diff --git a/Changelog.md b/Changelog.md new file mode 100644 index 0000000..28e67bb --- /dev/null +++ b/Changelog.md @@ -0,0 +1,46 @@ +### Welcome to the DEROHE Testnet +[Explorer](https://testnetexplorer.dero.io) [Source](https://github.com/deroproject/derohe) [Twitter](https://twitter.com/DeroProject) [Discord](https://discord.gg/H95TJDp) [Wiki](https://wiki.dero.io) [Github](https://github.com/deroproject/derohe) [DERO CryptoNote Mainnet Stats](http://network.dero.io) [Mainnet WebWallet](https://wallet.dero.io/) + +### DERO HE Changelog +[From Wikipedia: ](https://en.wikipedia.org/wiki/Homomorphic_encryption) + +###At this point in time, DERO blockchain has the first mover advantage in the following + * Private SCs ( no one knows who owns what tokens and who is transferring to whom and how much is being transferred) + * Homomorphic protocol + * Ability to do instant sync (takes couple of seconds or minutes), depends on network bandwidth. + * Ability to deliver encrypted license keys and other data. + * Pruned chains are the core. + * Ability to model 99.9% earth based financial model of the world. + * Privacy by design, backed by crypto algorithms. Many years of research in place. + + +###3.3 + * Private SCs are now supported. (90% completed). + * Sample Token contract is available with guide. + * Multi-send is now possible. sending to multiple destination per tx + * Few more ideas implemented and will be tested for review in upcoming technology preview. + +###3.2 + * Open SCs are now supported + * Private SCs which have their balance encrypted at all times (under implementation) + * SCs can now update themselves. however, new code will only run on next invocation + * Multi Send is under implementation. + +###3.1 + * TX now have significant savings of around 31 * ringsize bytes for every tx + * Daemon now supports pruned chains. + * Daemon by default bootstraps a pruned chain. + * Daemon currently syncs full node by using --fullnode option. + * P2P has been rewritten for various improvements and easier understanding of state machine + * Address specification now enables to embed various RPC parameters for easier transaction + * DERO blockchain represents transaction finality in a couple of blocks (less than 1 minute), unlike other blockchains. + * Proving and parsing of embedded data is now available in explorer. + * Senders/Receivers both have proofs which confirm data sent on execution. + * All tx now have inbuilt space of 144 bytes for user defined data + * User defined space has inbuilt RPC which can be used to implement most practical use-cases.All user defined data is encrypted. + * The model currrently defines data on chain while execution is referred to wallet extensions. A dummy example of pongserver extension showcases how to enable purchases/delivery of license keys/information privately. + * Burn transactions which burn value are now working. + +###3.0 + * DERO HE implemented + diff --git a/Start.md b/Start.md index 6ae14fa..3e6e5f3 100644 --- a/Start.md +++ b/Start.md @@ -2,7 +2,7 @@ DERO is written in golang and very easy to install both from source and binary. Installation From Source: - Install Golang, minimum Golang 1.10.3 required. + Install Golang, minimum Golang 1.15 required. In go workspace: go get -u github.com/deroproject/derohe/... Check go workspace bin folder for binaries. For example on Linux machine following binaries will be created: diff --git a/block/block.go b/block/block.go index ba52397..5078de2 100644 --- a/block/block.go +++ b/block/block.go @@ -24,10 +24,10 @@ import "runtime/debug" import "encoding/hex" import "encoding/binary" -import "github.com/ebfe/keccak" +import "golang.org/x/crypto/sha3" import "github.com/romana/rlog" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" //import "github.com/deroproject/derosuite/config" import "github.com/deroproject/derohe/astrobwt" @@ -65,7 +65,7 @@ func (bl *Block) GetHash() (hash crypto.Hash) { long_header := bl.GetBlockWork() // keccak hash of this above blob, gives the block id - return crypto.Keccak256(long_header) + return sha3.Sum256(long_header) } // converts a block, into a getwork style work, ready for either submitting the block @@ -78,7 +78,7 @@ func (bl *Block) GetBlockWork() []byte { buf = append(buf, []byte{byte(bl.Major_Version), byte(bl.Minor_Version), 0, 0, 0, 0, 0}...) // 0 first 7 bytes are version in little endia format binary.LittleEndian.PutUint32(buf[2:6], uint32(bl.Timestamp)) - header_hash := crypto.Keccak256(bl.getserializedheaderforwork()) // 0 + 7 + header_hash := sha3.Sum256(bl.getserializedheaderforwork()) // 0 + 7 buf = append(buf, header_hash[:]...) // 0 + 7 + 32 = 39 @@ -251,7 +251,7 @@ func (bl *Block) GetTipsHash() (result crypto.Hash) { }*/ // add all the remaining hashes - h := keccak.New256() + h := sha3.New256() for i := range bl.Tips { h.Write(bl.Tips[i][:]) } @@ -263,7 +263,7 @@ func (bl *Block) GetTipsHash() (result crypto.Hash) { // get block transactions // we have discarded the merkle tree and have shifted to a plain version func (bl *Block) GetTXSHash() (result crypto.Hash) { - h := keccak.New256() + h := sha3.New256() for i := range bl.Tx_hashes { h.Write(bl.Tx_hashes[i][:]) } diff --git a/blockchain/blockchain.go b/blockchain/blockchain.go index 67f4b72..7b3a3b6 100644 --- a/blockchain/blockchain.go +++ b/blockchain/blockchain.go @@ -47,7 +47,7 @@ import "github.com/golang/groupcache/lru" import hashicorp_lru "github.com/hashicorp/golang-lru" import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/errormsg" import "github.com/prometheus/client_golang/prometheus" @@ -57,6 +57,7 @@ import "github.com/deroproject/derohe/globals" import "github.com/deroproject/derohe/transaction" import "github.com/deroproject/derohe/blockchain/mempool" import "github.com/deroproject/derohe/blockchain/regpool" +import "github.com/deroproject/derohe/rpc" /* import "github.com/deroproject/derosuite/emission" @@ -80,6 +81,7 @@ type Blockchain struct { Height int64 // chain height is always 1 more than block height_seen int64 // height seen on peers Top_ID crypto.Hash // id of the top block + Pruned int64 // until where the chain has been pruned Tips map[crypto.Hash]crypto.Hash // current tips @@ -108,6 +110,10 @@ type Blockchain struct { RPC_NotifyNewBlock *sync.Cond // used to notify rpc that a new block has been found RPC_NotifyHeightChanged *sync.Cond // used to notify rpc that chain height has changed due to addition of block + Dev_Address_Bytes []byte // used to fund reward every block + + Sync bool // whether the sync is active, used while bootstrapping + sync.RWMutex } @@ -168,6 +174,7 @@ func Blockchain_Start(params map[string]interface{}) (*Blockchain, error) { logger.Fatalf("Failed to add genesis block, we can no longer continue. err %s", err) } } + /* // genesis block not in chain, add it to chain, together with its miner tx @@ -225,9 +232,26 @@ func Blockchain_Start(params map[string]interface{}) (*Blockchain, error) { // hard forks must be initialized asap init_hard_forks(params) + // parse dev address once and for all + if addr, err := rpc.NewAddress(globals.Config.Dev_Address); err != nil { + logger.Fatalf("Could not parse dev address, err:%s", err) + } else { + chain.Dev_Address_Bytes = addr.PublicKey.EncodeCompressed() + } + // load the chain from the disk chain.Initialise_Chain_From_DB() + chain.Sync = true + //if globals.Arguments["--fullnode"] != nil { + if chain.Get_Height() <= 1 { + chain.Sync = false + if globals.Arguments["--fullnode"].(bool) { + chain.Sync = globals.Arguments["--fullnode"].(bool) + } + } + //} + // logger.Fatalf("Testing complete quitting") go clean_up_valid_cache() // clean up valid cache @@ -504,9 +528,11 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro } // always check whether the coin base tx is okay - if bl.Height != 0 && !chain.Verify_Transaction_Coinbase(cbl, &bl.Miner_TX) { // if miner address is not registered give error - block_logger.Warnf("Miner address is not registered") - return errormsg.ErrInvalidBlock, false + if bl.Height != 0 { + if err = chain.Verify_Transaction_Coinbase(cbl, &bl.Miner_TX); err != nil { // if miner address is not registered give error + block_logger.Warnf("Error verifying coinbase tx, err :'%s'", err) + return err, false + } } // TODO we need to verify address whether they are valid points on curve or not @@ -563,7 +589,7 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro // another check, whether the tx is build with the latest snapshot of balance tree { for i := 0; i < len(cbl.Txs); i++ { - if cbl.Txs[i].TransactionType == transaction.NORMAL { + if cbl.Txs[i].TransactionType == transaction.NORMAL || cbl.Txs[i].TransactionType == transaction.BURN_TX || cbl.Txs[i].TransactionType == transaction.SC_TX { if cbl.Txs[i].Height+1 != cbl.Bl.Height { block_logger.Warnf("invalid tx mined %s", cbl.Txs[i].GetHash()) return errormsg.ErrTXDoubleSpend, false @@ -579,12 +605,12 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro nonce_map := map[crypto.Hash]bool{} for i := 0; i < len(cbl.Txs); i++ { - if cbl.Txs[i].TransactionType == transaction.NORMAL { - if _, ok := nonce_map[cbl.Txs[i].Proof.Nonce()]; ok { + if cbl.Txs[i].TransactionType == transaction.NORMAL || cbl.Txs[i].TransactionType == transaction.BURN_TX || cbl.Txs[i].TransactionType == transaction.SC_TX { + if _, ok := nonce_map[cbl.Txs[i].Payloads[0].Proof.Nonce()]; ok { block_logger.Warnf("Double Spend attack within block %s", cbl.Txs[i].GetHash()) return errormsg.ErrTXDoubleSpend, false } - nonce_map[cbl.Txs[i].Proof.Nonce()] = true + nonce_map[cbl.Txs[i].Payloads[0].Proof.Nonce()] = true } } } @@ -613,9 +639,9 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro hf_version := chain.Get_Current_Version_at_Height(chain.Calculate_Height_At_Tips(bl.Tips)) for i := 0; i < len(cbl.Txs); i++ { go func(j int) { - if !chain.Verify_Transaction_NonCoinbase(hf_version, cbl.Txs[j]) { // transaction verification failed + if err := chain.Verify_Transaction_NonCoinbase(hf_version, cbl.Txs[j]); err != nil { // transaction verification failed atomic.AddInt32(&fail_count, 1) // increase fail count by 1 - block_logger.Warnf("Block verification failed rejecting since TX %s verification failed", cbl.Txs[j].GetHash()) + block_logger.Warnf("Block verification failed rejecting since TX %s verification failed, err:'%s'", cbl.Txs[j].GetHash(), err) } wg.Done() }(i) @@ -705,6 +731,7 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro // any blocks which have not changed their topo will be skipped using graviton trick skip := true + for i := int64(0); i < int64(len(full_order)); i++ { // check whether the new block is at the same position at the last position @@ -752,12 +779,16 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro } - var balance_tree *graviton.Tree - // + var balance_tree, sc_meta *graviton.Tree + _ = sc_meta + + var ss *graviton.Snapshot if bl_current.Height == 0 { // if it's genesis block - if ss, err := chain.Store.Balance_store.LoadSnapshot(0); err != nil { + if ss, err = chain.Store.Balance_store.LoadSnapshot(0); err != nil { panic(err) - } else if balance_tree, err = ss.GetTree(BALANCE_TREE); err != nil { + } else if balance_tree, err = ss.GetTree(config.BALANCE_TREE); err != nil { + panic(err) + } else if sc_meta, err = ss.GetTree(config.SC_META); err != nil { panic(err) } } else { // we already have a block before us, use it @@ -772,13 +803,15 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro record_version = toporecord.State_Version } - ss, err := chain.Store.Balance_store.LoadSnapshot(record_version) + ss, err = chain.Store.Balance_store.LoadSnapshot(record_version) if err != nil { panic(err) } - balance_tree, err = ss.GetTree(BALANCE_TREE) - if err != nil { + if balance_tree, err = ss.GetTree(config.BALANCE_TREE); err != nil { + panic(err) + } + if sc_meta, err = ss.GetTree(config.SC_META); err != nil { panic(err) } } @@ -790,7 +823,12 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro // their transactions are ignored //chain.Store.Topo_store.Write(i+base_topo_index, full_order[i],0, int64(bl_current.Height)) // write entry so as sideblock could work + var data_trees []*graviton.Tree + if !chain.isblock_SideBlock_internal(full_order[i], current_topo_block, int64(bl_current.Height)) { + + sc_change_cache := map[crypto.Hash]*graviton.Tree{} // cache entire changes for entire block + for _, txhash := range bl_current.Tx_hashes { // execute all the transactions if tx_bytes, err := chain.Store.Block_tx_store.ReadTX(txhash); err != nil { panic(err) @@ -799,23 +837,74 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro if err = tx.DeserializeHeader(tx_bytes); err != nil { panic(err) } + for t := range tx.Payloads { + if !tx.Payloads[t].SCID.IsZero() { + tree, _ := ss.GetTree(string(tx.Payloads[t].SCID[:])) + sc_change_cache[tx.Payloads[t].SCID] = tree + } + } // we have loaded a tx successfully, now lets execute it - fees_collected += chain.process_transaction(tx, balance_tree) + tx_fees := chain.process_transaction(sc_change_cache, tx, balance_tree) + + //fmt.Printf("transaction %s type %s data %+v\n", txhash, tx.TransactionType, tx.SCDATA) + if tx.TransactionType == transaction.SC_TX { + tx_fees, err = chain.process_transaction_sc(sc_change_cache, ss, bl_current.Height, uint64(current_topo_block), bl_current_hash, tx, balance_tree, sc_meta) + + //fmt.Printf("Processsing sc err %s\n", err) + if err == nil { // TODO process gasg here + + } + } + fees_collected += tx_fees } } - chain.process_miner_transaction(bl_current.Miner_TX, bl_current.Height == 0, balance_tree, fees_collected) + // at this point, we must commit all the SCs, so entire tree hash is interlinked + for scid, v := range sc_change_cache { + meta_bytes, err := sc_meta.Get(SC_Meta_Key(scid)) + if err != nil { + panic(err) + } + + var meta SC_META_DATA // the meta contains metadata about SC + if err := meta.UnmarshalBinary(meta_bytes); err != nil { + panic(err) + } + + if meta.DataHash, err = v.Hash(); err != nil { // encode data tree hash + panic(err) + } + + sc_meta.Put(SC_Meta_Key(scid), meta.MarshalBinary()) + data_trees = append(data_trees, v) + + /*fmt.Printf("will commit tree name %x \n", v.GetName()) + c := v.Cursor() + for k, v, err := c.First(); err == nil; k, v, err = c.Next() { + fmt.Printf("key=%x, value=%x\n", k, v) + }*/ + + } + + chain.process_miner_transaction(bl_current.Miner_TX, bl_current.Height == 0, balance_tree, fees_collected, bl_current.Height) } else { rlog.Debugf("this block is a side block block height %d blid %s ", chain.Load_Block_Height(full_order[i]), full_order[i]) } // we are here, means everything is okay, lets commit the update balance tree - commit_version, err := graviton.Commit(balance_tree) + + data_trees = append(data_trees, balance_tree, sc_meta) + + //fmt.Printf("committing data trees %+v\n", data_trees) + + commit_version, err := graviton.Commit(data_trees...) if err != nil { panic(err) } + //fmt.Printf("committed trees version %d\n", commit_version) + chain.Store.Topo_store.Write(current_topo_block, full_order[i], commit_version, chain.Load_Block_Height(full_order[i])) rlog.Debugf("%d %s topo_index %d base topo %d", i, full_order[i], current_topo_block, base_topo_index) @@ -904,7 +993,7 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro continue } - case transaction.NORMAL: + case transaction.NORMAL, transaction.BURN_TX, transaction.SC_TX: if chain.Mempool.Mempool_TX_Exist(txid) { rlog.Tracef(1, "Deleting TX from mempool txid=%s", txid) chain.Mempool.Mempool_Delete_TX(txid) @@ -920,7 +1009,7 @@ func (chain *Blockchain) Add_Complete_Block(cbl *block.Complete_Block) (err erro // ggive regpool a chance to register if ss, err := chain.Store.Balance_store.LoadSnapshot(0); err == nil { - if balance_tree, err := ss.GetTree(BALANCE_TREE); err == nil { + if balance_tree, err := ss.GetTree(config.BALANCE_TREE); err == nil { chain.Regpool.HouseKeeping(uint64(block_height), func(tx *transaction.Transaction) bool { if tx.TransactionType != transaction.REGISTRATION { // tx not registration so delete @@ -948,6 +1037,11 @@ func (chain *Blockchain) Initialise_Chain_From_DB() { chain.Lock() defer chain.Unlock() + chain.Pruned = chain.LocatePruneTopo() + if chain.Pruned >= 1 { + logger.Debugf("Chain Pruned until %d\n", chain.Pruned) + } + // find the tips from the chain , first by reaching top height // then downgrading to top-10 height // then reworking the chain to get the tip @@ -963,7 +1057,7 @@ func (chain *Blockchain) Initialise_Chain_From_DB() { // get dag unsettled, it's only possible when we have the tips // chain.dag_unsettled = chain.Get_DAG_Unsettled() // directly off the disk - logger.Infof("Chain Tips %+v Height %d", chain.Tips, chain.Height) + logger.Debugf("Reloaded Chain Tips %+v Height %d", chain.Tips, chain.Height) } @@ -1093,19 +1187,38 @@ var block_processing_time = prometheus.NewHistogram(prometheus.HistogramOpts{ // add a transaction to MEMPOOL, // verifying everything means everything possible // this only change mempool, no DB changes -func (chain *Blockchain) Add_TX_To_Pool(tx *transaction.Transaction) (result bool) { +func (chain *Blockchain) Add_TX_To_Pool(tx *transaction.Transaction) error { var err error + + if tx.IsPremine() { + return fmt.Errorf("premine tx not mineable") + } if tx.IsRegistration() { // registration tx will not go any forward // ggive regpool a chance to register if ss, err := chain.Store.Balance_store.LoadSnapshot(0); err == nil { - if balance_tree, err := ss.GetTree(BALANCE_TREE); err == nil { + if balance_tree, err := ss.GetTree(config.BALANCE_TREE); err == nil { if _, err := balance_tree.Get(tx.MinerAddress[:]); err == nil { // address already registered - return false + return nil + } else { // add to regpool + if chain.Regpool.Regpool_Add_TX(tx, 0) { + return nil + } else { + return fmt.Errorf("registration for address is already pending") + } } + } else { + return err } + } else { + return err } - return chain.Regpool.Regpool_Add_TX(tx, 0) + } + + switch tx.TransactionType { + case transaction.BURN_TX, transaction.NORMAL, transaction.SC_TX: + default: + return fmt.Errorf("such transaction type cannot appear in mempool") } // track counter for the amount of mempool tx @@ -1116,25 +1229,25 @@ func (chain *Blockchain) Add_TX_To_Pool(tx *transaction.Transaction) (result boo // Coin base TX can not come through this path if tx.IsCoinbase() { logger.WithFields(log.Fields{"txid": txhash}).Warnf("TX rejected coinbase tx cannot appear in mempool") - return false + return fmt.Errorf("TX rejected coinbase tx cannot appear in mempool") } chain_height := uint64(chain.Get_Height()) if chain_height > tx.Height { rlog.Tracef(2, "TX %s rejected since chain has already progressed", txhash) - return false + return fmt.Errorf("TX %s rejected since chain has already progressed", txhash) } // quick check without calculating everything whether tx is in pool, if yes we do nothing if chain.Mempool.Mempool_TX_Exist(txhash) { rlog.Tracef(2, "TX %s rejected Already in MEMPOOL", txhash) - return false + return fmt.Errorf("TX %s rejected Already in MEMPOOL", txhash) } // check whether tx is already mined if _, err = chain.Store.Block_tx_store.ReadTX(txhash); err == nil { rlog.Tracef(2, "TX %s rejected Already mined in some block", txhash) - return false + return fmt.Errorf("TX %s rejected Already mined in some block", txhash) } hf_version := chain.Get_Current_Version_at_Height(int64(chain_height)) @@ -1143,12 +1256,12 @@ func (chain *Blockchain) Add_TX_To_Pool(tx *transaction.Transaction) (result boo // currently, limits are as per consensus if uint64(len(tx.Serialize())) > config.STARGATE_HE_MAX_TX_SIZE { logger.WithFields(log.Fields{"txid": txhash}).Warnf("TX rejected Size %d byte Max possible %d", len(tx.Serialize()), config.STARGATE_HE_MAX_TX_SIZE) - return false + return fmt.Errorf("TX rejected Size %d byte Max possible %d", len(tx.Serialize()), config.STARGATE_HE_MAX_TX_SIZE) } // check whether enough fees is provided in the transaction calculated_fee := chain.Calculate_TX_fee(hf_version, uint64(len(tx.Serialize()))) - provided_fee := tx.Statement.Fees // get fee from tx + provided_fee := tx.Fees() // get fee from tx _ = calculated_fee _ = provided_fee @@ -1164,20 +1277,20 @@ func (chain *Blockchain) Add_TX_To_Pool(tx *transaction.Transaction) (result boo } */ - if chain.Verify_Transaction_NonCoinbase(hf_version, tx) && chain.Verify_Transaction_NonCoinbase_DoubleSpend_Check(tx) { - if chain.Mempool.Mempool_Add_TX(tx, 0) { // new tx come with 0 marker - rlog.Tracef(2, "Successfully added tx %s to pool", txhash) - - mempool_tx_counter.Inc() - return true - } else { - rlog.Tracef(2, "TX %s rejected by pool", txhash) - return false - } + if err := chain.Verify_Transaction_NonCoinbase(hf_version, tx); err != nil { + rlog.Warnf("Incoming TX %s could not be verified, err %s", txhash, err) + return fmt.Errorf("Incoming TX %s could not be verified, err %s", txhash, err) } - rlog.Warnf("Incoming TX %s could not be verified", txhash) - return false + if chain.Mempool.Mempool_Add_TX(tx, 0) { // new tx come with 0 marker + rlog.Tracef(2, "Successfully added tx %s to pool", txhash) + + mempool_tx_counter.Inc() + return nil + } else { + rlog.Tracef(2, "TX %s rejected by pool", txhash) + return fmt.Errorf("TX %s rejected by pool", txhash) + } } @@ -1618,7 +1731,7 @@ func (chain *Blockchain) BuildReachabilityNonces(bl *block.Block) map[crypto.Has } // tx has been loaded, now lets get the nonce - nonce_reach_map[tx.Proof.Nonce()] = true // add element to map for next check + nonce_reach_map[tx.Payloads[0].Proof.Nonce()] = true // add element to map for next check } } return nonce_reach_map diff --git a/blockchain/blockheader.go b/blockchain/blockheader.go index 27b1533..e48dd70 100644 --- a/blockchain/blockheader.go +++ b/blockchain/blockheader.go @@ -17,13 +17,13 @@ package blockchain //import "fmt" -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/rpc" // this function is only used by the RPC and is not used by the core and should be moved to RPC interface /* fill up the above structure from the blockchain */ -func (chain *Blockchain) GetBlockHeader(hash crypto.Hash) (result structures.BlockHeader_Print, err error) { +func (chain *Blockchain) GetBlockHeader(hash crypto.Hash) (result rpc.BlockHeader_Print, err error) { bl, err := chain.Load_BL_FROM_ID(hash) if err != nil { return diff --git a/blockchain/difficulty.go b/blockchain/difficulty.go index 6f4bf9d..889f295 100644 --- a/blockchain/difficulty.go +++ b/blockchain/difficulty.go @@ -23,7 +23,7 @@ import "math/big" import "github.com/deroproject/derohe/block" import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/globals" var ( diff --git a/blockchain/genesis.go b/blockchain/genesis.go index 66d620e..9530f28 100644 --- a/blockchain/genesis.go +++ b/blockchain/genesis.go @@ -22,7 +22,7 @@ import "encoding/hex" import "github.com/romana/rlog" //import "github.com/deroproject/derosuite/address" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/block" import "github.com/deroproject/derohe/globals" diff --git a/blockchain/mempool/mempool.go b/blockchain/mempool/mempool.go index c90471b..f5c3d63 100644 --- a/blockchain/mempool/mempool.go +++ b/blockchain/mempool/mempool.go @@ -31,7 +31,7 @@ import log "github.com/sirupsen/logrus" import "github.com/deroproject/derohe/transaction" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" // this is only used for sorting and nothing else type TX_Sorting_struct struct { @@ -126,7 +126,7 @@ func (obj *mempool_object) UnmarshalJSON(data []byte) error { err = obj.Tx.DeserializeHeader(tx_bytes) if err == nil { - obj.FEEperBYTE = obj.Tx.Statement.Fees / obj.Size + obj.FEEperBYTE = obj.Tx.Fees() / obj.Size } return err } @@ -283,7 +283,7 @@ func (pool *Mempool) Mempool_Add_TX(tx *transaction.Transaction, Height uint64) var object mempool_object tx_hash := crypto.Hash(tx.GetHash()) - if pool.Mempool_Keyimage_Spent(tx.Proof.Nonce()) { + if pool.Mempool_Keyimage_Spent(tx.Payloads[0].Proof.Nonce()) { rlog.Debugf("Rejecting TX, since nonce already seen %x", tx_hash) return false } @@ -300,7 +300,7 @@ func (pool *Mempool) Mempool_Add_TX(tx *transaction.Transaction, Height uint64) // pool.key_images.Store(tx.Vin[i].(transaction.Txin_to_key).K_image,true) // add element to map for next check // } - pool.key_images.Store(tx.Proof.Nonce(), true) + pool.key_images.Store(tx.Payloads[0].Proof.Nonce(), true) // we are here means we can add it to pool object.Tx = tx @@ -308,7 +308,7 @@ func (pool *Mempool) Mempool_Add_TX(tx *transaction.Transaction, Height uint64) object.Added = uint64(time.Now().UTC().Unix()) object.Size = uint64(len(tx.Serialize())) - object.FEEperBYTE = tx.Statement.Fees / object.Size + object.FEEperBYTE = tx.Fees() / object.Size pool.txs.Store(tx_hash, &object) @@ -367,7 +367,7 @@ func (pool *Mempool) Mempool_Delete_TX(txid crypto.Hash) (tx *transaction.Transa // for i := 0; i < len(object.Tx.Vin); i++ { // pool.key_images.Delete(object.Tx.Vin[i].(transaction.Txin_to_key).K_image) // } - pool.key_images.Delete(tx.Proof.Nonce()) + pool.key_images.Delete(tx.Payloads[0].Proof.Nonce()) //pool.sort_list() // sort and update pool list pool.modified = true // pool has been modified diff --git a/blockchain/miner_block.go b/blockchain/miner_block.go index 17cd685..d362a24 100644 --- a/blockchain/miner_block.go +++ b/blockchain/miner_block.go @@ -31,9 +31,9 @@ import "github.com/romana/rlog" import "github.com/deroproject/derohe/block" import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/address" +import "github.com/deroproject/derohe/rpc" //import "github.com/deroproject/derohe/emission" import "github.com/deroproject/derohe/transaction" @@ -50,7 +50,7 @@ import "github.com/deroproject/graviton" // the top hash over which to do mining now ( it should already be in the chain) // this is work in progress // TODO we need to rework fees algorithm, to improve its quality and lower fees -func (chain *Blockchain) Create_new_miner_block(miner_address address.Address, tx *transaction.Transaction) (cbl *block.Complete_Block, bl block.Block) { +func (chain *Blockchain) Create_new_miner_block(miner_address rpc.Address, tx *transaction.Transaction) (cbl *block.Complete_Block, bl block.Block) { //chain.Lock() //defer chain.Unlock() @@ -88,7 +88,7 @@ func (chain *Blockchain) Create_new_miner_block(miner_address address.Address, t panic(err) } - balance_tree, err := ss.GetTree(BALANCE_TREE) + balance_tree, err := ss.GetTree(config.BALANCE_TREE) if err != nil { panic(err) } @@ -268,7 +268,7 @@ func (chain *Blockchain) Create_new_miner_block(miner_address address.Address, t var cache_block block.Block var cache_block_mutex sync.Mutex -func (chain *Blockchain) Create_new_block_template_mining(top_hash crypto.Hash, miner_address address.Address, reserve_space int) (bl block.Block, blockhashing_blob string, block_template_blob string, reserved_pos int) { +func (chain *Blockchain) Create_new_block_template_mining(top_hash crypto.Hash, miner_address rpc.Address, reserve_space int) (bl block.Block, blockhashing_blob string, block_template_blob string, reserved_pos int) { rlog.Debugf("Mining block will give reward to %s", miner_address) cache_block_mutex.Lock() @@ -310,12 +310,6 @@ var duplicate_height_check = map[uint64]bool{} // otherwise the miner is trying to attack the network func (chain *Blockchain) Accept_new_block(block_template []byte, blockhashing_blob []byte) (blid crypto.Hash, result bool, err error) { - - // check whether we are in lowcpu mode, if yes reject the block - if globals.Arguments["--lowcpuram"].(bool) { - globals.Logger.Warnf("Mining is deactivated since daemon is running in low cpu mode, please check program options.") - return blid, false, fmt.Errorf("Please decativate lowcpuram mode") - } if globals.Arguments["--sync-node"].(bool) { globals.Logger.Warnf("Mining is deactivated since daemon is running with --sync-mode, please check program options.") return blid, false, fmt.Errorf("Please deactivate --sync-node option before mining") @@ -415,7 +409,6 @@ func (chain *Blockchain) Accept_new_block(block_template []byte, blockhashing_bl } err, result = chain.Add_Complete_Block(cbl) - if result { duplicate_height_check[bl.Height] = true diff --git a/blockchain/prune_history.go b/blockchain/prune_history.go index 0e9a320..0d30562 100644 --- a/blockchain/prune_history.go +++ b/blockchain/prune_history.go @@ -28,6 +28,7 @@ import "path/filepath" import "github.com/romana/rlog" +import "github.com/deroproject/derohe/config" import "github.com/deroproject/graviton" import "github.com/deroproject/derohe/block" import "github.com/deroproject/derohe/globals" @@ -158,9 +159,9 @@ func rewrite_graviton_store(store *storage, prune_topoheight int64, max_topoheig var old_ss, write_ss *graviton.Snapshot var old_balance_tree, write_balance_tree *graviton.Tree if old_ss, err = store.Balance_store.LoadSnapshot(toporecord.State_Version); err == nil { - if old_balance_tree, err = old_ss.GetTree(BALANCE_TREE); err == nil { + if old_balance_tree, err = old_ss.GetTree(config.BALANCE_TREE); err == nil { if write_ss, err = write_store.LoadSnapshot(0); err == nil { - if write_balance_tree, err = write_ss.GetTree(BALANCE_TREE); err == nil { + if write_balance_tree, err = write_ss.GetTree(config.BALANCE_TREE); err == nil { var latest_commit_version uint64 latest_commit_version, err = clone_entire_tree(old_balance_tree, write_balance_tree) @@ -195,16 +196,16 @@ func rewrite_graviton_store(store *storage, prune_topoheight int64, max_topoheig if old_toporecord, err = store.Topo_store.Read(old_topo); err == nil { if old_ss, err = store.Balance_store.LoadSnapshot(old_toporecord.State_Version); err == nil { - if old_balance_tree, err = old_ss.GetTree(BALANCE_TREE); err == nil { + if old_balance_tree, err = old_ss.GetTree(config.BALANCE_TREE); err == nil { // fetch new tree data if new_toporecord, err = store.Topo_store.Read(new_topo); err == nil { if new_ss, err = store.Balance_store.LoadSnapshot(new_toporecord.State_Version); err == nil { - if new_balance_tree, err = new_ss.GetTree(BALANCE_TREE); err == nil { + if new_balance_tree, err = new_ss.GetTree(config.BALANCE_TREE); err == nil { // fetch tree where to write it if write_ss, err = write_store.LoadSnapshot(0); err == nil { - if write_tree, err = write_ss.GetTree(BALANCE_TREE); err == nil { + if write_tree, err = write_ss.GetTree(config.BALANCE_TREE); err == nil { // new_balance_tree.Graph("/tmp/original.dot") // write_tree.Graph("/tmp/writable.dot") diff --git a/blockchain/regpool/regpool.go b/blockchain/regpool/regpool.go index b9a2208..b2117a3 100644 --- a/blockchain/regpool/regpool.go +++ b/blockchain/regpool/regpool.go @@ -30,7 +30,7 @@ import log "github.com/sirupsen/logrus" import "github.com/deroproject/derohe/transaction" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" // this is only used for sorting and nothing else type TX_Sorting_struct struct { @@ -125,7 +125,7 @@ func (obj *regpool_object) UnmarshalJSON(data []byte) error { err = obj.Tx.DeserializeHeader(tx_bytes) if err == nil { - obj.FEEperBYTE = obj.Tx.Statement.Fees / obj.Size + obj.FEEperBYTE = 0 } return err } diff --git a/blockchain/sc.go b/blockchain/sc.go new file mode 100644 index 0000000..85410bd --- /dev/null +++ b/blockchain/sc.go @@ -0,0 +1,300 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package blockchain + +// this file implements necessary structure to SC handling + +import "fmt" +import "runtime/debug" +import "encoding/binary" +import "github.com/deroproject/derohe/cryptography/crypto" + +import "github.com/deroproject/derohe/dvm" + +//import "github.com/deroproject/graviton" +import "github.com/deroproject/derohe/rpc" +import "github.com/deroproject/derohe/transaction" + +import "github.com/romana/rlog" + +// currently we 2 contract types +// 1 OPEN +// 2 PRIVATE +type SC_META_DATA struct { + Type byte // 0 Open, 1 Private + Balance uint64 + DataHash crypto.Hash // hash of SC data tree is here, so as the meta tree verifies all SC DATA +} + +// serialize the structure +func (meta SC_META_DATA) MarshalBinary() (buf []byte) { + buf = make([]byte, 41, 41) + buf[0] = meta.Type + binary.LittleEndian.PutUint64(buf[1:], meta.Balance) + copy(buf[1+8+len(meta.DataHash):], meta.DataHash[:]) + return +} + +func (meta *SC_META_DATA) UnmarshalBinary(buf []byte) (err error) { + if len(buf) != 1+8+32 { + return fmt.Errorf("input buffer should be of 41 bytes in length") + } + meta.Type = buf[0] + meta.Balance = binary.LittleEndian.Uint64(buf[1:]) + copy(meta.DataHash[:], buf[1+8+len(meta.DataHash):]) + return nil +} + +func SC_Meta_Key(scid crypto.Hash) []byte { + return scid[:] +} +func SC_Code_Key(scid crypto.Hash) []byte { + return dvm.Variable{Type: dvm.String, Value: "C"}.MarshalBinaryPanic() +} + +// this will process the SC transaction +// the tx should only be processed , if it has been processed + +func (chain *Blockchain) execute_sc_function(w_sc_tree *Tree_Wrapper, data_tree *Tree_Wrapper, scid crypto.Hash, bl_height, bl_topoheight uint64, bl_hash crypto.Hash, tx transaction.Transaction, entrypoint string, hard_fork_version_current int64) (gas uint64, err error) { + defer func() { + // safety so if anything wrong happens, verification fails + if r := recover(); r != nil { + logger.Warnf("Recovered while rewinding chain, Stack trace below block_hash ") + logger.Warnf("Stack trace \n%s", debug.Stack()) + } + }() + + //if !tx.Verify_SC_Signature() { // if tx is not SC TX, or Signature could not be verified skip it + // return + //} + + tx_hash := tx.GetHash() + tx_store := dvm.Initialize_TX_store() + + // used as value loader from disk + // this function is used to load any data required by the SC + + diskloader := func(key dvm.DataKey, found *uint64) (result dvm.Variable) { + var exists bool + if result, exists = chain.LoadSCValue(data_tree, key.SCID, key.MarshalBinaryPanic()); exists { + *found = uint64(1) + } + //fmt.Printf("Loading from disk %+v result %+v found status %+v \n", key, result, exists) + + return + } + + diskloader_raw := func(key []byte) (value []byte, found bool) { + var err error + value, err = data_tree.Get(key[:]) + if err != nil { + return value, false + } + + if len(value) == 0 { + return value, false + } + //fmt.Printf("Loading from disk %+v result %+v found status %+v \n", key, result, exists) + + return value, true + } + + balance, sc_parsed, found := chain.ReadSC(w_sc_tree, data_tree, scid) + if !found { + fmt.Printf("SC not found\n") + return + } + // if we found the SC in parsed form, check whether entrypoint is found + function, ok := sc_parsed.Functions[entrypoint] + if !ok { + rlog.Warnf("stored SC does not contain entrypoint '%s' scid %s \n", entrypoint, scid) + return + } + _ = function + + //fmt.Printf("entrypoint found '%s' scid %s\n", entrypoint, scid) + //if len(sc_tx.Params) == 0 { // initialize params if not initialized earlier + // sc_tx.Params = map[string]string{} + //} + //sc_tx.Params["value"] = fmt.Sprintf("%d", sc_tx.Value) // overide value + + tx_store.DiskLoader = diskloader // hook up loading from chain + tx_store.DiskLoaderRaw = diskloader_raw + tx_store.BalanceAtStart = balance + tx_store.SCID = scid + + //fmt.Printf("tx store %v\n", tx_store) + + // setup block hash, height, topoheight correctly + state := &dvm.Shared_State{ + Store: tx_store, + Chain_inputs: &dvm.Blockchain_Input{ + BL_HEIGHT: bl_height, + BL_TOPOHEIGHT: uint64(bl_topoheight), + SCID: scid, + BLID: bl_hash, + TXID: tx_hash, + Signer: string(tx.MinerAddress[:]), + }, + } + + for p := range tx.Payloads { + if tx.Payloads[p].SCID.IsZero() { + state.DERO_Received += tx.Payloads[p].BurnValue + } + if tx.Payloads[p].SCID == scid { + state.Token_Received += tx.Payloads[p].BurnValue + } + } + + // setup balance correctly + tx_store.ReceiveInternal(scid, state.DERO_Received) + + // we have an entrypoint, now we must setup parameters and dvm + // all parameters are in string form to bypass translation issues in middle layers + params := map[string]interface{}{} + + for _, p := range function.Params { + switch { + case p.Type == dvm.Uint64 && p.Name == "value": + params[p.Name] = fmt.Sprintf("%d", state.DERO_Received) // overide value + case p.Type == dvm.Uint64 && tx.SCDATA.Has(p.Name, rpc.DataUint64): + params[p.Name] = fmt.Sprintf("%d", tx.SCDATA.Value(p.Name, rpc.DataUint64).(uint64)) + case p.Type == dvm.String && tx.SCDATA.Has(p.Name, rpc.DataString): + params[p.Name] = tx.SCDATA.Value(p.Name, rpc.DataString).(string) + + default: + err = fmt.Errorf("entrypoint '%s' parameter type missing or not yet supported (%+v)", entrypoint, p) + return + } + } + + result, err := dvm.RunSmartContract(&sc_parsed, entrypoint, state, params) + + //fmt.Printf("result value %+v\n", result) + + if err != nil { + rlog.Warnf("entrypoint '%s' scid %s err execution '%s' \n", entrypoint, scid, err) + return + } + + if err == nil && result.Type == dvm.Uint64 && result.Value.(uint64) == 0 { // confirm the changes + for k, v := range tx_store.Keys { + chain.StoreSCValue(data_tree, scid, k.MarshalBinaryPanic(), v.MarshalBinaryPanic()) + } + for k, v := range tx_store.RawKeys { + chain.StoreSCValue(data_tree, scid, []byte(k), v) + } + + data_tree.leftover_balance = tx_store.Balance(scid) + data_tree.transfere = append(data_tree.transfere, tx_store.Transfers[scid].TransferE...) + + } else { // discard all changes, since we never write to store immediately, they are purged, however we need to return any value associated + err = fmt.Errorf("Discarded knowingly") + return + } + + //fmt.Printf("SC execution finished amount value %d\n", tx.Value) + return + +} + +// reads SC, balance +func (chain *Blockchain) ReadSC(w_sc_tree *Tree_Wrapper, data_tree *Tree_Wrapper, scid crypto.Hash) (balance uint64, sc dvm.SmartContract, found bool) { + meta_bytes, err := w_sc_tree.Get(SC_Meta_Key(scid)) + if err != nil { + return + } + + var meta SC_META_DATA // the meta contains the link to the SC bytes + if err := meta.UnmarshalBinary(meta_bytes); err != nil { + return + } + balance = meta.Balance + + sc_bytes, err := data_tree.Get(SC_Code_Key(scid)) + if err != nil { + return + } + + var v dvm.Variable + + if err = v.UnmarshalBinary(sc_bytes); err != nil { + return + } + + sc, pos, err := dvm.ParseSmartContract(v.Value.(string)) + if err != nil { + return + } + + _ = pos + + found = true + return +} + +func (chain *Blockchain) LoadSCValue(data_tree *Tree_Wrapper, scid crypto.Hash, key []byte) (v dvm.Variable, found bool) { + //fmt.Printf("loading fromdb %s %s \n", scid, key) + + object_data, err := data_tree.Get(key[:]) + if err != nil { + return v, false + } + + if len(object_data) == 0 { + return v, false + } + + if err = v.UnmarshalBinary(object_data); err != nil { + return v, false + } + + return v, true +} + +// reads a value from SC, always read balance +func (chain *Blockchain) ReadSCValue(data_tree *Tree_Wrapper, scid crypto.Hash, key interface{}) (value interface{}) { + var keybytes []byte + + if key == nil { + return + } + switch k := key.(type) { + case uint64: + keybytes = dvm.DataKey{Key: dvm.Variable{Type: dvm.Uint64, Value: k}}.MarshalBinaryPanic() + case string: + keybytes = dvm.DataKey{Key: dvm.Variable{Type: dvm.String, Value: k}}.MarshalBinaryPanic() + case int64: + keybytes = dvm.DataKey{Key: dvm.Variable{Type: dvm.String, Value: k}}.MarshalBinaryPanic() + default: + return + } + + value_var, found := chain.LoadSCValue(data_tree, scid, keybytes) + //fmt.Printf("read value %+v", value_var) + if found && value_var.Type != dvm.Invalid { + value = value_var.Value + } + return +} + +// store the value in the chain +func (chain *Blockchain) StoreSCValue(data_tree *Tree_Wrapper, scid crypto.Hash, key, value []byte) { + data_tree.Put(key, value) + return +} diff --git a/blockchain/store.go b/blockchain/store.go index 8e99875..207a4d6 100644 --- a/blockchain/store.go +++ b/blockchain/store.go @@ -25,15 +25,13 @@ import "path/filepath" import log "github.com/sirupsen/logrus" import "github.com/deroproject/derohe/globals" import "github.com/deroproject/derohe/block" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/graviton" import "github.com/golang/groupcache/lru" -// note we are keeping the tree name small for disk savings, since they will be stored n times (atleast or archival nodes) -const BALANCE_TREE = "B" - // though these can be done within a single DB, these are separated for completely clarity purposes type storage struct { Balance_store *graviton.Store // stores most critical data, only history can be purged, its merkle tree is stored in the block @@ -85,7 +83,7 @@ func (s *storage) IsBalancesIntialized() bool { var balancehash, random_hash [32]byte balance_ss, _ := s.Balance_store.LoadSnapshot(0) // load most recent snapshot - balancetree, _ := balance_ss.GetTree(BALANCE_TREE) + balancetree, _ := balance_ss.GetTree(config.BALANCE_TREE) // avoid hardcoding any hash if balancehash, err = balancetree.Hash(); err == nil { @@ -354,3 +352,42 @@ func (chain *Blockchain) Load_Block_Topological_order_at_index(index_pos int64) } } + +//load store hash from 2 tree +func (chain *Blockchain) Load_Merkle_Hash(index_pos int64) (hash crypto.Hash, err error) { + + toporecord, err := chain.Store.Topo_store.Read(index_pos) + if err != nil { + return hash, err + } + if toporecord.IsClean() { + err = fmt.Errorf("cannot query clean block") + return + } + + ss, err := chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version) + if err != nil { + return + } + + balance_tree, err := ss.GetTree(config.BALANCE_TREE) + if err != nil { + return + } + sc_meta_tree, err := ss.GetTree(config.SC_META) + if err != nil { + return + } + balance_merkle_hash, err := balance_tree.Hash() + if err != nil { + return + } + meta_merkle_hash, err := sc_meta_tree.Hash() + if err != nil { + return + } + for i := range balance_merkle_hash { + hash[i] = balance_merkle_hash[i] ^ meta_merkle_hash[i] + } + return hash, nil +} diff --git a/blockchain/storefs.go b/blockchain/storefs.go index 9aa43a5..7ac163f 100644 --- a/blockchain/storefs.go +++ b/blockchain/storefs.go @@ -35,7 +35,7 @@ type storefs struct { func (s *storefs) ReadBlock(h [32]byte) ([]byte, error) { var dummy [32]byte if h == dummy { - panic("empty block") + return nil, fmt.Errorf("empty block") } dir := filepath.Join(filepath.Join(s.basedir, "bltx_store"), fmt.Sprintf("%02x", h[0]), fmt.Sprintf("%02x", h[1]), fmt.Sprintf("%02x", h[2])) diff --git a/blockchain/storetopo.go b/blockchain/storetopo.go index a52ba67..48bcece 100644 --- a/blockchain/storetopo.go +++ b/blockchain/storetopo.go @@ -23,7 +23,7 @@ import "path/filepath" import "encoding/binary" import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" type TopoRecord struct { BLOCK_ID [32]byte @@ -161,8 +161,7 @@ func (s *storetopofs) LocatePruneTopo() int64 { prune_topo-- - // fmt.Printf("pruned topo %d\n",prune_topo) - + pruned_till = prune_topo return prune_topo } @@ -208,7 +207,7 @@ func (s *storetopofs) binarySearchHeight(targetheight int64) (blids []crypto.Has } } - for i, count := midIndex, 0; i <= total_records && count < 100; i, count = i+1, count+1 { + for i, count := midIndex, 0; i < total_records && count < 100; i, count = i+1, count+1 { record, _ := s.Read(i) if record.Height == targetheight { blids = append(blids, record.BLOCK_ID) diff --git a/blockchain/transaction_execute.go b/blockchain/transaction_execute.go index e3c54b7..1e4ecc5 100644 --- a/blockchain/transaction_execute.go +++ b/blockchain/transaction_execute.go @@ -18,16 +18,42 @@ package blockchain // this file implements core execution of all changes to block chain homomorphically +import "fmt" import "math/big" import "golang.org/x/xerrors" -import "github.com/deroproject/derohe/crypto" +import "github.com/romana/rlog" + +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/transaction" +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/rpc" +import "github.com/deroproject/derohe/dvm" import "github.com/deroproject/graviton" -// process the miner tx, giving fees, miner rewatd etc -func (chain *Blockchain) process_miner_transaction(tx transaction.Transaction, genesis bool, balance_tree *graviton.Tree, fees uint64) { +// convert bitcoin model to our, but skip initial 4 years of supply, so our total supply gets to 10.5 million +const RewardReductionInterval = 210000 * 600 / config.BLOCK_TIME // 210000 comes from bitcoin +const BaseReward = 50 * 100000 * config.BLOCK_TIME / 600 // convert bitcoin reward system to our block +// CalcBlockSubsidy returns the subsidy amount a block at the provided height +// should have. This is mainly used for determining how much the coinbase for +// newly generated blocks awards as well as validating the coinbase for blocks +// has the expected value. +// +// The subsidy is halved every SubsidyReductionInterval blocks. Mathematically +// this is: baseSubsidy / 2^(height/SubsidyReductionInterval) +// +// At the target block generation rate for the main network, this is +// approximately every 4 years. +// + +// basically out of of the bitcoin supply, we have wiped of initial interval ( this wipes of 10.5 million, so total remaining is around 10.5 million +func CalcBlockReward(height uint64) uint64 { + return BaseReward >> ((height + RewardReductionInterval) / RewardReductionInterval) +} + +// process the miner tx, giving fees, miner rewatd etc +func (chain *Blockchain) process_miner_transaction(tx transaction.Transaction, genesis bool, balance_tree *graviton.Tree, fees uint64, height uint64) { var acckey crypto.Point if err := acckey.DecodeCompressed(tx.MinerAddress[:]); err != nil { panic(err) @@ -41,21 +67,39 @@ func (chain *Blockchain) process_miner_transaction(tx transaction.Transaction, g } // general coin base transaction - balance_serialized, err := balance_tree.Get(tx.MinerAddress[:]) - if err != nil { - panic(err) + base_reward := CalcBlockReward(uint64(height)) + full_reward := base_reward + fees + + dev_reward := (full_reward * config.DEVSHARE) / 10000 // take % from reward + miner_reward := full_reward - dev_reward // it's value, do subtraction + + { // giver miner reward + balance_serialized, err := balance_tree.Get(tx.MinerAddress[:]) + if err != nil { + panic(err) + } + balance := new(crypto.ElGamal).Deserialize(balance_serialized) + balance = balance.Plus(new(big.Int).SetUint64(miner_reward)) // add miners reward to miners balance homomorphically + balance_tree.Put(tx.MinerAddress[:], balance.Serialize()) // reserialize and store + } + + { // give devs reward + balance_serialized, err := balance_tree.Get(chain.Dev_Address_Bytes[:]) + if err != nil { + panic(err) + } + balance := new(crypto.ElGamal).Deserialize(balance_serialized) + balance = balance.Plus(new(big.Int).SetUint64(dev_reward)) // add devs reward to devs balance homomorphically + balance_tree.Put(chain.Dev_Address_Bytes[:], balance.Serialize()) // reserialize and store } - balance := new(crypto.ElGamal).Deserialize(balance_serialized) - balance = balance.Plus(new(big.Int).SetUint64(fees + 50000)) // add fees colllected to users balance homomorphically - balance_tree.Put(tx.MinerAddress[:], balance.Serialize()) // reserialize and store return } // process the tx, giving fees, miner rewatd etc // this should be atomic, either all should be done or none at all -func (chain *Blockchain) process_transaction(tx transaction.Transaction, balance_tree *graviton.Tree) uint64 { +func (chain *Blockchain) process_transaction(changed map[crypto.Hash]*graviton.Tree, tx transaction.Transaction, balance_tree *graviton.Tree) uint64 { //fmt.Printf("Processing/Executing transaction %s %s\n", tx.GetHash(), tx.TransactionType.String()) switch tx.TransactionType { @@ -79,25 +123,233 @@ func (chain *Blockchain) process_transaction(tx transaction.Transaction, balance return 0 // registration doesn't give any fees . why & how ? - case transaction.NORMAL: - for i := range tx.Statement.Publickeylist_compressed { - if balance_serialized, err := balance_tree.Get(tx.Statement.Publickeylist_compressed[i][:]); err == nil { + case transaction.BURN_TX, transaction.NORMAL, transaction.SC_TX: // burned amount is not added anywhere and thus lost forever - balance := new(crypto.ElGamal).Deserialize(balance_serialized) - echanges := crypto.ConstructElGamal(tx.Statement.C[i], tx.Statement.D) - - balance = balance.Add(echanges) // homomorphic addition of changes - balance_tree.Put(tx.Statement.Publickeylist_compressed[i][:], balance.Serialize()) // reserialize and store + for t := range tx.Payloads { + var tree *graviton.Tree + if tx.Payloads[t].SCID.IsZero() { + tree = balance_tree } else { - panic(err) // if balance could not be obtained panic ( we can never reach here, otherwise how tx got verified) + tree = changed[tx.Payloads[t].SCID] } + for i := 0; i < int(tx.Payloads[t].Statement.RingSize); i++ { + key_pointer := tx.Payloads[t].Statement.Publickeylist_pointers[i*int(tx.Payloads[t].Statement.Bytes_per_publickey) : (i+1)*int(tx.Payloads[t].Statement.Bytes_per_publickey)] + if _, key_compressed, balance_serialized, err := tree.GetKeyValueFromHash(key_pointer); err == nil { + balance := new(crypto.ElGamal).Deserialize(balance_serialized) + echanges := crypto.ConstructElGamal(tx.Payloads[t].Statement.C[i], tx.Payloads[t].Statement.D) + + balance = balance.Add(echanges) // homomorphic addition of changes + tree.Put(key_compressed, balance.Serialize()) // reserialize and store + } else { + panic(err) // if balance could not be obtained panic ( we can never reach here, otherwise how tx got verified) + } + } } - return tx.Statement.Fees + + return tx.Fees() default: panic("unknown transaction, do not know how to process it") return 0 } - +} + +type Tree_Wrapper struct { + tree *graviton.Tree + entries map[string][]byte + leftover_balance uint64 + transfere []dvm.TransferExternal +} + +func (t *Tree_Wrapper) Get(key []byte) ([]byte, error) { + if value, ok := t.entries[string(key)]; ok { + return value, nil + } else { + return t.tree.Get(key) + } +} + +func (t *Tree_Wrapper) Put(key []byte, value []byte) error { + t.entries[string(key)] = append([]byte{}, value...) + return nil +} + +// does additional processing for SC +func (chain *Blockchain) process_transaction_sc(cache map[crypto.Hash]*graviton.Tree, ss *graviton.Snapshot, bl_height, bl_topoheight uint64, blid crypto.Hash, tx transaction.Transaction, balance_tree *graviton.Tree, sc_tree *graviton.Tree) (gas uint64, err error) { + + if len(tx.SCDATA) == 0 { + return tx.Fees(), nil + } + + success := false + w_balance_tree := &Tree_Wrapper{tree: balance_tree, entries: map[string][]byte{}} + w_sc_tree := &Tree_Wrapper{tree: sc_tree, entries: map[string][]byte{}} + + _ = w_balance_tree + + var sc_data_tree *graviton.Tree // SC data tree + var w_sc_data_tree *Tree_Wrapper + + txhash := tx.GetHash() + scid := txhash + + defer func() { + if success { // merge the trees + + } + }() + + if tx.SCDATA.Has(rpc.SCACTION, rpc.DataUint64) { // but only it is present + action_code := rpc.SC_ACTION(tx.SCDATA.Value(rpc.SCACTION, rpc.DataUint64).(uint64)) + + switch action_code { + case rpc.SC_INSTALL: // request to install an SC + if !tx.SCDATA.Has(rpc.SCCODE, rpc.DataString) { // but only it is present + break + } + sc_code := tx.SCDATA.Value(rpc.SCCODE, rpc.DataString).(string) + if sc_code == "" { // no code provided nothing to do + err = fmt.Errorf("no code provided") + break + } + + // check whether sc can be parsed + //var sc_parsed dvm.SmartContract + pos := "" + var sc dvm.SmartContract + + sc, pos, err = dvm.ParseSmartContract(sc_code) + if err != nil { + rlog.Warnf("error Parsing sc txid %s err %s pos %s\n", txhash, err, pos) + break + } + + meta := SC_META_DATA{Balance: tx.Value} + + if _, ok := sc.Functions["InitializePrivate"]; ok { + meta.Type = 1 + } + if sc_data_tree, err = ss.GetTree(string(scid[:])); err != nil { + break + } else { + w_sc_data_tree = &Tree_Wrapper{tree: sc_data_tree, entries: map[string][]byte{}} + } + + // install SC, should we check for sanity now, why or why not + w_sc_data_tree.Put(SC_Code_Key(scid), dvm.Variable{Type: dvm.String, Value: sc_code}.MarshalBinaryPanic()) + + w_sc_tree.Put(SC_Meta_Key(scid), meta.MarshalBinary()) + + // at this point we must trigger the initialize call in the DVM + //fmt.Printf("We must call the SC initialize function\n") + + if meta.Type == 1 { // if its a a private SC + gas, err = chain.execute_sc_function(w_sc_tree, w_sc_data_tree, scid, bl_height, bl_topoheight, blid, tx, "InitializePrivate", 1) + } else { + gas, err = chain.execute_sc_function(w_sc_tree, w_sc_data_tree, scid, bl_height, bl_topoheight, blid, tx, "Initialize", 1) + } + + case rpc.SC_CALL: // trigger a CALL + if !tx.SCDATA.Has(rpc.SCID, rpc.DataHash) { // but only it is present + err = fmt.Errorf("no scid provided") + break + } + if !tx.SCDATA.Has("entrypoint", rpc.DataString) { // but only it is present + err = fmt.Errorf("no entrypoint provided") + break + } + + scid = tx.SCDATA.Value(rpc.SCID, rpc.DataHash).(crypto.Hash) + + if _, err = w_sc_tree.Get(SC_Meta_Key(scid)); err != nil { + err = fmt.Errorf("scid %s not installed", scid) + return + } + + if sc_data_tree, err = ss.GetTree(string(scid[:])); err != nil { + + return + } else { + w_sc_data_tree = &Tree_Wrapper{tree: sc_data_tree, entries: map[string][]byte{}} + } + + entrypoint := tx.SCDATA.Value("entrypoint", rpc.DataString).(string) + //fmt.Printf("We must call the SC %s function\n", entrypoint) + + gas, err = chain.execute_sc_function(w_sc_tree, w_sc_data_tree, scid, bl_height, bl_topoheight, blid, tx, entrypoint, 1) + + default: // unknown what to do + err = fmt.Errorf("unknown action what to do", scid) + return + } + } + + if err == nil { // we must commit the changes + var data_tree *graviton.Tree + var ok bool + if data_tree, ok = cache[scid]; !ok { + data_tree = w_sc_data_tree.tree + cache[scid] = w_sc_data_tree.tree + } + + // commit entire data to tree + for k, v := range w_sc_data_tree.entries { + //fmt.Printf("persisting %x %x\n", k, v) + if err = data_tree.Put([]byte(k), v); err != nil { + return + } + } + + for k, v := range w_sc_tree.entries { // these entries are only partial + if err = sc_tree.Put([]byte(k), v); err != nil { + return + } + } + + // at this point, settle the balances, how ?? + var meta_bytes []byte + meta_bytes, err = w_sc_tree.Get(SC_Meta_Key(scid)) + if err != nil { + return + } + + var meta SC_META_DATA // the meta contains the link to the SC bytes + if err = meta.UnmarshalBinary(meta_bytes); err != nil { + return + } + meta.Balance = w_sc_data_tree.leftover_balance + + //fmt.Printf("SC %s balance %d\n", scid, w_sc_data_tree.leftover_balance) + sc_tree.Put(SC_Meta_Key(scid), meta.MarshalBinary()) + + for _, transfer := range w_sc_data_tree.transfere { // give devs reward + var balance_serialized []byte + addr_bytes := []byte(transfer.Address) + balance_serialized, err = balance_tree.Get(addr_bytes) + if err != nil { + return + } + balance := new(crypto.ElGamal).Deserialize(balance_serialized) + balance = balance.Plus(new(big.Int).SetUint64(transfer.Amount)) // add devs reward to devs balance homomorphically + balance_tree.Put(addr_bytes, balance.Serialize()) // reserialize and store + + //fmt.Printf("%s paid back %d\n", scid, transfer.Amount) + + } + + /* + c := data_tree.Cursor() + for k, v, err := c.First(); err == nil; k, v, err = c.Next() { + fmt.Printf("key=%s (%x), value=%s\n", k, k, v) + } + fmt.Printf("cursor complete\n") + */ + + //h, err := data_tree.Hash() + //fmt.Printf("%s successfully executed sc_call data_tree hash %x %s\n", scid, h, err) + + } + + return tx.Fees(), nil } diff --git a/blockchain/transaction_verify.go b/blockchain/transaction_verify.go index 53dd1be..a3e0eb7 100644 --- a/blockchain/transaction_verify.go +++ b/blockchain/transaction_verify.go @@ -16,7 +16,7 @@ package blockchain -//import "fmt" +import "fmt" import "time" /*import "bytes" @@ -33,11 +33,11 @@ import "github.com/deroproject/graviton" //import "github.com/romana/rlog" import log "github.com/sirupsen/logrus" -//import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/config" import "github.com/deroproject/derohe/block" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/transaction" -import "github.com/deroproject/derohe/crypto/bn256" +import "github.com/deroproject/derohe/cryptography/bn256" //import "github.com/deroproject/derosuite/emission" @@ -71,10 +71,10 @@ func clean_up_valid_cache() { /* Coinbase transactions need to verify registration * */ -func (chain *Blockchain) Verify_Transaction_Coinbase(cbl *block.Complete_Block, minertx *transaction.Transaction) (result bool) { +func (chain *Blockchain) Verify_Transaction_Coinbase(cbl *block.Complete_Block, minertx *transaction.Transaction) (err error) { if !minertx.IsCoinbase() { // transaction is not coinbase, return failed - return false + return fmt.Errorf("tx is not coinbase") } // make sure miner address is registered @@ -82,7 +82,7 @@ func (chain *Blockchain) Verify_Transaction_Coinbase(cbl *block.Complete_Block, _, topos := chain.Store.Topo_store.binarySearchHeight(int64(cbl.Bl.Height - 1)) // load all db versions one by one and check whether the root hash matches the one mentioned in the tx if len(topos) < 1 { - return false + return fmt.Errorf("could not find previous height blocks") } var balance_tree *graviton.Tree @@ -90,29 +90,26 @@ func (chain *Blockchain) Verify_Transaction_Coinbase(cbl *block.Complete_Block, toporecord, err := chain.Store.Topo_store.Read(topos[i]) if err != nil { - log.Infof("Skipping block at height %d due to error while obtaining toporecord %s\n", i, err) - continue + return fmt.Errorf("could not read block at height %d due to error while obtaining toporecord topos %+v processing %d err:%s\n", cbl.Bl.Height-1, topos, i, err) } ss, err := chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version) if err != nil { - panic(err) + return err } - if balance_tree, err = ss.GetTree(BALANCE_TREE); err != nil { - panic(err) + if balance_tree, err = ss.GetTree(config.BALANCE_TREE); err != nil { + return err } if _, err := balance_tree.Get(minertx.MinerAddress[:]); err != nil { - //logger.Infof("balance not obtained err %s\n",err) + return fmt.Errorf("balance not obtained err %s\n", err) //return false - } else { - return true } } - return false + return nil // success comes last } // all non miner tx must be non-coinbase tx @@ -122,156 +119,223 @@ func (chain *Blockchain) Verify_Transaction_Coinbase(cbl *block.Complete_Block, // if the transaction has passed the check it can be added to mempool, relayed or added to blockchain // the transaction has already been deserialized thats it // It also expands the transactions, using the repective state trie -func (chain *Blockchain) Verify_Transaction_NonCoinbase(hf_version int64, tx *transaction.Transaction) (result bool) { +func (chain *Blockchain) Verify_Transaction_NonCoinbase(hf_version int64, tx *transaction.Transaction) (err error) { var tx_hash crypto.Hash defer func() { // safety so if anything wrong happens, verification fails if r := recover(); r != nil { logger.WithFields(log.Fields{"txid": tx_hash}).Warnf("Recovered while Verifying transaction, failed verification, Stack trace below") logger.Warnf("Stack trace \n%s", debug.Stack()) - result = false + err = fmt.Errorf("Stack Trace %s", debug.Stack()) } }() if tx.Version != 1 { - return false + return fmt.Errorf("TX should be version 1") } tx_hash = tx.GetHash() if tx.TransactionType == transaction.REGISTRATION { if _, ok := transaction_valid_cache.Load(tx_hash); ok { - return true //logger.Infof("Found in cache %s ",tx_hash) + return nil //logger.Infof("Found in cache %s ",tx_hash) } else { //logger.Infof("TX not found in cache %s len %d ",tx_hash, len(tmp_buffer)) } if tx.IsRegistrationValid() { transaction_valid_cache.Store(tx_hash, time.Now()) // signature got verified, cache it - return true + return nil } - return false + return fmt.Errorf("Registration has invalid signature") } - // currently we allow 2 types of transaction - if !(tx.TransactionType == transaction.NORMAL || tx.TransactionType == transaction.REGISTRATION) { - return false + // currently we allow following types of transaction + if !(tx.TransactionType == transaction.NORMAL || tx.TransactionType == transaction.SC_TX || tx.TransactionType == transaction.BURN_TX) { + return fmt.Errorf("Unknown transaction type") } - // check sanity - if tx.Statement.RingSize != uint64(len(tx.Statement.Publickeylist_compressed)) || tx.Statement.RingSize != uint64(len(tx.Statement.Publickeylist)) { - return false + if tx.TransactionType == transaction.BURN_TX { + if tx.Value == 0 { + return fmt.Errorf("Burn Value cannot be zero") + } } // avoid some bugs lurking elsewhere if tx.Height != uint64(int64(tx.Height)) { - return false + return fmt.Errorf("invalid tx height") } - if tx.Statement.RingSize < 2 { // ring size minimum 4 - return false - } - - if tx.Statement.RingSize > 128 { // ring size current limited to 128 - return false - } - - if !crypto.IsPowerOf2(len(tx.Statement.Publickeylist_compressed)) { - return false - } - - // check duplicate ring members within the tx - { - key_map := map[string]bool{} - for i := range tx.Statement.Publickeylist_compressed { - key_map[string(tx.Statement.Publickeylist_compressed[i][:])] = true - } - if len(key_map) != len(tx.Statement.Publickeylist_compressed) { - return false + for t := range tx.Payloads { + // check sanity + if tx.Payloads[t].Statement.RingSize != uint64(len(tx.Payloads[t].Statement.Publickeylist_pointers)/int(tx.Payloads[t].Statement.Bytes_per_publickey)) { + return fmt.Errorf("corrupted key pointers ringsize") } + if tx.Payloads[t].Statement.RingSize < 2 { // ring size minimum 4 + return fmt.Errorf("RingSize cannot be less than 2") + } + + if tx.Payloads[t].Statement.RingSize > 128 { // ring size current limited to 128 + return fmt.Errorf("RingSize cannot be more than 128") + } + + if !crypto.IsPowerOf2(len(tx.Payloads[t].Statement.Publickeylist_pointers) / int(tx.Payloads[t].Statement.Bytes_per_publickey)) { + return fmt.Errorf("corrupted key pointers") + } + + // check duplicate ring members within the tx + { + key_map := map[string]bool{} + for i := 0; i < int(tx.Payloads[t].Statement.RingSize); i++ { + key_map[string(tx.Payloads[t].Statement.Publickeylist_pointers[i*int(tx.Payloads[t].Statement.Bytes_per_publickey):(i+1)*int(tx.Payloads[t].Statement.Bytes_per_publickey)])] = true + } + if len(key_map) != int(tx.Payloads[t].Statement.RingSize) { + return fmt.Errorf("Duplicated ring members") + } + + } + tx.Payloads[t].Statement.CLn = tx.Payloads[t].Statement.CLn[:0] + tx.Payloads[t].Statement.CRn = tx.Payloads[t].Statement.CRn[:0] + } + + match_topo := int64(1) + + // transaction needs to be expanded. this expansion needs balance state + _, topos := chain.Store.Topo_store.binarySearchHeight(int64(tx.Height)) + + // load all db versions one by one and check whether the root hash matches the one mentioned in the tx + if len(topos) < 1 { + return fmt.Errorf("TX could NOT be expanded") + } + + for i := range topos { + hash, err := chain.Load_Merkle_Hash(topos[i]) + if err != nil { + continue + } + + if hash == tx.Payloads[0].Statement.Roothash { + match_topo = topos[i] + break // we have found the balance tree with which it was built now lets verify + } + + } + + if match_topo < 0 { + return fmt.Errorf("mentioned balance tree not found, cannot verify TX") } var balance_tree *graviton.Tree + toporecord, err := chain.Store.Topo_store.Read(match_topo) + if err != nil { + return err + } - tx.Statement.CLn = tx.Statement.CLn[:0] - tx.Statement.CRn = tx.Statement.CRn[:0] + ss, err := chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version) + if err != nil { + return err + } - // this expansion needs balance state - if len(tx.Statement.CLn) == 0 { // transaction needs to be expanded - _, topos := chain.Store.Topo_store.binarySearchHeight(int64(tx.Height)) - - // load all db versions one by one and check whether the root hash matches the one mentioned in the tx - if len(topos) < 1 { - panic("TX could NOT be expanded") - } - - for i := range topos { - toporecord, err := chain.Store.Topo_store.Read(topos[i]) - if err != nil { - //log.Infof("Skipping block at height %d due to error while obtaining toporecord %s\n", i, err) - continue - } - - ss, err := chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version) - if err != nil { - panic(err) - } - - if balance_tree, err = ss.GetTree(BALANCE_TREE); err != nil { - panic(err) - } - - if hash, err := balance_tree.Hash(); err != nil { - panic(err) - } else { - //logger.Infof("dTX balance tree hash from tx %x treehash from blockchain %x", tx.Statement.Roothash, hash) - - if hash == tx.Statement.Roothash { - break // we have found the balance tree with which it was built now lets verify - } - } - balance_tree = nil - } + if balance_tree, err = ss.GetTree(config.BALANCE_TREE); err != nil { + return err } if balance_tree == nil { - panic("mentioned balance tree not found, cannot verify TX") + return fmt.Errorf("mentioned balance tree not found, cannot verify TX") } if _, ok := transaction_valid_cache.Load(tx_hash); ok { - return true //logger.Infof("Found in cache %s ",tx_hash) + return nil //logger.Infof("Found in cache %s ",tx_hash) } else { //logger.Infof("TX not found in cache %s len %d ",tx_hash, len(tmp_buffer)) } //logger.Infof("dTX state tree has been found") - // now lets calculate CLn and CRn - for i := range tx.Statement.Publickeylist_compressed { - balance_serialized, err := balance_tree.Get(tx.Statement.Publickeylist_compressed[i][:]) - if err != nil { - //logger.Infof("balance not obtained err %s\n",err) - return false + trees := map[crypto.Hash]*graviton.Tree{} + + var zerohash crypto.Hash + trees[zerohash] = balance_tree // initialize main tree by default + + for t := range tx.Payloads { + tx.Payloads[t].Statement.Publickeylist_compressed = tx.Payloads[t].Statement.Publickeylist_compressed[:0] + tx.Payloads[t].Statement.Publickeylist = tx.Payloads[t].Statement.Publickeylist[:0] + + var tree *graviton.Tree + + if _, ok := trees[tx.Payloads[t].SCID]; ok { + tree = trees[tx.Payloads[t].SCID] + } else { + + // fmt.Printf("SCID loading %s tree\n", tx.Payloads[t].SCID) + tree, _ = ss.GetTree(string(tx.Payloads[t].SCID[:])) + trees[tx.Payloads[t].SCID] = tree } - var ll, rr bn256.G1 - ebalance := new(crypto.ElGamal).Deserialize(balance_serialized) + // now lets calculate CLn and CRn + for i := 0; i < int(tx.Payloads[t].Statement.RingSize); i++ { + key_pointer := tx.Payloads[t].Statement.Publickeylist_pointers[i*int(tx.Payloads[t].Statement.Bytes_per_publickey) : (i+1)*int(tx.Payloads[t].Statement.Bytes_per_publickey)] + _, key_compressed, balance_serialized, err := tree.GetKeyValueFromHash(key_pointer) + if err != nil { + return fmt.Errorf("balance not obtained err %s\n", err) + } - ll.Add(ebalance.Left, tx.Statement.C[i]) - tx.Statement.CLn = append(tx.Statement.CLn, &ll) - rr.Add(ebalance.Right, tx.Statement.D) - tx.Statement.CRn = append(tx.Statement.CRn, &rr) + // decode public key and expand + { + var p bn256.G1 + var pcopy [33]byte + copy(pcopy[:], key_compressed) + if err = p.DecodeCompressed(key_compressed[:]); err != nil { + return fmt.Errorf("key %d could not be decompressed", i) + } + tx.Payloads[t].Statement.Publickeylist_compressed = append(tx.Payloads[t].Statement.Publickeylist_compressed, pcopy) + tx.Payloads[t].Statement.Publickeylist = append(tx.Payloads[t].Statement.Publickeylist, &p) + } + + var ll, rr bn256.G1 + ebalance := new(crypto.ElGamal).Deserialize(balance_serialized) + + ll.Add(ebalance.Left, tx.Payloads[t].Statement.C[i]) + tx.Payloads[t].Statement.CLn = append(tx.Payloads[t].Statement.CLn, &ll) + rr.Add(ebalance.Right, tx.Payloads[t].Statement.D) + tx.Payloads[t].Statement.CRn = append(tx.Payloads[t].Statement.CRn, &rr) + + // prepare for another sub transaction + echanges := crypto.ConstructElGamal(tx.Payloads[t].Statement.C[i], tx.Payloads[t].Statement.D) + ebalance = new(crypto.ElGamal).Deserialize(balance_serialized).Add(echanges) // homomorphic addition of changes + tree.Put(key_compressed, ebalance.Serialize()) // reserialize and store temporarily, tree will be discarded after verification + + } } - if tx.Proof.Verify(&tx.Statement, tx.GetHash()) { - //logger.Infof("dTX verified with proof successfuly") + // at this point has been completely expanded, verify the tx statement + for t := range tx.Payloads { + if !tx.Payloads[t].Proof.Verify(&tx.Payloads[t].Statement, tx.GetHash(), tx.Payloads[t].BurnValue) { + + fmt.Printf("Statement %+v\n", tx.Payloads[t].Statement) + fmt.Printf("Proof %+v\n", tx.Payloads[t].Proof) + + return fmt.Errorf("transaction statement %d verification failed", t) + } + } + + // these transactions are done + if tx.TransactionType == transaction.NORMAL || tx.TransactionType == transaction.BURN_TX { transaction_valid_cache.Store(tx_hash, time.Now()) // signature got verified, cache it - return true + return nil } - logger.Infof("transaction verification failed\n") - return false + // we reach here if tx proofs are valid + if tx.TransactionType != transaction.SC_TX { + return fmt.Errorf("non sc transaction should never reach here") + } + + if !tx.IsRegistrationValid() { + return fmt.Errorf("SC has invalid signature") + } + + return nil /* var tx_hash crypto.Hash @@ -501,23 +565,5 @@ func (chain *Blockchain) Verify_Transaction_NonCoinbase(hf_version int64, tx *tr //logger.WithFields(log.Fields{"txid": tx_hash}).Debugf("TX successfully verified") */ - return true -} - -// double spend check is separate from the core checks ( due to softforks ) -func (chain *Blockchain) Verify_Transaction_NonCoinbase_DoubleSpend_Check(tx *transaction.Transaction) (result bool) { - return true } - -// verify all non coinbase tx, single threaded for double spending on current active chain -func (chain *Blockchain) Verify_Block_DoubleSpending(cbl *block.Complete_Block) (result bool) { - /* - for i := 0; i < len(cbl.Txs); i++ { - if !chain.Verify_Transaction_NonCoinbase_DoubleSpend_Check(dbtx, cbl.Txs[i]) { - return false - } - } - */ - return true -} diff --git a/build_all.sh b/build_all.sh index b3b4e12..c281a6b 100644 --- a/build_all.sh +++ b/build_all.sh @@ -1,16 +1,14 @@ #!/usr/bin/env bash - - CURDIR=`/bin/pwd` BASEDIR=$(dirname $0) ABSPATH=$(readlink -f $0) ABSDIR=$(dirname $ABSPATH) -cd $ABSDIR/../../../../ -GOPATH=`pwd` -version=`cat src/github.com/deroproject/derohe/config/version.go | grep -i version |cut -d\" -f 2` +unset GOPATH + +version=`cat ./config/version.go | grep -i version |cut -d\" -f 2` cd $CURDIR @@ -18,6 +16,7 @@ bash $ABSDIR/build_package.sh "github.com/deroproject/derohe/cmd/derod" bash $ABSDIR/build_package.sh "github.com/deroproject/derohe/cmd/explorer" bash $ABSDIR/build_package.sh "github.com/deroproject/derohe/cmd/dero-wallet-cli" bash $ABSDIR/build_package.sh "github.com/deroproject/derohe/cmd/dero-miner" +bash $ABSDIR/build_package.sh "github.com/deroproject/derohe/cmd/rpc_examples/pong_server" for d in build/*; do cp Start.md "$d"; done diff --git a/cmd/dero-miner/difficulty.go b/cmd/dero-miner/difficulty.go index b494678..97f363d 100644 --- a/cmd/dero-miner/difficulty.go +++ b/cmd/dero-miner/difficulty.go @@ -18,7 +18,7 @@ package main // ripoff from blockchain folder import "math/big" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" var ( // bigZero is 0 represented as a big.Int. It is defined here to avoid diff --git a/cmd/dero-miner/miner.go b/cmd/dero-miner/miner.go index 607973c..ee91b1d 100644 --- a/cmd/dero-miner/miner.go +++ b/cmd/dero-miner/miner.go @@ -37,9 +37,9 @@ import "strconv" import "github.com/deroproject/derohe/config" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/astrobwt" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/rpc" import log "github.com/sirupsen/logrus" import "github.com/ybbus/jsonrpc" @@ -48,10 +48,10 @@ import "github.com/romana/rlog" import "github.com/chzyer/readline" import "github.com/docopt/docopt-go" -var rpcClient *jsonrpc.RPCClient +var rpcClient jsonrpc.RPCClient var netClient *http.Client var mutex sync.RWMutex -var job structures.GetBlockTemplate_Result +var job rpc.GetBlockTemplate_Result var maxdelay int = 10000 var threads int var iterations int = 100 @@ -423,7 +423,7 @@ func increase_delay() { func getwork() { // create client - rpcClient = jsonrpc.NewRPCClient(daemon_rpc_address + "/json_rpc") + rpcClient = jsonrpc.NewClient(daemon_rpc_address + "/json_rpc") var netTransport = &http.Transport{ Dial: (&net.Dialer{ @@ -450,9 +450,9 @@ func getwork() { for { - response, err = rpcClient.CallNamed("getblocktemplate", map[string]interface{}{"wallet_address": fmt.Sprintf("%s", wallet_address), "reserve_size": 10}) + response, err = rpcClient.Call("getblocktemplate", map[string]interface{}{"wallet_address": fmt.Sprintf("%s", wallet_address), "reserve_size": 10}) if err == nil { - var block_template structures.GetBlockTemplate_Result + var block_template rpc.GetBlockTemplate_Result err = response.GetObject(&block_template) if err == nil { mutex.Lock() diff --git a/cmd/dero-wallet-cli/easymenu_post_open.go b/cmd/dero-wallet-cli/easymenu_post_open.go index 82a5db0..bf65bb2 100644 --- a/cmd/dero-wallet-cli/easymenu_post_open.go +++ b/cmd/dero-wallet-cli/easymenu_post_open.go @@ -17,17 +17,22 @@ package main import "io" -import "os" + +import "time" import "fmt" -import "io/ioutil" + +//import "io/ioutil" import "strings" -import "path/filepath" -import "encoding/hex" + +//import "path/filepath" +//import "encoding/hex" import "github.com/chzyer/readline" +import "github.com/deroproject/derohe/rpc" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/address" + +//import "github.com/deroproject/derohe/address" //import "github.com/deroproject/derohe/walletapi" import "github.com/deroproject/derohe/transaction" @@ -42,12 +47,12 @@ func display_easymenu_post_open_command(l *readline.Instance) { io.WriteString(w, "\t\033[1m3\033[0m\tDisplay Keys (hex)\n") - if !is_registered(wallet) { + if !wallet.IsRegistered() { io.WriteString(w, "\t\033[1m4\033[0m\tAccount registration to blockchain (registration has no fee requirement and is precondition to use the account)\n") io.WriteString(w, "\n") io.WriteString(w, "\n") } else { // hide some commands, if view only wallet - io.WriteString(w, "\n") + io.WriteString(w, "\t\033[1m4\033[0m\tDisplay wallet pool\n") io.WriteString(w, "\t\033[1m5\033[0m\tTransfer (send DERO) To Another Wallet\n") //io.WriteString(w, "\t\033[1m6\033[0m\tCreate Transaction in offline mode\n") io.WriteString(w, "\n") @@ -55,7 +60,7 @@ func display_easymenu_post_open_command(l *readline.Instance) { io.WriteString(w, "\t\033[1m7\033[0m\tChange wallet password\n") io.WriteString(w, "\t\033[1m8\033[0m\tClose Wallet\n") - if is_registered(wallet) { + if wallet.IsRegistered() { io.WriteString(w, "\t\033[1m12\033[0m\tTransfer all balance (send DERO) To Another Wallet\n") io.WriteString(w, "\t\033[1m13\033[0m\tShow transaction history\n") io.WriteString(w, "\t\033[1m14\033[0m\tRescan transaction history\n") @@ -90,7 +95,7 @@ func handle_easymenu_post_open_command(l *readline.Instance, line string) (proce case "1": fmt.Fprintf(l.Stderr(), "Wallet address : "+color_green+"%s"+color_white+"\n", wallet.GetAddress()) - if !is_registered(wallet) { + if !wallet.IsRegistered() { reg_tx := wallet.GetRegistrationTX() fmt.Fprintf(l.Stderr(), "Registration TX : "+color_green+"%x"+color_white+"\n", reg_tx.Serialize()) } @@ -118,28 +123,34 @@ func handle_easymenu_post_open_command(l *readline.Instance, line string) (proce case "4": // Registration - if !ValidateCurrentPassword(l, wallet) { - globals.Logger.Warnf("Invalid password") - PressAnyKey(l, wallet) - break - } + if !wallet.IsRegistered() { - //if valid_registration_or_display_error(l, wallet) { - // globals.Logger.Warnf("This wallet address is already registered.") - // break - //} - fmt.Fprintf(l.Stderr(), "Wallet address : "+color_green+"%s"+color_white+" is going to be registered.This is a pre-condition for using the online chain.It will take few seconds to register/", wallet.GetAddress()) - - reg_tx := wallet.GetRegistrationTX() + fmt.Fprintf(l.Stderr(), "Wallet address : "+color_green+"%s"+color_white+" is going to be registered.This is a pre-condition for using the online chain.It will take few seconds to register.\n", wallet.GetAddress()) + reg_tx := wallet.GetRegistrationTX() // at this point we must send the registration transaction - fmt.Fprintf(l.Stderr(), "Wallet address : "+color_green+"%s"+color_white+" is going to be registered.Pls wait till the account is registered.", wallet.GetAddress()) + fmt.Fprintf(l.Stderr(), "Wallet address : "+color_green+"%s"+color_white+" is going to be registered.Pls wait till the account is registered.\n", wallet.GetAddress()) - wallet.SendTransaction(reg_tx) + fmt.Printf("sending registration tx err %s\n", wallet.SendTransaction(reg_tx)) + } else { + pool := wallet.GetPool() + fmt.Fprintf(l.Stderr(), "Wallet pool has %d pending/in-progress transactions.\n", len(pool)) + fmt.Fprintf(l.Stderr(), "%5s %9s %8s %64s %s %s\n", "No.", "Amount", "TH", "TXID", "Destination", "Status") + for i := range pool { + var txid, status string + if len(pool[i].Tries) > 0 { + try := pool[i].Tries[len(pool[i].Tries)-1] + txid = try.TXID.String() + status = try.Status + } else { + status = "Will Dispatch in next block" + } + fmt.Fprintf(l.Stderr(), "%5d %9s %8d %64s %s %s\n", i, "-"+globals.FormatMoney(pool[i].Amount()), pool[i].Trigger_Height, txid, "Not implemented", status) + } - + } case "6": offline_tx = true @@ -160,34 +171,129 @@ func handle_easymenu_post_open_command(l *readline.Instance, line string) (proce break } - amount_str := read_line_with_prompt(l, fmt.Sprintf("Enter amount to transfer in DERO (max TODO .00004 hard coded): ")) + var amount_to_transfer uint64 - if amount_str == "" { - amount_str = ".00009" + var arguments = rpc.Arguments{ + // { rpc.RPC_DESTINATION_PORT, rpc.DataUint64,uint64(0x1234567812345678)}, + // { rpc.RPC_VALUE_TRANSFER, rpc.DataUint64,uint64(12345)}, + // { rpc.RPC_EXPIRY , rpc.DataTime, time.Now().Add(time.Hour).UTC()}, + // { rpc.RPC_COMMENT , rpc.DataString, "Purchase XYZ"}, } - amount_to_transfer, err := globals.ParseAmount(amount_str) - if err != nil { - globals.Logger.Warnf("Err :%s", err) - break // invalid amount provided, bail out + if a.IsIntegratedAddress() { // read everything from the address + + if a.Arguments.Validate_Arguments() != nil { + globals.Logger.Warnf("Integrated Address arguments could not be validated, err: %s", err) + break + } + + if !a.Arguments.Has(rpc.RPC_DESTINATION_PORT, rpc.DataUint64) { // but only it is present + globals.Logger.Warnf("Integrated Address does not contain destination port.") + break + } + + arguments = append(arguments, rpc.Argument{rpc.RPC_DESTINATION_PORT, rpc.DataUint64, a.Arguments.Value(rpc.RPC_DESTINATION_PORT, rpc.DataUint64).(uint64)}) + // arguments = append(arguments, rpc.Argument{"Comment", rpc.DataString, "holygrail of all data is now working if you can see this"}) + + if a.Arguments.Has(rpc.RPC_EXPIRY, rpc.DataTime) { // but only it is present + + if a.Arguments.Value(rpc.RPC_EXPIRY, rpc.DataTime).(time.Time).Before(time.Now().UTC()) { + globals.Logger.Warnf("This address has expired on %s", a.Arguments.Value(rpc.RPC_EXPIRY, rpc.DataTime)) + break + } else { + globals.Logger.Infof("This address will expire on %s", a.Arguments.Value(rpc.RPC_EXPIRY, rpc.DataTime)) + } + } + + globals.Logger.Infof("Destination port is integreted in address ID:%016x", a.Arguments.Value(rpc.RPC_DESTINATION_PORT, rpc.DataUint64).(uint64)) + + if a.Arguments.Has(rpc.RPC_COMMENT, rpc.DataString) { // but only it is present + globals.Logger.Infof("Integrated Message:%s", a.Arguments.Value(rpc.RPC_COMMENT, rpc.DataString)) + } } - var payment_id []byte - _ = payment_id - // if user provided an integrated address donot ask him payment id - if a.IsIntegratedAddress() { - globals.Logger.Infof("Payment ID is integreted in address ID:%x", a.PaymentID) + // arguments have been already validated + for _, arg := range a.Arguments { + if !(arg.Name == rpc.RPC_COMMENT || arg.Name == rpc.RPC_EXPIRY || arg.Name == rpc.RPC_DESTINATION_PORT || arg.Name == rpc.RPC_SOURCE_PORT || arg.Name == rpc.RPC_VALUE_TRANSFER) { + switch arg.DataType { + case rpc.DataString: + if v, err := ReadString(l, arg.Name, arg.Value.(string)); err == nil { + arguments = append(arguments, rpc.Argument{arg.Name, arg.DataType, v}) + } else { + globals.Logger.Warnf("%s could not be parsed (type %s),", arg.Name, arg.DataType) + return + } + case rpc.DataInt64: + if v, err := ReadInt64(l, arg.Name, arg.Value.(int64)); err == nil { + arguments = append(arguments, rpc.Argument{arg.Name, arg.DataType, v}) + } else { + globals.Logger.Warnf("%s could not be parsed (type %s),", arg.Name, arg.DataType) + return + } + case rpc.DataUint64: + if v, err := ReadUint64(l, arg.Name, arg.Value.(uint64)); err == nil { + arguments = append(arguments, rpc.Argument{arg.Name, arg.DataType, v}) + } else { + globals.Logger.Warnf("%s could not be parsed (type %s),", arg.Name, arg.DataType) + return + } + case rpc.DataFloat64: + if v, err := ReadFloat64(l, arg.Name, arg.Value.(float64)); err == nil { + arguments = append(arguments, rpc.Argument{arg.Name, arg.DataType, v}) + } else { + globals.Logger.Warnf("%s could not be parsed (type %s),", arg.Name, arg.DataType) + return + } + case rpc.DataTime: + globals.Logger.Warnf("time argument is currently not supported.") + break + + } + } + } + + if a.Arguments.Has(rpc.RPC_VALUE_TRANSFER, rpc.DataUint64) { // but only it is present + globals.Logger.Infof("Transaction Value: %s", globals.FormatMoney(a.Arguments.Value(rpc.RPC_VALUE_TRANSFER, rpc.DataUint64).(uint64))) + amount_to_transfer = a.Arguments.Value(rpc.RPC_VALUE_TRANSFER, rpc.DataUint64).(uint64) + } else { + + amount_str := read_line_with_prompt(l, fmt.Sprintf("Enter amount to transfer in DERO (max TODO): ")) + + if amount_str == "" { + amount_str = ".00009" + } + amount_to_transfer, err = globals.ParseAmount(amount_str) + if err != nil { + globals.Logger.Warnf("Err :%s", err) + break // invalid amount provided, bail out + } + } + + // if no arguments, use space by embedding a small comment + if len(arguments) == 0 { // allow user to enter Comment + if v, err := ReadString(l, "Comment", ""); err == nil { + arguments = append(arguments, rpc.Argument{"Comment", rpc.DataString, v}) + } else { + globals.Logger.Warnf("%s could not be parsed (type %s),", "Comment", rpc.DataString) + return + } + } + + if _, err := arguments.CheckPack(transaction.PAYLOAD0_LIMIT); err != nil { + globals.Logger.Warnf("Arguments packing err: %s,", err) + return } if ConfirmYesNoDefaultNo(l, "Confirm Transaction (y/N)") { - addr_list := []address.Address{*a} - amount_list := []uint64{amount_to_transfer} // transfer 50 dero, 2 dero - fees_per_kb := uint64(0) // fees must be calculated by walletapi - tx, err := wallet.Transfer(addr_list, amount_list, 0, hex.EncodeToString(payment_id), fees_per_kb, 0, false) + + //src_port := uint64(0xffffffffffffffff) + + _, err := wallet.PoolTransfer([]rpc.Transfer{rpc.Transfer{Amount: amount_to_transfer, Destination: a.String(), Payload_RPC: arguments}}, rpc.Arguments{}) // empty SCDATA + if err != nil { globals.Logger.Warnf("Error while building Transaction err %s\n", err) break } - build_relay_transaction(l, tx, err, offline_tx, amount_list) + //fmt.Printf("queued tx err %s\n") } case "12": @@ -199,31 +305,34 @@ func handle_easymenu_post_open_command(l *readline.Instance, line string) (proce break } - // a , amount_to_transfer, err := collect_transfer_info(l,wallet) - fmt.Printf("dest address %s\n", "deroi1qxqqkmaz8nhv4q07w3cjyt84kmrqnuw4nprpqfl9xmmvtvwa7cdykxq5dph4ufnx5ndq4ltraf (14686f5e2666a4da) dero1qxqqkmaz8nhv4q07w3cjyt84kmrqnuw4nprpqfl9xmmvtvwa7cdykxqpfpaes") - a, err := ReadAddress(l) - if err != nil { - globals.Logger.Warnf("Err :%s", err) - break - } - // if user provided an integrated address donot ask him payment id - if a.IsIntegratedAddress() { - globals.Logger.Infof("Payment ID is integreted in address ID:%x", a.PaymentID) - } + globals.Logger.Warnf("Not supported err %s\n", err) - if ConfirmYesNoDefaultNo(l, "Confirm Transaction to send entire balance (y/N)") { - - addr_list := []address.Address{*a} - amount_list := []uint64{0} // transfer 50 dero, 2 dero - fees_per_kb := uint64(0) // fees must be calculated by walletapi - tx, err := wallet.Transfer(addr_list, amount_list, 0, "", fees_per_kb, 0, true) + /* + // a , amount_to_transfer, err := collect_transfer_info(l,wallet) + fmt.Printf("dest address %s\n", "deroi1qxqqkmaz8nhv4q07w3cjyt84kmrqnuw4nprpqfl9xmmvtvwa7cdykxq5dph4ufnx5ndq4ltraf (14686f5e2666a4da) dero1qxqqkmaz8nhv4q07w3cjyt84kmrqnuw4nprpqfl9xmmvtvwa7cdykxqpfpaes") + a, err := ReadAddress(l) if err != nil { - globals.Logger.Warnf("Error while building Transaction err %s\n", err) + globals.Logger.Warnf("Err :%s", err) break } + // if user provided an integrated address donot ask him payment id + if a.IsIntegratedAddress() { + globals.Logger.Infof("Payment ID is integreted in address ID:%x", a.PaymentID) + } - build_relay_transaction(l, tx, err, offline_tx, amount_list) - } + if ConfirmYesNoDefaultNo(l, "Confirm Transaction to send entire balance (y/N)") { + + addr_list := []address.Address{*a} + amount_list := []uint64{0} // transfer 50 dero, 2 dero + fees_per_kb := uint64(0) // fees must be calculated by walletapi + uid, err := wallet.PoolTransfer(addr_list, amount_list, fees_per_kb, 0, true) + _ = uid + if err != nil { + globals.Logger.Warnf("Error while building Transaction err %s\n", err) + break + } + } + */ //PressAnyKey(l, wallet) // wait for a key press @@ -275,62 +384,3 @@ func handle_easymenu_post_open_command(l *readline.Instance, line string) (proce } return } - -// handles the output after building tx, takes feedback, confirms or relays tx -func build_relay_transaction(l *readline.Instance, tx *transaction.Transaction, err error, offline_tx bool, amount_list []uint64) { - - if err != nil { - globals.Logger.Warnf("Error while building Transaction err %s\n", err) - return - } - amount := uint64(0) - for i := range amount_list { - amount += amount_list[i] - } - globals.Logger.Infof("Transfering total amount %s DERO", globals.FormatMoney(amount)) - - globals.Logger.Infof("fees %s DERO", globals.FormatMoney(tx.Statement.Fees)) - globals.Logger.Infof("TX Size %0.1f KiB", float32(len(tx.Serialize()))/1024.0) - - //if input_sum != (amount + change + tx.Fee()) { - // panic(fmt.Sprintf("Inputs %d != outputs ( %d + %d + %d )", input_sum, amount, change, tx.RctSignature.Get_TX_Fee())) - //} - - //if ConfirmYesNoDefaultNo(l, "Confirm Transaction (y/N)") { - if true { - - if offline_tx { // if its an offline tx, dump it to a file - cur_dir, err := os.Getwd() - if err != nil { - globals.Logger.Warnf("Cannot obtain current directory to save tx") - globals.Logger.Infof("Transaction discarded") - return - } - filename := filepath.Join(cur_dir, tx.GetHash().String()+".tx") - err = ioutil.WriteFile(filename, []byte(hex.EncodeToString(tx.Serialize())), 0600) - if err == nil { - if err == nil { - globals.Logger.Infof("Transaction saved successfully. txid = %s", tx.GetHash()) - globals.Logger.Infof("Saved to %s", filename) - } else { - globals.Logger.Warnf("Error saving tx to %s, err %s", filename, err) - } - } - - } else { - - err = wallet.SendTransaction(tx) // relay tx to daemon/network - if err == nil { - globals.Logger.Infof("Transaction sent successfully. txid = %s", tx.GetHash()) - } else { - globals.Logger.Warnf("Transaction sending failed txid = %s, err %s", tx.GetHash(), err) - } - - } - - PressAnyKey(l, wallet) // wait for a key press - } else { - globals.Logger.Infof("Transaction discarded") - } - -} diff --git a/cmd/dero-wallet-cli/easymenu_pre_open.go b/cmd/dero-wallet-cli/easymenu_pre_open.go index 9e9807f..659aea8 100644 --- a/cmd/dero-wallet-cli/easymenu_pre_open.go +++ b/cmd/dero-wallet-cli/easymenu_pre_open.go @@ -24,7 +24,7 @@ import "encoding/hex" import "github.com/chzyer/readline" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/config" import "github.com/deroproject/derohe/globals" import "github.com/deroproject/derohe/walletapi" @@ -61,6 +61,8 @@ func handle_easymenu_pre_open_command(l *readline.Instance, line string) { command = strings.ToLower(line_parts[0]) } + var wallett *walletapi.Wallet_Disk + //account_state := account_valid switch command { case "1": // open existing wallet @@ -68,7 +70,7 @@ func handle_easymenu_pre_open_command(l *readline.Instance, line string) { // ask user a password for i := 0; i < 3; i++ { - wallet, err = walletapi.Open_Encrypted_Wallet(filename, ReadPassword(l, filename)) + wallett, err = walletapi.Open_Encrypted_Wallet(filename, ReadPassword(l, filename)) if err != nil { globals.Logger.Warnf("Error occurred while opening wallet file %s. err %s", filename, err) wallet = nil @@ -77,7 +79,9 @@ func handle_easymenu_pre_open_command(l *readline.Instance, line string) { break } } - if wallet != nil { + if wallett != nil { + wallet = wallett + wallett = nil globals.Logger.Infof("Successfully opened wallet") common_processing(wallet) @@ -89,17 +93,20 @@ func handle_easymenu_pre_open_command(l *readline.Instance, line string) { password := ReadConfirmedPassword(l, "Enter password", "Confirm password") - wallet, err = walletapi.Create_Encrypted_Wallet_Random(filename, password) + wallett, err = walletapi.Create_Encrypted_Wallet_Random(filename, password) if err != nil { globals.Logger.Warnf("Error occured while creating new wallet, err: %s", err) wallet = nil break } - err = wallet.Set_Encrypted_Wallet_Password(password) + err = wallett.Set_Encrypted_Wallet_Password(password) if err != nil { globals.Logger.Warnf("Error changing password") } + wallet = wallett + wallett = nil + seed_language := choose_seed_language(l) wallet.SetSeedLanguage(seed_language) globals.Logger.Debugf("Seed Language %s", seed_language) @@ -114,11 +121,13 @@ func handle_easymenu_pre_open_command(l *readline.Instance, line string) { password := ReadConfirmedPassword(l, "Enter password", "Confirm password") electrum_words := read_line_with_prompt(l, "Enter seed (25 words) : ") - wallet, err = walletapi.Create_Encrypted_Wallet_From_Recovery_Words(filename, password, electrum_words) + wallett, err = walletapi.Create_Encrypted_Wallet_From_Recovery_Words(filename, password, electrum_words) if err != nil { globals.Logger.Warnf("Error while recovering wallet using seed err %s\n", err) break } + wallet = wallett + wallett = nil //globals.Logger.Debugf("Seed Language %s", account.SeedLanguage) globals.Logger.Infof("Successfully recovered wallet from seed") common_processing(wallet) @@ -136,12 +145,14 @@ func handle_easymenu_pre_open_command(l *readline.Instance, line string) { break } - wallet, err = walletapi.Create_Encrypted_Wallet(filename, password, new(crypto.BNRed).SetBytes(seed_raw)) + wallett, err = walletapi.Create_Encrypted_Wallet(filename, password, new(crypto.BNRed).SetBytes(seed_raw)) if err != nil { globals.Logger.Warnf("Error while recovering wallet using seed key err %s\n", err) break } globals.Logger.Infof("Successfully recovered wallet from hex seed") + wallet = wallett + wallett = nil seed_language := choose_seed_language(l) wallet.SetSeedLanguage(seed_language) globals.Logger.Debugf("Seed Language %s", seed_language) @@ -233,8 +244,10 @@ func common_processing(wallet *walletapi.Wallet_Disk) { globals.Logger.Warnf("Error starting rpc server err %s", err) } - } time.Sleep(time.Second) + // init_script_engine(wallet) // init script engine + // init_plugins_engine(wallet) // init script engine + } diff --git a/cmd/dero-wallet-cli/main.go b/cmd/dero-wallet-cli/main.go index b82e268..3a74b38 100644 --- a/cmd/dero-wallet-cli/main.go +++ b/cmd/dero-wallet-cli/main.go @@ -119,7 +119,7 @@ func main() { } // init the lookup table one, anyone importing walletapi should init this first, this will take around 1 sec on any recent system - walletapi.Initialize_LookupTable(1, 1<<20) + walletapi.Initialize_LookupTable(1, 1<<17) // We need to initialize readline first, so it changes stderr to ansi processor on windows l, err := readline.NewEx(&readline.Config{ @@ -407,11 +407,13 @@ func update_prompt(l *readline.Instance) { balance_string := "" //balance_unlocked, locked_balance := wallet.Get_Balance_Rescan()// wallet.Get_Balance() - balance_unlocked, locked_balance := wallet.Get_Balance() - balance_string = fmt.Sprintf(color_green+"%s "+color_white+"| "+color_yellow+"%s", globals.FormatMoney(balance_unlocked), globals.FormatMoney(locked_balance)) + balance_unlocked, _ := wallet.Get_Balance() + balance_string = fmt.Sprintf(color_green+"%s "+color_white, globals.FormatMoney(balance_unlocked)) if wallet.Error != nil { balance_string += fmt.Sprintf(color_red+" %s ", wallet.Error) + } else if wallet.PoolCount() > 0 { + balance_string += fmt.Sprintf(color_yellow+"(%d tx pending for -%s)", wallet.PoolCount(), globals.FormatMoney(wallet.PoolBalance())) } testnet_string := "" diff --git a/cmd/dero-wallet-cli/prompt.go b/cmd/dero-wallet-cli/prompt.go index 652c566..515a95c 100644 --- a/cmd/dero-wallet-cli/prompt.go +++ b/cmd/dero-wallet-cli/prompt.go @@ -30,12 +30,13 @@ import "encoding/hex" import "github.com/chzyer/readline" +import "github.com/deroproject/derohe/rpc" import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/crypto" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/address" import "github.com/deroproject/derohe/walletapi" +import "github.com/deroproject/derohe/cryptography/crypto" + var account walletapi.Account // handle all commands while in prompt mode @@ -80,7 +81,32 @@ func handle_prompt_command(l *readline.Instance, line string) { fallthrough case "balance": // give user his balance balance_unlocked, locked_balance := wallet.Get_Balance_Rescan() - fmt.Fprintf(l.Stderr(), "Balance : "+color_green+"%s"+color_white+"\n\n", globals.FormatMoney(locked_balance+balance_unlocked)) + fmt.Fprintf(l.Stderr(), "DERO Balance : "+color_green+"%s"+color_white+"\n", globals.FormatMoney(locked_balance+balance_unlocked)) + + line_parts := line_parts[1:] // remove first part + + switch len(line_parts) { + case 0: + //globals.Logger.Warnf("not implemented") + break + + case 1: // scid balance + scid := crypto.HashHexToHash(line_parts[0]) + + //globals.Logger.Infof("scid1 %s line_parts %+v", scid, line_parts) + balance, err := wallet.GetDecryptedBalanceAtTopoHeight(scid, -1, wallet.GetAddress().String()) + + //globals.Logger.Infof("scid %s", scid) + if err != nil { + globals.Logger.Infof("error %s", err) + } else { + fmt.Fprintf(l.Stderr(), "SCID %s Balance : "+color_green+"%s"+color_white+"\n\n", line_parts[0], globals.FormatMoney(balance)) + } + + case 2: // scid balance at topoheight + globals.Logger.Warnf("not implemented") + break + } case "rescan_bc", "rescan_spent": // rescan from 0 if offline_mode { @@ -123,7 +149,7 @@ func handle_prompt_command(l *readline.Instance, line string) { globals.Logger.Warnf("Error parsing txhash") break } - key := wallet.GetTXKey(crypto.HexToHash(line_parts[1])) + key := wallet.GetTXKey(line_parts[1]) if key != "" { globals.Logger.Infof("TX Proof key \"%s\"", key) } else { @@ -134,7 +160,7 @@ func handle_prompt_command(l *readline.Instance, line string) { globals.Logger.Warnf("eg. get_tx_key ea551b02b9f1e8aebe4d7b1b7f6bf173d76ae614cb9a066800773fee9e226fd7") } case "sweep_all", "transfer_all": // transfer everything - Transfer_Everything(l) + //Transfer_Everything(l) case "show_transfers": show_transfers(l, wallet, 100) @@ -153,11 +179,37 @@ func handle_prompt_command(l *readline.Instance, line string) { case "i8", "integrated_address": // user wants a random integrated address 8 bytes a := wallet.GetRandomIAddress8() fmt.Fprintf(l.Stderr(), "Wallet integrated address : "+color_green+"%s"+color_white+"\n", a.String()) - fmt.Fprintf(l.Stderr(), "Embedded payment ID : "+color_green+"%x"+color_white+"\n", a.PaymentID) + fmt.Fprintf(l.Stderr(), "Embedded Arguments : "+color_green+"%s"+color_white+"\n", a.Arguments) case "version": globals.Logger.Infof("Version %s\n", config.Version.String()) + case "burn": + line_parts := line_parts[1:] // remove first part + if len(line_parts) < 2 { + globals.Logger.Warnf("burn needs destination address and amount as input parameter") + break + } + addr := line_parts[0] + send_amount := uint64(1) + burn_amount, err := globals.ParseAmount(line_parts[1]) + if err != nil { + globals.Logger.Warnf("Error Parsing burn amount \"%s\" err %s", line_parts[1], err) + return + } + if ConfirmYesNoDefaultNo(l, "Confirm Transaction (y/N)") { + + //uid, err := wallet.PoolTransferWithBurn(addr, send_amount, burn_amount, data, rpc.Arguments{}) + + uid, err := wallet.PoolTransfer([]rpc.Transfer{rpc.Transfer{Amount: send_amount, Burn: burn_amount, Destination: addr}}, rpc.Arguments{}) // empty SCDATA + _ = uid + if err != nil { + globals.Logger.Warnf("Error while building Transaction err %s\n", err) + break + } + //fmt.Printf("queued tx err %s\n", err) + //build_relay_transaction(l, uid, err, offline_tx, amount_list) + } case "transfer": // parse the address, amount pair /* @@ -221,16 +273,6 @@ func handle_prompt_command(l *readline.Instance, line string) { } - // if user provided an integrated address donot ask him payment id - // otherwise confirm whether user wants to send without payment id - if payment_id_integrated == false && len(payment_id) == 0 { - payment_id_bytes, err := ReadPaymentID(l) - payment_id = hex.EncodeToString(payment_id_bytes) - if err != nil { - globals.Logger.Warnf("Err :%s", err) - break - } - } offline := false tx, inputs, input_sum, change, err := wallet.Transfer(addr_list, amount_list, 0, payment_id, 0, 0) @@ -242,6 +284,10 @@ func handle_prompt_command(l *readline.Instance, line string) { if wallet != nil { wallet.Close_Encrypted_Wallet() // overwrite previous instance } + case "flush": // flush wallet pool + if wallet != nil { + fmt.Fprintf(l.Stderr(), "Flushed %d transactions from wallet pool\n", wallet.PoolClear()) + } case "": // blank enter key just loop default: @@ -317,85 +363,8 @@ func handle_set_command(l *readline.Instance, line string) { } } -func Transfer_Everything(l *readline.Instance) { - /* - if wallet.Is_View_Only() { - fmt.Fprintf(l.Stderr(), color_yellow+"View Only wallet cannot transfer."+color_white) - } - - if !ValidateCurrentPassword(l, wallet) { - globals.Logger.Warnf("Invalid password") - return - } - - // a , amount_to_transfer, err := collect_transfer_info(l,wallet) - addr, err := ReadAddress(l) - if err != nil { - globals.Logger.Warnf("Err :%s", err) - return - } - - var payment_id []byte - // if user provided an integrated address donot ask him payment id - if !addr.IsIntegratedAddress() { - payment_id, err = ReadPaymentID(l) - if err != nil { - globals.Logger.Warnf("Err :%s", err) - return - } - } else { - globals.Logger.Infof("Payment ID is integreted in address ID:%x", addr.PaymentID) - } - - fees_per_kb := uint64(0) // fees must be calculated by walletapi - - tx, inputs, input_sum, err := wallet.Transfer_Everything(*addr, hex.EncodeToString(payment_id), 0, fees_per_kb, 5) - - _ = inputs - if err != nil { - globals.Logger.Warnf("Error while building Transaction err %s\n", err) - return - } - globals.Logger.Infof("%d Inputs Selected for %s DERO", len(inputs), globals.FormatMoney12(input_sum)) - globals.Logger.Infof("fees %s DERO", globals.FormatMoneyPrecision(tx.RctSignature.Get_TX_Fee(), 12)) - globals.Logger.Infof("TX Size %0.1f KiB (should be < 240 KiB)", float32(len(tx.Serialize()))/1024.0) - offline_tx := false - if ConfirmYesNoDefaultNo(l, "Confirm Transaction (y/N)") { - - if offline_tx { // if its an offline tx, dump it to a file - cur_dir, err := os.Getwd() - if err != nil { - globals.Logger.Warnf("Cannot obtain current directory to save tx") - return - } - filename := filepath.Join(cur_dir, tx.GetHash().String()+".tx") - err = ioutil.WriteFile(filename, []byte(hex.EncodeToString(tx.Serialize())), 0600) - if err == nil { - if err == nil { - globals.Logger.Infof("Transaction saved successfully. txid = %s", tx.GetHash()) - globals.Logger.Infof("Saved to %s", filename) - } else { - globals.Logger.Warnf("Error saving tx to %s , err %s", filename, err) - } - } - - } else { - - err = wallet.SendTransaction(tx) // relay tx to daemon/network - if err == nil { - globals.Logger.Infof("Transaction sent successfully. txid = %s", tx.GetHash()) - } else { - globals.Logger.Warnf("Transaction sending failed txid = %s, err %s", tx.GetHash(), err) - } - - } - } - */ - -} - // read an address with all goodies such as color encoding and other things in prompt -func ReadAddress(l *readline.Instance) (a *address.Address, err error) { +func ReadAddress(l *readline.Instance) (a *rpc.Address, err error) { setPasswordCfg := l.GenPasswordConfig() setPasswordCfg.EnableMask = false @@ -435,18 +404,10 @@ func ReadAddress(l *readline.Instance) (a *address.Address, err error) { return } -/* -// read an payment with all goodies such as color encoding and other things in prompt -func ReadPaymentID(l *readline.Instance) (payment_id []byte, err error) { +func ReadFloat64(l *readline.Instance, cprompt string, default_value float64) (a float64, err error) { setPasswordCfg := l.GenPasswordConfig() setPasswordCfg.EnableMask = false - // ask user whether he want to enter a payment ID - - if !ConfirmYesNoDefaultNo(l, "Provide Payment ID (y/N)") { // user doesnot want to provide payment it, skip - return - } - prompt_mutex.Lock() defer prompt_mutex.Unlock() @@ -455,19 +416,17 @@ func ReadPaymentID(l *readline.Instance) (payment_id []byte, err error) { color := color_green if len(line) >= 1 { - _, err := hex.DecodeString(string(line)) - if (len(line) == 16 || len(line) == 64) && err == nil { - error_message = "" - } else { + _, err := strconv.ParseFloat(string(line), 64) + if err != nil { error_message = " " //err.Error() } } if error_message != "" { color = color_red // Should we display the error message here?? - l.SetPrompt(fmt.Sprintf("%sEnter Payment ID (16/64 hex char): ", color)) + l.SetPrompt(fmt.Sprintf("%sEnter %s (default %f): ", color, cprompt, default_value)) } else { - l.SetPrompt(fmt.Sprintf("%sEnter Payment ID (16/64 hex char): ", color)) + l.SetPrompt(fmt.Sprintf("%sEnter %s (default %f): ", color, cprompt, default_value)) } @@ -479,21 +438,128 @@ func ReadPaymentID(l *readline.Instance) (payment_id []byte, err error) { if err != nil { return } - payment_id, err = hex.DecodeString(string(line)) + a, err = strconv.ParseFloat(string(line), 64) + l.SetPrompt(cprompt) + l.Refresh() + return +} + +func ReadUint64(l *readline.Instance, cprompt string, default_value uint64) (a uint64, err error) { + setPasswordCfg := l.GenPasswordConfig() + setPasswordCfg.EnableMask = false + + prompt_mutex.Lock() + defer prompt_mutex.Unlock() + + setPasswordCfg.SetListener(func(line []rune, pos int, key rune) (newLine []rune, newPos int, ok bool) { + error_message := "" + color := color_green + + if len(line) >= 1 { + _, err := strconv.ParseUint(string(line), 0, 64) + if err != nil { + error_message = " " //err.Error() + } + } + + if error_message != "" { + color = color_red // Should we display the error message here?? + l.SetPrompt(fmt.Sprintf("%sEnter %s (default %d): ", color, cprompt, default_value)) + } else { + l.SetPrompt(fmt.Sprintf("%sEnter %s (default %d): ", color, cprompt, default_value)) + + } + + l.Refresh() + return nil, 0, false + }) + + line, err := l.ReadPasswordWithConfig(setPasswordCfg) if err != nil { return } - l.SetPrompt(prompt) + a, err = strconv.ParseUint(string(line), 0, 64) + l.SetPrompt(cprompt) + l.Refresh() + return +} + +func ReadInt64(l *readline.Instance, cprompt string, default_value int64) (a int64, err error) { + setPasswordCfg := l.GenPasswordConfig() + setPasswordCfg.EnableMask = false + + prompt_mutex.Lock() + defer prompt_mutex.Unlock() + + setPasswordCfg.SetListener(func(line []rune, pos int, key rune) (newLine []rune, newPos int, ok bool) { + error_message := "" + color := color_green + + if len(line) >= 1 { + _, err := strconv.ParseInt(string(line), 0, 64) + if err != nil { + error_message = " " //err.Error() + } + } + + if error_message != "" { + color = color_red // Should we display the error message here?? + l.SetPrompt(fmt.Sprintf("%sEnter %s (default %d): ", color, cprompt, default_value)) + } else { + l.SetPrompt(fmt.Sprintf("%sEnter %s (default %d): ", color, cprompt, default_value)) + + } + + l.Refresh() + return nil, 0, false + }) + + line, err := l.ReadPasswordWithConfig(setPasswordCfg) + if err != nil { + return + } + a, err = strconv.ParseInt(string(line), 0, 64) + l.SetPrompt(cprompt) + l.Refresh() + return +} + +func ReadString(l *readline.Instance, cprompt string, default_value string) (a string, err error) { + setPasswordCfg := l.GenPasswordConfig() + setPasswordCfg.EnableMask = false + + prompt_mutex.Lock() + defer prompt_mutex.Unlock() + + setPasswordCfg.SetListener(func(line []rune, pos int, key rune) (newLine []rune, newPos int, ok bool) { + error_message := "" + color := color_green + + if len(line) < 1 { + error_message = " " //err.Error() + } + + if error_message != "" { + color = color_red // Should we display the error message here?? + l.SetPrompt(fmt.Sprintf("%sEnter %s (default '%s'): ", color, cprompt, default_value)) + } else { + l.SetPrompt(fmt.Sprintf("%sEnter %s (default '%s'): ", color, cprompt, default_value)) + + } + + l.Refresh() + return nil, 0, false + }) + + line, err := l.ReadPasswordWithConfig(setPasswordCfg) + if err != nil { + return + } + a = string(line) + l.SetPrompt(cprompt) l.Refresh() - - if len(payment_id) == 8 || len(payment_id) == 32 { - return - } - - err = fmt.Errorf("Invalid Payment ID") return } -*/ // confirms whether the user wants to confirm yes func ConfirmYesNoDefaultYes(l *readline.Instance, prompt_temporary string) bool { @@ -656,32 +722,6 @@ func PressAnyKey(l *readline.Instance, wallet *walletapi.Wallet_Disk) { return } -/* -// if we are in offline, scan default or user provided file -// this function will replay the blockchain data in offline mode -func trigger_offline_data_scan() { - filename := default_offline_datafile - - if globals.Arguments["--offline_datafile"] != nil { - filename = globals.Arguments["--offline_datafile"].(string) - } - - f, err := os.Open(filename) - if err != nil { - globals.Logger.Warnf("Cannot read offline data file=\"%s\" err: %s ", filename, err) - return - } - w := bufio.NewReader(f) - gzipreader, err := gzip.NewReader(w) - if err != nil { - globals.Logger.Warnf("Error while decompressing offline data file=\"%s\" err: %s ", filename, err) - return - } - defer gzipreader.Close() - io.Copy(pipe_writer, gzipreader) -} -*/ - // this completer is used to complete the commands at the prompt // BUG, this needs to be disabled in menu mode var completer = readline.NewPrefixCompleter( @@ -733,6 +773,7 @@ func usage(w io.Writer) { io.WriteString(w, "\t\033[1mtransfer\033[0m\tTransfer/Send DERO to another address\n") io.WriteString(w, "\t\t\tEg. transfer
\n") io.WriteString(w, "\t\033[1mtransfer_all\033[0m\tTransfer everything to another address\n") + io.WriteString(w, "\t\033[1mflush\033[0m\tFlush local wallet pool (for testing purposes)\n") io.WriteString(w, "\t\033[1mversion\033[0m\t\tShow version\n") io.WriteString(w, "\t\033[1mbye\033[0m\t\tQuit wallet\n") io.WriteString(w, "\t\033[1mexit\033[0m\t\tQuit wallet\n") @@ -754,7 +795,7 @@ func display_seed(l *readline.Instance, wallet *walletapi.Wallet_Disk) { func display_spend_key(l *readline.Instance, wallet *walletapi.Wallet_Disk) { keys := wallet.Get_Keys() - h := "0000000000000000000000000000000000000000000000"+keys.Secret.Text(16) + h := "0000000000000000000000000000000000000000000000" + keys.Secret.Text(16) fmt.Fprintf(os.Stderr, "secret key: "+color_red+"%s"+color_white+"\n", h[len(h)-64:]) fmt.Fprintf(os.Stderr, "public key: %s\n", keys.Public.StringHex()) @@ -769,15 +810,8 @@ func rescan_bc(wallet *walletapi.Wallet_Disk) { } -func is_registered(wallet *walletapi.Wallet_Disk) bool { - if wallet.Get_Registration_TopoHeight() == -1 { - return false - } - return true -} - func valid_registration_or_display_error(l *readline.Instance, wallet *walletapi.Wallet_Disk) bool { - if !is_registered(wallet) { + if !wallet.IsRegistered() { globals.Logger.Warnf("Your account is not registered.Please register.") } return true @@ -786,11 +820,9 @@ func valid_registration_or_display_error(l *readline.Instance, wallet *walletapi // show the transfers to the user originating from this account func show_transfers(l *readline.Instance, wallet *walletapi.Wallet_Disk, limit uint64) { - available := true in := true out := true - pool := true // this is not processed still TODO list - failed := false // this is not processed still TODO list + coinbase := true min_height := uint64(0) max_height := uint64(0) @@ -798,37 +830,18 @@ func show_transfers(l *readline.Instance, wallet *walletapi.Wallet_Disk, limit u line_parts := strings.Fields(line) if len(line_parts) >= 2 { switch strings.ToLower(line_parts[1]) { - case "available": - available = true - in = false + case "coinbase": out = false - pool = false - failed = false + in = false + case "in": - available = true + coinbase = false in = true out = false - pool = false - failed = false case "out": - available = false + coinbase = false in = false out = true - pool = false - failed = false - case "pool": - available = false - in = false - out = false - pool = true - failed = false - case "failed": - available = false - in = false - out = false - pool = false - failed = true - } } @@ -851,7 +864,7 @@ func show_transfers(l *readline.Instance, wallet *walletapi.Wallet_Disk, limit u } // request payments without payment id - transfers := wallet.Show_Transfers(available, in, out, pool, failed, false, min_height, max_height) // receives sorted list of transfers + transfers := wallet.Show_Transfers(coinbase, in, out, min_height, max_height, "", "", 0, 0) // receives sorted list of transfers if len(transfers) == 0 { globals.Logger.Warnf("No transfers available") @@ -872,16 +885,42 @@ func show_transfers(l *readline.Instance, wallet *walletapi.Wallet_Disk, limit u if transfers[i].Coinbase { io.WriteString(l.Stderr(), fmt.Sprintf(color_green+"%s Height %d TopoHeight %d Coinbase (miner reward) received %s DERO"+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, globals.FormatMoney(transfers[i].Amount))) - } else if len(transfers[i].PaymentID) == 0 { - io.WriteString(l.Stderr(), fmt.Sprintf(color_green+"%s Height %d TopoHeight %d transaction %s received %s DERO"+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount))) } else { - payment_id := fmt.Sprintf("%x", transfers[i].PaymentID) - io.WriteString(l.Stderr(), fmt.Sprintf(color_green+"%s Height %d TopoHeight %d transaction %s received %s DERO"+color_white+" PAYMENT ID:%s\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), payment_id)) + + args, err := transfers[i].ProcessPayload() + if err != nil { + io.WriteString(l.Stderr(), fmt.Sprintf(color_green+"%s Height %d TopoHeight %d transaction %s received %s DERO Proof: %s"+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), transfers[i].Proof)) + + io.WriteString(l.Stderr(), fmt.Sprintf("Full Entry\n", transfers[i])) // dump entire entry for debugging purposes + + } else if len(args) == 0 { // no rpc + + io.WriteString(l.Stderr(), fmt.Sprintf(color_green+"%s Height %d TopoHeight %d transaction %s received %s DERO Proof: %s NO RPC CALL"+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), transfers[i].Proof)) + + } else { // yes, its rpc + io.WriteString(l.Stderr(), fmt.Sprintf(color_green+"%s Height %d TopoHeight %d transaction %s received %s DERO Proof: %s RPC CALL arguments %s "+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), transfers[i].Proof, args)) + + } + } case 1: - payment_id := fmt.Sprintf("%x", transfers[i].PaymentID) - io.WriteString(l.Stderr(), fmt.Sprintf(color_magenta+"%s Height %d TopoHeight %d transaction %s spent %s DERO"+color_white+" PAYMENT ID: %s Proof:%s\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), payment_id, transfers[i].Proof)) + + args, err := transfers[i].ProcessPayload() + if err != nil { + io.WriteString(l.Stderr(), fmt.Sprintf(color_yellow+"%s Height %d TopoHeight %d transaction %s spent %s DERO Destination: %s Proof: %s\n"+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), transfers[i].Destination, transfers[i].Proof)) + + io.WriteString(l.Stderr(), fmt.Sprintf("Err decoding entry %s\nFull Entry %+v\n", err, transfers[i])) // dump entire entry for debugging purposes + + } else if len(args) == 0 { // no rpc + + io.WriteString(l.Stderr(), fmt.Sprintf(color_yellow+"%s Height %d TopoHeight %d transaction %s spent %s DERO Destination: %s Proof: %s NO RPC CALL"+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), transfers[i].Destination, transfers[i].Proof)) + + } else { // yes, its rpc + io.WriteString(l.Stderr(), fmt.Sprintf(color_yellow+"%s Height %d TopoHeight %d transaction %s spent %s DERO Destination: %s Proof: %s RPC CALL arguments %s "+color_white+"\n", transfers[i].Time.Format(time.RFC822), transfers[i].Height, transfers[i].TopoHeight, transfers[i].TXID, globals.FormatMoney(transfers[i].Amount), transfers[i].Destination, transfers[i].Proof, args)) + + } + case 2: fallthrough default: diff --git a/cmd/derod/main.go b/cmd/derod/main.go index 387f169..fd86db2 100644 --- a/cmd/derod/main.go +++ b/cmd/derod/main.go @@ -45,12 +45,12 @@ import "github.com/deroproject/derohe/p2p" import "github.com/deroproject/derohe/globals" import "github.com/deroproject/derohe/block" import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/address" +import "github.com/deroproject/derohe/rpc" import "github.com/deroproject/derohe/blockchain" import "github.com/deroproject/derohe/transaction" //import "github.com/deroproject/derosuite/checkpoints" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" //import "github.com/deroproject/derosuite/cryptonight" @@ -62,7 +62,7 @@ var command_line string = `derod DERO : A secure, private blockchain with smart-contracts Usage: - derod [--help] [--version] [--testnet] [--debug] [--sync-node] [--disable-checkpoints] [--socks-proxy=] [--data-dir=] [--p2p-bind=<0.0.0.0:18089>] [--add-exclusive-node=]... [--add-priority-node=]... [--min-peers=<11>] [--rpc-bind=<127.0.0.1:9999>] [--lowcpuram] [--mining-address=] [--mining-threads=] [--node-tag=] [--prune-history=<50>] + derod [--help] [--version] [--testnet] [--debug] [--sync-node] [--fullnode] [--disable-checkpoints] [--socks-proxy=] [--data-dir=] [--p2p-bind=<0.0.0.0:18089>] [--add-exclusive-node=]... [--add-priority-node=]... [--min-peers=<11>] [--rpc-bind=<127.0.0.1:9999>] [--node-tag=] [--prune-history=<50>] derod -h | --help derod --version @@ -71,6 +71,7 @@ Options: --version Show version. --testnet Run in testnet mode. --debug Debug mode enabled, print log messages + --fullnode Full node mode (this option has effect only while bootstrapping) --socks-proxy= Use a proxy to connect to network. --data-dir= Store blockchain data at this location --rpc-bind=<127.0.0.1:9999> RPC listens on this ip:port @@ -78,10 +79,6 @@ Options: --add-exclusive-node= Connect to specific peer only --add-priority-node= Maintain persistant connection to specified peer --sync-node Sync node automatically with the seeds nodes. This option is for rare use. - --min-peers=<11> Number of connections the daemon tries to maintain - --lowcpuram Disables some RAM consuming sections (deactivates mining/ultra compact protocol etc). - --mining-address= This address is rewarded when a block is mined sucessfully - --mining-threads= Number of CPU threads for mining --node-tag= Unique name of node, visible to everyone --prune-history=<50> prunes blockchain history until the specific topo_height @@ -188,18 +185,18 @@ func main() { p2p.P2P_Init(params) - rpc, _ := RPCServer_Start(params) + rpcserver, _ := RPCServer_Start(params) // setup function pointers // these pointers need to fixed chain.Mempool.P2P_TX_Relayer = func(tx *transaction.Transaction, peerid uint64) (count int) { - count += p2p.Broadcast_Tx(tx, peerid) + count += int(p2p.Broadcast_Tx(tx, peerid)) return } chain.Regpool.P2P_TX_Relayer = func(tx *transaction.Transaction, peerid uint64) (count int) { - count += p2p.Broadcast_Tx(tx, peerid) + count += int(p2p.Broadcast_Tx(tx, peerid)) return } @@ -207,47 +204,6 @@ func main() { p2p.Broadcast_Block(cbl, peerid) } - if globals.Arguments["--lowcpuram"].(bool) == false && globals.Arguments["--sync-node"].(bool) == false { // enable v1 of protocol only if requested - - // if an address has been provided, verify that it satisfies //mainnet/testnet criteria - if globals.Arguments["--mining-address"] != nil { - - addr, err := globals.ParseValidateAddress(globals.Arguments["--mining-address"].(string)) - if err != nil { - globals.Logger.Fatalf("Mining address is invalid: err %s", err) - } - params["mining-address"] = addr - - //log.Debugf("Setting up proxy using %s", Arguments["--socks-proxy"].(string)) - } - - if globals.Arguments["--mining-threads"] != nil { - thread_count := 0 - if s, err := strconv.Atoi(globals.Arguments["--mining-threads"].(string)); err == nil { - //fmt.Printf("%T, %v", s, s) - thread_count = s - - } else { - globals.Logger.Fatalf("Mining threads argument cannot be parsed: err %s", err) - } - - if thread_count > runtime.GOMAXPROCS(0) { - globals.Logger.Fatalf("Mining threads (%d) is more than available CPUs (%d). This is NOT optimal", thread_count, runtime.GOMAXPROCS(0)) - - } - params["mining-threads"] = thread_count - - if _, ok := params["mining-address"]; !ok { - globals.Logger.Fatalf("Mining threads require a valid wallet address") - } - - globals.Logger.Infof("System will mine to %s with %d threads. Good Luck!!", globals.Arguments["--mining-address"].(string), thread_count) - - go start_miner(chain, params["mining-address"].(*address.Address), nil, thread_count) - } - - } - //go time_check_routine() // check whether server time is in sync // This tiny goroutine continuously updates status as required @@ -397,7 +353,7 @@ func main() { break } // - case command == "import_chain": // this migrates existing chain from DERO to DERO atlantis + case command == "import_chain": // this migrates existing chain from DERO atlantis to DERO HE /* f, err := os.Open("/tmp/raw_export.txt") if err != nil { @@ -553,27 +509,14 @@ func main() { diff = chain.Load_Block_Difficulty(current_block_id) } - toporecord, err := chain.Store.Topo_store.Read(i) - if err != nil { - log.Infof("Skipping block at height %d due to error while obtaining toporecord %s\n", i, err) - continue - } - - ss, err := chain.Store.Balance_store.LoadSnapshot(uint64(toporecord.State_Version)) - if err != nil { - panic(err) - } - - balance_tree, err := ss.GetTree(blockchain.BALANCE_TREE) + balance_hash, err := chain.Load_Merkle_Hash(i) if err != nil { panic(err) } - balance_hash, _ := balance_tree.Hash() - log.Infof("topo height: %10d, height %d, timestamp: %10d, difficulty: %s cdiff: %s", i, chain.Load_Height_for_BL_ID(current_block_id), timestamp, diff.String(), cdiff.String()) - log.Infof("Block Id: %s , balance_tree hash %x \n", current_block_id, balance_hash) + log.Infof("Block Id: %s , balance_tree hash %s \n", current_block_id, balance_hash) log.Infof("") } @@ -625,24 +568,19 @@ func main() { case command == "start_mining": // it needs 2 parameters, one dero address, second number of threads var tx *transaction.Transaction - var addr *address.Address + var addr *rpc.Address if mining { fmt.Printf("Mining is already started\n") continue } - if globals.Arguments["--lowcpuram"].(bool) { - globals.Logger.Warnf("Mining is deactivated since daemon is running in low cpu mode, please check program options.") - continue - } - if globals.Arguments["--sync-node"].(bool) { globals.Logger.Warnf("Mining is deactivated since daemon is running with --sync-mode, please check program options.") continue } if len(line_parts) != 3 { - fmt.Printf("This function requires 2 parameters 1) dero address or registration TX 2) number of threads\n") + fmt.Printf("This function requires 2 parameters 1) dero address 2) number of threads\n") continue } @@ -661,40 +599,16 @@ func main() { } - hexdecoded, err := hex.DecodeString(line_parts[1]) - if err == nil { - tx = &transaction.Transaction{} - if err = tx.DeserializeHeader(hexdecoded); err == nil { + var err error - if tx.IsRegistration() { - - if tx.IsRegistrationValid() { - - addr = &address.Address{ - PublicKey: new(crypto.Point), - } - - err = addr.PublicKey.DecodeCompressed(tx.MinerAddress[0:33]) - - } else { - err = fmt.Errorf("Registration TX is invalid") - } - } else { - err = fmt.Errorf("TX is not registration") - } - } - } else { - err = nil - - addr, err = globals.ParseValidateAddress(line_parts[1]) - if err != nil { - globals.Logger.Warnf("Mining address is invalid: err %s", err) - continue - } - - } + addr, err = globals.ParseValidateAddress(line_parts[1]) if err != nil { - globals.Logger.Warnf("Registration TX/Mining address is invalid: err %s", err) + globals.Logger.Warnf("Mining address is invalid: err %s", err) + continue + } + + if err != nil { + globals.Logger.Warnf("Mining address is invalid: err %s", err) continue } @@ -757,25 +671,12 @@ func main() { fmt.Printf("Height: %d\n", chain.Load_Height_for_BL_ID(hash)) fmt.Printf("TopoHeight: %d\n", s) - toporecord, err := chain.Store.Topo_store.Read(s) - if err != nil { - log.Infof("Skipping block at topo height %d due to error while obtaining toporecord %s\n", s, err) - panic(err) - continue - } + bhash, err := chain.Load_Merkle_Hash(s) - ss, err := chain.Store.Balance_store.LoadSnapshot(uint64(toporecord.State_Version)) if err != nil { panic(err) } - balance_tree, err := ss.GetTree(blockchain.BALANCE_TREE) - if err != nil { - panic(err) - } - - bhash, _ := balance_tree.Hash() - fmt.Printf("BALANCE_TREE : %s\n", bhash) fmt.Printf("PoW: %s\n", bl.GetPoWHash()) @@ -1124,7 +1025,7 @@ exit: globals.Logger.Infof("Exit in Progress, Please wait") time.Sleep(100 * time.Millisecond) // give prompt update time to finish - rpc.RPCServer_Stop() + rpcserver.RPCServer_Stop() p2p.P2P_Shutdown() // shutdown p2p subsystem chain.Shutdown() // shutdown chain subsysem @@ -1155,7 +1056,7 @@ func writenode(chain *blockchain.Blockchain, w *bufio.Writer, blid crypto.Hash, panic(err) } - addr := address.NewAddressFromKeys(&acckey) + addr := rpc.NewAddressFromKeys(&acckey) addr.Mainnet = globals.IsMainnet() w.WriteString(fmt.Sprintf("L%s [ fillcolor=%s label = \"%s %d height %d score %d stored %d order %d\nminer %s\" ];\n", blid.String(), color, blid.String(), 0, chain.Load_Height_for_BL_ID(blid), 0, chain.Load_Block_Cumulative_Difficulty(blid), chain.Load_Block_Topological_order(blid), addr.String())) diff --git a/cmd/derod/miner.go b/cmd/derod/miner.go index 357da36..c608f9b 100644 --- a/cmd/derod/miner.go +++ b/cmd/derod/miner.go @@ -63,9 +63,9 @@ import "sync/atomic" import "encoding/binary" import "github.com/deroproject/derohe/block" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/address" +import "github.com/deroproject/derohe/rpc" import "github.com/deroproject/derohe/blockchain" import "github.com/deroproject/derohe/transaction" @@ -76,38 +76,41 @@ var counter uint64 = 0 // used to track speeds of current miner var mining bool // whether system is mining // request block chain template, see if the tip changes, then continously mine -func start_miner(chain *blockchain.Blockchain, addr *address.Address, tx *transaction.Transaction, threads int) { +func start_miner(chain *blockchain.Blockchain, addr *rpc.Address, tx *transaction.Transaction, threads int) { - mining = true - counter = 0 //tip_counter := 0 - for { - //time.Sleep(50 * time.Millisecond) + for { // once started keep generating blocks after every 10 secs + mining = true + counter = 0 + for { + //time.Sleep(50 * time.Millisecond) - if !mining { - break + if !mining { + break + } + + if chain.MINING_BLOCK == true { + time.Sleep(10 * time.Millisecond) + continue + } + + cbl, bl := chain.Create_new_miner_block(*addr, tx) + + difficulty := chain.Get_Difficulty_At_Tips(bl.Tips) + + //globals.Logger.Infof("Difficulty of new block is %s", difficulty.String()) + // calculate difficulty once + // update job from chain + wg := sync.WaitGroup{} + wg.Add(threads) // add total number of tx as work + + for i := 0; i < threads; i++ { + go generate_valid_PoW(chain, 0, cbl, cbl.Bl, difficulty, &wg) // work should be complete in approx 100 ms, on a 12 cpu system, this would add cost of launching 12 g routine per second + } + wg.Wait() } - - if chain.MINING_BLOCK == true { - time.Sleep(10 * time.Millisecond) - continue - } - - cbl, bl := chain.Create_new_miner_block(*addr, tx) - - difficulty := chain.Get_Difficulty_At_Tips(bl.Tips) - - //globals.Logger.Infof("Difficulty of new block is %s", difficulty.String()) - // calculate difficulty once - // update job from chain - wg := sync.WaitGroup{} - wg.Add(threads) // add total number of tx as work - - for i := 0; i < threads; i++ { - go generate_valid_PoW(chain, 0, cbl, cbl.Bl, difficulty, &wg) // work should be complete in approx 100 ms, on a 12 cpu system, this would add cost of launching 12 g routine per second - } - wg.Wait() + time.Sleep(10 * time.Second) } // g @@ -150,7 +153,7 @@ func generate_valid_PoW(chain *blockchain.Blockchain, hf_version uint64, cbl *bl if _, ok := chain.Add_Complete_Block(cbl); ok { globals.Logger.Infof("Block %s successfully accepted diff %s", bl.GetHash(), current_difficulty.String()) - //chain.P2P_Block_Relayer(cbl, 0) // broadcast block to network ASAP + chain.P2P_Block_Relayer(cbl, 0) // broadcast block to network ASAP mining = false // this line enables single block mining in 1 go diff --git a/cmd/derod/rpc_dero_getblock.go b/cmd/derod/rpc_dero_getblock.go index 06864ac..3c8b6fa 100644 --- a/cmd/derod/rpc_dero_getblock.go +++ b/cmd/derod/rpc_dero_getblock.go @@ -21,16 +21,12 @@ import "context" import "encoding/hex" import "encoding/json" import "runtime/debug" - -//import "log" -//import "net/http" - -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/rpc" //import "github.com/deroproject/derosuite/blockchain" -func (DERO_RPC_APIS) GetBlock(ctx context.Context, p structures.GetBlock_Params) (result structures.GetBlock_Result, err error) { +func (DERO_RPC_APIS) GetBlock(ctx context.Context, p rpc.GetBlock_Params) (result rpc.GetBlock_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { @@ -70,7 +66,7 @@ func (DERO_RPC_APIS) GetBlock(ctx context.Context, p structures.GetBlock_Params) if err != nil { // if err return err return } - return structures.GetBlock_Result{ // return success + return rpc.GetBlock_Result{ // return success Block_Header: block_header, Blob: hex.EncodeToString(bl.Serialize()), Json: string(json_encoded_bytes), diff --git a/cmd/derod/rpc_dero_getblockcount.go b/cmd/derod/rpc_dero_getblockcount.go index b4868fa..9bdb056 100644 --- a/cmd/derod/rpc_dero_getblockcount.go +++ b/cmd/derod/rpc_dero_getblockcount.go @@ -17,10 +17,10 @@ package main import "context" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/rpc" -func (DERO_RPC_APIS) GetBlockCount(ctx context.Context) structures.GetBlockCount_Result { - return structures.GetBlockCount_Result{ +func (DERO_RPC_APIS) GetBlockCount(ctx context.Context) rpc.GetBlockCount_Result { + return rpc.GetBlockCount_Result{ Count: uint64(chain.Get_Height()), Status: "OK", } diff --git a/cmd/derod/rpc_dero_getblockheaderbyhash.go b/cmd/derod/rpc_dero_getblockheaderbyhash.go index e0bf3b9..f4f092d 100644 --- a/cmd/derod/rpc_dero_getblockheaderbyhash.go +++ b/cmd/derod/rpc_dero_getblockheaderbyhash.go @@ -19,14 +19,10 @@ package main import "fmt" import "context" import "runtime/debug" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/rpc" -//import "log" -//import "net/http" - -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/structures" - -func (DERO_RPC_APIS) GetBlockHeaderByHash(ctx context.Context, p structures.GetBlockHeaderByHash_Params) (result structures.GetBlockHeaderByHash_Result, err error) { +func (DERO_RPC_APIS) GetBlockHeaderByHash(ctx context.Context, p rpc.GetBlockHeaderByHash_Params) (result rpc.GetBlockHeaderByHash_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { err = fmt.Errorf("panic occured. stack trace %s", debug.Stack()) @@ -34,7 +30,7 @@ func (DERO_RPC_APIS) GetBlockHeaderByHash(ctx context.Context, p structures.GetB }() hash := crypto.HashHexToHash(p.Hash) if block_header, err := chain.GetBlockHeader(hash); err == nil { // if err return err - return structures.GetBlockHeaderByHash_Result{ // return success + return rpc.GetBlockHeaderByHash_Result{ // return success Block_Header: block_header, Status: "OK", }, nil diff --git a/cmd/derod/rpc_dero_getblockheaderbytopoheight.go b/cmd/derod/rpc_dero_getblockheaderbytopoheight.go index ed89ac3..84591c8 100644 --- a/cmd/derod/rpc_dero_getblockheaderbytopoheight.go +++ b/cmd/derod/rpc_dero_getblockheaderbytopoheight.go @@ -19,13 +19,9 @@ package main import "fmt" import "context" import "runtime/debug" +import "github.com/deroproject/derohe/rpc" -//import "log" -//import "net/http" -//import "github.com/deroproject/derosuite/crypto" -import "github.com/deroproject/derohe/structures" - -func (DERO_RPC_APIS) GetBlockHeaderByTopoHeight(ctx context.Context, p structures.GetBlockHeaderByTopoHeight_Params) (result structures.GetBlockHeaderByHeight_Result, err error) { +func (DERO_RPC_APIS) GetBlockHeaderByTopoHeight(ctx context.Context, p rpc.GetBlockHeaderByTopoHeight_Params) (result rpc.GetBlockHeaderByHeight_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { @@ -51,7 +47,7 @@ func (DERO_RPC_APIS) GetBlockHeaderByTopoHeight(ctx context.Context, p structure return } - return structures.GetBlockHeaderByHeight_Result{ // return success + return rpc.GetBlockHeaderByHeight_Result{ // return success Block_Header: block_header, Status: "OK", }, nil diff --git a/cmd/derod/rpc_dero_getblocktemplate.go b/cmd/derod/rpc_dero_getblocktemplate.go index a58a027..e5decaf 100644 --- a/cmd/derod/rpc_dero_getblocktemplate.go +++ b/cmd/derod/rpc_dero_getblocktemplate.go @@ -20,23 +20,14 @@ import "fmt" import "time" import "context" import "runtime/debug" - -//import "log" -//import "net/http" - import "golang.org/x/time/rate" - -//import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/address" -import "github.com/deroproject/derohe/structures" - -//import "github.com/deroproject/derohe/transaction" +import "github.com/deroproject/derohe/rpc" // rate limiter is deployed, in case RPC is exposed over internet // someone should not be just giving fake inputs and delay chain syncing var get_block_limiter = rate.NewLimiter(16.0, 8) // 16 req per sec, burst of 8 req is okay -func (DERO_RPC_APIS) GetBlockTemplate(ctx context.Context, p structures.GetBlockTemplate_Params) (result structures.GetBlockTemplate_Result, err error) { +func (DERO_RPC_APIS) GetBlockTemplate(ctx context.Context, p rpc.GetBlockTemplate_Params) (result rpc.GetBlockTemplate_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { @@ -57,7 +48,7 @@ func (DERO_RPC_APIS) GetBlockTemplate(ctx context.Context, p structures.GetBlock */ // validate address - miner_address, err := address.NewAddress(p.Wallet_Address) + miner_address, err := rpc.NewAddress(p.Wallet_Address) if err != nil { return result, fmt.Errorf("Address could not be parsed, err:%s", err) } @@ -72,7 +63,7 @@ func (DERO_RPC_APIS) GetBlockTemplate(ctx context.Context, p structures.GetBlock for i := range bl.Tips { prev_hash = prev_hash + bl.Tips[i].String() } - return structures.GetBlockTemplate_Result{ + return rpc.GetBlockTemplate_Result{ Blocktemplate_blob: block_template_hex, Blockhashing_blob: block_hashing_blob_hex, Reserved_Offset: uint64(reserved_pos), diff --git a/cmd/derod/rpc_dero_getencryptedbalance.go b/cmd/derod/rpc_dero_getencryptedbalance.go index 611b980..88dcac7 100644 --- a/cmd/derod/rpc_dero_getencryptedbalance.go +++ b/cmd/derod/rpc_dero_getencryptedbalance.go @@ -19,25 +19,23 @@ package main import "fmt" import "math" import "context" -import "encoding/hex" import "runtime/debug" -//import "log" -//import "net/http" import "golang.org/x/xerrors" - import "github.com/deroproject/graviton" - import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/blockchain" -import "github.com/deroproject/derohe/address" +import "github.com/deroproject/derohe/config" import "github.com/deroproject/derohe/errormsg" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/rpc" -func (DERO_RPC_APIS) GetEncryptedBalance(ctx context.Context, p structures.GetEncryptedBalance_Params) (result structures.GetEncryptedBalance_Result, err error) { +//import "github.com/deroproject/derohe/dvm" +//import "github.com/deroproject/derohe/cryptography/crypto" + +func (DERO_RPC_APIS) GetEncryptedBalance(ctx context.Context, p rpc.GetEncryptedBalance_Params) (result rpc.GetEncryptedBalance_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { err = fmt.Errorf("panic occured. stack trace %s", debug.Stack()) + fmt.Printf("panic stack trace %s\n", debug.Stack()) } }() @@ -66,33 +64,23 @@ func (DERO_RPC_APIS) GetEncryptedBalance(ctx context.Context, p structures.GetEn var balance_tree *graviton.Tree - if p.Merkle_Balance_TreeHash != "" { // user requested a specific tree hash version - - hash, err := hex.DecodeString(p.Merkle_Balance_TreeHash) - if err != nil { - panic(err) - } - - if len(hash) != 32 { - panic("corruted hash") - } - - balance_tree, err = ss.GetTreeWithRootHash(hash) - - } else { - - balance_tree, err = ss.GetTree(blockchain.BALANCE_TREE) - + treename := config.BALANCE_TREE + keyname := uaddress.Compressed() + if !p.SCID.IsZero() { + treename = string(p.SCID[:]) } - if err != nil { + + if balance_tree, err = ss.GetTree(treename); err != nil { panic(err) } - balance_serialized, err := balance_tree.Get(uaddress.Compressed()) + bits, _, balance_serialized, err := balance_tree.GetKeyValueFromKey(keyname) + + //fmt.Printf("balance_serialized %x err %s, scid %s keyname %x treename %x\n", balance_serialized,err,p.SCID, keyname, treename) if err != nil { if xerrors.Is(err, graviton.ErrNotFound) { // address needs registration - return structures.GetEncryptedBalance_Result{ // return success + return rpc.GetEncryptedBalance_Result{ // return success Registration: registration, Status: errormsg.ErrAccountUnregistered.Error(), }, errormsg.ErrAccountUnregistered @@ -101,7 +89,7 @@ func (DERO_RPC_APIS) GetEncryptedBalance(ctx context.Context, p structures.GetEn panic(err) } } - merkle_hash, err := balance_tree.Hash() + merkle_hash, err := chain.Load_Merkle_Hash(topoheight) if err != nil { panic(err) } @@ -109,29 +97,15 @@ func (DERO_RPC_APIS) GetEncryptedBalance(ctx context.Context, p structures.GetEn // calculate top height merkle tree hash //var dmerkle_hash crypto.Hash - toporecord, err = chain.Store.Topo_store.Read(chain.Load_TOPO_HEIGHT()) + dmerkle_hash, err := chain.Load_Merkle_Hash(chain.Load_TOPO_HEIGHT()) if err != nil { panic(err) } - ss, err = chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version) - if err != nil { - panic(err) - } - - balance_tree, err = ss.GetTree(blockchain.BALANCE_TREE) - if err != nil { - panic(err) - } - - dmerkle_hash, err := balance_tree.Hash() - if err != nil { - panic(err) - } - - return structures.GetEncryptedBalance_Result{ // return success + return rpc.GetEncryptedBalance_Result{ // return success Data: fmt.Sprintf("%x", balance_serialized), Registration: registration, + Bits: bits, // no. of bbits required Height: toporecord.Height, Topoheight: topoheight, BlockHash: fmt.Sprintf("%x", toporecord.BLOCK_ID), @@ -144,7 +118,7 @@ func (DERO_RPC_APIS) GetEncryptedBalance(ctx context.Context, p structures.GetEn } // if address is unregistered, returns negative numbers -func LocatePointOfRegistration(uaddress *address.Address) int64 { +func LocatePointOfRegistration(uaddress *rpc.Address) int64 { addr := uaddress.Compressed() @@ -192,7 +166,7 @@ func IsRegisteredAtTopoHeight(addr []byte, topoheight int64) bool { } var balance_tree *graviton.Tree - balance_tree, err = ss.GetTree(blockchain.BALANCE_TREE) + balance_tree, err = ss.GetTree(config.BALANCE_TREE) if err != nil { panic(err) } diff --git a/cmd/derod/rpc_dero_getheight.go b/cmd/derod/rpc_dero_getheight.go index da26341..7b6bec9 100644 --- a/cmd/derod/rpc_dero_getheight.go +++ b/cmd/derod/rpc_dero_getheight.go @@ -17,14 +17,10 @@ package main import "context" +import "github.com/deroproject/derohe/rpc" -//import "log" -//import "net/http" - -import "github.com/deroproject/derohe/structures" - -func (DERO_RPC_APIS) GetHeight(ctx context.Context) structures.Daemon_GetHeight_Result { - return structures.Daemon_GetHeight_Result{ +func (DERO_RPC_APIS) GetHeight(ctx context.Context) rpc.Daemon_GetHeight_Result { + return rpc.Daemon_GetHeight_Result{ Height: uint64(chain.Get_Height()), StableHeight: chain.Get_Stable_Height(), TopoHeight: chain.Load_TOPO_HEIGHT(), diff --git a/cmd/derod/rpc_dero_getinfo.go b/cmd/derod/rpc_dero_getinfo.go index ce6a6c7..abac92f 100644 --- a/cmd/derod/rpc_dero_getinfo.go +++ b/cmd/derod/rpc_dero_getinfo.go @@ -17,20 +17,15 @@ package main import "fmt" - -//import "time" import "context" import "runtime/debug" - -//import "log" -//import "net/http" - import "github.com/deroproject/derohe/config" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/structures" -import "github.com/deroproject/derohe/blockchain" +import "github.com/deroproject/derohe/rpc" -func (DERO_RPC_APIS) GetInfo(ctx context.Context) (result structures.GetInfo_Result, err error) { +//import "github.com/deroproject/derohe/blockchain" + +func (DERO_RPC_APIS) GetInfo(ctx context.Context) (result rpc.GetInfo_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { @@ -44,28 +39,11 @@ func (DERO_RPC_APIS) GetInfo(ctx context.Context) (result structures.GetInfo_Res result.TopoHeight = chain.Load_TOPO_HEIGHT() { - - toporecord, err := chain.Store.Topo_store.Read(result.TopoHeight) - - //fmt.Printf("current block %d previous topo %d record %+v err %s\n", i+base_topo_index, i+base_topo_index-1, toporecord,err) + balance_merkle_hash, err := chain.Load_Merkle_Hash(result.TopoHeight) if err != nil { panic(err) } - ss, err := chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version) - if err != nil { - panic(err) - } - - balance_tree, err := ss.GetTree(blockchain.BALANCE_TREE) - if err != nil { - panic(err) - } - merkle_hash, err := balance_tree.Hash() - if err != nil { - panic(err) - } - result.Merkle_Balance_TreeHash = fmt.Sprintf("%X", merkle_hash[:]) - + result.Merkle_Balance_TreeHash = fmt.Sprintf("%X", balance_merkle_hash[:]) } blid, err := chain.Load_Block_Topological_order_at_index(result.TopoHeight) @@ -78,7 +56,7 @@ func (DERO_RPC_APIS) GetInfo(ctx context.Context) (result structures.GetInfo_Res result.Top_block_hash = blid.String() result.Target = chain.Get_Current_BlockTime() - if result.TopoHeight > 50 { + if result.TopoHeight-chain.LocatePruneTopo() > 100 { blid50, err := chain.Load_Block_Topological_order_at_index(result.TopoHeight - 50) if err == nil { now := chain.Load_Block_Timestamp(blid) diff --git a/cmd/derod/rpc_dero_getrandomaddress.go b/cmd/derod/rpc_dero_getrandomaddress.go index fb04563..a00769a 100644 --- a/cmd/derod/rpc_dero_getrandomaddress.go +++ b/cmd/derod/rpc_dero_getrandomaddress.go @@ -17,18 +17,16 @@ package main import "fmt" - import "context" import "runtime/debug" - import "github.com/deroproject/derohe/config" import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/address" -import "github.com/deroproject/derohe/structures" -import "github.com/deroproject/derohe/blockchain" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/rpc" -func (DERO_RPC_APIS) GetRandomAddress(ctx context.Context) (result structures.GetRandomAddress_Result, err error) { +//import "github.com/deroproject/derohe/blockchain" + +func (DERO_RPC_APIS) GetRandomAddress(ctx context.Context, p rpc.GetRandomAddress_Params) (result rpc.GetRandomAddress_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { err = fmt.Errorf("panic occured. stack trace %s", debug.Stack()) @@ -54,7 +52,12 @@ func (DERO_RPC_APIS) GetRandomAddress(ctx context.Context) (result structures.Ge panic(err) } - balance_tree, err := ss.GetTree(blockchain.BALANCE_TREE) + treename := config.BALANCE_TREE + if p.SCID.IsZero() { + treename = string(p.SCID[:]) + } + + balance_tree, err := ss.GetTree(treename) if err != nil { panic(err) } @@ -70,10 +73,10 @@ func (DERO_RPC_APIS) GetRandomAddress(ctx context.Context) (result structures.Ge var acckey crypto.Point if err := acckey.DecodeCompressed(k[:]); err != nil { - panic(err) + continue } - addr := address.NewAddressFromKeys(&acckey) + addr := rpc.NewAddressFromKeys(&acckey) addr.Mainnet = true if globals.Config.Name != config.Mainnet.Name { // anything other than mainnet is testnet at this point in time addr.Mainnet = false diff --git a/cmd/derod/rpc_dero_getsc.go b/cmd/derod/rpc_dero_getsc.go new file mode 100644 index 0000000..36f4bfe --- /dev/null +++ b/cmd/derod/rpc_dero_getsc.go @@ -0,0 +1,165 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package main + +import "fmt" +import "context" + +//import "encoding/hex" +import "runtime/debug" + +//import "github.com/romana/rlog" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/rpc" +import "github.com/deroproject/derohe/dvm" + +//import "github.com/deroproject/derohe/transaction" +import "github.com/deroproject/derohe/blockchain" + +import "github.com/deroproject/graviton" + +func (DERO_RPC_APIS) GetSC(ctx context.Context, p rpc.GetSC_Params) (result rpc.GetSC_Result, err error) { + + defer func() { // safety so if anything wrong happens, we return error + if r := recover(); r != nil { + err = fmt.Errorf("panic occured. stack trace %s", debug.Stack()) + } + }() + + scid := crypto.HashHexToHash(p.SCID) + + topoheight := chain.Load_TOPO_HEIGHT() + + if p.TopoHeight >= 1 { + topoheight = p.TopoHeight + } + + toporecord, err := chain.Store.Topo_store.Read(topoheight) + // we must now fill in compressed ring members + if err == nil { + var ss *graviton.Snapshot + ss, err = chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version) + if err == nil { + var sc_meta_tree *graviton.Tree + if sc_meta_tree, err = ss.GetTree(config.SC_META); err == nil { + var meta_bytes []byte + if meta_bytes, err = sc_meta_tree.Get(blockchain.SC_Meta_Key(scid)); err == nil { + var meta blockchain.SC_META_DATA + if err = meta.UnmarshalBinary(meta_bytes); err == nil { + result.Balance = meta.Balance + } + } + } else { + return + } + + if sc_data_tree, err := ss.GetTree(string(scid[:])); err == nil { + if p.Code { // give SC code + var code_bytes []byte + var v dvm.Variable + if code_bytes, err = sc_data_tree.Get(blockchain.SC_Code_Key(scid)); err == nil { + if err = v.UnmarshalBinary(code_bytes); err != nil { + result.Code = "Unmarshal error" + } else { + result.Code = v.Value.(string) + } + } + } + + // give any uint64 keys data if any + for _, value := range p.KeysUint64 { + var v dvm.Variable + key, _ := dvm.Variable{Type: dvm.Uint64, Value: value}.MarshalBinary() + + var value_bytes []byte + if value_bytes, err = sc_data_tree.Get(key); err != nil { + result.ValuesUint64 = append(result.ValuesUint64, fmt.Sprintf("NOT AVAILABLE err: %s", err)) + continue + } + if err = v.UnmarshalBinary(value_bytes); err != nil { + result.ValuesUint64 = append(result.ValuesUint64, "Unmarshal error") + continue + } + switch v.Type { + case dvm.Uint64: + result.ValuesUint64 = append(result.ValuesUint64, fmt.Sprintf("%d", v.Value)) + case dvm.String: + result.ValuesUint64 = append(result.ValuesUint64, fmt.Sprintf("%s", v.Value)) + default: + result.ValuesUint64 = append(result.ValuesUint64, "UNKNOWN Data type") + } + } + for _, value := range p.KeysString { + var v dvm.Variable + key, _ := dvm.Variable{Type: dvm.String, Value: value}.MarshalBinary() + + var value_bytes []byte + if value_bytes, err = sc_data_tree.Get(key); err != nil { + fmt.Printf("Getting key %x\n", key) + result.ValuesString = append(result.ValuesString, fmt.Sprintf("NOT AVAILABLE err: %s", err)) + continue + } + if err = v.UnmarshalBinary(value_bytes); err != nil { + result.ValuesString = append(result.ValuesString, "Unmarshal error") + continue + } + switch v.Type { + case dvm.Uint64: + result.ValuesString = append(result.ValuesUint64, fmt.Sprintf("%d", v.Value)) + case dvm.String: + result.ValuesString = append(result.ValuesString, fmt.Sprintf("%s", v.Value)) + default: + result.ValuesString = append(result.ValuesString, "UNKNOWN Data type") + } + } + + for _, value := range p.KeysBytes { + var v dvm.Variable + key, _ := dvm.Variable{Type: dvm.String, Value: string(value)}.MarshalBinary() + + var value_bytes []byte + if value_bytes, err = sc_data_tree.Get(key); err != nil { + result.ValuesBytes = append(result.ValuesBytes, "NOT AVAILABLE") + continue + } + if err = v.UnmarshalBinary(value_bytes); err != nil { + result.ValuesBytes = append(result.ValuesBytes, "Unmarshal error") + continue + } + switch v.Type { + case dvm.Uint64: + result.ValuesBytes = append(result.ValuesBytes, fmt.Sprintf("%d", v.Value)) + case dvm.String: + result.ValuesBytes = append(result.ValuesBytes, fmt.Sprintf("%s", v.Value)) + default: + result.ValuesBytes = append(result.ValuesBytes, "UNKNOWN Data type") + } + } + + } + + } + + } + + result.Status = "OK" + err = nil + + //logger.Debugf("result %+v\n", result); + return +} diff --git a/cmd/derod/rpc_dero_gettransactions.go b/cmd/derod/rpc_dero_gettransactions.go index 52594ae..c0b024e 100644 --- a/cmd/derod/rpc_dero_gettransactions.go +++ b/cmd/derod/rpc_dero_gettransactions.go @@ -22,15 +22,14 @@ import "encoding/hex" import "runtime/debug" //import "github.com/romana/rlog" -//import "github.com/vmihailenco/msgpack" - -import "github.com/deroproject/derohe/crypto" - -//import "github.com/deroproject/derohe/globals" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/rpc" import "github.com/deroproject/derohe/transaction" +import "github.com/deroproject/derohe/blockchain" +import "github.com/deroproject/graviton" -func (DERO_RPC_APIS) GetTransaction(ctx context.Context, p structures.GetTransaction_Params) (result structures.GetTransaction_Result, err error) { +func (DERO_RPC_APIS) GetTransaction(ctx context.Context, p rpc.GetTransaction_Params) (result rpc.GetTransaction_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { @@ -48,7 +47,7 @@ func (DERO_RPC_APIS) GetTransaction(ctx context.Context, p structures.GetTransac // logger.Debugf("checking tx in pool %+v", tx); if tx != nil { // found the tx in the mempool - var related structures.Tx_Related_Info + var related rpc.Tx_Related_Info related.Block_Height = -1 // not mined related.In_pool = true @@ -63,8 +62,11 @@ func (DERO_RPC_APIS) GetTransaction(ctx context.Context, p structures.GetTransac { // check if tx is from blockchain var tx transaction.Transaction var tx_bytes []byte - if tx_bytes, err = chain.Store.Block_tx_store.ReadTX(hash); err != nil { - return + if tx_bytes, err = chain.Store.Block_tx_store.ReadTX(hash); err != nil { // if tx not found return empty rpc + var related rpc.Tx_Related_Info + result.Txs_as_hex = append(result.Txs_as_hex, "") // a not found tx will return "" + result.Txs = append(result.Txs, related) + continue } else { //fmt.Printf("txhash %s loaded %d bytes\n", hash, len(tx_bytes)) @@ -75,7 +77,7 @@ func (DERO_RPC_APIS) GetTransaction(ctx context.Context, p structures.GetTransac } if err == nil { - var related structures.Tx_Related_Info + var related rpc.Tx_Related_Info // check whether tx is orphan @@ -100,8 +102,69 @@ func (DERO_RPC_APIS) GetTransaction(ctx context.Context, p structures.GetTransac if valid { related.ValidBlock = valid_blid.String() // topo height at which it was mined - related.Block_Height = int64(chain.Load_Block_Topological_order(valid_blid)) + topo_height := int64(chain.Load_Block_Topological_order(valid_blid)) + related.Block_Height = topo_height + if tx.TransactionType != transaction.REGISTRATION { + // we must now fill in compressed ring members + if toporecord, err := chain.Store.Topo_store.Read(topo_height); err == nil { + if ss, err := chain.Store.Balance_store.LoadSnapshot(toporecord.State_Version); err == nil { + + if tx.TransactionType == transaction.SC_TX { + scid := tx.GetHash() + if tx.SCDATA.Has(rpc.SCACTION, rpc.DataUint64) && rpc.SC_INSTALL == rpc.SC_ACTION(tx.SCDATA.Value(rpc.SCACTION, rpc.DataUint64).(uint64)) { + if sc_meta_tree, err := ss.GetTree(config.SC_META); err == nil { + var meta_bytes []byte + if meta_bytes, err = sc_meta_tree.Get(blockchain.SC_Meta_Key(scid)); err == nil { + var meta blockchain.SC_META_DATA // the meta contains the link to the SC bytes + if err = meta.UnmarshalBinary(meta_bytes); err == nil { + related.Balance = meta.Balance + } + } + } + if sc_data_tree, err := ss.GetTree(string(scid[:])); err == nil { + var code_bytes []byte + if code_bytes, err = sc_data_tree.Get(blockchain.SC_Code_Key(scid)); err == nil { + related.Code = string(code_bytes) + + } + + } + + } + } + + for t := range tx.Payloads { + var ring [][]byte + + var tree *graviton.Tree + + if tx.Payloads[t].SCID.IsZero() { + tree, err = ss.GetTree(config.BALANCE_TREE) + + } else { + tree, err = ss.GetTree(string(tx.Payloads[t].SCID[:])) + } + + if err != nil { + fmt.Printf("no such SC %s\n", tx.Payloads[t].SCID) + } + + for j := 0; j < int(tx.Payloads[t].Statement.RingSize); j++ { + key_pointer := tx.Payloads[t].Statement.Publickeylist_pointers[j*int(tx.Payloads[t].Statement.Bytes_per_publickey) : (j+1)*int(tx.Payloads[t].Statement.Bytes_per_publickey)] + _, key_compressed, _, err := tree.GetKeyValueFromHash(key_pointer) + if err == nil { + ring = append(ring, key_compressed) + } else { // we should some how report error + fmt.Printf("Error expanding member for txid %s t %d err %s key_compressed %x\n", hash, t, err, key_compressed) + } + } + related.Ring = append(related.Ring, ring) + } + + } + } + } } for i := range invalid_blid { related.InvalidBlock = append(related.InvalidBlock, invalid_blid[i].String()) @@ -125,6 +188,6 @@ func (DERO_RPC_APIS) GetTransaction(ctx context.Context, p structures.GetTransac result.Status = "OK" err = nil - //logger.Debugf("result %+v\n", result); + logger.Debugf("result %+v\n", result) return } diff --git a/cmd/derod/rpc_dero_gettxpool.go b/cmd/derod/rpc_dero_gettxpool.go index f2c267a..7a216b6 100644 --- a/cmd/derod/rpc_dero_gettxpool.go +++ b/cmd/derod/rpc_dero_gettxpool.go @@ -18,10 +18,9 @@ package main import "fmt" import "context" +import "github.com/deroproject/derohe/rpc" -import "github.com/deroproject/derohe/structures" - -func (DERO_RPC_APIS) GetTxPool(ctx context.Context) (result structures.GetTxPool_Result) { +func (DERO_RPC_APIS) GetTxPool(ctx context.Context) (result rpc.GetTxPool_Result) { result.Status = "OK" pool_list := chain.Mempool.Mempool_List_TX() diff --git a/cmd/derod/rpc_dero_sendrawtransaction.go b/cmd/derod/rpc_dero_sendrawtransaction.go index f5d3396..c92b0f8 100644 --- a/cmd/derod/rpc_dero_sendrawtransaction.go +++ b/cmd/derod/rpc_dero_sendrawtransaction.go @@ -20,14 +20,12 @@ import "fmt" import "context" import "encoding/hex" import "runtime/debug" - import "github.com/romana/rlog" - -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/rpc" import "github.com/deroproject/derohe/transaction" //NOTE: finally we have shifted to json api -func (DERO_RPC_APIS) SendRawTransaction(ctx context.Context, p structures.SendRawTransaction_Params) (result structures.SendRawTransaction_Result, err error) { +func (DERO_RPC_APIS) SendRawTransaction(ctx context.Context, p rpc.SendRawTransaction_Params) (result rpc.SendRawTransaction_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { @@ -61,15 +59,12 @@ func (DERO_RPC_APIS) SendRawTransaction(ctx context.Context, p structures.SendRa rlog.Debugf("Incoming TXID %s from RPC Server", tx.GetHash()) // lets try to add it to pool - success := chain.Add_TX_To_Pool(&tx) - if success { + if err = chain.Add_TX_To_Pool(&tx); err == nil { result.Status = "OK" - err = nil rlog.Debugf("Incoming TXID %s from RPC Server successfully accepted by MEMPOOL", tx.GetHash()) } else { - - err = fmt.Errorf("Transaction %s rejected by daemon, check daemon msgs", tx.GetHash()) + err = fmt.Errorf("Transaction %s rejected by daemon err '%s'", tx.GetHash(), err) rlog.Warnf("Incoming TXID %s from RPC Server rejected by POOL", tx.GetHash()) } return diff --git a/cmd/derod/rpc_dero_submitblock.go b/cmd/derod/rpc_dero_submitblock.go index a220760..009090e 100644 --- a/cmd/derod/rpc_dero_submitblock.go +++ b/cmd/derod/rpc_dero_submitblock.go @@ -20,10 +20,9 @@ import "fmt" import "context" import "encoding/hex" import "runtime/debug" +import "github.com/deroproject/derohe/rpc" -import "github.com/deroproject/derohe/structures" - -func (DERO_RPC_APIS) SubmitBlock(ctx context.Context, block_data [2]string) (result structures.SubmitBlock_Result, err error) { +func (DERO_RPC_APIS) SubmitBlock(ctx context.Context, block_data [2]string) (result rpc.SubmitBlock_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { @@ -47,7 +46,7 @@ func (DERO_RPC_APIS) SubmitBlock(ctx context.Context, block_data [2]string) (res if sresult { logger.Infof("Submitted block %s accepted", blid) - return structures.SubmitBlock_Result{ + return rpc.SubmitBlock_Result{ BLID: blid.String(), Status: "OK", }, nil @@ -59,7 +58,7 @@ func (DERO_RPC_APIS) SubmitBlock(ctx context.Context, block_data [2]string) (res } logger.Infof("Submitting block rejected err %s", err) - return structures.SubmitBlock_Result{ + return rpc.SubmitBlock_Result{ Status: "REJECTED", }, nil diff --git a/cmd/derod/rpc_get_getlastblockheader.go b/cmd/derod/rpc_get_getlastblockheader.go index 8fe038b..d43f28a 100644 --- a/cmd/derod/rpc_get_getlastblockheader.go +++ b/cmd/derod/rpc_get_getlastblockheader.go @@ -21,9 +21,9 @@ package main import "fmt" import "context" import "runtime/debug" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/rpc" -func (DERO_RPC_APIS) GetLastBlockHeader(ctx context.Context) (result structures.GetLastBlockHeader_Result, err error) { +func (DERO_RPC_APIS) GetLastBlockHeader(ctx context.Context) (result rpc.GetLastBlockHeader_Result, err error) { defer func() { // safety so if anything wrong happens, we return error if r := recover(); r != nil { err = fmt.Errorf("panic occured. stack trace %s", debug.Stack()) @@ -35,7 +35,7 @@ func (DERO_RPC_APIS) GetLastBlockHeader(ctx context.Context) (result structures. return } - return structures.GetLastBlockHeader_Result{ + return rpc.GetLastBlockHeader_Result{ Block_Header: block_header, Status: "OK", }, nil diff --git a/cmd/derod/websocket_server.go b/cmd/derod/websocket_server.go index 84d0a5b..cbf0d0b 100644 --- a/cmd/derod/websocket_server.go +++ b/cmd/derod/websocket_server.go @@ -136,65 +136,6 @@ func (r *RPCServer) RPCServer_Stop() { // setup handlers func (r *RPCServer) Run() { - /* - mr := jsonrpc.NewMethodRepository() - - if err := mr.RegisterMethod("Main.Echo", EchoHandler{}, EchoParams{}, EchoResult{}); err != nil { - log.Fatalln(err) - } - - // install getblockcount handler - if err := mr.RegisterMethod("getblockcount", GetBlockCount_Handler{}, structures.GetBlockCount_Params{}, structures.GetBlockCount_Result{}); err != nil { - log.Fatalln(err) - } - - // install on_getblockhash - if err := mr.RegisterMethod("on_getblockhash", On_GetBlockHash_Handler{}, structures.On_GetBlockHash_Params{}, structures.On_GetBlockHash_Result{}); err != nil { - log.Fatalln(err) - } - - // install getblocktemplate handler - //if err := mr.RegisterMethod("getblocktemplate", GetBlockTemplate_Handler{}, structures.GetBlockTemplate_Params{}, structures.GetBlockTemplate_Result{}); err != nil { - // log.Fatalln(err) - //} - - // submitblock handler - if err := mr.RegisterMethod("submitblock", SubmitBlock_Handler{}, structures.SubmitBlock_Params{}, structures.SubmitBlock_Result{}); err != nil { - log.Fatalln(err) - } - - if err := mr.RegisterMethod("getlastblockheader", GetLastBlockHeader_Handler{}, structures.GetLastBlockHeader_Params{}, structures.GetLastBlockHeader_Result{}); err != nil { - log.Fatalln(err) - } - - if err := mr.RegisterMethod("getblockheaderbyhash", GetBlockHeaderByHash_Handler{}, structures.GetBlockHeaderByHash_Params{}, structures.GetBlockHeaderByHash_Result{}); err != nil { - log.Fatalln(err) - } - - //if err := mr.RegisterMethod("getblockheaderbyheight", GetBlockHeaderByHeight_Handler{}, structures.GetBlockHeaderByHeight_Params{}, structures.GetBlockHeaderByHeight_Result{}); err != nil { - // log.Fatalln(err) - //} - - if err := mr.RegisterMethod("getblockheaderbytopoheight", GetBlockHeaderByTopoHeight_Handler{}, structures.GetBlockHeaderByTopoHeight_Params{}, structures.GetBlockHeaderByHeight_Result{}); err != nil { - log.Fatalln(err) - } - - if err := mr.RegisterMethod("getblock", GetBlock_Handler{}, structures.GetBlock_Params{}, structures.GetBlock_Result{}); err != nil { - log.Fatalln(err) - } - - if err := mr.RegisterMethod("get_info", GetInfo_Handler{}, structures.GetInfo_Params{}, structures.GetInfo_Result{}); err != nil { - log.Fatalln(err) - } - - if err := mr.RegisterMethod("getencryptedbalance", GetEncryptedBalance_Handler{}, structures.GetEncryptedBalance_Params{}, structures.GetEncryptedBalance_Result{}); err != nil { - log.Fatalln(err) - } - - if err := mr.RegisterMethod("gettxpool", GetTxPool_Handler{}, structures.GetTxPool_Params{}, structures.GetTxPool_Result{}); err != nil { - log.Fatalln(err) - } - */ // create a new mux r.mux = http.NewServeMux() @@ -344,7 +285,8 @@ var historical_apis = handler.Map{"getinfo": handler.New(dero_apis.GetInfo), "getblockcount": handler.New(dero_apis.GetBlockCount), "getlastblockheader": handler.New(dero_apis.GetLastBlockHeader), "getblocktemplate": handler.New(dero_apis.GetBlockTemplate), - "getencryptedbalance": handler.New(dero_apis.GetEncryptedBalance)} + "getencryptedbalance": handler.New(dero_apis.GetEncryptedBalance), + "getsc": handler.New(dero_apis.GetSC)} func translate_http_to_jsonrpc_and_vice_versa(w http.ResponseWriter, r *http.Request) { bridge.ServeHTTP(w, r) diff --git a/cmd/explorer/explorer.go b/cmd/explorer/explorer.go index cdabc83..c27d503 100644 --- a/cmd/explorer/explorer.go +++ b/cmd/explorer/explorer.go @@ -20,9 +20,6 @@ package main // this needs only RPC access // NOTE: Only use data exported from within the RPC interface, do direct use of exported variables fom packages // NOTE: we can use structs defined within the RPCserver package -// This is being developed to track down and confirm some bugs -// NOTE: This is NO longer entirely compliant with the xyz RPC interface ( the pool part is not compliant), currently and can be used as it for their chain, -// atleast for the last 1 year // TODO: error handling is non-existant ( as this was built up in hrs ). Add proper error handling // @@ -31,7 +28,9 @@ import "time" import "fmt" //import "net" -//import "bytes" +import "bytes" +import "unicode" +import "unsafe" // need to avoid this, but only used by byteviewer import "strings" import "strconv" import "context" @@ -48,11 +47,11 @@ import log "github.com/sirupsen/logrus" //import "github.com/ybbus/jsonrpc" import "github.com/deroproject/derohe/block" -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/address" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/cryptography/bn256" import "github.com/deroproject/derohe/globals" import "github.com/deroproject/derohe/transaction" -import "github.com/deroproject/derohe/structures" +import "github.com/deroproject/derohe/rpc" import "github.com/deroproject/derohe/proof" import "github.com/deroproject/derohe/glue/rwc" @@ -164,7 +163,7 @@ func Connect() (err error) { fmt.Printf("Ping Received %s\n", result) } - var info structures.GetInfo_Result + var info rpc.GetInfo_Result // collect all the data afresh, execute rpc to service if err = rpc_client.Call("DERO.GetInfo", nil, &info); err != nil { @@ -248,6 +247,7 @@ type txinfo struct { Version int // version of tx Size string // size of tx in KB Sizeuint64 uint64 // size of tx in bytes + Burn_Value string // value of burned amount Fee string // fee in TX Feeuint64 uint64 // fee in atomic units In int // inputs counts @@ -263,18 +263,37 @@ type txinfo struct { InvalidBlock []string // the tx is invalid in which block Skipped bool // this is only valid, when a block is being listed Ring_size int - //Ring [][]globals.TX_Output_Data + Ring [][][]byte // contains entire ring in raw form TXpublickey string PayID32 string // 32 byte payment ID PayID8 string // 8 byte encrypted payment ID - Proof_address string // address agains which which the proving ran - Proof_index int64 // proof satisfied for which index - Proof_amount string // decoded amount - Proof_PayID8 string // decrypted 8 byte payment id - Proof_error string // error if any while decoding proof + Proof_address string // address agains which which the proving ran + Proof_index int64 // proof satisfied for which index + Proof_amount string // decoded amount + Proof_Payload_raw string // payload raw bytes + Proof_Payload string // if proof decoded, decoded , else decode error + Proof_error string // error if any while decoding proof + SC_TX_Available string //bool // whether this contains an SC TX + SC_Signer string // whether SC signer + SC_Signer_verified string // whether SC signer can be verified successfully + SC_Balance uint64 // SC SC_Balance in atomic units + SC_Balance_string string // SC_Balance in DERO + SC_Keys map[string]string // SC key value of + SC_Args rpc.Arguments // rpc.Arguments + SC_Code string // install SC + + Assets []Asset +} + +type Asset struct { + SCID crypto.Hash + Fees string + Burn string + Ring []string + Ring_size int } // any information for block which needs to be printed @@ -306,7 +325,7 @@ type block_info struct { // if hash is less than 64 bytes then it is considered a height parameter func load_block_from_rpc(info *block_info, block_hash string, recursive bool) (err error) { var bl block.Block - var bresult structures.GetBlock_Result + var bresult rpc.GetBlock_Result var block_height int var block_bin []byte @@ -314,7 +333,7 @@ func load_block_from_rpc(info *block_info, block_hash string, recursive bool) (e fmt.Sscanf(block_hash, "%d", &block_height) // user requested block height log.Debugf("User requested block at topoheight %d user input %s", block_height, block_hash) - if err = rpc_client.Call("DERO.GetBlock", structures.GetBlock_Params{Height: uint64(block_height)}, &bresult); err != nil { + if err = rpc_client.Call("DERO.GetBlock", rpc.GetBlock_Params{Height: uint64(block_height)}, &bresult); err != nil { return fmt.Errorf("getblock rpc failed") } @@ -322,7 +341,7 @@ func load_block_from_rpc(info *block_info, block_hash string, recursive bool) (e log.Debugf("User requested block using hash %s", block_hash) - if err = rpc_client.Call("DERO.GetBlock", structures.GetBlock_Params{Hash: block_hash}, &bresult); err != nil { + if err = rpc_client.Call("DERO.GetBlock", rpc.GetBlock_Params{Hash: block_hash}, &bresult); err != nil { return fmt.Errorf("getblock rpc failed") } } @@ -405,11 +424,18 @@ func load_tx_info_from_tx(info *txinfo, tx *transaction.Transaction) (err error) info.Sizeuint64 = uint64(len(tx.Serialize())) info.Version = int(tx.Version) //info.Extra = fmt.Sprintf("%x", tx.Extra) - info.RootHash = fmt.Sprintf("%x", tx.Statement.Roothash[:]) + + if len(tx.Payloads) >= 1 { + info.RootHash = fmt.Sprintf("%x", tx.Payloads[0].Statement.Roothash[:]) + } info.HeightBuilt = tx.Height //info.In = len(tx.Vin) //info.Out = len(tx.Vout) + if tx.TransactionType == transaction.BURN_TX { + info.Burn_Value = fmt.Sprintf(" %.05f", float64(tx.Value)/100000) + } + switch tx.TransactionType { case transaction.PREMINE: @@ -418,7 +444,7 @@ func load_tx_info_from_tx(info *txinfo, tx *transaction.Transaction) (err error) panic(err) } - astring := address.NewAddressFromKeys(&acckey) + astring := rpc.NewAddressFromKeys(&acckey) astring.Mainnet = mainnet info.OutAddress = append(info.OutAddress, astring.String()) info.Amount = globals.FormatMoney(tx.Value) @@ -429,7 +455,7 @@ func load_tx_info_from_tx(info *txinfo, tx *transaction.Transaction) (err error) panic(err) } - astring := address.NewAddressFromKeys(&acckey) + astring := rpc.NewAddressFromKeys(&acckey) astring.Mainnet = mainnet info.OutAddress = append(info.OutAddress, astring.String()) @@ -440,23 +466,15 @@ func load_tx_info_from_tx(info *txinfo, tx *transaction.Transaction) (err error) if err := acckey.DecodeCompressed(tx.MinerAddress[:]); err != nil { panic(err) } - astring := address.NewAddressFromKeys(&acckey) + astring := rpc.NewAddressFromKeys(&acckey) astring.Mainnet = mainnet info.OutAddress = append(info.OutAddress, astring.String()) - case transaction.NORMAL: + case transaction.NORMAL, transaction.BURN_TX, transaction.SC_TX: - info.Fee = fmt.Sprintf("%.05f", float64(tx.Statement.Fees)/100000) - info.Feeuint64 = tx.Statement.Fees - info.Amount = "?" + } - info.Ring_size = len(tx.Statement.Publickeylist_compressed) //len(tx.Vin[0].(transaction.Txin_to_key).Key_offsets) - - for i := range tx.Statement.Publickeylist { - astring := address.NewAddressFromKeys((*crypto.Point)(tx.Statement.Publickeylist[i])) - astring.Mainnet = mainnet - info.OutAddress = append(info.OutAddress, astring.String()) - - } + if tx.TransactionType == transaction.SC_TX { + info.SC_Args = tx.SCDATA } // if outputs cannot be located, do not panic @@ -468,21 +486,11 @@ func load_tx_info_from_tx(info *txinfo, tx *transaction.Transaction) (err error) switch 0 { case 0: info.Type = "DERO_HOMOMORPHIC" - /*case 1: - info.Type = "RingCT/1 MG" - case 2: - info.Type = "RingCT/2 Simple" - case 3: - info.Type = "RingCT/3 Full bulletproof" - case 4: - info.Type = "RingCT/4 Simple Bulletproof" - */ - default: - panic("not implement") + panic("not implemented") } - if !info.In_Pool && !info.CoinBase && tx.TransactionType == transaction.NORMAL { // find the age of block and other meta + if !info.In_Pool && !info.CoinBase && (tx.TransactionType == transaction.NORMAL || tx.TransactionType == transaction.BURN_TX || tx.TransactionType == transaction.SC_TX) { // find the age of block and other meta var blinfo block_info err := load_block_from_rpc(&blinfo, fmt.Sprintf("%s", info.Height), false) // we only need block data and not data of txs if err != nil { @@ -504,8 +512,8 @@ func load_tx_info_from_tx(info *txinfo, tx *transaction.Transaction) (err error) // load and setup txinfo from rpc func load_tx_from_rpc(info *txinfo, txhash string) (err error) { - var tx_params structures.GetTransaction_Params - var tx_result structures.GetTransaction_Result + var tx_params rpc.GetTransaction_Params + var tx_result rpc.GetTransaction_Result //fmt.Printf("Requesting tx data %s", txhash); tx_params.Tx_Hashes = append(tx_params.Tx_Hashes, txhash) @@ -541,13 +549,46 @@ func load_tx_from_rpc(info *txinfo, txhash string) (err error) { } if tx.IsCoinbase() { // fill miner tx reward from what the chain tells us - info.Amount = fmt.Sprintf("%.012f", float64(uint64(tx_result.Txs[0].Reward))/1000000000000) + info.Amount = fmt.Sprintf("%.05f", float64(uint64(tx_result.Txs[0].Reward))/100000) } info.ValidBlock = tx_result.Txs[0].ValidBlock info.InvalidBlock = tx_result.Txs[0].InvalidBlock - //info.Ring = tx_result.Txs[0].Ring + info.Ring = tx_result.Txs[0].Ring + + if tx.TransactionType == transaction.NORMAL || tx.TransactionType == transaction.BURN_TX || tx.TransactionType == transaction.SC_TX { + + for t := range tx.Payloads { + var a Asset + a.SCID = tx.Payloads[t].SCID + a.Fees = fmt.Sprintf("%.05f", float64(tx.Payloads[t].Statement.Fees)/100000) + a.Burn = fmt.Sprintf("%.05f", float64(tx.Payloads[t].BurnValue)/100000) + a.Ring_size = len(tx_result.Txs[0].Ring[t]) + + for i := range tx_result.Txs[0].Ring[t] { + + point_compressed := tx_result.Txs[0].Ring[t][i] + var p bn256.G1 + if err = p.DecodeCompressed(point_compressed[:]); err != nil { + continue + } + + astring := rpc.NewAddressFromKeys((*crypto.Point)(&p)) + astring.Mainnet = mainnet + a.Ring = append(a.Ring, astring.String()) + } + + info.Assets = append(info.Assets, a) + + } + //fmt.Printf("assets now %+v\n", info.Assets) + } + + info.SC_Balance = tx_result.Txs[0].Balance + info.SC_Balance_string = fmt.Sprintf("%.05f", float64(uint64(info.SC_Balance)/100000)) + info.SC_Code = tx_result.Txs[0].Code + //info.Ring = strings.Join(info.OutAddress, " ") //fmt.Printf("tx_result %+v\n",tx_result.Txs) // fmt.Printf("response contained tx %s \n", tx.GetHash()) @@ -607,14 +648,14 @@ func tx_handler(w http.ResponseWriter, r *http.Request) { if tx_proof != "" { // there may be more than 1 amounts, only first one is shown - addresses, amounts, payids, err := proof.Prove(tx_proof, info.Hex, mainnet) + addresses, amounts, raw, decoded, err := proof.Prove(tx_proof, info.Hex, info.Ring, mainnet) if err == nil { //&& len(amounts) > 0 && len(indexes) > 0{ - log.Debugf("Successfully proved transaction %s len(payids) %d", tx_hex, len(payids)) + log.Debugf("Successfully proved transaction %s len(payids) %d", tx_hex, len(decoded)) info.Proof_address = addresses[0] info.Proof_amount = globals.FormatMoney(amounts[0]) - if len(payids) >= 1 { - info.Proof_PayID8 = fmt.Sprintf("%x", payids[0]) // decrypted payment ID - } + info.Proof_Payload_raw = BytesViewer(raw[0]).String() // raw payload + info.Proof_Payload = decoded[0] + } else { log.Debugf("err while proving %s", err) if err != nil { @@ -675,7 +716,7 @@ func fill_tx_structure(pos int, size_in_blocks int) (data []block_info) { func show_page(w http.ResponseWriter, page int) { data := map[string]interface{}{} - var info structures.GetInfo_Result + var info rpc.GetInfo_Result data["title"] = "DERO HE BlockChain Explorer(v1)" data["servertime"] = time.Now().UTC().Format("2006-01-02 15:04:05") @@ -747,7 +788,7 @@ exit_error: func txpool_handler(w http.ResponseWriter, r *http.Request) { data := map[string]interface{}{} - var info structures.GetInfo_Result + var info rpc.GetInfo_Result data["title"] = "DERO HE BlockChain Explorer(v1)" data["servertime"] = time.Now().UTC().Format("2006-01-02 15:04:05") @@ -801,7 +842,7 @@ func root_handler(w http.ResponseWriter, r *http.Request) { // search handler, finds the items using rpc bruteforce func search_handler(w http.ResponseWriter, r *http.Request) { - var info structures.GetInfo_Result + var info rpc.GetInfo_Result var err error log.Debugf("Showing search page") @@ -860,7 +901,7 @@ func search_handler(w http.ResponseWriter, r *http.Request) { { // show error page data := map[string]interface{}{} - var info structures.GetInfo_Result + var info rpc.GetInfo_Result data["title"] = "DERO HE BlockChain Explorer(v1)" data["servertime"] = time.Now().UTC().Format("2006-01-02 15:04:05") @@ -901,7 +942,7 @@ func fill_tx_pool_info(data map[string]interface{}, max_count int) error { var err error var txs []txinfo - var txpool structures.GetTxPool_Result + var txpool rpc.GetTxPool_Result data["mempool"] = txs // initialize with empty data if err = rpc_client.Call("DERO.GetTxPool", nil, &txpool); err != nil { @@ -923,5 +964,56 @@ func fill_tx_pool_info(data map[string]interface{}, max_count int) error { data["mempool"] = txs return nil - +} + +// BytesViewer bytes viewer +type BytesViewer []byte + +// String returns view in hexadecimal +func (b BytesViewer) String() string { + if len(b) == 0 { + return "invlaid string" + } + const head = ` +| Address | Hex | Text | +| -------: | :---------------------------------------------- | :--------------- | +` + const row = 16 + result := make([]byte, 0, len(head)/2*(len(b)/16+3)) + result = append(result, head...) + for i := 0; i < len(b); i += row { + result = append(result, "| "...) + result = append(result, fmt.Sprintf("%08x", i)...) + result = append(result, " | "...) + + k := i + row + more := 0 + if k >= len(b) { + more = k - len(b) + k = len(b) + } + for j := i; j != k; j++ { + if b[j] < 16 { + result = append(result, '0') + } + result = strconv.AppendUint(result, uint64(b[j]), 16) + result = append(result, ' ') + } + for j := 0; j != more; j++ { + result = append(result, " "...) + } + result = append(result, "| "...) + buf := bytes.Map(func(r rune) rune { + if unicode.IsSpace(r) { + return ' ' + } + return r + }, b[i:k]) + result = append(result, buf...) + for j := 0; j != more; j++ { + result = append(result, ' ') + } + result = append(result, " |\n"...) + } + return *(*string)(unsafe.Pointer(&result)) } diff --git a/cmd/explorer/templates.go b/cmd/explorer/templates.go index f6442a3..2fcb59b 100644 --- a/cmd/explorer/templates.go +++ b/cmd/explorer/templates.go @@ -303,7 +303,10 @@ var tx_template string = `{{define "tx"}} {{ template "header" . }}

Tx hash: {{.info.Hash}} Type {{.info.TransactionType }}

-
Tx prefix hash: {{.info.PrefixHash}}
+ + {{if eq .info.TransactionType "BURN" }} +

Burns: {{.info.Burn_Value }} DERO

+ {{end}}
Block: {{.info.ValidBlock}} (VALID)
@@ -329,7 +332,7 @@ var tx_template string = `{{define "tx"}} {{end}} -{{if eq .info.TransactionType "NORMAL"}} +{{if or (eq .info.TransactionType "NORMAL") (eq .info.TransactionType "BURN") (eq .info.TransactionType "SC") }}
Tx RootHash: {{.info.RootHash}} built height : {{.info.HeightBuilt}}
@@ -360,23 +363,40 @@ var tx_template string = `{{define "tx"}} Extra: {{.info.Extra}} -

{{len .info.OutAddress}} inputs/outputs (RING size)

-
+ + {{range $ii, $ee := .info.Assets}} +
SCID: {{$ee.SCID}} {{$ee.Ring_size}} inputs/outputs (RING size) Fees {{$ee.Fees}} Burned {{$ee.Burn}}
+ +
- - {{range $i, $e := .info.OutAddress}} + {{range $i, $e := $ee.Ring}} - {{end}}
addressamount
{{ $e }}{{$.info.Amount}}
+ + {{end}} +{{if eq .info.TransactionType "SC"}} + + + + + + + + + + +
SC Balance: {{ .info.SC_Balance_string }} DERO
SC CODE:
  {{  .info.SC_Code }}
SC Arguments: {{ .info.SC_Args }}
+ +{{end}}

@@ -415,8 +435,13 @@ var tx_template string = `{{define "tx"}}

{{.info.Proof_address}} Received {{.info.Proof_amount}} DERO - {{if .info.Proof_PayID8}} -
Decrypted Payment ID {{ .info.Proof_PayID8}} + + {{if .info.Proof_Payload}} +
Decoded Data {{ .info.Proof_Payload}} + +
Raw Data +
{{ .info.Proof_Payload_raw}}
+ {{end}}

diff --git a/cmd/rpc_examples/pong_server/pong_server.go b/cmd/rpc_examples/pong_server/pong_server.go new file mode 100644 index 0000000..1d704a1 --- /dev/null +++ b/cmd/rpc_examples/pong_server/pong_server.go @@ -0,0 +1,182 @@ +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package main + +//import "os" +import "fmt" +import "time" +import "crypto/sha1" +import "github.com/romana/rlog" + +import "etcd.io/bbolt" + +import "github.com/deroproject/derohe/rpc" +import "github.com/deroproject/derohe/walletapi" +import "github.com/ybbus/jsonrpc" + +const PLUGIN_NAME = "pong_server" + +const DEST_PORT = uint64(0x1234567812345678) + +var expected_arguments = rpc.Arguments{ + {rpc.RPC_DESTINATION_PORT, rpc.DataUint64, DEST_PORT}, + // { rpc.RPC_EXPIRY , rpc.DataTime, time.Now().Add(time.Hour).UTC()}, + {rpc.RPC_COMMENT, rpc.DataString, "Purchase PONG"}, + //{"float64", rpc.DataFloat64, float64(0.12345)}, // in atomic units + {rpc.RPC_VALUE_TRANSFER, rpc.DataUint64, uint64(12345)}, // in atomic units + +} + +// currently the interpreter seems to have a glitch if this gets initialized within the code +// see limitations github.com/traefik/yaegi +var response = rpc.Arguments{ + {rpc.RPC_DESTINATION_PORT, rpc.DataUint64, uint64(0)}, + {rpc.RPC_SOURCE_PORT, rpc.DataUint64, DEST_PORT}, + {rpc.RPC_COMMENT, rpc.DataString, "Successfully purchased pong (this could be serial/license key or download link or further)"}, +} + +var rpcClient = jsonrpc.NewClient("http://127.0.0.1:40403/json_rpc") + +// empty place holder + +func main() { + var err error + fmt.Printf("Pong Server to demonstrate RPC over dero chain.\n") + var addr *rpc.Address + var addr_result rpc.GetAddress_Result + err = rpcClient.CallFor(&addr_result, "GetAddress") + if err != nil || addr_result.Address == "" { + fmt.Printf("Could not obtain address from wallet err %s\n", err) + return + } + + if addr, err = rpc.NewAddress(addr_result.Address); err != nil { + fmt.Printf("address could not be parsed: addr:%s err:%s\n", addr_result.Address, err) + return + } + + shasum := fmt.Sprintf("%x", sha1.Sum([]byte(addr.String()))) + + db_name := fmt.Sprintf("%s_%s.bbolt.db", PLUGIN_NAME, shasum) + db, err := bbolt.Open(db_name, 0600, nil) + if err != nil { + fmt.Printf("could not open db err:%s\n", err) + return + } + //defer db.Close() + + err = db.Update(func(tx *bbolt.Tx) error { + _, err := tx.CreateBucketIfNotExists([]byte("SALE")) + return err + }) + if err != nil { + fmt.Printf("err creating bucket. err %s\n", err) + } + + fmt.Printf("Persistant store created in '%s'\n", db_name) + + fmt.Printf("Wallet Address: %s\n", addr) + service_address_without_amount := addr.Clone() + service_address_without_amount.Arguments = expected_arguments[:len(expected_arguments)-1] + fmt.Printf("Integrated address to activate '%s', (without hardcoded amount) service: \n%s\n", PLUGIN_NAME, service_address_without_amount.String()) + + // service address can be created client side for now + service_address := addr.Clone() + service_address.Arguments = expected_arguments + fmt.Printf("Integrated address to activate '%s', service: \n%s\n", PLUGIN_NAME, service_address.String()) + + processing_thread(db) // rkeep processing + + //time.Sleep(time.Second) + //return +} + +func processing_thread(db *bbolt.DB) { + + var err error + + for { // currently we traverse entire history + + time.Sleep(time.Second) + + var transfers rpc.Get_Transfers_Result + err = rpcClient.CallFor(&transfers, "GetTransfers", rpc.Get_Transfers_Params{In: true, DestinationPort: DEST_PORT}) + if err != nil { + rlog.Warnf("Could not obtain gettransfers from wallet err %s\n", err) + continue + } + + for _, e := range transfers.Entries { + if e.Coinbase || !e.Incoming { // skip coinbase or outgoing, self generated transactions + continue + } + + // check whether the entry has been processed before, if yes skip it + var already_processed bool + db.View(func(tx *bbolt.Tx) error { + if b := tx.Bucket([]byte("SALE")); b != nil { + if ok := b.Get([]byte(e.TXID)); ok != nil { // if existing in bucket + already_processed = true + } + } + return nil + }) + + if already_processed { // if already processed skip it + continue + } + + // check whether this service should handle the transfer + if !e.Payload_RPC.Has(rpc.RPC_DESTINATION_PORT, rpc.DataUint64) || + DEST_PORT != e.Payload_RPC.Value(rpc.RPC_DESTINATION_PORT, rpc.DataUint64).(uint64) { // this service is expecting value to be specfic + continue + + } + + rlog.Infof("tx should be processed %s\n", e.TXID) + + if expected_arguments.Has(rpc.RPC_VALUE_TRANSFER, rpc.DataUint64) { // this service is expecting value to be specfic + value_expected := expected_arguments.Value(rpc.RPC_VALUE_TRANSFER, rpc.DataUint64).(uint64) + if e.Amount != value_expected { // TODO we should mark it as faulty + rlog.Warnf("user transferred %d, we were expecting %d. so we will not do anything\n", e.Amount, value_expected) // this is an unexpected situation + continue + } + // value received is what we are expecting, so time for response + + response[0].Value = e.SourcePort // source port now becomes destination port, similar to TCP + response[2].Value = fmt.Sprintf("Sucessfully purchased pong (could be serial, license or download link or anything).You sent %s at height %d", walletapi.FormatMoney(e.Amount), e.Height) + + //_, err := response.CheckPack(transaction.PAYLOAD0_LIMIT)) // we only have 144 bytes for RPC + + // sender of ping now becomes destination + var str string + tparams := rpc.Transfer_Params{Transfers: []rpc.Transfer{{Destination: e.Sender, Amount: uint64(1), Payload_RPC: response}}} + err = rpcClient.CallFor(&str, "Transfer", tparams) + if err != nil { + rlog.Warnf("sending reply tx err %s\n", err) + continue + } + + err = db.Update(func(tx *bbolt.Tx) error { + b := tx.Bucket([]byte("SALE")) + return b.Put([]byte(e.TXID), []byte("done")) + }) + if err != nil { + rlog.Warnf("err updating db to err %s\n", err) + } else { + rlog.Infof("ping replied successfully with pong") + } + + } + } + + } +} diff --git a/cmd/rpc_examples/readme.txt b/cmd/rpc_examples/readme.txt new file mode 100644 index 0000000..09aaa26 --- /dev/null +++ b/cmd/rpc_examples/readme.txt @@ -0,0 +1,2 @@ +Various RPC servers can be developed, which can represent various activitities not representable on any existing blockchain. + diff --git a/config/config.go b/config/config.go index 5c33e0c..2aab3d2 100644 --- a/config/config.go +++ b/config/config.go @@ -17,7 +17,7 @@ package config import "github.com/satori/go.uuid" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" // all global configuration variables are picked from here @@ -28,27 +28,12 @@ import "github.com/deroproject/derohe/crypto" // since most mining nodes will be running in datacenter, 3 secs blocks c const BLOCK_TIME = uint64(18) -// we are ignoring leap seconds from calculations - -// coin emiision related settings -const COIN_MONEY_SUPPLY = uint64(18446744073709551615) // 2^64-1 -const COIN_EMISSION_SPEED_FACTOR = uint64(20) -const COIN_DIFFICULTY_TARGET = uint64(120) // this is a feeder to emission formula -const COIN_FINAL_SUBSIDY_PER_MINUTE = uint64(300000000000) // 0.3 DERO per minute = 157680 per year roughly - -// these are used to configure mainnet hard fork -const HARDFORK_1_END = int64(1) - -//const HARDFORK_1_TOTAL_SUPPLY = uint64(2000000000000000000 ) // this is used to mark total supply -// till 95532 (includind) 4739519967524007940 -// 95543 4739807553788105597 -// 95549 4739964392976757069 -// 95550 4739990536584241377 -const MAINNET_HARDFORK_1_TOTAL_SUPPLY = uint64(4739990536584241377) - -const TESTNET_HARDFORK_1_TOTAL_SUPPLY = uint64(4319584000000000000) - -const MAX_CHAIN_HEIGHT = uint64(2147483648) // 2^31 +// note we are keeping the tree name small for disk savings, since they will be stored n times (atleast or archival nodes) +// this is used by graviton +const BALANCE_TREE = "B" // keeps main balance +const SC_META = "M" // keeps all SCs balance, their state, their OWNER, their data tree top hash is stored here +// one are open SCs, which provide i/o privacy +// one are private SCs which are truly private, in which no one has visibility of io or functionality // 1.25 MB block every 12 secs is equal to roughly 75 TX per second // if we consider side blocks, TPS increase to > 100 TPS @@ -65,8 +50,8 @@ const MAX_MIXIN = 128 // <= 128, mixin will be accepted // ATLANTIS FEE calculation constants are here const FEE_PER_KB = uint64(1000000000) // .001 dero per kb -const MAINNET_BOOTSTRAP_DIFFICULTY = uint64(10 * BLOCK_TIME) // atlantis mainnet botstrapped at 200 MH/s -const MAINNET_MINIMUM_DIFFICULTY = uint64(10 * BLOCK_TIME) // 5 KH/s +const MAINNET_BOOTSTRAP_DIFFICULTY = uint64(800 * BLOCK_TIME) // atlantis mainnet botstrapped at 200 MH/s +const MAINNET_MINIMUM_DIFFICULTY = uint64(800 * BLOCK_TIME) // 5 KH/s // testnet bootstraps at 1 MH //const TESTNET_BOOTSTRAP_DIFFICULTY = uint64(1000*1000*BLOCK_TIME) @@ -79,6 +64,9 @@ const TESTNET_MINIMUM_DIFFICULTY = uint64(800 * BLOCK_TIME) // 800 H // gives immense scalability, const STABLE_LIMIT = int64(8) +// reward percent that is shared between miners/dev +const DEVSHARE = uint64(600) // it's out of 10000, 600*100/10000 = 6%, 3% dev, 3% foundation + // we can have number of chains running for testing reasons type CHAIN_CONFIG struct { Name string @@ -88,6 +76,8 @@ type CHAIN_CONFIG struct { RPC_Default_Port int Wallet_RPC_Default_Port int + Dev_Address string // to which address the dev's share of fees must go + Genesis_Nonce uint32 Genesis_Block_Hash crypto.Hash @@ -96,7 +86,7 @@ type CHAIN_CONFIG struct { } var Mainnet = CHAIN_CONFIG{Name: "mainnet", - Network_ID: uuid.FromBytesOrNil([]byte{0x59, 0xd7, 0xf7, 0xe9, 0xdd, 0x48, 0xd5, 0xfd, 0x13, 0x0a, 0xf6, 0xe0, 0x9a, 0x44, 0x44, 0x0}), + Network_ID: uuid.FromBytesOrNil([]byte{0x59, 0xd7, 0xf7, 0xe9, 0xdd, 0x48, 0xd5, 0xfd, 0x13, 0x0a, 0xf6, 0xe0, 0x9a, 0x44, 0x45, 0x0}), P2P_Default_Port: 10101, RPC_Default_Port: 10102, Wallet_RPC_Default_Port: 10103, @@ -110,10 +100,11 @@ var Mainnet = CHAIN_CONFIG{Name: "mainnet", "8fff7f" + // PREMINE_VALUE "a01f9bcc1208dee302769931ad378a4c0c4b2c21b0cfb3e752607e12d2b6fa6425", // miners public key + Dev_Address: "deto1qxsplx7vzgydacczw6vnrtfh3fxqcjevyxcvlvl82fs8uykjkmaxgfgulfha5", } var Testnet = CHAIN_CONFIG{Name: "testnet", // testnet will always have last 3 bytes 0 - Network_ID: uuid.FromBytesOrNil([]byte{0x59, 0xd7, 0xf7, 0xe9, 0xdd, 0x48, 0xd5, 0xfd, 0x13, 0x0a, 0xf6, 0xe0, 0x24, 0x00, 0x00, 0x00}), + Network_ID: uuid.FromBytesOrNil([]byte{0x59, 0xd7, 0xf7, 0xe9, 0xdd, 0x48, 0xd5, 0xfd, 0x13, 0x0a, 0xf6, 0xe0, 0x25, 0x00, 0x00, 0x00}), P2P_Default_Port: 40401, RPC_Default_Port: 40402, Wallet_RPC_Default_Port: 40403, @@ -127,6 +118,7 @@ var Testnet = CHAIN_CONFIG{Name: "testnet", // testnet will always have last 3 b "8fff7f" + // PREMINE_VALUE "a01f9bcc1208dee302769931ad378a4c0c4b2c21b0cfb3e752607e12d2b6fa6425", // miners public key + Dev_Address: "deto1qxsplx7vzgydacczw6vnrtfh3fxqcjevyxcvlvl82fs8uykjkmaxgfgulfha5", } // mainnet has a remote daemon node, which can be used be default, if user provides a --remote flag diff --git a/config/version.go b/config/version.go index 60f370a..5ffe2cc 100644 --- a/config/version.go +++ b/config/version.go @@ -20,4 +20,4 @@ import "github.com/blang/semver" // right now it has to be manually changed // do we need to include git commitsha?? -var Version = semver.MustParse("3.0.0-25.DEROHE.alpha+30122020") +var Version = semver.MustParse("3.2.0-12.DEROHE.STARGATE+22022021") diff --git a/cryptography/bn256/CODE_OF_CONDUCT.md b/cryptography/bn256/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..61069f8 --- /dev/null +++ b/cryptography/bn256/CODE_OF_CONDUCT.md @@ -0,0 +1,47 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation. + +## Our Standards + +Examples of behavior that contributes to creating a positive environment include: + +* Using welcoming and inclusive language +* Being respectful of differing viewpoints and experiences +* Gracefully accepting constructive criticism +* Focusing on what is best for the community +* Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +* The use of sexualized language or imagery and unwelcome sexual attention or advances +* Trolling, insulting/derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or electronic address, without explicit permission +* Other conduct which could reasonably be considered inappropriate in a professional setting + +## Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful. + +## Scope + +This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [opensource@clearmatics.com][email]. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately. + +Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version] + +[email]: mailto:opensource@clearmatics.com +[homepage]: http://contributor-covenant.org +[version]: http://contributor-covenant.org/version/1/4/ diff --git a/vendor/golang.org/x/tools/LICENSE b/cryptography/bn256/LICENSE similarity index 100% rename from vendor/golang.org/x/tools/LICENSE rename to cryptography/bn256/LICENSE diff --git a/cryptography/bn256/Makefile b/cryptography/bn256/Makefile new file mode 100644 index 0000000..464399b --- /dev/null +++ b/cryptography/bn256/Makefile @@ -0,0 +1,34 @@ +SHELL = bash +GO_FILES = $(shell find . -name "*.go" | grep -vE ".git") +GO_COVER_FILE = `find . -name "coverage.out"` + +.PHONY: all test format cover-clean check fmt vet lint + +test: $(GO_FILES) + go test ./... + +format: + gofmt -s -w ${GO_FILES} + +cover: $(GO_FILES) + go test -coverprofile=coverage.out ./... + go tool cover -html=coverage.out + +cover-clean: + rm -f $(GO_COVER_FILE) + +deps: + go mod download + +check: + if [ -n "$(shell gofmt -l ${GO_FILES})" ]; then \ + echo 1>&2 'The following files need to be formatted:'; \ + gofmt -l .; \ + exit 1; \ + fi + +vet: + go vet $(GO_FILES) + +lint: + golint $(GO_FILES) diff --git a/cryptography/bn256/README.md b/cryptography/bn256/README.md new file mode 100644 index 0000000..e4a77fd --- /dev/null +++ b/cryptography/bn256/README.md @@ -0,0 +1,33 @@ +# BN256 + +[![Build Status](https://travis-ci.org/clearmatics/bn256.svg?branch=master)](https://travis-ci.org/clearmatics/bn256) + +This package implements a [particular](https://eprint.iacr.org/2013/507.pdf) bilinear group. +The code is imported from https://github.com/ethereum/go-ethereum/tree/master/crypto/bn256/cloudflare + +:rotating_light: **WARNING** This package originally claimed to operate at a 128-bit level. However, [recent work](https://ellipticnews.wordpress.com/2016/05/02/kim-barbulescu-variant-of-the-number-field-sieve-to-compute-discrete-logarithms-in-finite-fields/) suggest that **this is no longer the case**. + +## A note on the selection of the bilinear group + +The parameters defined in the `constants.go` file follow the parameters used in [alt-bn128 (libff)](https://github.com/scipr-lab/libff/blob/master/libff/algebra/curves/alt_bn128/alt_bn128_init.cpp). These parameters were selected so that `r−1` has a high 2-adic order. This is key to improve efficiency of the key and proof generation algorithms of the SNARK used. + +## Installation + + go get github.com/clearmatics/bn256 + +## Development + +This project uses [go modules](https://github.com/golang/go/wiki/Modules). +If you develop in your `GOPATH` and use GO 1.11, make sure to run: +```bash +export GO111MODULE=on +``` + +In fact: +> (Inside $GOPATH/src, for compatibility, the go command still runs in the old GOPATH mode, even if a go.mod is found.) +See: https://blog.golang.org/using-go-modules + +> For more fine-grained control, the module support in Go 1.11 respects a temporary environment variable, GO111MODULE, which can be set to one of three string values: off, on, or auto (the default). If GO111MODULE=off, then the go command never uses the new module support. Instead it looks in vendor directories and GOPATH to find dependencies; we now refer to this as "GOPATH mode." If GO111MODULE=on, then the go command requires the use of modules, never consulting GOPATH. We refer to this as the command being module-aware or running in "module-aware mode". If GO111MODULE=auto or is unset, then the go command enables or disables module support based on the current directory. Module support is enabled only when the current directory is outside GOPATH/src and itself contains a go.mod file or is below a directory containing a go.mod file. +See: https://golang.org/cmd/go/#hdr-Preliminary_module_support + +The project follows standard Go conventions using `gofmt`. If you wish to contribute to the project please follow standard Go conventions. The CI server automatically runs these checks. diff --git a/cryptography/bn256/bn256.go b/cryptography/bn256/bn256.go new file mode 100644 index 0000000..ff58584 --- /dev/null +++ b/cryptography/bn256/bn256.go @@ -0,0 +1,490 @@ +// Package bn256 implements a particular bilinear group at the 128-bit security +// level. +// +// Bilinear groups are the basis of many of the new cryptographic protocols that +// have been proposed over the past decade. They consist of a triplet of groups +// (G₁, G₂ and GT) such that there exists a function e(g₁ˣ,g₂ʸ)=gTˣʸ (where gₓ +// is a generator of the respective group). That function is called a pairing +// function. +// +// This package specifically implements the Optimal Ate pairing over a 256-bit +// Barreto-Naehrig curve as described in +// http://cryptojedi.org/papers/dclxvi-20100714.pdf. Its output is compatible +// with the implementation described in that paper. +package bn256 + +import ( + "crypto/rand" + "errors" + "io" + "math/big" +) + +func randomK(r io.Reader) (k *big.Int, err error) { + for { + k, err = rand.Int(r, Order) + if k.Sign() > 0 || err != nil { + return + } + } +} + +// G1 is an abstract cyclic group. The zero value is suitable for use as the +// output of an operation, but cannot be used as an input. +type G1 struct { + p *curvePoint +} + +// RandomG1 returns x and g₁ˣ where x is a random, non-zero number read from r. +func RandomG1(r io.Reader) (*big.Int, *G1, error) { + k, err := randomK(r) + if err != nil { + return nil, nil, err + } + + return k, new(G1).ScalarBaseMult(k), nil +} + +func (e *G1) String() string { + return "bn256.G1" + e.p.String() +} + +// ScalarBaseMult sets e to g*k where g is the generator of the group and then +// returns e. +func (e *G1) ScalarBaseMult(k *big.Int) *G1 { + if e.p == nil { + e.p = &curvePoint{} + } + e.p.Mul(curveGen, k) + return e +} + +// ScalarMult sets e to a*k and then returns e. +func (e *G1) ScalarMult(a *G1, k *big.Int) *G1 { + if e.p == nil { + e.p = &curvePoint{} + } + e.p.Mul(a.p, k) + return e +} + +// Add sets e to a+b and then returns e. +func (e *G1) Add(a, b *G1) *G1 { + if e.p == nil { + e.p = &curvePoint{} + } + e.p.Add(a.p, b.p) + return e +} + +// Neg sets e to -a and then returns e. +func (e *G1) Neg(a *G1) *G1 { + if e.p == nil { + e.p = &curvePoint{} + } + e.p.Neg(a.p) + return e +} + +// Set sets e to a and then returns e. +func (e *G1) Set(a *G1) *G1 { + if e.p == nil { + e.p = &curvePoint{} + } + e.p.Set(a.p) + return e +} + +// Marshal converts e to a byte slice. +func (e *G1) Marshal() []byte { + // Each value is a 256-bit number. + const numBytes = 256 / 8 + + if e.p == nil { + e.p = &curvePoint{} + } + + e.p.MakeAffine() + ret := make([]byte, numBytes*2) + if e.p.IsInfinity() { + return ret + } + temp := &gfP{} + + montDecode(temp, &e.p.x) + temp.Marshal(ret) + montDecode(temp, &e.p.y) + temp.Marshal(ret[numBytes:]) + + return ret +} + +// Unmarshal sets e to the result of converting the output of Marshal back into +// a group element and then returns e. +func (e *G1) Unmarshal(m []byte) ([]byte, error) { + // Each value is a 256-bit number. + const numBytes = 256 / 8 + if len(m) < 2*numBytes { + return nil, errors.New("bn256: not enough data") + } + // Unmarshal the points and check their caps + if e.p == nil { + e.p = &curvePoint{} + } else { + e.p.x, e.p.y = gfP{0}, gfP{0} + } + var err error + if err = e.p.x.Unmarshal(m); err != nil { + return nil, err + } + if err = e.p.y.Unmarshal(m[numBytes:]); err != nil { + return nil, err + } + // Encode into Montgomery form and ensure it's on the curve + montEncode(&e.p.x, &e.p.x) + montEncode(&e.p.y, &e.p.y) + + zero := gfP{0} + if e.p.x == zero && e.p.y == zero { + // This is the point at infinity. + e.p.y = *newGFp(1) + e.p.z = gfP{0} + e.p.t = gfP{0} + } else { + e.p.z = *newGFp(1) + e.p.t = *newGFp(1) + + if !e.p.IsOnCurve() { + return nil, errors.New("bn256: malformed point") + } + } + return m[2*numBytes:], nil +} + +// G2 is an abstract cyclic group. The zero value is suitable for use as the +// output of an operation, but cannot be used as an input. +type G2 struct { + p *twistPoint +} + +// RandomG2 returns x and g₂ˣ where x is a random, non-zero number read from r. +func RandomG2(r io.Reader) (*big.Int, *G2, error) { + k, err := randomK(r) + if err != nil { + return nil, nil, err + } + + return k, new(G2).ScalarBaseMult(k), nil +} + +func (e *G2) String() string { + return "bn256.G2" + e.p.String() +} + +// ScalarBaseMult sets e to g*k where g is the generator of the group and then +// returns out. +func (e *G2) ScalarBaseMult(k *big.Int) *G2 { + if e.p == nil { + e.p = &twistPoint{} + } + e.p.Mul(twistGen, k) + return e +} + +// ScalarMult sets e to a*k and then returns e. +func (e *G2) ScalarMult(a *G2, k *big.Int) *G2 { + if e.p == nil { + e.p = &twistPoint{} + } + e.p.Mul(a.p, k) + return e +} + +// Add sets e to a+b and then returns e. +func (e *G2) Add(a, b *G2) *G2 { + if e.p == nil { + e.p = &twistPoint{} + } + e.p.Add(a.p, b.p) + return e +} + +// Neg sets e to -a and then returns e. +func (e *G2) Neg(a *G2) *G2 { + if e.p == nil { + e.p = &twistPoint{} + } + e.p.Neg(a.p) + return e +} + +// Set sets e to a and then returns e. +func (e *G2) Set(a *G2) *G2 { + if e.p == nil { + e.p = &twistPoint{} + } + e.p.Set(a.p) + return e +} + +// Marshal converts e into a byte slice. +func (e *G2) Marshal() []byte { + // Each value is a 256-bit number. + const numBytes = 256 / 8 + + if e.p == nil { + e.p = &twistPoint{} + } + + e.p.MakeAffine() + ret := make([]byte, numBytes*4) + if e.p.IsInfinity() { + return ret + } + temp := &gfP{} + + montDecode(temp, &e.p.x.x) + temp.Marshal(ret) + montDecode(temp, &e.p.x.y) + temp.Marshal(ret[numBytes:]) + montDecode(temp, &e.p.y.x) + temp.Marshal(ret[2*numBytes:]) + montDecode(temp, &e.p.y.y) + temp.Marshal(ret[3*numBytes:]) + + return ret +} + +// Unmarshal sets e to the result of converting the output of Marshal back into +// a group element and then returns e. +func (e *G2) Unmarshal(m []byte) ([]byte, error) { + // Each value is a 256-bit number. + const numBytes = 256 / 8 + if len(m) < 4*numBytes { + return nil, errors.New("bn256: not enough data") + } + // Unmarshal the points and check their caps + if e.p == nil { + e.p = &twistPoint{} + } + var err error + if err = e.p.x.x.Unmarshal(m); err != nil { + return nil, err + } + if err = e.p.x.y.Unmarshal(m[numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.x.Unmarshal(m[2*numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.y.Unmarshal(m[3*numBytes:]); err != nil { + return nil, err + } + // Encode into Montgomery form and ensure it's on the curve + montEncode(&e.p.x.x, &e.p.x.x) + montEncode(&e.p.x.y, &e.p.x.y) + montEncode(&e.p.y.x, &e.p.y.x) + montEncode(&e.p.y.y, &e.p.y.y) + + if e.p.x.IsZero() && e.p.y.IsZero() { + // This is the point at infinity. + e.p.y.SetOne() + e.p.z.SetZero() + e.p.t.SetZero() + } else { + e.p.z.SetOne() + e.p.t.SetOne() + + if !e.p.IsOnCurve() { + return nil, errors.New("bn256: malformed point") + } + } + return m[4*numBytes:], nil +} + +// GT is an abstract cyclic group. The zero value is suitable for use as the +// output of an operation, but cannot be used as an input. +type GT struct { + p *gfP12 +} + +// Pair calculates an Optimal Ate pairing. +func Pair(g1 *G1, g2 *G2) *GT { + return >{optimalAte(g2.p, g1.p)} +} + +// PairingCheck calculates the Optimal Ate pairing for a set of points. +func PairingCheck(a []*G1, b []*G2) bool { + acc := new(gfP12) + acc.SetOne() + + for i := 0; i < len(a); i++ { + if a[i].p.IsInfinity() || b[i].p.IsInfinity() { + continue + } + acc.Mul(acc, miller(b[i].p, a[i].p)) + } + return finalExponentiation(acc).IsOne() +} + +// Miller applies Miller's algorithm, which is a bilinear function from the +// source groups to F_p^12. Miller(g1, g2).Finalize() is equivalent to Pair(g1, +// g2). +func Miller(g1 *G1, g2 *G2) *GT { + return >{miller(g2.p, g1.p)} +} + +func (e *GT) String() string { + return "bn256.GT" + e.p.String() +} + +// ScalarMult sets e to a*k and then returns e. +func (e *GT) ScalarMult(a *GT, k *big.Int) *GT { + if e.p == nil { + e.p = &gfP12{} + } + e.p.Exp(a.p, k) + return e +} + +// Add sets e to a+b and then returns e. +func (e *GT) Add(a, b *GT) *GT { + if e.p == nil { + e.p = &gfP12{} + } + e.p.Mul(a.p, b.p) + return e +} + +// Neg sets e to -a and then returns e. +func (e *GT) Neg(a *GT) *GT { + if e.p == nil { + e.p = &gfP12{} + } + e.p.Conjugate(a.p) + return e +} + +// Set sets e to a and then returns e. +func (e *GT) Set(a *GT) *GT { + if e.p == nil { + e.p = &gfP12{} + } + e.p.Set(a.p) + return e +} + +// Finalize is a linear function from F_p^12 to GT. +func (e *GT) Finalize() *GT { + ret := finalExponentiation(e.p) + e.p.Set(ret) + return e +} + +// Marshal converts e into a byte slice. +func (e *GT) Marshal() []byte { + // Each value is a 256-bit number. + const numBytes = 256 / 8 + + if e.p == nil { + e.p = &gfP12{} + e.p.SetOne() + } + + ret := make([]byte, numBytes*12) + temp := &gfP{} + + montDecode(temp, &e.p.x.x.x) + temp.Marshal(ret) + montDecode(temp, &e.p.x.x.y) + temp.Marshal(ret[numBytes:]) + montDecode(temp, &e.p.x.y.x) + temp.Marshal(ret[2*numBytes:]) + montDecode(temp, &e.p.x.y.y) + temp.Marshal(ret[3*numBytes:]) + montDecode(temp, &e.p.x.z.x) + temp.Marshal(ret[4*numBytes:]) + montDecode(temp, &e.p.x.z.y) + temp.Marshal(ret[5*numBytes:]) + montDecode(temp, &e.p.y.x.x) + temp.Marshal(ret[6*numBytes:]) + montDecode(temp, &e.p.y.x.y) + temp.Marshal(ret[7*numBytes:]) + montDecode(temp, &e.p.y.y.x) + temp.Marshal(ret[8*numBytes:]) + montDecode(temp, &e.p.y.y.y) + temp.Marshal(ret[9*numBytes:]) + montDecode(temp, &e.p.y.z.x) + temp.Marshal(ret[10*numBytes:]) + montDecode(temp, &e.p.y.z.y) + temp.Marshal(ret[11*numBytes:]) + + return ret +} + +// Unmarshal sets e to the result of converting the output of Marshal back into +// a group element and then returns e. +func (e *GT) Unmarshal(m []byte) ([]byte, error) { + // Each value is a 256-bit number. + const numBytes = 256 / 8 + + if len(m) < 12*numBytes { + return nil, errors.New("bn256: not enough data") + } + + if e.p == nil { + e.p = &gfP12{} + } + + var err error + if err = e.p.x.x.x.Unmarshal(m); err != nil { + return nil, err + } + if err = e.p.x.x.y.Unmarshal(m[numBytes:]); err != nil { + return nil, err + } + if err = e.p.x.y.x.Unmarshal(m[2*numBytes:]); err != nil { + return nil, err + } + if err = e.p.x.y.y.Unmarshal(m[3*numBytes:]); err != nil { + return nil, err + } + if err = e.p.x.z.x.Unmarshal(m[4*numBytes:]); err != nil { + return nil, err + } + if err = e.p.x.z.y.Unmarshal(m[5*numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.x.x.Unmarshal(m[6*numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.x.y.Unmarshal(m[7*numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.y.x.Unmarshal(m[8*numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.y.y.Unmarshal(m[9*numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.z.x.Unmarshal(m[10*numBytes:]); err != nil { + return nil, err + } + if err = e.p.y.z.y.Unmarshal(m[11*numBytes:]); err != nil { + return nil, err + } + montEncode(&e.p.x.x.x, &e.p.x.x.x) + montEncode(&e.p.x.x.y, &e.p.x.x.y) + montEncode(&e.p.x.y.x, &e.p.x.y.x) + montEncode(&e.p.x.y.y, &e.p.x.y.y) + montEncode(&e.p.x.z.x, &e.p.x.z.x) + montEncode(&e.p.x.z.y, &e.p.x.z.y) + montEncode(&e.p.y.x.x, &e.p.y.x.x) + montEncode(&e.p.y.x.y, &e.p.y.x.y) + montEncode(&e.p.y.y.x, &e.p.y.y.x) + montEncode(&e.p.y.y.y, &e.p.y.y.y) + montEncode(&e.p.y.z.x, &e.p.y.z.x) + montEncode(&e.p.y.z.y, &e.p.y.z.y) + + return m[12*numBytes:], nil +} diff --git a/cryptography/bn256/bn256_test.go b/cryptography/bn256/bn256_test.go new file mode 100644 index 0000000..0c8016d --- /dev/null +++ b/cryptography/bn256/bn256_test.go @@ -0,0 +1,116 @@ +package bn256 + +import ( + "bytes" + "crypto/rand" + "testing" +) + +func TestG1Marshal(t *testing.T) { + _, Ga, err := RandomG1(rand.Reader) + if err != nil { + t.Fatal(err) + } + ma := Ga.Marshal() + + Gb := new(G1) + _, err = Gb.Unmarshal(ma) + if err != nil { + t.Fatal(err) + } + mb := Gb.Marshal() + + if !bytes.Equal(ma, mb) { + t.Fatal("bytes are different") + } +} + +func TestG2Marshal(t *testing.T) { + _, Ga, err := RandomG2(rand.Reader) + if err != nil { + t.Fatal(err) + } + ma := Ga.Marshal() + + Gb := new(G2) + _, err = Gb.Unmarshal(ma) + if err != nil { + t.Fatal(err) + } + mb := Gb.Marshal() + + if !bytes.Equal(ma, mb) { + t.Fatal("bytes are different") + } +} + +func TestBilinearity(t *testing.T) { + for i := 0; i < 2; i++ { + a, p1, _ := RandomG1(rand.Reader) + b, p2, _ := RandomG2(rand.Reader) + e1 := Pair(p1, p2) + + e2 := Pair(&G1{curveGen}, &G2{twistGen}) + e2.ScalarMult(e2, a) + e2.ScalarMult(e2, b) + + if *e1.p != *e2.p { + t.Fatalf("bad pairing result: %s", e1) + } + } +} + +func TestTripartiteDiffieHellman(t *testing.T) { + a, _ := rand.Int(rand.Reader, Order) + b, _ := rand.Int(rand.Reader, Order) + c, _ := rand.Int(rand.Reader, Order) + + pa, pb, pc := new(G1), new(G1), new(G1) + qa, qb, qc := new(G2), new(G2), new(G2) + + pa.Unmarshal(new(G1).ScalarBaseMult(a).Marshal()) + qa.Unmarshal(new(G2).ScalarBaseMult(a).Marshal()) + pb.Unmarshal(new(G1).ScalarBaseMult(b).Marshal()) + qb.Unmarshal(new(G2).ScalarBaseMult(b).Marshal()) + pc.Unmarshal(new(G1).ScalarBaseMult(c).Marshal()) + qc.Unmarshal(new(G2).ScalarBaseMult(c).Marshal()) + + k1 := Pair(pb, qc) + k1.ScalarMult(k1, a) + k1Bytes := k1.Marshal() + + k2 := Pair(pc, qa) + k2.ScalarMult(k2, b) + k2Bytes := k2.Marshal() + + k3 := Pair(pa, qb) + k3.ScalarMult(k3, c) + k3Bytes := k3.Marshal() + + if !bytes.Equal(k1Bytes, k2Bytes) || !bytes.Equal(k2Bytes, k3Bytes) { + t.Errorf("keys didn't agree") + } +} + +func BenchmarkG1(b *testing.B) { + x, _ := rand.Int(rand.Reader, Order) + b.ResetTimer() + + for i := 0; i < b.N; i++ { + new(G1).ScalarBaseMult(x) + } +} + +func BenchmarkG2(b *testing.B) { + x, _ := rand.Int(rand.Reader, Order) + b.ResetTimer() + + for i := 0; i < b.N; i++ { + new(G2).ScalarBaseMult(x) + } +} +func BenchmarkPairing(b *testing.B) { + for i := 0; i < b.N; i++ { + Pair(&G1{curveGen}, &G2{twistGen}) + } +} diff --git a/cryptography/bn256/constants.go b/cryptography/bn256/constants.go new file mode 100644 index 0000000..08cfc8d --- /dev/null +++ b/cryptography/bn256/constants.go @@ -0,0 +1,79 @@ +// Copyright 2012 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package bn256 + +import ( + "math/big" +) + +func bigFromBase10(s string) *big.Int { + n, _ := new(big.Int).SetString(s, 10) + return n +} + +// u is the BN parameter. +var u = bigFromBase10("4965661367192848881") + +// Order is the number of elements in both G₁ and G₂: 36u⁴+36u³+18u²+6u+1. +var Order = bigFromBase10("21888242871839275222246405745257275088548364400416034343698204186575808495617") + +// P is a prime over which we form a basic field: 36u⁴+36u³+24u²+6u+1. +var P = bigFromBase10("21888242871839275222246405745257275088696311157297823662689037894645226208583") + +// p2 is p, represented as little-endian 64-bit words. +var p2 = [4]uint64{0x3c208c16d87cfd47, 0x97816a916871ca8d, 0xb85045b68181585d, 0x30644e72e131a029} + +// np is the negative inverse of p, mod 2^256. +var np = [4]uint64{0x87d20782e4866389, 0x9ede7d651eca6ac9, 0xd8afcbd01833da80, 0xf57a22b791888c6b} + +// +// p = 21888242871839275222246405745257275088696311157297823662689037894645226208583; Fp = GF(p) +// r = Fp(2^256) # 6350874878119819312338956282401532409788428879151445726012394534686998597021 +// rInv = 1/r # 20988524275117001072002809824448087578619730785600314334253784976379291040311 +// hex(20988524275117001072002809824448087578619730785600314334253784976379291040311) +// # 2e67157159e5c639 cf63e9cfb74492d9 eb2022850278edf8 ed84884a014afa37 +// <\sage> +// +// rN1 is R^-1 where R = 2^256 mod p. +var rN1 = &gfP{0xed84884a014afa37, 0xeb2022850278edf8, 0xcf63e9cfb74492d9, 0x2e67157159e5c639} + +// +// r2 = r^2 # 3096616502983703923843567936837374451735540968419076528771170197431451843209 +// hex(3096616502983703923843567936837374451735540968419076528771170197431451843209) +// # 06d89f71cab8351f 47ab1eff0a417ff6 b5e71911d44501fb f32cfc5b538afa89 +// <\sage> +// +// r2 is R^2 where R = 2^256 mod p. +var r2 = &gfP{0xf32cfc5b538afa89, 0xb5e71911d44501fb, 0x47ab1eff0a417ff6, 0x06d89f71cab8351f} + +// r3 is R^3 where R = 2^256 mod p. +var r3 = &gfP{0xb1cd6dafda1530df, 0x62f210e6a7283db6, 0xef7f0b0c0ada0afb, 0x20fd6e902d592544} + +// +// xiToPMinus1Over6 = Fp2(i + 9) ^ ((p-1)/6); xiToPMinus1Over6 +// # 16469823323077808223889137241176536799009286646108169935659301613961712198316*i + 8376118865763821496583973867626364092589906065868298776909617916018768340080 +// <\sage> +// +// The value of `xiToPMinus1Over6` below is the same as the one obtained in sage, but where every field element is montgomery encoded +// xiToPMinus1Over6 is ξ^((p-1)/6) where ξ = i+9. +var xiToPMinus1Over6 = &gfP2{gfP{0xa222ae234c492d72, 0xd00f02a4565de15b, 0xdc2ff3a253dfc926, 0x10a75716b3899551}, gfP{0xaf9ba69633144907, 0xca6b1d7387afb78a, 0x11bded5ef08a2087, 0x02f34d751a1f3a7c}} + +// xiToPMinus1Over3 is ξ^((p-1)/3) where ξ = i+9. +var xiToPMinus1Over3 = &gfP2{gfP{0x6e849f1ea0aa4757, 0xaa1c7b6d89f89141, 0xb6e713cdfae0ca3a, 0x26694fbb4e82ebc3}, gfP{0xb5773b104563ab30, 0x347f91c8a9aa6454, 0x7a007127242e0991, 0x1956bcd8118214ec}} + +// xiToPMinus1Over2 is ξ^((p-1)/2) where ξ = i+9. +var xiToPMinus1Over2 = &gfP2{gfP{0xa1d77ce45ffe77c7, 0x07affd117826d1db, 0x6d16bd27bb7edc6b, 0x2c87200285defecc}, gfP{0xe4bbdd0c2936b629, 0xbb30f162e133bacb, 0x31a9d1b6f9645366, 0x253570bea500f8dd}} + +// xiToPSquaredMinus1Over3 is ξ^((p²-1)/3) where ξ = i+9. +var xiToPSquaredMinus1Over3 = &gfP{0x3350c88e13e80b9c, 0x7dce557cdb5e56b9, 0x6001b4b8b615564a, 0x2682e617020217e0} + +// xiTo2PSquaredMinus2Over3 is ξ^((2p²-2)/3) where ξ = i+9 (a cubic root of unity, mod p). +var xiTo2PSquaredMinus2Over3 = &gfP{0x71930c11d782e155, 0xa6bb947cffbe3323, 0xaa303344d4741444, 0x2c3b3f0d26594943} + +// xiToPSquaredMinus1Over6 is ξ^((1p²-1)/6) where ξ = i+9 (a cubic root of -1, mod p). +var xiToPSquaredMinus1Over6 = &gfP{0xca8d800500fa1bf2, 0xf0c5d61468b39769, 0x0e201271ad0d4418, 0x04290f65bad856e6} + +// xiTo2PMinus2Over3 is ξ^((2p-2)/3) where ξ = i+9. +var xiTo2PMinus2Over3 = &gfP2{gfP{0x5dddfd154bd8c949, 0x62cb29a5a4445b60, 0x37bc870a0c7dd2b9, 0x24830a9d3171f0fd}, gfP{0x7361d77f843abe92, 0xa5bb2bd3273411fb, 0x9c941f314b3e2399, 0x15df9cddbb9fd3ec}} diff --git a/cryptography/bn256/curve.go b/cryptography/bn256/curve.go new file mode 100644 index 0000000..d017915 --- /dev/null +++ b/cryptography/bn256/curve.go @@ -0,0 +1,318 @@ +package bn256 + +import ( + "math/big" +) + +// curvePoint implements the elliptic curve y²=x³+3. Points are kept in Jacobian +// form and t=z² when valid. G₁ is the set of points of this curve on GF(p). +type curvePoint struct { + x, y, z, t gfP +} + +var curveB = newGFp(3) + +// curveGen is the generator of G₁. +var curveGen = &curvePoint{ + x: *newGFp(1), + y: *newGFp(2), + z: *newGFp(1), + t: *newGFp(1), +} + +func (c *curvePoint) String() string { + c.MakeAffine() + x, y := &gfP{}, &gfP{} + montDecode(x, &c.x) + montDecode(y, &c.y) + return "(" + x.String() + ", " + y.String() + ")" +} + +func (c *curvePoint) Set(a *curvePoint) { + c.x.Set(&a.x) + c.y.Set(&a.y) + c.z.Set(&a.z) + c.t.Set(&a.t) +} + +// IsOnCurve returns true iff c is on the curve. +func (c *curvePoint) IsOnCurve() bool { + c.MakeAffine() + if c.IsInfinity() { + return true + } + + y2, x3 := &gfP{}, &gfP{} + gfpMul(y2, &c.y, &c.y) + gfpMul(x3, &c.x, &c.x) + gfpMul(x3, x3, &c.x) + gfpAdd(x3, x3, curveB) + + return *y2 == *x3 +} + +func (c *curvePoint) SetInfinity() { + c.x = gfP{0} + c.y = *newGFp(1) + c.z = gfP{0} + c.t = gfP{0} +} + +func (c *curvePoint) IsInfinity() bool { + return c.z == gfP{0} +} + +func (c *curvePoint) Add(a, b *curvePoint) { + if a.IsInfinity() { + c.Set(b) + return + } + if b.IsInfinity() { + c.Set(a) + return + } + + // See http://hyperelliptic.org/EFD/g1p/auto-code/shortw/jacobian-0/addition/add-2007-bl.op3 + + // Normalize the points by replacing a = [x1:y1:z1] and b = [x2:y2:z2] + // by [u1:s1:z1·z2] and [u2:s2:z1·z2] + // where u1 = x1·z2², s1 = y1·z2³ and u1 = x2·z1², s2 = y2·z1³ + z12, z22 := &gfP{}, &gfP{} + gfpMul(z12, &a.z, &a.z) + gfpMul(z22, &b.z, &b.z) + + u1, u2 := &gfP{}, &gfP{} + gfpMul(u1, &a.x, z22) + gfpMul(u2, &b.x, z12) + + t, s1 := &gfP{}, &gfP{} + gfpMul(t, &b.z, z22) + gfpMul(s1, &a.y, t) + + s2 := &gfP{} + gfpMul(t, &a.z, z12) + gfpMul(s2, &b.y, t) + + // Compute x = (2h)²(s²-u1-u2) + // where s = (s2-s1)/(u2-u1) is the slope of the line through + // (u1,s1) and (u2,s2). The extra factor 2h = 2(u2-u1) comes from the value of z below. + // This is also: + // 4(s2-s1)² - 4h²(u1+u2) = 4(s2-s1)² - 4h³ - 4h²(2u1) + // = r² - j - 2v + // with the notations below. + h := &gfP{} + gfpSub(h, u2, u1) + xEqual := *h == gfP{0} + + gfpAdd(t, h, h) + // i = 4h² + i := &gfP{} + gfpMul(i, t, t) + // j = 4h³ + j := &gfP{} + gfpMul(j, h, i) + + gfpSub(t, s2, s1) + yEqual := *t == gfP{0} + if xEqual && yEqual { + c.Double(a) + return + } + r := &gfP{} + gfpAdd(r, t, t) + + v := &gfP{} + gfpMul(v, u1, i) + + // t4 = 4(s2-s1)² + t4, t6 := &gfP{}, &gfP{} + gfpMul(t4, r, r) + gfpAdd(t, v, v) + gfpSub(t6, t4, j) + + gfpSub(&c.x, t6, t) + + // Set y = -(2h)³(s1 + s*(x/4h²-u1)) + // This is also + // y = - 2·s1·j - (s2-s1)(2x - 2i·u1) = r(v-x) - 2·s1·j + gfpSub(t, v, &c.x) // t7 + gfpMul(t4, s1, j) // t8 + gfpAdd(t6, t4, t4) // t9 + gfpMul(t4, r, t) // t10 + gfpSub(&c.y, t4, t6) + + // Set z = 2(u2-u1)·z1·z2 = 2h·z1·z2 + gfpAdd(t, &a.z, &b.z) // t11 + gfpMul(t4, t, t) // t12 + gfpSub(t, t4, z12) // t13 + gfpSub(t4, t, z22) // t14 + gfpMul(&c.z, t4, h) +} + +func (c *curvePoint) Double(a *curvePoint) { + // See http://hyperelliptic.org/EFD/g1p/auto-code/shortw/jacobian-0/doubling/dbl-2009-l.op3 + A, B, C := &gfP{}, &gfP{}, &gfP{} + gfpMul(A, &a.x, &a.x) + gfpMul(B, &a.y, &a.y) + gfpMul(C, B, B) + + t, t2 := &gfP{}, &gfP{} + gfpAdd(t, &a.x, B) + gfpMul(t2, t, t) + gfpSub(t, t2, A) + gfpSub(t2, t, C) + + d, e, f := &gfP{}, &gfP{}, &gfP{} + gfpAdd(d, t2, t2) + gfpAdd(t, A, A) + gfpAdd(e, t, A) + gfpMul(f, e, e) + + gfpAdd(t, d, d) + gfpSub(&c.x, f, t) + + gfpAdd(t, C, C) + gfpAdd(t2, t, t) + gfpAdd(t, t2, t2) + gfpSub(&c.y, d, &c.x) + gfpMul(t2, e, &c.y) + gfpSub(&c.y, t2, t) + + gfpMul(t, &a.y, &a.z) + gfpAdd(&c.z, t, t) +} + +func (c *curvePoint) Mul(a *curvePoint, scalar *big.Int) { + precomp := [1 << 2]*curvePoint{nil, {}, {}, {}} + precomp[1].Set(a) + precomp[2].Set(a) + gfpMul(&precomp[2].x, &precomp[2].x, xiTo2PSquaredMinus2Over3) + precomp[3].Add(precomp[1], precomp[2]) + + multiScalar := curveLattice.Multi(scalar) + + sum := &curvePoint{} + sum.SetInfinity() + t := &curvePoint{} + + for i := len(multiScalar) - 1; i >= 0; i-- { + t.Double(sum) + if multiScalar[i] == 0 { + sum.Set(t) + } else { + sum.Add(t, precomp[multiScalar[i]]) + } + } + c.Set(sum) +} + +// Transforms Jacobian coordinates to Affine coordinates +// (X' : Y' : Z) -> (X'/(Z^2) : Y'/(Z^3) : 1) +func (c *curvePoint) MakeAffine() { + // point0 := *newGFp(0) + // point1 := *newGFp(1) + + if c.z == point1 { + return + } else if c.z == point0 { // return point at infinity if z = 0 + c.x = gfP{0} + c.y = point1 + c.t = gfP{0} + return + } + + zInv := &gfP{} + zInv.Invert(&c.z) + + t, zInv2 := &gfP{}, &gfP{} + gfpMul(t, &c.y, zInv) // t = y/z + gfpMul(zInv2, zInv, zInv) // zInv2 = 1/(z^2) + + gfpMul(&c.x, &c.x, zInv2) // x = x/(z^2) + gfpMul(&c.y, t, zInv2) // y = y/(z^3) + + c.z = point1 + c.t = point1 +} + +func (c *curvePoint) Neg(a *curvePoint) { + c.x.Set(&a.x) + gfpNeg(&c.y, &a.y) + c.z.Set(&a.z) + c.t = gfP{0} +} + +var point0 = *newGFp(0) +var point1 = *newGFp(1) + +// this will do batch inversions and thus optimize lookup table generation +// Montgomery Batch Inversion based trick +type G1Array []*G1 + +func (points G1Array) MakeAffine() { + // point0 := *newGFp(0) + // point1 := *newGFp(1) + + accum := newGFp(1) + + var scratch_backup [256]gfP + + var scratch []gfP + if len(points) <= 256 { + scratch = scratch_backup[:0] // avoid allocation is possible + } + for _, e := range points { + if e.p == nil { + e.p = &curvePoint{} + } + scratch = append(scratch, *accum) + if e.p.z == point1 { + continue + } else if e.p.z == point0 { // return point at infinity if z = 0 + e.p.x = gfP{0} + e.p.y = point1 + e.p.t = gfP{0} + continue + } + + gfpMul(accum, accum, &e.p.z) // accum *= z + + /* + zInv := &gfP{} + zInv.Invert(&e.p.z) + fmt.Printf("%d inv %s\n",i, zInv) + */ + } + + zInv_accum := gfP{} + zInv_accum.Invert(accum) + + tmp := gfP{} + zInv := &gfP{} + + for i := len(points) - 1; i >= 0; i-- { + e := points[i] + + if e.p.z == point1 { + continue + } else if e.p.z == point0 { // return point at infinity if z = 0 + continue + } + + tmp = gfP{} + gfpMul(&tmp, &zInv_accum, &e.p.z) + gfpMul(zInv, &zInv_accum, &scratch[i]) + zInv_accum = tmp + // fmt.Printf("%d inv %s\n",i, zInv) + + t, zInv2 := &gfP{}, &gfP{} + gfpMul(t, &e.p.y, zInv) // t = y/z + gfpMul(zInv2, zInv, zInv) // zInv2 = 1/(z^2) + + gfpMul(&e.p.x, &e.p.x, zInv2) // x = x/(z^2) + gfpMul(&e.p.y, t, zInv2) // y = y/(z^3) + + e.p.z = point1 + e.p.t = point1 + } +} diff --git a/cryptography/bn256/curve_test.go b/cryptography/bn256/curve_test.go new file mode 100644 index 0000000..3f4f884 --- /dev/null +++ b/cryptography/bn256/curve_test.go @@ -0,0 +1,66 @@ +// Copyright 2012 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package bn256 + +import ( + "crypto/rand" + "testing" + + "github.com/stretchr/testify/require" +) + +func TestG1Array(t *testing.T) { + count := 8 + + var g1array G1Array + var g1array_opt G1Array + + for i := 0; i < count; i++ { + a, _ := rand.Int(rand.Reader, Order) + g1array = append(g1array, new(G1).ScalarBaseMult(a)) + g1array_opt = append(g1array_opt, new(G1).ScalarBaseMult(a)) + } + g1array_opt.MakeAffine() + for i := range g1array_opt { + require.Equal(t, g1array_opt[i].p.z, *newGFp(1)) // current we are not testing points of infinity + } +} + +func benchmarksingleinverts(count int, b *testing.B) { + var g1array, g1backup G1Array + + for i := 0; i < count; i++ { + a, _ := rand.Int(rand.Reader, Order) + g1backup = append(g1backup, new(G1).ScalarBaseMult(a)) + } + + for n := 0; n < b.N; n++ { + g1array = g1array[:0] + for i := range g1backup { + g1array = append(g1array, new(G1).Set(g1backup[i])) + g1array[i].p.MakeAffine() + } + } +} + +func benchmarkbatchedinverts(count int, b *testing.B) { + var g1array, g1backup G1Array + + for i := 0; i < count; i++ { + a, _ := rand.Int(rand.Reader, Order) + g1backup = append(g1backup, new(G1).ScalarBaseMult(a)) + } + + for n := 0; n < b.N; n++ { + g1array = g1array[:0] + for i := range g1backup { + g1array = append(g1array, new(G1).Set(g1backup[i])) + } + g1array.MakeAffine() + } +} + +func BenchmarkInverts_Single_256(b *testing.B) { benchmarksingleinverts(256, b) } +func BenchmarkInverts_Batched_256(b *testing.B) { benchmarkbatchedinverts(256, b) } diff --git a/cryptography/bn256/example_test.go b/cryptography/bn256/example_test.go new file mode 100644 index 0000000..6c28599 --- /dev/null +++ b/cryptography/bn256/example_test.go @@ -0,0 +1,51 @@ +// Copyright 2012 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package bn256 + +import ( + "crypto/rand" + "testing" + + "github.com/stretchr/testify/require" +) + +func TestExamplePair(t *testing.T) { + // This implements the tripartite Diffie-Hellman algorithm from "A One + // Round Protocol for Tripartite Diffie-Hellman", A. Joux. + // http://www.springerlink.com/content/cddc57yyva0hburb/fulltext.pdf + + // Each of three parties, a, b and c, generate a private value. + a, _ := rand.Int(rand.Reader, Order) + b, _ := rand.Int(rand.Reader, Order) + c, _ := rand.Int(rand.Reader, Order) + + // Then each party calculates g₁ and g₂ times their private value. + pa := new(G1).ScalarBaseMult(a) + qa := new(G2).ScalarBaseMult(a) + + pb := new(G1).ScalarBaseMult(b) + qb := new(G2).ScalarBaseMult(b) + + pc := new(G1).ScalarBaseMult(c) + qc := new(G2).ScalarBaseMult(c) + + // Now each party exchanges its public values with the other two and + // all parties can calculate the shared key. + k1 := Pair(pb, qc) + k1.ScalarMult(k1, a) + + k2 := Pair(pc, qa) + k2.ScalarMult(k2, b) + + k3 := Pair(pa, qb) + k3.ScalarMult(k3, c) + + // k1, k2 and k3 will all be equal. + + require.Equal(t, k1, k2) + require.Equal(t, k1, k3) + + require.Equal(t, len(np), 4) //Avoid gometalinter varcheck err on np +} diff --git a/cryptography/bn256/g1_serialization.go b/cryptography/bn256/g1_serialization.go new file mode 100644 index 0000000..c508984 --- /dev/null +++ b/cryptography/bn256/g1_serialization.go @@ -0,0 +1,424 @@ +// Package bn256 implements a particular bilinear group at the 128-bit security +// level. +// +// Bilinear groups are the basis of many of the new cryptographic protocols that +// have been proposed over the past decade. They consist of a triplet of groups +// (G₁, G₂ and GT) such that there exists a function e(g₁ˣ,g₂ʸ)=gTˣʸ (where gₓ +// is a generator of the respective group). That function is called a pairing +// function. +// +// This package specifically implements the Optimal Ate pairing over a 256-bit +// Barreto-Naehrig curve as described in +// http://cryptojedi.org/papers/dclxvi-20100714.pdf. Its output is compatible +// with the implementation described in that paper. +package bn256 + +// This file implement some util functions for the MPC +// especially the serialization and deserialization functions for points in G1 +import ( + "errors" + "math/big" +) + +// Constants related to the bn256 pairing friendly curve +const ( + FqElementSize = 32 + G1CompressedSize = FqElementSize + 1 // + 1 accounts for the additional byte used for masking + G1UncompressedSize = 2*FqElementSize + 1 // + 1 accounts for the additional byte used for masking +) + +// https://github.com/ebfull/pairing/tree/master/src/bls12_381#serialization +// Bytes used to detect the formatting. By reading the first byte of the encoded point we can know it's nature +// ie: we can know if the point is the point at infinity, if it is encoded uncompressed or if it is encoded compressed +// Bit masking used to detect the serialization of the points and their nature +// +// The BSL12-381 curve is built over a 381-bit prime field. +// Thus each point coordinate is represented over 381 bits = 47bytes + 5bits +// Thus, to represent a point we need to have 48bytes, but the last 3 bits of the 48th byte will be set to 0 +// These are these bits that are used to implement the masking, hence why the masking proposed by ebfull was: +const ( + serializationMask = (1 << 5) - 1 // 0001 1111 // Enable to pick the 3 MSB corresponding to the serialization flag + serializationCompressed = 1 << 7 // 1000 0000 + serializationInfinity = 1 << 6 // 0100 0000 + serializationBigY = 1 << 5 // 0010 0000 +) + +// IsHigherY is used to distinguish between the 2 points of E +// that have the same x-coordinate +// The point e is assumed to be given in the affine form +func (e *G1) IsHigherY() bool { + // Check nil pointers + if e.p == nil { + e.p = &curvePoint{} + } + + var yCoord gfP + //yCoord.Set(&e.p.y) + yCoord = e.p.y + + var yCoordNeg gfP + gfpNeg(&yCoordNeg, &yCoord) + + res := gfpCmp(&yCoord, &yCoordNeg) + if res == 1 { // yCoord > yCoordNeg + return true + } else if res == -1 { + return false + } + + return false +} + +// EncodeCompressed converts the compressed point e into bytes +// This function takes a point in the Jacobian form +// This function does not modify the point e +// (the variable `temp` is introduced to avoid to modify e) +func (e *G1) EncodeCompressed() []byte { + // Check nil pointers + if e.p == nil { + e.p = &curvePoint{} + } + + e.p.MakeAffine() + ret := make([]byte, G1CompressedSize) + + // Flag the encoding with the compressed flag + ret[0] |= serializationCompressed + + if e.p.IsInfinity() { + // Flag the encoding with the infinity flag + ret[0] |= serializationInfinity + return ret + } + + if e.IsHigherY() { + // Flag the encoding with the bigY flag + ret[0] |= serializationBigY + } + + // We start the serializagtion of the coordinates at the index 1 + // Since the index 0 in the `ret` corresponds to the masking + temp := &gfP{} + montDecode(temp, &e.p.x) + temp.Marshal(ret[1:]) + + return ret +} + +// returns to buffer rather than allocation from GC +func (e *G1) EncodeCompressedToBuf(ret []byte) { + // Check nil pointers + if e.p == nil { + e.p = &curvePoint{} + } + + e.p.MakeAffine() + //ret := make([]byte, G1CompressedSize) + + // Flag the encoding with the compressed flag + ret[0] |= serializationCompressed + + if e.p.IsInfinity() { + // Flag the encoding with the infinity flag + ret[0] |= serializationInfinity + return + } + + if e.IsHigherY() { + // Flag the encoding with the bigY flag + ret[0] |= serializationBigY + } + + // We start the serializagtion of the coordinates at the index 1 + // Since the index 0 in the `ret` corresponds to the masking + temp := &gfP{} + montDecode(temp, &e.p.x) + temp.Marshal(ret[1:]) + + return +} + +// EncodeUncompressed converts the compressed point e into bytes +// Take a point P in Jacobian form (where each coordinate is MontEncoded) +// and encodes it by going back to affine coordinates and montDecode all coordinates +// This function does not modify the point e +// (the variable `temp` is introduced to avoid to modify e) +/* +func (e *G1) EncodeUncompressed() []byte { + // Check nil pointers + if e.p == nil { + e.p = &curvePoint{} + } + + e.p.MakeAffine() + ret := make([]byte, G1UncompressedSize) + + if e.p.IsInfinity() { + // Flag the encoding with the infinity flag + ret[0] |= serializationInfinity + return ret + } + + // We start the serialization of the coordinates at the index 1 + // Since the index 0 in the `ret` corresponds to the masking + temp := &gfP{} + montDecode(temp, &e.p.x) // Store the montgomery decoding in temp + temp.Marshal(ret[1:33]) // Write temp in the `ret` slice, this is the x-coordinate + montDecode(temp, &e.p.y) + temp.Marshal(ret[33:]) // this is the y-coordinate + + return ret +} +*/ +func (e *G1) EncodeUncompressed() []byte { + // Check nil pointers + if e.p == nil { + e.p = &curvePoint{} + } + + // Set the right flags + ret := make([]byte, G1UncompressedSize) + if e.p.IsInfinity() { + // Flag the encoding with the infinity flag + ret[0] |= serializationInfinity + return ret + } + + // Marshal + marshal := e.Marshal() + // The encoding = flags || marshalledPoint + copy(ret[1:], marshal) + + return ret +} + +// Takes a MontEncoded x and finds the corresponding y (one of the two possible y's) +func getYFromMontEncodedX(x *gfP) (*gfP, error) { + // Check nil pointers + if x == nil { + return nil, errors.New("Cannot retrieve the y-coordinate form a nil pointer") + } + + // Operations on montgomery encoded field elements + x2 := &gfP{} + gfpMul(x2, x, x) + + x3 := &gfP{} + gfpMul(x3, x2, x) + + rhs := &gfP{} + gfpAdd(rhs, x3, curveB) // curveB is MontEncoded, since it is create with newGFp + + // Montgomery decode rhs + // Needed because when we create a GFp element + // with gfP{}, then it is not montEncoded. However + // if we create an element of GFp by using `newGFp()` + // then this field element is Montgomery encoded + // Above, we have been working on Montgomery encoded field elements + // here we solve the quad. resid. over F (not encoded) + // and then we encode back and return the encoded result + // + // Eg: + // - Px := &gfP{1} => 0000000000000000000000000000000000000000000000000000000000000001 + // - PxNew := newGFp(1) => 0e0a77c19a07df2f666ea36f7879462c0a78eb28f5c70b3dd35d438dc58f0d9d + montDecode(rhs, rhs) + rhsBig, err := rhs.gFpToBigInt() + if err != nil { + return nil, err + } + + // Note, if we use the ModSqrt method, we don't need the exponent, so we can comment these lines + yCoord := big.NewInt(0) + res := yCoord.ModSqrt(rhsBig, P) + if res == nil { + return nil, errors.New("not a square mod P") + } + + yCoordGFp := newGFpFromBigInt(yCoord) + montEncode(yCoordGFp, yCoordGFp) + + return yCoordGFp, nil +} + +// DecodeCompressed decodes a point in the compressed form +// Take a point P encoded (ie: written in affine form where each coordinate is MontDecoded) +// and encodes it by going back to Jacobian coordinates and montEncode all coordinates +func (e *G1) DecodeCompressed(encoding []byte) error { + if len(encoding) != G1CompressedSize { + return errors.New("wrong encoded point size") + } + if encoding[0]&serializationCompressed == 0 { // Also test the length of the encoding to make sure it is 33bytes + return errors.New("point isn't compressed") + } + + // Unmarshal the points and check their caps + if e.p == nil { + e.p = &curvePoint{} + } + { + e.p.x, e.p.y = gfP{0}, gfP{0} + e.p.z, e.p.t = *newGFp(1), *newGFp(1) + } + + // Removes the bits of the masking (This does a bitwise AND with `0001 1111`) + // And thus removes the first 3 bits corresponding to the masking + bin := make([]byte, G1CompressedSize) + copy(bin, encoding) + bin[0] &= serializationMask + + // Decode the point at infinity in the compressed form + if encoding[0]&serializationInfinity != 0 { + if encoding[0]&serializationBigY != 0 { + return errors.New("high Y bit improperly set") + } + + // Similar to `for i:=0; i 0 { // GaNeg.p.y > Ga.p.y + assert.True(t, GaNeg.IsHigherY(), "GaNeg.IsHigherY should be true if GaNeg.p.y > Ga.p.y") + // Test the comparision of the big int also, should be the same result + assert.Equal(t, GaNegYBig.Cmp(GaYBig), 1, "GaNegYBig should be bigger than GaYBig") + } else if res < 0 { // GaNeg.p.y < Ga.p.y + assert.False(t, GaNeg.IsHigherY(), "GaNeg.IsHigherY should be false if GaNeg.p.y < Ga.p.y") + // Test the comparision of the big int also, should be the same result + assert.Equal(t, GaYBig.Cmp(GaNegYBig), 1, "GaYBig should be bigger than GaNegYBig") + } +} + +func TestGetYFromMontEncodedX(t *testing.T) { + // We know that the generator of the curve is P = (x: 1, y: 2, z: 1, t: 1) + // We take x = 1 and we see if we retrieve P such that y = 2 or -P such that y' = Inv(2) + + // Create the GFp element 1 and MontEncode it + PxMontEncoded := newGFp(1) + yRetrieved, err := getYFromMontEncodedX(PxMontEncoded) + assert.Nil(t, err) + + smallYMontEncoded := newGFp(2) + bigYMontEncoded := &gfP{} + gfpNeg(bigYMontEncoded, smallYMontEncoded) + + testCondition := (*yRetrieved == *smallYMontEncoded) || (*yRetrieved == *bigYMontEncoded) + assert.True(t, testCondition, "The retrieved Y should either equal 2 or Inv(2)") +} + +func TestEncodeUncompressed(t *testing.T) { + // Case1: Create random point (Jacobian form) + _, GaInit, err := RandomG1(rand.Reader) + if err != nil { + t.Fatal(err) + } + + // Affine form of GaInit + GaAffine := new(G1) + GaAffine.Set(GaInit) + GaAffine.p.MakeAffine() + + // Encode GaCopy1 with the EncodeUncompress function + GaCopy1 := new(G1) + GaCopy1.Set(GaInit) + encoded := GaCopy1.EncodeUncompressed() + + // Encode GaCopy2 with the Marshal function + GaCopy2 := new(G1) + GaCopy2.Set(GaInit) + marshalled := GaCopy2.Marshal() // Careful Marshal modifies the point since it makes it an affine point! + + // Make sure that the x-coordinate is encoded as it is when we call the Marshal function + assert.Equal( + t, + encoded[1:], // Ignore the masking byte + marshalled[:], + "The EncodeUncompressed and Marshal function yield different results") + + // Unmarshal the point Ga with the unmarshal function + Gb1 := new(G1) + _, err = Gb1.Unmarshal(marshalled) + assert.Nil(t, err) + assert.Equal(t, GaAffine.p.x.String(), Gb1.p.x.String(), "The x-coord of the unmarshalled point should equal the x-coord of the intial point") + assert.Equal(t, GaAffine.p.y.String(), Gb1.p.y.String(), "The y-coord of the unmarshalled point should equal the y-coord of the intial point") + + // Decode the point Ga with the decodeUncompress function + Gb2 := new(G1) + err = Gb2.DecodeUncompressed(encoded) + assert.Nil(t, err) + assert.Equal(t, GaAffine.p.x.String(), Gb2.p.x.String(), "The x-coord of the decoded point should equal the x-coord of the intial point") + assert.Equal(t, GaAffine.p.y.String(), Gb2.p.y.String(), "The y-coord of the decoded point should equal the y-coord of the intial point") + + // Case2: Encode the point at infinity + GInfinity := new(G1) + GInfinity.p = &curvePoint{} + GInfinity.p.SetInfinity() + + // Get the point in affine form + GInfinityAffine := new(G1) + GInfinityAffine.Set(GInfinity) + GInfinityAffine.p.MakeAffine() + + // Encode GaCopy1 with the EncodeUncompress function + GInfinityCopy1 := new(G1) + GInfinityCopy1.Set(GInfinity) + encoded = GInfinityCopy1.EncodeUncompressed() + + // Encode GaCopy2 with the Marshal function + GInfinityCopy2 := new(G1) + GInfinityCopy2.Set(GInfinity) + marshalled = GInfinityCopy2.Marshal() // Careful Marshal modifies the point since it makes it an affine point! + + // Make sure that the x-coordinate is encoded as it is when we call the Marshal function + assert.Equal( + t, + encoded[1:], // Ignore the masking byte + marshalled[:], + "The EncodeUncompressed and Marshal function yield different results") + + // Unmarshal the point Ga with the unmarshal function + Gb1 = new(G1) + _, err = Gb1.Unmarshal(marshalled) + assert.Nil(t, err) + assert.Equal(t, GInfinityAffine.p.x.String(), Gb1.p.x.String(), "The x-coord of the unmarshalled point should equal the x-coord of the intial point") + assert.Equal(t, GInfinityAffine.p.y.String(), Gb1.p.y.String(), "The y-coord of the unmarshalled point should equal the y-coord of the intial point") + + // Decode the point Ga with the decodeCompress function + Gb2 = new(G1) + err = Gb2.DecodeUncompressed(encoded) + assert.Nil(t, err) + assert.Equal(t, GInfinityAffine.p.x.String(), Gb2.p.x.String(), "The x-coord of the decompressed point should equal the x-coord of the intial point") + assert.Equal(t, GInfinityAffine.p.y.String(), Gb2.p.y.String(), "The y-coord of the decompressed point should equal the y-coord of the intial point") +} diff --git a/cryptography/bn256/g2_serialization.go b/cryptography/bn256/g2_serialization.go new file mode 100644 index 0000000..b020933 --- /dev/null +++ b/cryptography/bn256/g2_serialization.go @@ -0,0 +1,266 @@ +// Package bn256 implements a particular bilinear group at the 128-bit security +// level. +// +// Bilinear groups are the basis of many of the new cryptographic protocols that +// have been proposed over the past decade. They consist of a triplet of groups +// (G₁, G₂ and GT) such that there exists a function e(g₁ˣ,g₂ʸ)=gTˣʸ (where gₓ +// is a generator of the respective group). That function is called a pairing +// function. +// +// This package specifically implements the Optimal Ate pairing over a 256-bit +// Barreto-Naehrig curve as described in +// http://cryptojedi.org/papers/dclxvi-20100714.pdf. Its output is compatible +// with the implementation described in that paper. +package bn256 + +import ( + "errors" +) + +// This file implement some util functions for the MPC +// especially the serialization and deserialization functions for points in G1 + +// Constants related to the bn256 pairing friendly curve +const ( + Fq2ElementSize = 2 * FqElementSize + G2CompressedSize = Fq2ElementSize + 1 // + 1 accounts for the additional byte used for masking + G2UncompressedSize = 2*Fq2ElementSize + 1 // + 1 accounts for the additional byte used for masking +) + +// EncodeUncompressed converts the compressed point e into bytes +// Take a point P in Jacobian form (where each coordinate is MontEncoded) +// and encodes it by going back to affine coordinates and montDecode all coordinates +// This function does not modify the point e +// (the variable `temp` is introduced to avoid to modify e) +func (e *G2) EncodeUncompressed() []byte { + // Check nil pointers + if e.p == nil { + e.p = &twistPoint{} + } + + // Set the right flags + ret := make([]byte, G2UncompressedSize) + if e.p.IsInfinity() { + // Flag the encoding with the infinity flag + ret[0] |= serializationInfinity + return ret + } + + // Marshal + marshal := e.Marshal() + // The encoding = flags || marshalledPoint + copy(ret[1:], marshal) + + return ret +} + +// DecodeUncompressed decodes a point in the uncompressed form +// Take a point P encoded (ie: written in affine form where each coordinate is MontDecoded) +// and encodes it by going back to Jacobian coordinates and montEncode all coordinates +func (e *G2) DecodeUncompressed(encoding []byte) error { + if len(encoding) != G2UncompressedSize { + return errors.New("wrong encoded point size") + } + if encoding[0]&serializationCompressed != 0 { // Also test the length of the encoding to make sure it is 65bytes + return errors.New("point is compressed") + } + if encoding[0]&serializationBigY != 0 { // Also test that the bigY flag if not set + return errors.New("bigY flag should not be set") + } + + // Unmarshal the points and check their caps + if e.p == nil { + e.p = &twistPoint{} + } + + // Removes the bits of the masking (This does a bitwise AND with `0001 1111`) + // And thus removes the first 3 bits corresponding to the masking + // Useless for now because in bn256, we added a full byte to enable masking + // However, this is needed if we work over BLS12 and its underlying field + bin := make([]byte, G2UncompressedSize) + copy(bin, encoding) + bin[0] &= serializationMask + + // Decode the point at infinity in the compressed form + if encoding[0]&serializationInfinity != 0 { + // Makes sense to check that all bytes of bin are 0x0 since we removed the masking above} + for i := range bin { + if bin[i] != 0 { + return errors.New("invalid infinity encoding") + } + } + e.p.SetInfinity() + return nil + } + + // We remove the flags and unmarshal the data + _, err := e.Unmarshal(encoding[1:]) + return err +} + +func (e *G2) IsHigherY() bool { + // Check nil pointers + if e.p == nil { + e.p = &twistPoint{} + e.p.MakeAffine() + } + + // Note: the structures attributes are quite confusing here + // In fact, each element of Fp2 is a polynomial with 2 terms + // the `x` and `y` denote these coefficients, ie: xi + y + // However, `x` and `y` are also used to denote the x and y **coordinates** + // of an elliptic curve point. Hence, e.p.y represents the y-coordinate of the + // point e, and e.p.y.y represents the **coefficient** y of the y-coordinate + // of the elliptic curve point e. + // + // TODO: Rename the coefficients of the elements of Fp2 as c0 and c1 to clarify the code + yCoordY := &gfP{} + yCoordY.Set(&e.p.y.y) + yCoordYNeg := &gfP{} + gfpNeg(yCoordYNeg, yCoordY) + + res := gfpCmp(yCoordY, yCoordYNeg) + if res == 1 { // yCoordY > yCoordNegY + return true + } else if res == -1 { + return false + } + + return false +} + +func (e *G2) EncodeCompressed() []byte { + // Check nil pointers + if e.p == nil { + e.p = &twistPoint{} + } + + e.p.MakeAffine() + ret := make([]byte, G2CompressedSize) + + // Flag the encoding with the compressed flag + ret[0] |= serializationCompressed + + if e.p.IsInfinity() { + // Flag the encoding with the infinity flag + ret[0] |= serializationInfinity + return ret + } + + if e.IsHigherY() { + // Flag the encoding with the bigY flag + ret[0] |= serializationBigY + } + + // We start the serialization of the coordinates at the index 1 + // Since the index 0 in the `ret` corresponds to the masking + // + // `temp` contains the the x-coordinate of the point + // Thus, to fully encode `temp`, we need to Marshal it's x coefficient and y coefficient + temp := gfP2Decode(&e.p.x) + temp.x.Marshal(ret[1:]) + temp.y.Marshal(ret[FqElementSize+1:]) + + return ret +} + +// Takes a MontEncoded x and finds the corresponding y (one of the two possible y's) +func getYFromMontEncodedXG2(x *gfP2) (*gfP2, error) { + // Check nil pointers + if x == nil { + return nil, errors.New("Cannot retrieve the y-coordinate from a nil pointer") + } + + x2 := new(gfP2).Mul(x, x) + x3 := new(gfP2).Mul(x2, x) + rhs := new(gfP2).Add(x3, twistB) // twistB is MontEncoded, since it is create with newGFp + + yCoord, err := rhs.Sqrt() + if err != nil { + return nil, err + } + + return yCoord, nil +} + +// DecodeCompressed decodes a point in the compressed form +// Take a point P in G2 decoded (ie: written in affine form where each coordinate is MontDecoded) +// and encodes it by going back to Jacobian coordinates and montEncode all coordinates +func (e *G2) DecodeCompressed(encoding []byte) error { + if len(encoding) != G2CompressedSize { + return errors.New("wrong encoded point size") + } + if encoding[0]&serializationCompressed == 0 { // Also test the length of the encoding to make sure it is 33bytes + return errors.New("point isn't compressed") + } + + // Unmarshal the points and check their caps + if e.p == nil { + e.p = &twistPoint{} + } else { + e.p.x.SetZero() + e.p.y.SetZero() + e.p.z.SetOne() + e.p.t.SetOne() + } + + // Removes the bits of the masking (This does a bitwise AND with `0001 1111`) + // And thus removes the first 3 bits corresponding to the masking + bin := make([]byte, G2CompressedSize) + copy(bin, encoding) + bin[0] &= serializationMask + + // Decode the point at infinity in the compressed form + if encoding[0]&serializationInfinity != 0 { + if encoding[0]&serializationBigY != 0 { + return errors.New("high Y bit improperly set") + } + + // Similar to `for i:=0; i= 0 { + out = &gfP{uint64(x)} + } else { + out = &gfP{uint64(-x)} + gfpNeg(out, out) + } + + montEncode(out, out) + return out +} + +func (e *gfP) String() string { + return fmt.Sprintf("%16.16x%16.16x%16.16x%16.16x", e[3], e[2], e[1], e[0]) +} + +/* +func byteToUint64(in []byte) (uint64, error) { + if len(in) > 8 { + return 0, errors.New("the input bytes length should be equal to 8 (or smaller)") + } + + // Takes the bytes in the little endian order + // The byte 0x64 translate in a uint64 of the shape 0x64 (= 0x0000000000000064) rather than 0x6400000000000000 + res := binary.LittleEndian.Uint64(in) + return res, nil +} +*/ + +// Makes sure that the +func padBytes(bb []byte) ([]byte, error) { + if len(bb) > 32 { + return []byte{}, errors.New("Cannot pad the given byte slice as the length exceed the padding length") + } + + if len(bb) == 32 { + return bb, nil + } + + padSlice := make([]byte, 32) + index := len(padSlice) - len(bb) + copy(padSlice[index:], bb) + return padSlice, nil +} + +// Convert a big.Int into gfP +func newGFpFromBigInt(in *big.Int) (out *gfP) { + // in >= P, so we mod it to get back in the field + // (ie: we get the smallest representative of the equivalence class mod P) + if res := in.Cmp(P); res >= 0 { + // We need to mod P to get back into the field + in.Mod(in, P) + } + + inBytes := in.Bytes() + // We want to work on byte slices of length 32 to re-assemble our GFpe element + if len(inBytes) < 32 { + // Safe to ignore the err as we are in the if so the condition is satisfied + inBytes, _ = padBytes(inBytes) + } + + out = &gfP{} + var n uint64 + // Now we have the guarantee that inBytes has length 32 so it makes sense to run this for + // loop safely (we won't exceed the boundaries of the container) + for i := 0; i < FpUint64Size; i++ { + buf := bytes.NewBuffer(inBytes[i*8 : (i+1)*8]) + binary.Read(buf, binary.BigEndian, &n) + out[(FpUint64Size-1)-i] = n // In gfP field elements are represented as little-endian 64-bit words + } + + return out +} + +// Returns a new element of GFp montgomery encoded +func newMontEncodedGFpFromBigInt(in *big.Int) *gfP { + res := newGFpFromBigInt(in) + montEncode(res, res) + + return res +} + +// Convert a gfP into a big.Int +func (e *gfP) gFpToBigInt() (*big.Int, error) { + str := e.String() + + out := new(big.Int) + _, ok := out.SetString(str, 16) + if !ok { + return nil, errors.New("couldn't create big.Int from gfP element") + } + + return out, nil +} + +func (e *gfP) Set(f *gfP) { + e[0] = f[0] + e[1] = f[1] + e[2] = f[2] + e[3] = f[3] +} + +func (e *gfP) Invert(f *gfP) { + bits := [4]uint64{0x3c208c16d87cfd45, 0x97816a916871ca8d, 0xb85045b68181585d, 0x30644e72e131a029} + + sum, power := &gfP{}, &gfP{} + sum.Set(rN1) + power.Set(f) + + for word := 0; word < 4; word++ { + for bit := uint(0); bit < 64; bit++ { + if (bits[word]>>bit)&1 == 1 { + gfpMul(sum, sum, power) + } + gfpMul(power, power, power) + } + } + + gfpMul(sum, sum, r3) + e.Set(sum) +} + +func (e *gfP) Marshal(out []byte) { + for w := uint(0); w < 4; w++ { + for b := uint(0); b < 8; b++ { + out[8*w+b] = byte(e[3-w] >> (56 - 8*b)) + } + } +} + +func (e *gfP) Unmarshal(in []byte) error { + // Unmarshal the bytes into little endian form + for w := uint(0); w < 4; w++ { + for b := uint(0); b < 8; b++ { + e[3-w] += uint64(in[8*w+b]) << (56 - 8*b) + } + } + // Ensure the point respects the curve modulus + for i := 3; i >= 0; i-- { + if e[i] < p2[i] { + return nil + } + if e[i] > p2[i] { + return errors.New("bn256: coordinate exceeds modulus") + } + } + return errors.New("bn256: coordinate equals modulus") +} + +// Note: This function is only used to distinguish between points with the same x-coordinates +// when doing point compression. +// An ordered field must be infinite and we are working over a finite field here +func gfpCmp(a, b *gfP) int { + for i := FpUint64Size - 1; i >= 0; i-- { // Remember that the gfP elements are written as little-endian 64-bit words + if a[i] > b[i] { // As soon as we figure out that the MSByte of A > MSByte of B, we return + return 1 + } else if a[i] == b[i] { // If the current bytes are equal we continue as we cannot conclude on A and B relation + continue + } else { // a[i] < b[i] so we can directly conclude and we return + return -1 + } + } + + return 0 +} + +// In Montgomery representation, an element x is represented by xR mod p, where +// R is a power of 2 corresponding to the number of machine-words that can contain p. +// (where p is the characteristic of the prime field we work over) +// See: https://web.wpi.edu/Pubs/ETD/Available/etd-0430102-120529/unrestricted/thesis.pdf +func montEncode(c, a *gfP) { gfpMul(c, a, r2) } +func montDecode(c, a *gfP) { gfpMul(c, a, &gfP{1}) } diff --git a/cryptography/bn256/gfp12.go b/cryptography/bn256/gfp12.go new file mode 100644 index 0000000..287b8be --- /dev/null +++ b/cryptography/bn256/gfp12.go @@ -0,0 +1,160 @@ +package bn256 + +// For details of the algorithms used, see "Multiplication and Squaring on +// Pairing-Friendly Fields, Devegili et al. +// http://eprint.iacr.org/2006/471.pdf. + +import ( + "math/big" +) + +// gfP12 implements the field of size p¹² as a quadratic extension of gfP6 +// where ω²=τ. +type gfP12 struct { + x, y gfP6 // value is xω + y +} + +func (e *gfP12) String() string { + return "(" + e.x.String() + "," + e.y.String() + ")" +} + +func (e *gfP12) Set(a *gfP12) *gfP12 { + e.x.Set(&a.x) + e.y.Set(&a.y) + return e +} + +func (e *gfP12) SetZero() *gfP12 { + e.x.SetZero() + e.y.SetZero() + return e +} + +func (e *gfP12) SetOne() *gfP12 { + e.x.SetZero() + e.y.SetOne() + return e +} + +func (e *gfP12) IsZero() bool { + return e.x.IsZero() && e.y.IsZero() +} + +func (e *gfP12) IsOne() bool { + return e.x.IsZero() && e.y.IsOne() +} + +func (e *gfP12) Conjugate(a *gfP12) *gfP12 { + e.x.Neg(&a.x) + e.y.Set(&a.y) + return e +} + +func (e *gfP12) Neg(a *gfP12) *gfP12 { + e.x.Neg(&a.x) + e.y.Neg(&a.y) + return e +} + +// Frobenius computes (xω+y)^p = x^p ω·ξ^((p-1)/6) + y^p +func (e *gfP12) Frobenius(a *gfP12) *gfP12 { + e.x.Frobenius(&a.x) + e.y.Frobenius(&a.y) + e.x.MulScalar(&e.x, xiToPMinus1Over6) + return e +} + +// FrobeniusP2 computes (xω+y)^p² = x^p² ω·ξ^((p²-1)/6) + y^p² +func (e *gfP12) FrobeniusP2(a *gfP12) *gfP12 { + e.x.FrobeniusP2(&a.x) + e.x.MulGFP(&e.x, xiToPSquaredMinus1Over6) + e.y.FrobeniusP2(&a.y) + return e +} + +func (e *gfP12) FrobeniusP4(a *gfP12) *gfP12 { + e.x.FrobeniusP4(&a.x) + e.x.MulGFP(&e.x, xiToPSquaredMinus1Over3) + e.y.FrobeniusP4(&a.y) + return e +} + +func (e *gfP12) Add(a, b *gfP12) *gfP12 { + e.x.Add(&a.x, &b.x) + e.y.Add(&a.y, &b.y) + return e +} + +func (e *gfP12) Sub(a, b *gfP12) *gfP12 { + e.x.Sub(&a.x, &b.x) + e.y.Sub(&a.y, &b.y) + return e +} + +func (e *gfP12) Mul(a, b *gfP12) *gfP12 { + tx := (&gfP6{}).Mul(&a.x, &b.y) + t := (&gfP6{}).Mul(&b.x, &a.y) + tx.Add(tx, t) + + ty := (&gfP6{}).Mul(&a.y, &b.y) + t.Mul(&a.x, &b.x).MulTau(t) + + e.x.Set(tx) + e.y.Add(ty, t) + return e +} + +func (e *gfP12) MulScalar(a *gfP12, b *gfP6) *gfP12 { + e.x.Mul(&e.x, b) + e.y.Mul(&e.y, b) + return e +} + +func (e *gfP12) Exp(a *gfP12, power *big.Int) *gfP12 { + sum := (&gfP12{}).SetOne() + t := &gfP12{} + + for i := power.BitLen() - 1; i >= 0; i-- { + t.Square(sum) + if power.Bit(i) != 0 { + sum.Mul(t, a) + } else { + sum.Set(t) + } + } + + e.Set(sum) + return e +} + +func (e *gfP12) Square(a *gfP12) *gfP12 { + // Complex squaring algorithm + v0 := (&gfP6{}).Mul(&a.x, &a.y) + + t := (&gfP6{}).MulTau(&a.x) + t.Add(&a.y, t) + ty := (&gfP6{}).Add(&a.x, &a.y) + ty.Mul(ty, t).Sub(ty, v0) + t.MulTau(v0) + ty.Sub(ty, t) + + e.x.Add(v0, v0) + e.y.Set(ty) + return e +} + +func (e *gfP12) Invert(a *gfP12) *gfP12 { + // See "Implementing cryptographic pairings", M. Scott, section 3.2. + // ftp://136.206.11.249/pub/crypto/pairings.pdf + t1, t2 := &gfP6{}, &gfP6{} + + t1.Square(&a.x) + t2.Square(&a.y) + t1.MulTau(t1).Sub(t2, t1) + t2.Invert(t1) + + e.x.Neg(&a.x) + e.y.Set(&a.y) + e.MulScalar(e, t2) + return e +} diff --git a/cryptography/bn256/gfp2.go b/cryptography/bn256/gfp2.go new file mode 100644 index 0000000..766b177 --- /dev/null +++ b/cryptography/bn256/gfp2.go @@ -0,0 +1,327 @@ +package bn256 + +import ( + "errors" + "math" + "math/big" +) + +// For details of the algorithms used, see "Multiplication and Squaring on +// Pairing-Friendly Fields, Devegili et al. +// http://eprint.iacr.org/2006/471.pdf. + +// gfP2 implements a field of size p² as a quadratic extension of the base field +// where i²=-1. +type gfP2 struct { + x, y gfP // value is xi+y. +} + +func gfP2Decode(in *gfP2) *gfP2 { + out := &gfP2{} + montDecode(&out.x, &in.x) + montDecode(&out.y, &in.y) + return out +} + +func (e *gfP2) String() string { + return "(" + e.x.String() + ", " + e.y.String() + ")" +} + +func (e *gfP2) Set(a *gfP2) *gfP2 { + e.x.Set(&a.x) + e.y.Set(&a.y) + return e +} + +func (e *gfP2) SetZero() *gfP2 { + e.x = gfP{0} + e.y = gfP{0} + return e +} + +func (e *gfP2) SetOne() *gfP2 { + e.x = gfP{0} + e.y = *newGFp(1) + return e +} + +func (e *gfP2) IsZero() bool { + zero := gfP{0} + return e.x == zero && e.y == zero +} + +func (e *gfP2) IsOne() bool { + zero, one := gfP{0}, *newGFp(1) + return e.x == zero && e.y == one +} + +func (e *gfP2) Conjugate(a *gfP2) *gfP2 { + e.y.Set(&a.y) + gfpNeg(&e.x, &a.x) + return e +} + +func (e *gfP2) Neg(a *gfP2) *gfP2 { + gfpNeg(&e.x, &a.x) + gfpNeg(&e.y, &a.y) + return e +} + +func (e *gfP2) Add(a, b *gfP2) *gfP2 { + gfpAdd(&e.x, &a.x, &b.x) + gfpAdd(&e.y, &a.y, &b.y) + return e +} + +func (e *gfP2) Sub(a, b *gfP2) *gfP2 { + gfpSub(&e.x, &a.x, &b.x) + gfpSub(&e.y, &a.y, &b.y) + return e +} + +// See "Multiplication and Squaring in Pairing-Friendly Fields", +// http://eprint.iacr.org/2006/471.pdf Section 3 "Schoolbook method" +func (e *gfP2) Mul(a, b *gfP2) *gfP2 { + tx, t := &gfP{}, &gfP{} + gfpMul(tx, &a.x, &b.y) // tx = a.x * b.y + gfpMul(t, &b.x, &a.y) // t = b.x * a.y + gfpAdd(tx, tx, t) // tx = a.x * b.y + b.x * a.y + + ty := &gfP{} + gfpMul(ty, &a.y, &b.y) // ty = a.y * b.y + gfpMul(t, &a.x, &b.x) // t = a.x * b.x + // We do a subtraction in the field since β = -1 in our case + // In fact, Fp2 is built using the irreducible polynomial X^2 - β, where β = -1 = p-1 + gfpSub(ty, ty, t) // ty = a.y * b.y - a.x * b.x + + e.x.Set(tx) // e.x = a.x * b.y + b.x * a.y + e.y.Set(ty) // e.y = a.y * b.y - a.x * b.x + return e +} + +func (e *gfP2) MulScalar(a *gfP2, b *gfP) *gfP2 { + gfpMul(&e.x, &a.x, b) + gfpMul(&e.y, &a.y, b) + return e +} + +// MulXi sets e=ξa where ξ=i+9 and then returns e. +func (e *gfP2) MulXi(a *gfP2) *gfP2 { + // (xi+y)(i+9) = (9x+y)i+(9y-x) + tx := &gfP{} + gfpAdd(tx, &a.x, &a.x) + gfpAdd(tx, tx, tx) + gfpAdd(tx, tx, tx) + gfpAdd(tx, tx, &a.x) + + gfpAdd(tx, tx, &a.y) + + ty := &gfP{} + gfpAdd(ty, &a.y, &a.y) + gfpAdd(ty, ty, ty) + gfpAdd(ty, ty, ty) + gfpAdd(ty, ty, &a.y) + + gfpSub(ty, ty, &a.x) + + e.x.Set(tx) + e.y.Set(ty) + return e +} + +func (e *gfP2) Square(a *gfP2) *gfP2 { + // Complex squaring algorithm: + // (xi+y)² = (x+y)(y-x) + 2*i*x*y + // - "Devegili OhEig Scott Dahab --- Multiplication and Squaring on Pairing-Friendly Fields.pdf"; Section 3 (Complex squaring) + // - URL: https://eprint.iacr.org/2006/471.pdf + // Here, since the non residue used is β = -1 in Fp, then we have: + // c0 = (a0 + a1)(a0 + βa1) - v0 - βv0 => c0 = (a0 + a1)(a0 - a1) + // c1 = 2v0, where v0 is a0 * a1 (= x * y, with our notations) + tx, ty := &gfP{}, &gfP{} + gfpSub(tx, &a.y, &a.x) // a.y - a.x + gfpAdd(ty, &a.x, &a.y) // a.x + a.y + gfpMul(ty, tx, ty) + + gfpMul(tx, &a.x, &a.y) + gfpAdd(tx, tx, tx) + + e.x.Set(tx) + e.y.Set(ty) + return e +} + +func (e *gfP2) Invert(a *gfP2) *gfP2 { + // See "Implementing cryptographic pairings", M. Scott, section 3.2. + // ftp://136.206.11.249/pub/crypto/pairings.pdf + t1, t2 := &gfP{}, &gfP{} + gfpMul(t1, &a.x, &a.x) + gfpMul(t2, &a.y, &a.y) + gfpAdd(t1, t1, t2) + + inv := &gfP{} + inv.Invert(t1) + + gfpNeg(t1, &a.x) + + gfpMul(&e.x, t1, inv) + gfpMul(&e.y, &a.y, inv) + return e +} + +// Exp is a function to exponentiate field elements +// This function navigates the big.Int binary representation +// from left to right (assumed to be in big endian) +// When going from left to right, each bit is checked, and when the first `1` bit is found +// the `foundOne` flag is set, and the "exponentiation begins" +// +// Eg: Let's assume that we want to exponentiate 3^5 +// then the exponent is 5 = 0000 0101 +// We navigate 0000 0101 from left to right until we reach 0000 0101 +// ^ +// | +// When this bit is reached, the flag `foundOne` is set, and and we do: +// res = res * 3 = 3 +// Then, we move on to the left to read the next bit, and since `foundOne` is set (ie: +// the exponentiation has started), then we square the result, and do: +// res = res * res = 3*3 = 3^2 +// The bit is `0`, so we continue +// Next bit is `1`, so we do: res = res * res = 3^2 * 3^2 = 3^4 +// and because the bit is `1`, then, we do res = res * 3 = 3^4 * 3 = 3^5 +// We reached the end of the bit string, so we can stop. +// +// The binary representation of the exponent is assumed to be binary big endian +// +// Careful, since `res` is initialized with SetOne() and since this function +// initializes the calling gfP2 to the one element of the Gfp2 which is montEncoded +// then, we need to make sure that the `e` element of gfP2 used to call the Exp function +// is also montEncoded (ie; both x and y are montEncoded) +/* +TODO: Refactor this function like this: +func (e *gfP2) Exp(a *gfP2, exponent *big.Int) *gfP2 { + sum := (&gfP2{}).SetOne() + t := &gfP2{} + + for i := exponent.BitLen() - 1; i >= 0; i-- { + t.Square(sum) + if exponent.Bit(i) != 0 { + sum.Mul(t, a) + } else { + sum.Set(t) + } + } + + e.Set(sum) + return e +} +*/ +func (e *gfP2) Exp(exponent *big.Int) *gfP2 { + res := &gfP2{} + res = res.SetOne() + + base := &gfP2{} + base = base.Set(e) + + foundOne := false + exponentBytes := exponent.Bytes() // big endian bytes slice + + for i := 0; i < len(exponentBytes); i++ { // for each byte (remember the slice is big endian) + for j := 0; j <= 7; j++ { // A byte contains the powers of 2 to 2^7 to 2^0 from left to right + if foundOne { + res = res.Mul(res, res) + } + + if uint(exponentBytes[i])&uint(math.Pow(2, float64(7-j))) != uint(0) { // a byte contains the powers of 2 from 2^7 to 2^0 hence why we do 2^(7-j) (big-endian assumed) + foundOne = true + res = res.Mul(res, base) + } + } + } + + e.Set(res) + return e +} + +// Sqrt returns the square root of e in GFp2 +// See: +// - "A High-Speed Square Root Algorithm for Extension Fields - Especially for Fast Extension Fields" +// - URL: https://core.ac.uk/download/pdf/12530172.pdf +// +// - "Square Roots Modulo p" +// - URL: http://www.cmat.edu.uy/~tornaria/pub/Tornaria-2002.pdf +// +// - "Faster square roots in annoying finite fields" +// - URL: http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.21.9172 +func (e *gfP2) Sqrt() (*gfP2, error) { + // In GF(p^m), Euler's Criterion is defined like EC(x) = x^((p^m -1) / 2), if EC(x) == 1, x is a QR; if EC(x) == -1, x is a QNR + // `euler` here, is the exponent used in Euler's criterion, thus, euler = (p^m -1) / 2 for GF(p^m) + // here, we work over GF(p^2), so euler = (p^2 -1) / 2, where p = 21888242871839275222246405745257275088696311157297823662689037894645226208583 + ////euler := bigFromBase10("239547588008311421220994022608339370399626158265550411218223901127035046843189118723920525909718935985594116157406550130918127817069793474323196511433944") + + // modulus^2 = 2^s * t + 1 => p^2 = 2^s * t + 1, where t is odd + // In our case, p^2 = 2^s * t + 1, where s = 4, t = 29943448501038927652624252826042421299953269783193801402277987640879380855398639840490065738714866998199264519675818766364765977133724184290399563929243 + ////t := bigFromBase10("29943448501038927652624252826042421299953269783193801402277987640879380855398639840490065738714866998199264519675818766364765977133724184290399563929243") + ////s := bigFromBase10("4") + s := 4 + + // tMinus1Over2 = (t-1) / 2 + tMinus1Over2 := bigFromBase10("14971724250519463826312126413021210649976634891596900701138993820439690427699319920245032869357433499099632259837909383182382988566862092145199781964621") + + // A non quadratic residue in Fp + ////nonResidueFp := bigFromBase10("21888242871839275222246405745257275088696311157297823662689037894645226208582") + + // A non quadratic residue in Fp2. Here nonResidueFp2 = i + 2 (Euler Criterion applied to this element of Fp2 shows that this element is a QNR) + ////nonResidueFp2 := &gfP2{*newGFp(1), *newGFp(2)} + + // nonResidueFp2 ^ t + nonResidueFp2ToTXCoord := bigFromBase10("314498342015008975724433667930697407966947188435857772134235984660852259084") + nonResidueFp2ToTYCoord := bigFromBase10("5033503716262624267312492558379982687175200734934877598599011485707452665730") + nonResidueFp2ToT := &gfP2{*newMontEncodedGFpFromBigInt(nonResidueFp2ToTXCoord), *newMontEncodedGFpFromBigInt(nonResidueFp2ToTYCoord)} + + // Start algorithm + // Initialize the algorithm variables + v := s + z := nonResidueFp2ToT + w := new(gfP2).Set(e) + w = w.Exp(tMinus1Over2) + x := new(gfP2).Mul(e, w) + b := new(gfP2).Mul(x, w) // contains e^t + + // Check if the element is a QR + // Since p^2 = 2^s * t + 1 => t = (p^2 - 1)/2 + // Thus, since we have b = e^t, and since we want to test if e is a QR + // we need to square b (s-1) times. That way we'd have + // (e^t)^{2^(s-1)} which equals e^{(p^2 - 1)/2} => Euler criterion + bCheck := new(gfP2).Set(b) + for i := 0; i < s-1; i++ { // s-1 == 3 here (see comment above) + bCheck = bCheck.Square(bCheck) + } + + if !bCheck.IsOne() { + return nil, errors.New("Cannot extract a root. The element is not a QR in Fp2") + } + + // Extract the root of the quadratic residue using the Tonelli-Shanks algorithm + for !b.IsOne() { + m := 0 + b2m := new(gfP2).Set(b) + for !b2m.IsOne() { + /* invariant: b2m = b^(2^m) after entering this loop */ + b2m = b2m.Square(b2m) + m++ + } + + j := v - m - 1 + w = z + for j > 0 { + w = w.Square(w) + j-- + } // w = z^2^(v-m-1) + + z = new(gfP2).Square(w) + b = b.Mul(b, z) + x = x.Mul(x, w) + v = m + } + + return x, nil +} diff --git a/cryptography/bn256/gfp2_test.go b/cryptography/bn256/gfp2_test.go new file mode 100644 index 0000000..cfbdb29 --- /dev/null +++ b/cryptography/bn256/gfp2_test.go @@ -0,0 +1,164 @@ +package bn256 + +import ( + "testing" + + "github.com/stretchr/testify/assert" +) + +// Tests that the exponentiation in gfp2 works correctly +// SageMath test vector: +/* +p = 21888242871839275222246405745257275088696311157297823662689037894645226208583 +Fp = GF(p) +Fpx. = PolynomialRing(Fp, 'j') +// The modulus is in the form `j^2 - non-residue-in-Fp` +// Fp2. = GF(p^2, modulus=j^2 - 3) // 3 is a quadratic non-residue in Fp +// See: https://github.com/scipr-lab/libff/blob/master/libff/algebra/curves/alt_bn128/alt_bn128_init.cpp#L95 +// The quadratic non-residue used in -1, so the modulus is +Fp2. = GF(p^2, modulus=j^2 + 1) + +// Quad. Non. Resid. test (Euler's criterion) +eulerExp = (Fp(p-1)/Fp(2)) +Fp(-1)^eulerExp + Fp(1) == p // Should return true, then we see that -1 (ie: p-1) is a nqr (non quadratic residue mod p) + +// Element taken randomly in the field Fp2 +// we denote an element of Fp2 as: e = x*i + y +baseElement = 8192512702373747571754527085437364828369119615795326562285198594140975111129*i + 14719814144181528030533020377409648968040866053797156997322427920899698335369 + +// baseElementXHex = hex(8192512702373747571754527085437364828369119615795326562285198594140975111129) +baseElementXHex = 121ccc410d6339f7 bbc9a8f5b577c5c5 96c9dfdd6233cbac 34a8ddeafedf9bd9 +baseElementXHexLittleEndian = 34a8ddeafedf9bd9 96c9dfdd6233cbac bbc9a8f5b577c5c5 121ccc410d6339f7 + +// baseElementYHex = hex(14719814144181528030533020377409648968040866053797156997322427920899698335369) +baseElementYHex = 208b1e9b9b11a98c 30a84b2641e87244 9a54780d0e482cfb 146adf9eb7641e89 +baseElementYHexLittleEndian = 146adf9eb7641e89 9a54780d0e482cfb 30a84b2641e87244 208b1e9b9b11a98c + +// We run in Sage, resExponentiation = baseElement ^ 5, and we get +baseElementTo5 = baseElement ^ 5 +baseElementTo5 = 1919494216989370714282264091499504460829540920627494019318177103740489354093*i + 3944397571509712892671395330294281468555185483198747137614153093242854529958 +baseElementTo5XHex = 043e652d8f044857 c4cbfe9636928309 44288a2a00432390 7fa7e33a3e5acb6d +baseElementTo5XHexLittleEndian = 7fa7e33a3e5acb6d 44288a2a00432390 c4cbfe9636928309 043e652d8f044857 + +baseElementTo5YHex = 08b8732d547b1cda b5c82ff0bfaa42c1 54e7b24b65223fc2 88b3e8a6de535ba6 +baseElementTo5XHexLittleEndian = 88b3e8a6de535ba6 54e7b24b65223fc2 b5c82ff0bfaa42c1 08b8732d547b1cda +*/ +func TestExp(t *testing.T) { + // Case 1: Exponent = 5 (= 0x05) + baseElementX := &gfP{0x34a8ddeafedf9bd9, 0x96c9dfdd6233cbac, 0xbbc9a8f5b577c5c5, 0x121ccc410d6339f7} + baseElementY := &gfP{0x146adf9eb7641e89, 0x9a54780d0e482cfb, 0x30a84b2641e87244, 0x208b1e9b9b11a98c} + // montEncode each Fp element + // Important to do since the field arithmetic uses montgomery encoding in the library + montEncode(baseElementX, baseElementX) + montEncode(baseElementY, baseElementY) + baseElement := &gfP2{*baseElementX, *baseElementY} + + // We keep the expected result non encoded + // Will need to decode the obtained result to be able to assert it with this + baseElementTo5X := &gfP{0x7fa7e33a3e5acb6d, 0x44288a2a00432390, 0xc4cbfe9636928309, 0x043e652d8f044857} + baseElementTo5Y := &gfP{0x88b3e8a6de535ba6, 0x54e7b24b65223fc2, 0xb5c82ff0bfaa42c1, 0x08b8732d547b1cda} + baseElementTo5 := &gfP2{*baseElementTo5X, *baseElementTo5Y} + + // Manual multiplication, to make sure the results are all coherent with each other + manual := &gfP2{} + manual = manual.Set(baseElement) + manual = manual.Mul(manual, manual) // manual ^ 2 + manual = manual.Mul(manual, manual) // manual ^ 4 + manual = manual.Mul(manual, baseElement) // manual ^ 5 + manualDecoded := gfP2Decode(manual) + + // Expected result (obtained with sagemath, after some type conversions) + w := &gfP2{} + w = w.Set(baseElementTo5) + + // Result returned by the Exp function + exponent5 := bigFromBase10("5") + h := &gfP2{} + h = h.Set(baseElement) + h = h.Exp(exponent5) + + // We decode the result of the exponentiation to be able to compare with the + // non-encoded/sagemath generated expected result + hDecoded := gfP2Decode(h) + + assert.Equal(t, *w, *hDecoded, "The result of the exponentiation is not coherent with the Sagemath test vector") + assert.Equal(t, *manualDecoded, *hDecoded, "The result of the exponentiation is not coherent with the manual repeated multiplication") + + // Case 2: Exponent = bigExponent = 39028236692093846773374607431768211455 + 2^128 - 2^64 = 379310603613032310218302470789826871295 = 0x11d5c90a20486bd1c40686b493777ffff + // This exponent can be encoded on 3 words/uint64 => 0x1 0x1d5c90a20486bd1c 0x40686b493777ffff if 64bit machine or + // on 5 words/uint32 => 0x1 0x1d5c90a2 0x0486bd1c 0x40686b49 0x3777ffff if 32bit machine + baseElementX = &gfP{0x34a8ddeafedf9bd9, 0x96c9dfdd6233cbac, 0xbbc9a8f5b577c5c5, 0x121ccc410d6339f7} + baseElementY = &gfP{0x146adf9eb7641e89, 0x9a54780d0e482cfb, 0x30a84b2641e87244, 0x208b1e9b9b11a98c} + // montEncode each Fp element + // Important to do since the field arithmetic uses montgomery encoding in the library + montEncode(baseElementX, baseElementX) + montEncode(baseElementY, baseElementY) + baseElement = &gfP2{*baseElementX, *baseElementY} + + // We keep the expected result non encoded + // Will need to decode the obtained result to be able to assert it with this + // Sagemath: + // baseElementToBigExp = baseElement ^ bigExponent + // baseElementToBigExp => 7379142427977467878031119988604583496475317621776403696479934226513132928021*i + 17154720713365092794088637301427106756251681045968150072197181728711103784706 + // baseElementToBigExpXHex = 10507254ce787236 62cf3f84eb21adee 30ec827a799a519a 1464fc2ec9263c15 + // baseElementToBigExpYHex = 25ed3a53d558db9a 07da01cc9d10c5d5 ff7b1e4f41b874d7 debbc13409c8a702 + baseElementToBigExpX := &gfP{0x1464fc2ec9263c15, 0x30ec827a799a519a, 0x62cf3f84eb21adee, 0x10507254ce787236} + baseElementToBigExpY := &gfP{0xdebbc13409c8a702, 0xff7b1e4f41b874d7, 0x07da01cc9d10c5d5, 0x25ed3a53d558db9a} + baseElementToBigExp := &gfP2{*baseElementToBigExpX, *baseElementToBigExpY} + + // Expected result (obtained with sagemath, after some type conversions) + w = &gfP2{} + w = w.Set(baseElementToBigExp) + + // Result returned by the Exp function + bigExp := bigFromBase10("379310603613032310218302470789826871295") + h = &gfP2{} + h = h.Set(baseElement) + h = h.Exp(bigExp) + + // We decode the result of the exponentiation to be able to compare with the + // non-encoded/sagemath generated expected result + hDecoded = gfP2Decode(h) + + assert.Equal(t, *w, *hDecoded, "The result of the exponentiation is not coherent with the Sagemath test vector") +} + +func TestSqrt(t *testing.T) { + // Case 1: Valid QR + // qr = 8192512702373747571754527085437364828369119615795326562285198594140975111129*i + 14719814144181528030533020377409648968040866053797156997322427920899698335369 + // This is a QR in Fp2 + qrXBig := bigFromBase10("8192512702373747571754527085437364828369119615795326562285198594140975111129") + qrYBig := bigFromBase10("14719814144181528030533020377409648968040866053797156997322427920899698335369") + qr := &gfP2{*newMontEncodedGFpFromBigInt(qrXBig), *newMontEncodedGFpFromBigInt(qrYBig)} + res, err := qr.Sqrt() + assert.NoError(t, err, "An error shouldn't be returned as we try to get the sqrt of a QR") + // We decode the result of the squaring to compare the result with the Sagemath test vector + // To get the sqrt of `r` in Sage, we run: `r.sqrt()`, and we get: + // 838738240039331261565244756819667559640832302782323121523807597830118111128*i + 701115843855913009657260259360827182296091347204618857804078039211229345012 + resDecoded := gfP2Decode(res) + expectedXBig := bigFromBase10("838738240039331261565244756819667559640832302782323121523807597830118111128") + expectedYBig := bigFromBase10("701115843855913009657260259360827182296091347204618857804078039211229345012") + expected := &gfP2{*newGFpFromBigInt(expectedXBig), *newGFpFromBigInt(expectedYBig)} + + assert.Equal(t, *expected, *resDecoded, "The result of the sqrt is not coherent with the Sagemath test vector") + + // Case 2: Valid QR + // qr = -1 = 0 * i + 21888242871839275222246405745257275088696311157297823662689037894645226208582 + // The sqrt of qr is: sqrt = 21888242871839275222246405745257275088696311157297823662689037894645226208582 * i + 0 + qr = &gfP2{*newGFp(0), *newMontEncodedGFpFromBigInt(bigFromBase10("21888242871839275222246405745257275088696311157297823662689037894645226208582"))} + res, err = qr.Sqrt() + assert.NoError(t, err, "An error shouldn't be returned as we try to get the sqrt of a QR") + + resDecoded = gfP2Decode(res) + expected = &gfP2{*newGFpFromBigInt(bigFromBase10("21888242871839275222246405745257275088696311157297823662689037894645226208582")), *newGFp(0)} + assert.Equal(t, *expected, *resDecoded, "The result of the sqrt is not coherent with the Sagemath test vector") + + // Case 3: Get the sqrt of a QNR + // qnr = 10142231111593789910248975994434553601587001629804098271704323146176084338608*i + 13558357083504759335548106329923635779485621365040524539176938811542516618464 + qnrXBig := bigFromBase10("10142231111593789910248975994434553601587001629804098271704323146176084338608") + qnrYBig := bigFromBase10("13558357083504759335548106329923635779485621365040524539176938811542516618464") + qnr := &gfP2{*newMontEncodedGFpFromBigInt(qnrXBig), *newMontEncodedGFpFromBigInt(qnrYBig)} + res, err = qnr.Sqrt() + assert.Error(t, err, "An error should have been returned as we try to get the sqrt of a QNR") + assert.Nil(t, res, "The result of sqrt should be nil as we try to get the sqrt of a QNR") +} diff --git a/cryptography/bn256/gfp6.go b/cryptography/bn256/gfp6.go new file mode 100644 index 0000000..83d61b7 --- /dev/null +++ b/cryptography/bn256/gfp6.go @@ -0,0 +1,213 @@ +package bn256 + +// For details of the algorithms used, see "Multiplication and Squaring on +// Pairing-Friendly Fields, Devegili et al. +// http://eprint.iacr.org/2006/471.pdf. + +// gfP6 implements the field of size p⁶ as a cubic extension of gfP2 where τ³=ξ +// and ξ=i+3. +type gfP6 struct { + x, y, z gfP2 // value is xτ² + yτ + z +} + +func (e *gfP6) String() string { + return "(" + e.x.String() + ", " + e.y.String() + ", " + e.z.String() + ")" +} + +func (e *gfP6) Set(a *gfP6) *gfP6 { + e.x.Set(&a.x) + e.y.Set(&a.y) + e.z.Set(&a.z) + return e +} + +func (e *gfP6) SetZero() *gfP6 { + e.x.SetZero() + e.y.SetZero() + e.z.SetZero() + return e +} + +func (e *gfP6) SetOne() *gfP6 { + e.x.SetZero() + e.y.SetZero() + e.z.SetOne() + return e +} + +func (e *gfP6) IsZero() bool { + return e.x.IsZero() && e.y.IsZero() && e.z.IsZero() +} + +func (e *gfP6) IsOne() bool { + return e.x.IsZero() && e.y.IsZero() && e.z.IsOne() +} + +func (e *gfP6) Neg(a *gfP6) *gfP6 { + e.x.Neg(&a.x) + e.y.Neg(&a.y) + e.z.Neg(&a.z) + return e +} + +func (e *gfP6) Frobenius(a *gfP6) *gfP6 { + e.x.Conjugate(&a.x) + e.y.Conjugate(&a.y) + e.z.Conjugate(&a.z) + + e.x.Mul(&e.x, xiTo2PMinus2Over3) + e.y.Mul(&e.y, xiToPMinus1Over3) + return e +} + +// FrobeniusP2 computes (xτ²+yτ+z)^(p²) = xτ^(2p²) + yτ^(p²) + z +func (e *gfP6) FrobeniusP2(a *gfP6) *gfP6 { + // τ^(2p²) = τ²τ^(2p²-2) = τ²ξ^((2p²-2)/3) + e.x.MulScalar(&a.x, xiTo2PSquaredMinus2Over3) + // τ^(p²) = ττ^(p²-1) = τξ^((p²-1)/3) + e.y.MulScalar(&a.y, xiToPSquaredMinus1Over3) + e.z.Set(&a.z) + return e +} + +func (e *gfP6) FrobeniusP4(a *gfP6) *gfP6 { + e.x.MulScalar(&a.x, xiToPSquaredMinus1Over3) + e.y.MulScalar(&a.y, xiTo2PSquaredMinus2Over3) + e.z.Set(&a.z) + return e +} + +func (e *gfP6) Add(a, b *gfP6) *gfP6 { + e.x.Add(&a.x, &b.x) + e.y.Add(&a.y, &b.y) + e.z.Add(&a.z, &b.z) + return e +} + +func (e *gfP6) Sub(a, b *gfP6) *gfP6 { + e.x.Sub(&a.x, &b.x) + e.y.Sub(&a.y, &b.y) + e.z.Sub(&a.z, &b.z) + return e +} + +func (e *gfP6) Mul(a, b *gfP6) *gfP6 { + // "Multiplication and Squaring on Pairing-Friendly Fields" + // Section 4, Karatsuba method. + // http://eprint.iacr.org/2006/471.pdf + v0 := (&gfP2{}).Mul(&a.z, &b.z) + v1 := (&gfP2{}).Mul(&a.y, &b.y) + v2 := (&gfP2{}).Mul(&a.x, &b.x) + + t0 := (&gfP2{}).Add(&a.x, &a.y) + t1 := (&gfP2{}).Add(&b.x, &b.y) + tz := (&gfP2{}).Mul(t0, t1) + tz.Sub(tz, v1).Sub(tz, v2).MulXi(tz).Add(tz, v0) + + t0.Add(&a.y, &a.z) + t1.Add(&b.y, &b.z) + ty := (&gfP2{}).Mul(t0, t1) + t0.MulXi(v2) + ty.Sub(ty, v0).Sub(ty, v1).Add(ty, t0) + + t0.Add(&a.x, &a.z) + t1.Add(&b.x, &b.z) + tx := (&gfP2{}).Mul(t0, t1) + tx.Sub(tx, v0).Add(tx, v1).Sub(tx, v2) + + e.x.Set(tx) + e.y.Set(ty) + e.z.Set(tz) + return e +} + +func (e *gfP6) MulScalar(a *gfP6, b *gfP2) *gfP6 { + e.x.Mul(&a.x, b) + e.y.Mul(&a.y, b) + e.z.Mul(&a.z, b) + return e +} + +func (e *gfP6) MulGFP(a *gfP6, b *gfP) *gfP6 { + e.x.MulScalar(&a.x, b) + e.y.MulScalar(&a.y, b) + e.z.MulScalar(&a.z, b) + return e +} + +// MulTau computes τ·(aτ²+bτ+c) = bτ²+cτ+aξ +func (e *gfP6) MulTau(a *gfP6) *gfP6 { + tz := (&gfP2{}).MulXi(&a.x) + ty := (&gfP2{}).Set(&a.y) + + e.y.Set(&a.z) + e.x.Set(ty) + e.z.Set(tz) + return e +} + +func (e *gfP6) Square(a *gfP6) *gfP6 { + v0 := (&gfP2{}).Square(&a.z) + v1 := (&gfP2{}).Square(&a.y) + v2 := (&gfP2{}).Square(&a.x) + + c0 := (&gfP2{}).Add(&a.x, &a.y) + c0.Square(c0).Sub(c0, v1).Sub(c0, v2).MulXi(c0).Add(c0, v0) + + c1 := (&gfP2{}).Add(&a.y, &a.z) + c1.Square(c1).Sub(c1, v0).Sub(c1, v1) + xiV2 := (&gfP2{}).MulXi(v2) + c1.Add(c1, xiV2) + + c2 := (&gfP2{}).Add(&a.x, &a.z) + c2.Square(c2).Sub(c2, v0).Add(c2, v1).Sub(c2, v2) + + e.x.Set(c2) + e.y.Set(c1) + e.z.Set(c0) + return e +} + +func (e *gfP6) Invert(a *gfP6) *gfP6 { + // See "Implementing cryptographic pairings", M. Scott, section 3.2. + // ftp://136.206.11.249/pub/crypto/pairings.pdf + + // Here we can give a short explanation of how it works: let j be a cubic root of + // unity in GF(p²) so that 1+j+j²=0. + // Then (xτ² + yτ + z)(xj²τ² + yjτ + z)(xjτ² + yj²τ + z) + // = (xτ² + yτ + z)(Cτ²+Bτ+A) + // = (x³ξ²+y³ξ+z³-3ξxyz) = F is an element of the base field (the norm). + // + // On the other hand (xj²τ² + yjτ + z)(xjτ² + yj²τ + z) + // = τ²(y²-ξxz) + τ(ξx²-yz) + (z²-ξxy) + // + // So that's why A = (z²-ξxy), B = (ξx²-yz), C = (y²-ξxz) + t1 := (&gfP2{}).Mul(&a.x, &a.y) + t1.MulXi(t1) + + A := (&gfP2{}).Square(&a.z) + A.Sub(A, t1) + + B := (&gfP2{}).Square(&a.x) + B.MulXi(B) + t1.Mul(&a.y, &a.z) + B.Sub(B, t1) + + C := (&gfP2{}).Square(&a.y) + t1.Mul(&a.x, &a.z) + C.Sub(C, t1) + + F := (&gfP2{}).Mul(C, &a.y) + F.MulXi(F) + t1.Mul(A, &a.z) + F.Add(F, t1) + t1.Mul(B, &a.x).MulXi(t1) + F.Add(F, t1) + + F.Invert(F) + + e.x.Mul(C, F) + e.y.Mul(B, F) + e.z.Mul(A, F) + return e +} diff --git a/cryptography/bn256/gfp_amd64.s b/cryptography/bn256/gfp_amd64.s new file mode 100644 index 0000000..bdb4ffb --- /dev/null +++ b/cryptography/bn256/gfp_amd64.s @@ -0,0 +1,129 @@ +// +build amd64,!generic + +#define storeBlock(a0,a1,a2,a3, r) \ + MOVQ a0, 0+r \ + MOVQ a1, 8+r \ + MOVQ a2, 16+r \ + MOVQ a3, 24+r + +#define loadBlock(r, a0,a1,a2,a3) \ + MOVQ 0+r, a0 \ + MOVQ 8+r, a1 \ + MOVQ 16+r, a2 \ + MOVQ 24+r, a3 + +#define gfpCarry(a0,a1,a2,a3,a4, b0,b1,b2,b3,b4) \ + \ // b = a-p + MOVQ a0, b0 \ + MOVQ a1, b1 \ + MOVQ a2, b2 \ + MOVQ a3, b3 \ + MOVQ a4, b4 \ + \ + SUBQ ·p2+0(SB), b0 \ + SBBQ ·p2+8(SB), b1 \ + SBBQ ·p2+16(SB), b2 \ + SBBQ ·p2+24(SB), b3 \ + SBBQ $0, b4 \ + \ + \ // if b is negative then return a + \ // else return b + CMOVQCC b0, a0 \ + CMOVQCC b1, a1 \ + CMOVQCC b2, a2 \ + CMOVQCC b3, a3 + +#include "mul_amd64.h" +#include "mul_bmi2_amd64.h" + +TEXT ·gfpNeg(SB),0,$0-16 + MOVQ ·p2+0(SB), R8 + MOVQ ·p2+8(SB), R9 + MOVQ ·p2+16(SB), R10 + MOVQ ·p2+24(SB), R11 + + MOVQ a+8(FP), DI + SUBQ 0(DI), R8 + SBBQ 8(DI), R9 + SBBQ 16(DI), R10 + SBBQ 24(DI), R11 + + MOVQ $0, AX + gfpCarry(R8,R9,R10,R11,AX, R12,R13,R14,R15,BX) + + MOVQ c+0(FP), DI + storeBlock(R8,R9,R10,R11, 0(DI)) + RET + +TEXT ·gfpAdd(SB),0,$0-24 + MOVQ a+8(FP), DI + MOVQ b+16(FP), SI + + loadBlock(0(DI), R8,R9,R10,R11) + MOVQ $0, R12 + + ADDQ 0(SI), R8 + ADCQ 8(SI), R9 + ADCQ 16(SI), R10 + ADCQ 24(SI), R11 + ADCQ $0, R12 + + gfpCarry(R8,R9,R10,R11,R12, R13,R14,R15,AX,BX) + + MOVQ c+0(FP), DI + storeBlock(R8,R9,R10,R11, 0(DI)) + RET + +TEXT ·gfpSub(SB),0,$0-24 + MOVQ a+8(FP), DI + MOVQ b+16(FP), SI + + loadBlock(0(DI), R8,R9,R10,R11) + + MOVQ ·p2+0(SB), R12 + MOVQ ·p2+8(SB), R13 + MOVQ ·p2+16(SB), R14 + MOVQ ·p2+24(SB), R15 + MOVQ $0, AX + + SUBQ 0(SI), R8 + SBBQ 8(SI), R9 + SBBQ 16(SI), R10 + SBBQ 24(SI), R11 + + CMOVQCC AX, R12 + CMOVQCC AX, R13 + CMOVQCC AX, R14 + CMOVQCC AX, R15 + + ADDQ R12, R8 + ADCQ R13, R9 + ADCQ R14, R10 + ADCQ R15, R11 + + MOVQ c+0(FP), DI + storeBlock(R8,R9,R10,R11, 0(DI)) + RET + +TEXT ·gfpMul(SB),0,$160-24 + MOVQ a+8(FP), DI + MOVQ b+16(FP), SI + + // Jump to a slightly different implementation if MULX isn't supported. + CMPB ·hasBMI2(SB), $0 + JE nobmi2Mul + + mulBMI2(0(DI),8(DI),16(DI),24(DI), 0(SI)) + storeBlock( R8, R9,R10,R11, 0(SP)) + storeBlock(R12,R13,R14,R15, 32(SP)) + gfpReduceBMI2() + JMP end + +nobmi2Mul: + mul(0(DI),8(DI),16(DI),24(DI), 0(SI), 0(SP)) + gfpReduce(0(SP)) + +end: + MOVQ c+0(FP), DI + storeBlock(R12,R13,R14,R15, 0(DI)) + RET diff --git a/cryptography/bn256/gfp_arm64.s b/cryptography/bn256/gfp_arm64.s new file mode 100644 index 0000000..c65e801 --- /dev/null +++ b/cryptography/bn256/gfp_arm64.s @@ -0,0 +1,113 @@ +// +build arm64,!generic + +#define storeBlock(a0,a1,a2,a3, r) \ + MOVD a0, 0+r \ + MOVD a1, 8+r \ + MOVD a2, 16+r \ + MOVD a3, 24+r + +#define loadBlock(r, a0,a1,a2,a3) \ + MOVD 0+r, a0 \ + MOVD 8+r, a1 \ + MOVD 16+r, a2 \ + MOVD 24+r, a3 + +#define loadModulus(p0,p1,p2,p3) \ + MOVD ·p2+0(SB), p0 \ + MOVD ·p2+8(SB), p1 \ + MOVD ·p2+16(SB), p2 \ + MOVD ·p2+24(SB), p3 + +#include "mul_arm64.h" + +TEXT ·gfpNeg(SB),0,$0-16 + MOVD a+8(FP), R0 + loadBlock(0(R0), R1,R2,R3,R4) + loadModulus(R5,R6,R7,R8) + + SUBS R1, R5, R1 + SBCS R2, R6, R2 + SBCS R3, R7, R3 + SBCS R4, R8, R4 + + SUBS R5, R1, R5 + SBCS R6, R2, R6 + SBCS R7, R3, R7 + SBCS R8, R4, R8 + + CSEL CS, R5, R1, R1 + CSEL CS, R6, R2, R2 + CSEL CS, R7, R3, R3 + CSEL CS, R8, R4, R4 + + MOVD c+0(FP), R0 + storeBlock(R1,R2,R3,R4, 0(R0)) + RET + +TEXT ·gfpAdd(SB),0,$0-24 + MOVD a+8(FP), R0 + loadBlock(0(R0), R1,R2,R3,R4) + MOVD b+16(FP), R0 + loadBlock(0(R0), R5,R6,R7,R8) + loadModulus(R9,R10,R11,R12) + MOVD ZR, R0 + + ADDS R5, R1 + ADCS R6, R2 + ADCS R7, R3 + ADCS R8, R4 + ADCS ZR, R0 + + SUBS R9, R1, R5 + SBCS R10, R2, R6 + SBCS R11, R3, R7 + SBCS R12, R4, R8 + SBCS ZR, R0, R0 + + CSEL CS, R5, R1, R1 + CSEL CS, R6, R2, R2 + CSEL CS, R7, R3, R3 + CSEL CS, R8, R4, R4 + + MOVD c+0(FP), R0 + storeBlock(R1,R2,R3,R4, 0(R0)) + RET + +TEXT ·gfpSub(SB),0,$0-24 + MOVD a+8(FP), R0 + loadBlock(0(R0), R1,R2,R3,R4) + MOVD b+16(FP), R0 + loadBlock(0(R0), R5,R6,R7,R8) + loadModulus(R9,R10,R11,R12) + + SUBS R5, R1 + SBCS R6, R2 + SBCS R7, R3 + SBCS R8, R4 + + CSEL CS, ZR, R9, R9 + CSEL CS, ZR, R10, R10 + CSEL CS, ZR, R11, R11 + CSEL CS, ZR, R12, R12 + + ADDS R9, R1 + ADCS R10, R2 + ADCS R11, R3 + ADCS R12, R4 + + MOVD c+0(FP), R0 + storeBlock(R1,R2,R3,R4, 0(R0)) + RET + +TEXT ·gfpMul(SB),0,$0-24 + MOVD a+8(FP), R0 + loadBlock(0(R0), R1,R2,R3,R4) + MOVD b+16(FP), R0 + loadBlock(0(R0), R5,R6,R7,R8) + + mul(R9,R10,R11,R12,R13,R14,R15,R16) + gfpReduce() + + MOVD c+0(FP), R0 + storeBlock(R1,R2,R3,R4, 0(R0)) + RET diff --git a/cryptography/bn256/gfp_decl.go b/cryptography/bn256/gfp_decl.go new file mode 100644 index 0000000..fdea5c1 --- /dev/null +++ b/cryptography/bn256/gfp_decl.go @@ -0,0 +1,25 @@ +// +build amd64,!generic arm64,!generic + +package bn256 + +// This file contains forward declarations for the architecture-specific +// assembly implementations of these functions, provided that they exist. + +import ( + "golang.org/x/sys/cpu" +) + +//nolint:varcheck +var hasBMI2 = cpu.X86.HasBMI2 + +// go:noescape +func gfpNeg(c, a *gfP) + +//go:noescape +func gfpAdd(c, a, b *gfP) + +//go:noescape +func gfpSub(c, a, b *gfP) + +//go:noescape +func gfpMul(c, a, b *gfP) diff --git a/cryptography/bn256/gfp_generic.go b/cryptography/bn256/gfp_generic.go new file mode 100644 index 0000000..d902aa7 --- /dev/null +++ b/cryptography/bn256/gfp_generic.go @@ -0,0 +1,209 @@ +// +build !amd64,!arm64 generic + +package bn256 + +func gfpCarry(a *gfP, head uint64) { + b := &gfP{} + + var carry uint64 + for i, pi := range p2 { + ai := a[i] + bi := ai - pi - carry + b[i] = bi + carry = (pi&^ai | (pi|^ai)&bi) >> 63 + } + carry = carry &^ head + + // If b is negative, then return a. + // Else return b. + carry = -carry + ncarry := ^carry + for i := 0; i < 4; i++ { + a[i] = (a[i] & carry) | (b[i] & ncarry) + } +} + +func gfpNeg(c, a *gfP) { + var carry uint64 + for i, pi := range p2 { // p2 being the prime that defines the base/prime field + ai := a[i] + ci := pi - ai - carry + c[i] = ci + carry = (ai&^pi | (ai|^pi)&ci) >> 63 + } + gfpCarry(c, 0) +} + +func gfpAdd(c, a, b *gfP) { + var carry uint64 + for i, ai := range a { + bi := b[i] + ci := ai + bi + carry + c[i] = ci + carry = (ai&bi | (ai|bi)&^ci) >> 63 + } + gfpCarry(c, carry) +} + +func gfpSub(c, a, b *gfP) { + t := &gfP{} + + var carry uint64 + for i, pi := range p2 { + bi := b[i] + ti := pi - bi - carry + t[i] = ti + carry = (bi&^pi | (bi|^pi)&ti) >> 63 + } + + carry = 0 + for i, ai := range a { + ti := t[i] + ci := ai + ti + carry + c[i] = ci + carry = (ai&ti | (ai|ti)&^ci) >> 63 + } + gfpCarry(c, carry) +} + +func mul(a, b [4]uint64) [8]uint64 { + const ( + mask16 uint64 = 0x0000ffff + mask32 uint64 = 0xffffffff + ) + + var buff [32]uint64 + for i, ai := range a { + a0, a1, a2, a3 := ai&mask16, (ai>>16)&mask16, (ai>>32)&mask16, ai>>48 + + for j, bj := range b { + b0, b2 := bj&mask32, bj>>32 + + off := 4 * (i + j) + buff[off+0] += a0 * b0 + buff[off+1] += a1 * b0 + buff[off+2] += a2*b0 + a0*b2 + buff[off+3] += a3*b0 + a1*b2 + buff[off+4] += a2 * b2 + buff[off+5] += a3 * b2 + } + } + + for i := uint(1); i < 4; i++ { + shift := 16 * i + + var head, carry uint64 + for j := uint(0); j < 8; j++ { + block := 4 * j + + xi := buff[block] + yi := (buff[block+i] << shift) + head + zi := xi + yi + carry + buff[block] = zi + carry = (xi&yi | (xi|yi)&^zi) >> 63 + + head = buff[block+i] >> (64 - shift) + } + } + + return [8]uint64{buff[0], buff[4], buff[8], buff[12], buff[16], buff[20], buff[24], buff[28]} +} + +func halfMul(a, b [4]uint64) [4]uint64 { + const ( + mask16 uint64 = 0x0000ffff + mask32 uint64 = 0xffffffff + ) + + var buff [18]uint64 + for i, ai := range a { + a0, a1, a2, a3 := ai&mask16, (ai>>16)&mask16, (ai>>32)&mask16, ai>>48 + + for j, bj := range b { + if i+j > 3 { + break + } + b0, b2 := bj&mask32, bj>>32 + + off := 4 * (i + j) + buff[off+0] += a0 * b0 + buff[off+1] += a1 * b0 + buff[off+2] += a2*b0 + a0*b2 + buff[off+3] += a3*b0 + a1*b2 + buff[off+4] += a2 * b2 + buff[off+5] += a3 * b2 + } + } + + for i := uint(1); i < 4; i++ { + shift := 16 * i + + var head, carry uint64 + for j := uint(0); j < 4; j++ { + block := 4 * j + + xi := buff[block] + yi := (buff[block+i] << shift) + head + zi := xi + yi + carry + buff[block] = zi + carry = (xi&yi | (xi|yi)&^zi) >> 63 + + head = buff[block+i] >> (64 - shift) + } + } + + return [4]uint64{buff[0], buff[4], buff[8], buff[12]} +} + +func gfpMul(c, a, b *gfP) { + T := mul(*a, *b) + m := halfMul([4]uint64{T[0], T[1], T[2], T[3]}, np) + t := mul([4]uint64{m[0], m[1], m[2], m[3]}, p2) + + var carry uint64 + for i, Ti := range T { + ti := t[i] + zi := Ti + ti + carry + T[i] = zi + carry = (Ti&ti | (Ti|ti)&^zi) >> 63 + } + + *c = gfP{T[4], T[5], T[6], T[7]} + gfpCarry(c, carry) +} + +// Util function to compare field elements. Should be defined in gfP files +// Compares 2 GFp elements +// Returns 1 if a > b; 0 if a == b; -1 if a < b +/* +func gfpCmp(a, b *gfP) int { + for i := FpUint64Size - 1; i >= 0; i-- { // Remember that the gfP elements are written as little-endian 64-bit words + if a[i] > b[i] { // As soon as we figure out that the MSByte of A > MSByte of B, we return + return 1 + } else if a[i] == b[i] { // If the current bytes are equal we continue as we cannot conclude on A and B relation + continue + } else { // a[i] < b[i] so we can directly conclude and we return + return -1 + } + } + + return 0 +} +*/ + +// TODO: Optimize these functions as for now all it's doing is to convert in big.Int +// and use big integer arithmetic +// Computes c = a^{exp} in Fp (so mod p) +/* +func gfpExp(a *gfP, exp, mod *big.Int) *gfP { + // Convert the field elements to big.Int + aBig := a.gFpToBigInt() + + // Run the big.Int Exp algorithm + resBig := new(big.Int).Exp(aBig, exp, mod) + + // Convert the big.Int result back to field element + res := newGFpFromBigInt(resBig) + return res +} +*/ diff --git a/cryptography/bn256/gfp_test.go b/cryptography/bn256/gfp_test.go new file mode 100644 index 0000000..6fe2872 --- /dev/null +++ b/cryptography/bn256/gfp_test.go @@ -0,0 +1,116 @@ +package bn256 + +import ( + "testing" +) + +// Tests that negation works the same way on both assembly-optimized and pure Go +// implementation. +func TestGFpNeg(t *testing.T) { + n := &gfP{0x0123456789abcdef, 0xfedcba9876543210, 0xdeadbeefdeadbeef, 0xfeebdaedfeebdaed} + w := &gfP{0xfedcba9876543211, 0x0123456789abcdef, 0x2152411021524110, 0x0114251201142512} + h := &gfP{} + + gfpNeg(h, n) + if *h != *w { + t.Errorf("negation mismatch: have %#x, want %#x", *h, *w) + } +} + +// Tests that addition works the same way on both assembly-optimized and pure Go +// implementation. +func TestGFpAdd(t *testing.T) { + a := &gfP{0x0123456789abcdef, 0xfedcba9876543210, 0xdeadbeefdeadbeef, 0xfeebdaedfeebdaed} + b := &gfP{0xfedcba9876543210, 0x0123456789abcdef, 0xfeebdaedfeebdaed, 0xdeadbeefdeadbeef} + w := &gfP{0xc3df73e9278302b8, 0x687e956e978e3572, 0x254954275c18417f, 0xad354b6afc67f9b4} + h := &gfP{} + + gfpAdd(h, a, b) + if *h != *w { + t.Errorf("addition mismatch: have %#x, want %#x", *h, *w) + } +} + +// Tests that subtraction works the same way on both assembly-optimized and pure Go +// implementation. +func TestGFpSub(t *testing.T) { + a := &gfP{0x0123456789abcdef, 0xfedcba9876543210, 0xdeadbeefdeadbeef, 0xfeebdaedfeebdaed} + b := &gfP{0xfedcba9876543210, 0x0123456789abcdef, 0xfeebdaedfeebdaed, 0xdeadbeefdeadbeef} + w := &gfP{0x02468acf13579bdf, 0xfdb97530eca86420, 0xdfc1e401dfc1e402, 0x203e1bfe203e1bfd} + h := &gfP{} + + gfpSub(h, a, b) + if *h != *w { + t.Errorf("subtraction mismatch: have %#x, want %#x", *h, *w) + } +} + +// Tests that multiplication works the same way on both assembly-optimized and pure Go +// implementation. +func TestGFpMul(t *testing.T) { + a := &gfP{0x0123456789abcdef, 0xfedcba9876543210, 0xdeadbeefdeadbeef, 0xfeebdaedfeebdaed} + b := &gfP{0xfedcba9876543210, 0x0123456789abcdef, 0xfeebdaedfeebdaed, 0xdeadbeefdeadbeef} + w := &gfP{0xcbcbd377f7ad22d3, 0x3b89ba5d849379bf, 0x87b61627bd38b6d2, 0xc44052a2a0e654b2} + h := &gfP{} + + gfpMul(h, a, b) + if *h != *w { + t.Errorf("multiplication mismatch: have %#x, want %#x", *h, *w) + } +} + +// Tests the conversion from big.Int to GFp element +func TestNewGFpFromBigInt(t *testing.T) { + // Case 1 + twoBig := bigFromBase10("2") + h := *newGFpFromBigInt(twoBig) + twoHex := [4]uint64{0x0000000000000002, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000} + w := gfP(twoHex) + + if h != w { + t.Errorf("conversion mismatch: have %s, want %s", h.String(), w.String()) + } + + // Case 2 + pMinus1Big := bigFromBase10("21888242871839275222246405745257275088696311157297823662689037894645226208582") + h = *newGFpFromBigInt(pMinus1Big) + pMinus1Hex := [4]uint64{0x3c208c16d87cfd46, 0x97816a916871ca8d, 0xb85045b68181585d, 0x30644e72e131a029} + w = gfP(pMinus1Hex) + + if h != w { + t.Errorf("conversion mismatch: have %s, want %s", h.String(), w.String()) + } +} + +// Tests the conversion from GFp element to big.Int +func TestGFpToBigInt(t *testing.T) { + // Case 1 + twoHex := [4]uint64{0x0000000000000002, 0x0000000000000000, 0x0000000000000000, 0x0000000000000000} + twoBig := bigFromBase10("2") + twoGFp := gfP(twoHex) // Not MontEncoded! + w := twoBig + h, err := twoGFp.gFpToBigInt() + + if err != nil { + t.Errorf("Couldn't convert GFp to big.Int: %s", err) + } + + if r := h.Cmp(w); r != 0 { + t.Errorf("conversion mismatch: have %s, want %s", h.String(), w.String()) + } + + // Case 2 + pMinus1Hex := [4]uint64{0x3c208c16d87cfd46, 0x97816a916871ca8d, 0xb85045b68181585d, 0x30644e72e131a029} + pMinus1Big := bigFromBase10("21888242871839275222246405745257275088696311157297823662689037894645226208582") + pMinus1GFp := gfP(pMinus1Hex) // Not MontEncoded! + w = pMinus1Big + h, err = pMinus1GFp.gFpToBigInt() + + if err != nil { + t.Errorf("Couldn't convert GFp to big.Int: %s", err) + } + + if r := h.Cmp(w); r != 0 { + t.Errorf("conversion mismatch: have %s, want %s", h.String(), w.String()) + } +} diff --git a/cryptography/bn256/lattice.go b/cryptography/bn256/lattice.go new file mode 100644 index 0000000..f9ace4d --- /dev/null +++ b/cryptography/bn256/lattice.go @@ -0,0 +1,115 @@ +package bn256 + +import ( + "math/big" +) + +var half = new(big.Int).Rsh(Order, 1) + +var curveLattice = &lattice{ + vectors: [][]*big.Int{ + {bigFromBase10("147946756881789319000765030803803410728"), bigFromBase10("147946756881789319010696353538189108491")}, + {bigFromBase10("147946756881789319020627676272574806254"), bigFromBase10("-147946756881789318990833708069417712965")}, + }, + inverse: []*big.Int{ + bigFromBase10("147946756881789318990833708069417712965"), + bigFromBase10("147946756881789319010696353538189108491"), + }, + det: bigFromBase10("43776485743678550444492811490514550177096728800832068687396408373151616991234"), +} + +var targetLattice = &lattice{ + vectors: [][]*big.Int{ + {bigFromBase10("9931322734385697761"), bigFromBase10("9931322734385697761"), bigFromBase10("9931322734385697763"), bigFromBase10("9931322734385697764")}, + {bigFromBase10("4965661367192848881"), bigFromBase10("4965661367192848881"), bigFromBase10("4965661367192848882"), bigFromBase10("-9931322734385697762")}, + {bigFromBase10("-9931322734385697762"), bigFromBase10("-4965661367192848881"), bigFromBase10("4965661367192848881"), bigFromBase10("-4965661367192848882")}, + {bigFromBase10("9931322734385697763"), bigFromBase10("-4965661367192848881"), bigFromBase10("-4965661367192848881"), bigFromBase10("-4965661367192848881")}, + }, + inverse: []*big.Int{ + bigFromBase10("734653495049373973658254490726798021314063399421879442165"), + bigFromBase10("147946756881789319000765030803803410728"), + bigFromBase10("-147946756881789319005730692170996259609"), + bigFromBase10("1469306990098747947464455738335385361643788813749140841702"), + }, + det: new(big.Int).Set(Order), +} + +type lattice struct { + vectors [][]*big.Int + inverse []*big.Int + det *big.Int +} + +// decompose takes a scalar mod Order as input and finds a short, positive decomposition of it wrt to the lattice basis. +func (l *lattice) decompose(k *big.Int) []*big.Int { + n := len(l.inverse) + + // Calculate closest vector in lattice to with Babai's rounding. + c := make([]*big.Int, n) + for i := 0; i < n; i++ { + c[i] = new(big.Int).Mul(k, l.inverse[i]) + round(c[i], l.det) + } + + // Transform vectors according to c and subtract . + out := make([]*big.Int, n) + temp := new(big.Int) + + for i := 0; i < n; i++ { + out[i] = new(big.Int) + + for j := 0; j < n; j++ { + temp.Mul(c[j], l.vectors[j][i]) + out[i].Add(out[i], temp) + } + + out[i].Neg(out[i]) + out[i].Add(out[i], l.vectors[0][i]).Add(out[i], l.vectors[0][i]) + } + out[0].Add(out[0], k) + + return out +} + +func (l *lattice) Precompute(add func(i, j uint)) { + n := uint(len(l.vectors)) + total := uint(1) << n + + for i := uint(0); i < n; i++ { + for j := uint(0); j < total; j++ { + if (j>>i)&1 == 1 { + add(i, j) + } + } + } +} + +func (l *lattice) Multi(scalar *big.Int) []uint8 { + decomp := l.decompose(scalar) + + maxLen := 0 + for _, x := range decomp { + if x.BitLen() > maxLen { + maxLen = x.BitLen() + } + } + + out := make([]uint8, maxLen) + for j, x := range decomp { + for i := 0; i < maxLen; i++ { + out[i] += uint8(x.Bit(i)) << uint(j) + } + } + + return out +} + +// round sets num to num/denom rounded to the nearest integer. +func round(num, denom *big.Int) { + r := new(big.Int) + num.DivMod(num, denom, r) + + if r.Cmp(half) == 1 { + num.Add(num, big.NewInt(1)) + } +} diff --git a/cryptography/bn256/lattice_test.go b/cryptography/bn256/lattice_test.go new file mode 100644 index 0000000..4d52ad9 --- /dev/null +++ b/cryptography/bn256/lattice_test.go @@ -0,0 +1,29 @@ +package bn256 + +import ( + "crypto/rand" + + "testing" +) + +func TestLatticeReduceCurve(t *testing.T) { + k, _ := rand.Int(rand.Reader, Order) + ks := curveLattice.decompose(k) + + if ks[0].BitLen() > 130 || ks[1].BitLen() > 130 { + t.Fatal("reduction too large") + } else if ks[0].Sign() < 0 || ks[1].Sign() < 0 { + t.Fatal("reduction must be positive") + } +} + +func TestLatticeReduceTarget(t *testing.T) { + k, _ := rand.Int(rand.Reader, Order) + ks := targetLattice.decompose(k) + + if ks[0].BitLen() > 66 || ks[1].BitLen() > 66 || ks[2].BitLen() > 66 || ks[3].BitLen() > 66 { + t.Fatal("reduction too large") + } else if ks[0].Sign() < 0 || ks[1].Sign() < 0 || ks[2].Sign() < 0 || ks[3].Sign() < 0 { + t.Fatal("reduction must be positive") + } +} diff --git a/cryptography/bn256/main_test.go b/cryptography/bn256/main_test.go new file mode 100644 index 0000000..c0c8545 --- /dev/null +++ b/cryptography/bn256/main_test.go @@ -0,0 +1,71 @@ +package bn256 + +import ( + "testing" + + "crypto/rand" +) + +func TestRandomG2Marshal(t *testing.T) { + for i := 0; i < 10; i++ { + n, g2, err := RandomG2(rand.Reader) + if err != nil { + t.Error(err) + continue + } + t.Logf("%v: %x\n", n, g2.Marshal()) + } +} + +func TestPairings(t *testing.T) { + a1 := new(G1).ScalarBaseMult(bigFromBase10("1")) + a2 := new(G1).ScalarBaseMult(bigFromBase10("2")) + a37 := new(G1).ScalarBaseMult(bigFromBase10("37")) + an1 := new(G1).ScalarBaseMult(bigFromBase10("21888242871839275222246405745257275088548364400416034343698204186575808495616")) + + b0 := new(G2).ScalarBaseMult(bigFromBase10("0")) + b1 := new(G2).ScalarBaseMult(bigFromBase10("1")) + b2 := new(G2).ScalarBaseMult(bigFromBase10("2")) + b27 := new(G2).ScalarBaseMult(bigFromBase10("27")) + b999 := new(G2).ScalarBaseMult(bigFromBase10("999")) + bn1 := new(G2).ScalarBaseMult(bigFromBase10("21888242871839275222246405745257275088548364400416034343698204186575808495616")) + + p1 := Pair(a1, b1) + pn1 := Pair(a1, bn1) + np1 := Pair(an1, b1) + if pn1.String() != np1.String() { + t.Error("Pairing mismatch: e(a, -b) != e(-a, b)") + } + if !PairingCheck([]*G1{a1, an1}, []*G2{b1, b1}) { + t.Error("MultiAte check gave false negative!") + } + p0 := new(GT).Add(p1, pn1) + p0_2 := Pair(a1, b0) + if p0.String() != p0_2.String() { + t.Error("Pairing mismatch: e(a, b) * e(a, -b) != 1") + } + p0_3 := new(GT).ScalarMult(p1, bigFromBase10("21888242871839275222246405745257275088548364400416034343698204186575808495617")) + if p0.String() != p0_3.String() { + t.Error("Pairing mismatch: e(a, b) has wrong order") + } + p2 := Pair(a2, b1) + p2_2 := Pair(a1, b2) + p2_3 := new(GT).ScalarMult(p1, bigFromBase10("2")) + if p2.String() != p2_2.String() { + t.Error("Pairing mismatch: e(a, b * 2) != e(a * 2, b)") + } + if p2.String() != p2_3.String() { + t.Error("Pairing mismatch: e(a, b * 2) != e(a, b) ** 2") + } + if p2.String() == p1.String() { + t.Error("Pairing is degenerate!") + } + if PairingCheck([]*G1{a1, a1}, []*G2{b1, b1}) { + t.Error("MultiAte check gave false positive!") + } + p999 := Pair(a37, b27) + p999_2 := Pair(a1, b999) + if p999.String() != p999_2.String() { + t.Error("Pairing mismatch: e(a * 37, b * 27) != e(a, b * 999)") + } +} diff --git a/cryptography/bn256/mul_amd64.h b/cryptography/bn256/mul_amd64.h new file mode 100644 index 0000000..bab5da8 --- /dev/null +++ b/cryptography/bn256/mul_amd64.h @@ -0,0 +1,181 @@ +#define mul(a0,a1,a2,a3, rb, stack) \ + MOVQ a0, AX \ + MULQ 0+rb \ + MOVQ AX, R8 \ + MOVQ DX, R9 \ + MOVQ a0, AX \ + MULQ 8+rb \ + ADDQ AX, R9 \ + ADCQ $0, DX \ + MOVQ DX, R10 \ + MOVQ a0, AX \ + MULQ 16+rb \ + ADDQ AX, R10 \ + ADCQ $0, DX \ + MOVQ DX, R11 \ + MOVQ a0, AX \ + MULQ 24+rb \ + ADDQ AX, R11 \ + ADCQ $0, DX \ + MOVQ DX, R12 \ + \ + storeBlock(R8,R9,R10,R11, 0+stack) \ + MOVQ R12, 32+stack \ + \ + MOVQ a1, AX \ + MULQ 0+rb \ + MOVQ AX, R8 \ + MOVQ DX, R9 \ + MOVQ a1, AX \ + MULQ 8+rb \ + ADDQ AX, R9 \ + ADCQ $0, DX \ + MOVQ DX, R10 \ + MOVQ a1, AX \ + MULQ 16+rb \ + ADDQ AX, R10 \ + ADCQ $0, DX \ + MOVQ DX, R11 \ + MOVQ a1, AX \ + MULQ 24+rb \ + ADDQ AX, R11 \ + ADCQ $0, DX \ + MOVQ DX, R12 \ + \ + ADDQ 8+stack, R8 \ + ADCQ 16+stack, R9 \ + ADCQ 24+stack, R10 \ + ADCQ 32+stack, R11 \ + ADCQ $0, R12 \ + storeBlock(R8,R9,R10,R11, 8+stack) \ + MOVQ R12, 40+stack \ + \ + MOVQ a2, AX \ + MULQ 0+rb \ + MOVQ AX, R8 \ + MOVQ DX, R9 \ + MOVQ a2, AX \ + MULQ 8+rb \ + ADDQ AX, R9 \ + ADCQ $0, DX \ + MOVQ DX, R10 \ + MOVQ a2, AX \ + MULQ 16+rb \ + ADDQ AX, R10 \ + ADCQ $0, DX \ + MOVQ DX, R11 \ + MOVQ a2, AX \ + MULQ 24+rb \ + ADDQ AX, R11 \ + ADCQ $0, DX \ + MOVQ DX, R12 \ + \ + ADDQ 16+stack, R8 \ + ADCQ 24+stack, R9 \ + ADCQ 32+stack, R10 \ + ADCQ 40+stack, R11 \ + ADCQ $0, R12 \ + storeBlock(R8,R9,R10,R11, 16+stack) \ + MOVQ R12, 48+stack \ + \ + MOVQ a3, AX \ + MULQ 0+rb \ + MOVQ AX, R8 \ + MOVQ DX, R9 \ + MOVQ a3, AX \ + MULQ 8+rb \ + ADDQ AX, R9 \ + ADCQ $0, DX \ + MOVQ DX, R10 \ + MOVQ a3, AX \ + MULQ 16+rb \ + ADDQ AX, R10 \ + ADCQ $0, DX \ + MOVQ DX, R11 \ + MOVQ a3, AX \ + MULQ 24+rb \ + ADDQ AX, R11 \ + ADCQ $0, DX \ + MOVQ DX, R12 \ + \ + ADDQ 24+stack, R8 \ + ADCQ 32+stack, R9 \ + ADCQ 40+stack, R10 \ + ADCQ 48+stack, R11 \ + ADCQ $0, R12 \ + storeBlock(R8,R9,R10,R11, 24+stack) \ + MOVQ R12, 56+stack + +#define gfpReduce(stack) \ + \ // m = (T * N') mod R, store m in R8:R9:R10:R11 + MOVQ ·np+0(SB), AX \ + MULQ 0+stack \ + MOVQ AX, R8 \ + MOVQ DX, R9 \ + MOVQ ·np+0(SB), AX \ + MULQ 8+stack \ + ADDQ AX, R9 \ + ADCQ $0, DX \ + MOVQ DX, R10 \ + MOVQ ·np+0(SB), AX \ + MULQ 16+stack \ + ADDQ AX, R10 \ + ADCQ $0, DX \ + MOVQ DX, R11 \ + MOVQ ·np+0(SB), AX \ + MULQ 24+stack \ + ADDQ AX, R11 \ + \ + MOVQ ·np+8(SB), AX \ + MULQ 0+stack \ + MOVQ AX, R12 \ + MOVQ DX, R13 \ + MOVQ ·np+8(SB), AX \ + MULQ 8+stack \ + ADDQ AX, R13 \ + ADCQ $0, DX \ + MOVQ DX, R14 \ + MOVQ ·np+8(SB), AX \ + MULQ 16+stack \ + ADDQ AX, R14 \ + \ + ADDQ R12, R9 \ + ADCQ R13, R10 \ + ADCQ R14, R11 \ + \ + MOVQ ·np+16(SB), AX \ + MULQ 0+stack \ + MOVQ AX, R12 \ + MOVQ DX, R13 \ + MOVQ ·np+16(SB), AX \ + MULQ 8+stack \ + ADDQ AX, R13 \ + \ + ADDQ R12, R10 \ + ADCQ R13, R11 \ + \ + MOVQ ·np+24(SB), AX \ + MULQ 0+stack \ + ADDQ AX, R11 \ + \ + storeBlock(R8,R9,R10,R11, 64+stack) \ + \ + \ // m * N + mul(·p2+0(SB),·p2+8(SB),·p2+16(SB),·p2+24(SB), 64+stack, 96+stack) \ + \ + \ // Add the 512-bit intermediate to m*N + loadBlock(96+stack, R8,R9,R10,R11) \ + loadBlock(128+stack, R12,R13,R14,R15) \ + \ + MOVQ $0, AX \ + ADDQ 0+stack, R8 \ + ADCQ 8+stack, R9 \ + ADCQ 16+stack, R10 \ + ADCQ 24+stack, R11 \ + ADCQ 32+stack, R12 \ + ADCQ 40+stack, R13 \ + ADCQ 48+stack, R14 \ + ADCQ 56+stack, R15 \ + ADCQ $0, AX \ + \ + gfpCarry(R12,R13,R14,R15,AX, R8,R9,R10,R11,BX) diff --git a/cryptography/bn256/mul_arm64.h b/cryptography/bn256/mul_arm64.h new file mode 100644 index 0000000..d405eb8 --- /dev/null +++ b/cryptography/bn256/mul_arm64.h @@ -0,0 +1,133 @@ +#define mul(c0,c1,c2,c3,c4,c5,c6,c7) \ + MUL R1, R5, c0 \ + UMULH R1, R5, c1 \ + MUL R1, R6, R0 \ + ADDS R0, c1 \ + UMULH R1, R6, c2 \ + MUL R1, R7, R0 \ + ADCS R0, c2 \ + UMULH R1, R7, c3 \ + MUL R1, R8, R0 \ + ADCS R0, c3 \ + UMULH R1, R8, c4 \ + ADCS ZR, c4 \ + \ + MUL R2, R5, R1 \ + UMULH R2, R5, R26 \ + MUL R2, R6, R0 \ + ADDS R0, R26 \ + UMULH R2, R6, R27 \ + MUL R2, R7, R0 \ + ADCS R0, R27 \ + UMULH R2, R7, R29 \ + MUL R2, R8, R0 \ + ADCS R0, R29 \ + UMULH R2, R8, c5 \ + ADCS ZR, c5 \ + ADDS R1, c1 \ + ADCS R26, c2 \ + ADCS R27, c3 \ + ADCS R29, c4 \ + ADCS ZR, c5 \ + \ + MUL R3, R5, R1 \ + UMULH R3, R5, R26 \ + MUL R3, R6, R0 \ + ADDS R0, R26 \ + UMULH R3, R6, R27 \ + MUL R3, R7, R0 \ + ADCS R0, R27 \ + UMULH R3, R7, R29 \ + MUL R3, R8, R0 \ + ADCS R0, R29 \ + UMULH R3, R8, c6 \ + ADCS ZR, c6 \ + ADDS R1, c2 \ + ADCS R26, c3 \ + ADCS R27, c4 \ + ADCS R29, c5 \ + ADCS ZR, c6 \ + \ + MUL R4, R5, R1 \ + UMULH R4, R5, R26 \ + MUL R4, R6, R0 \ + ADDS R0, R26 \ + UMULH R4, R6, R27 \ + MUL R4, R7, R0 \ + ADCS R0, R27 \ + UMULH R4, R7, R29 \ + MUL R4, R8, R0 \ + ADCS R0, R29 \ + UMULH R4, R8, c7 \ + ADCS ZR, c7 \ + ADDS R1, c3 \ + ADCS R26, c4 \ + ADCS R27, c5 \ + ADCS R29, c6 \ + ADCS ZR, c7 + +#define gfpReduce() \ + \ // m = (T * N') mod R, store m in R1:R2:R3:R4 + MOVD ·np+0(SB), R17 \ + MOVD ·np+8(SB), R25 \ + MOVD ·np+16(SB), R19 \ + MOVD ·np+24(SB), R20 \ + \ + MUL R9, R17, R1 \ + UMULH R9, R17, R2 \ + MUL R9, R25, R0 \ + ADDS R0, R2 \ + UMULH R9, R25, R3 \ + MUL R9, R19, R0 \ + ADCS R0, R3 \ + UMULH R9, R19, R4 \ + MUL R9, R20, R0 \ + ADCS R0, R4 \ + \ + MUL R10, R17, R21 \ + UMULH R10, R17, R22 \ + MUL R10, R25, R0 \ + ADDS R0, R22 \ + UMULH R10, R25, R23 \ + MUL R10, R19, R0 \ + ADCS R0, R23 \ + ADDS R21, R2 \ + ADCS R22, R3 \ + ADCS R23, R4 \ + \ + MUL R11, R17, R21 \ + UMULH R11, R17, R22 \ + MUL R11, R25, R0 \ + ADDS R0, R22 \ + ADDS R21, R3 \ + ADCS R22, R4 \ + \ + MUL R12, R17, R21 \ + ADDS R21, R4 \ + \ + \ // m * N + loadModulus(R5,R6,R7,R8) \ + mul(R17,R25,R19,R20,R21,R22,R23,R24) \ + \ + \ // Add the 512-bit intermediate to m*N + MOVD ZR, R0 \ + ADDS R9, R17 \ + ADCS R10, R25 \ + ADCS R11, R19 \ + ADCS R12, R20 \ + ADCS R13, R21 \ + ADCS R14, R22 \ + ADCS R15, R23 \ + ADCS R16, R24 \ + ADCS ZR, R0 \ + \ + \ // Our output is R21:R22:R23:R24. Reduce mod p if necessary. + SUBS R5, R21, R10 \ + SBCS R6, R22, R11 \ + SBCS R7, R23, R12 \ + SBCS R8, R24, R13 \ + \ + CSEL CS, R10, R21, R1 \ + CSEL CS, R11, R22, R2 \ + CSEL CS, R12, R23, R3 \ + CSEL CS, R13, R24, R4 diff --git a/cryptography/bn256/mul_bmi2_amd64.h b/cryptography/bn256/mul_bmi2_amd64.h new file mode 100644 index 0000000..71ad049 --- /dev/null +++ b/cryptography/bn256/mul_bmi2_amd64.h @@ -0,0 +1,112 @@ +#define mulBMI2(a0,a1,a2,a3, rb) \ + MOVQ a0, DX \ + MOVQ $0, R13 \ + MULXQ 0+rb, R8, R9 \ + MULXQ 8+rb, AX, R10 \ + ADDQ AX, R9 \ + MULXQ 16+rb, AX, R11 \ + ADCQ AX, R10 \ + MULXQ 24+rb, AX, R12 \ + ADCQ AX, R11 \ + ADCQ $0, R12 \ + ADCQ $0, R13 \ + \ + MOVQ a1, DX \ + MOVQ $0, R14 \ + MULXQ 0+rb, AX, BX \ + ADDQ AX, R9 \ + ADCQ BX, R10 \ + MULXQ 16+rb, AX, BX \ + ADCQ AX, R11 \ + ADCQ BX, R12 \ + ADCQ $0, R13 \ + MULXQ 8+rb, AX, BX \ + ADDQ AX, R10 \ + ADCQ BX, R11 \ + MULXQ 24+rb, AX, BX \ + ADCQ AX, R12 \ + ADCQ BX, R13 \ + ADCQ $0, R14 \ + \ + MOVQ a2, DX \ + MOVQ $0, R15 \ + MULXQ 0+rb, AX, BX \ + ADDQ AX, R10 \ + ADCQ BX, R11 \ + MULXQ 16+rb, AX, BX \ + ADCQ AX, R12 \ + ADCQ BX, R13 \ + ADCQ $0, R14 \ + MULXQ 8+rb, AX, BX \ + ADDQ AX, R11 \ + ADCQ BX, R12 \ + MULXQ 24+rb, AX, BX \ + ADCQ AX, R13 \ + ADCQ BX, R14 \ + ADCQ $0, R15 \ + \ + MOVQ a3, DX \ + MULXQ 0+rb, AX, BX \ + ADDQ AX, R11 \ + ADCQ BX, R12 \ + MULXQ 16+rb, AX, BX \ + ADCQ AX, R13 \ + ADCQ BX, R14 \ + ADCQ $0, R15 \ + MULXQ 8+rb, AX, BX \ + ADDQ AX, R12 \ + ADCQ BX, R13 \ + MULXQ 24+rb, AX, BX \ + ADCQ AX, R14 \ + ADCQ BX, R15 + +#define gfpReduceBMI2() \ + \ // m = (T * N') mod R, store m in R8:R9:R10:R11 + MOVQ ·np+0(SB), DX \ + MULXQ 0(SP), R8, R9 \ + MULXQ 8(SP), AX, R10 \ + ADDQ AX, R9 \ + MULXQ 16(SP), AX, R11 \ + ADCQ AX, R10 \ + MULXQ 24(SP), AX, BX \ + ADCQ AX, R11 \ + \ + MOVQ ·np+8(SB), DX \ + MULXQ 0(SP), AX, BX \ + ADDQ AX, R9 \ + ADCQ BX, R10 \ + MULXQ 16(SP), AX, BX \ + ADCQ AX, R11 \ + MULXQ 8(SP), AX, BX \ + ADDQ AX, R10 \ + ADCQ BX, R11 \ + \ + MOVQ ·np+16(SB), DX \ + MULXQ 0(SP), AX, BX \ + ADDQ AX, R10 \ + ADCQ BX, R11 \ + MULXQ 8(SP), AX, BX \ + ADDQ AX, R11 \ + \ + MOVQ ·np+24(SB), DX \ + MULXQ 0(SP), AX, BX \ + ADDQ AX, R11 \ + \ + storeBlock(R8,R9,R10,R11, 64(SP)) \ + \ + \ // m * N + mulBMI2(·p2+0(SB),·p2+8(SB),·p2+16(SB),·p2+24(SB), 64(SP)) \ + \ + \ // Add the 512-bit intermediate to m*N + MOVQ $0, AX \ + ADDQ 0(SP), R8 \ + ADCQ 8(SP), R9 \ + ADCQ 16(SP), R10 \ + ADCQ 24(SP), R11 \ + ADCQ 32(SP), R12 \ + ADCQ 40(SP), R13 \ + ADCQ 48(SP), R14 \ + ADCQ 56(SP), R15 \ + ADCQ $0, AX \ + \ + gfpCarry(R12,R13,R14,R15,AX, R8,R9,R10,R11,BX) diff --git a/cryptography/bn256/optate.go b/cryptography/bn256/optate.go new file mode 100644 index 0000000..b71e50e --- /dev/null +++ b/cryptography/bn256/optate.go @@ -0,0 +1,271 @@ +package bn256 + +func lineFunctionAdd(r, p *twistPoint, q *curvePoint, r2 *gfP2) (a, b, c *gfP2, rOut *twistPoint) { + // See the mixed addition algorithm from "Faster Computation of the + // Tate Pairing", http://arxiv.org/pdf/0904.0854v3.pdf + B := (&gfP2{}).Mul(&p.x, &r.t) + + D := (&gfP2{}).Add(&p.y, &r.z) + D.Square(D).Sub(D, r2).Sub(D, &r.t).Mul(D, &r.t) + + H := (&gfP2{}).Sub(B, &r.x) + I := (&gfP2{}).Square(H) + + E := (&gfP2{}).Add(I, I) + E.Add(E, E) + + J := (&gfP2{}).Mul(H, E) + + L1 := (&gfP2{}).Sub(D, &r.y) + L1.Sub(L1, &r.y) + + V := (&gfP2{}).Mul(&r.x, E) + + rOut = &twistPoint{} + rOut.x.Square(L1).Sub(&rOut.x, J).Sub(&rOut.x, V).Sub(&rOut.x, V) + + rOut.z.Add(&r.z, H).Square(&rOut.z).Sub(&rOut.z, &r.t).Sub(&rOut.z, I) + + t := (&gfP2{}).Sub(V, &rOut.x) + t.Mul(t, L1) + t2 := (&gfP2{}).Mul(&r.y, J) + t2.Add(t2, t2) + rOut.y.Sub(t, t2) + + rOut.t.Square(&rOut.z) + + t.Add(&p.y, &rOut.z).Square(t).Sub(t, r2).Sub(t, &rOut.t) + + t2.Mul(L1, &p.x) + t2.Add(t2, t2) + a = (&gfP2{}).Sub(t2, t) + + c = (&gfP2{}).MulScalar(&rOut.z, &q.y) + c.Add(c, c) + + b = (&gfP2{}).Neg(L1) + b.MulScalar(b, &q.x).Add(b, b) + + return +} + +func lineFunctionDouble(r *twistPoint, q *curvePoint) (a, b, c *gfP2, rOut *twistPoint) { + // See the doubling algorithm for a=0 from "Faster Computation of the + // Tate Pairing", http://arxiv.org/pdf/0904.0854v3.pdf + A := (&gfP2{}).Square(&r.x) + B := (&gfP2{}).Square(&r.y) + C := (&gfP2{}).Square(B) + + D := (&gfP2{}).Add(&r.x, B) + D.Square(D).Sub(D, A).Sub(D, C).Add(D, D) + + E := (&gfP2{}).Add(A, A) + E.Add(E, A) + + G := (&gfP2{}).Square(E) + + rOut = &twistPoint{} + rOut.x.Sub(G, D).Sub(&rOut.x, D) + + rOut.z.Add(&r.y, &r.z).Square(&rOut.z).Sub(&rOut.z, B).Sub(&rOut.z, &r.t) + + rOut.y.Sub(D, &rOut.x).Mul(&rOut.y, E) + t := (&gfP2{}).Add(C, C) + t.Add(t, t).Add(t, t) + rOut.y.Sub(&rOut.y, t) + + rOut.t.Square(&rOut.z) + + t.Mul(E, &r.t).Add(t, t) + b = (&gfP2{}).Neg(t) + b.MulScalar(b, &q.x) + + a = (&gfP2{}).Add(&r.x, E) + a.Square(a).Sub(a, A).Sub(a, G) + t.Add(B, B).Add(t, t) + a.Sub(a, t) + + c = (&gfP2{}).Mul(&rOut.z, &r.t) + c.Add(c, c).MulScalar(c, &q.y) + + return +} + +func mulLine(ret *gfP12, a, b, c *gfP2) { + a2 := &gfP6{} + a2.y.Set(a) + a2.z.Set(b) + a2.Mul(a2, &ret.x) + t3 := (&gfP6{}).MulScalar(&ret.y, c) + + t := (&gfP2{}).Add(b, c) + t2 := &gfP6{} + t2.y.Set(a) + t2.z.Set(t) + ret.x.Add(&ret.x, &ret.y) + + ret.y.Set(t3) + + ret.x.Mul(&ret.x, t2).Sub(&ret.x, a2).Sub(&ret.x, &ret.y) + a2.MulTau(a2) + ret.y.Add(&ret.y, a2) +} + +// sixuPlus2NAF is 6u+2 in non-adjacent form. +var sixuPlus2NAF = []int8{0, 0, 0, 1, 0, 1, 0, -1, 0, 0, 1, -1, 0, 0, 1, 0, + 0, 1, 1, 0, -1, 0, 0, 1, 0, -1, 0, 0, 0, 0, 1, 1, + 1, 0, 0, -1, 0, 0, 1, 0, 0, 0, 0, 0, -1, 0, 0, 1, + 1, 0, 0, -1, 0, 0, 0, 1, 1, 0, -1, 0, 0, 1, 0, 1, 1} + +// miller implements the Miller loop for calculating the Optimal Ate pairing. +// See algorithm 1 from http://cryptojedi.org/papers/dclxvi-20100714.pdf +func miller(q *twistPoint, p *curvePoint) *gfP12 { + ret := (&gfP12{}).SetOne() + + aAffine := &twistPoint{} + aAffine.Set(q) + aAffine.MakeAffine() + + bAffine := &curvePoint{} + bAffine.Set(p) + bAffine.MakeAffine() + + minusA := &twistPoint{} + minusA.Neg(aAffine) + + r := &twistPoint{} + r.Set(aAffine) + + r2 := (&gfP2{}).Square(&aAffine.y) + + for i := len(sixuPlus2NAF) - 1; i > 0; i-- { + a, b, c, newR := lineFunctionDouble(r, bAffine) + if i != len(sixuPlus2NAF)-1 { + ret.Square(ret) + } + + mulLine(ret, a, b, c) + r = newR + + switch sixuPlus2NAF[i-1] { + case 1: + a, b, c, newR = lineFunctionAdd(r, aAffine, bAffine, r2) + case -1: + a, b, c, newR = lineFunctionAdd(r, minusA, bAffine, r2) + default: + continue + } + + mulLine(ret, a, b, c) + r = newR + } + + // In order to calculate Q1 we have to convert q from the sextic twist + // to the full GF(p^12) group, apply the Frobenius there, and convert + // back. + // + // The twist isomorphism is (x', y') -> (xω², yω³). If we consider just + // x for a moment, then after applying the Frobenius, we have x̄ω^(2p) + // where x̄ is the conjugate of x. If we are going to apply the inverse + // isomorphism we need a value with a single coefficient of ω² so we + // rewrite this as x̄ω^(2p-2)ω². ξ⁶ = ω and, due to the construction of + // p, 2p-2 is a multiple of six. Therefore we can rewrite as + // x̄ξ^((p-1)/3)ω² and applying the inverse isomorphism eliminates the + // ω². + // + // A similar argument can be made for the y value. + + q1 := &twistPoint{} + q1.x.Conjugate(&aAffine.x).Mul(&q1.x, xiToPMinus1Over3) + q1.y.Conjugate(&aAffine.y).Mul(&q1.y, xiToPMinus1Over2) + q1.z.SetOne() + q1.t.SetOne() + + // For Q2 we are applying the p² Frobenius. The two conjugations cancel + // out and we are left only with the factors from the isomorphism. In + // the case of x, we end up with a pure number which is why + // xiToPSquaredMinus1Over3 is ∈ GF(p). With y we get a factor of -1. We + // ignore this to end up with -Q2. + + minusQ2 := &twistPoint{} + minusQ2.x.MulScalar(&aAffine.x, xiToPSquaredMinus1Over3) + minusQ2.y.Set(&aAffine.y) + minusQ2.z.SetOne() + minusQ2.t.SetOne() + + r2.Square(&q1.y) + a, b, c, newR := lineFunctionAdd(r, q1, bAffine, r2) + mulLine(ret, a, b, c) + r = newR + + r2.Square(&minusQ2.y) + a, b, c, newR = lineFunctionAdd(r, minusQ2, bAffine, r2) + mulLine(ret, a, b, c) + r = newR + + return ret +} + +// finalExponentiation computes the (p¹²-1)/Order-th power of an element of +// GF(p¹²) to obtain an element of GT (steps 13-15 of algorithm 1 from +// http://cryptojedi.org/papers/dclxvi-20100714.pdf) +func finalExponentiation(in *gfP12) *gfP12 { + t1 := &gfP12{} + + // This is the p^6-Frobenius + t1.x.Neg(&in.x) + t1.y.Set(&in.y) + + inv := &gfP12{} + inv.Invert(in) + t1.Mul(t1, inv) + + t2 := (&gfP12{}).FrobeniusP2(t1) + t1.Mul(t1, t2) + + fp := (&gfP12{}).Frobenius(t1) + fp2 := (&gfP12{}).FrobeniusP2(t1) + fp3 := (&gfP12{}).Frobenius(fp2) + + fu := (&gfP12{}).Exp(t1, u) + fu2 := (&gfP12{}).Exp(fu, u) + fu3 := (&gfP12{}).Exp(fu2, u) + + y3 := (&gfP12{}).Frobenius(fu) + fu2p := (&gfP12{}).Frobenius(fu2) + fu3p := (&gfP12{}).Frobenius(fu3) + y2 := (&gfP12{}).FrobeniusP2(fu2) + + y0 := &gfP12{} + y0.Mul(fp, fp2).Mul(y0, fp3) + + y1 := (&gfP12{}).Conjugate(t1) + y5 := (&gfP12{}).Conjugate(fu2) + y3.Conjugate(y3) + y4 := (&gfP12{}).Mul(fu, fu2p) + y4.Conjugate(y4) + + y6 := (&gfP12{}).Mul(fu3, fu3p) + y6.Conjugate(y6) + + t0 := (&gfP12{}).Square(y6) + t0.Mul(t0, y4).Mul(t0, y5) + t1.Mul(y3, y5).Mul(t1, t0) + t0.Mul(t0, y2) + t1.Square(t1).Mul(t1, t0).Square(t1) + t0.Mul(t1, y1) + t1.Mul(t1, y0) + t0.Square(t0).Mul(t0, t1) + + return t0 +} + +func optimalAte(a *twistPoint, b *curvePoint) *gfP12 { + e := miller(a, b) + ret := finalExponentiation(e) + + if a.IsInfinity() || b.IsInfinity() { + ret.SetOne() + } + return ret +} diff --git a/cryptography/bn256/twist.go b/cryptography/bn256/twist.go new file mode 100644 index 0000000..865a930 --- /dev/null +++ b/cryptography/bn256/twist.go @@ -0,0 +1,217 @@ +package bn256 + +import ( + "math/big" +) + +// twistPoint implements the elliptic curve y²=x³+3/ξ over GF(p²). Points are +// kept in Jacobian form and t=z² when valid. The group G₂ is the set of +// n-torsion points of this curve over GF(p²) (where n = Order) +type twistPoint struct { + x, y, z, t gfP2 +} + +// +// btwist = 3 / Fp2(i + 9); btwist +// # 266929791119991161246907387137283842545076965332900288569378510910307636690*i + 19485874751759354771024239261021720505790618469301721065564631296452457478373 +// hex(266929791119991161246907387137283842545076965332900288569378510910307636690) +// # 009713b03af0fed4 cd2cafadeed8fdf4 a74fa084e52d1852 e4a2bd0685c315d2 +// hex(19485874751759354771024239261021720505790618469301721065564631296452457478373) +// # 2b149d40ceb8aaae 81be18991be06ac3 b5b4c5e559dbefa3 3267e6dc24a138e5 +// <\sage> +// +// c0 = 19485874751759354771024239261021720505790618469301721065564631296452457478373 +// c1 = 266929791119991161246907387137283842545076965332900288569378510910307636690 +// +// twistB is the montgomery encoding of the btwist obtained above +var twistB = &gfP2{ + gfP{0x38e7ecccd1dcff67, 0x65f0b37d93ce0d3e, 0xd749d0dd22ac00aa, 0x0141b9ce4a688d4d}, + gfP{0x3bf938e377b802a8, 0x020b1b273633535d, 0x26b7edf049755260, 0x2514c6324384a86d}, +} + +// twistGen is the generator of group G₂. +var twistGen = &twistPoint{ + gfP2{ + gfP{0xafb4737da84c6140, 0x6043dd5a5802d8c4, 0x09e950fc52a02f86, 0x14fef0833aea7b6b}, + gfP{0x8e83b5d102bc2026, 0xdceb1935497b0172, 0xfbb8264797811adf, 0x19573841af96503b}, + }, + gfP2{ + gfP{0x64095b56c71856ee, 0xdc57f922327d3cbb, 0x55f935be33351076, 0x0da4a0e693fd6482}, + gfP{0x619dfa9d886be9f6, 0xfe7fd297f59e9b78, 0xff9e1a62231b7dfe, 0x28fd7eebae9e4206}, + }, + gfP2{*newGFp(0), *newGFp(1)}, + gfP2{*newGFp(0), *newGFp(1)}, +} + +func (c *twistPoint) String() string { + c.MakeAffine() + x, y := gfP2Decode(&c.x), gfP2Decode(&c.y) + return "(" + x.String() + ", " + y.String() + ")" +} + +func (c *twistPoint) Set(a *twistPoint) { + c.x.Set(&a.x) + c.y.Set(&a.y) + c.z.Set(&a.z) + c.t.Set(&a.t) +} + +// IsOnCurve returns true iff c is on the curve. +func (c *twistPoint) IsOnCurve() bool { + c.MakeAffine() + if c.IsInfinity() { + return true + } + + y2, x3 := &gfP2{}, &gfP2{} + y2.Square(&c.y) + x3.Square(&c.x).Mul(x3, &c.x).Add(x3, twistB) + + if *y2 != *x3 { + return false + } + cneg := &twistPoint{} + cneg.Mul(c, Order) + return cneg.z.IsZero() +} + +func (c *twistPoint) SetInfinity() { + c.x.SetZero() + c.y.SetOne() + c.z.SetZero() + c.t.SetZero() +} + +func (c *twistPoint) IsInfinity() bool { + return c.z.IsZero() +} + +func (c *twistPoint) Add(a, b *twistPoint) { + // For additional comments, see the same function in curve.go. + + if a.IsInfinity() { + c.Set(b) + return + } + if b.IsInfinity() { + c.Set(a) + return + } + + // See http://hyperelliptic.org/EFD/g1p/auto-code/shortw/jacobian-0/addition/add-2007-bl.op3 + z12 := (&gfP2{}).Square(&a.z) + z22 := (&gfP2{}).Square(&b.z) + u1 := (&gfP2{}).Mul(&a.x, z22) + u2 := (&gfP2{}).Mul(&b.x, z12) + + t := (&gfP2{}).Mul(&b.z, z22) + s1 := (&gfP2{}).Mul(&a.y, t) + + t.Mul(&a.z, z12) + s2 := (&gfP2{}).Mul(&b.y, t) + + h := (&gfP2{}).Sub(u2, u1) + xEqual := h.IsZero() + + t.Add(h, h) + i := (&gfP2{}).Square(t) + j := (&gfP2{}).Mul(h, i) + + t.Sub(s2, s1) + yEqual := t.IsZero() + if xEqual && yEqual { + c.Double(a) + return + } + r := (&gfP2{}).Add(t, t) + + v := (&gfP2{}).Mul(u1, i) + + t4 := (&gfP2{}).Square(r) + t.Add(v, v) + t6 := (&gfP2{}).Sub(t4, j) + c.x.Sub(t6, t) + + t.Sub(v, &c.x) // t7 + t4.Mul(s1, j) // t8 + t6.Add(t4, t4) // t9 + t4.Mul(r, t) // t10 + c.y.Sub(t4, t6) + + t.Add(&a.z, &b.z) // t11 + t4.Square(t) // t12 + t.Sub(t4, z12) // t13 + t4.Sub(t, z22) // t14 + c.z.Mul(t4, h) +} + +func (c *twistPoint) Double(a *twistPoint) { + // See http://hyperelliptic.org/EFD/g1p/auto-code/shortw/jacobian-0/doubling/dbl-2009-l.op3 + A := (&gfP2{}).Square(&a.x) + B := (&gfP2{}).Square(&a.y) + C := (&gfP2{}).Square(B) + + t := (&gfP2{}).Add(&a.x, B) + t2 := (&gfP2{}).Square(t) + t.Sub(t2, A) + t2.Sub(t, C) + d := (&gfP2{}).Add(t2, t2) + t.Add(A, A) + e := (&gfP2{}).Add(t, A) + f := (&gfP2{}).Square(e) + + t.Add(d, d) + c.x.Sub(f, t) + + t.Add(C, C) + t2.Add(t, t) + t.Add(t2, t2) + c.y.Sub(d, &c.x) + t2.Mul(e, &c.y) + c.y.Sub(t2, t) + + t.Mul(&a.y, &a.z) + c.z.Add(t, t) +} + +func (c *twistPoint) Mul(a *twistPoint, scalar *big.Int) { + sum, t := &twistPoint{}, &twistPoint{} + + for i := scalar.BitLen(); i >= 0; i-- { + t.Double(sum) + if scalar.Bit(i) != 0 { + sum.Add(t, a) + } else { + sum.Set(t) + } + } + + c.Set(sum) +} + +func (c *twistPoint) MakeAffine() { + if c.z.IsOne() { + return + } else if c.z.IsZero() { + c.x.SetZero() + c.y.SetOne() + c.t.SetZero() + return + } + + zInv := (&gfP2{}).Invert(&c.z) + t := (&gfP2{}).Mul(&c.y, zInv) + zInv2 := (&gfP2{}).Square(zInv) + c.y.Mul(t, zInv2) + t.Mul(&c.x, zInv2) + c.x.Set(t) + c.z.SetOne() + c.t.SetOne() +} + +func (c *twistPoint) Neg(a *twistPoint) { + c.x.Set(&a.x) + c.y.Neg(&a.y) + c.z.Set(&a.z) + c.t.SetZero() +} diff --git a/cryptography/crypto/LICENSE b/cryptography/crypto/LICENSE new file mode 100644 index 0000000..26fca3f --- /dev/null +++ b/cryptography/crypto/LICENSE @@ -0,0 +1,90 @@ +RESEARCH LICENSE + + +Version 1.1.2 + +I. DEFINITIONS. + +"Licensee " means You and any other party that has entered into and has in effect a version of this License. + +“Licensor” means DERO PROJECT(GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8) and its successors and assignees. + +"Modifications" means any (a) change or addition to the Technology or (b) new source or object code implementing any portion of the Technology. + +"Research Use" means research, evaluation, or development for the purpose of advancing knowledge, teaching, learning, or customizing the Technology for personal use. Research Use expressly excludes use or distribution for direct or indirect commercial (including strategic) gain or advantage. + +"Technology" means the source code, object code and specifications of the technology made available by Licensor pursuant to this License. + +"Technology Site" means the website designated by Licensor for accessing the Technology. + +"You" means the individual executing this License or the legal entity or entities represented by the individual executing this License. + +II. PURPOSE. + +Licensor is licensing the Technology under this Research License (the "License") to promote research, education, innovation, and development using the Technology. + +COMMERCIAL USE AND DISTRIBUTION OF TECHNOLOGY AND MODIFICATIONS IS PERMITTED ONLY UNDER AN APPROPRIATE COMMERCIAL USE LICENSE AVAILABLE FROM LICENSOR AT . + +III. RESEARCH USE RIGHTS. + +A. Subject to the conditions contained herein, Licensor grants to You a non-exclusive, non-transferable, worldwide, and royalty-free license to do the following for Your Research Use only: + +1. reproduce, create Modifications of, and use the Technology alone, or with Modifications; +2. share source code of the Technology alone, or with Modifications, with other Licensees; + +3. distribute object code of the Technology, alone, or with Modifications, to any third parties for Research Use only, under a license of Your choice that is consistent with this License; and + +4. publish papers and books discussing the Technology which may include relevant excerpts that do not in the aggregate constitute a significant portion of the Technology. + +B. Residual Rights. You may use any information in intangible form that you remember after accessing the Technology, except when such use violates Licensor's copyrights or patent rights. + +C. No Implied Licenses. Other than the rights granted herein, Licensor retains all rights, title, and interest in Technology , and You retain all rights, title, and interest in Your Modifications and associated specifications, subject to the terms of this License. + +D. Open Source Licenses. Portions of the Technology may be provided with notices and open source licenses from open source communities and third parties that govern the use of those portions, and any licenses granted hereunder do not alter any rights and obligations you may have under such open source licenses, however, the disclaimer of warranty and limitation of liability provisions in this License will apply to all Technology in this distribution. + +IV. INTELLECTUAL PROPERTY REQUIREMENTS + +As a condition to Your License, You agree to comply with the following restrictions and responsibilities: + +A. License and Copyright Notices. You must include a copy of this License in a Readme file for any Technology or Modifications you distribute. You must also include the following statement, "Use and distribution of this technology is subject to the Java Research License included herein", (a) once prominently in the source code tree and/or specifications for Your source code distributions, and (b) once in the same file as Your copyright or proprietary notices for Your binary code distributions. You must cause any files containing Your Modification to carry prominent notice stating that You changed the files. You must not remove or alter any copyright or other proprietary notices in the Technology. + +B. Licensee Exchanges. Any Technology and Modifications You receive from any Licensee are governed by this License. + +V. GENERAL TERMS. + +A. Disclaimer Of Warranties. + +TECHNOLOGY IS PROVIDED "AS IS", WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT ANY SUCH TECHNOLOGY IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING OF THIRD PARTY RIGHTS. YOU AGREE THAT YOU BEAR THE ENTIRE RISK IN CONNECTION WITH YOUR USE AND DISTRIBUTION OF ANY AND ALL TECHNOLOGY UNDER THIS LICENSE. + +B. Infringement; Limitation Of Liability. + +1. If any portion of, or functionality implemented by, the Technology becomes the subject of a claim or threatened claim of infringement ("Affected Materials"), Licensor may, in its unrestricted discretion, suspend Your rights to use and distribute the Affected Materials under this License. Such suspension of rights will be effective immediately upon Licensor's posting of notice of suspension on the Technology Site. + +2. IN NO EVENT WILL LICENSOR BE LIABLE FOR ANY DIRECT, INDIRECT, PUNITIVE, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES IN CONNECTION WITH OR ARISING OUT OF THIS LICENSE (INCLUDING, WITHOUT LIMITATION, LOSS OF PROFITS, USE, DATA, OR ECONOMIC ADVANTAGE OF ANY SORT), HOWEVER IT ARISES AND ON ANY THEORY OF LIABILITY (including negligence), WHETHER OR NOT LICENSOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. LIABILITY UNDER THIS SECTION V.B.2 SHALL BE SO LIMITED AND EXCLUDED, NOTWITHSTANDING FAILURE OF THE ESSENTIAL PURPOSE OF ANY REMEDY. + +C. Termination. + +1. You may terminate this License at any time by notifying Licensor in writing. + +2. All Your rights will terminate under this License if You fail to comply with any of its material terms or conditions and do not cure such failure within thirty (30) days after becoming aware of such noncompliance. + +3. Upon termination, You must discontinue all uses and distribution of the Technology , and all provisions of this Section V shall survive termination. + +D. Miscellaneous. + +1. Trademark. You agree to comply with Licensor's Trademark & Logo Usage Requirements, if any and as modified from time to time, available at the Technology Site. Except as expressly provided in this License, You are granted no rights in or to any Licensor's trademarks now or hereafter used or licensed by Licensor. + +2. Integration. This License represents the complete agreement of the parties concerning the subject matter hereof. + +3. Severability. If any provision of this License is held unenforceable, such provision shall be reformed to the extent necessary to make it enforceable unless to do so would defeat the intent of the parties, in which case, this License shall terminate. + +4. Governing Law. This License is governed by the laws of the United States and the State of California, as applied to contracts entered into and performed in California between California residents. In no event shall this License be construed against the drafter. + +5. Export Control. You agree to comply with the U.S. export controlsand trade laws of other countries that apply to Technology and Modifications. + +READ ALL THE TERMS OF THIS LICENSE CAREFULLY BEFORE ACCEPTING. + +BY CLICKING ON THE YES BUTTON BELOW OR USING THE TECHNOLOGY, YOU ARE ACCEPTING AND AGREEING TO ABIDE BY THE TERMS AND CONDITIONS OF THIS LICENSE. YOU MUST BE AT LEAST 18 YEARS OF AGE AND OTHERWISE COMPETENT TO ENTER INTO CONTRACTS. + +IF YOU DO NOT MEET THESE CRITERIA, OR YOU DO NOT AGREE TO ANY OF THE TERMS OF THIS LICENSE, DO NOT USE THIS SOFTWARE IN ANY FORM. + diff --git a/cryptography/crypto/algebra_elgamal.go b/cryptography/crypto/algebra_elgamal.go new file mode 100644 index 0000000..35098b3 --- /dev/null +++ b/cryptography/crypto/algebra_elgamal.go @@ -0,0 +1,177 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "fmt" +import "math/big" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" + +// a ZERO +var ElGamal_ZERO *bn256.G1 +var ElGamal_ZERO_string string +var ElGamal_BASE_G *bn256.G1 + +type ElGamal struct { + G *bn256.G1 + Randomness *big.Int + Left *bn256.G1 + Right *bn256.G1 +} + +func NewElGamal() (p *ElGamal) { + return &ElGamal{G: global_pedersen_values.G} +} +func CommitElGamal(key *bn256.G1, value *big.Int) *ElGamal { + e := NewElGamal() + e.Randomness = RandomScalarFixed() + e.Left = new(bn256.G1).Add(new(bn256.G1).ScalarMult(e.G, value), new(bn256.G1).ScalarMult(key, e.Randomness)) + e.Right = new(bn256.G1).ScalarMult(G, e.Randomness) + return e +} + +func ConstructElGamal(left, right *bn256.G1) *ElGamal { + e := NewElGamal() + + if left != nil { + e.Left = new(bn256.G1).Set(left) + } + e.Right = new(bn256.G1).Set(right) + return e +} + +func (e *ElGamal) IsZero() bool { + if e.Left != nil && e.Right != nil && e.Left.String() == ElGamal_ZERO_string && e.Right.String() == ElGamal_ZERO_string { + return true + } + return false +} + +func (e *ElGamal) Add(addendum *ElGamal) *ElGamal { + if e.Left == nil { + return ConstructElGamal(nil, new(bn256.G1).Add(e.Right, addendum.Right)) + } + return ConstructElGamal(new(bn256.G1).Add(e.Left, addendum.Left), new(bn256.G1).Add(e.Right, addendum.Right)) +} + +func (e *ElGamal) Mul(scalar *big.Int) *ElGamal { + return ConstructElGamal(new(bn256.G1).ScalarMult(e.Left, scalar), new(bn256.G1).ScalarMult(e.Right, scalar)) +} + +func (e *ElGamal) Plus(value *big.Int) *ElGamal { + if e.Right == nil { + return ConstructElGamal(new(bn256.G1).Add(e.Left, new(bn256.G1).ScalarMult(e.G, value)), nil) + } + return ConstructElGamal(new(bn256.G1).Add(e.Left, new(bn256.G1).ScalarMult(e.G, value)), new(bn256.G1).Set(e.Right)) +} + +func (e *ElGamal) Serialize() (data []byte) { + if e.Left == nil || e.Right == nil { + panic("elgamal has nil pointer") + } + data = append(data, e.Left.EncodeUncompressed()...) + data = append(data, e.Right.EncodeUncompressed()...) + return data +} + +func (e *ElGamal) Deserialize(data []byte) *ElGamal { + + if len(data) != 130 { + panic("insufficient buffer size") + } + //var left,right *bn256.G1 + left := new(bn256.G1) + right := new(bn256.G1) + + if err := left.DecodeUncompressed(data[:65]); err != nil { + panic(err) + } + if err := right.DecodeUncompressed(data[65:130]); err != nil { + panic(err) + } + e = ConstructElGamal(left, right) + return e +} + +func (e *ElGamal) Neg() *ElGamal { + + var left, right *bn256.G1 + if e.Left != nil { + left = new(bn256.G1).Neg(e.Left) + } + if e.Right != nil { + right = new(bn256.G1).Neg(e.Right) + } + return ConstructElGamal(left, right) +} + +type ElGamalVector struct { + vector []*ElGamal +} + +func (e *ElGamalVector) MultiExponentiate(exponents *FieldVector) *ElGamal { + accumulator := ConstructElGamal(ElGamal_ZERO, ElGamal_ZERO) + for i := range exponents.vector { + accumulator = accumulator.Add(e.vector[i].Mul(exponents.vector[i])) + } + return accumulator +} + +func (e *ElGamalVector) Sum() *ElGamal { + r := ConstructElGamal(ElGamal_ZERO, ElGamal_ZERO) + for i := range e.vector { + r = r.Add(e.vector[i]) + } + return r +} + +func (e *ElGamalVector) Add(other *ElGamalVector) *ElGamalVector { + var r ElGamalVector + for i := range e.vector { + r.vector = append(r.vector, ConstructElGamal(e.vector[i].Left, e.vector[i].Right)) + } + + for i := range other.vector { + r.vector[i] = r.vector[i].Add(other.vector[i]) + } + return &r +} + +func (e *ElGamalVector) Hadamard(exponents FieldVector) *ElGamalVector { + var r ElGamalVector + for i := range e.vector { + r.vector = append(r.vector, ConstructElGamal(e.vector[i].Left, e.vector[i].Right)) + } + + for i := range exponents.vector { + r.vector[i] = r.vector[i].Mul(exponents.vector[i]) + } + return &r +} + +func (e *ElGamalVector) Times(scalar *big.Int) *ElGamalVector { + var r ElGamalVector + for i := range e.vector { + r.vector = append(r.vector, e.vector[i].Mul(scalar)) + } + return &r +} diff --git a/cryptography/crypto/algebra_fieldvector.go b/cryptography/crypto/algebra_fieldvector.go new file mode 100644 index 0000000..97a6892 --- /dev/null +++ b/cryptography/crypto/algebra_fieldvector.go @@ -0,0 +1,201 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "fmt" +import "math/big" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" + +type FieldVector struct { + vector []*big.Int +} + +func NewFieldVector(input []*big.Int) *FieldVector { + return &FieldVector{vector: input} +} + +func NewFieldVectorRandomFilled(capacity int) *FieldVector { + fv := &FieldVector{vector: make([]*big.Int, capacity, capacity)} + for i := range fv.vector { + fv.vector[i] = RandomScalarFixed() + } + return fv +} + +func (fv *FieldVector) Length() int { + return len(fv.vector) +} + +// slice and return +func (fv *FieldVector) Slice(start, end int) *FieldVector { + var result FieldVector + for i := start; i < end; i++ { + result.vector = append(result.vector, new(big.Int).Set(fv.vector[i])) + } + return &result +} + +//copy and return +func (fv *FieldVector) Clone() *FieldVector { + return fv.Slice(0, len(fv.vector)) +} + +func (fv *FieldVector) SliceRaw(start, end int) []*big.Int { + var result FieldVector + for i := start; i < end; i++ { + result.vector = append(result.vector, new(big.Int).Set(fv.vector[i])) + } + return result.vector +} + +func (fv *FieldVector) Flip() *FieldVector { + var result FieldVector + for i := range fv.vector { + result.vector = append(result.vector, new(big.Int).Set(fv.vector[(len(fv.vector)-i)%len(fv.vector)])) + } + return &result +} + +func (fv *FieldVector) Sum() *big.Int { + var accumulator big.Int + + for i := range fv.vector { + var accopy big.Int + + accopy.Add(&accumulator, fv.vector[i]) + accumulator.Mod(&accopy, bn256.Order) + } + + return &accumulator +} + +func (fv *FieldVector) Add(addendum *FieldVector) *FieldVector { + var result FieldVector + + if len(fv.vector) != len(addendum.vector) { + panic("mismatched number of elements") + } + + for i := range fv.vector { + var ri big.Int + ri.Mod(new(big.Int).Add(fv.vector[i], addendum.vector[i]), bn256.Order) + result.vector = append(result.vector, &ri) + } + + return &result +} + +func (gv *FieldVector) AddConstant(c *big.Int) *FieldVector { + var result FieldVector + + for i := range gv.vector { + var ri big.Int + ri.Mod(new(big.Int).Add(gv.vector[i], c), bn256.Order) + result.vector = append(result.vector, &ri) + } + + return &result +} + +func (fv *FieldVector) Hadamard(exponent *FieldVector) *FieldVector { + var result FieldVector + + if len(fv.vector) != len(exponent.vector) { + panic("mismatched number of elements") + } + for i := range fv.vector { + result.vector = append(result.vector, new(big.Int).Mod(new(big.Int).Mul(fv.vector[i], exponent.vector[i]), bn256.Order)) + } + + return &result +} + +func (fv *FieldVector) InnerProduct(exponent *FieldVector) *big.Int { + if len(fv.vector) != len(exponent.vector) { + panic("mismatched number of elements") + } + + accumulator := new(big.Int) + for i := range fv.vector { + tmp := new(big.Int).Mod(new(big.Int).Mul(fv.vector[i], exponent.vector[i]), bn256.Order) + accumulator.Add(accumulator, tmp) + accumulator.Mod(accumulator, bn256.Order) + } + + return accumulator +} + +func (fv *FieldVector) Negate() *FieldVector { + var result FieldVector + for i := range fv.vector { + result.vector = append(result.vector, new(big.Int).Mod(new(big.Int).Neg(fv.vector[i]), bn256.Order)) + } + return &result +} + +func (fv *FieldVector) Times(multiplier *big.Int) *FieldVector { + var result FieldVector + for i := range fv.vector { + res := new(big.Int).Mul(fv.vector[i], multiplier) + res.Mod(res, bn256.Order) + result.vector = append(result.vector, res) + } + return &result +} + +func (fv *FieldVector) Invert() *FieldVector { + var result FieldVector + for i := range fv.vector { + result.vector = append(result.vector, new(big.Int).ModInverse(fv.vector[i], bn256.Order)) + } + return &result +} + +func (fv *FieldVector) Concat(addendum *FieldVector) *FieldVector { + var result FieldVector + for i := range fv.vector { + result.vector = append(result.vector, new(big.Int).Set(fv.vector[i])) + } + + for i := range addendum.vector { + result.vector = append(result.vector, new(big.Int).Set(addendum.vector[i])) + } + + return &result +} + +func (fv *FieldVector) Extract(parity bool) *FieldVector { + var result FieldVector + + remainder := 0 + if parity { + remainder = 1 + } + for i := range fv.vector { + if i%2 == remainder { + + result.vector = append(result.vector, new(big.Int).Set(fv.vector[i])) + } + } + return &result +} diff --git a/cryptography/crypto/algebra_pedersen.go b/cryptography/crypto/algebra_pedersen.go new file mode 100644 index 0000000..ae17ea7 --- /dev/null +++ b/cryptography/crypto/algebra_pedersen.go @@ -0,0 +1,110 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" +import "math/big" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" + +var G *bn256.G1 +var global_pedersen_values PedersenVectorCommitment + +func init() { + var zeroes [64]byte + var gs, hs []*bn256.G1 + + global_pedersen_values.G = HashToPoint(HashtoNumber([]byte(PROTOCOL_CONSTANT + "G"))) // this is same as mybase or vice-versa + global_pedersen_values.H = HashToPoint(HashtoNumber([]byte(PROTOCOL_CONSTANT + "H"))) + + global_pedersen_values.GSUM = new(bn256.G1) + global_pedersen_values.GSUM.Unmarshal(zeroes[:]) + + for i := 0; i < 128; i++ { + gs = append(gs, HashToPoint(HashtoNumber(append([]byte(PROTOCOL_CONSTANT+"G"), hextobytes(makestring64(fmt.Sprintf("%x", i)))...)))) + hs = append(hs, HashToPoint(HashtoNumber(append([]byte(PROTOCOL_CONSTANT+"H"), hextobytes(makestring64(fmt.Sprintf("%x", i)))...)))) + + global_pedersen_values.GSUM = new(bn256.G1).Add(global_pedersen_values.GSUM, gs[i]) + } + global_pedersen_values.Gs = NewPointVector(gs) + global_pedersen_values.Hs = NewPointVector(hs) + + // also initialize elgamal_zero + ElGamal_ZERO = new(bn256.G1).ScalarMult(global_pedersen_values.G, new(big.Int).SetUint64(0)) + ElGamal_ZERO_string = ElGamal_ZERO.String() + ElGamal_BASE_G = global_pedersen_values.G + G = global_pedersen_values.G + ((*bn256.G1)(&GPoint)).Set(G) // setup base point + + // fmt.Printf("basepoint %s on %x\n", G.String(), G.Marshal()) +} + +type PedersenCommitmentNew struct { + G *bn256.G1 + H *bn256.G1 + Randomness *big.Int + Result *bn256.G1 +} + +func NewPedersenCommitmentNew() (p *PedersenCommitmentNew) { + return &PedersenCommitmentNew{G: global_pedersen_values.G, H: global_pedersen_values.H} +} + +// commit a specific value to specific bases +func (p *PedersenCommitmentNew) Commit(value *big.Int) *PedersenCommitmentNew { + p.Randomness = RandomScalarFixed() + point := new(bn256.G1).Add(new(bn256.G1).ScalarMult(p.G, value), new(bn256.G1).ScalarMult(p.H, p.Randomness)) + p.Result = new(bn256.G1).Set(point) + return p +} + +type PedersenVectorCommitment struct { + G *bn256.G1 + H *bn256.G1 + GSUM *bn256.G1 + + Gs *PointVector + Hs *PointVector + Randomness *big.Int + Result *bn256.G1 + + gvalues *FieldVector + hvalues *FieldVector +} + +func NewPedersenVectorCommitment() (p *PedersenVectorCommitment) { + p = &PedersenVectorCommitment{} + *p = global_pedersen_values + return +} + +// commit a specific value to specific bases +func (p *PedersenVectorCommitment) Commit(gvalues, hvalues *FieldVector) *PedersenVectorCommitment { + + p.Randomness = RandomScalarFixed() + point := new(bn256.G1).ScalarMult(p.H, p.Randomness) + point = new(bn256.G1).Add(point, p.Gs.MultiExponentiate(gvalues)) + point = new(bn256.G1).Add(point, p.Hs.MultiExponentiate(hvalues)) + + p.Result = new(bn256.G1).Set(point) + return p +} diff --git a/cryptography/crypto/algebra_pointvector.go b/cryptography/crypto/algebra_pointvector.go new file mode 100644 index 0000000..7cfffa6 --- /dev/null +++ b/cryptography/crypto/algebra_pointvector.go @@ -0,0 +1,192 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "fmt" +import "math/big" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" + +// ToDO evaluate others curves such as BLS12 used by zcash, also BLS24 or others , providing ~200 bits of security , may be required for long time use( say 50 years) +type PointVector struct { + vector []*bn256.G1 +} + +func NewPointVector(input []*bn256.G1) *PointVector { + return &PointVector{vector: input} +} + +func (gv *PointVector) Length() int { + return len(gv.vector) +} + +// slice and return +func (gv *PointVector) Slice(start, end int) *PointVector { + var result PointVector + for i := start; i < end; i++ { + var ri bn256.G1 + ri.Set(gv.vector[i]) + result.vector = append(result.vector, &ri) + } + return &result +} + +func (gv *PointVector) Commit(exponent []*big.Int) *bn256.G1 { + var accumulator, zero bn256.G1 + var zeroes [64]byte + accumulator.Unmarshal(zeroes[:]) // obtain zero element, this should be static and + zero.Unmarshal(zeroes[:]) + + accumulator.ScalarMult(G, new(big.Int)) + + //fmt.Printf("zero %s\n", accumulator.String()) + + if len(gv.vector) != len(exponent) { + panic("mismatched number of elements") + } + for i := range gv.vector { // TODO a bug exists somewhere deep here + var tmp, accopy bn256.G1 + tmp.ScalarMult(gv.vector[i], exponent[i]) + + accopy.Set(&accumulator) + accumulator.Add(&accopy, &tmp) + } + + return &accumulator +} + +func (gv *PointVector) Sum() *bn256.G1 { + var accumulator bn256.G1 + + accumulator.ScalarMult(G, new(big.Int)) // set it to zero + + for i := range gv.vector { + var accopy bn256.G1 + + accopy.Set(&accumulator) + accumulator.Add(&accopy, gv.vector[i]) + } + + return &accumulator +} + +func (gv *PointVector) Add(addendum *PointVector) *PointVector { + var result PointVector + + if len(gv.vector) != len(addendum.vector) { + panic("mismatched number of elements") + } + + for i := range gv.vector { + var ri bn256.G1 + + ri.Add(gv.vector[i], addendum.vector[i]) + result.vector = append(result.vector, &ri) + } + + return &result +} + +func (gv *PointVector) Hadamard(exponent []*big.Int) *PointVector { + var result PointVector + + if len(gv.vector) != len(exponent) { + panic("mismatched number of elements") + } + for i := range gv.vector { + var ri bn256.G1 + ri.ScalarMult(gv.vector[i], exponent[i]) + result.vector = append(result.vector, &ri) + + } + + return &result +} + +func (gv *PointVector) Negate() *PointVector { + var result PointVector + for i := range gv.vector { + var ri bn256.G1 + ri.Neg(gv.vector[i]) + result.vector = append(result.vector, &ri) + } + return &result +} + +func (gv *PointVector) Times(multiplier *big.Int) *PointVector { + var result PointVector + for i := range gv.vector { + var ri bn256.G1 + ri.ScalarMult(gv.vector[i], multiplier) + result.vector = append(result.vector, &ri) + } + return &result +} + +func (gv *PointVector) Extract(parity bool) *PointVector { + var result PointVector + + remainder := 0 + if parity { + remainder = 1 + } + for i := range gv.vector { + if i%2 == remainder { + var ri bn256.G1 + ri.Set(gv.vector[i]) + result.vector = append(result.vector, &ri) + } + } + return &result +} + +func (gv *PointVector) Concat(addendum *PointVector) *PointVector { + var result PointVector + for i := range gv.vector { + var ri bn256.G1 + ri.Set(gv.vector[i]) + result.vector = append(result.vector, &ri) + } + + for i := range addendum.vector { + var ri bn256.G1 + ri.Set(addendum.vector[i]) + result.vector = append(result.vector, &ri) + } + + return &result +} + +func (pv *PointVector) MultiExponentiate(fv *FieldVector) *bn256.G1 { + var accumulator bn256.G1 + + accumulator.ScalarMult(G, new(big.Int)) // set it to zero + + for i := range fv.vector { + var accopy bn256.G1 + + accopy.Set(&accumulator) + accumulator.Add(&accopy, new(bn256.G1).ScalarMult(pv.vector[i], fv.vector[i])) + } + + return &accumulator +} diff --git a/cryptography/crypto/bnred.go b/cryptography/crypto/bnred.go new file mode 100644 index 0000000..1e22b16 --- /dev/null +++ b/cryptography/crypto/bnred.go @@ -0,0 +1,102 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" +import "math/big" + +//import "encoding/binary" + +//import "crypto/rand" +//import "github.com/deroproject/derohe/crypto/bn256" + +// this file implements Big Number Reduced form with bn256's Order + +type BNRed big.Int + +func RandomScalarBNRed() *BNRed { + return (*BNRed)(RandomScalar()) +} + +// converts big.Int to BNRed +func GetBNRed(x *big.Int) *BNRed { + result := new(BNRed) + + ((*big.Int)(result)).Set(x) + return result +} + +// convert BNRed to BigInt +func (x *BNRed) BigInt() *big.Int { + return new(big.Int).Set(((*big.Int)(x))) +} + +func (x *BNRed) SetBytes(buf []byte) *BNRed { + ((*big.Int)(x)).SetBytes(buf) + return x +} + +func (x *BNRed) String() string { + return ((*big.Int)(x)).Text(16) +} + +func (x *BNRed) Text(base int) string { + return ((*big.Int)(x)).Text(base) +} + +func (x *BNRed) MarshalText() ([]byte, error) { + return []byte(((*big.Int)(x)).Text(16)), nil +} + +func (x *BNRed) UnmarshalText(text []byte) error { + _, err := fmt.Sscan("0x"+string(text), ((*big.Int)(x))) + return err +} + +func FillBytes(x *big.Int, xbytes []byte) { + // FillBytes not available pre 1.15 + bb := x.Bytes() + + if len(bb) > 32 { + panic(fmt.Sprintf("number not representable in 32 bytes %d %x", len(bb), bb)) + } + + for i := range xbytes { // optimized to memclr + xbytes[i] = 0 + } + + j := 32 + for i := len(bb) - 1; i >= 0; i-- { + j-- + xbytes[j] = bb[i] + } +} + +/* +// this will return fixed random scalar +func RandomScalarFixed() *big.Int { + //return new(big.Int).Set(fixed) + + return RandomScalar() +} + + +type KeyPair struct { + x *big.Int // secret key + y *bn256.G1 // public key +} +*/ diff --git a/cryptography/crypto/const.go b/cryptography/crypto/const.go new file mode 100644 index 0000000..a0deb40 --- /dev/null +++ b/cryptography/crypto/const.go @@ -0,0 +1,57 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" + +const POINT_SIZE = 33 // this can be optimized to 33 bytes +const FIELDELEMENT_SIZE = 32 // why not have bigger curves + +// protocol supports amounts upto this amounts +const MAX_AMOUNT = 18446744073709551616 // 2^64 - 1, + +const PROTOCOL_CONSTANT = "DERO" + +// checks a number is power of 2 +func IsPowerOf2(num int) bool { + for num >= 2 { + if num%2 != 0 { + return false + } + num = num / 2 + } + return num == 1 +} + +// tell what power a number is +func GetPowerof2(num int) int { + + if num <= 0 { + panic("number cannot be less than 0") + } + + if !IsPowerOf2(num) { + panic(fmt.Sprintf("number(%d) must be power of 2", num)) + } + + power := 0 + calculated := 1 + for ; calculated != num; power++ { + calculated *= 2 + } + return power +} diff --git a/cryptography/crypto/fieldvector.go b/cryptography/crypto/fieldvector.go new file mode 100644 index 0000000..6ac101c --- /dev/null +++ b/cryptography/crypto/fieldvector.go @@ -0,0 +1,297 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "fmt" +import "math/big" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +type FieldVectorPolynomial struct { + coefficients []*FieldVector +} + +func NewFieldVectorPolynomial(inputs ...*FieldVector) *FieldVectorPolynomial { + fv := &FieldVectorPolynomial{} + for _, input := range inputs { + fv.coefficients = append(fv.coefficients, input.Clone()) + } + return fv +} + +func (fv *FieldVectorPolynomial) Length() int { + return len(fv.coefficients) +} + +func (fv *FieldVectorPolynomial) Evaluate(x *big.Int) *FieldVector { + + result := fv.coefficients[0].Clone() + + accumulator := new(big.Int).Set(x) + + for i := 1; i < len(fv.coefficients); i++ { + result = result.Add(fv.coefficients[i].Times(accumulator)) + accumulator.Mul(accumulator, x) + accumulator.Mod(accumulator, bn256.Order) + + } + return result +} + +func (fv *FieldVectorPolynomial) InnerProduct(other *FieldVectorPolynomial) []*big.Int { + + var result []*big.Int + + result_length := fv.Length() + other.Length() - 1 + for i := 0; i < result_length; i++ { + result = append(result, new(big.Int)) // 0 value fill + } + + for i := range fv.coefficients { + for j := range other.coefficients { + tmp := new(big.Int).Set(result[i+j]) + result[i+j].Add(tmp, fv.coefficients[i].InnerProduct(other.coefficients[j])) + result[i+j].Mod(result[i+j], bn256.Order) + } + } + return result +} + +/* + +type PedersenCommitment struct { + X *big.Int + R *big.Int + Params *GeneratorParams +} + +func NewPedersenCommitment(params *GeneratorParams, x, r *big.Int) *PedersenCommitment { + pc := &PedersenCommitment{Params: params, X: new(big.Int).Set(x), R: new(big.Int).Set(r)} + return pc +} +func (pc *PedersenCommitment) Commit() *bn256.G1 { + var left, right, result bn256.G1 + left.ScalarMult(pc.Params.G, pc.X) + right.ScalarMult(pc.Params.H, pc.R) + result.Add(&left, &right) + return &result +} +func (pc *PedersenCommitment) Add(other *PedersenCommitment) *PedersenCommitment { + var x, r big.Int + x.Mod(new(big.Int).Add(pc.X, other.X), bn256.Order) + r.Mod(new(big.Int).Add(pc.R, other.R), bn256.Order) + return NewPedersenCommitment(pc.Params, &x, &r) +} +func (pc *PedersenCommitment) Times(constant *big.Int) *PedersenCommitment { + var x, r big.Int + x.Mod(new(big.Int).Mul(pc.X, constant), bn256.Order) + r.Mod(new(big.Int).Mul(pc.R, constant), bn256.Order) + return NewPedersenCommitment(pc.Params, &x, &r) +} + +type PolyCommitment struct { + coefficient_commitments []*PedersenCommitment + Params *GeneratorParams +} + +func NewPolyCommitment(params *GeneratorParams, coefficients []*big.Int) *PolyCommitment { + pc := &PolyCommitment{Params: params} + pc.coefficient_commitments = append(pc.coefficient_commitments, NewPedersenCommitment(params, coefficients[0], new(big.Int).SetUint64(0))) + + for i := 1; i < len(coefficients); i++ { + pc.coefficient_commitments = append(pc.coefficient_commitments, NewPedersenCommitment(params, coefficients[i], RandomScalarFixed())) + + } + return pc +} + +func (pc *PolyCommitment) GetCommitments() []*bn256.G1 { + var result []*bn256.G1 + for i := 1; i < len(pc.coefficient_commitments); i++ { + result = append(result, pc.coefficient_commitments[i].Commit()) + } + return result +} + +func (pc *PolyCommitment) Evaluate(constant *big.Int) *PedersenCommitment { + result := pc.coefficient_commitments[0] + + accumulator := new(big.Int).Set(constant) + + for i := 1; i < len(pc.coefficient_commitments); i++ { + + tmp := new(big.Int).Set(accumulator) + result = result.Add(pc.coefficient_commitments[i].Times(accumulator)) + accumulator.Mod(new(big.Int).Mul(tmp, constant), bn256.Order) + } + + return result +} +*/ + +/* +// bother FieldVector and GeneratorVector satisfy this +type Vector interface{ + Length() int + Extract(parity bool) Vector + Add(other Vector)Vector + Hadamard( []*big.Int) Vector + Times (*big.Int) Vector + Negate() Vector +} +*/ + +// check this https://pdfs.semanticscholar.org/d38d/e48ee4127205a0f25d61980c8f241718b66e.pdf +// https://arxiv.org/pdf/1802.03932.pdf + +var unity *big.Int + +func init() { + // primitive 2^28th root of unity modulo q + unity, _ = new(big.Int).SetString("14a3074b02521e3b1ed9852e5028452693e87be4e910500c7ba9bbddb2f46edd", 16) + +} + +func fft_FieldVector(input *FieldVector, inverse bool) *FieldVector { + length := input.Length() + if length == 1 { + return input + } + + // lngth must be multiple of 2 ToDO + if length%2 != 0 { + panic("length must be multiple of 2") + } + + //unity,_ := new(big.Int).SetString("14a3074b02521e3b1ed9852e5028452693e87be4e910500c7ba9bbddb2f46edd",16) + + omega := new(big.Int).Exp(unity, new(big.Int).SetUint64((1<<28)/uint64(length)), bn256.Order) + if inverse { + omega = new(big.Int).ModInverse(omega, bn256.Order) + } + + even := fft_FieldVector(input.Extract(false), inverse) + odd := fft_FieldVector(input.Extract(true), inverse) + + omegas := []*big.Int{new(big.Int).SetUint64(1)} + + for i := 1; i < length/2; i++ { + omegas = append(omegas, new(big.Int).Mod(new(big.Int).Mul(omegas[i-1], omega), bn256.Order)) + } + + omegasv := NewFieldVector(omegas) + result := even.Add(odd.Hadamard(omegasv)).Concat(even.Add(odd.Hadamard(omegasv).Negate())) + if inverse { + result = result.Times(new(big.Int).ModInverse(new(big.Int).SetUint64(2), bn256.Order)) + } + + return result + +} + +// this is exactly same as fft_FieldVector, alternate implementation +func fftints(input []*big.Int) (result []*big.Int) { + size := len(input) + if size == 1 { + return input + } + //require(size % 2 == 0, "Input size is not a power of 2!"); + + unity, _ := new(big.Int).SetString("14a3074b02521e3b1ed9852e5028452693e87be4e910500c7ba9bbddb2f46edd", 16) + + omega := new(big.Int).Exp(unity, new(big.Int).SetUint64((1<<28)/uint64(size)), bn256.Order) + + even := fftints(extractbits(input, 0)) + odd := fftints(extractbits(input, 1)) + omega_run := new(big.Int).SetUint64(1) + result = make([]*big.Int, len(input), len(input)) + for i := 0; i < len(input)/2; i++ { + temp := new(big.Int).Mod(new(big.Int).Mul(odd[i], omega_run), bn256.Order) + result[i] = new(big.Int).Mod(new(big.Int).Add(even[i], temp), bn256.Order) + result[i+size/2] = new(big.Int).Mod(new(big.Int).Sub(even[i], temp), bn256.Order) + omega_run = new(big.Int).Mod(new(big.Int).Mul(omega, omega_run), bn256.Order) + } + return result +} + +func extractbits(input []*big.Int, parity int) (result []*big.Int) { + result = make([]*big.Int, len(input)/2, len(input)/2) + for i := 0; i < len(input)/2; i++ { + result[i] = new(big.Int).Set(input[2*i+parity]) + } + return +} + +func fft_GeneratorVector(input *PointVector, inverse bool) *PointVector { + length := input.Length() + if length == 1 { + return input + } + + // lngth must be multiple of 2 ToDO + if length%2 != 0 { + panic("length must be multiple of 2") + } + + // unity,_ := new(big.Int).SetString("14a3074b02521e3b1ed9852e5028452693e87be4e910500c7ba9bbddb2f46edd",16) + + omega := new(big.Int).Exp(unity, new(big.Int).SetUint64((1<<28)/uint64(length)), bn256.Order) + if inverse { + omega = new(big.Int).ModInverse(omega, bn256.Order) + } + + even := fft_GeneratorVector(input.Extract(false), inverse) + + //fmt.Printf("exponent_fft %d %s \n",i, exponent_fft.vector[i].Text(16)) + + odd := fft_GeneratorVector(input.Extract(true), inverse) + + omegas := []*big.Int{new(big.Int).SetUint64(1)} + + for i := 1; i < length/2; i++ { + omegas = append(omegas, new(big.Int).Mod(new(big.Int).Mul(omegas[i-1], omega), bn256.Order)) + } + + omegasv := omegas + result := even.Add(odd.Hadamard(omegasv)).Concat(even.Add(odd.Hadamard(omegasv).Negate())) + if inverse { + result = result.Times(new(big.Int).ModInverse(new(big.Int).SetUint64(2), bn256.Order)) + } + + return result + +} + +func Convolution(exponent *FieldVector, base *PointVector) *PointVector { + size := base.Length() + + exponent_fft := fft_FieldVector(exponent.Flip(), false) + + /*exponent_fft2 := fftints( exponent.Flip().vector) // aternate implementation proof checking + for i := range exponent_fft.vector{ + fmt.Printf("exponent_fft %d %s \n",i, exponent_fft.vector[i].Text(16)) + fmt.Printf("exponent_ff2 %d %s \n",i, exponent_fft2[i].Text(16)) + } + */ + + temp := fft_GeneratorVector(base, false).Hadamard(exponent_fft.vector) + return fft_GeneratorVector(temp.Slice(0, size/2).Add(temp.Slice(size/2, size)).Times(new(big.Int).ModInverse(new(big.Int).SetUint64(2), bn256.Order)), true) + // using the optimization described here https://dsp.stackexchange.com/a/30699 +} diff --git a/cryptography/crypto/generatorparams.go b/cryptography/crypto/generatorparams.go new file mode 100644 index 0000000..a06801e --- /dev/null +++ b/cryptography/crypto/generatorparams.go @@ -0,0 +1,72 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" +import "math/big" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +func NewGeneratorParams(count int) *GeneratorParams { + GP := &GeneratorParams{} + var zeroes [64]byte + + GP.G = HashToPoint(HashtoNumber([]byte(PROTOCOL_CONSTANT + "G"))) // this is same as mybase or vice-versa + GP.H = HashToPoint(HashtoNumber([]byte(PROTOCOL_CONSTANT + "H"))) + + var gs, hs []*bn256.G1 + + GP.GSUM = new(bn256.G1) + GP.GSUM.Unmarshal(zeroes[:]) + + for i := 0; i < count; i++ { + gs = append(gs, HashToPoint(HashtoNumber(append([]byte(PROTOCOL_CONSTANT+"G"), hextobytes(makestring64(fmt.Sprintf("%x", i)))...)))) + hs = append(hs, HashToPoint(HashtoNumber(append([]byte(PROTOCOL_CONSTANT+"H"), hextobytes(makestring64(fmt.Sprintf("%x", i)))...)))) + + GP.GSUM = new(bn256.G1).Add(GP.GSUM, gs[i]) + } + GP.Gs = NewPointVector(gs) + GP.Hs = NewPointVector(hs) + + return GP +} + +func NewGeneratorParams3(h *bn256.G1, gs, hs *PointVector) *GeneratorParams { + GP := &GeneratorParams{} + + GP.G = HashToPoint(HashtoNumber([]byte(PROTOCOL_CONSTANT + "G"))) // this is same as mybase or vice-versa + GP.H = h + GP.Gs = gs + GP.Hs = hs + return GP +} + +func (gp *GeneratorParams) Commit(blind *big.Int, gexps, hexps *FieldVector) *bn256.G1 { + result := new(bn256.G1).ScalarMult(gp.H, blind) + for i := range gexps.vector { + result = new(bn256.G1).Add(result, new(bn256.G1).ScalarMult(gp.Gs.vector[i], gexps.vector[i])) + } + if hexps != nil { + for i := range hexps.vector { + result = new(bn256.G1).Add(result, new(bn256.G1).ScalarMult(gp.Hs.vector[i], hexps.vector[i])) + } + } + return result +} diff --git a/cryptography/crypto/group.go b/cryptography/crypto/group.go new file mode 100644 index 0000000..31131fe --- /dev/null +++ b/cryptography/crypto/group.go @@ -0,0 +1,73 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "fmt" +import "math/big" +import "encoding/hex" + +//import "crypto/rand" +import "github.com/deroproject/derohe/cryptography/bn256" + +// this file implements Big Number Reduced form with bn256's Order + +type Point bn256.G1 + +var GPoint Point + +// ScalarMult with chainable API +func (p *Point) ScalarMult(r *BNRed) (result *Point) { + result = new(Point) + ((*bn256.G1)(result)).ScalarMult(((*bn256.G1)(p)), ((*big.Int)(r))) + return result +} + +func (p *Point) EncodeCompressed() []byte { + return ((*bn256.G1)(p)).EncodeCompressed() +} + +func (p *Point) DecodeCompressed(i []byte) error { + return ((*bn256.G1)(p)).DecodeCompressed(i) +} + +func (p *Point) G1() *bn256.G1 { + return ((*bn256.G1)(p)) +} +func (p *Point) Set(x *Point) *Point { + return ((*Point)(((*bn256.G1)(p)).Set(((*bn256.G1)(x))))) +} + +func (p *Point) String() string { + return string(((*bn256.G1)(p)).EncodeCompressed()) +} + +func (p *Point) StringHex() string { + return string(hex.EncodeToString(((*bn256.G1)(p)).EncodeCompressed())) +} + +func (p *Point) MarshalText() ([]byte, error) { + return []byte(hex.EncodeToString(((*bn256.G1)(p)).EncodeCompressed())), nil +} + +func (p *Point) UnmarshalText(text []byte) error { + + tmp, err := hex.DecodeString(string(text)) + if err != nil { + return err + } + return p.DecodeCompressed(tmp) +} diff --git a/cryptography/crypto/hash.go b/cryptography/crypto/hash.go new file mode 100644 index 0000000..3223456 --- /dev/null +++ b/cryptography/crypto/hash.go @@ -0,0 +1,68 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" +import "encoding/hex" + +const HashLength = 32 + +type Hash [HashLength]byte + +var ZEROHASH Hash + +func (h Hash) MarshalText() ([]byte, error) { + return []byte(fmt.Sprintf("%x", h[:])), nil +} + +func (h *Hash) UnmarshalText(data []byte) (err error) { + byteSlice, _ := hex.DecodeString(string(data)) + if len(byteSlice) != 32 { + return fmt.Errorf("Incorrect hash size") + } + copy(h[:], byteSlice) + return +} + +// stringifier +func (h Hash) String() string { + return fmt.Sprintf("%064x", h[:]) +} + +func (h Hash) IsZero() bool { + var zerohash Hash + return h == zerohash +} + +// convert a hash of hex form to binary form, returns a zero hash if any error +// TODO this should be in crypto +func HashHexToHash(hash_hex string) (hash Hash) { + hash_raw, err := hex.DecodeString(hash_hex) + + if err != nil { + //panic(fmt.Sprintf("Cannot hex decode checkpint hash \"%s\"", hash_hex)) + return hash + } + + if len(hash_raw) != 32 { + //panic(fmt.Sprintf(" hash not 32 byte size Cannot hex decode checkpint hash \"%s\"", hash_hex)) + return hash + } + + copy(hash[:], hash_raw) + return +} diff --git a/cryptography/crypto/hashtopoint.go b/cryptography/crypto/hashtopoint.go new file mode 100644 index 0000000..1fd0a89 --- /dev/null +++ b/cryptography/crypto/hashtopoint.go @@ -0,0 +1,260 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" +import "math/big" + +//import "crypto/rand" +import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" +import "github.com/deroproject/derohe/cryptography/sha3" + +// the original try and increment method A Note on Hashing to BN Curves https://www.normalesup.org/~tibouchi/papers/bnhash-scis.pdf +// see this for a simplified version https://github.com/clearmatics/mobius/blob/7ad988b816b18e22424728329fc2b166d973a120/contracts/bn256g1.sol + +var FIELD_MODULUS, w = new(big.Int).SetString("30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47", 16) +var GROUP_MODULUS, w1 = new(big.Int).SetString("30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f0000001", 16) + +// this file basically implements curve based items + +type GeneratorParams struct { + G *bn256.G1 + H *bn256.G1 + GSUM *bn256.G1 + + Gs *PointVector + Hs *PointVector +} + +// converts a big int to 32 bytes, prepending zeroes +func ConvertBigIntToByte(x *big.Int) []byte { + var dummy [128]byte + joined := append(dummy[:], x.Bytes()...) + return joined[len(joined)-32:] +} + +// the number if already reduced +func HashtoNumber(input []byte) *big.Int { + + hasher := sha3.NewLegacyKeccak256() + hasher.Write(input) + + hash := hasher.Sum(nil) + return new(big.Int).SetBytes(hash[:]) +} + +// calculate hash and reduce it by curve's order +func reducedhash(input []byte) *big.Int { + return new(big.Int).Mod(HashtoNumber(input), bn256.Order) +} + +func ReducedHash(input []byte) *big.Int { + return new(big.Int).Mod(HashtoNumber(input), bn256.Order) +} + +func makestring64(input string) string { + for len(input) != 64 { + input = "0" + input + } + return input +} + +func makestring66(input string) string { + for len(input) != 64 { + input = "0" + input + } + return input + "00" +} + +func hextobytes(input string) []byte { + ibytes, err := hex.DecodeString(input) + if err != nil { + panic(err) + } + return ibytes +} + +// p = p(u) = 36u^4 + 36u^3 + 24u^2 + 6u + 1 +var FIELD_ORDER, _ = new(big.Int).SetString("30644e72e131a029b85045b68181585d97816a916871ca8d3c208c16d87cfd47", 16) + +// Number of elements in the field (often called `q`) +// n = n(u) = 36u^4 + 36u^3 + 18u^2 + 6u + 1 +var GEN_ORDER, _ = new(big.Int).SetString("30644e72e131a029b85045b68181585d2833e84879b9709143e1f593f0000001", 16) + +var CURVE_B = new(big.Int).SetUint64(3) + +// a = (p+1) / 4 +var CURVE_A, _ = new(big.Int).SetString("c19139cb84c680a6e14116da060561765e05aa45a1c72a34f082305b61f3f52", 16) + +func HashToPointNew(seed *big.Int) *bn256.G1 { + y_squared := new(big.Int) + one := new(big.Int).SetUint64(1) + + x := new(big.Int).Set(seed) + x.Mod(x, GEN_ORDER) + for { + beta, y := findYforX(x) + + if y != nil { + + // fmt.Printf("beta %s y %s\n", beta.String(),y.String()) + + // y^2 == beta + y_squared.Mul(y, y) + y_squared.Mod(y_squared, FIELD_ORDER) + + if beta.Cmp(y_squared) == 0 { + + // fmt.Printf("liesoncurve test %+v\n", isOnCurve(x,y)) + // fmt.Printf("x %s\n",x.Text(16)) + // fmt.Printf("y %s\n",y.Text(16)) + + xstring := x.Text(16) + ystring := y.Text(16) + + var point bn256.G1 + xbytes, err := hex.DecodeString(makestring64(xstring)) + if err != nil { + panic(err) + } + ybytes, err := hex.DecodeString(makestring64(ystring)) + if err != nil { + panic(err) + } + + if _, err := point.Unmarshal(append(xbytes, ybytes...)); err == nil { + return &point + } else { + + panic(fmt.Sprintf("not found err %s\n", err)) + } + } + } + + x.Add(x, one) + x.Mod(x, FIELD_ORDER) + } + +} + +/* + * Given X, find Y + * + * where y = sqrt(x^3 + b) + * + * Returns: (x^3 + b), y +**/ +func findYforX(x *big.Int) (*big.Int, *big.Int) { + // beta = (x^3 + b) % p + xcube := new(big.Int).Exp(x, CURVE_B, FIELD_ORDER) + xcube.Add(xcube, CURVE_B) + beta := new(big.Int).Mod(xcube, FIELD_ORDER) + //beta := addmod(mulmod(mulmod(x, x, FIELD_ORDER), x, FIELD_ORDER), CURVE_B, FIELD_ORDER); + + // y^2 = x^3 + b + // this acts like: y = sqrt(beta) + + //ymod := new(big.Int).ModSqrt(beta,FIELD_ORDER) // this can return nil in some cases + y := new(big.Int).Exp(beta, CURVE_A, FIELD_ORDER) + return beta, y +} + +/* + * Verify if the X and Y coordinates represent a valid Point on the Curve + * + * Where the G1 curve is: x^2 = x^3 + b +**/ +func isOnCurve(x, y *big.Int) bool { + //p_squared := new(big.Int).Exp(x, new(big.Int).SetUint64(2), FIELD_ORDER); + p_cubed := new(big.Int).Exp(x, new(big.Int).SetUint64(3), FIELD_ORDER) + + p_cubed.Add(p_cubed, CURVE_B) + p_cubed.Mod(p_cubed, FIELD_ORDER) + + // return addmod(p_cubed, CURVE_B, FIELD_ORDER) == mulmod(p.Y, p.Y, FIELD_ORDER); + return p_cubed.Cmp(new(big.Int).Exp(y, new(big.Int).SetUint64(2), FIELD_ORDER)) == 0 +} + +// this should be merged , simplified just as simple as 25519 +func HashToPoint(seed *big.Int) *bn256.G1 { + /* + var x, _ = new(big.Int).SetString("0d36fdf1852f1563df9c904374055bb2a4d351571b853971764b9561ae203a9e",16) + var y, _ = new(big.Int).SetString("06efda2e606d7bafec34b82914953fa253d21ca3ced18db99c410e9057dccd50",16) + + + + fmt.Printf("hardcode point on curve %+v\n", isOnCurve(x,y)) + panic("done") + */ + return HashToPointNew(seed) + + seed_reduced := new(big.Int) + seed_reduced.Mod(seed, FIELD_MODULUS) + + counter := 0 + + p_1_4 := new(big.Int).Add(FIELD_MODULUS, new(big.Int).SetInt64(1)) + p_1_4 = p_1_4.Div(p_1_4, new(big.Int).SetInt64(4)) + + for { + tmp := new(big.Int) + y, y_squared, y_resquare := new(big.Int), new(big.Int), new(big.Int) // basically y_sqaured = seed ^3 + 3 mod group order + tmp.Exp(seed_reduced, new(big.Int).SetInt64(3), FIELD_MODULUS) + y_squared.Add(tmp, new(big.Int).SetInt64(3)) + y_squared.Mod(y_squared, FIELD_MODULUS) + + y = y.Exp(y_squared, p_1_4, FIELD_MODULUS) + + y_resquare = y_resquare.Exp(y, new(big.Int).SetInt64(2), FIELD_MODULUS) + + if y_resquare.Cmp(y_squared) == 0 { // seed becomes x and y iis usy + xstring := seed_reduced.Text(16) + ystring := y.Text(16) + + var point bn256.G1 + xbytes, err := hex.DecodeString(makestring64(xstring)) + if err != nil { + panic(err) + } + ybytes, err := hex.DecodeString(makestring64(ystring)) + if err != nil { + panic(err) + } + + if _, err = point.Unmarshal(append(xbytes, ybytes...)); err == nil { + return &point + } else { + // continue finding + counter++ + + if counter%10000 == 0 { + fmt.Printf("tried %d times\n", counter) + } + + } + + } + seed_reduced.Add(seed_reduced, new(big.Int).SetInt64(1)) + seed_reduced.Mod(seed_reduced, FIELD_MODULUS) + } + + return nil +} diff --git a/cryptography/crypto/keccak.go b/cryptography/crypto/keccak.go new file mode 100644 index 0000000..528a6d2 --- /dev/null +++ b/cryptography/crypto/keccak.go @@ -0,0 +1,41 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "golang.org/x/crypto/sha3" +import "github.com/deroproject/derohe/cryptography/sha3" + +// quick keccak wrapper +func Keccak256(data ...[]byte) (result Hash) { + h := sha3.NewLegacyKeccak256() + for _, b := range data { + h.Write(b) + } + r := h.Sum(nil) + copy(result[:], r) + return +} + +func Keccak512(data ...[]byte) (result Hash) { + h := sha3.NewLegacyKeccak512() + for _, b := range data { + h.Write(b) + } + r := h.Sum(nil) + copy(result[:], r) + return +} diff --git a/cryptography/crypto/keccak_test.go b/cryptography/crypto/keccak_test.go new file mode 100644 index 0000000..bc614e8 --- /dev/null +++ b/cryptography/crypto/keccak_test.go @@ -0,0 +1,57 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "testing" +import "encoding/hex" + +func TestKeccak256(t *testing.T) { + tests := []struct { + name string + messageHex string + wantHex string + }{ + { + name: "from monero 1", + messageHex: "c8fedd380dbae40ffb52", + wantHex: "8e41962058b7422e7404253121489a3e63d186ed115086919a75105661483ba9", + }, + { + name: "from monero 2", + messageHex: "5020c4d530b6ec6cb4d9", + wantHex: "8a597f11961935e32e0adeab2ce48b3df2d907c9b26619dad22f42ff65ab7593", + }, + { + name: "hello", + messageHex: "68656c6c6f", + wantHex: "1c8aff950685c2ed4bc3174f3472287b56d9517b9c948127319a09a7a36deac8", + }, + { + name: "from monero cryptotest.pl", + messageHex: "0f3fe9c20b24a11bf4d6d1acd335c6a80543f1f0380590d7323caf1390c78e88", + wantHex: "73b7a236f2a97c4e1805f7a319f1283e3276598567757186c526caf9a49e0a92", + }, + } + for _, test := range tests { + message, _ := hex.DecodeString(test.messageHex) + got := Keccak256(message) + want := HexToHash(test.wantHex) + if want != got { + t.Errorf("want %x, got %x", want, got) + } + } +} diff --git a/cryptography/crypto/key_old.go b/cryptography/crypto/key_old.go new file mode 100644 index 0000000..d4ab96c --- /dev/null +++ b/cryptography/crypto/key_old.go @@ -0,0 +1,70 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" +import "encoding/hex" + +const KeyLength = 32 + +// Key can be a Scalar or a Point +type Key [KeyLength]byte + +func (k Key) MarshalText() ([]byte, error) { + return []byte(fmt.Sprintf("%x", k[:])), nil +} + +func (k *Key) UnmarshalText(data []byte) (err error) { + byteSlice, _ := hex.DecodeString(string(data)) + if len(byteSlice) != 32 { + return fmt.Errorf("Incorrect key size") + } + copy(k[:], byteSlice) + return +} + +func (k Key) String() string { + return fmt.Sprintf("%x", k[:]) +} + +func (p *Key) FromBytes(b [KeyLength]byte) { + *p = b +} + +func (p *Key) ToBytes() (result [KeyLength]byte) { + result = [KeyLength]byte(*p) + return +} + +// convert a hex string to a key +func HexToKey(h string) (result Key) { + byteSlice, _ := hex.DecodeString(h) + if len(byteSlice) != 32 { + panic("Incorrect key size") + } + copy(result[:], byteSlice) + return +} + +func HexToHash(h string) (result Hash) { + byteSlice, _ := hex.DecodeString(h) + if len(byteSlice) != 32 { + panic("Incorrect key size") + } + copy(result[:], byteSlice) + return +} diff --git a/cryptography/crypto/polynomial.go b/cryptography/crypto/polynomial.go new file mode 100644 index 0000000..ae99c28 --- /dev/null +++ b/cryptography/crypto/polynomial.go @@ -0,0 +1,91 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "fmt" +import "math/big" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" + +type Polynomial struct { + coefficients []*big.Int +} + +func NewPolynomial(input []*big.Int) *Polynomial { + if input == nil { + return &Polynomial{coefficients: []*big.Int{new(big.Int).SetInt64(1)}} + } + return &Polynomial{coefficients: input} +} + +func (p *Polynomial) Length() int { + return len(p.coefficients) +} + +func (p *Polynomial) Mul(m *Polynomial) *Polynomial { + var product []*big.Int + for i := range p.coefficients { + product = append(product, new(big.Int).Mod(new(big.Int).Mul(p.coefficients[i], m.coefficients[0]), bn256.Order)) + } + product = append(product, new(big.Int)) // add 0 element + + if m.coefficients[1].IsInt64() && m.coefficients[1].Int64() == 1 { + for i := range product { + if i > 0 { + tmp := new(big.Int).Add(product[i], p.coefficients[i-1]) + + product[i] = new(big.Int).Mod(tmp, bn256.Order) + + } else { // do nothing + + } + } + } + return NewPolynomial(product) +} + +type dummy struct { + list [][]*big.Int +} + +func RecursivePolynomials(list [][]*big.Int, accum *Polynomial, a, b []*big.Int) (rlist [][]*big.Int) { + var d dummy + d.recursivePolynomialsinternal(accum, a, b) + + return d.list +} + +func (d *dummy) recursivePolynomialsinternal(accum *Polynomial, a, b []*big.Int) { + if len(a) == 0 { + d.list = append(d.list, accum.coefficients) + return + } + + atop := a[len(a)-1] + btop := b[len(b)-1] + + left := NewPolynomial([]*big.Int{new(big.Int).Mod(new(big.Int).Neg(atop), bn256.Order), new(big.Int).Mod(new(big.Int).Sub(new(big.Int).SetInt64(1), btop), bn256.Order)}) + right := NewPolynomial([]*big.Int{atop, btop}) + + d.recursivePolynomialsinternal(accum.Mul(left), a[:len(a)-1], b[:len(b)-1]) + d.recursivePolynomialsinternal(accum.Mul(right), a[:len(a)-1], b[:len(b)-1]) +} diff --git a/cryptography/crypto/proof_generate.go b/cryptography/crypto/proof_generate.go new file mode 100644 index 0000000..e37d572 --- /dev/null +++ b/cryptography/crypto/proof_generate.go @@ -0,0 +1,1206 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "fmt" +import "math" +import "math/big" +import "bytes" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" + +//import "github.com/kubernetes/klog" + +type Proof struct { + BA *bn256.G1 + BS *bn256.G1 + A *bn256.G1 + B *bn256.G1 + + CLnG, CRnG, C_0G, DG, y_0G, gG, C_XG, y_XG []*bn256.G1 + + u *bn256.G1 + + f *FieldVector + + z_A *big.Int + + T_1 *bn256.G1 + T_2 *bn256.G1 + + that *big.Int + mu *big.Int + + c *big.Int + s_sk, s_r, s_b, s_tau *big.Int + + ip *InnerProduct +} + +type IPStatement struct { + PrimeBase *GeneratorParams + P *bn256.G1 +} + +type IPWitness struct { + L *FieldVector + R *FieldVector +} + +// this is based on roothash and user's secret key and thus is the basis of protection from a number of double spending attacks +func (p *Proof) Nonce() Hash { + return Keccak256(p.u.EncodeCompressed()) +} + +func (p *Proof) Serialize(w *bytes.Buffer) { + if p == nil { + return + } + w.Write(p.BA.EncodeCompressed()) + w.Write(p.BS.EncodeCompressed()) + w.Write(p.A.EncodeCompressed()) + w.Write(p.B.EncodeCompressed()) + + //w.WriteByte(byte(len(p.CLnG))) // we can skip this byte also, why not skip it + + // fmt.Printf("CLnG byte %d\n",len(p.CLnG)) + for i := 0; i < len(p.CLnG); i++ { + w.Write(p.CLnG[i].EncodeCompressed()) + w.Write(p.CRnG[i].EncodeCompressed()) + w.Write(p.C_0G[i].EncodeCompressed()) + w.Write(p.DG[i].EncodeCompressed()) + w.Write(p.y_0G[i].EncodeCompressed()) + w.Write(p.gG[i].EncodeCompressed()) + w.Write(p.C_XG[i].EncodeCompressed()) + w.Write(p.y_XG[i].EncodeCompressed()) + } + + w.Write(p.u.EncodeCompressed()) + + if len(p.CLnG) != len(p.f.vector) { + /// panic(fmt.Sprintf("different size %d %d", len(p.CLnG), len(p.f.vector))) + } + + /*if len(p.f.vector) != 2 { + panic(fmt.Sprintf("f could not be serialized length %d", len(p.CLnG), len(p.f.vector))) + } + */ + + // fmt.Printf("writing %d fvector points\n", len(p.f.vector)); + for i := 0; i < len(p.f.vector); i++ { + w.Write(ConvertBigIntToByte(p.f.vector[i])) + } + + w.Write(ConvertBigIntToByte(p.z_A)) + + w.Write(p.T_1.EncodeCompressed()) + w.Write(p.T_2.EncodeCompressed()) + + w.Write(ConvertBigIntToByte(p.that)) + w.Write(ConvertBigIntToByte(p.mu)) + + w.Write(ConvertBigIntToByte(p.c)) + w.Write(ConvertBigIntToByte(p.s_sk)) + w.Write(ConvertBigIntToByte(p.s_r)) + w.Write(ConvertBigIntToByte(p.s_b)) + w.Write(ConvertBigIntToByte(p.s_tau)) + + p.ip.Serialize(w) + +} + +func (proof *Proof) Deserialize(r *bytes.Reader, length int) error { + + var buf [32]byte + var bufp [33]byte + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.BA = &p + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.BS = &p + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.A = &p + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.B = &p + } else { + return err + } + + proof.CLnG = proof.CLnG[:0] + proof.CRnG = proof.CRnG[:0] + proof.C_0G = proof.C_0G[:0] + proof.DG = proof.DG[:0] + proof.y_0G = proof.y_0G[:0] + proof.gG = proof.gG[:0] + proof.C_XG = proof.C_XG[:0] + proof.y_XG = proof.y_XG[:0] + + for i := 0; i < length; i++ { + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.CLnG = append(proof.CLnG, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + //fmt.Printf("CRnG point bytes2 %x\n", bufp[:]) + if err = p.DecodeCompressed(bufp[:]); err != nil { + //fmt.Printf("CRng point bytes1 %x\n", bufp[:]) + return err + } + proof.CRnG = append(proof.CRnG, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.C_0G = append(proof.C_0G, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.DG = append(proof.DG, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.y_0G = append(proof.y_0G, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.gG = append(proof.gG, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.C_XG = append(proof.C_XG, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.y_XG = append(proof.y_XG, &p) + } else { + return err + } + + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.u = &p + } else { + return err + } + + proof.f = &FieldVector{} + + //fmt.Printf("flen %d\n", flen ) + for j := 0; j < length*2; j++ { + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.f.vector = append(proof.f.vector, new(big.Int).SetBytes(buf[:])) + } else { + return err + } + + } + + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.z_A = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.T_1 = &p + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + proof.T_2 = &p + } else { + return err + } + + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.that = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.mu = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.c = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.s_sk = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.s_r = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.s_b = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + if n, err := r.Read(buf[:]); n == 32 && err == nil { + proof.s_tau = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + proof.ip = &InnerProduct{} + + return proof.ip.Deserialize(r) + +} + +/* +// statement hash +func (s *Statement) Hash() *big.Int { + var input []byte + for i := range s.CLn { + input = append(input, s.CLn[i].Marshal()...) + } + for i := range s.CRn { + input = append(input, s.CRn[i].Marshal()...) + } + for i := range s.C { + input = append(input, s.C[i].Marshal()...) + } + input = append(input, s.D.Marshal()...) + for i := range s.Publickeylist { + input = append(input, s.Publickeylist[i].Marshal()...) + } + input = append(input, s.Roothash[:]...) + + return reducedhash(input) +} +*/ + +func (p *Proof) Size() int { + size := 4*POINT_SIZE + (len(p.CLnG)+len(p.CRnG)+len(p.C_0G)+len(p.DG)+len(p.y_0G)+len(p.gG)+len(p.C_XG)+len(p.y_XG))*POINT_SIZE + size += POINT_SIZE + size += len(p.f.vector) * FIELDELEMENT_SIZE + size += FIELDELEMENT_SIZE + size += 2 * POINT_SIZE // T_1 ,T_2 + size += 7 * FIELDELEMENT_SIZE + size += p.ip.Size() + return size +} + +func (proof *Proof) hashmash1(v *big.Int) *big.Int { + var input []byte + input = append(input, ConvertBigIntToByte(v)...) + for i := range proof.CLnG { + input = append(input, proof.CLnG[i].Marshal()...) + } + for i := range proof.CRnG { + input = append(input, proof.CRnG[i].Marshal()...) + } + for i := range proof.C_0G { + input = append(input, proof.C_0G[i].Marshal()...) + } + for i := range proof.DG { + input = append(input, proof.DG[i].Marshal()...) + } + for i := range proof.y_0G { + input = append(input, proof.y_0G[i].Marshal()...) + } + for i := range proof.gG { + input = append(input, proof.gG[i].Marshal()...) + } + for i := range proof.C_XG { + input = append(input, proof.C_XG[i].Marshal()...) + } + for i := range proof.y_XG { + input = append(input, proof.y_XG[i].Marshal()...) + } + return reducedhash(input) +} + +// function, which takes a string as +// argument and return the reverse of string. +func reverse(s string) string { + rns := []rune(s) // convert to rune + for i, j := 0, len(rns)-1; i < j; i, j = i+1, j-1 { + + // swap the letters of the string, + // like first with last and so on. + rns[i], rns[j] = rns[j], rns[i] + } + + // return the reversed string. + return string(rns) +} + +var params = NewGeneratorParams(128) // these can be pregenerated similarly as in DERO project + +func GenerateProof(s *Statement, witness *Witness, u *bn256.G1, txid Hash, burn_value uint64) *Proof { + + var proof Proof + proof.u = u + + statementhash := reducedhash(txid[:]) + + // statement should be constructed from these, however these are being simplified + var C []*ElGamal + var Cn ElGamalVector + for i := range s.C { + C = append(C, ConstructElGamal(s.C[i], s.D)) + Cn.vector = append(Cn.vector, ConstructElGamal(s.CLn[i], s.CRn[i])) + } + + btransfer := new(big.Int).SetInt64(int64(witness.TransferAmount)) // this should be reduced + bdiff := new(big.Int).SetInt64(int64(witness.Balance)) // this should be reduced + + number := btransfer.Add(btransfer, bdiff.Lsh(bdiff, 64)) // we are placing balance and left over balance, and doing a range proof of 128 bits + + number_string := reverse("0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000" + number.Text(2)) + number_string_left_128bits := string(number_string[0:128]) + + var aL, aR FieldVector // convert the amount to make sure it cannot be negative + + //klog.V(2).Infof("reverse %s\n", number_string_left_128bits) + for _, b := range []byte(number_string_left_128bits) { + if b == '1' { + aL.vector = append(aL.vector, new(big.Int).SetInt64(1)) + aR.vector = append(aR.vector, new(big.Int).SetInt64(0)) + } else { + aL.vector = append(aL.vector, new(big.Int).SetInt64(0)) + aR.vector = append(aR.vector, new(big.Int).Mod(new(big.Int).SetInt64(-1), bn256.Order)) + } + } + + //klog.V(2).Infof("aRa %+v\n", aRa) + + proof_BA_internal := NewPedersenVectorCommitment().Commit(&aL, &aR) + proof.BA = proof_BA_internal.Result + + sL := NewFieldVectorRandomFilled(len(aL.vector)) + sR := NewFieldVectorRandomFilled(len(aL.vector)) + proof_BS_internal := NewPedersenVectorCommitment().Commit(sL, sR) + proof.BS = proof_BS_internal.Result + + //klog.V(2).Infof("Proof BA %s\n", proof.BA.String()) + //klog.V(2).Infof("Proof BS %s\n", proof.BS.String()) + + if len(s.Publickeylist) >= 1 && len(s.Publickeylist)&(len(s.Publickeylist)-1) != 0 { + fmt.Printf("len of Publickeylist %d\n", len(s.Publickeylist)) + panic("we need power of 2") + } + + N := len(s.Publickeylist) + m := int(math.Log2(float64(N))) + + if math.Pow(2, float64(m)) != float64(N) { + panic("log failed") + } + + var aa, ba, bspecial []*big.Int + for i := 0; i < 2*m; i++ { + aa = append(aa, RandomScalarFixed()) + } + + witness_index := reverse(fmt.Sprintf("%0"+fmt.Sprintf("%db", m)+"%0"+fmt.Sprintf("%db", m), witness.Index[1], witness.Index[0])) + + for _, b := range []byte(witness_index) { + if b == '1' { + ba = append(ba, new(big.Int).SetUint64(1)) + bspecial = append(bspecial, new(big.Int).Mod(new(big.Int).SetInt64(-1), bn256.Order)) + } else { + ba = append(ba, new(big.Int).SetUint64(0)) + bspecial = append(bspecial, new(big.Int).Mod(new(big.Int).SetInt64(1), bn256.Order)) + } + } + + a := NewFieldVector(aa) + b := NewFieldVector(ba) + + // klog.V(1).Infof("witness_index of sender/receiver %s\n", witness_index) + + c := a.Hadamard(NewFieldVector(bspecial)) + d := a.Hadamard(a).Negate() + + // klog.V(2).Infof("d %s\n", d.vector[0].Text(16)) + + e := NewFieldVector([]*big.Int{new(big.Int).Mod(new(big.Int).Mul(a.vector[0], a.vector[m]), bn256.Order), + new(big.Int).Mod(new(big.Int).Mul(a.vector[0], a.vector[m]), bn256.Order)}) + + second := new(big.Int).Set(a.vector[b.vector[m].Uint64()*uint64(m)]) + second.Neg(second) + + f := NewFieldVector([]*big.Int{a.vector[b.vector[0].Uint64()*uint64(m)], new(big.Int).Mod(second, bn256.Order)}) + + // for i := range f.vector { + // klog.V(2).Infof("f %d %s\n", i, f.vector[i].Text(16)) + // } + + proof_A_internal := NewPedersenVectorCommitment().Commit(a, d.Concat(e)) + proof.A = proof_A_internal.Result + proof_B_internal := NewPedersenVectorCommitment().Commit(b, c.Concat(f)) + proof.B = proof_B_internal.Result + + // klog.V(2).Infof("Proof A %s\n", proof.A.String()) + // klog.V(2).Infof("Proof B %s\n", proof.B.String()) + + var v *big.Int + + { // hash mash + var input []byte + input = append(input, ConvertBigIntToByte(statementhash)...) + input = append(input, proof.BA.Marshal()...) + input = append(input, proof.BS.Marshal()...) + input = append(input, proof.A.Marshal()...) + input = append(input, proof.B.Marshal()...) + v = reducedhash(input) + } + + var P, Q, Pi, Qi [][]*big.Int + Pi = RecursivePolynomials(Pi, NewPolynomial(nil), a.SliceRaw(0, m), b.SliceRaw(0, m)) + Qi = RecursivePolynomials(Qi, NewPolynomial(nil), a.SliceRaw(m, 2*m), b.SliceRaw(m, 2*m)) + + // transpose the matrices + for i := 0; i < m; i++ { + P = append(P, []*big.Int{}) + Q = append(Q, []*big.Int{}) + for j := range Pi { + P[i] = append(P[i], Pi[j][i]) + Q[i] = append(Q[i], Qi[j][i]) + } + } + + // for i := range P { + // for j := range P[i] { + // klog.V(2).Infof("P%d,%d %s\n", i, j, P[i][j].Text(16)) + // } + // } + + //phi := NewFieldVectorRandomFilled(m) + //chi := NewFieldVectorRandomFilled(m) + //psi := NewFieldVectorRandomFilled(m) + + var phi, chi, psi ElGamalVector + for i := 0; i < m; i++ { + phi.vector = append(phi.vector, CommitElGamal(s.Publickeylist[witness.Index[0]], new(big.Int).SetUint64(0))) + chi.vector = append(chi.vector, CommitElGamal(s.Publickeylist[witness.Index[0]], new(big.Int).SetUint64(0))) + psi.vector = append(psi.vector, CommitElGamal(s.Publickeylist[witness.Index[0]], new(big.Int).SetUint64(0))) + } + + var CnG, C_0G, y_0G ElGamalVector + for i := 0; i < m; i++ { + + CnG.vector = append(CnG.vector, Cn.MultiExponentiate(NewFieldVector(P[i])).Add(phi.vector[i])) + + { + var pvector PointVector + for j := range C { + pvector.vector = append(pvector.vector, C[j].Left) + } + left := pvector.MultiExponentiate(NewFieldVector(P[i])) //.Add(chi.vector[i].Left) + left = new(bn256.G1).Add(new(bn256.G1).Set(left), chi.vector[i].Left) + C_0G.vector = append(C_0G.vector, ConstructElGamal(left, chi.vector[i].Right)) + } + + { + + left := NewPointVector(s.Publickeylist).MultiExponentiate(NewFieldVector(P[i])) + left = new(bn256.G1).Add(new(bn256.G1).Set(left), psi.vector[i].Left) + y_0G.vector = append(y_0G.vector, ConstructElGamal(left, psi.vector[i].Right)) + } + + /* + { // y_0G + var rightp, result bn256.G1 + leftp := NewPointVector(s.Publickeylist).Commit(P[i]) + rightp.ScalarMult(s.Publickeylist[witness.Index[0]], psi.vector[i]) + result.Add(leftp, &rightp) + proof.y_0G = append(proof.y_0G, &result) + //klog.V(2).Infof("y_0G %d %s\n",i, result.String()) + } + + { // gG + var result bn256.G1 + result.ScalarMult(params.G, psi.vector[i]) + proof.gG = append(proof.gG, &result) + //klog.V(2).Infof("gG %d %s\n",i, result.String()) + } + */ + + /* + { // C_XG + var result bn256.G1 + result.ScalarMult(s.D, omega.vector[i]) + proof.C_XG = append(proof.C_XG, &result) + //klog.V(2).Infof("C_XG %d %s\n",i, result.String()) + } + + { // y_XG + var result bn256.G1 + result.ScalarMult(params.G, omega.vector[i]) + proof.y_XG = append(proof.y_XG, &result) + klog.V(2).Infof("y_XG %d %s\n", i, result.String()) + } + */ + + } + + /* + for i := range proof.CLnG { + klog.V(2).Infof("CLnG %d %s\n", i, proof.CLnG[i].String()) + } + for i := range proof.CRnG { + klog.V(2).Infof("CRnG %d %s\n", i, proof.CRnG[i].String()) + } + for i := range proof.C_0G { + klog.V(2).Infof("C_0G %d %s\n", i, proof.C_0G[i].String()) + } + for i := range proof.DG { + klog.V(2).Infof("DG %d %s\n", i, proof.DG[i].String()) + } + for i := range proof.y_0G { + klog.V(2).Infof("y_0G %d %s\n", i, proof.y_0G[i].String()) + } + for i := range proof.gG { + klog.V(2).Infof("gG %d %s\n", i, proof.gG[i].String()) + } + for i := range proof.C_XG { + klog.V(2).Infof("C_XG %d %s\n", i, proof.C_XG[i].String()) + } + for i := range proof.y_XG { + klog.V(2).Infof("y_XG %d %s\n", i, proof.y_XG[i].String()) + } + */ + var C_XG []*ElGamal + for i := 0; i < m; i++ { + C_XG = append(C_XG, CommitElGamal(C[0].Right, new(big.Int).SetUint64(0))) + } + + vPow := new(big.Int).SetInt64(1) // doesn't need reduction, since it' alredy reduced + + for i := 0; i < N; i++ { + + var poly [][]*big.Int + if i%2 == 0 { + poly = P + } else { + poly = Q + } + + // klog.V(2).Infof("\n\n") + // for i := range proof.C_XG { + // klog.V(2).Infof("C_XG before %d %s\n", i, proof.C_XG[i].String()) + // } + + // klog.V(2).Infof("loop %d pos in poly sender %d receiver %d\n", i, (witness.Index[0]+N-(i-i%2))%N, (witness.Index[1]+N-(i-i%2))%N) + + for j := range C_XG { + + amount := new(big.Int).SetUint64(uint64(witness.TransferAmount)) + amount_neg := new(big.Int).Neg(amount) + amount_fees := new(big.Int).SetUint64(s.Fees + burn_value) + left := new(big.Int).Sub(amount_neg, amount_fees) + left = new(big.Int).Mod(new(big.Int).Mul(new(big.Int).Set(left), poly[j][(witness.Index[0]+N-(i-i%2))%N]), bn256.Order) + + right := new(big.Int).Mod(new(big.Int).Mul(new(big.Int).Set(amount), poly[j][(witness.Index[1]+N-(i-i%2))%N]), bn256.Order) + + joined := new(big.Int).Mod(new(big.Int).Add(left, right), bn256.Order) + + mul := new(big.Int).Mod(new(big.Int).Mul(vPow, joined), bn256.Order) + + C_XG[j] = C_XG[j].Plus(mul) + } + + if i != 0 { + vPow.Mul(vPow, v) + vPow.Mod(vPow, bn256.Order) + } + + //klog.V(2).Infof("vPow %d %s\n", i, vPow.Text(16))) + + } + + for i := range C_XG { + proof.C_XG = append(proof.C_XG, C_XG[i].Left) + proof.y_XG = append(proof.y_XG, C_XG[i].Right) + + proof.CLnG = append(proof.CLnG, CnG.vector[i].Left) + proof.CRnG = append(proof.CRnG, CnG.vector[i].Right) + + proof.C_0G = append(proof.C_0G, C_0G.vector[i].Left) + proof.DG = append(proof.DG, C_0G.vector[i].Right) + + proof.y_0G = append(proof.y_0G, y_0G.vector[i].Left) + proof.gG = append(proof.gG, y_0G.vector[i].Right) + } + + //klog.V(2).Infof("\n\n") + // for i := range proof.C_XG { + // klog.V(2).Infof("C_XG after %d %s\n", i, proof.C_XG[i].String()) + // } + + // calculate w hashmash + + w := proof.hashmash1(v) + + { + var input []byte + + input = append(input, ConvertBigIntToByte(v)...) + for i := range proof.CLnG { + input = append(input, proof.CLnG[i].Marshal()...) + } + for i := range proof.CRnG { + input = append(input, proof.CRnG[i].Marshal()...) + } + + for i := range proof.C_0G { + input = append(input, proof.C_0G[i].Marshal()...) + } + for i := range proof.DG { + input = append(input, proof.DG[i].Marshal()...) + } + for i := range proof.y_0G { + input = append(input, proof.y_0G[i].Marshal()...) + } + for i := range proof.gG { + input = append(input, proof.gG[i].Marshal()...) + } + for i := range C_XG { + input = append(input, C_XG[i].Left.Marshal()...) + } + for i := range proof.y_XG { + input = append(input, C_XG[i].Right.Marshal()...) + } + //fmt.Printf("whash %s %s\n", reducedhash(input).Text(16), w.Text(16)) + + } + + proof.f = b.Times(w).Add(a) + + // for i := range proof.f.vector { + // klog.V(2).Infof("proof.f %d %s\n", i, proof.f.vector[i].Text(16)) + // } + + ttttt := new(big.Int).Mod(new(big.Int).Mul(proof_B_internal.Randomness, w), bn256.Order) + proof.z_A = new(big.Int).Mod(new(big.Int).Add(ttttt, proof_A_internal.Randomness), bn256.Order) + + // klog.V(2).Infof("proofz_A %s\n", proof.z_A.Text(16)) + + y := reducedhash(ConvertBigIntToByte(w)) + + // klog.V(2).Infof("yyyyyyyyyy %s\n", y.Text(16)) + + ys_raw := []*big.Int{new(big.Int).SetUint64(1)} + for i := 1; i < 128; i++ { + var tt big.Int + tt.Mul(ys_raw[len(ys_raw)-1], y) + tt.Mod(&tt, bn256.Order) + ys_raw = append(ys_raw, &tt) + } + ys := NewFieldVector(ys_raw) + + z := reducedhash(ConvertBigIntToByte(y)) + // klog.V(2).Infof("zzzzzzzzzz %s \n", z.Text(16)) + + zs := []*big.Int{new(big.Int).Exp(z, new(big.Int).SetUint64(2), bn256.Order), new(big.Int).Exp(z, new(big.Int).SetUint64(3), bn256.Order)} + // for i := range zs { + // klog.V(2).Infof("zs %d %s\n", i, zs[i].Text(16)) + // } + + twos := []*big.Int{new(big.Int).SetUint64(1)} + for i := 1; i < 64; i++ { + var tt big.Int + tt.Mul(twos[len(twos)-1], new(big.Int).SetUint64(2)) + tt.Mod(&tt, bn256.Order) + twos = append(twos, &tt) + } + + twoTimesZs := []*big.Int{} + for i := 0; i < 2; i++ { + for j := 0; j < 64; j++ { + var tt big.Int + tt.Mul(zs[i], twos[j]) + tt.Mod(&tt, bn256.Order) + twoTimesZs = append(twoTimesZs, &tt) + + // klog.V(2).Infof("twoTimesZssss ============= %d %s\n", i*32+j, twoTimesZs[i*32+j].Text(16)) + + } + } + + tmp := aL.AddConstant(new(big.Int).Mod(new(big.Int).Neg(z), bn256.Order)) + lPoly := NewFieldVectorPolynomial(tmp, sL) + //for i := range lPoly.coefficients { + // for j := range lPoly.coefficients[i].vector { + // klog.V(2).Infof("lPoly %d,%d %s\n", i, j, lPoly.coefficients[i].vector[j].Text(16)) + // } + //} + + rPoly := NewFieldVectorPolynomial(ys.Hadamard(aR.AddConstant(z)).Add(NewFieldVector(twoTimesZs)), sR.Hadamard(ys)) + //for i := range rPoly.coefficients { + // for j := range rPoly.coefficients[i].vector { + // klog.V(2).Infof("rPoly %d,%d %s\n", i, j, rPoly.coefficients[i].vector[j].Text(16)) + // } + //} + + tPolyCoefficients := lPoly.InnerProduct(rPoly) // just an array of BN Reds... should be length 3 + //for j := range tPolyCoefficients { + // klog.V(2).Infof("tPolyCoefficients %d,%d %s\n", 0, j, tPolyCoefficients[j].Text(16)) + //} + + proof_T1 := NewPedersenCommitmentNew().Commit(tPolyCoefficients[1]) + proof_T2 := NewPedersenCommitmentNew().Commit(tPolyCoefficients[2]) + proof.T_1 = proof_T1.Result + proof.T_2 = proof_T2.Result + + //polyCommitment := NewPolyCommitment(params, tPolyCoefficients) + /*proof.tCommits = NewPointVector(polyCommitment.GetCommitments()) + + for j := range proof.tCommits.vector { + klog.V(2).Infof("tCommits %d %s\n", j, proof.tCommits.vector[j].String()) + } + */ + + x := new(big.Int) + + { + var input []byte + input = append(input, ConvertBigIntToByte(z)...) // tie intermediates/commit + //for j := range proof.tCommits.vector { + // input = append(input, proof.tCommits.vector[j].Marshal()...) + //} + input = append(input, proof_T1.Result.Marshal()...) + input = append(input, proof_T2.Result.Marshal()...) + x = reducedhash(input) + } + + //klog.V(2).Infof("x %s\n", x.Text(16)) + + //evalCommit := polyCommitment.Evaluate(x) + + //klog.V(2).Infof("evalCommit.X %s\n", j, evalCommit.X.Text(16)) + //klog.V(2).Infof("evalCommit.R %s\n", j, evalCommit.R.Text(16)) + + //proof.that = evalCommit.X + + xsquare := new(big.Int).Mod(new(big.Int).Mul(x, x), bn256.Order) + + proof.that = tPolyCoefficients[0] + proof.that = new(big.Int).Mod(new(big.Int).Add(proof.that, new(big.Int).Mod(new(big.Int).Mul(tPolyCoefficients[1], x), bn256.Order)), bn256.Order) + proof.that = new(big.Int).Mod(new(big.Int).Add(proof.that, new(big.Int).Mod(new(big.Int).Mul(tPolyCoefficients[2], xsquare), bn256.Order)), bn256.Order) + + /* + accumulator := new(big.Int).Set(x) + for i := 1; i < 3; i++ { + tmp := new(big.Int).Set(accumulator) + proof.that = proof.that.Add(new(bn256.G1).Set(proof.that), tPolyCoefficients[i].Times(accumulator)) + accumulator.Mod(new(big.Int).Mul(tmp, x), bn256.Order) + } + */ + + //klog.V(2).Infof("evalCommit.that %s\n", proof.that.Text(16)) + + //tauX := evalCommit.R + tauX_left := new(big.Int).Mod(new(big.Int).Mul(proof_T1.Randomness, x), bn256.Order) + tauX_right := new(big.Int).Mod(new(big.Int).Mul(proof_T2.Randomness, xsquare), bn256.Order) + tauX := new(big.Int).Mod(new(big.Int).Add(tauX_left, tauX_right), bn256.Order) + + proof.mu = new(big.Int).Mod(new(big.Int).Mul(proof_BS_internal.Randomness, x), bn256.Order) + proof.mu.Add(proof.mu, proof_BA_internal.Randomness) + proof.mu.Mod(proof.mu, bn256.Order) + + //klog.V(2).Infof("proof.mu %s\n", proof.mu.Text(16)) + + var CrnR, y_0R, y_XR bn256.G1 + // var gR bn256.G1 + CrnR.ScalarMult(params.G, new(big.Int)) + y_0R.ScalarMult(params.G, new(big.Int)) + y_XR.ScalarMult(params.G, new(big.Int)) + //DR.ScalarMult(params.G, new(big.Int)) + //gR.ScalarMult(params.G, new(big.Int)) + + CnR := ConstructElGamal(nil, ElGamal_ZERO) // only right side is needer + chi_bigint := new(big.Int).SetUint64(0) + psi_bigint := new(big.Int).SetUint64(0) + C_XR := ConstructElGamal(nil, ElGamal_ZERO) // only right side is needer + + var p_, q_ []*big.Int + for i := 0; i < N; i++ { + p_ = append(p_, new(big.Int)) + q_ = append(q_, new(big.Int)) + } + p := NewFieldVector(p_) + q := NewFieldVector(q_) + + wPow := new(big.Int).SetUint64(1) // already reduced + + for i := 0; i < m; i++ { + + { + CnR = CnR.Add(phi.vector[i].Neg().Mul(wPow)) + } + + { + mm := new(big.Int).Mod(new(big.Int).Mul(chi.vector[i].Randomness, wPow), bn256.Order) + chi_bigint = new(big.Int).Mod(new(big.Int).Add(chi_bigint, mm), bn256.Order) + } + + { + mm := new(big.Int).Mod(new(big.Int).Mul(psi.vector[i].Randomness, wPow), bn256.Order) + psi_bigint = new(big.Int).Mod(new(big.Int).Add(psi_bigint, mm), bn256.Order) + } + + /* { + tmp := new(bn256.G1) + mm := new(big.Int).Mod(new(big.Int).Neg(chi.vector[i]), bn256.Order) + mm = mm.Mod(new(big.Int).Mul(mm, wPow), bn256.Order) + tmp.ScalarMult(params.G, mm) + DR.Add(new(bn256.G1).Set(&DR), tmp) + } + + { + tmp := new(bn256.G1) + mm := new(big.Int).Mod(new(big.Int).Neg(psi.vector[i]), bn256.Order) + mm = mm.Mod(new(big.Int).Mul(mm, wPow), bn256.Order) + tmp.ScalarMult(s.Publickeylist[witness.Index[0]], mm) + y_0R.Add(new(bn256.G1).Set(&y_0R), tmp) + } + */ + /* + { + tmp := new(bn256.G1) + mm := new(big.Int).Mod(new(big.Int).Neg(psi.vector[i]), bn256.Order) + mm = mm.Mod(new(big.Int).Mul(mm, wPow), bn256.Order) + tmp.ScalarMult(params.G, mm) + gR.Add(new(bn256.G1).Set(&gR), tmp) + } + + { + tmp := new(bn256.G1) + tmp.ScalarMult(proof.y_XG[i], new(big.Int).Neg(wPow)) + y_XR.Add(new(bn256.G1).Set(&y_XR), tmp) + } + */ + + { + C_XR = C_XR.Add(C_XG[i].Neg().Mul(wPow)) + } + + //fmt.Printf("y_XG[%d] %s\n",i, proof.y_XG[i].String()) + //fmt.Printf("C_XG[%d] %s\n",i, C_XG[i].Right.String()) + + //fmt.Printf("G %s\n",G.String()) + //fmt.Printf("elgamalG %s\n",C_XG[0].G.String()) + + p = p.Add(NewFieldVector(P[i]).Times(wPow)) + q = q.Add(NewFieldVector(Q[i]).Times(wPow)) + wPow = new(big.Int).Mod(new(big.Int).Mul(wPow, w), bn256.Order) + + // klog.V(2).Infof("wPow %s\n", wPow.Text(16)) + + } + + CnR = CnR.Add(Cn.vector[witness.Index[0]].Mul(wPow)) + + //for i := range CnR{ + // proof.CLnG = append(proof.CLnG, CnR[i].Left) + // proof.CRnG = append(proof.CRnG, CnR[i].Right) + //} + + //CrnR.Add(new(bn256.G1).Set(&CrnR), new(bn256.G1).ScalarMult(s.CRn[witness.Index[0]], wPow)) + //y_0R.Add(new(bn256.G1).Set(&y_0R), new(bn256.G1).ScalarMult(s.Publickeylist[witness.Index[0]], wPow)) + //DR.Add(new(bn256.G1).Set(&DR), new(bn256.G1).ScalarMult(s.D, wPow)) + + DR := new(bn256.G1).ScalarMult(C[0].Right, wPow) + DR = new(bn256.G1).Add(new(bn256.G1).Set(DR), new(bn256.G1).ScalarMult(global_pedersen_values.G, new(big.Int).Mod(new(big.Int).Neg(chi_bigint), bn256.Order))) + + gR := new(bn256.G1).ScalarMult(global_pedersen_values.G, new(big.Int).Mod(new(big.Int).Sub(wPow, psi_bigint), bn256.Order)) + + //gR.Add(new(bn256.G1).Set(&gR), new(bn256.G1).ScalarMult(params.G, wPow)) + + var p__, q__ []*big.Int + for i := 0; i < N; i++ { + + if i == witness.Index[0] { + p__ = append(p__, new(big.Int).Set(wPow)) + } else { + p__ = append(p__, new(big.Int)) + } + + if i == witness.Index[1] { + q__ = append(q__, new(big.Int).Set(wPow)) + } else { + q__ = append(q__, new(big.Int)) + } + } + p = p.Add(NewFieldVector(p__)) + q = q.Add(NewFieldVector(q__)) + + // klog.V(2).Infof("CrnR %s\n", CrnR.String()) + // klog.V(2).Infof("DR %s\n", DR.String()) + // klog.V(2).Infof("y_0R %s\n", y_0R.String()) + // klog.V(2).Infof("gR %s\n", gR.String()) + // klog.V(2).Infof("y_XR %s\n", y_XR.String()) + + // for i := range p.vector { + // klog.V(2).Infof("p %d %s \n", i, p.vector[i].Text(16)) + // } + + // for i := range q.vector { + // klog.V(2).Infof("q %d %s \n", i, q.vector[i].Text(16)) + // } + + y_p := Convolution(p, NewPointVector(s.Publickeylist)) + y_q := Convolution(q, NewPointVector(s.Publickeylist)) + + // for i := range y_p.vector { + // klog.V(2).Infof("y_p %d %s \n", i, y_p.vector[i].String()) + // } + // for i := range y_q.vector { + // klog.V(2).Infof("y_q %d %s \n", i, y_q.vector[i].String()) + // } + + vPow = new(big.Int).SetUint64(1) // already reduced + for i := 0; i < N; i++ { + + ypoly := y_p + if i%2 == 1 { + ypoly = y_q + } + y_XR.Add(new(bn256.G1).Set(&y_XR), new(bn256.G1).ScalarMult(ypoly.vector[i/2], vPow)) + + C_XR = C_XR.Add(ConstructElGamal(nil, new(bn256.G1).ScalarMult(ypoly.vector[i/2], vPow))) + + //fmt.Printf("y_XR[%d] %s\n",i, y_XR.String()) + //fmt.Printf("C_XR[%d] %s\n",i, C_XR.Right.String()) + if i > 0 { + vPow = new(big.Int).Mod(new(big.Int).Mul(vPow, v), bn256.Order) + } + } + + // klog.V(2).Infof("y_XR %s\n", y_XR.String()) + // klog.V(2).Infof("vPow %s\n", vPow.Text(16)) + // klog.V(2).Infof("v %s\n", v.Text(16)) + + k_sk := RandomScalarFixed() + k_r := RandomScalarFixed() + k_b := RandomScalarFixed() + k_tau := RandomScalarFixed() + + A_y := new(bn256.G1).ScalarMult(gR, k_sk) + A_D := new(bn256.G1).ScalarMult(params.G, k_r) + A_b := new(bn256.G1).ScalarMult(params.G, k_b) + t1 := new(bn256.G1).ScalarMult(CnR.Right, zs[1]) + d1 := new(bn256.G1).ScalarMult(DR, new(big.Int).Mod(new(big.Int).Neg(zs[0]), bn256.Order)) + d1 = new(bn256.G1).Add(d1, t1) + d1 = new(bn256.G1).ScalarMult(d1, k_sk) + A_b = new(bn256.G1).Add(A_b, d1) + + A_X := new(bn256.G1).ScalarMult(C_XR.Right, k_r) + + A_t := new(bn256.G1).ScalarMult(params.G, new(big.Int).Mod(new(big.Int).Neg(k_b), bn256.Order)) + A_t = new(bn256.G1).Add(A_t, new(bn256.G1).ScalarMult(params.H, k_tau)) + + A_u := new(bn256.G1) + + { + var input []byte + input = append(input, []byte(PROTOCOL_CONSTANT)...) + input = append(input, s.Roothash[:]...) + + point := HashToPoint(HashtoNumber(input)) + + A_u = new(bn256.G1).ScalarMult(point, k_sk) + } + + // klog.V(2).Infof("A_y %s\n", A_y.String()) + // klog.V(2).Infof("A_D %s\n", A_D.String()) + // klog.V(2).Infof("A_b %s\n", A_b.String()) + // klog.V(2).Infof("A_X %s\n", A_X.String()) + // klog.V(2).Infof("A_t %s\n", A_t.String()) + // klog.V(2).Infof("A_u %s\n", A_u.String()) + + { + var input []byte + input = append(input, ConvertBigIntToByte(x)...) + input = append(input, A_y.Marshal()...) + input = append(input, A_D.Marshal()...) + input = append(input, A_b.Marshal()...) + input = append(input, A_X.Marshal()...) + input = append(input, A_t.Marshal()...) + input = append(input, A_u.Marshal()...) + proof.c = reducedhash(input) + } + + proof.s_sk = new(big.Int).Mod(new(big.Int).Mul(proof.c, witness.SecretKey), bn256.Order) + proof.s_sk = new(big.Int).Mod(new(big.Int).Add(proof.s_sk, k_sk), bn256.Order) + + proof.s_r = new(big.Int).Mod(new(big.Int).Mul(proof.c, witness.R), bn256.Order) + proof.s_r = new(big.Int).Mod(new(big.Int).Add(proof.s_r, k_r), bn256.Order) + + // proof_c_neg := new(big.Int).Mod(new(big.Int).Neg(proof.c), bn256.Order) + // dummyA_X := new(bn256.G1).ScalarMult(&y_XR, proof.s_r) //, new(bn256.G1).ScalarMult(anonsupport.C_XR, proof_c_neg) ) + + // klog.V(2).Infof("dummyA_X %s\n", dummyA_X.String()) + // klog.V(2).Infof("s_r %s\n", proof.s_r.Text(16)) + // klog.V(2).Infof("C %s\n", proof.c.Text(16)) + // klog.V(2).Infof("C_neg %s\n", proof_c_neg.Text(16)) + + w_transfer := new(big.Int).Mod(new(big.Int).Mul(new(big.Int).SetUint64(uint64(witness.TransferAmount)), zs[0]), bn256.Order) + w_balance := new(big.Int).Mod(new(big.Int).Mul(new(big.Int).SetUint64(uint64(witness.Balance)), zs[1]), bn256.Order) + w_tmp := new(big.Int).Mod(new(big.Int).Add(w_transfer, w_balance), bn256.Order) + w_tmp = new(big.Int).Mod(new(big.Int).Mul(w_tmp, wPow), bn256.Order) + w_tmp = new(big.Int).Mod(new(big.Int).Mul(w_tmp, proof.c), bn256.Order) + proof.s_b = new(big.Int).Mod(new(big.Int).Add(w_tmp, k_b), bn256.Order) + + proof.s_tau = new(big.Int).Mod(new(big.Int).Mul(tauX, wPow), bn256.Order) + proof.s_tau = new(big.Int).Mod(new(big.Int).Mul(proof.s_tau, proof.c), bn256.Order) + proof.s_tau = new(big.Int).Mod(new(big.Int).Add(proof.s_tau, k_tau), bn256.Order) + + // klog.V(2).Infof("proof.c %s\n", proof.c.Text(16)) + // klog.V(2).Infof("proof.s_sk %s\n", proof.s_sk.Text(16)) + // klog.V(2).Infof("proof.s_r %s\n", proof.s_r.Text(16)) + // klog.V(2).Infof("proof.s_b %s\n", proof.s_b.Text(16)) + // klog.V(2).Infof("proof.s_tau %s\n", proof.s_tau.Text(16)) + + o := reducedhash(ConvertBigIntToByte(proof.c)) + + pvector := NewPedersenVectorCommitment() + pvector.H = new(bn256.G1).ScalarMult(pvector.H, o) + pvector.Hs = pvector.Hs.Hadamard(ys.Invert().vector) + pvector.gvalues = lPoly.Evaluate(x) + pvector.hvalues = rPoly.Evaluate(x) + proof.ip = NewInnerProductProofNew(pvector, o) + /* + + u_x := new(bn256.G1).ScalarMult(params.G, o) + P1 = new(bn256.G1).Add(P1, new(bn256.G1).ScalarMult(u_x, proof.that)) + klog.V(2).Infof("o %s\n", o.Text(16)) + klog.V(2).Infof("x %s\n", x.Text(16)) + klog.V(2).Infof("u_x %s\n", u_x.String()) + klog.V(2).Infof("p %s\n", P1.String()) + klog.V(2).Infof("hPrimes length %d\n", len(hPrimes.vector)) + + primebase := NewGeneratorParams3(u_x, params.Gs, hPrimes) // trigger sigma protocol + ipstatement := &IPStatement{PrimeBase: primebase, P: P1} + ipwitness := &IPWitness{L: lPoly.Evaluate(x), R: rPoly.Evaluate(x)} + + for i := range ipwitness.L.vector { + klog.V(2).Infof("L %d %s \n", i, ipwitness.L.vector[i].Text(16)) + } + + for i := range ipwitness.R.vector { + klog.V(2).Infof("R %d %s \n", i, ipwitness.R.vector[i].Text(16)) + } + + proof.ip = NewInnerProductProof(ipstatement, ipwitness, o) + */ + + return &proof + +} diff --git a/cryptography/crypto/proof_innerproduct.go b/cryptography/crypto/proof_innerproduct.go new file mode 100644 index 0000000..b8a3f32 --- /dev/null +++ b/cryptography/crypto/proof_innerproduct.go @@ -0,0 +1,313 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +//import "fmt" +import "math" +import "math/big" +import "bytes" + +//import "crypto/rand" +//import "encoding/hex" + +import "github.com/deroproject/derohe/cryptography/bn256" + +//import "golang.org/x/crypto/sha3" + +// basically the Σ-protocol +type InnerProduct struct { + a, b *big.Int + ls, rs []*bn256.G1 +} + +func (ip *InnerProduct) Size() int { + return FIELDELEMENT_SIZE + FIELDELEMENT_SIZE + 1 + len(ip.ls)*POINT_SIZE + len(ip.rs)*POINT_SIZE +} + +// since our bulletproofs are 128 bits, we can get away hard coded 7 entries +func (ip *InnerProduct) Serialize(w *bytes.Buffer) { + w.Write(ConvertBigIntToByte(ip.a)) + w.Write(ConvertBigIntToByte(ip.b)) + // w.WriteByte(byte(len(ip.ls))) // we can skip this byte also, why not skip it + + // fmt.Printf("inner proof length byte %d\n",len(ip.ls)) + for i := range ip.ls { + w.Write(ip.ls[i].EncodeCompressed()) + w.Write(ip.rs[i].EncodeCompressed()) + } +} + +func (ip *InnerProduct) Deserialize(r *bytes.Reader) (err error) { + + var buf [32]byte + var bufp [33]byte + + if n, err := r.Read(buf[:]); n == 32 && err == nil { + ip.a = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + + if n, err := r.Read(buf[:]); n == 32 && err == nil { + ip.b = new(big.Int).SetBytes(buf[:]) + } else { + return err + } + + length := 7 + + ip.ls = ip.ls[:0] + ip.rs = ip.rs[:0] + for i := 0; i < length; i++ { + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + + ip.ls = append(ip.ls, &p) + } else { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + + ip.rs = append(ip.rs, &p) + } else { + return err + } + + } + + return err +} + +func NewInnerProductProof(ips *IPStatement, witness *IPWitness, salt *big.Int) *InnerProduct { + var ip InnerProduct + + ip.generateInnerProductProof(ips.PrimeBase, ips.P, witness.L, witness.R, salt) + return &ip +} + +func (ip *InnerProduct) generateInnerProductProof(base *GeneratorParams, P *bn256.G1, as, bs *FieldVector, prev_challenge *big.Int) { + n := as.Length() + + if n == 1 { // the proof is done, ls,rs are already in place + ip.a = as.vector[0] + ip.b = bs.vector[0] + return + } + + nPrime := n / 2 + asLeft := as.Slice(0, nPrime) + asRight := as.Slice(nPrime, n) + bsLeft := bs.Slice(0, nPrime) + bsRight := bs.Slice(nPrime, n) + gLeft := base.Gs.Slice(0, nPrime) + gRight := base.Gs.Slice(nPrime, n) + hLeft := base.Hs.Slice(0, nPrime) + hRight := base.Hs.Slice(nPrime, n) + + cL := asLeft.InnerProduct(bsRight) + cR := asRight.InnerProduct(bsLeft) + + u := base.H + L := new(bn256.G1).Add(gRight.Commit(asLeft.vector), hLeft.Commit(bsRight.vector)) + L = new(bn256.G1).Add(L, new(bn256.G1).ScalarMult(u, cL)) + + R := new(bn256.G1).Add(gLeft.Commit(asRight.vector), hRight.Commit(bsLeft.vector)) + R = new(bn256.G1).Add(R, new(bn256.G1).ScalarMult(u, cR)) + + ip.ls = append(ip.ls, L) + ip.rs = append(ip.rs, R) + + var input []byte + input = append(input, ConvertBigIntToByte(prev_challenge)...) + input = append(input, L.Marshal()...) + input = append(input, R.Marshal()...) + x := reducedhash(input) + + xinv := new(big.Int).ModInverse(x, bn256.Order) + + gPrime := gLeft.Times(xinv).Add(gRight.Times(x)) + hPrime := hLeft.Times(x).Add(hRight.Times(xinv)) + aPrime := asLeft.Times(x).Add(asRight.Times(xinv)) + bPrime := bsLeft.Times(xinv).Add(bsRight.Times(x)) + + basePrime := NewGeneratorParams3(u, gPrime, hPrime) + + PPrimeL := new(bn256.G1).ScalarMult(L, new(big.Int).Mod(new(big.Int).Mul(x, x), bn256.Order)) //L * (x*x) + PPrimeR := new(bn256.G1).ScalarMult(R, new(big.Int).Mod(new(big.Int).Mul(xinv, xinv), bn256.Order)) //R * (xinv*xinv) + + PPrime := new(bn256.G1).Add(PPrimeL, PPrimeR) + PPrime = new(bn256.G1).Add(PPrime, P) + + ip.generateInnerProductProof(basePrime, PPrime, aPrime, bPrime, x) + + return + +} + +func NewInnerProductProofNew(p *PedersenVectorCommitment, salt *big.Int) *InnerProduct { + var ip InnerProduct + + ip.generateInnerProductProofNew(p, p.gvalues, p.hvalues, salt) + return &ip +} + +func (ip *InnerProduct) generateInnerProductProofNew(p *PedersenVectorCommitment, as, bs *FieldVector, prev_challenge *big.Int) { + n := as.Length() + + if n == 1 { // the proof is done, ls,rs are already in place + ip.a = as.vector[0] + ip.b = bs.vector[0] + return + } + + nPrime := n / 2 + asLeft := as.Slice(0, nPrime) + asRight := as.Slice(nPrime, n) + bsLeft := bs.Slice(0, nPrime) + bsRight := bs.Slice(nPrime, n) + + gsLeft := p.Gs.Slice(0, nPrime) + gsRight := p.Gs.Slice(nPrime, n) + hsLeft := p.Hs.Slice(0, nPrime) + hsRight := p.Hs.Slice(nPrime, n) + + cL := asLeft.InnerProduct(bsRight) + cR := asRight.InnerProduct(bsLeft) + + /*u := base.H + L := new(bn256.G1).Add(gRight.Commit(asLeft.vector), hLeft.Commit(bsRight.vector)) + L = new(bn256.G1).Add(L, new(bn256.G1).ScalarMult(u, cL)) + + R := new(bn256.G1).Add(gLeft.Commit(asRight.vector), hRight.Commit(bsLeft.vector)) + R = new(bn256.G1).Add(R, new(bn256.G1).ScalarMult(u, cR)) + */ + + Lpart := new(bn256.G1).Add(gsRight.MultiExponentiate(asLeft), hsLeft.MultiExponentiate(bsRight)) + L := new(bn256.G1).Add(Lpart, new(bn256.G1).ScalarMult(p.H, cL)) + + Rpart := new(bn256.G1).Add(gsLeft.MultiExponentiate(asRight), hsRight.MultiExponentiate(bsLeft)) + R := new(bn256.G1).Add(Rpart, new(bn256.G1).ScalarMult(p.H, cR)) + + ip.ls = append(ip.ls, L) + ip.rs = append(ip.rs, R) + + var input []byte + input = append(input, ConvertBigIntToByte(prev_challenge)...) + input = append(input, L.Marshal()...) + input = append(input, R.Marshal()...) + x := reducedhash(input) + + xInv := new(big.Int).ModInverse(x, bn256.Order) + + p.Gs = gsLeft.Times(xInv).Add(gsRight.Times(x)) + p.Hs = hsLeft.Times(x).Add(hsRight.Times(xInv)) + asPrime := asLeft.Times(x).Add(asRight.Times(xInv)) + bsPrime := bsLeft.Times(xInv).Add(bsRight.Times(x)) + + ip.generateInnerProductProofNew(p, asPrime, bsPrime, x) + + return + +} + +func (ip *InnerProduct) Verify(hs []*bn256.G1, u, P *bn256.G1, salt *big.Int, gp *GeneratorParams) bool { + log_n := uint(len(ip.ls)) + + if len(ip.ls) != len(ip.rs) { // length must be same + return false + } + n := uint(math.Pow(2, float64(log_n))) + + o := salt + var challenges []*big.Int + for i := uint(0); i < log_n; i++ { + + var input []byte + input = append(input, ConvertBigIntToByte(o)...) + input = append(input, ip.ls[i].Marshal()...) + input = append(input, ip.rs[i].Marshal()...) + o = reducedhash(input) + challenges = append(challenges, o) + + o_inv := new(big.Int).ModInverse(o, bn256.Order) + + PPrimeL := new(bn256.G1).ScalarMult(ip.ls[i], new(big.Int).Mod(new(big.Int).Mul(o, o), bn256.Order)) //L * (x*x) + PPrimeR := new(bn256.G1).ScalarMult(ip.rs[i], new(big.Int).Mod(new(big.Int).Mul(o_inv, o_inv), bn256.Order)) //L * (x*x) + + PPrime := new(bn256.G1).Add(PPrimeL, PPrimeR) + P = new(bn256.G1).Add(PPrime, P) + } + + exp := new(big.Int).SetUint64(1) + for i := uint(0); i < log_n; i++ { + exp = new(big.Int).Mod(new(big.Int).Mul(exp, challenges[i]), bn256.Order) + } + + exp_inv := new(big.Int).ModInverse(exp, bn256.Order) + + exponents := make([]*big.Int, n, n) + + exponents[0] = exp_inv // initializefirst element + + bits := make([]bool, n, n) + for i := uint(0); i < n/2; i++ { + for j := uint(0); (1< 0 { + anonsupport.vPow = new(big.Int).Mod(new(big.Int).Mul(anonsupport.vPow, anonsupport.v), bn256.Order) + // klog.V(2).Infof("vPow %s\n", anonsupport.vPow.Text(16)) + } + } + + // klog.V(2).Infof("vPow %s\n", anonsupport.vPow.Text(16)) + // klog.V(2).Infof("v %s\n", anonsupport.v.Text(16)) + + anonsupport.wPow = new(big.Int).SetUint64(1) + anonsupport.gR = new(bn256.G1) + anonsupport.gR.Unmarshal(zeroes[:]) + anonsupport.DR = new(bn256.G1) + anonsupport.DR.Unmarshal(zeroes[:]) + + for i := 0; i < m; i++ { + wPow_neg := new(big.Int).Mod(new(big.Int).Neg(anonsupport.wPow), bn256.Order) + anonsupport.CLnR.Add(new(bn256.G1).Set(anonsupport.CLnR), new(bn256.G1).ScalarMult(proof.CLnG[i], wPow_neg)) + anonsupport.CRnR.Add(new(bn256.G1).Set(anonsupport.CRnR), new(bn256.G1).ScalarMult(proof.CRnG[i], wPow_neg)) + + anonsupport.CR[0][0].Add(new(bn256.G1).Set(anonsupport.CR[0][0]), new(bn256.G1).ScalarMult(proof.C_0G[i], wPow_neg)) + anonsupport.DR.Add(new(bn256.G1).Set(anonsupport.DR), new(bn256.G1).ScalarMult(proof.DG[i], wPow_neg)) + anonsupport.yR[0][0].Add(new(bn256.G1).Set(anonsupport.yR[0][0]), new(bn256.G1).ScalarMult(proof.y_0G[i], wPow_neg)) + anonsupport.gR.Add(new(bn256.G1).Set(anonsupport.gR), new(bn256.G1).ScalarMult(proof.gG[i], wPow_neg)) + + anonsupport.C_XR.Add(new(bn256.G1).Set(anonsupport.C_XR), new(bn256.G1).ScalarMult(proof.C_XG[i], wPow_neg)) + anonsupport.y_XR.Add(new(bn256.G1).Set(anonsupport.y_XR), new(bn256.G1).ScalarMult(proof.y_XG[i], wPow_neg)) + + anonsupport.wPow = new(big.Int).Mod(new(big.Int).Mul(anonsupport.wPow, anonsupport.w), bn256.Order) + + } + // klog.V(2).Infof("qCrnR %s\n", anonsupport.CRnR.String()) + + anonsupport.DR.Add(new(bn256.G1).Set(anonsupport.DR), new(bn256.G1).ScalarMult(s.D, anonsupport.wPow)) + anonsupport.gR.Add(new(bn256.G1).Set(anonsupport.gR), new(bn256.G1).ScalarMult(gparams.G, anonsupport.wPow)) + anonsupport.C_XR.Add(new(bn256.G1).Set(anonsupport.C_XR), new(bn256.G1).ScalarMult(gparams.G, new(big.Int).Mod(new(big.Int).Mul(new(big.Int).SetUint64(total_open_value), anonsupport.wPow), bn256.Order))) + + //anonAuxiliaries.C_XR = anonAuxiliaries.C_XR.add(Utils.g().mul(Utils.fee().mul(anonAuxiliaries.wPow))); // this line is new + + // at this point, these parameters are comparable with proof generator + // klog.V(2).Infof("CLnR %s\n", anonsupport.CLnR.String()) + // klog.V(2).Infof("qCrnR %s\n", anonsupport.CRnR.String()) + // klog.V(2).Infof("DR %s\n", anonsupport.DR.String()) + // klog.V(2).Infof("gR %s\n", anonsupport.gR.String()) + // klog.V(2).Infof("C_XR %s\n", anonsupport.C_XR.String()) + // klog.V(2).Infof("y_XR %s\n", anonsupport.y_XR.String()) + + protsupport.y = reducedhash(ConvertBigIntToByte(anonsupport.w)) + protsupport.ys = append(protsupport.ys, new(big.Int).SetUint64(1)) + protsupport.k = new(big.Int).SetUint64(1) + for i := 1; i < 128; i++ { + protsupport.ys = append(protsupport.ys, new(big.Int).Mod(new(big.Int).Mul(protsupport.ys[i-1], protsupport.y), bn256.Order)) + protsupport.k = new(big.Int).Mod(new(big.Int).Add(protsupport.k, protsupport.ys[i]), bn256.Order) + } + + protsupport.z = reducedhash(ConvertBigIntToByte(protsupport.y)) + protsupport.zs = []*big.Int{new(big.Int).Exp(protsupport.z, new(big.Int).SetUint64(2), bn256.Order), new(big.Int).Exp(protsupport.z, new(big.Int).SetUint64(3), bn256.Order)} + + protsupport.zSum = new(big.Int).Mod(new(big.Int).Add(protsupport.zs[0], protsupport.zs[1]), bn256.Order) + protsupport.zSum = new(big.Int).Mod(new(big.Int).Mul(new(big.Int).Set(protsupport.zSum), protsupport.z), bn256.Order) + + // klog.V(2).Infof("zsum %s\n ", protsupport.zSum.Text(16)) + + z_z0 := new(big.Int).Mod(new(big.Int).Sub(protsupport.z, protsupport.zs[0]), bn256.Order) + protsupport.k = new(big.Int).Mod(new(big.Int).Mul(protsupport.k, z_z0), bn256.Order) + + proof_2_64, _ := new(big.Int).SetString("18446744073709551616", 10) + zsum_pow := new(big.Int).Mod(new(big.Int).Mul(protsupport.zSum, proof_2_64), bn256.Order) + zsum_pow = new(big.Int).Mod(new(big.Int).Sub(zsum_pow, protsupport.zSum), bn256.Order) + protsupport.k = new(big.Int).Mod(new(big.Int).Sub(protsupport.k, zsum_pow), bn256.Order) + + protsupport.t = new(big.Int).Mod(new(big.Int).Sub(proof.that, protsupport.k), bn256.Order) // t = tHat - delta(y, z) + + // klog.V(2).Infof("that %s\n ", proof.that.Text(16)) + // klog.V(2).Infof("zk %s\n ", protsupport.k.Text(16)) + + for i := 0; i < 64; i++ { + protsupport.twoTimesZSquared[i] = new(big.Int).Mod(new(big.Int).Mul(protsupport.zs[0], new(big.Int).SetUint64(uint64(math.Pow(2, float64(i))))), bn256.Order) + protsupport.twoTimesZSquared[64+i] = new(big.Int).Mod(new(big.Int).Mul(protsupport.zs[1], new(big.Int).SetUint64(uint64(math.Pow(2, float64(i))))), bn256.Order) + } + + // for i := 0; i < 128; i++ { + // klog.V(2).Infof("zsq %d %s", i, protsupport.twoTimesZSquared[i].Text(16)) + // } + + x := new(big.Int) + + { + var input []byte + input = append(input, ConvertBigIntToByte(protsupport.z)...) // tie intermediates/commit + input = append(input, proof.T_1.Marshal()...) + input = append(input, proof.T_2.Marshal()...) + x = reducedhash(input) + } + + xsq := new(big.Int).Mod(new(big.Int).Mul(x, x), bn256.Order) + protsupport.tEval = new(bn256.G1).ScalarMult(proof.T_1, x) + protsupport.tEval.Add(new(bn256.G1).Set(protsupport.tEval), new(bn256.G1).ScalarMult(proof.T_2, xsq)) + + // klog.V(2).Infof("protsupport.tEval %s\n", protsupport.tEval.String()) + + proof_c_neg := new(big.Int).Mod(new(big.Int).Neg(proof.c), bn256.Order) + + sigmasupport.A_y = new(bn256.G1).Add(new(bn256.G1).ScalarMult(anonsupport.gR, proof.s_sk), new(bn256.G1).ScalarMult(anonsupport.yR[0][0], proof_c_neg)) + sigmasupport.A_D = new(bn256.G1).Add(new(bn256.G1).ScalarMult(gparams.G, proof.s_r), new(bn256.G1).ScalarMult(s.D, proof_c_neg)) + + zs0_neg := new(big.Int).Mod(new(big.Int).Neg(protsupport.zs[0]), bn256.Order) + + left := new(bn256.G1).ScalarMult(anonsupport.DR, zs0_neg) + left.Add(new(bn256.G1).Set(left), new(bn256.G1).ScalarMult(anonsupport.CRnR, protsupport.zs[1])) + left = new(bn256.G1).ScalarMult(new(bn256.G1).Set(left), proof.s_sk) + + // TODO mid seems wrong + amount_fees := new(big.Int).SetUint64(total_open_value) + mid := new(bn256.G1).ScalarMult(G, new(big.Int).Mod(new(big.Int).Mul(amount_fees, anonsupport.wPow), bn256.Order)) + mid.Add(new(bn256.G1).Set(mid), new(bn256.G1).Set(anonsupport.CR[0][0])) + + right := new(bn256.G1).ScalarMult(mid, zs0_neg) + right.Add(new(bn256.G1).Set(right), new(bn256.G1).ScalarMult(anonsupport.CLnR, protsupport.zs[1])) + right = new(bn256.G1).ScalarMult(new(bn256.G1).Set(right), proof_c_neg) + + sigmasupport.A_b = new(bn256.G1).ScalarMult(gparams.G, proof.s_b) + temp := new(bn256.G1).Add(left, right) + sigmasupport.A_b.Add(new(bn256.G1).Set(sigmasupport.A_b), temp) + + //- sigmaAuxiliaries.A_b = Utils.g().mul(proof.s_b).add(anonAuxiliaries.DR.mul(zetherAuxiliaries.zs[0].neg()).add(anonAuxiliaries.CRnR.mul(zetherAuxiliaries.zs[1])).mul(proof.s_sk).add(anonAuxiliaries.CR[0][0] .mul(zetherAuxiliaries.zs[0].neg()).add(anonAuxiliaries.CLnR.mul(zetherAuxiliaries.zs[1])).mul(proof.c.neg()))); + //+ sigmaAuxiliaries.A_b = Utils.g().mul(proof.s_b).add(anonAuxiliaries.DR.mul(zetherAuxiliaries.zs[0].neg()).add(anonAuxiliaries.CRnR.mul(zetherAuxiliaries.zs[1])).mul(proof.s_sk).add(anonAuxiliaries.CR[0][0].add(Utils.g().mul(Utils.fee().mul(anonAuxiliaries.wPow))).mul(zetherAuxiliaries.zs[0].neg()).add(anonAuxiliaries.CLnR.mul(zetherAuxiliaries.zs[1])).mul(proof.c.neg()))); + + //var fees bn256.G1 + //fees.ScalarMult(G, new(big.Int).SetInt64(int64( -1 ))) + //anonsupport.C_XR.Add( new(bn256.G1).Set(anonsupport.C_XR), &fees) + + sigmasupport.A_X = new(bn256.G1).Add(new(bn256.G1).ScalarMult(anonsupport.y_XR, proof.s_r), new(bn256.G1).ScalarMult(anonsupport.C_XR, proof_c_neg)) + + proof_s_b_neg := new(big.Int).Mod(new(big.Int).Neg(proof.s_b), bn256.Order) + + sigmasupport.A_t = new(bn256.G1).ScalarMult(gparams.G, protsupport.t) + sigmasupport.A_t.Add(new(bn256.G1).Set(sigmasupport.A_t), new(bn256.G1).Neg(protsupport.tEval)) + sigmasupport.A_t = new(bn256.G1).ScalarMult(sigmasupport.A_t, new(big.Int).Mod(new(big.Int).Mul(proof.c, anonsupport.wPow), bn256.Order)) + sigmasupport.A_t.Add(new(bn256.G1).Set(sigmasupport.A_t), new(bn256.G1).ScalarMult(gparams.H, proof.s_tau)) + sigmasupport.A_t.Add(new(bn256.G1).Set(sigmasupport.A_t), new(bn256.G1).ScalarMult(gparams.G, proof_s_b_neg)) + // klog.V(2).Infof("t %s\n ", protsupport.t.Text(16)) + // klog.V(2).Infof("protsupport.tEval %s\n", protsupport.tEval.String()) + + { + var input []byte + input = append(input, []byte(PROTOCOL_CONSTANT)...) + input = append(input, s.Roothash[:]...) + + point := HashToPoint(HashtoNumber(input)) + + sigmasupport.A_u = new(bn256.G1).ScalarMult(point, proof.s_sk) + sigmasupport.A_u.Add(new(bn256.G1).Set(sigmasupport.A_u), new(bn256.G1).ScalarMult(proof.u, proof_c_neg)) + } + + // klog.V(2).Infof("A_y %s\n", sigmasupport.A_y.String()) + // klog.V(2).Infof("A_D %s\n", sigmasupport.A_D.String()) + // klog.V(2).Infof("A_b %s\n", sigmasupport.A_b.String()) + // klog.V(2).Infof("A_X %s\n", sigmasupport.A_X.String()) + // klog.V(2).Infof("A_t %s\n", sigmasupport.A_t.String()) + // klog.V(2).Infof("A_u %s\n", sigmasupport.A_u.String()) + + { + var input []byte + input = append(input, ConvertBigIntToByte(x)...) + input = append(input, sigmasupport.A_y.Marshal()...) + input = append(input, sigmasupport.A_D.Marshal()...) + input = append(input, sigmasupport.A_b.Marshal()...) + input = append(input, sigmasupport.A_X.Marshal()...) + input = append(input, sigmasupport.A_t.Marshal()...) + input = append(input, sigmasupport.A_u.Marshal()...) + // fmt.Printf("C calculation expected %s actual %s\n",proof.c.Text(16), reducedhash(input).Text(16) ) + + if reducedhash(input).Text(16) != proof.c.Text(16) { // we must fail here + + // klog.Warning("C calculation failed") + return false + } + } + + o := reducedhash(ConvertBigIntToByte(proof.c)) + + u_x := new(bn256.G1).ScalarMult(gparams.H, o) + + var hPrimes []*bn256.G1 + hPrimeSum := new(bn256.G1) + + hPrimeSum.Unmarshal(zeroes[:]) + for i := 0; i < 128; i++ { + hPrimes = append(hPrimes, new(bn256.G1).ScalarMult(gparams.Hs.vector[i], new(big.Int).ModInverse(protsupport.ys[i], bn256.Order))) + + // klog.V(2).Infof("hPrimes %d %s\n", i, hPrimes[i].String()) + + tmp := new(big.Int).Mod(new(big.Int).Mul(protsupport.ys[i], protsupport.z), bn256.Order) + tmp = new(big.Int).Mod(new(big.Int).Add(tmp, protsupport.twoTimesZSquared[i]), bn256.Order) + + hPrimeSum = new(bn256.G1).Add(hPrimeSum, new(bn256.G1).ScalarMult(hPrimes[i], tmp)) + + } + + P := new(bn256.G1).Add(proof.BA, new(bn256.G1).ScalarMult(proof.BS, x)) + P = new(bn256.G1).Add(P, new(bn256.G1).ScalarMult(gparams.GSUM, new(big.Int).Mod(new(big.Int).Neg(protsupport.z), bn256.Order))) + P = new(bn256.G1).Add(P, hPrimeSum) + + P = new(bn256.G1).Add(P, new(bn256.G1).ScalarMult(gparams.H, new(big.Int).Mod(new(big.Int).Neg(proof.mu), bn256.Order))) + P = new(bn256.G1).Add(P, new(bn256.G1).ScalarMult(u_x, new(big.Int).Mod(new(big.Int).Set(proof.that), bn256.Order))) + + // klog.V(2).Infof("P %s\n", P.String()) + + if !proof.ip.Verify(hPrimes, u_x, P, o, gparams) { + // klog.Warning("inner proof failed") + return false + } + + // klog.V(2).Infof("proof %s\n", proof.String()) + // panic("proof successful") + + // klog.V(2).Infof("Proof successful verified\n") + + return true + +} + +/* +func (proof *Proof) String() string { + klog.V(1).Infof("proof BA %s\n", proof.BA.String()) + klog.V(1).Infof("proof BS %s\n", proof.BS.String()) + klog.V(1).Infof("proof A %s\n", proof.A.String()) + klog.V(1).Infof("proof B %s\n", proof.B.String()) + + for i := range proof.CLnG { + klog.V(1).Infof("CLnG %d %s \n", i, proof.CLnG[i].String()) + } + for i := range proof.CRnG { + klog.V(1).Infof("CRnG %d %s \n", i, proof.CRnG[i].String()) + } + + for i := range proof.C_0G { + klog.V(1).Infof("C_0G %d %s \n", i, proof.C_0G[i].String()) + } + for i := range proof.DG { + klog.V(1).Infof("DG %d %s \n", i, proof.DG[i].String()) + } + for i := range proof.y_0G { + klog.V(1).Infof("y_0G %d %s \n", i, proof.y_0G[i].String()) + } + for i := range proof.gG { + klog.V(1).Infof("gG %d %s \n", i, proof.gG[i].String()) + } + + for i := range proof.C_XG { + klog.V(1).Infof("C_XG %d %s \n", i, proof.C_XG[i].String()) + } + for i := range proof.y_XG { + klog.V(1).Infof("y_XG %d %s \n", i, proof.y_XG[i].String()) + } + + //for i := range proof.tCommits.vector { + // klog.V(1).Infof("tCommits %d %s \n", i, proof.tCommits.vector[i].String()) + //} + + klog.V(1).Infof("proof z_A %s\n", proof.z_A.Text(16)) + klog.V(1).Infof("proof that %s\n", proof.that.Text(16)) + klog.V(1).Infof("proof mu %s\n", proof.mu.Text(16)) + klog.V(1).Infof("proof C %s\n", proof.c.Text(16)) + klog.V(1).Infof("proof s_sk %s\n", proof.s_sk.Text(16)) + klog.V(1).Infof("proof s_r %s\n", proof.s_r.Text(16)) + klog.V(1).Infof("proof s_b %s\n", proof.s_b.Text(16)) + klog.V(1).Infof("proof s_tau %s\n", proof.s_tau.Text(16)) + + return "" + +} +*/ +func assemblepolynomials(f [][2]*big.Int) [][2]*big.Int { + m := len(f) / 2 + N := int(math.Pow(2, float64(m))) + result := make([][2]*big.Int, N, N) + + for i := 0; i < 2; i++ { + half := recursivepolynomials(i*m, (i+1)*m, new(big.Int).SetInt64(1), f) + for j := 0; j < N; j++ { + result[j][i] = half[j] + } + } + return result +} + +func recursivepolynomials(baseline, current int, accum *big.Int, f [][2]*big.Int) []*big.Int { + size := int(math.Pow(2, float64(current-baseline))) + + result := make([]*big.Int, size, size) + if current == baseline { + result[0] = accum + return result + } + current-- + + left := recursivepolynomials(baseline, current, new(big.Int).Mod(new(big.Int).Mul(accum, f[current][0]), bn256.Order), f) + right := recursivepolynomials(baseline, current, new(big.Int).Mod(new(big.Int).Mul(accum, f[current][1]), bn256.Order), f) + for i := 0; i < size/2; i++ { + result[i] = left[i] + result[i+size/2] = right[i] + } + + return result +} diff --git a/cryptography/crypto/protocol_structures.go b/cryptography/crypto/protocol_structures.go new file mode 100644 index 0000000..ecfa123 --- /dev/null +++ b/cryptography/crypto/protocol_structures.go @@ -0,0 +1,225 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "bytes" +import "encoding/binary" +import "math/big" +import "github.com/deroproject/derohe/cryptography/bn256" +import "github.com/deroproject/graviton" + +type Statement struct { + RingSize uint64 + CLn []*bn256.G1 + CRn []*bn256.G1 + Bytes_per_publickey byte // number of bytes need per public key, it will be from 1 to 32 bytes long, but will rarely be more than 4 byte + Publickeylist_pointers []byte // all the public keys are hashed and there necessary bits taken from the start to reach graviton leaf + Publickeylist []*bn256.G1 // Todo these can be skipped and collected back later on from the chain, this will save ringsize * POINTSIZE bytes + Publickeylist_compressed [][33]byte // compressed format for public keys NOTE: only valid in deserialized transactions + C []*bn256.G1 // commitments + D *bn256.G1 + Fees uint64 + + Roothash [32]byte // note roothash contains the merkle root hash of chain, when it was build +} + +type Witness struct { + SecretKey *big.Int + R *big.Int + TransferAmount uint64 // total value being transferred + Balance uint64 // whatever is the the amount left after transfer + Index []int // index of sender in the public key list + +} + +func (s *Statement) Serialize(w *bytes.Buffer) { + buf := make([]byte, binary.MaxVarintLen64) + //n := binary.PutUvarint(buf, uint64(len(s.Publickeylist))) + //w.Write(buf[:n]) + + if len(s.Publickeylist_pointers) == 0 { + power := byte(GetPowerof2(len(s.Publickeylist))) // len(s.Publickeylist) is always power of 2 + w.WriteByte(power) + w.WriteByte(s.Bytes_per_publickey) + + n := binary.PutUvarint(buf, s.Fees) + w.Write(buf[:n]) + + w.Write(s.D.EncodeCompressed()) + s.Publickeylist_pointers = s.Publickeylist_pointers[:0] + for i := 0; i < len(s.Publickeylist); i++ { + hashed_key := graviton.Sum(s.Publickeylist[i].EncodeCompressed()) + w.Write(hashed_key[:s.Bytes_per_publickey]) + s.Publickeylist_pointers = append(s.Publickeylist_pointers, hashed_key[:s.Bytes_per_publickey]...) + } + } else { + power := byte(GetPowerof2(len(s.Publickeylist_pointers) / int(s.Bytes_per_publickey))) // len(s.Publickeylist) is always power of 2 + w.WriteByte(power) + w.WriteByte(s.Bytes_per_publickey) + n := binary.PutUvarint(buf, s.Fees) + w.Write(buf[:n]) + w.Write(s.D.EncodeCompressed()) + w.Write(s.Publickeylist_pointers[:]) + } + + for i := 0; i < len(s.Publickeylist_pointers)/int(s.Bytes_per_publickey); i++ { + // w.Write( s.CLn[i].EncodeCompressed()) /// this is expanded from graviton store + // w.Write( s.CRn[i].EncodeCompressed()) /// this is expanded from graviton store + //w.Write(s.Publickeylist[i].EncodeCompressed()) /// this is expanded from graviton store + w.Write(s.C[i].EncodeCompressed()) + } + + w.Write(s.Roothash[:]) + +} + +func (s *Statement) Deserialize(r *bytes.Reader) error { + + var err error + //var buf [32]byte + var bufp [33]byte + + length, err := r.ReadByte() + if err != nil { + return err + } + s.RingSize = 1 << length + + s.Bytes_per_publickey, err = r.ReadByte() + if err != nil { + return err + } + + s.Fees, err = binary.ReadUvarint(r) + if err != nil { + return err + } + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + s.D = &p + } else { + return err + } + + s.CLn = s.CLn[:0] + s.CRn = s.CRn[:0] + s.Publickeylist = s.Publickeylist[:0] + s.Publickeylist_compressed = s.Publickeylist_compressed[:0] + s.Publickeylist_pointers = s.Publickeylist_pointers[:0] + s.C = s.C[:0] + + s.Publickeylist_pointers = make([]byte, s.RingSize*uint64(s.Bytes_per_publickey), s.RingSize*uint64(s.Bytes_per_publickey)) + + // read all compressed pointers in 1 go + if n, err := r.Read(s.Publickeylist_pointers); n == int(s.RingSize*uint64(s.Bytes_per_publickey)) && err == nil { + + } else { + return err + } + + for i := uint64(0); i < s.RingSize; i++ { + + /* + if n,err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + s.CLn = append(s.CLn,&p) + }else{ + return err + } + + if n,err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + s.CRn = append(s.CRn,&p) + }else{ + return err + } + */ + + /* + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + var pcopy [33]byte + copy(pcopy[:], bufp[:]) + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + s.Publickeylist_compressed = append(s.Publickeylist_compressed, pcopy) + s.Publickeylist = append(s.Publickeylist, &p) + } else { + return err + } + */ + + if n, err := r.Read(bufp[:]); n == 33 && err == nil { + var p bn256.G1 + if err = p.DecodeCompressed(bufp[:]); err != nil { + return err + } + s.C = append(s.C, &p) + } else { + return err + } + + } + + if n, err := r.Read(s.Roothash[:]); n == 32 && err == nil { + + } else { + return err + } + + return nil + +} + +/* +type Proof struct { + BA *bn256.G1 + BS *bn256.G1 + A *bn256.G1 + B *bn256.G1 + + CLnG, CRnG, C_0G, DG, y_0G, gG, C_XG, y_XG []*bn256.G1 + + u *bn256.G1 + + f *FieldVector + + z_A *big.Int + + T_1 *bn256.G1 + T_2 *bn256.G1 + + that *big.Int + mu *big.Int + + c *big.Int + s_sk, s_r, s_b, s_tau *big.Int + + //ip *InnerProduct +} +*/ diff --git a/cryptography/crypto/random.go b/cryptography/crypto/random.go new file mode 100644 index 0000000..aea2957 --- /dev/null +++ b/cryptography/crypto/random.go @@ -0,0 +1,44 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "math/big" +import "crypto/rand" +import "github.com/deroproject/derohe/cryptography/bn256" + +func RandomScalar() *big.Int { + + for { + a, _ := rand.Int(rand.Reader, bn256.Order) + if a.Sign() > 0 { + return a + } + + } +} + +// this will return fixed random scalar +func RandomScalarFixed() *big.Int { + //return new(big.Int).Set(fixed) + + return RandomScalar() +} + +type KeyPair struct { + x *big.Int // secret key + y *bn256.G1 // public key +} diff --git a/cryptography/crypto/userdata.go b/cryptography/crypto/userdata.go new file mode 100644 index 0000000..03ee80f --- /dev/null +++ b/cryptography/crypto/userdata.go @@ -0,0 +1,43 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package crypto + +import "golang.org/x/crypto/chacha20" +import "github.com/deroproject/derohe/cryptography/bn256" + +// this function is used to encrypt/decrypt payment id,srcid and other userdata +// as the operation is symmetric XOR, is the same in both direction +// +func EncryptDecryptUserData(blinder *bn256.G1, inputs ...[]byte) { + blinder_compressed := blinder.EncodeCompressed() + if len(blinder_compressed) != 33 { + panic("point compression needs to be fixed") + } + + key := Keccak256(blinder_compressed[:]) + var nonce [24]byte // nonce is 24 bytes, we will use xchacha20 + + cipher, err := chacha20.NewUnauthenticatedCipher(key[:], nonce[:]) + if err != nil { + panic(err) + } + + for _, input := range inputs { + cipher.XORKeyStream(input, input) + } + return +} diff --git a/cryptography/sha3/doc.go b/cryptography/sha3/doc.go new file mode 100644 index 0000000..c06a330 --- /dev/null +++ b/cryptography/sha3/doc.go @@ -0,0 +1,66 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package sha3 implements the SHA-3 fixed-output-length hash functions and +// the SHAKE variable-output-length hash functions defined by FIPS-202. +// +// Both types of hash function use the "sponge" construction and the Keccak +// permutation. For a detailed specification see http://keccak.noekeon.org/ +// +// +// Guidance +// +// If you aren't sure what function you need, use SHAKE256 with at least 64 +// bytes of output. The SHAKE instances are faster than the SHA3 instances; +// the latter have to allocate memory to conform to the hash.Hash interface. +// +// If you need a secret-key MAC (message authentication code), prepend the +// secret key to the input, hash with SHAKE256 and read at least 32 bytes of +// output. +// +// +// Security strengths +// +// The SHA3-x (x equals 224, 256, 384, or 512) functions have a security +// strength against preimage attacks of x bits. Since they only produce "x" +// bits of output, their collision-resistance is only "x/2" bits. +// +// The SHAKE-256 and -128 functions have a generic security strength of 256 and +// 128 bits against all attacks, provided that at least 2x bits of their output +// is used. Requesting more than 64 or 32 bytes of output, respectively, does +// not increase the collision-resistance of the SHAKE functions. +// +// +// The sponge construction +// +// A sponge builds a pseudo-random function from a public pseudo-random +// permutation, by applying the permutation to a state of "rate + capacity" +// bytes, but hiding "capacity" of the bytes. +// +// A sponge starts out with a zero state. To hash an input using a sponge, up +// to "rate" bytes of the input are XORed into the sponge's state. The sponge +// is then "full" and the permutation is applied to "empty" it. This process is +// repeated until all the input has been "absorbed". The input is then padded. +// The digest is "squeezed" from the sponge in the same way, except that output +// is copied out instead of input being XORed in. +// +// A sponge is parameterized by its generic security strength, which is equal +// to half its capacity; capacity + rate is equal to the permutation's width. +// Since the KeccakF-1600 permutation is 1600 bits (200 bytes) wide, this means +// that the security strength of a sponge instance is equal to (1600 - bitrate) / 2. +// +// +// Recommendations +// +// The SHAKE functions are recommended for most new uses. They can produce +// output of arbitrary length. SHAKE256, with an output length of at least +// 64 bytes, provides 256-bit security against all attacks. The Keccak team +// recommends it for most applications upgrading from SHA2-512. (NIST chose a +// much stronger, but much slower, sponge instance for SHA3-512.) +// +// The SHA-3 functions are "drop-in" replacements for the SHA-2 functions. +// They produce output of the same length, with the same security strengths +// against all attacks. This means, in particular, that SHA3-256 only has +// 128-bit collision resistance, because its output length is 32 bytes. +package sha3 diff --git a/cryptography/sha3/hashes.go b/cryptography/sha3/hashes.go new file mode 100644 index 0000000..0d8043f --- /dev/null +++ b/cryptography/sha3/hashes.go @@ -0,0 +1,97 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package sha3 + +// This file provides functions for creating instances of the SHA-3 +// and SHAKE hash functions, as well as utility functions for hashing +// bytes. + +import ( + "hash" +) + +// New224 creates a new SHA3-224 hash. +// Its generic security strength is 224 bits against preimage attacks, +// and 112 bits against collision attacks. +func New224() hash.Hash { + if h := new224Asm(); h != nil { + return h + } + return &state{rate: 144, outputLen: 28, dsbyte: 0x06} +} + +// New256 creates a new SHA3-256 hash. +// Its generic security strength is 256 bits against preimage attacks, +// and 128 bits against collision attacks. +func New256() hash.Hash { + if h := new256Asm(); h != nil { + return h + } + return &state{rate: 136, outputLen: 32, dsbyte: 0x06} +} + +// New384 creates a new SHA3-384 hash. +// Its generic security strength is 384 bits against preimage attacks, +// and 192 bits against collision attacks. +func New384() hash.Hash { + if h := new384Asm(); h != nil { + return h + } + return &state{rate: 104, outputLen: 48, dsbyte: 0x06} +} + +// New512 creates a new SHA3-512 hash. +// Its generic security strength is 512 bits against preimage attacks, +// and 256 bits against collision attacks. +func New512() hash.Hash { + if h := new512Asm(); h != nil { + return h + } + return &state{rate: 72, outputLen: 64, dsbyte: 0x06} +} + +// NewLegacyKeccak256 creates a new Keccak-256 hash. +// +// Only use this function if you require compatibility with an existing cryptosystem +// that uses non-standard padding. All other users should use New256 instead. +func NewLegacyKeccak256() hash.Hash { return &state{rate: 136, outputLen: 32, dsbyte: 0x01} } + +// NewLegacyKeccak512 creates a new Keccak-512 hash. +// +// Only use this function if you require compatibility with an existing cryptosystem +// that uses non-standard padding. All other users should use New512 instead. +func NewLegacyKeccak512() hash.Hash { return &state{rate: 72, outputLen: 64, dsbyte: 0x01} } + +// Sum224 returns the SHA3-224 digest of the data. +func Sum224(data []byte) (digest [28]byte) { + h := New224() + h.Write(data) + h.Sum(digest[:0]) + return +} + +// Sum256 returns the SHA3-256 digest of the data. +func Sum256(data []byte) (digest [32]byte) { + h := New256() + h.Write(data) + h.Sum(digest[:0]) + return +} + +// Sum384 returns the SHA3-384 digest of the data. +func Sum384(data []byte) (digest [48]byte) { + h := New384() + h.Write(data) + h.Sum(digest[:0]) + return +} + +// Sum512 returns the SHA3-512 digest of the data. +func Sum512(data []byte) (digest [64]byte) { + h := New512() + h.Write(data) + h.Sum(digest[:0]) + return +} diff --git a/cryptography/sha3/hashes_generic.go b/cryptography/sha3/hashes_generic.go new file mode 100644 index 0000000..f455147 --- /dev/null +++ b/cryptography/sha3/hashes_generic.go @@ -0,0 +1,27 @@ +// Copyright 2017 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build gccgo appengine !s390x + +package sha3 + +import ( + "hash" +) + +// new224Asm returns an assembly implementation of SHA3-224 if available, +// otherwise it returns nil. +func new224Asm() hash.Hash { return nil } + +// new256Asm returns an assembly implementation of SHA3-256 if available, +// otherwise it returns nil. +func new256Asm() hash.Hash { return nil } + +// new384Asm returns an assembly implementation of SHA3-384 if available, +// otherwise it returns nil. +func new384Asm() hash.Hash { return nil } + +// new512Asm returns an assembly implementation of SHA3-512 if available, +// otherwise it returns nil. +func new512Asm() hash.Hash { return nil } diff --git a/cryptography/sha3/keccakf.go b/cryptography/sha3/keccakf.go new file mode 100644 index 0000000..46d03ed --- /dev/null +++ b/cryptography/sha3/keccakf.go @@ -0,0 +1,412 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build !amd64 appengine gccgo + +package sha3 + +// rc stores the round constants for use in the ι step. +var rc = [24]uint64{ + 0x0000000000000001, + 0x0000000000008082, + 0x800000000000808A, + 0x8000000080008000, + 0x000000000000808B, + 0x0000000080000001, + 0x8000000080008081, + 0x8000000000008009, + 0x000000000000008A, + 0x0000000000000088, + 0x0000000080008009, + 0x000000008000000A, + 0x000000008000808B, + 0x800000000000008B, + 0x8000000000008089, + 0x8000000000008003, + 0x8000000000008002, + 0x8000000000000080, + 0x000000000000800A, + 0x800000008000000A, + 0x8000000080008081, + 0x8000000000008080, + 0x0000000080000001, + 0x8000000080008008, +} + +// keccakF1600 applies the Keccak permutation to a 1600b-wide +// state represented as a slice of 25 uint64s. +func keccakF1600(a *[25]uint64) { + // Implementation translated from Keccak-inplace.c + // in the keccak reference code. + var t, bc0, bc1, bc2, bc3, bc4, d0, d1, d2, d3, d4 uint64 + + for i := 0; i < 24; i += 4 { + // Combines the 5 steps in each round into 2 steps. + // Unrolls 4 rounds per loop and spreads some steps across rounds. + + // Round 1 + bc0 = a[0] ^ a[5] ^ a[10] ^ a[15] ^ a[20] + bc1 = a[1] ^ a[6] ^ a[11] ^ a[16] ^ a[21] + bc2 = a[2] ^ a[7] ^ a[12] ^ a[17] ^ a[22] + bc3 = a[3] ^ a[8] ^ a[13] ^ a[18] ^ a[23] + bc4 = a[4] ^ a[9] ^ a[14] ^ a[19] ^ a[24] + d0 = bc4 ^ (bc1<<1 | bc1>>63) + d1 = bc0 ^ (bc2<<1 | bc2>>63) + d2 = bc1 ^ (bc3<<1 | bc3>>63) + d3 = bc2 ^ (bc4<<1 | bc4>>63) + d4 = bc3 ^ (bc0<<1 | bc0>>63) + + bc0 = a[0] ^ d0 + t = a[6] ^ d1 + bc1 = t<<44 | t>>(64-44) + t = a[12] ^ d2 + bc2 = t<<43 | t>>(64-43) + t = a[18] ^ d3 + bc3 = t<<21 | t>>(64-21) + t = a[24] ^ d4 + bc4 = t<<14 | t>>(64-14) + a[0] = bc0 ^ (bc2 &^ bc1) ^ rc[i] + a[6] = bc1 ^ (bc3 &^ bc2) + a[12] = bc2 ^ (bc4 &^ bc3) + a[18] = bc3 ^ (bc0 &^ bc4) + a[24] = bc4 ^ (bc1 &^ bc0) + + t = a[10] ^ d0 + bc2 = t<<3 | t>>(64-3) + t = a[16] ^ d1 + bc3 = t<<45 | t>>(64-45) + t = a[22] ^ d2 + bc4 = t<<61 | t>>(64-61) + t = a[3] ^ d3 + bc0 = t<<28 | t>>(64-28) + t = a[9] ^ d4 + bc1 = t<<20 | t>>(64-20) + a[10] = bc0 ^ (bc2 &^ bc1) + a[16] = bc1 ^ (bc3 &^ bc2) + a[22] = bc2 ^ (bc4 &^ bc3) + a[3] = bc3 ^ (bc0 &^ bc4) + a[9] = bc4 ^ (bc1 &^ bc0) + + t = a[20] ^ d0 + bc4 = t<<18 | t>>(64-18) + t = a[1] ^ d1 + bc0 = t<<1 | t>>(64-1) + t = a[7] ^ d2 + bc1 = t<<6 | t>>(64-6) + t = a[13] ^ d3 + bc2 = t<<25 | t>>(64-25) + t = a[19] ^ d4 + bc3 = t<<8 | t>>(64-8) + a[20] = bc0 ^ (bc2 &^ bc1) + a[1] = bc1 ^ (bc3 &^ bc2) + a[7] = bc2 ^ (bc4 &^ bc3) + a[13] = bc3 ^ (bc0 &^ bc4) + a[19] = bc4 ^ (bc1 &^ bc0) + + t = a[5] ^ d0 + bc1 = t<<36 | t>>(64-36) + t = a[11] ^ d1 + bc2 = t<<10 | t>>(64-10) + t = a[17] ^ d2 + bc3 = t<<15 | t>>(64-15) + t = a[23] ^ d3 + bc4 = t<<56 | t>>(64-56) + t = a[4] ^ d4 + bc0 = t<<27 | t>>(64-27) + a[5] = bc0 ^ (bc2 &^ bc1) + a[11] = bc1 ^ (bc3 &^ bc2) + a[17] = bc2 ^ (bc4 &^ bc3) + a[23] = bc3 ^ (bc0 &^ bc4) + a[4] = bc4 ^ (bc1 &^ bc0) + + t = a[15] ^ d0 + bc3 = t<<41 | t>>(64-41) + t = a[21] ^ d1 + bc4 = t<<2 | t>>(64-2) + t = a[2] ^ d2 + bc0 = t<<62 | t>>(64-62) + t = a[8] ^ d3 + bc1 = t<<55 | t>>(64-55) + t = a[14] ^ d4 + bc2 = t<<39 | t>>(64-39) + a[15] = bc0 ^ (bc2 &^ bc1) + a[21] = bc1 ^ (bc3 &^ bc2) + a[2] = bc2 ^ (bc4 &^ bc3) + a[8] = bc3 ^ (bc0 &^ bc4) + a[14] = bc4 ^ (bc1 &^ bc0) + + // Round 2 + bc0 = a[0] ^ a[5] ^ a[10] ^ a[15] ^ a[20] + bc1 = a[1] ^ a[6] ^ a[11] ^ a[16] ^ a[21] + bc2 = a[2] ^ a[7] ^ a[12] ^ a[17] ^ a[22] + bc3 = a[3] ^ a[8] ^ a[13] ^ a[18] ^ a[23] + bc4 = a[4] ^ a[9] ^ a[14] ^ a[19] ^ a[24] + d0 = bc4 ^ (bc1<<1 | bc1>>63) + d1 = bc0 ^ (bc2<<1 | bc2>>63) + d2 = bc1 ^ (bc3<<1 | bc3>>63) + d3 = bc2 ^ (bc4<<1 | bc4>>63) + d4 = bc3 ^ (bc0<<1 | bc0>>63) + + bc0 = a[0] ^ d0 + t = a[16] ^ d1 + bc1 = t<<44 | t>>(64-44) + t = a[7] ^ d2 + bc2 = t<<43 | t>>(64-43) + t = a[23] ^ d3 + bc3 = t<<21 | t>>(64-21) + t = a[14] ^ d4 + bc4 = t<<14 | t>>(64-14) + a[0] = bc0 ^ (bc2 &^ bc1) ^ rc[i+1] + a[16] = bc1 ^ (bc3 &^ bc2) + a[7] = bc2 ^ (bc4 &^ bc3) + a[23] = bc3 ^ (bc0 &^ bc4) + a[14] = bc4 ^ (bc1 &^ bc0) + + t = a[20] ^ d0 + bc2 = t<<3 | t>>(64-3) + t = a[11] ^ d1 + bc3 = t<<45 | t>>(64-45) + t = a[2] ^ d2 + bc4 = t<<61 | t>>(64-61) + t = a[18] ^ d3 + bc0 = t<<28 | t>>(64-28) + t = a[9] ^ d4 + bc1 = t<<20 | t>>(64-20) + a[20] = bc0 ^ (bc2 &^ bc1) + a[11] = bc1 ^ (bc3 &^ bc2) + a[2] = bc2 ^ (bc4 &^ bc3) + a[18] = bc3 ^ (bc0 &^ bc4) + a[9] = bc4 ^ (bc1 &^ bc0) + + t = a[15] ^ d0 + bc4 = t<<18 | t>>(64-18) + t = a[6] ^ d1 + bc0 = t<<1 | t>>(64-1) + t = a[22] ^ d2 + bc1 = t<<6 | t>>(64-6) + t = a[13] ^ d3 + bc2 = t<<25 | t>>(64-25) + t = a[4] ^ d4 + bc3 = t<<8 | t>>(64-8) + a[15] = bc0 ^ (bc2 &^ bc1) + a[6] = bc1 ^ (bc3 &^ bc2) + a[22] = bc2 ^ (bc4 &^ bc3) + a[13] = bc3 ^ (bc0 &^ bc4) + a[4] = bc4 ^ (bc1 &^ bc0) + + t = a[10] ^ d0 + bc1 = t<<36 | t>>(64-36) + t = a[1] ^ d1 + bc2 = t<<10 | t>>(64-10) + t = a[17] ^ d2 + bc3 = t<<15 | t>>(64-15) + t = a[8] ^ d3 + bc4 = t<<56 | t>>(64-56) + t = a[24] ^ d4 + bc0 = t<<27 | t>>(64-27) + a[10] = bc0 ^ (bc2 &^ bc1) + a[1] = bc1 ^ (bc3 &^ bc2) + a[17] = bc2 ^ (bc4 &^ bc3) + a[8] = bc3 ^ (bc0 &^ bc4) + a[24] = bc4 ^ (bc1 &^ bc0) + + t = a[5] ^ d0 + bc3 = t<<41 | t>>(64-41) + t = a[21] ^ d1 + bc4 = t<<2 | t>>(64-2) + t = a[12] ^ d2 + bc0 = t<<62 | t>>(64-62) + t = a[3] ^ d3 + bc1 = t<<55 | t>>(64-55) + t = a[19] ^ d4 + bc2 = t<<39 | t>>(64-39) + a[5] = bc0 ^ (bc2 &^ bc1) + a[21] = bc1 ^ (bc3 &^ bc2) + a[12] = bc2 ^ (bc4 &^ bc3) + a[3] = bc3 ^ (bc0 &^ bc4) + a[19] = bc4 ^ (bc1 &^ bc0) + + // Round 3 + bc0 = a[0] ^ a[5] ^ a[10] ^ a[15] ^ a[20] + bc1 = a[1] ^ a[6] ^ a[11] ^ a[16] ^ a[21] + bc2 = a[2] ^ a[7] ^ a[12] ^ a[17] ^ a[22] + bc3 = a[3] ^ a[8] ^ a[13] ^ a[18] ^ a[23] + bc4 = a[4] ^ a[9] ^ a[14] ^ a[19] ^ a[24] + d0 = bc4 ^ (bc1<<1 | bc1>>63) + d1 = bc0 ^ (bc2<<1 | bc2>>63) + d2 = bc1 ^ (bc3<<1 | bc3>>63) + d3 = bc2 ^ (bc4<<1 | bc4>>63) + d4 = bc3 ^ (bc0<<1 | bc0>>63) + + bc0 = a[0] ^ d0 + t = a[11] ^ d1 + bc1 = t<<44 | t>>(64-44) + t = a[22] ^ d2 + bc2 = t<<43 | t>>(64-43) + t = a[8] ^ d3 + bc3 = t<<21 | t>>(64-21) + t = a[19] ^ d4 + bc4 = t<<14 | t>>(64-14) + a[0] = bc0 ^ (bc2 &^ bc1) ^ rc[i+2] + a[11] = bc1 ^ (bc3 &^ bc2) + a[22] = bc2 ^ (bc4 &^ bc3) + a[8] = bc3 ^ (bc0 &^ bc4) + a[19] = bc4 ^ (bc1 &^ bc0) + + t = a[15] ^ d0 + bc2 = t<<3 | t>>(64-3) + t = a[1] ^ d1 + bc3 = t<<45 | t>>(64-45) + t = a[12] ^ d2 + bc4 = t<<61 | t>>(64-61) + t = a[23] ^ d3 + bc0 = t<<28 | t>>(64-28) + t = a[9] ^ d4 + bc1 = t<<20 | t>>(64-20) + a[15] = bc0 ^ (bc2 &^ bc1) + a[1] = bc1 ^ (bc3 &^ bc2) + a[12] = bc2 ^ (bc4 &^ bc3) + a[23] = bc3 ^ (bc0 &^ bc4) + a[9] = bc4 ^ (bc1 &^ bc0) + + t = a[5] ^ d0 + bc4 = t<<18 | t>>(64-18) + t = a[16] ^ d1 + bc0 = t<<1 | t>>(64-1) + t = a[2] ^ d2 + bc1 = t<<6 | t>>(64-6) + t = a[13] ^ d3 + bc2 = t<<25 | t>>(64-25) + t = a[24] ^ d4 + bc3 = t<<8 | t>>(64-8) + a[5] = bc0 ^ (bc2 &^ bc1) + a[16] = bc1 ^ (bc3 &^ bc2) + a[2] = bc2 ^ (bc4 &^ bc3) + a[13] = bc3 ^ (bc0 &^ bc4) + a[24] = bc4 ^ (bc1 &^ bc0) + + t = a[20] ^ d0 + bc1 = t<<36 | t>>(64-36) + t = a[6] ^ d1 + bc2 = t<<10 | t>>(64-10) + t = a[17] ^ d2 + bc3 = t<<15 | t>>(64-15) + t = a[3] ^ d3 + bc4 = t<<56 | t>>(64-56) + t = a[14] ^ d4 + bc0 = t<<27 | t>>(64-27) + a[20] = bc0 ^ (bc2 &^ bc1) + a[6] = bc1 ^ (bc3 &^ bc2) + a[17] = bc2 ^ (bc4 &^ bc3) + a[3] = bc3 ^ (bc0 &^ bc4) + a[14] = bc4 ^ (bc1 &^ bc0) + + t = a[10] ^ d0 + bc3 = t<<41 | t>>(64-41) + t = a[21] ^ d1 + bc4 = t<<2 | t>>(64-2) + t = a[7] ^ d2 + bc0 = t<<62 | t>>(64-62) + t = a[18] ^ d3 + bc1 = t<<55 | t>>(64-55) + t = a[4] ^ d4 + bc2 = t<<39 | t>>(64-39) + a[10] = bc0 ^ (bc2 &^ bc1) + a[21] = bc1 ^ (bc3 &^ bc2) + a[7] = bc2 ^ (bc4 &^ bc3) + a[18] = bc3 ^ (bc0 &^ bc4) + a[4] = bc4 ^ (bc1 &^ bc0) + + // Round 4 + bc0 = a[0] ^ a[5] ^ a[10] ^ a[15] ^ a[20] + bc1 = a[1] ^ a[6] ^ a[11] ^ a[16] ^ a[21] + bc2 = a[2] ^ a[7] ^ a[12] ^ a[17] ^ a[22] + bc3 = a[3] ^ a[8] ^ a[13] ^ a[18] ^ a[23] + bc4 = a[4] ^ a[9] ^ a[14] ^ a[19] ^ a[24] + d0 = bc4 ^ (bc1<<1 | bc1>>63) + d1 = bc0 ^ (bc2<<1 | bc2>>63) + d2 = bc1 ^ (bc3<<1 | bc3>>63) + d3 = bc2 ^ (bc4<<1 | bc4>>63) + d4 = bc3 ^ (bc0<<1 | bc0>>63) + + bc0 = a[0] ^ d0 + t = a[1] ^ d1 + bc1 = t<<44 | t>>(64-44) + t = a[2] ^ d2 + bc2 = t<<43 | t>>(64-43) + t = a[3] ^ d3 + bc3 = t<<21 | t>>(64-21) + t = a[4] ^ d4 + bc4 = t<<14 | t>>(64-14) + a[0] = bc0 ^ (bc2 &^ bc1) ^ rc[i+3] + a[1] = bc1 ^ (bc3 &^ bc2) + a[2] = bc2 ^ (bc4 &^ bc3) + a[3] = bc3 ^ (bc0 &^ bc4) + a[4] = bc4 ^ (bc1 &^ bc0) + + t = a[5] ^ d0 + bc2 = t<<3 | t>>(64-3) + t = a[6] ^ d1 + bc3 = t<<45 | t>>(64-45) + t = a[7] ^ d2 + bc4 = t<<61 | t>>(64-61) + t = a[8] ^ d3 + bc0 = t<<28 | t>>(64-28) + t = a[9] ^ d4 + bc1 = t<<20 | t>>(64-20) + a[5] = bc0 ^ (bc2 &^ bc1) + a[6] = bc1 ^ (bc3 &^ bc2) + a[7] = bc2 ^ (bc4 &^ bc3) + a[8] = bc3 ^ (bc0 &^ bc4) + a[9] = bc4 ^ (bc1 &^ bc0) + + t = a[10] ^ d0 + bc4 = t<<18 | t>>(64-18) + t = a[11] ^ d1 + bc0 = t<<1 | t>>(64-1) + t = a[12] ^ d2 + bc1 = t<<6 | t>>(64-6) + t = a[13] ^ d3 + bc2 = t<<25 | t>>(64-25) + t = a[14] ^ d4 + bc3 = t<<8 | t>>(64-8) + a[10] = bc0 ^ (bc2 &^ bc1) + a[11] = bc1 ^ (bc3 &^ bc2) + a[12] = bc2 ^ (bc4 &^ bc3) + a[13] = bc3 ^ (bc0 &^ bc4) + a[14] = bc4 ^ (bc1 &^ bc0) + + t = a[15] ^ d0 + bc1 = t<<36 | t>>(64-36) + t = a[16] ^ d1 + bc2 = t<<10 | t>>(64-10) + t = a[17] ^ d2 + bc3 = t<<15 | t>>(64-15) + t = a[18] ^ d3 + bc4 = t<<56 | t>>(64-56) + t = a[19] ^ d4 + bc0 = t<<27 | t>>(64-27) + a[15] = bc0 ^ (bc2 &^ bc1) + a[16] = bc1 ^ (bc3 &^ bc2) + a[17] = bc2 ^ (bc4 &^ bc3) + a[18] = bc3 ^ (bc0 &^ bc4) + a[19] = bc4 ^ (bc1 &^ bc0) + + t = a[20] ^ d0 + bc3 = t<<41 | t>>(64-41) + t = a[21] ^ d1 + bc4 = t<<2 | t>>(64-2) + t = a[22] ^ d2 + bc0 = t<<62 | t>>(64-62) + t = a[23] ^ d3 + bc1 = t<<55 | t>>(64-55) + t = a[24] ^ d4 + bc2 = t<<39 | t>>(64-39) + a[20] = bc0 ^ (bc2 &^ bc1) + a[21] = bc1 ^ (bc3 &^ bc2) + a[22] = bc2 ^ (bc4 &^ bc3) + a[23] = bc3 ^ (bc0 &^ bc4) + a[24] = bc4 ^ (bc1 &^ bc0) + } +} diff --git a/vendor/golang.org/x/tools/godoc/appengine.go b/cryptography/sha3/keccakf_amd64.go similarity index 52% rename from vendor/golang.org/x/tools/godoc/appengine.go rename to cryptography/sha3/keccakf_amd64.go index 2a68558..7886795 100644 --- a/vendor/golang.org/x/tools/godoc/appengine.go +++ b/cryptography/sha3/keccakf_amd64.go @@ -2,12 +2,12 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build appengine +// +build amd64,!appengine,!gccgo -package godoc +package sha3 -import "appengine" +// This function is implemented in keccakf_amd64.s. -func init() { - onAppengine = !appengine.IsDevAppServer() -} +//go:noescape + +func keccakF1600(a *[25]uint64) diff --git a/cryptography/sha3/keccakf_amd64.s b/cryptography/sha3/keccakf_amd64.s new file mode 100644 index 0000000..f88533a --- /dev/null +++ b/cryptography/sha3/keccakf_amd64.s @@ -0,0 +1,390 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build amd64,!appengine,!gccgo + +// This code was translated into a form compatible with 6a from the public +// domain sources at https://github.com/gvanas/KeccakCodePackage + +// Offsets in state +#define _ba (0*8) +#define _be (1*8) +#define _bi (2*8) +#define _bo (3*8) +#define _bu (4*8) +#define _ga (5*8) +#define _ge (6*8) +#define _gi (7*8) +#define _go (8*8) +#define _gu (9*8) +#define _ka (10*8) +#define _ke (11*8) +#define _ki (12*8) +#define _ko (13*8) +#define _ku (14*8) +#define _ma (15*8) +#define _me (16*8) +#define _mi (17*8) +#define _mo (18*8) +#define _mu (19*8) +#define _sa (20*8) +#define _se (21*8) +#define _si (22*8) +#define _so (23*8) +#define _su (24*8) + +// Temporary registers +#define rT1 AX + +// Round vars +#define rpState DI +#define rpStack SP + +#define rDa BX +#define rDe CX +#define rDi DX +#define rDo R8 +#define rDu R9 + +#define rBa R10 +#define rBe R11 +#define rBi R12 +#define rBo R13 +#define rBu R14 + +#define rCa SI +#define rCe BP +#define rCi rBi +#define rCo rBo +#define rCu R15 + +#define MOVQ_RBI_RCE MOVQ rBi, rCe +#define XORQ_RT1_RCA XORQ rT1, rCa +#define XORQ_RT1_RCE XORQ rT1, rCe +#define XORQ_RBA_RCU XORQ rBa, rCu +#define XORQ_RBE_RCU XORQ rBe, rCu +#define XORQ_RDU_RCU XORQ rDu, rCu +#define XORQ_RDA_RCA XORQ rDa, rCa +#define XORQ_RDE_RCE XORQ rDe, rCe + +#define mKeccakRound(iState, oState, rc, B_RBI_RCE, G_RT1_RCA, G_RT1_RCE, G_RBA_RCU, K_RT1_RCA, K_RT1_RCE, K_RBA_RCU, M_RT1_RCA, M_RT1_RCE, M_RBE_RCU, S_RDU_RCU, S_RDA_RCA, S_RDE_RCE) \ + /* Prepare round */ \ + MOVQ rCe, rDa; \ + ROLQ $1, rDa; \ + \ + MOVQ _bi(iState), rCi; \ + XORQ _gi(iState), rDi; \ + XORQ rCu, rDa; \ + XORQ _ki(iState), rCi; \ + XORQ _mi(iState), rDi; \ + XORQ rDi, rCi; \ + \ + MOVQ rCi, rDe; \ + ROLQ $1, rDe; \ + \ + MOVQ _bo(iState), rCo; \ + XORQ _go(iState), rDo; \ + XORQ rCa, rDe; \ + XORQ _ko(iState), rCo; \ + XORQ _mo(iState), rDo; \ + XORQ rDo, rCo; \ + \ + MOVQ rCo, rDi; \ + ROLQ $1, rDi; \ + \ + MOVQ rCu, rDo; \ + XORQ rCe, rDi; \ + ROLQ $1, rDo; \ + \ + MOVQ rCa, rDu; \ + XORQ rCi, rDo; \ + ROLQ $1, rDu; \ + \ + /* Result b */ \ + MOVQ _ba(iState), rBa; \ + MOVQ _ge(iState), rBe; \ + XORQ rCo, rDu; \ + MOVQ _ki(iState), rBi; \ + MOVQ _mo(iState), rBo; \ + MOVQ _su(iState), rBu; \ + XORQ rDe, rBe; \ + ROLQ $44, rBe; \ + XORQ rDi, rBi; \ + XORQ rDa, rBa; \ + ROLQ $43, rBi; \ + \ + MOVQ rBe, rCa; \ + MOVQ rc, rT1; \ + ORQ rBi, rCa; \ + XORQ rBa, rT1; \ + XORQ rT1, rCa; \ + MOVQ rCa, _ba(oState); \ + \ + XORQ rDu, rBu; \ + ROLQ $14, rBu; \ + MOVQ rBa, rCu; \ + ANDQ rBe, rCu; \ + XORQ rBu, rCu; \ + MOVQ rCu, _bu(oState); \ + \ + XORQ rDo, rBo; \ + ROLQ $21, rBo; \ + MOVQ rBo, rT1; \ + ANDQ rBu, rT1; \ + XORQ rBi, rT1; \ + MOVQ rT1, _bi(oState); \ + \ + NOTQ rBi; \ + ORQ rBa, rBu; \ + ORQ rBo, rBi; \ + XORQ rBo, rBu; \ + XORQ rBe, rBi; \ + MOVQ rBu, _bo(oState); \ + MOVQ rBi, _be(oState); \ + B_RBI_RCE; \ + \ + /* Result g */ \ + MOVQ _gu(iState), rBe; \ + XORQ rDu, rBe; \ + MOVQ _ka(iState), rBi; \ + ROLQ $20, rBe; \ + XORQ rDa, rBi; \ + ROLQ $3, rBi; \ + MOVQ _bo(iState), rBa; \ + MOVQ rBe, rT1; \ + ORQ rBi, rT1; \ + XORQ rDo, rBa; \ + MOVQ _me(iState), rBo; \ + MOVQ _si(iState), rBu; \ + ROLQ $28, rBa; \ + XORQ rBa, rT1; \ + MOVQ rT1, _ga(oState); \ + G_RT1_RCA; \ + \ + XORQ rDe, rBo; \ + ROLQ $45, rBo; \ + MOVQ rBi, rT1; \ + ANDQ rBo, rT1; \ + XORQ rBe, rT1; \ + MOVQ rT1, _ge(oState); \ + G_RT1_RCE; \ + \ + XORQ rDi, rBu; \ + ROLQ $61, rBu; \ + MOVQ rBu, rT1; \ + ORQ rBa, rT1; \ + XORQ rBo, rT1; \ + MOVQ rT1, _go(oState); \ + \ + ANDQ rBe, rBa; \ + XORQ rBu, rBa; \ + MOVQ rBa, _gu(oState); \ + NOTQ rBu; \ + G_RBA_RCU; \ + \ + ORQ rBu, rBo; \ + XORQ rBi, rBo; \ + MOVQ rBo, _gi(oState); \ + \ + /* Result k */ \ + MOVQ _be(iState), rBa; \ + MOVQ _gi(iState), rBe; \ + MOVQ _ko(iState), rBi; \ + MOVQ _mu(iState), rBo; \ + MOVQ _sa(iState), rBu; \ + XORQ rDi, rBe; \ + ROLQ $6, rBe; \ + XORQ rDo, rBi; \ + ROLQ $25, rBi; \ + MOVQ rBe, rT1; \ + ORQ rBi, rT1; \ + XORQ rDe, rBa; \ + ROLQ $1, rBa; \ + XORQ rBa, rT1; \ + MOVQ rT1, _ka(oState); \ + K_RT1_RCA; \ + \ + XORQ rDu, rBo; \ + ROLQ $8, rBo; \ + MOVQ rBi, rT1; \ + ANDQ rBo, rT1; \ + XORQ rBe, rT1; \ + MOVQ rT1, _ke(oState); \ + K_RT1_RCE; \ + \ + XORQ rDa, rBu; \ + ROLQ $18, rBu; \ + NOTQ rBo; \ + MOVQ rBo, rT1; \ + ANDQ rBu, rT1; \ + XORQ rBi, rT1; \ + MOVQ rT1, _ki(oState); \ + \ + MOVQ rBu, rT1; \ + ORQ rBa, rT1; \ + XORQ rBo, rT1; \ + MOVQ rT1, _ko(oState); \ + \ + ANDQ rBe, rBa; \ + XORQ rBu, rBa; \ + MOVQ rBa, _ku(oState); \ + K_RBA_RCU; \ + \ + /* Result m */ \ + MOVQ _ga(iState), rBe; \ + XORQ rDa, rBe; \ + MOVQ _ke(iState), rBi; \ + ROLQ $36, rBe; \ + XORQ rDe, rBi; \ + MOVQ _bu(iState), rBa; \ + ROLQ $10, rBi; \ + MOVQ rBe, rT1; \ + MOVQ _mi(iState), rBo; \ + ANDQ rBi, rT1; \ + XORQ rDu, rBa; \ + MOVQ _so(iState), rBu; \ + ROLQ $27, rBa; \ + XORQ rBa, rT1; \ + MOVQ rT1, _ma(oState); \ + M_RT1_RCA; \ + \ + XORQ rDi, rBo; \ + ROLQ $15, rBo; \ + MOVQ rBi, rT1; \ + ORQ rBo, rT1; \ + XORQ rBe, rT1; \ + MOVQ rT1, _me(oState); \ + M_RT1_RCE; \ + \ + XORQ rDo, rBu; \ + ROLQ $56, rBu; \ + NOTQ rBo; \ + MOVQ rBo, rT1; \ + ORQ rBu, rT1; \ + XORQ rBi, rT1; \ + MOVQ rT1, _mi(oState); \ + \ + ORQ rBa, rBe; \ + XORQ rBu, rBe; \ + MOVQ rBe, _mu(oState); \ + \ + ANDQ rBa, rBu; \ + XORQ rBo, rBu; \ + MOVQ rBu, _mo(oState); \ + M_RBE_RCU; \ + \ + /* Result s */ \ + MOVQ _bi(iState), rBa; \ + MOVQ _go(iState), rBe; \ + MOVQ _ku(iState), rBi; \ + XORQ rDi, rBa; \ + MOVQ _ma(iState), rBo; \ + ROLQ $62, rBa; \ + XORQ rDo, rBe; \ + MOVQ _se(iState), rBu; \ + ROLQ $55, rBe; \ + \ + XORQ rDu, rBi; \ + MOVQ rBa, rDu; \ + XORQ rDe, rBu; \ + ROLQ $2, rBu; \ + ANDQ rBe, rDu; \ + XORQ rBu, rDu; \ + MOVQ rDu, _su(oState); \ + \ + ROLQ $39, rBi; \ + S_RDU_RCU; \ + NOTQ rBe; \ + XORQ rDa, rBo; \ + MOVQ rBe, rDa; \ + ANDQ rBi, rDa; \ + XORQ rBa, rDa; \ + MOVQ rDa, _sa(oState); \ + S_RDA_RCA; \ + \ + ROLQ $41, rBo; \ + MOVQ rBi, rDe; \ + ORQ rBo, rDe; \ + XORQ rBe, rDe; \ + MOVQ rDe, _se(oState); \ + S_RDE_RCE; \ + \ + MOVQ rBo, rDi; \ + MOVQ rBu, rDo; \ + ANDQ rBu, rDi; \ + ORQ rBa, rDo; \ + XORQ rBi, rDi; \ + XORQ rBo, rDo; \ + MOVQ rDi, _si(oState); \ + MOVQ rDo, _so(oState) \ + +// func keccakF1600(state *[25]uint64) +TEXT ·keccakF1600(SB), 0, $200-8 + MOVQ state+0(FP), rpState + + // Convert the user state into an internal state + NOTQ _be(rpState) + NOTQ _bi(rpState) + NOTQ _go(rpState) + NOTQ _ki(rpState) + NOTQ _mi(rpState) + NOTQ _sa(rpState) + + // Execute the KeccakF permutation + MOVQ _ba(rpState), rCa + MOVQ _be(rpState), rCe + MOVQ _bu(rpState), rCu + + XORQ _ga(rpState), rCa + XORQ _ge(rpState), rCe + XORQ _gu(rpState), rCu + + XORQ _ka(rpState), rCa + XORQ _ke(rpState), rCe + XORQ _ku(rpState), rCu + + XORQ _ma(rpState), rCa + XORQ _me(rpState), rCe + XORQ _mu(rpState), rCu + + XORQ _sa(rpState), rCa + XORQ _se(rpState), rCe + MOVQ _si(rpState), rDi + MOVQ _so(rpState), rDo + XORQ _su(rpState), rCu + + mKeccakRound(rpState, rpStack, $0x0000000000000001, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x0000000000008082, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x800000000000808a, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x8000000080008000, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x000000000000808b, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x0000000080000001, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x8000000080008081, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x8000000000008009, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x000000000000008a, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x0000000000000088, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x0000000080008009, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x000000008000000a, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x000000008000808b, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x800000000000008b, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x8000000000008089, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x8000000000008003, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x8000000000008002, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x8000000000000080, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x000000000000800a, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x800000008000000a, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x8000000080008081, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x8000000000008080, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpState, rpStack, $0x0000000080000001, MOVQ_RBI_RCE, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBA_RCU, XORQ_RT1_RCA, XORQ_RT1_RCE, XORQ_RBE_RCU, XORQ_RDU_RCU, XORQ_RDA_RCA, XORQ_RDE_RCE) + mKeccakRound(rpStack, rpState, $0x8000000080008008, NOP, NOP, NOP, NOP, NOP, NOP, NOP, NOP, NOP, NOP, NOP, NOP, NOP) + + // Revert the internal state to the user state + NOTQ _be(rpState) + NOTQ _bi(rpState) + NOTQ _go(rpState) + NOTQ _ki(rpState) + NOTQ _mi(rpState) + NOTQ _sa(rpState) + + RET diff --git a/cryptography/sha3/register.go b/cryptography/sha3/register.go new file mode 100644 index 0000000..3cf6a22 --- /dev/null +++ b/cryptography/sha3/register.go @@ -0,0 +1,18 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build go1.4 + +package sha3 + +import ( + "crypto" +) + +func init() { + crypto.RegisterHash(crypto.SHA3_224, New224) + crypto.RegisterHash(crypto.SHA3_256, New256) + crypto.RegisterHash(crypto.SHA3_384, New384) + crypto.RegisterHash(crypto.SHA3_512, New512) +} diff --git a/cryptography/sha3/sha3.go b/cryptography/sha3/sha3.go new file mode 100644 index 0000000..ba269a0 --- /dev/null +++ b/cryptography/sha3/sha3.go @@ -0,0 +1,193 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package sha3 + +// spongeDirection indicates the direction bytes are flowing through the sponge. +type spongeDirection int + +const ( + // spongeAbsorbing indicates that the sponge is absorbing input. + spongeAbsorbing spongeDirection = iota + // spongeSqueezing indicates that the sponge is being squeezed. + spongeSqueezing +) + +const ( + // maxRate is the maximum size of the internal buffer. SHAKE-256 + // currently needs the largest buffer. + maxRate = 168 +) + +type state struct { + // Generic sponge components. + a [25]uint64 // main state of the hash + buf []byte // points into storage + rate int // the number of bytes of state to use + + // dsbyte contains the "domain separation" bits and the first bit of + // the padding. Sections 6.1 and 6.2 of [1] separate the outputs of the + // SHA-3 and SHAKE functions by appending bitstrings to the message. + // Using a little-endian bit-ordering convention, these are "01" for SHA-3 + // and "1111" for SHAKE, or 00000010b and 00001111b, respectively. Then the + // padding rule from section 5.1 is applied to pad the message to a multiple + // of the rate, which involves adding a "1" bit, zero or more "0" bits, and + // a final "1" bit. We merge the first "1" bit from the padding into dsbyte, + // giving 00000110b (0x06) and 00011111b (0x1f). + // [1] http://csrc.nist.gov/publications/drafts/fips-202/fips_202_draft.pdf + // "Draft FIPS 202: SHA-3 Standard: Permutation-Based Hash and + // Extendable-Output Functions (May 2014)" + dsbyte byte + + storage storageBuf + + // Specific to SHA-3 and SHAKE. + outputLen int // the default output size in bytes + state spongeDirection // whether the sponge is absorbing or squeezing +} + +// BlockSize returns the rate of sponge underlying this hash function. +func (d *state) BlockSize() int { return d.rate } + +// Size returns the output size of the hash function in bytes. +func (d *state) Size() int { return d.outputLen } + +// Reset clears the internal state by zeroing the sponge state and +// the byte buffer, and setting Sponge.state to absorbing. +func (d *state) Reset() { + // Zero the permutation's state. + for i := range d.a { + d.a[i] = 0 + } + d.state = spongeAbsorbing + d.buf = d.storage.asBytes()[:0] +} + +func (d *state) clone() *state { + ret := *d + if ret.state == spongeAbsorbing { + ret.buf = ret.storage.asBytes()[:len(ret.buf)] + } else { + ret.buf = ret.storage.asBytes()[d.rate-cap(d.buf) : d.rate] + } + + return &ret +} + +// permute applies the KeccakF-1600 permutation. It handles +// any input-output buffering. +func (d *state) permute() { + switch d.state { + case spongeAbsorbing: + // If we're absorbing, we need to xor the input into the state + // before applying the permutation. + xorIn(d, d.buf) + d.buf = d.storage.asBytes()[:0] + keccakF1600(&d.a) + case spongeSqueezing: + // If we're squeezing, we need to apply the permutatin before + // copying more output. + keccakF1600(&d.a) + d.buf = d.storage.asBytes()[:d.rate] + copyOut(d, d.buf) + } +} + +// pads appends the domain separation bits in dsbyte, applies +// the multi-bitrate 10..1 padding rule, and permutes the state. +func (d *state) padAndPermute(dsbyte byte) { + if d.buf == nil { + d.buf = d.storage.asBytes()[:0] + } + // Pad with this instance's domain-separator bits. We know that there's + // at least one byte of space in d.buf because, if it were full, + // permute would have been called to empty it. dsbyte also contains the + // first one bit for the padding. See the comment in the state struct. + d.buf = append(d.buf, dsbyte) + zerosStart := len(d.buf) + d.buf = d.storage.asBytes()[:d.rate] + for i := zerosStart; i < d.rate; i++ { + d.buf[i] = 0 + } + // This adds the final one bit for the padding. Because of the way that + // bits are numbered from the LSB upwards, the final bit is the MSB of + // the last byte. + d.buf[d.rate-1] ^= 0x80 + // Apply the permutation + d.permute() + d.state = spongeSqueezing + d.buf = d.storage.asBytes()[:d.rate] + copyOut(d, d.buf) +} + +// Write absorbs more data into the hash's state. It produces an error +// if more data is written to the ShakeHash after writing +func (d *state) Write(p []byte) (written int, err error) { + if d.state != spongeAbsorbing { + panic("sha3: write to sponge after read") + } + if d.buf == nil { + d.buf = d.storage.asBytes()[:0] + } + written = len(p) + + for len(p) > 0 { + if len(d.buf) == 0 && len(p) >= d.rate { + // The fast path; absorb a full "rate" bytes of input and apply the permutation. + xorIn(d, p[:d.rate]) + p = p[d.rate:] + keccakF1600(&d.a) + } else { + // The slow path; buffer the input until we can fill the sponge, and then xor it in. + todo := d.rate - len(d.buf) + if todo > len(p) { + todo = len(p) + } + d.buf = append(d.buf, p[:todo]...) + p = p[todo:] + + // If the sponge is full, apply the permutation. + if len(d.buf) == d.rate { + d.permute() + } + } + } + + return +} + +// Read squeezes an arbitrary number of bytes from the sponge. +func (d *state) Read(out []byte) (n int, err error) { + // If we're still absorbing, pad and apply the permutation. + if d.state == spongeAbsorbing { + d.padAndPermute(d.dsbyte) + } + + n = len(out) + + // Now, do the squeezing. + for len(out) > 0 { + n := copy(out, d.buf) + d.buf = d.buf[n:] + out = out[n:] + + // Apply the permutation if we've squeezed the sponge dry. + if len(d.buf) == 0 { + d.permute() + } + } + + return +} + +// Sum applies padding to the hash state and then squeezes out the desired +// number of output bytes. +func (d *state) Sum(in []byte) []byte { + // Make a copy of the original hash so that caller can keep writing + // and summing. + dup := d.clone() + hash := make([]byte, dup.outputLen) + dup.Read(hash) + return append(in, hash...) +} diff --git a/cryptography/sha3/sha3_s390x.go b/cryptography/sha3/sha3_s390x.go new file mode 100644 index 0000000..259ff4d --- /dev/null +++ b/cryptography/sha3/sha3_s390x.go @@ -0,0 +1,284 @@ +// Copyright 2017 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build !gccgo,!appengine + +package sha3 + +// This file contains code for using the 'compute intermediate +// message digest' (KIMD) and 'compute last message digest' (KLMD) +// instructions to compute SHA-3 and SHAKE hashes on IBM Z. + +import ( + "hash" + + "golang.org/x/sys/cpu" +) + +// codes represent 7-bit KIMD/KLMD function codes as defined in +// the Principles of Operation. +type code uint64 + +const ( + // function codes for KIMD/KLMD + sha3_224 code = 32 + sha3_256 = 33 + sha3_384 = 34 + sha3_512 = 35 + shake_128 = 36 + shake_256 = 37 + nopad = 0x100 +) + +// kimd is a wrapper for the 'compute intermediate message digest' instruction. +// src must be a multiple of the rate for the given function code. +//go:noescape +func kimd(function code, chain *[200]byte, src []byte) + +// klmd is a wrapper for the 'compute last message digest' instruction. +// src padding is handled by the instruction. +//go:noescape +func klmd(function code, chain *[200]byte, dst, src []byte) + +type asmState struct { + a [200]byte // 1600 bit state + buf []byte // care must be taken to ensure cap(buf) is a multiple of rate + rate int // equivalent to block size + storage [3072]byte // underlying storage for buf + outputLen int // output length if fixed, 0 if not + function code // KIMD/KLMD function code + state spongeDirection // whether the sponge is absorbing or squeezing +} + +func newAsmState(function code) *asmState { + var s asmState + s.function = function + switch function { + case sha3_224: + s.rate = 144 + s.outputLen = 28 + case sha3_256: + s.rate = 136 + s.outputLen = 32 + case sha3_384: + s.rate = 104 + s.outputLen = 48 + case sha3_512: + s.rate = 72 + s.outputLen = 64 + case shake_128: + s.rate = 168 + case shake_256: + s.rate = 136 + default: + panic("sha3: unrecognized function code") + } + + // limit s.buf size to a multiple of s.rate + s.resetBuf() + return &s +} + +func (s *asmState) clone() *asmState { + c := *s + c.buf = c.storage[:len(s.buf):cap(s.buf)] + return &c +} + +// copyIntoBuf copies b into buf. It will panic if there is not enough space to +// store all of b. +func (s *asmState) copyIntoBuf(b []byte) { + bufLen := len(s.buf) + s.buf = s.buf[:len(s.buf)+len(b)] + copy(s.buf[bufLen:], b) +} + +// resetBuf points buf at storage, sets the length to 0 and sets cap to be a +// multiple of the rate. +func (s *asmState) resetBuf() { + max := (cap(s.storage) / s.rate) * s.rate + s.buf = s.storage[:0:max] +} + +// Write (via the embedded io.Writer interface) adds more data to the running hash. +// It never returns an error. +func (s *asmState) Write(b []byte) (int, error) { + if s.state != spongeAbsorbing { + panic("sha3: write to sponge after read") + } + length := len(b) + for len(b) > 0 { + if len(s.buf) == 0 && len(b) >= cap(s.buf) { + // Hash the data directly and push any remaining bytes + // into the buffer. + remainder := len(b) % s.rate + kimd(s.function, &s.a, b[:len(b)-remainder]) + if remainder != 0 { + s.copyIntoBuf(b[len(b)-remainder:]) + } + return length, nil + } + + if len(s.buf) == cap(s.buf) { + // flush the buffer + kimd(s.function, &s.a, s.buf) + s.buf = s.buf[:0] + } + + // copy as much as we can into the buffer + n := len(b) + if len(b) > cap(s.buf)-len(s.buf) { + n = cap(s.buf) - len(s.buf) + } + s.copyIntoBuf(b[:n]) + b = b[n:] + } + return length, nil +} + +// Read squeezes an arbitrary number of bytes from the sponge. +func (s *asmState) Read(out []byte) (n int, err error) { + n = len(out) + + // need to pad if we were absorbing + if s.state == spongeAbsorbing { + s.state = spongeSqueezing + + // write hash directly into out if possible + if len(out)%s.rate == 0 { + klmd(s.function, &s.a, out, s.buf) // len(out) may be 0 + s.buf = s.buf[:0] + return + } + + // write hash into buffer + max := cap(s.buf) + if max > len(out) { + max = (len(out)/s.rate)*s.rate + s.rate + } + klmd(s.function, &s.a, s.buf[:max], s.buf) + s.buf = s.buf[:max] + } + + for len(out) > 0 { + // flush the buffer + if len(s.buf) != 0 { + c := copy(out, s.buf) + out = out[c:] + s.buf = s.buf[c:] + continue + } + + // write hash directly into out if possible + if len(out)%s.rate == 0 { + klmd(s.function|nopad, &s.a, out, nil) + return + } + + // write hash into buffer + s.resetBuf() + if cap(s.buf) > len(out) { + s.buf = s.buf[:(len(out)/s.rate)*s.rate+s.rate] + } + klmd(s.function|nopad, &s.a, s.buf, nil) + } + return +} + +// Sum appends the current hash to b and returns the resulting slice. +// It does not change the underlying hash state. +func (s *asmState) Sum(b []byte) []byte { + if s.outputLen == 0 { + panic("sha3: cannot call Sum on SHAKE functions") + } + + // Copy the state to preserve the original. + a := s.a + + // Hash the buffer. Note that we don't clear it because we + // aren't updating the state. + klmd(s.function, &a, nil, s.buf) + return append(b, a[:s.outputLen]...) +} + +// Reset resets the Hash to its initial state. +func (s *asmState) Reset() { + for i := range s.a { + s.a[i] = 0 + } + s.resetBuf() + s.state = spongeAbsorbing +} + +// Size returns the number of bytes Sum will return. +func (s *asmState) Size() int { + return s.outputLen +} + +// BlockSize returns the hash's underlying block size. +// The Write method must be able to accept any amount +// of data, but it may operate more efficiently if all writes +// are a multiple of the block size. +func (s *asmState) BlockSize() int { + return s.rate +} + +// Clone returns a copy of the ShakeHash in its current state. +func (s *asmState) Clone() ShakeHash { + return s.clone() +} + +// new224Asm returns an assembly implementation of SHA3-224 if available, +// otherwise it returns nil. +func new224Asm() hash.Hash { + if cpu.S390X.HasSHA3 { + return newAsmState(sha3_224) + } + return nil +} + +// new256Asm returns an assembly implementation of SHA3-256 if available, +// otherwise it returns nil. +func new256Asm() hash.Hash { + if cpu.S390X.HasSHA3 { + return newAsmState(sha3_256) + } + return nil +} + +// new384Asm returns an assembly implementation of SHA3-384 if available, +// otherwise it returns nil. +func new384Asm() hash.Hash { + if cpu.S390X.HasSHA3 { + return newAsmState(sha3_384) + } + return nil +} + +// new512Asm returns an assembly implementation of SHA3-512 if available, +// otherwise it returns nil. +func new512Asm() hash.Hash { + if cpu.S390X.HasSHA3 { + return newAsmState(sha3_512) + } + return nil +} + +// newShake128Asm returns an assembly implementation of SHAKE-128 if available, +// otherwise it returns nil. +func newShake128Asm() ShakeHash { + if cpu.S390X.HasSHA3 { + return newAsmState(shake_128) + } + return nil +} + +// newShake256Asm returns an assembly implementation of SHAKE-256 if available, +// otherwise it returns nil. +func newShake256Asm() ShakeHash { + if cpu.S390X.HasSHA3 { + return newAsmState(shake_256) + } + return nil +} diff --git a/cryptography/sha3/sha3_s390x.s b/cryptography/sha3/sha3_s390x.s new file mode 100644 index 0000000..8a4458f --- /dev/null +++ b/cryptography/sha3/sha3_s390x.s @@ -0,0 +1,33 @@ +// Copyright 2017 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build !gccgo,!appengine + +#include "textflag.h" + +// func kimd(function code, chain *[200]byte, src []byte) +TEXT ·kimd(SB), NOFRAME|NOSPLIT, $0-40 + MOVD function+0(FP), R0 + MOVD chain+8(FP), R1 + LMG src+16(FP), R2, R3 // R2=base, R3=len + +continue: + WORD $0xB93E0002 // KIMD --, R2 + BVS continue // continue if interrupted + MOVD $0, R0 // reset R0 for pre-go1.8 compilers + RET + +// func klmd(function code, chain *[200]byte, dst, src []byte) +TEXT ·klmd(SB), NOFRAME|NOSPLIT, $0-64 + // TODO: SHAKE support + MOVD function+0(FP), R0 + MOVD chain+8(FP), R1 + LMG dst+16(FP), R2, R3 // R2=base, R3=len + LMG src+40(FP), R4, R5 // R4=base, R5=len + +continue: + WORD $0xB93F0024 // KLMD R2, R4 + BVS continue // continue if interrupted + MOVD $0, R0 // reset R0 for pre-go1.8 compilers + RET diff --git a/cryptography/sha3/sha3_test.go b/cryptography/sha3/sha3_test.go new file mode 100644 index 0000000..005a242 --- /dev/null +++ b/cryptography/sha3/sha3_test.go @@ -0,0 +1,483 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package sha3 + +// Tests include all the ShortMsgKATs provided by the Keccak team at +// https://github.com/gvanas/KeccakCodePackage +// +// They only include the zero-bit case of the bitwise testvectors +// published by NIST in the draft of FIPS-202. + +import ( + "bytes" + "compress/flate" + "encoding/hex" + "encoding/json" + "fmt" + "hash" + "os" + "strings" + "testing" +) + +const ( + testString = "brekeccakkeccak koax koax" + katFilename = "testdata/keccakKats.json.deflate" +) + +// testDigests contains functions returning hash.Hash instances +// with output-length equal to the KAT length for SHA-3, Keccak +// and SHAKE instances. +var testDigests = map[string]func() hash.Hash{ + "SHA3-224": New224, + "SHA3-256": New256, + "SHA3-384": New384, + "SHA3-512": New512, + "Keccak-256": NewLegacyKeccak256, + "Keccak-512": NewLegacyKeccak512, +} + +// testShakes contains functions that return sha3.ShakeHash instances for +// with output-length equal to the KAT length. +var testShakes = map[string]struct { + constructor func(N []byte, S []byte) ShakeHash + defAlgoName string + defCustomStr string +}{ + // NewCShake without customization produces same result as SHAKE + "SHAKE128": {NewCShake128, "", ""}, + "SHAKE256": {NewCShake256, "", ""}, + "cSHAKE128": {NewCShake128, "CSHAKE128", "CustomStrign"}, + "cSHAKE256": {NewCShake256, "CSHAKE256", "CustomStrign"}, +} + +// decodeHex converts a hex-encoded string into a raw byte string. +func decodeHex(s string) []byte { + b, err := hex.DecodeString(s) + if err != nil { + panic(err) + } + return b +} + +// structs used to marshal JSON test-cases. +type KeccakKats struct { + Kats map[string][]struct { + Digest string `json:"digest"` + Length int64 `json:"length"` + Message string `json:"message"` + + // Defined only for cSHAKE + N string `json:"N"` + S string `json:"S"` + } +} + +func testUnalignedAndGeneric(t *testing.T, testf func(impl string)) { + xorInOrig, copyOutOrig := xorIn, copyOut + xorIn, copyOut = xorInGeneric, copyOutGeneric + testf("generic") + if xorImplementationUnaligned != "generic" { + xorIn, copyOut = xorInUnaligned, copyOutUnaligned + testf("unaligned") + } + xorIn, copyOut = xorInOrig, copyOutOrig +} + +// TestKeccakKats tests the SHA-3 and Shake implementations against all the +// ShortMsgKATs from https://github.com/gvanas/KeccakCodePackage +// (The testvectors are stored in keccakKats.json.deflate due to their length.) +func TestKeccakKats(t *testing.T) { + testUnalignedAndGeneric(t, func(impl string) { + // Read the KATs. + deflated, err := os.Open(katFilename) + if err != nil { + t.Errorf("error opening %s: %s", katFilename, err) + } + file := flate.NewReader(deflated) + dec := json.NewDecoder(file) + var katSet KeccakKats + err = dec.Decode(&katSet) + if err != nil { + t.Errorf("error decoding KATs: %s", err) + } + + for algo, function := range testDigests { + d := function() + for _, kat := range katSet.Kats[algo] { + d.Reset() + in, err := hex.DecodeString(kat.Message) + if err != nil { + t.Errorf("error decoding KAT: %s", err) + } + d.Write(in[:kat.Length/8]) + got := strings.ToUpper(hex.EncodeToString(d.Sum(nil))) + if got != kat.Digest { + t.Errorf("function=%s, implementation=%s, length=%d\nmessage:\n %s\ngot:\n %s\nwanted:\n %s", + algo, impl, kat.Length, kat.Message, got, kat.Digest) + t.Logf("wanted %+v", kat) + t.FailNow() + } + continue + } + } + + for algo, v := range testShakes { + for _, kat := range katSet.Kats[algo] { + N, err := hex.DecodeString(kat.N) + if err != nil { + t.Errorf("error decoding KAT: %s", err) + } + + S, err := hex.DecodeString(kat.S) + if err != nil { + t.Errorf("error decoding KAT: %s", err) + } + d := v.constructor(N, S) + in, err := hex.DecodeString(kat.Message) + if err != nil { + t.Errorf("error decoding KAT: %s", err) + } + + d.Write(in[:kat.Length/8]) + out := make([]byte, len(kat.Digest)/2) + d.Read(out) + got := strings.ToUpper(hex.EncodeToString(out)) + if got != kat.Digest { + t.Errorf("function=%s, implementation=%s, length=%d N:%s\n S:%s\nmessage:\n %s \ngot:\n %s\nwanted:\n %s", + algo, impl, kat.Length, kat.N, kat.S, kat.Message, got, kat.Digest) + t.Logf("wanted %+v", kat) + t.FailNow() + } + continue + } + } + }) +} + +// TestKeccak does a basic test of the non-standardized Keccak hash functions. +func TestKeccak(t *testing.T) { + tests := []struct { + fn func() hash.Hash + data []byte + want string + }{ + { + NewLegacyKeccak256, + []byte("abc"), + "4e03657aea45a94fc7d47ba826c8d667c0d1e6e33a64a036ec44f58fa12d6c45", + }, + { + NewLegacyKeccak512, + []byte("abc"), + "18587dc2ea106b9a1563e32b3312421ca164c7f1f07bc922a9c83d77cea3a1e5d0c69910739025372dc14ac9642629379540c17e2a65b19d77aa511a9d00bb96", + }, + } + + for _, u := range tests { + h := u.fn() + h.Write(u.data) + got := h.Sum(nil) + want := decodeHex(u.want) + if !bytes.Equal(got, want) { + t.Errorf("unexpected hash for size %d: got '%x' want '%s'", h.Size()*8, got, u.want) + } + } +} + +// TestUnalignedWrite tests that writing data in an arbitrary pattern with +// small input buffers. +func TestUnalignedWrite(t *testing.T) { + testUnalignedAndGeneric(t, func(impl string) { + buf := sequentialBytes(0x10000) + for alg, df := range testDigests { + d := df() + d.Reset() + d.Write(buf) + want := d.Sum(nil) + d.Reset() + for i := 0; i < len(buf); { + // Cycle through offsets which make a 137 byte sequence. + // Because 137 is prime this sequence should exercise all corner cases. + offsets := [17]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 1} + for _, j := range offsets { + if v := len(buf) - i; v < j { + j = v + } + d.Write(buf[i : i+j]) + i += j + } + } + got := d.Sum(nil) + if !bytes.Equal(got, want) { + t.Errorf("Unaligned writes, implementation=%s, alg=%s\ngot %q, want %q", impl, alg, got, want) + } + } + + // Same for SHAKE + for alg, df := range testShakes { + want := make([]byte, 16) + got := make([]byte, 16) + d := df.constructor([]byte(df.defAlgoName), []byte(df.defCustomStr)) + + d.Reset() + d.Write(buf) + d.Read(want) + d.Reset() + for i := 0; i < len(buf); { + // Cycle through offsets which make a 137 byte sequence. + // Because 137 is prime this sequence should exercise all corner cases. + offsets := [17]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 1} + for _, j := range offsets { + if v := len(buf) - i; v < j { + j = v + } + d.Write(buf[i : i+j]) + i += j + } + } + d.Read(got) + if !bytes.Equal(got, want) { + t.Errorf("Unaligned writes, implementation=%s, alg=%s\ngot %q, want %q", impl, alg, got, want) + } + } + }) +} + +// TestAppend checks that appending works when reallocation is necessary. +func TestAppend(t *testing.T) { + testUnalignedAndGeneric(t, func(impl string) { + d := New224() + + for capacity := 2; capacity <= 66; capacity += 64 { + // The first time around the loop, Sum will have to reallocate. + // The second time, it will not. + buf := make([]byte, 2, capacity) + d.Reset() + d.Write([]byte{0xcc}) + buf = d.Sum(buf) + expected := "0000DF70ADC49B2E76EEE3A6931B93FA41841C3AF2CDF5B32A18B5478C39" + if got := strings.ToUpper(hex.EncodeToString(buf)); got != expected { + t.Errorf("got %s, want %s", got, expected) + } + } + }) +} + +// TestAppendNoRealloc tests that appending works when no reallocation is necessary. +func TestAppendNoRealloc(t *testing.T) { + testUnalignedAndGeneric(t, func(impl string) { + buf := make([]byte, 1, 200) + d := New224() + d.Write([]byte{0xcc}) + buf = d.Sum(buf) + expected := "00DF70ADC49B2E76EEE3A6931B93FA41841C3AF2CDF5B32A18B5478C39" + if got := strings.ToUpper(hex.EncodeToString(buf)); got != expected { + t.Errorf("%s: got %s, want %s", impl, got, expected) + } + }) +} + +// TestSqueezing checks that squeezing the full output a single time produces +// the same output as repeatedly squeezing the instance. +func TestSqueezing(t *testing.T) { + testUnalignedAndGeneric(t, func(impl string) { + for algo, v := range testShakes { + d0 := v.constructor([]byte(v.defAlgoName), []byte(v.defCustomStr)) + d0.Write([]byte(testString)) + ref := make([]byte, 32) + d0.Read(ref) + + d1 := v.constructor([]byte(v.defAlgoName), []byte(v.defCustomStr)) + d1.Write([]byte(testString)) + var multiple []byte + for range ref { + one := make([]byte, 1) + d1.Read(one) + multiple = append(multiple, one...) + } + if !bytes.Equal(ref, multiple) { + t.Errorf("%s (%s): squeezing %d bytes one at a time failed", algo, impl, len(ref)) + } + } + }) +} + +// sequentialBytes produces a buffer of size consecutive bytes 0x00, 0x01, ..., used for testing. +func sequentialBytes(size int) []byte { + result := make([]byte, size) + for i := range result { + result[i] = byte(i) + } + return result +} + +func TestReset(t *testing.T) { + out1 := make([]byte, 32) + out2 := make([]byte, 32) + + for _, v := range testShakes { + // Calculate hash for the first time + c := v.constructor(nil, []byte{0x99, 0x98}) + c.Write(sequentialBytes(0x100)) + c.Read(out1) + + // Calculate hash again + c.Reset() + c.Write(sequentialBytes(0x100)) + c.Read(out2) + + if !bytes.Equal(out1, out2) { + t.Error("\nExpected:\n", out1, "\ngot:\n", out2) + } + } +} + +func TestClone(t *testing.T) { + out1 := make([]byte, 16) + out2 := make([]byte, 16) + + // Test for sizes smaller and larger than block size. + for _, size := range []int{0x1, 0x100} { + in := sequentialBytes(size) + for _, v := range testShakes { + h1 := v.constructor(nil, []byte{0x01}) + h1.Write([]byte{0x01}) + + h2 := h1.Clone() + + h1.Write(in) + h1.Read(out1) + + h2.Write(in) + h2.Read(out2) + + if !bytes.Equal(out1, out2) { + t.Error("\nExpected:\n", hex.EncodeToString(out1), "\ngot:\n", hex.EncodeToString(out2)) + } + } + } +} + +// BenchmarkPermutationFunction measures the speed of the permutation function +// with no input data. +func BenchmarkPermutationFunction(b *testing.B) { + b.SetBytes(int64(200)) + var lanes [25]uint64 + for i := 0; i < b.N; i++ { + keccakF1600(&lanes) + } +} + +// benchmarkHash tests the speed to hash num buffers of buflen each. +func benchmarkHash(b *testing.B, h hash.Hash, size, num int) { + b.StopTimer() + h.Reset() + data := sequentialBytes(size) + b.SetBytes(int64(size * num)) + b.StartTimer() + + var state []byte + for i := 0; i < b.N; i++ { + for j := 0; j < num; j++ { + h.Write(data) + } + state = h.Sum(state[:0]) + } + b.StopTimer() + h.Reset() +} + +// benchmarkShake is specialized to the Shake instances, which don't +// require a copy on reading output. +func benchmarkShake(b *testing.B, h ShakeHash, size, num int) { + b.StopTimer() + h.Reset() + data := sequentialBytes(size) + d := make([]byte, 32) + + b.SetBytes(int64(size * num)) + b.StartTimer() + + for i := 0; i < b.N; i++ { + h.Reset() + for j := 0; j < num; j++ { + h.Write(data) + } + h.Read(d) + } +} + +func BenchmarkSha3_512_MTU(b *testing.B) { benchmarkHash(b, New512(), 1350, 1) } +func BenchmarkSha3_384_MTU(b *testing.B) { benchmarkHash(b, New384(), 1350, 1) } +func BenchmarkSha3_256_MTU(b *testing.B) { benchmarkHash(b, New256(), 1350, 1) } +func BenchmarkSha3_224_MTU(b *testing.B) { benchmarkHash(b, New224(), 1350, 1) } + +func BenchmarkShake128_MTU(b *testing.B) { benchmarkShake(b, NewShake128(), 1350, 1) } +func BenchmarkShake256_MTU(b *testing.B) { benchmarkShake(b, NewShake256(), 1350, 1) } +func BenchmarkShake256_16x(b *testing.B) { benchmarkShake(b, NewShake256(), 16, 1024) } +func BenchmarkShake256_1MiB(b *testing.B) { benchmarkShake(b, NewShake256(), 1024, 1024) } + +func BenchmarkSha3_512_1MiB(b *testing.B) { benchmarkHash(b, New512(), 1024, 1024) } + +func Example_sum() { + buf := []byte("some data to hash") + // A hash needs to be 64 bytes long to have 256-bit collision resistance. + h := make([]byte, 64) + // Compute a 64-byte hash of buf and put it in h. + ShakeSum256(h, buf) + fmt.Printf("%x\n", h) + // Output: 0f65fe41fc353e52c55667bb9e2b27bfcc8476f2c413e9437d272ee3194a4e3146d05ec04a25d16b8f577c19b82d16b1424c3e022e783d2b4da98de3658d363d +} + +func Example_mac() { + k := []byte("this is a secret key; you should generate a strong random key that's at least 32 bytes long") + buf := []byte("and this is some data to authenticate") + // A MAC with 32 bytes of output has 256-bit security strength -- if you use at least a 32-byte-long key. + h := make([]byte, 32) + d := NewShake256() + // Write the key into the hash. + d.Write(k) + // Now write the data. + d.Write(buf) + // Read 32 bytes of output from the hash into h. + d.Read(h) + fmt.Printf("%x\n", h) + // Output: 78de2974bd2711d5549ffd32b753ef0f5fa80a0db2556db60f0987eb8a9218ff +} + +func ExampleNewCShake256() { + out := make([]byte, 32) + msg := []byte("The quick brown fox jumps over the lazy dog") + + // Example 1: Simple cshake + c1 := NewCShake256([]byte("NAME"), []byte("Partition1")) + c1.Write(msg) + c1.Read(out) + fmt.Println(hex.EncodeToString(out)) + + // Example 2: Different customization string produces different digest + c1 = NewCShake256([]byte("NAME"), []byte("Partition2")) + c1.Write(msg) + c1.Read(out) + fmt.Println(hex.EncodeToString(out)) + + // Example 3: Longer output length produces longer digest + out = make([]byte, 64) + c1 = NewCShake256([]byte("NAME"), []byte("Partition1")) + c1.Write(msg) + c1.Read(out) + fmt.Println(hex.EncodeToString(out)) + + // Example 4: Next read produces different result + c1.Read(out) + fmt.Println(hex.EncodeToString(out)) + + // Output: + //a90a4c6ca9af2156eba43dc8398279e6b60dcd56fb21837afe6c308fd4ceb05b + //a8db03e71f3e4da5c4eee9d28333cdd355f51cef3c567e59be5beb4ecdbb28f0 + //a90a4c6ca9af2156eba43dc8398279e6b60dcd56fb21837afe6c308fd4ceb05b9dd98c6ee866ca7dc5a39d53e960f400bcd5a19c8a2d6ec6459f63696543a0d8 + //85e73a72228d08b46515553ca3a29d47df3047e5d84b12d6c2c63e579f4fd1105716b7838e92e981863907f434bfd4443c9e56ea09da998d2f9b47db71988109 +} diff --git a/cryptography/sha3/shake.go b/cryptography/sha3/shake.go new file mode 100644 index 0000000..d7be295 --- /dev/null +++ b/cryptography/sha3/shake.go @@ -0,0 +1,173 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package sha3 + +// This file defines the ShakeHash interface, and provides +// functions for creating SHAKE and cSHAKE instances, as well as utility +// functions for hashing bytes to arbitrary-length output. +// +// +// SHAKE implementation is based on FIPS PUB 202 [1] +// cSHAKE implementations is based on NIST SP 800-185 [2] +// +// [1] https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.202.pdf +// [2] https://doi.org/10.6028/NIST.SP.800-185 + +import ( + "encoding/binary" + "io" +) + +// ShakeHash defines the interface to hash functions that +// support arbitrary-length output. +type ShakeHash interface { + // Write absorbs more data into the hash's state. It panics if input is + // written to it after output has been read from it. + io.Writer + + // Read reads more output from the hash; reading affects the hash's + // state. (ShakeHash.Read is thus very different from Hash.Sum) + // It never returns an error. + io.Reader + + // Clone returns a copy of the ShakeHash in its current state. + Clone() ShakeHash + + // Reset resets the ShakeHash to its initial state. + Reset() +} + +// cSHAKE specific context +type cshakeState struct { + *state // SHA-3 state context and Read/Write operations + + // initBlock is the cSHAKE specific initialization set of bytes. It is initialized + // by newCShake function and stores concatenation of N followed by S, encoded + // by the method specified in 3.3 of [1]. + // It is stored here in order for Reset() to be able to put context into + // initial state. + initBlock []byte +} + +// Consts for configuring initial SHA-3 state +const ( + dsbyteShake = 0x1f + dsbyteCShake = 0x04 + rate128 = 168 + rate256 = 136 +) + +func bytepad(input []byte, w int) []byte { + // leftEncode always returns max 9 bytes + buf := make([]byte, 0, 9+len(input)+w) + buf = append(buf, leftEncode(uint64(w))...) + buf = append(buf, input...) + padlen := w - (len(buf) % w) + return append(buf, make([]byte, padlen)...) +} + +func leftEncode(value uint64) []byte { + var b [9]byte + binary.BigEndian.PutUint64(b[1:], value) + // Trim all but last leading zero bytes + i := byte(1) + for i < 8 && b[i] == 0 { + i++ + } + // Prepend number of encoded bytes + b[i-1] = 9 - i + return b[i-1:] +} + +func newCShake(N, S []byte, rate int, dsbyte byte) ShakeHash { + c := cshakeState{state: &state{rate: rate, dsbyte: dsbyte}} + + // leftEncode returns max 9 bytes + c.initBlock = make([]byte, 0, 9*2+len(N)+len(S)) + c.initBlock = append(c.initBlock, leftEncode(uint64(len(N)*8))...) + c.initBlock = append(c.initBlock, N...) + c.initBlock = append(c.initBlock, leftEncode(uint64(len(S)*8))...) + c.initBlock = append(c.initBlock, S...) + c.Write(bytepad(c.initBlock, c.rate)) + return &c +} + +// Reset resets the hash to initial state. +func (c *cshakeState) Reset() { + c.state.Reset() + c.Write(bytepad(c.initBlock, c.rate)) +} + +// Clone returns copy of a cSHAKE context within its current state. +func (c *cshakeState) Clone() ShakeHash { + b := make([]byte, len(c.initBlock)) + copy(b, c.initBlock) + return &cshakeState{state: c.clone(), initBlock: b} +} + +// Clone returns copy of SHAKE context within its current state. +func (c *state) Clone() ShakeHash { + return c.clone() +} + +// NewShake128 creates a new SHAKE128 variable-output-length ShakeHash. +// Its generic security strength is 128 bits against all attacks if at +// least 32 bytes of its output are used. +func NewShake128() ShakeHash { + if h := newShake128Asm(); h != nil { + return h + } + return &state{rate: rate128, dsbyte: dsbyteShake} +} + +// NewShake256 creates a new SHAKE256 variable-output-length ShakeHash. +// Its generic security strength is 256 bits against all attacks if +// at least 64 bytes of its output are used. +func NewShake256() ShakeHash { + if h := newShake256Asm(); h != nil { + return h + } + return &state{rate: rate256, dsbyte: dsbyteShake} +} + +// NewCShake128 creates a new instance of cSHAKE128 variable-output-length ShakeHash, +// a customizable variant of SHAKE128. +// N is used to define functions based on cSHAKE, it can be empty when plain cSHAKE is +// desired. S is a customization byte string used for domain separation - two cSHAKE +// computations on same input with different S yield unrelated outputs. +// When N and S are both empty, this is equivalent to NewShake128. +func NewCShake128(N, S []byte) ShakeHash { + if len(N) == 0 && len(S) == 0 { + return NewShake128() + } + return newCShake(N, S, rate128, dsbyteCShake) +} + +// NewCShake256 creates a new instance of cSHAKE256 variable-output-length ShakeHash, +// a customizable variant of SHAKE256. +// N is used to define functions based on cSHAKE, it can be empty when plain cSHAKE is +// desired. S is a customization byte string used for domain separation - two cSHAKE +// computations on same input with different S yield unrelated outputs. +// When N and S are both empty, this is equivalent to NewShake256. +func NewCShake256(N, S []byte) ShakeHash { + if len(N) == 0 && len(S) == 0 { + return NewShake256() + } + return newCShake(N, S, rate256, dsbyteCShake) +} + +// ShakeSum128 writes an arbitrary-length digest of data into hash. +func ShakeSum128(hash, data []byte) { + h := NewShake128() + h.Write(data) + h.Read(hash) +} + +// ShakeSum256 writes an arbitrary-length digest of data into hash. +func ShakeSum256(hash, data []byte) { + h := NewShake256() + h.Write(data) + h.Read(hash) +} diff --git a/cryptography/sha3/shake_generic.go b/cryptography/sha3/shake_generic.go new file mode 100644 index 0000000..add4e73 --- /dev/null +++ b/cryptography/sha3/shake_generic.go @@ -0,0 +1,19 @@ +// Copyright 2017 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build gccgo appengine !s390x + +package sha3 + +// newShake128Asm returns an assembly implementation of SHAKE-128 if available, +// otherwise it returns nil. +func newShake128Asm() ShakeHash { + return nil +} + +// newShake256Asm returns an assembly implementation of SHAKE-256 if available, +// otherwise it returns nil. +func newShake256Asm() ShakeHash { + return nil +} diff --git a/cryptography/sha3/testdata/keccakKats.json.deflate b/cryptography/sha3/testdata/keccakKats.json.deflate new file mode 100644 index 0000000..7a94c2f Binary files /dev/null and b/cryptography/sha3/testdata/keccakKats.json.deflate differ diff --git a/cryptography/sha3/xor.go b/cryptography/sha3/xor.go new file mode 100644 index 0000000..079b650 --- /dev/null +++ b/cryptography/sha3/xor.go @@ -0,0 +1,23 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build !amd64,!386,!ppc64le appengine + +package sha3 + +// A storageBuf is an aligned array of maxRate bytes. +type storageBuf [maxRate]byte + +func (b *storageBuf) asBytes() *[maxRate]byte { + return (*[maxRate]byte)(b) +} + +var ( + xorIn = xorInGeneric + copyOut = copyOutGeneric + xorInUnaligned = xorInGeneric + copyOutUnaligned = copyOutGeneric +) + +const xorImplementationUnaligned = "generic" diff --git a/cryptography/sha3/xor_generic.go b/cryptography/sha3/xor_generic.go new file mode 100644 index 0000000..fd35f02 --- /dev/null +++ b/cryptography/sha3/xor_generic.go @@ -0,0 +1,28 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package sha3 + +import "encoding/binary" + +// xorInGeneric xors the bytes in buf into the state; it +// makes no non-portable assumptions about memory layout +// or alignment. +func xorInGeneric(d *state, buf []byte) { + n := len(buf) / 8 + + for i := 0; i < n; i++ { + a := binary.LittleEndian.Uint64(buf) + d.a[i] ^= a + buf = buf[8:] + } +} + +// copyOutGeneric copies ulint64s to a byte buffer. +func copyOutGeneric(d *state, b []byte) { + for i := 0; len(b) >= 8; i++ { + binary.LittleEndian.PutUint64(b, d.a[i]) + b = b[8:] + } +} diff --git a/cryptography/sha3/xor_unaligned.go b/cryptography/sha3/xor_unaligned.go new file mode 100644 index 0000000..a3d0686 --- /dev/null +++ b/cryptography/sha3/xor_unaligned.go @@ -0,0 +1,65 @@ +// Copyright 2015 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build amd64 386 ppc64le +// +build !appengine + +package sha3 + +import "unsafe" + +// A storageBuf is an aligned array of maxRate bytes. +type storageBuf [maxRate / 8]uint64 + +func (b *storageBuf) asBytes() *[maxRate]byte { + return (*[maxRate]byte)(unsafe.Pointer(b)) +} + +func xorInUnaligned(d *state, buf []byte) { + n := len(buf) + bw := (*[maxRate / 8]uint64)(unsafe.Pointer(&buf[0]))[: n/8 : n/8] + if n >= 72 { + d.a[0] ^= bw[0] + d.a[1] ^= bw[1] + d.a[2] ^= bw[2] + d.a[3] ^= bw[3] + d.a[4] ^= bw[4] + d.a[5] ^= bw[5] + d.a[6] ^= bw[6] + d.a[7] ^= bw[7] + d.a[8] ^= bw[8] + } + if n >= 104 { + d.a[9] ^= bw[9] + d.a[10] ^= bw[10] + d.a[11] ^= bw[11] + d.a[12] ^= bw[12] + } + if n >= 136 { + d.a[13] ^= bw[13] + d.a[14] ^= bw[14] + d.a[15] ^= bw[15] + d.a[16] ^= bw[16] + } + if n >= 144 { + d.a[17] ^= bw[17] + } + if n >= 168 { + d.a[18] ^= bw[18] + d.a[19] ^= bw[19] + d.a[20] ^= bw[20] + } +} + +func copyOutUnaligned(d *state, buf []byte) { + ab := (*[maxRate]uint8)(unsafe.Pointer(&d.a[0])) + copy(buf, ab[:]) +} + +var ( + xorIn = xorInUnaligned + copyOut = copyOutUnaligned +) + +const xorImplementationUnaligned = "unaligned" diff --git a/dvm/deterministic_random_number.go b/dvm/deterministic_random_number.go new file mode 100644 index 0000000..7a76c44 --- /dev/null +++ b/dvm/deterministic_random_number.go @@ -0,0 +1,68 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +import "encoding/binary" +import "golang.org/x/crypto/salsa20/salsa" + +import "github.com/deroproject/derohe/cryptography/crypto" + +/* this file implements a deterministic random number generator + the random number space is quite large but still unattackable, since the seeds are random + the seeds depend on the BLID and the TXID, if an attacker can somehow control the TXID, + he will not be able to control BLID +*/ + +type RND struct { + Key [32]byte + Pos uint64 // we will wrap around in 2^64 times but this is per TX,BLOCK,SCID +} + +// make sure 2 SCs cannot ever generate same series of random numbers +func Initialize_RND(SCID, BLID, TXID crypto.Hash) (r *RND) { + r = &RND{} + tmp := crypto.Keccak256(SCID[:], BLID[:], TXID[:]) + copy(r.Key[:], tmp[:]) + r.Pos = 1 // we start at 1 to eliminate an edge case + return // TODO we must reinitialize using blid and other parameters +} + +func (r *RND) Random() uint64 { + + var out [32]byte + var in [16]byte + var key [32]byte + + copy(key[:], r.Key[:]) + + binary.BigEndian.PutUint64(in[:], r.Pos) + + salsa.HSalsa20(&out, &in, &key, &in) + + deterministic_value := binary.BigEndian.Uint64(out[:]) + r.Pos++ + + return deterministic_value +} + +// range to (input-1) +func (r *RND) Random_MAX(input uint64) uint64 { + if input == 0 { + panic("RNG cannot generate RND with 0 as max") + } + return r.Random() % input +} diff --git a/dvm/deterministic_random_number_test.go b/dvm/deterministic_random_number_test.go new file mode 100644 index 0000000..89b4a03 --- /dev/null +++ b/dvm/deterministic_random_number_test.go @@ -0,0 +1,58 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +//import "fmt" +//import "reflect" +import "testing" + +import "github.com/deroproject/derohe/cryptography/crypto" + +// run the test +func Test_RND_execution(t *testing.T) { + + var SCID, BLID, TXID crypto.Hash + SCID[0] = 22 + rnd := Initialize_RND(SCID, BLID, TXID) + + //get a random number + result_initial := rnd.Random() + + // lets tweak , each parameter by a byte and check whether it affects the output + SCID[0] = 23 + if Initialize_RND(SCID, BLID, TXID).Random() == result_initial { + t.Fatalf("RND not dependent on SCID") + } + SCID[0] = 0 + + BLID[0] = 22 + if Initialize_RND(SCID, BLID, TXID).Random() == result_initial { + t.Fatalf("RND not dependent on BLID") + } + BLID[0] = 0 + + TXID[0] = 22 + if Initialize_RND(SCID, BLID, TXID).Random() == result_initial { + t.Fatalf("RND not dependent on TXID") + } + TXID[0] = 22 + + if Initialize_RND(SCID, BLID, TXID).Random_MAX(10000) >= 10000 { + t.Fatalf("RND cannot be generated within a range") + } + +} diff --git a/dvm/dvm.go b/dvm/dvm.go new file mode 100644 index 0000000..6afe955 --- /dev/null +++ b/dvm/dvm.go @@ -0,0 +1,1120 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +import "fmt" +import "text/scanner" +import "strings" +import "strconv" +import "unicode" +import "unicode/utf8" +import "go/ast" +import "go/parser" +import "go/token" +import "math" + +import "runtime/debug" +import "github.com/deroproject/derohe/cryptography/crypto" + +//import "github.com/deroproject/derohe/rpc" + +type Vtype int + +const ( + Invalid Vtype = iota // default is invalid + Uint64 // uint64 data type + String // string + Blob +) + +var replacer = strings.NewReplacer("< =", "<=", "> =", ">=", "= =", "==", "! =", "!=", "& &", "&&", "| |", "||", "< <", "<<", "> >", ">>", "< >", "!=") + +// Some global variables are always accessible, namely +// SCID TXID which installed the SC +// TXID current TXID under which this SC is currently executing +// BLID current BLID under which TXID is found, THIS CAN be used as deterministic RND Generator, if the SC needs secure randomness +// BL_HEIGHT current height of blockchain + +type Variable struct { + Name string `cbor:"N,omitempty" json:"N,omitempty"` + Type Vtype `cbor:"T,omitempty" json:"T,omitempty"` // we have only 4 data types + Value interface{} `cbor:"V,omitempty" json:"V,omitempty"` +} + +type Function struct { + Name string `cbor:"N,omitempty" json:"N,omitempty"` + Params []Variable `cbor:"P,omitempty" json:"P,omitempty"` + ReturnValue Variable `cbor:"R,omitempty" json:"R,omitempty"` + Lines map[uint64][]string `cbor:"L,omitempty" json:"L,omitempty"` + // map from line number to array index below + LinesNumberIndex map[uint64]uint64 `cbor:"LI,omitempty" json:"LI,omitempty"` // a map is used to avoid sorting/searching + LineNumbers []uint64 `cbor:"LN,omitempty" json:"LN,omitempty"` +} + +const LIMIT_interpreted_lines = 2000 // testnet has hardcoded limit +const LIMIT_evals = 11000 // testnet has hardcoded limit eval limit + +// each smart code is nothing but a collection of functions +type SmartContract struct { + Functions map[string]Function `cbor:"F,omitempty" json:"F,omitempty"` +} + +// we have a rudimentary line by line parser +// SC authors must make sure code coverage is 100 % +// we are doing away with AST +func ParseSmartContract(src_code string) (SC SmartContract, pos string, err error) { + + defer func() { + if r := recover(); r != nil { + err = fmt.Errorf("Recovered in function %+v", r) + } + }() + + var s scanner.Scanner + s.Init(strings.NewReader(src_code)) + s.Filename = "code" + s.Mode = scanner.ScanIdents | scanner.ScanFloats | scanner.ScanChars | scanner.ScanStrings | scanner.ScanRawStrings | scanner.SkipComments | scanner.ScanComments // skip comments + + skip_line := int32(-1) + var current_line int32 = -1 + var line_tokens []string + var current_function *Function + + SC.Functions = map[string]Function{} + + for tok := s.Scan(); tok != scanner.EOF; tok = s.Scan() { + pos := s.Position.String() + txt := s.TokenText() + + if strings.HasPrefix(txt, ";") || strings.HasPrefix(txt, "REM") { // skip line, if this is the first word + skip_line = int32(s.Position.Line) + } + if skip_line == int32(s.Position.Line) { + continue + } + + /*if strings.HasPrefix(txt, "//") || strings.HasPrefix(txt, "/*") { // skip comments + continue + }*/ + + process_token: + if current_line == -1 { + current_line = int32(s.Position.Line) + } + + if current_line == int32(s.Position.Line) { // collect a complete line + line_tokens = append(line_tokens, txt) + } else { // if new line found, process previous line + if err = parse_function_line(&SC, ¤t_function, line_tokens); err != nil { + return SC, pos, err + } + line_tokens = line_tokens[:0] + + current_line = -1 + goto process_token + } + // fmt.Printf("%s: %s line %+v\n", s.Position, txt, line_tokens) + } + + if len(line_tokens) > 0 { // last line is processed here + if err = parse_function_line(&SC, ¤t_function, line_tokens); err != nil { + return SC, pos, err + } + } + + if current_function != nil { + err = fmt.Errorf("EOF reached but End Function is missing \"%s\"", current_function.Name) + return SC, pos, err + } + + return +} + +// checks whether a function name is valid +// a valid name starts with a non digit and does not contain . +func check_valid_name(name string) bool { + r, size := utf8.DecodeRuneInString(name) + if r == utf8.RuneError || size == 0 { + return false + } + return unicode.IsLetter(r) +} + +func check_valid_type(name string) Vtype { + switch name { + case "Uint64": + return Uint64 + case "Blob": + return Blob + case "String": + return String + } + return Invalid +} + +// this will parse 1 line at a time, if there is an error, it is returned +func parse_function_line(SC *SmartContract, function **Function, line []string) (err error) { + pos := 0 + //fmt.Printf("parsing function line %+v\n", line) + + if *function == nil { //if no current function, only legal is Sub + if !strings.EqualFold(line[pos], "Function") { + return fmt.Errorf("Expecting declaration of function but found \"%s\"", line[0]) + } + pos++ + + var f Function + f.Lines = map[uint64][]string{} // initialize line map + f.LinesNumberIndex = map[uint64]uint64{} + + if len(line) < (pos + 1) { + return fmt.Errorf("function name missing") + } + + if !check_valid_name(line[pos]) { + return fmt.Errorf("function name \"%s\" contains invalid characters", line[pos]) + } + f.Name = line[pos] + + pos++ + if len(line) < (pos+1) || line[pos] != "(" { + return fmt.Errorf("function \"%s\" missing '('", f.Name) + } + + parse_params: // now lets parse function params, but lets filter out , + pos++ + if len(line) < (pos + 1) { + return fmt.Errorf("function \"%s\" missing function parameters", f.Name) + } + + if line[pos] == "," { + goto parse_params + } + if line[pos] == ")" { + // function does not have any parameters + // or all parameters have been parsed + + } else { // we must parse param name, param type as pairs + if len(line) < (pos + 2) { + return fmt.Errorf("function \"%s\" missing function parameters", f.Name) + } + + param_name := line[pos] + param_type := check_valid_type(line[pos+1]) + + if !check_valid_name(param_name) { + return fmt.Errorf("function name \"%s\", variable name \"%s\" contains invalid characters", f.Name, param_name) + } + + if param_type == Invalid { + return fmt.Errorf("function name \"%s\", variable type \"%s\" is invalid", f.Name, line[pos+1]) + } + f.Params = append(f.Params, Variable{Name: param_name, Type: param_type}) + + pos++ + goto parse_params + } + + pos++ + + // check if we have return value + if len(line) < (pos + 1) { // we do not have return value + f.ReturnValue.Type = Invalid + } else { + return_type := check_valid_type(line[pos]) + if return_type == Invalid { + return fmt.Errorf("function name \"%s\", return type \"%s\" is invalid", f.Name, line[pos]) + } + f.ReturnValue.Type = return_type + } + + *function = &f + return nil + } else if strings.EqualFold(line[pos], "End") && strings.EqualFold(line[pos+1], "Function") { + SC.Functions[(*function).Name] = **function + *function = nil + } else if strings.EqualFold(line[pos], "Function") { + return fmt.Errorf("Nested functions are not allowed") + } else { // add line to current function, provided line numbers are not duplicated, line numbers are mandatory + line_number, err := strconv.ParseUint(line[pos], 10, 64) + if err != nil { + return fmt.Errorf("Error Parsing line number \"%s\" in function \"%s\" ", line[pos], (*function).Name) + } + if line_number == 0 || line_number == math.MaxUint64 { + return fmt.Errorf("Error: line number cannot be %d in function \"%s\" ", line_number, (*function).Name) + } + + if _, ok := (*function).Lines[line_number]; ok { // duplicate line number + return fmt.Errorf("Error: duplicate line number within function \"%s\" ", (*function).Name) + } + if len((*function).LineNumbers) >= 1 && line_number < (*function).LineNumbers[len((*function).LineNumbers)-1] { + return fmt.Errorf("Error: line number must be ascending within function \"%s\" ", (*function).Name) + } + + line_copy := make([]string, len(line)-1, len(line)-1) + copy(line_copy, line[1:]) + (*function).Lines[line_number] = line_copy // we need to copy and add ( since line is reused) + (*function).LinesNumberIndex[line_number] = uint64(len((*function).LineNumbers)) + (*function).LineNumbers = append((*function).LineNumbers, line_number) + + // fmt.Printf("%s %d %+v\n", (*function).Name, line_number, line[0:]) + // fmt.Printf("%s %d %+v\n", (*function).Name, line_number, (*function).Lines[line_number]) + + } + + return nil +} + +// this will run a function from a loaded SC and execute it if possible +// it can run all internal functions +// parameters must be passed as strings +func runSmartContract_internal(SC *SmartContract, EntryPoint string, state *Shared_State, params map[string]interface{}) (result Variable, err error) { + // if smart contract does not contain function, trigger exception + function_call, ok := SC.Functions[EntryPoint] + if !ok { + err = fmt.Errorf("function \"%s\" is not available in SC", EntryPoint) + return + } + + var dvm DVM_Interpreter + dvm.SC = SC + dvm.f = function_call + dvm.Locals = map[string]Variable{} + + dvm.State = state // set state to execute current function + + // parse parameters, rename them, make them available as local variables + for _, p := range function_call.Params { + variable := Variable{Name: p.Name, Type: p.Type} + value, ok := params[p.Name] + if !ok { // necessary parameter is missing from arguments + err = fmt.Errorf("Argument \"%s\" is missing while invoking \"%s\"", p.Name, EntryPoint) + return + } + + // now lets parse the data,Uint64,Address,String,Blob + switch p.Type { + case Uint64: + variable.Value, err = strconv.ParseUint(value.(string), 0, 64) + if err != nil { + return + } + case String: + variable.Value = value.(string) + + case Blob: + variable.Value = value.(string) + //panic("address and blob cannot have parameters") + + } + + dvm.Locals[variable.Name] = variable + } + + // all variables have been collected, start interpreter + dvm.ReturnValue = dvm.f.ReturnValue // enforce return value to be of same type + + dvm.State.Monitor_recursion++ // higher recursion + + err = dvm.interpret_SmartContract() + if err != nil { + return + } + + result = dvm.ReturnValue + + return +} + +// it is similar to internal functions, however it enforces the condition that only Exportable functions are callable +// any function which has first character ASCII and upper case is considered an exported function +func RunSmartContract(SC *SmartContract, EntryPoint string, state *Shared_State, params map[string]interface{}) (result Variable, err error) { + // if smart contract does not contain function, trigger exception + + defer func() { + if r := recover(); r != nil { + err = fmt.Errorf("Recovered in function %+v", r) + fmt.Printf("%+v ", err) + fmt.Printf("%s\n", debug.Stack()) + } + //debug.Stack() + + }() + + r, size := utf8.DecodeRuneInString(EntryPoint) + + if r == utf8.RuneError || size == 0 { + return result, fmt.Errorf("Invalid function name") + + } + + if r >= unicode.MaxASCII { + return result, fmt.Errorf("Invalid function name, First character must be ASCII alphabet") + } + + if !unicode.IsLetter(r) { + return result, fmt.Errorf("Invalid function name, First character must be ASCII Letter") + } + + if !unicode.IsUpper(r) { + return result, fmt.Errorf("Invalid function name, First character must be Capital/Upper Case") + } + + // initialize RND + if state.Monitor_recursion == 0 { + state.RND = Initialize_RND(state.Chain_inputs.SCID, state.Chain_inputs.BLID, state.Chain_inputs.TXID) + //state.store = Initialize_TX_store() + state.DERO_Transfer = map[string]uint64{} + } + + result, err = runSmartContract_internal(SC, EntryPoint, state, params) + + if err != nil { + return result, err + } + if state.Monitor_recursion != 0 { // recursion must be zero at end + return result, fmt.Errorf("Invalid recursion level %d", state.Monitor_recursion) + } + + // if recursion level is zero, we should check return value and persist the state changes + + return result, err +} + +// this structure is all the inputs that are available to SC during execution +type Blockchain_Input struct { + SCID crypto.Hash // current smart contract which is executing + BLID crypto.Hash // BLID + TXID crypto.Hash // current TXID under which TX + Signer string // address which signed this, inn 33 byte form + BL_HEIGHT uint64 // current chain height under which current tx is valid + BL_TOPOHEIGHT uint64 // current block topo height which can be used to uniquely pinpoint the block +} + +// all DVMs triggered by the first call, will share this structure +// sharing this structure means RND number attacks are not possible +// all storage state is shared, this means something similar to solidity delegatecall +// this is necessary to prevent number of attacks +type Shared_State struct { + Persistance bool // whether the results will be persistant or it's just a demo/test call + + Chain_inputs *Blockchain_Input // all blockchain info is available here + + DERO_Balance uint64 // DERO balance of this smart contract, this is loaded + // this includes any DERO that has arrived with this TX + DERO_Received uint64 // amount of DERO received with this TX + Token_Received uint64 // token received + + DERO_Transfer map[string]uint64 // any DERO that this TX wants to send OUT + // transfers are only processed after the contract has terminated successfully + + RND *RND // this is initialized only once while invoking entrypoint + Store *TX_Storage // mechanism to access a data store, can discard changes + + Monitor_recursion int64 // used to control recursion amount 64 calls are more than necessary + Monitor_lines_interpreted int64 // number of lines interpreted + Monitor_ops int64 // number of ops evaluated, for expressions, variables + +} + +type DVM_Interpreter struct { + SCID string + SC *SmartContract + EntryPoint string + f Function + IP uint64 // current line number + ReturnValue Variable // Result of current function call + Locals map[string]Variable // all local variables + + Chain_inputs *Blockchain_Input // all blockchain info is available here + + State *Shared_State // all shared state between DVM is available here + + RND *RND // this is initialized only once while invoking entrypoint + + store *TX_Storage // mechanism to access a data store, can discard changes + +} + +func (i *DVM_Interpreter) incrementIP(newip uint64) (line []string, err error) { + var ok bool +try_again: + + // increase cost here + + if newip == 0 { // we are simply falling through + index := i.f.LinesNumberIndex[i.IP] // find the pos in the line numbers and find the current line_number + index++ + if i.IP == 0 { + index = 0 // start from first line + } + if uint64(len(i.f.LineNumbers)) <= index { // if function does not contain more lines to execute, return + err = fmt.Errorf("No lines after line number (%d) in SC %s in function %s", i.IP, i.SCID, i.f.Name) + return + } + + i.IP = i.f.LineNumbers[index] + + } else { // we have a GOTO and must jump to the line numbr mentioned + i.IP = newip + } + line, ok = i.f.Lines[i.IP] + if !ok { + err = fmt.Errorf("No such line number (%d) in SC %s in function %s", i.IP, i.SCID, i.f.Name) + return + } + i.State.Monitor_lines_interpreted++ // increment line interpreted + + if len(line) == 0 { // increment to next line + goto try_again + } + return +} + +// this runs a smart contract function with specific params +func (i *DVM_Interpreter) interpret_SmartContract() (err error) { + + newIP := uint64(0) + for { + var line []string + line, err = i.incrementIP(newIP) + if err != nil { + return + } + + newIP = 0 // this is necessary otherwise, it will trigger an infinite loop in the case given below + + /* + * Function SetOwner(value Uint64, newowner String) Uint64 + 10 IF LOAD("owner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 STORE("owner",newowner) + 40 RETURN 0 + End Function + */ + + if i.State.Monitor_lines_interpreted > LIMIT_interpreted_lines { + panic(fmt.Sprintf("%d lines interpreted, reached limit %d", LIMIT_interpreted_lines, LIMIT_interpreted_lines)) + } + + //fmt.Printf("interpreting line %+v\n", line) + + //fmt.Printf("received line to interpret %+v err\n", line, err) + switch { + case strings.EqualFold(line[0], "DIM"): + newIP, err = i.interpret_DIM(line[1:]) + case strings.EqualFold(line[0], "LET"): + newIP, err = i.interpret_LET(line[1:]) + case strings.EqualFold(line[0], "GOTO"): + newIP, err = i.interpret_GOTO(line[1:]) + case strings.EqualFold(line[0], "IF"): + newIP, err = i.interpret_IF(line[1:]) + case strings.EqualFold(line[0], "RETURN"): + newIP, err = i.interpret_RETURN(line[1:]) + + //ability to print something for debugging purpose + case strings.EqualFold(line[0], "PRINT"): + fallthrough + case strings.EqualFold(line[0], "PRINTF"): + newIP, err = i.interpret_PRINT(line[1:]) + + // if we are here, the first part is unknown + + default: + + // we should try to evaluate expression and make sure it's a function call + // now lets evaluate the expression + + expr, err1 := parser.ParseExpr(replacer.Replace(strings.Join(line, " "))) + if err1 != nil { + err = err1 + return + } + + if _, ok := expr.(*ast.CallExpr); !ok { + return fmt.Errorf("not a function call line %+v\n", line) + } + i.eval(expr) + + } + + if err != nil { + err = fmt.Errorf("err while interpreting line %+v err %s\n", line, err) + return + } + if newIP == math.MaxUint64 { + break + } + } + return +} + +// this is very limited and can be used print only variables +func (dvm *DVM_Interpreter) interpret_PRINT(args []string) (newIP uint64, err error) { + var variable Variable + var ok bool + if len(args) > 0 { + params := []interface{}{} + for i := 1; i < len(args); i++ { + if variable, ok = dvm.Locals[args[i]]; !ok { // TODO what about printing globals + /*if variable,ok := dvm.Locals[exp.Name];!ok{ + + }*/ + + } + if ok { + params = append(params, variable.Value) + } else { + params = append(params, fmt.Sprintf("unknown variable %s", args[i])) + } + } + + _, err = fmt.Printf(strings.Trim(args[0], "\"")+"\n", params...) + } + return +} + +// process DIM line +func (dvm *DVM_Interpreter) interpret_DIM(line []string) (newIP uint64, err error) { + + if len(line) <= 2 || !strings.EqualFold(line[len(line)-2], "as") { + return 0, fmt.Errorf("Invalid DIM syntax") + } + + // check last data type + data_type := check_valid_type(line[len(line)-1]) + if data_type == Invalid { + return 0, fmt.Errorf("function name \"%s\", No such Data type \"%s\"", dvm.f.Name, line[len(line)-1]) + } + + for i := 0; i < len(line)-2; i++ { + if line[i] != "," { // ignore separators + + if !check_valid_name(line[i]) { + return 0, fmt.Errorf("function name \"%s\", variable name \"%s\" contains invalid characters", dvm.f.Name, line[i]) + } + + // check whether variable is already defined + if _, ok := dvm.Locals[line[i]]; ok { + return 0, fmt.Errorf("function name \"%s\", variable name \"%s\" contains invalid characters", dvm.f.Name, line[i]) + } + + // all data variables are pre-initialized + + switch data_type { + case Uint64: + dvm.Locals[line[i]] = Variable{Name: line[i], Type: Uint64, Value: uint64(0)} + case String: + dvm.Locals[line[i]] = Variable{Name: line[i], Type: String, Value: ""} + case Blob: + dvm.Locals[line[i]] = Variable{Name: line[i], Type: Blob, Value: ""} + // return 0, fmt.Errorf("function name \"%s\", variable name \"%s\" blobs are currently not supported", dvm.f.Name, line[i]) + + } + // fmt.Printf("Initialising variable %s %+v\n",line[i],dvm.Locals[line[i]]) + + } + } + + return +} + +// process LET statement +func (dvm *DVM_Interpreter) interpret_LET(line []string) (newIP uint64, err error) { + + if len(line) <= 2 || !strings.EqualFold(line[1], "=") { + err = fmt.Errorf("Invalid LET syntax") + return + } + + if _, ok := dvm.Locals[line[0]]; !ok { + err = fmt.Errorf("function name \"%s\", variable name \"%s\" is used without definition", dvm.f.Name, line[0]) + return + } + result := dvm.Locals[line[0]] + + expr, err := parser.ParseExpr(strings.Join(line[2:], " ")) + if err != nil { + return + } + + expr_result := dvm.eval(expr) + //fmt.Printf("expression %s = %+v\n", line[0],expr_result) + + //fmt.Printf(" %+v \n", dvm.Locals[line[0]]) + switch result.Type { + case Uint64: + result.Value = expr_result.(uint64) + case String: + result.Value = expr_result.(string) + + case Blob: + result.Value = expr_result // FIXME address validation should be provided + } + + dvm.Locals[line[0]] = result + // fmt.Printf(" %+v \n", dvm.Locals[line[0]]) + + return +} + +// process GOTO line +func (dvm *DVM_Interpreter) interpret_GOTO(line []string) (newIP uint64, err error) { + + if len(line) != 1 { + err = fmt.Errorf("GOTO contains 1 mandatory line number as argument") + return + } + + newIP, err = strconv.ParseUint(line[0], 0, 64) + if err != nil { + return + } + + if newIP == 0 || newIP == math.MaxUint64 { + return 0, fmt.Errorf("GOTO has invalid line number \"%d\"", newIP) + } + return +} + +// process IF line +// IF has two forms vis x,y are line numbers +// IF expr THEN GOTO x +// IF expr THEN GOTO x ELSE GOTO y +func (dvm *DVM_Interpreter) interpret_IF(line []string) (newIP uint64, err error) { + + thenip := uint64(0) + elseip := uint64(0) + + // first form of IF + if len(line) >= 4 && strings.EqualFold(line[len(line)-3], "THEN") && strings.EqualFold(line[len(line)-2], "GOTO") { + + thenip, err = strconv.ParseUint(line[len(line)-1], 0, 64) + if err != nil { + return + } + line = line[:len(line)-3] + + } else if len(line) >= 7 && strings.EqualFold(line[len(line)-6], "THEN") && strings.EqualFold(line[len(line)-5], "GOTO") && strings.EqualFold(line[len(line)-3], "ELSE") && strings.EqualFold(line[len(line)-2], "GOTO") { + + thenip, err = strconv.ParseUint(line[len(line)-4], 0, 64) + if err != nil { + return + } + + elseip, err = strconv.ParseUint(line[len(line)-1], 0, 64) + if err != nil { + return + } + + if elseip == 0 || elseip == math.MaxUint64 { + return 0, fmt.Errorf("ELSE GOTO has invalid line number \"%d\"", thenip) + } + + line = line[:len(line)-6] + } else { + err = fmt.Errorf("Invalid IF syntax") + return + } + + if thenip == 0 || thenip == math.MaxUint64 { + return 0, fmt.Errorf("THEN GOTO has invalid line number \"%d\"", thenip) + } + + // now lets evaluate the expression + + expr, err := parser.ParseExpr(replacer.Replace(strings.Join(line, " "))) + if err != nil { + return + } + + expr_result := dvm.eval(expr) + //fmt.Printf("if %d %T expr( %s)\n", expr_result, expr_result, replacer.Replace(strings.Join(line, " "))) + if result, ok := expr_result.(uint64); ok { + if result != 0 { + newIP = thenip + } else { + newIP = elseip + } + } else { + + err = fmt.Errorf("Invalid IF expression \"%s\"", replacer.Replace(strings.Join(line, " "))) + } + + return + +} + +// process RETURN line +func (dvm *DVM_Interpreter) interpret_RETURN(line []string) (newIP uint64, err error) { + + if dvm.ReturnValue.Type == Invalid { + if len(line) != 0 { + err = fmt.Errorf("function name \"%s\" cannot return anything", dvm.f.Name) + return + } + + dvm.State.Monitor_recursion-- // lower recursion + newIP = math.MaxUint64 // simple return + return + } + + if len(line) == 0 { + err = fmt.Errorf("function name \"%s\" should return a value", dvm.f.Name) + return + } + + // we may be returning an expression which must be solved + expr, err := parser.ParseExpr(replacer.Replace(strings.Join(line, " "))) + if err != nil { + return + } + + expr_result := dvm.eval(expr) + //fmt.Printf("expression %+v %T\n", expr_result, expr_result) + + switch dvm.ReturnValue.Type { + case Uint64: + dvm.ReturnValue.Value = expr_result.(uint64) + case String: + dvm.ReturnValue.Value = expr_result.(string) + case Blob: + dvm.ReturnValue.Value = expr_result.(string) + } + + dvm.State.Monitor_recursion-- // lower recursion + newIP = math.MaxUint64 // simple return + + return +} + +// only returns identifiers +func (dvm *DVM_Interpreter) eval_identifier(exp ast.Expr) string { + + switch exp := exp.(type) { + case *ast.Ident: // it's a variable, + return exp.Name + default: + panic("expecting identifier") + + } + +} + +func (dvm *DVM_Interpreter) eval(exp ast.Expr) interface{} { + + dvm.State.Monitor_ops++ // maintain counter + + if dvm.State.Monitor_ops > LIMIT_evals { + panic(fmt.Sprintf("%d lines interpreted, evals reached limit %d", dvm.State.Monitor_lines_interpreted, LIMIT_evals)) + } + + //fmt.Printf("exp %+v %T\n", exp, exp) + switch exp := exp.(type) { + case *ast.ParenExpr: + return dvm.eval(exp.X) + + case *ast.UnaryExpr: // there are 2 unary operators, one is binary NOT , second is logical not + switch exp.Op { + case token.XOR: + return ^(dvm.eval(exp.X).(uint64)) + case token.NOT: + x := dvm.eval(exp.X) + switch x := x.(type) { + case uint64: + return ^x + case string: + if IsZero(x) == 1 { + return uint64(1) + } + return uint64(0) + + } + } + + case *ast.BinaryExpr: + return dvm.evalBinaryExpr(exp) + case *ast.Ident: // it's a variable, + if _, ok := dvm.Locals[exp.Name]; !ok { + panic(fmt.Sprintf("function name \"%s\", variable name \"%s\" is used without definition", dvm.f.Name, exp.Name)) + + } + //fmt.Printf("value %s %d\n",exp.Name, dvm.Locals[exp.Name].Value) + return dvm.Locals[exp.Name].Value + + // there are 2 types of calls, one within the smartcontract + // other one crosses smart contract boundaries + case *ast.CallExpr: + func_name := dvm.eval_identifier(exp.Fun) + //fmt.Printf("Call expression %+v %s \"%s\" \n",exp,exp.Fun, func_name) + // if call is internal + // + + // try to handle internal functions, SC function cannot overide internal functions + if ok, result := dvm.Handle_Internal_Function(exp, func_name); ok { + return result + } + function_call, ok := dvm.SC.Functions[func_name] + if !ok { + panic(fmt.Sprintf("Unknown function called \"%s\"", exp.Fun)) + } + if len(function_call.Params) != len(exp.Args) { + panic(fmt.Sprintf("function \"%s\" called with incorrect number of arguments , expected %d , actual %d", func_name, len(function_call.Params), len(exp.Args))) + } + + arguments := map[string]interface{}{} + for i, p := range function_call.Params { + switch p.Type { + case Uint64: + arguments[p.Name] = fmt.Sprintf("%d", dvm.eval(exp.Args[i]).(uint64)) + case String: + arguments[p.Name] = dvm.eval(exp.Args[i]).(string) + + case Blob: + arguments[p.Name] = dvm.eval(exp.Args[i]).(string) + } + } + + // allow calling unexported functions + result, err := runSmartContract_internal(dvm.SC, func_name, dvm.State, arguments) + if err != nil { + panic(err) + } + if function_call.ReturnValue.Type != Invalid { + return result.Value + } + return nil + + case *ast.BasicLit: + switch exp.Kind { + case token.INT: + i, err := strconv.ParseUint(exp.Value, 0, 64) + if err != nil { + panic(err) + } + return i + case token.STRING: + unquoted, err := strconv.Unquote(exp.Value) + if err != nil { + panic(err) + } + return unquoted + } + default: + panic(fmt.Sprintf("Unhandled expression type %+v", exp)) + + } + + panic("We should never reach here while evaluating expressions") + return 0 +} + +// this can be used to check whether variable has a default value +// for uint64 , it is 0 +// for string , it is "" +// TODO Address, Blob +func IsZero(value interface{}) uint64 { + switch v := value.(type) { + case uint64: + if v == 0 { + return 1 + } + case string: + if v == "" { + return 1 + } + + default: + panic("IsZero not being handled") + + } + + return 0 +} + +func (dvm *DVM_Interpreter) evalBinaryExpr(exp *ast.BinaryExpr) interface{} { + + left := dvm.eval(exp.X) + right := dvm.eval(exp.Y) + + //fmt.Printf("left '%+v %T' %+v right '%+v %T'\n", left, left, exp.Op, right, right) + + // special case to append uint64 to strings + if fmt.Sprintf("%T", left) == "string" && fmt.Sprintf("%T", right) == "uint64" { + return left.(string) + fmt.Sprintf("%d", right) + } + + if fmt.Sprintf("%T", left) != fmt.Sprintf("%T", right) { + panic(fmt.Sprintf("Expressions cannot be different type(String/Uint64) left (val %+v %+v) right (%+v %+v)", left, exp.X, right, exp.Y)) + } + + // logical ops are handled differently + switch exp.Op { + case token.LAND: + if (IsZero(left) == 0) && (IsZero(right) == 0) { // both sides should be set + return uint64(1) + } + + return uint64(0) + case token.LOR: + //fmt.Printf("left %d right %d\n", left,right) + //fmt.Printf("left %v right %v\n", (IsZero(left) != 0),(IsZero(right) != 0)) + if (IsZero(left) == 0) || (IsZero(right) == 0) { + return uint64(1) + } + return uint64(0) + + } + + // handle string operands + if fmt.Sprintf("%T", left) == "string" { + left_string := left.(string) + right_string := right.(string) + + switch exp.Op { + case token.ADD: + return left_string + right_string + case token.EQL: + if left_string == right_string { + return uint64(1) + } + return uint64(0) + case token.NEQ: + if left_string != right_string { + return uint64(1) + } + return uint64(0) + default: + panic(fmt.Sprintf("String data type only support addition operation ('%s') not supported", exp.Op)) + } + + } + + left_uint64 := left.(uint64) + right_uint64 := right.(uint64) + + switch exp.Op { + case token.ADD: + return left_uint64 + right_uint64 // TODO : can we add rounding case here and raise exception + case token.SUB: + return left_uint64 - right_uint64 // TODO : can we add rounding case here and raise exception + case token.MUL: + return left_uint64 * right_uint64 + case token.QUO: + return left_uint64 / right_uint64 + case token.REM: + return left_uint64 % right_uint64 + + //bitwise ops + case token.AND: + return left_uint64 & right_uint64 + case token.OR: + return left_uint64 | right_uint64 + case token.XOR: + return left_uint64 ^ right_uint64 + case token.SHL: + return left_uint64 << right_uint64 + case token.SHR: + return left_uint64 >> right_uint64 + + case token.EQL: + if left_uint64 == right_uint64 { + return uint64(1) + } + case token.NEQ: + if left_uint64 != right_uint64 { + return uint64(1) + } + case token.LEQ: + if left_uint64 <= right_uint64 { + return uint64(1) + } + case token.GEQ: + if left_uint64 >= right_uint64 { + return uint64(1) + } + case token.LSS: + if left_uint64 < right_uint64 { + return uint64(1) + } + case token.GTR: + if left_uint64 > right_uint64 { + return uint64(1) + } + default: + panic("This operation cannot be handled") + } + return uint64(0) +} + +/* +func main() { + + const src = ` + Function HelloWorld(s Uint64) Uint64 + + 5 + 10 Dim x1, x2 as Uint64 + 20 LET x1 = 3 + 25 LET x1 = 3 + 5 - 1 + 27 LET x2 = x1 + 3 + 28 RETURN HelloWorld2(s*s) + 30 Printf "x1=%d x2=%d s = %d" x1 x2 s + 35 IF x1 == 7 THEN GOTO 100 ELSE GOTO 38 + 38 Dim y1, y2 as String + 40 LET y1 = "first string" + "second string" + + + 60 GOTO 100 + 80 GOTO 10 + 100 RETURN 0 + 500 LET y = 45 + 501 y = 45 + + End Function + + + Function HelloWorld2(s Uint64) Uint64 + + 900 Return s + 950 y = 45 + // Comment begins at column 5. + + ; This line should not be included in the output. +REM jj + + + +7000 let x.ku[1+1]=0x55 +End Function + +` + + // we should be build an AST here + + sc, pos, err := ParseSmartContract(src) + if err != nil { + fmt.Printf("Error while parsing smart contract pos %s err : %s\n", pos, err) + return + } + + result, err := RunSmartContract(&sc, "HelloWorld", map[string]interface{}{"s": "9999"}) + + fmt.Printf("result %+v err %s\n", result, err) + +} +*/ diff --git a/dvm/dvm_execution_test.go b/dvm/dvm_execution_test.go new file mode 100644 index 0000000..155364a --- /dev/null +++ b/dvm/dvm_execution_test.go @@ -0,0 +1,1757 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +import "fmt" +import "reflect" +import "testing" + +//import "github.com/deroproject/derosuite/crypto" + +var execution_tests = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "demo 1", + `Function TestRun(s Uint64) Uint64 + 10 Return s + End Function + `, + "TestRun", + map[string]interface{}{"s": "8"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, + { + "invalid return expression", + `Function TestRun(s Uint64) Uint64 + 10 Return 1s + End Function + `, + "TestRun", + map[string]interface{}{"s": "8"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function with 2 params", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 + a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "4", "a2": "4"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function with 2 string params", + `Function TestRun(a1 String,a2 String) String + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 + a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "4", "a2": "4"}, + nil, + Variable{Type: String, Value: "44"}, + }, + + // test all arithmetic operations + { + "valid function testing substraction ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 - a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "12", "a2": "4"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing multiplication ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 * a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "4"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing division ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 / a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "25", "a2": "3"}, // it is 25 to confirm we are doing integer division + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing modulus ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 % a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "35", "a2": "9"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing SHL ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 << a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "4", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing SHR ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 >> a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "32", "a2": "2"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing OR ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 | a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "8", "a2": "8"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing AND ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 & a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "9", "a2": "10"}, + nil, + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "valid function testing NOT ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return !a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "9", "a2": "10"}, + nil, + Variable{Type: Uint64, Value: uint64(18446744073709551606)}, //NOT 9 == 18446744073709551606 + }, { + "valid function testing ^XOR ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return ^a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "9", "a2": "10"}, + nil, + Variable{Type: Uint64, Value: uint64(18446744073709551606)}, //NOT 9 == 18446744073709551606 + }, { + "valid function testing XOR ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 ^ a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "60", "a2": "13"}, + nil, + Variable{Type: Uint64, Value: uint64(49)}, + }, { + "valid function testing || ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 || a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "0", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "valid function testing && 1 ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 && a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "0", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(0)}, + }, { + "valid function testing && 2", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return (a1 && a2) + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(1)}, + }, + + { + "valid function testing && 3", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 + 30 return 0 || (a1 && a2) + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(1)}, + }, + { + "valid function testing LET ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "valid function testing IF THEN form1 fallthrough", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "valid function testing IF THEN form1 THEN case", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(0)}, + }, + { + "valid function testing IF THEN ELSE form1 THEN case", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 ELSE GOTO 20 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(0)}, + }, { + "valid function testing IF THEN ELSE form1 ELSE case", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 ELSE GOTO 20 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "valid function testing != success ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 != 3 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, + { + "valid function testing != failed", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 != 3 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "3", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, + + { + "valid function testing <> ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 <> 3 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "invalid operator testing = ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 = 3 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(99)}, + }, + { + "valid function testing > success ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 > 1 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing > failed ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if 1 > a1 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing >= success", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 >= 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing >= failed", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 >= 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing < success ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 < 3 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing < failed ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 < 3 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "5", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing <= success ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 <= 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing <= success ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 <= 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "4", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing string == success", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 == a2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "asdf", "a2": "asdf"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing string == success", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 == "asdf" then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "asdf", "a2": "asdf"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing string == failed", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 == a2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "asdf", "a2": "asdf1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing !string success ", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if !a1 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "", "a2": "asdf1"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing !string fail ", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if !a1 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "a1", "a2": "asdf1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing string != ", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 != a2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "asdf", "a2": "asdfz"}, + nil, + Variable{Type: Uint64, Value: uint64(99)}, + }, { + "valid function testing LOR ", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 != a2 || a1 != a2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "asdf", "a2": "asdf"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing comparision of uint64 /string ", + `Function TestRun(a1 String,a2 String) Uint64 + 10 dim s1, s2 as Uint64 + 13 LET s1 = 99 + 15 if a1 != s1 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "asdf", "a2": "asdfz"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(99)}, + }, + + { + "valid function arbitrary function evaluation", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 fact_recursive(10) + 20 LET s1 = fact_recursive(10) + 30 return s1 + End Function + Function fact_recursive(s Uint64) Uint64 + 10 IF s == 1 THEN GOTO 20 ELSE GOTO 30 + 20 RETURN 1 + 30 RETURN s * fact_recursive(s -1) + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(3628800)}, + }, + + { + "Invalid function with 2 string params substractions", + `Function TestRun(a1 String,a2 String) String + 10 dim s1, s2 as Uint64 + 20 + 30 return a1 - a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "4", "a2": "4"}, + fmt.Errorf("dummy"), + Variable{Type: String, Value: "44"}, + }, +} + +// run the test +func Test_execution(t *testing.T) { + for _, test := range execution_tests { + + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + + } +} + +// ensure 100% coverage of IF +var execution_tests_if = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "valid function testing IF THEN form1 fallthrough", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "valid function testing IF THEN form1 THEN case", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(0)}, + }, + { + "valid function testing IF THEN ELSE form1 THEN case", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 ELSE GOTO 20 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "2", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(0)}, + }, { + "valid function testing IF THEN ELSE form1 ELSE case", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 ELSE GOTO 20 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, + + { + "invalid function testing IF THEN form1 malformed if then", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 = != 2 thenn GOTO 30 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing IF THEN form1 malformed else", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 30 ELSEE GOTO 20 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing IF THEN form1 malformed then line number", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 0 ELSE GOTO 20 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing IF THEN form1 malformed then else number", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 20 ELSE GOTO 0 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing IF THEN form1 malformed unparseable then line number", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO ewr + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing IF THEN ELSE form1 malformed unparseable then line number", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO ewr ELSE GOTO 20 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing IF THEN form1 malformed unparseable else number", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 20 ELSE GOTO ewr + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + { + "invalid function testing IF THEN form1 unknownelse number", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 if a1 == 2 then GOTO 20 ELSE GOTO 43535 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing IF THEN invalid IF expression", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 13 dim x1 as String + 15 if x1 then GOTO 20 ELSE GOTO 43535 + 20 RETURN 2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "77", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, +} + +// run the test +func Test_IF_execution(t *testing.T) { + for _, test := range execution_tests_if { + + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + + } +} + +// ensure 100% coverage of DIM +var execution_tests_dim = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "valid function testing DIM ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 GOTO 20 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing DIM address", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Address + 15 GOTO 30 + 17 RETURN 0 + 20 + 30 return a1 + a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing DIM blob", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Blob + 15 GOTO 30 + 17 RETURN 0 + 20 + 30 return a1 + a2 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid dim expression collision between arguments and local variable", + `Function TestRun(s Uint64) Uint64 + 10 dim s as Uint64 + 20 + 30 return 8 + End Function + `, + "TestRun", + map[string]interface{}{"s": "8"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "invalid dim expression invalid variable name", + `Function TestRun(s Uint64) Uint64 + 10 dim 1s as Uint64 + 20 + 30 return 8 + End Function + `, + "TestRun", + map[string]interface{}{"s": "8"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "invalid dim expression invalid 2nd variable name", + `Function TestRun(s Uint64) Uint64 + 10 dim s1,2s2 as Uint64 + 20 + 30 return 8 + End Function + `, + "TestRun", + map[string]interface{}{"s": "8"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "invalid dim expression invalid dim syntax", + `Function TestRun(s Uint64) Uint64 + 10 dim tu ajs Uint64 + 20 + 30 return 8 + End Function + `, + "TestRun", + map[string]interface{}{"s": "8"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(8)}, + }, { + "invalid dim expression invalid dim syntax", + `Function TestRun(s Uint64) Uint64 + 10 dim tu as UUint64 + 20 + 30 return 8 + End Function + `, + "TestRun", + map[string]interface{}{"s": "8"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(8)}, + }, +} + +// run the test +func Test_DIM_execution(t *testing.T) { + for _, test := range execution_tests_dim { + + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + + } +} + +// ensure 100% coverage of LET +var execution_tests_let = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "valid function testing LET ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing LET Address", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 12 dim add1,add2 as Address + 13 let add1 = add2 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "valid function testing LET blob", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 12 dim add1, add2 as Blob + 13 let add1 = add2 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing LET ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 LET + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing LET undefined local variable", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 LET s3 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing LET malformed expression", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 20 LET s1 = ((a1) + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing LET putting int into string", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as String + 20 LET s1 = (a1) + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, +} + +// run the test +func Test_LET_execution(t *testing.T) { + for _, test := range execution_tests_let { + + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + + } +} + +// ensure 100% coverage of PRINT +var execution_tests_print = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "valid function testing PRINT ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 + 17 PRINT "%d %d" s1 s2 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing PRINT ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 + 17 PRINT "%d %d" s1 s2 s3 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, +} + +// run the test +func Test_PRINT_execution(t *testing.T) { + for _, test := range execution_tests_print { + + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + + } +} + +// generic cases of coding mistakes +var execution_tests_generic = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "invalid function testing Generic case if function does not return ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 + 17 PRINT "%d %d" s1 s2 + 20 LET s1 = a1 + a2 + // 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing Generic case if invalid expression evaluated ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 + 17 dummy (s1 s2 s3 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing Generic case if valid expression but not a function call ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 + 17 2 +3 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, + + // these case check callability of unexported functions etc + { + "valid function testing Invalid Rune ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + string([]byte{0x80}), // EntryPoint checking + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "valid function testing executing first non-ascii function ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + "☺☻TestRun", // EntryPoint checking + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "valid function testing executing first non-letter function", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + "1TestRun", // EntryPoint checking + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "valid function testing executing unexported function ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + "testRun", // EntryPoint checking + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "invalid function testing executing non-existing function ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + "TestRun1", // no function exists + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, + + { + "valid function testing parameter missing ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + "TestRun", + map[string]interface{}{"a3": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, + + { + "valid function testing Invalid parameter uint64 ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "-1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, + { + "valid function testing use unknown variable ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1*a3 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "valid function testing use uint64 larger than 64 bits ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1* 118446744073709551615 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, + + { + "valid function testing recursive FACTORIAL ", + `Function fact_recursive(s Uint64) Uint64 + 10 IF s == 1 THEN GOTO 20 ELSE GOTO 30 + 20 RETURN 1 + 30 RETURN s * fact_recursive(s -1) + End Function + Function TestRun(a1 Uint64) Uint64 + 10 dim result as Uint64 + 20 LET result = fact_recursive(a1) + 60 printf "FACTORIAL of %d = %d" s result + 70 RETURN result + End Function + `, + "TestRun", + map[string]interface{}{"a1": "10", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(3628800)}, + }, + + { + "invalid function testing paramter skipped ", + `Function fact_recursive(s Uint64) Uint64 + 10 IF s == 1 THEN GOTO 20 ELSE GOTO 30 + 20 RETURN 1 + 30 RETURN s * fact_recursive(s -1) + End Function + Function TestRun(a1 Uint64) Uint64 + 10 dim result as Uint64 + 20 LET result = fact_recursive() + 60 printf "FACTORIAL of %d = %d" s result + 70 RETURN result + End Function + `, + "TestRun", + map[string]interface{}{"a1": "10", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(3628800)}, + }, + { + "invalid function testing unknown function called ", + `Function fact_recursive(s Uint64) Uint64 + 10 IF s == 1 THEN GOTO 20 ELSE GOTO 30 + 20 RETURN 1 + 30 RETURN s * fact_recursive(s -1) + End Function + Function TestRun(a1 Uint64) Uint64 + 10 dim result as Uint64 + 20 LET result = fact_recursive_unknown(a1) + 60 printf "FACTORIAL of %d = %d" s result + 70 RETURN result + End Function + `, + "TestRun", + map[string]interface{}{"a1": "10", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(3628800)}, + }, + { + "invalid function testing error withing sub function call", + `Function fact_recursive(s Uint64) Uint64 + 10 IF s == 1 THEN GOTO 20 ELSE GOTO 30 + 20 RETURN 1 + 30 RETURN s * fact_recursive(s -1) * ( + End Function + Function TestRun(a1 Uint64) Uint64 + 10 dim result as Uint64 + 20 LET result = fact_recursive(a1) + 60 printf "FACTORIAL of %d = %d" s result + 70 RETURN result + End Function + `, + "TestRun", + map[string]interface{}{"a1": "10", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(3628800)}, + }, + + { + "valid function testing sub function call without return", + `Function dummy(s Uint64) + + 20 RETURN + End Function + Function TestRun(a1 Uint64) Uint64 + 10 dim result as Uint64 + 20 LET result = a1 + 60 dummy(a1) + 70 RETURN result + End Function + `, + "TestRun", + map[string]interface{}{"a1": "10", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(10)}, + }, + { + "valid function testing recursive FACTORIAL ", + `Function fact_recursive(s Uint64, a Address, b Blob, str String) Uint64 + 10 IF s == 1 THEN GOTO 20 ELSE GOTO 30 + 20 RETURN 1 + 30 RETURN s * fact_recursive(s -1,a,b,str) + End Function + Function TestRun(a1 Uint64,a Address, b Blob, str String) Uint64 + 10 dim result as Uint64 + 20 LET result = fact_recursive(a1,a,b,str) + 60 printf "FACTORIAL of %d = %d" s result + 70 RETURN result + End Function + `, + "TestRun", + map[string]interface{}{"a1": "10", "a2": "1", "a": "address param", "b": "blob param", "str": "str_param"}, + nil, + Variable{Type: Uint64, Value: uint64(3628800)}, + }, + { + "valid function testing recursive FACTORIAL ", + `Function fact_recursive(s Uint64, a Address, b Blob, str String) Uint64 + 10 IF s == 1 THEN GOTO 20 ELSE GOTO 30 + 20 RETURN 1 + 30 RETURN s * fact_recursive(s -1,a,b,str) + End Function + Function TestRun(a1 Uint64,a Address, b Blob, str String) Uint64 + 10 dim result as Uint64 + 20 LET result = fact_recursive(a1,a,b,str) + 60 printf "FACTORIAL of %d = %d" s result + 70 RETURN result + End Function + `, + "TestRun", + map[string]interface{}{"a1": "10", "a2": "1", "a": "address param", "b": "blob param", "str": "str_param"}, + nil, + Variable{Type: Uint64, Value: uint64(3628800)}, + }, +} + +// run the test +func Test_Generic_execution(t *testing.T) { + for _, test := range execution_tests_generic { + + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + + } +} + +// ensure 100% coverage of RETURN +var execution_tests_return = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "valid function testing RETURN uint64 ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "valid function testing RETURN String ", + `Function TestRun(a1 String,a2 Uint64) String + 30 return a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: String, Value: "1"}, + }, + { + "valid function testing RETURN Address ", + `Function TestRun(a1 Address,a2 Uint64) Address + 30 return a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Address, Value: "1"}, + }, { + "valid function testing RETURN Blob ", + `Function TestRun(a1 Blob,a2 Uint64) Blob + 30 return a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Blob, Value: "1"}, + }, { + "valid function testing non returning function returning nothing ", + `Function TestRun(a1 Uint64,a2 Uint64) + 30 return + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Invalid}, + }, + { + "valid function testing non returning function returning something ", + `Function TestRun(a1 Uint64,a2 Uint64) + 30 return a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: "1"}, + }, { + "invalid function testing RETURN uint64 ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, { + "invalid function testing RETURN contains unparseable function ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 30 return ( a1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(1)}, + }, +} + +// run the test +func Test_RETURN_execution(t *testing.T) { + for _, test := range execution_tests_return { + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + } +} + +// ensure 100% coverage of GOTO +var execution_tests_goto = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "valid function testing GOTO ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 GOTO 20 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing GOTO ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 GOTO qeee + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing GOTO ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 GOTO + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, { + "invalid function testing GOTO ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 GOTO 0 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return s1 + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + fmt.Errorf("dummy"), + Variable{Type: Uint64, Value: uint64(2)}, + }, +} + +// run the test +func Test_GOTO_execution(t *testing.T) { + for _, test := range execution_tests_goto { + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + } +} diff --git a/dvm/dvm_functions.go b/dvm/dvm_functions.go new file mode 100644 index 0000000..80437a5 --- /dev/null +++ b/dvm/dvm_functions.go @@ -0,0 +1,332 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +import "go/ast" +import "strings" +import "math/big" + +import "github.com/deroproject/derohe/rpc" +import "github.com/deroproject/derohe/cryptography/crypto" + +// this files defines external functions which can be called in DVM +// for example to load and store data from the blockchain and other basic functions + +// random number generator is the basis +// however, further investigation is needed if we would like to enable users to use pederson commitments +// they can be used like +// original SC developers delivers a pederson commitment to SC as external oracle +// after x users have played lottery, dev reveals the commitment using which the winner is finalised +// this needs more investigation +// also, more investigation is required to enable predetermined external oracles + +// this will handle all internal functions which may be required/necessary to expand DVM functionality +func (dvm *DVM_Interpreter) Handle_Internal_Function(expr *ast.CallExpr, func_name string) (handled bool, result interface{}) { + var err error + _ = err + switch { + + // TODO evaluate why not use a blackbox function which can be used for as many returns as possible + // the function should behave similar to how RDMSR intel instruction works. + // this can allow as future compatibility etc + case strings.EqualFold(func_name, "MAJOR_VERSION"): + if len(expr.Args) != 0 { // expression without limit + panic("MAJOR_VERSION expects no parameters") + } else { + return true, 0 + } + + case strings.EqualFold(func_name, "Load"): + if len(expr.Args) != 1 { + panic("Load function expects a single varible as parameter") + } + // evaluate the argument and use the result + key := dvm.eval(expr.Args[0]) + switch k := key.(type) { + + case uint64: + return true, dvm.Load(Variable{Type: Uint64, Value: k}) + case string: + return true, dvm.Load(Variable{Type: String, Value: k}) + default: + panic("This variable cannot be loaded") + } + case strings.EqualFold(func_name, "Exists"): + if len(expr.Args) != 1 { + panic("Exists function expects a single varible as parameter") + } + // evaluate the argument and use the result + key := dvm.eval(expr.Args[0]) + switch k := key.(type) { + + case uint64: + return true, dvm.Exists(Variable{Type: Uint64, Value: k}) + case string: + return true, dvm.Exists(Variable{Type: String, Value: k}) + default: + panic("This variable cannot be loaded") + } + + case strings.EqualFold(func_name, "Store"): + if len(expr.Args) != 2 { + panic("Store function expects 2 variables as parameter") + } + key_eval := dvm.eval(expr.Args[0]) + value_eval := dvm.eval(expr.Args[1]) + var key, value Variable + switch k := key_eval.(type) { + case uint64: + key = Variable{Type: Uint64, Value: k} + + case string: + key = Variable{Type: String, Value: k} + default: + panic("This variable cannot be stored") + } + + switch k := value_eval.(type) { + case uint64: + value = Variable{Type: Uint64, Value: k} + case string: + value = Variable{Type: String, Value: k} + default: + panic("This variable cannot be stored") + } + + dvm.Store(key, value) + return true, nil + + case strings.EqualFold(func_name, "RANDOM"): + if len(expr.Args) >= 2 { + panic("RANDOM function expects 0 or 1 number as parameter") + } + + if len(expr.Args) == 0 { // expression without limit + return true, dvm.State.RND.Random() + } + + range_eval := dvm.eval(expr.Args[0]) + switch k := range_eval.(type) { + case uint64: + return true, dvm.State.RND.Random_MAX(k) + default: + panic("This variable cannot be randomly generated") + } + case strings.EqualFold(func_name, "SCID"): + if len(expr.Args) != 0 { + panic("SCID function expects 0 parameters") + } + return true, dvm.State.Chain_inputs.SCID.String() + case strings.EqualFold(func_name, "BLID"): + if len(expr.Args) != 0 { + panic("BLID function expects 0 parameters") + } + return true, dvm.State.Chain_inputs.BLID.String() + case strings.EqualFold(func_name, "TXID"): + if len(expr.Args) != 0 { + panic("TXID function expects 0 parameters") + } + return true, dvm.State.Chain_inputs.TXID.String() + + case strings.EqualFold(func_name, "BLOCK_HEIGHT"): + if len(expr.Args) != 0 { + panic("BLOCK_HEIGHT function expects 0 parameters") + } + return true, dvm.State.Chain_inputs.BL_HEIGHT + case strings.EqualFold(func_name, "BLOCK_TOPOHEIGHT"): + if len(expr.Args) != 0 { + panic("BLOCK_TOPOHEIGHT function expects 0 parameters") + } + return true, dvm.State.Chain_inputs.BL_TOPOHEIGHT + + case strings.EqualFold(func_name, "SIGNER"): + if len(expr.Args) != 0 { + panic("SIGNER function expects 0 parameters") + } + return true, dvm.State.Chain_inputs.Signer + + case strings.EqualFold(func_name, "UPDATE_SC_CODE"): + if len(expr.Args) != 1 { + panic("UPDATE_SC_CODE function expects 1 parameters") + } + + code_eval := dvm.eval(expr.Args[0]) + switch k := code_eval.(type) { + case string: + dvm.State.Store.Keys[DataKey{Key: Variable{Type: String, Value: "C"}}] = Variable{Type: String, Value: k} // TODO verify code authenticity how + return true, uint64(1) + + return true, uint64(0) // fallthrough not supported in type switch + + default: + return true, uint64(0) + } + + case strings.EqualFold(func_name, "IS_ADDRESS_VALID"): // checks whether the address is valid DERO address + if len(expr.Args) != 1 { + panic("IS_ADDRESS_VALID function expects 1 parameters") + } + + addr_eval := dvm.eval(expr.Args[0]) + switch k := addr_eval.(type) { + case string: + + signer_raw := new(crypto.Point) + if err = signer_raw.DecodeCompressed([]byte(k)); err == nil { + return true, uint64(1) + } + return true, uint64(0) // fallthrough not supported in type switch + + default: + return true, uint64(0) + } + + case strings.EqualFold(func_name, "ADDRESS_RAW"): // returns a string of 33 bytes if everything is okay + if len(expr.Args) != 1 { + panic("ADDRESS_RAW function expects 1 parameters") + } + + addr_eval := dvm.eval(expr.Args[0]) + switch k := addr_eval.(type) { + case string: + if addr, err := rpc.NewAddress(k); err == nil { + return true, string(addr.Compressed()) + } + + return true, nil // fallthrough not supported in type switch + default: + return true, nil + } + + case strings.EqualFold(func_name, "ADDRESS_STRING"): // returns a DERO mainnet address if everything is okay + if len(expr.Args) != 1 { + panic("ADDRESS_STRING function expects 1 parameters") + } + + addr_eval := dvm.eval(expr.Args[0]) + switch k := addr_eval.(type) { + case string: + p := new(crypto.Point) + if err = p.DecodeCompressed([]byte(k)); err == nil { + + addr := rpc.NewAddressFromKeys(p) + return true, addr.String() + } + + return true, nil // fallthrough not supported in type switch + default: + return true, nil + } + + case strings.EqualFold(func_name, "SEND_DERO_TO_ADDRESS"): + if len(expr.Args) != 2 { + panic("SEND_DERO_TO_ADDRESS function expects 2 parameters") + } + + addr_eval := dvm.eval(expr.Args[0]) + amount_eval := dvm.eval(expr.Args[1]) + + p := new(crypto.Point) + if err = p.DecodeCompressed([]byte(addr_eval.(string))); err != nil { + panic("address must be valid DERO network address") + } + + if _, ok := amount_eval.(uint64); !ok { + panic("amount must be valid uint64") + } + + if amount_eval.(uint64) == 0 { + return true, amount_eval + } + + dvm.State.Store.SendExternal(dvm.State.Chain_inputs.SCID, addr_eval.(string), amount_eval.(uint64)) // add record for external transfer + + return true, amount_eval + + case strings.EqualFold(func_name, "DEROVALUE"): + if len(expr.Args) != 0 { // expression without limit + panic("DEROVALUE expects no parameters") + } else { + return true, dvm.State.DERO_Received + } + case strings.EqualFold(func_name, "TOKENVALUE"): + if len(expr.Args) != 0 { // expression without limit + panic("TOKENVALUE expects no parameters") + } else { + return true, dvm.State.Token_Received + } + + case strings.EqualFold(func_name, "ADD_VALUE"): + if len(expr.Args) != 2 { + panic("ADD_VALUE function expects 2 parameters") + } + + addr_eval := dvm.eval(expr.Args[0]) + amount_eval := dvm.eval(expr.Args[1]) + + p := new(crypto.Point) + if err = p.DecodeCompressed([]byte(addr_eval.(string))); err != nil { + panic("address must be valid DERO network address") + } + + if _, ok := amount_eval.(uint64); !ok { + panic("amount must be valid uint64") + } + + if amount_eval.(uint64) > 21*100000 { + panic("pls test with small amounts, for better debug reasons ") + } + + // if exists value, load it + var ebalance *crypto.ElGamal + if ebalance_bytes, found := dvm.State.Store.RawLoad([]byte(addr_eval.(string))); found { + ebalance = new(crypto.ElGamal).Deserialize(ebalance_bytes) + + } else { + + ebalance = crypto.ConstructElGamal(p.G1(), crypto.ElGamal_BASE_G) // init zero balance + + } + + ebalance = ebalance.Plus(new(big.Int).SetUint64(amount_eval.(uint64))) // add value to users balance homomorphically + + dvm.State.Store.RawStore([]byte(addr_eval.(string)), ebalance.Serialize()) + + return true, amount_eval + + } + return false, nil +} + +// the load/store functions are sandboxed and thus cannot affect any other SC storage +// loads a variable from store +func (dvm *DVM_Interpreter) Load(key Variable) interface{} { + var found uint64 + result := dvm.State.Store.Load(DataKey{SCID: dvm.State.Chain_inputs.SCID, Key: key}, &found) + return result.Value +} + +// whether a variable exists in store or not +func (dvm *DVM_Interpreter) Exists(key Variable) uint64 { + var found uint64 + dvm.State.Store.Load(DataKey{SCID: dvm.State.Chain_inputs.SCID, Key: key}, &found) + return found +} + +func (dvm *DVM_Interpreter) Store(key Variable, value Variable) { + dvm.State.Store.Store(DataKey{SCID: dvm.State.Chain_inputs.SCID, Key: key}, value) +} diff --git a/dvm/dvm_functions_test.go b/dvm/dvm_functions_test.go new file mode 100644 index 0000000..e974614 --- /dev/null +++ b/dvm/dvm_functions_test.go @@ -0,0 +1,132 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +//import "fmt" +import "reflect" +import "testing" + +import "github.com/deroproject/derohe/cryptography/crypto" + +// ensure 100% coverage of functions execution +var execution_tests_functions = []struct { + Name string + Code string + EntryPoint string + Args map[string]interface{} + Eerr error // execute error + result Variable // execution result +}{ + { + "valid function testing BLOCK_HEIGHT() ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 GOTO 20 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return BLOCK_HEIGHT() + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(5)}, + }, + { + "valid function testing BLOCK_TOPOHEIGHT() ", + `Function TestRun(a1 Uint64,a2 Uint64) Uint64 + 10 dim s1, s2 as Uint64 + 15 GOTO 20 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return BLOCK_TOPOHEIGHT() + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: Uint64, Value: uint64(9)}, + }, + { + "valid function testing SCID() ", + `Function TestRun(a1 Uint64,a2 Uint64) String + 10 dim s1, s2 as Uint64 + 15 GOTO 20 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return SCID() + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: String, Value: crypto.ZEROHASH.String()}, + }, { + "valid function testing BLID() ", + `Function TestRun(a1 Uint64,a2 Uint64) String + 10 dim s1, s2 as Uint64 + 15 GOTO 20 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return BLID() + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: String, Value: crypto.ZEROHASH.String()}, + }, { + "valid function testing TXID() ", + `Function TestRun(a1 Uint64,a2 Uint64) String + 10 dim s1, s2 as Uint64 + 15 GOTO 20 + 17 RETURN 0 + 20 LET s1 = a1 + a2 + 30 return TXID() + End Function + `, + "TestRun", + map[string]interface{}{"a1": "1", "a2": "1"}, + nil, + Variable{Type: String, Value: crypto.ZEROHASH.String()}, + }, +} + +// run the test +func Test_FUNCTION_execution(t *testing.T) { + for _, test := range execution_tests_functions { + sc, _, err := ParseSmartContract(test.Code) + if err != nil { + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected nil\nActual %s\n", test.Name, err) + } + + state := &Shared_State{Chain_inputs: &Blockchain_Input{BL_HEIGHT: 5, BL_TOPOHEIGHT: 9, SCID: crypto.ZEROHASH, + BLID: crypto.ZEROHASH, TXID: crypto.ZEROHASH}} + result, err := RunSmartContract(&sc, test.EntryPoint, state, test.Args) + switch { + case test.Eerr == nil && err == nil: + if !reflect.DeepEqual(result, test.result) { + t.Fatalf("Error while executing smart contract \"%s\"\nExpected result %v\nActual result %v\n", test.Name, test.result, result) + } + case test.Eerr != nil && err != nil: // pass + case test.Eerr == nil && err != nil: + fallthrough + case test.Eerr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Eerr, err) + } + } +} diff --git a/dvm/dvm_parse_test.go b/dvm/dvm_parse_test.go new file mode 100644 index 0000000..b101f23 --- /dev/null +++ b/dvm/dvm_parse_test.go @@ -0,0 +1,239 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +import "testing" +import "fmt" + +var evalList = []struct { + Name string + Code string + Perr error // parse error +}{ + // some basics + { + "demo 1", + `Function HelloWorld(s Uint64) Uint64 + 900 Return s + End Function + `, + nil, + }, { + "function beginning skipped", + `Functionq HelloWorld(s Uint64) Uint64 + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, + { + "Invalid function name", + `Function 1Hello(s Uint64) Uint64 + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "Invalid argument variable name", + `Function HelloWorld(1s Uint64) Uint64 + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "Invalid variable type", + `Function HelloWorld(a1 Uint64, a2 String1,) Uint64 + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "Invalid line number minimum", + `Function HelloWorld(s Uint64) Uint64 + 0 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "Invalid line number maximum", + `Function HelloWorld(s Uint64) Uint64 + 18446744073709551615 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "Invalid line number duplicate", + `Function HelloWorld(s Uint64) Uint64 + 10 Return s + 10 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "Invalid line number descending", + `Function HelloWorld(s Uint64) Uint64 + 10 Return s + 5 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "Function End missing", + `Function HelloWorld(s Uint64) Uint64 + 10 dim 1s as Uint64 + 20 Return s + Function + `, + fmt.Errorf("dummy"), + }, { + "Function Nesting now allowed", + `Function HelloWorld(s Uint64) Uint64 + 10 dim 1s as Uint64 + 20 Return s + Function HelloWorld() + + End Function + `, + fmt.Errorf("dummy"), + }, + { + "Function \" \" between arguments", + `Function HelloWorld(s Uint64 s2 String ) Uint64 + 10 dim s as Uint64 + 20 Return s + End Function + `, + nil, + }, + { + "Function , between arguments", + `Function HelloWorld(s Uint64 , s2 String ) Uint64 + 10 dim s as Uint64 + 20 Return s + End Function + `, + nil, + }, + { + "Missing end function", + `Function HelloWorld(s Uint64) Uint64 + 900 Return s + + `, + fmt.Errorf("dummy"), + }, { + "negative line number", + `Function HelloWorld(s Uint64) Uint64 + -900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "negative line number", + `Function HelloWorld(s Uint64) Uint64 + -900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "REM line number", + `Function HelloWorld(s Uint64) Uint64 + REM line number + 900 Return s + End Function + `, + nil, + }, { + "// comments are skipped", + `Function HelloWorld(s Uint64) Uint64 + // line number + 900 Return s + End Function + `, + nil, + }, { + "invalid function name", + `Function ` + string([]byte{0x80, 0x80, 0x80, 0x80, 0x80}) + `HelloWorld(s Uint64) Uint64 + // line number + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "function name missin", + `Function + // line number + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "function name missin (", + `Function HelloWorld s Uint64) Uint64 + // line number + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "function name missin )", + `Function HelloWorld ( + // line number + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "function name missin argument typ)", + `Function HelloWorld ( s1 + // line number + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, { + "function name unknonw argument type", + `Function HelloWorld ( s1 monkey ) + // line number + 900 Return + End Function + `, + fmt.Errorf("dummy"), + }, { + "Invalid return type", + `Function HelloWorld(s Uint64) Stream + 900 Return s + End Function + `, + fmt.Errorf("dummy"), + }, +} + +// run the test +func TestEval(t *testing.T) { + for _, test := range evalList { + _, _, err := ParseSmartContract(test.Code) + switch { + case test.Perr == nil && err == nil: // pass + case test.Perr != nil && err != nil: // pass + case test.Perr == nil && err != nil: + fallthrough + case test.Perr != nil && err == nil: + t.Fatalf("Error while parsing smart contract \"%s\"\nExpected %s\nActual %s\n", test.Name, test.Perr, err) + } + } +} diff --git a/dvm/dvm_store.go b/dvm/dvm_store.go new file mode 100644 index 0000000..8d17ded --- /dev/null +++ b/dvm/dvm_store.go @@ -0,0 +1,324 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +import "fmt" +import "encoding/binary" +import "github.com/deroproject/derohe/cryptography/crypto" + +const DVAL = "DERO_BALANCE" // DERO Values are stored in this variable +const CHANGELOG = "CHANGELOG" + +// this package exports an interface which is used by blockchain to persist/query data + +type DataKey struct { + SCID crypto.Hash // tx which created the the contract or contract ID + Key Variable +} + +type DataAtom struct { + Key DataKey + + Prev_Value Variable // previous Value if any + Value Variable // current value if any +} + +type TransferInternal struct { + Received []uint64 + Sent []uint64 +} + +// any external tranfers +type TransferExternal struct { + Address string `cbor:"A,omitempty" json:"A,omitempty"` // transfer to this blob + Amount uint64 `cbor:"V,omitempty" json:"V,omitempty"` // Amount in Atomic units +} + +type SC_Transfers struct { + BalanceAtStart uint64 // value at start + TransferI TransferInternal // all internal transfers, SC to other SC + TransferE []TransferExternal // all external transfers, SC to external wallets +} + +// all SC load and store operations will go though this +type TX_Storage struct { + DiskLoader func(DataKey, *uint64) Variable + DiskLoaderRaw func([]byte) ([]byte, bool) + SCID crypto.Hash + BalanceAtStart uint64 // at runtime this will be fed balance + Keys map[DataKey]Variable // this keeps the in-transit DB updates, just in case we have to discard instantly + RawKeys map[string][]byte + + Transfers map[crypto.Hash]SC_Transfers // all transfers ( internal/external ) +} + +var DVM_STORAGE_BACKEND DVM_Storage_Loader // this variable can be hijacked at runtime to offer different stores such as RAM/file/DB etc + +type DVM_Storage_Loader interface { + Load(DataKey, *uint64) Variable + Store(DataKey, Variable) + RawLoad([]byte) ([]byte, bool) + RawStore([]byte, []byte) +} + +// initialize tx store +func Initialize_TX_store() (tx_store *TX_Storage) { + tx_store = &TX_Storage{Keys: map[DataKey]Variable{}, RawKeys: map[string][]byte{}, Transfers: map[crypto.Hash]SC_Transfers{}} + return +} + +func (tx_store *TX_Storage) RawLoad(key []byte) (value []byte, found bool) { + value, found = tx_store.RawKeys[string(key)] + + if !found { + if tx_store.DiskLoaderRaw == nil { + return + } + value, found = tx_store.DiskLoaderRaw(key) + } + return +} + +func (tx_store *TX_Storage) RawStore(key []byte, value []byte) { + tx_store.RawKeys[string(key)] = value + return +} + +// this will load the variable, and if the key is found +func (tx_store *TX_Storage) Load(dkey DataKey, found_value *uint64) (value Variable) { + + //fmt.Printf("Loading %+v \n", dkey) + + *found_value = 0 + if result, ok := tx_store.Keys[dkey]; ok { // if it was modified in current TX, use it + *found_value = 1 + return result + } + + if tx_store.DiskLoader == nil { + panic("DVM_STORAGE_BACKEND is not ready") + } + + value = tx_store.DiskLoader(dkey, found_value) + + return +} + +// store variable +func (tx_store *TX_Storage) Store(dkey DataKey, v Variable) { + //fmt.Printf("Storing request %+v : %+v\n", dkey, v) + + tx_store.Keys[dkey] = v +} + +// store variable +func (tx_store *TX_Storage) SendExternal(sender_scid crypto.Hash, addr_str string, amount uint64) { + + //fmt.Printf("Transfer to external address : %+v\n", addr_str) + + tx_store.Balance(sender_scid) // load from disk if required + transfer := tx_store.Transfers[sender_scid] + transfer.TransferE = append(transfer.TransferE, TransferExternal{Address: addr_str, Amount: amount}) + tx_store.Transfers[sender_scid] = transfer + tx_store.Balance(sender_scid) // recalculate balance panic if any issues + +} + +// if TXID is not already loaded, load it +func (tx_store *TX_Storage) ReceiveInternal(scid crypto.Hash, amount uint64) { + + tx_store.Balance(scid) // load from disk if required + transfer := tx_store.Transfers[scid] + transfer.TransferI.Received = append(transfer.TransferI.Received, amount) + tx_store.Transfers[scid] = transfer + tx_store.Balance(scid) // recalculate balance panic if any issues +} + +func (tx_store *TX_Storage) SendInternal(sender_scid crypto.Hash, receiver_scid crypto.Hash, amount uint64) { + + //sender side + { + tx_store.Balance(sender_scid) // load from disk if required + transfer := tx_store.Transfers[sender_scid] + transfer.TransferI.Sent = append(transfer.TransferI.Sent, amount) + tx_store.Transfers[sender_scid] = transfer + tx_store.Balance(sender_scid) // recalculate balance panic if any issues + } + + { + tx_store.Balance(receiver_scid) // load from disk if required + transfer := tx_store.Transfers[receiver_scid] + transfer.TransferI.Received = append(transfer.TransferI.Received, amount) + tx_store.Transfers[receiver_scid] = transfer + tx_store.Balance(receiver_scid) // recalculate balance panic if any issues + } + +} + +func GetBalanceKey(scid crypto.Hash) (x DataKey) { + x.SCID = scid + x.Key = Variable{Type: String, Value: DVAL} + return x +} + +/* +func GetNormalKey(scid crypto.Key, v Variable) (x DataKey) { + x.SCID = scid + x.Key = Variable {Type:v.Type, Value: v.Value} + return x +} +*/ + +// this will give the balance, will load the balance from disk +func (tx_store *TX_Storage) Balance(scid crypto.Hash) uint64 { + + if scid != tx_store.SCID { + fmt.Printf("scid %s SCID %s\n", scid, tx_store.SCID) + fmt.Printf("tx_store internal %+v\n", tx_store) + panic("cross SC balance calls are not supported") + } + if _, ok := tx_store.Transfers[scid]; !ok { + + var transfer SC_Transfers + /* + found_value := uint64(0) + value := tx_store.Load(GetBalanceKey(scid), &found_value) + + if found_value == 0 { + panic(fmt.Sprintf("SCID %s is not loaded", scid)) // we must load it from disk + } + + if value.Type != Uint64 { + panic(fmt.Sprintf("SCID %s balance is not uint64, HOW ??", scid)) // we must load it from disk + } + */ + + transfer.BalanceAtStart = tx_store.BalanceAtStart + tx_store.Transfers[scid] = transfer + } + + transfers := tx_store.Transfers[scid] + balance := transfers.BalanceAtStart + + // replay all receives/sends + + // handle all internal receives + for _, amt_received := range transfers.TransferI.Received { + c := balance + amt_received + + if c >= balance { + balance = c + } else { + panic("uint64 overflow wraparound attack") + } + } + + // handle all internal sends + for _, amt_sent := range transfers.TransferI.Sent { + if amt_sent >= balance { + panic("uint64 underflow wraparound attack") + } + balance = balance - amt_sent + } + + // handle all external sends + for _, trans := range transfers.TransferE { + if trans.Amount >= balance { + panic("uint64 underflow wraparound attack") + } + balance = balance - trans.Amount + } + + return balance +} + +// whether the scid has enough balance +func (tx_store *TX_Storage) HasBalance(scid crypto.Key, amount uint64) { + +} + +// why should we not hash the return value to return a hash value +// using entire key could be useful, if DB can somehow link between them in the form of buckets and all +func (dkey DataKey) MarshalBinary() (ser []byte, err error) { + ser, err = dkey.Key.MarshalBinary() + return +} + +func (dkey DataKey) MarshalBinaryPanic() (ser []byte) { + var err error + if ser, err = dkey.Key.MarshalBinary(); err != nil { + panic(err) + } + return +} + +// these are used by lowest layers +func (v Variable) MarshalBinary() (data []byte, err error) { + data = append(data, byte(v.Type)) // add object type + switch v.Type { + case Invalid: + return + case Uint64: + var buf [binary.MaxVarintLen64]byte + done := binary.PutUvarint(buf[:], v.Value.(uint64)) // uint64 data type + data = append(data, buf[:done]...) + case Blob: + panic("not implemented") + case String: + data = append(data, ([]byte(v.Value.(string)))...) // string + default: + panic("unknown variable type not implemented") + } + return +} +func (v Variable) MarshalBinaryPanic() (ser []byte) { + var err error + if ser, err = v.MarshalBinary(); err != nil { + panic(err) + } + return +} + +func (v *Variable) UnmarshalBinary(buf []byte) (err error) { + if len(buf) < 1 || Vtype(buf[0]) == Invalid { + return fmt.Errorf("invalid, probably corruption") + } + + switch Vtype(buf[0]) { + case Invalid: + return fmt.Errorf("Invalid cannot be deserialized") + case Uint64: + v.Type = Uint64 + var n int + v.Value, n = binary.Uvarint(buf[1:]) // uint64 data type + if n <= 0 { + panic("corruption in DB") + return fmt.Errorf("corruption in DB") + } + case String: + v.Type = String + v.Value = string(buf[1:]) + return nil + case Blob: + panic("blob not implemented") // an encrypted blob, used to add data to blockchain without knowing address + + default: + panic("unknown variable type not implemented") + + } + return +} diff --git a/dvm/dvm_store_memory.go b/dvm/dvm_store_memory.go new file mode 100644 index 0000000..480fc99 --- /dev/null +++ b/dvm/dvm_store_memory.go @@ -0,0 +1,77 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package dvm + +import "fmt" + +// this file implements a RAM store backend for testing purposes + +type Memory_Storage struct { + Atoms []DataAtom // all modification operations have to played/reverse in this order + Keys map[DataKey]Variable + RawKeys map[string][]byte +} + +var Memory_Backend Memory_Storage + +func init() { + DVM_STORAGE_BACKEND = &Memory_Backend +} + +func (mem_store *Memory_Storage) RawLoad(key []byte) (value []byte, found bool) { + value, found = mem_store.RawKeys[string(key)] + return +} + +func (mem_store *Memory_Storage) RawStore(key []byte, value []byte) { + mem_store.RawKeys[string(key)] = value + return +} + +// this will load the variable, and if the key is found +func (mem_store *Memory_Storage) Load(dkey DataKey, found_value *uint64) (value Variable) { + + *found_value = 0 + // if it was modified in current TX, use it + if result, ok := mem_store.Keys[dkey]; ok { + *found_value = 1 + return result + } + + return +} + +// store variable +func (mem_store *Memory_Storage) Store(dkey DataKey, v Variable) { + + fmt.Printf("Storing %+v : %+v\n", dkey, v) + var found uint64 + old_value := mem_store.Load(dkey, &found) + + var atom DataAtom + atom.Key = dkey + atom.Value = v + if found != 0 { + atom.Prev_Value = old_value + } else { + atom.Prev_Value = Variable{} + } + + mem_store.Keys[atom.Key] = atom.Value + mem_store.Atoms = append(mem_store.Atoms, atom) + +} diff --git a/globals/globals.go b/globals/globals.go index 6315e7b..d4d9d42 100644 --- a/globals/globals.go +++ b/globals/globals.go @@ -24,12 +24,14 @@ import "strings" import "strconv" import "math/big" import "path/filepath" +import "runtime/debug" import "golang.org/x/net/proxy" +import "github.com/romana/rlog" import "github.com/sirupsen/logrus" import log "github.com/sirupsen/logrus" import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/address" +import "github.com/deroproject/derohe/rpc" type ChainState int // block chain can only be in 2 state, either SYNCRONISED or syncing @@ -66,17 +68,20 @@ var Dialer proxy.Dialer = proxy.Direct // for proxy and direct connections // all program arguments are available here var Arguments map[string]interface{} +func InitNetwork() { + Config = config.Mainnet // default is mainnnet + if Arguments["--testnet"].(bool) == true { // setup testnet if requested + Config = config.Testnet + } + +} func Initialize() { var err error _ = err Arguments["--testnet"] = true // force testnet every where - Config = config.Mainnet // default is mainnnet - if Arguments["--testnet"].(bool) == true { // setup testnet if requested - Config = config.Testnet - } - + InitNetwork() // formatter := &logrus.TextFormatter{DisableColors : true} //Logger= &logrus.Logger{Formatter:formatter} @@ -119,6 +124,14 @@ func Initialize() { } +// used to recover in case of panics +func Recover() { + if r := recover(); r != nil { + rlog.Warnf("Recovered while handling connection, Stack trace below", r) + rlog.Warnf("Stack trace \n%s", debug.Stack()) + } +} + // tells whether we are in mainnet mode // if we are not mainnet, we are a testnet, // we will only have a single mainnet ,( but we may have one or more testnets ) @@ -163,7 +176,7 @@ func CTXString(entry *logrus.Entry) string { // newbies, see type the next in python interpretor "3.33-3.13" // func FormatMoney(amount uint64) string { - return FormatMoneyPrecision(amount, 5) // default is 8 precision after floating point + return FormatMoneyPrecision(amount, 5) // default is 5 precision after floating point } // 0 @@ -192,12 +205,12 @@ func FormatMoneyPrecision(amount uint64, precision int) string { float_amount, _, _ := big.ParseFloat(fmt.Sprintf("%d", amount), 10, 0, big.ToZero) result := new(big.Float) result.Quo(float_amount, hard_coded_decimals) - return result.Text('f', precision) // 8 is display precision after floating point + return result.Text('f', precision) // 5 is display precision after floating point } // this will parse and validate an address, in reference to the current main/test mode -func ParseValidateAddress(str string) (addr *address.Address, err error) { - addr, err = address.NewAddress(strings.TrimSpace(str)) +func ParseValidateAddress(str string) (addr *rpc.Address, err error) { + addr, err = rpc.NewAddress(strings.TrimSpace(str)) if err != nil { return } diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..6b44278 --- /dev/null +++ b/go.mod @@ -0,0 +1,3 @@ +module github.com/deroproject/derohe + +go 1.14 diff --git a/guide/README.md b/guide/README.md new file mode 100644 index 0000000..4141dce --- /dev/null +++ b/guide/README.md @@ -0,0 +1,61 @@ +# DERO Virtual Machine (DVM) + +DERO Virtual Machine represents entire DERO Smart Contracts eco-system which runs on the DERO block chain. + +Documentation + +DVM is a decentralized platform that runs both public and private smart contracts: applications that run exactly as programmed without any possibility of downtime, censorship, fraud or third-party interference.Public Smart contracts are open versions. However, the DVM is being designed to support Private Smart Contracts where everything is hidden, eg parties, and information involved. Smart Contracts are nothing but rules which apply on transacting parties. + +Current version of DVM is an interpretor based system to avoid security vulneribilities, issues and compiler backdoors. This also allows easy audits of Smart Contracts for quality,bug-testing and security assurances. DVM supports a new language DVM-BASIC. + +----- + + + +DVM apps run on a from scratch custom built privacy supporting, encrypted blockchain, an enormously powerful shared global infrastructure that can move value around and represent the ownership of assets/property without leaking any information.No one knows who owns what and who transferred to whom. + +* This enables developers to create puzzles, games, voting, markets, store registries of debts or promises, move funds in accordance with instructions given long in the past (like a will or a futures contract) and many other ideas/things that have not been invented yet, all without a middleman or counterparty risk. + + +* DVM-BASIC is a contract-oriented, high-level language for implementing smart contracts. It is influenced by GW-BASIC, Visual Basic and C and is designed to target the DERO Virtual Machine (DVM). It is very easy to program and very readable. + +* DVM runs Smart Contracts which are a collection of functions written in DVM-BASIC. +These functions can be invoked over the blockchain to do something. SCs can act as libraries for other SCs. + + +* DVM supports number of comments formats such as ', // , /* */ as good documentation is necessary. + +Example Factorial program + +``` +' This is a comment +// This comment is supported +/* this is multi-line comment */ +// printf is not supported in latest DVM. Please comment or remove printf from all old Smart Contracts. + Function Factorial(s Uint64) Uint64 // this is a commment + 10 DIM result,scopy as Uint64 /* this is also comment */ + 15 LET scopy = s + 20 LET result = 1 + 30 LET result = result * s + 40 LET s = s - 1 + 50 IF s >= 2 THEN GOTO 30 + //60 PRINTF "FACTORIAL of %d = %d" scopy result // printf is not supported in latest DVM. + 70 RETURN result +End Function +``` + +### DVM are written in a DVM-BASIC custom BASIC style language with line numbers. +#### DVM supports uint64 and string data-types. +#### DVM interprets the smart-contract and processes the SC line-line + +* uint64 supports almost all operators namely +,-,*,/,% +* uint64 support following bitwise operators & ,|, ^, ! , >> , << +* uint64 supports following logical operators >, >= , <, <=, == , != + +* string supports only + operator. string support concatenation with a uint64. +* string supports ==, != logical operators. + +* All DVM variables are mandatory to define and are initialized to default values namely 0 and "". + + +A SC execution must return 0 to persist any changes made during execution. During execution, no panics should occur. diff --git a/guide/dim.md b/guide/dim.md new file mode 100644 index 0000000..818a6e9 --- /dev/null +++ b/guide/dim.md @@ -0,0 +1,11 @@ +# DIM statement +DIM stands for data in memory and is used to define variable names within a function + +syntax + +10 DIM variable1 as type +20 DIM variable1,variable2 as type + +type can be any type supported by DVM + +Defining a varible initializes a variable to its ZERO value. \ No newline at end of file diff --git a/guide/examples/lottery.bas b/guide/examples/lottery.bas new file mode 100644 index 0000000..b5e8274 --- /dev/null +++ b/guide/examples/lottery.bas @@ -0,0 +1,90 @@ +/* Lottery Smart Contract Example in DVM-BASIC. + This lottery smart contract will give lottery wins every xth try. +*/ + + + + Function Lottery(value Uint64) Uint64 + 10 dim deposit_count,winner as Uint64 + 20 LET deposit_count = LOAD("deposit_count")+1 + 25 IF value == 0 THEN GOTO 110 // if deposit amount is 0, simply return + 30 STORE("depositor_address" + (deposit_count-1), SIGNER()) // store address for later on payment + 40 STORE("deposit_total", LOAD("deposit_total") + value ) + 50 STORE("deposit_count",deposit_count) + 60 IF LOAD("lotteryeveryXdeposit") > deposit_count THEN GOTO 110 // we will wait till X players join in + // we are here means all players have joined in, roll the DICE, + 70 LET winner = RANDOM() % deposit_count // we have a winner + 80 SEND_DERO_TO_ADDRESS(LOAD("depositor_address" + winner) , LOAD("lotterygiveback")*LOAD("deposit_total")/10000) + // Re-Initialize for another round + 90 STORE("deposit_count", 0) // initial players + 100 STORE("deposit_total", 0) // total deposit of all players + 110 RETURN 0 + End Function + + + // This function is used to initialize parameters during install time + Function Initialize() Uint64 + 10 STORE("owner", SIGNER()) // store in DB ["owner"] = address + 20 STORE("lotteryeveryXdeposit", 2) // lottery will reward every X deposits + // How much will lottery giveback in 1/10000 parts, granularity .01 % + 30 STORE("lotterygiveback", 9900) // lottery will give reward 99% of deposits, 1 % is accumulated for owner to withdraw + 33 STORE("deposit_count", 0) // initial players + 34 STORE("deposit_total", 0) // total deposit of all players + // 35 printf "Initialize executed" + 40 RETURN 0 + End Function + + + + // Function to tune lottery parameters + Function TuneLotteryParameters(input Uint64, lotteryeveryXdeposit Uint64, lotterygiveback Uint64) Uint64 + 10 dim key,stored_owner as String + 20 dim value_uint64 as Uint64 + 30 IF LOAD("owner") == SIGNER() THEN GOTO 100 // check whether owner is real owner + 40 RETURN 1 + + 100 STORE("lotteryeveryXdeposit", lotteryeveryXdeposit) // lottery will reward every X deposits + 130 STORE("lotterygiveback", value_uint64) // how much will lottery giveback in 1/10000 parts, granularity .01 % + 140 RETURN 0 // return success + End Function + + + + // This function is used to change owner + // owner is an string form of address + Function TransferOwnership(newowner String) Uint64 + 10 IF LOAD("owner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 STORE("tmpowner",ADDRESS_RAW(newowner)) + 40 RETURN 0 + End Function + + // Until the new owner claims ownership, existing owner remains owner + Function ClaimOwnership() Uint64 + 10 IF LOAD("tmpowner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 STORE("owner",SIGNER()) // ownership claim successful + 40 RETURN 0 + End Function + + // If signer is owner, withdraw any requested funds + // If everthing is okay, they will be showing in signers wallet + Function Withdraw( amount Uint64) Uint64 + 10 IF LOAD("owner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 SEND_DERO_TO_ADDRESS(SIGNER(),amount) + 40 RETURN 0 + End Function + + // If signer is owner, provide him rights to update code anytime + // make sure update is always available to SC + Function UpdateCode( code String) Uint64 + 10 IF LOAD("owner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 UPDATE_SC_CODE(code) + 40 RETURN 0 + End Function + + + + diff --git a/guide/examples/lottery_sc_guide.md b/guide/examples/lottery_sc_guide.md new file mode 100644 index 0000000..4efcbf5 --- /dev/null +++ b/guide/examples/lottery_sc_guide.md @@ -0,0 +1,76 @@ +## Dero Stargate DVM Smart Contracts guide to install and test various function of lottery Smart Contract. + +**Download** Dero Stargate testnet [source](https://github.com/deroproject/derohe) and [binaries](https://github.com/deroproject/derohe/releases). + +**Start Dero daemon in testnet mode.** +``` +./derod-linux-amd64 --testnet +``` + +**Start Dero wallet in testnet.** +``` +dero-wallet-cli-linux-amd64 --rpc-server --wallet-file testnet.wallet --testnet +``` + +**Start Dero wallet second instance to test transfer/ownership functions etc.** +``` +dero-wallet-cli-linux-amd64 --wallet-file testnet2.wallet --testnet --rpc-server --rpc-bind=127.0.0.1:40403 +``` + +**Dero testnet Explorer** +``` +./explorer-linux-amd64 --rpc-server-address 127.0.0.1:30306 --http-address=0.0.0.0:8080 +``` + +**Dero Stargate Testnet Explorer** +[https://testnetexplorer.dero.io/ ](https://testnetexplorer.dero.io/) + + +**Installing Smart Contract.** + [Download lottery.bas](https://git.dero.io/DeroProject/derosuite_stargate/src/master/cmd/dvm/lottery.bas) +``` +curl --request POST --data-binary @lottery.bas http://127.0.0.1:40403/install_sc +``` + + +** Download SC Code,check balance and variables from chain** +```curl http://127.0.0.1:40402/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"getsc","params":{ "scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af" , "code":true}}' -H 'Content-Type: application/json' + + +curl http://127.0.0.1:40402/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"getsc","params":{ "scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af" , "code":false, "keysstring":["deposit_count"]}}' -H 'Content-Type: application/json' +``` + + +**Examples of various lottery Smart Contract functions** +**Eg: To play lottery** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af","sc_rpc":[{"name":"entrypoint","datatype":"S","value":"Lottery"}] }}' -H 'Content-Type: application/json' + +``` + +**Eg: Withdraw balance only for smart contract owner** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"Withdraw"}, {"name":"amount","datatype":"U","value":2 }] }}' -H 'Content-Type: application/json' +``` + +**Eg: To transfer ownership** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"TransferOwnership"}, {"name":"newowner","datatype":"S","value":"deto1qxsplx7vzgydacczw6vnrtfh3fxqcjevyxcvlvl82fs8uykjkmaxgfgulfha5" }] }}' -H 'Content-Type: application/json' + +``` + + +``` +**Eg: To claim ownership** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"ClaimOwnership"}] }}' -H 'Content-Type: application/json' +``` + + +**Eg: To update code** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"UpdateCode"}, {"name":"code","datatype":"S","value":"new code should be placed here" }] }}' -H 'Content-Type: application/json' + +``` + + diff --git a/guide/examples/token.bas b/guide/examples/token.bas new file mode 100644 index 0000000..f2d8bde --- /dev/null +++ b/guide/examples/token.bas @@ -0,0 +1,70 @@ +/* Private Token Smart Contract Example in DVM-BASIC. + DERO Smart Contracts Tokens privacy can be understood just like banks handle cash. Once cash is out from the bank, bank is not aware about it (who owns what value), until it is deposited back. + Smart contract only maintains supply and other necessary items to keep it working. + DERO Tokens can be tranfered to other wallets just like native DERO with Homomorphic Encryption and without involvement of issuing Smart Contracts. + Token issuing Smart Contract cannot hold/freeze/control their tokens once they are issued and sent to any wallet. + This token is Private. Use Function InitializePrivate() Uint64 to make any Smart Contract private. + +*/ + + + // Issue tokens after depositing DERO (Convert DERO to TOKENX) + Function IssueTOKENX() Uint64 + 10 ADD_VALUE(SIGNER(), DEROVALUE()) // Increment balance of user, without knowing original balance, this is done homomorphically + 20 RETURN 0 + End Function + + // Convert TOKENX to DERO after depositing TOKENX. Smart Contract can give DERO, Only if DERO balance exists. + Function ConvertTOKENX() Uint64 + 10 SEND_DERO_TO_ADDRESS(SIGNER(),TOKENVALUE()) // Increment balance of user, without knowing original balance, this is done using Homomorphic Encryption. + 20 RETURN 0 + End Function + + // This function is used to initialize parameters during install time + // InitializePrivate initializes a private SC + Function InitializePrivate() Uint64 + 10 STORE("owner", SIGNER()) // Store in DB ["owner"] = address + 20 ADD_VALUE(ADDRESS_RAW("deto1qxsplx7vzgydacczw6vnrtfh3fxqcjevyxcvlvl82fs8uykjkmaxgfgulfha5"), 1900000) // Gives initial encrypted balance. + 30 ADD_VALUE(SIGNER(), 1600000) // Gives initial encrypted balance of 1600000. + 40 RETURN 0 + End Function + + + // This function is used to change owner + // owner is an string form of address + Function TransferOwnership(newowner String) Uint64 + 10 IF LOAD("owner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 STORE("tmpowner",ADDRESS_RAW(newowner)) + 40 RETURN 0 + End Function + + // Until the new owner claims ownership, existing owner remains owner + Function ClaimOwnership() Uint64 + 10 IF LOAD("tmpowner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 STORE("owner",SIGNER()) // ownership claim successful + 40 RETURN 0 + End Function + + // if signer is owner, withdraw any requested funds + // if everthing is okay, they will be showing in signers wallet + Function Withdraw( amount Uint64) Uint64 + 10 IF LOAD("owner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 SEND_DERO_TO_ADDRESS(SIGNER(),amount) + 40 RETURN 0 + End Function + + // if signer is owner, provide him rights to update code anytime + // make sure update is always available to SC + Function UpdateCode( code String) Uint64 + 10 IF LOAD("owner") == SIGNER() THEN GOTO 30 + 20 RETURN 1 + 30 UPDATE_SC_CODE(code) + 40 RETURN 0 + End Function + + + + diff --git a/guide/examples/token_sc_guide.md b/guide/examples/token_sc_guide.md new file mode 100644 index 0000000..7e0007b --- /dev/null +++ b/guide/examples/token_sc_guide.md @@ -0,0 +1,100 @@ +## Dero Stargate DVM Smart Contracts guide to install and test various function of private token Smart Contract. + +**Download** Dero Stargate testnet [source](https://git.dero.io/DeroProject/derosuite_stargate) and [binaries](https://git.dero.io/DeroProject/Dero_Stargate_testnet_binaries). + +**Start Dero daemon in testnet mode.** +``` +./derod-linux-amd64 --testnet +``` + +**Start Dero wallet in testnet.** +``` +dero-wallet-cli-linux-amd64 --rpc-server --wallet-file testnet.wallet --testnet +``` + +**Start Dero wallet second instance to test transfer/ownership functions etc.** +``` +dero-wallet-cli-linux-amd64 --wallet-file testnet2.wallet --testnet --rpc-server --rpc-bind=127.0.0.1:40403 +``` + +**Dero testnet Explorer, Not required but if you want to host your own explorer for privacy reasons.** +``` +./explorer-linux-amd64 --http-address=0.0.0.0:8080 +``` +Connect to explorer using browser on localhost:8080 + + +**Dero Stargate Testnet Explorer** +[https://testnetexplorer.dero.io/ ](https://testnetexplorer.dero.io/) + + +**To send DERO to multiple users in one transaction** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":100000,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"},{"amount":300000,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}] }}' -H 'Content-Type: application/json' +``` + +**DERO has 2 types of SCs, public and private.** +1. Public SCs are public with all data/code/exchanges are public. +1. Private SCs have their smart contract data public. But no one knows how many tokens a particular user own or how much is he sending or how much is he receiving. Best example is to understand private SCs as banks and private tokens as cash. Once cash is out from the bank, Bank doesn't know "who has what amount or how is it being used/sent/received etc.". This makes all private tokens completely private. + +**Installing Private Smart Contract.** + [Download token.bas](https://git.dero.io/DeroProject/derosuite_stargate/src/master/cmd/dvm/token.bas) +``` +curl --request POST --data-binary @token.bas http://127.0.0.1:40403/install_sc +``` + +**To check private token balance in wallet, type this command in wallet.** +``` +balance SCID +``` + +**Download SC Code,check SC balance and variables from chain** +``` +curl http://127.0.0.1:40402/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"getsc","params":{ "scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af" , "code":true}}' -H 'Content-Type: application/json' +``` + + +**Examples of various private token Smart Contract functions** +**Eg: To send private tokens from one wallet to another wallet, this does not involve SC** +**Eg: this also showcases to send multiple assets( DERO and other tokens on DERO Network) within a single transaction** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"},{"amount":333333,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu","scid": "aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af" }] }}' -H 'Content-Type: application/json' +``` + + +**Eg: Convert DERO to tokens 1:1 swap, we are swapping 44 DERO atomic units to get some tokens** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{"transfers":[{"amount":1,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu", "burn":44}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"IssueTOKENX"}] }}' -H 'Content-Type: application/json' +``` + + +**Convert tokens to DERO 1:1 swap, we are swapping 9 token atomic units to get 9 DERO atomic units** +**This tx shows transferring tokens natively, no dero fees etc, this is under evaluation,** +**Currently these show as coinbase rewards ** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{"transfers":[{"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "amount":1,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu", "burn":9}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"ConvertTOKENX"}] }}' -H 'Content-Type: application/json' +``` + +**Eg: To withdraw balance only for smart contract owner** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"Withdraw"}, {"name":"amount","datatype":"U","value":2 }] }}' -H 'Content-Type: application/json' +``` + +**Eg: To transfer ownership of smart contract to new address/owner** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"TransferOwnership"}, {"name":"newowner","datatype":"S","value":"deto1qxsplx7vzgydacczw6vnrtfh3fxqcjevyxcvlvl82fs8uykjkmaxgfgulfha5" }] }}' -H 'Content-Type: application/json' + +``` + +**Eg: To claim ownership of smart contract** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"ClaimOwnership"}] }}' -H 'Content-Type: application/json' +``` + + +**Eg: To update smart contract code** +``` +curl http://127.0.0.1:40403/json_rpc -d '{"jsonrpc":"2.0","id":"0","method":"transfer","params":{ "transfers":[{"amount":111111,"destination":"deto1qxqqen6lqmksmzmxmfqmxp2y8zvkldtcq8jhkzqflmyczepjw9dp46gc3cczu"}],"scid":"aacaa7bb2388d06e523e5bc0783e4e131738270641406c12978155ba033373af", "sc_rpc":[{"name":"entrypoint","datatype":"S","value":"UpdateCode"}, {"name":"code","datatype":"S","value":"new code should be placed here" }] }}' -H 'Content-Type: application/json' + + +``` \ No newline at end of file diff --git a/guide/function.md b/guide/function.md new file mode 100644 index 0000000..ff267c6 --- /dev/null +++ b/guide/function.md @@ -0,0 +1,27 @@ +# Function statement + +Function statement is used to define a function. See eg, below for a function which adds 2 numbers + +``` +Function ADD(x uint64, y uint64) uint64 +10 RETURN x + y +End Function + +``` + +Function syntax is of 2 types + +1. Function function_name( 0 or more arguments ) +2. Function function_name( 0 or more arguments ) return type + +The rules for functions are as follows +* All functions begin with Function keyword +* Function name should be alpha-numeric. If the first letter of the function is Upper case alphabet, it can be invoked by blockchain and other smart-contracts. Otherwise the function can only be called by other functions within the smart contract. +* Function may or may not have a return type +* All functions must use RETURN to return from function or to return a value. RETURN is mandatory. +* All functions must end with End Function. End Function is mandatory +* A function can have a implicit parameter value of type uint64, which contains amount of DERO value sent with the transaction. + +Any error caused during processing will immediately stop execution and discard all changes that occur during SC execution. + +Any Entrypoint which returns uint64 value 0 is termed as success and will make transaction to commit all state changes. diff --git a/guide/goto.md b/guide/goto.md new file mode 100644 index 0000000..d4ffc3a --- /dev/null +++ b/guide/goto.md @@ -0,0 +1,6 @@ +# GOTO statement +It is used to jump to any point within the function. It cannot cross function-boundary + +syntax +GOTO line-number + diff --git a/guide/if.md b/guide/if.md new file mode 100644 index 0000000..1bddd65 --- /dev/null +++ b/guide/if.md @@ -0,0 +1,8 @@ +# IF +If statement is used to evaluate expression and make decisions.It has following forms +1. IF expr1 condition expr2 THEN GOTO line number +2. IF expr1 condition expr2 THEN GOTO line number ELSE GOTO line number + + +This is used to change execution flow based on conditions. +Conditions can be as complex expressions \ No newline at end of file diff --git a/guide/let.md b/guide/let.md new file mode 100644 index 0000000..96951c6 --- /dev/null +++ b/guide/let.md @@ -0,0 +1,14 @@ +# LET statement +LET is used to assign a value to a variable. +value can be as complex as possible and can contain complex expression + +syntax +``` +line number LET variable_name = expression +``` + +expression can invoke other functions,eg + +10 LET x = 2 + 3 + ADD(2,3) + +ANY assignments within DVM can only be done using LET \ No newline at end of file diff --git a/guide/return.md b/guide/return.md new file mode 100644 index 0000000..95ce516 --- /dev/null +++ b/guide/return.md @@ -0,0 +1,8 @@ +# RETURN statement +it is used to return from a function and can be used anywhere within a function + +syntax +1. RETURN ( return nil ) +2. RETURN expression ( evaluates expression and returns value ) + +any return value must match with the type defined while declaring function diff --git a/guide/support_functions.md b/guide/support_functions.md new file mode 100644 index 0000000..c28a453 --- /dev/null +++ b/guide/support_functions.md @@ -0,0 +1,69 @@ +Support Functions are inbuilt functions which provide some functionality or expose internals for speed and technical reasons. + + +LOAD(variable) +============== + +LOAD loads a variable which was previously stored in the blockchain using STORE function. Return type will be Uint64/String depending on what is stored. +It will panic if the value does NOT exists + +Uint64 EXISTS(variable) +======================= +EXISTS return 1 if the variable is store in DB and 0 otherwise + +STORE(key variable, value variable) +=================================== +STORE stores key and value in the DB. All storage state of the SC is accessible only from the SC which created it. + +Uint64 RANDOM() +Uint64 RANDOM(limit Uin64) +============================ +RANDOM returns a random using a PRNG seeded on BLID,SCID,TXID. First form gives a uint64, second form returns +random number in the range 0 - (limit), 0 is inclusive, limit is exclusive + +String SCID() +============== +Returns SMART CONTRACT ID which is currently running + +String BLID() +============== +Returns current BLOCK ID which contains current execution-in-progress TXID + +String TXID() +============= +Returns current TXID which is execution-in-progress. + +Uint64 BLOCK_HEIGHT() +===================== +Returns current chain height of BLID() + +Uint64 BLOCK_TOPOHEIGHT() +=========================== +Returns current topoheight of BLID() + +String SIGNER() +================= +Returns address of who signed this transaction + +Uint64 IS_ADDRESS_VALID(p String) +================================= +Returns 1 if address is valid, 0 otherwise + + +String ADDRESS_RAW(p String) +============================ +Returns address in RAW form as 33 byte keys, stripping away textual/presentation form. 2 address should always be compared in RAW form + +SEND_DERO_TO_ADDRESS(a String, amount Uint64) +============================================== +Sends amount DERO from SC DERO balance to a address which should be raw form. address must in string form DERO/DETO form +If the SC does not have enough balance, it will panic + + +ADD_VALUE(a String, amount Uint64) +==================================== +Send specific number of token to specific account. +If account is bring touched for the first time, it is done simply. +If account is already initialized ( it already has some balance, but SC does not know how much). So, it gives additional balance homomorphically + + diff --git a/p2p/chain_bootstrap.go b/p2p/chain_bootstrap.go new file mode 100644 index 0000000..760865e --- /dev/null +++ b/p2p/chain_bootstrap.go @@ -0,0 +1,345 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package p2p + +import "fmt" + +//import "net" +import "time" +import "math/big" +import "math/bits" +import "sync/atomic" +import "encoding/binary" + +//import "container/list" + +//import log "github.com/sirupsen/logrus" +import "github.com/romana/rlog" + +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/globals" +import "github.com/deroproject/derohe/block" + +//import "github.com/deroproject/derohe/errormsg" +import "github.com/deroproject/derohe/transaction" + +import "github.com/deroproject/graviton" + +import "github.com/deroproject/derohe/cryptography/crypto" + +//import "github.com/deroproject/derosuite/blockchain" + +// we are expecting other side to have a heavier PoW chain +// this is for the case when the chain only moves in pruned state +// if after bootstraping the chain can continousky sync for few minutes, this means we have got the job done +func (connection *Connection) bootstrap_chain() { + + var request ChangeList + var response Changes + // var err error + var zerohash crypto.Hash + + // we will request top 60 blocks + ctopo := connection.TopoHeight + var topos []int64 + for i := ctopo - 20; i < ctopo; i++ { + topos = append(topos, i) + } + + connection.logger.Infof("Bootstrap Initiated") + + for i := range topos { + request.TopoHeights = append(request.TopoHeights, topos[i]) + } + + fill_common(&request.Common) // fill common info + if err := connection.RConn.Client.Call("Peer.ChangeSet", request, &response); err != nil { + rlog.Errorf("Call faileda ChangeSet: %v\n", err) + return + } + // we have a response, see if its valid and try to add to get the blocks + rlog.Infof("changeset received, estimated keys : %d SC Keys : %d \n", response.KeyCount, response.SCKeyCount) + + commit_version := uint64(0) + + { // fetch and commit balance tree + + chunksize := int64(640) + chunks_estm := response.KeyCount / chunksize + chunks := int64(1) // chunks need to be in power of 2 + path_length := 0 + for chunks < chunks_estm { + chunks = chunks * 2 + path_length++ + } + + if chunks < 2 { + chunks = 2 + path_length = 1 + } + + var section [8]byte + + total_keys := 0 + + for i := int64(0); i < chunks; i++ { + binary.BigEndian.PutUint64(section[:], bits.Reverse64(uint64(i))) // place reverse path + ts_request := Request_Tree_Section_Struct{Topo: request.TopoHeights[0], TreeName: []byte(config.BALANCE_TREE), Section: section[:], SectionLength: uint64(path_length)} + var ts_response Response_Tree_Section_Struct + fill_common(&ts_response.Common) + if err := connection.RConn.Client.Call("Peer.TreeSection", ts_request, &ts_response); err != nil { + connection.logger.Warnf("Call failed TreeSection: %v\n", err) + return + } else { + // now we must write all the state changes to gravition + var balance_tree *graviton.Tree + if ss, err := chain.Store.Balance_store.LoadSnapshot(0); err != nil { + panic(err) + } else if balance_tree, err = ss.GetTree(config.BALANCE_TREE); err != nil { + panic(err) + } + + if len(ts_response.Keys) != len(ts_response.Values) { + rlog.Warnf("Incoming Key count %d value count %d \"%s\" ", len(ts_response.Keys), len(ts_response.Values), globals.CTXString(connection.logger)) + connection.exit() + return + } + rlog.Debugf("chunk %d Will write %d keys\n", i, len(ts_response.Keys)) + + for j := range ts_response.Keys { + balance_tree.Put(ts_response.Keys[j], ts_response.Values[j]) + } + total_keys += len(ts_response.Keys) + + commit_version, err = graviton.Commit(balance_tree) + if err != nil { + panic(err) + } + + h, err := balance_tree.Hash() + rlog.Debugf("total keys %d hash %x err %s\n", total_keys, h, err) + + } + connection.logger.Infof("Bootstrap %3.1f%% completed", float32(i*100)/float32(chunks)) + } + } + + { // fetch and commit SC tree + + chunksize := int64(640) + chunks_estm := response.SCKeyCount / chunksize + chunks := int64(1) // chunks need to be in power of 2 + path_length := 0 + for chunks < chunks_estm { + chunks = chunks * 2 + path_length++ + } + + if chunks < 2 { + chunks = 2 + path_length = 1 + } + + var section [8]byte + + total_keys := 0 + + for i := int64(0); i < chunks; i++ { + binary.BigEndian.PutUint64(section[:], bits.Reverse64(uint64(i))) // place reverse path + ts_request := Request_Tree_Section_Struct{Topo: request.TopoHeights[0], TreeName: []byte(config.SC_META), Section: section[:], SectionLength: uint64(path_length)} + var ts_response Response_Tree_Section_Struct + fill_common(&ts_response.Common) + if err := connection.RConn.Client.Call("Peer.TreeSection", ts_request, &ts_response); err != nil { + connection.logger.Warnf("Call failed TreeSection: %v\n", err) + return + } else { + // now we must write all the state changes to gravition + var changed_trees []*graviton.Tree + var sc_tree *graviton.Tree + //var changed_trees []*graviton.Tree + ss, err := chain.Store.Balance_store.LoadSnapshot(0) + if err != nil { + panic(err) + } else if sc_tree, err = ss.GetTree(config.SC_META); err != nil { + panic(err) + } + + if len(ts_response.Keys) != len(ts_response.Values) { + rlog.Warnf("Incoming Key count %d value count %d \"%s\" ", len(ts_response.Keys), len(ts_response.Values), globals.CTXString(connection.logger)) + connection.exit() + return + } + rlog.Debugf("SC chunk %d Will write %d keys\n", i, len(ts_response.Keys)) + + for j := range ts_response.Keys { + sc_tree.Put(ts_response.Keys[j], ts_response.Values[j]) + + // we must fetch each individual SC tree + + sc_request := Request_Tree_Section_Struct{Topo: request.TopoHeights[0], TreeName: ts_response.Keys[j], Section: section[:], SectionLength: uint64(0)} + var sc_response Response_Tree_Section_Struct + fill_common(&sc_response.Common) + if err := connection.RConn.Client.Call("Peer.TreeSection", sc_request, &sc_response); err != nil { + connection.logger.Warnf("Call failed TreeSection: %v\n", err) + return + } else { + var sc_data_tree *graviton.Tree + if sc_data_tree, err = ss.GetTree(string(ts_response.Keys[j])); err != nil { + panic(err) + } else { + for j := range sc_response.Keys { + sc_data_tree.Put(sc_response.Keys[j], sc_response.Values[j]) + } + changed_trees = append(changed_trees, sc_data_tree) + + } + + } + + } + total_keys += len(ts_response.Keys) + changed_trees = append(changed_trees, sc_tree) + commit_version, err = graviton.Commit(changed_trees...) + if err != nil { + panic(err) + } + + h, err := sc_tree.Hash() + rlog.Debugf("total SC keys %d hash %x err %s\n", total_keys, h, err) + + } + connection.logger.Infof("Bootstrap %3.1f%% completed", float32(i*100)/float32(chunks)) + } + } + + for i := int64(0); i <= request.TopoHeights[0]; i++ { + chain.Store.Topo_store.Write(i, zerohash, commit_version, 0) // commit everything + } + + for i := range response.CBlocks { // we must store the blocks + + var cbl block.Complete_Block // parse incoming block and deserialize it + var bl block.Block + // lets deserialize block first and see whether it is the requested object + cbl.Bl = &bl + err := bl.Deserialize(response.CBlocks[i].Block) + if err != nil { // we have a block which could not be deserialized ban peer + connection.logger.Warnf("Error Incoming block could not be deserilised err %s %s", err, connection.logid) + connection.exit() + return + } + + // give the chain some more time to respond + atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) + + if i == 0 { // whatever datastore we have written, its state hash must match + // ToDo + + } + + // complete the txs + for j := range response.CBlocks[i].Txs { + var tx transaction.Transaction + err = tx.DeserializeHeader(response.CBlocks[i].Txs[j]) + if err != nil { // we have a tx which could not be deserialized ban peer + rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, connection.logid) + connection.exit() + return + } + if bl.Tx_hashes[j] != tx.GetHash() { + rlog.Warnf("Error Incoming TX has mismatch err %s %s", err, connection.logid) + connection.exit() + return + } + + cbl.Txs = append(cbl.Txs, &tx) + } + + { // first lets save all the txs, together with their link to this block as height + for i := 0; i < len(cbl.Txs); i++ { + if err = chain.Store.Block_tx_store.WriteTX(bl.Tx_hashes[i], cbl.Txs[i].Serialize()); err != nil { + panic(err) + } + } + } + + diff := new(big.Int) + if _, ok := diff.SetString(response.CBlocks[i].Difficulty, 10); !ok { // if Cumulative_Difficulty could not be parsed, kill connection + rlog.Warnf("Could not Parse Difficulty in common %s \"%s\" ", connection.Cumulative_Difficulty, globals.CTXString(connection.logger)) + connection.exit() + return + } + + cdiff := new(big.Int) + if _, ok := cdiff.SetString(response.CBlocks[i].Cumulative_Difficulty, 10); !ok { // if Cumulative_Difficulty could not be parsed, kill connection + rlog.Warnf("Could not Parse Cumulative_Difficulty in common %s \"%s\" ", connection.Cumulative_Difficulty, globals.CTXString(connection.logger)) + connection.exit() + return + } + + if err = chain.Store.Block_tx_store.WriteBlock(bl.GetHash(), bl.Serialize(), diff, cdiff); err != nil { + panic(fmt.Sprintf("error while writing block")) + } + + // now we must write all the state changes to gravition + + var ss *graviton.Snapshot + if ss, err = chain.Store.Balance_store.LoadSnapshot(0); err != nil { + panic(err) + } + + /*if len(response.CBlocks[i].Keys) != len(response.CBlocks[i].Values) { + rlog.Warnf("Incoming Key count %d value count %d \"%s\" ", len(response.CBlocks[i].Keys), len(response.CBlocks[i].Values), globals.CTXString(connection.logger)) + connection.exit() + return + }*/ + + write_count := 0 + commit_version := ss.GetVersion() + if i != 0 { + + var changed_trees []*graviton.Tree + + for _, change := range response.CBlocks[i].Changes { + var tree *graviton.Tree + if tree, err = ss.GetTree(string(change.TreeName)); err != nil { + panic(err) + } + + for j := range change.Keys { + tree.Put(change.Keys[j], change.Values[j]) + write_count++ + } + changed_trees = append(changed_trees, tree) + } + commit_version, err = graviton.Commit(changed_trees...) + if err != nil { + panic(err) + } + } + + rlog.Debugf("%d wrote %d keys commit version %d\n", request.TopoHeights[i], write_count, commit_version) + + chain.Store.Topo_store.Write(request.TopoHeights[i], bl.GetHash(), commit_version, int64(bl.Height)) // commit everything + } + + connection.logger.Infof("Bootstrap completed successfully") + // load the chain from the disk + chain.Initialise_Chain_From_DB() + chain.Sync = true + return +} diff --git a/p2p/chain_response.go b/p2p/chain_response.go deleted file mode 100644 index 515553e..0000000 --- a/p2p/chain_response.go +++ /dev/null @@ -1,125 +0,0 @@ -// Copyright 2017-2021 DERO Project. All rights reserved. -// Use of this source code in any form is governed by RESEARCH license. -// license can be found in the LICENSE file. -// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 -// -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL -// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF -// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -package p2p - -//import "fmt" -//import "net" -//import "sync" -//import "time" - -//import "container/list" - -//import log "github.com/sirupsen/logrus" -import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" - -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/config" - -//import "github.com/deroproject/derosuite/blockchain" - -// peer has responded with chain response and we must process the response -func (connection *Connection) Handle_ChainResponse(buf []byte) { - var response Chain_Response_Struct - - err := msgpack.Unmarshal(buf, &response) - if err != nil { - rlog.Warnf("Error while decoding incoming chain response err %s %s", err, connection.logid) - connection.Exit() - return - } - - // check what we we queued is what what we got back - // for chain request we queue an empty hash - - var expected Queued_Command - - select { - case expected = <-connection.Objects: - - default: // if nothing is on queue the peer sent us bogus request, - rlog.Warnf("Peer sent us a chain response, when we didnot request chain, Exiting, may be block the peer %s", connection.logid) - connection.Exit() - } - - if expected.Command != V2_COMMAND_CHAIN_RESPONSE { - rlog.Warnf("We were waiting for a different object, but peer sent something else, Exiting, may be block the peer %s", connection.logid) - connection.Exit() - } - - // we were expecting something else ban - if len(response.Block_list) < 1 || len(response.TopBlocks) > 100 { - rlog.Warnf("Malformed chain response %s", err, connection.logid) - connection.Exit() - return - } - - rlog.Tracef(2, "Peer wants to give chain from topoheight %d ", response.Start_height) - _ = config.STABLE_LIMIT - - // we do not need reorganisation if deviation is less than or equak to 7 blocks - // only pop blocks if the system has somehow deviated more than 7 blocks - // if the deviation is less than 7 blocks, we internally reorganise everything - if chain.Get_Height() -response.Start_height > config.STABLE_LIMIT && connection.SyncNode { - // get our top block - rlog.Infof("rewinding status our %d peer %d", chain.Load_TOPO_HEIGHT(), response.Start_topoheight) - pop_count := chain.Load_TOPO_HEIGHT() - response.Start_topoheight - chain.Rewind_Chain(int(pop_count)) // pop as many blocks as necessary - - // we should NOT queue blocks, instead we sent our chain request again - connection.Send_ChainRequest() - return - - }else if chain.Get_Height()-response.Start_height <= config.STABLE_LIMIT { - pop_count := chain.Load_TOPO_HEIGHT() - response.Start_topoheight - chain.Rewind_Chain(int(pop_count)) // pop as many blocks as necessary, assumming peer has given us good chain - }else{ // we must somehow notify that deviation is way too much and manual interaction is necessary, so as any bug for chain deviationmay be detected - - } - - // response only 128 blocks at a time - max_blocks_to_queue := 128 - // check whether the objects are in our db or not - // until we put in place a parallel object tracker, do it one at a time - - rlog.Infof("response block list %d\n", len(response.Block_list)) - for i := range response.Block_list { - our_topo_order := chain.Load_Block_Topological_order(response.Block_list[i]) - if our_topo_order != (int64(i)+ response.Start_topoheight) || chain.Load_Block_Topological_order(response.Block_list[i]) == -1 { // if block is not in our chain, add it to request list - //queue_block(request.Block_list[i]) - if max_blocks_to_queue >= 0 { - max_blocks_to_queue-- - connection.Send_ObjectRequest([]crypto.Hash{response.Block_list[i]}, []crypto.Hash{}) - rlog.Tracef(2, "Queuing block %x height %d %s", response.Block_list[i], response.Start_height+int64(i), connection.logid) - } - } else { - rlog.Tracef(3, "We must have queued %x, but we skipped it at height %d", response.Block_list[i], response.Start_height+int64(i)) - } - } - - // request alt-tips ( blocks if we are nearing the main tip ) - if (response.Common.TopoHeight - chain.Load_TOPO_HEIGHT()) <= 5 { - for i := range response.TopBlocks { - if chain.Load_Block_Topological_order(response.TopBlocks[i]) == -1 { - connection.Send_ObjectRequest([]crypto.Hash{response.TopBlocks[i]}, []crypto.Hash{}) - rlog.Tracef(2, "Queuing ALT-TIP block %x %s", response.TopBlocks[i], connection.logid) - - } - - } - } -} diff --git a/p2p/chain_sync.go b/p2p/chain_sync.go new file mode 100644 index 0000000..f1b9f36 --- /dev/null +++ b/p2p/chain_sync.go @@ -0,0 +1,234 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package p2p + +import "fmt" + +//import "net" +import "time" +import "sync/atomic" + +//import "container/list" + +//import log "github.com/sirupsen/logrus" +import "github.com/romana/rlog" + +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/globals" +import "github.com/deroproject/derohe/block" +import "github.com/deroproject/derohe/errormsg" +import "github.com/deroproject/derohe/transaction" + +//import "github.com/deroproject/derohe/cryptography/crypto" + +//import "github.com/deroproject/derosuite/blockchain" + +// we are expecting other side to have a heavier PoW chain, try to sync now +func (connection *Connection) sync_chain() { + + var request Chain_Request_Struct + var response Chain_Response_Struct + +try_again: + + // send our blocks, first 10 blocks directly, then decreasing in powers of 2 + start_point := chain.Load_TOPO_HEIGHT() + for i := int64(0); i < start_point; { + + tr, err := chain.Store.Topo_store.Read(start_point - i) // commit everything + if err != nil { + continue + } + if tr.IsClean() { + break + } + + request.Block_list = append(request.Block_list, tr.BLOCK_ID) + request.TopoHeights = append(request.TopoHeights, start_point-i) + switch { + case len(request.Block_list) < 10: + i++ + default: + i = i * 2 + } + } + // add genesis block at the end + request.Block_list = append(request.Block_list, globals.Config.Genesis_Block_Hash) + request.TopoHeights = append(request.TopoHeights, 0) + fill_common(&request.Common) // fill common info + if err := connection.RConn.Client.Call("Peer.Chain", request, &response); err != nil { + fmt.Printf("Call failed Peer.Chain : %v \n", err) + return + } + // we have a response, see if its valid and try to add to get the blocks + + rlog.Infof("Peer wants to give chain from topoheight %d ", response.Start_height) + _ = config.STABLE_LIMIT + + // we do not need reorganisation if deviation is less than or equak to 7 blocks + // only pop blocks if the system has somehow deviated more than 7 blocks + // if the deviation is less than 7 blocks, we internally reorganise everything + if chain.Get_Height()-response.Start_height > config.STABLE_LIMIT && connection.SyncNode { + // get our top block + rlog.Infof("rewinding status our %d peer %d", chain.Load_TOPO_HEIGHT(), response.Start_topoheight) + pop_count := chain.Load_TOPO_HEIGHT() - response.Start_topoheight + chain.Rewind_Chain(int(pop_count)) // pop as many blocks as necessary + + // we should NOT queue blocks, instead we sent our chain request again + goto try_again + + } else if chain.Get_Height()-response.Start_height <= config.STABLE_LIMIT { + pop_count := chain.Load_TOPO_HEIGHT() - response.Start_topoheight + chain.Rewind_Chain(int(pop_count)) // pop as many blocks as necessary, assumming peer has given us good chain + } else { // we must somehow notify that deviation is way too much and manual interaction is necessary, so as any bug for chain deviationmay be detected + return + } + + // response only 128 blocks at a time + max_blocks_to_queue := 128 + // check whether the objects are in our db or not + // until we put in place a parallel object tracker, do it one at a time + + rlog.Infof("response block list %d\n", len(response.Block_list)) + for i := range response.Block_list { + our_topo_order := chain.Load_Block_Topological_order(response.Block_list[i]) + if our_topo_order != (int64(i)+response.Start_topoheight) || chain.Load_Block_Topological_order(response.Block_list[i]) == -1 { // if block is not in our chain, add it to request list + //queue_block(request.Block_list[i]) + if max_blocks_to_queue >= 0 { + max_blocks_to_queue-- + //connection.Send_ObjectRequest([]crypto.Hash{response.Block_list[i]}, []crypto.Hash{}) + var orequest ObjectList + var oresponse Objects + + orequest.Block_list = append(orequest.Block_list, response.Block_list[i]) + fill_common(&orequest.Common) + if err := connection.RConn.Client.Call("Peer.GetObject", orequest, &oresponse); err != nil { + fmt.Printf("Call faileda Peer.GetObject: %v\n", err) + return + } else { // process the response + if err = connection.process_object_response(oresponse); err != nil { + return + } + } + + //fmt.Printf("Queuing block %x height %d %s", response.Block_list[i], response.Start_height+int64(i), connection.logid) + } + } else { + rlog.Tracef(3, "We must have queued %x, but we skipped it at height %d", response.Block_list[i], response.Start_height+int64(i)) + } + } + + // request alt-tips ( blocks if we are nearing the main tip ) + if (response.Common.TopoHeight - chain.Load_TOPO_HEIGHT()) <= 5 { + for i := range response.TopBlocks { + if chain.Load_Block_Topological_order(response.TopBlocks[i]) == -1 { + //connection.Send_ObjectRequest([]crypto.Hash{response.TopBlocks[i]}, []crypto.Hash{}) + rlog.Tracef(2, "Queuing ALT-TIP block %x %s", response.TopBlocks[i], connection.logid) + + } + + } + } + +} + +func (connection *Connection) process_object_response(response Objects) error { + var err error + + // make sure connection does not timeout and be killed while processing huge blocks + processing_complete := make(chan bool) + go func() { + ticker := time.NewTicker(500 * time.Millisecond) + defer ticker.Stop() + for { + select { + case <-processing_complete: + return // complete the loop + case <-ticker.C: // give the chain some more time to respond + atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) + } + } + }() + + defer func() { + processing_complete <- true + }() + + for i := 0; i < len(response.CBlocks); i++ { // process incoming full blocks + var cbl block.Complete_Block // parse incoming block and deserialize it + var bl block.Block + // lets deserialize block first and see whether it is the requested object + cbl.Bl = &bl + err := bl.Deserialize(response.CBlocks[i].Block) + if err != nil { // we have a block which could not be deserialized ban peer + rlog.Warnf("Error Incoming block could not be deserilised err %s %s", err, connection.logid) + connection.exit() + return nil + } + + // give the chain some more time to respond + atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) + + // check whether the object was requested one + + // complete the txs + for j := range response.CBlocks[i].Txs { + var tx transaction.Transaction + err = tx.DeserializeHeader(response.CBlocks[i].Txs[j]) + if err != nil { // we have a tx which could not be deserialized ban peer + rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, connection.logid) + connection.exit() + + return nil + } + cbl.Txs = append(cbl.Txs, &tx) + } + + // check if we can add ourselves to chain + err, ok := chain.Add_Complete_Block(&cbl) + if !ok && err == errormsg.ErrInvalidPoW { + connection.logger.Warnf("This peer should be banned") + connection.exit() + return nil + } + + if !ok && err == errormsg.ErrPastMissing { + rlog.Warnf("Error Incoming Block coould not be added due to missing past, so skipping future block err %s %s", err, connection.logid) + return nil + } + + // add the object to object pool from where it will be consume + // queue_block_received(bl.GetHash(),&cbl) + + } + + for i := range response.Txs { // process incoming txs for mempool + var tx transaction.Transaction + err = tx.DeserializeHeader(response.Txs[i]) + if err != nil { // we have a tx which could not be deserialized ban peer + rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, connection.logid) + connection.exit() + + return nil + } + if !chain.Mempool.Mempool_TX_Exist(tx.GetHash()) { // we still donot have it, so try to process it + + chain.Add_TX_To_Pool(&tx) // currently we are ignoring error + } + } + return nil +} diff --git a/p2p/common.go b/p2p/common.go new file mode 100644 index 0000000..12109d3 --- /dev/null +++ b/p2p/common.go @@ -0,0 +1,72 @@ +package p2p + +import "math/big" +import "sync/atomic" +import "github.com/romana/rlog" + +import "github.com/deroproject/derohe/globals" +import "github.com/deroproject/derohe/cryptography/crypto" + +// fill the common part from our chain +func fill_common(common *Common_Struct) { + common.Height = chain.Get_Height() + //common.StableHeight = chain.Get_Stable_Height() + common.TopoHeight = chain.Load_TOPO_HEIGHT() + //common.Top_ID, _ = chain.Load_BL_ID_at_Height(common.Height - 1) + + high_block, err := chain.Load_Block_Topological_order_at_index(common.TopoHeight) + if err != nil { + common.Cumulative_Difficulty = "0" + } else { + common.Cumulative_Difficulty = chain.Load_Block_Cumulative_Difficulty(high_block).String() + } + + if common.StateHash, err = chain.Load_Merkle_Hash(common.TopoHeight); err != nil { + panic(err) + } + + common.Top_Version = uint64(chain.Get_Current_Version_at_Height(int64(common.Height))) // this must be taken from the hardfork + +} + +// used while sendint TX ASAP +// this also skips statehash +func fill_common_skip_topoheight(common *Common_Struct) { + fill_common(common) + return + +} + +// update some common properties quickly +func (connection *Connection) update(common *Common_Struct) { + //connection.Lock() + //defer connection.Unlock() + var hash crypto.Hash + atomic.StoreInt64(&connection.Height, common.Height) // satify race detector GOD + if common.StableHeight != 0 { + atomic.StoreInt64(&connection.StableHeight, common.StableHeight) // satify race detector GOD + } + atomic.StoreInt64(&connection.TopoHeight, common.TopoHeight) // satify race detector GOD + + //connection.Top_ID = common.Top_ID + if common.Cumulative_Difficulty != "" { + connection.Cumulative_Difficulty = common.Cumulative_Difficulty + + var x *big.Int + x = new(big.Int) + if _, ok := x.SetString(connection.Cumulative_Difficulty, 10); !ok { // if Cumulative_Difficulty could not be parsed, kill connection + rlog.Warnf("Could not Parse Cumulative_Difficulty in common '%s' \"%s\" ", connection.Cumulative_Difficulty, globals.CTXString(connection.logger)) + connection.exit() + } + + connection.CDIFF.Store(x) // do it atomically + } + + if connection.Top_Version != common.Top_Version { + atomic.StoreUint64(&connection.Top_Version, common.Top_Version) // satify race detector GOD + } + if common.StateHash != hash { + connection.StateHash = common.StateHash + } + +} diff --git a/p2p/connection_handler.go b/p2p/connection_handler.go deleted file mode 100644 index 1dba0aa..0000000 --- a/p2p/connection_handler.go +++ /dev/null @@ -1,453 +0,0 @@ -// Copyright 2017-2021 DERO Project. All rights reserved. -// Use of this source code in any form is governed by RESEARCH license. -// license can be found in the LICENSE file. -// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 -// -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL -// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF -// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -package p2p - -import "io" - -//import "fmt" -import "net" - -//import "sync" -//import "math/rand" -import "time" -import "math/big" -import "runtime/debug" -import "sync/atomic" -import "encoding/binary" - -//import "container/list" - -import "github.com/romana/rlog" -import log "github.com/sirupsen/logrus" -import "github.com/paulbellamy/ratecounter" -import "github.com/vmihailenco/msgpack" - -import "github.com/deroproject/derohe/config" - -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/globals" - -import "github.com/deroproject/derohe/blockchain" - -// This file defines what all needs to be responded to become a server ( handling incoming requests) - -// fill the common part from our chain -func fill_common(common *Common_Struct) { - common.Height = chain.Get_Height() - //common.StableHeight = chain.Get_Stable_Height() - common.TopoHeight = chain.Load_TOPO_HEIGHT() - //common.Top_ID, _ = chain.Load_BL_ID_at_Height(common.Height - 1) - - high_block, err := chain.Load_Block_Topological_order_at_index(common.TopoHeight) - if err != nil { - common.Cumulative_Difficulty = "0" - } else { - common.Cumulative_Difficulty = chain.Load_Block_Cumulative_Difficulty(high_block).String() - } - - if toporecord, err := chain.Store.Topo_store.Read(common.TopoHeight); err == nil { - if ss, err := chain.Store.Balance_store.LoadSnapshot(uint64(toporecord.State_Version)); err == nil { - if balance_tree, err := ss.GetTree(blockchain.BALANCE_TREE); err == nil { - if bhash, err := balance_tree.Hash(); err == nil { - common.StateHash = bhash - } - } - } - } - - common.Top_Version = uint64(chain.Get_Current_Version_at_Height(int64(common.Height))) // this must be taken from the hardfork - -} - -// used while sendint TX ASAP -// this also skips statehash -func fill_common_skip_topoheight(common *Common_Struct) { - fill_common(common) - return - /* - common.Height = chain.Get_Height() - //common.StableHeight = chain.Get_Stable_Height() - common.TopoHeight = chain.Load_TOPO_HEIGHT() - //common.Top_ID, _ = chain.Load_BL_ID_at_Height(common.Height - 1) - - high_block, err := chain.Load_Block_Topological_order_at_index(common.TopoHeight) - if err != nil { - common.Cumulative_Difficulty = "0" - } else { - common.Cumulative_Difficulty = chain.Load_Block_Cumulative_Difficulty(high_block).String() - } - common.Top_Version = uint64(chain.Get_Current_Version_at_Height(int64(common.Height))) // this must be taken from the hardfork - */ - -} - -// update some common properties quickly -func (connection *Connection) Update(common *Common_Struct) { - //connection.Lock() - //defer connection.Unlock() - var hash crypto.Hash - atomic.StoreInt64(&connection.Height, common.Height) // satify race detector GOD - if common.StableHeight != 0 { - atomic.StoreInt64(&connection.StableHeight, common.StableHeight) // satify race detector GOD - } - atomic.StoreInt64(&connection.TopoHeight, common.TopoHeight) // satify race detector GOD - - //connection.Top_ID = common.Top_ID - connection.Cumulative_Difficulty = common.Cumulative_Difficulty - - var x *big.Int - x = new(big.Int) - if _, ok := x.SetString(connection.Cumulative_Difficulty, 10); !ok { // if Cumulative_Difficulty could not be parsed, kill connection - rlog.Warnf("Could not Parse Cumulative_Difficulty in common %s \"%s\" ", connection.Cumulative_Difficulty, globals.CTXString(connection.logger)) - - connection.Exit() - } - - connection.CDIFF.Store(x) // do it atomically - - if connection.Top_Version != common.Top_Version { - atomic.StoreUint64(&connection.Top_Version, common.Top_Version) // satify race detector GOD - } - if common.StateHash != hash { - connection.StateHash = common.StateHash - } - -} - -// sets timeout based on connection state, so as stale connections are cleared quickly -// if these timeouts are met connection is closed -func (connection *Connection) set_timeout() { - if atomic.LoadUint32(&connection.State) == HANDSHAKE_PENDING { - connection.Conn.SetReadDeadline(time.Now().Add(8 * time.Second)) // new connections have 8 seconds to handshake - } else { - // if we have queued something, time should be less than 30 sec assumming 10KB/sec BW is available - connection.Conn.SetReadDeadline(time.Now().Add(40 * time.Second)) // good connections have 120 secs to communicate - } - -} - -// marks connection as exit in progress -func (conn *Connection) Exit() { - atomic.AddInt32(&conn.ExitCounter, 1) -} - -func (conn *Connection) IsExitInProgress() bool { - if atomic.AddInt32(&conn.ExitCounter, 0) != 0 { - return true - } - return false -} - -// the message is sent as follows - -func (conn *Connection) Send_Message(data_bytes []byte) { - - // measure parameters - conn.SpeedOut.Incr(int64(len(data_bytes)) + 4) - atomic.StoreUint64(&conn.BytesOut, atomic.LoadUint64(&conn.BytesOut)+(uint64(len(data_bytes))+4)) - - if atomic.LoadUint32(&conn.State) != HANDSHAKE_PENDING { - atomic.StoreUint32(&conn.State, ACTIVE) - } - conn.Send_Message_prelocked(data_bytes) -} - -// used when we have command queue -// assumingin peer lock has already been taken -func (conn *Connection) Send_Message_prelocked(data_bytes []byte) { - - conn.writelock.Lock() - defer conn.writelock.Unlock() - - defer func() { - if r := recover(); r != nil { - conn.logger.Warnf("Recovered while handling connection, Stack trace below %+v", r) - conn.logger.Warnf("Stack trace \n%s", debug.Stack()) - conn.Exit() - } - }() - - if conn.IsExitInProgress() { - return - } - - var length_bytes [4]byte - binary.LittleEndian.PutUint32(length_bytes[:], uint32(len(data_bytes))) - - // each connection has a write deadline of 60 secs - conn.Conn.SetWriteDeadline(time.Now().Add(60 * time.Second)) - if _, err := conn.Conn.Write(length_bytes[:]); err != nil { // send the length prefix - conn.Exit() - return - } - - conn.Conn.SetWriteDeadline(time.Now().Add(60 * time.Second)) - if _, err := conn.Conn.Write(data_bytes[:]); err != nil { // send the message itself - conn.Exit() - return - } - -} - -// reads our data, length prefix blocks -func (connection *Connection) Read_Data_Frame(timeout int64, max_block_size uint32) (data_buf []byte) { - - var frame_length_buf [4]byte - - connection.set_timeout() - nbyte, err := io.ReadFull(connection.Conn, frame_length_buf[:]) - if err != nil || nbyte != 4 { - // error while reading from connection we must disconnect it - rlog.Warnf("Could not read length prefix err %s %s", err, globals.CTXString(connection.logger)) - - connection.Exit() - - return - } - - // time to ban - frame_length := binary.LittleEndian.Uint32(frame_length_buf[:]) - if frame_length == 0 || uint64(frame_length) > (15*config.STARGATE_HE_MAX_BLOCK_SIZE/10) || uint64(frame_length) > (2*uint64(max_block_size)) { - // most probably memory DDOS attack, kill the connection - rlog.Warnf("Frame length is too big Expected %d Actual %d %s", (2 * uint64(max_block_size)), frame_length, globals.CTXString(connection.logger)) - connection.Exit() - return - - } - - data_buf = make([]byte, frame_length) - connection.set_timeout() - data_size, err := io.ReadFull(connection.Conn, data_buf) - if err != nil || data_size <= 0 || uint32(data_size) != frame_length { - // error while reading from connection we must kiil it - rlog.Warnf("Could not read data size read %d, frame length %d err %s", data_size, frame_length, err, globals.CTXString(connection.logger)) - connection.Exit() - return - - } - data_buf = data_buf[:frame_length] - - // measure parameters - connection.SpeedIn.Incr(int64(frame_length) + 4) - connection.BytesIn += (uint64(frame_length) + 4) - if atomic.LoadUint32(&connection.State) != HANDSHAKE_PENDING { - atomic.StoreUint32(&connection.State, ACTIVE) - } - - return data_buf - -} - -// handles both server and client connections -func Handle_Connection(conn net.Conn, remote_addr *net.TCPAddr, incoming bool, sync_node bool) { - - var err error - - defer func() { - if r := recover(); r != nil { // under rare condition below defer can also raise an exception, catch it now - // connection.logger.Warnf("Recovered while handling connection RARE", r) - rlog.Warnf("Recovered while handling connection RARE") - //conn.Exit() - } - }() - - var connection Connection - connection.Incoming = incoming - connection.Conn = conn - connection.SyncNode = sync_node - connection.Addr = remote_addr // since we may be connecting via socks, get target IP - //connection.Command_queue = list.New() // init command queue - connection.Objects = make(chan Queued_Command, 2048) - connection.CDIFF.Store(new(big.Int).SetUint64(1)) - connection.State = HANDSHAKE_PENDING - - connection.request_time.Store(time.Now()) - //connection.Exit = make(chan bool) - connection.SpeedIn = ratecounter.NewRateCounter(60 * time.Second) - connection.SpeedOut = ratecounter.NewRateCounter(60 * time.Second) - - if incoming { - connection.logger = logger.WithFields(log.Fields{"RIP": remote_addr.String(), "DIR": "INC"}) - } else { - connection.logger = logger.WithFields(log.Fields{"RIP": remote_addr.String(), "DIR": "OUT"}) - } - // this is to kill most of the races, related to logger - connection.logid = globals.CTXString(connection.logger) - - defer func() { - if r := recover(); r != nil { - connection.logger.Warnf("Recovered while handling connection, Stack trace below %+v", r) - connection.logger.Warnf("Stack trace \n%s", debug.Stack()) - connection.Exit() - } - }() - - // goroutine to exit the connection if signalled - go func() { - - defer func() { - if r := recover(); r != nil { // under rare condition below defer can also raise an exception, catch it now - // connection.logger.Warnf("Recovered while handling connection RARE", r) - rlog.Warnf("Recovered while handling Timed Sync") - connection.Exit() - } - }() - - ticker := time.NewTicker(1 * time.Second) // 1 second ticker - idle := 0 - rehandshake := 0 - for { - - if connection.IsExitInProgress() { - - //connection.logger.Warnf("Removing connection") - ticker.Stop() // release resources of timer - conn.Close() - Connection_Delete(&connection) - return // close the connection and close the routine - } - - select { - case <-ticker.C: - idle++ - rehandshake++ - if idle > 2 { // if idle more than 2 secs, we should send a timed sync - if atomic.LoadUint32(&connection.State) != HANDSHAKE_PENDING { - atomic.StoreUint32(&connection.State, IDLE) - connection.Send_TimedSync(true) - idle = 0 - } - - // if no timed sync response in 2 minute kill the connection - if time.Now().Sub(connection.request_time.Load().(time.Time)) > 120*time.Second { - connection.Exit() - } - - //if !connection.Incoming { // there is not point in sending timed sync both sides simultaneously - - if rehandshake > 1800 { // rehandshake to exchange peers every half hour - connection.Send_Handshake(true) - rehandshake = 0 - - // run cleanup process every 1800 seconds - connection.TXpool_cache_lock.Lock() - if connection.TXpool_cache != nil { - current_time := uint32(time.Now().Unix()) - for k, v := range connection.TXpool_cache { - if (v + 1800) < current_time { - delete(connection.TXpool_cache, k) - } - } - } - connection.TXpool_cache_lock.Unlock() - } - //} - } - case <-Exit_Event: - ticker.Stop() // release resources of timer - conn.Close() - Connection_Delete(&connection) - return // close the connection and close the routine - - } - } - }() - - if !incoming { - Connection_Add(&connection) // add outgoing connection to pool, incoming are added when handshake are done - connection.Send_Handshake(true) // send handshake request - } - - for { - - var command Sync_Struct // decode as sync minimum - - //connection.logger.Info("Waiting for frame") - if connection.IsExitInProgress() { - return - } - - //connection.logger.Infof("Waiting for data frame") - // no one should be able to request more than necessary amount of buffer - data_read := connection.Read_Data_Frame(0, uint32(config.STARGATE_HE_MAX_BLOCK_SIZE*2)) - - if connection.IsExitInProgress() { - return - } - //connection.logger.Info("frame received") - - // connection.logger.Infof(" data frame arrived %d", len(data_read)) - - // lets decode command and make sure we understand it - err = msgpack.Unmarshal(data_read, &command) - if err != nil { - rlog.Warnf("Error while decoding incoming frame err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() - return - } - - // check version sanctity - //connection.logger.Infof(" data frame parsed %+v", command) - - // till the time handshake is done, we donot process any commands - if atomic.LoadUint32(&connection.State) == HANDSHAKE_PENDING && !(command.Command == V2_COMMAND_HANDSHAKE || command.Command == V2_COMMAND_SYNC) { - // client sent something else when we were waiting for handshake, ban the peer - rlog.Warnf("Terminating connection, we were waiting for handshake but received %d %s", command.Command, globals.CTXString(connection.logger)) - - connection.Exit() - return - } - - //connection.logger.Debugf("v2 command incoming %d", command.Command) - - switch command.Command { - case V2_COMMAND_HANDSHAKE: - connection.Update(&command.Common) - connection.Handle_Handshake(data_read) - case V2_COMMAND_SYNC: - connection.Update(&command.Common) - connection.Handle_TimedSync(data_read) - case V2_COMMAND_CHAIN_REQUEST: - connection.Update(&command.Common) - connection.Handle_ChainRequest(data_read) - case V2_COMMAND_CHAIN_RESPONSE: - connection.Update(&command.Common) - connection.Handle_ChainResponse(data_read) - case V2_COMMAND_OBJECTS_REQUEST: - connection.Update(&command.Common) - connection.Handle_ObjectRequest(data_read) - case V2_COMMAND_OBJECTS_RESPONSE: - connection.Update(&command.Common) - connection.Handle_ObjectResponse(data_read) - case V2_NOTIFY_NEW_BLOCK: // for notification, instead of syncing, we will process notificaton first - connection.Handle_Notification_Block(data_read) - connection.Update(&command.Common) // we do it a bit later so we donot staart syncing - case V2_NOTIFY_NEW_TX: - connection.Update(&command.Common) - connection.Handle_Notification_Transaction(data_read) - case V2_NOTIFY_INVENTORY: - connection.Update(&command.Common) - connection.Handle_Incoming_Inventory(data_read) - - default: - connection.logger.Debugf("Unhandled v2 command %d", command.Command) - - } - - } - -} diff --git a/p2p/connection_pool.go b/p2p/connection_pool.go index 39e3a4c..9510401 100644 --- a/p2p/connection_pool.go +++ b/p2p/connection_pool.go @@ -36,14 +36,13 @@ import "encoding/binary" //import "container/list" import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" import "github.com/dustin/go-humanize" import log "github.com/sirupsen/logrus" import "github.com/paulbellamy/ratecounter" import "github.com/prometheus/client_golang/prometheus" import "github.com/deroproject/derohe/block" -import "github.com/deroproject/derohe/crypto" +import "github.com/deroproject/derohe/cryptography/crypto" import "github.com/deroproject/derohe/globals" import "github.com/deroproject/derohe/transaction" @@ -60,6 +59,7 @@ type Queued_Command struct { Command uint64 // we are waiting for this response BLID []crypto.Hash TXID []crypto.Hash + Topos []int64 } // This structure is used to do book keeping for the connection and keeps other DATA related to peer @@ -81,7 +81,6 @@ type Connection struct { Addr *net.TCPAddr // endpoint on the other end Port uint32 // port advertised by other end as its server,if it's 0 server cannot accept connections Peer_ID uint64 // Remote peer id - Lowcpuram bool // whether the peer has low cpu ram SyncNode bool // whether the peer has been added to command line as sync node Top_Version uint64 // current hard fork version supported by peer TXpool_cache map[uint64]uint32 // used for ultra blocks in miner mode,cache where we keep TX which have been broadcasted to this peer @@ -96,10 +95,11 @@ type Connection struct { Cumulative_Difficulty string // cumulative difficulty of top block of peer, this is NOT required CDIFF atomic.Value //*big.Int // NOTE: this field is used internally and is the parsed from Cumulative_Difficulty - logger *log.Entry // connection specific logger - logid string // formatted version of connection - Requested_Objects [][32]byte // currently unused as we sync up with a single peer at a time - Conn net.Conn // actual object to talk + logger *log.Entry // connection specific logger + logid string // formatted version of connection + Requested_Objects [][32]byte // currently unused as we sync up with a single peer at a time + Conn net.Conn // actual object to talk + RConn *RPC_Connection // object for communication // Command_queue *list.List // New protocol is partly syncronous Objects chan Queued_Command // contains all objects that are requested SpeedIn *ratecounter.RateCounter // average speed in last 60 seconds @@ -107,7 +107,11 @@ type Connection struct { request_time atomic.Value //time.Time // used to track latency writelock sync.Mutex // used to Serialize writes - sync.Mutex // used only by connection go routine + Mutex sync.Mutex // used only by connection go routine +} + +func (c *Connection) exit() { + c.RConn.Session.Close() } @@ -226,7 +230,7 @@ func Connection_Add(c *Connection) { if ip_count >= 8 || peer_id_count >= 4 { rlog.Warnf("IP address %s (%d) Peer ID %d(%d) already has too many connections, exiting this connection", incoming_ip, ip_count, incoming_peer_id, peer_id_count) - c.Exit() + c.exit() return } @@ -287,7 +291,7 @@ func Connection_Print() { // skip pending handshakes and skip ourselves if atomic.LoadUint32(&clist[i].State) == HANDSHAKE_PENDING || GetPeerID() == clist[i].Peer_ID { - continue + // continue } dir := "OUT" @@ -322,11 +326,11 @@ func Connection_Print() { if globals.Arguments["--debug"].(bool) == true { hstring := fmt.Sprintf("%d/%d/%d", clist[i].StableHeight, clist[i].Height, clist[i].TopoHeight) - fmt.Printf("%-20s %16x %5d %7s %7s %23s %s %5d %7s %7s %8s %9s %16s %s %x\n", clist[i].Addr.IP, clist[i].Peer_ID, clist[i].Port, state, time.Duration(atomic.LoadInt64(&clist[i].Latency)).Round(time.Millisecond).String(), hstring, dir, clist[i].IsConnectionSyncing(), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesIn)), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesOut)), humanize.Bytes(uint64(clist[i].SpeedIn.Rate()/60)), humanize.Bytes(uint64(clist[i].SpeedOut.Rate()/60)), version, tag, clist[i].StateHash[:]) + fmt.Printf("%-20s %16x %5d %7s %7s %23s %s %5d %7s %7s %8s %9s %16s %s %x\n", clist[i].Addr.IP, clist[i].Peer_ID, clist[i].Port, state, time.Duration(atomic.LoadInt64(&clist[i].Latency)).Round(time.Millisecond).String(), hstring, dir, clist[i].isConnectionSyncing(), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesIn)), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesOut)), humanize.Bytes(uint64(clist[i].SpeedIn.Rate()/60)), humanize.Bytes(uint64(clist[i].SpeedOut.Rate()/60)), version, tag, clist[i].StateHash[:]) } else { hstring := fmt.Sprintf("%d/%d", clist[i].Height, clist[i].TopoHeight) - fmt.Printf("%-20s %16x %5d %7s %7s %17s %s %5d %7s %7s %8s %9s %16s %s %x\n", clist[i].Addr.IP, clist[i].Peer_ID, clist[i].Port, state, time.Duration(atomic.LoadInt64(&clist[i].Latency)).Round(time.Millisecond).String(), hstring, dir, clist[i].IsConnectionSyncing(), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesIn)), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesOut)), humanize.Bytes(uint64(clist[i].SpeedIn.Rate()/60)), humanize.Bytes(uint64(clist[i].SpeedOut.Rate()/60)), version, tag, clist[i].StateHash[:8]) + fmt.Printf("%-20s %16x %5d %7s %7s %17s %s %5d %7s %7s %8s %9s %16s %s %x\n", clist[i].Addr.IP, clist[i].Peer_ID, clist[i].Port, state, time.Duration(atomic.LoadInt64(&clist[i].Latency)).Round(time.Millisecond).String(), hstring, dir, clist[i].isConnectionSyncing(), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesIn)), humanize.Bytes(atomic.LoadUint64(&clist[i].BytesOut)), humanize.Bytes(uint64(clist[i].SpeedIn.Rate()/60)), humanize.Bytes(uint64(clist[i].SpeedOut.Rate()/60)), version, tag, clist[i].StateHash[:8]) } @@ -375,7 +379,6 @@ func Disconnect_All() (Count uint64) { // this function return peer count which have successful handshake func Peer_Count() (Count uint64) { - connection_map.Range(func(k, value interface{}) bool { v := value.(*Connection) if atomic.LoadUint32(&v.State) != HANDSHAKE_PENDING && GetPeerID() != v.Peer_ID { @@ -383,10 +386,37 @@ func Peer_Count() (Count uint64) { } return true }) - return } +// this function has infinite loop to keep ping every few sec +func ping_loop() { + + for { + time.Sleep(5 * time.Second) + connection_map.Range(func(k, value interface{}) bool { + c := value.(*Connection) + if atomic.LoadUint32(&c.State) != HANDSHAKE_PENDING && GetPeerID() != c.Peer_ID { + go func() { + defer globals.Recover() + var dummy Dummy + fill_common(&dummy.Common) // fill common info + + ctime := time.Now() + if err := c.RConn.Client.Call("Peer.Ping", dummy, &dummy); err != nil { + return + } + took := time.Now().Sub(ctime) + c.update(&dummy.Common) // update common information + atomic.StoreInt64(&c.Latency, int64(took/2)) // divide by 2 is for round-trip + c.update(&dummy.Common) // update common information + }() + } + return true + }) + } +} + // this function returnw random connection which have successful handshake func Random_Connection(height int64) (c *Connection) { @@ -430,30 +460,18 @@ func Peer_Direction_Count() (Incoming uint64, Outgoing uint64) { // this function is trigger from 2 points, one when we receive a unknown block which can be successfully added to chain // second from the blockchain which has to relay locally mined blocks as soon as possible func Broadcast_Block(cbl *block.Complete_Block, PeerID uint64) { // if peerid is provided it is skipped - var request Notify_New_Objects_Struct + var cblock_serialized Complete_Block - defer func() { - if r := recover(); r != nil { - logger.Warnf("Recovered while broadcasting Block, Stack trace below %+v", r) - logger.Warnf("Stack trace \n%s", debug.Stack()) - } - }() + defer globals.Recover() /*if IsSyncing() { // if we are syncing, do NOT broadcast the block return }*/ - fill_common(&request.Common) // fill common info - request.Command = V2_NOTIFY_NEW_BLOCK - request.CBlock.Block = cbl.Bl.Serialize() + cblock_serialized.Block = cbl.Bl.Serialize() for i := range cbl.Txs { - request.CBlock.Txs = append(request.CBlock.Txs, cbl.Txs[i].Serialize()) - } - - serialized, err := msgpack.Marshal(&request) - if err != nil { - panic(err) + cblock_serialized.Txs = append(cblock_serialized.Txs, cbl.Txs[i].Serialize()) } our_height := chain.Get_Height() @@ -480,17 +498,13 @@ func Broadcast_Block(cbl *block.Complete_Block, PeerID uint64) { // if peerid is count++ go func(connection *Connection) { - defer func() { - if r := recover(); r != nil { - rlog.Warnf("Recovered while handling connection, Stack trace below", r) - rlog.Warnf("Stack trace \n%s", debug.Stack()) - } - }() - if globals.Arguments["--lowcpuram"].(bool) == false && connection.TXpool_cache != nil { // everyone needs ultrac compact block if possible - var miner_specific_request Notify_New_Objects_Struct - miner_specific_request.Common = request.Common - miner_specific_request.Command = V2_NOTIFY_NEW_BLOCK - miner_specific_request.CBlock.Block = request.CBlock.Block + defer globals.Recover() + + { // everyone needs ultra compact block if possible + var peer_specific_block Objects + + var cblock Complete_Block + cblock.Block = cblock_serialized.Block sent := 0 skipped := 0 @@ -500,7 +514,7 @@ func Broadcast_Block(cbl *block.Complete_Block, PeerID uint64) { // if peerid is // send only tx not found in cache if _, ok := connection.TXpool_cache[binary.LittleEndian.Uint64(cbl.Bl.Tx_hashes[i][:])]; !ok { - miner_specific_request.CBlock.Txs = append(miner_specific_request.CBlock.Txs, request.CBlock.Txs[i]) + cblock.Txs = append(cblock.Txs, cblock_serialized.Txs[i]) sent++ } else { @@ -511,31 +525,28 @@ func Broadcast_Block(cbl *block.Complete_Block, PeerID uint64) { // if peerid is connection.TXpool_cache_lock.RUnlock() connection.logger.Debugf("Sending ultra block to peer total %d tx skipped %d sent %d", len(cbl.Bl.Tx_hashes), skipped, sent) - - serialized_miner_specific, err := msgpack.Marshal(&miner_specific_request) - if err != nil { - panic(err) + peer_specific_block.CBlocks = append(peer_specific_block.CBlocks, cblock) + var dummy Dummy + fill_common(&peer_specific_block.Common) // fill common info + if err := connection.RConn.Client.Call("Peer.NotifyBlock", peer_specific_block, &dummy); err != nil { + return } - connection.Send_Message(serialized_miner_specific) // miners need ultra compact blocks + connection.update(&dummy.Common) // update common information - } else { - connection.logger.Debugf("Sending full block to peer") - - connection.Send_Message(serialized) // non miners need full blocks } }(v) } } - rlog.Infof("Broadcasted block %s to %d peers", cbl.Bl.GetHash(), count) + //rlog.Infof("Broadcasted block %s to %d peers", cbl.Bl.GetHash(), count) } // broadcast a new transaction, return to how many peers the transaction has been broadcasted // this function is trigger from 2 points, one when we receive a unknown tx // second from the mempool which may want to relay local ot soon going to expire transactions -func Broadcast_Tx(tx *transaction.Transaction, PeerID uint64) (relayed_count int) { +func Broadcast_Tx(tx *transaction.Transaction, PeerID uint64) (relayed_count int32) { defer func() { if r := recover(); r != nil { @@ -544,19 +555,12 @@ func Broadcast_Tx(tx *transaction.Transaction, PeerID uint64) (relayed_count int } }() - var request Object_Request_Struct + var request ObjectList fill_common_skip_topoheight(&request.Common) // fill common info, but skip topo height - request.Command = V2_NOTIFY_INVENTORY - txhash := tx.GetHash() request.Tx_list = append(request.Tx_list, txhash) - serialized, err := msgpack.Marshal(&request) - if err != nil { - panic(err) - } - our_height := chain.Get_Height() unique_map := UniqueConnections() @@ -579,7 +583,6 @@ func Broadcast_Tx(tx *transaction.Transaction, PeerID uint64) (relayed_count int continue } - relayed_count++ go func(connection *Connection) { defer func() { if r := recover(); r != nil { @@ -591,26 +594,34 @@ func Broadcast_Tx(tx *transaction.Transaction, PeerID uint64) (relayed_count int resend := true // disable cache if not possible due to options // assuming the peer is good, he would like to obtain the tx ASAP - if globals.Arguments["--lowcpuram"].(bool) == false && connection.TXpool_cache != nil { - connection.TXpool_cache_lock.Lock() - if _, ok := connection.TXpool_cache[binary.LittleEndian.Uint64(txhash[:])]; !ok { - connection.TXpool_cache[binary.LittleEndian.Uint64(txhash[:])] = uint32(time.Now().Unix()) - resend = true - } else { - resend = false - } - connection.TXpool_cache_lock.Unlock() + + connection.TXpool_cache_lock.Lock() + if _, ok := connection.TXpool_cache[binary.LittleEndian.Uint64(txhash[:])]; !ok { + connection.TXpool_cache[binary.LittleEndian.Uint64(txhash[:])] = uint32(time.Now().Unix()) + resend = true + } else { + resend = false } + connection.TXpool_cache_lock.Unlock() if resend { - connection.Send_Message(serialized) // send the bytes + var dummy Dummy + fill_common(&dummy.Common) // fill common info + if err := connection.RConn.Client.Call("Peer.NotifyINV", request, &dummy); err != nil { + return + } + connection.update(&dummy.Common) // update common information + + atomic.AddInt32(&relayed_count, 1) } }(v) } } - //rlog.Infof("Broadcasted tx %s to %d peers", txhash, relayed_count) + if relayed_count > 0 { + rlog.Debugf("Broadcasted tx %s to %d peers", txhash, relayed_count) + } return } @@ -620,7 +631,7 @@ func Broadcast_Tx(tx *transaction.Transaction, PeerID uint64) (relayed_count int // if objects response are queued, we are syncing // if even one of the connection is syncing, then we are syncronising // returns a number how many blocks are queued -func (connection *Connection) IsConnectionSyncing() (count int) { +func (connection *Connection) isConnectionSyncing() (count int) { //connection.Lock() //defer connection.Unlock() @@ -632,7 +643,7 @@ func (connection *Connection) IsConnectionSyncing() (count int) { // so we can try some other connection if len(connection.Objects) > 0 { if time.Now().Unix() >= (13 + atomic.LoadInt64(&connection.LastObjectRequestTime)) { - connection.Exit() + connection.exit() return 0 } } @@ -684,7 +695,16 @@ func trigger_sync() { connection.logger.Debugf("We need to resync with the peer height %d", connection.Height) //connection.Unlock() // set mode to syncronising - connection.Send_ChainRequest() + + if chain.Sync { + //fmt.Printf("chain send chain request disabled\n") + connection.sync_chain() + connection.logger.Debugf("sync done ") + + } else { // we need a state only sync, bootstrap without history but verified chain + connection.bootstrap_chain() + chain.Sync = true + } break } } @@ -700,7 +720,7 @@ func IsSyncing() (result bool) { syncing := false connection_map.Range(func(k, value interface{}) bool { v := value.(*Connection) - if v.IsConnectionSyncing() != 0 { + if v.isConnectionSyncing() != 0 { syncing = true return false } @@ -724,5 +744,4 @@ func syncroniser() { } } - } diff --git a/p2p/controller.go b/p2p/controller.go index 702a226..092fe4c 100644 --- a/p2p/controller.go +++ b/p2p/controller.go @@ -19,6 +19,7 @@ package p2p //import "os" import "fmt" import "net" +import "net/rpc" import "time" import "sort" import "strings" @@ -60,6 +61,8 @@ var nonbanlist []string // any ips in this list will never be banned func P2P_Init(params map[string]interface{}) error { logger = globals.Logger.WithFields(log.Fields{"com": "P2P"}) // all components must use this logger + // register_handlers() + GetPeerID() // Initialize peer id once // parse node tag if availble @@ -110,6 +113,7 @@ func P2P_Init(params map[string]interface{}) error { go P2P_engine() // start outgoing engine go syncroniser() // start sync engine go clean_up_propagation() // clean up propagation map + go ping_loop() // keep pinging logger.Infof("P2P started") atomic.AddUint32(&globals.Subsystem_Active, 1) // increment subsystem return nil @@ -201,7 +205,7 @@ func connect_with_endpoint(endpoint string, sync_node bool) { // check whether are already connected to this address if yes, return if IsAddressConnected(remote_ip.String()) { - return + return //nil, fmt.Errorf("Already connected") } // since we may be connecting through socks, grab the remote ip for our purpose rightnow @@ -212,7 +216,7 @@ func connect_with_endpoint(endpoint string, sync_node bool) { if err != nil { rlog.Warnf("Dial failed err %s", err.Error()) Peer_SetFail(remote_ip.String()) // update peer list as we see - return + return //nil, fmt.Errorf("Dial failed err %s", err.Error()) } tcpc := conn.(*net.TCPConn) @@ -230,9 +234,9 @@ func connect_with_endpoint(endpoint string, sync_node bool) { // TODO we need to choose fastest cipher here ( so both clients/servers are not loaded) conn = tls.Client(conn, &tls.Config{InsecureSkipVerify: true}) - // success is setup after handshake is done - rlog.Debugf("Connection established to %s", remote_ip) - Handle_Connection(conn, remote_ip, false, sync_node) // handle connection + process_connection(conn, remote_ip, false, sync_node) + + //Handle_Connection(conn, remote_ip, false, sync_node) // handle connection } // maintains a persistant connection to endpoint @@ -379,11 +383,47 @@ func P2P_Server_v2() { tcpc.SetLinger(0) // discard any pending data tlsconn := tls.Server(conn, tlsconfig) - go Handle_Connection(tlsconn, raddr, true, false) // handle connection in a different go routine - - //go Handle_Connection(conn, raddr, true, false) // handle connection in a different go routine + go process_connection(tlsconn, raddr, true, false) // handle connection in a different go routine } } + +} + +func process_connection(conn net.Conn, remote_addr *net.TCPAddr, incoming, sync_node bool) { + defer globals.Recover() + + var rconn *RPC_Connection + var err error + if incoming { + rconn, err = wait_stream_creation_server_side(conn) // do server side processing + } else { + rconn, err = stream_creation_client_side(conn) // do client side processing + } + if err == nil { + + var RPCSERVER = rpc.NewServer() + c := &Connection{RConn: rconn, Addr: remote_addr, State: HANDSHAKE_PENDING, Incoming: incoming, SyncNode: sync_node} + RPCSERVER.RegisterName("Peer", c) // register the handlers + + if incoming { + c.logger = logger.WithFields(log.Fields{"RIP": remote_addr.String(), "DIR": "INC"}) + } else { + c.logger = logger.WithFields(log.Fields{"RIP": remote_addr.String(), "DIR": "OUT"}) + } + go func() { + defer globals.Recover() + //RPCSERVER.ServeConn(rconn.ServerConn) // start single threaded rpc server with GOB encoding + RPCSERVER.ServeCodec(NewCBORServerCodec(rconn.ServerConn)) // use CBOR encoding on rpc + }() + + c.dispatch_test_handshake() + + <-rconn.Session.CloseChan() + Connection_Delete(c) + //fmt.Printf("closing connection status err: %s\n",err) + } + conn.Close() + } // shutdown the p2p component @@ -456,3 +496,29 @@ func generate_random_tls_cert() tls.Certificate { } return tlsCert } + +/* +// register all the handlers +func register_handlers(){ + arpc.DefaultHandler.Handle("/handshake",Handshake_Handler) + arpc.DefaultHandler.Handle("/active",func (ctx *arpc.Context) { // set the connection active + if c,ok := ctx.Client.Get("connection");ok { + connection := c.(*Connection) + atomic.StoreUint32(&connection.State, ACTIVE) + }} ) + + arpc.DefaultHandler.HandleConnected(OnConnected_Handler) // all incoming connections will first processed here +arpc.DefaultHandler.HandleDisconnected(OnDisconnected_Handler) // all disconnected +} + + + +// triggers when new clients connect and +func OnConnected_Handler(c *arpc.Client){ + dispatch_test_handshake(c, c.Conn.RemoteAddr().(*net.TCPAddr) ,true,false) // client connected we must handshake +} + +func OnDisconnected_Handler(c *arpc.Client){ + c.Stop() +} +*/ diff --git a/p2p/handshake.go b/p2p/handshake.go deleted file mode 100644 index 7a3c8a4..0000000 --- a/p2p/handshake.go +++ /dev/null @@ -1,196 +0,0 @@ -// Copyright 2017-2021 DERO Project. All rights reserved. -// Use of this source code in any form is governed by RESEARCH license. -// license can be found in the LICENSE file. -// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 -// -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL -// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF -// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -package p2p - -import "fmt" -import "bytes" - -//import "net" -import "sync/atomic" -import "time" - -//import "container/list" - -//import log "github.com/sirupsen/logrus" -//import "github.com/allegro/bigcache" -import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" - -import "github.com/deroproject/derohe/config" -import "github.com/deroproject/derohe/globals" - -//import "github.com/deroproject/derosuite/blockchain" - -// reads our data, length prefix blocks -func (connection *Connection) Send_Handshake(request bool) { - - var handshake Handshake_Struct - - fill_common(&handshake.Common) // fill common info - handshake.Command = V2_COMMAND_HANDSHAKE - handshake.Request = request - - // TODO these version strings should be setup during build - // original protocol in c daemon should be called version 1 - // the new version is version 2 - handshake.ProtocolVersion = "1.0.0" - handshake.DaemonVersion = config.Version.String() - handshake.Tag = node_tag - handshake.UTC_Time = int64(time.Now().UTC().Unix()) // send our UTC time - handshake.Local_Port = uint32(P2P_Port) // export requested or default port - handshake.Peer_ID = GetPeerID() // give our randomly generated peer id - handshake.Pruned = chain.LocatePruneTopo() - if globals.Arguments["--lowcpuram"].(bool) == false { - handshake.Flags = append(handshake.Flags, FLAG_LOWCPURAM) // add low cpu ram flag - } - - //scan our peer list and send peers which have been recently communicated - handshake.PeerList = get_peer_list() - copy(handshake.Network_ID[:], globals.Config.Network_ID[:]) - - // serialize and send - serialized, err := msgpack.Marshal(&handshake) - if err != nil { - panic(err) - } - - rlog.Tracef(2, "handshake sent %s", globals.CTXString(connection.logger)) - connection.Send_Message(serialized) -} - -// verify incoming handshake for number of checks such as mainnet/testnet etc etc -func (connection *Connection) Verify_Handshake(handshake *Handshake_Struct) bool { - return bytes.Equal(handshake.Network_ID[:], globals.Config.Network_ID[:]) -} - -// handles both server and client connections -func (connection *Connection) Handle_Handshake(buf []byte) { - - var handshake Handshake_Struct - - err := msgpack.Unmarshal(buf, &handshake) - if err != nil { - rlog.Warnf("Error while decoding incoming handshake request err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() - return - } - - if !connection.Verify_Handshake(&handshake) { // if not same network boot off - connection.logger.Debugf("kill connection network id mismatch peer network id %x", handshake.Network_ID) - connection.Exit() - return - } - - rlog.Tracef(2, "handshake response received %+v %s", handshake, globals.CTXString(connection.logger)) - - // check if self connection exit - if connection.Incoming && handshake.Peer_ID == GetPeerID() { - rlog.Tracef(1, "Same peer ID, probably self connection, disconnecting from this client") - connection.Exit() - return - } - - if handshake.Request { - connection.Send_Handshake(false) // send it as response - } - if !connection.Incoming { // setup success - Peer_SetSuccess(connection.Addr.String()) - } - - connection.Update(&handshake.Common) // update common information - - if atomic.LoadUint32(&connection.State) == HANDSHAKE_PENDING { // some of the fields are processed only while initial handshake - connection.Lock() - if len(handshake.ProtocolVersion) < 128 { - connection.ProtocolVersion = handshake.ProtocolVersion - } - - if len(handshake.DaemonVersion) < 128 { - connection.DaemonVersion = handshake.DaemonVersion - } - connection.Port = handshake.Local_Port - connection.Peer_ID = handshake.Peer_ID - if len(handshake.Tag) < 128 { - connection.Tag = handshake.Tag - } - if handshake.Pruned >= 0 { - connection.Pruned = handshake.Pruned - } - - // TODO we must also add the peer to our list - // which can be distributed to other peers - if connection.Port != 0 && connection.Port <= 65535 { // peer is saying it has an open port, handshake is success so add peer - - var p Peer - if connection.Addr.IP.To4() != nil { // if ipv4 - p.Address = fmt.Sprintf("%s:%d", connection.Addr.IP.String(), connection.Port) - } else { // if ipv6 - p.Address = fmt.Sprintf("[%s]:%d", connection.Addr.IP.String(), connection.Port) - } - p.ID = connection.Peer_ID - - p.LastConnected = uint64(time.Now().UTC().Unix()) - - /* TODO we should add any flags here if necessary, but they are not - required, since a peer can only be used if connected and if connected - we already have a truly synced view - for _, k := range handshake.Flags { - switch k { - case FLAG_MINER: - p.Miner = true - } - }*/ - - Peer_Add(&p) - } - - for _, k := range handshake.Flags { - switch k { - case FLAG_LOWCPURAM: - connection.Lowcpuram = true - - //connection.logger.Debugf("Miner flag \"%s\" from peer", k) - default: - connection.logger.Debugf("Unknown flag \"%s\" from peer, ignoring", k) - - } - - } - - // do NOT build TX cache, if we are runnin in lowcpu mode - if globals.Arguments["--lowcpuram"].(bool) == true { // if connection is not running in low cpu mode and we are also same, activate transaction cache - connection.TXpool_cache = nil - } else { // we do not have any limitation, activate per peer cache - connection.TXpool_cache = map[uint64]uint32{} - - } - connection.Unlock() - } - - // parse delivered peer list as grey list - rlog.Debugf("Peer provides %d peers", len(handshake.PeerList)) - for i := range handshake.PeerList { - if i < 13 { - Peer_Add(&Peer{Address: handshake.PeerList[i].Addr, LastConnected: uint64(time.Now().UTC().Unix())}) - } - } - - atomic.StoreUint32(&connection.State, ACTIVE) - if connection.Incoming { - Connection_Add(connection) - } -} diff --git a/p2p/inventory_handler.go b/p2p/inventory_handler.go deleted file mode 100644 index f17b2c0..0000000 --- a/p2p/inventory_handler.go +++ /dev/null @@ -1,135 +0,0 @@ -// Copyright 2017-2021 DERO Project. All rights reserved. -// Use of this source code in any form is governed by RESEARCH license. -// license can be found in the LICENSE file. -// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 -// -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL -// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF -// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -package p2p - -//import "fmt" -//import "net" -import "sync/atomic" -import "time" - -//import "container/list" - -import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" - -//import "github.com/deroproject/derosuite/crypto" -//import "github.com/deroproject/derosuite/globals" - -import "github.com/deroproject/derohe/crypto" - -//import "github.com/deroproject/derosuite/globals" - -//import "github.com/deroproject/derosuite/blockchain" - -// we are sending object request -// right now we only send block ids -func (connection *Connection) Send_Inventory(blids []crypto.Hash, txids []crypto.Hash) { - - var request Object_Request_Struct - fill_common(&request.Common) // fill common info - request.Command = V2_NOTIFY_INVENTORY - - for i := range blids { - request.Block_list = append(request.Block_list, blids[i]) - } - - for i := range txids { - request.Tx_list = append(request.Tx_list, txids[i]) - } - - if len(blids) > 0 || len(txids) > 0 { - serialized, err := msgpack.Marshal(&request) // serialize and send - if err != nil { - panic(err) - } - - // use first object - - command := Queued_Command{Command: V2_COMMAND_OBJECTS_RESPONSE, BLID: blids, TXID: txids} - - connection.Objects <- command - atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) - - // we should add to queue that we are waiting for object response - //command := Queued_Command{Command: V2_COMMAND_OBJECTS_RESPONSE, BLID: blids, TXID: txids, Started: time.Now()} - - connection.Lock() - //connection.Command_queue.PushBack(command) // queue command - connection.Send_Message_prelocked(serialized) - connection.Unlock() - rlog.Tracef(3, "object request sent contains %d blids %d txids %s ", len(blids), connection.logid) - } -} - -// peer has given his list of inventory -// if certain object is not in our list we request with the inventory -// if everything is already in our inventory, do nothing ignore -func (connection *Connection) Handle_Incoming_Inventory(buf []byte) { - var request Object_Request_Struct - var response Object_Request_Struct - - var blids, txids []crypto.Hash - - var dirty = false - - err := msgpack.Unmarshal(buf, &request) - if err != nil { - rlog.Warnf("Error while decoding incoming object request err %s %s", err, connection.logid) - connection.Exit() - } - - if len(request.Block_list) >= 1 { // handle incoming blocks list - for i := range request.Block_list { // - if !chain.Is_Block_Topological_order(request.Block_list[i]) { // block is not in our chain - if !chain.Block_Exists(request.Block_list[i]) { // check whether the block can be loaded from disk - response.Block_list = append(response.Block_list, request.Block_list[i]) - blids = append(blids, request.Block_list[i]) - dirty = true - } - } - } - } - - if len(request.Tx_list) >= 1 { // handle incoming tx list and see whether it exists in mempoolor regpool - for i := range request.Tx_list { // - if !(chain.Mempool.Mempool_TX_Exist(request.Tx_list[i]) || chain.Regpool.Regpool_TX_Exist(request.Tx_list[i])) { // check if is already in mempool skip it - if _, err = chain.Store.Block_tx_store.ReadTX(request.Tx_list[i]); err != nil { // check whether the tx can be loaded from disk - response.Tx_list = append(response.Tx_list, request.Tx_list[i]) - txids = append(txids, request.Tx_list[i]) - dirty = true - } - } - } - } - - if dirty { // request inventory only if we want it - fill_common(&response.Common) // fill common info - response.Command = V2_COMMAND_OBJECTS_REQUEST - serialized, err := msgpack.Marshal(&response) // serialize and send - if err != nil { - panic(err) - } - - command := Queued_Command{Command: V2_COMMAND_OBJECTS_RESPONSE, BLID: blids, TXID: txids} - connection.Objects <- command - atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) - - rlog.Tracef(3, "OBJECT REQUEST SENT sent size %d %s", len(serialized), connection.logid) - connection.Send_Message(serialized) - } - -} diff --git a/p2p/object_pool.go b/p2p/object_pool.go deleted file mode 100644 index c53d758..0000000 --- a/p2p/object_pool.go +++ /dev/null @@ -1,136 +0,0 @@ -// Copyright 2017-2021 DERO Project. All rights reserved. -// Use of this source code in any form is governed by RESEARCH license. -// license can be found in the LICENSE file. -// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 -// -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL -// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF -// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -package p2p - -//import "fmt" -//import "net" -import "sync" -import "time" - -//import "container/list" - -//import log "github.com/sirupsen/logrus" -//import "github.com/vmihailenco/msgpack" - -import "github.com/deroproject/derohe/crypto" - -//import "github.com/deroproject/derosuite/globals" - -import "github.com/deroproject/derohe/block" - -// if block request pool is empty, we are syncronised otherwise we are syncronising -var block_request_pool = map[crypto.Hash]uint64{} // these are received, we must attach a connection to blacklist peers - -var block_received = map[crypto.Hash]*block.Complete_Block{} // once blocks are received, they are placed here -var block_request_pool_mutex sync.Mutex - -func queue_block(blid crypto.Hash) { - block_request_pool_mutex.Lock() - defer block_request_pool_mutex.Unlock() - - // if object has already been received, it no longer should be request - if _, ok := block_received[blid]; ok { // object is already in pool - return - } - - // if object has already been requested, skip it , else add it to queue - if _, ok := block_request_pool[blid]; !ok { - block_request_pool[blid] = 0 - } -} - -// a block hash been received, make it ready for consumption -func queue_block_received(blid crypto.Hash, cbl *block.Complete_Block) { - block_request_pool_mutex.Lock() - defer block_request_pool_mutex.Unlock() - - if _, ok := block_request_pool[blid]; !ok { - // unknown object received discard it - return - } - delete(block_request_pool, blid) - - block_received[blid] = cbl -} - -// continusly retrieve_objects -func retrieve_objects() { - - for { - select { - case <-Exit_Event: - return - case <-time.After(5 * time.Second): - } - - block_request_pool_mutex.Lock() - - for k, _ := range block_request_pool { - - connection := Random_Connection(0) - if connection != nil { - connection.Send_ObjectRequest([]crypto.Hash{k}, []crypto.Hash{}) - } - } - block_request_pool_mutex.Unlock() - - } - -} - -// this goroutine will keep searching the queue for any blocks and see if they are can be attached somewhere, if yes they will be attached and cleaned up -func sync_retrieved_blocks() { - // success := make(chan bool) - for { - - select { - case <-Exit_Event: - return - //case <- success: - case <-time.After(1 * time.Second): - } - - block_request_pool_mutex.Lock() - - for blid, cbl := range block_received { - if chain.Is_Block_Topological_order(blid) { /// block is already in chain, discard it - delete(block_received, blid) - continue - } - _ = cbl - /*if cbl == nil { - delete(block_received,blid) - block_request_pool[blid]=0 // need to request object again - continue - }*/ - - /* - // attach it to parent, else skip for now - if chain.Block_Exists(cbl.Bl.Prev_Hash) { - if chain.Add_Complete_Block(cbl) { - // if block successfully added , delete it now - delete(block_received, blid) - - continue - } else { // checksum of something failed, request it randomly from another peer - block_request_pool[blid] = 0 - } - }*/ - } - block_request_pool_mutex.Unlock() - } -} diff --git a/p2p/object_response.go b/p2p/object_response.go deleted file mode 100644 index afce8fd..0000000 --- a/p2p/object_response.go +++ /dev/null @@ -1,160 +0,0 @@ -// Copyright 2017-2021 DERO Project. All rights reserved. -// Use of this source code in any form is governed by RESEARCH license. -// license can be found in the LICENSE file. -// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 -// -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL -// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF -// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -package p2p - -//import "fmt" -//import "net" -import "sync/atomic" -import "time" - -//import "container/list" - -//import log "github.com/sirupsen/logrus" -import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" - -//import "github.com/deroproject/derosuite/crypto" -//import "github.com/deroproject/derosuite/globals" - -import "github.com/deroproject/derohe/block" -import "github.com/deroproject/derohe/errormsg" -import "github.com/deroproject/derohe/transaction" - -// peer has responded with some objects, we must respond -func (connection *Connection) Handle_ObjectResponse(buf []byte) { - var response Object_Response_struct - - err := msgpack.Unmarshal(buf, &response) - if err != nil { - rlog.Warnf("Error while decoding incoming object response err %s %s", err, connection.logid) - connection.Exit() - } - - var expected Queued_Command - - select { - case expected = <-connection.Objects: - - default: // if nothing is on queue the peer sent us bogus request, - rlog.Warnf("Peer sent us a chain response, when we didnot request chain, Exiting, may be block the peer %s", connection.logid) - connection.Exit() - } - - if expected.Command != V2_COMMAND_OBJECTS_RESPONSE { - rlog.Warnf("We were waiting for a different object, but peer sent something else, Exiting, may be block the peer %s", connection.logid) - connection.Exit() - } - - // we need to verify common and update common - - if len(response.CBlocks) != len(expected.BLID) { // we requested x block , peer sent us y blocks, time to ban peer - rlog.Warnf("we got %d response for %d requests %s %s", len(response.CBlocks), len(expected.BLID), connection.logid) - } - - if len(response.Txs) != len(expected.TXID) { // we requested x block , peer sent us y blocks, time to ban peer - rlog.Warnf("we got %d response for %d requests %s %s", len(response.CBlocks), len(expected.BLID), connection.logid) - } - - // make sure connection does not timeout and be killed while processing huge blocks - processing_complete := make(chan bool) - go func() { - ticker := time.NewTicker(500 * time.Millisecond) - defer ticker.Stop() - for { - select { - case <- processing_complete: return // complete the loop - case <-ticker.C:// give the chain some more time to respond - atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) - } - } - }() - - defer func() { - processing_complete <- true - }() - - - for i := 0; i < len(response.CBlocks); i++ { // process incoming full blocks - var cbl block.Complete_Block // parse incoming block and deserialize it - var bl block.Block - // lets deserialize block first and see whether it is the requested object - cbl.Bl = &bl - err := bl.Deserialize(response.CBlocks[i].Block) - if err != nil { // we have a block which could not be deserialized ban peer - rlog.Warnf("Error Incoming block could not be deserilised err %s %s", err, connection.logid) - connection.Exit() - return - } - - // check if deserialized hash is same as what we requested - if bl.GetHash() != expected.BLID[i] { // user is trying to spoof block, ban hime - connection.logger.Warnf("requested and response block mismatch") - rlog.Warnf("Error block hash mismatch Actual %s Expected %s err %s %s", bl.GetHash(), expected.BLID[i], connection.logid) - connection.Exit() - } - - // give the chain some more time to respond - atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) - - // check whether the object was requested one - - // complete the txs - for j := range response.CBlocks[i].Txs { - var tx transaction.Transaction - err = tx.DeserializeHeader(response.CBlocks[i].Txs[j]) - if err != nil { // we have a tx which could not be deserialized ban peer - rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, connection.logid) - connection.Exit() - - return - } - cbl.Txs = append(cbl.Txs, &tx) - } - - // check if we can add ourselves to chain - err, ok := chain.Add_Complete_Block(&cbl) - if !ok && err == errormsg.ErrInvalidPoW { - connection.logger.Warnf("This peer should be banned") - connection.Exit() - return - } - - if !ok && err == errormsg.ErrPastMissing { - rlog.Warnf("Error Incoming Block coould not be added due to missing past, so skipping future block err %s %s", err, connection.logid) - return - } - - // add the object to object pool from where it will be consume - // queue_block_received(bl.GetHash(),&cbl) - - } - - for i := range response.Txs { // process incoming txs for mempool - if !chain.Mempool.Mempool_TX_Exist(expected.TXID[i]) { // we still donot have it, so try to process it - var tx transaction.Transaction - err = tx.DeserializeHeader(response.Txs[i]) - if err != nil { // we have a tx which could not be deserialized ban peer - rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, connection.logid) - connection.Exit() - - return - } - chain.Add_TX_To_Pool(&tx) // currently we are ignoring error - } - } - -} diff --git a/p2p/rpc.go b/p2p/rpc.go new file mode 100644 index 0000000..b8d0686 --- /dev/null +++ b/p2p/rpc.go @@ -0,0 +1,87 @@ +package p2p + +// this function implements bidirectional rpc using yamux multiplexor +//import "fmt" +import "net" +import "net/rpc" +import "time" +import "io/ioutil" +import "github.com/hashicorp/yamux" + +type RPC_Connection struct { + ClientConn net.Conn // its used to trigger requests + Client *rpc.Client // used to dispatch RPC requests + + ServerConn net.Conn // its used to serve requests + + Session *yamux.Session + Conn net.Conn // connection backing everything +} + +func yamux_config() *yamux.Config { + return &yamux.Config{ + AcceptBacklog: 2, + EnableKeepAlive: false, + KeepAliveInterval: 5 * time.Second, + ConnectionWriteTimeout: 17 * time.Second, + MaxStreamWindowSize: uint32(256 * 1024), + LogOutput: ioutil.Discard, + } +} + +// do server side processing +func wait_stream_creation_server_side(conn net.Conn) (*RPC_Connection, error) { + + session, err := yamux.Server(conn, yamux_config()) // Setup server side of yamux + if err != nil { + conn.Close() + panic(err) + } + + // Accept a stream + client, err := session.Accept() + if err != nil { + panic(err) + } + + server, err := session.Accept() + if err != nil { + panic(err) + } + + rconn := &RPC_Connection{ClientConn: client, ServerConn: server, Session: session, Conn: conn} + rconn.common_processing() + return rconn, nil +} + +// do client side processing +func stream_creation_client_side(conn net.Conn) (*RPC_Connection, error) { + session, err := yamux.Client(conn, yamux_config()) // Setup client side of yamux + if err != nil { + conn.Close() + panic(err) + } + + // create a stream + client, err := session.Open() + if err != nil { + panic(err) + } + //create a stream + server, err := session.Open() + if err != nil { + panic(err) + } + + rconn := &RPC_Connection{ClientConn: server, ServerConn: client, Session: session, Conn: conn} // this line is flipped between client/server + rconn.common_processing() + return rconn, nil +} + +func (r *RPC_Connection) common_processing() { + //r.Client = rpc.NewClient(r.ClientConn) // will use GOB encoding, but doesn't have certain protections + r.Client = rpc.NewClientWithCodec(NewCBORClientCodec(r.ClientConn)) // will use CBOR encoding with protections + + // fmt.Printf("client connection %+v\n", r.Client) + +} diff --git a/p2p/rpc_cbor_codec.go b/p2p/rpc_cbor_codec.go new file mode 100644 index 0000000..c318eb3 --- /dev/null +++ b/p2p/rpc_cbor_codec.go @@ -0,0 +1,188 @@ +package p2p + +// this file implements CBOR codec to prevent from certain attacks +import "fmt" +import "io" +import "net" +import "net/rpc" +import "bufio" +import "encoding/binary" +import "github.com/fxamacker/cbor" + +import "github.com/deroproject/derohe/config" // only used get constants such as max data per frame + +// used to represent net/rpc structs +type Request struct { + ServiceMethod string `cbor:"M"` // format: "Service.Method" + Seq uint64 `cbor:"S"` // sequence number chosen by client +} + +type Response struct { + ServiceMethod string `cbor:"M"` // echoes that of the Request + Seq uint64 `cbor:"S"` // echoes that of the request + Error string `cbor:"E"` // error, if any. +} + +// reads our data, length prefix blocks +func Read_Data_Frame(r io.Reader, obj interface{}) error { + var frame_length_buf [4]byte + + //connection.set_timeout() + nbyte, err := io.ReadFull(r, frame_length_buf[:]) + if err != nil { + return err + } + if nbyte != 4 { + return fmt.Errorf("needed 4 bytes, but got %d bytes", nbyte) + } + + // time to ban + frame_length := binary.LittleEndian.Uint32(frame_length_buf[:]) + if frame_length == 0 { + return nil + } + // most probably memory DDOS attack, kill the connection + if uint64(frame_length) > (5 * config.STARGATE_HE_MAX_BLOCK_SIZE) { + return fmt.Errorf("Frame length is too big Expected %d Actual %d %s", 5*config.STARGATE_HE_MAX_BLOCK_SIZE, frame_length) + } + data_buf := make([]byte, frame_length) + data_size, err := io.ReadFull(r, data_buf) + if err != nil || data_size <= 0 || uint32(data_size) != frame_length { + return fmt.Errorf("Could not read data size read %d, frame length %d err %s", data_size, frame_length, err) + } + data_buf = data_buf[:frame_length] + err = cbor.Unmarshal(data_buf, obj) + + //fmt.Printf("Read object %+v raw %s\n",obj, data_buf) + return err +} + +// reads our data, length prefix blocks +func Write_Data_Frame(w io.Writer, obj interface{}) error { + var frame_length_buf [4]byte + data_bytes, err := cbor.Marshal(obj) + if err != nil { + return err + } + binary.LittleEndian.PutUint32(frame_length_buf[:], uint32(len(data_bytes))) + + if _, err = w.Write(frame_length_buf[:]); err != nil { + return err + } + _, err = w.Write(data_bytes[:]) + //fmt.Printf("Wrote object %+v raw %s\n",obj, data_bytes) + return err +} + +// ClientCodec implements the rpc.ClientCodec interface for generic golang objects. +type ClientCodec struct { + r *bufio.Reader + w io.WriteCloser +} + +// ServerCodec implements the rpc.ServerCodec interface for generic protobufs. +type ServerCodec ClientCodec + +// NewClientCodec returns a ClientCodec for communicating with the ServerCodec +// on the other end of the conn. +func NewCBORClientCodec(conn net.Conn) *ClientCodec { + return &ClientCodec{bufio.NewReader(conn), conn} +} + +// NewServerCodec returns a ServerCodec that communicates with the ClientCodec +// on the other end of the given conn. +func NewCBORServerCodec(conn net.Conn) *ServerCodec { + return &ServerCodec{bufio.NewReader(conn), conn} +} + +// WriteRequest writes the 4 byte length from the connection and encodes that many +// subsequent bytes into the given object. +func (c *ClientCodec) WriteRequest(req *rpc.Request, obj interface{}) error { + // Write the header + header := Request{ServiceMethod: req.ServiceMethod, Seq: req.Seq} + if err := Write_Data_Frame(c.w, header); err != nil { + return err + } + return Write_Data_Frame(c.w, obj) +} + +// ReadResponseHeader reads a 4 byte length from the connection and decodes that many +// subsequent bytes into the given object, decodes it, and stores the fields +// in the given request. +func (c *ClientCodec) ReadResponseHeader(resp *rpc.Response) error { + var header Response + if err := Read_Data_Frame(c.r, &header); err != nil { + return err + } + if header.ServiceMethod == "" { + return fmt.Errorf("header missing method: %s", header) + } + resp.ServiceMethod = header.ServiceMethod + resp.Seq = header.Seq + resp.Error = header.Error + + return nil +} + +// ReadResponseBody reads a 4 byte length from the connection and decodes that many +// subsequent bytes into the given object (which should be a pointer to a +// struct). +func (c *ClientCodec) ReadResponseBody(obj interface{}) error { + if obj == nil { + return nil + } + return Read_Data_Frame(c.r, obj) +} + +// Close closes the underlying connection. +func (c *ClientCodec) Close() error { + return c.w.Close() +} + +// Close closes the underlying connection. +func (c *ServerCodec) Close() error { + return c.w.Close() +} + +// ReadRequestHeader reads the header (which is prefixed by a 4 byte lil endian length +// indicating its size) from the connection, decodes it, and stores the fields +// in the given request. +func (s *ServerCodec) ReadRequestHeader(req *rpc.Request) error { + var header Request + if err := Read_Data_Frame(s.r, &header); err != nil { + return err + } + if header.ServiceMethod == "" { + return fmt.Errorf("header missing method: %s", header) + } + req.ServiceMethod = header.ServiceMethod + req.Seq = header.Seq + return nil +} + +// ReadRequestBody reads a 4 byte length from the connection and decodes that many +// subsequent bytes into the object +func (s *ServerCodec) ReadRequestBody(obj interface{}) error { + if obj == nil { + return nil + } + return Read_Data_Frame(s.r, obj) +} + +// WriteResponse writes the appropriate header. If +// the response was invalid, the size of the body of the resp is reported as +// having size zero and is not sent. +func (s *ServerCodec) WriteResponse(resp *rpc.Response, obj interface{}) error { + // Write the header + header := Response{ServiceMethod: resp.ServiceMethod, Seq: resp.Seq, Error: resp.Error} + + if err := Write_Data_Frame(s.w, header); err != nil { + return err + } + + if resp.Error == "" { // only write response object if error is nil + return Write_Data_Frame(s.w, obj) + } + + return nil +} diff --git a/p2p/chain_request.go b/p2p/rpc_chain_request.go similarity index 56% rename from p2p/chain_request.go rename to p2p/rpc_chain_request.go index 22be789..b5b101f 100644 --- a/p2p/chain_request.go +++ b/p2p/rpc_chain_request.go @@ -18,108 +18,46 @@ package p2p //import "fmt" //import "net" -import "sync/atomic" -import "time" //import "container/list" //import log "github.com/sirupsen/logrus" import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" //import "github.com/deroproject/derosuite/crypto" import "github.com/deroproject/derohe/globals" //import "github.com/deroproject/derosuite/blockchain" -// we are sending a chain request, build a packet with our chain data -// so as other side can respond with chain response -func (connection *Connection) Send_ChainRequest() { - var request Chain_Request_Struct - - fill_common(&request.Common) // fill common info - request.Command = V2_COMMAND_CHAIN_REQUEST - - // send our blocks, first 10 blocks directly, then decreasing in powers of 2 - start_point := chain.Load_TOPO_HEIGHT() - for i := int64(0); i < start_point; { - - blid, _ := chain.Load_Block_Topological_order_at_index(start_point - i) - request.Block_list = append(request.Block_list, blid) - request.TopoHeights = append(request.TopoHeights, start_point-i) - rlog.Tracef(3, "Adding block to chain request h %d %s", i, blid) - switch { - case len(request.Block_list) < 10: - i++ - default: - i = i * 2 - } - } - - // add genesis block at the end - request.Block_list = append(request.Block_list, globals.Config.Genesis_Block_Hash) - request.TopoHeights = append(request.TopoHeights, 0) - - // serialize and send - serialized, err := msgpack.Marshal(&request) - if err != nil { - panic(err) - } - - // queue command - command := Queued_Command{Command: V2_COMMAND_CHAIN_RESPONSE} - connection.Objects <- command - - atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) - //connection.Lock() - //connection.Command_queue.PushBack(command) // queue command - connection.Send_Message_prelocked(serialized) - //connection.Unlock() - - rlog.Tracef(2, "chain request sent successfully %s", globals.CTXString(connection.logger)) -} - // peer has requested chain -func (connection *Connection) Handle_ChainRequest(buf []byte) { - var request Chain_Request_Struct - var response Chain_Response_Struct - err := msgpack.Unmarshal(buf, &request) - if err != nil { - rlog.Warnf("Error while decoding incoming chain request err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() - return - } +func (c *Connection) Chain(request Chain_Request_Struct, response *Chain_Response_Struct) error { - // if len(request.Block_list) < 1 { // malformed request ban peer - rlog.Warnf("malformed chain request received, banning peer %+v %s", request, globals.CTXString(connection.logger)) - connection.Exit() - - return + rlog.Warnf("malformed chain request received, banning peer %+v %s", request, globals.CTXString(c.logger)) + c.exit() + return nil } if len(request.Block_list) != len(request.TopoHeights) || len(request.Block_list) > 1024 { rlog.Warnf("Peer chain request has %d block %d topos, therefore invalid", len(request.Block_list), len(request.TopoHeights)) - connection.Exit() - return + c.exit() + return nil } if request.Block_list[len(request.Block_list)-1] != globals.Config.Genesis_Block_Hash { rlog.Warnf("Peer's genesis block is different from our, so disconnect Actual %s Expected %s", request.Block_list[len(request.Block_list)-1], globals.Config.Genesis_Block_Hash) - connection.Exit() - return + c.exit() + return nil } - rlog.Tracef(2, "chain request received %s", globals.CTXString(connection.logger)) - // we must give user our version of the chain start_height := int64(0) start_topoheight := int64(0) for i := 0; i < len(request.Block_list); i++ { // find the common point in our chain ( the block is NOT orphan) - //connection.logger.Infof("Checking block for chain detection %d %s", i, request.Block_list[i]) + //c.logger.Infof("Checking block for chain detection %d %s", i, request.Block_list[i]) if chain.Block_Exists(request.Block_list[i]) && chain.Is_Block_Topological_order(request.Block_list[i]) && request.TopoHeights[i] == chain.Load_Block_Topological_order(request.Block_list[i]) { @@ -133,9 +71,6 @@ func (connection *Connection) Handle_ChainRequest(buf []byte) { // we can serve maximum of 512 BLID = 16K KB const MAX_BLOCKS = 512 - // if everything is OK, we must respond with chain response - //connection.Send_TimedSync(false) // send it as response - for i := start_topoheight; i <= chain.Load_TOPO_HEIGHT() && len(response.Block_list) <= MAX_BLOCKS; i++ { hash, _ := chain.Load_Block_Topological_order_at_index(i) response.Block_list = append(response.Block_list, [32]byte(hash)) @@ -155,15 +90,7 @@ func (connection *Connection) Handle_ChainRequest(buf []byte) { response.Start_height = start_height response.Start_topoheight = start_topoheight fill_common(&response.Common) // fill common info - response.Command = V2_COMMAND_CHAIN_RESPONSE + c.update(&request.Common) // update common information - // serialize and send - serialized, err := msgpack.Marshal(&response) - if err != nil { - panic(err) - } - - // we should add to queue that we are waiting for chain response - rlog.Tracef(2, "chain response sent due to incoming chain request sent len response = %d %s", len(serialized), globals.CTXString(connection.logger)) - connection.Send_Message(serialized) + return nil } diff --git a/p2p/rpc_changeset.go b/p2p/rpc_changeset.go new file mode 100644 index 0000000..ee61eb1 --- /dev/null +++ b/p2p/rpc_changeset.go @@ -0,0 +1,136 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package p2p + +import "github.com/romana/rlog" +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/graviton" + +// notifies inventory +func (c *Connection) ChangeSet(request ChangeList, response *Changes) (err error) { + + if len(request.TopoHeights) < 1 || len(request.TopoHeights) > 50 { // we are expecting 1 block or 1 tx + rlog.Warnf("malformed object request received, banning peer %+v %s", request, c.logid) + c.exit() + return nil + } + + c.update(&request.Common) // update common information + + for _, topo := range request.TopoHeights { + var cbl Complete_Block + + blid, err := chain.Load_Block_Topological_order_at_index(topo) + if err != nil { + return err + } + + bl, _ := chain.Load_BL_FROM_ID(blid) + cbl.Block = bl.Serialize() + for j := range bl.Tx_hashes { + var tx_bytes []byte + if tx_bytes, err = chain.Store.Block_tx_store.ReadTX(bl.Tx_hashes[j]); err != nil { + return err + } + cbl.Txs = append(cbl.Txs, tx_bytes) // append all the txs + + } + cbl.Difficulty = chain.Load_Block_Difficulty(blid).String() + cbl.Cumulative_Difficulty = chain.Load_Block_Cumulative_Difficulty(blid).String() + + // now we must load all the changes the block has done to the state tree + previous_sr, err := chain.Store.Topo_store.Read(topo - 1) + if err != nil { + return err + } + current_sr, err := chain.Store.Topo_store.Read(topo) + if err != nil { + return err + } + + { // do the heavy lifting, merge all changes before this topoheight + var previous_ss, current_ss *graviton.Snapshot + + if previous_ss, err = chain.Store.Balance_store.LoadSnapshot(previous_sr.State_Version); err == nil { + if current_ss, err = chain.Store.Balance_store.LoadSnapshot(current_sr.State_Version); err == nil { + if response.KeyCount == 0 { + var current_balance_tree *graviton.Tree + if current_balance_tree, err = current_ss.GetTree(config.BALANCE_TREE); err == nil { + response.KeyCount = current_balance_tree.KeyCountEstimate() + } + } + var changes Tree_Changes + if changes, err = record_changes(previous_ss, current_ss, config.BALANCE_TREE); err == nil { + cbl.Changes = append(cbl.Changes, changes) + } + + if response.SCKeyCount == 0 { + var current_sc_tree *graviton.Tree + if current_sc_tree, err = current_ss.GetTree(config.SC_META); err == nil { + response.SCKeyCount = current_sc_tree.KeyCountEstimate() + } + } + if changes, err = record_changes(previous_ss, current_ss, config.SC_META); err == nil { + cbl.Changes = append(cbl.Changes, changes) + // now lets build all the SC changes + for k := range cbl.Changes[1].Keys { + var sc_data Tree_Changes + //fmt.Printf("bundling SC changes %x\n", k) + if sc_data, err = record_changes(previous_ss, current_ss, string(k)); err == nil { + cbl.Changes = append(cbl.Changes, sc_data) + } + + } + } + } + + } + + if err != nil { + return err + } else { + + } + response.CBlocks = append(response.CBlocks, cbl) + } + } + + // if everything is OK, we must respond with object response + fill_common(&response.Common) // fill common info + + return nil + +} + +// this will record all the changes +func record_changes(previous_ss, current_ss *graviton.Snapshot, treename string) (changes Tree_Changes, err error) { + var previous_tree, current_tree *graviton.Tree + if previous_tree, err = previous_ss.GetTree(treename); err == nil { + if current_tree, err = current_ss.GetTree(treename); err == nil { + + change_handler := func(k, v []byte) { + changes.Keys = append(changes.Keys, k) + changes.Values = append(changes.Values, v) + } + err = graviton.Diff(previous_tree, current_tree, nil, change_handler, change_handler) + } + } + + changes.TreeName = []byte(treename) + + return +} diff --git a/p2p/rpc_handshake.go b/p2p/rpc_handshake.go new file mode 100644 index 0000000..6667fd3 --- /dev/null +++ b/p2p/rpc_handshake.go @@ -0,0 +1,190 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package p2p + +import "fmt" +import "bytes" +import "math/big" + +import "sync/atomic" +import "time" + +import "github.com/romana/rlog" +import "github.com/paulbellamy/ratecounter" + +import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/globals" + +// verify incoming handshake for number of checks such as mainnet/testnet etc etc +func Verify_Handshake(handshake *Handshake_Struct) bool { + return bytes.Equal(handshake.Network_ID[:], globals.Config.Network_ID[:]) +} + +func (handshake *Handshake_Struct) Fill() { + fill_common(&handshake.Common) // fill common info + + handshake.ProtocolVersion = "1.0.0" + handshake.DaemonVersion = config.Version.String() + handshake.Tag = node_tag + handshake.UTC_Time = int64(time.Now().UTC().Unix()) // send our UTC time + handshake.Local_Port = uint32(P2P_Port) // export requested or default port + handshake.Peer_ID = GetPeerID() // give our randomly generated peer id + handshake.Pruned = chain.LocatePruneTopo() + + // handshake.Flags = // add any flags necessary + + //scan our peer list and send peers which have been recently communicated + handshake.PeerList = get_peer_list() + copy(handshake.Network_ID[:], globals.Config.Network_ID[:]) +} + +// this is used only once +// all clients start with handshake, then other party sends avtive to mark that connection is active +func (connection *Connection) dispatch_test_handshake() { + var request, response Handshake_Struct + request.Fill() + + if err := connection.RConn.Client.Call("Peer.Handshake", request, &response); err != nil { + connection.exit() + return + } + + if !Verify_Handshake(&response) { // if not same network boot off + //fmt.Printf("kill connection network id mismatch peer network id1 %x", response.Network_ID) + connection.exit() + return + } + + connection.CDIFF.Store(new(big.Int).SetUint64(1)) + + connection.request_time.Store(time.Now()) + connection.SpeedIn = ratecounter.NewRateCounter(60 * time.Second) + connection.SpeedOut = ratecounter.NewRateCounter(60 * time.Second) + + connection.update(&response.Common) // update common information + + if !connection.Incoming { // setup success + Peer_SetSuccess(connection.Addr.String()) + } + + if len(response.ProtocolVersion) < 128 { + connection.ProtocolVersion = response.ProtocolVersion + } + + if len(response.DaemonVersion) < 128 { + connection.DaemonVersion = response.DaemonVersion + } + connection.Port = response.Local_Port + connection.Peer_ID = response.Peer_ID + if len(response.Tag) < 128 { + connection.Tag = response.Tag + } + if response.Pruned >= 1 { + connection.Pruned = response.Pruned + } + + // TODO we must also add the peer to our list + // which can be distributed to other peers + if connection.Port != 0 && connection.Port <= 65535 { // peer is saying it has an open port, handshake is success so add peer + + var p Peer + if connection.Addr.IP.To4() != nil { // if ipv4 + p.Address = fmt.Sprintf("%s:%d", connection.Addr.IP.String(), connection.Port) + } else { // if ipv6 + p.Address = fmt.Sprintf("[%s]:%d", connection.Addr.IP.String(), connection.Port) + } + p.ID = connection.Peer_ID + + p.LastConnected = uint64(time.Now().UTC().Unix()) + + // TODO we should add any flags here if necessary, but they are not + // required, since a peer can only be used if connected and if connected + // we already have a truly synced view + for _, k := range response.Flags { + switch k { + //case FLAG_MINER:p.Miner = true + default: + } + } + Peer_Add(&p) + } + + connection.TXpool_cache = map[uint64]uint32{} + + // parse delivered peer list as grey list + rlog.Debugf("Peer provides %d peers", len(response.PeerList)) + for i := range response.PeerList { + if i < 13 { + Peer_Add(&Peer{Address: response.PeerList[i].Addr, LastConnected: uint64(time.Now().UTC().Unix())}) + } + } + + Connection_Add(connection) // add connection to pool + + // mark active + var r Dummy + fill_common(&r.Common) // fill common info + if err := connection.RConn.Client.Call("Peer.Active", r, &r); err != nil { + connection.exit() + return + } + +} + +// mark connection active +func (c *Connection) Active(req Dummy, dummy *Dummy) error { + c.update(&req.Common) // update common information + atomic.StoreUint32(&c.State, ACTIVE) + fill_common(&dummy.Common) // fill common info + return nil +} + +// used to ping pong +func (c *Connection) Ping(req Dummy, resp *Dummy) error { + c.update(&req.Common) // update common information + fill_common(&resp.Common) // fill common info + return nil +} + +// serves handhake requests +func (c *Connection) Handshake(request Handshake_Struct, response *Handshake_Struct) error { + + if request.Peer_ID == GetPeerID() { // check if self connection exit + rlog.Tracef(1, "Same peer ID, probably self connection, disconnecting from this client") + c.exit() + return fmt.Errorf("Same peer ID") + } + + if !Verify_Handshake(&request) { // if not same network boot off + rlog.Tracef(1, "kill connection network id mismatch peer network id0 %x", request.Network_ID) + c.exit() + return fmt.Errorf("NID mismatch") + } + + response.Fill() + + c.update(&request.Common) // update common information + if c.State == ACTIVE { + for i := range request.PeerList { + if i < 13 { + Peer_Add(&Peer{Address: request.PeerList[i].Addr, LastConnected: uint64(time.Now().UTC().Unix())}) + } + } + } + + return nil +} diff --git a/p2p/notification.go b/p2p/rpc_notifications.go similarity index 51% rename from p2p/notification.go rename to p2p/rpc_notifications.go index 73174bd..6baff35 100644 --- a/p2p/notification.go +++ b/p2p/rpc_notifications.go @@ -16,40 +16,90 @@ package p2p -//import "fmt" -//import "net" +import "fmt" import "sync/atomic" -import "time" - import "encoding/binary" - -//import "container/list" - +import "time" import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" -import "github.com/deroproject/derohe/crypto" import "github.com/deroproject/derohe/globals" import "github.com/deroproject/derohe/block" import "github.com/deroproject/derohe/errormsg" import "github.com/deroproject/derohe/transaction" -// Peer has notified us of a new transaction -func (connection *Connection) Handle_Notification_Transaction(buf []byte) { - var request Notify_New_Objects_Struct +// notifies inventory +func (c *Connection) NotifyINV(request ObjectList, response *Dummy) (err error) { + var need ObjectList + var dirty = false - err := msgpack.Unmarshal(buf, &request) - if err != nil { - rlog.Warnf("Error while decoding incoming TX notifcation err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() + c.update(&request.Common) // update common information + + if len(request.Block_list) >= 1 { // handle incoming blocks list + for i := range request.Block_list { // + if !chain.Is_Block_Topological_order(request.Block_list[i]) { // block is not in our chain + if !chain.Block_Exists(request.Block_list[i]) { // check whether the block can be loaded from disk + need.Block_list = append(need.Block_list, request.Block_list[i]) + dirty = true + } + } + } } + if len(request.Tx_list) >= 1 { // handle incoming tx list and see whether it exists in mempoolor regpool + for i := range request.Tx_list { // + if !(chain.Mempool.Mempool_TX_Exist(request.Tx_list[i]) || chain.Regpool.Regpool_TX_Exist(request.Tx_list[i])) { // check if is already in mempool skip it + if _, err = chain.Store.Block_tx_store.ReadTX(request.Tx_list[i]); err != nil { // check whether the tx can be loaded from disk + need.Tx_list = append(need.Tx_list, request.Tx_list[i]) + dirty = true + } + } + } + } + + if dirty { // request inventory only if we want it + var oresponse Objects + fill_common(&need.Common) // fill common info + if err = c.RConn.Client.Call("Peer.GetObject", need, &oresponse); err != nil { + fmt.Printf("Call faileda: %v\n", err) + c.exit() + return + } else { // process the response + if err = c.process_object_response(oresponse); err != nil { + return + } + } + } + + fill_common(&response.Common) // fill common info + + return nil + +} + +// Peer has notified us of a new transaction +func (c *Connection) NotifyTx(request Objects, response *Dummy) error { + var err error var tx transaction.Transaction - err = tx.DeserializeHeader(request.Tx) + + c.update(&request.Common) // update common information + + if len(request.CBlocks) != 0 { + rlog.Warnf("Error while decoding incoming tx notifcation request err %s", globals.CTXString(c.logger)) + c.exit() + return fmt.Errorf("Notify TX cannot notify blocks") + } + + if len(request.Txs) != 1 { + rlog.Warnf("Error while decoding incoming tx notification request err %s ", globals.CTXString(c.logger)) + c.exit() + return fmt.Errorf("Notify TX can only notify 1 tx") + } + + err = tx.DeserializeHeader(request.Txs[0]) if err != nil { // we have a tx which could not be deserialized ban peer - rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() - return + rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, globals.CTXString(c.logger)) + c.exit() + return err } // track transaction propagation @@ -62,47 +112,45 @@ func (connection *Connection) Handle_Notification_Transaction(buf []byte) { } // try adding tx to pool - success_pool := chain.Add_TX_To_Pool(&tx) - - // add tx to cache of the peer who sent us this tx - connection.TXpool_cache_lock.Lock() - if success_pool && globals.Arguments["--lowcpuram"].(bool) == false && connection.TXpool_cache != nil { - + if err = chain.Add_TX_To_Pool(&tx); err == nil { + // add tx to cache of the peer who sent us this tx txhash := tx.GetHash() - connection.TXpool_cache[binary.LittleEndian.Uint64(txhash[:])] = uint32(time.Now().Unix()) - - //logger.Debugf("Adding %s to cache", tx.GetHash()) + c.TXpool_cache_lock.Lock() + c.TXpool_cache[binary.LittleEndian.Uint64(txhash[:])] = uint32(time.Now().Unix()) + c.TXpool_cache_lock.Unlock() } - connection.TXpool_cache_lock.Unlock() + fill_common(&response.Common) // fill common info // broadcasting of tx is controlled by mempool + // broadcast how ??? + + return nil } -// Peer has notified us of a new block -func (connection *Connection) Handle_Notification_Block(buf []byte) { - var request Notify_New_Objects_Struct - - err := msgpack.Unmarshal(buf, &request) - if err != nil { - rlog.Warnf("Error while decoding incoming Block notifcation request err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() +func (c *Connection) NotifyBlock(request Objects, response *Dummy) error { + var err error + if len(request.CBlocks) != 1 { + rlog.Warnf("Error while decoding incoming Block notifcation request err %s %s", err, globals.CTXString(c.logger)) + c.exit() + return fmt.Errorf("Notify Block cannot only notify single block") } + c.update(&request.Common) // update common information var cbl block.Complete_Block // parse incoming block and deserialize it var bl block.Block // lets deserialize block first and see whether it is the requested object cbl.Bl = &bl - err = bl.Deserialize(request.CBlock.Block) + err = bl.Deserialize(request.CBlocks[0].Block) if err != nil { // we have a block which could not be deserialized ban peer - rlog.Warnf("Error Incoming block could not be deserilised err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() - return + rlog.Warnf("Error Incoming block could not be deserilised err %s %s", err, globals.CTXString(c.logger)) + c.exit() + return err } blid := bl.GetHash() - rlog.Infof("Incoming block Notification hash %s %s ", blid, globals.CTXString(connection.logger)) + rlog.Infof("Incoming block Notification hash %s %s ", blid, globals.CTXString(c.logger)) // track block propagation if first_time, ok := block_propagation_map.Load(blid); ok { @@ -115,32 +163,32 @@ func (connection *Connection) Handle_Notification_Block(buf []byte) { // object is already is in our chain, we need not relay it if chain.Is_Block_Topological_order(blid) { - return + return nil } // the block is not in our db, parse entire block, complete the txs and try to add it - if len(bl.Tx_hashes) == len(request.CBlock.Txs) { - connection.logger.Debugf("Received a complete block %s with %d transactions", blid, len(bl.Tx_hashes)) - for j := range request.CBlock.Txs { + if len(bl.Tx_hashes) == len(request.CBlocks[0].Txs) { + c.logger.Debugf("Received a complete block %s with %d transactions", blid, len(bl.Tx_hashes)) + for j := range request.CBlocks[0].Txs { var tx transaction.Transaction - err = tx.DeserializeHeader(request.CBlock.Txs[j]) + err = tx.DeserializeHeader(request.CBlocks[0].Txs[j]) if err != nil { // we have a tx which could not be deserialized ban peer - rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() - return + rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, globals.CTXString(c.logger)) + c.exit() + return err } cbl.Txs = append(cbl.Txs, &tx) } } else { // the block is NOT complete, we consider it as an ultra compact block - connection.logger.Debugf("Received an ultra compact block %s, total %d contains %d skipped %d transactions", blid, len(bl.Tx_hashes), len(request.CBlock.Txs), len(bl.Tx_hashes)-len(request.CBlock.Txs)) - for j := range request.CBlock.Txs { + c.logger.Debugf("Received an ultra compact block %s, total %d contains %d skipped %d transactions", blid, len(bl.Tx_hashes), len(request.CBlocks[0].Txs), len(bl.Tx_hashes)-len(request.CBlocks[0].Txs)) + for j := range request.CBlocks[0].Txs { var tx transaction.Transaction - err = tx.DeserializeHeader(request.CBlock.Txs[j]) + err = tx.DeserializeHeader(request.CBlocks[0].Txs[j]) if err != nil { // we have a tx which could not be deserialized ban peer - rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, globals.CTXString(connection.logger)) - connection.Exit() - return + rlog.Warnf("Error Incoming TX could not be deserialized err %s %s", err, globals.CTXString(c.logger)) + c.exit() + return err } chain.Add_TX_To_Pool(&tx) // add tx to pool } @@ -163,50 +211,54 @@ func (connection *Connection) Handle_Notification_Block(buf []byte) { var tx_bytes []byte if tx_bytes, err = chain.Store.Block_tx_store.ReadTX(bl.Tx_hashes[i]); err != nil { // the tx mentioned in ultra compact block could not be found, request a full block - connection.Send_ObjectRequest([]crypto.Hash{blid}, []crypto.Hash{}) + //connection.Send_ObjectRequest([]crypto.Hash{blid}, []crypto.Hash{}) logger.Debugf("Ultra compact block %s missing TX %s, requesting full block", blid, bl.Tx_hashes[i]) - return + return err } tx = &transaction.Transaction{} if err = tx.DeserializeHeader(tx_bytes); err != nil { // the tx mentioned in ultra compact block could not be found, request a full block - connection.Send_ObjectRequest([]crypto.Hash{blid}, []crypto.Hash{}) + //connection.Send_ObjectRequest([]crypto.Hash{blid}, []crypto.Hash{}) logger.Debugf("Ultra compact block %s missing TX %s, requesting full block", blid, bl.Tx_hashes[i]) - return + return err } cbl.Txs = append(cbl.Txs, tx) // tx is from disk } } -// make sure connection does not timeout and be killed while processing huge blocks - processing_complete := make(chan bool) - go func() { - ticker := time.NewTicker(500 * time.Millisecond) - defer ticker.Stop() - for { - select { - case <- processing_complete: return // complete the loop - case <-ticker.C:// give the chain some more time to respond - atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) - } - } - }() + // make sure connection does not timeout and be killed while processing huge blocks + processing_complete := make(chan bool) + go func() { + ticker := time.NewTicker(500 * time.Millisecond) + defer ticker.Stop() + for { + select { + case <-processing_complete: + return // complete the loop + case <-ticker.C: // give the chain some more time to respond + atomic.StoreInt64(&c.LastObjectRequestTime, time.Now().Unix()) + } + } + }() - defer func() { - processing_complete <- true - }() + defer func() { + processing_complete <- true + }() // check if we can add ourselves to chain if err, ok := chain.Add_Complete_Block(&cbl); ok { // if block addition was successfil // notify all peers - Broadcast_Block(&cbl, connection.Peer_ID) // do not send back to the original peer - + Broadcast_Block(&cbl, c.Peer_ID) // do not send back to the original peer } else { // ban the peer for sometime if err == errormsg.ErrInvalidPoW { - connection.logger.Warnf("This peer should be banned and terminated") - connection.Exit() + c.logger.Warnf("This peer should be banned and terminated") + c.exit() + return err } } + fill_common(&response.Common) // fill common info + + return nil } diff --git a/p2p/object_request.go b/p2p/rpc_object_request.go similarity index 50% rename from p2p/object_request.go rename to p2p/rpc_object_request.go index a288d47..00b5414 100644 --- a/p2p/object_request.go +++ b/p2p/rpc_object_request.go @@ -16,90 +16,29 @@ package p2p -//import "fmt" -//import "net" -import "sync/atomic" -import "time" - -//import "container/list" - import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" - -//import "github.com/deroproject/derosuite/crypto" -//import "github.com/deroproject/derosuite/globals" - -import "github.com/deroproject/derohe/crypto" - -//import "github.com/deroproject/derosuite/globals" - -//import "github.com/deroproject/derosuite/blockchain" - -// we are sending object request -// right now we only send block ids -func (connection *Connection) Send_ObjectRequest(blids []crypto.Hash, txids []crypto.Hash) { - - var request Object_Request_Struct - fill_common(&request.Common) // fill common info - request.Command = V2_COMMAND_OBJECTS_REQUEST - - for i := range blids { - request.Block_list = append(request.Block_list, blids[i]) - } - - for i := range txids { - request.Tx_list = append(request.Tx_list, txids[i]) - } - - if len(blids) > 0 || len(txids) > 0 { - serialized, err := msgpack.Marshal(&request) // serialize and send - if err != nil { - panic(err) - } - - // use first object - - command := Queued_Command{Command: V2_COMMAND_OBJECTS_RESPONSE, BLID: blids, TXID: txids} - - connection.Objects <- command - atomic.StoreInt64(&connection.LastObjectRequestTime, time.Now().Unix()) - - // we should add to queue that we are waiting for object response - //command := Queued_Command{Command: V2_COMMAND_OBJECTS_RESPONSE, BLID: blids, TXID: txids, Started: time.Now()} - - connection.Lock() - //connection.Command_queue.PushBack(command) // queue command - connection.Send_Message_prelocked(serialized) - connection.Unlock() - rlog.Tracef(3, "object request sent contains %d blids %d txids %s ", len(blids), connection.logid) - } -} // peer has requested some objects, we must respond // if certain object is not in our list we respond with empty buffer for that slot -func (connection *Connection) Handle_ObjectRequest(buf []byte) { - var request Object_Request_Struct - var response Object_Response_struct - - err := msgpack.Unmarshal(buf, &request) - if err != nil { - rlog.Warnf("Error while decoding incoming object request err %s %s", err, connection.logid) - connection.Exit() - } +// an object is either a block or a tx +func (connection *Connection) GetObject(request ObjectList, response *Objects) error { + var err error if len(request.Block_list) < 1 && len(request.Tx_list) < 1 { // we are expecting 1 block or 1 tx - rlog.Warnf("malformed object request received, banning peer %+v %s", request, connection.logid) - connection.Exit() + rlog.Warnf("malformed object request received, banning peer %+v %s", request) + connection.exit() + return nil } + connection.update(&request.Common) // update common information - for i := range request.Block_list { // find the common point in our chain + for i := range request.Block_list { // find the block var cbl Complete_Block bl, _ := chain.Load_BL_FROM_ID(request.Block_list[i]) cbl.Block = bl.Serialize() for j := range bl.Tx_hashes { var tx_bytes []byte if tx_bytes, err = chain.Store.Block_tx_store.ReadTX(bl.Tx_hashes[j]); err != nil { - return + return err } cbl.Txs = append(cbl.Txs, tx_bytes) // append all the txs @@ -114,20 +53,14 @@ func (connection *Connection) Handle_ObjectRequest(buf []byte) { } else if tx := chain.Regpool.Regpool_Get_TX(request.Tx_list[i]); tx != nil { // if tx can be satisfied from regpool, so be it tx_bytes = tx.Serialize() } else if tx_bytes, err = chain.Store.Block_tx_store.ReadTX(request.Tx_list[i]); err != nil { - return + return err } response.Txs = append(response.Txs, tx_bytes) // append all the txs } // if everything is OK, we must respond with object response fill_common(&response.Common) // fill common info - response.Command = V2_COMMAND_OBJECTS_RESPONSE - serialized, err := msgpack.Marshal(&response) // serialize and send - if err != nil { - panic(err) - } - - rlog.Tracef(3, "OBJECT RESPONSE SENT sent size %d %s", len(serialized), connection.logid) - connection.Send_Message(serialized) + //rlog.Tracef(3, "OBJECT RESPONSE SENT sent size %d %s", len(serialized), connection.logid) + return nil } diff --git a/p2p/rpc_treesection.go b/p2p/rpc_treesection.go new file mode 100644 index 0000000..e1e7f29 --- /dev/null +++ b/p2p/rpc_treesection.go @@ -0,0 +1,68 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package p2p + +import "github.com/romana/rlog" +import "github.com/deroproject/graviton" + +// get parts of the specified balance tree chunk by chunk +func (c *Connection) TreeSection(request Request_Tree_Section_Struct, response *Response_Tree_Section_Struct) (err error) { + + if request.Topo < 2 || request.SectionLength > 256 || len(request.Section) < int(request.SectionLength/8) { // we are expecting 1 block or 1 tx + rlog.Warnf("malformed object request received, banning peer %+v %s", request, c.logid) + c.exit() + } + + c.update(&request.Common) // update common information + + topo_sr, err := chain.Store.Topo_store.Read(request.Topo) + if err != nil { + return + } + + { // do the heavy lifting, merge all changes before this topoheight + var topo_ss *graviton.Snapshot + var topo_balance_tree *graviton.Tree + if topo_ss, err = chain.Store.Balance_store.LoadSnapshot(topo_sr.State_Version); err == nil { + if topo_balance_tree, err = topo_ss.GetTree(string(request.TreeName)); err == nil { + cursor := topo_balance_tree.Cursor() + for k, v, err := cursor.SpecialFirst(request.Section, uint(request.SectionLength)); err == nil; k, v, err = cursor.Next() { + response.Keys = append(response.Keys, k) + response.Values = append(response.Values, v) + + if len(response.Keys) > 10000 { + break + } + + } + err = nil + + } + + } + + if err != nil { + return + } + + } + + // if everything is OK, we must respond with object response + fill_common(&response.Common) // fill common info + return nil + +} diff --git a/p2p/timedsync.go b/p2p/timedsync.go deleted file mode 100644 index 98132db..0000000 --- a/p2p/timedsync.go +++ /dev/null @@ -1,72 +0,0 @@ -// Copyright 2017-2021 DERO Project. All rights reserved. -// Use of this source code in any form is governed by RESEARCH license. -// license can be found in the LICENSE file. -// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 -// -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL -// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, -// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF -// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -package p2p - -//import "fmt" -//import "net" -import "sync/atomic" -import "time" - -//import "container/list" -import "github.com/romana/rlog" -import "github.com/vmihailenco/msgpack" - -//import "github.com/deroproject/derosuite/crypto" -//import "github.com/deroproject/derosuite/globals" - -// reads our data, length prefix blocks -func (connection *Connection) Send_TimedSync(request bool) { - - var sync Sync_Struct - - fill_common(&sync.Common) // fill common info - sync.Command = V2_COMMAND_SYNC - sync.Request = request - - serialized, err := msgpack.Marshal(&sync) // serialize and send - if err != nil { - panic(err) - } - if request { // queue command that we are expecting a response - //connection.Lock() - connection.request_time.Store(time.Now()) - //connection.Unlock() - } - //rlog.Tracef(2, "Timed sync sent successfully %s", connection.logid) - connection.Send_Message(serialized) - -} - -// handles incoming timed syncs -func (connection *Connection) Handle_TimedSync(buf []byte) { - var sync Sync_Struct - err := msgpack.Unmarshal(buf, &sync) - if err != nil { - rlog.Warnf("Error while decoding incoming chain request err %s %s", err, connection.logid) - connection.Exit() - return - } - //rlog.Tracef(2, "Timed sync received %s", connection.logid) - if sync.Request { - connection.Send_TimedSync(false) // send it as response - } else { // this is a response for our request track latency - //connection.Lock() - atomic.StoreInt64(&connection.Latency, int64(time.Now().Sub(connection.request_time.Load().(time.Time))/2)) // divide by 2 is for round-trip - //connection.Unlock() - - } -} diff --git a/p2p/wire_structs.go b/p2p/wire_structs.go index d9a45cf..0258a49 100644 --- a/p2p/wire_structs.go +++ b/p2p/wire_structs.go @@ -16,122 +16,126 @@ package p2p -// This file defines the structure for the protocol which is a msgp encoded ( which is standard) -// msgp would cause an easy rewrite of p2p layer even in c, ruby or rust etc as future may demand -// the protocol is length prefixed msgp payload -// though we can use http2 stream features, they may become compilcated as the project evolves -// the prefix length is 4 bytes, little endian encoded ( so a frame can be 4GB in size) -// this is Work-In-Progress -// the reason for writing it from scratch is the mess of boost serialisation +// This file defines the structure for the protocol which is CBOR ( which is standard) stream multiplexed using yamux +// stream multiplexing allows us have bidirection RPC using net/rpc // the p2p package is currently the most complex within the entire project -// the protocol is partly syncronous, partly asyncronous , except for first handshake, so the node remain undetectable to external network scans, the detection cost is atleast send a handshake packet*/ - -// these are the commands required to make it completely operational - -const V2_COMMAND_NULL = 0 // default value is zero and is a null command -//const V2_COMMAND_NULL = 0 -//first 40 are reserved for future use -const V2_COMMAND_HANDSHAKE = 41 // commands are syncronous and must be responded within 10 secs -const V2_COMMAND_SYNC = 42 -const V2_COMMAND_CHAIN_REQUEST = 43 -const V2_COMMAND_CHAIN_RESPONSE = 44 -const V2_COMMAND_OBJECTS_REQUEST = 45 -const V2_COMMAND_OBJECTS_RESPONSE = 46 - -const V2_NOTIFY_NEW_BLOCK = 0xff // Notifications are asyncronous all notifications come here, such as new block, new txs -const V2_NOTIFY_NEW_TX = 0xfe // notify tx using this -const V2_NOTIFY_INVENTORY = 0xfd // notify inventory that we have a new tx, or block -// this has the same structure V2_COMMAND_OBJECTS_REQUEST +// the protocol is partly syncronous, partly asyncronous // used to parse incoming packet for for command , so as a repective command command could be triggered type Common_Struct struct { - Height int64 `msgpack:"HEIGHT"` - TopoHeight int64 `msgpack:"THEIGHT"` - StableHeight int64 `msgpack:"SHEIGHT"` - Cumulative_Difficulty string `msgpack:"CDIFF"` - StateHash [32]byte `msgpack:"STATE"` - // Top_ID [32]byte `msgpack:"TOP"` // 32 bytes of Top block - Top_Version uint64 `msgpack:"HF"` // this basically represents the hard fork version + Height int64 `cbor:"HEIGHT"` + TopoHeight int64 `cbor:"THEIGHT"` + StableHeight int64 `cbor:"SHEIGHT"` + Cumulative_Difficulty string `cbor:"CDIFF"` + StateHash [32]byte `cbor:"STATE"` + // Top_ID [32]byte `cbor:"TOP"` // 32 bytes of Top block + Top_Version uint64 `cbor:"HF"` // this basically represents the hard fork version } -const FLAG_LOWCPURAM string = "LOWCPURAM" +type Dummy struct { + Common Common_Struct `cbor:"COMMON"` // add all fields of Common +} // at start, client sends handshake and server will respond to handshake type Handshake_Struct struct { - Command uint64 `msgpack:"COMMAND"` - Common Common_Struct `msgpack:"COMMON"` // add all fields of Common - ProtocolVersion string `msgpack:"PVERSION"` // version is a sematic version string semver - Tag string `msgpack:"TAG"` // user specific tag - DaemonVersion string `msgpack:"DVERSION"` - UTC_Time int64 `msgpack:"UTC"` - Local_Port uint32 `msgpack:"LP"` - Peer_ID uint64 `msgpack:"PID"` - Pruned int64 `msgpack:"PRUNED"` - Network_ID [16]byte `msgpack:"NID"` // 16 bytes - Flags []string `msgpack:"FLAGS"` - PeerList []Peer_Info `msgpack:"PLIST"` - Extension_List []string `msgpack:"EXT"` - Request bool `msgpack:"REQUEST"` //whether this is a request + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + ProtocolVersion string `cbor:"PVERSION"` // version is a sematic version string semver + Tag string `cbor:"TAG"` // user specific tag + DaemonVersion string `cbor:"DVERSION"` + UTC_Time int64 `cbor:"UTC"` + Local_Port uint32 `cbor:"LP"` + Peer_ID uint64 `cbor:"PID"` + Pruned int64 `cbor:"PRUNED"` + Network_ID [16]byte `cbor:"NID"` // 16 bytes + Flags []string `cbor:"FLAGS"` + PeerList []Peer_Info `cbor:"PLIST"` + Extension_List []string `cbor:"EXT"` + Request bool `cbor:"REQUEST"` //whether this is a request } type Peer_Info struct { - Addr string `msgpack:"ADDR"` // ip:port pair - Miner bool `msgpack:"MINER"` - //ID uint64 `msgpack:"I"` - //LastSeen uint64 `msgpack:"LS"` + Addr string `cbor:"ADDR"` // ip:port pair + Miner bool `cbor:"MINER"` + //ID uint64 `cbor:"I"` + //LastSeen uint64 `cbor:"LS"` } type Sync_Struct struct { // sync packets are sent every 2 seconds - Command uint64 `msgpack:"COMMAND"` - Common Common_Struct `msgpack:"COMMON"` // add all fields of Common - PeerList []Peer_Info `msgpack:"PLIST"` // update peer list - Request bool `msgpack:"REQUEST"` //whether this is a request + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + PeerList []Peer_Info `cbor:"PLIST"` // update peer list + Request bool `cbor:"REQUEST"` //whether this is a request } type Chain_Request_Struct struct { // our version of chain - Command uint64 `msgpack:"COMMAND"` - Common Common_Struct `msgpack:"COMMON"` // add all fields of Common - Block_list [][32]byte `msgpack:"BLIST"` // block list - TopoHeights []int64 `msgpack:"TOPO"` // topo heights of added blocks + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + Block_list [][32]byte `cbor:"BLIST"` // block list + TopoHeights []int64 `cbor:"TOPO"` // topo heights of added blocks } type Chain_Response_Struct struct { // peers gives us point where to get the chain - Command uint64 `msgpack:"COMMAND"` - Common Common_Struct `msgpack:"COMMON"` // add all fields of Common - Start_height int64 `msgpack:"SH"` - Start_topoheight int64 `msgpack:"STH"` - Block_list [][32]byte `msgpack:"BLIST"` - TopBlocks [][32]byte `msgpack:"TOPBLOCKS"` // top blocks used for faster syncronisation of alt-tips + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + Start_height int64 `cbor:"SH"` + Start_topoheight int64 `cbor:"STH"` + Block_list [][32]byte `cbor:"BLIST"` + TopBlocks [][32]byte `cbor:"TOPBLOCKS"` // top blocks used for faster syncronisation of alt-tips // this contains all blocks hashes for the last 10 heights, heightwise ordered - } -// also used by V2_NOTIFY_INVENTORY -type Object_Request_Struct struct { - Command uint64 `msgpack:"COMMAND"` - Common Common_Struct `msgpack:"COMMON"` // add all fields of Common - Block_list [][32]byte `msgpack:"BLIST"` - Tx_list [][32]byte `msgpack:"TXLIST"` +type ObjectList struct { + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + Block_list [][32]byte `cbor:"BLIST"` + Tx_list [][32]byte `cbor:"TXLIST"` } -type Object_Response_struct struct { - Command uint64 `msgpack:"COMMAND"` - Common Common_Struct `msgpack:"COMMON"` // add all fields of Common - CBlocks []Complete_Block `msgpack:"CBLOCKS"` - Txs [][]byte `msgpack:"TXS"` +type Objects struct { + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + CBlocks []Complete_Block `cbor:"CBLOCKS"` + Txs [][]byte `cbor:"TXS"` +} + +// used to request what all changes are done by the block to the chain +type ChangeList struct { + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + TopoHeights []int64 `cbor:"TOPO"` +} + +type Changes struct { + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + CBlocks []Complete_Block `cbor:"CBLOCKS"` + KeyCount int64 `cbor:"KEYCOUNT"` + SCKeyCount int64 `cbor:"SCKEYCOUNT"` +} + +type Request_Tree_Section_Struct struct { + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + Topo int64 `cbor:"TOPO"` // request section from the balance tree of this topo + TreeName []byte `cbor:"TREENAME,omitempty"` // changes to state tree + Section []byte `cbor:"SECTION"` // section path from which data must be received + SectionLength uint64 `cbor:"SECTIONL"` // section length in bits +} + +type Response_Tree_Section_Struct struct { + Common Common_Struct `cbor:"COMMON"` // add all fields of Common + Topo int64 `cbor:"TOPO"` // request section from the balance tree of this topo + TreeName []byte `cbor:"TREENAME,omitempty"` // changes to state tree + Section []byte `cbor:"SECTION"` + SectionLength uint64 `cbor:"SECTIONL"` // section length in bits + StateHash [32]byte `cbor:"STATE"` + Keys [][]byte `cbor:"KEYS,omitempty"` // changes to state tree + Values [][]byte `cbor:"VALUES,omitempty"` // changes to state tree +} + +type Tree_Changes struct { + TreeName []byte `cbor:"TREENAME,omitempty"` // changes to state tree + Keys [][]byte `cbor:"KEYS,omitempty"` // changes to state tree + Values [][]byte `cbor:"VALUES,omitempty"` // changes to state tree } type Complete_Block struct { - Block []byte `msgpack:"BLOCK"` - Txs [][]byte `msgpack:"TXS"` + Block []byte `cbor:"BLOCK"` + Txs [][]byte `cbor:"TXS"` + Difficulty string `cbor:"DIFF,omitempty"` // Diff + Cumulative_Difficulty string `cbor:"CDIFF,omitempty"` // CDiff + Changes []Tree_Changes `cbor:"CHANGES,omitempty"` // changes to state tree } - -type Notify_New_Objects_Struct struct { - Command uint64 `msgpack:"COMMAND"` - Common Common_Struct `msgpack:"COMMON"` // add all fields of Common - CBlock Complete_Block `msgpack:"CBLOCK"` - Tx []byte `msgpack:"TX"` -} - -// each packet has to be parsed twice once for extracting command and then a full parsing based on Command diff --git a/proof/proof.go b/proof/proof.go index 4e9ed1c..f8a141c 100644 --- a/proof/proof.go +++ b/proof/proof.go @@ -19,20 +19,19 @@ package proof import "fmt" import "math/big" import "encoding/hex" -import "encoding/binary" -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/crypto/bn256" -import "github.com/deroproject/derohe/address" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/rpc" +import "github.com/deroproject/derohe/cryptography/bn256" import "github.com/deroproject/derohe/transaction" //import "github.com/deroproject/derosuite/walletapi" // to decode encrypted payment ID // this function will prove detect and decode output amount for the tx -func Prove(proof string, input_tx string, mainnet bool) (receivers []string, amounts []uint64, payids [][]byte, err error) { +func Prove(proof string, input_tx string, ring [][][]byte, mainnet bool) (receivers []string, amounts []uint64, payload_raw [][]byte, payload_decoded []string, err error) { var tx transaction.Transaction - addr, err := address.NewAddress(proof) + addr, err := rpc.NewAddress(proof) if err != nil { return } @@ -42,8 +41,14 @@ func Prove(proof string, input_tx string, mainnet bool) (receivers []string, amo return } - if len(addr.PaymentID) != 8 { - err = fmt.Errorf("Invalid proof paymentid") + args := addr.Arguments + + amount := uint64(0) + + if args.Has(rpc.RPC_VALUE_TRANSFER, rpc.DataUint64) { // this service is expecting value to be specfic + amount = args.Value(rpc.RPC_VALUE_TRANSFER, rpc.DataUint64).(uint64) + } else { + err = fmt.Errorf("Invalid proof.") return } @@ -57,28 +62,52 @@ func Prove(proof string, input_tx string, mainnet bool) (receivers []string, amo return } + // now lets decode the ring + + for t := range ring { + for i := range ring[t] { + point_compressed := ring[t][i][:] + + var p bn256.G1 + if err = p.DecodeCompressed(point_compressed[:]); err != nil { + err = fmt.Errorf("Invalid Ring member.") + return + } + + tx.Payloads[t].Statement.Publickeylist = append(tx.Payloads[t].Statement.Publickeylist, &p) + } + } + // okay all inputs have been parsed - - amount := binary.LittleEndian.Uint64(addr.PaymentID) - var x bn256.G1 x.ScalarMult(crypto.G, new(big.Int).SetInt64(int64(amount))) x.Add(new(bn256.G1).Set(&x), addr.PublicKey.G1()) - for k := range tx.Statement.C { - if x.String() == tx.Statement.C[k].String() { + for t := range tx.Payloads { + for k := range tx.Payloads[t].Statement.C { - astring := address.NewAddressFromKeys((*crypto.Point)(tx.Statement.Publickeylist[k])) - astring.Mainnet = mainnet + if x.String() == tx.Payloads[t].Statement.C[k].String() { - receivers = append(receivers, astring.String()) - amounts = append(amounts, amount) + astring := rpc.NewAddressFromKeys((*crypto.Point)(tx.Payloads[t].Statement.Publickeylist[k])) + astring.Mainnet = mainnet - //decode payment id - output := crypto.EncryptDecryptPaymentID(addr.PublicKey.G1(), tx.PaymentID[:]) - payids = append(payids, output) - return + receivers = append(receivers, astring.String()) + amounts = append(amounts, amount) + crypto.EncryptDecryptUserData(addr.PublicKey.G1(), tx.Payloads[t].RPCPayload) + // skip first byte as it is not guaranteed, even rest of the bytes are not + + payload_raw = append(payload_raw, tx.Payloads[t].RPCPayload[1:]) + var args rpc.Arguments + if err := args.UnmarshalBinary(tx.Payloads[t].RPCPayload[1:]); err == nil { + payload_decoded = append(payload_decoded, fmt.Sprintf("%s", args)) + } else { + payload_decoded = append(payload_decoded, err.Error()) + } + + return + + } } } diff --git a/rpc/LICENSE b/rpc/LICENSE new file mode 100644 index 0000000..26fca3f --- /dev/null +++ b/rpc/LICENSE @@ -0,0 +1,90 @@ +RESEARCH LICENSE + + +Version 1.1.2 + +I. DEFINITIONS. + +"Licensee " means You and any other party that has entered into and has in effect a version of this License. + +“Licensor” means DERO PROJECT(GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8) and its successors and assignees. + +"Modifications" means any (a) change or addition to the Technology or (b) new source or object code implementing any portion of the Technology. + +"Research Use" means research, evaluation, or development for the purpose of advancing knowledge, teaching, learning, or customizing the Technology for personal use. Research Use expressly excludes use or distribution for direct or indirect commercial (including strategic) gain or advantage. + +"Technology" means the source code, object code and specifications of the technology made available by Licensor pursuant to this License. + +"Technology Site" means the website designated by Licensor for accessing the Technology. + +"You" means the individual executing this License or the legal entity or entities represented by the individual executing this License. + +II. PURPOSE. + +Licensor is licensing the Technology under this Research License (the "License") to promote research, education, innovation, and development using the Technology. + +COMMERCIAL USE AND DISTRIBUTION OF TECHNOLOGY AND MODIFICATIONS IS PERMITTED ONLY UNDER AN APPROPRIATE COMMERCIAL USE LICENSE AVAILABLE FROM LICENSOR AT . + +III. RESEARCH USE RIGHTS. + +A. Subject to the conditions contained herein, Licensor grants to You a non-exclusive, non-transferable, worldwide, and royalty-free license to do the following for Your Research Use only: + +1. reproduce, create Modifications of, and use the Technology alone, or with Modifications; +2. share source code of the Technology alone, or with Modifications, with other Licensees; + +3. distribute object code of the Technology, alone, or with Modifications, to any third parties for Research Use only, under a license of Your choice that is consistent with this License; and + +4. publish papers and books discussing the Technology which may include relevant excerpts that do not in the aggregate constitute a significant portion of the Technology. + +B. Residual Rights. You may use any information in intangible form that you remember after accessing the Technology, except when such use violates Licensor's copyrights or patent rights. + +C. No Implied Licenses. Other than the rights granted herein, Licensor retains all rights, title, and interest in Technology , and You retain all rights, title, and interest in Your Modifications and associated specifications, subject to the terms of this License. + +D. Open Source Licenses. Portions of the Technology may be provided with notices and open source licenses from open source communities and third parties that govern the use of those portions, and any licenses granted hereunder do not alter any rights and obligations you may have under such open source licenses, however, the disclaimer of warranty and limitation of liability provisions in this License will apply to all Technology in this distribution. + +IV. INTELLECTUAL PROPERTY REQUIREMENTS + +As a condition to Your License, You agree to comply with the following restrictions and responsibilities: + +A. License and Copyright Notices. You must include a copy of this License in a Readme file for any Technology or Modifications you distribute. You must also include the following statement, "Use and distribution of this technology is subject to the Java Research License included herein", (a) once prominently in the source code tree and/or specifications for Your source code distributions, and (b) once in the same file as Your copyright or proprietary notices for Your binary code distributions. You must cause any files containing Your Modification to carry prominent notice stating that You changed the files. You must not remove or alter any copyright or other proprietary notices in the Technology. + +B. Licensee Exchanges. Any Technology and Modifications You receive from any Licensee are governed by this License. + +V. GENERAL TERMS. + +A. Disclaimer Of Warranties. + +TECHNOLOGY IS PROVIDED "AS IS", WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT ANY SUCH TECHNOLOGY IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING OF THIRD PARTY RIGHTS. YOU AGREE THAT YOU BEAR THE ENTIRE RISK IN CONNECTION WITH YOUR USE AND DISTRIBUTION OF ANY AND ALL TECHNOLOGY UNDER THIS LICENSE. + +B. Infringement; Limitation Of Liability. + +1. If any portion of, or functionality implemented by, the Technology becomes the subject of a claim or threatened claim of infringement ("Affected Materials"), Licensor may, in its unrestricted discretion, suspend Your rights to use and distribute the Affected Materials under this License. Such suspension of rights will be effective immediately upon Licensor's posting of notice of suspension on the Technology Site. + +2. IN NO EVENT WILL LICENSOR BE LIABLE FOR ANY DIRECT, INDIRECT, PUNITIVE, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES IN CONNECTION WITH OR ARISING OUT OF THIS LICENSE (INCLUDING, WITHOUT LIMITATION, LOSS OF PROFITS, USE, DATA, OR ECONOMIC ADVANTAGE OF ANY SORT), HOWEVER IT ARISES AND ON ANY THEORY OF LIABILITY (including negligence), WHETHER OR NOT LICENSOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. LIABILITY UNDER THIS SECTION V.B.2 SHALL BE SO LIMITED AND EXCLUDED, NOTWITHSTANDING FAILURE OF THE ESSENTIAL PURPOSE OF ANY REMEDY. + +C. Termination. + +1. You may terminate this License at any time by notifying Licensor in writing. + +2. All Your rights will terminate under this License if You fail to comply with any of its material terms or conditions and do not cure such failure within thirty (30) days after becoming aware of such noncompliance. + +3. Upon termination, You must discontinue all uses and distribution of the Technology , and all provisions of this Section V shall survive termination. + +D. Miscellaneous. + +1. Trademark. You agree to comply with Licensor's Trademark & Logo Usage Requirements, if any and as modified from time to time, available at the Technology Site. Except as expressly provided in this License, You are granted no rights in or to any Licensor's trademarks now or hereafter used or licensed by Licensor. + +2. Integration. This License represents the complete agreement of the parties concerning the subject matter hereof. + +3. Severability. If any provision of this License is held unenforceable, such provision shall be reformed to the extent necessary to make it enforceable unless to do so would defeat the intent of the parties, in which case, this License shall terminate. + +4. Governing Law. This License is governed by the laws of the United States and the State of California, as applied to contracts entered into and performed in California between California residents. In no event shall this License be construed against the drafter. + +5. Export Control. You agree to comply with the U.S. export controlsand trade laws of other countries that apply to Technology and Modifications. + +READ ALL THE TERMS OF THIS LICENSE CAREFULLY BEFORE ACCEPTING. + +BY CLICKING ON THE YES BUTTON BELOW OR USING THE TECHNOLOGY, YOU ARE ACCEPTING AND AGREEING TO ABIDE BY THE TERMS AND CONDITIONS OF THIS LICENSE. YOU MUST BE AT LEAST 18 YEARS OF AGE AND OTHERWISE COMPETENT TO ENTER INTO CONTRACTS. + +IF YOU DO NOT MEET THESE CRITERIA, OR YOU DO NOT AGREE TO ANY OF THE TERMS OF THIS LICENSE, DO NOT USE THIS SOFTWARE IN ANY FORM. + diff --git a/rpc/address.go b/rpc/address.go new file mode 100644 index 0000000..57ed1d9 --- /dev/null +++ b/rpc/address.go @@ -0,0 +1,202 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package rpc + +import "fmt" + +//import "github.com/deroproject/derohe/config" +import "github.com/deroproject/derohe/cryptography/crypto" + +// older dero address https://cryptonote.org/cns/cns007.txt to understand address more +// current dero versions use https://github.com/bitcoin/bips/blob/master/bip-0173.mediawiki + +// there are 3 hrps for mainnet DERO, DEROI,DEROPROOF +// these are 3 hrps for testnet DETO, DETOI,DEROPROOF +// so a total of 5 hrps +// 1 byte version is support capable to represent 255 versions, currently we will be using only version 1 +// point is 33 bytes +// payment id if present is 8 bytes + +type Address struct { + Network uint64 + Mainnet bool + Proof bool + PublicKey *crypto.Point //33 byte compressed point + Arguments Arguments // all data related to integrated address +} + +// Encode encodes hrp(human-readable part) , version(int) and data(bytes array), returns Address / or error +func (a Address) MarshalText() ([]byte, error) { + hrp := "dero" + if !a.Mainnet { + hrp = "deto" + } + + if len(a.Arguments) >= 1 { + hrp += "i" + } + + if a.Proof { + hrp = "deroproof" + } + + // first we are appending version byte + data_bytes := append([]byte{1}, a.PublicKey.EncodeCompressed()...) + + if len(a.Arguments) >= 1 { + if b, err := a.Arguments.MarshalBinary(); err != nil { + return []byte{}, err + } else { + data_bytes = append(data_bytes, b...) + } + } + var data_ints []int + for i := range data_bytes { + data_ints = append(data_ints, int(data_bytes[i])) + } + + data, err := convertbits(data_ints, 8, 5, true) + if err != nil { + return []byte{}, err + } + ret, err := Encode(hrp, data) + if err != nil { + return []byte{}, err + } + return []byte(ret), nil +} + +// stringifier +func (a Address) String() string { + result, _ := a.MarshalText() + return string(result) +} + +// base address if its integrated address +func (a Address) BaseAddress() Address { + z := a.Clone() + z.Arguments = Arguments{} + return z +} + +func (a Address) Clone() (z Address) { + z = Address{Mainnet: a.Mainnet, Proof: a.Proof, Network: a.Network, PublicKey: new(crypto.Point).Set(a.PublicKey)} + z.Arguments = append(z.Arguments, a.Arguments...) + return z +} + +func (a Address) Compressed() []byte { + return a.PublicKey.EncodeCompressed() +} + +// tells whether address is mainnet address +func (a *Address) IsMainnet() bool { + return a.Mainnet +} + +// tells whether address is mainnet address +func (a *Address) IsIntegratedAddress() bool { + return len(a.Arguments) >= 1 +} + +// tells whether address belongs to DERO Network +func (a *Address) IsDERONetwork() bool { + return true +} + +func (result *Address) UnmarshalText(text []byte) error { + dechrp, data, err := Decode(string(text)) + if err != nil { + return err + } + result.Network = 0 + result.Mainnet = false + result.Proof = false + result.PublicKey = new(crypto.Point) + result.Arguments = result.Arguments[:0] + + switch dechrp { + case "dero", "deroi", "deto", "detoi", "deroproof": + default: + return fmt.Errorf("invalid human-readable part : %s != %s", "", dechrp) + } + if len(data) < 1 { + return fmt.Errorf("invalid decode version: %d", len(data)) + } + + res, err := convertbits(data, 5, 8, false) + if err != nil { + return err + } + + if res[0] != 1 { + return fmt.Errorf("invalid address version : %d", res[0]) + } + res = res[1:] + + var resbytes []byte + for _, b := range res { + resbytes = append(resbytes, byte(b)) + } + + if len(resbytes) < 33 { + return fmt.Errorf("invalid address length as per spec : %d", len(res)) + } + + if err = result.PublicKey.DecodeCompressed(resbytes[0:33]); err != nil { + return err + } + + result.Mainnet = true + if dechrp == "deto" || dechrp == "detoi" { + result.Mainnet = false + } + if dechrp == "deroproof" { + result.Proof = true + } + + switch { + case len(res) == 33 && (dechrp == "dero" || dechrp == "deto"): + case (dechrp == "deroi" || dechrp == "detoi" || dechrp == "deroproof"): // address contains service request + if err = result.Arguments.UnmarshalBinary(resbytes[33:]); err != nil { + return err + } + default: + return fmt.Errorf("invalid address length as per spec : %d", len(res)) + } + + return nil + +} + +// NewAddress decodes hrp(human-readable part) Address(string), returns address or error +func NewAddress(addr string) (result *Address, err error) { + var r Address + if err = r.UnmarshalText([]byte(addr)); err != nil { + return + } + return &r, nil +} + +// create a new address from key +func NewAddressFromKeys(key *crypto.Point) (result *Address) { + result = &Address{ + Mainnet: true, + PublicKey: new(crypto.Point).Set(key), + } + return +} diff --git a/rpc/address_test.go1 b/rpc/address_test.go1 new file mode 100644 index 0000000..3377146 --- /dev/null +++ b/rpc/address_test.go1 @@ -0,0 +1,250 @@ +// Copyright 2017-2018 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package address + +import "fmt" +import "bytes" +import "testing" +import "encoding/hex" + +import "github.com/deroproject/derohe/config" + +func TestAddressError(t *testing.T) { + _, err := NewAddress("") + want := fmt.Errorf("Address is not complete") + if err.Error() != want.Error() { + t.Fatalf("want: %s, got: %s", want, err) + } + + _, err = NewAddress("dERoNzsi5WW1ABhQ1UGLwoLqBU6sbzvyuS4cCi4PGzW7QRM5TH4MUf3QvZUBNJCYSDPw6K495eroGe24cf75uDdD2QwWy9pchN") + want = fmt.Errorf("Checksum failed") + if err.Error() != want.Error() { + t.Fatalf("want: %s, got: %s", want, err) + } + +} + +func TestAddress(t *testing.T) { + + const Monero_MainNetwork = 18 + const Monero_TestNetwork = 53 + + tests := []struct { + name string + Network uint64 + SpendingKeyHex string + ViewingKeyHex string + Address string + }{ + { + name: "generic", + Network: Monero_MainNetwork, + SpendingKeyHex: "8c1a9d5ff5aaf1c3cdeb2a1be62f07a34ae6b15fe47a254c8bc240f348271679", + ViewingKeyHex: "0a29b163e392eb9416a52907fd7d3b84530f8d02ff70b1f63e72fdcb54cf7fe1", + Address: "46w3n5EGhBeZkYmKvQRsd8UK9GhvcbYWQDobJape3NLMMFEjFZnJ3CnRmeKspubQGiP8iMTwFEX2QiBsjUkjKT4SSPd3fKp", + }, + { + name: "generic 2", + Network: Monero_MainNetwork, + SpendingKeyHex: "5007b84275af9a173c2080683afce90b2157ab640c18ddd5ce3e060a18a9ce99", + ViewingKeyHex: "27024b45150037b677418fcf11ba9675494ffdf994f329b9f7a8f8402b7934a0", + Address: "44f1Y84r9Lu4tQdLWRxV122rygfhUeVBrcmBaqcYCwUHScmf1ht8DFLXX9YN4T7nPPLcpqYLUdrFiY77nQYeH9RuK9gg4p6", + }, + { + name: "require 1 padding in middle", + Network: Monero_MainNetwork, + SpendingKeyHex: "6add197bd82866e8bfbf1dc2fdf49873ec5f679059652da549cd806f2b166756", + ViewingKeyHex: "f5cf2897088fda0f7ac1c42491ed7d558a46ee41d0c81d038fd53ff4360afda0", + Address: "45fzHekTd5FfvxWBPYX2TqLPbtWjaofxYUeWCi6BRQXYFYd85sY2qw73bAuKhqY7deFJr6pN3STY81bZ9x2Zf4nGKASksqe", + }, + { + name: "require 1 padding in last chunk", + Network: Monero_MainNetwork, + SpendingKeyHex: "50defe92d88b19aaf6bf66f061dd4380b79866a4122b25a03bceb571767dbe7b", + ViewingKeyHex: "f8f6f28283921bf5a17f0bcf4306233fc25ce9b6276154ad0de22aebc5c67702", + Address: "44grjkXtDHJVbZgtU1UKnrNXidcHfZ3HWToU5WjR3KgHMjgwrYLjXC6i5vm3HCp4vnBfYaNEyNiuZVwqtHD2SenS1JBRyco", + }, + { + name: "testnet", + Network: Monero_TestNetwork, + SpendingKeyHex: "8de9cce254e60cd940abf6c77ef344c3a21fad74320e45734fbfcd5870e5c875", + ViewingKeyHex: "27024b45150037b677418fcf11ba9675494ffdf994f329b9f7a8f8402b7934a0", + Address: "9xYZvCDf6aFdLd7Qawg5XHZitWLKoeFvcLHfe5GxsGCFLbXSWeQNKciXX9YN4T7nPPLcpqYLUdrFiY77nQYeH9RuK9bogZJ", + }, + + { + name: "DERO testnet", + Network: config.Testnet.Public_Address_Prefix, + SpendingKeyHex: "ffb4baf32792d38d36c5f1792201d1cff142a10bad6aa088090156a35858739d", + ViewingKeyHex: "0ea428a9608fc9dc06acceea608ac97cc9119647b943941a381306548ee43455", + Address: "dETosYceeTxRZQBk5hQzN51JepzZn5H24JqR96q7mY7ZFo6JhJKPNSKR3vs9ES1ibyQDQgeRheDP6CJbb7AKJY2H9eacz2RtPy", + }, + { + name: "DERO mainnet requires padding in second block", + Network: config.Mainnet.Public_Address_Prefix, + SpendingKeyHex: "10a80329a700f25c9892a696de768f5bdc73cafe6095d647e5707c04f48c0481", + ViewingKeyHex: "b0fa8ca43a8f07681274ddd8fa891aea4222aa8027dd516bc144317a042547c4", + Address: "dERoNzsi5WW1ABhQ1UGLwoLqBU6sbzvyuS4cCi4PGzW7QRM5TH4MUf3QvZUBNJCYSDPw6K495eroGe24cf75uDdD2QwWy9pchM", + }, + } + var base58 string + var spendingKey, viewingKey []byte + for _, test := range tests { + spendingKey, _ = hex.DecodeString(test.SpendingKeyHex) + viewingKey, _ = hex.DecodeString(test.ViewingKeyHex) + + address, err := NewAddress(test.Address) + if err != nil { + t.Fatalf("%s: Failed while parsing address %s", test.name, err) + continue + } + + if address.Network != test.Network { + t.Fatalf("%s: want: %d, got: %d", test.name, test.Network, address.Network) + continue + } + + if bytes.Compare(address.SpendKey[:], spendingKey) != 0 { + t.Fatalf("%s: want: %x, got: %s", test.name, spendingKey, address.SpendKey) + continue + } + if bytes.Compare(address.ViewKey[:], viewingKey) != 0 { + t.Fatalf("%s: want: %x, got: %s", test.name, viewingKey, address.ViewKey) + continue + } + + base58 = address.Base58() + if base58 != test.Address { + t.Fatalf("%s: want: %s, got: %s", test.name, test.Address, base58) + continue + } + + } +} + +// more explaination here https://monero.stackexchange.com/questions/1910/how-do-payment-ids-work +// test case created from here https://xmr.llcoins.net/addresstests.html +func TestIntegratedAddress(t *testing.T) { + + const Monero_MainNetwork = 18 + const Monero_MainNetwork_Integrated = 19 + const Monero_TestNetwork = 53 + + tests := []struct { + name string + Network uint64 + NetworkI uint64 + SpendingKeyHex string + ViewingKeyHex string + PaymentID string + Address string + AddressI string + }{ + { + name: "generic", + Network: Monero_MainNetwork, + NetworkI: Monero_MainNetwork_Integrated, + SpendingKeyHex: "80d3eca27896f549abc41dd941d08a4c82cff165a7f8bc4c3c0841cffd11c095", + ViewingKeyHex: "7849297236cd7c0d6c69a3c8c179c038d3c1c434735741bb3c8995c3c9d6f2ac", + PaymentID: "90470a40196034b5", + Address: "46WGHoGHRT2DKhdr4BxzhXDoFe5NBjNm1Dka5144aXZHS13cAoUQWRq3FE2gcT3LJjAWJ6fGWq8t8YKRqwwit8vmLT6tcxK", + + AddressI: "4GCwJc5n2iYDKhdr4BxzhXDoFe5NBjNm1Dka5144aXZHS13cAoUQWRq3FE2gcT3LJjAWJ6fGWq8t8YKRqwwit8vmVs5oxyLeWQsMWmcgkC", + }, + + { + name: "generic", + Network: config.Mainnet.Public_Address_Prefix, + NetworkI: config.Mainnet.Public_Address_Prefix_Integrated, + SpendingKeyHex: "bd7393b76af23611e6e0eb1e4974bcb5688fceea6ad8a1b08435a4e68fcb7b8c", + ViewingKeyHex: "c828aa405d78c3a0b0a7263d2cb82811d4c6ee3374ada5cc753d8196a271b3d2", + PaymentID: "0cbd6e050cf3b73c", + Address: "dERoiVavtPjhWkdEPp17RJLXVoHkr2ucMdEbgGgpskhLb33732LBifWMCZhPga3EcjXoYqfM9jRv3W3bnWUSpdmK5Jur1PhN6P", + + AddressI: "dERijfr9y7XhWkdEPp17RJLXVoHkr2ucMdEbgGgpskhLb33732LBifWMCZhPga3EcjXoYqfM9jRv3W3bnWUSpdmKL24FBjG6ctTAEg1jrhDHh", + }, + } + + var base58 string + var spendingKey, viewingKey []byte + for _, test := range tests { + spendingKey, _ = hex.DecodeString(test.SpendingKeyHex) + viewingKey, _ = hex.DecodeString(test.ViewingKeyHex) + + address, err := NewAddress(test.Address) + if err != nil { + t.Fatalf("%s: Failed while parsing address %s", test.name, err) + continue + } + + if address.Network != test.Network { + t.Errorf("%s: want: %d, got: %d", test.name, test.Network, address.Network) + continue + } + + if bytes.Compare(address.SpendKey[:], spendingKey) != 0 { + t.Fatalf("%s: want: %x, got: %s", test.name, spendingKey, address.SpendKey) + continue + } + if bytes.Compare(address.ViewKey[:], viewingKey) != 0 { + t.Fatalf("%s: want: %x, got: %s", test.name, viewingKey, address.ViewKey) + continue + } + + base58 = address.Base58() + if base58 != test.Address { + t.Fatalf("%s: want: %s, got: %s", test.name, test.Address, base58) + continue + } + + address, err = NewAddress(test.AddressI) + if err != nil { + t.Fatalf("%s: Failed while parsing address %s", test.name, err) + continue + } + + base58 = address.Base58() + if base58 != test.AddressI { + t.Fatalf("%s: want: %s, got: %s", test.name, test.AddressI, base58) + continue + } + + if fmt.Sprintf("%x", address.PaymentID) != test.PaymentID { + t.Fatalf("%s: PaymentID want: %s, got: %s", test.name, test.PaymentID, address.PaymentID) + } + + } + +} + +func Test_Bruteforce_IntegratedAddress(t *testing.T) { + var AddressI string = "dERijfr9y7XhWkdEPp17RJLXVoHkr2ucMdEbgGgpskhLb33732LBifWMCZhPga3EcjXoYqfM9jRv3W3bnWUSpdmKL24FBjG6ctTAEg1jrhDHh" + + var PaymentID string = "0cbd6e050cf3b73c" + + + for i := 0; i < 100000;i++ { + address, err := NewAddress(AddressI) + if err != nil { + t.Fatalf("%s: Failed while parsing address %s", AddressI, err) + continue + } + if fmt.Sprintf("%x",address.PaymentID) != PaymentID{ + t.Fatalf("Payment ID failed at loop %d", i) + } + } +} diff --git a/rpc/bech32.go b/rpc/bech32.go new file mode 100644 index 0000000..4e98eea --- /dev/null +++ b/rpc/bech32.go @@ -0,0 +1,217 @@ +// Package bech32 reference implementation for Bech32 and segwit addresses. +// Copyright (c) 2017 Takatoshi Nakagawa +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. +package rpc + +import ( + "bytes" + "fmt" + "strings" +) + +var charset = "qpzry9x8gf2tvdw0s3jn54khce6mua7l" + +var generator = []int{0x3b6a57b2, 0x26508e6d, 0x1ea119fa, 0x3d4233dd, 0x2a1462b3} + +func polymod(values []int) int { + chk := 1 + for _, v := range values { + top := chk >> 25 + chk = (chk&0x1ffffff)<<5 ^ v + for i := 0; i < 5; i++ { + if (top>>uint(i))&1 == 1 { + chk ^= generator[i] + } + } + } + return chk +} + +func hrpExpand(hrp string) []int { + ret := []int{} + for _, c := range hrp { + ret = append(ret, int(c>>5)) + } + ret = append(ret, 0) + for _, c := range hrp { + ret = append(ret, int(c&31)) + } + return ret +} + +func verifyChecksum(hrp string, data []int) bool { + return polymod(append(hrpExpand(hrp), data...)) == 1 +} + +func createChecksum(hrp string, data []int) []int { + values := append(append(hrpExpand(hrp), data...), []int{0, 0, 0, 0, 0, 0}...) + mod := polymod(values) ^ 1 + ret := make([]int, 6) + for p := 0; p < len(ret); p++ { + ret[p] = (mod >> uint(5*(5-p))) & 31 + } + return ret +} + +// Encode encodes hrp(human-readable part) and data(32bit data array), returns Bech32 / or error +// if hrp is uppercase, return uppercase Bech32 +func Encode(hrp string, data []int) (string, error) { + if (len(hrp) + len(data) + 7) > 90 { + //return "", fmt.Errorf("too long : hrp length=%d, data length=%d", len(hrp), len(data)) + } + if len(hrp) < 1 { + return "", fmt.Errorf("invalid hrp : hrp=%v", hrp) + } + for p, c := range hrp { + if c < 33 || c > 126 { + return "", fmt.Errorf("invalid character human-readable part : hrp[%d]=%d", p, c) + } + } + if strings.ToUpper(hrp) != hrp && strings.ToLower(hrp) != hrp { + return "", fmt.Errorf("mix case : hrp=%v", hrp) + } + lower := strings.ToLower(hrp) == hrp + hrp = strings.ToLower(hrp) + combined := append(data, createChecksum(hrp, data)...) + var ret bytes.Buffer + ret.WriteString(hrp) + ret.WriteString("1") + for idx, p := range combined { + if p < 0 || p >= len(charset) { + return "", fmt.Errorf("invalid data : data[%d]=%d", idx, p) + } + ret.WriteByte(charset[p]) + } + if lower { + return ret.String(), nil + } + return strings.ToUpper(ret.String()), nil +} + +// Decode decodes bechString(Bech32) returns hrp(human-readable part) and data(32bit data array) / or error +func Decode(bechString string) (string, []int, error) { + if len(bechString) > 90 { + //return "", nil, fmt.Errorf("too long : len=%d", len(bechString)) + } + if strings.ToLower(bechString) != bechString && strings.ToUpper(bechString) != bechString { + return "", nil, fmt.Errorf("mixed case") + } + bechString = strings.ToLower(bechString) + pos := strings.LastIndex(bechString, "1") + if pos < 1 || pos+7 > len(bechString) { + return "", nil, fmt.Errorf("separator '1' at invalid position : pos=%d , len=%d", pos, len(bechString)) + } + hrp := bechString[0:pos] + for p, c := range hrp { + if c < 33 || c > 126 { + return "", nil, fmt.Errorf("invalid character human-readable part : bechString[%d]=%d", p, c) + } + } + data := []int{} + for p := pos + 1; p < len(bechString); p++ { + d := strings.Index(charset, fmt.Sprintf("%c", bechString[p])) + if d == -1 { + return "", nil, fmt.Errorf("invalid character data part : bechString[%d]=%d", p, bechString[p]) + } + data = append(data, d) + } + if !verifyChecksum(hrp, data) { + return "", nil, fmt.Errorf("invalid checksum") + } + return hrp, data[:len(data)-6], nil +} + +func convertbits(data []int, frombits, tobits uint, pad bool) ([]int, error) { + acc := 0 + bits := uint(0) + ret := []int{} + maxv := (1 << tobits) - 1 + for idx, value := range data { + if value < 0 || (value>>frombits) != 0 { + return nil, fmt.Errorf("invalid data range : data[%d]=%d (frombits=%d)", idx, value, frombits) + } + acc = (acc << frombits) | value + bits += frombits + for bits >= tobits { + bits -= tobits + ret = append(ret, (acc>>bits)&maxv) + } + } + if pad { + if bits > 0 { + ret = append(ret, (acc<<(tobits-bits))&maxv) + } + } else if bits >= frombits { + return nil, fmt.Errorf("illegal zero padding") + } else if ((acc << (tobits - bits)) & maxv) != 0 { + return nil, fmt.Errorf("non-zero padding") + } + return ret, nil +} + +// SegwitAddrDecode decodes hrp(human-readable part) Segwit Address(string), returns version(int) and data(bytes array) / or error +func SegwitAddrDecode(hrp, addr string) (int, []int, error) { + dechrp, data, err := Decode(addr) + if err != nil { + return -1, nil, err + } + if dechrp != hrp { + return -1, nil, fmt.Errorf("invalid human-readable part : %s != %s", hrp, dechrp) + } + if len(data) < 1 { + return -1, nil, fmt.Errorf("invalid decode data length : %d", len(data)) + } + if data[0] > 16 { + return -1, nil, fmt.Errorf("invalid witness version : %d", data[0]) + } + res, err := convertbits(data[1:], 5, 8, false) + if err != nil { + return -1, nil, err + } + if len(res) < 2 || len(res) > 40 { + return -1, nil, fmt.Errorf("invalid convertbits length : %d", len(res)) + } + if data[0] == 0 && len(res) != 20 && len(res) != 32 { + return -1, nil, fmt.Errorf("invalid program length for witness version 0 (per BIP141) : %d", len(res)) + } + return data[0], res, nil +} + +// SegwitAddrEncode encodes hrp(human-readable part) , version(int) and data(bytes array), returns Segwit Address / or error +func SegwitAddrEncode(hrp string, version int, program []int) (string, error) { + if version < 0 || version > 16 { + return "", fmt.Errorf("invalid witness version : %d", version) + } + if len(program) < 2 || len(program) > 40 { + return "", fmt.Errorf("invalid program length : %d", len(program)) + } + if version == 0 && len(program) != 20 && len(program) != 32 { + return "", fmt.Errorf("invalid program length for witness version 0 (per BIP141) : %d", len(program)) + } + data, err := convertbits(program, 8, 5, true) + if err != nil { + return "", err + } + ret, err := Encode(hrp, append([]int{version}, data...)) + if err != nil { + return "", err + } + return ret, nil +} diff --git a/rpc/bech32_test.go b/rpc/bech32_test.go new file mode 100644 index 0000000..f88804f --- /dev/null +++ b/rpc/bech32_test.go @@ -0,0 +1,402 @@ +// Copyright (c) 2017 Takatoshi Nakagawa +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. +package rpc + +import ( + "reflect" + "strings" + "testing" +) + +func segwitScriptpubkey(version int, program []int) []int { + if version != 0 { + version += 0x50 + } + return append(append([]int{version}, len(program)), program...) +} + +var validChecksum = []string{ + "A12UEL5L", + "an83characterlonghumanreadablepartthatcontainsthenumber1andtheexcludedcharactersbio1tt5tgs", + "abcdef1qpzry9x8gf2tvdw0s3jn54khce6mua7lmqqqxw", + "11qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqc8247j", + "split1checkupstagehandshakeupstreamerranterredcaperred2y9e3w", +} + +var invalidChecksum = []string{ + " 1nwldj5", + "\x7F" + "1axkwrx", + "an84characterslonghumanreadablepartthatcontainsthenumber1andtheexcludedcharactersbio1569pvx", + "pzry9x0s0muk", + "1pzry9x0s0muk", + "x1b4n0q5v", + "li1dgmt3", + "de1lg7wt\xFF", +} + +type item struct { + address string + scriptpubkey []int +} + +var validAddress = []item{ + item{"BC1QW508D6QEJXTDG4Y5R3ZARVARY0C5XW7KV8F3T4", + []int{ + 0x00, 0x14, 0x75, 0x1e, 0x76, 0xe8, 0x19, 0x91, 0x96, 0xd4, 0x54, + 0x94, 0x1c, 0x45, 0xd1, 0xb3, 0xa3, 0x23, 0xf1, 0x43, 0x3b, 0xd6, + }, + }, + item{"tb1qrp33g0q5c5txsp9arysrx4k6zdkfs4nce4xj0gdcccefvpysxf3q0sl5k7", + []int{ + 0x00, 0x20, 0x18, 0x63, 0x14, 0x3c, 0x14, 0xc5, 0x16, 0x68, 0x04, + 0xbd, 0x19, 0x20, 0x33, 0x56, 0xda, 0x13, 0x6c, 0x98, 0x56, 0x78, + 0xcd, 0x4d, 0x27, 0xa1, 0xb8, 0xc6, 0x32, 0x96, 0x04, 0x90, 0x32, + 0x62, + }, + }, + item{"bc1pw508d6qejxtdg4y5r3zarvary0c5xw7kw508d6qejxtdg4y5r3zarvary0c5xw7k7grplx", + []int{ + 0x51, 0x28, 0x75, 0x1e, 0x76, 0xe8, 0x19, 0x91, 0x96, 0xd4, 0x54, + 0x94, 0x1c, 0x45, 0xd1, 0xb3, 0xa3, 0x23, 0xf1, 0x43, 0x3b, 0xd6, + 0x75, 0x1e, 0x76, 0xe8, 0x19, 0x91, 0x96, 0xd4, 0x54, 0x94, 0x1c, + 0x45, 0xd1, 0xb3, 0xa3, 0x23, 0xf1, 0x43, 0x3b, 0xd6, + }, + }, + item{"BC1SW50QA3JX3S", + []int{ + 0x60, 0x02, 0x75, 0x1e, + }, + }, + item{"bc1zw508d6qejxtdg4y5r3zarvaryvg6kdaj", + []int{ + 0x52, 0x10, 0x75, 0x1e, 0x76, 0xe8, 0x19, 0x91, 0x96, 0xd4, 0x54, + 0x94, 0x1c, 0x45, 0xd1, 0xb3, 0xa3, 0x23, + }, + }, + item{"tb1qqqqqp399et2xygdj5xreqhjjvcmzhxw4aywxecjdzew6hylgvsesrxh6hy", + []int{ + 0x00, 0x20, 0x00, 0x00, 0x00, 0xc4, 0xa5, 0xca, 0xd4, 0x62, 0x21, + 0xb2, 0xa1, 0x87, 0x90, 0x5e, 0x52, 0x66, 0x36, 0x2b, 0x99, 0xd5, + 0xe9, 0x1c, 0x6c, 0xe2, 0x4d, 0x16, 0x5d, 0xab, 0x93, 0xe8, 0x64, + 0x33, + }, + }, +} + +var invalidAddress = []string{ + "tc1qw508d6qejxtdg4y5r3zarvary0c5xw7kg3g4ty", + "bc1qw508d6qejxtdg4y5r3zarvary0c5xw7kv8f3t5", + "BC13W508D6QEJXTDG4Y5R3ZARVARY0C5XW7KN40WF2", + "bc1rw5uspcuh", + "bc10w508d6qejxtdg4y5r3zarvary0c5xw7kw508d6qejxtdg4y5r3zarvary0c5xw7kw5rljs90", + "BC1QR508D6QEJXTDG4Y5R3ZARVARYV98GJ9P", + "tb1qrp33g0q5c5txsp9arysrx4k6zdkfs4nce4xj0gdcccefvpysxf3q0sL5k7", + "bc1zw508d6qejxtdg4y5r3zarvaryvqyzf3du", + "tb1qrp33g0q5c5txsp9arysrx4k6zdkfs4nce4xj0gdcccefvpysxf3pjxtptv", + "bc1gmk9yu", +} + +func TestValidChecksum(t *testing.T) { + for _, test := range validChecksum { + hrp, data, err := Decode(test) + if err != nil { + t.Errorf("Valid checksum for %s : FAIL / error %+v\n", test, err) + } else { + t.Logf("Valid checksum for %s : ok / hrp : %+v , data : %+v\n", test, hrp, data) + } + } +} + +func TestInvalidChecksum(t *testing.T) { + for _, test := range invalidChecksum { + hrp, data, err := Decode(test) + if err != nil { + t.Logf("Invalid checksum for %s : ok / hrp : %+v , data : %+v\n", test, hrp, data) + } else { + t.Errorf("Invalid checksum for %s : FAIL\n", test) + } + } +} + +func TestValidAddress(t *testing.T) { + for _, test := range validAddress { + hrp := "bc" + version, program, err := SegwitAddrDecode(hrp, test.address) + if err != nil { + hrp = "tb" + version, program, err = SegwitAddrDecode(hrp, test.address) + } + ok := err == nil + if ok { + output := segwitScriptpubkey(version, program) + ok = reflect.DeepEqual(output, test.scriptpubkey) + } + if ok { + recreate, err := SegwitAddrEncode(hrp, version, program) + if err == nil { + ok = recreate == strings.ToLower(test.address) + } + } + if ok { + t.Logf("Valid address %v : ok\n", test.address) + } else { + t.Errorf("Valid address %v : FAIL\n", test.address) + } + } +} + +func TestInvalidAddress(t *testing.T) { + for _, test := range invalidAddress { + _, _, bcErr := SegwitAddrDecode("bc", test) + t.Logf("bc error:%v\n", bcErr) + _, _, tbErr := SegwitAddrDecode("tb", test) + t.Logf("tb error:%v\n", tbErr) + if bcErr != nil && tbErr != nil { + t.Logf("Invalid address %v : ok\n", test) + } else { + t.Errorf("Invalid address %v : FAIL\n", test) + } + } +} + +// add coverage tests + +func TestCoverage(t *testing.T) { + var err error + var bech32String string + var hrp string + var data []int + + // SegwitAddrEncode + bech32String, err = SegwitAddrEncode("bc", 1, []int{0, 1}) + if err != nil { + t.Errorf("Coverage SegwitAddrEncode normal case : FAIL / error : %+v\n", err) + } else { + t.Log("Coverage SegwitAddrEncode normal case : ok / bech32String :", bech32String) + } + data = make([]int, 40) + bech32String, err = SegwitAddrEncode("bc", 16, data) + if err != nil { + t.Errorf("Coverage SegwitAddrEncode normal case : FAIL / error : %+v\n", err) + } else { + t.Log("Coverage SegwitAddrEncode normal case : ok / bech32String :", bech32String) + } + data = make([]int, 20) + bech32String, err = SegwitAddrEncode("bc", 0, data) + if err != nil { + t.Errorf("Coverage SegwitAddrEncode normal case : FAIL / error : %+v\n", err) + } else { + t.Log("Coverage SegwitAddrEncode normal case : ok / bech32String :", bech32String) + } + data = make([]int, 32) + bech32String, err = SegwitAddrEncode("bc", 0, data) + if err != nil { + t.Errorf("Coverage SegwitAddrEncode normal case : FAIL / error : %+v\n", err) + } else { + t.Log("Coverage SegwitAddrEncode normal case : ok / bech32String :", bech32String) + } + data = make([]int, 1) + _, err = SegwitAddrEncode("bc", 1, data) + if err == nil { + t.Errorf("Coverage SegwitAddrEncode invalid program length error case : FAIL") + } else { + t.Log("Coverage SegwitAddrEncode invalid program length error case : ok / error :", err) + } + data = make([]int, 41) + _, err = SegwitAddrEncode("bc", 1, data) + if err == nil { + t.Errorf("Coverage SegwitAddrEncode invalid program length error case : FAIL") + } else { + t.Log("Coverage SegwitAddrEncode invalid program length error case : ok / error :", err) + } + data = make([]int, 26) + _, err = SegwitAddrEncode("bc", 0, data) + if err == nil { + t.Errorf("Coverage SegwitAddrEncode invalid program length for witness version 0 (per BIP141) error case : FAIL") + } else { + t.Log("Coverage SegwitAddrEncode invalid program length for witness version 0 (per BIP141) error case : ok / error :", err) + } + data = make([]int, 20) + _, err = SegwitAddrEncode("Bc", 0, data) + if err == nil { + t.Errorf("Coverage SegwitAddrEncode Encode error case : FAIL") + } else { + t.Log("Coverage SegwitAddrEncode Encode error case : ok / error :", err) + } + _, err = SegwitAddrEncode("bc", 1, []int{-1, 0}) + if err == nil { + t.Errorf("Coverage SegwitAddrEncode invalid data range error case : FAIL") + } else { + t.Log("Coverage SegwitAddrEncode invalid data range error case : ok / error :", err) + } + _, err = SegwitAddrEncode("bc", -1, data) + if err == nil { + t.Errorf("Coverage SegwitAddrEncode invalid witness version error case : FAIL") + } else { + t.Log("Coverage SegwitAddrEncode invalid witness version error case : ok / error :", err) + } + _, err = SegwitAddrEncode("bc", 17, data) + if err == nil { + t.Errorf("Coverage SegwitAddrEncode invalid witness version error case : FAIL") + } else { + t.Log("Coverage SegwitAddrEncode invalid witness version error case : ok / error :", err) + } + + // SegwitAddrDecode + _, _, err = SegwitAddrDecode("a", "A12UEL5L") + if err == nil { + t.Errorf("Coverage SegwitAddrDecode invalid decode data length error case : FAIL") + } else { + t.Log("Coverage SegwitAddrDecode invalid decode data length error case : ok / error :", err) + } + + // Decode + _, _, err = Decode("!~1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqc356v3") + if err != nil { + t.Errorf("Coverage Decode normal case : FAIL / error :%v", err) + } else { + t.Log("Coverage Decode normal case : ok") + } + _, _, err = Decode("a1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq") + if err == nil { + t.Errorf("Coverage Decode too long error case : FAIL") + } else { + t.Log("Coverage Decode too long error case : ok / error :", err) + } + _, _, err = Decode("1") + if err == nil { + t.Errorf("Coverage Decode separator '1' at invalid position error case : FAIL") + } else { + t.Log("Coverage Decode separator '1' at invalid position error case : ok / error :", err) + } + _, _, err = Decode("a1qqqqq") + if err == nil { + t.Errorf("Coverage Decode separator '1' at invalid position error case : FAIL") + } else { + t.Log("Coverage Decode separator '1' at invalid position error case : ok / error :", err) + } + _, _, err = Decode("a" + string(rune(32)) + "1qqqqqq") + if err == nil { + t.Errorf("Coverage Decode invalid character human-readable part error case : FAIL") + } else { + t.Log("Coverage Decode invalid character human-readable part error case : ok / error :", err) + } + _, _, err = Decode("a" + string(rune(127)) + "1qqqqqq") + if err == nil { + t.Errorf("Coverage Decode invalid character human-readable part error case : FAIL") + } else { + t.Log("Coverage Decode invalid character human-readable part error case : ok / error :", err) + } + _, _, err = Decode("a1qqqqqb") + if err == nil { + t.Errorf("Coverage Decode invalid character data part error case : FAIL") + } else { + t.Log("Coverage Decode invalid character data part erroer case : ok / error :", err) + } + + // Encode + hrp = "bc" + data = []int{} + bech32String, err = Encode(hrp, data) + if err != nil || bech32String != strings.ToLower(bech32String) { + t.Errorf("Coverage Encode lower case : FAIL / bech32String : %v , error : %v", bech32String, err) + } else { + t.Log("Coverage Encode lower case : ok / bech32String : ", bech32String) + } + hrp = "BC" + bech32String, err = Encode(hrp, data) + if err != nil || bech32String != strings.ToUpper(bech32String) { + t.Errorf("Coverage Encode upper case : FAIL / bech32String : %v , error : %v", bech32String, err) + } else { + t.Log("Coverage Encode upper case : ok / bech32String : ", bech32String) + } + hrp = "bc" + data = make([]int, 90-7-len(hrp)+1) + bech32String, err = Encode(hrp, data) + if err == nil { + t.Errorf("Coverage Encode too long error case : FAIL / bech32String : %v", bech32String) + } else { + t.Log("Coverage Encode too long error case : ok / error : ", err) + } + hrp = "" + data = make([]int, 90-7-len(hrp)) + bech32String, err = Encode(hrp, data) + if err == nil { + t.Errorf("Coverage Encode invalid hrp error case : FAIL / bech32String : %v", bech32String) + } else { + t.Log("Coverage Encode invalid hrp error case : ok / error : ", err) + } + hrp = "Bc" + data = make([]int, 90-7-len(hrp)) + bech32String, err = Encode(hrp, data) + if err == nil { + t.Errorf("Coverage Encode mix case error case : FAIL / bech32String : %v", bech32String) + } else { + t.Log("Coverage Encode mix case error case : ok / error : ", err) + } + hrp = string(rune(33)) + string(rune(126)) + data = make([]int, 90-7-len(hrp)) + bech32String, err = Encode(hrp, data) + if err != nil { + t.Errorf("Coverage Encode normal case : FAIL / error : %v", err) + } else { + t.Log("Coverage Encode normal case : ok / bech32String : ", bech32String) + } + hrp = string(rune(32)) + "c" + data = make([]int, 90-7-len(hrp)) + bech32String, err = Encode(hrp, data) + if err == nil { + t.Errorf("Coverage Encode invalid character human-readable part error case : FAIL / bech32String : %v", bech32String) + } else { + t.Log("Coverage Encode invalid character human-readable part error case : ok / error : ", err) + } + hrp = "b" + string(rune(127)) + data = make([]int, 90-7-len(hrp)) + bech32String, err = Encode(hrp, data) + if err == nil { + t.Errorf("Coverage Encode invalid character human-readable part error case : FAIL / bech32String : %v", bech32String) + } else { + t.Log("Coverage Encode invalid character human-readable part error case : ok / error : ", err) + } + hrp = "bc" + data = []int{0, 31} + bech32String, err = Encode(hrp, data) + if err != nil { + t.Errorf("Coverage Encode normal case : FAIL / error : %v", err) + } else { + t.Log("Coverage Encode normal case : ok / bech32String : ", bech32String) + } + hrp = "bc" + data = []int{-1} + bech32String, err = Encode(hrp, data) + if err == nil { + t.Errorf("Coverage Encode invalid data error case : FAIL / bech32String : %v", bech32String) + } else { + t.Log("Coverage Encode invalid data error case : ok / error : ", err) + } + hrp = "bc" + data = []int{32} + bech32String, err = Encode(hrp, data) + if err == nil { + t.Errorf("Coverage Encode invalid data error case : FAIL / bech32String : %v", bech32String) + } else { + t.Log("Coverage Encode invalid data error case : ok / error : ", err) + } +} diff --git a/rpc/daemon_rpc.go b/rpc/daemon_rpc.go new file mode 100644 index 0000000..4a01b9d --- /dev/null +++ b/rpc/daemon_rpc.go @@ -0,0 +1,304 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +// this package contains struct definitions and related processing code + +package rpc + +import "github.com/deroproject/derohe/cryptography/crypto" + +// this is used to print blockheader for the rpc and the daemon +type BlockHeader_Print struct { + Depth int64 `json:"depth"` + Difficulty string `json:"difficulty"` + Hash string `json:"hash"` + Height int64 `json:"height"` + TopoHeight int64 `json:"topoheight"` + Major_Version uint64 `json:"major_version"` + Minor_Version uint64 `json:"minor_version"` + Nonce uint64 `json:"nonce"` + Orphan_Status bool `json:"orphan_status"` + SyncBlock bool `json:"syncblock"` + SideBlock bool `json:"sideblock"` + TXCount int64 `json:"txcount"` + + Reward uint64 `json:"reward"` + Tips []string `json:"tips"` + Timestamp uint64 `json:"timestamp"` +} + +type ( + GetBlockHeaderByTopoHeight_Params struct { + TopoHeight uint64 `json:"topoheight"` + } + GetBlockHeaderByHeight_Result struct { + Block_Header BlockHeader_Print `json:"block_header"` + Status string `json:"status"` + } +) + +// GetBlockHeaderByHash +type ( + GetBlockHeaderByHash_Params struct { + Hash string `json:"hash"` + } // no params + GetBlockHeaderByHash_Result struct { + Block_Header BlockHeader_Print `json:"block_header"` + Status string `json:"status"` + } +) + +// get block count +type ( + GetBlockCount_Params struct { + // NO params + } + GetBlockCount_Result struct { + Count uint64 `json:"count"` + Status string `json:"status"` + } +) + +// getblock +type ( + GetBlock_Params struct { + Hash string `json:"hash,omitempty"` // Monero Daemon breaks if both are provided + Height uint64 `json:"height,omitempty"` // Monero Daemon breaks if both are provided + } // no params + GetBlock_Result struct { + Blob string `json:"blob"` + Json string `json:"json"` + Block_Header BlockHeader_Print `json:"block_header"` + Status string `json:"status"` + } +) + +// get block template request response +type ( + GetBlockTemplate_Params struct { + Wallet_Address string `json:"wallet_address"` + Reserve_size uint64 `json:"reserve_size"` + } + GetBlockTemplate_Result struct { + Blocktemplate_blob string `json:"blocktemplate_blob"` + Blockhashing_blob string `json:"blockhashing_blob"` + Expected_reward uint64 `json:"expected_reward"` + Difficulty uint64 `json:"difficulty"` + Height uint64 `json:"height"` + Prev_Hash string `json:"prev_hash"` + Reserved_Offset uint64 `json:"reserved_offset"` + Epoch uint64 `json:"epoch"` // used to expire pool jobs + Status string `json:"status"` + } +) + +type ( // array without name containing block template in hex + SubmitBlock_Params struct { + X []string + } + SubmitBlock_Result struct { + BLID string `json:"blid"` + Status string `json:"status"` + } +) + +type ( + GetLastBlockHeader_Params struct{} // no params + GetLastBlockHeader_Result struct { + Block_Header BlockHeader_Print `json:"block_header"` + Status string `json:"status"` + } +) + +//get encrypted balance call +type ( + GetEncryptedBalance_Params struct { + Address string `json:"address"` + SCID crypto.Hash `json:"scid"` + Merkle_Balance_TreeHash string `json:"treehash,omitempty"` + TopoHeight int64 `json:"topoheight,omitempty"` + } // no params + GetEncryptedBalance_Result struct { + Data string `json:"data"` // balance is in hex form, 66 * 2 byte = 132 bytes + Registration int64 `json:"registration"` // at what topoheight the account was registered + Bits int `json:"bits"` // no. of bits required to access the public key from the chain + Height int64 `json:"height"` // at what height is this balance + Topoheight int64 `json:"topoheight"` // at what topoheight is this balance + BlockHash string `json:"blockhash"` // blockhash at this topoheight + Merkle_Balance_TreeHash string `json:"treehash"` + DHeight int64 `json:"dheight"` // daemon height + DTopoheight int64 `json:"dtopoheight"` // daemon topoheight + DMerkle_Balance_TreeHash string `json:"dtreehash"` // daemon dmerkle tree hash + Status string `json:"status"` + } +) + +type ( + GetTxPool_Params struct{} // no params + GetTxPool_Result struct { + Tx_list []string `json:"txs,omitempty"` + Status string `json:"status"` + } +) + +// get height http response as json +type ( + Daemon_GetHeight_Result struct { + Height uint64 `json:"height"` + StableHeight int64 `json:"stableheight"` + TopoHeight int64 `json:"topoheight"` + + Status string `json:"status"` + } +) + +type ( + On_GetBlockHash_Params struct { + X [1]uint64 + } + On_GetBlockHash_Result struct{} +) + +type ( + GetTransaction_Params struct { + Tx_Hashes []string `json:"txs_hashes"` + Decode uint64 `json:"decode_as_json,omitempty"` // Monero Daemon breaks if this sent + } // no params + GetTransaction_Result struct { + Txs_as_hex []string `json:"txs_as_hex"` + Txs_as_json []string `json:"txs_as_json"` + Txs []Tx_Related_Info `json:"txs"` + Status string `json:"status"` + } + + Tx_Related_Info struct { + As_Hex string `json:"as_hex"` + As_Json string `json:"as_json"` + Block_Height int64 `json:"block_height"` + Reward uint64 `json:"reward"` // miner tx rewards are decided by the protocol during execution + Ignored bool `json:"ignored"` // tell whether this tx is okau as per client protocol or bein ignored + In_pool bool `json:"in_pool"` + Output_Indices []uint64 `json:"output_indices"` + Tx_hash string `json:"tx_hash"` + ValidBlock string `json:"valid_block"` // TX is valid in this block + InvalidBlock []string `json:"invalid_block"` // TX is invalid in this block, 0 or more + Ring [][][]byte `json:"ring"` // ring members completed, since tx contains compressed + Balance uint64 `json:"balance"` // if tx is SC, give SC balance at start + Code string `json:"code"` // smart contract code at start + BalanceNow uint64 `json:"balancenow"` // if tx is SC, give SC balance at current topo height + CodeNow string `json:"codenow"` // smart contract code at current topo + + } +) + +type ( + GetSC_Params struct { + SCID string `json:"scid"` + Code bool `json:"code,omitempty"` // if true code will be returned + TopoHeight int64 `json:"topoheight,omitempty"` // all queries are related to this topoheight + KeysUint64 []uint64 `json:"keysuint64,omitempty"` + KeysString []string `json:"keysstring,omitempty"` + KeysBytes [][]byte `json:"keysbytes,omitempty"` // all keys can also be represented as bytes + } + GetSC_Result struct { + ValuesUint64 []string `json:"valuesuint64,omitempty"` + ValuesString []string `json:"valuesstring,omitempty"` + ValuesBytes []string `json:"valuesbytes,omitempty"` + Balance uint64 `json:"balance"` + Code string `json:"code"` + Status string `json:"status"` + } +) + +type ( + GetRandomAddress_Params struct { + SCID crypto.Hash `json:"scid"` + } + + GetRandomAddress_Result struct { + Address []string `json:"address"` // daemon will return around 20 address in 1 go + Status string `json:"status"` + } +) + +type ( + SendRawTransaction_Params struct { + Tx_as_hex string `json:"tx_as_hex"` + } + SendRawTransaction_Result struct { + Status string `json:"status"` + DoubleSpend bool `json:"double_spend"` + FeeTooLow bool `json:"fee_too_low"` + InvalidInput bool `json:"invalid_input"` + InvalidOutput bool `json:"invalid_output"` + Low_Mixin bool `json:"low_mixin"` + Non_rct bool `json:"not_rct"` + NotRelayed bool `json:"not_relayed"` + Overspend bool `json:"overspend"` + TooBig bool `json:"too_big"` + Reason string `json:"string"` + } +) + +/* +{ + "id": "0", + "jsonrpc": "2.0", + "result": { + "alt_blocks_count": 5, + "difficulty": 972165250, + "grey_peerlist_size": 2280, + "height": 993145, + "incoming_connections_count": 0, + "outgoing_connections_count": 8, + "status": "OK", + "target": 60, + "target_height": 993137, + "testnet": false, + "top_block_hash": "", + "tx_count": 564287, + "tx_pool_size": 45, + "white_peerlist_size": 529 + } +}*/ +type ( + GetInfo_Params struct{} // no params + GetInfo_Result struct { + Alt_Blocks_Count uint64 `json:"alt_blocks_count"` + Difficulty uint64 `json:"difficulty"` + Grey_PeerList_Size uint64 `json:"grey_peerlist_size"` + Height int64 `json:"height"` + StableHeight int64 `json:"stableheight"` + TopoHeight int64 `json:"topoheight"` + Merkle_Balance_TreeHash string `json:"treehash"` + AverageBlockTime50 float32 `json:"averageblocktime50"` + Incoming_connections_count uint64 `json:"incoming_connections_count"` + Outgoing_connections_count uint64 `json:"outgoing_connections_count"` + Target uint64 `json:"target"` + Target_Height uint64 `json:"target_height"` + Testnet bool `json:"testnet"` + Top_block_hash string `json:"top_block_hash"` + Tx_count uint64 `json:"tx_count"` + Tx_pool_size uint64 `json:"tx_pool_size"` + Dynamic_fee_per_kb uint64 `json:"dynamic_fee_per_kb"` // our addition + Total_Supply uint64 `json:"total_supply"` // our addition + Median_Block_Size uint64 `json:"median_block_size"` // our addition + White_peerlist_size uint64 `json:"white_peerlist_size"` + Version string `json:"version"` + + Status string `json:"status"` + } +) diff --git a/rpc/rpc.go b/rpc/rpc.go new file mode 100644 index 0000000..4d4f9ab --- /dev/null +++ b/rpc/rpc.go @@ -0,0 +1,423 @@ +package rpc + +import "fmt" +import "time" +import "sort" +import "encoding/json" + +import "github.com/fxamacker/cbor" +import "github.com/deroproject/derohe/cryptography/crypto" + +// this package defines interfaces and necessary glue code Digital Network, it exposes and provides encrypted RPC calls over DERO chain + +var enc_options = cbor.EncOptions{ + Sort: cbor.SortCTAP2, + TimeTag: cbor.EncTagRequired, +} + +var dec_options = cbor.DecOptions{ + TimeTag: cbor.DecTagRequired, +} + +var dec cbor.DecMode +var enc cbor.EncMode + +func init() { + var err error + if dec, err = dec_options.DecMode(); err != nil { + panic(err) + } + if enc, err = enc_options.EncMode(); err != nil { + panic(err) + } + +} + +// currently we support only the following Data Type +// the following data types are present +// int64 represented by inputbox +// uint64 represented by inputbox +// string represented by input box +// what about listbox, checkbox , checkbox can be represented by bool but currently not suported +type DataType string + +const ( + DataString DataType = "S" + DataInt64 = "I" + DataUint64 = "U" + DataFloat64 = "F" + DataHash = "H" // a 256 bit hash (basically sha256 of 32 bytes long) + DataAddress = "A" // dero address represented in 33 bytes + DataTime = "T" +) + +func (d DataType) String() string { + switch d { + case DataString: + return "string" + case DataInt64: + return "int64" + case DataUint64: + return "uint64" + case DataFloat64: + return "float64" + case DataHash: + return "hash" + case DataAddress: + return "address" + case DataTime: + return "time" + + default: + return "unknown data type" + } + +} + +//type DataType byte +type Argument struct { + Name string `json:"name"` // string name must be atleast 1 byte + DataType DataType `json:"datatype"` // Type must one of the known data types + Value interface{} `json:"value"` // value should be as per type +} + +type Arguments []Argument + +func (arg Argument) String() string { + switch arg.DataType { + case DataString: + return fmt.Sprintf("Name:%s Type:%s Value:'%s'", arg.Name, arg.DataType, arg.Value) + case DataInt64: + return fmt.Sprintf("Name:%s Type:%s Value:'%d'", arg.Name, arg.DataType, arg.Value) + case DataUint64: + return fmt.Sprintf("Name:%s Type:%s Value:'%d'", arg.Name, arg.DataType, arg.Value) + case DataFloat64: + return fmt.Sprintf("Name:%s Type:%s Value:'%f'", arg.Name, arg.DataType, arg.Value) + case DataHash: + return fmt.Sprintf("Name:%s Type:%s Value:'%s'", arg.Name, arg.DataType, arg.Value) + case DataAddress: + return fmt.Sprintf("Name:%s Type:%s Value:'%x'", arg.Name, arg.DataType, arg.Value) + case DataTime: + return fmt.Sprintf("Name:%s Type:%s Value:'%s'", arg.Name, arg.DataType, arg.Value) + + default: + return "unknown data type" + } +} + +// tells whether the arguments have an argument of this type +func (args Arguments) Has(name string, dtype DataType) bool { + for _, arg := range args { + if arg.Name == name && arg.DataType == dtype { + return true + } + } + return false +} + +// tells whether the arguments have an argument of this type and value it not nil +func (args Arguments) HasValue(name string, dtype DataType) bool { + for _, arg := range args { + if arg.Name == name && arg.DataType == dtype && arg.Value != nil { + return true + } + } + return false +} + +// tells the index of the specific argument +func (args Arguments) Index(name string, dtype DataType) int { + for i, arg := range args { + if arg.Name == name && arg.DataType == dtype { + return i + } + } + return -1 +} + +// return value wrapped in an interface +func (args Arguments) Value(name string, dtype DataType) interface{} { + for _, arg := range args { + if arg.Name == name && arg.DataType == dtype { + return arg.Value + } + } + return nil +} + +// this function will pack the args into buffer of specific limit, if it fails, it panics +func (args Arguments) MustPack(limit int) []byte { + if packed, err := args.CheckPack(limit); err != nil { + panic(err) + } else { + return packed + } +} + +// this function will pack the args into buffer of specific limit, if it fails, it gives eroor +func (args Arguments) CheckPack(limit int) ([]byte, error) { + packed, err := args.MarshalBinary() + if err != nil { + return nil, err + } + if len(packed) > limit { + return nil, fmt.Errorf("Packed size %d bytes, but limit is %d", len(packed), limit) + } + if len(packed) == limit { + return packed, nil + } else { // we need to fill with 0 values, upto limit size + + fill_count := limit - len(packed) + for i := 0; i < fill_count; i++ { + packed = append(packed, 0) + } + + } + + return packed, nil +} + +// pack more deeply +func (args Arguments) MarshalBinary() (data []byte, err error) { + if err = args.Validate_Arguments(); err != nil { + return + } + + localmap := map[string]interface{}{} // this also filters any duplicates + for _, arg := range args { + switch v := arg.Value.(type) { + case int64: + localmap[arg.Name+string(arg.DataType)] = v + case uint64: + localmap[arg.Name+string(arg.DataType)] = v + case float64: + localmap[arg.Name+string(arg.DataType)] = v + case crypto.Hash: + localmap[arg.Name+string(arg.DataType)] = v + case Address: + localmap[arg.Name+string(arg.DataType)] = v + case string: + localmap[arg.Name+string(arg.DataType)] = v + case time.Time: + localmap[arg.Name+string(arg.DataType)] = v + default: + err = fmt.Errorf("I don't know about type %T!\n", v) + return + } + } + return enc.Marshal(localmap) +} + +func (args *Arguments) UnmarshalBinary(data []byte) (err error) { + localmap := map[string]interface{}{} + + if err = dec.Unmarshal(data, &localmap); err != nil { + return err + } + + *args = (*args)[:0] + + for k, v := range localmap { + if len(k) < 2 { + return fmt.Errorf("Invalid encoding for key '%s'", k) + } + + arg := Argument{Name: string(k[:len(k)-1]), DataType: DataType(k[len(k)-1:])} + + switch arg.DataType { + case DataInt64: + if value, ok := v.(int64); ok { + arg.Value = value + } else if value, ok := v.(uint64); ok { + arg.Value = int64(value) + } else { + return fmt.Errorf("%+v has invalid data typei %T\n", arg, v) + } + case DataUint64: + if value, ok := v.(uint64); ok { + arg.Value = value + } else { + return fmt.Errorf("%+v has invalid data type %T\n", arg, v) + } + case DataFloat64: + if value, ok := v.(float64); ok { + arg.Value = value + } else { + return fmt.Errorf("%+v has invalid data type %T\n", arg, v) + } + case DataHash: + if value, ok := v.([]uint8); ok { + var hash crypto.Hash + copy(hash[:], value) + arg.Value = hash + } else { + return fmt.Errorf("%+v has invalid data type %T\n", arg, v) + } + case DataAddress: + if value, ok := v.([]uint8); ok { + a := make([]byte, 33, 33) + copy(a[:], value) + + p := new(crypto.Point) + if err = p.DecodeCompressed(a[0:33]); err != nil { + return err + } + addr := NewAddressFromKeys(p) + arg.Value = *addr + } else { + return fmt.Errorf("%+v has invalid data type %T\n", arg, v) + } + case DataString: + if value, ok := v.(string); ok { + arg.Value = value + } else { + return fmt.Errorf("%+v has invalid data type %T\n", arg, v) + } + case DataTime: + if value, ok := v.(time.Time); ok { + arg.Value = value + } else { + return fmt.Errorf("%+v has invalid data type %T\n", arg, v) + } + default: + err = fmt.Errorf("I don't know about typeaa %T %s!\n", v, k) + return + } + *args = append(*args, arg) + + } + + if err = args.Validate_Arguments(); err != nil { + return + } + args.Sort() // sort everything + + return +} + +// used to validata arguments whether the type is proper +func (args Arguments) Validate_Arguments() error { + for _, arg := range args { + if len(arg.Name) < 1 { + return fmt.Errorf("Name must be atleast 1 char long") + } + + switch arg.DataType { + case DataString: + if _, ok := arg.Value.(string); !ok { + return fmt.Errorf("'%s' value should be of type string", arg.Name) + } + case DataInt64: + if _, ok := arg.Value.(int64); !ok { + return fmt.Errorf("'%s' value should be of type int64", arg.Name) + } + case DataUint64: + if _, ok := arg.Value.(uint64); !ok { + return fmt.Errorf("'%s' value should be of type uint64", arg.Name) + } + case DataFloat64: + if _, ok := arg.Value.(float64); !ok { + return fmt.Errorf("'%s' value should be of type float64", arg.Name) + } + case DataHash: + if _, ok := arg.Value.(crypto.Hash); !ok { + return fmt.Errorf("'%s' value should be of type Hash", arg.Name) + } + case DataAddress: + if _, ok := arg.Value.(Address); !ok { + return fmt.Errorf("'%s' value should be of type address", arg.Name) + } + case DataTime: + if _, ok := arg.Value.(time.Time); !ok { + return fmt.Errorf("'%s' value should be of type time", arg.Name) + } + + default: + return fmt.Errorf("unknown data type. Pls implement") + } + } + return nil +} + +// sort the arguments by their name +func (args *Arguments) Sort() { + s := *args + if len(*args) <= 1 { + return + } + sort.Slice(s, func(i, j int) bool { + return s[i].Name <= s[j].Name + }) + +} + +// some fields are already defined +const RPC_DESTINATION_PORT = "D" // mandatory,uint64, used for ID of type uint64 +const RPC_SOURCE_PORT = "S" // mandatory,uint64, used for ID +const RPC_VALUE_TRANSFER = "V" //uint64, this is representation and is only readable, value is never transferred +const RPC_COMMENT = "C" //optional,string, used for display MSG to user +const RPC_EXPIRY = "E" //optional,time used for Expiry for this service call + +type argument_raw struct { + Name string `json:"name"` // string name must be atleast 1 byte + DataType DataType `json:"datatype"` // Type must one of the known data types + Value json.RawMessage `json:"value"` // delay parsing until we know the value should be as per type +} + +func (a *Argument) UnmarshalJSON(b []byte) (err error) { + var raw argument_raw + if err = json.Unmarshal(b, &raw); err != nil { + return err + } + a.Name = raw.Name + a.DataType = raw.DataType + switch raw.DataType { + case DataString: + var x string + if err = json.Unmarshal(raw.Value, &x); err == nil { + a.Value = x + return + } + case DataInt64: + var x int64 + if err = json.Unmarshal(raw.Value, &x); err == nil { + a.Value = x + return + } + case DataUint64: + var x uint64 + if err = json.Unmarshal(raw.Value, &x); err == nil { + a.Value = x + return + } + case DataFloat64: + var x float64 + if err = json.Unmarshal(raw.Value, &x); err == nil { + a.Value = x + return + } + case DataHash: + var x crypto.Hash + if err = json.Unmarshal(raw.Value, &x); err == nil { + a.Value = x + return + } + case DataAddress: + var x Address + if err = json.Unmarshal(raw.Value, &x); err == nil { + a.Value = x + return + } + case DataTime: + var x time.Time + if err = json.Unmarshal(raw.Value, &x); err == nil { + a.Value = x + return + } + default: + return fmt.Errorf("unknown data type %s", raw.DataType) + + } + + return +} diff --git a/rpc/rpc_sc.go b/rpc/rpc_sc.go new file mode 100644 index 0000000..42ae051 --- /dev/null +++ b/rpc/rpc_sc.go @@ -0,0 +1,21 @@ +package rpc + +// definitions related to SC + +type SC_ACTION uint64 // sc actions are coded as follow +const ( + SC_CALL SC_ACTION = iota + SC_INSTALL +) + +// SC_CALL must have an arg of type SC_ENTRYPOINT of type String, SCID of type Hash +// SC_INSTALL must have an arg SC of String + +// some fields are already defined +const SCACTION = "SC_ACTION" //all SCS must have an ACTION +const SCCODE = "SC_CODE" // SCCODE must be sent in this ARGUMENT +const SCSIGNER = "SC_SIGNER" // the signer address +const SCSIGNC = "SC_SIGNC" // the sign C component +const SCSIGNS = "SC_SIGNS" // the sign S component + +const SCID = "SC_ID" // SCID diff --git a/rpc/wallet_rpc.go b/rpc/wallet_rpc.go new file mode 100644 index 0000000..4e76127 --- /dev/null +++ b/rpc/wallet_rpc.go @@ -0,0 +1,276 @@ +// Copyright 2017-2021 DERO Project. All rights reserved. +// Use of this source code in any form is governed by RESEARCH license. +// license can be found in the LICENSE file. +// GPG: 0F39 E425 8C65 3947 702A 8234 08B2 0360 A03A 9DE8 +// +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY +// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL +// THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF +// THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +// this package contains only struct definitions required to implement wallet rpc (compatible with C daemon) +// in order to avoid the dependency on block chain by any package requiring access to rpc +// and other structures +// having the structures was causing the build times of explorer/wallet to be more than couple of secs +// so separated the logic from the structures + +package rpc + +import "fmt" +import "time" +import "strings" +import "math/big" + +import "github.com/deroproject/derohe/cryptography/crypto" + +// these structures are completely decoupled from blockchain and live only within the wallet +// all inputs and outputs which modify balance are presented by this structure +type Entry struct { + Height uint64 `json:"height"` + TopoHeight int64 `json:"topoheight"` + BlockHash string `json:"blockhash"` + MinerReward uint64 `json:"minerreward"` + TransactionPos int `json:"tpos"` // pos within block is negative -1 for coinbase + Pos int `json:"pos"` // pos within transaction + Coinbase bool `json:"coinbase"` + Incoming bool `json:"incoming"` + TXID string `json:"txid"` + Destination string `json:"destination"` + Burn uint64 `json:"burn,omitempty"` + Amount uint64 `json:"amount"` + Fees uint64 `json:"fees"` + Proof string `json:"proof"` // can be used to prove if available + Status byte `json:"status"` + Time time.Time `json:"time"` + EWData string `json:"ewdata"` // encrypted wallet balance at that point in time + + Data []byte `json:"data"` // data is entire decrypted dump + + PayloadType byte `json:"payloadtype"` + Payload []byte `json:"payload"` + PayloadError string `json:"payloaderror,omitempty"` + Payload_RPC Arguments `json:"payload_rpc,omitempty"` + + // these fields are only valid based on payload type and if payload could be successfully parsed and will by default be equal to zero values + Sender string `json:"sender"` + DestinationPort uint64 `json:"dstport"` + SourcePort uint64 `json:"srcport"` +} + +// converts entry to string +func (e Entry) String() string { + var b strings.Builder + + if e.Coinbase { + fmt.Fprintf(&b, "Type: Coinbase\n") + fmt.Fprintf(&b, "Amount: %s\n", FormatMoney(e.Amount)) + } else if e.Incoming { + fmt.Fprintf(&b, "Type: Received\n") + fmt.Fprintf(&b, "Amount: %s\n", FormatMoney(e.Amount)) + fmt.Fprintf(&b, "TXID: %s\n", e.TXID) + } else { + fmt.Fprintf(&b, "Type: Sent Outgoing\n") + fmt.Fprintf(&b, "Amount: %s\n", FormatMoney(e.Amount)) + fmt.Fprintf(&b, "TXID: %s\n", e.TXID) + fmt.Fprintf(&b, "Destination: %s\n", e.Destination) + fmt.Fprintf(&b, "Proof: %s\n", e.Proof) + } + if !e.Coinbase { + fmt.Fprintf(&b, "PayloadType : %d\n", e.PayloadType) + if e.PayloadType == 0 { + fmt.Fprintf(&b, "Sender: %s\n", e.Sender) + if e.PayloadError == "" { + args, _ := e.ProcessPayload() + fmt.Fprintf(&b, "DestPort: %016x\n", e.DestinationPort) + fmt.Fprintf(&b, "SrcPort: %016x\n", e.SourcePort) + fmt.Fprintf(&b, "Arguments: %+v\n", args) + } else { + fmt.Fprintf(&b, "Raw Payload: %x\n", e.Payload[:]) + fmt.Fprintf(&b, "Payload error: %s\n", e.PayloadError) + } + } + } + fmt.Fprintf(&b, "Block: %s\n", e.BlockHash) + fmt.Fprintf(&b, "Block Height: %d\n", e.Height) + fmt.Fprintf(&b, "Block TopoHeight: %d\n", e.TopoHeight) + fmt.Fprintf(&b, "Pos within tx: %d\n", e.Pos) + fmt.Fprintf(&b, "Time: %s\n", e.Time) + + return b.String() +} + +// process and updates necessary fields in the entry +func (e *Entry) ProcessPayload() (args Arguments, err error) { + + if len(e.Payload) == 0 { + err = fmt.Errorf("zero length payload") + return + } + if err = args.UnmarshalBinary(e.Payload); err == nil { + // lets decode dest port,source port for easier services programming + if args.Has(RPC_DESTINATION_PORT, DataUint64) { // but only it is present + e.DestinationPort = args.Value(RPC_DESTINATION_PORT, DataUint64).(uint64) + } + if args.Has(RPC_SOURCE_PORT, DataUint64) { // but only it is present + e.SourcePort = args.Value(RPC_SOURCE_PORT, DataUint64).(uint64) + } + e.Payload_RPC = append([]Argument{}, args...) + } else { // err is not nil so store it + e.PayloadError = err.Error() + } + return args, err + +} + +// never do any division operation on money due to floating point issues +// newbies, see type the next in python interpretor "3.33-3.13" +// +func FormatMoney(amount uint64) string { + return FormatMoneyPrecision(amount, 5) // default is 5 precision after floating point +} + +// 0 +func FormatMoney0(amount uint64) string { + return FormatMoneyPrecision(amount, 0) +} + +//5 precision +func FormatMoney5(amount uint64) string { + return FormatMoneyPrecision(amount, 5) +} + +//8 precision +func FormatMoney8(amount uint64) string { + return FormatMoneyPrecision(amount, 8) +} + +// 12 precision +func FormatMoney12(amount uint64) string { + return FormatMoneyPrecision(amount, 12) // default is 8 precision after floating point +} + +// format money with specific precision +func FormatMoneyPrecision(amount uint64, precision int) string { + hard_coded_decimals := new(big.Float).SetInt64(100000) + float_amount, _, _ := big.ParseFloat(fmt.Sprintf("%d", amount), 10, 0, big.ToZero) + result := new(big.Float) + result.Quo(float_amount, hard_coded_decimals) + return result.Text('f', precision) // 5 is display precision after floating point +} + +type ( + GetBalance_Params struct{} // no params + GetBalance_Result struct { + Balance uint64 `json:"balance"` + Unlocked_Balance uint64 `json:"unlocked_balance"` + } +) + +type ( + GetAddress_Params struct{} // no params + GetAddress_Result struct { + Address string `json:"address"` + } +) + +type ( + GetHeight_Params struct{} // no params + GetHeight_Result struct { + Height uint64 `json:"height"` + } +) + +// return type is string +type ( + Transfer struct { + SCID crypto.Hash `json:"scid"` + Destination string `json:"destination"` + Amount uint64 `json:"amount"` + Burn uint64 `json:"burn"` + Payload_RPC Arguments `json:"payload_rpc"` + } + + Transfer_Params struct { + Transfers []Transfer `json:"transfers"` + SC_Code string `json:"sc"` + SC_Value uint64 `json:"sc_value"` + SC_ID string `json:"scid"` + SC_RPC Arguments `json:"sc_rpc"` + } +) + +type ( + Get_Transfers_Params struct { + Coinbase bool `json:"coinbase"` + In bool `json:"in"` + Out bool `json:"out"` + Min_Height uint64 `json:"min_height"` + Max_Height uint64 `json:"max_height"` + Sender string `json:"sender"` + Receiver string `json:"receiver"` + DestinationPort uint64 `json:"dstport"` + SourcePort uint64 `json:"srcport"` + } + Get_Transfers_Result struct { + Entries []Entry `json:"entries,omitempty"` + } +) + +// Get_Bulk_Payments +type ( + Get_Bulk_Payments_Params struct { + Payment_IDs []string `json:"payment_ids"` + Min_block_height uint64 `json:"min_block_height"` + } + Get_Bulk_Payments_Result struct { + } +) + +// query_key +type ( + Query_Key_Params struct { + Key_type string `json:"key_type"` + } + Query_Key_Result struct { + Key string `json:"key"` + } +) + +// make_integrated_address_handler +type ( + Make_Integrated_Address_Params struct { + Address string `json:"address"` // if its empty we assume wallets address + Payload_RPC Arguments `json:"payload_rpc"` + } + Make_Integrated_Address_Result struct { + Integrated_Address string `json:"integrated_address"` + Payload_RPC Arguments `json:"payload_rpc"` + } +) + +// split_integrated_address_handler +type ( + Split_Integrated_Address_Params struct { + Integrated_Address string `json:"integrated_address"` + } + Split_Integrated_Address_Result struct { + Address string `json:"address"` + Payload_RPC Arguments `json:"payload_rpc"` + } +) + +// Get_Transfer_By_TXID +type ( + Get_Transfer_By_TXID_Params struct { + TXID string `json:"txid"` + } + Get_Transfer_By_TXID_Result struct { + Entry Entry `json:"entry,omitempty"` + } +) diff --git a/transaction/transaction.go b/transaction/transaction.go index d4bbea5..a685771 100644 --- a/transaction/transaction.go +++ b/transaction/transaction.go @@ -21,10 +21,11 @@ import "bytes" import "math/big" import "encoding/binary" -//import "github.com/romana/rlog" +import "github.com/romana/rlog" -import "github.com/deroproject/derohe/crypto" -import "github.com/deroproject/derohe/crypto/bn256" +import "github.com/deroproject/derohe/cryptography/crypto" +import "github.com/deroproject/derohe/cryptography/bn256" +import "github.com/deroproject/derohe/rpc" type TransactionType uint64 @@ -34,7 +35,6 @@ const ( COINBASE // normal coinbase tx ( if miner address is already registered) NORMAL // one to one TX with ring members BURN_TX // if user burns an amount to control inflation - MULTIUSER_TX // multi-user transaction SC_TX // smart contract transaction ) @@ -51,33 +51,126 @@ func (t TransactionType) String() string { return "NORMAL" case BURN_TX: return "BURN" - case MULTIUSER_TX: - return "MULTIUSER_TX" case SC_TX: - return "SMARTCONTRACT_TX" + return "SC" default: return "unknown transaction type" } } +const PAYLOAD_LIMIT = 1 + 144 // entire payload header is mandatorily encrypted +// sender position in ring representation in a byte, uptp 256 ring +// 144 byte payload ( to implement specific functionality such as delivery of keys etc), user dependent encryption +const PAYLOAD0_LIMIT = 144 // 1 byte has been reserved for sender position in ring representation in a byte, uptp 256 ring + +const ENCRYPTED_DEFAULT_PAYLOAD_CBOR = byte(0) + // the core transaction +// in our design, tx cam be sent by 1 wallet, but SC part/gas can be signed by any other user, but this is not implemented type Transaction_Prefix struct { Version uint64 `json:"version"` TransactionType TransactionType `json:"version"` - Value uint64 `json:"value"` // represnets premine, value for SC, BURN amount - Amounts []uint64 // open amounts for multi user tx + Value uint64 `json:"value"` // represents value for premine, SC, BURN transactions MinerAddress [33]byte `json:"miner_address"` // miner address // 33 bytes also used for registration C [32]byte `json:"c"` // used for registration S [32]byte `json:"s"` // used for registration Height uint64 `json:"height"` // height at the state, used to cross-check state - PaymentID [8]byte `json:"paymentid"` // hardcoded 8 bytes + SCDATA rpc.Arguments `json:"scdata"` // all SC related data is provided here, an SC tx uses all the fields +} + +type AssetPayload struct { + SCID crypto.Hash // which asset, it's zero for main asset + BurnValue uint64 `json:"value"` // represents value for premine, SC, BURN transactions + + RPCType byte // its unencrypted and is by default 0 for almost all txs + RPCPayload []byte // rpc payload encryption depends on RPCType + + // sender position in ring representation in a byte, uptp 256 ring + // 144 byte payload ( to implement specific functionality such as delivery of keys etc), user dependent encryption + Statement crypto.Statement // note statement containts fees + Proof *crypto.Proof +} + +// marshal asset +/* +func (a AssetPayload) MarshalHeader() ([]byte, error) { + + return writer.Bytes(), nil +} +*/ + +func (a AssetPayload) MarshalHeaderStatement() ([]byte, error) { + var writer bytes.Buffer + var buffer_backing [binary.MaxVarintLen64]byte + buf := buffer_backing[:] + _ = buf + + n := binary.PutUvarint(buf, a.BurnValue) + writer.Write(buf[:n]) + + writer.Write(a.SCID[:]) + + writer.WriteByte(a.RPCType) // payload type byte + writer.Write(a.RPCPayload) // src Id is always payload limit bytes + + if len(a.RPCPayload) != PAYLOAD_LIMIT { + return nil, fmt.Errorf("RPCPayload should be %d bytes, but have %d bytes", PAYLOAD_LIMIT, len(a.RPCPayload)) + } + + a.Statement.Serialize(&writer) + //if err != nil { + // return nil,err + //} + + return writer.Bytes(), nil +} + +func (a *AssetPayload) UnmarshalHeaderStatement(r *bytes.Reader) (err error) { + if a.BurnValue, err = binary.ReadUvarint(r); err != nil { + return err + } + if _, err = r.Read(a.SCID[:]); err != nil { + return err + } + if a.RPCType, err = r.ReadByte(); err != nil { + return err + } + + a.RPCPayload = make([]byte, PAYLOAD_LIMIT, PAYLOAD_LIMIT) + if _, err = r.Read(a.RPCPayload[:]); err != nil { + return err + } + + if err = a.Statement.Deserialize(r); err != nil { + return err + } + + return nil +} + +func (a AssetPayload) MarshalProofs() ([]byte, error) { + var writer bytes.Buffer + a.Proof.Serialize(&writer) + + return writer.Bytes(), nil +} + +func (a *AssetPayload) UnmarshalProofs(r *bytes.Reader) (err error) { + a.Proof = &crypto.Proof{} + + if err = a.Proof.Deserialize(r, crypto.GetPowerof2(len(a.Statement.Publickeylist_pointers)/int(a.Statement.Bytes_per_publickey))); err != nil { + return err + } + + return nil + } type Transaction struct { Transaction_Prefix // same as Transaction_Prefix - Statement crypto.Statement - Proof *crypto.Proof + + Payloads []AssetPayload // each transaction can have a number os payloads } // this excludes the proof part, so it can pruned @@ -89,7 +182,6 @@ func (tx *Transaction) GetHash() (result crypto.Hash) { panic("Transaction version unknown") } - return } @@ -106,6 +198,16 @@ func (tx *Transaction) IsPremine() (result bool) { return tx.TransactionType == PREMINE } +func (tx *Transaction) Fees() (fees uint64) { + var zero_scid [32]byte + for i := range tx.Payloads { + if zero_scid == tx.Payloads[i].SCID { + fees += tx.Payloads[i].Statement.Fees + } + } + return fees +} + func (tx *Transaction) IsRegistrationValid() (result bool) { var u bn256.G1 @@ -152,24 +254,27 @@ func (tx *Transaction) DeserializeHeader(buf []byte) (err error) { tx.TransactionType = TransactionType(tmp_uint64) switch tx.TransactionType { - case PREMINE: + case PREMINE, REGISTRATION, COINBASE, BURN_TX, NORMAL, SC_TX: + default: + panic("unknown transaction type") + } + + if tx.TransactionType == PREMINE || tx.TransactionType == BURN_TX || tx.TransactionType == SC_TX { tx.Value, done = binary.Uvarint(buf) if done <= 0 { return fmt.Errorf("Invalid Premine value in Transaction\n") } buf = buf[done:] + } + + if tx.TransactionType == PREMINE || tx.TransactionType == COINBASE || tx.TransactionType == REGISTRATION || tx.TransactionType == SC_TX { if 33 != copy(tx.MinerAddress[:], buf[:]) { return fmt.Errorf("Invalid Miner Address in Transaction\n") } buf = buf[33:] - goto done - - case REGISTRATION: - if 33 != copy(tx.MinerAddress[:], buf[:33]) { - return fmt.Errorf("Invalid Miner Address in Transaction\n") - } - buf = buf[33:] + } + if tx.TransactionType == REGISTRATION || tx.TransactionType == SC_TX { if 32 != copy(tx.C[:], buf[:32]) { return fmt.Errorf("Invalid C in Transaction\n") } @@ -179,68 +284,67 @@ func (tx *Transaction) DeserializeHeader(buf []byte) (err error) { return fmt.Errorf("Invalid S in Transaction\n") } buf = buf[32:] + } - goto done - - case COINBASE: - if 33 != copy(tx.MinerAddress[:], buf[:]) { - return fmt.Errorf("Invalid Miner Address in Transaction\n") - } - buf = buf[33:] - goto done - - case NORMAL: // parse height and root hash + if tx.TransactionType == BURN_TX || tx.TransactionType == NORMAL || tx.TransactionType == SC_TX { + // parse height and root hash tx.Height, done = binary.Uvarint(buf) if done <= 0 { return fmt.Errorf("Invalid Height value in Transaction\n") } buf = buf[done:] - if len(buf) < 8 { - return fmt.Errorf("Invalid payment id value in Transaction\n") + var asset_count uint64 + asset_count, done = binary.Uvarint(buf) + if done <= 0 || asset_count < 1 { + return fmt.Errorf("Invalid asset_count in Transaction\n") } - copy(tx.PaymentID[:], buf[:8]) - buf = buf[8:] + buf = buf[done:] - tx.Proof = &crypto.Proof{} + for i := uint64(0); i < asset_count; i++ { + var a AssetPayload - r = bytes.NewReader(buf[:]) - - tx.Statement.Deserialize(r) - - statement_size := len(buf) - r.Len() - // fmt.Printf("tx Statement size deserialing %d\n", statement_size) - - // fmt.Printf("tx Proof size %d\n", len(buf) - statement_size) - - buf = buf[statement_size:] - r = bytes.NewReader(buf[:]) - - if err := tx.Proof.Deserialize(r, crypto.GetPowerof2(len(tx.Statement.Publickeylist_compressed))); err != nil { - fmt.Printf("error deserialing proof err %s", err) - return err + r = bytes.NewReader(buf[:]) + if err = a.UnmarshalHeaderStatement(r); err != nil { + panic(err) + } + tx.Payloads = append(tx.Payloads, a) + buf = buf[len(buf)-r.Len():] } - // fmt.Printf("tx Proof size deserialed %d bytes remaining %d \n", len(buf) - r.Len(), r.Len()) - - if r.Len() != 0 { - return fmt.Errorf("Extra unknown data in Transaction, extrabytes %d\n", r.Len()) - } - - case BURN_TX: - panic("TODO") - case MULTIUSER_TX: - panic("TODO") - case SC_TX: - panic("TODO") - - default: - panic("unknown transaction type") } -done: - if len(buf) != 0 { - //return fmt.Errorf("Extra unknown data in Transaction\n") + if tx.TransactionType == SC_TX { + var sc_len uint64 + sc_len, done = binary.Uvarint(buf) + if done <= 0 { + return fmt.Errorf("Invalid sc length in Transaction\n") + } + buf = buf[done:] + if sc_len > uint64(len(buf)) { // we are are crossing tx_boundary + return fmt.Errorf("SC len out of possible range") + } + if err := tx.SCDATA.UnmarshalBinary(buf[:sc_len]); err != nil { + return err + } + buf = buf[sc_len:] + } + + if tx.TransactionType == BURN_TX || tx.TransactionType == NORMAL || tx.TransactionType == SC_TX { + + for i := range tx.Payloads { + tx.Payloads[i].Proof = &crypto.Proof{} + + r = bytes.NewReader(buf[:]) + if err = tx.Payloads[i].UnmarshalProofs(r); err != nil { + panic(err) + } + buf = buf[len(buf)-r.Len():] + } + } + + if len(buf) != 0 && (tx.TransactionType == PREMINE || tx.TransactionType == REGISTRATION || tx.TransactionType == COINBASE) { // these tx are complete + //return fmt.Errorf("Extra unknown data in Transaction, extrabytes %d\n", r.Len()) } //rlog.Tracef(8, "TX deserialized %+v\n", tx) @@ -265,41 +369,53 @@ func (tx *Transaction) SerializeHeader() []byte { n := binary.PutUvarint(buf, tx.Version) serialised_header.Write(buf[:n]) + switch tx.TransactionType { + case PREMINE, REGISTRATION, COINBASE, BURN_TX, NORMAL, SC_TX: + default: + panic("unknown transaction type") + } + n = binary.PutUvarint(buf, uint64(tx.TransactionType)) serialised_header.Write(buf[:n]) - switch tx.TransactionType { - case PREMINE: + if tx.TransactionType == PREMINE || tx.TransactionType == BURN_TX || tx.TransactionType == SC_TX { n := binary.PutUvarint(buf, tx.Value) serialised_header.Write(buf[:n]) + } + if tx.TransactionType == PREMINE || tx.TransactionType == COINBASE || tx.TransactionType == REGISTRATION || tx.TransactionType == SC_TX { serialised_header.Write(tx.MinerAddress[:]) - return serialised_header.Bytes() - - case REGISTRATION: - serialised_header.Write(tx.MinerAddress[:]) + } + if tx.TransactionType == REGISTRATION || tx.TransactionType == SC_TX { serialised_header.Write(tx.C[:]) serialised_header.Write(tx.S[:]) - return serialised_header.Bytes() + } - case COINBASE: - serialised_header.Write(tx.MinerAddress[:]) - return serialised_header.Bytes() - - case NORMAL: + if tx.TransactionType == BURN_TX || tx.TransactionType == NORMAL || tx.TransactionType == SC_TX { n = binary.PutUvarint(buf, uint64(tx.Height)) serialised_header.Write(buf[:n]) - serialised_header.Write(tx.PaymentID[:8]) // payment Id is always 8 bytes - return serialised_header.Bytes() - case BURN_TX: - panic("TODO") - case MULTIUSER_TX: - panic("TODO") - case SC_TX: - panic("TODO") + n = binary.PutUvarint(buf, uint64(len(tx.Payloads))) + serialised_header.Write(buf[:n]) - default: - panic("unknown transaction type") + for _, p := range tx.Payloads { + if pheader_bytes, err := p.MarshalHeaderStatement(); err == nil { + serialised_header.Write(pheader_bytes) + } else { + panic(err) + } + } + + } + + if tx.TransactionType == SC_TX { + if data, err := tx.SCDATA.MarshalBinary(); err != nil { + rlog.Warnf("err marshalling SC data %s\n", err) + panic(err) + } else { + n = binary.PutUvarint(buf, uint64(len(data))) + serialised_header.Write(buf[:n]) + serialised_header.Write(data) + } } return serialised_header.Bytes() @@ -307,27 +423,16 @@ func (tx *Transaction) SerializeHeader() []byte { // serialize entire transaction include signature func (tx *Transaction) Serialize() []byte { - var serialised bytes.Buffer - header_bytes := tx.SerializeHeader() - //base_bytes := tx.RctSignature.SerializeBase() - //prunable := tx.RctSignature.SerializePrunable() serialised.Write(header_bytes) - if tx.Proof != nil { - - // done_bytes := serialised.Len() - - tx.Statement.Serialize(&serialised) - // statement_size := serialised.Len() - done_bytes - // fmt.Printf("tx statement_size serializing %d\n", statement_size) - - //done_bytes =serialised.Len() - tx.Proof.Serialize(&serialised) - - // fmt.Printf("tx Proof serialised size %d\n", serialised.Len() - done_bytes) + for _, p := range tx.Payloads { + if pheader_bytes, err := p.MarshalProofs(); err == nil { + serialised.Write(pheader_bytes) + } else { + panic(err) + } } - return serialised.Bytes() //buf } @@ -339,10 +444,9 @@ func (tx *Transaction) SerializeCoreStatement() []byte { serialised.Write(header_bytes) switch tx.TransactionType { - case PREMINE, REGISTRATION, COINBASE: - case NORMAL, BURN_TX, MULTIUSER_TX, SC_TX: - tx.Statement.Serialize(&serialised) - + case PREMINE, COINBASE: + case REGISTRATION: + case NORMAL, BURN_TX, SC_TX: default: panic("unknown transaction type") } diff --git a/vendor/etcd.io/bbolt/.gitignore b/vendor/etcd.io/bbolt/.gitignore new file mode 100644 index 0000000..3bcd8cb --- /dev/null +++ b/vendor/etcd.io/bbolt/.gitignore @@ -0,0 +1,5 @@ +*.prof +*.test +*.swp +/bin/ +cover.out diff --git a/vendor/etcd.io/bbolt/.travis.yml b/vendor/etcd.io/bbolt/.travis.yml new file mode 100644 index 0000000..257dfdf --- /dev/null +++ b/vendor/etcd.io/bbolt/.travis.yml @@ -0,0 +1,17 @@ +language: go +go_import_path: go.etcd.io/bbolt + +sudo: false + +go: +- 1.12 + +before_install: +- go get -v honnef.co/go/tools/... +- go get -v github.com/kisielk/errcheck + +script: +- make fmt +- make test +- make race +# - make errcheck diff --git a/vendor/github.com/alecthomas/jsonschema/COPYING b/vendor/etcd.io/bbolt/LICENSE similarity index 52% rename from vendor/github.com/alecthomas/jsonschema/COPYING rename to vendor/etcd.io/bbolt/LICENSE index 2993ec0..004e77f 100644 --- a/vendor/github.com/alecthomas/jsonschema/COPYING +++ b/vendor/etcd.io/bbolt/LICENSE @@ -1,19 +1,20 @@ -Copyright (C) 2014 Alec Thomas +The MIT License (MIT) + +Copyright (c) 2013 Ben Johnson Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/vendor/etcd.io/bbolt/Makefile b/vendor/etcd.io/bbolt/Makefile new file mode 100644 index 0000000..2968aaa --- /dev/null +++ b/vendor/etcd.io/bbolt/Makefile @@ -0,0 +1,38 @@ +BRANCH=`git rev-parse --abbrev-ref HEAD` +COMMIT=`git rev-parse --short HEAD` +GOLDFLAGS="-X main.branch $(BRANCH) -X main.commit $(COMMIT)" + +default: build + +race: + @TEST_FREELIST_TYPE=hashmap go test -v -race -test.run="TestSimulate_(100op|1000op)" + @echo "array freelist test" + @TEST_FREELIST_TYPE=array go test -v -race -test.run="TestSimulate_(100op|1000op)" + +fmt: + !(gofmt -l -s -d $(shell find . -name \*.go) | grep '[a-z]') + +# go get honnef.co/go/tools/simple +gosimple: + gosimple ./... + +# go get honnef.co/go/tools/unused +unused: + unused ./... + +# go get github.com/kisielk/errcheck +errcheck: + @errcheck -ignorepkg=bytes -ignore=os:Remove go.etcd.io/bbolt + +test: + TEST_FREELIST_TYPE=hashmap go test -timeout 20m -v -coverprofile cover.out -covermode atomic + # Note: gets "program not an importable package" in out of path builds + TEST_FREELIST_TYPE=hashmap go test -v ./cmd/bbolt + + @echo "array freelist test" + + @TEST_FREELIST_TYPE=array go test -timeout 20m -v -coverprofile cover.out -covermode atomic + # Note: gets "program not an importable package" in out of path builds + @TEST_FREELIST_TYPE=array go test -v ./cmd/bbolt + +.PHONY: race fmt errcheck test gosimple unused diff --git a/vendor/etcd.io/bbolt/README.md b/vendor/etcd.io/bbolt/README.md new file mode 100644 index 0000000..6b5ed3c --- /dev/null +++ b/vendor/etcd.io/bbolt/README.md @@ -0,0 +1,958 @@ +bbolt +===== + +[![Go Report Card](https://goreportcard.com/badge/github.com/etcd-io/bbolt?style=flat-square)](https://goreportcard.com/report/github.com/etcd-io/bbolt) +[![Coverage](https://codecov.io/gh/etcd-io/bbolt/branch/master/graph/badge.svg)](https://codecov.io/gh/etcd-io/bbolt) +[![Build Status Travis](https://img.shields.io/travis/etcd-io/bboltlabs.svg?style=flat-square&&branch=master)](https://travis-ci.com/etcd-io/bbolt) +[![Godoc](http://img.shields.io/badge/go-documentation-blue.svg?style=flat-square)](https://godoc.org/github.com/etcd-io/bbolt) +[![Releases](https://img.shields.io/github/release/etcd-io/bbolt/all.svg?style=flat-square)](https://github.com/etcd-io/bbolt/releases) +[![LICENSE](https://img.shields.io/github/license/etcd-io/bbolt.svg?style=flat-square)](https://github.com/etcd-io/bbolt/blob/master/LICENSE) + +bbolt is a fork of [Ben Johnson's][gh_ben] [Bolt][bolt] key/value +store. The purpose of this fork is to provide the Go community with an active +maintenance and development target for Bolt; the goal is improved reliability +and stability. bbolt includes bug fixes, performance enhancements, and features +not found in Bolt while preserving backwards compatibility with the Bolt API. + +Bolt is a pure Go key/value store inspired by [Howard Chu's][hyc_symas] +[LMDB project][lmdb]. The goal of the project is to provide a simple, +fast, and reliable database for projects that don't require a full database +server such as Postgres or MySQL. + +Since Bolt is meant to be used as such a low-level piece of functionality, +simplicity is key. The API will be small and only focus on getting values +and setting values. That's it. + +[gh_ben]: https://github.com/benbjohnson +[bolt]: https://github.com/boltdb/bolt +[hyc_symas]: https://twitter.com/hyc_symas +[lmdb]: http://symas.com/mdb/ + +## Project Status + +Bolt is stable, the API is fixed, and the file format is fixed. Full unit +test coverage and randomized black box testing are used to ensure database +consistency and thread safety. Bolt is currently used in high-load production +environments serving databases as large as 1TB. Many companies such as +Shopify and Heroku use Bolt-backed services every day. + +## Project versioning + +bbolt uses [semantic versioning](http://semver.org). +API should not change between patch and minor releases. +New minor versions may add additional features to the API. + +## Table of Contents + + - [Getting Started](#getting-started) + - [Installing](#installing) + - [Opening a database](#opening-a-database) + - [Transactions](#transactions) + - [Read-write transactions](#read-write-transactions) + - [Read-only transactions](#read-only-transactions) + - [Batch read-write transactions](#batch-read-write-transactions) + - [Managing transactions manually](#managing-transactions-manually) + - [Using buckets](#using-buckets) + - [Using key/value pairs](#using-keyvalue-pairs) + - [Autoincrementing integer for the bucket](#autoincrementing-integer-for-the-bucket) + - [Iterating over keys](#iterating-over-keys) + - [Prefix scans](#prefix-scans) + - [Range scans](#range-scans) + - [ForEach()](#foreach) + - [Nested buckets](#nested-buckets) + - [Database backups](#database-backups) + - [Statistics](#statistics) + - [Read-Only Mode](#read-only-mode) + - [Mobile Use (iOS/Android)](#mobile-use-iosandroid) + - [Resources](#resources) + - [Comparison with other databases](#comparison-with-other-databases) + - [Postgres, MySQL, & other relational databases](#postgres-mysql--other-relational-databases) + - [LevelDB, RocksDB](#leveldb-rocksdb) + - [LMDB](#lmdb) + - [Caveats & Limitations](#caveats--limitations) + - [Reading the Source](#reading-the-source) + - [Other Projects Using Bolt](#other-projects-using-bolt) + +## Getting Started + +### Installing + +To start using Bolt, install Go and run `go get`: + +```sh +$ go get go.etcd.io/bbolt/... +``` + +This will retrieve the library and install the `bolt` command line utility into +your `$GOBIN` path. + + +### Importing bbolt + +To use bbolt as an embedded key-value store, import as: + +```go +import bolt "go.etcd.io/bbolt" + +db, err := bolt.Open(path, 0666, nil) +if err != nil { + return err +} +defer db.Close() +``` + + +### Opening a database + +The top-level object in Bolt is a `DB`. It is represented as a single file on +your disk and represents a consistent snapshot of your data. + +To open your database, simply use the `bolt.Open()` function: + +```go +package main + +import ( + "log" + + bolt "go.etcd.io/bbolt" +) + +func main() { + // Open the my.db data file in your current directory. + // It will be created if it doesn't exist. + db, err := bolt.Open("my.db", 0600, nil) + if err != nil { + log.Fatal(err) + } + defer db.Close() + + ... +} +``` + +Please note that Bolt obtains a file lock on the data file so multiple processes +cannot open the same database at the same time. Opening an already open Bolt +database will cause it to hang until the other process closes it. To prevent +an indefinite wait you can pass a timeout option to the `Open()` function: + +```go +db, err := bolt.Open("my.db", 0600, &bolt.Options{Timeout: 1 * time.Second}) +``` + + +### Transactions + +Bolt allows only one read-write transaction at a time but allows as many +read-only transactions as you want at a time. Each transaction has a consistent +view of the data as it existed when the transaction started. + +Individual transactions and all objects created from them (e.g. buckets, keys) +are not thread safe. To work with data in multiple goroutines you must start +a transaction for each one or use locking to ensure only one goroutine accesses +a transaction at a time. Creating transaction from the `DB` is thread safe. + +Transactions should not depend on one another and generally shouldn't be opened +simultaneously in the same goroutine. This can cause a deadlock as the read-write +transaction needs to periodically re-map the data file but it cannot do so while +any read-only transaction is open. Even a nested read-only transaction can cause +a deadlock, as the child transaction can block the parent transaction from releasing +its resources. + +#### Read-write transactions + +To start a read-write transaction, you can use the `DB.Update()` function: + +```go +err := db.Update(func(tx *bolt.Tx) error { + ... + return nil +}) +``` + +Inside the closure, you have a consistent view of the database. You commit the +transaction by returning `nil` at the end. You can also rollback the transaction +at any point by returning an error. All database operations are allowed inside +a read-write transaction. + +Always check the return error as it will report any disk failures that can cause +your transaction to not complete. If you return an error within your closure +it will be passed through. + + +#### Read-only transactions + +To start a read-only transaction, you can use the `DB.View()` function: + +```go +err := db.View(func(tx *bolt.Tx) error { + ... + return nil +}) +``` + +You also get a consistent view of the database within this closure, however, +no mutating operations are allowed within a read-only transaction. You can only +retrieve buckets, retrieve values, and copy the database within a read-only +transaction. + + +#### Batch read-write transactions + +Each `DB.Update()` waits for disk to commit the writes. This overhead +can be minimized by combining multiple updates with the `DB.Batch()` +function: + +```go +err := db.Batch(func(tx *bolt.Tx) error { + ... + return nil +}) +``` + +Concurrent Batch calls are opportunistically combined into larger +transactions. Batch is only useful when there are multiple goroutines +calling it. + +The trade-off is that `Batch` can call the given +function multiple times, if parts of the transaction fail. The +function must be idempotent and side effects must take effect only +after a successful return from `DB.Batch()`. + +For example: don't display messages from inside the function, instead +set variables in the enclosing scope: + +```go +var id uint64 +err := db.Batch(func(tx *bolt.Tx) error { + // Find last key in bucket, decode as bigendian uint64, increment + // by one, encode back to []byte, and add new key. + ... + id = newValue + return nil +}) +if err != nil { + return ... +} +fmt.Println("Allocated ID %d", id) +``` + + +#### Managing transactions manually + +The `DB.View()` and `DB.Update()` functions are wrappers around the `DB.Begin()` +function. These helper functions will start the transaction, execute a function, +and then safely close your transaction if an error is returned. This is the +recommended way to use Bolt transactions. + +However, sometimes you may want to manually start and end your transactions. +You can use the `DB.Begin()` function directly but **please** be sure to close +the transaction. + +```go +// Start a writable transaction. +tx, err := db.Begin(true) +if err != nil { + return err +} +defer tx.Rollback() + +// Use the transaction... +_, err := tx.CreateBucket([]byte("MyBucket")) +if err != nil { + return err +} + +// Commit the transaction and check for error. +if err := tx.Commit(); err != nil { + return err +} +``` + +The first argument to `DB.Begin()` is a boolean stating if the transaction +should be writable. + + +### Using buckets + +Buckets are collections of key/value pairs within the database. All keys in a +bucket must be unique. You can create a bucket using the `Tx.CreateBucket()` +function: + +```go +db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("MyBucket")) + if err != nil { + return fmt.Errorf("create bucket: %s", err) + } + return nil +}) +``` + +You can also create a bucket only if it doesn't exist by using the +`Tx.CreateBucketIfNotExists()` function. It's a common pattern to call this +function for all your top-level buckets after you open your database so you can +guarantee that they exist for future transactions. + +To delete a bucket, simply call the `Tx.DeleteBucket()` function. + + +### Using key/value pairs + +To save a key/value pair to a bucket, use the `Bucket.Put()` function: + +```go +db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("MyBucket")) + err := b.Put([]byte("answer"), []byte("42")) + return err +}) +``` + +This will set the value of the `"answer"` key to `"42"` in the `MyBucket` +bucket. To retrieve this value, we can use the `Bucket.Get()` function: + +```go +db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("MyBucket")) + v := b.Get([]byte("answer")) + fmt.Printf("The answer is: %s\n", v) + return nil +}) +``` + +The `Get()` function does not return an error because its operation is +guaranteed to work (unless there is some kind of system failure). If the key +exists then it will return its byte slice value. If it doesn't exist then it +will return `nil`. It's important to note that you can have a zero-length value +set to a key which is different than the key not existing. + +Use the `Bucket.Delete()` function to delete a key from the bucket. + +Please note that values returned from `Get()` are only valid while the +transaction is open. If you need to use a value outside of the transaction +then you must use `copy()` to copy it to another byte slice. + + +### Autoincrementing integer for the bucket +By using the `NextSequence()` function, you can let Bolt determine a sequence +which can be used as the unique identifier for your key/value pairs. See the +example below. + +```go +// CreateUser saves u to the store. The new user ID is set on u once the data is persisted. +func (s *Store) CreateUser(u *User) error { + return s.db.Update(func(tx *bolt.Tx) error { + // Retrieve the users bucket. + // This should be created when the DB is first opened. + b := tx.Bucket([]byte("users")) + + // Generate ID for the user. + // This returns an error only if the Tx is closed or not writeable. + // That can't happen in an Update() call so I ignore the error check. + id, _ := b.NextSequence() + u.ID = int(id) + + // Marshal user data into bytes. + buf, err := json.Marshal(u) + if err != nil { + return err + } + + // Persist bytes to users bucket. + return b.Put(itob(u.ID), buf) + }) +} + +// itob returns an 8-byte big endian representation of v. +func itob(v int) []byte { + b := make([]byte, 8) + binary.BigEndian.PutUint64(b, uint64(v)) + return b +} + +type User struct { + ID int + ... +} +``` + +### Iterating over keys + +Bolt stores its keys in byte-sorted order within a bucket. This makes sequential +iteration over these keys extremely fast. To iterate over keys we'll use a +`Cursor`: + +```go +db.View(func(tx *bolt.Tx) error { + // Assume bucket exists and has keys + b := tx.Bucket([]byte("MyBucket")) + + c := b.Cursor() + + for k, v := c.First(); k != nil; k, v = c.Next() { + fmt.Printf("key=%s, value=%s\n", k, v) + } + + return nil +}) +``` + +The cursor allows you to move to a specific point in the list of keys and move +forward or backward through the keys one at a time. + +The following functions are available on the cursor: + +``` +First() Move to the first key. +Last() Move to the last key. +Seek() Move to a specific key. +Next() Move to the next key. +Prev() Move to the previous key. +``` + +Each of those functions has a return signature of `(key []byte, value []byte)`. +When you have iterated to the end of the cursor then `Next()` will return a +`nil` key. You must seek to a position using `First()`, `Last()`, or `Seek()` +before calling `Next()` or `Prev()`. If you do not seek to a position then +these functions will return a `nil` key. + +During iteration, if the key is non-`nil` but the value is `nil`, that means +the key refers to a bucket rather than a value. Use `Bucket.Bucket()` to +access the sub-bucket. + + +#### Prefix scans + +To iterate over a key prefix, you can combine `Seek()` and `bytes.HasPrefix()`: + +```go +db.View(func(tx *bolt.Tx) error { + // Assume bucket exists and has keys + c := tx.Bucket([]byte("MyBucket")).Cursor() + + prefix := []byte("1234") + for k, v := c.Seek(prefix); k != nil && bytes.HasPrefix(k, prefix); k, v = c.Next() { + fmt.Printf("key=%s, value=%s\n", k, v) + } + + return nil +}) +``` + +#### Range scans + +Another common use case is scanning over a range such as a time range. If you +use a sortable time encoding such as RFC3339 then you can query a specific +date range like this: + +```go +db.View(func(tx *bolt.Tx) error { + // Assume our events bucket exists and has RFC3339 encoded time keys. + c := tx.Bucket([]byte("Events")).Cursor() + + // Our time range spans the 90's decade. + min := []byte("1990-01-01T00:00:00Z") + max := []byte("2000-01-01T00:00:00Z") + + // Iterate over the 90's. + for k, v := c.Seek(min); k != nil && bytes.Compare(k, max) <= 0; k, v = c.Next() { + fmt.Printf("%s: %s\n", k, v) + } + + return nil +}) +``` + +Note that, while RFC3339 is sortable, the Golang implementation of RFC3339Nano does not use a fixed number of digits after the decimal point and is therefore not sortable. + + +#### ForEach() + +You can also use the function `ForEach()` if you know you'll be iterating over +all the keys in a bucket: + +```go +db.View(func(tx *bolt.Tx) error { + // Assume bucket exists and has keys + b := tx.Bucket([]byte("MyBucket")) + + b.ForEach(func(k, v []byte) error { + fmt.Printf("key=%s, value=%s\n", k, v) + return nil + }) + return nil +}) +``` + +Please note that keys and values in `ForEach()` are only valid while +the transaction is open. If you need to use a key or value outside of +the transaction, you must use `copy()` to copy it to another byte +slice. + +### Nested buckets + +You can also store a bucket in a key to create nested buckets. The API is the +same as the bucket management API on the `DB` object: + +```go +func (*Bucket) CreateBucket(key []byte) (*Bucket, error) +func (*Bucket) CreateBucketIfNotExists(key []byte) (*Bucket, error) +func (*Bucket) DeleteBucket(key []byte) error +``` + +Say you had a multi-tenant application where the root level bucket was the account bucket. Inside of this bucket was a sequence of accounts which themselves are buckets. And inside the sequence bucket you could have many buckets pertaining to the Account itself (Users, Notes, etc) isolating the information into logical groupings. + +```go + +// createUser creates a new user in the given account. +func createUser(accountID int, u *User) error { + // Start the transaction. + tx, err := db.Begin(true) + if err != nil { + return err + } + defer tx.Rollback() + + // Retrieve the root bucket for the account. + // Assume this has already been created when the account was set up. + root := tx.Bucket([]byte(strconv.FormatUint(accountID, 10))) + + // Setup the users bucket. + bkt, err := root.CreateBucketIfNotExists([]byte("USERS")) + if err != nil { + return err + } + + // Generate an ID for the new user. + userID, err := bkt.NextSequence() + if err != nil { + return err + } + u.ID = userID + + // Marshal and save the encoded user. + if buf, err := json.Marshal(u); err != nil { + return err + } else if err := bkt.Put([]byte(strconv.FormatUint(u.ID, 10)), buf); err != nil { + return err + } + + // Commit the transaction. + if err := tx.Commit(); err != nil { + return err + } + + return nil +} + +``` + + + + +### Database backups + +Bolt is a single file so it's easy to backup. You can use the `Tx.WriteTo()` +function to write a consistent view of the database to a writer. If you call +this from a read-only transaction, it will perform a hot backup and not block +your other database reads and writes. + +By default, it will use a regular file handle which will utilize the operating +system's page cache. See the [`Tx`](https://godoc.org/go.etcd.io/bbolt#Tx) +documentation for information about optimizing for larger-than-RAM datasets. + +One common use case is to backup over HTTP so you can use tools like `cURL` to +do database backups: + +```go +func BackupHandleFunc(w http.ResponseWriter, req *http.Request) { + err := db.View(func(tx *bolt.Tx) error { + w.Header().Set("Content-Type", "application/octet-stream") + w.Header().Set("Content-Disposition", `attachment; filename="my.db"`) + w.Header().Set("Content-Length", strconv.Itoa(int(tx.Size()))) + _, err := tx.WriteTo(w) + return err + }) + if err != nil { + http.Error(w, err.Error(), http.StatusInternalServerError) + } +} +``` + +Then you can backup using this command: + +```sh +$ curl http://localhost/backup > my.db +``` + +Or you can open your browser to `http://localhost/backup` and it will download +automatically. + +If you want to backup to another file you can use the `Tx.CopyFile()` helper +function. + + +### Statistics + +The database keeps a running count of many of the internal operations it +performs so you can better understand what's going on. By grabbing a snapshot +of these stats at two points in time we can see what operations were performed +in that time range. + +For example, we could start a goroutine to log stats every 10 seconds: + +```go +go func() { + // Grab the initial stats. + prev := db.Stats() + + for { + // Wait for 10s. + time.Sleep(10 * time.Second) + + // Grab the current stats and diff them. + stats := db.Stats() + diff := stats.Sub(&prev) + + // Encode stats to JSON and print to STDERR. + json.NewEncoder(os.Stderr).Encode(diff) + + // Save stats for the next loop. + prev = stats + } +}() +``` + +It's also useful to pipe these stats to a service such as statsd for monitoring +or to provide an HTTP endpoint that will perform a fixed-length sample. + + +### Read-Only Mode + +Sometimes it is useful to create a shared, read-only Bolt database. To this, +set the `Options.ReadOnly` flag when opening your database. Read-only mode +uses a shared lock to allow multiple processes to read from the database but +it will block any processes from opening the database in read-write mode. + +```go +db, err := bolt.Open("my.db", 0666, &bolt.Options{ReadOnly: true}) +if err != nil { + log.Fatal(err) +} +``` + +### Mobile Use (iOS/Android) + +Bolt is able to run on mobile devices by leveraging the binding feature of the +[gomobile](https://github.com/golang/mobile) tool. Create a struct that will +contain your database logic and a reference to a `*bolt.DB` with a initializing +constructor that takes in a filepath where the database file will be stored. +Neither Android nor iOS require extra permissions or cleanup from using this method. + +```go +func NewBoltDB(filepath string) *BoltDB { + db, err := bolt.Open(filepath+"/demo.db", 0600, nil) + if err != nil { + log.Fatal(err) + } + + return &BoltDB{db} +} + +type BoltDB struct { + db *bolt.DB + ... +} + +func (b *BoltDB) Path() string { + return b.db.Path() +} + +func (b *BoltDB) Close() { + b.db.Close() +} +``` + +Database logic should be defined as methods on this wrapper struct. + +To initialize this struct from the native language (both platforms now sync +their local storage to the cloud. These snippets disable that functionality for the +database file): + +#### Android + +```java +String path; +if (android.os.Build.VERSION.SDK_INT >=android.os.Build.VERSION_CODES.LOLLIPOP){ + path = getNoBackupFilesDir().getAbsolutePath(); +} else{ + path = getFilesDir().getAbsolutePath(); +} +Boltmobiledemo.BoltDB boltDB = Boltmobiledemo.NewBoltDB(path) +``` + +#### iOS + +```objc +- (void)demo { + NSString* path = [NSSearchPathForDirectoriesInDomains(NSLibraryDirectory, + NSUserDomainMask, + YES) objectAtIndex:0]; + GoBoltmobiledemoBoltDB * demo = GoBoltmobiledemoNewBoltDB(path); + [self addSkipBackupAttributeToItemAtPath:demo.path]; + //Some DB Logic would go here + [demo close]; +} + +- (BOOL)addSkipBackupAttributeToItemAtPath:(NSString *) filePathString +{ + NSURL* URL= [NSURL fileURLWithPath: filePathString]; + assert([[NSFileManager defaultManager] fileExistsAtPath: [URL path]]); + + NSError *error = nil; + BOOL success = [URL setResourceValue: [NSNumber numberWithBool: YES] + forKey: NSURLIsExcludedFromBackupKey error: &error]; + if(!success){ + NSLog(@"Error excluding %@ from backup %@", [URL lastPathComponent], error); + } + return success; +} + +``` + +## Resources + +For more information on getting started with Bolt, check out the following articles: + +* [Intro to BoltDB: Painless Performant Persistence](http://npf.io/2014/07/intro-to-boltdb-painless-performant-persistence/) by [Nate Finch](https://github.com/natefinch). +* [Bolt -- an embedded key/value database for Go](https://www.progville.com/go/bolt-embedded-db-golang/) by Progville + + +## Comparison with other databases + +### Postgres, MySQL, & other relational databases + +Relational databases structure data into rows and are only accessible through +the use of SQL. This approach provides flexibility in how you store and query +your data but also incurs overhead in parsing and planning SQL statements. Bolt +accesses all data by a byte slice key. This makes Bolt fast to read and write +data by key but provides no built-in support for joining values together. + +Most relational databases (with the exception of SQLite) are standalone servers +that run separately from your application. This gives your systems +flexibility to connect multiple application servers to a single database +server but also adds overhead in serializing and transporting data over the +network. Bolt runs as a library included in your application so all data access +has to go through your application's process. This brings data closer to your +application but limits multi-process access to the data. + + +### LevelDB, RocksDB + +LevelDB and its derivatives (RocksDB, HyperLevelDB) are similar to Bolt in that +they are libraries bundled into the application, however, their underlying +structure is a log-structured merge-tree (LSM tree). An LSM tree optimizes +random writes by using a write ahead log and multi-tiered, sorted files called +SSTables. Bolt uses a B+tree internally and only a single file. Both approaches +have trade-offs. + +If you require a high random write throughput (>10,000 w/sec) or you need to use +spinning disks then LevelDB could be a good choice. If your application is +read-heavy or does a lot of range scans then Bolt could be a good choice. + +One other important consideration is that LevelDB does not have transactions. +It supports batch writing of key/values pairs and it supports read snapshots +but it will not give you the ability to do a compare-and-swap operation safely. +Bolt supports fully serializable ACID transactions. + + +### LMDB + +Bolt was originally a port of LMDB so it is architecturally similar. Both use +a B+tree, have ACID semantics with fully serializable transactions, and support +lock-free MVCC using a single writer and multiple readers. + +The two projects have somewhat diverged. LMDB heavily focuses on raw performance +while Bolt has focused on simplicity and ease of use. For example, LMDB allows +several unsafe actions such as direct writes for the sake of performance. Bolt +opts to disallow actions which can leave the database in a corrupted state. The +only exception to this in Bolt is `DB.NoSync`. + +There are also a few differences in API. LMDB requires a maximum mmap size when +opening an `mdb_env` whereas Bolt will handle incremental mmap resizing +automatically. LMDB overloads the getter and setter functions with multiple +flags whereas Bolt splits these specialized cases into their own functions. + + +## Caveats & Limitations + +It's important to pick the right tool for the job and Bolt is no exception. +Here are a few things to note when evaluating and using Bolt: + +* Bolt is good for read intensive workloads. Sequential write performance is + also fast but random writes can be slow. You can use `DB.Batch()` or add a + write-ahead log to help mitigate this issue. + +* Bolt uses a B+tree internally so there can be a lot of random page access. + SSDs provide a significant performance boost over spinning disks. + +* Try to avoid long running read transactions. Bolt uses copy-on-write so + old pages cannot be reclaimed while an old transaction is using them. + +* Byte slices returned from Bolt are only valid during a transaction. Once the + transaction has been committed or rolled back then the memory they point to + can be reused by a new page or can be unmapped from virtual memory and you'll + see an `unexpected fault address` panic when accessing it. + +* Bolt uses an exclusive write lock on the database file so it cannot be + shared by multiple processes. + +* Be careful when using `Bucket.FillPercent`. Setting a high fill percent for + buckets that have random inserts will cause your database to have very poor + page utilization. + +* Use larger buckets in general. Smaller buckets causes poor page utilization + once they become larger than the page size (typically 4KB). + +* Bulk loading a lot of random writes into a new bucket can be slow as the + page will not split until the transaction is committed. Randomly inserting + more than 100,000 key/value pairs into a single new bucket in a single + transaction is not advised. + +* Bolt uses a memory-mapped file so the underlying operating system handles the + caching of the data. Typically, the OS will cache as much of the file as it + can in memory and will release memory as needed to other processes. This means + that Bolt can show very high memory usage when working with large databases. + However, this is expected and the OS will release memory as needed. Bolt can + handle databases much larger than the available physical RAM, provided its + memory-map fits in the process virtual address space. It may be problematic + on 32-bits systems. + +* The data structures in the Bolt database are memory mapped so the data file + will be endian specific. This means that you cannot copy a Bolt file from a + little endian machine to a big endian machine and have it work. For most + users this is not a concern since most modern CPUs are little endian. + +* Because of the way pages are laid out on disk, Bolt cannot truncate data files + and return free pages back to the disk. Instead, Bolt maintains a free list + of unused pages within its data file. These free pages can be reused by later + transactions. This works well for many use cases as databases generally tend + to grow. However, it's important to note that deleting large chunks of data + will not allow you to reclaim that space on disk. + + For more information on page allocation, [see this comment][page-allocation]. + +[page-allocation]: https://github.com/boltdb/bolt/issues/308#issuecomment-74811638 + + +## Reading the Source + +Bolt is a relatively small code base (<5KLOC) for an embedded, serializable, +transactional key/value database so it can be a good starting point for people +interested in how databases work. + +The best places to start are the main entry points into Bolt: + +- `Open()` - Initializes the reference to the database. It's responsible for + creating the database if it doesn't exist, obtaining an exclusive lock on the + file, reading the meta pages, & memory-mapping the file. + +- `DB.Begin()` - Starts a read-only or read-write transaction depending on the + value of the `writable` argument. This requires briefly obtaining the "meta" + lock to keep track of open transactions. Only one read-write transaction can + exist at a time so the "rwlock" is acquired during the life of a read-write + transaction. + +- `Bucket.Put()` - Writes a key/value pair into a bucket. After validating the + arguments, a cursor is used to traverse the B+tree to the page and position + where they key & value will be written. Once the position is found, the bucket + materializes the underlying page and the page's parent pages into memory as + "nodes". These nodes are where mutations occur during read-write transactions. + These changes get flushed to disk during commit. + +- `Bucket.Get()` - Retrieves a key/value pair from a bucket. This uses a cursor + to move to the page & position of a key/value pair. During a read-only + transaction, the key and value data is returned as a direct reference to the + underlying mmap file so there's no allocation overhead. For read-write + transactions, this data may reference the mmap file or one of the in-memory + node values. + +- `Cursor` - This object is simply for traversing the B+tree of on-disk pages + or in-memory nodes. It can seek to a specific key, move to the first or last + value, or it can move forward or backward. The cursor handles the movement up + and down the B+tree transparently to the end user. + +- `Tx.Commit()` - Converts the in-memory dirty nodes and the list of free pages + into pages to be written to disk. Writing to disk then occurs in two phases. + First, the dirty pages are written to disk and an `fsync()` occurs. Second, a + new meta page with an incremented transaction ID is written and another + `fsync()` occurs. This two phase write ensures that partially written data + pages are ignored in the event of a crash since the meta page pointing to them + is never written. Partially written meta pages are invalidated because they + are written with a checksum. + +If you have additional notes that could be helpful for others, please submit +them via pull request. + + +## Other Projects Using Bolt + +Below is a list of public, open source projects that use Bolt: + +* [Algernon](https://github.com/xyproto/algernon) - A HTTP/2 web server with built-in support for Lua. Uses BoltDB as the default database backend. +* [Bazil](https://bazil.org/) - A file system that lets your data reside where it is most convenient for it to reside. +* [bolter](https://github.com/hasit/bolter) - Command-line app for viewing BoltDB file in your terminal. +* [boltcli](https://github.com/spacewander/boltcli) - the redis-cli for boltdb with Lua script support. +* [BoltHold](https://github.com/timshannon/bolthold) - An embeddable NoSQL store for Go types built on BoltDB +* [BoltStore](https://github.com/yosssi/boltstore) - Session store using Bolt. +* [Boltdb Boilerplate](https://github.com/bobintornado/boltdb-boilerplate) - Boilerplate wrapper around bolt aiming to make simple calls one-liners. +* [BoltDbWeb](https://github.com/evnix/boltdbweb) - A web based GUI for BoltDB files. +* [bleve](http://www.blevesearch.com/) - A pure Go search engine similar to ElasticSearch that uses Bolt as the default storage backend. +* [btcwallet](https://github.com/btcsuite/btcwallet) - A bitcoin wallet. +* [buckets](https://github.com/joyrexus/buckets) - a bolt wrapper streamlining + simple tx and key scans. +* [cayley](https://github.com/google/cayley) - Cayley is an open-source graph database using Bolt as optional backend. +* [ChainStore](https://github.com/pressly/chainstore) - Simple key-value interface to a variety of storage engines organized as a chain of operations. +* [Consul](https://github.com/hashicorp/consul) - Consul is service discovery and configuration made easy. Distributed, highly available, and datacenter-aware. +* [DVID](https://github.com/janelia-flyem/dvid) - Added Bolt as optional storage engine and testing it against Basho-tuned leveldb. +* [dcrwallet](https://github.com/decred/dcrwallet) - A wallet for the Decred cryptocurrency. +* [drive](https://github.com/odeke-em/drive) - drive is an unofficial Google Drive command line client for \*NIX operating systems. +* [event-shuttle](https://github.com/sclasen/event-shuttle) - A Unix system service to collect and reliably deliver messages to Kafka. +* [Freehold](http://tshannon.bitbucket.org/freehold/) - An open, secure, and lightweight platform for your files and data. +* [Go Report Card](https://goreportcard.com/) - Go code quality report cards as a (free and open source) service. +* [GoWebApp](https://github.com/josephspurrier/gowebapp) - A basic MVC web application in Go using BoltDB. +* [GoShort](https://github.com/pankajkhairnar/goShort) - GoShort is a URL shortener written in Golang and BoltDB for persistent key/value storage and for routing it's using high performent HTTPRouter. +* [gopherpit](https://github.com/gopherpit/gopherpit) - A web service to manage Go remote import paths with custom domains +* [gokv](https://github.com/philippgille/gokv) - Simple key-value store abstraction and implementations for Go (Redis, Consul, etcd, bbolt, BadgerDB, LevelDB, Memcached, DynamoDB, S3, PostgreSQL, MongoDB, CockroachDB and many more) +* [Gitchain](https://github.com/gitchain/gitchain) - Decentralized, peer-to-peer Git repositories aka "Git meets Bitcoin". +* [InfluxDB](https://influxdata.com) - Scalable datastore for metrics, events, and real-time analytics. +* [ipLocator](https://github.com/AndreasBriese/ipLocator) - A fast ip-geo-location-server using bolt with bloom filters. +* [ipxed](https://github.com/kelseyhightower/ipxed) - Web interface and api for ipxed. +* [Ironsmith](https://github.com/timshannon/ironsmith) - A simple, script-driven continuous integration (build - > test -> release) tool, with no external dependencies +* [Kala](https://github.com/ajvb/kala) - Kala is a modern job scheduler optimized to run on a single node. It is persistent, JSON over HTTP API, ISO 8601 duration notation, and dependent jobs. +* [Key Value Access Langusge (KVAL)](https://github.com/kval-access-language) - A proposed grammar for key-value datastores offering a bbolt binding. +* [LedisDB](https://github.com/siddontang/ledisdb) - A high performance NoSQL, using Bolt as optional storage. +* [lru](https://github.com/crowdriff/lru) - Easy to use Bolt-backed Least-Recently-Used (LRU) read-through cache with chainable remote stores. +* [mbuckets](https://github.com/abhigupta912/mbuckets) - A Bolt wrapper that allows easy operations on multi level (nested) buckets. +* [MetricBase](https://github.com/msiebuhr/MetricBase) - Single-binary version of Graphite. +* [MuLiFS](https://github.com/dankomiocevic/mulifs) - Music Library Filesystem creates a filesystem to organise your music files. +* [NATS](https://github.com/nats-io/nats-streaming-server) - NATS Streaming uses bbolt for message and metadata storage. +* [Operation Go: A Routine Mission](http://gocode.io) - An online programming game for Golang using Bolt for user accounts and a leaderboard. +* [photosite/session](https://godoc.org/bitbucket.org/kardianos/photosite/session) - Sessions for a photo viewing site. +* [Prometheus Annotation Server](https://github.com/oliver006/prom_annotation_server) - Annotation server for PromDash & Prometheus service monitoring system. +* [Rain](https://github.com/cenkalti/rain) - BitTorrent client and library. +* [reef-pi](https://github.com/reef-pi/reef-pi) - reef-pi is an award winning, modular, DIY reef tank controller using easy to learn electronics based on a Raspberry Pi. +* [Request Baskets](https://github.com/darklynx/request-baskets) - A web service to collect arbitrary HTTP requests and inspect them via REST API or simple web UI, similar to [RequestBin](http://requestb.in/) service +* [Seaweed File System](https://github.com/chrislusf/seaweedfs) - Highly scalable distributed key~file system with O(1) disk read. +* [stow](https://github.com/djherbis/stow) - a persistence manager for objects + backed by boltdb. +* [Storm](https://github.com/asdine/storm) - Simple and powerful ORM for BoltDB. +* [SimpleBolt](https://github.com/xyproto/simplebolt) - A simple way to use BoltDB. Deals mainly with strings. +* [Skybox Analytics](https://github.com/skybox/skybox) - A standalone funnel analysis tool for web analytics. +* [Scuttlebutt](https://github.com/benbjohnson/scuttlebutt) - Uses Bolt to store and process all Twitter mentions of GitHub projects. +* [tentacool](https://github.com/optiflows/tentacool) - REST api server to manage system stuff (IP, DNS, Gateway...) on a linux server. +* [torrent](https://github.com/anacrolix/torrent) - Full-featured BitTorrent client package and utilities in Go. BoltDB is a storage backend in development. +* [Wiki](https://github.com/peterhellberg/wiki) - A tiny wiki using Goji, BoltDB and Blackfriday. + +If you are using Bolt in a project please send a pull request to add it to the list. diff --git a/vendor/etcd.io/bbolt/allocate_test.go b/vendor/etcd.io/bbolt/allocate_test.go new file mode 100644 index 0000000..98b06b4 --- /dev/null +++ b/vendor/etcd.io/bbolt/allocate_test.go @@ -0,0 +1,31 @@ +package bbolt + +import ( + "testing" +) + +func TestTx_allocatePageStats(t *testing.T) { + f := newTestFreelist() + ids := []pgid{2, 3} + f.readIDs(ids) + + tx := &Tx{ + db: &DB{ + freelist: f, + pageSize: defaultPageSize, + }, + meta: &meta{}, + pages: make(map[pgid]*page), + } + + prePageCnt := tx.Stats().PageCount + allocateCnt := f.free_count() + + if _, err := tx.allocate(allocateCnt); err != nil { + t.Fatal(err) + } + + if tx.Stats().PageCount != prePageCnt+allocateCnt { + t.Errorf("Allocated %d but got %d page in stats", allocateCnt, tx.Stats().PageCount) + } +} diff --git a/vendor/etcd.io/bbolt/bolt_386.go b/vendor/etcd.io/bbolt/bolt_386.go new file mode 100644 index 0000000..aee2596 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_386.go @@ -0,0 +1,7 @@ +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0x7FFFFFFF // 2GB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0xFFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_amd64.go b/vendor/etcd.io/bbolt/bolt_amd64.go new file mode 100644 index 0000000..5dd8f3f --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_amd64.go @@ -0,0 +1,7 @@ +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0xFFFFFFFFFFFF // 256TB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0x7FFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_arm.go b/vendor/etcd.io/bbolt/bolt_arm.go new file mode 100644 index 0000000..aee2596 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_arm.go @@ -0,0 +1,7 @@ +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0x7FFFFFFF // 2GB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0xFFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_arm64.go b/vendor/etcd.io/bbolt/bolt_arm64.go new file mode 100644 index 0000000..810dfd5 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_arm64.go @@ -0,0 +1,9 @@ +// +build arm64 + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0xFFFFFFFFFFFF // 256TB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0x7FFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_linux.go b/vendor/etcd.io/bbolt/bolt_linux.go new file mode 100644 index 0000000..7707bca --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_linux.go @@ -0,0 +1,10 @@ +package bbolt + +import ( + "syscall" +) + +// fdatasync flushes written data to a file descriptor. +func fdatasync(db *DB) error { + return syscall.Fdatasync(int(db.file.Fd())) +} diff --git a/vendor/etcd.io/bbolt/bolt_mips64x.go b/vendor/etcd.io/bbolt/bolt_mips64x.go new file mode 100644 index 0000000..dd8ffe1 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_mips64x.go @@ -0,0 +1,9 @@ +// +build mips64 mips64le + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0x8000000000 // 512GB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0x7FFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_mipsx.go b/vendor/etcd.io/bbolt/bolt_mipsx.go new file mode 100644 index 0000000..a669703 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_mipsx.go @@ -0,0 +1,9 @@ +// +build mips mipsle + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0x40000000 // 1GB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0xFFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_openbsd.go b/vendor/etcd.io/bbolt/bolt_openbsd.go new file mode 100644 index 0000000..d7f5035 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_openbsd.go @@ -0,0 +1,27 @@ +package bbolt + +import ( + "syscall" + "unsafe" +) + +const ( + msAsync = 1 << iota // perform asynchronous writes + msSync // perform synchronous writes + msInvalidate // invalidate cached data +) + +func msync(db *DB) error { + _, _, errno := syscall.Syscall(syscall.SYS_MSYNC, uintptr(unsafe.Pointer(db.data)), uintptr(db.datasz), msInvalidate) + if errno != 0 { + return errno + } + return nil +} + +func fdatasync(db *DB) error { + if db.data != nil { + return msync(db) + } + return db.file.Sync() +} diff --git a/vendor/etcd.io/bbolt/bolt_ppc.go b/vendor/etcd.io/bbolt/bolt_ppc.go new file mode 100644 index 0000000..84e545e --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_ppc.go @@ -0,0 +1,9 @@ +// +build ppc + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0x7FFFFFFF // 2GB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0xFFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_ppc64.go b/vendor/etcd.io/bbolt/bolt_ppc64.go new file mode 100644 index 0000000..a761209 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_ppc64.go @@ -0,0 +1,9 @@ +// +build ppc64 + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0xFFFFFFFFFFFF // 256TB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0x7FFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_ppc64le.go b/vendor/etcd.io/bbolt/bolt_ppc64le.go new file mode 100644 index 0000000..c830f2f --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_ppc64le.go @@ -0,0 +1,9 @@ +// +build ppc64le + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0xFFFFFFFFFFFF // 256TB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0x7FFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_riscv64.go b/vendor/etcd.io/bbolt/bolt_riscv64.go new file mode 100644 index 0000000..c967613 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_riscv64.go @@ -0,0 +1,9 @@ +// +build riscv64 + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0xFFFFFFFFFFFF // 256TB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0x7FFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_s390x.go b/vendor/etcd.io/bbolt/bolt_s390x.go new file mode 100644 index 0000000..ff2a560 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_s390x.go @@ -0,0 +1,9 @@ +// +build s390x + +package bbolt + +// maxMapSize represents the largest mmap size supported by Bolt. +const maxMapSize = 0xFFFFFFFFFFFF // 256TB + +// maxAllocSize is the size used when creating array pointers. +const maxAllocSize = 0x7FFFFFFF diff --git a/vendor/etcd.io/bbolt/bolt_unix.go b/vendor/etcd.io/bbolt/bolt_unix.go new file mode 100644 index 0000000..2938fed --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_unix.go @@ -0,0 +1,93 @@ +// +build !windows,!plan9,!solaris,!aix + +package bbolt + +import ( + "fmt" + "syscall" + "time" + "unsafe" +) + +// flock acquires an advisory lock on a file descriptor. +func flock(db *DB, exclusive bool, timeout time.Duration) error { + var t time.Time + if timeout != 0 { + t = time.Now() + } + fd := db.file.Fd() + flag := syscall.LOCK_NB + if exclusive { + flag |= syscall.LOCK_EX + } else { + flag |= syscall.LOCK_SH + } + for { + // Attempt to obtain an exclusive lock. + err := syscall.Flock(int(fd), flag) + if err == nil { + return nil + } else if err != syscall.EWOULDBLOCK { + return err + } + + // If we timed out then return an error. + if timeout != 0 && time.Since(t) > timeout-flockRetryTimeout { + return ErrTimeout + } + + // Wait for a bit and try again. + time.Sleep(flockRetryTimeout) + } +} + +// funlock releases an advisory lock on a file descriptor. +func funlock(db *DB) error { + return syscall.Flock(int(db.file.Fd()), syscall.LOCK_UN) +} + +// mmap memory maps a DB's data file. +func mmap(db *DB, sz int) error { + // Map the data file to memory. + b, err := syscall.Mmap(int(db.file.Fd()), 0, sz, syscall.PROT_READ, syscall.MAP_SHARED|db.MmapFlags) + if err != nil { + return err + } + + // Advise the kernel that the mmap is accessed randomly. + err = madvise(b, syscall.MADV_RANDOM) + if err != nil && err != syscall.ENOSYS { + // Ignore not implemented error in kernel because it still works. + return fmt.Errorf("madvise: %s", err) + } + + // Save the original byte slice and convert to a byte array pointer. + db.dataref = b + db.data = (*[maxMapSize]byte)(unsafe.Pointer(&b[0])) + db.datasz = sz + return nil +} + +// munmap unmaps a DB's data file from memory. +func munmap(db *DB) error { + // Ignore the unmap if we have no mapped data. + if db.dataref == nil { + return nil + } + + // Unmap using the original byte slice. + err := syscall.Munmap(db.dataref) + db.dataref = nil + db.data = nil + db.datasz = 0 + return err +} + +// NOTE: This function is copied from stdlib because it is not available on darwin. +func madvise(b []byte, advice int) (err error) { + _, _, e1 := syscall.Syscall(syscall.SYS_MADVISE, uintptr(unsafe.Pointer(&b[0])), uintptr(len(b)), uintptr(advice)) + if e1 != 0 { + err = e1 + } + return +} diff --git a/vendor/etcd.io/bbolt/bolt_unix_aix.go b/vendor/etcd.io/bbolt/bolt_unix_aix.go new file mode 100644 index 0000000..a64c16f --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_unix_aix.go @@ -0,0 +1,90 @@ +// +build aix + +package bbolt + +import ( + "fmt" + "syscall" + "time" + "unsafe" + + "golang.org/x/sys/unix" +) + +// flock acquires an advisory lock on a file descriptor. +func flock(db *DB, exclusive bool, timeout time.Duration) error { + var t time.Time + if timeout != 0 { + t = time.Now() + } + fd := db.file.Fd() + var lockType int16 + if exclusive { + lockType = syscall.F_WRLCK + } else { + lockType = syscall.F_RDLCK + } + for { + // Attempt to obtain an exclusive lock. + lock := syscall.Flock_t{Type: lockType} + err := syscall.FcntlFlock(fd, syscall.F_SETLK, &lock) + if err == nil { + return nil + } else if err != syscall.EAGAIN { + return err + } + + // If we timed out then return an error. + if timeout != 0 && time.Since(t) > timeout-flockRetryTimeout { + return ErrTimeout + } + + // Wait for a bit and try again. + time.Sleep(flockRetryTimeout) + } +} + +// funlock releases an advisory lock on a file descriptor. +func funlock(db *DB) error { + var lock syscall.Flock_t + lock.Start = 0 + lock.Len = 0 + lock.Type = syscall.F_UNLCK + lock.Whence = 0 + return syscall.FcntlFlock(uintptr(db.file.Fd()), syscall.F_SETLK, &lock) +} + +// mmap memory maps a DB's data file. +func mmap(db *DB, sz int) error { + // Map the data file to memory. + b, err := unix.Mmap(int(db.file.Fd()), 0, sz, syscall.PROT_READ, syscall.MAP_SHARED|db.MmapFlags) + if err != nil { + return err + } + + // Advise the kernel that the mmap is accessed randomly. + if err := unix.Madvise(b, syscall.MADV_RANDOM); err != nil { + return fmt.Errorf("madvise: %s", err) + } + + // Save the original byte slice and convert to a byte array pointer. + db.dataref = b + db.data = (*[maxMapSize]byte)(unsafe.Pointer(&b[0])) + db.datasz = sz + return nil +} + +// munmap unmaps a DB's data file from memory. +func munmap(db *DB) error { + // Ignore the unmap if we have no mapped data. + if db.dataref == nil { + return nil + } + + // Unmap using the original byte slice. + err := unix.Munmap(db.dataref) + db.dataref = nil + db.data = nil + db.datasz = 0 + return err +} diff --git a/vendor/etcd.io/bbolt/bolt_unix_solaris.go b/vendor/etcd.io/bbolt/bolt_unix_solaris.go new file mode 100644 index 0000000..babad65 --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_unix_solaris.go @@ -0,0 +1,88 @@ +package bbolt + +import ( + "fmt" + "syscall" + "time" + "unsafe" + + "golang.org/x/sys/unix" +) + +// flock acquires an advisory lock on a file descriptor. +func flock(db *DB, exclusive bool, timeout time.Duration) error { + var t time.Time + if timeout != 0 { + t = time.Now() + } + fd := db.file.Fd() + var lockType int16 + if exclusive { + lockType = syscall.F_WRLCK + } else { + lockType = syscall.F_RDLCK + } + for { + // Attempt to obtain an exclusive lock. + lock := syscall.Flock_t{Type: lockType} + err := syscall.FcntlFlock(fd, syscall.F_SETLK, &lock) + if err == nil { + return nil + } else if err != syscall.EAGAIN { + return err + } + + // If we timed out then return an error. + if timeout != 0 && time.Since(t) > timeout-flockRetryTimeout { + return ErrTimeout + } + + // Wait for a bit and try again. + time.Sleep(flockRetryTimeout) + } +} + +// funlock releases an advisory lock on a file descriptor. +func funlock(db *DB) error { + var lock syscall.Flock_t + lock.Start = 0 + lock.Len = 0 + lock.Type = syscall.F_UNLCK + lock.Whence = 0 + return syscall.FcntlFlock(uintptr(db.file.Fd()), syscall.F_SETLK, &lock) +} + +// mmap memory maps a DB's data file. +func mmap(db *DB, sz int) error { + // Map the data file to memory. + b, err := unix.Mmap(int(db.file.Fd()), 0, sz, syscall.PROT_READ, syscall.MAP_SHARED|db.MmapFlags) + if err != nil { + return err + } + + // Advise the kernel that the mmap is accessed randomly. + if err := unix.Madvise(b, syscall.MADV_RANDOM); err != nil { + return fmt.Errorf("madvise: %s", err) + } + + // Save the original byte slice and convert to a byte array pointer. + db.dataref = b + db.data = (*[maxMapSize]byte)(unsafe.Pointer(&b[0])) + db.datasz = sz + return nil +} + +// munmap unmaps a DB's data file from memory. +func munmap(db *DB) error { + // Ignore the unmap if we have no mapped data. + if db.dataref == nil { + return nil + } + + // Unmap using the original byte slice. + err := unix.Munmap(db.dataref) + db.dataref = nil + db.data = nil + db.datasz = 0 + return err +} diff --git a/vendor/etcd.io/bbolt/bolt_windows.go b/vendor/etcd.io/bbolt/bolt_windows.go new file mode 100644 index 0000000..fca178b --- /dev/null +++ b/vendor/etcd.io/bbolt/bolt_windows.go @@ -0,0 +1,141 @@ +package bbolt + +import ( + "fmt" + "os" + "syscall" + "time" + "unsafe" +) + +// LockFileEx code derived from golang build filemutex_windows.go @ v1.5.1 +var ( + modkernel32 = syscall.NewLazyDLL("kernel32.dll") + procLockFileEx = modkernel32.NewProc("LockFileEx") + procUnlockFileEx = modkernel32.NewProc("UnlockFileEx") +) + +const ( + // see https://msdn.microsoft.com/en-us/library/windows/desktop/aa365203(v=vs.85).aspx + flagLockExclusive = 2 + flagLockFailImmediately = 1 + + // see https://msdn.microsoft.com/en-us/library/windows/desktop/ms681382(v=vs.85).aspx + errLockViolation syscall.Errno = 0x21 +) + +func lockFileEx(h syscall.Handle, flags, reserved, locklow, lockhigh uint32, ol *syscall.Overlapped) (err error) { + r, _, err := procLockFileEx.Call(uintptr(h), uintptr(flags), uintptr(reserved), uintptr(locklow), uintptr(lockhigh), uintptr(unsafe.Pointer(ol))) + if r == 0 { + return err + } + return nil +} + +func unlockFileEx(h syscall.Handle, reserved, locklow, lockhigh uint32, ol *syscall.Overlapped) (err error) { + r, _, err := procUnlockFileEx.Call(uintptr(h), uintptr(reserved), uintptr(locklow), uintptr(lockhigh), uintptr(unsafe.Pointer(ol)), 0) + if r == 0 { + return err + } + return nil +} + +// fdatasync flushes written data to a file descriptor. +func fdatasync(db *DB) error { + return db.file.Sync() +} + +// flock acquires an advisory lock on a file descriptor. +func flock(db *DB, exclusive bool, timeout time.Duration) error { + var t time.Time + if timeout != 0 { + t = time.Now() + } + var flag uint32 = flagLockFailImmediately + if exclusive { + flag |= flagLockExclusive + } + for { + // Fix for https://github.com/etcd-io/bbolt/issues/121. Use byte-range + // -1..0 as the lock on the database file. + var m1 uint32 = (1 << 32) - 1 // -1 in a uint32 + err := lockFileEx(syscall.Handle(db.file.Fd()), flag, 0, 1, 0, &syscall.Overlapped{ + Offset: m1, + OffsetHigh: m1, + }) + + if err == nil { + return nil + } else if err != errLockViolation { + return err + } + + // If we timed oumercit then return an error. + if timeout != 0 && time.Since(t) > timeout-flockRetryTimeout { + return ErrTimeout + } + + // Wait for a bit and try again. + time.Sleep(flockRetryTimeout) + } +} + +// funlock releases an advisory lock on a file descriptor. +func funlock(db *DB) error { + var m1 uint32 = (1 << 32) - 1 // -1 in a uint32 + err := unlockFileEx(syscall.Handle(db.file.Fd()), 0, 1, 0, &syscall.Overlapped{ + Offset: m1, + OffsetHigh: m1, + }) + return err +} + +// mmap memory maps a DB's data file. +// Based on: https://github.com/edsrzf/mmap-go +func mmap(db *DB, sz int) error { + if !db.readOnly { + // Truncate the database to the size of the mmap. + if err := db.file.Truncate(int64(sz)); err != nil { + return fmt.Errorf("truncate: %s", err) + } + } + + // Open a file mapping handle. + sizelo := uint32(sz >> 32) + sizehi := uint32(sz) & 0xffffffff + h, errno := syscall.CreateFileMapping(syscall.Handle(db.file.Fd()), nil, syscall.PAGE_READONLY, sizelo, sizehi, nil) + if h == 0 { + return os.NewSyscallError("CreateFileMapping", errno) + } + + // Create the memory map. + addr, errno := syscall.MapViewOfFile(h, syscall.FILE_MAP_READ, 0, 0, uintptr(sz)) + if addr == 0 { + return os.NewSyscallError("MapViewOfFile", errno) + } + + // Close mapping handle. + if err := syscall.CloseHandle(syscall.Handle(h)); err != nil { + return os.NewSyscallError("CloseHandle", err) + } + + // Convert to a byte array. + db.data = ((*[maxMapSize]byte)(unsafe.Pointer(addr))) + db.datasz = sz + + return nil +} + +// munmap unmaps a pointer from a file. +// Based on: https://github.com/edsrzf/mmap-go +func munmap(db *DB) error { + if db.data == nil { + return nil + } + + addr := (uintptr)(unsafe.Pointer(&db.data[0])) + if err := syscall.UnmapViewOfFile(addr); err != nil { + return os.NewSyscallError("UnmapViewOfFile", err) + } + return nil +} diff --git a/vendor/etcd.io/bbolt/boltsync_unix.go b/vendor/etcd.io/bbolt/boltsync_unix.go new file mode 100644 index 0000000..9587afe --- /dev/null +++ b/vendor/etcd.io/bbolt/boltsync_unix.go @@ -0,0 +1,8 @@ +// +build !windows,!plan9,!linux,!openbsd + +package bbolt + +// fdatasync flushes written data to a file descriptor. +func fdatasync(db *DB) error { + return db.file.Sync() +} diff --git a/vendor/etcd.io/bbolt/bucket.go b/vendor/etcd.io/bbolt/bucket.go new file mode 100644 index 0000000..d8750b1 --- /dev/null +++ b/vendor/etcd.io/bbolt/bucket.go @@ -0,0 +1,777 @@ +package bbolt + +import ( + "bytes" + "fmt" + "unsafe" +) + +const ( + // MaxKeySize is the maximum length of a key, in bytes. + MaxKeySize = 32768 + + // MaxValueSize is the maximum length of a value, in bytes. + MaxValueSize = (1 << 31) - 2 +) + +const bucketHeaderSize = int(unsafe.Sizeof(bucket{})) + +const ( + minFillPercent = 0.1 + maxFillPercent = 1.0 +) + +// DefaultFillPercent is the percentage that split pages are filled. +// This value can be changed by setting Bucket.FillPercent. +const DefaultFillPercent = 0.5 + +// Bucket represents a collection of key/value pairs inside the database. +type Bucket struct { + *bucket + tx *Tx // the associated transaction + buckets map[string]*Bucket // subbucket cache + page *page // inline page reference + rootNode *node // materialized node for the root page. + nodes map[pgid]*node // node cache + + // Sets the threshold for filling nodes when they split. By default, + // the bucket will fill to 50% but it can be useful to increase this + // amount if you know that your write workloads are mostly append-only. + // + // This is non-persisted across transactions so it must be set in every Tx. + FillPercent float64 +} + +// bucket represents the on-file representation of a bucket. +// This is stored as the "value" of a bucket key. If the bucket is small enough, +// then its root page can be stored inline in the "value", after the bucket +// header. In the case of inline buckets, the "root" will be 0. +type bucket struct { + root pgid // page id of the bucket's root-level page + sequence uint64 // monotonically incrementing, used by NextSequence() +} + +// newBucket returns a new bucket associated with a transaction. +func newBucket(tx *Tx) Bucket { + var b = Bucket{tx: tx, FillPercent: DefaultFillPercent} + if tx.writable { + b.buckets = make(map[string]*Bucket) + b.nodes = make(map[pgid]*node) + } + return b +} + +// Tx returns the tx of the bucket. +func (b *Bucket) Tx() *Tx { + return b.tx +} + +// Root returns the root of the bucket. +func (b *Bucket) Root() pgid { + return b.root +} + +// Writable returns whether the bucket is writable. +func (b *Bucket) Writable() bool { + return b.tx.writable +} + +// Cursor creates a cursor associated with the bucket. +// The cursor is only valid as long as the transaction is open. +// Do not use a cursor after the transaction is closed. +func (b *Bucket) Cursor() *Cursor { + // Update transaction statistics. + b.tx.stats.CursorCount++ + + // Allocate and return a cursor. + return &Cursor{ + bucket: b, + stack: make([]elemRef, 0), + } +} + +// Bucket retrieves a nested bucket by name. +// Returns nil if the bucket does not exist. +// The bucket instance is only valid for the lifetime of the transaction. +func (b *Bucket) Bucket(name []byte) *Bucket { + if b.buckets != nil { + if child := b.buckets[string(name)]; child != nil { + return child + } + } + + // Move cursor to key. + c := b.Cursor() + k, v, flags := c.seek(name) + + // Return nil if the key doesn't exist or it is not a bucket. + if !bytes.Equal(name, k) || (flags&bucketLeafFlag) == 0 { + return nil + } + + // Otherwise create a bucket and cache it. + var child = b.openBucket(v) + if b.buckets != nil { + b.buckets[string(name)] = child + } + + return child +} + +// Helper method that re-interprets a sub-bucket value +// from a parent into a Bucket +func (b *Bucket) openBucket(value []byte) *Bucket { + var child = newBucket(b.tx) + + // Unaligned access requires a copy to be made. + const unalignedMask = unsafe.Alignof(struct { + bucket + page + }{}) - 1 + unaligned := uintptr(unsafe.Pointer(&value[0]))&unalignedMask != 0 + if unaligned { + value = cloneBytes(value) + } + + // If this is a writable transaction then we need to copy the bucket entry. + // Read-only transactions can point directly at the mmap entry. + if b.tx.writable && !unaligned { + child.bucket = &bucket{} + *child.bucket = *(*bucket)(unsafe.Pointer(&value[0])) + } else { + child.bucket = (*bucket)(unsafe.Pointer(&value[0])) + } + + // Save a reference to the inline page if the bucket is inline. + if child.root == 0 { + child.page = (*page)(unsafe.Pointer(&value[bucketHeaderSize])) + } + + return &child +} + +// CreateBucket creates a new bucket at the given key and returns the new bucket. +// Returns an error if the key already exists, if the bucket name is blank, or if the bucket name is too long. +// The bucket instance is only valid for the lifetime of the transaction. +func (b *Bucket) CreateBucket(key []byte) (*Bucket, error) { + if b.tx.db == nil { + return nil, ErrTxClosed + } else if !b.tx.writable { + return nil, ErrTxNotWritable + } else if len(key) == 0 { + return nil, ErrBucketNameRequired + } + + // Move cursor to correct position. + c := b.Cursor() + k, _, flags := c.seek(key) + + // Return an error if there is an existing key. + if bytes.Equal(key, k) { + if (flags & bucketLeafFlag) != 0 { + return nil, ErrBucketExists + } + return nil, ErrIncompatibleValue + } + + // Create empty, inline bucket. + var bucket = Bucket{ + bucket: &bucket{}, + rootNode: &node{isLeaf: true}, + FillPercent: DefaultFillPercent, + } + var value = bucket.write() + + // Insert into node. + key = cloneBytes(key) + c.node().put(key, key, value, 0, bucketLeafFlag) + + // Since subbuckets are not allowed on inline buckets, we need to + // dereference the inline page, if it exists. This will cause the bucket + // to be treated as a regular, non-inline bucket for the rest of the tx. + b.page = nil + + return b.Bucket(key), nil +} + +// CreateBucketIfNotExists creates a new bucket if it doesn't already exist and returns a reference to it. +// Returns an error if the bucket name is blank, or if the bucket name is too long. +// The bucket instance is only valid for the lifetime of the transaction. +func (b *Bucket) CreateBucketIfNotExists(key []byte) (*Bucket, error) { + child, err := b.CreateBucket(key) + if err == ErrBucketExists { + return b.Bucket(key), nil + } else if err != nil { + return nil, err + } + return child, nil +} + +// DeleteBucket deletes a bucket at the given key. +// Returns an error if the bucket does not exist, or if the key represents a non-bucket value. +func (b *Bucket) DeleteBucket(key []byte) error { + if b.tx.db == nil { + return ErrTxClosed + } else if !b.Writable() { + return ErrTxNotWritable + } + + // Move cursor to correct position. + c := b.Cursor() + k, _, flags := c.seek(key) + + // Return an error if bucket doesn't exist or is not a bucket. + if !bytes.Equal(key, k) { + return ErrBucketNotFound + } else if (flags & bucketLeafFlag) == 0 { + return ErrIncompatibleValue + } + + // Recursively delete all child buckets. + child := b.Bucket(key) + err := child.ForEach(func(k, v []byte) error { + if _, _, childFlags := child.Cursor().seek(k); (childFlags & bucketLeafFlag) != 0 { + if err := child.DeleteBucket(k); err != nil { + return fmt.Errorf("delete bucket: %s", err) + } + } + return nil + }) + if err != nil { + return err + } + + // Remove cached copy. + delete(b.buckets, string(key)) + + // Release all bucket pages to freelist. + child.nodes = nil + child.rootNode = nil + child.free() + + // Delete the node if we have a matching key. + c.node().del(key) + + return nil +} + +// Get retrieves the value for a key in the bucket. +// Returns a nil value if the key does not exist or if the key is a nested bucket. +// The returned value is only valid for the life of the transaction. +func (b *Bucket) Get(key []byte) []byte { + k, v, flags := b.Cursor().seek(key) + + // Return nil if this is a bucket. + if (flags & bucketLeafFlag) != 0 { + return nil + } + + // If our target node isn't the same key as what's passed in then return nil. + if !bytes.Equal(key, k) { + return nil + } + return v +} + +// Put sets the value for a key in the bucket. +// If the key exist then its previous value will be overwritten. +// Supplied value must remain valid for the life of the transaction. +// Returns an error if the bucket was created from a read-only transaction, if the key is blank, if the key is too large, or if the value is too large. +func (b *Bucket) Put(key []byte, value []byte) error { + if b.tx.db == nil { + return ErrTxClosed + } else if !b.Writable() { + return ErrTxNotWritable + } else if len(key) == 0 { + return ErrKeyRequired + } else if len(key) > MaxKeySize { + return ErrKeyTooLarge + } else if int64(len(value)) > MaxValueSize { + return ErrValueTooLarge + } + + // Move cursor to correct position. + c := b.Cursor() + k, _, flags := c.seek(key) + + // Return an error if there is an existing key with a bucket value. + if bytes.Equal(key, k) && (flags&bucketLeafFlag) != 0 { + return ErrIncompatibleValue + } + + // Insert into node. + key = cloneBytes(key) + c.node().put(key, key, value, 0, 0) + + return nil +} + +// Delete removes a key from the bucket. +// If the key does not exist then nothing is done and a nil error is returned. +// Returns an error if the bucket was created from a read-only transaction. +func (b *Bucket) Delete(key []byte) error { + if b.tx.db == nil { + return ErrTxClosed + } else if !b.Writable() { + return ErrTxNotWritable + } + + // Move cursor to correct position. + c := b.Cursor() + k, _, flags := c.seek(key) + + // Return nil if the key doesn't exist. + if !bytes.Equal(key, k) { + return nil + } + + // Return an error if there is already existing bucket value. + if (flags & bucketLeafFlag) != 0 { + return ErrIncompatibleValue + } + + // Delete the node if we have a matching key. + c.node().del(key) + + return nil +} + +// Sequence returns the current integer for the bucket without incrementing it. +func (b *Bucket) Sequence() uint64 { return b.bucket.sequence } + +// SetSequence updates the sequence number for the bucket. +func (b *Bucket) SetSequence(v uint64) error { + if b.tx.db == nil { + return ErrTxClosed + } else if !b.Writable() { + return ErrTxNotWritable + } + + // Materialize the root node if it hasn't been already so that the + // bucket will be saved during commit. + if b.rootNode == nil { + _ = b.node(b.root, nil) + } + + // Increment and return the sequence. + b.bucket.sequence = v + return nil +} + +// NextSequence returns an autoincrementing integer for the bucket. +func (b *Bucket) NextSequence() (uint64, error) { + if b.tx.db == nil { + return 0, ErrTxClosed + } else if !b.Writable() { + return 0, ErrTxNotWritable + } + + // Materialize the root node if it hasn't been already so that the + // bucket will be saved during commit. + if b.rootNode == nil { + _ = b.node(b.root, nil) + } + + // Increment and return the sequence. + b.bucket.sequence++ + return b.bucket.sequence, nil +} + +// ForEach executes a function for each key/value pair in a bucket. +// If the provided function returns an error then the iteration is stopped and +// the error is returned to the caller. The provided function must not modify +// the bucket; this will result in undefined behavior. +func (b *Bucket) ForEach(fn func(k, v []byte) error) error { + if b.tx.db == nil { + return ErrTxClosed + } + c := b.Cursor() + for k, v := c.First(); k != nil; k, v = c.Next() { + if err := fn(k, v); err != nil { + return err + } + } + return nil +} + +// Stat returns stats on a bucket. +func (b *Bucket) Stats() BucketStats { + var s, subStats BucketStats + pageSize := b.tx.db.pageSize + s.BucketN += 1 + if b.root == 0 { + s.InlineBucketN += 1 + } + b.forEachPage(func(p *page, depth int) { + if (p.flags & leafPageFlag) != 0 { + s.KeyN += int(p.count) + + // used totals the used bytes for the page + used := pageHeaderSize + + if p.count != 0 { + // If page has any elements, add all element headers. + used += leafPageElementSize * uintptr(p.count-1) + + // Add all element key, value sizes. + // The computation takes advantage of the fact that the position + // of the last element's key/value equals to the total of the sizes + // of all previous elements' keys and values. + // It also includes the last element's header. + lastElement := p.leafPageElement(p.count - 1) + used += uintptr(lastElement.pos + lastElement.ksize + lastElement.vsize) + } + + if b.root == 0 { + // For inlined bucket just update the inline stats + s.InlineBucketInuse += int(used) + } else { + // For non-inlined bucket update all the leaf stats + s.LeafPageN++ + s.LeafInuse += int(used) + s.LeafOverflowN += int(p.overflow) + + // Collect stats from sub-buckets. + // Do that by iterating over all element headers + // looking for the ones with the bucketLeafFlag. + for i := uint16(0); i < p.count; i++ { + e := p.leafPageElement(i) + if (e.flags & bucketLeafFlag) != 0 { + // For any bucket element, open the element value + // and recursively call Stats on the contained bucket. + subStats.Add(b.openBucket(e.value()).Stats()) + } + } + } + } else if (p.flags & branchPageFlag) != 0 { + s.BranchPageN++ + lastElement := p.branchPageElement(p.count - 1) + + // used totals the used bytes for the page + // Add header and all element headers. + used := pageHeaderSize + (branchPageElementSize * uintptr(p.count-1)) + + // Add size of all keys and values. + // Again, use the fact that last element's position equals to + // the total of key, value sizes of all previous elements. + used += uintptr(lastElement.pos + lastElement.ksize) + s.BranchInuse += int(used) + s.BranchOverflowN += int(p.overflow) + } + + // Keep track of maximum page depth. + if depth+1 > s.Depth { + s.Depth = (depth + 1) + } + }) + + // Alloc stats can be computed from page counts and pageSize. + s.BranchAlloc = (s.BranchPageN + s.BranchOverflowN) * pageSize + s.LeafAlloc = (s.LeafPageN + s.LeafOverflowN) * pageSize + + // Add the max depth of sub-buckets to get total nested depth. + s.Depth += subStats.Depth + // Add the stats for all sub-buckets + s.Add(subStats) + return s +} + +// forEachPage iterates over every page in a bucket, including inline pages. +func (b *Bucket) forEachPage(fn func(*page, int)) { + // If we have an inline page then just use that. + if b.page != nil { + fn(b.page, 0) + return + } + + // Otherwise traverse the page hierarchy. + b.tx.forEachPage(b.root, 0, fn) +} + +// forEachPageNode iterates over every page (or node) in a bucket. +// This also includes inline pages. +func (b *Bucket) forEachPageNode(fn func(*page, *node, int)) { + // If we have an inline page or root node then just use that. + if b.page != nil { + fn(b.page, nil, 0) + return + } + b._forEachPageNode(b.root, 0, fn) +} + +func (b *Bucket) _forEachPageNode(pgid pgid, depth int, fn func(*page, *node, int)) { + var p, n = b.pageNode(pgid) + + // Execute function. + fn(p, n, depth) + + // Recursively loop over children. + if p != nil { + if (p.flags & branchPageFlag) != 0 { + for i := 0; i < int(p.count); i++ { + elem := p.branchPageElement(uint16(i)) + b._forEachPageNode(elem.pgid, depth+1, fn) + } + } + } else { + if !n.isLeaf { + for _, inode := range n.inodes { + b._forEachPageNode(inode.pgid, depth+1, fn) + } + } + } +} + +// spill writes all the nodes for this bucket to dirty pages. +func (b *Bucket) spill() error { + // Spill all child buckets first. + for name, child := range b.buckets { + // If the child bucket is small enough and it has no child buckets then + // write it inline into the parent bucket's page. Otherwise spill it + // like a normal bucket and make the parent value a pointer to the page. + var value []byte + if child.inlineable() { + child.free() + value = child.write() + } else { + if err := child.spill(); err != nil { + return err + } + + // Update the child bucket header in this bucket. + value = make([]byte, unsafe.Sizeof(bucket{})) + var bucket = (*bucket)(unsafe.Pointer(&value[0])) + *bucket = *child.bucket + } + + // Skip writing the bucket if there are no materialized nodes. + if child.rootNode == nil { + continue + } + + // Update parent node. + var c = b.Cursor() + k, _, flags := c.seek([]byte(name)) + if !bytes.Equal([]byte(name), k) { + panic(fmt.Sprintf("misplaced bucket header: %x -> %x", []byte(name), k)) + } + if flags&bucketLeafFlag == 0 { + panic(fmt.Sprintf("unexpected bucket header flag: %x", flags)) + } + c.node().put([]byte(name), []byte(name), value, 0, bucketLeafFlag) + } + + // Ignore if there's not a materialized root node. + if b.rootNode == nil { + return nil + } + + // Spill nodes. + if err := b.rootNode.spill(); err != nil { + return err + } + b.rootNode = b.rootNode.root() + + // Update the root node for this bucket. + if b.rootNode.pgid >= b.tx.meta.pgid { + panic(fmt.Sprintf("pgid (%d) above high water mark (%d)", b.rootNode.pgid, b.tx.meta.pgid)) + } + b.root = b.rootNode.pgid + + return nil +} + +// inlineable returns true if a bucket is small enough to be written inline +// and if it contains no subbuckets. Otherwise returns false. +func (b *Bucket) inlineable() bool { + var n = b.rootNode + + // Bucket must only contain a single leaf node. + if n == nil || !n.isLeaf { + return false + } + + // Bucket is not inlineable if it contains subbuckets or if it goes beyond + // our threshold for inline bucket size. + var size = pageHeaderSize + for _, inode := range n.inodes { + size += leafPageElementSize + uintptr(len(inode.key)) + uintptr(len(inode.value)) + + if inode.flags&bucketLeafFlag != 0 { + return false + } else if size > b.maxInlineBucketSize() { + return false + } + } + + return true +} + +// Returns the maximum total size of a bucket to make it a candidate for inlining. +func (b *Bucket) maxInlineBucketSize() uintptr { + return uintptr(b.tx.db.pageSize / 4) +} + +// write allocates and writes a bucket to a byte slice. +func (b *Bucket) write() []byte { + // Allocate the appropriate size. + var n = b.rootNode + var value = make([]byte, bucketHeaderSize+n.size()) + + // Write a bucket header. + var bucket = (*bucket)(unsafe.Pointer(&value[0])) + *bucket = *b.bucket + + // Convert byte slice to a fake page and write the root node. + var p = (*page)(unsafe.Pointer(&value[bucketHeaderSize])) + n.write(p) + + return value +} + +// rebalance attempts to balance all nodes. +func (b *Bucket) rebalance() { + for _, n := range b.nodes { + n.rebalance() + } + for _, child := range b.buckets { + child.rebalance() + } +} + +// node creates a node from a page and associates it with a given parent. +func (b *Bucket) node(pgid pgid, parent *node) *node { + _assert(b.nodes != nil, "nodes map expected") + + // Retrieve node if it's already been created. + if n := b.nodes[pgid]; n != nil { + return n + } + + // Otherwise create a node and cache it. + n := &node{bucket: b, parent: parent} + if parent == nil { + b.rootNode = n + } else { + parent.children = append(parent.children, n) + } + + // Use the inline page if this is an inline bucket. + var p = b.page + if p == nil { + p = b.tx.page(pgid) + } + + // Read the page into the node and cache it. + n.read(p) + b.nodes[pgid] = n + + // Update statistics. + b.tx.stats.NodeCount++ + + return n +} + +// free recursively frees all pages in the bucket. +func (b *Bucket) free() { + if b.root == 0 { + return + } + + var tx = b.tx + b.forEachPageNode(func(p *page, n *node, _ int) { + if p != nil { + tx.db.freelist.free(tx.meta.txid, p) + } else { + n.free() + } + }) + b.root = 0 +} + +// dereference removes all references to the old mmap. +func (b *Bucket) dereference() { + if b.rootNode != nil { + b.rootNode.root().dereference() + } + + for _, child := range b.buckets { + child.dereference() + } +} + +// pageNode returns the in-memory node, if it exists. +// Otherwise returns the underlying page. +func (b *Bucket) pageNode(id pgid) (*page, *node) { + // Inline buckets have a fake page embedded in their value so treat them + // differently. We'll return the rootNode (if available) or the fake page. + if b.root == 0 { + if id != 0 { + panic(fmt.Sprintf("inline bucket non-zero page access(2): %d != 0", id)) + } + if b.rootNode != nil { + return nil, b.rootNode + } + return b.page, nil + } + + // Check the node cache for non-inline buckets. + if b.nodes != nil { + if n := b.nodes[id]; n != nil { + return nil, n + } + } + + // Finally lookup the page from the transaction if no node is materialized. + return b.tx.page(id), nil +} + +// BucketStats records statistics about resources used by a bucket. +type BucketStats struct { + // Page count statistics. + BranchPageN int // number of logical branch pages + BranchOverflowN int // number of physical branch overflow pages + LeafPageN int // number of logical leaf pages + LeafOverflowN int // number of physical leaf overflow pages + + // Tree statistics. + KeyN int // number of keys/value pairs + Depth int // number of levels in B+tree + + // Page size utilization. + BranchAlloc int // bytes allocated for physical branch pages + BranchInuse int // bytes actually used for branch data + LeafAlloc int // bytes allocated for physical leaf pages + LeafInuse int // bytes actually used for leaf data + + // Bucket statistics + BucketN int // total number of buckets including the top bucket + InlineBucketN int // total number on inlined buckets + InlineBucketInuse int // bytes used for inlined buckets (also accounted for in LeafInuse) +} + +func (s *BucketStats) Add(other BucketStats) { + s.BranchPageN += other.BranchPageN + s.BranchOverflowN += other.BranchOverflowN + s.LeafPageN += other.LeafPageN + s.LeafOverflowN += other.LeafOverflowN + s.KeyN += other.KeyN + if s.Depth < other.Depth { + s.Depth = other.Depth + } + s.BranchAlloc += other.BranchAlloc + s.BranchInuse += other.BranchInuse + s.LeafAlloc += other.LeafAlloc + s.LeafInuse += other.LeafInuse + + s.BucketN += other.BucketN + s.InlineBucketN += other.InlineBucketN + s.InlineBucketInuse += other.InlineBucketInuse +} + +// cloneBytes returns a copy of a given slice. +func cloneBytes(v []byte) []byte { + var clone = make([]byte, len(v)) + copy(clone, v) + return clone +} diff --git a/vendor/etcd.io/bbolt/bucket_test.go b/vendor/etcd.io/bbolt/bucket_test.go new file mode 100644 index 0000000..e48204b --- /dev/null +++ b/vendor/etcd.io/bbolt/bucket_test.go @@ -0,0 +1,1959 @@ +package bbolt_test + +import ( + "bytes" + "encoding/binary" + "errors" + "fmt" + "log" + "math/rand" + "os" + "strconv" + "strings" + "testing" + "testing/quick" + + bolt "go.etcd.io/bbolt" +) + +// Ensure that a bucket that gets a non-existent key returns nil. +func TestBucket_Get_NonExistent(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if v := b.Get([]byte("foo")); v != nil { + t.Fatal("expected nil value") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can read a value that is not flushed yet. +func TestBucket_Get_FromNode(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if v := b.Get([]byte("foo")); !bytes.Equal(v, []byte("bar")) { + t.Fatalf("unexpected value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket retrieved via Get() returns a nil. +func TestBucket_Get_IncompatibleValue(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if _, err := tx.Bucket([]byte("widgets")).CreateBucket([]byte("foo")); err != nil { + t.Fatal(err) + } + + if tx.Bucket([]byte("widgets")).Get([]byte("foo")) != nil { + t.Fatal("expected nil value") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a slice returned from a bucket has a capacity equal to its length. +// This also allows slices to be appended to since it will require a realloc by Go. +// +// https://github.com/boltdb/bolt/issues/544 +func TestBucket_Get_Capacity(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + // Write key to a bucket. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("bucket")) + if err != nil { + return err + } + return b.Put([]byte("key"), []byte("val")) + }); err != nil { + t.Fatal(err) + } + + // Retrieve value and attempt to append to it. + if err := db.Update(func(tx *bolt.Tx) error { + k, v := tx.Bucket([]byte("bucket")).Cursor().First() + + // Verify capacity. + if len(k) != cap(k) { + t.Fatalf("unexpected key slice capacity: %d", cap(k)) + } else if len(v) != cap(v) { + t.Fatalf("unexpected value slice capacity: %d", cap(v)) + } + + // Ensure slice can be appended to without a segfault. + k = append(k, []byte("123")...) + v = append(v, []byte("123")...) + _, _ = k, v // to pass ineffassign + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can write a key/value. +func TestBucket_Put(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + + v := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + if !bytes.Equal([]byte("bar"), v) { + t.Fatalf("unexpected value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can rewrite a key in the same transaction. +func TestBucket_Put_Repeat(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("baz")); err != nil { + t.Fatal(err) + } + + value := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + if !bytes.Equal([]byte("baz"), value) { + t.Fatalf("unexpected value: %v", value) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can write a bunch of large values. +func TestBucket_Put_Large(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + count, factor := 100, 200 + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + for i := 1; i < count; i++ { + if err := b.Put([]byte(strings.Repeat("0", i*factor)), []byte(strings.Repeat("X", (count-i)*factor))); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for i := 1; i < count; i++ { + value := b.Get([]byte(strings.Repeat("0", i*factor))) + if !bytes.Equal(value, []byte(strings.Repeat("X", (count-i)*factor))) { + t.Fatalf("unexpected value: %v", value) + } + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a database can perform multiple large appends safely. +func TestDB_Put_VeryLarge(t *testing.T) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } + + n, batchN := 400000, 200000 + ksize, vsize := 8, 500 + + db := MustOpenDB() + defer db.MustClose() + + for i := 0; i < n; i += batchN { + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + for j := 0; j < batchN; j++ { + k, v := make([]byte, ksize), make([]byte, vsize) + binary.BigEndian.PutUint32(k, uint32(i+j)) + if err := b.Put(k, v); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + } +} + +// Ensure that a setting a value on a key with a bucket value returns an error. +func TestBucket_Put_IncompatibleValue(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b0, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if _, err := tx.Bucket([]byte("widgets")).CreateBucket([]byte("foo")); err != nil { + t.Fatal(err) + } + if err := b0.Put([]byte("foo"), []byte("bar")); err != bolt.ErrIncompatibleValue { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a setting a value while the transaction is closed returns an error. +func TestBucket_Put_Closed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + + if err := b.Put([]byte("foo"), []byte("bar")); err != bolt.ErrTxClosed { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that setting a value on a read-only bucket returns an error. +func TestBucket_Put_ReadOnly(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + if err := b.Put([]byte("foo"), []byte("bar")); err != bolt.ErrTxNotWritable { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can delete an existing key. +func TestBucket_Delete(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if err := b.Delete([]byte("foo")); err != nil { + t.Fatal(err) + } + if v := b.Get([]byte("foo")); v != nil { + t.Fatalf("unexpected value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that deleting a large set of keys will work correctly. +func TestBucket_Delete_Large(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + for i := 0; i < 100; i++ { + if err := b.Put([]byte(strconv.Itoa(i)), []byte(strings.Repeat("*", 1024))); err != nil { + t.Fatal(err) + } + } + + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for i := 0; i < 100; i++ { + if err := b.Delete([]byte(strconv.Itoa(i))); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for i := 0; i < 100; i++ { + if v := b.Get([]byte(strconv.Itoa(i))); v != nil { + t.Fatalf("unexpected value: %v, i=%d", v, i) + } + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Deleting a very large list of keys will cause the freelist to use overflow. +func TestBucket_Delete_FreelistOverflow(t *testing.T) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } + + db := MustOpenDB() + defer db.MustClose() + + k := make([]byte, 16) + for i := uint64(0); i < 10000; i++ { + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte("0")) + if err != nil { + t.Fatalf("bucket error: %s", err) + } + + for j := uint64(0); j < 1000; j++ { + binary.BigEndian.PutUint64(k[:8], i) + binary.BigEndian.PutUint64(k[8:], j) + if err := b.Put(k, nil); err != nil { + t.Fatalf("put error: %s", err) + } + } + + return nil + }); err != nil { + t.Fatal(err) + } + } + + // Delete all of them in one large transaction + if err := db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("0")) + c := b.Cursor() + for k, _ := c.First(); k != nil; k, _ = c.Next() { + if err := c.Delete(); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Check more than an overflow's worth of pages are freed. + stats := db.Stats() + freePages := stats.FreePageN + stats.PendingPageN + if freePages <= 0xFFFF { + t.Fatalf("expected more than 0xFFFF free pages, got %v", freePages) + } + + // Free page count should be preserved on reopen. + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + db.MustReopen() + if reopenFreePages := db.Stats().FreePageN; freePages != reopenFreePages { + t.Fatalf("expected %d free pages, got %+v", freePages, db.Stats()) + } +} + +// Ensure that deleting of non-existing key is a no-op. +func TestBucket_Delete_NonExisting(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if _, err = b.CreateBucket([]byte("nested")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + if err := b.Delete([]byte("foo")); err != nil { + t.Fatal(err) + } + if b.Bucket([]byte("nested")) == nil { + t.Fatal("nested bucket has been deleted") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that accessing and updating nested buckets is ok across transactions. +func TestBucket_Nested(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + // Create a widgets bucket. + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + // Create a widgets/foo bucket. + _, err = b.CreateBucket([]byte("foo")) + if err != nil { + t.Fatal(err) + } + + // Create a widgets/bar key. + if err := b.Put([]byte("bar"), []byte("0000")); err != nil { + t.Fatal(err) + } + + return nil + }); err != nil { + t.Fatal(err) + } + db.MustCheck() + + // Update widgets/bar. + if err := db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + if err := b.Put([]byte("bar"), []byte("xxxx")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + db.MustCheck() + + // Cause a split. + if err := db.Update(func(tx *bolt.Tx) error { + var b = tx.Bucket([]byte("widgets")) + for i := 0; i < 10000; i++ { + if err := b.Put([]byte(strconv.Itoa(i)), []byte(strconv.Itoa(i))); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + db.MustCheck() + + // Insert into widgets/foo/baz. + if err := db.Update(func(tx *bolt.Tx) error { + var b = tx.Bucket([]byte("widgets")) + if err := b.Bucket([]byte("foo")).Put([]byte("baz"), []byte("yyyy")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + db.MustCheck() + + // Verify. + if err := db.View(func(tx *bolt.Tx) error { + var b = tx.Bucket([]byte("widgets")) + if v := b.Bucket([]byte("foo")).Get([]byte("baz")); !bytes.Equal(v, []byte("yyyy")) { + t.Fatalf("unexpected value: %v", v) + } + if v := b.Get([]byte("bar")); !bytes.Equal(v, []byte("xxxx")) { + t.Fatalf("unexpected value: %v", v) + } + for i := 0; i < 10000; i++ { + if v := b.Get([]byte(strconv.Itoa(i))); !bytes.Equal(v, []byte(strconv.Itoa(i))) { + t.Fatalf("unexpected value: %v", v) + } + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that deleting a bucket using Delete() returns an error. +func TestBucket_Delete_Bucket(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if _, err := b.CreateBucket([]byte("foo")); err != nil { + t.Fatal(err) + } + if err := b.Delete([]byte("foo")); err != bolt.ErrIncompatibleValue { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that deleting a key on a read-only bucket returns an error. +func TestBucket_Delete_ReadOnly(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + if err := tx.Bucket([]byte("widgets")).Delete([]byte("foo")); err != bolt.ErrTxNotWritable { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a deleting value while the transaction is closed returns an error. +func TestBucket_Delete_Closed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + if err := b.Delete([]byte("foo")); err != bolt.ErrTxClosed { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that deleting a bucket causes nested buckets to be deleted. +func TestBucket_DeleteBucket_Nested(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + widgets, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + foo, err := widgets.CreateBucket([]byte("foo")) + if err != nil { + t.Fatal(err) + } + + bar, err := foo.CreateBucket([]byte("bar")) + if err != nil { + t.Fatal(err) + } + if err := bar.Put([]byte("baz"), []byte("bat")); err != nil { + t.Fatal(err) + } + if err := tx.Bucket([]byte("widgets")).DeleteBucket([]byte("foo")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that deleting a bucket causes nested buckets to be deleted after they have been committed. +func TestBucket_DeleteBucket_Nested2(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + widgets, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + foo, err := widgets.CreateBucket([]byte("foo")) + if err != nil { + t.Fatal(err) + } + + bar, err := foo.CreateBucket([]byte("bar")) + if err != nil { + t.Fatal(err) + } + + if err := bar.Put([]byte("baz"), []byte("bat")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + widgets := tx.Bucket([]byte("widgets")) + if widgets == nil { + t.Fatal("expected widgets bucket") + } + + foo := widgets.Bucket([]byte("foo")) + if foo == nil { + t.Fatal("expected foo bucket") + } + + bar := foo.Bucket([]byte("bar")) + if bar == nil { + t.Fatal("expected bar bucket") + } + + if v := bar.Get([]byte("baz")); !bytes.Equal(v, []byte("bat")) { + t.Fatalf("unexpected value: %v", v) + } + if err := tx.DeleteBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + if tx.Bucket([]byte("widgets")) != nil { + t.Fatal("expected bucket to be deleted") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that deleting a child bucket with multiple pages causes all pages to get collected. +// NOTE: Consistency check in bolt_test.DB.Close() will panic if pages not freed properly. +func TestBucket_DeleteBucket_Large(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + widgets, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + foo, err := widgets.CreateBucket([]byte("foo")) + if err != nil { + t.Fatal(err) + } + + for i := 0; i < 1000; i++ { + if err := foo.Put([]byte(fmt.Sprintf("%d", i)), []byte(fmt.Sprintf("%0100d", i))); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + if err := tx.DeleteBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a simple value retrieved via Bucket() returns a nil. +func TestBucket_Bucket_IncompatibleValue(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + widgets, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if err := widgets.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if b := tx.Bucket([]byte("widgets")).Bucket([]byte("foo")); b != nil { + t.Fatal("expected nil bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that creating a bucket on an existing non-bucket key returns an error. +func TestBucket_CreateBucket_IncompatibleValue(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + widgets, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if err := widgets.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if _, err := widgets.CreateBucket([]byte("foo")); err != bolt.ErrIncompatibleValue { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that deleting a bucket on an existing non-bucket key returns an error. +func TestBucket_DeleteBucket_IncompatibleValue(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + widgets, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := widgets.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if err := tx.Bucket([]byte("widgets")).DeleteBucket([]byte("foo")); err != bolt.ErrIncompatibleValue { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure bucket can set and update its sequence number. +func TestBucket_Sequence(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + bkt, err := tx.CreateBucket([]byte("0")) + if err != nil { + t.Fatal(err) + } + + // Retrieve sequence. + if v := bkt.Sequence(); v != 0 { + t.Fatalf("unexpected sequence: %d", v) + } + + // Update sequence. + if err := bkt.SetSequence(1000); err != nil { + t.Fatal(err) + } + + // Read sequence again. + if v := bkt.Sequence(); v != 1000 { + t.Fatalf("unexpected sequence: %d", v) + } + + return nil + }); err != nil { + t.Fatal(err) + } + + // Verify sequence in separate transaction. + if err := db.View(func(tx *bolt.Tx) error { + if v := tx.Bucket([]byte("0")).Sequence(); v != 1000 { + t.Fatalf("unexpected sequence: %d", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can return an autoincrementing sequence. +func TestBucket_NextSequence(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + widgets, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + woojits, err := tx.CreateBucket([]byte("woojits")) + if err != nil { + t.Fatal(err) + } + + // Make sure sequence increments. + if seq, err := widgets.NextSequence(); err != nil { + t.Fatal(err) + } else if seq != 1 { + t.Fatalf("unexpecte sequence: %d", seq) + } + + if seq, err := widgets.NextSequence(); err != nil { + t.Fatal(err) + } else if seq != 2 { + t.Fatalf("unexpected sequence: %d", seq) + } + + // Buckets should be separate. + if seq, err := woojits.NextSequence(); err != nil { + t.Fatal(err) + } else if seq != 1 { + t.Fatalf("unexpected sequence: %d", 1) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket will persist an autoincrementing sequence even if its +// the only thing updated on the bucket. +// https://github.com/boltdb/bolt/issues/296 +func TestBucket_NextSequence_Persist(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.Bucket([]byte("widgets")).NextSequence(); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + seq, err := tx.Bucket([]byte("widgets")).NextSequence() + if err != nil { + t.Fatalf("unexpected error: %s", err) + } else if seq != 2 { + t.Fatalf("unexpected sequence: %d", seq) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that retrieving the next sequence on a read-only bucket returns an error. +func TestBucket_NextSequence_ReadOnly(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + _, err := tx.Bucket([]byte("widgets")).NextSequence() + if err != bolt.ErrTxNotWritable { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that retrieving the next sequence for a bucket on a closed database return an error. +func TestBucket_NextSequence_Closed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + if _, err := b.NextSequence(); err != bolt.ErrTxClosed { + t.Fatal(err) + } +} + +// Ensure a user can loop over all key/value pairs in a bucket. +func TestBucket_ForEach(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("0000")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte("0001")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("bar"), []byte("0002")); err != nil { + t.Fatal(err) + } + + var index int + if err := b.ForEach(func(k, v []byte) error { + switch index { + case 0: + if !bytes.Equal(k, []byte("bar")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte("0002")) { + t.Fatalf("unexpected value: %v", v) + } + case 1: + if !bytes.Equal(k, []byte("baz")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte("0001")) { + t.Fatalf("unexpected value: %v", v) + } + case 2: + if !bytes.Equal(k, []byte("foo")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte("0000")) { + t.Fatalf("unexpected value: %v", v) + } + } + index++ + return nil + }); err != nil { + t.Fatal(err) + } + + if index != 3 { + t.Fatalf("unexpected index: %d", index) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a database can stop iteration early. +func TestBucket_ForEach_ShortCircuit(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("bar"), []byte("0000")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte("0000")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("0000")); err != nil { + t.Fatal(err) + } + + var index int + if err := tx.Bucket([]byte("widgets")).ForEach(func(k, v []byte) error { + index++ + if bytes.Equal(k, []byte("baz")) { + return errors.New("marker") + } + return nil + }); err == nil || err.Error() != "marker" { + t.Fatalf("unexpected error: %s", err) + } + if index != 2 { + t.Fatalf("unexpected index: %d", index) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that looping over a bucket on a closed database returns an error. +func TestBucket_ForEach_Closed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + + if err := b.ForEach(func(k, v []byte) error { return nil }); err != bolt.ErrTxClosed { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that an error is returned when inserting with an empty key. +func TestBucket_Put_EmptyKey(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte(""), []byte("bar")); err != bolt.ErrKeyRequired { + t.Fatalf("unexpected error: %s", err) + } + if err := b.Put(nil, []byte("bar")); err != bolt.ErrKeyRequired { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that an error is returned when inserting with a key that's too large. +func TestBucket_Put_KeyTooLarge(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put(make([]byte, 32769), []byte("bar")); err != bolt.ErrKeyTooLarge { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that an error is returned when inserting a value that's too large. +func TestBucket_Put_ValueTooLarge(t *testing.T) { + // Skip this test on DroneCI because the machine is resource constrained. + if os.Getenv("DRONE") == "true" { + t.Skip("not enough RAM for test") + } + + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), make([]byte, bolt.MaxValueSize+1)); err != bolt.ErrValueTooLarge { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a bucket can calculate stats. +func TestBucket_Stats(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + // Add bucket with fewer keys but one big value. + bigKey := []byte("really-big-value") + for i := 0; i < 500; i++ { + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte("woojits")) + if err != nil { + t.Fatal(err) + } + + if err := b.Put([]byte(fmt.Sprintf("%03d", i)), []byte(strconv.Itoa(i))); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + } + if err := db.Update(func(tx *bolt.Tx) error { + if err := tx.Bucket([]byte("woojits")).Put(bigKey, []byte(strings.Repeat("*", 10000))); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + db.MustCheck() + + if err := db.View(func(tx *bolt.Tx) error { + stats := tx.Bucket([]byte("woojits")).Stats() + if stats.BranchPageN != 1 { + t.Fatalf("unexpected BranchPageN: %d", stats.BranchPageN) + } else if stats.BranchOverflowN != 0 { + t.Fatalf("unexpected BranchOverflowN: %d", stats.BranchOverflowN) + } else if stats.LeafPageN != 7 { + t.Fatalf("unexpected LeafPageN: %d", stats.LeafPageN) + } else if stats.LeafOverflowN != 2 { + t.Fatalf("unexpected LeafOverflowN: %d", stats.LeafOverflowN) + } else if stats.KeyN != 501 { + t.Fatalf("unexpected KeyN: %d", stats.KeyN) + } else if stats.Depth != 2 { + t.Fatalf("unexpected Depth: %d", stats.Depth) + } + + branchInuse := 16 // branch page header + branchInuse += 7 * 16 // branch elements + branchInuse += 7 * 3 // branch keys (6 3-byte keys) + if stats.BranchInuse != branchInuse { + t.Fatalf("unexpected BranchInuse: %d", stats.BranchInuse) + } + + leafInuse := 7 * 16 // leaf page header + leafInuse += 501 * 16 // leaf elements + leafInuse += 500*3 + len(bigKey) // leaf keys + leafInuse += 1*10 + 2*90 + 3*400 + 10000 // leaf values + if stats.LeafInuse != leafInuse { + t.Fatalf("unexpected LeafInuse: %d", stats.LeafInuse) + } + + // Only check allocations for 4KB pages. + if db.Info().PageSize == 4096 { + if stats.BranchAlloc != 4096 { + t.Fatalf("unexpected BranchAlloc: %d", stats.BranchAlloc) + } else if stats.LeafAlloc != 36864 { + t.Fatalf("unexpected LeafAlloc: %d", stats.LeafAlloc) + } + } + + if stats.BucketN != 1 { + t.Fatalf("unexpected BucketN: %d", stats.BucketN) + } else if stats.InlineBucketN != 0 { + t.Fatalf("unexpected InlineBucketN: %d", stats.InlineBucketN) + } else if stats.InlineBucketInuse != 0 { + t.Fatalf("unexpected InlineBucketInuse: %d", stats.InlineBucketInuse) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a bucket with random insertion utilizes fill percentage correctly. +func TestBucket_Stats_RandomFill(t *testing.T) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } else if os.Getpagesize() != 4096 { + t.Skip("invalid page size for test") + } + + db := MustOpenDB() + defer db.MustClose() + + // Add a set of values in random order. It will be the same random + // order so we can maintain consistency between test runs. + var count int + rand := rand.New(rand.NewSource(42)) + for _, i := range rand.Perm(1000) { + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte("woojits")) + if err != nil { + t.Fatal(err) + } + b.FillPercent = 0.9 + for _, j := range rand.Perm(100) { + index := (j * 10000) + i + if err := b.Put([]byte(fmt.Sprintf("%d000000000000000", index)), []byte("0000000000")); err != nil { + t.Fatal(err) + } + count++ + } + return nil + }); err != nil { + t.Fatal(err) + } + } + + db.MustCheck() + + if err := db.View(func(tx *bolt.Tx) error { + stats := tx.Bucket([]byte("woojits")).Stats() + if stats.KeyN != 100000 { + t.Fatalf("unexpected KeyN: %d", stats.KeyN) + } + + if stats.BranchPageN != 98 { + t.Fatalf("unexpected BranchPageN: %d", stats.BranchPageN) + } else if stats.BranchOverflowN != 0 { + t.Fatalf("unexpected BranchOverflowN: %d", stats.BranchOverflowN) + } else if stats.BranchInuse != 130984 { + t.Fatalf("unexpected BranchInuse: %d", stats.BranchInuse) + } else if stats.BranchAlloc != 401408 { + t.Fatalf("unexpected BranchAlloc: %d", stats.BranchAlloc) + } + + if stats.LeafPageN != 3412 { + t.Fatalf("unexpected LeafPageN: %d", stats.LeafPageN) + } else if stats.LeafOverflowN != 0 { + t.Fatalf("unexpected LeafOverflowN: %d", stats.LeafOverflowN) + } else if stats.LeafInuse != 4742482 { + t.Fatalf("unexpected LeafInuse: %d", stats.LeafInuse) + } else if stats.LeafAlloc != 13975552 { + t.Fatalf("unexpected LeafAlloc: %d", stats.LeafAlloc) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a bucket can calculate stats. +func TestBucket_Stats_Small(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + // Add a bucket that fits on a single root leaf. + b, err := tx.CreateBucket([]byte("whozawhats")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + + return nil + }); err != nil { + t.Fatal(err) + } + + db.MustCheck() + + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("whozawhats")) + stats := b.Stats() + if stats.BranchPageN != 0 { + t.Fatalf("unexpected BranchPageN: %d", stats.BranchPageN) + } else if stats.BranchOverflowN != 0 { + t.Fatalf("unexpected BranchOverflowN: %d", stats.BranchOverflowN) + } else if stats.LeafPageN != 0 { + t.Fatalf("unexpected LeafPageN: %d", stats.LeafPageN) + } else if stats.LeafOverflowN != 0 { + t.Fatalf("unexpected LeafOverflowN: %d", stats.LeafOverflowN) + } else if stats.KeyN != 1 { + t.Fatalf("unexpected KeyN: %d", stats.KeyN) + } else if stats.Depth != 1 { + t.Fatalf("unexpected Depth: %d", stats.Depth) + } else if stats.BranchInuse != 0 { + t.Fatalf("unexpected BranchInuse: %d", stats.BranchInuse) + } else if stats.LeafInuse != 0 { + t.Fatalf("unexpected LeafInuse: %d", stats.LeafInuse) + } + + if db.Info().PageSize == 4096 { + if stats.BranchAlloc != 0 { + t.Fatalf("unexpected BranchAlloc: %d", stats.BranchAlloc) + } else if stats.LeafAlloc != 0 { + t.Fatalf("unexpected LeafAlloc: %d", stats.LeafAlloc) + } + } + + if stats.BucketN != 1 { + t.Fatalf("unexpected BucketN: %d", stats.BucketN) + } else if stats.InlineBucketN != 1 { + t.Fatalf("unexpected InlineBucketN: %d", stats.InlineBucketN) + } else if stats.InlineBucketInuse != 16+16+6 { + t.Fatalf("unexpected InlineBucketInuse: %d", stats.InlineBucketInuse) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +func TestBucket_Stats_EmptyBucket(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + // Add a bucket that fits on a single root leaf. + if _, err := tx.CreateBucket([]byte("whozawhats")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + db.MustCheck() + + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("whozawhats")) + stats := b.Stats() + if stats.BranchPageN != 0 { + t.Fatalf("unexpected BranchPageN: %d", stats.BranchPageN) + } else if stats.BranchOverflowN != 0 { + t.Fatalf("unexpected BranchOverflowN: %d", stats.BranchOverflowN) + } else if stats.LeafPageN != 0 { + t.Fatalf("unexpected LeafPageN: %d", stats.LeafPageN) + } else if stats.LeafOverflowN != 0 { + t.Fatalf("unexpected LeafOverflowN: %d", stats.LeafOverflowN) + } else if stats.KeyN != 0 { + t.Fatalf("unexpected KeyN: %d", stats.KeyN) + } else if stats.Depth != 1 { + t.Fatalf("unexpected Depth: %d", stats.Depth) + } else if stats.BranchInuse != 0 { + t.Fatalf("unexpected BranchInuse: %d", stats.BranchInuse) + } else if stats.LeafInuse != 0 { + t.Fatalf("unexpected LeafInuse: %d", stats.LeafInuse) + } + + if db.Info().PageSize == 4096 { + if stats.BranchAlloc != 0 { + t.Fatalf("unexpected BranchAlloc: %d", stats.BranchAlloc) + } else if stats.LeafAlloc != 0 { + t.Fatalf("unexpected LeafAlloc: %d", stats.LeafAlloc) + } + } + + if stats.BucketN != 1 { + t.Fatalf("unexpected BucketN: %d", stats.BucketN) + } else if stats.InlineBucketN != 1 { + t.Fatalf("unexpected InlineBucketN: %d", stats.InlineBucketN) + } else if stats.InlineBucketInuse != 16 { + t.Fatalf("unexpected InlineBucketInuse: %d", stats.InlineBucketInuse) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a bucket can calculate stats. +func TestBucket_Stats_Nested(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("foo")) + if err != nil { + t.Fatal(err) + } + for i := 0; i < 100; i++ { + if err := b.Put([]byte(fmt.Sprintf("%02d", i)), []byte(fmt.Sprintf("%02d", i))); err != nil { + t.Fatal(err) + } + } + + bar, err := b.CreateBucket([]byte("bar")) + if err != nil { + t.Fatal(err) + } + for i := 0; i < 10; i++ { + if err := bar.Put([]byte(strconv.Itoa(i)), []byte(strconv.Itoa(i))); err != nil { + t.Fatal(err) + } + } + + baz, err := bar.CreateBucket([]byte("baz")) + if err != nil { + t.Fatal(err) + } + for i := 0; i < 10; i++ { + if err := baz.Put([]byte(strconv.Itoa(i)), []byte(strconv.Itoa(i))); err != nil { + t.Fatal(err) + } + } + + return nil + }); err != nil { + t.Fatal(err) + } + + db.MustCheck() + + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("foo")) + stats := b.Stats() + if stats.BranchPageN != 0 { + t.Fatalf("unexpected BranchPageN: %d", stats.BranchPageN) + } else if stats.BranchOverflowN != 0 { + t.Fatalf("unexpected BranchOverflowN: %d", stats.BranchOverflowN) + } else if stats.LeafPageN != 2 { + t.Fatalf("unexpected LeafPageN: %d", stats.LeafPageN) + } else if stats.LeafOverflowN != 0 { + t.Fatalf("unexpected LeafOverflowN: %d", stats.LeafOverflowN) + } else if stats.KeyN != 122 { + t.Fatalf("unexpected KeyN: %d", stats.KeyN) + } else if stats.Depth != 3 { + t.Fatalf("unexpected Depth: %d", stats.Depth) + } else if stats.BranchInuse != 0 { + t.Fatalf("unexpected BranchInuse: %d", stats.BranchInuse) + } + + foo := 16 // foo (pghdr) + foo += 101 * 16 // foo leaf elements + foo += 100*2 + 100*2 // foo leaf key/values + foo += 3 + 16 // foo -> bar key/value + + bar := 16 // bar (pghdr) + bar += 11 * 16 // bar leaf elements + bar += 10 + 10 // bar leaf key/values + bar += 3 + 16 // bar -> baz key/value + + baz := 16 // baz (inline) (pghdr) + baz += 10 * 16 // baz leaf elements + baz += 10 + 10 // baz leaf key/values + + if stats.LeafInuse != foo+bar+baz { + t.Fatalf("unexpected LeafInuse: %d", stats.LeafInuse) + } + + if db.Info().PageSize == 4096 { + if stats.BranchAlloc != 0 { + t.Fatalf("unexpected BranchAlloc: %d", stats.BranchAlloc) + } else if stats.LeafAlloc != 8192 { + t.Fatalf("unexpected LeafAlloc: %d", stats.LeafAlloc) + } + } + + if stats.BucketN != 3 { + t.Fatalf("unexpected BucketN: %d", stats.BucketN) + } else if stats.InlineBucketN != 1 { + t.Fatalf("unexpected InlineBucketN: %d", stats.InlineBucketN) + } else if stats.InlineBucketInuse != baz { + t.Fatalf("unexpected InlineBucketInuse: %d", stats.InlineBucketInuse) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a large bucket can calculate stats. +func TestBucket_Stats_Large(t *testing.T) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } + + db := MustOpenDB() + defer db.MustClose() + + var index int + for i := 0; i < 100; i++ { + // Add bucket with lots of keys. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + for i := 0; i < 1000; i++ { + if err := b.Put([]byte(strconv.Itoa(index)), []byte(strconv.Itoa(index))); err != nil { + t.Fatal(err) + } + index++ + } + return nil + }); err != nil { + t.Fatal(err) + } + } + + db.MustCheck() + + if err := db.View(func(tx *bolt.Tx) error { + stats := tx.Bucket([]byte("widgets")).Stats() + if stats.BranchPageN != 13 { + t.Fatalf("unexpected BranchPageN: %d", stats.BranchPageN) + } else if stats.BranchOverflowN != 0 { + t.Fatalf("unexpected BranchOverflowN: %d", stats.BranchOverflowN) + } else if stats.LeafPageN != 1196 { + t.Fatalf("unexpected LeafPageN: %d", stats.LeafPageN) + } else if stats.LeafOverflowN != 0 { + t.Fatalf("unexpected LeafOverflowN: %d", stats.LeafOverflowN) + } else if stats.KeyN != 100000 { + t.Fatalf("unexpected KeyN: %d", stats.KeyN) + } else if stats.Depth != 3 { + t.Fatalf("unexpected Depth: %d", stats.Depth) + } else if stats.BranchInuse != 25257 { + t.Fatalf("unexpected BranchInuse: %d", stats.BranchInuse) + } else if stats.LeafInuse != 2596916 { + t.Fatalf("unexpected LeafInuse: %d", stats.LeafInuse) + } + + if db.Info().PageSize == 4096 { + if stats.BranchAlloc != 53248 { + t.Fatalf("unexpected BranchAlloc: %d", stats.BranchAlloc) + } else if stats.LeafAlloc != 4898816 { + t.Fatalf("unexpected LeafAlloc: %d", stats.LeafAlloc) + } + } + + if stats.BucketN != 1 { + t.Fatalf("unexpected BucketN: %d", stats.BucketN) + } else if stats.InlineBucketN != 0 { + t.Fatalf("unexpected InlineBucketN: %d", stats.InlineBucketN) + } else if stats.InlineBucketInuse != 0 { + t.Fatalf("unexpected InlineBucketInuse: %d", stats.InlineBucketInuse) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can write random keys and values across multiple transactions. +func TestBucket_Put_Single(t *testing.T) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } + + index := 0 + if err := quick.Check(func(items testdata) bool { + db := MustOpenDB() + defer db.MustClose() + + m := make(map[string][]byte) + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + for _, item := range items { + if err := db.Update(func(tx *bolt.Tx) error { + if err := tx.Bucket([]byte("widgets")).Put(item.Key, item.Value); err != nil { + panic("put error: " + err.Error()) + } + m[string(item.Key)] = item.Value + return nil + }); err != nil { + t.Fatal(err) + } + + // Verify all key/values so far. + if err := db.View(func(tx *bolt.Tx) error { + i := 0 + for k, v := range m { + value := tx.Bucket([]byte("widgets")).Get([]byte(k)) + if !bytes.Equal(value, v) { + t.Logf("value mismatch [run %d] (%d of %d):\nkey: %x\ngot: %x\nexp: %x", index, i, len(m), []byte(k), value, v) + db.CopyTempFile() + t.FailNow() + } + i++ + } + return nil + }); err != nil { + t.Fatal(err) + } + } + + index++ + return true + }, qconfig()); err != nil { + t.Error(err) + } +} + +// Ensure that a transaction can insert multiple key/value pairs at once. +func TestBucket_Put_Multiple(t *testing.T) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } + + if err := quick.Check(func(items testdata) bool { + db := MustOpenDB() + defer db.MustClose() + + // Bulk insert all values. + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for _, item := range items { + if err := b.Put(item.Key, item.Value); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Verify all items exist. + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for _, item := range items { + value := b.Get(item.Key) + if !bytes.Equal(item.Value, value) { + db.CopyTempFile() + t.Fatalf("exp=%x; got=%x", item.Value, value) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + return true + }, qconfig()); err != nil { + t.Error(err) + } +} + +// Ensure that a transaction can delete all key/value pairs and return to a single leaf page. +func TestBucket_Delete_Quick(t *testing.T) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } + + if err := quick.Check(func(items testdata) bool { + db := MustOpenDB() + defer db.MustClose() + + // Bulk insert all values. + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for _, item := range items { + if err := b.Put(item.Key, item.Value); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Remove items one at a time and check consistency. + for _, item := range items { + if err := db.Update(func(tx *bolt.Tx) error { + return tx.Bucket([]byte("widgets")).Delete(item.Key) + }); err != nil { + t.Fatal(err) + } + } + + // Anything before our deletion index should be nil. + if err := db.View(func(tx *bolt.Tx) error { + if err := tx.Bucket([]byte("widgets")).ForEach(func(k, v []byte) error { + t.Fatalf("bucket should be empty; found: %06x", trunc(k, 3)) + return nil + }); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + return true + }, qconfig()); err != nil { + t.Error(err) + } +} + +func ExampleBucket_Put() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Start a write transaction. + if err := db.Update(func(tx *bolt.Tx) error { + // Create a bucket. + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + return err + } + + // Set the value "bar" for the key "foo". + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + return err + } + return nil + }); err != nil { + log.Fatal(err) + } + + // Read value back in a different read-only transaction. + if err := db.View(func(tx *bolt.Tx) error { + value := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + fmt.Printf("The value of 'foo' is: %s\n", value) + return nil + }); err != nil { + log.Fatal(err) + } + + // Close database to release file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // The value of 'foo' is: bar +} + +func ExampleBucket_Delete() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Start a write transaction. + if err := db.Update(func(tx *bolt.Tx) error { + // Create a bucket. + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + return err + } + + // Set the value "bar" for the key "foo". + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + return err + } + + // Retrieve the key back from the database and verify it. + value := b.Get([]byte("foo")) + fmt.Printf("The value of 'foo' was: %s\n", value) + + return nil + }); err != nil { + log.Fatal(err) + } + + // Delete the key in a different write transaction. + if err := db.Update(func(tx *bolt.Tx) error { + return tx.Bucket([]byte("widgets")).Delete([]byte("foo")) + }); err != nil { + log.Fatal(err) + } + + // Retrieve the key again. + if err := db.View(func(tx *bolt.Tx) error { + value := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + if value == nil { + fmt.Printf("The value of 'foo' is now: nil\n") + } + return nil + }); err != nil { + log.Fatal(err) + } + + // Close database to release file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // The value of 'foo' was: bar + // The value of 'foo' is now: nil +} + +func ExampleBucket_ForEach() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Insert data into a bucket. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("animals")) + if err != nil { + return err + } + + if err := b.Put([]byte("dog"), []byte("fun")); err != nil { + return err + } + if err := b.Put([]byte("cat"), []byte("lame")); err != nil { + return err + } + if err := b.Put([]byte("liger"), []byte("awesome")); err != nil { + return err + } + + // Iterate over items in sorted key order. + if err := b.ForEach(func(k, v []byte) error { + fmt.Printf("A %s is %s.\n", k, v) + return nil + }); err != nil { + return err + } + + return nil + }); err != nil { + log.Fatal(err) + } + + // Close database to release file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // A cat is lame. + // A dog is fun. + // A liger is awesome. +} diff --git a/vendor/etcd.io/bbolt/cmd/bbolt/main.go b/vendor/etcd.io/bbolt/cmd/bbolt/main.go new file mode 100644 index 0000000..91a13bc --- /dev/null +++ b/vendor/etcd.io/bbolt/cmd/bbolt/main.go @@ -0,0 +1,2136 @@ +package main + +import ( + "bytes" + "encoding/binary" + "errors" + "flag" + "fmt" + "io" + "io/ioutil" + "math/rand" + "os" + "runtime" + "runtime/pprof" + "strconv" + "strings" + "time" + "unicode" + "unicode/utf8" + "unsafe" + + bolt "go.etcd.io/bbolt" +) + +var ( + // ErrUsage is returned when a usage message was printed and the process + // should simply exit with an error. + ErrUsage = errors.New("usage") + + // ErrUnknownCommand is returned when a CLI command is not specified. + ErrUnknownCommand = errors.New("unknown command") + + // ErrPathRequired is returned when the path to a Bolt database is not specified. + ErrPathRequired = errors.New("path required") + + // ErrFileNotFound is returned when a Bolt database does not exist. + ErrFileNotFound = errors.New("file not found") + + // ErrInvalidValue is returned when a benchmark reads an unexpected value. + ErrInvalidValue = errors.New("invalid value") + + // ErrCorrupt is returned when a checking a data file finds errors. + ErrCorrupt = errors.New("invalid value") + + // ErrNonDivisibleBatchSize is returned when the batch size can't be evenly + // divided by the iteration count. + ErrNonDivisibleBatchSize = errors.New("number of iterations must be divisible by the batch size") + + // ErrPageIDRequired is returned when a required page id is not specified. + ErrPageIDRequired = errors.New("page id required") + + // ErrBucketRequired is returned when a bucket is not specified. + ErrBucketRequired = errors.New("bucket required") + + // ErrBucketNotFound is returned when a bucket is not found. + ErrBucketNotFound = errors.New("bucket not found") + + // ErrKeyRequired is returned when a key is not specified. + ErrKeyRequired = errors.New("key required") + + // ErrKeyNotFound is returned when a key is not found. + ErrKeyNotFound = errors.New("key not found") +) + +// PageHeaderSize represents the size of the bolt.page header. +const PageHeaderSize = 16 + +func main() { + m := NewMain() + if err := m.Run(os.Args[1:]...); err == ErrUsage { + os.Exit(2) + } else if err != nil { + fmt.Println(err.Error()) + os.Exit(1) + } +} + +// Main represents the main program execution. +type Main struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewMain returns a new instance of Main connect to the standard input/output. +func NewMain() *Main { + return &Main{ + Stdin: os.Stdin, + Stdout: os.Stdout, + Stderr: os.Stderr, + } +} + +// Run executes the program. +func (m *Main) Run(args ...string) error { + // Require a command at the beginning. + if len(args) == 0 || strings.HasPrefix(args[0], "-") { + fmt.Fprintln(m.Stderr, m.Usage()) + return ErrUsage + } + + // Execute command. + switch args[0] { + case "help": + fmt.Fprintln(m.Stderr, m.Usage()) + return ErrUsage + case "bench": + return newBenchCommand(m).Run(args[1:]...) + case "buckets": + return newBucketsCommand(m).Run(args[1:]...) + case "check": + return newCheckCommand(m).Run(args[1:]...) + case "compact": + return newCompactCommand(m).Run(args[1:]...) + case "dump": + return newDumpCommand(m).Run(args[1:]...) + case "page-item": + return newPageItemCommand(m).Run(args[1:]...) + case "get": + return newGetCommand(m).Run(args[1:]...) + case "info": + return newInfoCommand(m).Run(args[1:]...) + case "keys": + return newKeysCommand(m).Run(args[1:]...) + case "page": + return newPageCommand(m).Run(args[1:]...) + case "pages": + return newPagesCommand(m).Run(args[1:]...) + case "stats": + return newStatsCommand(m).Run(args[1:]...) + default: + return ErrUnknownCommand + } +} + +// Usage returns the help message. +func (m *Main) Usage() string { + return strings.TrimLeft(` +Bolt is a tool for inspecting bolt databases. + +Usage: + + bolt command [arguments] + +The commands are: + + bench run synthetic benchmark against bolt + buckets print a list of buckets + check verifies integrity of bolt database + compact copies a bolt database, compacting it in the process + dump print a hexadecimal dump of a single page + get print the value of a key in a bucket + info print basic info + keys print a list of keys in a bucket + help print this screen + page print one or more pages in human readable format + pages print list of pages with their types + page-item print the key and value of a page item. + stats iterate over all pages and generate usage stats + +Use "bolt [command] -h" for more information about a command. +`, "\n") +} + +// CheckCommand represents the "check" command execution. +type CheckCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewCheckCommand returns a CheckCommand. +func newCheckCommand(m *Main) *CheckCommand { + return &CheckCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *CheckCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path. + path := fs.Arg(0) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Open database. + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return err + } + defer db.Close() + + // Perform consistency check. + return db.View(func(tx *bolt.Tx) error { + var count int + for err := range tx.Check() { + fmt.Fprintln(cmd.Stdout, err) + count++ + } + + // Print summary of errors. + if count > 0 { + fmt.Fprintf(cmd.Stdout, "%d errors found\n", count) + return ErrCorrupt + } + + // Notify user that database is valid. + fmt.Fprintln(cmd.Stdout, "OK") + return nil + }) +} + +// Usage returns the help message. +func (cmd *CheckCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt check PATH + +Check opens a database at PATH and runs an exhaustive check to verify that +all pages are accessible or are marked as freed. It also verifies that no +pages are double referenced. + +Verification errors will stream out as they are found and the process will +return after all pages have been checked. +`, "\n") +} + +// InfoCommand represents the "info" command execution. +type InfoCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewInfoCommand returns a InfoCommand. +func newInfoCommand(m *Main) *InfoCommand { + return &InfoCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *InfoCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path. + path := fs.Arg(0) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Open the database. + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return err + } + defer db.Close() + + // Print basic database info. + info := db.Info() + fmt.Fprintf(cmd.Stdout, "Page Size: %d\n", info.PageSize) + + return nil +} + +// Usage returns the help message. +func (cmd *InfoCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt info PATH + +Info prints basic information about the Bolt database at PATH. +`, "\n") +} + +// DumpCommand represents the "dump" command execution. +type DumpCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// newDumpCommand returns a DumpCommand. +func newDumpCommand(m *Main) *DumpCommand { + return &DumpCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *DumpCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path and page id. + path := fs.Arg(0) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Read page ids. + pageIDs, err := atois(fs.Args()[1:]) + if err != nil { + return err + } else if len(pageIDs) == 0 { + return ErrPageIDRequired + } + + // Open database to retrieve page size. + pageSize, err := ReadPageSize(path) + if err != nil { + return err + } + + // Open database file handler. + f, err := os.Open(path) + if err != nil { + return err + } + defer func() { _ = f.Close() }() + + // Print each page listed. + for i, pageID := range pageIDs { + // Print a separator. + if i > 0 { + fmt.Fprintln(cmd.Stdout, "===============================================") + } + + // Print page to stdout. + if err := cmd.PrintPage(cmd.Stdout, f, pageID, pageSize); err != nil { + return err + } + } + + return nil +} + +// PrintPage prints a given page as hexadecimal. +func (cmd *DumpCommand) PrintPage(w io.Writer, r io.ReaderAt, pageID int, pageSize int) error { + const bytesPerLineN = 16 + + // Read page into buffer. + buf := make([]byte, pageSize) + addr := pageID * pageSize + if n, err := r.ReadAt(buf, int64(addr)); err != nil { + return err + } else if n != pageSize { + return io.ErrUnexpectedEOF + } + + // Write out to writer in 16-byte lines. + var prev []byte + var skipped bool + for offset := 0; offset < pageSize; offset += bytesPerLineN { + // Retrieve current 16-byte line. + line := buf[offset : offset+bytesPerLineN] + isLastLine := (offset == (pageSize - bytesPerLineN)) + + // If it's the same as the previous line then print a skip. + if bytes.Equal(line, prev) && !isLastLine { + if !skipped { + fmt.Fprintf(w, "%07x *\n", addr+offset) + skipped = true + } + } else { + // Print line as hexadecimal in 2-byte groups. + fmt.Fprintf(w, "%07x %04x %04x %04x %04x %04x %04x %04x %04x\n", addr+offset, + line[0:2], line[2:4], line[4:6], line[6:8], + line[8:10], line[10:12], line[12:14], line[14:16], + ) + + skipped = false + } + + // Save the previous line. + prev = line + } + fmt.Fprint(w, "\n") + + return nil +} + +// Usage returns the help message. +func (cmd *DumpCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt dump PATH pageid [pageid...] + +Dump prints a hexadecimal dump of one or more pages. +`, "\n") +} + +// PageItemCommand represents the "page-item" command execution. +type PageItemCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// newPageItemCommand returns a PageItemCommand. +func newPageItemCommand(m *Main) *PageItemCommand { + return &PageItemCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +type pageItemOptions struct { + help bool + keyOnly bool + valueOnly bool + format string +} + +// Run executes the command. +func (cmd *PageItemCommand) Run(args ...string) error { + // Parse flags. + options := &pageItemOptions{} + fs := flag.NewFlagSet("", flag.ContinueOnError) + fs.BoolVar(&options.keyOnly, "key-only", false, "Print only the key") + fs.BoolVar(&options.valueOnly, "value-only", false, "Print only the value") + fs.StringVar(&options.format, "format", "ascii-encoded", "Output format. One of: ascii-encoded|hex|bytes") + fs.BoolVar(&options.help, "h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if options.help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + if options.keyOnly && options.valueOnly { + return fmt.Errorf("The --key-only or --value-only flag may be set, but not both.") + } + + // Require database path and page id. + path := fs.Arg(0) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Read page id. + pageID, err := strconv.Atoi(fs.Arg(1)) + if err != nil { + return err + } + + // Read item id. + itemID, err := strconv.Atoi(fs.Arg(2)) + if err != nil { + return err + } + + // Open database file handler. + f, err := os.Open(path) + if err != nil { + return err + } + defer func() { _ = f.Close() }() + + // Retrieve page info and page size. + _, buf, err := ReadPage(path, pageID) + if err != nil { + return err + } + + if !options.valueOnly { + err := cmd.PrintLeafItemKey(cmd.Stdout, buf, uint16(itemID), options.format) + if err != nil { + return err + } + } + if !options.keyOnly { + err := cmd.PrintLeafItemValue(cmd.Stdout, buf, uint16(itemID), options.format) + if err != nil { + return err + } + } + return nil +} + +// leafPageElement retrieves a leaf page element. +func (cmd *PageItemCommand) leafPageElement(pageBytes []byte, index uint16) (*leafPageElement, error) { + p := (*page)(unsafe.Pointer(&pageBytes[0])) + if index >= p.count { + return nil, fmt.Errorf("leafPageElement: expected item index less than %d, but got %d.", p.count, index) + } + if p.Type() != "leaf" { + return nil, fmt.Errorf("leafPageElement: expected page type of 'leaf', but got '%s'", p.Type()) + } + return p.leafPageElement(index), nil +} + +// writeBytes writes the byte to the writer. Supported formats: ascii-encoded, hex, bytes. +func (cmd *PageItemCommand) writeBytes(w io.Writer, b []byte, format string) error { + switch format { + case "ascii-encoded": + _, err := fmt.Fprintf(w, "%q", b) + if err != nil { + return err + } + _, err = fmt.Fprintf(w, "\n") + return err + case "hex": + _, err := fmt.Fprintf(w, "%x", b) + if err != nil { + return err + } + _, err = fmt.Fprintf(w, "\n") + return err + case "bytes": + _, err := w.Write(b) + return err + default: + return fmt.Errorf("writeBytes: unsupported format: %s", format) + } +} + +// PrintLeafItemKey writes the bytes of a leaf element's key. +func (cmd *PageItemCommand) PrintLeafItemKey(w io.Writer, pageBytes []byte, index uint16, format string) error { + e, err := cmd.leafPageElement(pageBytes, index) + if err != nil { + return err + } + return cmd.writeBytes(w, e.key(), format) +} + +// PrintLeafItemKey writes the bytes of a leaf element's value. +func (cmd *PageItemCommand) PrintLeafItemValue(w io.Writer, pageBytes []byte, index uint16, format string) error { + e, err := cmd.leafPageElement(pageBytes, index) + if err != nil { + return err + } + return cmd.writeBytes(w, e.value(), format) +} + +// Usage returns the help message. +func (cmd *PageItemCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt page-item [options] PATH pageid itemid + +Additional options include: + + --key-only + Print only the key + --value-only + Print only the value + --format + Output format. One of: ascii-encoded|hex|bytes (default=ascii-encoded) + +page-item prints a page item key and value. +`, "\n") +} + +// PageCommand represents the "page" command execution. +type PageCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// newPageCommand returns a PageCommand. +func newPageCommand(m *Main) *PageCommand { + return &PageCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *PageCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path and page id. + path := fs.Arg(0) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Read page ids. + pageIDs, err := atois(fs.Args()[1:]) + if err != nil { + return err + } else if len(pageIDs) == 0 { + return ErrPageIDRequired + } + + // Open database file handler. + f, err := os.Open(path) + if err != nil { + return err + } + defer func() { _ = f.Close() }() + + // Print each page listed. + for i, pageID := range pageIDs { + // Print a separator. + if i > 0 { + fmt.Fprintln(cmd.Stdout, "===============================================") + } + + // Retrieve page info and page size. + p, buf, err := ReadPage(path, pageID) + if err != nil { + return err + } + + // Print basic page info. + fmt.Fprintf(cmd.Stdout, "Page ID: %d\n", p.id) + fmt.Fprintf(cmd.Stdout, "Page Type: %s\n", p.Type()) + fmt.Fprintf(cmd.Stdout, "Total Size: %d bytes\n", len(buf)) + + // Print type-specific data. + switch p.Type() { + case "meta": + err = cmd.PrintMeta(cmd.Stdout, buf) + case "leaf": + err = cmd.PrintLeaf(cmd.Stdout, buf) + case "branch": + err = cmd.PrintBranch(cmd.Stdout, buf) + case "freelist": + err = cmd.PrintFreelist(cmd.Stdout, buf) + } + if err != nil { + return err + } + } + + return nil +} + +// PrintMeta prints the data from the meta page. +func (cmd *PageCommand) PrintMeta(w io.Writer, buf []byte) error { + m := (*meta)(unsafe.Pointer(&buf[PageHeaderSize])) + fmt.Fprintf(w, "Version: %d\n", m.version) + fmt.Fprintf(w, "Page Size: %d bytes\n", m.pageSize) + fmt.Fprintf(w, "Flags: %08x\n", m.flags) + fmt.Fprintf(w, "Root: \n", m.root.root) + fmt.Fprintf(w, "Freelist: \n", m.freelist) + fmt.Fprintf(w, "HWM: \n", m.pgid) + fmt.Fprintf(w, "Txn ID: %d\n", m.txid) + fmt.Fprintf(w, "Checksum: %016x\n", m.checksum) + fmt.Fprintf(w, "\n") + return nil +} + +// PrintLeaf prints the data for a leaf page. +func (cmd *PageCommand) PrintLeaf(w io.Writer, buf []byte) error { + p := (*page)(unsafe.Pointer(&buf[0])) + + // Print number of items. + fmt.Fprintf(w, "Item Count: %d\n", p.count) + fmt.Fprintf(w, "\n") + + // Print each key/value. + for i := uint16(0); i < p.count; i++ { + e := p.leafPageElement(i) + + // Format key as string. + var k string + if isPrintable(string(e.key())) { + k = fmt.Sprintf("%q", string(e.key())) + } else { + k = fmt.Sprintf("%x", string(e.key())) + } + + // Format value as string. + var v string + if (e.flags & uint32(bucketLeafFlag)) != 0 { + b := (*bucket)(unsafe.Pointer(&e.value()[0])) + v = fmt.Sprintf("", b.root, b.sequence) + } else if isPrintable(string(e.value())) { + v = fmt.Sprintf("%q", string(e.value())) + } else { + v = fmt.Sprintf("%x", string(e.value())) + } + + fmt.Fprintf(w, "%s: %s\n", k, v) + } + fmt.Fprintf(w, "\n") + return nil +} + +// PrintBranch prints the data for a leaf page. +func (cmd *PageCommand) PrintBranch(w io.Writer, buf []byte) error { + p := (*page)(unsafe.Pointer(&buf[0])) + + // Print number of items. + fmt.Fprintf(w, "Item Count: %d\n", p.count) + fmt.Fprintf(w, "\n") + + // Print each key/value. + for i := uint16(0); i < p.count; i++ { + e := p.branchPageElement(i) + + // Format key as string. + var k string + if isPrintable(string(e.key())) { + k = fmt.Sprintf("%q", string(e.key())) + } else { + k = fmt.Sprintf("%x", string(e.key())) + } + + fmt.Fprintf(w, "%s: \n", k, e.pgid) + } + fmt.Fprintf(w, "\n") + return nil +} + +// PrintFreelist prints the data for a freelist page. +func (cmd *PageCommand) PrintFreelist(w io.Writer, buf []byte) error { + p := (*page)(unsafe.Pointer(&buf[0])) + + // Check for overflow and, if present, adjust starting index and actual element count. + idx, count := 0, int(p.count) + if p.count == 0xFFFF { + idx = 1 + count = int(((*[maxAllocSize]pgid)(unsafe.Pointer(&p.ptr)))[0]) + } + + // Print number of items. + fmt.Fprintf(w, "Item Count: %d\n", count) + fmt.Fprintf(w, "Overflow: %d\n", p.overflow) + + fmt.Fprintf(w, "\n") + + // Print each page in the freelist. + ids := (*[maxAllocSize]pgid)(unsafe.Pointer(&p.ptr)) + for i := idx; i < count; i++ { + fmt.Fprintf(w, "%d\n", ids[i]) + } + fmt.Fprintf(w, "\n") + return nil +} + +// PrintPage prints a given page as hexadecimal. +func (cmd *PageCommand) PrintPage(w io.Writer, r io.ReaderAt, pageID int, pageSize int) error { + const bytesPerLineN = 16 + + // Read page into buffer. + buf := make([]byte, pageSize) + addr := pageID * pageSize + if n, err := r.ReadAt(buf, int64(addr)); err != nil { + return err + } else if n != pageSize { + return io.ErrUnexpectedEOF + } + + // Write out to writer in 16-byte lines. + var prev []byte + var skipped bool + for offset := 0; offset < pageSize; offset += bytesPerLineN { + // Retrieve current 16-byte line. + line := buf[offset : offset+bytesPerLineN] + isLastLine := (offset == (pageSize - bytesPerLineN)) + + // If it's the same as the previous line then print a skip. + if bytes.Equal(line, prev) && !isLastLine { + if !skipped { + fmt.Fprintf(w, "%07x *\n", addr+offset) + skipped = true + } + } else { + // Print line as hexadecimal in 2-byte groups. + fmt.Fprintf(w, "%07x %04x %04x %04x %04x %04x %04x %04x %04x\n", addr+offset, + line[0:2], line[2:4], line[4:6], line[6:8], + line[8:10], line[10:12], line[12:14], line[14:16], + ) + + skipped = false + } + + // Save the previous line. + prev = line + } + fmt.Fprint(w, "\n") + + return nil +} + +// Usage returns the help message. +func (cmd *PageCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt page PATH pageid [pageid...] + +Page prints one or more pages in human readable format. +`, "\n") +} + +// PagesCommand represents the "pages" command execution. +type PagesCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewPagesCommand returns a PagesCommand. +func newPagesCommand(m *Main) *PagesCommand { + return &PagesCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *PagesCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path. + path := fs.Arg(0) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Open database. + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return err + } + defer func() { _ = db.Close() }() + + // Write header. + fmt.Fprintln(cmd.Stdout, "ID TYPE ITEMS OVRFLW") + fmt.Fprintln(cmd.Stdout, "======== ========== ====== ======") + + return db.Update(func(tx *bolt.Tx) error { + var id int + for { + p, err := tx.Page(id) + if err != nil { + return &PageError{ID: id, Err: err} + } else if p == nil { + break + } + + // Only display count and overflow if this is a non-free page. + var count, overflow string + if p.Type != "free" { + count = strconv.Itoa(p.Count) + if p.OverflowCount > 0 { + overflow = strconv.Itoa(p.OverflowCount) + } + } + + // Print table row. + fmt.Fprintf(cmd.Stdout, "%-8d %-10s %-6s %-6s\n", p.ID, p.Type, count, overflow) + + // Move to the next non-overflow page. + id += 1 + if p.Type != "free" { + id += p.OverflowCount + } + } + return nil + }) +} + +// Usage returns the help message. +func (cmd *PagesCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt pages PATH + +Pages prints a table of pages with their type (meta, leaf, branch, freelist). +Leaf and branch pages will show a key count in the "items" column while the +freelist will show the number of free pages in the "items" column. + +The "overflow" column shows the number of blocks that the page spills over +into. Normally there is no overflow but large keys and values can cause +a single page to take up multiple blocks. +`, "\n") +} + +// StatsCommand represents the "stats" command execution. +type StatsCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewStatsCommand returns a StatsCommand. +func newStatsCommand(m *Main) *StatsCommand { + return &StatsCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *StatsCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path. + path, prefix := fs.Arg(0), fs.Arg(1) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Open database. + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return err + } + defer db.Close() + + return db.View(func(tx *bolt.Tx) error { + var s bolt.BucketStats + var count int + if err := tx.ForEach(func(name []byte, b *bolt.Bucket) error { + if bytes.HasPrefix(name, []byte(prefix)) { + s.Add(b.Stats()) + count += 1 + } + return nil + }); err != nil { + return err + } + + fmt.Fprintf(cmd.Stdout, "Aggregate statistics for %d buckets\n\n", count) + + fmt.Fprintln(cmd.Stdout, "Page count statistics") + fmt.Fprintf(cmd.Stdout, "\tNumber of logical branch pages: %d\n", s.BranchPageN) + fmt.Fprintf(cmd.Stdout, "\tNumber of physical branch overflow pages: %d\n", s.BranchOverflowN) + fmt.Fprintf(cmd.Stdout, "\tNumber of logical leaf pages: %d\n", s.LeafPageN) + fmt.Fprintf(cmd.Stdout, "\tNumber of physical leaf overflow pages: %d\n", s.LeafOverflowN) + + fmt.Fprintln(cmd.Stdout, "Tree statistics") + fmt.Fprintf(cmd.Stdout, "\tNumber of keys/value pairs: %d\n", s.KeyN) + fmt.Fprintf(cmd.Stdout, "\tNumber of levels in B+tree: %d\n", s.Depth) + + fmt.Fprintln(cmd.Stdout, "Page size utilization") + fmt.Fprintf(cmd.Stdout, "\tBytes allocated for physical branch pages: %d\n", s.BranchAlloc) + var percentage int + if s.BranchAlloc != 0 { + percentage = int(float32(s.BranchInuse) * 100.0 / float32(s.BranchAlloc)) + } + fmt.Fprintf(cmd.Stdout, "\tBytes actually used for branch data: %d (%d%%)\n", s.BranchInuse, percentage) + fmt.Fprintf(cmd.Stdout, "\tBytes allocated for physical leaf pages: %d\n", s.LeafAlloc) + percentage = 0 + if s.LeafAlloc != 0 { + percentage = int(float32(s.LeafInuse) * 100.0 / float32(s.LeafAlloc)) + } + fmt.Fprintf(cmd.Stdout, "\tBytes actually used for leaf data: %d (%d%%)\n", s.LeafInuse, percentage) + + fmt.Fprintln(cmd.Stdout, "Bucket statistics") + fmt.Fprintf(cmd.Stdout, "\tTotal number of buckets: %d\n", s.BucketN) + percentage = 0 + if s.BucketN != 0 { + percentage = int(float32(s.InlineBucketN) * 100.0 / float32(s.BucketN)) + } + fmt.Fprintf(cmd.Stdout, "\tTotal number on inlined buckets: %d (%d%%)\n", s.InlineBucketN, percentage) + percentage = 0 + if s.LeafInuse != 0 { + percentage = int(float32(s.InlineBucketInuse) * 100.0 / float32(s.LeafInuse)) + } + fmt.Fprintf(cmd.Stdout, "\tBytes used for inlined buckets: %d (%d%%)\n", s.InlineBucketInuse, percentage) + + return nil + }) +} + +// Usage returns the help message. +func (cmd *StatsCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt stats PATH + +Stats performs an extensive search of the database to track every page +reference. It starts at the current meta page and recursively iterates +through every accessible bucket. + +The following errors can be reported: + + already freed + The page is referenced more than once in the freelist. + + unreachable unfreed + The page is not referenced by a bucket or in the freelist. + + reachable freed + The page is referenced by a bucket but is also in the freelist. + + out of bounds + A page is referenced that is above the high water mark. + + multiple references + A page is referenced by more than one other page. + + invalid type + The page type is not "meta", "leaf", "branch", or "freelist". + +No errors should occur in your database. However, if for some reason you +experience corruption, please submit a ticket to the Bolt project page: + + https://github.com/boltdb/bolt/issues +`, "\n") +} + +// BucketsCommand represents the "buckets" command execution. +type BucketsCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewBucketsCommand returns a BucketsCommand. +func newBucketsCommand(m *Main) *BucketsCommand { + return &BucketsCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *BucketsCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path. + path := fs.Arg(0) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } + + // Open database. + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return err + } + defer db.Close() + + // Print buckets. + return db.View(func(tx *bolt.Tx) error { + return tx.ForEach(func(name []byte, _ *bolt.Bucket) error { + fmt.Fprintln(cmd.Stdout, string(name)) + return nil + }) + }) +} + +// Usage returns the help message. +func (cmd *BucketsCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt buckets PATH + +Print a list of buckets. +`, "\n") +} + +// KeysCommand represents the "keys" command execution. +type KeysCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewKeysCommand returns a KeysCommand. +func newKeysCommand(m *Main) *KeysCommand { + return &KeysCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *KeysCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path and bucket. + path, bucket := fs.Arg(0), fs.Arg(1) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } else if bucket == "" { + return ErrBucketRequired + } + + // Open database. + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return err + } + defer db.Close() + + // Print keys. + return db.View(func(tx *bolt.Tx) error { + // Find bucket. + b := tx.Bucket([]byte(bucket)) + if b == nil { + return ErrBucketNotFound + } + + // Iterate over each key. + return b.ForEach(func(key, _ []byte) error { + fmt.Fprintln(cmd.Stdout, string(key)) + return nil + }) + }) +} + +// Usage returns the help message. +func (cmd *KeysCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt keys PATH BUCKET + +Print a list of keys in the given bucket. +`, "\n") +} + +// GetCommand represents the "get" command execution. +type GetCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewGetCommand returns a GetCommand. +func newGetCommand(m *Main) *GetCommand { + return &GetCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *GetCommand) Run(args ...string) error { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + help := fs.Bool("h", false, "") + if err := fs.Parse(args); err != nil { + return err + } else if *help { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } + + // Require database path, bucket and key. + path, bucket, key := fs.Arg(0), fs.Arg(1), fs.Arg(2) + if path == "" { + return ErrPathRequired + } else if _, err := os.Stat(path); os.IsNotExist(err) { + return ErrFileNotFound + } else if bucket == "" { + return ErrBucketRequired + } else if key == "" { + return ErrKeyRequired + } + + // Open database. + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return err + } + defer db.Close() + + // Print value. + return db.View(func(tx *bolt.Tx) error { + // Find bucket. + b := tx.Bucket([]byte(bucket)) + if b == nil { + return ErrBucketNotFound + } + + // Find value for given key. + val := b.Get([]byte(key)) + if val == nil { + return ErrKeyNotFound + } + + fmt.Fprintln(cmd.Stdout, string(val)) + return nil + }) +} + +// Usage returns the help message. +func (cmd *GetCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt get PATH BUCKET KEY + +Print the value of the given key in the given bucket. +`, "\n") +} + +var benchBucketName = []byte("bench") + +// BenchCommand represents the "bench" command execution. +type BenchCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer +} + +// NewBenchCommand returns a BenchCommand using the +func newBenchCommand(m *Main) *BenchCommand { + return &BenchCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the "bench" command. +func (cmd *BenchCommand) Run(args ...string) error { + // Parse CLI arguments. + options, err := cmd.ParseFlags(args) + if err != nil { + return err + } + + // Remove path if "-work" is not set. Otherwise keep path. + if options.Work { + fmt.Fprintf(cmd.Stdout, "work: %s\n", options.Path) + } else { + defer os.Remove(options.Path) + } + + // Create database. + db, err := bolt.Open(options.Path, 0666, nil) + if err != nil { + return err + } + db.NoSync = options.NoSync + defer db.Close() + + // Write to the database. + var results BenchResults + if err := cmd.runWrites(db, options, &results); err != nil { + return fmt.Errorf("write: %v", err) + } + + // Read from the database. + if err := cmd.runReads(db, options, &results); err != nil { + return fmt.Errorf("bench: read: %s", err) + } + + // Print results. + fmt.Fprintf(os.Stderr, "# Write\t%v\t(%v/op)\t(%v op/sec)\n", results.WriteDuration, results.WriteOpDuration(), results.WriteOpsPerSecond()) + fmt.Fprintf(os.Stderr, "# Read\t%v\t(%v/op)\t(%v op/sec)\n", results.ReadDuration, results.ReadOpDuration(), results.ReadOpsPerSecond()) + fmt.Fprintln(os.Stderr, "") + return nil +} + +// ParseFlags parses the command line flags. +func (cmd *BenchCommand) ParseFlags(args []string) (*BenchOptions, error) { + var options BenchOptions + + // Parse flagset. + fs := flag.NewFlagSet("", flag.ContinueOnError) + fs.StringVar(&options.ProfileMode, "profile-mode", "rw", "") + fs.StringVar(&options.WriteMode, "write-mode", "seq", "") + fs.StringVar(&options.ReadMode, "read-mode", "seq", "") + fs.IntVar(&options.Iterations, "count", 1000, "") + fs.IntVar(&options.BatchSize, "batch-size", 0, "") + fs.IntVar(&options.KeySize, "key-size", 8, "") + fs.IntVar(&options.ValueSize, "value-size", 32, "") + fs.StringVar(&options.CPUProfile, "cpuprofile", "", "") + fs.StringVar(&options.MemProfile, "memprofile", "", "") + fs.StringVar(&options.BlockProfile, "blockprofile", "", "") + fs.Float64Var(&options.FillPercent, "fill-percent", bolt.DefaultFillPercent, "") + fs.BoolVar(&options.NoSync, "no-sync", false, "") + fs.BoolVar(&options.Work, "work", false, "") + fs.StringVar(&options.Path, "path", "", "") + fs.SetOutput(cmd.Stderr) + if err := fs.Parse(args); err != nil { + return nil, err + } + + // Set batch size to iteration size if not set. + // Require that batch size can be evenly divided by the iteration count. + if options.BatchSize == 0 { + options.BatchSize = options.Iterations + } else if options.Iterations%options.BatchSize != 0 { + return nil, ErrNonDivisibleBatchSize + } + + // Generate temp path if one is not passed in. + if options.Path == "" { + f, err := ioutil.TempFile("", "bolt-bench-") + if err != nil { + return nil, fmt.Errorf("temp file: %s", err) + } + f.Close() + os.Remove(f.Name()) + options.Path = f.Name() + } + + return &options, nil +} + +// Writes to the database. +func (cmd *BenchCommand) runWrites(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + // Start profiling for writes. + if options.ProfileMode == "rw" || options.ProfileMode == "w" { + cmd.startProfiling(options) + } + + t := time.Now() + + var err error + switch options.WriteMode { + case "seq": + err = cmd.runWritesSequential(db, options, results) + case "rnd": + err = cmd.runWritesRandom(db, options, results) + case "seq-nest": + err = cmd.runWritesSequentialNested(db, options, results) + case "rnd-nest": + err = cmd.runWritesRandomNested(db, options, results) + default: + return fmt.Errorf("invalid write mode: %s", options.WriteMode) + } + + // Save time to write. + results.WriteDuration = time.Since(t) + + // Stop profiling for writes only. + if options.ProfileMode == "w" { + cmd.stopProfiling() + } + + return err +} + +func (cmd *BenchCommand) runWritesSequential(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + var i = uint32(0) + return cmd.runWritesWithSource(db, options, results, func() uint32 { i++; return i }) +} + +func (cmd *BenchCommand) runWritesRandom(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + r := rand.New(rand.NewSource(time.Now().UnixNano())) + return cmd.runWritesWithSource(db, options, results, func() uint32 { return r.Uint32() }) +} + +func (cmd *BenchCommand) runWritesSequentialNested(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + var i = uint32(0) + return cmd.runWritesNestedWithSource(db, options, results, func() uint32 { i++; return i }) +} + +func (cmd *BenchCommand) runWritesRandomNested(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + r := rand.New(rand.NewSource(time.Now().UnixNano())) + return cmd.runWritesNestedWithSource(db, options, results, func() uint32 { return r.Uint32() }) +} + +func (cmd *BenchCommand) runWritesWithSource(db *bolt.DB, options *BenchOptions, results *BenchResults, keySource func() uint32) error { + results.WriteOps = options.Iterations + + for i := 0; i < options.Iterations; i += options.BatchSize { + if err := db.Update(func(tx *bolt.Tx) error { + b, _ := tx.CreateBucketIfNotExists(benchBucketName) + b.FillPercent = options.FillPercent + + for j := 0; j < options.BatchSize; j++ { + key := make([]byte, options.KeySize) + value := make([]byte, options.ValueSize) + + // Write key as uint32. + binary.BigEndian.PutUint32(key, keySource()) + + // Insert key/value. + if err := b.Put(key, value); err != nil { + return err + } + } + + return nil + }); err != nil { + return err + } + } + return nil +} + +func (cmd *BenchCommand) runWritesNestedWithSource(db *bolt.DB, options *BenchOptions, results *BenchResults, keySource func() uint32) error { + results.WriteOps = options.Iterations + + for i := 0; i < options.Iterations; i += options.BatchSize { + if err := db.Update(func(tx *bolt.Tx) error { + top, err := tx.CreateBucketIfNotExists(benchBucketName) + if err != nil { + return err + } + top.FillPercent = options.FillPercent + + // Create bucket key. + name := make([]byte, options.KeySize) + binary.BigEndian.PutUint32(name, keySource()) + + // Create bucket. + b, err := top.CreateBucketIfNotExists(name) + if err != nil { + return err + } + b.FillPercent = options.FillPercent + + for j := 0; j < options.BatchSize; j++ { + var key = make([]byte, options.KeySize) + var value = make([]byte, options.ValueSize) + + // Generate key as uint32. + binary.BigEndian.PutUint32(key, keySource()) + + // Insert value into subbucket. + if err := b.Put(key, value); err != nil { + return err + } + } + + return nil + }); err != nil { + return err + } + } + return nil +} + +// Reads from the database. +func (cmd *BenchCommand) runReads(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + // Start profiling for reads. + if options.ProfileMode == "r" { + cmd.startProfiling(options) + } + + t := time.Now() + + var err error + switch options.ReadMode { + case "seq": + switch options.WriteMode { + case "seq-nest", "rnd-nest": + err = cmd.runReadsSequentialNested(db, options, results) + default: + err = cmd.runReadsSequential(db, options, results) + } + default: + return fmt.Errorf("invalid read mode: %s", options.ReadMode) + } + + // Save read time. + results.ReadDuration = time.Since(t) + + // Stop profiling for reads. + if options.ProfileMode == "rw" || options.ProfileMode == "r" { + cmd.stopProfiling() + } + + return err +} + +func (cmd *BenchCommand) runReadsSequential(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + return db.View(func(tx *bolt.Tx) error { + t := time.Now() + + for { + var count int + + c := tx.Bucket(benchBucketName).Cursor() + for k, v := c.First(); k != nil; k, v = c.Next() { + if v == nil { + return errors.New("invalid value") + } + count++ + } + + if options.WriteMode == "seq" && count != options.Iterations { + return fmt.Errorf("read seq: iter mismatch: expected %d, got %d", options.Iterations, count) + } + + results.ReadOps += count + + // Make sure we do this for at least a second. + if time.Since(t) >= time.Second { + break + } + } + + return nil + }) +} + +func (cmd *BenchCommand) runReadsSequentialNested(db *bolt.DB, options *BenchOptions, results *BenchResults) error { + return db.View(func(tx *bolt.Tx) error { + t := time.Now() + + for { + var count int + var top = tx.Bucket(benchBucketName) + if err := top.ForEach(func(name, _ []byte) error { + if b := top.Bucket(name); b != nil { + c := b.Cursor() + for k, v := c.First(); k != nil; k, v = c.Next() { + if v == nil { + return ErrInvalidValue + } + count++ + } + } + return nil + }); err != nil { + return err + } + + if options.WriteMode == "seq-nest" && count != options.Iterations { + return fmt.Errorf("read seq-nest: iter mismatch: expected %d, got %d", options.Iterations, count) + } + + results.ReadOps += count + + // Make sure we do this for at least a second. + if time.Since(t) >= time.Second { + break + } + } + + return nil + }) +} + +// File handlers for the various profiles. +var cpuprofile, memprofile, blockprofile *os.File + +// Starts all profiles set on the options. +func (cmd *BenchCommand) startProfiling(options *BenchOptions) { + var err error + + // Start CPU profiling. + if options.CPUProfile != "" { + cpuprofile, err = os.Create(options.CPUProfile) + if err != nil { + fmt.Fprintf(cmd.Stderr, "bench: could not create cpu profile %q: %v\n", options.CPUProfile, err) + os.Exit(1) + } + pprof.StartCPUProfile(cpuprofile) + } + + // Start memory profiling. + if options.MemProfile != "" { + memprofile, err = os.Create(options.MemProfile) + if err != nil { + fmt.Fprintf(cmd.Stderr, "bench: could not create memory profile %q: %v\n", options.MemProfile, err) + os.Exit(1) + } + runtime.MemProfileRate = 4096 + } + + // Start fatal profiling. + if options.BlockProfile != "" { + blockprofile, err = os.Create(options.BlockProfile) + if err != nil { + fmt.Fprintf(cmd.Stderr, "bench: could not create block profile %q: %v\n", options.BlockProfile, err) + os.Exit(1) + } + runtime.SetBlockProfileRate(1) + } +} + +// Stops all profiles. +func (cmd *BenchCommand) stopProfiling() { + if cpuprofile != nil { + pprof.StopCPUProfile() + cpuprofile.Close() + cpuprofile = nil + } + + if memprofile != nil { + pprof.Lookup("heap").WriteTo(memprofile, 0) + memprofile.Close() + memprofile = nil + } + + if blockprofile != nil { + pprof.Lookup("block").WriteTo(blockprofile, 0) + blockprofile.Close() + blockprofile = nil + runtime.SetBlockProfileRate(0) + } +} + +// BenchOptions represents the set of options that can be passed to "bolt bench". +type BenchOptions struct { + ProfileMode string + WriteMode string + ReadMode string + Iterations int + BatchSize int + KeySize int + ValueSize int + CPUProfile string + MemProfile string + BlockProfile string + StatsInterval time.Duration + FillPercent float64 + NoSync bool + Work bool + Path string +} + +// BenchResults represents the performance results of the benchmark. +type BenchResults struct { + WriteOps int + WriteDuration time.Duration + ReadOps int + ReadDuration time.Duration +} + +// Returns the duration for a single write operation. +func (r *BenchResults) WriteOpDuration() time.Duration { + if r.WriteOps == 0 { + return 0 + } + return r.WriteDuration / time.Duration(r.WriteOps) +} + +// Returns average number of write operations that can be performed per second. +func (r *BenchResults) WriteOpsPerSecond() int { + var op = r.WriteOpDuration() + if op == 0 { + return 0 + } + return int(time.Second) / int(op) +} + +// Returns the duration for a single read operation. +func (r *BenchResults) ReadOpDuration() time.Duration { + if r.ReadOps == 0 { + return 0 + } + return r.ReadDuration / time.Duration(r.ReadOps) +} + +// Returns average number of read operations that can be performed per second. +func (r *BenchResults) ReadOpsPerSecond() int { + var op = r.ReadOpDuration() + if op == 0 { + return 0 + } + return int(time.Second) / int(op) +} + +type PageError struct { + ID int + Err error +} + +func (e *PageError) Error() string { + return fmt.Sprintf("page error: id=%d, err=%s", e.ID, e.Err) +} + +// isPrintable returns true if the string is valid unicode and contains only printable runes. +func isPrintable(s string) bool { + if !utf8.ValidString(s) { + return false + } + for _, ch := range s { + if !unicode.IsPrint(ch) { + return false + } + } + return true +} + +// ReadPage reads page info & full page data from a path. +// This is not transactionally safe. +func ReadPage(path string, pageID int) (*page, []byte, error) { + // Find page size. + pageSize, err := ReadPageSize(path) + if err != nil { + return nil, nil, fmt.Errorf("read page size: %s", err) + } + + // Open database file. + f, err := os.Open(path) + if err != nil { + return nil, nil, err + } + defer f.Close() + + // Read one block into buffer. + buf := make([]byte, pageSize) + if n, err := f.ReadAt(buf, int64(pageID*pageSize)); err != nil { + return nil, nil, err + } else if n != len(buf) { + return nil, nil, io.ErrUnexpectedEOF + } + + // Determine total number of blocks. + p := (*page)(unsafe.Pointer(&buf[0])) + overflowN := p.overflow + + // Re-read entire page (with overflow) into buffer. + buf = make([]byte, (int(overflowN)+1)*pageSize) + if n, err := f.ReadAt(buf, int64(pageID*pageSize)); err != nil { + return nil, nil, err + } else if n != len(buf) { + return nil, nil, io.ErrUnexpectedEOF + } + p = (*page)(unsafe.Pointer(&buf[0])) + + return p, buf, nil +} + +// ReadPageSize reads page size a path. +// This is not transactionally safe. +func ReadPageSize(path string) (int, error) { + // Open database file. + f, err := os.Open(path) + if err != nil { + return 0, err + } + defer f.Close() + + // Read 4KB chunk. + buf := make([]byte, 4096) + if _, err := io.ReadFull(f, buf); err != nil { + return 0, err + } + + // Read page size from metadata. + m := (*meta)(unsafe.Pointer(&buf[PageHeaderSize])) + return int(m.pageSize), nil +} + +// atois parses a slice of strings into integers. +func atois(strs []string) ([]int, error) { + var a []int + for _, str := range strs { + i, err := strconv.Atoi(str) + if err != nil { + return nil, err + } + a = append(a, i) + } + return a, nil +} + +// DO NOT EDIT. Copied from the "bolt" package. +const maxAllocSize = 0xFFFFFFF + +// DO NOT EDIT. Copied from the "bolt" package. +const ( + branchPageFlag = 0x01 + leafPageFlag = 0x02 + metaPageFlag = 0x04 + freelistPageFlag = 0x10 +) + +// DO NOT EDIT. Copied from the "bolt" package. +const bucketLeafFlag = 0x01 + +// DO NOT EDIT. Copied from the "bolt" package. +type pgid uint64 + +// DO NOT EDIT. Copied from the "bolt" package. +type txid uint64 + +// DO NOT EDIT. Copied from the "bolt" package. +type meta struct { + magic uint32 + version uint32 + pageSize uint32 + flags uint32 + root bucket + freelist pgid + pgid pgid + txid txid + checksum uint64 +} + +// DO NOT EDIT. Copied from the "bolt" package. +type bucket struct { + root pgid + sequence uint64 +} + +// DO NOT EDIT. Copied from the "bolt" package. +type page struct { + id pgid + flags uint16 + count uint16 + overflow uint32 + ptr uintptr +} + +// DO NOT EDIT. Copied from the "bolt" package. +func (p *page) Type() string { + if (p.flags & branchPageFlag) != 0 { + return "branch" + } else if (p.flags & leafPageFlag) != 0 { + return "leaf" + } else if (p.flags & metaPageFlag) != 0 { + return "meta" + } else if (p.flags & freelistPageFlag) != 0 { + return "freelist" + } + return fmt.Sprintf("unknown<%02x>", p.flags) +} + +// DO NOT EDIT. Copied from the "bolt" package. +func (p *page) leafPageElement(index uint16) *leafPageElement { + n := &((*[0x7FFFFFF]leafPageElement)(unsafe.Pointer(&p.ptr)))[index] + return n +} + +// DO NOT EDIT. Copied from the "bolt" package. +func (p *page) branchPageElement(index uint16) *branchPageElement { + return &((*[0x7FFFFFF]branchPageElement)(unsafe.Pointer(&p.ptr)))[index] +} + +// DO NOT EDIT. Copied from the "bolt" package. +type branchPageElement struct { + pos uint32 + ksize uint32 + pgid pgid +} + +// DO NOT EDIT. Copied from the "bolt" package. +func (n *branchPageElement) key() []byte { + buf := (*[maxAllocSize]byte)(unsafe.Pointer(n)) + return buf[n.pos : n.pos+n.ksize] +} + +// DO NOT EDIT. Copied from the "bolt" package. +type leafPageElement struct { + flags uint32 + pos uint32 + ksize uint32 + vsize uint32 +} + +// DO NOT EDIT. Copied from the "bolt" package. +func (n *leafPageElement) key() []byte { + buf := (*[maxAllocSize]byte)(unsafe.Pointer(n)) + return buf[n.pos : n.pos+n.ksize] +} + +// DO NOT EDIT. Copied from the "bolt" package. +func (n *leafPageElement) value() []byte { + buf := (*[maxAllocSize]byte)(unsafe.Pointer(n)) + return buf[n.pos+n.ksize : n.pos+n.ksize+n.vsize] +} + +// CompactCommand represents the "compact" command execution. +type CompactCommand struct { + Stdin io.Reader + Stdout io.Writer + Stderr io.Writer + + SrcPath string + DstPath string + TxMaxSize int64 +} + +// newCompactCommand returns a CompactCommand. +func newCompactCommand(m *Main) *CompactCommand { + return &CompactCommand{ + Stdin: m.Stdin, + Stdout: m.Stdout, + Stderr: m.Stderr, + } +} + +// Run executes the command. +func (cmd *CompactCommand) Run(args ...string) (err error) { + // Parse flags. + fs := flag.NewFlagSet("", flag.ContinueOnError) + fs.SetOutput(ioutil.Discard) + fs.StringVar(&cmd.DstPath, "o", "", "") + fs.Int64Var(&cmd.TxMaxSize, "tx-max-size", 65536, "") + if err := fs.Parse(args); err == flag.ErrHelp { + fmt.Fprintln(cmd.Stderr, cmd.Usage()) + return ErrUsage + } else if err != nil { + return err + } else if cmd.DstPath == "" { + return fmt.Errorf("output file required") + } + + // Require database paths. + cmd.SrcPath = fs.Arg(0) + if cmd.SrcPath == "" { + return ErrPathRequired + } + + // Ensure source file exists. + fi, err := os.Stat(cmd.SrcPath) + if os.IsNotExist(err) { + return ErrFileNotFound + } else if err != nil { + return err + } + initialSize := fi.Size() + + // Open source database. + src, err := bolt.Open(cmd.SrcPath, 0444, nil) + if err != nil { + return err + } + defer src.Close() + + // Open destination database. + dst, err := bolt.Open(cmd.DstPath, fi.Mode(), nil) + if err != nil { + return err + } + defer dst.Close() + + // Run compaction. + if err := cmd.compact(dst, src); err != nil { + return err + } + + // Report stats on new size. + fi, err = os.Stat(cmd.DstPath) + if err != nil { + return err + } else if fi.Size() == 0 { + return fmt.Errorf("zero db size") + } + fmt.Fprintf(cmd.Stdout, "%d -> %d bytes (gain=%.2fx)\n", initialSize, fi.Size(), float64(initialSize)/float64(fi.Size())) + + return nil +} + +func (cmd *CompactCommand) compact(dst, src *bolt.DB) error { + // commit regularly, or we'll run out of memory for large datasets if using one transaction. + var size int64 + tx, err := dst.Begin(true) + if err != nil { + return err + } + defer tx.Rollback() + + if err := cmd.walk(src, func(keys [][]byte, k, v []byte, seq uint64) error { + // On each key/value, check if we have exceeded tx size. + sz := int64(len(k) + len(v)) + if size+sz > cmd.TxMaxSize && cmd.TxMaxSize != 0 { + // Commit previous transaction. + if err := tx.Commit(); err != nil { + return err + } + + // Start new transaction. + tx, err = dst.Begin(true) + if err != nil { + return err + } + size = 0 + } + size += sz + + // Create bucket on the root transaction if this is the first level. + nk := len(keys) + if nk == 0 { + bkt, err := tx.CreateBucket(k) + if err != nil { + return err + } + if err := bkt.SetSequence(seq); err != nil { + return err + } + return nil + } + + // Create buckets on subsequent levels, if necessary. + b := tx.Bucket(keys[0]) + if nk > 1 { + for _, k := range keys[1:] { + b = b.Bucket(k) + } + } + + // Fill the entire page for best compaction. + b.FillPercent = 1.0 + + // If there is no value then this is a bucket call. + if v == nil { + bkt, err := b.CreateBucket(k) + if err != nil { + return err + } + if err := bkt.SetSequence(seq); err != nil { + return err + } + return nil + } + + // Otherwise treat it as a key/value pair. + return b.Put(k, v) + }); err != nil { + return err + } + + return tx.Commit() +} + +// walkFunc is the type of the function called for keys (buckets and "normal" +// values) discovered by Walk. keys is the list of keys to descend to the bucket +// owning the discovered key/value pair k/v. +type walkFunc func(keys [][]byte, k, v []byte, seq uint64) error + +// walk walks recursively the bolt database db, calling walkFn for each key it finds. +func (cmd *CompactCommand) walk(db *bolt.DB, walkFn walkFunc) error { + return db.View(func(tx *bolt.Tx) error { + return tx.ForEach(func(name []byte, b *bolt.Bucket) error { + return cmd.walkBucket(b, nil, name, nil, b.Sequence(), walkFn) + }) + }) +} + +func (cmd *CompactCommand) walkBucket(b *bolt.Bucket, keypath [][]byte, k, v []byte, seq uint64, fn walkFunc) error { + // Execute callback. + if err := fn(keypath, k, v, seq); err != nil { + return err + } + + // If this is not a bucket then stop. + if v != nil { + return nil + } + + // Iterate over each child key/value. + keypath = append(keypath, k) + return b.ForEach(func(k, v []byte) error { + if v == nil { + bkt := b.Bucket(k) + return cmd.walkBucket(bkt, keypath, k, nil, bkt.Sequence(), fn) + } + return cmd.walkBucket(b, keypath, k, v, b.Sequence(), fn) + }) +} + +// Usage returns the help message. +func (cmd *CompactCommand) Usage() string { + return strings.TrimLeft(` +usage: bolt compact [options] -o DST SRC + +Compact opens a database at SRC path and walks it recursively, copying keys +as they are found from all buckets, to a newly created database at DST path. + +The original database is left untouched. + +Additional options include: + + -tx-max-size NUM + Specifies the maximum size of individual transactions. + Defaults to 64KB. +`, "\n") +} diff --git a/vendor/etcd.io/bbolt/cmd/bbolt/main_test b/vendor/etcd.io/bbolt/cmd/bbolt/main_test new file mode 100644 index 0000000..b4871ff --- /dev/null +++ b/vendor/etcd.io/bbolt/cmd/bbolt/main_test @@ -0,0 +1,455 @@ +package main_test + +import ( + "bytes" + crypto "crypto/rand" + "encoding/binary" + "fmt" + "io" + "io/ioutil" + "math/rand" + "os" + "strconv" + "testing" + + bolt "go.etcd.io/bbolt" +) + +// Ensure the "info" command can print information about a database. +func TestInfoCommand_Run(t *testing.T) { + db := MustOpen(0666, nil) + db.DB.Close() + defer db.Close() + + // Run the info command. + m := NewMain() + if err := m.Run("info", db.Path); err != nil { + t.Fatal(err) + } +} + +// Ensure the "stats" command executes correctly with an empty database. +func TestStatsCommand_Run_EmptyDatabase(t *testing.T) { + // Ignore + if os.Getpagesize() != 4096 { + t.Skip("system does not use 4KB page size") + } + + db := MustOpen(0666, nil) + defer db.Close() + db.DB.Close() + + // Generate expected result. + exp := "Aggregate statistics for 0 buckets\n\n" + + "Page count statistics\n" + + "\tNumber of logical branch pages: 0\n" + + "\tNumber of physical branch overflow pages: 0\n" + + "\tNumber of logical leaf pages: 0\n" + + "\tNumber of physical leaf overflow pages: 0\n" + + "Tree statistics\n" + + "\tNumber of keys/value pairs: 0\n" + + "\tNumber of levels in B+tree: 0\n" + + "Page size utilization\n" + + "\tBytes allocated for physical branch pages: 0\n" + + "\tBytes actually used for branch data: 0 (0%)\n" + + "\tBytes allocated for physical leaf pages: 0\n" + + "\tBytes actually used for leaf data: 0 (0%)\n" + + "Bucket statistics\n" + + "\tTotal number of buckets: 0\n" + + "\tTotal number on inlined buckets: 0 (0%)\n" + + "\tBytes used for inlined buckets: 0 (0%)\n" + + // Run the command. + m := NewMain() + if err := m.Run("stats", db.Path); err != nil { + t.Fatal(err) + } else if m.Stdout.String() != exp { + t.Fatalf("unexpected stdout:\n\n%s", m.Stdout.String()) + } +} + +// Ensure the "stats" command can execute correctly. +func TestStatsCommand_Run(t *testing.T) { + // Ignore + if os.Getpagesize() != 4096 { + t.Skip("system does not use 4KB page size") + } + + db := MustOpen(0666, nil) + defer db.Close() + + if err := db.Update(func(tx *bolt.Tx) error { + // Create "foo" bucket. + b, err := tx.CreateBucket([]byte("foo")) + if err != nil { + return err + } + for i := 0; i < 10; i++ { + if err := b.Put([]byte(strconv.Itoa(i)), []byte(strconv.Itoa(i))); err != nil { + return err + } + } + + // Create "bar" bucket. + b, err = tx.CreateBucket([]byte("bar")) + if err != nil { + return err + } + for i := 0; i < 100; i++ { + if err := b.Put([]byte(strconv.Itoa(i)), []byte(strconv.Itoa(i))); err != nil { + return err + } + } + + // Create "baz" bucket. + b, err = tx.CreateBucket([]byte("baz")) + if err != nil { + return err + } + if err := b.Put([]byte("key"), []byte("value")); err != nil { + return err + } + + return nil + }); err != nil { + t.Fatal(err) + } + db.DB.Close() + + // Generate expected result. + exp := "Aggregate statistics for 3 buckets\n\n" + + "Page count statistics\n" + + "\tNumber of logical branch pages: 0\n" + + "\tNumber of physical branch overflow pages: 0\n" + + "\tNumber of logical leaf pages: 1\n" + + "\tNumber of physical leaf overflow pages: 0\n" + + "Tree statistics\n" + + "\tNumber of keys/value pairs: 111\n" + + "\tNumber of levels in B+tree: 1\n" + + "Page size utilization\n" + + "\tBytes allocated for physical branch pages: 0\n" + + "\tBytes actually used for branch data: 0 (0%)\n" + + "\tBytes allocated for physical leaf pages: 4096\n" + + "\tBytes actually used for leaf data: 1996 (48%)\n" + + "Bucket statistics\n" + + "\tTotal number of buckets: 3\n" + + "\tTotal number on inlined buckets: 2 (66%)\n" + + "\tBytes used for inlined buckets: 236 (11%)\n" + + // Run the command. + m := NewMain() + if err := m.Run("stats", db.Path); err != nil { + t.Fatal(err) + } else if m.Stdout.String() != exp { + t.Fatalf("unexpected stdout:\n\n%s", m.Stdout.String()) + } +} + +// Ensure the "buckets" command can print a list of buckets. +func TestBucketsCommand_Run(t *testing.T) { + db := MustOpen(0666, nil) + defer db.Close() + + if err := db.Update(func(tx *bolt.Tx) error { + for _, name := range []string{"foo", "bar", "baz"} { + _, err := tx.CreateBucket([]byte(name)) + if err != nil { + return err + } + } + return nil + }); err != nil { + t.Fatal(err) + } + db.DB.Close() + + expected := "bar\nbaz\nfoo\n" + + // Run the command. + m := NewMain() + if err := m.Run("buckets", db.Path); err != nil { + t.Fatal(err) + } else if actual := m.Stdout.String(); actual != expected { + t.Fatalf("unexpected stdout:\n\n%s", actual) + } +} + +// Ensure the "keys" command can print a list of keys for a bucket. +func TestKeysCommand_Run(t *testing.T) { + db := MustOpen(0666, nil) + defer db.Close() + + if err := db.Update(func(tx *bolt.Tx) error { + for _, name := range []string{"foo", "bar"} { + b, err := tx.CreateBucket([]byte(name)) + if err != nil { + return err + } + for i := 0; i < 3; i++ { + key := fmt.Sprintf("%s-%d", name, i) + if err := b.Put([]byte(key), []byte{0}); err != nil { + return err + } + } + } + return nil + }); err != nil { + t.Fatal(err) + } + db.DB.Close() + + expected := "foo-0\nfoo-1\nfoo-2\n" + + // Run the command. + m := NewMain() + if err := m.Run("keys", db.Path, "foo"); err != nil { + t.Fatal(err) + } else if actual := m.Stdout.String(); actual != expected { + t.Fatalf("unexpected stdout:\n\n%s", actual) + } +} + +// Ensure the "get" command can print the value of a key in a bucket. +func TestGetCommand_Run(t *testing.T) { + db := MustOpen(0666, nil) + defer db.Close() + + if err := db.Update(func(tx *bolt.Tx) error { + for _, name := range []string{"foo", "bar"} { + b, err := tx.CreateBucket([]byte(name)) + if err != nil { + return err + } + for i := 0; i < 3; i++ { + key := fmt.Sprintf("%s-%d", name, i) + val := fmt.Sprintf("val-%s-%d", name, i) + if err := b.Put([]byte(key), []byte(val)); err != nil { + return err + } + } + } + return nil + }); err != nil { + t.Fatal(err) + } + db.DB.Close() + + expected := "val-foo-1\n" + + // Run the command. + m := NewMain() + if err := m.Run("get", db.Path, "foo", "foo-1"); err != nil { + t.Fatal(err) + } else if actual := m.Stdout.String(); actual != expected { + t.Fatalf("unexpected stdout:\n\n%s", actual) + } +} + +// Main represents a test wrapper for main.Main that records output. +type Main struct { + *main.Main + Stdin bytes.Buffer + Stdout bytes.Buffer + Stderr bytes.Buffer +} + +// NewMain returns a new instance of Main. +func NewMain() *Main { + m := &Main{Main: main.NewMain()} + m.Main.Stdin = &m.Stdin + m.Main.Stdout = &m.Stdout + m.Main.Stderr = &m.Stderr + return m +} + +// MustOpen creates a Bolt database in a temporary location. +func MustOpen(mode os.FileMode, options *bolt.Options) *DB { + // Create temporary path. + f, _ := ioutil.TempFile("", "bolt-") + f.Close() + os.Remove(f.Name()) + + db, err := bolt.Open(f.Name(), mode, options) + if err != nil { + panic(err.Error()) + } + return &DB{DB: db, Path: f.Name()} +} + +// DB is a test wrapper for bolt.DB. +type DB struct { + *bolt.DB + Path string +} + +// Close closes and removes the database. +func (db *DB) Close() error { + defer os.Remove(db.Path) + return db.DB.Close() +} + +func TestCompactCommand_Run(t *testing.T) { + var s int64 + if err := binary.Read(crypto.Reader, binary.BigEndian, &s); err != nil { + t.Fatal(err) + } + rand.Seed(s) + + dstdb := MustOpen(0666, nil) + dstdb.Close() + + // fill the db + db := MustOpen(0666, nil) + if err := db.Update(func(tx *bolt.Tx) error { + n := 2 + rand.Intn(5) + for i := 0; i < n; i++ { + k := []byte(fmt.Sprintf("b%d", i)) + b, err := tx.CreateBucketIfNotExists(k) + if err != nil { + return err + } + if err := b.SetSequence(uint64(i)); err != nil { + return err + } + if err := fillBucket(b, append(k, '.')); err != nil { + return err + } + } + return nil + }); err != nil { + db.Close() + t.Fatal(err) + } + + // make the db grow by adding large values, and delete them. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte("large_vals")) + if err != nil { + return err + } + n := 5 + rand.Intn(5) + for i := 0; i < n; i++ { + v := make([]byte, 1000*1000*(1+rand.Intn(5))) + _, err := crypto.Read(v) + if err != nil { + return err + } + if err := b.Put([]byte(fmt.Sprintf("l%d", i)), v); err != nil { + return err + } + } + return nil + }); err != nil { + db.Close() + t.Fatal(err) + } + if err := db.Update(func(tx *bolt.Tx) error { + c := tx.Bucket([]byte("large_vals")).Cursor() + for k, _ := c.First(); k != nil; k, _ = c.Next() { + if err := c.Delete(); err != nil { + return err + } + } + return tx.DeleteBucket([]byte("large_vals")) + }); err != nil { + db.Close() + t.Fatal(err) + } + db.DB.Close() + defer db.Close() + defer dstdb.Close() + + dbChk, err := chkdb(db.Path) + if err != nil { + t.Fatal(err) + } + + m := NewMain() + if err := m.Run("compact", "-o", dstdb.Path, db.Path); err != nil { + t.Fatal(err) + } + + dbChkAfterCompact, err := chkdb(db.Path) + if err != nil { + t.Fatal(err) + } + + dstdbChk, err := chkdb(dstdb.Path) + if err != nil { + t.Fatal(err) + } + + if !bytes.Equal(dbChk, dbChkAfterCompact) { + t.Error("the original db has been touched") + } + if !bytes.Equal(dbChk, dstdbChk) { + t.Error("the compacted db data isn't the same than the original db") + } +} + +func fillBucket(b *bolt.Bucket, prefix []byte) error { + n := 10 + rand.Intn(50) + for i := 0; i < n; i++ { + v := make([]byte, 10*(1+rand.Intn(4))) + _, err := crypto.Read(v) + if err != nil { + return err + } + k := append(prefix, []byte(fmt.Sprintf("k%d", i))...) + if err := b.Put(k, v); err != nil { + return err + } + } + // limit depth of subbuckets + s := 2 + rand.Intn(4) + if len(prefix) > (2*s + 1) { + return nil + } + n = 1 + rand.Intn(3) + for i := 0; i < n; i++ { + k := append(prefix, []byte(fmt.Sprintf("b%d", i))...) + sb, err := b.CreateBucket(k) + if err != nil { + return err + } + if err := fillBucket(sb, append(k, '.')); err != nil { + return err + } + } + return nil +} + +func chkdb(path string) ([]byte, error) { + db, err := bolt.Open(path, 0666, nil) + if err != nil { + return nil, err + } + defer db.Close() + var buf bytes.Buffer + err = db.View(func(tx *bolt.Tx) error { + return tx.ForEach(func(name []byte, b *bolt.Bucket) error { + return walkBucket(b, name, nil, &buf) + }) + }) + if err != nil { + return nil, err + } + return buf.Bytes(), nil +} + +func walkBucket(parent *bolt.Bucket, k []byte, v []byte, w io.Writer) error { + if _, err := fmt.Fprintf(w, "%d:%x=%x\n", parent.Sequence(), k, v); err != nil { + return err + } + + // not a bucket, exit. + if v != nil { + return nil + } + return parent.ForEach(func(k, v []byte) error { + if v == nil { + return walkBucket(parent.Bucket(k), k, nil, w) + } + return walkBucket(parent, k, v, w) + }) +} diff --git a/vendor/etcd.io/bbolt/cursor.go b/vendor/etcd.io/bbolt/cursor.go new file mode 100644 index 0000000..98aeb44 --- /dev/null +++ b/vendor/etcd.io/bbolt/cursor.go @@ -0,0 +1,396 @@ +package bbolt + +import ( + "bytes" + "fmt" + "sort" +) + +// Cursor represents an iterator that can traverse over all key/value pairs in a bucket in sorted order. +// Cursors see nested buckets with value == nil. +// Cursors can be obtained from a transaction and are valid as long as the transaction is open. +// +// Keys and values returned from the cursor are only valid for the life of the transaction. +// +// Changing data while traversing with a cursor may cause it to be invalidated +// and return unexpected keys and/or values. You must reposition your cursor +// after mutating data. +type Cursor struct { + bucket *Bucket + stack []elemRef +} + +// Bucket returns the bucket that this cursor was created from. +func (c *Cursor) Bucket() *Bucket { + return c.bucket +} + +// First moves the cursor to the first item in the bucket and returns its key and value. +// If the bucket is empty then a nil key and value are returned. +// The returned key and value are only valid for the life of the transaction. +func (c *Cursor) First() (key []byte, value []byte) { + _assert(c.bucket.tx.db != nil, "tx closed") + c.stack = c.stack[:0] + p, n := c.bucket.pageNode(c.bucket.root) + c.stack = append(c.stack, elemRef{page: p, node: n, index: 0}) + c.first() + + // If we land on an empty page then move to the next value. + // https://github.com/boltdb/bolt/issues/450 + if c.stack[len(c.stack)-1].count() == 0 { + c.next() + } + + k, v, flags := c.keyValue() + if (flags & uint32(bucketLeafFlag)) != 0 { + return k, nil + } + return k, v + +} + +// Last moves the cursor to the last item in the bucket and returns its key and value. +// If the bucket is empty then a nil key and value are returned. +// The returned key and value are only valid for the life of the transaction. +func (c *Cursor) Last() (key []byte, value []byte) { + _assert(c.bucket.tx.db != nil, "tx closed") + c.stack = c.stack[:0] + p, n := c.bucket.pageNode(c.bucket.root) + ref := elemRef{page: p, node: n} + ref.index = ref.count() - 1 + c.stack = append(c.stack, ref) + c.last() + k, v, flags := c.keyValue() + if (flags & uint32(bucketLeafFlag)) != 0 { + return k, nil + } + return k, v +} + +// Next moves the cursor to the next item in the bucket and returns its key and value. +// If the cursor is at the end of the bucket then a nil key and value are returned. +// The returned key and value are only valid for the life of the transaction. +func (c *Cursor) Next() (key []byte, value []byte) { + _assert(c.bucket.tx.db != nil, "tx closed") + k, v, flags := c.next() + if (flags & uint32(bucketLeafFlag)) != 0 { + return k, nil + } + return k, v +} + +// Prev moves the cursor to the previous item in the bucket and returns its key and value. +// If the cursor is at the beginning of the bucket then a nil key and value are returned. +// The returned key and value are only valid for the life of the transaction. +func (c *Cursor) Prev() (key []byte, value []byte) { + _assert(c.bucket.tx.db != nil, "tx closed") + + // Attempt to move back one element until we're successful. + // Move up the stack as we hit the beginning of each page in our stack. + for i := len(c.stack) - 1; i >= 0; i-- { + elem := &c.stack[i] + if elem.index > 0 { + elem.index-- + break + } + c.stack = c.stack[:i] + } + + // If we've hit the end then return nil. + if len(c.stack) == 0 { + return nil, nil + } + + // Move down the stack to find the last element of the last leaf under this branch. + c.last() + k, v, flags := c.keyValue() + if (flags & uint32(bucketLeafFlag)) != 0 { + return k, nil + } + return k, v +} + +// Seek moves the cursor to a given key and returns it. +// If the key does not exist then the next key is used. If no keys +// follow, a nil key is returned. +// The returned key and value are only valid for the life of the transaction. +func (c *Cursor) Seek(seek []byte) (key []byte, value []byte) { + k, v, flags := c.seek(seek) + + // If we ended up after the last element of a page then move to the next one. + if ref := &c.stack[len(c.stack)-1]; ref.index >= ref.count() { + k, v, flags = c.next() + } + + if k == nil { + return nil, nil + } else if (flags & uint32(bucketLeafFlag)) != 0 { + return k, nil + } + return k, v +} + +// Delete removes the current key/value under the cursor from the bucket. +// Delete fails if current key/value is a bucket or if the transaction is not writable. +func (c *Cursor) Delete() error { + if c.bucket.tx.db == nil { + return ErrTxClosed + } else if !c.bucket.Writable() { + return ErrTxNotWritable + } + + key, _, flags := c.keyValue() + // Return an error if current value is a bucket. + if (flags & bucketLeafFlag) != 0 { + return ErrIncompatibleValue + } + c.node().del(key) + + return nil +} + +// seek moves the cursor to a given key and returns it. +// If the key does not exist then the next key is used. +func (c *Cursor) seek(seek []byte) (key []byte, value []byte, flags uint32) { + _assert(c.bucket.tx.db != nil, "tx closed") + + // Start from root page/node and traverse to correct page. + c.stack = c.stack[:0] + c.search(seek, c.bucket.root) + + // If this is a bucket then return a nil value. + return c.keyValue() +} + +// first moves the cursor to the first leaf element under the last page in the stack. +func (c *Cursor) first() { + for { + // Exit when we hit a leaf page. + var ref = &c.stack[len(c.stack)-1] + if ref.isLeaf() { + break + } + + // Keep adding pages pointing to the first element to the stack. + var pgid pgid + if ref.node != nil { + pgid = ref.node.inodes[ref.index].pgid + } else { + pgid = ref.page.branchPageElement(uint16(ref.index)).pgid + } + p, n := c.bucket.pageNode(pgid) + c.stack = append(c.stack, elemRef{page: p, node: n, index: 0}) + } +} + +// last moves the cursor to the last leaf element under the last page in the stack. +func (c *Cursor) last() { + for { + // Exit when we hit a leaf page. + ref := &c.stack[len(c.stack)-1] + if ref.isLeaf() { + break + } + + // Keep adding pages pointing to the last element in the stack. + var pgid pgid + if ref.node != nil { + pgid = ref.node.inodes[ref.index].pgid + } else { + pgid = ref.page.branchPageElement(uint16(ref.index)).pgid + } + p, n := c.bucket.pageNode(pgid) + + var nextRef = elemRef{page: p, node: n} + nextRef.index = nextRef.count() - 1 + c.stack = append(c.stack, nextRef) + } +} + +// next moves to the next leaf element and returns the key and value. +// If the cursor is at the last leaf element then it stays there and returns nil. +func (c *Cursor) next() (key []byte, value []byte, flags uint32) { + for { + // Attempt to move over one element until we're successful. + // Move up the stack as we hit the end of each page in our stack. + var i int + for i = len(c.stack) - 1; i >= 0; i-- { + elem := &c.stack[i] + if elem.index < elem.count()-1 { + elem.index++ + break + } + } + + // If we've hit the root page then stop and return. This will leave the + // cursor on the last element of the last page. + if i == -1 { + return nil, nil, 0 + } + + // Otherwise start from where we left off in the stack and find the + // first element of the first leaf page. + c.stack = c.stack[:i+1] + c.first() + + // If this is an empty page then restart and move back up the stack. + // https://github.com/boltdb/bolt/issues/450 + if c.stack[len(c.stack)-1].count() == 0 { + continue + } + + return c.keyValue() + } +} + +// search recursively performs a binary search against a given page/node until it finds a given key. +func (c *Cursor) search(key []byte, pgid pgid) { + p, n := c.bucket.pageNode(pgid) + if p != nil && (p.flags&(branchPageFlag|leafPageFlag)) == 0 { + panic(fmt.Sprintf("invalid page type: %d: %x", p.id, p.flags)) + } + e := elemRef{page: p, node: n} + c.stack = append(c.stack, e) + + // If we're on a leaf page/node then find the specific node. + if e.isLeaf() { + c.nsearch(key) + return + } + + if n != nil { + c.searchNode(key, n) + return + } + c.searchPage(key, p) +} + +func (c *Cursor) searchNode(key []byte, n *node) { + var exact bool + index := sort.Search(len(n.inodes), func(i int) bool { + // TODO(benbjohnson): Optimize this range search. It's a bit hacky right now. + // sort.Search() finds the lowest index where f() != -1 but we need the highest index. + ret := bytes.Compare(n.inodes[i].key, key) + if ret == 0 { + exact = true + } + return ret != -1 + }) + if !exact && index > 0 { + index-- + } + c.stack[len(c.stack)-1].index = index + + // Recursively search to the next page. + c.search(key, n.inodes[index].pgid) +} + +func (c *Cursor) searchPage(key []byte, p *page) { + // Binary search for the correct range. + inodes := p.branchPageElements() + + var exact bool + index := sort.Search(int(p.count), func(i int) bool { + // TODO(benbjohnson): Optimize this range search. It's a bit hacky right now. + // sort.Search() finds the lowest index where f() != -1 but we need the highest index. + ret := bytes.Compare(inodes[i].key(), key) + if ret == 0 { + exact = true + } + return ret != -1 + }) + if !exact && index > 0 { + index-- + } + c.stack[len(c.stack)-1].index = index + + // Recursively search to the next page. + c.search(key, inodes[index].pgid) +} + +// nsearch searches the leaf node on the top of the stack for a key. +func (c *Cursor) nsearch(key []byte) { + e := &c.stack[len(c.stack)-1] + p, n := e.page, e.node + + // If we have a node then search its inodes. + if n != nil { + index := sort.Search(len(n.inodes), func(i int) bool { + return bytes.Compare(n.inodes[i].key, key) != -1 + }) + e.index = index + return + } + + // If we have a page then search its leaf elements. + inodes := p.leafPageElements() + index := sort.Search(int(p.count), func(i int) bool { + return bytes.Compare(inodes[i].key(), key) != -1 + }) + e.index = index +} + +// keyValue returns the key and value of the current leaf element. +func (c *Cursor) keyValue() ([]byte, []byte, uint32) { + ref := &c.stack[len(c.stack)-1] + + // If the cursor is pointing to the end of page/node then return nil. + if ref.count() == 0 || ref.index >= ref.count() { + return nil, nil, 0 + } + + // Retrieve value from node. + if ref.node != nil { + inode := &ref.node.inodes[ref.index] + return inode.key, inode.value, inode.flags + } + + // Or retrieve value from page. + elem := ref.page.leafPageElement(uint16(ref.index)) + return elem.key(), elem.value(), elem.flags +} + +// node returns the node that the cursor is currently positioned on. +func (c *Cursor) node() *node { + _assert(len(c.stack) > 0, "accessing a node with a zero-length cursor stack") + + // If the top of the stack is a leaf node then just return it. + if ref := &c.stack[len(c.stack)-1]; ref.node != nil && ref.isLeaf() { + return ref.node + } + + // Start from root and traverse down the hierarchy. + var n = c.stack[0].node + if n == nil { + n = c.bucket.node(c.stack[0].page.id, nil) + } + for _, ref := range c.stack[:len(c.stack)-1] { + _assert(!n.isLeaf, "expected branch node") + n = n.childAt(ref.index) + } + _assert(n.isLeaf, "expected leaf node") + return n +} + +// elemRef represents a reference to an element on a given page/node. +type elemRef struct { + page *page + node *node + index int +} + +// isLeaf returns whether the ref is pointing at a leaf page/node. +func (r *elemRef) isLeaf() bool { + if r.node != nil { + return r.node.isLeaf + } + return (r.page.flags & leafPageFlag) != 0 +} + +// count returns the number of inodes or page elements. +func (r *elemRef) count() int { + if r.node != nil { + return len(r.node.inodes) + } + return int(r.page.count) +} diff --git a/vendor/etcd.io/bbolt/cursor_test.go b/vendor/etcd.io/bbolt/cursor_test.go new file mode 100644 index 0000000..d2a8bc7 --- /dev/null +++ b/vendor/etcd.io/bbolt/cursor_test.go @@ -0,0 +1,817 @@ +package bbolt_test + +import ( + "bytes" + "encoding/binary" + "fmt" + "log" + "os" + "reflect" + "sort" + "testing" + "testing/quick" + + bolt "go.etcd.io/bbolt" +) + +// Ensure that a cursor can return a reference to the bucket that created it. +func TestCursor_Bucket(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if cb := b.Cursor().Bucket(); !reflect.DeepEqual(cb, b) { + t.Fatal("cursor bucket mismatch") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx cursor can seek to the appropriate keys. +func TestCursor_Seek(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("0001")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("bar"), []byte("0002")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte("0003")); err != nil { + t.Fatal(err) + } + + if _, err := b.CreateBucket([]byte("bkt")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + c := tx.Bucket([]byte("widgets")).Cursor() + + // Exact match should go to the key. + if k, v := c.Seek([]byte("bar")); !bytes.Equal(k, []byte("bar")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte("0002")) { + t.Fatalf("unexpected value: %v", v) + } + + // Inexact match should go to the next key. + if k, v := c.Seek([]byte("bas")); !bytes.Equal(k, []byte("baz")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte("0003")) { + t.Fatalf("unexpected value: %v", v) + } + + // Low key should go to the first key. + if k, v := c.Seek([]byte("")); !bytes.Equal(k, []byte("bar")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte("0002")) { + t.Fatalf("unexpected value: %v", v) + } + + // High key should return no key. + if k, v := c.Seek([]byte("zzz")); k != nil { + t.Fatalf("expected nil key: %v", k) + } else if v != nil { + t.Fatalf("expected nil value: %v", v) + } + + // Buckets should return their key but no value. + if k, v := c.Seek([]byte("bkt")); !bytes.Equal(k, []byte("bkt")) { + t.Fatalf("unexpected key: %v", k) + } else if v != nil { + t.Fatalf("expected nil value: %v", v) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +func TestCursor_Delete(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + const count = 1000 + + // Insert every other key between 0 and $count. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + for i := 0; i < count; i += 1 { + k := make([]byte, 8) + binary.BigEndian.PutUint64(k, uint64(i)) + if err := b.Put(k, make([]byte, 100)); err != nil { + t.Fatal(err) + } + } + if _, err := b.CreateBucket([]byte("sub")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + c := tx.Bucket([]byte("widgets")).Cursor() + bound := make([]byte, 8) + binary.BigEndian.PutUint64(bound, uint64(count/2)) + for key, _ := c.First(); bytes.Compare(key, bound) < 0; key, _ = c.Next() { + if err := c.Delete(); err != nil { + t.Fatal(err) + } + } + + c.Seek([]byte("sub")) + if err := c.Delete(); err != bolt.ErrIncompatibleValue { + t.Fatalf("unexpected error: %s", err) + } + + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + stats := tx.Bucket([]byte("widgets")).Stats() + if stats.KeyN != count/2+1 { + t.Fatalf("unexpected KeyN: %d", stats.KeyN) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx cursor can seek to the appropriate keys when there are a +// large number of keys. This test also checks that seek will always move +// forward to the next key. +// +// Related: https://github.com/boltdb/bolt/pull/187 +func TestCursor_Seek_Large(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var count = 10000 + + // Insert every other key between 0 and $count. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + for i := 0; i < count; i += 100 { + for j := i; j < i+100; j += 2 { + k := make([]byte, 8) + binary.BigEndian.PutUint64(k, uint64(j)) + if err := b.Put(k, make([]byte, 100)); err != nil { + t.Fatal(err) + } + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + c := tx.Bucket([]byte("widgets")).Cursor() + for i := 0; i < count; i++ { + seek := make([]byte, 8) + binary.BigEndian.PutUint64(seek, uint64(i)) + + k, _ := c.Seek(seek) + + // The last seek is beyond the end of the the range so + // it should return nil. + if i == count-1 { + if k != nil { + t.Fatal("expected nil key") + } + continue + } + + // Otherwise we should seek to the exact key or the next key. + num := binary.BigEndian.Uint64(k) + if i%2 == 0 { + if num != uint64(i) { + t.Fatalf("unexpected num: %d", num) + } + } else { + if num != uint64(i+1) { + t.Fatalf("unexpected num: %d", num) + } + } + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a cursor can iterate over an empty bucket without error. +func TestCursor_EmptyBucket(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + c := tx.Bucket([]byte("widgets")).Cursor() + k, v := c.First() + if k != nil { + t.Fatalf("unexpected key: %v", k) + } else if v != nil { + t.Fatalf("unexpected value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx cursor can reverse iterate over an empty bucket without error. +func TestCursor_EmptyBucketReverse(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + t.Fatal(err) + } + if err := db.View(func(tx *bolt.Tx) error { + c := tx.Bucket([]byte("widgets")).Cursor() + k, v := c.Last() + if k != nil { + t.Fatalf("unexpected key: %v", k) + } else if v != nil { + t.Fatalf("unexpected value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx cursor can iterate over a single root with a couple elements. +func TestCursor_Iterate_Leaf(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte{}); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte{0}); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("bar"), []byte{1}); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + tx, err := db.Begin(false) + if err != nil { + t.Fatal(err) + } + defer func() { _ = tx.Rollback() }() + + c := tx.Bucket([]byte("widgets")).Cursor() + + k, v := c.First() + if !bytes.Equal(k, []byte("bar")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte{1}) { + t.Fatalf("unexpected value: %v", v) + } + + k, v = c.Next() + if !bytes.Equal(k, []byte("baz")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte{}) { + t.Fatalf("unexpected value: %v", v) + } + + k, v = c.Next() + if !bytes.Equal(k, []byte("foo")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte{0}) { + t.Fatalf("unexpected value: %v", v) + } + + k, v = c.Next() + if k != nil { + t.Fatalf("expected nil key: %v", k) + } else if v != nil { + t.Fatalf("expected nil value: %v", v) + } + + k, v = c.Next() + if k != nil { + t.Fatalf("expected nil key: %v", k) + } else if v != nil { + t.Fatalf("expected nil value: %v", v) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx cursor can iterate in reverse over a single root with a couple elements. +func TestCursor_LeafRootReverse(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte{}); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte{0}); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("bar"), []byte{1}); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + tx, err := db.Begin(false) + if err != nil { + t.Fatal(err) + } + c := tx.Bucket([]byte("widgets")).Cursor() + + if k, v := c.Last(); !bytes.Equal(k, []byte("foo")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte{0}) { + t.Fatalf("unexpected value: %v", v) + } + + if k, v := c.Prev(); !bytes.Equal(k, []byte("baz")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte{}) { + t.Fatalf("unexpected value: %v", v) + } + + if k, v := c.Prev(); !bytes.Equal(k, []byte("bar")) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, []byte{1}) { + t.Fatalf("unexpected value: %v", v) + } + + if k, v := c.Prev(); k != nil { + t.Fatalf("expected nil key: %v", k) + } else if v != nil { + t.Fatalf("expected nil value: %v", v) + } + + if k, v := c.Prev(); k != nil { + t.Fatalf("expected nil key: %v", k) + } else if v != nil { + t.Fatalf("expected nil value: %v", v) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx cursor can restart from the beginning. +func TestCursor_Restart(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("bar"), []byte{}); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte{}); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + tx, err := db.Begin(false) + if err != nil { + t.Fatal(err) + } + c := tx.Bucket([]byte("widgets")).Cursor() + + if k, _ := c.First(); !bytes.Equal(k, []byte("bar")) { + t.Fatalf("unexpected key: %v", k) + } + if k, _ := c.Next(); !bytes.Equal(k, []byte("foo")) { + t.Fatalf("unexpected key: %v", k) + } + + if k, _ := c.First(); !bytes.Equal(k, []byte("bar")) { + t.Fatalf("unexpected key: %v", k) + } + if k, _ := c.Next(); !bytes.Equal(k, []byte("foo")) { + t.Fatalf("unexpected key: %v", k) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } +} + +// Ensure that a cursor can skip over empty pages that have been deleted. +func TestCursor_First_EmptyPages(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + // Create 1000 keys in the "widgets" bucket. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + for i := 0; i < 1000; i++ { + if err := b.Put(u64tob(uint64(i)), []byte{}); err != nil { + t.Fatal(err) + } + } + + return nil + }); err != nil { + t.Fatal(err) + } + + // Delete half the keys and then try to iterate. + if err := db.Update(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for i := 0; i < 600; i++ { + if err := b.Delete(u64tob(uint64(i))); err != nil { + t.Fatal(err) + } + } + + c := b.Cursor() + var n int + for k, _ := c.First(); k != nil; k, _ = c.Next() { + n++ + } + if n != 400 { + t.Fatalf("unexpected key count: %d", n) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx can iterate over all elements in a bucket. +func TestCursor_QuickCheck(t *testing.T) { + f := func(items testdata) bool { + db := MustOpenDB() + defer db.MustClose() + + // Bulk insert all values. + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + for _, item := range items { + if err := b.Put(item.Key, item.Value); err != nil { + t.Fatal(err) + } + } + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + + // Sort test data. + sort.Sort(items) + + // Iterate over all items and check consistency. + var index = 0 + tx, err = db.Begin(false) + if err != nil { + t.Fatal(err) + } + + c := tx.Bucket([]byte("widgets")).Cursor() + for k, v := c.First(); k != nil && index < len(items); k, v = c.Next() { + if !bytes.Equal(k, items[index].Key) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, items[index].Value) { + t.Fatalf("unexpected value: %v", v) + } + index++ + } + if len(items) != index { + t.Fatalf("unexpected item count: %v, expected %v", len(items), index) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + + return true + } + if err := quick.Check(f, qconfig()); err != nil { + t.Error(err) + } +} + +// Ensure that a transaction can iterate over all elements in a bucket in reverse. +func TestCursor_QuickCheck_Reverse(t *testing.T) { + f := func(items testdata) bool { + db := MustOpenDB() + defer db.MustClose() + + // Bulk insert all values. + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + for _, item := range items { + if err := b.Put(item.Key, item.Value); err != nil { + t.Fatal(err) + } + } + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + + // Sort test data. + sort.Sort(revtestdata(items)) + + // Iterate over all items and check consistency. + var index = 0 + tx, err = db.Begin(false) + if err != nil { + t.Fatal(err) + } + c := tx.Bucket([]byte("widgets")).Cursor() + for k, v := c.Last(); k != nil && index < len(items); k, v = c.Prev() { + if !bytes.Equal(k, items[index].Key) { + t.Fatalf("unexpected key: %v", k) + } else if !bytes.Equal(v, items[index].Value) { + t.Fatalf("unexpected value: %v", v) + } + index++ + } + if len(items) != index { + t.Fatalf("unexpected item count: %v, expected %v", len(items), index) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + + return true + } + if err := quick.Check(f, qconfig()); err != nil { + t.Error(err) + } +} + +// Ensure that a Tx cursor can iterate over subbuckets. +func TestCursor_QuickCheck_BucketsOnly(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if _, err := b.CreateBucket([]byte("foo")); err != nil { + t.Fatal(err) + } + if _, err := b.CreateBucket([]byte("bar")); err != nil { + t.Fatal(err) + } + if _, err := b.CreateBucket([]byte("baz")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + var names []string + c := tx.Bucket([]byte("widgets")).Cursor() + for k, v := c.First(); k != nil; k, v = c.Next() { + names = append(names, string(k)) + if v != nil { + t.Fatalf("unexpected value: %v", v) + } + } + if !reflect.DeepEqual(names, []string{"bar", "baz", "foo"}) { + t.Fatalf("unexpected names: %+v", names) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx cursor can reverse iterate over subbuckets. +func TestCursor_QuickCheck_BucketsOnly_Reverse(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if _, err := b.CreateBucket([]byte("foo")); err != nil { + t.Fatal(err) + } + if _, err := b.CreateBucket([]byte("bar")); err != nil { + t.Fatal(err) + } + if _, err := b.CreateBucket([]byte("baz")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + var names []string + c := tx.Bucket([]byte("widgets")).Cursor() + for k, v := c.Last(); k != nil; k, v = c.Prev() { + names = append(names, string(k)) + if v != nil { + t.Fatalf("unexpected value: %v", v) + } + } + if !reflect.DeepEqual(names, []string{"foo", "baz", "bar"}) { + t.Fatalf("unexpected names: %+v", names) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +func ExampleCursor() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Start a read-write transaction. + if err := db.Update(func(tx *bolt.Tx) error { + // Create a new bucket. + b, err := tx.CreateBucket([]byte("animals")) + if err != nil { + return err + } + + // Insert data into a bucket. + if err := b.Put([]byte("dog"), []byte("fun")); err != nil { + log.Fatal(err) + } + if err := b.Put([]byte("cat"), []byte("lame")); err != nil { + log.Fatal(err) + } + if err := b.Put([]byte("liger"), []byte("awesome")); err != nil { + log.Fatal(err) + } + + // Create a cursor for iteration. + c := b.Cursor() + + // Iterate over items in sorted key order. This starts from the + // first key/value pair and updates the k/v variables to the + // next key/value on each iteration. + // + // The loop finishes at the end of the cursor when a nil key is returned. + for k, v := c.First(); k != nil; k, v = c.Next() { + fmt.Printf("A %s is %s.\n", k, v) + } + + return nil + }); err != nil { + log.Fatal(err) + } + + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // A cat is lame. + // A dog is fun. + // A liger is awesome. +} + +func ExampleCursor_reverse() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Start a read-write transaction. + if err := db.Update(func(tx *bolt.Tx) error { + // Create a new bucket. + b, err := tx.CreateBucket([]byte("animals")) + if err != nil { + return err + } + + // Insert data into a bucket. + if err := b.Put([]byte("dog"), []byte("fun")); err != nil { + log.Fatal(err) + } + if err := b.Put([]byte("cat"), []byte("lame")); err != nil { + log.Fatal(err) + } + if err := b.Put([]byte("liger"), []byte("awesome")); err != nil { + log.Fatal(err) + } + + // Create a cursor for iteration. + c := b.Cursor() + + // Iterate over items in reverse sorted key order. This starts + // from the last key/value pair and updates the k/v variables to + // the previous key/value on each iteration. + // + // The loop finishes at the beginning of the cursor when a nil key + // is returned. + for k, v := c.Last(); k != nil; k, v = c.Prev() { + fmt.Printf("A %s is %s.\n", k, v) + } + + return nil + }); err != nil { + log.Fatal(err) + } + + // Close the database to release the file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // A liger is awesome. + // A dog is fun. + // A cat is lame. +} diff --git a/vendor/etcd.io/bbolt/db.go b/vendor/etcd.io/bbolt/db.go new file mode 100644 index 0000000..80b0095 --- /dev/null +++ b/vendor/etcd.io/bbolt/db.go @@ -0,0 +1,1174 @@ +package bbolt + +import ( + "errors" + "fmt" + "hash/fnv" + "log" + "os" + "runtime" + "sort" + "sync" + "time" + "unsafe" +) + +// The largest step that can be taken when remapping the mmap. +const maxMmapStep = 1 << 30 // 1GB + +// The data file format version. +const version = 2 + +// Represents a marker value to indicate that a file is a Bolt DB. +const magic uint32 = 0xED0CDAED + +const pgidNoFreelist pgid = 0xffffffffffffffff + +// IgnoreNoSync specifies whether the NoSync field of a DB is ignored when +// syncing changes to a file. This is required as some operating systems, +// such as OpenBSD, do not have a unified buffer cache (UBC) and writes +// must be synchronized using the msync(2) syscall. +const IgnoreNoSync = runtime.GOOS == "openbsd" + +// Default values if not set in a DB instance. +const ( + DefaultMaxBatchSize int = 1000 + DefaultMaxBatchDelay = 10 * time.Millisecond + DefaultAllocSize = 16 * 1024 * 1024 +) + +// default page size for db is set to the OS page size. +var defaultPageSize = os.Getpagesize() + +// The time elapsed between consecutive file locking attempts. +const flockRetryTimeout = 50 * time.Millisecond + +// FreelistType is the type of the freelist backend +type FreelistType string + +const ( + // FreelistArrayType indicates backend freelist type is array + FreelistArrayType = FreelistType("array") + // FreelistMapType indicates backend freelist type is hashmap + FreelistMapType = FreelistType("hashmap") +) + +// DB represents a collection of buckets persisted to a file on disk. +// All data access is performed through transactions which can be obtained through the DB. +// All the functions on DB will return a ErrDatabaseNotOpen if accessed before Open() is called. +type DB struct { + // When enabled, the database will perform a Check() after every commit. + // A panic is issued if the database is in an inconsistent state. This + // flag has a large performance impact so it should only be used for + // debugging purposes. + StrictMode bool + + // Setting the NoSync flag will cause the database to skip fsync() + // calls after each commit. This can be useful when bulk loading data + // into a database and you can restart the bulk load in the event of + // a system failure or database corruption. Do not set this flag for + // normal use. + // + // If the package global IgnoreNoSync constant is true, this value is + // ignored. See the comment on that constant for more details. + // + // THIS IS UNSAFE. PLEASE USE WITH CAUTION. + NoSync bool + + // When true, skips syncing freelist to disk. This improves the database + // write performance under normal operation, but requires a full database + // re-sync during recovery. + NoFreelistSync bool + + // FreelistType sets the backend freelist type. There are two options. Array which is simple but endures + // dramatic performance degradation if database is large and framentation in freelist is common. + // The alternative one is using hashmap, it is faster in almost all circumstances + // but it doesn't guarantee that it offers the smallest page id available. In normal case it is safe. + // The default type is array + FreelistType FreelistType + + // When true, skips the truncate call when growing the database. + // Setting this to true is only safe on non-ext3/ext4 systems. + // Skipping truncation avoids preallocation of hard drive space and + // bypasses a truncate() and fsync() syscall on remapping. + // + // https://github.com/boltdb/bolt/issues/284 + NoGrowSync bool + + // If you want to read the entire database fast, you can set MmapFlag to + // syscall.MAP_POPULATE on Linux 2.6.23+ for sequential read-ahead. + MmapFlags int + + // MaxBatchSize is the maximum size of a batch. Default value is + // copied from DefaultMaxBatchSize in Open. + // + // If <=0, disables batching. + // + // Do not change concurrently with calls to Batch. + MaxBatchSize int + + // MaxBatchDelay is the maximum delay before a batch starts. + // Default value is copied from DefaultMaxBatchDelay in Open. + // + // If <=0, effectively disables batching. + // + // Do not change concurrently with calls to Batch. + MaxBatchDelay time.Duration + + // AllocSize is the amount of space allocated when the database + // needs to create new pages. This is done to amortize the cost + // of truncate() and fsync() when growing the data file. + AllocSize int + + path string + openFile func(string, int, os.FileMode) (*os.File, error) + file *os.File + dataref []byte // mmap'ed readonly, write throws SEGV + data *[maxMapSize]byte + datasz int + filesz int // current on disk file size + meta0 *meta + meta1 *meta + pageSize int + opened bool + rwtx *Tx + txs []*Tx + stats Stats + + freelist *freelist + freelistLoad sync.Once + + pagePool sync.Pool + + batchMu sync.Mutex + batch *batch + + rwlock sync.Mutex // Allows only one writer at a time. + metalock sync.Mutex // Protects meta page access. + mmaplock sync.RWMutex // Protects mmap access during remapping. + statlock sync.RWMutex // Protects stats access. + + ops struct { + writeAt func(b []byte, off int64) (n int, err error) + } + + // Read only mode. + // When true, Update() and Begin(true) return ErrDatabaseReadOnly immediately. + readOnly bool +} + +// Path returns the path to currently open database file. +func (db *DB) Path() string { + return db.path +} + +// GoString returns the Go string representation of the database. +func (db *DB) GoString() string { + return fmt.Sprintf("bolt.DB{path:%q}", db.path) +} + +// String returns the string representation of the database. +func (db *DB) String() string { + return fmt.Sprintf("DB<%q>", db.path) +} + +// Open creates and opens a database at the given path. +// If the file does not exist then it will be created automatically. +// Passing in nil options will cause Bolt to open the database with the default options. +func Open(path string, mode os.FileMode, options *Options) (*DB, error) { + db := &DB{ + opened: true, + } + // Set default options if no options are provided. + if options == nil { + options = DefaultOptions + } + db.NoSync = options.NoSync + db.NoGrowSync = options.NoGrowSync + db.MmapFlags = options.MmapFlags + db.NoFreelistSync = options.NoFreelistSync + db.FreelistType = options.FreelistType + + // Set default values for later DB operations. + db.MaxBatchSize = DefaultMaxBatchSize + db.MaxBatchDelay = DefaultMaxBatchDelay + db.AllocSize = DefaultAllocSize + + flag := os.O_RDWR + if options.ReadOnly { + flag = os.O_RDONLY + db.readOnly = true + } + + db.openFile = options.OpenFile + if db.openFile == nil { + db.openFile = os.OpenFile + } + + // Open data file and separate sync handler for metadata writes. + var err error + if db.file, err = db.openFile(path, flag|os.O_CREATE, mode); err != nil { + _ = db.close() + return nil, err + } + db.path = db.file.Name() + + // Lock file so that other processes using Bolt in read-write mode cannot + // use the database at the same time. This would cause corruption since + // the two processes would write meta pages and free pages separately. + // The database file is locked exclusively (only one process can grab the lock) + // if !options.ReadOnly. + // The database file is locked using the shared lock (more than one process may + // hold a lock at the same time) otherwise (options.ReadOnly is set). + if err := flock(db, !db.readOnly, options.Timeout); err != nil { + _ = db.close() + return nil, err + } + + // Default values for test hooks + db.ops.writeAt = db.file.WriteAt + + if db.pageSize = options.PageSize; db.pageSize == 0 { + // Set the default page size to the OS page size. + db.pageSize = defaultPageSize + } + + // Initialize the database if it doesn't exist. + if info, err := db.file.Stat(); err != nil { + _ = db.close() + return nil, err + } else if info.Size() == 0 { + // Initialize new files with meta pages. + if err := db.init(); err != nil { + // clean up file descriptor on initialization fail + _ = db.close() + return nil, err + } + } else { + // Read the first meta page to determine the page size. + var buf [0x1000]byte + // If we can't read the page size, but can read a page, assume + // it's the same as the OS or one given -- since that's how the + // page size was chosen in the first place. + // + // If the first page is invalid and this OS uses a different + // page size than what the database was created with then we + // are out of luck and cannot access the database. + // + // TODO: scan for next page + if bw, err := db.file.ReadAt(buf[:], 0); err == nil && bw == len(buf) { + if m := db.pageInBuffer(buf[:], 0).meta(); m.validate() == nil { + db.pageSize = int(m.pageSize) + } + } else { + _ = db.close() + return nil, ErrInvalid + } + } + + // Initialize page pool. + db.pagePool = sync.Pool{ + New: func() interface{} { + return make([]byte, db.pageSize) + }, + } + + // Memory map the data file. + if err := db.mmap(options.InitialMmapSize); err != nil { + _ = db.close() + return nil, err + } + + if db.readOnly { + return db, nil + } + + db.loadFreelist() + + // Flush freelist when transitioning from no sync to sync so + // NoFreelistSync unaware boltdb can open the db later. + if !db.NoFreelistSync && !db.hasSyncedFreelist() { + tx, err := db.Begin(true) + if tx != nil { + err = tx.Commit() + } + if err != nil { + _ = db.close() + return nil, err + } + } + + // Mark the database as opened and return. + return db, nil +} + +// loadFreelist reads the freelist if it is synced, or reconstructs it +// by scanning the DB if it is not synced. It assumes there are no +// concurrent accesses being made to the freelist. +func (db *DB) loadFreelist() { + db.freelistLoad.Do(func() { + db.freelist = newFreelist(db.FreelistType) + if !db.hasSyncedFreelist() { + // Reconstruct free list by scanning the DB. + db.freelist.readIDs(db.freepages()) + } else { + // Read free list from freelist page. + db.freelist.read(db.page(db.meta().freelist)) + } + db.stats.FreePageN = db.freelist.free_count() + }) +} + +func (db *DB) hasSyncedFreelist() bool { + return db.meta().freelist != pgidNoFreelist +} + +// mmap opens the underlying memory-mapped file and initializes the meta references. +// minsz is the minimum size that the new mmap can be. +func (db *DB) mmap(minsz int) error { + db.mmaplock.Lock() + defer db.mmaplock.Unlock() + + info, err := db.file.Stat() + if err != nil { + return fmt.Errorf("mmap stat error: %s", err) + } else if int(info.Size()) < db.pageSize*2 { + return fmt.Errorf("file size too small") + } + + // Ensure the size is at least the minimum size. + var size = int(info.Size()) + if size < minsz { + size = minsz + } + size, err = db.mmapSize(size) + if err != nil { + return err + } + + // Dereference all mmap references before unmapping. + if db.rwtx != nil { + db.rwtx.root.dereference() + } + + // Unmap existing data before continuing. + if err := db.munmap(); err != nil { + return err + } + + // Memory-map the data file as a byte slice. + if err := mmap(db, size); err != nil { + return err + } + + // Save references to the meta pages. + db.meta0 = db.page(0).meta() + db.meta1 = db.page(1).meta() + + // Validate the meta pages. We only return an error if both meta pages fail + // validation, since meta0 failing validation means that it wasn't saved + // properly -- but we can recover using meta1. And vice-versa. + err0 := db.meta0.validate() + err1 := db.meta1.validate() + if err0 != nil && err1 != nil { + return err0 + } + + return nil +} + +// munmap unmaps the data file from memory. +func (db *DB) munmap() error { + if err := munmap(db); err != nil { + return fmt.Errorf("unmap error: " + err.Error()) + } + return nil +} + +// mmapSize determines the appropriate size for the mmap given the current size +// of the database. The minimum size is 32KB and doubles until it reaches 1GB. +// Returns an error if the new mmap size is greater than the max allowed. +func (db *DB) mmapSize(size int) (int, error) { + // Double the size from 32KB until 1GB. + for i := uint(15); i <= 30; i++ { + if size <= 1< maxMapSize { + return 0, fmt.Errorf("mmap too large") + } + + // If larger than 1GB then grow by 1GB at a time. + sz := int64(size) + if remainder := sz % int64(maxMmapStep); remainder > 0 { + sz += int64(maxMmapStep) - remainder + } + + // Ensure that the mmap size is a multiple of the page size. + // This should always be true since we're incrementing in MBs. + pageSize := int64(db.pageSize) + if (sz % pageSize) != 0 { + sz = ((sz / pageSize) + 1) * pageSize + } + + // If we've exceeded the max size then only grow up to the max size. + if sz > maxMapSize { + sz = maxMapSize + } + + return int(sz), nil +} + +// init creates a new database file and initializes its meta pages. +func (db *DB) init() error { + // Create two meta pages on a buffer. + buf := make([]byte, db.pageSize*4) + for i := 0; i < 2; i++ { + p := db.pageInBuffer(buf[:], pgid(i)) + p.id = pgid(i) + p.flags = metaPageFlag + + // Initialize the meta page. + m := p.meta() + m.magic = magic + m.version = version + m.pageSize = uint32(db.pageSize) + m.freelist = 2 + m.root = bucket{root: 3} + m.pgid = 4 + m.txid = txid(i) + m.checksum = m.sum64() + } + + // Write an empty freelist at page 3. + p := db.pageInBuffer(buf[:], pgid(2)) + p.id = pgid(2) + p.flags = freelistPageFlag + p.count = 0 + + // Write an empty leaf page at page 4. + p = db.pageInBuffer(buf[:], pgid(3)) + p.id = pgid(3) + p.flags = leafPageFlag + p.count = 0 + + // Write the buffer to our data file. + if _, err := db.ops.writeAt(buf, 0); err != nil { + return err + } + if err := fdatasync(db); err != nil { + return err + } + + return nil +} + +// Close releases all database resources. +// It will block waiting for any open transactions to finish +// before closing the database and returning. +func (db *DB) Close() error { + db.rwlock.Lock() + defer db.rwlock.Unlock() + + db.metalock.Lock() + defer db.metalock.Unlock() + + db.mmaplock.Lock() + defer db.mmaplock.Unlock() + + return db.close() +} + +func (db *DB) close() error { + if !db.opened { + return nil + } + + db.opened = false + + db.freelist = nil + + // Clear ops. + db.ops.writeAt = nil + + // Close the mmap. + if err := db.munmap(); err != nil { + return err + } + + // Close file handles. + if db.file != nil { + // No need to unlock read-only file. + if !db.readOnly { + // Unlock the file. + if err := funlock(db); err != nil { + log.Printf("bolt.Close(): funlock error: %s", err) + } + } + + // Close the file descriptor. + if err := db.file.Close(); err != nil { + return fmt.Errorf("db file close: %s", err) + } + db.file = nil + } + + db.path = "" + return nil +} + +// Begin starts a new transaction. +// Multiple read-only transactions can be used concurrently but only one +// write transaction can be used at a time. Starting multiple write transactions +// will cause the calls to block and be serialized until the current write +// transaction finishes. +// +// Transactions should not be dependent on one another. Opening a read +// transaction and a write transaction in the same goroutine can cause the +// writer to deadlock because the database periodically needs to re-mmap itself +// as it grows and it cannot do that while a read transaction is open. +// +// If a long running read transaction (for example, a snapshot transaction) is +// needed, you might want to set DB.InitialMmapSize to a large enough value +// to avoid potential blocking of write transaction. +// +// IMPORTANT: You must close read-only transactions after you are finished or +// else the database will not reclaim old pages. +func (db *DB) Begin(writable bool) (*Tx, error) { + if writable { + return db.beginRWTx() + } + return db.beginTx() +} + +func (db *DB) beginTx() (*Tx, error) { + // Lock the meta pages while we initialize the transaction. We obtain + // the meta lock before the mmap lock because that's the order that the + // write transaction will obtain them. + db.metalock.Lock() + + // Obtain a read-only lock on the mmap. When the mmap is remapped it will + // obtain a write lock so all transactions must finish before it can be + // remapped. + db.mmaplock.RLock() + + // Exit if the database is not open yet. + if !db.opened { + db.mmaplock.RUnlock() + db.metalock.Unlock() + return nil, ErrDatabaseNotOpen + } + + // Create a transaction associated with the database. + t := &Tx{} + t.init(db) + + // Keep track of transaction until it closes. + db.txs = append(db.txs, t) + n := len(db.txs) + + // Unlock the meta pages. + db.metalock.Unlock() + + // Update the transaction stats. + db.statlock.Lock() + db.stats.TxN++ + db.stats.OpenTxN = n + db.statlock.Unlock() + + return t, nil +} + +func (db *DB) beginRWTx() (*Tx, error) { + // If the database was opened with Options.ReadOnly, return an error. + if db.readOnly { + return nil, ErrDatabaseReadOnly + } + + // Obtain writer lock. This is released by the transaction when it closes. + // This enforces only one writer transaction at a time. + db.rwlock.Lock() + + // Once we have the writer lock then we can lock the meta pages so that + // we can set up the transaction. + db.metalock.Lock() + defer db.metalock.Unlock() + + // Exit if the database is not open yet. + if !db.opened { + db.rwlock.Unlock() + return nil, ErrDatabaseNotOpen + } + + // Create a transaction associated with the database. + t := &Tx{writable: true} + t.init(db) + db.rwtx = t + db.freePages() + return t, nil +} + +// freePages releases any pages associated with closed read-only transactions. +func (db *DB) freePages() { + // Free all pending pages prior to earliest open transaction. + sort.Sort(txsById(db.txs)) + minid := txid(0xFFFFFFFFFFFFFFFF) + if len(db.txs) > 0 { + minid = db.txs[0].meta.txid + } + if minid > 0 { + db.freelist.release(minid - 1) + } + // Release unused txid extents. + for _, t := range db.txs { + db.freelist.releaseRange(minid, t.meta.txid-1) + minid = t.meta.txid + 1 + } + db.freelist.releaseRange(minid, txid(0xFFFFFFFFFFFFFFFF)) + // Any page both allocated and freed in an extent is safe to release. +} + +type txsById []*Tx + +func (t txsById) Len() int { return len(t) } +func (t txsById) Swap(i, j int) { t[i], t[j] = t[j], t[i] } +func (t txsById) Less(i, j int) bool { return t[i].meta.txid < t[j].meta.txid } + +// removeTx removes a transaction from the database. +func (db *DB) removeTx(tx *Tx) { + // Release the read lock on the mmap. + db.mmaplock.RUnlock() + + // Use the meta lock to restrict access to the DB object. + db.metalock.Lock() + + // Remove the transaction. + for i, t := range db.txs { + if t == tx { + last := len(db.txs) - 1 + db.txs[i] = db.txs[last] + db.txs[last] = nil + db.txs = db.txs[:last] + break + } + } + n := len(db.txs) + + // Unlock the meta pages. + db.metalock.Unlock() + + // Merge statistics. + db.statlock.Lock() + db.stats.OpenTxN = n + db.stats.TxStats.add(&tx.stats) + db.statlock.Unlock() +} + +// Update executes a function within the context of a read-write managed transaction. +// If no error is returned from the function then the transaction is committed. +// If an error is returned then the entire transaction is rolled back. +// Any error that is returned from the function or returned from the commit is +// returned from the Update() method. +// +// Attempting to manually commit or rollback within the function will cause a panic. +func (db *DB) Update(fn func(*Tx) error) error { + t, err := db.Begin(true) + if err != nil { + return err + } + + // Make sure the transaction rolls back in the event of a panic. + defer func() { + if t.db != nil { + t.rollback() + } + }() + + // Mark as a managed tx so that the inner function cannot manually commit. + t.managed = true + + // If an error is returned from the function then rollback and return error. + err = fn(t) + t.managed = false + if err != nil { + _ = t.Rollback() + return err + } + + return t.Commit() +} + +// View executes a function within the context of a managed read-only transaction. +// Any error that is returned from the function is returned from the View() method. +// +// Attempting to manually rollback within the function will cause a panic. +func (db *DB) View(fn func(*Tx) error) error { + t, err := db.Begin(false) + if err != nil { + return err + } + + // Make sure the transaction rolls back in the event of a panic. + defer func() { + if t.db != nil { + t.rollback() + } + }() + + // Mark as a managed tx so that the inner function cannot manually rollback. + t.managed = true + + // If an error is returned from the function then pass it through. + err = fn(t) + t.managed = false + if err != nil { + _ = t.Rollback() + return err + } + + return t.Rollback() +} + +// Batch calls fn as part of a batch. It behaves similar to Update, +// except: +// +// 1. concurrent Batch calls can be combined into a single Bolt +// transaction. +// +// 2. the function passed to Batch may be called multiple times, +// regardless of whether it returns error or not. +// +// This means that Batch function side effects must be idempotent and +// take permanent effect only after a successful return is seen in +// caller. +// +// The maximum batch size and delay can be adjusted with DB.MaxBatchSize +// and DB.MaxBatchDelay, respectively. +// +// Batch is only useful when there are multiple goroutines calling it. +func (db *DB) Batch(fn func(*Tx) error) error { + errCh := make(chan error, 1) + + db.batchMu.Lock() + if (db.batch == nil) || (db.batch != nil && len(db.batch.calls) >= db.MaxBatchSize) { + // There is no existing batch, or the existing batch is full; start a new one. + db.batch = &batch{ + db: db, + } + db.batch.timer = time.AfterFunc(db.MaxBatchDelay, db.batch.trigger) + } + db.batch.calls = append(db.batch.calls, call{fn: fn, err: errCh}) + if len(db.batch.calls) >= db.MaxBatchSize { + // wake up batch, it's ready to run + go db.batch.trigger() + } + db.batchMu.Unlock() + + err := <-errCh + if err == trySolo { + err = db.Update(fn) + } + return err +} + +type call struct { + fn func(*Tx) error + err chan<- error +} + +type batch struct { + db *DB + timer *time.Timer + start sync.Once + calls []call +} + +// trigger runs the batch if it hasn't already been run. +func (b *batch) trigger() { + b.start.Do(b.run) +} + +// run performs the transactions in the batch and communicates results +// back to DB.Batch. +func (b *batch) run() { + b.db.batchMu.Lock() + b.timer.Stop() + // Make sure no new work is added to this batch, but don't break + // other batches. + if b.db.batch == b { + b.db.batch = nil + } + b.db.batchMu.Unlock() + +retry: + for len(b.calls) > 0 { + var failIdx = -1 + err := b.db.Update(func(tx *Tx) error { + for i, c := range b.calls { + if err := safelyCall(c.fn, tx); err != nil { + failIdx = i + return err + } + } + return nil + }) + + if failIdx >= 0 { + // take the failing transaction out of the batch. it's + // safe to shorten b.calls here because db.batch no longer + // points to us, and we hold the mutex anyway. + c := b.calls[failIdx] + b.calls[failIdx], b.calls = b.calls[len(b.calls)-1], b.calls[:len(b.calls)-1] + // tell the submitter re-run it solo, continue with the rest of the batch + c.err <- trySolo + continue retry + } + + // pass success, or bolt internal errors, to all callers + for _, c := range b.calls { + c.err <- err + } + break retry + } +} + +// trySolo is a special sentinel error value used for signaling that a +// transaction function should be re-run. It should never be seen by +// callers. +var trySolo = errors.New("batch function returned an error and should be re-run solo") + +type panicked struct { + reason interface{} +} + +func (p panicked) Error() string { + if err, ok := p.reason.(error); ok { + return err.Error() + } + return fmt.Sprintf("panic: %v", p.reason) +} + +func safelyCall(fn func(*Tx) error, tx *Tx) (err error) { + defer func() { + if p := recover(); p != nil { + err = panicked{p} + } + }() + return fn(tx) +} + +// Sync executes fdatasync() against the database file handle. +// +// This is not necessary under normal operation, however, if you use NoSync +// then it allows you to force the database file to sync against the disk. +func (db *DB) Sync() error { return fdatasync(db) } + +// Stats retrieves ongoing performance stats for the database. +// This is only updated when a transaction closes. +func (db *DB) Stats() Stats { + db.statlock.RLock() + defer db.statlock.RUnlock() + return db.stats +} + +// This is for internal access to the raw data bytes from the C cursor, use +// carefully, or not at all. +func (db *DB) Info() *Info { + return &Info{uintptr(unsafe.Pointer(&db.data[0])), db.pageSize} +} + +// page retrieves a page reference from the mmap based on the current page size. +func (db *DB) page(id pgid) *page { + pos := id * pgid(db.pageSize) + return (*page)(unsafe.Pointer(&db.data[pos])) +} + +// pageInBuffer retrieves a page reference from a given byte array based on the current page size. +func (db *DB) pageInBuffer(b []byte, id pgid) *page { + return (*page)(unsafe.Pointer(&b[id*pgid(db.pageSize)])) +} + +// meta retrieves the current meta page reference. +func (db *DB) meta() *meta { + // We have to return the meta with the highest txid which doesn't fail + // validation. Otherwise, we can cause errors when in fact the database is + // in a consistent state. metaA is the one with the higher txid. + metaA := db.meta0 + metaB := db.meta1 + if db.meta1.txid > db.meta0.txid { + metaA = db.meta1 + metaB = db.meta0 + } + + // Use higher meta page if valid. Otherwise fallback to previous, if valid. + if err := metaA.validate(); err == nil { + return metaA + } else if err := metaB.validate(); err == nil { + return metaB + } + + // This should never be reached, because both meta1 and meta0 were validated + // on mmap() and we do fsync() on every write. + panic("bolt.DB.meta(): invalid meta pages") +} + +// allocate returns a contiguous block of memory starting at a given page. +func (db *DB) allocate(txid txid, count int) (*page, error) { + // Allocate a temporary buffer for the page. + var buf []byte + if count == 1 { + buf = db.pagePool.Get().([]byte) + } else { + buf = make([]byte, count*db.pageSize) + } + p := (*page)(unsafe.Pointer(&buf[0])) + p.overflow = uint32(count - 1) + + // Use pages from the freelist if they are available. + if p.id = db.freelist.allocate(txid, count); p.id != 0 { + return p, nil + } + + // Resize mmap() if we're at the end. + p.id = db.rwtx.meta.pgid + var minsz = int((p.id+pgid(count))+1) * db.pageSize + if minsz >= db.datasz { + if err := db.mmap(minsz); err != nil { + return nil, fmt.Errorf("mmap allocate error: %s", err) + } + } + + // Move the page id high water mark. + db.rwtx.meta.pgid += pgid(count) + + return p, nil +} + +// grow grows the size of the database to the given sz. +func (db *DB) grow(sz int) error { + // Ignore if the new size is less than available file size. + if sz <= db.filesz { + return nil + } + + // If the data is smaller than the alloc size then only allocate what's needed. + // Once it goes over the allocation size then allocate in chunks. + if db.datasz < db.AllocSize { + sz = db.datasz + } else { + sz += db.AllocSize + } + + // Truncate and fsync to ensure file size metadata is flushed. + // https://github.com/boltdb/bolt/issues/284 + if !db.NoGrowSync && !db.readOnly { + if runtime.GOOS != "windows" { + if err := db.file.Truncate(int64(sz)); err != nil { + return fmt.Errorf("file resize error: %s", err) + } + } + if err := db.file.Sync(); err != nil { + return fmt.Errorf("file sync error: %s", err) + } + } + + db.filesz = sz + return nil +} + +func (db *DB) IsReadOnly() bool { + return db.readOnly +} + +func (db *DB) freepages() []pgid { + tx, err := db.beginTx() + defer func() { + err = tx.Rollback() + if err != nil { + panic("freepages: failed to rollback tx") + } + }() + if err != nil { + panic("freepages: failed to open read only tx") + } + + reachable := make(map[pgid]*page) + nofreed := make(map[pgid]bool) + ech := make(chan error) + go func() { + for e := range ech { + panic(fmt.Sprintf("freepages: failed to get all reachable pages (%v)", e)) + } + }() + tx.checkBucket(&tx.root, reachable, nofreed, ech) + close(ech) + + var fids []pgid + for i := pgid(2); i < db.meta().pgid; i++ { + if _, ok := reachable[i]; !ok { + fids = append(fids, i) + } + } + return fids +} + +// Options represents the options that can be set when opening a database. +type Options struct { + // Timeout is the amount of time to wait to obtain a file lock. + // When set to zero it will wait indefinitely. This option is only + // available on Darwin and Linux. + Timeout time.Duration + + // Sets the DB.NoGrowSync flag before memory mapping the file. + NoGrowSync bool + + // Do not sync freelist to disk. This improves the database write performance + // under normal operation, but requires a full database re-sync during recovery. + NoFreelistSync bool + + // FreelistType sets the backend freelist type. There are two options. Array which is simple but endures + // dramatic performance degradation if database is large and framentation in freelist is common. + // The alternative one is using hashmap, it is faster in almost all circumstances + // but it doesn't guarantee that it offers the smallest page id available. In normal case it is safe. + // The default type is array + FreelistType FreelistType + + // Open database in read-only mode. Uses flock(..., LOCK_SH |LOCK_NB) to + // grab a shared lock (UNIX). + ReadOnly bool + + // Sets the DB.MmapFlags flag before memory mapping the file. + MmapFlags int + + // InitialMmapSize is the initial mmap size of the database + // in bytes. Read transactions won't block write transaction + // if the InitialMmapSize is large enough to hold database mmap + // size. (See DB.Begin for more information) + // + // If <=0, the initial map size is 0. + // If initialMmapSize is smaller than the previous database size, + // it takes no effect. + InitialMmapSize int + + // PageSize overrides the default OS page size. + PageSize int + + // NoSync sets the initial value of DB.NoSync. Normally this can just be + // set directly on the DB itself when returned from Open(), but this option + // is useful in APIs which expose Options but not the underlying DB. + NoSync bool + + // OpenFile is used to open files. It defaults to os.OpenFile. This option + // is useful for writing hermetic tests. + OpenFile func(string, int, os.FileMode) (*os.File, error) +} + +// DefaultOptions represent the options used if nil options are passed into Open(). +// No timeout is used which will cause Bolt to wait indefinitely for a lock. +var DefaultOptions = &Options{ + Timeout: 0, + NoGrowSync: false, + FreelistType: FreelistArrayType, +} + +// Stats represents statistics about the database. +type Stats struct { + // Freelist stats + FreePageN int // total number of free pages on the freelist + PendingPageN int // total number of pending pages on the freelist + FreeAlloc int // total bytes allocated in free pages + FreelistInuse int // total bytes used by the freelist + + // Transaction stats + TxN int // total number of started read transactions + OpenTxN int // number of currently open read transactions + + TxStats TxStats // global, ongoing stats. +} + +// Sub calculates and returns the difference between two sets of database stats. +// This is useful when obtaining stats at two different points and time and +// you need the performance counters that occurred within that time span. +func (s *Stats) Sub(other *Stats) Stats { + if other == nil { + return *s + } + var diff Stats + diff.FreePageN = s.FreePageN + diff.PendingPageN = s.PendingPageN + diff.FreeAlloc = s.FreeAlloc + diff.FreelistInuse = s.FreelistInuse + diff.TxN = s.TxN - other.TxN + diff.TxStats = s.TxStats.Sub(&other.TxStats) + return diff +} + +type Info struct { + Data uintptr + PageSize int +} + +type meta struct { + magic uint32 + version uint32 + pageSize uint32 + flags uint32 + root bucket + freelist pgid + pgid pgid + txid txid + checksum uint64 +} + +// validate checks the marker bytes and version of the meta page to ensure it matches this binary. +func (m *meta) validate() error { + if m.magic != magic { + return ErrInvalid + } else if m.version != version { + return ErrVersionMismatch + } else if m.checksum != 0 && m.checksum != m.sum64() { + return ErrChecksum + } + return nil +} + +// copy copies one meta object to another. +func (m *meta) copy(dest *meta) { + *dest = *m +} + +// write writes the meta onto a page. +func (m *meta) write(p *page) { + if m.root.root >= m.pgid { + panic(fmt.Sprintf("root bucket pgid (%d) above high water mark (%d)", m.root.root, m.pgid)) + } else if m.freelist >= m.pgid && m.freelist != pgidNoFreelist { + // TODO: reject pgidNoFreeList if !NoFreelistSync + panic(fmt.Sprintf("freelist pgid (%d) above high water mark (%d)", m.freelist, m.pgid)) + } + + // Page id is either going to be 0 or 1 which we can determine by the transaction ID. + p.id = pgid(m.txid % 2) + p.flags |= metaPageFlag + + // Calculate the checksum. + m.checksum = m.sum64() + + m.copy(p.meta()) +} + +// generates the checksum for the meta. +func (m *meta) sum64() uint64 { + var h = fnv.New64a() + _, _ = h.Write((*[unsafe.Offsetof(meta{}.checksum)]byte)(unsafe.Pointer(m))[:]) + return h.Sum64() +} + +// _assert will panic with a given formatted message if the given condition is false. +func _assert(condition bool, msg string, v ...interface{}) { + if !condition { + panic(fmt.Sprintf("assertion failed: "+msg, v...)) + } +} diff --git a/vendor/etcd.io/bbolt/db_test.go b/vendor/etcd.io/bbolt/db_test.go new file mode 100644 index 0000000..9b03f2f --- /dev/null +++ b/vendor/etcd.io/bbolt/db_test.go @@ -0,0 +1,1783 @@ +package bbolt_test + +import ( + "bytes" + "encoding/binary" + "errors" + "flag" + "fmt" + "hash/fnv" + "io/ioutil" + "log" + "math/rand" + "os" + "path/filepath" + "regexp" + "sync" + "testing" + "time" + "unsafe" + + bolt "go.etcd.io/bbolt" +) + +var statsFlag = flag.Bool("stats", false, "show performance stats") + +// pageSize is the size of one page in the data file. +const pageSize = 4096 + +// pageHeaderSize is the size of a page header. +const pageHeaderSize = 16 + +// meta represents a simplified version of a database meta page for testing. +type meta struct { + magic uint32 + version uint32 + _ uint32 + _ uint32 + _ [16]byte + _ uint64 + pgid uint64 + _ uint64 + checksum uint64 +} + +// Ensure that a database can be opened without error. +func TestOpen(t *testing.T) { + path := tempfile() + defer os.RemoveAll(path) + + db, err := bolt.Open(path, 0666, nil) + if err != nil { + t.Fatal(err) + } else if db == nil { + t.Fatal("expected db") + } + + if s := db.Path(); s != path { + t.Fatalf("unexpected path: %s", s) + } + + if err := db.Close(); err != nil { + t.Fatal(err) + } +} + +// Regression validation for https://github.com/etcd-io/bbolt/pull/122. +// Tests multiple goroutines simultaneously opening a database. +func TestOpen_MultipleGoroutines(t *testing.T) { + const ( + instances = 30 + iterations = 30 + ) + path := tempfile() + defer os.RemoveAll(path) + var wg sync.WaitGroup + errCh := make(chan error, iterations*instances) + for iteration := 0; iteration < iterations; iteration++ { + for instance := 0; instance < instances; instance++ { + wg.Add(1) + go func() { + defer wg.Done() + db, err := bolt.Open(path, 0600, nil) + if err != nil { + errCh <- err + return + } + if err := db.Close(); err != nil { + errCh <- err + return + } + }() + } + wg.Wait() + } + close(errCh) + for err := range errCh { + if err != nil { + t.Fatalf("error from inside goroutine: %v", err) + } + } +} + +// Ensure that opening a database with a blank path returns an error. +func TestOpen_ErrPathRequired(t *testing.T) { + _, err := bolt.Open("", 0666, nil) + if err == nil { + t.Fatalf("expected error") + } +} + +// Ensure that opening a database with a bad path returns an error. +func TestOpen_ErrNotExists(t *testing.T) { + _, err := bolt.Open(filepath.Join(tempfile(), "bad-path"), 0666, nil) + if err == nil { + t.Fatal("expected error") + } +} + +// Ensure that opening a file that is not a Bolt database returns ErrInvalid. +func TestOpen_ErrInvalid(t *testing.T) { + path := tempfile() + defer os.RemoveAll(path) + + f, err := os.Create(path) + if err != nil { + t.Fatal(err) + } + if _, err := fmt.Fprintln(f, "this is not a bolt database"); err != nil { + t.Fatal(err) + } + if err := f.Close(); err != nil { + t.Fatal(err) + } + + if _, err := bolt.Open(path, 0666, nil); err != bolt.ErrInvalid { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that opening a file with two invalid versions returns ErrVersionMismatch. +func TestOpen_ErrVersionMismatch(t *testing.T) { + if pageSize != os.Getpagesize() { + t.Skip("page size mismatch") + } + + // Create empty database. + db := MustOpenDB() + path := db.Path() + defer db.MustClose() + + // Close database. + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + + // Read data file. + buf, err := ioutil.ReadFile(path) + if err != nil { + t.Fatal(err) + } + + // Rewrite meta pages. + meta0 := (*meta)(unsafe.Pointer(&buf[pageHeaderSize])) + meta0.version++ + meta1 := (*meta)(unsafe.Pointer(&buf[pageSize+pageHeaderSize])) + meta1.version++ + if err := ioutil.WriteFile(path, buf, 0666); err != nil { + t.Fatal(err) + } + + // Reopen data file. + if _, err := bolt.Open(path, 0666, nil); err != bolt.ErrVersionMismatch { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that opening a file with two invalid checksums returns ErrChecksum. +func TestOpen_ErrChecksum(t *testing.T) { + if pageSize != os.Getpagesize() { + t.Skip("page size mismatch") + } + + // Create empty database. + db := MustOpenDB() + path := db.Path() + defer db.MustClose() + + // Close database. + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + + // Read data file. + buf, err := ioutil.ReadFile(path) + if err != nil { + t.Fatal(err) + } + + // Rewrite meta pages. + meta0 := (*meta)(unsafe.Pointer(&buf[pageHeaderSize])) + meta0.pgid++ + meta1 := (*meta)(unsafe.Pointer(&buf[pageSize+pageHeaderSize])) + meta1.pgid++ + if err := ioutil.WriteFile(path, buf, 0666); err != nil { + t.Fatal(err) + } + + // Reopen data file. + if _, err := bolt.Open(path, 0666, nil); err != bolt.ErrChecksum { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that opening a database does not increase its size. +// https://github.com/boltdb/bolt/issues/291 +func TestOpen_Size(t *testing.T) { + // Open a data file. + db := MustOpenDB() + path := db.Path() + defer db.MustClose() + + pagesize := db.Info().PageSize + + // Insert until we get above the minimum 4MB size. + if err := db.Update(func(tx *bolt.Tx) error { + b, _ := tx.CreateBucketIfNotExists([]byte("data")) + for i := 0; i < 10000; i++ { + if err := b.Put([]byte(fmt.Sprintf("%04d", i)), make([]byte, 1000)); err != nil { + t.Fatal(err) + } + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Close database and grab the size. + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + sz := fileSize(path) + if sz == 0 { + t.Fatalf("unexpected new file size: %d", sz) + } + + // Reopen database, update, and check size again. + db0, err := bolt.Open(path, 0666, nil) + if err != nil { + t.Fatal(err) + } + if err := db0.Update(func(tx *bolt.Tx) error { + if err := tx.Bucket([]byte("data")).Put([]byte{0}, []byte{0}); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + if err := db0.Close(); err != nil { + t.Fatal(err) + } + newSz := fileSize(path) + if newSz == 0 { + t.Fatalf("unexpected new file size: %d", newSz) + } + + // Compare the original size with the new size. + // db size might increase by a few page sizes due to the new small update. + if sz < newSz-5*int64(pagesize) { + t.Fatalf("unexpected file growth: %d => %d", sz, newSz) + } +} + +// Ensure that opening a database beyond the max step size does not increase its size. +// https://github.com/boltdb/bolt/issues/303 +func TestOpen_Size_Large(t *testing.T) { + if testing.Short() { + t.Skip("short mode") + } + + // Open a data file. + db := MustOpenDB() + path := db.Path() + defer db.MustClose() + + pagesize := db.Info().PageSize + + // Insert until we get above the minimum 4MB size. + var index uint64 + for i := 0; i < 10000; i++ { + if err := db.Update(func(tx *bolt.Tx) error { + b, _ := tx.CreateBucketIfNotExists([]byte("data")) + for j := 0; j < 1000; j++ { + if err := b.Put(u64tob(index), make([]byte, 50)); err != nil { + t.Fatal(err) + } + index++ + } + return nil + }); err != nil { + t.Fatal(err) + } + } + + // Close database and grab the size. + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + sz := fileSize(path) + if sz == 0 { + t.Fatalf("unexpected new file size: %d", sz) + } else if sz < (1 << 30) { + t.Fatalf("expected larger initial size: %d", sz) + } + + // Reopen database, update, and check size again. + db0, err := bolt.Open(path, 0666, nil) + if err != nil { + t.Fatal(err) + } + if err := db0.Update(func(tx *bolt.Tx) error { + return tx.Bucket([]byte("data")).Put([]byte{0}, []byte{0}) + }); err != nil { + t.Fatal(err) + } + if err := db0.Close(); err != nil { + t.Fatal(err) + } + + newSz := fileSize(path) + if newSz == 0 { + t.Fatalf("unexpected new file size: %d", newSz) + } + + // Compare the original size with the new size. + // db size might increase by a few page sizes due to the new small update. + if sz < newSz-5*int64(pagesize) { + t.Fatalf("unexpected file growth: %d => %d", sz, newSz) + } +} + +// Ensure that a re-opened database is consistent. +func TestOpen_Check(t *testing.T) { + path := tempfile() + defer os.RemoveAll(path) + + db, err := bolt.Open(path, 0666, nil) + if err != nil { + t.Fatal(err) + } + if err = db.View(func(tx *bolt.Tx) error { return <-tx.Check() }); err != nil { + t.Fatal(err) + } + if err = db.Close(); err != nil { + t.Fatal(err) + } + + db, err = bolt.Open(path, 0666, nil) + if err != nil { + t.Fatal(err) + } + if err := db.View(func(tx *bolt.Tx) error { return <-tx.Check() }); err != nil { + t.Fatal(err) + } + if err := db.Close(); err != nil { + t.Fatal(err) + } +} + +// Ensure that write errors to the meta file handler during initialization are returned. +func TestOpen_MetaInitWriteError(t *testing.T) { + t.Skip("pending") +} + +// Ensure that a database that is too small returns an error. +func TestOpen_FileTooSmall(t *testing.T) { + path := tempfile() + defer os.RemoveAll(path) + + db, err := bolt.Open(path, 0666, nil) + if err != nil { + t.Fatal(err) + } + pageSize := int64(db.Info().PageSize) + if err = db.Close(); err != nil { + t.Fatal(err) + } + + // corrupt the database + if err = os.Truncate(path, pageSize); err != nil { + t.Fatal(err) + } + + db, err = bolt.Open(path, 0666, nil) + if err == nil || err.Error() != "file size too small" { + t.Fatalf("unexpected error: %s", err) + } +} + +// TestDB_Open_InitialMmapSize tests if having InitialMmapSize large enough +// to hold data from concurrent write transaction resolves the issue that +// read transaction blocks the write transaction and causes deadlock. +// This is a very hacky test since the mmap size is not exposed. +func TestDB_Open_InitialMmapSize(t *testing.T) { + path := tempfile() + defer os.Remove(path) + + initMmapSize := 1 << 30 // 1GB + testWriteSize := 1 << 27 // 134MB + + db, err := bolt.Open(path, 0666, &bolt.Options{InitialMmapSize: initMmapSize}) + if err != nil { + t.Fatal(err) + } + + // create a long-running read transaction + // that never gets closed while writing + rtx, err := db.Begin(false) + if err != nil { + t.Fatal(err) + } + + // create a write transaction + wtx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + + b, err := wtx.CreateBucket([]byte("test")) + if err != nil { + t.Fatal(err) + } + + // and commit a large write + err = b.Put([]byte("foo"), make([]byte, testWriteSize)) + if err != nil { + t.Fatal(err) + } + + done := make(chan error, 1) + + go func() { + err := wtx.Commit() + done <- err + }() + + select { + case <-time.After(5 * time.Second): + t.Errorf("unexpected that the reader blocks writer") + case err := <-done: + if err != nil { + t.Fatal(err) + } + } + + if err := rtx.Rollback(); err != nil { + t.Fatal(err) + } +} + +// TestDB_Open_ReadOnly checks a database in read only mode can read but not write. +func TestDB_Open_ReadOnly(t *testing.T) { + // Create a writable db, write k-v and close it. + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + + f := db.f + o := &bolt.Options{ReadOnly: true} + readOnlyDB, err := bolt.Open(f, 0666, o) + if err != nil { + panic(err) + } + + if !readOnlyDB.IsReadOnly() { + t.Fatal("expect db in read only mode") + } + + // Read from a read-only transaction. + if err := readOnlyDB.View(func(tx *bolt.Tx) error { + value := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + if !bytes.Equal(value, []byte("bar")) { + t.Fatal("expect value 'bar', got", value) + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Can't launch read-write transaction. + if _, err := readOnlyDB.Begin(true); err != bolt.ErrDatabaseReadOnly { + t.Fatalf("unexpected error: %s", err) + } + + if err := readOnlyDB.Close(); err != nil { + t.Fatal(err) + } +} + +// TestOpen_BigPage checks the database uses bigger pages when +// changing PageSize. +func TestOpen_BigPage(t *testing.T) { + pageSize := os.Getpagesize() + + db1 := MustOpenWithOption(&bolt.Options{PageSize: pageSize * 2}) + defer db1.MustClose() + + db2 := MustOpenWithOption(&bolt.Options{PageSize: pageSize * 4}) + defer db2.MustClose() + + if db1sz, db2sz := fileSize(db1.f), fileSize(db2.f); db1sz >= db2sz { + t.Errorf("expected %d < %d", db1sz, db2sz) + } +} + +// TestOpen_RecoverFreeList tests opening the DB with free-list +// write-out after no free list sync will recover the free list +// and write it out. +func TestOpen_RecoverFreeList(t *testing.T) { + db := MustOpenWithOption(&bolt.Options{NoFreelistSync: true}) + defer db.MustClose() + + // Write some pages. + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + wbuf := make([]byte, 8192) + for i := 0; i < 100; i++ { + s := fmt.Sprintf("%d", i) + b, err := tx.CreateBucket([]byte(s)) + if err != nil { + t.Fatal(err) + } + if err = b.Put([]byte(s), wbuf); err != nil { + t.Fatal(err) + } + } + if err = tx.Commit(); err != nil { + t.Fatal(err) + } + + // Generate free pages. + if tx, err = db.Begin(true); err != nil { + t.Fatal(err) + } + for i := 0; i < 50; i++ { + s := fmt.Sprintf("%d", i) + b := tx.Bucket([]byte(s)) + if b == nil { + t.Fatal(err) + } + if err := b.Delete([]byte(s)); err != nil { + t.Fatal(err) + } + } + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + + // Record freelist count from opening with NoFreelistSync. + db.MustReopen() + freepages := db.Stats().FreePageN + if freepages == 0 { + t.Fatalf("no free pages on NoFreelistSync reopen") + } + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + + // Check free page count is reconstructed when opened with freelist sync. + db.o = &bolt.Options{} + db.MustReopen() + // One less free page for syncing the free list on open. + freepages-- + if fp := db.Stats().FreePageN; fp < freepages { + t.Fatalf("closed with %d free pages, opened with %d", freepages, fp) + } +} + +// Ensure that a database cannot open a transaction when it's not open. +func TestDB_Begin_ErrDatabaseNotOpen(t *testing.T) { + var db bolt.DB + if _, err := db.Begin(false); err != bolt.ErrDatabaseNotOpen { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that a read-write transaction can be retrieved. +func TestDB_BeginRW(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } else if tx == nil { + t.Fatal("expected tx") + } + + if tx.DB() != db.DB { + t.Fatal("unexpected tx database") + } else if !tx.Writable() { + t.Fatal("expected writable tx") + } + + if err := tx.Commit(); err != nil { + t.Fatal(err) + } +} + +// TestDB_Concurrent_WriteTo checks that issuing WriteTo operations concurrently +// with commits does not produce corrupted db files. +func TestDB_Concurrent_WriteTo(t *testing.T) { + o := &bolt.Options{NoFreelistSync: false} + db := MustOpenWithOption(o) + defer db.MustClose() + + var wg sync.WaitGroup + wtxs, rtxs := 5, 5 + wg.Add(wtxs * rtxs) + f := func(tx *bolt.Tx) { + defer wg.Done() + f, err := ioutil.TempFile("", "bolt-") + if err != nil { + panic(err) + } + time.Sleep(time.Duration(rand.Intn(20)+1) * time.Millisecond) + tx.WriteTo(f) + tx.Rollback() + f.Close() + snap := &DB{nil, f.Name(), o} + snap.MustReopen() + defer snap.MustClose() + snap.MustCheck() + } + + tx1, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + if _, err := tx1.CreateBucket([]byte("abc")); err != nil { + t.Fatal(err) + } + if err := tx1.Commit(); err != nil { + t.Fatal(err) + } + + for i := 0; i < wtxs; i++ { + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + if err := tx.Bucket([]byte("abc")).Put([]byte{0}, []byte{0}); err != nil { + t.Fatal(err) + } + for j := 0; j < rtxs; j++ { + rtx, rerr := db.Begin(false) + if rerr != nil { + t.Fatal(rerr) + } + go f(rtx) + } + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + } + wg.Wait() +} + +// Ensure that opening a transaction while the DB is closed returns an error. +func TestDB_BeginRW_Closed(t *testing.T) { + var db bolt.DB + if _, err := db.Begin(true); err != bolt.ErrDatabaseNotOpen { + t.Fatalf("unexpected error: %s", err) + } +} + +func TestDB_Close_PendingTx_RW(t *testing.T) { testDB_Close_PendingTx(t, true) } +func TestDB_Close_PendingTx_RO(t *testing.T) { testDB_Close_PendingTx(t, false) } + +// Ensure that a database cannot close while transactions are open. +func testDB_Close_PendingTx(t *testing.T, writable bool) { + db := MustOpenDB() + + // Start transaction. + tx, err := db.Begin(writable) + if err != nil { + t.Fatal(err) + } + + // Open update in separate goroutine. + done := make(chan error, 1) + go func() { + err := db.Close() + done <- err + }() + + // Ensure database hasn't closed. + time.Sleep(100 * time.Millisecond) + select { + case err := <-done: + if err != nil { + t.Errorf("error from inside goroutine: %v", err) + } + t.Fatal("database closed too early") + default: + } + + // Commit/close transaction. + if writable { + err = tx.Commit() + } else { + err = tx.Rollback() + } + if err != nil { + t.Fatal(err) + } + + // Ensure database closed now. + time.Sleep(100 * time.Millisecond) + select { + case err := <-done: + if err != nil { + t.Fatalf("error from inside goroutine: %v", err) + } + default: + t.Fatal("database did not close") + } +} + +// Ensure a database can provide a transactional block. +func TestDB_Update(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte("bat")); err != nil { + t.Fatal(err) + } + if err := b.Delete([]byte("foo")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + if v := b.Get([]byte("foo")); v != nil { + t.Fatalf("expected nil value, got: %v", v) + } + if v := b.Get([]byte("baz")); !bytes.Equal(v, []byte("bat")) { + t.Fatalf("unexpected value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a closed database returns an error while running a transaction block +func TestDB_Update_Closed(t *testing.T) { + var db bolt.DB + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != bolt.ErrDatabaseNotOpen { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure a panic occurs while trying to commit a managed transaction. +func TestDB_Update_ManualCommit(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var panicked bool + if err := db.Update(func(tx *bolt.Tx) error { + func() { + defer func() { + if r := recover(); r != nil { + panicked = true + } + }() + + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + }() + return nil + }); err != nil { + t.Fatal(err) + } else if !panicked { + t.Fatal("expected panic") + } +} + +// Ensure a panic occurs while trying to rollback a managed transaction. +func TestDB_Update_ManualRollback(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var panicked bool + if err := db.Update(func(tx *bolt.Tx) error { + func() { + defer func() { + if r := recover(); r != nil { + panicked = true + } + }() + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + }() + return nil + }); err != nil { + t.Fatal(err) + } else if !panicked { + t.Fatal("expected panic") + } +} + +// Ensure a panic occurs while trying to commit a managed transaction. +func TestDB_View_ManualCommit(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var panicked bool + if err := db.View(func(tx *bolt.Tx) error { + func() { + defer func() { + if r := recover(); r != nil { + panicked = true + } + }() + + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + }() + return nil + }); err != nil { + t.Fatal(err) + } else if !panicked { + t.Fatal("expected panic") + } +} + +// Ensure a panic occurs while trying to rollback a managed transaction. +func TestDB_View_ManualRollback(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var panicked bool + if err := db.View(func(tx *bolt.Tx) error { + func() { + defer func() { + if r := recover(); r != nil { + panicked = true + } + }() + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + }() + return nil + }); err != nil { + t.Fatal(err) + } else if !panicked { + t.Fatal("expected panic") + } +} + +// Ensure a write transaction that panics does not hold open locks. +func TestDB_Update_Panic(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + // Panic during update but recover. + func() { + defer func() { + if r := recover(); r != nil { + t.Log("recover: update", r) + } + }() + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + panic("omg") + }); err != nil { + t.Fatal(err) + } + }() + + // Verify we can update again. + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Verify that our change persisted. + if err := db.Update(func(tx *bolt.Tx) error { + if tx.Bucket([]byte("widgets")) == nil { + t.Fatal("expected bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure a database can return an error through a read-only transactional block. +func TestDB_View_Error(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.View(func(tx *bolt.Tx) error { + return errors.New("xxx") + }); err == nil || err.Error() != "xxx" { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure a read transaction that panics does not hold open locks. +func TestDB_View_Panic(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Panic during view transaction but recover. + func() { + defer func() { + if r := recover(); r != nil { + t.Log("recover: view", r) + } + }() + + if err := db.View(func(tx *bolt.Tx) error { + if tx.Bucket([]byte("widgets")) == nil { + t.Fatal("expected bucket") + } + panic("omg") + }); err != nil { + t.Fatal(err) + } + }() + + // Verify that we can still use read transactions. + if err := db.View(func(tx *bolt.Tx) error { + if tx.Bucket([]byte("widgets")) == nil { + t.Fatal("expected bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that DB stats can be returned. +func TestDB_Stats(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + t.Fatal(err) + } + + stats := db.Stats() + if stats.TxStats.PageCount != 2 { + t.Fatalf("unexpected TxStats.PageCount: %d", stats.TxStats.PageCount) + } else if stats.FreePageN != 0 { + t.Fatalf("unexpected FreePageN != 0: %d", stats.FreePageN) + } else if stats.PendingPageN != 2 { + t.Fatalf("unexpected PendingPageN != 2: %d", stats.PendingPageN) + } +} + +// Ensure that database pages are in expected order and type. +func TestDB_Consistency(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + t.Fatal(err) + } + + for i := 0; i < 10; i++ { + if err := db.Update(func(tx *bolt.Tx) error { + if err := tx.Bucket([]byte("widgets")).Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + } + + if err := db.Update(func(tx *bolt.Tx) error { + if p, _ := tx.Page(0); p == nil { + t.Fatal("expected page") + } else if p.Type != "meta" { + t.Fatalf("unexpected page type: %s", p.Type) + } + + if p, _ := tx.Page(1); p == nil { + t.Fatal("expected page") + } else if p.Type != "meta" { + t.Fatalf("unexpected page type: %s", p.Type) + } + + if p, _ := tx.Page(2); p == nil { + t.Fatal("expected page") + } else if p.Type != "free" { + t.Fatalf("unexpected page type: %s", p.Type) + } + + if p, _ := tx.Page(3); p == nil { + t.Fatal("expected page") + } else if p.Type != "free" { + t.Fatalf("unexpected page type: %s", p.Type) + } + + if p, _ := tx.Page(4); p == nil { + t.Fatal("expected page") + } else if p.Type != "leaf" { + t.Fatalf("unexpected page type: %s", p.Type) + } + + if p, _ := tx.Page(5); p == nil { + t.Fatal("expected page") + } else if p.Type != "freelist" { + t.Fatalf("unexpected page type: %s", p.Type) + } + + if p, _ := tx.Page(6); p != nil { + t.Fatal("unexpected page") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that DB stats can be subtracted from one another. +func TestDBStats_Sub(t *testing.T) { + var a, b bolt.Stats + a.TxStats.PageCount = 3 + a.FreePageN = 4 + b.TxStats.PageCount = 10 + b.FreePageN = 14 + diff := b.Sub(&a) + if diff.TxStats.PageCount != 7 { + t.Fatalf("unexpected TxStats.PageCount: %d", diff.TxStats.PageCount) + } + + // free page stats are copied from the receiver and not subtracted + if diff.FreePageN != 14 { + t.Fatalf("unexpected FreePageN: %d", diff.FreePageN) + } +} + +// Ensure two functions can perform updates in a single batch. +func TestDB_Batch(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Iterate over multiple updates in separate goroutines. + n := 2 + ch := make(chan error) + for i := 0; i < n; i++ { + go func(i int) { + ch <- db.Batch(func(tx *bolt.Tx) error { + return tx.Bucket([]byte("widgets")).Put(u64tob(uint64(i)), []byte{}) + }) + }(i) + } + + // Check all responses to make sure there's no error. + for i := 0; i < n; i++ { + if err := <-ch; err != nil { + t.Fatal(err) + } + } + + // Ensure data is correct. + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for i := 0; i < n; i++ { + if v := b.Get(u64tob(uint64(i))); v == nil { + t.Errorf("key not found: %d", i) + } + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +func TestDB_Batch_Panic(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var sentinel int + var bork = &sentinel + var problem interface{} + var err error + + // Execute a function inside a batch that panics. + func() { + defer func() { + if p := recover(); p != nil { + problem = p + } + }() + err = db.Batch(func(tx *bolt.Tx) error { + panic(bork) + }) + }() + + // Verify there is no error. + if g, e := err, error(nil); g != e { + t.Fatalf("wrong error: %v != %v", g, e) + } + // Verify the panic was captured. + if g, e := problem, bork; g != e { + t.Fatalf("wrong error: %v != %v", g, e) + } +} + +func TestDB_BatchFull(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + t.Fatal(err) + } + + const size = 3 + // buffered so we never leak goroutines + ch := make(chan error, size) + put := func(i int) { + ch <- db.Batch(func(tx *bolt.Tx) error { + return tx.Bucket([]byte("widgets")).Put(u64tob(uint64(i)), []byte{}) + }) + } + + db.MaxBatchSize = size + // high enough to never trigger here + db.MaxBatchDelay = 1 * time.Hour + + go put(1) + go put(2) + + // Give the batch a chance to exhibit bugs. + time.Sleep(10 * time.Millisecond) + + // not triggered yet + select { + case <-ch: + t.Fatalf("batch triggered too early") + default: + } + + go put(3) + + // Check all responses to make sure there's no error. + for i := 0; i < size; i++ { + if err := <-ch; err != nil { + t.Fatal(err) + } + } + + // Ensure data is correct. + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for i := 1; i <= size; i++ { + if v := b.Get(u64tob(uint64(i))); v == nil { + t.Errorf("key not found: %d", i) + } + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +func TestDB_BatchTime(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + t.Fatal(err) + } + + const size = 1 + // buffered so we never leak goroutines + ch := make(chan error, size) + put := func(i int) { + ch <- db.Batch(func(tx *bolt.Tx) error { + return tx.Bucket([]byte("widgets")).Put(u64tob(uint64(i)), []byte{}) + }) + } + + db.MaxBatchSize = 1000 + db.MaxBatchDelay = 0 + + go put(1) + + // Batch must trigger by time alone. + + // Check all responses to make sure there's no error. + for i := 0; i < size; i++ { + if err := <-ch; err != nil { + t.Fatal(err) + } + } + + // Ensure data is correct. + if err := db.View(func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("widgets")) + for i := 1; i <= size; i++ { + if v := b.Get(u64tob(uint64(i))); v == nil { + t.Errorf("key not found: %d", i) + } + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +func ExampleDB_Update() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Execute several commands within a read-write transaction. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + return err + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + return err + } + return nil + }); err != nil { + log.Fatal(err) + } + + // Read the value back from a separate read-only transaction. + if err := db.View(func(tx *bolt.Tx) error { + value := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + fmt.Printf("The value of 'foo' is: %s\n", value) + return nil + }); err != nil { + log.Fatal(err) + } + + // Close database to release the file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // The value of 'foo' is: bar +} + +func ExampleDB_View() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Insert data into a bucket. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("people")) + if err != nil { + return err + } + if err := b.Put([]byte("john"), []byte("doe")); err != nil { + return err + } + if err := b.Put([]byte("susy"), []byte("que")); err != nil { + return err + } + return nil + }); err != nil { + log.Fatal(err) + } + + // Access data from within a read-only transactional block. + if err := db.View(func(tx *bolt.Tx) error { + v := tx.Bucket([]byte("people")).Get([]byte("john")) + fmt.Printf("John's last name is %s.\n", v) + return nil + }); err != nil { + log.Fatal(err) + } + + // Close database to release the file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // John's last name is doe. +} + +func ExampleDB_Begin() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Create a bucket using a read-write transaction. + if err = db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + log.Fatal(err) + } + + // Create several keys in a transaction. + tx, err := db.Begin(true) + if err != nil { + log.Fatal(err) + } + b := tx.Bucket([]byte("widgets")) + if err = b.Put([]byte("john"), []byte("blue")); err != nil { + log.Fatal(err) + } + if err = b.Put([]byte("abby"), []byte("red")); err != nil { + log.Fatal(err) + } + if err = b.Put([]byte("zephyr"), []byte("purple")); err != nil { + log.Fatal(err) + } + if err = tx.Commit(); err != nil { + log.Fatal(err) + } + + // Iterate over the values in sorted key order. + tx, err = db.Begin(false) + if err != nil { + log.Fatal(err) + } + c := tx.Bucket([]byte("widgets")).Cursor() + for k, v := c.First(); k != nil; k, v = c.Next() { + fmt.Printf("%s likes %s\n", k, v) + } + + if err = tx.Rollback(); err != nil { + log.Fatal(err) + } + + if err = db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // abby likes red + // john likes blue + // zephyr likes purple +} + +func BenchmarkDBBatchAutomatic(b *testing.B) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("bench")) + return err + }); err != nil { + b.Fatal(err) + } + + b.ResetTimer() + for i := 0; i < b.N; i++ { + start := make(chan struct{}) + var wg sync.WaitGroup + + for round := 0; round < 1000; round++ { + wg.Add(1) + + go func(id uint32) { + defer wg.Done() + <-start + + h := fnv.New32a() + buf := make([]byte, 4) + binary.LittleEndian.PutUint32(buf, id) + _, _ = h.Write(buf[:]) + k := h.Sum(nil) + insert := func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("bench")) + return b.Put(k, []byte("filler")) + } + if err := db.Batch(insert); err != nil { + b.Error(err) + return + } + }(uint32(round)) + } + close(start) + wg.Wait() + } + + b.StopTimer() + validateBatchBench(b, db) +} + +func BenchmarkDBBatchSingle(b *testing.B) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("bench")) + return err + }); err != nil { + b.Fatal(err) + } + + b.ResetTimer() + for i := 0; i < b.N; i++ { + start := make(chan struct{}) + var wg sync.WaitGroup + + for round := 0; round < 1000; round++ { + wg.Add(1) + go func(id uint32) { + defer wg.Done() + <-start + + h := fnv.New32a() + buf := make([]byte, 4) + binary.LittleEndian.PutUint32(buf, id) + _, _ = h.Write(buf[:]) + k := h.Sum(nil) + insert := func(tx *bolt.Tx) error { + b := tx.Bucket([]byte("bench")) + return b.Put(k, []byte("filler")) + } + if err := db.Update(insert); err != nil { + b.Error(err) + return + } + }(uint32(round)) + } + close(start) + wg.Wait() + } + + b.StopTimer() + validateBatchBench(b, db) +} + +func BenchmarkDBBatchManual10x100(b *testing.B) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("bench")) + return err + }); err != nil { + b.Fatal(err) + } + + b.ResetTimer() + for i := 0; i < b.N; i++ { + start := make(chan struct{}) + var wg sync.WaitGroup + errCh := make(chan error, 10) + + for major := 0; major < 10; major++ { + wg.Add(1) + go func(id uint32) { + defer wg.Done() + <-start + + insert100 := func(tx *bolt.Tx) error { + h := fnv.New32a() + buf := make([]byte, 4) + for minor := uint32(0); minor < 100; minor++ { + binary.LittleEndian.PutUint32(buf, uint32(id*100+minor)) + h.Reset() + _, _ = h.Write(buf[:]) + k := h.Sum(nil) + b := tx.Bucket([]byte("bench")) + if err := b.Put(k, []byte("filler")); err != nil { + return err + } + } + return nil + } + err := db.Update(insert100) + errCh <- err + }(uint32(major)) + } + close(start) + wg.Wait() + close(errCh) + for err := range errCh { + if err != nil { + b.Fatal(err) + } + } + } + + b.StopTimer() + validateBatchBench(b, db) +} + +func validateBatchBench(b *testing.B, db *DB) { + var rollback = errors.New("sentinel error to cause rollback") + validate := func(tx *bolt.Tx) error { + bucket := tx.Bucket([]byte("bench")) + h := fnv.New32a() + buf := make([]byte, 4) + for id := uint32(0); id < 1000; id++ { + binary.LittleEndian.PutUint32(buf, id) + h.Reset() + _, _ = h.Write(buf[:]) + k := h.Sum(nil) + v := bucket.Get(k) + if v == nil { + b.Errorf("not found id=%d key=%x", id, k) + continue + } + if g, e := v, []byte("filler"); !bytes.Equal(g, e) { + b.Errorf("bad value for id=%d key=%x: %s != %q", id, k, g, e) + } + if err := bucket.Delete(k); err != nil { + return err + } + } + // should be empty now + c := bucket.Cursor() + for k, v := c.First(); k != nil; k, v = c.Next() { + b.Errorf("unexpected key: %x = %q", k, v) + } + return rollback + } + if err := db.Update(validate); err != nil && err != rollback { + b.Error(err) + } +} + +// DB is a test wrapper for bolt.DB. +type DB struct { + *bolt.DB + f string + o *bolt.Options +} + +// MustOpenDB returns a new, open DB at a temporary location. +func MustOpenDB() *DB { + return MustOpenWithOption(nil) +} + +// MustOpenDBWithOption returns a new, open DB at a temporary location with given options. +func MustOpenWithOption(o *bolt.Options) *DB { + f := tempfile() + if o == nil { + o = bolt.DefaultOptions + } + + freelistType := bolt.FreelistArrayType + if env := os.Getenv(bolt.TestFreelistType); env == string(bolt.FreelistMapType) { + freelistType = bolt.FreelistMapType + } + o.FreelistType = freelistType + + db, err := bolt.Open(f, 0666, o) + if err != nil { + panic(err) + } + return &DB{ + DB: db, + f: f, + o: o, + } +} + +// Close closes the database and deletes the underlying file. +func (db *DB) Close() error { + // Log statistics. + if *statsFlag { + db.PrintStats() + } + + // Check database consistency after every test. + db.MustCheck() + + // Close database and remove file. + defer os.Remove(db.Path()) + return db.DB.Close() +} + +// MustClose closes the database and deletes the underlying file. Panic on error. +func (db *DB) MustClose() { + if err := db.Close(); err != nil { + panic(err) + } +} + +// MustReopen reopen the database. Panic on error. +func (db *DB) MustReopen() { + indb, err := bolt.Open(db.f, 0666, db.o) + if err != nil { + panic(err) + } + db.DB = indb +} + +// PrintStats prints the database stats +func (db *DB) PrintStats() { + var stats = db.Stats() + fmt.Printf("[db] %-20s %-20s %-20s\n", + fmt.Sprintf("pg(%d/%d)", stats.TxStats.PageCount, stats.TxStats.PageAlloc), + fmt.Sprintf("cur(%d)", stats.TxStats.CursorCount), + fmt.Sprintf("node(%d/%d)", stats.TxStats.NodeCount, stats.TxStats.NodeDeref), + ) + fmt.Printf(" %-20s %-20s %-20s\n", + fmt.Sprintf("rebal(%d/%v)", stats.TxStats.Rebalance, truncDuration(stats.TxStats.RebalanceTime)), + fmt.Sprintf("spill(%d/%v)", stats.TxStats.Spill, truncDuration(stats.TxStats.SpillTime)), + fmt.Sprintf("w(%d/%v)", stats.TxStats.Write, truncDuration(stats.TxStats.WriteTime)), + ) +} + +// MustCheck runs a consistency check on the database and panics if any errors are found. +func (db *DB) MustCheck() { + if err := db.Update(func(tx *bolt.Tx) error { + // Collect all the errors. + var errors []error + for err := range tx.Check() { + errors = append(errors, err) + if len(errors) > 10 { + break + } + } + + // If errors occurred, copy the DB and print the errors. + if len(errors) > 0 { + var path = tempfile() + if err := tx.CopyFile(path, 0600); err != nil { + panic(err) + } + + // Print errors. + fmt.Print("\n\n") + fmt.Printf("consistency check failed (%d errors)\n", len(errors)) + for _, err := range errors { + fmt.Println(err) + } + fmt.Println("") + fmt.Println("db saved to:") + fmt.Println(path) + fmt.Print("\n\n") + os.Exit(-1) + } + + return nil + }); err != nil && err != bolt.ErrDatabaseNotOpen { + panic(err) + } +} + +// CopyTempFile copies a database to a temporary file. +func (db *DB) CopyTempFile() { + path := tempfile() + if err := db.View(func(tx *bolt.Tx) error { + return tx.CopyFile(path, 0600) + }); err != nil { + panic(err) + } + fmt.Println("db copied to: ", path) +} + +// tempfile returns a temporary file path. +func tempfile() string { + f, err := ioutil.TempFile("", "bolt-") + if err != nil { + panic(err) + } + if err := f.Close(); err != nil { + panic(err) + } + if err := os.Remove(f.Name()); err != nil { + panic(err) + } + return f.Name() +} + +func trunc(b []byte, length int) []byte { + if length < len(b) { + return b[:length] + } + return b +} + +func truncDuration(d time.Duration) string { + return regexp.MustCompile(`^(\d+)(\.\d+)`).ReplaceAllString(d.String(), "$1") +} + +func fileSize(path string) int64 { + fi, err := os.Stat(path) + if err != nil { + return 0 + } + return fi.Size() +} + +// u64tob converts a uint64 into an 8-byte slice. +func u64tob(v uint64) []byte { + b := make([]byte, 8) + binary.BigEndian.PutUint64(b, v) + return b +} diff --git a/vendor/etcd.io/bbolt/doc.go b/vendor/etcd.io/bbolt/doc.go new file mode 100644 index 0000000..95f25f0 --- /dev/null +++ b/vendor/etcd.io/bbolt/doc.go @@ -0,0 +1,44 @@ +/* +package bbolt implements a low-level key/value store in pure Go. It supports +fully serializable transactions, ACID semantics, and lock-free MVCC with +multiple readers and a single writer. Bolt can be used for projects that +want a simple data store without the need to add large dependencies such as +Postgres or MySQL. + +Bolt is a single-level, zero-copy, B+tree data store. This means that Bolt is +optimized for fast read access and does not require recovery in the event of a +system crash. Transactions which have not finished committing will simply be +rolled back in the event of a crash. + +The design of Bolt is based on Howard Chu's LMDB database project. + +Bolt currently works on Windows, Mac OS X, and Linux. + + +Basics + +There are only a few types in Bolt: DB, Bucket, Tx, and Cursor. The DB is +a collection of buckets and is represented by a single file on disk. A bucket is +a collection of unique keys that are associated with values. + +Transactions provide either read-only or read-write access to the database. +Read-only transactions can retrieve key/value pairs and can use Cursors to +iterate over the dataset sequentially. Read-write transactions can create and +delete buckets and can insert and remove keys. Only one read-write transaction +is allowed at a time. + + +Caveats + +The database uses a read-only, memory-mapped data file to ensure that +applications cannot corrupt the database, however, this means that keys and +values returned from Bolt cannot be changed. Writing to a read-only byte slice +will cause Go to panic. + +Keys and values retrieved from the database are only valid for the life of +the transaction. When used outside the transaction, these byte slices can +point to different data or can point to invalid memory which will cause a panic. + + +*/ +package bbolt diff --git a/vendor/etcd.io/bbolt/errors.go b/vendor/etcd.io/bbolt/errors.go new file mode 100644 index 0000000..48758ca --- /dev/null +++ b/vendor/etcd.io/bbolt/errors.go @@ -0,0 +1,71 @@ +package bbolt + +import "errors" + +// These errors can be returned when opening or calling methods on a DB. +var ( + // ErrDatabaseNotOpen is returned when a DB instance is accessed before it + // is opened or after it is closed. + ErrDatabaseNotOpen = errors.New("database not open") + + // ErrDatabaseOpen is returned when opening a database that is + // already open. + ErrDatabaseOpen = errors.New("database already open") + + // ErrInvalid is returned when both meta pages on a database are invalid. + // This typically occurs when a file is not a bolt database. + ErrInvalid = errors.New("invalid database") + + // ErrVersionMismatch is returned when the data file was created with a + // different version of Bolt. + ErrVersionMismatch = errors.New("version mismatch") + + // ErrChecksum is returned when either meta page checksum does not match. + ErrChecksum = errors.New("checksum error") + + // ErrTimeout is returned when a database cannot obtain an exclusive lock + // on the data file after the timeout passed to Open(). + ErrTimeout = errors.New("timeout") +) + +// These errors can occur when beginning or committing a Tx. +var ( + // ErrTxNotWritable is returned when performing a write operation on a + // read-only transaction. + ErrTxNotWritable = errors.New("tx not writable") + + // ErrTxClosed is returned when committing or rolling back a transaction + // that has already been committed or rolled back. + ErrTxClosed = errors.New("tx closed") + + // ErrDatabaseReadOnly is returned when a mutating transaction is started on a + // read-only database. + ErrDatabaseReadOnly = errors.New("database is in read-only mode") +) + +// These errors can occur when putting or deleting a value or a bucket. +var ( + // ErrBucketNotFound is returned when trying to access a bucket that has + // not been created yet. + ErrBucketNotFound = errors.New("bucket not found") + + // ErrBucketExists is returned when creating a bucket that already exists. + ErrBucketExists = errors.New("bucket already exists") + + // ErrBucketNameRequired is returned when creating a bucket with a blank name. + ErrBucketNameRequired = errors.New("bucket name required") + + // ErrKeyRequired is returned when inserting a zero-length key. + ErrKeyRequired = errors.New("key required") + + // ErrKeyTooLarge is returned when inserting a key that is larger than MaxKeySize. + ErrKeyTooLarge = errors.New("key too large") + + // ErrValueTooLarge is returned when inserting a value that is larger than MaxValueSize. + ErrValueTooLarge = errors.New("value too large") + + // ErrIncompatibleValue is returned when trying create or delete a bucket + // on an existing non-bucket key or when trying to create or delete a + // non-bucket key on an existing bucket key. + ErrIncompatibleValue = errors.New("incompatible value") +) diff --git a/vendor/etcd.io/bbolt/freelist.go b/vendor/etcd.io/bbolt/freelist.go new file mode 100644 index 0000000..697a469 --- /dev/null +++ b/vendor/etcd.io/bbolt/freelist.go @@ -0,0 +1,404 @@ +package bbolt + +import ( + "fmt" + "sort" + "unsafe" +) + +// txPending holds a list of pgids and corresponding allocation txns +// that are pending to be freed. +type txPending struct { + ids []pgid + alloctx []txid // txids allocating the ids + lastReleaseBegin txid // beginning txid of last matching releaseRange +} + +// pidSet holds the set of starting pgids which have the same span size +type pidSet map[pgid]struct{} + +// freelist represents a list of all pages that are available for allocation. +// It also tracks pages that have been freed but are still in use by open transactions. +type freelist struct { + freelistType FreelistType // freelist type + ids []pgid // all free and available free page ids. + allocs map[pgid]txid // mapping of txid that allocated a pgid. + pending map[txid]*txPending // mapping of soon-to-be free page ids by tx. + cache map[pgid]bool // fast lookup of all free and pending page ids. + freemaps map[uint64]pidSet // key is the size of continuous pages(span), value is a set which contains the starting pgids of same size + forwardMap map[pgid]uint64 // key is start pgid, value is its span size + backwardMap map[pgid]uint64 // key is end pgid, value is its span size + allocate func(txid txid, n int) pgid // the freelist allocate func + free_count func() int // the function which gives you free page number + mergeSpans func(ids pgids) // the mergeSpan func + getFreePageIDs func() []pgid // get free pgids func + readIDs func(pgids []pgid) // readIDs func reads list of pages and init the freelist +} + +// newFreelist returns an empty, initialized freelist. +func newFreelist(freelistType FreelistType) *freelist { + f := &freelist{ + freelistType: freelistType, + allocs: make(map[pgid]txid), + pending: make(map[txid]*txPending), + cache: make(map[pgid]bool), + freemaps: make(map[uint64]pidSet), + forwardMap: make(map[pgid]uint64), + backwardMap: make(map[pgid]uint64), + } + + if freelistType == FreelistMapType { + f.allocate = f.hashmapAllocate + f.free_count = f.hashmapFreeCount + f.mergeSpans = f.hashmapMergeSpans + f.getFreePageIDs = f.hashmapGetFreePageIDs + f.readIDs = f.hashmapReadIDs + } else { + f.allocate = f.arrayAllocate + f.free_count = f.arrayFreeCount + f.mergeSpans = f.arrayMergeSpans + f.getFreePageIDs = f.arrayGetFreePageIDs + f.readIDs = f.arrayReadIDs + } + + return f +} + +// size returns the size of the page after serialization. +func (f *freelist) size() int { + n := f.count() + if n >= 0xFFFF { + // The first element will be used to store the count. See freelist.write. + n++ + } + return int(pageHeaderSize) + (int(unsafe.Sizeof(pgid(0))) * n) +} + +// count returns count of pages on the freelist +func (f *freelist) count() int { + return f.free_count() + f.pending_count() +} + +// arrayFreeCount returns count of free pages(array version) +func (f *freelist) arrayFreeCount() int { + return len(f.ids) +} + +// pending_count returns count of pending pages +func (f *freelist) pending_count() int { + var count int + for _, txp := range f.pending { + count += len(txp.ids) + } + return count +} + +// copyall copies a list of all free ids and all pending ids in one sorted list. +// f.count returns the minimum length required for dst. +func (f *freelist) copyall(dst []pgid) { + m := make(pgids, 0, f.pending_count()) + for _, txp := range f.pending { + m = append(m, txp.ids...) + } + sort.Sort(m) + mergepgids(dst, f.getFreePageIDs(), m) +} + +// arrayAllocate returns the starting page id of a contiguous list of pages of a given size. +// If a contiguous block cannot be found then 0 is returned. +func (f *freelist) arrayAllocate(txid txid, n int) pgid { + if len(f.ids) == 0 { + return 0 + } + + var initial, previd pgid + for i, id := range f.ids { + if id <= 1 { + panic(fmt.Sprintf("invalid page allocation: %d", id)) + } + + // Reset initial page if this is not contiguous. + if previd == 0 || id-previd != 1 { + initial = id + } + + // If we found a contiguous block then remove it and return it. + if (id-initial)+1 == pgid(n) { + // If we're allocating off the beginning then take the fast path + // and just adjust the existing slice. This will use extra memory + // temporarily but the append() in free() will realloc the slice + // as is necessary. + if (i + 1) == n { + f.ids = f.ids[i+1:] + } else { + copy(f.ids[i-n+1:], f.ids[i+1:]) + f.ids = f.ids[:len(f.ids)-n] + } + + // Remove from the free cache. + for i := pgid(0); i < pgid(n); i++ { + delete(f.cache, initial+i) + } + f.allocs[initial] = txid + return initial + } + + previd = id + } + return 0 +} + +// free releases a page and its overflow for a given transaction id. +// If the page is already free then a panic will occur. +func (f *freelist) free(txid txid, p *page) { + if p.id <= 1 { + panic(fmt.Sprintf("cannot free page 0 or 1: %d", p.id)) + } + + // Free page and all its overflow pages. + txp := f.pending[txid] + if txp == nil { + txp = &txPending{} + f.pending[txid] = txp + } + allocTxid, ok := f.allocs[p.id] + if ok { + delete(f.allocs, p.id) + } else if (p.flags & freelistPageFlag) != 0 { + // Freelist is always allocated by prior tx. + allocTxid = txid - 1 + } + + for id := p.id; id <= p.id+pgid(p.overflow); id++ { + // Verify that page is not already free. + if f.cache[id] { + panic(fmt.Sprintf("page %d already freed", id)) + } + // Add to the freelist and cache. + txp.ids = append(txp.ids, id) + txp.alloctx = append(txp.alloctx, allocTxid) + f.cache[id] = true + } +} + +// release moves all page ids for a transaction id (or older) to the freelist. +func (f *freelist) release(txid txid) { + m := make(pgids, 0) + for tid, txp := range f.pending { + if tid <= txid { + // Move transaction's pending pages to the available freelist. + // Don't remove from the cache since the page is still free. + m = append(m, txp.ids...) + delete(f.pending, tid) + } + } + f.mergeSpans(m) +} + +// releaseRange moves pending pages allocated within an extent [begin,end] to the free list. +func (f *freelist) releaseRange(begin, end txid) { + if begin > end { + return + } + var m pgids + for tid, txp := range f.pending { + if tid < begin || tid > end { + continue + } + // Don't recompute freed pages if ranges haven't updated. + if txp.lastReleaseBegin == begin { + continue + } + for i := 0; i < len(txp.ids); i++ { + if atx := txp.alloctx[i]; atx < begin || atx > end { + continue + } + m = append(m, txp.ids[i]) + txp.ids[i] = txp.ids[len(txp.ids)-1] + txp.ids = txp.ids[:len(txp.ids)-1] + txp.alloctx[i] = txp.alloctx[len(txp.alloctx)-1] + txp.alloctx = txp.alloctx[:len(txp.alloctx)-1] + i-- + } + txp.lastReleaseBegin = begin + if len(txp.ids) == 0 { + delete(f.pending, tid) + } + } + f.mergeSpans(m) +} + +// rollback removes the pages from a given pending tx. +func (f *freelist) rollback(txid txid) { + // Remove page ids from cache. + txp := f.pending[txid] + if txp == nil { + return + } + var m pgids + for i, pgid := range txp.ids { + delete(f.cache, pgid) + tx := txp.alloctx[i] + if tx == 0 { + continue + } + if tx != txid { + // Pending free aborted; restore page back to alloc list. + f.allocs[pgid] = tx + } else { + // Freed page was allocated by this txn; OK to throw away. + m = append(m, pgid) + } + } + // Remove pages from pending list and mark as free if allocated by txid. + delete(f.pending, txid) + f.mergeSpans(m) +} + +// freed returns whether a given page is in the free list. +func (f *freelist) freed(pgid pgid) bool { + return f.cache[pgid] +} + +// read initializes the freelist from a freelist page. +func (f *freelist) read(p *page) { + if (p.flags & freelistPageFlag) == 0 { + panic(fmt.Sprintf("invalid freelist page: %d, page type is %s", p.id, p.typ())) + } + // If the page.count is at the max uint16 value (64k) then it's considered + // an overflow and the size of the freelist is stored as the first element. + var idx, count = 0, int(p.count) + if count == 0xFFFF { + idx = 1 + c := *(*pgid)(unsafeAdd(unsafe.Pointer(p), unsafe.Sizeof(*p))) + count = int(c) + if count < 0 { + panic(fmt.Sprintf("leading element count %d overflows int", c)) + } + } + + // Copy the list of page ids from the freelist. + if count == 0 { + f.ids = nil + } else { + var ids []pgid + data := unsafeIndex(unsafe.Pointer(p), unsafe.Sizeof(*p), unsafe.Sizeof(ids[0]), idx) + unsafeSlice(unsafe.Pointer(&ids), data, count) + + // copy the ids, so we don't modify on the freelist page directly + idsCopy := make([]pgid, count) + copy(idsCopy, ids) + // Make sure they're sorted. + sort.Sort(pgids(idsCopy)) + + f.readIDs(idsCopy) + } +} + +// arrayReadIDs initializes the freelist from a given list of ids. +func (f *freelist) arrayReadIDs(ids []pgid) { + f.ids = ids + f.reindex() +} + +func (f *freelist) arrayGetFreePageIDs() []pgid { + return f.ids +} + +// write writes the page ids onto a freelist page. All free and pending ids are +// saved to disk since in the event of a program crash, all pending ids will +// become free. +func (f *freelist) write(p *page) error { + // Combine the old free pgids and pgids waiting on an open transaction. + + // Update the header flag. + p.flags |= freelistPageFlag + + // The page.count can only hold up to 64k elements so if we overflow that + // number then we handle it by putting the size in the first element. + l := f.count() + if l == 0 { + p.count = uint16(l) + } else if l < 0xFFFF { + p.count = uint16(l) + var ids []pgid + data := unsafeAdd(unsafe.Pointer(p), unsafe.Sizeof(*p)) + unsafeSlice(unsafe.Pointer(&ids), data, l) + f.copyall(ids) + } else { + p.count = 0xFFFF + var ids []pgid + data := unsafeAdd(unsafe.Pointer(p), unsafe.Sizeof(*p)) + unsafeSlice(unsafe.Pointer(&ids), data, l+1) + ids[0] = pgid(l) + f.copyall(ids[1:]) + } + + return nil +} + +// reload reads the freelist from a page and filters out pending items. +func (f *freelist) reload(p *page) { + f.read(p) + + // Build a cache of only pending pages. + pcache := make(map[pgid]bool) + for _, txp := range f.pending { + for _, pendingID := range txp.ids { + pcache[pendingID] = true + } + } + + // Check each page in the freelist and build a new available freelist + // with any pages not in the pending lists. + var a []pgid + for _, id := range f.getFreePageIDs() { + if !pcache[id] { + a = append(a, id) + } + } + + f.readIDs(a) +} + +// noSyncReload reads the freelist from pgids and filters out pending items. +func (f *freelist) noSyncReload(pgids []pgid) { + // Build a cache of only pending pages. + pcache := make(map[pgid]bool) + for _, txp := range f.pending { + for _, pendingID := range txp.ids { + pcache[pendingID] = true + } + } + + // Check each page in the freelist and build a new available freelist + // with any pages not in the pending lists. + var a []pgid + for _, id := range pgids { + if !pcache[id] { + a = append(a, id) + } + } + + f.readIDs(a) +} + +// reindex rebuilds the free cache based on available and pending free lists. +func (f *freelist) reindex() { + ids := f.getFreePageIDs() + f.cache = make(map[pgid]bool, len(ids)) + for _, id := range ids { + f.cache[id] = true + } + for _, txp := range f.pending { + for _, pendingID := range txp.ids { + f.cache[pendingID] = true + } + } +} + +// arrayMergeSpans try to merge list of pages(represented by pgids) with existing spans but using array +func (f *freelist) arrayMergeSpans(ids pgids) { + sort.Sort(ids) + f.ids = pgids(f.ids).merge(ids) +} diff --git a/vendor/etcd.io/bbolt/freelist_hmap.go b/vendor/etcd.io/bbolt/freelist_hmap.go new file mode 100644 index 0000000..02ef2be --- /dev/null +++ b/vendor/etcd.io/bbolt/freelist_hmap.go @@ -0,0 +1,178 @@ +package bbolt + +import "sort" + +// hashmapFreeCount returns count of free pages(hashmap version) +func (f *freelist) hashmapFreeCount() int { + // use the forwardmap to get the total count + count := 0 + for _, size := range f.forwardMap { + count += int(size) + } + return count +} + +// hashmapAllocate serves the same purpose as arrayAllocate, but use hashmap as backend +func (f *freelist) hashmapAllocate(txid txid, n int) pgid { + if n == 0 { + return 0 + } + + // if we have a exact size match just return short path + if bm, ok := f.freemaps[uint64(n)]; ok { + for pid := range bm { + // remove the span + f.delSpan(pid, uint64(n)) + + f.allocs[pid] = txid + + for i := pgid(0); i < pgid(n); i++ { + delete(f.cache, pid+i) + } + return pid + } + } + + // lookup the map to find larger span + for size, bm := range f.freemaps { + if size < uint64(n) { + continue + } + + for pid := range bm { + // remove the initial + f.delSpan(pid, uint64(size)) + + f.allocs[pid] = txid + + remain := size - uint64(n) + + // add remain span + f.addSpan(pid+pgid(n), remain) + + for i := pgid(0); i < pgid(n); i++ { + delete(f.cache, pid+pgid(i)) + } + return pid + } + } + + return 0 +} + +// hashmapReadIDs reads pgids as input an initial the freelist(hashmap version) +func (f *freelist) hashmapReadIDs(pgids []pgid) { + f.init(pgids) + + // Rebuild the page cache. + f.reindex() +} + +// hashmapGetFreePageIDs returns the sorted free page ids +func (f *freelist) hashmapGetFreePageIDs() []pgid { + count := f.free_count() + if count == 0 { + return nil + } + + m := make([]pgid, 0, count) + for start, size := range f.forwardMap { + for i := 0; i < int(size); i++ { + m = append(m, start+pgid(i)) + } + } + sort.Sort(pgids(m)) + + return m +} + +// hashmapMergeSpans try to merge list of pages(represented by pgids) with existing spans +func (f *freelist) hashmapMergeSpans(ids pgids) { + for _, id := range ids { + // try to see if we can merge and update + f.mergeWithExistingSpan(id) + } +} + +// mergeWithExistingSpan merges pid to the existing free spans, try to merge it backward and forward +func (f *freelist) mergeWithExistingSpan(pid pgid) { + prev := pid - 1 + next := pid + 1 + + preSize, mergeWithPrev := f.backwardMap[prev] + nextSize, mergeWithNext := f.forwardMap[next] + newStart := pid + newSize := uint64(1) + + if mergeWithPrev { + //merge with previous span + start := prev + 1 - pgid(preSize) + f.delSpan(start, preSize) + + newStart -= pgid(preSize) + newSize += preSize + } + + if mergeWithNext { + // merge with next span + f.delSpan(next, nextSize) + newSize += nextSize + } + + f.addSpan(newStart, newSize) +} + +func (f *freelist) addSpan(start pgid, size uint64) { + f.backwardMap[start-1+pgid(size)] = size + f.forwardMap[start] = size + if _, ok := f.freemaps[size]; !ok { + f.freemaps[size] = make(map[pgid]struct{}) + } + + f.freemaps[size][start] = struct{}{} +} + +func (f *freelist) delSpan(start pgid, size uint64) { + delete(f.forwardMap, start) + delete(f.backwardMap, start+pgid(size-1)) + delete(f.freemaps[size], start) + if len(f.freemaps[size]) == 0 { + delete(f.freemaps, size) + } +} + +// initial from pgids using when use hashmap version +// pgids must be sorted +func (f *freelist) init(pgids []pgid) { + if len(pgids) == 0 { + return + } + + size := uint64(1) + start := pgids[0] + + if !sort.SliceIsSorted([]pgid(pgids), func(i, j int) bool { return pgids[i] < pgids[j] }) { + panic("pgids not sorted") + } + + f.freemaps = make(map[uint64]pidSet) + f.forwardMap = make(map[pgid]uint64) + f.backwardMap = make(map[pgid]uint64) + + for i := 1; i < len(pgids); i++ { + // continuous page + if pgids[i] == pgids[i-1]+1 { + size++ + } else { + f.addSpan(start, size) + + size = 1 + start = pgids[i] + } + } + + // init the tail + if size != 0 && start != 0 { + f.addSpan(start, size) + } +} diff --git a/vendor/etcd.io/bbolt/freelist_test.go b/vendor/etcd.io/bbolt/freelist_test.go new file mode 100644 index 0000000..97656f4 --- /dev/null +++ b/vendor/etcd.io/bbolt/freelist_test.go @@ -0,0 +1,434 @@ +package bbolt + +import ( + "math/rand" + "os" + "reflect" + "sort" + "testing" + "unsafe" +) + +// TestFreelistType is used as a env variable for test to indicate the backend type +const TestFreelistType = "TEST_FREELIST_TYPE" + +// Ensure that a page is added to a transaction's freelist. +func TestFreelist_free(t *testing.T) { + f := newTestFreelist() + f.free(100, &page{id: 12}) + if !reflect.DeepEqual([]pgid{12}, f.pending[100].ids) { + t.Fatalf("exp=%v; got=%v", []pgid{12}, f.pending[100].ids) + } +} + +// Ensure that a page and its overflow is added to a transaction's freelist. +func TestFreelist_free_overflow(t *testing.T) { + f := newTestFreelist() + f.free(100, &page{id: 12, overflow: 3}) + if exp := []pgid{12, 13, 14, 15}; !reflect.DeepEqual(exp, f.pending[100].ids) { + t.Fatalf("exp=%v; got=%v", exp, f.pending[100].ids) + } +} + +// Ensure that a transaction's free pages can be released. +func TestFreelist_release(t *testing.T) { + f := newTestFreelist() + f.free(100, &page{id: 12, overflow: 1}) + f.free(100, &page{id: 9}) + f.free(102, &page{id: 39}) + f.release(100) + f.release(101) + if exp := []pgid{9, 12, 13}; !reflect.DeepEqual(exp, f.getFreePageIDs()) { + t.Fatalf("exp=%v; got=%v", exp, f.getFreePageIDs()) + } + + f.release(102) + if exp := []pgid{9, 12, 13, 39}; !reflect.DeepEqual(exp, f.getFreePageIDs()) { + t.Fatalf("exp=%v; got=%v", exp, f.getFreePageIDs()) + } +} + +// Ensure that releaseRange handles boundary conditions correctly +func TestFreelist_releaseRange(t *testing.T) { + type testRange struct { + begin, end txid + } + + type testPage struct { + id pgid + n int + allocTxn txid + freeTxn txid + } + + var releaseRangeTests = []struct { + title string + pagesIn []testPage + releaseRanges []testRange + wantFree []pgid + }{ + { + title: "Single pending in range", + pagesIn: []testPage{{id: 3, n: 1, allocTxn: 100, freeTxn: 200}}, + releaseRanges: []testRange{{1, 300}}, + wantFree: []pgid{3}, + }, + { + title: "Single pending with minimum end range", + pagesIn: []testPage{{id: 3, n: 1, allocTxn: 100, freeTxn: 200}}, + releaseRanges: []testRange{{1, 200}}, + wantFree: []pgid{3}, + }, + { + title: "Single pending outsize minimum end range", + pagesIn: []testPage{{id: 3, n: 1, allocTxn: 100, freeTxn: 200}}, + releaseRanges: []testRange{{1, 199}}, + wantFree: nil, + }, + { + title: "Single pending with minimum begin range", + pagesIn: []testPage{{id: 3, n: 1, allocTxn: 100, freeTxn: 200}}, + releaseRanges: []testRange{{100, 300}}, + wantFree: []pgid{3}, + }, + { + title: "Single pending outside minimum begin range", + pagesIn: []testPage{{id: 3, n: 1, allocTxn: 100, freeTxn: 200}}, + releaseRanges: []testRange{{101, 300}}, + wantFree: nil, + }, + { + title: "Single pending in minimum range", + pagesIn: []testPage{{id: 3, n: 1, allocTxn: 199, freeTxn: 200}}, + releaseRanges: []testRange{{199, 200}}, + wantFree: []pgid{3}, + }, + { + title: "Single pending and read transaction at 199", + pagesIn: []testPage{{id: 3, n: 1, allocTxn: 199, freeTxn: 200}}, + releaseRanges: []testRange{{100, 198}, {200, 300}}, + wantFree: nil, + }, + { + title: "Adjacent pending and read transactions at 199, 200", + pagesIn: []testPage{ + {id: 3, n: 1, allocTxn: 199, freeTxn: 200}, + {id: 4, n: 1, allocTxn: 200, freeTxn: 201}, + }, + releaseRanges: []testRange{ + {100, 198}, + {200, 199}, // Simulate the ranges db.freePages might produce. + {201, 300}, + }, + wantFree: nil, + }, + { + title: "Out of order ranges", + pagesIn: []testPage{ + {id: 3, n: 1, allocTxn: 199, freeTxn: 200}, + {id: 4, n: 1, allocTxn: 200, freeTxn: 201}, + }, + releaseRanges: []testRange{ + {201, 199}, + {201, 200}, + {200, 200}, + }, + wantFree: nil, + }, + { + title: "Multiple pending, read transaction at 150", + pagesIn: []testPage{ + {id: 3, n: 1, allocTxn: 100, freeTxn: 200}, + {id: 4, n: 1, allocTxn: 100, freeTxn: 125}, + {id: 5, n: 1, allocTxn: 125, freeTxn: 150}, + {id: 6, n: 1, allocTxn: 125, freeTxn: 175}, + {id: 7, n: 2, allocTxn: 150, freeTxn: 175}, + {id: 9, n: 2, allocTxn: 175, freeTxn: 200}, + }, + releaseRanges: []testRange{{50, 149}, {151, 300}}, + wantFree: []pgid{4, 9, 10}, + }, + } + + for _, c := range releaseRangeTests { + f := newTestFreelist() + var ids []pgid + for _, p := range c.pagesIn { + for i := uint64(0); i < uint64(p.n); i++ { + ids = append(ids, pgid(uint64(p.id)+i)) + } + } + f.readIDs(ids) + for _, p := range c.pagesIn { + f.allocate(p.allocTxn, p.n) + } + + for _, p := range c.pagesIn { + f.free(p.freeTxn, &page{id: p.id, overflow: uint32(p.n - 1)}) + } + + for _, r := range c.releaseRanges { + f.releaseRange(r.begin, r.end) + } + + if exp := c.wantFree; !reflect.DeepEqual(exp, f.getFreePageIDs()) { + t.Errorf("exp=%v; got=%v for %s", exp, f.getFreePageIDs(), c.title) + } + } +} + +func TestFreelistHashmap_allocate(t *testing.T) { + f := newTestFreelist() + if f.freelistType != FreelistMapType { + t.Skip() + } + + ids := []pgid{3, 4, 5, 6, 7, 9, 12, 13, 18} + f.readIDs(ids) + + f.allocate(1, 3) + if x := f.free_count(); x != 6 { + t.Fatalf("exp=6; got=%v", x) + } + + f.allocate(1, 2) + if x := f.free_count(); x != 4 { + t.Fatalf("exp=4; got=%v", x) + } + f.allocate(1, 1) + if x := f.free_count(); x != 3 { + t.Fatalf("exp=3; got=%v", x) + } + + f.allocate(1, 0) + if x := f.free_count(); x != 3 { + t.Fatalf("exp=3; got=%v", x) + } +} + +// Ensure that a freelist can find contiguous blocks of pages. +func TestFreelistArray_allocate(t *testing.T) { + f := newTestFreelist() + if f.freelistType != FreelistArrayType { + t.Skip() + } + ids := []pgid{3, 4, 5, 6, 7, 9, 12, 13, 18} + f.readIDs(ids) + if id := int(f.allocate(1, 3)); id != 3 { + t.Fatalf("exp=3; got=%v", id) + } + if id := int(f.allocate(1, 1)); id != 6 { + t.Fatalf("exp=6; got=%v", id) + } + if id := int(f.allocate(1, 3)); id != 0 { + t.Fatalf("exp=0; got=%v", id) + } + if id := int(f.allocate(1, 2)); id != 12 { + t.Fatalf("exp=12; got=%v", id) + } + if id := int(f.allocate(1, 1)); id != 7 { + t.Fatalf("exp=7; got=%v", id) + } + if id := int(f.allocate(1, 0)); id != 0 { + t.Fatalf("exp=0; got=%v", id) + } + if id := int(f.allocate(1, 0)); id != 0 { + t.Fatalf("exp=0; got=%v", id) + } + if exp := []pgid{9, 18}; !reflect.DeepEqual(exp, f.getFreePageIDs()) { + t.Fatalf("exp=%v; got=%v", exp, f.getFreePageIDs()) + } + + if id := int(f.allocate(1, 1)); id != 9 { + t.Fatalf("exp=9; got=%v", id) + } + if id := int(f.allocate(1, 1)); id != 18 { + t.Fatalf("exp=18; got=%v", id) + } + if id := int(f.allocate(1, 1)); id != 0 { + t.Fatalf("exp=0; got=%v", id) + } + if exp := []pgid{}; !reflect.DeepEqual(exp, f.getFreePageIDs()) { + t.Fatalf("exp=%v; got=%v", exp, f.getFreePageIDs()) + } +} + +// Ensure that a freelist can deserialize from a freelist page. +func TestFreelist_read(t *testing.T) { + // Create a page. + var buf [4096]byte + page := (*page)(unsafe.Pointer(&buf[0])) + page.flags = freelistPageFlag + page.count = 2 + + // Insert 2 page ids. + ids := (*[3]pgid)(unsafe.Pointer(uintptr(unsafe.Pointer(page)) + unsafe.Sizeof(*page))) + ids[0] = 23 + ids[1] = 50 + + // Deserialize page into a freelist. + f := newTestFreelist() + f.read(page) + + // Ensure that there are two page ids in the freelist. + if exp := []pgid{23, 50}; !reflect.DeepEqual(exp, f.getFreePageIDs()) { + t.Fatalf("exp=%v; got=%v", exp, f.getFreePageIDs()) + } +} + +// Ensure that a freelist can serialize into a freelist page. +func TestFreelist_write(t *testing.T) { + // Create a freelist and write it to a page. + var buf [4096]byte + f := newTestFreelist() + + f.readIDs([]pgid{12, 39}) + f.pending[100] = &txPending{ids: []pgid{28, 11}} + f.pending[101] = &txPending{ids: []pgid{3}} + p := (*page)(unsafe.Pointer(&buf[0])) + if err := f.write(p); err != nil { + t.Fatal(err) + } + + // Read the page back out. + f2 := newTestFreelist() + f2.read(p) + + // Ensure that the freelist is correct. + // All pages should be present and in reverse order. + if exp := []pgid{3, 11, 12, 28, 39}; !reflect.DeepEqual(exp, f2.getFreePageIDs()) { + t.Fatalf("exp=%v; got=%v", exp, f2.getFreePageIDs()) + } +} + +func Benchmark_FreelistRelease10K(b *testing.B) { benchmark_FreelistRelease(b, 10000) } +func Benchmark_FreelistRelease100K(b *testing.B) { benchmark_FreelistRelease(b, 100000) } +func Benchmark_FreelistRelease1000K(b *testing.B) { benchmark_FreelistRelease(b, 1000000) } +func Benchmark_FreelistRelease10000K(b *testing.B) { benchmark_FreelistRelease(b, 10000000) } + +func benchmark_FreelistRelease(b *testing.B, size int) { + ids := randomPgids(size) + pending := randomPgids(len(ids) / 400) + b.ResetTimer() + for i := 0; i < b.N; i++ { + txp := &txPending{ids: pending} + f := newTestFreelist() + f.pending = map[txid]*txPending{1: txp} + f.readIDs(ids) + f.release(1) + } +} + +func randomPgids(n int) []pgid { + rand.Seed(42) + pgids := make(pgids, n) + for i := range pgids { + pgids[i] = pgid(rand.Int63()) + } + sort.Sort(pgids) + return pgids +} + +func Test_freelist_ReadIDs_and_getFreePageIDs(t *testing.T) { + f := newTestFreelist() + exp := []pgid{3, 4, 5, 6, 7, 9, 12, 13, 18} + + f.readIDs(exp) + + if got := f.getFreePageIDs(); !reflect.DeepEqual(exp, got) { + t.Fatalf("exp=%v; got=%v", exp, got) + } + + f2 := newTestFreelist() + var exp2 []pgid + f2.readIDs(exp2) + + if got2 := f2.getFreePageIDs(); !reflect.DeepEqual(got2, exp2) { + t.Fatalf("exp2=%#v; got2=%#v", exp2, got2) + } + +} + +func Test_freelist_mergeWithExist(t *testing.T) { + bm1 := pidSet{1: struct{}{}} + + bm2 := pidSet{5: struct{}{}} + tests := []struct { + name string + ids []pgid + pgid pgid + want []pgid + wantForwardmap map[pgid]uint64 + wantBackwardmap map[pgid]uint64 + wantfreemap map[uint64]pidSet + }{ + { + name: "test1", + ids: []pgid{1, 2, 4, 5, 6}, + pgid: 3, + want: []pgid{1, 2, 3, 4, 5, 6}, + wantForwardmap: map[pgid]uint64{1: 6}, + wantBackwardmap: map[pgid]uint64{6: 6}, + wantfreemap: map[uint64]pidSet{6: bm1}, + }, + { + name: "test2", + ids: []pgid{1, 2, 5, 6}, + pgid: 3, + want: []pgid{1, 2, 3, 5, 6}, + wantForwardmap: map[pgid]uint64{1: 3, 5: 2}, + wantBackwardmap: map[pgid]uint64{6: 2, 3: 3}, + wantfreemap: map[uint64]pidSet{3: bm1, 2: bm2}, + }, + { + name: "test3", + ids: []pgid{1, 2}, + pgid: 3, + want: []pgid{1, 2, 3}, + wantForwardmap: map[pgid]uint64{1: 3}, + wantBackwardmap: map[pgid]uint64{3: 3}, + wantfreemap: map[uint64]pidSet{3: bm1}, + }, + { + name: "test4", + ids: []pgid{2, 3}, + pgid: 1, + want: []pgid{1, 2, 3}, + wantForwardmap: map[pgid]uint64{1: 3}, + wantBackwardmap: map[pgid]uint64{3: 3}, + wantfreemap: map[uint64]pidSet{3: bm1}, + }, + } + for _, tt := range tests { + f := newTestFreelist() + if f.freelistType == FreelistArrayType { + t.Skip() + } + f.readIDs(tt.ids) + + f.mergeWithExistingSpan(tt.pgid) + + if got := f.getFreePageIDs(); !reflect.DeepEqual(tt.want, got) { + t.Fatalf("name %s; exp=%v; got=%v", tt.name, tt.want, got) + } + if got := f.forwardMap; !reflect.DeepEqual(tt.wantForwardmap, got) { + t.Fatalf("name %s; exp=%v; got=%v", tt.name, tt.wantForwardmap, got) + } + if got := f.backwardMap; !reflect.DeepEqual(tt.wantBackwardmap, got) { + t.Fatalf("name %s; exp=%v; got=%v", tt.name, tt.wantBackwardmap, got) + } + if got := f.freemaps; !reflect.DeepEqual(tt.wantfreemap, got) { + t.Fatalf("name %s; exp=%v; got=%v", tt.name, tt.wantfreemap, got) + } + } +} + +// newTestFreelist get the freelist type from env and initial the freelist +func newTestFreelist() *freelist { + freelistType := FreelistArrayType + if env := os.Getenv(TestFreelistType); env == string(FreelistMapType) { + freelistType = FreelistMapType + } + + return newFreelist(freelistType) +} diff --git a/vendor/etcd.io/bbolt/go.mod b/vendor/etcd.io/bbolt/go.mod new file mode 100644 index 0000000..c2366da --- /dev/null +++ b/vendor/etcd.io/bbolt/go.mod @@ -0,0 +1,5 @@ +module go.etcd.io/bbolt + +go 1.12 + +require golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5 diff --git a/vendor/etcd.io/bbolt/go.sum b/vendor/etcd.io/bbolt/go.sum new file mode 100644 index 0000000..4ad15a4 --- /dev/null +++ b/vendor/etcd.io/bbolt/go.sum @@ -0,0 +1,2 @@ +golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5 h1:LfCXLvNmTYH9kEmVgqbnsWfruoXZIrh4YBgqVHtDvw0= +golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= diff --git a/vendor/etcd.io/bbolt/manydbs_test.go b/vendor/etcd.io/bbolt/manydbs_test.go new file mode 100644 index 0000000..fbbe8fe --- /dev/null +++ b/vendor/etcd.io/bbolt/manydbs_test.go @@ -0,0 +1,67 @@ +package bbolt + +import ( + "fmt" + "io/ioutil" + "math/rand" + "os" + "path/filepath" + "testing" +) + +func createDb(t *testing.T) (*DB, func()) { + // First, create a temporary directory to be used for the duration of + // this test. + tempDirName, err := ioutil.TempDir("", "bboltmemtest") + if err != nil { + t.Fatalf("error creating temp dir: %v", err) + } + path := filepath.Join(tempDirName, "testdb.db") + + bdb, err := Open(path, 0600, nil) + if err != nil { + t.Fatalf("error creating bbolt db: %v", err) + } + + cleanup := func() { + bdb.Close() + os.RemoveAll(tempDirName) + } + + return bdb, cleanup +} + +func createAndPutKeys(t *testing.T) { + t.Parallel() + + db, cleanup := createDb(t) + defer cleanup() + + bucketName := []byte("bucket") + + for i := 0; i < 100; i++ { + err := db.Update(func(tx *Tx) error { + nodes, err := tx.CreateBucketIfNotExists(bucketName) + if err != nil { + return err + } + + var key [16]byte + rand.Read(key[:]) + if err := nodes.Put(key[:], nil); err != nil { + return err + } + + return nil + }) + if err != nil { + t.Fatal(err) + } + } +} + +func TestManyDBs(t *testing.T) { + for i := 0; i < 100; i++ { + t.Run(fmt.Sprintf("%d", i), createAndPutKeys) + } +} diff --git a/vendor/etcd.io/bbolt/node.go b/vendor/etcd.io/bbolt/node.go new file mode 100644 index 0000000..73988b5 --- /dev/null +++ b/vendor/etcd.io/bbolt/node.go @@ -0,0 +1,602 @@ +package bbolt + +import ( + "bytes" + "fmt" + "sort" + "unsafe" +) + +// node represents an in-memory, deserialized page. +type node struct { + bucket *Bucket + isLeaf bool + unbalanced bool + spilled bool + key []byte + pgid pgid + parent *node + children nodes + inodes inodes +} + +// root returns the top-level node this node is attached to. +func (n *node) root() *node { + if n.parent == nil { + return n + } + return n.parent.root() +} + +// minKeys returns the minimum number of inodes this node should have. +func (n *node) minKeys() int { + if n.isLeaf { + return 1 + } + return 2 +} + +// size returns the size of the node after serialization. +func (n *node) size() int { + sz, elsz := pageHeaderSize, n.pageElementSize() + for i := 0; i < len(n.inodes); i++ { + item := &n.inodes[i] + sz += elsz + uintptr(len(item.key)) + uintptr(len(item.value)) + } + return int(sz) +} + +// sizeLessThan returns true if the node is less than a given size. +// This is an optimization to avoid calculating a large node when we only need +// to know if it fits inside a certain page size. +func (n *node) sizeLessThan(v uintptr) bool { + sz, elsz := pageHeaderSize, n.pageElementSize() + for i := 0; i < len(n.inodes); i++ { + item := &n.inodes[i] + sz += elsz + uintptr(len(item.key)) + uintptr(len(item.value)) + if sz >= v { + return false + } + } + return true +} + +// pageElementSize returns the size of each page element based on the type of node. +func (n *node) pageElementSize() uintptr { + if n.isLeaf { + return leafPageElementSize + } + return branchPageElementSize +} + +// childAt returns the child node at a given index. +func (n *node) childAt(index int) *node { + if n.isLeaf { + panic(fmt.Sprintf("invalid childAt(%d) on a leaf node", index)) + } + return n.bucket.node(n.inodes[index].pgid, n) +} + +// childIndex returns the index of a given child node. +func (n *node) childIndex(child *node) int { + index := sort.Search(len(n.inodes), func(i int) bool { return bytes.Compare(n.inodes[i].key, child.key) != -1 }) + return index +} + +// numChildren returns the number of children. +func (n *node) numChildren() int { + return len(n.inodes) +} + +// nextSibling returns the next node with the same parent. +func (n *node) nextSibling() *node { + if n.parent == nil { + return nil + } + index := n.parent.childIndex(n) + if index >= n.parent.numChildren()-1 { + return nil + } + return n.parent.childAt(index + 1) +} + +// prevSibling returns the previous node with the same parent. +func (n *node) prevSibling() *node { + if n.parent == nil { + return nil + } + index := n.parent.childIndex(n) + if index == 0 { + return nil + } + return n.parent.childAt(index - 1) +} + +// put inserts a key/value. +func (n *node) put(oldKey, newKey, value []byte, pgid pgid, flags uint32) { + if pgid >= n.bucket.tx.meta.pgid { + panic(fmt.Sprintf("pgid (%d) above high water mark (%d)", pgid, n.bucket.tx.meta.pgid)) + } else if len(oldKey) <= 0 { + panic("put: zero-length old key") + } else if len(newKey) <= 0 { + panic("put: zero-length new key") + } + + // Find insertion index. + index := sort.Search(len(n.inodes), func(i int) bool { return bytes.Compare(n.inodes[i].key, oldKey) != -1 }) + + // Add capacity and shift nodes if we don't have an exact match and need to insert. + exact := (len(n.inodes) > 0 && index < len(n.inodes) && bytes.Equal(n.inodes[index].key, oldKey)) + if !exact { + n.inodes = append(n.inodes, inode{}) + copy(n.inodes[index+1:], n.inodes[index:]) + } + + inode := &n.inodes[index] + inode.flags = flags + inode.key = newKey + inode.value = value + inode.pgid = pgid + _assert(len(inode.key) > 0, "put: zero-length inode key") +} + +// del removes a key from the node. +func (n *node) del(key []byte) { + // Find index of key. + index := sort.Search(len(n.inodes), func(i int) bool { return bytes.Compare(n.inodes[i].key, key) != -1 }) + + // Exit if the key isn't found. + if index >= len(n.inodes) || !bytes.Equal(n.inodes[index].key, key) { + return + } + + // Delete inode from the node. + n.inodes = append(n.inodes[:index], n.inodes[index+1:]...) + + // Mark the node as needing rebalancing. + n.unbalanced = true +} + +// read initializes the node from a page. +func (n *node) read(p *page) { + n.pgid = p.id + n.isLeaf = ((p.flags & leafPageFlag) != 0) + n.inodes = make(inodes, int(p.count)) + + for i := 0; i < int(p.count); i++ { + inode := &n.inodes[i] + if n.isLeaf { + elem := p.leafPageElement(uint16(i)) + inode.flags = elem.flags + inode.key = elem.key() + inode.value = elem.value() + } else { + elem := p.branchPageElement(uint16(i)) + inode.pgid = elem.pgid + inode.key = elem.key() + } + _assert(len(inode.key) > 0, "read: zero-length inode key") + } + + // Save first key so we can find the node in the parent when we spill. + if len(n.inodes) > 0 { + n.key = n.inodes[0].key + _assert(len(n.key) > 0, "read: zero-length node key") + } else { + n.key = nil + } +} + +// write writes the items onto one or more pages. +func (n *node) write(p *page) { + // Initialize page. + if n.isLeaf { + p.flags |= leafPageFlag + } else { + p.flags |= branchPageFlag + } + + if len(n.inodes) >= 0xFFFF { + panic(fmt.Sprintf("inode overflow: %d (pgid=%d)", len(n.inodes), p.id)) + } + p.count = uint16(len(n.inodes)) + + // Stop here if there are no items to write. + if p.count == 0 { + return + } + + // Loop over each item and write it to the page. + // off tracks the offset into p of the start of the next data. + off := unsafe.Sizeof(*p) + n.pageElementSize()*uintptr(len(n.inodes)) + for i, item := range n.inodes { + _assert(len(item.key) > 0, "write: zero-length inode key") + + // Create a slice to write into of needed size and advance + // byte pointer for next iteration. + sz := len(item.key) + len(item.value) + b := unsafeByteSlice(unsafe.Pointer(p), off, 0, sz) + off += uintptr(sz) + + // Write the page element. + if n.isLeaf { + elem := p.leafPageElement(uint16(i)) + elem.pos = uint32(uintptr(unsafe.Pointer(&b[0])) - uintptr(unsafe.Pointer(elem))) + elem.flags = item.flags + elem.ksize = uint32(len(item.key)) + elem.vsize = uint32(len(item.value)) + } else { + elem := p.branchPageElement(uint16(i)) + elem.pos = uint32(uintptr(unsafe.Pointer(&b[0])) - uintptr(unsafe.Pointer(elem))) + elem.ksize = uint32(len(item.key)) + elem.pgid = item.pgid + _assert(elem.pgid != p.id, "write: circular dependency occurred") + } + + // Write data for the element to the end of the page. + l := copy(b, item.key) + copy(b[l:], item.value) + } + + // DEBUG ONLY: n.dump() +} + +// split breaks up a node into multiple smaller nodes, if appropriate. +// This should only be called from the spill() function. +func (n *node) split(pageSize uintptr) []*node { + var nodes []*node + + node := n + for { + // Split node into two. + a, b := node.splitTwo(pageSize) + nodes = append(nodes, a) + + // If we can't split then exit the loop. + if b == nil { + break + } + + // Set node to b so it gets split on the next iteration. + node = b + } + + return nodes +} + +// splitTwo breaks up a node into two smaller nodes, if appropriate. +// This should only be called from the split() function. +func (n *node) splitTwo(pageSize uintptr) (*node, *node) { + // Ignore the split if the page doesn't have at least enough nodes for + // two pages or if the nodes can fit in a single page. + if len(n.inodes) <= (minKeysPerPage*2) || n.sizeLessThan(pageSize) { + return n, nil + } + + // Determine the threshold before starting a new node. + var fillPercent = n.bucket.FillPercent + if fillPercent < minFillPercent { + fillPercent = minFillPercent + } else if fillPercent > maxFillPercent { + fillPercent = maxFillPercent + } + threshold := int(float64(pageSize) * fillPercent) + + // Determine split position and sizes of the two pages. + splitIndex, _ := n.splitIndex(threshold) + + // Split node into two separate nodes. + // If there's no parent then we'll need to create one. + if n.parent == nil { + n.parent = &node{bucket: n.bucket, children: []*node{n}} + } + + // Create a new node and add it to the parent. + next := &node{bucket: n.bucket, isLeaf: n.isLeaf, parent: n.parent} + n.parent.children = append(n.parent.children, next) + + // Split inodes across two nodes. + next.inodes = n.inodes[splitIndex:] + n.inodes = n.inodes[:splitIndex] + + // Update the statistics. + n.bucket.tx.stats.Split++ + + return n, next +} + +// splitIndex finds the position where a page will fill a given threshold. +// It returns the index as well as the size of the first page. +// This is only be called from split(). +func (n *node) splitIndex(threshold int) (index, sz uintptr) { + sz = pageHeaderSize + + // Loop until we only have the minimum number of keys required for the second page. + for i := 0; i < len(n.inodes)-minKeysPerPage; i++ { + index = uintptr(i) + inode := n.inodes[i] + elsize := n.pageElementSize() + uintptr(len(inode.key)) + uintptr(len(inode.value)) + + // If we have at least the minimum number of keys and adding another + // node would put us over the threshold then exit and return. + if index >= minKeysPerPage && sz+elsize > uintptr(threshold) { + break + } + + // Add the element size to the total size. + sz += elsize + } + + return +} + +// spill writes the nodes to dirty pages and splits nodes as it goes. +// Returns an error if dirty pages cannot be allocated. +func (n *node) spill() error { + var tx = n.bucket.tx + if n.spilled { + return nil + } + + // Spill child nodes first. Child nodes can materialize sibling nodes in + // the case of split-merge so we cannot use a range loop. We have to check + // the children size on every loop iteration. + sort.Sort(n.children) + for i := 0; i < len(n.children); i++ { + if err := n.children[i].spill(); err != nil { + return err + } + } + + // We no longer need the child list because it's only used for spill tracking. + n.children = nil + + // Split nodes into appropriate sizes. The first node will always be n. + var nodes = n.split(uintptr(tx.db.pageSize)) + for _, node := range nodes { + // Add node's page to the freelist if it's not new. + if node.pgid > 0 { + tx.db.freelist.free(tx.meta.txid, tx.page(node.pgid)) + node.pgid = 0 + } + + // Allocate contiguous space for the node. + p, err := tx.allocate((node.size() + tx.db.pageSize - 1) / tx.db.pageSize) + if err != nil { + return err + } + + // Write the node. + if p.id >= tx.meta.pgid { + panic(fmt.Sprintf("pgid (%d) above high water mark (%d)", p.id, tx.meta.pgid)) + } + node.pgid = p.id + node.write(p) + node.spilled = true + + // Insert into parent inodes. + if node.parent != nil { + var key = node.key + if key == nil { + key = node.inodes[0].key + } + + node.parent.put(key, node.inodes[0].key, nil, node.pgid, 0) + node.key = node.inodes[0].key + _assert(len(node.key) > 0, "spill: zero-length node key") + } + + // Update the statistics. + tx.stats.Spill++ + } + + // If the root node split and created a new root then we need to spill that + // as well. We'll clear out the children to make sure it doesn't try to respill. + if n.parent != nil && n.parent.pgid == 0 { + n.children = nil + return n.parent.spill() + } + + return nil +} + +// rebalance attempts to combine the node with sibling nodes if the node fill +// size is below a threshold or if there are not enough keys. +func (n *node) rebalance() { + if !n.unbalanced { + return + } + n.unbalanced = false + + // Update statistics. + n.bucket.tx.stats.Rebalance++ + + // Ignore if node is above threshold (25%) and has enough keys. + var threshold = n.bucket.tx.db.pageSize / 4 + if n.size() > threshold && len(n.inodes) > n.minKeys() { + return + } + + // Root node has special handling. + if n.parent == nil { + // If root node is a branch and only has one node then collapse it. + if !n.isLeaf && len(n.inodes) == 1 { + // Move root's child up. + child := n.bucket.node(n.inodes[0].pgid, n) + n.isLeaf = child.isLeaf + n.inodes = child.inodes[:] + n.children = child.children + + // Reparent all child nodes being moved. + for _, inode := range n.inodes { + if child, ok := n.bucket.nodes[inode.pgid]; ok { + child.parent = n + } + } + + // Remove old child. + child.parent = nil + delete(n.bucket.nodes, child.pgid) + child.free() + } + + return + } + + // If node has no keys then just remove it. + if n.numChildren() == 0 { + n.parent.del(n.key) + n.parent.removeChild(n) + delete(n.bucket.nodes, n.pgid) + n.free() + n.parent.rebalance() + return + } + + _assert(n.parent.numChildren() > 1, "parent must have at least 2 children") + + // Destination node is right sibling if idx == 0, otherwise left sibling. + var target *node + var useNextSibling = (n.parent.childIndex(n) == 0) + if useNextSibling { + target = n.nextSibling() + } else { + target = n.prevSibling() + } + + // If both this node and the target node are too small then merge them. + if useNextSibling { + // Reparent all child nodes being moved. + for _, inode := range target.inodes { + if child, ok := n.bucket.nodes[inode.pgid]; ok { + child.parent.removeChild(child) + child.parent = n + child.parent.children = append(child.parent.children, child) + } + } + + // Copy over inodes from target and remove target. + n.inodes = append(n.inodes, target.inodes...) + n.parent.del(target.key) + n.parent.removeChild(target) + delete(n.bucket.nodes, target.pgid) + target.free() + } else { + // Reparent all child nodes being moved. + for _, inode := range n.inodes { + if child, ok := n.bucket.nodes[inode.pgid]; ok { + child.parent.removeChild(child) + child.parent = target + child.parent.children = append(child.parent.children, child) + } + } + + // Copy over inodes to target and remove node. + target.inodes = append(target.inodes, n.inodes...) + n.parent.del(n.key) + n.parent.removeChild(n) + delete(n.bucket.nodes, n.pgid) + n.free() + } + + // Either this node or the target node was deleted from the parent so rebalance it. + n.parent.rebalance() +} + +// removes a node from the list of in-memory children. +// This does not affect the inodes. +func (n *node) removeChild(target *node) { + for i, child := range n.children { + if child == target { + n.children = append(n.children[:i], n.children[i+1:]...) + return + } + } +} + +// dereference causes the node to copy all its inode key/value references to heap memory. +// This is required when the mmap is reallocated so inodes are not pointing to stale data. +func (n *node) dereference() { + if n.key != nil { + key := make([]byte, len(n.key)) + copy(key, n.key) + n.key = key + _assert(n.pgid == 0 || len(n.key) > 0, "dereference: zero-length node key on existing node") + } + + for i := range n.inodes { + inode := &n.inodes[i] + + key := make([]byte, len(inode.key)) + copy(key, inode.key) + inode.key = key + _assert(len(inode.key) > 0, "dereference: zero-length inode key") + + value := make([]byte, len(inode.value)) + copy(value, inode.value) + inode.value = value + } + + // Recursively dereference children. + for _, child := range n.children { + child.dereference() + } + + // Update statistics. + n.bucket.tx.stats.NodeDeref++ +} + +// free adds the node's underlying page to the freelist. +func (n *node) free() { + if n.pgid != 0 { + n.bucket.tx.db.freelist.free(n.bucket.tx.meta.txid, n.bucket.tx.page(n.pgid)) + n.pgid = 0 + } +} + +// dump writes the contents of the node to STDERR for debugging purposes. +/* +func (n *node) dump() { + // Write node header. + var typ = "branch" + if n.isLeaf { + typ = "leaf" + } + warnf("[NODE %d {type=%s count=%d}]", n.pgid, typ, len(n.inodes)) + + // Write out abbreviated version of each item. + for _, item := range n.inodes { + if n.isLeaf { + if item.flags&bucketLeafFlag != 0 { + bucket := (*bucket)(unsafe.Pointer(&item.value[0])) + warnf("+L %08x -> (bucket root=%d)", trunc(item.key, 4), bucket.root) + } else { + warnf("+L %08x -> %08x", trunc(item.key, 4), trunc(item.value, 4)) + } + } else { + warnf("+B %08x -> pgid=%d", trunc(item.key, 4), item.pgid) + } + } + warn("") +} +*/ + +type nodes []*node + +func (s nodes) Len() int { return len(s) } +func (s nodes) Swap(i, j int) { s[i], s[j] = s[j], s[i] } +func (s nodes) Less(i, j int) bool { + return bytes.Compare(s[i].inodes[0].key, s[j].inodes[0].key) == -1 +} + +// inode represents an internal node inside of a node. +// It can be used to point to elements in a page or point +// to an element which hasn't been added to a page yet. +type inode struct { + flags uint32 + pgid pgid + key []byte + value []byte +} + +type inodes []inode diff --git a/vendor/etcd.io/bbolt/node_test.go b/vendor/etcd.io/bbolt/node_test.go new file mode 100644 index 0000000..eea4d25 --- /dev/null +++ b/vendor/etcd.io/bbolt/node_test.go @@ -0,0 +1,156 @@ +package bbolt + +import ( + "testing" + "unsafe" +) + +// Ensure that a node can insert a key/value. +func TestNode_put(t *testing.T) { + n := &node{inodes: make(inodes, 0), bucket: &Bucket{tx: &Tx{meta: &meta{pgid: 1}}}} + n.put([]byte("baz"), []byte("baz"), []byte("2"), 0, 0) + n.put([]byte("foo"), []byte("foo"), []byte("0"), 0, 0) + n.put([]byte("bar"), []byte("bar"), []byte("1"), 0, 0) + n.put([]byte("foo"), []byte("foo"), []byte("3"), 0, leafPageFlag) + + if len(n.inodes) != 3 { + t.Fatalf("exp=3; got=%d", len(n.inodes)) + } + if k, v := n.inodes[0].key, n.inodes[0].value; string(k) != "bar" || string(v) != "1" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } + if k, v := n.inodes[1].key, n.inodes[1].value; string(k) != "baz" || string(v) != "2" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } + if k, v := n.inodes[2].key, n.inodes[2].value; string(k) != "foo" || string(v) != "3" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } + if n.inodes[2].flags != uint32(leafPageFlag) { + t.Fatalf("not a leaf: %d", n.inodes[2].flags) + } +} + +// Ensure that a node can deserialize from a leaf page. +func TestNode_read_LeafPage(t *testing.T) { + // Create a page. + var buf [4096]byte + page := (*page)(unsafe.Pointer(&buf[0])) + page.flags = leafPageFlag + page.count = 2 + + // Insert 2 elements at the beginning. sizeof(leafPageElement) == 16 + nodes := (*[3]leafPageElement)(unsafe.Pointer(uintptr(unsafe.Pointer(page)) + unsafe.Sizeof(*page))) + nodes[0] = leafPageElement{flags: 0, pos: 32, ksize: 3, vsize: 4} // pos = sizeof(leafPageElement) * 2 + nodes[1] = leafPageElement{flags: 0, pos: 23, ksize: 10, vsize: 3} // pos = sizeof(leafPageElement) + 3 + 4 + + // Write data for the nodes at the end. + const s = "barfoozhelloworldbye" + data := unsafeByteSlice(unsafe.Pointer(&nodes[2]), 0, 0, len(s)) + copy(data, s) + + // Deserialize page into a leaf. + n := &node{} + n.read(page) + + // Check that there are two inodes with correct data. + if !n.isLeaf { + t.Fatal("expected leaf") + } + if len(n.inodes) != 2 { + t.Fatalf("exp=2; got=%d", len(n.inodes)) + } + if k, v := n.inodes[0].key, n.inodes[0].value; string(k) != "bar" || string(v) != "fooz" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } + if k, v := n.inodes[1].key, n.inodes[1].value; string(k) != "helloworld" || string(v) != "bye" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } +} + +// Ensure that a node can serialize into a leaf page. +func TestNode_write_LeafPage(t *testing.T) { + // Create a node. + n := &node{isLeaf: true, inodes: make(inodes, 0), bucket: &Bucket{tx: &Tx{db: &DB{}, meta: &meta{pgid: 1}}}} + n.put([]byte("susy"), []byte("susy"), []byte("que"), 0, 0) + n.put([]byte("ricki"), []byte("ricki"), []byte("lake"), 0, 0) + n.put([]byte("john"), []byte("john"), []byte("johnson"), 0, 0) + + // Write it to a page. + var buf [4096]byte + p := (*page)(unsafe.Pointer(&buf[0])) + n.write(p) + + // Read the page back in. + n2 := &node{} + n2.read(p) + + // Check that the two pages are the same. + if len(n2.inodes) != 3 { + t.Fatalf("exp=3; got=%d", len(n2.inodes)) + } + if k, v := n2.inodes[0].key, n2.inodes[0].value; string(k) != "john" || string(v) != "johnson" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } + if k, v := n2.inodes[1].key, n2.inodes[1].value; string(k) != "ricki" || string(v) != "lake" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } + if k, v := n2.inodes[2].key, n2.inodes[2].value; string(k) != "susy" || string(v) != "que" { + t.Fatalf("exp=; got=<%s,%s>", k, v) + } +} + +// Ensure that a node can split into appropriate subgroups. +func TestNode_split(t *testing.T) { + // Create a node. + n := &node{inodes: make(inodes, 0), bucket: &Bucket{tx: &Tx{db: &DB{}, meta: &meta{pgid: 1}}}} + n.put([]byte("00000001"), []byte("00000001"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000002"), []byte("00000002"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000003"), []byte("00000003"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000004"), []byte("00000004"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000005"), []byte("00000005"), []byte("0123456701234567"), 0, 0) + + // Split between 2 & 3. + n.split(100) + + var parent = n.parent + if len(parent.children) != 2 { + t.Fatalf("exp=2; got=%d", len(parent.children)) + } + if len(parent.children[0].inodes) != 2 { + t.Fatalf("exp=2; got=%d", len(parent.children[0].inodes)) + } + if len(parent.children[1].inodes) != 3 { + t.Fatalf("exp=3; got=%d", len(parent.children[1].inodes)) + } +} + +// Ensure that a page with the minimum number of inodes just returns a single node. +func TestNode_split_MinKeys(t *testing.T) { + // Create a node. + n := &node{inodes: make(inodes, 0), bucket: &Bucket{tx: &Tx{db: &DB{}, meta: &meta{pgid: 1}}}} + n.put([]byte("00000001"), []byte("00000001"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000002"), []byte("00000002"), []byte("0123456701234567"), 0, 0) + + // Split. + n.split(20) + if n.parent != nil { + t.Fatalf("expected nil parent") + } +} + +// Ensure that a node that has keys that all fit on a page just returns one leaf. +func TestNode_split_SinglePage(t *testing.T) { + // Create a node. + n := &node{inodes: make(inodes, 0), bucket: &Bucket{tx: &Tx{db: &DB{}, meta: &meta{pgid: 1}}}} + n.put([]byte("00000001"), []byte("00000001"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000002"), []byte("00000002"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000003"), []byte("00000003"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000004"), []byte("00000004"), []byte("0123456701234567"), 0, 0) + n.put([]byte("00000005"), []byte("00000005"), []byte("0123456701234567"), 0, 0) + + // Split. + n.split(4096) + if n.parent != nil { + t.Fatalf("expected nil parent") + } +} diff --git a/vendor/etcd.io/bbolt/page.go b/vendor/etcd.io/bbolt/page.go new file mode 100644 index 0000000..c9a158f --- /dev/null +++ b/vendor/etcd.io/bbolt/page.go @@ -0,0 +1,204 @@ +package bbolt + +import ( + "fmt" + "os" + "sort" + "unsafe" +) + +const pageHeaderSize = unsafe.Sizeof(page{}) + +const minKeysPerPage = 2 + +const branchPageElementSize = unsafe.Sizeof(branchPageElement{}) +const leafPageElementSize = unsafe.Sizeof(leafPageElement{}) + +const ( + branchPageFlag = 0x01 + leafPageFlag = 0x02 + metaPageFlag = 0x04 + freelistPageFlag = 0x10 +) + +const ( + bucketLeafFlag = 0x01 +) + +type pgid uint64 + +type page struct { + id pgid + flags uint16 + count uint16 + overflow uint32 +} + +// typ returns a human readable page type string used for debugging. +func (p *page) typ() string { + if (p.flags & branchPageFlag) != 0 { + return "branch" + } else if (p.flags & leafPageFlag) != 0 { + return "leaf" + } else if (p.flags & metaPageFlag) != 0 { + return "meta" + } else if (p.flags & freelistPageFlag) != 0 { + return "freelist" + } + return fmt.Sprintf("unknown<%02x>", p.flags) +} + +// meta returns a pointer to the metadata section of the page. +func (p *page) meta() *meta { + return (*meta)(unsafeAdd(unsafe.Pointer(p), unsafe.Sizeof(*p))) +} + +// leafPageElement retrieves the leaf node by index +func (p *page) leafPageElement(index uint16) *leafPageElement { + return (*leafPageElement)(unsafeIndex(unsafe.Pointer(p), unsafe.Sizeof(*p), + leafPageElementSize, int(index))) +} + +// leafPageElements retrieves a list of leaf nodes. +func (p *page) leafPageElements() []leafPageElement { + if p.count == 0 { + return nil + } + var elems []leafPageElement + data := unsafeAdd(unsafe.Pointer(p), unsafe.Sizeof(*p)) + unsafeSlice(unsafe.Pointer(&elems), data, int(p.count)) + return elems +} + +// branchPageElement retrieves the branch node by index +func (p *page) branchPageElement(index uint16) *branchPageElement { + return (*branchPageElement)(unsafeIndex(unsafe.Pointer(p), unsafe.Sizeof(*p), + unsafe.Sizeof(branchPageElement{}), int(index))) +} + +// branchPageElements retrieves a list of branch nodes. +func (p *page) branchPageElements() []branchPageElement { + if p.count == 0 { + return nil + } + var elems []branchPageElement + data := unsafeAdd(unsafe.Pointer(p), unsafe.Sizeof(*p)) + unsafeSlice(unsafe.Pointer(&elems), data, int(p.count)) + return elems +} + +// dump writes n bytes of the page to STDERR as hex output. +func (p *page) hexdump(n int) { + buf := unsafeByteSlice(unsafe.Pointer(p), 0, 0, n) + fmt.Fprintf(os.Stderr, "%x\n", buf) +} + +type pages []*page + +func (s pages) Len() int { return len(s) } +func (s pages) Swap(i, j int) { s[i], s[j] = s[j], s[i] } +func (s pages) Less(i, j int) bool { return s[i].id < s[j].id } + +// branchPageElement represents a node on a branch page. +type branchPageElement struct { + pos uint32 + ksize uint32 + pgid pgid +} + +// key returns a byte slice of the node key. +func (n *branchPageElement) key() []byte { + return unsafeByteSlice(unsafe.Pointer(n), 0, int(n.pos), int(n.pos)+int(n.ksize)) +} + +// leafPageElement represents a node on a leaf page. +type leafPageElement struct { + flags uint32 + pos uint32 + ksize uint32 + vsize uint32 +} + +// key returns a byte slice of the node key. +func (n *leafPageElement) key() []byte { + i := int(n.pos) + j := i + int(n.ksize) + return unsafeByteSlice(unsafe.Pointer(n), 0, i, j) +} + +// value returns a byte slice of the node value. +func (n *leafPageElement) value() []byte { + i := int(n.pos) + int(n.ksize) + j := i + int(n.vsize) + return unsafeByteSlice(unsafe.Pointer(n), 0, i, j) +} + +// PageInfo represents human readable information about a page. +type PageInfo struct { + ID int + Type string + Count int + OverflowCount int +} + +type pgids []pgid + +func (s pgids) Len() int { return len(s) } +func (s pgids) Swap(i, j int) { s[i], s[j] = s[j], s[i] } +func (s pgids) Less(i, j int) bool { return s[i] < s[j] } + +// merge returns the sorted union of a and b. +func (a pgids) merge(b pgids) pgids { + // Return the opposite slice if one is nil. + if len(a) == 0 { + return b + } + if len(b) == 0 { + return a + } + merged := make(pgids, len(a)+len(b)) + mergepgids(merged, a, b) + return merged +} + +// mergepgids copies the sorted union of a and b into dst. +// If dst is too small, it panics. +func mergepgids(dst, a, b pgids) { + if len(dst) < len(a)+len(b) { + panic(fmt.Errorf("mergepgids bad len %d < %d + %d", len(dst), len(a), len(b))) + } + // Copy in the opposite slice if one is nil. + if len(a) == 0 { + copy(dst, b) + return + } + if len(b) == 0 { + copy(dst, a) + return + } + + // Merged will hold all elements from both lists. + merged := dst[:0] + + // Assign lead to the slice with a lower starting value, follow to the higher value. + lead, follow := a, b + if b[0] < a[0] { + lead, follow = b, a + } + + // Continue while there are elements in the lead. + for len(lead) > 0 { + // Merge largest prefix of lead that is ahead of follow[0]. + n := sort.Search(len(lead), func(i int) bool { return lead[i] > follow[0] }) + merged = append(merged, lead[:n]...) + if n >= len(lead) { + break + } + + // Swap lead and follow. + lead, follow = follow, lead[n:] + } + + // Append what's left in follow. + _ = append(merged, follow...) +} diff --git a/vendor/etcd.io/bbolt/page_test.go b/vendor/etcd.io/bbolt/page_test.go new file mode 100644 index 0000000..9f5b7c0 --- /dev/null +++ b/vendor/etcd.io/bbolt/page_test.go @@ -0,0 +1,72 @@ +package bbolt + +import ( + "reflect" + "sort" + "testing" + "testing/quick" +) + +// Ensure that the page type can be returned in human readable format. +func TestPage_typ(t *testing.T) { + if typ := (&page{flags: branchPageFlag}).typ(); typ != "branch" { + t.Fatalf("exp=branch; got=%v", typ) + } + if typ := (&page{flags: leafPageFlag}).typ(); typ != "leaf" { + t.Fatalf("exp=leaf; got=%v", typ) + } + if typ := (&page{flags: metaPageFlag}).typ(); typ != "meta" { + t.Fatalf("exp=meta; got=%v", typ) + } + if typ := (&page{flags: freelistPageFlag}).typ(); typ != "freelist" { + t.Fatalf("exp=freelist; got=%v", typ) + } + if typ := (&page{flags: 20000}).typ(); typ != "unknown<4e20>" { + t.Fatalf("exp=unknown<4e20>; got=%v", typ) + } +} + +// Ensure that the hexdump debugging function doesn't blow up. +func TestPage_dump(t *testing.T) { + (&page{id: 256}).hexdump(16) +} + +func TestPgids_merge(t *testing.T) { + a := pgids{4, 5, 6, 10, 11, 12, 13, 27} + b := pgids{1, 3, 8, 9, 25, 30} + c := a.merge(b) + if !reflect.DeepEqual(c, pgids{1, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 25, 27, 30}) { + t.Errorf("mismatch: %v", c) + } + + a = pgids{4, 5, 6, 10, 11, 12, 13, 27, 35, 36} + b = pgids{8, 9, 25, 30} + c = a.merge(b) + if !reflect.DeepEqual(c, pgids{4, 5, 6, 8, 9, 10, 11, 12, 13, 25, 27, 30, 35, 36}) { + t.Errorf("mismatch: %v", c) + } +} + +func TestPgids_merge_quick(t *testing.T) { + if err := quick.Check(func(a, b pgids) bool { + // Sort incoming lists. + sort.Sort(a) + sort.Sort(b) + + // Merge the two lists together. + got := a.merge(b) + + // The expected value should be the two lists combined and sorted. + exp := append(a, b...) + sort.Sort(exp) + + if !reflect.DeepEqual(exp, got) { + t.Errorf("\nexp=%+v\ngot=%+v\n", exp, got) + return false + } + + return true + }, nil); err != nil { + t.Fatal(err) + } +} diff --git a/vendor/etcd.io/bbolt/quick_test.go b/vendor/etcd.io/bbolt/quick_test.go new file mode 100644 index 0000000..da8b2e3 --- /dev/null +++ b/vendor/etcd.io/bbolt/quick_test.go @@ -0,0 +1,90 @@ +package bbolt_test + +import ( + "bytes" + "flag" + "fmt" + "math/rand" + "os" + "reflect" + "testing" + "testing/quick" + "time" +) + +// testing/quick defaults to 5 iterations and a random seed. +// You can override these settings from the command line: +// +// -quick.count The number of iterations to perform. +// -quick.seed The seed to use for randomizing. +// -quick.maxitems The maximum number of items to insert into a DB. +// -quick.maxksize The maximum size of a key. +// -quick.maxvsize The maximum size of a value. +// + +var qcount, qseed, qmaxitems, qmaxksize, qmaxvsize int + +func TestMain(m *testing.M) { + flag.IntVar(&qcount, "quick.count", 5, "") + flag.IntVar(&qseed, "quick.seed", int(time.Now().UnixNano())%100000, "") + flag.IntVar(&qmaxitems, "quick.maxitems", 1000, "") + flag.IntVar(&qmaxksize, "quick.maxksize", 1024, "") + flag.IntVar(&qmaxvsize, "quick.maxvsize", 1024, "") + flag.Parse() + fmt.Fprintln(os.Stderr, "seed:", qseed) + fmt.Fprintf(os.Stderr, "quick settings: count=%v, items=%v, ksize=%v, vsize=%v\n", qcount, qmaxitems, qmaxksize, qmaxvsize) + + m.Run() +} + +func qconfig() *quick.Config { + return &quick.Config{ + MaxCount: qcount, + Rand: rand.New(rand.NewSource(int64(qseed))), + } +} + +type testdata []testdataitem + +func (t testdata) Len() int { return len(t) } +func (t testdata) Swap(i, j int) { t[i], t[j] = t[j], t[i] } +func (t testdata) Less(i, j int) bool { return bytes.Compare(t[i].Key, t[j].Key) == -1 } + +func (t testdata) Generate(rand *rand.Rand, size int) reflect.Value { + n := rand.Intn(qmaxitems-1) + 1 + items := make(testdata, n) + used := make(map[string]bool) + for i := 0; i < n; i++ { + item := &items[i] + // Ensure that keys are unique by looping until we find one that we have not already used. + for { + item.Key = randByteSlice(rand, 1, qmaxksize) + if !used[string(item.Key)] { + used[string(item.Key)] = true + break + } + } + item.Value = randByteSlice(rand, 0, qmaxvsize) + } + return reflect.ValueOf(items) +} + +type revtestdata []testdataitem + +func (t revtestdata) Len() int { return len(t) } +func (t revtestdata) Swap(i, j int) { t[i], t[j] = t[j], t[i] } +func (t revtestdata) Less(i, j int) bool { return bytes.Compare(t[i].Key, t[j].Key) == 1 } + +type testdataitem struct { + Key []byte + Value []byte +} + +func randByteSlice(rand *rand.Rand, minSize, maxSize int) []byte { + n := rand.Intn(maxSize-minSize) + minSize + b := make([]byte, n) + for i := 0; i < n; i++ { + b[i] = byte(rand.Intn(255)) + } + return b +} diff --git a/vendor/etcd.io/bbolt/simulation_no_freelist_sync_test.go b/vendor/etcd.io/bbolt/simulation_no_freelist_sync_test.go new file mode 100644 index 0000000..25c3dfb --- /dev/null +++ b/vendor/etcd.io/bbolt/simulation_no_freelist_sync_test.go @@ -0,0 +1,47 @@ +package bbolt_test + +import ( + "testing" + + bolt "go.etcd.io/bbolt" +) + +func TestSimulateNoFreeListSync_1op_1p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 1, 1) +} +func TestSimulateNoFreeListSync_10op_1p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 10, 1) +} +func TestSimulateNoFreeListSync_100op_1p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 100, 1) +} +func TestSimulateNoFreeListSync_1000op_1p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 1000, 1) +} +func TestSimulateNoFreeListSync_10000op_1p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 10000, 1) +} +func TestSimulateNoFreeListSync_10op_10p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 10, 10) +} +func TestSimulateNoFreeListSync_100op_10p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 100, 10) +} +func TestSimulateNoFreeListSync_1000op_10p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 1000, 10) +} +func TestSimulateNoFreeListSync_10000op_10p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 10000, 10) +} +func TestSimulateNoFreeListSync_100op_100p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 100, 100) +} +func TestSimulateNoFreeListSync_1000op_100p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 1000, 100) +} +func TestSimulateNoFreeListSync_10000op_100p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 10000, 100) +} +func TestSimulateNoFreeListSync_10000op_1000p(t *testing.T) { + testSimulate(t, &bolt.Options{NoFreelistSync: true}, 8, 10000, 1000) +} diff --git a/vendor/etcd.io/bbolt/simulation_test.go b/vendor/etcd.io/bbolt/simulation_test.go new file mode 100644 index 0000000..a96a241 --- /dev/null +++ b/vendor/etcd.io/bbolt/simulation_test.go @@ -0,0 +1,361 @@ +package bbolt_test + +import ( + "bytes" + "fmt" + "math/rand" + "sync" + "sync/atomic" + "testing" + + bolt "go.etcd.io/bbolt" +) + +func TestSimulate_1op_1p(t *testing.T) { testSimulate(t, nil, 1, 1, 1) } +func TestSimulate_10op_1p(t *testing.T) { testSimulate(t, nil, 1, 10, 1) } +func TestSimulate_100op_1p(t *testing.T) { testSimulate(t, nil, 1, 100, 1) } +func TestSimulate_1000op_1p(t *testing.T) { testSimulate(t, nil, 1, 1000, 1) } +func TestSimulate_10000op_1p(t *testing.T) { testSimulate(t, nil, 1, 10000, 1) } + +func TestSimulate_10op_10p(t *testing.T) { testSimulate(t, nil, 1, 10, 10) } +func TestSimulate_100op_10p(t *testing.T) { testSimulate(t, nil, 1, 100, 10) } +func TestSimulate_1000op_10p(t *testing.T) { testSimulate(t, nil, 1, 1000, 10) } +func TestSimulate_10000op_10p(t *testing.T) { testSimulate(t, nil, 1, 10000, 10) } + +func TestSimulate_100op_100p(t *testing.T) { testSimulate(t, nil, 1, 100, 100) } +func TestSimulate_1000op_100p(t *testing.T) { testSimulate(t, nil, 1, 1000, 100) } +func TestSimulate_10000op_100p(t *testing.T) { testSimulate(t, nil, 1, 10000, 100) } + +func TestSimulate_10000op_1000p(t *testing.T) { testSimulate(t, nil, 1, 10000, 1000) } + +// Randomly generate operations on a given database with multiple clients to ensure consistency and thread safety. +func testSimulate(t *testing.T, openOption *bolt.Options, round, threadCount, parallelism int) { + if testing.Short() { + t.Skip("skipping test in short mode.") + } + + rand.Seed(int64(qseed)) + + // A list of operations that readers and writers can perform. + var readerHandlers = []simulateHandler{simulateGetHandler} + var writerHandlers = []simulateHandler{simulateGetHandler, simulatePutHandler} + + var versions = make(map[int]*QuickDB) + versions[1] = NewQuickDB() + + db := MustOpenWithOption(openOption) + defer db.MustClose() + + var mutex sync.Mutex + + for n := 0; n < round; n++ { + // Run n threads in parallel, each with their own operation. + var threads = make(chan bool, parallelism) + var wg sync.WaitGroup + + // counter for how many goroutines were fired + var opCount int64 + + // counter for ignored operations + var igCount int64 + + var errCh = make(chan error, threadCount) + + var i int + for { + // this buffered channel will keep accepting booleans + // until it hits the limit defined by the parallelism + // argument to testSimulate() + threads <- true + + // this wait group can only be marked "done" from inside + // the subsequent goroutine + wg.Add(1) + writable := ((rand.Int() % 100) < 20) // 20% writers + + // Choose an operation to execute. + var handler simulateHandler + if writable { + handler = writerHandlers[rand.Intn(len(writerHandlers))] + } else { + handler = readerHandlers[rand.Intn(len(readerHandlers))] + } + + // Execute a thread for the given operation. + go func(writable bool, handler simulateHandler) { + defer wg.Done() + atomic.AddInt64(&opCount, 1) + // Start transaction. + tx, err := db.Begin(writable) + if err != nil { + errCh <- fmt.Errorf("error tx begin: %v", err) + return + } + + // Obtain current state of the dataset. + mutex.Lock() + var qdb = versions[tx.ID()] + if writable { + qdb = versions[tx.ID()-1].Copy() + } + mutex.Unlock() + + // Make sure we commit/rollback the tx at the end and update the state. + if writable { + defer func() { + mutex.Lock() + versions[tx.ID()] = qdb + mutex.Unlock() + + if err := tx.Commit(); err != nil { + errCh <- err + return + } + }() + } else { + defer func() { _ = tx.Rollback() }() + } + + // Ignore operation if we don't have data yet. + if qdb == nil { + atomic.AddInt64(&igCount, 1) + return + } + + // Execute handler. + handler(tx, qdb) + + // Release a thread back to the scheduling loop. + <-threads + }(writable, handler) + + i++ + if i >= threadCount { + break + } + } + + // Wait until all threads are done. + wg.Wait() + t.Logf("transactions:%d ignored:%d", opCount, igCount) + close(errCh) + for err := range errCh { + if err != nil { + t.Fatalf("error from inside goroutine: %v", err) + } + } + + db.MustClose() + db.MustReopen() + } + +} + +type simulateHandler func(tx *bolt.Tx, qdb *QuickDB) + +// Retrieves a key from the database and verifies that it is what is expected. +func simulateGetHandler(tx *bolt.Tx, qdb *QuickDB) { + // Randomly retrieve an existing exist. + keys := qdb.Rand() + if len(keys) == 0 { + return + } + + // Retrieve root bucket. + b := tx.Bucket(keys[0]) + if b == nil { + panic(fmt.Sprintf("bucket[0] expected: %08x\n", trunc(keys[0], 4))) + } + + // Drill into nested buckets. + for _, key := range keys[1 : len(keys)-1] { + b = b.Bucket(key) + if b == nil { + panic(fmt.Sprintf("bucket[n] expected: %v -> %v\n", keys, key)) + } + } + + // Verify key/value on the final bucket. + expected := qdb.Get(keys) + actual := b.Get(keys[len(keys)-1]) + if !bytes.Equal(actual, expected) { + fmt.Println("=== EXPECTED ===") + fmt.Println(expected) + fmt.Println("=== ACTUAL ===") + fmt.Println(actual) + fmt.Println("=== END ===") + panic("value mismatch") + } +} + +// Inserts a key into the database. +func simulatePutHandler(tx *bolt.Tx, qdb *QuickDB) { + var err error + keys, value := randKeys(), randValue() + + // Retrieve root bucket. + b := tx.Bucket(keys[0]) + if b == nil { + b, err = tx.CreateBucket(keys[0]) + if err != nil { + panic("create bucket: " + err.Error()) + } + } + + // Create nested buckets, if necessary. + for _, key := range keys[1 : len(keys)-1] { + child := b.Bucket(key) + if child != nil { + b = child + } else { + b, err = b.CreateBucket(key) + if err != nil { + panic("create bucket: " + err.Error()) + } + } + } + + // Insert into database. + if err := b.Put(keys[len(keys)-1], value); err != nil { + panic("put: " + err.Error()) + } + + // Insert into in-memory database. + qdb.Put(keys, value) +} + +// QuickDB is an in-memory database that replicates the functionality of the +// Bolt DB type except that it is entirely in-memory. It is meant for testing +// that the Bolt database is consistent. +type QuickDB struct { + sync.RWMutex + m map[string]interface{} +} + +// NewQuickDB returns an instance of QuickDB. +func NewQuickDB() *QuickDB { + return &QuickDB{m: make(map[string]interface{})} +} + +// Get retrieves the value at a key path. +func (db *QuickDB) Get(keys [][]byte) []byte { + db.RLock() + defer db.RUnlock() + + m := db.m + for _, key := range keys[:len(keys)-1] { + value := m[string(key)] + if value == nil { + return nil + } + switch value := value.(type) { + case map[string]interface{}: + m = value + case []byte: + return nil + } + } + + // Only return if it's a simple value. + if value, ok := m[string(keys[len(keys)-1])].([]byte); ok { + return value + } + return nil +} + +// Put inserts a value into a key path. +func (db *QuickDB) Put(keys [][]byte, value []byte) { + db.Lock() + defer db.Unlock() + + // Build buckets all the way down the key path. + m := db.m + for _, key := range keys[:len(keys)-1] { + if _, ok := m[string(key)].([]byte); ok { + return // Keypath intersects with a simple value. Do nothing. + } + + if m[string(key)] == nil { + m[string(key)] = make(map[string]interface{}) + } + m = m[string(key)].(map[string]interface{}) + } + + // Insert value into the last key. + m[string(keys[len(keys)-1])] = value +} + +// Rand returns a random key path that points to a simple value. +func (db *QuickDB) Rand() [][]byte { + db.RLock() + defer db.RUnlock() + if len(db.m) == 0 { + return nil + } + var keys [][]byte + db.rand(db.m, &keys) + return keys +} + +func (db *QuickDB) rand(m map[string]interface{}, keys *[][]byte) { + i, index := 0, rand.Intn(len(m)) + for k, v := range m { + if i == index { + *keys = append(*keys, []byte(k)) + if v, ok := v.(map[string]interface{}); ok { + db.rand(v, keys) + } + return + } + i++ + } + panic("quickdb rand: out-of-range") +} + +// Copy copies the entire database. +func (db *QuickDB) Copy() *QuickDB { + db.RLock() + defer db.RUnlock() + return &QuickDB{m: db.copy(db.m)} +} + +func (db *QuickDB) copy(m map[string]interface{}) map[string]interface{} { + clone := make(map[string]interface{}, len(m)) + for k, v := range m { + switch v := v.(type) { + case map[string]interface{}: + clone[k] = db.copy(v) + default: + clone[k] = v + } + } + return clone +} + +func randKey() []byte { + var min, max = 1, 1024 + n := rand.Intn(max-min) + min + b := make([]byte, n) + for i := 0; i < n; i++ { + b[i] = byte(rand.Intn(255)) + } + return b +} + +func randKeys() [][]byte { + var keys [][]byte + var count = rand.Intn(2) + 2 + for i := 0; i < count; i++ { + keys = append(keys, randKey()) + } + return keys +} + +func randValue() []byte { + n := rand.Intn(8192) + b := make([]byte, n) + for i := 0; i < n; i++ { + b[i] = byte(rand.Intn(255)) + } + return b +} diff --git a/vendor/etcd.io/bbolt/tx.go b/vendor/etcd.io/bbolt/tx.go new file mode 100644 index 0000000..4b1a64a --- /dev/null +++ b/vendor/etcd.io/bbolt/tx.go @@ -0,0 +1,724 @@ +package bbolt + +import ( + "fmt" + "io" + "os" + "sort" + "strings" + "time" + "unsafe" +) + +// txid represents the internal transaction identifier. +type txid uint64 + +// Tx represents a read-only or read/write transaction on the database. +// Read-only transactions can be used for retrieving values for keys and creating cursors. +// Read/write transactions can create and remove buckets and create and remove keys. +// +// IMPORTANT: You must commit or rollback transactions when you are done with +// them. Pages can not be reclaimed by the writer until no more transactions +// are using them. A long running read transaction can cause the database to +// quickly grow. +type Tx struct { + writable bool + managed bool + db *DB + meta *meta + root Bucket + pages map[pgid]*page + stats TxStats + commitHandlers []func() + + // WriteFlag specifies the flag for write-related methods like WriteTo(). + // Tx opens the database file with the specified flag to copy the data. + // + // By default, the flag is unset, which works well for mostly in-memory + // workloads. For databases that are much larger than available RAM, + // set the flag to syscall.O_DIRECT to avoid trashing the page cache. + WriteFlag int +} + +// init initializes the transaction. +func (tx *Tx) init(db *DB) { + tx.db = db + tx.pages = nil + + // Copy the meta page since it can be changed by the writer. + tx.meta = &meta{} + db.meta().copy(tx.meta) + + // Copy over the root bucket. + tx.root = newBucket(tx) + tx.root.bucket = &bucket{} + *tx.root.bucket = tx.meta.root + + // Increment the transaction id and add a page cache for writable transactions. + if tx.writable { + tx.pages = make(map[pgid]*page) + tx.meta.txid += txid(1) + } +} + +// ID returns the transaction id. +func (tx *Tx) ID() int { + return int(tx.meta.txid) +} + +// DB returns a reference to the database that created the transaction. +func (tx *Tx) DB() *DB { + return tx.db +} + +// Size returns current database size in bytes as seen by this transaction. +func (tx *Tx) Size() int64 { + return int64(tx.meta.pgid) * int64(tx.db.pageSize) +} + +// Writable returns whether the transaction can perform write operations. +func (tx *Tx) Writable() bool { + return tx.writable +} + +// Cursor creates a cursor associated with the root bucket. +// All items in the cursor will return a nil value because all root bucket keys point to buckets. +// The cursor is only valid as long as the transaction is open. +// Do not use a cursor after the transaction is closed. +func (tx *Tx) Cursor() *Cursor { + return tx.root.Cursor() +} + +// Stats retrieves a copy of the current transaction statistics. +func (tx *Tx) Stats() TxStats { + return tx.stats +} + +// Bucket retrieves a bucket by name. +// Returns nil if the bucket does not exist. +// The bucket instance is only valid for the lifetime of the transaction. +func (tx *Tx) Bucket(name []byte) *Bucket { + return tx.root.Bucket(name) +} + +// CreateBucket creates a new bucket. +// Returns an error if the bucket already exists, if the bucket name is blank, or if the bucket name is too long. +// The bucket instance is only valid for the lifetime of the transaction. +func (tx *Tx) CreateBucket(name []byte) (*Bucket, error) { + return tx.root.CreateBucket(name) +} + +// CreateBucketIfNotExists creates a new bucket if it doesn't already exist. +// Returns an error if the bucket name is blank, or if the bucket name is too long. +// The bucket instance is only valid for the lifetime of the transaction. +func (tx *Tx) CreateBucketIfNotExists(name []byte) (*Bucket, error) { + return tx.root.CreateBucketIfNotExists(name) +} + +// DeleteBucket deletes a bucket. +// Returns an error if the bucket cannot be found or if the key represents a non-bucket value. +func (tx *Tx) DeleteBucket(name []byte) error { + return tx.root.DeleteBucket(name) +} + +// ForEach executes a function for each bucket in the root. +// If the provided function returns an error then the iteration is stopped and +// the error is returned to the caller. +func (tx *Tx) ForEach(fn func(name []byte, b *Bucket) error) error { + return tx.root.ForEach(func(k, v []byte) error { + return fn(k, tx.root.Bucket(k)) + }) +} + +// OnCommit adds a handler function to be executed after the transaction successfully commits. +func (tx *Tx) OnCommit(fn func()) { + tx.commitHandlers = append(tx.commitHandlers, fn) +} + +// Commit writes all changes to disk and updates the meta page. +// Returns an error if a disk write error occurs, or if Commit is +// called on a read-only transaction. +func (tx *Tx) Commit() error { + _assert(!tx.managed, "managed tx commit not allowed") + if tx.db == nil { + return ErrTxClosed + } else if !tx.writable { + return ErrTxNotWritable + } + + // TODO(benbjohnson): Use vectorized I/O to write out dirty pages. + + // Rebalance nodes which have had deletions. + var startTime = time.Now() + tx.root.rebalance() + if tx.stats.Rebalance > 0 { + tx.stats.RebalanceTime += time.Since(startTime) + } + + // spill data onto dirty pages. + startTime = time.Now() + if err := tx.root.spill(); err != nil { + tx.rollback() + return err + } + tx.stats.SpillTime += time.Since(startTime) + + // Free the old root bucket. + tx.meta.root.root = tx.root.root + + // Free the old freelist because commit writes out a fresh freelist. + if tx.meta.freelist != pgidNoFreelist { + tx.db.freelist.free(tx.meta.txid, tx.db.page(tx.meta.freelist)) + } + + if !tx.db.NoFreelistSync { + err := tx.commitFreelist() + if err != nil { + return err + } + } else { + tx.meta.freelist = pgidNoFreelist + } + + // Write dirty pages to disk. + startTime = time.Now() + if err := tx.write(); err != nil { + tx.rollback() + return err + } + + // If strict mode is enabled then perform a consistency check. + // Only the first consistency error is reported in the panic. + if tx.db.StrictMode { + ch := tx.Check() + var errs []string + for { + err, ok := <-ch + if !ok { + break + } + errs = append(errs, err.Error()) + } + if len(errs) > 0 { + panic("check fail: " + strings.Join(errs, "\n")) + } + } + + // Write meta to disk. + if err := tx.writeMeta(); err != nil { + tx.rollback() + return err + } + tx.stats.WriteTime += time.Since(startTime) + + // Finalize the transaction. + tx.close() + + // Execute commit handlers now that the locks have been removed. + for _, fn := range tx.commitHandlers { + fn() + } + + return nil +} + +func (tx *Tx) commitFreelist() error { + // Allocate new pages for the new free list. This will overestimate + // the size of the freelist but not underestimate the size (which would be bad). + opgid := tx.meta.pgid + p, err := tx.allocate((tx.db.freelist.size() / tx.db.pageSize) + 1) + if err != nil { + tx.rollback() + return err + } + if err := tx.db.freelist.write(p); err != nil { + tx.rollback() + return err + } + tx.meta.freelist = p.id + // If the high water mark has moved up then attempt to grow the database. + if tx.meta.pgid > opgid { + if err := tx.db.grow(int(tx.meta.pgid+1) * tx.db.pageSize); err != nil { + tx.rollback() + return err + } + } + + return nil +} + +// Rollback closes the transaction and ignores all previous updates. Read-only +// transactions must be rolled back and not committed. +func (tx *Tx) Rollback() error { + _assert(!tx.managed, "managed tx rollback not allowed") + if tx.db == nil { + return ErrTxClosed + } + tx.nonPhysicalRollback() + return nil +} + +// nonPhysicalRollback is called when user calls Rollback directly, in this case we do not need to reload the free pages from disk. +func (tx *Tx) nonPhysicalRollback() { + if tx.db == nil { + return + } + if tx.writable { + tx.db.freelist.rollback(tx.meta.txid) + } + tx.close() +} + +// rollback needs to reload the free pages from disk in case some system error happens like fsync error. +func (tx *Tx) rollback() { + if tx.db == nil { + return + } + if tx.writable { + tx.db.freelist.rollback(tx.meta.txid) + if !tx.db.hasSyncedFreelist() { + // Reconstruct free page list by scanning the DB to get the whole free page list. + // Note: scaning the whole db is heavy if your db size is large in NoSyncFreeList mode. + tx.db.freelist.noSyncReload(tx.db.freepages()) + } else { + // Read free page list from freelist page. + tx.db.freelist.reload(tx.db.page(tx.db.meta().freelist)) + } + } + tx.close() +} + +func (tx *Tx) close() { + if tx.db == nil { + return + } + if tx.writable { + // Grab freelist stats. + var freelistFreeN = tx.db.freelist.free_count() + var freelistPendingN = tx.db.freelist.pending_count() + var freelistAlloc = tx.db.freelist.size() + + // Remove transaction ref & writer lock. + tx.db.rwtx = nil + tx.db.rwlock.Unlock() + + // Merge statistics. + tx.db.statlock.Lock() + tx.db.stats.FreePageN = freelistFreeN + tx.db.stats.PendingPageN = freelistPendingN + tx.db.stats.FreeAlloc = (freelistFreeN + freelistPendingN) * tx.db.pageSize + tx.db.stats.FreelistInuse = freelistAlloc + tx.db.stats.TxStats.add(&tx.stats) + tx.db.statlock.Unlock() + } else { + tx.db.removeTx(tx) + } + + // Clear all references. + tx.db = nil + tx.meta = nil + tx.root = Bucket{tx: tx} + tx.pages = nil +} + +// Copy writes the entire database to a writer. +// This function exists for backwards compatibility. +// +// Deprecated; Use WriteTo() instead. +func (tx *Tx) Copy(w io.Writer) error { + _, err := tx.WriteTo(w) + return err +} + +// WriteTo writes the entire database to a writer. +// If err == nil then exactly tx.Size() bytes will be written into the writer. +func (tx *Tx) WriteTo(w io.Writer) (n int64, err error) { + // Attempt to open reader with WriteFlag + f, err := tx.db.openFile(tx.db.path, os.O_RDONLY|tx.WriteFlag, 0) + if err != nil { + return 0, err + } + defer func() { + if cerr := f.Close(); err == nil { + err = cerr + } + }() + + // Generate a meta page. We use the same page data for both meta pages. + buf := make([]byte, tx.db.pageSize) + page := (*page)(unsafe.Pointer(&buf[0])) + page.flags = metaPageFlag + *page.meta() = *tx.meta + + // Write meta 0. + page.id = 0 + page.meta().checksum = page.meta().sum64() + nn, err := w.Write(buf) + n += int64(nn) + if err != nil { + return n, fmt.Errorf("meta 0 copy: %s", err) + } + + // Write meta 1 with a lower transaction id. + page.id = 1 + page.meta().txid -= 1 + page.meta().checksum = page.meta().sum64() + nn, err = w.Write(buf) + n += int64(nn) + if err != nil { + return n, fmt.Errorf("meta 1 copy: %s", err) + } + + // Move past the meta pages in the file. + if _, err := f.Seek(int64(tx.db.pageSize*2), io.SeekStart); err != nil { + return n, fmt.Errorf("seek: %s", err) + } + + // Copy data pages. + wn, err := io.CopyN(w, f, tx.Size()-int64(tx.db.pageSize*2)) + n += wn + if err != nil { + return n, err + } + + return n, nil +} + +// CopyFile copies the entire database to file at the given path. +// A reader transaction is maintained during the copy so it is safe to continue +// using the database while a copy is in progress. +func (tx *Tx) CopyFile(path string, mode os.FileMode) error { + f, err := tx.db.openFile(path, os.O_RDWR|os.O_CREATE|os.O_TRUNC, mode) + if err != nil { + return err + } + + err = tx.Copy(f) + if err != nil { + _ = f.Close() + return err + } + return f.Close() +} + +// Check performs several consistency checks on the database for this transaction. +// An error is returned if any inconsistency is found. +// +// It can be safely run concurrently on a writable transaction. However, this +// incurs a high cost for large databases and databases with a lot of subbuckets +// because of caching. This overhead can be removed if running on a read-only +// transaction, however, it is not safe to execute other writer transactions at +// the same time. +func (tx *Tx) Check() <-chan error { + ch := make(chan error) + go tx.check(ch) + return ch +} + +func (tx *Tx) check(ch chan error) { + // Force loading free list if opened in ReadOnly mode. + tx.db.loadFreelist() + + // Check if any pages are double freed. + freed := make(map[pgid]bool) + all := make([]pgid, tx.db.freelist.count()) + tx.db.freelist.copyall(all) + for _, id := range all { + if freed[id] { + ch <- fmt.Errorf("page %d: already freed", id) + } + freed[id] = true + } + + // Track every reachable page. + reachable := make(map[pgid]*page) + reachable[0] = tx.page(0) // meta0 + reachable[1] = tx.page(1) // meta1 + if tx.meta.freelist != pgidNoFreelist { + for i := uint32(0); i <= tx.page(tx.meta.freelist).overflow; i++ { + reachable[tx.meta.freelist+pgid(i)] = tx.page(tx.meta.freelist) + } + } + + // Recursively check buckets. + tx.checkBucket(&tx.root, reachable, freed, ch) + + // Ensure all pages below high water mark are either reachable or freed. + for i := pgid(0); i < tx.meta.pgid; i++ { + _, isReachable := reachable[i] + if !isReachable && !freed[i] { + ch <- fmt.Errorf("page %d: unreachable unfreed", int(i)) + } + } + + // Close the channel to signal completion. + close(ch) +} + +func (tx *Tx) checkBucket(b *Bucket, reachable map[pgid]*page, freed map[pgid]bool, ch chan error) { + // Ignore inline buckets. + if b.root == 0 { + return + } + + // Check every page used by this bucket. + b.tx.forEachPage(b.root, 0, func(p *page, _ int) { + if p.id > tx.meta.pgid { + ch <- fmt.Errorf("page %d: out of bounds: %d", int(p.id), int(b.tx.meta.pgid)) + } + + // Ensure each page is only referenced once. + for i := pgid(0); i <= pgid(p.overflow); i++ { + var id = p.id + i + if _, ok := reachable[id]; ok { + ch <- fmt.Errorf("page %d: multiple references", int(id)) + } + reachable[id] = p + } + + // We should only encounter un-freed leaf and branch pages. + if freed[p.id] { + ch <- fmt.Errorf("page %d: reachable freed", int(p.id)) + } else if (p.flags&branchPageFlag) == 0 && (p.flags&leafPageFlag) == 0 { + ch <- fmt.Errorf("page %d: invalid type: %s", int(p.id), p.typ()) + } + }) + + // Check each bucket within this bucket. + _ = b.ForEach(func(k, v []byte) error { + if child := b.Bucket(k); child != nil { + tx.checkBucket(child, reachable, freed, ch) + } + return nil + }) +} + +// allocate returns a contiguous block of memory starting at a given page. +func (tx *Tx) allocate(count int) (*page, error) { + p, err := tx.db.allocate(tx.meta.txid, count) + if err != nil { + return nil, err + } + + // Save to our page cache. + tx.pages[p.id] = p + + // Update statistics. + tx.stats.PageCount += count + tx.stats.PageAlloc += count * tx.db.pageSize + + return p, nil +} + +// write writes any dirty pages to disk. +func (tx *Tx) write() error { + // Sort pages by id. + pages := make(pages, 0, len(tx.pages)) + for _, p := range tx.pages { + pages = append(pages, p) + } + // Clear out page cache early. + tx.pages = make(map[pgid]*page) + sort.Sort(pages) + + // Write pages to disk in order. + for _, p := range pages { + rem := (uint64(p.overflow) + 1) * uint64(tx.db.pageSize) + offset := int64(p.id) * int64(tx.db.pageSize) + var written uintptr + + // Write out page in "max allocation" sized chunks. + for { + sz := rem + if sz > maxAllocSize-1 { + sz = maxAllocSize - 1 + } + buf := unsafeByteSlice(unsafe.Pointer(p), written, 0, int(sz)) + + if _, err := tx.db.ops.writeAt(buf, offset); err != nil { + return err + } + + // Update statistics. + tx.stats.Write++ + + // Exit inner for loop if we've written all the chunks. + rem -= sz + if rem == 0 { + break + } + + // Otherwise move offset forward and move pointer to next chunk. + offset += int64(sz) + written += uintptr(sz) + } + } + + // Ignore file sync if flag is set on DB. + if !tx.db.NoSync || IgnoreNoSync { + if err := fdatasync(tx.db); err != nil { + return err + } + } + + // Put small pages back to page pool. + for _, p := range pages { + // Ignore page sizes over 1 page. + // These are allocated using make() instead of the page pool. + if int(p.overflow) != 0 { + continue + } + + buf := unsafeByteSlice(unsafe.Pointer(p), 0, 0, tx.db.pageSize) + + // See https://go.googlesource.com/go/+/f03c9202c43e0abb130669852082117ca50aa9b1 + for i := range buf { + buf[i] = 0 + } + tx.db.pagePool.Put(buf) + } + + return nil +} + +// writeMeta writes the meta to the disk. +func (tx *Tx) writeMeta() error { + // Create a temporary buffer for the meta page. + buf := make([]byte, tx.db.pageSize) + p := tx.db.pageInBuffer(buf, 0) + tx.meta.write(p) + + // Write the meta page to file. + if _, err := tx.db.ops.writeAt(buf, int64(p.id)*int64(tx.db.pageSize)); err != nil { + return err + } + if !tx.db.NoSync || IgnoreNoSync { + if err := fdatasync(tx.db); err != nil { + return err + } + } + + // Update statistics. + tx.stats.Write++ + + return nil +} + +// page returns a reference to the page with a given id. +// If page has been written to then a temporary buffered page is returned. +func (tx *Tx) page(id pgid) *page { + // Check the dirty pages first. + if tx.pages != nil { + if p, ok := tx.pages[id]; ok { + return p + } + } + + // Otherwise return directly from the mmap. + return tx.db.page(id) +} + +// forEachPage iterates over every page within a given page and executes a function. +func (tx *Tx) forEachPage(pgid pgid, depth int, fn func(*page, int)) { + p := tx.page(pgid) + + // Execute function. + fn(p, depth) + + // Recursively loop over children. + if (p.flags & branchPageFlag) != 0 { + for i := 0; i < int(p.count); i++ { + elem := p.branchPageElement(uint16(i)) + tx.forEachPage(elem.pgid, depth+1, fn) + } + } +} + +// Page returns page information for a given page number. +// This is only safe for concurrent use when used by a writable transaction. +func (tx *Tx) Page(id int) (*PageInfo, error) { + if tx.db == nil { + return nil, ErrTxClosed + } else if pgid(id) >= tx.meta.pgid { + return nil, nil + } + + // Build the page info. + p := tx.db.page(pgid(id)) + info := &PageInfo{ + ID: id, + Count: int(p.count), + OverflowCount: int(p.overflow), + } + + // Determine the type (or if it's free). + if tx.db.freelist.freed(pgid(id)) { + info.Type = "free" + } else { + info.Type = p.typ() + } + + return info, nil +} + +// TxStats represents statistics about the actions performed by the transaction. +type TxStats struct { + // Page statistics. + PageCount int // number of page allocations + PageAlloc int // total bytes allocated + + // Cursor statistics. + CursorCount int // number of cursors created + + // Node statistics + NodeCount int // number of node allocations + NodeDeref int // number of node dereferences + + // Rebalance statistics. + Rebalance int // number of node rebalances + RebalanceTime time.Duration // total time spent rebalancing + + // Split/Spill statistics. + Split int // number of nodes split + Spill int // number of nodes spilled + SpillTime time.Duration // total time spent spilling + + // Write statistics. + Write int // number of writes performed + WriteTime time.Duration // total time spent writing to disk +} + +func (s *TxStats) add(other *TxStats) { + s.PageCount += other.PageCount + s.PageAlloc += other.PageAlloc + s.CursorCount += other.CursorCount + s.NodeCount += other.NodeCount + s.NodeDeref += other.NodeDeref + s.Rebalance += other.Rebalance + s.RebalanceTime += other.RebalanceTime + s.Split += other.Split + s.Spill += other.Spill + s.SpillTime += other.SpillTime + s.Write += other.Write + s.WriteTime += other.WriteTime +} + +// Sub calculates and returns the difference between two sets of transaction stats. +// This is useful when obtaining stats at two different points and time and +// you need the performance counters that occurred within that time span. +func (s *TxStats) Sub(other *TxStats) TxStats { + var diff TxStats + diff.PageCount = s.PageCount - other.PageCount + diff.PageAlloc = s.PageAlloc - other.PageAlloc + diff.CursorCount = s.CursorCount - other.CursorCount + diff.NodeCount = s.NodeCount - other.NodeCount + diff.NodeDeref = s.NodeDeref - other.NodeDeref + diff.Rebalance = s.Rebalance - other.Rebalance + diff.RebalanceTime = s.RebalanceTime - other.RebalanceTime + diff.Split = s.Split - other.Split + diff.Spill = s.Spill - other.Spill + diff.SpillTime = s.SpillTime - other.SpillTime + diff.Write = s.Write - other.Write + diff.WriteTime = s.WriteTime - other.WriteTime + return diff +} diff --git a/vendor/etcd.io/bbolt/tx_test.go b/vendor/etcd.io/bbolt/tx_test.go new file mode 100644 index 0000000..38a25c6 --- /dev/null +++ b/vendor/etcd.io/bbolt/tx_test.go @@ -0,0 +1,924 @@ +package bbolt_test + +import ( + "bytes" + "errors" + "fmt" + "log" + "os" + "testing" + + bolt "go.etcd.io/bbolt" +) + +// TestTx_Check_ReadOnly tests consistency checking on a ReadOnly database. +func TestTx_Check_ReadOnly(t *testing.T) { + db := MustOpenDB() + defer db.Close() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + if err := db.DB.Close(); err != nil { + t.Fatal(err) + } + + readOnlyDB, err := bolt.Open(db.f, 0666, &bolt.Options{ReadOnly: true}) + if err != nil { + t.Fatal(err) + } + defer readOnlyDB.Close() + + tx, err := readOnlyDB.Begin(false) + if err != nil { + t.Fatal(err) + } + // ReadOnly DB will load freelist on Check call. + numChecks := 2 + errc := make(chan error, numChecks) + check := func() { + err, _ := <-tx.Check() + errc <- err + } + // Ensure the freelist is not reloaded and does not race. + for i := 0; i < numChecks; i++ { + go check() + } + for i := 0; i < numChecks; i++ { + if err := <-errc; err != nil { + t.Fatal(err) + } + } + // Close the view transaction + tx.Rollback() +} + +// Ensure that committing a closed transaction returns an error. +func TestTx_Commit_ErrTxClosed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + + if _, err := tx.CreateBucket([]byte("foo")); err != nil { + t.Fatal(err) + } + + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + + if err := tx.Commit(); err != bolt.ErrTxClosed { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that rolling back a closed transaction returns an error. +func TestTx_Rollback_ErrTxClosed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + + if err := tx.Rollback(); err != nil { + t.Fatal(err) + } + if err := tx.Rollback(); err != bolt.ErrTxClosed { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that committing a read-only transaction returns an error. +func TestTx_Commit_ErrTxNotWritable(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + tx, err := db.Begin(false) + if err != nil { + t.Fatal(err) + } + if err := tx.Commit(); err != bolt.ErrTxNotWritable { + t.Fatal(err) + } + // Close the view transaction + tx.Rollback() +} + +// Ensure that a transaction can retrieve a cursor on the root bucket. +func TestTx_Cursor(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + + if _, err := tx.CreateBucket([]byte("woojits")); err != nil { + t.Fatal(err) + } + + c := tx.Cursor() + if k, v := c.First(); !bytes.Equal(k, []byte("widgets")) { + t.Fatalf("unexpected key: %v", k) + } else if v != nil { + t.Fatalf("unexpected value: %v", v) + } + + if k, v := c.Next(); !bytes.Equal(k, []byte("woojits")) { + t.Fatalf("unexpected key: %v", k) + } else if v != nil { + t.Fatalf("unexpected value: %v", v) + } + + if k, v := c.Next(); k != nil { + t.Fatalf("unexpected key: %v", k) + } else if v != nil { + t.Fatalf("unexpected value: %v", k) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that creating a bucket with a read-only transaction returns an error. +func TestTx_CreateBucket_ErrTxNotWritable(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.View(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("foo")) + if err != bolt.ErrTxNotWritable { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that creating a bucket on a closed transaction returns an error. +func TestTx_CreateBucket_ErrTxClosed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + + if _, err := tx.CreateBucket([]byte("foo")); err != bolt.ErrTxClosed { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that a Tx can retrieve a bucket. +func TestTx_Bucket(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + if tx.Bucket([]byte("widgets")) == nil { + t.Fatal("expected bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a Tx retrieving a non-existent key returns nil. +func TestTx_Get_NotFound(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if b.Get([]byte("no_such_key")) != nil { + t.Fatal("expected nil value") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can be created and retrieved. +func TestTx_CreateBucket(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + // Create a bucket. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } else if b == nil { + t.Fatal("expected bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Read the bucket through a separate transaction. + if err := db.View(func(tx *bolt.Tx) error { + if tx.Bucket([]byte("widgets")) == nil { + t.Fatal("expected bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can be created if it doesn't already exist. +func TestTx_CreateBucketIfNotExists(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + // Create bucket. + if b, err := tx.CreateBucketIfNotExists([]byte("widgets")); err != nil { + t.Fatal(err) + } else if b == nil { + t.Fatal("expected bucket") + } + + // Create bucket again. + if b, err := tx.CreateBucketIfNotExists([]byte("widgets")); err != nil { + t.Fatal(err) + } else if b == nil { + t.Fatal("expected bucket") + } + + return nil + }); err != nil { + t.Fatal(err) + } + + // Read the bucket through a separate transaction. + if err := db.View(func(tx *bolt.Tx) error { + if tx.Bucket([]byte("widgets")) == nil { + t.Fatal("expected bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure transaction returns an error if creating an unnamed bucket. +func TestTx_CreateBucketIfNotExists_ErrBucketNameRequired(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucketIfNotExists([]byte{}); err != bolt.ErrBucketNameRequired { + t.Fatalf("unexpected error: %s", err) + } + + if _, err := tx.CreateBucketIfNotExists(nil); err != bolt.ErrBucketNameRequired { + t.Fatalf("unexpected error: %s", err) + } + + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket cannot be created twice. +func TestTx_CreateBucket_ErrBucketExists(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + // Create a bucket. + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Create the same bucket again. + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket([]byte("widgets")); err != bolt.ErrBucketExists { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket is created with a non-blank name. +func TestTx_CreateBucket_ErrBucketNameRequired(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + if _, err := tx.CreateBucket(nil); err != bolt.ErrBucketNameRequired { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that a bucket can be deleted. +func TestTx_DeleteBucket(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + // Create a bucket and add a value. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + // Delete the bucket and make sure we can't get the value. + if err := db.Update(func(tx *bolt.Tx) error { + if err := tx.DeleteBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + if tx.Bucket([]byte("widgets")) != nil { + t.Fatal("unexpected bucket") + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.Update(func(tx *bolt.Tx) error { + // Create the bucket again and make sure there's not a phantom value. + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if v := b.Get([]byte("foo")); v != nil { + t.Fatalf("unexpected phantom value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that deleting a bucket on a closed transaction returns an error. +func TestTx_DeleteBucket_ErrTxClosed(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + tx, err := db.Begin(true) + if err != nil { + t.Fatal(err) + } + if err := tx.Commit(); err != nil { + t.Fatal(err) + } + if err := tx.DeleteBucket([]byte("foo")); err != bolt.ErrTxClosed { + t.Fatalf("unexpected error: %s", err) + } +} + +// Ensure that deleting a bucket with a read-only transaction returns an error. +func TestTx_DeleteBucket_ReadOnly(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.View(func(tx *bolt.Tx) error { + if err := tx.DeleteBucket([]byte("foo")); err != bolt.ErrTxNotWritable { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that nothing happens when deleting a bucket that doesn't exist. +func TestTx_DeleteBucket_NotFound(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + if err := tx.DeleteBucket([]byte("widgets")); err != bolt.ErrBucketNotFound { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that no error is returned when a tx.ForEach function does not return +// an error. +func TestTx_ForEach_NoError(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + + if err := tx.ForEach(func(name []byte, b *bolt.Bucket) error { + return nil + }); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that an error is returned when a tx.ForEach function returns an error. +func TestTx_ForEach_WithError(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + + marker := errors.New("marker") + if err := tx.ForEach(func(name []byte, b *bolt.Bucket) error { + return marker + }); err != marker { + t.Fatalf("unexpected error: %s", err) + } + return nil + }); err != nil { + t.Fatal(err) + } +} + +// Ensure that Tx commit handlers are called after a transaction successfully commits. +func TestTx_OnCommit(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var x int + if err := db.Update(func(tx *bolt.Tx) error { + tx.OnCommit(func() { x += 1 }) + tx.OnCommit(func() { x += 2 }) + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } else if x != 3 { + t.Fatalf("unexpected x: %d", x) + } +} + +// Ensure that Tx commit handlers are NOT called after a transaction rolls back. +func TestTx_OnCommit_Rollback(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + var x int + if err := db.Update(func(tx *bolt.Tx) error { + tx.OnCommit(func() { x += 1 }) + tx.OnCommit(func() { x += 2 }) + if _, err := tx.CreateBucket([]byte("widgets")); err != nil { + t.Fatal(err) + } + return errors.New("rollback this commit") + }); err == nil || err.Error() != "rollback this commit" { + t.Fatalf("unexpected error: %s", err) + } else if x != 0 { + t.Fatalf("unexpected x: %d", x) + } +} + +// Ensure that the database can be copied to a file path. +func TestTx_CopyFile(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + + path := tempfile() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte("bat")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + return tx.CopyFile(path, 0600) + }); err != nil { + t.Fatal(err) + } + + db2, err := bolt.Open(path, 0600, nil) + if err != nil { + t.Fatal(err) + } + + if err := db2.View(func(tx *bolt.Tx) error { + if v := tx.Bucket([]byte("widgets")).Get([]byte("foo")); !bytes.Equal(v, []byte("bar")) { + t.Fatalf("unexpected value: %v", v) + } + if v := tx.Bucket([]byte("widgets")).Get([]byte("baz")); !bytes.Equal(v, []byte("bat")) { + t.Fatalf("unexpected value: %v", v) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db2.Close(); err != nil { + t.Fatal(err) + } +} + +type failWriterError struct{} + +func (failWriterError) Error() string { + return "error injected for tests" +} + +type failWriter struct { + // fail after this many bytes + After int +} + +func (f *failWriter) Write(p []byte) (n int, err error) { + n = len(p) + if n > f.After { + n = f.After + err = failWriterError{} + } + f.After -= n + return n, err +} + +// Ensure that Copy handles write errors right. +func TestTx_CopyFile_Error_Meta(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte("bat")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + return tx.Copy(&failWriter{}) + }); err == nil || err.Error() != "meta 0 copy: error injected for tests" { + t.Fatalf("unexpected error: %v", err) + } +} + +// Ensure that Copy handles write errors right. +func TestTx_CopyFile_Error_Normal(t *testing.T) { + db := MustOpenDB() + defer db.MustClose() + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + t.Fatal(err) + } + if err := b.Put([]byte("baz"), []byte("bat")); err != nil { + t.Fatal(err) + } + return nil + }); err != nil { + t.Fatal(err) + } + + if err := db.View(func(tx *bolt.Tx) error { + return tx.Copy(&failWriter{3 * db.Info().PageSize}) + }); err == nil || err.Error() != "error injected for tests" { + t.Fatalf("unexpected error: %v", err) + } +} + +// TestTx_Rollback ensures there is no error when tx rollback whether we sync freelist or not. +func TestTx_Rollback(t *testing.T) { + for _, isSyncFreelist := range []bool{false, true} { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + db.NoFreelistSync = isSyncFreelist + + tx, err := db.Begin(true) + if err != nil { + t.Fatalf("Error starting tx: %v", err) + } + bucket := []byte("mybucket") + if _, err := tx.CreateBucket(bucket); err != nil { + t.Fatalf("Error creating bucket: %v", err) + } + if err := tx.Commit(); err != nil { + t.Fatalf("Error on commit: %v", err) + } + + tx, err = db.Begin(true) + if err != nil { + t.Fatalf("Error starting tx: %v", err) + } + b := tx.Bucket(bucket) + if err := b.Put([]byte("k"), []byte("v")); err != nil { + t.Fatalf("Error on put: %v", err) + } + // Imagine there is an error and tx needs to be rolled-back + if err := tx.Rollback(); err != nil { + t.Fatalf("Error on rollback: %v", err) + } + + tx, err = db.Begin(false) + if err != nil { + t.Fatalf("Error starting tx: %v", err) + } + b = tx.Bucket(bucket) + if v := b.Get([]byte("k")); v != nil { + t.Fatalf("Value for k should not have been stored") + } + if err := tx.Rollback(); err != nil { + t.Fatalf("Error on rollback: %v", err) + } + + } +} + +// TestTx_releaseRange ensures db.freePages handles page releases +// correctly when there are transaction that are no longer reachable +// via any read/write transactions and are "between" ongoing read +// transactions, which requires they must be freed by +// freelist.releaseRange. +func TestTx_releaseRange(t *testing.T) { + // Set initial mmap size well beyond the limit we will hit in this + // test, since we are testing with long running read transactions + // and will deadlock if db.grow is triggered. + db := MustOpenWithOption(&bolt.Options{InitialMmapSize: os.Getpagesize() * 100}) + defer db.MustClose() + + bucket := "bucket" + + put := func(key, value string) { + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte(bucket)) + if err != nil { + t.Fatal(err) + } + return b.Put([]byte(key), []byte(value)) + }); err != nil { + t.Fatal(err) + } + } + + del := func(key string) { + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucketIfNotExists([]byte(bucket)) + if err != nil { + t.Fatal(err) + } + return b.Delete([]byte(key)) + }); err != nil { + t.Fatal(err) + } + } + + getWithTxn := func(txn *bolt.Tx, key string) []byte { + return txn.Bucket([]byte(bucket)).Get([]byte(key)) + } + + openReadTxn := func() *bolt.Tx { + readTx, err := db.Begin(false) + if err != nil { + t.Fatal(err) + } + return readTx + } + + checkWithReadTxn := func(txn *bolt.Tx, key string, wantValue []byte) { + value := getWithTxn(txn, key) + if !bytes.Equal(value, wantValue) { + t.Errorf("Wanted value to be %s for key %s, but got %s", wantValue, key, string(value)) + } + } + + rollback := func(txn *bolt.Tx) { + if err := txn.Rollback(); err != nil { + t.Fatal(err) + } + } + + put("k1", "v1") + rtx1 := openReadTxn() + put("k2", "v2") + hold1 := openReadTxn() + put("k3", "v3") + hold2 := openReadTxn() + del("k3") + rtx2 := openReadTxn() + del("k1") + hold3 := openReadTxn() + del("k2") + hold4 := openReadTxn() + put("k4", "v4") + hold5 := openReadTxn() + + // Close the read transactions we established to hold a portion of the pages in pending state. + rollback(hold1) + rollback(hold2) + rollback(hold3) + rollback(hold4) + rollback(hold5) + + // Execute a write transaction to trigger a releaseRange operation in the db + // that will free multiple ranges between the remaining open read transactions, now that the + // holds have been rolled back. + put("k4", "v4") + + // Check that all long running reads still read correct values. + checkWithReadTxn(rtx1, "k1", []byte("v1")) + checkWithReadTxn(rtx2, "k2", []byte("v2")) + rollback(rtx1) + rollback(rtx2) + + // Check that the final state is correct. + rtx7 := openReadTxn() + checkWithReadTxn(rtx7, "k1", nil) + checkWithReadTxn(rtx7, "k2", nil) + checkWithReadTxn(rtx7, "k3", nil) + checkWithReadTxn(rtx7, "k4", []byte("v4")) + rollback(rtx7) +} + +func ExampleTx_Rollback() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Create a bucket. + if err := db.Update(func(tx *bolt.Tx) error { + _, err := tx.CreateBucket([]byte("widgets")) + return err + }); err != nil { + log.Fatal(err) + } + + // Set a value for a key. + if err := db.Update(func(tx *bolt.Tx) error { + return tx.Bucket([]byte("widgets")).Put([]byte("foo"), []byte("bar")) + }); err != nil { + log.Fatal(err) + } + + // Update the key but rollback the transaction so it never saves. + tx, err := db.Begin(true) + if err != nil { + log.Fatal(err) + } + b := tx.Bucket([]byte("widgets")) + if err := b.Put([]byte("foo"), []byte("baz")); err != nil { + log.Fatal(err) + } + if err := tx.Rollback(); err != nil { + log.Fatal(err) + } + + // Ensure that our original value is still set. + if err := db.View(func(tx *bolt.Tx) error { + value := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + fmt.Printf("The value for 'foo' is still: %s\n", value) + return nil + }); err != nil { + log.Fatal(err) + } + + // Close database to release file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // The value for 'foo' is still: bar +} + +func ExampleTx_CopyFile() { + // Open the database. + db, err := bolt.Open(tempfile(), 0666, nil) + if err != nil { + log.Fatal(err) + } + defer os.Remove(db.Path()) + + // Create a bucket and a key. + if err := db.Update(func(tx *bolt.Tx) error { + b, err := tx.CreateBucket([]byte("widgets")) + if err != nil { + return err + } + if err := b.Put([]byte("foo"), []byte("bar")); err != nil { + return err + } + return nil + }); err != nil { + log.Fatal(err) + } + + // Copy the database to another file. + toFile := tempfile() + if err := db.View(func(tx *bolt.Tx) error { + return tx.CopyFile(toFile, 0666) + }); err != nil { + log.Fatal(err) + } + defer os.Remove(toFile) + + // Open the cloned database. + db2, err := bolt.Open(toFile, 0666, nil) + if err != nil { + log.Fatal(err) + } + + // Ensure that the key exists in the copy. + if err := db2.View(func(tx *bolt.Tx) error { + value := tx.Bucket([]byte("widgets")).Get([]byte("foo")) + fmt.Printf("The value for 'foo' in the clone is: %s\n", value) + return nil + }); err != nil { + log.Fatal(err) + } + + // Close database to release file lock. + if err := db.Close(); err != nil { + log.Fatal(err) + } + + if err := db2.Close(); err != nil { + log.Fatal(err) + } + + // Output: + // The value for 'foo' in the clone is: bar +} diff --git a/vendor/etcd.io/bbolt/unsafe.go b/vendor/etcd.io/bbolt/unsafe.go new file mode 100644 index 0000000..c0e5037 --- /dev/null +++ b/vendor/etcd.io/bbolt/unsafe.go @@ -0,0 +1,39 @@ +package bbolt + +import ( + "reflect" + "unsafe" +) + +func unsafeAdd(base unsafe.Pointer, offset uintptr) unsafe.Pointer { + return unsafe.Pointer(uintptr(base) + offset) +} + +func unsafeIndex(base unsafe.Pointer, offset uintptr, elemsz uintptr, n int) unsafe.Pointer { + return unsafe.Pointer(uintptr(base) + offset + uintptr(n)*elemsz) +} + +func unsafeByteSlice(base unsafe.Pointer, offset uintptr, i, j int) []byte { + // See: https://github.com/golang/go/wiki/cgo#turning-c-arrays-into-go-slices + // + // This memory is not allocated from C, but it is unmanaged by Go's + // garbage collector and should behave similarly, and the compiler + // should produce similar code. Note that this conversion allows a + // subslice to begin after the base address, with an optional offset, + // while the URL above does not cover this case and only slices from + // index 0. However, the wiki never says that the address must be to + // the beginning of a C allocation (or even that malloc was used at + // all), so this is believed to be correct. + return (*[maxAllocSize]byte)(unsafeAdd(base, offset))[i:j:j] +} + +// unsafeSlice modifies the data, len, and cap of a slice variable pointed to by +// the slice parameter. This helper should be used over other direct +// manipulation of reflect.SliceHeader to prevent misuse, namely, converting +// from reflect.SliceHeader to a Go slice type. +func unsafeSlice(slice, data unsafe.Pointer, len int) { + s := (*reflect.SliceHeader)(slice) + s.Data = uintptr(data) + s.Cap = len + s.Len = len +} diff --git a/vendor/github.com/alecthomas/.directory b/vendor/github.com/alecthomas/.directory deleted file mode 100644 index 36a5291..0000000 --- a/vendor/github.com/alecthomas/.directory +++ /dev/null @@ -1,6 +0,0 @@ -[Dolphin] -Timestamp=2018,1,23,17,47,46 -Version=3 - -[Settings] -HiddenFilesShown=true diff --git a/vendor/github.com/alecthomas/jsonschema/.travis.yml b/vendor/github.com/alecthomas/jsonschema/.travis.yml deleted file mode 100644 index d1c0f8f..0000000 --- a/vendor/github.com/alecthomas/jsonschema/.travis.yml +++ /dev/null @@ -1,6 +0,0 @@ -sudo: false -language: go -install: go get -t -v ./... -go: - - 1.7 - - 1.8 diff --git a/vendor/github.com/alecthomas/jsonschema/README.md b/vendor/github.com/alecthomas/jsonschema/README.md deleted file mode 100644 index 1254f01..0000000 --- a/vendor/github.com/alecthomas/jsonschema/README.md +++ /dev/null @@ -1,140 +0,0 @@ -# Go JSON Schema Reflection - -[![Build Status](https://travis-ci.org/alecthomas/jsonschema.png)](https://travis-ci.org/alecthomas/jsonschema) -[![Gitter chat](https://badges.gitter.im/alecthomas.png)](https://gitter.im/alecthomas/Lobby) -[![Go Report Card](https://goreportcard.com/badge/github.com/alecthomas/jsonschema)](https://goreportcard.com/report/github.com/alecthomas/jsonschema) -[![GoDoc](https://godoc.org/github.com/alecthomas/jsonschema?status.svg)](https://godoc.org/github.com/alecthomas/jsonschema) - -This package can be used to generate [JSON Schemas](http://json-schema.org/latest/json-schema-validation.html) from Go types through reflection. - -It supports arbitrarily complex types, including `interface{}`, maps, slices, etc. -And it also supports json-schema features such as minLength, maxLength, pattern, format and etc. -## Example - -The following Go type: - -```go -type TestUser struct { - ID int `json:"id"` - Name string `json:"name"` - Friends []int `json:"friends,omitempty"` - Tags map[string]interface{} `json:"tags,omitempty"` - BirthDate time.Time `json:"birth_date,omitempty"` -} -``` - -Results in following JSON Schema: - -```go -jsonschema.Reflect(&TestUser{}) -``` - -```json -{ - "$schema": "http://json-schema.org/draft-04/schema#", - "$ref": "#/definitions/TestUser", - "definitions": { - "TestUser": { - "type": "object", - "properties": { - "birth_date": { - "type": "string", - "format": "date-time" - }, - "friends": { - "type": "array", - "items": { - "type": "integer" - } - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string" - }, - "tags": { - "type": "object", - "patternProperties": { - ".*": { - "type": "object", - "additionalProperties": true - } - } - } - }, - "additionalProperties": false, - "required": ["id", "name"] - } - } -} -``` -## Configurable behaviour - -The behaviour of the schema generator can be altered with parameters when a `jsonschema.Reflector` -instance is created. - -### ExpandedStruct - -If set to ```true```, makes the top level struct not to reference itself in the definitions. But type passed should be a struct type. - -eg. - -```go -type GrandfatherType struct { - FamilyName string `json:"family_name" jsonschema:"required"` -} - -type SomeBaseType struct { - SomeBaseProperty int `json:"some_base_property"` - // The jsonschema required tag is nonsensical for private and ignored properties. - // Their presence here tests that the fields *will not* be required in the output - // schema, even if they are tagged required. - somePrivateBaseProperty string `json:"i_am_private" jsonschema:"required"` - SomeIgnoredBaseProperty string `json:"-" jsonschema:"required"` - SomeSchemaIgnoredProperty string `jsonschema:"-,required"` - SomeUntaggedBaseProperty bool `jsonschema:"required"` - someUnexportedUntaggedBaseProperty bool - Grandfather GrandfatherType `json:"grand"` -} -``` - -will output: - -```json -{ - "$schema": "http://json-schema.org/draft-04/schema#", - "required": [ - "some_base_property", - "grand", - "SomeUntaggedBaseProperty" - ], - "properties": { - "SomeUntaggedBaseProperty": { - "type": "boolean" - }, - "grand": { - "$schema": "http://json-schema.org/draft-04/schema#", - "$ref": "#/definitions/GrandfatherType" - }, - "some_base_property": { - "type": "integer" - } - }, - "type": "object", - "definitions": { - "GrandfatherType": { - "required": [ - "family_name" - ], - "properties": { - "family_name": { - "type": "string" - } - }, - "additionalProperties": false, - "type": "object" - } - } -} -``` diff --git a/vendor/github.com/alecthomas/jsonschema/fixtures/allow_additional_props.json b/vendor/github.com/alecthomas/jsonschema/fixtures/allow_additional_props.json deleted file mode 100644 index 4d90c77..0000000 --- a/vendor/github.com/alecthomas/jsonschema/fixtures/allow_additional_props.json +++ /dev/null @@ -1,109 +0,0 @@ -{ - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "$ref": "#\/definitions\/TestUser", - "definitions": { - "GrandfatherType": { - "required": [ - "family_name" - ], - "properties": { - "family_name": { - "type": "string" - } - }, - "additionalProperties": true, - "type": "object" - }, - "TestUser": { - "required": [ - "some_base_property", - "grand", - "SomeUntaggedBaseProperty", - "id", - "name", - "TestFlag", - "age", - "email" - ], - "properties": { - "SomeUntaggedBaseProperty": { - "type": "boolean" - }, - "TestFlag": { - "type": "boolean" - }, - "age":{ - "maximum": 120, - "minimum": 18, - "exclusiveMaximum": true, - "exclusiveMinimum": true, - "type": "integer" - }, - "email": { - "type": "string", - "format": "email" - }, - "birth_date": { - "type": "string", - "format": "date-time" - }, - "feeling": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "integer" - } - ] - }, - "friends": { - "items": { - "type": "integer" - }, - "type": "array" - }, - "grand": { - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "$ref": "#\/definitions\/GrandfatherType" - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string", - "maxLength": 20, - "minLength": 1 - }, - "network_address": { - "type": "string", - "format": "ipv4" - }, - "photo": { - "type": "string", - "media": { - "binaryEncoding": "base64" - } - }, - "some_base_property": { - "type": "integer" - }, - "tags": { - "patternProperties": { - ".*": { - "additionalProperties": true, - "type": "object" - } - }, - "type": "object" - }, - "website": { - "type": "string", - "format": "uri" - } - }, - "additionalProperties": true, - "type": "object" - } - } -} \ No newline at end of file diff --git a/vendor/github.com/alecthomas/jsonschema/fixtures/defaults.json b/vendor/github.com/alecthomas/jsonschema/fixtures/defaults.json deleted file mode 100644 index 801b57b..0000000 --- a/vendor/github.com/alecthomas/jsonschema/fixtures/defaults.json +++ /dev/null @@ -1,109 +0,0 @@ -{ - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "$ref": "#\/definitions\/TestUser", - "definitions": { - "GrandfatherType": { - "required": [ - "family_name" - ], - "properties": { - "family_name": { - "type": "string" - } - }, - "additionalProperties": false, - "type": "object" - }, - "TestUser": { - "required": [ - "some_base_property", - "grand", - "SomeUntaggedBaseProperty", - "id", - "name", - "TestFlag", - "age", - "email" - ], - "properties": { - "SomeUntaggedBaseProperty": { - "type": "boolean" - }, - "TestFlag": { - "type": "boolean" - }, - "age":{ - "maximum": 120, - "minimum": 18, - "exclusiveMaximum": true, - "exclusiveMinimum": true, - "type": "integer" - }, - "email": { - "type": "string", - "format": "email" - }, - "birth_date": { - "type": "string", - "format": "date-time" - }, - "feeling": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "integer" - } - ] - }, - "friends": { - "items": { - "type": "integer" - }, - "type": "array" - }, - "grand": { - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "$ref": "#\/definitions\/GrandfatherType" - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string", - "maxLength": 20, - "minLength": 1 - }, - "network_address": { - "type": "string", - "format": "ipv4" - }, - "photo": { - "type": "string", - "media": { - "binaryEncoding": "base64" - } - }, - "some_base_property": { - "type": "integer" - }, - "tags": { - "patternProperties": { - ".*": { - "additionalProperties": true, - "type": "object" - } - }, - "type": "object" - }, - "website": { - "type": "string", - "format": "uri" - } - }, - "additionalProperties": false, - "type": "object" - } - } -} \ No newline at end of file diff --git a/vendor/github.com/alecthomas/jsonschema/fixtures/defaults_expanded_toplevel.json b/vendor/github.com/alecthomas/jsonschema/fixtures/defaults_expanded_toplevel.json deleted file mode 100644 index 275689d..0000000 --- a/vendor/github.com/alecthomas/jsonschema/fixtures/defaults_expanded_toplevel.json +++ /dev/null @@ -1,106 +0,0 @@ -{ - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "required": [ - "some_base_property", - "grand", - "SomeUntaggedBaseProperty", - "id", - "name", - "TestFlag", - "age", - "email" - ], - "properties": { - "SomeUntaggedBaseProperty": { - "type": "boolean" - }, - "TestFlag": { - "type": "boolean" - }, - "age":{ - "maximum": 120, - "minimum": 18, - "exclusiveMaximum": true, - "exclusiveMinimum": true, - "type": "integer" - }, - "email": { - "type": "string", - "format": "email" - }, - "birth_date": { - "type": "string", - "format": "date-time" - }, - "feeling": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "integer" - } - ] - }, - "friends": { - "items": { - "type": "integer" - }, - "type": "array" - }, - "grand": { - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "$ref": "#\/definitions\/GrandfatherType" - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string", - "maxLength": 20, - "minLength": 1 - }, - "network_address": { - "type": "string", - "format": "ipv4" - }, - "photo": { - "type": "string", - "media": { - "binaryEncoding": "base64" - } - }, - "some_base_property": { - "type": "integer" - }, - "tags": { - "patternProperties": { - ".*": { - "additionalProperties": true, - "type": "object" - } - }, - "type": "object" - }, - "website": { - "type": "string", - "format": "uri" - } - }, - "additionalProperties": false, - "type": "object", - "definitions": { - "GrandfatherType": { - "required": [ - "family_name" - ], - "properties": { - "family_name": { - "type": "string" - } - }, - "additionalProperties": false, - "type": "object" - } - } -} diff --git a/vendor/github.com/alecthomas/jsonschema/fixtures/required_from_jsontags.json b/vendor/github.com/alecthomas/jsonschema/fixtures/required_from_jsontags.json deleted file mode 100644 index 3625a2a..0000000 --- a/vendor/github.com/alecthomas/jsonschema/fixtures/required_from_jsontags.json +++ /dev/null @@ -1,105 +0,0 @@ -{ - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "$ref": "#\/definitions\/TestUser", - "definitions": { - "GrandfatherType": { - "required": [ - "family_name" - ], - "properties": { - "family_name": { - "type": "string" - } - }, - "additionalProperties": false, - "type": "object" - }, - "TestUser": { - "required": [ - "SomeUntaggedBaseProperty", - "id", - "name", - "photo" - ], - "properties": { - "SomeUntaggedBaseProperty": { - "type": "boolean" - }, - "TestFlag": { - "type": "boolean" - }, - "age":{ - "maximum": 120, - "minimum": 18, - "exclusiveMaximum": true, - "exclusiveMinimum": true, - "type": "integer" - }, - "email": { - "type": "string", - "format": "email" - }, - "birth_date": { - "type": "string", - "format": "date-time" - }, - "feeling": { - "oneOf": [ - { - "type": "string" - }, - { - "type": "integer" - } - ] - }, - "friends": { - "items": { - "type": "integer" - }, - "type": "array" - }, - "grand": { - "$schema": "http:\/\/json-schema.org\/draft-04\/schema#", - "$ref": "#\/definitions\/GrandfatherType" - }, - "id": { - "type": "integer" - }, - "name": { - "type": "string", - "maxLength": 20, - "minLength": 1 - }, - "network_address": { - "type": "string", - "format": "ipv4" - }, - "photo": { - "type": "string", - "media": { - "binaryEncoding": "base64" - } - }, - "some_base_property": { - "type": "integer" - }, - "tags": { - "patternProperties": { - ".*": { - "additionalProperties": true, - "type": "object" - } - }, - "type": "object" - }, - "website": { - "type": "string", - "format": "uri" - } - }, - "additionalProperties": false, - "type": "object" - } - } -} \ No newline at end of file diff --git a/vendor/github.com/alecthomas/jsonschema/reflect.go b/vendor/github.com/alecthomas/jsonschema/reflect.go deleted file mode 100644 index 496587c..0000000 --- a/vendor/github.com/alecthomas/jsonschema/reflect.go +++ /dev/null @@ -1,451 +0,0 @@ -// Package jsonschema uses reflection to generate JSON Schemas from Go types [1]. -// -// If json tags are present on struct fields, they will be used to infer -// property names and if a property is required (omitempty is present). -// -// [1] http://json-schema.org/latest/json-schema-validation.html -package jsonschema - -import ( - "encoding/json" - "net" - "net/url" - "reflect" - "strings" - "time" - "strconv" -) - -// Version is the JSON Schema version. -// If extending JSON Schema with custom values use a custom URI. -// RFC draft-wright-json-schema-00, section 6 -var Version = "http://json-schema.org/draft-04/schema#" - -// Schema is the root schema. -// RFC draft-wright-json-schema-00, section 4.5 -type Schema struct { - *Type - Definitions Definitions `json:"definitions,omitempty"` -} - -// Type represents a JSON Schema object type. -type Type struct { - // RFC draft-wright-json-schema-00 - Version string `json:"$schema,omitempty"` // section 6.1 - Ref string `json:"$ref,omitempty"` // section 7 - // RFC draft-wright-json-schema-validation-00, section 5 - MultipleOf int `json:"multipleOf,omitempty"` // section 5.1 - Maximum int `json:"maximum,omitempty"` // section 5.2 - ExclusiveMaximum bool `json:"exclusiveMaximum,omitempty"` // section 5.3 - Minimum int `json:"minimum,omitempty"` // section 5.4 - ExclusiveMinimum bool `json:"exclusiveMinimum,omitempty"` // section 5.5 - MaxLength int `json:"maxLength,omitempty"` // section 5.6 - MinLength int `json:"minLength,omitempty"` // section 5.7 - Pattern string `json:"pattern,omitempty"` // section 5.8 - AdditionalItems *Type `json:"additionalItems,omitempty"` // section 5.9 - Items *Type `json:"items,omitempty"` // section 5.9 - MaxItems int `json:"maxItems,omitempty"` // section 5.10 - MinItems int `json:"minItems,omitempty"` // section 5.11 - UniqueItems bool `json:"uniqueItems,omitempty"` // section 5.12 - MaxProperties int `json:"maxProperties,omitempty"` // section 5.13 - MinProperties int `json:"minProperties,omitempty"` // section 5.14 - Required []string `json:"required,omitempty"` // section 5.15 - Properties map[string]*Type `json:"properties,omitempty"` // section 5.16 - PatternProperties map[string]*Type `json:"patternProperties,omitempty"` // section 5.17 - AdditionalProperties json.RawMessage `json:"additionalProperties,omitempty"` // section 5.18 - Dependencies map[string]*Type `json:"dependencies,omitempty"` // section 5.19 - Enum []interface{} `json:"enum,omitempty"` // section 5.20 - Type string `json:"type,omitempty"` // section 5.21 - AllOf []*Type `json:"allOf,omitempty"` // section 5.22 - AnyOf []*Type `json:"anyOf,omitempty"` // section 5.23 - OneOf []*Type `json:"oneOf,omitempty"` // section 5.24 - Not *Type `json:"not,omitempty"` // section 5.25 - Definitions Definitions `json:"definitions,omitempty"` // section 5.26 - // RFC draft-wright-json-schema-validation-00, section 6, 7 - Title string `json:"title,omitempty"` // section 6.1 - Description string `json:"description,omitempty"` // section 6.1 - Default interface{} `json:"default,omitempty"` // section 6.2 - Format string `json:"format,omitempty"` // section 7 - // RFC draft-wright-json-schema-hyperschema-00, section 4 - Media *Type `json:"media,omitempty"` // section 4.3 - BinaryEncoding string `json:"binaryEncoding,omitempty"` // section 4.3 -} - -// Reflect reflects to Schema from a value using the default Reflector -func Reflect(v interface{}) *Schema { - return ReflectFromType(reflect.TypeOf(v)) -} - -// ReflectFromType generates root schema using the default Reflector -func ReflectFromType(t reflect.Type) *Schema { - r := &Reflector{} - return r.ReflectFromType(t) -} - -// A Reflector reflects values into a Schema. -type Reflector struct { - // AllowAdditionalProperties will cause the Reflector to generate a schema - // with additionalProperties to 'true' for all struct types. This means - // the presence of additional keys in JSON objects will not cause validation - // to fail. Note said additional keys will simply be dropped when the - // validated JSON is unmarshaled. - AllowAdditionalProperties bool - - // RequiredFromJSONSchemaTags will cause the Reflector to generate a schema - // that requires any key tagged with `jsonschema:required`, overriding the - // default of requiring any key *not* tagged with `json:,omitempty`. - RequiredFromJSONSchemaTags bool - - // ExpandedStruct will cause the toplevel definitions of the schema not - // be referenced itself to a definition. - ExpandedStruct bool -} - -// Reflect reflects to Schema from a value. -func (r *Reflector) Reflect(v interface{}) *Schema { - return r.ReflectFromType(reflect.TypeOf(v)) -} - -// ReflectFromType generates root schema -func (r *Reflector) ReflectFromType(t reflect.Type) *Schema { - definitions := Definitions{} - if r.ExpandedStruct { - st := &Type{ - Version: Version, - Type: "object", - Properties: map[string]*Type{}, - AdditionalProperties: []byte("false"), - } - if r.AllowAdditionalProperties { - st.AdditionalProperties = []byte("true") - } - r.reflectStructFields(st, definitions, t) - r.reflectStruct(definitions, t) - delete(definitions, t.Name()) - return &Schema{Type: st, Definitions: definitions} - } - - s := &Schema{ - Type: r.reflectTypeToSchema(definitions, t), - Definitions: definitions, - } - return s -} - -// Definitions hold schema definitions. -// http://json-schema.org/latest/json-schema-validation.html#rfc.section.5.26 -// RFC draft-wright-json-schema-validation-00, section 5.26 -type Definitions map[string]*Type - -// Available Go defined types for JSON Schema Validation. -// RFC draft-wright-json-schema-validation-00, section 7.3 -var ( - timeType = reflect.TypeOf(time.Time{}) // date-time RFC section 7.3.1 - ipType = reflect.TypeOf(net.IP{}) // ipv4 and ipv6 RFC section 7.3.4, 7.3.5 - uriType = reflect.TypeOf(url.URL{}) // uri RFC section 7.3.6 -) - -// Byte slices will be encoded as base64 -var byteSliceType = reflect.TypeOf([]byte(nil)) - -// Go code generated from protobuf enum types should fulfil this interface. -type protoEnum interface { - EnumDescriptor() ([]byte, []int) -} - -var protoEnumType = reflect.TypeOf((*protoEnum)(nil)).Elem() - -func (r *Reflector) reflectTypeToSchema(definitions Definitions, t reflect.Type) *Type { - // Already added to definitions? - if _, ok := definitions[t.Name()]; ok { - return &Type{Ref: "#/definitions/" + t.Name()} - } - - // jsonpb will marshal protobuf enum options as either strings or integers. - // It will unmarshal either. - if t.Implements(protoEnumType) { - return &Type{OneOf: []*Type{ - {Type: "string"}, - {Type: "integer"}, - }} - } - - // Defined format types for JSON Schema Validation - // RFC draft-wright-json-schema-validation-00, section 7.3 - // TODO email RFC section 7.3.2, hostname RFC section 7.3.3, uriref RFC section 7.3.7 - switch t { - case ipType: - // TODO differentiate ipv4 and ipv6 RFC section 7.3.4, 7.3.5 - return &Type{Type: "string", Format: "ipv4"} // ipv4 RFC section 7.3.4 - } - - switch t.Kind() { - case reflect.Struct: - - switch t { - case timeType: // date-time RFC section 7.3.1 - return &Type{Type: "string", Format: "date-time"} - case uriType: // uri RFC section 7.3.6 - return &Type{Type: "string", Format: "uri"} - default: - return r.reflectStruct(definitions, t) - } - - case reflect.Map: - rt := &Type{ - Type: "object", - PatternProperties: map[string]*Type{ - ".*": r.reflectTypeToSchema(definitions, t.Elem()), - }, - } - delete(rt.PatternProperties, "additionalProperties") - return rt - - case reflect.Slice: - switch t { - case byteSliceType: - return &Type{ - Type: "string", - Media: &Type{BinaryEncoding: "base64"}, - } - default: - return &Type{ - Type: "array", - Items: r.reflectTypeToSchema(definitions, t.Elem()), - } - } - - case reflect.Interface: - return &Type{ - Type: "object", - AdditionalProperties: []byte("true"), - } - - case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64, - reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: - return &Type{Type: "integer"} - - case reflect.Float32, reflect.Float64: - return &Type{Type: "number"} - - case reflect.Bool: - return &Type{Type: "boolean"} - - case reflect.String: - return &Type{Type: "string"} - - case reflect.Ptr: - return r.reflectTypeToSchema(definitions, t.Elem()) - } - panic("unsupported type " + t.String()) -} - -// Refects a struct to a JSON Schema type. -func (r *Reflector) reflectStruct(definitions Definitions, t reflect.Type) *Type { - st := &Type{ - Type: "object", - Properties: map[string]*Type{}, - AdditionalProperties: []byte("false"), - } - if r.AllowAdditionalProperties { - st.AdditionalProperties = []byte("true") - } - definitions[t.Name()] = st - r.reflectStructFields(st, definitions, t) - - - return &Type{ - Version: Version, - Ref: "#/definitions/" + t.Name(), - } -} - -func (r *Reflector) reflectStructFields(st *Type, definitions Definitions, t reflect.Type) { - if t.Kind() == reflect.Ptr { - t = t.Elem() - } - for i := 0; i < t.NumField(); i++ { - f := t.Field(i) - // anonymous and exported type should be processed recursively - // current type should inherit properties of anonymous one - if f.Anonymous && f.PkgPath == "" { - r.reflectStructFields(st, definitions, f.Type) - continue - } - - name, required := r.reflectFieldName(f) - if name == "" { - continue - } - property := r.reflectTypeToSchema(definitions, f.Type) - property.structKeywordsFromTags(f) - st.Properties[name] = property - if required { - st.Required = append(st.Required, name) - } - } -} - -func (t *Type) structKeywordsFromTags(f reflect.StructField){ - tags := strings.Split(f.Tag.Get("jsonschema"), ",") - switch t.Type{ - case "string": - t.stringKeywords(tags) - case "number": - t.numbericKeywords(tags) - case "integer": - t.numbericKeywords(tags) - case "array": - t.arrayKeywords(tags) - } -} - -// read struct tags for string type keyworks -func (t *Type) stringKeywords(tags []string) { - for _, tag := range tags{ - nameValue := strings.Split(tag, "=") - if len(nameValue) == 2{ - name, val := nameValue[0], nameValue[1] - switch name{ - case "minLength": - i, _ := strconv.Atoi(val) - t.MinLength = i - case "maxLength": - i, _ := strconv.Atoi(val) - t.MaxLength = i - case "format": - switch val{ - case "date-time", "email", "hostname", "ipv4", "ipv6", "uri": - t.Format = val - break - } - } - } - } -} - -// read struct tags for numberic type keyworks -func (t *Type) numbericKeywords(tags []string) { - for _, tag := range tags{ - nameValue := strings.Split(tag, "=") - if len(nameValue) == 2{ - name, val := nameValue[0], nameValue[1] - switch name{ - case "multipleOf": - i, _ := strconv.Atoi(val) - t.MultipleOf = i - case "minimum": - i, _ := strconv.Atoi(val) - t.Minimum = i - case "maximum": - i, _ := strconv.Atoi(val) - t.Maximum = i - case "exclusiveMaximum": - b, _ := strconv.ParseBool(val) - t.ExclusiveMaximum = b - case "exclusiveMinimum": - b, _ := strconv.ParseBool(val) - t.ExclusiveMinimum = b - } - } - } -} - -// read struct tags for object type keyworks -// func (t *Type) objectKeywords(tags []string) { -// for _, tag := range tags{ -// nameValue := strings.Split(tag, "=") -// name, val := nameValue[0], nameValue[1] -// switch name{ -// case "dependencies": -// t.Dependencies = val -// break; -// case "patternProperties": -// t.PatternProperties = val -// break; -// } -// } -// } - -// read struct tags for array type keyworks -func (t *Type) arrayKeywords(tags []string) { - for _, tag := range tags{ - nameValue := strings.Split(tag, "=") - if len(nameValue) == 2{ - name, val := nameValue[0], nameValue[1] - switch name{ - case "minItems": - i, _ := strconv.Atoi(val) - t.MinItems = i - case "maxItems": - i, _ := strconv.Atoi(val) - t.MaxItems = i - case "uniqueItems": - t.UniqueItems = true - } - } - } -} - -func requiredFromJSONTags(tags []string) bool { - if ignoredByJSONTags(tags) { - return false - } - - for _, tag := range tags[1:] { - if tag == "omitempty" { - return false - } - } - return true -} - -func requiredFromJSONSchemaTags(tags []string) bool { - if ignoredByJSONSchemaTags(tags) { - return false - } - for _, tag := range tags { - if tag == "required" { - return true - } - } - return false -} - -func ignoredByJSONTags(tags []string) bool { - return tags[0] == "-" -} - -func ignoredByJSONSchemaTags(tags []string) bool { - return tags[0] == "-" -} - -func (r *Reflector) reflectFieldName(f reflect.StructField) (string, bool) { - if f.PkgPath != "" { // unexported field, ignore it - return "", false - } - - jsonTags := strings.Split(f.Tag.Get("json"), ",") - - if ignoredByJSONTags(jsonTags) { - return "", false - } - - jsonSchemaTags := strings.Split(f.Tag.Get("jsonschema"), ",") - if ignoredByJSONSchemaTags(jsonSchemaTags) { - return "", false - } - - name := f.Name - required := requiredFromJSONTags(jsonTags) - - if r.RequiredFromJSONSchemaTags { - required = requiredFromJSONSchemaTags(jsonSchemaTags) - } - - if jsonTags[0] != "" { - name = jsonTags[0] - } - - return name, required -} diff --git a/vendor/github.com/alecthomas/jsonschema/reflect_test.go b/vendor/github.com/alecthomas/jsonschema/reflect_test.go deleted file mode 100644 index 8447f31..0000000 --- a/vendor/github.com/alecthomas/jsonschema/reflect_test.go +++ /dev/null @@ -1,111 +0,0 @@ -package jsonschema - -import ( - "encoding/json" - "io/ioutil" - "net" - "net/url" - "path/filepath" - "reflect" - "strings" - "testing" - "time" -) - -type GrandfatherType struct { - FamilyName string `json:"family_name" jsonschema:"required"` -} - -type SomeBaseType struct { - SomeBaseProperty int `json:"some_base_property"` - // The jsonschema required tag is nonsensical for private and ignored properties. - // Their presence here tests that the fields *will not* be required in the output - // schema, even if they are tagged required. - somePrivateBaseProperty string `json:"i_am_private" jsonschema:"required"` - SomeIgnoredBaseProperty string `json:"-" jsonschema:"required"` - SomeSchemaIgnoredProperty string `jsonschema:"-,required"` - Grandfather GrandfatherType `json:"grand"` - - SomeUntaggedBaseProperty bool `jsonschema:"required"` - someUnexportedUntaggedBaseProperty bool -} - -type nonExported struct { - PublicNonExported int - privateNonExported int -} - -type ProtoEnum int32 - -func (ProtoEnum) EnumDescriptor() ([]byte, []int) { return []byte(nil), []int{0} } - -const ( - Unset ProtoEnum = iota - Great -) - -type TestUser struct { - SomeBaseType - nonExported - - ID int `json:"id" jsonschema:"required"` - Name string `json:"name" jsonschema:"required,minLength=1,maxLength=20"` - Friends []int `json:"friends,omitempty"` - Tags map[string]interface{} `json:"tags,omitempty"` - - TestFlag bool - IgnoredCounter int `json:"-"` - - // Tests for RFC draft-wright-json-schema-validation-00, section 7.3 - BirthDate time.Time `json:"birth_date,omitempty"` - Website url.URL `json:"website,omitempty"` - IPAddress net.IP `json:"network_address,omitempty"` - - // Tests for RFC draft-wright-json-schema-hyperschema-00, section 4 - Photo []byte `json:"photo,omitempty" jsonschema:"required"` - - // Tests for jsonpb enum support - Feeling ProtoEnum `json:"feeling,omitempty"` - Age int `json:"age" jsonschema:"minimum=18,maximum=120,exclusiveMaximum=true,exclusiveMinimum=true"` - Email string `json:"email" jsonschema:"format=email"` -} - -var schemaGenerationTests = []struct { - reflector *Reflector - fixture string -}{ - {&Reflector{}, "fixtures/defaults.json"}, - {&Reflector{AllowAdditionalProperties: true}, "fixtures/allow_additional_props.json"}, - {&Reflector{RequiredFromJSONSchemaTags: true}, "fixtures/required_from_jsontags.json"}, - {&Reflector{ExpandedStruct: true}, "fixtures/defaults_expanded_toplevel.json"}, -} - -func TestSchemaGeneration(t *testing.T) { - for _, tt := range schemaGenerationTests { - name := strings.TrimSuffix(filepath.Base(tt.fixture), ".json") - t.Run(name, func(t *testing.T) { - f, err := ioutil.ReadFile(tt.fixture) - if err != nil { - t.Errorf("ioutil.ReadAll(%s): %s", tt.fixture, err) - return - } - - actualSchema := tt.reflector.Reflect(&TestUser{}) - expectedSchema := &Schema{} - - if err := json.Unmarshal(f, expectedSchema); err != nil { - t.Errorf("json.Unmarshal(%s, %v): %s", tt.fixture, expectedSchema, err) - return - } - - if !reflect.DeepEqual(actualSchema, expectedSchema) { - actualJSON, err := json.MarshalIndent(actualSchema, "", " ") - if err != nil { - t.Errorf("json.MarshalIndent(%v, \"\", \" \"): %v", actualSchema, err) - return - } - t.Errorf("reflector %+v wanted schema %s, got %s", tt.reflector, f, actualJSON) - } - }) - } -} diff --git a/vendor/github.com/cheggaaa/pb/.travis.yml b/vendor/github.com/cheggaaa/pb/.travis.yml deleted file mode 100644 index b0fccc5..0000000 --- a/vendor/github.com/cheggaaa/pb/.travis.yml +++ /dev/null @@ -1,15 +0,0 @@ -language: go -arch: - - amd64 - - ppc64le -go: - - 1.9.x - - 1.12.x -sudo: false -os: - - linux - - osx -before_install: - - go get github.com/mattn/goveralls -script: - - $GOPATH/bin/goveralls -package github.com/cheggaaa/pb/v3 -repotoken QT1y5Iujb8ete6JOiE0ytKFlBDv9vheWc diff --git a/vendor/github.com/cheggaaa/pb/LICENSE b/vendor/github.com/cheggaaa/pb/LICENSE deleted file mode 100644 index 5119703..0000000 --- a/vendor/github.com/cheggaaa/pb/LICENSE +++ /dev/null @@ -1,12 +0,0 @@ -Copyright (c) 2012-2015, Sergey Cherepanov -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -* Neither the name of the author nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \ No newline at end of file diff --git a/vendor/github.com/cheggaaa/pb/README.md b/vendor/github.com/cheggaaa/pb/README.md deleted file mode 100644 index 1b21085..0000000 --- a/vendor/github.com/cheggaaa/pb/README.md +++ /dev/null @@ -1,129 +0,0 @@ -# Terminal progress bar for Go -[![Coverage Status](https://coveralls.io/repos/github/cheggaaa/pb/badge.svg)](https://coveralls.io/github/cheggaaa/pb) - -## Installation - -``` -go get github.com/cheggaaa/pb/v3 -``` - -Documentation for v1 bar available [here](README_V1.md) - -## Quick start - -```Go -package main - -import ( - "time" - - "github.com/cheggaaa/pb/v3" -) - -func main() { - count := 100000 - // create and start new bar - bar := pb.StartNew(count) - - // start bar from 'default' template - // bar := pb.Default.Start(count) - - // start bar from 'simple' template - // bar := pb.Simple.Start(count) - - // start bar from 'full' template - // bar := pb.Full.Start(count) - - for i := 0; i < count; i++ { - bar.Increment() - time.Sleep(time.Millisecond) - } - bar.Finish() -} - -``` - -Result will be like this: - -``` -> go run test.go -37158 / 100000 [================>_______________________________] 37.16% 1m11s -``` - -## Settings - -```Go -// create bar -bar := pb.New(count) - -// refresh info every second (default 200ms) -bar.SetRefreshRate(time.Second) - -// force set io.Writer, by default it's os.Stderr -bar.SetWriter(os.Stdout) - -// bar will format numbers as bytes (B, KiB, MiB, etc) -bar.Set(pb.Bytes, true) - -// bar use SI bytes prefix names (B, kB) instead of IEC (B, KiB) -bar.Set(pb.SIBytesPrefix, true) - -// set custom bar template -bar.SetTemplateString(myTemplate) - -// check for error after template set -if err = bar.Err(); err != nil { - return -} - -// start bar -bar.Start() - -``` - -## Progress bar for IO Operations -```go -package main - -import ( - "crypto/rand" - "io" - "io/ioutil" - - "github.com/cheggaaa/pb/v3" -) - -func main() { - - var limit int64 = 1024 * 1024 * 500 - // we will copy 200 Mb from /dev/rand to /dev/null - reader := io.LimitReader(rand.Reader, limit) - writer := ioutil.Discard - - // start new bar - bar := pb.Full.Start64(limit) - // create proxy reader - barReader := bar.NewProxyReader(reader) - // copy from proxy reader - io.Copy(writer, barReader) - // finish bar - bar.Finish() -} - -``` - -## Custom Progress Bar templates - -Rendering based on builtin text/template package. You can use existing pb's elements or create you own. - -All available elements are described in element.go file. - -#### All in one example: -```go -tmpl := `{{ red "With funcs:" }} {{ bar . "<" "-" (cycle . "↖" "↗" "↘" "↙" ) "." ">"}} {{speed . | rndcolor }} {{percent .}} {{string . "my_green_string" | green}} {{string . "my_blue_string" | blue}}` -// start bar based on our template -bar := pb.ProgressBarTemplate(tmpl).Start64(limit) -// set values for string elements -bar.Set("my_green_string", "green"). - Set("my_blue_string", "blue") -``` diff --git a/vendor/github.com/cheggaaa/pb/README_V1.md b/vendor/github.com/cheggaaa/pb/README_V1.md deleted file mode 100644 index f0689ac..0000000 --- a/vendor/github.com/cheggaaa/pb/README_V1.md +++ /dev/null @@ -1,175 +0,0 @@ -# Terminal progress bar for Go - -Simple progress bar for console programs. - -## Installation - -``` -go get github.com/cheggaaa/pb -``` - -## Usage - -```Go -package main - -import ( - "github.com/cheggaaa/pb" - "time" -) - -func main() { - count := 100000 - bar := pb.StartNew(count) - for i := 0; i < count; i++ { - bar.Increment() - time.Sleep(time.Millisecond) - } - bar.FinishPrint("The End!") -} - -``` - -Result will be like this: - -``` -> go run test.go -37158 / 100000 [================>_______________________________] 37.16% 1m11s -``` - -## Customization - -```Go -// create bar -bar := pb.New(count) - -// refresh info every second (default 200ms) -bar.SetRefreshRate(time.Second) - -// show percents (by default already true) -bar.ShowPercent = true - -// show bar (by default already true) -bar.ShowBar = true - -// no counters -bar.ShowCounters = false - -// show "time left" -bar.ShowTimeLeft = true - -// show average speed -bar.ShowSpeed = true - -// sets the width of the progress bar -bar.SetWidth(80) - -// sets the width of the progress bar, but if terminal size smaller will be ignored -bar.SetMaxWidth(80) - -// convert output to readable format (like KB, MB) -bar.SetUnits(pb.U_BYTES) - -// and start -bar.Start() -``` - -## Progress bar for IO Operations - -```go -// create and start bar -bar := pb.New(myDataLen).SetUnits(pb.U_BYTES) -bar.Start() - -// my io.Reader -r := myReader - -// my io.Writer -w := myWriter - -// create proxy reader -reader := bar.NewProxyReader(r) - -// and copy from pb reader -io.Copy(w, reader) - -``` - -```go -// create and start bar -bar := pb.New(myDataLen).SetUnits(pb.U_BYTES) -bar.Start() - -// my io.Reader -r := myReader - -// my io.Writer -w := myWriter - -// create multi writer -writer := io.MultiWriter(w, bar) - -// and copy -io.Copy(writer, r) - -bar.Finish() -``` - -## Custom Progress Bar Look-and-feel - -```go -bar.Format("<.- >") -``` - -## Multiple Progress Bars (experimental and unstable) - -Do not print to terminal while pool is active. - -```go -package main - -import ( - "math/rand" - "sync" - "time" - - "github.com/cheggaaa/pb" -) - -func main() { - // create bars - first := pb.New(200).Prefix("First ") - second := pb.New(200).Prefix("Second ") - third := pb.New(200).Prefix("Third ") - // start pool - pool, err := pb.StartPool(first, second, third) - if err != nil { - panic(err) - } - // update bars - wg := new(sync.WaitGroup) - for _, bar := range []*pb.ProgressBar{first, second, third} { - wg.Add(1) - go func(cb *pb.ProgressBar) { - for n := 0; n < 200; n++ { - cb.Increment() - time.Sleep(time.Millisecond * time.Duration(rand.Intn(100))) - } - cb.Finish() - wg.Done() - }(bar) - } - wg.Wait() - // close pool - pool.Stop() -} -``` - -The result will be as follows: - -``` -$ go run example/multiple.go -First 34 / 200 [=========>---------------------------------------------] 17.00% 00m08s -Second 42 / 200 [===========>------------------------------------------] 21.00% 00m06s -Third 36 / 200 [=========>---------------------------------------------] 18.00% 00m08s -``` diff --git a/vendor/github.com/cheggaaa/pb/example_copy_test.go b/vendor/github.com/cheggaaa/pb/example_copy_test.go deleted file mode 100644 index 85662d0..0000000 --- a/vendor/github.com/cheggaaa/pb/example_copy_test.go +++ /dev/null @@ -1,82 +0,0 @@ -package pb_test - -import ( - "fmt" - "io" - "net/http" - "os" - "strconv" - "strings" - "time" - - "github.com/cheggaaa/pb" -) - -func Example_copy() { - // check args - if len(os.Args) < 3 { - printUsage() - return - } - sourceName, destName := os.Args[1], os.Args[2] - - // check source - var source io.Reader - var sourceSize int64 - if strings.HasPrefix(sourceName, "http://") { - // open as url - resp, err := http.Get(sourceName) - if err != nil { - fmt.Printf("Can't get %s: %v\n", sourceName, err) - return - } - defer resp.Body.Close() - if resp.StatusCode != http.StatusOK { - fmt.Printf("Server return non-200 status: %v\n", resp.Status) - return - } - i, _ := strconv.Atoi(resp.Header.Get("Content-Length")) - sourceSize = int64(i) - source = resp.Body - } else { - // open as file - s, err := os.Open(sourceName) - if err != nil { - fmt.Printf("Can't open %s: %v\n", sourceName, err) - return - } - defer s.Close() - // get source size - sourceStat, err := s.Stat() - if err != nil { - fmt.Printf("Can't stat %s: %v\n", sourceName, err) - return - } - sourceSize = sourceStat.Size() - source = s - } - - // create dest - dest, err := os.Create(destName) - if err != nil { - fmt.Printf("Can't create %s: %v\n", destName, err) - return - } - defer dest.Close() - - // create bar - bar := pb.New(int(sourceSize)).SetUnits(pb.U_BYTES).SetRefreshRate(time.Millisecond * 10) - bar.ShowSpeed = true - bar.Start() - - // create proxy reader - reader := bar.NewProxyReader(source) - - // and copy from reader - io.Copy(dest, reader) - bar.Finish() -} - -func printUsage() { - fmt.Println("copy [source file or url] [dest file]") -} diff --git a/vendor/github.com/cheggaaa/pb/example_multiple_test.go b/vendor/github.com/cheggaaa/pb/example_multiple_test.go deleted file mode 100644 index d3396f4..0000000 --- a/vendor/github.com/cheggaaa/pb/example_multiple_test.go +++ /dev/null @@ -1,37 +0,0 @@ -package pb_test - -import ( - "math/rand" - "sync" - "time" - - "github.com/cheggaaa/pb" -) - -func Example_multiple() { - // create bars - first := pb.New(200).Prefix("First ") - second := pb.New(200).Prefix("Second ") - third := pb.New(200).Prefix("Third ") - // start pool - pool, err := pb.StartPool(first, second, third) - if err != nil { - panic(err) - } - // update bars - wg := new(sync.WaitGroup) - for _, bar := range []*pb.ProgressBar{first, second, third} { - wg.Add(1) - go func(cb *pb.ProgressBar) { - for n := 0; n < 200; n++ { - cb.Increment() - time.Sleep(time.Millisecond * time.Duration(rand.Intn(100))) - } - cb.Finish() - wg.Done() - }(bar) - } - wg.Wait() - // close pool - pool.Stop() -} diff --git a/vendor/github.com/cheggaaa/pb/example_test.go b/vendor/github.com/cheggaaa/pb/example_test.go deleted file mode 100644 index fe00f68..0000000 --- a/vendor/github.com/cheggaaa/pb/example_test.go +++ /dev/null @@ -1,30 +0,0 @@ -package pb_test - -import ( - "time" - - "github.com/cheggaaa/pb" -) - -func Example() { - count := 5000 - bar := pb.New(count) - - // show percents (by default already true) - bar.ShowPercent = true - - // show bar (by default already true) - bar.ShowBar = true - - bar.ShowCounters = true - - bar.ShowTimeLeft = true - - // and start - bar.Start() - for i := 0; i < count; i++ { - bar.Increment() - time.Sleep(time.Millisecond) - } - bar.FinishPrint("The End!") -} diff --git a/vendor/github.com/cheggaaa/pb/format.go b/vendor/github.com/cheggaaa/pb/format.go deleted file mode 100644 index 8bb8a7a..0000000 --- a/vendor/github.com/cheggaaa/pb/format.go +++ /dev/null @@ -1,125 +0,0 @@ -package pb - -import ( - "fmt" - "time" -) - -type Units int - -const ( - // U_NO are default units, they represent a simple value and are not formatted at all. - U_NO Units = iota - // U_BYTES units are formatted in a human readable way (B, KiB, MiB, ...) - U_BYTES - // U_BYTES_DEC units are like U_BYTES, but base 10 (B, KB, MB, ...) - U_BYTES_DEC - // U_DURATION units are formatted in a human readable way (3h14m15s) - U_DURATION -) - -const ( - KiB = 1024 - MiB = 1048576 - GiB = 1073741824 - TiB = 1099511627776 - - KB = 1e3 - MB = 1e6 - GB = 1e9 - TB = 1e12 -) - -func Format(i int64) *formatter { - return &formatter{n: i} -} - -type formatter struct { - n int64 - unit Units - width int - perSec bool -} - -func (f *formatter) To(unit Units) *formatter { - f.unit = unit - return f -} - -func (f *formatter) Width(width int) *formatter { - f.width = width - return f -} - -func (f *formatter) PerSec() *formatter { - f.perSec = true - return f -} - -func (f *formatter) String() (out string) { - switch f.unit { - case U_BYTES: - out = formatBytes(f.n) - case U_BYTES_DEC: - out = formatBytesDec(f.n) - case U_DURATION: - out = formatDuration(f.n) - default: - out = fmt.Sprintf(fmt.Sprintf("%%%dd", f.width), f.n) - } - if f.perSec { - out += "/s" - } - return -} - -// Convert bytes to human readable string. Like 2 MiB, 64.2 KiB, 52 B -func formatBytes(i int64) (result string) { - switch { - case i >= TiB: - result = fmt.Sprintf("%.02f TiB", float64(i)/TiB) - case i >= GiB: - result = fmt.Sprintf("%.02f GiB", float64(i)/GiB) - case i >= MiB: - result = fmt.Sprintf("%.02f MiB", float64(i)/MiB) - case i >= KiB: - result = fmt.Sprintf("%.02f KiB", float64(i)/KiB) - default: - result = fmt.Sprintf("%d B", i) - } - return -} - -// Convert bytes to base-10 human readable string. Like 2 MB, 64.2 KB, 52 B -func formatBytesDec(i int64) (result string) { - switch { - case i >= TB: - result = fmt.Sprintf("%.02f TB", float64(i)/TB) - case i >= GB: - result = fmt.Sprintf("%.02f GB", float64(i)/GB) - case i >= MB: - result = fmt.Sprintf("%.02f MB", float64(i)/MB) - case i >= KB: - result = fmt.Sprintf("%.02f KB", float64(i)/KB) - default: - result = fmt.Sprintf("%d B", i) - } - return -} - -func formatDuration(n int64) (result string) { - d := time.Duration(n) - if d > time.Hour*24 { - result = fmt.Sprintf("%dd", d/24/time.Hour) - d -= (d / time.Hour / 24) * (time.Hour * 24) - } - if d > time.Hour { - result = fmt.Sprintf("%s%dh", result, d/time.Hour) - d -= d / time.Hour * time.Hour - } - m := d / time.Minute - d -= m * time.Minute - s := d / time.Second - result = fmt.Sprintf("%s%02dm%02ds", result, m, s) - return -} diff --git a/vendor/github.com/cheggaaa/pb/format_test.go b/vendor/github.com/cheggaaa/pb/format_test.go deleted file mode 100644 index 645709e..0000000 --- a/vendor/github.com/cheggaaa/pb/format_test.go +++ /dev/null @@ -1,95 +0,0 @@ -package pb - -import ( - "fmt" - "strconv" - "testing" - "time" -) - -func Test_DefaultsToInteger(t *testing.T) { - value := int64(1000) - expected := strconv.Itoa(int(value)) - actual := Format(value).String() - - if actual != expected { - t.Error(fmt.Sprintf("Expected {%s} was {%s}", expected, actual)) - } -} - -func Test_CanFormatAsInteger(t *testing.T) { - value := int64(1000) - expected := strconv.Itoa(int(value)) - actual := Format(value).To(U_NO).String() - - if actual != expected { - t.Error(fmt.Sprintf("Expected {%s} was {%s}", expected, actual)) - } -} - -func Test_CanFormatAsBytes(t *testing.T) { - inputs := []struct { - v int64 - e string - }{ - {v: 1000, e: "1000 B"}, - {v: 1024, e: "1.00 KiB"}, - {v: 3*MiB + 140*KiB, e: "3.14 MiB"}, - {v: 2 * GiB, e: "2.00 GiB"}, - {v: 2048 * GiB, e: "2.00 TiB"}, - } - - for _, input := range inputs { - actual := Format(input.v).To(U_BYTES).String() - if actual != input.e { - t.Error(fmt.Sprintf("Expected {%s} was {%s}", input.e, actual)) - } - } -} - -func Test_CanFormatAsBytesDec(t *testing.T) { - inputs := []struct { - v int64 - e string - }{ - {v: 999, e: "999 B"}, - {v: 1024, e: "1.02 KB"}, - {v: 3*MB + 140*KB, e: "3.14 MB"}, - {v: 2 * GB, e: "2.00 GB"}, - {v: 2048 * GB, e: "2.05 TB"}, - } - - for _, input := range inputs { - actual := Format(input.v).To(U_BYTES_DEC).String() - if actual != input.e { - t.Error(fmt.Sprintf("Expected {%s} was {%s}", input.e, actual)) - } - } -} - -func Test_CanFormatDuration(t *testing.T) { - value := 10 * time.Minute - expected := "10m00s" - actual := Format(int64(value)).To(U_DURATION).String() - if actual != expected { - t.Error(fmt.Sprintf("Expected {%s} was {%s}", expected, actual)) - } -} - -func Test_CanFormatLongDuration(t *testing.T) { - value := 62 * time.Hour + 13 * time.Second - expected := "2d14h00m13s" - actual := Format(int64(value)).To(U_DURATION).String() - if actual != expected { - t.Error(fmt.Sprintf("Expected {%s} was {%s}", expected, actual)) - } -} - -func Test_DefaultUnitsWidth(t *testing.T) { - value := 10 - expected := " 10" - actual := Format(int64(value)).Width(7).String() - if actual != expected { - t.Error(fmt.Sprintf("Expected {%s} was {%s}", expected, actual)) - } -} diff --git a/vendor/github.com/cheggaaa/pb/go.mod b/vendor/github.com/cheggaaa/pb/go.mod deleted file mode 100644 index 058345e..0000000 --- a/vendor/github.com/cheggaaa/pb/go.mod +++ /dev/null @@ -1,10 +0,0 @@ -module github.com/cheggaaa/pb - -require ( - github.com/fatih/color v1.9.0 - github.com/mattn/go-colorable v0.1.4 - github.com/mattn/go-runewidth v0.0.4 - golang.org/x/sys v0.0.0-20191026070338-33540a1f6037 -) - -go 1.12 diff --git a/vendor/github.com/cheggaaa/pb/go.sum b/vendor/github.com/cheggaaa/pb/go.sum deleted file mode 100644 index 3ecb91d..0000000 --- a/vendor/github.com/cheggaaa/pb/go.sum +++ /dev/null @@ -1,19 +0,0 @@ -github.com/fatih/color v1.7.0 h1:DkWD4oS2D8LGGgTQ6IvwJJXSL5Vp2ffcQg58nFV38Ys= -github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/fatih/color v1.9.0 h1:8xPHl4/q1VyqGIPif1F+1V3Y3lSmrq01EabUW3CoW5s= -github.com/fatih/color v1.9.0/go.mod h1:eQcE1qtQxscV5RaZvpXrrb8Drkc3/DdQ+uUYCNjL+zU= -github.com/mattn/go-colorable v0.1.2 h1:/bC9yWikZXAL9uJdulbSfyVNIR3n3trXl+v8+1sx8mU= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.4 h1:snbPLB8fVfU9iwbbo30TPtbLRzwWu6aJS6Xh4eaaviA= -github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.11 h1:FxPOTFNqGkuDUGi3H/qkUbQO4ZiBa2brKq5r0l8TGeM= -github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE= -github.com/mattn/go-runewidth v0.0.4 h1:2BvfKmzob6Bmd4YsL0zygOqfdFnK7GR4QL06Do4/p7Y= -github.com/mattn/go-runewidth v0.0.4/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb h1:fgwFCsaw9buMuxNd6+DQfAuSFqbNiQZpcgJQAgJsK6k= -golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037 h1:YyJpGZS1sBuBCzLAR1VEpK193GlqGZbnPFnPV/5Rsb4= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= diff --git a/vendor/github.com/cheggaaa/pb/pb.go b/vendor/github.com/cheggaaa/pb/pb.go deleted file mode 100644 index 04dbce6..0000000 --- a/vendor/github.com/cheggaaa/pb/pb.go +++ /dev/null @@ -1,506 +0,0 @@ -// Simple console progress bars -package pb - -import ( - "fmt" - "io" - "math" - "strings" - "sync" - "sync/atomic" - "time" - "unicode/utf8" -) - -// Current version -const Version = "1.0.29" - -const ( - // Default refresh rate - 200ms - DEFAULT_REFRESH_RATE = time.Millisecond * 200 - FORMAT = "[=>-]" -) - -// DEPRECATED -// variables for backward compatibility, from now do not work -// use pb.Format and pb.SetRefreshRate -var ( - DefaultRefreshRate = DEFAULT_REFRESH_RATE - BarStart, BarEnd, Empty, Current, CurrentN string -) - -// Create new progress bar object -func New(total int) *ProgressBar { - return New64(int64(total)) -} - -// Create new progress bar object using int64 as total -func New64(total int64) *ProgressBar { - pb := &ProgressBar{ - Total: total, - RefreshRate: DEFAULT_REFRESH_RATE, - ShowPercent: true, - ShowCounters: true, - ShowBar: true, - ShowTimeLeft: true, - ShowElapsedTime: false, - ShowFinalTime: true, - Units: U_NO, - ManualUpdate: false, - finish: make(chan struct{}), - } - return pb.Format(FORMAT) -} - -// Create new object and start -func StartNew(total int) *ProgressBar { - return New(total).Start() -} - -// Callback for custom output -// For example: -// bar.Callback = func(s string) { -// mySuperPrint(s) -// } -// -type Callback func(out string) - -type ProgressBar struct { - current int64 // current must be first member of struct (https://code.google.com/p/go/issues/detail?id=5278) - previous int64 - - Total int64 - RefreshRate time.Duration - ShowPercent, ShowCounters bool - ShowSpeed, ShowTimeLeft, ShowBar bool - ShowFinalTime, ShowElapsedTime bool - Output io.Writer - Callback Callback - NotPrint bool - Units Units - Width int - ForceWidth bool - ManualUpdate bool - AutoStat bool - - // Default width for the time box. - UnitsWidth int - TimeBoxWidth int - - finishOnce sync.Once //Guards isFinish - finish chan struct{} - isFinish bool - - startTime time.Time - startValue int64 - - changeTime time.Time - - prefix, postfix string - - mu sync.Mutex - lastPrint string - - BarStart string - BarEnd string - Empty string - Current string - CurrentN string - - AlwaysUpdate bool -} - -// Start print -func (pb *ProgressBar) Start() *ProgressBar { - pb.startTime = time.Now() - pb.startValue = atomic.LoadInt64(&pb.current) - if atomic.LoadInt64(&pb.Total) == 0 { - pb.ShowTimeLeft = false - pb.ShowPercent = false - pb.AutoStat = false - } - if !pb.ManualUpdate { - pb.Update() // Initial printing of the bar before running the bar refresher. - go pb.refresher() - } - return pb -} - -// Increment current value -func (pb *ProgressBar) Increment() int { - return pb.Add(1) -} - -// Get current value -func (pb *ProgressBar) Get() int64 { - c := atomic.LoadInt64(&pb.current) - return c -} - -// Set current value -func (pb *ProgressBar) Set(current int) *ProgressBar { - return pb.Set64(int64(current)) -} - -// Set64 sets the current value as int64 -func (pb *ProgressBar) Set64(current int64) *ProgressBar { - atomic.StoreInt64(&pb.current, current) - return pb -} - -// Add to current value -func (pb *ProgressBar) Add(add int) int { - return int(pb.Add64(int64(add))) -} - -func (pb *ProgressBar) Add64(add int64) int64 { - return atomic.AddInt64(&pb.current, add) -} - -// Set prefix string -func (pb *ProgressBar) Prefix(prefix string) *ProgressBar { - pb.mu.Lock() - defer pb.mu.Unlock() - pb.prefix = prefix - return pb -} - -// Set postfix string -func (pb *ProgressBar) Postfix(postfix string) *ProgressBar { - pb.mu.Lock() - defer pb.mu.Unlock() - pb.postfix = postfix - return pb -} - -// Set custom format for bar -// Example: bar.Format("[=>_]") -// Example: bar.Format("[\x00=\x00>\x00-\x00]") // \x00 is the delimiter -func (pb *ProgressBar) Format(format string) *ProgressBar { - var formatEntries []string - if utf8.RuneCountInString(format) == 5 { - formatEntries = strings.Split(format, "") - } else { - formatEntries = strings.Split(format, "\x00") - } - if len(formatEntries) == 5 { - pb.BarStart = formatEntries[0] - pb.BarEnd = formatEntries[4] - pb.Empty = formatEntries[3] - pb.Current = formatEntries[1] - pb.CurrentN = formatEntries[2] - } - return pb -} - -// Set bar refresh rate -func (pb *ProgressBar) SetRefreshRate(rate time.Duration) *ProgressBar { - pb.RefreshRate = rate - return pb -} - -// Set units -// bar.SetUnits(U_NO) - by default -// bar.SetUnits(U_BYTES) - for Mb, Kb, etc -func (pb *ProgressBar) SetUnits(units Units) *ProgressBar { - pb.Units = units - return pb -} - -// Set max width, if width is bigger than terminal width, will be ignored -func (pb *ProgressBar) SetMaxWidth(width int) *ProgressBar { - pb.Width = width - pb.ForceWidth = false - return pb -} - -// Set bar width -func (pb *ProgressBar) SetWidth(width int) *ProgressBar { - pb.Width = width - pb.ForceWidth = true - return pb -} - -// End print -func (pb *ProgressBar) Finish() { - //Protect multiple calls - pb.finishOnce.Do(func() { - close(pb.finish) - pb.write(atomic.LoadInt64(&pb.Total), atomic.LoadInt64(&pb.current)) - pb.mu.Lock() - defer pb.mu.Unlock() - switch { - case pb.Output != nil: - fmt.Fprintln(pb.Output) - case !pb.NotPrint: - fmt.Println() - } - pb.isFinish = true - }) -} - -// IsFinished return boolean -func (pb *ProgressBar) IsFinished() bool { - pb.mu.Lock() - defer pb.mu.Unlock() - return pb.isFinish -} - -// End print and write string 'str' -func (pb *ProgressBar) FinishPrint(str string) { - pb.Finish() - if pb.Output != nil { - fmt.Fprintln(pb.Output, str) - } else { - fmt.Println(str) - } -} - -// implement io.Writer -func (pb *ProgressBar) Write(p []byte) (n int, err error) { - n = len(p) - pb.Add(n) - return -} - -// implement io.Reader -func (pb *ProgressBar) Read(p []byte) (n int, err error) { - n = len(p) - pb.Add(n) - return -} - -// Create new proxy reader over bar -// Takes io.Reader or io.ReadCloser -func (pb *ProgressBar) NewProxyReader(r io.Reader) *Reader { - return &Reader{r, pb} -} - -// Create new proxy writer over bar -// Takes io.Writer or io.WriteCloser -func (pb *ProgressBar) NewProxyWriter(r io.Writer) *Writer { - return &Writer{r, pb} -} - -func (pb *ProgressBar) write(total, current int64) { - pb.mu.Lock() - defer pb.mu.Unlock() - width := pb.GetWidth() - - var percentBox, countersBox, timeLeftBox, timeSpentBox, speedBox, barBox, end, out string - - // percents - if pb.ShowPercent { - var percent float64 - if total > 0 { - percent = float64(current) / (float64(total) / float64(100)) - } else { - percent = float64(current) / float64(100) - } - percentBox = fmt.Sprintf(" %6.02f%%", percent) - } - - // counters - if pb.ShowCounters { - current := Format(current).To(pb.Units).Width(pb.UnitsWidth) - if total > 0 { - totalS := Format(total).To(pb.Units).Width(pb.UnitsWidth) - countersBox = fmt.Sprintf(" %s / %s ", current, totalS) - } else { - countersBox = fmt.Sprintf(" %s / ? ", current) - } - } - - // time left - currentFromStart := current - pb.startValue - fromStart := time.Now().Sub(pb.startTime) - lastChangeTime := pb.changeTime - fromChange := lastChangeTime.Sub(pb.startTime) - - if pb.ShowElapsedTime { - timeSpentBox = fmt.Sprintf(" %s ", (fromStart/time.Second)*time.Second) - } - - select { - case <-pb.finish: - if pb.ShowFinalTime { - var left time.Duration - left = (fromStart / time.Second) * time.Second - timeLeftBox = fmt.Sprintf(" %s", left.String()) - } - default: - if pb.ShowTimeLeft && currentFromStart > 0 { - perEntry := fromChange / time.Duration(currentFromStart) - var left time.Duration - if total > 0 { - left = time.Duration(total-current) * perEntry - left -= time.Since(lastChangeTime) - left = (left / time.Second) * time.Second - } - if left > 0 { - timeLeft := Format(int64(left)).To(U_DURATION).String() - timeLeftBox = fmt.Sprintf(" %s", timeLeft) - } - } - } - - if len(timeLeftBox) < pb.TimeBoxWidth { - timeLeftBox = fmt.Sprintf("%s%s", strings.Repeat(" ", pb.TimeBoxWidth-len(timeLeftBox)), timeLeftBox) - } - - // speed - if pb.ShowSpeed && currentFromStart > 0 { - fromStart := time.Now().Sub(pb.startTime) - speed := float64(currentFromStart) / (float64(fromStart) / float64(time.Second)) - speedBox = " " + Format(int64(speed)).To(pb.Units).Width(pb.UnitsWidth).PerSec().String() - } - - barWidth := escapeAwareRuneCountInString(countersBox + pb.BarStart + pb.BarEnd + percentBox + timeSpentBox + timeLeftBox + speedBox + pb.prefix + pb.postfix) - // bar - if pb.ShowBar { - size := width - barWidth - if size > 0 { - if total > 0 { - curSize := int(math.Ceil((float64(current) / float64(total)) * float64(size))) - emptySize := size - curSize - barBox = pb.BarStart - if emptySize < 0 { - emptySize = 0 - } - if curSize > size { - curSize = size - } - - cursorLen := escapeAwareRuneCountInString(pb.Current) - if emptySize <= 0 { - barBox += strings.Repeat(pb.Current, curSize/cursorLen) - } else if curSize > 0 { - cursorEndLen := escapeAwareRuneCountInString(pb.CurrentN) - cursorRepetitions := (curSize - cursorEndLen) / cursorLen - barBox += strings.Repeat(pb.Current, cursorRepetitions) - barBox += pb.CurrentN - } - - emptyLen := escapeAwareRuneCountInString(pb.Empty) - barBox += strings.Repeat(pb.Empty, emptySize/emptyLen) - barBox += pb.BarEnd - } else { - pos := size - int(current)%int(size) - barBox = pb.BarStart - if pos-1 > 0 { - barBox += strings.Repeat(pb.Empty, pos-1) - } - barBox += pb.Current - if size-pos-1 > 0 { - barBox += strings.Repeat(pb.Empty, size-pos-1) - } - barBox += pb.BarEnd - } - } - } - - // check len - out = pb.prefix + timeSpentBox + countersBox + barBox + percentBox + speedBox + timeLeftBox + pb.postfix - - if cl := escapeAwareRuneCountInString(out); cl < width { - end = strings.Repeat(" ", width-cl) - } - - // and print! - pb.lastPrint = out + end - isFinish := pb.isFinish - - switch { - case isFinish: - return - case pb.Output != nil: - fmt.Fprint(pb.Output, "\r"+out+end) - case pb.Callback != nil: - pb.Callback(out + end) - case !pb.NotPrint: - fmt.Print("\r" + out + end) - } -} - -// GetTerminalWidth - returns terminal width for all platforms. -func GetTerminalWidth() (int, error) { - return terminalWidth() -} - -func (pb *ProgressBar) GetWidth() int { - if pb.ForceWidth { - return pb.Width - } - - width := pb.Width - termWidth, _ := terminalWidth() - if width == 0 || termWidth <= width { - width = termWidth - } - - return width -} - -// Write the current state of the progressbar -func (pb *ProgressBar) Update() { - c := atomic.LoadInt64(&pb.current) - p := atomic.LoadInt64(&pb.previous) - t := atomic.LoadInt64(&pb.Total) - if p != c { - pb.mu.Lock() - pb.changeTime = time.Now() - pb.mu.Unlock() - atomic.StoreInt64(&pb.previous, c) - } - pb.write(t, c) - if pb.AutoStat { - if c == 0 { - pb.startTime = time.Now() - pb.startValue = 0 - } else if c >= t && pb.isFinish != true { - pb.Finish() - } - } -} - -// String return the last bar print -func (pb *ProgressBar) String() string { - pb.mu.Lock() - defer pb.mu.Unlock() - return pb.lastPrint -} - -// SetTotal atomically sets new total count -func (pb *ProgressBar) SetTotal(total int) *ProgressBar { - return pb.SetTotal64(int64(total)) -} - -// SetTotal64 atomically sets new total count -func (pb *ProgressBar) SetTotal64(total int64) *ProgressBar { - atomic.StoreInt64(&pb.Total, total) - return pb -} - -// Reset bar and set new total count -// Does effect only on finished bar -func (pb *ProgressBar) Reset(total int) *ProgressBar { - pb.mu.Lock() - defer pb.mu.Unlock() - if pb.isFinish { - pb.SetTotal(total).Set(0) - atomic.StoreInt64(&pb.previous, 0) - } - return pb -} - -// Internal loop for refreshing the progressbar -func (pb *ProgressBar) refresher() { - for { - select { - case <-pb.finish: - return - case <-time.After(pb.RefreshRate): - pb.Update() - } - } -} diff --git a/vendor/github.com/cheggaaa/pb/pb_appengine.go b/vendor/github.com/cheggaaa/pb/pb_appengine.go deleted file mode 100644 index 17168f3..0000000 --- a/vendor/github.com/cheggaaa/pb/pb_appengine.go +++ /dev/null @@ -1,11 +0,0 @@ -// +build appengine js - -package pb - -import "errors" - -// terminalWidth returns width of the terminal, which is not supported -// and should always failed on appengine classic which is a sandboxed PaaS. -func terminalWidth() (int, error) { - return 0, errors.New("Not supported") -} diff --git a/vendor/github.com/cheggaaa/pb/pb_plan9.go b/vendor/github.com/cheggaaa/pb/pb_plan9.go deleted file mode 100644 index 32e3b98..0000000 --- a/vendor/github.com/cheggaaa/pb/pb_plan9.go +++ /dev/null @@ -1,70 +0,0 @@ -package pb - -import ( - "errors" - "os" - "os/signal" - "sync" - "syscall" -) - -var ErrPoolWasStarted = errors.New("Bar pool was started") - -var ( - echoLockMutex sync.Mutex - consctl *os.File -) - -// terminalWidth returns width of the terminal. -func terminalWidth() (int, error) { - return 0, errors.New("Not Supported") -} - -func lockEcho() (shutdownCh chan struct{}, err error) { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - - if consctl != nil { - return nil, ErrPoolWasStarted - } - consctl, err = os.OpenFile("/dev/consctl", os.O_WRONLY, 0) - if err != nil { - return nil, err - } - _, err = consctl.WriteString("rawon") - if err != nil { - consctl.Close() - consctl = nil - return nil, err - } - shutdownCh = make(chan struct{}) - go catchTerminate(shutdownCh) - return -} - -func unlockEcho() error { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - - if consctl == nil { - return nil - } - if err := consctl.Close(); err != nil { - return err - } - consctl = nil - return nil -} - -// listen exit signals and restore terminal state -func catchTerminate(shutdownCh chan struct{}) { - sig := make(chan os.Signal, 1) - signal.Notify(sig, os.Interrupt, syscall.SIGTERM, syscall.SIGKILL) - defer signal.Stop(sig) - select { - case <-shutdownCh: - unlockEcho() - case <-sig: - unlockEcho() - } -} diff --git a/vendor/github.com/cheggaaa/pb/pb_test.go b/vendor/github.com/cheggaaa/pb/pb_test.go deleted file mode 100644 index 86d4ce6..0000000 --- a/vendor/github.com/cheggaaa/pb/pb_test.go +++ /dev/null @@ -1,154 +0,0 @@ -package pb - -import ( - "bytes" - "strings" - "sync" - "testing" - "time" - - "github.com/fatih/color" - "github.com/mattn/go-colorable" -) - -func Test_IncrementAddsOne(t *testing.T) { - count := 5000 - bar := New(count) - expected := 1 - actual := bar.Increment() - - if actual != expected { - t.Errorf("Expected {%d} was {%d}", expected, actual) - } -} - -func Test_Width(t *testing.T) { - count := 5000 - bar := New(count) - width := 100 - bar.SetWidth(100).Callback = func(out string) { - if len(out) != width { - t.Errorf("Bar width expected {%d} was {%d}", len(out), width) - } - } - bar.Start() - bar.Increment() - bar.Finish() -} - -func Test_MultipleFinish(t *testing.T) { - bar := New(5000) - bar.Add(2000) - bar.Finish() - bar.Finish() -} - -func TestWriteRace(t *testing.T) { - outBuffer := &bytes.Buffer{} - totalCount := 20 - bar := New(totalCount) - bar.Output = outBuffer - bar.Start() - var wg sync.WaitGroup - for i := 0; i < totalCount; i++ { - wg.Add(1) - go func() { - bar.Increment() - time.Sleep(250 * time.Millisecond) - wg.Done() - }() - } - wg.Wait() - bar.Finish() -} - -func Test_Format(t *testing.T) { - bar := New(5000).Format(strings.Join([]string{ - color.GreenString("["), - color.New(color.BgGreen).SprintFunc()("o"), - color.New(color.BgHiGreen).SprintFunc()("o"), - color.New(color.BgRed).SprintFunc()("o"), - color.GreenString("]"), - }, "\x00")) - w := colorable.NewColorableStdout() - bar.Callback = func(out string) { - w.Write([]byte(out)) - } - bar.Add(2000) - bar.Finish() - bar.Finish() -} - -func Test_MultiCharacter(t *testing.T) { - bar := New(5).Format(strings.Join([]string{"[[[", "---", ">>", "....", "]]"}, "\x00")) - bar.Start() - for i := 0; i < 5; i++ { - time.Sleep(500 * time.Millisecond) - bar.Increment() - } - - time.Sleep(500 * time.Millisecond) - bar.Finish() -} - -func Test_AutoStat(t *testing.T) { - bar := New(5) - bar.AutoStat = true - bar.Start() - time.Sleep(2 * time.Second) - //real start work - for i := 0; i < 5; i++ { - time.Sleep(500 * time.Millisecond) - bar.Increment() - } - //real finish work - time.Sleep(2 * time.Second) - bar.Finish() -} - -func Test_Finish_PrintNewline(t *testing.T) { - bar := New(5) - buf := &bytes.Buffer{} - bar.Output = buf - bar.Finish() - - expected := "\n" - actual := buf.String() - //Finish should write newline to bar.Output - if !strings.HasSuffix(actual, expected) { - t.Errorf("Expected %q to have suffix %q", expected, actual) - } -} - -func Test_FinishPrint(t *testing.T) { - bar := New(5) - buf := &bytes.Buffer{} - bar.Output = buf - bar.FinishPrint("foo") - - expected := "foo\n" - actual := buf.String() - //FinishPrint should write to bar.Output - if !strings.HasSuffix(actual, expected) { - t.Errorf("Expected %q to have suffix %q", expected, actual) - } -} - -func Test_Reset(t *testing.T) { - bar := StartNew(5) - for i := 0; i < 5; i++ { - bar.Increment() - } - if actual := bar.Get(); actual != 5 { - t.Errorf("Expected: %d; actual: %d", 5, actual) - } - bar.Finish() - bar.Reset(10).Start() - defer bar.Finish() - if actual := bar.Get(); actual != 0 { - t.Errorf("Expected: %d; actual: %d", 0, actual) - } - if actual := bar.Total; actual != 10 { - t.Errorf("Expected: %d; actual: %d", 10, actual) - } -} diff --git a/vendor/github.com/cheggaaa/pb/pb_win.go b/vendor/github.com/cheggaaa/pb/pb_win.go deleted file mode 100644 index 9595e82..0000000 --- a/vendor/github.com/cheggaaa/pb/pb_win.go +++ /dev/null @@ -1,143 +0,0 @@ -// +build windows - -package pb - -import ( - "errors" - "fmt" - "os" - "sync" - "syscall" - "unsafe" -) - -var tty = os.Stdin - -var ( - kernel32 = syscall.NewLazyDLL("kernel32.dll") - - // GetConsoleScreenBufferInfo retrieves information about the - // specified console screen buffer. - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms683171(v=vs.85).aspx - procGetConsoleScreenBufferInfo = kernel32.NewProc("GetConsoleScreenBufferInfo") - - // GetConsoleMode retrieves the current input mode of a console's - // input buffer or the current output mode of a console screen buffer. - // https://msdn.microsoft.com/en-us/library/windows/desktop/ms683167(v=vs.85).aspx - getConsoleMode = kernel32.NewProc("GetConsoleMode") - - // SetConsoleMode sets the input mode of a console's input buffer - // or the output mode of a console screen buffer. - // https://msdn.microsoft.com/en-us/library/windows/desktop/ms686033(v=vs.85).aspx - setConsoleMode = kernel32.NewProc("SetConsoleMode") - - // SetConsoleCursorPosition sets the cursor position in the - // specified console screen buffer. - // https://msdn.microsoft.com/en-us/library/windows/desktop/ms686025(v=vs.85).aspx - setConsoleCursorPosition = kernel32.NewProc("SetConsoleCursorPosition") -) - -type ( - // Defines the coordinates of the upper left and lower right corners - // of a rectangle. - // See - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms686311(v=vs.85).aspx - smallRect struct { - Left, Top, Right, Bottom int16 - } - - // Defines the coordinates of a character cell in a console screen - // buffer. The origin of the coordinate system (0,0) is at the top, left cell - // of the buffer. - // See - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms682119(v=vs.85).aspx - coordinates struct { - X, Y int16 - } - - word int16 - - // Contains information about a console screen buffer. - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms682093(v=vs.85).aspx - consoleScreenBufferInfo struct { - dwSize coordinates - dwCursorPosition coordinates - wAttributes word - srWindow smallRect - dwMaximumWindowSize coordinates - } -) - -// terminalWidth returns width of the terminal. -func terminalWidth() (width int, err error) { - var info consoleScreenBufferInfo - _, _, e := syscall.Syscall(procGetConsoleScreenBufferInfo.Addr(), 2, uintptr(syscall.Stdout), uintptr(unsafe.Pointer(&info)), 0) - if e != 0 { - return 0, error(e) - } - return int(info.dwSize.X) - 1, nil -} - -func getCursorPos() (pos coordinates, err error) { - var info consoleScreenBufferInfo - _, _, e := syscall.Syscall(procGetConsoleScreenBufferInfo.Addr(), 2, uintptr(syscall.Stdout), uintptr(unsafe.Pointer(&info)), 0) - if e != 0 { - return info.dwCursorPosition, error(e) - } - return info.dwCursorPosition, nil -} - -func setCursorPos(pos coordinates) error { - _, _, e := syscall.Syscall(setConsoleCursorPosition.Addr(), 2, uintptr(syscall.Stdout), uintptr(uint32(uint16(pos.Y))<<16|uint32(uint16(pos.X))), 0) - if e != 0 { - return error(e) - } - return nil -} - -var ErrPoolWasStarted = errors.New("Bar pool was started") - -var echoLocked bool -var echoLockMutex sync.Mutex - -var oldState word - -func lockEcho() (shutdownCh chan struct{}, err error) { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - if echoLocked { - err = ErrPoolWasStarted - return - } - echoLocked = true - - if _, _, e := syscall.Syscall(getConsoleMode.Addr(), 2, uintptr(syscall.Stdout), uintptr(unsafe.Pointer(&oldState)), 0); e != 0 { - err = fmt.Errorf("Can't get terminal settings: %v", e) - return - } - - newState := oldState - const ENABLE_ECHO_INPUT = 0x0004 - const ENABLE_LINE_INPUT = 0x0002 - newState = newState & (^(ENABLE_LINE_INPUT | ENABLE_ECHO_INPUT)) - if _, _, e := syscall.Syscall(setConsoleMode.Addr(), 2, uintptr(syscall.Stdout), uintptr(newState), 0); e != 0 { - err = fmt.Errorf("Can't set terminal settings: %v", e) - return - } - - shutdownCh = make(chan struct{}) - return -} - -func unlockEcho() (err error) { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - if !echoLocked { - return - } - echoLocked = false - if _, _, e := syscall.Syscall(setConsoleMode.Addr(), 2, uintptr(syscall.Stdout), uintptr(oldState), 0); e != 0 { - err = fmt.Errorf("Can't set terminal settings") - } - return -} diff --git a/vendor/github.com/cheggaaa/pb/pb_x.go b/vendor/github.com/cheggaaa/pb/pb_x.go deleted file mode 100644 index af42517..0000000 --- a/vendor/github.com/cheggaaa/pb/pb_x.go +++ /dev/null @@ -1,118 +0,0 @@ -// +build linux darwin freebsd netbsd openbsd solaris dragonfly -// +build !appengine !js - -package pb - -import ( - "errors" - "fmt" - "os" - "os/signal" - "sync" - "syscall" - - "golang.org/x/sys/unix" -) - -var ErrPoolWasStarted = errors.New("Bar pool was started") - -var ( - echoLockMutex sync.Mutex - origTermStatePtr *unix.Termios - tty *os.File - istty bool -) - -func init() { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - - var err error - tty, err = os.Open("/dev/tty") - istty = true - if err != nil { - tty = os.Stdin - istty = false - } -} - -// terminalWidth returns width of the terminal. -func terminalWidth() (int, error) { - if !istty { - return 0, errors.New("Not Supported") - } - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - - fd := int(tty.Fd()) - - ws, err := unix.IoctlGetWinsize(fd, unix.TIOCGWINSZ) - if err != nil { - return 0, err - } - - return int(ws.Col), nil -} - -func lockEcho() (shutdownCh chan struct{}, err error) { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - if istty { - if origTermStatePtr != nil { - return shutdownCh, ErrPoolWasStarted - } - - fd := int(tty.Fd()) - - origTermStatePtr, err = unix.IoctlGetTermios(fd, ioctlReadTermios) - if err != nil { - return nil, fmt.Errorf("Can't get terminal settings: %v", err) - } - - oldTermios := *origTermStatePtr - newTermios := oldTermios - newTermios.Lflag &^= syscall.ECHO - newTermios.Lflag |= syscall.ICANON | syscall.ISIG - newTermios.Iflag |= syscall.ICRNL - if err := unix.IoctlSetTermios(fd, ioctlWriteTermios, &newTermios); err != nil { - return nil, fmt.Errorf("Can't set terminal settings: %v", err) - } - - } - shutdownCh = make(chan struct{}) - go catchTerminate(shutdownCh) - return -} - -func unlockEcho() error { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - if istty { - if origTermStatePtr == nil { - return nil - } - - fd := int(tty.Fd()) - - if err := unix.IoctlSetTermios(fd, ioctlWriteTermios, origTermStatePtr); err != nil { - return fmt.Errorf("Can't set terminal settings: %v", err) - } - - } - origTermStatePtr = nil - - return nil -} - -// listen exit signals and restore terminal state -func catchTerminate(shutdownCh chan struct{}) { - sig := make(chan os.Signal, 1) - signal.Notify(sig, os.Interrupt, syscall.SIGQUIT, syscall.SIGTERM, syscall.SIGKILL) - defer signal.Stop(sig) - select { - case <-shutdownCh: - unlockEcho() - case <-sig: - unlockEcho() - } -} diff --git a/vendor/github.com/cheggaaa/pb/pool.go b/vendor/github.com/cheggaaa/pb/pool.go deleted file mode 100644 index 861d787..0000000 --- a/vendor/github.com/cheggaaa/pb/pool.go +++ /dev/null @@ -1,104 +0,0 @@ -// +build linux darwin freebsd netbsd openbsd solaris dragonfly windows plan9 - -package pb - -import ( - "io" - "sync" - "time" -) - -// Create and start new pool with given bars -// You need call pool.Stop() after work -func StartPool(pbs ...*ProgressBar) (pool *Pool, err error) { - pool = new(Pool) - if err = pool.Start(); err != nil { - return - } - pool.Add(pbs...) - return -} - -// NewPool initialises a pool with progress bars, but -// doesn't start it. You need to call Start manually -func NewPool(pbs ...*ProgressBar) (pool *Pool) { - pool = new(Pool) - pool.Add(pbs...) - return -} - -type Pool struct { - Output io.Writer - RefreshRate time.Duration - bars []*ProgressBar - lastBarsCount int - shutdownCh chan struct{} - workerCh chan struct{} - m sync.Mutex - finishOnce sync.Once -} - -// Add progress bars. -func (p *Pool) Add(pbs ...*ProgressBar) { - p.m.Lock() - defer p.m.Unlock() - for _, bar := range pbs { - bar.ManualUpdate = true - bar.NotPrint = true - bar.Start() - p.bars = append(p.bars, bar) - } -} - -func (p *Pool) Start() (err error) { - p.RefreshRate = DefaultRefreshRate - p.shutdownCh, err = lockEcho() - if err != nil { - return - } - p.workerCh = make(chan struct{}) - go p.writer() - return -} - -func (p *Pool) writer() { - var first = true - defer func() { - if first == false { - p.print(false) - } else { - p.print(true) - p.print(false) - } - close(p.workerCh) - }() - - for { - select { - case <-time.After(p.RefreshRate): - if p.print(first) { - p.print(false) - return - } - first = false - case <-p.shutdownCh: - return - } - } -} - -// Restore terminal state and close pool -func (p *Pool) Stop() error { - p.finishOnce.Do(func() { - if p.shutdownCh != nil { - close(p.shutdownCh) - } - }) - - // Wait for the worker to complete - select { - case <-p.workerCh: - } - - return unlockEcho() -} diff --git a/vendor/github.com/cheggaaa/pb/pool_win.go b/vendor/github.com/cheggaaa/pb/pool_win.go deleted file mode 100644 index 63598d3..0000000 --- a/vendor/github.com/cheggaaa/pb/pool_win.go +++ /dev/null @@ -1,45 +0,0 @@ -// +build windows - -package pb - -import ( - "fmt" - "log" -) - -func (p *Pool) print(first bool) bool { - p.m.Lock() - defer p.m.Unlock() - var out string - if !first { - coords, err := getCursorPos() - if err != nil { - log.Panic(err) - } - coords.Y -= int16(p.lastBarsCount) - if coords.Y < 0 { - coords.Y = 0 - } - coords.X = 0 - - err = setCursorPos(coords) - if err != nil { - log.Panic(err) - } - } - isFinished := true - for _, bar := range p.bars { - if !bar.IsFinished() { - isFinished = false - } - bar.Update() - out += fmt.Sprintf("\r%s\n", bar.String()) - } - if p.Output != nil { - fmt.Fprint(p.Output, out) - } else { - fmt.Print(out) - } - p.lastBarsCount = len(p.bars) - return isFinished -} diff --git a/vendor/github.com/cheggaaa/pb/pool_x.go b/vendor/github.com/cheggaaa/pb/pool_x.go deleted file mode 100644 index 3d4ed94..0000000 --- a/vendor/github.com/cheggaaa/pb/pool_x.go +++ /dev/null @@ -1,29 +0,0 @@ -// +build linux darwin freebsd netbsd openbsd solaris dragonfly plan9 - -package pb - -import "fmt" - -func (p *Pool) print(first bool) bool { - p.m.Lock() - defer p.m.Unlock() - var out string - if !first { - out = fmt.Sprintf("\033[%dA", p.lastBarsCount) - } - isFinished := true - for _, bar := range p.bars { - if !bar.IsFinished() { - isFinished = false - } - bar.Update() - out += fmt.Sprintf("\r%s\n", bar.String()) - } - if p.Output != nil { - fmt.Fprint(p.Output, out) - } else { - fmt.Print(out) - } - p.lastBarsCount = len(p.bars) - return isFinished -} diff --git a/vendor/github.com/cheggaaa/pb/reader.go b/vendor/github.com/cheggaaa/pb/reader.go deleted file mode 100644 index 9562e94..0000000 --- a/vendor/github.com/cheggaaa/pb/reader.go +++ /dev/null @@ -1,26 +0,0 @@ -package pb - -import ( - "io" -) - -// It's proxy reader, implement io.Reader -type Reader struct { - io.Reader - bar *ProgressBar -} - -func (r *Reader) Read(p []byte) (n int, err error) { - n, err = r.Reader.Read(p) - r.bar.Add(n) - return -} - -// Close the reader when it implements io.Closer -func (r *Reader) Close() (err error) { - r.bar.Finish() - if closer, ok := r.Reader.(io.Closer); ok { - return closer.Close() - } - return -} diff --git a/vendor/github.com/cheggaaa/pb/runecount.go b/vendor/github.com/cheggaaa/pb/runecount.go deleted file mode 100644 index c617c55..0000000 --- a/vendor/github.com/cheggaaa/pb/runecount.go +++ /dev/null @@ -1,17 +0,0 @@ -package pb - -import ( - "github.com/mattn/go-runewidth" - "regexp" -) - -// Finds the control character sequences (like colors) -var ctrlFinder = regexp.MustCompile("\x1b\x5b[0-9]+\x6d") - -func escapeAwareRuneCountInString(s string) int { - n := runewidth.StringWidth(s) - for _, sm := range ctrlFinder.FindAllString(s, -1) { - n -= runewidth.StringWidth(sm) - } - return n -} diff --git a/vendor/github.com/cheggaaa/pb/runecount_test.go b/vendor/github.com/cheggaaa/pb/runecount_test.go deleted file mode 100644 index d23f511..0000000 --- a/vendor/github.com/cheggaaa/pb/runecount_test.go +++ /dev/null @@ -1,20 +0,0 @@ -package pb - -import "testing" - -func Test_RuneCount(t *testing.T) { - s := string([]byte{ - 27, 91, 51, 49, 109, // {Red} - 72, 101, 108, 108, 111, // Hello - 44, 32, // , - 112, 108, 97, 121, 103, 114, 111, 117, 110, 100, // Playground - 27, 91, 48, 109, // {Reset} - }) - if e, l := 17, escapeAwareRuneCountInString(s); l != e { - t.Errorf("Invalid length %d, expected %d", l, e) - } - s = "進捗 " - if e, l := 5, escapeAwareRuneCountInString(s); l != e { - t.Errorf("Invalid length %d, expected %d", l, e) - } -} diff --git a/vendor/github.com/cheggaaa/pb/termios_bsd.go b/vendor/github.com/cheggaaa/pb/termios_bsd.go deleted file mode 100644 index 517ea8e..0000000 --- a/vendor/github.com/cheggaaa/pb/termios_bsd.go +++ /dev/null @@ -1,9 +0,0 @@ -// +build darwin freebsd netbsd openbsd dragonfly -// +build !appengine - -package pb - -import "syscall" - -const ioctlReadTermios = syscall.TIOCGETA -const ioctlWriteTermios = syscall.TIOCSETA diff --git a/vendor/github.com/cheggaaa/pb/termios_sysv.go b/vendor/github.com/cheggaaa/pb/termios_sysv.go deleted file mode 100644 index b10f618..0000000 --- a/vendor/github.com/cheggaaa/pb/termios_sysv.go +++ /dev/null @@ -1,13 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build linux solaris -// +build !appengine - -package pb - -import "golang.org/x/sys/unix" - -const ioctlReadTermios = unix.TCGETS -const ioctlWriteTermios = unix.TCSETS diff --git a/vendor/github.com/cheggaaa/pb/v3/LICENSE b/vendor/github.com/cheggaaa/pb/v3/LICENSE deleted file mode 100644 index 5119703..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/LICENSE +++ /dev/null @@ -1,12 +0,0 @@ -Copyright (c) 2012-2015, Sergey Cherepanov -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - -* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - -* Neither the name of the author nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \ No newline at end of file diff --git a/vendor/github.com/cheggaaa/pb/v3/element.go b/vendor/github.com/cheggaaa/pb/v3/element.go deleted file mode 100644 index 965183f..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/element.go +++ /dev/null @@ -1,290 +0,0 @@ -package pb - -import ( - "bytes" - "fmt" - "math" - "sync" - "time" -) - -const ( - adElPlaceholder = "%_ad_el_%" - adElPlaceholderLen = len(adElPlaceholder) -) - -var ( - defaultBarEls = [5]string{"[", "-", ">", "_", "]"} -) - -// Element is an interface for bar elements -type Element interface { - ProgressElement(state *State, args ...string) string -} - -// ElementFunc type implements Element interface and created for simplify elements -type ElementFunc func(state *State, args ...string) string - -// ProgressElement just call self func -func (e ElementFunc) ProgressElement(state *State, args ...string) string { - return e(state, args...) -} - -var elementsM sync.Mutex - -var elements = map[string]Element{ - "percent": ElementPercent, - "counters": ElementCounters, - "bar": adaptiveWrap(ElementBar), - "speed": ElementSpeed, - "rtime": ElementRemainingTime, - "etime": ElementElapsedTime, - "string": ElementString, - "cycle": ElementCycle, -} - -// RegisterElement give you a chance to use custom elements -func RegisterElement(name string, el Element, adaptive bool) { - if adaptive { - el = adaptiveWrap(el) - } - elementsM.Lock() - elements[name] = el - elementsM.Unlock() -} - -type argsHelper []string - -func (args argsHelper) getOr(n int, value string) string { - if len(args) > n { - return args[n] - } - return value -} - -func (args argsHelper) getNotEmptyOr(n int, value string) (v string) { - if v = args.getOr(n, value); v == "" { - return value - } - return -} - -func adaptiveWrap(el Element) Element { - return ElementFunc(func(state *State, args ...string) string { - state.recalc = append(state.recalc, ElementFunc(func(s *State, _ ...string) (result string) { - s.adaptive = true - result = el.ProgressElement(s, args...) - s.adaptive = false - return - })) - return adElPlaceholder - }) -} - -// ElementPercent shows current percent of progress. -// Optionally can take one or two string arguments. -// First string will be used as value for format float64, default is "%.02f%%". -// Second string will be used when percent can't be calculated, default is "?%" -// In template use as follows: {{percent .}} or {{percent . "%.03f%%"}} or {{percent . "%.03f%%" "?"}} -var ElementPercent ElementFunc = func(state *State, args ...string) string { - argsh := argsHelper(args) - if state.Total() > 0 { - return fmt.Sprintf( - argsh.getNotEmptyOr(0, "%.02f%%"), - float64(state.Value())/(float64(state.Total())/float64(100)), - ) - } - return argsh.getOr(1, "?%") -} - -// ElementCounters shows current and total values. -// Optionally can take one or two string arguments. -// First string will be used as format value when Total is present (>0). Default is "%s / %s" -// Second string will be used when total <= 0. Default is "%[1]s" -// In template use as follows: {{counters .}} or {{counters . "%s/%s"}} or {{counters . "%s/%s" "%s/?"}} -var ElementCounters ElementFunc = func(state *State, args ...string) string { - var f string - if state.Total() > 0 { - f = argsHelper(args).getNotEmptyOr(0, "%s / %s") - } else { - f = argsHelper(args).getNotEmptyOr(1, "%[1]s") - } - return fmt.Sprintf(f, state.Format(state.Value()), state.Format(state.Total())) -} - -type elementKey int - -const ( - barObj elementKey = iota - speedObj - cycleObj -) - -type bar struct { - eb [5][]byte // elements in bytes - cc [5]int // cell counts - buf *bytes.Buffer -} - -func (p *bar) write(state *State, eln, width int) int { - repeat := width / p.cc[eln] - for i := 0; i < repeat; i++ { - p.buf.Write(p.eb[eln]) - } - StripStringToBuffer(string(p.eb[eln]), width%p.cc[eln], p.buf) - return width -} - -func getProgressObj(state *State, args ...string) (p *bar) { - var ok bool - if p, ok = state.Get(barObj).(*bar); !ok { - p = &bar{ - buf: bytes.NewBuffer(nil), - } - state.Set(barObj, p) - } - argsH := argsHelper(args) - for i := range p.eb { - arg := argsH.getNotEmptyOr(i, defaultBarEls[i]) - if string(p.eb[i]) != arg { - p.cc[i] = CellCount(arg) - p.eb[i] = []byte(arg) - if p.cc[i] == 0 { - p.cc[i] = 1 - p.eb[i] = []byte(" ") - } - } - } - return -} - -// ElementBar make progress bar view [-->__] -// Optionally can take up to 5 string arguments. Defaults is "[", "-", ">", "_", "]" -// In template use as follows: {{bar . }} or {{bar . "<" "oOo" "|" "~" ">"}} -// Color args: {{bar . (red "[") (green "-") ... -var ElementBar ElementFunc = func(state *State, args ...string) string { - // init - var p = getProgressObj(state, args...) - - total, value := state.Total(), state.Value() - if total < 0 { - total = -total - } - if value < 0 { - value = -value - } - - // check for overflow - if total != 0 && value > total { - total = value - } - - p.buf.Reset() - - var widthLeft = state.AdaptiveElWidth() - if widthLeft <= 0 || !state.IsAdaptiveWidth() { - widthLeft = 30 - } - - // write left border - if p.cc[0] < widthLeft { - widthLeft -= p.write(state, 0, p.cc[0]) - } else { - p.write(state, 0, widthLeft) - return p.buf.String() - } - - // check right border size - if p.cc[4] < widthLeft { - // write later - widthLeft -= p.cc[4] - } else { - p.write(state, 4, widthLeft) - return p.buf.String() - } - - var curCount int - - if total > 0 { - // calculate count of currenct space - curCount = int(math.Ceil((float64(value) / float64(total)) * float64(widthLeft))) - } - - // write bar - if total == value && state.IsFinished() { - widthLeft -= p.write(state, 1, curCount) - } else if toWrite := curCount - p.cc[2]; toWrite > 0 { - widthLeft -= p.write(state, 1, toWrite) - widthLeft -= p.write(state, 2, p.cc[2]) - } else if curCount > 0 { - widthLeft -= p.write(state, 2, curCount) - } - if widthLeft > 0 { - widthLeft -= p.write(state, 3, widthLeft) - } - // write right border - p.write(state, 4, p.cc[4]) - // cut result and return string - return p.buf.String() -} - -// ElementRemainingTime calculates remaining time based on speed (EWMA) -// Optionally can take one or two string arguments. -// First string will be used as value for format time duration string, default is "%s". -// Second string will be used when bar finished and value indicates elapsed time, default is "%s" -// Third string will be used when value not available, default is "?" -// In template use as follows: {{rtime .}} or {{rtime . "%s remain"}} or {{rtime . "%s remain" "%s total" "???"}} -var ElementRemainingTime ElementFunc = func(state *State, args ...string) string { - var rts string - sp := getSpeedObj(state).value(state) - if !state.IsFinished() { - if sp > 0 { - remain := float64(state.Total() - state.Value()) - remainDur := time.Duration(remain/sp) * time.Second - rts = remainDur.String() - } else { - return argsHelper(args).getOr(2, "?") - } - } else { - rts = state.Time().Truncate(time.Second).Sub(state.StartTime().Truncate(time.Second)).String() - return fmt.Sprintf(argsHelper(args).getOr(1, "%s"), rts) - } - return fmt.Sprintf(argsHelper(args).getOr(0, "%s"), rts) -} - -// ElementElapsedTime shows elapsed time -// Optionally cat take one argument - it's format for time string. -// In template use as follows: {{etime .}} or {{etime . "%s elapsed"}} -var ElementElapsedTime ElementFunc = func(state *State, args ...string) string { - etm := state.Time().Truncate(time.Second).Sub(state.StartTime().Truncate(time.Second)) - return fmt.Sprintf(argsHelper(args).getOr(0, "%s"), etm.String()) -} - -// ElementString get value from bar by given key and print them -// bar.Set("myKey", "string to print") -// In template use as follows: {{string . "myKey"}} -var ElementString ElementFunc = func(state *State, args ...string) string { - if len(args) == 0 { - return "" - } - v := state.Get(args[0]) - if v == nil { - return "" - } - return fmt.Sprint(v) -} - -// ElementCycle return next argument for every call -// In template use as follows: {{cycle . "1" "2" "3"}} -// Or mix width other elements: {{ bar . "" "" (cycle . "↖" "↗" "↘" "↙" )}} -var ElementCycle ElementFunc = func(state *State, args ...string) string { - if len(args) == 0 { - return "" - } - n, _ := state.Get(cycleObj).(int) - if n >= len(args) { - n = 0 - } - state.Set(cycleObj, n+1) - return args[n] -} diff --git a/vendor/github.com/cheggaaa/pb/v3/element_test.go b/vendor/github.com/cheggaaa/pb/v3/element_test.go deleted file mode 100644 index d5c5cfd..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/element_test.go +++ /dev/null @@ -1,278 +0,0 @@ -package pb - -import ( - "fmt" - "strings" - "testing" - "time" - - "github.com/fatih/color" -) - -func testState(total, value int64, maxWidth int, bools ...bool) (s *State) { - s = &State{ - total: total, - current: value, - adaptiveElWidth: maxWidth, - ProgressBar: new(ProgressBar), - } - if len(bools) > 0 { - s.Set(Bytes, bools[0]) - } - if len(bools) > 1 && bools[1] { - s.adaptive = true - } - return -} - -func testElementBarString(t *testing.T, state *State, el Element, want string, args ...string) { - if state.ProgressBar == nil { - state.ProgressBar = new(ProgressBar) - } - res := el.ProgressElement(state, args...) - if res != want { - t.Errorf("Unexpected result: '%s'; want: '%s'", res, want) - } - if state.IsAdaptiveWidth() && state.AdaptiveElWidth() != CellCount(res) { - t.Errorf("Unepected width: %d; want: %d", CellCount(res), state.AdaptiveElWidth()) - } -} - -func TestElementPercent(t *testing.T) { - testElementBarString(t, testState(100, 50, 0), ElementPercent, "50.00%") - testElementBarString(t, testState(100, 50, 0), ElementPercent, "50 percent", "%v percent") - testElementBarString(t, testState(0, 50, 0), ElementPercent, "?%") - testElementBarString(t, testState(0, 50, 0), ElementPercent, "unkn", "%v%%", "unkn") -} - -func TestElementCounters(t *testing.T) { - testElementBarString(t, testState(100, 50, 0), ElementCounters, "50 / 100") - testElementBarString(t, testState(100, 50, 0), ElementCounters, "50 of 100", "%s of %s") - testElementBarString(t, testState(100, 50, 0, true), ElementCounters, "50 B of 100 B", "%s of %s") - testElementBarString(t, testState(100, 50, 0, true), ElementCounters, "50 B / 100 B") - testElementBarString(t, testState(0, 50, 0, true), ElementCounters, "50 B") - testElementBarString(t, testState(0, 50, 0, true), ElementCounters, "50 B / ?", "", "%[1]s / ?") -} - -func TestElementBar(t *testing.T) { - // short - testElementBarString(t, testState(100, 50, 1, false, true), ElementBar, "[") - testElementBarString(t, testState(100, 50, 2, false, true), ElementBar, "[]") - testElementBarString(t, testState(100, 50, 3, false, true), ElementBar, "[>]") - testElementBarString(t, testState(100, 50, 4, false, true), ElementBar, "[>_]") - testElementBarString(t, testState(100, 50, 5, false, true), ElementBar, "[->_]") - // middle - testElementBarString(t, testState(100, 50, 10, false, true), ElementBar, "[--->____]") - testElementBarString(t, testState(100, 50, 10, false, true), ElementBar, "<--->____>", "<", "", "", "", ">") - // finished - st := testState(100, 100, 10, false, true) - st.finished = true - testElementBarString(t, st, ElementBar, "[--------]") - // empty color - st = testState(100, 50, 10, false, true) - st.Set(Terminal, true) - color.NoColor = false - testElementBarString(t, st, ElementBar, " --->____]", color.RedString("%s", "")) - // empty - testElementBarString(t, testState(0, 50, 10, false, true), ElementBar, "[________]") - // full - testElementBarString(t, testState(20, 20, 10, false, true), ElementBar, "[------->]") - // everflow - testElementBarString(t, testState(20, 50, 10, false, true), ElementBar, "[------->]") - // small width - testElementBarString(t, testState(20, 50, 2, false, true), ElementBar, "[]") - testElementBarString(t, testState(20, 50, 1, false, true), ElementBar, "[") - // negative counters - testElementBarString(t, testState(-50, -150, 10, false, true), ElementBar, "[------->]") - testElementBarString(t, testState(-150, -50, 10, false, true), ElementBar, "[-->_____]") - testElementBarString(t, testState(50, -150, 10, false, true), ElementBar, "[------->]") - testElementBarString(t, testState(-50, 150, 10, false, true), ElementBar, "[------->]") - // long entities / unicode - f1 := []string{"進捗|", "многобайт", "active", "пусто", "|end"} - testElementBarString(t, testState(100, 50, 1, false, true), ElementBar, " ", f1...) - testElementBarString(t, testState(100, 50, 3, false, true), ElementBar, "進 ", f1...) - testElementBarString(t, testState(100, 50, 4, false, true), ElementBar, "進捗", f1...) - testElementBarString(t, testState(100, 50, 29, false, true), ElementBar, "進捗|многactiveпустопусто|end", f1...) - testElementBarString(t, testState(100, 50, 11, false, true), ElementBar, "進捗|aп|end", f1...) - - // unicode - f2 := []string{"⚑", ".", ">", "⟞", "⚐"} - testElementBarString(t, testState(100, 50, 8, false, true), ElementBar, "⚑..>⟞⟞⟞⚐", f2...) - - // no adaptive - testElementBarString(t, testState(0, 50, 10), ElementBar, "[____________________________]") - - var formats = [][]string{ - []string{}, - f1, f2, - } - - // all widths / extreme values - // check for panic and correct width - for _, f := range formats { - for tt := int64(-2); tt < 12; tt++ { - for v := int64(-2); v < 12; v++ { - state := testState(tt, v, 0, false, true) - for w := -2; w < 20; w++ { - state.adaptiveElWidth = w - res := ElementBar(state, f...) - var we = w - if we <= 0 { - we = 30 - } - if CellCount(res) != we { - t.Errorf("Unexpected len(%d): '%s'", we, res) - } - } - } - } - } -} - -func TestElementSpeed(t *testing.T) { - var state = testState(1000, 0, 0, false) - state.time = time.Now() - for i := int64(0); i < 10; i++ { - state.id = uint64(i) + 1 - state.current += 42 - state.time = state.time.Add(time.Second) - state.finished = i == 9 - if state.finished { - state.current += 100 - } - r := ElementSpeed(state) - r2 := ElementSpeed(state) - if r != r2 { - t.Errorf("Must be the same: '%s' vs '%s'", r, r2) - } - if i < 1 { - // do not calc first result - if w := "? p/s"; r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - } else if state.finished { - if w := "58 p/s"; r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - state.time = state.time.Add(-time.Hour) - r = ElementSpeed(state) - if w := "? p/s"; r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - } else { - if w := "42 p/s"; r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - } - } -} - -func TestElementRemainingTime(t *testing.T) { - var state = testState(100, 0, 0, false) - state.time = time.Now() - state.startTime = state.time - for i := int64(0); i < 10; i++ { - state.id = uint64(i) + 1 - state.time = state.time.Add(time.Second) - state.finished = i == 9 - r := ElementRemainingTime(state) - if i < 1 { - // do not calc first two results - if w := "?"; r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - } else if state.finished { - // final elapsed time - if w := "10s"; r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - } else { - w := fmt.Sprintf("%ds", 10-i) - if r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - } - state.current += 10 - } -} - -func TestElementElapsedTime(t *testing.T) { - var state = testState(1000, 0, 0, false) - state.startTime = time.Now() - state.time = state.startTime - for i := int64(0); i < 10; i++ { - r := ElementElapsedTime(state) - if w := fmt.Sprintf("%ds", i); r != w { - t.Errorf("Unexpected result[%d]: '%s' vs '%s'", i, r, w) - } - state.time = state.time.Add(time.Second) - } -} - -func TestElementString(t *testing.T) { - var state = testState(0, 0, 0, false) - testElementBarString(t, state, ElementString, "", "myKey") - state.Set("myKey", "my value") - testElementBarString(t, state, ElementString, "my value", "myKey") - state.Set("myKey", "my value1") - testElementBarString(t, state, ElementString, "my value1", "myKey") - testElementBarString(t, state, ElementString, "") -} - -func TestElementCycle(t *testing.T) { - var state = testState(0, 0, 0, false) - testElementBarString(t, state, ElementCycle, "") - testElementBarString(t, state, ElementCycle, "1", "1", "2", "3") - testElementBarString(t, state, ElementCycle, "2", "1", "2", "3") - testElementBarString(t, state, ElementCycle, "3", "1", "2", "3") - testElementBarString(t, state, ElementCycle, "1", "1", "2", "3") - testElementBarString(t, state, ElementCycle, "2", "1", "2") - testElementBarString(t, state, ElementCycle, "1", "1", "2") -} - -func TestAdaptiveWrap(t *testing.T) { - var state = testState(0, 0, 0, false) - state.id = 1 - state.Set("myKey", "my value") - el := adaptiveWrap(ElementString) - testElementBarString(t, state, el, adElPlaceholder, "myKey") - if v := state.recalc[0].ProgressElement(state); v != "my value" { - t.Errorf("Unexpected result: %s", v) - } - state.id = 2 - testElementBarString(t, state, el, adElPlaceholder, "myKey1") - state.Set("myKey", "my value1") - if v := state.recalc[0].ProgressElement(state); v != "my value1" { - t.Errorf("Unexpected result: %s", v) - } -} - -func TestRegisterElement(t *testing.T) { - var testEl ElementFunc = func(state *State, args ...string) string { - return strings.Repeat("*", state.AdaptiveElWidth()) - } - RegisterElement("testEl", testEl, true) - result := ProgressBarTemplate(`{{testEl . }}`).New(0).SetWidth(5).String() - if result != "*****" { - t.Errorf("Unexpected result: '%v'", result) - } -} - -func BenchmarkBar(b *testing.B) { - var formats = map[string][]string{ - "simple": []string{".", ".", ".", ".", "."}, - "unicode": []string{"⚑", "⚒", "⚟", "⟞", "⚐"}, - "color": []string{color.RedString("%s", "."), color.RedString("%s", "."), color.RedString("%s", "."), color.RedString("%s", "."), color.RedString("%s", ".")}, - "long": []string{"..", "..", "..", "..", ".."}, - "longunicode": []string{"⚑⚑", "⚒⚒", "⚟⚟", "⟞⟞", "⚐⚐"}, - } - for name, args := range formats { - state := testState(100, 50, 100, false, true) - b.Run(name, func(b *testing.B) { - b.ReportAllocs() - for i := 0; i < b.N; i++ { - ElementBar(state, args...) - } - }) - } -} diff --git a/vendor/github.com/cheggaaa/pb/v3/go.mod b/vendor/github.com/cheggaaa/pb/v3/go.mod deleted file mode 100644 index 666c86b..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/go.mod +++ /dev/null @@ -1,11 +0,0 @@ -module github.com/cheggaaa/pb/v3 - -require ( - github.com/VividCortex/ewma v1.1.1 - github.com/fatih/color v1.7.0 - github.com/mattn/go-colorable v0.1.2 - github.com/mattn/go-isatty v0.0.12 - github.com/mattn/go-runewidth v0.0.7 -) - -go 1.12 diff --git a/vendor/github.com/cheggaaa/pb/v3/go.sum b/vendor/github.com/cheggaaa/pb/v3/go.sum deleted file mode 100644 index 71cb183..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/go.sum +++ /dev/null @@ -1,21 +0,0 @@ -github.com/VividCortex/ewma v1.1.1 h1:MnEK4VOv6n0RSY4vtRe3h11qjxL3+t0B8yOL8iMXdcM= -github.com/VividCortex/ewma v1.1.1/go.mod h1:2Tkkvm3sRDVXaiyucHiACn4cqf7DpdyLvmxzcbUokwA= -github.com/fatih/color v1.7.0 h1:DkWD4oS2D8LGGgTQ6IvwJJXSL5Vp2ffcQg58nFV38Ys= -github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/mattn/go-colorable v0.1.2 h1:/bC9yWikZXAL9uJdulbSfyVNIR3n3trXl+v8+1sx8mU= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-isatty v0.0.8 h1:HLtExJ+uU2HOZ+wI0Tt5DtUDrx8yhUqDcp7fYERX4CE= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.10 h1:qxFzApOv4WsAL965uUPIsXzAKCZxN2p9UqdhFS4ZW10= -github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84= -github.com/mattn/go-isatty v0.0.12 h1:wuysRhFDzyxgEmMf5xjvJ2M9dZoWAXNNr5LSBS7uHXY= -github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= -github.com/mattn/go-runewidth v0.0.7 h1:Ei8KR0497xHyKJPAv59M1dkC+rOZCMBJ+t3fZ+twI54= -github.com/mattn/go-runewidth v0.0.7/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223 h1:DH4skfRX4EBpamg7iV4ZlCpblAHI6s6TDM39bFZumv8= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191128015809-6d18c012aee9 h1:ZBzSG/7F4eNKz2L3GE9o300RX0Az1Bw5HF7PDraD+qU= -golang.org/x/sys v0.0.0-20191128015809-6d18c012aee9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200116001909-b77594299b42 h1:vEOn+mP2zCOVzKckCZy6YsCtDblrpj/w7B9nxGNELpg= -golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= diff --git a/vendor/github.com/cheggaaa/pb/v3/io.go b/vendor/github.com/cheggaaa/pb/v3/io.go deleted file mode 100644 index 6ad5abc..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/io.go +++ /dev/null @@ -1,49 +0,0 @@ -package pb - -import ( - "io" -) - -// Reader it's a wrapper for given reader, but with progress handle -type Reader struct { - io.Reader - bar *ProgressBar -} - -// Read reads bytes from wrapped reader and add amount of bytes to progress bar -func (r *Reader) Read(p []byte) (n int, err error) { - n, err = r.Reader.Read(p) - r.bar.Add(n) - return -} - -// Close the wrapped reader when it implements io.Closer -func (r *Reader) Close() (err error) { - r.bar.Finish() - if closer, ok := r.Reader.(io.Closer); ok { - return closer.Close() - } - return -} - -// Writer it's a wrapper for given writer, but with progress handle -type Writer struct { - io.Writer - bar *ProgressBar -} - -// Write writes bytes to wrapped writer and add amount of bytes to progress bar -func (r *Writer) Write(p []byte) (n int, err error) { - n, err = r.Writer.Write(p) - r.bar.Add(n) - return -} - -// Close the wrapped reader when it implements io.Closer -func (r *Writer) Close() (err error) { - r.bar.Finish() - if closer, ok := r.Writer.(io.Closer); ok { - return closer.Close() - } - return -} diff --git a/vendor/github.com/cheggaaa/pb/v3/io_test.go b/vendor/github.com/cheggaaa/pb/v3/io_test.go deleted file mode 100644 index bfd8a06..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/io_test.go +++ /dev/null @@ -1,100 +0,0 @@ -package pb - -import ( - "testing" -) - -func TestPBProxyReader(t *testing.T) { - bar := new(ProgressBar) - if bar.GetBool(Bytes) { - t.Errorf("By default bytes must be false") - } - - testReader := new(testReaderWriterCloser) - proxyReader := bar.NewProxyReader(testReader) - - if !bar.GetBool(Bytes) { - t.Errorf("Bytes must be true after call NewProxyReader") - } - - for i := 0; i < 10; i++ { - buf := make([]byte, 10) - n, e := proxyReader.Read(buf) - if e != nil { - t.Errorf("Proxy reader return err: %v", e) - } - if n != len(buf) { - t.Errorf("Proxy reader return unexpected N: %d (wand %d)", n, len(buf)) - } - for _, b := range buf { - if b != 'f' { - t.Errorf("Unexpected read value: %v (want %v)", b, 'f') - } - } - if want := int64((i + 1) * len(buf)); bar.Current() != want { - t.Errorf("Unexpected bar current value: %d (want %d)", bar.Current(), want) - } - } - proxyReader.Close() - if !testReader.closed { - t.Errorf("Reader must be closed after call ProxyReader.Close") - } - proxyReader.Reader = nil - proxyReader.Close() -} - -func TestPBProxyWriter(t *testing.T) { - bar := new(ProgressBar) - if bar.GetBool(Bytes) { - t.Errorf("By default bytes must be false") - } - - testWriter := new(testReaderWriterCloser) - proxyReader := bar.NewProxyWriter(testWriter) - - if !bar.GetBool(Bytes) { - t.Errorf("Bytes must be true after call NewProxyReader") - } - - for i := 0; i < 10; i++ { - buf := make([]byte, 10) - n, e := proxyReader.Write(buf) - if e != nil { - t.Errorf("Proxy reader return err: %v", e) - } - if n != len(buf) { - t.Errorf("Proxy reader return unexpected N: %d (wand %d)", n, len(buf)) - } - if want := int64((i + 1) * len(buf)); bar.Current() != want { - t.Errorf("Unexpected bar current value: %d (want %d)", bar.Current(), want) - } - } - proxyReader.Close() - if !testWriter.closed { - t.Errorf("Reader must be closed after call ProxyReader.Close") - } - proxyReader.Writer = nil - proxyReader.Close() -} - -type testReaderWriterCloser struct { - closed bool - data []byte -} - -func (tr *testReaderWriterCloser) Read(p []byte) (n int, err error) { - for i := range p { - p[i] = 'f' - } - return len(p), nil -} - -func (tr *testReaderWriterCloser) Write(p []byte) (n int, err error) { - tr.data = append(tr.data, p...) - return len(p), nil -} - -func (tr *testReaderWriterCloser) Close() (err error) { - tr.closed = true - return -} diff --git a/vendor/github.com/cheggaaa/pb/v3/pb.go b/vendor/github.com/cheggaaa/pb/v3/pb.go deleted file mode 100644 index 17f3750..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/pb.go +++ /dev/null @@ -1,566 +0,0 @@ -package pb - -import ( - "bytes" - "fmt" - "io" - "os" - "strconv" - "strings" - "sync" - "sync/atomic" - "text/template" - "time" - - "github.com/mattn/go-colorable" - "github.com/mattn/go-isatty" - - "github.com/cheggaaa/pb/v3/termutil" -) - -// Version of ProgressBar library -const Version = "3.0.5" - -type key int - -const ( - // Bytes means we're working with byte sizes. Numbers will print as Kb, Mb, etc - // bar.Set(pb.Bytes, true) - Bytes key = 1 << iota - - // Use SI bytes prefix names (kB, MB, etc) instead of IEC prefix names (KiB, MiB, etc) - SIBytesPrefix - - // Terminal means we're will print to terminal and can use ascii sequences - // Also we're will try to use terminal width - Terminal - - // Static means progress bar will not update automaticly - Static - - // ReturnSymbol - by default in terminal mode it's '\r' - ReturnSymbol - - // Color by default is true when output is tty, but you can set to false for disabling colors - Color -) - -const ( - defaultBarWidth = 100 - defaultRefreshRate = time.Millisecond * 200 -) - -// New creates new ProgressBar object -func New(total int) *ProgressBar { - return New64(int64(total)) -} - -// New64 creates new ProgressBar object using int64 as total -func New64(total int64) *ProgressBar { - pb := new(ProgressBar) - return pb.SetTotal(total) -} - -// StartNew starts new ProgressBar with Default template -func StartNew(total int) *ProgressBar { - return New(total).Start() -} - -// Start64 starts new ProgressBar with Default template. Using int64 as total. -func Start64(total int64) *ProgressBar { - return New64(total).Start() -} - -var ( - terminalWidth = termutil.TerminalWidth - isTerminal = isatty.IsTerminal - isCygwinTerminal = isatty.IsCygwinTerminal -) - -// ProgressBar is the main object of bar -type ProgressBar struct { - current, total int64 - width int - maxWidth int - mu sync.RWMutex - rm sync.Mutex - vars map[interface{}]interface{} - elements map[string]Element - output io.Writer - coutput io.Writer - nocoutput io.Writer - startTime time.Time - refreshRate time.Duration - tmpl *template.Template - state *State - buf *bytes.Buffer - ticker *time.Ticker - finish chan struct{} - finished bool - configured bool - err error -} - -func (pb *ProgressBar) configure() { - if pb.configured { - return - } - pb.configured = true - - if pb.vars == nil { - pb.vars = make(map[interface{}]interface{}) - } - if pb.output == nil { - pb.output = os.Stderr - } - - if pb.tmpl == nil { - pb.tmpl, pb.err = getTemplate(string(Default)) - if pb.err != nil { - return - } - } - if pb.vars[Terminal] == nil { - if f, ok := pb.output.(*os.File); ok { - if isTerminal(f.Fd()) || isCygwinTerminal(f.Fd()) { - pb.vars[Terminal] = true - } - } - } - if pb.vars[ReturnSymbol] == nil { - if tm, ok := pb.vars[Terminal].(bool); ok && tm { - pb.vars[ReturnSymbol] = "\r" - } - } - if pb.vars[Color] == nil { - if tm, ok := pb.vars[Terminal].(bool); ok && tm { - pb.vars[Color] = true - } - } - if pb.refreshRate == 0 { - pb.refreshRate = defaultRefreshRate - } - if f, ok := pb.output.(*os.File); ok { - pb.coutput = colorable.NewColorable(f) - } else { - pb.coutput = pb.output - } - pb.nocoutput = colorable.NewNonColorable(pb.output) -} - -// Start starts the bar -func (pb *ProgressBar) Start() *ProgressBar { - pb.mu.Lock() - defer pb.mu.Unlock() - if pb.finish != nil { - return pb - } - pb.configure() - pb.finished = false - pb.state = nil - pb.startTime = time.Now() - if st, ok := pb.vars[Static].(bool); ok && st { - return pb - } - pb.finish = make(chan struct{}) - pb.ticker = time.NewTicker(pb.refreshRate) - go pb.writer(pb.finish) - return pb -} - -func (pb *ProgressBar) writer(finish chan struct{}) { - for { - select { - case <-pb.ticker.C: - pb.write(false) - case <-finish: - pb.ticker.Stop() - pb.write(true) - finish <- struct{}{} - return - } - } -} - -// Write performs write to the output -func (pb *ProgressBar) Write() *ProgressBar { - pb.mu.RLock() - finished := pb.finished - pb.mu.RUnlock() - pb.write(finished) - return pb -} - -func (pb *ProgressBar) write(finish bool) { - result, width := pb.render() - if pb.Err() != nil { - return - } - if pb.GetBool(Terminal) { - if r := (width - CellCount(result)); r > 0 { - result += strings.Repeat(" ", r) - } - } - if ret, ok := pb.Get(ReturnSymbol).(string); ok { - result = ret + result - if finish && ret == "\r" { - result += "\n" - } - } - if pb.GetBool(Color) { - pb.coutput.Write([]byte(result)) - } else { - pb.nocoutput.Write([]byte(result)) - } -} - -// Total return current total bar value -func (pb *ProgressBar) Total() int64 { - return atomic.LoadInt64(&pb.total) -} - -// SetTotal sets the total bar value -func (pb *ProgressBar) SetTotal(value int64) *ProgressBar { - atomic.StoreInt64(&pb.total, value) - return pb -} - -// SetCurrent sets the current bar value -func (pb *ProgressBar) SetCurrent(value int64) *ProgressBar { - atomic.StoreInt64(&pb.current, value) - return pb -} - -// Current return current bar value -func (pb *ProgressBar) Current() int64 { - return atomic.LoadInt64(&pb.current) -} - -// Add adding given int64 value to bar value -func (pb *ProgressBar) Add64(value int64) *ProgressBar { - atomic.AddInt64(&pb.current, value) - return pb -} - -// Add adding given int value to bar value -func (pb *ProgressBar) Add(value int) *ProgressBar { - return pb.Add64(int64(value)) -} - -// Increment atomically increments the progress -func (pb *ProgressBar) Increment() *ProgressBar { - return pb.Add64(1) -} - -// Set sets any value by any key -func (pb *ProgressBar) Set(key, value interface{}) *ProgressBar { - pb.mu.Lock() - defer pb.mu.Unlock() - if pb.vars == nil { - pb.vars = make(map[interface{}]interface{}) - } - pb.vars[key] = value - return pb -} - -// Get return value by key -func (pb *ProgressBar) Get(key interface{}) interface{} { - pb.mu.RLock() - defer pb.mu.RUnlock() - if pb.vars == nil { - return nil - } - return pb.vars[key] -} - -// GetBool return value by key and try to convert there to boolean -// If value doesn't set or not boolean - return false -func (pb *ProgressBar) GetBool(key interface{}) bool { - if v, ok := pb.Get(key).(bool); ok { - return v - } - return false -} - -// SetWidth sets the bar width -// When given value <= 0 would be using the terminal width (if possible) or default value. -func (pb *ProgressBar) SetWidth(width int) *ProgressBar { - pb.mu.Lock() - pb.width = width - pb.mu.Unlock() - return pb -} - -// SetMaxWidth sets the bar maximum width -// When given value <= 0 would be using the terminal width (if possible) or default value. -func (pb *ProgressBar) SetMaxWidth(maxWidth int) *ProgressBar { - pb.mu.Lock() - pb.maxWidth = maxWidth - pb.mu.Unlock() - return pb -} - -// Width return the bar width -// It's current terminal width or settled over 'SetWidth' value. -func (pb *ProgressBar) Width() (width int) { - defer func() { - if r := recover(); r != nil { - width = defaultBarWidth - } - }() - pb.mu.RLock() - width = pb.width - maxWidth := pb.maxWidth - pb.mu.RUnlock() - if width <= 0 { - var err error - if width, err = terminalWidth(); err != nil { - return defaultBarWidth - } - } - if maxWidth > 0 && width > maxWidth { - width = maxWidth - } - return -} - -func (pb *ProgressBar) SetRefreshRate(dur time.Duration) *ProgressBar { - pb.mu.Lock() - if dur > 0 { - pb.refreshRate = dur - } - pb.mu.Unlock() - return pb -} - -// SetWriter sets the io.Writer. Bar will write in this writer -// By default this is os.Stderr -func (pb *ProgressBar) SetWriter(w io.Writer) *ProgressBar { - pb.mu.Lock() - pb.output = w - pb.configured = false - pb.configure() - pb.mu.Unlock() - return pb -} - -// StartTime return the time when bar started -func (pb *ProgressBar) StartTime() time.Time { - pb.mu.RLock() - defer pb.mu.RUnlock() - return pb.startTime -} - -// Format convert int64 to string according to the current settings -func (pb *ProgressBar) Format(v int64) string { - if pb.GetBool(Bytes) { - return formatBytes(v, pb.GetBool(SIBytesPrefix)) - } - return strconv.FormatInt(v, 10) -} - -// Finish stops the bar -func (pb *ProgressBar) Finish() *ProgressBar { - pb.mu.Lock() - if pb.finished { - pb.mu.Unlock() - return pb - } - finishChan := pb.finish - pb.finished = true - pb.mu.Unlock() - if finishChan != nil { - finishChan <- struct{}{} - <-finishChan - pb.mu.Lock() - pb.finish = nil - pb.mu.Unlock() - } - return pb -} - -// IsStarted indicates progress bar state -func (pb *ProgressBar) IsStarted() bool { - pb.mu.RLock() - defer pb.mu.RUnlock() - return pb.finish != nil -} - -// SetTemplateString sets ProgressBar tempate string and parse it -func (pb *ProgressBar) SetTemplateString(tmpl string) *ProgressBar { - pb.mu.Lock() - defer pb.mu.Unlock() - pb.tmpl, pb.err = getTemplate(tmpl) - return pb -} - -// SetTemplateString sets ProgressBarTempate and parse it -func (pb *ProgressBar) SetTemplate(tmpl ProgressBarTemplate) *ProgressBar { - return pb.SetTemplateString(string(tmpl)) -} - -// NewProxyReader creates a wrapper for given reader, but with progress handle -// Takes io.Reader or io.ReadCloser -// Also, it automatically switches progress bar to handle units as bytes -func (pb *ProgressBar) NewProxyReader(r io.Reader) *Reader { - pb.Set(Bytes, true) - return &Reader{r, pb} -} - -// NewProxyWriter creates a wrapper for given writer, but with progress handle -// Takes io.Writer or io.WriteCloser -// Also, it automatically switches progress bar to handle units as bytes -func (pb *ProgressBar) NewProxyWriter(r io.Writer) *Writer { - pb.Set(Bytes, true) - return &Writer{r, pb} -} - -func (pb *ProgressBar) render() (result string, width int) { - defer func() { - if r := recover(); r != nil { - pb.SetErr(fmt.Errorf("render panic: %v", r)) - } - }() - pb.rm.Lock() - defer pb.rm.Unlock() - pb.mu.Lock() - pb.configure() - if pb.state == nil { - pb.state = &State{ProgressBar: pb} - pb.buf = bytes.NewBuffer(nil) - } - if pb.startTime.IsZero() { - pb.startTime = time.Now() - } - pb.state.id++ - pb.state.finished = pb.finished - pb.state.time = time.Now() - pb.mu.Unlock() - - pb.state.width = pb.Width() - width = pb.state.width - pb.state.total = pb.Total() - pb.state.current = pb.Current() - pb.buf.Reset() - - if e := pb.tmpl.Execute(pb.buf, pb.state); e != nil { - pb.SetErr(e) - return "", 0 - } - - result = pb.buf.String() - - aec := len(pb.state.recalc) - if aec == 0 { - // no adaptive elements - return - } - - staticWidth := CellCount(result) - (aec * adElPlaceholderLen) - - if pb.state.Width()-staticWidth <= 0 { - result = strings.Replace(result, adElPlaceholder, "", -1) - result = StripString(result, pb.state.Width()) - } else { - pb.state.adaptiveElWidth = (width - staticWidth) / aec - for _, el := range pb.state.recalc { - result = strings.Replace(result, adElPlaceholder, el.ProgressElement(pb.state), 1) - } - } - pb.state.recalc = pb.state.recalc[:0] - return -} - -// SetErr sets error to the ProgressBar -// Error will be available over Err() -func (pb *ProgressBar) SetErr(err error) *ProgressBar { - pb.mu.Lock() - pb.err = err - pb.mu.Unlock() - return pb -} - -// Err return possible error -// When all ok - will be nil -// May contain template.Execute errors -func (pb *ProgressBar) Err() error { - pb.mu.RLock() - defer pb.mu.RUnlock() - return pb.err -} - -// String return currrent string representation of ProgressBar -func (pb *ProgressBar) String() string { - res, _ := pb.render() - return res -} - -// ProgressElement implements Element interface -func (pb *ProgressBar) ProgressElement(s *State, args ...string) string { - if s.IsAdaptiveWidth() { - pb.SetWidth(s.AdaptiveElWidth()) - } - return pb.String() -} - -// State represents the current state of bar -// Need for bar elements -type State struct { - *ProgressBar - - id uint64 - total, current int64 - width, adaptiveElWidth int - finished, adaptive bool - time time.Time - - recalc []Element -} - -// Id it's the current state identifier -// - incremental -// - starts with 1 -// - resets after finish/start -func (s *State) Id() uint64 { - return s.id -} - -// Total it's bar int64 total -func (s *State) Total() int64 { - return s.total -} - -// Value it's current value -func (s *State) Value() int64 { - return s.current -} - -// Width of bar -func (s *State) Width() int { - return s.width -} - -// AdaptiveElWidth - adaptive elements must return string with given cell count (when AdaptiveElWidth > 0) -func (s *State) AdaptiveElWidth() int { - return s.adaptiveElWidth -} - -// IsAdaptiveWidth returns true when element must be shown as adaptive -func (s *State) IsAdaptiveWidth() bool { - return s.adaptive -} - -// IsFinished return true when bar is finished -func (s *State) IsFinished() bool { - return s.finished -} - -// IsFirst return true only in first render -func (s *State) IsFirst() bool { - return s.id == 1 -} - -// Time when state was created -func (s *State) Time() time.Time { - return s.time -} diff --git a/vendor/github.com/cheggaaa/pb/v3/pb_test.go b/vendor/github.com/cheggaaa/pb/v3/pb_test.go deleted file mode 100644 index c8439d9..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/pb_test.go +++ /dev/null @@ -1,240 +0,0 @@ -package pb - -import ( - "bytes" - "errors" - "fmt" - "strings" - "testing" - "time" - - "github.com/fatih/color" -) - -func TestPBBasic(t *testing.T) { - bar := new(ProgressBar) - var a, e int64 - if a, e = bar.Total(), 0; a != e { - t.Errorf("Unexpected total: actual: %v; expected: %v", a, e) - } - if a, e = bar.Current(), 0; a != e { - t.Errorf("Unexpected current: actual: %v; expected: %v", a, e) - } - bar.SetCurrent(10).SetTotal(20) - if a, e = bar.Total(), 20; a != e { - t.Errorf("Unexpected total: actual: %v; expected: %v", a, e) - } - if a, e = bar.Current(), 10; a != e { - t.Errorf("Unexpected current: actual: %v; expected: %v", a, e) - } - bar.Add(5) - if a, e = bar.Current(), 15; a != e { - t.Errorf("Unexpected current: actual: %v; expected: %v", a, e) - } - bar.Increment() - if a, e = bar.Current(), 16; a != e { - t.Errorf("Unexpected current: actual: %v; expected: %v", a, e) - } -} - -func TestPBWidth(t *testing.T) { - terminalWidth = func() (int, error) { - return 50, nil - } - // terminal width - bar := new(ProgressBar) - if a, e := bar.Width(), 50; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } - // terminal width error - terminalWidth = func() (int, error) { - return 0, errors.New("test error") - } - if a, e := bar.Width(), defaultBarWidth; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } - // terminal width panic - terminalWidth = func() (int, error) { - panic("test") - return 0, nil - } - if a, e := bar.Width(), defaultBarWidth; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } - // set negative terminal width - bar.SetWidth(-42) - if a, e := bar.Width(), defaultBarWidth; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } - // set terminal width - bar.SetWidth(42) - if a, e := bar.Width(), 42; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } -} - -func TestPBMaxWidth(t *testing.T) { - terminalWidth = func() (int, error) { - return 50, nil - } - // terminal width - bar := new(ProgressBar) - if a, e := bar.Width(), 50; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } - - bar.SetMaxWidth(55) - if a, e := bar.Width(), 50; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } - - bar.SetMaxWidth(38) - if a, e := bar.Width(), 38; a != e { - t.Errorf("Unexpected width: actual: %v; expected: %v", a, e) - } -} - -func TestPBTemplate(t *testing.T) { - bar := new(ProgressBar) - result := bar.SetTotal(100).SetCurrent(50).SetWidth(40).String() - expected := "50 / 100 [------->________] 50.00% ? p/s" - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n%s\n%s", result, expected) - } - - // check strip - result = bar.SetWidth(8).String() - expected = "50 / 100" - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n%s\n%s", result, expected) - } - - // invalid template - for _, invalidTemplate := range []string{ - `{{invalid template`, `{{speed}}`, - } { - bar.SetTemplateString(invalidTemplate) - result = bar.String() - expected = "" - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n%s\n%s", result, expected) - } - if err := bar.Err(); err == nil { - t.Errorf("Must be error") - } - } - - // simple template without adaptive elemnts - bar.SetTemplateString(`{{counters . }}`) - result = bar.String() - expected = "50 / 100" - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n%s\n%s", result, expected) - } -} - -func TestPBStartFinish(t *testing.T) { - bar := ProgressBarTemplate(`{{counters . }}`).New(0) - for i := int64(0); i < 2; i++ { - if bar.IsStarted() { - t.Error("Must be false") - } - var buf = bytes.NewBuffer(nil) - bar.SetTotal(100). - SetCurrent(int64(i)). - SetWidth(7). - Set(Terminal, true). - SetWriter(buf). - SetRefreshRate(time.Millisecond * 20). - Start() - if !bar.IsStarted() { - t.Error("Must be true") - } - time.Sleep(time.Millisecond * 100) - bar.Finish() - if buf.Len() == 0 { - t.Error("no writes") - } - var resultsString = strings.TrimPrefix(buf.String(), "\r") - if !strings.HasSuffix(resultsString, "\n") { - t.Error("No end \\n symb") - } else { - resultsString = resultsString[:len(resultsString)-1] - } - var results = strings.Split(resultsString, "\r") - if len(results) < 3 { - t.Errorf("Unexpected writes count: %v", len(results)) - } - exp := fmt.Sprintf("%d / 100", i) - for i, res := range results { - if res != exp { - t.Errorf("Unexpected result[%d]: '%v'", i, res) - } - } - // test second finish call - bar.Finish() - } -} - -func TestPBFlags(t *testing.T) { - // Static - color.NoColor = false - buf := bytes.NewBuffer(nil) - bar := ProgressBarTemplate(`{{counters . | red}}`).New(100) - bar.Set(Static, true).SetCurrent(50).SetWidth(10).SetWriter(buf).Start() - if bar.IsStarted() { - t.Error("Must be false") - } - bar.Write() - result := buf.String() - expected := "50 / 100" - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n'%s'\n'%s'", result, expected) - } - if !bar.state.IsFirst() { - t.Error("must be true") - } - // Color - bar.Set(Color, true) - buf.Reset() - bar.Write() - result = buf.String() - expected = color.RedString("50 / 100") - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n'%s'\n'%s'", result, expected) - } - if bar.state.IsFirst() { - t.Error("must be false") - } - // Terminal - bar.Set(Terminal, true).SetWriter(buf) - buf.Reset() - bar.Write() - result = buf.String() - expected = "\r" + color.RedString("50 / 100") + " " - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n'%s'\n'%s'", result, expected) - } -} - -func BenchmarkRender(b *testing.B) { - var formats = []string{ - string(Simple), - string(Default), - string(Full), - `{{string . "prefix" | red}}{{counters . | green}} {{bar . | yellow}} {{percent . | cyan}} {{speed . | cyan}}{{string . "suffix" | cyan}}`, - } - var names = []string{ - "Simple", "Default", "Full", "Color", - } - for i, tmpl := range formats { - bar := new(ProgressBar) - bar.SetTemplateString(tmpl).SetWidth(100) - b.Run(names[i], func(b *testing.B) { - b.ReportAllocs() - for i := 0; i < b.N; i++ { - bar.String() - } - }) - } -} diff --git a/vendor/github.com/cheggaaa/pb/v3/preset.go b/vendor/github.com/cheggaaa/pb/v3/preset.go deleted file mode 100644 index f5e2fff..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/preset.go +++ /dev/null @@ -1,15 +0,0 @@ -package pb - -var ( - // Full - preset with all default available elements - // Example: 'Prefix 20/100 [-->______] 20% 1 p/s ETA 1m Suffix' - Full ProgressBarTemplate = `{{string . "prefix"}}{{counters . }} {{bar . }} {{percent . }} {{speed . }} {{rtime . "ETA %s"}}{{string . "suffix"}}` - - // Default - preset like Full but without elapsed time - // Example: 'Prefix 20/100 [-->______] 20% 1 p/s ETA 1m Suffix' - Default ProgressBarTemplate = `{{string . "prefix"}}{{counters . }} {{bar . }} {{percent . }} {{speed . }}{{string . "suffix"}}` - - // Simple - preset without speed and any timers. Only counters, bar and percents - // Example: 'Prefix 20/100 [-->______] 20% Suffix' - Simple ProgressBarTemplate = `{{string . "prefix"}}{{counters . }} {{bar . }} {{percent . }}{{string . "suffix"}}` -) diff --git a/vendor/github.com/cheggaaa/pb/v3/speed.go b/vendor/github.com/cheggaaa/pb/v3/speed.go deleted file mode 100644 index 17a6b1b..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/speed.go +++ /dev/null @@ -1,83 +0,0 @@ -package pb - -import ( - "fmt" - "math" - "time" - - "github.com/VividCortex/ewma" -) - -var speedAddLimit = time.Second / 2 - -type speed struct { - ewma ewma.MovingAverage - lastStateId uint64 - prevValue, startValue int64 - prevTime, startTime time.Time -} - -func (s *speed) value(state *State) float64 { - if s.ewma == nil { - s.ewma = ewma.NewMovingAverage() - } - if state.IsFirst() || state.Id() < s.lastStateId { - s.reset(state) - return 0 - } - if state.Id() == s.lastStateId { - return s.ewma.Value() - } - if state.IsFinished() { - return s.absValue(state) - } - dur := state.Time().Sub(s.prevTime) - if dur < speedAddLimit { - return s.ewma.Value() - } - diff := math.Abs(float64(state.Value() - s.prevValue)) - lastSpeed := diff / dur.Seconds() - s.prevTime = state.Time() - s.prevValue = state.Value() - s.lastStateId = state.Id() - s.ewma.Add(lastSpeed) - return s.ewma.Value() -} - -func (s *speed) reset(state *State) { - s.lastStateId = state.Id() - s.startTime = state.Time() - s.prevTime = state.Time() - s.startValue = state.Value() - s.prevValue = state.Value() - s.ewma = ewma.NewMovingAverage() -} - -func (s *speed) absValue(state *State) float64 { - if dur := state.Time().Sub(s.startTime); dur > 0 { - return float64(state.Value()) / dur.Seconds() - } - return 0 -} - -func getSpeedObj(state *State) (s *speed) { - if sObj, ok := state.Get(speedObj).(*speed); ok { - return sObj - } - s = new(speed) - state.Set(speedObj, s) - return -} - -// ElementSpeed calculates current speed by EWMA -// Optionally can take one or two string arguments. -// First string will be used as value for format speed, default is "%s p/s". -// Second string will be used when speed not available, default is "? p/s" -// In template use as follows: {{speed .}} or {{speed . "%s per second"}} or {{speed . "%s ps" "..."} -var ElementSpeed ElementFunc = func(state *State, args ...string) string { - sp := getSpeedObj(state).value(state) - if sp == 0 { - return argsHelper(args).getNotEmptyOr(1, "? p/s") - } - return fmt.Sprintf(argsHelper(args).getNotEmptyOr(0, "%s p/s"), state.Format(int64(round(sp)))) -} diff --git a/vendor/github.com/cheggaaa/pb/v3/template.go b/vendor/github.com/cheggaaa/pb/v3/template.go deleted file mode 100644 index ecfc271..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/template.go +++ /dev/null @@ -1,88 +0,0 @@ -package pb - -import ( - "math/rand" - "sync" - "text/template" - - "github.com/fatih/color" -) - -// ProgressBarTemplate that template string -type ProgressBarTemplate string - -// New creates new bar from template -func (pbt ProgressBarTemplate) New(total int) *ProgressBar { - return New(total).SetTemplate(pbt) -} - -// Start64 create and start new bar with given int64 total value -func (pbt ProgressBarTemplate) Start64(total int64) *ProgressBar { - return New64(total).SetTemplate(pbt).Start() -} - -// Start create and start new bar with given int total value -func (pbt ProgressBarTemplate) Start(total int) *ProgressBar { - return pbt.Start64(int64(total)) -} - -var templateCacheMu sync.Mutex -var templateCache = make(map[string]*template.Template) - -var defaultTemplateFuncs = template.FuncMap{ - // colors - "black": color.New(color.FgBlack).SprintFunc(), - "red": color.New(color.FgRed).SprintFunc(), - "green": color.New(color.FgGreen).SprintFunc(), - "yellow": color.New(color.FgYellow).SprintFunc(), - "blue": color.New(color.FgBlue).SprintFunc(), - "magenta": color.New(color.FgMagenta).SprintFunc(), - "cyan": color.New(color.FgCyan).SprintFunc(), - "white": color.New(color.FgWhite).SprintFunc(), - "resetcolor": color.New(color.Reset).SprintFunc(), - "rndcolor": rndcolor, - "rnd": rnd, -} - -func getTemplate(tmpl string) (t *template.Template, err error) { - templateCacheMu.Lock() - defer templateCacheMu.Unlock() - t = templateCache[tmpl] - if t != nil { - // found in cache - return - } - t = template.New("") - fillTemplateFuncs(t) - _, err = t.Parse(tmpl) - if err != nil { - t = nil - return - } - templateCache[tmpl] = t - return -} - -func fillTemplateFuncs(t *template.Template) { - t.Funcs(defaultTemplateFuncs) - emf := make(template.FuncMap) - elementsM.Lock() - for k, v := range elements { - emf[k] = v - } - elementsM.Unlock() - t.Funcs(emf) - return -} - -func rndcolor(s string) string { - c := rand.Intn(int(color.FgWhite-color.FgBlack)) + int(color.FgBlack) - return color.New(color.Attribute(c)).Sprint(s) -} - -func rnd(args ...string) string { - if len(args) == 0 { - return "" - } - return args[rand.Intn(len(args))] -} diff --git a/vendor/github.com/cheggaaa/pb/v3/template_test.go b/vendor/github.com/cheggaaa/pb/v3/template_test.go deleted file mode 100644 index 84022d3..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/template_test.go +++ /dev/null @@ -1,53 +0,0 @@ -package pb - -import ( - "bytes" - "testing" -) - -func TestProgressBarTemplate(t *testing.T) { - // test New - bar := ProgressBarTemplate(`{{counters . }}`).New(0) - result := bar.String() - expected := "0" - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n%s\n%s", result, expected) - } - if bar.IsStarted() { - t.Error("Must be false") - } - - // test Start - bar = ProgressBarTemplate(`{{counters . }}`).Start(42).SetWriter(bytes.NewBuffer(nil)) - result = bar.String() - expected = "0 / 42" - if result != expected { - t.Errorf("Unexpected result: (actual/expected)\n%s\n%s", result, expected) - } - if !bar.IsStarted() { - t.Error("Must be true") - } -} - -func TestTemplateFuncs(t *testing.T) { - var results = make(map[string]int) - for i := 0; i < 100; i++ { - r := rndcolor("s") - results[r] = results[r] + 1 - } - if len(results) < 6 { - t.Errorf("Unexpected rndcolor results count: %v", len(results)) - } - - results = make(map[string]int) - for i := 0; i < 100; i++ { - r := rnd("1", "2", "3") - results[r] = results[r] + 1 - } - if len(results) != 3 { - t.Errorf("Unexpected rnd results count: %v", len(results)) - } - if r := rnd(); r != "" { - t.Errorf("Unexpected rnd result: '%v'", r) - } -} diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term.go deleted file mode 100644 index 02b5279..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term.go +++ /dev/null @@ -1,56 +0,0 @@ -package termutil - -import ( - "errors" - "os" - "os/signal" - "sync" -) - -var echoLocked bool -var echoLockMutex sync.Mutex -var errLocked = errors.New("terminal locked") - -// RawModeOn switches terminal to raw mode -func RawModeOn() (quit chan struct{}, err error) { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - if echoLocked { - err = errLocked - return - } - if err = lockEcho(); err != nil { - return - } - echoLocked = true - quit = make(chan struct{}, 1) - go catchTerminate(quit) - return -} - -// RawModeOff restore previous terminal state -func RawModeOff() (err error) { - echoLockMutex.Lock() - defer echoLockMutex.Unlock() - if !echoLocked { - return - } - if err = unlockEcho(); err != nil { - return - } - echoLocked = false - return -} - -// listen exit signals and restore terminal state -func catchTerminate(quit chan struct{}) { - sig := make(chan os.Signal, 1) - signal.Notify(sig, unlockSignals...) - defer signal.Stop(sig) - select { - case <-quit: - RawModeOff() - case <-sig: - RawModeOff() - } -} diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_appengine.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_appengine.go deleted file mode 100644 index 4b7b20e..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_appengine.go +++ /dev/null @@ -1,11 +0,0 @@ -// +build appengine - -package termutil - -import "errors" - -// terminalWidth returns width of the terminal, which is not supported -// and should always failed on appengine classic which is a sandboxed PaaS. -func TerminalWidth() (int, error) { - return 0, errors.New("Not supported") -} diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_bsd.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_bsd.go deleted file mode 100644 index 272659a..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_bsd.go +++ /dev/null @@ -1,9 +0,0 @@ -// +build darwin freebsd netbsd openbsd dragonfly -// +build !appengine - -package termutil - -import "syscall" - -const ioctlReadTermios = syscall.TIOCGETA -const ioctlWriteTermios = syscall.TIOCSETA diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_linux.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_linux.go deleted file mode 100644 index 2f59e53..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_linux.go +++ /dev/null @@ -1,7 +0,0 @@ -// +build linux -// +build !appengine - -package termutil - -const ioctlReadTermios = 0x5401 // syscall.TCGETS -const ioctlWriteTermios = 0x5402 // syscall.TCSETS diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_nix.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_nix.go deleted file mode 100644 index 14277e7..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_nix.go +++ /dev/null @@ -1,8 +0,0 @@ -// +build linux darwin freebsd netbsd openbsd dragonfly -// +build !appengine - -package termutil - -import "syscall" - -const sysIoctl = syscall.SYS_IOCTL diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_plan9.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_plan9.go deleted file mode 100644 index f3934c6..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_plan9.go +++ /dev/null @@ -1,50 +0,0 @@ -package termutil - -import ( - "errors" - "os" - "syscall" -) - -var ( - consctl *os.File - - // Plan 9 doesn't have syscall.SIGQUIT - unlockSignals = []os.Signal{ - os.Interrupt, syscall.SIGTERM, syscall.SIGKILL, - } -) - -// TerminalWidth returns width of the terminal. -func TerminalWidth() (int, error) { - return 0, errors.New("Not supported") -} - -func lockEcho() error { - if consctl != nil { - return errors.New("consctl already open") - } - var err error - consctl, err = os.OpenFile("/dev/consctl", os.O_WRONLY, 0) - if err != nil { - return err - } - _, err = consctl.WriteString("rawon") - if err != nil { - consctl.Close() - consctl = nil - return err - } - return nil -} - -func unlockEcho() error { - if consctl == nil { - return nil - } - if err := consctl.Close(); err != nil { - return err - } - consctl = nil - return nil -} diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_solaris.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_solaris.go deleted file mode 100644 index fc96c2b..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_solaris.go +++ /dev/null @@ -1,8 +0,0 @@ -// +build solaris -// +build !appengine - -package termutil - -const ioctlReadTermios = 0x5401 // syscall.TCGETS -const ioctlWriteTermios = 0x5402 // syscall.TCSETS -const sysIoctl = 54 diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_win.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_win.go deleted file mode 100644 index c867d27..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_win.go +++ /dev/null @@ -1,155 +0,0 @@ -// +build windows - -package termutil - -import ( - "fmt" - "os" - "os/exec" - "strconv" - "syscall" - "unsafe" -) - -var ( - tty = os.Stdin - - unlockSignals = []os.Signal{ - os.Interrupt, syscall.SIGQUIT, syscall.SIGTERM, syscall.SIGKILL, - } -) - -var ( - kernel32 = syscall.NewLazyDLL("kernel32.dll") - - // GetConsoleScreenBufferInfo retrieves information about the - // specified console screen buffer. - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms683171(v=vs.85).aspx - procGetConsoleScreenBufferInfo = kernel32.NewProc("GetConsoleScreenBufferInfo") - - // GetConsoleMode retrieves the current input mode of a console's - // input buffer or the current output mode of a console screen buffer. - // https://msdn.microsoft.com/en-us/library/windows/desktop/ms683167(v=vs.85).aspx - getConsoleMode = kernel32.NewProc("GetConsoleMode") - - // SetConsoleMode sets the input mode of a console's input buffer - // or the output mode of a console screen buffer. - // https://msdn.microsoft.com/en-us/library/windows/desktop/ms686033(v=vs.85).aspx - setConsoleMode = kernel32.NewProc("SetConsoleMode") - - // SetConsoleCursorPosition sets the cursor position in the - // specified console screen buffer. - // https://msdn.microsoft.com/en-us/library/windows/desktop/ms686025(v=vs.85).aspx - setConsoleCursorPosition = kernel32.NewProc("SetConsoleCursorPosition") - - mingw = isMingw() -) - -type ( - // Defines the coordinates of the upper left and lower right corners - // of a rectangle. - // See - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms686311(v=vs.85).aspx - smallRect struct { - Left, Top, Right, Bottom int16 - } - - // Defines the coordinates of a character cell in a console screen - // buffer. The origin of the coordinate system (0,0) is at the top, left cell - // of the buffer. - // See - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms682119(v=vs.85).aspx - coordinates struct { - X, Y int16 - } - - word int16 - - // Contains information about a console screen buffer. - // http://msdn.microsoft.com/en-us/library/windows/desktop/ms682093(v=vs.85).aspx - consoleScreenBufferInfo struct { - dwSize coordinates - dwCursorPosition coordinates - wAttributes word - srWindow smallRect - dwMaximumWindowSize coordinates - } -) - -// TerminalWidth returns width of the terminal. -func TerminalWidth() (width int, err error) { - if mingw { - return termWidthTPut() - } - return termWidthCmd() -} - -func termWidthCmd() (width int, err error) { - var info consoleScreenBufferInfo - _, _, e := syscall.Syscall(procGetConsoleScreenBufferInfo.Addr(), 2, uintptr(syscall.Stdout), uintptr(unsafe.Pointer(&info)), 0) - if e != 0 { - return 0, error(e) - } - return int(info.dwSize.X) - 1, nil -} - -func isMingw() bool { - return os.Getenv("MINGW_PREFIX") != "" || os.Getenv("MSYSTEM") == "MINGW64" -} - -func termWidthTPut() (width int, err error) { - // TODO: maybe anybody knows a better way to get it on mintty... - var res []byte - cmd := exec.Command("tput", "cols") - cmd.Stdin = os.Stdin - if res, err = cmd.CombinedOutput(); err != nil { - return 0, fmt.Errorf("%s: %v", string(res), err) - } - if len(res) > 1 { - res = res[:len(res)-1] - } - return strconv.Atoi(string(res)) -} - -func getCursorPos() (pos coordinates, err error) { - var info consoleScreenBufferInfo - _, _, e := syscall.Syscall(procGetConsoleScreenBufferInfo.Addr(), 2, uintptr(syscall.Stdout), uintptr(unsafe.Pointer(&info)), 0) - if e != 0 { - return info.dwCursorPosition, error(e) - } - return info.dwCursorPosition, nil -} - -func setCursorPos(pos coordinates) error { - _, _, e := syscall.Syscall(setConsoleCursorPosition.Addr(), 2, uintptr(syscall.Stdout), uintptr(uint32(uint16(pos.Y))<<16|uint32(uint16(pos.X))), 0) - if e != 0 { - return error(e) - } - return nil -} - -var oldState word - -func lockEcho() (err error) { - if _, _, e := syscall.Syscall(getConsoleMode.Addr(), 2, uintptr(syscall.Stdout), uintptr(unsafe.Pointer(&oldState)), 0); e != 0 { - err = fmt.Errorf("Can't get terminal settings: %v", e) - return - } - - newState := oldState - const ENABLE_ECHO_INPUT = 0x0004 - const ENABLE_LINE_INPUT = 0x0002 - newState = newState & (^(ENABLE_LINE_INPUT | ENABLE_ECHO_INPUT)) - if _, _, e := syscall.Syscall(setConsoleMode.Addr(), 2, uintptr(syscall.Stdout), uintptr(newState), 0); e != 0 { - err = fmt.Errorf("Can't set terminal settings: %v", e) - return - } - return -} - -func unlockEcho() (err error) { - if _, _, e := syscall.Syscall(setConsoleMode.Addr(), 2, uintptr(syscall.Stdout), uintptr(oldState), 0); e != 0 { - err = fmt.Errorf("Can't set terminal settings") - } - return -} diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_x.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_x.go deleted file mode 100644 index 6937755..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_x.go +++ /dev/null @@ -1,76 +0,0 @@ -// +build linux darwin freebsd netbsd openbsd solaris dragonfly -// +build !appengine - -package termutil - -import ( - "fmt" - "os" - "syscall" - "unsafe" -) - -var ( - tty *os.File - - unlockSignals = []os.Signal{ - os.Interrupt, syscall.SIGQUIT, syscall.SIGTERM, syscall.SIGKILL, - } -) - -type window struct { - Row uint16 - Col uint16 - Xpixel uint16 - Ypixel uint16 -} - -func init() { - var err error - tty, err = os.Open("/dev/tty") - if err != nil { - tty = os.Stdin - } -} - -// TerminalWidth returns width of the terminal. -func TerminalWidth() (int, error) { - w := new(window) - res, _, err := syscall.Syscall(sysIoctl, - tty.Fd(), - uintptr(syscall.TIOCGWINSZ), - uintptr(unsafe.Pointer(w)), - ) - if int(res) == -1 { - return 0, err - } - return int(w.Col), nil -} - -var oldState syscall.Termios - -func lockEcho() (err error) { - fd := tty.Fd() - if _, _, e := syscall.Syscall6(sysIoctl, fd, ioctlReadTermios, uintptr(unsafe.Pointer(&oldState)), 0, 0, 0); e != 0 { - err = fmt.Errorf("Can't get terminal settings: %v", e) - return - } - - newState := oldState - newState.Lflag &^= syscall.ECHO - newState.Lflag |= syscall.ICANON | syscall.ISIG - newState.Iflag |= syscall.ICRNL - if _, _, e := syscall.Syscall6(sysIoctl, fd, ioctlWriteTermios, uintptr(unsafe.Pointer(&newState)), 0, 0, 0); e != 0 { - err = fmt.Errorf("Can't set terminal settings: %v", e) - return - } - return -} - -func unlockEcho() (err error) { - fd := tty.Fd() - if _, _, e := syscall.Syscall6(sysIoctl, fd, ioctlWriteTermios, uintptr(unsafe.Pointer(&oldState)), 0, 0, 0); e != 0 { - err = fmt.Errorf("Can't set terminal settings") - } - return -} diff --git a/vendor/github.com/cheggaaa/pb/v3/util.go b/vendor/github.com/cheggaaa/pb/v3/util.go deleted file mode 100644 index 0781234..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/util.go +++ /dev/null @@ -1,115 +0,0 @@ -package pb - -import ( - "bytes" - "fmt" - "github.com/mattn/go-runewidth" - "math" - "regexp" - //"unicode/utf8" -) - -const ( - _KiB = 1024 - _MiB = 1048576 - _GiB = 1073741824 - _TiB = 1099511627776 - - _kB = 1e3 - _MB = 1e6 - _GB = 1e9 - _TB = 1e12 -) - -var ctrlFinder = regexp.MustCompile("\x1b\x5b[0-9]+\x6d") - -func CellCount(s string) int { - n := runewidth.StringWidth(s) - for _, sm := range ctrlFinder.FindAllString(s, -1) { - n -= runewidth.StringWidth(sm) - } - return n -} - -func StripString(s string, w int) string { - l := CellCount(s) - if l <= w { - return s - } - var buf = bytes.NewBuffer(make([]byte, 0, len(s))) - StripStringToBuffer(s, w, buf) - return buf.String() -} - -func StripStringToBuffer(s string, w int, buf *bytes.Buffer) { - var seqs = ctrlFinder.FindAllStringIndex(s, -1) -mainloop: - for i, r := range s { - for _, seq := range seqs { - if i >= seq[0] && i < seq[1] { - buf.WriteRune(r) - continue mainloop - } - } - if rw := CellCount(string(r)); rw <= w { - w -= rw - buf.WriteRune(r) - } else { - break - } - } - for w > 0 { - buf.WriteByte(' ') - w-- - } - return -} - -func round(val float64) (newVal float64) { - roundOn := 0.5 - places := 0 - var round float64 - pow := math.Pow(10, float64(places)) - digit := pow * val - _, div := math.Modf(digit) - if div >= roundOn { - round = math.Ceil(digit) - } else { - round = math.Floor(digit) - } - newVal = round / pow - return -} - -// Convert bytes to human readable string. Like a 2 MiB, 64.2 KiB, or 2 MB, 64.2 kB -// if useSIPrefix is set to true -func formatBytes(i int64, useSIPrefix bool) (result string) { - if !useSIPrefix { - switch { - case i >= _TiB: - result = fmt.Sprintf("%.02f TiB", float64(i)/_TiB) - case i >= _GiB: - result = fmt.Sprintf("%.02f GiB", float64(i)/_GiB) - case i >= _MiB: - result = fmt.Sprintf("%.02f MiB", float64(i)/_MiB) - case i >= _KiB: - result = fmt.Sprintf("%.02f KiB", float64(i)/_KiB) - default: - result = fmt.Sprintf("%d B", i) - } - } else { - switch { - case i >= _TB: - result = fmt.Sprintf("%.02f TB", float64(i)/_TB) - case i >= _GB: - result = fmt.Sprintf("%.02f GB", float64(i)/_GB) - case i >= _MB: - result = fmt.Sprintf("%.02f MB", float64(i)/_MB) - case i >= _kB: - result = fmt.Sprintf("%.02f kB", float64(i)/_kB) - default: - result = fmt.Sprintf("%d B", i) - } - } - return -} diff --git a/vendor/github.com/cheggaaa/pb/v3/util_test.go b/vendor/github.com/cheggaaa/pb/v3/util_test.go deleted file mode 100644 index d541876..0000000 --- a/vendor/github.com/cheggaaa/pb/v3/util_test.go +++ /dev/null @@ -1,80 +0,0 @@ -package pb - -import ( - "github.com/fatih/color" - "testing" -) - -var testColorString = color.RedString("red") + - color.GreenString("hello") + - "simple" + - color.WhiteString("進捗") - -func TestUtilCellCount(t *testing.T) { - if e, l := 18, CellCount(testColorString); l != e { - t.Errorf("Invalid length %d, expected %d", l, e) - } -} - -func TestUtilStripString(t *testing.T) { - if r, e := StripString("12345", 4), "1234"; r != e { - t.Errorf("Invalid result '%s', expected '%s'", r, e) - } - - if r, e := StripString("12345", 5), "12345"; r != e { - t.Errorf("Invalid result '%s', expected '%s'", r, e) - } - if r, e := StripString("12345", 10), "12345"; r != e { - t.Errorf("Invalid result '%s', expected '%s'", r, e) - } - - s := color.RedString("1") + "23" - e := color.RedString("1") + "2" - if r := StripString(s, 2); r != e { - t.Errorf("Invalid result '%s', expected '%s'", r, e) - } - return -} - -func TestUtilRound(t *testing.T) { - if v := round(4.4); v != 4 { - t.Errorf("Unexpected result: %v", v) - } - if v := round(4.501); v != 5 { - t.Errorf("Unexpected result: %v", v) - } -} - -func TestUtilFormatBytes(t *testing.T) { - inputs := []struct { - v int64 - s bool - e string - }{ - {v: 1000, s: false, e: "1000 B"}, - {v: 1024, s: false, e: "1.00 KiB"}, - {v: 3*_MiB + 140*_KiB, s: false, e: "3.14 MiB"}, - {v: 2 * _GiB, s: false, e: "2.00 GiB"}, - {v: 2048 * _GiB, s: false, e: "2.00 TiB"}, - - {v: 999, s: true, e: "999 B"}, - {v: 1024, s: true, e: "1.02 kB"}, - {v: 3*_MB + 140*_kB, s: true, e: "3.14 MB"}, - {v: 2 * _GB, s: true, e: "2.00 GB"}, - {v: 2048 * _GB, s: true, e: "2.05 TB"}, - } - - for _, input := range inputs { - actual := formatBytes(input.v, input.s) - if actual != input.e { - t.Errorf("Expected {%s} was {%s}", input.e, actual) - } - } -} - -func BenchmarkUtilsCellCount(b *testing.B) { - b.ReportAllocs() - for i := 0; i < b.N; i++ { - CellCount(testColorString) - } -} diff --git a/vendor/github.com/cheggaaa/pb/writer.go b/vendor/github.com/cheggaaa/pb/writer.go deleted file mode 100644 index 9451ec5..0000000 --- a/vendor/github.com/cheggaaa/pb/writer.go +++ /dev/null @@ -1,26 +0,0 @@ -package pb - -import ( - "io" -) - -// It's proxy Writer, implement io.Writer -type Writer struct { - io.Writer - bar *ProgressBar -} - -func (r *Writer) Write(p []byte) (n int, err error) { - n, err = r.Writer.Write(p) - r.bar.Add(n) - return -} - -// Close the reader when it implements io.Closer -func (r *Writer) Close() (err error) { - r.bar.Finish() - if closer, ok := r.Writer.(io.Closer); ok { - return closer.Close() - } - return -} diff --git a/vendor/github.com/dchest/.directory b/vendor/github.com/dchest/.directory deleted file mode 100644 index dcad5d9..0000000 --- a/vendor/github.com/dchest/.directory +++ /dev/null @@ -1,6 +0,0 @@ -[Dolphin] -Timestamp=2018,1,11,12,15,22 -Version=3 - -[Settings] -HiddenFilesShown=true diff --git a/vendor/github.com/dchest/blake256/README.markdown b/vendor/github.com/dchest/blake256/README.markdown deleted file mode 100644 index 98426c2..0000000 --- a/vendor/github.com/dchest/blake256/README.markdown +++ /dev/null @@ -1,56 +0,0 @@ -Package blake256 -===================== - - import "github.com/dchest/blake256" - -Package blake256 implements BLAKE-256 and BLAKE-224 hash functions (SHA-3 -candidate). - -Public domain. - - -Constants ---------- - -``` go -const BlockSize = 64 -``` -The block size of the hash algorithm in bytes. - -``` go -const Size = 32 -``` -The size of BLAKE-256 hash in bytes. - -``` go -const Size224 = 28 -``` -The size of BLAKE-224 hash in bytes. - - -Functions ---------- - -### func New - - func New() hash.Hash - -New returns a new hash.Hash computing the BLAKE-256 checksum. - -### func New224 - - func New224() hash.Hash - -New224 returns a new hash.Hash computing the BLAKE-224 checksum. - -### func New224Salt - - func New224Salt(salt []byte) hash.Hash - -New224Salt is like New224 but initializes salt with the given 16-byte slice. - -### func NewSalt - - func NewSalt(salt []byte) hash.Hash - -NewSalt is like New but initializes salt with the given 16-byte slice. diff --git a/vendor/github.com/dchest/blake256/blake256.go b/vendor/github.com/dchest/blake256/blake256.go deleted file mode 100644 index 148ec9e..0000000 --- a/vendor/github.com/dchest/blake256/blake256.go +++ /dev/null @@ -1,194 +0,0 @@ -// Written in 2011-2012 by Dmitry Chestnykh. -// -// To the extent possible under law, the author have dedicated all copyright -// and related and neighboring rights to this software to the public domain -// worldwide. This software is distributed without any warranty. -// http://creativecommons.org/publicdomain/zero/1.0/ - -// Package blake256 implements BLAKE-256 and BLAKE-224 hash functions (SHA-3 -// candidate). -package blake256 - -import "hash" - -// The block size of the hash algorithm in bytes. -const BlockSize = 64 - -// The size of BLAKE-256 hash in bytes. -const Size = 32 - -// The size of BLAKE-224 hash in bytes. -const Size224 = 28 - -type digest struct { - hashSize int // hash output size in bits (224 or 256) - h [8]uint32 // current chain value - s [4]uint32 // salt (zero by default) - t uint64 // message bits counter - nullt bool // special case for finalization: skip counter - x [BlockSize]byte // buffer for data not yet compressed - nx int // number of bytes in buffer -} - -var ( - // Initialization values. - iv256 = [8]uint32{ - 0x6A09E667, 0xBB67AE85, 0x3C6EF372, 0xA54FF53A, - 0x510E527F, 0x9B05688C, 0x1F83D9AB, 0x5BE0CD19} - - iv224 = [8]uint32{ - 0xC1059ED8, 0x367CD507, 0x3070DD17, 0xF70E5939, - 0xFFC00B31, 0x68581511, 0x64F98FA7, 0xBEFA4FA4} - - pad = [64]byte{0x80} -) - -// Reset resets the state of digest. It leaves salt intact. -func (d *digest) Reset() { - if d.hashSize == 224 { - d.h = iv224 - } else { - d.h = iv256 - } - d.t = 0 - d.nx = 0 - d.nullt = false -} - -func (d *digest) Size() int { return d.hashSize >> 3 } - -func (d *digest) BlockSize() int { return BlockSize } - -func (d *digest) Write(p []byte) (nn int, err error) { - nn = len(p) - if d.nx > 0 { - n := len(p) - if n > BlockSize-d.nx { - n = BlockSize - d.nx - } - d.nx += copy(d.x[d.nx:], p) - if d.nx == BlockSize { - block(d, d.x[:]) - d.nx = 0 - } - p = p[n:] - } - if len(p) >= BlockSize { - n := len(p) &^ (BlockSize - 1) - block(d, p[:n]) - p = p[n:] - } - if len(p) > 0 { - d.nx = copy(d.x[:], p) - } - return -} - -// Sum returns the calculated checksum. -func (d0 *digest) Sum(in []byte) []byte { - // Make a copy of d0 so that caller can keep writing and summing. - d := *d0 - - nx := uint64(d.nx) - l := d.t + nx<<3 - len := make([]byte, 8) - len[0] = byte(l >> 56) - len[1] = byte(l >> 48) - len[2] = byte(l >> 40) - len[3] = byte(l >> 32) - len[4] = byte(l >> 24) - len[5] = byte(l >> 16) - len[6] = byte(l >> 8) - len[7] = byte(l) - - if nx == 55 { - // One padding byte. - d.t -= 8 - if d.hashSize == 224 { - d.Write([]byte{0x80}) - } else { - d.Write([]byte{0x81}) - } - } else { - if nx < 55 { - // Enough space to fill the block. - if nx == 0 { - d.nullt = true - } - d.t -= 440 - nx<<3 - d.Write(pad[0 : 55-nx]) - } else { - // Need 2 compressions. - d.t -= 512 - nx<<3 - d.Write(pad[0 : 64-nx]) - d.t -= 440 - d.Write(pad[1:56]) - d.nullt = true - } - if d.hashSize == 224 { - d.Write([]byte{0x00}) - } else { - d.Write([]byte{0x01}) - } - d.t -= 8 - } - d.t -= 64 - d.Write(len) - - out := make([]byte, d.Size()) - j := 0 - for _, s := range d.h[:d.hashSize>>5] { - out[j+0] = byte(s >> 24) - out[j+1] = byte(s >> 16) - out[j+2] = byte(s >> 8) - out[j+3] = byte(s >> 0) - j += 4 - } - return append(in, out...) -} - -func (d *digest) setSalt(s []byte) { - if len(s) != 16 { - panic("salt length must be 16 bytes") - } - d.s[0] = uint32(s[0])<<24 | uint32(s[1])<<16 | uint32(s[2])<<8 | uint32(s[3]) - d.s[1] = uint32(s[4])<<24 | uint32(s[5])<<16 | uint32(s[6])<<8 | uint32(s[7]) - d.s[2] = uint32(s[8])<<24 | uint32(s[9])<<16 | uint32(s[10])<<8 | uint32(s[11]) - d.s[3] = uint32(s[12])<<24 | uint32(s[13])<<16 | uint32(s[14])<<8 | uint32(s[15]) -} - -// New returns a new hash.Hash computing the BLAKE-256 checksum. -func New() hash.Hash { - return &digest{ - hashSize: 256, - h: iv256, - } -} - -// NewSalt is like New but initializes salt with the given 16-byte slice. -func NewSalt(salt []byte) hash.Hash { - d := &digest{ - hashSize: 256, - h: iv256, - } - d.setSalt(salt) - return d -} - -// New224 returns a new hash.Hash computing the BLAKE-224 checksum. -func New224() hash.Hash { - return &digest{ - hashSize: 224, - h: iv224, - } -} - -// New224Salt is like New224 but initializes salt with the given 16-byte slice. -func New224Salt(salt []byte) hash.Hash { - d := &digest{ - hashSize: 224, - h: iv224, - } - d.setSalt(salt) - return d -} diff --git a/vendor/github.com/dchest/blake256/blake256_test.go b/vendor/github.com/dchest/blake256/blake256_test.go deleted file mode 100644 index 1908133..0000000 --- a/vendor/github.com/dchest/blake256/blake256_test.go +++ /dev/null @@ -1,188 +0,0 @@ -// Written in 2011-2012 by Dmitry Chestnykh. -// -// To the extent possible under law, the author have dedicated all copyright -// and related and neighboring rights to this software to the public domain -// worldwide. This software is distributed without any warranty. -// http://creativecommons.org/publicdomain/zero/1.0/ - -package blake256 - -import ( - "bytes" - "fmt" - "hash" - "testing" -) - -func Test256C(t *testing.T) { - // Test as in C program. - var hashes = [][]byte{ - { - 0x0C, 0xE8, 0xD4, 0xEF, 0x4D, 0xD7, 0xCD, 0x8D, - 0x62, 0xDF, 0xDE, 0xD9, 0xD4, 0xED, 0xB0, 0xA7, - 0x74, 0xAE, 0x6A, 0x41, 0x92, 0x9A, 0x74, 0xDA, - 0x23, 0x10, 0x9E, 0x8F, 0x11, 0x13, 0x9C, 0x87, - }, - { - 0xD4, 0x19, 0xBA, 0xD3, 0x2D, 0x50, 0x4F, 0xB7, - 0xD4, 0x4D, 0x46, 0x0C, 0x42, 0xC5, 0x59, 0x3F, - 0xE5, 0x44, 0xFA, 0x4C, 0x13, 0x5D, 0xEC, 0x31, - 0xE2, 0x1B, 0xD9, 0xAB, 0xDC, 0xC2, 0x2D, 0x41, - }, - } - data := make([]byte, 72) - - h := New() - h.Write(data[:1]) - sum := h.Sum(nil) - if !bytes.Equal(hashes[0], sum) { - t.Errorf("0: expected %X, got %X", hashes[0], sum) - } - - // Try to continue hashing. - h.Write(data[1:]) - sum = h.Sum(nil) - if !bytes.Equal(hashes[1], sum) { - t.Errorf("1(1): expected %X, got %X", hashes[1], sum) - } - - // Try with reset. - h.Reset() - h.Write(data) - sum = h.Sum(nil) - if !bytes.Equal(hashes[1], sum) { - t.Errorf("1(2): expected %X, got %X", hashes[1], sum) - } -} - -type blakeVector struct { - out, in string -} - -var vectors256 = []blakeVector{ - {"7576698ee9cad30173080678e5965916adbb11cb5245d386bf1ffda1cb26c9d7", - "The quick brown fox jumps over the lazy dog"}, - {"07663e00cf96fbc136cf7b1ee099c95346ba3920893d18cc8851f22ee2e36aa6", - "BLAKE"}, - {"716f6e863f744b9ac22c97ec7b76ea5f5908bc5b2f67c61510bfc4751384ea7a", - ""}, - {"18a393b4e62b1887a2edf79a5c5a5464daf5bbb976f4007bea16a73e4c1e198e", - "'BLAKE wins SHA-3! Hooray!!!' (I have time machine)"}, - {"fd7282ecc105ef201bb94663fc413db1b7696414682090015f17e309b835f1c2", - "Go"}, - {"1e75db2a709081f853c2229b65fd1558540aa5e7bd17b04b9a4b31989effa711", - "HELP! I'm trapped in hash!"}, - {"4181475cb0c22d58ae847e368e91b4669ea2d84bcd55dbf01fe24bae6571dd08", - `Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congue ligula ac quam viverra nec consectetur ante hendrerit. Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean ut gravida lorem. Ut turpis felis, pulvinar a semper sed, adipiscing id dolor. Pellentesque auctor nisi id magna consequat sagittis. Curabitur dapibus enim sit amet elit pharetra tincidunt feugiat nisl imperdiet. Ut convallis libero in urna ultrices accumsan. Donec sed odio eros. Donec viverra mi quis quam pulvinar at malesuada arcu rhoncus. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. In rutrum accumsan ultricies. Mauris vitae nisi at sem facilisis semper ac in est.`, - }, - {"af95fffc7768821b1e08866a2f9f66916762bfc9d71c4acb5fd515f31fd6785a", // test with one padding byte - "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit amet ipsum mauris. Maecenas congu", - }, -} - -var vectors224 = []blakeVector{ - {"c8e92d7088ef87c1530aee2ad44dc720cc10589cc2ec58f95a15e51b", - "The quick brown fox jumps over the lazy dog"}, - {"cfb6848add73e1cb47994c4765df33b8f973702705a30a71fe4747a3", - "BLAKE"}, - {"7dc5313b1c04512a174bd6503b89607aecbee0903d40a8a569c94eed", - ""}, - {"dde9e442003c24495db607b17e07ec1f67396cc1907642a09a96594e", - "Go"}, - {"9f655b0a92d4155754fa35e055ce7c5e18eb56347081ea1e5158e751", - "Buffalo buffalo Buffalo buffalo buffalo buffalo Buffalo buffalo"}, -} - -func testVectors(t *testing.T, hashfunc func() hash.Hash, vectors []blakeVector) { - for i, v := range vectors { - h := hashfunc() - h.Write([]byte(v.in)) - res := fmt.Sprintf("%x", h.Sum(nil)) - if res != v.out { - t.Errorf("%d: expected %q, got %q", i, v.out, res) - } - } -} - -func Test256(t *testing.T) { - testVectors(t, New, vectors256) -} - -func Test224(t *testing.T) { - testVectors(t, New224, vectors224) -} - -var vectors256salt = []struct{ out, in, salt string }{ - {"561d6d0cfa3d31d5eedaf2d575f3942539b03522befc2a1196ba0e51af8992a8", - "", - "1234567890123456"}, - {"88cc11889bbbee42095337fe2153c591971f94fbf8fe540d3c7e9f1700ab2d0c", - "It's so salty out there!", - "SALTsaltSaltSALT"}, -} - -func TestSalt(t *testing.T) { - for i, v := range vectors256salt { - h := NewSalt([]byte(v.salt)) - h.Write([]byte(v.in)) - res := fmt.Sprintf("%x", h.Sum(nil)) - if res != v.out { - t.Errorf("%d: expected %q, got %q", i, v.out, res) - } - } - - // Check that passing bad salt length panics. - defer func() { - if err := recover(); err == nil { - t.Errorf("expected panic for bad salt length") - } - }() - NewSalt([]byte{1, 2, 3, 4, 5, 6, 7, 8}) -} - -func TestTwoWrites(t *testing.T) { - b := make([]byte, 65) - for i := range b { - b[i] = byte(i) - } - h1 := New() - h1.Write(b[:1]) - h1.Write(b[1:]) - sum1 := h1.Sum(nil) - - h2 := New() - h2.Write(b) - sum2 := h2.Sum(nil) - - if !bytes.Equal(sum1, sum2) { - t.Errorf("Result of two writes differs from a single write with the same bytes") - } -} - -var bench = New() -var buf = make([]byte, 8<<10) - -func BenchmarkHash1K(b *testing.B) { - b.SetBytes(1024) - for i := 0; i < b.N; i++ { - bench.Write(buf[:1024]) - } -} - -func BenchmarkHash8K(b *testing.B) { - b.SetBytes(int64(len(buf))) - for i := 0; i < b.N; i++ { - bench.Write(buf) - } -} - -func BenchmarkFull64(b *testing.B) { - b.SetBytes(64) - tmp := make([]byte, 32) - b.ResetTimer() - for i := 0; i < b.N; i++ { - bench.Reset() - bench.Write(buf[:64]) - bench.Sum(tmp[0:0]) - } -} diff --git a/vendor/github.com/dchest/blake256/blake256block.go b/vendor/github.com/dchest/blake256/blake256block.go deleted file mode 100644 index 49daf69..0000000 --- a/vendor/github.com/dchest/blake256/blake256block.go +++ /dev/null @@ -1,1681 +0,0 @@ -// Written in 2011-2012 by Dmitry Chestnykh. -// -// To the extent possible under law, the author have dedicated all copyright -// and related and neighboring rights to this software to the public domain -// worldwide. This software is distributed without any warranty. -// http://creativecommons.org/publicdomain/zero/1.0/ - -// BLAKE-256 block step. -// In its own file so that a faster assembly or C version -// can be substituted easily. - -package blake256 - -const ( - cst0 = 0x243F6A88 - cst1 = 0x85A308D3 - cst2 = 0x13198A2E - cst3 = 0x03707344 - cst4 = 0xA4093822 - cst5 = 0x299F31D0 - cst6 = 0x082EFA98 - cst7 = 0xEC4E6C89 - cst8 = 0x452821E6 - cst9 = 0x38D01377 - cst10 = 0xBE5466CF - cst11 = 0x34E90C6C - cst12 = 0xC0AC29B7 - cst13 = 0xC97C50DD - cst14 = 0x3F84D5B5 - cst15 = 0xB5470917 -) - -func block(d *digest, p []uint8) { - h0, h1, h2, h3, h4, h5, h6, h7 := d.h[0], d.h[1], d.h[2], d.h[3], d.h[4], d.h[5], d.h[6], d.h[7] - s0, s1, s2, s3 := d.s[0], d.s[1], d.s[2], d.s[3] - - for len(p) >= BlockSize { - v0, v1, v2, v3, v4, v5, v6, v7 := h0, h1, h2, h3, h4, h5, h6, h7 - v8 := cst0 ^ s0 - v9 := cst1 ^ s1 - v10 := cst2 ^ s2 - v11 := cst3 ^ s3 - v12 := uint32(cst4) - v13 := uint32(cst5) - v14 := uint32(cst6) - v15 := uint32(cst7) - d.t += 512 - if !d.nullt { - v12 ^= uint32(d.t) - v13 ^= uint32(d.t) - v14 ^= uint32(d.t >> 32) - v15 ^= uint32(d.t >> 32) - } - var m [16]uint32 - - m[0] = uint32(p[0])<<24 | uint32(p[1])<<16 | uint32(p[2])<<8 | uint32(p[3]) - m[1] = uint32(p[4])<<24 | uint32(p[5])<<16 | uint32(p[6])<<8 | uint32(p[7]) - m[2] = uint32(p[8])<<24 | uint32(p[9])<<16 | uint32(p[10])<<8 | uint32(p[11]) - m[3] = uint32(p[12])<<24 | uint32(p[13])<<16 | uint32(p[14])<<8 | uint32(p[15]) - m[4] = uint32(p[16])<<24 | uint32(p[17])<<16 | uint32(p[18])<<8 | uint32(p[19]) - m[5] = uint32(p[20])<<24 | uint32(p[21])<<16 | uint32(p[22])<<8 | uint32(p[23]) - m[6] = uint32(p[24])<<24 | uint32(p[25])<<16 | uint32(p[26])<<8 | uint32(p[27]) - m[7] = uint32(p[28])<<24 | uint32(p[29])<<16 | uint32(p[30])<<8 | uint32(p[31]) - m[8] = uint32(p[32])<<24 | uint32(p[33])<<16 | uint32(p[34])<<8 | uint32(p[35]) - m[9] = uint32(p[36])<<24 | uint32(p[37])<<16 | uint32(p[38])<<8 | uint32(p[39]) - m[10] = uint32(p[40])<<24 | uint32(p[41])<<16 | uint32(p[42])<<8 | uint32(p[43]) - m[11] = uint32(p[44])<<24 | uint32(p[45])<<16 | uint32(p[46])<<8 | uint32(p[47]) - m[12] = uint32(p[48])<<24 | uint32(p[49])<<16 | uint32(p[50])<<8 | uint32(p[51]) - m[13] = uint32(p[52])<<24 | uint32(p[53])<<16 | uint32(p[54])<<8 | uint32(p[55]) - m[14] = uint32(p[56])<<24 | uint32(p[57])<<16 | uint32(p[58])<<8 | uint32(p[59]) - m[15] = uint32(p[60])<<24 | uint32(p[61])<<16 | uint32(p[62])<<8 | uint32(p[63]) - - // Round 1. - v0 += m[0] ^ cst1 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[2] ^ cst3 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[4] ^ cst5 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[6] ^ cst7 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[5] ^ cst4 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[7] ^ cst6 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[3] ^ cst2 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[1] ^ cst0 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[8] ^ cst9 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[10] ^ cst11 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[12] ^ cst13 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[14] ^ cst15 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[13] ^ cst12 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[15] ^ cst14 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[11] ^ cst10 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[9] ^ cst8 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 2. - v0 += m[14] ^ cst10 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[4] ^ cst8 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[9] ^ cst15 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[13] ^ cst6 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[15] ^ cst9 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[6] ^ cst13 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[8] ^ cst4 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[10] ^ cst14 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[1] ^ cst12 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[0] ^ cst2 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[11] ^ cst7 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[5] ^ cst3 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[7] ^ cst11 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[3] ^ cst5 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[2] ^ cst0 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[12] ^ cst1 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 3. - v0 += m[11] ^ cst8 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[12] ^ cst0 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[5] ^ cst2 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[15] ^ cst13 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[2] ^ cst5 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[13] ^ cst15 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[0] ^ cst12 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[8] ^ cst11 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[10] ^ cst14 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[3] ^ cst6 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[7] ^ cst1 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[9] ^ cst4 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[1] ^ cst7 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[4] ^ cst9 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[6] ^ cst3 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[14] ^ cst10 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 4. - v0 += m[7] ^ cst9 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[3] ^ cst1 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[13] ^ cst12 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[11] ^ cst14 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[12] ^ cst13 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[14] ^ cst11 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[1] ^ cst3 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[9] ^ cst7 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[2] ^ cst6 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[5] ^ cst10 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[4] ^ cst0 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[15] ^ cst8 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[0] ^ cst4 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[8] ^ cst15 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[10] ^ cst5 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[6] ^ cst2 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 5. - v0 += m[9] ^ cst0 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[5] ^ cst7 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[2] ^ cst4 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[10] ^ cst15 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[4] ^ cst2 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[15] ^ cst10 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[7] ^ cst5 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[0] ^ cst9 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[14] ^ cst1 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[11] ^ cst12 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[6] ^ cst8 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[3] ^ cst13 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[8] ^ cst6 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[13] ^ cst3 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[12] ^ cst11 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[1] ^ cst14 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 6. - v0 += m[2] ^ cst12 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[6] ^ cst10 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[0] ^ cst11 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[8] ^ cst3 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[11] ^ cst0 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[3] ^ cst8 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[10] ^ cst6 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[12] ^ cst2 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[4] ^ cst13 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[7] ^ cst5 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[15] ^ cst14 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[1] ^ cst9 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[14] ^ cst15 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[9] ^ cst1 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[5] ^ cst7 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[13] ^ cst4 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 7. - v0 += m[12] ^ cst5 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[1] ^ cst15 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[14] ^ cst13 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[4] ^ cst10 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[13] ^ cst14 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[10] ^ cst4 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[15] ^ cst1 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[5] ^ cst12 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[0] ^ cst7 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[6] ^ cst3 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[9] ^ cst2 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[8] ^ cst11 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[2] ^ cst9 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[11] ^ cst8 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[3] ^ cst6 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[7] ^ cst0 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 8. - v0 += m[13] ^ cst11 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[7] ^ cst14 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[12] ^ cst1 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[3] ^ cst9 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[1] ^ cst12 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[9] ^ cst3 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[14] ^ cst7 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[11] ^ cst13 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[5] ^ cst0 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[15] ^ cst4 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[8] ^ cst6 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[2] ^ cst10 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[6] ^ cst8 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[10] ^ cst2 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[4] ^ cst15 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[0] ^ cst5 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 9. - v0 += m[6] ^ cst15 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[14] ^ cst9 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[11] ^ cst3 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[0] ^ cst8 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[3] ^ cst11 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[8] ^ cst0 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[9] ^ cst14 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[15] ^ cst6 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[12] ^ cst2 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[13] ^ cst7 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[1] ^ cst4 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[10] ^ cst5 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[4] ^ cst1 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[5] ^ cst10 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[7] ^ cst13 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[2] ^ cst12 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 10. - v0 += m[10] ^ cst2 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[8] ^ cst4 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[7] ^ cst6 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[1] ^ cst5 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[6] ^ cst7 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[5] ^ cst1 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[4] ^ cst8 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[2] ^ cst10 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[15] ^ cst11 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[9] ^ cst14 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[3] ^ cst12 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[13] ^ cst0 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[12] ^ cst3 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[0] ^ cst13 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[14] ^ cst9 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[11] ^ cst15 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 11. - v0 += m[0] ^ cst1 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[2] ^ cst3 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[4] ^ cst5 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[6] ^ cst7 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[5] ^ cst4 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[7] ^ cst6 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[3] ^ cst2 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[1] ^ cst0 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[8] ^ cst9 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[10] ^ cst11 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[12] ^ cst13 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[14] ^ cst15 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[13] ^ cst12 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[15] ^ cst14 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[11] ^ cst10 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[9] ^ cst8 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 12. - v0 += m[14] ^ cst10 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[4] ^ cst8 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[9] ^ cst15 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[13] ^ cst6 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[15] ^ cst9 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[6] ^ cst13 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[8] ^ cst4 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[10] ^ cst14 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[1] ^ cst12 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[0] ^ cst2 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[11] ^ cst7 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[5] ^ cst3 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[7] ^ cst11 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[3] ^ cst5 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[2] ^ cst0 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[12] ^ cst1 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 13. - v0 += m[11] ^ cst8 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[12] ^ cst0 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[5] ^ cst2 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[15] ^ cst13 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[2] ^ cst5 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[13] ^ cst15 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[0] ^ cst12 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[8] ^ cst11 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[10] ^ cst14 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[3] ^ cst6 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[7] ^ cst1 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[9] ^ cst4 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[1] ^ cst7 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[4] ^ cst9 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[6] ^ cst3 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[14] ^ cst10 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - // Round 14. - v0 += m[7] ^ cst9 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-16) | v12>>16 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-12) | v4>>12 - v1 += m[3] ^ cst1 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-16) | v13>>16 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-12) | v5>>12 - v2 += m[13] ^ cst12 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-16) | v14>>16 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-12) | v6>>12 - v3 += m[11] ^ cst14 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-16) | v15>>16 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-12) | v7>>12 - v2 += m[12] ^ cst13 - v2 += v6 - v14 ^= v2 - v14 = v14<<(32-8) | v14>>8 - v10 += v14 - v6 ^= v10 - v6 = v6<<(32-7) | v6>>7 - v3 += m[14] ^ cst11 - v3 += v7 - v15 ^= v3 - v15 = v15<<(32-8) | v15>>8 - v11 += v15 - v7 ^= v11 - v7 = v7<<(32-7) | v7>>7 - v1 += m[1] ^ cst3 - v1 += v5 - v13 ^= v1 - v13 = v13<<(32-8) | v13>>8 - v9 += v13 - v5 ^= v9 - v5 = v5<<(32-7) | v5>>7 - v0 += m[9] ^ cst7 - v0 += v4 - v12 ^= v0 - v12 = v12<<(32-8) | v12>>8 - v8 += v12 - v4 ^= v8 - v4 = v4<<(32-7) | v4>>7 - v0 += m[2] ^ cst6 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-16) | v15>>16 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-12) | v5>>12 - v1 += m[5] ^ cst10 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-16) | v12>>16 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-12) | v6>>12 - v2 += m[4] ^ cst0 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-16) | v13>>16 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-12) | v7>>12 - v3 += m[15] ^ cst8 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-16) | v14>>16 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-12) | v4>>12 - v2 += m[0] ^ cst4 - v2 += v7 - v13 ^= v2 - v13 = v13<<(32-8) | v13>>8 - v8 += v13 - v7 ^= v8 - v7 = v7<<(32-7) | v7>>7 - v3 += m[8] ^ cst15 - v3 += v4 - v14 ^= v3 - v14 = v14<<(32-8) | v14>>8 - v9 += v14 - v4 ^= v9 - v4 = v4<<(32-7) | v4>>7 - v1 += m[10] ^ cst5 - v1 += v6 - v12 ^= v1 - v12 = v12<<(32-8) | v12>>8 - v11 += v12 - v6 ^= v11 - v6 = v6<<(32-7) | v6>>7 - v0 += m[6] ^ cst2 - v0 += v5 - v15 ^= v0 - v15 = v15<<(32-8) | v15>>8 - v10 += v15 - v5 ^= v10 - v5 = v5<<(32-7) | v5>>7 - - h0 ^= v0 ^ v8 ^ s0 - h1 ^= v1 ^ v9 ^ s1 - h2 ^= v2 ^ v10 ^ s2 - h3 ^= v3 ^ v11 ^ s3 - h4 ^= v4 ^ v12 ^ s0 - h5 ^= v5 ^ v13 ^ s1 - h6 ^= v6 ^ v14 ^ s2 - h7 ^= v7 ^ v15 ^ s3 - - p = p[BlockSize:] - } - d.h[0], d.h[1], d.h[2], d.h[3], d.h[4], d.h[5], d.h[6], d.h[7] = h0, h1, h2, h3, h4, h5, h6, h7 -} diff --git a/vendor/github.com/deroproject/graviton/cursor.go b/vendor/github.com/deroproject/graviton/cursor.go index f11d4c8..53b5c7f 100644 --- a/vendor/github.com/deroproject/graviton/cursor.go +++ b/vendor/github.com/deroproject/graviton/cursor.go @@ -10,7 +10,8 @@ type Cursor struct { tree *Tree node_path []*inner - left []bool + left []bool // it basically represents the path as bools + } // get Cursor which is used as an iterator that can traverse over all key/value pairs in a tree in hash sorted order. diff --git a/vendor/github.com/deroproject/graviton/extra.go b/vendor/github.com/deroproject/graviton/extra.go index 3f31828..84094d9 100644 --- a/vendor/github.com/deroproject/graviton/extra.go +++ b/vendor/github.com/deroproject/graviton/extra.go @@ -4,6 +4,10 @@ import "fmt" import "math" import "crypto/rand" + +func (t *Tree) GetName() (string) { + return t.treename +} // Random returns a random key,value from the tree, provided a tree has keys // the following are limitations // a tree containing 0 key, value pairs will return err diff --git a/vendor/github.com/deroproject/graviton/go.mod b/vendor/github.com/deroproject/graviton/go.mod new file mode 100644 index 0000000..e0c388a --- /dev/null +++ b/vendor/github.com/deroproject/graviton/go.mod @@ -0,0 +1,3 @@ +module github.com/deroproject/graviton + +go 1.14 diff --git a/vendor/github.com/deroproject/graviton/special.go b/vendor/github.com/deroproject/graviton/special.go index 3ec5430..de99784 100644 --- a/vendor/github.com/deroproject/graviton/special.go +++ b/vendor/github.com/deroproject/graviton/special.go @@ -3,11 +3,30 @@ package graviton //import "io" //import "math" +import "fmt" +import "bytes" import "golang.org/x/xerrors" +// this file contains some functions ( to extend read-only api). these apis are used in the dero blockchain. + +func Sum(key []byte) [HASHSIZE]byte { + return sum(key) +} + +// we have a key and need to get both the key,value +func (t *Tree) GetKeyValueFromKey(key []byte) (int, []byte, []byte, error) { + return t.root.GetKeyValue(t.store, sum(key), 256, 0) +} + // we only have a keyhash and need to get both the key,value -func (t *Tree) GetKeyValue(keyhash [HASHSIZE]byte) (int, []byte, []byte, error) { - return t.root.GetKeyValue(t.store, keyhash, 256, 0) +func (t *Tree) GetKeyValueFromHash(keyhashc []byte) (int, []byte, []byte, error) { + var keyhash [HASHSIZE]byte + if len(keyhashc) <= 0 || len(keyhashc) > HASHSIZE { + return 0, nil, nil, fmt.Errorf("keyhashc must be atleast 1 byte and less than 33 bytes, len=%d", len(keyhashc)) + } + copy(keyhash[:], keyhashc) + + return t.root.GetKeyValue(t.store, keyhash, len(keyhashc)*8, 0) } func (in *inner) GetKeyValue(store *Store, keyhash [HASHSIZE]byte, valid_bit_count, used_bit_count int) (int, []byte, []byte, error) { @@ -54,9 +73,69 @@ func (l *leaf) GetKeyValue(store *Store, keyhash [HASHSIZE]byte, valid_bit_count } } - if l.keyhash == keyhash { + if bytes.Compare(l.keyhash[:valid_bit_count/8], keyhash[:valid_bit_count/8]) == 0 { return used_bit_count, l.key, l.value, nil } return used_bit_count, nil, nil, xerrors.Errorf("%w: collision, keyhash %x not found", ErrNotFound, keyhash) } + +// sets a root for the cursor, so the cursor visits only a specific prefix keys +func (c *Cursor) SpecialFirst(section []byte, validbits uint) (k, v []byte, err error) { + loop_node := node(c.tree.root) // we always start at root node + + donebits := uint(0) + + if validbits >= 256 { + err = fmt.Errorf("invalid valid bits %d", validbits) + return + } + + if validbits == 0 { + return c.First() + } + + // the function is iterative and not recursive + for { + switch node := loop_node.(type) { + case *inner: + if node.loaded_partial { // if node is loaded partially, load it fully now + if err = node.loadinnerfromstore(c.tree.store); err != nil { + return + } + } + + left, right := node.left, node.right + if isBitSet(section, donebits) { // 1 is right + if right == nil { + err = ErrNoMoreKeys + return + } + loop_node = right + } else { //0 is left + if left == nil { + err = ErrNoMoreKeys + return + } + loop_node = left + } + donebits++ + + if donebits < validbits { + continue + } else if donebits == validbits { + return c.next_internal(loop_node, false) + } + + // we can only reach here if a tree has both left,right nil, ie an empty tree + err = ErrNoMoreKeys + return + + case *leaf: + err = ErrNoMoreKeys + return + default: + return k, v, fmt.Errorf("unknown node type, corruption") + } + } +} diff --git a/vendor/github.com/dgraph-io/badger/.travis.yml b/vendor/github.com/dgraph-io/badger/.travis.yml deleted file mode 100644 index c942e02..0000000 --- a/vendor/github.com/dgraph-io/badger/.travis.yml +++ /dev/null @@ -1,20 +0,0 @@ -language: go -go: 1.9 -matrix: - include: - - os: osx -notifications: - email: false - slack: - secure: X7uBLWYbuUhf8QFE16CoS5z7WvFR8EN9j6cEectMW6mKZ3vwXGwVXRIPsgUq/606DsQdCCx34MR8MRWYGlu6TBolbSe9y0EP0i46yipPz22YtuT7umcVUbGEyx8MZKgG0v1u/zA0O4aCsOBpGAA3gxz8h3JlEHDt+hv6U8xRsSllVLzLSNb5lwxDtcfEDxVVqP47GMEgjLPM28Pyt5qwjk7o5a4YSVzkfdxBXxd3gWzFUWzJ5E3cTacli50dK4GVfiLcQY2aQYoYO7AAvDnvP+TPfjDkBlUEE4MUz5CDIN51Xb+WW33s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_script: -- go get github.com/mattn/goveralls -script: -- bash contrib/cover.sh $HOME/build coverage.out || travis_terminate 1 -- goveralls -service=travis-ci -coverprofile=coverage.out || true -- goveralls -coverprofile=coverage.out -service=travis-ci diff --git a/vendor/github.com/dgraph-io/badger/CHANGELOG.md b/vendor/github.com/dgraph-io/badger/CHANGELOG.md deleted file mode 100644 index abab551..0000000 --- a/vendor/github.com/dgraph-io/badger/CHANGELOG.md +++ /dev/null @@ -1,69 +0,0 @@ -# Changelog -All notable changes to this project will be documented in this file. - -The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) -and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). - -## [Unreleased] - -## [1.5.0] - 2018-05-08 -* Introduce `NumVersionsToKeep` option. This option is used to discard many - versions of the same key, which saves space. -* Add a new `SetWithDiscard` method, which would indicate that all the older - versions of the key are now invalid. Those versions would be discarded during - compactions. -* Value log GC moves are now bound to another keyspace to ensure latest versions - of data are always at the top in LSM tree. -* Introduce `ValueLogMaxEntries` to restrict the number of key-value pairs per - value log file. This helps bound the time it takes to garbage collect one - file. - -## [1.4.0] - 2018-05-04 -* Make mmap-ing of value log optional. -* Run GC multiple times, based on recorded discard statistics. -* Add MergeOperator. -* Force compact L0 on clsoe (#439). -* Add truncate option to warn about data loss (#452). -* Discard key versions during compaction (#464). -* Introduce new `LSMOnlyOptions`, to make Badger act like a typical LSM based DB. - -Bug fix: -* [Temporary] Check max version across all tables in Get (removed in next - release). -* Update commit and read ts while loading from backup. -* Ensure all transaction entries are part of the same value log file. -* On commit, run unlock callbacks before doing writes (#413). -* Wait for goroutines to finish before closing iterators (#421). - -## [1.3.0] - 2017-12-12 -* Add `DB.NextSequence()` method to generate monotonically increasing integer - sequences. -* Add `DB.Size()` method to return the size of LSM and value log files. -* Tweaked mmap code to make Windows 32-bit builds work. -* Tweaked build tags on some files to make iOS builds work. -* Fix `DB.PurgeOlderVersions()` to not violate some constraints. - -## [1.2.0] - 2017-11-30 -* Expose a `Txn.SetEntry()` method to allow setting the key-value pair - and all the metadata at the same time. - -## [1.1.1] - 2017-11-28 -* Fix bug where txn.Get was returing key deleted in same transaction. -* Fix race condition while decrementing reference in oracle. -* Update doneCommit in the callback for CommitAsync. -* Iterator see writes of current txn. - -## [1.1.0] - 2017-11-13 -* Create Badger directory if it does not exist when `badger.Open` is called. -* Added `Item.ValueCopy()` to avoid deadlocks in long-running iterations -* Fixed 64-bit alignment issues to make Badger run on Arm v7 - -## [1.0.1] - 2017-11-06 -* Fix an uint16 overflow when resizing key slice - -[Unreleased]: https://github.com/dgraph-io/badger/compare/v1.3.0...HEAD -[1.3.0]: https://github.com/dgraph-io/badger/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/dgraph-io/badger/compare/v1.1.1...v1.2.0 -[1.1.1]: https://github.com/dgraph-io/badger/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/dgraph-io/badger/compare/v1.0.1...v1.1.0 -[1.0.1]: https://github.com/dgraph-io/badger/compare/v1.0.0...v1.0.1 diff --git a/vendor/github.com/dgraph-io/badger/LICENSE b/vendor/github.com/dgraph-io/badger/LICENSE deleted file mode 100644 index d9a10c0..0000000 --- a/vendor/github.com/dgraph-io/badger/LICENSE +++ /dev/null @@ -1,176 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS diff --git a/vendor/github.com/dgraph-io/badger/README.md b/vendor/github.com/dgraph-io/badger/README.md deleted file mode 100644 index 083cb4c..0000000 --- a/vendor/github.com/dgraph-io/badger/README.md +++ /dev/null @@ -1,619 +0,0 @@ -# BadgerDB [![GoDoc](https://godoc.org/github.com/dgraph-io/badger?status.svg)](https://godoc.org/github.com/dgraph-io/badger) [![Go Report Card](https://goreportcard.com/badge/github.com/dgraph-io/badger)](https://goreportcard.com/report/github.com/dgraph-io/badger) [![Build Status](https://teamcity.dgraph.io/guestAuth/app/rest/builds/buildType:(id:Badger_UnitTests)/statusIcon.svg)](https://teamcity.dgraph.io/viewLog.html?buildTypeId=Badger_UnitTests&buildId=lastFinished&guest=1) ![Appveyor](https://ci.appveyor.com/api/projects/status/github/dgraph-io/badger?branch=master&svg=true) [![Coverage Status](https://coveralls.io/repos/github/dgraph-io/badger/badge.svg?branch=master)](https://coveralls.io/github/dgraph-io/badger?branch=master) - -![Badger mascot](images/diggy-shadow.png) - -BadgerDB is an embeddable, persistent, simple and fast key-value (KV) database -written in pure Go. It's meant to be a performant alternative to non-Go-based -key-value stores like [RocksDB](https://github.com/facebook/rocksdb). - -## Project Status -Badger v1.0 was released in Nov 2017. Check the [Changelog] for the full details. - -[Changelog]:https://github.com/dgraph-io/badger/blob/master/CHANGELOG.md - -We introduced transactions in [v0.9.0] which involved a major API change. If you have a Badger -datastore prior to that, please use [v0.8.1], but we strongly urge you to upgrade. Upgrading from -both v0.8 and v0.9 will require you to [take backups](#database-backup) and restore using the new -version. - -[v1.0.1]: //github.com/dgraph-io/badger/tree/v1.0.1 -[v0.8.1]: //github.com/dgraph-io/badger/tree/v0.8.1 -[v0.9.0]: //github.com/dgraph-io/badger/tree/v0.9.0 - -## Table of Contents - * [Getting Started](#getting-started) - + [Installing](#installing) - + [Opening a database](#opening-a-database) - + [Transactions](#transactions) - - [Read-only transactions](#read-only-transactions) - - [Read-write transactions](#read-write-transactions) - - [Managing transactions manually](#managing-transactions-manually) - + [Using key/value pairs](#using-keyvalue-pairs) - + [Monotonically increasing integers](#monotonically-increasing-integers) - * [Merge Operations](#merge-operations) - + [Setting Time To Live(TTL) and User Metadata on Keys](#setting-time-to-livettl-and-user-metadata-on-keys) - + [Iterating over keys](#iterating-over-keys) - - [Prefix scans](#prefix-scans) - - [Key-only iteration](#key-only-iteration) - + [Garbage Collection](#garbage-collection) - + [Database backup](#database-backup) - + [Memory usage](#memory-usage) - + [Statistics](#statistics) - * [Resources](#resources) - + [Blog Posts](#blog-posts) - * [Contact](#contact) - * [Design](#design) - + [Comparisons](#comparisons) - + [Benchmarks](#benchmarks) - * [Other Projects Using Badger](#other-projects-using-badger) - * [Frequently Asked Questions](#frequently-asked-questions) - -## Getting Started - -### Installing -To start using Badger, install Go 1.8 or above and run `go get`: - -```sh -$ go get github.com/dgraph-io/badger/... -``` - -This will retrieve the library and install the `badger_info` command line -utility into your `$GOBIN` path. - - -### Opening a database -The top-level object in Badger is a `DB`. It represents multiple files on disk -in specific directories, which contain the data for a single database. - -To open your database, use the `badger.Open()` function, with the appropriate -options. The `Dir` and `ValueDir` options are mandatory and must be -specified by the client. They can be set to the same value to simplify things. - -```go -package main - -import ( - "log" - - "github.com/dgraph-io/badger" -) - -func main() { - // Open the Badger database located in the /tmp/badger directory. - // It will be created if it doesn't exist. - opts := badger.DefaultOptions - opts.Dir = "/tmp/badger" - opts.ValueDir = "/tmp/badger" - db, err := badger.Open(opts) - if err != nil { - log.Fatal(err) - } - defer db.Close() -  // Your code here… -} -``` - -Please note that Badger obtains a lock on the directories so multiple processes -cannot open the same database at the same time. - -### Transactions - -#### Read-only transactions -To start a read-only transaction, you can use the `DB.View()` method: - -```go -err := db.View(func(txn *badger.Txn) error { -  // Your code here… -  return nil -}) -``` - -You cannot perform any writes or deletes within this transaction. Badger -ensures that you get a consistent view of the database within this closure. Any -writes that happen elsewhere after the transaction has started, will not be -seen by calls made within the closure. - -#### Read-write transactions -To start a read-write transaction, you can use the `DB.Update()` method: - -```go -err := db.Update(func(txn *badger.Txn) error { -  // Your code here… -  return nil -}) -``` - -All database operations are allowed inside a read-write transaction. - -Always check the returned error value. If you return an error -within your closure it will be passed through. - -An `ErrConflict` error will be reported in case of a conflict. Depending on the state -of your application, you have the option to retry the operation if you receive -this error. - -An `ErrTxnTooBig` will be reported in case the number of pending writes/deletes in -the transaction exceed a certain limit. In that case, it is best to commit the -transaction and start a new transaction immediately. Here is an example (we are -not checking for errors in some places for simplicity): - -```go -updates := make(map[string]string) -txn := db.NewTransaction(true) -for k,v := range updates { - if err := txn.Set([]byte(k),[]byte(v)); err == ErrTxnTooBig { - _ = txn.Commit() - txn = db.NewTransaction(..) - _ = txn.Set([]byte(k),[]byte(v)) - } -} -_ = txn.Commit() -``` - -#### Managing transactions manually -The `DB.View()` and `DB.Update()` methods are wrappers around the -`DB.NewTransaction()` and `Txn.Commit()` methods (or `Txn.Discard()` in case of -read-only transactions). These helper methods will start the transaction, -execute a function, and then safely discard your transaction if an error is -returned. This is the recommended way to use Badger transactions. - -However, sometimes you may want to manually create and commit your -transactions. You can use the `DB.NewTransaction()` function directly, which -takes in a boolean argument to specify whether a read-write transaction is -required. For read-write transactions, it is necessary to call `Txn.Commit()` -to ensure the transaction is committed. For read-only transactions, calling -`Txn.Discard()` is sufficient. `Txn.Commit()` also calls `Txn.Discard()` -internally to cleanup the transaction, so just calling `Txn.Commit()` is -sufficient for read-write transaction. However, if your code doesn’t call -`Txn.Commit()` for some reason (for e.g it returns prematurely with an error), -then please make sure you call `Txn.Discard()` in a `defer` block. Refer to the -code below. - -```go -// Start a writable transaction. -txn, err := db.NewTransaction(true) -if err != nil { - return err -} -defer txn.Discard() - -// Use the transaction... -err := txn.Set([]byte("answer"), []byte("42")) -if err != nil { - return err -} - -// Commit the transaction and check for error. -if err := txn.Commit(nil); err != nil { - return err -} -``` - -The first argument to `DB.NewTransaction()` is a boolean stating if the transaction -should be writable. - -Badger allows an optional callback to the `Txn.Commit()` method. Normally, the -callback can be set to `nil`, and the method will return after all the writes -have succeeded. However, if this callback is provided, the `Txn.Commit()` -method returns as soon as it has checked for any conflicts. The actual writing -to the disk happens asynchronously, and the callback is invoked once the -writing has finished, or an error has occurred. This can improve the throughput -of the application in some cases. But it also means that a transaction is not -durable until the callback has been invoked with a `nil` error value. - -### Using key/value pairs -To save a key/value pair, use the `Txn.Set()` method: - -```go -err := db.Update(func(txn *badger.Txn) error { - err := txn.Set([]byte("answer"), []byte("42")) - return err -}) -``` - -This will set the value of the `"answer"` key to `"42"`. To retrieve this -value, we can use the `Txn.Get()` method: - -```go -err := db.View(func(txn *badger.Txn) error { - item, err := txn.Get([]byte("answer")) - if err != nil { - return err - } - val, err := item.Value() - if err != nil { - return err - } - fmt.Printf("The answer is: %s\n", val) - return nil -}) -``` - -`Txn.Get()` returns `ErrKeyNotFound` if the value is not found. - -Please note that values returned from `Get()` are only valid while the -transaction is open. If you need to use a value outside of the transaction -then you must use `copy()` to copy it to another byte slice. - -Use the `Txn.Delete()` method to delete a key. - -### Monotonically increasing integers - -To get unique monotonically increasing integers with strong durability, you can -use the `DB.GetSequence` method. This method returns a `Sequence` object, which -is thread-safe and can be used concurrently via various goroutines. - -Badger would lease a range of integers to hand out from memory, with the -bandwidth provided to `DB.GetSequence`. The frequency at which disk writes are -done is determined by this lease bandwidth and the frequency of `Next` -invocations. Setting a bandwith too low would do more disk writes, setting it -too high would result in wasted integers if Badger is closed or crashes. -To avoid wasted integers, call `Release` before closing Badger. - -```go -seq, err := db.GetSequence(key, 1000) -defer seq.Release() -for { - num, err := seq.Next() -} -``` - -### Merge Operations -Badger provides support for unordered merge operations. You can define a func -of type `MergeFunc` which takes in an existing value, and a value to be -_merged_ with it. It returns a new value which is the result of the _merge_ -operation. All values are specified in byte arrays. For e.g., here is a merge -function (`add`) which adds a `uint64` value to an existing `uint64` value. - -```Go -uint64ToBytes(i uint64) []byte { - var buf [8]byte - binary.BigEndian.PutUint64(buf[:], i) - return buf[:] -} - -func bytesToUint64(b []byte) uint64 { - return binary.BigEndian.Uint64(b) -} - -// Merge function to add two uint64 numbers -func add(existing, new []byte) []byte { - return uint64ToBytes(bytesToUint64(existing) + bytesToUint64(new)) -} -``` - -This function can then be passed to the `DB.GetMergeOperator()` method, along -with a key, and a duration value. The duration specifies how often the merge -function is run on values that have been added using the `MergeOperator.Add()` -method. - -`MergeOperator.Get()` method can be used to retrieve the cumulative value of the key -associated with the merge operation. - -```Go -key := []byte("merge") -m := db.GetMergeOperator(key, add, 200*time.Millisecond) -defer m.Stop() - -m.Add(uint64ToBytes(1)) -m.Add(uint64ToBytes(2)) -m.Add(uint64ToBytes(3)) - -res, err := m.Get() // res should have value 6 encoded -fmt.Println(bytesToUint64(res)) -``` - -### Setting Time To Live(TTL) and User Metadata on Keys -Badger allows setting an optional Time to Live (TTL) value on keys. Once the TTL has -elapsed, the key will no longer be retrievable and will be eligible for garbage -collection. A TTL can be set as a `time.Duration` value using the `Txn.SetWithTTL()` -API method. - -An optional user metadata value can be set on each key. A user metadata value -is represented by a single byte. It can be used to set certain bits along -with the key to aid in interpreting or decoding the key-value pair. User -metadata can be set using the `Txn.SetWithMeta()` API method. - -`Txn.SetEntry()` can be used to set the key, value, user metatadata and TTL, -all at once. - -### Iterating over keys -To iterate over keys, we can use an `Iterator`, which can be obtained using the -`Txn.NewIterator()` method. Iteration happens in byte-wise lexicographical sorting -order. - - -```go -err := db.View(func(txn *badger.Txn) error { - opts := badger.DefaultIteratorOptions - opts.PrefetchSize = 10 - it := txn.NewIterator(opts) - defer it.Close() - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - k := item.Key() - v, err := item.Value() - if err != nil { - return err - } - fmt.Printf("key=%s, value=%s\n", k, v) - } - return nil -}) -``` - -The iterator allows you to move to a specific point in the list of keys and move -forward or backward through the keys one at a time. - -By default, Badger prefetches the values of the next 100 items. You can adjust -that with the `IteratorOptions.PrefetchSize` field. However, setting it to -a value higher than GOMAXPROCS (which we recommend to be 128 or higher) -shouldn’t give any additional benefits. You can also turn off the fetching of -values altogether. See section below on key-only iteration. - -#### Prefix scans -To iterate over a key prefix, you can combine `Seek()` and `ValidForPrefix()`: - -```go -db.View(func(txn *badger.Txn) error { - it := txn.NewIterator(badger.DefaultIteratorOptions) - defer it.Close() - prefix := []byte("1234") - for it.Seek(prefix); it.ValidForPrefix(prefix); it.Next() { - item := it.Item() - k := item.Key() - v, err := item.Value() - if err != nil { - return err - } - fmt.Printf("key=%s, value=%s\n", k, v) - } - return nil -}) -``` - -#### Key-only iteration -Badger supports a unique mode of iteration called _key-only_ iteration. It is -several order of magnitudes faster than regular iteration, because it involves -access to the LSM-tree only, which is usually resident entirely in RAM. To -enable key-only iteration, you need to set the `IteratorOptions.PrefetchValues` -field to `false`. This can also be used to do sparse reads for selected keys -during an iteration, by calling `item.Value()` only when required. - -```go -err := db.View(func(txn *badger.Txn) error { - opts := badger.DefaultIteratorOptions - opts.PrefetchValues = false - it := txn.NewIterator(opts) - defer it.Close() - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - k := item.Key() - fmt.Printf("key=%s\n", k) - } - return nil -}) -``` - -### Garbage Collection -Badger values need to be garbage collected, because of two reasons: - -* Badger keeps values separately from the LSM tree. This means that the compaction operations -that clean up the LSM tree do not touch the values at all. Values need to be cleaned up -separately. - -* Concurrent read/write transactions could leave behind multiple values for a single key, because they -are stored with different versions. These could accumulate, and take up unneeded space beyond the -time these older versions are needed. - -Badger relies on the client to perform garbage collection at a time of their choosing. It provides -the following methods, which can be invoked at an appropriate time: - -* `DB.PurgeOlderVersions()`: Is no longer needed since v1.5.0. Badger's LSM tree automatically discards older/invalid versions of keys. -* `DB.RunValueLogGC()`: This method is designed to do garbage collection while - Badger is online. Along with randomly picking a file, it uses statistics generated by the - LSM-tree compactions to pick files that are likely to lead to maximum space - reclamation. - - It is recommended that this method be called regularly. - -### Database backup -There are two public API methods `DB.Backup()` and `DB.Load()` which can be -used to do online backups and restores. Badger v0.9 provides a CLI tool -`badger`, which can do offline backup/restore. Make sure you have `$GOPATH/bin` -in your PATH to use this tool. - -The command below will create a version-agnostic backup of the database, to a -file `badger.bak` in the current working directory - -``` -badger backup --dir -``` - -To restore `badger.bak` in the current working directory to a new database: - -``` -badger restore --dir -``` - -See `badger --help` for more details. - -If you have a Badger database that was created using v0.8 (or below), you can -use the `badger_backup` tool provided in v0.8.1, and then restore it using the -command above to upgrade your database to work with the latest version. - -``` -badger_backup --dir --backup-file badger.bak -``` - -### Memory usage -Badger's memory usage can be managed by tweaking several options available in -the `Options` struct that is passed in when opening the database using -`DB.Open`. - -- `Options.ValueLogLoadingMode` can be set to `options.FileIO` (instead of the - default `options.MemoryMap`) to avoid memory-mapping log files. This can be - useful in environments with low RAM. -- Number of memtables (`Options.NumMemtables`) - - If you modify `Options.NumMemtables`, also adjust `Options.NumLevelZeroTables` and - `Options.NumLevelZeroTablesStall` accordingly. -- Number of concurrent compactions (`Options.NumCompactors`) -- Mode in which LSM tree is loaded (`Options.TableLoadingMode`) -- Size of table (`Options.MaxTableSize`) -- Size of value log file (`Options.ValueLogFileSize`) - -If you want to decrease the memory usage of Badger instance, tweak these -options (ideally one at a time) until you achieve the desired -memory usage. - -### Statistics -Badger records metrics using the [expvar] package, which is included in the Go -standard library. All the metrics are documented in [y/metrics.go][metrics] -file. - -`expvar` package adds a handler in to the default HTTP server (which has to be -started explicitly), and serves up the metrics at the `/debug/vars` endpoint. -These metrics can then be collected by a system like [Prometheus], to get -better visibility into what Badger is doing. - -[expvar]: https://golang.org/pkg/expvar/ -[metrics]: https://github.com/dgraph-io/badger/blob/master/y/metrics.go -[Prometheus]: https://prometheus.io/ - -## Resources - -### Blog Posts -1. [Introducing Badger: A fast key-value store written natively in -Go](https://open.dgraph.io/post/badger/) -2. [Make Badger crash resilient with ALICE](https://blog.dgraph.io/post/alice/) -3. [Badger vs LMDB vs BoltDB: Benchmarking key-value databases in Go](https://blog.dgraph.io/post/badger-lmdb-boltdb/) -4. [Concurrent ACID Transactions in Badger](https://blog.dgraph.io/post/badger-txn/) - -## Design -Badger was written with these design goals in mind: - -- Write a key-value database in pure Go. -- Use latest research to build the fastest KV database for data sets spanning terabytes. -- Optimize for SSDs. - -Badger’s design is based on a paper titled _[WiscKey: Separating Keys from -Values in SSD-conscious Storage][wisckey]_. - -[wisckey]: https://www.usenix.org/system/files/conference/fast16/fast16-papers-lu.pdf - -### Comparisons -| Feature | Badger | RocksDB | BoltDB | -| ------- | ------ | ------- | ------ | -| Design | LSM tree with value log | LSM tree only | B+ tree | -| High Read throughput | Yes | No | Yes | -| High Write throughput | Yes | Yes | No | -| Designed for SSDs | Yes (with latest research 1) | Not specifically 2 | No | -| Embeddable | Yes | Yes | Yes | -| Sorted KV access | Yes | Yes | Yes | -| Pure Go (no Cgo) | Yes | No | Yes | -| Transactions | Yes, ACID, concurrent with SSI3 | Yes (but non-ACID) | Yes, ACID | -| Snapshots | Yes | Yes | Yes | -| TTL support | Yes | Yes | No | - -1 The [WISCKEY paper][wisckey] (on which Badger is based) saw big -wins with separating values from keys, significantly reducing the write -amplification compared to a typical LSM tree. - -2 RocksDB is an SSD optimized version of LevelDB, which was designed specifically for rotating disks. -As such RocksDB's design isn't aimed at SSDs. - -3 SSI: Serializable Snapshot Isolation. For more details, see the blog post [Concurrent ACID Transactions in Badger](https://blog.dgraph.io/post/badger-txn/) - -### Benchmarks -We have run comprehensive benchmarks against RocksDB, Bolt and LMDB. The -benchmarking code, and the detailed logs for the benchmarks can be found in the -[badger-bench] repo. More explanation, including graphs can be found the blog posts (linked -above). - -[badger-bench]: https://github.com/dgraph-io/badger-bench - -## Other Projects Using Badger -Below is a list of known projects that use Badger: - -* [0-stor](https://github.com/zero-os/0-stor) - Single device object store. -* [Dgraph](https://github.com/dgraph-io/dgraph) - Distributed graph database. -* [Sandglass](https://github.com/celrenheit/sandglass) - distributed, horizontally scalable, persistent, time sorted message queue. -* [Usenet Express](https://usenetexpress.com/) - Serving over 300TB of data with Badger. -* [go-ipfs](https://github.com/ipfs/go-ipfs) - Go client for the InterPlanetary File System (IPFS), a new hypermedia distribution protocol. -* [gorush](https://github.com/appleboy/gorush) - A push notification server written in Go. - -If you are using Badger in a project please send a pull request to add it to the list. - -## Frequently Asked Questions -- **My writes are getting stuck. Why?** - -This can happen if a long running iteration with `Prefetch` is set to false, but -a `Item::Value` call is made internally in the loop. That causes Badger to -acquire read locks over the value log files to avoid value log GC removing the -file from underneath. As a side effect, this also blocks a new value log GC -file from being created, when the value log file boundary is hit. - -Please see Github issues [#293](https://github.com/dgraph-io/badger/issues/293) -and [#315](https://github.com/dgraph-io/badger/issues/315). - -There are multiple workarounds during iteration: - -1. Use `Item::ValueCopy` instead of `Item::Value` when retrieving value. -1. Set `Prefetch` to true. Badger would then copy over the value and release the - file lock immediately. -1. When `Prefetch` is false, don't call `Item::Value` and do a pure key-only - iteration. This might be useful if you just want to delete a lot of keys. -1. Do the writes in a separate transaction after the reads. - -- **My writes are really slow. Why?** - -Are you creating a new transaction for every single key update? This will lead -to very low throughput. To get best write performance, batch up multiple writes -inside a transaction using single `DB.Update()` call. You could also have -multiple such `DB.Update()` calls being made concurrently from multiple -goroutines. - -- **I don't see any disk write. Why?** - -If you're using Badger with `SyncWrites=false`, then your writes might not be written to value log -and won't get synced to disk immediately. Writes to LSM tree are done inmemory first, before they -get compacted to disk. The compaction would only happen once `MaxTableSize` has been reached. So, if -you're doing a few writes and then checking, you might not see anything on disk. Once you `Close` -the database, you'll see these writes on disk. - -- **Reverse iteration doesn't give me the right results.** - -Just like forward iteration goes to the first key which is equal or greater than the SEEK key, reverse iteration goes to the first key which is equal or lesser than the SEEK key. Therefore, SEEK key would not be part of the results. You can typically add a tilde (~) as a suffix to the SEEK key to include it in the results. See the following issues: [#436](https://github.com/dgraph-io/badger/issues/436) and [#347](https://github.com/dgraph-io/badger/issues/347). - -- **Which instances should I use for Badger?** - -We recommend using instances which provide local SSD storage, without any limit -on the maximum IOPS. In AWS, these are storage optimized instances like i3. They -provide local SSDs which clock 100K IOPS over 4KB blocks easily. - -- **I'm getting a closed channel error. Why?** - -``` -panic: close of closed channel -panic: send on closed channel -``` - -If you're seeing panics like above, this would be because you're operating on a closed DB. This can happen, if you call `Close()` before sending a write, or multiple times. You should ensure that you only call `Close()` once, and all your read/write operations finish before closing. - -- **Are there any Go specific settings that I should use?** - -We *highly* recommend setting a high number for GOMAXPROCS, which allows Go to -observe the full IOPS throughput provided by modern SSDs. In Dgraph, we have set -it to 128. For more details, [see this -thread](https://groups.google.com/d/topic/golang-nuts/jPb_h3TvlKE/discussion). - -- **Are there any linux specific settings that I should use?** - -We recommend setting max file descriptors to a high number depending upon the expected size of you data. - -## Contact -- Please use [discuss.dgraph.io](https://discuss.dgraph.io) for questions, feature requests and discussions. -- Please use [Github issue tracker](https://github.com/dgraph-io/badger/issues) for filing bugs or feature requests. -- Join [![Slack Status](http://slack.dgraph.io/badge.svg)](http://slack.dgraph.io). -- Follow us on Twitter [@dgraphlabs](https://twitter.com/dgraphlabs). - diff --git a/vendor/github.com/dgraph-io/badger/appveyor.yml b/vendor/github.com/dgraph-io/badger/appveyor.yml deleted file mode 100644 index 79dac33..0000000 --- a/vendor/github.com/dgraph-io/badger/appveyor.yml +++ /dev/null @@ -1,48 +0,0 @@ -# version format -version: "{build}" - -# Operating system (build VM template) -os: Windows Server 2012 R2 - -# Platform. -platform: x64 - -clone_folder: c:\gopath\src\github.com\dgraph-io\badger - -# Environment variables -environment: - GOVERSION: 1.8.3 - GOPATH: c:\gopath - -# scripts that run after cloning repository -install: - - set PATH=%GOPATH%\bin;c:\go\bin;%PATH% - - go version - - go env - - python --version - -# To run your custom scripts instead of automatic MSBuild -build_script: - # We need to disable firewall - https://github.com/appveyor/ci/issues/1579#issuecomment-309830648 - - ps: Disable-NetFirewallRule -DisplayName 'File and Printer Sharing (SMB-Out)' - - cd c:\gopath\src\github.com\dgraph-io\badger - - git branch - - go get -t ./... - -# To run your custom scripts instead of automatic tests -test_script: - # Unit tests - - ps: Add-AppveyorTest "Unit Tests" -Outcome Running - - go test -v github.com/dgraph-io/badger/... - - go test -v -vlog_mmap=false github.com/dgraph-io/badger/... - - ps: Update-AppveyorTest "Unit Tests" -Outcome Passed - -notifications: - - provider: Email - to: - - pawan@dgraph.io - on_build_failure: true - on_build_status_changed: true -# to disable deployment -deploy: off - diff --git a/vendor/github.com/dgraph-io/badger/backup.go b/vendor/github.com/dgraph-io/badger/backup.go deleted file mode 100644 index 4cd4de2..0000000 --- a/vendor/github.com/dgraph-io/badger/backup.go +++ /dev/null @@ -1,174 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bufio" - "encoding/binary" - "io" - "log" - "sync" - - "github.com/dgraph-io/badger/y" - - "github.com/dgraph-io/badger/protos" -) - -func writeTo(entry *protos.KVPair, w io.Writer) error { - if err := binary.Write(w, binary.LittleEndian, uint64(entry.Size())); err != nil { - return err - } - buf, err := entry.Marshal() - if err != nil { - return err - } - _, err = w.Write(buf) - return err -} - -// Backup dumps a protobuf-encoded list of all entries in the database into the -// given writer, that are newer than the specified version. It returns a -// timestamp indicating when the entries were dumped which can be passed into a -// later invocation to generate an incremental dump, of entries that have been -// added/modified since the last invocation of DB.Backup() -// -// This can be used to backup the data in a database at a given point in time. -func (db *DB) Backup(w io.Writer, since uint64) (uint64, error) { - var tsNew uint64 - err := db.View(func(txn *Txn) error { - opts := DefaultIteratorOptions - opts.AllVersions = true - it := txn.NewIterator(opts) - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - if item.Version() < since { - // Ignore versions less than given timestamp - continue - } - val, err := item.Value() - if err != nil { - log.Printf("Key [%x]. Error while fetching value [%v]\n", item.Key(), err) - continue - } - - entry := &protos.KVPair{ - Key: y.Copy(item.Key()), - Value: y.Copy(val), - UserMeta: []byte{item.UserMeta()}, - Version: item.Version(), - ExpiresAt: item.ExpiresAt(), - } - - // Write entries to disk - if err := writeTo(entry, w); err != nil { - return err - } - } - tsNew = txn.readTs - return nil - }) - return tsNew, err -} - -// Load reads a protobuf-encoded list of all entries from a reader and writes -// them to the database. This can be used to restore the database from a backup -// made by calling DB.Backup(). -// -// DB.Load() should be called on a database that is not running any other -// concurrent transactions while it is running. -func (db *DB) Load(r io.Reader) error { - br := bufio.NewReaderSize(r, 16<<10) - unmarshalBuf := make([]byte, 1<<10) - var entries []*Entry - var wg sync.WaitGroup - errChan := make(chan error, 1) - - // func to check for pending error before sending off a batch for writing - batchSetAsyncIfNoErr := func(entries []*Entry) error { - select { - case err := <-errChan: - return err - default: - wg.Add(1) - return db.batchSetAsync(entries, func(err error) { - defer wg.Done() - if err != nil { - select { - case errChan <- err: - default: - } - } - }) - } - } - - for { - var sz uint64 - err := binary.Read(br, binary.LittleEndian, &sz) - if err == io.EOF { - break - } else if err != nil { - return err - } - - if cap(unmarshalBuf) < int(sz) { - unmarshalBuf = make([]byte, sz) - } - - e := &protos.KVPair{} - if _, err = io.ReadFull(br, unmarshalBuf[:sz]); err != nil { - return err - } - if err = e.Unmarshal(unmarshalBuf[:sz]); err != nil { - return err - } - entries = append(entries, &Entry{ - Key: y.KeyWithTs(e.Key, e.Version), - Value: e.Value, - UserMeta: e.UserMeta[0], - ExpiresAt: e.ExpiresAt, - }) - // Update nextCommit, memtable stores this timestamp in badger head - // when flushed. - if e.Version >= db.orc.commitTs() { - db.orc.nextCommit = e.Version + 1 - } - - if len(entries) == 1000 { - if err := batchSetAsyncIfNoErr(entries); err != nil { - return err - } - entries = make([]*Entry, 0, 1000) - } - } - - if len(entries) > 0 { - if err := batchSetAsyncIfNoErr(entries); err != nil { - return err - } - } - - wg.Wait() - - select { - case err := <-errChan: - return err - default: - db.orc.curRead = db.orc.commitTs() - 1 - return nil - } -} diff --git a/vendor/github.com/dgraph-io/badger/backup_test.go b/vendor/github.com/dgraph-io/badger/backup_test.go deleted file mode 100644 index 350c3e6..0000000 --- a/vendor/github.com/dgraph-io/badger/backup_test.go +++ /dev/null @@ -1,255 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bytes" - "fmt" - "io/ioutil" - "os" - "path/filepath" - "reflect" - "testing" - - "github.com/stretchr/testify/require" -) - -func TestDumpLoad(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - db, err := Open(getTestOptions(dir)) - require.NoError(t, err) - - // Write some stuff - entries := []struct { - key []byte - val []byte - userMeta byte - version uint64 - }{ - {key: []byte("answer1"), val: []byte("42"), version: 1}, - {key: []byte("answer2"), val: []byte("43"), userMeta: 1, version: 2}, - } - - err = db.Update(func(txn *Txn) error { - e := entries[0] - err := txn.SetWithMeta(e.key, e.val, e.userMeta) - if err != nil { - return err - } - return nil - }) - require.NoError(t, err) - - err = db.Update(func(txn *Txn) error { - e := entries[1] - err := txn.SetWithMeta(e.key, e.val, e.userMeta) - if err != nil { - return err - } - return nil - }) - require.NoError(t, err) - - // Use different directory. - dir, err = ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - bak, err := ioutil.TempFile(dir, "badgerbak") - require.NoError(t, err) - ts, err := db.Backup(bak, 0) - t.Logf("New ts: %d\n", ts) - require.NoError(t, err) - require.NoError(t, bak.Close()) - require.NoError(t, db.Close()) - - db, err = Open(getTestOptions(dir)) - require.NoError(t, err) - defer db.Close() - bak, err = os.Open(bak.Name()) - require.NoError(t, err) - defer bak.Close() - - require.NoError(t, db.Load(bak)) - - err = db.View(func(txn *Txn) error { - opts := DefaultIteratorOptions - opts.AllVersions = true - it := txn.NewIterator(opts) - var count int - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - val, err := item.Value() - if err != nil { - return err - } - require.Equal(t, entries[count].key, item.Key()) - require.Equal(t, entries[count].val, val) - require.Equal(t, entries[count].version, item.Version()) - require.Equal(t, entries[count].userMeta, item.UserMeta()) - count++ - } - require.Equal(t, count, 2) - return nil - }) - require.NoError(t, err) -} - -func Test_BackupRestore(t *testing.T) { - tmpdir, err := ioutil.TempDir("", "badger-test") - if err != nil { - t.Fatal(err) - } - defer func() { - os.RemoveAll(tmpdir) - }() - - s1Path := filepath.Join(tmpdir, "test1") - s2Path := filepath.Join(tmpdir, "test2") - s3Path := filepath.Join(tmpdir, "test3") - - opts := DefaultOptions - opts.Dir = s1Path - opts.ValueDir = s1Path - db1, err := Open(opts) - if err != nil { - t.Fatal(err) - } - key1 := []byte("key1") - key2 := []byte("key2") - rawValue := []byte("NotLongValue") - N := byte(251) - err = db1.Update(func(tx *Txn) error { - if err := tx.Set(key1, rawValue); err != nil { - return err - } - return tx.Set(key2, rawValue) - }) - if err != nil { - t.Fatal(err) - } - for i := byte(0); i < N; i++ { - err = db1.Update(func(tx *Txn) error { - if err := tx.Set(append(key1, i), rawValue); err != nil { - return err - } - return tx.Set(append(key2, i), rawValue) - }) - if err != nil { - t.Fatal(err) - } - } - var backup bytes.Buffer - _, err = db1.Backup(&backup, 0) - if err != nil { - t.Fatal(err) - } - fmt.Println("backup1 length:", backup.Len()) - - opts = DefaultOptions - opts.Dir = s2Path - opts.ValueDir = s2Path - db2, err := Open(opts) - if err != nil { - t.Fatal(err) - } - err = db2.Load(&backup) - if err != nil { - t.Fatal(err) - } - - for i := byte(0); i < N; i++ { - err = db2.View(func(tx *Txn) error { - k := append(key1, i) - item, err := tx.Get(k) - if err != nil { - if err == ErrKeyNotFound { - return fmt.Errorf("Key %q has been not found, but was set\n", k) - } - return err - } - v, err := item.Value() - if err != nil { - return err - } - if !reflect.DeepEqual(v, rawValue) { - return fmt.Errorf("Values not match, got %v, expected %v", v, rawValue) - } - return nil - }) - if err != nil { - t.Fatal(err) - } - } - - for i := byte(0); i < N; i++ { - err = db2.Update(func(tx *Txn) error { - if err := tx.Set(append(key1, i), rawValue); err != nil { - return err - } - return tx.Set(append(key2, i), rawValue) - }) - if err != nil { - t.Fatal(err) - } - } - - backup.Reset() - _, err = db2.Backup(&backup, 0) - if err != nil { - t.Fatal(err) - } - fmt.Println("backup2 length:", backup.Len()) - opts = DefaultOptions - opts.Dir = s3Path - opts.ValueDir = s3Path - db3, err := Open(opts) - if err != nil { - t.Fatal(err) - } - - err = db3.Load(&backup) - if err != nil { - t.Fatal(err) - } - - for i := byte(0); i < N; i++ { - err = db3.View(func(tx *Txn) error { - k := append(key1, i) - item, err := tx.Get(k) - if err != nil { - if err == ErrKeyNotFound { - return fmt.Errorf("Key %q has been not found, but was set\n", k) - } - return err - } - v, err := item.Value() - if err != nil { - return err - } - if !reflect.DeepEqual(v, rawValue) { - return fmt.Errorf("Values not match, got %v, expected %v", v, rawValue) - } - return nil - }) - if err != nil { - t.Fatal(err) - } - } - -} diff --git a/vendor/github.com/dgraph-io/badger/badger/.gitignore b/vendor/github.com/dgraph-io/badger/badger/.gitignore deleted file mode 100644 index a8e6bd9..0000000 --- a/vendor/github.com/dgraph-io/badger/badger/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/badger diff --git a/vendor/github.com/dgraph-io/badger/badger/cmd/backup.go b/vendor/github.com/dgraph-io/badger/badger/cmd/backup.go deleted file mode 100644 index 98b7392..0000000 --- a/vendor/github.com/dgraph-io/badger/badger/cmd/backup.go +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package cmd - -import ( - "os" - - "github.com/dgraph-io/badger" - "github.com/spf13/cobra" -) - -var backupFile string -var truncate bool - -// backupCmd represents the backup command -var backupCmd = &cobra.Command{ - Use: "backup", - Short: "Backup Badger database.", - Long: `Backup Badger database to a file in a version-agnostic manner. - -Iterates over each key-value pair, encodes it along with its metadata and -version in protocol buffers and writes them to a file. This file can later be -used by the restore command to create an identical copy of the -database.`, - RunE: doBackup, -} - -func init() { - RootCmd.AddCommand(backupCmd) - backupCmd.Flags().StringVarP(&backupFile, "backup-file", "f", - "badger.bak", "File to backup to") - backupCmd.Flags().BoolVarP(&truncate, "truncate", "t", - false, "Allow value log truncation if required.") -} - -func doBackup(cmd *cobra.Command, args []string) error { - // Open DB - opts := badger.DefaultOptions - opts.Dir = sstDir - opts.ValueDir = vlogDir - opts.Truncate = truncate - db, err := badger.Open(opts) - if err != nil { - return err - } - defer db.Close() - - // Create File - f, err := os.Create(backupFile) - if err != nil { - return err - } - defer f.Close() - - // Run Backup - _, err = db.Backup(f, 0) - return err -} diff --git a/vendor/github.com/dgraph-io/badger/badger/cmd/info.go b/vendor/github.com/dgraph-io/badger/badger/cmd/info.go deleted file mode 100644 index 0d23d3a..0000000 --- a/vendor/github.com/dgraph-io/badger/badger/cmd/info.go +++ /dev/null @@ -1,284 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package cmd - -import ( - "fmt" - "io/ioutil" - "os" - "path/filepath" - "sort" - "strings" - "time" - - "github.com/dgraph-io/badger" - "github.com/dgraph-io/badger/table" - "github.com/dgraph-io/badger/y" - humanize "github.com/dustin/go-humanize" - "github.com/spf13/cobra" -) - -var infoCmd = &cobra.Command{ - Use: "info", - Short: "Health info about Badger database.", - Long: ` -This command prints information about the badger key-value store. It reads MANIFEST and prints its -info. It also prints info about missing/extra files, and general information about the value log -files (which are not referenced by the manifest). Use this tool to report any issues about Badger -to the Dgraph team. -`, - Run: func(cmd *cobra.Command, args []string) { - err := printInfo(sstDir, vlogDir) - if err != nil { - fmt.Println("Error:", err.Error()) - os.Exit(1) - } - err = tableInfo(sstDir, vlogDir) - if err != nil { - fmt.Println("Error:", err.Error()) - os.Exit(1) - } - }, -} - -func init() { - RootCmd.AddCommand(infoCmd) -} - -func bytes(sz int64) string { - return humanize.Bytes(uint64(sz)) -} - -func dur(src, dst time.Time) string { - return humanize.RelTime(dst, src, "earlier", "later") -} - -func tableInfo(dir, valueDir string) error { - // Open DB - opts := badger.DefaultOptions - opts.Dir = sstDir - opts.ValueDir = vlogDir - opts.ReadOnly = true - - db, err := badger.Open(opts) - if err != nil { - return err - } - defer db.Close() - - tables := db.Tables() - for _, t := range tables { - lk, lv := y.ParseKey(t.Left), y.ParseTs(t.Left) - rk, rv := y.ParseKey(t.Right), y.ParseTs(t.Right) - fmt.Printf("SSTable [L%d, %03d] [%20X, v%-10d -> %20X, v%-10d]\n", - t.Level, t.ID, lk, lv, rk, rv) - } - return nil -} - -func printInfo(dir, valueDir string) error { - if dir == "" { - return fmt.Errorf("--dir not supplied") - } - if valueDir == "" { - valueDir = dir - } - fp, err := os.Open(filepath.Join(dir, badger.ManifestFilename)) - if err != nil { - return err - } - defer func() { - if fp != nil { - fp.Close() - } - }() - manifest, truncOffset, err := badger.ReplayManifestFile(fp) - if err != nil { - return err - } - fp.Close() - fp = nil - - fileinfos, err := ioutil.ReadDir(dir) - if err != nil { - return err - } - fileinfoByName := make(map[string]os.FileInfo) - fileinfoMarked := make(map[string]bool) - for _, info := range fileinfos { - fileinfoByName[info.Name()] = info - fileinfoMarked[info.Name()] = false - } - - fmt.Println() - var baseTime time.Time - // fmt.Print("\n[Manifest]\n") - manifestTruncated := false - manifestInfo, ok := fileinfoByName[badger.ManifestFilename] - if ok { - fileinfoMarked[badger.ManifestFilename] = true - truncatedString := "" - if truncOffset != manifestInfo.Size() { - truncatedString = fmt.Sprintf(" [TRUNCATED to %d]", truncOffset) - manifestTruncated = true - } - - baseTime = manifestInfo.ModTime() - fmt.Printf("[%25s] %-12s %6s MA%s\n", manifestInfo.ModTime().Format(time.RFC3339), - manifestInfo.Name(), bytes(manifestInfo.Size()), truncatedString) - } else { - fmt.Printf("%s [MISSING]\n", manifestInfo.Name()) - } - - numMissing := 0 - numEmpty := 0 - - levelSizes := make([]int64, len(manifest.Levels)) - for level, lm := range manifest.Levels { - // fmt.Printf("\n[Level %d]\n", level) - // We create a sorted list of table ID's so that output is in consistent order. - tableIDs := make([]uint64, 0, len(lm.Tables)) - for id := range lm.Tables { - tableIDs = append(tableIDs, id) - } - sort.Slice(tableIDs, func(i, j int) bool { - return tableIDs[i] < tableIDs[j] - }) - for _, tableID := range tableIDs { - tableFile := table.IDToFilename(tableID) - file, ok := fileinfoByName[tableFile] - if ok { - fileinfoMarked[tableFile] = true - emptyString := "" - fileSize := file.Size() - if fileSize == 0 { - emptyString = " [EMPTY]" - numEmpty++ - } - levelSizes[level] += fileSize - // (Put level on every line to make easier to process with sed/perl.) - fmt.Printf("[%25s] %-12s %6s L%d%s\n", dur(baseTime, file.ModTime()), - tableFile, bytes(fileSize), level, emptyString) - } else { - fmt.Printf("%s [MISSING]\n", tableFile) - numMissing++ - } - } - } - - valueDirFileinfos := fileinfos - if valueDir != dir { - valueDirFileinfos, err = ioutil.ReadDir(valueDir) - if err != nil { - return err - } - } - - // If valueDir is different from dir, holds extra files in the value dir. - valueDirExtras := []os.FileInfo{} - - valueLogSize := int64(0) - // fmt.Print("\n[Value Log]\n") - for _, file := range valueDirFileinfos { - if !strings.HasSuffix(file.Name(), ".vlog") { - if valueDir != dir { - valueDirExtras = append(valueDirExtras, file) - } - continue - } - - fileSize := file.Size() - emptyString := "" - if fileSize == 0 { - emptyString = " [EMPTY]" - numEmpty++ - } - valueLogSize += fileSize - fmt.Printf("[%25s] %-12s %6s VL%s\n", dur(baseTime, file.ModTime()), file.Name(), - bytes(fileSize), emptyString) - - fileinfoMarked[file.Name()] = true - } - - numExtra := 0 - for _, file := range fileinfos { - if fileinfoMarked[file.Name()] { - continue - } - if numExtra == 0 { - fmt.Print("\n[EXTRA]\n") - } - fmt.Printf("[%s] %-12s %6s\n", file.ModTime().Format(time.RFC3339), - file.Name(), bytes(file.Size())) - numExtra++ - } - - numValueDirExtra := 0 - for _, file := range valueDirExtras { - if numValueDirExtra == 0 { - fmt.Print("\n[ValueDir EXTRA]\n") - } - fmt.Printf("[%s] %-12s %6s\n", file.ModTime().Format(time.RFC3339), - file.Name(), bytes(file.Size())) - numValueDirExtra++ - } - - fmt.Print("\n[Summary]\n") - totalIndexSize := int64(0) - for i, sz := range levelSizes { - fmt.Printf("Level %d size: %12s\n", i, bytes(sz)) - totalIndexSize += sz - } - - fmt.Printf("Total index size: %8s\n", bytes(totalIndexSize)) - fmt.Printf("Value log size: %10s\n", bytes(valueLogSize)) - fmt.Println() - totalExtra := numExtra + numValueDirExtra - if totalExtra == 0 && numMissing == 0 && numEmpty == 0 && !manifestTruncated { - fmt.Println("Abnormalities: None.") - } else { - fmt.Println("Abnormalities:") - } - fmt.Printf("%d extra %s.\n", totalExtra, pluralFiles(totalExtra)) - fmt.Printf("%d missing %s.\n", numMissing, pluralFiles(numMissing)) - fmt.Printf("%d empty %s.\n", numEmpty, pluralFiles(numEmpty)) - fmt.Printf("%d truncated %s.\n", boolToNum(manifestTruncated), - pluralManifest(manifestTruncated)) - - return nil -} - -func boolToNum(x bool) int { - if x { - return 1 - } - return 0 -} - -func pluralManifest(manifestTruncated bool) string { - if manifestTruncated { - return "manifest" - } - return "manifests" -} - -func pluralFiles(count int) string { - if count == 1 { - return "file" - } - return "files" -} diff --git a/vendor/github.com/dgraph-io/badger/badger/cmd/restore.go b/vendor/github.com/dgraph-io/badger/badger/cmd/restore.go deleted file mode 100644 index 80f7382..0000000 --- a/vendor/github.com/dgraph-io/badger/badger/cmd/restore.go +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package cmd - -import ( - "errors" - "os" - "path" - - "github.com/dgraph-io/badger" - "github.com/spf13/cobra" -) - -var restoreFile string - -// restoreCmd represents the restore command -var restoreCmd = &cobra.Command{ - Use: "restore", - Short: "Restore Badger database.", - Long: `Restore Badger database from a file. - -It reads a file generated using the backup command (or by calling the -DB.Backup() API method) and writes each key-value pair found in the file to -the Badger database. - -Restore creates a new database, and currently does not work on an already -existing database.`, - RunE: doRestore, -} - -func init() { - RootCmd.AddCommand(restoreCmd) - restoreCmd.Flags().StringVarP(&restoreFile, "backup-file", "f", - "badger.bak", "File to restore from") -} - -func doRestore(cmd *cobra.Command, args []string) error { - // Check if the DB already exists - manifestFile := path.Join(sstDir, badger.ManifestFilename) - if _, err := os.Stat(manifestFile); err == nil { // No error. File already exists. - return errors.New("Cannot restore to an already existing database") - } else if os.IsNotExist(err) { - // pass - } else { // Return an error if anything other than the error above - return err - } - - // Open DB - opts := badger.DefaultOptions - opts.Dir = sstDir - opts.ValueDir = vlogDir - db, err := badger.Open(opts) - if err != nil { - return err - } - defer db.Close() - - // Open File - f, err := os.Open(restoreFile) - if err != nil { - return err - } - defer f.Close() - - // Run restore - return db.Load(f) -} diff --git a/vendor/github.com/dgraph-io/badger/badger/cmd/root.go b/vendor/github.com/dgraph-io/badger/badger/cmd/root.go deleted file mode 100644 index f536243..0000000 --- a/vendor/github.com/dgraph-io/badger/badger/cmd/root.go +++ /dev/null @@ -1,65 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package cmd - -import ( - "errors" - "fmt" - "os" - "strings" - - "github.com/spf13/cobra" -) - -var sstDir, vlogDir string - -// RootCmd represents the base command when called without any subcommands -var RootCmd = &cobra.Command{ - Use: "badger", - Short: "Tools to manage Badger database.", - PersistentPreRunE: validateRootCmdArgs, -} - -// Execute adds all child commands to the root command and sets flags appropriately. -// This is called by main.main(). It only needs to happen once to the rootCmd. -func Execute() { - if err := RootCmd.Execute(); err != nil { - fmt.Println(err) - os.Exit(1) - } -} - -func init() { - RootCmd.PersistentFlags().StringVar(&sstDir, "dir", "", - "Directory where the LSM tree files are located. (required)") - - RootCmd.PersistentFlags().StringVar(&vlogDir, "vlog-dir", "", - "Directory where the value log files are located, if different from --dir") -} - -func validateRootCmdArgs(cmd *cobra.Command, args []string) error { - if strings.HasPrefix(cmd.Use, "help ") { // No need to validate if it is help - return nil - } - if sstDir == "" { - return errors.New("--sst-dir not specified") - } - if vlogDir == "" { - vlogDir = sstDir - } - return nil -} diff --git a/vendor/github.com/dgraph-io/badger/badger/main.go b/vendor/github.com/dgraph-io/badger/badger/main.go deleted file mode 100644 index 4ad9eaf..0000000 --- a/vendor/github.com/dgraph-io/badger/badger/main.go +++ /dev/null @@ -1,38 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package main - -import ( - "fmt" - "net/http" - - "github.com/dgraph-io/badger/badger/cmd" -) - -func main() { - go func() { - for i := 8080; i < 9080; i++ { - fmt.Printf("Listening for /debug HTTP requests at port: %d\n", i) - if err := http.ListenAndServe(fmt.Sprintf("localhost:%d", i), nil); err != nil { - fmt.Println("Port busy. Trying another one...") - continue - - } - } - }() - cmd.Execute() -} diff --git a/vendor/github.com/dgraph-io/badger/compaction.go b/vendor/github.com/dgraph-io/badger/compaction.go deleted file mode 100644 index 00be8f6..0000000 --- a/vendor/github.com/dgraph-io/badger/compaction.go +++ /dev/null @@ -1,212 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bytes" - "fmt" - "log" - "math" - "sync" - - "golang.org/x/net/trace" - - "github.com/dgraph-io/badger/table" - "github.com/dgraph-io/badger/y" -) - -type keyRange struct { - left []byte - right []byte - inf bool -} - -var infRange = keyRange{inf: true} - -func (r keyRange) String() string { - return fmt.Sprintf("[left=%x, right=%x, inf=%v]", r.left, r.right, r.inf) -} - -func (r keyRange) equals(dst keyRange) bool { - return bytes.Equal(r.left, dst.left) && - bytes.Equal(r.right, dst.right) && - r.inf == dst.inf -} - -func (r keyRange) overlapsWith(dst keyRange) bool { - if r.inf || dst.inf { - return true - } - - // If my left is greater than dst right, we have no overlap. - if y.CompareKeys(r.left, dst.right) > 0 { - return false - } - // If my right is less than dst left, we have no overlap. - if y.CompareKeys(r.right, dst.left) < 0 { - return false - } - // We have overlap. - return true -} - -func getKeyRange(tables []*table.Table) keyRange { - y.AssertTrue(len(tables) > 0) - smallest := tables[0].Smallest() - biggest := tables[0].Biggest() - for i := 1; i < len(tables); i++ { - if y.CompareKeys(tables[i].Smallest(), smallest) < 0 { - smallest = tables[i].Smallest() - } - if y.CompareKeys(tables[i].Biggest(), biggest) > 0 { - biggest = tables[i].Biggest() - } - } - return keyRange{ - left: y.KeyWithTs(y.ParseKey(smallest), math.MaxUint64), - right: y.KeyWithTs(y.ParseKey(biggest), 0), - } -} - -type levelCompactStatus struct { - ranges []keyRange - delSize int64 -} - -func (lcs *levelCompactStatus) debug() string { - var b bytes.Buffer - for _, r := range lcs.ranges { - b.WriteString(r.String()) - } - return b.String() -} - -func (lcs *levelCompactStatus) overlapsWith(dst keyRange) bool { - for _, r := range lcs.ranges { - if r.overlapsWith(dst) { - return true - } - } - return false -} - -func (lcs *levelCompactStatus) remove(dst keyRange) bool { - final := lcs.ranges[:0] - var found bool - for _, r := range lcs.ranges { - if !r.equals(dst) { - final = append(final, r) - } else { - found = true - } - } - lcs.ranges = final - return found -} - -type compactStatus struct { - sync.RWMutex - levels []*levelCompactStatus -} - -func (cs *compactStatus) toLog(tr trace.Trace) { - cs.RLock() - defer cs.RUnlock() - - tr.LazyPrintf("Compaction status:") - for i, l := range cs.levels { - if len(l.debug()) == 0 { - continue - } - tr.LazyPrintf("[%d] %s", i, l.debug()) - } -} - -func (cs *compactStatus) overlapsWith(level int, this keyRange) bool { - cs.RLock() - defer cs.RUnlock() - - thisLevel := cs.levels[level] - return thisLevel.overlapsWith(this) -} - -func (cs *compactStatus) delSize(l int) int64 { - cs.RLock() - defer cs.RUnlock() - return cs.levels[l].delSize -} - -type thisAndNextLevelRLocked struct{} - -// compareAndAdd will check whether we can run this compactDef. That it doesn't overlap with any -// other running compaction. If it can be run, it would store this run in the compactStatus state. -func (cs *compactStatus) compareAndAdd(_ thisAndNextLevelRLocked, cd compactDef) bool { - cs.Lock() - defer cs.Unlock() - - level := cd.thisLevel.level - - y.AssertTruef(level < len(cs.levels)-1, "Got level %d. Max levels: %d", level, len(cs.levels)) - thisLevel := cs.levels[level] - nextLevel := cs.levels[level+1] - - if thisLevel.overlapsWith(cd.thisRange) { - return false - } - if nextLevel.overlapsWith(cd.nextRange) { - return false - } - // Check whether this level really needs compaction or not. Otherwise, we'll end up - // running parallel compactions for the same level. - // NOTE: We can directly call thisLevel.totalSize, because we already have acquire a read lock - // over this and the next level. - if cd.thisLevel.totalSize-thisLevel.delSize < cd.thisLevel.maxTotalSize { - return false - } - - thisLevel.ranges = append(thisLevel.ranges, cd.thisRange) - nextLevel.ranges = append(nextLevel.ranges, cd.nextRange) - thisLevel.delSize += cd.thisSize - - return true -} - -func (cs *compactStatus) delete(cd compactDef) { - cs.Lock() - defer cs.Unlock() - - level := cd.thisLevel.level - y.AssertTruef(level < len(cs.levels)-1, "Got level %d. Max levels: %d", level, len(cs.levels)) - - thisLevel := cs.levels[level] - nextLevel := cs.levels[level+1] - - thisLevel.delSize -= cd.thisSize - found := thisLevel.remove(cd.thisRange) - found = nextLevel.remove(cd.nextRange) && found - - if !found { - this := cd.thisRange - next := cd.nextRange - fmt.Printf("Looking for: [%q, %q, %v] in this level.\n", this.left, this.right, this.inf) - fmt.Printf("This Level:\n%s\n", thisLevel.debug()) - fmt.Println() - fmt.Printf("Looking for: [%q, %q, %v] in next level.\n", next.left, next.right, next.inf) - fmt.Printf("Next Level:\n%s\n", nextLevel.debug()) - log.Fatal("keyRange not found") - } -} diff --git a/vendor/github.com/dgraph-io/badger/contrib/cover.sh b/vendor/github.com/dgraph-io/badger/contrib/cover.sh deleted file mode 100755 index 5e2c179..0000000 --- a/vendor/github.com/dgraph-io/badger/contrib/cover.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/bash - -SRC="$( cd -P "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/.." -TMP=$(mktemp /tmp/badger-coverage-XXXXX.txt) - -BUILD=$1 -OUT=$2 - -set -e - -pushd $SRC &> /dev/null - -# create coverage output -echo 'mode: atomic' > $OUT -for PKG in $(go list ./...|grep -v -E 'vendor'); do - go test -covermode=atomic -coverprofile=$TMP $PKG - tail -n +2 $TMP >> $OUT -done - -# Another round of tests after turning off mmap -go test -v -vlog_mmap=false github.com/dgraph-io/badger - -popd &> /dev/null diff --git a/vendor/github.com/dgraph-io/badger/db.go b/vendor/github.com/dgraph-io/badger/db.go deleted file mode 100644 index 1685bc8..0000000 --- a/vendor/github.com/dgraph-io/badger/db.go +++ /dev/null @@ -1,1230 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "encoding/binary" - "expvar" - "log" - "math" - "os" - "path/filepath" - "strconv" - "sync" - "time" - - "github.com/dgraph-io/badger/options" - - "golang.org/x/net/trace" - - "github.com/dgraph-io/badger/skl" - "github.com/dgraph-io/badger/table" - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" -) - -var ( - badgerPrefix = []byte("!badger!") // Prefix for internal keys used by badger. - head = []byte("!badger!head") // For storing value offset for replay. - txnKey = []byte("!badger!txn") // For indicating end of entries in txn. - badgerMove = []byte("!badger!move") // For key-value pairs which got moved during GC. -) - -type closers struct { - updateSize *y.Closer - compactors *y.Closer - memtable *y.Closer - writes *y.Closer - valueGC *y.Closer -} - -// DB provides the various functions required to interact with Badger. -// DB is thread-safe. -type DB struct { - sync.RWMutex // Guards list of inmemory tables, not individual reads and writes. - - dirLockGuard *directoryLockGuard - // nil if Dir and ValueDir are the same - valueDirGuard *directoryLockGuard - - closers closers - elog trace.EventLog - mt *skl.Skiplist // Our latest (actively written) in-memory table - imm []*skl.Skiplist // Add here only AFTER pushing to flushChan. - opt Options - manifest *manifestFile - lc *levelsController - vlog valueLog - vptr valuePointer // less than or equal to a pointer to the last vlog value put into mt - writeCh chan *request - flushChan chan flushTask // For flushing memtables. - - orc *oracle -} - -const ( - kvWriteChCapacity = 1000 -) - -func replayFunction(out *DB) func(Entry, valuePointer) error { - type txnEntry struct { - nk []byte - v y.ValueStruct - } - - var txn []txnEntry - var lastCommit uint64 - - toLSM := func(nk []byte, vs y.ValueStruct) { - for err := out.ensureRoomForWrite(); err != nil; err = out.ensureRoomForWrite() { - out.elog.Printf("Replay: Making room for writes") - time.Sleep(10 * time.Millisecond) - } - out.mt.Put(nk, vs) - } - - first := true - return func(e Entry, vp valuePointer) error { // Function for replaying. - if first { - out.elog.Printf("First key=%s\n", e.Key) - } - first = false - - if out.orc.curRead < y.ParseTs(e.Key) { - out.orc.curRead = y.ParseTs(e.Key) - } - - nk := make([]byte, len(e.Key)) - copy(nk, e.Key) - var nv []byte - meta := e.meta - if out.shouldWriteValueToLSM(e) { - nv = make([]byte, len(e.Value)) - copy(nv, e.Value) - } else { - nv = make([]byte, vptrSize) - vp.Encode(nv) - meta = meta | bitValuePointer - } - - v := y.ValueStruct{ - Value: nv, - Meta: meta, - UserMeta: e.UserMeta, - } - - if e.meta&bitFinTxn > 0 { - txnTs, err := strconv.ParseUint(string(e.Value), 10, 64) - if err != nil { - return errors.Wrapf(err, "Unable to parse txn fin: %q", e.Value) - } - y.AssertTrue(lastCommit == txnTs) - y.AssertTrue(len(txn) > 0) - // Got the end of txn. Now we can store them. - for _, t := range txn { - toLSM(t.nk, t.v) - } - txn = txn[:0] - lastCommit = 0 - - } else if e.meta&bitTxn == 0 { - // This entry is from a rewrite. - toLSM(nk, v) - - // We shouldn't get this entry in the middle of a transaction. - y.AssertTrue(lastCommit == 0) - y.AssertTrue(len(txn) == 0) - - } else { - txnTs := y.ParseTs(nk) - if lastCommit == 0 { - lastCommit = txnTs - } - y.AssertTrue(lastCommit == txnTs) - te := txnEntry{nk: nk, v: v} - txn = append(txn, te) - } - return nil - } -} - -// Open returns a new DB object. -func Open(opt Options) (db *DB, err error) { - opt.maxBatchSize = (15 * opt.MaxTableSize) / 100 - opt.maxBatchCount = opt.maxBatchSize / int64(skl.MaxNodeSize) - - if opt.ValueThreshold > math.MaxUint16-16 { - return nil, ErrValueThreshold - } - - if opt.ReadOnly { - // Can't truncate if the DB is read only. - opt.Truncate = false - } - - for _, path := range []string{opt.Dir, opt.ValueDir} { - dirExists, err := exists(path) - if err != nil { - return nil, y.Wrapf(err, "Invalid Dir: %q", path) - } - if !dirExists { - if opt.ReadOnly { - return nil, y.Wrapf(err, "Cannot find Dir for read-only open: %q", path) - } - // Try to create the directory - err = os.Mkdir(path, 0700) - if err != nil { - return nil, y.Wrapf(err, "Error Creating Dir: %q", path) - } - } - } - absDir, err := filepath.Abs(opt.Dir) - if err != nil { - return nil, err - } - absValueDir, err := filepath.Abs(opt.ValueDir) - if err != nil { - return nil, err - } - var dirLockGuard, valueDirLockGuard *directoryLockGuard - dirLockGuard, err = acquireDirectoryLock(opt.Dir, lockFile, opt.ReadOnly) - if err != nil { - return nil, err - } - defer func() { - if dirLockGuard != nil { - _ = dirLockGuard.release() - } - }() - if absValueDir != absDir { - valueDirLockGuard, err = acquireDirectoryLock(opt.ValueDir, lockFile, opt.ReadOnly) - if err != nil { - return nil, err - } - } - defer func() { - if valueDirLockGuard != nil { - _ = valueDirLockGuard.release() - } - }() - if !(opt.ValueLogFileSize <= 2<<30 && opt.ValueLogFileSize >= 1<<20) { - return nil, ErrValueLogSize - } - if !(opt.ValueLogLoadingMode == options.FileIO || - opt.ValueLogLoadingMode == options.MemoryMap) { - return nil, ErrInvalidLoadingMode - } - manifestFile, manifest, err := openOrCreateManifestFile(opt.Dir, opt.ReadOnly) - if err != nil { - return nil, err - } - defer func() { - if manifestFile != nil { - _ = manifestFile.close() - } - }() - - orc := &oracle{ - isManaged: opt.managedTxns, - nextCommit: 1, - commits: make(map[uint64]uint64), - readMark: y.WaterMark{}, - } - orc.readMark.Init() - - db = &DB{ - imm: make([]*skl.Skiplist, 0, opt.NumMemtables), - flushChan: make(chan flushTask, opt.NumMemtables), - writeCh: make(chan *request, kvWriteChCapacity), - opt: opt, - manifest: manifestFile, - elog: trace.NewEventLog("Badger", "DB"), - dirLockGuard: dirLockGuard, - valueDirGuard: valueDirLockGuard, - orc: orc, - } - - // Calculate initial size. - db.calculateSize() - db.closers.updateSize = y.NewCloser(1) - go db.updateSize(db.closers.updateSize) - db.mt = skl.NewSkiplist(arenaSize(opt)) - - // newLevelsController potentially loads files in directory. - if db.lc, err = newLevelsController(db, &manifest); err != nil { - return nil, err - } - - if !opt.ReadOnly { - db.closers.compactors = y.NewCloser(1) - db.lc.startCompact(db.closers.compactors) - - db.closers.memtable = y.NewCloser(1) - go db.flushMemtable(db.closers.memtable) // Need levels controller to be up. - } - - if err = db.vlog.Open(db, opt); err != nil { - return nil, err - } - - headKey := y.KeyWithTs(head, math.MaxUint64) - // Need to pass with timestamp, lsm get removes the last 8 bytes and compares key - vs, err := db.get(headKey) - if err != nil { - return nil, errors.Wrap(err, "Retrieving head") - } - db.orc.curRead = vs.Version - var vptr valuePointer - if len(vs.Value) > 0 { - vptr.Decode(vs.Value) - } - - // lastUsedCasCounter will either be the value stored in !badger!head, or some subsequently - // written value log entry that we replay. (Subsequent value log entries might be _less_ - // than lastUsedCasCounter, if there was value log gc so we have to max() values while - // replaying.) - // out.lastUsedCasCounter = item.casCounter - // TODO: Figure this out. This would update the read timestamp, and set nextCommitTs. - - replayCloser := y.NewCloser(1) - go db.doWrites(replayCloser) - - if err = db.vlog.Replay(vptr, replayFunction(db)); err != nil { - return db, err - } - - replayCloser.SignalAndWait() // Wait for replay to be applied first. - // Now that we have the curRead, we can update the nextCommit. - db.orc.nextCommit = db.orc.curRead + 1 - - // Mmap writable log - lf := db.vlog.filesMap[db.vlog.maxFid] - if err = lf.mmap(2 * db.vlog.opt.ValueLogFileSize); err != nil { - return db, errors.Wrapf(err, "Unable to mmap RDWR log file") - } - - db.writeCh = make(chan *request, kvWriteChCapacity) - db.closers.writes = y.NewCloser(1) - go db.doWrites(db.closers.writes) - - db.closers.valueGC = y.NewCloser(1) - go db.vlog.waitOnGC(db.closers.valueGC) - - valueDirLockGuard = nil - dirLockGuard = nil - manifestFile = nil - return db, nil -} - -// Close closes a DB. It's crucial to call it to ensure all the pending updates -// make their way to disk. Calling DB.Close() multiple times is not safe and would -// cause panic. -func (db *DB) Close() (err error) { - db.elog.Printf("Closing database") - // Stop value GC first. - db.closers.valueGC.SignalAndWait() - - // Stop writes next. - db.closers.writes.SignalAndWait() - - // Now close the value log. - if vlogErr := db.vlog.Close(); err == nil { - err = errors.Wrap(vlogErr, "DB.Close") - } - - // Make sure that block writer is done pushing stuff into memtable! - // Otherwise, you will have a race condition: we are trying to flush memtables - // and remove them completely, while the block / memtable writer is still - // trying to push stuff into the memtable. This will also resolve the value - // offset problem: as we push into memtable, we update value offsets there. - if !db.mt.Empty() { - db.elog.Printf("Flushing memtable") - for { - pushedFlushTask := func() bool { - db.Lock() - defer db.Unlock() - y.AssertTrue(db.mt != nil) - select { - case db.flushChan <- flushTask{db.mt, db.vptr}: - db.imm = append(db.imm, db.mt) // Flusher will attempt to remove this from s.imm. - db.mt = nil // Will segfault if we try writing! - db.elog.Printf("pushed to flush chan\n") - return true - default: - // If we fail to push, we need to unlock and wait for a short while. - // The flushing operation needs to update s.imm. Otherwise, we have a deadlock. - // TODO: Think about how to do this more cleanly, maybe without any locks. - } - return false - }() - if pushedFlushTask { - break - } - time.Sleep(10 * time.Millisecond) - } - } - db.flushChan <- flushTask{nil, valuePointer{}} // Tell flusher to quit. - - if db.closers.memtable != nil { - db.closers.memtable.Wait() - db.elog.Printf("Memtable flushed") - } - if db.closers.compactors != nil { - db.closers.compactors.SignalAndWait() - db.elog.Printf("Compaction finished") - } - - // Force Compact L0 - // We don't need to care about cstatus since no parallel compaction is running. - cd := compactDef{ - elog: trace.New("Badger", "Compact"), - thisLevel: db.lc.levels[0], - nextLevel: db.lc.levels[1], - } - cd.elog.SetMaxEvents(100) - defer cd.elog.Finish() - if db.lc.fillTablesL0(&cd) { - if err := db.lc.runCompactDef(0, cd); err != nil { - cd.elog.LazyPrintf("\tLOG Compact FAILED with error: %+v: %+v", err, cd) - } - } else { - cd.elog.LazyPrintf("fillTables failed for level zero. No compaction required") - } - - if lcErr := db.lc.close(); err == nil { - err = errors.Wrap(lcErr, "DB.Close") - } - db.elog.Printf("Waiting for closer") - db.closers.updateSize.SignalAndWait() - - db.elog.Finish() - - if db.dirLockGuard != nil { - if guardErr := db.dirLockGuard.release(); err == nil { - err = errors.Wrap(guardErr, "DB.Close") - } - } - if db.valueDirGuard != nil { - if guardErr := db.valueDirGuard.release(); err == nil { - err = errors.Wrap(guardErr, "DB.Close") - } - } - if manifestErr := db.manifest.close(); err == nil { - err = errors.Wrap(manifestErr, "DB.Close") - } - - // Fsync directories to ensure that lock file, and any other removed files whose directory - // we haven't specifically fsynced, are guaranteed to have their directory entry removal - // persisted to disk. - if syncErr := syncDir(db.opt.Dir); err == nil { - err = errors.Wrap(syncErr, "DB.Close") - } - if syncErr := syncDir(db.opt.ValueDir); err == nil { - err = errors.Wrap(syncErr, "DB.Close") - } - - return err -} - -const ( - lockFile = "LOCK" -) - -// When you create or delete a file, you have to ensure the directory entry for the file is synced -// in order to guarantee the file is visible (if the system crashes). (See the man page for fsync, -// or see https://github.com/coreos/etcd/issues/6368 for an example.) -func syncDir(dir string) error { - f, err := openDir(dir) - if err != nil { - return errors.Wrapf(err, "While opening directory: %s.", dir) - } - err = f.Sync() - closeErr := f.Close() - if err != nil { - return errors.Wrapf(err, "While syncing directory: %s.", dir) - } - return errors.Wrapf(closeErr, "While closing directory: %s.", dir) -} - -// getMemtables returns the current memtables and get references. -func (db *DB) getMemTables() ([]*skl.Skiplist, func()) { - db.RLock() - defer db.RUnlock() - - tables := make([]*skl.Skiplist, len(db.imm)+1) - - // Get mutable memtable. - tables[0] = db.mt - tables[0].IncrRef() - - // Get immutable memtables. - last := len(db.imm) - 1 - for i := range db.imm { - tables[i+1] = db.imm[last-i] - tables[i+1].IncrRef() - } - return tables, func() { - for _, tbl := range tables { - tbl.DecrRef() - } - } -} - -// get returns the value in memtable or disk for given key. -// Note that value will include meta byte. -// -// IMPORTANT: We should never write an entry with an older timestamp for the same key, We need to -// maintain this invariant to search for the latest value of a key, or else we need to search in all -// tables and find the max version among them. To maintain this invariant, we also need to ensure -// that all versions of a key are always present in the same table from level 1, because compaction -// can push any table down. -func (db *DB) get(key []byte) (y.ValueStruct, error) { - tables, decr := db.getMemTables() // Lock should be released. - defer decr() - - y.NumGets.Add(1) - for i := 0; i < len(tables); i++ { - vs := tables[i].Get(key) - y.NumMemtableGets.Add(1) - if vs.Meta != 0 || vs.Value != nil { - return vs, nil - } - } - return db.lc.get(key) -} - -func (db *DB) updateOffset(ptrs []valuePointer) { - var ptr valuePointer - for i := len(ptrs) - 1; i >= 0; i-- { - p := ptrs[i] - if !p.IsZero() { - ptr = p - break - } - } - if ptr.IsZero() { - return - } - - db.Lock() - defer db.Unlock() - y.AssertTrue(!ptr.Less(db.vptr)) - db.vptr = ptr -} - -var requestPool = sync.Pool{ - New: func() interface{} { - return new(request) - }, -} - -func (db *DB) shouldWriteValueToLSM(e Entry) bool { - return len(e.Value) < db.opt.ValueThreshold -} - -func (db *DB) writeToLSM(b *request) error { - if len(b.Ptrs) != len(b.Entries) { - return errors.Errorf("Ptrs and Entries don't match: %+v", b) - } - - for i, entry := range b.Entries { - if entry.meta&bitFinTxn != 0 { - continue - } - if db.shouldWriteValueToLSM(*entry) { // Will include deletion / tombstone case. - db.mt.Put(entry.Key, - y.ValueStruct{ - Value: entry.Value, - Meta: entry.meta, - UserMeta: entry.UserMeta, - ExpiresAt: entry.ExpiresAt, - }) - } else { - var offsetBuf [vptrSize]byte - db.mt.Put(entry.Key, - y.ValueStruct{ - Value: b.Ptrs[i].Encode(offsetBuf[:]), - Meta: entry.meta | bitValuePointer, - UserMeta: entry.UserMeta, - ExpiresAt: entry.ExpiresAt, - }) - } - } - return nil -} - -// writeRequests is called serially by only one goroutine. -func (db *DB) writeRequests(reqs []*request) error { - if len(reqs) == 0 { - return nil - } - - done := func(err error) { - for _, r := range reqs { - r.Err = err - r.Wg.Done() - } - } - - db.elog.Printf("writeRequests called. Writing to value log") - - err := db.vlog.write(reqs) - if err != nil { - done(err) - return err - } - - db.elog.Printf("Writing to memtable") - var count int - for _, b := range reqs { - if len(b.Entries) == 0 { - continue - } - count += len(b.Entries) - var i uint64 - for err := db.ensureRoomForWrite(); err == errNoRoom; err = db.ensureRoomForWrite() { - i++ - if i%100 == 0 { - db.elog.Printf("Making room for writes") - } - // We need to poll a bit because both hasRoomForWrite and the flusher need access to s.imm. - // When flushChan is full and you are blocked there, and the flusher is trying to update s.imm, - // you will get a deadlock. - time.Sleep(10 * time.Millisecond) - } - if err != nil { - done(err) - return errors.Wrap(err, "writeRequests") - } - if err := db.writeToLSM(b); err != nil { - done(err) - return errors.Wrap(err, "writeRequests") - } - db.updateOffset(b.Ptrs) - } - done(nil) - db.elog.Printf("%d entries written", count) - return nil -} - -func (db *DB) sendToWriteCh(entries []*Entry) (*request, error) { - var count, size int64 - for _, e := range entries { - size += int64(e.estimateSize(db.opt.ValueThreshold)) - count++ - } - if count >= db.opt.maxBatchCount || size >= db.opt.maxBatchSize { - return nil, ErrTxnTooBig - } - - // We can only service one request because we need each txn to be stored in a contigous section. - // Txns should not interleave among other txns or rewrites. - req := requestPool.Get().(*request) - req.Entries = entries - req.Wg = sync.WaitGroup{} - req.Wg.Add(1) - db.writeCh <- req // Handled in doWrites. - y.NumPuts.Add(int64(len(entries))) - - return req, nil -} - -func (db *DB) doWrites(lc *y.Closer) { - defer lc.Done() - pendingCh := make(chan struct{}, 1) - - writeRequests := func(reqs []*request) { - if err := db.writeRequests(reqs); err != nil { - log.Printf("ERROR in Badger::writeRequests: %v", err) - } - <-pendingCh - } - - // This variable tracks the number of pending writes. - reqLen := new(expvar.Int) - y.PendingWrites.Set(db.opt.Dir, reqLen) - - reqs := make([]*request, 0, 10) - for { - var r *request - select { - case r = <-db.writeCh: - case <-lc.HasBeenClosed(): - goto closedCase - } - - for { - reqs = append(reqs, r) - reqLen.Set(int64(len(reqs))) - - if len(reqs) >= 3*kvWriteChCapacity { - pendingCh <- struct{}{} // blocking. - goto writeCase - } - - select { - // Either push to pending, or continue to pick from writeCh. - case r = <-db.writeCh: - case pendingCh <- struct{}{}: - goto writeCase - case <-lc.HasBeenClosed(): - goto closedCase - } - } - - closedCase: - close(db.writeCh) - for r := range db.writeCh { // Flush the channel. - reqs = append(reqs, r) - } - - pendingCh <- struct{}{} // Push to pending before doing a write. - writeRequests(reqs) - return - - writeCase: - go writeRequests(reqs) - reqs = make([]*request, 0, 10) - reqLen.Set(0) - } -} - -// batchSet applies a list of badger.Entry. If a request level error occurs it -// will be returned. -// Check(kv.BatchSet(entries)) -func (db *DB) batchSet(entries []*Entry) error { - req, err := db.sendToWriteCh(entries) - if err != nil { - return err - } - - return req.Wait() -} - -// batchSetAsync is the asynchronous version of batchSet. It accepts a callback -// function which is called when all the sets are complete. If a request level -// error occurs, it will be passed back via the callback. -// err := kv.BatchSetAsync(entries, func(err error)) { -// Check(err) -// } -func (db *DB) batchSetAsync(entries []*Entry, f func(error)) error { - req, err := db.sendToWriteCh(entries) - if err != nil { - return err - } - go func() { - err := req.Wait() - // Write is complete. Let's call the callback function now. - f(err) - }() - return nil -} - -var errNoRoom = errors.New("No room for write") - -// ensureRoomForWrite is always called serially. -func (db *DB) ensureRoomForWrite() error { - var err error - db.Lock() - defer db.Unlock() - if db.mt.MemSize() < db.opt.MaxTableSize { - return nil - } - - y.AssertTrue(db.mt != nil) // A nil mt indicates that DB is being closed. - select { - case db.flushChan <- flushTask{db.mt, db.vptr}: - db.elog.Printf("Flushing value log to disk if async mode.") - // Ensure value log is synced to disk so this memtable's contents wouldn't be lost. - err = db.vlog.sync() - if err != nil { - return err - } - - db.elog.Printf("Flushing memtable, mt.size=%d size of flushChan: %d\n", - db.mt.MemSize(), len(db.flushChan)) - // We manage to push this task. Let's modify imm. - db.imm = append(db.imm, db.mt) - db.mt = skl.NewSkiplist(arenaSize(db.opt)) - // New memtable is empty. We certainly have room. - return nil - default: - // We need to do this to unlock and allow the flusher to modify imm. - return errNoRoom - } -} - -func arenaSize(opt Options) int64 { - return opt.MaxTableSize + opt.maxBatchSize + opt.maxBatchCount*int64(skl.MaxNodeSize) -} - -// WriteLevel0Table flushes memtable. -func writeLevel0Table(s *skl.Skiplist, f *os.File) error { - iter := s.NewIterator() - defer iter.Close() - b := table.NewTableBuilder() - defer b.Close() - for iter.SeekToFirst(); iter.Valid(); iter.Next() { - if err := b.Add(iter.Key(), iter.Value()); err != nil { - return err - } - } - _, err := f.Write(b.Finish()) - return err -} - -type flushTask struct { - mt *skl.Skiplist - vptr valuePointer -} - -// TODO: Ensure that this function doesn't return, or is handled by another wrapper function. -// Otherwise, we would have no goroutine which can flush memtables. -func (db *DB) flushMemtable(lc *y.Closer) error { - defer lc.Done() - - for ft := range db.flushChan { - if ft.mt == nil { - return nil - } - - if !ft.mt.Empty() { - // Store badger head even if vptr is zero, need it for readTs - db.elog.Printf("Storing offset: %+v\n", ft.vptr) - offset := make([]byte, vptrSize) - ft.vptr.Encode(offset) - - // Pick the max commit ts, so in case of crash, our read ts would be higher than all the - // commits. - headTs := y.KeyWithTs(head, db.orc.commitTs()) - ft.mt.Put(headTs, y.ValueStruct{Value: offset}) - } - - fileID := db.lc.reserveFileID() - fd, err := y.CreateSyncedFile(table.NewFilename(fileID, db.opt.Dir), true) - if err != nil { - return y.Wrap(err) - } - - // Don't block just to sync the directory entry. - dirSyncCh := make(chan error) - go func() { dirSyncCh <- syncDir(db.opt.Dir) }() - - err = writeLevel0Table(ft.mt, fd) - dirSyncErr := <-dirSyncCh - - if err != nil { - db.elog.Errorf("ERROR while writing to level 0: %v", err) - return err - } - if dirSyncErr != nil { - db.elog.Errorf("ERROR while syncing level directory: %v", dirSyncErr) - return err - } - - tbl, err := table.OpenTable(fd, db.opt.TableLoadingMode) - if err != nil { - db.elog.Printf("ERROR while opening table: %v", err) - return err - } - // We own a ref on tbl. - err = db.lc.addLevel0Table(tbl) // This will incrRef (if we don't error, sure) - tbl.DecrRef() // Releases our ref. - if err != nil { - return err - } - - // Update s.imm. Need a lock. - db.Lock() - y.AssertTrue(ft.mt == db.imm[0]) //For now, single threaded. - db.imm = db.imm[1:] - ft.mt.DecrRef() // Return memory. - db.Unlock() - } - return nil -} - -func exists(path string) (bool, error) { - _, err := os.Stat(path) - if err == nil { - return true, nil - } - if os.IsNotExist(err) { - return false, nil - } - return true, err -} - -// This function does a filewalk, calculates the size of vlog and sst files and stores it in -// y.LSMSize and y.VlogSize. -func (db *DB) calculateSize() { - newInt := func(val int64) *expvar.Int { - v := new(expvar.Int) - v.Add(val) - return v - } - - totalSize := func(dir string) (int64, int64) { - var lsmSize, vlogSize int64 - err := filepath.Walk(dir, func(path string, info os.FileInfo, err error) error { - if err != nil { - return err - } - ext := filepath.Ext(path) - if ext == ".sst" { - lsmSize += info.Size() - } else if ext == ".vlog" { - vlogSize += info.Size() - } - return nil - }) - if err != nil { - db.elog.Printf("Got error while calculating total size of directory: %s", dir) - } - return lsmSize, vlogSize - } - - lsmSize, vlogSize := totalSize(db.opt.Dir) - y.LSMSize.Set(db.opt.Dir, newInt(lsmSize)) - // If valueDir is different from dir, we'd have to do another walk. - if db.opt.ValueDir != db.opt.Dir { - _, vlogSize = totalSize(db.opt.ValueDir) - } - y.VlogSize.Set(db.opt.Dir, newInt(vlogSize)) - -} - -func (db *DB) updateSize(lc *y.Closer) { - defer lc.Done() - - metricsTicker := time.NewTicker(time.Minute) - defer metricsTicker.Stop() - - for { - select { - case <-metricsTicker.C: - db.calculateSize() - case <-lc.HasBeenClosed(): - return - } - } -} - -// RunValueLogGC triggers a value log garbage collection. -// -// It picks value log files to perform GC based on statistics that are collected -// duing compactions. If no such statistics are available, then log files are -// picked in random order. The process stops as soon as the first log file is -// encountered which does not result in garbage collection. -// -// When a log file is picked, it is first sampled. If the sample shows that we -// can discard at least discardRatio space of that file, it would be rewritten. -// -// If a call to RunValueLogGC results in no rewrites, then an ErrNoRewrite is -// thrown indicating that the call resulted in no file rewrites. -// -// We recommend setting discardRatio to 0.5, thus indicating that a file be -// rewritten if half the space can be discarded. This results in a lifetime -// value log write amplification of 2 (1 from original write + 0.5 rewrite + -// 0.25 + 0.125 + ... = 2). Setting it to higher value would result in fewer -// space reclaims, while setting it to a lower value would result in more space -// reclaims at the cost of increased activity on the LSM tree. discardRatio -// must be in the range (0.0, 1.0), both endpoints excluded, otherwise an -// ErrInvalidRequest is returned. -// -// Only one GC is allowed at a time. If another value log GC is running, or DB -// has been closed, this would return an ErrRejected. -// -// Note: Every time GC is run, it would produce a spike of activity on the LSM -// tree. -func (db *DB) RunValueLogGC(discardRatio float64) error { - if discardRatio >= 1.0 || discardRatio <= 0.0 { - return ErrInvalidRequest - } - - // Find head on disk - headKey := y.KeyWithTs(head, math.MaxUint64) - // Need to pass with timestamp, lsm get removes the last 8 bytes and compares key - val, err := db.lc.get(headKey) - if err != nil { - return errors.Wrap(err, "Retrieving head from on-disk LSM") - } - - var head valuePointer - if len(val.Value) > 0 { - head.Decode(val.Value) - } - - // Pick a log file and run GC - return db.vlog.runGC(discardRatio, head) -} - -// Size returns the size of lsm and value log files in bytes. It can be used to decide how often to -// call RunValueLogGC. -func (db *DB) Size() (lsm int64, vlog int64) { - if y.LSMSize.Get(db.opt.Dir) == nil { - lsm, vlog = 0, 0 - return - } - lsm = y.LSMSize.Get(db.opt.Dir).(*expvar.Int).Value() - vlog = y.VlogSize.Get(db.opt.Dir).(*expvar.Int).Value() - return -} - -// Sequence represents a Badger sequence. -type Sequence struct { - sync.Mutex - db *DB - key []byte - next uint64 - leased uint64 - bandwidth uint64 -} - -// Next would return the next integer in the sequence, updating the lease by running a transaction -// if needed. -func (seq *Sequence) Next() (uint64, error) { - seq.Lock() - defer seq.Unlock() - if seq.next >= seq.leased { - if err := seq.updateLease(); err != nil { - return 0, err - } - } - val := seq.next - seq.next++ - return val, nil -} - -// Release the leased sequence to avoid wasted integers. This should be done right -// before closing the associated DB. However it is valid to use the sequence after -// it was released, causing a new lease with full bandwidth. -func (seq *Sequence) Release() error { - seq.Lock() - defer seq.Unlock() - err := seq.db.Update(func(txn *Txn) error { - var buf [8]byte - binary.BigEndian.PutUint64(buf[:], seq.next) - return txn.Set(seq.key, buf[:]) - }) - if err != nil { - return err - } - seq.leased = seq.next - return nil -} - -func (seq *Sequence) updateLease() error { - return seq.db.Update(func(txn *Txn) error { - item, err := txn.Get(seq.key) - if err == ErrKeyNotFound { - seq.next = 0 - } else if err != nil { - return err - } else { - val, err := item.Value() - if err != nil { - return err - } - num := binary.BigEndian.Uint64(val) - seq.next = num - } - - lease := seq.next + seq.bandwidth - var buf [8]byte - binary.BigEndian.PutUint64(buf[:], lease) - if err = txn.Set(seq.key, buf[:]); err != nil { - return err - } - seq.leased = lease - return nil - }) -} - -// GetSequence would initiate a new sequence object, generating it from the stored lease, if -// available, in the database. Sequence can be used to get a list of monotonically increasing -// integers. Multiple sequences can be created by providing different keys. Bandwidth sets the -// size of the lease, determining how many Next() requests can be served from memory. -func (db *DB) GetSequence(key []byte, bandwidth uint64) (*Sequence, error) { - switch { - case len(key) == 0: - return nil, ErrEmptyKey - case bandwidth == 0: - return nil, ErrZeroBandwidth - } - seq := &Sequence{ - db: db, - key: key, - next: 0, - leased: 0, - bandwidth: bandwidth, - } - err := seq.updateLease() - return seq, err -} - -func (db *DB) Tables() []TableInfo { - return db.lc.getTableInfo() -} - -// MergeOperator represents a Badger merge operator. -type MergeOperator struct { - sync.RWMutex - f MergeFunc - db *DB - key []byte - closer *y.Closer -} - -// MergeFunc accepts two byte slices, one representing an existing value, and -// another representing a new value that needs to be ‘merged’ into it. MergeFunc -// contains the logic to perform the ‘merge’ and return an updated value. -// MergeFunc could perform operations like integer addition, list appends etc. -// Note that the ordering of the operands is unspecified, so the merge func -// should either be agnostic to ordering or do additional handling if ordering -// is required. -type MergeFunc func(existing, val []byte) []byte - -// GetMergeOperator creates a new MergeOperator for a given key and returns a -// pointer to it. It also fires off a goroutine that performs a compaction using -// the merge function that runs periodically, as specified by dur. -func (db *DB) GetMergeOperator(key []byte, - f MergeFunc, dur time.Duration) *MergeOperator { - op := &MergeOperator{ - f: f, - db: db, - key: key, - closer: y.NewCloser(1), - } - - go op.runCompactions(dur) - return op -} - -var errNoMerge = errors.New("No need for merge") - -func (op *MergeOperator) iterateAndMerge(txn *Txn) (val []byte, err error) { - opt := DefaultIteratorOptions - opt.AllVersions = true - it := txn.NewIterator(opt) - var numVersions int - for it.Rewind(); it.ValidForPrefix(op.key); it.Next() { - item := it.Item() - numVersions++ - if numVersions == 1 { - val, err = item.ValueCopy(val) - if err != nil { - return nil, err - } - } else { - newVal, err := item.Value() - if err != nil { - return nil, err - } - val = op.f(val, newVal) - } - if item.DiscardEarlierVersions() { - break - } - } - if numVersions == 0 { - return nil, ErrKeyNotFound - } else if numVersions == 1 { - return val, errNoMerge - } - return val, nil -} - -func (op *MergeOperator) compact() error { - op.Lock() - defer op.Unlock() - err := op.db.Update(func(txn *Txn) error { - var ( - val []byte - err error - ) - val, err = op.iterateAndMerge(txn) - if err != nil { - return err - } - - // Write value back to db - if err := txn.SetWithDiscard(op.key, val, 0); err != nil { - return err - } - return nil - }) - - if err == ErrKeyNotFound || err == errNoMerge { - // pass. - } else if err != nil { - return err - } - return nil -} - -func (op *MergeOperator) runCompactions(dur time.Duration) { - ticker := time.NewTicker(dur) - defer op.closer.Done() - var stop bool - for { - select { - case <-op.closer.HasBeenClosed(): - stop = true - case <-ticker.C: // wait for tick - } - if err := op.compact(); err != nil { - log.Printf("Error while running merge operation: %s", err) - } - if stop { - ticker.Stop() - break - } - } -} - -// Add records a value in Badger which will eventually be merged by a background -// routine into the values that were recorded by previous invocations to Add(). -func (op *MergeOperator) Add(val []byte) error { - return op.db.Update(func(txn *Txn) error { - return txn.Set(op.key, val) - }) -} - -// Get returns the latest value for the merge operator, which is derived by -// applying the merge function to all the values added so far. -// -// If Add has not been called even once, Get will return ErrKeyNotFound. -func (op *MergeOperator) Get() ([]byte, error) { - op.RLock() - defer op.RUnlock() - var existing []byte - err := op.db.View(func(txn *Txn) (err error) { - existing, err = op.iterateAndMerge(txn) - return err - }) - if err == errNoMerge { - return existing, nil - } - return existing, err -} - -// Stop waits for any pending merge to complete and then stops the background -// goroutine. -func (op *MergeOperator) Stop() { - op.closer.SignalAndWait() -} diff --git a/vendor/github.com/dgraph-io/badger/db_test.go b/vendor/github.com/dgraph-io/badger/db_test.go deleted file mode 100644 index 004b837..0000000 --- a/vendor/github.com/dgraph-io/badger/db_test.go +++ /dev/null @@ -1,1565 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bytes" - "encoding/binary" - "flag" - "fmt" - "io/ioutil" - "log" - "math" - "math/rand" - "os" - "path/filepath" - "regexp" - "sort" - "sync" - "testing" - "time" - - "github.com/dgraph-io/badger/options" - - "github.com/dgraph-io/badger/y" - "github.com/stretchr/testify/require" -) - -var mmap = flag.Bool("vlog_mmap", true, "Specify if value log must be memory-mapped") - -func getTestOptions(dir string) Options { - opt := DefaultOptions - opt.MaxTableSize = 1 << 15 // Force more compaction. - opt.LevelOneSize = 4 << 15 // Force more compaction. - opt.Dir = dir - opt.ValueDir = dir - opt.SyncWrites = false - if !*mmap { - opt.ValueLogLoadingMode = options.FileIO - } - return opt -} - -func getItemValue(t *testing.T, item *Item) (val []byte) { - v, err := item.Value() - if err != nil { - t.Error(err) - } - if v == nil { - return nil - } - another, err := item.ValueCopy(nil) - require.NoError(t, err) - require.Equal(t, v, another) - return v -} - -func txnSet(t *testing.T, kv *DB, key []byte, val []byte, meta byte) { - txn := kv.NewTransaction(true) - require.NoError(t, txn.SetWithMeta(key, val, meta)) - require.NoError(t, txn.Commit(nil)) -} - -func txnDelete(t *testing.T, kv *DB, key []byte) { - txn := kv.NewTransaction(true) - require.NoError(t, txn.Delete(key)) - require.NoError(t, txn.Commit(nil)) -} - -// Opens a badger db and runs a a test on it. -func runBadgerTest(t *testing.T, opts *Options, test func(t *testing.T, db *DB)) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - if opts == nil { - opts = new(Options) - *opts = getTestOptions(dir) - } - db, err := Open(*opts) - require.NoError(t, err) - defer db.Close() - test(t, db) -} - -func TestWrite(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - for i := 0; i < 100; i++ { - txnSet(t, db, []byte(fmt.Sprintf("key%d", i)), []byte(fmt.Sprintf("val%d", i)), 0x00) - } - }) -} - -func TestUpdateAndView(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - err := db.Update(func(txn *Txn) error { - for i := 0; i < 10; i++ { - err := txn.Set([]byte(fmt.Sprintf("key%d", i)), []byte(fmt.Sprintf("val%d", i))) - if err != nil { - return err - } - } - return nil - }) - require.NoError(t, err) - - err = db.View(func(txn *Txn) error { - for i := 0; i < 10; i++ { - item, err := txn.Get([]byte(fmt.Sprintf("key%d", i))) - if err != nil { - return err - } - - val, err := item.Value() - if err != nil { - return err - } - expected := []byte(fmt.Sprintf("val%d", i)) - require.Equal(t, expected, val, - "Invalid value for key %q. expected: %q, actual: %q", - item.Key(), expected, val) - } - return nil - }) - require.NoError(t, err) - }) -} - -func TestConcurrentWrite(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // Not a benchmark. Just a simple test for concurrent writes. - n := 20 - m := 500 - var wg sync.WaitGroup - for i := 0; i < n; i++ { - wg.Add(1) - go func(i int) { - defer wg.Done() - for j := 0; j < m; j++ { - txnSet(t, db, []byte(fmt.Sprintf("k%05d_%08d", i, j)), - []byte(fmt.Sprintf("v%05d_%08d", i, j)), byte(j%127)) - } - }(i) - } - wg.Wait() - - t.Log("Starting iteration") - - opt := IteratorOptions{} - opt.Reverse = false - opt.PrefetchSize = 10 - opt.PrefetchValues = true - - txn := db.NewTransaction(true) - it := txn.NewIterator(opt) - defer it.Close() - var i, j int - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - k := item.Key() - if k == nil { - break // end of iteration. - } - - require.EqualValues(t, fmt.Sprintf("k%05d_%08d", i, j), string(k)) - v := getItemValue(t, item) - require.EqualValues(t, fmt.Sprintf("v%05d_%08d", i, j), string(v)) - require.Equal(t, item.UserMeta(), byte(j%127)) - j++ - if j == m { - i++ - j = 0 - } - } - require.EqualValues(t, n, i) - require.EqualValues(t, 0, j) - }) -} - -func TestGet(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - txnSet(t, db, []byte("key1"), []byte("val1"), 0x08) - - txn := db.NewTransaction(false) - item, err := txn.Get([]byte("key1")) - require.NoError(t, err) - require.EqualValues(t, "val1", getItemValue(t, item)) - require.Equal(t, byte(0x08), item.UserMeta()) - txn.Discard() - - txnSet(t, db, []byte("key1"), []byte("val2"), 0x09) - - txn = db.NewTransaction(false) - item, err = txn.Get([]byte("key1")) - require.NoError(t, err) - require.EqualValues(t, "val2", getItemValue(t, item)) - require.Equal(t, byte(0x09), item.UserMeta()) - txn.Discard() - - txnDelete(t, db, []byte("key1")) - - txn = db.NewTransaction(false) - _, err = txn.Get([]byte("key1")) - require.Equal(t, ErrKeyNotFound, err) - txn.Discard() - - txnSet(t, db, []byte("key1"), []byte("val3"), 0x01) - - txn = db.NewTransaction(false) - item, err = txn.Get([]byte("key1")) - require.NoError(t, err) - require.EqualValues(t, "val3", getItemValue(t, item)) - require.Equal(t, byte(0x01), item.UserMeta()) - - longVal := make([]byte, 1000) - txnSet(t, db, []byte("key1"), longVal, 0x00) - - txn = db.NewTransaction(false) - item, err = txn.Get([]byte("key1")) - require.NoError(t, err) - require.EqualValues(t, longVal, getItemValue(t, item)) - txn.Discard() - }) -} - -func TestGetAfterDelete(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // populate with one entry - key := []byte("key") - txnSet(t, db, key, []byte("val1"), 0x00) - require.NoError(t, db.Update(func(txn *Txn) error { - err := txn.Delete(key) - require.NoError(t, err) - - _, err = txn.Get(key) - require.Equal(t, ErrKeyNotFound, err) - return nil - })) - }) -} - -func TestTxnTooBig(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - data := func(i int) []byte { - return []byte(fmt.Sprintf("%b", i)) - } - // n := 500000 - n := 1000 - txn := db.NewTransaction(true) - for i := 0; i < n; { - if err := txn.Set(data(i), data(i)); err != nil { - require.NoError(t, txn.Commit(nil)) - txn = db.NewTransaction(true) - } else { - i++ - } - } - require.NoError(t, txn.Commit(nil)) - - txn = db.NewTransaction(true) - for i := 0; i < n; { - if err := txn.Delete(data(i)); err != nil { - require.NoError(t, txn.Commit(nil)) - txn = db.NewTransaction(true) - } else { - i++ - } - } - require.NoError(t, txn.Commit(nil)) - }) -} - -func TestForceCompactL0(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opts := getTestOptions(dir) - opts.ValueLogFileSize = 15 << 20 - db, err := OpenManaged(opts) - require.NoError(t, err) - - data := func(i int) []byte { - return []byte(fmt.Sprintf("%b", i)) - } - n := 80 - m := 45 // Increasing would cause ErrTxnTooBig - sz := 32 << 10 - v := make([]byte, sz) - for i := 0; i < n; i += 2 { - version := uint64(i) - txn := db.NewTransactionAt(version, true) - for j := 0; j < m; j++ { - require.NoError(t, txn.Set(data(j), v)) - } - require.NoError(t, txn.CommitAt(version+1, nil)) - } - db.Close() - - db, err = OpenManaged(opts) - defer db.Close() - require.Equal(t, len(db.lc.levels[0].tables), 0) -} - -// Put a lot of data to move some data to disk. -// WARNING: This test might take a while but it should pass! -func TestGetMore(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - - data := func(i int) []byte { - return []byte(fmt.Sprintf("%b", i)) - } - // n := 500000 - n := 10000 - m := 45 // Increasing would cause ErrTxnTooBig - for i := 0; i < n; i += m { - txn := db.NewTransaction(true) - for j := i; j < i+m && j < n; j++ { - require.NoError(t, txn.Set(data(j), data(j))) - } - require.NoError(t, txn.Commit(nil)) - } - require.NoError(t, db.validate()) - - for i := 0; i < n; i++ { - txn := db.NewTransaction(false) - item, err := txn.Get(data(i)) - if err != nil { - t.Error(err) - } - require.EqualValues(t, string(data(i)), string(getItemValue(t, item))) - txn.Discard() - } - - // Overwrite - for i := 0; i < n; i += m { - txn := db.NewTransaction(true) - for j := i; j < i+m && j < n; j++ { - require.NoError(t, txn.Set(data(j), - // Use a long value that will certainly exceed value threshold. - []byte(fmt.Sprintf("zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz%9d", j)))) - } - require.NoError(t, txn.Commit(nil)) - } - require.NoError(t, db.validate()) - - for i := 0; i < n; i++ { - expectedValue := fmt.Sprintf("zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz%9d", i) - k := data(i) - txn := db.NewTransaction(false) - item, err := txn.Get(k) - if err != nil { - t.Error(err) - } - got := string(getItemValue(t, item)) - if expectedValue != got { - - vs, err := db.get(y.KeyWithTs(k, math.MaxUint64)) - require.NoError(t, err) - fmt.Printf("wanted=%q Item: %s\n", k, item) - fmt.Printf("on re-run, got version: %+v\n", vs) - - txn := db.NewTransaction(false) - itr := txn.NewIterator(DefaultIteratorOptions) - for itr.Seek(k); itr.Valid(); itr.Next() { - item := itr.Item() - fmt.Printf("item=%s\n", item) - if !bytes.Equal(item.Key(), k) { - break - } - } - itr.Close() - txn.Discard() - } - require.EqualValues(t, expectedValue, string(getItemValue(t, item)), "wanted=%q Item: %s\n", k, item) - txn.Discard() - } - - // "Delete" key. - for i := 0; i < n; i += m { - if (i % 10000) == 0 { - fmt.Printf("Deleting i=%d\n", i) - } - txn := db.NewTransaction(true) - for j := i; j < i+m && j < n; j++ { - require.NoError(t, txn.Delete(data(j))) - } - require.NoError(t, txn.Commit(nil)) - } - db.validate() - for i := 0; i < n; i++ { - if (i % 10000) == 0 { - // Display some progress. Right now, it's not very fast with no caching. - fmt.Printf("Testing i=%d\n", i) - } - k := data(i) - txn := db.NewTransaction(false) - _, err := txn.Get([]byte(k)) - require.Equal(t, ErrKeyNotFound, err, "should not have found k: %q", k) - txn.Discard() - } - }) -} - -// Put a lot of data to move some data to disk. -// WARNING: This test might take a while but it should pass! -func TestExistsMore(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // n := 500000 - n := 10000 - m := 45 - for i := 0; i < n; i += m { - if (i % 1000) == 0 { - t.Logf("Putting i=%d\n", i) - } - txn := db.NewTransaction(true) - for j := i; j < i+m && j < n; j++ { - require.NoError(t, txn.Set([]byte(fmt.Sprintf("%09d", j)), - []byte(fmt.Sprintf("%09d", j)))) - } - require.NoError(t, txn.Commit(nil)) - } - db.validate() - - for i := 0; i < n; i++ { - if (i % 1000) == 0 { - fmt.Printf("Testing i=%d\n", i) - } - k := fmt.Sprintf("%09d", i) - require.NoError(t, db.View(func(txn *Txn) error { - _, err := txn.Get([]byte(k)) - require.NoError(t, err) - return nil - })) - } - require.NoError(t, db.View(func(txn *Txn) error { - _, err := txn.Get([]byte("non-exists")) - require.Error(t, err) - return nil - })) - - // "Delete" key. - for i := 0; i < n; i += m { - if (i % 1000) == 0 { - fmt.Printf("Deleting i=%d\n", i) - } - txn := db.NewTransaction(true) - for j := i; j < i+m && j < n; j++ { - require.NoError(t, txn.Delete([]byte(fmt.Sprintf("%09d", j)))) - } - require.NoError(t, txn.Commit(nil)) - } - db.validate() - for i := 0; i < n; i++ { - if (i % 10000) == 0 { - // Display some progress. Right now, it's not very fast with no caching. - fmt.Printf("Testing i=%d\n", i) - } - k := fmt.Sprintf("%09d", i) - - require.NoError(t, db.View(func(txn *Txn) error { - _, err := txn.Get([]byte(k)) - require.Error(t, err) - return nil - })) - } - fmt.Println("Done and closing") - }) -} - -func TestIterate2Basic(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - - bkey := func(i int) []byte { - return []byte(fmt.Sprintf("%09d", i)) - } - bval := func(i int) []byte { - return []byte(fmt.Sprintf("%025d", i)) - } - - // n := 500000 - n := 10000 - for i := 0; i < n; i++ { - if (i % 1000) == 0 { - t.Logf("Put i=%d\n", i) - } - txnSet(t, db, bkey(i), bval(i), byte(i%127)) - } - - opt := IteratorOptions{} - opt.PrefetchValues = true - opt.PrefetchSize = 10 - - txn := db.NewTransaction(false) - it := txn.NewIterator(opt) - { - var count int - rewind := true - t.Log("Starting first basic iteration") - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - key := item.Key() - if rewind && count == 5000 { - // Rewind would skip /head/ key, and it.Next() would skip 0. - count = 1 - it.Rewind() - t.Log("Rewinding from 5000 to zero.") - rewind = false - continue - } - require.EqualValues(t, bkey(count), string(key)) - val := getItemValue(t, item) - require.EqualValues(t, bval(count), string(val)) - require.Equal(t, byte(count%127), item.UserMeta()) - count++ - } - require.EqualValues(t, n, count) - } - - { - t.Log("Starting second basic iteration") - idx := 5030 - for it.Seek(bkey(idx)); it.Valid(); it.Next() { - item := it.Item() - require.EqualValues(t, bkey(idx), string(item.Key())) - require.EqualValues(t, bval(idx), string(getItemValue(t, item))) - idx++ - } - } - it.Close() - }) -} - -func TestLoad(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - fmt.Printf("Writing to dir %s\n", dir) - require.NoError(t, err) - defer os.RemoveAll(dir) - n := 10000 - { - kv, _ := Open(getTestOptions(dir)) - for i := 0; i < n; i++ { - if (i % 10000) == 0 { - fmt.Printf("Putting i=%d\n", i) - } - k := []byte(fmt.Sprintf("%09d", i)) - txnSet(t, kv, k, k, 0x00) - } - kv.Close() - } - - kv, err := Open(getTestOptions(dir)) - require.NoError(t, err) - require.Equal(t, uint64(10001), kv.orc.readTs()) - for i := 0; i < n; i++ { - if (i % 10000) == 0 { - fmt.Printf("Testing i=%d\n", i) - } - k := fmt.Sprintf("%09d", i) - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get([]byte(k)) - require.NoError(t, err) - require.EqualValues(t, k, string(getItemValue(t, item))) - return nil - })) - - } - kv.Close() - summary := kv.lc.getSummary() - - // Check that files are garbage collected. - idMap := getIDMap(dir) - for fileID := range idMap { - // Check that name is in summary.filenames. - require.True(t, summary.fileIDs[fileID], "%d", fileID) - } - require.EqualValues(t, len(idMap), len(summary.fileIDs)) - - var fileIDs []uint64 - for k := range summary.fileIDs { // Map to array. - fileIDs = append(fileIDs, k) - } - sort.Slice(fileIDs, func(i, j int) bool { return fileIDs[i] < fileIDs[j] }) - fmt.Printf("FileIDs: %v\n", fileIDs) -} - -func TestIterateDeleted(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - txnSet(t, db, []byte("Key1"), []byte("Value1"), 0x00) - txnSet(t, db, []byte("Key2"), []byte("Value2"), 0x00) - - iterOpt := DefaultIteratorOptions - iterOpt.PrefetchValues = false - txn := db.NewTransaction(false) - idxIt := txn.NewIterator(iterOpt) - defer idxIt.Close() - - count := 0 - txn2 := db.NewTransaction(true) - prefix := []byte("Key") - for idxIt.Seek(prefix); idxIt.ValidForPrefix(prefix); idxIt.Next() { - key := idxIt.Item().Key() - count++ - newKey := make([]byte, len(key)) - copy(newKey, key) - require.NoError(t, txn2.Delete(newKey)) - } - require.Equal(t, 2, count) - require.NoError(t, txn2.Commit(nil)) - - for _, prefetch := range [...]bool{true, false} { - t.Run(fmt.Sprintf("Prefetch=%t", prefetch), func(t *testing.T) { - txn := db.NewTransaction(false) - iterOpt = DefaultIteratorOptions - iterOpt.PrefetchValues = prefetch - idxIt = txn.NewIterator(iterOpt) - - var estSize int64 - var idxKeys []string - for idxIt.Seek(prefix); idxIt.Valid(); idxIt.Next() { - item := idxIt.Item() - key := item.Key() - estSize += item.EstimatedSize() - if !bytes.HasPrefix(key, prefix) { - break - } - idxKeys = append(idxKeys, string(key)) - t.Logf("%+v\n", idxIt.Item()) - } - require.Equal(t, 0, len(idxKeys)) - require.Equal(t, int64(0), estSize) - }) - } - }) -} - -func TestDeleteWithoutSyncWrite(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - opt := DefaultOptions - opt.Dir = dir - opt.ValueDir = dir - kv, err := Open(opt) - if err != nil { - t.Error(err) - t.Fail() - } - - key := []byte("k1") - // Set a value with size > value threshold so that its written to value log. - txnSet(t, kv, key, []byte("ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789FOOBARZOGZOG"), 0x00) - txnDelete(t, kv, key) - kv.Close() - - // Reopen KV - kv, err = Open(opt) - if err != nil { - t.Error(err) - t.Fail() - } - defer kv.Close() - - require.NoError(t, kv.View(func(txn *Txn) error { - _, err := txn.Get(key) - require.Equal(t, ErrKeyNotFound, err) - return nil - })) -} - -func TestPidFile(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // Reopen database - _, err := Open(getTestOptions(db.opt.Dir)) - require.Error(t, err) - require.Contains(t, err.Error(), "Another process is using this Badger database") - }) -} - -func TestBigKeyValuePairs(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - bigK := make([]byte, maxKeySize+1) - bigV := make([]byte, db.opt.ValueLogFileSize+1) - small := make([]byte, 10) - - txn := db.NewTransaction(true) - require.Regexp(t, regexp.MustCompile("Key.*exceeded"), txn.Set(bigK, small)) - require.Regexp(t, regexp.MustCompile("Value.*exceeded"), txn.Set(small, bigV)) - - require.NoError(t, txn.Set(small, small)) - require.Regexp(t, regexp.MustCompile("Key.*exceeded"), txn.Set(bigK, bigV)) - - require.NoError(t, db.View(func(txn *Txn) error { - _, err := txn.Get(small) - require.Equal(t, ErrKeyNotFound, err) - return nil - })) - }) -} - -func TestIteratorPrefetchSize(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - - bkey := func(i int) []byte { - return []byte(fmt.Sprintf("%09d", i)) - } - bval := func(i int) []byte { - return []byte(fmt.Sprintf("%025d", i)) - } - - n := 100 - for i := 0; i < n; i++ { - // if (i % 10) == 0 { - // t.Logf("Put i=%d\n", i) - // } - txnSet(t, db, bkey(i), bval(i), byte(i%127)) - } - - getIteratorCount := func(prefetchSize int) int { - opt := IteratorOptions{} - opt.PrefetchValues = true - opt.PrefetchSize = prefetchSize - - var count int - txn := db.NewTransaction(false) - it := txn.NewIterator(opt) - { - t.Log("Starting first basic iteration") - for it.Rewind(); it.Valid(); it.Next() { - count++ - } - require.EqualValues(t, n, count) - } - return count - } - - var sizes = []int{-10, 0, 1, 10} - for _, size := range sizes { - c := getIteratorCount(size) - require.Equal(t, 100, c) - } - }) -} - -func TestSetIfAbsentAsync(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - kv, _ := Open(getTestOptions(dir)) - - bkey := func(i int) []byte { - return []byte(fmt.Sprintf("%09d", i)) - } - - f := func(err error) {} - - n := 1000 - for i := 0; i < n; i++ { - // if (i % 10) == 0 { - // t.Logf("Put i=%d\n", i) - // } - txn := kv.NewTransaction(true) - _, err = txn.Get(bkey(i)) - require.Equal(t, ErrKeyNotFound, err) - require.NoError(t, txn.SetWithMeta(bkey(i), nil, byte(i%127))) - require.NoError(t, txn.Commit(f)) - } - - require.NoError(t, kv.Close()) - kv, err = Open(getTestOptions(dir)) - require.NoError(t, err) - - opt := DefaultIteratorOptions - txn := kv.NewTransaction(false) - var count int - it := txn.NewIterator(opt) - { - t.Log("Starting first basic iteration") - for it.Rewind(); it.Valid(); it.Next() { - count++ - } - require.EqualValues(t, n, count) - } - require.Equal(t, n, count) - require.NoError(t, kv.Close()) -} - -func TestGetSetRace(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - - data := make([]byte, 4096) - _, err := rand.Read(data) - require.NoError(t, err) - - var ( - numOp = 100 - wg sync.WaitGroup - keyCh = make(chan string) - ) - - // writer - wg.Add(1) - go func() { - defer func() { - wg.Done() - close(keyCh) - }() - - for i := 0; i < numOp; i++ { - key := fmt.Sprintf("%d", i) - txnSet(t, db, []byte(key), data, 0x00) - keyCh <- key - } - }() - - // reader - wg.Add(1) - go func() { - defer wg.Done() - - for key := range keyCh { - require.NoError(t, db.View(func(txn *Txn) error { - item, err := txn.Get([]byte(key)) - require.NoError(t, err) - _, err = item.Value() - require.NoError(t, err) - return nil - })) - } - }() - - wg.Wait() - }) -} - -func TestDiscardVersionsBelow(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // Write 4 versions of the same key - for i := 0; i < 4; i++ { - err := db.Update(func(txn *Txn) error { - return txn.Set([]byte("answer"), []byte(fmt.Sprintf("%d", i))) - }) - require.NoError(t, err) - } - - opts := DefaultIteratorOptions - opts.AllVersions = true - opts.PrefetchValues = false - - // Verify that there are 4 versions, and record 3rd version (2nd from top in iteration) - db.View(func(txn *Txn) error { - it := txn.NewIterator(opts) - var count int - for it.Rewind(); it.Valid(); it.Next() { - count++ - item := it.Item() - require.Equal(t, []byte("answer"), item.Key()) - if item.DiscardEarlierVersions() { - break - } - } - require.Equal(t, 4, count) - return nil - }) - - // Set new version and discard older ones. - err := db.Update(func(txn *Txn) error { - return txn.SetWithDiscard([]byte("answer"), []byte("5"), 0) - }) - require.NoError(t, err) - - // Verify that there are only 2 versions left, and versions - // below ts have been deleted. - db.View(func(txn *Txn) error { - it := txn.NewIterator(opts) - var count int - for it.Rewind(); it.Valid(); it.Next() { - count++ - item := it.Item() - require.Equal(t, []byte("answer"), item.Key()) - if item.DiscardEarlierVersions() { - break - } - } - require.Equal(t, 1, count) - return nil - }) - }) -} - -func TestExpiry(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // Write two keys, one with a TTL - err := db.Update(func(txn *Txn) error { - return txn.Set([]byte("answer1"), []byte("42")) - }) - require.NoError(t, err) - - err = db.Update(func(txn *Txn) error { - return txn.SetWithTTL([]byte("answer2"), []byte("43"), 1*time.Second) - }) - require.NoError(t, err) - - time.Sleep(2 * time.Second) - - // Verify that only unexpired key is found during iteration - err = db.View(func(txn *Txn) error { - _, err := txn.Get([]byte("answer1")) - require.NoError(t, err) - - _, err = txn.Get([]byte("answer2")) - require.Equal(t, ErrKeyNotFound, err) - return nil - }) - require.NoError(t, err) - - // Verify that only one key is found during iteration - opts := DefaultIteratorOptions - opts.PrefetchValues = false - err = db.View(func(txn *Txn) error { - it := txn.NewIterator(opts) - var count int - for it.Rewind(); it.Valid(); it.Next() { - count++ - item := it.Item() - require.Equal(t, []byte("answer1"), item.Key()) - } - require.Equal(t, 1, count) - return nil - }) - require.NoError(t, err) - }) -} - -func randBytes(n int) []byte { - recv := make([]byte, n) - in, err := rand.Read(recv) - if err != nil { - log.Fatal(err) - } - return recv[:in] -} - -var benchmarkData = []struct { - key, value []byte -}{ - {randBytes(100), nil}, - {randBytes(1000), []byte("foo")}, - {[]byte("foo"), randBytes(1000)}, - {[]byte(""), randBytes(1000)}, - {nil, randBytes(1000000)}, - {randBytes(100000), nil}, - {randBytes(1000000), nil}, -} - -func TestLargeKeys(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opts := new(Options) - *opts = DefaultOptions - opts.ValueLogFileSize = 1024 * 1024 * 1024 - opts.Dir = dir - opts.ValueDir = dir - - db, err := Open(*opts) - if err != nil { - t.Fatal(err) - } - for i := 0; i < 1000; i++ { - tx := db.NewTransaction(true) - for _, kv := range benchmarkData { - k := make([]byte, len(kv.key)) - copy(k, kv.key) - - v := make([]byte, len(kv.value)) - copy(v, kv.value) - if err := tx.Set(k, v); err != nil { - // Skip over this record. - } - } - if err := tx.Commit(nil); err != nil { - t.Fatalf("#%d: batchSet err: %v", i, err) - } - } -} - -func TestCreateDirs(t *testing.T) { - dir, err := ioutil.TempDir("", "parent") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opts := DefaultOptions - dir = filepath.Join(dir, "badger") - opts.Dir = dir - opts.ValueDir = dir - db, err := Open(opts) - require.NoError(t, err) - db.Close() - _, err = os.Stat(dir) - require.NoError(t, err) -} - -func TestGetSetDeadlock(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - fmt.Println(dir) - require.NoError(t, err) - defer os.RemoveAll(dir) - - opt := DefaultOptions - opt.Dir = dir - opt.ValueDir = dir - opt.ValueLogFileSize = 1 << 20 - db, err := Open(opt) - require.NoError(t, err) - defer db.Close() - - val := make([]byte, 1<<19) - key := []byte("key1") - require.NoError(t, db.Update(func(txn *Txn) error { - rand.Read(val) - require.NoError(t, txn.Set(key, val)) - return nil - })) - - timeout, done := time.After(10*time.Second), make(chan bool) - - go func() { - db.Update(func(txn *Txn) error { - item, err := txn.Get(key) - require.NoError(t, err) - _, err = item.Value() // This take a RLock on file - require.NoError(t, err) - - rand.Read(val) - require.NoError(t, txn.Set(key, val)) - require.NoError(t, txn.Set([]byte("key2"), val)) - return nil - }) - done <- true - }() - - select { - case <-timeout: - t.Fatal("db.Update did not finish within 10s, assuming deadlock.") - case <-done: - t.Log("db.Update finished.") - } -} - -func TestWriteDeadlock(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - fmt.Println(dir) - require.NoError(t, err) - defer os.RemoveAll(dir) - - opt := DefaultOptions - opt.Dir = dir - opt.ValueDir = dir - opt.ValueLogFileSize = 10 << 20 - db, err := Open(opt) - require.NoError(t, err) - - print := func(count *int) { - *count++ - if *count%100 == 0 { - fmt.Printf("%05d\r", *count) - } - } - - var count int - val := make([]byte, 10000) - require.NoError(t, db.Update(func(txn *Txn) error { - for i := 0; i < 1500; i++ { - key := fmt.Sprintf("%d", i) - rand.Read(val) - require.NoError(t, txn.Set([]byte(key), val)) - print(&count) - } - return nil - })) - - count = 0 - fmt.Println("\nWrites done. Iteration and updates starting...") - err = db.Update(func(txn *Txn) error { - opt := DefaultIteratorOptions - opt.PrefetchValues = false - it := txn.NewIterator(opt) - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - - // Using Value() would cause deadlock. - // item.Value() - out, err := item.ValueCopy(nil) - require.NoError(t, err) - require.Equal(t, len(val), len(out)) - - key := y.Copy(item.Key()) - rand.Read(val) - require.NoError(t, txn.Set(key, val)) - print(&count) - } - return nil - }) - require.NoError(t, err) -} - -func TestSequence(t *testing.T) { - key0 := []byte("seq0") - key1 := []byte("seq1") - - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - seq0, err := db.GetSequence(key0, 10) - require.NoError(t, err) - seq1, err := db.GetSequence(key1, 100) - require.NoError(t, err) - - for i := uint64(0); i < uint64(105); i++ { - num, err := seq0.Next() - require.NoError(t, err) - require.Equal(t, i, num) - - num, err = seq1.Next() - require.NoError(t, err) - require.Equal(t, i, num) - } - err = db.View(func(txn *Txn) error { - item, err := txn.Get(key0) - if err != nil { - return err - } - val, err := item.Value() - if err != nil { - return err - } - num0 := binary.BigEndian.Uint64(val) - require.Equal(t, uint64(110), num0) - - item, err = txn.Get(key1) - if err != nil { - return err - } - val, err = item.Value() - if err != nil { - return err - } - num1 := binary.BigEndian.Uint64(val) - require.Equal(t, uint64(200), num1) - return nil - }) - require.NoError(t, err) - }) -} - -func TestSequence_Release(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // get sequence, use once and release - key := []byte("key") - seq, err := db.GetSequence(key, 1000) - require.NoError(t, err) - num, err := seq.Next() - require.NoError(t, err) - require.Equal(t, uint64(0), num) - require.NoError(t, seq.Release()) - - // we used up 0 and 1 should be stored now - err = db.View(func(txn *Txn) error { - item, err := txn.Get(key) - if err != nil { - return err - } - val, err := item.Value() - if err != nil { - return err - } - require.Equal(t, num+1, binary.BigEndian.Uint64(val)) - return nil - }) - require.NoError(t, err) - - // using it again will lease 1+1000 - num, err = seq.Next() - require.NoError(t, err) - require.Equal(t, uint64(1), num) - err = db.View(func(txn *Txn) error { - item, err := txn.Get(key) - if err != nil { - return err - } - val, err := item.Value() - if err != nil { - return err - } - require.Equal(t, uint64(1001), binary.BigEndian.Uint64(val)) - return nil - }) - require.NoError(t, err) - }) -} - -func uint64ToBytes(i uint64) []byte { - var buf [8]byte - binary.BigEndian.PutUint64(buf[:], i) - return buf[:] -} - -func bytesToUint64(b []byte) uint64 { - return binary.BigEndian.Uint64(b) -} - -// Merge function to add two uint64 numbers -func add(existing, new []byte) []byte { - return uint64ToBytes( - bytesToUint64(existing) + - bytesToUint64(new)) -} - -func TestMergeOperatorGetBeforeAdd(t *testing.T) { - key := []byte("merge") - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - m := db.GetMergeOperator(key, add, 200*time.Millisecond) - defer m.Stop() - - _, err := m.Get() - require.Equal(t, ErrKeyNotFound, err) - }) -} - -func TestMergeOperatorBeforeAdd(t *testing.T) { - key := []byte("merge") - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - m := db.GetMergeOperator(key, add, 200*time.Millisecond) - defer m.Stop() - time.Sleep(time.Second) - }) -} - -func TestMergeOperatorAddAndGet(t *testing.T) { - key := []byte("merge") - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - m := db.GetMergeOperator(key, add, 200*time.Millisecond) - defer m.Stop() - - err := m.Add(uint64ToBytes(1)) - require.NoError(t, err) - m.Add(uint64ToBytes(2)) - require.NoError(t, err) - m.Add(uint64ToBytes(3)) - require.NoError(t, err) - - res, err := m.Get() - require.NoError(t, err) - require.Equal(t, uint64(6), bytesToUint64(res)) - }) -} - -func TestMergeOperatorCompactBeforeGet(t *testing.T) { - key := []byte("merge") - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - m := db.GetMergeOperator(key, add, 200*time.Millisecond) - defer m.Stop() - - err := m.Add(uint64ToBytes(1)) - require.NoError(t, err) - m.Add(uint64ToBytes(2)) - require.NoError(t, err) - m.Add(uint64ToBytes(3)) - require.NoError(t, err) - - time.Sleep(250 * time.Millisecond) // wait for merge to happen - - res, err := m.Get() - require.NoError(t, err) - require.Equal(t, uint64(6), bytesToUint64(res)) - }) -} - -func TestMergeOperatorGetAfterStop(t *testing.T) { - key := []byte("merge") - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - m := db.GetMergeOperator(key, add, 1*time.Second) - - err := m.Add(uint64ToBytes(1)) - require.NoError(t, err) - m.Add(uint64ToBytes(2)) - require.NoError(t, err) - m.Add(uint64ToBytes(3)) - require.NoError(t, err) - - m.Stop() - res, err := m.Get() - require.NoError(t, err) - require.Equal(t, uint64(6), bytesToUint64(res)) - }) -} - -func TestReadOnly(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - opts := getTestOptions(dir) - - // Create the DB - db, err := Open(opts) - require.NoError(t, err) - for i := 0; i < 10000; i++ { - txnSet(t, db, []byte(fmt.Sprintf("key%d", i)), []byte(fmt.Sprintf("value%d", i)), 0x00) - } - - // Attempt a read-only open while it's open read-write. - opts.ReadOnly = true - _, err = Open(opts) - require.Error(t, err) - if err == ErrWindowsNotSupported { - return - } - require.Contains(t, err.Error(), "Another process is using this Badger database") - db.Close() - - // Open one read-only - opts.ReadOnly = true - kv1, err := Open(opts) - require.NoError(t, err) - defer kv1.Close() - - // Open another read-only - kv2, err := Open(opts) - require.NoError(t, err) - defer kv2.Close() - - // Attempt a read-write open while it's open for read-only - opts.ReadOnly = false - _, err = Open(opts) - require.Error(t, err) - require.Contains(t, err.Error(), "Another process is using this Badger database") - - // Get a thing from the DB - txn1 := kv1.NewTransaction(true) - v1, err := txn1.Get([]byte("key1")) - require.NoError(t, err) - b1, err := v1.Value() - require.NoError(t, err) - require.Equal(t, b1, []byte("value1")) - err = txn1.Commit(nil) - require.NoError(t, err) - - // Get a thing from the DB via the other connection - txn2 := kv2.NewTransaction(true) - v2, err := txn2.Get([]byte("key2000")) - require.NoError(t, err) - b2, err := v2.Value() - require.NoError(t, err) - require.Equal(t, b2, []byte("value2000")) - err = txn2.Commit(nil) - require.NoError(t, err) - - // Attempt to set a value on a read-only connection - txn := kv1.NewTransaction(true) - err = txn.SetWithMeta([]byte("key"), []byte("value"), 0x00) - require.Error(t, err) - require.Contains(t, err.Error(), "No sets or deletes are allowed in a read-only transaction") - err = txn.Commit(nil) - require.NoError(t, err) -} - -func TestLSMOnly(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opts := LSMOnlyOptions - opts.Dir = dir - opts.ValueDir = dir - - dopts := DefaultOptions - require.NotEqual(t, dopts.ValueThreshold, opts.ValueThreshold) - require.NotEqual(t, dopts.ValueLogLoadingMode, opts.ValueLogLoadingMode) - require.NotEqual(t, dopts.ValueLogFileSize, opts.ValueLogFileSize) - - dopts.ValueThreshold = 1 << 16 - _, err = Open(dopts) - require.Equal(t, ErrValueThreshold, err) - - db, err := Open(opts) - require.NoError(t, err) - if err != nil { - t.Fatal(err) - } - defer db.Close() - - for i := 0; i < 5000; i++ { - value := make([]byte, 64000) - _, err = rand.Read(value) - require.NoError(t, err) - - txnSet(t, db, []byte(fmt.Sprintf("key%d", i)), value, 0x00) - } - require.NoError(t, db.RunValueLogGC(0.2)) -} - -func TestMinReadTs(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - for i := 0; i < 10; i++ { - require.NoError(t, db.Update(func(txn *Txn) error { - return txn.Set([]byte("x"), []byte("y")) - })) - } - time.Sleep(time.Millisecond) - require.Equal(t, uint64(10), db.orc.readTs()) - min := db.orc.readMark.MinReadTs() - require.Equal(t, uint64(9), min) - - readTxn := db.NewTransaction(false) - for i := 0; i < 10; i++ { - require.NoError(t, db.Update(func(txn *Txn) error { - return txn.Set([]byte("x"), []byte("y")) - })) - } - require.Equal(t, uint64(20), db.orc.readTs()) - time.Sleep(time.Millisecond) - require.Equal(t, min, db.orc.readMark.MinReadTs()) - readTxn.Discard() - time.Sleep(time.Millisecond) - require.Equal(t, uint64(19), db.orc.readMark.MinReadTs()) - - for i := 0; i < 10; i++ { - db.View(func(txn *Txn) error { - return nil - }) - } - time.Sleep(time.Millisecond) - require.Equal(t, uint64(20), db.orc.readMark.MinReadTs()) - }) -} - -func ExampleOpen() { - dir, err := ioutil.TempDir("", "badger") - if err != nil { - log.Fatal(err) - } - defer os.RemoveAll(dir) - opts := DefaultOptions - opts.Dir = dir - opts.ValueDir = dir - db, err := Open(opts) - if err != nil { - log.Fatal(err) - } - defer db.Close() - - err = db.View(func(txn *Txn) error { - _, err := txn.Get([]byte("key")) - // We expect ErrKeyNotFound - fmt.Println(err) - return nil - }) - - if err != nil { - log.Fatal(err) - } - - txn := db.NewTransaction(true) // Read-write txn - err = txn.Set([]byte("key"), []byte("value")) - if err != nil { - log.Fatal(err) - } - err = txn.Commit(nil) - if err != nil { - log.Fatal(err) - } - - err = db.View(func(txn *Txn) error { - item, err := txn.Get([]byte("key")) - if err != nil { - return err - } - val, err := item.Value() - if err != nil { - return err - } - fmt.Printf("%s\n", string(val)) - return nil - }) - - if err != nil { - log.Fatal(err) - } - - // Output: - // Key not found - // value -} - -func ExampleTxn_NewIterator() { - dir, err := ioutil.TempDir("", "badger") - if err != nil { - log.Fatal(err) - } - defer os.RemoveAll(dir) - - opts := DefaultOptions - opts.Dir = dir - opts.ValueDir = dir - - db, err := Open(opts) - if err != nil { - log.Fatal(err) - } - defer db.Close() - - bkey := func(i int) []byte { - return []byte(fmt.Sprintf("%09d", i)) - } - bval := func(i int) []byte { - return []byte(fmt.Sprintf("%025d", i)) - } - - txn := db.NewTransaction(true) - - // Fill in 1000 items - n := 1000 - for i := 0; i < n; i++ { - err := txn.Set(bkey(i), bval(i)) - if err != nil { - log.Fatal(err) - } - } - - err = txn.Commit(nil) - if err != nil { - log.Fatal(err) - } - - opt := DefaultIteratorOptions - opt.PrefetchSize = 10 - - // Iterate over 1000 items - var count int - err = db.View(func(txn *Txn) error { - it := txn.NewIterator(opt) - for it.Rewind(); it.Valid(); it.Next() { - count++ - } - return nil - }) - if err != nil { - log.Fatal(err) - } - fmt.Printf("Counted %d elements", count) - // Output: - // Counted 1000 elements -} diff --git a/vendor/github.com/dgraph-io/badger/dir_unix.go b/vendor/github.com/dgraph-io/badger/dir_unix.go deleted file mode 100644 index a5e0fa3..0000000 --- a/vendor/github.com/dgraph-io/badger/dir_unix.go +++ /dev/null @@ -1,100 +0,0 @@ -// +build !windows - -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "fmt" - "io/ioutil" - "os" - "path/filepath" - - "github.com/pkg/errors" - "golang.org/x/sys/unix" -) - -// directoryLockGuard holds a lock on a directory and a pid file inside. The pid file isn't part -// of the locking mechanism, it's just advisory. -type directoryLockGuard struct { - // File handle on the directory, which we've flocked. - f *os.File - // The absolute path to our pid file. - path string - // Was this a shared lock for a read-only database? - readOnly bool -} - -// acquireDirectoryLock gets a lock on the directory (using flock). If -// this is not read-only, it will also write our pid to -// dirPath/pidFileName for convenience. -func acquireDirectoryLock(dirPath string, pidFileName string, readOnly bool) (*directoryLockGuard, error) { - // Convert to absolute path so that Release still works even if we do an unbalanced - // chdir in the meantime. - absPidFilePath, err := filepath.Abs(filepath.Join(dirPath, pidFileName)) - if err != nil { - return nil, errors.Wrap(err, "cannot get absolute path for pid lock file") - } - f, err := os.Open(dirPath) - if err != nil { - return nil, errors.Wrapf(err, "cannot open directory %q", dirPath) - } - opts := unix.LOCK_EX | unix.LOCK_NB - if readOnly { - opts = unix.LOCK_SH | unix.LOCK_NB - } - - err = unix.Flock(int(f.Fd()), opts) - if err != nil { - f.Close() - return nil, errors.Wrapf(err, - "Cannot acquire directory lock on %q. Another process is using this Badger database.", - dirPath) - } - - if !readOnly { - // Yes, we happily overwrite a pre-existing pid file. We're the - // only read-write badger process using this directory. - err = ioutil.WriteFile(absPidFilePath, []byte(fmt.Sprintf("%d\n", os.Getpid())), 0666) - if err != nil { - f.Close() - return nil, errors.Wrapf(err, - "Cannot write pid file %q", absPidFilePath) - } - } - return &directoryLockGuard{f, absPidFilePath, readOnly}, nil -} - -// Release deletes the pid file and releases our lock on the directory. -func (guard *directoryLockGuard) release() error { - var err error - if !guard.readOnly { - // It's important that we remove the pid file first. - err = os.Remove(guard.path) - } - - if closeErr := guard.f.Close(); err == nil { - err = closeErr - } - guard.path = "" - guard.f = nil - - return err -} - -// openDir opens a directory for syncing. -func openDir(path string) (*os.File, error) { return os.Open(path) } diff --git a/vendor/github.com/dgraph-io/badger/dir_windows.go b/vendor/github.com/dgraph-io/badger/dir_windows.go deleted file mode 100644 index 80de84e..0000000 --- a/vendor/github.com/dgraph-io/badger/dir_windows.go +++ /dev/null @@ -1,94 +0,0 @@ -// +build windows - -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -// OpenDir opens a directory in windows with write access for syncing. -import ( - "fmt" - "os" - "path/filepath" - "syscall" - - "github.com/pkg/errors" -) - -func openDir(path string) (*os.File, error) { - fd, err := openDirWin(path) - if err != nil { - return nil, err - } - return os.NewFile(uintptr(fd), path), nil -} - -func openDirWin(path string) (fd syscall.Handle, err error) { - if len(path) == 0 { - return syscall.InvalidHandle, syscall.ERROR_FILE_NOT_FOUND - } - pathp, err := syscall.UTF16PtrFromString(path) - if err != nil { - return syscall.InvalidHandle, err - } - access := uint32(syscall.GENERIC_READ | syscall.GENERIC_WRITE) - sharemode := uint32(syscall.FILE_SHARE_READ | syscall.FILE_SHARE_WRITE) - createmode := uint32(syscall.OPEN_EXISTING) - fl := uint32(syscall.FILE_FLAG_BACKUP_SEMANTICS) - return syscall.CreateFile(pathp, access, sharemode, nil, createmode, fl, 0) -} - -// DirectoryLockGuard holds a lock on the directory. -type directoryLockGuard struct { - path string -} - -// AcquireDirectoryLock acquires exclusive access to a directory. -func acquireDirectoryLock(dirPath string, pidFileName string, readOnly bool) (*directoryLockGuard, error) { - if readOnly { - return nil, ErrWindowsNotSupported - } - - // Convert to absolute path so that Release still works even if we do an unbalanced - // chdir in the meantime. - absLockFilePath, err := filepath.Abs(filepath.Join(dirPath, pidFileName)) - if err != nil { - return nil, errors.Wrap(err, "Cannot get absolute path for pid lock file") - } - - f, err := os.OpenFile(absLockFilePath, os.O_RDWR|os.O_CREATE|os.O_EXCL, 0666) - if err != nil { - return nil, errors.Wrapf(err, - "Cannot create pid lock file %q. Another process is using this Badger database", - absLockFilePath) - } - _, err = fmt.Fprintf(f, "%d\n", os.Getpid()) - closeErr := f.Close() - if err != nil { - return nil, errors.Wrap(err, "Cannot write to pid lock file") - } - if closeErr != nil { - return nil, errors.Wrap(closeErr, "Cannot close pid lock file") - } - return &directoryLockGuard{path: absLockFilePath}, nil -} - -// Release removes the directory lock. -func (g *directoryLockGuard) release() error { - path := g.path - g.path = "" - return os.Remove(path) -} diff --git a/vendor/github.com/dgraph-io/badger/doc.go b/vendor/github.com/dgraph-io/badger/doc.go deleted file mode 100644 index 83dc9a2..0000000 --- a/vendor/github.com/dgraph-io/badger/doc.go +++ /dev/null @@ -1,28 +0,0 @@ -/* -Package badger implements an embeddable, simple and fast key-value database, -written in pure Go. It is designed to be highly performant for both reads and -writes simultaneously. Badger uses Multi-Version Concurrency Control (MVCC), and -supports transactions. It runs transactions concurrently, with serializable -snapshot isolation guarantees. - -Badger uses an LSM tree along with a value log to separate keys from values, -hence reducing both write amplification and the size of the LSM tree. This -allows LSM tree to be served entirely from RAM, while the values are served -from SSD. - - -Usage - -Badger has the following main types: DB, Txn, Item and Iterator. DB contains -keys that are associated with values. It must be opened with the appropriate -options before it can be accessed. - -All operations happen inside a Txn. Txn represents a transaction, which can -be read-only or read-write. Read-only transactions can read values for a -given key (which are returned inside an Item), or iterate over a set of -key-value pairs using an Iterator (which are returned as Item type values as -well). Read-write transactions can also update and delete keys from the DB. - -See the examples for more usage details. -*/ -package badger diff --git a/vendor/github.com/dgraph-io/badger/errors.go b/vendor/github.com/dgraph-io/badger/errors.go deleted file mode 100644 index c567d3c..0000000 --- a/vendor/github.com/dgraph-io/badger/errors.go +++ /dev/null @@ -1,112 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "encoding/hex" - - "github.com/pkg/errors" -) - -var ( - // ErrValueLogSize is returned when opt.ValueLogFileSize option is not within the valid - // range. - ErrValueLogSize = errors.New("Invalid ValueLogFileSize, must be between 1MB and 2GB") - - // ErrValueThreshold is returned when ValueThreshold is set to a value close to or greater than - // uint16. - ErrValueThreshold = errors.New("Invalid ValueThreshold, must be lower than uint16.") - - // ErrKeyNotFound is returned when key isn't found on a txn.Get. - ErrKeyNotFound = errors.New("Key not found") - - // ErrTxnTooBig is returned if too many writes are fit into a single transaction. - ErrTxnTooBig = errors.New("Txn is too big to fit into one request") - - // ErrConflict is returned when a transaction conflicts with another transaction. This can happen if - // the read rows had been updated concurrently by another transaction. - ErrConflict = errors.New("Transaction Conflict. Please retry") - - // ErrReadOnlyTxn is returned if an update function is called on a read-only transaction. - ErrReadOnlyTxn = errors.New("No sets or deletes are allowed in a read-only transaction") - - // ErrDiscardedTxn is returned if a previously discarded transaction is re-used. - ErrDiscardedTxn = errors.New("This transaction has been discarded. Create a new one") - - // ErrEmptyKey is returned if an empty key is passed on an update function. - ErrEmptyKey = errors.New("Key cannot be empty") - - // ErrRetry is returned when a log file containing the value is not found. - // This usually indicates that it may have been garbage collected, and the - // operation needs to be retried. - ErrRetry = errors.New("Unable to find log file. Please retry") - - // ErrThresholdZero is returned if threshold is set to zero, and value log GC is called. - // In such a case, GC can't be run. - ErrThresholdZero = errors.New( - "Value log GC can't run because threshold is set to zero") - - // ErrNoRewrite is returned if a call for value log GC doesn't result in a log file rewrite. - ErrNoRewrite = errors.New( - "Value log GC attempt didn't result in any cleanup") - - // ErrRejected is returned if a value log GC is called either while another GC is running, or - // after DB::Close has been called. - ErrRejected = errors.New("Value log GC request rejected") - - // ErrInvalidRequest is returned if the user request is invalid. - ErrInvalidRequest = errors.New("Invalid request") - - // ErrManagedTxn is returned if the user tries to use an API which isn't - // allowed due to external management of transactions, when using ManagedDB. - ErrManagedTxn = errors.New( - "Invalid API request. Not allowed to perform this action using ManagedDB") - - // ErrInvalidDump if a data dump made previously cannot be loaded into the database. - ErrInvalidDump = errors.New("Data dump cannot be read") - - // ErrZeroBandwidth is returned if the user passes in zero bandwidth for sequence. - ErrZeroBandwidth = errors.New("Bandwidth must be greater than zero") - - // ErrInvalidLoadingMode is returned when opt.ValueLogLoadingMode option is not - // within the valid range - ErrInvalidLoadingMode = errors.New("Invalid ValueLogLoadingMode, must be FileIO or MemoryMap") - - // ErrReplayNeeded is returned when opt.ReadOnly is set but the - // database requires a value log replay. - ErrReplayNeeded = errors.New("Database was not properly closed, cannot open read-only") - - // ErrWindowsNotSupported is returned when opt.ReadOnly is used on Windows - ErrWindowsNotSupported = errors.New("Read-only mode is not supported on Windows") - - // ErrTruncateNeeded is returned when the value log gets corrupt, and requires truncation of - // corrupt data to allow Badger to run properly. - ErrTruncateNeeded = errors.New("Value log truncate required to run DB. This might result in data loss.") -) - -// Key length can't be more than uint16, as determined by table::header. -const maxKeySize = 1<<16 - 8 // 8 bytes are for storing timestamp - -func exceedsMaxKeySizeError(key []byte) error { - return errors.Errorf("Key with size %d exceeded %d limit. Key:\n%s", - len(key), maxKeySize, hex.Dump(key[:1<<10])) -} - -func exceedsMaxValueSizeError(value []byte, maxValueSize int64) error { - return errors.Errorf("Value with size %d exceeded ValueLogFileSize (%d). Key:\n%s", - len(value), maxValueSize, hex.Dump(value[:1<<10])) -} diff --git a/vendor/github.com/dgraph-io/badger/images/benchmarks-rocksdb.png b/vendor/github.com/dgraph-io/badger/images/benchmarks-rocksdb.png deleted file mode 100644 index 27081e8..0000000 Binary files a/vendor/github.com/dgraph-io/badger/images/benchmarks-rocksdb.png and /dev/null differ diff --git a/vendor/github.com/dgraph-io/badger/images/diggy-shadow.png b/vendor/github.com/dgraph-io/badger/images/diggy-shadow.png deleted file mode 100644 index 19ba3f2..0000000 Binary files a/vendor/github.com/dgraph-io/badger/images/diggy-shadow.png and /dev/null differ diff --git a/vendor/github.com/dgraph-io/badger/images/sketch.jpg b/vendor/github.com/dgraph-io/badger/images/sketch.jpg deleted file mode 100644 index e1ea10e..0000000 Binary files a/vendor/github.com/dgraph-io/badger/images/sketch.jpg and /dev/null differ diff --git a/vendor/github.com/dgraph-io/badger/integration/testgc/.gitignore b/vendor/github.com/dgraph-io/badger/integration/testgc/.gitignore deleted file mode 100644 index f660066..0000000 --- a/vendor/github.com/dgraph-io/badger/integration/testgc/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/testgc diff --git a/vendor/github.com/dgraph-io/badger/integration/testgc/main.go b/vendor/github.com/dgraph-io/badger/integration/testgc/main.go deleted file mode 100644 index b354f94..0000000 --- a/vendor/github.com/dgraph-io/badger/integration/testgc/main.go +++ /dev/null @@ -1,221 +0,0 @@ -package main - -import ( - "encoding/binary" - "fmt" - "log" - "math/rand" - "net/http" - _ "net/http/pprof" - "os" - "sync" - "sync/atomic" - "time" - - "github.com/dgraph-io/badger" - "github.com/dgraph-io/badger/options" - "github.com/dgraph-io/badger/y" -) - -var Max int64 = 10000000 -var suffix = make([]byte, 128) - -type S struct { - sync.Mutex - vals map[uint64]uint64 - - count uint64 // Not under mutex lock. -} - -func encoded(i uint64) []byte { - out := make([]byte, 8) - binary.BigEndian.PutUint64(out, i) - return out -} - -func (s *S) write(db *badger.DB) error { - return db.Update(func(txn *badger.Txn) error { - for i := 0; i < 10; i++ { - // These keys would be overwritten. - keyi := uint64(rand.Int63n(Max)) - key := encoded(keyi) - vali := atomic.AddUint64(&s.count, 1) - val := encoded(vali) - val = append(val, suffix...) - if err := txn.Set(key, val); err != nil { - return err - } - } - for i := 0; i < 20; i++ { - // These keys would be new and never overwritten. - keyi := atomic.AddUint64(&s.count, 1) - if keyi%1000000 == 0 { - log.Printf("Count: %d\n", keyi) - } - key := encoded(keyi) - val := append(key, suffix...) - if err := txn.Set(key, val); err != nil { - return err - } - } - return nil - }) -} - -func (s *S) read(db *badger.DB) error { - max := int64(atomic.LoadUint64(&s.count)) - keyi := uint64(rand.Int63n(max)) - key := encoded(keyi) - - err := db.View(func(txn *badger.Txn) error { - item, err := txn.Get(key) - if err != nil { - return err - } - val, err := item.Value() - if err != nil { - return err - } - y.AssertTruef(len(val) == len(suffix)+8, "Found val of len: %d\n", len(val)) - vali := binary.BigEndian.Uint64(val[0:8]) - s.Lock() - expected := s.vals[keyi] - if vali < expected { - log.Fatalf("Expected: %d. Found: %d. Key: %d\n", expected, vali, keyi) - } else if vali == expected { - // pass - } else { - s.vals[keyi] = vali - } - s.Unlock() - return nil - }) - if err == badger.ErrKeyNotFound { - return nil - } - return err -} - -func main() { - fmt.Println("Badger Integration test for value log GC.") - - // dir, err := ioutil.TempDir("./", "badger") - // if err != nil { - // log.Fatal(err) - // } - dir := "/mnt/drive/badgertest" - os.RemoveAll(dir) - // defer os.RemoveAll(dir) - - opts := badger.DefaultOptions - opts.Dir = dir - opts.ValueDir = dir - opts.TableLoadingMode = options.MemoryMap - opts.ValueLogLoadingMode = options.FileIO - // opts.ValueLogFileSize = 64 << 20 // 64 MB. - opts.SyncWrites = false - - db, err := badger.Open(opts) - if err != nil { - log.Fatal(err) - } - defer db.Close() - - go http.ListenAndServe("localhost:8080", nil) - - closer := y.NewCloser(11) - go func() { - // Run value log GC. - defer closer.Done() - var count int - ticker := time.NewTicker(30 * time.Second) - defer ticker.Stop() - for range ticker.C { - select { - case <-closer.HasBeenClosed(): - log.Printf("Num times value log GC was successful: %d\n", count) - return - default: - } - log.Printf("Starting a value log GC") - err := db.RunValueLogGC(0.1) - log.Printf("Result of value log GC: %v\n", err) - if err == nil { - count++ - } - } - }() - - s := S{ - count: uint64(Max), - vals: make(map[uint64]uint64), - } - var numLoops uint64 - ticker := time.NewTicker(5 * time.Second) - for i := 0; i < 10; i++ { - go func() { - defer closer.Done() - for { - if err := s.write(db); err != nil { - log.Fatal(err) - } - for j := 0; j < 10; j++ { - if err := s.read(db); err != nil { - log.Fatal(err) - } - } - nl := atomic.AddUint64(&numLoops, 1) - select { - case <-closer.HasBeenClosed(): - return - case <-ticker.C: - log.Printf("Num loops: %d\n", nl) - default: - } - } - }() - } - time.Sleep(5 * time.Minute) - log.Println("Signaling...") - closer.SignalAndWait() - log.Println("Wait done. Now iterating over everything.") - - err = db.View(func(txn *badger.Txn) error { - iopts := badger.DefaultIteratorOptions - itr := txn.NewIterator(iopts) - defer itr.Close() - - var total, tested int - for itr.Rewind(); itr.Valid(); itr.Next() { - item := itr.Item() - key := item.Key() - keyi := binary.BigEndian.Uint64(key) - total++ - - val, err := item.Value() - if err != nil { - return err - } - if len(val) < 8 { - log.Printf("Unexpected value: %x\n", val) - continue - } - vali := binary.BigEndian.Uint64(val[0:8]) - - expected, ok := s.vals[keyi] // Not all keys must be in vals map. - if ok { - tested++ - if vali < expected { - // vali must be equal or greater than what's in the map. - log.Fatalf("Expected: %d. Got: %d. Key: %d\n", expected, vali, keyi) - } - } - } - log.Printf("Total iterated: %d. Tested values: %d\n", total, tested) - return nil - }) - if err != nil { - log.Fatalf("Error while iterating: %v", err) - } - log.Println("Iteration done. Test successful.") -} diff --git a/vendor/github.com/dgraph-io/badger/iterator.go b/vendor/github.com/dgraph-io/badger/iterator.go deleted file mode 100644 index 80ac1c0..0000000 --- a/vendor/github.com/dgraph-io/badger/iterator.go +++ /dev/null @@ -1,574 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bytes" - "fmt" - "sync" - "time" - - "github.com/dgraph-io/badger/options" - - "github.com/dgraph-io/badger/y" - farm "github.com/dgryski/go-farm" -) - -type prefetchStatus uint8 - -const ( - prefetched prefetchStatus = iota + 1 -) - -// Item is returned during iteration. Both the Key() and Value() output is only valid until -// iterator.Next() is called. -type Item struct { - status prefetchStatus - err error - wg sync.WaitGroup - db *DB - key []byte - vptr []byte - meta byte // We need to store meta to know about bitValuePointer. - userMeta byte - expiresAt uint64 - val []byte - slice *y.Slice // Used only during prefetching. - next *Item - version uint64 - txn *Txn -} - -// String returns a string representation of Item -func (item *Item) String() string { - return fmt.Sprintf("key=%q, version=%d, meta=%x", item.Key(), item.Version(), item.meta) -} - -// Deprecated -// ToString returns a string representation of Item -func (item *Item) ToString() string { - return item.String() -} - -// Key returns the key. -// -// Key is only valid as long as item is valid, or transaction is valid. If you need to use it -// outside its validity, please use KeyCopy -func (item *Item) Key() []byte { - return item.key -} - -// KeyCopy returns a copy of the key of the item, writing it to dst slice. -// If nil is passed, or capacity of dst isn't sufficient, a new slice would be allocated and -// returned. -func (item *Item) KeyCopy(dst []byte) []byte { - return y.SafeCopy(dst, item.key) -} - -// Version returns the commit timestamp of the item. -func (item *Item) Version() uint64 { - return item.version -} - -// Value retrieves the value of the item from the value log. -// -// This method must be called within a transaction. Calling it outside a -// transaction is considered undefined behavior. If an iterator is being used, -// then Item.Value() is defined in the current iteration only, because items are -// reused. -// -// If you need to use a value outside a transaction, please use Item.ValueCopy -// instead, or copy it yourself. Value might change once discard or commit is called. -// Use ValueCopy if you want to do a Set after Get. -func (item *Item) Value() ([]byte, error) { - item.wg.Wait() - if item.status == prefetched { - return item.val, item.err - } - buf, cb, err := item.yieldItemValue() - if cb != nil { - item.txn.callbacks = append(item.txn.callbacks, cb) - } - return buf, err -} - -// ValueCopy returns a copy of the value of the item from the value log, writing it to dst slice. -// If nil is passed, or capacity of dst isn't sufficient, a new slice would be allocated and -// returned. Tip: It might make sense to reuse the returned slice as dst argument for the next call. -// -// This function is useful in long running iterate/update transactions to avoid a write deadlock. -// See Github issue: https://github.com/dgraph-io/badger/issues/315 -func (item *Item) ValueCopy(dst []byte) ([]byte, error) { - item.wg.Wait() - if item.status == prefetched { - return y.SafeCopy(dst, item.val), item.err - } - buf, cb, err := item.yieldItemValue() - defer runCallback(cb) - return y.SafeCopy(dst, buf), err -} - -func (item *Item) hasValue() bool { - if item.meta == 0 && item.vptr == nil { - // key not found - return false - } - return true -} - -// IsDeletedOrExpired returns true if item contains deleted or expired value. -func (item *Item) IsDeletedOrExpired() bool { - return isDeletedOrExpired(item.meta, item.expiresAt) -} - -func (item *Item) DiscardEarlierVersions() bool { - return item.meta&bitDiscardEarlierVersions > 0 -} - -func (item *Item) yieldItemValue() ([]byte, func(), error) { - if !item.hasValue() { - return nil, nil, nil - } - - if item.slice == nil { - item.slice = new(y.Slice) - } - - if (item.meta & bitValuePointer) == 0 { - val := item.slice.Resize(len(item.vptr)) - copy(val, item.vptr) - return val, nil, nil - } - - var vp valuePointer - vp.Decode(item.vptr) - result, cb, err := item.db.vlog.Read(vp, item.slice) - if err != ErrRetry { - return result, cb, err - } - - // The value pointer is pointing to a deleted value log. Look for the move key and read that - // instead. - runCallback(cb) - key := y.KeyWithTs(item.Key(), item.Version()) - moveKey := append(badgerMove, key...) - vs, err := item.db.get(moveKey) - if err != nil { - return nil, nil, err - } - if vs.Version != item.Version() { - return nil, nil, nil - } - item.vptr = vs.Value - item.meta |= vs.Meta // This meta would only be about value pointer. - return item.yieldItemValue() -} - -func runCallback(cb func()) { - if cb != nil { - cb() - } -} - -func (item *Item) prefetchValue() { - val, cb, err := item.yieldItemValue() - defer runCallback(cb) - - item.err = err - item.status = prefetched - if val == nil { - return - } - if item.db.opt.ValueLogLoadingMode == options.MemoryMap { - buf := item.slice.Resize(len(val)) - copy(buf, val) - item.val = buf - } else { - item.val = val - } -} - -// EstimatedSize returns approximate size of the key-value pair. -// -// This can be called while iterating through a store to quickly estimate the -// size of a range of key-value pairs (without fetching the corresponding -// values). -func (item *Item) EstimatedSize() int64 { - if !item.hasValue() { - return 0 - } - if (item.meta & bitValuePointer) == 0 { - return int64(len(item.key) + len(item.vptr)) - } - var vp valuePointer - vp.Decode(item.vptr) - return int64(vp.Len) // includes key length. -} - -// UserMeta returns the userMeta set by the user. Typically, this byte, optionally set by the user -// is used to interpret the value. -func (item *Item) UserMeta() byte { - return item.userMeta -} - -// ExpiresAt returns a Unix time value indicating when the item will be -// considered expired. 0 indicates that the item will never expire. -func (item *Item) ExpiresAt() uint64 { - return item.expiresAt -} - -// TODO: Switch this to use linked list container in Go. -type list struct { - head *Item - tail *Item -} - -func (l *list) push(i *Item) { - i.next = nil - if l.tail == nil { - l.head = i - l.tail = i - return - } - l.tail.next = i - l.tail = i -} - -func (l *list) pop() *Item { - if l.head == nil { - return nil - } - i := l.head - if l.head == l.tail { - l.tail = nil - l.head = nil - } else { - l.head = i.next - } - i.next = nil - return i -} - -// IteratorOptions is used to set options when iterating over Badger key-value -// stores. -// -// This package provides DefaultIteratorOptions which contains options that -// should work for most applications. Consider using that as a starting point -// before customizing it for your own needs. -type IteratorOptions struct { - // Indicates whether we should prefetch values during iteration and store them. - PrefetchValues bool - // How many KV pairs to prefetch while iterating. Valid only if PrefetchValues is true. - PrefetchSize int - Reverse bool // Direction of iteration. False is forward, true is backward. - AllVersions bool // Fetch all valid versions of the same key. - - internalAccess bool // Used to allow internal access to badger keys. -} - -// DefaultIteratorOptions contains default options when iterating over Badger key-value stores. -var DefaultIteratorOptions = IteratorOptions{ - PrefetchValues: true, - PrefetchSize: 100, - Reverse: false, - AllVersions: false, -} - -// Iterator helps iterating over the KV pairs in a lexicographically sorted order. -type Iterator struct { - iitr *y.MergeIterator - txn *Txn - readTs uint64 - - opt IteratorOptions - item *Item - data list - waste list - - lastKey []byte // Used to skip over multiple versions of the same key. -} - -// NewIterator returns a new iterator. Depending upon the options, either only keys, or both -// key-value pairs would be fetched. The keys are returned in lexicographically sorted order. -// Using prefetch is highly recommended if you're doing a long running iteration. -// Avoid long running iterations in update transactions. -func (txn *Txn) NewIterator(opt IteratorOptions) *Iterator { - tables, decr := txn.db.getMemTables() - defer decr() - txn.db.vlog.incrIteratorCount() - var iters []y.Iterator - if itr := txn.newPendingWritesIterator(opt.Reverse); itr != nil { - iters = append(iters, itr) - } - for i := 0; i < len(tables); i++ { - iters = append(iters, tables[i].NewUniIterator(opt.Reverse)) - } - iters = txn.db.lc.appendIterators(iters, opt.Reverse) // This will increment references. - res := &Iterator{ - txn: txn, - iitr: y.NewMergeIterator(iters, opt.Reverse), - opt: opt, - readTs: txn.readTs, - } - return res -} - -func (it *Iterator) newItem() *Item { - item := it.waste.pop() - if item == nil { - item = &Item{slice: new(y.Slice), db: it.txn.db, txn: it.txn} - } - return item -} - -// Item returns pointer to the current key-value pair. -// This item is only valid until it.Next() gets called. -func (it *Iterator) Item() *Item { - tx := it.txn - if tx.update { - // Track reads if this is an update txn. - tx.reads = append(tx.reads, farm.Fingerprint64(it.item.Key())) - } - return it.item -} - -// Valid returns false when iteration is done. -func (it *Iterator) Valid() bool { return it.item != nil } - -// ValidForPrefix returns false when iteration is done -// or when the current key is not prefixed by the specified prefix. -func (it *Iterator) ValidForPrefix(prefix []byte) bool { - return it.item != nil && bytes.HasPrefix(it.item.key, prefix) -} - -// Close would close the iterator. It is important to call this when you're done with iteration. -func (it *Iterator) Close() { - it.iitr.Close() - - // It is important to wait for the fill goroutines to finish. Otherwise, we might leave zombie - // goroutines behind, which are waiting to acquire file read locks after DB has been closed. - waitFor := func(l list) { - item := l.pop() - for item != nil { - item.wg.Wait() - item = l.pop() - } - } - waitFor(it.waste) - waitFor(it.data) - - // TODO: We could handle this error. - _ = it.txn.db.vlog.decrIteratorCount() -} - -// Next would advance the iterator by one. Always check it.Valid() after a Next() -// to ensure you have access to a valid it.Item(). -func (it *Iterator) Next() { - // Reuse current item - it.item.wg.Wait() // Just cleaner to wait before pushing to avoid doing ref counting. - it.waste.push(it.item) - - // Set next item to current - it.item = it.data.pop() - - for it.iitr.Valid() { - if it.parseItem() { - // parseItem calls one extra next. - // This is used to deal with the complexity of reverse iteration. - break - } - } -} - -func isDeletedOrExpired(meta byte, expiresAt uint64) bool { - if meta&bitDelete > 0 { - return true - } - if expiresAt == 0 { - return false - } - return expiresAt <= uint64(time.Now().Unix()) -} - -// parseItem is a complex function because it needs to handle both forward and reverse iteration -// implementation. We store keys such that their versions are sorted in descending order. This makes -// forward iteration efficient, but revese iteration complicated. This tradeoff is better because -// forward iteration is more common than reverse. -// -// This function advances the iterator. -func (it *Iterator) parseItem() bool { - mi := it.iitr - key := mi.Key() - - setItem := func(item *Item) { - if it.item == nil { - it.item = item - } else { - it.data.push(item) - } - } - - // Skip badger keys. - if !it.opt.internalAccess && bytes.HasPrefix(key, badgerPrefix) { - mi.Next() - return false - } - - // Skip any versions which are beyond the readTs. - version := y.ParseTs(key) - if version > it.readTs { - mi.Next() - return false - } - - if it.opt.AllVersions { - // Return deleted or expired values also, otherwise user can't figure out - // whether the key was deleted. - item := it.newItem() - it.fill(item) - setItem(item) - mi.Next() - return true - } - - // If iterating in forward direction, then just checking the last key against current key would - // be sufficient. - if !it.opt.Reverse { - if y.SameKey(it.lastKey, key) { - mi.Next() - return false - } - // Only track in forward direction. - // We should update lastKey as soon as we find a different key in our snapshot. - // Consider keys: a 5, b 7 (del), b 5. When iterating, lastKey = a. - // Then we see b 7, which is deleted. If we don't store lastKey = b, we'll then return b 5, - // which is wrong. Therefore, update lastKey here. - it.lastKey = y.SafeCopy(it.lastKey, mi.Key()) - } - -FILL: - // If deleted, advance and return. - vs := mi.Value() - if isDeletedOrExpired(vs.Meta, vs.ExpiresAt) { - mi.Next() - return false - } - - item := it.newItem() - it.fill(item) - // fill item based on current cursor position. All Next calls have returned, so reaching here - // means no Next was called. - - mi.Next() // Advance but no fill item yet. - if !it.opt.Reverse || !mi.Valid() { // Forward direction, or invalid. - setItem(item) - return true - } - - // Reverse direction. - nextTs := y.ParseTs(mi.Key()) - mik := y.ParseKey(mi.Key()) - if nextTs <= it.readTs && bytes.Equal(mik, item.key) { - // This is a valid potential candidate. - goto FILL - } - // Ignore the next candidate. Return the current one. - setItem(item) - return true -} - -func (it *Iterator) fill(item *Item) { - vs := it.iitr.Value() - item.meta = vs.Meta - item.userMeta = vs.UserMeta - item.expiresAt = vs.ExpiresAt - - item.version = y.ParseTs(it.iitr.Key()) - item.key = y.SafeCopy(item.key, y.ParseKey(it.iitr.Key())) - - item.vptr = y.SafeCopy(item.vptr, vs.Value) - item.val = nil - if it.opt.PrefetchValues { - item.wg.Add(1) - go func() { - // FIXME we are not handling errors here. - item.prefetchValue() - item.wg.Done() - }() - } -} - -func (it *Iterator) prefetch() { - prefetchSize := 2 - if it.opt.PrefetchValues && it.opt.PrefetchSize > 1 { - prefetchSize = it.opt.PrefetchSize - } - - i := it.iitr - var count int - it.item = nil - for i.Valid() { - if !it.parseItem() { - continue - } - count++ - if count == prefetchSize { - break - } - } -} - -// Seek would seek to the provided key if present. If absent, it would seek to the next smallest key -// greater than provided if iterating in the forward direction. Behavior would be reversed is -// iterating backwards. -func (it *Iterator) Seek(key []byte) { - for i := it.data.pop(); i != nil; i = it.data.pop() { - i.wg.Wait() - it.waste.push(i) - } - - it.lastKey = it.lastKey[:0] - if len(key) == 0 { - it.iitr.Rewind() - it.prefetch() - return - } - - if !it.opt.Reverse { - key = y.KeyWithTs(key, it.txn.readTs) - } else { - key = y.KeyWithTs(key, 0) - } - it.iitr.Seek(key) - it.prefetch() -} - -// Rewind would rewind the iterator cursor all the way to zero-th position, which would be the -// smallest key if iterating forward, and largest if iterating backward. It does not keep track of -// whether the cursor started with a Seek(). -func (it *Iterator) Rewind() { - i := it.data.pop() - for i != nil { - i.wg.Wait() // Just cleaner to wait before pushing. No ref counting needed. - it.waste.push(i) - i = it.data.pop() - } - - it.lastKey = it.lastKey[:0] - it.iitr.Rewind() - it.prefetch() -} diff --git a/vendor/github.com/dgraph-io/badger/level_handler.go b/vendor/github.com/dgraph-io/badger/level_handler.go deleted file mode 100644 index d7295c4..0000000 --- a/vendor/github.com/dgraph-io/badger/level_handler.go +++ /dev/null @@ -1,294 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "fmt" - "sort" - "sync" - - "github.com/dgraph-io/badger/table" - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" -) - -type levelHandler struct { - // Guards tables, totalSize. - sync.RWMutex - - // For level >= 1, tables are sorted by key ranges, which do not overlap. - // For level 0, tables are sorted by time. - // For level 0, newest table are at the back. Compact the oldest one first, which is at the front. - tables []*table.Table - totalSize int64 - - // The following are initialized once and const. - level int - strLevel string - maxTotalSize int64 - db *DB -} - -func (s *levelHandler) getTotalSize() int64 { - s.RLock() - defer s.RUnlock() - return s.totalSize -} - -// initTables replaces s.tables with given tables. This is done during loading. -func (s *levelHandler) initTables(tables []*table.Table) { - s.Lock() - defer s.Unlock() - - s.tables = tables - s.totalSize = 0 - for _, t := range tables { - s.totalSize += t.Size() - } - - if s.level == 0 { - // Key range will overlap. Just sort by fileID in ascending order - // because newer tables are at the end of level 0. - sort.Slice(s.tables, func(i, j int) bool { - return s.tables[i].ID() < s.tables[j].ID() - }) - } else { - // Sort tables by keys. - sort.Slice(s.tables, func(i, j int) bool { - return y.CompareKeys(s.tables[i].Smallest(), s.tables[j].Smallest()) < 0 - }) - } -} - -// deleteTables remove tables idx0, ..., idx1-1. -func (s *levelHandler) deleteTables(toDel []*table.Table) error { - s.Lock() // s.Unlock() below - - toDelMap := make(map[uint64]struct{}) - for _, t := range toDel { - toDelMap[t.ID()] = struct{}{} - } - - // Make a copy as iterators might be keeping a slice of tables. - var newTables []*table.Table - for _, t := range s.tables { - _, found := toDelMap[t.ID()] - if !found { - newTables = append(newTables, t) - continue - } - s.totalSize -= t.Size() - } - s.tables = newTables - - s.Unlock() // Unlock s _before_ we DecrRef our tables, which can be slow. - - return decrRefs(toDel) -} - -// replaceTables will replace tables[left:right] with newTables. Note this EXCLUDES tables[right]. -// You must call decr() to delete the old tables _after_ writing the update to the manifest. -func (s *levelHandler) replaceTables(newTables []*table.Table) error { - // Need to re-search the range of tables in this level to be replaced as other goroutines might - // be changing it as well. (They can't touch our tables, but if they add/remove other tables, - // the indices get shifted around.) - if len(newTables) == 0 { - return nil - } - - s.Lock() // We s.Unlock() below. - - // Increase totalSize first. - for _, tbl := range newTables { - s.totalSize += tbl.Size() - tbl.IncrRef() - } - - kr := keyRange{ - left: newTables[0].Smallest(), - right: newTables[len(newTables)-1].Biggest(), - } - left, right := s.overlappingTables(levelHandlerRLocked{}, kr) - - toDecr := make([]*table.Table, right-left) - // Update totalSize and reference counts. - for i := left; i < right; i++ { - tbl := s.tables[i] - s.totalSize -= tbl.Size() - toDecr[i-left] = tbl - } - - // To be safe, just make a copy. TODO: Be more careful and avoid copying. - numDeleted := right - left - numAdded := len(newTables) - tables := make([]*table.Table, len(s.tables)-numDeleted+numAdded) - y.AssertTrue(left == copy(tables, s.tables[:left])) - t := tables[left:] - y.AssertTrue(numAdded == copy(t, newTables)) - t = t[numAdded:] - y.AssertTrue(len(s.tables[right:]) == copy(t, s.tables[right:])) - s.tables = tables - s.Unlock() // s.Unlock before we DecrRef tables -- that can be slow. - return decrRefs(toDecr) -} - -func decrRefs(tables []*table.Table) error { - for _, table := range tables { - if err := table.DecrRef(); err != nil { - return err - } - } - return nil -} - -func newLevelHandler(db *DB, level int) *levelHandler { - return &levelHandler{ - level: level, - strLevel: fmt.Sprintf("l%d", level), - db: db, - } -} - -// tryAddLevel0Table returns true if ok and no stalling. -func (s *levelHandler) tryAddLevel0Table(t *table.Table) bool { - y.AssertTrue(s.level == 0) - // Need lock as we may be deleting the first table during a level 0 compaction. - s.Lock() - defer s.Unlock() - if len(s.tables) >= s.db.opt.NumLevelZeroTablesStall { - return false - } - - s.tables = append(s.tables, t) - t.IncrRef() - s.totalSize += t.Size() - - return true -} - -func (s *levelHandler) numTables() int { - s.RLock() - defer s.RUnlock() - return len(s.tables) -} - -func (s *levelHandler) close() error { - s.RLock() - defer s.RUnlock() - var err error - for _, t := range s.tables { - if closeErr := t.Close(); closeErr != nil && err == nil { - err = closeErr - } - } - return errors.Wrap(err, "levelHandler.close") -} - -// getTableForKey acquires a read-lock to access s.tables. It returns a list of tableHandlers. -func (s *levelHandler) getTableForKey(key []byte) ([]*table.Table, func() error) { - s.RLock() - defer s.RUnlock() - - if s.level == 0 { - // For level 0, we need to check every table. Remember to make a copy as s.tables may change - // once we exit this function, and we don't want to lock s.tables while seeking in tables. - // CAUTION: Reverse the tables. - out := make([]*table.Table, 0, len(s.tables)) - for i := len(s.tables) - 1; i >= 0; i-- { - out = append(out, s.tables[i]) - s.tables[i].IncrRef() - } - return out, func() error { - for _, t := range out { - if err := t.DecrRef(); err != nil { - return err - } - } - return nil - } - } - // For level >= 1, we can do a binary search as key range does not overlap. - idx := sort.Search(len(s.tables), func(i int) bool { - return y.CompareKeys(s.tables[i].Biggest(), key) >= 0 - }) - if idx >= len(s.tables) { - // Given key is strictly > than every element we have. - return nil, func() error { return nil } - } - tbl := s.tables[idx] - tbl.IncrRef() - return []*table.Table{tbl}, tbl.DecrRef -} - -// get returns value for a given key or the key after that. If not found, return nil. -func (s *levelHandler) get(key []byte) (y.ValueStruct, error) { - tables, decr := s.getTableForKey(key) - keyNoTs := y.ParseKey(key) - - var maxVs y.ValueStruct - for _, th := range tables { - if th.DoesNotHave(keyNoTs) { - y.NumLSMBloomHits.Add(s.strLevel, 1) - continue - } - - it := th.NewIterator(false) - defer it.Close() - - y.NumLSMGets.Add(s.strLevel, 1) - it.Seek(key) - if !it.Valid() { - continue - } - if y.SameKey(key, it.Key()) { - if version := y.ParseTs(it.Key()); maxVs.Version < version { - maxVs = it.Value() - maxVs.Version = version - } - } - } - return maxVs, decr() -} - -// appendIterators appends iterators to an array of iterators, for merging. -// Note: This obtains references for the table handlers. Remember to close these iterators. -func (s *levelHandler) appendIterators(iters []y.Iterator, reversed bool) []y.Iterator { - s.RLock() - defer s.RUnlock() - - if s.level == 0 { - // Remember to add in reverse order! - // The newer table at the end of s.tables should be added first as it takes precedence. - return appendIteratorsReversed(iters, s.tables, reversed) - } - return append(iters, table.NewConcatIterator(s.tables, reversed)) -} - -type levelHandlerRLocked struct{} - -// overlappingTables returns the tables that intersect with key range. Returns a half-interval. -// This function should already have acquired a read lock, and this is so important the caller must -// pass an empty parameter declaring such. -func (s *levelHandler) overlappingTables(_ levelHandlerRLocked, kr keyRange) (int, int) { - left := sort.Search(len(s.tables), func(i int) bool { - return y.CompareKeys(kr.left, s.tables[i].Biggest()) <= 0 - }) - right := sort.Search(len(s.tables), func(i int) bool { - return y.CompareKeys(kr.right, s.tables[i].Smallest()) < 0 - }) - return left, right -} diff --git a/vendor/github.com/dgraph-io/badger/levels.go b/vendor/github.com/dgraph-io/badger/levels.go deleted file mode 100644 index e7f01d2..0000000 --- a/vendor/github.com/dgraph-io/badger/levels.go +++ /dev/null @@ -1,785 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "fmt" - "math" - "math/rand" - "os" - "sort" - "time" - - "golang.org/x/net/trace" - - "github.com/dgraph-io/badger/protos" - "github.com/dgraph-io/badger/table" - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" -) - -type levelsController struct { - nextFileID uint64 // Atomic - elog trace.EventLog - - // The following are initialized once and const. - levels []*levelHandler - kv *DB - - cstatus compactStatus -} - -var ( - // This is for getting timings between stalls. - lastUnstalled time.Time -) - -// revertToManifest checks that all necessary table files exist and removes all table files not -// referenced by the manifest. idMap is a set of table file id's that were read from the directory -// listing. -func revertToManifest(kv *DB, mf *Manifest, idMap map[uint64]struct{}) error { - // 1. Check all files in manifest exist. - for id := range mf.Tables { - if _, ok := idMap[id]; !ok { - return fmt.Errorf("file does not exist for table %d", id) - } - } - - // 2. Delete files that shouldn't exist. - for id := range idMap { - if _, ok := mf.Tables[id]; !ok { - kv.elog.Printf("Table file %d not referenced in MANIFEST\n", id) - filename := table.NewFilename(id, kv.opt.Dir) - if err := os.Remove(filename); err != nil { - return y.Wrapf(err, "While removing table %d", id) - } - } - } - - return nil -} - -func newLevelsController(kv *DB, mf *Manifest) (*levelsController, error) { - y.AssertTrue(kv.opt.NumLevelZeroTablesStall > kv.opt.NumLevelZeroTables) - s := &levelsController{ - kv: kv, - elog: kv.elog, - levels: make([]*levelHandler, kv.opt.MaxLevels), - } - s.cstatus.levels = make([]*levelCompactStatus, kv.opt.MaxLevels) - - for i := 0; i < kv.opt.MaxLevels; i++ { - s.levels[i] = newLevelHandler(kv, i) - if i == 0 { - // Do nothing. - } else if i == 1 { - // Level 1 probably shouldn't be too much bigger than level 0. - s.levels[i].maxTotalSize = kv.opt.LevelOneSize - } else { - s.levels[i].maxTotalSize = s.levels[i-1].maxTotalSize * int64(kv.opt.LevelSizeMultiplier) - } - s.cstatus.levels[i] = new(levelCompactStatus) - } - - // Compare manifest against directory, check for existent/non-existent files, and remove. - if err := revertToManifest(kv, mf, getIDMap(kv.opt.Dir)); err != nil { - return nil, err - } - - // Some files may be deleted. Let's reload. - tables := make([][]*table.Table, kv.opt.MaxLevels) - var maxFileID uint64 - for fileID, tableManifest := range mf.Tables { - fname := table.NewFilename(fileID, kv.opt.Dir) - var flags uint32 = y.Sync - if kv.opt.ReadOnly { - flags |= y.ReadOnly - } - fd, err := y.OpenExistingFile(fname, flags) - if err != nil { - closeAllTables(tables) - return nil, errors.Wrapf(err, "Opening file: %q", fname) - } - - t, err := table.OpenTable(fd, kv.opt.TableLoadingMode) - if err != nil { - closeAllTables(tables) - return nil, errors.Wrapf(err, "Opening table: %q", fname) - } - - level := tableManifest.Level - tables[level] = append(tables[level], t) - - if fileID > maxFileID { - maxFileID = fileID - } - } - s.nextFileID = maxFileID + 1 - for i, tbls := range tables { - s.levels[i].initTables(tbls) - } - - // Make sure key ranges do not overlap etc. - if err := s.validate(); err != nil { - _ = s.cleanupLevels() - return nil, errors.Wrap(err, "Level validation") - } - - // Sync directory (because we have at least removed some files, or previously created the - // manifest file). - if err := syncDir(kv.opt.Dir); err != nil { - _ = s.close() - return nil, err - } - - return s, nil -} - -// Closes the tables, for cleanup in newLevelsController. (We Close() instead of using DecrRef() -// because that would delete the underlying files.) We ignore errors, which is OK because tables -// are read-only. -func closeAllTables(tables [][]*table.Table) { - for _, tableSlice := range tables { - for _, table := range tableSlice { - _ = table.Close() - } - } -} - -func (s *levelsController) cleanupLevels() error { - var firstErr error - for _, l := range s.levels { - if err := l.close(); err != nil && firstErr == nil { - firstErr = err - } - } - return firstErr -} - -func (s *levelsController) startCompact(lc *y.Closer) { - n := s.kv.opt.NumCompactors - lc.AddRunning(n - 1) - for i := 0; i < n; i++ { - go s.runWorker(lc) - } -} - -func (s *levelsController) runWorker(lc *y.Closer) { - defer lc.Done() - if s.kv.opt.DoNotCompact { - return - } - - time.Sleep(time.Duration(rand.Int31n(1000)) * time.Millisecond) - ticker := time.NewTicker(time.Second) - defer ticker.Stop() - - for { - select { - // Can add a done channel or other stuff. - case <-ticker.C: - prios := s.pickCompactLevels() - for _, p := range prios { - // TODO: Handle error. - didCompact, _ := s.doCompact(p) - if didCompact { - break - } - } - case <-lc.HasBeenClosed(): - return - } - } -} - -// Returns true if level zero may be compacted, without accounting for compactions that already -// might be happening. -func (s *levelsController) isLevel0Compactable() bool { - return s.levels[0].numTables() >= s.kv.opt.NumLevelZeroTables -} - -// Returns true if the non-zero level may be compacted. delSize provides the size of the tables -// which are currently being compacted so that we treat them as already having started being -// compacted (because they have been, yet their size is already counted in getTotalSize). -func (l *levelHandler) isCompactable(delSize int64) bool { - return l.getTotalSize()-delSize >= l.maxTotalSize -} - -type compactionPriority struct { - level int - score float64 -} - -// pickCompactLevel determines which level to compact. -// Based on: https://github.com/facebook/rocksdb/wiki/Leveled-Compaction -func (s *levelsController) pickCompactLevels() (prios []compactionPriority) { - // This function must use identical criteria for guaranteeing compaction's progress that - // addLevel0Table uses. - - // cstatus is checked to see if level 0's tables are already being compacted - if !s.cstatus.overlapsWith(0, infRange) && s.isLevel0Compactable() { - pri := compactionPriority{ - level: 0, - score: float64(s.levels[0].numTables()) / float64(s.kv.opt.NumLevelZeroTables), - } - prios = append(prios, pri) - } - - for i, l := range s.levels[1:] { - // Don't consider those tables that are already being compacted right now. - delSize := s.cstatus.delSize(i + 1) - - if l.isCompactable(delSize) { - pri := compactionPriority{ - level: i + 1, - score: float64(l.getTotalSize()-delSize) / float64(l.maxTotalSize), - } - prios = append(prios, pri) - } - } - sort.Slice(prios, func(i, j int) bool { - return prios[i].score > prios[j].score - }) - return prios -} - -// compactBuildTables merge topTables and botTables to form a list of new tables. -func (s *levelsController) compactBuildTables( - l int, cd compactDef) ([]*table.Table, func() error, error) { - topTables := cd.top - botTables := cd.bot - - var hasOverlap bool - { - kr := getKeyRange(cd.top) - for i, lh := range s.levels { - if i <= l { // Skip upper levels. - continue - } - lh.RLock() - left, right := lh.overlappingTables(levelHandlerRLocked{}, kr) - lh.RUnlock() - if right-left > 0 { - hasOverlap = true - break - } - } - cd.elog.LazyPrintf("Key range overlaps with lower levels: %v", hasOverlap) - } - - // Try to collect stats so that we can inform value log about GC. That would help us find which - // value log file should be GCed. - discardStats := make(map[uint32]int64) - updateStats := func(vs y.ValueStruct) { - if vs.Meta&bitValuePointer > 0 { - var vp valuePointer - vp.Decode(vs.Value) - discardStats[vp.Fid] += int64(vp.Len) - } - } - - // Create iterators across all the tables involved first. - var iters []y.Iterator - if l == 0 { - iters = appendIteratorsReversed(iters, topTables, false) - } else { - y.AssertTrue(len(topTables) == 1) - iters = []y.Iterator{topTables[0].NewIterator(false)} - } - - // Next level has level>=1 and we can use ConcatIterator as key ranges do not overlap. - iters = append(iters, table.NewConcatIterator(botTables, false)) - it := y.NewMergeIterator(iters, false) - defer it.Close() // Important to close the iterator to do ref counting. - - it.Rewind() - - // Pick up the currently pending transactions' min readTs, so we can discard versions below this - // readTs. We should never discard any versions starting from above this timestamp, because that - // would affect the snapshot view guarantee provided by transactions. - minReadTs := s.kv.orc.readMark.MinReadTs() - - // Start generating new tables. - type newTableResult struct { - table *table.Table - err error - } - resultCh := make(chan newTableResult) - var numBuilds, numVersions int - var lastKey, skipKey []byte - for it.Valid() { - timeStart := time.Now() - builder := table.NewTableBuilder() - var numKeys, numSkips uint64 - for ; it.Valid(); it.Next() { - // See if we need to skip this key. - if len(skipKey) > 0 { - if y.SameKey(it.Key(), skipKey) { - numSkips++ - updateStats(it.Value()) - continue - } else { - skipKey = skipKey[:0] - } - } - - if !y.SameKey(it.Key(), lastKey) { - if builder.ReachedCapacity(s.kv.opt.MaxTableSize) { - // Only break if we are on a different key, and have reached capacity. We want - // to ensure that all versions of the key are stored in the same sstable, and - // not divided across multiple tables at the same level. - break - } - lastKey = y.SafeCopy(lastKey, it.Key()) - numVersions = 0 - } - - vs := it.Value() - version := y.ParseTs(it.Key()) - if version <= minReadTs { - // Keep track of the number of versions encountered for this key. Only consider the - // versions which are below the minReadTs, otherwise, we might end up discarding the - // only valid version for a running transaction. - numVersions++ - lastValidVersion := vs.Meta&bitDiscardEarlierVersions > 0 - if isDeletedOrExpired(vs.Meta, vs.ExpiresAt) || - numVersions > s.kv.opt.NumVersionsToKeep || - lastValidVersion { - // If this version of the key is deleted or expired, skip all the rest of the - // versions. Ensure that we're only removing versions below readTs. - skipKey = y.SafeCopy(skipKey, it.Key()) - - if lastValidVersion { - // Add this key. We have set skipKey, so the following key versions - // would be skipped. - } else if hasOverlap { - // If this key range has overlap with lower levels, then keep the deletion - // marker with the latest version, discarding the rest. We have set skipKey, - // so the following key versions would be skipped. - } else { - // If no overlap, we can skip all the versions, by continuing here. - numSkips++ - updateStats(vs) - continue // Skip adding this key. - } - } - } - numKeys++ - y.Check(builder.Add(it.Key(), it.Value())) - } - // It was true that it.Valid() at least once in the loop above, which means we - // called Add() at least once, and builder is not Empty(). - cd.elog.LazyPrintf("Added %d keys. Skipped %d keys.", numKeys, numSkips) - cd.elog.LazyPrintf("LOG Compact. Iteration took: %v\n", time.Since(timeStart)) - if !builder.Empty() { - numBuilds++ - fileID := s.reserveFileID() - go func(builder *table.Builder) { - defer builder.Close() - - fd, err := y.CreateSyncedFile(table.NewFilename(fileID, s.kv.opt.Dir), true) - if err != nil { - resultCh <- newTableResult{nil, errors.Wrapf(err, "While opening new table: %d", fileID)} - return - } - - if _, err := fd.Write(builder.Finish()); err != nil { - resultCh <- newTableResult{nil, errors.Wrapf(err, "Unable to write to file: %d", fileID)} - return - } - - tbl, err := table.OpenTable(fd, s.kv.opt.TableLoadingMode) - // decrRef is added below. - resultCh <- newTableResult{tbl, errors.Wrapf(err, "Unable to open table: %q", fd.Name())} - }(builder) - } - } - - newTables := make([]*table.Table, 0, 20) - // Wait for all table builders to finish. - var firstErr error - for x := 0; x < numBuilds; x++ { - res := <-resultCh - newTables = append(newTables, res.table) - if firstErr == nil { - firstErr = res.err - } - } - - if firstErr == nil { - // Ensure created files' directory entries are visible. We don't mind the extra latency - // from not doing this ASAP after all file creation has finished because this is a - // background operation. - firstErr = syncDir(s.kv.opt.Dir) - } - - if firstErr != nil { - // An error happened. Delete all the newly created table files (by calling DecrRef - // -- we're the only holders of a ref). - for j := 0; j < numBuilds; j++ { - if newTables[j] != nil { - newTables[j].DecrRef() - } - } - errorReturn := errors.Wrapf(firstErr, "While running compaction for: %+v", cd) - return nil, nil, errorReturn - } - - sort.Slice(newTables, func(i, j int) bool { - return y.CompareKeys(newTables[i].Biggest(), newTables[j].Biggest()) < 0 - }) - s.kv.vlog.updateGCStats(discardStats) - cd.elog.LazyPrintf("Discard stats: %v", discardStats) - return newTables, func() error { return decrRefs(newTables) }, nil -} - -func buildChangeSet(cd *compactDef, newTables []*table.Table) protos.ManifestChangeSet { - changes := []*protos.ManifestChange{} - for _, table := range newTables { - changes = append(changes, makeTableCreateChange(table.ID(), cd.nextLevel.level)) - } - for _, table := range cd.top { - changes = append(changes, makeTableDeleteChange(table.ID())) - } - for _, table := range cd.bot { - changes = append(changes, makeTableDeleteChange(table.ID())) - } - return protos.ManifestChangeSet{Changes: changes} -} - -type compactDef struct { - elog trace.Trace - - thisLevel *levelHandler - nextLevel *levelHandler - - top []*table.Table - bot []*table.Table - - thisRange keyRange - nextRange keyRange - - thisSize int64 -} - -func (cd *compactDef) lockLevels() { - cd.thisLevel.RLock() - cd.nextLevel.RLock() -} - -func (cd *compactDef) unlockLevels() { - cd.nextLevel.RUnlock() - cd.thisLevel.RUnlock() -} - -func (s *levelsController) fillTablesL0(cd *compactDef) bool { - cd.lockLevels() - defer cd.unlockLevels() - - cd.top = make([]*table.Table, len(cd.thisLevel.tables)) - copy(cd.top, cd.thisLevel.tables) - if len(cd.top) == 0 { - return false - } - cd.thisRange = infRange - - kr := getKeyRange(cd.top) - left, right := cd.nextLevel.overlappingTables(levelHandlerRLocked{}, kr) - cd.bot = make([]*table.Table, right-left) - copy(cd.bot, cd.nextLevel.tables[left:right]) - - if len(cd.bot) == 0 { - cd.nextRange = kr - } else { - cd.nextRange = getKeyRange(cd.bot) - } - - if !s.cstatus.compareAndAdd(thisAndNextLevelRLocked{}, *cd) { - return false - } - - return true -} - -func (s *levelsController) fillTables(cd *compactDef) bool { - cd.lockLevels() - defer cd.unlockLevels() - - tbls := make([]*table.Table, len(cd.thisLevel.tables)) - copy(tbls, cd.thisLevel.tables) - if len(tbls) == 0 { - return false - } - - // Find the biggest table, and compact that first. - // TODO: Try other table picking strategies. - sort.Slice(tbls, func(i, j int) bool { - return tbls[i].Size() > tbls[j].Size() - }) - - for _, t := range tbls { - cd.thisSize = t.Size() - cd.thisRange = keyRange{ - // We pick all the versions of the smallest and the biggest key. - left: y.KeyWithTs(y.ParseKey(t.Smallest()), math.MaxUint64), - // Note that version zero would be the rightmost key. - right: y.KeyWithTs(y.ParseKey(t.Biggest()), 0), - } - if s.cstatus.overlapsWith(cd.thisLevel.level, cd.thisRange) { - continue - } - cd.top = []*table.Table{t} - left, right := cd.nextLevel.overlappingTables(levelHandlerRLocked{}, cd.thisRange) - - cd.bot = make([]*table.Table, right-left) - copy(cd.bot, cd.nextLevel.tables[left:right]) - - if len(cd.bot) == 0 { - cd.bot = []*table.Table{} - cd.nextRange = cd.thisRange - if !s.cstatus.compareAndAdd(thisAndNextLevelRLocked{}, *cd) { - continue - } - return true - } - cd.nextRange = getKeyRange(cd.bot) - - if s.cstatus.overlapsWith(cd.nextLevel.level, cd.nextRange) { - continue - } - - if !s.cstatus.compareAndAdd(thisAndNextLevelRLocked{}, *cd) { - continue - } - return true - } - return false -} - -func (s *levelsController) runCompactDef(l int, cd compactDef) (err error) { - timeStart := time.Now() - - thisLevel := cd.thisLevel - nextLevel := cd.nextLevel - - // Table should never be moved directly between levels, always be rewritten to allow discarding - // invalid versions. - - newTables, decr, err := s.compactBuildTables(l, cd) - if err != nil { - return err - } - defer func() { - // Only assign to err, if it's not already nil. - if decErr := decr(); err == nil { - err = decErr - } - }() - changeSet := buildChangeSet(&cd, newTables) - - // We write to the manifest _before_ we delete files (and after we created files) - if err := s.kv.manifest.addChanges(changeSet.Changes); err != nil { - return err - } - - // See comment earlier in this function about the ordering of these ops, and the order in which - // we access levels when reading. - if err := nextLevel.replaceTables(newTables); err != nil { - return err - } - if err := thisLevel.deleteTables(cd.top); err != nil { - return err - } - - // Note: For level 0, while doCompact is running, it is possible that new tables are added. - // However, the tables are added only to the end, so it is ok to just delete the first table. - - cd.elog.LazyPrintf("LOG Compact %d->%d, del %d tables, add %d tables, took %v\n", - l, l+1, len(cd.top)+len(cd.bot), len(newTables), time.Since(timeStart)) - return nil -} - -// doCompact picks some table on level l and compacts it away to the next level. -func (s *levelsController) doCompact(p compactionPriority) (bool, error) { - l := p.level - y.AssertTrue(l+1 < s.kv.opt.MaxLevels) // Sanity check. - - cd := compactDef{ - elog: trace.New(fmt.Sprintf("Badger.L%d", l), "Compact"), - thisLevel: s.levels[l], - nextLevel: s.levels[l+1], - } - cd.elog.SetMaxEvents(100) - defer cd.elog.Finish() - - cd.elog.LazyPrintf("Got compaction priority: %+v", p) - - // While picking tables to be compacted, both levels' tables are expected to - // remain unchanged. - if l == 0 { - if !s.fillTablesL0(&cd) { - cd.elog.LazyPrintf("fillTables failed for level: %d\n", l) - return false, nil - } - - } else { - if !s.fillTables(&cd) { - cd.elog.LazyPrintf("fillTables failed for level: %d\n", l) - return false, nil - } - } - defer s.cstatus.delete(cd) // Remove the ranges from compaction status. - - cd.elog.LazyPrintf("Running for level: %d\n", cd.thisLevel.level) - s.cstatus.toLog(cd.elog) - if err := s.runCompactDef(l, cd); err != nil { - // This compaction couldn't be done successfully. - cd.elog.LazyPrintf("\tLOG Compact FAILED with error: %+v: %+v", err, cd) - return false, err - } - - s.cstatus.toLog(cd.elog) - cd.elog.LazyPrintf("Compaction for level: %d DONE", cd.thisLevel.level) - return true, nil -} - -func (s *levelsController) addLevel0Table(t *table.Table) error { - // We update the manifest _before_ the table becomes part of a levelHandler, because at that - // point it could get used in some compaction. This ensures the manifest file gets updated in - // the proper order. (That means this update happens before that of some compaction which - // deletes the table.) - err := s.kv.manifest.addChanges([]*protos.ManifestChange{ - makeTableCreateChange(t.ID(), 0), - }) - if err != nil { - return err - } - - for !s.levels[0].tryAddLevel0Table(t) { - // Stall. Make sure all levels are healthy before we unstall. - var timeStart time.Time - { - s.elog.Printf("STALLED STALLED STALLED STALLED STALLED STALLED STALLED STALLED: %v\n", - time.Since(lastUnstalled)) - s.cstatus.RLock() - for i := 0; i < s.kv.opt.MaxLevels; i++ { - s.elog.Printf("level=%d. Status=%s Size=%d\n", - i, s.cstatus.levels[i].debug(), s.levels[i].getTotalSize()) - } - s.cstatus.RUnlock() - timeStart = time.Now() - } - // Before we unstall, we need to make sure that level 0 and 1 are healthy. Otherwise, we - // will very quickly fill up level 0 again and if the compaction strategy favors level 0, - // then level 1 is going to super full. - for i := 0; ; i++ { - // Passing 0 for delSize to compactable means we're treating incomplete compactions as - // not having finished -- we wait for them to finish. Also, it's crucial this behavior - // replicates pickCompactLevels' behavior in computing compactability in order to - // guarantee progress. - if !s.isLevel0Compactable() && !s.levels[1].isCompactable(0) { - break - } - time.Sleep(10 * time.Millisecond) - if i%100 == 0 { - prios := s.pickCompactLevels() - s.elog.Printf("Waiting to add level 0 table. Compaction priorities: %+v\n", prios) - i = 0 - } - } - { - s.elog.Printf("UNSTALLED UNSTALLED UNSTALLED UNSTALLED UNSTALLED UNSTALLED: %v\n", - time.Since(timeStart)) - lastUnstalled = time.Now() - } - } - - return nil -} - -func (s *levelsController) close() error { - err := s.cleanupLevels() - return errors.Wrap(err, "levelsController.Close") -} - -// get returns the found value if any. If not found, we return nil. -func (s *levelsController) get(key []byte) (y.ValueStruct, error) { - // It's important that we iterate the levels from 0 on upward. The reason is, if we iterated - // in opposite order, or in parallel (naively calling all the h.RLock() in some order) we could - // read level L's tables post-compaction and level L+1's tables pre-compaction. (If we do - // parallelize this, we will need to call the h.RLock() function by increasing order of level - // number.) - for _, h := range s.levels { - vs, err := h.get(key) // Calls h.RLock() and h.RUnlock(). - if err != nil { - return y.ValueStruct{}, errors.Wrapf(err, "get key: %q", key) - } - if vs.Value == nil && vs.Meta == 0 { - continue - } - return vs, nil - } - return y.ValueStruct{}, nil -} - -func appendIteratorsReversed(out []y.Iterator, th []*table.Table, reversed bool) []y.Iterator { - for i := len(th) - 1; i >= 0; i-- { - // This will increment the reference of the table handler. - out = append(out, th[i].NewIterator(reversed)) - } - return out -} - -// appendIterators appends iterators to an array of iterators, for merging. -// Note: This obtains references for the table handlers. Remember to close these iterators. -func (s *levelsController) appendIterators( - iters []y.Iterator, reversed bool) []y.Iterator { - // Just like with get, it's important we iterate the levels from 0 on upward, to avoid missing - // data when there's a compaction. - for _, level := range s.levels { - iters = level.appendIterators(iters, reversed) - } - return iters -} - -type TableInfo struct { - ID uint64 - Level int - Left []byte - Right []byte -} - -func (s *levelsController) getTableInfo() (result []TableInfo) { - for _, l := range s.levels { - for _, t := range l.tables { - info := TableInfo{ - ID: t.ID(), - Level: l.level, - Left: t.Smallest(), - Right: t.Biggest(), - } - result = append(result, info) - } - } - sort.Slice(result, func(i, j int) bool { - if result[i].Level != result[j].Level { - return result[i].Level < result[j].Level - } - return result[i].ID < result[j].ID - }) - return -} diff --git a/vendor/github.com/dgraph-io/badger/managed_db.go b/vendor/github.com/dgraph-io/badger/managed_db.go deleted file mode 100644 index adbec80..0000000 --- a/vendor/github.com/dgraph-io/badger/managed_db.go +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -// ManagedDB allows end users to manage the transactions themselves. Transaction -// start and commit timestamps are set by end-user. -// -// This is only useful for databases built on top of Badger (like Dgraph), and -// can be ignored by most users. -// -// WARNING: This is an experimental feature and may be changed significantly in -// a future release. So please proceed with caution. -type ManagedDB struct { - *DB -} - -// OpenManaged returns a new ManagedDB, which allows more control over setting -// transaction timestamps. -// -// This is only useful for databases built on top of Badger (like Dgraph), and -// can be ignored by most users. -func OpenManaged(opts Options) (*ManagedDB, error) { - opts.managedTxns = true - db, err := Open(opts) - if err != nil { - return nil, err - } - return &ManagedDB{db}, nil -} - -// NewTransaction overrides DB.NewTransaction() and panics when invoked. Use -// NewTransactionAt() instead. -func (db *ManagedDB) NewTransaction(update bool) { - panic("Cannot use NewTransaction() for ManagedDB. Use NewTransactionAt() instead.") -} - -// NewTransactionAt follows the same logic as DB.NewTransaction(), but uses the -// provided read timestamp. -// -// This is only useful for databases built on top of Badger (like Dgraph), and -// can be ignored by most users. -func (db *ManagedDB) NewTransactionAt(readTs uint64, update bool) *Txn { - txn := db.DB.NewTransaction(update) - txn.readTs = readTs - return txn -} - -// CommitAt commits the transaction, following the same logic as Commit(), but -// at the given commit timestamp. This will panic if not used with ManagedDB. -// -// This is only useful for databases built on top of Badger (like Dgraph), and -// can be ignored by most users. -func (txn *Txn) CommitAt(commitTs uint64, callback func(error)) error { - if !txn.db.opt.managedTxns { - return ErrManagedTxn - } - txn.commitTs = commitTs - return txn.Commit(callback) -} - -// GetSequence is not supported on ManagedDB. Calling this would result -// in a panic. -func (db *ManagedDB) GetSequence(_ []byte, _ uint64) (*Sequence, error) { - panic("Cannot use GetSequence for ManagedDB.") -} diff --git a/vendor/github.com/dgraph-io/badger/manifest.go b/vendor/github.com/dgraph-io/badger/manifest.go deleted file mode 100644 index e16bbfb..0000000 --- a/vendor/github.com/dgraph-io/badger/manifest.go +++ /dev/null @@ -1,433 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bufio" - "bytes" - "encoding/binary" - "fmt" - "hash/crc32" - "io" - "os" - "path/filepath" - "sync" - - "github.com/dgraph-io/badger/protos" - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" -) - -// Manifest represents the contents of the MANIFEST file in a Badger store. -// -// The MANIFEST file describes the startup state of the db -- all LSM files and what level they're -// at. -// -// It consists of a sequence of ManifestChangeSet objects. Each of these is treated atomically, -// and contains a sequence of ManifestChange's (file creations/deletions) which we use to -// reconstruct the manifest at startup. -type Manifest struct { - Levels []levelManifest - Tables map[uint64]tableManifest - - // Contains total number of creation and deletion changes in the manifest -- used to compute - // whether it'd be useful to rewrite the manifest. - Creations int - Deletions int -} - -func createManifest() Manifest { - levels := make([]levelManifest, 0) - return Manifest{ - Levels: levels, - Tables: make(map[uint64]tableManifest), - } -} - -// levelManifest contains information about LSM tree levels -// in the MANIFEST file. -type levelManifest struct { - Tables map[uint64]struct{} // Set of table id's -} - -// tableManifest contains information about a specific level -// in the LSM tree. -type tableManifest struct { - Level uint8 -} - -// manifestFile holds the file pointer (and other info) about the manifest file, which is a log -// file we append to. -type manifestFile struct { - fp *os.File - directory string - // We make this configurable so that unit tests can hit rewrite() code quickly - deletionsRewriteThreshold int - - // Guards appends, which includes access to the manifest field. - appendLock sync.Mutex - - // Used to track the current state of the manifest, used when rewriting. - manifest Manifest -} - -const ( - // ManifestFilename is the filename for the manifest file. - ManifestFilename = "MANIFEST" - manifestRewriteFilename = "MANIFEST-REWRITE" - manifestDeletionsRewriteThreshold = 10000 - manifestDeletionsRatio = 10 -) - -// asChanges returns a sequence of changes that could be used to recreate the Manifest in its -// present state. -func (m *Manifest) asChanges() []*protos.ManifestChange { - changes := make([]*protos.ManifestChange, 0, len(m.Tables)) - for id, tm := range m.Tables { - changes = append(changes, makeTableCreateChange(id, int(tm.Level))) - } - return changes -} - -func (m *Manifest) clone() Manifest { - changeSet := protos.ManifestChangeSet{Changes: m.asChanges()} - ret := createManifest() - y.Check(applyChangeSet(&ret, &changeSet)) - return ret -} - -// openOrCreateManifestFile opens a Badger manifest file if it exists, or creates on if -// one doesn’t. -func openOrCreateManifestFile(dir string, readOnly bool) (ret *manifestFile, result Manifest, err error) { - return helpOpenOrCreateManifestFile(dir, readOnly, manifestDeletionsRewriteThreshold) -} - -func helpOpenOrCreateManifestFile(dir string, readOnly bool, deletionsThreshold int) (ret *manifestFile, result Manifest, err error) { - path := filepath.Join(dir, ManifestFilename) - var flags uint32 - if readOnly { - flags |= y.ReadOnly - } - fp, err := y.OpenExistingFile(path, flags) // We explicitly sync in addChanges, outside the lock. - if err != nil { - if !os.IsNotExist(err) { - return nil, Manifest{}, err - } - if readOnly { - return nil, Manifest{}, fmt.Errorf("no manifest found, required for read-only db") - } - m := createManifest() - fp, netCreations, err := helpRewrite(dir, &m) - if err != nil { - return nil, Manifest{}, err - } - y.AssertTrue(netCreations == 0) - mf := &manifestFile{ - fp: fp, - directory: dir, - manifest: m.clone(), - deletionsRewriteThreshold: deletionsThreshold, - } - return mf, m, nil - } - - manifest, truncOffset, err := ReplayManifestFile(fp) - if err != nil { - _ = fp.Close() - return nil, Manifest{}, err - } - - if !readOnly { - // Truncate file so we don't have a half-written entry at the end. - if err := fp.Truncate(truncOffset); err != nil { - _ = fp.Close() - return nil, Manifest{}, err - } - } - if _, err = fp.Seek(0, io.SeekEnd); err != nil { - _ = fp.Close() - return nil, Manifest{}, err - } - - mf := &manifestFile{ - fp: fp, - directory: dir, - manifest: manifest.clone(), - deletionsRewriteThreshold: deletionsThreshold, - } - return mf, manifest, nil -} - -func (mf *manifestFile) close() error { - return mf.fp.Close() -} - -// addChanges writes a batch of changes, atomically, to the file. By "atomically" that means when -// we replay the MANIFEST file, we'll either replay all the changes or none of them. (The truth of -// this depends on the filesystem -- some might append garbage data if a system crash happens at -// the wrong time.) -func (mf *manifestFile) addChanges(changesParam []*protos.ManifestChange) error { - changes := protos.ManifestChangeSet{Changes: changesParam} - buf, err := changes.Marshal() - if err != nil { - return err - } - - // Maybe we could use O_APPEND instead (on certain file systems) - mf.appendLock.Lock() - if err := applyChangeSet(&mf.manifest, &changes); err != nil { - mf.appendLock.Unlock() - return err - } - // Rewrite manifest if it'd shrink by 1/10 and it's big enough to care - if mf.manifest.Deletions > mf.deletionsRewriteThreshold && - mf.manifest.Deletions > manifestDeletionsRatio*(mf.manifest.Creations-mf.manifest.Deletions) { - if err := mf.rewrite(); err != nil { - mf.appendLock.Unlock() - return err - } - } else { - var lenCrcBuf [8]byte - binary.BigEndian.PutUint32(lenCrcBuf[0:4], uint32(len(buf))) - binary.BigEndian.PutUint32(lenCrcBuf[4:8], crc32.Checksum(buf, y.CastagnoliCrcTable)) - buf = append(lenCrcBuf[:], buf...) - if _, err := mf.fp.Write(buf); err != nil { - mf.appendLock.Unlock() - return err - } - } - - mf.appendLock.Unlock() - return mf.fp.Sync() -} - -// Has to be 4 bytes. The value can never change, ever, anyway. -var magicText = [4]byte{'B', 'd', 'g', 'r'} - -// The magic version number. -const magicVersion = 4 - -func helpRewrite(dir string, m *Manifest) (*os.File, int, error) { - rewritePath := filepath.Join(dir, manifestRewriteFilename) - // We explicitly sync. - fp, err := y.OpenTruncFile(rewritePath, false) - if err != nil { - return nil, 0, err - } - - buf := make([]byte, 8) - copy(buf[0:4], magicText[:]) - binary.BigEndian.PutUint32(buf[4:8], magicVersion) - - netCreations := len(m.Tables) - changes := m.asChanges() - set := protos.ManifestChangeSet{Changes: changes} - - changeBuf, err := set.Marshal() - if err != nil { - fp.Close() - return nil, 0, err - } - var lenCrcBuf [8]byte - binary.BigEndian.PutUint32(lenCrcBuf[0:4], uint32(len(changeBuf))) - binary.BigEndian.PutUint32(lenCrcBuf[4:8], crc32.Checksum(changeBuf, y.CastagnoliCrcTable)) - buf = append(buf, lenCrcBuf[:]...) - buf = append(buf, changeBuf...) - if _, err := fp.Write(buf); err != nil { - fp.Close() - return nil, 0, err - } - if err := fp.Sync(); err != nil { - fp.Close() - return nil, 0, err - } - - // In Windows the files should be closed before doing a Rename. - if err = fp.Close(); err != nil { - return nil, 0, err - } - manifestPath := filepath.Join(dir, ManifestFilename) - if err := os.Rename(rewritePath, manifestPath); err != nil { - return nil, 0, err - } - fp, err = y.OpenExistingFile(manifestPath, 0) - if err != nil { - return nil, 0, err - } - if _, err := fp.Seek(0, io.SeekEnd); err != nil { - fp.Close() - return nil, 0, err - } - if err := syncDir(dir); err != nil { - fp.Close() - return nil, 0, err - } - - return fp, netCreations, nil -} - -// Must be called while appendLock is held. -func (mf *manifestFile) rewrite() error { - // In Windows the files should be closed before doing a Rename. - if err := mf.fp.Close(); err != nil { - return err - } - fp, netCreations, err := helpRewrite(mf.directory, &mf.manifest) - if err != nil { - return err - } - mf.fp = fp - mf.manifest.Creations = netCreations - mf.manifest.Deletions = 0 - - return nil -} - -type countingReader struct { - wrapped *bufio.Reader - count int64 -} - -func (r *countingReader) Read(p []byte) (n int, err error) { - n, err = r.wrapped.Read(p) - r.count += int64(n) - return -} - -func (r *countingReader) ReadByte() (b byte, err error) { - b, err = r.wrapped.ReadByte() - if err == nil { - r.count++ - } - return -} - -var ( - errBadMagic = errors.New("manifest has bad magic") -) - -// ReplayManifestFile reads the manifest file and constructs two manifest objects. (We need one -// immutable copy and one mutable copy of the manifest. Easiest way is to construct two of them.) -// Also, returns the last offset after a completely read manifest entry -- the file must be -// truncated at that point before further appends are made (if there is a partial entry after -// that). In normal conditions, truncOffset is the file size. -func ReplayManifestFile(fp *os.File) (ret Manifest, truncOffset int64, err error) { - r := countingReader{wrapped: bufio.NewReader(fp)} - - var magicBuf [8]byte - if _, err := io.ReadFull(&r, magicBuf[:]); err != nil { - return Manifest{}, 0, errBadMagic - } - if !bytes.Equal(magicBuf[0:4], magicText[:]) { - return Manifest{}, 0, errBadMagic - } - version := binary.BigEndian.Uint32(magicBuf[4:8]) - if version != magicVersion { - return Manifest{}, 0, - fmt.Errorf("manifest has unsupported version: %d (we support %d)", version, magicVersion) - } - - build := createManifest() - var offset int64 - for { - offset = r.count - var lenCrcBuf [8]byte - _, err := io.ReadFull(&r, lenCrcBuf[:]) - if err != nil { - if err == io.EOF || err == io.ErrUnexpectedEOF { - break - } - return Manifest{}, 0, err - } - length := binary.BigEndian.Uint32(lenCrcBuf[0:4]) - var buf = make([]byte, length) - if _, err := io.ReadFull(&r, buf); err != nil { - if err == io.EOF || err == io.ErrUnexpectedEOF { - break - } - return Manifest{}, 0, err - } - if crc32.Checksum(buf, y.CastagnoliCrcTable) != binary.BigEndian.Uint32(lenCrcBuf[4:8]) { - break - } - - var changeSet protos.ManifestChangeSet - if err := changeSet.Unmarshal(buf); err != nil { - return Manifest{}, 0, err - } - - if err := applyChangeSet(&build, &changeSet); err != nil { - return Manifest{}, 0, err - } - } - - return build, offset, err -} - -func applyManifestChange(build *Manifest, tc *protos.ManifestChange) error { - switch tc.Op { - case protos.ManifestChange_CREATE: - if _, ok := build.Tables[tc.Id]; ok { - return fmt.Errorf("MANIFEST invalid, table %d exists", tc.Id) - } - build.Tables[tc.Id] = tableManifest{ - Level: uint8(tc.Level), - } - for len(build.Levels) <= int(tc.Level) { - build.Levels = append(build.Levels, levelManifest{make(map[uint64]struct{})}) - } - build.Levels[tc.Level].Tables[tc.Id] = struct{}{} - build.Creations++ - case protos.ManifestChange_DELETE: - tm, ok := build.Tables[tc.Id] - if !ok { - return fmt.Errorf("MANIFEST removes non-existing table %d", tc.Id) - } - delete(build.Levels[tm.Level].Tables, tc.Id) - delete(build.Tables, tc.Id) - build.Deletions++ - default: - return fmt.Errorf("MANIFEST file has invalid manifestChange op") - } - return nil -} - -// This is not a "recoverable" error -- opening the KV store fails because the MANIFEST file is -// just plain broken. -func applyChangeSet(build *Manifest, changeSet *protos.ManifestChangeSet) error { - for _, change := range changeSet.Changes { - if err := applyManifestChange(build, change); err != nil { - return err - } - } - return nil -} - -func makeTableCreateChange(id uint64, level int) *protos.ManifestChange { - return &protos.ManifestChange{ - Id: id, - Op: protos.ManifestChange_CREATE, - Level: uint32(level), - } -} - -func makeTableDeleteChange(id uint64) *protos.ManifestChange { - return &protos.ManifestChange{ - Id: id, - Op: protos.ManifestChange_DELETE, - } -} diff --git a/vendor/github.com/dgraph-io/badger/manifest_test.go b/vendor/github.com/dgraph-io/badger/manifest_test.go deleted file mode 100644 index b59cf83..0000000 --- a/vendor/github.com/dgraph-io/badger/manifest_test.go +++ /dev/null @@ -1,244 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "fmt" - "io/ioutil" - "math/rand" - "os" - "path/filepath" - "sort" - "testing" - - "golang.org/x/net/trace" - - "github.com/dgraph-io/badger/options" - "github.com/dgraph-io/badger/protos" - "github.com/dgraph-io/badger/table" - "github.com/dgraph-io/badger/y" - "github.com/stretchr/testify/require" -) - -func TestManifestBasic(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opt := getTestOptions(dir) - { - kv, err := Open(opt) - require.NoError(t, err) - n := 5000 - for i := 0; i < n; i++ { - if (i % 10000) == 0 { - fmt.Printf("Putting i=%d\n", i) - } - k := []byte(fmt.Sprintf("%16x", rand.Int63())) - txnSet(t, kv, k, k, 0x00) - } - txnSet(t, kv, []byte("testkey"), []byte("testval"), 0x05) - kv.validate() - require.NoError(t, kv.Close()) - } - - kv, err := Open(opt) - require.NoError(t, err) - - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get([]byte("testkey")) - require.NoError(t, err) - require.EqualValues(t, "testval", string(getItemValue(t, item))) - require.EqualValues(t, byte(0x05), item.UserMeta()) - return nil - })) - require.NoError(t, kv.Close()) -} - -func helpTestManifestFileCorruption(t *testing.T, off int64, errorContent string) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opt := getTestOptions(dir) - { - kv, err := Open(opt) - require.NoError(t, err) - require.NoError(t, kv.Close()) - } - fp, err := os.OpenFile(filepath.Join(dir, ManifestFilename), os.O_RDWR, 0) - require.NoError(t, err) - // Mess with magic value or version to force error - _, err = fp.WriteAt([]byte{'X'}, off) - require.NoError(t, err) - require.NoError(t, fp.Close()) - kv, err := Open(opt) - defer func() { - if kv != nil { - kv.Close() - } - }() - require.Error(t, err) - require.Contains(t, err.Error(), errorContent) -} - -func TestManifestMagic(t *testing.T) { - helpTestManifestFileCorruption(t, 3, "bad magic") -} - -func TestManifestVersion(t *testing.T) { - helpTestManifestFileCorruption(t, 4, "unsupported version") -} - -func key(prefix string, i int) string { - return prefix + fmt.Sprintf("%04d", i) -} - -func buildTestTable(t *testing.T, prefix string, n int) *os.File { - y.AssertTrue(n <= 10000) - keyValues := make([][]string, n) - for i := 0; i < n; i++ { - k := key(prefix, i) - v := fmt.Sprintf("%d", i) - keyValues[i] = []string{k, v} - } - return buildTable(t, keyValues) -} - -// TODO - Move these to somewhere where table package can also use it. -// keyValues is n by 2 where n is number of pairs. -func buildTable(t *testing.T, keyValues [][]string) *os.File { - b := table.NewTableBuilder() - defer b.Close() - // TODO: Add test for file garbage collection here. No files should be left after the tests here. - - filename := fmt.Sprintf("%s%s%d.sst", os.TempDir(), string(os.PathSeparator), rand.Int63()) - f, err := y.OpenSyncedFile(filename, true) - if t != nil { - require.NoError(t, err) - } else { - y.Check(err) - } - - sort.Slice(keyValues, func(i, j int) bool { - return keyValues[i][0] < keyValues[j][0] - }) - for _, kv := range keyValues { - y.AssertTrue(len(kv) == 2) - err := b.Add(y.KeyWithTs([]byte(kv[0]), 10), y.ValueStruct{ - Value: []byte(kv[1]), - Meta: 'A', - UserMeta: 0, - }) - if t != nil { - require.NoError(t, err) - } else { - y.Check(err) - } - } - f.Write(b.Finish()) - f.Close() - f, _ = y.OpenSyncedFile(filename, true) - return f -} - -func TestOverlappingKeyRangeError(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - opt := DefaultOptions - opt.Dir = dir - opt.ValueDir = dir - kv, err := Open(opt) - require.NoError(t, err) - - lh0 := newLevelHandler(kv, 0) - lh1 := newLevelHandler(kv, 1) - f := buildTestTable(t, "k", 2) - t1, err := table.OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer t1.DecrRef() - - done := lh0.tryAddLevel0Table(t1) - require.Equal(t, true, done) - - cd := compactDef{ - thisLevel: lh0, - nextLevel: lh1, - elog: trace.New("Badger", "Compact"), - } - - manifest := createManifest() - lc, err := newLevelsController(kv, &manifest) - require.NoError(t, err) - done = lc.fillTablesL0(&cd) - require.Equal(t, true, done) - lc.runCompactDef(0, cd) - - f = buildTestTable(t, "l", 2) - t2, err := table.OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer t2.DecrRef() - done = lh0.tryAddLevel0Table(t2) - require.Equal(t, true, done) - - cd = compactDef{ - thisLevel: lh0, - nextLevel: lh1, - elog: trace.New("Badger", "Compact"), - } - lc.fillTablesL0(&cd) - lc.runCompactDef(0, cd) -} - -func TestManifestRewrite(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - deletionsThreshold := 10 - mf, m, err := helpOpenOrCreateManifestFile(dir, false, deletionsThreshold) - defer func() { - if mf != nil { - mf.close() - } - }() - require.NoError(t, err) - require.Equal(t, 0, m.Creations) - require.Equal(t, 0, m.Deletions) - - err = mf.addChanges([]*protos.ManifestChange{ - makeTableCreateChange(0, 0), - }) - require.NoError(t, err) - - for i := uint64(0); i < uint64(deletionsThreshold*3); i++ { - ch := []*protos.ManifestChange{ - makeTableCreateChange(i+1, 0), - makeTableDeleteChange(i), - } - err := mf.addChanges(ch) - require.NoError(t, err) - } - err = mf.close() - require.NoError(t, err) - mf = nil - mf, m, err = helpOpenOrCreateManifestFile(dir, false, deletionsThreshold) - require.NoError(t, err) - require.Equal(t, map[uint64]tableManifest{ - uint64(deletionsThreshold * 3): {Level: 0}, - }, m.Tables) -} diff --git a/vendor/github.com/dgraph-io/badger/options.go b/vendor/github.com/dgraph-io/badger/options.go deleted file mode 100644 index f6d0abb..0000000 --- a/vendor/github.com/dgraph-io/badger/options.go +++ /dev/null @@ -1,144 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "github.com/dgraph-io/badger/options" -) - -// NOTE: Keep the comments in the following to 75 chars width, so they -// format nicely in godoc. - -// Options are params for creating DB object. -// -// This package provides DefaultOptions which contains options that should -// work for most applications. Consider using that as a starting point before -// customizing it for your own needs. -type Options struct { - // 1. Mandatory flags - // ------------------- - // Directory to store the data in. Should exist and be writable. - Dir string - // Directory to store the value log in. Can be the same as Dir. Should - // exist and be writable. - ValueDir string - - // 2. Frequently modified flags - // ----------------------------- - // Sync all writes to disk. Setting this to true would slow down data - // loading significantly. - SyncWrites bool - - // How should LSM tree be accessed. - TableLoadingMode options.FileLoadingMode - - // How should value log be accessed. - ValueLogLoadingMode options.FileLoadingMode - - // How many versions to keep per key. - NumVersionsToKeep int - - // 3. Flags that user might want to review - // ---------------------------------------- - // The following affect all levels of LSM tree. - MaxTableSize int64 // Each table (or file) is at most this size. - LevelSizeMultiplier int // Equals SizeOf(Li+1)/SizeOf(Li). - MaxLevels int // Maximum number of levels of compaction. - // If value size >= this threshold, only store value offsets in tree. - ValueThreshold int - // Maximum number of tables to keep in memory, before stalling. - NumMemtables int - // The following affect how we handle LSM tree L0. - // Maximum number of Level 0 tables before we start compacting. - NumLevelZeroTables int - - // If we hit this number of Level 0 tables, we will stall until L0 is - // compacted away. - NumLevelZeroTablesStall int - - // Maximum total size for L1. - LevelOneSize int64 - - // Size of single value log file. - ValueLogFileSize int64 - - // Max number of entries a value log file can hold (approximately). A value log file would be - // determined by the smaller of its file size and max entries. - ValueLogMaxEntries uint32 - - // Number of compaction workers to run concurrently. - NumCompactors int - - // Transaction start and commit timestamps are manaVgedTxns by end-user. This - // is a private option used by ManagedDB. - managedTxns bool - - // 4. Flags for testing purposes - // ------------------------------ - DoNotCompact bool // Stops LSM tree from compactions. - - maxBatchCount int64 // max entries in batch - maxBatchSize int64 // max batch size in bytes - - // Open the DB as read-only. With this set, multiple processes can - // open the same Badger DB. Note: if the DB being opened had crashed - // before and has vlog data to be replayed, ReadOnly will cause Open - // to fail with an appropriate message. - ReadOnly bool - - // Truncate value log to delete corrupt data, if any. Would not truncate if ReadOnly is set. - Truncate bool -} - -// DefaultOptions sets a list of recommended options for good performance. -// Feel free to modify these to suit your needs. -var DefaultOptions = Options{ - DoNotCompact: false, - LevelOneSize: 256 << 20, - LevelSizeMultiplier: 10, - TableLoadingMode: options.LoadToRAM, - ValueLogLoadingMode: options.MemoryMap, - // table.MemoryMap to mmap() the tables. - // table.Nothing to not preload the tables. - MaxLevels: 7, - MaxTableSize: 64 << 20, - NumCompactors: 3, - NumLevelZeroTables: 5, - NumLevelZeroTablesStall: 10, - NumMemtables: 5, - SyncWrites: true, - NumVersionsToKeep: 1, - // Nothing to read/write value log using standard File I/O - // MemoryMap to mmap() the value log files - ValueLogFileSize: 1 << 30, - ValueLogMaxEntries: 1000000, - ValueThreshold: 32, - Truncate: false, -} - -// LSMOnlyOptions follows from DefaultOptions, but sets a higher ValueThreshold so values would -// be colocated with the LSM tree, with value log largely acting as a write-ahead log only. These -// options would reduce the disk usage of value log, and make Badger act like a typical LSM tree. -var LSMOnlyOptions = Options{} - -func init() { - LSMOnlyOptions = DefaultOptions - - LSMOnlyOptions.ValueThreshold = 65500 // Max value length which fits in uint16. - LSMOnlyOptions.ValueLogFileSize = 64 << 20 // Allow easy space reclamation. - LSMOnlyOptions.ValueLogLoadingMode = options.FileIO -} diff --git a/vendor/github.com/dgraph-io/badger/options/options.go b/vendor/github.com/dgraph-io/badger/options/options.go deleted file mode 100644 index 06c8b1b..0000000 --- a/vendor/github.com/dgraph-io/badger/options/options.go +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package options - -// FileLoadingMode specifies how data in LSM table files and value log files should -// be loaded. -type FileLoadingMode int - -const ( - // FileIO indicates that files must be loaded using standard I/O - FileIO FileLoadingMode = iota - // LoadToRAM indicates that file must be loaded into RAM - LoadToRAM - // MemoryMap indicates that that the file must be memory-mapped - MemoryMap -) diff --git a/vendor/github.com/dgraph-io/badger/protos/backup.pb.go b/vendor/github.com/dgraph-io/badger/protos/backup.pb.go deleted file mode 100644 index 13a9f61..0000000 --- a/vendor/github.com/dgraph-io/badger/protos/backup.pb.go +++ /dev/null @@ -1,497 +0,0 @@ -// Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: backup.proto - -/* - Package protos is a generated protocol buffer package. - - It is generated from these files: - backup.proto - manifest.proto - - It has these top-level messages: - KVPair - ManifestChangeSet - ManifestChange -*/ -package protos - -import proto "github.com/golang/protobuf/proto" -import fmt "fmt" -import math "math" - -import io "io" - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package - -type KVPair struct { - Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` - Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` - UserMeta []byte `protobuf:"bytes,3,opt,name=userMeta,proto3" json:"userMeta,omitempty"` - Version uint64 `protobuf:"varint,4,opt,name=version,proto3" json:"version,omitempty"` - ExpiresAt uint64 `protobuf:"varint,5,opt,name=expires_at,json=expiresAt,proto3" json:"expires_at,omitempty"` -} - -func (m *KVPair) Reset() { *m = KVPair{} } -func (m *KVPair) String() string { return proto.CompactTextString(m) } -func (*KVPair) ProtoMessage() {} -func (*KVPair) Descriptor() ([]byte, []int) { return fileDescriptorBackup, []int{0} } - -func (m *KVPair) GetKey() []byte { - if m != nil { - return m.Key - } - return nil -} - -func (m *KVPair) GetValue() []byte { - if m != nil { - return m.Value - } - return nil -} - -func (m *KVPair) GetUserMeta() []byte { - if m != nil { - return m.UserMeta - } - return nil -} - -func (m *KVPair) GetVersion() uint64 { - if m != nil { - return m.Version - } - return 0 -} - -func (m *KVPair) GetExpiresAt() uint64 { - if m != nil { - return m.ExpiresAt - } - return 0 -} - -func init() { - proto.RegisterType((*KVPair)(nil), "protos.KVPair") -} -func (m *KVPair) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalTo(dAtA) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *KVPair) MarshalTo(dAtA []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Key) > 0 { - dAtA[i] = 0xa - i++ - i = encodeVarintBackup(dAtA, i, uint64(len(m.Key))) - i += copy(dAtA[i:], m.Key) - } - if len(m.Value) > 0 { - dAtA[i] = 0x12 - i++ - i = encodeVarintBackup(dAtA, i, uint64(len(m.Value))) - i += copy(dAtA[i:], m.Value) - } - if len(m.UserMeta) > 0 { - dAtA[i] = 0x1a - i++ - i = encodeVarintBackup(dAtA, i, uint64(len(m.UserMeta))) - i += copy(dAtA[i:], m.UserMeta) - } - if m.Version != 0 { - dAtA[i] = 0x20 - i++ - i = encodeVarintBackup(dAtA, i, uint64(m.Version)) - } - if m.ExpiresAt != 0 { - dAtA[i] = 0x28 - i++ - i = encodeVarintBackup(dAtA, i, uint64(m.ExpiresAt)) - } - return i, nil -} - -func encodeFixed64Backup(dAtA []byte, offset int, v uint64) int { - dAtA[offset] = uint8(v) - dAtA[offset+1] = uint8(v >> 8) - dAtA[offset+2] = uint8(v >> 16) - dAtA[offset+3] = uint8(v >> 24) - dAtA[offset+4] = uint8(v >> 32) - dAtA[offset+5] = uint8(v >> 40) - dAtA[offset+6] = uint8(v >> 48) - dAtA[offset+7] = uint8(v >> 56) - return offset + 8 -} -func encodeFixed32Backup(dAtA []byte, offset int, v uint32) int { - dAtA[offset] = uint8(v) - dAtA[offset+1] = uint8(v >> 8) - dAtA[offset+2] = uint8(v >> 16) - dAtA[offset+3] = uint8(v >> 24) - return offset + 4 -} -func encodeVarintBackup(dAtA []byte, offset int, v uint64) int { - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) - return offset + 1 -} -func (m *KVPair) Size() (n int) { - var l int - _ = l - l = len(m.Key) - if l > 0 { - n += 1 + l + sovBackup(uint64(l)) - } - l = len(m.Value) - if l > 0 { - n += 1 + l + sovBackup(uint64(l)) - } - l = len(m.UserMeta) - if l > 0 { - n += 1 + l + sovBackup(uint64(l)) - } - if m.Version != 0 { - n += 1 + sovBackup(uint64(m.Version)) - } - if m.ExpiresAt != 0 { - n += 1 + sovBackup(uint64(m.ExpiresAt)) - } - return n -} - -func sovBackup(x uint64) (n int) { - for { - n++ - x >>= 7 - if x == 0 { - break - } - } - return n -} -func sozBackup(x uint64) (n int) { - return sovBackup(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (m *KVPair) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowBackup - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: KVPair: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: KVPair: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowBackup - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthBackup - } - postIndex := iNdEx + byteLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Key = append(m.Key[:0], dAtA[iNdEx:postIndex]...) - if m.Key == nil { - m.Key = []byte{} - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowBackup - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthBackup - } - postIndex := iNdEx + byteLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Value = append(m.Value[:0], dAtA[iNdEx:postIndex]...) - if m.Value == nil { - m.Value = []byte{} - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field UserMeta", wireType) - } - var byteLen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowBackup - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - byteLen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if byteLen < 0 { - return ErrInvalidLengthBackup - } - postIndex := iNdEx + byteLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.UserMeta = append(m.UserMeta[:0], dAtA[iNdEx:postIndex]...) - if m.UserMeta == nil { - m.UserMeta = []byte{} - } - iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) - } - m.Version = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowBackup - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Version |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ExpiresAt", wireType) - } - m.ExpiresAt = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowBackup - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.ExpiresAt |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipBackup(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthBackup - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func skipBackup(dAtA []byte) (n int, err error) { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowBackup - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - wireType := int(wire & 0x7) - switch wireType { - case 0: - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowBackup - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - iNdEx++ - if dAtA[iNdEx-1] < 0x80 { - break - } - } - return iNdEx, nil - case 1: - iNdEx += 8 - return iNdEx, nil - case 2: - var length int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowBackup - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - length |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - iNdEx += length - if length < 0 { - return 0, ErrInvalidLengthBackup - } - return iNdEx, nil - case 3: - for { - var innerWire uint64 - var start int = iNdEx - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowBackup - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - innerWire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - innerWireType := int(innerWire & 0x7) - if innerWireType == 4 { - break - } - next, err := skipBackup(dAtA[start:]) - if err != nil { - return 0, err - } - iNdEx = start + next - } - return iNdEx, nil - case 4: - return iNdEx, nil - case 5: - iNdEx += 4 - return iNdEx, nil - default: - return 0, fmt.Errorf("proto: illegal wireType %d", wireType) - } - } - panic("unreachable") -} - -var ( - ErrInvalidLengthBackup = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowBackup = fmt.Errorf("proto: integer overflow") -) - -func init() { proto.RegisterFile("backup.proto", fileDescriptorBackup) } - -var fileDescriptorBackup = []byte{ - // 167 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x49, 0x4a, 0x4c, 0xce, - 0x2e, 0x2d, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x03, 0x53, 0xc5, 0x4a, 0xad, 0x8c, - 0x5c, 0x6c, 0xde, 0x61, 0x01, 0x89, 0x99, 0x45, 0x42, 0x02, 0x5c, 0xcc, 0xd9, 0xa9, 0x95, 0x12, - 0x8c, 0x0a, 0x8c, 0x1a, 0x3c, 0x41, 0x20, 0xa6, 0x90, 0x08, 0x17, 0x6b, 0x59, 0x62, 0x4e, 0x69, - 0xaa, 0x04, 0x13, 0x58, 0x0c, 0xc2, 0x11, 0x92, 0xe2, 0xe2, 0x28, 0x2d, 0x4e, 0x2d, 0xf2, 0x4d, - 0x2d, 0x49, 0x94, 0x60, 0x06, 0x4b, 0xc0, 0xf9, 0x42, 0x12, 0x5c, 0xec, 0x65, 0xa9, 0x45, 0xc5, - 0x99, 0xf9, 0x79, 0x12, 0x2c, 0x0a, 0x8c, 0x1a, 0x2c, 0x41, 0x30, 0xae, 0x90, 0x2c, 0x17, 0x57, - 0x6a, 0x45, 0x41, 0x66, 0x51, 0x6a, 0x71, 0x7c, 0x62, 0x89, 0x04, 0x2b, 0x58, 0x92, 0x13, 0x2a, - 0xe2, 0x58, 0xe2, 0x24, 0x70, 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, - 0x31, 0xce, 0x78, 0x2c, 0xc7, 0x90, 0x04, 0x71, 0xa1, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, 0xe7, - 0x3f, 0x3f, 0x95, 0xb8, 0x00, 0x00, 0x00, -} diff --git a/vendor/github.com/dgraph-io/badger/protos/backup.proto b/vendor/github.com/dgraph-io/badger/protos/backup.proto deleted file mode 100644 index 0f4e3d6..0000000 --- a/vendor/github.com/dgraph-io/badger/protos/backup.proto +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright (C) 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -// Use protos/gen.sh to generate .pb.go files. -syntax = "proto3"; - -package protos; - -message KVPair { - bytes key = 1; - bytes value = 2; - bytes userMeta = 3; - uint64 version = 4; - uint64 expires_at = 5; -} \ No newline at end of file diff --git a/vendor/github.com/dgraph-io/badger/protos/gen.sh b/vendor/github.com/dgraph-io/badger/protos/gen.sh deleted file mode 100755 index 15bb38e..0000000 --- a/vendor/github.com/dgraph-io/badger/protos/gen.sh +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/bash - -# You might need to go get -v github.com/gogo/protobuf/... - -protos=${GOPATH-$HOME/go}/src/github.com/dgraph-io/badger/protos -pushd $protos > /dev/null -protoc --gofast_out=plugins=grpc:. -I=. *.proto diff --git a/vendor/github.com/dgraph-io/badger/protos/manifest.pb.go b/vendor/github.com/dgraph-io/badger/protos/manifest.pb.go deleted file mode 100644 index d8db55f..0000000 --- a/vendor/github.com/dgraph-io/badger/protos/manifest.pb.go +++ /dev/null @@ -1,534 +0,0 @@ -// Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: manifest.proto - -package protos - -import proto "github.com/golang/protobuf/proto" -import fmt "fmt" -import math "math" - -import io "io" - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -type ManifestChange_Operation int32 - -const ( - ManifestChange_CREATE ManifestChange_Operation = 0 - ManifestChange_DELETE ManifestChange_Operation = 1 -) - -var ManifestChange_Operation_name = map[int32]string{ - 0: "CREATE", - 1: "DELETE", -} -var ManifestChange_Operation_value = map[string]int32{ - "CREATE": 0, - "DELETE": 1, -} - -func (x ManifestChange_Operation) String() string { - return proto.EnumName(ManifestChange_Operation_name, int32(x)) -} -func (ManifestChange_Operation) EnumDescriptor() ([]byte, []int) { - return fileDescriptorManifest, []int{1, 0} -} - -type ManifestChangeSet struct { - // A set of changes that are applied atomically. - Changes []*ManifestChange `protobuf:"bytes,1,rep,name=changes" json:"changes,omitempty"` -} - -func (m *ManifestChangeSet) Reset() { *m = ManifestChangeSet{} } -func (m *ManifestChangeSet) String() string { return proto.CompactTextString(m) } -func (*ManifestChangeSet) ProtoMessage() {} -func (*ManifestChangeSet) Descriptor() ([]byte, []int) { return fileDescriptorManifest, []int{0} } - -func (m *ManifestChangeSet) GetChanges() []*ManifestChange { - if m != nil { - return m.Changes - } - return nil -} - -type ManifestChange struct { - Id uint64 `protobuf:"varint,1,opt,name=Id,proto3" json:"Id,omitempty"` - Op ManifestChange_Operation `protobuf:"varint,2,opt,name=Op,proto3,enum=protos.ManifestChange_Operation" json:"Op,omitempty"` - Level uint32 `protobuf:"varint,3,opt,name=Level,proto3" json:"Level,omitempty"` -} - -func (m *ManifestChange) Reset() { *m = ManifestChange{} } -func (m *ManifestChange) String() string { return proto.CompactTextString(m) } -func (*ManifestChange) ProtoMessage() {} -func (*ManifestChange) Descriptor() ([]byte, []int) { return fileDescriptorManifest, []int{1} } - -func (m *ManifestChange) GetId() uint64 { - if m != nil { - return m.Id - } - return 0 -} - -func (m *ManifestChange) GetOp() ManifestChange_Operation { - if m != nil { - return m.Op - } - return ManifestChange_CREATE -} - -func (m *ManifestChange) GetLevel() uint32 { - if m != nil { - return m.Level - } - return 0 -} - -func init() { - proto.RegisterType((*ManifestChangeSet)(nil), "protos.ManifestChangeSet") - proto.RegisterType((*ManifestChange)(nil), "protos.ManifestChange") - proto.RegisterEnum("protos.ManifestChange_Operation", ManifestChange_Operation_name, ManifestChange_Operation_value) -} -func (m *ManifestChangeSet) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalTo(dAtA) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *ManifestChangeSet) MarshalTo(dAtA []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Changes) > 0 { - for _, msg := range m.Changes { - dAtA[i] = 0xa - i++ - i = encodeVarintManifest(dAtA, i, uint64(msg.Size())) - n, err := msg.MarshalTo(dAtA[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *ManifestChange) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalTo(dAtA) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *ManifestChange) MarshalTo(dAtA []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if m.Id != 0 { - dAtA[i] = 0x8 - i++ - i = encodeVarintManifest(dAtA, i, uint64(m.Id)) - } - if m.Op != 0 { - dAtA[i] = 0x10 - i++ - i = encodeVarintManifest(dAtA, i, uint64(m.Op)) - } - if m.Level != 0 { - dAtA[i] = 0x18 - i++ - i = encodeVarintManifest(dAtA, i, uint64(m.Level)) - } - return i, nil -} - -func encodeFixed64Manifest(dAtA []byte, offset int, v uint64) int { - dAtA[offset] = uint8(v) - dAtA[offset+1] = uint8(v >> 8) - dAtA[offset+2] = uint8(v >> 16) - dAtA[offset+3] = uint8(v >> 24) - dAtA[offset+4] = uint8(v >> 32) - dAtA[offset+5] = uint8(v >> 40) - dAtA[offset+6] = uint8(v >> 48) - dAtA[offset+7] = uint8(v >> 56) - return offset + 8 -} -func encodeFixed32Manifest(dAtA []byte, offset int, v uint32) int { - dAtA[offset] = uint8(v) - dAtA[offset+1] = uint8(v >> 8) - dAtA[offset+2] = uint8(v >> 16) - dAtA[offset+3] = uint8(v >> 24) - return offset + 4 -} -func encodeVarintManifest(dAtA []byte, offset int, v uint64) int { - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) - return offset + 1 -} -func (m *ManifestChangeSet) Size() (n int) { - var l int - _ = l - if len(m.Changes) > 0 { - for _, e := range m.Changes { - l = e.Size() - n += 1 + l + sovManifest(uint64(l)) - } - } - return n -} - -func (m *ManifestChange) Size() (n int) { - var l int - _ = l - if m.Id != 0 { - n += 1 + sovManifest(uint64(m.Id)) - } - if m.Op != 0 { - n += 1 + sovManifest(uint64(m.Op)) - } - if m.Level != 0 { - n += 1 + sovManifest(uint64(m.Level)) - } - return n -} - -func sovManifest(x uint64) (n int) { - for { - n++ - x >>= 7 - if x == 0 { - break - } - } - return n -} -func sozManifest(x uint64) (n int) { - return sovManifest(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (m *ManifestChangeSet) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowManifest - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ManifestChangeSet: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ManifestChangeSet: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Changes", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowManifest - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthManifest - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Changes = append(m.Changes, &ManifestChange{}) - if err := m.Changes[len(m.Changes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipManifest(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthManifest - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ManifestChange) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowManifest - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ManifestChange: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ManifestChange: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) - } - m.Id = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowManifest - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Id |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType) - } - m.Op = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowManifest - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Op |= (ManifestChange_Operation(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Level", wireType) - } - m.Level = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowManifest - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - m.Level |= (uint32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipManifest(dAtA[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthManifest - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func skipManifest(dAtA []byte) (n int, err error) { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowManifest - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - wireType := int(wire & 0x7) - switch wireType { - case 0: - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowManifest - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - iNdEx++ - if dAtA[iNdEx-1] < 0x80 { - break - } - } - return iNdEx, nil - case 1: - iNdEx += 8 - return iNdEx, nil - case 2: - var length int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowManifest - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - length |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - iNdEx += length - if length < 0 { - return 0, ErrInvalidLengthManifest - } - return iNdEx, nil - case 3: - for { - var innerWire uint64 - var start int = iNdEx - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowManifest - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - innerWire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - innerWireType := int(innerWire & 0x7) - if innerWireType == 4 { - break - } - next, err := skipManifest(dAtA[start:]) - if err != nil { - return 0, err - } - iNdEx = start + next - } - return iNdEx, nil - case 4: - return iNdEx, nil - case 5: - iNdEx += 4 - return iNdEx, nil - default: - return 0, fmt.Errorf("proto: illegal wireType %d", wireType) - } - } - panic("unreachable") -} - -var ( - ErrInvalidLengthManifest = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowManifest = fmt.Errorf("proto: integer overflow") -) - -func init() { proto.RegisterFile("manifest.proto", fileDescriptorManifest) } - -var fileDescriptorManifest = []byte{ - // 208 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0xcb, 0x4d, 0xcc, 0xcb, - 0x4c, 0x4b, 0x2d, 0x2e, 0xd1, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x03, 0x53, 0xc5, 0x4a, - 0xae, 0x5c, 0x82, 0xbe, 0x50, 0x19, 0xe7, 0x8c, 0xc4, 0xbc, 0xf4, 0xd4, 0xe0, 0xd4, 0x12, 0x21, - 0x03, 0x2e, 0xf6, 0x64, 0x30, 0xa7, 0x58, 0x82, 0x51, 0x81, 0x59, 0x83, 0xdb, 0x48, 0x0c, 0xa2, - 0xab, 0x58, 0x0f, 0x55, 0x6d, 0x10, 0x4c, 0x99, 0x52, 0x2f, 0x23, 0x17, 0x1f, 0xaa, 0x9c, 0x10, - 0x1f, 0x17, 0x93, 0x67, 0x8a, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0x4b, 0x10, 0x93, 0x67, 0x8a, 0x90, - 0x01, 0x17, 0x93, 0x7f, 0x81, 0x04, 0x93, 0x02, 0xa3, 0x06, 0x9f, 0x91, 0x02, 0x76, 0xf3, 0xf4, - 0xfc, 0x0b, 0x52, 0x8b, 0x12, 0x4b, 0x32, 0xf3, 0xf3, 0x82, 0x98, 0xfc, 0x0b, 0x84, 0x44, 0xb8, - 0x58, 0x7d, 0x52, 0xcb, 0x52, 0x73, 0x24, 0x98, 0x15, 0x18, 0x35, 0x78, 0x83, 0x20, 0x1c, 0x25, - 0x65, 0x2e, 0x4e, 0xb8, 0x32, 0x21, 0x2e, 0x2e, 0x36, 0xe7, 0x20, 0x57, 0xc7, 0x10, 0x57, 0x01, - 0x06, 0x10, 0xdb, 0xc5, 0xd5, 0xc7, 0x35, 0xc4, 0x55, 0x80, 0xd1, 0x49, 0xe0, 0xc4, 0x23, 0x39, - 0xc6, 0x0b, 0x8f, 0xe4, 0x18, 0x1f, 0x3c, 0x92, 0x63, 0x9c, 0xf1, 0x58, 0x8e, 0x21, 0x09, 0xe2, - 0x61, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x42, 0x6f, 0x23, 0xc9, 0x09, 0x01, 0x00, 0x00, -} diff --git a/vendor/github.com/dgraph-io/badger/protos/manifest.proto b/vendor/github.com/dgraph-io/badger/protos/manifest.proto deleted file mode 100644 index 295c63a..0000000 --- a/vendor/github.com/dgraph-io/badger/protos/manifest.proto +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright (C) 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -// Use protos/gen.sh to generate .pb.go files. -syntax = "proto3"; - -package protos; - -message ManifestChangeSet { - // A set of changes that are applied atomically. - repeated ManifestChange changes = 1; -} - -message ManifestChange { - uint64 Id = 1; - enum Operation { - CREATE = 0; - DELETE = 1; - } - Operation Op = 2; - uint32 Level = 3; // Only used for CREATE -} diff --git a/vendor/github.com/dgraph-io/badger/skl/README.md b/vendor/github.com/dgraph-io/badger/skl/README.md deleted file mode 100644 index 92fa68b..0000000 --- a/vendor/github.com/dgraph-io/badger/skl/README.md +++ /dev/null @@ -1,113 +0,0 @@ -This is much better than `skiplist` and `slist`. - -``` -BenchmarkReadWrite/frac_0-8 3000000 537 ns/op -BenchmarkReadWrite/frac_1-8 3000000 503 ns/op -BenchmarkReadWrite/frac_2-8 3000000 492 ns/op -BenchmarkReadWrite/frac_3-8 3000000 475 ns/op -BenchmarkReadWrite/frac_4-8 3000000 440 ns/op -BenchmarkReadWrite/frac_5-8 5000000 442 ns/op -BenchmarkReadWrite/frac_6-8 5000000 380 ns/op -BenchmarkReadWrite/frac_7-8 5000000 338 ns/op -BenchmarkReadWrite/frac_8-8 5000000 294 ns/op -BenchmarkReadWrite/frac_9-8 10000000 268 ns/op -BenchmarkReadWrite/frac_10-8 100000000 26.3 ns/op -``` - -And even better than a simple map with read-write lock: - -``` -BenchmarkReadWriteMap/frac_0-8 2000000 774 ns/op -BenchmarkReadWriteMap/frac_1-8 2000000 647 ns/op -BenchmarkReadWriteMap/frac_2-8 3000000 605 ns/op -BenchmarkReadWriteMap/frac_3-8 3000000 603 ns/op -BenchmarkReadWriteMap/frac_4-8 3000000 556 ns/op -BenchmarkReadWriteMap/frac_5-8 3000000 472 ns/op -BenchmarkReadWriteMap/frac_6-8 3000000 476 ns/op -BenchmarkReadWriteMap/frac_7-8 3000000 457 ns/op -BenchmarkReadWriteMap/frac_8-8 5000000 444 ns/op -BenchmarkReadWriteMap/frac_9-8 5000000 361 ns/op -BenchmarkReadWriteMap/frac_10-8 10000000 212 ns/op -``` - -# Node Pooling - -Command used - -``` -rm -Rf tmp && /usr/bin/time -l ./populate -keys_mil 10 -``` - -For pprof results, we run without using /usr/bin/time. There are four runs below. - -Results seem to vary quite a bit between runs. - -## Before node pooling - -``` -1311.53MB of 1338.69MB total (97.97%) -Dropped 30 nodes (cum <= 6.69MB) -Showing top 10 nodes out of 37 (cum >= 12.50MB) - flat flat% sum% cum cum% - 523.04MB 39.07% 39.07% 523.04MB 39.07% github.com/dgraph-io/badger/skl.(*Skiplist).Put - 184.51MB 13.78% 52.85% 184.51MB 13.78% runtime.stringtoslicebyte - 166.01MB 12.40% 65.25% 689.04MB 51.47% github.com/dgraph-io/badger/mem.(*Table).Put - 165MB 12.33% 77.58% 165MB 12.33% runtime.convT2E - 116.92MB 8.73% 86.31% 116.92MB 8.73% bytes.makeSlice - 62.50MB 4.67% 90.98% 62.50MB 4.67% main.newValue - 34.50MB 2.58% 93.56% 34.50MB 2.58% github.com/dgraph-io/badger/table.(*BlockIterator).parseKV - 25.50MB 1.90% 95.46% 100.06MB 7.47% github.com/dgraph-io/badger/y.(*MergeIterator).Next - 21.06MB 1.57% 97.04% 21.06MB 1.57% github.com/dgraph-io/badger/table.(*Table).read - 12.50MB 0.93% 97.97% 12.50MB 0.93% github.com/dgraph-io/badger/table.header.Encode - - 128.31 real 329.37 user 17.11 sys -3355660288 maximum resident set size - 0 average shared memory size - 0 average unshared data size - 0 average unshared stack size - 2203080 page reclaims - 764 page faults - 0 swaps - 275 block input operations - 76 block output operations - 0 messages sent - 0 messages received - 0 signals received - 49173 voluntary context switches - 599922 involuntary context switches -``` - -## After node pooling - -``` -1963.13MB of 2026.09MB total (96.89%) -Dropped 29 nodes (cum <= 10.13MB) -Showing top 10 nodes out of 41 (cum >= 185.62MB) - flat flat% sum% cum cum% - 658.05MB 32.48% 32.48% 658.05MB 32.48% github.com/dgraph-io/badger/skl.glob..func1 - 297.51MB 14.68% 47.16% 297.51MB 14.68% runtime.convT2E - 257.51MB 12.71% 59.87% 257.51MB 12.71% runtime.stringtoslicebyte - 249.01MB 12.29% 72.16% 1007.06MB 49.70% github.com/dgraph-io/badger/mem.(*Table).Put - 142.43MB 7.03% 79.19% 142.43MB 7.03% bytes.makeSlice - 100MB 4.94% 84.13% 758.05MB 37.41% github.com/dgraph-io/badger/skl.newNode - 99.50MB 4.91% 89.04% 99.50MB 4.91% main.newValue - 75MB 3.70% 92.74% 75MB 3.70% github.com/dgraph-io/badger/table.(*BlockIterator).parseKV - 44.62MB 2.20% 94.94% 44.62MB 2.20% github.com/dgraph-io/badger/table.(*Table).read - 39.50MB 1.95% 96.89% 185.62MB 9.16% github.com/dgraph-io/badger/y.(*MergeIterator).Next - - 135.58 real 374.29 user 17.65 sys -3740614656 maximum resident set size - 0 average shared memory size - 0 average unshared data size - 0 average unshared stack size - 2276566 page reclaims - 770 page faults - 0 swaps - 128 block input operations - 90 block output operations - 0 messages sent - 0 messages received - 0 signals received - 46434 voluntary context switches - 597049 involuntary context switches -``` \ No newline at end of file diff --git a/vendor/github.com/dgraph-io/badger/skl/arena.go b/vendor/github.com/dgraph-io/badger/skl/arena.go deleted file mode 100644 index def5507..0000000 --- a/vendor/github.com/dgraph-io/badger/skl/arena.go +++ /dev/null @@ -1,136 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package skl - -import ( - "sync/atomic" - "unsafe" - - "github.com/dgraph-io/badger/y" -) - -const ( - offsetSize = int(unsafe.Sizeof(uint32(0))) - - // Always align nodes on 64-bit boundaries, even on 32-bit architectures, - // so that the node.value field is 64-bit aligned. This is necessary because - // node.getValueOffset uses atomic.LoadUint64, which expects its input - // pointer to be 64-bit aligned. - nodeAlign = int(unsafe.Sizeof(uint64(0))) - 1 -) - -// Arena should be lock-free. -type Arena struct { - n uint32 - buf []byte -} - -// newArena returns a new arena. -func newArena(n int64) *Arena { - // Don't store data at position 0 in order to reserve offset=0 as a kind - // of nil pointer. - out := &Arena{ - n: 1, - buf: make([]byte, n), - } - return out -} - -func (s *Arena) size() int64 { - return int64(atomic.LoadUint32(&s.n)) -} - -func (s *Arena) reset() { - atomic.StoreUint32(&s.n, 0) -} - -// putNode allocates a node in the arena. The node is aligned on a pointer-sized -// boundary. The arena offset of the node is returned. -func (s *Arena) putNode(height int) uint32 { - // Compute the amount of the tower that will never be used, since the height - // is less than maxHeight. - unusedSize := (maxHeight - height) * offsetSize - - // Pad the allocation with enough bytes to ensure pointer alignment. - l := uint32(MaxNodeSize - unusedSize + nodeAlign) - n := atomic.AddUint32(&s.n, l) - y.AssertTruef(int(n) <= len(s.buf), - "Arena too small, toWrite:%d newTotal:%d limit:%d", - l, n, len(s.buf)) - - // Return the aligned offset. - m := (n - l + uint32(nodeAlign)) & ^uint32(nodeAlign) - return m -} - -// Put will *copy* val into arena. To make better use of this, reuse your input -// val buffer. Returns an offset into buf. User is responsible for remembering -// size of val. We could also store this size inside arena but the encoding and -// decoding will incur some overhead. -func (s *Arena) putVal(v y.ValueStruct) uint32 { - l := uint32(v.EncodedSize()) - n := atomic.AddUint32(&s.n, l) - y.AssertTruef(int(n) <= len(s.buf), - "Arena too small, toWrite:%d newTotal:%d limit:%d", - l, n, len(s.buf)) - m := n - l - v.Encode(s.buf[m:]) - return m -} - -func (s *Arena) putKey(key []byte) uint32 { - l := uint32(len(key)) - n := atomic.AddUint32(&s.n, l) - y.AssertTruef(int(n) <= len(s.buf), - "Arena too small, toWrite:%d newTotal:%d limit:%d", - l, n, len(s.buf)) - m := n - l - y.AssertTrue(len(key) == copy(s.buf[m:n], key)) - return m -} - -// getNode returns a pointer to the node located at offset. If the offset is -// zero, then the nil node pointer is returned. -func (s *Arena) getNode(offset uint32) *node { - if offset == 0 { - return nil - } - - return (*node)(unsafe.Pointer(&s.buf[offset])) -} - -// getKey returns byte slice at offset. -func (s *Arena) getKey(offset uint32, size uint16) []byte { - return s.buf[offset : offset+uint32(size)] -} - -// getVal returns byte slice at offset. The given size should be just the value -// size and should NOT include the meta bytes. -func (s *Arena) getVal(offset uint32, size uint16) (ret y.ValueStruct) { - ret.Decode(s.buf[offset : offset+uint32(size)]) - return -} - -// getNodeOffset returns the offset of node in the arena. If the node pointer is -// nil, then the zero offset is returned. -func (s *Arena) getNodeOffset(nd *node) uint32 { - if nd == nil { - return 0 - } - - return uint32(uintptr(unsafe.Pointer(nd)) - uintptr(unsafe.Pointer(&s.buf[0]))) -} diff --git a/vendor/github.com/dgraph-io/badger/skl/skl.go b/vendor/github.com/dgraph-io/badger/skl/skl.go deleted file mode 100644 index b465b09..0000000 --- a/vendor/github.com/dgraph-io/badger/skl/skl.go +++ /dev/null @@ -1,516 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/* -Adapted from RocksDB inline skiplist. - -Key differences: -- No optimization for sequential inserts (no "prev"). -- No custom comparator. -- Support overwrites. This requires care when we see the same key when inserting. - For RocksDB or LevelDB, overwrites are implemented as a newer sequence number in the key, so - there is no need for values. We don't intend to support versioning. In-place updates of values - would be more efficient. -- We discard all non-concurrent code. -- We do not support Splices. This simplifies the code a lot. -- No AllocateNode or other pointer arithmetic. -- We combine the findLessThan, findGreaterOrEqual, etc into one function. -*/ - -package skl - -import ( - "math" - "math/rand" - "sync/atomic" - "unsafe" - - "github.com/dgraph-io/badger/y" -) - -const ( - maxHeight = 20 - heightIncrease = math.MaxUint32 / 3 -) - -// MaxNodeSize is the memory footprint of a node of maximum height. -const MaxNodeSize = int(unsafe.Sizeof(node{})) - -type node struct { - // Multiple parts of the value are encoded as a single uint64 so that it - // can be atomically loaded and stored: - // value offset: uint32 (bits 0-31) - // value size : uint16 (bits 32-47) - value uint64 - - // A byte slice is 24 bytes. We are trying to save space here. - keyOffset uint32 // Immutable. No need to lock to access key. - keySize uint16 // Immutable. No need to lock to access key. - - // Height of the tower. - height uint16 - - // Most nodes do not need to use the full height of the tower, since the - // probability of each successive level decreases exponentially. Because - // these elements are never accessed, they do not need to be allocated. - // Therefore, when a node is allocated in the arena, its memory footprint - // is deliberately truncated to not include unneeded tower elements. - // - // All accesses to elements should use CAS operations, with no need to lock. - tower [maxHeight]uint32 -} - -// Skiplist maps keys to values (in memory) -type Skiplist struct { - height int32 // Current height. 1 <= height <= kMaxHeight. CAS. - head *node - ref int32 - arena *Arena -} - -// IncrRef increases the refcount -func (s *Skiplist) IncrRef() { - atomic.AddInt32(&s.ref, 1) -} - -// DecrRef decrements the refcount, deallocating the Skiplist when done using it -func (s *Skiplist) DecrRef() { - newRef := atomic.AddInt32(&s.ref, -1) - if newRef > 0 { - return - } - - s.arena.reset() - // Indicate we are closed. Good for testing. Also, lets GC reclaim memory. Race condition - // here would suggest we are accessing skiplist when we are supposed to have no reference! - s.arena = nil -} - -func (s *Skiplist) valid() bool { return s.arena != nil } - -func newNode(arena *Arena, key []byte, v y.ValueStruct, height int) *node { - // The base level is already allocated in the node struct. - offset := arena.putNode(height) - node := arena.getNode(offset) - node.keyOffset = arena.putKey(key) - node.keySize = uint16(len(key)) - node.height = uint16(height) - node.value = encodeValue(arena.putVal(v), v.EncodedSize()) - return node -} - -func encodeValue(valOffset uint32, valSize uint16) uint64 { - return uint64(valSize)<<32 | uint64(valOffset) -} - -func decodeValue(value uint64) (valOffset uint32, valSize uint16) { - valOffset = uint32(value) - valSize = uint16(value >> 32) - return -} - -// NewSkiplist makes a new empty skiplist, with a given arena size -func NewSkiplist(arenaSize int64) *Skiplist { - arena := newArena(arenaSize) - head := newNode(arena, nil, y.ValueStruct{}, maxHeight) - return &Skiplist{ - height: 1, - head: head, - arena: arena, - ref: 1, - } -} - -func (s *node) getValueOffset() (uint32, uint16) { - value := atomic.LoadUint64(&s.value) - return decodeValue(value) -} - -func (s *node) key(arena *Arena) []byte { - return arena.getKey(s.keyOffset, s.keySize) -} - -func (s *node) setValue(arena *Arena, v y.ValueStruct) { - valOffset := arena.putVal(v) - value := encodeValue(valOffset, v.EncodedSize()) - atomic.StoreUint64(&s.value, value) -} - -func (s *node) getNextOffset(h int) uint32 { - return atomic.LoadUint32(&s.tower[h]) -} - -func (s *node) casNextOffset(h int, old, val uint32) bool { - return atomic.CompareAndSwapUint32(&s.tower[h], old, val) -} - -// Returns true if key is strictly > n.key. -// If n is nil, this is an "end" marker and we return false. -//func (s *Skiplist) keyIsAfterNode(key []byte, n *node) bool { -// y.AssertTrue(n != s.head) -// return n != nil && y.CompareKeys(key, n.key) > 0 -//} - -func randomHeight() int { - h := 1 - for h < maxHeight && rand.Uint32() <= heightIncrease { - h++ - } - return h -} - -func (s *Skiplist) getNext(nd *node, height int) *node { - return s.arena.getNode(nd.getNextOffset(height)) -} - -// findNear finds the node near to key. -// If less=true, it finds rightmost node such that node.key < key (if allowEqual=false) or -// node.key <= key (if allowEqual=true). -// If less=false, it finds leftmost node such that node.key > key (if allowEqual=false) or -// node.key >= key (if allowEqual=true). -// Returns the node found. The bool returned is true if the node has key equal to given key. -func (s *Skiplist) findNear(key []byte, less bool, allowEqual bool) (*node, bool) { - x := s.head - level := int(s.getHeight() - 1) - for { - // Assume x.key < key. - next := s.getNext(x, level) - if next == nil { - // x.key < key < END OF LIST - if level > 0 { - // Can descend further to iterate closer to the end. - level-- - continue - } - // Level=0. Cannot descend further. Let's return something that makes sense. - if !less { - return nil, false - } - // Try to return x. Make sure it is not a head node. - if x == s.head { - return nil, false - } - return x, false - } - - nextKey := next.key(s.arena) - cmp := y.CompareKeys(key, nextKey) - if cmp > 0 { - // x.key < next.key < key. We can continue to move right. - x = next - continue - } - if cmp == 0 { - // x.key < key == next.key. - if allowEqual { - return next, true - } - if !less { - // We want >, so go to base level to grab the next bigger note. - return s.getNext(next, 0), false - } - // We want <. If not base level, we should go closer in the next level. - if level > 0 { - level-- - continue - } - // On base level. Return x. - if x == s.head { - return nil, false - } - return x, false - } - // cmp < 0. In other words, x.key < key < next. - if level > 0 { - level-- - continue - } - // At base level. Need to return something. - if !less { - return next, false - } - // Try to return x. Make sure it is not a head node. - if x == s.head { - return nil, false - } - return x, false - } -} - -// findSpliceForLevel returns (outBefore, outAfter) with outBefore.key <= key <= outAfter.key. -// The input "before" tells us where to start looking. -// If we found a node with the same key, then we return outBefore = outAfter. -// Otherwise, outBefore.key < key < outAfter.key. -func (s *Skiplist) findSpliceForLevel(key []byte, before *node, level int) (*node, *node) { - for { - // Assume before.key < key. - next := s.getNext(before, level) - if next == nil { - return before, next - } - nextKey := next.key(s.arena) - cmp := y.CompareKeys(key, nextKey) - if cmp == 0 { - // Equality case. - return next, next - } - if cmp < 0 { - // before.key < key < next.key. We are done for this level. - return before, next - } - before = next // Keep moving right on this level. - } -} - -func (s *Skiplist) getHeight() int32 { - return atomic.LoadInt32(&s.height) -} - -// Put inserts the key-value pair. -func (s *Skiplist) Put(key []byte, v y.ValueStruct) { - // Since we allow overwrite, we may not need to create a new node. We might not even need to - // increase the height. Let's defer these actions. - - listHeight := s.getHeight() - var prev [maxHeight + 1]*node - var next [maxHeight + 1]*node - prev[listHeight] = s.head - next[listHeight] = nil - for i := int(listHeight) - 1; i >= 0; i-- { - // Use higher level to speed up for current level. - prev[i], next[i] = s.findSpliceForLevel(key, prev[i+1], i) - if prev[i] == next[i] { - prev[i].setValue(s.arena, v) - return - } - } - - // We do need to create a new node. - height := randomHeight() - x := newNode(s.arena, key, v, height) - - // Try to increase s.height via CAS. - listHeight = s.getHeight() - for height > int(listHeight) { - if atomic.CompareAndSwapInt32(&s.height, listHeight, int32(height)) { - // Successfully increased skiplist.height. - break - } - listHeight = s.getHeight() - } - - // We always insert from the base level and up. After you add a node in base level, we cannot - // create a node in the level above because it would have discovered the node in the base level. - for i := 0; i < height; i++ { - for { - if prev[i] == nil { - y.AssertTrue(i > 1) // This cannot happen in base level. - // We haven't computed prev, next for this level because height exceeds old listHeight. - // For these levels, we expect the lists to be sparse, so we can just search from head. - prev[i], next[i] = s.findSpliceForLevel(key, s.head, i) - // Someone adds the exact same key before we are able to do so. This can only happen on - // the base level. But we know we are not on the base level. - y.AssertTrue(prev[i] != next[i]) - } - nextOffset := s.arena.getNodeOffset(next[i]) - x.tower[i] = nextOffset - if prev[i].casNextOffset(i, nextOffset, s.arena.getNodeOffset(x)) { - // Managed to insert x between prev[i] and next[i]. Go to the next level. - break - } - // CAS failed. We need to recompute prev and next. - // It is unlikely to be helpful to try to use a different level as we redo the search, - // because it is unlikely that lots of nodes are inserted between prev[i] and next[i]. - prev[i], next[i] = s.findSpliceForLevel(key, prev[i], i) - if prev[i] == next[i] { - y.AssertTruef(i == 0, "Equality can happen only on base level: %d", i) - prev[i].setValue(s.arena, v) - return - } - } - } -} - -// Empty returns if the Skiplist is empty. -func (s *Skiplist) Empty() bool { - return s.findLast() == nil -} - -// findLast returns the last element. If head (empty list), we return nil. All the find functions -// will NEVER return the head nodes. -func (s *Skiplist) findLast() *node { - n := s.head - level := int(s.getHeight()) - 1 - for { - next := s.getNext(n, level) - if next != nil { - n = next - continue - } - if level == 0 { - if n == s.head { - return nil - } - return n - } - level-- - } -} - -// Get gets the value associated with the key. It returns a valid value if it finds equal or earlier -// version of the same key. -func (s *Skiplist) Get(key []byte) y.ValueStruct { - n, _ := s.findNear(key, false, true) // findGreaterOrEqual. - if n == nil { - return y.ValueStruct{} - } - - nextKey := s.arena.getKey(n.keyOffset, n.keySize) - if !y.SameKey(key, nextKey) { - return y.ValueStruct{} - } - - valOffset, valSize := n.getValueOffset() - vs := s.arena.getVal(valOffset, valSize) - vs.Version = y.ParseTs(nextKey) - return vs -} - -// NewIterator returns a skiplist iterator. You have to Close() the iterator. -func (s *Skiplist) NewIterator() *Iterator { - s.IncrRef() - return &Iterator{list: s} -} - -// MemSize returns the size of the Skiplist in terms of how much memory is used within its internal -// arena. -func (s *Skiplist) MemSize() int64 { return s.arena.size() } - -// Iterator is an iterator over skiplist object. For new objects, you just -// need to initialize Iterator.list. -type Iterator struct { - list *Skiplist - n *node -} - -// Close frees the resources held by the iterator -func (s *Iterator) Close() error { - s.list.DecrRef() - return nil -} - -// Valid returns true iff the iterator is positioned at a valid node. -func (s *Iterator) Valid() bool { return s.n != nil } - -// Key returns the key at the current position. -func (s *Iterator) Key() []byte { - return s.list.arena.getKey(s.n.keyOffset, s.n.keySize) -} - -// Value returns value. -func (s *Iterator) Value() y.ValueStruct { - valOffset, valSize := s.n.getValueOffset() - return s.list.arena.getVal(valOffset, valSize) -} - -// Next advances to the next position. -func (s *Iterator) Next() { - y.AssertTrue(s.Valid()) - s.n = s.list.getNext(s.n, 0) -} - -// Prev advances to the previous position. -func (s *Iterator) Prev() { - y.AssertTrue(s.Valid()) - s.n, _ = s.list.findNear(s.Key(), true, false) // find <. No equality allowed. -} - -// Seek advances to the first entry with a key >= target. -func (s *Iterator) Seek(target []byte) { - s.n, _ = s.list.findNear(target, false, true) // find >=. -} - -// SeekForPrev finds an entry with key <= target. -func (s *Iterator) SeekForPrev(target []byte) { - s.n, _ = s.list.findNear(target, true, true) // find <=. -} - -// SeekToFirst seeks position at the first entry in list. -// Final state of iterator is Valid() iff list is not empty. -func (s *Iterator) SeekToFirst() { - s.n = s.list.getNext(s.list.head, 0) -} - -// SeekToLast seeks position at the last entry in list. -// Final state of iterator is Valid() iff list is not empty. -func (s *Iterator) SeekToLast() { - s.n = s.list.findLast() -} - -// UniIterator is a unidirectional memtable iterator. It is a thin wrapper around -// Iterator. We like to keep Iterator as before, because it is more powerful and -// we might support bidirectional iterators in the future. -type UniIterator struct { - iter *Iterator - reversed bool -} - -// NewUniIterator returns a UniIterator. -func (s *Skiplist) NewUniIterator(reversed bool) *UniIterator { - return &UniIterator{ - iter: s.NewIterator(), - reversed: reversed, - } -} - -// Next implements y.Interface -func (s *UniIterator) Next() { - if !s.reversed { - s.iter.Next() - } else { - s.iter.Prev() - } -} - -// Rewind implements y.Interface -func (s *UniIterator) Rewind() { - if !s.reversed { - s.iter.SeekToFirst() - } else { - s.iter.SeekToLast() - } -} - -// Seek implements y.Interface -func (s *UniIterator) Seek(key []byte) { - if !s.reversed { - s.iter.Seek(key) - } else { - s.iter.SeekForPrev(key) - } -} - -// Key implements y.Interface -func (s *UniIterator) Key() []byte { return s.iter.Key() } - -// Value implements y.Interface -func (s *UniIterator) Value() y.ValueStruct { return s.iter.Value() } - -// Valid implements y.Interface -func (s *UniIterator) Valid() bool { return s.iter.Valid() } - -// Close implements y.Interface (and frees up the iter's resources) -func (s *UniIterator) Close() error { return s.iter.Close() } diff --git a/vendor/github.com/dgraph-io/badger/skl/skl_test.go b/vendor/github.com/dgraph-io/badger/skl/skl_test.go deleted file mode 100644 index d50e304..0000000 --- a/vendor/github.com/dgraph-io/badger/skl/skl_test.go +++ /dev/null @@ -1,475 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package skl - -import ( - "encoding/binary" - "fmt" - "math/rand" - "strconv" - "sync" - "sync/atomic" - "testing" - "time" - - "github.com/stretchr/testify/require" - - "github.com/dgraph-io/badger/y" -) - -const arenaSize = 1 << 20 - -func newValue(v int) []byte { - return []byte(fmt.Sprintf("%05d", v)) -} - -// length iterates over skiplist to give exact size. -func length(s *Skiplist) int { - x := s.getNext(s.head, 0) - count := 0 - for x != nil { - count++ - x = s.getNext(x, 0) - } - return count -} - -func TestEmpty(t *testing.T) { - key := []byte("aaa") - l := NewSkiplist(arenaSize) - - v := l.Get(key) - require.True(t, v.Value == nil) // Cannot use require.Nil for unsafe.Pointer nil. - - for _, less := range []bool{true, false} { - for _, allowEqual := range []bool{true, false} { - n, found := l.findNear(key, less, allowEqual) - require.Nil(t, n) - require.False(t, found) - } - } - - it := l.NewIterator() - require.False(t, it.Valid()) - - it.SeekToFirst() - require.False(t, it.Valid()) - - it.SeekToLast() - require.False(t, it.Valid()) - - it.Seek(key) - require.False(t, it.Valid()) - - l.DecrRef() - require.True(t, l.valid()) // Check the reference counting. - - it.Close() - require.False(t, l.valid()) // Check the reference counting. -} - -// TestBasic tests single-threaded inserts and updates and gets. -func TestBasic(t *testing.T) { - l := NewSkiplist(arenaSize) - val1 := newValue(42) - val2 := newValue(52) - val3 := newValue(62) - val4 := newValue(72) - - // Try inserting values. - // Somehow require.Nil doesn't work when checking for unsafe.Pointer(nil). - l.Put(y.KeyWithTs([]byte("key1"), 0), y.ValueStruct{Value: val1, Meta: 55, UserMeta: 0}) - l.Put(y.KeyWithTs([]byte("key2"), 2), y.ValueStruct{Value: val2, Meta: 56, UserMeta: 0}) - l.Put(y.KeyWithTs([]byte("key3"), 0), y.ValueStruct{Value: val3, Meta: 57, UserMeta: 0}) - - v := l.Get(y.KeyWithTs([]byte("key"), 0)) - require.True(t, v.Value == nil) - - v = l.Get(y.KeyWithTs([]byte("key1"), 0)) - require.True(t, v.Value != nil) - require.EqualValues(t, "00042", string(v.Value)) - require.EqualValues(t, 55, v.Meta) - - v = l.Get(y.KeyWithTs([]byte("key2"), 0)) - require.True(t, v.Value == nil) - - v = l.Get(y.KeyWithTs([]byte("key3"), 0)) - require.True(t, v.Value != nil) - require.EqualValues(t, "00062", string(v.Value)) - require.EqualValues(t, 57, v.Meta) - - l.Put(y.KeyWithTs([]byte("key3"), 1), y.ValueStruct{Value: val4, Meta: 12, UserMeta: 0}) - v = l.Get(y.KeyWithTs([]byte("key3"), 1)) - require.True(t, v.Value != nil) - require.EqualValues(t, "00072", string(v.Value)) - require.EqualValues(t, 12, v.Meta) -} - -// TestConcurrentBasic tests concurrent writes followed by concurrent reads. -func TestConcurrentBasic(t *testing.T) { - const n = 1000 - l := NewSkiplist(arenaSize) - var wg sync.WaitGroup - key := func(i int) []byte { - return y.KeyWithTs([]byte(fmt.Sprintf("%05d", i)), 0) - } - for i := 0; i < n; i++ { - wg.Add(1) - go func(i int) { - defer wg.Done() - l.Put(key(i), - y.ValueStruct{Value: newValue(i), Meta: 0, UserMeta: 0}) - }(i) - } - wg.Wait() - // Check values. Concurrent reads. - for i := 0; i < n; i++ { - wg.Add(1) - go func(i int) { - defer wg.Done() - v := l.Get(key(i)) - require.True(t, v.Value != nil) - require.EqualValues(t, newValue(i), v.Value) - }(i) - } - wg.Wait() - require.EqualValues(t, n, length(l)) -} - -// TestOneKey will read while writing to one single key. -func TestOneKey(t *testing.T) { - const n = 100 - key := y.KeyWithTs([]byte("thekey"), 0) - l := NewSkiplist(arenaSize) - defer l.DecrRef() - - var wg sync.WaitGroup - for i := 0; i < n; i++ { - wg.Add(1) - go func(i int) { - defer wg.Done() - l.Put(key, y.ValueStruct{Value: newValue(i), Meta: 0, UserMeta: 0}) - }(i) - } - // We expect that at least some write made it such that some read returns a value. - var sawValue int32 - for i := 0; i < n; i++ { - wg.Add(1) - go func() { - defer wg.Done() - p := l.Get(key) - if p.Value == nil { - return - } - atomic.StoreInt32(&sawValue, 1) - v, err := strconv.Atoi(string(p.Value)) - require.NoError(t, err) - require.True(t, 0 <= v && v < n) - }() - } - wg.Wait() - require.True(t, sawValue > 0) - require.EqualValues(t, 1, length(l)) -} - -func TestFindNear(t *testing.T) { - l := NewSkiplist(arenaSize) - defer l.DecrRef() - for i := 0; i < 1000; i++ { - key := fmt.Sprintf("%05d", i*10+5) - l.Put(y.KeyWithTs([]byte(key), 0), y.ValueStruct{Value: newValue(i), Meta: 0, UserMeta: 0}) - } - - n, eq := l.findNear(y.KeyWithTs([]byte("00001"), 0), false, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("00005"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("00001"), 0), false, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("00005"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("00001"), 0), true, false) - require.Nil(t, n) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("00001"), 0), true, true) - require.Nil(t, n) - require.False(t, eq) - - n, eq = l.findNear(y.KeyWithTs([]byte("00005"), 0), false, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("00015"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("00005"), 0), false, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("00005"), 0), string(n.key(l.arena))) - require.True(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("00005"), 0), true, false) - require.Nil(t, n) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("00005"), 0), true, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("00005"), 0), string(n.key(l.arena))) - require.True(t, eq) - - n, eq = l.findNear(y.KeyWithTs([]byte("05555"), 0), false, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05565"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("05555"), 0), false, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05555"), 0), string(n.key(l.arena))) - require.True(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("05555"), 0), true, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05545"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("05555"), 0), true, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05555"), 0), string(n.key(l.arena))) - require.True(t, eq) - - n, eq = l.findNear(y.KeyWithTs([]byte("05558"), 0), false, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05565"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("05558"), 0), false, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05565"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("05558"), 0), true, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05555"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("05558"), 0), true, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("05555"), 0), string(n.key(l.arena))) - require.False(t, eq) - - n, eq = l.findNear(y.KeyWithTs([]byte("09995"), 0), false, false) - require.Nil(t, n) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("09995"), 0), false, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("09995"), 0), string(n.key(l.arena))) - require.True(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("09995"), 0), true, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("09985"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("09995"), 0), true, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("09995"), 0), string(n.key(l.arena))) - require.True(t, eq) - - n, eq = l.findNear(y.KeyWithTs([]byte("59995"), 0), false, false) - require.Nil(t, n) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("59995"), 0), false, true) - require.Nil(t, n) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("59995"), 0), true, false) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("09995"), 0), string(n.key(l.arena))) - require.False(t, eq) - n, eq = l.findNear(y.KeyWithTs([]byte("59995"), 0), true, true) - require.NotNil(t, n) - require.EqualValues(t, y.KeyWithTs([]byte("09995"), 0), string(n.key(l.arena))) - require.False(t, eq) -} - -// TestIteratorNext tests a basic iteration over all nodes from the beginning. -func TestIteratorNext(t *testing.T) { - const n = 100 - l := NewSkiplist(arenaSize) - defer l.DecrRef() - it := l.NewIterator() - defer it.Close() - require.False(t, it.Valid()) - it.SeekToFirst() - require.False(t, it.Valid()) - for i := n - 1; i >= 0; i-- { - l.Put(y.KeyWithTs([]byte(fmt.Sprintf("%05d", i)), 0), - y.ValueStruct{Value: newValue(i), Meta: 0, UserMeta: 0}) - } - it.SeekToFirst() - for i := 0; i < n; i++ { - require.True(t, it.Valid()) - v := it.Value() - require.EqualValues(t, newValue(i), v.Value) - it.Next() - } - require.False(t, it.Valid()) -} - -// TestIteratorPrev tests a basic iteration over all nodes from the end. -func TestIteratorPrev(t *testing.T) { - const n = 100 - l := NewSkiplist(arenaSize) - defer l.DecrRef() - it := l.NewIterator() - defer it.Close() - require.False(t, it.Valid()) - it.SeekToFirst() - require.False(t, it.Valid()) - for i := 0; i < n; i++ { - l.Put(y.KeyWithTs([]byte(fmt.Sprintf("%05d", i)), 0), - y.ValueStruct{Value: newValue(i), Meta: 0, UserMeta: 0}) - } - it.SeekToLast() - for i := n - 1; i >= 0; i-- { - require.True(t, it.Valid()) - v := it.Value() - require.EqualValues(t, newValue(i), v.Value) - it.Prev() - } - require.False(t, it.Valid()) -} - -// TestIteratorSeek tests Seek and SeekForPrev. -func TestIteratorSeek(t *testing.T) { - const n = 100 - l := NewSkiplist(arenaSize) - defer l.DecrRef() - - it := l.NewIterator() - defer it.Close() - - require.False(t, it.Valid()) - it.SeekToFirst() - require.False(t, it.Valid()) - // 1000, 1010, 1020, ..., 1990. - for i := n - 1; i >= 0; i-- { - v := i*10 + 1000 - l.Put(y.KeyWithTs([]byte(fmt.Sprintf("%05d", i*10+1000)), 0), - y.ValueStruct{Value: newValue(v), Meta: 0, UserMeta: 0}) - } - it.SeekToFirst() - require.True(t, it.Valid()) - v := it.Value() - require.EqualValues(t, "01000", v.Value) - - it.Seek(y.KeyWithTs([]byte("01000"), 0)) - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, "01000", v.Value) - - it.Seek(y.KeyWithTs([]byte("01005"), 0)) - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, "01010", v.Value) - - it.Seek(y.KeyWithTs([]byte("01010"), 0)) - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, "01010", v.Value) - - it.Seek(y.KeyWithTs([]byte("99999"), 0)) - require.False(t, it.Valid()) - - // Try SeekForPrev. - it.SeekForPrev(y.KeyWithTs([]byte("00"), 0)) - require.False(t, it.Valid()) - - it.SeekForPrev(y.KeyWithTs([]byte("01000"), 0)) - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, "01000", v.Value) - - it.SeekForPrev(y.KeyWithTs([]byte("01005"), 0)) - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, "01000", v.Value) - - it.SeekForPrev(y.KeyWithTs([]byte("01010"), 0)) - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, "01010", v.Value) - - it.SeekForPrev(y.KeyWithTs([]byte("99999"), 0)) - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, "01990", v.Value) -} - -func randomKey(rng *rand.Rand) []byte { - b := make([]byte, 8) - key := rng.Uint32() - key2 := rng.Uint32() - binary.LittleEndian.PutUint32(b, key) - binary.LittleEndian.PutUint32(b[4:], key2) - return y.KeyWithTs(b, 0) -} - -// Standard test. Some fraction is read. Some fraction is write. Writes have -// to go through mutex lock. -func BenchmarkReadWrite(b *testing.B) { - value := newValue(123) - for i := 0; i <= 10; i++ { - readFrac := float32(i) / 10.0 - b.Run(fmt.Sprintf("frac_%d", i), func(b *testing.B) { - l := NewSkiplist(int64((b.N + 1) * MaxNodeSize)) - defer l.DecrRef() - b.ResetTimer() - var count int - b.RunParallel(func(pb *testing.PB) { - rng := rand.New(rand.NewSource(time.Now().UnixNano())) - for pb.Next() { - if rng.Float32() < readFrac { - v := l.Get(randomKey(rng)) - if v.Value != nil { - count++ - } - } else { - l.Put(randomKey(rng), y.ValueStruct{Value: value, Meta: 0, UserMeta: 0}) - } - } - }) - }) - } -} - -// Standard test. Some fraction is read. Some fraction is write. Writes have -// to go through mutex lock. -func BenchmarkReadWriteMap(b *testing.B) { - value := newValue(123) - for i := 0; i <= 10; i++ { - readFrac := float32(i) / 10.0 - b.Run(fmt.Sprintf("frac_%d", i), func(b *testing.B) { - m := make(map[string][]byte) - var mutex sync.RWMutex - b.ResetTimer() - var count int - b.RunParallel(func(pb *testing.PB) { - rng := rand.New(rand.NewSource(time.Now().UnixNano())) - for pb.Next() { - if rand.Float32() < readFrac { - mutex.RLock() - _, ok := m[string(randomKey(rng))] - mutex.RUnlock() - if ok { - count++ - } - } else { - mutex.Lock() - m[string(randomKey(rng))] = value - mutex.Unlock() - } - } - }) - }) - } -} diff --git a/vendor/github.com/dgraph-io/badger/structs.go b/vendor/github.com/dgraph-io/badger/structs.go deleted file mode 100644 index 09547a4..0000000 --- a/vendor/github.com/dgraph-io/badger/structs.go +++ /dev/null @@ -1,132 +0,0 @@ -package badger - -import ( - "bytes" - "encoding/binary" - "fmt" - "hash/crc32" - - "github.com/dgraph-io/badger/y" -) - -type valuePointer struct { - Fid uint32 - Len uint32 - Offset uint32 -} - -func (p valuePointer) Less(o valuePointer) bool { - if p.Fid != o.Fid { - return p.Fid < o.Fid - } - if p.Offset != o.Offset { - return p.Offset < o.Offset - } - return p.Len < o.Len -} - -func (p valuePointer) IsZero() bool { - return p.Fid == 0 && p.Offset == 0 && p.Len == 0 -} - -const vptrSize = 12 - -// Encode encodes Pointer into byte buffer. -func (p valuePointer) Encode(b []byte) []byte { - binary.BigEndian.PutUint32(b[:4], p.Fid) - binary.BigEndian.PutUint32(b[4:8], p.Len) - binary.BigEndian.PutUint32(b[8:12], p.Offset) - return b[:vptrSize] -} - -func (p *valuePointer) Decode(b []byte) { - p.Fid = binary.BigEndian.Uint32(b[:4]) - p.Len = binary.BigEndian.Uint32(b[4:8]) - p.Offset = binary.BigEndian.Uint32(b[8:12]) -} - -// header is used in value log as a header before Entry. -type header struct { - klen uint32 - vlen uint32 - expiresAt uint64 - meta byte - userMeta byte -} - -const ( - headerBufSize = 18 -) - -func (h header) Encode(out []byte) { - y.AssertTrue(len(out) >= headerBufSize) - binary.BigEndian.PutUint32(out[0:4], h.klen) - binary.BigEndian.PutUint32(out[4:8], h.vlen) - binary.BigEndian.PutUint64(out[8:16], h.expiresAt) - out[16] = h.meta - out[17] = h.userMeta -} - -// Decodes h from buf. -func (h *header) Decode(buf []byte) { - h.klen = binary.BigEndian.Uint32(buf[0:4]) - h.vlen = binary.BigEndian.Uint32(buf[4:8]) - h.expiresAt = binary.BigEndian.Uint64(buf[8:16]) - h.meta = buf[16] - h.userMeta = buf[17] -} - -// Entry provides Key, Value, UserMeta and ExpiresAt. This struct can be used by the user to set data. -type Entry struct { - Key []byte - Value []byte - UserMeta byte - ExpiresAt uint64 // time.Unix - meta byte - - // Fields maintained internally. - offset uint32 -} - -func (e *Entry) estimateSize(threshold int) int { - if len(e.Value) < threshold { - return len(e.Key) + len(e.Value) + 2 // Meta, UserMeta - } - return len(e.Key) + 12 + 2 // 12 for ValuePointer, 2 for metas. -} - -// Encodes e to buf. Returns number of bytes written. -func encodeEntry(e *Entry, buf *bytes.Buffer) (int, error) { - h := header{ - klen: uint32(len(e.Key)), - vlen: uint32(len(e.Value)), - expiresAt: e.ExpiresAt, - meta: e.meta, - userMeta: e.UserMeta, - } - - var headerEnc [headerBufSize]byte - h.Encode(headerEnc[:]) - - hash := crc32.New(y.CastagnoliCrcTable) - - buf.Write(headerEnc[:]) - hash.Write(headerEnc[:]) - - buf.Write(e.Key) - hash.Write(e.Key) - - buf.Write(e.Value) - hash.Write(e.Value) - - var crcBuf [4]byte - binary.BigEndian.PutUint32(crcBuf[:], hash.Sum32()) - buf.Write(crcBuf[:]) - - return len(headerEnc) + len(e.Key) + len(e.Value) + len(crcBuf), nil -} - -func (e Entry) print(prefix string) { - fmt.Printf("%s Key: %s Meta: %d UserMeta: %d Offset: %d len(val)=%d", - prefix, e.Key, e.meta, e.UserMeta, e.offset, len(e.Value)) -} diff --git a/vendor/github.com/dgraph-io/badger/table/README.md b/vendor/github.com/dgraph-io/badger/table/README.md deleted file mode 100644 index 5d33e96..0000000 --- a/vendor/github.com/dgraph-io/badger/table/README.md +++ /dev/null @@ -1,51 +0,0 @@ -# BenchmarkRead - -``` -$ go test -bench Read$ -count 3 - -Size of table: 105843444 -BenchmarkRead-8 3 343846914 ns/op -BenchmarkRead-8 3 351790907 ns/op -BenchmarkRead-8 3 351762823 ns/op -``` - -Size of table is 105,843,444 bytes, which is ~101M. - -The rate is ~287M/s which matches our read speed. This is using mmap. - -To read a 64M table, this would take ~0.22s, which is negligible. - -``` -$ go test -bench BenchmarkReadAndBuild -count 3 - -BenchmarkReadAndBuild-8 1 2341034225 ns/op -BenchmarkReadAndBuild-8 1 2346349671 ns/op -BenchmarkReadAndBuild-8 1 2364064576 ns/op -``` - -The rate is ~43M/s. To build a ~64M table, this would take ~1.5s. Note that this -does NOT include the flushing of the table to disk. All we are doing above is -to read one table (mmaped) and write one table in memory. - -The table building takes 1.5-0.22 ~ 1.3s. - -If we are writing out up to 10 tables, this would take 1.5*10 ~ 15s, and ~13s -is spent building the tables. - -When running populate, building one table in memory tends to take ~1.5s to ~2.5s -on my system. Where does this overhead come from? Let's investigate the merging. - -Below, we merge 5 tables. The total size remains unchanged at ~101M. - -``` -$ go test -bench ReadMerged -count 3 -BenchmarkReadMerged-8 1 1321190264 ns/op -BenchmarkReadMerged-8 1 1296958737 ns/op -BenchmarkReadMerged-8 1 1314381178 ns/op -``` - -The rate is ~76M/s. To build a 64M table, this would take ~0.84s. The writing -takes ~1.3s as we saw above. So in total, we expect around 0.84+1.3 ~ 2.1s. -This roughly matches what we observe when running populate. There might be -some additional overhead due to the concurrent writes going on, in flushing the -table to disk. Also, the tables tend to be slightly bigger than 64M/s. \ No newline at end of file diff --git a/vendor/github.com/dgraph-io/badger/table/builder.go b/vendor/github.com/dgraph-io/badger/table/builder.go deleted file mode 100644 index 43e6562..0000000 --- a/vendor/github.com/dgraph-io/badger/table/builder.go +++ /dev/null @@ -1,235 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package table - -import ( - "bytes" - "encoding/binary" - "io" - "math" - - "github.com/AndreasBriese/bbloom" - "github.com/dgraph-io/badger/y" -) - -var ( - restartInterval = 100 // Might want to change this to be based on total size instead of numKeys. -) - -func newBuffer(sz int) *bytes.Buffer { - b := new(bytes.Buffer) - b.Grow(sz) - return b -} - -type header struct { - plen uint16 // Overlap with base key. - klen uint16 // Length of the diff. - vlen uint16 // Length of value. - prev uint32 // Offset for the previous key-value pair. The offset is relative to block base offset. -} - -// Encode encodes the header. -func (h header) Encode(b []byte) { - binary.BigEndian.PutUint16(b[0:2], h.plen) - binary.BigEndian.PutUint16(b[2:4], h.klen) - binary.BigEndian.PutUint16(b[4:6], h.vlen) - binary.BigEndian.PutUint32(b[6:10], h.prev) -} - -// Decode decodes the header. -func (h *header) Decode(buf []byte) int { - h.plen = binary.BigEndian.Uint16(buf[0:2]) - h.klen = binary.BigEndian.Uint16(buf[2:4]) - h.vlen = binary.BigEndian.Uint16(buf[4:6]) - h.prev = binary.BigEndian.Uint32(buf[6:10]) - return h.Size() -} - -// Size returns size of the header. Currently it's just a constant. -func (h header) Size() int { return 10 } - -// Builder is used in building a table. -type Builder struct { - counter int // Number of keys written for the current block. - - // Typically tens or hundreds of meg. This is for one single file. - buf *bytes.Buffer - - baseKey []byte // Base key for the current block. - baseOffset uint32 // Offset for the current block. - - restarts []uint32 // Base offsets of every block. - - // Tracks offset for the previous key-value pair. Offset is relative to block base offset. - prevOffset uint32 - - keyBuf *bytes.Buffer - keyCount int -} - -// NewTableBuilder makes a new TableBuilder. -func NewTableBuilder() *Builder { - return &Builder{ - keyBuf: newBuffer(1 << 20), - buf: newBuffer(1 << 20), - prevOffset: math.MaxUint32, // Used for the first element! - } -} - -// Close closes the TableBuilder. -func (b *Builder) Close() {} - -// Empty returns whether it's empty. -func (b *Builder) Empty() bool { return b.buf.Len() == 0 } - -// keyDiff returns a suffix of newKey that is different from b.baseKey. -func (b Builder) keyDiff(newKey []byte) []byte { - var i int - for i = 0; i < len(newKey) && i < len(b.baseKey); i++ { - if newKey[i] != b.baseKey[i] { - break - } - } - return newKey[i:] -} - -func (b *Builder) addHelper(key []byte, v y.ValueStruct) { - // Add key to bloom filter. - if len(key) > 0 { - var klen [2]byte - keyNoTs := y.ParseKey(key) - binary.BigEndian.PutUint16(klen[:], uint16(len(keyNoTs))) - b.keyBuf.Write(klen[:]) - b.keyBuf.Write(keyNoTs) - b.keyCount++ - } - - // diffKey stores the difference of key with baseKey. - var diffKey []byte - if len(b.baseKey) == 0 { - // Make a copy. Builder should not keep references. Otherwise, caller has to be very careful - // and will have to make copies of keys every time they add to builder, which is even worse. - b.baseKey = append(b.baseKey[:0], key...) - diffKey = key - } else { - diffKey = b.keyDiff(key) - } - - h := header{ - plen: uint16(len(key) - len(diffKey)), - klen: uint16(len(diffKey)), - vlen: uint16(v.EncodedSize()), - prev: b.prevOffset, // prevOffset is the location of the last key-value added. - } - b.prevOffset = uint32(b.buf.Len()) - b.baseOffset // Remember current offset for the next Add call. - - // Layout: header, diffKey, value. - var hbuf [10]byte - h.Encode(hbuf[:]) - b.buf.Write(hbuf[:]) - b.buf.Write(diffKey) // We only need to store the key difference. - - v.EncodeTo(b.buf) - b.counter++ // Increment number of keys added for this current block. -} - -func (b *Builder) finishBlock() { - // When we are at the end of the block and Valid=false, and the user wants to do a Prev, - // we need a dummy header to tell us the offset of the previous key-value pair. - b.addHelper([]byte{}, y.ValueStruct{}) -} - -// Add adds a key-value pair to the block. -// If doNotRestart is true, we will not restart even if b.counter >= restartInterval. -func (b *Builder) Add(key []byte, value y.ValueStruct) error { - if b.counter >= restartInterval { - b.finishBlock() - // Start a new block. Initialize the block. - b.restarts = append(b.restarts, uint32(b.buf.Len())) - b.counter = 0 - b.baseKey = []byte{} - b.baseOffset = uint32(b.buf.Len()) - b.prevOffset = math.MaxUint32 // First key-value pair of block has header.prev=MaxInt. - } - b.addHelper(key, value) - return nil // Currently, there is no meaningful error. -} - -// TODO: vvv this was the comment on ReachedCapacity. -// FinalSize returns the *rough* final size of the array, counting the header which is not yet written. -// TODO: Look into why there is a discrepancy. I suspect it is because of Write(empty, empty) -// at the end. The diff can vary. - -// ReachedCapacity returns true if we... roughly (?) reached capacity? -func (b *Builder) ReachedCapacity(cap int64) bool { - estimateSz := b.buf.Len() + 8 /* empty header */ + 4*len(b.restarts) + 8 // 8 = end of buf offset + len(restarts). - return int64(estimateSz) > cap -} - -// blockIndex generates the block index for the table. -// It is mainly a list of all the block base offsets. -func (b *Builder) blockIndex() []byte { - // Store the end offset, so we know the length of the final block. - b.restarts = append(b.restarts, uint32(b.buf.Len())) - - // Add 4 because we want to write out number of restarts at the end. - sz := 4*len(b.restarts) + 4 - out := make([]byte, sz) - buf := out - for _, r := range b.restarts { - binary.BigEndian.PutUint32(buf[:4], r) - buf = buf[4:] - } - binary.BigEndian.PutUint32(buf[:4], uint32(len(b.restarts))) - return out -} - -// Finish finishes the table by appending the index. -func (b *Builder) Finish() []byte { - bf := bbloom.New(float64(b.keyCount), 0.01) - var klen [2]byte - key := make([]byte, 1024) - for { - if _, err := b.keyBuf.Read(klen[:]); err == io.EOF { - break - } else if err != nil { - y.Check(err) - } - kl := int(binary.BigEndian.Uint16(klen[:])) - if cap(key) < kl { - key = make([]byte, 2*int(kl)) // 2 * uint16 will overflow - } - key = key[:kl] - y.Check2(b.keyBuf.Read(key)) - bf.Add(key) - } - - b.finishBlock() // This will never start a new block. - index := b.blockIndex() - b.buf.Write(index) - - // Write bloom filter. - bdata := bf.JSONMarshal() - n, err := b.buf.Write(bdata) - y.Check(err) - var buf [4]byte - binary.BigEndian.PutUint32(buf[:], uint32(n)) - b.buf.Write(buf[:]) - - return b.buf.Bytes() -} diff --git a/vendor/github.com/dgraph-io/badger/table/iterator.go b/vendor/github.com/dgraph-io/badger/table/iterator.go deleted file mode 100644 index 0eb5ed0..0000000 --- a/vendor/github.com/dgraph-io/badger/table/iterator.go +++ /dev/null @@ -1,539 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package table - -import ( - "bytes" - "io" - "math" - "sort" - - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" -) - -type blockIterator struct { - data []byte - pos uint32 - err error - baseKey []byte - - key []byte - val []byte - init bool - - last header // The last header we saw. -} - -func (itr *blockIterator) Reset() { - itr.pos = 0 - itr.err = nil - itr.baseKey = []byte{} - itr.key = []byte{} - itr.val = []byte{} - itr.init = false - itr.last = header{} -} - -func (itr *blockIterator) Init() { - if !itr.init { - itr.Next() - } -} - -func (itr *blockIterator) Valid() bool { - return itr != nil && itr.err == nil -} - -func (itr *blockIterator) Error() error { - return itr.err -} - -func (itr *blockIterator) Close() {} - -var ( - origin = 0 - current = 1 -) - -// Seek brings us to the first block element that is >= input key. -func (itr *blockIterator) Seek(key []byte, whence int) { - itr.err = nil - - switch whence { - case origin: - itr.Reset() - case current: - } - - var done bool - for itr.Init(); itr.Valid(); itr.Next() { - k := itr.Key() - if y.CompareKeys(k, key) >= 0 { - // We are done as k is >= key. - done = true - break - } - } - if !done { - itr.err = io.EOF - } -} - -func (itr *blockIterator) SeekToFirst() { - itr.err = nil - itr.Init() -} - -// SeekToLast brings us to the last element. Valid should return true. -func (itr *blockIterator) SeekToLast() { - itr.err = nil - for itr.Init(); itr.Valid(); itr.Next() { - } - itr.Prev() -} - -// parseKV would allocate a new byte slice for key and for value. -func (itr *blockIterator) parseKV(h header) { - if cap(itr.key) < int(h.plen+h.klen) { - sz := int(h.plen) + int(h.klen) // Convert to int before adding to avoid uint16 overflow. - itr.key = make([]byte, 2*sz) - } - itr.key = itr.key[:h.plen+h.klen] - copy(itr.key, itr.baseKey[:h.plen]) - copy(itr.key[h.plen:], itr.data[itr.pos:itr.pos+uint32(h.klen)]) - itr.pos += uint32(h.klen) - - if itr.pos+uint32(h.vlen) > uint32(len(itr.data)) { - itr.err = errors.Errorf("Value exceeded size of block: %d %d %d %d %v", - itr.pos, h.klen, h.vlen, len(itr.data), h) - return - } - itr.val = y.SafeCopy(itr.val, itr.data[itr.pos:itr.pos+uint32(h.vlen)]) - itr.pos += uint32(h.vlen) -} - -func (itr *blockIterator) Next() { - itr.init = true - itr.err = nil - if itr.pos >= uint32(len(itr.data)) { - itr.err = io.EOF - return - } - - var h header - itr.pos += uint32(h.Decode(itr.data[itr.pos:])) - itr.last = h // Store the last header. - - if h.klen == 0 && h.plen == 0 { - // Last entry in the table. - itr.err = io.EOF - return - } - - // Populate baseKey if it isn't set yet. This would only happen for the first Next. - if len(itr.baseKey) == 0 { - // This should be the first Next() for this block. Hence, prefix length should be zero. - y.AssertTrue(h.plen == 0) - itr.baseKey = itr.data[itr.pos : itr.pos+uint32(h.klen)] - } - itr.parseKV(h) -} - -func (itr *blockIterator) Prev() { - if !itr.init { - return - } - itr.err = nil - if itr.last.prev == math.MaxUint32 { - // This is the first element of the block! - itr.err = io.EOF - itr.pos = 0 - return - } - - // Move back using current header's prev. - itr.pos = itr.last.prev - - var h header - y.AssertTruef(itr.pos < uint32(len(itr.data)), "%d %d", itr.pos, len(itr.data)) - itr.pos += uint32(h.Decode(itr.data[itr.pos:])) - itr.parseKV(h) - itr.last = h -} - -func (itr *blockIterator) Key() []byte { - if itr.err != nil { - return nil - } - return itr.key -} - -func (itr *blockIterator) Value() []byte { - if itr.err != nil { - return nil - } - return itr.val -} - -// Iterator is an iterator for a Table. -type Iterator struct { - t *Table - bpos int - bi *blockIterator - err error - - // Internally, Iterator is bidirectional. However, we only expose the - // unidirectional functionality for now. - reversed bool -} - -// NewIterator returns a new iterator of the Table -func (t *Table) NewIterator(reversed bool) *Iterator { - t.IncrRef() // Important. - ti := &Iterator{t: t, reversed: reversed} - ti.next() - return ti -} - -// Close closes the iterator (and it must be called). -func (itr *Iterator) Close() error { - return itr.t.DecrRef() -} - -func (itr *Iterator) reset() { - itr.bpos = 0 - itr.err = nil -} - -// Valid follows the y.Iterator interface -func (itr *Iterator) Valid() bool { - return itr.err == nil -} - -func (itr *Iterator) seekToFirst() { - numBlocks := len(itr.t.blockIndex) - if numBlocks == 0 { - itr.err = io.EOF - return - } - itr.bpos = 0 - block, err := itr.t.block(itr.bpos) - if err != nil { - itr.err = err - return - } - itr.bi = block.NewIterator() - itr.bi.SeekToFirst() - itr.err = itr.bi.Error() -} - -func (itr *Iterator) seekToLast() { - numBlocks := len(itr.t.blockIndex) - if numBlocks == 0 { - itr.err = io.EOF - return - } - itr.bpos = numBlocks - 1 - block, err := itr.t.block(itr.bpos) - if err != nil { - itr.err = err - return - } - itr.bi = block.NewIterator() - itr.bi.SeekToLast() - itr.err = itr.bi.Error() -} - -func (itr *Iterator) seekHelper(blockIdx int, key []byte) { - itr.bpos = blockIdx - block, err := itr.t.block(blockIdx) - if err != nil { - itr.err = err - return - } - itr.bi = block.NewIterator() - itr.bi.Seek(key, origin) - itr.err = itr.bi.Error() -} - -// seekFrom brings us to a key that is >= input key. -func (itr *Iterator) seekFrom(key []byte, whence int) { - itr.err = nil - switch whence { - case origin: - itr.reset() - case current: - } - - idx := sort.Search(len(itr.t.blockIndex), func(idx int) bool { - ko := itr.t.blockIndex[idx] - return y.CompareKeys(ko.key, key) > 0 - }) - if idx == 0 { - // The smallest key in our table is already strictly > key. We can return that. - // This is like a SeekToFirst. - itr.seekHelper(0, key) - return - } - - // block[idx].smallest is > key. - // Since idx>0, we know block[idx-1].smallest is <= key. - // There are two cases. - // 1) Everything in block[idx-1] is strictly < key. In this case, we should go to the first - // element of block[idx]. - // 2) Some element in block[idx-1] is >= key. We should go to that element. - itr.seekHelper(idx-1, key) - if itr.err == io.EOF { - // Case 1. Need to visit block[idx]. - if idx == len(itr.t.blockIndex) { - // If idx == len(itr.t.blockIndex), then input key is greater than ANY element of table. - // There's nothing we can do. Valid() should return false as we seek to end of table. - return - } - // Since block[idx].smallest is > key. This is essentially a block[idx].SeekToFirst. - itr.seekHelper(idx, key) - } - // Case 2: No need to do anything. We already did the seek in block[idx-1]. -} - -// seek will reset iterator and seek to >= key. -func (itr *Iterator) seek(key []byte) { - itr.seekFrom(key, origin) -} - -// seekForPrev will reset iterator and seek to <= key. -func (itr *Iterator) seekForPrev(key []byte) { - // TODO: Optimize this. We shouldn't have to take a Prev step. - itr.seekFrom(key, origin) - if !bytes.Equal(itr.Key(), key) { - itr.prev() - } -} - -func (itr *Iterator) next() { - itr.err = nil - - if itr.bpos >= len(itr.t.blockIndex) { - itr.err = io.EOF - return - } - - if itr.bi == nil { - block, err := itr.t.block(itr.bpos) - if err != nil { - itr.err = err - return - } - itr.bi = block.NewIterator() - itr.bi.SeekToFirst() - itr.err = itr.bi.Error() - return - } - - itr.bi.Next() - if !itr.bi.Valid() { - itr.bpos++ - itr.bi = nil - itr.next() - return - } -} - -func (itr *Iterator) prev() { - itr.err = nil - if itr.bpos < 0 { - itr.err = io.EOF - return - } - - if itr.bi == nil { - block, err := itr.t.block(itr.bpos) - if err != nil { - itr.err = err - return - } - itr.bi = block.NewIterator() - itr.bi.SeekToLast() - itr.err = itr.bi.Error() - return - } - - itr.bi.Prev() - if !itr.bi.Valid() { - itr.bpos-- - itr.bi = nil - itr.prev() - return - } -} - -// Key follows the y.Iterator interface -func (itr *Iterator) Key() []byte { - return itr.bi.Key() -} - -// Value follows the y.Iterator interface -func (itr *Iterator) Value() (ret y.ValueStruct) { - ret.Decode(itr.bi.Value()) - return -} - -// Next follows the y.Iterator interface -func (itr *Iterator) Next() { - if !itr.reversed { - itr.next() - } else { - itr.prev() - } -} - -// Rewind follows the y.Iterator interface -func (itr *Iterator) Rewind() { - if !itr.reversed { - itr.seekToFirst() - } else { - itr.seekToLast() - } -} - -// Seek follows the y.Iterator interface -func (itr *Iterator) Seek(key []byte) { - if !itr.reversed { - itr.seek(key) - } else { - itr.seekForPrev(key) - } -} - -// ConcatIterator concatenates the sequences defined by several iterators. (It only works with -// TableIterators, probably just because it's faster to not be so generic.) -type ConcatIterator struct { - idx int // Which iterator is active now. - cur *Iterator - iters []*Iterator // Corresponds to tables. - tables []*Table // Disregarding reversed, this is in ascending order. - reversed bool -} - -// NewConcatIterator creates a new concatenated iterator -func NewConcatIterator(tbls []*Table, reversed bool) *ConcatIterator { - iters := make([]*Iterator, len(tbls)) - for i := 0; i < len(tbls); i++ { - iters[i] = tbls[i].NewIterator(reversed) - } - return &ConcatIterator{ - reversed: reversed, - iters: iters, - tables: tbls, - idx: -1, // Not really necessary because s.it.Valid()=false, but good to have. - } -} - -func (s *ConcatIterator) setIdx(idx int) { - s.idx = idx - if idx < 0 || idx >= len(s.iters) { - s.cur = nil - } else { - s.cur = s.iters[s.idx] - } -} - -// Rewind implements y.Interface -func (s *ConcatIterator) Rewind() { - if len(s.iters) == 0 { - return - } - if !s.reversed { - s.setIdx(0) - } else { - s.setIdx(len(s.iters) - 1) - } - s.cur.Rewind() -} - -// Valid implements y.Interface -func (s *ConcatIterator) Valid() bool { - return s.cur != nil && s.cur.Valid() -} - -// Key implements y.Interface -func (s *ConcatIterator) Key() []byte { - return s.cur.Key() -} - -// Value implements y.Interface -func (s *ConcatIterator) Value() y.ValueStruct { - return s.cur.Value() -} - -// Seek brings us to element >= key if reversed is false. Otherwise, <= key. -func (s *ConcatIterator) Seek(key []byte) { - var idx int - if !s.reversed { - idx = sort.Search(len(s.tables), func(i int) bool { - return y.CompareKeys(s.tables[i].Biggest(), key) >= 0 - }) - } else { - n := len(s.tables) - idx = n - 1 - sort.Search(n, func(i int) bool { - return y.CompareKeys(s.tables[n-1-i].Smallest(), key) <= 0 - }) - } - if idx >= len(s.tables) || idx < 0 { - s.setIdx(-1) - return - } - // For reversed=false, we know s.tables[i-1].Biggest() < key. Thus, the - // previous table cannot possibly contain key. - s.setIdx(idx) - s.cur.Seek(key) -} - -// Next advances our concat iterator. -func (s *ConcatIterator) Next() { - s.cur.Next() - if s.cur.Valid() { - // Nothing to do. Just stay with the current table. - return - } - for { // In case there are empty tables. - if !s.reversed { - s.setIdx(s.idx + 1) - } else { - s.setIdx(s.idx - 1) - } - if s.cur == nil { - // End of list. Valid will become false. - return - } - s.cur.Rewind() - if s.cur.Valid() { - break - } - } -} - -// Close implements y.Interface. -func (s *ConcatIterator) Close() error { - for _, it := range s.iters { - if err := it.Close(); err != nil { - return errors.Wrap(err, "ConcatIterator") - } - } - return nil -} diff --git a/vendor/github.com/dgraph-io/badger/table/table.go b/vendor/github.com/dgraph-io/badger/table/table.go deleted file mode 100644 index 9804fa1..0000000 --- a/vendor/github.com/dgraph-io/badger/table/table.go +++ /dev/null @@ -1,359 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package table - -import ( - "encoding/binary" - "fmt" - "os" - "path" - "path/filepath" - "strconv" - "strings" - "sync" - "sync/atomic" - - "github.com/AndreasBriese/bbloom" - "github.com/dgraph-io/badger/options" - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" -) - -const fileSuffix = ".sst" - -type keyOffset struct { - key []byte - offset int - len int -} - -// Table represents a loaded table file with the info we have about it -type Table struct { - sync.Mutex - - fd *os.File // Own fd. - tableSize int // Initialized in OpenTable, using fd.Stat(). - - blockIndex []keyOffset - ref int32 // For file garbage collection. Atomic. - - loadingMode options.FileLoadingMode - mmap []byte // Memory mapped. - - // The following are initialized once and const. - smallest, biggest []byte // Smallest and largest keys. - id uint64 // file id, part of filename - - bf bbloom.Bloom -} - -// IncrRef increments the refcount (having to do with whether the file should be deleted) -func (t *Table) IncrRef() { - atomic.AddInt32(&t.ref, 1) -} - -// DecrRef decrements the refcount and possibly deletes the table -func (t *Table) DecrRef() error { - newRef := atomic.AddInt32(&t.ref, -1) - if newRef == 0 { - // We can safely delete this file, because for all the current files, we always have - // at least one reference pointing to them. - - // It's necessary to delete windows files - if t.loadingMode == options.MemoryMap { - y.Munmap(t.mmap) - } - if err := t.fd.Truncate(0); err != nil { - // This is very important to let the FS know that the file is deleted. - return err - } - filename := t.fd.Name() - if err := t.fd.Close(); err != nil { - return err - } - if err := os.Remove(filename); err != nil { - return err - } - } - return nil -} - -type block struct { - offset int - data []byte -} - -func (b block) NewIterator() *blockIterator { - return &blockIterator{data: b.data} -} - -// OpenTable assumes file has only one table and opens it. Takes ownership of fd upon function -// entry. Returns a table with one reference count on it (decrementing which may delete the file! -// -- consider t.Close() instead). The fd has to writeable because we call Truncate on it before -// deleting. -func OpenTable(fd *os.File, loadingMode options.FileLoadingMode) (*Table, error) { - fileInfo, err := fd.Stat() - if err != nil { - // It's OK to ignore fd.Close() errs in this function because we have only read - // from the file. - _ = fd.Close() - return nil, y.Wrap(err) - } - - filename := fileInfo.Name() - id, ok := ParseFileID(filename) - if !ok { - _ = fd.Close() - return nil, errors.Errorf("Invalid filename: %s", filename) - } - t := &Table{ - fd: fd, - ref: 1, // Caller is given one reference. - id: id, - loadingMode: loadingMode, - } - - t.tableSize = int(fileInfo.Size()) - - if loadingMode == options.MemoryMap { - t.mmap, err = y.Mmap(fd, false, fileInfo.Size()) - if err != nil { - _ = fd.Close() - return nil, y.Wrapf(err, "Unable to map file") - } - } else if loadingMode == options.LoadToRAM { - err = t.loadToRAM() - if err != nil { - _ = fd.Close() - return nil, y.Wrap(err) - } - } - - if err := t.readIndex(); err != nil { - return nil, y.Wrap(err) - } - - it := t.NewIterator(false) - defer it.Close() - it.Rewind() - if it.Valid() { - t.smallest = it.Key() - } - - it2 := t.NewIterator(true) - defer it2.Close() - it2.Rewind() - if it2.Valid() { - t.biggest = it2.Key() - } - return t, nil -} - -// Close closes the open table. (Releases resources back to the OS.) -func (t *Table) Close() error { - if t.loadingMode == options.MemoryMap { - y.Munmap(t.mmap) - } - - return t.fd.Close() -} - -func (t *Table) read(off int, sz int) ([]byte, error) { - if len(t.mmap) > 0 { - if len(t.mmap[off:]) < sz { - return nil, y.ErrEOF - } - return t.mmap[off : off+sz], nil - } - - res := make([]byte, sz) - nbr, err := t.fd.ReadAt(res, int64(off)) - y.NumReads.Add(1) - y.NumBytesRead.Add(int64(nbr)) - return res, err -} - -func (t *Table) readNoFail(off int, sz int) []byte { - res, err := t.read(off, sz) - y.Check(err) - return res -} - -func (t *Table) readIndex() error { - readPos := t.tableSize - - // Read bloom filter. - readPos -= 4 - buf := t.readNoFail(readPos, 4) - bloomLen := int(binary.BigEndian.Uint32(buf)) - readPos -= bloomLen - data := t.readNoFail(readPos, bloomLen) - t.bf = bbloom.JSONUnmarshal(data) - - readPos -= 4 - buf = t.readNoFail(readPos, 4) - restartsLen := int(binary.BigEndian.Uint32(buf)) - - readPos -= 4 * restartsLen - buf = t.readNoFail(readPos, 4*restartsLen) - - offsets := make([]int, restartsLen) - for i := 0; i < restartsLen; i++ { - offsets[i] = int(binary.BigEndian.Uint32(buf[:4])) - buf = buf[4:] - } - - // The last offset stores the end of the last block. - for i := 0; i < len(offsets); i++ { - var o int - if i == 0 { - o = 0 - } else { - o = offsets[i-1] - } - - ko := keyOffset{ - offset: o, - len: offsets[i] - o, - } - t.blockIndex = append(t.blockIndex, ko) - } - - che := make(chan error, len(t.blockIndex)) - blocks := make(chan int, len(t.blockIndex)) - - for i := 0; i < len(t.blockIndex); i++ { - blocks <- i - } - - for i := 0; i < 64; i++ { // Run 64 goroutines. - go func() { - var h header - - for index := range blocks { - ko := &t.blockIndex[index] - - offset := ko.offset - buf, err := t.read(offset, h.Size()) - if err != nil { - che <- errors.Wrap(err, "While reading first header in block") - continue - } - - h.Decode(buf) - y.AssertTruef(h.plen == 0, "Key offset: %+v, h.plen = %d", *ko, h.plen) - - offset += h.Size() - buf = make([]byte, h.klen) - var out []byte - if out, err = t.read(offset, int(h.klen)); err != nil { - che <- errors.Wrap(err, "While reading first key in block") - continue - } - y.AssertTrue(len(buf) == copy(buf, out)) - - ko.key = buf - che <- nil - } - }() - } - close(blocks) // to stop reading goroutines - - var readError error - for i := 0; i < len(t.blockIndex); i++ { - if err := <-che; err != nil && readError == nil { - readError = err - } - } - if readError != nil { - return readError - } - - return nil -} - -func (t *Table) block(idx int) (block, error) { - y.AssertTruef(idx >= 0, "idx=%d", idx) - if idx >= len(t.blockIndex) { - return block{}, errors.New("block out of index") - } - - ko := t.blockIndex[idx] - blk := block{ - offset: ko.offset, - } - var err error - blk.data, err = t.read(blk.offset, ko.len) - return blk, err -} - -// Size is its file size in bytes -func (t *Table) Size() int64 { return int64(t.tableSize) } - -// Smallest is its smallest key, or nil if there are none -func (t *Table) Smallest() []byte { return t.smallest } - -// Biggest is its biggest key, or nil if there are none -func (t *Table) Biggest() []byte { return t.biggest } - -// Filename is NOT the file name. Just kidding, it is. -func (t *Table) Filename() string { return t.fd.Name() } - -// ID is the table's ID number (used to make the file name). -func (t *Table) ID() uint64 { return t.id } - -// DoesNotHave returns true if (but not "only if") the table does not have the key. It does a -// bloom filter lookup. -func (t *Table) DoesNotHave(key []byte) bool { return !t.bf.Has(key) } - -// ParseFileID reads the file id out of a filename. -func ParseFileID(name string) (uint64, bool) { - name = path.Base(name) - if !strings.HasSuffix(name, fileSuffix) { - return 0, false - } - // suffix := name[len(fileSuffix):] - name = strings.TrimSuffix(name, fileSuffix) - id, err := strconv.Atoi(name) - if err != nil { - return 0, false - } - y.AssertTrue(id >= 0) - return uint64(id), true -} - -// IDToFilename does the inverse of ParseFileID -func IDToFilename(id uint64) string { - return fmt.Sprintf("%06d", id) + fileSuffix -} - -// NewFilename should be named TableFilepath -- it combines the dir with the ID to make a table -// filepath. -func NewFilename(id uint64, dir string) string { - return filepath.Join(dir, IDToFilename(id)) -} - -func (t *Table) loadToRAM() error { - t.mmap = make([]byte, t.tableSize) - read, err := t.fd.ReadAt(t.mmap, 0) - if err != nil || read != t.tableSize { - return y.Wrapf(err, "Unable to load file in memory. Table file: %s", t.Filename()) - } - y.NumReads.Add(1) - y.NumBytesRead.Add(int64(read)) - return nil -} diff --git a/vendor/github.com/dgraph-io/badger/table/table_test.go b/vendor/github.com/dgraph-io/badger/table/table_test.go deleted file mode 100644 index 0f7effd..0000000 --- a/vendor/github.com/dgraph-io/badger/table/table_test.go +++ /dev/null @@ -1,729 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package table - -import ( - "fmt" - "math/rand" - "os" - "sort" - "testing" - - "github.com/dgraph-io/badger/options" - "github.com/dgraph-io/badger/y" - "github.com/stretchr/testify/require" -) - -func key(prefix string, i int) string { - return prefix + fmt.Sprintf("%04d", i) -} - -func buildTestTable(t *testing.T, prefix string, n int) *os.File { - y.AssertTrue(n <= 10000) - keyValues := make([][]string, n) - for i := 0; i < n; i++ { - k := key(prefix, i) - v := fmt.Sprintf("%d", i) - keyValues[i] = []string{k, v} - } - return buildTable(t, keyValues) -} - -// keyValues is n by 2 where n is number of pairs. -func buildTable(t *testing.T, keyValues [][]string) *os.File { - b := NewTableBuilder() - defer b.Close() - // TODO: Add test for file garbage collection here. No files should be left after the tests here. - - filename := fmt.Sprintf("%s%s%d.sst", os.TempDir(), string(os.PathSeparator), rand.Int63()) - f, err := y.OpenSyncedFile(filename, true) - if t != nil { - require.NoError(t, err) - } else { - y.Check(err) - } - - sort.Slice(keyValues, func(i, j int) bool { - return keyValues[i][0] < keyValues[j][0] - }) - for _, kv := range keyValues { - y.AssertTrue(len(kv) == 2) - err := b.Add(y.KeyWithTs([]byte(kv[0]), 0), y.ValueStruct{Value: []byte(kv[1]), Meta: 'A', UserMeta: 0}) - if t != nil { - require.NoError(t, err) - } else { - y.Check(err) - } - } - f.Write(b.Finish()) - f.Close() - f, _ = y.OpenSyncedFile(filename, true) - return f -} - -func TestTableIterator(t *testing.T) { - for _, n := range []int{99, 100, 101} { - t.Run(fmt.Sprintf("n=%d", n), func(t *testing.T) { - f := buildTestTable(t, "key", n) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - it := table.NewIterator(false) - defer it.Close() - count := 0 - for it.Rewind(); it.Valid(); it.Next() { - v := it.Value() - k := y.KeyWithTs([]byte(key("key", count)), 0) - require.EqualValues(t, k, it.Key()) - require.EqualValues(t, fmt.Sprintf("%d", count), string(v.Value)) - count++ - } - require.Equal(t, count, n) - }) - } -} - -func TestSeekToFirst(t *testing.T) { - for _, n := range []int{99, 100, 101, 199, 200, 250, 9999, 10000} { - t.Run(fmt.Sprintf("n=%d", n), func(t *testing.T) { - f := buildTestTable(t, "key", n) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - it := table.NewIterator(false) - defer it.Close() - it.seekToFirst() - require.True(t, it.Valid()) - v := it.Value() - require.EqualValues(t, "0", string(v.Value)) - require.EqualValues(t, 'A', v.Meta) - }) - } -} - -func TestSeekToLast(t *testing.T) { - for _, n := range []int{99, 100, 101, 199, 200, 250, 9999, 10000} { - t.Run(fmt.Sprintf("n=%d", n), func(t *testing.T) { - f := buildTestTable(t, "key", n) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - it := table.NewIterator(false) - defer it.Close() - it.seekToLast() - require.True(t, it.Valid()) - v := it.Value() - require.EqualValues(t, fmt.Sprintf("%d", n-1), string(v.Value)) - require.EqualValues(t, 'A', v.Meta) - it.prev() - require.True(t, it.Valid()) - v = it.Value() - require.EqualValues(t, fmt.Sprintf("%d", n-2), string(v.Value)) - require.EqualValues(t, 'A', v.Meta) - }) - } -} - -func TestSeek(t *testing.T) { - f := buildTestTable(t, "k", 10000) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - - it := table.NewIterator(false) - defer it.Close() - - var data = []struct { - in string - valid bool - out string - }{ - {"abc", true, "k0000"}, - {"k0100", true, "k0100"}, - {"k0100b", true, "k0101"}, // Test case where we jump to next block. - {"k1234", true, "k1234"}, - {"k1234b", true, "k1235"}, - {"k9999", true, "k9999"}, - {"z", false, ""}, - } - - for _, tt := range data { - it.seek(y.KeyWithTs([]byte(tt.in), 0)) - if !tt.valid { - require.False(t, it.Valid()) - continue - } - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, tt.out, string(y.ParseKey(k))) - } -} - -func TestSeekForPrev(t *testing.T) { - f := buildTestTable(t, "k", 10000) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - - it := table.NewIterator(false) - defer it.Close() - - var data = []struct { - in string - valid bool - out string - }{ - {"abc", false, ""}, - {"k0100", true, "k0100"}, - {"k0100b", true, "k0100"}, // Test case where we jump to next block. - {"k1234", true, "k1234"}, - {"k1234b", true, "k1234"}, - {"k9999", true, "k9999"}, - {"z", true, "k9999"}, - } - - for _, tt := range data { - it.seekForPrev(y.KeyWithTs([]byte(tt.in), 0)) - if !tt.valid { - require.False(t, it.Valid()) - continue - } - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, tt.out, string(y.ParseKey(k))) - } -} - -func TestIterateFromStart(t *testing.T) { - // Vary the number of elements added. - for _, n := range []int{99, 100, 101, 199, 200, 250, 9999, 10000} { - t.Run(fmt.Sprintf("n=%d", n), func(t *testing.T) { - f := buildTestTable(t, "key", n) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - ti := table.NewIterator(false) - defer ti.Close() - ti.reset() - ti.seekToFirst() - require.True(t, ti.Valid()) - // No need to do a Next. - // ti.Seek brings us to the first key >= "". Essentially a SeekToFirst. - var count int - for ; ti.Valid(); ti.next() { - v := ti.Value() - require.EqualValues(t, fmt.Sprintf("%d", count), string(v.Value)) - require.EqualValues(t, 'A', v.Meta) - count++ - } - require.EqualValues(t, n, count) - }) - } -} - -func TestIterateFromEnd(t *testing.T) { - // Vary the number of elements added. - for _, n := range []int{99, 100, 101, 199, 200, 250, 9999, 10000} { - t.Run(fmt.Sprintf("n=%d", n), func(t *testing.T) { - f := buildTestTable(t, "key", n) - table, err := OpenTable(f, options.FileIO) - require.NoError(t, err) - defer table.DecrRef() - ti := table.NewIterator(false) - defer ti.Close() - ti.reset() - ti.seek(y.KeyWithTs([]byte("zzzzzz"), 0)) // Seek to end, an invalid element. - require.False(t, ti.Valid()) - for i := n - 1; i >= 0; i-- { - ti.prev() - require.True(t, ti.Valid()) - v := ti.Value() - require.EqualValues(t, fmt.Sprintf("%d", i), string(v.Value)) - require.EqualValues(t, 'A', v.Meta) - } - ti.prev() - require.False(t, ti.Valid()) - }) - } -} - -func TestTable(t *testing.T) { - f := buildTestTable(t, "key", 10000) - table, err := OpenTable(f, options.FileIO) - require.NoError(t, err) - defer table.DecrRef() - ti := table.NewIterator(false) - defer ti.Close() - kid := 1010 - seek := y.KeyWithTs([]byte(key("key", kid)), 0) - for ti.seek(seek); ti.Valid(); ti.next() { - k := ti.Key() - require.EqualValues(t, string(y.ParseKey(k)), key("key", kid)) - kid++ - } - if kid != 10000 { - t.Errorf("Expected kid: 10000. Got: %v", kid) - } - - ti.seek(y.KeyWithTs([]byte(key("key", 99999)), 0)) - require.False(t, ti.Valid()) - - ti.seek(y.KeyWithTs([]byte(key("key", -1)), 0)) - require.True(t, ti.Valid()) - k := ti.Key() - require.EqualValues(t, string(y.ParseKey(k)), key("key", 0)) -} - -func TestIterateBackAndForth(t *testing.T) { - f := buildTestTable(t, "key", 10000) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - - seek := y.KeyWithTs([]byte(key("key", 1010)), 0) - it := table.NewIterator(false) - defer it.Close() - it.seek(seek) - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, seek, k) - - it.prev() - it.prev() - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, key("key", 1008), string(y.ParseKey(k))) - - it.next() - it.next() - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, key("key", 1010), y.ParseKey(k)) - - it.seek(y.KeyWithTs([]byte(key("key", 2000)), 0)) - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, key("key", 2000), y.ParseKey(k)) - - it.prev() - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, key("key", 1999), y.ParseKey(k)) - - it.seekToFirst() - k = it.Key() - require.EqualValues(t, key("key", 0), y.ParseKey(k)) -} - -func TestUniIterator(t *testing.T) { - f := buildTestTable(t, "key", 10000) - table, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer table.DecrRef() - { - it := table.NewIterator(false) - defer it.Close() - var count int - for it.Rewind(); it.Valid(); it.Next() { - v := it.Value() - require.EqualValues(t, fmt.Sprintf("%d", count), string(v.Value)) - require.EqualValues(t, 'A', v.Meta) - count++ - } - require.EqualValues(t, 10000, count) - } - { - it := table.NewIterator(true) - defer it.Close() - var count int - for it.Rewind(); it.Valid(); it.Next() { - v := it.Value() - require.EqualValues(t, fmt.Sprintf("%d", 10000-1-count), string(v.Value)) - require.EqualValues(t, 'A', v.Meta) - count++ - } - require.EqualValues(t, 10000, count) - } -} - -// Try having only one table. -func TestConcatIteratorOneTable(t *testing.T) { - f := buildTable(t, [][]string{ - {"k1", "a1"}, - {"k2", "a2"}, - }) - - tbl, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer tbl.DecrRef() - - it := NewConcatIterator([]*Table{tbl}, false) - defer it.Close() - - it.Rewind() - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, "k1", string(y.ParseKey(k))) - vs := it.Value() - require.EqualValues(t, "a1", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) -} - -func TestConcatIterator(t *testing.T) { - f := buildTestTable(t, "keya", 10000) - f2 := buildTestTable(t, "keyb", 10000) - f3 := buildTestTable(t, "keyc", 10000) - tbl, err := OpenTable(f, options.MemoryMap) - require.NoError(t, err) - defer tbl.DecrRef() - tbl2, err := OpenTable(f2, options.LoadToRAM) - require.NoError(t, err) - defer tbl2.DecrRef() - tbl3, err := OpenTable(f3, options.LoadToRAM) - require.NoError(t, err) - defer tbl3.DecrRef() - - { - it := NewConcatIterator([]*Table{tbl, tbl2, tbl3}, false) - defer it.Close() - it.Rewind() - require.True(t, it.Valid()) - var count int - for ; it.Valid(); it.Next() { - vs := it.Value() - require.EqualValues(t, fmt.Sprintf("%d", count%10000), string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - count++ - } - require.EqualValues(t, 30000, count) - - it.Seek(y.KeyWithTs([]byte("a"), 0)) - require.EqualValues(t, "keya0000", string(y.ParseKey(it.Key()))) - vs := it.Value() - require.EqualValues(t, "0", string(vs.Value)) - - it.Seek(y.KeyWithTs([]byte("keyb"), 0)) - require.EqualValues(t, "keyb0000", string(y.ParseKey(it.Key()))) - vs = it.Value() - require.EqualValues(t, "0", string(vs.Value)) - - it.Seek(y.KeyWithTs([]byte("keyb9999b"), 0)) - require.EqualValues(t, "keyc0000", string(y.ParseKey(it.Key()))) - vs = it.Value() - require.EqualValues(t, "0", string(vs.Value)) - - it.Seek(y.KeyWithTs([]byte("keyd"), 0)) - require.False(t, it.Valid()) - } - { - it := NewConcatIterator([]*Table{tbl, tbl2, tbl3}, true) - defer it.Close() - it.Rewind() - require.True(t, it.Valid()) - var count int - for ; it.Valid(); it.Next() { - vs := it.Value() - require.EqualValues(t, fmt.Sprintf("%d", 10000-(count%10000)-1), string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - count++ - } - require.EqualValues(t, 30000, count) - - it.Seek(y.KeyWithTs([]byte("a"), 0)) - require.False(t, it.Valid()) - - it.Seek(y.KeyWithTs([]byte("keyb"), 0)) - require.EqualValues(t, "keya9999", string(y.ParseKey(it.Key()))) - vs := it.Value() - require.EqualValues(t, "9999", string(vs.Value)) - - it.Seek(y.KeyWithTs([]byte("keyb9999b"), 0)) - require.EqualValues(t, "keyb9999", string(y.ParseKey(it.Key()))) - vs = it.Value() - require.EqualValues(t, "9999", string(vs.Value)) - - it.Seek(y.KeyWithTs([]byte("keyd"), 0)) - require.EqualValues(t, "keyc9999", string(y.ParseKey(it.Key()))) - vs = it.Value() - require.EqualValues(t, "9999", string(vs.Value)) - } -} - -func TestMergingIterator(t *testing.T) { - f1 := buildTable(t, [][]string{ - {"k1", "a1"}, - {"k2", "a2"}, - }) - f2 := buildTable(t, [][]string{ - {"k1", "b1"}, - {"k2", "b2"}, - }) - tbl1, err := OpenTable(f1, options.LoadToRAM) - require.NoError(t, err) - defer tbl1.DecrRef() - tbl2, err := OpenTable(f2, options.LoadToRAM) - require.NoError(t, err) - defer tbl2.DecrRef() - it1 := tbl1.NewIterator(false) - it2 := NewConcatIterator([]*Table{tbl2}, false) - it := y.NewMergeIterator([]y.Iterator{it1, it2}, false) - defer it.Close() - - it.Rewind() - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, "k1", string(y.ParseKey(k))) - vs := it.Value() - require.EqualValues(t, "a1", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, "k2", string(y.ParseKey(k))) - vs = it.Value() - require.EqualValues(t, "a2", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.False(t, it.Valid()) -} - -func TestMergingIteratorReversed(t *testing.T) { - f1 := buildTable(t, [][]string{ - {"k1", "a1"}, - {"k2", "a2"}, - }) - f2 := buildTable(t, [][]string{ - {"k1", "b1"}, - {"k2", "b2"}, - }) - tbl1, err := OpenTable(f1, options.LoadToRAM) - require.NoError(t, err) - defer tbl1.DecrRef() - tbl2, err := OpenTable(f2, options.LoadToRAM) - require.NoError(t, err) - defer tbl2.DecrRef() - it1 := tbl1.NewIterator(true) - it2 := NewConcatIterator([]*Table{tbl2}, true) - it := y.NewMergeIterator([]y.Iterator{it1, it2}, true) - defer it.Close() - - it.Rewind() - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, "k2", string(y.ParseKey(k))) - vs := it.Value() - require.EqualValues(t, "a2", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, "k1", string(y.ParseKey(k))) - vs = it.Value() - require.EqualValues(t, "a1", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.False(t, it.Valid()) -} - -// Take only the first iterator. -func TestMergingIteratorTakeOne(t *testing.T) { - f1 := buildTable(t, [][]string{ - {"k1", "a1"}, - {"k2", "a2"}, - }) - f2 := buildTable(t, [][]string{}) - - t1, err := OpenTable(f1, options.LoadToRAM) - require.NoError(t, err) - defer t1.DecrRef() - t2, err := OpenTable(f2, options.LoadToRAM) - require.NoError(t, err) - defer t2.DecrRef() - - it1 := NewConcatIterator([]*Table{t1}, false) - it2 := NewConcatIterator([]*Table{t2}, false) - it := y.NewMergeIterator([]y.Iterator{it1, it2}, false) - defer it.Close() - - it.Rewind() - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, "k1", string(y.ParseKey(k))) - vs := it.Value() - require.EqualValues(t, "a1", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, "k2", string(y.ParseKey(k))) - vs = it.Value() - require.EqualValues(t, "a2", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.False(t, it.Valid()) -} - -// Take only the second iterator. -func TestMergingIteratorTakeTwo(t *testing.T) { - f1 := buildTable(t, [][]string{}) - f2 := buildTable(t, [][]string{ - {"k1", "a1"}, - {"k2", "a2"}, - }) - - t1, err := OpenTable(f1, options.LoadToRAM) - require.NoError(t, err) - defer t1.DecrRef() - t2, err := OpenTable(f2, options.LoadToRAM) - require.NoError(t, err) - defer t2.DecrRef() - - it1 := NewConcatIterator([]*Table{t1}, false) - it2 := NewConcatIterator([]*Table{t2}, false) - it := y.NewMergeIterator([]y.Iterator{it1, it2}, false) - defer it.Close() - - it.Rewind() - require.True(t, it.Valid()) - k := it.Key() - require.EqualValues(t, "k1", string(y.ParseKey(k))) - vs := it.Value() - require.EqualValues(t, "a1", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.True(t, it.Valid()) - k = it.Key() - require.EqualValues(t, "k2", string(y.ParseKey(k))) - vs = it.Value() - require.EqualValues(t, "a2", string(vs.Value)) - require.EqualValues(t, 'A', vs.Meta) - it.Next() - - require.False(t, it.Valid()) -} - -func BenchmarkRead(b *testing.B) { - n := 5 << 20 - builder := NewTableBuilder() - filename := fmt.Sprintf("%s%s%d.sst", os.TempDir(), string(os.PathSeparator), rand.Int63()) - f, err := y.OpenSyncedFile(filename, true) - y.Check(err) - for i := 0; i < n; i++ { - k := fmt.Sprintf("%016x", i) - v := fmt.Sprintf("%d", i) - y.Check(builder.Add([]byte(k), y.ValueStruct{Value: []byte(v), Meta: 123, UserMeta: 0})) - } - - f.Write(builder.Finish()) - tbl, err := OpenTable(f, options.MemoryMap) - y.Check(err) - defer tbl.DecrRef() - - // y.Printf("Size of table: %d\n", tbl.Size()) - b.ResetTimer() - // Iterate b.N times over the entire table. - for i := 0; i < b.N; i++ { - func() { - it := tbl.NewIterator(false) - defer it.Close() - for it.seekToFirst(); it.Valid(); it.next() { - } - }() - } -} - -func BenchmarkReadAndBuild(b *testing.B) { - n := 5 << 20 - builder := NewTableBuilder() - filename := fmt.Sprintf("%s%s%d.sst", os.TempDir(), string(os.PathSeparator), rand.Int63()) - f, err := y.OpenSyncedFile(filename, true) - y.Check(err) - for i := 0; i < n; i++ { - k := fmt.Sprintf("%016x", i) - v := fmt.Sprintf("%d", i) - y.Check(builder.Add([]byte(k), y.ValueStruct{Value: []byte(v), Meta: 123, UserMeta: 0})) - } - - f.Write(builder.Finish()) - tbl, err := OpenTable(f, options.MemoryMap) - y.Check(err) - defer tbl.DecrRef() - - // y.Printf("Size of table: %d\n", tbl.Size()) - b.ResetTimer() - // Iterate b.N times over the entire table. - for i := 0; i < b.N; i++ { - func() { - newBuilder := NewTableBuilder() - it := tbl.NewIterator(false) - defer it.Close() - for it.seekToFirst(); it.Valid(); it.next() { - vs := it.Value() - newBuilder.Add(it.Key(), vs) - } - newBuilder.Finish() - }() - } -} - -func BenchmarkReadMerged(b *testing.B) { - n := 5 << 20 - m := 5 // Number of tables. - y.AssertTrue((n % m) == 0) - tableSize := n / m - var tables []*Table - for i := 0; i < m; i++ { - filename := fmt.Sprintf("%s%s%d.sst", os.TempDir(), string(os.PathSeparator), rand.Int63()) - builder := NewTableBuilder() - f, err := y.OpenSyncedFile(filename, true) - y.Check(err) - for j := 0; j < tableSize; j++ { - id := j*m + i // Arrays are interleaved. - // id := i*tableSize+j (not interleaved) - k := fmt.Sprintf("%016x", id) - v := fmt.Sprintf("%d", id) - y.Check(builder.Add([]byte(k), y.ValueStruct{Value: []byte(v), Meta: 123, UserMeta: 0})) - } - f.Write(builder.Finish()) - tbl, err := OpenTable(f, options.MemoryMap) - y.Check(err) - tables = append(tables, tbl) - defer tbl.DecrRef() - } - - b.ResetTimer() - // Iterate b.N times over the entire table. - for i := 0; i < b.N; i++ { - func() { - var iters []y.Iterator - for _, tbl := range tables { - iters = append(iters, tbl.NewIterator(false)) - } - it := y.NewMergeIterator(iters, false) - defer it.Close() - for it.Rewind(); it.Valid(); it.Next() { - } - }() - } -} diff --git a/vendor/github.com/dgraph-io/badger/test.sh b/vendor/github.com/dgraph-io/badger/test.sh deleted file mode 100755 index a0c7f09..0000000 --- a/vendor/github.com/dgraph-io/badger/test.sh +++ /dev/null @@ -1,5 +0,0 @@ -l=$(go list ./...) -for x in $l; do - echo "Testing package $x" - go test -v $x -done diff --git a/vendor/github.com/dgraph-io/badger/transaction.go b/vendor/github.com/dgraph-io/badger/transaction.go deleted file mode 100644 index de5f479..0000000 --- a/vendor/github.com/dgraph-io/badger/transaction.go +++ /dev/null @@ -1,581 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bytes" - "math" - "sort" - "strconv" - "sync" - "sync/atomic" - "time" - - "github.com/dgraph-io/badger/y" - farm "github.com/dgryski/go-farm" - "github.com/pkg/errors" -) - -type oracle struct { - // curRead must be at the top for memory alignment. See issue #311. - curRead uint64 // Managed by the mutex. - refCount int64 - isManaged bool // Does not change value, so no locking required. - - sync.Mutex - writeLock sync.Mutex - nextCommit uint64 - - readMark y.WaterMark - - // commits stores a key fingerprint and latest commit counter for it. - // refCount is used to clear out commits map to avoid a memory blowup. - commits map[uint64]uint64 -} - -func (o *oracle) addRef() { - atomic.AddInt64(&o.refCount, 1) -} - -func (o *oracle) decrRef() { - if count := atomic.AddInt64(&o.refCount, -1); count == 0 { - // Clear out commits maps to release memory. - o.Lock() - // Avoids the race where something new is added to commitsMap - // after we check refCount and before we take Lock. - if atomic.LoadInt64(&o.refCount) != 0 { - o.Unlock() - return - } - if len(o.commits) >= 1000 { // If the map is still small, let it slide. - o.commits = make(map[uint64]uint64) - } - o.Unlock() - } -} - -func (o *oracle) readTs() uint64 { - if o.isManaged { - return math.MaxUint64 - } - return atomic.LoadUint64(&o.curRead) -} - -func (o *oracle) commitTs() uint64 { - o.Lock() - defer o.Unlock() - return o.nextCommit -} - -// hasConflict must be called while having a lock. -func (o *oracle) hasConflict(txn *Txn) bool { - if len(txn.reads) == 0 { - return false - } - for _, ro := range txn.reads { - if ts, has := o.commits[ro]; has && ts > txn.readTs { - return true - } - } - return false -} - -func (o *oracle) newCommitTs(txn *Txn) uint64 { - o.Lock() - defer o.Unlock() - - if o.hasConflict(txn) { - return 0 - } - - var ts uint64 - if !o.isManaged { - // This is the general case, when user doesn't specify the read and commit ts. - ts = o.nextCommit - o.nextCommit++ - - } else { - // If commitTs is set, use it instead. - ts = txn.commitTs - } - - for _, w := range txn.writes { - o.commits[w] = ts // Update the commitTs. - } - return ts -} - -func (o *oracle) doneCommit(cts uint64) { - if o.isManaged { - // No need to update anything. - return - } - - for { - curRead := atomic.LoadUint64(&o.curRead) - if cts <= curRead { - return - } - atomic.CompareAndSwapUint64(&o.curRead, curRead, cts) - } -} - -// Txn represents a Badger transaction. -type Txn struct { - readTs uint64 - commitTs uint64 - - update bool // update is used to conditionally keep track of reads. - reads []uint64 // contains fingerprints of keys read. - writes []uint64 // contains fingerprints of keys written. - - pendingWrites map[string]*Entry // cache stores any writes done by txn. - - db *DB - callbacks []func() - discarded bool - - size int64 - count int64 -} - -type pendingWritesIterator struct { - entries []*Entry - nextIdx int - readTs uint64 - reversed bool -} - -func (pi *pendingWritesIterator) Next() { - pi.nextIdx++ -} - -func (pi *pendingWritesIterator) Rewind() { - pi.nextIdx = 0 -} - -func (pi *pendingWritesIterator) Seek(key []byte) { - key = y.ParseKey(key) - pi.nextIdx = sort.Search(len(pi.entries), func(idx int) bool { - cmp := bytes.Compare(pi.entries[idx].Key, key) - if !pi.reversed { - return cmp >= 0 - } - return cmp <= 0 - }) -} - -func (pi *pendingWritesIterator) Key() []byte { - y.AssertTrue(pi.Valid()) - entry := pi.entries[pi.nextIdx] - return y.KeyWithTs(entry.Key, pi.readTs) -} - -func (pi *pendingWritesIterator) Value() y.ValueStruct { - y.AssertTrue(pi.Valid()) - entry := pi.entries[pi.nextIdx] - return y.ValueStruct{ - Value: entry.Value, - Meta: entry.meta, - UserMeta: entry.UserMeta, - ExpiresAt: entry.ExpiresAt, - Version: pi.readTs, - } -} - -func (pi *pendingWritesIterator) Valid() bool { - return pi.nextIdx < len(pi.entries) -} - -func (pi *pendingWritesIterator) Close() error { - return nil -} - -func (txn *Txn) newPendingWritesIterator(reversed bool) *pendingWritesIterator { - if !txn.update || len(txn.pendingWrites) == 0 { - return nil - } - entries := make([]*Entry, 0, len(txn.pendingWrites)) - for _, e := range txn.pendingWrites { - entries = append(entries, e) - } - // Number of pending writes per transaction shouldn't be too big in general. - sort.Slice(entries, func(i, j int) bool { - cmp := bytes.Compare(entries[i].Key, entries[j].Key) - if !reversed { - return cmp < 0 - } - return cmp > 0 - }) - return &pendingWritesIterator{ - readTs: txn.readTs, - entries: entries, - reversed: reversed, - } -} - -func (txn *Txn) checkSize(e *Entry) error { - count := txn.count + 1 - // Extra bytes for version in key. - size := txn.size + int64(e.estimateSize(txn.db.opt.ValueThreshold)) + 10 - if count >= txn.db.opt.maxBatchCount || size >= txn.db.opt.maxBatchSize { - return ErrTxnTooBig - } - txn.count, txn.size = count, size - return nil -} - -// Set adds a key-value pair to the database. -// -// It will return ErrReadOnlyTxn if update flag was set to false when creating the -// transaction. -// -// The current transaction keeps a reference to the key and val byte slice -// arguments. Users must not modify key and val until the end of the transaction. -func (txn *Txn) Set(key, val []byte) error { - e := &Entry{ - Key: key, - Value: val, - } - return txn.SetEntry(e) -} - -// SetWithMeta adds a key-value pair to the database, along with a metadata -// byte. -// -// This byte is stored alongside the key, and can be used as an aid to -// interpret the value or store other contextual bits corresponding to the -// key-value pair. -// -// The current transaction keeps a reference to the key and val byte slice -// arguments. Users must not modify key and val until the end of the transaction. -func (txn *Txn) SetWithMeta(key, val []byte, meta byte) error { - e := &Entry{Key: key, Value: val, UserMeta: meta} - return txn.SetEntry(e) -} - -// SetWithDiscard acts like SetWithMeta, but adds a marker to discard earlier -// versions of the key. -// -// This method is only useful if you have set a higher limit for -// options.NumVersionsToKeep. The default setting is 1, in which case, this -// function doesn't add any more benefit than just calling the normal -// SetWithMeta (or Set) function. If however, you have a higher setting for -// NumVersionsToKeep (in Dgraph, we set it to infinity), you can use this method -// to indicate that all the older versions can be discarded and removed during -// compactions. -// -// The current transaction keeps a reference to the key and val byte slice -// arguments. Users must not modify key and val until the end of the -// transaction. -func (txn *Txn) SetWithDiscard(key, val []byte, meta byte) error { - e := &Entry{ - Key: key, - Value: val, - UserMeta: meta, - meta: bitDiscardEarlierVersions, - } - return txn.SetEntry(e) -} - -// SetWithTTL adds a key-value pair to the database, along with a time-to-live -// (TTL) setting. A key stored with a TTL would automatically expire after the -// time has elapsed , and be eligible for garbage collection. -// -// The current transaction keeps a reference to the key and val byte slice -// arguments. Users must not modify key and val until the end of the -// transaction. -func (txn *Txn) SetWithTTL(key, val []byte, dur time.Duration) error { - expire := time.Now().Add(dur).Unix() - e := &Entry{Key: key, Value: val, ExpiresAt: uint64(expire)} - return txn.SetEntry(e) -} - -func (txn *Txn) modify(e *Entry) error { - if !txn.update { - return ErrReadOnlyTxn - } else if txn.discarded { - return ErrDiscardedTxn - } else if len(e.Key) == 0 { - return ErrEmptyKey - } else if len(e.Key) > maxKeySize { - return exceedsMaxKeySizeError(e.Key) - } else if int64(len(e.Value)) > txn.db.opt.ValueLogFileSize { - return exceedsMaxValueSizeError(e.Value, txn.db.opt.ValueLogFileSize) - } - if err := txn.checkSize(e); err != nil { - return err - } - - fp := farm.Fingerprint64(e.Key) // Avoid dealing with byte arrays. - txn.writes = append(txn.writes, fp) - txn.pendingWrites[string(e.Key)] = e - return nil -} - -// SetEntry takes an Entry struct and adds the key-value pair in the struct, -// along with other metadata to the database. -// -// The current transaction keeps a reference to the entry passed in argument. -// Users must not modify the entry until the end of the transaction. -func (txn *Txn) SetEntry(e *Entry) error { - return txn.modify(e) -} - -// Delete deletes a key. -// -// This is done by adding a delete marker for the key at commit timestamp. Any -// reads happening before this timestamp would be unaffected. Any reads after -// this commit would see the deletion. -// -// The current transaction keeps a reference to the key byte slice argument. -// Users must not modify the key until the end of the transaction. -func (txn *Txn) Delete(key []byte) error { - e := &Entry{ - Key: key, - meta: bitDelete, - } - return txn.modify(e) -} - -// Get looks for key and returns corresponding Item. -// If key is not found, ErrKeyNotFound is returned. -func (txn *Txn) Get(key []byte) (item *Item, rerr error) { - if len(key) == 0 { - return nil, ErrEmptyKey - } else if txn.discarded { - return nil, ErrDiscardedTxn - } - - item = new(Item) - if txn.update { - if e, has := txn.pendingWrites[string(key)]; has && bytes.Equal(key, e.Key) { - if isDeletedOrExpired(e.meta, e.ExpiresAt) { - return nil, ErrKeyNotFound - } - // Fulfill from cache. - item.meta = e.meta - item.val = e.Value - item.userMeta = e.UserMeta - item.key = key - item.status = prefetched - item.version = txn.readTs - item.expiresAt = e.ExpiresAt - // We probably don't need to set db on item here. - return item, nil - } - // Only track reads if this is update txn. No need to track read if txn serviced it - // internally. - fp := farm.Fingerprint64(key) - txn.reads = append(txn.reads, fp) - } - - seek := y.KeyWithTs(key, txn.readTs) - vs, err := txn.db.get(seek) - if err != nil { - return nil, errors.Wrapf(err, "DB::Get key: %q", key) - } - if vs.Value == nil && vs.Meta == 0 { - return nil, ErrKeyNotFound - } - if isDeletedOrExpired(vs.Meta, vs.ExpiresAt) { - return nil, ErrKeyNotFound - } - - item.key = key - item.version = vs.Version - item.meta = vs.Meta - item.userMeta = vs.UserMeta - item.db = txn.db - item.vptr = vs.Value - item.txn = txn - item.expiresAt = vs.ExpiresAt - return item, nil -} - -func (txn *Txn) runCallbacks() { - for _, cb := range txn.callbacks { - cb() - } - txn.callbacks = nil -} - -// Discard discards a created transaction. This method is very important and must be called. Commit -// method calls this internally, however, calling this multiple times doesn't cause any issues. So, -// this can safely be called via a defer right when transaction is created. -// -// NOTE: If any operations are run on a discarded transaction, ErrDiscardedTxn is returned. -func (txn *Txn) Discard() { - if txn.discarded { // Avoid a re-run. - return - } - txn.discarded = true - txn.db.orc.readMark.Done(txn.readTs) - txn.runCallbacks() - - if txn.update { - txn.db.orc.decrRef() - } -} - -// Commit commits the transaction, following these steps: -// -// 1. If there are no writes, return immediately. -// -// 2. Check if read rows were updated since txn started. If so, return ErrConflict. -// -// 3. If no conflict, generate a commit timestamp and update written rows' commit ts. -// -// 4. Batch up all writes, write them to value log and LSM tree. -// -// 5. If callback is provided, Badger will return immediately after checking -// for conflicts. Writes to the database will happen in the background. If -// there is a conflict, an error will be returned and the callback will not -// run. If there are no conflicts, the callback will be called in the -// background upon successful completion of writes or any error during write. -// -// If error is nil, the transaction is successfully committed. In case of a non-nil error, the LSM -// tree won't be updated, so there's no need for any rollback. -func (txn *Txn) Commit(callback func(error)) error { - if txn.commitTs == 0 && txn.db.opt.managedTxns { - return ErrManagedTxn - } - if txn.discarded { - return ErrDiscardedTxn - } - defer txn.Discard() - if len(txn.writes) == 0 { - return nil // Nothing to do. - } - - state := txn.db.orc - state.writeLock.Lock() - commitTs := state.newCommitTs(txn) - if commitTs == 0 { - state.writeLock.Unlock() - return ErrConflict - } - - entries := make([]*Entry, 0, len(txn.pendingWrites)+1) - for _, e := range txn.pendingWrites { - // Suffix the keys with commit ts, so the key versions are sorted in - // descending order of commit timestamp. - e.Key = y.KeyWithTs(e.Key, commitTs) - e.meta |= bitTxn - entries = append(entries, e) - } - e := &Entry{ - Key: y.KeyWithTs(txnKey, commitTs), - Value: []byte(strconv.FormatUint(commitTs, 10)), - meta: bitFinTxn, - } - entries = append(entries, e) - - req, err := txn.db.sendToWriteCh(entries) - state.writeLock.Unlock() - if err != nil { - return err - } - - // Need to release all locks or writes can get deadlocked. - txn.runCallbacks() - - if callback == nil { - // If batchSet failed, LSM would not have been updated. So, no need to rollback anything. - - // TODO: What if some of the txns successfully make it to value log, but others fail. - // Nothing gets updated to LSM, until a restart happens. - defer state.doneCommit(commitTs) - return req.Wait() - } - go func() { - err := req.Wait() - // Write is complete. Let's call the callback function now. - state.doneCommit(commitTs) - callback(err) - }() - return nil -} - -// NewTransaction creates a new transaction. Badger supports concurrent execution of transactions, -// providing serializable snapshot isolation, avoiding write skews. Badger achieves this by tracking -// the keys read and at Commit time, ensuring that these read keys weren't concurrently modified by -// another transaction. -// -// For read-only transactions, set update to false. In this mode, we don't track the rows read for -// any changes. Thus, any long running iterations done in this mode wouldn't pay this overhead. -// -// Running transactions concurrently is OK. However, a transaction itself isn't thread safe, and -// should only be run serially. It doesn't matter if a transaction is created by one goroutine and -// passed down to other, as long as the Txn APIs are called serially. -// -// When you create a new transaction, it is absolutely essential to call -// Discard(). This should be done irrespective of what the update param is set -// to. Commit API internally runs Discard, but running it twice wouldn't cause -// any issues. -// -// txn := db.NewTransaction(false) -// defer txn.Discard() -// // Call various APIs. -func (db *DB) NewTransaction(update bool) *Txn { - if db.opt.ReadOnly && update { - // DB is read-only, force read-only transaction. - update = false - } - - txn := &Txn{ - update: update, - db: db, - readTs: db.orc.readTs(), - count: 1, // One extra entry for BitFin. - size: int64(len(txnKey) + 10), // Some buffer for the extra entry. - } - db.orc.readMark.Begin(txn.readTs) - if update { - txn.pendingWrites = make(map[string]*Entry) - txn.db.orc.addRef() - } - return txn -} - -// View executes a function creating and managing a read-only transaction for the user. Error -// returned by the function is relayed by the View method. -func (db *DB) View(fn func(txn *Txn) error) error { - if db.opt.managedTxns { - return ErrManagedTxn - } - txn := db.NewTransaction(false) - defer txn.Discard() - - return fn(txn) -} - -// Update executes a function, creating and managing a read-write transaction -// for the user. Error returned by the function is relayed by the Update method. -func (db *DB) Update(fn func(txn *Txn) error) error { - if db.opt.managedTxns { - return ErrManagedTxn - } - txn := db.NewTransaction(true) - defer txn.Discard() - - if err := fn(txn); err != nil { - return err - } - - return txn.Commit(nil) -} diff --git a/vendor/github.com/dgraph-io/badger/transaction_test.go b/vendor/github.com/dgraph-io/badger/transaction_test.go deleted file mode 100644 index 154b988..0000000 --- a/vendor/github.com/dgraph-io/badger/transaction_test.go +++ /dev/null @@ -1,827 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "fmt" - "io/ioutil" - "math/rand" - "os" - "strconv" - "sync" - "sync/atomic" - "testing" - "time" - - "github.com/dgraph-io/badger/options" - "github.com/dgraph-io/badger/y" - - "github.com/stretchr/testify/require" -) - -func TestTxnSimple(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - - txn := db.NewTransaction(true) - - for i := 0; i < 10; i++ { - k := []byte(fmt.Sprintf("key=%d", i)) - v := []byte(fmt.Sprintf("val=%d", i)) - txn.Set(k, v) - } - - item, err := txn.Get([]byte("key=8")) - require.NoError(t, err) - - val, err := item.Value() - require.NoError(t, err) - require.Equal(t, []byte("val=8"), val) - - require.Equal(t, ErrManagedTxn, txn.CommitAt(100, nil)) - require.NoError(t, txn.Commit(nil)) - }) -} - -func TestTxnReadAfterWrite(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - var wg sync.WaitGroup - N := 100 - wg.Add(N) - for i := 0; i < N; i++ { - go func(i int) { - defer wg.Done() - key := []byte(fmt.Sprintf("key%d", i)) - err := db.Update(func(tx *Txn) error { - return tx.Set(key, key) - }) - require.NoError(t, err) - err = db.View(func(tx *Txn) error { - item, err := tx.Get(key) - require.NoError(t, err) - val, err := item.Value() - require.NoError(t, err) - require.Equal(t, val, key) - return nil - }) - require.NoError(t, err) - }(i) - } - wg.Wait() - }) -} - -func TestTxnCommitAsync(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - - txn := db.NewTransaction(true) - key := func(i int) []byte { - return []byte(fmt.Sprintf("key=%d", i)) - } - for i := 0; i < 40; i++ { - err := txn.Set(key(i), []byte(strconv.Itoa(100))) - require.NoError(t, err) - } - require.NoError(t, txn.Commit(nil)) - txn.Discard() - - var done uint64 - go func() { - // Keep checking balance variant - for atomic.LoadUint64(&done) == 0 { - txn := db.NewTransaction(false) - totalBalance := 0 - for i := 0; i < 40; i++ { - item, err := txn.Get(key(i)) - require.NoError(t, err) - val, err := item.Value() - require.NoError(t, err) - bal, err := strconv.Atoi(string(val)) - require.NoError(t, err) - totalBalance += bal - } - require.Equal(t, totalBalance, 4000) - txn.Discard() - } - }() - - var wg sync.WaitGroup - wg.Add(100) - for i := 0; i < 100; i++ { - go func() { - txn := db.NewTransaction(true) - delta := rand.Intn(100) - for i := 0; i < 20; i++ { - err := txn.Set(key(i), []byte(strconv.Itoa(100-delta))) - require.NoError(t, err) - } - for i := 20; i < 40; i++ { - err := txn.Set(key(i), []byte(strconv.Itoa(100+delta))) - require.NoError(t, err) - } - // We are only doing writes, so there won't be any conflicts. - require.NoError(t, txn.Commit(func(err error) {})) - txn.Discard() - wg.Done() - }() - } - wg.Wait() - atomic.StoreUint64(&done, 1) - time.Sleep(time.Millisecond * 10) // allow goroutine to complete. - }) -} - -func TestTxnVersions(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - k := []byte("key") - for i := 1; i < 10; i++ { - txn := db.NewTransaction(true) - - txn.Set(k, []byte(fmt.Sprintf("valversion=%d", i))) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(i), db.orc.readTs()) - } - - checkIterator := func(itr *Iterator, i int) { - count := 0 - for itr.Rewind(); itr.Valid(); itr.Next() { - item := itr.Item() - require.Equal(t, k, item.Key()) - - val, err := item.Value() - require.NoError(t, err) - exp := fmt.Sprintf("valversion=%d", i) - require.Equal(t, exp, string(val), "i=%d", i) - count++ - } - require.Equal(t, 1, count, "i=%d", i) // Should only loop once. - } - - checkAllVersions := func(itr *Iterator, i int) { - var version uint64 - if itr.opt.Reverse { - version = 1 - } else { - version = uint64(i) - } - - count := 0 - for itr.Rewind(); itr.Valid(); itr.Next() { - item := itr.Item() - require.Equal(t, k, item.Key()) - require.Equal(t, version, item.Version()) - - val, err := item.Value() - require.NoError(t, err) - exp := fmt.Sprintf("valversion=%d", version) - require.Equal(t, exp, string(val), "v=%d", version) - count++ - - if itr.opt.Reverse { - version++ - } else { - version-- - } - } - require.Equal(t, i, count, "i=%d", i) // Should loop as many times as i. - } - - for i := 1; i < 10; i++ { - txn := db.NewTransaction(true) - txn.readTs = uint64(i) // Read version at i. - - item, err := txn.Get(k) - require.NoError(t, err) - - val, err := item.Value() - require.NoError(t, err) - require.Equal(t, []byte(fmt.Sprintf("valversion=%d", i)), val, - "Expected versions to match up at i=%d", i) - - // Try retrieving the latest version forward and reverse. - itr := txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, i) - - opt := DefaultIteratorOptions - opt.Reverse = true - itr = txn.NewIterator(opt) - checkIterator(itr, i) - - // Now try retrieving all versions forward and reverse. - opt = DefaultIteratorOptions - opt.AllVersions = true - itr = txn.NewIterator(opt) - checkAllVersions(itr, i) - - opt = DefaultIteratorOptions - opt.AllVersions = true - opt.Reverse = true - itr = txn.NewIterator(opt) - checkAllVersions(itr, i) - - txn.Discard() - } - txn := db.NewTransaction(true) - defer txn.Discard() - item, err := txn.Get(k) - require.NoError(t, err) - - val, err := item.Value() - require.NoError(t, err) - require.Equal(t, []byte("valversion=9"), val) - }) -} - -func TestTxnWriteSkew(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // Accounts - ax := []byte("x") - ay := []byte("y") - - // Set balance to $100 in each account. - txn := db.NewTransaction(true) - defer txn.Discard() - val := []byte(strconv.Itoa(100)) - txn.Set(ax, val) - txn.Set(ay, val) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(1), db.orc.readTs()) - - getBal := func(txn *Txn, key []byte) (bal int) { - item, err := txn.Get(key) - require.NoError(t, err) - - val, err := item.Value() - require.NoError(t, err) - bal, err = strconv.Atoi(string(val)) - require.NoError(t, err) - return bal - } - - // Start two transactions, each would read both accounts and deduct from one account. - txn1 := db.NewTransaction(true) - - sum := getBal(txn1, ax) - sum += getBal(txn1, ay) - require.Equal(t, 200, sum) - txn1.Set(ax, []byte("0")) // Deduct 100 from ax. - - // Let's read this back. - sum = getBal(txn1, ax) - require.Equal(t, 0, sum) - sum += getBal(txn1, ay) - require.Equal(t, 100, sum) - // Don't commit yet. - - txn2 := db.NewTransaction(true) - - sum = getBal(txn2, ax) - sum += getBal(txn2, ay) - require.Equal(t, 200, sum) - txn2.Set(ay, []byte("0")) // Deduct 100 from ay. - - // Let's read this back. - sum = getBal(txn2, ax) - require.Equal(t, 100, sum) - sum += getBal(txn2, ay) - require.Equal(t, 100, sum) - - // Commit both now. - require.NoError(t, txn1.Commit(nil)) - require.Error(t, txn2.Commit(nil)) // This should fail. - - require.Equal(t, uint64(2), db.orc.readTs()) - }) -} - -// a3, a2, b4 (del), b3, c2, c1 -// Read at ts=4 -> a3, c2 -// Read at ts=4(Uncomitted) -> a3, b4 -// Read at ts=3 -> a3, b3, c2 -// Read at ts=2 -> a2, c2 -// Read at ts=1 -> c1 -func TestTxnIterationEdgeCase(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - ka := []byte("a") - kb := []byte("b") - kc := []byte("c") - - // c1 - txn := db.NewTransaction(true) - txn.Set(kc, []byte("c1")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(1), db.orc.readTs()) - - // a2, c2 - txn = db.NewTransaction(true) - txn.Set(ka, []byte("a2")) - txn.Set(kc, []byte("c2")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(2), db.orc.readTs()) - - // b3 - txn = db.NewTransaction(true) - txn.Set(ka, []byte("a3")) - txn.Set(kb, []byte("b3")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(3), db.orc.readTs()) - - // b4, c4(del) (Uncomitted) - txn4 := db.NewTransaction(true) - require.NoError(t, txn4.Set(kb, []byte("b4"))) - require.NoError(t, txn4.Delete(kc)) - require.Equal(t, uint64(3), db.orc.readTs()) - - // b4 (del) - txn = db.NewTransaction(true) - txn.Delete(kb) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(4), db.orc.readTs()) - - checkIterator := func(itr *Iterator, expected []string) { - var i int - for itr.Rewind(); itr.Valid(); itr.Next() { - item := itr.Item() - val, err := item.Value() - require.NoError(t, err) - require.Equal(t, expected[i], string(val), "readts=%d", itr.readTs) - i++ - } - require.Equal(t, len(expected), i) - } - - txn = db.NewTransaction(true) - defer txn.Discard() - itr := txn.NewIterator(DefaultIteratorOptions) - itr5 := txn4.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"a3", "c2"}) - checkIterator(itr5, []string{"a3", "b4"}) - - rev := DefaultIteratorOptions - rev.Reverse = true - itr = txn.NewIterator(rev) - itr5 = txn4.NewIterator(rev) - checkIterator(itr, []string{"c2", "a3"}) - checkIterator(itr5, []string{"b4", "a3"}) - - txn.readTs = 3 - itr = txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"a3", "b3", "c2"}) - itr = txn.NewIterator(rev) - checkIterator(itr, []string{"c2", "b3", "a3"}) - - txn.readTs = 2 - itr = txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"a2", "c2"}) - itr = txn.NewIterator(rev) - checkIterator(itr, []string{"c2", "a2"}) - - txn.readTs = 1 - itr = txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"c1"}) - itr = txn.NewIterator(rev) - checkIterator(itr, []string{"c1"}) - }) -} - -// a2, a3, b4 (del), b3, c2, c1 -// Read at ts=4 -> a3, c2 -// Read at ts=3 -> a3, b3, c2 -// Read at ts=2 -> a2, c2 -// Read at ts=1 -> c1 -func TestTxnIterationEdgeCase2(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - ka := []byte("a") - kb := []byte("aa") - kc := []byte("aaa") - - // c1 - txn := db.NewTransaction(true) - txn.Set(kc, []byte("c1")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(1), db.orc.readTs()) - - // a2, c2 - txn = db.NewTransaction(true) - txn.Set(ka, []byte("a2")) - txn.Set(kc, []byte("c2")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(2), db.orc.readTs()) - - // b3 - txn = db.NewTransaction(true) - txn.Set(ka, []byte("a3")) - txn.Set(kb, []byte("b3")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(3), db.orc.readTs()) - - // b4 (del) - txn = db.NewTransaction(true) - txn.Delete(kb) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(4), db.orc.readTs()) - - checkIterator := func(itr *Iterator, expected []string) { - var i int - for itr.Rewind(); itr.Valid(); itr.Next() { - item := itr.Item() - val, err := item.Value() - require.NoError(t, err) - require.Equal(t, expected[i], string(val), "readts=%d", itr.readTs) - i++ - } - require.Equal(t, len(expected), i) - } - txn = db.NewTransaction(true) - defer txn.Discard() - rev := DefaultIteratorOptions - rev.Reverse = true - - itr := txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"a3", "c2"}) - itr = txn.NewIterator(rev) - checkIterator(itr, []string{"c2", "a3"}) - - txn.readTs = 5 - itr = txn.NewIterator(DefaultIteratorOptions) - itr.Seek(ka) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), ka) - itr.Seek(kc) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - - itr = txn.NewIterator(rev) - itr.Seek(ka) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), ka) - itr.Seek(kc) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - - txn.readTs = 3 - itr = txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"a3", "b3", "c2"}) - itr = txn.NewIterator(rev) - checkIterator(itr, []string{"c2", "b3", "a3"}) - - txn.readTs = 2 - itr = txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"a2", "c2"}) - itr = txn.NewIterator(rev) - checkIterator(itr, []string{"c2", "a2"}) - - txn.readTs = 1 - itr = txn.NewIterator(DefaultIteratorOptions) - checkIterator(itr, []string{"c1"}) - itr = txn.NewIterator(rev) - checkIterator(itr, []string{"c1"}) - }) -} - -func TestTxnIterationEdgeCase3(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - kb := []byte("abc") - kc := []byte("acd") - kd := []byte("ade") - - // c1 - txn := db.NewTransaction(true) - txn.Set(kc, []byte("c1")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(1), db.orc.readTs()) - - // b2 - txn = db.NewTransaction(true) - txn.Set(kb, []byte("b2")) - require.NoError(t, txn.Commit(nil)) - require.Equal(t, uint64(2), db.orc.readTs()) - - txn2 := db.NewTransaction(true) - require.NoError(t, txn2.Set(kd, []byte("d2"))) - require.NoError(t, txn2.Delete(kc)) - - txn = db.NewTransaction(true) - defer txn.Discard() - rev := DefaultIteratorOptions - rev.Reverse = true - - itr := txn.NewIterator(DefaultIteratorOptions) - itr.Seek([]byte("ab")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ac")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - itr.Seek(nil) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ac")) - itr.Rewind() - itr.Seek(nil) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ac")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - - // Keys: "abc", "ade" - // Read pending writes. - itr = txn2.NewIterator(DefaultIteratorOptions) - itr.Seek([]byte("ab")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ac")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kd) - itr.Seek(nil) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ac")) - itr.Rewind() - itr.Seek(nil) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ad")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kd) - - itr = txn.NewIterator(rev) - itr.Seek([]byte("ac")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ad")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - itr.Seek(nil) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - itr.Seek([]byte("ac")) - itr.Rewind() - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - itr.Seek([]byte("ad")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kc) - - // Keys: "abc", "ade" - itr = txn2.NewIterator(rev) - itr.Seek([]byte("ad")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - itr.Seek([]byte("ae")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kd) - itr.Seek(nil) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kd) - itr.Seek([]byte("ab")) - itr.Rewind() - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kd) - itr.Seek([]byte("ac")) - require.True(t, itr.Valid()) - require.Equal(t, itr.item.Key(), kb) - }) -} - -func TestIteratorAllVersionsWithDeleted(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // Write two keys - err := db.Update(func(txn *Txn) error { - txn.Set([]byte("answer1"), []byte("42")) - txn.Set([]byte("answer2"), []byte("43")) - return nil - }) - require.NoError(t, err) - - // Delete the specific key version from underlying db directly - err = db.View(func(txn *Txn) error { - item, err := txn.Get([]byte("answer1")) - require.NoError(t, err) - err = txn.db.batchSet([]*Entry{ - { - Key: y.KeyWithTs(item.key, item.version), - meta: bitDelete, - }, - }) - require.NoError(t, err) - return err - }) - require.NoError(t, err) - - opts := DefaultIteratorOptions - opts.AllVersions = true - opts.PrefetchValues = false - - // Verify that deleted shows up when AllVersions is set. - err = db.View(func(txn *Txn) error { - it := txn.NewIterator(opts) - var count int - for it.Rewind(); it.Valid(); it.Next() { - count++ - item := it.Item() - if count == 1 { - require.Equal(t, []byte("answer1"), item.Key()) - require.True(t, item.meta&bitDelete > 0) - } else { - require.Equal(t, []byte("answer2"), item.Key()) - } - } - require.Equal(t, 2, count) - return nil - }) - require.NoError(t, err) - }) -} - -func TestIteratorAllVersionsWithDeleted2(t *testing.T) { - runBadgerTest(t, nil, func(t *testing.T, db *DB) { - // Set and delete alternatively - for i := 0; i < 4; i++ { - err := db.Update(func(txn *Txn) error { - if i%2 == 0 { - txn.Set([]byte("key"), []byte("value")) - return nil - } - txn.Delete([]byte("key")) - return nil - }) - require.NoError(t, err) - } - - opts := DefaultIteratorOptions - opts.AllVersions = true - opts.PrefetchValues = false - - // Verify that deleted shows up when AllVersions is set. - err := db.View(func(txn *Txn) error { - it := txn.NewIterator(opts) - var count int - for it.Rewind(); it.Valid(); it.Next() { - item := it.Item() - require.Equal(t, []byte("key"), item.Key()) - if count%2 != 0 { - val, err := item.Value() - require.NoError(t, err) - require.Equal(t, val, []byte("value")) - } else { - require.True(t, item.meta&bitDelete > 0) - } - count++ - } - require.Equal(t, 4, count) - return nil - }) - require.NoError(t, err) - }) -} - -func TestManagedDB(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opt := getTestOptions(dir) - kv, err := OpenManaged(opt) - require.NoError(t, err) - defer kv.Close() - - key := func(i int) []byte { - return []byte(fmt.Sprintf("key-%02d", i)) - } - - val := func(i int) []byte { - return []byte(fmt.Sprintf("val-%d", i)) - } - - // Don't allow these APIs in ManagedDB - require.Panics(t, func() { kv.NewTransaction(false) }) - - err = kv.Update(func(tx *Txn) error { return nil }) - require.Equal(t, ErrManagedTxn, err) - - err = kv.View(func(tx *Txn) error { return nil }) - require.Equal(t, ErrManagedTxn, err) - - // Write data at t=3. - txn := kv.NewTransactionAt(3, true) - for i := 0; i <= 3; i++ { - require.NoError(t, txn.Set(key(i), val(i))) - } - require.Equal(t, ErrManagedTxn, txn.Commit(nil)) - require.NoError(t, txn.CommitAt(3, nil)) - - // Read data at t=2. - txn = kv.NewTransactionAt(2, false) - for i := 0; i <= 3; i++ { - _, err := txn.Get(key(i)) - require.Equal(t, ErrKeyNotFound, err) - } - txn.Discard() - - // Read data at t=3. - txn = kv.NewTransactionAt(3, false) - for i := 0; i <= 3; i++ { - item, err := txn.Get(key(i)) - require.NoError(t, err) - require.Equal(t, uint64(3), item.Version()) - v, err := item.Value() - require.NoError(t, err) - require.Equal(t, val(i), v) - } - txn.Discard() - - // Write data at t=7. - txn = kv.NewTransactionAt(6, true) - for i := 0; i <= 7; i++ { - _, err := txn.Get(key(i)) - if err == nil { - continue // Don't overwrite existing keys. - } - require.NoError(t, txn.Set(key(i), val(i))) - } - require.NoError(t, txn.CommitAt(7, nil)) - - // Read data at t=9. - txn = kv.NewTransactionAt(9, false) - for i := 0; i <= 9; i++ { - item, err := txn.Get(key(i)) - if i <= 7 { - require.NoError(t, err) - } else { - require.Equal(t, ErrKeyNotFound, err) - } - - if i <= 3 { - require.Equal(t, uint64(3), item.Version()) - } else if i <= 7 { - require.Equal(t, uint64(7), item.Version()) - } - if i <= 7 { - v, err := item.Value() - require.NoError(t, err) - require.Equal(t, val(i), v) - } - } - txn.Discard() -} - -func TestArmV7Issue311Fix(t *testing.T) { - dir, err := ioutil.TempDir("", "") - if err != nil { - t.Fatal(err) - } - defer os.RemoveAll(dir) - - config := DefaultOptions - config.TableLoadingMode = options.MemoryMap - config.ValueLogFileSize = 16 << 20 - config.LevelOneSize = 8 << 20 - config.MaxTableSize = 2 << 20 - config.Dir = dir - config.ValueDir = dir - config.SyncWrites = false - - db, err := Open(config) - if err != nil { - t.Fatalf("cannot open db at location %s: %v", dir, err) - } - - err = db.View(func(txn *Txn) error { return nil }) - if err != nil { - t.Fatal(err) - } - - err = db.Update(func(txn *Txn) error { - return txn.Set([]byte{0x11}, []byte{0x22}) - }) - if err != nil { - t.Fatal(err) - } - - err = db.Update(func(txn *Txn) error { - return txn.Set([]byte{0x11}, []byte{0x22}) - }) - - if err != nil { - t.Fatal(err) - } - - if err = db.Close(); err != nil { - t.Fatal(err) - } -} diff --git a/vendor/github.com/dgraph-io/badger/util.go b/vendor/github.com/dgraph-io/badger/util.go deleted file mode 100644 index 88fd74d..0000000 --- a/vendor/github.com/dgraph-io/badger/util.go +++ /dev/null @@ -1,139 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "io/ioutil" - "math/rand" - "sync/atomic" - "time" - - "github.com/dgraph-io/badger/table" - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" -) - -// summary is produced when DB is closed. Currently it is used only for testing. -type summary struct { - fileIDs map[uint64]bool -} - -func (s *levelsController) getSummary() *summary { - out := &summary{ - fileIDs: make(map[uint64]bool), - } - for _, l := range s.levels { - l.getSummary(out) - } - return out -} - -func (s *levelHandler) getSummary(sum *summary) { - s.RLock() - defer s.RUnlock() - for _, t := range s.tables { - sum.fileIDs[t.ID()] = true - } -} - -func (s *DB) validate() error { return s.lc.validate() } - -func (s *levelsController) validate() error { - for _, l := range s.levels { - if err := l.validate(); err != nil { - return errors.Wrap(err, "Levels Controller") - } - } - return nil -} - -// Check does some sanity check on one level of data or in-memory index. -func (s *levelHandler) validate() error { - if s.level == 0 { - return nil - } - - s.RLock() - defer s.RUnlock() - numTables := len(s.tables) - for j := 1; j < numTables; j++ { - if j >= len(s.tables) { - return errors.Errorf("Level %d, j=%d numTables=%d", s.level, j, numTables) - } - - if y.CompareKeys(s.tables[j-1].Biggest(), s.tables[j].Smallest()) >= 0 { - return errors.Errorf( - "Inter: %q vs %q: level=%d j=%d numTables=%d", - string(s.tables[j-1].Biggest()), string(s.tables[j].Smallest()), s.level, j, numTables) - } - - if y.CompareKeys(s.tables[j].Smallest(), s.tables[j].Biggest()) > 0 { - return errors.Errorf( - "Intra: %q vs %q: level=%d j=%d numTables=%d", - s.tables[j].Smallest(), s.tables[j].Biggest(), s.level, j, numTables) - } - } - return nil -} - -// func (s *KV) debugPrintMore() { s.lc.debugPrintMore() } - -// // debugPrintMore shows key ranges of each level. -// func (s *levelsController) debugPrintMore() { -// s.Lock() -// defer s.Unlock() -// for i := 0; i < s.kv.opt.MaxLevels; i++ { -// s.levels[i].debugPrintMore() -// } -// } - -// func (s *levelHandler) debugPrintMore() { -// s.RLock() -// defer s.RUnlock() -// s.elog.Printf("Level %d:", s.level) -// for _, t := range s.tables { -// y.Printf(" [%s, %s]", t.Smallest(), t.Biggest()) -// } -// y.Printf("\n") -// } - -// reserveFileID reserves a unique file id. -func (s *levelsController) reserveFileID() uint64 { - id := atomic.AddUint64(&s.nextFileID, 1) - return id - 1 -} - -func getIDMap(dir string) map[uint64]struct{} { - fileInfos, err := ioutil.ReadDir(dir) - y.Check(err) - idMap := make(map[uint64]struct{}) - for _, info := range fileInfos { - if info.IsDir() { - continue - } - fileID, ok := table.ParseFileID(info.Name()) - if !ok { - continue - } - idMap[fileID] = struct{}{} - } - return idMap -} - -func init() { - rand.Seed(time.Now().UnixNano()) -} diff --git a/vendor/github.com/dgraph-io/badger/value.go b/vendor/github.com/dgraph-io/badger/value.go deleted file mode 100644 index f406c8f..0000000 --- a/vendor/github.com/dgraph-io/badger/value.go +++ /dev/null @@ -1,1216 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "bufio" - "bytes" - "encoding/binary" - "fmt" - "hash/crc32" - "io" - "io/ioutil" - "log" - "math" - "math/rand" - "os" - "sort" - "strconv" - "strings" - "sync" - "sync/atomic" - "time" - - "github.com/dgraph-io/badger/options" - - "github.com/dgraph-io/badger/y" - "github.com/pkg/errors" - "golang.org/x/net/trace" -) - -// Values have their first byte being byteData or byteDelete. This helps us distinguish between -// a key that has never been seen and a key that has been explicitly deleted. -const ( - bitDelete byte = 1 << 0 // Set if the key has been deleted. - bitValuePointer byte = 1 << 1 // Set if the value is NOT stored directly next to key. - bitDiscardEarlierVersions byte = 1 << 2 // Set if earlier versions can be discarded. - - // The MSB 2 bits are for transactions. - bitTxn byte = 1 << 6 // Set if the entry is part of a txn. - bitFinTxn byte = 1 << 7 // Set if the entry is to indicate end of txn in value log. - - mi int64 = 1 << 20 -) - -type logFile struct { - path string - // This is a lock on the log file. It guards the fd’s value, the file’s - // existence and the file’s memory map. - // - // Use shared ownership when reading/writing the file or memory map, use - // exclusive ownership to open/close the descriptor, unmap or remove the file. - lock sync.RWMutex - fd *os.File - fid uint32 - fmap []byte - size uint32 - loadingMode options.FileLoadingMode -} - -// openReadOnly assumes that we have a write lock on logFile. -func (lf *logFile) openReadOnly() error { - var err error - lf.fd, err = os.OpenFile(lf.path, os.O_RDONLY, 0666) - if err != nil { - return errors.Wrapf(err, "Unable to open %q as RDONLY.", lf.path) - } - - fi, err := lf.fd.Stat() - if err != nil { - return errors.Wrapf(err, "Unable to check stat for %q", lf.path) - } - lf.size = uint32(fi.Size()) - - if err = lf.mmap(fi.Size()); err != nil { - _ = lf.fd.Close() - return y.Wrapf(err, "Unable to map file") - } - - return nil -} - -func (lf *logFile) mmap(size int64) (err error) { - if lf.loadingMode != options.MemoryMap { - // Nothing to do - return nil - } - lf.fmap, err = y.Mmap(lf.fd, false, size) - if err == nil { - err = y.Madvise(lf.fmap, false) // Disable readahead - } - return err -} - -func (lf *logFile) munmap() (err error) { - if lf.loadingMode != options.MemoryMap { - // Nothing to do - return nil - } - if err := y.Munmap(lf.fmap); err != nil { - return errors.Wrapf(err, "Unable to munmap value log: %q", lf.path) - } - return nil -} - -// Acquire lock on mmap/file if you are calling this -func (lf *logFile) read(p valuePointer, s *y.Slice) (buf []byte, err error) { - var nbr int64 - offset := p.Offset - if lf.loadingMode == options.FileIO { - buf = s.Resize(int(p.Len)) - var n int - n, err = lf.fd.ReadAt(buf, int64(offset)) - nbr = int64(n) - } else { - size := uint32(len(lf.fmap)) - valsz := p.Len - if offset >= size || offset+valsz > size { - err = y.ErrEOF - } else { - buf = lf.fmap[offset : offset+valsz] - nbr = int64(valsz) - } - } - y.NumReads.Add(1) - y.NumBytesRead.Add(nbr) - return buf, err -} - -func (lf *logFile) doneWriting(offset uint32) error { - // Sync before acquiring lock. (We call this from write() and thus know we have shared access - // to the fd.) - if err := lf.fd.Sync(); err != nil { - return errors.Wrapf(err, "Unable to sync value log: %q", lf.path) - } - // Close and reopen the file read-only. Acquire lock because fd will become invalid for a bit. - // Acquiring the lock is bad because, while we don't hold the lock for a long time, it forces - // one batch of readers wait for the preceding batch of readers to finish. - // - // If there's a benefit to reopening the file read-only, it might be on Windows. I don't know - // what the benefit is. Consider keeping the file read-write, or use fcntl to change - // permissions. - lf.lock.Lock() - defer lf.lock.Unlock() - if err := lf.munmap(); err != nil { - return err - } - // TODO: Confirm if we need to run a file sync after truncation. - // Truncation must run after unmapping, otherwise Windows would crap itself. - if err := lf.fd.Truncate(int64(offset)); err != nil { - return errors.Wrapf(err, "Unable to truncate file: %q", lf.path) - } - if err := lf.fd.Close(); err != nil { - return errors.Wrapf(err, "Unable to close value log: %q", lf.path) - } - - return lf.openReadOnly() -} - -// You must hold lf.lock to sync() -func (lf *logFile) sync() error { - return lf.fd.Sync() -} - -var errStop = errors.New("Stop iteration") -var errTruncate = errors.New("Do truncate") - -type logEntry func(e Entry, vp valuePointer) error - -type safeRead struct { - k []byte - v []byte - - recordOffset uint32 -} - -func (r *safeRead) Entry(reader *bufio.Reader) (*Entry, error) { - var hbuf [headerBufSize]byte - var err error - - hash := crc32.New(y.CastagnoliCrcTable) - tee := io.TeeReader(reader, hash) - if _, err = io.ReadFull(tee, hbuf[:]); err != nil { - return nil, err - } - - var h header - h.Decode(hbuf[:]) - if h.klen > maxKeySize { - return nil, errTruncate - } - kl := int(h.klen) - if cap(r.k) < kl { - r.k = make([]byte, 2*kl) - } - vl := int(h.vlen) - if cap(r.v) < vl { - r.v = make([]byte, 2*vl) - } - - e := &Entry{} - e.offset = r.recordOffset - e.Key = r.k[:kl] - e.Value = r.v[:vl] - - if _, err = io.ReadFull(tee, e.Key); err != nil { - if err == io.EOF { - err = errTruncate - } - return nil, err - } - if _, err = io.ReadFull(tee, e.Value); err != nil { - if err == io.EOF { - err = errTruncate - } - return nil, err - } - var crcBuf [4]byte - if _, err = io.ReadFull(reader, crcBuf[:]); err != nil { - if err == io.EOF { - err = errTruncate - } - return nil, err - } - crc := binary.BigEndian.Uint32(crcBuf[:]) - if crc != hash.Sum32() { - return nil, errTruncate - } - e.meta = h.meta - e.UserMeta = h.userMeta - e.ExpiresAt = h.expiresAt - return e, nil -} - -// iterate iterates over log file. It doesn't not allocate new memory for every kv pair. -// Therefore, the kv pair is only valid for the duration of fn call. -func (vlog *valueLog) iterate(lf *logFile, offset uint32, fn logEntry) error { - _, err := lf.fd.Seek(int64(offset), io.SeekStart) - if err != nil { - return y.Wrap(err) - } - - reader := bufio.NewReader(lf.fd) - read := &safeRead{ - k: make([]byte, 10), - v: make([]byte, 10), - recordOffset: offset, - } - - truncate := false - var lastCommit uint64 - var validEndOffset uint32 - for { - e, err := read.Entry(reader) - if err == io.EOF { - break - } else if err == io.ErrUnexpectedEOF || err == errTruncate { - truncate = true - break - } else if err != nil { - return err - } else if e == nil { - continue - } - - var vp valuePointer - vp.Len = uint32(headerBufSize + len(e.Key) + len(e.Value) + 4) // len(crcBuf) - read.recordOffset += vp.Len - - vp.Offset = e.offset - vp.Fid = lf.fid - - if e.meta&bitTxn > 0 { - txnTs := y.ParseTs(e.Key) - if lastCommit == 0 { - lastCommit = txnTs - } - if lastCommit != txnTs { - truncate = true - break - } - - } else if e.meta&bitFinTxn > 0 { - txnTs, err := strconv.ParseUint(string(e.Value), 10, 64) - if err != nil || lastCommit != txnTs { - truncate = true - break - } - // Got the end of txn. Now we can store them. - lastCommit = 0 - validEndOffset = read.recordOffset - - } else { - if lastCommit != 0 { - // This is most likely an entry which was moved as part of GC. - // We shouldn't get this entry in the middle of a transaction. - truncate = true - break - } - validEndOffset = read.recordOffset - } - - if vlog.opt.ReadOnly { - return ErrReplayNeeded - } - if err := fn(*e, vp); err != nil { - if err == errStop { - break - } - return y.Wrap(err) - } - } - - if vlog.opt.Truncate && truncate && len(lf.fmap) == 0 { - // Only truncate if the file isn't mmaped. Otherwise, Windows would puke. - if err := lf.fd.Truncate(int64(validEndOffset)); err != nil { - return err - } - } else if truncate { - return ErrTruncateNeeded - } - - return nil -} - -func (vlog *valueLog) rewrite(f *logFile, tr trace.Trace) error { - maxFid := atomic.LoadUint32(&vlog.maxFid) - y.AssertTruef(uint32(f.fid) < maxFid, "fid to move: %d. Current max fid: %d", f.fid, maxFid) - tr.LazyPrintf("Rewriting fid: %d", f.fid) - - wb := make([]*Entry, 0, 1000) - var size int64 - - y.AssertTrue(vlog.kv != nil) - var count, moved int - fe := func(e Entry) error { - count++ - if count%100000 == 0 { - tr.LazyPrintf("Processing entry %d", count) - } - - vs, err := vlog.kv.get(e.Key) - if err != nil { - return err - } - if discardEntry(e, vs) { - return nil - } - - // Value is still present in value log. - if len(vs.Value) == 0 { - return errors.Errorf("Empty value: %+v", vs) - } - var vp valuePointer - vp.Decode(vs.Value) - - if vp.Fid > f.fid { - return nil - } - if vp.Offset > e.offset { - return nil - } - if vp.Fid == f.fid && vp.Offset == e.offset { - moved++ - // This new entry only contains the key, and a pointer to the value. - ne := new(Entry) - ne.meta = 0 // Remove all bits. Different keyspace doesn't need these bits. - ne.UserMeta = e.UserMeta - - // Create a new key in a separate keyspace, prefixed by moveKey. We are not - // allowed to rewrite an older version of key in the LSM tree, because then this older - // version would be at the top of the LSM tree. To work correctly, reads expect the - // latest versions to be at the top, and the older versions at the bottom. - ne.Key = append(badgerMove, e.Key...) - - ne.Value = make([]byte, len(e.Value)) - copy(ne.Value, e.Value) - wb = append(wb, ne) - size += int64(e.estimateSize(vlog.opt.ValueThreshold)) - if size >= 64*mi { - tr.LazyPrintf("request has %d entries, size %d", len(wb), size) - if err := vlog.kv.batchSet(wb); err != nil { - return err - } - size = 0 - wb = wb[:0] - } - } else { - log.Printf("WARNING: This entry should have been caught. %+v\n", e) - } - return nil - } - - err := vlog.iterate(f, 0, func(e Entry, vp valuePointer) error { - return fe(e) - }) - if err != nil { - return err - } - - tr.LazyPrintf("request has %d entries, size %d", len(wb), size) - batchSize := 1024 - var loops int - for i := 0; i < len(wb); { - loops++ - if batchSize == 0 { - log.Printf("WARNING: We shouldn't reach batch size of zero.") - return ErrNoRewrite - } - end := i + batchSize - if end > len(wb) { - end = len(wb) - } - if err := vlog.kv.batchSet(wb[i:end]); err != nil { - if err == ErrTxnTooBig { - // Decrease the batch size to half. - batchSize = batchSize / 2 - tr.LazyPrintf("Dropped batch size to %d", batchSize) - continue - } - return err - } - i += batchSize - } - tr.LazyPrintf("Processed %d entries in %d loops", len(wb), loops) - tr.LazyPrintf("Total entries: %d. Moved: %d", count, moved) - tr.LazyPrintf("Removing fid: %d", f.fid) - var deleteFileNow bool - // Entries written to LSM. Remove the older file now. - { - vlog.filesLock.Lock() - // Just a sanity-check. - if _, ok := vlog.filesMap[f.fid]; !ok { - vlog.filesLock.Unlock() - return errors.Errorf("Unable to find fid: %d", f.fid) - } - if vlog.numActiveIterators == 0 { - delete(vlog.filesMap, f.fid) - deleteFileNow = true - } else { - vlog.filesToBeDeleted = append(vlog.filesToBeDeleted, f.fid) - } - vlog.filesLock.Unlock() - } - - if deleteFileNow { - vlog.deleteLogFile(f) - } - - return nil -} - -func (vlog *valueLog) deleteMoveKeysFor(fid uint32, tr trace.Trace) { - db := vlog.kv - var result []*Entry - var count, pointers uint64 - tr.LazyPrintf("Iterating over move keys to find invalids for fid: %d", fid) - err := db.View(func(txn *Txn) error { - opt := DefaultIteratorOptions - opt.internalAccess = true - opt.PrefetchValues = false - itr := txn.NewIterator(opt) - defer itr.Close() - - for itr.Seek(badgerMove); itr.ValidForPrefix(badgerMove); itr.Next() { - count++ - item := itr.Item() - if item.meta&bitValuePointer == 0 { - continue - } - pointers++ - var vp valuePointer - vp.Decode(item.vptr) - if vp.Fid == fid { - e := &Entry{Key: item.KeyCopy(nil), meta: bitDelete} - result = append(result, e) - } - } - return nil - }) - if err != nil { - tr.LazyPrintf("Got error while iterating move keys: %v", err) - tr.SetError() - return - } - tr.LazyPrintf("Num total move keys: %d. Num pointers: %d", count, pointers) - tr.LazyPrintf("Number of invalid move keys found: %d", len(result)) - batchSize := 10240 - for i := 0; i < len(result); { - end := i + batchSize - if end > len(result) { - end = len(result) - } - if err := db.batchSet(result[i:end]); err != nil { - if err == ErrTxnTooBig { - batchSize /= 2 - tr.LazyPrintf("Dropped batch size to %d", batchSize) - continue - } - tr.LazyPrintf("Error while doing batchSet: %v", err) - tr.SetError() - return - } - i += batchSize - } - tr.LazyPrintf("Move keys deletion done.") - return -} - -func (vlog *valueLog) incrIteratorCount() { - atomic.AddInt32(&vlog.numActiveIterators, 1) -} - -func (vlog *valueLog) decrIteratorCount() error { - num := atomic.AddInt32(&vlog.numActiveIterators, -1) - if num != 0 { - return nil - } - - vlog.filesLock.Lock() - lfs := make([]*logFile, 0, len(vlog.filesToBeDeleted)) - for _, id := range vlog.filesToBeDeleted { - lfs = append(lfs, vlog.filesMap[id]) - delete(vlog.filesMap, id) - } - vlog.filesToBeDeleted = nil - vlog.filesLock.Unlock() - - for _, lf := range lfs { - if err := vlog.deleteLogFile(lf); err != nil { - return err - } - } - return nil -} - -func (vlog *valueLog) deleteLogFile(lf *logFile) error { - path := vlog.fpath(lf.fid) - if err := lf.munmap(); err != nil { - _ = lf.fd.Close() - return err - } - if err := lf.fd.Close(); err != nil { - return err - } - return os.Remove(path) -} - -// lfDiscardStats keeps track of the amount of data that could be discarded for -// a given logfile. -type lfDiscardStats struct { - sync.Mutex - m map[uint32]int64 -} - -type valueLog struct { - buf bytes.Buffer - dirPath string - elog trace.EventLog - - // guards our view of which files exist, which to be deleted, how many active iterators - filesLock sync.RWMutex - filesMap map[uint32]*logFile - filesToBeDeleted []uint32 - // A refcount of iterators -- when this hits zero, we can delete the filesToBeDeleted. - numActiveIterators int32 - - kv *DB - maxFid uint32 - writableLogOffset uint32 - numEntriesWritten uint32 - opt Options - - garbageCh chan struct{} - lfDiscardStats *lfDiscardStats -} - -func vlogFilePath(dirPath string, fid uint32) string { - return fmt.Sprintf("%s%s%06d.vlog", dirPath, string(os.PathSeparator), fid) -} - -func (vlog *valueLog) fpath(fid uint32) string { - return vlogFilePath(vlog.dirPath, fid) -} - -func (vlog *valueLog) openOrCreateFiles(readOnly bool) error { - files, err := ioutil.ReadDir(vlog.dirPath) - if err != nil { - return errors.Wrapf(err, "Error while opening value log") - } - - found := make(map[uint64]struct{}) - var maxFid uint32 // Beware len(files) == 0 case, this starts at 0. - for _, file := range files { - if !strings.HasSuffix(file.Name(), ".vlog") { - continue - } - fsz := len(file.Name()) - fid, err := strconv.ParseUint(file.Name()[:fsz-5], 10, 32) - if err != nil { - return errors.Wrapf(err, "Error while parsing value log id for file: %q", file.Name()) - } - if _, ok := found[fid]; ok { - return errors.Errorf("Found the same value log file twice: %d", fid) - } - found[fid] = struct{}{} - - lf := &logFile{ - fid: uint32(fid), - path: vlog.fpath(uint32(fid)), - loadingMode: vlog.opt.ValueLogLoadingMode, - } - vlog.filesMap[uint32(fid)] = lf - if uint32(fid) > maxFid { - maxFid = uint32(fid) - } - } - vlog.maxFid = uint32(maxFid) - - // Open all previous log files as read only. Open the last log file - // as read write (unless the DB is read only). - for fid, lf := range vlog.filesMap { - if fid == maxFid { - var flags uint32 - if vlog.opt.SyncWrites { - flags |= y.Sync - } - if readOnly { - flags |= y.ReadOnly - } - if lf.fd, err = y.OpenExistingFile(vlog.fpath(fid), flags); err != nil { - return errors.Wrapf(err, "Unable to open value log file") - } - } else { - if err := lf.openReadOnly(); err != nil { - return err - } - } - } - - // If no files are found, then create a new file. - if len(vlog.filesMap) == 0 { - // We already set vlog.maxFid above - _, err := vlog.createVlogFile(0) - if err != nil { - return err - } - } - return nil -} - -func (vlog *valueLog) createVlogFile(fid uint32) (*logFile, error) { - path := vlog.fpath(fid) - lf := &logFile{fid: fid, path: path, loadingMode: vlog.opt.ValueLogLoadingMode} - vlog.writableLogOffset = 0 - vlog.numEntriesWritten = 0 - - var err error - if lf.fd, err = y.CreateSyncedFile(path, vlog.opt.SyncWrites); err != nil { - return nil, errors.Wrapf(err, "Unable to create value log file") - } - - if err = syncDir(vlog.dirPath); err != nil { - return nil, errors.Wrapf(err, "Unable to sync value log file dir") - } - - vlog.filesLock.Lock() - vlog.filesMap[fid] = lf - vlog.filesLock.Unlock() - - return lf, nil -} - -func (vlog *valueLog) Open(kv *DB, opt Options) error { - vlog.dirPath = opt.ValueDir - vlog.opt = opt - vlog.kv = kv - vlog.filesMap = make(map[uint32]*logFile) - if err := vlog.openOrCreateFiles(kv.opt.ReadOnly); err != nil { - return errors.Wrapf(err, "Unable to open value log") - } - - vlog.elog = trace.NewEventLog("Badger", "Valuelog") - vlog.garbageCh = make(chan struct{}, 1) // Only allow one GC at a time. - vlog.lfDiscardStats = &lfDiscardStats{m: make(map[uint32]int64)} - return nil -} - -func (vlog *valueLog) Close() error { - vlog.elog.Printf("Stopping garbage collection of values.") - defer vlog.elog.Finish() - - var err error - for id, f := range vlog.filesMap { - - f.lock.Lock() // We won’t release the lock. - if munmapErr := f.munmap(); munmapErr != nil && err == nil { - err = munmapErr - } - - if !vlog.opt.ReadOnly && id == vlog.maxFid { - // truncate writable log file to correct offset. - if truncErr := f.fd.Truncate( - int64(vlog.writableLogOffset)); truncErr != nil && err == nil { - err = truncErr - } - } - - if closeErr := f.fd.Close(); closeErr != nil && err == nil { - err = closeErr - } - - } - return err -} - -// sortedFids returns the file id's not pending deletion, sorted. Assumes we have shared access to -// filesMap. -func (vlog *valueLog) sortedFids() []uint32 { - toBeDeleted := make(map[uint32]struct{}) - for _, fid := range vlog.filesToBeDeleted { - toBeDeleted[fid] = struct{}{} - } - ret := make([]uint32, 0, len(vlog.filesMap)) - for fid := range vlog.filesMap { - if _, ok := toBeDeleted[fid]; !ok { - ret = append(ret, fid) - } - } - sort.Slice(ret, func(i, j int) bool { - return ret[i] < ret[j] - }) - return ret -} - -// Replay replays the value log. The kv provided is only valid for the lifetime of function call. -func (vlog *valueLog) Replay(ptr valuePointer, fn logEntry) error { - fid := ptr.Fid - offset := ptr.Offset + ptr.Len - vlog.elog.Printf("Seeking at value pointer: %+v\n", ptr) - - fids := vlog.sortedFids() - - for _, id := range fids { - if id < fid { - continue - } - of := offset - if id > fid { - of = 0 - } - f := vlog.filesMap[id] - err := vlog.iterate(f, of, fn) - if err != nil { - return errors.Wrapf(err, "Unable to replay value log: %q", f.path) - } - } - - // Seek to the end to start writing. - var err error - last := vlog.filesMap[vlog.maxFid] - lastOffset, err := last.fd.Seek(0, io.SeekEnd) - atomic.AddUint32(&vlog.writableLogOffset, uint32(lastOffset)) - return errors.Wrapf(err, "Unable to seek to end of value log: %q", last.path) -} - -type request struct { - // Input values - Entries []*Entry - // Output values and wait group stuff below - Ptrs []valuePointer - Wg sync.WaitGroup - Err error -} - -func (req *request) Wait() error { - req.Wg.Wait() - req.Entries = nil - err := req.Err - requestPool.Put(req) - return err -} - -// sync is thread-unsafe and should not be called concurrently with write. -func (vlog *valueLog) sync() error { - if vlog.opt.SyncWrites { - return nil - } - - vlog.filesLock.RLock() - if len(vlog.filesMap) == 0 { - vlog.filesLock.RUnlock() - return nil - } - curlf := vlog.filesMap[vlog.maxFid] - curlf.lock.RLock() - vlog.filesLock.RUnlock() - - dirSyncCh := make(chan error) - go func() { dirSyncCh <- syncDir(vlog.opt.ValueDir) }() - err := curlf.sync() - curlf.lock.RUnlock() - dirSyncErr := <-dirSyncCh - if err != nil { - err = dirSyncErr - } - return err -} - -func (vlog *valueLog) writableOffset() uint32 { - return atomic.LoadUint32(&vlog.writableLogOffset) -} - -// write is thread-unsafe by design and should not be called concurrently. -func (vlog *valueLog) write(reqs []*request) error { - vlog.filesLock.RLock() - curlf := vlog.filesMap[vlog.maxFid] - vlog.filesLock.RUnlock() - - toDisk := func() error { - if vlog.buf.Len() == 0 { - return nil - } - vlog.elog.Printf("Flushing %d blocks of total size: %d", len(reqs), vlog.buf.Len()) - n, err := curlf.fd.Write(vlog.buf.Bytes()) - if err != nil { - return errors.Wrapf(err, "Unable to write to value log file: %q", curlf.path) - } - y.NumWrites.Add(1) - y.NumBytesWritten.Add(int64(n)) - vlog.elog.Printf("Done") - atomic.AddUint32(&vlog.writableLogOffset, uint32(n)) - vlog.buf.Reset() - - if vlog.writableOffset() > uint32(vlog.opt.ValueLogFileSize) || - vlog.numEntriesWritten > vlog.opt.ValueLogMaxEntries { - var err error - if err = curlf.doneWriting(vlog.writableLogOffset); err != nil { - return err - } - - newid := atomic.AddUint32(&vlog.maxFid, 1) - y.AssertTruef(newid <= math.MaxUint32, "newid will overflow uint32: %v", newid) - newlf, err := vlog.createVlogFile(newid) - if err != nil { - return err - } - - if err = newlf.mmap(2 * vlog.opt.ValueLogFileSize); err != nil { - return err - } - - curlf = newlf - } - return nil - } - - for i := range reqs { - b := reqs[i] - b.Ptrs = b.Ptrs[:0] - for j := range b.Entries { - e := b.Entries[j] - var p valuePointer - - p.Fid = curlf.fid - // Use the offset including buffer length so far. - p.Offset = vlog.writableOffset() + uint32(vlog.buf.Len()) - plen, err := encodeEntry(e, &vlog.buf) // Now encode the entry into buffer. - if err != nil { - return err - } - p.Len = uint32(plen) - b.Ptrs = append(b.Ptrs, p) - } - vlog.numEntriesWritten += uint32(len(b.Entries)) - // We write to disk here so that all entries that are part of the same transaction are - // written to the same vlog file. - writeNow := - vlog.writableOffset()+uint32(vlog.buf.Len()) > uint32(vlog.opt.ValueLogFileSize) || - vlog.numEntriesWritten > uint32(vlog.opt.ValueLogMaxEntries) - if writeNow { - if err := toDisk(); err != nil { - return err - } - } - } - return toDisk() - - // Acquire mutex locks around this manipulation, so that the reads don't try to use - // an invalid file descriptor. -} - -// Gets the logFile and acquires and RLock() for the mmap. You must call RUnlock on the file -// (if non-nil) -func (vlog *valueLog) getFileRLocked(fid uint32) (*logFile, error) { - vlog.filesLock.RLock() - defer vlog.filesLock.RUnlock() - ret, ok := vlog.filesMap[fid] - if !ok { - // log file has gone away, will need to retry the operation. - return nil, ErrRetry - } - ret.lock.RLock() - return ret, nil -} - -// Read reads the value log at a given location. -// TODO: Make this read private. -func (vlog *valueLog) Read(vp valuePointer, s *y.Slice) ([]byte, func(), error) { - // Check for valid offset if we are reading to writable log. - if vp.Fid == vlog.maxFid && vp.Offset >= vlog.writableOffset() { - return nil, nil, errors.Errorf( - "Invalid value pointer offset: %d greater than current offset: %d", - vp.Offset, vlog.writableOffset()) - } - - buf, cb, err := vlog.readValueBytes(vp, s) - if err != nil { - return nil, cb, err - } - var h header - h.Decode(buf) - n := uint32(headerBufSize) + h.klen - return buf[n : n+h.vlen], cb, nil -} - -func (vlog *valueLog) readValueBytes(vp valuePointer, s *y.Slice) ([]byte, func(), error) { - lf, err := vlog.getFileRLocked(vp.Fid) - if err != nil { - return nil, nil, err - } - - buf, err := lf.read(vp, s) - if vlog.opt.ValueLogLoadingMode == options.MemoryMap { - return buf, lf.lock.RUnlock, err - } - // If we are using File I/O we unlock the file immediately - // and return an empty function as callback. - lf.lock.RUnlock() - return buf, nil, err -} - -// Test helper -func valueBytesToEntry(buf []byte) (e Entry) { - var h header - h.Decode(buf) - n := uint32(headerBufSize) - - e.Key = buf[n : n+h.klen] - n += h.klen - e.meta = h.meta - e.UserMeta = h.userMeta - e.Value = buf[n : n+h.vlen] - return -} - -func (vlog *valueLog) pickLog(head valuePointer, tr trace.Trace) (files []*logFile) { - vlog.filesLock.RLock() - defer vlog.filesLock.RUnlock() - fids := vlog.sortedFids() - if len(fids) <= 1 { - tr.LazyPrintf("Only one or less value log file.") - return nil - } else if head.Fid == 0 { - tr.LazyPrintf("Head pointer is at zero.") - return nil - } - - // Pick a candidate that contains the largest amount of discardable data - candidate := struct { - fid uint32 - discard int64 - }{math.MaxUint32, 0} - vlog.lfDiscardStats.Lock() - for _, fid := range fids { - if fid >= head.Fid { - break - } - if vlog.lfDiscardStats.m[fid] > candidate.discard { - candidate.fid = fid - candidate.discard = vlog.lfDiscardStats.m[fid] - } - } - vlog.lfDiscardStats.Unlock() - - if candidate.fid != math.MaxUint32 { // Found a candidate - tr.LazyPrintf("Found candidate via discard stats: %v", candidate) - files = append(files, vlog.filesMap[candidate.fid]) - } else { - tr.LazyPrintf("Could not find candidate via discard stats. Randomly picking one.") - } - - // Fallback to randomly picking a log file - var idxHead int - for i, fid := range fids { - if fid == head.Fid { - idxHead = i - break - } - } - if idxHead == 0 { // Not found or first file - tr.LazyPrintf("Could not find any file.") - return nil - } - idx := rand.Intn(idxHead) // Don’t include head.Fid. We pick a random file before it. - if idx > 0 { - idx = rand.Intn(idx + 1) // Another level of rand to favor smaller fids. - } - tr.LazyPrintf("Randomly chose fid: %d", fids[idx]) - files = append(files, vlog.filesMap[fids[idx]]) - return files -} - -func discardEntry(e Entry, vs y.ValueStruct) bool { - if vs.Version != y.ParseTs(e.Key) { - // Version not found. Discard. - return true - } - if isDeletedOrExpired(vs.Meta, vs.ExpiresAt) { - return true - } - if (vs.Meta & bitValuePointer) == 0 { - // Key also stores the value in LSM. Discard. - return true - } - if (vs.Meta & bitFinTxn) > 0 { - // Just a txn finish entry. Discard. - return true - } - return false -} - -func (vlog *valueLog) doRunGC(lf *logFile, discardRatio float64, tr trace.Trace) (err error) { - // Update stats before exiting - defer func() { - if err == nil { - vlog.lfDiscardStats.Lock() - delete(vlog.lfDiscardStats.m, lf.fid) - vlog.lfDiscardStats.Unlock() - } - }() - - type reason struct { - total float64 - discard float64 - count int - } - - fi, err := lf.fd.Stat() - if err != nil { - tr.LazyPrintf("Error while finding file size: %v", err) - tr.SetError() - return err - } - window := float64(fi.Size()) * 0.1 // 10% of the file as window. - - // Pick a random start point for the log. - skipFirstM := float64(rand.Int63n(fi.Size())) // Pick a random starting location. - skipFirstM -= window // Avoid hitting EOF by moving back by window. - skipFirstM /= float64(mi) // Convert to MBs. - tr.LazyPrintf("Skip first %5.2f MB of file of size: %d MB", skipFirstM, fi.Size()/mi) - var skipped float64 - - var r reason - start := time.Now() - y.AssertTrue(vlog.kv != nil) - s := new(y.Slice) - var numIterations int - err = vlog.iterate(lf, 0, func(e Entry, vp valuePointer) error { - numIterations++ - esz := float64(vp.Len) / (1 << 20) // in MBs. +4 for the CAS stuff. - if skipped < skipFirstM { - skipped += esz - return nil - } - - // Sample until we reach window size or 10K entries or exceed 10 seconds. - if r.count > 10000 { - tr.LazyPrintf("Stopping sampling after 10K entries.") - return errStop - } - if r.total > window { - tr.LazyPrintf("Stopping sampling after reaching window size.") - return errStop - } - if time.Since(start) > 10*time.Second { - tr.LazyPrintf("Stopping sampling after 10 seconds.") - return errStop - } - r.total += esz - r.count++ - - vs, err := vlog.kv.get(e.Key) - if err != nil { - return err - } - if discardEntry(e, vs) { - r.discard += esz - return nil - } - - // Value is still present in value log. - y.AssertTrue(len(vs.Value) > 0) - vp.Decode(vs.Value) - - if vp.Fid > lf.fid { - // Value is present in a later log. Discard. - r.discard += esz - return nil - } - if vp.Offset > e.offset { - // Value is present in a later offset, but in the same log. - r.discard += esz - return nil - } - if vp.Fid == lf.fid && vp.Offset == e.offset { - // This is still the active entry. This would need to be rewritten. - - } else { - vlog.elog.Printf("Reason=%+v\n", r) - - buf, cb, err := vlog.readValueBytes(vp, s) - if err != nil { - return errStop - } - ne := valueBytesToEntry(buf) - ne.offset = vp.Offset - ne.print("Latest Entry Header in LSM") - e.print("Latest Entry in Log") - runCallback(cb) - return errors.Errorf("This shouldn't happen. Latest Pointer:%+v. Meta:%v.", - vp, vs.Meta) - } - return nil - }) - - if err != nil { - tr.LazyPrintf("Error while iterating for RunGC: %v", err) - tr.SetError() - return err - } - tr.LazyPrintf("Fid: %d. Skipped: %5.2fMB Num iterations: %d. Data status=%+v\n", - lf.fid, skipped, numIterations, r) - - // If we sampled at least 10MB, we can make a call about rewrite. - if (r.count < 10000 && r.total < 10.0) || r.discard < discardRatio*r.total { - tr.LazyPrintf("Skipping GC on fid: %d", lf.fid) - return ErrNoRewrite - } - if err = vlog.rewrite(lf, tr); err != nil { - return err - } - tr.LazyPrintf("Done rewriting.") - return nil -} - -func (vlog *valueLog) waitOnGC(lc *y.Closer) { - defer lc.Done() - - <-lc.HasBeenClosed() // Wait for lc to be closed. - - // Block any GC in progress to finish, and don't allow any more writes to runGC by filling up - // the channel of size 1. - vlog.garbageCh <- struct{}{} -} - -func (vlog *valueLog) runGC(discardRatio float64, head valuePointer) error { - select { - case vlog.garbageCh <- struct{}{}: - // Pick a log file for GC. - tr := trace.New("Badger.ValueLog", "GC") - defer func() { - tr.Finish() - <-vlog.garbageCh - }() - - var err error - files := vlog.pickLog(head, tr) - tried := make(map[uint32]bool) - for _, lf := range files { - if _, done := tried[lf.fid]; done { - continue - } - tried[lf.fid] = true - err = vlog.doRunGC(lf, discardRatio, tr) - if err == nil { - vlog.deleteMoveKeysFor(lf.fid, tr) - return nil - } - } - return err - default: - return ErrRejected - } -} - -func (vlog *valueLog) updateGCStats(stats map[uint32]int64) { - vlog.lfDiscardStats.Lock() - for fid, sz := range stats { - vlog.lfDiscardStats.m[fid] += sz - } - vlog.lfDiscardStats.Unlock() -} diff --git a/vendor/github.com/dgraph-io/badger/value_test.go b/vendor/github.com/dgraph-io/badger/value_test.go deleted file mode 100644 index 43c7f0c..0000000 --- a/vendor/github.com/dgraph-io/badger/value_test.go +++ /dev/null @@ -1,680 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package badger - -import ( - "fmt" - "io/ioutil" - "math/rand" - "os" - "testing" - - "github.com/dgraph-io/badger/y" - "github.com/stretchr/testify/require" - "golang.org/x/net/trace" -) - -func TestValueBasic(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - y.Check(err) - defer os.RemoveAll(dir) - - kv, _ := Open(getTestOptions(dir)) - defer kv.Close() - log := &kv.vlog - - // Use value big enough that the value log writes them even if SyncWrites is false. - const val1 = "sampleval012345678901234567890123" - const val2 = "samplevalb012345678901234567890123" - require.True(t, len(val1) >= kv.opt.ValueThreshold) - - e := &Entry{ - Key: []byte("samplekey"), - Value: []byte(val1), - meta: bitValuePointer, - } - e2 := &Entry{ - Key: []byte("samplekeyb"), - Value: []byte(val2), - meta: bitValuePointer, - } - - b := new(request) - b.Entries = []*Entry{e, e2} - - log.write([]*request{b}) - require.Len(t, b.Ptrs, 2) - t.Logf("Pointer written: %+v %+v\n", b.Ptrs[0], b.Ptrs[1]) - - s := new(y.Slice) - buf1, cb1, err1 := log.readValueBytes(b.Ptrs[0], s) - buf2, cb2, err2 := log.readValueBytes(b.Ptrs[1], s) - require.NoError(t, err1) - require.NoError(t, err2) - defer runCallback(cb1) - defer runCallback(cb2) - - readEntries := []Entry{valueBytesToEntry(buf1), valueBytesToEntry(buf2)} - require.EqualValues(t, []Entry{ - { - Key: []byte("samplekey"), - Value: []byte(val1), - meta: bitValuePointer, - }, - { - Key: []byte("samplekeyb"), - Value: []byte(val2), - meta: bitValuePointer, - }, - }, readEntries) - -} - -func TestValueGC(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - opt := getTestOptions(dir) - opt.ValueLogFileSize = 1 << 20 - - kv, _ := Open(opt) - defer kv.Close() - - sz := 32 << 10 - txn := kv.NewTransaction(true) - for i := 0; i < 100; i++ { - v := make([]byte, sz) - rand.Read(v[:rand.Intn(sz)]) - require.NoError(t, txn.Set([]byte(fmt.Sprintf("key%d", i)), v)) - if i%20 == 0 { - require.NoError(t, txn.Commit(nil)) - txn = kv.NewTransaction(true) - } - } - require.NoError(t, txn.Commit(nil)) - - for i := 0; i < 45; i++ { - txnDelete(t, kv, []byte(fmt.Sprintf("key%d", i))) - } - - kv.vlog.filesLock.RLock() - lf := kv.vlog.filesMap[kv.vlog.sortedFids()[0]] - kv.vlog.filesLock.RUnlock() - - // lf.iterate(0, func(e Entry) bool { - // e.print("lf") - // return true - // }) - - tr := trace.New("Test", "Test") - defer tr.Finish() - kv.vlog.rewrite(lf, tr) - for i := 45; i < 100; i++ { - key := []byte(fmt.Sprintf("key%d", i)) - - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get(key) - require.NoError(t, err) - val := getItemValue(t, item) - require.NotNil(t, val) - require.True(t, len(val) == sz, "Size found: %d", len(val)) - return nil - })) - } -} - -func TestValueGC2(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - opt := getTestOptions(dir) - opt.ValueLogFileSize = 1 << 20 - - kv, _ := Open(opt) - defer kv.Close() - - sz := 32 << 10 - txn := kv.NewTransaction(true) - for i := 0; i < 100; i++ { - v := make([]byte, sz) - rand.Read(v[:rand.Intn(sz)]) - require.NoError(t, txn.Set([]byte(fmt.Sprintf("key%d", i)), v)) - if i%20 == 0 { - require.NoError(t, txn.Commit(nil)) - txn = kv.NewTransaction(true) - } - } - require.NoError(t, txn.Commit(nil)) - - for i := 0; i < 5; i++ { - txnDelete(t, kv, []byte(fmt.Sprintf("key%d", i))) - } - - for i := 5; i < 10; i++ { - v := []byte(fmt.Sprintf("value%d", i)) - txnSet(t, kv, []byte(fmt.Sprintf("key%d", i)), v, 0) - } - - kv.vlog.filesLock.RLock() - lf := kv.vlog.filesMap[kv.vlog.sortedFids()[0]] - kv.vlog.filesLock.RUnlock() - - // lf.iterate(0, func(e Entry) bool { - // e.print("lf") - // return true - // }) - - tr := trace.New("Test", "Test") - defer tr.Finish() - kv.vlog.rewrite(lf, tr) - for i := 0; i < 5; i++ { - key := []byte(fmt.Sprintf("key%d", i)) - require.NoError(t, kv.View(func(txn *Txn) error { - _, err := txn.Get(key) - require.Equal(t, ErrKeyNotFound, err) - return nil - })) - } - for i := 5; i < 10; i++ { - key := []byte(fmt.Sprintf("key%d", i)) - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get(key) - require.NoError(t, err) - val := getItemValue(t, item) - require.NotNil(t, val) - require.Equal(t, string(val), fmt.Sprintf("value%d", i)) - return nil - })) - } - for i := 10; i < 100; i++ { - key := []byte(fmt.Sprintf("key%d", i)) - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get(key) - require.NoError(t, err) - val := getItemValue(t, item) - require.NotNil(t, val) - require.True(t, len(val) == sz, "Size found: %d", len(val)) - return nil - })) - } -} - -func TestValueGC3(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - opt := getTestOptions(dir) - opt.ValueLogFileSize = 1 << 20 - - kv, err := Open(opt) - require.NoError(t, err) - defer kv.Close() - - // We want to test whether an iterator can continue through a value log GC. - - valueSize := 32 << 10 - - var value3 []byte - txn := kv.NewTransaction(true) - for i := 0; i < 100; i++ { - v := make([]byte, valueSize) // 32K * 100 will take >=3'276'800 B. - if i == 3 { - value3 = v - } - rand.Read(v[:]) - // Keys key000, key001, key002, such that sorted order matches insertion order - require.NoError(t, txn.Set([]byte(fmt.Sprintf("key%03d", i)), v)) - if i%20 == 0 { - require.NoError(t, txn.Commit(nil)) - txn = kv.NewTransaction(true) - } - } - require.NoError(t, txn.Commit(nil)) - - // Start an iterator to keys in the first value log file - itOpt := IteratorOptions{ - PrefetchValues: false, - PrefetchSize: 0, - Reverse: false, - } - - txn = kv.NewTransaction(true) - it := txn.NewIterator(itOpt) - defer it.Close() - // Walk a few keys - it.Rewind() - require.True(t, it.Valid()) - item := it.Item() - require.Equal(t, []byte("key000"), item.Key()) - it.Next() - require.True(t, it.Valid()) - item = it.Item() - require.Equal(t, []byte("key001"), item.Key()) - it.Next() - require.True(t, it.Valid()) - item = it.Item() - require.Equal(t, []byte("key002"), item.Key()) - - // Like other tests, we pull out a logFile to rewrite it directly - - kv.vlog.filesLock.RLock() - logFile := kv.vlog.filesMap[kv.vlog.sortedFids()[0]] - kv.vlog.filesLock.RUnlock() - - tr := trace.New("Test", "Test") - defer tr.Finish() - kv.vlog.rewrite(logFile, tr) - it.Next() - require.True(t, it.Valid()) - item = it.Item() - require.Equal(t, []byte("key003"), item.Key()) - - v3, err := item.Value() - require.NoError(t, err) - require.Equal(t, value3, v3) -} - -func TestValueGC4(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - opt := getTestOptions(dir) - opt.ValueLogFileSize = 1 << 20 - - kv, _ := Open(opt) - defer kv.Close() - - sz := 128 << 10 // 5 entries per value log file. - txn := kv.NewTransaction(true) - for i := 0; i < 24; i++ { - v := make([]byte, sz) - rand.Read(v[:rand.Intn(sz)]) - require.NoError(t, txn.Set([]byte(fmt.Sprintf("key%d", i)), v)) - if i%3 == 0 { - require.NoError(t, txn.Commit(nil)) - txn = kv.NewTransaction(true) - } - } - require.NoError(t, txn.Commit(nil)) - - for i := 0; i < 8; i++ { - txnDelete(t, kv, []byte(fmt.Sprintf("key%d", i))) - } - - for i := 8; i < 16; i++ { - v := []byte(fmt.Sprintf("value%d", i)) - txnSet(t, kv, []byte(fmt.Sprintf("key%d", i)), v, 0) - } - - kv.vlog.filesLock.RLock() - lf0 := kv.vlog.filesMap[kv.vlog.sortedFids()[0]] - lf1 := kv.vlog.filesMap[kv.vlog.sortedFids()[1]] - kv.vlog.filesLock.RUnlock() - - // lf.iterate(0, func(e Entry) bool { - // e.print("lf") - // return true - // }) - - tr := trace.New("Test", "Test") - defer tr.Finish() - kv.vlog.rewrite(lf0, tr) - kv.vlog.rewrite(lf1, tr) - - // Replay value log - kv.vlog.Replay(valuePointer{Fid: 2}, replayFunction(kv)) - - for i := 0; i < 8; i++ { - key := []byte(fmt.Sprintf("key%d", i)) - require.NoError(t, kv.View(func(txn *Txn) error { - _, err := txn.Get(key) - require.Equal(t, ErrKeyNotFound, err) - return nil - })) - } - for i := 8; i < 16; i++ { - key := []byte(fmt.Sprintf("key%d", i)) - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get(key) - require.NoError(t, err) - val := getItemValue(t, item) - require.NotNil(t, val) - require.Equal(t, string(val), fmt.Sprintf("value%d", i)) - return nil - })) - } -} - -func TestChecksums(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - // Set up SST with K1=V1 - opts := getTestOptions(dir) - opts.Truncate = true - opts.ValueLogFileSize = 100 * 1024 * 1024 // 100Mb - kv, err := Open(opts) - require.NoError(t, err) - require.NoError(t, kv.Close()) - - var ( - k0 = []byte("k0") - k1 = []byte("k1") - k2 = []byte("k2") - k3 = []byte("k3") - v0 = []byte("value0-012345678901234567890123012345678901234567890123") - v1 = []byte("value1-012345678901234567890123012345678901234567890123") - v2 = []byte("value2-012345678901234567890123012345678901234567890123") - v3 = []byte("value3-012345678901234567890123012345678901234567890123") - ) - // Make sure the value log would actually store the item - require.True(t, len(v0) >= kv.opt.ValueThreshold) - - // Use a vlog with K0=V0 and a (corrupted) second transaction(k1,k2) - buf := createVlog(t, []*Entry{ - {Key: k0, Value: v0}, - {Key: k1, Value: v1}, - {Key: k2, Value: v2}, - }) - buf[len(buf)-1]++ // Corrupt last byte - require.NoError(t, ioutil.WriteFile(vlogFilePath(dir, 0), buf, 0777)) - - // K1 should exist, but K2 shouldn't. - kv, err = Open(opts) - require.NoError(t, err) - - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get(k0) - require.NoError(t, err) - require.Equal(t, getItemValue(t, item), v0) - - _, err = txn.Get(k1) - require.Equal(t, ErrKeyNotFound, err) - - _, err = txn.Get(k2) - require.Equal(t, ErrKeyNotFound, err) - return nil - })) - - // Write K3 at the end of the vlog. - txnSet(t, kv, k3, v3, 0) - require.NoError(t, kv.Close()) - - // The vlog should contain K0 and K3 (K1 and k2 was lost when Badger started up - // last due to checksum failure). - kv, err = Open(opts) - require.NoError(t, err) - - { - txn := kv.NewTransaction(false) - - iter := txn.NewIterator(DefaultIteratorOptions) - iter.Seek(k0) - require.True(t, iter.Valid()) - it := iter.Item() - require.Equal(t, it.Key(), k0) - require.Equal(t, getItemValue(t, it), v0) - iter.Next() - require.True(t, iter.Valid()) - it = iter.Item() - require.Equal(t, it.Key(), k3) - require.Equal(t, getItemValue(t, it), v3) - - iter.Close() - txn.Discard() - } - - require.NoError(t, kv.Close()) -} - -func TestPartialAppendToValueLog(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - // Create skeleton files. - opts := getTestOptions(dir) - opts.Truncate = true - opts.ValueLogFileSize = 100 * 1024 * 1024 // 100Mb - kv, err := Open(opts) - require.NoError(t, err) - require.NoError(t, kv.Close()) - - var ( - k0 = []byte("k0") - k1 = []byte("k1") - k2 = []byte("k2") - k3 = []byte("k3") - v0 = []byte("value0-01234567890123456789012012345678901234567890123") - v1 = []byte("value1-01234567890123456789012012345678901234567890123") - v2 = []byte("value2-01234567890123456789012012345678901234567890123") - v3 = []byte("value3-01234567890123456789012012345678901234567890123") - ) - // Values need to be long enough to actually get written to value log. - require.True(t, len(v3) >= kv.opt.ValueThreshold) - - // Create truncated vlog to simulate a partial append. - // k0 - single transaction, k1 and k2 in another transaction - buf := createVlog(t, []*Entry{ - {Key: k0, Value: v0}, - {Key: k1, Value: v1}, - {Key: k2, Value: v2}, - }) - buf = buf[:len(buf)-6] - require.NoError(t, ioutil.WriteFile(vlogFilePath(dir, 0), buf, 0777)) - - // Badger should now start up - kv, err = Open(opts) - require.NoError(t, err) - - require.NoError(t, kv.View(func(txn *Txn) error { - item, err := txn.Get(k0) - require.NoError(t, err) - require.Equal(t, v0, getItemValue(t, item)) - - _, err = txn.Get(k1) - require.Equal(t, ErrKeyNotFound, err) - _, err = txn.Get(k2) - require.Equal(t, ErrKeyNotFound, err) - return nil - })) - - // When K3 is set, it should be persisted after a restart. - txnSet(t, kv, k3, v3, 0) - require.NoError(t, kv.Close()) - kv, err = Open(getTestOptions(dir)) - require.NoError(t, err) - checkKeys(t, kv, [][]byte{k3}) - - // Replay value log from beginning, badger head is past k2. - kv.vlog.Replay(valuePointer{Fid: 0}, replayFunction(kv)) - require.NoError(t, kv.Close()) -} - -func TestReadOnlyOpenWithPartialAppendToValueLog(t *testing.T) { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - // Create skeleton files. - opts := getTestOptions(dir) - opts.ValueLogFileSize = 100 * 1024 * 1024 // 100Mb - kv, err := Open(opts) - require.NoError(t, err) - require.NoError(t, kv.Close()) - - var ( - k0 = []byte("k0") - k1 = []byte("k1") - k2 = []byte("k2") - v0 = []byte("value0-012345678901234567890123") - v1 = []byte("value1-012345678901234567890123") - v2 = []byte("value2-012345678901234567890123") - ) - - // Create truncated vlog to simulate a partial append. - // k0 - single transaction, k1 and k2 in another transaction - buf := createVlog(t, []*Entry{ - {Key: k0, Value: v0}, - {Key: k1, Value: v1}, - {Key: k2, Value: v2}, - }) - buf = buf[:len(buf)-6] - require.NoError(t, ioutil.WriteFile(vlogFilePath(dir, 0), buf, 0777)) - - opts.ReadOnly = true - // Badger should fail a read-only open with values to replay - kv, err = Open(opts) - require.Error(t, err) - require.Regexp(t, "Database was not properly closed, cannot open read-only|Read-only mode is not supported on Windows", err.Error()) -} - -func TestValueLogTrigger(t *testing.T) { - t.Skip("Difficult to trigger compaction, so skipping. Re-enable after fixing #226") - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opt := getTestOptions(dir) - opt.ValueLogFileSize = 1 << 20 - kv, err := Open(opt) - require.NoError(t, err) - - // Write a lot of data, so it creates some work for valug log GC. - sz := 32 << 10 - txn := kv.NewTransaction(true) - for i := 0; i < 100; i++ { - v := make([]byte, sz) - rand.Read(v[:rand.Intn(sz)]) - require.NoError(t, txn.Set([]byte(fmt.Sprintf("key%d", i)), v)) - if i%20 == 0 { - require.NoError(t, txn.Commit(nil)) - txn = kv.NewTransaction(true) - } - } - require.NoError(t, txn.Commit(nil)) - - for i := 0; i < 45; i++ { - txnDelete(t, kv, []byte(fmt.Sprintf("key%d", i))) - } - - require.NoError(t, kv.RunValueLogGC(0.5)) - - require.NoError(t, kv.Close()) - - err = kv.RunValueLogGC(0.5) - require.Equal(t, ErrRejected, err, "Error should be returned after closing DB.") -} - -func createVlog(t *testing.T, entries []*Entry) []byte { - dir, err := ioutil.TempDir("", "badger") - require.NoError(t, err) - defer os.RemoveAll(dir) - - opts := getTestOptions(dir) - opts.ValueLogFileSize = 100 * 1024 * 1024 // 100Mb - kv, err := Open(opts) - require.NoError(t, err) - txnSet(t, kv, entries[0].Key, entries[0].Value, entries[0].meta) - entries = entries[1:] - txn := kv.NewTransaction(true) - for _, entry := range entries { - require.NoError(t, txn.SetWithMeta(entry.Key, entry.Value, entry.meta)) - } - require.NoError(t, txn.Commit(nil)) - require.NoError(t, kv.Close()) - - filename := vlogFilePath(dir, 0) - buf, err := ioutil.ReadFile(filename) - require.NoError(t, err) - return buf -} - -func checkKeys(t *testing.T, kv *DB, keys [][]byte) { - i := 0 - txn := kv.NewTransaction(false) - iter := txn.NewIterator(IteratorOptions{}) - for iter.Seek(keys[0]); iter.Valid(); iter.Next() { - require.Equal(t, iter.Item().Key(), keys[i]) - i++ - } - require.Equal(t, i, len(keys)) -} - -func BenchmarkReadWrite(b *testing.B) { - rwRatio := []float32{ - 0.1, 0.2, 0.5, 1.0, - } - valueSize := []int{ - 64, 128, 256, 512, 1024, 2048, 4096, 8192, 16384, - } - - for _, vsz := range valueSize { - for _, rw := range rwRatio { - b.Run(fmt.Sprintf("%3.1f,%04d", rw, vsz), func(b *testing.B) { - var vl valueLog - dir, err := ioutil.TempDir("", "vlog") - y.Check(err) - defer os.RemoveAll(dir) - err = vl.Open(nil, getTestOptions(dir)) - y.Check(err) - defer vl.Close() - b.ResetTimer() - - for i := 0; i < b.N; i++ { - e := new(Entry) - e.Key = make([]byte, 16) - e.Value = make([]byte, vsz) - bl := new(request) - bl.Entries = []*Entry{e} - - var ptrs []valuePointer - - vl.write([]*request{bl}) - ptrs = append(ptrs, bl.Ptrs...) - - f := rand.Float32() - if f < rw { - vl.write([]*request{bl}) - - } else { - ln := len(ptrs) - if ln == 0 { - b.Fatalf("Zero length of ptrs") - } - idx := rand.Intn(ln) - s := new(y.Slice) - buf, cb, err := vl.readValueBytes(ptrs[idx], s) - if err != nil { - b.Fatalf("Benchmark Read: %v", err) - } - - e := valueBytesToEntry(buf) - if len(e.Key) != 16 { - b.Fatalf("Key is invalid") - } - if len(e.Value) != vsz { - b.Fatalf("Value is invalid") - } - cb() - } - } - }) - } - } -} diff --git a/vendor/github.com/dgraph-io/badger/y/error.go b/vendor/github.com/dgraph-io/badger/y/error.go deleted file mode 100644 index 59bb283..0000000 --- a/vendor/github.com/dgraph-io/badger/y/error.go +++ /dev/null @@ -1,83 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -// This file contains some functions for error handling. Note that we are moving -// towards using x.Trace, i.e., rpc tracing using net/tracer. But for now, these -// functions are useful for simple checks logged on one machine. -// Some common use cases are: -// (1) You receive an error from external lib, and would like to check/log fatal. -// For this, use x.Check, x.Checkf. These will check for err != nil, which is -// more common in Go. If you want to check for boolean being true, use -// x.Assert, x.Assertf. -// (2) You receive an error from external lib, and would like to pass on with some -// stack trace information. In this case, use x.Wrap or x.Wrapf. -// (3) You want to generate a new error with stack trace info. Use x.Errorf. - -import ( - "fmt" - "log" - - "github.com/pkg/errors" -) - -var debugMode = true - -// Check logs fatal if err != nil. -func Check(err error) { - if err != nil { - log.Fatalf("%+v", Wrap(err)) - } -} - -// Check2 acts as convenience wrapper around Check, using the 2nd argument as error. -func Check2(_ interface{}, err error) { - Check(err) -} - -// AssertTrue asserts that b is true. Otherwise, it would log fatal. -func AssertTrue(b bool) { - if !b { - log.Fatalf("%+v", errors.Errorf("Assert failed")) - } -} - -// AssertTruef is AssertTrue with extra info. -func AssertTruef(b bool, format string, args ...interface{}) { - if !b { - log.Fatalf("%+v", errors.Errorf(format, args...)) - } -} - -// Wrap wraps errors from external lib. -func Wrap(err error) error { - if !debugMode { - return err - } - return errors.Wrap(err, "") -} - -// Wrapf is Wrap with extra info. -func Wrapf(err error, format string, args ...interface{}) error { - if !debugMode { - if err == nil { - return nil - } - return fmt.Errorf(format+" error: %+v", append(args, err)...) - } - return errors.Wrapf(err, format, args...) -} diff --git a/vendor/github.com/dgraph-io/badger/y/file_dsync.go b/vendor/github.com/dgraph-io/badger/y/file_dsync.go deleted file mode 100644 index 3f3445e..0000000 --- a/vendor/github.com/dgraph-io/badger/y/file_dsync.go +++ /dev/null @@ -1,25 +0,0 @@ -// +build !dragonfly,!freebsd,!windows - -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import "golang.org/x/sys/unix" - -func init() { - datasyncFileFlag = unix.O_DSYNC -} diff --git a/vendor/github.com/dgraph-io/badger/y/file_nodsync.go b/vendor/github.com/dgraph-io/badger/y/file_nodsync.go deleted file mode 100644 index b68be7a..0000000 --- a/vendor/github.com/dgraph-io/badger/y/file_nodsync.go +++ /dev/null @@ -1,25 +0,0 @@ -// +build dragonfly freebsd windows - -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import "syscall" - -func init() { - datasyncFileFlag = syscall.O_SYNC -} diff --git a/vendor/github.com/dgraph-io/badger/y/iterator.go b/vendor/github.com/dgraph-io/badger/y/iterator.go deleted file mode 100644 index 719e8ec..0000000 --- a/vendor/github.com/dgraph-io/badger/y/iterator.go +++ /dev/null @@ -1,264 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import ( - "bytes" - "container/heap" - "encoding/binary" - - "github.com/pkg/errors" -) - -// ValueStruct represents the value info that can be associated with a key, but also the internal -// Meta field. -type ValueStruct struct { - Meta byte - UserMeta byte - ExpiresAt uint64 - Value []byte - - Version uint64 // This field is not serialized. Only for internal usage. -} - -func sizeVarint(x uint64) (n int) { - for { - n++ - x >>= 7 - if x == 0 { - break - } - } - return n -} - -// EncodedSize is the size of the ValueStruct when encoded -func (v *ValueStruct) EncodedSize() uint16 { - sz := len(v.Value) + 2 // meta, usermeta. - if v.ExpiresAt == 0 { - return uint16(sz + 1) - } - - enc := sizeVarint(v.ExpiresAt) - return uint16(sz + enc) -} - -// Decode uses the length of the slice to infer the length of the Value field. -func (v *ValueStruct) Decode(b []byte) { - v.Meta = b[0] - v.UserMeta = b[1] - var sz int - v.ExpiresAt, sz = binary.Uvarint(b[2:]) - v.Value = b[2+sz:] -} - -// Encode expects a slice of length at least v.EncodedSize(). -func (v *ValueStruct) Encode(b []byte) { - b[0] = v.Meta - b[1] = v.UserMeta - sz := binary.PutUvarint(b[2:], v.ExpiresAt) - copy(b[2+sz:], v.Value) -} - -// EncodeTo should be kept in sync with the Encode function above. The reason -// this function exists is to avoid creating byte arrays per key-value pair in -// table/builder.go. -func (v *ValueStruct) EncodeTo(buf *bytes.Buffer) { - buf.WriteByte(v.Meta) - buf.WriteByte(v.UserMeta) - var enc [binary.MaxVarintLen64]byte - sz := binary.PutUvarint(enc[:], v.ExpiresAt) - buf.Write(enc[:sz]) - buf.Write(v.Value) -} - -// Iterator is an interface for a basic iterator. -type Iterator interface { - Next() - Rewind() - Seek(key []byte) - Key() []byte - Value() ValueStruct - Valid() bool - - // All iterators should be closed so that file garbage collection works. - Close() error -} - -type elem struct { - itr Iterator - nice int - reversed bool -} - -type elemHeap []*elem - -func (eh elemHeap) Len() int { return len(eh) } -func (eh elemHeap) Swap(i, j int) { eh[i], eh[j] = eh[j], eh[i] } -func (eh *elemHeap) Push(x interface{}) { *eh = append(*eh, x.(*elem)) } -func (eh *elemHeap) Pop() interface{} { - // Remove the last element, because Go has already swapped 0th elem <-> last. - old := *eh - n := len(old) - x := old[n-1] - *eh = old[0 : n-1] - return x -} -func (eh elemHeap) Less(i, j int) bool { - cmp := CompareKeys(eh[i].itr.Key(), eh[j].itr.Key()) - if cmp < 0 { - return !eh[i].reversed - } - if cmp > 0 { - return eh[i].reversed - } - // The keys are equal. In this case, lower nice take precedence. This is important. - return eh[i].nice < eh[j].nice -} - -// MergeIterator merges multiple iterators. -// NOTE: MergeIterator owns the array of iterators and is responsible for closing them. -type MergeIterator struct { - h elemHeap - curKey []byte - reversed bool - - all []Iterator -} - -// NewMergeIterator returns a new MergeIterator from a list of Iterators. -func NewMergeIterator(iters []Iterator, reversed bool) *MergeIterator { - m := &MergeIterator{all: iters, reversed: reversed} - m.h = make(elemHeap, 0, len(iters)) - m.initHeap() - return m -} - -func (s *MergeIterator) storeKey(smallest Iterator) { - if cap(s.curKey) < len(smallest.Key()) { - s.curKey = make([]byte, 2*len(smallest.Key())) - } - s.curKey = s.curKey[:len(smallest.Key())] - copy(s.curKey, smallest.Key()) -} - -// initHeap checks all iterators and initializes our heap and array of keys. -// Whenever we reverse direction, we need to run this. -func (s *MergeIterator) initHeap() { - s.h = s.h[:0] - for idx, itr := range s.all { - if !itr.Valid() { - continue - } - e := &elem{itr: itr, nice: idx, reversed: s.reversed} - s.h = append(s.h, e) - } - heap.Init(&s.h) - for len(s.h) > 0 { - it := s.h[0].itr - if it == nil || !it.Valid() { - heap.Pop(&s.h) - continue - } - s.storeKey(s.h[0].itr) - break - } -} - -// Valid returns whether the MergeIterator is at a valid element. -func (s *MergeIterator) Valid() bool { - if s == nil { - return false - } - if len(s.h) == 0 { - return false - } - return s.h[0].itr.Valid() -} - -// Key returns the key associated with the current iterator -func (s *MergeIterator) Key() []byte { - if len(s.h) == 0 { - return nil - } - return s.h[0].itr.Key() -} - -// Value returns the value associated with the iterator. -func (s *MergeIterator) Value() ValueStruct { - if len(s.h) == 0 { - return ValueStruct{} - } - return s.h[0].itr.Value() -} - -// Next returns the next element. If it is the same as the current key, ignore it. -func (s *MergeIterator) Next() { - if len(s.h) == 0 { - return - } - - smallest := s.h[0].itr - smallest.Next() - - for len(s.h) > 0 { - smallest = s.h[0].itr - if !smallest.Valid() { - heap.Pop(&s.h) - continue - } - - heap.Fix(&s.h, 0) - smallest = s.h[0].itr - if smallest.Valid() { - if !bytes.Equal(smallest.Key(), s.curKey) { - break - } - smallest.Next() - } - } - if !smallest.Valid() { - return - } - s.storeKey(smallest) -} - -// Rewind seeks to first element (or last element for reverse iterator). -func (s *MergeIterator) Rewind() { - for _, itr := range s.all { - itr.Rewind() - } - s.initHeap() -} - -// Seek brings us to element with key >= given key. -func (s *MergeIterator) Seek(key []byte) { - for _, itr := range s.all { - itr.Seek(key) - } - s.initHeap() -} - -// Close implements y.Iterator -func (s *MergeIterator) Close() error { - for _, itr := range s.all { - if err := itr.Close(); err != nil { - return errors.Wrap(err, "MergeIterator") - } - } - return nil -} diff --git a/vendor/github.com/dgraph-io/badger/y/iterator_test.go b/vendor/github.com/dgraph-io/badger/y/iterator_test.go deleted file mode 100644 index cff88be..0000000 --- a/vendor/github.com/dgraph-io/badger/y/iterator_test.go +++ /dev/null @@ -1,234 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import ( - "sort" - "testing" - - "github.com/stretchr/testify/require" -) - -type SimpleIterator struct { - keys [][]byte - vals [][]byte - idx int - reversed bool -} - -var ( - closeCount int -) - -func (s *SimpleIterator) Close() error { closeCount++; return nil } - -func (s *SimpleIterator) Next() { - if !s.reversed { - s.idx++ - } else { - s.idx-- - } -} - -func (s *SimpleIterator) Rewind() { - if !s.reversed { - s.idx = 0 - } else { - s.idx = len(s.keys) - 1 - } -} - -func (s *SimpleIterator) Seek(key []byte) { - key = KeyWithTs(key, 0) - if !s.reversed { - s.idx = sort.Search(len(s.keys), func(i int) bool { - return CompareKeys(s.keys[i], key) >= 0 - }) - } else { - n := len(s.keys) - s.idx = n - 1 - sort.Search(n, func(i int) bool { - return CompareKeys(s.keys[n-1-i], key) <= 0 - }) - } -} - -func (s *SimpleIterator) Key() []byte { return s.keys[s.idx] } -func (s *SimpleIterator) Value() ValueStruct { - return ValueStruct{ - Value: s.vals[s.idx], - UserMeta: 55, - Meta: 0, - } -} -func (s *SimpleIterator) Valid() bool { - return s.idx >= 0 && s.idx < len(s.keys) -} - -func newSimpleIterator(keys []string, vals []string, reversed bool) *SimpleIterator { - k := make([][]byte, len(keys)) - v := make([][]byte, len(vals)) - AssertTrue(len(keys) == len(vals)) - for i := 0; i < len(keys); i++ { - k[i] = KeyWithTs([]byte(keys[i]), 0) - v[i] = []byte(vals[i]) - } - return &SimpleIterator{ - keys: k, - vals: v, - idx: -1, - reversed: reversed, - } -} - -func getAll(it Iterator) ([]string, []string) { - var keys, vals []string - for ; it.Valid(); it.Next() { - k := it.Key() - keys = append(keys, string(ParseKey(k))) - v := it.Value() - vals = append(vals, string(v.Value)) - } - return keys, vals -} - -func closeAndCheck(t *testing.T, it Iterator, expected int) { - closeCount = 0 - it.Close() - require.EqualValues(t, expected, closeCount) -} - -func TestSimpleIterator(t *testing.T) { - keys := []string{"1", "2", "3"} - vals := []string{"v1", "v2", "v3"} - it := newSimpleIterator(keys, vals, false) - it.Rewind() - k, v := getAll(it) - require.EqualValues(t, keys, k) - require.EqualValues(t, vals, v) - - closeAndCheck(t, it, 1) -} - -func reversed(a []string) []string { - var out []string - for i := len(a) - 1; i >= 0; i-- { - out = append(out, a[i]) - } - return out -} - -func TestMergeSingle(t *testing.T) { - keys := []string{"1", "2", "3"} - vals := []string{"v1", "v2", "v3"} - it := newSimpleIterator(keys, vals, false) - mergeIt := NewMergeIterator([]Iterator{it}, false) - mergeIt.Rewind() - k, v := getAll(mergeIt) - require.EqualValues(t, keys, k) - require.EqualValues(t, vals, v) - closeAndCheck(t, mergeIt, 1) -} - -func TestMergeSingleReversed(t *testing.T) { - keys := []string{"1", "2", "3"} - vals := []string{"v1", "v2", "v3"} - it := newSimpleIterator(keys, vals, true) - mergeIt := NewMergeIterator([]Iterator{it}, true) - mergeIt.Rewind() - k, v := getAll(mergeIt) - require.EqualValues(t, reversed(keys), k) - require.EqualValues(t, reversed(vals), v) - closeAndCheck(t, mergeIt, 1) -} - -func TestMergeMore(t *testing.T) { - it := newSimpleIterator([]string{"1", "3", "7"}, []string{"a1", "a3", "a7"}, false) - it2 := newSimpleIterator([]string{"2", "3", "5"}, []string{"b2", "b3", "b5"}, false) - it3 := newSimpleIterator([]string{"1"}, []string{"c1"}, false) - it4 := newSimpleIterator([]string{"1", "7", "9"}, []string{"d1", "d7", "d9"}, false) - - mergeIt := NewMergeIterator([]Iterator{it, it2, it3, it4}, false) - expectedKeys := []string{"1", "2", "3", "5", "7", "9"} - expectedVals := []string{"a1", "b2", "a3", "b5", "a7", "d9"} - mergeIt.Rewind() - k, v := getAll(mergeIt) - require.EqualValues(t, expectedKeys, k) - require.EqualValues(t, expectedVals, v) - closeAndCheck(t, mergeIt, 4) -} - -// Ensure MergeIterator satisfies the Iterator interface -func TestMergeIteratorNested(t *testing.T) { - keys := []string{"1", "2", "3"} - vals := []string{"v1", "v2", "v3"} - it := newSimpleIterator(keys, vals, false) - mergeIt := NewMergeIterator([]Iterator{it}, false) - mergeIt2 := NewMergeIterator([]Iterator{mergeIt}, false) - mergeIt2.Rewind() - k, v := getAll(mergeIt2) - require.EqualValues(t, keys, k) - require.EqualValues(t, vals, v) - closeAndCheck(t, mergeIt2, 1) -} - -func TestMergeIteratorSeek(t *testing.T) { - it := newSimpleIterator([]string{"1", "3", "7"}, []string{"a1", "a3", "a7"}, false) - it2 := newSimpleIterator([]string{"2", "3", "5"}, []string{"b2", "b3", "b5"}, false) - it3 := newSimpleIterator([]string{"1"}, []string{"c1"}, false) - it4 := newSimpleIterator([]string{"1", "7", "9"}, []string{"d1", "d7", "d9"}, false) - mergeIt := NewMergeIterator([]Iterator{it, it2, it3, it4}, false) - mergeIt.Seek([]byte("4")) - k, v := getAll(mergeIt) - require.EqualValues(t, []string{"5", "7", "9"}, k) - require.EqualValues(t, []string{"b5", "a7", "d9"}, v) - closeAndCheck(t, mergeIt, 4) -} - -func TestMergeIteratorSeekReversed(t *testing.T) { - it := newSimpleIterator([]string{"1", "3", "7"}, []string{"a1", "a3", "a7"}, true) - it2 := newSimpleIterator([]string{"2", "3", "5"}, []string{"b2", "b3", "b5"}, true) - it3 := newSimpleIterator([]string{"1"}, []string{"c1"}, true) - it4 := newSimpleIterator([]string{"1", "7", "9"}, []string{"d1", "d7", "d9"}, true) - mergeIt := NewMergeIterator([]Iterator{it, it2, it3, it4}, true) - mergeIt.Seek([]byte("5")) - k, v := getAll(mergeIt) - require.EqualValues(t, []string{"5", "3", "2", "1"}, k) - require.EqualValues(t, []string{"b5", "a3", "b2", "a1"}, v) - closeAndCheck(t, mergeIt, 4) -} - -func TestMergeIteratorSeekInvalid(t *testing.T) { - it := newSimpleIterator([]string{"1", "3", "7"}, []string{"a1", "a3", "a7"}, false) - it2 := newSimpleIterator([]string{"2", "3", "5"}, []string{"b2", "b3", "b5"}, false) - it3 := newSimpleIterator([]string{"1"}, []string{"c1"}, false) - it4 := newSimpleIterator([]string{"1", "7", "9"}, []string{"d1", "d7", "d9"}, false) - mergeIt := NewMergeIterator([]Iterator{it, it2, it3, it4}, false) - mergeIt.Seek([]byte("f")) - require.False(t, mergeIt.Valid()) - closeAndCheck(t, mergeIt, 4) -} - -func TestMergeIteratorSeekInvalidReversed(t *testing.T) { - it := newSimpleIterator([]string{"1", "3", "7"}, []string{"a1", "a3", "a7"}, true) - it2 := newSimpleIterator([]string{"2", "3", "5"}, []string{"b2", "b3", "b5"}, true) - it3 := newSimpleIterator([]string{"1"}, []string{"c1"}, true) - it4 := newSimpleIterator([]string{"1", "7", "9"}, []string{"d1", "d7", "d9"}, true) - mergeIt := NewMergeIterator([]Iterator{it, it2, it3, it4}, true) - mergeIt.Seek([]byte("0")) - require.False(t, mergeIt.Valid()) - closeAndCheck(t, mergeIt, 4) -} diff --git a/vendor/github.com/dgraph-io/badger/y/metrics.go b/vendor/github.com/dgraph-io/badger/y/metrics.go deleted file mode 100644 index 2de17d1..0000000 --- a/vendor/github.com/dgraph-io/badger/y/metrics.go +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright (C) 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import "expvar" - -var ( - // LSMSize has size of the LSM in bytes - LSMSize *expvar.Map - // VlogSize has size of the value log in bytes - VlogSize *expvar.Map - // PendingWrites tracks the number of pending writes. - PendingWrites *expvar.Map - - // These are cumulative - - // NumReads has cumulative number of reads - NumReads *expvar.Int - // NumWrites has cumulative number of writes - NumWrites *expvar.Int - // NumBytesRead has cumulative number of bytes read - NumBytesRead *expvar.Int - // NumBytesWritten has cumulative number of bytes written - NumBytesWritten *expvar.Int - // NumLSMGets is number of LMS gets - NumLSMGets *expvar.Map - // NumLSMBloomHits is number of LMS bloom hits - NumLSMBloomHits *expvar.Map - // NumGets is number of gets - NumGets *expvar.Int - // NumPuts is number of puts - NumPuts *expvar.Int - // NumBlockedPuts is number of blocked puts - NumBlockedPuts *expvar.Int - // NumMemtableGets is number of memtable gets - NumMemtableGets *expvar.Int -) - -// These variables are global and have cumulative values for all kv stores. -func init() { - NumReads = expvar.NewInt("badger_disk_reads_total") - NumWrites = expvar.NewInt("badger_disk_writes_total") - NumBytesRead = expvar.NewInt("badger_read_bytes") - NumBytesWritten = expvar.NewInt("badger_written_bytes") - NumLSMGets = expvar.NewMap("badger_lsm_level_gets_total") - NumLSMBloomHits = expvar.NewMap("badger_lsm_bloom_hits_total") - NumGets = expvar.NewInt("badger_gets_total") - NumPuts = expvar.NewInt("badger_puts_total") - NumBlockedPuts = expvar.NewInt("badger_blocked_puts_total") - NumMemtableGets = expvar.NewInt("badger_memtable_gets_total") - LSMSize = expvar.NewMap("badger_lsm_size_bytes") - VlogSize = expvar.NewMap("badger_vlog_size_bytes") - PendingWrites = expvar.NewMap("badger_pending_writes_total") -} diff --git a/vendor/github.com/dgraph-io/badger/y/mmap_unix.go b/vendor/github.com/dgraph-io/badger/y/mmap_unix.go deleted file mode 100644 index f9203a0..0000000 --- a/vendor/github.com/dgraph-io/badger/y/mmap_unix.go +++ /dev/null @@ -1,63 +0,0 @@ -// +build !windows - -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import ( - "os" - "syscall" - "unsafe" - - "golang.org/x/sys/unix" -) - -// Mmap uses the mmap system call to memory-map a file. If writable is true, -// memory protection of the pages is set so that they may be written to as well. -func Mmap(fd *os.File, writable bool, size int64) ([]byte, error) { - mtype := unix.PROT_READ - if writable { - mtype |= unix.PROT_WRITE - } - return unix.Mmap(int(fd.Fd()), 0, int(size), mtype, unix.MAP_SHARED) -} - -// Munmap unmaps a previously mapped slice. -func Munmap(b []byte) error { - return unix.Munmap(b) -} - -// Madvise uses the madvise system call to give advise about the use of memory -// when using a slice that is memory-mapped to a file. Set the readahead flag to -// false if page references are expected in random order. -func Madvise(b []byte, readahead bool) error { - flags := unix.MADV_NORMAL - if !readahead { - flags = unix.MADV_RANDOM - } - return madvise(b, flags) -} - -// This is required because the unix package does not support the madvise system call on OS X. -func madvise(b []byte, advice int) (err error) { - _, _, e1 := syscall.Syscall(syscall.SYS_MADVISE, uintptr(unsafe.Pointer(&b[0])), - uintptr(len(b)), uintptr(advice)) - if e1 != 0 { - err = e1 - } - return -} diff --git a/vendor/github.com/dgraph-io/badger/y/mmap_windows.go b/vendor/github.com/dgraph-io/badger/y/mmap_windows.go deleted file mode 100644 index 0efb2d0..0000000 --- a/vendor/github.com/dgraph-io/badger/y/mmap_windows.go +++ /dev/null @@ -1,90 +0,0 @@ -// +build windows - -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import ( - "fmt" - "os" - "syscall" - "unsafe" -) - -func Mmap(fd *os.File, write bool, size int64) ([]byte, error) { - protect := syscall.PAGE_READONLY - access := syscall.FILE_MAP_READ - - if write { - protect = syscall.PAGE_READWRITE - access = syscall.FILE_MAP_WRITE - } - fi, err := fd.Stat() - if err != nil { - return nil, err - } - - // Truncate the database to the size of the mmap. - if fi.Size() < size { - if err := fd.Truncate(size); err != nil { - return nil, fmt.Errorf("truncate: %s", err) - } - } - - // Open a file mapping handle. - sizelo := uint32(size >> 32) - sizehi := uint32(size) & 0xffffffff - - handler, err := syscall.CreateFileMapping(syscall.Handle(fd.Fd()), nil, - uint32(protect), sizelo, sizehi, nil) - if err != nil { - return nil, os.NewSyscallError("CreateFileMapping", err) - } - - // Create the memory map. - addr, err := syscall.MapViewOfFile(handler, uint32(access), 0, 0, uintptr(size)) - if addr == 0 { - return nil, os.NewSyscallError("MapViewOfFile", err) - } - - // Close mapping handle. - if err := syscall.CloseHandle(syscall.Handle(handler)); err != nil { - return nil, os.NewSyscallError("CloseHandle", err) - } - - // Slice memory layout - // Copied this snippet from golang/sys package - var sl = struct { - addr uintptr - len int - cap int - }{addr, int(size), int(size)} - - // Use unsafe to turn sl into a []byte. - data := *(*[]byte)(unsafe.Pointer(&sl)) - - return data, nil -} - -func Munmap(b []byte) error { - return syscall.UnmapViewOfFile(uintptr(unsafe.Pointer(&b[0]))) -} - -func Madvise(b []byte, readahead bool) error { - // Do Nothing. We don’t care about this setting on Windows - return nil -} diff --git a/vendor/github.com/dgraph-io/badger/y/watermark.go b/vendor/github.com/dgraph-io/badger/y/watermark.go deleted file mode 100644 index 6fd3c89..0000000 --- a/vendor/github.com/dgraph-io/badger/y/watermark.go +++ /dev/null @@ -1,130 +0,0 @@ -/* - * Copyright 2018 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import ( - "container/heap" - "sync/atomic" - - "golang.org/x/net/trace" -) - -type uint64Heap []uint64 - -func (u uint64Heap) Len() int { return len(u) } -func (u uint64Heap) Less(i int, j int) bool { return u[i] < u[j] } -func (u uint64Heap) Swap(i int, j int) { u[i], u[j] = u[j], u[i] } -func (u *uint64Heap) Push(x interface{}) { *u = append(*u, x.(uint64)) } -func (u *uint64Heap) Pop() interface{} { - old := *u - n := len(old) - x := old[n-1] - *u = old[0 : n-1] - return x -} - -type mark struct { - readTs uint64 - done bool // Set to true if the pending mutation is done. -} -type WaterMark struct { - markCh chan mark - minReadTs uint64 - elog trace.EventLog -} - -// Init initializes a WaterMark struct. MUST be called before using it. -func (w *WaterMark) Init() { - w.markCh = make(chan mark, 1000) - w.elog = trace.NewEventLog("Badger", "MinReadTs") - go w.process() -} - -func (w *WaterMark) Begin(readTs uint64) { - w.markCh <- mark{readTs: readTs, done: false} -} -func (w *WaterMark) Done(readTs uint64) { - w.markCh <- mark{readTs: readTs, done: true} -} - -// DoneUntil returns the maximum index until which all tasks are done. -func (w *WaterMark) MinReadTs() uint64 { - return atomic.LoadUint64(&w.minReadTs) -} - -// process is used to process the Mark channel. This is not thread-safe, -// so only run one goroutine for process. One is sufficient, because -// all ops in the goroutine use only memory and cpu. -func (w *WaterMark) process() { - var reads uint64Heap - // pending maps raft proposal index to the number of pending mutations for this proposal. - pending := make(map[uint64]int) - - heap.Init(&reads) - var loop uint64 - - processOne := func(readTs uint64, done bool) { - // If not already done, then set. Otherwise, don't undo a done entry. - prev, present := pending[readTs] - if !present { - heap.Push(&reads, readTs) - } - - delta := 1 - if done { - delta = -1 - } - pending[readTs] = prev + delta - - loop++ - if len(reads) > 0 && loop%1000 == 0 { - min := reads[0] - w.elog.Printf("ReadTs: %4d. Size: %4d MinReadTs: %-4d Looking for: %-4d. Value: %d\n", - readTs, len(reads), w.MinReadTs(), min, pending[min]) - } - - // Update mark by going through all reads in order; and checking if they have - // been done. Stop at the first readTs, which isn't done. - minReadTs := w.MinReadTs() - // Don't assert that minReadTs < readTs, to avoid any inconsistencies caused by managed - // transactions, or testing where we explicitly set the readTs for transactions like in - // TestTxnVersions. - until := minReadTs - loops := 0 - - for len(reads) > 0 { - min := reads[0] - if done := pending[min]; done != 0 { - break // len(reads) will be > 0. - } - heap.Pop(&reads) - delete(pending, min) - until = min - loops++ - } - if until != minReadTs { - AssertTrue(atomic.CompareAndSwapUint64(&w.minReadTs, minReadTs, until)) - w.elog.Printf("MinReadTs: %d. Loops: %d\n", until, loops) - } - } - - for mark := range w.markCh { - if mark.readTs > 0 { - processOne(mark.readTs, mark.done) - } - } -} diff --git a/vendor/github.com/dgraph-io/badger/y/y.go b/vendor/github.com/dgraph-io/badger/y/y.go deleted file mode 100644 index 5927fd3..0000000 --- a/vendor/github.com/dgraph-io/badger/y/y.go +++ /dev/null @@ -1,209 +0,0 @@ -/* - * Copyright 2017 Dgraph Labs, Inc. and Contributors - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package y - -import ( - "bytes" - "encoding/binary" - "hash/crc32" - "math" - "os" - "sync" - - "github.com/pkg/errors" -) - -// ErrEOF indicates an end of file when trying to read from a memory mapped file -// and encountering the end of slice. -var ErrEOF = errors.New("End of mapped region") - -const ( - // Sync indicates that O_DSYNC should be set on the underlying file, - // ensuring that data writes do not return until the data is flushed - // to disk. - Sync = 1 << iota - // ReadOnly opens the underlying file on a read-only basis. - ReadOnly -) - -var ( - // This is O_DSYNC (datasync) on platforms that support it -- see file_unix.go - datasyncFileFlag = 0x0 - - // CastagnoliCrcTable is a CRC32 polynomial table - CastagnoliCrcTable = crc32.MakeTable(crc32.Castagnoli) -) - -// OpenExistingFile opens an existing file, errors if it doesn't exist. -func OpenExistingFile(filename string, flags uint32) (*os.File, error) { - openFlags := os.O_RDWR - if flags&ReadOnly != 0 { - openFlags = os.O_RDONLY - } - - if flags&Sync != 0 { - openFlags |= datasyncFileFlag - } - return os.OpenFile(filename, openFlags, 0) -} - -// CreateSyncedFile creates a new file (using O_EXCL), errors if it already existed. -func CreateSyncedFile(filename string, sync bool) (*os.File, error) { - flags := os.O_RDWR | os.O_CREATE | os.O_EXCL - if sync { - flags |= datasyncFileFlag - } - return os.OpenFile(filename, flags, 0666) -} - -// OpenSyncedFile creates the file if one doesn't exist. -func OpenSyncedFile(filename string, sync bool) (*os.File, error) { - flags := os.O_RDWR | os.O_CREATE - if sync { - flags |= datasyncFileFlag - } - return os.OpenFile(filename, flags, 0666) -} - -// OpenTruncFile opens the file with O_RDWR | O_CREATE | O_TRUNC -func OpenTruncFile(filename string, sync bool) (*os.File, error) { - flags := os.O_RDWR | os.O_CREATE | os.O_TRUNC - if sync { - flags |= datasyncFileFlag - } - return os.OpenFile(filename, flags, 0666) -} - -// SafeCopy does append(a[:0], src...). -func SafeCopy(a []byte, src []byte) []byte { - return append(a[:0], src...) -} - -// Copy copies a byte slice and returns the copied slice. -func Copy(a []byte) []byte { - b := make([]byte, len(a)) - copy(b, a) - return b -} - -// KeyWithTs generates a new key by appending ts to key. -func KeyWithTs(key []byte, ts uint64) []byte { - out := make([]byte, len(key)+8) - copy(out, key) - binary.BigEndian.PutUint64(out[len(key):], math.MaxUint64-ts) - return out -} - -// ParseTs parses the timestamp from the key bytes. -func ParseTs(key []byte) uint64 { - if len(key) <= 8 { - return 0 - } - return math.MaxUint64 - binary.BigEndian.Uint64(key[len(key)-8:]) -} - -// CompareKeys checks the key without timestamp and checks the timestamp if keyNoTs -// is same. -// a would be sorted higher than aa if we use bytes.compare -// All keys should have timestamp. -func CompareKeys(key1 []byte, key2 []byte) int { - AssertTrue(len(key1) > 8 && len(key2) > 8) - if cmp := bytes.Compare(key1[:len(key1)-8], key2[:len(key2)-8]); cmp != 0 { - return cmp - } - return bytes.Compare(key1[len(key1)-8:], key2[len(key2)-8:]) -} - -// ParseKey parses the actual key from the key bytes. -func ParseKey(key []byte) []byte { - if key == nil { - return nil - } - - AssertTruef(len(key) > 8, "key=%q", key) - return key[:len(key)-8] -} - -// SameKey checks for key equality ignoring the version timestamp suffix. -func SameKey(src, dst []byte) bool { - if len(src) != len(dst) { - return false - } - return bytes.Equal(ParseKey(src), ParseKey(dst)) -} - -// Slice holds a reusable buf, will reallocate if you request a larger size than ever before. -// One problem is with n distinct sizes in random order it'll reallocate log(n) times. -type Slice struct { - buf []byte -} - -// Resize reuses the Slice's buffer (or makes a new one) and returns a slice in that buffer of -// length sz. -func (s *Slice) Resize(sz int) []byte { - if cap(s.buf) < sz { - s.buf = make([]byte, sz) - } - return s.buf[0:sz] -} - -// Closer holds the two things we need to close a goroutine and wait for it to finish: a chan -// to tell the goroutine to shut down, and a WaitGroup with which to wait for it to finish shutting -// down. -type Closer struct { - closed chan struct{} - waiting sync.WaitGroup -} - -// NewCloser constructs a new Closer, with an initial count on the WaitGroup. -func NewCloser(initial int) *Closer { - ret := &Closer{closed: make(chan struct{})} - ret.waiting.Add(initial) - return ret -} - -// AddRunning Add()'s delta to the WaitGroup. -func (lc *Closer) AddRunning(delta int) { - lc.waiting.Add(delta) -} - -// Signal signals the HasBeenClosed signal. -func (lc *Closer) Signal() { - close(lc.closed) -} - -// HasBeenClosed gets signaled when Signal() is called. -func (lc *Closer) HasBeenClosed() <-chan struct{} { - return lc.closed -} - -// Done calls Done() on the WaitGroup. -func (lc *Closer) Done() { - lc.waiting.Done() -} - -// Wait waits on the WaitGroup. (It waits for NewCloser's initial value, AddRunning, and Done -// calls to balance out.) -func (lc *Closer) Wait() { - lc.waiting.Wait() -} - -// SignalAndWait calls Signal(), then Wait(). -func (lc *Closer) SignalAndWait() { - lc.Signal() - lc.Wait() -} diff --git a/vendor/github.com/dgryski/go-farm/.travis.yml b/vendor/github.com/dgryski/go-farm/.travis.yml deleted file mode 100644 index 10c8a83..0000000 --- a/vendor/github.com/dgryski/go-farm/.travis.yml +++ /dev/null @@ -1,38 +0,0 @@ -language: go - -sudo: false - -branches: - except: - - release - -branches: - only: - - master - - develop - - travis - -go: - - 1.9 - - tip - -matrix: - allow_failures: - - go: tip - -before_install: - - if [ -n "$GH_USER" ]; then git config --global github.user ${GH_USER}; fi; - - if [ -n "$GH_TOKEN" ]; then git config --global github.token ${GH_TOKEN}; fi; - - go get github.com/mattn/goveralls - -before_script: - - make deps - -script: - - make qa - -after_failure: - - cat ./target/test/report.xml - -after_success: - - if [ "$TRAVIS_GO_VERSION" = "1.9" ]; then $HOME/gopath/bin/goveralls -covermode=count -coverprofile=target/report/coverage.out -service=travis-ci; fi; diff --git a/vendor/github.com/dgryski/go-farm/LICENSE b/vendor/github.com/dgryski/go-farm/LICENSE deleted file mode 100644 index 3d07f66..0000000 --- a/vendor/github.com/dgryski/go-farm/LICENSE +++ /dev/null @@ -1,23 +0,0 @@ -As this is a highly derivative work, I have placed it under the same license as the original implementation: - -Copyright (c) 2014-2017 Damian Gryski -Copyright (c) 2016-2017 Nicola Asuni - Tecnick.com - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. - diff --git a/vendor/github.com/dgryski/go-farm/Makefile b/vendor/github.com/dgryski/go-farm/Makefile deleted file mode 100644 index f01244b..0000000 --- a/vendor/github.com/dgryski/go-farm/Makefile +++ /dev/null @@ -1,203 +0,0 @@ -# MAKEFILE -# -# @author Nicola Asuni -# @link https://github.com/dgryski/go-farm -# -# This file is intended to be executed in a Linux-compatible system. -# It also assumes that the project has been cloned in the right path under GOPATH: -# $GOPATH/src/github.com/dgryski/go-farm -# -# ------------------------------------------------------------------------------ - -# List special make targets that are not associated with files -.PHONY: help all test format fmtcheck vet lint coverage cyclo ineffassign misspell structcheck varcheck errcheck gosimple astscan qa deps clean nuke - -# Use bash as shell (Note: Ubuntu now uses dash which doesn't support PIPESTATUS). -SHELL=/bin/bash - -# CVS path (path to the parent dir containing the project) -CVSPATH=github.com/dgryski - -# Project owner -OWNER=dgryski - -# Project vendor -VENDOR=dgryski - -# Project name -PROJECT=go-farm - -# Project version -VERSION=$(shell cat VERSION) - -# Name of RPM or DEB package -PKGNAME=${VENDOR}-${PROJECT} - -# Current directory -CURRENTDIR=$(shell pwd) - -# GO lang path -ifneq ($(GOPATH),) - ifeq ($(findstring $(GOPATH),$(CURRENTDIR)),) - # the defined GOPATH is not valid - GOPATH= - endif -endif -ifeq ($(GOPATH),) - # extract the GOPATH - GOPATH=$(firstword $(subst /src/, ,$(CURRENTDIR))) -endif - -# --- MAKE TARGETS --- - -# Display general help about this command -help: - @echo "" - @echo "$(PROJECT) Makefile." - @echo "GOPATH=$(GOPATH)" - @echo "The following commands are available:" - @echo "" - @echo " make qa : Run all the tests" - @echo " make test : Run the unit tests" - @echo "" - @echo " make format : Format the source code" - @echo " make fmtcheck : Check if the source code has been formatted" - @echo " make vet : Check for suspicious constructs" - @echo " make lint : Check for style errors" - @echo " make coverage : Generate the coverage report" - @echo " make cyclo : Generate the cyclomatic complexity report" - @echo " make ineffassign : Detect ineffectual assignments" - @echo " make misspell : Detect commonly misspelled words in source files" - @echo " make structcheck : Find unused struct fields" - @echo " make varcheck : Find unused global variables and constants" - @echo " make errcheck : Check that error return values are used" - @echo " make gosimple : Suggest code simplifications" - @echo " make astscan : GO AST scanner" - @echo "" - @echo " make docs : Generate source code documentation" - @echo "" - @echo " make deps : Get the dependencies" - @echo " make clean : Remove any build artifact" - @echo " make nuke : Deletes any intermediate file" - @echo "" - - -# Alias for help target -all: help - -# Run the unit tests -test: - @mkdir -p target/test - @mkdir -p target/report - GOPATH=$(GOPATH) \ - go test \ - -covermode=atomic \ - -bench=. \ - -race \ - -cpuprofile=target/report/cpu.out \ - -memprofile=target/report/mem.out \ - -mutexprofile=target/report/mutex.out \ - -coverprofile=target/report/coverage.out \ - -v ./... | \ - tee >(PATH=$(GOPATH)/bin:$(PATH) go-junit-report > target/test/report.xml); \ - test $${PIPESTATUS[0]} -eq 0 - -# Format the source code -format: - @find . -type f -name "*.go" -exec gofmt -s -w {} \; - -# Check if the source code has been formatted -fmtcheck: - @mkdir -p target - @find . -type f -name "*.go" -exec gofmt -s -d {} \; | tee target/format.diff - @test ! -s target/format.diff || { echo "ERROR: the source code has not been formatted - please use 'make format' or 'gofmt'"; exit 1; } - -# Check for syntax errors -vet: - GOPATH=$(GOPATH) go vet . - -# Check for style errors -lint: - GOPATH=$(GOPATH) PATH=$(GOPATH)/bin:$(PATH) golint . - -# Generate the coverage report -coverage: - @mkdir -p target/report - GOPATH=$(GOPATH) \ - go tool cover -html=target/report/coverage.out -o target/report/coverage.html - -# Report cyclomatic complexity -cyclo: - @mkdir -p target/report - GOPATH=$(GOPATH) gocyclo -avg ./ | tee target/report/cyclo.txt ; test $${PIPESTATUS[0]} -eq 0 - -# Detect ineffectual assignments -ineffassign: - @mkdir -p target/report - GOPATH=$(GOPATH) ineffassign ./ | tee target/report/ineffassign.txt ; test $${PIPESTATUS[0]} -eq 0 - -# Detect commonly misspelled words in source files -misspell: - @mkdir -p target/report - GOPATH=$(GOPATH) misspell -error ./ | tee target/report/misspell.txt ; test $${PIPESTATUS[0]} -eq 0 - -# Find unused struct fields -structcheck: - @mkdir -p target/report - GOPATH=$(GOPATH) structcheck -a ./ | tee target/report/structcheck.txt - -# Find unused global variables and constants -varcheck: - @mkdir -p target/report - GOPATH=$(GOPATH) varcheck -e ./ | tee target/report/varcheck.txt - -# Check that error return values are used -errcheck: - @mkdir -p target/report - GOPATH=$(GOPATH) errcheck ./ | tee target/report/errcheck.txt - -# Suggest code simplifications -gosimple: - @mkdir -p target/report - GOPATH=$(GOPATH) gosimple ./ | tee target/report/gosimple.txt - -# AST scanner -astscan: - @mkdir -p target/report - GOPATH=$(GOPATH) gas .//*.go | tee target/report/astscan.txt - -# Generate source docs -docs: - @mkdir -p target/docs - nohup sh -c 'GOPATH=$(GOPATH) godoc -http=127.0.0.1:6060' > target/godoc_server.log 2>&1 & - wget --directory-prefix=target/docs/ --execute robots=off --retry-connrefused --recursive --no-parent --adjust-extension --page-requisites --convert-links http://127.0.0.1:6060/pkg/github.com/${VENDOR}/${PROJECT}/ ; kill -9 `lsof -ti :6060` - @echo ''${PKGNAME}' Documentation ...' > target/docs/index.html - -# Alias to run all quality-assurance checks -qa: fmtcheck test vet lint coverage cyclo ineffassign misspell structcheck varcheck errcheck gosimple astscan - -# --- INSTALL --- - -# Get the dependencies -deps: - GOPATH=$(GOPATH) go get ./... - GOPATH=$(GOPATH) go get github.com/golang/lint/golint - GOPATH=$(GOPATH) go get github.com/jstemmer/go-junit-report - GOPATH=$(GOPATH) go get github.com/axw/gocov/gocov - GOPATH=$(GOPATH) go get github.com/fzipp/gocyclo - GOPATH=$(GOPATH) go get github.com/gordonklaus/ineffassign - GOPATH=$(GOPATH) go get github.com/client9/misspell/cmd/misspell - GOPATH=$(GOPATH) go get github.com/opennota/check/cmd/structcheck - GOPATH=$(GOPATH) go get github.com/opennota/check/cmd/varcheck - GOPATH=$(GOPATH) go get github.com/kisielk/errcheck - GOPATH=$(GOPATH) go get honnef.co/go/tools/cmd/gosimple - GOPATH=$(GOPATH) go get github.com/GoASTScanner/gas - -# Remove any build artifact -clean: - GOPATH=$(GOPATH) go clean ./... - -# Deletes any intermediate file -nuke: - rm -rf ./target - GOPATH=$(GOPATH) go clean -i ./... diff --git a/vendor/github.com/dgryski/go-farm/README.md b/vendor/github.com/dgryski/go-farm/README.md deleted file mode 100644 index dd07d6f..0000000 --- a/vendor/github.com/dgryski/go-farm/README.md +++ /dev/null @@ -1,41 +0,0 @@ -# go-farm - -*Google's FarmHash hash functions implemented in Go* - -[![Master Branch](https://img.shields.io/badge/-master:-gray.svg)](https://github.com/dgryski/go-farm/tree/master) -[![Master Build Status](https://secure.travis-ci.org/dgryski/go-farm.png?branch=master)](https://travis-ci.org/dgryski/go-farm?branch=master) -[![Master Coverage Status](https://coveralls.io/repos/dgryski/go-farm/badge.svg?branch=master&service=github)](https://coveralls.io/github/dgryski/go-farm?branch=master) -[![Go Report Card](https://goreportcard.com/badge/github.com/dgryski/go-farm)](https://goreportcard.com/report/github.com/dgryski/go-farm) -[![GoDoc](https://godoc.org/github.com/dgryski/go-farm?status.svg)](http://godoc.org/github.com/dgryski/go-farm) - -## Description - -FarmHash, a family of hash functions. - -This is a (mechanical) translation of the non-SSE4/non-AESNI hash functions from Google's FarmHash (https://github.com/google/farmhash). - - -FarmHash provides hash functions for strings and other data. -The functions mix the input bits thoroughly but are not suitable for cryptography. - -All members of the FarmHash family were designed with heavy reliance on previous work by Jyrki Alakuijala, Austin Appleby, Bob Jenkins, and others. - -For more information please consult https://github.com/google/farmhash - - -## Getting started - -This application is written in Go language, please refer to the guides in https://golang.org for getting started. - -This project include a Makefile that allows you to test and build the project with simple commands. -To see all available options: -```bash -make help -``` - -## Running all tests - -Before committing the code, please check if it passes all tests using -```bash -make qa -``` diff --git a/vendor/github.com/dgryski/go-farm/VERSION b/vendor/github.com/dgryski/go-farm/VERSION deleted file mode 100644 index 38f77a6..0000000 --- a/vendor/github.com/dgryski/go-farm/VERSION +++ /dev/null @@ -1 +0,0 @@ -2.0.1 diff --git a/vendor/github.com/dgryski/go-farm/basics.go b/vendor/github.com/dgryski/go-farm/basics.go deleted file mode 100644 index f27a422..0000000 --- a/vendor/github.com/dgryski/go-farm/basics.go +++ /dev/null @@ -1,30 +0,0 @@ -package farm - -// Some primes between 2^63 and 2^64 for various uses. -const k0 uint64 = 0xc3a5c85c97cb3127 -const k1 uint64 = 0xb492b66fbe98f273 -const k2 uint64 = 0x9ae16a3b2f90404f - -// Magic numbers for 32-bit hashing. Copied from Murmur3. -const c1 uint32 = 0xcc9e2d51 -const c2 uint32 = 0x1b873593 - -// A 32-bit to 32-bit integer hash copied from Murmur3. -func fmix(h uint32) uint32 { - h ^= h >> 16 - h *= 0x85ebca6b - h ^= h >> 13 - h *= 0xc2b2ae35 - h ^= h >> 16 - return h -} - -func mur(a, h uint32) uint32 { - // Helper from Murmur3 for combining two 32-bit values. - a *= c1 - a = rotate32(a, 17) - a *= c2 - h ^= a - h = rotate32(h, 19) - return h*5 + 0xe6546b64 -} diff --git a/vendor/github.com/dgryski/go-farm/bench_test.go b/vendor/github.com/dgryski/go-farm/bench_test.go deleted file mode 100644 index 45f51c1..0000000 --- a/vendor/github.com/dgryski/go-farm/bench_test.go +++ /dev/null @@ -1,37 +0,0 @@ -package farm - -import "testing" - -var res32 uint32 -var res64 uint64 -var res64lo, res64hi uint64 - -// 256-bytes random string -var buf = []byte("RMVx)@MLxH9M.WeGW-ktWwR3Cy1XS.,K~i@n-Y+!!yx4?AB%cM~l/#0=2:BOn7HPipG&o/6QeI+Da7Qt~!C^cB2wq(^FGyB?kGQpd(G8I.A7") - -func BenchmarkHash32(b *testing.B) { - var r uint32 - for i := 0; i < b.N; i++ { - // record the result to prevent the compiler eliminating the function call - r = Hash32(buf) - } - // store the result to a package level variable so the compiler cannot eliminate the Benchmark itself - res32 = r -} - -func BenchmarkHash64(b *testing.B) { - var r uint64 - for i := 0; i < b.N; i++ { - r = Hash64(buf) - } - res64 = r -} - -func BenchmarkHash128(b *testing.B) { - var rlo, rhi uint64 - for i := 0; i < b.N; i++ { - rlo, rhi = Hash128(buf) - } - res64lo = rlo - res64hi = rhi -} diff --git a/vendor/github.com/dgryski/go-farm/farmhash_test.go b/vendor/github.com/dgryski/go-farm/farmhash_test.go deleted file mode 100644 index dfef7a4..0000000 --- a/vendor/github.com/dgryski/go-farm/farmhash_test.go +++ /dev/null @@ -1,259 +0,0 @@ -package farm - -import "testing" - -var testData = []struct { - oh32, oh32s uint32 - oh64na, oh64, oh64s, oh64ss uint64 - oh128lo, oh128hi uint64 - oh128slo, oh128shi uint64 - in string -}{ - {0xdc56d17a, 0x0108292b, 0x9ae16a3b2f90404f, 0x9ae16a3b2f90404f, 0xb0403333574d37e4, 0x1ad9361c3f563461, 0x3df09dfc64c09a2b, 0x3cb540c392e51e29, 0x9fd4b80883017649, 0x806308c81d07d094, ""}, - {0x3c973d4d, 0x7e4cfeed, 0xb3454265b6df75e3, 0xb3454265b6df75e3, 0x779ef0ca4870bcc2, 0xd95bffbe1f68b36d, 0x6e97d6bbdfc0a0c4, 0x52a71e38f43be561, 0xa347ea476dd92aff, 0xe12da4d2563e7840, "a"}, - {0x417330fd, 0x546fd574, 0xaa8d6e5242ada51e, 0xaa8d6e5242ada51e, 0xbfb091da4ffef5d8, 0xa05bfc8f958ce312, 0x13e834f38a6c88b8, 0xcfdbce01c0e7622e, 0x4cfab1d0801d789d, 0x1cb9185cd5d6c743, "ab"}, - {0x2f635ec7, 0x27b6c746, 0x24a5b3a074e7f369, 0x24a5b3a074e7f369, 0x7c6dc4691a7576b6, 0x008b6aa9b6344c8d, 0x3980b2afd2126c04, 0xa085f09013029e45, 0xbeadc73cd0b92afe, 0xd0d697a5a943a657, "abc"}, - {0x98b51e95, 0xdfb26aae, 0x1a5502de4a1f8101, 0x1a5502de4a1f8101, 0xfdc6b0ac6369ca3a, 0xf0d7f476a4cc1a4a, 0xb8d7175e11647e82, 0x0906d778016538d9, 0x83799d5bc388066c, 0x81f582de4830d3ef, "abcd"}, - {0xa3f366ac, 0xd29c0f4d, 0xc22f4663e54e04d4, 0xc22f4663e54e04d4, 0x64b5b351c1cee4a2, 0x6ecf50380f033790, 0x940fcbbc468d384f, 0xf7776b2eaa1583e1, 0x752e188459fdb79b, 0xaccbe81c5b1e610a, "abcde"}, - {0x0f813aa4, 0x4abfab6e, 0xc329379e6a03c2cd, 0xc329379e6a03c2cd, 0xb8e8ed73451fc99f, 0x03850d708bfcb24b, 0x6f7c444b0a4eb3eb, 0x7da95bbe683b00b0, 0x09ca9b9287f397d9, 0x0dc7ad8161b168d6, "abcdef"}, - {0x21deb6d7, 0xbd18c595, 0x3c40c92b1ccb7355, 0x3c40c92b1ccb7355, 0x66301d1183086f9c, 0x25fcd92789893a23, 0x9e5daa7baf7e4573, 0xcfb5d54dd0ac6959, 0x45ada3ef413e2174, 0xe05f1b93e468b6df, "abcdefg"}, - {0xfd7ec8b9, 0x759ee8b6, 0xfee9d22990c82909, 0xfee9d22990c82909, 0xef6b24f6a776fd30, 0xee098adfe88e7340, 0x60f2a826d4d614ef, 0x56f19716a4032fcb, 0x6e315acf85d006a2, 0xdc645ba0560c2dc9, "abcdefgh"}, - {0x6f98dc86, 0xa7440120, 0x332c8ed4dae5ba42, 0x332c8ed4dae5ba42, 0xb54b4c8bd2372ffc, 0x4c405cec37506bfd, 0x7b5fd93102612d91, 0x61aa40e4e386bd9c, 0xf6120c3bbe5f4aff, 0x7d2f90ca09078fa8, "abcdefghi"}, - {0x9741ca1a, 0xdb4c64d2, 0xad052244b781c4eb, 0xad052244b781c4eb, 0xd56f3e3e18d9cacc, 0xe148f198dad5079d, 0xcf650cdfad0d0675, 0x6f6cb496e4b429c5, 0x5f9889eedca799d1, 0xee9890e8b8567c89, "0123456789"}, - {0xca179ba9, 0x7fca6fd6, 0x3ef4c03514208c77, 0x3ef4c03514208c77, 0xda0851051d8a9854, 0xdd0bdad27bda1972, 0xc82790fefc8d709e, 0x95fac84d6ce3f311, 0x000153a7819942df, 0x8ee8ba5010b1da1c, "0123456789 "}, - {0xf8cc7928, 0x00be5c31, 0x496841e83a33cc91, 0x496841e83a33cc91, 0x27f085304094b99f, 0x0e85e1954a10b28e, 0x334199771269f58b, 0xdfe28ae349106abd, 0x2231c7f1bfd9b5d6, 0x50a4d4015221e228, "0123456789-0"}, - {0x0d92cafb, 0xe6588500, 0xd81bcb9f3679ac0c, 0xd81bcb9f3679ac0c, 0x938a277ef2446d80, 0x378ce8623423a232, 0x534f80dc46200e5b, 0x33de7f2feb6e9f9c, 0x9b8e156e09691d6a, 0xe80b02c1357f2c45, "0123456789~01"}, - {0x71a36842, 0xe514ed82, 0x5da5a6a117c606f6, 0x5da5a6a117c606f6, 0x2439b47b63cfb868, 0x9b0a3f5504372975, 0x4ffccef1542c2681, 0x481bec885727f698, 0x7b31a7b9c6950bce, 0x4feef06f8e8343f5, "0123456789#012"}, - {0x93ee6801, 0x0cfc86d2, 0x5361eae17c1ff6bc, 0x5361eae17c1ff6bc, 0xf629b20de846fc23, 0x3ca6d68cb0129d5f, 0x8ea7f4ceea677800, 0x27f04b052a82a69d, 0xc2bc043bcda6164e, 0xf11906ca790e0d90, "0123456789@0123"}, - {0x9cecd750, 0x93278a98, 0x4283d4ef43627f64, 0x4283d4ef43627f64, 0x33abb5361a4815c1, 0x5bec11b7f0eb5b0e, 0xbb5db1cf64974657, 0x620437956a2c3feb, 0x1b5d8f018909205d, 0xc1b3ecfee087c7af, "0123456789'01234"}, - {0x335f081f, 0x34981478, 0x46a7416ed4861e3b, 0x46a7416ed4861e3b, 0xf4547ea9e910bc0e, 0x5cfaf00ae1d9b34c, 0x18814368ecc30fa6, 0xa73eb969f0303770, 0x3dbd3fa7a545bf08, 0x991d50420e35a9ff, "0123456789=012345"}, - {0xa9785062, 0x7580b9fb, 0xa4abb4e0da2c594c, 0xa4abb4e0da2c594c, 0x05d865e3844b83fe, 0x8a6aa12f6f761cf2, 0xb86e8b3e907ea7f9, 0xd28023bc18e339ef, 0x77c6ecb4928fd5e7, 0xe8b55ddbfef07956, "0123456789+0123456"}, - {0x5d4bd7f6, 0x73bdc9fb, 0xcf1c7d3ad54f9215, 0xcf1c7d3ad54f9215, 0x79be62145d9d67cf, 0x6541cb3eebafd693, 0xc83a8801c1057f7a, 0x7a6ef6954512e51b, 0x49daf680f01b4e79, 0x42eeb6d63a4a2481, "0123456789*01234567"}, - {0x3884aa05, 0xda41f50b, 0x07adf50b2ac764fc, 0x07adf50b2ac764fc, 0x2474703a1b29f6a9, 0xb01e016d86ede665, 0x7f14c7b52d596e44, 0x6767246d19bc4e34, 0x3d154e894a20b400, 0x76e45ed353112875, "0123456789&012345678"}, - {0x536d1efd, 0xcbd6cb47, 0xdebcba8e6f3eabd1, 0xdebcba8e6f3eabd1, 0x9fb28e096e6968db, 0x91b2d71a5147967b, 0x321c9c8e18ea81f4, 0xc4acf23d0fbc5484, 0xc4c32b477c0574dc, 0x9440e0adeba7673b, "0123456789^0123456789"}, - {0x1723dd7a, 0xf3485759, 0x4dbd128af51d77e8, 0x4dbd128af51d77e8, 0x1e9ce746b2ffef52, 0xac60f1c73ac2c016, 0x6e80a3ba73041556, 0x0a5d94eaead48b58, 0x64a7728894381e6b, 0x71d9d110555d07b2, "0123456789%0123456789£"}, - {0xfa88d020, 0xd89da44b, 0xd78d5f852d522e6a, 0xd78d5f852d522e6a, 0x072fd1a4b21ed852, 0x7a7ddf0143013fc2, 0xe91658c980e0f179, 0x3eb8d05028d2fe3c, 0xcaf33ff7add6b07b, 0xfcc2de2d2f0f458b, "0123456789$0123456789!0"}, - {0xc6246b8d, 0x9f99edf0, 0x80d73b843ba57db8, 0x80d73b843ba57db8, 0x8d8d5757a7bda0ba, 0xb9857c5b86ba9e86, 0x12ab5d9fca8a7a6f, 0x26726f42f1aba3b3, 0x33bb4a26e209e9f8, 0x00f453ad18334e87, "size: a.out: bad magic"}, - {0x322984d9, 0xb630933e, 0x8eb3808d1ccfc779, 0x8eb3808d1ccfc779, 0x5ba1410bdca911a7, 0x78fc99025fd288e6, 0xa646f296be6c7a80, 0xc5c0c296fea38db2, 0x481512913a7eb34a, 0xa6d72dee130312f8, "Nepal premier won't resign."}, - {0x221694e4, 0xb959719f, 0xb944f8a16261e414, 0xb944f8a16261e414, 0x4e4d65c93956a760, 0x5edcdee0fa2d5936, 0x1e41fc4638c4da77, 0x0896f4bd73582b3e, 0xb7a0568d25721aa1, 0xdbb71e5308b97e38, "C is as portable as Stonehedge!!"}, - {0xe273108f, 0x6d328965, 0xe8f89ab6df9bdd25, 0xe8f89ab6df9bdd25, 0xa3a2a2a6c80ebbd2, 0xf88dbcbab3c05f4e, 0xc6c8eac0aafacfed, 0x8efcd3bd44573235, 0x445f11917c9e20cd, 0x6b22d6c3239d923d, "Discard medicine more than two years old."}, - {0x363394d1, 0xc5010f28, 0xa9961670ce2a46d9, 0xa9961670ce2a46d9, 0x9d0526b9480738b8, 0xf31be505a4ee2623, 0xea8b15a2a33e8211, 0xe23fc1fda1552993, 0xb589f51ad7354d27, 0x2322b93f6ce62132, "I wouldn't marry him with a ten foot pole."}, - {0x4fda5f07, 0x40172aa7, 0xbdd69b798d6ba37a, 0xbdd69b798d6ba37a, 0x1110fe437d57c4d3, 0x74a9361763b11819, 0x5595b0dbcb471e00, 0xcd5ead4e1c04dfa1, 0x36982c3d96d9ec47, 0x7341db869a7d531d, "If the enemy is within range, then so are you."}, - {0xd225e92e, 0xf458e174, 0xc2f8db8624fefc0e, 0xc2f8db8624fefc0e, 0x755a46f13a764857, 0xe7f5413a7f308fd6, 0x41d35389237b36e4, 0xc544a2d600ae8dfb, 0x619e9c54f1c9f3d4, 0xdcf6f01ae331847e, "The major problem is with sendmail. -Mark Horton"}, - {0x0819a4e8, 0xae0b7a86, 0x5a0a6efd52e84e2a, 0x5a0a6efd52e84e2a, 0x3eb089865ab8b75e, 0x9fb5f8a3ed197d12, 0x9813f2f5d9b33cb3, 0xc59d72687a4b9b15, 0x2f9635cc9d58655a, 0xc219bcc95498f19f, "How can you write a big system without C++? -Paul Glick"}, - {0xf585dfc4, 0x8e82e216, 0x786d7e1987023ca9, 0x786d7e1987023ca9, 0x54bf932850a761e1, 0x636c00055b1d3e3f, 0x273ef578b7c1056b, 0xa872b4052ea8c636, 0xa695b68b07c0d24c, 0x715add30687d7092, "He who has a shady past knows that nice guys finish last."}, - {0x7613810f, 0x3f6469cc, 0x5d14f96c18fe3d5e, 0x5d14f96c18fe3d5e, 0x7d87801f634222c4, 0xfa0e0a8b2a984142, 0x4813d464644d7658, 0x7367af890cc39d36, 0xc62a3e17cf5aff0b, 0x9f53c87726807e89, "Free! Free!/A trip/to Mars/for 900/empty jars/Burma Shave"}, - {0x1090d244, 0x84dd9748, 0xec8848fd3b266c10, 0xec8848fd3b266c10, 0xddce3cea9126d550, 0x8c085581e9f35148, 0xe09d3113753a527c, 0xec22d95954539646, 0xe09f6dfb52ddaedd, 0x3deedf6bf668881c, "His money is twice tainted: 'taint yours and 'taint mine."}, - {0x2cc30bb7, 0xa3672fa1, 0x2a578b80bb82147c, 0x2a578b80bb82147c, 0xf425894aebcce21a, 0x7a02d6d816a67950, 0xcccd07c8d398e7fe, 0x8f623e32dec3f91f, 0xe6b9e7bd64737d0b, 0xaebc6683db6a5ed3, "The days of the digital watch are numbered. -Tom Stoppard"}, - {0xa5812ac8, 0x65c7e743, 0x55182f8859eca4ce, 0xb8d104d1135bbc60, 0xf0b5522f8062b30f, 0xb76f3e8c68eea2bc, 0x3e23a6e232671c25, 0x5ccc8ce07185764f, 0xfd24d1c7bef69416, 0xf22c727703f66aa4, "For every action there is an equal and opposite government program."}, - {0xd07de88f, 0x104a7d01, 0xabcdb319fcf2826c, 0x836f5ff0c2a7dfaa, 0x7b609bd1b51446df, 0xf45b1631b573f390, 0xd7ff0e47283d075c, 0xb7663fe8a39ee896, 0xdbdcf1735ff9b85c, 0x26a482705faec710, "You remind me of a TV show, but that's all right: I watch it anyway."}, - {0x2e18e880, 0xf7f48b6b, 0x1d85702503ac7eb4, 0x61751a90ec7d71bf, 0x4e58adfd902e4097, 0x141a2e0ff5e0e729, 0x1082910836b47d27, 0x2f3b24ebcfa58e41, 0x847e36b2945571f6, 0x4358a10fff41fcc0, "It's well we cannot hear the screams/That we create in others' dreams."}, - {0x1b8db5d0, 0x0159176d, 0xa2b8bf3032021993, 0xa58e3702193e4631, 0x50f9160881ddf6ff, 0xbbdfff333383198f, 0x1cdb19fd13eccaff, 0x28db4556ceb58337, 0xc8f51ab686f4ddaa, 0x74c85ad931043872, "Give me a rock, paper and scissors and I will move the world. CCFestoon"}, - {0xcc3d0ff2, 0xc20708a8, 0x38aa3175b37f305c, 0xa104da6f2f575514, 0x88387579f38d77c9, 0xbfe4b3fa04bb6506, 0xabc0c75984ae62f2, 0x0ff3a7fb8f8419ae, 0xec996d7f77e0de82, 0x28a45862814611fe, "It's a tiny change to the code and not completely disgusting. - Bob Manchek"}, - {0xff16c9e6, 0x99735ad0, 0x7e85d7b050ed2967, 0xfe6aa49558b3cbe0, 0x249fa05ebf23cc74, 0x113915d477dc320b, 0x313bece7d506637d, 0x04e405567dabb986, 0x95d4a5700f5adee8, 0x71adea5e2345f3e9, "There is no reason for any individual to have a computer in their home. -Ken Olsen, 1977"}, - {0xe2053c2c, 0x510d0e3c, 0x5a05644eb66e435e, 0x96d012f9bccb3e, 0x7b88e6bee477c3e0, 0x07d20be82d1835c9, 0x89432ab05f44af82, 0xcdab02ccb904bcd1, 0x4edcb81c107d8234, 0xfc94e1b62a99beb3, "Even if I could be Shakespeare, I think I should still choose to be Faraday. - A. Huxley"}, - {0x11c493bb, 0xa36704a5, 0x98eff6958c5e91a, 0x8fe4429d157f60f5, 0x37d8c1e3d3f79073, 0xdf1461ed0c9c3fcb, 0x71dc055b46107f35, 0xff33cd37f0985850, 0xfaa96848001f77af, 0x1bd9b707750cf5ac, "The fugacity of a constituent in a mixture of gases at a given temperature is proportional to its mole fraction. Lewis-Randall Rule"}, - {0xd402abf8, 0x656d5959, 0xc3f02c4ffd5d71e6, 0xed25cfc61b15bddd, 0x42b50de39d3f2225, 0x2e29484ace9fbcf0, 0x2012daecbb4ecf6c, 0xe75cabf03e64cbca, 0xefc0033cde0e7257, 0x8040fd1a39ea0f06, "Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum."}, -} - -var testSize = 300 -var dataSize = 1048576 // 1 << 20 - -var expectedFingerprint64 = []uint32{ - 2598464059, 797982799, 1410420968, 2134990486, 255297188, 2992121793, 4019337850, 452431531, 299850021, - 2532580744, 2199864459, 3696623795, 1053458494, 1882212500, 458884671, 3033004529, 2700149065, 2699376854, - 4220361840, 1712034059, 594028478, 2921867846, 3280331829, 326029180, 3824583307, 1612122221, 2233466664, - 1432476832, 1628777059, 1499109081, 1145519619, 3190844552, 65721842, 489963606, 1790705123, 2128624475, - 155445229, 1672724608, 3610042449, 1911523866, 1099072299, 1389770549, 3603803785, 629449419, 1552847036, - 645684964, 3151491850, 3272648435, 916494250, 1230085527, 231181488, 851743255, 1142264800, 3667013118, - 732137533, 1909203251, 4072067757, 4165088768, 956300927, 914413116, 3074915312, 3117299654, 1438494951, - 507436733, 126024219, 146044391, 165589978, 1578546616, 249776086, 1207522198, 46987739, 1157614300, - 3614377032, 586863115, 1164298657, 4140791139, 3725511003, 232064808, 512845449, 3748861010, 22638523, - 648000590, 1024246061, 4027776454, 411505255, 1973395102, 3474970689, 1029055034, 589567754, 325737734, - 257578986, 3698087965, 2305332220, 191910725, 3315355162, 2135941665, 23075771, 3252374102, 663013031, - 3444053918, 2115441882, 4081398201, 1379288194, 4225182569, 3667516477, 1709989541, 2725013602, 3639843023, - 2470483982, 877580602, 3981838403, 3762572073, 1129162571, 732225574, 3232041815, 1652884780, 2227121257, - 1426140634, 1386256573, 24035717, 1598686658, 3146815575, 739944537, 579625482, 3903349120, 389846205, - 2834153464, 1481069623, 3740748788, 3388062747, 1020177209, 734239551, 2610427744, 49703572, 1416453607, - 2815915291, 937074653, 3035635454, 3711259084, 2627383582, 3669691805, 263366740, 3565059103, 1190977418, - 2747519432, 4129538640, 2271095827, 2993032712, 795918276, 1116991810, 937372240, 1343017609, 1166522068, - 1623631848, 2721658101, 1937681565, 114616703, 954762543, 1756889687, 2936126607, 2483004780, 1927385370, - 1672737098, 2148675559, 2636210123, 1338083267, 1335160250, 2084630531, 2746885618, 636616055, 2076016059, - 408721884, 2301682622, 2691859523, 2614088922, 1975527044, 3529473373, 1490330107, 4271796078, 1910401882, - 3738454258, 2554452696, 2237827073, 2803250686, 1996680960, 839529273, 3544595875, 3909443124, 3656063205, - 837475154, 438095290, 484603494, 308425103, 268427550, 4243643405, 2849988118, 2948254999, 2102063419, - 1735616066, 1539151988, 95237878, 2005032160, 1433635018, 116647396, 881378302, 2159170082, 336034862, - 2017579106, 944743644, 1694443528, 260177668, 505662155, 3722741628, 1511077569, 1103819072, 2089123665, - 2475035432, 1120017626, 2842141483, 4029205195, 3873078673, 136118734, 1699452298, 1403506686, 1805475756, - 2562064338, 4271866024, 3071338162, 459509140, 771592405, 185232757, 4032960199, 3512945009, 308584855, - 4250142168, 2565680167, 38924274, 3770488806, 3099963860, 1255084262, 2363435042, 54945052, 2534883189, - 2432427547, 2741583197, 1280920000, 1281043691, 1121403845, 2127558730, 713121337, 2108187161, 927011680, - 4134691985, 1958963937, 2567532373, 4075249328, 4104757832, 3026358429, 3573008472, 3615577014, 1541946015, - 3087190425, 857839960, 2515339233, 2809830736, 460237542, 1950698961, 2069753399, 1106466069, 356742959, - 3662626864, 1750561299, 992181339, 3384018814, 100741310, 451656820, 3650357479, 2390172694, 2088767754, - 164402616, 2751052984, 1767810825, 3441135892, 3323383489, 2756998822, 207428029, 2648427775, 2360400900, - 1396468647, 1377764574, 1435134775, 1099809675, 3374512975, 3542220540, 4081637863, 337070226, 644850146, - 1306761320, 1242645122, 4109252858, 3377483696, 1788337208, 1658628529, 2911512007, 367022558, 3071359622, - 4273132307, 3898950547, 1858986613, 2040551642, 4077477194, 3565689036, 265993036, 1864569342, 923017956, - 490608221, 3833372385, 3287246572, 2649450292, 500120236, 2810524030, 1561519055, 3224066062, 2774151984, - 2107011431, 96459446, 1235983679, 4237425634, 276949224, 4100839753, 427484362, 4246879223, 1858777639, - 3476334357, 358032121, 2511026735, 1535473864, 556796152, 1476438092, 2913077464, 3051522276, 4046477658, - 1802040304, 990407433, 4052924496, 2926590471, 4265214507, 82077489, 464407878, 4190838199, 733509243, - 1583801700, 1877837196, 3912423882, 8759461, 2540185277, 2019419351, 4051584612, 700836153, 1675560450, - 3130433948, 405251683, 2224044848, 4071581802, 2272418128, 803575837, 4019147902, 3841480082, 3424361375, - 779434428, 3057021940, 2285701422, 1783152480, 823305654, 3032187389, 4159715581, 3420960112, 3198900547, - 3006227299, 4194096960, 1775955687, 1719108984, 684087286, 531310503, 3105682208, 3382290593, 777173623, - 3241407531, 2649684057, 1397502982, 3193669211, 811750340, 3403136990, 2540585554, 784952939, 943914610, - 3985088434, 1911188923, 519948041, 3181425568, 1089679033, 240953857, 3017658263, 3828377737, 308018483, - 4262383425, 3188015819, 4051263539, 4074952232, 1683612329, 206775997, 2283918569, 2217060665, 350160869, - 140980, 1891558063, 422986366, 330624974, 918718096, 376390582, 3424344721, 3187805406, 3855037968, - 1928519266, 3059200728, 2108753646, 1343511943, 2247006571, 622521957, 917121602, 3299763344, 2864033668, - 2661022773, 2006922227, 1237256330, 3449066284, 3285899651, 786322314, 1244759631, 3263135197, 987586766, - 3206261120, 1827135136, 1781944746, 2482286699, 1109175923, 4190721328, 1129462471, 1623777358, 3389003793, - 1646071378, 1164309901, 989577914, 3626554867, 1516846461, 3656006011, 3698796465, 3155218919, 1237411891, - 1854985978, 3939149151, 878608872, 2437686324, 3163786257, 1235300371, 1256485167, 1883344352, 2083771672, - 3066325351, 2770847216, 601221482, 3992583643, 2557027816, 900741486, 90375300, 300318232, 3253901179, - 542270815, 1273768482, 1216399252, 325675502, 3652676161, 1097584090, 3262252593, 3704419305, 411263051, - 3460621305, 1967599860, 901109753, 2682611693, 797089608, 3286110054, 2219863904, 3623364733, 3061255808, - 1615375832, 2701956286, 4145497671, 449740816, 2686506989, 1235084019, 2151665147, 2091754612, 1178454681, - 3213794286, 2601416506, 4004834921, 238887261, 186020771, 2367569534, 1962659444, 3539886328, 2144472852, - 1390394371, 3597555910, 3188438773, 3371014971, 2058751609, 1169588594, 857915866, 923161569, 4068653043, - 3808667664, 581227317, 2077539039, 851579036, 2794103714, 2094375930, 3122317317, 2365436865, 2023960931, - 2312244996, 612094988, 1555465129, 3306195841, 1702313921, 1171351291, 2043136409, 3744621107, 1028502697, - 6114625, 3359104346, 1024572712, 1927582962, 3392622118, 1347167673, 2075035198, 4202817168, 701024148, - 1481965992, 1334816273, 2870251538, 1010064531, 713520765, 4089081247, 3231042924, 2452539325, 1343734533, - 587001593, 1917607088, 3498936874, 246692543, 2836854664, 2317249321, 774652981, 1285694082, 397012087, - 1717527689, 2904461070, 3893453420, 1565179401, 600903026, 1134342772, 3234226304, 345572299, 2274770442, - 1079209397, 2122849632, 1242840526, 3987000643, 3065138774, 3111336863, 1023721001, 3763083325, 2196937373, - 2643841788, 4201389782, 4223278891, 292733931, 1424229089, 2927147928, 1048291071, 2490333812, 4098360768, - 3948800722, 335456628, 540133451, 3313113759, 3430536378, 2514123129, 2418881542, 487365389, 1136054817, - 3004241477, 4109233936, 3679809321, 3527024461, 1147434678, 3308746763, 1875093248, 4217929592, 400784472, - 160353261, 2413172925, 1853298225, 3201741245, 3680311316, 4274382900, 1131020455, 194781179, 3440090658, - 2165746386, 3106421434, 880320527, 1429837716, 252230074, 3623657004, 3869801679, 2507199021, 1659221866, - 3121647246, 3884308578, 2610217849, 641564641, 329123979, 121860586, 947795261, 1992594155, 3050771207, - 2767035539, 627269409, 1806905031, 584050483, 4142579188, 3259749808, 644172091, 3053081915, 2840648309, - 2244943480, 4057483496, 873421687, 2447660175, 1233635843, 2163464207, 2515400215, 3100476924, 470325051, - 2598261204, 850667549, 3622479237, 2781907007, 943739431, 1901484772, 939810041, 3261383939, 2212130277, - 3349254805, 2796552902, 3372846298, 3835884044, 2764936304, 1338171648, 2525665319, 4196233786, 2290169528, - 1793910997, 1554419340, 1733094688, 1084699349, 3233936866, 1428704144, 3269904970, 3347011944, 1892898231, - 1072588531, 3547435717, 1593338562, 919414554, 3953006207, 877438080, 224271045, 2914958001, 2920583824, - 1251814062, 385182008, 640855184, 4263183176, 3041193150, 3505072908, 2830570613, 1949847968, 2999344380, - 1714496583, 15918244, 2605688266, 3253705097, 4152736859, 2097020806, 2122199776, 1069285218, 670591796, - 768977505, 379861934, 1557579480, 547346027, 388559045, 1495176194, 4093461535, 1911655402, 1053371241, - 3717104621, 1144474110, 4166253320, 2747410691, -} - -func TestHash32(t *testing.T) { - for _, tt := range testData { - if h := Hash32([]byte(tt.in)); h != tt.oh32 { - t.Errorf("Hash32(%q)=%#08x (len=%d), want %#08x", tt.in, h, len(tt.in), tt.oh32) - } - } -} - -func TestFingerprint32(t *testing.T) { - for _, tt := range testData { - if h := Fingerprint32([]byte(tt.in)); h != tt.oh32 { - t.Errorf("Hash32(%q)=%#08x (len=%d), want %#08x", tt.in, h, len(tt.in), tt.oh32) - } - } -} - -func TestHash32WithSeed(t *testing.T) { - for _, tt := range testData { - if h := Hash32WithSeed([]byte(tt.in), 32); h != tt.oh32s { - t.Errorf("Hash32WithSeed(%q)=%#08x (len=%d), want %#08x", tt.in, h, len(tt.in), tt.oh32s) - } - } -} - -func TestHash64(t *testing.T) { - for _, tt := range testData { - if h := Hash64([]byte(tt.in)); h != tt.oh64 { - t.Errorf("Hash64(%q)=%#08x (len=%d), want %#08x", tt.in, h, len(tt.in), tt.oh64) - } - } -} - -func TestFingerprint64(t *testing.T) { - for _, tt := range testData { - if h := Fingerprint64([]byte(tt.in)); h != tt.oh64na { - t.Errorf("Hash64(%q)=%#08x (len=%d), want %#08x", tt.in, h, len(tt.in), tt.oh64na) - } - } -} - -func TestHash64WithSeed(t *testing.T) { - for _, tt := range testData { - if h := Hash64WithSeed([]byte(tt.in), 32); h != tt.oh64s { - t.Errorf("Hash64WithSeed(%q)=%#08x (len=%d), want %#08x", tt.in, h, len(tt.in), tt.oh64s) - } - } -} - -func TestHash64WithSeeds(t *testing.T) { - for _, tt := range testData { - if h := Hash64WithSeeds([]byte(tt.in), 32, 64); h != tt.oh64ss { - t.Errorf("Hash64WithSeeds(%q)=%#08x (len=%d), want %#08x", tt.in, h, len(tt.in), tt.oh64ss) - } - } -} - -func TestHash128(t *testing.T) { - for _, tt := range testData { - if lo, hi := Hash128([]byte(tt.in)); lo != tt.oh128lo || hi != tt.oh128hi { - t.Errorf("Hash128(%q)=(%#016x, %#016x) (len=%d) want (%#016x, %#016x)", tt.in, lo, hi, len(tt.in), tt.oh128lo, tt.oh128hi) - } - } -} - -func TestHash128WithSeed(t *testing.T) { - for _, tt := range testData { - if lo, hi := Hash128WithSeed([]byte(tt.in), 32, 64); lo != tt.oh128slo || hi != tt.oh128shi { - t.Errorf("Hash128WithSeed(%q)=(%#016x, %#016x) (len=%d) want (%#016x, %#016x)", tt.in, lo, hi, len(tt.in), tt.oh128slo, tt.oh128shi) - } - } -} - -func dataSetup() []byte { - data := make([]byte, dataSize) - var a uint64 = 9 - var b uint64 = 777 - var u byte - for i := 0; i < dataSize; i++ { - a += b - b += a - a = (a ^ (a >> 41)) * k0 - b = (b^(b>>41))*k0 + uint64(i) - u = byte(b >> 37) - data[i] = u - } - return data -} - -func testFingerprint64DataItem(t *testing.T, data []byte, offset int, len int, index int) { - h := Fingerprint64(data[offset : offset+len]) - a := (uint32)(h >> 32) - if a != expectedFingerprint64[index] { - t.Errorf("Expected %d got %d", expectedFingerprint64[index], a) - } - a = (uint32)((h << 32) >> 32) - if a != expectedFingerprint64[index+1] { - t.Errorf("Expected %d got %d", expectedFingerprint64[index+1], a) - } -} - -func TestFingerprint64Data(t *testing.T) { - data := dataSetup() - index := 0 - i := 0 - for ; i < testSize-1; i++ { - testFingerprint64DataItem(t, data, i*i, i, index) - index += 2 - } - for ; i < dataSize; i += i / 7 { - testFingerprint64DataItem(t, data, 0, i, index) - index += 2 - } - testFingerprint64DataItem(t, data, 0, dataSize, index) -} diff --git a/vendor/github.com/dgryski/go-farm/farmhashcc.go b/vendor/github.com/dgryski/go-farm/farmhashcc.go deleted file mode 100644 index 12e5c04..0000000 --- a/vendor/github.com/dgryski/go-farm/farmhashcc.go +++ /dev/null @@ -1,199 +0,0 @@ -package farm - -// This file provides a 32-bit hash equivalent to CityHash32 (v1.1.1) -// and a 128-bit hash equivalent to CityHash128 (v1.1.1). It also provides -// a seeded 32-bit hash function similar to CityHash32. - -func hash32Len13to24Seed(s []byte, seed uint32) uint32 { - slen := len(s) - a := fetch32(s, -4+(slen>>1)) - b := fetch32(s, 4) - c := fetch32(s, slen-8) - d := fetch32(s, (slen >> 1)) - e := fetch32(s, 0) - f := fetch32(s, slen-4) - h := d*c1 + uint32(slen) + seed - a = rotate32(a, 12) + f - h = mur(c, h) + a - a = rotate32(a, 3) + c - h = mur(e, h) + a - a = rotate32(a+f, 12) + d - h = mur(b^seed, h) + a - return fmix(h) -} - -func hash32Len0to4(s []byte, seed uint32) uint32 { - slen := len(s) - b := seed - c := uint32(9) - for i := 0; i < slen; i++ { - v := int8(s[i]) - b = (b * c1) + uint32(v) - c ^= b - } - return fmix(mur(b, mur(uint32(slen), c))) -} - -func hash128to64(x uint128) uint64 { - // Murmur-inspired hashing. - const mul uint64 = 0x9ddfea08eb382d69 - a := (x.lo ^ x.hi) * mul - a ^= (a >> 47) - b := (x.hi ^ a) * mul - b ^= (b >> 47) - b *= mul - return b -} - -type uint128 struct { - lo uint64 - hi uint64 -} - -// A subroutine for CityHash128(). Returns a decent 128-bit hash for strings -// of any length representable in signed long. Based on City and Murmur. -func cityMurmur(s []byte, seed uint128) uint128 { - slen := len(s) - a := seed.lo - b := seed.hi - var c uint64 - var d uint64 - l := slen - 16 - if l <= 0 { // len <= 16 - a = shiftMix(a*k1) * k1 - c = b*k1 + hashLen0to16(s) - if slen >= 8 { - d = shiftMix(a + fetch64(s, 0)) - } else { - d = shiftMix(a + c) - } - } else { // len > 16 - c = hashLen16(fetch64(s, slen-8)+k1, a) - d = hashLen16(b+uint64(slen), c+fetch64(s, slen-16)) - a += d - for { - a ^= shiftMix(fetch64(s, 0)*k1) * k1 - a *= k1 - b ^= a - c ^= shiftMix(fetch64(s, 8)*k1) * k1 - c *= k1 - d ^= c - s = s[16:] - l -= 16 - if l <= 0 { - break - } - } - } - a = hashLen16(a, c) - b = hashLen16(d, b) - return uint128{a ^ b, hashLen16(b, a)} -} - -func cityHash128WithSeed(s []byte, seed uint128) uint128 { - slen := len(s) - if slen < 128 { - return cityMurmur(s, seed) - } - - endIdx := ((slen - 1) / 128) * 128 - lastBlockIdx := endIdx + ((slen - 1) & 127) - 127 - last := s[lastBlockIdx:] - - // We expect len >= 128 to be the common case. Keep 56 bytes of state: - // v, w, x, y, and z. - var v1, v2 uint64 - var w1, w2 uint64 - x := seed.lo - y := seed.hi - z := uint64(slen) * k1 - v1 = rotate64(y^k1, 49)*k1 + fetch64(s, 0) - v2 = rotate64(v1, 42)*k1 + fetch64(s, 8) - w1 = rotate64(y+z, 35)*k1 + x - w2 = rotate64(x+fetch64(s, 88), 53) * k1 - - // This is the same inner loop as CityHash64(), manually unrolled. - for { - x = rotate64(x+y+v1+fetch64(s, 8), 37) * k1 - y = rotate64(y+v2+fetch64(s, 48), 42) * k1 - x ^= w2 - y += v1 + fetch64(s, 40) - z = rotate64(z+w1, 33) * k1 - v1, v2 = weakHashLen32WithSeeds(s, v2*k1, x+w1) - w1, w2 = weakHashLen32WithSeeds(s[32:], z+w2, y+fetch64(s, 16)) - z, x = x, z - s = s[64:] - x = rotate64(x+y+v1+fetch64(s, 8), 37) * k1 - y = rotate64(y+v2+fetch64(s, 48), 42) * k1 - x ^= w2 - y += v1 + fetch64(s, 40) - z = rotate64(z+w1, 33) * k1 - v1, v2 = weakHashLen32WithSeeds(s, v2*k1, x+w1) - w1, w2 = weakHashLen32WithSeeds(s[32:], z+w2, y+fetch64(s, 16)) - z, x = x, z - s = s[64:] - slen -= 128 - if slen < 128 { - break - } - } - x += rotate64(v1+z, 49) * k0 - y = y*k0 + rotate64(w2, 37) - z = z*k0 + rotate64(w1, 27) - w1 *= 9 - v1 *= k0 - // If 0 < len < 128, hash up to 4 chunks of 32 bytes each from the end of s. - for tailDone := 0; tailDone < slen; { - tailDone += 32 - y = rotate64(x+y, 42)*k0 + v2 - w1 += fetch64(last, 128-tailDone+16) - x = x*k0 + w1 - z += w2 + fetch64(last, 128-tailDone) - w2 += v1 - v1, v2 = weakHashLen32WithSeeds(last[128-tailDone:], v1+z, v2) - v1 *= k0 - } - - // At this point our 56 bytes of state should contain more than - // enough information for a strong 128-bit hash. We use two - // different 56-byte-to-8-byte hashes to get a 16-byte final result. - x = hashLen16(x, v1) - y = hashLen16(y+z, w1) - return uint128{hashLen16(x+v2, w2) + y, - hashLen16(x+w2, y+v2)} -} - -func cityHash128(s []byte) uint128 { - slen := len(s) - if slen >= 16 { - return cityHash128WithSeed(s[16:], uint128{fetch64(s, 0), fetch64(s, 8) + k0}) - } - return cityHash128WithSeed(s, uint128{k0, k1}) -} - -// Fingerprint128 is a 128-bit fingerprint function for byte-slices -func Fingerprint128(s []byte) (lo, hi uint64) { - h := cityHash128(s) - return h.lo, h.hi -} - -// Fingerprint64 is a 64-bit fingerprint function for byte-slices -func Fingerprint64(s []byte) uint64 { - return naHash64(s) -} - -// Fingerprint32 is a 32-bit fingerprint function for byte-slices -func Fingerprint32(s []byte) uint32 { - return Hash32(s) -} - -// Hash128 is a 128-bit hash function for byte-slices -func Hash128(s []byte) (lo, hi uint64) { - return Fingerprint128(s) -} - -// Hash128WithSeed is a 128-bit hash function for byte-slices and a 128-bit seed -func Hash128WithSeed(s []byte, seed0, seed1 uint64) (lo, hi uint64) { - h := cityHash128WithSeed(s, uint128{seed0, seed1}) - return h.lo, h.hi -} diff --git a/vendor/github.com/dgryski/go-farm/farmhashmk.go b/vendor/github.com/dgryski/go-farm/farmhashmk.go deleted file mode 100644 index ee41bd7..0000000 --- a/vendor/github.com/dgryski/go-farm/farmhashmk.go +++ /dev/null @@ -1,102 +0,0 @@ -package farm - -func hash32Len5to12(s []byte, seed uint32) uint32 { - slen := len(s) - a := uint32(len(s)) - b := uint32(len(s) * 5) - c := uint32(9) - d := b + seed - a += fetch32(s, 0) - b += fetch32(s, slen-4) - c += fetch32(s, ((slen >> 1) & 4)) - return fmix(seed ^ mur(c, mur(b, mur(a, d)))) -} - -// Hash32 hashes a byte slice and returns a uint32 hash value -func Hash32(s []byte) uint32 { - - slen := len(s) - - if slen <= 24 { - if slen <= 12 { - if slen <= 4 { - return hash32Len0to4(s, 0) - } - return hash32Len5to12(s, 0) - } - return hash32Len13to24Seed(s, 0) - } - - // len > 24 - h := uint32(slen) - g := c1 * uint32(slen) - f := g - a0 := rotate32(fetch32(s, slen-4)*c1, 17) * c2 - a1 := rotate32(fetch32(s, slen-8)*c1, 17) * c2 - a2 := rotate32(fetch32(s, slen-16)*c1, 17) * c2 - a3 := rotate32(fetch32(s, slen-12)*c1, 17) * c2 - a4 := rotate32(fetch32(s, slen-20)*c1, 17) * c2 - h ^= a0 - h = rotate32(h, 19) - h = h*5 + 0xe6546b64 - h ^= a2 - h = rotate32(h, 19) - h = h*5 + 0xe6546b64 - g ^= a1 - g = rotate32(g, 19) - g = g*5 + 0xe6546b64 - g ^= a3 - g = rotate32(g, 19) - g = g*5 + 0xe6546b64 - f += a4 - f = rotate32(f, 19) + 113 - iters := (slen - 1) / 20 - for { - a := fetch32(s, 0) - b := fetch32(s, 4) - c := fetch32(s, 8) - d := fetch32(s, 12) - e := fetch32(s, 16) - h += a - g += b - f += c - h = mur(d, h) + e - g = mur(c, g) + a - f = mur(b+e*c1, f) + d - f += g - g += f - s = s[20:] - iters-- - if iters == 0 { - break - } - } - g = rotate32(g, 11) * c1 - g = rotate32(g, 17) * c1 - f = rotate32(f, 11) * c1 - f = rotate32(f, 17) * c1 - h = rotate32(h+g, 19) - h = h*5 + 0xe6546b64 - h = rotate32(h, 17) * c1 - h = rotate32(h+f, 19) - h = h*5 + 0xe6546b64 - h = rotate32(h, 17) * c1 - return h -} - -// Hash32WithSeed hashes a byte slice and a uint32 seed and returns a uint32 hash value -func Hash32WithSeed(s []byte, seed uint32) uint32 { - slen := len(s) - - if slen <= 24 { - if slen >= 13 { - return hash32Len13to24Seed(s, seed*c1) - } - if slen >= 5 { - return hash32Len5to12(s, seed) - } - return hash32Len0to4(s, seed) - } - h := hash32Len13to24Seed(s[:24], seed^uint32(slen)) - return mur(Hash32(s[24:])+seed, h) -} diff --git a/vendor/github.com/dgryski/go-farm/farmhashna.go b/vendor/github.com/dgryski/go-farm/farmhashna.go deleted file mode 100644 index 574925e..0000000 --- a/vendor/github.com/dgryski/go-farm/farmhashna.go +++ /dev/null @@ -1,156 +0,0 @@ -package farm - -func shiftMix(val uint64) uint64 { - return val ^ (val >> 47) -} - -func hashLen16(u, v uint64) uint64 { - return hash128to64(uint128{u, v}) -} - -func hashLen16Mul(u, v, mul uint64) uint64 { - // Murmur-inspired hashing. - a := (u ^ v) * mul - a ^= (a >> 47) - b := (v ^ a) * mul - b ^= (b >> 47) - b *= mul - return b -} - -func hashLen0to16(s []byte) uint64 { - slen := uint64(len(s)) - if slen >= 8 { - mul := k2 + slen*2 - a := fetch64(s, 0) + k2 - b := fetch64(s, int(slen-8)) - c := rotate64(b, 37)*mul + a - d := (rotate64(a, 25) + b) * mul - return hashLen16Mul(c, d, mul) - } - - if slen >= 4 { - mul := k2 + slen*2 - a := fetch32(s, 0) - return hashLen16Mul(slen+(uint64(a)<<3), uint64(fetch32(s, int(slen-4))), mul) - } - if slen > 0 { - a := s[0] - b := s[slen>>1] - c := s[slen-1] - y := uint32(a) + (uint32(b) << 8) - z := uint32(slen) + (uint32(c) << 2) - return shiftMix(uint64(y)*k2^uint64(z)*k0) * k2 - } - return k2 -} - -// This probably works well for 16-byte strings as well, but it may be overkill -// in that case. -func hashLen17to32(s []byte) uint64 { - slen := len(s) - mul := k2 + uint64(slen*2) - a := fetch64(s, 0) * k1 - b := fetch64(s, 8) - c := fetch64(s, slen-8) * mul - d := fetch64(s, slen-16) * k2 - return hashLen16Mul(rotate64(a+b, 43)+rotate64(c, 30)+d, a+rotate64(b+k2, 18)+c, mul) -} - -// Return a 16-byte hash for 48 bytes. Quick and dirty. -// Callers do best to use "random-looking" values for a and b. -func weakHashLen32WithSeedsWords(w, x, y, z, a, b uint64) (uint64, uint64) { - a += w - b = rotate64(b+a+z, 21) - c := a - a += x - a += y - b += rotate64(a, 44) - return a + z, b + c -} - -// Return a 16-byte hash for s[0] ... s[31], a, and b. Quick and dirty. -func weakHashLen32WithSeeds(s []byte, a, b uint64) (uint64, uint64) { - return weakHashLen32WithSeedsWords(fetch64(s, 0), - fetch64(s, 8), - fetch64(s, 16), - fetch64(s, 24), - a, - b) -} - -// Return an 8-byte hash for 33 to 64 bytes. -func hashLen33to64(s []byte) uint64 { - slen := len(s) - mul := k2 + uint64(slen)*2 - a := fetch64(s, 0) * k2 - b := fetch64(s, 8) - c := fetch64(s, slen-8) * mul - d := fetch64(s, slen-16) * k2 - y := rotate64(a+b, 43) + rotate64(c, 30) + d - z := hashLen16Mul(y, a+rotate64(b+k2, 18)+c, mul) - e := fetch64(s, 16) * mul - f := fetch64(s, 24) - g := (y + fetch64(s, slen-32)) * mul - h := (z + fetch64(s, slen-24)) * mul - return hashLen16Mul(rotate64(e+f, 43)+rotate64(g, 30)+h, e+rotate64(f+a, 18)+g, mul) -} - -func naHash64(s []byte) uint64 { - slen := len(s) - var seed uint64 = 81 - if slen <= 32 { - if slen <= 16 { - return hashLen0to16(s) - } - return hashLen17to32(s) - } - if slen <= 64 { - return hashLen33to64(s) - } - // For strings over 64 bytes we loop. - // Internal state consists of 56 bytes: v, w, x, y, and z. - v := uint128{0, 0} - w := uint128{0, 0} - x := seed*k2 + fetch64(s, 0) - y := seed*k1 + 113 - z := shiftMix(y*k2+113) * k2 - // Set end so that after the loop we have 1 to 64 bytes left to process. - endIdx := ((slen - 1) / 64) * 64 - last64Idx := endIdx + ((slen - 1) & 63) - 63 - last64 := s[last64Idx:] - for len(s) > 64 { - x = rotate64(x+y+v.lo+fetch64(s, 8), 37) * k1 - y = rotate64(y+v.hi+fetch64(s, 48), 42) * k1 - x ^= w.hi - y += v.lo + fetch64(s, 40) - z = rotate64(z+w.lo, 33) * k1 - v.lo, v.hi = weakHashLen32WithSeeds(s, v.hi*k1, x+w.lo) - w.lo, w.hi = weakHashLen32WithSeeds(s[32:], z+w.hi, y+fetch64(s, 16)) - x, z = z, x - s = s[64:] - } - mul := k1 + ((z & 0xff) << 1) - // Make s point to the last 64 bytes of input. - s = last64 - w.lo += (uint64(slen-1) & 63) - v.lo += w.lo - w.lo += v.lo - x = rotate64(x+y+v.lo+fetch64(s, 8), 37) * mul - y = rotate64(y+v.hi+fetch64(s, 48), 42) * mul - x ^= w.hi * 9 - y += v.lo*9 + fetch64(s, 40) - z = rotate64(z+w.lo, 33) * mul - v.lo, v.hi = weakHashLen32WithSeeds(s, v.hi*mul, x+w.lo) - w.lo, w.hi = weakHashLen32WithSeeds(s[32:], z+w.hi, y+fetch64(s, 16)) - x, z = z, x - return hashLen16Mul(hashLen16Mul(v.lo, w.lo, mul)+shiftMix(y)*k0+z, hashLen16Mul(v.hi, w.hi, mul)+x, mul) -} - -func naHash64WithSeed(s []byte, seed uint64) uint64 { - return naHash64WithSeeds(s, k2, seed) -} - -func naHash64WithSeeds(s []byte, seed0, seed1 uint64) uint64 { - return hashLen16(naHash64(s)-seed0, seed1) -} diff --git a/vendor/github.com/dgryski/go-farm/farmhashuo.go b/vendor/github.com/dgryski/go-farm/farmhashuo.go deleted file mode 100644 index 7bf3d42..0000000 --- a/vendor/github.com/dgryski/go-farm/farmhashuo.go +++ /dev/null @@ -1,117 +0,0 @@ -package farm - -func uoH(x, y, mul uint64, r uint) uint64 { - a := (x ^ y) * mul - a ^= (a >> 47) - b := (y ^ a) * mul - return rotate64(b, r) * mul -} - -// Hash64WithSeeds hashes a byte slice and two uint64 seeds and returns a uint64 hash value -func Hash64WithSeeds(s []byte, seed0, seed1 uint64) uint64 { - slen := len(s) - if slen <= 64 { - return naHash64WithSeeds(s, seed0, seed1) - } - - // For strings over 64 bytes we loop. - // Internal state consists of 64 bytes: u, v, w, x, y, and z. - x := seed0 - y := seed1*k2 + 113 - z := shiftMix(y*k2) * k2 - v := uint128{seed0, seed1} - var w uint128 - u := x - z - x *= k2 - mul := k2 + (u & 0x82) - - // Set end so that after the loop we have 1 to 64 bytes left to process. - endIdx := ((slen - 1) / 64) * 64 - last64Idx := endIdx + ((slen - 1) & 63) - 63 - last64 := s[last64Idx:] - - for len(s) > 64 { - a0 := fetch64(s, 0) - a1 := fetch64(s, 8) - a2 := fetch64(s, 16) - a3 := fetch64(s, 24) - a4 := fetch64(s, 32) - a5 := fetch64(s, 40) - a6 := fetch64(s, 48) - a7 := fetch64(s, 56) - x += a0 + a1 - y += a2 - z += a3 - v.lo += a4 - v.hi += a5 + a1 - w.lo += a6 - w.hi += a7 - - x = rotate64(x, 26) - x *= 9 - y = rotate64(y, 29) - z *= mul - v.lo = rotate64(v.lo, 33) - v.hi = rotate64(v.hi, 30) - w.lo ^= x - w.lo *= 9 - z = rotate64(z, 32) - z += w.hi - w.hi += z - z *= 9 - u, y = y, u - - z += a0 + a6 - v.lo += a2 - v.hi += a3 - w.lo += a4 - w.hi += a5 + a6 - x += a1 - y += a7 - - y += v.lo - v.lo += x - y - v.hi += w.lo - w.lo += v.hi - w.hi += x - y - x += w.hi - w.hi = rotate64(w.hi, 34) - u, z = z, u - s = s[64:] - } - // Make s point to the last 64 bytes of input. - s = last64 - u *= 9 - v.hi = rotate64(v.hi, 28) - v.lo = rotate64(v.lo, 20) - w.lo += (uint64(slen-1) & 63) - u += y - y += u - x = rotate64(y-x+v.lo+fetch64(s, 8), 37) * mul - y = rotate64(y^v.hi^fetch64(s, 48), 42) * mul - x ^= w.hi * 9 - y += v.lo + fetch64(s, 40) - z = rotate64(z+w.lo, 33) * mul - v.lo, v.hi = weakHashLen32WithSeeds(s, v.hi*mul, x+w.lo) - w.lo, w.hi = weakHashLen32WithSeeds(s[32:], z+w.hi, y+fetch64(s, 16)) - return uoH(hashLen16Mul(v.lo+x, w.lo^y, mul)+z-u, - uoH(v.hi+y, w.hi+z, k2, 30)^x, - k2, - 31) -} - -// Hash64WithSeed hashes a byte slice and a uint64 seed and returns a uint64 hash value -func Hash64WithSeed(s []byte, seed uint64) uint64 { - if len(s) <= 64 { - return naHash64WithSeed(s, seed) - } - return Hash64WithSeeds(s, 0, seed) -} - -// Hash64 hashes a byte slice and returns a uint64 hash value -func Hash64(s []byte) uint64 { - if len(s) <= 64 { - return naHash64(s) - } - return Hash64WithSeeds(s, 81, 0) -} diff --git a/vendor/github.com/dgryski/go-farm/platform.go b/vendor/github.com/dgryski/go-farm/platform.go deleted file mode 100644 index 6ddf458..0000000 --- a/vendor/github.com/dgryski/go-farm/platform.go +++ /dev/null @@ -1,18 +0,0 @@ -package farm - -func rotate32(val uint32, shift uint) uint32 { - return ((val >> shift) | (val << (32 - shift))) -} - -func rotate64(val uint64, shift uint) uint64 { - return ((val >> shift) | (val << (64 - shift))) -} - -func fetch32(s []byte, idx int) uint32 { - return uint32(s[idx+0]) | uint32(s[idx+1])<<8 | uint32(s[idx+2])<<16 | uint32(s[idx+3])<<24 -} - -func fetch64(s []byte, idx int) uint64 { - return uint64(s[idx+0]) | uint64(s[idx+1])<<8 | uint64(s[idx+2])<<16 | uint64(s[idx+3])<<24 | - uint64(s[idx+4])<<32 | uint64(s[idx+5])<<40 | uint64(s[idx+6])<<48 | uint64(s[idx+7])<<56 -} diff --git a/vendor/github.com/ebfe/.directory b/vendor/github.com/ebfe/.directory deleted file mode 100644 index 64ba230..0000000 --- a/vendor/github.com/ebfe/.directory +++ /dev/null @@ -1,6 +0,0 @@ -[Dolphin] -Timestamp=2018,1,11,12,15,41 -Version=3 - -[Settings] -HiddenFilesShown=true diff --git a/vendor/github.com/ebfe/keccak/.gitignore b/vendor/github.com/ebfe/keccak/.gitignore deleted file mode 100644 index d772925..0000000 --- a/vendor/github.com/ebfe/keccak/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -*~ -*.swp -*.swo diff --git a/vendor/github.com/ebfe/keccak/.travis.yml b/vendor/github.com/ebfe/keccak/.travis.yml deleted file mode 100644 index 58c2726..0000000 --- a/vendor/github.com/ebfe/keccak/.travis.yml +++ /dev/null @@ -1,4 +0,0 @@ -language: go -go: - - 1.4 - - tip diff --git a/vendor/github.com/ebfe/keccak/LICENSE b/vendor/github.com/ebfe/keccak/LICENSE deleted file mode 100644 index 02e9a91..0000000 --- a/vendor/github.com/ebfe/keccak/LICENSE +++ /dev/null @@ -1,23 +0,0 @@ -Copyright (c) 2014, Michael Gehring -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, -are permitted provided that the following conditions are met: - -* Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. - -* Redistributions in binary form must reproduce the above copyright notice, this - list of conditions and the following disclaimer in the documentation and/or - other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/github.com/ebfe/keccak/keccak.go b/vendor/github.com/ebfe/keccak/keccak.go deleted file mode 100644 index 2e58981..0000000 --- a/vendor/github.com/ebfe/keccak/keccak.go +++ /dev/null @@ -1,323 +0,0 @@ -// Package keccak implements the Keccak (SHA-3) hash algorithm. -// http://keccak.noekeon.org / FIPS 202 draft. -package keccak - -import ( - "hash" -) - -const ( - domainNone = 1 - domainSHA3 = 0x06 - domainSHAKE = 0x1f -) - -const rounds = 24 - -var roundConstants = []uint64{ - 0x0000000000000001, 0x0000000000008082, - 0x800000000000808A, 0x8000000080008000, - 0x000000000000808B, 0x0000000080000001, - 0x8000000080008081, 0x8000000000008009, - 0x000000000000008A, 0x0000000000000088, - 0x0000000080008009, 0x000000008000000A, - 0x000000008000808B, 0x800000000000008B, - 0x8000000000008089, 0x8000000000008003, - 0x8000000000008002, 0x8000000000000080, - 0x000000000000800A, 0x800000008000000A, - 0x8000000080008081, 0x8000000000008080, - 0x0000000080000001, 0x8000000080008008, -} - -type keccak struct { - S [25]uint64 - size int - blockSize int - buf []byte - domain byte -} - -func newKeccak(capacity, output int, domain byte) hash.Hash { - var h keccak - h.size = output / 8 - h.blockSize = (200 - capacity/8) - h.domain = domain - return &h -} - -func New224() hash.Hash { - return newKeccak(224*2, 224, domainNone) -} - -func New256() hash.Hash { - return newKeccak(256*2, 256, domainNone) -} - -func New384() hash.Hash { - return newKeccak(384*2, 384, domainNone) -} - -func New512() hash.Hash { - return newKeccak(512*2, 512, domainNone) -} - -func (k *keccak) Write(b []byte) (int, error) { - n := len(b) - - if len(k.buf) > 0 { - x := k.blockSize - len(k.buf) - if x > len(b) { - x = len(b) - } - k.buf = append(k.buf, b[:x]...) - b = b[x:] - - if len(k.buf) < k.blockSize { - return n, nil - } - - k.absorb(k.buf) - k.buf = nil - } - - for len(b) >= k.blockSize { - k.absorb(b[:k.blockSize]) - b = b[k.blockSize:] - } - - k.buf = b - - return n, nil -} - -func (k0 *keccak) Sum(b []byte) []byte { - k := *k0 - k.final() - return k.squeeze(b) -} - -func (k *keccak) Reset() { - for i := range k.S { - k.S[i] = 0 - } - k.buf = nil -} - -func (k *keccak) Size() int { - return k.size -} - -func (k *keccak) BlockSize() int { - return k.blockSize -} - -func (k *keccak) absorb(block []byte) { - if len(block) != k.blockSize { - panic("absorb() called with invalid block size") - } - - for i := 0; i < k.blockSize/8; i++ { - k.S[i] ^= uint64le(block[i*8:]) - } - keccakf(&k.S) -} - -func (k *keccak) pad(block []byte) []byte { - - padded := make([]byte, k.blockSize) - - copy(padded, k.buf) - padded[len(k.buf)] = k.domain - padded[len(padded)-1] |= 0x80 - - return padded -} - -func (k *keccak) final() { - last := k.pad(k.buf) - k.absorb(last) -} - -func (k *keccak) squeeze(b []byte) []byte { - buf := make([]byte, 8*len(k.S)) - n := k.size - for { - for i := range k.S { - putUint64le(buf[i*8:], k.S[i]) - } - if n <= k.blockSize { - b = append(b, buf[:n]...) - break - } - b = append(b, buf[:k.blockSize]...) - n -= k.blockSize - keccakf(&k.S) - } - return b -} - -func keccakf(S *[25]uint64) { - var bc0, bc1, bc2, bc3, bc4 uint64 - var S0, S1, S2, S3, S4 uint64 - var S5, S6, S7, S8, S9 uint64 - var S10, S11, S12, S13, S14 uint64 - var S15, S16, S17, S18, S19 uint64 - var S20, S21, S22, S23, S24 uint64 - var tmp uint64 - - S0, S1, S2, S3, S4 = S[0], S[1], S[2], S[3], S[4] - S5, S6, S7, S8, S9 = S[5], S[6], S[7], S[8], S[9] - S10, S11, S12, S13, S14 = S[10], S[11], S[12], S[13], S[14] - S15, S16, S17, S18, S19 = S[15], S[16], S[17], S[18], S[19] - S20, S21, S22, S23, S24 = S[20], S[21], S[22], S[23], S[24] - - for r := 0; r < rounds; r++ { - // theta - bc0 = S0 ^ S5 ^ S10 ^ S15 ^ S20 - bc1 = S1 ^ S6 ^ S11 ^ S16 ^ S21 - bc2 = S2 ^ S7 ^ S12 ^ S17 ^ S22 - bc3 = S3 ^ S8 ^ S13 ^ S18 ^ S23 - bc4 = S4 ^ S9 ^ S14 ^ S19 ^ S24 - tmp = bc4 ^ (bc1<<1 | bc1>>(64-1)) - S0 ^= tmp - S5 ^= tmp - S10 ^= tmp - S15 ^= tmp - S20 ^= tmp - tmp = bc0 ^ (bc2<<1 | bc2>>(64-1)) - S1 ^= tmp - S6 ^= tmp - S11 ^= tmp - S16 ^= tmp - S21 ^= tmp - tmp = bc1 ^ (bc3<<1 | bc3>>(64-1)) - S2 ^= tmp - S7 ^= tmp - S12 ^= tmp - S17 ^= tmp - S22 ^= tmp - tmp = bc2 ^ (bc4<<1 | bc4>>(64-1)) - S3 ^= tmp - S8 ^= tmp - S13 ^= tmp - S18 ^= tmp - S23 ^= tmp - tmp = bc3 ^ (bc0<<1 | bc0>>(64-1)) - S4 ^= tmp - S9 ^= tmp - S14 ^= tmp - S19 ^= tmp - S24 ^= tmp - - // rho phi - tmp = S1 - tmp, S10 = S10, tmp<<1|tmp>>(64-1) - tmp, S7 = S7, tmp<<3|tmp>>(64-3) - tmp, S11 = S11, tmp<<6|tmp>>(64-6) - tmp, S17 = S17, tmp<<10|tmp>>(64-10) - tmp, S18 = S18, tmp<<15|tmp>>(64-15) - tmp, S3 = S3, tmp<<21|tmp>>(64-21) - tmp, S5 = S5, tmp<<28|tmp>>(64-28) - tmp, S16 = S16, tmp<<36|tmp>>(64-36) - tmp, S8 = S8, tmp<<45|tmp>>(64-45) - tmp, S21 = S21, tmp<<55|tmp>>(64-55) - tmp, S24 = S24, tmp<<2|tmp>>(64-2) - tmp, S4 = S4, tmp<<14|tmp>>(64-14) - tmp, S15 = S15, tmp<<27|tmp>>(64-27) - tmp, S23 = S23, tmp<<41|tmp>>(64-41) - tmp, S19 = S19, tmp<<56|tmp>>(64-56) - tmp, S13 = S13, tmp<<8|tmp>>(64-8) - tmp, S12 = S12, tmp<<25|tmp>>(64-25) - tmp, S2 = S2, tmp<<43|tmp>>(64-43) - tmp, S20 = S20, tmp<<62|tmp>>(64-62) - tmp, S14 = S14, tmp<<18|tmp>>(64-18) - tmp, S22 = S22, tmp<<39|tmp>>(64-39) - tmp, S9 = S9, tmp<<61|tmp>>(64-61) - tmp, S6 = S6, tmp<<20|tmp>>(64-20) - S1 = tmp<<44 | tmp>>(64-44) - - // chi - bc0 = S0 - bc1 = S1 - bc2 = S2 - bc3 = S3 - bc4 = S4 - S0 ^= (^bc1) & bc2 - S1 ^= (^bc2) & bc3 - S2 ^= (^bc3) & bc4 - S3 ^= (^bc4) & bc0 - S4 ^= (^bc0) & bc1 - bc0 = S5 - bc1 = S6 - bc2 = S7 - bc3 = S8 - bc4 = S9 - S5 ^= (^bc1) & bc2 - S6 ^= (^bc2) & bc3 - S7 ^= (^bc3) & bc4 - S8 ^= (^bc4) & bc0 - S9 ^= (^bc0) & bc1 - bc0 = S10 - bc1 = S11 - bc2 = S12 - bc3 = S13 - bc4 = S14 - S10 ^= (^bc1) & bc2 - S11 ^= (^bc2) & bc3 - S12 ^= (^bc3) & bc4 - S13 ^= (^bc4) & bc0 - S14 ^= (^bc0) & bc1 - bc0 = S15 - bc1 = S16 - bc2 = S17 - bc3 = S18 - bc4 = S19 - S15 ^= (^bc1) & bc2 - S16 ^= (^bc2) & bc3 - S17 ^= (^bc3) & bc4 - S18 ^= (^bc4) & bc0 - S19 ^= (^bc0) & bc1 - bc0 = S20 - bc1 = S21 - bc2 = S22 - bc3 = S23 - bc4 = S24 - S20 ^= (^bc1) & bc2 - S21 ^= (^bc2) & bc3 - S22 ^= (^bc3) & bc4 - S23 ^= (^bc4) & bc0 - S24 ^= (^bc0) & bc1 - - // iota - S0 ^= roundConstants[r] - } - - S[0], S[1], S[2], S[3], S[4] = S0, S1, S2, S3, S4 - S[5], S[6], S[7], S[8], S[9] = S5, S6, S7, S8, S9 - S[10], S[11], S[12], S[13], S[14] = S10, S11, S12, S13, S14 - S[15], S[16], S[17], S[18], S[19] = S15, S16, S17, S18, S19 - S[20], S[21], S[22], S[23], S[24] = S20, S21, S22, S23, S24 -} - -func uint64le(v []byte) uint64 { - return uint64(v[0]) | - uint64(v[1])<<8 | - uint64(v[2])<<16 | - uint64(v[3])<<24 | - uint64(v[4])<<32 | - uint64(v[5])<<40 | - uint64(v[6])<<48 | - uint64(v[7])<<56 - -} - -func putUint64le(v []byte, x uint64) { - v[0] = byte(x) - v[1] = byte(x >> 8) - v[2] = byte(x >> 16) - v[3] = byte(x >> 24) - v[4] = byte(x >> 32) - v[5] = byte(x >> 40) - v[6] = byte(x >> 48) - v[7] = byte(x >> 56) -} diff --git a/vendor/github.com/ebfe/keccak/keccak_test.go b/vendor/github.com/ebfe/keccak/keccak_test.go deleted file mode 100644 index 0f5eeec..0000000 --- a/vendor/github.com/ebfe/keccak/keccak_test.go +++ /dev/null @@ -1,272 +0,0 @@ -package keccak - -import ( - "bytes" - "hash" - "testing" -) - -type test struct { - length int - input []byte - output []byte -} - -var tests = []test{ - { - 28, - []byte{}, - []byte{ - 0xf7, 0x18, 0x37, 0x50, 0x2b, 0xa8, 0xe1, 0x08, - 0x37, 0xbd, 0xd8, 0xd3, 0x65, 0xad, 0xb8, 0x55, - 0x91, 0x89, 0x56, 0x02, 0xfc, 0x55, 0x2b, 0x48, - 0xb7, 0x39, 0x0a, 0xbd, - }, - }, { - 28, - []byte("Keccak-224 Test Hash"), - []byte{ - 0x30, 0x04, 0x5b, 0x34, 0x94, 0x6e, 0x1b, 0x2e, - 0x09, 0x16, 0x13, 0x36, 0x2f, 0xd2, 0x2a, 0xa0, - 0x8e, 0x2b, 0xea, 0xfe, 0xc5, 0xe8, 0xda, 0xee, - 0x42, 0xc2, 0xe6, 0x65}, - }, { - 32, - []byte{}, - []byte{ - 0xc5, 0xd2, 0x46, 0x01, 0x86, 0xf7, 0x23, 0x3c, - 0x92, 0x7e, 0x7d, 0xb2, 0xdc, 0xc7, 0x03, 0xc0, - 0xe5, 0x00, 0xb6, 0x53, 0xca, 0x82, 0x27, 0x3b, - 0x7b, 0xfa, 0xd8, 0x04, 0x5d, 0x85, 0xa4, 0x70, - }, - }, { - 32, - []byte("Keccak-256 Test Hash"), - []byte{ - 0xa8, 0xd7, 0x1b, 0x07, 0xf4, 0xaf, 0x26, 0xa4, - 0xff, 0x21, 0x02, 0x7f, 0x62, 0xff, 0x60, 0x26, - 0x7f, 0xf9, 0x55, 0xc9, 0x63, 0xf0, 0x42, 0xc4, - 0x6d, 0xa5, 0x2e, 0xe3, 0xcf, 0xaf, 0x3d, 0x3c}, - }, { - 48, - []byte{}, - []byte{ - 0x2c, 0x23, 0x14, 0x6a, 0x63, 0xa2, 0x9a, 0xcf, - 0x99, 0xe7, 0x3b, 0x88, 0xf8, 0xc2, 0x4e, 0xaa, - 0x7d, 0xc6, 0x0a, 0xa7, 0x71, 0x78, 0x0c, 0xcc, - 0x00, 0x6a, 0xfb, 0xfa, 0x8f, 0xe2, 0x47, 0x9b, - 0x2d, 0xd2, 0xb2, 0x13, 0x62, 0x33, 0x74, 0x41, - 0xac, 0x12, 0xb5, 0x15, 0x91, 0x19, 0x57, 0xff, - }, - }, { - 48, - []byte("Keccak-384 Test Hash"), - []byte{ - 0xe2, 0x13, 0xfd, 0x74, 0xaf, 0x0c, 0x5f, 0xf9, - 0x1b, 0x42, 0x3c, 0x8b, 0xce, 0xec, 0xd7, 0x01, - 0xf8, 0xdd, 0x64, 0xec, 0x18, 0xfd, 0x6f, 0x92, - 0x60, 0xfc, 0x9e, 0xc1, 0xed, 0xbd, 0x22, 0x30, - 0xa6, 0x90, 0x86, 0x65, 0xbc, 0xd9, 0xfb, 0xf4, - 0x1a, 0x99, 0xa1, 0x8a, 0x7d, 0x9e, 0x44, 0x6e}, - }, { - 64, - []byte{}, - []byte{ - 0x0e, 0xab, 0x42, 0xde, 0x4c, 0x3c, 0xeb, 0x92, - 0x35, 0xfc, 0x91, 0xac, 0xff, 0xe7, 0x46, 0xb2, - 0x9c, 0x29, 0xa8, 0xc3, 0x66, 0xb7, 0xc6, 0x0e, - 0x4e, 0x67, 0xc4, 0x66, 0xf3, 0x6a, 0x43, 0x04, - 0xc0, 0x0f, 0xa9, 0xca, 0xf9, 0xd8, 0x79, 0x76, - 0xba, 0x46, 0x9b, 0xcb, 0xe0, 0x67, 0x13, 0xb4, - 0x35, 0xf0, 0x91, 0xef, 0x27, 0x69, 0xfb, 0x16, - 0x0c, 0xda, 0xb3, 0x3d, 0x36, 0x70, 0x68, 0x0e, - }, - }, { - 64, - []byte("Keccak-512 Test Hash"), - []byte{ - 0x96, 0xee, 0x47, 0x18, 0xdc, 0xba, 0x3c, 0x74, - 0x61, 0x9b, 0xa1, 0xfa, 0x7f, 0x57, 0xdf, 0xe7, - 0x76, 0x9d, 0x3f, 0x66, 0x98, 0xa8, 0xb3, 0x3f, - 0xa1, 0x01, 0x83, 0x89, 0x70, 0xa1, 0x31, 0xe6, - 0x21, 0xcc, 0xfd, 0x05, 0xfe, 0xff, 0xbc, 0x11, - 0x80, 0xf2, 0x63, 0xc2, 0x7f, 0x1a, 0xda, 0xb4, - 0x60, 0x95, 0xd6, 0xf1, 0x25, 0x33, 0x14, 0x72, - 0x4b, 0x5c, 0xbf, 0x78, 0x28, 0x65, 0x8e, 0x6a, - }, - }, -} - -func TestKeccak(t *testing.T) { - for i := range tests { - var h hash.Hash - - switch tests[i].length { - case 28: - h = New224() - case 32: - h = New256() - case 48: - h = New384() - case 64: - h = New512() - default: - panic("invalid testcase") - } - - h.Write(tests[i].input) - - d := h.Sum(nil) - if !bytes.Equal(d, tests[i].output) { - t.Errorf("testcase %d: expected %x got %x", i, tests[i].output, d) - } - } -} - -type testcase struct { - msg []byte - output224 []byte - output256 []byte - output384 []byte - output512 []byte -} - -func TestKeccakShort224(t *testing.T) { - h := New224() - for i := range tstShort { - h.Reset() - h.Write(tstShort[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstShort[i].output224) { - t.Errorf("testcase Short224 %d: expected %x got %x", i, tstShort[i].output224, d) - } - } -} - -func TestKeccakShort256(t *testing.T) { - h := New256() - for i := range tstShort { - h.Reset() - h.Write(tstShort[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstShort[i].output256) { - t.Errorf("testcase Short256 %d: expected %x got %x", i, tstShort[i].output256, d) - } - } -} - -func TestKeccakShort384(t *testing.T) { - h := New384() - for i := range tstShort { - h.Reset() - h.Write(tstShort[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstShort[i].output384) { - t.Errorf("testcase Short384 %d: expected %x got %x", i, tstShort[i].output384, d) - } - } -} - -func TestKeccakShort512(t *testing.T) { - h := New512() - for i := range tstShort { - h.Reset() - h.Write(tstShort[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstShort[i].output512) { - t.Errorf("testcase Short512 %d: expected %x got %x", i, tstShort[i].output512, d) - } - } -} - -func TestKeccakLong224(t *testing.T) { - h := New224() - for i := range tstLong { - h.Reset() - h.Write(tstLong[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstLong[i].output224) { - t.Errorf("testcase Long224 %d: expected %x got %x", i, tstLong[i].output224, d) - } - } -} - -func TestKeccakLong256(t *testing.T) { - h := New256() - for i := range tstLong { - h.Reset() - h.Write(tstLong[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstLong[i].output256) { - t.Errorf("testcase Long256 %d: expected %x got %x", i, tstLong[i].output256, d) - } - } -} - -func TestKeccakLong384(t *testing.T) { - h := New384() - for i := range tstLong { - h.Reset() - h.Write(tstLong[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstLong[i].output384) { - t.Errorf("testcase Long384 %d: expected %x got %x", i, tstLong[i].output384, d) - } - } -} - -func TestKeccakLong512(t *testing.T) { - h := New512() - for i := range tstLong { - h.Reset() - h.Write(tstLong[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, tstLong[i].output512) { - t.Errorf("testcase Long512 %d: expected %x got %x", i, tstLong[i].output512, d) - } - } -} - -func TestSmallWrites(t *testing.T) { - h := New512() - tc := tstLong[len(tstLong)-1] - - for i := 0; i < len(tc.msg); i++ { - h.Write(tc.msg[i : i+1]) - } - - d := h.Sum(nil) - if !bytes.Equal(d, tc.output512) { - t.Errorf("testcase small writes: expected %x got %x", tc.output512, d) - } -} - -func benchmarkHash(b *testing.B, h hash.Hash) { - m := make([]byte, 4096) - h.Reset() - b.SetBytes(int64(len(m))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - h.Write(m) - } -} - -func BenchmarkKeccakf(b *testing.B) { - var s [25]uint64 - b.SetBytes(25 * 8) - for i := 0; i < b.N; i++ { - keccakf(&s) - } -} - -func Benchmark224(b *testing.B) { benchmarkHash(b, New224()) } -func Benchmark256(b *testing.B) { benchmarkHash(b, New256()) } -func Benchmark384(b *testing.B) { benchmarkHash(b, New384()) } -func Benchmark512(b *testing.B) { benchmarkHash(b, New512()) } -func BenchmarkSHA3224(b *testing.B) { benchmarkHash(b, NewSHA3224()) } -func BenchmarkSHA3256(b *testing.B) { benchmarkHash(b, NewSHA3256()) } -func BenchmarkSHA3384(b *testing.B) { benchmarkHash(b, NewSHA3384()) } -func BenchmarkSHA3512(b *testing.B) { benchmarkHash(b, NewSHA3512()) } -func BenchmarkSHAKE128(b *testing.B) { benchmarkHash(b, NewSHAKE128(256)) } -func BenchmarkSHAKE256(b *testing.B) { benchmarkHash(b, NewSHAKE256(256)) } diff --git a/vendor/github.com/ebfe/keccak/keccak_vectors_test.go b/vendor/github.com/ebfe/keccak/keccak_vectors_test.go deleted file mode 100644 index 12ceb24..0000000 --- a/vendor/github.com/ebfe/keccak/keccak_vectors_test.go +++ /dev/null @@ -1,1929 +0,0 @@ -package keccak - -// extracted from ShortMsgKAT_{224,256,384,512}.txt -var tstShort = []testcase{ - testcase{ - msg: []byte{0xcc}, - output224: []byte{0xa9, 0xca, 0xb5, 0x9e, 0xb4, 0xa, 0x10, 0xb2, 0x46, 0x29, 0xf, 0x2d, 0x60, 0x86, 0xe3, 0x2e, 0x36, 0x89, 0xfa, 0xf1, 0xd2, 0x6b, 0x47, 0xc, 0x89, 0x9f, 0x28, 0x2}, - output256: []byte{0xee, 0xad, 0x6d, 0xbf, 0xc7, 0x34, 0xa, 0x56, 0xca, 0xed, 0xc0, 0x44, 0x69, 0x6a, 0x16, 0x88, 0x70, 0x54, 0x9a, 0x6a, 0x7f, 0x6f, 0x56, 0x96, 0x1e, 0x84, 0xa5, 0x4b, 0xd9, 0x97, 0xb, 0x8a}, - output384: []byte{0x1b, 0x84, 0xe6, 0x2a, 0x46, 0xe5, 0xa2, 0x1, 0x86, 0x17, 0x54, 0xaf, 0x5d, 0xc9, 0x5c, 0x4a, 0x1a, 0x69, 0xca, 0xf4, 0xa7, 0x96, 0xae, 0x40, 0x56, 0x80, 0x16, 0x1e, 0x29, 0x57, 0x26, 0x41, 0xf5, 0xfa, 0x1e, 0x86, 0x41, 0xd7, 0x95, 0x83, 0x36, 0xee, 0x7b, 0x11, 0xc5, 0x8f, 0x73, 0xe9}, - output512: []byte{0x86, 0x30, 0xc1, 0x3c, 0xbd, 0x6, 0x6e, 0xa7, 0x4b, 0xbe, 0x7f, 0xe4, 0x68, 0xfe, 0xc1, 0xde, 0xe1, 0xe, 0xdc, 0x12, 0x54, 0xfb, 0x4c, 0x1b, 0x7c, 0x5f, 0xd6, 0x9b, 0x64, 0x6e, 0x44, 0x16, 0xb, 0x8c, 0xe0, 0x1d, 0x5, 0xa0, 0x90, 0x8c, 0xa7, 0x90, 0xdf, 0xb0, 0x80, 0xf4, 0xb5, 0x13, 0xbc, 0x3b, 0x62, 0x25, 0xec, 0xe7, 0xa8, 0x10, 0x37, 0x14, 0x41, 0xa5, 0xac, 0x66, 0x6e, 0xb9}}, - testcase{ - msg: []byte{0x41, 0xfb}, - output224: []byte{0x61, 0x5b, 0xa3, 0x67, 0xaf, 0xdc, 0x35, 0xaa, 0xc3, 0x97, 0xbc, 0x7e, 0xb5, 0xd5, 0x8d, 0x10, 0x6a, 0x73, 0x4b, 0x24, 0x98, 0x6d, 0x5d, 0x97, 0x8f, 0xef, 0xd6, 0x2c}, - output256: []byte{0xa8, 0xea, 0xce, 0xda, 0x4d, 0x47, 0xb3, 0x28, 0x1a, 0x79, 0x5a, 0xd9, 0xe1, 0xea, 0x21, 0x22, 0xb4, 0x7, 0xba, 0xf9, 0xaa, 0xbc, 0xb9, 0xe1, 0x8b, 0x57, 0x17, 0xb7, 0x87, 0x35, 0x37, 0xd2}, - output384: []byte{0x49, 0x5c, 0xce, 0x27, 0x14, 0xcd, 0x72, 0xc8, 0xc5, 0x3c, 0x33, 0x63, 0xd2, 0x2c, 0x58, 0xb5, 0x59, 0x60, 0xfe, 0x26, 0xbe, 0xb, 0xf3, 0xbb, 0xc7, 0xa3, 0x31, 0x6d, 0xd5, 0x63, 0xad, 0x1d, 0xb8, 0x41, 0xe, 0x75, 0xee, 0xfe, 0xa6, 0x55, 0xe3, 0x9d, 0x46, 0x70, 0xec, 0xb, 0x17, 0x92}, - output512: []byte{0x55, 0x1d, 0xa6, 0x23, 0x6f, 0x8b, 0x96, 0xfc, 0xe9, 0xf9, 0x7f, 0x11, 0x90, 0xe9, 0x1, 0x32, 0x4f, 0xb, 0x45, 0xe0, 0x6d, 0xbb, 0xb5, 0xcd, 0xb8, 0x35, 0x5d, 0x6e, 0xd1, 0xdc, 0x34, 0xb3, 0xf0, 0xea, 0xe7, 0xdc, 0xb6, 0x86, 0x22, 0xff, 0x23, 0x2f, 0xa3, 0xce, 0xce, 0xd, 0x46, 0x16, 0xcd, 0xeb, 0x39, 0x31, 0xf9, 0x38, 0x3, 0x66, 0x2a, 0x28, 0xdf, 0x1c, 0xd5, 0x35, 0xb7, 0x31}}, - testcase{ - msg: []byte{0x1f, 0x87, 0x7c}, - output224: []byte{0x6f, 0x9d, 0x28, 0x98, 0xef, 0xd0, 0x96, 0xba, 0xaa, 0xaa, 0xb2, 0xe9, 0x74, 0x82, 0xdd, 0xb6, 0x38, 0x9b, 0x8e, 0x6c, 0xaa, 0x96, 0x4b, 0x7a, 0xe, 0x34, 0x7e, 0x13}, - output256: []byte{0x62, 0x7d, 0x7b, 0xc1, 0x49, 0x1b, 0x2a, 0xb1, 0x27, 0x28, 0x28, 0x27, 0xb8, 0xde, 0x2d, 0x27, 0x6b, 0x13, 0xd7, 0xd7, 0xf, 0xb4, 0xc5, 0x95, 0x7f, 0xdf, 0x20, 0x65, 0x5b, 0xc7, 0xac, 0x30}, - output384: []byte{0xb0, 0x66, 0x5c, 0x34, 0x5f, 0x45, 0xe6, 0xde, 0x14, 0x5b, 0x1, 0x90, 0x33, 0x5e, 0xf5, 0xd5, 0xaa, 0x59, 0xe0, 0xb4, 0x9f, 0xc1, 0x42, 0x5d, 0x5e, 0xae, 0x73, 0x55, 0xea, 0x44, 0x22, 0x84, 0xcb, 0x8a, 0x21, 0x52, 0xd5, 0x65, 0xeb, 0xdf, 0x28, 0x10, 0xec, 0xca, 0xb1, 0x5a, 0xf0, 0x4f}, - output512: []byte{0xeb, 0x7f, 0x2a, 0x98, 0xe0, 0xa, 0xf3, 0x7d, 0x96, 0x4f, 0x7d, 0x8c, 0x44, 0xc1, 0xfb, 0x6e, 0x11, 0x4d, 0x8e, 0xe2, 0x1a, 0x7b, 0x97, 0x6a, 0xe7, 0x36, 0x53, 0x9e, 0xfd, 0xc1, 0xe3, 0xfe, 0x43, 0xbe, 0xce, 0xf5, 0x1, 0x51, 0x71, 0xe6, 0xda, 0x30, 0x16, 0x8c, 0xae, 0x99, 0xa8, 0x2c, 0x53, 0xfa, 0x99, 0x4, 0x27, 0x74, 0xef, 0x98, 0x2c, 0x1, 0x62, 0x6a, 0x54, 0xf, 0x8, 0xc0}}, - testcase{ - msg: []byte{0xc1, 0xec, 0xfd, 0xfc}, - output224: []byte{0xe4, 0x5, 0x86, 0x9d, 0xa1, 0x46, 0x4a, 0x70, 0x57, 0x0, 0xa3, 0xcb, 0xce, 0x13, 0x1a, 0xab, 0xee, 0xba, 0x9c, 0x8d, 0x2f, 0xe6, 0x57, 0x6b, 0x21, 0xbc, 0xbe, 0x16}, - output256: []byte{0xb1, 0x49, 0xe7, 0x66, 0xd7, 0x61, 0x2e, 0xaf, 0x7d, 0x55, 0xf7, 0x4e, 0x1a, 0x4f, 0xdd, 0x63, 0x70, 0x9a, 0x81, 0x15, 0xb1, 0x4f, 0x61, 0xfc, 0xd2, 0x2a, 0xa4, 0xab, 0xc8, 0xb8, 0xe1, 0x22}, - output384: []byte{0xf1, 0x85, 0xb, 0x2a, 0xbb, 0x24, 0xf3, 0xfd, 0x68, 0x3c, 0x70, 0x15, 0x82, 0x78, 0x9d, 0x9e, 0x92, 0xb6, 0xa4, 0x5f, 0x9c, 0x34, 0x5f, 0x9d, 0xae, 0x7f, 0x79, 0x97, 0xc8, 0xc9, 0x10, 0xe8, 0x80, 0x3, 0xe5, 0x92, 0xe5, 0x92, 0x81, 0xcf, 0x92, 0xc9, 0x2d, 0x6b, 0x51, 0xa1, 0xaf, 0xd1}, - output512: []byte{0x95, 0x2d, 0x4c, 0xa, 0x6f, 0xe, 0xf5, 0xce, 0x43, 0x8c, 0x52, 0xe3, 0xed, 0xd3, 0x45, 0xea, 0x0, 0xf9, 0x1c, 0xf5, 0xda, 0x80, 0x97, 0xc1, 0x16, 0x8a, 0x16, 0x6, 0x9e, 0x95, 0x8f, 0xc0, 0x5b, 0xad, 0x90, 0xa0, 0xc5, 0xfb, 0x4d, 0xd9, 0xec, 0x28, 0xe8, 0x4b, 0x22, 0x6b, 0x94, 0xa8, 0x47, 0xd6, 0xbb, 0x89, 0x23, 0x56, 0x92, 0xef, 0x4c, 0x97, 0x12, 0xf0, 0xc7, 0x3, 0xf, 0xae}}, - testcase{ - msg: []byte{0x21, 0xf1, 0x34, 0xac, 0x57}, - output224: []byte{0x55, 0x73, 0xda, 0x2b, 0x2, 0x21, 0x6a, 0x86, 0x3, 0x89, 0xa5, 0x81, 0xf6, 0xe9, 0xfb, 0x8d, 0x80, 0x5e, 0x9e, 0x2, 0xf6, 0xfa, 0x91, 0x17, 0x1, 0xee, 0xe2, 0x98}, - output256: []byte{0x67, 0xf0, 0x55, 0x44, 0xdb, 0xe9, 0x7d, 0x5d, 0x64, 0x17, 0xc1, 0xb1, 0xea, 0x9b, 0xc0, 0xe3, 0xa9, 0x9a, 0x54, 0x13, 0x81, 0xd1, 0xcd, 0x9b, 0x8, 0xa9, 0x76, 0x56, 0x87, 0xeb, 0x5b, 0xb4}, - output384: []byte{0x68, 0xd4, 0x37, 0x32, 0x7f, 0x15, 0x82, 0x87, 0xc3, 0x4, 0xbb, 0xaf, 0x36, 0xf7, 0x82, 0xf4, 0x97, 0xda, 0x2c, 0x48, 0xa, 0x1f, 0xbb, 0x26, 0x86, 0x82, 0x36, 0x22, 0x18, 0x64, 0x1f, 0x90, 0x70, 0xa0, 0x14, 0x91, 0x9a, 0xd7, 0x33, 0x1c, 0x49, 0xbe, 0xef, 0xcc, 0xb4, 0x37, 0xfe, 0x9a}, - output512: []byte{0x2e, 0x76, 0xd9, 0x3a, 0xff, 0xd6, 0x2b, 0x92, 0xfc, 0x4f, 0x29, 0xcb, 0x83, 0xef, 0xbe, 0x4b, 0xa2, 0x1d, 0x88, 0x42, 0x6a, 0xa7, 0xf0, 0x75, 0xbf, 0xc2, 0x9, 0x60, 0xea, 0x25, 0x87, 0x87, 0x89, 0x81, 0x72, 0xe1, 0x70, 0x45, 0xaf, 0x43, 0xab, 0x1f, 0xe4, 0x45, 0x53, 0x2b, 0xe0, 0x18, 0x5f, 0xbe, 0xa8, 0x4d, 0x9b, 0xe7, 0x88, 0xb0, 0x5f, 0x14, 0xdb, 0xf4, 0x85, 0x6a, 0x52, 0x54}}, - testcase{ - msg: []byte{0xc6, 0xf5, 0xb, 0xb7, 0x4e, 0x29}, - output224: []byte{0x16, 0x3c, 0x90, 0x60, 0x16, 0x3a, 0xa6, 0x6b, 0x8b, 0x7c, 0xc, 0xfa, 0xa6, 0x5d, 0x93, 0x4b, 0xff, 0x21, 0x9b, 0xcb, 0xc2, 0x67, 0x18, 0x7c, 0xab, 0xa0, 0x4, 0x2f}, - output256: []byte{0x92, 0x30, 0x62, 0xc4, 0xe6, 0xf0, 0x57, 0x59, 0x72, 0x20, 0xd1, 0x82, 0xdb, 0xb1, 0xe, 0x81, 0xcd, 0x25, 0xf6, 0xb, 0x54, 0x0, 0x5b, 0x2a, 0x75, 0xdd, 0x33, 0xd6, 0xda, 0xc5, 0x18, 0xd0}, - output384: []byte{0x3, 0x56, 0x6e, 0xc0, 0x3, 0xff, 0x55, 0x18, 0x4f, 0xc, 0x85, 0xbe, 0xeb, 0xc6, 0xd1, 0xec, 0xf5, 0xe5, 0xd0, 0x82, 0xd8, 0xd4, 0x1, 0x37, 0x24, 0x6f, 0x8f, 0xd4, 0x2b, 0xce, 0x9, 0x7c, 0x9, 0x41, 0x88, 0x45, 0xef, 0x60, 0x28, 0x6f, 0xdd, 0x89, 0x4a, 0x0, 0xfd, 0x2d, 0x65, 0x89}, - output512: []byte{0x40, 0xfa, 0x80, 0x74, 0xe1, 0xe5, 0x9, 0xb2, 0x6, 0x44, 0x8f, 0xbe, 0x75, 0x7d, 0x94, 0x94, 0xb9, 0xb5, 0x1e, 0x8d, 0x6e, 0x67, 0x4a, 0x67, 0xf5, 0x3c, 0x11, 0xef, 0x92, 0xe9, 0x6c, 0x3e, 0xa0, 0x8b, 0x95, 0xeb, 0xd4, 0x17, 0x2b, 0x2, 0x0, 0x10, 0xcd, 0x6c, 0xf2, 0x95, 0x39, 0xa3, 0x4d, 0x6b, 0xfa, 0x0, 0x2a, 0x20, 0x42, 0x78, 0x7a, 0xa8, 0xd8, 0x79, 0xa0, 0xf5, 0xb5, 0x4c}}, - testcase{ - msg: []byte{0x11, 0x97, 0x13, 0xcc, 0x83, 0xee, 0xef}, - output224: []byte{0xcf, 0xc0, 0x4c, 0x6f, 0x84, 0x63, 0xdd, 0xab, 0x24, 0xcd, 0xf8, 0xb8, 0x65, 0x2b, 0xd1, 0x1d, 0xf2, 0x3d, 0xd1, 0xb9, 0x5f, 0x11, 0x83, 0x28, 0xdd, 0x1, 0x58, 0xe}, - output256: []byte{0xfe, 0xb8, 0x40, 0x5d, 0xcd, 0x31, 0x5d, 0x48, 0xc6, 0xcb, 0xf7, 0xa3, 0x50, 0x49, 0x96, 0xde, 0x8e, 0x25, 0xcc, 0x22, 0x56, 0x6e, 0xfe, 0xc6, 0x74, 0x33, 0x71, 0x2e, 0xda, 0x99, 0x89, 0x4f}, - output384: []byte{0x79, 0xd, 0x70, 0xf, 0xa3, 0x4d, 0x6a, 0x83, 0x5b, 0xe3, 0x11, 0xb6, 0x39, 0x47, 0x47, 0x80, 0x14, 0x8a, 0x2f, 0x8, 0x7a, 0xc2, 0xfa, 0x86, 0xe8, 0xa1, 0xa4, 0x33, 0xec, 0x7a, 0x4, 0xfc, 0xbf, 0xc5, 0x28, 0x4a, 0x3e, 0x18, 0x8b, 0x7d, 0x91, 0xc6, 0xd0, 0x94, 0xea, 0xfb, 0xee, 0xcb}, - output512: []byte{0xd1, 0x11, 0x67, 0x86, 0xa3, 0xc1, 0xea, 0x46, 0xa8, 0xf2, 0x2d, 0x82, 0xab, 0xb4, 0xc5, 0xd0, 0x6d, 0xc0, 0x69, 0x1b, 0x2e, 0x74, 0x7a, 0xc9, 0x72, 0x6d, 0xb, 0x29, 0xe, 0x69, 0x59, 0xf7, 0xb2, 0x34, 0x28, 0x51, 0x9a, 0x65, 0x6b, 0x23, 0x76, 0x95, 0xe5, 0x64, 0x3, 0x85, 0x5e, 0xc4, 0xc9, 0x8d, 0xb0, 0xcf, 0x87, 0xf3, 0x1b, 0x6c, 0xea, 0xbf, 0x2b, 0x9b, 0x85, 0x89, 0xb7, 0x13}}, - testcase{ - msg: []byte{0x4a, 0x4f, 0x20, 0x24, 0x84, 0x51, 0x25, 0x26}, - output224: []byte{0x7a, 0x5c, 0x2c, 0xb3, 0xf9, 0x99, 0xdd, 0x0, 0xef, 0xf7, 0x39, 0x99, 0x63, 0x31, 0x4c, 0xa6, 0x47, 0xdd, 0xe, 0x5a, 0xe1, 0xbd, 0xde, 0xc6, 0x11, 0xf8, 0x33, 0x8d}, - output256: []byte{0xe6, 0x20, 0xd8, 0xf2, 0x98, 0x2b, 0x24, 0xfe, 0xda, 0xaa, 0x3b, 0xaa, 0x9b, 0x46, 0xc3, 0xf9, 0xce, 0x20, 0x4e, 0xe3, 0x56, 0x66, 0x65, 0x53, 0xec, 0xb3, 0x5e, 0x15, 0xc3, 0xff, 0x9b, 0xf9}, - output384: []byte{0x63, 0x8e, 0x65, 0x75, 0x8a, 0x29, 0x7c, 0xb0, 0x9d, 0xed, 0x1a, 0xc5, 0xb9, 0xe8, 0xf7, 0x79, 0x80, 0x20, 0x0, 0xab, 0x79, 0x1f, 0x67, 0xf3, 0x3c, 0x60, 0xbe, 0x36, 0x44, 0x37, 0x93, 0xad, 0xcc, 0x8a, 0x4a, 0x58, 0xe9, 0x86, 0x88, 0x15, 0x7a, 0x41, 0x78, 0x4f, 0x2, 0xa4, 0xbc, 0xb2}, - output512: []byte{0xf3, 0x26, 0xc7, 0xc1, 0x26, 0xdd, 0xc2, 0x77, 0x92, 0x27, 0x60, 0xfe, 0xef, 0x77, 0xc9, 0xba, 0xb6, 0xfb, 0x5d, 0x34, 0x30, 0xf6, 0x52, 0x59, 0x37, 0x3, 0xd7, 0xc5, 0xe3, 0x1, 0x35, 0xcd, 0xb, 0x5, 0x75, 0x25, 0x75, 0x9, 0xa6, 0x24, 0x18, 0x43, 0x30, 0xd6, 0xab, 0x1f, 0x50, 0x8a, 0x66, 0x63, 0x91, 0xb5, 0xd4, 0x69, 0x4, 0x26, 0xb4, 0xe0, 0x53, 0x1, 0x89, 0x1d, 0xf8, 0x97}}, - testcase{ - msg: []byte{0x1f, 0x66, 0xab, 0x41, 0x85, 0xed, 0x9b, 0x63, 0x75}, - output224: []byte{0xa5, 0xa7, 0x58, 0x6, 0x8, 0x3a, 0xa9, 0x30, 0x70, 0x74, 0xef, 0x8f, 0xbd, 0x7d, 0xf5, 0x92, 0x98, 0x5e, 0x5f, 0x71, 0x46, 0x11, 0xe8, 0x12, 0x21, 0x6c, 0x4, 0x49}, - output256: []byte{0x9e, 0x3, 0xf7, 0xc9, 0xa3, 0xd0, 0x55, 0xec, 0xa1, 0xd7, 0x86, 0xed, 0x6f, 0xb6, 0x24, 0xd9, 0x3f, 0x1c, 0xf0, 0xac, 0x27, 0xf9, 0xc2, 0xb6, 0xc0, 0x5e, 0x50, 0x9f, 0xac, 0x9e, 0x7f, 0xca}, - output384: []byte{0x30, 0x8e, 0xc6, 0xf2, 0xee, 0x3f, 0x6e, 0x1, 0xfb, 0x3a, 0xa0, 0x6e, 0xb7, 0xc8, 0xca, 0xdd, 0x19, 0x93, 0x54, 0x75, 0x1b, 0x69, 0xfd, 0x4b, 0xa4, 0xd4, 0x67, 0x18, 0x58, 0xf2, 0x8b, 0xb4, 0x5c, 0x94, 0xe7, 0x12, 0xad, 0x9d, 0x35, 0x6f, 0xcb, 0x44, 0x30, 0x67, 0xef, 0x5a, 0xca, 0x2d}, - output512: []byte{0x1f, 0x5b, 0x8a, 0x6e, 0x8d, 0x94, 0xf5, 0xe2, 0x53, 0x5d, 0x46, 0x84, 0x2b, 0x9c, 0xed, 0x46, 0x7c, 0x39, 0xc2, 0xdb, 0x32, 0x39, 0x63, 0xd3, 0xf3, 0xd9, 0x37, 0xe9, 0xdd, 0xa7, 0x6f, 0xbc, 0x17, 0x7, 0x2d, 0xda, 0x2a, 0xb4, 0x77, 0x1c, 0xd7, 0xa6, 0x45, 0x14, 0x5a, 0x2a, 0xec, 0x1b, 0x57, 0x49, 0xbf, 0x9e, 0xfe, 0xc, 0xde, 0x0, 0x6c, 0xc3, 0xef, 0x89, 0x36, 0x43, 0x8e, 0xd}}, - testcase{ - msg: []byte{0xee, 0xd7, 0x42, 0x22, 0x27, 0x61, 0x3b, 0x6f, 0x53, 0xc9}, - output224: []byte{0xac, 0x78, 0xfc, 0x53, 0xa1, 0xdb, 0x90, 0xa6, 0x34, 0xf1, 0xaa, 0xaf, 0x90, 0x11, 0x9c, 0x88, 0x9c, 0x8c, 0x24, 0xb5, 0x9b, 0x98, 0xb7, 0x36, 0x60, 0x29, 0xcc, 0x73}, - output256: []byte{0xca, 0xad, 0x8e, 0x1e, 0xd5, 0x46, 0x63, 0x7, 0x48, 0xa1, 0x2f, 0x53, 0x51, 0xb5, 0x18, 0xa9, 0xa4, 0x31, 0xcd, 0xa6, 0xba, 0x56, 0xcb, 0xfc, 0x3c, 0xcb, 0xdd, 0x8a, 0xae, 0x50, 0x92, 0xf7}, - output384: []byte{0xa8, 0x8f, 0x2f, 0xd1, 0x12, 0xe5, 0xf1, 0x1e, 0x77, 0x5a, 0xa7, 0x85, 0x8a, 0x3a, 0x52, 0x2, 0xe8, 0xfc, 0xd2, 0x59, 0xf5, 0xd1, 0x12, 0xba, 0xa6, 0xf5, 0x68, 0x24, 0xd, 0x2e, 0xcc, 0x4, 0x7e, 0xad, 0x88, 0x50, 0x9e, 0x4b, 0x8a, 0x74, 0x7d, 0x37, 0x7, 0x51, 0xff, 0xb2, 0xfd, 0xc0}, - output512: []byte{0x2a, 0xee, 0xe7, 0xa7, 0x20, 0xc0, 0x30, 0xa8, 0x20, 0xcd, 0x7b, 0xaa, 0x85, 0x70, 0xd7, 0x2c, 0xb9, 0xb, 0x7a, 0x23, 0x8c, 0x38, 0xc3, 0x58, 0x67, 0x63, 0x58, 0xa7, 0xae, 0x9a, 0x5c, 0xf2, 0x66, 0x35, 0xb2, 0x32, 0xd, 0x61, 0xc1, 0x28, 0x48, 0x99, 0xe6, 0x54, 0xf0, 0xbf, 0xdd, 0xa, 0x3a, 0x9c, 0x34, 0x3f, 0xfb, 0xd1, 0x18, 0x38, 0xb5, 0x74, 0x65, 0xe6, 0xc3, 0xad, 0x3a, 0x57}}, - testcase{ - msg: []byte{0xea, 0xee, 0xd5, 0xcd, 0xff, 0xd8, 0x9d, 0xec, 0xe4, 0x55, 0xf1}, - output224: []byte{0x67, 0x2c, 0xa6, 0x82, 0x66, 0x86, 0xbe, 0xdb, 0x25, 0x85, 0x32, 0x83, 0xd, 0x60, 0x6b, 0x25, 0x8c, 0x6d, 0xe6, 0x1, 0x54, 0xec, 0x9, 0x57, 0xcd, 0x8b, 0x85, 0x8b}, - output256: []byte{0xd6, 0x17, 0x8, 0xbd, 0xb3, 0x21, 0x1a, 0x9a, 0xab, 0x28, 0xd4, 0xdf, 0x1, 0xdf, 0xa4, 0xb2, 0x9e, 0xd4, 0x2, 0x85, 0x84, 0x4d, 0x84, 0x10, 0x42, 0x25, 0x7e, 0x97, 0x48, 0x86, 0x17, 0xb0}, - output384: []byte{0xa2, 0x2a, 0x31, 0x34, 0x9d, 0x78, 0x16, 0x54, 0x5b, 0xe3, 0x1b, 0x80, 0xe9, 0x92, 0xbd, 0xbb, 0x62, 0xa2, 0x94, 0x80, 0x91, 0x7c, 0xea, 0xbd, 0xa, 0xf5, 0xf2, 0xfa, 0xfb, 0xf2, 0x76, 0xd4, 0xc2, 0x9b, 0x63, 0xa0, 0x49, 0x10, 0xb8, 0x30, 0xb8, 0x75, 0x7c, 0x81, 0xe2, 0x23, 0xb7, 0xf9}, - output512: []byte{0x7b, 0x1c, 0x1b, 0xef, 0x3b, 0x4d, 0xeb, 0x4b, 0x48, 0x12, 0xc8, 0x1a, 0x6e, 0x7b, 0x3f, 0x2c, 0x66, 0xfa, 0x95, 0x15, 0x7f, 0xa3, 0xb9, 0xd2, 0x95, 0x9d, 0xc5, 0x6b, 0x8a, 0xdd, 0x10, 0x1, 0x70, 0xd3, 0xc8, 0xd1, 0x74, 0x5f, 0xd2, 0x30, 0xa3, 0x1f, 0x89, 0xfa, 0x17, 0x88, 0x9c, 0x4c, 0x58, 0x94, 0x6b, 0x5d, 0x74, 0x6e, 0x47, 0xb7, 0x1e, 0xd0, 0x39, 0x4b, 0x66, 0xd1, 0xbd, 0xb2}}, - testcase{ - msg: []byte{0x5b, 0xe4, 0x3c, 0x90, 0xf2, 0x29, 0x2, 0xe4, 0xfe, 0x8e, 0xd2, 0xd3}, - output224: []byte{0xd9, 0x8c, 0xa0, 0x7e, 0x17, 0x2b, 0xb, 0xc5, 0x3d, 0x67, 0x9d, 0x2f, 0x8d, 0x0, 0x2c, 0x63, 0xfd, 0x24, 0xa6, 0x30, 0x7f, 0x2b, 0x7e, 0x1e, 0xee, 0xf2, 0x8b, 0xe0}, - output256: []byte{0xf, 0x53, 0xbe, 0x55, 0x99, 0x7, 0x80, 0xb3, 0xfa, 0xd9, 0x87, 0xf, 0x4, 0xf7, 0xd8, 0x15, 0x3c, 0x3a, 0xe6, 0x5, 0xc0, 0x57, 0xc8, 0x5a, 0xbb, 0x5d, 0x71, 0x76, 0x50, 0x43, 0xaa, 0xa8}, - output384: []byte{0x36, 0xca, 0x9c, 0xc3, 0x29, 0xf9, 0xa0, 0xf, 0xaa, 0x5f, 0x4f, 0x21, 0x17, 0xa, 0x1, 0x77, 0x42, 0x17, 0x4d, 0x3c, 0xf0, 0x3c, 0x8, 0x4a, 0xeb, 0x75, 0x9f, 0x6f, 0xa0, 0x39, 0x3, 0x49, 0xe1, 0xb5, 0x2, 0xe4, 0x35, 0xcf, 0xfb, 0xb, 0xce, 0x4e, 0xd4, 0x6c, 0x0, 0x12, 0xa6, 0x5c}, - output512: []byte{0xee, 0x41, 0x40, 0x1a, 0xf5, 0x9, 0xd6, 0xfc, 0x9, 0x44, 0xcd, 0x4a, 0xb, 0xb2, 0x9d, 0x2d, 0xce, 0xd, 0xcc, 0x86, 0x26, 0x6, 0xe6, 0x69, 0xe3, 0x13, 0x81, 0xe5, 0xd6, 0xce, 0xcb, 0x46, 0x31, 0x43, 0x64, 0x5d, 0x69, 0x6d, 0x14, 0xe4, 0x1, 0x69, 0xcd, 0xc7, 0x1c, 0x75, 0x68, 0x6d, 0x6e, 0x87, 0x32, 0xb4, 0x32, 0x9, 0x26, 0x26, 0x42, 0x1c, 0xc6, 0xcc, 0x19, 0x6f, 0x80, 0xbf}}, - testcase{ - msg: []byte{0xa7, 0x46, 0x27, 0x32, 0x28, 0x12, 0x2f, 0x38, 0x1c, 0x3b, 0x46, 0xe4, 0xf1}, - output224: []byte{0xf1, 0x22, 0xbe, 0x39, 0xc9, 0x1a, 0x6c, 0x17, 0xcd, 0x59, 0x0, 0xf5, 0x31, 0xe6, 0x80, 0xd5, 0x4c, 0xed, 0xef, 0xd4, 0xf0, 0xe3, 0xd1, 0x13, 0xd2, 0x65, 0x43, 0xd4}, - output256: []byte{0x32, 0x21, 0x5a, 0xe8, 0x82, 0x4, 0xa7, 0x82, 0xb6, 0x2d, 0x18, 0x10, 0xd9, 0x45, 0xde, 0x49, 0x94, 0x8d, 0xe4, 0x58, 0x60, 0xf, 0x5e, 0x1e, 0x38, 0x96, 0xce, 0xca, 0x2e, 0xd3, 0x29, 0x2b}, - output384: []byte{0x3d, 0xa5, 0x49, 0x76, 0xb2, 0x91, 0xdf, 0x77, 0xf1, 0xb, 0xf9, 0x5e, 0x9b, 0x7e, 0xf9, 0xfb, 0x2f, 0x88, 0xde, 0x7, 0x5d, 0xdf, 0x66, 0x50, 0xba, 0x78, 0x85, 0x90, 0xf4, 0xe2, 0xe3, 0xc8, 0x30, 0xd3, 0xb7, 0xdf, 0xc0, 0x19, 0x36, 0x56, 0xb0, 0xa1, 0x85, 0xe3, 0xaa, 0xd9, 0xaa, 0x5a}, - output512: []byte{0x9b, 0x53, 0xb4, 0x10, 0xb9, 0xf5, 0xdc, 0xe9, 0xa, 0x77, 0x24, 0x4d, 0xb4, 0x7, 0xa3, 0xd0, 0xf4, 0x89, 0x8d, 0x11, 0x2d, 0x0, 0x44, 0xa8, 0xf6, 0x6a, 0xf9, 0x33, 0xe2, 0x66, 0x66, 0xde, 0x63, 0xeb, 0xd2, 0xa4, 0x32, 0x2d, 0x8f, 0xe5, 0x25, 0xab, 0x35, 0x4c, 0xe9, 0x67, 0x6b, 0x6a, 0x14, 0xd0, 0xce, 0x6b, 0x3d, 0x24, 0xe6, 0xcd, 0x58, 0x32, 0xbe, 0xa0, 0xc5, 0x15, 0x3c, 0xef}}, - testcase{ - msg: []byte{0x3c, 0x58, 0x71, 0xcd, 0x61, 0x9c, 0x69, 0xa6, 0x3b, 0x54, 0xe, 0xb5, 0xa6, 0x25}, - output224: []byte{0x2a, 0x26, 0xd2, 0xad, 0x20, 0x15, 0xc6, 0x7c, 0xab, 0xb7, 0x89, 0x5e, 0xc5, 0xfa, 0x25, 0x47, 0x3d, 0x4d, 0x14, 0x33, 0xfa, 0xe9, 0x2b, 0x9b, 0x2c, 0xda, 0x31, 0xf0}, - output256: []byte{0x95, 0x10, 0xda, 0x68, 0xe5, 0x8e, 0xbb, 0x8d, 0x2a, 0xb9, 0xde, 0x84, 0x85, 0xbb, 0x40, 0x8e, 0x35, 0x82, 0x99, 0xa9, 0xc0, 0x11, 0xae, 0x85, 0x44, 0xb0, 0xd0, 0xfa, 0xf9, 0xd4, 0xa4, 0xea}, - output384: []byte{0xd2, 0x1a, 0x7c, 0xf2, 0x52, 0x35, 0x8a, 0x11, 0x59, 0xa5, 0x59, 0x34, 0x45, 0x6e, 0x67, 0xd9, 0xe1, 0xda, 0x53, 0x8d, 0x4e, 0x9f, 0x9f, 0x1a, 0xce, 0x2f, 0xd7, 0x5f, 0x30, 0x74, 0xb2, 0x7a, 0xe2, 0xb3, 0x56, 0x14, 0x4b, 0xda, 0x7b, 0xa0, 0xb1, 0xec, 0xa1, 0xaa, 0x20, 0x1b, 0x20, 0xde}, - output512: []byte{0x2b, 0x53, 0xfe, 0x65, 0x83, 0xfc, 0x24, 0xee, 0x8a, 0x63, 0x80, 0x10, 0x67, 0xe4, 0xd3, 0xbd, 0x6e, 0x69, 0x34, 0xef, 0x16, 0xbc, 0x82, 0x2f, 0xc3, 0xa6, 0x9f, 0x4e, 0xe1, 0x3a, 0x40, 0x4d, 0x9a, 0x3c, 0xe2, 0xbb, 0x4a, 0x12, 0xc7, 0x73, 0x82, 0xbf, 0xde, 0x4d, 0x84, 0x3f, 0x87, 0xfd, 0x6, 0xed, 0x8a, 0xec, 0xc2, 0x34, 0xa3, 0xa2, 0x4c, 0xed, 0xfe, 0x60, 0xbf, 0xc0, 0x69, 0x33}}, - testcase{ - msg: []byte{0xfa, 0x22, 0x87, 0x4b, 0xcc, 0x6, 0x88, 0x79, 0xe8, 0xef, 0x11, 0xa6, 0x9f, 0x7, 0x22}, - output224: []byte{0xa6, 0x9e, 0x4e, 0xc1, 0x64, 0x8c, 0xbb, 0xd5, 0x95, 0x55, 0x8e, 0xe4, 0xea, 0x34, 0x5e, 0x41, 0x96, 0xc2, 0x88, 0x1e, 0x85, 0xe8, 0x53, 0x73, 0x9b, 0x1f, 0x46, 0x4}, - output256: []byte{0xf2, 0xb, 0x3b, 0xcf, 0x74, 0x3a, 0xa6, 0xfa, 0x8, 0x40, 0x38, 0x52, 0x7, 0x91, 0xc3, 0x64, 0xcb, 0x6d, 0x3d, 0x1d, 0xd7, 0x58, 0x41, 0xf8, 0xd7, 0x2, 0x1c, 0xd9, 0x83, 0x22, 0xbd, 0x8f}, - output384: []byte{0x8a, 0xc, 0x63, 0x31, 0x42, 0x93, 0x75, 0xf0, 0x52, 0x96, 0xa, 0xff, 0xf6, 0xd5, 0xfe, 0x33, 0x75, 0x9f, 0x97, 0x14, 0x5d, 0x60, 0xb2, 0x62, 0xbe, 0xde, 0x86, 0xd5, 0x25, 0x49, 0x94, 0x55, 0x8f, 0xc1, 0x80, 0xa, 0xdd, 0x9, 0xd6, 0x88, 0x7c, 0x27, 0x5f, 0x4d, 0xd3, 0x53, 0x1c, 0xb0}, - output512: []byte{0x80, 0x94, 0x6c, 0xa6, 0x8e, 0x8c, 0x16, 0xa9, 0x66, 0x7c, 0xd8, 0x33, 0x9d, 0x1c, 0x5b, 0x0, 0xf1, 0xe0, 0xd4, 0x1, 0xd0, 0xec, 0xc7, 0x94, 0x58, 0x75, 0x47, 0x94, 0x83, 0x8f, 0x3a, 0xe2, 0x94, 0x9a, 0x8c, 0xc5, 0xfe, 0x55, 0x84, 0x3, 0x3b, 0xca, 0x9c, 0x5b, 0xe6, 0x2c, 0x7c, 0x8, 0xf4, 0x2, 0xef, 0x2, 0xf7, 0x27, 0xce, 0xfa, 0x43, 0xbb, 0xd3, 0x74, 0xc2, 0xa6, 0x7c, 0x52}}, - testcase{ - msg: []byte{0x52, 0xa6, 0x8, 0xab, 0x21, 0xcc, 0xdd, 0x8a, 0x44, 0x57, 0xa5, 0x7e, 0xde, 0x78, 0x21, 0x76}, - output224: []byte{0x56, 0x79, 0xcd, 0x50, 0x9c, 0x51, 0x20, 0xaf, 0x54, 0x79, 0x5c, 0xf4, 0x77, 0x14, 0x96, 0x41, 0xcf, 0x27, 0xb2, 0xeb, 0xb6, 0xa5, 0xf9, 0x3, 0x40, 0x70, 0x4e, 0x57}, - output256: []byte{0xe, 0x32, 0xde, 0xfa, 0x20, 0x71, 0xf0, 0xb5, 0xac, 0xe, 0x6a, 0x10, 0x8b, 0x84, 0x2e, 0xd0, 0xf1, 0xd3, 0x24, 0x97, 0x12, 0xf5, 0x8e, 0xe0, 0xdd, 0xf9, 0x56, 0xfe, 0x33, 0x2a, 0x5f, 0x95}, - output384: []byte{0x18, 0x42, 0x2a, 0xc1, 0xd3, 0xa1, 0xe5, 0x4b, 0xad, 0x87, 0x68, 0x83, 0xd2, 0xd6, 0xdd, 0x65, 0xf6, 0x5c, 0x1d, 0x5f, 0x33, 0xa7, 0x12, 0x5c, 0xc4, 0xc1, 0x86, 0x40, 0x5a, 0x12, 0xed, 0x64, 0xba, 0x96, 0x67, 0x2e, 0xed, 0xda, 0x8c, 0x5a, 0x63, 0x31, 0xd2, 0x86, 0x83, 0xf4, 0x88, 0xeb}, - output512: []byte{0x4b, 0x39, 0xd3, 0xda, 0x5b, 0xcd, 0xf4, 0xd9, 0xb7, 0x69, 0x1, 0x59, 0x95, 0x64, 0x43, 0x11, 0xc1, 0x4c, 0x43, 0x5b, 0xf7, 0x2b, 0x10, 0x9, 0xd6, 0xdd, 0x71, 0xb0, 0x1a, 0x63, 0xb9, 0x7c, 0xfb, 0x59, 0x64, 0x18, 0xe8, 0xe4, 0x23, 0x42, 0xd1, 0x17, 0xe0, 0x74, 0x71, 0xa8, 0x91, 0x43, 0x14, 0xba, 0x7b, 0xe, 0x26, 0x4d, 0xad, 0xf0, 0xce, 0xa3, 0x81, 0x86, 0x8c, 0xbd, 0x43, 0xd1}}, - testcase{ - msg: []byte{0x82, 0xe1, 0x92, 0xe4, 0x4, 0x3d, 0xdc, 0xd1, 0x2e, 0xcf, 0x52, 0x96, 0x9d, 0xf, 0x80, 0x7e, 0xed}, - output224: []byte{0x45, 0x55, 0x84, 0xa1, 0xa3, 0xbb, 0xfb, 0xb9, 0x77, 0xae, 0x8, 0xdd, 0xee, 0x93, 0xda, 0x5a, 0xca, 0xe0, 0xf2, 0xf4, 0xc3, 0xcd, 0xaa, 0xf0, 0x89, 0x72, 0x8a, 0xae}, - output256: []byte{0x92, 0x4, 0x55, 0x6, 0x77, 0xb9, 0xaa, 0x77, 0xe, 0x6e, 0x93, 0xe3, 0x19, 0xb9, 0x95, 0x85, 0x40, 0xd5, 0x4f, 0xf4, 0xdc, 0xcb, 0x6, 0x3c, 0x85, 0x61, 0x30, 0x2c, 0xd8, 0xaf, 0xf6, 0x76}, - output384: []byte{0x4a, 0x59, 0xda, 0x5, 0xc6, 0xe0, 0x35, 0xd5, 0x9d, 0x93, 0xf5, 0x59, 0xd4, 0xa1, 0x30, 0xd3, 0xed, 0x91, 0xc2, 0x2e, 0xad, 0xa5, 0x3f, 0xd6, 0x79, 0xfb, 0xb, 0xf, 0x31, 0x39, 0x8a, 0x6f, 0xf8, 0x3a, 0x5a, 0x97, 0x39, 0xbf, 0xd4, 0xe9, 0x5f, 0x57, 0x31, 0x8f, 0xcc, 0xb8, 0x16, 0xf0}, - output512: []byte{0xc3, 0x7c, 0x9d, 0xc2, 0xe2, 0xd, 0x8e, 0x2f, 0xa, 0xe5, 0x88, 0xd7, 0xd4, 0x5a, 0x80, 0x7c, 0xcf, 0xa0, 0x0, 0xfc, 0x94, 0x8a, 0xc4, 0x2a, 0x8e, 0xd6, 0x3b, 0xb1, 0x4f, 0x31, 0x8f, 0xc3, 0xd4, 0xb9, 0x63, 0xf7, 0x30, 0x59, 0x80, 0xe6, 0xa0, 0xfd, 0x23, 0x16, 0xb5, 0x5b, 0x63, 0x14, 0x23, 0x73, 0xb1, 0xa2, 0x90, 0x2, 0x26, 0x48, 0x55, 0xc7, 0x16, 0xc5, 0xc9, 0xf1, 0x7f, 0x4c}}, - testcase{ - msg: []byte{0x75, 0x68, 0x3d, 0xcb, 0x55, 0x61, 0x40, 0xc5, 0x22, 0x54, 0x3b, 0xb6, 0xe9, 0x9, 0x8b, 0x21, 0xa2, 0x1e}, - output224: []byte{0xbb, 0x77, 0x9e, 0x72, 0x67, 0xca, 0xf0, 0xe8, 0x91, 0x54, 0x7e, 0xe3, 0xe3, 0xba, 0xbf, 0x17, 0x83, 0x76, 0x71, 0xcf, 0x73, 0x1e, 0xd5, 0x63, 0x34, 0xf6, 0x1c, 0xc3}, - output256: []byte{0xa6, 0xd5, 0x44, 0x4c, 0xb7, 0xaa, 0x61, 0xf5, 0x10, 0x6c, 0xde, 0xdb, 0x39, 0xd5, 0xe1, 0xdd, 0x7d, 0x60, 0x8f, 0x10, 0x27, 0x98, 0xd7, 0xe8, 0x18, 0xac, 0x87, 0x28, 0x91, 0x23, 0xa1, 0xdb}, - output384: []byte{0x98, 0xe6, 0xbc, 0xca, 0x5f, 0x2b, 0xb3, 0xc, 0x55, 0x47, 0x0, 0x20, 0x2e, 0x6, 0x4, 0xf7, 0xc8, 0x6b, 0x49, 0x41, 0xf0, 0x34, 0x53, 0x25, 0x10, 0xc, 0x83, 0xb1, 0x23, 0x4c, 0x45, 0x85, 0x6d, 0xfa, 0x76, 0x1e, 0x70, 0xdc, 0xd9, 0x72, 0xec, 0xb1, 0x24, 0x7a, 0xea, 0xc2, 0x92, 0x59}, - output512: []byte{0x90, 0x73, 0xc6, 0x25, 0x55, 0xe6, 0x9, 0x5f, 0x17, 0xdf, 0x71, 0xad, 0x2, 0xba, 0xbb, 0x91, 0x0, 0x28, 0x86, 0x33, 0x89, 0x84, 0x89, 0xb2, 0x1c, 0x90, 0x6a, 0x31, 0x90, 0x87, 0x5b, 0xae, 0xac, 0xcc, 0x83, 0xbe, 0x80, 0xab, 0xd1, 0x14, 0x66, 0xfe, 0xc3, 0x71, 0xba, 0x2c, 0x46, 0x23, 0xd0, 0x7f, 0x1, 0x31, 0xde, 0xfa, 0xec, 0x13, 0xa8, 0xc7, 0x32, 0xa9, 0xf8, 0x41, 0x71, 0x63}}, - testcase{ - msg: []byte{0x6, 0xe4, 0xef, 0xe4, 0x50, 0x35, 0xe6, 0x1f, 0xaa, 0xf4, 0x28, 0x7b, 0x4d, 0x8d, 0x1f, 0x12, 0xca, 0x97, 0xe5}, - output224: []byte{0xe7, 0xb1, 0x81, 0xda, 0xec, 0x13, 0x2d, 0x3b, 0x6c, 0x9d, 0xfb, 0xf6, 0x18, 0x41, 0x13, 0x5b, 0x87, 0xfb, 0x99, 0x5b, 0xe2, 0x9, 0x57, 0xb8, 0xcd, 0x9, 0x5e, 0x2b}, - output256: []byte{0x57, 0x96, 0xb9, 0x93, 0xd0, 0xbd, 0x12, 0x57, 0xcf, 0x26, 0x78, 0x2b, 0x4e, 0x58, 0xfa, 0xfb, 0x22, 0xb0, 0x98, 0x6d, 0x88, 0x68, 0x4a, 0xb5, 0xa2, 0xe6, 0xce, 0xc6, 0x70, 0x62, 0x75, 0xf9}, - output384: []byte{0xd3, 0xc3, 0xd7, 0x6b, 0x3d, 0x39, 0x26, 0xfd, 0x4c, 0xc4, 0xc0, 0x5a, 0x8, 0x7c, 0x2d, 0x76, 0x99, 0x29, 0x98, 0xa5, 0xcd, 0x8c, 0x13, 0xfa, 0x3d, 0x23, 0x3e, 0xe, 0xcb, 0x2a, 0xd8, 0xb8, 0x1b, 0xa4, 0xbe, 0x58, 0x1e, 0x2, 0xbe, 0x91, 0xc7, 0xf8, 0x2c, 0xca, 0xc9, 0x0, 0x13, 0xa0}, - output512: []byte{0x23, 0xe9, 0x35, 0x28, 0x56, 0x71, 0x8e, 0x1e, 0x2d, 0x68, 0xa2, 0x1d, 0x56, 0xd9, 0x31, 0x17, 0xce, 0xd7, 0x62, 0x8e, 0x98, 0x4f, 0xf0, 0x4e, 0xd8, 0xc0, 0xcb, 0x9b, 0x10, 0x53, 0x9e, 0x4e, 0xde, 0x28, 0x4f, 0x94, 0xfa, 0x71, 0xbf, 0x4b, 0x83, 0xbb, 0xb4, 0x93, 0x43, 0x5f, 0xd6, 0xbe, 0x26, 0xed, 0xdb, 0x9, 0xde, 0xac, 0x39, 0x68, 0xe, 0x6b, 0x5, 0xac, 0xc8, 0x7b, 0x8c, 0x4e}}, - testcase{ - msg: []byte{0xe2, 0x61, 0x93, 0x98, 0x9d, 0x6, 0x56, 0x8f, 0xe6, 0x88, 0xe7, 0x55, 0x40, 0xae, 0xa0, 0x67, 0x47, 0xd9, 0xf8, 0x51}, - output224: []byte{0x44, 0x72, 0x96, 0x46, 0xa0, 0x5a, 0xd0, 0x50, 0x3a, 0x87, 0x6b, 0x44, 0x8f, 0x88, 0xf1, 0x77, 0xa0, 0xa2, 0x63, 0xab, 0x74, 0x6c, 0xa6, 0xe3, 0x6, 0x76, 0xad, 0xb2}, - output256: []byte{0xcf, 0xbe, 0x73, 0xc6, 0x58, 0x5b, 0xe6, 0x20, 0x4d, 0xd4, 0x73, 0xab, 0xe3, 0x56, 0xb5, 0x39, 0x47, 0x71, 0x74, 0xc4, 0xb7, 0x70, 0xbf, 0xc9, 0x1e, 0x9f, 0xdb, 0xcb, 0xc5, 0x70, 0x86, 0xe6}, - output384: []byte{0x7c, 0x53, 0xda, 0x6, 0x0, 0x58, 0x18, 0x3c, 0xa6, 0x20, 0x4e, 0x77, 0xf0, 0x70, 0x9a, 0xeb, 0xef, 0x73, 0x55, 0x7c, 0x8f, 0x5e, 0x45, 0xc1, 0x95, 0xb7, 0xe9, 0x41, 0x6e, 0x72, 0x61, 0x36, 0x5d, 0x3, 0xb8, 0xa2, 0xd6, 0xc0, 0x1a, 0x10, 0x26, 0x55, 0x34, 0x4e, 0x72, 0x54, 0x75, 0xc4}, - output512: []byte{0x90, 0x9d, 0x75, 0x34, 0x26, 0xb1, 0xde, 0xe0, 0x9f, 0xc4, 0x74, 0xf1, 0x8c, 0xf8, 0x10, 0xd5, 0xd5, 0xaa, 0xdb, 0xf8, 0xa0, 0x9a, 0xf4, 0x95, 0xbf, 0x6c, 0x22, 0xac, 0xa0, 0xc6, 0x73, 0x2, 0x1b, 0xfc, 0x5d, 0x2a, 0xd9, 0x4f, 0x50, 0xb2, 0x4e, 0x15, 0x69, 0xe9, 0x56, 0x69, 0x4b, 0x21, 0xcf, 0x2c, 0xc8, 0xb4, 0xf3, 0xc7, 0xee, 0x4c, 0xf1, 0x95, 0xe4, 0x42, 0x4c, 0xc4, 0x15, 0xdd}}, - testcase{ - msg: []byte{0xd8, 0xdc, 0x8f, 0xde, 0xfb, 0xdc, 0xe9, 0xd4, 0x4e, 0x4c, 0xba, 0xfe, 0x78, 0x44, 0x7b, 0xae, 0x3b, 0x54, 0x36, 0x10, 0x2a}, - output224: []byte{0x5, 0xe1, 0x57, 0x93, 0xe4, 0x17, 0xdd, 0x4e, 0x2, 0xcd, 0x6c, 0x56, 0x36, 0xd4, 0x2c, 0x16, 0x38, 0xc1, 0x64, 0xd7, 0xb, 0x79, 0xf7, 0x17, 0xf2, 0x5d, 0x1a, 0x15}, - output256: []byte{0x31, 0xc8, 0x0, 0x6b, 0xe, 0xc3, 0x5e, 0x69, 0x6, 0x74, 0x29, 0x7c, 0xb2, 0x74, 0x76, 0xdb, 0x60, 0x66, 0xb5, 0xfa, 0x98, 0x25, 0xc6, 0x7, 0x28, 0xe9, 0xe0, 0xbb, 0x33, 0x8f, 0xb7, 0xc3}, - output384: []byte{0x24, 0x15, 0xc1, 0xd0, 0x53, 0xca, 0x20, 0x7c, 0x17, 0xd9, 0x9d, 0x2, 0xdb, 0xd1, 0x77, 0xcd, 0x1a, 0xa7, 0xf0, 0xb, 0xd, 0xc, 0xa2, 0xcf, 0x30, 0xb4, 0xd2, 0x9, 0x8e, 0xea, 0x1a, 0x4, 0xa6, 0x8e, 0x5b, 0x1c, 0x6d, 0xf2, 0xfb, 0x25, 0xec, 0xe1, 0x57, 0xc4, 0x23, 0xee, 0x8a, 0xb7}, - output512: []byte{0x4, 0x6c, 0x60, 0x19, 0xfc, 0x4d, 0x62, 0x8a, 0xe0, 0xda, 0x70, 0x92, 0xf9, 0x91, 0xf, 0x26, 0x9b, 0x85, 0x3d, 0x3b, 0x57, 0x5, 0x20, 0x39, 0xad, 0x13, 0x75, 0xc6, 0x65, 0x40, 0x5f, 0x9f, 0xd7, 0x9d, 0x57, 0x57, 0x9f, 0x42, 0xc4, 0xff, 0xf2, 0x49, 0xbb, 0x85, 0xae, 0x65, 0x11, 0x3a, 0x9f, 0x42, 0x76, 0xce, 0xde, 0x73, 0xe9, 0xcc, 0xb0, 0xc2, 0x47, 0x53, 0x93, 0x5a, 0x0, 0x6e}}, - testcase{ - msg: []byte{0x57, 0x8, 0x5f, 0xd7, 0xe1, 0x42, 0x16, 0xab, 0x10, 0x2d, 0x83, 0x17, 0xb0, 0xcb, 0x33, 0x8a, 0x78, 0x6d, 0x5f, 0xc3, 0x2d, 0x8f}, - output224: []byte{0x2c, 0x40, 0x77, 0xa8, 0x85, 0x89, 0x66, 0xef, 0x79, 0xaa, 0xc3, 0xec, 0x6d, 0x82, 0x85, 0x5e, 0xad, 0x22, 0x86, 0x7b, 0xa4, 0x5d, 0x61, 0x7a, 0x68, 0xcb, 0x92, 0x6e}, - output256: []byte{0x3b, 0x8f, 0xa3, 0x90, 0x4f, 0xe1, 0xb8, 0x37, 0x56, 0x5a, 0x50, 0xd0, 0xfb, 0xf0, 0x3e, 0x48, 0x7d, 0x6d, 0x72, 0xfc, 0x3c, 0xea, 0x41, 0xad, 0xcc, 0xe3, 0x3d, 0xf1, 0xb8, 0x35, 0xd2, 0x47}, - output384: []byte{0x90, 0xda, 0x42, 0xb0, 0xc3, 0x14, 0x44, 0x5e, 0xaf, 0xd8, 0x65, 0x6b, 0x26, 0x64, 0x4a, 0xdd, 0xed, 0xdc, 0x71, 0x3e, 0xab, 0x36, 0x28, 0x9b, 0xff, 0xc6, 0xed, 0x4a, 0x85, 0xbe, 0x66, 0xa1, 0xf, 0x5a, 0xcd, 0x6b, 0x3c, 0x61, 0xe9, 0xc3, 0x6a, 0x17, 0xc2, 0x62, 0x60, 0x87, 0x2d, 0xc8}, - output512: []byte{0x51, 0xc9, 0x9, 0xa6, 0x52, 0x89, 0x49, 0xba, 0xdd, 0xaf, 0x1b, 0xa0, 0xb1, 0x54, 0xea, 0x9c, 0x33, 0xfd, 0xe5, 0x7, 0x43, 0x59, 0x50, 0x5b, 0x76, 0xd4, 0xb7, 0xed, 0x54, 0x35, 0x2d, 0xd8, 0x93, 0xd4, 0xb, 0x14, 0x2a, 0x5f, 0x80, 0x2f, 0x37, 0x8c, 0xba, 0x7b, 0x8c, 0x37, 0x82, 0xec, 0xf2, 0xa0, 0x48, 0x54, 0x2b, 0xe6, 0xc5, 0x93, 0x68, 0x22, 0x21, 0x48, 0x46, 0xa8, 0xd5, 0xe4}}, - testcase{ - msg: []byte{0xa0, 0x54, 0x4, 0xdf, 0x5d, 0xbb, 0x57, 0x69, 0x7e, 0x2c, 0x16, 0xfa, 0x29, 0xde, 0xfa, 0xc8, 0xab, 0x35, 0x60, 0xd6, 0x12, 0x6f, 0xa0}, - output224: []byte{0x2e, 0x89, 0x7b, 0x47, 0x9f, 0xbc, 0xbf, 0x42, 0xd2, 0x13, 0x9f, 0x67, 0x68, 0xdf, 0x14, 0x7a, 0x3b, 0x85, 0xc3, 0x6a, 0x5b, 0x3f, 0x3c, 0x6, 0x6e, 0xb0, 0x56, 0x5e}, - output256: []byte{0x37, 0xfe, 0xbc, 0x4d, 0xf9, 0xd5, 0xd, 0xae, 0xab, 0xd0, 0xca, 0xa6, 0x57, 0x88, 0x12, 0xa6, 0x87, 0xe5, 0x5f, 0x1a, 0xc0, 0xb1, 0x9, 0xd2, 0x51, 0x28, 0x10, 0xd0, 0x5, 0x48, 0xc8, 0x5b}, - output384: []byte{0xee, 0x20, 0x9e, 0x98, 0xa7, 0x5a, 0x67, 0xb0, 0x90, 0x8, 0x20, 0x2c, 0xad, 0x38, 0x9, 0x17, 0xeb, 0x1f, 0x92, 0xc5, 0xdb, 0x4e, 0x8f, 0x2c, 0x64, 0x90, 0xa, 0xf8, 0xc6, 0x3, 0xd2, 0x65, 0xca, 0xb3, 0x17, 0xbf, 0x7b, 0x8e, 0x22, 0x51, 0xe4, 0x79, 0xf8, 0x81, 0x8d, 0x30, 0x22, 0xca}, - output512: []byte{0xef, 0xc8, 0x91, 0x7e, 0x12, 0x47, 0x74, 0x2a, 0x2d, 0x4e, 0xc2, 0x9a, 0xfe, 0xdd, 0xf1, 0xe6, 0xec, 0xe3, 0x77, 0xb3, 0xd8, 0xac, 0x6e, 0x58, 0xc9, 0x85, 0x1c, 0xe9, 0xc9, 0x9b, 0xd5, 0x99, 0xad, 0xeb, 0xfe, 0xd6, 0x57, 0xba, 0xac, 0xd1, 0x79, 0x3f, 0xc9, 0x1b, 0x4, 0xdf, 0x29, 0x57, 0xbf, 0x6f, 0x18, 0x88, 0x86, 0x92, 0x86, 0x0, 0x2d, 0xc4, 0xad, 0x9a, 0xc7, 0xf7, 0x67, 0x93}}, - testcase{ - msg: []byte{0xae, 0xcb, 0xb0, 0x27, 0x59, 0xf7, 0x43, 0x3d, 0x6f, 0xcb, 0x6, 0x96, 0x3c, 0x74, 0x6, 0x1c, 0xd8, 0x3b, 0x5b, 0x3f, 0xfa, 0x6f, 0x13, 0xc6}, - output224: []byte{0xba, 0x76, 0xff, 0xef, 0xd0, 0x6, 0xb8, 0x1e, 0xf5, 0x99, 0x1e, 0x69, 0x7d, 0x4, 0x25, 0x62, 0x1b, 0x16, 0x81, 0x8e, 0xa2, 0x7c, 0x11, 0x5, 0x6e, 0x0, 0x90, 0x4e}, - output256: []byte{0x23, 0x29, 0x81, 0xb, 0x5a, 0x47, 0x35, 0xbc, 0xd4, 0x9c, 0x10, 0xe6, 0x45, 0x6c, 0xb, 0x1d, 0xed, 0x5e, 0xac, 0x25, 0x8a, 0xf4, 0x7c, 0xbb, 0x79, 0x7c, 0xa1, 0x62, 0xab, 0x6d, 0x1b, 0xa8}, - output384: []byte{0x11, 0x98, 0xef, 0xa5, 0x7e, 0x1a, 0x78, 0x84, 0xda, 0xc8, 0x27, 0xe6, 0x83, 0x25, 0x55, 0x75, 0x51, 0xe, 0x1f, 0x92, 0x2, 0x4a, 0x13, 0x51, 0x44, 0x65, 0x9b, 0xe8, 0x7b, 0xbf, 0xd, 0x6, 0x3e, 0xd2, 0x6c, 0x98, 0x76, 0x47, 0xb9, 0x23, 0xa0, 0x91, 0xcf, 0x11, 0x68, 0x3, 0x16, 0xfe}, - output512: []byte{0xfc, 0xef, 0x88, 0xbc, 0xc7, 0xef, 0x70, 0xd8, 0xc3, 0x97, 0x34, 0x29, 0xac, 0x51, 0x39, 0x15, 0x5f, 0x9b, 0xa6, 0x43, 0xb4, 0x31, 0x1, 0x3f, 0x18, 0x17, 0xec, 0xd2, 0xff, 0x3a, 0xb2, 0x87, 0x88, 0xf, 0x9e, 0xa5, 0x4d, 0xf7, 0x50, 0x3c, 0xb3, 0xf7, 0x3d, 0x7c, 0xf2, 0xb8, 0x7d, 0x2e, 0x9b, 0xdb, 0xd2, 0x3, 0x37, 0x8f, 0xae, 0x74, 0xca, 0x4b, 0xd2, 0x66, 0x7a, 0x4a, 0xa7, 0x6}}, - testcase{ - msg: []byte{0xaa, 0xfd, 0xc9, 0x24, 0x3d, 0x3d, 0x4a, 0x9, 0x65, 0x58, 0xa3, 0x60, 0xcc, 0x27, 0xc8, 0xd8, 0x62, 0xf0, 0xbe, 0x73, 0xdb, 0x5e, 0x88, 0xaa, 0x55}, - output224: []byte{0x1c, 0x1e, 0x75, 0x8d, 0x87, 0x39, 0x9a, 0x36, 0xbf, 0x7c, 0x8a, 0x2e, 0x6a, 0x55, 0xce, 0x6a, 0x4f, 0xc, 0x49, 0x87, 0x37, 0x95, 0x69, 0x59, 0x95, 0x9f, 0xd2, 0xac}, - output256: []byte{0x6f, 0xff, 0xa0, 0x70, 0xb8, 0x65, 0xbe, 0x3e, 0xe7, 0x66, 0xdc, 0x2d, 0xb4, 0x9b, 0x6a, 0xa5, 0x5c, 0x36, 0x9f, 0x7d, 0xe3, 0x70, 0x3a, 0xda, 0x26, 0x12, 0xd7, 0x54, 0x14, 0x5c, 0x1, 0xe6}, - output384: []byte{0x4, 0x35, 0xe5, 0x4c, 0x1, 0x6c, 0x7, 0x91, 0x67, 0x7d, 0xdb, 0xc6, 0xba, 0xdd, 0x55, 0xd1, 0x46, 0x75, 0x42, 0x96, 0xb3, 0x11, 0x32, 0xb0, 0xb1, 0xc0, 0xb5, 0xce, 0x4a, 0xed, 0xb0, 0x3a, 0xea, 0xa9, 0xa2, 0xdc, 0x51, 0x57, 0xd7, 0xaf, 0x20, 0xb8, 0xe3, 0x6d, 0x75, 0xe1, 0xcc, 0x0}, - output512: []byte{0x47, 0xb, 0xdd, 0x8d, 0x70, 0x98, 0x75, 0xc8, 0xe6, 0xf8, 0x85, 0x91, 0xb9, 0x7d, 0x64, 0x86, 0xc5, 0xf0, 0x3b, 0x54, 0xbf, 0xc9, 0x5, 0x75, 0x74, 0x83, 0xe0, 0x13, 0xf6, 0x3a, 0x6c, 0x56, 0x98, 0x4d, 0x45, 0x18, 0xd4, 0x5c, 0x2d, 0x22, 0x98, 0xea, 0xdb, 0x44, 0xaf, 0x3a, 0xc, 0x35, 0xa7, 0x6b, 0x57, 0x3d, 0x45, 0x2f, 0x57, 0x47, 0x84, 0x4d, 0x3a, 0xd8, 0xf8, 0x4a, 0x2e, 0x85}}, - testcase{ - msg: []byte{0x7b, 0xc8, 0x48, 0x67, 0xf6, 0xf9, 0xe9, 0xfd, 0xc3, 0xe1, 0x4, 0x6c, 0xae, 0x3a, 0x52, 0xc7, 0x7e, 0xd4, 0x85, 0x86, 0xe, 0xe2, 0x60, 0xe3, 0xb, 0x15}, - output224: []byte{0xdd, 0xea, 0x76, 0x40, 0x9c, 0x61, 0xf6, 0xd1, 0x87, 0x3f, 0x1, 0xa3, 0x42, 0x51, 0xc7, 0x4c, 0x37, 0xb3, 0x4f, 0x28, 0xf7, 0xf4, 0x82, 0xa8, 0x43, 0x95, 0xb5, 0xf3}, - output256: []byte{0xb3, 0x7, 0x61, 0xc0, 0x53, 0xe9, 0x26, 0xf1, 0x50, 0xb9, 0xdc, 0xe7, 0xe0, 0x5, 0xb4, 0xd8, 0x78, 0x11, 0xcc, 0xfb, 0x9e, 0x3b, 0x6e, 0xdb, 0x2, 0x21, 0x2, 0x2f, 0x1, 0x71, 0x1c, 0xf0}, - output384: []byte{0x88, 0xd8, 0x98, 0xed, 0x7e, 0x6e, 0x54, 0xa6, 0x83, 0x81, 0x2b, 0x37, 0x2f, 0x67, 0x8a, 0x5f, 0xd7, 0x3b, 0xcf, 0x31, 0x60, 0xa9, 0x69, 0xfe, 0x45, 0x84, 0x65, 0x1a, 0xdb, 0x32, 0x55, 0xf9, 0xad, 0xcc, 0x8b, 0x85, 0xdc, 0xca, 0x5c, 0x3b, 0xf8, 0xeb, 0xa3, 0xa1, 0xb6, 0x9d, 0x9b, 0x90}, - output512: []byte{0x42, 0x9f, 0xd4, 0x38, 0xb3, 0x90, 0xad, 0x2, 0x24, 0x2, 0x89, 0x75, 0x46, 0x7e, 0xc2, 0x28, 0xf9, 0xad, 0xcd, 0xe7, 0x1e, 0x17, 0x38, 0x0, 0x5e, 0x37, 0x17, 0xc5, 0x8f, 0x72, 0x7a, 0xa2, 0xb7, 0xc6, 0x17, 0x80, 0xbf, 0xc, 0x5f, 0x8b, 0x76, 0x6c, 0xc6, 0xd3, 0x45, 0x51, 0xd8, 0x7d, 0x22, 0xa1, 0x30, 0xb8, 0xc2, 0x15, 0x61, 0x42, 0x4, 0xe6, 0x7, 0xaa, 0x82, 0xff, 0x84, 0x69}}, - testcase{ - msg: []byte{0xfa, 0xc5, 0x23, 0x57, 0x5a, 0x99, 0xec, 0x48, 0x27, 0x9a, 0x7a, 0x45, 0x9e, 0x98, 0xff, 0x90, 0x19, 0x18, 0xa4, 0x75, 0x3, 0x43, 0x27, 0xef, 0xb5, 0x58, 0x43}, - output224: []byte{0x77, 0x7c, 0x52, 0x3c, 0xf4, 0x2d, 0x0, 0x6, 0xed, 0x1f, 0x88, 0xf1, 0xbd, 0xc, 0x3a, 0x5e, 0xf2, 0x18, 0x14, 0x72, 0x37, 0x94, 0xb8, 0x46, 0x1a, 0x37, 0x5c, 0x3a}, - output256: []byte{0x4, 0xf1, 0xb3, 0xc1, 0xe2, 0x5b, 0xa5, 0xd0, 0x12, 0xe2, 0x2a, 0xd1, 0x44, 0xe5, 0xa8, 0x71, 0x9d, 0x94, 0x32, 0x2d, 0x5, 0xad, 0x9e, 0xf6, 0x1e, 0x7d, 0xb4, 0x9b, 0x59, 0x95, 0x9b, 0x3a}, - output384: []byte{0x7a, 0xc3, 0x43, 0xa9, 0x36, 0x9f, 0xa7, 0xbf, 0x45, 0xaf, 0xed, 0x43, 0x8, 0x4d, 0xc1, 0xe2, 0x75, 0xab, 0x1b, 0x70, 0x3, 0x4c, 0xfa, 0xac, 0xd4, 0xf3, 0xcb, 0x5e, 0x5e, 0x22, 0x1, 0xcf, 0xbd, 0x1c, 0xff, 0xf8, 0x3b, 0xaa, 0xd3, 0x89, 0x7a, 0x4c, 0xb8, 0xa0, 0xde, 0x5c, 0x35, 0xc4}, - output512: []byte{0x79, 0xa, 0x1, 0xa, 0xeb, 0x6f, 0x13, 0xe0, 0x19, 0xa1, 0xdc, 0x35, 0x57, 0x4b, 0x12, 0x19, 0xe7, 0x4f, 0xf5, 0xdb, 0x6f, 0xbd, 0x87, 0x46, 0x73, 0x36, 0x64, 0xff, 0xdb, 0xcf, 0xe1, 0xcc, 0x6e, 0x8a, 0xb3, 0x91, 0x17, 0xe3, 0x24, 0x4c, 0x4f, 0xa3, 0xc0, 0xa9, 0x62, 0xc9, 0xf5, 0x0, 0x30, 0xae, 0xf8, 0x8e, 0x19, 0x3e, 0x7e, 0xd, 0x4c, 0x47, 0x47, 0x34, 0x5f, 0x30, 0xcb, 0x54}}, - testcase{ - msg: []byte{0xf, 0x8b, 0x2d, 0x8f, 0xcf, 0xd9, 0xd6, 0x8c, 0xff, 0xc1, 0x7c, 0xcf, 0xb1, 0x17, 0x70, 0x9b, 0x53, 0xd2, 0x64, 0x62, 0xa3, 0xf3, 0x46, 0xfb, 0x7c, 0x79, 0xb8, 0x5e}, - output224: []byte{0x8d, 0x74, 0x74, 0xed, 0x6d, 0xea, 0x46, 0x26, 0xad, 0x3c, 0x1d, 0x6, 0xd2, 0xad, 0x5b, 0x19, 0x8c, 0xaa, 0xd0, 0x7b, 0x12, 0x7, 0x7c, 0x68, 0xc, 0xf6, 0xd8, 0x9b}, - output256: []byte{0xae, 0xef, 0x4b, 0x4d, 0xa4, 0x20, 0x83, 0x4f, 0xfc, 0xed, 0x26, 0xdb, 0x29, 0x12, 0x48, 0xfb, 0x2d, 0x1, 0xe7, 0x65, 0xe2, 0xb0, 0x56, 0x40, 0x57, 0xf8, 0xe6, 0xc2, 0x3, 0xa, 0xc3, 0x7f}, - output384: []byte{0x58, 0x87, 0x7b, 0x8d, 0xd9, 0x8c, 0x51, 0x33, 0x9e, 0x43, 0x2, 0xab, 0xe9, 0x5c, 0xf5, 0x76, 0x62, 0xcf, 0x5, 0xaa, 0x1, 0x93, 0x81, 0x61, 0xcb, 0xfb, 0x5d, 0xdd, 0xa7, 0x24, 0x51, 0x7f, 0xc, 0x0, 0x2d, 0x54, 0xb5, 0x4e, 0xea, 0x7e, 0xbd, 0x64, 0xe2, 0x9, 0xda, 0xeb, 0x8f, 0x1}, - output512: []byte{0xaa, 0xf7, 0xa3, 0x91, 0x60, 0x2, 0x70, 0xf7, 0xb5, 0xa2, 0xa3, 0xbb, 0xc7, 0x47, 0x4a, 0xc4, 0x15, 0x4e, 0xbe, 0xac, 0x3, 0xa7, 0x90, 0xa5, 0x7f, 0xda, 0xd9, 0x6c, 0xea, 0x2d, 0x4, 0x3c, 0x9f, 0xa5, 0xf6, 0x91, 0x67, 0x90, 0xb9, 0x2f, 0x80, 0x32, 0xd6, 0x68, 0xed, 0x9a, 0x7, 0x11, 0x2d, 0xc5, 0xb2, 0x37, 0x3e, 0xc8, 0x16, 0xaa, 0xbc, 0xa6, 0xf5, 0x77, 0xce, 0x60, 0x41, 0x5e}}, - testcase{ - msg: []byte{0xa9, 0x63, 0xc3, 0xe8, 0x95, 0xff, 0x5a, 0xb, 0xe4, 0x82, 0x44, 0x0, 0x51, 0x8d, 0x81, 0x41, 0x2f, 0x87, 0x5f, 0xa5, 0x5, 0x21, 0xe2, 0x6e, 0x85, 0xea, 0xc9, 0xc, 0x4}, - output224: []byte{0xf5, 0x25, 0xd4, 0x51, 0x5d, 0x3c, 0xa5, 0x4a, 0x2f, 0xab, 0x9c, 0x67, 0x9e, 0x93, 0x56, 0x1f, 0xe1, 0x51, 0xea, 0x9, 0x60, 0x75, 0x13, 0x52, 0xcd, 0x7f, 0x59, 0x1a}, - output256: []byte{0x3, 0xd2, 0x6a, 0xee, 0xb4, 0xa7, 0xbd, 0xdd, 0xbf, 0xf7, 0xcf, 0xf6, 0x67, 0x19, 0x8c, 0x42, 0x59, 0x41, 0xa2, 0x77, 0x69, 0x22, 0xdf, 0x2b, 0xec, 0x54, 0x5f, 0x53, 0x4, 0xe2, 0xc6, 0x1c}, - output384: []byte{0x1c, 0xd6, 0x38, 0x12, 0x87, 0x18, 0xbe, 0x35, 0x13, 0x85, 0xe7, 0xa1, 0x56, 0xc3, 0xf0, 0xee, 0x8b, 0x21, 0xd, 0x15, 0x65, 0x87, 0x6f, 0x8e, 0xd4, 0x6c, 0x22, 0x7b, 0x93, 0xd, 0x18, 0x8f, 0xe8, 0xca, 0x27, 0x76, 0xf, 0xe1, 0x89, 0xd3, 0xb1, 0x36, 0x83, 0x65, 0x61, 0xe9, 0xa0, 0xee}, - output512: []byte{0x3e, 0x28, 0x80, 0xa9, 0x74, 0xe5, 0xf, 0x98, 0xbd, 0x6c, 0xc0, 0xf9, 0xd7, 0x69, 0xaf, 0x34, 0x8c, 0xe3, 0xb7, 0xe8, 0xfa, 0x38, 0xcf, 0xc, 0xa2, 0xda, 0x5f, 0xd7, 0x4, 0xc9, 0xc0, 0xe5, 0x7d, 0x55, 0x0, 0xbe, 0xa3, 0xcb, 0x74, 0x77, 0x92, 0x7f, 0x9c, 0x39, 0x4a, 0xa3, 0xf9, 0xbb, 0xc0, 0x18, 0x24, 0x35, 0x2, 0x91, 0xb9, 0xa0, 0xa0, 0xcb, 0xf0, 0x94, 0xbb, 0x37, 0xda, 0x55}}, - testcase{ - msg: []byte{0x3, 0xa1, 0x86, 0x88, 0xb1, 0xc, 0xc0, 0xed, 0xf8, 0x3a, 0xdf, 0xa, 0x84, 0x80, 0x8a, 0x97, 0x18, 0x38, 0x3c, 0x40, 0x70, 0xc6, 0xc4, 0xf2, 0x95, 0x9, 0x86, 0x99, 0xac, 0x2c}, - output224: []byte{0x9a, 0x84, 0x55, 0xf4, 0x1f, 0x69, 0x3b, 0x91, 0xb3, 0xde, 0x46, 0xbf, 0x66, 0xff, 0x9, 0xd4, 0x2d, 0xc3, 0x0, 0xb8, 0x56, 0xb1, 0xdc, 0x2d, 0xfd, 0x12, 0x55, 0x5c}, - output256: []byte{0x43, 0x5c, 0xfc, 0xd, 0x1a, 0xfd, 0x8d, 0x55, 0x9, 0xa9, 0xcc, 0xbf, 0x49, 0x70, 0x65, 0x75, 0x3, 0x86, 0x85, 0xbf, 0x8, 0xdb, 0x54, 0x9d, 0x97, 0x14, 0x54, 0x82, 0x40, 0x46, 0x3e, 0xe9}, - output384: []byte{0xb4, 0xdb, 0xdf, 0xd9, 0x92, 0x2a, 0xfd, 0x1c, 0xe4, 0x6f, 0xf1, 0xcb, 0x27, 0xc3, 0xe, 0x2a, 0xea, 0xa9, 0x67, 0x63, 0x1a, 0x4, 0x0, 0x1c, 0x7e, 0xf2, 0xb5, 0xea, 0xbd, 0x3c, 0x6, 0x78, 0xc0, 0xff, 0x21, 0x9b, 0xe7, 0xb9, 0xfa, 0x4, 0xcf, 0x83, 0xdd, 0x40, 0xbc, 0x1b, 0x33, 0xb6}, - output512: []byte{0x48, 0xe5, 0x5e, 0x3, 0x40, 0xf2, 0x4, 0x66, 0x88, 0x1a, 0x73, 0x2a, 0xa8, 0x84, 0x59, 0xad, 0x4b, 0xcd, 0xef, 0x36, 0x4c, 0x3b, 0xd0, 0x45, 0xae, 0x9, 0x9f, 0x95, 0x3d, 0x89, 0xf1, 0x59, 0x57, 0xae, 0xf2, 0x4, 0x26, 0x5c, 0x39, 0x15, 0xba, 0x42, 0xfe, 0x42, 0x35, 0x19, 0x6b, 0xe3, 0xd0, 0xf5, 0x64, 0x67, 0x62, 0x27, 0xc3, 0xc0, 0xde, 0xac, 0xfb, 0xaf, 0x68, 0xf9, 0xe7, 0x17}}, - testcase{ - msg: []byte{0x84, 0xfb, 0x51, 0xb5, 0x17, 0xdf, 0x6c, 0x5a, 0xcc, 0xb5, 0xd0, 0x22, 0xf8, 0xf2, 0x8d, 0xa0, 0x9b, 0x10, 0x23, 0x2d, 0x42, 0x32, 0xf, 0xfc, 0x32, 0xdb, 0xec, 0xc3, 0x83, 0x5b, 0x29}, - output224: []byte{0x81, 0xaf, 0x3a, 0x7a, 0x5b, 0xd4, 0xc1, 0xf9, 0x48, 0xd6, 0xaf, 0x4b, 0x96, 0xf9, 0x3c, 0x3b, 0xc, 0xf9, 0xc0, 0xe7, 0xa6, 0xda, 0x6f, 0xcd, 0x71, 0xee, 0xc7, 0xf6}, - output256: []byte{0xd4, 0x77, 0xfb, 0x2, 0xca, 0xaa, 0x95, 0xb3, 0x28, 0xe, 0xc8, 0xee, 0x88, 0x2c, 0x29, 0xd9, 0xe8, 0xa6, 0x54, 0xb2, 0x1e, 0xf1, 0x78, 0xe0, 0xf9, 0x75, 0x71, 0xbf, 0x9d, 0x4d, 0x3c, 0x1c}, - output384: []byte{0x50, 0x3d, 0xca, 0xa4, 0xad, 0xda, 0x5a, 0x94, 0x20, 0xb2, 0xe4, 0x36, 0xdd, 0x62, 0xd9, 0xab, 0x2e, 0x2, 0x54, 0x29, 0x5c, 0x29, 0x82, 0xef, 0x67, 0xfc, 0xe4, 0xf, 0x11, 0x7a, 0x24, 0x0, 0xab, 0x49, 0x2f, 0x7b, 0xd5, 0xd1, 0x33, 0xc6, 0xec, 0x22, 0x32, 0x26, 0x8b, 0xc2, 0x7b, 0x42}, - output512: []byte{0x9d, 0x80, 0x98, 0xd8, 0xd6, 0xed, 0xbb, 0xaa, 0x2b, 0xcf, 0xc6, 0xfb, 0x2f, 0x89, 0xc3, 0xea, 0xc6, 0x7f, 0xec, 0x25, 0xcd, 0xfe, 0x75, 0xaa, 0x7b, 0xd5, 0x70, 0xa6, 0x48, 0xe8, 0xc8, 0x94, 0x5f, 0xf2, 0xec, 0x28, 0xf, 0x6d, 0xcf, 0x73, 0x38, 0x61, 0x9, 0x15, 0x5c, 0x5b, 0xbc, 0x44, 0x4c, 0x70, 0x7b, 0xb4, 0x2e, 0xab, 0x87, 0x3f, 0x5f, 0x74, 0x76, 0x65, 0x7b, 0x1b, 0xc1, 0xa8}}, - testcase{ - msg: []byte{0x9f, 0x2f, 0xcc, 0x7c, 0x90, 0xde, 0x9, 0xd, 0x6b, 0x87, 0xcd, 0x7e, 0x97, 0x18, 0xc1, 0xea, 0x6c, 0xb2, 0x11, 0x18, 0xfc, 0x2d, 0x5d, 0xe9, 0xf9, 0x7e, 0x5d, 0xb6, 0xac, 0x1e, 0x9c, 0x10}, - output224: []byte{0xa2, 0x7a, 0x5, 0x1a, 0x36, 0xa1, 0x50, 0x19, 0x74, 0xad, 0x8e, 0x98, 0x73, 0xe9, 0xdf, 0x23, 0x1a, 0xa9, 0xad, 0x90, 0xec, 0x1d, 0x7a, 0x8b, 0xbf, 0x8f, 0x63, 0x9a}, - output256: []byte{0x24, 0xdd, 0x2e, 0xe0, 0x24, 0x82, 0x14, 0x4f, 0x53, 0x9f, 0x81, 0xd, 0x2c, 0xaa, 0x8a, 0x7b, 0x75, 0xd0, 0xfa, 0x33, 0x65, 0x7e, 0x47, 0x93, 0x21, 0x22, 0xd2, 0x73, 0xc3, 0xf6, 0xf6, 0xd1}, - output384: []byte{0x64, 0xd1, 0x1a, 0xdc, 0x77, 0xaf, 0x5c, 0x56, 0x8f, 0x37, 0xe4, 0x4e, 0xfa, 0xc5, 0xfd, 0x3, 0xc4, 0x60, 0x39, 0x1a, 0xa8, 0x33, 0xab, 0xec, 0x4e, 0x46, 0x42, 0x37, 0xa8, 0x93, 0x7e, 0xed, 0xd2, 0x3e, 0xc5, 0x13, 0xdd, 0x2a, 0x71, 0xd0, 0x32, 0x9b, 0xea, 0xa8, 0xbe, 0xf3, 0x95, 0xc9}, - output512: []byte{0x1e, 0xaf, 0xed, 0xce, 0x72, 0x92, 0xba, 0x73, 0xb8, 0xa, 0xe6, 0x15, 0x17, 0x45, 0xf4, 0x3a, 0xc9, 0x5b, 0xfc, 0x9f, 0x31, 0x69, 0x4d, 0x42, 0x24, 0x73, 0xab, 0xca, 0x2e, 0x69, 0xd6, 0x95, 0xcb, 0x65, 0x44, 0xdb, 0x65, 0x50, 0x60, 0x78, 0xcb, 0x20, 0xdb, 0xe0, 0x76, 0x2f, 0x84, 0xaa, 0x6a, 0xfd, 0x14, 0xa6, 0xa, 0xb5, 0x97, 0x95, 0x5b, 0xe7, 0x3f, 0x3f, 0x5c, 0x50, 0xf7, 0xa8}}, - testcase{ - msg: []byte{0xde, 0x8f, 0x1b, 0x3f, 0xaa, 0x4b, 0x70, 0x40, 0xed, 0x45, 0x63, 0xc3, 0xb8, 0xe5, 0x98, 0x25, 0x31, 0x78, 0xe8, 0x7e, 0x4d, 0xd, 0xf7, 0x5e, 0x4f, 0xf2, 0xf2, 0xde, 0xdd, 0x5a, 0xb, 0xe0, 0x46}, - output224: []byte{0xf2, 0x17, 0x81, 0x2e, 0x36, 0x2e, 0xc6, 0x4d, 0x4d, 0xc5, 0xea, 0xcf, 0xab, 0xc1, 0x65, 0x18, 0x4b, 0xfa, 0x45, 0x6e, 0x5c, 0x32, 0xc2, 0xc7, 0x90, 0x2, 0x53, 0xd0}, - output256: []byte{0xe7, 0x8c, 0x42, 0x1e, 0x62, 0x13, 0xaf, 0xf8, 0xde, 0x1f, 0x2, 0x57, 0x59, 0xa4, 0xf2, 0xc9, 0x43, 0xdb, 0x62, 0xbb, 0xde, 0x35, 0x9c, 0x87, 0x37, 0xe1, 0x9b, 0x37, 0x76, 0xed, 0x2d, 0xd2}, - output384: []byte{0xcf, 0x38, 0x76, 0x49, 0x73, 0xf1, 0xec, 0x1c, 0x34, 0xb5, 0x43, 0x3a, 0xe7, 0x5a, 0x3a, 0xad, 0x1a, 0xae, 0xf6, 0xab, 0x19, 0x78, 0x50, 0xc5, 0x6c, 0x86, 0x17, 0xbc, 0xd6, 0xa8, 0x82, 0xf6, 0x66, 0x68, 0x83, 0xac, 0x17, 0xb2, 0xdc, 0xcd, 0xba, 0xa6, 0x47, 0x7, 0x5d, 0x9, 0x72, 0xb5}, - output512: []byte{0x9a, 0x76, 0x88, 0xe3, 0x1a, 0xaf, 0x40, 0xc1, 0x55, 0x75, 0xfc, 0x58, 0xc6, 0xb3, 0x92, 0x67, 0xaa, 0xd3, 0x72, 0x2e, 0x69, 0x6e, 0x51, 0x8a, 0x99, 0x45, 0xcf, 0x7f, 0x7c, 0xf, 0xea, 0x84, 0xcb, 0x3c, 0xb2, 0xe9, 0xf0, 0x38, 0x4a, 0x6b, 0x5d, 0xc6, 0x71, 0xad, 0xe7, 0xfb, 0x4d, 0x2b, 0x27, 0x1, 0x11, 0x73, 0xf3, 0xee, 0xea, 0xf1, 0x7c, 0xb4, 0x51, 0xcf, 0x26, 0x54, 0x20, 0x31}}, - testcase{ - msg: []byte{0x62, 0xf1, 0x54, 0xec, 0x39, 0x4d, 0xb, 0xc7, 0x57, 0xd0, 0x45, 0xc7, 0x98, 0xc8, 0xb8, 0x7a, 0x0, 0xe0, 0x65, 0x5d, 0x4, 0x81, 0xa7, 0xd2, 0xd9, 0xfb, 0x58, 0xd9, 0x3a, 0xed, 0xc6, 0x76, 0xb5, 0xa0}, - output224: []byte{0x5c, 0xa9, 0x2b, 0x5f, 0x58, 0x30, 0xe1, 0xe5, 0xf8, 0xdf, 0x43, 0x91, 0x33, 0x9d, 0xf7, 0xdf, 0x1f, 0x23, 0xbb, 0x31, 0xaa, 0x5, 0x43, 0x7c, 0x10, 0x3f, 0x16, 0x52}, - output256: []byte{0xcc, 0xe3, 0xe3, 0xd4, 0x98, 0x32, 0x8a, 0x4d, 0x9c, 0x5b, 0x4d, 0xbf, 0x9a, 0x12, 0x9, 0x62, 0x8a, 0xb8, 0x26, 0x21, 0xad, 0x1a, 0xd, 0xa, 0x18, 0x68, 0x3, 0x62, 0x88, 0x9e, 0x61, 0x64}, - output384: []byte{0x88, 0x2b, 0xff, 0x90, 0x4b, 0xff, 0x10, 0x31, 0x13, 0x95, 0x3, 0xbf, 0x6e, 0x2, 0x74, 0xc7, 0xa3, 0x92, 0x8c, 0x2d, 0x73, 0xbf, 0x47, 0x4a, 0x65, 0xb9, 0x7c, 0x22, 0xf6, 0x5f, 0x32, 0xbe, 0x26, 0xad, 0x1c, 0x5f, 0x7e, 0x4f, 0xa3, 0x5d, 0x5b, 0x62, 0x53, 0xaa, 0x40, 0x76, 0x36, 0x1a}, - output512: []byte{0xad, 0xa5, 0xca, 0x56, 0x30, 0x66, 0x0, 0x3, 0xc4, 0xd1, 0x61, 0x49, 0xf2, 0x35, 0xfa, 0xeb, 0x78, 0x13, 0x2f, 0x7f, 0x77, 0x3a, 0x63, 0x1f, 0x82, 0xc, 0xc5, 0xc6, 0x54, 0xb0, 0x8e, 0xab, 0x42, 0x6, 0xbb, 0x4e, 0xa1, 0x38, 0x9d, 0x1c, 0xf7, 0x4d, 0x3b, 0x60, 0xb8, 0x6e, 0x48, 0x4c, 0x90, 0xc8, 0x17, 0xcd, 0xb5, 0xdd, 0x5d, 0xbf, 0x32, 0x71, 0x63, 0xb4, 0x64, 0x6f, 0x72, 0x13}}, - testcase{ - msg: []byte{0xb2, 0xdc, 0xfe, 0x9f, 0xf1, 0x9e, 0x2b, 0x23, 0xce, 0x7d, 0xa2, 0xa4, 0x20, 0x7d, 0x3e, 0x5e, 0xc7, 0xc6, 0x11, 0x2a, 0x8a, 0x22, 0xae, 0xc9, 0x67, 0x5a, 0x88, 0x63, 0x78, 0xe1, 0x4e, 0x5b, 0xfb, 0xad, 0x4e}, - output224: []byte{0x9f, 0x1, 0xf0, 0x7d, 0x93, 0xf, 0x40, 0xa2, 0x64, 0x7, 0x76, 0x1, 0x4, 0xef, 0xd1, 0xd, 0x44, 0x36, 0x29, 0x5f, 0x6b, 0x8c, 0x41, 0xfe, 0x2a, 0x4e, 0x9, 0xea}, - output256: []byte{0xf8, 0x71, 0xdb, 0x93, 0xc5, 0xc9, 0x2e, 0xcd, 0x65, 0xd4, 0xed, 0xb9, 0x6f, 0xcb, 0x12, 0xe4, 0x72, 0x9b, 0xc2, 0xa1, 0x89, 0x9f, 0x7f, 0xb0, 0x29, 0xf5, 0xb, 0xff, 0x43, 0x1c, 0xbb, 0x72}, - output384: []byte{0x80, 0x44, 0x8b, 0x7a, 0x76, 0xe0, 0xf0, 0x66, 0x60, 0x48, 0xc0, 0x21, 0x65, 0xa4, 0xfa, 0x8d, 0xfd, 0x25, 0xa, 0x22, 0x7c, 0xcd, 0xd4, 0x47, 0x1c, 0x37, 0x3, 0xd0, 0x77, 0x62, 0x36, 0x2d, 0xc1, 0xdf, 0x55, 0xfe, 0xc2, 0x9e, 0x2a, 0x31, 0xfe, 0x70, 0x95, 0x83, 0x74, 0x27, 0x1d, 0xd7}, - output512: []byte{0x71, 0xa0, 0x80, 0x1d, 0x32, 0x58, 0x79, 0x80, 0xb0, 0x99, 0x63, 0xa0, 0xf5, 0x47, 0xb8, 0xb6, 0xee, 0x3b, 0xad, 0xe2, 0x24, 0x67, 0x1b, 0xf4, 0x4f, 0x12, 0xe3, 0xda, 0x4f, 0x21, 0x77, 0x8b, 0xac, 0x37, 0xfc, 0xc7, 0x3e, 0xf4, 0x5f, 0xee, 0x1c, 0x96, 0x68, 0x8b, 0xaf, 0x90, 0x20, 0xf4, 0x87, 0xb1, 0xa1, 0x6e, 0x3a, 0xc9, 0x1b, 0x50, 0x48, 0x45, 0xd6, 0xfb, 0xa8, 0x79, 0x13, 0x4f}}, - testcase{ - msg: []byte{0x47, 0xf5, 0x69, 0x7a, 0xc8, 0xc3, 0x14, 0x9, 0xc0, 0x86, 0x88, 0x27, 0x34, 0x7a, 0x61, 0x3a, 0x35, 0x62, 0x4, 0x1c, 0x63, 0x3c, 0xf1, 0xf1, 0xf8, 0x68, 0x65, 0xa5, 0x76, 0xe0, 0x28, 0x35, 0xed, 0x2c, 0x24, 0x92}, - output224: []byte{0x22, 0xa3, 0xfe, 0xd1, 0xf4, 0xe2, 0x98, 0xc3, 0x7a, 0x1d, 0x7b, 0xa0, 0xc8, 0xe, 0x99, 0x4b, 0x11, 0xd9, 0x5f, 0x29, 0xf, 0x39, 0x45, 0xa3, 0xce, 0xb2, 0xe2, 0xe6}, - output256: []byte{0x4e, 0xb1, 0x43, 0x47, 0x74, 0x31, 0xdf, 0x1, 0x93, 0x11, 0xae, 0xd9, 0x36, 0xca, 0xb9, 0x1a, 0x91, 0x2e, 0xc1, 0xe6, 0x86, 0x8b, 0x71, 0xe9, 0xed, 0xdb, 0x77, 0x74, 0x8, 0xd4, 0xaf, 0x34}, - output384: []byte{0x62, 0x68, 0xcd, 0x6b, 0x41, 0xf4, 0xc5, 0x12, 0x3e, 0xc4, 0xd5, 0x4d, 0x1e, 0x69, 0x43, 0xab, 0xb3, 0x2d, 0xbe, 0x7b, 0xff, 0xb8, 0xeb, 0x95, 0xe4, 0xfc, 0xee, 0x5c, 0x12, 0xd4, 0x64, 0x7b, 0xe1, 0x43, 0xc2, 0x7f, 0x12, 0x81, 0xcd, 0xd2, 0x75, 0x90, 0x49, 0x20, 0x44, 0x15, 0x8, 0xda}, - output512: []byte{0xeb, 0xa6, 0x78, 0xb7, 0xa0, 0xe5, 0x66, 0x9d, 0xc7, 0xfa, 0x5e, 0xca, 0x5d, 0x5f, 0x19, 0xfe, 0x62, 0x5e, 0x11, 0x3e, 0x50, 0x28, 0xda, 0x5e, 0xfb, 0x13, 0x89, 0x23, 0xcd, 0x44, 0x47, 0x57, 0xb0, 0x60, 0x78, 0xe0, 0xba, 0x6, 0x4b, 0x36, 0xc7, 0x2c, 0xa2, 0x18, 0x7a, 0xb9, 0xdd, 0x31, 0xdd, 0xa6, 0xf2, 0x46, 0x68, 0xf4, 0x6c, 0x32, 0xf8, 0xec, 0x21, 0xac, 0x59, 0xaa, 0xfa, 0x24}}, - testcase{ - msg: []byte{0x51, 0x2a, 0x6d, 0x29, 0x2e, 0x67, 0xec, 0xb2, 0xfe, 0x48, 0x6b, 0xfe, 0x92, 0x66, 0x9, 0x53, 0xa7, 0x54, 0x84, 0xff, 0x4c, 0x4f, 0x2e, 0xca, 0x2b, 0xa, 0xf0, 0xed, 0xcd, 0xd4, 0x33, 0x9c, 0x6b, 0x2e, 0xe4, 0xe5, 0x42}, - output224: []byte{0x35, 0xf1, 0xab, 0x12, 0x63, 0x21, 0x1f, 0x73, 0x8d, 0x3f, 0x97, 0xd0, 0xe4, 0x84, 0xc, 0x38, 0x7e, 0x9, 0x36, 0x9f, 0x23, 0xbf, 0x92, 0x39, 0x15, 0xd, 0x3, 0x6}, - output256: []byte{0x9a, 0xc, 0x1d, 0x50, 0xa5, 0x9d, 0xbf, 0x65, 0x7f, 0x67, 0x13, 0xc7, 0x95, 0xed, 0x14, 0xe1, 0xf2, 0x3b, 0x4e, 0xaa, 0x13, 0x7c, 0x55, 0x40, 0xaa, 0xcd, 0xb0, 0xa7, 0xe3, 0x2c, 0x29, 0xfc}, - output384: []byte{0xc7, 0x3d, 0x18, 0xde, 0x7, 0xa6, 0x5a, 0xcc, 0x7e, 0x2d, 0x8b, 0x2a, 0x51, 0x0, 0x2a, 0xe2, 0x8c, 0xbc, 0x4b, 0xa, 0x6e, 0xe7, 0xf8, 0x1a, 0x6b, 0x48, 0x3f, 0x81, 0xa6, 0xdf, 0x8f, 0xf6, 0xb3, 0x3f, 0x63, 0x2a, 0x6e, 0x63, 0x12, 0x88, 0x8c, 0xa7, 0x14, 0x82, 0x1c, 0xb, 0x13, 0xdf}, - output512: []byte{0x12, 0xdf, 0x92, 0xd8, 0x89, 0xd7, 0xba, 0xd, 0xf0, 0x5b, 0xcd, 0x2, 0xd9, 0xde, 0x58, 0xc9, 0x7f, 0x48, 0x13, 0x12, 0x69, 0x67, 0xff, 0x78, 0xbd, 0xf7, 0x59, 0xc6, 0x6c, 0x4c, 0xbe, 0x9d, 0xf6, 0x8a, 0xb3, 0x1a, 0x2, 0x56, 0xc7, 0x76, 0x73, 0xb, 0xb2, 0x5d, 0xee, 0xcf, 0x91, 0xf0, 0x99, 0x78, 0x68, 0xac, 0x8b, 0xb8, 0x6d, 0xf7, 0xa0, 0xfc, 0x11, 0xc, 0xb0, 0xa4, 0xde, 0x5d}}, - testcase{ - msg: []byte{0x97, 0x3c, 0xf2, 0xb4, 0xdc, 0xf0, 0xbf, 0xa8, 0x72, 0xb4, 0x11, 0x94, 0xcb, 0x5, 0xbb, 0x4e, 0x16, 0x76, 0xa, 0x18, 0x40, 0xd8, 0x34, 0x33, 0x1, 0x80, 0x25, 0x76, 0x19, 0x7e, 0xc1, 0x9e, 0x2a, 0x14, 0x93, 0xd8, 0xf4, 0xfb}, - output224: []byte{0x34, 0xcc, 0x70, 0x8b, 0x87, 0x4d, 0x40, 0x47, 0x8e, 0x82, 0x32, 0x4b, 0xf3, 0xaa, 0x32, 0xfe, 0x9f, 0x85, 0xaf, 0xf8, 0xc6, 0xb, 0x4b, 0xad, 0xf9, 0x70, 0x3, 0xe3}, - output256: []byte{0xba, 0x6, 0x2e, 0x5d, 0x37, 0x2, 0x16, 0xd1, 0x19, 0x85, 0xc4, 0xca, 0x7a, 0x26, 0x58, 0xdd, 0xc7, 0x32, 0x8b, 0x4b, 0xe4, 0xb4, 0xa, 0x52, 0xdd, 0x8f, 0xa3, 0xca, 0x66, 0x2f, 0x9, 0xd1}, - output384: []byte{0x3a, 0xb, 0xea, 0x62, 0xf4, 0x2f, 0x9c, 0xee, 0xdb, 0x34, 0x8f, 0x6e, 0x16, 0x13, 0xf0, 0x3, 0x56, 0xed, 0x97, 0x66, 0xa5, 0xc1, 0x9f, 0xc, 0x2e, 0xeb, 0x5, 0xc7, 0x4d, 0xe6, 0x9d, 0x39, 0x43, 0xe1, 0x6c, 0xf7, 0x22, 0x81, 0xfd, 0xd9, 0x27, 0x15, 0xfa, 0x3d, 0x51, 0x51, 0x59, 0x31}, - output512: []byte{0xb8, 0xc7, 0xce, 0x2b, 0xe4, 0xcb, 0x32, 0xc1, 0x40, 0xe7, 0x5b, 0x75, 0x47, 0x42, 0x48, 0xc1, 0xdd, 0x77, 0xd1, 0x9b, 0xc, 0xbc, 0xa3, 0x1a, 0x3e, 0xcc, 0x2a, 0x35, 0xc5, 0x32, 0xe4, 0xfa, 0x3e, 0xd4, 0xab, 0xbc, 0xda, 0x27, 0xaa, 0x68, 0xa9, 0xdd, 0xa0, 0x6b, 0x24, 0x54, 0x43, 0xe5, 0x90, 0x3a, 0x65, 0x65, 0x2a, 0x94, 0xed, 0x3a, 0xf1, 0x50, 0x65, 0xd3, 0xe7, 0x73, 0x6e, 0x47}}, - testcase{ - msg: []byte{0x80, 0xbe, 0xeb, 0xcd, 0x2e, 0x3f, 0x8a, 0x94, 0x51, 0xd4, 0x49, 0x99, 0x61, 0xc9, 0x73, 0x1a, 0xe6, 0x67, 0xcd, 0xc2, 0x4e, 0xa0, 0x20, 0xce, 0x3b, 0x9a, 0xa4, 0xbb, 0xc0, 0xa7, 0xf7, 0x9e, 0x30, 0xa9, 0x34, 0x46, 0x7d, 0xa4, 0xb0}, - output224: []byte{0x5f, 0x33, 0x9b, 0x2f, 0x87, 0xe7, 0xf6, 0x95, 0xb2, 0x36, 0x26, 0x7c, 0x81, 0x9b, 0xa1, 0x70, 0x5d, 0x97, 0x64, 0x4a, 0xd7, 0x2e, 0x8, 0x71, 0xc7, 0xe3, 0xa9, 0x13}, - output256: []byte{0x3a, 0x8, 0x3a, 0xe1, 0x63, 0xdf, 0x42, 0xbd, 0x51, 0xb9, 0xc6, 0x64, 0xbe, 0xe9, 0xdc, 0x43, 0x62, 0xf1, 0x6e, 0x63, 0x38, 0x3d, 0xf1, 0x64, 0x73, 0xdf, 0x71, 0xbe, 0x6d, 0xd4, 0xc, 0x1c}, - output384: []byte{0x10, 0x92, 0xf6, 0x39, 0x55, 0xf3, 0xdf, 0xef, 0x13, 0x22, 0xcf, 0x95, 0x16, 0xf2, 0x15, 0x40, 0x21, 0x55, 0x52, 0xbc, 0x57, 0x9, 0xcc, 0xda, 0x17, 0xad, 0x27, 0x6e, 0xca, 0xa0, 0x91, 0xa7, 0x84, 0x51, 0xfe, 0x99, 0x25, 0x79, 0x1b, 0x8a, 0x91, 0x91, 0xb5, 0xd4, 0x20, 0x10, 0x15, 0x6f}, - output512: []byte{0xa0, 0xae, 0x9d, 0xfb, 0x56, 0x83, 0x1f, 0xe4, 0xa3, 0x22, 0x3c, 0x50, 0x1b, 0x69, 0x7b, 0xd8, 0x24, 0x3c, 0x47, 0x1e, 0x83, 0x43, 0xac, 0xfd, 0x37, 0xa6, 0xb5, 0x87, 0xfe, 0xac, 0x74, 0x57, 0x1c, 0x23, 0xde, 0xeb, 0xc9, 0xb9, 0x4a, 0x54, 0xa, 0x2, 0xf1, 0xb1, 0xe2, 0x25, 0x1e, 0x1, 0x22, 0x9c, 0x9d, 0x58, 0xc4, 0x27, 0x9f, 0x15, 0x5d, 0x55, 0x66, 0xfb, 0x18, 0xe8, 0x12, 0x95}}, - testcase{ - msg: []byte{0x7a, 0xba, 0xa1, 0x2e, 0xc2, 0xa7, 0x34, 0x76, 0x74, 0xe4, 0x44, 0x14, 0xa, 0xe0, 0xfb, 0x65, 0x9d, 0x8, 0xe1, 0xc6, 0x6d, 0xec, 0xd8, 0xd6, 0xea, 0xe9, 0x25, 0xfa, 0x45, 0x1d, 0x65, 0xf3, 0xc0, 0x30, 0x8e, 0x29, 0x44, 0x6b, 0x8e, 0xd3}, - output224: []byte{0x8e, 0x20, 0xd5, 0xc8, 0x3c, 0xda, 0x82, 0x26, 0xb5, 0x8c, 0xef, 0xd7, 0x4c, 0x29, 0x3c, 0xa7, 0x57, 0x9c, 0xbb, 0x39, 0x49, 0xca, 0x9e, 0xb2, 0xf6, 0x15, 0x65, 0xb8}, - output256: []byte{0x48, 0x76, 0xe2, 0x73, 0xac, 0x0, 0x94, 0x25, 0x76, 0xd9, 0x60, 0x8d, 0x5b, 0x63, 0xec, 0xc9, 0xa3, 0xe7, 0x5d, 0x5e, 0xc, 0x42, 0xc6, 0xab, 0xdb, 0xcd, 0xe0, 0x37, 0x78, 0x5a, 0xf9, 0xa7}, - output384: []byte{0x8c, 0xd0, 0x22, 0x97, 0x1d, 0x57, 0x69, 0x76, 0x1b, 0x8e, 0x96, 0xb4, 0x42, 0x44, 0x4f, 0xa1, 0x85, 0xf, 0x12, 0x1, 0xaa, 0xb0, 0xac, 0x9f, 0x6e, 0x84, 0x4, 0xe2, 0xb3, 0xea, 0x1d, 0x93, 0x62, 0x44, 0xee, 0xdc, 0x79, 0x57, 0xc8, 0xb, 0x7f, 0xae, 0x60, 0xb3, 0xf2, 0x16, 0xc6, 0xa0}, - output512: []byte{0x63, 0x1e, 0x78, 0x47, 0x12, 0x4a, 0x70, 0xfe, 0x6e, 0xb2, 0x93, 0xa4, 0x4a, 0x25, 0xc5, 0x6, 0x0, 0xb5, 0xe7, 0xe9, 0x75, 0xca, 0x9f, 0xab, 0x5a, 0xe6, 0x4a, 0xb8, 0x6c, 0x7e, 0x42, 0xc9, 0x12, 0xdd, 0x6e, 0xc0, 0x93, 0xf0, 0x1a, 0x8d, 0xeb, 0xc6, 0xe1, 0xf5, 0xe4, 0x87, 0xaf, 0x97, 0xdc, 0x3f, 0xd6, 0xc5, 0x30, 0x2, 0x76, 0x50, 0x50, 0xbe, 0x96, 0x3f, 0xfc, 0xd4, 0xd9, 0x89}}, - testcase{ - msg: []byte{0xc8, 0x8d, 0xee, 0x99, 0x27, 0x67, 0x9b, 0x8a, 0xf4, 0x22, 0xab, 0xcb, 0xac, 0xf2, 0x83, 0xb9, 0x4, 0xff, 0x31, 0xe1, 0xca, 0xc5, 0x8c, 0x78, 0x19, 0x80, 0x9f, 0x65, 0xd5, 0x80, 0x7d, 0x46, 0x72, 0x3b, 0x20, 0xf6, 0x7b, 0xa6, 0x10, 0xc2, 0xb7}, - output224: []byte{0x60, 0x62, 0x55, 0x34, 0x88, 0x12, 0xcf, 0xb5, 0x8, 0x2f, 0x4d, 0x4b, 0xb6, 0xbb, 0xc2, 0xfe, 0xef, 0x4, 0x4e, 0x38, 0x1f, 0xeb, 0xe, 0x34, 0x60, 0x61, 0xaa, 0x4f}, - output256: []byte{0x47, 0x97, 0xba, 0x1c, 0x7a, 0xb7, 0x19, 0x70, 0x50, 0xd6, 0xb2, 0xe5, 0x6, 0xf2, 0xdf, 0x45, 0x50, 0xe4, 0xb6, 0x73, 0xdf, 0x78, 0xf1, 0x8c, 0x46, 0x54, 0x24, 0xe4, 0x8d, 0xf5, 0xe9, 0x97}, - output384: []byte{0xb6, 0x57, 0x5d, 0x53, 0xd3, 0x53, 0x36, 0x5, 0x21, 0xb2, 0xa, 0xa1, 0xf9, 0x93, 0xf6, 0xe2, 0xb5, 0xa2, 0x62, 0xd1, 0xf5, 0x8, 0x78, 0x9d, 0x5c, 0xe2, 0x46, 0x9e, 0x9f, 0x3f, 0x33, 0xcc, 0xe8, 0x84, 0x8d, 0xf6, 0x90, 0xcc, 0xb0, 0xd6, 0x76, 0xfb, 0x94, 0x9e, 0xb1, 0x71, 0xa7, 0xd7}, - output512: []byte{0xb9, 0x89, 0x26, 0x3b, 0xb4, 0xe0, 0x42, 0x4f, 0x95, 0xfd, 0xc9, 0xa4, 0x9c, 0x83, 0xa3, 0x76, 0x9f, 0xbf, 0x31, 0xdc, 0xed, 0xda, 0x7e, 0x0, 0x5a, 0xb5, 0xf2, 0x2f, 0x43, 0xd2, 0x71, 0x8d, 0xeb, 0xd3, 0x90, 0x85, 0x97, 0x1f, 0x7e, 0xb7, 0x82, 0x2c, 0x9f, 0xa0, 0xf6, 0x7f, 0x77, 0x6c, 0xec, 0x4e, 0x35, 0xa9, 0xa8, 0xb8, 0xc8, 0x35, 0xef, 0x4e, 0x9e, 0xbd, 0xa1, 0x92, 0x2e, 0x4d}}, - testcase{ - msg: []byte{0x1, 0xe4, 0x3f, 0xe3, 0x50, 0xfc, 0xec, 0x45, 0xe, 0xc9, 0xb1, 0x2, 0x5, 0x3e, 0x6b, 0x5d, 0x56, 0xe0, 0x98, 0x96, 0xe0, 0xdd, 0xd9, 0x7, 0x4f, 0xe1, 0x38, 0xe6, 0x3, 0x82, 0x10, 0x27, 0xc, 0x83, 0x4c, 0xe6, 0xea, 0xdc, 0x2b, 0xb8, 0x6b, 0xf6}, - output224: []byte{0xc8, 0x85, 0x27, 0x4c, 0xc3, 0xbf, 0x11, 0x9, 0x95, 0xfe, 0xf1, 0x15, 0x4a, 0x86, 0x77, 0x2f, 0x28, 0xb4, 0x1e, 0x74, 0x5e, 0x86, 0xe9, 0x35, 0xb4, 0xe3, 0xa0, 0x3f}, - output256: []byte{0x41, 0xc9, 0x1b, 0xe9, 0x8c, 0x58, 0x13, 0xa4, 0xc5, 0xd8, 0xae, 0x7c, 0x29, 0xb9, 0x91, 0x9c, 0x1c, 0xc9, 0x5b, 0x4a, 0x5, 0xf8, 0x24, 0x33, 0x94, 0x8c, 0xb9, 0x9d, 0x9a, 0x6d, 0x3, 0x9c}, - output384: []byte{0x73, 0x58, 0xc6, 0xa0, 0xae, 0x58, 0xef, 0xa1, 0x4f, 0x65, 0xb8, 0xe1, 0x62, 0xf0, 0x7e, 0xf2, 0xd0, 0xad, 0x8d, 0xd2, 0x0, 0x6a, 0x98, 0x29, 0x33, 0x7, 0xb7, 0x6b, 0x3b, 0xa9, 0xe7, 0x1c, 0x30, 0x8a, 0x66, 0x94, 0xf0, 0xb5, 0x6d, 0xe8, 0xd5, 0x9e, 0x58, 0x53, 0x6c, 0x35, 0x13, 0xe8}, - output512: []byte{0xff, 0x6a, 0xdc, 0xb9, 0xe1, 0x54, 0x67, 0x98, 0xd3, 0x96, 0xdb, 0x78, 0x45, 0x2d, 0xf1, 0xa3, 0x75, 0xb6, 0x5e, 0xe3, 0xd5, 0x4f, 0xcc, 0x91, 0x5a, 0x8c, 0xa3, 0xda, 0x69, 0x3e, 0x24, 0x93, 0x19, 0x99, 0xb0, 0xfc, 0x8a, 0x4e, 0xb9, 0x2f, 0x6f, 0xf8, 0x5e, 0x42, 0xbb, 0x4c, 0xfd, 0x9c, 0xe7, 0xd7, 0x86, 0x3e, 0xee, 0x70, 0x9c, 0x9e, 0xf3, 0x76, 0x42, 0xb6, 0x96, 0x17, 0x44, 0x74}}, - testcase{ - msg: []byte{0x33, 0x70, 0x23, 0x37, 0xa, 0x48, 0xb6, 0x2e, 0xe4, 0x35, 0x46, 0xf1, 0x7c, 0x4e, 0xf2, 0xbf, 0x8d, 0x7e, 0xcd, 0x1d, 0x49, 0xf9, 0xb, 0xab, 0x60, 0x4b, 0x83, 0x9c, 0x2e, 0x6e, 0x5b, 0xd2, 0x15, 0x40, 0xd2, 0x9b, 0xa2, 0x7a, 0xb8, 0xe3, 0x9, 0xa4, 0xb7}, - output224: []byte{0xef, 0xa7, 0xf7, 0xe7, 0xbf, 0xfa, 0x6a, 0x5e, 0x7f, 0x7d, 0x1c, 0x24, 0xe7, 0xa0, 0xa9, 0xdc, 0x9a, 0x6f, 0x72, 0xb3, 0xe9, 0x55, 0xa, 0xa, 0xaa, 0x6, 0xcc, 0xe6}, - output256: []byte{0xee, 0x35, 0x42, 0x90, 0xe3, 0xf9, 0xce, 0x91, 0x23, 0xc4, 0x9b, 0xa6, 0x16, 0xe1, 0xa2, 0x68, 0x4a, 0x90, 0xf3, 0xdd, 0xd8, 0x4e, 0x73, 0xa1, 0xd2, 0xc2, 0x32, 0xf7, 0x40, 0x41, 0x2b, 0x18}, - output384: []byte{0x18, 0x3, 0xc, 0x2b, 0x5e, 0xa2, 0x3b, 0x6c, 0x66, 0xbd, 0xaf, 0x18, 0xa, 0x41, 0x17, 0x33, 0x94, 0x54, 0x2, 0x15, 0xca, 0x48, 0xfb, 0x3e, 0x75, 0x84, 0x33, 0xff, 0x98, 0x84, 0xef, 0xb9, 0xe5, 0x6d, 0x29, 0x22, 0xba, 0x53, 0x20, 0xba, 0x84, 0xbe, 0x36, 0xe6, 0xef, 0xe6, 0xb8, 0x9d}, - output512: []byte{0x10, 0x51, 0xb7, 0xff, 0x77, 0x27, 0x4b, 0x78, 0x4e, 0x7f, 0xb7, 0x82, 0x3e, 0x75, 0x6f, 0xc, 0x43, 0x55, 0x4, 0x7e, 0x48, 0x97, 0x75, 0xbb, 0xed, 0xaa, 0x7c, 0xe5, 0xa7, 0x5e, 0xfa, 0xc3, 0x31, 0x49, 0x2c, 0x1, 0x6c, 0xe0, 0x2e, 0xb2, 0xbe, 0x8b, 0xa2, 0xfe, 0x6b, 0x73, 0x5b, 0x9a, 0x14, 0x84, 0xe7, 0x3a, 0xc0, 0x6d, 0xe5, 0x73, 0xc5, 0xd0, 0xb4, 0xa5, 0x88, 0x22, 0xa3, 0x6a}}, - testcase{ - msg: []byte{0x68, 0x92, 0x54, 0xf, 0x96, 0x4c, 0x8c, 0x74, 0xbd, 0x2d, 0xb0, 0x2c, 0xa, 0xd8, 0x84, 0x51, 0xc, 0xb3, 0x8a, 0xfd, 0x44, 0x38, 0xaf, 0x31, 0xfc, 0x91, 0x27, 0x56, 0xf3, 0xef, 0xec, 0x6b, 0x32, 0xb5, 0x8e, 0xbc, 0x38, 0xfc, 0x2a, 0x6b, 0x91, 0x35, 0x96, 0xa8}, - output224: []byte{0xac, 0xa7, 0xdc, 0xcc, 0x6b, 0x80, 0x9d, 0x51, 0x1f, 0x4c, 0x24, 0x8c, 0xaa, 0x5d, 0x13, 0x74, 0xe7, 0x34, 0xc1, 0xed, 0x6b, 0x99, 0x57, 0x60, 0xcc, 0x3c, 0x56, 0xd2}, - output256: []byte{0xfb, 0xec, 0xb, 0x6d, 0x71, 0x69, 0x6e, 0xed, 0xe9, 0x0, 0xb7, 0x7a, 0xa6, 0xd7, 0xd2, 0x5f, 0x4a, 0xb4, 0x5d, 0xf8, 0x96, 0x1c, 0xa9, 0xc8, 0xb3, 0xf4, 0xf9, 0xb5, 0x1a, 0xf9, 0x83, 0xab}, - output384: []byte{0x6f, 0x9f, 0x90, 0x16, 0xac, 0x3b, 0x6a, 0x59, 0x78, 0xa5, 0xdc, 0x8c, 0x75, 0x6, 0xc8, 0xb4, 0xd2, 0x87, 0x42, 0x25, 0x3b, 0xc5, 0x42, 0xe7, 0x9d, 0x95, 0x82, 0x44, 0x17, 0xaa, 0x54, 0x29, 0x91, 0xee, 0xf7, 0xe2, 0xb9, 0xc5, 0x8c, 0xdb, 0xc, 0x93, 0x61, 0x6a, 0xe9, 0xc1, 0xf8, 0x8f}, - output512: []byte{0x56, 0x39, 0xa2, 0x82, 0x42, 0x97, 0xca, 0x9, 0x9e, 0xcf, 0x2a, 0x81, 0xee, 0xf1, 0x75, 0x3f, 0x63, 0x14, 0xcb, 0x66, 0x3d, 0x86, 0xf, 0x5, 0xa3, 0x9e, 0x3e, 0x80, 0x1f, 0xf8, 0x20, 0x60, 0xbb, 0xa1, 0x6, 0x28, 0xe2, 0xc0, 0xd9, 0xe0, 0xa8, 0x4d, 0xd0, 0x5e, 0xd6, 0x37, 0xfc, 0xb, 0x65, 0xba, 0x3, 0xbb, 0x66, 0xe4, 0x6f, 0xb2, 0x56, 0xf2, 0xa5, 0xb2, 0x8d, 0x3f, 0x41, 0xd2}}, - testcase{ - msg: []byte{0xf5, 0x96, 0x1d, 0xfd, 0x2b, 0x1f, 0xff, 0xfd, 0xa4, 0xff, 0xbf, 0x30, 0x56, 0xc, 0x16, 0x5b, 0xfe, 0xda, 0xb8, 0xce, 0xb, 0xe5, 0x25, 0x84, 0x5d, 0xeb, 0x8d, 0xc6, 0x10, 0x4, 0xb7, 0xdb, 0x38, 0x46, 0x72, 0x5, 0xf5, 0xdc, 0xfb, 0x34, 0xa2, 0xac, 0xfe, 0x96, 0xc0}, - output224: []byte{0x6f, 0x1e, 0xf5, 0x5c, 0xcc, 0x6e, 0xf9, 0xb6, 0x8d, 0xe5, 0x4c, 0x14, 0x44, 0x84, 0x87, 0x90, 0x10, 0x22, 0x45, 0x2a, 0xb7, 0x61, 0xf8, 0x46, 0x44, 0xe9, 0xa1, 0x27}, - output256: []byte{0x9d, 0x24, 0xae, 0xea, 0x8, 0xf9, 0xa4, 0xb5, 0xfb, 0x8b, 0x6d, 0xe8, 0x5a, 0x22, 0x96, 0xf5, 0xf4, 0x10, 0x8d, 0xdd, 0x1e, 0xea, 0x4f, 0x8e, 0xe5, 0x88, 0x19, 0xcf, 0x84, 0xed, 0xb7, 0x65}, - output384: []byte{0x42, 0x44, 0x21, 0xbb, 0x93, 0x99, 0xbd, 0x44, 0xab, 0x76, 0x50, 0x2, 0x73, 0xd7, 0xf1, 0xe1, 0x42, 0x1a, 0x2b, 0xfd, 0xe1, 0xa1, 0xc1, 0x30, 0xc0, 0xb3, 0x47, 0x44, 0x9, 0xd8, 0xae, 0x92, 0xb3, 0xe3, 0x85, 0x39, 0xcf, 0xb0, 0x9e, 0xd1, 0xd2, 0x3c, 0x62, 0xbb, 0x32, 0xb9, 0x36, 0x4b}, - output512: []byte{0x97, 0xf9, 0xd6, 0x42, 0x50, 0x7e, 0x6d, 0xd1, 0x79, 0xd5, 0x6f, 0x4b, 0x81, 0x5e, 0x92, 0xd0, 0xd4, 0x86, 0x82, 0x6f, 0x27, 0x3e, 0xc7, 0x11, 0xb8, 0xf9, 0xcb, 0x76, 0xaf, 0xc7, 0x9f, 0x90, 0x8, 0x16, 0xfd, 0xbc, 0x13, 0xdd, 0x3a, 0x59, 0xfb, 0xec, 0xba, 0x1f, 0x3b, 0x69, 0x53, 0xf8, 0x79, 0xf2, 0x7c, 0x89, 0x87, 0xb2, 0x4c, 0x6f, 0xf8, 0x55, 0x7a, 0x2c, 0x83, 0x40, 0x76, 0xb9}}, - testcase{ - msg: []byte{0xca, 0x6, 0x1a, 0x2e, 0xb6, 0xce, 0xed, 0x88, 0x81, 0xce, 0x20, 0x57, 0x17, 0x2d, 0x86, 0x9d, 0x73, 0xa1, 0x95, 0x1e, 0x63, 0xd5, 0x72, 0x61, 0x38, 0x4b, 0x80, 0xce, 0xb5, 0x45, 0x1e, 0x77, 0xb0, 0x6c, 0xf0, 0xf5, 0xa0, 0xea, 0x15, 0xca, 0x90, 0x7e, 0xe1, 0xc2, 0x7e, 0xba}, - output224: []byte{0xb2, 0x97, 0xf6, 0x1f, 0xf0, 0x60, 0x21, 0xbf, 0xe1, 0xb9, 0xd3, 0x50, 0xb3, 0xf5, 0x4d, 0x81, 0xb, 0xc1, 0x6a, 0xde, 0x17, 0x0, 0x1b, 0xae, 0x1b, 0x4c, 0xd4, 0xa2}, - output256: []byte{0x73, 0x20, 0x34, 0xca, 0xe3, 0xff, 0x11, 0x16, 0xf0, 0x7f, 0xc1, 0x8b, 0x5a, 0x26, 0xef, 0x8f, 0xaf, 0x3f, 0xe7, 0x5d, 0x3d, 0xbc, 0xa0, 0x5e, 0x48, 0x79, 0x53, 0x65, 0xe0, 0xa1, 0x7c, 0x40}, - output384: []byte{0xd0, 0x7a, 0x2c, 0xac, 0xee, 0xa8, 0x69, 0x27, 0x4b, 0xae, 0xec, 0xda, 0x43, 0xb6, 0x2, 0x9, 0x30, 0xef, 0x38, 0x3a, 0x89, 0x7c, 0x72, 0xa7, 0xac, 0x7f, 0xbd, 0x8f, 0xf5, 0xce, 0xa7, 0xf8, 0xbe, 0x65, 0x58, 0x44, 0xd9, 0xf9, 0xbd, 0x2b, 0x49, 0x88, 0x80, 0xfa, 0x15, 0x27, 0xd9, 0x4f}, - output512: []byte{0xaf, 0xef, 0x2a, 0xf5, 0xa0, 0x1b, 0x89, 0xbe, 0x19, 0xa, 0xe, 0x6e, 0x79, 0x6a, 0xa5, 0x1f, 0x1f, 0x8c, 0x35, 0x67, 0x72, 0xc6, 0xfc, 0x77, 0x31, 0xf0, 0x8a, 0xab, 0x8b, 0xd8, 0x1a, 0xee, 0x12, 0x87, 0xc7, 0xd, 0x56, 0x4f, 0x4f, 0x16, 0x9e, 0x37, 0xb0, 0x7f, 0x28, 0x20, 0x2a, 0x85, 0xf4, 0x68, 0x28, 0x1b, 0x4c, 0xdc, 0x12, 0x73, 0xcf, 0x61, 0xeb, 0x30, 0xe3, 0xbd, 0xce, 0xe1}}, - testcase{ - msg: []byte{0x17, 0x43, 0xa7, 0x72, 0x51, 0xd6, 0x92, 0x42, 0x75, 0xc, 0x4f, 0x11, 0x40, 0x53, 0x2c, 0xd3, 0xc3, 0x3f, 0x9b, 0x5c, 0xcd, 0xf7, 0x51, 0x4e, 0x85, 0x84, 0xd4, 0xa5, 0xf9, 0xfb, 0xd7, 0x30, 0xbc, 0xf8, 0x4d, 0xd, 0x47, 0x26, 0x36, 0x4b, 0x9b, 0xf9, 0x5a, 0xb2, 0x51, 0xd9, 0xbb}, - output224: []byte{0xbe, 0x9a, 0x75, 0x43, 0x6c, 0x39, 0x88, 0xfb, 0x2f, 0xe2, 0x1d, 0xc, 0x10, 0xea, 0xd9, 0xb9, 0xc8, 0x7, 0xde, 0x2e, 0x13, 0xa9, 0xbd, 0x84, 0x37, 0xf1, 0x33, 0x32}, - output256: []byte{0xde, 0xac, 0x52, 0x18, 0x5, 0xbc, 0x6a, 0x97, 0xc0, 0x87, 0xe, 0x9e, 0x22, 0x5d, 0x1c, 0x4b, 0x2f, 0xd8, 0xf3, 0xa9, 0xa7, 0xf6, 0xb3, 0x9e, 0x35, 0x7c, 0x26, 0x41, 0x48, 0x21, 0xe2, 0xdd}, - output384: []byte{0x25, 0xd7, 0xab, 0x5e, 0x93, 0x8, 0x19, 0xcf, 0x5f, 0x59, 0xac, 0xd2, 0x54, 0x26, 0x91, 0xad, 0x66, 0x48, 0x1d, 0xa5, 0x47, 0xea, 0xa9, 0xc2, 0xad, 0xd7, 0xc8, 0xea, 0x69, 0xa4, 0x75, 0xf4, 0x16, 0xc4, 0x30, 0xea, 0x1d, 0xe8, 0x40, 0x97, 0x4e, 0x32, 0x36, 0xa6, 0x25, 0x20, 0x91, 0x1f}, - output512: []byte{0xf4, 0x67, 0xcc, 0xa6, 0x7c, 0x38, 0x7f, 0xfc, 0x9f, 0x1b, 0x17, 0x3a, 0x8, 0x4c, 0x45, 0x10, 0x95, 0xd0, 0x1a, 0xd0, 0xbf, 0x39, 0x53, 0xac, 0x10, 0x3a, 0x76, 0xf0, 0xf1, 0xbc, 0x86, 0x16, 0x73, 0x5, 0xa9, 0x26, 0xa9, 0x41, 0xa5, 0x34, 0x17, 0xf1, 0x61, 0x1a, 0x50, 0x5a, 0xaa, 0x20, 0x5b, 0xcf, 0xcc, 0xbf, 0xd3, 0x43, 0x46, 0x5d, 0xad, 0x8a, 0x6c, 0x1e, 0x80, 0x60, 0x9a, 0x9d}}, - testcase{ - msg: []byte{0xd8, 0xfa, 0xba, 0x1f, 0x51, 0x94, 0xc4, 0xdb, 0x5f, 0x17, 0x6f, 0xab, 0xff, 0xf8, 0x56, 0x92, 0x4e, 0xf6, 0x27, 0xa3, 0x7c, 0xd0, 0x8c, 0xf5, 0x56, 0x8, 0xbb, 0xa8, 0xf1, 0xe3, 0x24, 0xd7, 0xc7, 0xf1, 0x57, 0x29, 0x8e, 0xab, 0xc4, 0xdc, 0xe7, 0xd8, 0x9c, 0xe5, 0x16, 0x24, 0x99, 0xf9}, - output224: []byte{0x43, 0x4, 0x58, 0x2c, 0x38, 0x92, 0x94, 0x2b, 0x19, 0x60, 0x82, 0x2c, 0x96, 0x57, 0x88, 0xb2, 0x2d, 0xe1, 0x9f, 0x1c, 0x6d, 0x5e, 0x20, 0x44, 0x76, 0xad, 0xfd, 0x26}, - output256: []byte{0xad, 0x55, 0x53, 0x73, 0x47, 0xb2, 0xd, 0x9f, 0xca, 0x2, 0x68, 0x3e, 0x6d, 0xe1, 0x3, 0x2e, 0xc1, 0xe, 0xb8, 0x4d, 0xa4, 0xcb, 0xd5, 0x1, 0xe4, 0x97, 0x44, 0xa6, 0x66, 0x29, 0x2e, 0xdf}, - output384: []byte{0x36, 0xa6, 0xbf, 0x2d, 0x4e, 0xb3, 0xcc, 0x6f, 0xb7, 0x97, 0x91, 0x4e, 0x73, 0x4b, 0x2c, 0xa8, 0x70, 0x2c, 0xa7, 0xcc, 0x6d, 0x53, 0x9b, 0x4d, 0xdb, 0x23, 0x3e, 0xfa, 0xfc, 0xf0, 0x68, 0x71, 0x2e, 0x84, 0x53, 0x64, 0xa4, 0xa9, 0x29, 0xd3, 0x1a, 0x44, 0xc, 0x7d, 0xaf, 0x8b, 0x13, 0x4c}, - output512: []byte{0x4b, 0x38, 0x9a, 0x2a, 0xd, 0xf5, 0xe2, 0x95, 0xea, 0x94, 0x44, 0xf2, 0x73, 0x9b, 0x54, 0x92, 0xf2, 0x90, 0xc4, 0x46, 0x7b, 0xb, 0x4c, 0xdc, 0x1c, 0xc9, 0xed, 0x2c, 0xef, 0xa7, 0xa9, 0xe5, 0x27, 0xe0, 0x62, 0x7c, 0xda, 0xf0, 0xbd, 0xa5, 0x8f, 0x17, 0xd1, 0x3f, 0x94, 0xaf, 0x7d, 0x2d, 0xef, 0xf6, 0xfc, 0x5d, 0x53, 0xdd, 0x91, 0x57, 0x67, 0x44, 0x75, 0x52, 0x7f, 0xbb, 0x4f, 0x86}}, - testcase{ - msg: []byte{0xbe, 0x96, 0x84, 0xbe, 0x70, 0x34, 0x8, 0x60, 0x37, 0x3c, 0x9c, 0x48, 0x2b, 0xa5, 0x17, 0xe8, 0x99, 0xfc, 0x81, 0xba, 0xaa, 0x12, 0xe5, 0xc6, 0xd7, 0x72, 0x79, 0x75, 0xd1, 0xd4, 0x1b, 0xa8, 0xbe, 0xf7, 0x88, 0xcd, 0xb5, 0xcf, 0x46, 0x6, 0xc9, 0xc1, 0xc7, 0xf6, 0x1a, 0xed, 0x59, 0xf9, 0x7d}, - output224: []byte{0x4, 0x80, 0xef, 0x85, 0x19, 0xc3, 0x2f, 0x89, 0xc6, 0x5b, 0x8d, 0xd4, 0x50, 0x2, 0x5e, 0xc4, 0x9c, 0xbd, 0xad, 0xa6, 0xc4, 0xcf, 0xcf, 0xc6, 0xfb, 0x4f, 0x1c, 0x61}, - output256: []byte{0xb1, 0xf9, 0x90, 0x20, 0x4b, 0xf6, 0x30, 0x56, 0x9a, 0x3e, 0xdc, 0x63, 0x48, 0x64, 0x27, 0x47, 0x86, 0xf4, 0xc, 0xe1, 0xc5, 0x71, 0x65, 0xee, 0x32, 0xd0, 0xe2, 0x9f, 0x5d, 0xc, 0x68, 0x51}, - output384: []byte{0xb6, 0x9d, 0x40, 0xa9, 0x2, 0x7, 0xed, 0xb2, 0xc, 0x0, 0x68, 0xf4, 0x2, 0x0, 0x8c, 0xe, 0x64, 0x30, 0xb, 0x89, 0xa1, 0xb6, 0xaf, 0x79, 0x30, 0x70, 0x8b, 0x26, 0x3c, 0x79, 0xa, 0x8, 0x7f, 0x3a, 0xdb, 0xb4, 0xc8, 0x42, 0x95, 0xd2, 0x33, 0x92, 0xe0, 0x69, 0x2f, 0x35, 0xbd, 0xbc}, - output512: []byte{0x65, 0x90, 0xff, 0xfb, 0x73, 0x11, 0xab, 0x7d, 0xab, 0x37, 0xf, 0xb5, 0x18, 0xcc, 0xc1, 0x9b, 0xaa, 0x9a, 0xf7, 0xc8, 0x41, 0x79, 0xad, 0xb0, 0x2, 0xf8, 0xfa, 0xcd, 0x3c, 0x44, 0xaf, 0x28, 0x30, 0xa8, 0x4d, 0xf1, 0xe2, 0xc2, 0x40, 0x23, 0x68, 0xcc, 0x36, 0x61, 0x4a, 0x6e, 0xa2, 0x29, 0x3, 0x6, 0x3e, 0x57, 0xd0, 0xe, 0xc5, 0x11, 0xa4, 0x6a, 0x9a, 0x3, 0xfe, 0x38, 0x19, 0xf7}}, - testcase{ - msg: []byte{0x7e, 0x15, 0xd2, 0xb9, 0xea, 0x74, 0xca, 0x60, 0xf6, 0x6c, 0x8d, 0xfa, 0xb3, 0x77, 0xd9, 0x19, 0x8b, 0x7b, 0x16, 0xde, 0xb6, 0xa1, 0xba, 0xe, 0xa3, 0xc7, 0xee, 0x20, 0x42, 0xf8, 0x9d, 0x37, 0x86, 0xe7, 0x79, 0xcf, 0x5, 0x3c, 0x77, 0x78, 0x5a, 0xa9, 0xe6, 0x92, 0xf8, 0x21, 0xf1, 0x4a, 0x7f, 0x51}, - output224: []byte{0xb, 0xde, 0x9c, 0xd5, 0xd, 0x70, 0xf0, 0xe, 0xed, 0x97, 0xcc, 0xe4, 0xc, 0x3d, 0xf2, 0x2b, 0xb4, 0x90, 0x4c, 0x8, 0xc4, 0x17, 0x7c, 0x3a, 0x95, 0x98, 0x5d, 0x97}, - output256: []byte{0xfa, 0x46, 0xc, 0xd5, 0x1b, 0xc6, 0x11, 0x78, 0x6d, 0x36, 0x4f, 0xca, 0xbe, 0x39, 0x5, 0x2b, 0xcd, 0x5f, 0x0, 0x9e, 0xdf, 0xa8, 0x1f, 0x47, 0x1, 0xc5, 0xb2, 0x2b, 0x72, 0x9b, 0x0, 0x16}, - output384: []byte{0xcd, 0xdb, 0x88, 0x3b, 0x9e, 0xad, 0xc5, 0x9d, 0x28, 0x94, 0x17, 0x8b, 0x3b, 0xa6, 0xf6, 0x1e, 0x5e, 0x11, 0xc2, 0xc4, 0x15, 0xc8, 0x9e, 0x55, 0x4e, 0x20, 0xa1, 0x7e, 0x49, 0x9, 0xf8, 0xd9, 0x60, 0xf0, 0x2a, 0xa8, 0xe, 0x1a, 0x51, 0x29, 0xae, 0xeb, 0xf2, 0xcf, 0x97, 0x57, 0x11, 0xa4}, - output512: []byte{0x89, 0x57, 0x96, 0xb2, 0xa0, 0x82, 0x4c, 0x55, 0xf0, 0x30, 0xd8, 0x2e, 0x79, 0x49, 0x25, 0xc3, 0x8d, 0x84, 0x59, 0xf3, 0x8c, 0xf8, 0x48, 0x51, 0x9f, 0x12, 0xf, 0xf6, 0xa9, 0xd5, 0xa0, 0x3e, 0xbf, 0x0, 0x6c, 0x3e, 0xa5, 0x2, 0x1e, 0x8f, 0x3b, 0x34, 0x8, 0xff, 0x12, 0xf0, 0x1b, 0xcd, 0xdf, 0x7a, 0x8, 0x5b, 0xa0, 0xa9, 0xa5, 0x89, 0x44, 0xfe, 0xc1, 0xf5, 0x54, 0x83, 0x6d, 0xf8}}, - testcase{ - msg: []byte{0x9a, 0x21, 0x9b, 0xe4, 0x37, 0x13, 0xbd, 0x57, 0x80, 0x15, 0xe9, 0xfd, 0xa6, 0x6c, 0xf, 0x2d, 0x83, 0xca, 0xc5, 0x63, 0xb7, 0x76, 0xab, 0x9f, 0x38, 0xf3, 0xe4, 0xf7, 0xef, 0x22, 0x9c, 0xb4, 0x43, 0x30, 0x4f, 0xba, 0x40, 0x1e, 0xfb, 0x2b, 0xdb, 0xd7, 0xec, 0xe9, 0x39, 0x10, 0x22, 0x98, 0x65, 0x1c, 0x86}, - output224: []byte{0x3b, 0xf3, 0xad, 0xdb, 0x76, 0x1a, 0xb3, 0x2a, 0x38, 0xb7, 0xb4, 0x70, 0x47, 0xad, 0x45, 0xb6, 0x8e, 0xdf, 0xd8, 0x8e, 0xd4, 0x75, 0x22, 0x74, 0x47, 0xea, 0x1b, 0x1e}, - output256: []byte{0xf7, 0xb0, 0xfe, 0x5a, 0x69, 0xff, 0x44, 0x6, 0xd, 0x4f, 0x6a, 0xd2, 0x48, 0x6e, 0x6c, 0xde, 0x9e, 0xd6, 0x79, 0xaf, 0x9a, 0xa1, 0xad, 0xa6, 0x13, 0xe4, 0xcc, 0x39, 0x24, 0x42, 0xbe, 0xb5}, - output384: []byte{0xfb, 0xe0, 0x5, 0x6d, 0x65, 0xaf, 0x27, 0x9e, 0xff, 0x15, 0x73, 0xf1, 0x69, 0x80, 0x9a, 0x5, 0xb6, 0xa5, 0x21, 0x12, 0xb6, 0x62, 0xd0, 0x7c, 0xdd, 0x25, 0x70, 0xbe, 0x5e, 0x19, 0x8a, 0x28, 0xd1, 0xea, 0x49, 0xcb, 0xea, 0xf0, 0xc0, 0x5e, 0x76, 0xa9, 0xf0, 0x9b, 0xaf, 0x6d, 0x1f, 0x34}, - output512: []byte{0xe4, 0xbb, 0xd5, 0x4b, 0xfb, 0x99, 0xd3, 0x45, 0x47, 0x1f, 0x8a, 0xb9, 0x42, 0x71, 0xb4, 0xb7, 0x48, 0xf5, 0xce, 0x70, 0xc2, 0x1c, 0x28, 0xae, 0x65, 0x59, 0xe0, 0x3e, 0xe7, 0x89, 0xa, 0x2c, 0x81, 0x40, 0x43, 0xe6, 0x24, 0xa6, 0xbd, 0x29, 0x44, 0x35, 0x7, 0x56, 0xb3, 0x7f, 0xa8, 0x20, 0x8f, 0xc7, 0x47, 0x3a, 0x67, 0xb3, 0x10, 0xce, 0xeb, 0xc1, 0x7d, 0x96, 0x5e, 0xd6, 0x88, 0xb2}}, - testcase{ - msg: []byte{0xc8, 0xf2, 0xb6, 0x93, 0xbd, 0xd, 0x75, 0xef, 0x99, 0xca, 0xeb, 0xdc, 0x22, 0xad, 0xf4, 0x8, 0x8a, 0x95, 0xa3, 0x54, 0x2f, 0x63, 0x72, 0x3, 0xe2, 0x83, 0xbb, 0xc3, 0x26, 0x87, 0x80, 0xe7, 0x87, 0xd6, 0x8d, 0x28, 0xcc, 0x38, 0x97, 0x45, 0x2f, 0x6a, 0x22, 0xaa, 0x85, 0x73, 0xcc, 0xeb, 0xf2, 0x45, 0x97, 0x2a}, - output224: []byte{0x61, 0x82, 0x61, 0x4c, 0x82, 0x57, 0xeb, 0x5, 0xe9, 0xac, 0x9, 0x50, 0xe1, 0x5e, 0x60, 0x44, 0x87, 0x2e, 0x5c, 0xa, 0xb2, 0xaf, 0x45, 0x40, 0x76, 0x4c, 0xa0, 0xc8}, - output256: []byte{0x24, 0x20, 0x4d, 0x49, 0x1f, 0x20, 0x25, 0x34, 0x85, 0x9f, 0xc0, 0xa2, 0x8, 0x23, 0x71, 0x84, 0x47, 0x1a, 0x2d, 0x80, 0x1f, 0xb3, 0xb9, 0x34, 0xd0, 0x96, 0x8d, 0xd, 0x84, 0x3d, 0x3, 0x45}, - output384: []byte{0x26, 0x47, 0x3d, 0xe6, 0x84, 0xcf, 0x58, 0xd5, 0x59, 0xc7, 0xc0, 0xcf, 0xd3, 0x60, 0xa9, 0xaf, 0xfd, 0xf3, 0x39, 0x0, 0xfd, 0x69, 0xa3, 0xa9, 0x46, 0x58, 0x14, 0x84, 0xb9, 0x3e, 0xf6, 0xfe, 0x6f, 0xfa, 0xc4, 0x61, 0xb4, 0x55, 0x1e, 0x13, 0x6b, 0xea, 0xc6, 0x4c, 0xc3, 0x3a, 0x4c, 0x15}, - output512: []byte{0x80, 0xd8, 0x62, 0xad, 0x5, 0x42, 0x8a, 0x29, 0x92, 0x13, 0xe6, 0x5b, 0x50, 0x31, 0x4, 0x63, 0xfd, 0x22, 0xc5, 0x5, 0xe6, 0x93, 0xdd, 0x47, 0x19, 0xe0, 0xa1, 0x20, 0xee, 0xaa, 0x35, 0xc5, 0xfc, 0x16, 0x8, 0xa0, 0x8d, 0x22, 0xe2, 0xcc, 0xdd, 0xec, 0xa4, 0x98, 0x78, 0xbc, 0x26, 0xab, 0xe5, 0x5a, 0x3c, 0x9a, 0x54, 0x63, 0x47, 0x43, 0x9a, 0x94, 0x2e, 0xd0, 0xc1, 0xa6, 0xa2, 0x3e}}, - testcase{ - msg: []byte{0xec, 0xf, 0x99, 0x71, 0x10, 0x16, 0xc6, 0xa2, 0xa0, 0x7a, 0xd8, 0xd, 0x16, 0x42, 0x75, 0x6, 0xce, 0x6f, 0x44, 0x10, 0x59, 0xfd, 0x26, 0x94, 0x42, 0xba, 0xaa, 0x28, 0xc6, 0xca, 0x3, 0x7b, 0x22, 0xee, 0xac, 0x49, 0xd5, 0xd8, 0x94, 0xc0, 0xbf, 0x66, 0x21, 0x9f, 0x2c, 0x8, 0xe9, 0xd0, 0xe8, 0xab, 0x21, 0xde, 0x52}, - output224: []byte{0xb, 0x5d, 0xc7, 0x22, 0xee, 0xa2, 0xc3, 0x48, 0x32, 0x5f, 0xd9, 0xb3, 0xd7, 0xf0, 0x8f, 0x36, 0x5b, 0x71, 0xd5, 0xb5, 0x82, 0xc2, 0x7b, 0xeb, 0x79, 0xb5, 0x1d, 0x5d}, - output256: []byte{0x81, 0x14, 0x7c, 0xba, 0x6, 0x47, 0xee, 0xe7, 0x8c, 0x47, 0x84, 0x87, 0x4c, 0x5, 0x57, 0x62, 0x1a, 0x13, 0x8c, 0xa7, 0x81, 0xfb, 0x6f, 0x5d, 0xcd, 0xd, 0x9c, 0x60, 0x9a, 0xf5, 0x6f, 0x35}, - output384: []byte{0x46, 0x2a, 0xd9, 0x7b, 0xb0, 0x15, 0x6a, 0x5d, 0xa3, 0xdd, 0xe, 0x9e, 0x5b, 0xf0, 0x6d, 0x31, 0x2, 0x4f, 0xe4, 0x3b, 0xb8, 0xc, 0x1, 0x8f, 0x68, 0x58, 0xee, 0x43, 0x32, 0xf2, 0xeb, 0x5a, 0x78, 0xad, 0xa0, 0x6c, 0xb5, 0x5d, 0xdc, 0x17, 0x2a, 0xd8, 0x7f, 0x88, 0xe2, 0x6d, 0x24, 0x51}, - output512: []byte{0x2, 0x1b, 0x3b, 0x39, 0x2d, 0xec, 0xcb, 0x90, 0x75, 0x55, 0x9f, 0x88, 0xc0, 0xc2, 0x29, 0x2, 0x6a, 0x20, 0x48, 0xce, 0xf8, 0xee, 0xb2, 0xd4, 0xf9, 0x48, 0x3, 0xdc, 0xf2, 0xda, 0xa, 0x73, 0xe0, 0x4, 0xd7, 0xf1, 0x4e, 0x9f, 0xd6, 0x62, 0x67, 0xb, 0x59, 0x22, 0x9a, 0xb3, 0x88, 0x3c, 0x34, 0xf, 0x4e, 0x3a, 0x8c, 0x42, 0x62, 0x4c, 0xcb, 0x90, 0xbe, 0xc1, 0x15, 0x6f, 0x95, 0xd4}}, - testcase{ - msg: []byte{0xd, 0xc4, 0x51, 0x81, 0x33, 0x7c, 0xa3, 0x2a, 0x82, 0x22, 0xfe, 0x7a, 0x3b, 0xf4, 0x2f, 0xc9, 0xf8, 0x97, 0x44, 0x25, 0x9c, 0xff, 0x65, 0x35, 0x4, 0xd6, 0x5, 0x1f, 0xe8, 0x4b, 0x1a, 0x7f, 0xfd, 0x20, 0xcb, 0x47, 0xd4, 0x69, 0x6c, 0xe2, 0x12, 0xa6, 0x86, 0xbb, 0x9b, 0xe9, 0xa8, 0xab, 0x1c, 0x69, 0x7b, 0x6d, 0x6a, 0x33}, - output224: []byte{0x29, 0xc2, 0xb8, 0x17, 0xc7, 0x5b, 0x64, 0x17, 0xbc, 0x89, 0xc2, 0x62, 0xaf, 0x9d, 0x58, 0xf0, 0xc1, 0x8f, 0xbd, 0x99, 0x1f, 0x59, 0xf4, 0x18, 0x1f, 0x23, 0x70, 0x38}, - output256: []byte{0x5b, 0x6d, 0x7e, 0xda, 0x55, 0x95, 0x74, 0xfa, 0xe8, 0x82, 0xe6, 0x26, 0x6f, 0x4c, 0x2b, 0xe3, 0x62, 0x13, 0x3e, 0x44, 0xb5, 0xa9, 0x47, 0xec, 0xb6, 0xe7, 0x5d, 0xb9, 0xfc, 0x85, 0x67, 0xe0}, - output384: []byte{0x9f, 0x89, 0xf, 0xa8, 0xa, 0x4c, 0x48, 0xb6, 0x71, 0x81, 0xe8, 0x9d, 0xbf, 0x15, 0x17, 0x5c, 0xe4, 0x8b, 0x21, 0xf9, 0xd0, 0x94, 0x5, 0x21, 0x8a, 0x8c, 0xe3, 0xc0, 0x75, 0x92, 0x82, 0x78, 0xe, 0x14, 0x2f, 0xc5, 0x98, 0x51, 0x15, 0x7d, 0x14, 0x50, 0x9f, 0xce, 0x79, 0xd1, 0xb1, 0x7f}, - output512: []byte{0x97, 0xbf, 0x33, 0xa5, 0x25, 0x4c, 0x8a, 0xca, 0x27, 0x48, 0x64, 0x28, 0x44, 0xb, 0x10, 0x34, 0xaa, 0xaf, 0xac, 0x8b, 0x49, 0x8e, 0xcb, 0x83, 0xc, 0x25, 0x81, 0xdc, 0x68, 0x51, 0x80, 0x79, 0xb6, 0x5f, 0xb0, 0xc5, 0x95, 0x99, 0x76, 0x93, 0xdd, 0xb8, 0xd6, 0x8d, 0x95, 0x64, 0xea, 0x98, 0xdc, 0x43, 0xcd, 0x28, 0x7e, 0x2e, 0x1, 0x8d, 0xb7, 0xdf, 0xaa, 0xaa, 0x20, 0x5c, 0x54, 0x7a}}, - testcase{ - msg: []byte{0xde, 0x28, 0x6b, 0xa4, 0x20, 0x6e, 0x8b, 0x0, 0x57, 0x14, 0xf8, 0xf, 0xb1, 0xcd, 0xfa, 0xeb, 0xde, 0x91, 0xd2, 0x9f, 0x84, 0x60, 0x3e, 0x4a, 0x3e, 0xbc, 0x4, 0x68, 0x6f, 0x99, 0xa4, 0x6c, 0x9e, 0x88, 0xb, 0x96, 0xc5, 0x74, 0x82, 0x55, 0x82, 0xe8, 0x81, 0x2a, 0x26, 0xe5, 0xa8, 0x57, 0xff, 0xc6, 0x57, 0x9f, 0x63, 0x74, 0x2f}, - output224: []byte{0x62, 0xc5, 0x87, 0x66, 0x94, 0xd8, 0x80, 0x7, 0x70, 0x9b, 0x50, 0x90, 0xe, 0xe2, 0xe6, 0xca, 0x95, 0x5, 0xcc, 0x90, 0x6, 0x7e, 0xfb, 0xf4, 0xc1, 0xd9, 0x5b, 0xb}, - output256: []byte{0x86, 0xf8, 0x7e, 0x75, 0xc8, 0x7f, 0x9b, 0xe3, 0x9e, 0x4a, 0xa6, 0xd0, 0xc5, 0xa3, 0x7a, 0x59, 0x64, 0xd6, 0xff, 0xdc, 0x46, 0x25, 0x25, 0xc0, 0x64, 0x2c, 0x9d, 0xb0, 0x10, 0xde, 0x38, 0xee}, - output384: []byte{0x2d, 0x9a, 0x34, 0x47, 0xd7, 0x72, 0x3d, 0x83, 0x7b, 0x87, 0x84, 0xfe, 0xaf, 0x3, 0xb8, 0xf9, 0x69, 0x4c, 0xde, 0x5f, 0xfb, 0x84, 0xc6, 0xa6, 0x62, 0x88, 0x95, 0xa3, 0x45, 0xbb, 0x8f, 0x3f, 0x5b, 0xa7, 0x25, 0x41, 0x69, 0x6, 0xde, 0x6, 0x3b, 0x1c, 0xef, 0xb7, 0x22, 0xc7, 0xe5, 0x6a}, - output512: []byte{0xc0, 0x5f, 0xd9, 0xc3, 0xfa, 0x73, 0xf8, 0x9, 0x56, 0xff, 0x1c, 0x3b, 0x89, 0x16, 0xe, 0xb5, 0x20, 0xca, 0x64, 0xe, 0x20, 0x1b, 0x3f, 0xe5, 0xe6, 0xe2, 0x96, 0x22, 0xe, 0x81, 0xb5, 0x9d, 0x53, 0x4, 0x76, 0x1, 0xd, 0x37, 0x84, 0xca, 0x8, 0x69, 0x2b, 0x8c, 0x71, 0x6a, 0x3b, 0xe9, 0x82, 0xb3, 0x74, 0x50, 0xa9, 0x6d, 0x30, 0xa4, 0x1, 0xd3, 0xba, 0x3c, 0x39, 0xd, 0x9d, 0xe3}}, - testcase{ - msg: []byte{0xee, 0xbc, 0xc1, 0x80, 0x57, 0x25, 0x2c, 0xbf, 0x3f, 0x9c, 0x7, 0xf, 0x1a, 0x73, 0x21, 0x33, 0x56, 0xd5, 0xd4, 0xbc, 0x19, 0xac, 0x2a, 0x41, 0x1e, 0xc8, 0xcd, 0xee, 0xe7, 0xa5, 0x71, 0xe2, 0xe2, 0xe, 0xaf, 0x61, 0xfd, 0xc, 0x33, 0xa0, 0xff, 0xeb, 0x29, 0x7d, 0xdb, 0x77, 0xa9, 0x7f, 0xa, 0x41, 0x53, 0x47, 0xdb, 0x66, 0xbc, 0xaf}, - output224: []byte{0xd3, 0x62, 0xbe, 0x78, 0x96, 0xb2, 0xac, 0x3c, 0xa4, 0xdc, 0x31, 0x61, 0xb7, 0xf6, 0xc5, 0xb3, 0xfb, 0xe6, 0x5f, 0x32, 0xd0, 0x40, 0x40, 0x2b, 0x8d, 0x30, 0x6b, 0x15}, - output256: []byte{0x95, 0x9f, 0xe0, 0x7, 0xb5, 0x7c, 0x29, 0x47, 0xc3, 0x6d, 0x1d, 0x66, 0xcc, 0x8, 0x8, 0xd8, 0xd, 0xb7, 0xdf, 0x45, 0xd6, 0x8a, 0x34, 0x85, 0x2b, 0x70, 0xd2, 0xdd, 0xa1, 0x92, 0xc2, 0x5c}, - output384: []byte{0xaf, 0x41, 0x50, 0x63, 0xa5, 0xe2, 0x5c, 0x6e, 0x55, 0xec, 0xa7, 0xf9, 0xbd, 0x1c, 0xb0, 0xc7, 0x1a, 0x7a, 0x5, 0x9b, 0x56, 0x97, 0x37, 0x3, 0x6b, 0x33, 0x9c, 0xa5, 0x59, 0xcc, 0x9c, 0x74, 0x66, 0xfa, 0x23, 0x9e, 0xa5, 0x7c, 0xfb, 0x5f, 0xcc, 0x50, 0x94, 0x48, 0x71, 0xc0, 0x8, 0xfb}, - output512: []byte{0xb9, 0x80, 0xe6, 0x57, 0xc1, 0x37, 0x26, 0xdb, 0xad, 0xb6, 0x57, 0xe, 0xa3, 0xa9, 0xe6, 0x33, 0x86, 0x9c, 0xad, 0xb7, 0x98, 0xeb, 0x35, 0xc4, 0x82, 0x69, 0x7a, 0x4, 0xcb, 0x71, 0x2f, 0x1c, 0x1e, 0x8c, 0x5d, 0xb, 0xd6, 0x7e, 0x43, 0xe5, 0x2d, 0xa2, 0x94, 0xe8, 0x2d, 0x5e, 0x80, 0xa6, 0x95, 0xa7, 0x4a, 0x3d, 0x27, 0xc0, 0xc6, 0x72, 0xad, 0xcf, 0xe2, 0xc9, 0x28, 0x85, 0x9a, 0x6d}}, - testcase{ - msg: []byte{0x41, 0x6b, 0x5c, 0xdc, 0x9f, 0xe9, 0x51, 0xbd, 0x36, 0x1b, 0xd7, 0xab, 0xfc, 0x12, 0xa, 0x50, 0x54, 0x75, 0x8e, 0xba, 0x88, 0xfd, 0xd6, 0x8f, 0xd8, 0x4e, 0x39, 0xd3, 0xb0, 0x9a, 0xc2, 0x54, 0x97, 0xd3, 0x6b, 0x43, 0xcb, 0xe7, 0xb8, 0x5a, 0x6a, 0x3c, 0xeb, 0xda, 0x8d, 0xb4, 0xe5, 0x54, 0x9c, 0x3e, 0xe5, 0x1b, 0xb6, 0xfc, 0xb6, 0xac, 0x1e}, - output224: []byte{0xd4, 0x20, 0xc7, 0xbd, 0xf8, 0xd8, 0x6d, 0x7b, 0x1c, 0xbd, 0x1a, 0xf7, 0x86, 0x8e, 0xbc, 0x4f, 0xf1, 0x72, 0x45, 0x59, 0x5b, 0x94, 0x95, 0x9a, 0x7, 0x14, 0x33, 0x3c}, - output256: []byte{0x1a, 0x93, 0x56, 0x7e, 0xeb, 0xc4, 0x1c, 0xc4, 0x4d, 0x93, 0x46, 0xcd, 0xe6, 0x46, 0x0, 0x5d, 0x3e, 0x82, 0xde, 0x8e, 0xee, 0xb1, 0x31, 0xe9, 0xc1, 0xf6, 0xd1, 0xe4, 0xaf, 0xd2, 0x60, 0xf7}, - output384: []byte{0x68, 0x11, 0xec, 0x7, 0xe6, 0xe8, 0x5a, 0x28, 0x9c, 0x88, 0x17, 0x22, 0xae, 0x84, 0xe6, 0xae, 0xf0, 0x1f, 0xd2, 0x76, 0x12, 0x94, 0xc6, 0xed, 0x98, 0x56, 0xd2, 0xf7, 0xea, 0x1c, 0x71, 0xa8, 0x9b, 0x2f, 0xcf, 0x4a, 0x9e, 0x56, 0x53, 0x33, 0x60, 0xea, 0x22, 0x31, 0x75, 0x61, 0xec, 0x5}, - output512: []byte{0x6a, 0xdf, 0xc5, 0x61, 0x83, 0x5f, 0xdd, 0xd7, 0xa, 0x9f, 0xeb, 0x57, 0xc5, 0x13, 0x16, 0x5d, 0x12, 0xae, 0xb3, 0x28, 0x3f, 0xd, 0xd7, 0x77, 0x4d, 0xd5, 0x88, 0x52, 0xda, 0x9e, 0x96, 0x9a, 0xbd, 0xaf, 0x20, 0xdd, 0x44, 0x85, 0x6f, 0xa6, 0xe, 0x11, 0xbd, 0xfa, 0x2d, 0xbb, 0x7e, 0x33, 0x47, 0x66, 0x9f, 0xff, 0x7a, 0x57, 0xa8, 0xd8, 0xd3, 0x74, 0x31, 0xc2, 0xb3, 0x9, 0x97, 0x2d}}, - testcase{ - msg: []byte{0x5c, 0x5f, 0xaf, 0x66, 0xf3, 0x2e, 0xf, 0x83, 0x11, 0xc3, 0x2e, 0x8d, 0xa8, 0x28, 0x4a, 0x4e, 0xd6, 0x8, 0x91, 0xa5, 0xa7, 0xe5, 0xf, 0xb2, 0x95, 0x6b, 0x3c, 0xba, 0xa7, 0x9f, 0xc6, 0x6c, 0xa3, 0x76, 0x46, 0xe, 0x10, 0x4, 0x15, 0x40, 0x1f, 0xc2, 0xb8, 0x51, 0x8c, 0x64, 0x50, 0x2f, 0x18, 0x7e, 0xa1, 0x4b, 0xfc, 0x95, 0x3, 0x75, 0x97, 0x5}, - output224: []byte{0x2e, 0x4, 0xda, 0xe6, 0xe3, 0xfd, 0xf2, 0xa4, 0x7f, 0xf4, 0xe, 0x6f, 0x3e, 0x61, 0xb3, 0x71, 0xf3, 0xe5, 0x1a, 0x58, 0x64, 0xa3, 0x1c, 0xc1, 0x1d, 0x12, 0x76, 0x20}, - output256: []byte{0x54, 0x9d, 0xb0, 0x56, 0xb6, 0x5e, 0xdf, 0x7d, 0x5, 0xbd, 0x66, 0x66, 0x1b, 0x6d, 0xa, 0x39, 0xb2, 0x9b, 0x82, 0x5b, 0xc8, 0x9, 0x10, 0xf8, 0xbf, 0x70, 0x60, 0xa5, 0x3b, 0xff, 0x68, 0xe1}, - output384: []byte{0x7c, 0x90, 0x26, 0x8e, 0x98, 0x1a, 0x3c, 0xf, 0xf1, 0x9e, 0x14, 0xce, 0x98, 0x30, 0xa1, 0xb9, 0xda, 0x5f, 0xc1, 0x83, 0x95, 0x8, 0x75, 0x96, 0x15, 0x82, 0x64, 0x44, 0x62, 0x5, 0x9d, 0xd2, 0xfa, 0xdc, 0xfa, 0x68, 0x75, 0xd, 0x7d, 0x2f, 0x44, 0xdf, 0xca, 0xb9, 0xff, 0xce, 0x58, 0x32}, - output512: []byte{0xe, 0x74, 0x59, 0xbd, 0xc8, 0x57, 0xb9, 0x49, 0xcc, 0x59, 0xa9, 0xc6, 0x49, 0xb9, 0x62, 0x52, 0x68, 0xbf, 0x9a, 0x11, 0xea, 0x81, 0xee, 0xef, 0xa4, 0xec, 0xdd, 0x41, 0xe, 0x2f, 0x6f, 0xd2, 0xc7, 0x82, 0x89, 0xc0, 0x13, 0x65, 0xf9, 0x90, 0x34, 0xff, 0x8f, 0xa8, 0xc1, 0x15, 0xdd, 0xce, 0xbe, 0xfa, 0x26, 0xa8, 0xd6, 0x46, 0x8f, 0x50, 0x30, 0xe6, 0x41, 0x74, 0x59, 0x50, 0x6, 0x1e}}, - testcase{ - msg: []byte{0x71, 0x67, 0xe1, 0xe0, 0x2b, 0xe1, 0xa7, 0xca, 0x69, 0xd7, 0x88, 0x66, 0x6f, 0x82, 0x3a, 0xe4, 0xee, 0xf3, 0x92, 0x71, 0xf3, 0xc2, 0x6a, 0x5c, 0xf7, 0xce, 0xe0, 0x5b, 0xca, 0x83, 0x16, 0x10, 0x66, 0xdc, 0x2e, 0x21, 0x7b, 0x33, 0xd, 0xf8, 0x21, 0x10, 0x37, 0x99, 0xdf, 0x6d, 0x74, 0x81, 0xe, 0xed, 0x36, 0x3a, 0xdc, 0x4a, 0xb9, 0x9f, 0x36, 0x4, 0x6a}, - output224: []byte{0x22, 0x81, 0x7a, 0x21, 0xcf, 0xce, 0xc4, 0xfd, 0x23, 0x48, 0xb6, 0xbe, 0x8a, 0x70, 0x42, 0xa3, 0x77, 0x54, 0xd7, 0x6a, 0x3f, 0x33, 0xa8, 0xf8, 0x18, 0x31, 0x2c, 0xc7}, - output256: []byte{0x79, 0x4a, 0xbf, 0xd7, 0xeb, 0x62, 0x2d, 0x56, 0x8, 0xc1, 0xc7, 0xb3, 0xf0, 0xa7, 0x82, 0x1a, 0x71, 0x90, 0xb, 0x71, 0x72, 0x84, 0x7f, 0xb0, 0x90, 0x7a, 0xa2, 0x89, 0x99, 0x72, 0x66, 0x3e}, - output384: []byte{0x64, 0xe9, 0xad, 0x35, 0x7b, 0x58, 0xc6, 0xfa, 0xd, 0x26, 0xd0, 0xd1, 0xf4, 0x8c, 0x4a, 0xb0, 0x57, 0xb9, 0xf8, 0x9, 0x65, 0xac, 0x38, 0x49, 0x4e, 0x88, 0xf5, 0x42, 0xba, 0x41, 0xd6, 0xb7, 0x98, 0xfc, 0x2d, 0xd8, 0x82, 0x90, 0xf8, 0xdd, 0xe7, 0x94, 0x8c, 0x19, 0xb5, 0xa1, 0xf2, 0x60}, - output512: []byte{0x2a, 0x8c, 0xe9, 0xdf, 0x40, 0x87, 0x9b, 0x24, 0xda, 0xdf, 0x61, 0xc9, 0x13, 0x1f, 0x69, 0x4e, 0x55, 0x31, 0xad, 0xe6, 0xb7, 0xab, 0x7, 0x1c, 0xa1, 0xa, 0xbd, 0xd3, 0xc2, 0xe4, 0xa2, 0x2c, 0x86, 0x8a, 0x52, 0x98, 0x6a, 0x32, 0x9f, 0x88, 0x1, 0x37, 0xee, 0x76, 0x10, 0x97, 0x70, 0x92, 0x7d, 0x26, 0x58, 0xe6, 0x3e, 0xb4, 0x86, 0xd8, 0x80, 0x29, 0xa, 0xc0, 0x78, 0x2c, 0xf5, 0xbf}}, - testcase{ - msg: []byte{0x2f, 0xda, 0x31, 0x1d, 0xbb, 0xa2, 0x73, 0x21, 0xc5, 0x32, 0x95, 0x10, 0xfa, 0xe6, 0x94, 0x8f, 0x3, 0x21, 0xb, 0x76, 0xd4, 0x3e, 0x74, 0x48, 0xd1, 0x68, 0x9a, 0x6, 0x38, 0x77, 0xb6, 0xd1, 0x4c, 0x4f, 0x6d, 0xe, 0xaa, 0x96, 0xc1, 0x50, 0x5, 0x13, 0x71, 0xf7, 0xdd, 0x8a, 0x41, 0x19, 0xf7, 0xda, 0x5c, 0x48, 0x3c, 0xc3, 0xe6, 0x72, 0x3c, 0x1, 0xfb, 0x7d}, - output224: []byte{0x68, 0xca, 0xf2, 0x20, 0x33, 0x17, 0xa8, 0xbe, 0xd3, 0xc, 0x17, 0x92, 0xe8, 0x88, 0x91, 0x1, 0x24, 0xf2, 0xf0, 0xee, 0x1d, 0x24, 0xd4, 0x72, 0x74, 0xbc, 0xc8, 0x56}, - output256: []byte{0x9c, 0xe8, 0x99, 0x58, 0xcb, 0xdd, 0xd8, 0xdc, 0xb2, 0x2f, 0x66, 0xe8, 0xcb, 0xa5, 0xf6, 0x9, 0x1a, 0x51, 0x95, 0x31, 0x89, 0x46, 0x48, 0x3, 0xbd, 0xc7, 0x73, 0xab, 0xc7, 0xfa, 0xa9, 0x6}, - output384: []byte{0x3d, 0x73, 0xb3, 0x3f, 0x0, 0x13, 0x87, 0xfd, 0x1e, 0x75, 0x20, 0x68, 0xaf, 0x39, 0x45, 0x4e, 0x47, 0x6b, 0x84, 0x7, 0x3, 0x8c, 0x77, 0x2d, 0x94, 0x40, 0x4, 0x58, 0xc9, 0x36, 0x64, 0xec, 0x52, 0x26, 0xad, 0x1b, 0xd3, 0xa1, 0x9a, 0x6d, 0x9a, 0x6f, 0xbd, 0x6e, 0x6a, 0x62, 0x69, 0x5c}, - output512: []byte{0xa8, 0x3c, 0xe5, 0xa6, 0xa5, 0x83, 0x76, 0xd5, 0x7d, 0xb4, 0xc5, 0x8d, 0xa1, 0xb4, 0x6c, 0x13, 0x1f, 0xf1, 0xbf, 0x8f, 0xf2, 0xde, 0x5e, 0x86, 0x17, 0xfb, 0x37, 0xe5, 0x9, 0x83, 0x98, 0xed, 0xb5, 0x3f, 0x98, 0x88, 0xb8, 0x75, 0x2a, 0x8a, 0xff, 0x19, 0x17, 0x8f, 0x2f, 0x6b, 0xd7, 0xa3, 0x3f, 0xd3, 0x6c, 0x59, 0xe4, 0xa6, 0x31, 0x90, 0x62, 0x80, 0x90, 0x7f, 0xc1, 0xc5, 0xab, 0x7}}, - testcase{ - msg: []byte{0x95, 0xd1, 0x47, 0x4a, 0x5a, 0xab, 0x5d, 0x24, 0x22, 0xac, 0xa6, 0xe4, 0x81, 0x18, 0x78, 0x33, 0xa6, 0x21, 0x2b, 0xd2, 0xd0, 0xf9, 0x14, 0x51, 0xa6, 0x7d, 0xd7, 0x86, 0xdf, 0xc9, 0x1d, 0xfe, 0xd5, 0x1b, 0x35, 0xf4, 0x7e, 0x1d, 0xeb, 0x8a, 0x8a, 0xb4, 0xb9, 0xcb, 0x67, 0xb7, 0x1, 0x79, 0xcc, 0x26, 0xf5, 0x53, 0xae, 0x7b, 0x56, 0x99, 0x69, 0xce, 0x15, 0x1b, 0x8d}, - output224: []byte{0x7b, 0xba, 0xc0, 0xc0, 0xf1, 0x92, 0xd2, 0xc4, 0x79, 0x34, 0x83, 0x58, 0xd2, 0x24, 0x7e, 0x4c, 0x8, 0x96, 0x6a, 0x51, 0x2f, 0x73, 0xd4, 0x4, 0x45, 0xb5, 0x2e, 0xc7}, - output256: []byte{0x6d, 0xa7, 0x33, 0x81, 0x7d, 0xc8, 0x26, 0xe8, 0xda, 0x77, 0x3b, 0xec, 0xa7, 0x33, 0x81, 0x31, 0xab, 0x73, 0x96, 0x41, 0x71, 0x4, 0xed, 0xa2, 0x59, 0x70, 0x98, 0xc, 0x4e, 0xb2, 0xa1, 0x5f}, - output384: []byte{0xfc, 0x61, 0x9c, 0xa9, 0x81, 0xc, 0xaa, 0xe3, 0x63, 0x9b, 0x3f, 0xc6, 0x61, 0x38, 0x8c, 0x45, 0x41, 0x67, 0x27, 0x1e, 0x65, 0xed, 0xa, 0x2e, 0x5e, 0x8b, 0xc7, 0x18, 0xad, 0x21, 0xb9, 0xed, 0xe8, 0x95, 0xa6, 0x58, 0xc9, 0x46, 0xdc, 0x2f, 0xb1, 0x5b, 0x33, 0x35, 0x4d, 0xfe, 0x40, 0x2a}, - output512: []byte{0x9e, 0xbf, 0xce, 0xa2, 0xdb, 0x16, 0x76, 0xee, 0xe6, 0xb1, 0x3, 0x11, 0x95, 0x43, 0xc6, 0x4, 0x9d, 0xeb, 0xd8, 0xfb, 0x8f, 0x1e, 0x1, 0xa5, 0xab, 0x5b, 0x34, 0x8e, 0x29, 0x19, 0xe1, 0x4c, 0x8c, 0xfe, 0x8e, 0x54, 0x2f, 0x2a, 0xb7, 0x47, 0xb0, 0xfd, 0x4a, 0x4c, 0x3e, 0xee, 0x40, 0x19, 0xbb, 0x4, 0x6e, 0x24, 0xbf, 0xe2, 0x9, 0x1f, 0xb9, 0xc6, 0x5d, 0xca, 0x52, 0x7b, 0x71, 0xad}}, - testcase{ - msg: []byte{0xc7, 0x1b, 0xd7, 0x94, 0x1f, 0x41, 0xdf, 0x4, 0x4a, 0x29, 0x27, 0xa8, 0xff, 0x55, 0xb4, 0xb4, 0x67, 0xc3, 0x3d, 0x8, 0x9f, 0x9, 0x88, 0xaa, 0x25, 0x3d, 0x29, 0x4a, 0xdd, 0xbd, 0xb3, 0x25, 0x30, 0xc0, 0xd4, 0x20, 0x8b, 0x10, 0xd9, 0x95, 0x98, 0x23, 0xf0, 0xc0, 0xf0, 0x73, 0x46, 0x84, 0x0, 0x6d, 0xf7, 0x9f, 0x70, 0x99, 0x87, 0xf, 0x6b, 0xf5, 0x32, 0x11, 0xa8, 0x8d}, - output224: []byte{0xd2, 0x26, 0xd9, 0xe1, 0xf3, 0x6e, 0xc4, 0x22, 0x26, 0x93, 0x69, 0x9b, 0x6d, 0x3, 0x83, 0xc1, 0x45, 0x2e, 0x39, 0x1c, 0x41, 0xef, 0xd7, 0x64, 0x52, 0x89, 0xf8, 0xe3}, - output256: []byte{0x66, 0xc9, 0xcd, 0xc8, 0xe8, 0xc6, 0xc9, 0x41, 0x7d, 0x7f, 0xfb, 0xef, 0x3b, 0x54, 0xb7, 0x2, 0xee, 0xe5, 0xf0, 0x1a, 0x9b, 0xda, 0x8d, 0xd4, 0xe2, 0x8f, 0xe3, 0x33, 0x5d, 0xeb, 0xbb, 0x51}, - output384: []byte{0x58, 0x43, 0x12, 0x3a, 0x28, 0xf0, 0xb5, 0xc, 0x8, 0x20, 0x23, 0xac, 0x43, 0xb7, 0x29, 0x9c, 0x4f, 0xe6, 0x73, 0x2, 0x53, 0x2d, 0xf4, 0x80, 0x5b, 0xe6, 0xde, 0xc3, 0xb8, 0x45, 0x15, 0xb1, 0xc6, 0xc9, 0x8f, 0x8a, 0x4e, 0x3d, 0x6c, 0xa8, 0x26, 0xda, 0x4a, 0x11, 0x30, 0xc, 0x3b, 0x9b}, - output512: []byte{0x97, 0xb0, 0x8b, 0xe7, 0x65, 0x3e, 0x9d, 0xf1, 0xb5, 0xaf, 0xa4, 0x59, 0xea, 0x75, 0xa, 0x3a, 0xc9, 0xbf, 0x35, 0x77, 0xbc, 0xc7, 0xe5, 0x34, 0x4f, 0xc8, 0x61, 0x18, 0x48, 0x80, 0x92, 0x6d, 0xef, 0x35, 0x4e, 0x4c, 0x65, 0xb2, 0xe, 0xc6, 0x6c, 0x47, 0xb7, 0xaf, 0xfd, 0x3e, 0x74, 0x93, 0x95, 0x8b, 0xab, 0xa, 0x90, 0x72, 0x4d, 0x3d, 0x8d, 0xd9, 0xe1, 0xd5, 0x61, 0xfa, 0x60, 0xc2}}, - testcase{ - msg: []byte{0xf5, 0x7c, 0x64, 0x0, 0x6d, 0x9e, 0xa7, 0x61, 0x89, 0x2e, 0x14, 0x5c, 0x99, 0xdf, 0x1b, 0x24, 0x64, 0x8, 0x83, 0xda, 0x79, 0xd9, 0xed, 0x52, 0x62, 0x85, 0x9d, 0xcd, 0xa8, 0xc3, 0xc3, 0x2e, 0x5, 0xb0, 0x3d, 0x98, 0x4f, 0x1a, 0xb4, 0xa2, 0x30, 0x24, 0x2a, 0xb6, 0xb7, 0x8d, 0x36, 0x8d, 0xc5, 0xaa, 0xa1, 0xe6, 0xd3, 0x49, 0x8d, 0x53, 0x37, 0x1e, 0x84, 0xb0, 0xc1, 0xd4, 0xba}, - output224: []byte{0x29, 0x4a, 0x1e, 0x5a, 0x6, 0x29, 0xa2, 0x73, 0x6f, 0x18, 0x86, 0x91, 0xa3, 0x5f, 0xe1, 0xab, 0xb5, 0x54, 0x72, 0x78, 0x5d, 0xaf, 0xf6, 0xcd, 0x88, 0xc6, 0xd5, 0x37}, - output256: []byte{0x24, 0xab, 0x37, 0xa9, 0x36, 0x74, 0xcc, 0xb1, 0xce, 0xec, 0x9e, 0x56, 0x81, 0xef, 0xc8, 0xbd, 0xf9, 0xfc, 0xc7, 0x72, 0x1c, 0xf1, 0xca, 0xc1, 0x75, 0xe0, 0xb2, 0xe, 0x46, 0x15, 0x75, 0xb8}, - output384: []byte{0x81, 0xed, 0xf0, 0x6e, 0x9b, 0x64, 0xf3, 0x1, 0x6b, 0x15, 0x47, 0x53, 0x5a, 0xba, 0x4d, 0xb0, 0x87, 0x60, 0xfd, 0x23, 0xe9, 0x58, 0x1, 0x63, 0x19, 0x2f, 0x66, 0x3f, 0xf6, 0x21, 0x6, 0x0, 0x10, 0x6, 0xa1, 0x39, 0x3c, 0xf2, 0xd, 0xe4, 0x65, 0x6d, 0xbc, 0xb0, 0x29, 0xfb, 0x63, 0x14}, - output512: []byte{0xef, 0x8a, 0xaf, 0x8, 0x15, 0x9b, 0xbc, 0xb8, 0x8e, 0xfa, 0xc4, 0x9a, 0x33, 0xa5, 0x24, 0x8b, 0x7e, 0xd0, 0x54, 0x49, 0x60, 0xd8, 0xdd, 0x54, 0xd7, 0x48, 0xa9, 0x1c, 0xd, 0x84, 0xc6, 0x9f, 0x30, 0x8b, 0xb5, 0x4c, 0xb5, 0xec, 0x97, 0xd3, 0xf8, 0x1c, 0xdf, 0x76, 0xe6, 0x8e, 0x3, 0x20, 0x81, 0x5b, 0x93, 0xf2, 0xa0, 0x9, 0x42, 0xf2, 0x16, 0x8c, 0xbc, 0x18, 0xe8, 0x37, 0x77, 0x8}}, - testcase{ - msg: []byte{0xe9, 0x26, 0xae, 0x8b, 0xa, 0xf6, 0xe5, 0x31, 0x76, 0xdb, 0xff, 0xcc, 0x2a, 0x6b, 0x88, 0xc6, 0xbd, 0x76, 0x5f, 0x93, 0x9d, 0x3d, 0x17, 0x8a, 0x9b, 0xde, 0x9e, 0xf3, 0xaa, 0x13, 0x1c, 0x61, 0xe3, 0x1c, 0x1e, 0x42, 0xcd, 0xfa, 0xf4, 0xb4, 0xdc, 0xde, 0x57, 0x9a, 0x37, 0xe1, 0x50, 0xef, 0xbe, 0xf5, 0x55, 0x5b, 0x4c, 0x1c, 0xb4, 0x4, 0x39, 0xd8, 0x35, 0xa7, 0x24, 0xe2, 0xfa, 0xe7}, - output224: []byte{0xc5, 0x33, 0xdc, 0xf8, 0x8c, 0xd1, 0xa5, 0xdf, 0xf2, 0x2b, 0x91, 0x4d, 0x38, 0x75, 0xbd, 0x57, 0xfc, 0x17, 0xb2, 0xe1, 0xf4, 0x74, 0xae, 0x36, 0xc, 0x38, 0x77, 0xd2}, - output256: []byte{0x57, 0x42, 0x71, 0xcd, 0x13, 0x95, 0x9e, 0x8d, 0xde, 0xae, 0x5b, 0xfb, 0xdb, 0x2, 0xa3, 0xfd, 0xf5, 0x4f, 0x2b, 0xab, 0xfd, 0xc, 0xbe, 0xb8, 0x93, 0x8, 0x2a, 0x97, 0x49, 0x57, 0xd0, 0xc1}, - output384: []byte{0x14, 0xaa, 0x67, 0x9b, 0xc, 0x11, 0xf9, 0xc3, 0x63, 0xf5, 0x49, 0x33, 0x2, 0x61, 0xb4, 0x5e, 0x1e, 0x90, 0xce, 0x31, 0xf4, 0xa1, 0xb0, 0xce, 0x5c, 0xb9, 0xeb, 0x81, 0xbd, 0x60, 0x79, 0xa3, 0x74, 0x2d, 0x86, 0x2, 0x35, 0x6c, 0x50, 0x98, 0x5d, 0xd, 0x3e, 0x54, 0xf, 0xdf, 0xdc, 0xfb}, - output512: []byte{0xc0, 0xa4, 0xd8, 0xdc, 0xa9, 0x67, 0x77, 0x2d, 0xbf, 0x6e, 0x55, 0x8, 0xc9, 0x13, 0xe7, 0xbe, 0xba, 0x1b, 0x74, 0x9a, 0x2b, 0x1a, 0xc9, 0x63, 0xd0, 0x67, 0x6e, 0x6f, 0x1d, 0xcd, 0x4e, 0xba, 0xa3, 0xf9, 0x9, 0xef, 0x87, 0xdd, 0x84, 0x98, 0x82, 0xdc, 0x82, 0x53, 0x34, 0x7a, 0x5f, 0x65, 0x20, 0xb5, 0xb9, 0xf5, 0x10, 0x97, 0x3f, 0x44, 0x39, 0x76, 0x45, 0x5f, 0x92, 0x3c, 0xfc, 0xb9}}, - testcase{ - msg: []byte{0x16, 0xe8, 0xb3, 0xd8, 0xf9, 0x88, 0xe9, 0xbb, 0x4, 0xde, 0x9c, 0x96, 0xf2, 0x62, 0x78, 0x11, 0xc9, 0x73, 0xce, 0x4a, 0x52, 0x96, 0xb4, 0x77, 0x2c, 0xa3, 0xee, 0xfe, 0xb8, 0xa, 0x65, 0x2b, 0xdf, 0x21, 0xf5, 0xd, 0xf7, 0x9f, 0x32, 0xdb, 0x23, 0xf9, 0xf7, 0x3d, 0x39, 0x3b, 0x2d, 0x57, 0xd9, 0xa0, 0x29, 0x7f, 0x7a, 0x2f, 0x2e, 0x79, 0xcf, 0xda, 0x39, 0xfa, 0x39, 0x3d, 0xf1, 0xac, 0x0}, - output224: []byte{0xc9, 0xb7, 0xad, 0x7a, 0x32, 0xb7, 0xd, 0xfb, 0x5a, 0x8a, 0x2f, 0xf9, 0xd9, 0x8b, 0x30, 0xe, 0x48, 0x4b, 0x99, 0x6e, 0xd7, 0x52, 0xa7, 0x32, 0xd8, 0x4d, 0xb6, 0xf7}, - output256: []byte{0x19, 0x47, 0xe9, 0x1, 0xfa, 0x59, 0xea, 0x78, 0x98, 0x45, 0x77, 0x5f, 0x2a, 0x4d, 0xb9, 0xb4, 0x84, 0x8f, 0x8a, 0x77, 0x60, 0x73, 0xd5, 0x3d, 0x84, 0xcb, 0xd5, 0xd9, 0x27, 0xa9, 0x6b, 0xff}, - output384: []byte{0xe4, 0x30, 0xce, 0x80, 0xbc, 0xc6, 0x1d, 0x87, 0xfd, 0xe0, 0xa2, 0x78, 0xcf, 0xf5, 0x4d, 0x73, 0xc, 0x3, 0xa0, 0x33, 0x77, 0xf4, 0xac, 0x10, 0xb9, 0x3e, 0xd5, 0x9c, 0x58, 0x80, 0x11, 0x7a, 0xcb, 0x20, 0xf1, 0x70, 0x5a, 0xef, 0xd2, 0x9b, 0xe0, 0x33, 0xd2, 0xf2, 0x2, 0x59, 0x46, 0x55}, - output512: []byte{0xcf, 0x3, 0xc9, 0x46, 0xeb, 0x70, 0x22, 0xf6, 0xf, 0xb5, 0x43, 0x94, 0x62, 0xac, 0x22, 0x68, 0x4e, 0x47, 0xea, 0xac, 0xbf, 0xfe, 0x19, 0xb7, 0x97, 0x76, 0xb, 0x4a, 0x24, 0xa5, 0x23, 0x8b, 0xe9, 0xd9, 0xe, 0x17, 0xd4, 0xe, 0xa6, 0xfe, 0x7b, 0x28, 0x85, 0xce, 0xf7, 0xdf, 0xb8, 0xbb, 0x48, 0x94, 0x1, 0xca, 0xa9, 0x4f, 0x2d, 0xd6, 0xe0, 0x45, 0x92, 0xe3, 0x3e, 0x76, 0xb9, 0xd1}}, - testcase{ - msg: []byte{0xfc, 0x42, 0x4e, 0xeb, 0x27, 0xc1, 0x8a, 0x11, 0xc0, 0x1f, 0x39, 0xc5, 0x55, 0xd8, 0xb7, 0x8a, 0x80, 0x5b, 0x88, 0xdb, 0xa1, 0xdc, 0x2a, 0x42, 0xed, 0x5e, 0x2c, 0xe, 0xc7, 0x37, 0xff, 0x68, 0xb2, 0x45, 0x6d, 0x80, 0xeb, 0x85, 0xe1, 0x17, 0x14, 0xfa, 0x3f, 0x8e, 0xab, 0xfb, 0x90, 0x6d, 0x3c, 0x17, 0x96, 0x4c, 0xb4, 0xf5, 0xe7, 0x6b, 0x29, 0xc1, 0x76, 0x5d, 0xb0, 0x3d, 0x91, 0xbe, 0x37, 0xfc}, - output224: []byte{0xcf, 0x64, 0x6d, 0x5e, 0x5c, 0x81, 0x81, 0x8c, 0x97, 0xa0, 0x1f, 0x39, 0x3f, 0x80, 0x33, 0xce, 0x3c, 0xb7, 0xcc, 0xd0, 0x7f, 0xda, 0xc9, 0x98, 0x87, 0x66, 0xbd, 0x1c}, - output256: []byte{0xc, 0x1b, 0x8c, 0x1a, 0xf2, 0x37, 0xe9, 0xc5, 0x50, 0x1b, 0x50, 0x31, 0x6a, 0x80, 0x86, 0x5a, 0xac, 0x8, 0xa3, 0x4a, 0xcf, 0x4f, 0x8b, 0xed, 0xd4, 0xa2, 0xd6, 0xe7, 0xb7, 0xbc, 0xbb, 0x85}, - output384: []byte{0xc9, 0xf7, 0x4a, 0xc4, 0x7f, 0x91, 0x46, 0xf0, 0x91, 0xde, 0x63, 0x9, 0x35, 0x7f, 0x3c, 0x2a, 0xf3, 0xa9, 0xc4, 0x47, 0x4c, 0xc0, 0x5, 0xae, 0xfa, 0xce, 0x3c, 0x7a, 0x55, 0x2b, 0x61, 0x27, 0xe3, 0x4e, 0xc8, 0x2c, 0x3a, 0xfc, 0xaa, 0xcd, 0xd8, 0x3e, 0x69, 0x5c, 0xb8, 0x62, 0x41, 0xe4}, - output512: []byte{0x2c, 0x35, 0xf1, 0xa5, 0x7a, 0x17, 0xcb, 0x29, 0x40, 0x3a, 0x2b, 0x40, 0xfc, 0x30, 0x7b, 0xde, 0x10, 0xba, 0x8f, 0x7f, 0xec, 0x7b, 0x94, 0xe1, 0xe4, 0x2e, 0xb4, 0xee, 0xb9, 0x52, 0xaa, 0xd0, 0xe, 0xc4, 0x6a, 0x26, 0x64, 0x6c, 0xd5, 0x1d, 0xb0, 0xc6, 0xb2, 0x38, 0x18, 0x9d, 0x7d, 0x47, 0xe, 0x21, 0xc2, 0x9b, 0xf8, 0x71, 0x4, 0x23, 0xcb, 0x56, 0x2, 0xca, 0xb7, 0x5e, 0x29, 0xe7}}, - testcase{ - msg: []byte{0xab, 0xe3, 0x47, 0x2b, 0x54, 0xe7, 0x27, 0x34, 0xbd, 0xba, 0x7d, 0x91, 0x58, 0x73, 0x64, 0x64, 0x25, 0x1c, 0x4f, 0x21, 0xb3, 0x3f, 0xbb, 0xc9, 0x2d, 0x7f, 0xac, 0x9a, 0x35, 0xc4, 0xe3, 0x32, 0x2f, 0xf0, 0x1d, 0x23, 0x80, 0xcb, 0xaa, 0x4e, 0xf8, 0xfb, 0x7, 0xd2, 0x1a, 0x21, 0x28, 0xb7, 0xb9, 0xf5, 0xb6, 0xd9, 0xf3, 0x4e, 0x13, 0xf3, 0x9c, 0x7f, 0xfc, 0x2e, 0x72, 0xe4, 0x78, 0x88, 0x59, 0x9b, 0xa5}, - output224: []byte{0xd4, 0x11, 0xe8, 0xa7, 0xcf, 0x50, 0xaa, 0xf9, 0x10, 0x76, 0xa8, 0xcc, 0x5f, 0x1, 0xbf, 0x5b, 0x6b, 0xb2, 0xcc, 0xae, 0x80, 0x46, 0xbf, 0x47, 0x87, 0x18, 0x91, 0xfd}, - output256: []byte{0xc4, 0x31, 0x56, 0x66, 0xc7, 0x1f, 0xea, 0x83, 0x4d, 0x8f, 0xf2, 0x7f, 0x2, 0x5f, 0x5c, 0xc3, 0x4f, 0x37, 0xc1, 0xaa, 0xe7, 0x86, 0x4, 0xa4, 0xb0, 0x8d, 0xac, 0x45, 0xde, 0xcd, 0x42, 0xbe}, - output384: []byte{0xc4, 0x2e, 0xcc, 0x88, 0x63, 0x7, 0x7a, 0xbf, 0xf6, 0x89, 0x41, 0x3c, 0xe3, 0x7b, 0x61, 0xf0, 0x43, 0x6d, 0xdb, 0x62, 0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x80, 0xe3, 0xcb, 0x4d, 0x78, 0xf1, 0x8e, 0x30, 0x11, 0x17, 0xc4}, - output256: []byte{0x5f, 0xf8, 0x73, 0x4d, 0xb3, 0xf9, 0x97, 0x7e, 0xee, 0x9c, 0xf5, 0xe2, 0xcf, 0x72, 0x5c, 0x57, 0xaf, 0x9, 0x92, 0x64, 0x90, 0xc5, 0x5a, 0xbd, 0x9d, 0x0, 0xa4, 0x2e, 0x91, 0xa8, 0xc3, 0x44}, - output384: []byte{0xb1, 0x53, 0x92, 0x71, 0x8c, 0xbf, 0x4a, 0x7c, 0x7f, 0xad, 0x1c, 0x15, 0xe7, 0xf2, 0x6c, 0x44, 0x6e, 0x79, 0xd5, 0x42, 0x51, 0x40, 0x4e, 0x64, 0x6b, 0x4d, 0xca, 0x3d, 0x42, 0x14, 0x2e, 0xd5, 0x14, 0xd, 0xd, 0x30, 0xbd, 0x83, 0x6c, 0x7d, 0x51, 0x3c, 0xe6, 0xf5, 0xe1, 0x4, 0xd4, 0x2d}, - output512: []byte{0x7b, 0xe2, 0xc9, 0x54, 0x13, 0xc5, 0x89, 0xec, 0x5a, 0xd6, 0x9f, 0x8d, 0x80, 0xbf, 0xe9, 0xf2, 0x65, 0x40, 0xd5, 0xc1, 0x83, 0x2c, 0x7a, 0x49, 0xa3, 0x1a, 0x8f, 0x56, 0x55, 0xd9, 0xce, 0x8b, 0x47, 0xd9, 0x7c, 0x69, 0xcc, 0xcd, 0x69, 0x3c, 0x21, 0x19, 0x4, 0x14, 0x2a, 0x54, 0x3, 0xda, 0x7a, 0xd0, 0x9f, 0xbd, 0xb8, 0x25, 0x69, 0x8f, 0xe2, 0x1, 0x98, 0x8f, 0xcc, 0xcd, 0x2b, 0xb2}}, - testcase{ - msg: []byte{0xab, 0xc8, 0x77, 0x63, 0xca, 0xe1, 0xca, 0x98, 0xbd, 0x8c, 0x5b, 0x82, 0xca, 0xba, 0x54, 0xac, 0x83, 0x28, 0x6f, 0x87, 0xe9, 0x61, 0x1, 0x28, 0xae, 0x4d, 0xe6, 0x8a, 0xc9, 0x5d, 0xf5, 0xe3, 0x29, 0xc3, 0x60, 0x71, 0x7b, 0xd3, 0x49, 0xf2, 0x6b, 0x87, 0x25, 0x28, 0x49, 0x2c, 0xa7, 0xc9, 0x4c, 0x2c, 0x1e, 0x1e, 0xf5, 0x6b, 0x74, 0xdb, 0xb6, 0x5c, 0x2a, 0xc3, 0x51, 0x98, 0x1f, 0xdb, 0x31, 0xd0, 0x6c, 0x77, 0xa4}, - output224: []byte{0x51, 0x94, 0x8e, 0x17, 0x72, 0xc2, 0xc2, 0xee, 0x49, 0x15, 0x8d, 0x2, 0xa9, 0x75, 0xb2, 0x74, 0x77, 0xbd, 0x4, 0x12, 0x62, 0x95, 0x4c, 0x3e, 0x60, 0xf5, 0xac, 0xc2}, - output256: []byte{0x1e, 0x14, 0x1a, 0x17, 0x1c, 0xab, 0x8, 0x52, 0x52, 0xea, 0x4c, 0x2f, 0x8f, 0x1f, 0x10, 0x87, 0xdd, 0x85, 0xa7, 0x5a, 0xb3, 0xac, 0xd0, 0xb3, 0xc2, 0x8e, 0xaa, 0x57, 0x35, 0xd3, 0x49, 0xaf}, - output384: []byte{0xe0, 0x32, 0x94, 0xc6, 0x8e, 0xdf, 0x4e, 0x88, 0x26, 0xb6, 0x99, 0xab, 0xdd, 0xbe, 0xf7, 0x54, 0x67, 0xc4, 0x9c, 0xab, 0x56, 0xe0, 0x85, 0xe4, 0xb8, 0x3a, 0x58, 0xb2, 0xd9, 0xbd, 0xfa, 0xc9, 0xd5, 0x8b, 0x45, 0xaa, 0xcc, 0xe, 0xc0, 0xce, 0x2d, 0x6d, 0x79, 0x68, 0x6a, 0x41, 0xac, 0x13}, - output512: []byte{0x8a, 0xac, 0x92, 0x1, 0xd7, 0x6d, 0xf1, 0x34, 0x24, 0xa3, 0x25, 0x52, 0xf0, 0x43, 0x90, 0xe4, 0x99, 0xb6, 0x16, 0x87, 0x11, 0xb7, 0xc, 0x87, 0x57, 0x89, 0xdd, 0xaa, 0x9b, 0x11, 0x5f, 0x8b, 0x82, 0x59, 0xa6, 0xd, 0x17, 0x83, 0x5e, 0x25, 0x87, 0xf8, 0x90, 0x1c, 0x3c, 0xa7, 0x82, 0xda, 0x9a, 0xfb, 0x28, 0xba, 0x87, 0xb9, 0xfc, 0xbe, 0x5, 0xa4, 0x7a, 0x42, 0xf4, 0x8f, 0xcd, 0x48}}, - testcase{ - msg: []byte{0x94, 0xf7, 0xca, 0x8e, 0x1a, 0x54, 0x23, 0x4c, 0x6d, 0x53, 0xcc, 0x73, 0x4b, 0xb3, 0xd3, 0x15, 0xc, 0x8b, 0xa8, 0xc5, 0xf8, 0x80, 0xea, 0xb8, 0xd2, 0x5f, 0xed, 0x13, 0x79, 0x3a, 0x97, 0x1, 0xeb, 0xe3, 0x20, 0x50, 0x92, 0x86, 0xfd, 0x8e, 0x42, 0x2e, 0x93, 0x1d, 0x99, 0xc9, 0x8d, 0xa4, 0xdf, 0x7e, 0x70, 0xae, 0x44, 0x7b, 0xab, 0x8c, 0xff, 0xd9, 0x23, 0x82, 0xd8, 0xa7, 0x77, 0x60, 0xa2, 0x59, 0xfc, 0x4f, 0xbd, 0x72}, - output224: []byte{0x82, 0x14, 0xa2, 0xb0, 0xe8, 0xbb, 0x60, 0xcd, 0x3e, 0x4d, 0xfb, 0xd, 0x8, 0x55, 0xd0, 0xf6, 0xc4, 0xba, 0x6d, 0x27, 0x28, 0xd0, 0x68, 0x7b, 0xdf, 0x75, 0xf7, 0x9e}, - output256: []byte{0xef, 0x76, 0x3f, 0x22, 0xf3, 0x59, 0xdd, 0x7f, 0x5b, 0x3f, 0xe6, 0xa7, 0x45, 0xc4, 0x23, 0xd6, 0xb6, 0x41, 0xec, 0x7, 0xba, 0x52, 0x35, 0x23, 0x2a, 0x7, 0x1, 0x51, 0xf, 0x74, 0x42, 0x6e}, - output384: []byte{0xd5, 0x53, 0x9d, 0x7a, 0xef, 0xf9, 0xf7, 0x4d, 0xc7, 0x5b, 0x6e, 0x95, 0xea, 0xde, 0x6, 0x3b, 0xe4, 0x19, 0xb1, 0x5a, 0x41, 0x79, 0xcf, 0xd0, 0x6d, 0x4f, 0xd2, 0x74, 0x1e, 0x22, 0xb2, 0xa2, 0x43, 0x95, 0xaa, 0xa1, 0xc0, 0x24, 0x2c, 0x99, 0x5e, 0xb5, 0xea, 0x89, 0x13, 0x47, 0xb4, 0xdb}, - output512: []byte{0xaa, 0x52, 0x58, 0x7d, 0x84, 0x58, 0x63, 0x17, 0x2, 0x8f, 0xb7, 0xd3, 0xc2, 0x8, 0x92, 0xe0, 0x28, 0x8b, 0xfe, 0x2f, 0xea, 0xbd, 0x76, 0xd7, 0xf8, 0x91, 0x55, 0xff, 0xe9, 0xcc, 0xbf, 0x1a, 0x9, 0xfa, 0xf, 0xfb, 0x5, 0x53, 0xe8, 0x3f, 0x79, 0xae, 0x58, 0xbd, 0x30, 0xa3, 0x5f, 0xa5, 0x48, 0x92, 0xb6, 0xab, 0xa0, 0x9, 0x3a, 0x1, 0x24, 0x27, 0xdd, 0xab, 0x71, 0xcd, 0xf8, 0x19}}, - testcase{ - msg: []byte{0x13, 0xbd, 0x28, 0x11, 0xf6, 0xed, 0x2b, 0x6f, 0x4, 0xff, 0x38, 0x95, 0xac, 0xee, 0xd7, 0xbe, 0xf8, 0xdc, 0xd4, 0x5e, 0xb1, 0x21, 0x79, 0x1b, 0xc1, 0x94, 0xa0, 0xf8, 0x6, 0x20, 0x6b, 0xff, 0xc3, 0xb9, 0x28, 0x1c, 0x2b, 0x30, 0x8b, 0x1a, 0x72, 0x9c, 0xe0, 0x8, 0x11, 0x9d, 0xd3, 0x6, 0x6e, 0x93, 0x78, 0xac, 0xdc, 0xc5, 0xa, 0x98, 0xa8, 0x2e, 0x20, 0x73, 0x88, 0x0, 0xb6, 0xcd, 0xdb, 0xe5, 0xfe, 0x96, 0x94, 0xad, 0x6d}, - output224: []byte{0x8a, 0x2a, 0xe6, 0xb9, 0xaa, 0x7b, 0x1e, 0x8, 0xf8, 0xc7, 0xdc, 0x3b, 0xf5, 0xae, 0x87, 0x66, 0x60, 0xd3, 0xf, 0x79, 0x39, 0x17, 0x14, 0xa1, 0x75, 0x38, 0x10, 0x91}, - output256: []byte{0x6a, 0x76, 0x9f, 0x93, 0xf2, 0x55, 0xb0, 0x78, 0xfe, 0x73, 0xaf, 0xf6, 0x8f, 0x4, 0x22, 0xa2, 0x79, 0x93, 0x99, 0x20, 0xe4, 0x69, 0xb, 0x4a, 0xff, 0xe, 0x43, 0x3c, 0xfa, 0x3d, 0x3d, 0xf3}, - output384: []byte{0xb1, 0x15, 0xa9, 0x96, 0x8b, 0x5, 0x4c, 0x93, 0x4c, 0x39, 0x6d, 0x81, 0x88, 0xba, 0xc, 0x33, 0xa2, 0x3c, 0x71, 0x89, 0xce, 0x88, 0xb1, 0xde, 0x4a, 0x6, 0xcd, 0x31, 0x97, 0x92, 0xd2, 0x86, 0x47, 0xea, 0xe1, 0xd8, 0x8f, 0xb0, 0xb8, 0x74, 0x43, 0xe4, 0x62, 0x92, 0xa5, 0xc6, 0x45, 0xe8}, - output512: []byte{0x48, 0xfc, 0x28, 0x2f, 0x37, 0xa3, 0xe1, 0xfb, 0x5d, 0xf4, 0xd2, 0xda, 0x1f, 0x71, 0x97, 0xec, 0x89, 0x9a, 0xe5, 0x73, 0xca, 0x8, 0xdf, 0x55, 0xe, 0x61, 0xee, 0x84, 0x7e, 0xeb, 0x1d, 0x24, 0xc0, 0x74, 0xff, 0x46, 0xbc, 0xae, 0xe2, 0x24, 0xec, 0x7d, 0x8c, 0xea, 0x42, 0x56, 0x15, 0x4f, 0xc, 0x4d, 0x43, 0x4e, 0x68, 0x28, 0x34, 0xf6, 0xd8, 0x27, 0xbf, 0xbd, 0xf7, 0x51, 0x12, 0xf5}}, - testcase{ - msg: []byte{0x1e, 0xed, 0x9c, 0xba, 0x17, 0x9a, 0x0, 0x9e, 0xc2, 0xec, 0x55, 0x8, 0x77, 0x3d, 0xd3, 0x5, 0x47, 0x7c, 0xa1, 0x17, 0xe6, 0xd5, 0x69, 0xe6, 0x6b, 0x5f, 0x64, 0xc6, 0xbc, 0x64, 0x80, 0x1c, 0xe2, 0x5a, 0x84, 0x24, 0xce, 0x4a, 0x26, 0xd5, 0x75, 0xb8, 0xa6, 0xfb, 0x10, 0xea, 0xd3, 0xfd, 0x19, 0x92, 0xed, 0xdd, 0xee, 0xc2, 0xeb, 0xe7, 0x15, 0xd, 0xc9, 0x8f, 0x63, 0xad, 0xc3, 0x23, 0x7e, 0xf5, 0x7b, 0x91, 0x39, 0x7a, 0xa8, 0xa7}, - output224: []byte{0x70, 0x2b, 0x19, 0x6, 0xa6, 0x3d, 0xf, 0x92, 0x4a, 0xfe, 0xc3, 0xbb, 0x5e, 0x5c, 0x57, 0x42, 0xe8, 0x5f, 0x98, 0x34, 0xea, 0x6f, 0x53, 0x6, 0x64, 0x48, 0x11, 0xa1}, - output256: []byte{0xc0, 0x6d, 0xd4, 0x26, 0x16, 0x38, 0xc4, 0x4a, 0xfc, 0xb1, 0x86, 0xf0, 0xaf, 0x5d, 0xe2, 0xe, 0xa5, 0x3a, 0xa6, 0x33, 0x16, 0xfb, 0xb7, 0x17, 0x28, 0xf8, 0x74, 0xff, 0x3d, 0xac, 0xeb, 0xd}, - output384: []byte{0xc8, 0xfa, 0xef, 0x75, 0x7e, 0x6d, 0x7b, 0xa, 0xf4, 0x6d, 0xa1, 0xe5, 0x7c, 0x71, 0xab, 0xb4, 0xaa, 0xf7, 0xcc, 0x91, 0xc5, 0xcd, 0xc3, 0x3b, 0xa8, 0xa7, 0x38, 0x17, 0x2b, 0x95, 0xde, 0x8, 0x7e, 0xc4, 0xc9, 0x26, 0x92, 0xcb, 0x40, 0xee, 0x37, 0x87, 0xbc, 0xe3, 0x20, 0x6f, 0xb7, 0xea}, - output512: []byte{0x6b, 0x4b, 0xf, 0x12, 0x68, 0x63, 0x55, 0x2a, 0x6f, 0x40, 0xf4, 0x5e, 0x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 0x8, 0x24, 0xf, 0xf6, 0x91, 0x31, 0xd8}, - output384: []byte{0xf4, 0xf2, 0x1b, 0xb7, 0x45, 0x93, 0xaa, 0x10, 0x7d, 0xc1, 0x95, 0xff, 0x52, 0xa3, 0xf9, 0x8, 0x16, 0xcc, 0xea, 0xe8, 0xd3, 0xeb, 0x9d, 0x45, 0x77, 0xb2, 0x8b, 0x49, 0xc3, 0x39, 0x83, 0x7a, 0x52, 0x70, 0xa, 0x62, 0xeb, 0x42, 0x1e, 0x8c, 0xa1, 0xc8, 0x7f, 0x45, 0x63, 0x10, 0xf6, 0x2c}, - output512: []byte{0x7e, 0xec, 0x7b, 0x73, 0x0, 0x56, 0xb1, 0xbd, 0x4f, 0x6f, 0xfc, 0x18, 0x6f, 0xb4, 0x55, 0x91, 0xe5, 0xc, 0xd9, 0x3c, 0xf6, 0xe4, 0xfc, 0x95, 0x88, 0x89, 0xf8, 0x2d, 0x3f, 0x32, 0xc5, 0xc7, 0x4d, 0x3, 0xa4, 0xbc, 0xf7, 0xd2, 0x75, 0x42, 0x98, 0xf1, 0x34, 0x69, 0x8a, 0xf4, 0x55, 0x9b, 0xe, 0x29, 0xba, 0xaa, 0x36, 0x5c, 0xc0, 0xd, 0xb0, 0xd5, 0x1d, 0x40, 0x71, 0x79, 0xc5, 0x6d}}, - testcase{ - msg: []byte{0xe, 0xfa, 0x26, 0xac, 0x56, 0x73, 0x16, 0x7d, 0xca, 0xca, 0xb8, 0x60, 0x93, 0x2e, 0xd6, 0x12, 0xf6, 0x5f, 0xf4, 0x9b, 0x80, 0xfa, 0x9a, 0xe6, 0x54, 0x65, 0xe5, 0x54, 0x2c, 0xb6, 0x20, 0x75, 0xdf, 0x1c, 0x5a, 0xe5, 0x4f, 0xba, 0x4d, 0xb8, 0x7, 0xbe, 0x25, 0xb0, 0x70, 0x3, 0x3e, 0xfa, 0x22, 0x3b, 0xdd, 0x5b, 0x1d, 0x3c, 0x94, 0xc6, 0xe1, 0x90, 0x9c, 0x2, 0xb6, 0x20, 0xd4, 0xb1, 0xb3, 0xa6, 0xc9, 0xfe, 0xd2, 0x4d, 0x70, 0x74, 0x96, 0x4}, - output224: []byte{0xb0, 0x7a, 0xdb, 0xed, 0x91, 0x27, 0x23, 0xa0, 0x7f, 0xa5, 0x35, 0x3f, 0x66, 0x5e, 0xc1, 0x4f, 0xf8, 0x2d, 0x85, 0xe9, 0xb, 0xe3, 0xe5, 0xa1, 0xf5, 0xc9, 0xf, 0xff}, - output256: []byte{0xca, 0xd7, 0xab, 0xb5, 0xbb, 0xa5, 0x90, 0x5b, 0x51, 0x81, 0xdd, 0x2d, 0xbc, 0x4e, 0x68, 0xcf, 0xd0, 0x1b, 0xa8, 0x65, 0x9f, 0x21, 0xc8, 0x29, 0xd, 0x3f, 0x83, 0x5c, 0x1a, 0x68, 0xbb, 0xe5}, - output384: []byte{0x83, 0x54, 0x45, 0x11, 0xa0, 0x7f, 0x60, 0x58, 0xd9, 0xfe, 0x5a, 0xad, 0x7e, 0xa8, 0x37, 0xa9, 0xe1, 0x80, 0xd8, 0xbb, 0xb8, 0x84, 0xc5, 0x65, 0xb, 0x79, 0x89, 0x42, 0x98, 0x3a, 0x60, 0x5a, 0x51, 0x4c, 0x21, 0xd8, 0xd6, 0x3d, 0xb0, 0xe2, 0x5a, 0xae, 0x51, 0xd2, 0x6f, 0x41, 0xb, 0xc5}, - output512: []byte{0x79, 0xcb, 0x92, 0x5a, 0xca, 0x7, 0x2e, 0xbb, 0x3b, 0x49, 0xa9, 0xd0, 0xe5, 0x9b, 0xb0, 0x7d, 0xd1, 0xc2, 0x23, 0xc1, 0xf2, 0x6c, 0x91, 0x76, 0x8b, 0x92, 0x94, 0x72, 0xc5, 0x1b, 0x97, 0x7f, 0x85, 0xc6, 0xce, 0xeb, 0x54, 0xbc, 0xe8, 0x9c, 0xf9, 0xff, 0x61, 0x55, 0xd7, 0xfe, 0x80, 0x91, 0x54, 0xf, 0x13, 0x48, 0xce, 0x95, 0x92, 0xa6, 0x40, 0x3f, 0x92, 0x10, 0x54, 0x77, 0x87, 0xe}}, - testcase{ - msg: []byte{0xbb, 0xfd, 0x93, 0x3d, 0x1f, 0xd7, 0xbf, 0x59, 0x4a, 0xc7, 0xf4, 0x35, 0x27, 0x7d, 0xc1, 0x7d, 0x8d, 0x5a, 0x5b, 0x8e, 0x4d, 0x13, 0xd9, 0x6d, 0x2f, 0x64, 0xe7, 0x71, 0xab, 0xbd, 0x51, 0xa5, 0xa8, 0xae, 0xa7, 0x41, 0xbe, 0xcc, 0xbd, 0xdb, 0x17, 0x7b, 0xce, 0xa0, 0x52, 0x43, 0xeb, 0xd0, 0x3, 0xcf, 0xde, 0xae, 0x87, 0x7c, 0xca, 0x4d, 0xa9, 0x46, 0x5, 0xb6, 0x76, 0x91, 0x91, 0x9d, 0x8b, 0x3, 0x3f, 0x77, 0xd3, 0x84, 0xca, 0x1, 0x59, 0x3c, 0x1b}, - output224: []byte{0xd1, 0x71, 0x8f, 0xd, 0x38, 0x7a, 0xc4, 0x27, 0x11, 0x1a, 0x7e, 0x90, 0xe5, 0x75, 0xde, 0x5f, 0x4, 0x77, 0x8e, 0xa2, 0xba, 0x14, 0x7a, 0x84, 0x51, 0x91, 0x4f, 0xf0}, - output256: []byte{0x83, 0xca, 0x9, 0xc1, 0xf4, 0x18, 0xb5, 0xda, 0xd0, 0xa7, 0xf6, 0x4a, 0x90, 0x4a, 0x2e, 0x7, 0xc3, 0x31, 0x4f, 0x7d, 0x2, 0xd9, 0x26, 0x22, 0xf8, 0xf4, 0x67, 0x4b, 0xc1, 0xf6, 0xaa, 0x3d}, - output384: []byte{0x8e, 0xcd, 0x84, 0x59, 0xfb, 0x90, 0x4d, 0x2e, 0xdd, 0xb1, 0x42, 0x7, 0x65, 0x9c, 0x2b, 0xf9, 0x6e, 0xfb, 0xd3, 0xe4, 0xc8, 0x98, 0x87, 0x36, 0xec, 0x75, 0x8, 0x8f, 0x1c, 0xc8, 0x11, 0x5d, 0x3f, 0xff, 0xc8, 0xce, 0xdf, 0x1c, 0x1, 0x72, 0x14, 0x69, 0xd2, 0x79, 0x68, 0xa6, 0x85, 0x6b}, - output512: []byte{0xb5, 0xd1, 0xed, 0x8f, 0x3, 0x90, 0x44, 0xbc, 0xfe, 0xf4, 0x1e, 0x99, 0xb2, 0xf5, 0x64, 0xf4, 0x59, 0x91, 0xb3, 0x29, 0xb5, 0x3, 0xfc, 0x91, 0xfa, 0x29, 0xd2, 0x40, 0x85, 0x12, 0xf8, 0x71, 0x1e, 0x9d, 0xb6, 0x6f, 0x8a, 0xe1, 0x72, 0x16, 0x46, 0x50, 0x54, 0x5a, 0xe9, 0xe3, 0xdb, 0x32, 0xaa, 0x36, 0x9e, 0xc4, 0x7e, 0x81, 0xa7, 0x71, 0x11, 0x27, 0x6e, 0x6c, 0xa3, 0x8e, 0x4d, 0x92}}, - testcase{ - msg: []byte{0x90, 0x7, 0x89, 0x99, 0xfd, 0x3c, 0x35, 0xb8, 0xaf, 0xbf, 0x40, 0x66, 0xcb, 0xde, 0x33, 0x58, 0x91, 0x36, 0x5f, 0xf, 0xc7, 0x5c, 0x12, 0x86, 0xcd, 0xd8, 0x8f, 0xa5, 0x1f, 0xab, 0x94, 0xf9, 0xb8, 0xde, 0xf7, 0xc9, 0xac, 0x58, 0x2a, 0x5d, 0xbc, 0xd9, 0x58, 0x17, 0xaf, 0xb7, 0xd1, 0xb4, 0x8f, 0x63, 0x70, 0x4e, 0x19, 0xc2, 0xba, 0xa4, 0xdf, 0x34, 0x7f, 0x48, 0xd4, 0xa6, 0xd6, 0x3, 0x1, 0x3c, 0x23, 0xf1, 0xe9, 0x61, 0x1d, 0x59, 0x5e, 0xba, 0xc3, 0x7c}, - output224: []byte{0xfa, 0xf7, 0xd7, 0x93, 0x2, 0x4e, 0x6d, 0x5, 0xe7, 0x7c, 0x52, 0x31, 0x71, 0x24, 0x78, 0x82, 0x2c, 0x91, 0x52, 0x92, 0xfc, 0xc1, 0x42, 0x7e, 0x6a, 0xcf, 0xd3, 0xcf}, - output256: []byte{0x33, 0xd, 0xe3, 0xee, 0x16, 0xae, 0xf6, 0x71, 0x14, 0x61, 0xa9, 0x94, 0x86, 0x3e, 0xed, 0x47, 0xaf, 0x71, 0xb3, 0x62, 0xd4, 0xc2, 0xf2, 0x43, 0x53, 0x4e, 0xf4, 0x32, 0xf6, 0x3a, 0x9, 0x1a}, - output384: []byte{0xbe, 0x60, 0x24, 0x6e, 0x27, 0x95, 0x9d, 0xc8, 0x6, 0x5c, 0x6d, 0x4d, 0xca, 0xc9, 0x3e, 0xb7, 0xf7, 0x14, 0x6b, 0x49, 0xc7, 0x59, 0xbf, 0x1d, 0xd5, 0xeb, 0xa4, 0x6a, 0x3e, 0xcf, 0x7, 0x47, 0x84, 0xa9, 0xdf, 0x18, 0xde, 0xab, 0x7a, 0x19, 0xaf, 0x7f, 0x62, 0x90, 0xcd, 0xac, 0xa8, 0x7b}, - output512: []byte{0x78, 0x2c, 0x0, 0x8a, 0x9e, 0xe3, 0xdd, 0xa0, 0xa1, 0x82, 0x26, 0x71, 0x85, 0xc9, 0x95, 0xa2, 0xaf, 0x73, 0x7b, 0xa8, 0xcb, 0x2f, 0x61, 0x79, 0xf2, 0xcd, 0xf5, 0x25, 0x5, 0xf8, 0xd9, 0x33, 0xe7, 0x12, 0xfc, 0x4e, 0x56, 0xd1, 0xe, 0x17, 0x5e, 0xc8, 0xcd, 0xd6, 0x2d, 0xe6, 0x52, 0x9c, 0xe1, 0xf0, 0x78, 0xbf, 0xa0, 0xdc, 0x7a, 0x52, 0x84, 0xf8, 0xc5, 0x65, 0x18, 0x2f, 0x85, 0xd9}}, - testcase{ - msg: []byte{0x64, 0x10, 0x5e, 0xca, 0x86, 0x35, 0x15, 0xc2, 0xe, 0x7c, 0xfb, 0xaa, 0xa, 0xb, 0x88, 0x9, 0x4, 0x61, 0x64, 0xf3, 0x74, 0xd6, 0x91, 0xcd, 0xbd, 0x65, 0x8, 0xaa, 0xab, 0xc1, 0x81, 0x9f, 0x9a, 0xc8, 0x4b, 0x52, 0xba, 0xfc, 0x1b, 0xf, 0xe7, 0xcd, 0xdb, 0xc5, 0x54, 0xb6, 0x8, 0xc0, 0x1c, 0x89, 0x4, 0xc6, 0x69, 0xd8, 0xdb, 0x31, 0x6a, 0x9, 0x53, 0xa4, 0xc6, 0x8e, 0xce, 0x32, 0x4e, 0xc5, 0xa4, 0x9f, 0xfd, 0xb5, 0x9a, 0x1b, 0xd6, 0xa2, 0x92, 0xaa, 0xe}, - output224: []byte{0xa3, 0x75, 0xd7, 0x56, 0xa8, 0xf3, 0x9c, 0x72, 0xf6, 0x7c, 0xa4, 0x89, 0xc9, 0x5f, 0x99, 0x35, 0xf, 0xfd, 0x5, 0x15, 0xb1, 0x51, 0xa3, 0xbf, 0xf2, 0x88, 0xca, 0xaa}, - output256: []byte{0xb5, 0x67, 0x51, 0x97, 0xe4, 0x9b, 0x35, 0x72, 0x18, 0xf7, 0x11, 0x8c, 0xd1, 0x5e, 0xe7, 0x73, 0xb3, 0x9b, 0xd5, 0x9b, 0x22, 0x4d, 0x9a, 0x45, 0xca, 0x71, 0xc6, 0xe3, 0x71, 0xd9, 0x38, 0xf1}, - output384: []byte{0x92, 0x35, 0xba, 0x18, 0xc5, 0x5e, 0x2c, 0xbc, 0xa0, 0xfb, 0x1d, 0xa3, 0xbc, 0x8d, 0xd, 0xfd, 0x84, 0x8c, 0xa0, 0xe5, 0x1d, 0xdc, 0x10, 0x20, 0xd4, 0xbe, 0xcc, 0xf, 0x13, 0x8d, 0xa1, 0x8, 0x79, 0x29, 0xfe, 0xc9, 0x3a, 0xf1, 0x6f, 0x5f, 0xb2, 0x9c, 0x4a, 0x77, 0x7d, 0xd9, 0x15, 0x48}, - output512: []byte{0x91, 0xa0, 0x24, 0x1e, 0xda, 0x8c, 0xa5, 0x97, 0xcb, 0xb0, 0xf7, 0x3, 0xab, 0x7d, 0xba, 0xaf, 0x85, 0x9c, 0xff, 0x77, 0xb2, 0x4, 0x1, 0xad, 0x46, 0x23, 0xc, 0xe3, 0xb2, 0xbe, 0xef, 0x66, 0x85, 0x77, 0x5d, 0xe3, 0x75, 0x76, 0x1, 0x4d, 0x8d, 0xa1, 0xba, 0x67, 0x2d, 0x47, 0xaa, 0xd9, 0x5f, 0xb5, 0x3c, 0x59, 0xb, 0x65, 0x6, 0x34, 0xce, 0xbb, 0x43, 0xa1, 0x75, 0x73, 0x85, 0x69}}, - testcase{ - msg: []byte{0xd4, 0x65, 0x4b, 0xe2, 0x88, 0xb9, 0xf3, 0xb7, 0x11, 0xc2, 0xd0, 0x20, 0x15, 0x97, 0x8a, 0x8c, 0xc5, 0x74, 0x71, 0xd5, 0x68, 0xa, 0x9, 0x2a, 0xa5, 0x34, 0xf7, 0x37, 0x2c, 0x71, 0xce, 0xaa, 0xb7, 0x25, 0xa3, 0x83, 0xc4, 0xfc, 0xf4, 0xd8, 0xde, 0xaa, 0x57, 0xfc, 0xa3, 0xce, 0x5, 0x6f, 0x31, 0x29, 0x61, 0xec, 0xcf, 0x9b, 0x86, 0xf1, 0x49, 0x81, 0xba, 0x5b, 0xed, 0x6a, 0xb5, 0xb4, 0x49, 0x8e, 0x1f, 0x6c, 0x82, 0xc6, 0xca, 0xe6, 0xfc, 0x14, 0x84, 0x5b, 0x3c, 0x8a}, - output224: []byte{0x1b, 0xd1, 0xb6, 0xf3, 0x14, 0x4a, 0x3d, 0xee, 0x93, 0xde, 0xa1, 0xdf, 0x3, 0xc0, 0xe9, 0x58, 0xf4, 0x85, 0xb8, 0xae, 0x16, 0x4d, 0xce, 0xe5, 0x5f, 0x97, 0x34, 0x13}, - output256: []byte{0xcd, 0x90, 0x38, 0xc1, 0x6, 0x6a, 0x59, 0x99, 0xd, 0xf5, 0x75, 0x21, 0x7, 0xb0, 0x66, 0xee, 0xbb, 0xe6, 0x72, 0xcb, 0xca, 0xf, 0x60, 0xd6, 0x87, 0xd0, 0x3a, 0x9d, 0x82, 0x19, 0x34, 0xbe}, - output384: []byte{0x8, 0x73, 0x9d, 0xd8, 0x66, 0xc6, 0x21, 0x6a, 0xdc, 0xa2, 0x6d, 0x61, 0x21, 0xe5, 0xd8, 0x1f, 0xdb, 0x1f, 0x7b, 0xcd, 0x48, 0x2, 0xc2, 0xb8, 0x11, 0xd7, 0x3c, 0x28, 0x22, 0x77, 0xd4, 0x1, 0x4b, 0x49, 0x36, 0xe5, 0x58, 0x9f, 0x62, 0x27, 0x9b, 0xb3, 0x30, 0x75, 0x70, 0x57, 0x95, 0xf8}, - output512: []byte{0x0, 0xb0, 0x2d, 0xbc, 0xb7, 0xa3, 0xbc, 0x11, 0x77, 0x1, 0xf2, 0xf1, 0x59, 0xfc, 0x44, 0x92, 0x92, 0x3c, 0x43, 0x7d, 0x33, 0x69, 0x83, 0x3a, 0x9b, 0xd0, 0x9e, 0x78, 0xe2, 0x60, 0xd4, 0x8d, 0x37, 0x16, 0x8d, 0x36, 0xc4, 0x97, 0x77, 0xb2, 0xe6, 0x8e, 0x6f, 0xe9, 0x84, 0x61, 0x6, 0xa6, 0xab, 0x87, 0x68, 0xc3, 0x97, 0x1f, 0xab, 0x31, 0xfd, 0x92, 0x2a, 0xac, 0xb8, 0x7d, 0x1c, 0xac}}, - testcase{ - msg: []byte{0x12, 0xd9, 0x39, 0x48, 0x88, 0x30, 0x5a, 0xc9, 0x6e, 0x65, 0xf2, 0xbf, 0xe, 0x1b, 0x18, 0xc2, 0x9c, 0x90, 0xfe, 0x9d, 0x71, 0x4d, 0xd5, 0x9f, 0x65, 0x1f, 0x52, 0xb8, 0x8b, 0x30, 0x8, 0xc5, 0x88, 0x43, 0x55, 0x48, 0x6, 0x6e, 0xa2, 0xfc, 0x4c, 0x10, 0x11, 0x18, 0xc9, 0x1f, 0x32, 0x55, 0x62, 0x24, 0xa5, 0x40, 0xde, 0x6e, 0xfd, 0xdb, 0xca, 0x29, 0x6e, 0xf1, 0xfb, 0x0, 0x34, 0x1f, 0x5b, 0x1, 0xfe, 0xcf, 0xc1, 0x46, 0xbd, 0xb2, 0x51, 0xb3, 0xbd, 0xad, 0x55, 0x6c, 0xd2}, - output224: []byte{0xbe, 0x88, 0xb4, 0x95, 0xd0, 0xcd, 0x90, 0x28, 0x1a, 0xf2, 0x9, 0x4b, 0x8d, 0x7e, 0x72, 0xeb, 0x41, 0x72, 0x88, 0xca, 0x16, 0xf7, 0x51, 0xc0, 0x96, 0x94, 0xb6, 0x82}, - output256: []byte{0xd3, 0x17, 0x2c, 0xa2, 0x63, 0xaf, 0xf2, 0xb9, 0xdb, 0x6f, 0xb1, 0x33, 0x37, 0xf2, 0x54, 0x3c, 0x5a, 0xf5, 0x11, 0x51, 0x80, 0x1a, 0x76, 0x19, 0x40, 0x12, 0xf7, 0x10, 0x30, 0x6c, 0x14, 0xf6}, - output384: []byte{0xd2, 0xa2, 0xe8, 0x58, 0xa5, 0xdd, 0x85, 0xd6, 0x2e, 0x6f, 0x51, 0xaf, 0x7e, 0x42, 0x35, 0x2a, 0xc0, 0xd7, 0xa6, 0x8a, 0x83, 0x54, 0x31, 0xbc, 0xca, 0x47, 0x55, 0x7e, 0x3b, 0x5c, 0x33, 0x73, 0xf4, 0xd, 0x3b, 0xaf, 0x85, 0xae, 0x41, 0x60, 0x12, 0xc7, 0xc9, 0x82, 0xb2, 0x32, 0x57, 0x90}, - output512: []byte{0x3d, 0xed, 0xf8, 0x19, 0xb3, 0x57, 0xdf, 0xab, 0x1c, 0x70, 0x92, 0xab, 0xd8, 0x72, 0xa1, 0x55, 0x4d, 0xd0, 0x96, 0x2e, 0x99, 0x44, 0xee, 0xf9, 0xf7, 0xf8, 0xbc, 0xe8, 0x30, 0xf2, 0xd7, 0x4f, 0x1d, 0x9b, 0xa2, 0xb7, 0x48, 0xbb, 0xc6, 0xee, 0xb, 0x76, 0x0, 0xbe, 0x8c, 0xb0, 0xff, 0xcb, 0x79, 0x92, 0x4d, 0x9f, 0x51, 0xcd, 0xb9, 0xb0, 0x6b, 0xd6, 0xfd, 0x37, 0xf3, 0x5, 0x2, 0x29}}, - testcase{ - msg: []byte{0x87, 0x1a, 0xd, 0x7a, 0x5f, 0x36, 0xc3, 0xda, 0x1d, 0xfc, 0xe5, 0x7a, 0xcd, 0x8a, 0xb8, 0x48, 0x7c, 0x27, 0x4f, 0xad, 0x33, 0x6b, 0xc1, 0x37, 0xeb, 0xd6, 0xff, 0x46, 0x58, 0xb5, 0x47, 0xc1, 0xdc, 0xfa, 0xb6, 0x5f, 0x3, 0x7a, 0xa5, 0x8f, 0x35, 0xef, 0x16, 0xaf, 0xf4, 0xab, 0xe7, 0x7b, 0xa6, 0x1f, 0x65, 0x82, 0x6f, 0x7b, 0xe6, 0x81, 0xb5, 0xb6, 0xd5, 0xa1, 0xea, 0x80, 0x85, 0xe2, 0xae, 0x9c, 0xd5, 0xcf, 0x9, 0x91, 0x87, 0x8a, 0x31, 0x1b, 0x54, 0x9a, 0x6d, 0x6a, 0xf2, 0x30}, - output224: []byte{0x7d, 0xac, 0x4, 0x62, 0x54, 0x80, 0x84, 0x64, 0x2, 0x46, 0x17, 0xd6, 0x3a, 0x3, 0x82, 0x67, 0xfe, 0x2c, 0xa6, 0x50, 0x52, 0xbd, 0xeb, 0x56, 0x9a, 0xa, 0x9c, 0x15}, - output256: []byte{0x9e, 0x3d, 0x4b, 0xcf, 0x58, 0xe, 0xec, 0xe3, 0x9b, 0xcf, 0x13, 0xe5, 0x71, 0x6e, 0x5b, 0xb8, 0xf5, 0xe8, 0xc3, 0xfc, 0x37, 0x23, 0xf6, 0x62, 0x46, 0xf8, 0x36, 0xd8, 0xdb, 0x12, 0x38, 0xf1}, - output384: []byte{0x29, 0x90, 0xd7, 0xea, 0x6, 0x8a, 0x3, 0x7, 0x4, 0x7b, 0x15, 0x1d, 0x5d, 0xd6, 0xb1, 0xb2, 0x35, 0x8a, 0x9e, 0xc8, 0xad, 0x9b, 0x6b, 0x82, 0x6c, 0xf1, 0xbe, 0xf3, 0x99, 0xd4, 0x88, 0xbd, 0x68, 0xd7, 0x7d, 0xf8, 0xbe, 0x99, 0xf7, 0xdf, 0x7a, 0xf1, 0x4a, 0xe0, 0xce, 0x63, 0x63, 0x79}, - output512: []byte{0x5f, 0xbe, 0x19, 0x45, 0x57, 0xb0, 0x42, 0x6f, 0x96, 0xba, 0x60, 0x71, 0x21, 0x76, 0xdf, 0x7, 0x3e, 0xaf, 0xe0, 0x4f, 0x2a, 0x50, 0x51, 0x54, 0x55, 0x41, 0x2e, 0xa3, 0xd8, 0xc, 0x11, 0x67, 0x58, 0xad, 0x95, 0x25, 0x98, 0xf4, 0x80, 0x31, 0x61, 0x21, 0x81, 0xd8, 0x2a, 0x16, 0xef, 0xe4, 0x66, 0x8f, 0xfb, 0x3b, 0xcc, 0xe9, 0x56, 0x3a, 0x77, 0x2f, 0xe4, 0x16, 0xff, 0x6d, 0xb3, 0xb3}}, - testcase{ - msg: []byte{0xe9, 0xb, 0x4f, 0xfe, 0xf4, 0xd4, 0x57, 0xbc, 0x77, 0x11, 0xff, 0x4a, 0xa7, 0x22, 0x31, 0xca, 0x25, 0xaf, 0x6b, 0x2e, 0x20, 0x6f, 0x8b, 0xf8, 0x59, 0xd8, 0x75, 0x8b, 0x89, 0xa7, 0xcd, 0x36, 0x10, 0x5d, 0xb2, 0x53, 0x8d, 0x6, 0xda, 0x83, 0xba, 0xd5, 0xf6, 0x63, 0xba, 0x11, 0xa5, 0xf6, 0xf6, 0x1f, 0x23, 0x6f, 0xd5, 0xf8, 0xd5, 0x3c, 0x5e, 0x89, 0xf1, 0x83, 0xa3, 0xce, 0xc6, 0x15, 0xb5, 0xc, 0x7c, 0x68, 0x1e, 0x77, 0x3d, 0x10, 0x9f, 0xf7, 0x49, 0x1b, 0x5c, 0xc2, 0x22, 0x96, 0xc5}, - output224: []byte{0x89, 0xf6, 0xb3, 0x20, 0xef, 0xab, 0xe4, 0x2c, 0xe1, 0x3c, 0x9e, 0x20, 0xe4, 0x82, 0x9f, 0x31, 0xa7, 0x84, 0x8e, 0xee, 0x3f, 0xc8, 0x54, 0xe6, 0x3, 0xfb, 0xd4, 0x6f}, - output256: []byte{0xed, 0xc2, 0xd3, 0xb4, 0x9c, 0x85, 0xb8, 0xdd, 0x75, 0xf7, 0xb5, 0x12, 0x8d, 0xa0, 0x4c, 0xd7, 0x6b, 0xf4, 0x87, 0x87, 0x79, 0xa0, 0x7, 0x7a, 0xf3, 0xf1, 0xd7, 0xfb, 0x44, 0xf1, 0x89, 0x31}, - output384: []byte{0x4b, 0x30, 0x87, 0xf8, 0x0, 0xe4, 0x8, 0x4d, 0x7f, 0x68, 0x57, 0x37, 0xac, 0x63, 0x5d, 0xb4, 0x59, 0xcf, 0x70, 0xc4, 0xfa, 0x86, 0x3c, 0x71, 0x1c, 0x11, 0x43, 0xcc, 0x10, 0xf0, 0xc4, 0xab, 0xa, 0x23, 0x70, 0xc0, 0x99, 0xfb, 0x28, 0x2f, 0x9c, 0x1c, 0xe5, 0xf0, 0x15, 0xbf, 0x3f, 0x79}, - output512: []byte{0x2e, 0x8a, 0xb1, 0x61, 0x98, 0x59, 0xc1, 0x14, 0x73, 0xdc, 0x7c, 0x47, 0x4c, 0xe8, 0xb0, 0xae, 0x44, 0xb1, 0xc3, 0x84, 0x17, 0x81, 0x6f, 0xd9, 0x5b, 0x9e, 0x6, 0x14, 0xf3, 0x1e, 0x51, 0xeb, 0xb1, 0xdd, 0x16, 0xd1, 0xcb, 0xb5, 0x84, 0xc4, 0xeb, 0xd2, 0x8a, 0xa9, 0x9f, 0x4a, 0x68, 0xe0, 0x9d, 0xfe, 0x3a, 0xd4, 0x62, 0x48, 0x7f, 0x26, 0x8, 0x12, 0x4b, 0x75, 0x28, 0x29, 0x30, 0x45}}, - testcase{ - msg: []byte{0xe7, 0x28, 0xde, 0x62, 0xd7, 0x58, 0x56, 0x50, 0xc, 0x4c, 0x77, 0xa4, 0x28, 0x61, 0x2c, 0xd8, 0x4, 0xf3, 0xc, 0x3f, 0x10, 0xd3, 0x6f, 0xb2, 0x19, 0xc5, 0xca, 0xa, 0xa3, 0x7, 0x26, 0xab, 0x19, 0xe, 0x5f, 0x3f, 0x27, 0x9e, 0x7, 0x33, 0xd7, 0x7e, 0x72, 0x67, 0xc1, 0x7b, 0xe2, 0x7d, 0x21, 0x65, 0xa, 0x9a, 0x4d, 0x1e, 0x32, 0xf6, 0x49, 0x62, 0x76, 0x38, 0xdb, 0xad, 0xa9, 0x70, 0x2c, 0x7c, 0xa3, 0x3, 0x26, 0x9e, 0xd1, 0x40, 0x14, 0xb2, 0xf3, 0xcf, 0x8b, 0x89, 0x4e, 0xac, 0x85, 0x54}, - output224: []byte{0xa8, 0x5, 0xdb, 0xd3, 0xb8, 0xdf, 0x5e, 0x3, 0xe0, 0x5e, 0xff, 0xfd, 0xe1, 0xb9, 0x4b, 0x35, 0xa2, 0x3c, 0x5d, 0x77, 0xc2, 0x79, 0x7d, 0x98, 0x4e, 0x56, 0x65, 0x6f}, - output256: []byte{0x80, 0xdc, 0xe7, 0xf0, 0x4d, 0xd6, 0xac, 0x17, 0xce, 0x70, 0x9b, 0x56, 0xcf, 0x6e, 0xa6, 0xc0, 0xa5, 0x71, 0x90, 0x64, 0x9b, 0xb1, 0x87, 0xb5, 0xe6, 0xd9, 0x5f, 0xa1, 0x81, 0x0, 0xc7, 0xac}, - output384: []byte{0x5d, 0x34, 0x7f, 0xdd, 0xb1, 0x18, 0xfd, 0x7d, 0xb2, 0x70, 0x89, 0x84, 0x7, 0x97, 0x9d, 0x2d, 0x15, 0x31, 0xd3, 0xff, 0x66, 0x42, 0xec, 0x4f, 0x22, 0x91, 0x7e, 0xbb, 0xed, 0xa6, 0xce, 0xe0, 0xfb, 0xd, 0xe1, 0x14, 0x32, 0xed, 0xdd, 0xfc, 0xbf, 0xe, 0x2a, 0xb9, 0xcf, 0xa6, 0x58, 0x4}, - output512: []byte{0xdb, 0x2d, 0x18, 0x2b, 0xdb, 0xac, 0x6a, 0xc8, 0x66, 0x53, 0x7e, 0x24, 0x71, 0x23, 0x32, 0xca, 0xe7, 0x4d, 0xc3, 0xd3, 0x61, 0x68, 0x98, 0x2e, 0x44, 0x53, 0xdd, 0x6e, 0x0, 0x96, 0x58, 0x34, 0x52, 0x55, 0x1, 0x3b, 0xc0, 0xa5, 0x4f, 0xca, 0x17, 0xae, 0xed, 0xcc, 0x4b, 0xeb, 0x79, 0xbd, 0xee, 0x19, 0x2c, 0xfa, 0xb5, 0x16, 0xd2, 0x45, 0x91, 0xc8, 0x69, 0x9f, 0x7c, 0x75, 0x81, 0x79}}, - testcase{ - msg: []byte{0x63, 0x48, 0xf2, 0x29, 0xe7, 0xb1, 0xdf, 0x3b, 0x77, 0xc, 0x77, 0x54, 0x4e, 0x51, 0x66, 0xe0, 0x81, 0x85, 0xf, 0xa1, 0xc6, 0xc8, 0x81, 0x69, 0xdb, 0x74, 0xc7, 0x6e, 0x42, 0xeb, 0x98, 0x3f, 0xac, 0xb2, 0x76, 0xad, 0x6a, 0xd, 0x1f, 0xa7, 0xb5, 0xd, 0x3e, 0x3b, 0x6f, 0xcd, 0x79, 0x9e, 0xc9, 0x74, 0x70, 0x92, 0xa, 0x7a, 0xbe, 0xd4, 0x7d, 0x28, 0x8f, 0xf8, 0x83, 0xe2, 0x4c, 0xa2, 0x1c, 0x7f, 0x80, 0x16, 0xb9, 0x3b, 0xb9, 0xb9, 0xe0, 0x78, 0xbd, 0xb9, 0x70, 0x3d, 0x2b, 0x78, 0x1b, 0x61, 0x6e}, - output224: []byte{0xf0, 0x57, 0x42, 0xcc, 0x1d, 0xb4, 0x22, 0xa3, 0x11, 0x3a, 0xc4, 0x96, 0x2, 0xe8, 0xd0, 0xdd, 0x6c, 0xb4, 0x72, 0xe7, 0xed, 0x26, 0xbc, 0xe4, 0xb, 0xba, 0x9, 0xbd}, - output256: []byte{0x49, 0xbb, 0xd5, 0x43, 0x5d, 0x27, 0x6, 0xf8, 0x5f, 0xe7, 0x7b, 0x84, 0xa5, 0xfa, 0x15, 0xdd, 0xd8, 0x25, 0x9e, 0x5d, 0x2c, 0x20, 0xfb, 0x94, 0x7f, 0x13, 0x93, 0x73, 0xe5, 0xc8, 0x61, 0x21}, - output384: []byte{0x95, 0x46, 0x37, 0xb8, 0x7f, 0xdc, 0xc4, 0x84, 0xf2, 0xb6, 0x1f, 0x7f, 0x42, 0x55, 0x80, 0x68, 0x2, 0x9f, 0x96, 0x9, 0x9c, 0x1d, 0x6b, 0x92, 0x46, 0x58, 0x50, 0x92, 0xea, 0xe6, 0x89, 0x24, 0xe5, 0x44, 0x1b, 0x45, 0x2, 0x72, 0x48, 0xa2, 0x72, 0x88, 0x33, 0x16, 0x9b, 0xfa, 0x50, 0x4}, - output512: []byte{0x90, 0xa2, 0xc0, 0x5f, 0x70, 0x1, 0xd9, 0x85, 0xb5, 0x87, 0xa0, 0x46, 0xb4, 0x88, 0xbf, 0x4e, 0xd2, 0x9d, 0x75, 0xcc, 0x3, 0xa7, 0x45, 0x73, 0x1b, 0x5b, 0xc, 0xe5, 0x1b, 0xb8, 0x63, 0x87, 0xc4, 0xce, 0x34, 0x1, 0x8a, 0x6d, 0x90, 0x6e, 0xb7, 0xbe, 0xb4, 0x1a, 0x9, 0xaf, 0xe9, 0xfe, 0xdd, 0x99, 0xaa, 0xcc, 0x41, 0xb4, 0x55, 0x6f, 0x75, 0x22, 0x9c, 0x86, 0x88, 0xc7, 0xfc, 0xa2}}, - testcase{ - msg: []byte{0x4b, 0x12, 0x7f, 0xde, 0x5d, 0xe7, 0x33, 0xa1, 0x68, 0xc, 0x27, 0x90, 0x36, 0x36, 0x27, 0xe6, 0x3a, 0xc8, 0xa3, 0xf1, 0xb4, 0x70, 0x7d, 0x98, 0x2c, 0xae, 0xa2, 0x58, 0x65, 0x5d, 0x9b, 0xf1, 0x8f, 0x89, 0xaf, 0xe5, 0x41, 0x27, 0x48, 0x2b, 0xa0, 0x1e, 0x8, 0x84, 0x55, 0x94, 0xb6, 0x71, 0x30, 0x6a, 0x2, 0x5c, 0x9a, 0x5c, 0x5b, 0x6f, 0x93, 0xb0, 0xa3, 0x95, 0x22, 0xdc, 0x87, 0x74, 0x37, 0xbe, 0x5c, 0x24, 0x36, 0xcb, 0xf3, 0x0, 0xce, 0x7a, 0xb6, 0x74, 0x79, 0x34, 0xfc, 0xfc, 0x30, 0xae, 0xaa, 0xf6}, - output224: []byte{0x45, 0x94, 0x5f, 0x86, 0x7b, 0x7e, 0x1e, 0x75, 0xee, 0x49, 0x6e, 0xf, 0xc4, 0xaa, 0xff, 0x71, 0xa0, 0xcc, 0x53, 0x98, 0x41, 0xd1, 0x53, 0x43, 0x9a, 0xed, 0x4d, 0xfc}, - output256: []byte{0x6b, 0x6c, 0x11, 0xf9, 0x73, 0x1d, 0x60, 0x78, 0x9d, 0x71, 0x3d, 0xaf, 0x53, 0xd2, 0xeb, 0x10, 0xab, 0x9c, 0xcf, 0x15, 0x43, 0xe, 0xa5, 0xd1, 0x24, 0x9b, 0xe0, 0x6e, 0xdf, 0xe2, 0xbf, 0xf6}, - output384: []byte{0x78, 0x72, 0x6e, 0x91, 0xac, 0x31, 0x1f, 0x4d, 0x10, 0x47, 0x6, 0x36, 0x2b, 0x3, 0x14, 0xc2, 0x43, 0xcd, 0x81, 0x64, 0x41, 0x25, 0x88, 0x1f, 0xbc, 0x3, 0x67, 0x2, 0x10, 0xc8, 0x9f, 0xb8, 0xe7, 0xbf, 0xf6, 0xc6, 0x1f, 0xf6, 0x8b, 0x23, 0x4c, 0x31, 0x71, 0xf1, 0x6b, 0x39, 0x8f, 0x36}, - output512: []byte{0xea, 0x39, 0x91, 0xc4, 0xa8, 0xa5, 0xf0, 0x14, 0x64, 0x2, 0xde, 0x4a, 0xe2, 0x35, 0x5, 0x4c, 0x78, 0xa4, 0x8d, 0xca, 0x34, 0xa, 0x7d, 0x4a, 0xd8, 0x75, 0x39, 0x95, 0xf8, 0x23, 0x47, 0xec, 0xfc, 0x0, 0x54, 0xd6, 0x4e, 0xb4, 0xf2, 0xa, 0xbc, 0x4f, 0x41, 0x5c, 0x54, 0x70, 0x1c, 0xbc, 0x61, 0xa7, 0xb2, 0x39, 0xa7, 0xc2, 0x21, 0xb8, 0x33, 0xd9, 0xea, 0x9f, 0x94, 0xb1, 0x54, 0xe8}}, - testcase{ - msg: []byte{0x8, 0x46, 0x1f, 0x0, 0x6c, 0xff, 0x4c, 0xc6, 0x4b, 0x75, 0x2c, 0x95, 0x72, 0x87, 0xe5, 0xa0, 0xfa, 0xab, 0xc0, 0x5c, 0x9b, 0xff, 0x89, 0xd2, 0x3f, 0xd9, 0x2, 0xd3, 0x24, 0xc7, 0x99, 0x3, 0xb4, 0x8f, 0xcb, 0x8f, 0x8f, 0x4b, 0x1, 0xf3, 0xe4, 0xdd, 0xb4, 0x83, 0x59, 0x3d, 0x25, 0xf0, 0x0, 0x38, 0x66, 0x98, 0xf5, 0xad, 0xe7, 0xfa, 0xad, 0xe9, 0x61, 0x5f, 0xdc, 0x50, 0xd3, 0x27, 0x85, 0xea, 0x51, 0xd4, 0x98, 0x94, 0xe4, 0x5b, 0xaa, 0x3d, 0xc7, 0x7, 0xe2, 0x24, 0x68, 0x8c, 0x64, 0x8, 0xb6, 0x8b, 0x11}, - output224: []byte{0x5a, 0x8a, 0xc7, 0x53, 0x3e, 0x13, 0x54, 0x6, 0x8b, 0x56, 0x4c, 0xcd, 0x21, 0x4e, 0xb2, 0xa2, 0xe0, 0x97, 0xdd, 0x60, 0xe0, 0x8b, 0xd6, 0x9f, 0xc7, 0x82, 0xb0, 0xaf}, - output256: []byte{0x7e, 0x73, 0x8e, 0x8e, 0xb3, 0xd4, 0x7d, 0x18, 0xe9, 0x7d, 0x87, 0xc7, 0xb3, 0xfc, 0x68, 0x1f, 0x86, 0x41, 0x78, 0x83, 0xce, 0xd9, 0x2b, 0xa9, 0x3c, 0x30, 0x77, 0x81, 0x2b, 0xbd, 0x17, 0xe7}, - output384: []byte{0x80, 0x76, 0x3f, 0xb5, 0x46, 0x88, 0xf1, 0x22, 0x26, 0x94, 0x30, 0x98, 0xa, 0xa3, 0xab, 0xe0, 0x90, 0x91, 0x2, 0xb, 0x8c, 0xfa, 0x6b, 0xde, 0xe, 0xdc, 0x2c, 0x63, 0xae, 0xd8, 0xb8, 0xba, 0x9, 0x7c, 0xdb, 0x79, 0xb8, 0xfc, 0x7f, 0x51, 0x17, 0x50, 0x8f, 0xca, 0x48, 0x64, 0xa1, 0x4d}, - output512: []byte{0x13, 0x13, 0x2, 0x3b, 0x75, 0x3e, 0xd1, 0x72, 0x7f, 0x13, 0xcc, 0x67, 0xa6, 0x4b, 0x98, 0x9a, 0x8b, 0xf6, 0x54, 0x83, 0x24, 0xdf, 0x98, 0x54, 0xd8, 0xd5, 0xa9, 0x63, 0xed, 0x3d, 0x86, 0x2, 0x57, 0xfe, 0x65, 0x22, 0xb9, 0xc6, 0xd6, 0xcb, 0x1b, 0xca, 0xdf, 0x32, 0x2c, 0x98, 0x56, 0x1, 0xba, 0x36, 0xf7, 0xe6, 0x71, 0x10, 0x19, 0x20, 0x94, 0xaa, 0x8f, 0x98, 0x69, 0xa4, 0x58, 0xa8}}, - testcase{ - msg: []byte{0x68, 0xc8, 0xf8, 0x84, 0x9b, 0x12, 0xe, 0x6e, 0xc, 0x99, 0x69, 0xa5, 0x86, 0x6a, 0xf5, 0x91, 0xa8, 0x29, 0xb9, 0x2f, 0x33, 0xcd, 0x9a, 0x4a, 0x31, 0x96, 0x95, 0x7a, 0x14, 0x8c, 0x49, 0x13, 0x8e, 0x1e, 0x2f, 0x5c, 0x76, 0x19, 0xa6, 0xd5, 0xed, 0xeb, 0xe9, 0x95, 0xac, 0xd8, 0x1e, 0xc8, 0xbb, 0x9c, 0x7b, 0x9c, 0xfc, 0xa6, 0x78, 0xd0, 0x81, 0xea, 0x9e, 0x25, 0xa7, 0x5d, 0x39, 0xdb, 0x4, 0xe1, 0x8d, 0x47, 0x59, 0x20, 0xce, 0x82, 0x8b, 0x94, 0xe7, 0x22, 0x41, 0xf2, 0x4d, 0xb7, 0x25, 0x46, 0xb3, 0x52, 0xa0, 0xe4}, - output224: []byte{0x5, 0x9f, 0x7e, 0xb9, 0x83, 0x36, 0x2f, 0xd4, 0x4e, 0x94, 0xe2, 0xbf, 0xd5, 0x9c, 0xce, 0xd4, 0x3c, 0xae, 0x95, 0x9c, 0x9a, 0x48, 0x3e, 0xbd, 0x5e, 0x6e, 0x20, 0x36}, - output256: []byte{0xa2, 0x78, 0xba, 0x93, 0xba, 0xd, 0x7c, 0xd2, 0x67, 0x7b, 0xe0, 0x8c, 0x9d, 0xfc, 0x5f, 0x51, 0x6a, 0x37, 0xf7, 0x22, 0xbb, 0x6, 0x56, 0x5f, 0xa2, 0x25, 0x0, 0xf6, 0x6f, 0xe0, 0x31, 0xa9}, - output384: []byte{0x80, 0x44, 0x75, 0x83, 0x26, 0x2d, 0xed, 0x3, 0x7d, 0xa8, 0x8f, 0x3b, 0x98, 0x69, 0x8b, 0xd8, 0xf7, 0xae, 0xd7, 0xd9, 0xbf, 0x4d, 0x99, 0xf8, 0x13, 0x2e, 0xc3, 0xe7, 0xd1, 0x6b, 0xb8, 0x44, 0xad, 0xad, 0x18, 0x87, 0x57, 0xce, 0xb3, 0x2b, 0x35, 0x9c, 0x56, 0xe5, 0x0, 0x7e, 0xa3, 0xe4}, - output512: []byte{0x9b, 0xca, 0x2a, 0x1a, 0x55, 0x46, 0xa1, 0x12, 0x75, 0xbf, 0x42, 0xf0, 0xb4, 0x84, 0x92, 0x86, 0x83, 0x59, 0xc7, 0x8d, 0x94, 0x78, 0x5a, 0xe, 0xe1, 0x2d, 0xc1, 0xc3, 0xd7, 0xa, 0x8e, 0x97, 0xeb, 0x46, 0x21, 0x48, 0xfa, 0xed, 0x1f, 0xfa, 0x4d, 0xab, 0xe, 0x91, 0x51, 0x9b, 0xd3, 0x6c, 0xc, 0x5c, 0x5f, 0xe7, 0xcf, 0xcf, 0xf3, 0xe1, 0x80, 0x68, 0x3, 0x18, 0xe1, 0xfc, 0xf7, 0x5b}}, - testcase{ - msg: []byte{0xb8, 0xd5, 0x64, 0x72, 0x95, 0x4e, 0x31, 0xfb, 0x54, 0xe2, 0x8f, 0xca, 0x74, 0x3f, 0x84, 0xd8, 0xdc, 0x34, 0x89, 0x1c, 0xb5, 0x64, 0xc6, 0x4b, 0x8, 0xf7, 0xb7, 0x16, 0x36, 0xde, 0xbd, 0x64, 0xca, 0x1e, 0xdb, 0xdb, 0xa7, 0xfc, 0x5c, 0x3e, 0x40, 0x4, 0x9c, 0xe9, 0x82, 0xbb, 0xa8, 0xc7, 0xe0, 0x70, 0x30, 0x34, 0xe3, 0x31, 0x38, 0x46, 0x95, 0xe9, 0xde, 0x76, 0xb5, 0x10, 0x4f, 0x2f, 0xbc, 0x45, 0x35, 0xec, 0xbe, 0xeb, 0xc3, 0x3b, 0xc2, 0x7f, 0x29, 0xf1, 0x8f, 0x6f, 0x27, 0xe8, 0x2, 0x3b, 0xf, 0xbb, 0x6f, 0x56, 0x3c}, - output224: []byte{0x22, 0xd6, 0x2a, 0xd2, 0x72, 0xfe, 0xfc, 0x89, 0xf7, 0x32, 0x56, 0xea, 0xac, 0xe0, 0xc, 0x7b, 0x8e, 0x99, 0x8f, 0xb3, 0x22, 0xc8, 0xeb, 0x67, 0xdc, 0x1e, 0xac, 0x6a}, - output256: []byte{0x9c, 0xa, 0x9f, 0xd, 0xa1, 0x13, 0xd3, 0x9f, 0x49, 0x1b, 0x7d, 0xa6, 0xc4, 0xda, 0x5d, 0x84, 0xfe, 0x1c, 0xc4, 0x63, 0x67, 0xe5, 0xac, 0xc4, 0x33, 0xca, 0x3e, 0x5, 0x0, 0x95, 0x17, 0x38}, - output384: []byte{0xe5, 0xfb, 0x4a, 0xe5, 0xdd, 0xfb, 0x4c, 0xe8, 0x22, 0x1d, 0xf4, 0xbe, 0x70, 0x24, 0xb, 0x76, 0x85, 0x1e, 0x55, 0xfa, 0xe8, 0x6b, 0xaf, 0x35, 0xba, 0xd9, 0xe7, 0x17, 0x9e, 0x24, 0xc9, 0x5d, 0xa6, 0xf0, 0xf0, 0x69, 0x5a, 0x8a, 0x52, 0x91, 0xa2, 0x39, 0x4b, 0x92, 0xa6, 0xff, 0x7b, 0x7c}, - output512: []byte{0x84, 0x92, 0xf5, 0xe6, 0x21, 0xe8, 0x2f, 0xdb, 0xff, 0x19, 0x76, 0xb1, 0xbe, 0xec, 0xff, 0x7d, 0x13, 0x78, 0x5, 0xb5, 0x73, 0x6a, 0xb4, 0x92, 0x16, 0x12, 0x2a, 0x95, 0x39, 0x6b, 0x86, 0x3a, 0x4, 0x81, 0x21, 0x2b, 0x6d, 0xab, 0xa8, 0xb0, 0x5e, 0x29, 0xe2, 0x87, 0xbb, 0xe, 0x2f, 0x58, 0x8f, 0x86, 0x40, 0x7c, 0x84, 0xdb, 0xfb, 0x89, 0x4e, 0x6a, 0xcf, 0xc6, 0xf6, 0xb2, 0xe5, 0x71}}, - testcase{ - msg: []byte{0xd, 0x58, 0xac, 0x66, 0x5f, 0xa8, 0x43, 0x42, 0xe6, 0xc, 0xef, 0xee, 0x31, 0xb1, 0xa4, 0xea, 0xcd, 0xb0, 0x92, 0xf1, 0x22, 0xdf, 0xc6, 0x83, 0x9, 0x7, 0x7a, 0xed, 0x1f, 0x3e, 0x52, 0x8f, 0x57, 0x88, 0x59, 0xee, 0x9e, 0x4c, 0xef, 0xb4, 0xa7, 0x28, 0xe9, 0x46, 0x32, 0x49, 0x27, 0xb6, 0x75, 0xcd, 0x4f, 0x4a, 0xc8, 0x4f, 0x64, 0xdb, 0x3d, 0xac, 0xfe, 0x85, 0xc, 0x1d, 0xd1, 0x87, 0x44, 0xc7, 0x4c, 0xec, 0xcd, 0x9f, 0xe4, 0xdc, 0x21, 0x40, 0x85, 0x10, 0x8f, 0x40, 0x4e, 0xab, 0x6d, 0x8f, 0x45, 0x2b, 0x54, 0x42, 0xa4, 0x7d}, - output224: []byte{0xa3, 0x96, 0xea, 0x90, 0x5e, 0xb6, 0x12, 0x55, 0x4b, 0xd0, 0xe, 0x4f, 0xc1, 0xbb, 0x4c, 0x52, 0x47, 0xd7, 0x3f, 0xde, 0x4b, 0xba, 0xf5, 0x38, 0xe, 0xd4, 0x2d, 0xd0}, - output256: []byte{0x6b, 0xed, 0x49, 0x6d, 0x2, 0xfe, 0x4c, 0xc2, 0x7d, 0x96, 0xdc, 0xee, 0xd1, 0x4a, 0x67, 0xda, 0x7b, 0xdf, 0x75, 0xe1, 0x9b, 0x62, 0x48, 0x96, 0xdf, 0xf6, 0xb0, 0xb6, 0x8e, 0x4f, 0xcc, 0x12}, - output384: []byte{0xce, 0x6b, 0x7, 0xc0, 0xc7, 0xda, 0x2f, 0xa1, 0xe6, 0xca, 0x5, 0xde, 0x6, 0x52, 0xfc, 0x9f, 0x1f, 0x45, 0x2f, 0xc2, 0x61, 0xe7, 0x3e, 0x52, 0x45, 0x7c, 0x72, 0xbf, 0xd, 0x51, 0xba, 0xc7, 0xd6, 0x61, 0x60, 0xcf, 0xf1, 0x6d, 0x6a, 0x3, 0x52, 0x79, 0x82, 0xe7, 0xd4, 0x39, 0x35, 0x7}, - output512: []byte{0xee, 0xbe, 0x4e, 0xc0, 0xfe, 0x3e, 0x2, 0x66, 0x52, 0x7f, 0x4d, 0x9f, 0x57, 0xa0, 0x17, 0x63, 0x7e, 0xab, 0x92, 0x37, 0x7d, 0x82, 0xb1, 0x58, 0x56, 0xa5, 0x5a, 0x22, 0xb0, 0x8, 0xdf, 0x67, 0xf2, 0x7a, 0xa5, 0xac, 0x4, 0xe1, 0xde, 0xee, 0xb2, 0xc8, 0x19, 0xce, 0x41, 0xdb, 0x7, 0xdb, 0xf6, 0xdc, 0xaf, 0x17, 0xa1, 0x92, 0xa4, 0x37, 0x1a, 0x1e, 0x92, 0xba, 0xdf, 0x1e, 0x63, 0x89}}, - testcase{ - msg: []byte{0x17, 0x55, 0xe2, 0xd2, 0xe5, 0xd1, 0xc1, 0xb0, 0x15, 0x64, 0x56, 0xb5, 0x39, 0x75, 0x3f, 0xf4, 0x16, 0x65, 0x1d, 0x44, 0x69, 0x8e, 0x87, 0x0, 0x2d, 0xcf, 0x61, 0xdc, 0xfa, 0x2b, 0x4e, 0x72, 0xf2, 0x64, 0xd9, 0xad, 0x59, 0x1d, 0xf1, 0xfd, 0xee, 0x7b, 0x41, 0xb2, 0xeb, 0x0, 0x28, 0x3c, 0x5a, 0xeb, 0xb3, 0x41, 0x13, 0x23, 0xb6, 0x72, 0xea, 0xa1, 0x45, 0xc5, 0x12, 0x51, 0x85, 0x10, 0x4f, 0x20, 0xf3, 0x35, 0x80, 0x4b, 0x2, 0x32, 0x5b, 0x6d, 0xea, 0x65, 0x60, 0x3f, 0x34, 0x9f, 0x4d, 0x5d, 0x8b, 0x78, 0x2d, 0xd3, 0x46, 0x9c, 0xcd}, - output224: []byte{0xd8, 0xb5, 0xb2, 0x4b, 0x9e, 0x92, 0x32, 0x6f, 0xde, 0x5d, 0xb1, 0x5, 0x8e, 0xed, 0xbe, 0xed, 0xb0, 0xb6, 0x59, 0x82, 0x92, 0x57, 0x34, 0xb6, 0xe2, 0x84, 0x40, 0x36}, - output256: []byte{0xec, 0xd2, 0xe3, 0xfa, 0xf4, 0xba, 0x4d, 0xd6, 0x7e, 0x5a, 0x86, 0x56, 0xce, 0xbe, 0xbd, 0xb2, 0x46, 0x11, 0x61, 0x16, 0x78, 0xe9, 0x2e, 0xb6, 0xf, 0x7c, 0xbd, 0x31, 0x11, 0xd0, 0xa3, 0x45}, - output384: []byte{0xfa, 0x76, 0xe0, 0x5f, 0x8d, 0x28, 0x32, 0xda, 0xdf, 0xeb, 0xa0, 0x10, 0x7a, 0x31, 0x37, 0xb7, 0xb9, 0xd4, 0xd1, 0x9a, 0x77, 0xa1, 0xe7, 0x8f, 0x8b, 0xbf, 0xec, 0xda, 0x7e, 0xf4, 0x64, 0x14, 0xc3, 0x63, 0x45, 0x3e, 0x8c, 0x49, 0x2, 0xc3, 0x2, 0xa4, 0xe1, 0x8c, 0xea, 0x4b, 0xa1, 0x57}, - output512: []byte{0x9e, 0x36, 0xe6, 0x29, 0x1b, 0xc2, 0x29, 0x6c, 0xb4, 0xba, 0x71, 0x10, 0x9c, 0xed, 0xcc, 0x2a, 0x3f, 0xb, 0x4f, 0x1a, 0xe5, 0xe5, 0x40, 0x6d, 0xc4, 0xb3, 0xe5, 0x94, 0x55, 0x1d, 0x5c, 0x70, 0xe6, 0xf8, 0x14, 0xd2, 0xc9, 0xb8, 0x41, 0x31, 0x3, 0xef, 0x7, 0x53, 0x58, 0x86, 0xb4, 0xac, 0x51, 0x8a, 0xaf, 0x7a, 0xed, 0x64, 0xab, 0xed, 0x7a, 0x5b, 0xa, 0x26, 0xf7, 0x17, 0x14, 0x25}}, - testcase{ - msg: []byte{0xb1, 0x80, 0xde, 0x1a, 0x61, 0x11, 0x11, 0xee, 0x75, 0x84, 0xba, 0x2c, 0x4b, 0x2, 0x5, 0x98, 0xcd, 0x57, 0x4a, 0xc7, 0x7e, 0x40, 0x4e, 0x85, 0x3d, 0x15, 0xa1, 0x1, 0xc6, 0xf5, 0xa2, 0xe5, 0xc8, 0x1, 0xd7, 0xd8, 0x5d, 0xc9, 0x52, 0x86, 0xa1, 0x80, 0x4c, 0x87, 0xb, 0xb9, 0xf0, 0xf, 0xd4, 0xdc, 0xb0, 0x3a, 0xa8, 0x32, 0x82, 0x75, 0x15, 0x88, 0x19, 0xdc, 0xad, 0x72, 0x53, 0xf3, 0xe3, 0xd2, 0x37, 0xae, 0xaa, 0x79, 0x79, 0x26, 0x8a, 0x5d, 0xb1, 0xc6, 0xce, 0x8, 0xa9, 0xec, 0x7c, 0x25, 0x79, 0x78, 0x3c, 0x8a, 0xfc, 0x1f, 0x91, 0xa7}, - output224: []byte{0xfd, 0xb9, 0x1, 0x5b, 0x20, 0xdb, 0x44, 0x6f, 0x79, 0x57, 0x5e, 0x6b, 0x8c, 0x73, 0xa9, 0x8e, 0xac, 0x73, 0x1c, 0xfe, 0x2e, 0x59, 0xbd, 0x46, 0xdb, 0xda, 0xe, 0x35}, - output256: []byte{0x63, 0x4a, 0x95, 0xa7, 0xe8, 0xba, 0x58, 0xf7, 0x81, 0x8a, 0x13, 0x90, 0x3e, 0xc8, 0xf3, 0x41, 0x1b, 0x6e, 0xcb, 0x7e, 0x38, 0x9e, 0xc9, 0xaa, 0x97, 0xc0, 0xec, 0xf8, 0x7f, 0xad, 0xd5, 0x88}, - output384: []byte{0x1b, 0x43, 0xb7, 0xb, 0x6b, 0xbb, 0xc7, 0x68, 0xc1, 0xf4, 0xb3, 0xce, 0x24, 0x16, 0x67, 0xad, 0xb5, 0x24, 0x6d, 0x29, 0x98, 0x17, 0x23, 0x84, 0x61, 0x68, 0xd2, 0x23, 0x4e, 0x19, 0xa5, 0x13, 0xb, 0x1f, 0x57, 0x6b, 0x49, 0x74, 0xc6, 0x13, 0x63, 0x9a, 0x44, 0x9e, 0x61, 0xb2, 0xca, 0x79}, - output512: []byte{0xf1, 0x8, 0x94, 0x83, 0xa0, 0xb, 0x26, 0x1, 0xbe, 0x9c, 0x16, 0x46, 0x9a, 0x9, 0xe, 0xfc, 0x49, 0xfc, 0xb7, 0xe, 0x62, 0xac, 0xf, 0xfe, 0xa2, 0xd1, 0xe5, 0x8, 0x8, 0x3c, 0xd5, 0xd4, 0x1d, 0xcf, 0x2d, 0xaa, 0xe1, 0xe0, 0xea, 0xc2, 0x17, 0x85, 0x9e, 0x5f, 0xea, 0xdd, 0xcb, 0x78, 0x2a, 0xc4, 0x71, 0xc0, 0x1d, 0x72, 0x66, 0x13, 0x61, 0x85, 0xd3, 0x7b, 0x56, 0x8e, 0x96, 0x6}}, - testcase{ - msg: []byte{0xcf, 0x35, 0x83, 0xcb, 0xdf, 0xd4, 0xcb, 0xc1, 0x70, 0x63, 0xb1, 0xe7, 0xd9, 0xb, 0x2, 0xf0, 0xe6, 0xe2, 0xee, 0x5, 0xf9, 0x9d, 0x77, 0xe2, 0x4e, 0x56, 0x3, 0x92, 0x53, 0x5e, 0x47, 0xe0, 0x50, 0x77, 0x15, 0x7f, 0x96, 0x81, 0x35, 0x44, 0xa1, 0x70, 0x46, 0x91, 0x4f, 0x9e, 0xfb, 0x64, 0x76, 0x2a, 0x23, 0xcf, 0x7a, 0x49, 0xfe, 0x52, 0xa0, 0xa4, 0xc0, 0x1c, 0x63, 0xc, 0xfe, 0x87, 0x27, 0xb8, 0x1f, 0xb9, 0x9a, 0x89, 0xff, 0x7c, 0xc1, 0x1d, 0xca, 0x51, 0x73, 0x5, 0x7e, 0x4, 0x17, 0xb8, 0xfe, 0x7a, 0x9e, 0xfb, 0xa6, 0xd9, 0x5c, 0x55, 0x5f}, - output224: []byte{0xdf, 0x1b, 0x47, 0xe7, 0x3e, 0x8c, 0xbd, 0x2c, 0xa8, 0x52, 0xcf, 0x58, 0xad, 0x68, 0xb5, 0xf8, 0xba, 0xa1, 0x16, 0x9c, 0x7, 0x95, 0x96, 0x10, 0x41, 0xe8, 0xa9, 0x18}, - output256: []byte{0xa0, 0xfe, 0x35, 0x2b, 0xa2, 0x38, 0x9b, 0x4, 0x30, 0xed, 0xbe, 0x12, 0x1, 0x3, 0x2e, 0xb0, 0x9c, 0x25, 0x55, 0x14, 0xc5, 0xc5, 0xb5, 0x29, 0xc4, 0xba, 0xaf, 0xce, 0xb1, 0xac, 0x98, 0x17}, - output384: []byte{0x93, 0x82, 0x52, 0x39, 0x3a, 0x53, 0x2d, 0x9e, 0x1f, 0x91, 0xd5, 0xc2, 0x22, 0xe2, 0xdf, 0x2c, 0xc7, 0xae, 0x10, 0x27, 0x5, 0xbf, 0xb8, 0x3f, 0xe3, 0xd, 0xca, 0xeb, 0xce, 0xa8, 0x2b, 0xff, 0x9b, 0xda, 0x7c, 0xa6, 0x70, 0x95, 0x43, 0x98, 0x59, 0x14, 0x66, 0x32, 0x49, 0x4d, 0x3c, 0xe4}, - output512: []byte{0xd0, 0x63, 0xea, 0x79, 0x4c, 0xfd, 0x2e, 0xd9, 0x24, 0x86, 0x65, 0xa6, 0x8, 0x4a, 0x7b, 0x99, 0x5, 0x1c, 0x10, 0x51, 0xe4, 0x1b, 0x7d, 0x9d, 0xcb, 0x15, 0x37, 0xa1, 0xc7, 0x9c, 0xba, 0x6d, 0xeb, 0x4d, 0x84, 0x4c, 0x6a, 0x61, 0x8e, 0x43, 0xc7, 0xca, 0x2, 0xd, 0x16, 0x97, 0x69, 0x99, 0x68, 0x4f, 0xeb, 0x8, 0x46, 0x16, 0xf7, 0x7, 0x20, 0x9f, 0x75, 0xc4, 0xbd, 0x58, 0x4d, 0x86}}, - testcase{ - msg: []byte{0x7, 0x2f, 0xc0, 0x23, 0x40, 0xef, 0x99, 0x11, 0x5b, 0xad, 0x72, 0xf9, 0x2c, 0x1, 0xe4, 0xc0, 0x93, 0xb9, 0x59, 0x9f, 0x6c, 0xfc, 0x45, 0xcb, 0x38, 0xe, 0xe6, 0x86, 0xcb, 0x5e, 0xb0, 0x19, 0xe8, 0x6, 0xab, 0x9b, 0xd5, 0x5e, 0x63, 0x4a, 0xb1, 0xa, 0xa6, 0x2a, 0x95, 0x10, 0xcc, 0x6, 0x72, 0xcd, 0x3e, 0xdd, 0xb5, 0x89, 0xc7, 0xdf, 0x2b, 0x67, 0xfc, 0xd3, 0x32, 0x9f, 0x61, 0xb1, 0xa4, 0x44, 0x1e, 0xca, 0x87, 0xa3, 0x3c, 0x8f, 0x55, 0xda, 0x4f, 0xbb, 0xad, 0x5c, 0xf2, 0xb2, 0x52, 0x7b, 0x8e, 0x98, 0x3b, 0xb3, 0x1a, 0x2f, 0xad, 0xec, 0x75, 0x23}, - output224: []byte{0x1e, 0x8a, 0x90, 0x91, 0x8d, 0x6e, 0xad, 0x31, 0xe4, 0x46, 0xd4, 0xee, 0x26, 0x73, 0x87, 0x1e, 0xcc, 0x5c, 0x7d, 0xa9, 0xb1, 0x8e, 0xd5, 0x11, 0xe1, 0x63, 0x2e, 0xd}, - output256: []byte{0x9a, 0xb, 0xfe, 0x14, 0xf9, 0xf3, 0x12, 0x7a, 0xca, 0x86, 0x77, 0x3a, 0x62, 0x9, 0x45, 0x73, 0x1d, 0xf7, 0x81, 0xa6, 0xd7, 0xdc, 0x82, 0x93, 0xc, 0xcd, 0xe2, 0xf6, 0x9d, 0xac, 0x8f, 0x94}, - output384: []byte{0x47, 0x63, 0x3a, 0xd0, 0xc8, 0xa, 0xf2, 0x6b, 0xf7, 0x4d, 0x95, 0x98, 0xdb, 0xd5, 0xbc, 0xf7, 0x7f, 0xc6, 0xbf, 0xf1, 0xbc, 0xa0, 0x15, 0xa6, 0x11, 0xd7, 0xb8, 0x24, 0xf, 0x59, 0x7d, 0x87, 0x67, 0xfb, 0x8b, 0xb, 0xf5, 0xc3, 0x33, 0x15, 0x65, 0x80, 0xaf, 0xee, 0x12, 0x1c, 0x29, 0x9c}, - output512: []byte{0x42, 0x4a, 0x86, 0xd7, 0x46, 0xc8, 0x7c, 0x85, 0xda, 0xbd, 0x1d, 0xae, 0x29, 0x8a, 0x48, 0x8e, 0x4c, 0xa2, 0x18, 0x3d, 0xe6, 0x92, 0xd1, 0xd0, 0x1c, 0x4b, 0x79, 0x94, 0xee, 0x51, 0x24, 0xf9, 0x0, 0x4b, 0xea, 0x84, 0x93, 0x3c, 0x31, 0x1c, 0xc3, 0x8e, 0xa6, 0xf6, 0x4, 0xa7, 0x76, 0x9e, 0xe1, 0x78, 0xe1, 0xec, 0x16, 0xa, 0x98, 0x91, 0xc4, 0x2c, 0x46, 0x2a, 0x13, 0xa6, 0x22, 0x86}}, - testcase{ - msg: []byte{0x76, 0xee, 0xcf, 0x95, 0x6a, 0x52, 0x64, 0x9f, 0x87, 0x75, 0x28, 0x14, 0x6d, 0xe3, 0x3d, 0xf2, 0x49, 0xcd, 0x80, 0xe, 0x21, 0x83, 0xf, 0x65, 0xe9, 0xf, 0xf, 0x25, 0xca, 0x9d, 0x65, 0x40, 0xfd, 0xe4, 0x6, 0x3, 0x23, 0xe, 0xca, 0x67, 0x60, 0xf1, 0x13, 0x9c, 0x7f, 0x26, 0x8d, 0xeb, 0xa2, 0x6, 0x6, 0x31, 0xee, 0xa9, 0x2b, 0x1f, 0xff, 0x5, 0xf9, 0x3f, 0xd5, 0x57, 0x2f, 0xbe, 0x29, 0x57, 0x9e, 0xcd, 0x48, 0xbc, 0x3a, 0x8d, 0x6c, 0x2e, 0xb4, 0xa6, 0xb2, 0x6e, 0x38, 0xd6, 0xc5, 0xfb, 0xf2, 0xc0, 0x80, 0x44, 0xae, 0xea, 0x47, 0xa, 0x8f, 0x2f, 0x26}, - output224: []byte{0x10, 0x60, 0xaf, 0xd1, 0xe1, 0xb9, 0xf7, 0xf4, 0x12, 0x91, 0xa4, 0x86, 0x17, 0x74, 0xb3, 0xb0, 0xc9, 0x5a, 0x81, 0x27, 0x88, 0xa4, 0x1d, 0x7e, 0xbe, 0xf4, 0xa8, 0x93}, - output256: []byte{0x19, 0xe5, 0x10, 0x1b, 0xde, 0x60, 0xb2, 0x0, 0xa8, 0xb1, 0x71, 0xe4, 0xc3, 0xea, 0x3d, 0xfd, 0x91, 0x3e, 0x10, 0x11, 0x1d, 0x96, 0xf9, 0x68, 0x2a, 0xcc, 0x74, 0x67, 0x28, 0x2b, 0x4e, 0x31}, - output384: []byte{0x4, 0x45, 0x63, 0x22, 0xe1, 0xbf, 0x27, 0x78, 0x5e, 0xdf, 0x3f, 0x59, 0x6d, 0xb3, 0x3e, 0x69, 0x3a, 0xad, 0xf7, 0x6d, 0x9d, 0x25, 0x93, 0x52, 0xd9, 0x7a, 0xcd, 0x56, 0x1b, 0xc4, 0x52, 0x36, 0x50, 0x6f, 0xba, 0x35, 0x30, 0x77, 0x22, 0x42, 0xcb, 0x36, 0x9a, 0x83, 0xa3, 0x8c, 0xd7, 0x49}, - output512: []byte{0xa9, 0x40, 0x3c, 0x26, 0xa9, 0x6d, 0xe2, 0xc3, 0xd3, 0x59, 0xee, 0x29, 0xf3, 0xfd, 0x1c, 0x58, 0x11, 0x54, 0x85, 0x2d, 0x19, 0xad, 0x12, 0x88, 0x4b, 0x79, 0xe7, 0x8, 0x2d, 0x2d, 0xa2, 0x2e, 0xc8, 0x35, 0x53, 0xba, 0xba, 0x2b, 0xdf, 0xf2, 0xa2, 0xfa, 0x15, 0x94, 0x7a, 0x8e, 0x6a, 0xcd, 0x5f, 0x5d, 0x11, 0x3e, 0xc0, 0x91, 0xbf, 0xd1, 0x96, 0x2a, 0xa, 0x10, 0x40, 0x1d, 0x2c, 0x98}}, - testcase{ - msg: []byte{0x7a, 0xdc, 0xb, 0x66, 0x93, 0xe6, 0x1c, 0x26, 0x9f, 0x27, 0x8e, 0x69, 0x44, 0xa5, 0xa2, 0xd8, 0x30, 0x9, 0x81, 0xe4, 0x0, 0x22, 0xf8, 0x39, 0xac, 0x64, 0x43, 0x87, 0xbf, 0xac, 0x90, 0x86, 0x65, 0x0, 0x85, 0xc2, 0xcd, 0xc5, 0x85, 0xfe, 0xa4, 0x7b, 0x9d, 0x2e, 0x52, 0xd6, 0x5a, 0x2b, 0x29, 0xa7, 0xdc, 0x37, 0x4, 0x1, 0xef, 0x5d, 0x60, 0xdd, 0xd, 0x21, 0xf9, 0xe2, 0xb9, 0xf, 0xae, 0x91, 0x93, 0x19, 0xb1, 0x4b, 0x8c, 0x55, 0x65, 0xb0, 0x42, 0x3c, 0xef, 0xb8, 0x27, 0xd5, 0xf1, 0x20, 0x33, 0x2, 0xa9, 0xd0, 0x15, 0x23, 0x49, 0x8a, 0x4d, 0xb1, 0x3, 0x74}, - output224: []byte{0xea, 0x91, 0xed, 0xc3, 0x93, 0x49, 0x1b, 0x4c, 0xbc, 0x3, 0x5b, 0x85, 0x38, 0xdf, 0x8, 0xe3, 0xc6, 0xb8, 0xca, 0xd1, 0x83, 0x38, 0x5, 0x3c, 0x81, 0xfe, 0x2e, 0x8}, - output256: []byte{0x4c, 0xc2, 0xaf, 0xf1, 0x41, 0x98, 0x7f, 0x4c, 0x2e, 0x68, 0x3f, 0xa2, 0xde, 0x30, 0x4, 0x2b, 0xac, 0xdc, 0xd0, 0x60, 0x87, 0xd7, 0xa7, 0xb0, 0x14, 0x99, 0x6e, 0x9c, 0xfe, 0xaa, 0x58, 0xce}, - output384: []byte{0xf8, 0xb1, 0xf2, 0xc3, 0x17, 0xb9, 0xd1, 0x89, 0x8c, 0x30, 0x5d, 0xec, 0x3c, 0x6c, 0xa, 0xc4, 0x5c, 0xfe, 0x7f, 0x99, 0x5e, 0x94, 0x49, 0x68, 0x20, 0x6c, 0x1c, 0x1b, 0x2c, 0x92, 0xbd, 0x1d, 0x4f, 0xa3, 0x92, 0xff, 0xaa, 0x60, 0x94, 0xc6, 0xaf, 0xf9, 0x5e, 0x47, 0xdc, 0x25, 0x9e, 0xe9}, - output512: []byte{0x3d, 0x23, 0x63, 0x2e, 0xe4, 0xc2, 0xd4, 0xf4, 0x11, 0x8a, 0x2, 0xa6, 0x77, 0xb5, 0xa3, 0x24, 0x27, 0xc7, 0x2b, 0xa5, 0x48, 0x99, 0xba, 0x2e, 0x6c, 0xcd, 0x22, 0xec, 0x3d, 0xef, 0xe0, 0xfc, 0xb0, 0x52, 0xe3, 0xf8, 0x3d, 0x35, 0x78, 0x6c, 0xea, 0x20, 0x80, 0xee, 0xd1, 0x48, 0xa0, 0xa9, 0x46, 0x28, 0xe7, 0x35, 0x20, 0x2e, 0x6b, 0x28, 0x9, 0x99, 0x4c, 0x5f, 0x5b, 0xda, 0xfd, 0xd6}}, - testcase{ - msg: []byte{0xe1, 0xff, 0xfa, 0x98, 0x26, 0xcc, 0xe8, 0xb8, 0x6b, 0xcc, 0xef, 0xb8, 0x79, 0x4e, 0x48, 0xc4, 0x6c, 0xdf, 0x37, 0x20, 0x13, 0xf7, 0x82, 0xec, 0xed, 0x1e, 0x37, 0x82, 0x69, 0xb7, 0xbe, 0x2b, 0x7b, 0xf5, 0x13, 0x74, 0x9, 0x22, 0x61, 0xae, 0x12, 0xe, 0x82, 0x2b, 0xe6, 0x85, 0xf2, 0xe7, 0xa8, 0x36, 0x64, 0xbc, 0xfb, 0xe3, 0x8f, 0xe8, 0x63, 0x3f, 0x24, 0xe6, 0x33, 0xff, 0xe1, 0x98, 0x8e, 0x1b, 0xc5, 0xac, 0xf5, 0x9a, 0x58, 0x70, 0x79, 0xa5, 0x7a, 0x91, 0xb, 0xda, 0x60, 0x6, 0xe, 0x85, 0xb5, 0xf5, 0xb6, 0xf7, 0x76, 0xf0, 0x52, 0x96, 0x39, 0xd9, 0xcc, 0xe4, 0xbd}, - output224: []byte{0xdf, 0x1a, 0xf1, 0x49, 0xe5, 0xc9, 0x2c, 0xb2, 0x91, 0x74, 0xc1, 0xed, 0xb6, 0xed, 0x89, 0x1e, 0xbc, 0xe4, 0x36, 0x60, 0x10, 0xdc, 0x7c, 0xbf, 0xc9, 0xb1, 0xd7, 0x57}, - output256: []byte{0x9a, 0x8c, 0xe8, 0x19, 0x89, 0x4e, 0xfc, 0xcc, 0x21, 0x53, 0xb2, 0x39, 0xc3, 0xad, 0xc3, 0xf0, 0x7d, 0x9, 0x68, 0xea, 0xc5, 0xec, 0x80, 0x80, 0xac, 0x1, 0x74, 0xf2, 0xd5, 0xe6, 0x95, 0x9c}, - output384: []byte{0x4f, 0x43, 0x91, 0x97, 0xc6, 0x64, 0x39, 0xba, 0xf6, 0x56, 0x18, 0xf8, 0x26, 0xe2, 0x99, 0xa3, 0x29, 0x38, 0xb, 0x55, 0x8a, 0x52, 0xb0, 0x71, 0x11, 0x82, 0x58, 0xb, 0xdb, 0xad, 0xba, 0xbb, 0x13, 0xad, 0x66, 0xd6, 0xf, 0xad, 0xdb, 0x9d, 0xed, 0x22, 0x6f, 0xb, 0x40, 0x1a, 0xa8, 0xbe}, - output512: []byte{0xd8, 0xfa, 0x88, 0x68, 0x84, 0xce, 0x57, 0x7a, 0x72, 0x82, 0xde, 0xce, 0xac, 0xf4, 0x78, 0x6e, 0x7c, 0x68, 0xfc, 0x69, 0xb1, 0x41, 0x13, 0x7f, 0xf5, 0xdc, 0x7c, 0xb3, 0xc5, 0xf8, 0xab, 0xc8, 0x45, 0x71, 0x6d, 0xd2, 0x73, 0x97, 0xe8, 0xbd, 0x5c, 0xe2, 0x45, 0x10, 0x7a, 0x98, 0x4a, 0x3f, 0x8b, 0x21, 0xf1, 0x9f, 0x99, 0xed, 0x40, 0x11, 0x86, 0x21, 0xdc, 0x85, 0x30, 0x3a, 0x30, 0xb4}}, - testcase{ - msg: []byte{0x69, 0xf9, 0xab, 0xba, 0x65, 0x59, 0x2e, 0xe0, 0x1d, 0xb4, 0xdc, 0xe5, 0x2d, 0xba, 0xb9, 0xb, 0x8, 0xfc, 0x4, 0x19, 0x36, 0x2, 0x79, 0x2e, 0xe4, 0xda, 0xa2, 0x63, 0x3, 0x3d, 0x59, 0x8, 0x15, 0x87, 0xb0, 0x9b, 0xbe, 0x49, 0xd0, 0xb4, 0x9c, 0x98, 0x25, 0xd2, 0x28, 0x40, 0xb2, 0xff, 0x5d, 0x9c, 0x51, 0x55, 0xf9, 0x75, 0xf8, 0xf2, 0xc2, 0xe7, 0xa9, 0xc, 0x75, 0xd2, 0xe4, 0xa8, 0x4, 0xf, 0xe3, 0x9f, 0x63, 0xbb, 0xaf, 0xb4, 0x3, 0xd9, 0xe2, 0x8c, 0xc3, 0xb8, 0x6e, 0x4, 0xe3, 0x94, 0xa9, 0xc9, 0xe8, 0x6, 0x5b, 0xd3, 0xc8, 0x5f, 0xa9, 0xf0, 0xc7, 0x89, 0x16, 0x0}, - output224: []byte{0x5f, 0x69, 0x84, 0x8, 0xbf, 0xf0, 0x24, 0x6b, 0x5, 0xba, 0xd9, 0x6c, 0xb3, 0x42, 0xb2, 0xfd, 0x2f, 0x11, 0xb6, 0x80, 0x4e, 0xf2, 0xfa, 0x7, 0xa8, 0x1b, 0x9, 0x20}, - output256: []byte{0x8b, 0x35, 0x76, 0x85, 0x25, 0xf5, 0x9a, 0xc7, 0x7d, 0x35, 0x52, 0x2a, 0xc8, 0x85, 0x83, 0x1a, 0x99, 0x47, 0x29, 0x9e, 0x11, 0x4a, 0x89, 0x56, 0xfe, 0x5b, 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, 0x17, 0xa9, 0x3f, 0x24, 0xeb, 0xb, 0x50, 0x6c, 0xeb, 0x70, 0xcb, 0xbc, 0xb8, 0xd7, 0x2b, 0x2a, 0x72, 0x99, 0x3f, 0x90, 0x9a, 0xad, 0x92, 0xf0, 0x44, 0xe0, 0xb5, 0xa2, 0xc9, 0xac, 0x9c, 0xb1, 0x6a, 0xc, 0xa2, 0xf8, 0x1f, 0x49}, - output224: []byte{0xeb, 0xe6, 0xd6, 0x1e, 0x8a, 0x94, 0x6e, 0xd, 0x45, 0xd3, 0x88, 0x9f, 0x9e, 0x36, 0xa, 0xcd, 0x3a, 0x1a, 0x7d, 0x6c, 0x4b, 0x13, 0x7, 0x44, 0x8e, 0x6e, 0x73, 0x57}, - output256: []byte{0x95, 0x5f, 0x1f, 0x7e, 0x4e, 0x54, 0x66, 0xb, 0x26, 0xf3, 0x0, 0x86, 0xf2, 0xdd, 0xda, 0xed, 0xd3, 0x28, 0x13, 0x54, 0x7c, 0x1b, 0x95, 0xd3, 0x5, 0xd8, 0x82, 0x68, 0x2b, 0x4f, 0xf7, 0xa0}, - output384: []byte{0x46, 0xf8, 0x7b, 0xc0, 0x78, 0x49, 0xe9, 0x51, 0x4, 0xe6, 0x7c, 0xc3, 0xdc, 0x71, 0xbd, 0xc1, 0x9, 0xc1, 0x10, 0x2b, 0xfb, 0x1a, 0xcd, 0xfe, 0x2f, 0x6a, 0x23, 0x17, 0x3b, 0x52, 0xbf, 0x83, 0x6c, 0xe0, 0xc, 0xd7, 0xa5, 0xa5, 0xff, 0xe7, 0xd3, 0xbb, 0x8f, 0xab, 0x33, 0xde, 0xce, 0xdf}, - output512: []byte{0x85, 0x62, 0xce, 0x93, 0x99, 0x80, 0x66, 0x23, 0xb2, 0x69, 0x57, 0x12, 0x26, 0x6a, 0xf3, 0xd4, 0xc1, 0x4f, 0x77, 0xd2, 0x44, 0x91, 0x43, 0x37, 0x92, 0x46, 0x96, 0x2c, 0x22, 0x39, 0x8c, 0x81, 0x35, 0x44, 0xa7, 0xde, 0xe4, 0xc4, 0x84, 0x7f, 0x9, 0xd3, 0xcb, 0xe4, 0x37, 0x34, 0x9b, 0x7f, 0xc6, 0x73, 0x8a, 0xc9, 0x70, 0x75, 0xb5, 0xdd, 0x9e, 0x2a, 0xdd, 0x6e, 0xca, 0xa6, 0x10, 0xf4}}, - testcase{ - msg: []byte{0x6d, 0x8c, 0x6e, 0x44, 0x9b, 0xc1, 0x36, 0x34, 0xf1, 0x15, 0x74, 0x9c, 0x24, 0x8c, 0x17, 0xcd, 0x14, 0x8b, 0x72, 0x15, 0x7a, 0x2c, 0x37, 0xbf, 0x89, 0x69, 0xea, 0x83, 0xb4, 0xd6, 0xba, 0x8c, 0xe, 0xe2, 0x71, 0x1c, 0x28, 0xee, 0x11, 0x49, 0x5f, 0x43, 0x4, 0x95, 0x96, 0x52, 0xc, 0xe4, 0x36, 0x0, 0x4b, 0x2, 0x6b, 0x6c, 0x1f, 0x72, 0x92, 0xb9, 0xc4, 0x36, 0xb0, 0x55, 0xcb, 0xb7, 0x2d, 0x53, 0xd, 0x86, 0xd, 0x12, 0x76, 0xa1, 0x50, 0x2a, 0x51, 0x40, 0xe3, 0xc3, 0xf5, 0x4a, 0x93, 0x66, 0x3e, 0x4d, 0x20, 0xed, 0xec, 0x32, 0xd2, 0x84, 0xe2, 0x55, 0x64, 0xf6, 0x24, 0x95, 0x5b, 0x52}, - output224: []byte{0x1b, 0x7f, 0x6b, 0xcb, 0x22, 0x71, 0xac, 0x9c, 0x3b, 0x55, 0x8e, 0x95, 0xf8, 0x52, 0x85, 0xee, 0x75, 0x6b, 0x3, 0xb7, 0x67, 0xa0, 0x1a, 0xc5, 0x7d, 0x7c, 0x6e, 0x94}, - output256: []byte{0x8f, 0xac, 0x5a, 0x34, 0xeb, 0xaf, 0xa3, 0x8b, 0x55, 0x33, 0x36, 0x24, 0xa9, 0x51, 0x4f, 0xe9, 0x7d, 0x99, 0x56, 0xe7, 0x43, 0x9, 0xc5, 0x25, 0x2c, 0xd2, 0x9, 0xd, 0x3b, 0xbe, 0x2f, 0x9e}, - output384: []byte{0xfa, 0x12, 0xb9, 0xd0, 0x70, 0xf6, 0x97, 0xfd, 0x53, 0x91, 0xf3, 0xfc, 0x9c, 0x44, 0x5, 0x6c, 0xed, 0xa6, 0x3f, 0x3, 0x5d, 0x76, 0x66, 0x55, 0xaa, 0x7d, 0xa, 0x57, 0x5e, 0xd5, 0x5b, 0x15, 0xba, 0x6b, 0xaf, 0x56, 0x30, 0x9, 0x40, 0xb5, 0x65, 0xe3, 0x7a, 0x24, 0x8e, 0x2d, 0xca, 0xb8}, - output512: []byte{0x99, 0xad, 0xe7, 0xb1, 0x3e, 0x8e, 0x79, 0xae, 0xa6, 0xed, 0x1, 0xa2, 0x5e, 0x10, 0xe4, 0x1, 0xcd, 0x1d, 0x5, 0x58, 0x84, 0x57, 0x5e, 0xab, 0x3e, 0x66, 0xb2, 0x29, 0x4f, 0x3, 0xf8, 0xd5, 0xdb, 0xf7, 0x2a, 0xb1, 0xae, 0x39, 0x10, 0x31, 0x89, 0x38, 0x3e, 0xbf, 0xd2, 0xe4, 0x32, 0x58, 0x51, 0xc, 0x12, 0x4a, 0x89, 0x4a, 0x79, 0x3b, 0x20, 0x6f, 0xac, 0x75, 0x2c, 0x3, 0x57, 0x89}}, - testcase{ - msg: []byte{0x6e, 0xfc, 0xbc, 0xaf, 0x45, 0x1c, 0x12, 0x9d, 0xbe, 0x0, 0xb9, 0xce, 0xf0, 0xc3, 0x74, 0x9d, 0x3e, 0xe9, 0xd4, 0x1c, 0x7b, 0xd5, 0x0, 0xad, 0xe4, 0xc, 0xdc, 0x65, 0xde, 0xdb, 0xbb, 0xad, 0xb8, 0x85, 0xa5, 0xb1, 0x4b, 0x32, 0xa0, 0xc0, 0xd0, 0x87, 0x82, 0x52, 0x1, 0xe3, 0x3, 0x28, 0x8a, 0x73, 0x38, 0x42, 0xfa, 0x7e, 0x59, 0x9c, 0xc, 0x51, 0x4e, 0x7, 0x8f, 0x5, 0xc8, 0x21, 0xc7, 0xa4, 0x49, 0x8b, 0x1, 0xc4, 0x0, 0x32, 0xe9, 0xf1, 0x87, 0x2a, 0x1c, 0x92, 0x5f, 0xa1, 0x7c, 0xe2, 0x53, 0xe8, 0x93, 0x5e, 0x4c, 0x3c, 0x71, 0x28, 0x22, 0x42, 0xcb, 0x71, 0x6b, 0x20, 0x89, 0xcc, 0xc1}, - output224: []byte{0x43, 0x6d, 0x1b, 0xcd, 0x6b, 0x3d, 0xe2, 0x67, 0x7a, 0x72, 0xb9, 0x3e, 0x2c, 0xed, 0xb6, 0xc, 0x84, 0xa4, 0xfe, 0x12, 0x5a, 0x80, 0x2e, 0x29, 0x97, 0xeb, 0x2e, 0x67}, - output256: []byte{0x62, 0x3, 0x9e, 0xf, 0x53, 0x86, 0x94, 0x80, 0xf8, 0x8c, 0x87, 0xbb, 0x3d, 0x19, 0xa3, 0x1a, 0xad, 0x32, 0x87, 0x8f, 0x27, 0xf2, 0xc4, 0xe7, 0x8f, 0xf0, 0x2b, 0xbe, 0xa2, 0xb8, 0xb0, 0xb9}, - output384: []byte{0x53, 0x4, 0xd6, 0xdb, 0x27, 0x30, 0xfb, 0x7, 0xb8, 0x53, 0x48, 0xb0, 0x22, 0x6b, 0x1a, 0x81, 0xa5, 0x46, 0xba, 0x1f, 0xe2, 0x1, 0xec, 0xce, 0x1e, 0x55, 0x2d, 0xba, 0x6a, 0xfb, 0x84, 0xcc, 0xe7, 0xa6, 0xf9, 0x54, 0xe3, 0x10, 0xa, 0xe1, 0x72, 0x4b, 0x82, 0xcf, 0x1c, 0xbc, 0x41, 0x28}, - output512: []byte{0xd1, 0x28, 0x31, 0xba, 0x39, 0xdb, 0xcd, 0x41, 0xf5, 0x6b, 0xc7, 0xfc, 0x7, 0x1b, 0xda, 0xab, 0xfb, 0x6e, 0x75, 0x72, 0xd0, 0x8b, 0x2f, 0xda, 0x3b, 0xdd, 0xfc, 0x6f, 0xa5, 0x66, 0x2f, 0x4b, 0xdb, 0xfa, 0x43, 0x1c, 0xa2, 0xe3, 0x8b, 0x18, 0x17, 0x27, 0x9, 0x7, 0x2e, 0x50, 0x12, 0xd, 0xb6, 0xbe, 0x93, 0xe8, 0x6c, 0xb4, 0xac, 0xe3, 0xc1, 0x1d, 0xd0, 0xe1, 0xf3, 0xf5, 0xc7, 0x12}}, - testcase{ - msg: []byte{0x43, 0x3c, 0x53, 0x3, 0x13, 0x16, 0x24, 0xc0, 0x2, 0x1d, 0x86, 0x8a, 0x30, 0x82, 0x54, 0x75, 0xe8, 0xd0, 0xbd, 0x30, 0x52, 0xa0, 0x22, 0x18, 0x3, 0x98, 0xf4, 0xca, 0x44, 0x23, 0xb9, 0x82, 0x14, 0xb6, 0xbe, 0xaa, 0xc2, 0x1c, 0x88, 0x7, 0xa2, 0xc3, 0x3f, 0x8c, 0x93, 0xbd, 0x42, 0xb0, 0x92, 0xcc, 0x1b, 0x6, 0xce, 0xdf, 0x32, 0x24, 0xd5, 0xed, 0x1e, 0xc2, 0x97, 0x84, 0x44, 0x4f, 0x22, 0xe0, 0x8a, 0x55, 0xaa, 0x58, 0x54, 0x2b, 0x52, 0x4b, 0x2, 0xcd, 0x3d, 0x5d, 0x5f, 0x69, 0x7, 0xaf, 0xe7, 0x1c, 0x5d, 0x74, 0x62, 0x22, 0x4a, 0x3f, 0x9d, 0x9e, 0x53, 0xe7, 0xe0, 0x84, 0x6d, 0xcb, 0xb4, 0xce}, - output224: []byte{0x62, 0xb1, 0xf, 0x1b, 0x62, 0x36, 0xeb, 0xc2, 0xda, 0x72, 0x95, 0x77, 0x42, 0xa8, 0xd4, 0xe4, 0x8e, 0x21, 0x3b, 0x5f, 0x89, 0x34, 0x60, 0x4b, 0xfd, 0x4d, 0x2c, 0x3a}, - output256: []byte{0xce, 0x87, 0xa5, 0x17, 0x3b, 0xff, 0xd9, 0x23, 0x99, 0x22, 0x16, 0x58, 0xf8, 0x1, 0xd4, 0x5c, 0x29, 0x4d, 0x90, 0x6, 0xee, 0x9f, 0x3f, 0x9d, 0x41, 0x9c, 0x8d, 0x42, 0x77, 0x48, 0xdc, 0x41}, - output384: []byte{0x13, 0x51, 0x14, 0x50, 0x8d, 0xd6, 0x3e, 0x27, 0x9e, 0x70, 0x9c, 0x26, 0xf7, 0x81, 0x7c, 0x4, 0x82, 0x76, 0x6c, 0xde, 0x49, 0x13, 0x2e, 0x3e, 0xdf, 0x2e, 0xed, 0xd8, 0x99, 0x6f, 0x4e, 0x35, 0x96, 0xd1, 0x84, 0x10, 0xb, 0x38, 0x48, 0x68, 0x24, 0x9f, 0x1d, 0x8b, 0x8f, 0xda, 0xa2, 0xc9}, - output512: []byte{0x52, 0x7d, 0x28, 0xe3, 0x41, 0xe6, 0xb1, 0x4f, 0x46, 0x84, 0xad, 0xb4, 0xb8, 0x24, 0xc4, 0x96, 0xc6, 0x48, 0x2e, 0x51, 0x14, 0x95, 0x65, 0xd3, 0xd1, 0x72, 0x26, 0x82, 0x88, 0x84, 0x30, 0x6b, 0x51, 0xd6, 0x14, 0x8a, 0x72, 0x62, 0x2c, 0x2b, 0x75, 0xf5, 0xd3, 0x51, 0xb, 0x79, 0x9d, 0x8b, 0xdc, 0x3, 0xea, 0xed, 0xe4, 0x53, 0x67, 0x6a, 0x6e, 0xc8, 0xfe, 0x3, 0xa1, 0xad, 0xe, 0xab}}, - testcase{ - msg: []byte{0xa8, 0x73, 0xe0, 0xc6, 0x7c, 0xa6, 0x39, 0x2, 0x6b, 0x66, 0x83, 0x0, 0x8f, 0x7a, 0xa6, 0x32, 0x4d, 0x49, 0x79, 0x55, 0xe, 0x9b, 0xce, 0x6, 0x4c, 0xa1, 0xe1, 0xfb, 0x97, 0xa3, 0xb, 0x14, 0x7a, 0x24, 0xf3, 0xf6, 0x66, 0xc0, 0xa7, 0x2d, 0x71, 0x34, 0x8e, 0xde, 0x70, 0x1c, 0xf2, 0xd1, 0x7e, 0x22, 0x53, 0xc3, 0x4d, 0x1e, 0xc3, 0xb6, 0x47, 0xdb, 0xce, 0xf2, 0xf8, 0x79, 0xf4, 0xeb, 0x88, 0x1c, 0x48, 0x30, 0xb7, 0x91, 0x37, 0x8c, 0x90, 0x1e, 0xb7, 0x25, 0xea, 0x5c, 0x17, 0x23, 0x16, 0xc6, 0xd6, 0x6, 0xe0, 0xaf, 0x7d, 0xf4, 0xdf, 0x7f, 0x76, 0xe4, 0x90, 0xcd, 0x30, 0xb2, 0xba, 0xdf, 0x45, 0x68, 0x5f}, - output224: []byte{0x11, 0x86, 0xbe, 0xa0, 0x88, 0xd, 0xa, 0x96, 0xf6, 0xa5, 0x6b, 0xbb, 0x43, 0x1f, 0x4d, 0x26, 0x48, 0x38, 0xbb, 0x1, 0x80, 0xdc, 0xf6, 0x6e, 0xf0, 0xb5, 0x99, 0xca}, - output256: []byte{0x2e, 0xf8, 0x90, 0x7b, 0x60, 0x10, 0x86, 0x38, 0xe5, 0xe, 0xac, 0x53, 0x5c, 0xc4, 0x6c, 0xa0, 0x2e, 0x4, 0x58, 0x1d, 0xdb, 0x42, 0x35, 0xfb, 0xac, 0x5c, 0xb5, 0xc5, 0x35, 0x83, 0xe2, 0x4b}, - output384: []byte{0xd5, 0x60, 0xd5, 0x4a, 0x28, 0x81, 0xed, 0x47, 0xcc, 0x8c, 0x5a, 0xf9, 0x81, 0x8f, 0xee, 0xaf, 0x8, 0xb6, 0x21, 0xb1, 0xae, 0xd4, 0x56, 0x9d, 0x8, 0x80, 0x7a, 0xb, 0x61, 0xf9, 0x2, 0xc1, 0x69, 0x1d, 0x8b, 0x8, 0xff, 0x75, 0x59, 0xf, 0xea, 0xae, 0xd6, 0xe7, 0x5f, 0x4c, 0x9e, 0x3f}, - output512: []byte{0xca, 0xcd, 0xcf, 0x8b, 0xf8, 0x55, 0x4, 0xe, 0x97, 0x95, 0xc4, 0x22, 0x6, 0x9d, 0x8e, 0x37, 0xb6, 0x28, 0x60, 0x66, 0xa2, 0x19, 0x7a, 0x32, 0xb, 0xd9, 0x34, 0x6, 0x1f, 0x66, 0x99, 0x52, 0x27, 0xbe, 0x6b, 0x85, 0xfd, 0x92, 0x8b, 0x83, 0x4d, 0x3c, 0xa4, 0x5e, 0x1a, 0xc3, 0x84, 0x4d, 0x9d, 0xc6, 0x6d, 0x61, 0x58, 0x1e, 0x77, 0x99, 0xcc, 0xfd, 0xe0, 0x8, 0x63, 0x9a, 0xb3, 0xdd}}, - testcase{ - msg: []byte{0x0, 0x69, 0x17, 0xb6, 0x4f, 0x9d, 0xcd, 0xf1, 0xd2, 0xd8, 0x7c, 0x8a, 0x61, 0x73, 0xb6, 0x4f, 0x65, 0x87, 0x16, 0x8e, 0x80, 0xfa, 0xa8, 0xf, 0x82, 0xd8, 0x4f, 0x60, 0x30, 0x1e, 0x56, 0x1e, 0x31, 0x2d, 0x9f, 0xbc, 0xe6, 0x2f, 0x39, 0xa6, 0xfb, 0x47, 0x6e, 0x1, 0xe9, 0x25, 0xf2, 0x6b, 0xcc, 0x91, 0xde, 0x62, 0x14, 0x49, 0xbe, 0x65, 0x4, 0xc5, 0x4, 0x83, 0xa, 0xae, 0x39, 0x40, 0x96, 0xc8, 0xfc, 0x76, 0x94, 0x65, 0x10, 0x51, 0x36, 0x5d, 0x4e, 0xe9, 0x7, 0x1, 0x1, 0xec, 0x9b, 0x68, 0x8, 0x6f, 0x2e, 0xa8, 0xf8, 0xab, 0x7b, 0x81, 0x1e, 0xa8, 0xad, 0x93, 0x4d, 0x5c, 0x9b, 0x62, 0xc6, 0xa, 0x47, 0x71}, - output224: []byte{0x38, 0x3d, 0x2f, 0x41, 0xec, 0xfd, 0xa5, 0x99, 0x4e, 0x81, 0x54, 0x32, 0x99, 0x9d, 0x19, 0x2e, 0x1a, 0x28, 0x2f, 0xf5, 0x66, 0x31, 0x96, 0xa4, 0xa2, 0x68, 0xa6, 0x7d}, - output256: []byte{0xbe, 0x8b, 0x5b, 0xd3, 0x65, 0x18, 0xe9, 0xc5, 0xf4, 0xc7, 0x68, 0xfc, 0x2, 0x46, 0x1b, 0xb3, 0xd3, 0x9a, 0x5d, 0x0, 0xed, 0xef, 0x82, 0xce, 0xc7, 0xdf, 0x35, 0x1d, 0xf8, 0x2, 0x38, 0xe0}, - output384: []byte{0xfe, 0x5f, 0x30, 0xa3, 0x15, 0x58, 0x40, 0x92, 0xa2, 0x71, 0xfd, 0xbc, 0xf4, 0x34, 0x7a, 0x24, 0xd1, 0x4a, 0x1f, 0x98, 0xca, 0xdc, 0x88, 0xdf, 0x28, 0x8c, 0x36, 0xce, 0xa8, 0xf8, 0x9e, 0x90, 0x20, 0x1, 0x99, 0x33, 0xbc, 0xd4, 0xf5, 0xa7, 0x47, 0x9e, 0x3e, 0x4a, 0x57, 0x64, 0x4c, 0x49}, - output512: []byte{0xf4, 0x54, 0xa9, 0x53, 0x50, 0x1e, 0x19, 0x1a, 0x12, 0xa8, 0xc, 0x7a, 0x53, 0x98, 0xf0, 0x81, 0xce, 0xf7, 0x38, 0xe2, 0x5d, 0x48, 0xb0, 0x76, 0xa5, 0x2f, 0x77, 0xfb, 0x9, 0xef, 0xb, 0xc2, 0x32, 0x51, 0x16, 0x2, 0xb, 0xb0, 0x6c, 0x2c, 0x58, 0x5d, 0xa9, 0xf1, 0x15, 0xbd, 0x9d, 0x8f, 0x13, 0xb5, 0xe, 0x8e, 0x1f, 0xb1, 0x66, 0x44, 0x50, 0xfa, 0xe6, 0x90, 0xb7, 0x78, 0x34, 0x0}}, - testcase{ - msg: []byte{0xf1, 0x3c, 0x97, 0x2c, 0x52, 0xcb, 0x3c, 0xc4, 0xa4, 0xdf, 0x28, 0xc9, 0x7f, 0x2d, 0xf1, 0x1c, 0xe0, 0x89, 0xb8, 0x15, 0x46, 0x6b, 0xe8, 0x88, 0x63, 0x24, 0x3e, 0xb3, 0x18, 0xc2, 0xad, 0xb1, 0xa4, 0x17, 0xcb, 0x10, 0x41, 0x30, 0x85, 0x98, 0x54, 0x17, 0x20, 0x19, 0x7b, 0x9b, 0x1c, 0xb5, 0xba, 0x23, 0x18, 0xbd, 0x55, 0x74, 0xd1, 0xdf, 0x21, 0x74, 0xaf, 0x14, 0x88, 0x41, 0x49, 0xba, 0x9b, 0x2f, 0x44, 0x6d, 0x60, 0x9d, 0xf2, 0x40, 0xce, 0x33, 0x55, 0x99, 0x95, 0x7b, 0x8e, 0xc8, 0x8, 0x76, 0xd9, 0xa0, 0x85, 0xae, 0x8, 0x49, 0x7, 0xbc, 0x59, 0x61, 0xb2, 0xb, 0xf5, 0xf6, 0xca, 0x58, 0xd5, 0xda, 0xb3, 0x8a, 0xdb}, - output224: []byte{0xe2, 0x59, 0x4a, 0x63, 0x3b, 0x2d, 0xc6, 0x71, 0xfd, 0xd, 0xdf, 0xd3, 0xbf, 0x72, 0x38, 0x33, 0x2c, 0x42, 0x55, 0x20, 0x82, 0x7c, 0x52, 0x4f, 0xb0, 0xe1, 0x97, 0x78}, - output256: []byte{0x52, 0xcb, 0xc5, 0xdb, 0xe4, 0x9b, 0x0, 0x96, 0x63, 0xc4, 0x3f, 0x7, 0x9d, 0xd1, 0x80, 0xe3, 0x8a, 0x77, 0x53, 0x37, 0x78, 0x6, 0x2a, 0x72, 0xa2, 0x9e, 0x86, 0x4a, 0x58, 0x52, 0x29, 0x22}, - output384: []byte{0xa4, 0xe5, 0xee, 0x13, 0xf, 0xc1, 0x5, 0x81, 0x8c, 0xd1, 0xa0, 0xde, 0x74, 0xf1, 0x8, 0x5b, 0x9b, 0x4d, 0x93, 0x88, 0x9c, 0x50, 0x9d, 0xc3, 0xa2, 0x8, 0xb5, 0x23, 0xd, 0x39, 0xd8, 0xf3, 0x4, 0xbb, 0x40, 0x3f, 0x72, 0xbf, 0xc, 0xf5, 0xe0, 0x2c, 0x4c, 0x4a, 0x8, 0x31, 0xf3, 0x28}, - output512: []byte{0x5f, 0x96, 0x8c, 0xc6, 0xec, 0xf7, 0x1c, 0x58, 0x8a, 0x3c, 0x3b, 0xa6, 0x88, 0x58, 0xbb, 0xff, 0x96, 0x86, 0x1f, 0x66, 0xc0, 0x73, 0x3f, 0xd6, 0x1f, 0xa9, 0x1a, 0x47, 0x9a, 0x49, 0x61, 0x8d, 0xf2, 0x2d, 0x94, 0x90, 0x21, 0x9d, 0xf8, 0x0, 0x8d, 0xc7, 0x88, 0x40, 0xae, 0x2, 0x2c, 0x5d, 0x41, 0xaf, 0x2b, 0x89, 0xd, 0x2, 0x14, 0xe5, 0x62, 0xda, 0x8d, 0xf0, 0xcb, 0x3f, 0x85, 0x22}}, - testcase{ - msg: []byte{0xe3, 0x57, 0x80, 0xeb, 0x97, 0x99, 0xad, 0x4c, 0x77, 0x53, 0x5d, 0x4d, 0xdb, 0x68, 0x3c, 0xf3, 0x3e, 0xf3, 0x67, 0x71, 0x53, 0x27, 0xcf, 0x4c, 0x4a, 0x58, 0xed, 0x9c, 0xbd, 0xcd, 0xd4, 0x86, 0xf6, 0x69, 0xf8, 0x1, 0x89, 0xd5, 0x49, 0xa9, 0x36, 0x4f, 0xa8, 0x2a, 0x51, 0xa5, 0x26, 0x54, 0xec, 0x72, 0x1b, 0xb3, 0xaa, 0xb9, 0x5d, 0xce, 0xb4, 0xa8, 0x6a, 0x6a, 0xfa, 0x93, 0x82, 0x6d, 0xb9, 0x23, 0x51, 0x7e, 0x92, 0x8f, 0x33, 0xe3, 0xfb, 0xa8, 0x50, 0xd4, 0x56, 0x60, 0xef, 0x83, 0xb9, 0x87, 0x6a, 0xcc, 0xaf, 0xa2, 0xa9, 0x98, 0x7a, 0x25, 0x4b, 0x13, 0x7c, 0x6e, 0x14, 0xa, 0x21, 0x69, 0x1e, 0x10, 0x69, 0x41, 0x38, 0x48}, - output224: []byte{0x23, 0x47, 0x64, 0xaa, 0xe8, 0xc3, 0x9b, 0x15, 0x71, 0xd7, 0x74, 0x1b, 0xb1, 0x76, 0xff, 0x86, 0x24, 0x60, 0x70, 0xec, 0x9a, 0xc9, 0x7a, 0x1b, 0x2e, 0xb3, 0x54, 0x72}, - output256: []byte{0x3a, 0x8d, 0xfc, 0xfd, 0x1b, 0x36, 0x20, 0x3, 0xdd, 0xfa, 0x17, 0x91, 0x7, 0x27, 0x53, 0x9e, 0x64, 0xb1, 0x80, 0x21, 0xab, 0xba, 0x1, 0x8b, 0x5f, 0x58, 0xd7, 0x1f, 0x7a, 0x44, 0x97, 0x33}, - output384: []byte{0x9f, 0xb5, 0x70, 0x5, 0x2, 0xe0, 0x19, 0x26, 0x82, 0x4f, 0x46, 0xe9, 0xf6, 0x18, 0x94, 0xf9, 0x48, 0x7d, 0xbc, 0xf8, 0xae, 0x62, 0x17, 0x20, 0x3c, 0x85, 0x60, 0x6f, 0x97, 0x55, 0x66, 0x53, 0x93, 0x76, 0xd6, 0x23, 0x9d, 0xb0, 0x4a, 0xef, 0x9b, 0xf4, 0x8c, 0xa4, 0xf1, 0x91, 0xa9, 0xb}, - output512: []byte{0xe7, 0x14, 0x94, 0x61, 0xf9, 0xcd, 0x0, 0xb7, 0x1c, 0x21, 0x6c, 0x50, 0x4, 0x1b, 0x3e, 0xda, 0x97, 0x7, 0xd7, 0x36, 0xd, 0x4c, 0x21, 0x74, 0xc, 0x44, 0xc2, 0x12, 0x25, 0x6a, 0x31, 0xda, 0x39, 0x8f, 0xe0, 0x97, 0x8, 0xe4, 0x50, 0xea, 0x4e, 0x28, 0x26, 0xb7, 0xec, 0x20, 0xbe, 0xf7, 0x6c, 0xd2, 0xfb, 0xd9, 0xd0, 0x96, 0xaf, 0x6f, 0x77, 0xf8, 0x4a, 0xbc, 0x2e, 0x4f, 0xb0, 0x93}}, - testcase{ - msg: []byte{0x64, 0xec, 0x2, 0x1c, 0x95, 0x85, 0xe0, 0x1f, 0xfe, 0x6d, 0x31, 0xbb, 0x50, 0xd4, 0x4c, 0x79, 0xb6, 0x99, 0x3d, 0x72, 0x67, 0x81, 0x63, 0xdb, 0x47, 0x49, 0x47, 0xa0, 0x53, 0x67, 0x46, 0x19, 0xd1, 0x58, 0x1, 0x6a, 0xdb, 0x24, 0x3f, 0x5c, 0x8d, 0x50, 0xaa, 0x92, 0xf5, 0xa, 0xb3, 0x6e, 0x57, 0x9f, 0xf2, 0xda, 0xbb, 0x78, 0xa, 0x2b, 0x52, 0x93, 0x70, 0xda, 0xa2, 0x99, 0x20, 0x7c, 0xfb, 0xcd, 0xd3, 0xa9, 0xa2, 0x50, 0x6, 0xd1, 0x9c, 0x4f, 0x1f, 0xe3, 0x3e, 0x4b, 0x1e, 0xae, 0xc3, 0x15, 0xd8, 0xc6, 0xee, 0x1e, 0x73, 0x6, 0x23, 0xfd, 0x19, 0x41, 0x87, 0x5b, 0x92, 0x4e, 0xb5, 0x7d, 0x6d, 0xc, 0x2e, 0xdc, 0x4e, 0x78, 0xd6}, - output224: []byte{0xa6, 0x34, 0xd7, 0xeb, 0xaa, 0x2b, 0xc0, 0x4, 0x3e, 0xb5, 0xe2, 0x37, 0x69, 0xe, 0x38, 0xff, 0x1e, 0x5, 0xee, 0x5a, 0x4, 0x28, 0x82, 0xa2, 0x33, 0xa2, 0xd9, 0x2a}, - output256: []byte{0xfa, 0x22, 0x1d, 0xee, 0xe8, 0xe, 0x25, 0xe5, 0x3c, 0x6c, 0x44, 0x8a, 0xa2, 0x20, 0x28, 0xb7, 0x25, 0x1, 0xf0, 0x7d, 0x1f, 0xf2, 0xc3, 0xfc, 0x7f, 0x93, 0xaf, 0x98, 0x38, 0xb2, 0xd0, 0xa9}, - output384: []byte{0xf2, 0xe0, 0xff, 0x6c, 0xf4, 0x80, 0x1c, 0xff, 0x2e, 0xca, 0x17, 0x3, 0xe4, 0xe9, 0x56, 0xc0, 0x7, 0xa1, 0xf2, 0x70, 0x94, 0x30, 0xf1, 0xf7, 0xa0, 0xa4, 0xfd, 0xd1, 0x6a, 0x6, 0x35, 0x22, 0xa4, 0xdf, 0xb6, 0xc4, 0x1f, 0xa5, 0x29, 0xc2, 0xe3, 0x25, 0xf8, 0xcd, 0xd4, 0xf8, 0xda, 0x96}, - output512: []byte{0x77, 0x9, 0x74, 0x13, 0xca, 0xa5, 0xa2, 0xd3, 0x82, 0x59, 0xd4, 0x7e, 0xc0, 0x78, 0x87, 0x1f, 0xa0, 0x9e, 0xe5, 0x61, 0x4d, 0x4c, 0x14, 0xfe, 0xb7, 0xa9, 0x5c, 0x92, 0x1c, 0xa, 0xae, 0x93, 0xb8, 0x73, 0x7a, 0x6d, 0xc8, 0x9e, 0x57, 0x69, 0x3b, 0xe8, 0xa0, 0x71, 0x2, 0x6, 0x66, 0x4b, 0x80, 0xb6, 0x57, 0xa1, 0x7, 0x96, 0x5, 0xa0, 0xff, 0x96, 0x64, 0xbb, 0xcb, 0x7, 0x22, 0xd6}}, - testcase{ - msg: []byte{0x59, 0x54, 0xba, 0xb5, 0x12, 0xcf, 0x32, 0x7d, 0x66, 0xb5, 0xd9, 0xf2, 0x96, 0x18, 0x0, 0x80, 0x40, 0x26, 0x24, 0xad, 0x76, 0x28, 0x50, 0x6b, 0x55, 0x5e, 0xea, 0x83, 0x82, 0x56, 0x23, 0x24, 0xcf, 0x45, 0x2f, 0xba, 0x4a, 0x21, 0x30, 0xde, 0x3e, 0x16, 0x5d, 0x11, 0x83, 0x1a, 0x27, 0xd, 0x9c, 0xb9, 0x7c, 0xe8, 0xc2, 0xd3, 0x2a, 0x96, 0xf5, 0xd, 0x71, 0x60, 0xb, 0xb4, 0xca, 0x26, 0x8c, 0xf9, 0x8e, 0x90, 0xd6, 0x49, 0x6b, 0xa, 0x66, 0x19, 0xa5, 0xa8, 0xc6, 0x3d, 0xb6, 0xd8, 0xa0, 0x63, 0x4d, 0xfc, 0x6c, 0x7e, 0xc8, 0xea, 0x9c, 0x0, 0x6b, 0x6c, 0x45, 0x6f, 0x1b, 0x20, 0xcd, 0x19, 0xe7, 0x81, 0xaf, 0x20, 0x45, 0x4a, 0xc8, 0x80}, - output224: []byte{0xef, 0x3, 0xfb, 0xb1, 0xef, 0x32, 0x96, 0xee, 0xcf, 0xb9, 0x89, 0x9, 0xe4, 0x16, 0xd1, 0x13, 0xb5, 0x74, 0x1e, 0x44, 0x96, 0x2e, 0xc5, 0x79, 0x93, 0xc6, 0xda, 0x5d}, - output256: []byte{0xed, 0x9c, 0x8b, 0x87, 0xfc, 0xe2, 0x7b, 0xe4, 0xe9, 0x56, 0x10, 0xdb, 0x1d, 0xdd, 0xc, 0x3, 0x58, 0x47, 0xf4, 0x69, 0x9d, 0xfc, 0x8c, 0x3, 0x9a, 0x79, 0x8a, 0x30, 0x34, 0x3a, 0x60, 0x59}, - output384: []byte{0x62, 0x2, 0x9d, 0x96, 0x2d, 0x2e, 0x32, 0x36, 0x88, 0xdc, 0x58, 0x51, 0xc5, 0x49, 0xda, 0x39, 0xef, 0x49, 0xcb, 0x99, 0x4d, 0x2d, 0x6c, 0x51, 0xc5, 0x7b, 0x9b, 0xba, 0xb3, 0x75, 0xaa, 0x10, 0xbd, 0x6, 0x5, 0x20, 0x8d, 0x99, 0x46, 0xea, 0x47, 0x25, 0x73, 0x88, 0x2, 0x30, 0xdd, 0x2d}, - output512: []byte{0x55, 0xd8, 0xe5, 0x20, 0x23, 0x60, 0xd7, 0xd5, 0x84, 0x14, 0x19, 0x36, 0x2f, 0x86, 0x4c, 0xc9, 0x0, 0xe1, 0x1c, 0x58, 0x2f, 0xd0, 0xca, 0xb2, 0xff, 0x5f, 0x16, 0x80, 0xf6, 0xce, 0x92, 0x7b, 0x53, 0x79, 0xe2, 0x7a, 0x33, 0x5e, 0xba, 0xfe, 0x12, 0x86, 0xb9, 0xd4, 0xa1, 0x72, 0xab, 0x76, 0x1a, 0x36, 0xea, 0xde, 0x60, 0xf1, 0x4, 0x68, 0xea, 0xc4, 0xce, 0xaf, 0xbf, 0x63, 0xc7, 0xcc}}, - testcase{ - msg: []byte{0x3, 0xd9, 0xf9, 0x2b, 0x2c, 0x56, 0x57, 0x9, 0xa5, 0x68, 0x72, 0x4a, 0xa, 0xff, 0x90, 0xf8, 0xf3, 0x47, 0xf4, 0x3b, 0x2, 0x33, 0x8f, 0x94, 0xa0, 0x3e, 0xd3, 0x2e, 0x6f, 0x33, 0x66, 0x6f, 0xf5, 0x80, 0x2d, 0xa4, 0xc8, 0x1b, 0xdc, 0xe0, 0xd0, 0xe8, 0x6c, 0x4, 0xaf, 0xd4, 0xed, 0xc2, 0xfc, 0x8b, 0x41, 0x41, 0xc2, 0x97, 0x5b, 0x6f, 0x7, 0x63, 0x9b, 0x19, 0x94, 0xc9, 0x73, 0xd9, 0xa9, 0xaf, 0xce, 0x3d, 0x9d, 0x36, 0x58, 0x62, 0x0, 0x34, 0x98, 0x51, 0x3b, 0xfa, 0x16, 0x6d, 0x26, 0x29, 0xe3, 0x14, 0xd9, 0x74, 0x41, 0x66, 0x7b, 0x0, 0x74, 0x14, 0xe7, 0x39, 0xd7, 0xfe, 0xbf, 0xf, 0xe3, 0xc3, 0x2c, 0x17, 0xaa, 0x18, 0x8a, 0x86, 0x83}, - output224: []byte{0x21, 0xd, 0x24, 0x5c, 0xc8, 0xb5, 0xa7, 0xb4, 0xc1, 0xb1, 0x18, 0xa9, 0x89, 0xe, 0xcd, 0xdc, 0x34, 0xa6, 0x6e, 0xa9, 0x28, 0x5, 0xb7, 0xa7, 0xc1, 0x9a, 0x94, 0x4a}, - output256: []byte{0xa4, 0x85, 0xcc, 0x9c, 0xf4, 0xca, 0x4f, 0x65, 0x9f, 0x89, 0xa0, 0xb7, 0x91, 0xa4, 0x42, 0x39, 0x53, 0x42, 0x4a, 0xc5, 0x71, 0x46, 0xb8, 0x79, 0xd3, 0x85, 0xa9, 0xe4, 0x6, 0x2a, 0xfe, 0x52}, - output384: []byte{0x25, 0xe5, 0x46, 0xf7, 0x6e, 0xa9, 0xf9, 0x8e, 0x3, 0xe3, 0xb2, 0xf4, 0xab, 0x60, 0x81, 0x85, 0x7, 0x36, 0x58, 0xe7, 0xed, 0xa0, 0x77, 0x7b, 0xd5, 0xb0, 0x47, 0xa5, 0x90, 0x85, 0xc3, 0xc5, 0x0, 0x91, 0x63, 0x47, 0xd4, 0xf7, 0x7e, 0x38, 0xe3, 0x51, 0x59, 0xaf, 0x13, 0x3e, 0xd6, 0x38}, - output512: []byte{0xef, 0xfb, 0x3, 0xb4, 0x97, 0xad, 0xd6, 0x23, 0xa, 0xe, 0xd9, 0x91, 0x22, 0xea, 0x86, 0x81, 0x38, 0x64, 0x4a, 0xb8, 0x1e, 0x86, 0x14, 0x91, 0xe5, 0x26, 0xfa, 0xe3, 0x7c, 0x39, 0x87, 0x2c, 0xa7, 0x31, 0x80, 0x4a, 0x0, 0x4, 0x59, 0x98, 0x49, 0x47, 0x8a, 0x78, 0x7b, 0xc7, 0xfc, 0xe2, 0x19, 0x3, 0xed, 0x55, 0x1d, 0x7d, 0xb8, 0x81, 0xd2, 0xa2, 0xc3, 0x67, 0xb6, 0x16, 0x85, 0x47}}, - testcase{ - msg: []byte{0xf3, 0x1e, 0x8b, 0x4f, 0x9e, 0x6, 0x21, 0xd5, 0x31, 0xd2, 0x2a, 0x38, 0xb, 0xe5, 0xd9, 0xab, 0xd5, 0x6f, 0xae, 0xc5, 0x3c, 0xbd, 0x39, 0xb1, 0xfa, 0xb2, 0x30, 0xea, 0x67, 0x18, 0x44, 0x40, 0xe5, 0xb1, 0xd1, 0x54, 0x57, 0xbd, 0x25, 0xf5, 0x62, 0x4, 0xfa, 0x91, 0x7f, 0xa4, 0x8e, 0x66, 0x90, 0x16, 0xcb, 0x48, 0xc1, 0xff, 0xc1, 0xe1, 0xe4, 0x52, 0x74, 0xb3, 0xb4, 0x73, 0x79, 0xe0, 0xa, 0x43, 0x84, 0x3c, 0xf8, 0x60, 0x1a, 0x55, 0x51, 0x41, 0x1e, 0xc1, 0x25, 0x3, 0xe5, 0xaa, 0xc4, 0x3d, 0x86, 0x76, 0xa1, 0xb2, 0x29, 0x7e, 0xc7, 0xa0, 0x80, 0xd, 0xbf, 0xee, 0x4, 0x29, 0x2e, 0x93, 0x7f, 0x21, 0xc0, 0x5, 0xf1, 0x74, 0x11, 0x47, 0x30, 0x41}, - output224: []byte{0x51, 0x7b, 0xae, 0x1, 0x7, 0x15, 0xa0, 0x20, 0x43, 0x5c, 0xfd, 0xb5, 0x31, 0xb8, 0x56, 0xc5, 0x70, 0x4e, 0xe, 0xc6, 0x11, 0x36, 0xf, 0x60, 0xd5, 0xb7, 0x61, 0x61}, - output256: []byte{0x93, 0xcd, 0x43, 0x69, 0xa7, 0x79, 0x62, 0x39, 0xa5, 0xcd, 0xf7, 0x8b, 0xce, 0x22, 0xeb, 0xb2, 0x13, 0x7a, 0x63, 0x1c, 0x3a, 0x61, 0x3d, 0x5e, 0x35, 0x81, 0x6d, 0x2a, 0x64, 0xa3, 0x49, 0x47}, - output384: []byte{0xbe, 0xef, 0xce, 0xff, 0x9e, 0x2d, 0x8, 0x25, 0xd6, 0xe, 0xa2, 0xe, 0x52, 0x71, 0xbf, 0x49, 0xc4, 0xae, 0x3a, 0x5b, 0x54, 0xb5, 0x60, 0x50, 0x98, 0x8d, 0xd3, 0xdf, 0x5d, 0xb5, 0xeb, 0x4f, 0x10, 0x2, 0xef, 0xbf, 0xba, 0xed, 0x2f, 0xc7, 0x21, 0x79, 0xde, 0x44, 0x11, 0x69, 0x76, 0xb2}, - output512: []byte{0xa2, 0x26, 0x9a, 0x6e, 0xf2, 0xea, 0x8f, 0x1c, 0xf8, 0xbc, 0x33, 0x94, 0xd2, 0x76, 0x57, 0xb0, 0xdb, 0x99, 0x6c, 0x55, 0xe7, 0xc4, 0x77, 0x84, 0xc0, 0xb4, 0x51, 0x20, 0x2f, 0xc5, 0x27, 0x96, 0x79, 0xd7, 0x9e, 0x6, 0xf8, 0xdb, 0xaa, 0x9a, 0x63, 0x66, 0x5f, 0xd0, 0xe9, 0x14, 0xd1, 0x3c, 0x6e, 0x5, 0x6e, 0xa0, 0x6, 0xda, 0xaf, 0x4c, 0xb6, 0x1d, 0x26, 0x29, 0x46, 0x8e, 0x3d, 0x25}}, - testcase{ - msg: []byte{0x75, 0x8e, 0xa3, 0xfe, 0xa7, 0x38, 0x97, 0x3d, 0xb0, 0xb8, 0xbe, 0x7e, 0x59, 0x9b, 0xbe, 0xf4, 0x51, 0x93, 0x73, 0xd6, 0xe6, 0xdc, 0xd7, 0x19, 0x5e, 0xa8, 0x85, 0xfc, 0x99, 0x1d, 0x89, 0x67, 0x62, 0x99, 0x27, 0x59, 0xc2, 0xa0, 0x90, 0x2, 0x91, 0x2f, 0xb0, 0x8e, 0xc, 0xb5, 0xb7, 0x6f, 0x49, 0x16, 0x2a, 0xeb, 0x8c, 0xf8, 0x7b, 0x17, 0x2c, 0xf3, 0xad, 0x19, 0x2, 0x53, 0xdf, 0x61, 0x2f, 0x77, 0xb1, 0xf0, 0xc5, 0x32, 0xe3, 0xb5, 0xfc, 0x99, 0xc2, 0xd3, 0x1f, 0x8f, 0x65, 0x1, 0x16, 0x95, 0xa0, 0x87, 0xa3, 0x5e, 0xe4, 0xee, 0xe5, 0xe3, 0x34, 0xc3, 0x69, 0xd8, 0xee, 0x5d, 0x29, 0xf6, 0x95, 0x81, 0x5d, 0x86, 0x6d, 0xa9, 0x9d, 0xf3, 0xf7, 0x94, 0x3}, - output224: []byte{0x79, 0xd4, 0x78, 0xb4, 0xbc, 0x5e, 0x6f, 0xc2, 0xd4, 0x6, 0xbb, 0x1c, 0x38, 0x34, 0xa5, 0xce, 0x39, 0x7a, 0x88, 0xe8, 0x1, 0x35, 0xf5, 0x5d, 0x8f, 0xe3, 0x2c, 0x5e}, - output256: []byte{0x37, 0x51, 0xce, 0x8, 0x75, 0xd, 0x92, 0x7e, 0xb5, 0xc3, 0xae, 0x4c, 0xa6, 0x2a, 0x70, 0x3a, 0x48, 0x1d, 0x86, 0xa4, 0xfa, 0x1c, 0x1, 0x1e, 0x81, 0x2b, 0x4b, 0xc0, 0xa2, 0xfe, 0xf0, 0x8d}, - output384: []byte{0x7d, 0x18, 0x25, 0x4d, 0x46, 0xa1, 0x4d, 0x3, 0x83, 0xec, 0x56, 0xac, 0x9c, 0xa2, 0xfd, 0xa7, 0x88, 0x5a, 0x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0xd7, 0xa3, 0x54, 0x9c, 0xd7, 0x57, 0x60, 0xc2, 0x1b, 0xb1, 0x5b, 0x44, 0x75, 0x89, 0xe8, 0x6e, 0x8d, 0x76, 0xb1, 0xe9, 0xce, 0xd2}, - output224: []byte{0xf7, 0xba, 0x7a, 0x56, 0xaf, 0xc1, 0xc5, 0x8e, 0x62, 0x84, 0x1c, 0x3b, 0x98, 0xf5, 0x67, 0x71, 0x99, 0xf2, 0x4b, 0x53, 0x4b, 0xd, 0x52, 0xd9, 0xa5, 0xc9, 0x54, 0x95}, - output256: []byte{0xa8, 0x8c, 0x7e, 0xf7, 0xb8, 0x9b, 0x7b, 0x6f, 0x75, 0xd8, 0x39, 0x22, 0xb8, 0xfd, 0x0, 0xf0, 0x34, 0xd7, 0x19, 0xf9, 0x7c, 0x67, 0x88, 0x41, 0x21, 0x43, 0x44, 0x47, 0xae, 0x9d, 0xd3, 0xb9}, - output384: []byte{0x1e, 0x3e, 0x0, 0x7c, 0xe3, 0x77, 0x92, 0xd8, 0xa4, 0x42, 0x3b, 0x79, 0x7e, 0x87, 0x6e, 0x89, 0x85, 0x95, 0x90, 0xde, 0xdd, 0x39, 0x71, 0x1a, 0xd0, 0xf1, 0xde, 0x2f, 0xd9, 0x25, 0xf4, 0x32, 0xb, 0x44, 0xbd, 0x57, 0xdd, 0xc7, 0x5, 0x4, 0x27, 0x94, 0x3e, 0x3c, 0x95, 0x7d, 0x4b, 0x6d}, - output512: []byte{0x2b, 0x43, 0x56, 0xa6, 0x4d, 0xf3, 0x19, 0x36, 0xb2, 0x7f, 0x45, 0x30, 0xf0, 0x76, 0xee, 0x73, 0xe7, 0x1e, 0x4e, 0x48, 0xab, 0xde, 0x4, 0xff, 0x1f, 0x54, 0x8e, 0x7, 0x27, 0xf4, 0xa5, 0x81, 0xb, 0x71, 0x87, 0x41, 0x87, 0xfd, 0x96, 0xed, 0x51, 0xd, 0xd, 0x68, 0x86, 0xaf, 0x11, 0x96, 0xa, 0xb, 0x3b, 0xad, 0x1e, 0xe7, 0x5d, 0xda, 0x4c, 0xdc, 0x14, 0x8e, 0x16, 0x2e, 0xda, 0xe9}}, - testcase{ - msg: []byte{0xf6, 0x90, 0xa1, 0x32, 0xab, 0x46, 0xb2, 0x8e, 0xdf, 0xa6, 0x47, 0x92, 0x83, 0xd6, 0x44, 0x4e, 0x37, 0x1c, 0x64, 0x59, 0x10, 0x8a, 0xfd, 0x9c, 0x35, 0xdb, 0xd2, 0x35, 0xe0, 0xb6, 0xb6, 0xff, 0x4c, 0x4e, 0xa5, 0x8e, 0x75, 0x54, 0xbd, 0x0, 0x24, 0x60, 0x43, 0x3b, 0x21, 0x64, 0xca, 0x51, 0xe8, 0x68, 0xf7, 0x94, 0x7d, 0x7d, 0x7a, 0xd, 0x79, 0x2e, 0x4a, 0xbf, 0xb, 0xe5, 0xf4, 0x50, 0x85, 0x3c, 0xc4, 0xd, 0x85, 0x48, 0x5b, 0x2b, 0x88, 0x57, 0xea, 0x31, 0xb5, 0xea, 0x6e, 0x4c, 0xcf, 0xa2, 0xf3, 0xa7, 0xef, 0x33, 0x80, 0x6, 0x6d, 0x7d, 0x89, 0x79, 0xfd, 0xac, 0x61, 0x8a, 0xad, 0x3d, 0x7e, 0x88, 0x6d, 0xea, 0x4f, 0x0, 0x5a, 0xe4, 0xad, 0x5, 0xe5, 0x6, 0x5f}, - output224: []byte{0x78, 0xa9, 0xb, 0x76, 0x9e, 0x9a, 0x32, 0x6c, 0x93, 0xd5, 0xa6, 0xa6, 0x10, 0x5a, 0xee, 0x3, 0x1d, 0xce, 0xb2, 0xc8, 0xd2, 0x22, 0xb3, 0x6e, 0x2, 0xf2, 0x7d, 0xb6}, - output256: []byte{0x2b, 0x4f, 0x8f, 0x9e, 0xf7, 0xd6, 0xed, 0x60, 0xbb, 0x48, 0x81, 0xe6, 0x35, 0xe0, 0xf8, 0x87, 0xa5, 0x1b, 0xc, 0x1a, 0x42, 0xba, 0xb0, 0x77, 0x97, 0x6b, 0x43, 0xd2, 0xc7, 0x15, 0xe1, 0x1a}, - output384: []byte{0xd1, 0xd2, 0x63, 0xb5, 0x31, 0x1b, 0x5, 0xc7, 0xb9, 0xf7, 0x78, 0x3e, 0x3a, 0xfd, 0x9a, 0x2e, 0x75, 0x79, 0x1c, 0xe0, 0x50, 0x3e, 0xd8, 0x20, 0x47, 0x4b, 0x35, 0x34, 0xd, 0x2c, 0xc8, 0x4b, 0x2, 0x70, 0x92, 0x1b, 0xbd, 0x96, 0x57, 0x22, 0x1, 0x1a, 0xa3, 0xc, 0xe4, 0x35, 0x29, 0x26}, - output512: []byte{0xed, 0xcb, 0x59, 0x98, 0x42, 0x67, 0xbb, 0x0, 0x40, 0x2a, 0x78, 0xf2, 0xca, 0x34, 0x5e, 0xf2, 0x49, 0x49, 0x56, 0x17, 0x2e, 0x10, 0x92, 0x7e, 0xe6, 0x3a, 0xff, 0x23, 0xd0, 0xc8, 0x34, 0xbc, 0xa5, 0xc, 0x47, 0xcd, 0xbf, 0xfd, 0x89, 0x95, 0x3, 0x63, 0x7, 0xe9, 0xed, 0x4b, 0x14, 0x3e, 0x85, 0x34, 0x50, 0x36, 0x7d, 0xe, 0x14, 0xaf, 0xc8, 0x49, 0x0, 0x73, 0x65, 0x3c, 0xd8, 0x50}}, - testcase{ - msg: []byte{0x58, 0xd6, 0xa9, 0x9b, 0xc6, 0x45, 0x88, 0x24, 0xb2, 0x56, 0x91, 0x67, 0x70, 0xa8, 0x41, 0x70, 0x40, 0x72, 0x1c, 0xcc, 0xfd, 0x4b, 0x79, 0xea, 0xcd, 0x8b, 0x65, 0xa3, 0x76, 0x7c, 0xe5, 0xba, 0x7e, 0x74, 0x10, 0x4c, 0x98, 0x5a, 0xc5, 0x6b, 0x8c, 0xc9, 0xae, 0xbd, 0x16, 0xfe, 0xbd, 0x4c, 0xda, 0x5a, 0xdb, 0x13, 0xb, 0xf, 0xf2, 0x32, 0x9c, 0xc8, 0xd6, 0x11, 0xeb, 0x14, 0xda, 0xc2, 0x68, 0xa2, 0xf9, 0xe6, 0x33, 0xc9, 0x9d, 0xe3, 0x39, 0x97, 0xfe, 0xa4, 0x1c, 0x52, 0xa7, 0xc5, 0xe1, 0x31, 0x7d, 0x5b, 0x5d, 0xae, 0xd3, 0x5e, 0xba, 0x7d, 0x5a, 0x60, 0xe4, 0x5d, 0x1f, 0xa7, 0xea, 0xab, 0xc3, 0x5f, 0x5c, 0x2b, 0xa, 0xf, 0x23, 0x79, 0x23, 0x19, 0x53, 0x32, 0x2c, 0x4e}, - output224: []byte{0x3d, 0x9d, 0x5c, 0x2f, 0xd2, 0xf6, 0xf, 0x4b, 0xb8, 0x9e, 0x11, 0xfd, 0x3b, 0xc2, 0xfb, 0xd6, 0x56, 0x2, 0xeb, 0x3f, 0x3f, 0x38, 0xd6, 0xfa, 0x3, 0xbd, 0xce, 0x2c}, - output256: []byte{0x58, 0x6c, 0xff, 0xdc, 0x43, 0x43, 0x13, 0xcc, 0x4e, 0x13, 0x3e, 0x85, 0xac, 0x88, 0xb3, 0xe5, 0xde, 0xa7, 0x18, 0x18, 0xab, 0xca, 0xc2, 0x36, 0xf0, 0xaa, 0xe4, 0x18, 0xf7, 0x2b, 0x6c, 0xde}, - output384: []byte{0xe4, 0x82, 0xb0, 0xc1, 0xb2, 0x5, 0x7f, 0x1b, 0x6b, 0x89, 0x7b, 0xdc, 0x23, 0xd, 0xca, 0x2b, 0x48, 0xff, 0xc0, 0xe4, 0x60, 0xa, 0xc4, 0xa, 0x44, 0xdc, 0xe0, 0x3e, 0x99, 0xa8, 0xd1, 0xdf, 0x94, 0x90, 0x8a, 0x9f, 0xeb, 0xa0, 0x40, 0x5d, 0xa7, 0x95, 0x69, 0xe7, 0x50, 0x59, 0xf9, 0xce}, - output512: []byte{0xd0, 0xb4, 0x53, 0xfb, 0xe7, 0x9, 0xc6, 0x91, 0x25, 0xdc, 0x8f, 0xe9, 0xe8, 0xae, 0x92, 0x45, 0x21, 0x16, 0x12, 0x97, 0x3, 0x73, 0xb4, 0x54, 0xf8, 0x65, 0x6a, 0x75, 0x5e, 0x84, 0x35, 0xb3, 0x21, 0xdd, 0x3a, 0x98, 0xf, 0xa2, 0x87, 0x19, 0x64, 0x17, 0x47, 0xe2, 0x54, 0xdc, 0x42, 0xc9, 0xbf, 0x1, 0x2b, 0x4d, 0x6d, 0xbd, 0x7e, 0xd1, 0x30, 0x20, 0xa8, 0x3b, 0x44, 0xc5, 0x4, 0xaa}}, - testcase{ - msg: []byte{0xbe, 0xfa, 0xb5, 0x74, 0x39, 0x6d, 0x7f, 0x8b, 0x67, 0x5, 0xe2, 0xd5, 0xb5, 0x8b, 0x2c, 0x1c, 0x82, 0xb, 0xb2, 0x4e, 0x3f, 0x4b, 0xae, 0x3e, 0x8f, 0xbc, 0xd3, 0x6d, 0xbf, 0x73, 0x4e, 0xe1, 0x4e, 0x5d, 0x6a, 0xb9, 0x72, 0xae, 0xdd, 0x35, 0x40, 0x23, 0x54, 0x66, 0xe8, 0x25, 0x85, 0xe, 0xe4, 0xc5, 0x12, 0xea, 0x97, 0x95, 0xab, 0xfd, 0x33, 0xf3, 0x30, 0xd9, 0xfd, 0x7f, 0x79, 0xe6, 0x2b, 0xbb, 0x63, 0xa6, 0xea, 0x85, 0xde, 0x15, 0xbe, 0xae, 0xea, 0x6f, 0x8d, 0x20, 0x4a, 0x28, 0x95, 0x60, 0x59, 0xe2, 0x63, 0x2d, 0x11, 0x86, 0x1d, 0xfb, 0xe, 0x65, 0xbc, 0x7, 0xac, 0x8a, 0x15, 0x93, 0x88, 0xd5, 0xc3, 0x27, 0x7e, 0x22, 0x72, 0x86, 0xf6, 0x5f, 0xf5, 0xe5, 0xb5, 0xae, 0xc1}, - output224: []byte{0xe1, 0xfa, 0xbe, 0x16, 0x15, 0x25, 0x60, 0x38, 0x7f, 0xad, 0xad, 0x33, 0x24, 0xcb, 0xb9, 0x4d, 0x8a, 0xf9, 0x68, 0x78, 0x6c, 0x3c, 0x99, 0x4c, 0x8f, 0x92, 0x6d, 0x32}, - output256: []byte{0x52, 0xd1, 0x4a, 0xb9, 0x6b, 0x24, 0xaa, 0x4a, 0x7a, 0x55, 0x72, 0x1a, 0xa8, 0x55, 0xb, 0x1f, 0xcc, 0xac, 0x36, 0x53, 0xc7, 0x82, 0x34, 0x78, 0x3f, 0x72, 0x95, 0xae, 0x5f, 0x39, 0xa1, 0x7a}, - output384: []byte{0xe5, 0x4b, 0xc3, 0xb2, 0x49, 0xdf, 0xf6, 0x37, 0x0, 0x1b, 0x58, 0xd1, 0x3c, 0xbf, 0x64, 0xf4, 0x53, 0xe0, 0x1a, 0xd6, 0x8a, 0x55, 0x4c, 0xa9, 0x94, 0xf7, 0x1e, 0xc7, 0x10, 0x21, 0x6e, 0xf9, 0x76, 0x9f, 0x1c, 0x8b, 0x46, 0x3d, 0xc7, 0xb4, 0xa9, 0xa, 0xc, 0xea, 0xce, 0xd4, 0x1e, 0x3d}, - output512: []byte{0xfe, 0x97, 0xc0, 0x11, 0xe5, 0x25, 0x11, 0xe, 0x3, 0x14, 0x9f, 0xac, 0x41, 0x79, 0x89, 0x1a, 0xfc, 0xb6, 0x30, 0x4e, 0x1c, 0xfd, 0x9d, 0x84, 0xcb, 0x73, 0x89, 0x75, 0x55, 0x54, 0xee, 0x72, 0x35, 0x71, 0xd7, 0x6b, 0x80, 0xb9, 0x33, 0x3a, 0x69, 0x58, 0x84, 0x19, 0x23, 0x40, 0xb3, 0xfe, 0x2, 0x2d, 0x4a, 0x23, 0x3b, 0x7a, 0xa8, 0xe8, 0xc7, 0x68, 0x67, 0x45, 0xcf, 0xe7, 0x5e, 0x67}}, - testcase{ - msg: []byte{0x8e, 0x58, 0x14, 0x4f, 0xa9, 0x17, 0x9d, 0x68, 0x64, 0x78, 0x62, 0x2c, 0xe4, 0x50, 0xc7, 0x48, 0x26, 0xc, 0x95, 0xd1, 0xba, 0x43, 0xb8, 0xf9, 0xb5, 0x9a, 0xbe, 0xca, 0x8d, 0x93, 0x48, 0x8d, 0xa7, 0x34, 0x63, 0xef, 0x40, 0x19, 0x8b, 0x4d, 0x16, 0xfb, 0xb, 0x7, 0x7, 0x20, 0x13, 0x47, 0xe0, 0x50, 0x6f, 0xf1, 0x9d, 0x1, 0xbe, 0xa0, 0xf4, 0x2b, 0x8a, 0xf9, 0xe7, 0x1a, 0x1f, 0x1b, 0xd1, 0x68, 0x78, 0x10, 0x69, 0xd4, 0xd3, 0x38, 0xfd, 0xef, 0x0, 0xbf, 0x41, 0x9f, 0xbb, 0x0, 0x30, 0x31, 0xdf, 0x67, 0x1f, 0x4a, 0x37, 0x97, 0x95, 0x64, 0xf6, 0x92, 0x82, 0xde, 0x9c, 0x65, 0x40, 0x78, 0x47, 0xdd, 0xd, 0xa5, 0x5, 0xab, 0x16, 0x41, 0xc0, 0x2d, 0xea, 0x4f, 0xd, 0x83, 0x49, 0x86}, - output224: []byte{0xce, 0xf8, 0x4f, 0x19, 0x66, 0x21, 0x5b, 0x15, 0x11, 0xf5, 0xe0, 0xdb, 0x56, 0x4d, 0x68, 0x27, 0x89, 0x81, 0x84, 0xfb, 0xcb, 0x88, 0xbe, 0x2, 0x13, 0xfc, 0x56, 0x3f}, - output256: []byte{0xb6, 0x34, 0x5e, 0xdd, 0x96, 0x60, 0x30, 0xcf, 0x70, 0xdf, 0xb5, 0xb7, 0x55, 0x2b, 0xc1, 0x41, 0xc4, 0x2e, 0xfe, 0x7a, 0x7e, 0x84, 0xf9, 0x57, 0xb1, 0xba, 0xf4, 0x67, 0x1b, 0xae, 0x43, 0x54}, - output384: []byte{0x1, 0xdc, 0x4c, 0xed, 0x46, 0x93, 0xb3, 0x68, 0x14, 0x44, 0x38, 0x57, 0x93, 0x1c, 0x5d, 0x3c, 0xee, 0x87, 0x62, 0xfd, 0xa0, 0x22, 0xf, 0x8e, 0x9e, 0x63, 0xab, 0x1e, 0xe9, 0xa7, 0x13, 0x5a, 0xde, 0x21, 0xc5, 0xab, 0x37, 0x91, 0x82, 0x13, 0x52, 0xff, 0xbc, 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 0xa1, 0x2d, 0x12, 0xae, 0xfc}, - output224: []byte{0x8e, 0x4b, 0x5a, 0x2b, 0x79, 0xfc, 0x1e, 0x7d, 0x5, 0x26, 0xaa, 0xcb, 0x5b, 0x9a, 0xc0, 0x1a, 0x56, 0x96, 0x35, 0x64, 0x4c, 0x92, 0x49, 0xdf, 0xfe, 0xe3, 0xb9, 0x27}, - output256: []byte{0x3, 0x47, 0x90, 0x19, 0x65, 0xd3, 0x63, 0x50, 0x5, 0xe7, 0x5a, 0x10, 0x95, 0x69, 0x5c, 0xca, 0x5, 0xb, 0xc9, 0xed, 0x2d, 0x44, 0xc, 0x3, 0x72, 0xa3, 0x1b, 0x34, 0x85, 0x14, 0xa8, 0x89}, - output384: []byte{0x58, 0x7c, 0x81, 0x4, 0x93, 0x6b, 0xdd, 0x74, 0x70, 0x6, 0x66, 0x66, 0x38, 0x43, 0x74, 0x60, 0x15, 0x90, 0x6c, 0xf4, 0xc6, 0x81, 0xc2, 0xa6, 0xff, 0xdd, 0x7, 0xb7, 0x32, 0xe9, 0xe7, 0x78, 0x7b, 0x16, 0x5e, 0x11, 0x7d, 0xa3, 0x40, 0xbc, 0xe4, 0xe2, 0x73, 0x2, 0xba, 0x28, 0x82, 0x99}, - output512: []byte{0x76, 0xe9, 0x70, 0xe9, 0x44, 0x9d, 0x86, 0x80, 0x67, 0xcd, 0x23, 0xb1, 0xa2, 0x2, 0xcb, 0xdc, 0x99, 0x69, 0x3f, 0xf6, 0xfa, 0x74, 0xba, 0x64, 0x4e, 0xc4, 0x1c, 0xbf, 0x8f, 0xd1, 0x39, 0xcb, 0xf, 0x5d, 0x11, 0x6, 0xfc, 0xd6, 0xc8, 0x71, 0xc3, 0x15, 0xff, 0x41, 0xc3, 0xea, 0xf9, 0x9c, 0x63, 0x62, 0x88, 0xf0, 0xfc, 0xf6, 0xa4, 0xb, 0x48, 0xc, 0xb8, 0x81, 0xd8, 0x7e, 0x9, 0x8f}}, - testcase{ - msg: []byte{0x2e, 0xee, 0xa6, 0x93, 0xf5, 0x85, 0xf4, 0xed, 0x6f, 0x6f, 0x88, 0x65, 0xbb, 0xae, 0x47, 0xa6, 0x90, 0x8a, 0xec, 0xd7, 0xc4, 0x29, 0xe4, 0xbe, 0xc4, 0xf0, 0xde, 0x1d, 0xc, 0xa0, 0x18, 0x3f, 0xa2, 0x1, 0xa0, 0xcb, 0x14, 0xa5, 0x29, 0xb7, 0xd7, 0xac, 0xe, 0x6f, 0xf6, 0x60, 0x7a, 0x32, 0x43, 0xee, 0x9f, 0xb1, 0x1b, 0xcf, 0x3e, 0x23, 0x4, 0xfe, 0x75, 0xff, 0xcd, 0xdd, 0x6c, 0x5c, 0x2e, 0x2a, 0x4c, 0xd4, 0x5f, 0x63, 0xc9, 0x62, 0xd0, 0x10, 0x64, 0x50, 0x58, 0xd3, 0x65, 0x71, 0x40, 0x4a, 0x6d, 0x2b, 0x4f, 0x44, 0x75, 0x54, 0x34, 0xd7, 0x69, 0x98, 0xe8, 0x34, 0x9, 0xc3, 0x20, 0x5a, 0xa1, 0x61, 0x5d, 0xb4, 0x40, 0x57, 0xdb, 0x99, 0x12, 0x31, 0xd2, 0xcb, 0x42, 0x62, 0x45, 0x74, 0xf5, 0x45}, - output224: []byte{0xba, 0xff, 0x55, 0xcd, 0xad, 0x66, 0xaa, 0x77, 0xad, 0x67, 0x7e, 0x13, 0xa1, 0x38, 0xb2, 0xf1, 0x72, 0x86, 0xb5, 0x4, 0xea, 0x6b, 0x94, 0xef, 0xfd, 0x9d, 0x9a, 0x95}, - output256: []byte{0xf0, 0xbf, 0x71, 0x5, 0x87, 0xf, 0x23, 0x82, 0xb7, 0x68, 0x63, 0xbb, 0x97, 0xae, 0xe7, 0x9f, 0x95, 0xae, 0xe, 0x81, 0x42, 0x67, 0x5b, 0xbc, 0xcd, 0xb3, 0x47, 0x5b, 0xc, 0x99, 0x35, 0x2f}, - output384: []byte{0x51, 0x75, 0x33, 0x84, 0xc8, 0xf9, 0x58, 0x4b, 0xe3, 0xed, 0x45, 0x26, 0xb9, 0xb2, 0x9a, 0x97, 0xdc, 0x8a, 0x87, 0xd1, 0x95, 0xd0, 0x15, 0x5e, 0x74, 0x44, 0x95, 0xe, 0xea, 0x55, 0xab, 0xec, 0x5c, 0xd, 0x78, 0x14, 0xf1, 0xdf, 0xce, 0x5c, 0xa4, 0xbf, 0x1d, 0x50, 0xeb, 0xc7, 0x9, 0xad}, - output512: []byte{0x87, 0x16, 0x66, 0xb2, 0x30, 0xc5, 0xad, 0x75, 0xb9, 0x6d, 0x63, 0xbe, 0x22, 0x87, 0x6, 0x21, 0xc6, 0x8f, 0xd0, 0x89, 0x96, 0x55, 0xba, 0x7d, 0xc0, 0xe0, 0xe5, 0x29, 0x99, 0x15, 0xaf, 0x25, 0x2c, 0x22, 0x6d, 0xd7, 0x21, 0x76, 0x1, 0xd3, 0xa6, 0x88, 0xd, 0x55, 0xee, 0x5a, 0x20, 0xb1, 0x8, 0x20, 0xe2, 0x1c, 0x74, 0xf7, 0x30, 0xee, 0xa9, 0xd4, 0x7f, 0xe2, 0x6d, 0xeb, 0xe0, 0x6}}, - testcase{ - msg: []byte{0xda, 0xb1, 0x1d, 0xc0, 0xb0, 0x47, 0xdb, 0x4, 0x20, 0xa5, 0x85, 0xf5, 0x6c, 0x42, 0xd9, 0x31, 0x75, 0x56, 0x28, 0x52, 0x42, 0x84, 0x99, 0xf6, 0x6a, 0xd, 0xb8, 0x11, 0xfc, 0xdd, 0xda, 0xb2, 0xf7, 0xcd, 0xff, 0xed, 0x15, 0x43, 0xe5, 0xfb, 0x72, 0x11, 0xb, 0x64, 0x68, 0x6b, 0xc7, 0xb6, 0x88, 0x7a, 0x53, 0x8a, 0xd4, 0x4c, 0x5, 0xf, 0x1e, 0x42, 0x63, 0x1b, 0xc4, 0xec, 0x8a, 0x9f, 0x2a, 0x4, 0x71, 0x63, 0xd8, 0x22, 0xa3, 0x89, 0x89, 0xee, 0x4a, 0xab, 0x1, 0xb4, 0xc1, 0xf1, 0x61, 0xb0, 0x62, 0xd8, 0x73, 0xb1, 0xcf, 0xa3, 0x88, 0xfd, 0x30, 0x15, 0x14, 0xf6, 0x22, 0x24, 0x15, 0x7b, 0x9b, 0xef, 0x42, 0x3c, 0x77, 0x83, 0xb7, 0xaa, 0xc8, 0xd3, 0xd, 0x65, 0xcd, 0x1b, 0xba, 0x8d, 0x68, 0x9c, 0x2d}, - output224: []byte{0xb4, 0xef, 0xbe, 0x11, 0x67, 0x75, 0x5f, 0x5a, 0x75, 0xb7, 0x2c, 0xf1, 0x5e, 0x6, 0x1, 0x66, 0x2d, 0x3, 0x6a, 0x16, 0xca, 0xc8, 0x60, 0x2a, 0x90, 0x9f, 0xb3, 0x28}, - output256: []byte{0x63, 0x1c, 0x6f, 0x5a, 0xbe, 0x50, 0xb2, 0x7c, 0x9d, 0xea, 0x55, 0x7f, 0xc3, 0xfb, 0xd3, 0xfb, 0x25, 0x78, 0x1f, 0xcb, 0x1b, 0xbf, 0x9f, 0x2e, 0x1, 0xc, 0xca, 0x20, 0xec, 0x52, 0xdb, 0xc4}, - output384: []byte{0xbd, 0x1e, 0x1e, 0x9a, 0xe8, 0xb, 0x7f, 0xa7, 0x9a, 0xdb, 0xd4, 0x7d, 0x7a, 0x28, 0xba, 0x44, 0xf4, 0x87, 0x41, 0x8, 0xcd, 0x9b, 0xe5, 0xd3, 0x27, 0xcc, 0x93, 0xc6, 0xed, 0x4d, 0xac, 0xf8, 0xa9, 0xe2, 0xa3, 0x49, 0x1d, 0x41, 0x68, 0xbf, 0xfa, 0xe6, 0x3f, 0xb2, 0xf1, 0x7, 0xd, 0xe7}, - output512: []byte{0x7e, 0x3e, 0xf6, 0x25, 0x52, 0xb2, 0x8a, 0x2b, 0x18, 0xa7, 0x1c, 0xee, 0xf2, 0xdd, 0x86, 0x59, 0xc8, 0xbd, 0xf2, 0x91, 0x38, 0x5a, 0xd0, 0x2f, 0xed, 0x35, 0x37, 0x75, 0xe0, 0x15, 0x94, 0xf2, 0x7c, 0xc2, 0x8c, 0xc7, 0x86, 0x63, 0xe1, 0x7c, 0xb8, 0xb3, 0x9f, 0xd4, 0xea, 0x48, 0xd4, 0x94, 0xad, 0xb, 0xd7, 0xae, 0xe9, 0x27, 0x7e, 0xc9, 0xb2, 0x1e, 0x46, 0x52, 0x38, 0x12, 0x73, 0x6e}}, - testcase{ - msg: []byte{0x42, 0xe9, 0x9a, 0x2f, 0x80, 0xae, 0xe0, 0xe0, 0x1, 0x27, 0x9a, 0x24, 0x34, 0xf7, 0x31, 0xe0, 0x1d, 0x34, 0xa4, 0x4b, 0x1a, 0x81, 0x1, 0x72, 0x69, 0x21, 0xc0, 0x59, 0xc, 0x30, 0xf3, 0x12, 0xe, 0xb8, 0x30, 0x59, 0xf3, 0x25, 0xe8, 0x94, 0xa5, 0xac, 0x95, 0x9d, 0xca, 0x71, 0xce, 0x22, 0x14, 0x79, 0x99, 0x16, 0x42, 0x4e, 0x85, 0x9d, 0x27, 0xd7, 0x89, 0x43, 0x7b, 0x9d, 0x27, 0x24, 0xb, 0xf8, 0xc3, 0x5a, 0xdb, 0xaf, 0xce, 0xcc, 0x32, 0x2b, 0x48, 0xaa, 0x20, 0x5b, 0x29, 0x39, 0x62, 0xd8, 0x58, 0x65, 0x2a, 0xba, 0xcb, 0xd5, 0x88, 0xbc, 0xf6, 0xcb, 0xc3, 0x88, 0xd0, 0x99, 0x3b, 0xd6, 0x22, 0xf9, 0x6e, 0xd5, 0x46, 0x14, 0xc2, 0x5b, 0x6a, 0x9a, 0xa5, 0x27, 0x58, 0x9e, 0xaa, 0xff, 0xcf, 0x17, 0xdd, 0xf7}, - output224: []byte{0xfa, 0x4b, 0xb6, 0x8, 0xf8, 0xf6, 0x8, 0x41, 0xe1, 0x18, 0x9f, 0x87, 0x70, 0x5, 0x16, 0x95, 0xcd, 0xc9, 0x93, 0x5b, 0xda, 0x71, 0x87, 0xc3, 0x64, 0x19, 0x22, 0x8a}, - output256: []byte{0x37, 0x57, 0xa5, 0x3d, 0x19, 0x5b, 0x43, 0xb4, 0x3, 0xa7, 0x96, 0xa7, 0x4a, 0xaf, 0xb2, 0x6, 0x40, 0x72, 0xa6, 0x9e, 0x37, 0x2e, 0xe5, 0xb3, 0x6c, 0xc2, 0xb7, 0xa7, 0x91, 0xf7, 0x5c, 0x9f}, - output384: []byte{0x6b, 0x7c, 0x11, 0x44, 0xfa, 0x98, 0x42, 0x61, 0x37, 0x7d, 0xba, 0xac, 0xa7, 0x8a, 0x3, 0xae, 0x58, 0xb, 0x7f, 0x3a, 0x17, 0xd6, 0x9b, 0xa0, 0xd5, 0x6e, 0xe9, 0x8, 0xdd, 0x9e, 0xc9, 0xf8, 0x7e, 0xa3, 0xa, 0x76, 0x26, 0xed, 0x7c, 0xcf, 0x25, 0xb5, 0x3a, 0x69, 0x94, 0xe1, 0x21, 0xe8}, - output512: []byte{0xb, 0x87, 0xf6, 0xeb, 0xaa, 0x29, 0x3f, 0xf7, 0x9c, 0x87, 0x38, 0x20, 0x84, 0x6c, 0xf, 0xcc, 0x94, 0x3e, 0x3a, 0x83, 0xbd, 0x81, 0x11, 0x93, 0x1f, 0xf0, 0x3f, 0xf3, 0xb0, 0xbf, 0x78, 0x5c, 0x96, 0x1c, 0xa8, 0x4c, 0xf3, 0xfd, 0x40, 0xe0, 0xd8, 0x31, 0xdb, 0xae, 0xa5, 0x95, 0x49, 0x8f, 0xc1, 0x2d, 0xa8, 0x8c, 0xc5, 0x7, 0xde, 0x72, 0xa, 0x35, 0xc0, 0x1d, 0x73, 0xfc, 0x95, 0x95}}, - testcase{ - msg: []byte{0x3c, 0x9b, 0x46, 0x45, 0xc, 0xf, 0x2c, 0xae, 0x8e, 0x38, 0x23, 0xf8, 0xbd, 0xb4, 0x27, 0x7f, 0x31, 0xb7, 0x44, 0xce, 0x2e, 0xb1, 0x70, 0x54, 0xbd, 0xdc, 0x6d, 0xff, 0x36, 0xaf, 0x7f, 0x49, 0xfb, 0x8a, 0x23, 0x20, 0xcc, 0x3b, 0xdf, 0x8e, 0xa, 0x2e, 0xa2, 0x9a, 0xd3, 0xa5, 0x5d, 0xe1, 0x16, 0x5d, 0x21, 0x9a, 0xde, 0xdd, 0xb5, 0x17, 0x52, 0x53, 0xe2, 0xd1, 0x48, 0x9e, 0x9b, 0x6f, 0xdd, 0x2, 0xe2, 0xc3, 0xd3, 0xa4, 0xb5, 0x4d, 0x60, 0xe3, 0xa4, 0x73, 0x34, 0xc3, 0x79, 0x13, 0xc5, 0x69, 0x53, 0x78, 0xa6, 0x69, 0xe9, 0xb7, 0x2d, 0xec, 0x32, 0xaf, 0x54, 0x34, 0xf9, 0x3f, 0x46, 0x17, 0x6e, 0xbf, 0x4, 0x4c, 0x47, 0x84, 0x46, 0x7c, 0x70, 0x4, 0x70, 0xd0, 0xc0, 0xb4, 0xc, 0x8a, 0x8, 0x8c, 0x81, 0x58, 0x16}, - output224: []byte{0xb3, 0xa8, 0x77, 0x23, 0x15, 0x19, 0xc2, 0x4e, 0x2e, 0xfa, 0x42, 0x4e, 0x60, 0x57, 0x12, 0x8e, 0xa1, 0x5, 0xb5, 0x4c, 0x65, 0xe5, 0x80, 0x74, 0xb5, 0xb1, 0x58, 0x3c}, - output256: []byte{0xc, 0xc9, 0x3, 0xac, 0xbc, 0xed, 0x72, 0x4b, 0x22, 0x1d, 0x34, 0x87, 0x7d, 0x1d, 0x14, 0x27, 0x18, 0x2f, 0x94, 0x93, 0xa3, 0x3d, 0xf7, 0x75, 0x87, 0x20, 0xe8, 0xbf, 0xc7, 0xaf, 0x98, 0xee}, - output384: []byte{0x76, 0x41, 0x4f, 0x3b, 0x9e, 0x4f, 0xf8, 0xd1, 0x50, 0x28, 0xc, 0x8e, 0x44, 0xbc, 0x54, 0x5, 0x68, 0x49, 0xb2, 0x53, 0x51, 0x35, 0x2d, 0x9d, 0x9e, 0x98, 0x6b, 0x3e, 0xcb, 0x6e, 0xc0, 0x50, 0x54, 0x27, 0x9, 0xaf, 0xe0, 0x19, 0x79, 0xd2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0x69, 0xaf, 0x78, 0xb3, 0xde, 0x48, 0xd1, 0x37, 0xdf, 0x4f, 0x28, 0x40}, - output224: []byte{0x9f, 0x38, 0x5c, 0xb, 0x64, 0x5d, 0xb8, 0xdb, 0x8b, 0x73, 0xc9, 0x8c, 0x40, 0xbe, 0x26, 0x4f, 0xfe, 0xe6, 0x15, 0x1c, 0x7b, 0x5a, 0x9, 0x64, 0xe6, 0x7d, 0xaa, 0x9f}, - output256: []byte{0xf2, 0x37, 0x50, 0xc3, 0x29, 0x73, 0xf2, 0x4c, 0x24, 0x22, 0xf4, 0xe2, 0xb4, 0x35, 0x89, 0xd9, 0xe7, 0x6d, 0x6a, 0x57, 0x59, 0x38, 0xe0, 0x1a, 0x96, 0xae, 0x8e, 0x73, 0xd0, 0x26, 0x56, 0x9c}, - output384: []byte{0x92, 0xac, 0x60, 0xe5, 0xdc, 0x49, 0x20, 0x10, 0xa4, 0x5f, 0x46, 0xae, 0xf0, 0x5f, 0x40, 0x3f, 0x75, 0x69, 0xe1, 0xb4, 0xe2, 0xd0, 0xc9, 0x9, 0xc8, 0x71, 0xa7, 0x83, 0xfc, 0x12, 0x45, 0x7d, 0xe2, 0x81, 0xaf, 0xf4, 0xc4, 0xce, 0xe0, 0x20, 0x7d, 0x20, 0xea, 0xf5, 0x46, 0x28, 0x50, 0x70}, - output512: []byte{0xc4, 0x6d, 0x22, 0x62, 0xf1, 0x86, 0x42, 0x1d, 0x7, 0xfd, 0x74, 0xf, 0x92, 0x23, 0x6, 0xd9, 0x9b, 0x1e, 0x38, 0x26, 0xf6, 0xa3, 0x24, 0x86, 0xbe, 0x5a, 0x91, 0xdc, 0x29, 0x8f, 0x17, 0x7f, 0x50, 0x91, 0x5e, 0x17, 0xeb, 0x4e, 0xa2, 0xe4, 0x54, 0x94, 0xc5, 0x1, 0x73, 0x6c, 0xef, 0xb0, 0xe2, 0x2a, 0xcd, 0x98, 0x9d, 0xa4, 0x1a, 0xc7, 0xbb, 0x7b, 0xe5, 0x6b, 0x4, 0xbf, 0xb5, 0xe1}}, - testcase{ - msg: []byte{0x62, 0x6f, 0x68, 0xc1, 0x8a, 0x69, 0xa6, 0x59, 0x1, 0x59, 0xa9, 0xc4, 0x6b, 0xe0, 0x3d, 0x59, 0x65, 0x69, 0x8f, 0x2d, 0xac, 0x3d, 0xe7, 0x79, 0xb8, 0x78, 0xb3, 0xd9, 0xc4, 0x21, 0xe0, 0xf2, 0x1b, 0x95, 0x5a, 0x16, 0xc7, 0x15, 0xc1, 0xec, 0x1e, 0x22, 0xce, 0x3e, 0xb6, 0x45, 0xb8, 0xb4, 0xf2, 0x63, 0xf6, 0x6, 0x60, 0xea, 0x30, 0x28, 0x98, 0x1e, 0xeb, 0xd6, 0xc8, 0xc3, 0xa3, 0x67, 0x28, 0x5b, 0x69, 0x1c, 0x8e, 0xe5, 0x69, 0x44, 0xa7, 0xcd, 0x12, 0x17, 0x99, 0x7e, 0x1d, 0x9c, 0x21, 0x62, 0xb, 0x53, 0x6b, 0xdb, 0xd5, 0xde, 0x89, 0x25, 0xff, 0x71, 0xde, 0xc6, 0xfb, 0xc0, 0x66, 0x24, 0xab, 0x6b, 0x21, 0xe3, 0x29, 0x81, 0x3d, 0xe9, 0xd, 0x1e, 0x57, 0x2d, 0xfb, 0x89, 0xa1, 0x81, 0x20, 0xc3, 0xf6, 0x6, 0x35, 0x5d, 0x25}, - output224: []byte{0xbd, 0x6c, 0x86, 0x59, 0x93, 0x8, 0x2e, 0xc7, 0xb3, 0x80, 0x8c, 0x13, 0xfd, 0x14, 0xf, 0xe0, 0xc0, 0x66, 0x7b, 0x3e, 0xe5, 0x1b, 0x9f, 0x8f, 0x1f, 0x4d, 0xff, 0xd8}, - output256: []byte{0x1e, 0xce, 0x87, 0xe4, 0x4a, 0x99, 0xf5, 0x9d, 0x26, 0x41, 0x14, 0x18, 0xfb, 0x87, 0x93, 0x68, 0x9f, 0xf8, 0xa9, 0xc6, 0xef, 0x75, 0x59, 0x90, 0x56, 0x8, 0x7d, 0x8c, 0x99, 0x5b, 0xce, 0x1e}, - output384: []byte{0x8f, 0x99, 0x3, 0x2c, 0xb4, 0x9b, 0xb0, 0x22, 0xee, 0x5f, 0xb3, 0x24, 0x46, 0xe1, 0xd3, 0x9a, 0xa0, 0xfc, 0xd7, 0x49, 0x74, 0x1e, 0x47, 0x96, 0x97, 0x9d, 0x4b, 0xea, 0x5a, 0xb1, 0xb0, 0x4d, 0x24, 0x15, 0x92, 0xec, 0x60, 0x58, 0xe5, 0x4b, 0x8e, 0xc9, 0xea, 0xb2, 0x74, 0xee, 0x63, 0x2d}, - output512: []byte{0xb, 0x3d, 0xbc, 0x77, 0x3, 0x32, 0x82, 0x3e, 0x68, 0x64, 0x70, 0xd8, 0x42, 0x10, 0x4d, 0x3b, 0x3c, 0x14, 0x52, 0xf6, 0x4f, 0x1b, 0xcc, 0x71, 0xc5, 0xf3, 0xfa, 0xd1, 0xc0, 0xd9, 0x3f, 0x21, 0xef, 0xbd, 0x48, 0xd7, 0x3c, 0x7d, 0x49, 0x9, 0x22, 0x7b, 0x6, 0xb0, 0x6d, 0x54, 0x5, 0x7a, 0x74, 0xe0, 0x3c, 0x36, 0xd9, 0xc1, 0x6, 0xeb, 0xa7, 0x94, 0x11, 0xf1, 0xe6, 0xe1, 0xcf, 0xfe}}, - testcase{ - msg: []byte{0x65, 0x1a, 0x6f, 0xb3, 0xc4, 0xb8, 0xc, 0x7c, 0x68, 0xc6, 0x1, 0x16, 0x75, 0xe6, 0x9, 0x4e, 0xb5, 0x6a, 0xbf, 0x5f, 0xc3, 0x5, 0x73, 0x24, 0xeb, 0xc6, 0x47, 0x78, 0x25, 0x6, 0x1f, 0x9f, 0x27, 0xe7, 0xa9, 0x46, 0x33, 0xab, 0xd1, 0xfa, 0x59, 0x8a, 0x74, 0x6e, 0x4a, 0x57, 0x7c, 0xaf, 0x52, 0x4c, 0x52, 0xec, 0x17, 0x88, 0x47, 0x1f, 0x92, 0xb8, 0xc3, 0x7f, 0x23, 0x79, 0x5c, 0xa1, 0x9d, 0x55, 0x9d, 0x44, 0x6c, 0xab, 0x16, 0xcb, 0xcd, 0xce, 0x90, 0xb7, 0x9f, 0xa1, 0x2, 0x6c, 0xee, 0x77, 0xbf, 0x4a, 0xb1, 0xb5, 0x3, 0xc5, 0xb9, 0x4c, 0x22, 0x56, 0xad, 0x75, 0xb3, 0xea, 0xc6, 0xfd, 0x5d, 0xcb, 0x96, 0xac, 0xa4, 0xb0, 0x3a, 0x83, 0x4b, 0xfb, 0x4e, 0x9a, 0xf9, 0x88, 0xce, 0xcb, 0xf2, 0xae, 0x59, 0x7c, 0xb9, 0x9, 0x79, 0x40}, - output224: []byte{0x8c, 0xa8, 0x44, 0xac, 0xfc, 0xaa, 0xbd, 0x3b, 0x96, 0x9f, 0x86, 0xc2, 0xf1, 0xec, 0xdf, 0x16, 0x20, 0x57, 0x4e, 0xc8, 0xc2, 0x44, 0x26, 0xbe, 0x2d, 0xcc, 0x1b, 0xb5}, - output256: []byte{0x71, 0xb4, 0xf9, 0xa, 0xc9, 0x21, 0x5d, 0x74, 0x74, 0xb1, 0x19, 0x7d, 0x1b, 0x8b, 0x24, 0x44, 0x9f, 0xd5, 0x7e, 0x9b, 0x5, 0x48, 0x3d, 0x32, 0xed, 0xbe, 0xbc, 0xb2, 0x1a, 0x82, 0xf8, 0x66}, - output384: []byte{0x8b, 0xb4, 0xf3, 0xcf, 0x3, 0x90, 0xa3, 0x1d, 0x68, 0x22, 0x13, 0xd2, 0x23, 0x54, 0xdf, 0xe7, 0xd5, 0x80, 0xc8, 0x11, 0x68, 0x22, 0x59, 0x87, 0x2f, 0x2a, 0x29, 0xa0, 0x8d, 0x37, 0x3f, 0xd9, 0x98, 0xf8, 0x42, 0x33, 0x4f, 0x64, 0xf8, 0x13, 0x49, 0x36, 0x4a, 0x93, 0xc, 0x82, 0xba, 0xd4}, - output512: []byte{0xca, 0x46, 0x27, 0x6b, 0xd, 0xc2, 0xec, 0x44, 0x24, 0xbb, 0x71, 0x36, 0xea, 0xe1, 0xaf, 0x20, 0x7b, 0xd6, 0xe5, 0xcd, 0x83, 0x36, 0x91, 0xc7, 0xd3, 0x7b, 0x2c, 0xae, 0xaf, 0x4f, 0x48, 0x4b, 0x96, 0xa3, 0x47, 0x6f, 0xc2, 0x5f, 0xeb, 0x20, 0x6a, 0xd3, 0x7c, 0xf9, 0x75, 0x38, 0x3d, 0xd5, 0x22, 0xca, 0xc, 0xc6, 0x20, 0xa, 0x38, 0x67, 0xfe, 0xe7, 0xf1, 0x78, 0xd6, 0x95, 0x3f, 0xef}}, - testcase{ - msg: []byte{0x8a, 0xaf, 0x7, 0x2f, 0xce, 0x8a, 0x2d, 0x96, 0xbc, 0x10, 0xb3, 0xc9, 0x1c, 0x80, 0x9e, 0xe9, 0x30, 0x72, 0xfb, 0x20, 0x5c, 0xa7, 0xf1, 0xa, 0xbd, 0x82, 0xec, 0xd8, 0x2c, 0xf0, 0x40, 0xb1, 0xbc, 0x49, 0xea, 0x13, 0xd1, 0x85, 0x78, 0x15, 0xc0, 0xe9, 0x97, 0x81, 0xde, 0x3a, 0xdb, 0xb5, 0x44, 0x3c, 0xe1, 0xc8, 0x97, 0xe5, 0x51, 0x88, 0xce, 0xaf, 0x22, 0x1a, 0xa9, 0x68, 0x16, 0x38, 0xde, 0x5, 0xae, 0x1b, 0x32, 0x29, 0x38, 0xf4, 0x6b, 0xce, 0x51, 0x54, 0x3b, 0x57, 0xec, 0xdb, 0x4c, 0x26, 0x62, 0x72, 0x25, 0x9d, 0x17, 0x98, 0xde, 0x13, 0xbe, 0x90, 0xe1, 0xe, 0xfe, 0xc2, 0xd0, 0x74, 0x84, 0xd9, 0xb2, 0x1a, 0x38, 0x70, 0xe2, 0xaa, 0x9e, 0x6, 0xc2, 0x1a, 0xa2, 0xd0, 0xc9, 0xcf, 0x42, 0x0, 0x80, 0xa8, 0xa, 0x91, 0xde, 0xe1, 0x6f}, - output224: []byte{0xe8, 0xd5, 0x49, 0xff, 0x8d, 0x53, 0x74, 0x5a, 0x4c, 0x5c, 0x75, 0xbd, 0xad, 0x92, 0x31, 0x40, 0x25, 0xda, 0x87, 0x7a, 0x77, 0xce, 0x49, 0xea, 0x13, 0x48, 0x40, 0xfa}, - output256: []byte{0x3b, 0x36, 0x78, 0xbb, 0x11, 0x6f, 0xad, 0xab, 0x48, 0x42, 0x91, 0xf0, 0xcf, 0x97, 0x26, 0x6, 0x52, 0x35, 0x1, 0xf5, 0xb4, 0x5d, 0x51, 0x6, 0x37, 0x97, 0x97, 0x29, 0x28, 0xe3, 0x33, 0xc0}, - output384: []byte{0xb, 0xb7, 0xda, 0xc5, 0x44, 0x56, 0x9e, 0x6e, 0xb7, 0x4a, 0xca, 0xb0, 0x1a, 0x84, 0x6f, 0x74, 0xad, 0x2a, 0xf, 0x31, 0xd8, 0xfa, 0xce, 0xe4, 0xd0, 0x9f, 0xa4, 0x9c, 0x81, 0xb9, 0x3b, 0xd8, 0x3b, 0x4f, 0x12, 0x9b, 0x96, 0xda, 0x4c, 0xe, 0xaf, 0x16, 0x5f, 0xde, 0x52, 0xef, 0x29, 0x5b}, - output512: []byte{0x81, 0x5b, 0x44, 0x66, 0x8b, 0xf3, 0x75, 0x1a, 0x33, 0x92, 0x94, 0xf, 0xca, 0x54, 0xc1, 0xe3, 0xe4, 0xef, 0x52, 0x27, 0xb0, 0x52, 0x33, 0x2a, 0xfe, 0x6e, 0xb7, 0xa1, 0xa, 0xc8, 0xad, 0x64, 0x38, 0xce, 0x8a, 0x2, 0x77, 0xaa, 0x14, 0xbc, 0xc4, 0x15, 0x90, 0xf6, 0xd6, 0xa1, 0xb, 0x6b, 0x1b, 0xab, 0xe6, 0xbb, 0x4f, 0x8d, 0x77, 0x7e, 0xa5, 0x76, 0xd6, 0x34, 0xb0, 0xbe, 0x41, 0xc0}}, - testcase{ - msg: []byte{0x53, 0xf9, 0x18, 0xfd, 0x0, 0xb1, 0x70, 0x1b, 0xd5, 0x4, 0xf8, 0xcd, 0xea, 0x80, 0x3a, 0xcc, 0xa2, 0x1a, 0xc1, 0x8c, 0x56, 0x4a, 0xb9, 0xc, 0x2a, 0x17, 0xda, 0x59, 0x2c, 0x7d, 0x69, 0x68, 0x8f, 0x65, 0x80, 0x57, 0x53, 0x95, 0x55, 0x1e, 0x8c, 0xd3, 0x3e, 0xf, 0xef, 0x8, 0xca, 0x6e, 0xd4, 0x58, 0x8d, 0x4d, 0x14, 0xb, 0x3e, 0x44, 0xc0, 0x32, 0x35, 0x5d, 0xf1, 0xc5, 0x31, 0x56, 0x4d, 0x7f, 0x48, 0x35, 0x75, 0x33, 0x44, 0x34, 0x5a, 0x67, 0x81, 0xe1, 0x1c, 0xd5, 0xe0, 0x95, 0xb7, 0x3d, 0xf5, 0xf8, 0x2c, 0x8a, 0xe3, 0xad, 0x0, 0x87, 0x79, 0x36, 0x89, 0x66, 0x71, 0xe9, 0x47, 0xcc, 0x52, 0xe2, 0xb2, 0x9d, 0xcd, 0x46, 0x3d, 0x90, 0xa0, 0xc9, 0x92, 0x91, 0x28, 0xda, 0x22, 0x2b, 0x5a, 0x21, 0x14, 0x50, 0xbb, 0xc0, 0xe0, 0x24, 0x48, 0xe2}, - output224: []byte{0xe6, 0xbd, 0x80, 0x78, 0x7f, 0x87, 0x4, 0xff, 0xf7, 0x31, 0x12, 0xe8, 0xb3, 0x68, 0xad, 0xfb, 0xa3, 0xa1, 0x10, 0x91, 0x62, 0xc7, 0x69, 0x49, 0x13, 0x49, 0xdc, 0xef}, - output256: []byte{0x40, 0x68, 0x24, 0x64, 0x95, 0xf5, 0x8, 0x89, 0x78, 0x13, 0x33, 0x29, 0x62, 0xd3, 0xae, 0xb, 0x84, 0x68, 0x50, 0x45, 0xe8, 0x32, 0xa9, 0xa3, 0x9a, 0xd5, 0xe9, 0x4c, 0x15, 0x4d, 0x26, 0x79}, - output384: []byte{0x10, 0xdd, 0x93, 0x48, 0xb2, 0xd9, 0x58, 0x89, 0xee, 0x61, 0x39, 0x7, 0x82, 0x4a, 0x10, 0xef, 0xc7, 0x8, 0xa1, 0x1, 0xa6, 0x76, 0x72, 0xfc, 0xa4, 0xc6, 0x53, 0x9f, 0x51, 0x56, 0xc7, 0xdf, 0x80, 0x5d, 0xbe, 0x66, 0x6f, 0xcf, 0x4c, 0xc5, 0x78, 0xf4, 0x21, 0xae, 0x3c, 0xf2, 0x71, 0x22}, - output512: []byte{0xf4, 0x77, 0x99, 0xa8, 0x54, 0x7f, 0xc9, 0xc0, 0x7d, 0xf, 0x80, 0x80, 0x29, 0xe7, 0x33, 0x56, 0x7, 0xd7, 0x22, 0x24, 0xbe, 0x28, 0x6e, 0x11, 0x86, 0x57, 0xbd, 0x13, 0xa2, 0xc5, 0x1d, 0x3, 0x74, 0x42, 0x6d, 0x9e, 0xeb, 0x76, 0x93, 0xbd, 0xe5, 0xec, 0x61, 0x81, 0x57, 0x4c, 0x14, 0x4, 0xdf, 0x29, 0xbf, 0x96, 0x94, 0x18, 0x62, 0xba, 0x1a, 0xa, 0x9a, 0x59, 0x3, 0x31, 0x94, 0x98}}, - testcase{ - msg: []byte{0xa6, 0x45, 0x99, 0xb8, 0xa6, 0x1b, 0x5c, 0xce, 0xc9, 0xe6, 0x7a, 0xed, 0x69, 0x44, 0x74, 0x59, 0xc8, 0xda, 0x3d, 0x1e, 0xc6, 0xc7, 0xc7, 0xc8, 0x2a, 0x74, 0x28, 0xb9, 0xb5, 0x84, 0xfa, 0x67, 0xe9, 0xf, 0x68, 0xe2, 0xc0, 0xf, 0xbb, 0xed, 0x46, 0x13, 0x66, 0x6e, 0x51, 0x68, 0xda, 0x4a, 0x16, 0xf3, 0x95, 0xf7, 0xa3, 0xc3, 0x83, 0x2b, 0x3b, 0x13, 0x4b, 0xfc, 0x9c, 0xba, 0xa9, 0x5d, 0x2a, 0xf, 0xe2, 0x52, 0xf4, 0x4a, 0xc6, 0x68, 0x1e, 0xb6, 0xd4, 0xa, 0xb9, 0x1c, 0x1d, 0x2, 0x82, 0xfe, 0xd6, 0x70, 0x1c, 0x57, 0x46, 0x3d, 0x3c, 0x5f, 0x2b, 0xb8, 0xc6, 0xa7, 0x30, 0x1f, 0xb4, 0x57, 0x6a, 0xa3, 0xb5, 0xf1, 0x55, 0x10, 0xdb, 0x89, 0x56, 0xff, 0x77, 0x47, 0x8c, 0x26, 0xa7, 0xc0, 0x9b, 0xea, 0x7b, 0x39, 0x8c, 0xfc, 0x83, 0x50, 0x3f, 0x53, 0x8e}, - output224: []byte{0xbd, 0x7d, 0x9e, 0x6c, 0xf9, 0xd2, 0xc1, 0x3, 0xf, 0x89, 0x25, 0x33, 0xe0, 0x1b, 0x72, 0xb5, 0x28, 0x8e, 0x17, 0x4b, 0x8, 0x64, 0xd8, 0x1d, 0x71, 0xf8, 0xc6, 0xe6}, - output256: []byte{0x82, 0x69, 0x62, 0x59, 0x53, 0x65, 0x20, 0xe5, 0xe4, 0xd4, 0x7e, 0x10, 0x6b, 0xd1, 0xdc, 0xb3, 0x97, 0x52, 0x9a, 0xaf, 0xb7, 0x58, 0x78, 0xf3, 0x32, 0xd2, 0xaf, 0x26, 0x84, 0x49, 0x3f, 0x1b}, - output384: []byte{0x44, 0x4b, 0x8a, 0x6f, 0x1e, 0xe1, 0x18, 0xde, 0x3f, 0xb3, 0xec, 0x76, 0xb2, 0xfb, 0xad, 0x9e, 0xf3, 0x19, 0x16, 0xe1, 0xf9, 0x90, 0x77, 0xde, 0xfc, 0x51, 0xc2, 0xe5, 0x9c, 0x8e, 0x6a, 0x3e, 0x20, 0x7b, 0xa4, 0x8e, 0x5e, 0xdd, 0x66, 0xc7, 0x2b, 0x5b, 0xeb, 0xa6, 0x74, 0x1, 0xd7, 0x94}, - output512: []byte{0x8a, 0xa, 0xe1, 0x2a, 0x9e, 0x79, 0x7f, 0xb7, 0xbd, 0x46, 0xcb, 0xb9, 0x10, 0x7, 0x6a, 0x32, 0x87, 0x3b, 0xff, 0xcb, 0x9a, 0xd9, 0x8b, 0x4f, 0xc3, 0x73, 0x16, 0x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x85, 0xf0, 0xb1, 0xfe, 0x32, 0xa4, 0xe1, 0xfa, 0xa, 0x2e, 0x25}, - output256: []byte{0xb4, 0x94, 0x85, 0x26, 0x3, 0x39, 0x3b, 0x2b, 0x71, 0x84, 0x5b, 0xac, 0xbd, 0xce, 0x89, 0xfa, 0x14, 0x27, 0xdf, 0xe4, 0xaf, 0x9c, 0xdf, 0x92, 0x5d, 0x4f, 0x93, 0xfa, 0x83, 0xb9, 0x96, 0x6b}, - output384: []byte{0xf4, 0xd1, 0x7c, 0x62, 0x99, 0xba, 0xe7, 0xd0, 0xe6, 0xd1, 0x5a, 0x55, 0xb, 0x31, 0x1f, 0x30, 0xc1, 0xb0, 0x38, 0xae, 0xf5, 0x6f, 0xe3, 0x75, 0xf3, 0xb4, 0xba, 0xe1, 0x4f, 0x7e, 0xa4, 0x27, 0xc5, 0xaa, 0x98, 0x7e, 0xf9, 0x32, 0x85, 0x97, 0x5c, 0xe5, 0xf9, 0xe4, 0x6a, 0x3e, 0x4c, 0x20}, - output512: []byte{0xa3, 0xc6, 0xd5, 0x88, 0x72, 0xba, 0xfd, 0xed, 0xfd, 0xd5, 0xc, 0x3, 0x9, 0x8, 0x92, 0x40, 0xd6, 0x97, 0x7d, 0x4d, 0x3d, 0x59, 0xfb, 0x3f, 0x2b, 0xe1, 0x33, 0xc5, 0x7d, 0x2d, 0xfc, 0xfc, 0xc7, 0xc0, 0x27, 0x29, 0x6f, 0x74, 0xfe, 0x58, 0xb2, 0xa9, 0xa6, 0xcb, 0x7e, 0x5d, 0x70, 0x8, 0x89, 0x34, 0xd0, 0x51, 0xcb, 0xa5, 0x70, 0x1, 0xfe, 0x27, 0x96, 0x5c, 0xfa, 0x7, 0x1a, 0x6f}}, - testcase{ - msg: []byte{0xa6, 0x2f, 0xc5, 0x95, 0xb4, 0x9, 0x6e, 0x63, 0x36, 0xe5, 0x3f, 0xcd, 0xfc, 0x8d, 0x1c, 0xc1, 0x75, 0xd7, 0x1d, 0xac, 0x9d, 0x75, 0xa, 0x61, 0x33, 0xd2, 0x31, 0x99, 0xea, 0xac, 0x28, 0x82, 0x7, 0x94, 0x4c, 0xea, 0x6b, 0x16, 0xd2, 0x76, 0x31, 0x91, 0x5b, 0x46, 0x19, 0xf7, 0x43, 0xda, 0x2e, 0x30, 0xa0, 0xc0, 0xb, 0xbd, 0xb1, 0xbb, 0xb3, 0x5a, 0xb8, 0x52, 0xef, 0x3b, 0x9a, 0xec, 0x6b, 0xa, 0x8d, 0xcc, 0x6e, 0x9e, 0x1a, 0xba, 0xa3, 0xad, 0x62, 0xac, 0xa, 0x6c, 0x5d, 0xe7, 0x65, 0xde, 0x2c, 0x37, 0x11, 0xb7, 0x69, 0xe3, 0xfd, 0xe4, 0x4a, 0x74, 0x1, 0x6f, 0xff, 0x82, 0xac, 0x46, 0xfa, 0x8f, 0x17, 0x97, 0xd3, 0xb2, 0xa7, 0x26, 0xb6, 0x96, 0xe3, 0xde, 0xa5, 0x53, 0x4, 0x39, 0xac, 0xee, 0x3a, 0x45, 0xc2, 0xa5, 0x1b, 0xc3, 0x2d, 0xd0, 0x55, 0x65, 0xb}, - output224: []byte{0x2e, 0xd, 0x73, 0x93, 0x86, 0xaa, 0xaf, 0x37, 0x98, 0xe, 0xe4, 0x21, 0xaa, 0x8c, 0x19, 0xb1, 0x9a, 0xf5, 0x2e, 0x70, 0xf5, 0x9d, 0xc0, 0xa6, 0x98, 0x84, 0x71, 0xf5}, - output256: []byte{0xd8, 0xa6, 0x19, 0xc0, 0xdf, 0xbe, 0xd2, 0xa9, 0x49, 0x8a, 0x14, 0x7b, 0x53, 0xd7, 0xb3, 0x3d, 0xd6, 0x53, 0xd3, 0x90, 0xe5, 0xc0, 0xcd, 0x69, 0x1f, 0x2, 0xc8, 0x60, 0x88, 0x22, 0xd0, 0x6a}, - output384: []byte{0x39, 0xf9, 0x11, 0xe9, 0xcb, 0x27, 0x63, 0xc8, 0x91, 0x1a, 0xc3, 0x15, 0x30, 0x40, 0xe4, 0x8f, 0x40, 0x3a, 0xbf, 0xe3, 0x73, 0xe1, 0x4b, 0x70, 0x9a, 0x47, 0x68, 0x68, 0xd3, 0xab, 0x58, 0x41, 0xd1, 0x8, 0x8f, 0x83, 0x93, 0xdd, 0x72, 0x83, 0x5, 0xba, 0x34, 0x11, 0x38, 0x36, 0x5d, 0x27}, - output512: []byte{0x11, 0xe0, 0xe5, 0x21, 0xb5, 0x5f, 0x2, 0xbe, 0xfc, 0x72, 0x7, 0xc0, 0x64, 0x44, 0xfc, 0xc0, 0xc1, 0x6d, 0xcf, 0x6f, 0x34, 0x96, 0x29, 0x21, 0xb7, 0x9, 0xa3, 0x22, 0xf3, 0x5e, 0x21, 0x93, 0x47, 0x7b, 0xd, 0xfa, 0x21, 0xf2, 0x13, 0xf2, 0x9, 0x70, 0x5f, 0xf3, 0x95, 0x85, 0x31, 0xa7, 0x5d, 0x94, 0x34, 0x60, 0x75, 0xfe, 0xb2, 0x9a, 0x28, 0x8b, 0x62, 0xe2, 0x31, 0x5a, 0xe2, 0x70}}, - testcase{ - msg: []byte{0x2b, 0x6d, 0xb7, 0xce, 0xd8, 0x66, 0x5e, 0xbe, 0x9d, 0xeb, 0x8, 0x2, 0x95, 0x21, 0x84, 0x26, 0xbd, 0xaa, 0x7c, 0x6d, 0xa9, 0xad, 0xd2, 0x8, 0x89, 0x32, 0xcd, 0xff, 0xba, 0xa1, 0xc1, 0x41, 0x29, 0xbc, 0xcd, 0xd7, 0xf, 0x36, 0x9e, 0xfb, 0x14, 0x92, 0x85, 0x85, 0x8d, 0x2b, 0x1d, 0x15, 0x5d, 0x14, 0xde, 0x2f, 0xdb, 0x68, 0xa, 0x8b, 0x2, 0x72, 0x84, 0x5, 0x51, 0x82, 0xa0, 0xca, 0xe2, 0x75, 0x23, 0x4c, 0xc9, 0xc9, 0x28, 0x63, 0xc1, 0xb4, 0xab, 0x66, 0xf3, 0x4, 0xcf, 0x6, 0x21, 0xcd, 0x54, 0x56, 0x5f, 0x5b, 0xff, 0x46, 0x1d, 0x3b, 0x46, 0x1b, 0xd4, 0xd, 0xf2, 0x81, 0x98, 0xe3, 0x73, 0x25, 0x1, 0xb4, 0x86, 0xe, 0xad, 0xd5, 0x3, 0xd2, 0x6d, 0x6e, 0x69, 0x33, 0x8f, 0x4e, 0x4, 0x56, 0xe9, 0xe9, 0xba, 0xf3, 0xd8, 0x27, 0xae, 0x68, 0x5f, 0xb1, 0xd8, 0x17}, - output224: []byte{0xaf, 0x3e, 0xc, 0xc6, 0xe6, 0x45, 0x1, 0xf1, 0xf, 0xd3, 0x97, 0x22, 0xe8, 0x52, 0x35, 0x5f, 0xd6, 0xd8, 0xd, 0x32, 0x19, 0x6, 0x31, 0xe2, 0xf0, 0x6c, 0x22, 0xad}, - output256: []byte{0xd8, 0x2e, 0x25, 0x7d, 0x0, 0xd, 0xc9, 0xfa, 0x27, 0x9a, 0x0, 0xe2, 0x96, 0x1e, 0x32, 0x86, 0xd2, 0xfe, 0x1c, 0x2, 0xef, 0x59, 0x83, 0x3a, 0xb8, 0xa6, 0xa7, 0x10, 0x1b, 0xc2, 0x50, 0x54}, - output384: []byte{0x3a, 0xde, 0xb7, 0xee, 0xec, 0xf9, 0x6, 0x9f, 0x14, 0x3a, 0x10, 0x15, 0x1f, 0xd4, 0x50, 0x6a, 0xee, 0xf3, 0xa0, 0xef, 0x94, 0xca, 0x65, 0xd4, 0x44, 0x8a, 0xcf, 0x1e, 0x89, 0x2b, 0x8e, 0xbb, 0x8, 0x87, 0x63, 0x18, 0x4, 0xdd, 0x64, 0xe1, 0x53, 0xad, 0x41, 0xfa, 0xe0, 0x12, 0x7a, 0x85}, - output512: []byte{0xae, 0xbb, 0xa5, 0x7c, 0x8e, 0xd5, 0xaf, 0x6e, 0xc9, 0x3f, 0x4a, 0xa4, 0x57, 0x72, 0xff, 0x51, 0x67, 0xb7, 0xea, 0x88, 0xdf, 0xa7, 0x13, 0x64, 0xf3, 0x7d, 0x8f, 0xc5, 0xfd, 0xb7, 0xdc, 0x3b, 0x2c, 0x83, 0x31, 0xa0, 0x80, 0x23, 0xf2, 0x1d, 0x11, 0xb, 0x7d, 0x82, 0x1e, 0x2d, 0xc7, 0xe8, 0x60, 0x82, 0x62, 0x35, 0xe7, 0xe6, 0x29, 0x19, 0x12, 0xac, 0x52, 0x13, 0x84, 0x74, 0x73, 0x54}}, - testcase{ - msg: []byte{0x10, 0xdb, 0x50, 0x9b, 0x2c, 0xdc, 0xab, 0xa6, 0xc0, 0x62, 0xae, 0x33, 0xbe, 0x48, 0x11, 0x6a, 0x29, 0xeb, 0x18, 0xe3, 0x90, 0xe1, 0xbb, 0xad, 0xa5, 0xca, 0xa, 0x27, 0x18, 0xaf, 0xbc, 0xd2, 0x34, 0x31, 0x44, 0x1, 0x6, 0x59, 0x48, 0x93, 0x4, 0x3c, 0xc7, 0xf2, 0x62, 0x52, 0x81, 0xbf, 0x7d, 0xe2, 0x65, 0x58, 0x80, 0x96, 0x6a, 0x23, 0x70, 0x5f, 0xc, 0x51, 0x55, 0xc2, 0xf5, 0xcc, 0xa9, 0xf2, 0xc2, 0x14, 0x2e, 0x96, 0xd0, 0xa2, 0xe7, 0x63, 0xb7, 0x6, 0x86, 0xcd, 0x42, 0x1b, 0x5d, 0xb8, 0x12, 0xda, 0xce, 0xd0, 0xc6, 0xd6, 0x50, 0x35, 0xfd, 0xe5, 0x58, 0xe9, 0x4f, 0x26, 0xb3, 0xe6, 0xdd, 0xe5, 0xbd, 0x13, 0x98, 0xc, 0xc8, 0x2, 0x92, 0xb7, 0x23, 0x1, 0x3b, 0xd0, 0x33, 0x28, 0x45, 0x84, 0xbf, 0xf2, 0x76, 0x57, 0x87, 0x1b, 0xc, 0xf0, 0x7a, 0x84, 0x9f, 0x4a, 0xe2}, - output224: []byte{0xf0, 0x9, 0xe0, 0x5d, 0x1a, 0xfe, 0x2d, 0x33, 0xd2, 0xc5, 0xf4, 0x0, 0x8b, 0x46, 0xf3, 0x14, 0x68, 0xa7, 0xbf, 0x52, 0x99, 0xd4, 0xf0, 0xab, 0xe, 0xfe, 0x4f, 0xd3}, - output256: []byte{0x8d, 0x5b, 0x7d, 0xbf, 0x39, 0x47, 0x21, 0x9a, 0xcd, 0xb0, 0x4f, 0xb2, 0xe1, 0x1a, 0x84, 0xa3, 0x13, 0xc5, 0x4c, 0x22, 0xf2, 0xae, 0x85, 0x8d, 0xfc, 0x88, 0x87, 0xbf, 0x62, 0x65, 0xf5, 0xf3}, - output384: []byte{0x14, 0x83, 0x8, 0x77, 0xdf, 0xaf, 0xe6, 0xf8, 0x86, 0xa2, 0x2d, 0xe7, 0xce, 0x9a, 0x5f, 0xc7, 0x47, 0x33, 0xa8, 0xfc, 0x27, 0xec, 0xc5, 0x23, 0xb6, 0xb4, 0x52, 0x4e, 0x63, 0x12, 0xcb, 0xb2, 0x2b, 0x51, 0xd7, 0xeb, 0x9d, 0xda, 0xb3, 0x7b, 0xa5, 0x4b, 0xb2, 0xc0, 0xbf, 0xc3, 0x2a, 0x6f}, - output512: []byte{0x2d, 0xf1, 0xe0, 0x95, 0x40, 0xb5, 0x3a, 0x17, 0x22, 0x2d, 0xab, 0x66, 0x27, 0x5c, 0xeb, 0xec, 0xeb, 0x1f, 0x8a, 0x5d, 0xb2, 0x6b, 0xc, 0x41, 0xf9, 0x55, 0xfa, 0x5, 0x49, 0xf3, 0x36, 0x7e, 0x82, 0x29, 0x9e, 0xc, 0xd6, 0x73, 0x95, 0x8a, 0xf7, 0xdf, 0xa0, 0x4d, 0x74, 0x1a, 0xa6, 0x3b, 0xa2, 0xc1, 0xad, 0x35, 0x17, 0x64, 0xdc, 0x92, 0x28, 0xd2, 0x15, 0xf2, 0x2c, 0x24, 0xca, 0x58}}, - testcase{ - msg: []byte{0x93, 0x34, 0xde, 0x60, 0xc9, 0x97, 0xbd, 0xa6, 0x8, 0x61, 0x1, 0xa6, 0x31, 0x4f, 0x64, 0xe4, 0x45, 0x8f, 0x5f, 0xf9, 0x45, 0xc, 0x50, 0x9d, 0xf0, 0x6, 0xe8, 0xc5, 0x47, 0x98, 0x3c, 0x65, 0x1c, 0xa9, 0x78, 0x79, 0x17, 0x5a, 0xab, 0xa0, 0xc5, 0x39, 0xe8, 0x2d, 0x5, 0xc1, 0xe0, 0x2c, 0x48, 0x9, 0x75, 0xcb, 0xb3, 0x1, 0x18, 0x12, 0x10, 0x61, 0xb1, 0xeb, 0xac, 0x4f, 0x8d, 0x9a, 0x37, 0x81, 0xe2, 0xdb, 0x6b, 0x18, 0x4, 0x2e, 0x1, 0xec, 0xf9, 0x1, 0x7a, 0x64, 0xa0, 0xe5, 0x74, 0x47, 0xec, 0x7f, 0xcb, 0xe6, 0xa7, 0xf8, 0x25, 0x85, 0xf7, 0x40, 0x3e, 0xe2, 0x22, 0x3d, 0x52, 0xd3, 0x7b, 0x4b, 0xf4, 0x26, 0x42, 0x86, 0x13, 0xd6, 0xb4, 0x25, 0x79, 0x80, 0x97, 0x2a, 0xa, 0xca, 0xb5, 0x8, 0xa7, 0x62, 0xc, 0x1c, 0xb2, 0x8e, 0xb4, 0xe9, 0xd3, 0xf, 0xc4, 0x13, 0x61, 0xec}, - output224: []byte{0x76, 0x28, 0x1b, 0xd1, 0x61, 0x38, 0x43, 0xa3, 0xad, 0xbc, 0xbc, 0x78, 0xd1, 0x92, 0x3a, 0xfb, 0x5b, 0x8a, 0xa2, 0xdc, 0xbc, 0x48, 0x93, 0x4d, 0xee, 0xc8, 0x4a, 0xaa}, - output256: []byte{0x60, 0x7c, 0x3f, 0x31, 0x34, 0x2c, 0x3e, 0xe5, 0xc9, 0x3e, 0x55, 0x2a, 0x8d, 0xd7, 0x9f, 0xa8, 0x6d, 0xcc, 0xae, 0x2c, 0x1b, 0x58, 0xaa, 0xba, 0xc2, 0x5b, 0x59, 0x18, 0xac, 0xfa, 0x4d, 0xa5}, - output384: []byte{0xd1, 0x9, 0x53, 0x2b, 0xc4, 0x21, 0x73, 0x26, 0xb3, 0xd2, 0x5e, 0xd2, 0xd2, 0xf3, 0xf0, 0xd2, 0x48, 0x2c, 0xc5, 0xbd, 0xd0, 0x54, 0x21, 0x8f, 0xa8, 0xbe, 0xdb, 0x91, 0xcd, 0x81, 0x4f, 0x7f, 0xd6, 0x83, 0xaa, 0x2a, 0xfc, 0xb8, 0x34, 0x2c, 0xd3, 0x4c, 0xe5, 0x4d, 0x60, 0x7e, 0x3d, 0xa0}, - output512: []byte{0x82, 0x99, 0xcf, 0xce, 0xa5, 0xf0, 0xc, 0x93, 0xa5, 0xeb, 0x8a, 0x84, 0xa1, 0x36, 0x28, 0xa6, 0x8b, 0x26, 0x79, 0x6d, 0x53, 0xfb, 0x6a, 0x98, 0x6c, 0x95, 0xb0, 0xb1, 0xc2, 0x48, 0x92, 0xf, 0xb9, 0x46, 0xd8, 0xaf, 0x98, 0x34, 0x3d, 0x14, 0xef, 0xc7, 0x4a, 0x46, 0x11, 0xc5, 0x3c, 0xcc, 0x27, 0xc5, 0xf1, 0x4c, 0x72, 0x37, 0xaf, 0x28, 0x36, 0x43, 0x46, 0xca, 0x5c, 0xd7, 0xd, 0x1a}}, - testcase{ - msg: []byte{0xe8, 0x8a, 0xb0, 0x86, 0x89, 0x16, 0x93, 0xaa, 0x53, 0x5c, 0xeb, 0x20, 0xe6, 0x4c, 0x7a, 0xb9, 0x7c, 0x7d, 0xd3, 0x54, 0x8f, 0x37, 0x86, 0x33, 0x98, 0x97, 0xa5, 0xf0, 0xc3, 0x90, 0x31, 0x54, 0x9c, 0xa8, 0x70, 0x16, 0x6e, 0x47, 0x77, 0x43, 0xcc, 0xfb, 0xe0, 0x16, 0xb4, 0x42, 0x8d, 0x89, 0x73, 0x8e, 0x42, 0x6f, 0x5f, 0xfe, 0x81, 0x62, 0x61, 0x37, 0xf1, 0x7a, 0xec, 0xff, 0x61, 0xb7, 0x2d, 0xbe, 0xe2, 0xdc, 0x20, 0x96, 0x18, 0x80, 0xcf, 0xe2, 0x81, 0xdf, 0xab, 0x5e, 0xe3, 0x8b, 0x19, 0x21, 0x88, 0x14, 0x50, 0xe1, 0x60, 0x32, 0xde, 0x5e, 0x4d, 0x55, 0xad, 0x8d, 0x4f, 0xca, 0x60, 0x97, 0x21, 0xb0, 0x69, 0x2b, 0xac, 0x79, 0xbe, 0x5a, 0x6, 0xe1, 0x77, 0xfe, 0x8c, 0x80, 0xc0, 0xc8, 0x35, 0x19, 0xfb, 0x33, 0x47, 0xde, 0x9f, 0x43, 0xd5, 0x56, 0x1c, 0xb8, 0x10, 0x7b, 0x9b, 0x5e, 0xdc}, - output224: []byte{0xda, 0x7c, 0x79, 0xe0, 0x4f, 0xca, 0x2b, 0x69, 0xaa, 0xa5, 0x81, 0x99, 0xca, 0x69, 0x10, 0x5b, 0x6b, 0x18, 0xfe, 0x67, 0xe2, 0x9f, 0x38, 0x5, 0x1, 0xaa, 0x7f, 0xa8}, - output256: []byte{0x6, 0x56, 0xde, 0x9d, 0xcd, 0x7b, 0x71, 0x12, 0xa8, 0x6c, 0x7b, 0xa1, 0x99, 0x63, 0x7d, 0x2c, 0x1c, 0x9e, 0x9c, 0xfb, 0xb7, 0x13, 0xe4, 0xed, 0xe7, 0x9f, 0x88, 0x62, 0xee, 0x69, 0x99, 0x3f}, - output384: []byte{0xde, 0x64, 0xa3, 0x7a, 0x74, 0x56, 0x63, 0x8d, 0x3a, 0xca, 0x1b, 0x89, 0x5f, 0x4a, 0x88, 0xc2, 0x68, 0x17, 0x17, 0x79, 0x86, 0xa9, 0xf2, 0xf5, 0xb7, 0x7b, 0x49, 0xcf, 0xf2, 0xc3, 0xe4, 0x6b, 0xe2, 0xc4, 0x9a, 0xbe, 0x89, 0xd7, 0x41, 0x37, 0x5d, 0xb8, 0x7f, 0x4c, 0x89, 0x8f, 0x67, 0x62}, - output512: []byte{0xaf, 0x57, 0xbe, 0xa3, 0x57, 0xfc, 0xba, 0x5, 0x79, 0xc4, 0x20, 0x4c, 0xf, 0x8d, 0xff, 0x18, 0x1b, 0xc8, 0xa4, 0x73, 0x1, 0x4b, 0xae, 0x78, 0xdf, 0x76, 0x6, 0x9d, 0xe4, 0x78, 0xb2, 0xf2, 0xa3, 0x90, 0x32, 0x7a, 0x65, 0xbd, 0xd2, 0x4b, 0xe9, 0x26, 0x55, 0x1c, 0x78, 0xf7, 0xb, 0xd, 0x5f, 0x1c, 0x8f, 0x4b, 0x97, 0x9, 0x97, 0xd5, 0x57, 0xf0, 0x63, 0x36, 0xa3, 0x15, 0xa7, 0x49}}, - testcase{ - msg: []byte{0xfd, 0x19, 0xe0, 0x1a, 0x83, 0xeb, 0x6e, 0xc8, 0x10, 0xb9, 0x45, 0x82, 0xcb, 0x8f, 0xbf, 0xa2, 0xfc, 0xb9, 0x92, 0xb5, 0x36, 0x84, 0xfb, 0x74, 0x8d, 0x22, 0x64, 0xf0, 0x20, 0xd3, 0xb9, 0x60, 0xcb, 0x1d, 0x6b, 0x8c, 0x34, 0x8c, 0x2b, 0x54, 0xa9, 0xfc, 0xea, 0x72, 0x33, 0xc, 0x2a, 0xaa, 0x9a, 0x24, 0xec, 0xdb, 0x0, 0xc4, 0x36, 0xab, 0xc7, 0x2, 0x36, 0x1a, 0x82, 0xbb, 0x88, 0x28, 0xb8, 0x53, 0x69, 0xb8, 0xc7, 0x2e, 0xce, 0x0, 0x82, 0xfe, 0x6, 0x55, 0x71, 0x63, 0x89, 0x9c, 0x2a, 0xe, 0xfa, 0x46, 0x6c, 0x33, 0xc0, 0x43, 0x43, 0xa8, 0x39, 0x41, 0x70, 0x57, 0x39, 0x9a, 0x63, 0xa3, 0x92, 0x9b, 0xe1, 0xee, 0x48, 0x5, 0xd6, 0xce, 0x3e, 0x5d, 0xd, 0x9, 0x67, 0xfe, 0x90, 0x4, 0x69, 0x6a, 0x56, 0x63, 0xf4, 0xca, 0xc9, 0x17, 0x90, 0x6, 0xa2, 0xce, 0xb7, 0x55, 0x42, 0xd7, 0x5d, 0x68}, - output224: []byte{0x70, 0xec, 0xb2, 0x61, 0x75, 0x73, 0x71, 0xa2, 0x82, 0x90, 0x3c, 0x69, 0x67, 0x15, 0xdc, 0x3, 0xf1, 0x6, 0xa3, 0x39, 0xf0, 0x76, 0x20, 0x3b, 0xab, 0x43, 0x6e, 0x94}, - output256: []byte{0x4d, 0xdd, 0x62, 0x24, 0x85, 0x82, 0x99, 0xf3, 0x37, 0x8e, 0x3f, 0x5a, 0xe, 0xcc, 0x52, 0xfa, 0x4c, 0x41, 0x9c, 0x8e, 0xbb, 0x20, 0xf6, 0x35, 0xc4, 0xc4, 0x3f, 0x36, 0x32, 0x4e, 0xcb, 0x4e}, - output384: []byte{0x8d, 0x97, 0x43, 0x71, 0xc, 0x17, 0x1c, 0xd3, 0x99, 0xa0, 0xd7, 0x12, 0xe9, 0xd5, 0x33, 0x74, 0xed, 0x8e, 0xa, 0x97, 0x67, 0x2a, 0x40, 0x29, 0x4c, 0x74, 0xf0, 0xd5, 0x3, 0xf0, 0x29, 0x2d, 0x6f, 0x41, 0xd5, 0xce, 0xa0, 0x8f, 0xb3, 0xc6, 0x23, 0xc4, 0xeb, 0xa5, 0x68, 0x48, 0x77, 0xd}, - output512: []byte{0xb2, 0x99, 0xe4, 0x21, 0x6, 0x1e, 0xf2, 0x6c, 0x32, 0xbb, 0x4f, 0x50, 0xee, 0x66, 0x9d, 0x5, 0xfe, 0xb2, 0xcc, 0xba, 0x32, 0x97, 0x28, 0x9c, 0x30, 0xe6, 0x43, 0x40, 0x57, 0xb3, 0xea, 0x7f, 0x61, 0x7b, 0xbb, 0xf7, 0xa5, 0x55, 0x53, 0x28, 0xfc, 0x29, 0x1f, 0x79, 0x49, 0x87, 0x57, 0x7f, 0x45, 0x83, 0x50, 0xdf, 0x99, 0xaf, 0x3a, 0x57, 0x78, 0x30, 0xb, 0xe0, 0xbd, 0x80, 0x16, 0x4f}}, - testcase{ - msg: []byte{0x59, 0xae, 0x20, 0xb6, 0xf7, 0xe0, 0xb3, 0xc7, 0xa9, 0x89, 0xaf, 0xb2, 0x83, 0x24, 0xa4, 0xf, 0xca, 0x25, 0xd8, 0x65, 0x1c, 0xf1, 0xf4, 0x6a, 0xe3, 0x83, 0xef, 0x6d, 0x84, 0x41, 0x58, 0x7a, 0xa1, 0xc0, 0x4c, 0x3e, 0x3b, 0xf8, 0x8e, 0x81, 0x31, 0xce, 0x61, 0x45, 0xcf, 0xb8, 0x97, 0x3d, 0x96, 0x1e, 0x84, 0x32, 0xb2, 0x2, 0xfa, 0x5a, 0xf3, 0xe0, 0x9d, 0x62, 0x5f, 0xaa, 0xd8, 0x25, 0xbc, 0x19, 0xda, 0x9b, 0x5c, 0x6c, 0x20, 0xd0, 0x2a, 0xbd, 0xa2, 0xfc, 0xc5, 0x8b, 0x5b, 0xd3, 0xfe, 0x50, 0x7b, 0xf2, 0x1, 0x26, 0x3f, 0x30, 0x54, 0x38, 0x19, 0x51, 0xc, 0x12, 0xbc, 0x23, 0xe2, 0xdd, 0xb4, 0xf7, 0x11, 0xd0, 0x87, 0xa8, 0x6e, 0xdb, 0x1b, 0x35, 0x53, 0x13, 0x36, 0x3a, 0x2d, 0xe9, 0x96, 0xb8, 0x91, 0x2, 0x5e, 0x14, 0x70, 0x36, 0x8, 0x74, 0x1, 0xcc, 0xf3, 0xca, 0x78, 0x15, 0xbf, 0x3c, 0x49}, - output224: []byte{0x74, 0xd, 0x3c, 0xb4, 0x55, 0x13, 0x31, 0x73, 0xec, 0x65, 0x2a, 0xa0, 0x47, 0x9, 0xef, 0xf, 0x54, 0x9f, 0x19, 0xa9, 0xd4, 0xcc, 0x6b, 0xec, 0x9e, 0x87, 0x6b, 0x5a}, - output256: []byte{0xec, 0x9, 0x63, 0x14, 0xe2, 0xf7, 0x3b, 0x6a, 0x70, 0x27, 0xff, 0xfa, 0x2, 0x10, 0x4c, 0x2f, 0x6d, 0xd1, 0x87, 0xf2, 0xc, 0x74, 0x34, 0x45, 0xbe, 0xfd, 0x4b, 0x5c, 0x3, 0x4b, 0x32, 0x95}, - output384: []byte{0xfa, 0xe9, 0x98, 0xd1, 0x7, 0x4e, 0x30, 0xf2, 0xea, 0xa, 0x8b, 0x9f, 0xe2, 0x59, 0xfd, 0x2e, 0x2a, 0x36, 0x80, 0x49, 0x95, 0xeb, 0xe7, 0xe3, 0xa5, 0xad, 0x34, 0x86, 0x5b, 0x1a, 0x33, 0x16, 0x67, 0x52, 0x97, 0xfe, 0x8e, 0x33, 0xee, 0xf8, 0xad, 0xcc, 0x2, 0xbe, 0x8c, 0x47, 0x65, 0xbe}, - output512: []byte{0xcb, 0xdf, 0xb0, 0xd0, 0xe7, 0x20, 0xf8, 0x72, 0x59, 0xdd, 0xd, 0xb, 0x4e, 0x9c, 0x53, 0x19, 0xe7, 0xf8, 0x8a, 0xae, 0xf7, 0xf7, 0xab, 0x2f, 0xa1, 0xca, 0x63, 0x9a, 0xfa, 0x1, 0x60, 0x82, 0x2f, 0x96, 0xb3, 0xc3, 0x57, 0xa4, 0x89, 0x4c, 0xe5, 0x3c, 0xd7, 0x13, 0xfa, 0xb2, 0x3a, 0xd0, 0x52, 0xe8, 0x56, 0x5f, 0xa3, 0xb3, 0xa5, 0x23, 0xcb, 0x9c, 0xe3, 0x9a, 0x6b, 0xd5, 0x35, 0xcc}}, - testcase{ - msg: []byte{0x77, 0xee, 0x80, 0x4b, 0x9f, 0x32, 0x95, 0xab, 0x23, 0x62, 0x79, 0x8b, 0x72, 0xb0, 0xa1, 0xb2, 0xd3, 0x29, 0x1d, 0xce, 0xb8, 0x13, 0x98, 0x96, 0x35, 0x58, 0x30, 0xf3, 0x4b, 0x3b, 0x32, 0x85, 0x61, 0x53, 0x1f, 0x80, 0x79, 0xb7, 0x9a, 0x6e, 0x99, 0x80, 0x70, 0x51, 0x50, 0x86, 0x64, 0x2, 0xfd, 0xc1, 0x76, 0xc0, 0x58, 0x97, 0xe3, 0x59, 0xa6, 0xcb, 0x1a, 0x7a, 0xb0, 0x67, 0x38, 0x3e, 0xb4, 0x97, 0x18, 0x2a, 0x7e, 0x5a, 0xef, 0x70, 0x38, 0xe4, 0xc9, 0x6d, 0x13, 0x3b, 0x27, 0x82, 0x91, 0x74, 0x17, 0xe3, 0x91, 0x53, 0x5b, 0x5e, 0x1b, 0x51, 0xf4, 0x7d, 0x8e, 0xd7, 0xe4, 0xd4, 0x2, 0x5f, 0xe9, 0x8d, 0xc8, 0x7b, 0x9c, 0x16, 0x22, 0x61, 0x4b, 0xff, 0x3d, 0x10, 0x29, 0xe6, 0x8e, 0x37, 0x2d, 0xe7, 0x19, 0x80, 0x38, 0x57, 0xca, 0x52, 0x6, 0x7c, 0xdd, 0xaa, 0xd9, 0x58, 0x95, 0x1c, 0xb2, 0x6, 0x8c, 0xc6}, - output224: []byte{0x66, 0x38, 0x35, 0xa8, 0x1a, 0x2a, 0x38, 0xd5, 0xad, 0x3a, 0x37, 0xbd, 0x9b, 0xc9, 0x66, 0x18, 0xd2, 0x7c, 0xa3, 0x22, 0x86, 0xe9, 0x9, 0x18, 0x34, 0xa0, 0x87, 0x1a}, - output256: []byte{0xfe, 0x71, 0xd0, 0x1c, 0x2e, 0xe5, 0xe, 0x5, 0x4d, 0x6b, 0x7, 0x14, 0x7e, 0xf6, 0x29, 0x54, 0xfd, 0xe7, 0xe6, 0x95, 0x9d, 0x6e, 0xeb, 0xa6, 0x8e, 0x3c, 0x94, 0x10, 0x7e, 0xb0, 0x8, 0x4d}, - output384: []byte{0xa, 0xa9, 0xcc, 0xc3, 0xc9, 0xca, 0xe1, 0x60, 0x3d, 0x3d, 0xa5, 0xe9, 0x5f, 0x30, 0x4a, 0xdb, 0x8f, 0xa5, 0x75, 0x83, 0x39, 0x29, 0xb0, 0x9f, 0x7c, 0x10, 0x95, 0xd9, 0x68, 0xbe, 0xa0, 0x47, 0x1d, 0xfe, 0x8a, 0xaa, 0xd3, 0xad, 0x11, 0x26, 0x6d, 0xaa, 0xff, 0x95, 0xf6, 0x66, 0x7a, 0xbc}, - output512: []byte{0x5, 0x9a, 0x18, 0x1c, 0x83, 0xa2, 0x2b, 0xff, 0xa, 0xa9, 0xba, 0xa2,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, 0xa8, 0x5, 0x2f, 0xbb}, - output224: []byte{0x25, 0x94, 0x15, 0x3a, 0xc2, 0xde, 0x68, 0x1f, 0x4d, 0xee, 0x34, 0xf, 0xa3, 0x44, 0xec, 0x38, 0x87, 0x73, 0xa3, 0x77, 0xd5, 0xb8, 0x9e, 0x50, 0x32, 0x54, 0xfd, 0x2e}, - output256: []byte{0xbd, 0x6f, 0x54, 0x92, 0x58, 0x2a, 0x7c, 0x1b, 0x11, 0x63, 0x4, 0xde, 0x28, 0x31, 0x4d, 0xf9, 0xff, 0xfe, 0x95, 0xb0, 0xda, 0x11, 0xaf, 0x52, 0xfe, 0x94, 0x40, 0xa7, 0x17, 0xa3, 0x48, 0x59}, - output384: []byte{0x8f, 0xfd, 0xf6, 0xa4, 0x75, 0x2d, 0x17, 0xd4, 0x96, 0xf8, 0xad, 0xee, 0x71, 0x16, 0xbd, 0x2a, 0xf0, 0xa4, 0xb7, 0x26, 0xbb, 0x3f, 0x4c, 0x5f, 0x85, 0xbe, 0x2c, 0x9d, 0xfc, 0x34, 0x5, 0x5a, 0x50, 0x9e, 0x4f, 0xe0, 0x16, 0x93, 0xd, 0x99, 0x51, 0xa7, 0x21, 0x25, 0x53, 0xe2, 0xe9, 0x8}, - output512: []byte{0x9e, 0xde, 0xeb, 0x10, 0xee, 0x1b, 0x7b, 0xb8, 0xf1, 0x6a, 0x28, 0xd, 0x8c, 0xc3, 0xed, 0xa5, 0xe9, 0x9, 0xc5, 0x54, 0x41, 0x9d, 0xdc, 0x52, 0x3b, 0x69, 0xec, 0xed, 0xf2, 0xad, 0xf3, 0xb3, 0xc9, 0xbc, 0x66, 0xfe, 0xf3, 0x65, 0x34, 0x24, 0x71, 0xc4, 0x58, 0x12, 0x6f, 0x8, 0x3a, 0x3b, 0x8e, 0x7c, 0xc, 0x9d, 0x9d, 0x77, 0xe9, 0xf9, 0x1, 0x96, 0xb7, 0x1f, 0x9a, 0xad, 0xf4, 0x92}}, - testcase{ - msg: []byte{0xb3, 0x2d, 0x95, 0xb0, 0xb9, 0xaa, 0xd2, 0xa8, 0x81, 0x6d, 0xe6, 0xd0, 0x6d, 0x1f, 0x86, 0x0, 0x85, 0x5, 0xbd, 0x8c, 0x14, 0x12, 0x4f, 0x6e, 0x9a, 0x16, 0x3b, 0x5a, 0x2a, 0xde, 0x55, 0xf8, 0x35, 0xd0, 0xec, 0x38, 0x80, 0xef, 0x50, 0x70, 0xd, 0x3b, 0x25, 0xe4, 0x2c, 0xc0, 0xaf, 0x5, 0xc, 0xcd, 0x1b, 0xe5, 0xe5, 0x55, 0xb2, 0x30, 0x87, 0xe0, 0x4d, 0x7b, 0xf9, 0x81, 0x36, 0x22, 0x78, 0xc, 0x73, 0x13, 0xa1, 0x95, 0x4f, 0x87, 0x40, 0xb6, 0xee, 0x2d, 0x3f, 0x71, 0xf7, 0x68, 0xdd, 0x41, 0x7f, 0x52, 0x4, 0x82, 0xbd, 0x3a, 0x8, 0xd4, 0xf2, 0x22, 0xb4, 0xee, 0x9d, 0xbd, 0x1, 0x54, 0x47, 0xb3, 0x35, 0x7, 0xdd, 0x50, 0xf3, 0xab, 0x42, 0x47, 0xc5, 0xde, 0x9a, 0x8a, 0xbd, 0x62, 0xa8, 0xde, 0xce, 0xa0, 0x1e, 0x3b, 0x87, 0xc8, 0xb9, 0x27, 0xf5, 0xb0, 0x8b, 0xeb, 0x37, 0x67, 0x4c, 0x6f, 0x8e, 0x38, 0xc, 0x4}, - output224: []byte{0x42, 0x27, 0x5c, 0x29, 0x69, 0x37, 0x74, 0x57, 0x58, 0xff, 0x2b, 0x7b, 0xee, 0x9a, 0x89, 0x71, 0x91, 0xae, 0x87, 0xe4, 0x2b, 0xd1, 0x1, 0x98, 0xd9, 0x46, 0x6c, 0x19}, - output256: []byte{0xe7, 0x17, 0xa7, 0x76, 0x94, 0x48, 0xab, 0xbe, 0x5f, 0xef, 0x81, 0x87, 0x95, 0x4a, 0x88, 0xac, 0x56, 0xde, 0xd1, 0xd2, 0x2e, 0x63, 0x94, 0xa, 0xb8, 0xd, 0x2, 0x95, 0x85, 0xa2, 0x19, 0x21}, - output384: []byte{0x27, 0x8e, 0x83, 0xcf, 0xf1, 0xff, 0x6c, 0xc4, 0xb3, 0xac, 0x41, 0xf3, 0x87, 0x9d, 0xa8, 0x7a, 0xe6, 0x3b, 0x53, 0x5b, 0x43, 0x81, 0x5e, 0x27, 0x36, 0x87, 0xa4, 0xcc, 0x51, 0x98, 0x55, 0xb4, 0x52, 0xcb, 0x6a, 0xf0, 0x19, 0x8b, 0xb9, 0xfd, 0xf, 0x3e, 0x43, 0x73, 0x9b, 0xc0, 0xcd, 0xd7}, - output512: []byte{0xa6, 0x5, 0x4f, 0xfc, 0x3d, 0x81, 0x59, 0x1b, 0xe9, 0x64, 0xc4, 0xb0, 0x4, 0xa3, 0xa2, 0x11, 0x42, 0x36, 0x5b, 0x59, 0xee, 0x98, 0xb2, 0x87, 0x3d, 0x48, 0x82, 0x93, 0xf9, 0x3a, 0x8d, 0x71, 0x54, 0xbf, 0x72, 0x10, 0x0, 0x12, 0xc6, 0xd, 0x3c, 0x94, 0x18, 0xf6, 0xaf, 0x8e, 0xa6, 0x63, 0x72, 0xcb, 0x47, 0x3, 0xf5, 0xf6, 0x38, 0x1d, 0xe6, 0xd4, 0xb9, 0xb9, 0x8c, 0xff, 0x1e, 0x90}}, - testcase{ - msg: []byte{0x4, 0x41, 0xe, 0x31, 0x8, 0x2a, 0x47, 0x58, 0x4b, 0x40, 0x6f, 0x5, 0x13, 0x98, 0xa6, 0xab, 0xe7, 0x4e, 0x4d, 0xa5, 0x9b, 0xb6, 0xf8, 0x5e, 0x6b, 0x49, 0xe8, 0xa1, 0xf7, 0xf2, 0xca, 0x0, 0xdf, 0xba, 0x54, 0x62, 0xc2, 0xcd, 0x2b, 0xfd, 0xe8, 0xb6, 0x4f, 0xb2, 0x1d, 0x70, 0xc0, 0x83, 0xf1, 0x13, 0x18, 0xb5, 0x6a, 0x52, 0xd0, 0x3b, 0x81, 0xca, 0xc5, 0xee, 0xc2, 0x9e, 0xb3, 0x1b, 0xd0, 0x7, 0x8b, 0x61, 0x56, 0x78, 0x6d, 0xa3, 0xd6, 0xd8, 0xc3, 0x30, 0x98, 0xc5, 0xc4, 0x7b, 0xb6, 0x7a, 0xc6, 0x4d, 0xb1, 0x41, 0x65, 0xaf, 0x65, 0xb4, 0x45, 0x44, 0xd8, 0x6, 0xdd, 0xe5, 0xf4, 0x87, 0xd5, 0x37, 0x3c, 0x7f, 0x97, 0x92, 0xc2, 0x99, 0xe9, 0x68, 0x6b, 0x7e, 0x58, 0x21, 0xe7, 0xc8, 0xe2, 0x45, 0x83, 0x15, 0xb9, 0x96, 0xb5, 0x67, 0x7d, 0x92, 0x6d, 0xac, 0x57, 0xb3, 0xf2, 0x2d, 0xa8, 0x73, 0xc6, 0x1, 0x1, 0x6a, 0xd}, - output224: []byte{0x14, 0x3f, 0x90, 0x55, 0xeb, 0x1f, 0x73, 0x67, 0x29, 0xc7, 0x77, 0x21, 0xfb, 0x65, 0xed, 0x5e, 0xe1, 0x42, 0xf6, 0xe9, 0x69, 0x13, 0x2f, 0xb2, 0x29, 0x89, 0xc1, 0x1f}, - output256: []byte{0xa9, 0x5d, 0x50, 0xb5, 0xb, 0x45, 0x45, 0xf0, 0x94, 0x74, 0x41, 0xdf, 0x74, 0xa1, 0xe9, 0xd7, 0x46, 0x22, 0xeb, 0x3b, 0xaa, 0x49, 0xc1, 0xbb, 0xfc, 0x3a, 0xc, 0xce, 0x66, 0x19, 0xc1, 0xaa}, - output384: []byte{0xaa, 0x4b, 0x5a, 0x5f, 0xb9, 0x4f, 0xe1, 0x95, 0x78, 0xf3, 0x33, 0x23, 0xba, 0x1e, 0xef, 0xc5, 0xb6, 0xed, 0x70, 0xb3, 0x4b, 0xc7, 0x1, 0x93, 0xf3, 0x86, 0xc9, 0x9f, 0x73, 0x86, 0x36, 0x11, 0xaf, 0x20, 0x58, 0x1b, 0x4b, 0x1b, 0x3e, 0xd7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xb7, 0x5f, 0x7c, 0x69, 0x75, 0xc, 0xb6, 0x7d, 0x82, 0x2c, 0x96, 0x17, 0x6c, 0x46, 0xbd, 0x8a, 0x29, 0xf1, 0x70, 0x13, 0x73, 0xfb, 0x9, 0xa1, 0xa6, 0xe3, 0xc7, 0x15, 0x8f}, - output224: []byte{0x44, 0x9a, 0x3, 0x13, 0xcc, 0xab, 0x44, 0x27, 0x3, 0x2b, 0x6b, 0xe9, 0xd6, 0x6f, 0x82, 0x7f, 0xfb, 0x4c, 0x71, 0xb5, 0x38, 0xb2, 0x10, 0x4f, 0x9d, 0x14, 0xd1, 0x4a}, - output256: []byte{0xed, 0x53, 0xd7, 0x25, 0x95, 0xac, 0xe3, 0xa6, 0xd5, 0x16, 0x6a, 0x4e, 0xde, 0x41, 0xcc, 0xe3, 0x62, 0xd6, 0x44, 0xbd, 0xed, 0x77, 0x2b, 0xe6, 0x16, 0xb8, 0x7b, 0xcf, 0x67, 0x8a, 0x63, 0x64}, - output384: []byte{0x31, 0x74, 0xcf, 0x37, 0x54, 0xa6, 0xfe, 0x60, 0x36, 0x31, 0xec, 0xda, 0x48, 0x95, 0x17, 0x1a, 0x9d, 0xcf, 0x7a, 0xfb, 0x2, 0xeb, 0x72, 0xae, 0x27, 0xa, 0x9e, 0x3e, 0xbf, 0x2a, 0x65, 0xa7, 0x2c, 0x34, 0x36, 0xc2, 0x33, 0xfd, 0x4f, 0x17, 0xf7, 0xfb, 0xaf, 0xba, 0xc0, 0x68, 0xc, 0x63}, - output512: []byte{0x3c, 0xe9, 0x60, 0x77, 0xeb, 0x17, 0xc6, 0xa9, 0xc9, 0x5a, 0x9a, 0x47, 0x77, 0x48, 0x87, 0x6c, 0x64, 0x51, 0x9, 0x8d, 0xbe, 0xa2, 0xb3, 0x26, 0x1e, 0x6d, 0x75, 0xb6, 0x4a, 0x98, 0x8e, 0x1c, 0x75, 0xd7, 0xea, 0xc7, 0x3b, 0xc2, 0x40, 0x2a, 0xfc, 0x72, 0x65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, 0x15, 0xeb, 0x6f, 0x7d, 0x42, 0xb0, 0x1d}, - output256: []byte{0x81, 0x4, 0x1, 0xb2, 0x47, 0xc2, 0x35, 0x29, 0xe2, 0x46, 0x55, 0xca, 0xb8, 0x6c, 0x42, 0xdf, 0x44, 0x8, 0x5d, 0xa7, 0x6c, 0xa0, 0x1c, 0x9a, 0x14, 0x61, 0x8e, 0x56, 0x3b, 0x7c, 0x41, 0xbe}, - output384: []byte{0x35, 0x48, 0x13, 0xd9, 0x82, 0x3d, 0x2f, 0x2, 0xd7, 0x5d, 0x13, 0x89, 0x3a, 0x6a, 0xbd, 0xb4, 0x4e, 0x9e, 0x99, 0x66, 0x65, 0x33, 0x42, 0x9c, 0xc6, 0xf7, 0xeb, 0x3f, 0xba, 0x10, 0xbf, 0x9e, 0xcd, 0x4a, 0x18, 0xbb, 0x9d, 0x51, 0x88, 0xe6, 0xe8, 0xf9, 0x1d, 0xfd, 0xdb, 0xe8, 0x40, 0x9a}, - output512: []byte{0xc9, 0xac, 0xd6, 0xd9, 0x8a, 0x34, 0x95, 0x12, 0xb9, 0x52, 0xd1, 0x51, 0xed, 0x50, 0x15, 0x62, 0xf0, 0x4e, 0xa4, 0xbb, 0x4b, 0x89, 0x65, 0x81, 0x25, 0x10, 0xb9, 0xb8, 0x42, 0x53, 0x1a, 0x2b, 0x41, 0xa0, 0x10, 0x8a, 0xc1, 0x29, 0xcf, 0x9c, 0x95, 0x17, 0xbe, 0x79, 0x9, 0x21, 0xdf, 0x64, 0xad, 0x1d, 0xfc, 0xb, 0x93, 0xdd, 0xba, 0x34, 0x15, 0xee, 0xba, 0xf0, 0xda, 0x72, 0xf6, 0xa0}}, - testcase{ - msg: []byte{0x9b, 0xb4, 0xaf, 0x1b, 0x4f, 0x9, 0xc0, 0x71, 0xce, 0x3c, 0xaf, 0xa9, 0x2e, 0x4e, 0xb7, 0x3c, 0xe8, 0xa6, 0xf5, 0xd8, 0x2a, 0x85, 0x73, 0x34, 0x40, 0x36, 0x8d, 0xee, 0x4e, 0xb1, 0xcb, 0xc7, 0xb5, 0x5a, 0xc1, 0x50, 0x77, 0x3b, 0x6f, 0xe4, 0x7d, 0xbe, 0x3, 0x6c, 0x45, 0x58, 0x2e, 0xd6, 0x7e, 0x23, 0xf4, 0xc7, 0x45, 0x85, 0xda, 0xb5, 0x9, 0xdf, 0x1b, 0x83, 0x61, 0x5, 0x64, 0x54, 0x56, 0x42, 0xb2, 0xb1, 0xec, 0x46, 0x3e, 0x18, 0x4, 0x8f, 0xc2, 0x34, 0x77, 0xc6, 0xb2, 0xaa, 0x3, 0x55, 0x94, 0xec, 0xd3, 0x37, 0x91, 0xaf, 0x6a, 0xf4, 0xcb, 0xc2, 0xa1, 0x16, 0x6a, 0xba, 0x8d, 0x62, 0x8c, 0x57, 0xe7, 0x7, 0xf0, 0xb0, 0xe8, 0x70, 0x7c, 0xaf, 0x91, 0xcd, 0x44, 0xbd, 0xb9, 0x15, 0xe0, 0x29, 0x6e, 0x1, 0x90, 0xd5, 0x6d, 0x33, 0xd8, 0xdd, 0xe1, 0xb, 0x5b, 0x60, 0x37, 0x78, 0x38, 0x97, 0x3c, 0x1d, 0x94, 0x3c, 0x22, 0xed, 0x33, 0x5e}, - output224: []byte{0xd5, 0x53, 0x4c, 0x72, 0xbe, 0x2e, 0x4b, 0x1f, 0xaa, 0xa8, 0x13, 0x11, 0x8b, 0xd, 0x29, 0xdb, 0xb8, 0x6f, 0x62, 0x40, 0x67, 0xea, 0x34, 0x51, 0x5a, 0xfa, 0x8, 0xbe}, - output256: []byte{0x9f, 0x1, 0xe6, 0x3f, 0x23, 0x55, 0x39, 0x3e, 0xcb, 0x19, 0x8, 0xd0, 0xca, 0xf3, 0x97, 0x18, 0x83, 0x30, 0x4, 0xa4, 0xbf, 0x37, 0xeb, 0xf4, 0xcf, 0x8d, 0x73, 0x19, 0xb6, 0x51, 0x72, 0xdf}, - output384: []byte{0xe2, 0xef, 0xdc, 0x50, 0x7, 0xe4, 0xc1, 0x3f, 0x81, 0x10, 0x43, 0xdb, 0x96, 0x7a, 0x42, 0x3d, 0xe0, 0x2a, 0xf4, 0x11, 0xb4, 0xa2, 0x51, 0xa2, 0x25, 0xca, 0xd0, 0x41, 0xe8, 0x3b, 0xd4, 0xdd, 0x89, 0xd8, 0xb2, 0x41, 0x98, 0xda, 0x0, 0x9, 0x6c, 0xfe, 0x2e, 0x1b, 0x3f, 0x5d, 0x19, 0x60}, - output512: []byte{0x26, 0xb4, 0xe5, 0xc4, 0xfa, 0x85, 0xcb, 0x33, 0x35, 0x94, 0x50, 0xe7, 0xf7, 0x15, 0x8f, 0xb6, 0xa0, 0x73, 0x99, 0x84, 0x56, 0x5e, 0x9d, 0x9e, 0xbe, 0x6a, 0xd6, 0x5b, 0x11, 0x82, 0x96, 0xe9, 0xc1, 0x9, 0x8c, 0x11, 0x54, 0x1c, 0x87, 0x1e, 0xb1, 0xb8, 0x98, 0x53, 0xf1, 0xfa, 0x73, 0xad, 0x87, 0x2, 0xeb, 0xf4, 0xfc, 0x9b, 0xe4, 0xd0, 0xab, 0x5, 0x7e, 0x43, 0x91, 0xdf, 0x96, 0x4e}}, - testcase{ - msg: []byte{0x21, 0x67, 0xf0, 0x21, 0x18, 0xcc, 0x62, 0x4, 0x3e, 0x90, 0x91, 0xa6, 0x47, 0xca, 0xdb, 0xed, 0x95, 0x61, 0x1a, 0x52, 0x1f, 0xe0, 0xd6, 0x4e, 0x85, 0x18, 0xf1, 0x6c, 0x80, 0x8a, 0xb2, 0x97, 0x72, 0x55, 0x98, 0xae, 0x29, 0x68, 0x80, 0xa7, 0x73, 0x60, 0x7a, 0x79, 0x8f, 0x7c, 0x3c, 0xfc, 0xe8, 0xd, 0x25, 0x1e, 0xbe, 0xc6, 0x88, 0x50, 0x15, 0xf9, 0xab, 0xf7, 0xea, 0xab, 0xae, 0x46, 0x79, 0x8f, 0x82, 0xcb, 0x59, 0x26, 0xde, 0x5c, 0x23, 0xf4, 0x4a, 0x3f, 0x9f, 0x95, 0x34, 0xb3, 0xc6, 0xf4, 0x5, 0xb5, 0x36, 0x4c, 0x2f, 0x8a, 0x8b, 0xdc, 0x5c, 0xa4, 0x9c, 0x74, 0x9b, 0xed, 0x8c, 0xe4, 0xba, 0x48, 0x89, 0x70, 0x62, 0xae, 0x84, 0x24, 0xca, 0x6d, 0xde, 0x5f, 0x55, 0xc0, 0xe4, 0x2a, 0x95, 0xd1, 0xe2, 0x92, 0xca, 0x54, 0xfb, 0x46, 0xa8, 0x4f, 0xbc, 0x9c, 0xd8, 0x7f, 0x2d, 0xc, 0x9e, 0x74, 0x48, 0xde, 0x30, 0x43, 0xae, 0x22, 0xfd, 0xd2, 0x29}, - output224: []byte{0xc0, 0xcd, 0x41, 0x3b, 0x1c, 0xe0, 0x0, 0xa1, 0xbb, 0xe3, 0xa2, 0xcd, 0x10, 0x3c, 0x7f, 0x8f, 0x95, 0x92, 0x5a, 0xc6, 0xc8, 0xa5, 0xc9, 0x22, 0xaf, 0xb5, 0xf9, 0x6d}, - output256: []byte{0x7e, 0xc1, 0x1d, 0xe7, 0xdb, 0x79, 0xa, 0x85, 0x2, 0x81, 0xf0, 0x43, 0x59, 0x27, 0x79, 0xb4, 0x9, 0x19, 0x5d, 0xb4, 0xec, 0xed, 0xee, 0xfb, 0xb9, 0x3b, 0xa6, 0x83, 0xd3, 0xbc, 0xa8, 0x51}, - output384: []byte{0xe4, 0x4c, 0x8, 0x56, 0xf0, 0xc2, 0x45, 0xe0, 0x2, 0xf9, 0x14, 0xcf, 0x30, 0xe, 0x98, 0xc4, 0x96, 0xe7, 0x25, 0xa4, 0xdb, 0x56, 0x1f, 0x29, 0x95, 0xad, 0x9c, 0x8b, 0x97, 0xf3, 0x41, 0xe1, 0x56, 0x25, 0xb5, 0x6b, 0x3, 0xd4, 0xd5, 0x88, 0x9, 0x27, 0xb8, 0x57, 0x4f, 0x5e, 0x5d, 0x74}, - output512: []byte{0x91, 0x3b, 0xba, 0x5c, 0xc, 0x13, 0xcc, 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 0x9e, 0xbc, 0xa, 0x5b, 0x6c, 0x33, 0x8c, 0xbb, 0x8f, 0x66, 0x59, 0xd3, 0x42, 0xa2, 0x43, 0x68, 0xcf}, - output224: []byte{0x93, 0xc6, 0xbf, 0x58, 0x5e, 0x99, 0x4b, 0x16, 0x69, 0x18, 0x4a, 0xc7, 0x1d, 0xc8, 0xe7, 0x72, 0xb5, 0x34, 0x43, 0xe6, 0x68, 0xda, 0x7, 0x86, 0xd5, 0x28, 0x9, 0xb}, - output256: []byte{0xa7, 0x4a, 0xf9, 0xc5, 0x23, 0xb4, 0xa0, 0x8d, 0x9d, 0xb9, 0x69, 0x2e, 0xa8, 0x92, 0x55, 0x97, 0x7a, 0x59, 0x19, 0xb9, 0x29, 0x2b, 0x7c, 0xd0, 0xd9, 0x2c, 0x90, 0xc9, 0x7c, 0x98, 0xe2, 0x24}, - output384: []byte{0x5d, 0x29, 0xc, 0x5d, 0xff, 0x59, 0xa3, 0xa3, 0xdb, 0x8b, 0xc7, 0x32, 0xb, 0x8f, 0x64, 0xa4, 0xdb, 0xf6, 0x7c, 0xa4, 0xf5, 0xdf, 0x9a, 0x7, 0xf2, 0x35, 0xed, 0xb6, 0x46, 0x3, 0x45, 0xfc, 0x89, 0x71, 0x4, 0x4, 0x81, 0xc9, 0xa5, 0xd0, 0xf0, 0x9b, 0x62, 0x26, 0x2b, 0x9e, 0xd9, 0xf8}, - output512: []byte{0xe5, 0xd5, 0x3e, 0x81, 0x86, 0x62, 0x83, 0x17, 0x90, 0x12, 0xd9, 0x23, 0x93, 0x40, 0xb0, 0xcb, 0xfb, 0x8d, 0x7a, 0xeb, 0xce, 0xc, 0x82, 0x4d, 0xc6, 0x65, 0x3a, 0x65, 0x2b, 0xb1, 0xb5, 0x4e, 0x8, 0x83, 0x99, 0x1b, 0xe2, 0xc3, 0xe3, 0x9a, 0xd1, 0x11, 0xa7, 0xb2, 0x4e, 0x95, 0xda, 0xf6, 0xf7, 0xd9, 0xa3, 0x79, 0xd8,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 0x21, 0x4, 0xe0}, - output256: []byte{0x34, 0x4d, 0x12, 0x9c, 0x22, 0x83, 0x59, 0x46, 0x3c, 0x40, 0x55, 0x5d, 0x94, 0x21, 0x3d, 0x1, 0x56, 0x27, 0xe5, 0x87, 0x1c, 0x4, 0xf1, 0x6, 0xa0, 0xfe, 0xef, 0x93, 0x61, 0xcd, 0xec, 0xb6}, - output384: []byte{0xfe, 0x68, 0x2, 0x50, 0xca, 0xb1, 0xfb, 0xdb, 0x6a, 0xc8, 0x80, 0xd, 0xdc, 0x28, 0xe7, 0x1, 0x0, 0xdf, 0x8d, 0xaa, 0xe3, 0x8d, 0xa2, 0x70, 0x4, 0x87, 0x2a, 0xb0, 0x5d, 0x40, 0xb1, 0x5a, 0xe9, 0x3e, 0xb4, 0x42, 0x66, 0xe3, 0x1, 0x4f, 0x9, 0x60, 0x3, 0x8b, 0x28, 0x25, 0x2c, 0x7b}, - output512: []byte{0x5d, 0xa8, 0x3b, 0x7e, 0x22, 0x19, 0x33, 0xcd, 0x67, 0xfa, 0x2a, 0xf8, 0xc9, 0x93, 0x4d, 0xb7, 0x4c, 0xe8, 0x22, 0x21, 0x2c, 0x99, 0xe0, 0xee, 0x1, 0xf5, 0x22, 0xb, 0x4f, 0xe1, 0xe9, 0xb0, 0x38, 0x8e, 0x42, 0xe3, 0x28, 0xa1, 0xd1, 0x74, 0xe6, 0x36, 0x8f, 0x57, 0x73, 0x85, 0x30, 0x42, 0x54, 0x3a, 0x9b, 0x49, 0x3a, 0x94, 0xb6, 0x25, 0x98, 0xb, 0x73, 0xdf, 0x3f, 0x3f, 0xcc, 0xbb}}, - testcase{ - msg: []byte{0x15, 0x7d, 0x5b, 0x7e, 0x45, 0x7, 0xf6, 0x6d, 0x9a, 0x26, 0x74, 0x76, 0xd3, 0x38, 0x31, 0xe7, 0xbb, 0x76, 0x8d, 0x4d, 0x4, 0xcc, 0x34, 0x38, 0xda, 0x12, 0xf9, 0x1, 0x2, 0x63, 0xea, 0x5f, 0xca, 0xfb, 0xde, 0x25, 0x79, 0xdb, 0x2f, 0x6b, 0x58, 0xf9, 0x11, 0xd5, 0x93, 0xd5, 0xf7, 0x9f, 0xb0, 0x5f, 0xe3, 0x59, 0x6e, 0x3f, 0xa8, 0xf, 0xf2, 0xf7, 0x61, 0xd1, 0xb0, 0xe5, 0x70, 0x80, 0x5, 0x5c, 0x11, 0x8c, 0x53, 0xe5, 0x3c, 0xdb, 0x63, 0x5, 0x52, 0x61, 0xd7, 0xc9, 0xb2, 0xb3, 0x9b, 0xd9, 0xa, 0xcc, 0x32, 0x52, 0xc, 0xbb, 0xdb, 0xda, 0x2c, 0x4f, 0xd8, 0x85, 0x6d, 0xbc, 0xee, 0x17, 0x31, 0x32, 0xa2, 0x67, 0x91, 0x98, 0xda, 0xf8, 0x30, 0x7, 0xa9, 0xb5, 0xc5, 0x15, 0x11, 0xae, 0x49, 0x76, 0x6c, 0x79, 0x2a, 0x29, 0x52, 0x3, 0x88, 0x44, 0x4e, 0xbe, 0xfe, 0x28, 0x25, 0x6f, 0xb3, 0x3d, 0x42, 0x60, 0x43, 0x9c, 0xba, 0x73, 0xa9, 0x47, 0x9e, 0xe0, 0xc, 0x63}, - output224: []byte{0x6d, 0x73, 0x5f, 0xb7, 0x57, 0x91, 0x35, 0xf6, 0x1b, 0x77, 0x1b, 0x2b, 0xb0, 0xd8, 0x15, 0x14, 0xcd, 0xe9, 0xc9, 0x77, 0xac, 0xcf, 0x6f, 0xea, 0xf6, 0xed, 0xeb, 0xf0}, - output256: []byte{0x4c, 0xe7, 0xc2, 0xb9, 0x35, 0xf2, 0x1f, 0xc3, 0x4c, 0x5e, 0x56, 0xd9, 0x40, 0xa5, 0x55, 0xc5, 0x93, 0x87, 0x2a, 0xec, 0x2f, 0x89, 0x6d, 0xe4, 0xe6, 0x8f, 0x2a, 0x1, 0x70, 0x60, 0xf5, 0x35}, - output384: []byte{0x51, 0x1b, 0x13, 0xe5, 0x3f, 0xd3, 0x53, 0xfa, 0x4d, 0x38, 0xef, 0xc, 0xf8, 0xf1, 0xaf, 0x30, 0xda, 0x55, 0x48, 0x28, 0xa5, 0xfd, 0x1c, 0x53, 0xec, 0x41, 0xf7, 0x3d, 0x9a, 0xca, 0x6c, 0x54, 0xac, 0x79, 0x72, 0xc9, 0x33, 0xaf, 0x4a, 0x2f, 0xc7, 0xab, 0x85, 0x2c, 0xa6, 0x3a, 0x1b, 0xa6}, - output512: []byte{0x72, 0xde, 0x91, 0x84, 0xbe, 0xb5, 0xc6, 0xa3, 0x7e, 0xa2, 0xc3, 0x95, 0x73, 0x4d, 0xd, 0x54, 0x12, 0x99, 0x1a, 0x57, 0xcf, 0xfc, 0xc1, 0x3f, 0xf9, 0xb5, 0xfa, 0xf, 0x20, 0x46, 0xee, 0x87, 0xc6, 0x18, 0x11, 0xfe, 0x8e, 0xf2, 0x47, 0x2, 0x39, 0xd5, 0x6, 0x6c, 0x22, 0x1, 0x73, 0xde, 0x5e, 0xbe, 0x41, 0x88, 0x5e, 0xd8, 0xac, 0xae, 0x39, 0x7f, 0xb3, 0x95, 0xe6, 0xca, 0x9a, 0xee}}, - testcase{ - msg: []byte{0x83, 0x6b, 0x34, 0xb5, 0x15, 0x47, 0x6f, 0x61, 0x3f, 0xe4, 0x47, 0xa4, 0xe0, 0xc3, 0xf3, 0xb8, 0xf2, 0x9, 0x10, 0xac, 0x89, 0xa3, 0x97, 0x70, 0x55, 0xc9, 0x60, 0xd2, 0xd5, 0xd2, 0xb7, 0x2b, 0xd8, 0xac, 0xc7, 0x15, 0xa9, 0x3, 0x53, 0x21, 0xb8, 0x67, 0x3, 0xa4, 0x11, 0xdd, 0xe0, 0x46, 0x6d, 0x58, 0xa5, 0x97, 0x69, 0x67, 0x2a, 0xa6, 0xa, 0xd5, 0x87, 0xb8, 0x48, 0x1d, 0xe4, 0xbb, 0xa5, 0x52, 0xa1, 0x64, 0x57, 0x79, 0x78, 0x95, 0x1, 0xec, 0x53, 0xd5, 0x40, 0xb9, 0x4, 0x82, 0x1f, 0x32, 0xb0, 0xbd, 0x18, 0x55, 0xb0, 0x4e, 0x48, 0x48, 0xf9, 0xf8, 0xcf, 0xe9, 0xeb, 0xd8, 0x91, 0x1b, 0xe9, 0x57, 0x81, 0xa7, 0x59, 0xd7, 0xad, 0x97, 0x24, 0xa7, 0x10, 0x2d, 0xbe, 0x57, 0x67, 0x76, 0xb7, 0xc6, 0x32, 0xbc, 0x39, 0xb9, 0xb5, 0xe1, 0x90, 0x57, 0xe2, 0x26, 0x55, 0x2a, 0x59, 0x94, 0xc1, 0xdb, 0xb3, 0xb5, 0xc7, 0x87, 0x1a, 0x11, 0xf5, 0x53, 0x70, 0x11, 0x4, 0x4c, 0x53}, - output224: []byte{0x6d, 0x93, 0x15, 0x31, 0x45, 0x90, 0x4c, 0xeb, 0xe0, 0xe8, 0xa6, 0x6c, 0x27, 0x2b, 0xed, 0xf4, 0xf0, 0xd0, 0xa3, 0xc5, 0x3a, 0xb3, 0x2, 0x64, 0x13, 0x54, 0x31, 0xa7}, - output256: []byte{0x24, 0xb6, 0x9d, 0x8a, 0xb3, 0x5b, 0xac, 0xcb, 0xd9, 0x2f, 0x94, 0xe1, 0xb7, 0xb, 0x7, 0xc4, 0xc0, 0xec, 0xf1, 0x4e, 0xae, 0xac, 0x4b, 0x6b, 0x85, 0x60, 0x96, 0x6d, 0x5b, 0xe0, 0x86, 0xf3}, - output384: []byte{0x55, 0x4c, 0xf0, 0xa, 0x9a, 0xaf, 0xe0, 0xdf, 0xc8, 0xd4, 0x9e, 0xa0, 0x32, 0x88, 0xb5, 0x2a, 0xed, 0x43, 0xa5, 0x10, 0x4e, 0x22, 0xb8, 0x38, 0xe4, 0xf, 0xde, 0x73, 0x58, 0x49, 0x1b, 0x57, 0x74, 0xdf, 0x45, 0x5c, 0xf2, 0xec, 0x73, 0xc5, 0x3a, 0x7b, 0x30, 0x62, 0x7a, 0x14, 0x2a, 0x41}, - output512: []byte{0xb6, 0x78, 0xfa, 0x76, 0x55,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x12, 0x5, 0xc0, 0x11, 0x67, 0x4e, 0x53, 0x42, 0x6c, 0xaa, 0x45, 0x3f, 0x8d, 0xe1, 0xcb, 0xb5, 0x79, 0x32, 0xb0, 0xb7, 0x41, 0xd4, 0xc6}, - output224: []byte{0xaf, 0xe3, 0x5, 0x35, 0x67, 0x5a, 0x70, 0x21, 0xbf, 0x61, 0x89, 0x41, 0xd9, 0x4d, 0xdf, 0xfc, 0xce, 0xfc, 0xaa, 0x1e, 0xf0, 0x6c, 0xde, 0x30, 0x6d, 0x5d, 0x7a, 0x75}, - output256: []byte{0x19, 0xf3, 0x42, 0x15, 0x37, 0x3e, 0x8e, 0x80, 0xf6, 0x86, 0x95, 0x3e, 0x3, 0xca, 0x47, 0x2b, 0x50, 0x21, 0x67, 0x19, 0xcb, 0x51, 0x5e, 0x6, 0x67, 0xd4, 0xe6, 0x86, 0xe4, 0x5f, 0xcf, 0x7c}, - output384: []byte{0xc1, 0x3c, 0x17, 0x7e, 0x64, 0x53, 0xf7, 0x8e, 0x81, 0xbc, 0x4e, 0xfe, 0xa7, 0xa1, 0xe, 0x9c, 0xa0, 0x22, 0x73, 0xa6, 0xeb, 0x75, 0x74, 0x97, 0x36, 0x85, 0x39, 0xbf, 0x4a, 0xe1, 0xf1, 0xbb, 0xcb, 0xae, 0xf, 0xff, 0x5d, 0xad, 0x55, 0xed, 0xca, 0x61, 0xf4, 0x74, 0x97, 0x6c, 0xbf, 0x64}, - output512: []byte{0x66, 0xc6, 0x4d, 0x5b, 0x5, 0x85, 0xdd, 0x8c, 0x40, 0xbe, 0xcd, 0x45, 0x6e, 0x4b, 0x1, 0x88, 0x6, 0x1a, 0xe8, 0x5, 0x9f, 0x3, 0xe7, 0x9f, 0xe0, 0x4c, 0x40, 0x92, 0x54, 0x42, 0xba, 0x93, 0xb0, 0x52, 0xf5, 0x20, 0x87, 0xb3, 0xb, 0xdb, 0xfd, 0x48, 0x16, 0xbb, 0xd1, 0x48, 0x69, 0x6d, 0x4f, 0xa6, 0xc6, 0x1f, 0x21, 0x62, 0x53, 0xd7, 0xac, 0x17, 0x8b, 0x39, 0xec, 0x44, 0xc7, 0x70}}, - testcase{ - msg: []byte{0x76, 0x39, 0xb4, 0x61, 0xff, 0xf2, 0x70, 0xb2, 0x45, 0x5a, 0xc1, 0xd1, 0xaf, 0xce, 0x78, 0x29, 0x44, 0xae, 0xa5, 0xe9, 0x8, 0x7e, 0xb4, 0xa3, 0x9e, 0xb9, 0x6b, 0xb5, 0xc3, 0xba, 0xaf, 0xe, 0x86, 0x8c, 0x85, 0x26, 0xd3, 0x40, 0x4f, 0x94, 0x5, 0xe7, 0x9e, 0x77, 0xbf, 0xac, 0x5f, 0xfb, 0x89, 0xbf, 0x19, 0x57, 0xb5, 0x23, 0xe1, 0x7d, 0x34, 0x1d, 0x73, 0x23, 0xc3, 0x2, 0xea, 0x70, 0x83, 0x87, 0x2d, 0xd5, 0xe8, 0x70, 0x56, 0x94, 0xac, 0xdd, 0xa3, 0x6d, 0x5a, 0x1b, 0x89, 0x5a, 0xaa, 0x16, 0xec, 0xa6, 0x10, 0x4c, 0x82, 0x68, 0x85, 0x32, 0xc8, 0xbf, 0xe1, 0x79, 0xb, 0x5d, 0xc9, 0xf4, 0xec, 0x5f, 0xe9, 0x5b, 0xae, 0xd3, 0x7e, 0x1d, 0x28, 0x7b, 0xe7, 0x10, 0x43, 0x1f, 0x1e, 0x5e, 0x8e, 0xe1, 0x5, 0xbc, 0x42, 0xed, 0x37, 0xd7, 0x4b, 0x1e, 0x55, 0x98, 0x4b, 0xf1, 0xc0, 0x9f, 0xe6, 0xa1, 0xfa, 0x13, 0xef, 0x3b, 0x96, 0xfa, 0xea, 0xed, 0x6a, 0x2a, 0x19, 0x50, 0xa1, 0x21, 0x53}, - output224: []byte{0x91, 0x65, 0x1, 0x61, 0x48, 0x91, 0xbd, 0x99, 0x40, 0xa, 0x8a, 0xea, 0xab, 0xf6, 0x93, 0x26, 0xfa, 0x98, 0xb8, 0x33, 0xae, 0xd8, 0x23, 0x86, 0xab, 0x19, 0xe5, 0x7}, - output256: []byte{0x29, 0xb, 0xd4, 0x80, 0x8e, 0x56, 0x76, 0xeb, 0xc, 0x97, 0x80, 0x84, 0xe4, 0xcd, 0x68, 0xe7, 0x45, 0x3, 0x16, 0x59, 0xa2, 0x68, 0x7, 0xad, 0x61, 0x5b, 0x10, 0xcd, 0xa5, 0x89, 0xb9, 0x69}, - output384: []byte{0xc3, 0xe5, 0xdd, 0xf4, 0x57, 0x2a, 0x38, 0x6c, 0x99, 0xf9, 0x98, 0xe6, 0x8f, 0xcc, 0xc7, 0xf8, 0x58, 0x67, 0xa7, 0x3e, 0x13, 0xc2, 0x5, 0x8c, 0x18, 0x39, 0x1a, 0x92, 0x24, 0x16, 0xfd, 0x35, 0x2c, 0xa6, 0xb6, 0x59, 0xba, 0xd0, 0x21, 0xe0, 0xd9, 0xa0, 0x57, 0x89, 0xf5, 0x9d, 0x3c, 0x67}, - output512: []byte{0xa7, 0xbd, 0x50, 0x6d, 0xb9, 0xc0, 0x50, 0x9a, 0xd4, 0x74, 0x13, 0xaf, 0x4b, 0xe, 0x39, 0x48, 0xb4, 0x7c, 0x18, 0x27, 0x8f, 0x15, 0xf5, 0xb1, 0x9f, 0xbb, 0xb, 0x76, 0xe2, 0xc1, 0xc1, 0xf1, 0x9d, 0xb9, 0x43, 0x85, 0x28, 0xeb, 0x6d, 0x87, 0xb0, 0xb4, 0xa5, 0x9, 0x56, 0x7d, 0xb3, 0x9f, 0x32, 0x64, 0x1e, 0x29, 0x44, 0x36, 0x57, 0x80, 0x91, 0x42, 0x96, 0xcf, 0x3e, 0x48, 0xce, 0xcf}}, - testcase{ - msg: []byte{0xeb, 0x65, 0x13, 0xfc, 0x61, 0xb3, 0xc, 0xfb, 0xa5, 0x8d, 0x4d, 0x7e, 0x80, 0xf9, 0x4d, 0x14, 0x58, 0x90, 0x90, 0xcf, 0x1d, 0x80, 0xb1, 0xdf, 0x2e, 0x68, 0x8, 0x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 0xdd, 0x65, 0x6c, 0x80, 0x54, 0x6f, 0xb1, 0xbf, 0x51, 0x6d, 0x62, 0xee, 0x82, 0xba, 0xa9, 0x92, 0x91, 0xe, 0xf4, 0xcc, 0x18, 0xb7, 0xf, 0x3f, 0x86, 0x98, 0x27, 0x6f, 0xcf, 0xb4, 0x4e, 0xe, 0xc5, 0x46, 0xc2, 0xc3, 0x9c, 0xfd, 0x8e, 0xe9, 0x10, 0x34, 0xff, 0x93, 0x3, 0x5, 0x8b, 0x42, 0x52, 0x46, 0x2f, 0x86, 0xc8, 0x23, 0xeb, 0x15, 0xbf, 0x48, 0x1e, 0x6b, 0x79, 0xcc, 0x3a, 0x2, 0x21, 0x85, 0x95, 0xb3, 0x65, 0x8e, 0x8b, 0x37, 0x38, 0x2b, 0xd5, 0x4, 0x8e, 0xae, 0xd5, 0xfd, 0x2, 0xc3, 0x79, 0x44, 0xe7, 0x3b}, - output224: []byte{0x73, 0x3a, 0xcd, 0xf9, 0xce, 0xd4, 0x7f, 0x2e, 0x43, 0x93, 0x6e, 0xd6, 0xc2, 0xac, 0xf, 0x82, 0x4f, 0x4f, 0x5b, 0x5d, 0x29, 0x42, 0x52, 0x2d, 0x4d, 0xe5, 0xf6, 0xfc}, - output256: []byte{0x83, 0x12, 0x0, 0x33, 0xb0, 0x14, 0xf, 0xe3, 0xe3, 0xe1, 0xcb, 0xfe, 0xbf, 0xf3, 0x23, 0xab, 0xc0, 0x85, 0x35, 0xc0, 0xaa, 0x1, 0x78, 0x3, 0xf5, 0xd2, 0xf4, 0xec, 0xb3, 0x5f, 0x5d, 0xfb}, - output384: []byte{0xbc, 0xdd, 0x36, 0xee, 0x35, 0xc2, 0xc7, 0x71, 0x85, 0x2e, 0x27, 0xdb, 0x2c, 0xdd, 0xab, 0xc1, 0x55, 0xab, 0x43, 0xd2, 0x8e, 0x62, 0x89, 0xf0, 0xab, 0xa4, 0xf9, 0x3e, 0x79, 0x3c, 0x99, 0x9f, 0x30, 0x83, 0x6c, 0x74, 0x83, 0xfb, 0xea, 0x5a, 0x73, 0xf4, 0xee, 0xb5, 0xd8, 0xd3, 0x2f, 0xe3}, - output512: []byte{0xfd, 0x9b, 0xe2, 0x47, 0x63, 0xf6, 0x82, 0x4, 0x32, 0x43, 0x52, 0x5e, 0x5e, 0x7, 0x80, 0x53, 0x4a, 0x82, 0xad, 0x5e, 0x83, 0xb6, 0x5e, 0xb4, 0xac, 0xaf, 0x53, 0x53, 0x31, 0x3a, 0x4c, 0xc7, 0xc5, 0xee, 0xa9, 0xda, 0x14, 0x1d, 0xe5, 0x70, 0x23, 0x2c, 0xb4, 0x12, 0x62, 0x87, 0xe5, 0xc7, 0x76, 0x57, 0xca, 0x8d, 0x6a, 0x16, 0xb5, 0xbe, 0x53, 0xf4, 0x70, 0x34, 0x3e, 0x72, 0x2f, 0xd6}}, - testcase{ - msg: []byte{0x4c, 0xfa, 0x12, 0x78, 0x90, 0x30, 0x26, 0xf6, 0x6f, 0xed, 0xd4, 0x13, 0x74, 0x55, 0x8b, 0xe1, 0xb5, 0x85, 0xd0, 0x3c, 0x5c, 0x55, 0xda, 0xc9, 0x43, 0x61, 0xdf, 0x28, 0x6d, 0x4b, 0xd3, 0x9c, 0x7c, 0xb8, 0x3, 0x7e, 0xd3, 0xb2, 0x67, 0xb0, 0x7c, 0x34, 0x66, 0x26, 0x44, 0x9d, 0xc, 0xc5, 0xb0, 0xdd, 0x2c, 0xf2, 0x21, 0xf7, 0xe4, 0xc3, 0x44, 0x9a, 0x4b, 0xe9, 0x99, 0x85, 0xd2, 0xd5, 0xe6, 0x7b, 0xff, 0x29, 0x23, 0x35, 0x7d, 0xde, 0xab, 0x5a, 0xbc, 0xb4, 0x61, 0x9f, 0x3a, 0x3a, 0x57, 0xb2, 0xcf, 0x92, 0x8a, 0x2, 0x2e, 0xb2, 0x76, 0x76, 0xc6, 0xcf, 0x80, 0x56, 0x89, 0x0, 0x4f, 0xca, 0x4d, 0x41, 0xea, 0x6c, 0x2d, 0xa, 0x47, 0x89, 0xc7, 0x60, 0x5f, 0x7b, 0xb8, 0x38, 0xdd, 0x88, 0x3b, 0x3a, 0xd3, 0xe6, 0x2, 0x7e, 0x77, 0x5b, 0xcf, 0x26, 0x28, 0x81, 0x42, 0x80, 0x99, 0xc7, 0xff, 0xf9, 0x5b, 0x14, 0xc0, 0x95, 0xea, 0x13, 0xe, 0xb, 0x99, 0x38, 0xa5, 0xe2, 0x2f, 0xc5, 0x26, 0x50, 0xf5, 0x91}, - output224: []byte{0x53, 0x4, 0x38, 0xb7, 0xa8, 0x6b, 0x16, 0x43, 0x4c, 0x82, 0x71, 0x3e, 0xf7, 0x39, 0x2d, 0x25, 0xc5, 0xcf, 0x81, 0x4c, 0x7c, 0x64, 0x8, 0x36, 0x8c, 0x4f, 0x2e, 0xaf}, - output256: []byte{0x55, 0x84, 0xbf, 0x3e, 0x93, 0xbc, 0x25, 0x94, 0x5c, 0x50, 0x8b, 0x91, 0x88, 0xd0, 0x50, 0x2c, 0x6e, 0x75, 0x5b, 0xbe, 0xba, 0xbf, 0xc8, 0xcb, 0x90, 0x7f, 0xa7, 0xa2, 0x52, 0xef, 0x46, 0x4a}, - output384: []byte{0xfa, 0x7f, 0x66, 0xd3, 0x7c, 0x1d, 0xc3, 0xe8, 0x1b, 0xf5, 0x5c, 0x44, 0x3a, 0xba, 0xd5, 0xcf, 0x79, 0xa3, 0xd9, 0x83, 0x4f, 0x77, 0xa2, 0x6, 0x29, 0x11, 0x38, 0xae, 0x31, 0x43, 0x8b, 0x98, 0x67, 0x37, 0xdc, 0x45, 0x99, 0xec, 0x5d, 0x10, 0xf7, 0xf0, 0x5, 0xd1, 0x83, 0x3b, 0x7d, 0x2e}, - output512: []byte{0x14, 0xea, 0x33, 0xbb, 0x33, 0xfd, 0xf0, 0x42, 0x6e, 0xd, 0xfb, 0x12, 0xde, 0x1c, 0x61, 0x3b, 0xa9, 0x71, 0x41, 0x45, 0x4c, 0x89, 0x71, 0xbc, 0xce, 0x25, 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, 0x29, 0xaf, 0x71, 0x6e, 0x9c, 0x8b, 0xba, 0x48}, - output224: []byte{0x84, 0x94, 0x4e, 0xb0, 0x18, 0xf8, 0xa1, 0x24, 0xe3, 0xc9, 0x69, 0xc0, 0x37, 0x46, 0x4e, 0xe3, 0x2b, 0xac, 0xf8, 0xe5, 0x89, 0x1, 0xd2, 0xe2, 0x22, 0x91, 0xdf, 0x9a}, - output256: []byte{0xc2, 0x34, 0xb2, 0x52, 0xc2, 0x1e, 0xdb, 0x84, 0x26, 0x34, 0xcc, 0x12, 0x4d, 0xa5, 0xbe, 0xe8, 0xa4, 0x74, 0x9c, 0xff, 0xba, 0x13, 0x47, 0x23, 0xf7, 0x96, 0x3b, 0x3a, 0x97, 0x29, 0xc0, 0xb4}, - output384: []byte{0x8f, 0xe, 0x47, 0xed, 0x68, 0x6, 0x61, 0xf1, 0xac, 0xe9, 0xee, 0xee, 0x85, 0x5d, 0x93, 0x5f, 0xdf, 0xc6, 0x6b, 0x97, 0xc2, 0xe9, 0xa6, 0xfc, 0x73, 0x41, 0xf1, 0x4d, 0x93, 0x27, 0xc8, 0xe7, 0x2b, 0xca, 0x3f, 0xa6, 0x7e, 0x59, 0x80, 0x4c, 0xea, 0x41, 0xf0, 0x9e, 0x1c, 0x4f, 0x87, 0x15}, - output512: []byte{0x3b, 0x4b, 0x39, 0x55, 0x14, 0xe0, 0xca, 0xb0, 0x4f, 0xc9, 0xf9, 0xd6, 0xc3, 0x58, 0x0, 0x6c, 0xe0, 0x6c, 0x93, 0x83, 0x1e, 0x89, 0x48, 0xfb, 0x9b, 0xd2, 0xa8, 0x63, 0xf3, 0xfa, 0x6, 0x4e, 0x78, 0xeb, 0x57, 0xc7, 0x6d, 0xd2, 0xd0, 0x58, 0xd0, 0x9a, 0xb3, 0xd1, 0x5, 0xc2, 0x8c, 0x2d, 0xac, 0xae, 0xbd, 0x4a, 0x47, 0x3f, 0x1f, 0xa0, 0x23, 0x5, 0x3c, 0xc1, 0x53, 0x66,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 0xb8}, - output256: []byte{0x64, 0x5f, 0x25, 0x45, 0x67, 0x52, 0x9, 0x1f, 0xff, 0xca, 0xad, 0xe8, 0x6, 0xc3, 0x4c, 0x79, 0xdf, 0xfe, 0x72, 0x14, 0xc, 0x7c, 0x75, 0xd6, 0xa6, 0xec, 0xfe, 0xed, 0xf6, 0xdb, 0x40, 0x1c}, - output384: []byte{0xf1, 0x5, 0x81, 0xe, 0x72, 0x4c, 0x2c, 0x55, 0x16, 0x2c, 0xf7, 0x17, 0x21, 0xe3, 0xf5, 0x98, 0x71, 0xf0, 0x60, 0x10, 0xbc, 0x7f, 0x5, 0x2a, 0xb2, 0x82, 0xbf, 0xb6, 0xd4, 0xa3, 0xbf, 0x18, 0x4b, 0x89, 0x2b, 0xaf, 0x8f, 0xad, 0xd0, 0x20, 0x70, 0xf6, 0x4b, 0x9e, 0x3, 0x6d, 0xc5, 0xf7}, - output512: []byte{0x2d, 0x7d, 0x28, 0xc4, 0x31, 0x1e, 0x4, 0x24, 0xd7, 0x1e, 0x7f, 0x9d, 0x26, 0x7a, 0x2e, 0x4, 0x8a, 0xa1, 0x75, 0x45, 0x5f, 0xcb, 0x72, 0x4c, 0xf0, 0xb1, 0x3d, 0xeb, 0xf4, 0x48, 0xb5, 0x9b, 0xf, 0x28, 0x26, 0x5b, 0xf, 0x1, 0xf, 0x4e, 0x4f, 0x40, 0x65, 0x0, 0x49, 0x4, 0xa7, 0xc2, 0x68, 0x7a, 0x5a, 0x1b, 0x30, 0xab, 0x59, 0x3b, 0xc4, 0x4f, 0x69, 0x8d, 0xff, 0x5d, 0xde, 0x33}}, - testcase{ - msg: []byte{0x6c, 0x4b, 0xa, 0x7, 0x19, 0x57, 0x3e, 0x57, 0x24, 0x86, 0x61, 0xe9, 0x8f, 0xeb, 0xe3, 0x26, 0x57, 0x1f, 0x9a, 0x1c, 0xa8, 0x13, 0xd3, 0x63, 0x85, 0x31, 0xae, 0x28, 0xb4, 0x86, 0xf, 0x23, 0xc3, 0xa3, 0xa8, 0xac, 0x1c, 0x25, 0x0, 0x34, 0xa6, 0x60, 0xe2, 0xd7, 0x1e, 0x16, 0xd3, 0xac, 0xc4, 0xbf, 0x9c, 0xe2, 0x15, 0xc6, 0xf1, 0x5b, 0x1c, 0xf, 0xc7, 0xe7, 0x7d, 0x3d, 0x27, 0x15, 0x7e, 0x66, 0xda, 0x9c, 0xee, 0xc9, 0x25, 0x8f, 0x8f, 0x2b, 0xf9, 0xe0, 0x2b, 0x4a, 0xc9, 0x37, 0x93, 0xdd, 0x6e, 0x29, 0xe3, 0x7, 0xed, 0xe3, 0x69, 0x5a, 0xd, 0xf6, 0x3c, 0xbd, 0xc0, 0xfc, 0x66, 0xfb, 0x77, 0x8, 0x13, 0xeb, 0x14, 0x9c, 0xa2, 0xa9, 0x16, 0x91, 0x1b, 0xee, 0x49, 0x2, 0xc4, 0x7c, 0x78, 0x2, 0xe6, 0x9e, 0x40, 0x5f, 0xe3, 0xc0, 0x4c, 0xeb, 0x55, 0x22, 0x79, 0x2a, 0x55, 0x3, 0xfa, 0x82, 0x9f, 0x70, 0x72, 0x72, 0x22, 0x66, 0x21, 0xf7, 0xc4, 0x88, 0xa7, 0x69, 0x8c, 0xd, 0x69, 0xaa, 0x56, 0x1b, 0xe9, 0xf3, 0x78}, - output224: []byte{0xb5, 0xfd, 0xae, 0xad, 0x7e, 0x68, 0x33, 0x3c, 0xed, 0xb5, 0xd4, 0xad, 0x63, 0x6a, 0xe7, 0x5, 0x9e, 0xb3, 0x13, 0x5, 0xe2, 0xc8, 0x31, 0x78, 0x7f, 0xd5, 0x12, 0x65}, - output256: []byte{0x2d, 0x7c, 0xac, 0x69, 0x7e, 0x74, 0x10, 0xc1, 0xf7, 0x73, 0x5d, 0xd6, 0x91, 0x62, 0x4a, 0x7d, 0x4, 0xfa, 0x51, 0x81, 0x58, 0x58, 0xe8, 0xba, 0x98, 0xb1, 0x9b, 0xd, 0xed, 0x6, 0x38, 0xb5}, - output384: []byte{0xcb, 0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 0xd3, 0xa2, 0x27, 0x8c, 0xae, 0x8a, 0x5f, 0xd6, 0x1c, 0x14, 0x33, 0xf7, 0xd3, 0x50, 0x67, 0x5d, 0xd2, 0x18, 0x3, 0x74, 0x6c, 0xad, 0xca, 0x57, 0x41, 0x30, 0xf0, 0x12, 0x0, 0x2, 0x4c, 0x63, 0x40, 0xab, 0xc, 0xc2, 0xcf, 0x74, 0xf2, 0x23, 0x46, 0x69, 0xf3, 0x4e, 0x90, 0x9, 0xef, 0x2e, 0xb9, 0x48, 0x23, 0xd6, 0x2b, 0x31, 0x40, 0x7f, 0x4b, 0xa4, 0x6f, 0x1a, 0x1e, 0xec, 0x41, 0x64, 0x1e, 0x84, 0xd7, 0x77, 0x27, 0xb5, 0x9e, 0x74, 0x6b, 0x8a, 0x67, 0x1b, 0xef, 0x93, 0x6f, 0x5, 0xbe, 0x82, 0x7, 0x59, 0xfa}, - output224: []byte{0x29, 0x19, 0xfd, 0x6c, 0x37, 0x6a, 0xec, 0x9f, 0x50, 0x28, 0x93, 0xa9, 0x97, 0xb, 0x9a, 0xc6, 0x59, 0x18, 0x55, 0x22, 0x7c, 0xe, 0x13, 0x7b, 0xe0, 0x17, 0x5, 0xac}, - output256: []byte{0xf6, 0x64, 0xf6, 0x26, 0xbc, 0x6b, 0x7a, 0x8c, 0xf0, 0x3b, 0xe4, 0x29, 0x15, 0x5e, 0xe1, 0xf5, 0xcd, 0x6e, 0xcf, 0x14, 0x81, 0x6d, 0xe4, 0x9a, 0x5e, 0x22, 0x99, 0x3, 0xf8, 0x9a, 0x4d, 0xc6}, - output384: []byte{0x44, 0xe4, 0xf7, 0x7c, 0xd, 0x7b, 0xca, 0x6a, 0xd5, 0x7d, 0x33, 0x4f, 0x97, 0x4b, 0xda, 0x8d, 0xe2, 0xe0, 0x8e, 0x10, 0x4f, 0x14, 0xa8, 0x71, 0x32, 0x80, 0xce, 0x73, 0x89, 0x7a, 0x94, 0x5d, 0xc2, 0x3a, 0xd0, 0x58, 0x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, 0x59, 0x20, 0x12, 0x53, 0xf9, 0x48, 0xdd, 0x94, 0x39, 0x5a, 0xba, 0x9e, 0x38, 0x52, 0xbd, 0x1d, 0x60, 0xdd, 0xa7, 0xae, 0x5d, 0xc0, 0x45, 0xb2, 0x83, 0xda, 0x0, 0x6e, 0x1c, 0xba, 0xd8, 0x3c, 0xc1, 0x32, 0x92, 0xa3, 0x15, 0xdb, 0x55, 0x53, 0x30, 0x5c, 0x62, 0x8d, 0xd0, 0x91, 0x14, 0x65, 0x97}, - output224: []byte{0x89, 0x10, 0xe7, 0xab, 0xc3, 0xda, 0xa5, 0x6, 0x97, 0x4e, 0xc1, 0x3e, 0x35, 0xc4, 0x31, 0x33, 0xeb, 0xfa, 0x91, 0xde, 0xec, 0x99, 0xbf, 0xad, 0x49, 0x54, 0x44, 0x7e}, - output256: []byte{0x6, 0x42, 0x5e, 0x83, 0xe4, 0xaf, 0x81, 0x7d, 0x73, 0x5e, 0x99, 0x62, 0xc0, 0xcd, 0xdc, 0xe2, 0xcd, 0x40, 0xa0, 0x87, 0xa6, 0xb0, 0xaf, 0x35, 0x99, 0x71, 0x9e, 0x41, 0x5a, 0xb9, 0xa7, 0x2a}, - output384: []byte{0x69, 0x13, 0x18, 0x4f, 0xae, 0x1e, 0xf9, 0xfa, 0x2d, 0x57, 0xb1, 0xb7, 0xbd, 0x58, 0x6d, 0x51, 0xde, 0x9a, 0x5f, 0x38, 0x70, 0x37, 0x26, 0x6e, 0x7b, 0x4a, 0x83, 0xf4, 0x36, 0x64, 0x98, 0xff, 0x86, 0xc8, 0x99, 0x34, 0xc0, 0x53, 0x32, 0xa7, 0xe6, 0x41, 0x14, 0x9e, 0xf6, 0x27, 0xfa, 0x34}, - output512: []byte{0xce, 0xe3, 0xe6, 0xa, 0x49, 0xf7, 0xca, 0xed, 0x93, 0x87, 0xf3, 0xea, 0x69, 0x95, 0x24, 0xc4, 0xcc, 0xaf, 0xd3, 0x7c, 0x1a, 0x7e, 0x60, 0xd2, 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, 0xb2, 0xd, 0xca, 0x49, 0xac, 0x2d, 0x39, 0x56, 0xd4, 0x73, 0x85, 0xe2}, - output224: []byte{0xf8, 0xb4, 0xa4, 0xa6, 0xfb, 0xb8, 0xc8, 0x43, 0x27, 0x12, 0xb5, 0xb8, 0x15, 0xb3, 0x66, 0x85, 0xc8, 0x66, 0x56, 0xc3, 0xf6, 0x7d, 0x5, 0xbd, 0xbb, 0x44, 0xb4, 0x9a}, - output256: []byte{0xe8, 0xc3, 0x29, 0x14, 0x9b, 0x7, 0x5c, 0x45, 0x9e, 0x11, 0xc8, 0xac, 0x1e, 0x7e, 0x6a, 0xcf, 0xa5, 0x1c, 0xa9, 0x81, 0xc8, 0x9e, 0xc0, 0x76, 0x8e, 0xd7, 0x9d, 0x19, 0xf4, 0xe4, 0x84, 0xfb}, - output384: []byte{0xf0, 0x4f, 0xf5, 0xaa, 0xa6, 0x8f, 0x25, 0x58, 0x58, 0x6d, 0x27, 0x48, 0x58, 0x7d, 0xee, 0x3c, 0xf2, 0x8b, 0xac, 0xab, 0x5b, 0xe5, 0xf8, 0x87, 0xd2, 0x4a, 0x6, 0x83, 0x11, 0xba, 0x2d, 0x9e, 0x9b, 0xc0, 0x20, 0x6c, 0x27, 0x6, 0xb9, 0xc1, 0x9, 0xe7, 0x16, 0x2e, 0x3e, 0xcb, 0x63, 0x46}, - output512: []byte{0xe6, 0xed, 0x6f, 0x6, 0x9, 0x6, 0xd1, 0xa7, 0x72, 0xf4, 0x7e, 0x83, 0x90, 0x75, 0x7, 0xf8, 0x8a, 0x15, 0x1d, 0xe4, 0x1, 0xed, 0x79, 0xac, 0xb5, 0x6b, 0xe5, 0x7c, 0x25, 0x96, 0x79, 0x2d, 0xc0, 0xbc, 0x5a, 0x9d, 0xc1, 0x4, 0x5e, 0x37, 0xc6, 0xa3, 0x1d, 0xa1, 0xc3, 0x62, 0x0, 0x21, 0x4e, 0x4f, 0x56, 0x98, 0xaa, 0x27, 0x54, 0xee, 0xb2, 0xca, 0xec, 0xfc, 0x3, 0xbe, 0xc3, 0x9d}}, - testcase{ - msg: []byte{0xca, 0x76, 0xd3, 0xa1, 0x25, 0x95, 0xa8, 0x17, 0x68, 0x26, 0x17, 0x0, 0x68, 0x48, 0x67, 0x55, 0x47, 0xd3, 0xe8, 0xf5, 0xc, 0x22, 0x10, 0xf9, 0xaf, 0x90, 0x6c, 0xe, 0x7c, 0xe5, 0xb, 0x44, 0x60, 0x18, 0x6f, 0xe7, 0x4, 0x57, 0xa9, 0xe8, 0x79, 0xe7, 0x9f, 0xd4, 0xd1, 0xa6, 0x88, 0xc7, 0xa, 0x34, 0x73, 0x61, 0xc8, 0x47, 0xba, 0xd, 0xd6, 0xaa, 0x52, 0x93, 0x6e, 0xaf, 0x8e, 0x58, 0xa1, 0xbe, 0x2f, 0x5c, 0x1c, 0x70, 0x4e, 0x20, 0x14, 0x6d, 0x36, 0x6a, 0xeb, 0x38, 0x53, 0xbe, 0xd9, 0xde, 0x9b, 0xef, 0xe9, 0x56, 0x9a, 0xc8, 0xaa, 0xea, 0x37, 0xa9, 0xfb, 0x71, 0x39, 0xa1, 0xa1, 0xa7, 0xd5, 0xc7, 0x48, 0x60, 0x5a, 0x8d, 0xef, 0xb2, 0x97, 0x86, 0x9e, 0xbe, 0xdd, 0x71, 0xd6, 0x15, 0xa5, 0xda, 0x23, 0x49, 0x6d, 0x11, 0xe1, 0x1a, 0xbb, 0xb1, 0x26, 0xb2, 0x6, 0xfa, 0xa, 0x77, 0x97, 0xee, 0x7d, 0xe1, 0x17, 0x98, 0x60, 0x12, 0xd0, 0x36, 0x2d, 0xce, 0xf7, 0x75, 0xc2, 0xfe, 0x14, 0x5a, 0xda, 0x6b, 0xda, 0x1c, 0xcb, 0x32, 0x6b, 0xf6, 0x44}, - output224: []byte{0x92, 0x6f, 0xe0, 0x4, 0x4b, 0x12, 0x42, 0x2d, 0x3e, 0x4b, 0xfa, 0x52, 0xc5, 0x92, 0x52, 0xac, 0xc9, 0x1d, 0xbf, 0x9, 0xc4, 0x88, 0xae, 0x9d, 0x31, 0xc7, 0xeb, 0x63}, - output256: []byte{0xc8, 0x67, 0x68, 0xf6, 0xc3, 0x49, 0xeb, 0x32, 0x3b, 0xd8, 0x2d, 0xb1, 0x96, 0x76, 0xe1, 0xb, 0xd8, 0xae, 0x9f, 0x70, 0x57, 0x76, 0x35, 0x56, 0xbb, 0xb6, 0xd0, 0xb6, 0x71, 0xe6, 0xf, 0x2a}, - output384: []byte{0xd4, 0xb8, 0xcf, 0xb2, 0xfe, 0x5b, 0x63, 0xbb, 0x5b, 0xb6, 0x78, 0xb9, 0x8b, 0x46, 0x5a, 0x2d, 0xfd, 0x23, 0xdf, 0xf4, 0x98, 0xe7, 0x78, 0xee, 0x5, 0x35, 0xa5, 0xc0, 0x77, 0x70, 0x5a, 0xa2, 0xca, 0x2f, 0x3, 0x98, 0x32, 0xba, 0xea, 0xf, 0x73, 0x56, 0x9, 0xb3, 0xe4, 0xe1, 0x8c, 0xf7}, - output512: []byte{0x9e, 0xd4, 0xee, 0xe8, 0x7f, 0x56, 0xae, 0x27, 0x41, 0xe8, 0xe4, 0xd6, 0x56, 0x23, 0xe4, 0xd1, 0xfa, 0x3a, 0xa1, 0x11, 0xf6, 0x4a, 0x85, 0xf6, 0x6e, 0x99, 0x9, 0x3b, 0xae, 0xd9, 0x90, 0xfe, 0x1d, 0x78, 0x8d, 0x6a, 0x4b, 0xe1, 0xa7, 0x2a, 0x66, 0x15, 0x28, 0x1e, 0xb4, 0x5e, 0x1b, 0x6f, 0xb6, 0xa, 0xfe, 0xfd, 0xd9, 0x39, 0x87, 0xf7, 0x94, 0x8, 0x4b, 0xda, 0x96, 0x2f, 0xac, 0x7f}}, - testcase{ - msg: []byte{0xf7, 0x6b, 0x85, 0xdc, 0x67, 0x42, 0x10, 0x25, 0xd6, 0x4e, 0x93, 0x9, 0x6d, 0x1d, 0x71, 0x2b, 0x7b, 0xaf, 0x7f, 0xb0, 0x1, 0x71, 0x6f, 0x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 0xe4, 0x25, 0x1e, 0x48, 0xa8, 0x53, 0xea, 0xbd, 0xf8, 0x76, 0x12, 0x77, 0x14}, - output384: []byte{0x25, 0xb7, 0x23, 0x7d, 0xa9, 0xd4, 0xd, 0xe0, 0x47, 0xd4, 0x1a, 0x30, 0xbd, 0x37, 0x15, 0x5c, 0xf, 0x10, 0x8d, 0x72, 0x96, 0xb0, 0x90, 0x79, 0x95, 0x7d, 0x4e, 0xe3, 0x12, 0x24, 0xa4, 0xba, 0x25, 0x6a, 0xf7, 0x56, 0xd1, 0x54, 0x87, 0x89, 0x10, 0xc1, 0x58, 0xe4, 0x91, 0x86, 0x72, 0x8b}, - output512: []byte{0x23, 0x13, 0x9b, 0xdd, 0x84, 0xe9, 0xf4, 0x3a, 0x6c, 0xc6, 0x15, 0xf0, 0xf0, 0x36, 0x19, 0x93, 0x28, 0xd3, 0x98, 0x7, 0xbe, 0xc9, 0xe7, 0x86, 0xd4, 0x25, 0x1b, 0x83, 0xb3, 0x8, 0x0, 0xf9, 0xdb, 0xe8, 0xed, 0xc0, 0xb9, 0x10, 0xfc, 0xd9, 0xd9, 0xf2, 0x4, 0xc2, 0xdd, 0xd4, 0xd3, 0xb9, 0x2b, 0xc2, 0x6a, 0xc, 0xfa, 0xab, 0xe7, 0x64, 0xbf, 0xb9, 0xa, 0x14, 0x44, 0x73, 0x3c, 0xd0}}, - testcase{ - msg: []byte{0x25, 0xb8, 0xc9, 0xc0, 0x32, 0xea, 0x6b, 0xcd, 0x73, 0x3f, 0xfc, 0x87, 0x18, 0xfb, 0xb2, 0xa5, 0x3, 0xa4, 0xea, 0x8f, 0x71, 0xde, 0xa1, 0x17, 0x61, 0x89, 0xf6, 0x94, 0x30, 0x4f, 0xf, 0xf6, 0x8e, 0x86, 0x2a, 0x81, 0x97, 0xb8, 0x39, 0x95, 0x75, 0x49, 0xef, 0x24, 0x3a, 0x52, 0x79, 0xfc, 0x26, 0x46, 0xbd, 0x4c, 0x0, 0x9b, 0x6d, 0x1e, 0xde, 0xbf, 0x24, 0x73, 0x81, 0x97, 0xab, 0xb4, 0xc9, 0x92, 0xf6, 0xb1, 0xdc, 0x9b, 0xa8, 0x91, 0xf5, 0x70, 0x87, 0x9a, 0xcc, 0xd5, 0xa6, 0xb1, 0x86, 0x91, 0xa9, 0x3c, 0x7d, 0xa, 0x8d, 0x38, 0xf9, 0x5b, 0x63, 0x9c, 0x1d, 0xae, 0xb4, 0x8c, 0x4c, 0x2f, 0x15, 0xcc, 0xf5, 0xb9, 0xd5, 0x8, 0xf8, 0x33, 0x3c, 0x32, 0xde, 0x78, 0x78, 0x1b, 0x41, 0x85, 0xf, 0x26, 0x1b, 0x85, 0x5c, 0x4b, 0xeb, 0xcc, 0x12, 0x5a, 0x38, 0xc, 0x54, 0xd5, 0x1, 0xc5, 0xd3, 0xbd, 0x7, 0xe6, 0xb5, 0x21, 0x2, 0x11, 0x60, 0x88, 0xe5, 0x3d, 0x76, 0x58, 0x3b, 0x1, 0x61, 0xe2, 0xa5, 0x8d, 0x7, 0x78, 0xf0, 0x91, 0x20, 0x6a, 0xab, 0xd5, 0xa1}, - output224: []byte{0xeb, 0xfd, 0x79, 0x6b, 0x29, 0xf6, 0x5, 0x99, 0x31, 0x73, 0x2f, 0x98, 0x60, 0x21, 0x85, 0xb6, 0x37, 0x7c, 0x4e, 0x6e, 0x40, 0xbd, 0x26, 0xc8, 0x10, 0xd6, 0xda, 0x96}, - output256: []byte{0x51, 0xd0, 0x8e, 0x0, 0xaa, 0xa2, 0x52, 0x81, 0x2d, 0x87, 0x33, 0x57, 0x10, 0x76, 0x16, 0x5, 0x5b, 0x1b, 0x8c, 0x5f, 0xb2, 0xac, 0x79, 0x17, 0xd0, 0xf9, 0x1, 0xdf, 0xb0, 0x1f, 0xac, 0x47}, - output384: []byte{0xf4, 0x1b, 0x2d, 0x2, 0xd3, 0x21, 0xf4, 0xba, 0x10, 0x6f, 0x93, 0x1e, 0xe2, 0x7d, 0x3f, 0x74, 0xe8, 0xd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0x21, 0xc6, 0x6b, 0xdf, 0x48, 0x64, 0x59, 0xd4, 0x27, 0xf9, 0x86, 0x41, 0xf, 0x88, 0x3a, 0x80, 0xa5, 0xbc, 0xc3, 0x2c, 0x20, 0xf0, 0x47, 0x8b, 0xb9, 0xa9, 0x7a, 0x12, 0x6f, 0xc5, 0xf9, 0x54, 0x51, 0xe4, 0xf, 0x29, 0x2a, 0x46, 0x14, 0x93, 0xd, 0x5, 0x4c, 0x85, 0x1a, 0xcd, 0x1, 0x9c, 0xcf}, - output224: []byte{0x8b, 0x37, 0x50, 0x65, 0x5a, 0xf5, 0xec, 0xa1, 0xc, 0xc4, 0xf2, 0x91, 0x4, 0x35, 0x90, 0xe2, 0xd1, 0x97, 0x59, 0x25, 0x30, 0x47, 0xa4, 0xc1, 0xdb, 0xc8, 0x65, 0x77}, - output256: []byte{0x2b, 0x31, 0xfb, 0xc5, 0x65, 0x11, 0x1, 0x10, 0x1, 0x1a, 0xb2, 0xc8, 0xf6, 0xcc, 0x3d, 0xa8, 0xfb, 0x55, 0xd4, 0x1b, 0x1a, 0xe5, 0xe0, 0x43, 0x10, 0x28, 0x3f, 0x20, 0x7d, 0x39, 0x68, 0x2d}, - output384: []byte{0x32, 0x42, 0x9c, 0xb1, 0xb5, 0xda, 0xd6, 0x63, 0xa0, 0x66, 0x3e, 0x49, 0x3, 0x3d, 0xb2, 0x29, 0x9, 0x45, 0x1, 0x9d, 0xf7, 0xe7, 0x92, 0xcd, 0xff, 0x37, 0x23, 0xee, 0xdb, 0x88, 0xcd, 0x6, 0x3, 0xb3, 0xfa, 0xe0, 0x22, 0x8a, 0x18, 0x4f, 0x8e, 0xff, 0xac, 0x45, 0x11, 0x2f, 0x45, 0x3e}, - output512: []byte{0x6a, 0x7a, 0xdd, 0xb2, 0x8f, 0x4f, 0x2c, 0x23, 0xcf, 0xc, 0x26, 0x45, 0x79, 0xfb, 0xa5, 0xf8, 0x92, 0xe0, 0x10, 0x68, 0x9f, 0x83, 0x7b, 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c5, 0xb2, 0x1b, 0xcf, 0xbf, 0x98, 0xe4, 0xa7, 0x7a, 0xb2, 0xaf, 0x1f, 0x3f, 0xda, 0x32, 0x33, 0xf0, 0x46, 0xd3, 0x8f, 0x1d, 0xc8}, - output224: []byte{0xd3, 0xa5, 0x0, 0x44, 0x77, 0xbb, 0xb2, 0x1c, 0xf7, 0xd0, 0xfc, 0xa8, 0x4e, 0x51, 0xa7, 0xa5, 0x7e, 0x93, 0xfa, 0xe7, 0x22, 0x25, 0x70, 0xc0, 0x1b, 0x0, 0xe8, 0x9a}, - output256: []byte{0x13, 0x51, 0xf5, 0xdb, 0xa4, 0x60, 0x98, 0xb9, 0xa7, 0x73, 0x38, 0x1d, 0x85, 0xd5, 0x2f, 0xad, 0x49, 0x1b, 0x3a, 0x82, 0xaf, 0x91, 0x7, 0xf1, 0x73, 0xdb, 0x81, 0xfb, 0x35, 0xed, 0x91, 0xd2}, - output384: []byte{0xe9, 0x1d, 0xee, 0xbc, 0xd7, 0x2b, 0xa1, 0x2e, 0x22, 0x15, 0x60, 0x2b, 0x48, 0x8d, 0xed, 0x20, 0x3a, 0x1e, 0x21, 0x1d, 0x63, 0x58, 0xca, 0xdc, 0x6f, 0x90, 0x6f, 0xbd, 0x89, 0xca, 0x92, 0x8f, 0x54, 0x12, 0x22, 0xcb, 0xd8, 0xfc, 0x9a, 0x20, 0xb5, 0x73, 0xef, 0x22, 0xfc, 0x17, 0x87, 0x78}, - output512: []byte{0x2c, 0xe, 0xe8, 0xa1, 0x65, 0xbf, 0x88, 0xc4, 0x4c, 0x86, 0x1, 0xc6, 0x37, 0x2e, 0x52, 0x2d, 0xa9, 0xec, 0xf4, 0x25, 0x44, 0xdc, 0xdc, 0x9, 0x86, 0x98, 0xf5, 0xd, 0xf8, 0xe7, 0xe, 0xb7, 0x44, 0xc, 0xab, 0x29, 0x53, 0xbb, 0x49, 0xc, 0xd2, 0xa5, 0xe0, 0x88, 0x7b, 0xee, 0xae, 0x34, 0x82, 0x19, 0x2d, 0xa9, 0x5e, 0x50, 0x98, 0xd3, 0xb3, 0x18, 0xf1, 0x6f, 0xc0, 0x8d, 0x1e, 0x1e}}, - testcase{ - msg: []byte{0xe9, 0x8, 0x47, 0xae, 0x67, 0x97, 0xfb, 0xc0, 0xb6, 0xb3, 0x6d, 0x6e, 0x58, 0x8c, 0xa, 0x74, 0x3d, 0x72, 0x57, 0x88, 0xca, 0x50, 0xb6, 0xd7, 0x92, 0x35, 0x2e, 0xa8, 0x29, 0x4f, 0x5b, 0xa6, 0x54, 0xa1, 0x53, 0x66, 0xb8, 0xe1, 0xb2, 0x88, 0xd8, 0x4f, 0x51, 0x78, 0x24, 0x8, 0x27, 0x97, 0x5a, 0x76, 0x3b, 0xc4, 0x5c, 0x7b, 0x4, 0x30, 0xe8, 0xa5, 0x59, 0xdf, 0x44, 0x88, 0x50, 0x5e, 0x0, 0x9c, 0x63, 0xda, 0x99, 0x4f, 0x14, 0x3, 0xf4, 0x7, 0x95, 0x82, 0x3, 0xce, 0xbb, 0x6e, 0x37, 0xd8, 0x9c, 0x94, 0xa5, 0xea, 0xcf, 0x60, 0x39, 0xa3, 0x27, 0xf6, 0xc4, 0xdb, 0xbc, 0x7a, 0x2a, 0x30, 0x7d, 0x97, 0x6a, 0xa3, 0x9e, 0x41, 0xaf, 0x65, 0x37, 0x24, 0x3f, 0xc2, 0x18, 0xdf, 0xa6, 0xab, 0x4d, 0xd8, 0x17, 0xb6, 0xa3, 0x97, 0xdf, 0x5c, 0xa6, 0x91, 0x7, 0xa9, 0x19, 0x87, 0x99, 0xed, 0x24, 0x86, 0x41, 0xb6, 0x3b, 0x42, 0xcb, 0x4c, 0x29, 0xbf, 0xdd, 0x79, 0x75, 0xac, 0x96, 0xed, 0xfc, 0x27, 0x4a, 0xc5, 0x62, 0xd0, 0x47, 0x4c, 0x60, 0x34, 0x7a, 0x7, 0x8c, 0xe4, 0xc2, 0x5e, 0x88}, - output224: []byte{0x75, 0xb7, 0x7c, 0x36, 0xe3, 0x94, 0x71, 0x1d, 0xfd, 0x35, 0xc1, 0x1a, 0xec, 0x8c, 0x3, 0x3d, 0xcd, 0x7c, 0x18, 0x71, 0x2f, 0x3b, 0x6, 0xd1, 0xfe, 0xdc, 0x10, 0x77}, - output256: []byte{0xdf, 0xfc, 0x70, 0xf, 0x3e, 0x4d, 0x84, 0xd9, 0x13, 0x1c, 0xbb, 0x1f, 0x98, 0xfb, 0x84, 0x3d, 0xba, 0xfc, 0xb2, 0xef, 0x94, 0xa5, 0x2e, 0x89, 0xd2, 0x4, 0xd4, 0x31, 0x45, 0x1a, 0x33, 0x31}, - output384: []byte{0x45, 0x29, 0xa, 0x24, 0x29, 0x1e, 0x81, 0xcc, 0xb8, 0xd7, 0x84, 0xb, 0x6c, 0x48, 0x12, 0xac, 0x98, 0x98, 0x3d, 0x7b, 0xd3, 0xaf, 0xe4, 0x6b, 0x42, 0x72, 0x96, 0xad, 0x63, 0x68, 0x62, 0xb9, 0xe0, 0x3e, 0xcf, 0x60, 0x5b, 0x11, 0x4c, 0xb4, 0x7c, 0x2, 0x7, 0x26, 0x7b, 0xc0, 0x59, 0x58}, - output512: []byte{0xdd, 0xd4, 0xff, 0x11, 0x72, 0x31, 0xec, 0xa0, 0x44, 0x5e, 0xad, 0xa7, 0xc7, 0xf1, 0xd8, 0x46, 0x86, 0x52, 0xd, 0xaa, 0x70, 0xe1, 0x60, 0xc8, 0x7d, 0xbb, 0xb3, 0xfb, 0x32, 0xbb, 0x9e, 0x2f, 0x4c, 0xc5, 0x3d, 0xb5, 0x41, 0x3d, 0x4e, 0x88, 0xde, 0x18, 0xa0, 0x11, 0x85, 0x70, 0x31, 0x8b, 0xd6, 0xd0, 0xe5, 0x26, 0x4d, 0x77, 0x93, 0x39, 0xac, 0x6f, 0x4f, 0x4a, 0x95, 0x54, 0x6a, 0x53}}, - testcase{ - msg: []byte{0xf6, 0xd5, 0xc2, 0xb6, 0xc9, 0x39, 0x54, 0xfc, 0x62, 0x76, 0x2,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byte{0x26, 0x72, 0x6b, 0x52, 0x24, 0x2e, 0xf8, 0xec, 0xf4, 0xc6, 0x6a, 0xed, 0x9c, 0x4b, 0x46, 0xbf, 0x6f, 0x5d, 0x87, 0x4, 0x4a, 0xb, 0x99, 0xd4, 0xe4, 0xaf, 0x47, 0xdc, 0x36, 0xb, 0x9b, 0xe}, - output384: []byte{0xe6, 0xbb, 0x2f, 0xaf, 0x5a, 0xbb, 0x3e, 0xda, 0xff, 0xe9, 0xe4, 0x7f, 0x62, 0x58, 0x64, 0x9, 0xb4, 0x43, 0xe4, 0xc6, 0x98, 0x7, 0xd, 0x61, 0xfc, 0x8, 0x22, 0x61, 0x5, 0x32, 0x70, 0xec, 0xdc, 0x24, 0x84, 0xaa, 0x1, 0x45, 0xc8, 0x51, 0x3, 0x1e, 0x3c, 0x99, 0xde, 0xff, 0x23, 0x89}, - output512: []byte{0xa9, 0x74, 0x4e, 0xfa, 0x42, 0x88, 0x7d, 0xf2, 0x92, 0xfc, 0x9, 0xdf, 0xeb, 0x88, 0x5f, 0x1e, 0x80, 0x18, 0x55, 0xde, 0xd0, 0x9d, 0xc2, 0xf9, 0x7c, 0xbf, 0xcb, 0xd0, 0x19, 0x75, 0x18, 0x78, 0x61, 0x9d, 0xa1, 0xbc, 0x95, 0x73, 0x20, 0x1c, 0x7c, 0xc0, 0x50, 0xe2, 0xaa, 0x1d, 0x45, 0x3e, 0x95, 0x13, 0x66, 0xd8, 0x1c, 0x18, 0x8d, 0x32, 0x9b, 0x3c, 0xb8, 0x61, 0xc1, 0xd7, 0x8f, 0x92}}, - testcase{ - msg: []byte{0xcf, 0x85, 0x62, 0xb1, 0xbe, 0xd8, 0x98, 0x92, 0xd6, 0x7d, 0xda, 0xaf, 0x3d, 0xee, 0xb2, 0x82, 0x46, 0x45, 0x6e, 0x97, 0x23, 0x26, 0xdb, 0xcd, 0xb5, 0xcf, 0x3f, 0xb2, 0x89, 0xac, 0xa0, 0x1e, 0x68, 0xda, 0x5d, 0x59, 0x89, 0x6e, 0x3a, 0x61, 0x65, 0x35, 0x8b, 0x7, 0x1b, 0x30, 0x4d, 0x6a, 0xb3, 0xd0, 0x18, 0x94, 0x4b, 0xe5, 0x4, 0x9d, 0x5e, 0xe, 0x2b, 0xb8, 0x19, 0xac, 0xf6, 0x7a, 0x60, 0x6, 0x11, 0x10, 0x89, 0xe6, 0x76, 0x71, 0x32, 0xd7, 0x2d, 0xd8, 0x5b, 0xed, 0xdc, 0xbb, 0x2d, 0x64, 0x49, 0x6d, 0xb0, 0xcc, 0x92, 0x95, 0x5a, 0xb4, 0xc6, 0x23, 0x4f, 0x1e, 0xea, 0x24, 0xf2, 0xd5, 0x14, 0x83, 0xf2, 0xe2, 0x9, 0xe4, 0x58, 0x9b, 0xf9, 0x51, 0x9f, 0xac, 0x51, 0xb4, 0xd0, 0x61, 0xe8, 0x1, 0x12, 0x5e, 0x60, 0x5f, 0x80, 0x93, 0xbb, 0x69, 0x97, 0xbc, 0x16, 0x3d, 0x55, 0x15, 0x96, 0xfe, 0x4a, 0xb7, 0xcf, 0xae, 0x8f, 0xb9, 0xa9, 0xf, 0x69, 0x80, 0x48, 0xc, 0xe0, 0xc2, 0x29, 0xfd, 0x16, 0x75, 0x40, 0x9b, 0xd7, 0x88, 0x35, 0x4d, 0xaf, 0x31, 0x62, 0x40, 0xcf, 0xe0, 0xaf, 0x93, 0xeb}, - output224: []byte{0x41, 0x85, 0x3c, 0xd5, 0x46, 0x92, 0xdb, 0xd4, 0x78, 0xbb, 0x1e, 0x2d, 0x6c, 0xed, 0xcd, 0xa1, 0xd1, 0x39, 0xc8, 0x38, 0xac, 0x95, 0x6a, 0x37, 0xc8, 0x7f, 0x9, 0x8f}, - output256: []byte{0x25, 0xe5, 0x36, 0x31, 0x5f, 0x8, 0xa4, 0x9, 0x76, 0xad, 0xec, 0xb5, 0x47, 0x56, 0xeb, 0xc0, 0xb2, 0x24, 0xc3, 0x8f, 0xaf, 0x11, 0x50, 0x93, 0x71, 0xb5, 0xa6, 0x92, 0xa5, 0x26, 0x9a, 0xb5}, - output384: []byte{0x79, 0xb7, 0x92, 0xb3, 0x4d, 0xa4, 0x42, 0x5b, 0xb0, 0xb4, 0x21, 0x7a, 0xbe, 0x23, 0xe5, 0xdb, 0xe4, 0xe8, 0x7d, 0x39, 0x40, 0xe2, 0xf7, 0xba, 0x52, 0xca, 0x14, 0x66, 0x18, 0x58, 0xa, 0x62, 0x54, 0x5c, 0x44, 0xb8, 0x1e, 0x6, 0x62, 0xa, 0xf6, 0xe2, 0x73, 0x49, 0x90, 0x73, 0xe3, 0xa8}, - output512: []byte{0x89, 0xca, 0xe4, 0x62, 0x46, 0xef, 0xed, 0xad, 0x11, 0x47, 0xeb, 0x18, 0x68, 0xc2, 0x3a, 0x6b, 0xe5, 0x4f, 0x6b, 0xac, 0x75, 0xf0, 0xc9, 0x8a, 0x9a, 0xef, 0xc6, 0xbf, 0x3c, 0xcb, 0x89, 0xae, 0x1, 0x2f, 0x2e, 0x88, 0xa9, 0xc8, 0x38, 0xb5, 0x5e, 0x57, 0xb2, 0x32, 0xcb, 0x3c, 0x80, 0xbc, 0x3c, 0x2e, 0x9f, 0xb3, 0xfc, 0x97, 0x68, 0xc6, 0x22, 0x6e, 0x93, 0x28, 0x4e, 0x20, 0x8b, 0xf2}}, - testcase{ - msg: []byte{0x2a, 0xce, 0x31, 0xab, 0xb0, 0xa2, 0xe3, 0x26, 0x79, 0x44, 0xd2, 0xf7, 0x5e, 0x15, 0x59, 0x98, 0x5d, 0xb7, 0x35, 0x4c, 0x6e, 0x60, 0x5f, 0x18, 0xdc, 0x84, 0x70, 0x42, 0x3f, 0xca, 0x30, 0xb7, 0x33, 0x1d, 0x9b, 0x33, 0xc4, 0xa4, 0x32, 0x67, 0x83, 0xd1, 0xca, 0xae, 0x1b, 0x4f, 0x7, 0x6, 0xe, 0xff, 0x97, 0x8e, 0x47, 0x46, 0xbf, 0xc, 0x7e, 0x30, 0xcd, 0x61, 0x4, 0xb, 0xd5, 0xec, 0x27, 0x46, 0xb2, 0x98, 0x63, 0xeb, 0x7f, 0x10, 0x3e, 0xbd, 0xa6, 0x14, 0xc4, 0x29, 0x1a, 0x80, 0x5b, 0x6a, 0x4c, 0x82, 0x14, 0x23, 0x5, 0x64, 0xa0, 0x55, 0x7b, 0xc7, 0x10, 0x2e, 0xb, 0xd3, 0xed, 0x23, 0x71, 0x92, 0x52, 0xf7, 0x43, 0x5d, 0x64, 0xd2, 0x10, 0xee, 0x2a, 0xaf, 0xc5, 0x85, 0xbe, 0x90, 0x3f, 0xa4, 0x1e, 0x19, 0x68, 0xc5, 0xf, 0xd5, 0xd5, 0x36, 0x79, 0x26, 0xdf, 0x7a, 0x5, 0xe3, 0xa4, 0x2c, 0xf0, 0x7e, 0x65, 0x6f, 0xf9, 0x2d, 0xe7, 0x3b, 0x3, 0x6c, 0xf8, 0xb1, 0x98, 0x98, 0xc0, 0xcb, 0x34, 0x55, 0x7c, 0xc, 0x12, 0xc2, 0xd8, 0xb8, 0x4e, 0x91, 0x18, 0x1a, 0xf4, 0x67, 0xbc, 0x75, 0xa9, 0xd1}, - output224: []byte{0x1f, 0x27, 0x27, 0xd5, 0x13, 0x2c, 0x45, 0x3b, 0xd3, 0x21, 0xa9, 0xfc, 0x7a, 0xa4, 0x6f, 0xb8, 0xb3, 0x34, 0x1d, 0x90, 0x98, 0x8c, 0x41, 0xde, 0x84, 0x39, 0xd2, 0xf1}, - output256: []byte{0xab, 0x50, 0x45, 0x92, 0xad, 0x71, 0x84, 0xbe, 0x83, 0xcc, 0x65, 0x9e, 0xfb, 0x5d, 0x3d, 0xe8, 0x8b, 0xa0, 0x4b, 0x6, 0xb, 0x45, 0xd1, 0x6a, 0x76, 0xf0, 0x34, 0x8, 0xd, 0xde, 0x56, 0xc6}, - output384: []byte{0x9f, 0xa1, 0xd0, 0xac, 0x7c, 0x37, 0x83, 0x17, 0x31, 0xb7, 0x1c, 0x19, 0xac, 0x9e, 0x81, 0xea, 0x11, 0x50, 0x83, 0xac, 0xe6, 0xd9, 0x43, 0x49, 0xce, 0x89, 0xfd, 0xb7, 0x9b, 0x34, 0x62, 0xa7, 0x49, 0xd7, 0x6f, 0xdc, 0x93, 0x89, 0x2f, 0x2f, 0x16, 0xab, 0xf, 0x7e, 0x18, 0xcd, 0xb7, 0x9c}, - output512: []byte{0xe8, 0xa, 0x63, 0xfa, 0xf2, 0x48, 0xae, 0x76, 0x2d, 0x13, 0x88, 0x7a, 0xfe, 0x8e, 0x19, 0x54, 0xf9, 0x73, 0x27, 0xed, 0xd9, 0x64, 0x1c, 0xe5, 0x63, 0xf4, 0x14, 0x8f, 0x97, 0x96, 0x66, 0x98, 0x27, 0xb3, 0xa1, 0x2b, 0x6, 0xeb, 0xd7, 0x10, 0xd4, 0x17, 0x1b, 0x86, 0xe2, 0x1b, 0xc1, 0x33, 0x60, 0xa5, 0x41, 0x84, 0x53, 0x54, 0xe0, 0xf4, 0x93, 0x4e, 0x6f, 0xbb, 0xd7, 0xac, 0xbf, 0x2d}}, - testcase{ - msg: []byte{0xd, 0x8d, 0x9, 0xae, 0xd1, 0x9f, 0x10, 0x13, 0x96, 0x9c, 0xe5, 0xe7, 0xeb, 0x92, 0xf8, 0x3a, 0x20, 0x9a, 0xe7, 0x6b, 0xe3, 0x1c, 0x75, 0x48, 0x44, 0xea, 0x91, 0x16, 0xce, 0xb3, 0x9a, 0x22, 0xeb, 0xb6, 0x0, 0x30, 0x17, 0xbb, 0xcf, 0x26, 0x55, 0x5f, 0xa6, 0x62, 0x41, 0x85, 0x18, 0x7d, 0xb8, 0xf0, 0xcb, 0x35, 0x64, 0xb8, 0xb1, 0xc0, 0x6b, 0xf6, 0x85, 0xd4, 0x7f, 0x32, 0x86, 0xed, 0xa2, 0xb, 0x83, 0x35, 0x8f, 0x59, 0x9d, 0x20, 0x44, 0xbb, 0xf0, 0x58, 0x3f, 0xab, 0x8d, 0x78, 0xf8, 0x54, 0xfe, 0xa, 0x59, 0x61, 0x83, 0x23, 0xc, 0x5e, 0xf8, 0xe5, 0x44, 0x26, 0x75, 0xe, 0xaf, 0x2c, 0xc4, 0xe2, 0x9d, 0x3b, 0xdd, 0x3, 0x7e, 0x73, 0x4d, 0x86, 0x3c, 0x2b, 0xd9, 0x78, 0x9b, 0x4c, 0x24, 0x30, 0x96, 0x13, 0x8f, 0x76, 0x72, 0xc2, 0x32, 0x31, 0x4e, 0xff, 0xdf, 0xc6, 0x51, 0x34, 0x27, 0xe2, 0xda, 0x76, 0x91, 0x6b, 0x52, 0x48, 0x93, 0x3b, 0xe3, 0x12, 0xeb, 0x5d, 0xde, 0x4c, 0xf7, 0x8, 0x4, 0xfb, 0x25, 0x8a, 0xc5, 0xfb, 0x82, 0xd5, 0x8d, 0x8, 0x17, 0x7a, 0xc6, 0xf4, 0x75, 0x60, 0x17, 0xff, 0xf5}, - output224: []byte{0x5e, 0x74, 0x5f, 0x89, 0x66, 0xd9, 0x1e, 0xee, 0x1, 0x3b, 0x6, 0x12, 0x81, 0xbc, 0x20, 0xc7, 0x9b, 0x3, 0x23, 0x0, 0xa, 0x15, 0xbb, 0xde, 0x7e, 0xd, 0x25, 0xae}, - output256: []byte{0x5d, 0x8e, 0xe1, 0x33, 0xec, 0x44, 0x1a, 0x3d, 0xf5, 0xa, 0x52, 0x68, 0xa8, 0xf3, 0x93, 0xf1, 0x3f, 0x30, 0xf2, 0x3f, 0x22, 0x6a, 0xe3, 0xa1, 0x8e, 0xc3, 0x31, 0x84, 0x44, 0x2, 0xff, 0x54}, - output384: []byte{0x18, 0x7c, 0xdf, 0xdb, 0x37, 0x57, 0xd8, 0x0, 0x10, 0xd1, 0xe5, 0x31, 0x57, 0xa5, 0xcc, 0xb0, 0xfc, 0xc3, 0x49, 0x98, 0xef, 0xc6, 0xbb, 0x3c, 0xe2, 0xe6, 0x7, 0x68, 0xf5, 0xee, 0xaa, 0x59, 0x6, 0x56, 0xb4, 0x9c, 0xe, 0x3, 0x6a, 0x3f, 0x34, 0xc9, 0xef, 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 0x34, 0x2e, 0x99, 0x29, 0x36, 0xe0, 0xf8, 0x8b, 0xfd, 0xe, 0x88, 0x4a, 0xd, 0xdb, 0x67, 0x9d, 0x5, 0x47, 0xcc, 0xde, 0xc6, 0x38, 0x42, 0x85, 0xa4, 0x54, 0x29, 0xd1, 0x15, 0xac, 0x7d, 0x23, 0x5a, 0x71, 0x72, 0x42, 0x2, 0x1d, 0x1d, 0xc3, 0x56, 0x41, 0xf5, 0xf0, 0xa4, 0x8e, 0x84, 0x45, 0xdb, 0xa5, 0x8e, 0x6c, 0xb2, 0xc8, 0xea}, - output224: []byte{0xcd, 0x2e, 0xeb, 0x7d, 0x48, 0xd0, 0x26, 0x9, 0x86, 0xba, 0xdf, 0x16, 0xf1, 0x5a, 0xa0, 0x9b, 0x52, 0x29, 0xb7, 0x83, 0xc, 0x73, 0xee, 0x95, 0xb8, 0xcb, 0xf8, 0x5a}, - output256: []byte{0x71, 0x2b, 0x1c, 0xc0, 0x4c, 0x0, 0x9b, 0x52, 0x3, 0x5c, 0xc4, 0x4c, 0x95, 0x5, 0xbb, 0x5c, 0xb5, 0x77, 0xba, 0xa, 0xd1, 0x73, 0x4e, 0xc2, 0x36, 0x20, 0xf5, 0x7e, 0xef, 0x3d, 0x37, 0xfb}, - output384: []byte{0x70, 0x43, 0xf5, 0x4f, 0x39, 0xb, 0x6a, 0xbd, 0xd, 0xff, 0x6, 0xf2, 0x66, 0xe0, 0xe7, 0xb3, 0xe4, 0x1f, 0x8d, 0x2e, 0x8d, 0xd4, 0x3f, 0x89, 0x9a, 0xc4, 0x56, 0x66, 0x24, 0x47, 0xa8, 0x23, 0xa5, 0x67, 0xb1, 0xb0, 0xfb, 0x8c, 0x2d, 0xf2, 0x4e, 0x5f, 0x66, 0x89, 0x6, 0xc, 0xdd, 0xb4}, - output512: []byte{0xd1, 0xca, 0xb5, 0x97, 0x9e, 0xb7, 0xf5, 0x3c, 0x97, 0xdc, 0xa5, 0xd7, 0x25, 0xd8, 0xb3, 0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x50, 0xeb, 0xcb, 0x46, 0x59, 0x5d, 0x42, 0x66, 0xa0, 0xbd, 0x7f, 0x65, 0x1b, 0xa4, 0x7d, 0xc, 0x7f, 0x17, 0x9c, 0xa2, 0x85, 0x45, 0x0, 0x7d, 0x92, 0xe8, 0x41, 0x9d, 0x48, 0xfd, 0xfb, 0xd7, 0x44, 0xce}, - output224: []byte{0x33, 0x22, 0xfa, 0x72, 0x7a, 0x0, 0x89, 0xf5, 0x0, 0xa6, 0xa9, 0x9d, 0x67, 0x41, 0x9a, 0x76, 0xc7, 0xaf, 0x77, 0xef, 0x28, 0x93, 0xe8, 0xd3, 0x85, 0xb4, 0x27, 0x20}, - output256: []byte{0x94, 0x2e, 0x39, 0xe2, 0x30, 0xa2, 0x25, 0x1f, 0xfd, 0xb2, 0xf8, 0x52, 0x2, 0x87, 0x1c, 0x98, 0x59, 0x70, 0x8, 0x40, 0x1b, 0x32, 0x2f, 0xf9, 0x84, 0xc, 0xc9, 0xc, 0xc8, 0x5b, 0x33, 0x7d}, - output384: []byte{0xd0, 0xce, 0x2, 0x59, 0xaa, 0xee, 0xa5, 0xba, 0xef, 0xf5, 0x29, 0x29, 0x42, 0x3c, 0x3d, 0xa0, 0x7a, 0x8c, 0x75, 0x19, 0x5f, 0x86, 0xd7, 0x33, 0xa7, 0x18, 0xd1, 0xc4, 0x6a, 0x1e, 0x40, 0xaa, 0xd4, 0x4, 0x75, 0xc, 0x41, 0xd7, 0xa1, 0x58, 0xe7, 0x9f, 0x27, 0x88, 0x30, 0xb4, 0xc0, 0x7a}, - output512: []byte{0x96, 0xad, 0x16, 0x38, 0x69, 0xae, 0x2f, 0xfd, 0xb8, 0x9b, 0x96, 0xf4, 0xdc, 0x70, 0xe, 0xce, 0x27, 0xd1, 0xf4, 0xda, 0xaf, 0xbc, 0x5f, 0xb8, 0x1a, 0x8e, 0x95, 0x13, 0xc6, 0xea, 0x5e, 0x2b, 0x6a, 0x8b, 0xcc, 0xf4, 0xe4, 0x9a, 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f, 0x94, 0xba, 0xab, 0x7f, 0x35, 0x9d, 0x5d, 0x1e, 0xea, 0x10, 0x5f, 0x28, 0xdc, 0xfb}, - output224: []byte{0x23, 0x4c, 0x1b, 0xc0, 0x3f, 0xd4, 0xc3, 0xd3, 0x8d, 0xd4, 0xc7, 0x36, 0xb5, 0x9a, 0x91, 0x7, 0x91, 0x12, 0x10, 0xd5, 0x4e, 0x98, 0xb3, 0xa3, 0x72, 0xf5, 0x72, 0x36}, - output256: []byte{0xb5, 0x42, 0xb6, 0xcd, 0x8e, 0xf2, 0xda, 0xb4, 0xed, 0x83, 0xb7, 0x7a, 0xc6, 0xdc, 0x52, 0xda, 0xf5, 0x54, 0xec, 0xda, 0x4e, 0xf7, 0xab, 0xa, 0x50, 0xe5, 0x46, 0xbe, 0xbe, 0x2d, 0x8e, 0x5a}, - output384: []byte{0xe4, 0x38, 0x5a, 0x3b, 0xe0, 0x11, 0xaf, 0x20, 0xfe, 0x45, 0x66, 0xc1, 0xce, 0xbf, 0x4a, 0xa6, 0x82, 0x70, 0xe4, 0x2b, 0xe5, 0xa, 0xaa, 0xae, 0x65, 0xf8, 0xf6, 0x5, 0xe9, 0x80, 0xb1, 0xd2, 0x73, 0x6f, 0xb0, 0xe7, 0x94, 0x33, 0xd, 0x76, 0x4c, 0xa9, 0x6b, 0xc6, 0x8b, 0x83, 0x60, 0xbc}, - output512: []byte{0xfd, 0x2e, 0x7a, 0x6e, 0x11, 0xe5, 0xd0, 0x2, 0x78, 0x9, 0x9e, 0xaf, 0x40, 0x30, 0x54, 0xd6, 0x17, 0xac, 0xac, 0x5b, 0xd3, 0xd0, 0xa4, 0x90, 0x81, 0x91, 0x78, 0x2c, 0x89, 0xf9, 0x21, 0x7a, 0x3f, 0x1, 0x18, 0xbc, 0x2b, 0x28, 0x4f, 0xdb, 0xce, 0x80, 0x3f, 0x66, 0xb7, 0x8d, 0xd7, 0x95, 0xeb, 0x18, 0xdc, 0x16, 0xba, 0x85, 0xe1, 0x9c,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 0x9f, 0x40, 0x17, 0xe1, 0x67, 0x4d, 0x4c, 0xb8, 0x7b, 0x70, 0xd3, 0xd7, 0x77, 0xc7, 0x11, 0x4f, 0x8, 0x5d, 0x77, 0x21, 0x64, 0x37, 0xb8, 0x60, 0xd6, 0x41}, - output256: []byte{0xf7, 0xe9, 0xe8, 0x25, 0x72, 0x2e, 0x65, 0x54, 0xa8, 0x61, 0x9c, 0xca, 0x3e, 0x57, 0xf5, 0xb5, 0xe6, 0xb7, 0x34, 0x74, 0x31, 0xd5, 0x5c, 0xe1, 0x78, 0x37, 0x2c, 0x91, 0x7b, 0xfb, 0x3d, 0xc2}, - output384: []byte{0xc9, 0x79, 0xf0, 0x6, 0x56, 0xa0, 0x9e, 0x68, 0x48, 0x5c, 0xcf, 0x7, 0xfb, 0xbb, 0x91, 0x8, 0xb0, 0xc, 0x5f, 0xc1, 0x1d, 0x41, 0xf5, 0x96, 0x6f, 0xf0, 0x86, 0xf2, 0x6c, 0x71, 0x2, 0x47, 0x8e, 0xc1, 0x77, 0xee, 0x6d, 0x78, 0xc6, 0x23, 0xc3, 0x75, 0xa9, 0xe6, 0xf7, 0x61, 0x80, 0x9a}, - output512: []byte{0xae, 0x53, 0x77, 0x6d, 0x96, 0x9a, 0x9b, 0x28, 0x56, 0x41, 0x99, 0x8a, 0x9f, 0x2c, 0x70, 0xca, 0x71, 0x85, 0x6c, 0x95, 0x6a, 0x3c, 0x43, 0xa, 0x32, 0xa1, 0xe0, 0x3a, 0x8e, 0x8, 0xd5, 0x44, 0xf1, 0x65, 0x11, 0xa2, 0x7c, 0xfa, 0x59, 0xf6, 0xb8, 0x27, 0x5a, 0x23, 0x57, 0xf8, 0xef, 0xa6, 0x54, 0x4b, 0x1c, 0xd0, 0xc0, 0xa, 0x94, 0x60, 0xf4, 0x79, 0x54, 0xa1, 0x46, 0x42, 0x9e, 0x49}}, - testcase{ - msg: []byte{0xb1, 0xc, 0x59, 0x72, 0x3e, 0x3d, 0xca, 0xdd, 0x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0xe5, 0x4c, 0x2f, 0x80, 0xf6, 0xd3, 0x14, 0xab, 0x5a}, - output256: []byte{0x14, 0xbb, 0x22, 0xb9, 0x8e, 0xaf, 0x41, 0xa4, 0xc2, 0x24, 0xfd, 0x3c, 0x37, 0x18, 0x8a, 0x75, 0x5f, 0x9b, 0x4, 0xf4, 0x6f, 0x3e, 0x23, 0xa6, 0x52, 0xda, 0x3d, 0xb9, 0xe2, 0x5d, 0x2f, 0x2c}, - output384: []byte{0x36, 0x13, 0x93, 0x36, 0x11, 0xd, 0x1d, 0x6c, 0x27, 0xe4, 0xcc, 0x1f, 0x26, 0xf4, 0x28, 0xeb, 0x8b, 0xdb, 0xcb, 0xa3, 0xaa, 0x9f, 0xfd, 0xce, 0xcf, 0x72, 0x0, 0x9f, 0xb4, 0x6b, 0xfa, 0xf9, 0xe3, 0x46, 0x4c, 0x48, 0xbe, 0xfa, 0x47, 0x45, 0xbe, 0x36, 0xc6, 0x97, 0xdd, 0x3b, 0xed, 0x8b}, - output512: []byte{0xd4, 0x74, 0x8c, 0x8e, 0x17, 0xf4, 0x11, 0x7b, 0xf2, 0xbf, 0x71, 0x55, 0x7a, 0xbb, 0x55, 0x92, 0x47, 0x55, 0x21, 0x26, 0xc3, 0x61, 0x92, 0xc5, 0xdf, 0x5c, 0x6c, 0x3e, 0x30, 0x7d, 0x87, 0x9b, 0x70, 0x3c, 0x3f, 0xcd, 0x70, 0x99, 0xdd, 0xab, 0x24, 0x3e, 0x2f, 0x1d, 0x5a, 0xe5, 0x6, 0x69, 0x90, 0xa7, 0xb3, 0x8d, 0x3f, 0x2c, 0xd7, 0xfb, 0x11, 0x5a, 0xa6, 0xd1, 0x35, 0xe7, 0x26, 0x1d}}, - testcase{ - msg: []byte{0xdb, 0x11, 0xf6, 0x9, 0xba, 0xba, 0x7b, 0xc, 0xa6, 0x34, 0x92, 0x6b, 0x1d, 0xd5, 0x39, 0xc8, 0xcb, 0xad, 0xa2, 0x49, 0x67, 0xd7, 0xad, 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9, 0x94, 0x1c, 0x6, 0xe5, 0xe3, 0x8e, 0xa0, 0x1b, 0x7f, 0xa9, 0x80, 0x63, 0x8b, 0x95, 0x36, 0xca, 0x19, 0x39, 0x95, 0xc, 0x16, 0x29, 0xf8, 0x4a, 0x6e, 0xff, 0x38, 0x66}, - output384: []byte{0xce, 0x32, 0x68, 0xb8, 0xec, 0x92, 0x3b, 0x33, 0x31, 0xea, 0x2c, 0xf8, 0x51, 0x32, 0xc0, 0x73, 0x3c, 0xf8, 0xbf, 0x87, 0xda, 0xa5, 0x44, 0xf8, 0xee, 0x38, 0x6d, 0x5d, 0xe9, 0xfb, 0xd4, 0xd8, 0xad, 0x94, 0xe0, 0xb, 0x70, 0x5c, 0xa5, 0xb6, 0x1a, 0x3c, 0x17, 0x90, 0xb6, 0x50, 0x8, 0xc}, - output512: []byte{0xd8, 0xff, 0x4, 0x81, 0xa6, 0x38, 0x90, 0xf0, 0xe5, 0xa5, 0x36, 0xeb, 0xba, 0x2f, 0x25, 0x3f, 0xa2, 0xcf, 0xa1, 0x9c, 0xf, 0x35, 0x35, 0x87, 0xaf, 0x4b, 0xdc, 0x31, 0x90, 0xe4, 0xf8, 0xf5, 0x4d, 0x17, 0xd6, 0x65, 0xe8, 0xb2, 0x1, 0x11, 0x21, 0xd4, 0x44, 0xbf, 0xad, 0xff, 0xf3, 0xe1, 0x92, 0xd9, 0x7f, 0xa0, 0x3b, 0x84, 0x9d, 0x63, 0xf3, 0x6d, 0xb2, 0xf, 0x4c, 0xf8, 0x8a, 0x74}}, - testcase{ - msg: []byte{0xbe, 0xbd, 0x4f, 0x1a, 0x84, 0xfc, 0x8b, 0x15, 0xe4, 0x45, 0x2a, 0x54, 0xbd, 0x2, 0xd6, 0x9e, 0x30, 0x4b, 0x7f, 0x32, 0x61, 0x6a, 0xad, 0xd9, 0x5, 0x37, 0x93, 0x71, 0x6, 0xae, 0x4e, 0x28, 0xde, 0x9d, 0x8a, 0xab, 0x2, 0xd1, 0x9b, 0xc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0, 0xb7, 0x18, 0xe2, 0x76, 0xbb, 0xbd, 0xb7, 0x3a, 0xf9, 0x8b, 0xe3, 0x5f}, - output384: []byte{0xdd, 0xc3, 0x98, 0x87, 0x9b, 0xd1, 0x6f, 0xb6, 0x81, 0xfa, 0xe1, 0x51, 0x2e, 0x3a, 0x1a, 0xe7, 0xed, 0x23, 0x62, 0xda, 0xd8, 0xbe, 0xe0, 0xd1, 0x2d, 0x22, 0x56, 0xb2, 0xd8, 0x56, 0x28, 0x20, 0x43, 0xdc, 0xc, 0xbb, 0xc0, 0xf6, 0x31, 0x97, 0xb7, 0x5e, 0x99, 0x82, 0xa1, 0xda, 0xa8, 0xae}, - output512: []byte{0x52, 0xd7, 0x71, 0xb5, 0x1, 0x6c, 0x6b, 0x1b, 0x93, 0xd3, 0xbf, 0x6a, 0x13, 0xf7, 0x18, 0xa7, 0xb4, 0x74, 0x1d, 0x52, 0x87, 0x98, 0x60, 0x93, 0x8, 0xb5, 0x4c, 0xea, 0x60, 0x37, 0x86, 0x2d, 0x92, 0x37, 0x51, 0xfd, 0xdc, 0xe1, 0x5, 0x80, 0xa7, 0xd6, 0x43, 0x1b, 0xf2, 0x8, 0xdf, 0x17, 0xc1, 0xb8, 0x25, 0xf7, 0xc7, 0x40, 0x1c, 0xcb, 0xd6, 0xd8, 0x6, 0xb7, 0x44, 0x24, 0x1a, 0xcf}}, - testcase{ - msg: []byte{0x5a, 0xca, 0x56, 0xa0, 0x3a, 0x13, 0x78, 0x4b, 0xdc, 0x32, 0x89, 0xd9, 0x36, 0x4f, 0x79, 0xe2, 0xa8, 0x5c, 0x12, 0x27, 0x6b, 0x49, 0xb9, 0x2d, 0xb0, 0xad, 0xaa, 0x4f, 0x20, 0x6d, 0x50, 0x28, 0xf2, 0x13, 0xf6, 0x78, 0xc3, 0x51, 0xe, 0x11, 0x1f, 0x9d, 0xc4, 0xc1, 0xc1, 0xf8, 0xb6, 0xac, 0xb1, 0x7a, 0x64, 0x13, 0xaa, 0x22, 0x76, 0x7, 0xc5, 0x15, 0xc6, 0x2a, 0x73, 0x38, 0x17, 0xba, 0x5e, 0x76, 0x2c, 0xc6, 0x74, 0x8e, 0x7e, 0xd, 0x68, 0x72, 0xc9, 0x84, 0xd7, 0x23, 0xc9, 0xbb, 0x3b, 0x11, 0x7e, 0xb8, 0x96, 0x31, 0x85, 0x30, 0xa, 0x80, 0xbf, 0xa6, 0x5c, 0xde, 0x49, 0x5d, 0x70, 0xa4, 0x6c, 0x44, 0x85, 0x86, 0x5, 0xfc, 0xcb, 0xed, 0x8, 0x6c, 0x2b, 0x45, 0xce, 0xf9, 0x63, 0xd3, 0x32, 0x94, 0xdb, 0xe9, 0x70, 0x6b, 0x13, 0xaf, 0x22, 0xf1, 0xb7, 0xc4, 0xcd, 0x5a, 0x0, 0x1c, 0xfe, 0xc2, 0x51, 0xfb, 0xa1, 0x8e, 0x72, 0x2c, 0x6e, 0x1c, 0x4b, 0x11, 0x66, 0x91, 0x8b, 0x4f, 0x6f, 0x48, 0xa9, 0x8b, 0x64, 0xb3, 0xc0, 0x7f, 0xc8, 0x6a, 0x6b, 0x17, 0xa6, 0xd0, 0x48, 0xa, 0xb7, 0x9d, 0x4e, 0x64, 0x15, 0xb5, 0x20, 0xf1, 0xc4, 0x84, 0xd6, 0x75, 0xb1}, - output224: []byte{0xd2, 0x74, 0x4a, 0x1b, 0xbb, 0x34, 0x71, 0x8f, 0xcb, 0xb6, 0x14, 0xc2, 0x1e, 0x1f, 0xcc, 0xd0, 0xff, 0x88, 0x61, 0x5c, 0xb8, 0x2a, 0xa0, 0x38, 0x3, 0xab, 0x94, 0x60}, - output256: []byte{0x2, 0x84, 0x41, 0x8c, 0x10, 0x19, 0xf, 0x41, 0x30, 0x42, 0xe3, 0xec, 0xeb, 0x39, 0x54, 0x97, 0x9b, 0x94, 0xaf, 0xbf, 0x2e, 0x54, 0x5f, 0xc7, 0xf8, 0xa3, 0xc7, 0xdb, 0x2c, 0x23, 0x59, 0x16}, - output384: []byte{0x35, 0xb, 0x4b, 0x27, 0x68, 0x2, 0xe, 0xaa, 0x95, 0x45, 0x2b, 0x90, 0x41, 0x44, 0x39, 0xa3, 0x8b, 0xe0, 0x36, 0x86, 0x13, 0x1d, 0x45, 0x61, 0x2c, 0x1b, 0x85, 0xfe, 0x6, 0xfd, 0x91, 0x96, 0xf2, 0x7d, 0x22, 0x1f, 0x4f, 0xf8, 0x32, 0x51, 0xaa, 0x8e, 0x69, 0xae, 0xf7, 0x2f, 0x90, 0x4d}, - output512: []byte{0x36, 0xd4, 0x72, 0xa8, 0xae, 0x13, 0xd1, 0xe7, 0xe, 0x1f, 0xd2, 0x75, 0x11, 0x7f, 0xfe, 0x34, 0x6, 0x3b, 0xef, 0xcc, 0xf6, 0x70, 0x6f, 0xab, 0x8, 0x16, 0xe1, 0xb8, 0x1f, 0x7f, 0xe7, 0xf2, 0xdd, 0xb2, 0xa1, 0x22, 0xf1, 0xf5, 0x2c, 0x99, 0x50, 0x64, 0x46, 0x59, 0x43, 0xf, 0x81, 0xbc, 0xed, 0xad, 0x5d, 0x83, 0x3d, 0xf4, 0x81, 0x4c, 0xf6, 0xa, 0xe6, 0xc5, 0x42, 0xcc, 0x44, 0x78}}, - testcase{ - msg: []byte{0xa5, 0xaa, 0xd0, 0xe4, 0x64, 0x6a, 0x32, 0xc8, 0x5c, 0xfc, 0xac, 0x73, 0xf0, 0x2f, 0xc5, 0x30, 0xf, 0x19, 0x82, 0xfa, 0xbb, 0x2f, 0x21, 0x79, 0xe2, 0x83, 0x3, 0xe4, 0x47, 0x85, 0x40, 0x94, 0xcd, 0xfc, 0x85, 0x43, 0x10, 0xe5, 0xc0, 0xf6, 0x9, 0x93, 0xce, 0xff, 0x54, 0xd8, 0x4d, 0x6b, 0x46, 0x32, 0x3d, 0x93, 0xa, 0xdb, 0x7, 0xc1, 0x75, 0x99, 0xb3, 0x5b, 0x50, 0x5f, 0x9, 0xe7, 0x84, 0xbc, 0xa5, 0x98, 0x5e, 0x1, 0x72, 0x25, 0x77, 0x97, 0xfb, 0x53, 0x64, 0x9e, 0x2e, 0x97, 0x23, 0xef, 0xd1, 0x68, 0x65, 0xc3, 0x1b, 0x5c, 0x3d, 0x51, 0x13, 0xb5, 0x8b, 0xb0, 0xbf, 0xc8, 0x92, 0xf, 0xab, 0xdd, 0xa0, 0x86, 0xd7, 0x53, 0x7e, 0x66, 0xd7, 0x9, 0xd0, 0x50, 0xbd, 0x14, 0xd0, 0xc9, 0x60, 0x87, 0x3f, 0x15, 0x6f, 0xad, 0x5b, 0x3d, 0x38, 0x40, 0xcd, 0xfc, 0xdc, 0x9b, 0xe6, 0xaf, 0x51, 0x9d, 0xb2, 0x62, 0xa2, 0x7f, 0x40, 0x89, 0x6a, 0xb2, 0x5c, 0xc3, 0x9f, 0x96, 0x98, 0x4d, 0x65, 0x6, 0x11, 0xc0, 0xd5, 0xa3, 0x8, 0xd, 0x5b, 0x3a, 0x1b, 0xf1, 0x86, 0xab, 0xd4, 0x29, 0x56, 0x58, 0x8b, 0x3b, 0x58, 0xcd, 0x94, 0x89, 0x70, 0xd2, 0x98, 0x77, 0x60, 0x60}, - output224: []byte{0xf6, 0x11, 0x5f, 0x63, 0x5d, 0x98, 0xb5, 0x72, 0xfd, 0x1b, 0xa8, 0x57, 0x63, 0xec, 0xcf, 0x8b, 0xf2, 0x73, 0xfb, 0xf7, 0xb9, 0x6f, 0xd, 0xb0, 0x12, 0xc, 0xa8, 0xad}, - output256: []byte{0x8f, 0xeb, 0xff, 0x80, 0x17, 0x87, 0xf5, 0x80, 0x3e, 0x15, 0x1d, 0xca, 0x34, 0x34, 0xa5, 0xcd, 0x44, 0xad, 0xb4, 0x9f, 0x1c, 0x2f, 0xfd, 0x5d, 0xc, 0xd0, 0x77, 0xa9, 0x7, 0x5a, 0x49, 0x2d}, - output384: []byte{0x4c, 0xd1, 0x36, 0x71, 0x12, 0xc4, 0xf, 0xb7, 0xe3, 0x91, 0x9d, 0xf2, 0x6, 0x97, 0xa4, 0xe1, 0xcd, 0xc5, 0x5f, 0xd0, 0xf0, 0x1b, 0xe3, 0x95, 0x3b, 0x19, 0x98, 0xb5, 0xfc, 0xb4, 0x73, 0xe7, 0x6e, 0x9e, 0x75, 0xd5, 0xd8, 0x2e, 0x29, 0x73, 0xb3, 0xdb, 0x89, 0x53, 0x85, 0x54, 0x93, 0x3b}, - output512: []byte{0xe5, 0x4, 0xad, 0x7f, 0x33, 0xd6, 0x5b, 0x8d, 0x34, 0x87, 0xb2, 0x88, 0x5, 0xd4, 0x78, 0x77, 0x8c, 0x90, 0x1c, 0xa, 0xff, 0x5f, 0x88, 0x9a, 0xe9, 0x5e, 0x29, 0x19, 0xb4, 0xf4, 0x31, 0xa8, 0x1, 0x16, 0xa8, 0x99, 0x34, 0x69, 0xe8, 0x22, 0x89, 0x5f, 0x3c, 0x21, 0xa4, 0x1d, 0x67, 0xaf, 0xda, 0x93, 0xa5, 0xb2, 0x9b, 0x62, 0x50, 0xf7, 0x63, 0x35, 0xa7, 0x6f, 0xe8, 0x91, 0x92, 0x74}}, - testcase{ - msg: []byte{0x6, 0xcb, 0xbe, 0x67, 0xe9, 0x4a, 0x97, 0x82, 0x3, 0xea, 0xd6, 0xc0, 0x57, 0xa1, 0xa5, 0xb0, 0x98, 0x47, 0x8b, 0x4b, 0x4c, 0xbe, 0xf5, 0xa9, 0x7e, 0x93, 0xc8, 0xe4, 0x2f, 0x55, 0x72, 0x71, 0x35, 0x75, 0xfc, 0x2a, 0x88, 0x45, 0x31, 0xd7, 0x62, 0x2f, 0x8f, 0x87, 0x93, 0x87, 0xa8, 0x59, 0xa8, 0xf, 0x10, 0xef, 0x2, 0x70, 0x8c, 0xd8, 0xf7, 0x41, 0x3a, 0xb3, 0x85, 0xaf, 0xc3, 0x57, 0x67, 0x8b, 0x95, 0x78, 0xc0, 0xeb, 0xf6, 0x41, 0xef, 0x7, 0x6a, 0x1a, 0x30, 0xf1, 0xf7, 0x53, 0x79, 0xe9, 0xdc, 0xb2, 0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, 0x6, 0xa, 0x16, 0x2e, 0xcc, 0xa8, 0xc3, 0x8c, 0x1a, 0x88, 0x35, 0xb, 0xd6, 0x3b, 0xb5, 0x39, 0x13, 0x4f, 0x70, 0xf, 0xd4, 0xad, 0xdd, 0x59, 0x59, 0xe2, 0x55, 0x33, 0x7d, 0xaa, 0x6, 0xbc, 0x86, 0x35, 0x8f, 0xab, 0xcb, 0xef, 0xdf, 0xb5, 0xbc, 0x88, 0x97, 0x83, 0xd8, 0x43, 0xc0, 0x8a, 0xad, 0xc6, 0xc4, 0xf6, 0xc3, 0x6f, 0x65, 0xf1, 0x56, 0xe8, 0x51, 0xc9, 0xa0, 0xf9, 0x17, 0xe4, 0xa3, 0x67, 0xb5, 0xad, 0x93, 0xd8, 0x74, 0x81, 0x2a, 0x1d, 0xe6, 0xa7, 0xb9, 0x3c, 0xd5, 0x3a, 0xd9, 0x72, 0x32}, - output224: []byte{0x44, 0xbc, 0x64, 0x55, 0x9b, 0xdb, 0x91, 0xb, 0x70, 0x79, 0xe0, 0x26, 0x1f, 0xf8, 0xb4, 0x9d, 0xba, 0x14, 0x1b, 0x32, 0xec, 0xbc, 0xb7, 0xb, 0x3a, 0xbd, 0xfb, 0xf9}, - output256: []byte{0xba, 0xae, 0xcb, 0x6e, 0x9d, 0xb5, 0x79, 0x71, 0xd5, 0xc7, 0xf, 0x58, 0x19, 0xff, 0x89, 0xc5, 0x9, 0x32, 0x54, 0xde, 0x19, 0xef, 0x60, 0x59, 0xc4, 0x3c, 0xc0, 0xaf, 0xda, 0x7c, 0x5d, 0x34}, - output384: []byte{0x60, 0x7, 0x1a, 0x7e, 0x2e, 0xcf, 0xaf, 0x3b, 0x5b, 0x2e, 0x84, 0xa6, 0x77, 0xfb, 0x98, 0xe4, 0x4b, 0xd3, 0x72, 0x5a, 0xdd, 0xee, 0xc5, 0xc3, 0x7e, 0xc6, 0x20, 0x52, 0xd5, 0x7a, 0xf7, 0xb6, 0x87, 0xa0, 0x63, 0xfd, 0x39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, 0xed, 0x2f, 0x43, 0x7d, 0xd1, 0x3b, 0x2e, 0xc1, 0x4, 0x2a, 0xfc, 0xf9, 0xde, 0xcd, 0xc3, 0xe8, 0x77, 0xe5, 0xf, 0xf4, 0x10, 0x6a, 0xd1, 0xa, 0x52, 0x52, 0x30, 0xd1, 0x19, 0x20, 0x32, 0x4a, 0x81, 0x9, 0x4d, 0xa3, 0x1d, 0xea, 0xb6, 0x47, 0x6a, 0xa4, 0x2f, 0x20, 0xc8, 0x48, 0x43, 0xcf, 0xc1, 0xc5, 0x85, 0x45, 0xee, 0x80, 0x35, 0x2b, 0xdd, 0x37, 0x40, 0xdd, 0x6a, 0x16, 0x79, 0x2a, 0xe2, 0xd8, 0x6f, 0x11, 0x64, 0x1b, 0xb7, 0x17, 0xc2}, - output224: []byte{0xde, 0x82, 0xad, 0xde, 0x82, 0x3c, 0x31, 0x2f, 0x83, 0xb3, 0xd4, 0xc0, 0xbd, 0x35, 0xaa, 0x3, 0x95, 0xab, 0x74, 0x7a, 0xbb, 0xc2, 0x2a, 0x70, 0x97, 0x3e, 0x2a, 0x6c}, - output256: []byte{0x56, 0xdb, 0x69, 0x43, 0xb, 0x8c, 0xa8, 0x52, 0x22, 0x1d, 0x55, 0xd7, 0xbb, 0xff, 0x47, 0x7d, 0xc8, 0x3f, 0x7c, 0xb4, 0x4a, 0xb4, 0x4d, 0xdd, 0x64, 0xc3, 0x1a, 0x52, 0xc4, 0x83, 0xdb, 0x4f}, - output384: []byte{0xeb, 0x92, 0x90, 0x23, 0xd6, 0x6a, 0xc2, 0xf, 0x11, 0xbf, 0x68, 0xeb, 0xc4, 0x30, 0x69, 0xd2, 0x7f, 0x35, 0x7, 0x7a, 0x68, 0xd2, 0x1f, 0xab, 0x30, 0x85, 0x4f, 0xfe, 0x53, 0xcb, 0xd7, 0x84, 0xd7, 0xb2, 0x57, 0x76, 0xd9, 0xf2, 0x66, 0xf1, 0x6, 0x43, 0x37, 0x51, 0xe6, 0xc3, 0x8a, 0x68}, - output512: []byte{0xf0, 0x48, 0x2f, 0x9, 0x8b, 0x93, 0x62, 0x4b, 0xcd, 0xe1, 0xaa, 0xb5, 0x80, 0x97, 0x19, 0x86, 0x49, 0xa8, 0xdc, 0x84, 0x42, 0x18, 0x26, 0xd1, 0xc1, 0x1, 0x1a, 0xd4, 0x1b, 0x94, 0x83, 0x84, 0xc8, 0xed, 0x5a, 0x97, 0xc6, 0x4c, 0x13, 0x4b, 0x38, 0xa0, 0x7, 0x58, 0x12, 0xa3, 0x5f, 0x9c, 0xe3, 0xcb, 0x20, 0x9, 0x72, 0xc2, 0xec, 0xdf, 0xc4, 0x8, 0x71, 0x41, 0x39, 0xb9, 0xbf, 0xf0}}, - testcase{ - msg: []byte{0x51, 0x79, 0x88, 0x87, 0x24, 0x81, 0x9f, 0xba, 0xd3, 0xaf, 0xa9, 0x27, 0xd3, 0x57, 0x77, 0x96, 0x66, 0xe, 0x6a, 0x81, 0xc5, 0x2d, 0x98, 0xe9, 0x30, 0x32, 0x61, 0xd5, 0xa4, 0xa8, 0x32, 0x32, 0xf6, 0xf7, 0x58, 0x93, 0x4d, 0x50, 0xaa, 0x83, 0xff, 0x9e, 0x20, 0xa5, 0x92, 0x6d, 0xfe, 0xba, 0xac, 0x49, 0x52, 0x9d, 0x0, 0x6e, 0xb9, 0x23, 0xc5, 0xae, 0x50, 0x48, 0xed, 0x54, 0x4e, 0xc4, 0x71, 0xed, 0x71, 0x91, 0xed, 0xf4, 0x63, 0x63, 0x38, 0x38, 0x24, 0xf9, 0x15, 0x76, 0x9b, 0x3e, 0x68, 0x80, 0x94, 0xc6, 0x82, 0xb0, 0x21, 0x51, 0xe5, 0xee, 0x1, 0xe5, 0x10, 0xb4, 0x31, 0xc8, 0x86, 0x5a, 0xff, 0x8b, 0x6b, 0x6f, 0x2f, 0x59, 0xcb, 0x6d, 0x12, 0x9d, 0xa7, 0x9e, 0x97, 0xc6, 0xd2, 0xb8, 0xfa, 0x6c, 0x6d, 0xa3, 0xf6, 0x3, 0x19, 0x9d, 0x2d, 0x1b, 0xca, 0xb5, 0x47, 0x68, 0x2a, 0x81, 0xcd, 0x6c, 0xf6, 0x5f, 0x65, 0x51, 0x12, 0x13, 0x91, 0xd7, 0x8b, 0xcc, 0x23, 0xb5, 0xbd, 0xe, 0x92, 0x2e, 0xc6, 0xd8, 0xbf, 0x97, 0xc9, 0x52, 0xe8, 0x4d, 0xd2, 0x8a, 0xef, 0x90, 0x9a, 0xba, 0x31, 0xed, 0xb9, 0x3, 0xb2, 0x8f, 0xbf, 0xc3, 0x3b, 0x77, 0x3, 0xcd, 0x99, 0x62, 0x15, 0xa1, 0x12, 0x38}, - output224: []byte{0xb1, 0xba, 0x91, 0xc, 0x9f, 0x5e, 0x12, 0x66, 0x7, 0xff, 0x25, 0x31, 0xaf, 0xfe, 0xcb, 0xa7, 0x91, 0x26, 0x1e, 0x35, 0x4e, 0x2c, 0x1a, 0x81, 0xfd, 0xa7, 0xa7, 0x56}, - output256: []byte{0xf8, 0x53, 0x8f, 0x59, 0x7f, 0x44, 0x63, 0xca, 0xd7, 0xa9, 0x19, 0x5, 0x74, 0x4b, 0x87, 0x15, 0x6d, 0xb3, 0x3c, 0x65, 0xba, 0x87, 0xb9, 0x12, 0x42, 0x7f, 0xec, 0x36, 0x69, 0xf4, 0x25, 0xd4}, - output384: []byte{0x6a, 0x51, 0x97, 0x5c, 0x9f, 0xfe, 0xe8, 0xb9, 0x41, 0x35, 0xa3, 0xbd, 0xa9, 0x54, 0xdf, 0xe1, 0x4e, 0x62, 0x67, 0xdb, 0xc9, 0x25, 0x3f, 0xb, 0xb0, 0x45, 0x15, 0xa6, 0xb7, 0x74, 0x5a, 0xec, 0x61, 0x1b, 0x7b, 0x66, 0xae, 0x57, 0xd3, 0xfd, 0x37, 0x70, 0xae, 0xd4, 0xf4, 0x12, 0xec, 0x84}, - output512: []byte{0xa3, 0x18, 0x84, 0x26, 0xce, 0xa0, 0xc1, 0x8c, 0xb6, 0x38, 0xb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3, 0x32, 0xb7, 0x6b, 0xe8, 0x9a, 0x3, 0x24, 0xaa, 0x12, 0xc5, 0x48, 0x2d, 0x1e, 0xa3, 0xee, 0x89, 0xde, 0xd4, 0x93, 0x6f, 0x3e, 0x3c, 0x8, 0x4, 0x36, 0xf5, 0x39, 0xfa, 0x13, 0x7e, 0x74, 0xc6, 0xd3, 0x38, 0x9b, 0xdf, 0x5a, 0x45, 0x7, 0x4c, 0x47, 0xbc, 0x7b, 0x20, 0xb0, 0x94, 0x84, 0x7, 0xa6, 0x6d, 0x85, 0x5e, 0x2f}, - output224: []byte{0x3e, 0xf8, 0xd4, 0xa6, 0xbb, 0x8e, 0x17, 0x23, 0x74, 0xe8, 0x6, 0xe8, 0xd6, 0x5d, 0x5f, 0x81, 0xb3, 0xfd, 0xb3, 0x62, 0x99, 0xde, 0x1c, 0xc, 0xcc, 0x26, 0xdc, 0x65}, - output256: []byte{0x44, 0x7e, 0xda, 0x92, 0x3c, 0xfe, 0x11, 0x12, 0xa6, 0xf1, 0xa3, 0xe4, 0xc7, 0x35, 0xbf, 0x8e, 0xe9, 0xe4, 0xf2, 0xae, 0xe7, 0xde, 0x66, 0x6a, 0x47, 0x2f, 0xf8, 0xcf, 0xf, 0xc6, 0x53, 0x15}, - output384: []byte{0xd2, 0xdc, 0x49, 0xc0, 0x45, 0x53, 0xf0, 0x9a, 0x8c, 0x3d, 0x7d, 0xb5, 0x1d, 0xe8, 0x90, 0xa7, 0x1d, 0xbc, 0x10, 0xfe, 0x4e, 0x91, 0xc, 0x68, 0xba, 0x5c, 0xa5, 0xdd, 0xb3, 0x13, 0xd0, 0xa6, 0x83, 0x75, 0x27, 0x5c, 0x29, 0x1b, 0x4d, 0xeb, 0x41, 0xf4, 0x5e, 0x35, 0xa5, 0x58, 0xbf, 0x77}, - output512: []byte{0xb, 0x14, 0x69, 0x3e, 0x63, 0x20, 0x66, 0x8d, 0x64, 0xeb, 0xb3, 0xbf, 0x6e, 0xeb, 0x81, 0xaa, 0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0xec, 0x21, 0x73, 0x72, 0xb9, 0x89, 0x70, 0xcc, 0x63, 0x21, 0x57, 0x6d, 0x92, 0xce, 0x38, 0xf7, 0xc3, 0x97, 0xa4, 0x3, 0xba, 0xda, 0x15, 0x48, 0xd2, 0x5, 0xc3, 0x43, 0xac, 0x9, 0xde, 0xca, 0x86, 0x32, 0x53, 0x73, 0xc3, 0xb7, 0x6d, 0x9f, 0x32, 0x2, 0x8f, 0xea, 0x8e, 0xb3, 0x25, 0x15}, - output224: []byte{0x1c, 0x89, 0xd6, 0x46, 0xb, 0x3f, 0x13, 0x58, 0x4b, 0xf8, 0x31, 0x9e, 0xe5, 0x38, 0xf2, 0x4c, 0x85, 0xc, 0xa7, 0x71, 0xa5, 0x1e, 0xcc, 0x54, 0x76, 0x52, 0xba, 0xe3}, - output256: []byte{0x74, 0xd9, 0x4c, 0x13, 0xaf, 0xea, 0x4d, 0xdd, 0x7, 0xa6, 0x37, 0xb6, 0x8b, 0x6f, 0xe0, 0x95, 0x1, 0x7c, 0x9, 0x2b, 0x3c, 0xdc, 0xcd, 0xc4, 0x98, 0xe2, 0x60, 0x35, 0xd8, 0x6d, 0x92, 0x1e}, - output384: []byte{0xaa, 0xb5, 0x74, 0x7d, 0x7d, 0xcc, 0x77, 0xba, 0xcd, 0xe8, 0x1a, 0x58, 0xc3, 0x77, 0x64, 0xf8, 0xf4, 0x1e, 0x8, 0xf2, 0x41, 0x3b, 0x40, 0xd4, 0xe6, 0xc7, 0x92, 0xce, 0xfe, 0x52, 0xe4, 0xe2, 0xa4, 0x6, 0x33, 0x87, 0x52, 0xd7, 0xad, 0x12, 0x69, 0xe7, 0xd5, 0x28, 0x4f, 0xcb, 0x74, 0x0}, - output512: []byte{0xa9, 0xab, 0xc3, 0xf5, 0x54, 0xc1, 0xe7, 0x17, 0x93, 0x5d, 0x28, 0xc2, 0x8e, 0x7c, 0x26, 0xaa, 0x9d, 0xc5, 0xbd, 0x6d, 0x7b, 0x2, 0xed, 0x7d, 0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c9, 0x7a, 0xbd, 0xef, 0x6b, 0x56, 0x38, 0xd, 0xda, 0x70, 0x12, 0xa8, 0x38, 0x40, 0x91, 0xb6, 0x65, 0x6d, 0xa, 0xb2, 0x72, 0xd3, 0x63, 0xce, 0xa7, 0x81, 0x63, 0xff, 0x76, 0x5c, 0xdd, 0x13, 0xab, 0x17, 0x38, 0xb9, 0x40, 0xd1, 0x6c, 0xae}, - output224: []byte{0x99, 0x98, 0x17, 0x66, 0xcf, 0xe3, 0xb1, 0x88, 0x8f, 0x2a, 0x0, 0x8e, 0xfa, 0x10, 0x88, 0x1, 0x6c, 0xb2, 0x99, 0x93, 0x56, 0x7f, 0x9b, 0xb7, 0x4b, 0x5c, 0x4d, 0x3c}, - output256: []byte{0xcc, 0x11, 0x19, 0x6c, 0x9, 0x5b, 0xff, 0xa0, 0x90, 0xa0, 0x5b, 0xa0, 0xbc, 0x25, 0x5d, 0x38, 0xbd, 0xa7, 0x21, 0x8d, 0x93, 0x11, 0x14, 0x3f, 0x4f, 0x20, 0xb, 0x18, 0x52, 0xd1, 0xbb, 0xd}, - output384: []byte{0x72, 0xb5, 0x26, 0xd7, 0x4c, 0xf9, 0x52, 0x1e, 0x0, 0xd9, 0xd6, 0xbc, 0xdf, 0xc1, 0xfb, 0x17, 0x60, 0xc6, 0xac, 0xdf, 0x2d, 0xd7, 0x51, 0x71, 0x30, 0x5d, 0xb4, 0x5d, 0x38, 0x9, 0x8f, 0xf2, 0x3c, 0x5b, 0x8e, 0xd3, 0xc2, 0x1d, 0xa7, 0x3f, 0xfb, 0x8d, 0xf7, 0x21, 0x7c, 0xe4, 0x6d, 0xbb}, - output512: []byte{0x4, 0xdd, 0x83, 0xd2, 0xf, 0x58, 0xe8, 0x54, 0xd8, 0x57, 0xf2, 0x47, 0x20, 0xc5, 0xa, 0x4b, 0x5f, 0x83, 0xdb, 0xc8, 0xca, 0xbd, 0x46, 0xd, 0x37, 0x94, 0x17, 0xcd, 0x48, 0x13, 0x77, 0x2a,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, 0xb5, 0x6d, 0x63, 0x1f, 0xca, 0x5c, 0xe8, 0xb2, 0xcd, 0xe6, 0x20, 0xd1, 0x1d, 0x17, 0x77, 0xed, 0x9f, 0xa6, 0x3, 0x54, 0x1d, 0xe7, 0x94, 0xdd, 0xc5, 0x75, 0x8f, 0xcd, 0x5f, 0xad, 0x78, 0xc0}, - output224: []byte{0x2, 0x15, 0xe9, 0x1e, 0xf9, 0x92, 0xdc, 0xc7, 0xe8, 0x2d, 0x16, 0xa2, 0xc9, 0xb2, 0x79, 0x21, 0xc1, 0x31, 0xc, 0x18, 0x2f, 0x59, 0xdf, 0x8b, 0xed, 0x51, 0x51, 0xe8}, - output256: []byte{0x8c, 0x8, 0x5b, 0x54, 0xc2, 0x13, 0x70, 0x43, 0x74, 0xdd, 0xd9, 0x20, 0xa4, 0x51, 0x68, 0x60, 0x8b, 0xe6, 0x5d, 0xfd, 0x3, 0x6a, 0x56, 0x26, 0x59, 0xf4, 0x71, 0x43, 0x60, 0x41, 0x44, 0xc2}, - output384: []byte{0x80, 0xc, 0xfa, 0x48, 0xb4, 0x64, 0x7f, 0x77, 0x83, 0xbc, 0xd4, 0x1b, 0x2c, 0xf, 0x7f, 0x7d, 0x4d, 0xf, 0xaa, 0x72, 0x48, 0x1a, 0x2a, 0x42, 0xc4, 0xe9, 0xc4, 0x3c, 0x9f, 0x62, 0xe2, 0x7a, 0xcb, 0x4d, 0xdb, 0x73, 0xe3, 0x18, 0x6, 0x1d, 0x39, 0x60, 0x59, 0xaa, 0xde, 0x41, 0x45, 0xe2}, - output512: []byte{0xce, 0x76, 0xb2, 0x5c, 0x92, 0x8c, 0xb7, 0x5c, 0x9, 0xc0, 0x67, 0x4e, 0x8f, 0xcd, 0x22, 0x8, 0x96, 0x54, 0x18, 0x2c, 0xd3, 0xd8, 0x4b, 0x85, 0xcc, 0x44, 0xb1, 0x86, 0xa8, 0xb1, 0xa7, 0xcc, 0x1b, 0xb6, 0x6f, 0x38, 0x9d, 0xa6, 0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0x7b, 0x72, 0x5, 0xc0, 0x72, 0xd0, 0x2b, 0x60, 0xdb, 0xf, 0xd7, 0xe4, 0x9e, 0xa0, 0x58, 0xc2, 0xe0, 0xba, 0x20, 0x2d, 0xaf, 0xf0, 0xde, 0x91, 0xe8, 0x45, 0xcf, 0x79}, - output224: []byte{0xe5, 0x2e, 0xa6, 0x71, 0x4a, 0x39, 0x78, 0x81, 0xd, 0xc1, 0x9e, 0x99, 0x9c, 0x32, 0x51, 0x6d, 0x4a, 0xcf, 0xc, 0xbc, 0xd6, 0x7e, 0x91, 0x7a, 0x4f, 0xeb, 0x56, 0xd0}, - output256: []byte{0xd2, 0xe2, 0x33, 0x26, 0x4a, 0x37, 0x73, 0x49, 0x5f, 0xfd, 0x12, 0x15, 0x9e, 0xf7, 0xb6, 0x31, 0x66, 0xc, 0x1b, 0x3e, 0x53, 0xa3, 0xda, 0xf, 0x24, 0xae, 0x14, 0x46, 0x6f, 0x16, 0x77, 0x57}, - output384: []byte{0xf7, 0x82, 0xff, 0xd, 0xe7, 0xd5, 0x44, 0x2d, 0x56, 0x2c, 0xc5, 0x0, 0x25, 0x6e, 0xe4, 0xb5, 0xa0, 0xe, 0x88, 0x5c, 0x8c, 0xd8, 0x60, 0x9, 0xc5, 0x3f, 0x33, 0x7a, 0xe0, 0x3, 0x85, 0x4d, 0xe4, 0xb8, 0x97, 0x94, 0x28, 0x1a, 0x64, 0x37, 0x5e, 0x3f, 0x69, 0x6a, 0x41, 0x5b, 0x95, 0xd2}, - output512: []byte{0x2, 0xd1, 0x67, 0x19, 0x81, 0xc2, 0xe8, 0x5d, 0x4, 0x55, 0xee, 0x85, 0xf4, 0x1b, 0x8e, 0x9c, 0x32, 0xb1, 0xc8, 0x2, 0x21, 0xdd, 0x43, 0x2b, 0x8b, 0xcb, 0x5f, 0xce, 0xfe, 0x9, 0x96, 0xf3, 0x2f, 0xe9, 0xfc, 0x3e, 0xeb, 0x3f, 0x1f, 0x55, 0x7a, 0xe1, 0x63, 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0xe2, 0x4b, 0xa0, 0xb7, 0x5, 0x55, 0x71, 0x30, 0xce, 0xc5, 0x7e, 0xba, 0xd1, 0xd0, 0xb3, 0x1a, 0x37, 0x8e, 0x91, 0x89, 0x4e, 0xe2, 0x6e, 0x3a, 0x4}, - output224: []byte{0x4c, 0x3d, 0x63, 0x21, 0x13, 0x3e, 0xf7, 0x48, 0x10, 0xe6, 0xd, 0x31, 0x90, 0xff, 0xf3, 0xcf, 0x20, 0xc8, 0x52, 0x1c, 0xae, 0xa6, 0xff, 0x78, 0x2d, 0x7e, 0x3b, 0xab}, - output256: []byte{0xff, 0xac, 0x7c, 0xa5, 0xfa, 0x6, 0x74, 0x19, 0xd1, 0xbd, 0xb0, 0xc, 0xe, 0x49, 0xc6, 0xe1, 0xa7, 0x48, 0x88, 0x9, 0x23, 0xa2, 0x3e, 0xd5, 0xdd, 0x67, 0xdd, 0xe6, 0x3d, 0x77, 0x7e, 0xdb}, - output384: []byte{0xde, 0x34, 0x50, 0x6a, 0xd6, 0x90, 0x85, 0xc6, 0x35, 0x7d, 0x62, 0xb0, 0xb1, 0x27, 0xce, 0x66, 0xe2, 0x5e, 0x8e, 0xc5, 0xfa, 0xca, 0x5b, 0xa8, 0x98, 0xc7, 0x5c, 0xa1, 0x9e, 0x9a, 0xf2, 0x4f, 0x2, 0x40, 0x67, 0x16, 0xc6, 0x1a, 0x71, 0xd6, 0x2b, 0xdc, 0x28, 0xd7, 0x18, 0xc1, 0x25, 0xdf}, - output512: []byte{0x6b, 0x8b, 0xc6, 0x21, 0x1f, 0xe5, 0x0, 0x1e, 0x7, 0xb7, 0xd2, 0xe, 0xc, 0x49, 0xd3, 0x14, 0x21, 0x1e, 0x38, 0x93, 0xa3, 0x9d, 0xa2, 0x41, 0xb8, 0x83, 0x9b, 0xb3, 0xa4, 0x94, 0xf9, 0xa2, 0xfd, 0x85, 0x61, 0x0, 0x9d, 0x22, 0xcc, 0xa1, 0x33, 0xa, 0x69, 0x36, 0x2b, 0x38,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c, 0x75, 0xb0, 0x6b, 0x80, 0xd3, 0xd, 0xad, 0x68, 0x6, 0x54, 0x4d, 0x51, 0xa, 0xf6, 0xc4, 0x78, 0x5e, 0x82, 0x3a, 0xc3, 0xe0, 0xb8}, - output224: []byte{0xb9, 0xf0, 0x6, 0xdb, 0xf8, 0x53, 0xc0, 0x23, 0xde, 0xbe, 0x2f, 0x40, 0x3, 0x5a, 0x7e, 0x83, 0xc4, 0x9c, 0xde, 0x65, 0x6e, 0xc8, 0x6a, 0x46, 0x21, 0x95, 0xf, 0x3e}, - output256: []byte{0x5b, 0x2e, 0xca, 0x9, 0x20, 0xd3, 0x2b, 0x19, 0x64, 0xbb, 0xf5, 0x81, 0xa, 0x6e, 0x6e, 0x53, 0x67, 0x5e, 0xd1, 0xb8, 0x38, 0x97, 0xfd, 0x4, 0x60, 0xd, 0x72, 0xe0, 0x97, 0x84, 0x58, 0x59}, - output384: []byte{0x6f, 0x4f, 0xee, 0xdb, 0xa0, 0xab, 0xb4, 0xdb, 0xf8, 0x24, 0x30, 0x22, 0x50, 0xe6, 0xb6, 0x68, 0xcb, 0xff, 0xdc, 0xa0, 0xb8, 0xc3, 0x38, 0x23, 0x6f, 0xe0, 0x2a, 0x87, 0x79, 0xd8, 0xac, 0xa3, 0x91, 0xd8, 0xd1, 0x16, 0xb2, 0xbc, 0x43, 0xd4, 0xe, 0x73, 0x60, 0x96, 0x47, 0xa, 0xb, 0xc0}, - output512: []byte{0xd0, 0xe, 0x91, 0x9d, 0xaf, 0xff, 0x3d, 0x5e, 0x51, 0xad, 0x3a, 0x30, 0x46, 0xf5, 0xe5, 0x9d, 0x64, 0xb6, 0x9c, 0xbc, 0xda, 0x22, 0x3c, 0xb2, 0x8b, 0xc3, 0x70, 0x20, 0x1d, 0x2c, 0x72, 0x2b, 0xae, 0x74, 0xdf, 0xe0, 0x8, 0x6b, 0xe, 0xb4, 0x7b, 0xdc, 0xb6, 0x2f, 0xab, 0xee, 0x87, 0xc, 0x33, 0x40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0x9c, 0xf5, 0x3b, 0xd7, 0x67, 0xf5, 0x73, 0x7d, 0x55, 0x18, 0x4e, 0xea, 0x1a, 0xb3, 0xf5, 0x3e, 0xdd, 0x9, 0x76, 0xc4, 0x85}, - output224: []byte{0xa, 0x5a, 0xa6, 0xbc, 0x56, 0x4b, 0x8c, 0xb2, 0xf5, 0xfd, 0x72, 0x55, 0x45, 0x5c, 0xe, 0x7a, 0x5d, 0xac, 0xe0, 0x5, 0xc, 0x3b, 0xbd, 0x25, 0x9f, 0xde, 0x2a, 0xb9}, - output256: []byte{0x68, 0xf4, 0x1f, 0xdf, 0xc7, 0x21, 0x7e, 0x89, 0x68, 0x7e, 0xd1, 0x18, 0xbc, 0x31, 0xac, 0x6e, 0xd2, 0xd9, 0xd1, 0xe1, 0xa2, 0xf1, 0xb2, 0xa, 0x2d, 0x42, 0x97, 0x29, 0xfa, 0x3, 0x51, 0x7b}, - output384: []byte{0xa0, 0x40, 0xce, 0x1c, 0xbb, 0x99, 0x67, 0x23, 0xcb, 0xcd, 0xbd, 0xff, 0x7a, 0x6a, 0x5f, 0x69, 0x28, 0x97, 0x37, 0x60, 0x95, 0x34, 0xc5, 0xaf, 0x36, 0xf6, 0xc4, 0x20, 0xa6, 0xad, 0xfd, 0x57, 0x7, 0x94, 0x7, 0x95, 0x9, 0xd0, 0x7e, 0x62, 0x56, 0x6c, 0x58, 0x6, 0x2d, 0x81, 0x86, 0xdb}, - output512: []byte{0xcf, 0x63, 0xf2, 0x8f, 0x10, 0x7a, 0x50, 0x9a, 0x41, 0x6f, 0x9a, 0x92, 0xc4, 0xe4, 0xdb, 0x4d, 0xbf, 0x0, 0xfb, 0x52, 0xc2, 0xe1, 0x6d, 0x8b, 0xb9, 0x69, 0x4e, 0x9, 0xf9, 0x14, 0x2a, 0x90, 0x4c, 0x34, 0xe1, 0xe9, 0x60, 0xbd, 0x97, 0xb8, 0xcf, 0xb2, 0xc5, 0x3e, 0x76, 0x60, 0xc7, 0x9b, 0x84, 0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, 0x55, 0x80, 0x2c, 0x11, 0x7d, 0x23, 0xcc, 0xb5, 0x5e, 0xa2, 0x8f, 0x95, 0xc0, 0xd8, 0xc2, 0xf9, 0xc5, 0xa2, 0x42, 0xb3, 0x3f}, - output224: []byte{0x8c, 0xa4, 0xe0, 0x85, 0xf0, 0x49, 0x56, 0xb5, 0xb1, 0x65, 0x20, 0xe3, 0xa7, 0x67, 0xf8, 0xba, 0x93, 0x73, 0x64, 0xfe, 0x5f, 0x44, 0x60, 0x28, 0x8a, 0xd4, 0xf2, 0x31}, - output256: []byte{0xfa, 0x2f, 0x3d, 0xe3, 0x1e, 0x9c, 0xf2, 0x5a, 0xb9, 0xa9, 0x78, 0xc8, 0x2d, 0x60, 0x5a, 0x43, 0xee, 0x39, 0xb6, 0x8a, 0xc8, 0xe3, 0xf, 0x49, 0xf9, 0xd2, 0x9, 0xcb, 0x4e, 0x17, 0x2a, 0xb4}, - output384: []byte{0xff, 0x13, 0xc2, 0x9c, 0x5e, 0xd, 0x74, 0x6c, 0xa2, 0x7a, 0xee, 0x38, 0xb6, 0xb4, 0x9a, 0x13, 0xc1, 0xb3, 0xd7, 0xe, 0x62, 0x87, 0x54, 0x43, 0xbc, 0xfc, 0x22, 0xa2, 0x2e, 0x75, 0x3, 0x1e, 0x60, 0xd6, 0x8a, 0x91, 0x7e, 0x3a, 0xe1, 0xd4, 0x2d, 0x37, 0x4d, 0x44, 0xcd, 0xc9, 0xf4, 0xc8}, - output512: []byte{0xf2, 0x1b, 0x8d, 0x45, 0xb6, 0xa8, 0x57, 0xce, 0x66, 0x3c, 0x7, 0x4c, 0x18, 0xcc, 0x54, 0xd9, 0x14, 0xcd, 0xd5, 0xeb, 0xd, 0x96, 0x8e, 0x61, 0x53, 0xa5, 0xf7, 0x0, 0x69, 0x34, 0x5d, 0x20, 0x5d, 0xdf, 0x43, 0x70, 0xec, 0x47, 0x3f, 0xc8, 0xb, 0x5, 0xf9, 0x37, 0xd0, 0x14, 0xc0, 0xa4, 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 0xbf, 0x0, 0xe5, 0xbc, 0x2a, 0xd5, 0x4d, 0xd9, 0x1f, 0xf9, 0xfd, 0xa4, 0xdd, 0x77, 0xb6, 0xc7, 0x54, 0xa9, 0x19, 0x55, 0xd1, 0xfb, 0xaa, 0xd0}, - output224: []byte{0xc0, 0xaa, 0x34, 0x39, 0x1c, 0xb3, 0x10, 0x4c, 0x41, 0x99, 0x5f, 0x3d, 0xe7, 0x82, 0xf0, 0x12, 0xd4, 0x21, 0x58, 0x5e, 0x53, 0x84, 0xe0, 0x47, 0xa9, 0x97, 0x6, 0x2f}, - output256: []byte{0xba, 0x2a, 0xf5, 0x6, 0xc1, 0xd, 0xa8, 0xd7, 0x75, 0x1e, 0x67, 0xed, 0x76, 0x6c, 0xfc, 0xd4, 0x7d, 0x4, 0x8d, 0x6e, 0xf9, 0x27, 0x7d, 0xbd, 0x2a, 0xbf, 0xe2, 0xfd, 0x5d, 0x78, 0x7b, 0x79}, - output384: []byte{0x3a, 0x44, 0x18, 0xa1, 0x68, 0x96, 0xad, 0xab, 0x7c, 0x6d, 0xc7, 0x83, 0xa0, 0xfc, 0x9f, 0x8d, 0x7e, 0x94, 0x99, 0x37, 0xbe, 0x1d, 0x68, 0xb5, 0xef, 0x2, 0x57, 0x4b, 0x2b, 0xc, 0x9b, 0xa9, 0x2, 0xfb, 0x9c, 0x15, 0xed, 0x64, 0xfc, 0x82, 0x5d, 0x59, 0x8a, 0xaf, 0xc1, 0xb2, 0x63, 0x47}, - output512: []byte{0x92, 0x28, 0x7f, 0x42, 0xab, 0x1a, 0x21, 0x23, 0x66, 0x9c, 0x4d, 0x35, 0xf1, 0x82, 0x57, 0xd3, 0xa5, 0x36, 0x44, 0x5f, 0xe, 0x4d, 0x2c, 0x80, 0x1e, 0x99, 0xf8, 0x52, 0x9c, 0xd9, 0xe2, 0xa7, 0x92, 0x5, 0x98, 0x2c, 0x28, 0xc, 0x7a, 0x6c, 0xdd, 0xde, 0xf2, 0x4c, 0xe9, 0x60,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b, 0xaa, 0x9f, 0xfc, 0x96, 0xa1, 0x65, 0x52, 0x16, 0x77, 0x34, 0x58, 0xbe, 0xc7, 0x2b, 0xe, 0x39, 0xc9, 0xf2, 0xc1, 0x21, 0x37, 0x8f, 0xea, 0xb4, 0xe7, 0x6a}, - output224: []byte{0x33, 0xc1, 0x0, 0x10, 0xa0, 0xb8, 0x10, 0x38, 0x6a, 0xe6, 0x2f, 0x3f, 0x92, 0x7d, 0xea, 0xfc, 0xd, 0x5a, 0xf0, 0xaf, 0x3d, 0xc7, 0xa8, 0x35, 0x5c, 0xb7, 0x79, 0xcd}, - output256: []byte{0x3c, 0xd3, 0x3f, 0x88, 0x11, 0xaf, 0x12, 0x18, 0x3c, 0x53, 0xe9, 0x78, 0x52, 0x8f, 0x53, 0xae, 0x7d, 0x55, 0x94, 0x32, 0x72, 0x40, 0x29, 0xe5, 0x5f, 0xcf, 0xa9, 0xb9, 0x90, 0xb9, 0x17, 0x13}, - output384: []byte{0x17, 0xf8, 0x44, 0x11, 0xe6, 0xf, 0x6b, 0xd8, 0x56, 0xd0, 0x9c, 0xa, 0xcf, 0x31, 0x4e, 0x75, 0x46, 0x46, 0x6a, 0xb0, 0xc1, 0x61, 0x62, 0x84, 0xd2, 0x24, 0xd, 0x22, 0xbc, 0xcc, 0x72, 0x40, 0xe5, 0xa2, 0xd6, 0x56, 0xd3, 0x52, 0x57, 0xab, 0x49, 0x78, 0x1b, 0xda, 0xbe, 0xf6, 0xfc, 0xf9}, - output512: []byte{0x74, 0xa9, 0xd8, 0xf9, 0xf7, 0x29, 0x8, 0xc7, 0x50, 0x2d, 0x1c, 0x41, 0x21, 0x2c, 0xd8, 0x6c, 0xf4, 0x34, 0x47, 0x21, 0xa6, 0xf0, 0x2d, 0x39, 0x3, 0x46, 0xf2, 0xba, 0xec, 0x6e, 0x61, 0x37, 0x42, 0x1e, 0x65, 0x16, 0xc3, 0x23, 0x54, 0x43, 0xbc, 0x23, 0x37, 0xb3, 0xa7, 0x76,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 0xf1, 0x4a, 0x72, 0xea, 0xeb, 0x3f, 0x44, 0xad, 0x4d, 0xf8, 0x58, 0x66, 0xde, 0xf4, 0x3d, 0x47, 0x81, 0xa0, 0xb3, 0x57, 0x8b, 0xc9, 0x96, 0xc8, 0x79, 0x70, 0xb1, 0x32}, - output224: []byte{0x84, 0x2a, 0x2e, 0x13, 0xd2, 0x72, 0x8c, 0xa5, 0x5b, 0x42, 0xd7, 0x84, 0xbb, 0x6b, 0xc4, 0xb8, 0x89, 0xe5, 0x67, 0x75, 0xad, 0x56, 0xbf, 0x75, 0x78, 0x9c, 0xc5, 0x7a}, - output256: []byte{0x3e, 0xcc, 0x9d, 0x27, 0x99, 0x40, 0x22, 0x4, 0x5c, 0xbe, 0xab, 0x4f, 0xc0, 0x41, 0xf1, 0x24, 0x19, 0xce, 0xc8, 0x6, 0xc, 0x8f, 0x6f, 0x9f, 0x3, 0x72, 0x88, 0x4d, 0xf6, 0x7, 0x4b, 0x5c}, - output384: []byte{0xe5, 0x77, 0xf7, 0x9b, 0xe, 0x5, 0x35, 0x5b, 0x8f, 0x63, 0xec, 0x1e, 0x63, 0x9b, 0xc5, 0xa5, 0x1a, 0x72, 0xbb, 0xb0, 0xab, 0xaf, 0xe7, 0x6d, 0x31, 0x33, 0xde, 0xc4, 0xda, 0x9b, 0xef, 0x9a, 0x36, 0x1f, 0x3e, 0x3c, 0xa, 0xdb, 0x4c, 0x7, 0xe2, 0x75, 0x7f, 0xe1, 0xd4, 0x79, 0xb, 0x9a}, - output512: []byte{0x74, 0x32, 0x86, 0x11, 0x32, 0xe6, 0x89, 0x4b, 0xb6, 0xae, 0x51, 0x15, 0x39, 0x81, 0x98, 0x31, 0x7e, 0x12, 0xcc, 0x73, 0xc0, 0xc5, 0xdf, 0xc6, 0x1c, 0xb1, 0x89, 0xff, 0x5a, 0xa9, 0xfb, 0xd, 0x62, 0x22, 0x4c, 0xbb, 0x1b, 0xfa, 0x8b, 0x10, 0x57, 0x84, 0x40, 0x57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 0x80, 0xf9, 0x78, 0x7a, 0xee, 0x27, 0xbe, 0x1f, 0xe1, 0x26, 0xcd, 0xc9, 0xef, 0x89, 0x3a, 0x4a, 0x7d, 0xcb, 0xbc, 0x36, 0x7e, 0x40, 0xfe, 0x4e, 0x1e, 0xe9, 0xb, 0x42, 0xea, 0x25, 0xaf, 0x1}, - output224: []byte{0xa5, 0x76, 0x28, 0x1c, 0xfa, 0xa8, 0x9d, 0xce, 0xfb, 0x1d, 0x37, 0x77, 0x24, 0x0, 0xba, 0x4c, 0xab, 0xce, 0xef, 0x33, 0xcb, 0xa2, 0xf8, 0x33, 0x33, 0x6a, 0x74, 0xf2}, - output256: []byte{0x15, 0x1, 0x98, 0x8a, 0x55, 0x37, 0x2a, 0xc1, 0xb0, 0xb7, 0x88, 0x49, 0xf3, 0xb7, 0xe1, 0x7, 0xe0, 0xbf, 0x1f, 0x2c, 0xba, 0xf6, 0x70, 0xde, 0x7f, 0x15, 0xac, 0xbb, 0x1a, 0x0, 0xad, 0x3d}, - output384: []byte{0xf7, 0x81, 0x6, 0xf1, 0xe, 0x6c, 0x1f, 0x1c, 0xa5, 0x19, 0xf, 0xe5, 0x41, 0x34, 0x51, 0x45, 0xee, 0x25, 0xbc, 0x51, 0xd3, 0xc1, 0xcb, 0xaa, 0xa0, 0x4c, 0xd, 0xb2, 0xa3, 0xba, 0x25, 0x84, 0xdd, 0xd3, 0xf, 0x3a, 0x88, 0x9b, 0x94, 0xbb, 0xcb, 0x95, 0x73, 0xcd, 0x94, 0x17, 0x57, 0x4c}, - output512: []byte{0x6a, 0xf4, 0xff, 0x4c, 0x42, 0x30, 0x51, 0xe3, 0x30, 0x6a, 0xce, 0x81, 0x2e, 0x5c, 0xfa, 0x85, 0x53, 0x2b, 0x73, 0xde, 0xef, 0xd, 0xfe, 0x60, 0x1d, 0x26, 0x30, 0x63, 0x23, 0x89, 0xd0, 0xfa, 0xb2, 0xa1, 0x9, 0x21, 0x4d, 0x32, 0x50, 0x8d, 0x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2, 0x8f, 0x75, 0xe3, 0xe0, 0x4e, 0x5b, 0x3d, 0xeb, 0xce, 0x60, 0x7a, 0x49, 0x6d, 0x84, 0x8d, 0x67, 0xfa, 0x7b, 0x49, 0x13, 0x2c, 0x71, 0xb8, 0x78, 0xfd, 0x55, 0x57, 0xe0, 0x82, 0xa1, 0x8e, 0xca, 0x1f, 0xbd, 0xa9, 0x4d, 0x4b}, - output224: []byte{0xb1, 0x57, 0x94, 0x76, 0x97, 0x2d, 0x42, 0xfa, 0x38, 0x8f, 0xee, 0xb8, 0x42, 0x48, 0x34, 0x67, 0x2c, 0x4d, 0x1a, 0x42, 0x25, 0xee, 0x2d, 0xb8, 0x9d, 0xea, 0x73, 0x59}, - output256: []byte{0x5c, 0x4e, 0x86, 0xa, 0x1, 0x75, 0xc9, 0x2c, 0x1e, 0x6a, 0xf2, 0xcb, 0xb3, 0x8, 0x41, 0x62, 0x40, 0x3c, 0xed, 0x7, 0x3f, 0xaa, 0xc9, 0x1, 0xd0, 0xd3, 0x58, 0xb6, 0xbf, 0x5e, 0xef, 0xa9}, - output384: []byte{0x6f, 0x42, 0xfa, 0xf8, 0x7d, 0xa6, 0x55, 0x16, 0xfc, 0xc, 0xca, 0x70, 0xa3, 0x85, 0xf2, 0x6e, 0xbd, 0xaa, 0x94, 0xdf, 0x64, 0xaa, 0x5e, 0x7a, 0x31, 0x19, 0xac, 0x18, 0xc6, 0x21, 0x4e, 0x3d, 0xb, 0x61, 0x15, 0x8f, 0xbd, 0x6c, 0x24, 0x87, 0xe0, 0xab, 0xfb, 0xc, 0x6c, 0x85, 0xef, 0x87}, - output512: []byte{0x46, 0x48, 0xd2, 0x63, 0xb6, 0x8, 0xcf, 0x28, 0xca, 0x65, 0xb2, 0x8a, 0x36, 0x1e, 0xbb, 0x0, 0xe0, 0x78, 0x4c, 0x65, 0xab, 0x1d, 0x55, 0xc4, 0x6a, 0x78, 0x57, 0x37, 0xb6, 0xc8, 0xd8, 0x3d, 0xd5, 0x2e,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b0, 0x71, 0xf4, 0xd, 0xd5, 0x7c, 0x42, 0x40, 0xd9, 0x8d, 0x37, 0xb7, 0x3e, 0x41, 0x2f, 0xe0, 0xfa, 0x47, 0x3, 0x12, 0xd, 0x7c, 0xc, 0x67, 0x97, 0x2e, 0xd2, 0x33, 0xe5, 0xde, 0xb3, 0x0, 0xa2, 0x26, 0x5, 0x47, 0x2f, 0xa3, 0xa3, 0xba, 0x86}, - output224: []byte{0xa3, 0x2e, 0xc6, 0x96, 0x48, 0xb4, 0xfd, 0x9b, 0xa2, 0x43, 0x1e, 0xd0, 0xfe, 0xf0, 0x36, 0x18, 0x8c, 0x19, 0x78, 0x8d, 0x7d, 0xdf, 0xd, 0x25, 0xb6, 0xb0, 0x3e, 0xcd}, - output256: []byte{0x27, 0x2b, 0x4f, 0x68, 0x92, 0x63, 0x5, 0x7f, 0xbf, 0x76, 0x5, 0xaa, 0xa6, 0x7a, 0xf0, 0x12, 0xd7, 0x42, 0x26, 0x71, 0x64, 0xc4, 0xfa, 0xb6, 0x80, 0x35, 0xd9, 0x9c, 0x58, 0x29, 0xb4, 0xf0}, - output384: []byte{0x82, 0xfc, 0x97, 0xee, 0x34, 0xa8, 0xfc, 0xc2, 0x76, 0xae, 0x1c, 0x81, 0x30, 0x55, 0x5c, 0xc2, 0xd3, 0x39, 0xaa, 0x6c, 0xb3, 0x40, 0x3, 0x48, 0x83, 0x78, 0x85, 0x55, 0x29, 0xf9, 0xee, 0x3a, 0xf8, 0x19, 0xec, 0x10, 0x4d, 0xd2, 0xde, 0x30, 0xa, 0xb7, 0xdb, 0xc0, 0x4b, 0x2b, 0x40, 0x17}, - output512: []byte{0xdb, 0xd3, 0x73, 0x24, 0x40, 0x1, 0x5, 0x95, 0xab, 0x26, 0xf8, 0x4e, 0xfe, 0xb0, 0x77, 0x32, 0x22, 0x7a, 0x7b, 0x7b, 0x52, 0xd6, 0xff, 0x33, 0x9c, 0x7f, 0xf1, 0xb6, 0x44, 0x22, 0x49, 0x20,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7f, 0x98, 0x73, 0x7c, 0xcb, 0x7b, 0x6a, 0x6d, 0xfa, 0xe4, 0x16, 0x47, 0x74, 0x72, 0xb0, 0x46, 0xbf, 0x18, 0x11, 0x18, 0x7d, 0x15, 0x1b, 0xfa, 0x9f, 0x7b, 0x2b, 0xf9, 0xac, 0xdb, 0x23, 0xa3, 0xbe, 0x50, 0x7c, 0xdf, 0x14, 0xcf, 0xdf, 0x51, 0x7d, 0x2c, 0xb5, 0xfb, 0x9e, 0x4a, 0xb6}, - output224: []byte{0x2b, 0x8c, 0xf4, 0xc8, 0xd9, 0xe6, 0x71, 0x7e, 0xbc, 0xe4, 0xf0, 0x58, 0x4a, 0xda, 0x59, 0xa8, 0xac, 0xdf, 0xab, 0x98, 0xad, 0x7e, 0x33, 0xf3, 0x55, 0xb7, 0x70, 0x95}, - output256: []byte{0x9b, 0x28, 0xe4, 0x2b, 0x67, 0xef, 0x32, 0xec, 0x80, 0xda, 0x10, 0xa0, 0x7b, 0x0, 0x4e, 0x1d, 0x71, 0xc6, 0xdc, 0xe7, 0x1d, 0x80, 0x13, 0xff, 0xa0, 0x30, 0x5d, 0xd, 0xc, 0xe0, 0x46, 0x9d}, - output384: []byte{0x75, 0xd1, 0x40, 0xbe, 0x47, 0xe1, 0x16, 0x21, 0x1f, 0x4f, 0x66, 0x8e, 0x5, 0xad, 0xd3, 0x6c, 0x83, 0xb3, 0xe4, 0x81, 0xdf, 0x9f, 0x28, 0x6, 0x4a, 0x41, 0x89, 0x83, 0x35, 0xd9, 0x7c, 0x80, 0x54, 0x71, 0x21, 0x4e, 0x29, 0xc0, 0xb8, 0x49, 0x87, 0x58, 0x45, 0xc9, 0xb8, 0xde, 0x25, 0xe3}, - output512: []byte{0xc2, 0x4d, 0x40, 0x54, 0x11, 0x8, 0x89, 0x29, 0xc, 0xbc, 0x40, 0xb8, 0x2a, 0xd8, 0x59, 0x92, 0x29, 0xd8, 0xe8, 0x6e, 0x4c, 0xe7, 0x6b, 0xdd, 0xb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x8a, 0xd1, 0x28, 0xaf, 0x68, 0x67, 0x21, 0x7, 0xd0, 0xf1, 0xfc, 0x73, 0xc5, 0xca, 0x74, 0x4, 0x59, 0x29, 0x7b, 0x32, 0x92, 0xb2, 0x81, 0xe9, 0x3b, 0xce, 0xb7, 0x61, 0xbd, 0xe7, 0x22, 0x1c, 0x3a, 0x55, 0x70, 0x8e, 0x5e, 0xc8, 0x44, 0x72, 0xcd, 0xdc, 0xaa, 0x84, 0xec, 0xf2, 0x37, 0x23, 0xcc, 0x9, 0x91, 0x35, 0x5c, 0x62, 0x80}, - output224: []byte{0xe5, 0x83, 0x84, 0x94, 0x74, 0xf3, 0xc7, 0x59, 0xb7, 0xa3, 0x9, 0x3c, 0x7a, 0xba, 0xdd, 0x61, 0x42, 0x50, 0x73, 0xae, 0xa2, 0x67, 0x8e, 0x27, 0x82, 0x15, 0x70, 0x8d}, - output256: []byte{0xee, 0x53, 0xf8, 0x3d, 0x2e, 0x2c, 0xcc, 0x31, 0x5c, 0x63, 0x77, 0xea, 0xdd, 0xa5, 0xf4, 0x2f, 0x42, 0xf3, 0xaa, 0xdd, 0x66, 0x4e, 0x3e, 0x89, 0x5c, 0x37, 0xcb, 0xe9, 0xd0, 0xe9, 0xb9, 0xde}, - output384: []byte{0x1a, 0x4, 0xcd, 0x93, 0x74, 0x7c, 0xa5, 0x83, 0xa5, 0x8a, 0xb4, 0xa8, 0xc7, 0xc8, 0xc7, 0xa3, 0x3f, 0x2, 0x5e, 0xde, 0x1b, 0x2d, 0xd0, 0x80, 0xe5, 0xaf, 0xc, 0x4d, 0xc6, 0x3c, 0x87, 0x15, 0xe4, 0x36, 0xdd, 0x57, 0xff, 0x7f, 0x40, 0x1d, 0xec, 0xef, 0x81, 0x3f, 0x33, 0xd, 0x65, 0x88}, - output512: []byte{0x4a, 0x64, 0x4, 0xd2, 0x78, 0xa0, 0xba, 0x70, 0x48, 0x8c, 0x18, 0xd7, 0xd1, 0x86, 0x1c, 0xde, 0x26, 0x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3b, 0xec, 0x80, 0xeb, 0xb4, 0xef, 0xde, 0x25, 0x81, 0x74, 0x36, 0x7, 0x66, 0x23, 0xfc, 0x65, 0x41, 0x5f, 0xe5, 0x1d, 0x1b, 0x2, 0x80, 0x36, 0x6d, 0x12, 0xc5, 0x54, 0xd8, 0x67, 0x43, 0xf3, 0xc3, 0xb6, 0x57, 0x2e, 0x40, 0x3, 0x61, 0xa6, 0x7, 0x26, 0x13, 0x14, 0x41, 0xba, 0x49, 0x3a, 0x83, 0xfb, 0xe9, 0xaf, 0xda, 0x90, 0xf7, 0xaf, 0x1a, 0xe7, 0x17, 0x23, 0x8d}, - output224: []byte{0x10, 0x79, 0x5d, 0x3a, 0xbc, 0xc0, 0x77, 0xf4, 0xa1, 0xf5, 0xb5, 0x65, 0x3c, 0x47, 0x8f, 0x9d, 0xb4, 0x21, 0x10, 0xea, 0x9f, 0x34, 0x92, 0x54, 0x70, 0xb3, 0xcd, 0x11}, - output256: []byte{0x21, 0xcc, 0xfd, 0xa6, 0x5c, 0x4b, 0x91, 0x53, 0x3, 0x1, 0x2b, 0x85, 0x2a, 0xb2, 0x94, 0x81, 0x3, 0xf, 0x87, 0x34, 0x7c, 0x29, 0x91, 0x7e, 0x21, 0xf2, 0x10, 0xf2, 0xbd, 0x5e, 0xfc, 0x9c}, - output384: []byte{0xfb, 0x6, 0x26, 0xf2, 0xb1, 0x89, 0x67, 0x9d, 0xd9, 0x98, 0xbc, 0x18, 0xf3, 0xd, 0xf8, 0x2d, 0x9, 0x7, 0xb6, 0x2a, 0xa7, 0x7c, 0x86, 0x69, 0xe2, 0x2b, 0x53, 0x86, 0xe, 0x39, 0x88, 0x50, 0x3d, 0x88, 0x48, 0x84, 0x16, 0x3a, 0x56, 0x17, 0x39, 0x25, 0x4c, 0xa1, 0x39, 0x29, 0xb6, 0x9b}, - output512: []byte{0xff, 0xfd, 0x1b, 0x1e, 0x31, 0x37, 0x7d, 0xff, 0x0, 0xb4, 0x92, 0x29, 0x5b, 0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, 0x2e, 0xa0, 0x7e, 0xf8, 0xb8, 0xee, 0xf2, 0x7d, 0xc8, 0x50, 0x2, 0xc3, 0xae, 0x35, 0xf1, 0xa5, 0xb, 0xee, 0x6a, 0x1c, 0x48, 0xba, 0x7e, 0x17, 0x5f, 0x33, 0x16, 0x67, 0xb, 0x27, 0x98, 0x34, 0x72, 0xaa, 0x6a, 0x61, 0xee, 0xd0, 0xa6, 0x83, 0xa3, 0x9e, 0xe3, 0x23, 0x8, 0x6, 0x20, 0xea, 0x44, 0xa9, 0xf7, 0x44, 0x11, 0xae, 0x5c, 0xe9, 0x90, 0x30, 0x52, 0x8f, 0x9a, 0xb4, 0x9c, 0x79, 0xf2}, - output224: []byte{0x31, 0xa8, 0x43, 0xb4, 0xa9, 0xf3, 0x32, 0xf3, 0xb6, 0xb0, 0x99, 0x84, 0x35, 0x40, 0xaa, 0x70, 0x65, 0x1b, 0x26, 0xb8, 0xe, 0xb, 0xd7, 0x5b, 0x77, 0xf3, 0xaa, 0x9b}, - output256: []byte{0xf5, 0xbf, 0x70, 0x71, 0xd, 0xa4, 0x40, 0xed, 0xb4, 0x3a, 0xfd, 0x3e, 0xb7, 0x69, 0x81, 0x80, 0x31, 0x7f, 0xfe, 0xfa, 0x81, 0x40, 0x6b, 0xb4, 0xdf, 0x9c, 0x2b, 0xb8, 0xb0, 0xb1, 0xc0, 0x34}, - output384: []byte{0xcc, 0x2e, 0xf9, 0x60, 0x2f, 0x80, 0xd0, 0x73, 0x42, 0x95, 0xc7, 0xc1, 0x58, 0xec, 0x36, 0x66, 0x8, 0xcf, 0x60, 0xa4, 0x23, 0xd0, 0x83, 0x66, 0x44, 0xb6, 0x8, 0x31, 0xa9, 0x4e, 0x7e, 0xaf, 0x99, 0x4c, 0x81, 0xf1, 0x91, 0x74, 0xfd, 0x6c, 0xa7, 0x5b, 0xb2, 0x46, 0xbb, 0xcc, 0xa2, 0x0}, - output512: []byte{0x33, 0xc8, 0xf4, 0xe, 0x1b, 0xd1, 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0xa6, 0xb6, 0x2e, 0x4f, 0x34, 0x6a, 0x5e, 0x8d, 0xd8, 0x51, 0xc2, 0x85, 0x79, 0x95, 0xdd, 0xbf, 0x5b, 0x2d, 0x71, 0x7a, 0xeb, 0x84, 0x73, 0x10, 0xe1, 0xf6, 0xa4, 0x6a, 0xc3, 0xd2, 0x6a, 0x7f, 0x9b, 0x44, 0x98, 0x5a, 0xf6, 0x56, 0xd2, 0xb7, 0xc9, 0x40, 0x6e, 0x8a, 0x9e, 0x8f, 0x47, 0xdc, 0xb4, 0xef, 0x6b, 0x83, 0xca, 0xac, 0xf9, 0xae, 0xfb, 0x61, 0x18, 0xbf, 0xcf, 0xf7, 0xe4, 0x4b, 0xef, 0x69, 0x37, 0xeb, 0xdd, 0xc8, 0x91, 0x86, 0x83, 0x9b, 0x77}, - output224: []byte{0x10, 0x29, 0xca, 0x11, 0x79, 0x57, 0xd8, 0xf, 0x3c, 0x85, 0x9e, 0x83, 0x94, 0xdd, 0x34, 0x96, 0x93, 0x31, 0xca, 0x3b, 0xce, 0xdc, 0x43, 0x6b, 0x1e, 0xab, 0x8, 0x49}, - output256: []byte{0xe8, 0x3e, 0xa2, 0x1f, 0x5b, 0xc0, 0x97, 0x69, 0x53, 0xaf, 0x86, 0x6, 0x9a, 0x10, 0xeb, 0x60, 0x24, 0xa1, 0xac, 0x59, 0xd6, 0x9, 0x68, 0x8e, 0x4a, 0x97, 0x59, 0xbb, 0x8b, 0x6c, 0x94, 0x41}, - output384: []byte{0xb5, 0xa7, 0x16, 0x1, 0x12, 0xe0, 0x82, 0x5a, 0x7c, 0x3, 0x64, 0x3b, 0xeb, 0x98, 0xb1, 0xfc, 0x25, 0x49, 0xb8, 0x1f, 0x1, 0xc3, 0xc4, 0x27, 0x1d, 0xff, 0x99, 0xbe, 0x57, 0xd4, 0x72, 0xa7, 0xfa, 0xd1, 0x33, 0x80, 0x8d, 0x7d, 0x2d, 0x41, 0x4d, 0x60, 0x11, 0xe9, 0xa2, 0xe8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 0x99, 0x7c, 0x3b, 0x25, 0x34, 0x5a, 0x96, 0x53, 0xf3, 0xc9, 0xa6, 0x71, 0x1a, 0xb1, 0xb9, 0x1d, 0x6a, 0x9d, 0x22, 0x16, 0x44, 0x2d, 0xa2, 0xc9, 0x73, 0xcb, 0xd6, 0x85, 0xee, 0x76, 0x43, 0xbf, 0xd7, 0x73, 0x27, 0xa2, 0xf7, 0xae, 0x9c, 0xb2, 0x83, 0x62, 0xa, 0x8, 0x71, 0x6d, 0xfb, 0x46, 0x2e, 0x5c, 0x1d, 0x65, 0x43, 0x2c, 0xa9, 0xd5, 0x6a, 0x90, 0xe8, 0x11, 0x44, 0x3c, 0xd1, 0xec, 0xb8, 0xf0, 0xde, 0x17, 0x9c, 0x9c, 0xb4, 0x8b, 0xa4, 0xf6, 0xfe, 0xc3, 0x60, 0xc6, 0x6f, 0x25, 0x2f, 0x6e, 0x64, 0xed, 0xc9, 0x6b}, - output224: []byte{0x60, 0x96, 0xe9, 0x91, 0x4c, 0x1a, 0xc9, 0x3a, 0x68, 0x9, 0xde, 0x7a, 0xd9, 0x11, 0x19, 0xc6, 0x37, 0xb0, 0xb, 0xbd, 0x64, 0xdc, 0xc3, 0xe1, 0xfa, 0xc1, 0xe1, 0xed}, - output256: []byte{0xa2, 0xd9, 0x3c, 0x63, 0x67, 0xe1, 0x86, 0x28, 0x9, 0xd3, 0x67, 0xec, 0x37, 0xf9, 0xda, 0x44, 0xcb, 0x3a, 0x8b, 0x43, 0x19, 0xc6, 0xa0, 0x94, 0xc5, 0xe7, 0xd7, 0x26, 0x6f, 0xe3, 0xa5, 0x93}, - output384: []byte{0xe7, 0xb3, 0x11, 0x8d, 0x7f, 0xca, 0x9d, 0x29, 0x4f, 0x59, 0x6d, 0x82, 0xf, 0x46, 0x8c, 0xd9, 0x2, 0x79, 0x20, 0x77, 0x7a, 0x41, 0xa7, 0x6, 0xed, 0xe8, 0x77, 0xcb, 0xeb, 0x95, 0x17, 0xf2, 0x23, 0xb2,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1c, 0xfb, 0x70, 0x95, 0xf5, 0x8a, 0x87, 0xc9, 0xfa, 0x21, 0xdb, 0x72, 0xba, 0x26, 0x93, 0x79, 0xb2, 0xdc, 0x23, 0x84, 0xb3, 0xda, 0x95, 0x3c, 0x79, 0x25, 0x76, 0x1f, 0xed, 0x32, 0x46, 0x20, 0xac, 0xea, 0x43, 0x5e, 0x52, 0xb4, 0x24, 0xa7, 0x72, 0x3f, 0x6a, 0x23, 0x57, 0x37, 0x41, 0x57, 0xa3, 0x4c, 0xd8, 0x25, 0x23, 0x51, 0xc2, 0x5a, 0x1b, 0x23, 0x28, 0x26, 0xce, 0xfe, 0x1b, 0xd3, 0xe7, 0xf, 0xfc, 0x15, 0xa3, 0x1e, 0x7c, 0x5, 0x98, 0x21, 0x9d, 0x7f, 0x0, 0x43, 0x62, 0x94, 0xd1, 0x18, 0x91, 0xb8, 0x24, 0x97, 0xbc, 0x78, 0xaa, 0x53, 0x63, 0x89, 0x2a, 0x24, 0x95, 0xdf, 0x8c, 0x1e, 0xef}, - output224: []byte{0xf5, 0x83, 0xf0, 0x7d, 0xf2, 0x32, 0x78, 0x87, 0xc6, 0xf1, 0xa, 0x9b, 0x1d, 0x50, 0x9a, 0x74, 0x4f, 0x3c, 0x29, 0x4a, 0x42, 0x27, 0x97, 0x6e, 0x3c, 0x37, 0x22, 0xe8}, - output256: []byte{0x3c, 0x64, 0x7b, 0x19, 0x5f, 0x22, 0xdc, 0x16, 0xd6, 0xde, 0xcc, 0x88, 0x73, 0x1, 0x7d, 0xf3, 0x69, 0xee, 0x1c, 0x46, 0x96, 0x34, 0x9, 0x34, 0xdb, 0x15, 0x8d, 0xc4, 0x5, 0x9c, 0x76, 0xdf}, - output384: []byte{0xc3, 0xfa, 0x6c, 0x9d, 0xf, 0xf2, 0x31, 0x19, 0x8a, 0xec, 0xa8, 0xe, 0xa4, 0x28, 0xac, 0x4b, 0x32, 0xc4, 0x81, 0xd3, 0x90, 0xce, 0x4a, 0x90, 0xd0, 0xf6, 0x5f, 0xf7, 0xd5, 0x8f, 0x69, 0x6c, 0x1f, 0xaa, 0xda, 0x16, 0x73, 0xd7, 0xe2, 0xd1, 0x61, 0x46, 0x2c, 0x95, 0xc2, 0xe2, 0xa3, 0x10}, - output512: []byte{0x19, 0x59, 0xca, 0xe3, 0x60, 0xf, 0x12, 0x8f, 0x72, 0xe1, 0x82, 0x1c, 0x33, 0x7d, 0x84, 0x1b, 0x14, 0xcb, 0xbf, 0xef, 0x3a, 0x6d, 0x22, 0x28, 0x6f, 0x18, 0xbd, 0xfc, 0x3e, 0xf6, 0x35, 0x28, 0xc1, 0x1b, 0xff, 0xa8, 0x41, 0xa6, 0xd2, 0x20, 0x8a, 0xfe, 0xb5, 0x66, 0x4d, 0x52, 0x4d, 0xe8, 0x30, 0x90, 0xab, 0xd, 0xb0, 0x7c, 0xd4, 0x7e, 0xf5, 0x2f, 0x4d, 0x2e, 0xaa, 0x84, 0x54, 0xce}}, - testcase{ - msg: []byte{0xc9, 0x41, 0xcd, 0xb9, 0xc2, 0x8a, 0xb0, 0xa7, 0x91, 0xf2, 0xe5, 0xc8, 0xe8, 0xbb, 0x52, 0x85, 0x6, 0x26, 0xaa, 0x89, 0x20, 0x5b, 0xec, 0x3a, 0x7e, 0x22, 0x68, 0x23, 0x13, 0xd1, 0x98, 0xb1, 0xfa, 0x33, 0xfc, 0x72, 0x95, 0x38, 0x13, 0x54, 0x85, 0x87, 0x58, 0xae, 0x6c, 0x8e, 0xc6, 0xfa, 0xc3, 0x24, 0x5c, 0x6e, 0x45, 0x4d, 0x16, 0xfa, 0x2f, 0x51, 0xc4, 0x16, 0x6f, 0xab, 0x51, 0xdf, 0x27, 0x28, 0x58, 0xf2, 0xd6, 0x3, 0x77, 0xc, 0x40, 0x98, 0x7f, 0x64, 0x44, 0x2d, 0x48, 0x7a, 0xf4, 0x9c, 0xd5, 0xc3, 0x99, 0x1c, 0xe8, 0x58, 0xea, 0x2a, 0x60, 0xda, 0xb6, 0xa6, 0x5a, 0x34, 0x41, 0x49, 0x65, 0x93, 0x39, 0x73, 0xac, 0x24, 0x57, 0x8, 0x9e, 0x35, 0x91, 0x60, 0xb7, 0xcd, 0xed, 0xc4, 0x2f, 0x29, 0xe1, 0xa, 0x91, 0x92, 0x17, 0x85, 0xf6, 0xb7, 0x22, 0x4e, 0xe0, 0xb3, 0x49, 0x39, 0x3c, 0xdc, 0xff, 0x61, 0x51, 0xb5, 0xb, 0x37, 0x7d, 0x60, 0x95, 0x59, 0x92, 0x3d, 0x9, 0x84, 0xcd, 0xa6, 0x0, 0x8, 0x29, 0xb9, 0x16, 0xab, 0x68, 0x96, 0x69, 0x3e, 0xf6, 0xa2, 0x19, 0x9b, 0x3c, 0x22, 0xf7, 0xdc, 0x55, 0x0, 0xa1, 0x5b, 0x82, 0x58, 0x42, 0xe, 0x31, 0x4c, 0x22, 0x2b, 0xc0, 0x0, 0xbc, 0x4e, 0x54, 0x13, 0xe6, 0xdd, 0x82, 0xc9, 0x93, 0xf8, 0x33, 0xf, 0x5c, 0x6d, 0x1b, 0xe4, 0xbc, 0x79, 0xf0, 0x8a, 0x1a, 0xa, 0x46}, - output224: []byte{0xa9, 0xf4, 0x3b, 0x96, 0x21, 0xfc, 0x59, 0x2, 0xdf, 0x24, 0x58, 0xfd, 0x53, 0xd0, 0xcd, 0xe9, 0xa, 0xae, 0x70, 0x0, 0x85, 0x5c, 0x67, 0xd8, 0x53, 0xc7, 0x93, 0x7a}, - output256: []byte{0x3b, 0xb3, 0x94, 0xd0, 0x56, 0xd9, 0x4f, 0xde, 0x68, 0x92, 0xc, 0xd3, 0x83, 0x37, 0x8e, 0xe3, 0xab, 0xcc, 0x44, 0xb7, 0x25, 0x9d, 0x3d, 0xb9, 0xcd, 0xa, 0x89, 0x7e, 0x2, 0x1f, 0x7e, 0x2e}, - output384: []byte{0xc4, 0xbd, 0x11, 0x57, 0xc0, 0x93, 0xac, 0xb2, 0x7b, 0xd3, 0xbd, 0x7f, 0x44, 0x4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 0x46, 0x3e, 0x86, 0x4a, 0x58, 0xd6, 0x28, 0x6f, 0x78, 0x5e, 0x32, 0xa8, 0x4, 0x44, 0x3a, 0x56, 0xaf, 0xb, 0x4d, 0xf6, 0xab, 0xc5, 0x7e, 0xd5, 0xc2, 0xb1, 0x85, 0xdd, 0xee, 0x84, 0x89, 0xea, 0x8, 0xd, 0xee, 0xee, 0x66, 0xaa, 0x33, 0xc2, 0xe6, 0xda, 0xb3, 0x62, 0x51, 0xc4, 0x2, 0x68, 0x2b, 0x68, 0x24, 0x82, 0x1f, 0x99, 0x8c, 0x32, 0x16, 0x31, 0x64, 0x29, 0x8e, 0x1f, 0xaf, 0xd3, 0x1b, 0xab, 0xbc, 0xff, 0xb5, 0x94, 0xc9, 0x18, 0x88, 0xc6, 0x21, 0x90, 0x79, 0xd9, 0x7, 0xfd, 0xb4, 0x38, 0xed, 0x89, 0x52, 0x9d, 0x6d, 0x96, 0x21, 0x2f, 0xd5, 0x5a, 0xbe, 0x20, 0x39, 0x9d, 0xbe, 0xfd, 0x34, 0x22, 0x48, 0x50, 0x74, 0x36, 0x93, 0x1c, 0xde, 0xad, 0x49, 0x6e, 0xb6, 0xe4, 0xa8, 0x3, 0x58, 0xac, 0xc7, 0x86, 0x47, 0xd0, 0x43}, - output224: []byte{0xe9, 0x67, 0x5f, 0xaa, 0xc3, 0x7c, 0x93, 0xaa, 0x61, 0xff, 0x97, 0x30, 0x67, 0x9a, 0x3d, 0x12, 0x9, 0xad, 0xba, 0xd4, 0x65, 0x25, 0x82, 0xdf, 0xf5, 0xb1, 0xba, 0xaf}, - output256: []byte{0x43, 0x64, 0xf, 0x40, 0x86, 0x13, 0xcb, 0xf7, 0x39, 0x3d, 0x90, 0xb, 0x92, 0x1f, 0x22, 0xb8, 0x26, 0x35, 0x7f, 0x3b, 0x4f, 0xdf, 0xf7, 0x16, 0x8e, 0xc4, 0x5c, 0xbf, 0xb3, 0xef, 0x5e, 0xff}, - output384: []byte{0xd0, 0x99, 0x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, 0x4a, 0xa4, 0x49, 0x57, 0x8a, 0x7e, 0x2a, 0x8e, 0x3f, 0x5a, 0x9d, 0x68, 0xe8, 0x16, 0xb8, 0xd1, 0x68, 0x89, 0xfb, 0xc0, 0xeb, 0xf0, 0x93, 0x9d, 0x4, 0xf6, 0x30, 0x33, 0xae, 0x9a, 0xe2, 0xbd, 0xab, 0x73, 0xb8, 0x8c, 0x26, 0xd6, 0xbd, 0x25, 0xee, 0x46, 0xe, 0xe1, 0xef, 0x58, 0xfb, 0xa, 0xfa, 0x92, 0xcc, 0x53, 0x9f, 0x8c, 0x76, 0xd3, 0xd0, 0x97, 0xe7, 0xa6, 0xa6, 0x3e, 0xbb, 0x9b, 0x58, 0x87, 0xed, 0xf3, 0xcf, 0x7, 0x60, 0x28, 0xc5, 0xbb, 0xd5, 0xb9, 0xdb, 0x32, 0x11, 0x37, 0x1a, 0xd3, 0xfe, 0x12, 0x1d, 0x4e, 0x9b, 0xf4, 0x42, 0x29, 0xf4, 0xe1, 0xec, 0xf5, 0xa0, 0xf9, 0xf0, 0xeb, 0xa4, 0xd5, 0xce, 0xb7, 0x28, 0x78, 0xab, 0x22, 0xc3, 0xf0, 0xeb, 0x5a, 0x62, 0x53, 0x23, 0xac, 0x66, 0xf7, 0x6, 0x1f, 0x4a, 0x81, 0xfa, 0xc8, 0x34, 0x47, 0x1e, 0xc, 0x59, 0x55, 0x3f, 0x10, 0x84, 0x75, 0xfe, 0x29, 0xd, 0x43, 0xe6, 0xa0, 0x55, 0xae, 0x3e, 0xe4, 0x6f, 0xb6, 0x74, 0x22, 0xf8, 0x14, 0xa6, 0x8c, 0x4b, 0xe3, 0xe8, 0xc9}, - output224: []byte{0x66, 0xf2, 0x5, 0xd7, 0x14, 0x79, 0x91, 0xa9, 0x40, 0xaf, 0xfb, 0x74, 0x1, 0xb6, 0x92, 0x27, 0x53, 0x38, 0x51, 0x9a, 0x97, 0x60, 0x8c, 0x58, 0x43, 0x62, 0xff, 0xee}, - output256: []byte{0xb3, 0x4, 0xfc, 0x4c, 0xa2, 0x21, 0x31, 0x85, 0x7d, 0x24, 0x2e, 0xb1, 0x2f, 0xe8, 0x99, 0xed, 0x9e, 0x6b, 0x55, 0x71, 0x7c, 0x33, 0x60, 0xf1, 0x13, 0x51, 0x2a, 0x84, 0x17, 0x4e, 0x6a, 0x77}, - output384: []byte{0x8a, 0xee, 0xde, 0x5d, 0x6e, 0x2f, 0x9f, 0x1c, 0x7a, 0x66, 0x44, 0xa8, 0xda, 0xf, 0x93, 0x57, 0x4d, 0xf8, 0xca, 0x33, 0xb2, 0xed, 0x9d, 0x36, 0x46, 0x15, 0xe1, 0xf9, 0xcf, 0x1a, 0x80, 0x13, 0x15, 0x41, 0x7, 0x33, 0x88, 0x1c, 0xe0, 0xda, 0xd2, 0xf6, 0xfb, 0x5a, 0x91, 0x6a, 0x97, 0xe1}, - output512: []byte{0xf8, 0xe0, 0x79, 0xa6, 0xdc, 0x5a, 0x6a, 0x7e, 0x7f, 0x32, 0xff, 0x7e, 0x80, 0x15, 0xd1, 0xb2, 0x6d, 0x43, 0xb5, 0x4f, 0x16, 0x6f, 0x21, 0x11, 0xcf, 0xb2, 0xb1, 0xeb, 0x23, 0x8c, 0xab, 0xee, 0x58, 0x63, 0xe, 0xf8, 0x45, 0xe0, 0xdb, 0x0, 0xdd, 0xf1, 0xd8, 0x0, 0xad, 0x67, 0xce, 0x7b, 0x2b, 0x65, 0x8b, 0x42, 0x11, 0x8c, 0xc1, 0x5c, 0x8e, 0xf3, 0xbc, 0x9f, 0xb2, 0x52, 0xdb, 0x64}}, - testcase{ - msg: []byte{0xd2, 0xcb, 0x2d, 0x73, 0x30, 0x33, 0xf9, 0xe9, 0x13, 0x95, 0x31, 0x28, 0x8, 0x38, 0x3c, 0xc4, 0xf0, 0xca, 0x97, 0x4e, 0x87, 0xec, 0x68, 0x40, 0xd, 0x52, 0xe9, 0x6b, 0x3f, 0xa6, 0x98, 0x4a, 0xc5, 0x8d, 0x9a, 0xd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f, 0xba, 0x7e, 0x18, 0xff, 0x1a, 0x88, 0xc6, 0x6d, 0xaf, 0x7a, 0xcf, 0x63, 0x3, 0x10}, - output256: []byte{0xa3, 0xca, 0x83, 0xd, 0x47, 0x71, 0xc1, 0xba, 0xa7, 0xfa, 0xda, 0x76, 0xc5, 0xfc, 0xea, 0xdd, 0xf, 0x3c, 0xb9, 0x73, 0x6e, 0x19, 0xcf, 0xec, 0x52, 0xe9, 0xe7, 0x4f, 0x56, 0xbf, 0xdd, 0x55}, - output384: []byte{0x29, 0xe6, 0x2d, 0x8c, 0x1b, 0x71, 0xf8, 0x26, 0x54, 0x4a, 0xc, 0xbf, 0xcd, 0xd9, 0x9c, 0xf8, 0xaa, 0x1c, 0x97, 0xe1, 0x53, 0x6, 0x31, 0x20, 0xd2, 0x95, 0xed, 0xf6, 0x9e, 0x2e, 0xcb, 0x5a, 0x27, 0x83, 0xc6, 0x67, 0x60, 0xd0, 0xf8, 0x7b, 0xf9, 0x44, 0x51, 0x68, 0x24, 0xcc, 0xfc, 0xb1}, - output512: []byte{0xa5, 0xbf, 0xaa, 0x52, 0x49, 0x9a, 0x68, 0x8d, 0x9c, 0x8d, 0x3d, 0xdc, 0xb, 0xa0, 0x6d, 0xec, 0xdf, 0x38, 0x29, 0xbe, 0x5d, 0x44, 0x4a, 0xcf, 0xa4, 0x12, 0xf4, 0xc6, 0xe8, 0x63, 0xf4, 0x78, 0x6b, 0xe9, 0x93, 0x58, 0x5, 0x31, 0x7, 0x34, 0xe4, 0xf0, 0xaf, 0xfe, 0x5, 0x55, 0x89, 0x99, 0x80, 0x74, 0x8, 0xe9, 0x7e, 0x10, 0xf, 0xad, 0xd0, 0xc9, 0x3f, 0xf1, 0x60, 0xf8, 0xb1, 0x1b}}, - testcase{ - msg: []byte{0xf2, 0x99, 0x89, 0x55, 0x61, 0x3d, 0xd4, 0x14, 0xcc, 0x11, 0x1d, 0xf5, 0xce, 0x30, 0xa9, 0x95, 0xbb, 0x79, 0x2e, 0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, 0xc3, 0xfa, 0xec, 0x86, 0x85}, - output224: []byte{0xed, 0x53, 0x5e, 0xc0, 0x75, 0xc9, 0x83, 0xa0, 0x8f, 0x7d, 0x7a, 0xd5, 0x71, 0x4e, 0xbc, 0x84, 0x6f, 0x25, 0xe8, 0x66, 0x14, 0x92, 0xb2, 0xb3, 0x19, 0x78, 0xed, 0xf2}, - output256: []byte{0xca, 0x15, 0x8c, 0x46, 0x37, 0xe, 0x64, 0xa9, 0xf0, 0x32, 0xf5, 0xba, 0x8e, 0x9, 0x14, 0x60, 0xfd, 0x55, 0x5e, 0xf7, 0x0, 0xed, 0xf7, 0x8, 0x7e, 0x56, 0xbe, 0xbf, 0xfa, 0x26, 0x1d, 0xe7}, - output384: []byte{0xeb, 0x2f, 0x1b, 0xf2, 0xd9, 0xee, 0x85, 0x7b, 0x18, 0x93, 0x18, 0xdf, 0xaf, 0x49, 0xdc, 0x3f, 0xad, 0x79, 0x50, 0x11, 0x89, 0xac, 0x9b, 0x57, 0x65, 0xdf, 0xb2, 0x34, 0xec, 0x4a, 0x62, 0xf0, 0xb0, 0xe3, 0x4e, 0x7a, 0xc3, 0xf4, 0x94, 0xd6, 0xf0, 0x5c, 0x7b, 0xb8, 0x6a, 0xe5, 0xcd, 0xa2}, - output512: []byte{0xcc, 0xea, 0x9f, 0xcf, 0x1a, 0xd9, 0x32, 0x70, 0xac, 0x46, 0x90, 0xe9, 0x6b, 0x87, 0x51, 0x22, 0xc5, 0xb5, 0xec, 0x20, 0xd2, 0xcc, 0x27, 0x7, 0x9c, 0xbf, 0x89, 0x31, 0x26, 0xc4, 0x4e, 0x2, 0x8, 0xa8, 0xbf, 0xa1, 0x39, 0x5, 0x7d, 0x72, 0xbd, 0x26, 0x38, 0x5, 0x9e, 0xc8, 0xda, 0x8a, 0x72, 0x4, 0x99, 0xaf, 0x9d, 0x4c, 0x11, 0x7f, 0x86, 0x79, 0x9d, 0x75, 0x15, 0xdf, 0xc6, 0xe0}}, - testcase{ - msg: []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a, 0xa9, 0x99, 0x49, 0xdd, 0xf8, 0x9e, 0xcd, 0x90, 0x33, 0x3a, 0x77, 0xbc, 0x4e, 0x19, 0x88, 0xa8, 0x2a, 0xbf, 0x7c, 0x7c, 0xaf, 0x32, 0x91}, - output224: []byte{0x87, 0xf1, 0x5c, 0xc2, 0xae, 0xc2, 0x41, 0x68, 0xd8, 0xbb, 0xaf, 0x18, 0x88, 0x25, 0xf3, 0xbb, 0x1, 0x78, 0xcf, 0xb5, 0xc5, 0x89, 0x9f, 0x2f, 0xd0, 0x42, 0xce, 0x89}, - output256: []byte{0x59, 0x1, 0xcd, 0xa0, 0xcd, 0x15, 0x10, 0xdb, 0x54, 0x55, 0xd0, 0x72, 0xd2, 0x73, 0x7a, 0x67, 0x21, 0xad, 0x9e, 0xe3, 0x27, 0x29, 0x53, 0xa1, 0x9c, 0x7a, 0xb3, 0x78, 0xbf, 0x36, 0x46, 0xc5}, - output384: []byte{0x2a, 0x9c, 0xf2, 0xfd, 0x1, 0x2b, 0x2, 0x56, 0x16, 0x47, 0x8c, 0xef, 0x69, 0x71, 0xb6, 0xf9, 0xe4, 0x94, 0xa6, 0x3a, 0xab, 0x5f, 0x53, 0x31, 0xd, 0xde, 0x70, 0xfc, 0x6e, 0xd2, 0x7f, 0x1e, 0x2d, 0x78, 0x4, 0xae, 0xb8, 0xd2, 0x6, 0xf6, 0x41, 0xa7, 0x3e, 0x5, 0x4d, 0xa6, 0x20, 0xe6}, - output512: []byte{0x2e, 0xfc, 0x5d, 0xfe, 0x2, 0x8a, 0x35, 0x50, 0x3a, 0x25, 0xbd, 0xf8, 0xb2, 0x16, 0x4d, 0x86, 0xca, 0x74, 0x96, 0xb7, 0xc5, 0xde, 0xd0, 0x9c, 0x5d, 0x41, 0x4b, 0x69, 0x77, 0xad, 0xbb, 0x4a, 0x69, 0x88, 0xab, 0x99, 0x39, 0xd1, 0xec, 0x65, 0xf4, 0x6b, 0xcc, 0x99, 0xc1, 0xdc, 0xd5, 0xf1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0x20, 0xe6, 0xf1, 0x8b, 0xfa, 0xfd, 0xbe, 0xcb, 0xf0, 0xab, 0x0, 0x28, 0x13, 0x33, 0xed, 0x50, 0xb9, 0xa9, 0x99, 0x54, 0x9c, 0x1c, 0x8f, 0x8c, 0x63, 0xd7, 0x62, 0x6c, 0x48, 0x32, 0x2e, 0x97, 0x91, 0xd5, 0xff, 0x72, 0x29, 0x40, 0x49, 0xbd, 0xe9, 0x1e, 0x73, 0xf8}, - output224: []byte{0x31, 0xbb, 0x87, 0x25, 0x45, 0x21, 0x7f, 0xdb, 0xf1, 0x10, 0x77, 0xe8, 0x6b, 0x1e, 0xe4, 0x51, 0x47, 0x5c, 0x31, 0xdc, 0x5e, 0xe, 0x63, 0x6e, 0xfb, 0xe5, 0x8, 0x25}, - output256: []byte{0xf6, 0x45, 0x62, 0xd6, 0x27, 0x3e, 0xfb, 0x5e, 0xbd, 0x2, 0x7e, 0xa, 0x6f, 0x38, 0xc3, 0xfb, 0x20, 0x4a, 0x6d, 0xbe, 0x89, 0x4e, 0xe0, 0x12, 0x0, 0xea, 0x24, 0x9b, 0x74, 0x7c, 0xfe, 0x66}, - output384: []byte{0x5f, 0x8e, 0x2d, 0xe7, 0x42, 0x3, 0x6b, 0x6a, 0xc4, 0xa7, 0xd8, 0x98, 0x7b, 0x47, 0xc4, 0xc7, 0xa1, 0xcc, 0xb7, 0x23, 0x9e, 0x1b, 0x3e, 0xef, 0xd1, 0x11, 0x6d, 0x63, 0x92, 0xc7, 0x91, 0x77, 0xd6, 0x8c, 0x66, 0x22, 0x1f, 0x31, 0xd0, 0xfa, 0xed, 0x91, 0x34, 0x42, 0x9b, 0x89, 0xbe, 0xea}, - output512: []byte{0xe8, 0xd, 0x7a, 0x93, 0x4f, 0xda, 0xf1, 0x7d, 0xb8, 0xdb, 0xb1, 0xdc, 0x6c, 0x42, 0xe9, 0xe, 0x13, 0x92, 0x11, 0xc2, 0xf5, 0x99, 0x89, 0xc, 0x6, 0xb1, 0x5d, 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7, 0xc5, 0x57, 0xe7, 0x9d, 0xd4, 0xf5, 0xc, 0x6, 0x51, 0x1f, 0x59, 0x9f, 0x56, 0xc8, 0x96, 0xb3, 0x5c, 0x91, 0x7b, 0x63, 0xba, 0x35, 0xc6, 0xff, 0x80, 0x92, 0xba, 0xf7, 0xd1, 0x65, 0x8e, 0x77, 0xfc, 0x95, 0xd8, 0xa6, 0xa4, 0x3e, 0xeb, 0x4c, 0x1, 0xf3, 0x3f, 0x3, 0x87, 0x7f, 0x92, 0x77, 0x4b, 0xe8, 0x9c, 0x11, 0x14, 0xdd, 0x53, 0x1c, 0x1, 0x1e, 0x53, 0xa3, 0x4d, 0xc2, 0x48, 0xa2, 0xf0, 0xe6}, - output224: []byte{0x26, 0xd6, 0x9f, 0xa, 0xe8, 0xe4, 0xdc, 0x61, 0xc6, 0x35, 0x4f, 0xf5, 0x70, 0xfd, 0xd9, 0x13, 0xca, 0xf2, 0x1c, 0x18, 0x69, 0x7f, 0x3, 0x71, 0xf2, 0xd3, 0x23, 0xaf}, - output256: []byte{0xe7, 0xd7, 0xa1, 0x13, 0xb3, 0xa3, 0x31, 0x75, 0xd0, 0xab, 0xd2, 0xcf, 0x4f, 0x9a, 0xdd, 0x8e, 0x41, 0xdc, 0x86, 0xc9, 0x3c, 0x95, 0x52, 0xc5, 0xb3, 0x58, 0x82, 0x77, 0xfb, 0xca, 0xa2, 0x4a}, - output384: []byte{0xb0, 0xb1, 0xf4, 0x5, 0x84, 0x17, 0x51, 0x6a, 0x5c, 0x5a, 0x96, 0x83, 0xa5, 0xd7, 0x2b, 0x48, 0x9e, 0x6a, 0xd4, 0x22, 0x73, 0xd5, 0x91, 0x79, 0x1d, 0x2c, 0xda, 0x73, 0x60, 0xa4, 0x0, 0x8e, 0x86, 0xc8, 0x89, 0x93, 0x69, 0x94, 0x6f, 0x7a, 0xbf, 0xe2, 0x9b, 0xf9, 0x2c, 0x9c, 0xa9, 0x65}, - output512: []byte{0xc4, 0x14, 0xb2, 0x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2, 0x51, 0xe9, 0xb2, 0xd8, 0xfe, 0x75, 0x4c, 0x47, 0x48, 0x2b, 0x72, 0xe0, 0xb3, 0x94, 0xea, 0xb7, 0x69, 0x16, 0x12, 0x6f, 0xd6, 0x8e, 0xa7, 0xd6, 0x5e, 0xb9, 0x3d, 0x59, 0xf5, 0xb4, 0xc5, 0xac, 0x40, 0xf7, 0xc3, 0xb3, 0x7e, 0x7f, 0x36, 0x94, 0xf2, 0x94, 0x24, 0xc2, 0x4a, 0xf8, 0xc8, 0xf0, 0xef, 0x59, 0xcd, 0x9d, 0xbf, 0x1d, 0x28, 0xe0, 0xe1, 0xf, 0x79, 0x9a, 0x6f, 0x78, 0xca, 0xd1, 0xd4, 0x5b, 0x9d, 0xb3, 0xd7, 0xde, 0xe4, 0xa7, 0x5, 0x9a, 0xbe, 0x99, 0x18, 0x27, 0x14, 0x98, 0x3b, 0x9c, 0x9d, 0x44, 0xd7, 0xf5, 0x64, 0x35, 0x96, 0xd4, 0xf3}, - output224: []byte{0x17, 0x53, 0x93, 0x53, 0x4d, 0x90, 0xb6, 0x14, 0xb1, 0x58, 0x10, 0x5c, 0x95, 0xe1, 0x8a, 0x10, 0x52, 0xa5, 0x6d, 0xe, 0x77, 0x5e, 0xa1, 0xcf, 0x51, 0xad, 0x58, 0x53}, - output256: []byte{0x3b, 0x40, 0xc1, 0x49, 0x3a, 0xf4, 0x11, 0xae, 0x78, 0x49, 0x90, 0x4d, 0x47, 0x8d, 0xf2, 0x40, 0x72, 0x54, 0xbf, 0x62, 0xb8, 0x8e, 0x9b, 0xff, 0xd7, 0xb4, 0x2b, 0xd2, 0xa6, 0xc, 0xe0, 0xfa}, - output384: []byte{0x91, 0x72, 0xaa, 0xd6, 0xc1, 0x5b, 0x4d, 0xcd, 0x79, 0xbb, 0xd8, 0x4f, 0xad, 0x6, 0x1, 0x11, 0x9d, 0x8b, 0x4e, 0x3a, 0xfe, 0xd1, 0x7b, 0x59, 0x4f, 0xf3, 0x84, 0x24,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 0x3d, 0xb2, 0xbc, 0x42, 0x12, 0xef, 0xf5, 0x39, 0xc6, 0x7c, 0xf1, 0x84, 0x68, 0x8, 0x26, 0x53, 0x55, 0x89, 0xc7, 0x11, 0x1d, 0x73, 0xbf, 0xfc, 0xe4, 0x31, 0xb4, 0xc4, 0x4, 0x92, 0xe7, 0x63, 0xd9, 0x27, 0x95, 0x60, 0xaa, 0xa3, 0x8e, 0xb2, 0xdc, 0x14, 0xa2, 0x12, 0xd7, 0x23, 0xf9, 0x94, 0xa1, 0xfe, 0x65, 0x6f, 0xf4, 0xdd, 0x14, 0x55, 0x1c, 0xe4, 0xe7, 0xc6, 0x21, 0xb2, 0xaa, 0x56, 0x4, 0xa1, 0x0, 0x1, 0xb2, 0x87, 0x8a, 0x89, 0x7a, 0x28, 0xa0, 0x80, 0x95, 0xc3, 0x25, 0xe1, 0xa, 0x26, 0xd2, 0xfb, 0x1a, 0x75, 0xbf, 0xd6, 0x4c, 0x25, 0x3, 0x9, 0xbb, 0x55, 0xa4, 0x4f, 0x23, 0xbb, 0xac, 0xd, 0x55, 0x16, 0xa1, 0xc6, 0x87, 0xd3, 0xb4, 0x1e, 0xf2, 0xfb, 0xbf, 0x9c, 0xc5, 0x6d, 0x47, 0x39}, - output224: []byte{0x3d, 0xec, 0xd7, 0x1d, 0xa2, 0x26, 0x39, 0x98, 0x5c, 0xf2, 0x42, 0xf2, 0xfa, 0xe7, 0x17, 0x24, 0x59, 0x4, 0x2c, 0x82, 0x64, 0x95, 0xc8, 0xd8, 0xd9, 0x5c, 0x37, 0x19}, - output256: []byte{0xfe, 0xeb, 0x17, 0x2a, 0xea, 0xb2, 0xf0, 0xde, 0xb7, 0x48, 0xfb, 0x77, 0x80, 0x1c, 0xa2, 0x2d, 0x3c, 0xe9, 0x9b, 0x7a, 0x9f, 0x97, 0x89, 0xe4, 0x79, 0xb9, 0x3d, 0x1f, 0x4b, 0x1d, 0x22, 0x7f}, - output384: []byte{0xba, 0xfb, 0xb3, 0x32, 0x1c, 0x47, 0x98, 0x54, 0x8f, 0x5d, 0xd9, 0x83, 0xea, 0xc1, 0xe1, 0x6e, 0x1f, 0x3e, 0xf2, 0xba, 0x5c, 0x9d, 0x69, 0xa3, 0x40, 0xf6, 0xca, 0xbc, 0x9c, 0x7f, 0xe9, 0xf1, 0xfd, 0x95, 0xa6, 0x92, 0xb7, 0x38, 0x73, 0x42, 0x30, 0x49, 0x45, 0x67, 0x4d, 0x9d, 0x2e, 0x4a}, - output512: []byte{0x5f, 0x49, 0xd6, 0x59, 0x4d, 0xa9, 0x39, 0x98, 0x7d, 0x19, 0x6, 0x29, 0x4b, 0x33, 0xa0, 0x37, 0xf6, 0x3c, 0x79, 0xe0, 0x78, 0x53, 0x1d, 0xfa, 0x7e, 0x6c, 0xe6, 0x72, 0x79, 0xd4, 0xd5, 0xdb, 0xeb, 0x65, 0xf, 0xf8, 0x69, 0xf, 0x23, 0xb6, 0x3b, 0x7e, 0x9c, 0x48, 0xea, 0x87, 0x91, 0xb8, 0xf, 0xdb, 0x34, 0xef, 0x66, 0xdc, 0xf0, 0xce, 0xfe, 0x45, 0x84, 0x2e, 0xcf, 0xf4, 0xad, 0x1d}}, - testcase{ - msg: []byte{0x7c, 0x79, 0x53, 0xd8, 0x1c, 0x8d, 0x20, 0x8f, 0xd1, 0xc9, 0x76, 0x81, 0xd4, 0x8f, 0x49, 0xdd, 0x0, 0x34, 0x56, 0xde, 0x60, 0x47, 0x5b, 0x84, 0x7, 0xe, 0xf4, 0x84, 0x7c, 0x33, 0x3b, 0x74, 0x57, 0x5b, 0x1f, 0xc8, 0xd2, 0xa1, 0x86, 0x96, 0x44, 0x85, 0xa3, 0xb8, 0x63, 0x4f, 0xea, 0xa3, 0x59, 0x5a, 0xaa, 0x1a, 0x2f, 0x45, 0x95, 0xa7, 0xd6, 0xb6, 0x15, 0x35, 0x63, 0xde, 0xe3, 0x1b, 0xba, 0xc4, 0x43, 0xc8, 0xa3, 0x3e, 0xed, 0x6d, 0x5d, 0x95, 0x6a, 0x98, 0xa, 0x68, 0x36, 0x6c, 0x25, 0x27, 0xb5, 0x50, 0xee, 0x95, 0x2, 0x50, 0xdf, 0xb6, 0x91, 0xea, 0xcb, 0xd5, 0xd5, 0x6a, 0xe1, 0x4b, 0x97, 0x6, 0x68, 0xbe, 0x17, 0x4c, 0x89, 0xdf, 0x2f, 0xea, 0x43, 0xae, 0x52, 0xf1, 0x31, 0x42, 0x63, 0x9c, 0x88, 0x4f, 0xd6, 0x2a, 0x36, 0x83, 0xc0, 0xc3, 0x79, 0x2f, 0xf, 0x24, 0xab, 0x13, 0x18, 0xbc, 0xb2, 0x7e, 0x21, 0xf4, 0x73, 0x7f, 0xab, 0x62, 0xc7, 0x7e, 0xa3, 0x8b, 0xc8, 0xfd, 0x1c, 0xf4, 0x1f, 0x7d, 0xab, 0x64, 0xc1, 0x3f, 0xeb, 0xe7, 0x15, 0x2b, 0xf5, 0xbb, 0x7a, 0xb5, 0xa7, 0x8f, 0x53, 0x46, 0xd4, 0x3c, 0xc7, 0x41, 0xcb, 0x6f, 0x72, 0xb7, 0xb8, 0x98, 0xf, 0x26, 0x8b, 0x68, 0xbf, 0x62, 0xab, 0xdf, 0xb1, 0x57, 0x7a, 0x52, 0x43, 0x8f, 0xe1, 0x4b, 0x59, 0x14, 0x98, 0xcc, 0x95, 0xf0, 0x71, 0x22, 0x84, 0x60, 0xc7, 0xc5, 0xd5, 0xce, 0xb4, 0xa7, 0xbd, 0xe5, 0x88, 0xe7, 0xf2, 0x1c}, - output224: []byte{0x2d, 0xa, 0x56, 0x86, 0x4b, 0xbe, 0xc6, 0x44, 0x9f, 0xbf, 0x7b, 0x2e, 0xae, 0x53, 0xda, 0x46, 0x64, 0x71, 0x83, 0xb5, 0x6f, 0xa4, 0xed, 0xb1, 0x60, 0x2e, 0x51, 0x63}, - output256: []byte{0xb2, 0x40, 0xbc, 0x52, 0xb8, 0xaf, 0x1b, 0x50, 0x2e, 0x26, 0xbf, 0x1d, 0x5e, 0x75, 0xfe, 0x26, 0x63, 0xbf, 0xba, 0x50, 0x3f, 0xaf, 0x10, 0xf4, 0x67, 0x54, 0xdc, 0x3d, 0x23, 0xcb, 0x61, 0xc1}, - output384: []byte{0xa0, 0x55, 0xe0, 0xa9, 0xc4, 0x57, 0x5c, 0xd4, 0xd7, 0xad, 0x84, 0xa2, 0x40, 0x17, 0x6f, 0x21, 0xed, 0x68, 0xf4, 0x84, 0xa2, 0x69, 0xe0, 0xc9, 0xef, 0xfb, 0x6f, 0xa9, 0x37, 0x46, 0xe3, 0x1f, 0x64, 0xb0, 0xb9, 0xc, 0x51, 0x3d, 0x2b, 0x57, 0xec, 0x78, 0xe9, 0xe5, 0xba, 0x3b, 0xa9, 0x9c}, - output512: []byte{0xb7, 0x7f, 0xb7, 0x96, 0x69, 0xea, 0x52, 0xc7, 0x38, 0xe5, 0x8a, 0x9e, 0xf3, 0xed, 0x15, 0x1, 0xbb, 0xe7, 0x97, 0x44, 0x78, 0xaf, 0xb5, 0xa8, 0xbe, 0xd4, 0x45, 0x49, 0xd6, 0x23, 0x2f, 0xf8, 0xd7, 0xaa, 0x9e, 0xee, 0xaf, 0x2, 0xf6, 0x75, 0x53, 0x27, 0x95, 0x10, 0x93, 0x24, 0x31, 0x10, 0xd7, 0xbc, 0xfc, 0xe, 0x51, 0x29, 0x9d, 0xb7, 0x93, 0x85, 0x6b, 0x57, 0xa7, 0x7e, 0x84, 0x20}}, - testcase{ - msg: []byte{0x7a, 0x6a, 0x4f, 0x4f, 0xdc, 0x59, 0xa1, 0xd2, 0x23, 0x38, 0x1a, 0xe5, 0xaf, 0x49, 0x8d, 0x74, 0xb7, 0x25, 0x2e, 0xcf, 0x59, 0xe3, 0x89, 0xe4, 0x91, 0x30, 0xc7, 0xea, 0xee, 0x62, 0x6e, 0x7b, 0xd9, 0x89, 0x7e, 0xff, 0xd9, 0x20, 0x17, 0xf4, 0xcc, 0xde, 0x66, 0xb0, 0x44, 0x4, 0x62, 0xcd, 0x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b, 0x7, 0x2b, 0x16, 0xdc, 0x4e, 0x3, 0xf9, 0xe4, 0x1, 0x9f}, - output256: []byte{0x3e, 0xba, 0xce, 0x41, 0xf5, 0x78, 0xfd, 0xe6, 0x60, 0x3e, 0x3, 0x2f, 0xc1, 0xc7, 0xcf, 0xee, 0xf1, 0xcb, 0x79, 0xfe, 0x93, 0x8a, 0x94, 0xd4, 0xc7, 0xb5, 0x8b, 0xb, 0xa4, 0xcb, 0x97, 0x20}, - output384: []byte{0x78, 0x8d, 0x19, 0xad, 0x68, 0xd1, 0xb2, 0x6c, 0xb0, 0x7, 0x83, 0x89, 0xb4, 0x5f, 0xb1, 0x8b, 0x3d, 0xa3, 0x5a, 0x57, 0xa1, 0xec, 0x91, 0x42, 0x73, 0x15, 0x8e, 0xad, 0x43, 0x74, 0x9b, 0xf1, 0xab, 0x49, 0xb1, 0xa6, 0x8d, 0x48, 0x31, 0xce, 0x19, 0x3f, 0x58, 0x52, 0xd2, 0xf, 0xd9, 0x6c}, - output512: []byte{0xca, 0xca, 0xf, 0xf4, 0x31, 0x7, 0xf7, 0x30, 0xa7, 0xfb, 0xe6, 0x86, 0x9f, 0xba, 0x5a, 0xf1, 0xe6, 0x26, 0xc9, 0x63, 0x3, 0xbe, 0x3b, 0xc9, 0x51, 0x55, 0x16, 0x41, 0x99, 0xc8, 0x89, 0x22, 0x19, 0x45, 0x11, 0xb2, 0x4c, 0x48, 0x91, 0x11, 0x86, 0xf6, 0x47, 0xca, 0x24, 0x64, 0x27, 0xf2, 0xce, 0x7b, 0xa7, 0x47, 0x27, 0x1c, 0xd8, 0xd7, 0xc5, 0xe1, 0xd1, 0x27, 0xc2, 0x1f, 0x1e, 0xaa}}, - testcase{ - msg: []byte{0xd9, 0xfa, 0xa1, 0x4c, 0xeb, 0xe9, 0xb7, 0xde, 0x55, 0x1b, 0x6c, 0x7, 0x65, 0x40, 0x9a, 0x33, 0x93, 0x85, 0x62, 0x1, 0x3b, 0x5e, 0x8e, 0xe, 0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e1, 0xa0, 0xa1, 0xc2, 0xe1, 0x70, 0xe7}, - output224: []byte{0x4f, 0xef, 0xbe, 0x74, 0x64, 0x59, 0x49, 0xa1, 0x29, 0x1c, 0x6f, 0x6f, 0x5, 0xea, 0xf4, 0xb7, 0x80, 0xea, 0x1, 0xec, 0x5e, 0xa5, 0x10, 0x5e, 0xcd, 0xcb, 0x98, 0x4a}, - output256: []byte{0x65, 0xeb, 0x4b, 0xd5, 0xec, 0xca, 0x71, 0x64, 0xce, 0x9b, 0x66, 0x72, 0x7f, 0x11, 0x2c, 0x1a, 0xc6, 0x12, 0xd, 0xdd, 0x20, 0xd, 0xcb, 0x5c, 0xe7, 0x5b, 0x74, 0x87, 0x84, 0x3f, 0xcd, 0xb8}, - output384: []byte{0x9c, 0x8a, 0x4f, 0x5b, 0xe0, 0x1a, 0xd5, 0xae, 0x9, 0x46, 0xef, 0x7e, 0x9f, 0x5a, 0x82, 0x28, 0x7b, 0x63, 0x44, 0xb9, 0x66, 0xee, 0x28, 0xbd, 0xed, 0xfe, 0x4b, 0xd4, 0x3d, 0x84, 0xd, 0x23, 0x20, 0x54, 0xd5, 0xe2, 0x16, 0x71, 0x6e, 0xa4, 0xf8, 0xb, 0x45, 0x7c, 0xbc, 0x11, 0xd, 0x1a}, - output512: []byte{0xe5, 0x10, 0x6b, 0x2a, 0xd, 0x49, 0xd6, 0xd1, 0xe1, 0x3e, 0x33, 0x23, 0x23, 0x21, 0x1, 0xce, 0xa5, 0xda, 0x71, 0xca, 0xa2, 0x4e, 0x70, 0xef, 0xca, 0xc5, 0x7e, 0xc, 0xcf, 0x15, 0x6c, 0xdf, 0x4c, 0x24, 0x92, 0xb0, 0x3c, 0xe0, 0xe1, 0x34, 0x37, 0x1, 0x8d, 0xab, 0x76, 0xb9, 0xc9, 0x89, 0x88, 0x3b, 0xea, 0x69, 0xe8, 0x49, 0xf3, 0x3b, 0xb9, 0x37, 0xa3, 0x97, 0xb8, 0x4a, 0xda, 0x6a}}, - testcase{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x6c, 0xe0, 0x5, 0xf8, 0xe8, 0xff, 0x6f, 0xe3, 0xc3, 0x80, 0x6b, 0xc2, 0xb7, 0x3c, 0x2b, 0x83, 0xaf, 0xb7, 0x4, 0x34, 0x56, 0x29, 0x30, 0x4f, 0x9f, 0x86, 0x35, 0x87, 0x12, 0xe9, 0xfa, 0xe3, 0xca, 0x3e}, - output224: []byte{0x7c, 0xc9, 0xee, 0xbb, 0xe0, 0xdf, 0x46, 0xa3, 0x98, 0x23, 0x3f, 0xa3, 0x12, 0x86, 0xf8, 0xa5, 0x30, 0x29, 0x2b, 0x53, 0xe4, 0x8b, 0xa5, 0x4b, 0x6a, 0xe4, 0x4, 0x72}, - output256: []byte{0xd7, 0x15, 0x5f, 0x6d, 0x3a, 0x90, 0x80, 0x1f, 0x5e, 0x54, 0x76, 0x89, 0x38, 0x9f, 0xf6, 0x2a, 0x60, 0x4c, 0x81, 0xb7, 0xc1, 0x58, 0x3d, 0x92, 0x4, 0xac, 0x6b, 0x1, 0x94, 0xf0, 0xe8, 0xdd}, - output384: []byte{0xa2, 0x9b, 0xcb, 0x89, 0xfd, 0x2b, 0x89, 0x0, 0x67, 0x82, 0x8, 0x8b, 0xf9, 0xa4, 0xab, 0x93, 0x9e, 0xab, 0xaf, 0xf6, 0xf4, 0xee, 0xfc, 0x31, 0xb0, 0x1a, 0x66, 0xb7, 0x3c, 0xdf, 0xb, 0x97, 0x7d, 0x94, 0x5e, 0x5, 0x1d, 0x7e, 0x9f, 0x2, 0xf1, 0x9c, 0xf3, 0x2a, 0xd4, 0xbe, 0xba, 0x6c}, - output512: []byte{0xfa, 0xee, 0x46, 0x2e, 0x4b, 0xce, 0xd1, 0x2a, 0xd5, 0x4d, 0x37, 0x57, 0xd6, 0x44, 0x39, 0x6e, 0xd9, 0x20, 0x30, 0x37, 0x74, 0x16, 0x61, 0xae, 0xa3, 0x2b, 0xcc, 0xad, 0xae, 0x56, 0x8c, 0x4b, 0xdc, 0x92, 0x5e, 0xda, 0x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x23, 0xa6, 0x8f, 0xf8, 0x0, 0x42, 0x58, 0xb9, 0x99, 0xe, 0xd3, 0x62, 0x30, 0x84, 0x61, 0x80, 0x4b, 0xa3, 0xe3, 0xa7, 0xe9, 0x2d, 0x8f, 0x2f, 0xfa, 0xe5, 0xc2, 0xfb, 0xa5, 0x5b, 0xa5, 0xa3, 0xc2, 0x7c, 0xa, 0x2f, 0x71, 0xbd, 0x71, 0x1d, 0x2f, 0xe1, 0x79, 0x9c, 0x2a, 0xdb, 0x31, 0xb2, 0x0, 0x3, 0x54, 0x81, 0xe9, 0xee, 0x5c, 0x4a, 0xdf, 0x2a, 0xb9, 0xc0, 0xfa, 0x50, 0xb2, 0x39, 0x75, 0xcf}, - output224: []byte{0x3, 0xd7, 0x18, 0xda, 0x67, 0x7c, 0x40, 0x18, 0xe5, 0x22, 0x88, 0xbb, 0x30, 0xe4, 0xe6, 0xe7, 0x32, 0xa1, 0x61, 0x44, 0x93, 0x11, 0x76, 0xf0, 0xa8, 0xc7, 0x39, 0x70}, - output256: []byte{0xaa, 0x7a, 0xda, 0xf1, 0x6f, 0x39, 0xe3, 0x98, 0xb4, 0xab, 0xa, 0xda, 0x3, 0x77, 0x10, 0x55, 0x6b, 0x72, 0xb, 0x2, 0x48, 0xd8, 0x48, 0x17, 0xb2, 0xcf, 0xdf, 0x76, 0x0, 0x93, 0x35, 0x95}, - output384: []byte{0x61, 0xd3, 0xb1, 0x37, 0x28, 0x92, 0x56, 0x46, 0x47, 0x6d, 0x67, 0xc8, 0xd6, 0x26, 0xd2, 0xec, 0xe6, 0x9d, 0x9b, 0x42, 0x50, 0x3f, 0xa6, 0xa0, 0xdf, 0x2b, 0x24, 0xa5, 0xf2, 0xab, 0xf, 0xb7, 0xd7, 0x4c, 0x2f, 0x1f, 0x7f, 0x4, 0x30, 0x4c, 0x49, 0xac, 0x94, 0xbd, 0x4e, 0x93, 0xfd, 0xa4}, - output512: []byte{0xfb, 0xe2, 0x5b, 0x43, 0xe5, 0x40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1, 0x39, 0x1a, 0x27, 0x4b, 0x22, 0xf8, 0x3c, 0xeb, 0x7, 0x2f, 0x9b, 0xca, 0xbc, 0xb, 0x21, 0x66, 0x85, 0xbf, 0xd7, 0x89, 0xf5, 0x2, 0x39, 0x71, 0x2, 0x4b, 0x18, 0x78, 0xa2, 0x5, 0x44, 0x25, 0x22, 0xf9, 0xea, 0x7d, 0x87, 0x97, 0xa4, 0x10, 0x2a, 0x3d, 0xf4, 0x17, 0x3, 0x76, 0x82, 0x51, 0xfd, 0x5e, 0x1, 0x7c, 0x85, 0xd1, 0x20, 0xa, 0x46, 0x41, 0x18, 0xaa, 0x35, 0x65, 0x4e, 0x7c, 0xa3, 0x9f, 0x3c, 0x37, 0x5b, 0x8e, 0xf8, 0xcb, 0xe7, 0x53, 0x4d, 0xbc, 0x64, 0xbc, 0x20, 0xbe, 0xfb, 0x41, 0x7c, 0xf6, 0xe, 0xc9, 0x2f, 0x63, 0xd9, 0xee, 0x73, 0x97}, - output224: []byte{0xa9, 0xab, 0xb4, 0x30, 0xfc, 0x1b, 0x3d, 0x8c, 0x6c, 0xde, 0xb5, 0x31, 0x98, 0x78, 0xe7, 0xb1, 0x2b, 0x11, 0x8e, 0x2e, 0x3, 0xf4, 0x5, 0x62, 0xa3, 0x76, 0x41, 0x8c}, - output256: []byte{0xb1, 0x95, 0x46, 0x3f, 0xe2, 0x2a, 0x16, 0x8, 0x2, 0xbe, 0xa, 0x4, 0x64, 0xee, 0x3a, 0xb4, 0xd2, 0xb1, 0x17, 0xde, 0x51, 0x7b, 0x33, 0x1c, 0x7b, 0xf0, 0x4c, 0x8b, 0xa9, 0xc, 0x61, 0x20}, - output384: []byte{0x58, 0x9a, 0xb9, 0x98, 0x1d, 0x9a, 0xbd, 0x1d, 0x71, 0x2d, 0x59, 0xc6, 0x86, 0x3d, 0x85, 0xb, 0xb1, 0xd4, 0x12, 0xd2, 0x4a, 0x96, 0x7d, 0x76, 0xcc, 0xe7, 0x8f, 0xfc, 0x99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7c, 0xe6}, - output384: []byte{0xb3, 0xcc, 0x72, 0x24, 0xa1, 0xdd, 0x20, 0x8e, 0x73, 0x9c, 0x55, 0x28, 0x23, 0x9b, 0x8d, 0x33, 0x5a, 0x12, 0x9e, 0xe2, 0xe, 0x59, 0x10, 0x26, 0x21, 0x18, 0xe, 0x6b, 0x51, 0x71, 0x4e, 0xd, 0x60, 0x7, 0x8f, 0x4e, 0x73, 0x28, 0x72, 0x64, 0x34, 0xae, 0x41, 0xca, 0x27, 0x35, 0x15, 0xba}, - output512: []byte{0xff, 0x8, 0x15, 0x7, 0xf9, 0x79, 0xf6, 0x9c, 0x67, 0x43, 0xe4, 0x2e, 0xe7, 0x58, 0x85, 0x87, 0x13, 0xb5, 0x70, 0xcb, 0x48, 0xff, 0x85, 0xef, 0xd, 0x72, 0x8c, 0x4e, 0x1b, 0xb5, 0x45, 0x6d, 0x3, 0x5e, 0x49, 0x8c, 0x5, 0xea, 0x4c, 0xeb, 0xd8, 0x20, 0xe1, 0x34, 0xbb, 0x25, 0x2a, 0xc7, 0x6b, 0xa4, 0x94, 0x9a, 0x4f, 0xad, 0x76, 0x87, 0x1a, 0x99, 0x72, 0xae, 0x2f, 0xcc, 0xce, 0xea}}, - testcase{ - msg: []byte{0x7f, 0xdf, 0xad, 0xcc, 0x9d, 0x29, 0xba, 0xd2, 0x3a, 0xe0, 0x38, 0xc6, 0xc6, 0x5c, 0xda, 0x1a, 0xef, 0x75, 0x72, 0x21, 0xb8, 0x87, 0x2e, 0xd3, 0xd7, 0x5f, 0xf8, 0xdf, 0x7d, 0xa0, 0x62, 0x7d, 0x26, 0x6e, 0x22, 0x4e, 0x81, 0x2c, 0x39, 0xf7, 0x98, 0x3e, 0x45, 0x58, 0xbf, 0xd0, 0xa1, 0xf2, 0xbe, 0xf3, 0xfe, 0xb5, 0x6b, 0xa0, 0x91, 0x20, 0xef, 0x76, 0x29, 0x17, 0xb9, 0xc0, 0x93, 0x86, 0x79, 0x48, 0x54, 0x7a, 0xee, 0x98, 0x60, 0xd, 0x10, 0xd8, 0x7b, 0x20, 0x10, 0x68, 0x78, 0xa8, 0xd2, 0x2c, 0x64, 0x37, 0x8b, 0xf6, 0x34, 0xf7, 0xf7, 0x59, 0x0, 0xc0, 0x39, 0x86, 0xb0, 0x77, 0xb0, 0xbf, 0x8b, 0x74, 0xa, 0x82, 0x44, 0x7b, 0x61, 0xb9, 0x9f, 0xee, 0x53, 0x76, 0xc5, 0xeb, 0x66, 0x80, 0xec, 0x9e, 0x30, 0x88, 0xf0, 0xbd, 0xd0, 0xc5, 0x68, 0x83, 0x41, 0x3d, 0x60, 0xc1, 0x35, 0x7d, 0x3c, 0x81, 0x19, 0x50, 0xe5, 0x89, 0xe, 0x76, 0x0, 0x10, 0x3c, 0x91, 0x63, 0x41, 0xb8, 0xc, 0x74, 0x3c, 0x6a, 0x85, 0x2b, 0x7b, 0x4f, 0xb6, 0xc, 0x3b, 0xa2, 0x1f, 0x3b, 0xc1, 0x5b, 0x83, 0x82, 0x43, 0x7a, 0x68, 0x45, 0x47, 0x79, 0xcf, 0x3c, 0xd7, 0xf9, 0xf9, 0xc, 0xcc, 0x8e, 0xf2, 0x8d, 0xb, 0x70, 0x65, 0x35, 0xb1, 0xe4, 0x10, 0x8e, 0xb5, 0x62, 0x7b, 0xb4, 0x5d, 0x71, 0x9c, 0xb0, 0x46, 0x83, 0x9a, 0xee, 0x31, 0x1c, 0xa1, 0xab, 0xdc, 0x83, 0x19, 0xe0, 0x50, 0xd6, 0x79, 0x72, 0xcb, 0x35, 0xa6, 0xb1, 0x60, 0x1b, 0x25, 0xdb, 0xf4, 0x87}, - output224: []byte{0x80, 0x8e, 0x1, 0xcd, 0x27, 0x39, 0x19, 0xba, 0x1b, 0xff, 0x1, 0x1e, 0xe, 0x70, 0x94, 0xec, 0x6d, 0x5c, 0x49, 0x62, 0x91, 0x2b, 0x8, 0xf1, 0x19, 0x65, 0xab, 0x58}, - output256: []byte{0x51, 0xde, 0x40, 0x90, 0xae, 0xc3, 0x6f, 0x6c, 0x44, 0x64, 0x76, 0xc7, 0x9, 0x25, 0x32, 0x72, 0xca, 0xb5, 0x95, 0xd9, 0x88, 0x7c, 0xa5, 0xd5, 0x2a, 0x9b, 0x38, 0x8, 0x68, 0x54, 0xd5, 0x8f}, - output384: []byte{0xd3, 0x3a, 0xd2, 0xa7, 0x1c, 0x71, 0x2a, 0x6f, 0x8a, 0xd9, 0xac, 0x92, 0x39, 0x66, 0xb4, 0xdb, 0x8c, 0x48, 0x18, 0xc7, 0x9c, 0xc6, 0xf, 0x82, 0x75, 0x36, 0x7d, 0x24, 0x52, 0xcf, 0xd2, 0xf5, 0x54, 0x2f, 0xd1, 0x88, 0x8d, 0x64, 0xc9, 0xe9, 0x12, 0xb9, 0x2a, 0x18, 0x68, 0x42, 0xb0, 0x0}, - output512: []byte{0x3, 0x44, 0x4a, 0xe8, 0x31, 0x9e, 0xbd, 0x12, 0x1e, 0x77, 0x7, 0xb9, 0xcd, 0xfd, 0x1f, 0xdf, 0xd5, 0x2f, 0x3d, 0x6b, 0x3d, 0x4b, 0xcb, 0x27, 0x48, 0xaf, 0x42, 0x1a, 0x3c, 0x86, 0x66, 0xc2, 0x2d, 0x8c, 0xd, 0x8a, 0x9, 0x67, 0x67, 0xb1, 0xcd, 0x16, 0xa8, 0xd5, 0x47, 0x38, 0xc5, 0xf6, 0x7a, 0x6f, 0x9d, 0x48, 0xc9, 0x8, 0x27, 0xbe, 0x71, 0x69, 0x1a, 0x42, 0xbe, 0x87, 0x10, 0x8b}}, - testcase{ - msg: []byte{0x98, 0x86, 0x38, 0x21, 0x9f, 0xd3, 0x9, 0x54, 0x21, 0xf8, 0x26, 0xf5, 0x6e, 0x4f, 0x9, 0xe3, 0x56, 0x29, 0x6b, 0x62, 0x8c, 0x3c, 0xe6, 0x93, 0xc, 0x9f, 0x2e, 0x75, 0x8f, 0xd1, 0xa8, 0xc, 0x82, 0x73, 0xf2, 0xf6, 0x1e, 0x4d, 0xaa, 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[]byte{0xdc, 0xbc, 0xc3, 0xb, 0x69, 0x9, 0xfd, 0xf0, 0x6, 0x50, 0xf1, 0xa1, 0xc, 0xfb, 0xbd, 0x41, 0x94, 0x8, 0xf9, 0xd3, 0x7f, 0x37, 0x8c, 0x5c, 0xa6, 0x93, 0xb8, 0x3}, - output256: []byte{0x87, 0xa1, 0x74, 0x0, 0xf9, 0x19, 0xf2, 0xf5, 0x32, 0x32, 0xb2, 0x20, 0x5e, 0x1e, 0x8b, 0x14, 0xbd, 0x56, 0x98, 0xa7, 0x6e, 0x74, 0xb9, 0xbd, 0xd5, 0x63, 0x8a, 0x5c, 0x7b, 0xa5, 0xde, 0x1e}, - output384: []byte{0xc1, 0x2d, 0x45, 0xa, 0x2, 0xc, 0xde, 0x18, 0xc2, 0x43, 0x23, 0xfb, 0x4e, 0x3f, 0xb2, 0x32, 0x55, 0x71, 0x4b, 0x1d, 0x4c, 0xbf, 0x29, 0x71, 0x9f, 0x74, 0xda, 0x5e, 0x61, 0x51, 0xfa, 0xe9, 0x1, 0xdc, 0x21, 0xa6, 0x68, 0xa, 0xd1, 0x59, 0xff, 0xb2, 0xe7, 0xc0, 0xaa, 0xab, 0xdf, 0x5b}, - output512: []byte{0x5e, 0xe0, 0xa4, 0x45, 0x97, 0x24, 0x3, 0x7b, 0x73, 0x18, 0x81, 0x5a, 0x80, 0x14, 0x7c, 0x17, 0x2d, 0x6c, 0x8f, 0x88, 0x74, 0xc9, 0xa0, 0x5, 0x77, 0x6, 0xfb, 0x3e, 0x30, 0xf, 0xe9, 0x36, 0x81, 0x5f, 0x7, 0x67, 0x2e, 0x64, 0x47, 0xb7, 0x71, 0xde, 0x69, 0x9d, 0xfa, 0xdf, 0x34, 0x5c, 0x3b, 0xb5, 0x97, 0x4c, 0xf0, 0x19, 0x31, 0x5f, 0xad, 0xd5, 0x53, 0x4d, 0xff, 0x6a, 0x7, 0x9c}}, - testcase{ - msg: []byte{0x5a, 0xab, 0x62, 0x75, 0x6d, 0x30, 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, 0x8a, 0x38, 0x46, 0xf4, 0x9d, 0x49, 0x96, 0x82, 0xb6, 0x83, 0xc4, 0xa0, 0x62, 0xb4, 0x21, 0x59, 0x4f, 0xaf, 0xbc, 0x13, 0x83, 0xc9, 0x43, 0xba, 0x83, 0xbd, 0xef, 0x51, 0x5e, 0xfc, 0xf1, 0xd}, - output224: []byte{0xbe, 0x7, 0x7f, 0x12, 0x76, 0x2e, 0xf5, 0x18, 0x59, 0xb6, 0xc5, 0x20, 0xb1, 0x92, 0x31, 0xe3, 0x4, 0x42, 0xac, 0x26, 0x8c, 0xe4, 0xfd, 0x47, 0x36, 0x6f, 0xf9, 0xf1}, - output256: []byte{0x97, 0x42, 0x53, 0x6c, 0x46, 0x1d, 0xc, 0x35, 0x3, 0xa6, 0xc9, 0x43, 0xfa, 0x81, 0x5, 0xdb, 0xcd, 0x1e, 0x54, 0x2f, 0x72, 0x8d, 0x71, 0xcc, 0xc0, 0x51, 0x7c, 0xff, 0xc2, 0x32, 0xea, 0x68}, - output384: []byte{0xe5, 0xb7, 0xa9, 0xb4, 0x1f, 0xa0, 0xce, 0xc3, 0x25, 0x2f, 0xf9, 0x50, 0x99, 0x52, 0x3d, 0xc8, 0x45, 0xc6, 0x9b, 0x67, 0xd, 0x8d, 0xfe, 0xba, 0x3e, 0x4a, 0xf6, 0xde, 0xc6, 0x59, 0xc4, 0xb2, 0xd4, 0xb0, 0x4f, 0x5f, 0x70, 0x62, 0x20, 0x94, 0x85, 0xa3, 0x7c, 0x54, 0x2c, 0xcb, 0xe7, 0xe6}, - output512: []byte{0x54, 0x8, 0x5a, 0x2f, 0x9c, 0x32, 0x7e, 0x5d, 0x8e, 0xe2, 0x25, 0xef, 0xf5, 0xbd, 0x2c, 0x28, 0x37, 0xe4, 0x4e, 0x80, 0x57, 0xcf, 0x16, 0x91, 0xe6, 0x20, 0x20, 0x50, 0x7, 0x9d, 0x26, 0x85, 0x10, 0x61, 0xc4, 0xda, 0x8d, 0x88, 0xfc, 0x19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, 0xe7, 0xf1, 0x9f, 0x30, 0x3c, 0xe4, 0xeb, 0xa0, 0x9d, 0x21, 0xe0, 0x36, 0x10, 0x20, 0x1b, 0xfc, 0x66, 0x5b, 0x72, 0x40, 0xa, 0x54, 0x7a, 0x1e, 0x0, 0xfa, 0x9b, 0x7a, 0xd8, 0xd8, 0x4f, 0x84, 0xb3, 0x4a, 0xef, 0x11, 0x85, 0x15, 0xe7, 0x4d, 0xef, 0x11, 0xb9, 0x18, 0x8b, 0xd1, 0xe1, 0xf9, 0x7d, 0x9a, 0x12, 0xc3, 0x1, 0x32, 0xec, 0x28, 0x6, 0x33, 0x9b, 0xda, 0xda, 0xcd, 0xa2, 0xfd, 0x8b, 0x78}, - output224: []byte{0x25, 0xc4, 0x25, 0x26, 0x5a, 0xb0, 0x7d, 0xa, 0x8e, 0xc6, 0x59, 0xd4, 0xd5, 0xee, 0x61, 0x8b, 0xde, 0x87, 0x0, 0x3b, 0x72, 0x55, 0xff, 0x4b, 0x53, 0x15, 0xf1, 0xc7}, - output256: []byte{0xae, 0x3b, 0xf0, 0x93, 0x64, 0x97, 0xa2, 0x95, 0x5d, 0xf8, 0x74, 0xb7, 0xf2, 0x68, 0x53, 0x14, 0xc7, 0x60, 0x60, 0x30, 0xb9, 0xc6, 0xe7, 0xbf, 0xb8, 0xa8, 0xdf, 0xf9, 0x82, 0x59, 0x57, 0xb5}, - output384: []byte{0x5e, 0x2b, 0xa5, 0x38, 0x2c, 0x35, 0x7b, 0x5a, 0x19, 0x87, 0xbd, 0xab, 0x9a, 0x2a, 0xb, 0x5, 0x3e, 0xb7, 0x5e, 0xe7, 0x70, 0xe1, 0x99, 0x4e, 0x63, 0xf, 0x24, 0x1, 0x5a, 0xb1, 0x2, 0xe4, 0x82, 0xa9, 0x5a, 0x25, 0xb6, 0x8f, 0x5d, 0xe9, 0x9f, 0xe9, 0x74, 0x8f, 0xa4, 0x8f, 0xf6, 0x96}, - output512: []byte{0x3e, 0xa4, 0x9b, 0x6a,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 0x3f, 0xf6, 0xa1, 0x92, 0xf3, 0x43, 0x29, 0x2b, 0xa2, 0xe3, 0x2a, 0xf, 0x26, 0x7f, 0x31, 0xcc, 0x26, 0x71, 0x9e, 0xb8, 0x52, 0x45, 0xd4, 0x15, 0xfb, 0x89, 0x7a, 0xc2, 0xda, 0x43, 0x3e, 0xe9, 0x1a, 0x99, 0x42, 0x4c, 0x9d, 0x7f, 0x17, 0x66, 0xa4, 0x41, 0x71, 0xd1, 0x65, 0x10, 0x1, 0xc3, 0x8f, 0xc7, 0x92, 0x94, 0xac, 0xcc, 0x68, 0xce, 0xb5, 0x66, 0x5d, 0x36, 0x21, 0x84, 0x54, 0xd3, 0xba, 0x16, 0x9a, 0xe0, 0x58, 0xa8, 0x31, 0x33, 0x8c, 0x17, 0x74, 0x36, 0x3, 0xf8, 0x1e, 0xe1, 0x73, 0xbf, 0xc0, 0x92, 0x74, 0x64, 0xf9, 0xbd, 0x72, 0x8d, 0xee, 0x94, 0xc6, 0xae, 0xab, 0x7a, 0xae, 0x6e, 0xe3, 0xa6, 0x27, 0xe8}, - output224: []byte{0x4, 0x6c, 0xf6, 0x2c, 0x41, 0xce, 0x9b, 0xf, 0x54, 0xb6, 0x67, 0x55, 0x80, 0x63, 0x2, 0x3f, 0x59, 0x88, 0x7b, 0xad, 0xa9, 0xcc, 0x28, 0x84, 0x14, 0xad, 0xee, 0x7f}, - output256: []byte{0x5f, 0xe0, 0x21, 0x6d, 0xcc, 0x1b, 0xdb, 0x48, 0xf3, 0x37, 0x5b, 0x91, 0x73, 0xb7, 0xb2, 0x32, 0x93, 0x9a, 0xa2, 0x17, 0x7c, 0x6d, 0x5, 0x6e, 0x90, 0x8c, 0x8f, 0x2b, 0x92, 0x93, 0xb0, 0x30}, - output384: []byte{0x4, 0x67, 0xc2, 0xb9, 0xf0, 0x2a, 0xf8, 0xce, 0xaf, 0x4f, 0x8f, 0xe8, 0x8d, 0x1d, 0xe3, 0xee, 0x3, 0xd7, 0x8e, 0xc2, 0x6e, 0xde, 0xe0, 0xe3, 0x4b, 0x6e, 0x7e, 0xe4, 0x9a, 0xc3, 0x57, 0xc3, 0x5a, 0x9a, 0xe3, 0x52, 0xff, 0x49, 0x32, 0xd7, 0x5e, 0x6, 0x17, 0xb8, 0xb0, 0xc6, 0x1c, 0x80}, - output512: []byte{0xb3, 0x85, 0x17, 0x90, 0xca, 0x47, 0x57, 0x5d, 0xbf, 0x98, 0x8f, 0x82, 0xc3, 0xb5, 0x1, 0xdc, 0x83, 0x90, 0xa8, 0xe8, 0x59, 0x86, 0x98, 0x16, 0x61, 0x67, 0x56, 0x7a, 0x3, 0x32, 0x91, 0x3c, 0xcc, 0x88, 0x68, 0x58, 0x4d, 0xb4, 0xac, 0xfb, 0x2c, 0x9d, 0xc0, 0xf0, 0xa6, 0x83, 0x32, 0x92, 0xf4, 0xdc, 0xed, 0xc4, 0x7c, 0xf0, 0x3, 0x21, 0x76, 0x89, 0xbc, 0x24, 0x22, 0xb5, 0x3b, 0x93}}, - testcase{ - msg: []byte{0xea, 0xcd, 0x7, 0x97, 0x1c, 0xff, 0x9b, 0x99, 0x39, 0x90, 0x3f, 0x8c, 0x1d, 0x8c, 0xbb, 0x5d, 0x4d, 0xb1, 0xb5, 0x48, 0xa8, 0x5d, 0x4, 0xe0, 0x37, 0x51, 0x4a, 0x58, 0x36, 0x4, 0xe7, 0x87, 0xf3, 0x29, 0x92, 0xbf, 0x21, 0x11, 0xb9, 0x7a, 0xc5, 0xe8, 0xa9, 0x38, 0x23, 0x35, 0x52, 0x73, 0x13, 0x21, 0x52, 0x2a, 0xb5, 0xe8, 0x58, 0x35, 0x61, 0x26, 0xb, 0x7d, 0x13, 0xeb, 0xee, 0xf7, 0x85, 0xb2, 0x3a, 0x41, 0xfd, 0x85, 0x76, 0xa6, 0xda, 0x76, 0x4a, 0x8e, 0xd6, 0xd8, 0x22, 0xd4, 0x95, 0x7a, 0x54, 0x5d, 0x52, 0x44, 0x75, 0x6c, 0x18, 0xa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 0x93, 0x4e, 0x0, 0x6e, 0xae, 0xdd, 0xbf, 0x45, 0xac, 0xbb, 0x6b, 0x38, 0x43, 0x10, 0x21}, - output384: []byte{0x87, 0xf9, 0xec, 0xb9, 0x6, 0xc9, 0xd8, 0xaa, 0xfa, 0x8d, 0xc6, 0x2a, 0xf8, 0x58, 0xc9, 0x96, 0x9, 0xa8, 0xe9, 0x59, 0xb, 0xa5, 0xbc, 0x91, 0xa8, 0x92, 0x5, 0xde, 0x44, 0xf0, 0x6a, 0xe7, 0x97, 0x6a, 0x9b, 0xe9, 0x18, 0xaa, 0xfc, 0x91, 0x34, 0xde, 0x90, 0x29, 0x11, 0x71, 0x52, 0xa1}, - output512: []byte{0xa7, 0x10, 0xcb, 0x26, 0xc6, 0x32, 0xf2, 0x89, 0x50, 0x4c, 0xd0, 0x3, 0x9b, 0xa6, 0xab, 0x9b, 0x4d, 0x35, 0x24, 0xc5, 0x2b, 0x28, 0x6d, 0x46, 0x6e, 0x2f, 0x89, 0x39, 0xf8, 0x68, 0x4e, 0x3f, 0x18, 0xdc, 0xa2, 0x98, 0xa2, 0xba, 0x67, 0xeb, 0x71, 0x9, 0x97, 0xb7, 0xbb, 0x10, 0xae, 0x27, 0x94, 0x38, 0xb9, 0xb4, 0x86, 0x8d, 0xa, 0xdb, 0x24, 0x8f, 0x28, 0x2b, 0xb4, 0x40, 0xa1, 0x30}}, - testcase{ - msg: []byte{0x23, 0xac, 0x4e, 0x9a, 0x42, 0xc6, 0xef, 0x45, 0xc3, 0x33, 0x6c, 0xe6, 0xdf, 0xc2, 0xff, 0x7d, 0xe8, 0x88, 0x4c, 0xd2, 0x3d, 0xc9, 0x12, 0xfe, 0xf0, 0xf7, 0x75, 0x6c, 0x9, 0xd3, 0x35, 0xc1, 0x89, 0xf3, 0xad, 0x3a, 0x23, 0x69, 0x7a, 0xbd, 0xa8, 0x51, 0xa8, 0x18, 0x81, 0xa0, 0xc8, 0xcc, 0xaf, 0xc9, 0x80, 0xab, 0x2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0x42, 0xca, 0xc1, 0xa0, 0x45, 0xa, 0xd, 0x7e, 0x2e, 0xdc, 0x63, 0xed, 0x87, 0xbf, 0x10, 0x9c, 0x50, 0x9c, 0x79, 0x87}, - output256: []byte{0x4c, 0xa8, 0xb7, 0xfe, 0xbd, 0xf0, 0xa8, 0x6, 0x2e, 0x9b, 0x76, 0x18, 0x5c, 0xf4, 0x16, 0x50, 0x71, 0xbb, 0x30, 0x92, 0x8c, 0x18, 0xf1, 0x43, 0x38, 0xc3, 0x5, 0x62, 0x67, 0x89, 0xc6, 0xd3}, - output384: []byte{0x51, 0xc, 0xb4, 0x84, 0xb6, 0xd4, 0xb4, 0x7a, 0x59, 0xf, 0x62, 0x11, 0xc7, 0xf3, 0x35, 0x92, 0x24, 0x6a, 0x2e, 0x5, 0xa1, 0xc6, 0x92, 0x58, 0xb6, 0xcf, 0x9a, 0x24, 0xc1, 0xa3, 0xaf, 0xc2, 0x52, 0x78, 0x41, 0xae, 0x3f, 0xcd, 0x55, 0x2e, 0x51, 0x3, 0xdd, 0x24, 0x74, 0x3a, 0xc6, 0xb3}, - output512: []byte{0x8f, 0x67, 0x7a, 0x80, 0x89, 0x5, 0x2b, 0x47, 0xbe, 0x60, 0xc0, 0xbb, 0x76, 0x66, 0xe4, 0x3, 0xa5, 0xda, 0xa5, 0xe2, 0x8a, 0x2b, 0x63, 0x2f, 0x2e, 0x49, 0x6c, 0x58, 0x7f, 0x1f, 0xdc, 0xa0, 0xee, 0x33, 0xd9, 0xe7, 0x8d, 0xaa, 0x4e, 0xf5, 0x75, 0xb1, 0x33, 0x89, 0x74, 0x8b, 0x8c, 0x24, 0x11, 0x0, 0x53, 0xb0, 0xb9, 0x6a, 0x8, 0x2c, 0x6, 0xc3, 0xf8, 0xe, 0xbe, 0x8d, 0xe9, 0x76}}, - testcase{ - msg: []byte{0x1, 0x72, 0xdf, 0x73, 0x22, 0x82, 0xc9, 0xd4, 0x88, 0x66, 0x9c, 0x35, 0x8e, 0x34, 0x92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0x86, 0x40, 0x54, 0x9a, 0x22, 0xcb, 0x23, 0xc7, 0x31, 0xac, 0xe7, 0x43, 0x25, 0x2a, 0x82, 0x27, 0xa0, 0xd2, 0x68, 0x9d, 0x4c, 0x60, 0x1, 0x60, 0x66, 0x78, 0xdf, 0xb9, 0x21}, - output224: []byte{0xcb, 0x40, 0x83, 0x7d, 0xaf, 0x4a, 0x88, 0x25, 0x38, 0x46, 0x4d, 0xec, 0xa, 0x99, 0x9d, 0xa4, 0x82, 0xb4, 0xaa, 0xe0, 0x87, 0x8, 0xea, 0x6d, 0x5d, 0x7f, 0xf4, 0x61}, - output256: []byte{0x23, 0xd2, 0x61, 0x44, 0x20, 0x85, 0x9b, 0x2f, 0x13, 0xac, 0x8, 0x44, 0x53, 0xdd, 0x35, 0xc3, 0x3f, 0xe4, 0x7c, 0x89, 0x4d, 0xd5, 0xc, 0x8, 0x7f, 0xd1, 0x65, 0x3f, 0xca, 0xee, 0xa0, 0xb}, - output384: []byte{0x3, 0xf3, 0xbb, 0x45, 0xfd, 0x70, 0x96, 0x6a, 0xc5, 0xef, 0xd9, 0x59, 0x8c, 0x48, 0xe, 0xd6, 0x77, 0xc8, 0x6c, 0x7c, 0xf0, 0xb, 0x10, 0x26, 0x1a, 0xe6, 0x79, 0xc, 0x52, 0x79, 0xa5, 0xe4, 0x73, 0x86, 0xf3, 0xd3, 0x17, 0x26, 0xd9, 0xcb, 0x61, 0x9b, 0x92, 0xa7, 0x9c, 0xca, 0xe2, 0x5c}, - output512: []byte{0xce, 0x63, 0x1e, 0x6f, 0x2c, 0x2d, 0xc5, 0x73, 0x8c, 0xf, 0xa9, 0x58, 0x57, 0x17, 0x73, 0xb5, 0x8a, 0xf1, 0x30, 0xb9, 0x48, 0x24, 0x33, 0x14, 0x19, 0xee, 0x57, 0xe2, 0x69, 0x1c, 0xe5, 0xf2, 0x9d, 0xb3, 0xd8, 0xfe, 0x45, 0x6c, 0xd1, 0xe7, 0xcd, 0xc0, 0x7f, 0x61, 0x5, 0xfa, 0x1b, 0x6f, 0xd7, 0x29, 0xc2, 0xb4, 0x19, 0x0, 0x8c, 0xcd, 0x88, 0x91, 0x69, 0xc3, 0x38, 0x5d, 0xb1, 0xb9}}, - testcase{ - msg: []byte{0x38, 0x75, 0xb9, 0x24, 0xc, 0xf3, 0xe0, 0xa8, 0xb5, 0x9c, 0x65, 0x85, 0x40, 0xf2, 0x6a, 0x70, 0x1c, 0xf1, 0x88, 0x49, 0x6e, 0x2c, 0x21, 0x74, 0x78, 0x8b, 0x12, 0x6f, 0xd2, 0x94, 0x2, 0xd6, 0xa7, 0x54, 0x53, 0xba, 0x6, 0x35, 0x28, 0x4d, 0x8, 0x83, 0x5f, 0x40, 0x5, 0x1a, 0x2a, 0x96, 0x83, 0xdc, 0x92, 0xaf, 0xb9, 0x38, 0x37, 0x19, 0x19, 0x12, 0x31, 0x17, 0x3, 0x79, 0xba, 0x6f, 0x4a, 0xdc, 0x81, 0x6f, 0xec, 0xbb, 0xf, 0x9c, 0x44, 0x6b, 0x78, 0x5b, 0xf5, 0x20, 0x79, 0x68, 0x41, 0xe5, 0x88, 0x78, 0xb7, 0x3c, 0x58, 0xd3, 0xeb, 0xb0, 0x97, 0xce, 0x47, 0x61, 0xfd, 0xea, 0xbe, 0x15, 0xde, 0x2f, 0x31, 0x9d, 0xfb, 0xaf, 0x17, 0x42, 0xcd, 0xeb, 0x38, 0x95, 0x59, 0xc7, 0x88, 0x13, 0x1a, 0x67, 0x93, 0xe1, 0x93, 0x85, 0x66, 0x61, 0x37, 0x6c, 0x81, 0xce, 0x95, 0x68, 0xda, 0x19, 0xaa, 0x69, 0x25, 0xb4, 0x7f, 0xfd, 0x77, 0xa4, 0x3c, 0x7a, 0xe, 0x75, 0x8c, 0x37, 0xd6, 0x92, 0x54, 0x90, 0x9f, 0xf0, 0xfb, 0xd4, 0x15, 0xef, 0x8e, 0xb9, 0x37, 0xbc, 0xd4, 0x9f, 0x91, 0x46, 0x8b, 0x49, 0x97, 0x4c, 0x7, 0xdc, 0x81, 0x9a, 0xbd, 0x67, 0x39, 0x5d, 0xb0, 0xe0, 0x58, 0x74, 0xff, 0x83, 0xdd, 0xda, 0xb8, 0x95, 0x34, 0x4a, 0xbd, 0xe, 0x71, 0x11, 0xb2, 0xdf, 0x9e, 0x58, 0xd7, 0x6d, 0x85, 0xad, 0x98, 0x10, 0x6b, 0x36, 0x29, 0x58, 0x26, 0xbe, 0x4, 0xd4, 0x35, 0x61, 0x55, 0x95, 0x60, 0x5e, 0x4b, 0x4b, 0xb8, 0x24, 0xb3, 0x3c, 0x4a, 0xfe, 0xb5, 0xe7, 0xbb, 0xd, 0x19, 0xf9, 0x9}, - output224: []byte{0xea, 0xe9, 0x11, 0xe6, 0x66, 0x61, 0xdc, 0xd3, 0x47, 0x2b, 0x45, 0x8a, 0x48, 0xb7, 0x47, 0x30, 0x46, 0x89, 0x23, 0xc7, 0xab, 0xca, 0xc7, 0xf3, 0x11, 0xf0, 0x24, 0x63}, - output256: []byte{0x55, 0x90, 0xbb, 0x75, 0x24, 0x7d, 0x7c, 0xd0, 0xb3, 0x56, 0x20, 0xf0, 0x6, 0x2b, 0x90, 0xff, 0xb2, 0xa2, 0x4d, 0xe4, 0x12, 0x20, 0xed, 0x62, 0x9d, 0x9e, 0x9a, 0x7a, 0xbc, 0xad, 0xfb, 0x51}, - output384: []byte{0x68, 0xa4, 0x7c, 0x7d, 0x12, 0x4e, 0x8a, 0xea, 0x5c, 0xfe, 0xef, 0x7a, 0x9d, 0x8c, 0xa7, 0xaa, 0x8d, 0xf6, 0xee, 0xe6, 0x65, 0x2d, 0xe3, 0xa3, 0x85, 0x23, 0x1f, 0x29, 0xbc, 0x4b, 0x98, 0x3a, 0xec, 0x8a, 0xf2, 0xa6, 0x13, 0x29, 0xb6, 0x4b, 0xb5, 0x9a, 0x45, 0xb7, 0x7a, 0x38, 0xe4, 0xdf}, - output512: []byte{0xff, 0xf6, 0x77, 0xbb, 0x58, 0x90, 0x9c, 0x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0x42, 0x37, 0x98, 0xaf, 0x77, 0x51, 0x7e, 0xbc, 0x55, 0x39, 0x2f, 0xcd, 0x1, 0xfc, 0x60, 0xd, 0x8d, 0x46, 0x6b, 0x9e, 0x7a, 0x7a, 0x85, 0xbf, 0x33, 0xf9, 0xcc, 0x54, 0x19, 0xe9, 0xbd, 0x87, 0x4d, 0xdf, 0xd6, 0x9, 0x81, 0x15, 0xd, 0xda, 0xf8, 0xd7, 0xfe, 0xba, 0xa4, 0x37, 0x4f, 0x8, 0x72, 0xa5, 0x62, 0x8d, 0x31, 0x80, 0x0, 0x31, 0x1e, 0x2f, 0x56, 0x55, 0x36, 0x5a, 0xd4, 0xd4, 0x7, 0xc2, 0xe, 0x5c, 0x4, 0xdf, 0x17, 0xa2, 0x22, 0xe7, 0xde, 0xec, 0x79, 0xc5, 0xab, 0x11, 0x16, 0xd8, 0x57, 0x2f, 0x91, 0xcd, 0x6, 0xe1, 0xcc, 0xc7, 0xce, 0xd5, 0x37, 0x36, 0xfc, 0x86, 0x7f, 0xd4, 0x9e, 0xce, 0xbe, 0x6b, 0xf8, 0x8, 0x2e, 0x8a}, - output224: []byte{0x30, 0x7d, 0x5a, 0x8b, 0xa5, 0x86, 0x5a, 0x4d, 0x28, 0x1a, 0xcb, 0x2f, 0x3c, 0x5e, 0xf1, 0x6e, 0x3b, 0x11, 0xbc, 0xd8, 0xc0, 0xf8, 0x2d, 0x22, 0xd4, 0x7c, 0x2c, 0xc8}, - output256: []byte{0xe5, 0x93, 0x24, 0x41, 0xb0, 0x12, 0xe5, 0x3, 0xb0, 0xb0, 0xc6, 0x10, 0x47, 0x3, 0xba, 0x2, 0x61, 0x3e, 0x47, 0x2a, 0xd6, 0x56, 0x55, 0xc0, 0x85, 0xb0, 0xad, 0xb0, 0x76, 0x56, 0xb2, 0x8f}, - output384: []byte{0xdd, 0x3b, 0xba, 0x1b, 0x4f, 0x84, 0x93, 0xe0, 0x63, 0x91, 0x51, 0xd9, 0x30, 0x38, 0x35,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17, 0x74, 0xf9, 0x7d, 0xb5, 0xd9, 0xac, 0xf1, 0xdf, 0xfa, 0xfb, 0x66, 0x2c, 0x1, 0xed, 0x29, 0x1a, 0x44, 0x2b, 0xec, 0x6f, 0x14, 0xd1, 0x33, 0x46, 0x99}, - output384: []byte{0x50, 0xd3, 0xb0, 0x2a, 0xc7, 0xb9, 0x7, 0xb3, 0x10, 0xc1, 0xc0, 0x10, 0x5e, 0xb4, 0x7f, 0x6d, 0xcf, 0x3a, 0xf0, 0xe4, 0x73, 0x78, 0x5d, 0xaa, 0x54, 0xd8, 0x3, 0x7a, 0x9a, 0x3e, 0x74, 0xa5, 0xd1, 0xa4, 0x1d, 0x81, 0x12, 0x2, 0xf1, 0xe3, 0xc8, 0xa1, 0x40, 0x17, 0x3d, 0x92, 0xf6, 0xf}, - output512: []byte{0xf9, 0xd6, 0xad, 0x86, 0x86, 0x12, 0x5e, 0x71, 0xfe, 0x8, 0x56, 0xe8, 0x6, 0xd6, 0x8b, 0xa9, 0x7e, 0xf1, 0x23, 0x44, 0x39, 0x38, 0xd2, 0x82, 0x83, 0x38, 0x7f, 0x33, 0xe3, 0xac, 0x6e, 0x2a, 0x7d, 0xe0, 0x42, 0xa3, 0xee, 0x5f, 0x79, 0x94, 0xc1, 0xee, 0xcc, 0x5b, 0x6f, 0x22, 0xcb, 0xae, 0x13, 0x49, 0xca, 0xb2, 0xfb, 0x7a, 0xa, 0x1, 0x25, 0xec, 0x23, 0x20, 0x32, 0x8, 0x58, 0xd4}}, - testcase{ - msg: []byte{0x4, 0xe1, 0x6d, 0xed, 0xc1, 0x22, 0x79, 0x2, 0xba, 0xaf, 0x33, 0x2d, 0x3d, 0x8, 0x92, 0x36, 0x1, 0xbd, 0xd6, 0x4f, 0x57, 0x3f, 0xaa, 0x1b, 0xb7, 0x20, 0x19, 0x18, 0xcf, 0xe1, 0x6b, 0x1e, 0x10, 0x15, 0x1d, 0xae, 0x87, 0x5d, 0xa0, 0xc0, 0xd6, 0x3c,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xa8, 0x1c, 0x6f, 0xbf}, - output224: []byte{0xbc, 0x29, 0x6f, 0xfd, 0x39, 0x38, 0x1c, 0xf1, 0xc9, 0x62, 0x28, 0xa9, 0xf3, 0x80, 0xf4, 0x1c, 0x87, 0x1b, 0x87, 0x88, 0xc6, 0x54, 0xed, 0x9b, 0x38, 0x4c, 0x17, 0xfe}, - output256: []byte{0xd, 0x1e, 0x6b, 0xb8, 0x81, 0x88, 0xb4, 0x9a, 0xf0, 0xa9, 0xa0, 0x5e, 0xb1, 0xaf, 0x94, 0x25, 0x5e, 0x67, 0x99, 0x51, 0x5a, 0x2f, 0x8e, 0xb4, 0x6a, 0xa6, 0xaf, 0x9a, 0x9d, 0xd5, 0xb9, 0xe0}, - output384: []byte{0xa6, 0xbb, 0xae, 0x1f, 0xf8, 0xe0, 0xd, 0xce, 0x34, 0xf6, 0x40, 0xce, 0xe2, 0xcd, 0xb5, 0xbc, 0xfe, 0x43, 0x82, 0x76, 0x1b, 0xe3, 0x6a, 0x94, 0xe, 0x50, 0xee, 0xc1, 0x2b, 0x5c, 0x2a, 0x2, 0xb2, 0xb6, 0xbe, 0x18, 0xa7, 0xc8, 0x7a, 0x36, 0xfd, 0x21, 0x94, 0xc4, 0xd2, 0x43, 0xec, 0x38}, - output512: []byte{0xf2, 0x6f, 0x32, 0x68, 0xfd, 0x62, 0xf, 0xc4, 0x76, 0xa4, 0x9a, 0xac, 0x3e, 0xd1, 0x58, 0x8, 0x64, 0x93, 0x4a, 0x2f, 0x6b, 0xa8, 0x81, 0xed, 0x8c, 0x8f, 0xb7, 0x57, 0xaa, 0xaa, 0x64, 0xbc, 0xdf, 0x50, 0x1e, 0x19, 0x13, 0xde, 0x60, 0xb, 0xbe, 0xf6, 0xf1, 0x2c, 0x94, 0x9f, 0xea, 0x8f, 0xd6, 0x8c, 0x64, 0x50, 0x86, 0xd5, 0xe3, 0xc, 0x92, 0x53, 0x58, 0x8f, 0xfb, 0xd1, 0x9b, 0xe5}}, - testcase{ -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0xde, 0xa1, 0xab, 0x4c, 0xba, 0x4d, 0x89, 0xf5, 0xfc, 0x7a, 0xe2, 0xf2, 0x1c, 0xcd, 0x27, 0xf6, 0x11, 0xec, 0xa4, 0x62, 0x6b, 0x2d, 0x8, 0xdc, 0x22, 0x38, 0x2e, 0x92, 0xc1, 0xef, 0xb2, 0xf6, 0xaf, 0xdc, 0x8f, 0xdc, 0x3d, 0x21, 0x72, 0x60, 0x4f, 0x50, 0x35, 0xc4, 0x6b, 0x81, 0x97, 0xd3}, - output224: []byte{0xc, 0xce, 0xae, 0x71, 0x3e, 0x5e, 0x39, 0xbc, 0xef, 0xe7, 0xa2, 0x27, 0x30, 0x4, 0x81, 0x6f, 0xe0, 0x5, 0xd5, 0xed, 0xfb, 0x2a, 0x96, 0x5c, 0xc9, 0xac, 0x99, 0x48}, - output256: []byte{0x93, 0x5d, 0xed, 0x24, 0xf5, 0xce, 0xcc, 0x69, 0xe1, 0xf0, 0x12, 0xb6, 0xb, 0x78, 0x31, 0xab, 0xce, 0x7e, 0xf5, 0xe, 0xeb, 0xb, 0xea, 0x7f, 0x81, 0x6c, 0x3d, 0xbf, 0x2b, 0x4a, 0xbd, 0xc1}, - output384: []byte{0x7e, 0xd8, 0x3e, 0xb6, 0x59, 0x53, 0x6b, 0x36, 0x6, 0x17, 0x73, 0x7, 0x3b, 0x14, 0x8e, 0xd2, 0x11, 0x75, 0x12, 0x37, 0x2e, 0x49, 0xe0, 0xa3, 0xae, 0xe4, 0x8b, 0x96, 0x35, 0x3e, 0xc9, 0x36, 0xb3, 0x26, 0x88, 0xb1, 0x50, 0xc5, 0x85, 0x94, 0x4d, 0x20, 0x8, 0xf2, 0x13, 0x66, 0xb5, 0x31}, - output512: []byte{0x8, 0x8, 0x45, 0xd6, 0xfd, 0x22, 0xa0, 0xb, 0x30, 0xfa, 0x1, 0xa4, 0xb4, 0xf8, 0x1f, 0xdc, 0x7b, 0x46, 0xca, 0x4c, 0x6a, 0x67, 0x6a, 0xd5, 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, 0xaa, 0x5e, 0x69, 0x2a, 0x0, 0xf8, 0x22, 0xa2, 0xab, 0x9a, 0x2f, 0xe6, 0x3, 0x50, 0xd7, 0x5e, 0x7b, 0xe1, 0x6f, 0xf2, 0x52, 0x6d, 0xc6, 0x43, 0x87, 0x25, 0x2, 0xd0, 0x1f, 0x42, 0xf1, 0x88, 0xab, 0xed, 0xa, 0x6e, 0x9a, 0x6f, 0x5f, 0xd0, 0xd1, 0xce, 0x7d, 0x57, 0x55, 0xc9, 0xff, 0xa6, 0x6b, 0xa, 0xf0, 0xb2, 0xb, 0xd8, 0x6, 0xf0, 0x8e, 0x6, 0x15, 0x66, 0x90, 0xd8, 0x1a, 0xc8, 0x11, 0x77, 0x8c, 0xa3, 0xda, 0xc2, 0xc2, 0x49, 0xb9, 0x60, 0x2, 0x1, 0x7f, 0xce, 0x93, 0xe5, 0x7, 0xe3, 0xb9, 0x53, 0xac, 0xf9, 0x99, 0x64, 0xb8, 0x47}, - output224: []byte{0x79, 0x97, 0xfd, 0xf3, 0x8, 0x37, 0xd8, 0xb2, 0x5e, 0x85, 0xfc, 0x1, 0x31, 0x6e, 0x31, 0xb6, 0x1e, 0xe8, 0x14, 0x49, 0xd, 0xa0, 0x2, 0xa0, 0x48, 0x16, 0xd7, 0xca}, - output256: []byte{0x67, 0x55, 0xbf, 0x7e, 0x60, 0xe4, 0xe0, 0x79, 0x65, 0xba, 0xc2, 0x4e, 0x51, 0xb1, 0xde, 0x93, 0xe3, 0xdd, 0x42, 0xae, 0x78, 0xf, 0x25, 0x66, 0x47, 0xd4, 0xcc, 0x2e, 0xf8, 0xef, 0xf7, 0x71}, - output384: []byte{0x25, 0x16, 0xe0, 0x1, 0x5e, 0xd1, 0x62, 0x7, 0x32, 0x38, 0x99, 0x6d, 0x5a, 0x3, 0x23, 0x90, 0x87, 0xe0, 0x1c, 0x20, 0x91, 0xf7, 0xb0, 0x36, 0x37, 0xe6, 0xc8, 0x9a, 0x75, 0x8f, 0x56, 0x5e,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 0x38, 0x75, 0x93, 0x80, 0x3b, 0x18, 0x7, 0x48, 0x2b, 0x13, 0x7b, 0x45, 0x9}, - output384: []byte{0x6b, 0xae, 0x42, 0xad, 0xd0, 0x6c, 0x6a, 0x20, 0xa0, 0x5d, 0x84, 0x5e, 0x7b, 0xf3, 0x91, 0xf1, 0xea, 0xb8, 0x3e, 0x83, 0xa7, 0x10, 0xa1, 0x85, 0x27, 0xfc, 0x3, 0x64, 0x61, 0x4, 0xe5, 0x2a, 0x8b, 0x41, 0x7c, 0xff, 0x37, 0x57, 0x53, 0x88, 0x20, 0x81, 0xf3, 0x1b, 0x6f, 0x22, 0x95, 0xeb}, - output512: []byte{0xaa, 0x3, 0xeb, 0x9, 0x41, 0x74, 0x35, 0xda, 0x9e, 0x6e, 0x78, 0x3, 0xf3, 0xb6, 0xea, 0xb6, 0x6f, 0xaa, 0x3d, 0x59, 0xcc, 0x62, 0x29, 0x50, 0xd6, 0x1f, 0x9b, 0x96, 0x2b, 0x69, 0x14, 0x5a, 0xc2, 0x25, 0x5c, 0xd7, 0x52, 0xcb, 0x96, 0x7, 0x74, 0x20, 0x92, 0x69, 0x7b, 0x1a, 0x79, 0xd1, 0x24, 0x81, 0x7a, 0xe2, 0x64, 0x21, 0xe6, 0x1d, 0x11, 0x76, 0x76, 0x48, 0x32, 0xed, 0x35, 0x4c}}, - testcase{ - msg: []byte{0x3a, 0x12, 0xf8, 0x50, 0x8b, 0x40, 0xc3, 0x2c, 0x74, 0x49, 0x2b, 0x66, 0x32, 0x33, 0x75, 0xdc, 0xfe, 0x49, 0x18, 0x4c, 0x78, 0xf7, 0x31, 0x79, 0xf3, 0x31, 0x4b, 0x79, 0xe6, 0x33, 0x76, 0xb8, 0xac, 0x68, 0x3f, 0x5a, 0x51, 0xf1, 0x53, 0x4b, 0xd7, 0x29, 0xb0, 0x2b, 0x4, 0xd0, 0x2, 0xf5, 0x5c, 0xbd, 0x8e, 0x8f, 0xc9, 0xb5, 0xec, 0x1e, 0xa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, 0xf, 0xbc, 0x4b, 0xdf, 0xb1, 0x4a, 0xec, 0x8c, 0x7b, 0x9a, 0xa8, 0x82, 0xba, 0x3e, 0xb2, 0xaa, 0xcc, 0x9a, 0x15, 0xd7, 0xd3, 0x6d, 0xba, 0x8, 0x6d}, - output256: []byte{0x99, 0x27, 0xfa, 0x5e, 0xfd, 0x86, 0x30, 0x4e, 0x73, 0xd5, 0x4a, 0xa4, 0x92, 0x88, 0x18, 0xc0, 0x5b, 0x1, 0x50, 0x46, 0x72, 0xc5, 0x29, 0x47, 0x13, 0x94, 0xa8, 0x2e, 0x4, 0x9e, 0x5f, 0x95}, - output384: []byte{0x14, 0x69, 0xd, 0xdb, 0x5a, 0x48, 0xfd, 0xf3, 0x82, 0xdb, 0xc7, 0x45, 0xad, 0x3, 0x30, 0xc1, 0x48, 0x61, 0x24, 0xf6, 0xad, 0x2e, 0x5a, 0xe4, 0xa8, 0x50, 0xe3, 0x8c, 0x26, 0x4f, 0x99, 0xae, 0xae, 0x6f, 0x15, 0x60, 0x62, 0xab, 0x19, 0x46, 0xdd, 0x7, 0xaf, 0xe1, 0x70, 0xa, 0x82, 0x94}, - output512: []byte{0xd3, 0x1, 0x2f, 0x2f, 0xb5, 0x68, 0x45, 0xb2, 0x58, 0xd7, 0x59, 0x8c, 0xb, 0xbb, 0x2c, 0x97, 0xd5, 0x3b, 0x60, 0x2d, 0xea, 0xe9, 0x32, 0x6d, 0xc3, 0x67, 0x8b, 0x22, 0x28, 0x45, 0x4a, 0x1e, 0x29, 0xf2, 0x88, 0x48, 0xed, 0x14, 0xc, 0x70, 0xbe, 0x85, 0xcd, 0xea, 0x9f, 0x99, 0xa8, 0xdc, 0x34, 0x7d, 0xea, 0xbd, 0x46, 0xd3, 0x62, 0xed, 0x1a, 0xfb, 0x23, 0x11, 0x46, 0xa0, 0x25, 0x5d}}, - testcase{ - msg: []byte{0x18, 0x61, 0xed, 0xce, 0x46, 0xfa, 0x5a, 0xd1, 0x7e, 0x1f, 0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 0x51, 0x19, 0xeb, 0xa4, 0x9c, 0x71, 0xd4, 0x9b, 0x9f, 0xe3, 0xf1, 0x56, 0x9f, 0xa2, 0x4e, 0x5c, 0xa3, 0xe3, 0x32, 0xd0, 0x42, 0x42, 0x2a, 0x8b, 0x81, 0x58, 0xd3, 0xec, 0x66, 0xa8, 0x0, 0x12, 0x97, 0x6f, 0x31, 0xff, 0xdf, 0x30, 0x5f, 0xc, 0x9c, 0x5e}, - output224: []byte{0x54, 0x5e, 0x59, 0x81, 0x2c, 0x7a, 0xea, 0x1b, 0xd1, 0xcd, 0x48, 0x88, 0xd, 0x66, 0x50, 0x11, 0x7d, 0xfd, 0x9e, 0x58, 0xa7, 0x91, 0xda, 0xc1, 0x7, 0x2b, 0x19, 0xda}, - output256: []byte{0x84, 0xe0, 0x56, 0xbf, 0x7b, 0xdf, 0xc7, 0x3a, 0x3a, 0xaa, 0x95, 0xb0, 0xa, 0x74, 0xa1, 0x36, 0xd7, 0x76, 0x6, 0x9b, 0xee, 0xb3, 0x4, 0x42, 0x3b, 0xea, 0xd9, 0x1, 0x20, 0xdb, 0x63, 0x50}, - output384: []byte{0x9d, 0xa6, 0x65, 0x2b, 0xa8, 0x90, 0x0, 0x7a, 0x1, 0x12, 0x6f, 0xf, 0x65, 0x97, 0xa, 0xbf, 0x34, 0x74, 0xc7, 0x65, 0x9c, 0x6c, 0x80, 0xb0, 0x4d, 0xa2, 0xca, 0x59, 0x2e, 0xdf, 0xf, 0x39, 0x96, 0x1, 0xbc, 0xd, 0xad, 0x10, 0xa0, 0xdd, 0x6e, 0x31, 0x6a, 0x28, 0x6e, 0x23, 0x38, 0xef}, - output512: []byte{0xb5, 0xc, 0x89, 0x6f, 0x2c, 0xdf, 0x7f, 0x10, 0x5d, 0xe7, 0x51, 0xff, 0x6c, 0xf6, 0x64, 0xe5, 0x92, 0xfa, 0xb7, 0x52, 0xd6, 0x52, 0xb0, 0x68, 0x98, 0xb9, 0xb2, 0x88, 0x5, 0x2d, 0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0x61, 0x7e, 0xec, 0xf1, 0xb6, 0x40, 0x47, 0x4a, 0x5d, 0x45, 0xcf, 0xde, 0x9f, 0x4d, 0x3e, 0xf9, 0x2d, 0x6d, 0x5, 0x5b, 0x90, 0x98, 0x92, 0x19, 0x4d, 0x8a, 0x82, 0x18, 0xdb, 0x6d, 0x82, 0x3, 0xa8, 0x42, 0x61, 0xd2, 0x0, 0xd7, 0x14, 0x73, 0xd7, 0x48, 0x8f, 0x34, 0x27, 0x41, 0x6b, 0x68, 0x96, 0xc1, 0x37, 0xd4, 0x55, 0xf2, 0x31, 0x7, 0x1c, 0xac, 0xbc, 0x86, 0xe0, 0x41, 0x5a, 0xb8, 0x8a, 0xec, 0x84, 0x1d, 0x96, 0xb7, 0xb8, 0xaf, 0x41, 0xe0, 0x5b, 0xb4, 0x61, 0xa4, 0x6, 0x45, 0xbf, 0x17, 0x66, 0x1, 0xf1, 0xe7, 0x60, 0xde, 0x5f}, - output224: []byte{0x7c, 0x2f, 0xa0, 0x9, 0x61, 0xbc, 0xf0, 0x20, 0xb9, 0x5a, 0xe, 0xd7, 0x19, 0x3e, 0xa3, 0x58, 0x33, 0x40, 0xbb, 0xd3, 0x78, 0x98, 0xef, 0x6a, 0x46, 0x4c, 0x19, 0x40}, - output256: []byte{0x40, 0x1c, 0x3b, 0xe5, 0x9c, 0xc3, 0x73, 0x45, 0x3a, 0xef, 0x96, 0x3, 0xf7, 0x33, 0x5c, 0x1d, 0x5f, 0xe6, 0x69, 0x90, 0x9a, 0x14, 0x25, 0xd7, 0x67, 0x1d, 0xcb, 0x84, 0xa4, 0x98, 0x87, 0xca}, - output384: []byte{0xb9, 0x4d, 0x57, 0x8d, 0xe7, 0x9a, 0x43, 0x7b, 0xea, 0xd9, 0x51, 0xe9, 0xae, 0xe9, 0x12, 0x54, 0xd, 0x1, 0x39, 0x96, 0x5c, 0xf0, 0x14, 0x2f, 0x1f, 0xd4, 0x3, 0x53, 0x49, 0x59, 0xb7, 0x5d, 0x11, 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0xda, 0xa3, 0xa0, 0xcc, 0x90, 0x45, 0x16, 0xf9, 0xa4, 0x3a, 0xf6, 0x60, 0x31, 0x53, 0x85, 0x17, 0x8a, 0x52, 0x9e, 0x51, 0xf8, 0xaa, 0xe1, 0x41, 0x80, 0x8c, 0x8b, 0xc5, 0xd7, 0xb6, 0xc, 0xac, 0x26, 0xbb, 0x98, 0x4a, 0xc1, 0x89, 0xd, 0x4, 0x36, 0xef, 0x78, 0x4, 0x26, 0xc5, 0x47, 0xe9, 0x4a, 0x7b, 0x8, 0xf0, 0x1a, 0xcb, 0xfc, 0x4a, 0x38, 0x25, 0xea, 0xe0, 0x4f, 0x52, 0xa, 0x90, 0x16, 0xf2, 0xfb, 0x8b, 0xf5, 0x16, 0x5e, 0xd1, 0x27, 0x36, 0xfc, 0x71, 0xe3, 0x6a, 0x49, 0xa7, 0x36, 0x14, 0x73, 0x9e, 0xaa, 0x3e, 0xc8, 0x34, 0x6, 0x9b, 0x1b, 0x40, 0xf1, 0x35, 0xc, 0x2b, 0x3a, 0xb8, 0x85, 0xc0, 0x2c, 0x64, 0xb, 0x9f, 0x76, 0x86, 0xed, 0x5f, 0x99, 0x52, 0x7e, 0x41, 0xcf, 0xcd, 0x79, 0x6f, 0xe4, 0xc2, 0x56, 0xc9, 0x17, 0x31, 0x86, 0xc2, 0x26, 0x16, 0x9f, 0xf2, 0x57, 0x95, 0x4e, 0xbd, 0xa8, 0x1c, 0xe, 0x5f, 0x99}, - output224: []byte{0x23, 0x2d, 0xb2, 0x2e, 0xb2, 0xc1, 0x91, 0x9, 0xaf, 0xef, 0xb7, 0x19, 0x18, 0xea, 0x2d, 0xaa, 0x7c, 0xd, 0x76, 0x65, 0x2e, 0x18, 0x84, 0xea, 0x7a, 0x8a, 0xe6, 0x46}, - output256: []byte{0x2, 0x4, 0x85, 0xdc, 0xd2, 0x64, 0x29, 0x6a, 0xfd, 0xb7, 0xf6, 0x43, 0xca, 0x82, 0x8c, 0x93, 0x35, 0x6f, 0x17, 0x14, 0xcb, 0xcc, 0x2f, 0xbb, 0xdd, 0x30, 0xf9, 0x89, 0x6c, 0x3f, 0x27, 0x89}, - output384: []byte{0xb8, 0x5f, 0x56, 0xf6, 0x9d, 0x3b, 0xe5, 0x7a, 0x1c, 0x2a, 0xa5, 0x53, 0xf9, 0xb, 0xc1, 0xb0, 0x89, 0xe8, 0xf1, 0xc5, 0x61, 0x88, 0x1b, 0xe6, 0x46, 0x30, 0xea, 0x6b, 0xa4, 0xdd, 0x3b, 0xd5, 0x30, 0x15, 0x12, 0x31, 0x3a, 0x18, 0xc2, 0x6d, 0xf3, 0xe9, 0x7e, 0x5, 0x6a, 0x59, 0xed, 0xcf}, - output512: []byte{0xdd, 0x5f, 0x4b, 0x16, 0x71, 0x75, 0xd9, 0x56, 0x6d, 0xca, 0x6c, 0x5b, 0x1b, 0x54, 0xa3, 0x3d, 0x2, 0xef, 0xd0, 0x2e, 0x25, 0xe2, 0x3b, 0xb6, 0xfb, 0x2, 0xd8, 0x78, 0xa4, 0x41, 0x5e, 0x5e, 0x86, 0x82, 0xc2, 0x9, 0xbe, 0xac, 0x4, 0xe9, 0x88, 0x2a, 0x27, 0x2d, 0x1, 0xe8, 0xeb, 0x43, 0x5c, 0xaa, 0x5b, 0xcd, 0x74, 0xfc, 0x82, 0x5c, 0x6b, 0x90, 0x82, 0xd0, 0x41, 0xdf, 0xf3, 0x33}}, - testcase{ - msg: []byte{0x5f, 0xce, 0x81, 0x9, 0xa3, 0x58, 0x57, 0xe, 0x40, 0x98, 0x3e, 0x11, 0x84, 0xe5, 0x41, 0x83, 0x3b, 0xb9, 0x9, 0x1e, 0x28, 0xf, 0x25, 0x8c, 0xfb, 0x14, 0x43, 0x87, 0xb0, 0x5d, 0x19, 0xe, 0x43, 0x1c, 0xb1, 0x9b, 0xaa, 0x67, 0x27, 0x3b, 0xa0, 0xc5, 0x8a, 0xbe, 0x91, 0x30, 0x8e, 0x18, 0x44, 0xdc, 0xd0, 0xb3, 0x67,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, 0x7a, 0x17, 0x2d}, - output224: []byte{0xdb, 0x85, 0xaf, 0x5c, 0xfc, 0xe7, 0x46, 0x24, 0xe, 0x6d, 0x44, 0xe7, 0x3c, 0xef, 0x66, 0xa7, 0x2c, 0xe5, 0x96, 0x82, 0x84, 0xd3, 0x5f, 0xfe, 0xf7, 0xfb, 0xff, 0x6c}, - output256: []byte{0xf8, 0xc4, 0x3e, 0x28, 0x81, 0x6b, 0xb4, 0x19, 0x93, 0xbd, 0xb8, 0x66, 0x88, 0x8f, 0x3c, 0xc5, 0x9e, 0xfb, 0xa2, 0x8, 0x39, 0x1, 0x44, 0xd3, 0x87, 0x8d, 0xbf, 0x9f, 0xbf, 0xa1, 0xd5, 0x7e}, - output384: []byte{0x7d, 0x95, 0x8, 0xfb, 0x79, 0x58, 0x11, 0xea, 0x14, 0x42, 0xdb, 0x3e, 0xcb, 0x77, 0x9c, 0xb0, 0x49, 0x47, 0x36, 0xe7, 0x12, 0x3b, 0x25, 0x2c, 0xf8, 0x8a, 0x9a, 0xb, 0x50, 0xd5, 0x7c, 0xf0, 0xb, 0x87, 0xa6, 0xc4, 0xfa, 0xc2, 0x7f, 0x82, 0x1c, 0xd5, 0x59, 0x79, 0xd5, 0x86, 0xaa, 0x39}, - output512: []byte{0xa4, 0x3a, 0xe5, 0xda, 0xd9, 0x36, 0x69, 0x75, 0x64, 0xae, 0x1b, 0xd9, 0xb8, 0x62, 0x4c, 0x5c, 0x31, 0xcc, 0x36, 0x60, 0x73, 0x22, 0xaf, 0x40, 0xe2, 0x53, 0xf1, 0xc, 0x28, 0x54, 0x67, 0xaf, 0xd0, 0xd0, 0x82, 0x52, 0xd2, 0xba, 0xd7, 0x6e, 0xfa, 0x52, 0xe4, 0x77, 0x5c, 0x9c, 0x26, 0x76, 0x1a, 0xbe, 0x38, 0x21, 0x28, 0x55, 0xa8, 0x1, 0x12, 0xfe, 0x2, 0x62, 0x3f, 0xbf, 0xa, 0x13}}, - testcase{ - msg: []byte{0x61, 0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 0xb1, 0xa5, 0x69, 0x6b, 0x2, 0x3f, 0x39, 0xab, 0x7a, 0xb5, 0xf2, 0x8d, 0xf4, 0x20, 0x29, 0x36, 0xbc, 0x97, 0x39, 0x3b, 0x93, 0xbc, 0x91, 0x5c, 0xb1, 0x59, 0xea, 0x1b, 0xd7, 0xa0, 0xa4, 0x14, 0xcb, 0x4b, 0x7a, 0x1a, 0xc3, 0xaf, 0x68, 0xf5, 0xd, 0x79, 0xf0, 0xc9, 0xc7, 0x31, 0x4e, 0x75, 0xf, 0x7d, 0x2, 0xfa, 0xa5, 0x8b, 0xfa}, - output224: []byte{0xa1, 0xeb, 0x42, 0xfb, 0x7, 0x92, 0x36, 0x1f, 0xd, 0x68, 0x9, 0xa2, 0xe8, 0xdc, 0x6, 0x2f, 0x9, 0xf2, 0x85, 0x5b, 0x39, 0xbc, 0x2c, 0x4b, 0x7f, 0x54, 0x31, 0x1e}, - output256: []byte{0x4e, 0xa5, 0x24, 0xe7, 0x5, 0x2, 0x2, 0x84, 0xb1, 0x82, 0x84, 0xe3, 0x46, 0x83, 0x72, 0x55, 0x90, 0xe1, 0xee, 0x56, 0x5a, 0x6f, 0xf5, 0x98, 0xed, 0x4d, 0x42, 0xb1, 0xc9, 0x87, 0x47, 0x1e}, - output384: []byte{0xaf, 0xd9, 0x4b, 0x6, 0x1f, 0x35, 0x4b, 0x4, 0xd0, 0x71, 0x83, 0x26, 0xd7, 0xe1, 0xa, 0x6b, 0x59, 0x8c, 0xe3, 0x1c, 0xc3, 0x9c, 0x52, 0xd2, 0x65, 0xd6, 0xcf, 0x4, 0xe4, 0xd9, 0xee, 0x75, 0xcc, 0x20, 0x1, 0x49, 0x36, 0x76, 0x0, 0x31, 0x2e, 0x75, 0x14, 0xa6, 0x2f, 0xf, 0x9, 0x64}, - output512: []byte{0xa5, 0xac, 0x23, 0xd4, 0xa0, 0xd5, 0x33, 0xcb, 0x9d, 0x8a, 0x68, 0x87, 0x3f, 0x5c, 0xb7, 0x49, 0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, 0x1b, 0x32, 0xd1, 0xe4, 0x6c, 0x90, 0x9e, 0x62, 0x6e, 0xd2, 0xda, 0xe9, 0x20, 0xf4, 0xc7, 0xdb, 0xeb, 0x63, 0x5b, 0xc7, 0x54, 0xfa, 0xcb, 0xd8, 0xd4, 0x9b, 0xeb, 0xa3, 0xf2, 0x3c, 0x1c, 0x41, 0xcc, 0xbf, 0xcd, 0xe, 0xe0, 0xc1, 0x14, 0xe6, 0x97, 0x37, 0xf5, 0x59, 0x7c, 0xb, 0xf1, 0xd8, 0x59, 0xf0, 0xc7, 0x67, 0xe1, 0x80, 0x2, 0xae, 0x8e, 0x39, 0xc2, 0x62, 0x61, 0xff, 0xde, 0x29, 0x20, 0xd3, 0xd0, 0xba, 0xf0, 0xe9, 0x6, 0x13, 0x86, 0x96, 0xcf, 0xe5, 0xb7, 0xe3, 0x2b, 0x60, 0xf, 0x45, 0xdf, 0x3a, 0xaa, 0x39, 0x93, 0x2f, 0x3a, 0x7d, 0xf9, 0x5b, 0x60, 0xfa, 0x87, 0x12, 0xa2, 0x27, 0x1f, 0xca, 0xf3, 0x91, 0x1c, 0xe7, 0xb5, 0x11, 0xb1}, - output224: []byte{0x1a, 0xf4, 0xa3, 0xab, 0x9a, 0x7, 0xcf, 0x6, 0x4c, 0x25, 0x4d, 0x12, 0x2c, 0xc7, 0xde, 0x15, 0xe0, 0xf0, 0xd3, 0xca, 0x3d, 0xfa, 0x50, 0xea, 0x1c, 0x43, 0xa7, 0x8d}, - output256: []byte{0xe4, 0x96, 0x3e, 0x74, 0xae, 0x1, 0xff, 0x77, 0x74, 0xb9, 0x6b, 0x4f, 0x61, 0x4d, 0x1c, 0xb2, 0xa4, 0xcf, 0x8d, 0x20, 0x6e, 0xd9, 0x3c, 0x66, 0xfa, 0x42, 0xf7, 0x14, 0x32, 0xbe, 0x2c, 0x3f}, - output384: []byte{0xec, 0x63, 0xce, 0x9d, 0xd9, 0x79, 0xfc, 0xd1, 0x32, 0x24, 0x4b, 0xe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8, 0x7f, 0x64, 0xf0, 0xf1, 0xd6, 0x21}, - output256: []byte{0xf, 0xd, 0x72, 0xbf, 0x8c, 0x1, 0x98, 0x45, 0x9e, 0x45, 0xec, 0xe9, 0xcc, 0x18, 0xe9, 0x30, 0xcb, 0x86, 0x26, 0x3a, 0xcc, 0xf1, 0xfc, 0x7a, 0x0, 0xbc, 0x85, 0x7a, 0xc9, 0xf2, 0x1, 0xad}, - output384: []byte{0x86, 0x30, 0x1f, 0xe9, 0x8f, 0x3f, 0xfa, 0xbb, 0xc, 0xb0, 0x8, 0x5a, 0xaa, 0x1e, 0xc6, 0x1b, 0xca, 0xd6, 0x17, 0x14, 0x59, 0xa8, 0x62, 0x3b, 0xb7, 0x80, 0xec, 0x32, 0xe4, 0x6f, 0x52, 0x64, 0x99, 0x46, 0xa4, 0x21, 0xeb, 0xfc, 0x7d, 0xe9, 0xf, 0xe, 0x74, 0xec, 0x78, 0x7a, 0x3e, 0x3}, - output512: []byte{0x13, 0xa5, 0x92, 0xb7, 0x3e, 0xde, 0x48, 0x70, 0x36, 0xc8, 0x81, 0x6b, 0xd6, 0xfc, 0x6c, 0xdc, 0x4, 0xdc, 0x61, 0x33, 0x40, 0x9a, 0x6e, 0xe9, 0x90, 0x58, 0x41, 0x60, 0x51, 0x8f, 0x9e, 0xf5, 0x73, 0x26, 0x4c, 0xf0, 0x4d, 0x38, 0xa3, 0xba, 0x75, 0xd1, 0x50, 0xf4, 0xf0, 0x26, 0xf6, 0xdf, 0x89, 0x36, 0xe1, 0x3c, 0x8f, 0x4f, 0x3e, 0xcc, 0x9e, 0xcb, 0xc4, 0x3f, 0xdf, 0xc4, 0x88, 0xa4}}, - testcase{ - msg: []byte{0x2e, 0xdc, 0x28, 0x2f, 0xfb, 0x90, 0xb9, 0x71, 0x18, 0xdd, 0x3, 0xaa, 0xa0, 0x3b, 0x14, 0x5f, 0x36, 0x39, 0x5, 0xe3, 0xcb, 0xd2, 0xd5, 0xe, 0xcd, 0x69, 0x2b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0xfe, 0xcf, 0xd5, 0x3b, 0x8e, 0xf9, 0x58, 0xef, 0x10, 0xee, 0x6, 0x8, 0xb7, 0xf5, 0xcb, 0x99, 0x23, 0xad, 0x97, 0x5, 0x8e, 0xc0, 0x67, 0x70, 0xc, 0xc7, 0x46, 0xc1, 0x27, 0xa6, 0x1e, 0xe3}, - output224: []byte{0x11, 0x6c, 0x4, 0x62, 0xd5, 0xd, 0x57, 0xf9, 0x48, 0x1, 0x5e, 0xc7, 0x4b, 0xe9, 0x1, 0x57, 0x7, 0x31, 0x37, 0x12, 0xb4, 0x58, 0x83, 0xc0, 0x2f, 0xe8, 0x4e, 0x1e}, - output256: []byte{0xdd, 0x1d, 0x2a, 0x92, 0xb3, 0xf3, 0xf3, 0x90, 0x2f, 0x6, 0x43, 0x65, 0x83, 0x8e, 0x1f, 0x5f, 0x34, 0x68, 0x73, 0xc, 0x34, 0x3e, 0x29, 0x74, 0xe7, 0xa9, 0xec, 0xfc, 0xd8, 0x4a, 0xa6, 0xdb}, - output384: []byte{0xdd, 0xf8, 0xd5, 0x47, 0xbb, 0xa4, 0xf4, 0x3d, 0x88, 0x64, 0xca, 0xef, 0x1b, 0x1b, 0xed, 0x77, 0xaa, 0x12, 0xe4, 0x1f, 0x68, 0x86, 0xa5, 0xd8, 0x75, 0x8c, 0x65, 0x4b, 0x7e, 0xc1, 0xfa, 0x5b, 0xe, 0x77, 0xba, 0x4e, 0x76, 0x80, 0xc7, 0x83, 0xd, 0xa1, 0x61, 0xe1, 0x4c, 0xb1, 0xe6, 0x5c}, - output512: []byte{0xc2, 0xfb, 0x59, 0xa, 0xb7, 0x4e, 0x23, 0xb, 0x8f, 0xe1, 0x59, 0x89, 0x2f, 0x94, 0xde, 0x4, 0xef, 0x7a, 0xda, 0xa0, 0x2b, 0x91, 0x8d, 0x49, 0x94, 0xf9, 0x96, 0x53, 0x8d, 0x25, 0x7f, 0x5a, 0x80, 0xc9, 0xb3, 0xbe, 0x8f, 0x41, 0x1, 0x70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, 0xcf, 0x0, 0xe2, 0xb1, 0x6a, 0x6c, 0x49, 0x17, 0x14, 0x33, 0xb0, 0xaa, 0xdf, 0xd8, 0x2, 0x31, 0x27, 0x65, 0x60, 0xb8, 0x4, 0x58, 0xdd, 0x77, 0x8, 0x9b, 0x7a, 0x1b, 0xbc, 0xc9, 0xe7, 0xe4, 0xb9, 0xf8, 0x81, 0xea, 0xcd, 0x6c, 0x92, 0xc4, 0x31, 0x83, 0x48, 0xa1, 0x3f, 0x49, 0x14, 0xeb, 0x27, 0x11, 0x5a, 0x1c, 0xfc, 0x5d, 0x16, 0xd7, 0xfd, 0x94, 0x95, 0x4c, 0x35, 0x32, 0xef, 0xac, 0xa2, 0xca, 0xb0, 0x25, 0x10, 0x3b, 0x2d, 0x2, 0xc6, 0xfd, 0x71, 0xda, 0x3a, 0x77, 0xf4, 0x17, 0xd7, 0x93, 0x26, 0x85, 0x88, 0x8a}, - output224: []byte{0x96, 0xf7, 0x11, 0x11, 0x76, 0x64, 0x1f, 0x63, 0x73, 0x70, 0x1b, 0xa5, 0x94, 0x9, 0x0, 0x79, 0x14, 0x6d, 0x42, 0x20, 0xf3, 0xb, 0x51, 0x20, 0xc1, 0x24, 0x98, 0xba}, - output256: []byte{0x21, 0xbf, 0x20, 0x66, 0x4c, 0xec, 0x2c, 0xd2, 0xce, 0xb1, 0xdf, 0xfc, 0x1d, 0x78, 0x89, 0x3d, 0x5c, 0xa1, 0xa7, 0xda, 0x88, 0xeb, 0x6b, 0xfd, 0xc, 0x6e, 0xfc, 0xa6, 0x19, 0xc, 0x9e, 0x15}, - output384: []byte{0x72, 0x95, 0x3f, 0xe4, 0xca, 0x34, 0xe7, 0x17, 0xe3, 0x4, 0xdc, 0x77, 0xaf, 0xd9, 0xde, 0xde, 0x32, 0xa8, 0x46, 0x71, 0x27, 0xb9, 0xf7, 0x8b, 0xb0, 0xbe, 0x61, 0x91, 0xa7, 0xec, 0xd0, 0x51, 0xb7, 0xda, 0xe0, 0x91, 0x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7, 0x17, 0x2b, 0x42, 0x1a, 0xf, 0xb6, 0x39, 0x8a, 0x28, 0x23, 0xdd, 0x2f, 0x2b, 0x26, 0x20, 0x8a, 0xf8, 0x94, 0x2e}, - output384: []byte{0xf3, 0x6a, 0x9e, 0xe4, 0x55, 0x6, 0x6e, 0x56, 0x2f, 0xb6, 0x75, 0xf3, 0x99, 0xd9, 0xdc, 0xc6, 0xbc, 0xcf, 0x68, 0xfd, 0x1b, 0xb, 0xa9, 0xf7, 0xdc, 0xc1, 0xed, 0xfa, 0xc1, 0xf1, 0xe2, 0x34, 0xcb, 0x67, 0xb5, 0xa0, 0xf7, 0x70, 0xe5, 0x54, 0x35, 0xf7, 0x5f, 0x9e, 0xc8, 0x4a, 0x91, 0x51}, - output512: []byte{0x5a, 0xa4, 0xe3, 0x2f, 0xe, 0xa3, 0xe8, 0x53, 0x92, 0x9b, 0xf6, 0x4a, 0xcc, 0x95, 0x65, 0xa0, 0x13, 0x0, 0xbc, 0x0, 0x70, 0x63, 0xb9, 0x39, 0xf6, 0xdb, 0xbe, 0x9c, 0xae, 0x5, 0x45, 0xea, 0x95, 0xfb, 0xca, 0xc3, 0x25, 0x75, 0xaa, 0x7, 0x27, 0xee, 0x4d, 0x93, 0x70, 0x71, 0xe6, 0xb3, 0xbe, 0x74, 0xe2, 0x3f, 0xe7, 0x6f, 0xd6, 0x3e, 0xc0, 0x5c, 0x7f, 0x7d, 0x8a, 0x40, 0x7a, 0xf0}}, - testcase{ - msg: []byte{0x72, 0x16, 0x45, 0x63, 0x3a, 0x44, 0xa2, 0xc7, 0x8b, 0x19, 0x2, 0x4e, 0xae, 0xcf, 0x58, 0x57, 0x5a, 0xb2, 0x3c, 0x27, 0x19, 0x8, 0x33, 0xc2, 0x68, 0x75, 0xdc, 0xf, 0xd, 0x50, 0xb4, 0x6a, 0xea, 0x9c, 0x34, 0x3d, 0x82, 0xea, 0x7d, 0x5b, 0x3e, 0x50, 0xec, 0x70, 0x5, 0x45, 0xc6, 0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21, 0xe4, 0xf7, 0x48, 0xfb, 0x8a, 0x51, 0xf4, 0x47, 0x50, 0xe2, 0x13, 0xa8, 0xfb}, - output224: []byte{0x54, 0xcc, 0x87, 0xb9, 0x65, 0x51, 0x80, 0xc0, 0xe1, 0xc6, 0x67, 0x23, 0x50, 0xae, 0x19, 0x52, 0xdd, 0xf5, 0x1e, 0xe5, 0xd7, 0xe2, 0x15, 0x56, 0x96, 0x52, 0xaa, 0x2e}, - output256: []byte{0x2a, 0xc7, 0xff, 0x80, 0xee, 0x36, 0xd5, 0x0, 0x99, 0x5c, 0x97, 0x3b, 0x87, 0x46, 0xd8, 0x46, 0x67, 0x15, 0xe6, 0xd8, 0xb0, 0xf5, 0x54, 0xaa, 0xcb, 0x5d, 0x28, 0x76, 0xd7, 0xf5, 0xb8, 0x74}, - output384: []byte{0x37, 0x36, 0x8f, 0x5a, 0x7, 0x4d, 0xa0, 0xe5, 0x7, 0x58, 0x45, 0xf7, 0x6b, 0x1a, 0xc5, 0x85, 0x8d, 0xf7, 0x93, 0xee, 0xf8, 0x8a, 0x85, 0x4c, 0x7d, 0xaf, 0xe3, 0xb9, 0x7, 0x20, 0x70, 0x7a, 0x14, 0x5a, 0x5d, 0xcb, 0xd, 0x92, 0x66, 0xc6, 0x14, 0x82, 0x4, 0xce, 0x69, 0x3c, 0x54, 0x32}, - output512: []byte{0x49, 0x5b, 0x2a, 0xa2, 0x10, 0x31, 0x59, 0xd9, 0xa9, 0x37, 0xe9, 0xdd, 0x56, 0xb0, 0x59, 0xac, 0xa9, 0x8a, 0x5e, 0x3c, 0xb7, 0xb5, 0x9b, 0xb6, 0x90, 0xde, 0xdc, 0x0, 0xc6, 0x92, 0xe9, 0xd7, 0xa1, 0x86, 0x14, 0xa7, 0x3d, 0x12, 0xe0, 0x76, 0x34, 0xb2, 0x9, 0xcc, 0x63, 0xd, 0x18, 0x18, 0xb0, 0x9f, 0x10, 0x76, 0xa9, 0x41, 0xff, 0x80, 0x47, 0x44, 0x93,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ff, 0x20, 0xed, 0x87, 0x58, 0xf4, 0xc2, 0xf, 0xe7, 0x59, 0xef, 0xb3, 0x31, 0x41, 0xcf, 0xe, 0x89, 0x25, 0x87, 0xfe, 0x81, 0x87, 0xe5, 0xfb, 0xc5, 0x77, 0x86, 0xb7, 0xe8, 0xb0, 0x89, 0x61, 0x2c, 0x93, 0x6d, 0xfc, 0x3, 0xd2, 0x7e, 0xfb, 0xbe, 0x7c, 0x86, 0x73, 0xf1, 0x60, 0x6b, 0xd5, 0x1d, 0x5f, 0xf3, 0x86, 0xf4, 0xa7, 0xab, 0x68, 0xed, 0xf5, 0x9f, 0x38, 0x5e, 0xb1, 0x29, 0x1f, 0x11, 0x7b, 0xfe, 0x71, 0x73, 0x99}, - output224: []byte{0x46, 0x29, 0xc9, 0x7f, 0x9b, 0xa9, 0x86, 0x98, 0xe0, 0xdd, 0xec, 0xa5, 0xe0, 0xa3, 0xb6, 0xde, 0x21, 0xe, 0xa9, 0xe8, 0x4b, 0xf9, 0x42, 0xc2, 0xcc, 0xf4, 0xec, 0x68}, - output256: []byte{0x9f, 0xf8, 0x1d, 0x57, 0x5f, 0x7b, 0xf0, 0xc4, 0xef, 0x34, 0xb, 0x42, 0x79, 0xd5, 0x6e, 0x16, 0xce, 0x68, 0x82, 0x1a, 0xfc, 0xdf, 0x2a, 0x69, 0x10, 0x5d, 0x4f, 0x9c, 0xad, 0xad, 0xd3, 0xcf}, - output384: []byte{0xda, 0xac, 0x83, 0xb0, 0xc5, 0xc8, 0xf8, 0xfc, 0x3b, 0xcc, 0xd2, 0x59, 0xc2, 0x7d, 0x96, 0x46, 0x73, 0xb4, 0xdc, 0xa7, 0x90, 0xb4, 0xb6, 0x38, 0x99, 0xe1, 0xb6, 0xc1, 0x9c, 0xc2, 0x91, 0xfe, 0x6f, 0x88, 0x37, 0x62, 0x81, 0xe0, 0xfa, 0x32, 0xa, 0xdf, 0xad, 0xc8, 0x2a, 0x8f, 0xf4, 0xef}, - output512: []byte{0x21, 0x7b, 0x5a, 0x98, 0x5b, 0xed, 0x80, 0x0, 0x82, 0x74, 0x47, 0xe, 0x25, 0x44, 0x43, 0x23, 0x8c, 0x5a, 0xea, 0xcb, 0xc7, 0xee, 0x22, 0x89, 0xf0, 0xe6, 0x3b, 0x7a, 0xfe, 0x6d, 0xf, 0x39, 0x5e, 0x23, 0x61, 0xfd, 0x6d, 0x9d, 0xc3, 0x3b, 0x4f, 0x54, 0xf0, 0x3f, 0xf5, 0x6f, 0x6b, 0x26, 0x49, 0x76, 0x16, 0x1d, 0x80, 0x9, 0x17, 0x88, 0xee, 0x9d, 0x26, 0x2f, 0x14, 0x7a, 0x35, 0xfc}}, - testcase{ - msg: []byte{0x6a, 0x1, 0x83, 0xa, 0xf3, 0x88, 0x9a, 0x25, 0x18, 0x32, 0x44, 0xde, 0xcb, 0x50, 0x8b, 0xd0, 0x12, 0x53, 0xd5, 0xb5, 0x8, 0xab, 0x49, 0xd, 0x31, 0x24, 0xaf, 0xbf, 0x42, 0x62, 0x6b, 0x2e, 0x70, 0x89, 0x4e, 0x9b, 0x56, 0x2b, 0x28, 0x8d, 0xa, 0x24, 0x50, 0xcf, 0xac, 0xf1, 0x4a, 0xd, 0xda, 0xe5, 0xc0, 0x47, 0x16, 0xe5, 0xa0, 0x8, 0x2c, 0x33, 0x98, 0x1f, 0x60, 0x37, 0xd2, 0x3d, 0x5e, 0x4, 0x5e, 0xe1, 0xef, 0x22, 0x83, 0xfb, 0x8b, 0x63, 0x78, 0xa9, 0x14, 0xc5, 0xd9, 0x44, 0x16, 0x27, 0xa7, 0x22, 0xc2, 0x82, 0xff, 0x45, 0x2e, 0x25, 0xa7, 0xea, 0x60, 0x8d, 0x69, 0xce, 0xe4, 0x39, 0x3a, 0x7, 0x25, 0xd1, 0x79, 0x63, 0xd0, 0x34, 0x26, 0x84, 0xf2, 0x55, 0x49, 0x6d, 0x8a, 0x18, 0xc2, 0x96, 0x11, 0x45, 0x31, 0x51, 0x30, 0x54, 0x93, 0x11, 0xfc, 0x7, 0xf0, 0x31, 0x2f, 0xb7, 0x8e, 0x60, 0x77, 0x33, 0x4f, 0x87, 0xea, 0xa8, 0x73, 0xbe, 0xe8, 0xaa, 0x95, 0x69, 0x89, 0x96, 0xeb, 0x21, 0x37, 0x5e, 0xb2, 0xb4, 0xef, 0x53, 0xc1, 0x44, 0x1, 0x20, 0x7d, 0xeb, 0x45, 0x68, 0x39, 0x8e, 0x5d, 0xd9, 0xa7, 0xcf, 0x97, 0xe8, 0xc9, 0x66, 0x3e, 0x23, 0x33, 0x4b, 0x46, 0x91, 0x2f, 0x83, 0x44, 0xc1, 0x9e, 0xfc, 0xf8, 0xc2, 0xba, 0x6f, 0x4, 0x32, 0x5f, 0x1a, 0x27, 0xe0, 0x62, 0xb6, 0x2a, 0x58, 0xd0, 0x76, 0x6f, 0xc6, 0xdb, 0x4d, 0x2c, 0x6a, 0x19, 0x28, 0x60, 0x4b, 0x1, 0x75, 0xd8, 0x72, 0xd1, 0x6b, 0x79, 0x8, 0xeb, 0xc0, 0x41, 0x76, 0x11, 0x87, 0xcc, 0x78, 0x55, 0x26, 0xc2, 0xa3, 0x87, 0x3f, 0xea, 0xc3, 0xa6, 0x42, 0xbb, 0x39, 0xf5, 0x35, 0x15, 0x50, 0xaf, 0x97, 0x70, 0xc3, 0x28, 0xaf, 0x7b}, - output224: []byte{0xf4, 0x50, 0x34, 0xaa, 0x94, 0xc1, 0xa2, 0x68, 0x6e, 0xb8, 0x49, 0xef, 0x42, 0x62, 0xf2, 0xf5, 0xba, 0x9a, 0xcd, 0xd0, 0xe8, 0xea, 0x32, 0x40, 0x1e, 0x6, 0xb, 0x43}, - output256: []byte{0x9, 0xed, 0xc4, 0x65, 0xd4, 0xfd, 0x91, 0xc5, 0xe8, 0x6b, 0x29, 0x2f, 0x4, 0x1b, 0xcc, 0x17, 0x57, 0x1e, 0x1f, 0x2e, 0x17, 0xd5, 0x84, 0xdf, 0xf2, 0x1d, 0xd7, 0xdd, 0x8d, 0x8b, 0xff, 0x35}, - output384: []byte{0x35, 0x72, 0x58, 0xfa, 0x65, 0x79, 0x86, 0x7c, 0xc0, 0x8, 0x9c, 0x8b, 0x3c, 0x93, 0xce, 0x10, 0x67, 0x7a, 0x5a, 0xd4, 0xdb, 0xee, 0xe2, 0xa2, 0x7c, 0xea, 0x90, 0x31, 0x7a, 0xce, 0xbe, 0x72, 0x54, 0x50, 0x54, 0x68, 0x87, 0x5b, 0xcb, 0x33, 0x4e, 0xb, 0x6f, 0x70, 0xcf, 0xe5, 0x90, 0x82}, - output512: []byte{0x29, 0x3c, 0x55, 0x1e, 0x75, 0x3b, 0xba, 0x7f, 0x31, 0x4d, 0xcb, 0x93, 0xa0, 0xfa, 0xd9, 0x4f, 0x3f, 0x5d, 0xee, 0x6e, 0xd4, 0x5d, 0x76, 0x5a, 0x70, 0x8e, 0x6f, 0xd2, 0x77, 0x60, 0x1f, 0x3, 0xf6, 0xc9, 0x5, 0xd7, 0xe1, 0xea, 0xea, 0xec, 0x51, 0x3c, 0xbb, 0xbd, 0x67, 0x2b, 0x81, 0x7f, 0x6d, 0x60, 0xfb, 0xf0, 0x2c, 0x20, 0x16, 0x7d, 0x7f, 0x4b, 0x7b, 0x84, 0xaf, 0xee, 0xb3, 0xf6}}, - testcase{ - msg: []byte{0xb3, 0xc5, 0xe7, 0x4b, 0x69, 0x93, 0x3c, 0x25, 0x33, 0x10, 0x6c, 0x56, 0x3b, 0x4c, 0xa2, 0x2, 0x38, 0xf2, 0xb6, 0xe6, 0x75, 0xe8, 0x68, 0x1e, 0x34, 0xa3, 0x89, 0x89, 0x47, 0x85, 0xbd, 0xad, 0xe5, 0x96, 0x52, 0xd4, 0xa7, 0x3d, 0x80, 0xa5, 0xc8, 0x5b, 0xd4, 0x54, 0xfd, 0x1e, 0x9f, 0xfd, 0xad, 0x1c, 0x38, 0x15, 0xf5, 0x3, 0x8e, 0x9e, 0xf4, 0x32, 0xaa, 0xc5, 0xc3, 0xc4, 0xfe, 0x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0xa9, 0x8f, 0x7e, 0x2b}, - output224: []byte{0x62, 0x15, 0x3f, 0x59, 0x2c, 0x49, 0xd3, 0xc0, 0x48, 0x5f, 0x80, 0x7, 0x33, 0x19, 0x4, 0x9a, 0x51, 0xc, 0x73, 0x3, 0x27, 0x94, 0xc, 0xd9, 0xd5, 0x2f, 0x36, 0x98}, - output256: []byte{0xc6, 0xd8, 0x6c, 0xc4, 0xcc, 0xef, 0x3b, 0xb7, 0xb, 0xf7, 0xbf, 0xdd, 0xec, 0x6a, 0x9a, 0x4, 0xa0, 0xdd, 0xa, 0x68, 0xfe, 0x1b, 0xf5, 0x1c, 0x14, 0x64, 0x8c, 0xf5, 0x6, 0xa0, 0x3e, 0x98}, - output384: []byte{0x6, 0xe9, 0xf8, 0x92, 0xa2, 0x71, 0x6d, 0xe1, 0x8d, 0xac, 0x1b, 0x89, 0x46, 0x60, 0x44, 0x73, 0xad, 0xe0, 0x60, 0xaf, 0xc8, 0xcb, 0x12, 0x87, 0xe3, 0x89, 0x99, 0x40, 0x76, 0xff, 0x92, 0xb4, 0xba, 0xe3, 0xd8, 0x48, 0x54, 0x47, 0xe, 0xd0, 0x61, 0xae, 0x31, 0xa9, 0x7b, 0x7d, 0xd, 0xcf}, - output512: []byte{0x89, 0xfe, 0x63, 0x14, 0xa0, 0x24, 0x6e, 0xff, 0x3b, 0xfd, 0x7, 0xa9, 0x5f, 0xe2, 0x39, 0xbd, 0x50, 0x71, 0x46, 0x7f, 0x53, 0x79, 0x91, 0x75, 0xb2, 0x26, 0xda, 0xf6, 0xc3, 0xdb, 0x61, 0x8c, 0xad, 0x4c, 0xa1, 0xc1, 0xaf, 0x64, 0xbf, 0x57, 0x93, 0xf0, 0x32, 0x54, 0xf5, 0x60, 0xe6, 0x33, 0x5b, 0xea, 0xaa, 0x86, 0xbc, 0xb9, 0xe9, 0x61, 0xf2, 0x14, 0xb2, 0xae, 0x97, 0xb4, 0x7a, 0xf0}}, - testcase{ - msg: []byte{0x83, 0xaf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0x9c, 0xd8, 0x2d, 0xce, 0xe5, 0x8c, 0xa, 0x2a, 0xf5, 0x38, 0xb2, 0x91, 0xa8, 0x7e, 0x33, 0x90, 0xd7, 0x37, 0x19, 0x1a, 0x7, 0x48, 0x4a, 0x5d, 0x3f, 0x3f, 0xb8, 0xc8, 0xf1, 0x5c, 0xe0, 0x56, 0xe5, 0xe5, 0xf8, 0xfe, 0xbe, 0x5e, 0x1f, 0xb5, 0x9d, 0x67, 0x40, 0x98, 0xa, 0xa0, 0x6c, 0xa8, 0xa0, 0xc2, 0xf, 0x57, 0x12, 0xb4, 0xcd, 0xe5, 0xd0, 0x32, 0xe9, 0x2a, 0xb8, 0x9f, 0xa, 0xe1}, - output224: []byte{0xec, 0xde, 0x4d, 0x6e, 0xb0, 0xcf, 0x28, 0x1, 0xb, 0x45, 0xd0, 0xd3, 0x10, 0xe7, 0xd0, 0x5f, 0x8, 0xb8, 0xa, 0xfc, 0x44, 0xb8, 0xa3, 0x59, 0xbe, 0x7e, 0x19, 0x23}, - output256: []byte{0x1a, 0xfc, 0x9b, 0xa6, 0x3e, 0xea, 0x27, 0x60, 0x3b, 0x3a, 0x7a, 0x55, 0x62, 0xe1, 0x2b, 0x31, 0xe8, 0xfe, 0x9a, 0x96, 0x81, 0x2b, 0x53, 0x1e, 0x9d, 0x4, 0x83, 0x85, 0xfb, 0x76, 0xd4, 0x4f}, - output384: []byte{0x64, 0x4, 0x77, 0x90, 0xb1, 0x65, 0x6e, 0x78, 0x95, 0x3b, 0x98, 0x1b, 0x1b, 0xbf, 0xae, 0xaf, 0x9d, 0x2b, 0x1b, 0x89, 0x53, 0xab, 0x3, 0x4, 0x79, 0x12, 0x38, 0x39, 0x3f, 0x33, 0x72, 0xc6, 0x37, 0x3a, 0x1e, 0x8, 0x7b, 0x57, 0xbe, 0x48, 0x80, 0x62, 0x29, 0xdb, 0x73, 0xe1, 0xb1, 0xa4}, - output512: []byte{0x76, 0x90, 0xf7, 0x3, 0xe8, 0x94, 0x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3, 0xe4, 0x2e, 0x61, 0x98, 0x5, 0xa}, - output384: []byte{0x9c, 0xa6, 0xf3, 0x90, 0x87, 0xe6, 0x45, 0x7e, 0x12, 0xc9, 0x69, 0xd4, 0x1c, 0x8b, 0xd6, 0x6b, 0xdd, 0x69, 0x90, 0xce, 0x23, 0xd3, 0x55, 0x66, 0x9e, 0x76, 0x6, 0xb9, 0x20, 0x3d, 0x21, 0x68, 0x11, 0x23, 0x79, 0x55, 0xdf, 0x67, 0x39, 0x49, 0x5d, 0x94, 0xf0, 0xc4, 0x8c, 0xe0, 0x28, 0x45}, - output512: []byte{0x65, 0xe4, 0x15, 0xc7, 0x95, 0x8a, 0x47, 0xfc, 0xa9, 0xee, 0xd3, 0x84, 0x6f, 0xd1, 0x28, 0x3a, 0xfe, 0xb3, 0x8e, 0x51, 0x30, 0xf5, 0x7e, 0xcd, 0x99, 0xdc, 0xb2, 0x1b, 0xed, 0xda, 0x85, 0x6e, 0x3b, 0x5f, 0xb9, 0xf8, 0x39, 0xe5, 0x79, 0xc5, 0xea, 0x38, 0x6e, 0xac, 0xa8, 0xcd, 0xc0, 0xa9, 0x54, 0x9e, 0xaa, 0xf6, 0xec, 0x45, 0x2d, 0xd6, 0xcb, 0x52, 0x12, 0xb7, 0x9, 0xbf, 0x5c, 0x59}}, - testcase{ - msg: []byte{0xa6, 0xfe, 0x30, 0xdc, 0xfc, 0xda, 0x1a, 0x32, 0x9e, 0x82, 0xab, 0x50, 0xe3, 0x2b, 0x5f, 0x50, 0xeb, 0x25, 0xc8, 0x73, 0xc5, 0xd2, 0x30, 0x58, 0x60, 0xa8, 0x35, 0xae, 0xce, 0xe6, 0x26, 0x4a, 0xa3, 0x6a, 0x47, 0x42, 0x99, 0x22, 0xc4, 0xb8, 0xb3, 0xaf, 0xd0, 0xd, 0xa1, 0x60, 0x35, 0x83, 0xe, 0xdb, 0x89, 0x78, 0x31, 0xc4, 0xe7, 0xb0, 0xf, 0x2c, 0x23, 0xfc, 0xb, 0x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0xaa, 0x27, 0xe6, 0x6c, 0x8f, 0xf6}, - output224: []byte{0x22, 0x71, 0x55, 0x59, 0xad, 0x15, 0x71, 0x77, 0x22, 0xb1, 0xfa, 0x5, 0x83, 0x99, 0x60, 0x90, 0xc7, 0x9c, 0x3d, 0xf1, 0x6c, 0xc1, 0xe6, 0xe0, 0xf6, 0xd3, 0xe8, 0x98}, - output256: []byte{0x21, 0x6f, 0xc3, 0x25, 0xf9, 0x42, 0xee, 0xd0, 0x84, 0x1, 0x52, 0x7a, 0x8f, 0x41, 0xc0, 0x88, 0x52, 0x7c, 0x64, 0x79, 0x34, 0x26, 0x22, 0xc9, 0x7, 0xea, 0x8, 0xff, 0x32, 0x90, 0xf8, 0xc6}, - output384: []byte{0xfe, 0x99, 0xf1, 0x9c, 0x79, 0xa8, 0x90, 0x80, 0xe2, 0xff, 0x90, 0x98, 0x1d, 0xde, 0x91, 0x99, 0x45, 0x42, 0xd4, 0xbc, 0xc1, 0x27, 0x6a, 0x82, 0xd1, 0xa2, 0xe5, 0x38, 0x50, 0x34, 0x1b, 0x9a, 0xd5, 0x42, 0x2c, 0xea, 0xb8, 0x1e, 0x69, 0xda, 0xe5, 0xe9, 0x1d, 0xc5, 0xff, 0x60, 0xe1, 0xa3}, - output512: []byte{0xd6, 0x54, 0x2a, 0x2f, 0x6, 0x54, 0xb9, 0xb8, 0x74, 0xa6, 0x27, 0xd3, 0xd5, 0x37, 0x64, 0xa6, 0x5b, 0x1d, 0xf2, 0xc0, 0xce, 0xc3, 0xbc, 0xd0, 0xb4, 0xb0, 0x88, 0xfa, 0xa1, 0x9, 0x5e, 0x54, 0xf1, 0x79, 0x97, 0x57, 0xc4, 0x37, 0x1f, 0x8d, 0x54, 0x4e, 0x29, 0x8d, 0x60, 0xe, 0x21, 0xe1, 0x1b, 0x2f, 0x90, 0xd2, 0x95, 0x71, 0x26, 0x21, 0x23, 0x1a, 0x9, 0xc5, 0x8b, 0x5, 0xa7, 0x4}}, - testcase{ - msg: []by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, 0xc5, 0x69, 0xc1, 0xe4, 0x3a, 0x35, 0x2e, 0x5b, 0x77, 0xc, 0x35, 0x4, 0xf8, 0x70, 0x90, 0xde, 0xe0, 0x75, 0xa1, 0xc4, 0xc8, 0x5c, 0xc, 0x39, 0xcf, 0x42, 0x1b, 0xdc, 0xc6, 0x15, 0xf9, 0xef, 0xf6, 0xcb, 0x4f, 0xe6, 0x46, 0x80, 0x4, 0xae, 0xce, 0x5f, 0x30, 0xe1, 0xec, 0xc6, 0xdb, 0x22, 0xad, 0x99, 0x39, 0xbb, 0x2b, 0xc, 0xcc, 0x96, 0x52, 0x1d, 0xfb, 0xf4, 0xae, 0x0, 0x8b, 0x5b, 0x46, 0xbc, 0x0, 0x6e}, - output224: []byte{0x2f, 0x36, 0xff, 0x8a, 0xb7, 0x26, 0x4f, 0x7a, 0x57, 0x66, 0xde, 0x2, 0x50, 0x18, 0xe1, 0x9b, 0x5a, 0x64, 0xd9, 0x9, 0x94, 0xb7, 0x43, 0xb8, 0xfb, 0xfb, 0xdc, 0xca}, - output256: []byte{0x43, 0x18, 0x4b, 0x9f, 0x2d, 0xb5, 0xb6, 0xda, 0x51, 0x60, 0xbc, 0x25, 0x5d, 0xbe, 0x19, 0xa0, 0xc9, 0x45, 0x33, 0xb8, 0x84, 0x80, 0x98, 0x15, 0xb7, 0xb3, 0x26, 0xd8, 0x68, 0x58, 0x9e, 0xdc}, - output384: []byte{0x92, 0xe1, 0xd9, 0x94, 0xfe, 0xa2, 0xfd, 0x50, 0xa, 0x4b, 0x7f, 0x51, 0x39, 0x11, 0x90, 0x58, 0xa5, 0xb7, 0xe, 0xf6, 0x17, 0x4e, 0x55, 0x3f, 0x12, 0xfe, 0x7b, 0xcf, 0xca, 0x24, 0xb0, 0xa, 0x28, 0x39, 0x1e, 0x37, 0x61, 0xbd, 0xcb, 0xa3, 0xfd, 0x6b, 0x3, 0x3c, 0x12, 0x86, 0xe2, 0x8e}, - output512: []byte{0xec, 0x98, 0x3e, 0x78,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 0x25, 0x7a, 0x89, 0xef, 0xfd, 0xb5, 0xa8, 0x2, 0xf1, 0x61, 0xb8, 0x62, 0xea}, - output384: []byte{0x6b, 0xff, 0x1c, 0x84, 0x5, 0xa3, 0xfe, 0x59, 0x4e, 0x36, 0xe, 0x3b, 0xcc, 0xea, 0x1e, 0xbc, 0xd5, 0x9, 0x31, 0xd, 0xc7, 0x9b, 0x9e, 0x45, 0xc2, 0x63, 0x78, 0x3d, 0x7a, 0x5d, 0xd6, 0x62, 0xc6, 0x78, 0x9b, 0x18, 0xbd, 0x56, 0x7d, 0xbd, 0xda, 0x15, 0x54, 0xf5, 0xbe, 0xe6, 0xa8, 0x60}, - output512: []byte{0x81, 0x95, 0xe, 0x70, 0x96, 0xd3, 0x1d, 0x4f, 0x22, 0xe3, 0xdb, 0x71, 0xca, 0xc7, 0x25, 0xbf, 0x59, 0xe8, 0x1a, 0xf5, 0x4c, 0x7c, 0xa9, 0xe6, 0xae, 0xee, 0x71, 0xc0, 0x10, 0xfc, 0x54, 0x67, 0x46, 0x63, 0x12, 0xa0, 0x1a, 0xa5, 0xc1, 0x37, 0xcf, 0xb1, 0x40, 0x64, 0x69, 0x41, 0x55, 0x67, 0x96, 0xf6, 0x12, 0xc9, 0x35, 0x12, 0x68, 0x73, 0x7c, 0x7e, 0x9a, 0x2b, 0x96, 0x31, 0xd1, 0xfa}}, -} - -// extracted from LongMsgKAT_{224,256,384,512}.txt -var tstLong = []testcase{ - testcase{ - msg: []byte{0x72, 0x46, 0x27, 0x91, 0x6c, 0x50, 0x33, 0x86, 0x43, 0xe6, 0x99, 0x6f, 0x7, 0x87, 0x7e, 0xaf, 0xd9, 0x6b, 0xdf, 0x1, 0xda, 0x7e, 0x99, 0x1d, 0x41, 0x55, 0xb9, 0xbe, 0x12, 0x95, 0xea, 0x7d, 0x21, 0xc9, 0x39, 0x1f, 0x4c, 0x4a, 0x41, 0xc7, 0x5f, 0x77, 0xe5, 0xd2, 0x73, 0x89, 0x25, 0x33, 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 0x52, 0xf0, 0x15, 0xdd, 0x59, 0x15, 0x0, 0xd0, 0x18, 0xdd, 0x16, 0x28, 0x15, 0xcc, 0x99, 0x35, 0x95, 0xb1, 0x95}, - output224: []byte{0xe9, 0xf, 0x81, 0xae, 0x86, 0xd7, 0x2d, 0xcc, 0x21, 0x90, 0xaf, 0x54, 0x5a, 0x34, 0x51, 0x50, 0xa6, 0x29, 0xee, 0x7d, 0xc7, 0x23, 0x7c, 0x19, 0x58, 0xcf, 0xcd, 0xbc}, - output256: []byte{0xea, 0xe, 0x41, 0x6c, 0xf, 0x7b, 0x4f, 0x11, 0xe3, 0xf0, 0x4, 0x79, 0xfd, 0xdf, 0x95, 0x4f, 0x25, 0x39, 0xe5, 0xe5, 0x57, 0x75, 0x3b, 0xd5, 0x46, 0xf6, 0x9e, 0xe3, 0x75, 0xa5, 0xde, 0x29}, - output384: []byte{0x86, 0xb7, 0xcc, 0x35, 0x44, 0xe5, 0xf9, 0x1f, 0x12, 0xa9, 0x10, 0xa5, 0x6a, 0xdd, 0xd6, 0xb5, 0xe7, 0xdc, 0x7d, 0xf5, 0x1f, 0xae, 0xcc, 0x2f, 0xc5, 0x15, 0xee, 0x66, 0x9b, 0x59, 0x12, 0xdd, 0x11, 0x6a, 0xa1, 0x30, 0x52, 0x56, 0x9e, 0xab, 0x59, 0x7c, 0xec, 0xa9, 0x22, 0xb1, 0xed, 0x32}, - output512: []byte{0x4e, 0x98, 0x77, 0x68, 0x46, 0x9f, 0x54, 0x62, 0x96, 0xad, 0x1a, 0x43, 0xd5, 0x4c, 0xa, 0xa, 0x6c, 0x87, 0xe7, 0xe4, 0xe2, 0x6b, 0x68, 0x66, 0x12, 0xb1, 0xe5, 0xb1, 0x55, 0x4b, 0x68, 0x9b, 0xff, 0xd5, 0x6d, 0x6a, 0x4b, 0x45, 0x4c, 0xe4, 0xa5, 0x71, 0x76, 0x25, 0xbb, 0xad, 0x32, 0x1f, 0x8d, 0x5, 0xf1, 0x9c, 0x22, 0x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xa9, 0xd1, 0x27, 0x44, 0x6f, 0x11, 0x3b, 0x7c, 0xc3, 0xd0, 0x7b, 0x97, 0xe, 0x7, 0xa3, 0x22, 0x32, 0x5e, 0xce, 0xe6, 0x6a, 0xe0, 0xc9, 0xca}, - output384: []byte{0xe0, 0x10, 0xd, 0x6a, 0x2, 0x56, 0x8b, 0x24, 0x4d, 0xf7, 0xea, 0x67, 0xf2, 0x80, 0xae, 0x5d, 0x95, 0x6b, 0xe6, 0x38, 0x36, 0xb0, 0x2b, 0xbf, 0xe8, 0x87, 0x5d, 0x6d, 0xbe, 0xd1, 0x64, 0x65, 0x58, 0x2e, 0x5b, 0x4d, 0xa7, 0xa6, 0x76, 0x2, 0x50, 0x8c, 0x67, 0x9f, 0xa, 0x50, 0xea, 0x2d}, - output512: []byte{0x3d, 0x37, 0xd, 0xc8, 0x50, 0xbc, 0x7e, 0x15, 0x9c, 0xee, 0x3f, 0x24, 0xd9, 0xe9, 0x15, 0xb5, 0xb1, 0x30, 0x6f, 0xf4, 0x3, 0xc3, 0x2c, 0x7a, 0x3a, 0x38, 0x44, 0xf3, 0xfc, 0x8d, 0x90, 0xe3, 0x5f, 0x56, 0xd8, 0x3b, 0xdd, 0x9c, 0x63, 0x7b, 0xc4, 0x5e, 0x44, 0xe, 0x1f, 0x27, 0xcc, 0xd5, 0x6b, 0x6b, 0x38, 0x72, 0xec, 0x19, 0x10, 0x1b, 0xbe, 0x31, 0x84, 0x51, 0x8, 0xdc, 0xe9, 0x29}}, - testcase{ - msg: []byte{0x2, 0x3d, 0x91, 0xac, 0x53, 0x26, 0x1, 0xc7, 0xca, 0x39, 0x42, 0xd6, 0x28, 0x27, 0x56, 0x6d, 0x92, 0x68, 0xbb, 0x42, 0x76, 0xfc, 0xaa, 0x1a, 0xe9, 0x27, 0x69, 0x3a, 0x69, 0x61, 0x65, 0x26, 0x76, 0xdb, 0xa0, 0x92, 0x19, 0xa0, 0x1b, 0x3d, 0x5a, 0xdf, 0xa1, 0x25, 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0x84, 0x13, 0x18, 0x6, 0x6b, 0x90, 0xa9, 0x60, 0x4d, 0xc, 0x8e, 0xcc, 0xb2, 0x98, 0x6b, 0x84, 0xa0, 0xc8, 0x67, 0x5c, 0xd2, 0x43, 0xe9, 0x69, 0x57, 0xd2, 0x6e, 0x9c, 0x1c, 0xfd}, - output384: []byte{0xae, 0x55, 0x9c, 0x73, 0x2e, 0x55, 0xc5, 0x21, 0xb7, 0x73, 0x1e, 0x9c, 0x80, 0x65, 0x93, 0x1b, 0x93, 0xab, 0x5e, 0xf1, 0x67, 0x28, 0xe3, 0xf3, 0xc7, 0x38, 0xe7, 0xd5, 0x7, 0xb1, 0x84, 0x89, 0x38, 0x8c, 0xc3, 0xca, 0x7b, 0xa0, 0x1a, 0xf6, 0x72, 0xc2, 0x2c, 0xb7, 0x67, 0xc2, 0x95, 0xd2}, - output512: []byte{0x21, 0x8a, 0x55, 0x79, 0x65, 0x29, 0x14, 0x9f, 0x29, 0xcc, 0x4a, 0x19, 0xc8, 0xe, 0x5, 0xc2, 0x6f, 0x4, 0x8a, 0xbc, 0x98, 0x94, 0xad, 0x79, 0xf1, 0x1b, 0xac, 0x7c, 0x28, 0xde, 0x53, 0xbd, 0xc9, 0xbd, 0xb8, 0xbe, 0x49, 0x84, 0xf9, 0x24, 0x64, 0x8, 0x67, 0xfc, 0xfc, 0xe4, 0x23, 0x10, 0xad, 0xfa, 0x94, 0x9e, 0x2b, 0x25, 0x68, 0xff, 0xa0, 0x79, 0x5f, 0xbb, 0x32, 0x3, 0xde, 0x65}}, - testcase{ - msg: []byte{0x20, 0xff, 0x45, 0x43, 0x69, 0xa5, 0xd0, 0x5b, 0x81, 0xa7, 0x8f, 0x3d, 0xb0, 0x58, 0x19, 0xfe, 0xa9, 0xb0, 0x8c, 0x23, 0x84, 0xf7, 0x5c, 0xb0, 0xab, 0x6a, 0xa1, 0x15, 0xdd, 0x69, 0xd, 0xa3, 0x13, 0x18, 0x74, 0xa1, 0xca, 0x8f, 0x70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ad, 0x60, 0xb, 0x41, 0xe, 0x6c, 0xe2, 0xf2, 0xa7, 0x97, 0xe4, 0x9d, 0xc1, 0xf1, 0x35, 0x31, 0x98, 0x1, 0xfa, 0x6f, 0x39, 0x6b, 0x6, 0xf9, 0x75, 0xe2, 0xa1, 0x90, 0xa0, 0x23, 0xe4, 0x74, 0xb6, 0x18, 0xe7}, - output224: []byte{0x34, 0xa5, 0x8d, 0xdf, 0xc5, 0xc2, 0x22, 0x22, 0x81, 0xfa, 0x73, 0xeb, 0x34, 0xbf, 0xb5, 0xe1, 0x52, 0x27, 0x2c, 0xc3, 0xac, 0x7f, 0xe9, 0x7a, 0xc5, 0x8c, 0x8, 0xb0}, - output256: []byte{0xe, 0xc8, 0xd9, 0xd2, 0xd, 0xdf, 0xa, 0x7b, 0x2, 0x51, 0xe9, 0x41, 0xa7, 0x26, 0x1b, 0x55, 0x75, 0x7, 0xff, 0x62, 0x87, 0xb5, 0x4, 0x36, 0x2a, 0x8f, 0x17, 0x34, 0xc5, 0xa9, 0x10, 0x12}, - output384: []byte{0x59, 0x75, 0xfa, 0x4b, 0xce, 0xfc, 0x79, 0xfa, 0xdc, 0x79, 0xcc, 0xf1, 0x25, 0x4b, 0xba, 0x9e, 0xac, 0x25, 0x2e, 0x24, 0xc7, 0xde, 0xc7, 0xeb, 0x89, 0x72, 0xd2, 0x65, 0xef, 0xad, 0x3f, 0x6c, 0xf6, 0x48, 0xc4, 0x9d, 0xff, 0xf5, 0x45, 0x3a, 0xd2, 0x7d, 0x62, 0xff, 0x86, 0x7a, 0x2f, 0x3}, - output512: []byte{0x11, 0x6a, 0xe9, 0x4c, 0x86, 0xf6, 0x8f, 0x96, 0xb8, 0xae, 0xf2, 0x98, 0xa9, 0xf5, 0x85, 0x2c, 0xc9, 0x91, 0x3a, 0x2a, 0xd3, 0xc3, 0xc3, 0x44, 0xf2, 0x8d, 0xcc, 0x9b, 0x29, 0x29, 0x2a, 0x71, 0x6f, 0xaf, 0x51, 0xdd, 0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 0x6c, 0x6f, 0x7e, 0xc8, 0x83, 0xc7, 0x26, 0x71, 0xdb, 0x21, 0x1c, 0xd1, 0x63}, - output256: []byte{0xe, 0xa3, 0x3e, 0x2e, 0x34, 0xf5, 0x72, 0x44, 0x6, 0x40, 0x24, 0x4c, 0x7f, 0x1f, 0x5f, 0x4, 0x69, 0x7c, 0xe9, 0x71, 0x39, 0xbd, 0xa7, 0x2a, 0x65, 0x58, 0xd8, 0x66, 0x3c, 0x2, 0xb3, 0x88}, - output384: []byte{0xd8, 0xa1, 0x8f, 0xdf, 0xd, 0xbc, 0x4d, 0x9d, 0xc9, 0xa3, 0x99, 0xee, 0xd8, 0x33, 0xd2, 0x58, 0xbd, 0xf4, 0xe0, 0x6c, 0x50, 0xc1, 0x25, 0x50, 0xb5, 0x2, 0x97, 0xdd, 0xa0, 0x57, 0x84, 0xae, 0xe9, 0x1f, 0x33, 0x97, 0x66, 0x2, 0x1b, 0x2c, 0xa6, 0xbe, 0x15, 0x77, 0x82, 0x3d, 0x92, 0xb}, - output512: []byte{0xde, 0xa5, 0x6b, 0xda, 0xbb, 0xc6, 0xd2, 0x41, 0x83, 0xcf, 0x7b, 0xde, 0x1e, 0x1f, 0x78, 0x63, 0x1b, 0x2b, 0x2, 0x30, 0xc7, 0x6f, 0xf2, 0xf4, 0x30, 0x75, 0xf2, 0xfd, 0xe7, 0x7c, 0xf0, 0x52, 0x76, 0x92, 0x76, 0xca, 0xd9, 0x8d, 0xa6, 0x23, 0x94, 0xec, 0x62, 0xd7, 0x77, 0x30, 0xf5, 0x76, 0x14, 0x89, 0x58, 0x5e, 0x9, 0x3e, 0xa7, 0x31, 0x5f, 0x35, 0x92, 0x71, 0x7c, 0x48, 0x5c, 0x84}}, - testcase{ - msg: []byte{0xfe, 0x6, 0xa4, 0x70, 0x64, 0x68, 0xb3, 0x69, 0xf7, 0x62, 0x4f, 0x62, 0xd0, 0x4f, 0x9f, 0xac, 0x2, 0xf, 0x5, 0x15, 0x2f, 0x13,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xf6, 0xaa, 0xa2, 0x5b, 0xe8, 0x97, 0x91, 0x60, 0x8c, 0x42, 0x9a, 0xd8, 0xa6, 0xde, 0x76, 0x7a, 0x47, 0x94, 0xb3, 0x5, 0xfb, 0x62}, - output256: []byte{0xd3, 0x10, 0x38, 0xec, 0x77, 0xcc, 0xad, 0x0, 0xaf, 0x3d, 0x9d, 0x5e, 0x9f, 0x5c, 0xe7, 0x17, 0xf5, 0x94, 0x5b, 0xde, 0x71, 0xc8, 0x7c, 0xea, 0x83, 0x7b, 0xe4, 0xb3, 0x60, 0xde, 0x59, 0x5a}, - output384: []byte{0x99, 0xfd, 0xee, 0x84, 0xa6, 0xe0, 0x6e, 0x7e, 0x8b, 0x21, 0xaf, 0x15, 0x64, 0x48, 0xb3, 0x16, 0x8f, 0x77, 0x71, 0x35, 0x2, 0x95, 0x65, 0x69, 0x46, 0x8, 0xe1, 0x47, 0x53, 0x7c, 0xe2, 0x62, 0x39, 0xd6, 0x89, 0x8f, 0xb, 0x1, 0xe4, 0x7, 0xef, 0x9e, 0x1c, 0xe5, 0x2b, 0xed, 0x34, 0x5e}, - output512: []byte{0x2e, 0x62, 0x36, 0x11, 0x7c, 0x4f, 0x99, 0x47, 0x8b, 0xff, 0x20, 0x4a, 0x44, 0x3c, 0x64, 0x77, 0x7c, 0xc0, 0xd6, 0x58, 0xa2, 0x46, 0x5, 0xe8, 0x10, 0xe5, 0xff, 0x12, 0xf2, 0x79, 0xbc, 0x32, 0x6c, 0x43, 0x91, 0x11, 0xa9, 0x11, 0x58, 0x31, 0x76, 0x28, 0xd, 0x63, 0xc4, 0xbf, 0x9c, 0x69, 0xf4, 0x7, 0x29, 0xcb, 0x97, 0x69, 0x96, 0xae, 0x77, 0x65, 0xe5, 0x91, 0x0, 0x4c, 0xd7, 0x99}}, - testcase{ - msg: []byte{0xd0, 0xff, 0x6e, 0x4, 0x5f, 0x4b, 0x63, 0x6f, 0x75, 0xa3, 0x89, 0x79, 0x9f, 0x31, 0x40, 0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, 0x8b, 0x6, 0xd, 0x31, 0xc8, 0xac, 0xc4, 0x6d, 0x26, 0x87, 0xb, 0xd4, 0x5d, 0xd, 0xe0, 0x79, 0x8d, 0x48, 0xe3, 0x2a, 0xad, 0x1a, 0x6d, 0x43, 0x22, 0xe6, 0x9f, 0x5e, 0x72, 0x30, 0x9b, 0x9d, 0x7f, 0xa1, 0xf2, 0x4b, 0xb1, 0xd6, 0x3f, 0xf0, 0x9e, 0xd4, 0x73, 0x91, 0xc2, 0x32, 0x49, 0x7b, 0xf2, 0x22, 0xc5, 0x42, 0xa7, 0x9, 0x75, 0xc8, 0x29, 0x2d, 0x27, 0x51, 0x97, 0xa4, 0xca}, - output224: []byte{0x68, 0xc9, 0x38, 0xd6, 0x49, 0x6b, 0xb5, 0x7, 0xd7, 0xed, 0xe9, 0xac, 0x12, 0xfe, 0x8e, 0x1, 0xb, 0x3b, 0x2c, 0xfd, 0x44, 0xa5, 0xd4, 0x76, 0x10, 0x31, 0xb9, 0xe2}, - output256: []byte{0xe4, 0xe3, 0xbb, 0x66, 0x2b, 0xe0, 0x94, 0x61, 0xf, 0x4, 0xd5, 0x59, 0x4e, 0xef, 0x5f, 0x78, 0xb1, 0xab, 0x8, 0xf, 0x2e, 0xbe, 0x5a, 0xcf, 0x41, 0xd6, 0x61, 0xfa, 0x13, 0xa6, 0x8d, 0xbd}, - output384: []byte{0xe7, 0x2a, 0xfb, 0xd3, 0xac, 0xd3, 0x5b, 0x7f, 0x87, 0x8f, 0xce, 0xfa, 0xc7, 0x8d, 0xc5, 0x34, 0xe4, 0x25, 0x5, 0x22, 0x13, 0x76, 0x9d, 0xc3, 0xee, 0x17, 0x2a, 0xe5, 0x62, 0xf4, 0xa0, 0xfc, 0x94, 0x6d, 0x9c, 0x8e, 0x54, 0x6f, 0x15, 0x78, 0xa2, 0xac, 0xf3, 0xd0, 0x6d, 0x9f, 0x3c, 0xc9}, - output512: []byte{0xc8, 0xee, 0x15, 0x8c, 0xc1, 0xad, 0x47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, 0xab, 0x13, 0xe5, 0x82, 0xb1, 0x3d, 0x49, 0x44, 0x26, 0x38, 0xe2, 0x69, 0x8f, 0xb7, 0xa5, 0x63, 0xc7, 0xfb, 0x26, 0x41, 0x57}, - output224: []byte{0x2e, 0xaf, 0x74, 0x19, 0x85, 0x69, 0xe0, 0x5a, 0x6, 0x14, 0xb0, 0x67, 0xc9, 0x11, 0xd6, 0x25, 0xa9, 0x22, 0x2b, 0xcb, 0x6f, 0x75, 0x37, 0xc3, 0x4e, 0x75, 0x3, 0x93}, - output256: []byte{0x6e, 0x1b, 0xb4, 0xd0, 0x34, 0xe9, 0xb9, 0x81, 0x6e, 0xd1, 0xa8, 0x46, 0xf9, 0x3, 0xf6, 0x2c, 0xb1, 0xbd, 0xb8, 0xa0, 0xd, 0x44, 0x6c, 0x9c, 0xc7, 0x77, 0xe4, 0x75, 0xa3, 0x27, 0xc5, 0x8d}, - output384: []byte{0x25, 0x64, 0x32, 0xcf, 0xe8, 0xf9, 0xf0, 0xc3, 0xef, 0xbb, 0x6c, 0xd1, 0x35, 0xfd, 0x92, 0xa9, 0x2a, 0xc5, 0x77, 0x2f, 0x3c, 0xd9, 0x5, 0x38, 0x9c, 0x5e, 0x76, 0xa4, 0x3e, 0x4f, 0x68, 0x3, 0x8, 0xc1, 0x34, 0xac, 0xb8, 0xd1, 0x7b, 0xf7, 0xcc, 0xa2, 0xe6, 0x67, 0x57, 0xc6, 0x7c, 0x33}, - output512: []byte{0x65, 0x6a, 0xbb, 0x69, 0x55, 0x4d, 0x7d, 0x34, 0x85, 0x5c, 0xc, 0x36, 0xd9, 0x9b, 0x73, 0xb9, 0x56, 0x9b, 0x1f, 0xf, 0x86, 0xb2, 0xcc, 0xa6, 0xc4, 0x6e, 0x80, 0x39, 0x37, 0x7d, 0x22, 0xc7, 0xf, 0x4d, 0x45, 0x7e, 0x3a, 0xd1, 0xdd, 0x33, 0x1, 0x2c, 0xb1, 0xbb, 0x26, 0x20, 0xbc, 0x1d, 0xb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x8d, 0xb3, 0x3a, 0x88, 0x9f, 0x22, 0x5d, 0x2, 0x7d, 0x16, 0x4f, 0x25, 0x45, 0x35, 0x77, 0xc, 0x50, 0x4c, 0x50, 0x6a, 0xee, 0x4e, 0xc4, 0x67, 0x67, 0x71, 0xf6, 0x9f, 0x93, 0x5b, 0xa0, 0x8a, 0x1c, 0x6c, 0x85}, - output224: []byte{0x3a, 0x96, 0x95, 0xfc, 0x92, 0x10, 0x64, 0xad, 0x79, 0x92, 0x1d, 0x76, 0xe9, 0x1d, 0x7a, 0xc9, 0x1c, 0x77, 0x7a, 0x77, 0xbf, 0xb5, 0x38, 0xe, 0xa0, 0x68, 0x6c, 0x87}, - output256: []byte{0x63, 0x19, 0xc9, 0x11, 0x7e, 0xc0, 0xfd, 0xfb, 0x18, 0x9c, 0x83, 0xb5, 0x51, 0x1, 0x51, 0x45, 0xfc, 0x61, 0xff, 0x66, 0xb0, 0xd1, 0xb1, 0x56, 0x8a, 0xc8, 0xd1, 0x7d, 0x61, 0xf2, 0xa0, 0x8f}, - output384: []byte{0x61, 0xf4, 0x7f, 0x6b, 0xc7, 0x97, 0xd1, 0x66, 0x58, 0x9, 0xa3, 0x9c, 0xf9, 0x9b, 0x9, 0x39, 0x26, 0xb3, 0x3f, 0x92, 0x6e, 0xf6, 0xb0, 0xa1, 0xec, 0x8d, 0x82, 0x52, 0x35, 0x11, 0xff, 0x71, 0x9b, 0x3b, 0x62, 0x5c, 0xb1, 0xb5, 0x6a, 0x96, 0x62, 0x98, 0xfa, 0x77, 0xe5, 0xbf, 0x16, 0xf0}, - output512: []byte{0xfc, 0x6, 0x93, 0x39, 0xa5, 0x2a, 0x68, 0x9a, 0xdd, 0x5b, 0xbb, 0xb6, 0x6d, 0x45, 0x82, 0xff, 0x1a, 0xf7, 0xc2, 0x20, 0x52, 0x48, 0x99, 0xa5, 0xee, 0x9a, 0x14, 0x42, 0x96, 0x6d, 0xfa, 0xdb, 0x6d, 0x98, 0xed, 0x2f, 0x74,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 0x97, 0xe5, 0xf2, 0xe1, 0x9e, 0xf9, 0xd5, 0x9a, 0xe1, 0x2b, 0x4, 0xe7, 0xf0, 0xe8, 0xa6, 0x21, 0xe0, 0x98, 0xa6, 0x69, 0x10, 0xe2, 0xa5, 0xed, 0x21, 0x2, 0xb8, 0x24, 0xcd, 0x3e, 0xa0, 0x44, 0xa8, 0x54, 0xf1, 0xcd, 0xb, 0x33, 0xe6, 0x1e, 0x7f, 0x73, 0x74, 0x14, 0xb2, 0x95, 0x35, 0x49, 0xf2, 0x5d, 0xd3, 0x4d, 0x19, 0xaa, 0x19, 0x81, 0xde, 0x7c, 0xd5, 0x64, 0x9f, 0xf6, 0xc6, 0x36, 0x4a, 0x4f, 0x25, 0x31, 0x2e, 0xf6, 0x23, 0x95, 0xa7, 0x47, 0xab, 0x88, 0xaa, 0xd7, 0x22, 0xc0, 0x5a, 0xec, 0x40, 0xde, 0xea, 0x8e, 0xee, 0x5e, 0x77, 0x9e, 0xf4, 0x58, 0xa6, 0x88, 0x40, 0xbc, 0x6b, 0xd5, 0xd2, 0x9a, 0xd4, 0xf, 0x98, 0xb3, 0xae, 0x1, 0xb, 0x62, 0x13, 0x37, 0x2a, 0xbb, 0x7b, 0xb8, 0xb8}, - output224: []byte{0x97, 0x49, 0x5b, 0xfe, 0xda, 0xf1, 0xca, 0xb1, 0x8e, 0x85, 0x19, 0xb, 0x37, 0x47, 0x29, 0xf5, 0x54, 0x3f, 0xa3, 0xf1, 0xcd, 0x88, 0x43, 0x81, 0x56, 0xf0, 0x1a, 0xc}, - output256: []byte{0xc7, 0x49, 0xb, 0x5, 0xb1, 0x72, 0xa1, 0xdb, 0xaa, 0xa6, 0x6f, 0xaa, 0x82, 0x31, 0x8, 0xd4, 0x4c, 0x82, 0xf1, 0xe8, 0x2a, 0x41, 0xfd, 0x57, 0xfd, 0x95, 0x0, 0xf, 0x30, 0xde, 0x74, 0x7e}, - output384: []byte{0x96, 0xac, 0x67, 0xd6, 0xc9, 0xb, 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6e, 0x4f, 0x73, 0xf2, 0x22, 0xe7, 0x79, 0xe5, 0x8b, 0x71, 0xd5, 0x17, 0x6d, 0x9a, 0x27, 0xf6, 0x5e, 0x49, 0xd8, 0x3e, 0xfb, 0xb2, 0xd7, 0x81, 0xe, 0x5b, 0x6, 0x61, 0x9d, 0x8c, 0xef, 0x7e, 0x7b, 0x51, 0xcd, 0xfb, 0x6e, 0x81, 0x38, 0xe4, 0xcf, 0x56, 0x74, 0x24, 0x2f, 0x94, 0x7e, 0xac, 0x13, 0xfa, 0xd0, 0x8d, 0x68, 0xa8, 0xa1, 0x1a, 0xac, 0x97, 0x54, 0xa5, 0x31, 0x6c, 0x93, 0x73, 0x8b, 0xa7, 0xf3, 0xc3, 0xbd, 0x2e, 0x82, 0x7a}, - output224: []byte{0xb9, 0xcb, 0xbf, 0x5f, 0x95, 0x4c, 0xfe, 0x7a, 0x56, 0x17, 0xa1, 0x7d, 0xad, 0x9c, 0x43, 0x9f, 0xbf, 0x2a, 0x7, 0x1e, 0xfb, 0x4f, 0x3c, 0x23, 0x3c, 0xb, 0x3d, 0xf0}, - output256: []byte{0x18, 0x36, 0x42, 0x46, 0x8b, 0xe2, 0x70, 0x7c, 0x33, 0x49, 0x13, 0x2c, 0xd3, 0xb0, 0x63, 0x3a, 0xa6, 0x3e, 0x57, 0x52, 0x48, 0x8c, 0x3a, 0xdc, 0xd, 0x50, 0x12, 0x65, 0xff, 0x5, 0x29, 0xb0}, - output384: []byte{0x98, 0x72, 0xc7, 0xe0, 0x59, 0x40, 0x6, 0xc8, 0xb5, 0x9c, 0x37, 0x19, 0xaf, 0x32, 0x82, 0x1a, 0x60, 0xc, 0x26, 0x4d, 0x5e, 0xde, 0x1e, 0x16, 0x8f, 0x3f, 0x8c, 0x3f, 0x94, 0xfe, 0xd3, 0x7e, 0xcc, 0xb1, 0x30, 0xc0, 0x41, 0x29, 0x3, 0x93, 0xf3, 0x2d, 0xf6, 0x9f, 0x4, 0xf7, 0x8, 0xf9},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 0xe, 0x38, 0xd9, 0xbe, 0x2e, 0x2c, 0x21, 0x5c, 0x69, 0xf5, 0x58, 0x8, 0x4e, 0x48, 0xee, 0xb6, 0x1f, 0x4e, 0xaa, 0xe8, 0x3c, 0x57, 0xf3, 0xf1, 0xcd, 0x8, 0xd0, 0x57, 0x83, 0xfb, 0x9f, 0x5a, 0xb1, 0xcd, 0xa5, 0xe4, 0xb8, 0x62, 0x91, 0xff, 0xfb, 0x14, 0xfe, 0x9b, 0x49, 0x7e, 0xc7, 0x32, 0x92, 0xbb, 0xd2, 0x95, 0xc5, 0x65, 0x7d, 0x71, 0xcc, 0x74, 0xd3, 0x8a, 0x2f, 0x3d, 0xb7, 0x3b, 0xa9, 0x72, 0x98, 0x6b, 0x71, 0x69, 0xf7, 0x6b, 0xa3, 0x76, 0x37, 0x6f, 0x47, 0x47, 0xed, 0x65, 0xf2, 0xf1, 0xa5, 0xe6, 0x78, 0x89, 0xaf, 0x38, 0xa3, 0x80}, - output224: []byte{0x65, 0x76, 0x51, 0xaa, 0x8d, 0x87, 0x15, 0xdb, 0x57, 0xff, 0x7f, 0x18, 0xea, 0x1f, 0x2a, 0x8c, 0xcd, 0xbc, 0x2d, 0x5b, 0xbe, 0xe8, 0xa5, 0x10, 0xeb, 0x3d, 0x3a, 0x27}, - output256: []byte{0xca, 0x37, 0x2b, 0xec, 0xea, 0xbf, 0x81, 0x70, 0xb0, 0x11, 0x27, 0xad, 0xd4, 0xd3, 0xf7, 0x9, 0xe1, 0x26, 0x7a, 0xfb, 0x3e, 0xfb, 0x42, 0x71, 0xe2, 0xe6, 0x8f, 0xe9, 0x55, 0x8, 0x3, 0x67}, - output384: []byte{0xee, 0x36, 0x27, 0x83, 0x2f, 0xbd, 0xf2, 0x54, 0xae, 0xd7, 0x1, 0x85, 0xd6, 0x8d, 0xbf, 0x87, 0x3c, 0x5f, 0x54, 0x82, 0xb6, 0xd1, 0x56, 0x38, 0x13, 0x88, 0xdf, 0xac, 0x4f, 0x33, 0x6b, 0x8e, 0x0, 0x5e, 0xed, 0xd2, 0xb8, 0x29, 0x8c, 0xa0, 0x9, 0x7, 0x88, 0xf0, 0xa6, 0xfa, 0x5f, 0x52}, - output512: []byte{0x75, 0xff, 0x7d, 0x8f, 0xa4, 0xb9, 0x37, 0xb, 0x5b, 0x81, 0xdd, 0x88, 0xb6, 0x46, 0xa2, 0xb5, 0x46, 0x3a, 0x8f, 0xfa, 0x49, 0x82, 0xfb, 0x90, 0xc5, 0x5b, 0x68, 0x1c, 0x27, 0x16, 0x19, 0x20, 0x8a, 0x1b, 0x24, 0xde, 0xa3, 0x2f, 0x79, 0xf1, 0x9d, 0x9a, 0x96, 0xdc, 0x64, 0x20, 0x96, 0xa5, 0xae, 0xc2, 0xaa, 0xd8, 0x28, 0xb3, 0x8e, 0x42, 0xcf, 0x3d, 0x9e, 0xc7, 0xf1, 0x23, 0x93, 0xbf}}, - testcase{ - msg: []byte{0x67, 0xb, 0x79, 0xc6, 0x3, 0xd, 0xa4, 0x36, 0x91, 0x46, 0xa7, 0xf1, 0x4e, 0x6b, 0xd3, 0x93, 0xdf, 0x72, 0x9b, 0x60, 0x36, 0x9d, 0x3d, 0x55, 0x46, 0x1e, 0x51, 0x87, 0xd4, 0xf8, 0xe8, 0x31, 0x14, 0xb2, 0x27, 0x52, 0x4e, 0xe9, 0x55, 0xf6, 0x4a, 0x2c, 0x60, 0x7d, 0xa8, 0x50, 0x23, 0x5a, 0x1b, 0x49, 0xfe, 0xc6, 0xeb, 0x51, 0xed, 0xc2, 0x19, 0x41, 0xdc, 0xc6, 0x7b, 0xd0, 0x74, 0x12, 0xcf, 0xe0, 0x58, 0xaf, 0x45, 0x5, 0xc3, 0x25, 0xd9, 0x49, 0x36, 0xee, 0x36, 0xde, 0x41, 0x33, 0x77, 0x3a, 0xcf, 0x66, 0x95, 0x15, 0xda, 0xf4, 0xed, 0x87, 0x50, 0x85, 0x89, 0xcf, 0x65, 0x17, 0x84, 0xa8, 0xc3, 0x82, 0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 0x31, 0xf1, 0x4, 0xca, 0x61, 0x66, 0x41, 0x6e, 0x36, 0x59, 0x7c, 0x35, 0xdc, 0xf0, 0xfa, 0x43, 0x29, 0x8b, 0x7f, 0xca, 0x4f, 0x50, 0x45, 0xaf, 0xf9, 0x0, 0x29, 0x83, 0x39, 0xff, 0x5d, 0xbc, 0xc1, 0x40, 0x8d, 0x70, 0x3c, 0xee, 0x17, 0x8c, 0x6b, 0x19, 0x4e, 0x10, 0x15, 0xdf, 0x36, 0x2b, 0x3, 0x8a, 0xfd, 0x34, 0x96, 0x10, 0x81, 0x9f, 0xab, 0x28, 0x9a, 0xc1, 0x1c, 0xbb, 0x3f, 0x19, 0xff, 0xc9, 0xfa, 0x2, 0x3, 0xc2, 0x31, 0x71, 0x1f, 0xbc, 0xc4, 0x89, 0x22, 0x42, 0x20, 0x59, 0x40, 0x7e, 0xa2, 0x25, 0xf8, 0x50, 0x97, 0x61, 0xd3, 0xc5, 0x3d, 0x83, 0x43, 0x7b, 0x50, 0x78, 0x14, 0xe6, 0x12, 0x6, 0x55, 0x8c, 0x8a, 0x27, 0xe7, 0xd5, 0x54, 0x0, 0xc6, 0x4c, 0x22, 0xaa, 0xe3, 0x3c, 0x81, 0x73, 0x24, 0xab, 0xdd, 0x71, 0x14, 0xab, 0xfc, 0x1, 0xcf, 0xb1, 0xaf, 0xc1, 0x62, 0x96, 0xff, 0x6b, 0x3d, 0xbc, 0x82, 0x18, 0x51, 0x4b, 0x83, 0x10, 0x2b, 0xc8, 0x42, 0x72, 0xd4, 0x1c, 0x5, 0xea, 0xea, 0xdc, 0xf4, 0xa0, 0xfd, 0x99, 0x83, 0xfb, 0xb7, 0x96, 0x27, 0xba, 0x8f, 0x90, 0x5e, 0x4c, 0xd3, 0x45, 0xc8, 0x74}, - output224: []byte{0x38, 0xa0, 0x93, 0xa9, 0x79, 0x52, 0x8f, 0xce, 0xad, 0x90, 0x63, 0xc2, 0x65, 0xb4, 0xfc, 0x44, 0xd, 0xda, 0xbb, 0x82, 0x77, 0x15, 0x73, 0xc7, 0xc2, 0xd0, 0x6b, 0x84}, - output256: []byte{0x8f, 0xb5, 0x5e, 0xed, 0x6, 0x3f, 0x80, 0x47, 0x6c, 0xc7, 0xb2, 0xa2, 0x2e, 0xbd, 0xd3, 0x51, 0xd0, 0x28, 0x8d, 0xba, 0x71, 0x49, 0xff, 0xa, 0x99, 0xd5, 0xc6, 0xf8, 0x95, 0x46, 0xfb, 0x4}, - output384: []byte{0x84, 0x3e, 0xbe, 0x1b, 0x88, 0x36, 0x7, 0xa3, 0x5e, 0x5b, 0x5a, 0x50, 0xd1, 0xc5, 0xa3, 0xb9, 0xba, 0x44, 0x3f, 0x59, 0x3d, 0x40, 0x4c, 0x4e, 0x95, 0xa1, 0x9c, 0x7, 0x42, 0x32, 0x4d, 0x43, 0xa9, 0x3b, 0xfa, 0xaf, 0x2a, 0xee, 0x7c, 0xb0, 0x4f, 0xac, 0xae, 0x49, 0xdd, 0x68, 0xa8, 0x8c}, - output512: []byte{0xe2, 0x98, 0xe7, 0x24, 0x2, 0x46, 0xff, 0x59, 0xf9, 0xcc, 0xe, 0x19, 0x61, 0xfc, 0x68, 0x60, 0xb8, 0x73, 0x23, 0xac, 0x52, 0x67, 0x56, 0x2b, 0x53, 0x90, 0x53, 0xf7, 0xc6, 0xad, 0x1a, 0x3d, 0x23, 0x71, 0x54, 0x7c, 0xee, 0x17, 0x1c, 0x20, 0x10, 0xfd, 0xd5, 0x3, 0x8d, 0x22, 0x70, 0x20, 0xcd, 0xd8, 0xc7, 0xa1, 0xfa, 0xc0, 0x76, 0x19, 0x82, 0xba, 0x57, 0x5f, 0x36, 0x9a, 0xe8, 0xac}}, - testcase{ - msg: []byte{0xc5, 0x95, 0x33, 0x68, 0x27, 0x25, 0x9b, 0x5, 0xd, 0xc7, 0x83, 0xf2, 0x2f, 0xf7, 0xb0, 0x33, 0xec, 0xc9, 0x8f, 0x9c, 0x7c, 0xe0, 0x26, 0x80, 0x9c, 0xf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b, 0xcf, 0xd3, 0xe4, 0xdd, 0xc2, 0xd6, 0xa2, 0xfa, 0x2, 0xab, 0x78, 0xe, 0xb0, 0xfb, 0x34, 0x91, 0x23, 0x9a, 0x2f, 0xa1, 0xb5, 0xec, 0x90, 0xa0, 0x20, 0x3d, 0xed, 0x37, 0x2d, 0x5f, 0x59, 0x48, 0x47, 0xd2, 0x79, 0x39, 0x67, 0x30, 0xa9, 0xd8, 0xce, 0x5c, 0xc9, 0x2a, 0xe3, 0x4f, 0x7c, 0x75, 0xa0, 0x7b, 0xb4, 0x87, 0x3a, 0x5c, 0x5e, 0xe7, 0x82, 0x68, 0xdd, 0xd0, 0xd8, 0xa3, 0x51, 0x79, 0x4f, 0xbd, 0x6c, 0x80, 0x15, 0x51, 0xb3, 0x9f, 0xad, 0x39, 0xe6, 0xcd, 0x2c, 0xac, 0x30, 0xd4, 0x53, 0x8e, 0x90, 0xee, 0x24, 0x78, 0x4b, 0xa1, 0xac, 0xb, 0xa9, 0xcb, 0xc2, 0x87, 0x15, 0x1c, 0x7d, 0x8e, 0xe7, 0xff, 0x94, 0x52, 0x4f, 0xad, 0x65, 0xb3, 0xdc, 0x45, 0x26, 0x5e, 0xf3, 0xb7, 0x8, 0xca, 0x2b, 0xcc, 0x5d}, - output224: []byte{0x68, 0x61, 0xb5, 0xe0, 0xcf, 0xc2, 0x23, 0xeb, 0x2b, 0x9b, 0x73, 0x55, 0x67, 0x1, 0x9f, 0x90, 0xb6, 0x1a, 0x76, 0x84, 0xc, 0x89, 0x0, 0x55, 0x11, 0xb6, 0x63, 0x85}, - output256: []byte{0xe4, 0x31, 0x20, 0x8e, 0x1a, 0x69, 0xa, 0x1c, 0x9f, 0x83, 0x9, 0x2c, 0xb5, 0x7b, 0xf0, 0x12, 0x6d, 0xd, 0x3a, 0xfc, 0xe, 0xa0, 0xd1, 0x88, 0x46, 0xa, 0x25, 0x9f, 0x42, 0x12, 0xd1, 0x27}, - output384: []byte{0xff, 0xb1, 0x55, 0x23, 0x2a, 0x1e, 0xf4, 0xa, 0x53, 0x1e, 0xed, 0x1a, 0xa6, 0x1c, 0x7f, 0xcc, 0xa0, 0xf2, 0x13, 0x32, 0x65, 0x1b, 0xef, 0xe, 0x71, 0xfc, 0x11, 0xa3, 0x57, 0x6c, 0x85, 0x5f, 0xe9, 0x8c, 0xbd, 0x7e, 0x75, 0xff, 0x2, 0x6a, 0x18, 0xa6, 0x91, 0xa9, 0x6a, 0x75, 0x3d, 0x68}, - output512: []byte{0x54, 0xb2, 0xef, 0xf1, 0x73, 0xb4, 0x6, 0xba, 0x66, 0x3e, 0x39, 0x90, 0x8a, 0xf6, 0x76, 0x8f, 0x33, 0x28, 0x3b, 0x8b, 0xfb, 0xf, 0x48, 0xa5, 0x8c, 0x10, 0x4, 0xc5, 0x23, 0x15, 0x9a, 0x68, 0x1e, 0x60, 0x63, 0xfe, 0x22, 0x51, 0x67, 0xbd, 0xcb, 0xc, 0x90, 0x2e, 0x53, 0x3c, 0xe, 0x53, 0x54, 0x15, 0x63, 0x49, 0x10, 0xe1, 0xc8, 0xa6, 0x9f, 0x62, 0x49, 0x87, 0x1b, 0x1b, 0x17, 0x94}}, - testcase{ - msg: []byte{0xa8, 0x67, 0x33, 0xd, 0xc, 0x93, 0x8, 0x3f, 0xbb, 0x15, 0x9e, 0xfe, 0xef, 0x90, 0x7a, 0xa5, 0x3a, 0xce, 0x39, 0x95, 0xac, 0xfe, 0x75, 0x87, 0xb4, 0x4, 0xaf, 0x8c, 0x83, 0x34, 0xe3, 0x2f, 0x9d, 0x35, 0x97, 0x6d, 0x4, 0x66, 0x65, 0x9f, 0x26, 0x48, 0x26, 0x10, 0x9b, 0x23, 0xa0, 0xdf, 0x20, 0x56, 0xa5, 0x47, 0x9d, 0xc, 0xc, 0x5e, 0xa5, 0x16, 0x6c, 0xa2, 0x31, 0x52, 0x5d, 0xa9, 0xb, 0x38, 0x8c, 0x43, 0x25, 0x9b, 0xa1, 0x69, 0x6f, 0xd3, 0x92, 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, 0x8a, 0xbe, 0x53, 0x6e, 0x86, 0xed, 0x14, 0xb2, 0x4a, 0xe5, 0x3e, 0xe}, - output384: []byte{0xb8, 0x2e, 0x19, 0xa3, 0x28, 0xf6, 0x72, 0x76, 0xba, 0x1b, 0x2, 0x2, 0xf4, 0xfe, 0x37, 0x40, 0x10, 0x2e, 0xe, 0x60, 0x72, 0xeb, 0xae, 0xb1, 0x6c, 0xfe, 0xe7, 0x21, 0xdb, 0x38, 0x1c, 0xa9, 0x35, 0xd3, 0x2e, 0x1a, 0x2f, 0x2d, 0x4e, 0xea, 0xf9, 0x79, 0xf8, 0xf6, 0xb, 0x67, 0x18, 0xde}, - output512: []byte{0xb9, 0x52, 0xc7, 0x56, 0xf1, 0xdf, 0xd6, 0xa3, 0xf7, 0x65, 0x2e, 0x3b, 0x13, 0xad, 0x5c, 0xd2, 0x93, 0xe3, 0xaf, 0x87, 0xb, 0xf3, 0xe7, 0x39, 0xe2, 0xe5, 0x20, 0xbf, 0x25, 0x45, 0xda, 0xe0, 0x8c, 0x5e, 0x45, 0x91, 0x47, 0xc8, 0x58, 0x9c, 0x33, 0x1a, 0x24, 0x24, 0xd4, 0x8e, 0xac, 0x3a, 0xc2, 0xcc, 0xf1, 0xef, 0x95, 0xfb, 0xb5, 0x91, 0xcc, 0x57, 0x57, 0x18, 0x2a, 0x57, 0xa7, 0xa8}}, - testcase{ - msg: []byte{0x2e, 0xb3, 0x10, 0x26, 0x15, 0x5b, 0x7b, 0xc3, 0x67, 0x2f, 0x6, 0xd, 0x84, 0x7, 0xb1, 0x62, 0x2f, 0x61, 0x62, 0xcf, 0xe4, 0xe, 0x2, 0x86, 0xcf, 0x9b, 0xd7, 0x3b, 0x18, 0x50, 0x3, 0x82, 0x7e, 0xb7, 0x5c, 0xa0, 0x80, 0xf0, 0xfa, 0x81, 0xd9, 0xe5, 0x89, 0x3f, 0x46, 0x21, 0x24, 0xf6, 0x79, 0xeb, 0xad, 0x80, 0x7d, 0xf6, 0xad, 0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0x21, 0xd4, 0x51, 0x40, 0x6, 0x95, 0xd1, 0x34, 0x13, 0x45, 0xdb, 0xc9, 0xe6, 0xcb, 0xf0, 0x2f, 0x56, 0x5e, 0x8b, 0x2, 0xf7, 0xb2, 0x15, 0x11, 0x31, 0x51, 0x4e, 0xe7, 0xd3, 0x19, 0x5c, 0xcc, 0x26, 0x2e, 0xb6, 0x15, 0xa6, 0xc6}, - output224: []byte{0xff, 0x5d, 0xc9, 0xce, 0x96, 0xc, 0x60, 0x43, 0x23, 0xcd, 0x9d, 0x2d, 0x5d, 0x8d, 0x52, 0x10, 0xd, 0xc1, 0x84, 0xd2, 0x89, 0x5b, 0xa8, 0x76, 0xa5, 0x35, 0xdb, 0xd3}, - output256: []byte{0x33, 0xc1, 0xc, 0xcc, 0x7e, 0xac, 0x44, 0xf3, 0x7d, 0xc5, 0xd0, 0xd5, 0x8e, 0xd5, 0x90, 0xc8, 0x4, 0x40, 0x2d, 0x64, 0xd2, 0xf1, 0xdd, 0xfc, 0xac, 0xf3, 0xb3, 0x3, 0xef, 0xcc, 0xa8, 0x4b}, - output384: []byte{0xd7, 0x9a, 0xca, 0x6f, 0x2d, 0xdd, 0x22, 0x5b, 0x1b, 0x72, 0xc6, 0x59, 0x88, 0x9, 0x6f, 0xd, 0xd2, 0x12, 0xee, 0x63, 0x61, 0x24, 0xf7, 0xfb, 0x95, 0x83, 0xde, 0x56, 0xf2, 0xf6, 0x32, 0x61, 0x68, 0x6d, 0xe1, 0xdd, 0x6, 0x94, 0xd2, 0x18, 0x7d, 0xf3, 0x25, 0x4c, 0x37, 0x97, 0x83, 0xa6}, - output512: []byte{0xd9, 0x98, 0x2c, 0xc7, 0x53, 0xea, 0x96, 0xda, 0xab, 0xb5, 0xee, 0x67, 0x12, 0x4a, 0x29, 0x83, 0xc6, 0x18, 0xe2, 0x5b, 0x0, 0xb4, 0x8e, 0x3d, 0xbb, 0xc7, 0xa5, 0x7b, 0xba, 0x38, 0x34, 0x17, 0x2f, 0x11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 0xc4, 0x5d, 0x37}, - output224: []byte{0x99, 0x98, 0x71, 0xb0, 0x57, 0xe1, 0x4, 0xe8, 0xa, 0x48, 0x85, 0xe3, 0x5b, 0x72, 0xe0, 0xd5, 0x79, 0xb5, 0x2b, 0x29, 0xc4, 0x4c, 0xfc, 0x36, 0xb9, 0xd4, 0x4, 0x6c}, - output256: []byte{0xf3, 0x3c, 0x45, 0xd1, 0x42, 0xe, 0xee, 0xac, 0x9f, 0xa7, 0x38, 0x46, 0xc0, 0x80, 0xae, 0xaa, 0x5, 0x25, 0x34, 0x4, 0xf7, 0xd4, 0x2, 0x8f, 0x57, 0x45, 0x7c, 0x4a, 0xfe, 0x15, 0x45, 0xde}, - output384: []byte{0x5c, 0xb2, 0x75, 0xf4, 0x61, 0x2f, 0xb, 0x3a, 0xf3, 0x1e, 0xa2, 0x9b, 0x1e, 0xbf, 0xc7, 0xd8, 0x8, 0xd1, 0x45, 0xe6, 0x95, 0x4f, 0x33, 0x7e, 0x9e, 0xb5, 0xd9, 0xef, 0x45, 0x20, 0x97, 0xf3, 0xd, 0x44, 0x18, 0x27, 0xed, 0x72, 0x72, 0x9c, 0xc9, 0x5, 0x1e, 0x45, 0x83, 0xcd, 0x4f, 0x11}, - output512: []byte{0xf1, 0xc0, 0x97, 0x6f, 0xfd, 0xfb, 0xbd, 0x9e, 0xb4, 0x6f, 0xbf, 0xaa, 0x34, 0x10, 0x94, 0x91, 0x91, 0xc, 0xef, 0x2f, 0x2b, 0xce, 0x2, 0x4a, 0x60, 0x89, 0x6e, 0x80, 0xe9, 0x2e, 0x60, 0xc5, 0xc, 0x99, 0x35, 0x23, 0xe, 0x5e, 0x16, 0x52, 0x4c, 0x17, 0x5, 0x3f, 0xc, 0x71, 0x9d, 0xba, 0xba, 0xe3, 0xfe, 0xa9, 0xfd, 0x4a, 0x88, 0xff, 0xc0, 0x2d, 0x6a, 0x2a, 0x48, 0x3f, 0x33, 0x8d}}, - testcase{ - msg: []byte{0x4f, 0xa3, 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8e, 0xc9, 0x35, 0x7e, 0x66, 0x5f, 0x99, 0xd7, 0x6f, 0xe5, 0x52, 0x9e, 0xf2, 0x3c, 0x1b, 0xdf, 0xe0, 0x17, 0xc3, 0xa6, 0x6c, 0xd4, 0xeb, 0x2d, 0xdb, 0x42, 0xef, 0x85, 0xea, 0xc, 0xd6, 0x55, 0x34}, - output224: []byte{0x62, 0x97, 0xda, 0xbd, 0xc6, 0x6a, 0x68, 0xa2, 0x8e, 0x2f, 0x32, 0xfc, 0x95, 0xe5, 0x86, 0x40, 0x35, 0x0, 0x1c, 0xcb, 0x7a, 0xd, 0xcf, 0x59, 0x24, 0x67, 0xd4, 0x15}, - output256: []byte{0xeb, 0x35, 0x18, 0x38, 0xfe, 0x82, 0x25, 0xfb, 0xeb, 0xea, 0x91, 0x68, 0xdb, 0xb7, 0x8, 0x87, 0x2c, 0xa4, 0x3a, 0xc9, 0x34, 0x80, 0xc3, 0xaf, 0xfb, 0xe6, 0xcc, 0x3a, 0x15, 0xa2, 0x26, 0x3c}, - output384: []byte{0x3c, 0xb4, 0x48, 0x2b, 0x4f, 0x5f, 0xa1, 0x5b, 0x8c, 0x24, 0xa, 0xde, 0x9d, 0x99, 0x53, 0x4e, 0x8d, 0x91, 0x4a, 0x4c, 0x1, 0x29, 0xe, 0xf4, 0xb9, 0x41, 0x75, 0x97, 0x43, 0x1e, 0xdb, 0x1e, 0xce, 0x45, 0x6d, 0xc6, 0xb, 0x26, 0xfb, 0xd9, 0xc8, 0x8d, 0xb5, 0x80, 0x2d, 0x1c, 0xdc, 0xd9}, - output512: []byte{0x7a, 0xee, 0x30, 0x93, 0x3, 0x55, 0x71, 0x86, 0x79, 0xd3, 0x87, 0xdf, 0xbe, 0xd0, 0x8e, 0xb7, 0x0, 0xb3, 0x24, 0xbb, 0x27, 0x75, 0xbc, 0xfd, 0x11, 0xa8, 0x8d, 0x37, 0xaa, 0x69, 0xa5, 0xb1, 0xb0, 0x1, 0xe, 0x8a, 0x5c, 0x38, 0xbb, 0x20, 0xe5, 0xe5, 0xdd, 0xcf, 0x5b, 0xb2, 0x43, 0x68, 0x30, 0xdc, 0xe8, 0xda, 0x20, 0x48, 0x19, 0x77, 0x56, 0xfc, 0x85, 0xb2, 0xc, 0x16, 0xf0, 0xa0}}, - testcase{ - msg: []byte{0xbc, 0x25, 0x99, 0x72, 0xad, 0x10, 0x9b, 0xde, 0x60, 0x39, 0x99, 0x72, 0x8e, 0xf0, 0xbb, 0xf2, 0x3a, 0x91, 0x18, 0x29, 0xc1, 0xc9, 0x10, 0xf0, 0x51, 0x7a, 0xd7, 0x58, 0x4a, 0xab, 0x80, 0xb2, 0x7d, 0x4a, 0x59, 0x52, 0x3d, 0xb1, 0x1e, 0xf7, 0xb8, 0x6d, 0x73, 0xe4, 0x80, 0xf8, 0x26, 0x99, 0xe4, 0x4e, 0x2e, 0x28, 0x11, 0x72, 0xd4, 0x1c, 0xef, 0xe2, 0xa1, 0x5a, 0xae, 0x50, 0xe1, 0x39, 0x18, 0xef, 0xb6, 0x3d, 0xe0, 0x78, 0x5b, 0xa4, 0x15, 0xc7, 0xda, 0x37, 0x46, 0xa6, 0x69, 0xc7, 0xf6, 0xad, 0xac, 0x8c, 0x7e, 0xd0, 0x4f, 0xb5, 0xf8, 0xec, 0x70, 0x20, 0x76, 0x15, 0xc5, 0xb6, 0x15, 0x7f, 0x3b, 0xd9, 0xac, 0x31, 0x47, 0x8f, 0x50, 0x5, 0xf0, 0xe8, 0xde, 0x11, 0x39, 0xfd, 0xf4, 0xd, 0x2e, 0x1, 0xdb, 0xf5, 0x49, 0x73, 0xf7, 0x22, 0x5c, 0xa5, 0x45, 0xad, 0x7b, 0x8f, 0xac, 0x82, 0x33, 0xcc, 0x57, 0x9d, 0x4e, 0x6, 0x39, 0x5b, 0xae, 0x79, 0x1a, 0x5e, 0x49, 0x83, 0x8a, 0x80, 0x6f, 0x69, 0xb5, 0x78, 0x58, 0x61, 0x20, 0x63, 0x93, 0x52, 0x84, 0xf7,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24, 0x9a}, - output384: []byte{0x8c, 0x3d, 0xe4, 0xc9, 0x79, 0x46, 0xdd, 0x88, 0x4e, 0x47, 0xae, 0x66, 0x18, 0xf9, 0xb0, 0xb6, 0xbc, 0xb7, 0x14, 0xf, 0xc3, 0x6c, 0x8b, 0x39, 0x2c, 0xdd, 0x75, 0x89, 0xcd, 0x61, 0x1e, 0x62, 0x52, 0x22, 0xfe, 0x85, 0xab, 0x38, 0x59, 0x60, 0xa7, 0xe0, 0x35, 0xfe, 0x70, 0x5a, 0xa, 0x49}, - output512: []byte{0x6c, 0x1b, 0x14, 0xa6, 0xa3, 0x1, 0x26, 0xd1, 0xac, 0x4c, 0x84, 0xc2, 0xe, 0x2f, 0x1d, 0x14, 0xca, 0x93, 0x8b, 0x19, 0xa0, 0xfe, 0x8c, 0xca, 0x81, 0x16, 0xca, 0xf4, 0x89, 0xb0, 0xfe, 0x43, 0x59, 0xe5, 0x92, 0xcf, 0xe7, 0x62, 0x55, 0xa7, 0xf8, 0xd0, 0x85, 0xee, 0xb6, 0x55, 0xfc, 0xeb, 0x12, 0x7c, 0x12, 0xbb, 0xba, 0x74, 0xb1, 0x9, 0x2f, 0x37, 0xba, 0x1c, 0x9b, 0xb1, 0x3b, 0xd2}}, - testcase{ - msg: []byte{0x82, 0x4a, 0x15, 0x5d, 0x77, 0x98, 0xe1, 0x29, 0x62, 0xf4, 0x46, 0x4e, 0xad, 0x9a, 0xf1, 0x32, 0xa2, 0x26, 0xda, 0x4d, 0xa6, 0xe8, 0x99, 0x62, 0x9e, 0xfb, 0x93, 0x8e, 0xa2, 0x9a, 0x86, 0x93, 0x7f, 0xb1, 0x44, 0x86, 0x6d, 0x8c, 0x7b, 0x2d, 0xf9, 0x98, 0x86, 0x4, 0xce, 0xd9, 0x68, 0x92, 0xda, 0x48, 0x2d, 0x4d, 0xd, 0xeb, 0x46, 0x58, 0x84, 0x4f, 0x41, 0x83, 0x5f, 0xd, 0x9c, 0x20, 0xc7, 0x96, 0x92, 0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0x5b, 0x18, 0xa, 0x2d, 0x6, 0x5c, 0x31, 0xdb, 0xc1, 0xe0, 0x73, 0x7d, 0x9a, 0x80, 0x2, 0x60, 0xc7, 0x1a, 0x2, 0x44, 0xf1, 0x95, 0x28, 0xe7, 0x90, 0x72, 0xd8, 0xb8, 0x32, 0x22, 0x25, 0xc6, 0xc6, 0xae, 0x84, 0x71, 0x6, 0x8b, 0xfe, 0xb6, 0x1c, 0x57, 0x8b, 0xeb, 0x30, 0xf9, 0xab, 0x6a, 0x17, 0x3d, 0x70, 0x37, 0x3d, 0x5f, 0x28, 0xe7, 0xc3, 0x53, 0xfe, 0x72, 0x33, 0x16, 0x14, 0x3b, 0x2a, 0x6e, 0xdf, 0x78, 0xea, 0xbd, 0x60, 0x12, 0x41, 0x38, 0xb6, 0x7, 0xd9, 0xa0, 0x9d, 0x6a, 0xce, 0x70, 0x88, 0x2d, 0x43, 0x3, 0xee, 0xf2, 0xc2}, - output224: []byte{0xa3, 0xd5, 0x12, 0x8d, 0x5b, 0xc7, 0x85, 0x2e, 0xc6, 0xb5, 0x9d, 0x3d, 0x33, 0xab, 0xe7, 0xf, 0x73, 0x52, 0x39, 0xd1, 0x49, 0x59, 0x3e, 0x9d, 0x17, 0x98, 0xd1, 0xa9}, - output256: []byte{0x9f, 0x4e, 0xa3, 0x42, 0x76, 0x42, 0xd8, 0xa8, 0xb3, 0x92, 0xa5, 0x7e, 0x3f, 0x0, 0xa5, 0xca, 0xbc, 0xcf, 0x56, 0x8e, 0xb, 0x81, 0x21, 0x88, 0x14, 0xb1, 0x8e, 0xa4, 0x7c, 0x85, 0x27, 0x26}, - output384: []byte{0x9d, 0x5a, 0x13, 0x7, 0x73, 0xc6, 0x96, 0xac, 0xd0, 0xf3, 0xa, 0xd5, 0x3a, 0x93, 0xa7, 0x1f, 0x18, 0x93, 0x2a, 0x25, 0xec, 0x31, 0x3b, 0x29, 0xed, 0x9b, 0x70, 0x1d, 0xec, 0xd4, 0xdb, 0xb7, 0x89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x25, 0x59, 0x7c, 0xe2, 0x8, 0x27, 0x95, 0x27, 0x49, 0xd0, 0x20, 0xff, 0xf0, 0x7a, 0x58, 0xae, 0xd9, 0x51, 0xfd, 0x9c, 0xa9, 0xb2, 0xac, 0xb1, 0x53, 0x46, 0xd5, 0x13, 0xb3, 0x49, 0xe, 0x2c, 0x12, 0x94, 0x60, 0x5d, 0x91, 0xec, 0x67, 0xcc, 0x73, 0xf7, 0x6a, 0x38, 0xff, 0xbd, 0x86, 0xd7, 0x9c, 0x55, 0xc8, 0x65, 0x15, 0x16, 0x4a, 0x8b, 0xea, 0xcc, 0xb3, 0x86, 0xe7, 0x5e, 0xa1, 0x81, 0xc7, 0x62, 0x33, 0xc1, 0x85, 0x49, 0xd4, 0x1d, 0x5e, 0xf5, 0xf4, 0xda, 0x25, 0x80, 0x9d, 0xc7, 0x1b, 0x5c, 0x3f, 0x83, 0xa1, 0xdc, 0x31, 0xd4, 0xd1, 0x17, 0xa5, 0x75, 0x1d, 0x77, 0x38, 0xb, 0x54, 0x19, 0xa2, 0xa4, 0xa8, 0xcf, 0xd2, 0x39, 0x1d, 0xd9, 0x7f, 0x88, 0xc7, 0xc8, 0xf3, 0x9a, 0x22, 0xea, 0xe, 0xa3}, - output224: []byte{0xda, 0x3b, 0x6c, 0x90, 0x8d, 0x94, 0x7a, 0x2, 0x59, 0x2, 0x39, 0xe1, 0x11, 0xbb, 0xe4, 0xd6, 0x43, 0x66, 0x55, 0xa3, 0xf, 0x7f, 0x6f, 0x17, 0xdd, 0xf5, 0x25, 0xcf}, - output256: []byte{0x3, 0xb5, 0xa9, 0x21, 0x8a, 0xf0, 0xfb, 0x5a, 0xbd, 0x1a, 0xd6, 0xdf, 0xb1, 0xb3, 0x2e, 0x2e, 0xe8, 0x2b, 0x5, 0x4c, 0xbb, 0x4, 0x6a, 0xbc, 0x65, 0x6c, 0xc5, 0x26, 0x20, 0x82, 0x85, 0x53}, - output384: []byte{0x8a, 0x12, 0x49, 0xf0, 0xaf, 0x80, 0x50, 0x79, 0xb5, 0xf1, 0xd8, 0x23, 0xc7, 0x10, 0x1e, 0xdb, 0x47, 0x91, 0x7b, 0xf0, 0x92, 0xa8, 0xaf, 0x98, 0xda, 0x8e, 0x1b, 0x1e, 0xe1, 0xe8, 0x22, 0xa8, 0x9, 0x83, 0x55, 0xd4, 0x51, 0x42, 0xe, 0xe2, 0x41, 0x43, 0xc9, 0x97, 0x81, 0x96, 0x96, 0x98}, - output512: []byte{0xd2, 0x3b, 0x6e, 0x24, 0x24, 0x7a, 0xce, 0x20, 0xa, 0xae, 0xd6, 0x9f, 0x42, 0x5b, 0x65, 0xfc, 0xa3, 0x78, 0x11, 0x2a, 0x2b, 0x53, 0xbe, 0x7e, 0x59, 0x12, 0x52, 0x2d, 0x95, 0xa2, 0x5a, 0xde, 0x40, 0xf5, 0xc7, 0xca, 0x9f, 0x7c, 0xb9, 0xf1, 0x50, 0xa9, 0xfe, 0xd4, 0x78, 0x2b, 0xdd, 0x3f, 0xb8, 0x63, 0xbc, 0x2, 0xe9, 0xeb, 0xe, 0xfc, 0xec, 0x44, 0x23, 0x4a, 0xf7, 0x66, 0x37, 0x71}}, - testcase{ - msg: []byte{0xaf, 0x3, 0x37, 0x72, 0x47, 0x8b, 0x6c, 0x7a, 0x40, 0x59, 0x6, 0x81, 0x1d, 0x78, 0x7a, 0xcd, 0xa7, 0xb7, 0x75, 0xc2, 0x8e, 0xbf, 0xfa, 0x6, 0xae, 0xab, 0x37, 0xee, 0x36, 0x34, 0x76, 0x23, 0x9a, 0x4f, 0xa0, 0xaf, 0x7a, 0xfc, 0xed, 0xad, 0xeb, 0x2d, 0xed, 0x7c, 0xa3, 0x99, 0x7c, 0x82, 0xa5, 0x4d, 0x6f, 0xd, 0x10, 0x16, 0xc4, 0xbc, 0x2d, 0x18, 0x2f, 0x61, 0x16, 0x23, 0x26, 0x86, 0xf7, 0xb5, 0xba, 0xec, 0x0, 0x75, 0x9e, 0x7b, 0x2a, 0xcf, 0x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 0x4d, 0x92, 0x89, 0xdb, 0x2d, 0x2e, 0x76, 0x26, 0x99, 0x58, 0x3f, 0xb, 0x86, 0x4d, 0x90, 0x81, 0x61, 0x1d, 0xe2, 0xb1, 0xc0, 0x32, 0xca, 0x0, 0xc7}, - output224: []byte{0xa6, 0x35, 0x1b, 0x5, 0xaf, 0xe1, 0x91, 0x21, 0xb1, 0x59, 0x81, 0xa3, 0xd4, 0x8a, 0xfa, 0x6f, 0xd5, 0xcd, 0x7b, 0x65, 0x89, 0xa9, 0x47, 0xbc, 0xc, 0xcd, 0xf5, 0xab}, - output256: []byte{0xe2, 0x59, 0x70, 0x3b, 0xe7, 0x2c, 0xc3, 0x26, 0x9, 0x4d, 0x4d, 0x53, 0x1c, 0xd7, 0xff, 0xc6, 0xf2, 0xe5, 0xd, 0xdf, 0x39, 0x4d, 0x96, 0x4e, 0x8d, 0x29, 0xfe, 0xe3, 0xd7, 0x58, 0xe4, 0x56}, - output384: []byte{0xa7, 0xcf, 0xbb, 0x3e, 0x0, 0x67, 0x35, 0x2, 0x57, 0xab, 0xe8, 0x8f, 0x84, 0x8e, 0x17, 0x4d, 0xaa, 0xf4, 0xb9, 0x57, 0xe2, 0x2f, 0x2e, 0xea, 0x4a, 0xc3, 0xa3, 0x6f, 0x6f, 0x3c, 0x1, 0x4e, 0x19, 0xca, 0xd5, 0x83, 0x45, 0x78, 0x5e, 0xaa, 0x37, 0xcc, 0x52, 0x33, 0x87, 0xc8, 0xed, 0x54}, - output512: []byte{0x27, 0x73, 0x9b, 0xda, 0x63, 0x9d, 0x10, 0x72, 0x75, 0xfa, 0x9f, 0x84, 0x8e, 0x40, 0xf9, 0x3c, 0x20, 0xa8, 0x89, 0x45, 0xa6, 0x2a, 0x15, 0x21, 0x8f, 0xb, 0x26, 0xc4, 0xa5, 0x37, 0xee, 0x42, 0x9c, 0x1f, 0xd, 0x6, 0xe9, 0x81, 0x12, 0x38, 0x4d, 0xa6, 0xb0, 0x1f, 0xeb, 0x15, 0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0xad, 0x6, 0x79, 0x21, 0x61, 0xe7, 0x4b, 0x19, 0x11, 0x70, 0xaa, 0x23, 0x65, 0xa0, 0x44, 0x3e, 0x67, 0xea, 0x9d, 0xff, 0xea, 0xf1, 0x15, 0x3a, 0xba, 0xbf, 0xe5}, - output256: []byte{0xc4, 0x2c, 0x1, 0x3, 0x3, 0x45, 0x6f, 0xbf, 0x39, 0xc4, 0x3a, 0xa9, 0x96, 0xd4, 0x2a, 0xc8, 0x6b, 0x36, 0x3b, 0xc6, 0x36, 0x5f, 0xdb, 0xd9, 0xea, 0x75, 0x8c, 0xc8, 0x96, 0x1c, 0xd9, 0xde}, - output384: []byte{0x49, 0xaa, 0xeb, 0x1a, 0x48, 0xa1, 0x89, 0x2f, 0x4d, 0xae, 0x92, 0x8d, 0x6c, 0x40, 0xf0, 0x3e, 0x49, 0x61, 0x4b, 0xcd, 0xfa, 0xa2, 0xd9, 0xbf, 0x2b, 0xe0, 0x73, 0x87, 0x54, 0x3e, 0x66, 0x71, 0x69, 0x40, 0xc5, 0xe, 0x36, 0xc3, 0x46, 0x46, 0xd0, 0xc3, 0x8d, 0x7b, 0x90, 0xc7, 0x4b, 0x1e}, - output512: []byte{0xbc, 0xb9, 0xe2, 0x7b, 0x76, 0xf, 0xd6, 0xe3, 0x15, 0x1f, 0xef, 0x53, 0xae, 0xd0, 0xa9, 0xcb, 0x8e, 0x43, 0xc0, 0x8a, 0x4b, 0xd5, 0x4f, 0xc5, 0x70, 0x34, 0x0, 0x64, 0x7e, 0x5, 0xc0, 0x6, 0x1, 0xd, 0xdd, 0xa0, 0xac, 0x7a, 0xf9, 0x64, 0xaf, 0x45, 0x22, 0x41, 0x4e, 0x13, 0xcb, 0x4c, 0x26, 0xcb, 0xa7, 0x1c, 0x13, 0xf3, 0x34, 0x61, 0x31, 0xc9, 0x35, 0x27, 0xc4, 0x2, 0xa0, 0x97}}, - testcase{ - msg: []byte{0xa8, 0xb7, 0x48, 0xdd, 0x69, 0x59, 0xfa,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0xbd, 0x9a, 0xdc, 0xa8, 0x4c, 0x35, 0xb9, 0xaa, 0xfa, 0xba, 0x6b, 0xcf, 0x7e, 0xd0, 0xd2, 0x2d, 0xa8, 0x7f, 0xb6, 0xeb, 0x81, 0x45, 0x59, 0x1c, 0x9b, 0x36, 0x52, 0xa4, 0xea, 0xc2, 0x56}, - output224: []byte{0xb1, 0xa2, 0x9c, 0x0, 0xab, 0x23, 0x41, 0xa7, 0x7c, 0xfe, 0xd8, 0x39, 0x8f, 0x23, 0x2b, 0x1f, 0xb5, 0x7b, 0xf4, 0x57, 0x2e, 0xaa, 0xb7, 0x56, 0xd, 0x7d, 0x4c, 0xd6}, - output256: []byte{0x1b, 0xae, 0x63, 0x99, 0x40, 0xec, 0x63, 0xdc, 0xb6, 0x7f, 0x9e, 0x80, 0x6c, 0x4b, 0x2e, 0xde, 0x67, 0x51, 0xcf, 0x54, 0xe, 0x63, 0xbc, 0xec, 0xa, 0xd8, 0x3d, 0x79, 0x6, 0xa8, 0x91, 0x37}, - output384: []byte{0x1d, 0x67, 0xe9, 0x94, 0xaf, 0x91, 0x86, 0xa2, 0x1a, 0xbb, 0x67, 0xaa, 0x4c, 0x54, 0x41, 0xfb, 0xd8, 0x6f, 0x7, 0x81, 0x4a, 0xa9, 0xeb, 0x38, 0x50, 0x8f, 0x9, 0x9c, 0x5c, 0xb, 0xbb, 0x41, 0x96, 0xf5, 0x17, 0x3d, 0xe4, 0x8f, 0x19, 0xbb, 0xab, 0x68, 0x42, 0xea, 0x51, 0x96, 0x2d, 0x8c}, - output512: []byte{0x26, 0xd9, 0x3e, 0x60, 0x41, 0x3e, 0x83, 0x23, 0xbc, 0xf6, 0x71, 0x44, 0xe8, 0x46, 0xe1, 0x97, 0x51, 0x10, 0x3c, 0xd1, 0xec, 0x47, 0x49, 0x93, 0x9, 0x25, 0x17, 0xa6, 0x3f, 0x40, 0x10, 0x1b, 0xea, 0x10, 0xc8, 0xd1, 0x20, 0xfa, 0x7, 0x7a, 0x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x6f, 0xe3, 0x98, 0x40, 0x4a, 0xe0, 0x47, 0xf6, 0x4e, 0xc4, 0x26, 0x35, 0x66, 0xde, 0xfe, 0xe6, 0x63, 0x29, 0xdd, 0x40, 0xac, 0x98, 0x5e, 0xb8, 0xa0, 0x8d, 0x26, 0x52, 0x9a, 0x54, 0x48, 0x91, 0xb6, 0xf5, 0x7c, 0xc2, 0x35, 0xc6, 0x3c, 0x9, 0x5, 0x7a, 0xb6, 0xb6, 0xed, 0x72, 0xe, 0xf4, 0x1a, 0x3c, 0x9a, 0xe6, 0x57, 0x68, 0xb4, 0x3f, 0x6d, 0xcf, 0x49, 0x62, 0xa1, 0x3, 0xdd, 0x93, 0xc2, 0x13, 0x17, 0x1d, 0xc2, 0xc9, 0x19, 0x4e, 0x43, 0x26, 0x5c, 0x68, 0x9b, 0x49, 0x33, 0x14, 0x50, 0x28, 0x1a, 0x3f, 0xeb, 0xc6, 0x18, 0xd1, 0xaa, 0x4d, 0x65, 0xa1, 0x35, 0x13, 0x70, 0x51, 0xfd, 0x46, 0xb5, 0x68, 0xce, 0x29, 0x4c, 0x89}, - output224: []byte{0x2c, 0x70, 0xb, 0x40, 0x59, 0x91, 0x6a, 0xf3, 0xf4, 0x7d, 0x90, 0x17, 0xf5, 0x72, 0x5f, 0x42, 0xb0, 0xd5, 0x18, 0x95, 0x33, 0x1f, 0x9, 0x0, 0x48, 0xc2, 0x76, 0xa0}, - output256: []byte{0x96, 0xba, 0xee, 0x8e, 0xca, 0x9d, 0xcd, 0xbd, 0xc4, 0x67, 0x54, 0x9e, 0x30, 0x7d, 0x95, 0xc2, 0xa, 0x7, 0xfe, 0xb7, 0x2e, 0xcc, 0xc7, 0x80, 0xdb, 0xc2, 0x9d, 0x40, 0xae, 0x7c, 0xae, 0x45}, - output384: []byte{0xe1, 0x7a, 0x2a, 0x66, 0x7, 0x82, 0xbd, 0xe, 0xb5, 0x7b, 0x46, 0x3a, 0xfa, 0xa7, 0x45, 0xf6, 0x58, 0xbd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0x38, 0xd1, 0x32, 0x6b, 0x5d, 0x2e, 0x18, 0x70, 0x53, 0x77, 0x77, 0xec, 0x8a, 0x47, 0xe6, 0x9e, 0xb5, 0x4a, 0x30, 0xf9, 0xb1, 0xae, 0x21, 0x4e, 0xd0, 0xa1, 0x45, 0x6, 0xec, 0x21, 0x8b, 0x5, 0xcc, 0x44, 0x8, 0x6f, 0x65, 0x30, 0x48, 0xd7, 0xe0, 0x69, 0x49, 0xd6, 0x1, 0x7b, 0xdc, 0xc7, 0x71, 0x39, 0x83, 0xb6, 0xea, 0x9d, 0xd7, 0xd7, 0x93, 0x65, 0x43, 0x1d, 0xfe, 0xca, 0x3a, 0xf4, 0xf6, 0xcf, 0x1e, 0xfa, 0x18, 0xad, 0x23, 0xb7, 0x16, 0x81, 0x4f, 0x61, 0x4e, 0xd2, 0xa2, 0x2a, 0x5d, 0x8b, 0x37, 0x7f, 0x44, 0x2f, 0x2c, 0x40, 0x2d, 0xe0, 0x5c, 0xc8, 0xc2, 0xdb, 0xaa, 0x50, 0x76, 0x13, 0x3e, 0x9, 0x5, 0xff, 0x84, 0x3d, 0x64, 0x54, 0x5a, 0x74, 0x9, 0x71, 0x1e, 0x15, 0x63, 0x7, 0x1c, 0x5d, 0x48, 0xe2, 0xae, 0x76, 0x5a, 0xfd, 0xba, 0xa8, 0x4c, 0x24, 0x99, 0xfa, 0xc8, 0xf1, 0x84, 0x8d, 0xb6, 0x5b, 0x74, 0x57, 0x76, 0xa4, 0x92, 0x11, 0xd0}, - output224: []byte{0xf6, 0x2e, 0xd9, 0xff, 0x9d, 0x91, 0xda, 0xa0, 0x54, 0xc2, 0x59, 0x27, 0xa1, 0xea, 0x4c, 0x85, 0x3e, 0xd9, 0xb3, 0xca, 0x63, 0xfe, 0xa7, 0x8a, 0x67, 0x12, 0x13, 0xe6}, - output256: []byte{0xfb, 0xf2, 0xfb, 0xa4, 0x5d, 0x6f, 0x2, 0xbc, 0xfa, 0x87, 0x88, 0xc4, 0x43, 0x70, 0x11, 0x4, 0xfe, 0xc7, 0xc8, 0x17, 0x0, 0xaa, 0xf2, 0xd0, 0x31, 0x11, 0x32, 0x95, 0x8e, 0x1b, 0xa5, 0x7f}, - output384: []byte{0xc8, 0xaa, 0x4a, 0xaa, 0x57, 0xd5, 0x24, 0x1a, 0xbf, 0xa4, 0xb4, 0x98, 0x64, 0xa, 0x36, 0x5d, 0x98, 0x76, 0x82, 0xcf, 0x66, 0xa0, 0xdd, 0x23, 0x59, 0xb8, 0x23, 0x92, 0x1b, 0x94, 0x62, 0x35, 0x65, 0x69, 0xc9, 0x66, 0xfc, 0x39, 0x11, 0xec, 0xfc, 0x40, 0xa7, 0x14, 0xed, 0xd2, 0xb3, 0x58}, - output512: []byte{0x31, 0x6, 0x1c, 0x59, 0xc5, 0xc6, 0xc, 0x55, 0xf0, 0xd3, 0x3e, 0xa7, 0x74, 0x94, 0x94, 0x7e, 0x6f, 0xdb, 0x71, 0xe8, 0x4e, 0x3c, 0x20, 0x7, 0xaf, 0xf1, 0x25, 0x7a, 0xda, 0x79, 0x71, 0xd, 0x41, 0x6b, 0x3a, 0x71, 0xa4, 0x10, 0x8f, 0x31, 0x89, 0xe2, 0x89, 0x8a, 0x19, 0x12, 0x47, 0xf0, 0xf2, 0xe0, 0x2c, 0xb9, 0xf2, 0x1a, 0x93, 0x3d, 0x14, 0x5, 0xb1, 0x55, 0xd9, 0xab, 0x33, 0x32}}, - testcase{ - msg: []byte{0xb8, 0xb2, 0x7e, 0xf9, 0x41, 0x79, 0x2b, 0xd6, 0x81, 0x97, 0x47, 0x43, 0x2c, 0xb8, 0x44, 0xd1, 0x1d, 0x32, 0x75, 0xe2, 0x35, 0xd6, 0xa0, 0x48, 0x42, 0xd0, 0xea, 0x1b, 0xe5, 0xa7, 0x27, 0xe, 0x3d, 0x32, 0x92, 0x4d, 0x2f, 0x74, 0xde, 0xb9, 0xac, 0x5a, 0x86, 0x91, 0x61, 0x7a, 0x1c, 0xbc, 0x10, 0x46, 0x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5, 0x53, 0xfc, 0x44, 0xb5, 0xf1, 0xba, 0xe4, 0x64, 0xb, 0x13, 0x47, 0xa9, 0x9c, 0xe9, 0x8e, 0x22, 0x4f, 0x88, 0x10, 0x98, 0x3d, 0x64, 0x15, 0x4a, 0x7f, 0xf5, 0xcc, 0xab, 0xc1, 0x38, 0xe4, 0xc4, 0x22, 0x57, 0xdc, 0x2b, 0x5e, 0x56, 0x91, 0xfc, 0xe4, 0xbf, 0x4a, 0x88, 0x96, 0x5a, 0xa3, 0x46, 0x8, 0x71, 0xa6, 0xea, 0xa3}, - output224: []byte{0x88, 0xf4, 0x69, 0x98, 0x92, 0xc2, 0x1e, 0x5, 0x64, 0x5a, 0x3, 0x5a, 0xe6, 0x62, 0x59, 0xd4, 0x46, 0xaf, 0xba, 0xa2, 0x2e, 0x35, 0x2a, 0xe1, 0x8f, 0x66, 0x8c, 0x9e}, - output256: []byte{0xa3, 0xba, 0xd4, 0x19, 0x5, 0xd8, 0xd5, 0x9, 0x95, 0x1e, 0xbe, 0xcc, 0xf3, 0x14, 0x8d, 0x52, 0x34, 0xd3, 0x98, 0x7b, 0x34, 0x84, 0x42, 0x70, 0xdc, 0xe8, 0x15, 0x8f, 0x15, 0x4, 0x51, 0x1e}, - output384: []byte{0x92, 0xce, 0x8d, 0xbe, 0xab, 0xa7, 0x35, 0x97, 0x51, 0x93, 0x9f, 0x3b, 0x5c, 0x8f, 0xa6, 0xdf, 0x41, 0xc2, 0xe5, 0x4b, 0x42, 0x86, 0x41, 0xac, 0xa9, 0x1e, 0x41, 0xeb, 0x52, 0xc5, 0x8d, 0x41, 0xe1, 0x34, 0x84, 0xa7, 0x41, 0x43, 0xaa, 0xd5, 0x45, 0xc8, 0xfe, 0x62, 0xf, 0xb7, 0xfa, 0x72}, - output512: []byte{0x39, 0x20, 0x5e, 0x6d, 0xff, 0x23, 0x16, 0xf0, 0x0, 0xa6, 0xe8, 0x2d, 0x56, 0x3e, 0x79, 0xa9, 0x2, 0x72, 0x80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, 0x21, 0x96, 0x6c, 0xd3, 0x3d, 0x86, 0xc6, 0x27, 0x5c, 0x1, 0x8f, 0xd2, 0xc1, 0x5a, 0xec, 0x46, 0xc0, 0x95, 0xac, 0xc, 0xd5, 0x15, 0x93, 0xcf, 0xb6, 0x46, 0xe8, 0xa5, 0xf8}, - output224: []byte{0x86, 0x89, 0xce, 0x87, 0x86, 0x4b, 0x65, 0x86, 0x6e, 0x50, 0xae, 0x81, 0x73, 0xbf, 0x9f, 0xde, 0x1e, 0x6c, 0x0, 0xf5, 0xd, 0x27, 0x99, 0xf5, 0xaf, 0x77, 0xed, 0x4f}, - output256: []byte{0x54, 0x21, 0x6e, 0x68, 0xa6, 0xbb, 0xdd, 0xd2, 0x78, 0x27, 0xd5, 0xfc, 0xa1, 0x1b, 0x1, 0x10, 0xff, 0xa8, 0x9d, 0x78, 0x96, 0xe5, 0x91, 0x4d, 0x57, 0x49, 0x5b, 0xd2, 0xc3, 0x9e, 0x94, 0x95}, - output384: []byte{0x53, 0xcc, 0xe2, 0xb5, 0x93, 0xe0, 0xd1, 0xfa, 0xbd, 0x91, 0xb6, 0x2e, 0x33, 0x49, 0x15, 0x66, 0xf9, 0x5d, 0xa2, 0x10, 0x6a, 0xda, 0xed, 0x5, 0x5e, 0x1, 0x6, 0x15, 0xc9, 0x3f, 0x7, 0x34, 0xcd, 0x27, 0x79, 0x21, 0x23, 0xc3, 0xf4, 0x3f, 0x44, 0xa9, 0x4f, 0xd5, 0x2d, 0x5e, 0xca, 0x97}, - output512: []byte{0xf7, 0x15, 0xdd, 0xae, 0x51, 0xac, 0xe7, 0xb5, 0xbb, 0xd9, 0x13, 0x32, 0x98, 0x4a, 0x92, 0x17, 0xb3, 0x39, 0xfa, 0xc4, 0xc1, 0xc7, 0xb1, 0x76, 0x18, 0xf5, 0xa, 0xf, 0x2d, 0x16, 0xd8, 0x6a, 0xe3, 0x85, 0x66, 0x64, 0x65, 0x4, 0x6, 0x5f, 0x67, 0xcd, 0xf3, 0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a, 0xcf, 0x58, 0x90, 0x43, 0x29, 0x26, 0x85, 0xf2, 0xc0, 0xe7, 0x32, 0x3, 0xe8, 0x58, 0x8b, 0x62, 0x55, 0x4f, 0xf1, 0x9d, 0x62, 0x60, 0xc7, 0xfe, 0x48, 0xdf, 0x30, 0x15, 0x9, 0xd3, 0x3b, 0xe0, 0xd8, 0xb3, 0x1d, 0x3f, 0x65, 0x8c, 0x92, 0x1e, 0xf7, 0xf5, 0x54, 0x49, 0xff, 0x38, 0x87, 0xd9, 0x1b, 0xfb, 0x89, 0x41, 0x16, 0xdf, 0x57, 0x20, 0x60, 0x98, 0xe8, 0xc5, 0x83, 0x5b}, - output224: []byte{0x3a, 0x44, 0x7c, 0x96, 0xe9, 0x7c, 0xab, 0xba, 0x2a, 0xed, 0xfb, 0x3d, 0xfd, 0x1a, 0x56, 0x3f, 0xe0, 0x5d, 0xf, 0x13, 0x32, 0x6b, 0xa5, 0x43, 0x75, 0x27, 0x4e, 0xb1}, - output256: []byte{0x3c, 0x79, 0xa3, 0xbd, 0x82, 0x45, 0x42, 0xc2, 0xa, 0xf7, 0x1f, 0x21, 0xd6, 0xc2, 0x8d, 0xf2, 0x21, 0x3a, 0x4, 0x1f, 0x77, 0xdd, 0x79, 0xa3, 0x28, 0xa0, 0x7, 0x81, 0x23, 0x95, 0x4e, 0x7b}, - output384: []byte{0x2a, 0xad, 0x66, 0x1e, 0xbc, 0x40, 0x4e, 0xfe, 0xdc, 0xfb, 0x7, 0x11, 0xe6, 0x9d, 0x0, 0xf1, 0xfb, 0x7d, 0x40, 0x3d, 0x97, 0x25, 0xaa, 0x1f, 0xb9, 0xa4, 0x3e, 0x40, 0xd0, 0xf3, 0x24, 0x95, 0x71, 0xa3, 0xad, 0xa0, 0x1f, 0x73, 0xf8, 0x3b, 0x2d, 0x46, 0x99, 0x57, 0x48, 0x5, 0x3f, 0x77}, - output512: []byte{0x5f, 0xb5, 0x2a, 0xb6, 0xba, 0xdf, 0xe3, 0xd5, 0x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xed, 0x7f, 0x75, 0x1, 0xd0, 0xc2, 0x93, 0x7b}, - output256: []byte{0x22, 0x61, 0x4d, 0x37, 0x96, 0x59, 0xde, 0xc8, 0xf3, 0x4b, 0x89, 0x26, 0xf9, 0x19, 0x15, 0x16, 0x38, 0xc1, 0xeb, 0xb8, 0x71, 0x30, 0x4e, 0x51, 0x90, 0x6, 0xe1, 0x85, 0xf8, 0xe2, 0x25, 0xde}, - output384: []byte{0xd, 0x25, 0xfc, 0xc6, 0x35, 0x27, 0xef, 0xf5, 0x2d, 0x6e, 0x4c, 0x3e, 0x3f, 0x96, 0x63, 0xa9, 0xf, 0x8d, 0xbb, 0xfb, 0x50, 0xbc, 0x20, 0x35, 0x5c, 0x4e, 0x88, 0x79, 0x26, 0xe8, 0xdd, 0x45, 0xcc, 0x4, 0x15, 0x2c, 0x88, 0xf4, 0x23, 0x1, 0x3c, 0x3c, 0x40, 0xca, 0xc7, 0x6e, 0xa7, 0x80}, - output512: []byte{0x8b, 0x6, 0xcd, 0x2b, 0x1e, 0xba, 0x5b, 0x4f, 0x60, 0x7b, 0x2e, 0xf6, 0x1e, 0x1d, 0xc2, 0x4b, 0x26, 0xce, 0x8a, 0x50, 0xf2, 0x26, 0xfd, 0x78, 0x61, 0x35, 0x40, 0x67, 0x50, 0x9, 0xe9, 0x46, 0x88, 0x1f, 0xa1, 0x9d, 0x4e, 0xf0, 0x17, 0x2c, 0x90, 0xe5, 0xd1, 0xa1, 0x99, 0x27, 0xc6, 0xd9, 0x2d, 0x86, 0x2f, 0xd5, 0x13, 0xda, 0x66, 0x42, 0x8b, 0x8, 0x49, 0x16, 0x23, 0x58, 0x49, 0x38}}, - testcase{ - msg: []byte{0xcf, 0xf5, 0x45, 0x96, 0xc3, 0x15, 0x40, 0x30, 0x90, 0xb3, 0xdf, 0x12, 0x53, 0xc9, 0x77, 0x9b, 0x89, 0xe8, 0x66, 0xf1, 0x42, 0x1e, 0x13, 0xf7, 0x64, 0x6e, 0x3c, 0xc1,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b1, 0xf9, 0xb7, 0x98, 0xdd, 0xa9, 0x99, 0x96, 0x35, 0x6c, 0xf6, 0x5, 0x55, 0xdc, 0x63, 0xee, 0x40, 0xb2, 0x3c, 0x77, 0xfc, 0xe4, 0x38, 0x79, 0xc, 0x8f, 0x25, 0x0, 0x30, 0x3, 0x32, 0xa, 0xba, 0x73, 0x1a, 0x2f, 0x23, 0x37, 0x25, 0xff, 0x7d, 0x62, 0xa4, 0x9e, 0x76, 0xbc, 0xeb, 0x7e, 0xc7, 0x6f, 0x58, 0x55, 0x8c, 0x2, 0x56, 0x72, 0xd7, 0x14, 0x4e, 0x59, 0x43, 0x40, 0x8f, 0x4d, 0xaf, 0x60, 0xe4, 0xd9, 0x91, 0x99, 0xb, 0x51, 0xf, 0x54, 0x85, 0x51, 0xf2, 0xab, 0xac, 0x99, 0x6e, 0x60, 0x3f, 0x55, 0x90, 0x51, 0xc4, 0xa8, 0x2c, 0x81, 0x81, 0xe9, 0x67, 0xee, 0xe7, 0x2e, 0x5, 0xae, 0x35, 0x8, 0xe1, 0x81, 0xdb, 0x54, 0xc8, 0xee, 0xa4, 0xc0, 0x5d, 0x2c, 0x94, 0x40, 0x52, 0x1e, 0xb1, 0x93, 0x8, 0xb3, 0xd5, 0xf0, 0xb5, 0x48, 0x59, 0x2, 0xa6, 0xb0, 0x1a, 0x5a, 0xe0, 0x4f, 0xa, 0x4d, 0x57, 0x12, 0xc2, 0x83, 0x8c, 0x81, 0x50, 0x98}, - output224: []byte{0x13, 0xb7, 0x2f, 0x2c, 0xba, 0x9f, 0x9a, 0x26, 0x92, 0x2e, 0xe7, 0xa8, 0xe5, 0x72, 0x2a, 0xed, 0xd6, 0x27, 0x82, 0xd4, 0x67, 0x96, 0x49, 0xec, 0xa6, 0xcb, 0x48, 0xc6}, - output256: []byte{0xab, 0x9b, 0xeb, 0xef, 0x5, 0x3a, 0xd5, 0x70, 0x60, 0xfb, 0xa, 0x7c, 0xbf, 0xc7, 0xe4, 0x2a, 0x6d, 0x78, 0xb4, 0x9f, 0x60, 0xcd, 0xb5, 0xaa, 0x8b, 0xd3, 0xbc, 0xe1, 0x73, 0xb5, 0xc2, 0xb7}, - output384: []byte{0x92, 0x91, 0xd0, 0x1c, 0x91, 0x3e, 0xe2, 0x5e, 0x11, 0xc1, 0x6a, 0x2f, 0xd2, 0x4e, 0x89, 0xab, 0x9, 0x14, 0x91, 0xfb, 0xfb, 0xe8, 0x5a, 0xde, 0x41, 0x12, 0x28, 0xac, 0x35, 0xc2, 0x8d, 0xc0, 0xce, 0x9b, 0x2e, 0x9a, 0x9, 0x8, 0xad, 0x28, 0x8b, 0x3b, 0xf8, 0x8c, 0x49, 0x29, 0xae, 0x5}, - output512: []byte{0x6, 0x7, 0x15, 0xba, 0xf2, 0x20, 0xba, 0xce, 0xab, 0x6e, 0xf1, 0x57, 0x56, 0x98, 0x5c, 0xc0, 0xcc, 0x2d, 0x60, 0x85, 0x40, 0x99, 0x51, 0x6, 0x20, 0x89, 0x6b, 0x76, 0x53, 0x20, 0x4d, 0xfa, 0x9e, 0x57, 0xfd, 0xbb, 0xa3, 0x45, 0x5c, 0x63, 0x7e, 0xd4, 0x88, 0xc1, 0xa1, 0x3e, 0x6c, 0x67, 0x89, 0x38, 0x49, 0xbc, 0x1, 0x7c, 0x34, 0x18, 0x45, 0x48, 0x5a, 0x3a, 0x8c, 0x38, 0x8c, 0xf3}}, - testcase{ - msg: []byte{0x94, 0x13, 0x3b, 0x8e, 0x14, 0x78, 0x5f, 0xc1, 0x95, 0x65, 0xa3, 0xaf, 0xa, 0xef, 0x60, 0x46, 0x2b, 0xb7, 0xf8, 0x4, 0x5e, 0x2e, 0xdf, 0x4a, 0x83, 0x67, 0x18, 0x56, 0x1a, 0xee, 0xfb, 0xd0, 0x38, 0x24, 0x34, 0xd3, 0x19, 0x21, 0x1c, 0x67, 0xf, 0xc6, 0x99, 0xd2, 0x5f, 0x2, 0xec, 0x60, 0x8c, 0xfe, 0xd9, 0x78, 0x6b, 0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x28, 0x4e, 0x38, 0x7, 0x8a, 0x5e, 0x48, 0x50, 0x74, 0x89, 0x65, 0x55, 0x72, 0x71, 0xff, 0xa, 0x84, 0x84, 0x89, 0xd2}, - output256: []byte{0x20, 0x52, 0x6a, 0xd, 0x4e, 0x6f, 0x6, 0x24, 0x52, 0x1b, 0x3, 0x69, 0x83, 0xfd, 0xd4, 0xf3, 0x7b, 0xc7, 0x9b, 0x79, 0xf, 0xe2, 0xaa, 0x8a, 0xed, 0x1b, 0x16, 0x6b, 0x40, 0xcd, 0x99, 0x9d}, - output384: []byte{0xfc, 0xf, 0x4, 0xe5, 0xc1, 0x67, 0x21, 0x10, 0x1e, 0x7a, 0x92, 0x54, 0xd2, 0x78, 0x3b, 0x61, 0x9f, 0x78, 0xa5, 0x26, 0xe4, 0x0, 0x6c, 0x43, 0xe6, 0xd1, 0x23, 0x51, 0x28, 0x12, 0x27, 0xd1, 0x3b, 0xc5, 0x7c, 0x8c, 0xf3, 0x86, 0x52, 0xff, 0xdf, 0x56, 0xa8, 0x88, 0xcd, 0x90, 0x22, 0x9d}, - output512: []byte{0x50, 0x59, 0x3e, 0xd5, 0xad, 0xf3, 0x21, 0x50, 0x10, 0x53, 0x1e, 0x3a, 0x1b, 0xb6, 0x58, 0x5f, 0x94, 0xca, 0xd6, 0xb5, 0x7f, 0x34, 0x72, 0x74, 0x18, 0xc2, 0x9d, 0xa1, 0xdd, 0xf9, 0xd0, 0x61, 0xb, 0xac, 0x77, 0x81, 0xff, 0xf7, 0x96, 0x62, 0x7c, 0x9f, 0x51, 0xc1, 0x8b, 0x1f, 0xf, 0x4, 0x60, 0xf9, 0xba, 0x9c, 0x13, 0xb0, 0x95, 0x61, 0x7c, 0xc7, 0x8d, 0x18, 0xa, 0x71, 0x9b, 0x1}}, - testcase{ - msg: []byte{0xf5, 0x8, 0xd, 0x4c, 0x59, 0xe8, 0x4, 0xbf, 0x8f, 0x34, 0xb3, 0x34, 0xca, 0xbb, 0xcc, 0x7d, 0x32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x22, 0xc9, 0xa3, 0xd1, 0xab, 0xf6, 0xe7, 0x7b, 0x5e, 0xd7, 0xfe, 0x2f, 0x72, 0x28, 0xfe, 0xd6, 0xc8, 0x49, 0xbf, 0x71, 0x42, 0xc4, 0x10, 0x39, 0x89, 0xa8, 0xf, 0x7c, 0x15, 0x64, 0x2a, 0xe6, 0x16, 0x50, 0xcd, 0xca, 0x7e, 0x85, 0x4e, 0xb2, 0x5e, 0x9e, 0x72, 0xf4, 0xc3, 0xe3, 0x76, 0x8e, 0x6c, 0xcc, 0x8b, 0xfd, 0x55, 0x6b, 0x56, 0xd3, 0x50, 0x7e, 0xdd, 0xe9, 0xe5, 0xc3, 0x31, 0xdd, 0xea, 0x75, 0x56, 0x8b, 0x7, 0x81, 0x3d, 0x20, 0xe8, 0xf4, 0xc9, 0x54, 0x78, 0x38, 0xed, 0x28, 0x44, 0x8f, 0x2e, 0x67, 0x15, 0x8a, 0xcf, 0xc, 0x0, 0xb1, 0x31, 0x47, 0x38, 0x47, 0x81, 0x6c, 0x5e, 0x2d, 0xc2, 0x15}, - output224: []byte{0xb4, 0x97, 0x8f, 0x5d, 0xe0, 0x29, 0x5, 0x35, 0x5d, 0x9d, 0x40, 0xfa, 0x9, 0xe6, 0xf8, 0xa2, 0x97, 0xca, 0x54, 0x6a, 0xc8, 0x38, 0x2c, 0xf1, 0x1, 0x52, 0xb2, 0xb3}, - output256: []byte{0x6c, 0x87, 0x23, 0xda, 0x27, 0xcd, 0x98, 0xe2, 0xf, 0x25, 0x83, 0xd0, 0x18, 0x68, 0x5, 0x1e, 0xf2, 0xda, 0xfa, 0x64, 0x59, 0x1, 0xf8, 0x2c, 0x74, 0xd5, 0x32, 0xe, 0xaf, 0xc1, 0x8a, 0xac}, - output384: []byte{0x74, 0xb1, 0x9a, 0x3c, 0xc5, 0x77, 0x84, 0x7c, 0x75, 0x7b, 0x8, 0xc2, 0xe1, 0x9c, 0x9e, 0x94, 0x92, 0xf8, 0xc5, 0xa8, 0xeb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0xdd, 0x25, 0xa5, 0xb7, 0x67, 0x55, 0x38, 0xb, 0xa7, 0xe2, 0xea, 0x2, 0x14, 0x2e, 0x43, 0xa3, 0xff, 0xfb, 0x6f, 0x1b, 0xed, 0x55, 0x9c, 0xaa, 0x68, 0xb0, 0x9d, 0xfc, 0x8d, 0xfc, 0x18, 0x64, 0xed, 0xaf, 0xf7, 0x5, 0xbb, 0x1e, 0x30, 0xfb, 0x58, 0xc3, 0xa2, 0x7c, 0x5b, 0x1c, 0x42, 0x5b, 0x22, 0xd0, 0xc1, 0x7, 0x37, 0x26, 0xa2, 0xca, 0xae, 0x5c, 0xfa, 0x63, 0x1c, 0xc2, 0xed, 0xac, 0x96, 0xc1, 0xf, 0xb2, 0x53, 0x29, 0xf0, 0xe6, 0xd1, 0x5e, 0x4d, 0x52, 0x69, 0x4f, 0x86, 0x70, 0xd3, 0xd0, 0x54, 0xe9, 0xfb, 0xb2}, - output224: []byte{0xdf, 0x76, 0x57, 0x85, 0xbb, 0x97, 0xba, 0x37, 0x86, 0xea, 0x56, 0xdf, 0xe8, 0x5a, 0xf5, 0xc7, 0x34, 0x47, 0x13, 0xeb, 0x5f, 0xee, 0xf3, 0x74, 0xed, 0xe9, 0xe6, 0x60}, - output256: []byte{0xc3, 0x6a, 0xc1, 0x51, 0xbe, 0x54, 0x58, 0x23, 0x9a, 0xe7, 0xa0, 0xe6, 0xb4, 0x70, 0x69, 0x50, 0xa1, 0xc6, 0xb0, 0x46, 0xf0, 0x2d, 0x64, 0x29, 0x5d, 0xc1, 0xe5, 0xe9, 0x6e, 0x7f, 0xfd, 0x5b}, - output384: []byte{0x2e, 0xf1, 0x6b, 0xfe, 0xf6, 0xea, 0x7a, 0x6, 0xc3, 0x80, 0xb8, 0x8d, 0xbc, 0x41, 0x27, 0x7b, 0xea, 0x79, 0x6e, 0xf1, 0xba, 0x8d, 0x7c, 0xdd, 0x32, 0xef, 0x15, 0xcf, 0x6e, 0xb0, 0x7a, 0x23, 0x4, 0xf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 0xd7, 0x99, 0x7c, 0x28, 0xe2, 0xd4, 0xdc, 0x6e, 0x64, 0xee, 0x5e, 0x24, 0x20}, - output384: []byte{0x53, 0xc1, 0x19, 0xf, 0x68, 0xf5, 0xad, 0xff, 0x7, 0xe0, 0x51, 0xc7, 0xbc, 0xa8, 0x96, 0x1c, 0x48, 0xe9, 0x76, 0x84, 0xb3, 0xa2, 0x9c, 0xf6, 0xa6, 0x8, 0x23, 0x23, 0x30, 0x0, 0x73, 0x67, 0xcf, 0xb4, 0xe3, 0x9d, 0xd9, 0x3, 0x98, 0xd9, 0x30, 0x3e, 0x1f, 0x85, 0xf5, 0x1d, 0x14, 0x66}, - output512: []byte{0x7b, 0x4d, 0xff, 0x95, 0xfa, 0x73, 0x60, 0xe9, 0xec, 0xa6, 0x86, 0x29, 0x30, 0x3d, 0x9, 0x3f, 0x3c, 0xa9, 0x29, 0x44, 0xf9, 0x91, 0xb0, 0xa7, 0x19, 0xfc, 0xc3, 0x16, 0xf6, 0x57, 0xbb, 0xa3, 0xfa, 0xae, 0xf5, 0xd4, 0x35, 0x68, 0xeb, 0x88, 0x59, 0x1e, 0x86, 0x42, 0x7d, 0xef, 0x6b, 0xd7, 0xc8, 0x8f, 0xc7, 0xdb, 0x27, 0x11, 0x82, 0xee, 0x8c, 0x49, 0x5b, 0xdf, 0x4d, 0xec, 0x74, 0xe8}}, - testcase{ - msg: []byte{0xca, 0xd9, 0xef, 0x7, 0x7a, 0x98, 0xe3, 0xf2, 0xe5, 0x70, 0x6e, 0xbe, 0xc4, 0x96, 0xd, 0x5a, 0x5b, 0x78, 0xb5, 0x7c, 0xc8, 0x1, 0x7d, 0xb1, 0x11, 0x2f, 0x2c, 0x53, 0x70, 0x76, 0x35, 0xc, 0x80, 0x7d, 0x5c, 0xb1, 0x42, 0x1c, 0x23, 0x5a, 0xd2, 0xf8, 0xab, 0xf7, 0xce, 0x90, 0x5c, 0x26, 0xb1, 0x85, 0x66, 0xd8, 0xfd, 0x6a, 0xf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x2, 0x6c, 0x3e, 0x66, 0xe4, 0xf0, 0xa3, 0x84, 0x7a, 0xa4, 0x98, 0x15, 0xcf, 0x40, 0xc9, 0x2, 0xba, 0x79, 0xec, 0x7c, 0x4e, 0x3d, 0x82, 0xee, 0x14, 0xc, 0x8c, 0x9, 0xf7, 0x3e, 0xba, 0xac, 0xb, 0x5c, 0xa1, 0x17, 0x23, 0xb0, 0x87, 0x93, 0xfe, 0x17, 0xdf, 0xf3, 0xef, 0xca, 0xc0, 0xc5, 0x76, 0xd8, 0xf5, 0xd9, 0x69, 0x9b, 0x74, 0x18, 0x61, 0xe6, 0xe2, 0xe9, 0x77, 0xa}, - output224: []byte{0xfd, 0x1, 0xd3, 0x42, 0xd2, 0x1, 0xaf, 0x1, 0x2a, 0xd2, 0xc, 0xd5, 0x86, 0x30, 0xdf, 0x41, 0x12, 0xec, 0xcf, 0xe4, 0xcf, 0x2e, 0x87, 0x26, 0x28, 0xd9, 0xfb, 0x80}, - output256: []byte{0xa0, 0x20, 0xf8, 0xf6, 0x46, 0x48, 0x53, 0xc4, 0x64, 0x91, 0xd1, 0x7d, 0xe7, 0x6e, 0xd9, 0x81, 0x57, 0xe, 0x18, 0x20, 0x57, 0xea, 0x64, 0xbf, 0xc4, 0xc9, 0x88, 0xae, 0x58, 0x1b, 0xb8, 0x9e}, - output384: []byte{0xad, 0x99, 0xc9, 0x7f, 0xc, 0xa5, 0xa5, 0x68, 0xf, 0x2a, 0x89, 0x5f, 0xf7, 0x9e, 0xa0, 0x9a, 0x42, 0x20, 0xdc, 0x74, 0x28, 0xdd, 0x5e, 0x78, 0x8, 0x1b, 0xc5, 0x4c, 0x7a, 0x49, 0xa4, 0xde, 0x4f, 0x1, 0x83, 0x61, 0x3, 0x88, 0x28, 0x7e, 0xa0, 0xde, 0x88, 0xa, 0xc6, 0xea, 0xbe, 0xfa}, - output512: []byte{0xf2, 0x9c, 0x92, 0xba, 0x7a, 0xe0, 0x87, 0xbf, 0x53, 0x51, 0x26, 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 0xd8, 0xcf, 0xe, 0x70, 0xa4, 0x82, 0xf2, 0x24, 0xe0, 0xf4, 0xf3, 0xcc, 0xde, 0xaa, 0x55, 0xa2, 0x26, 0x55, 0xb4, 0x48, 0x2e, 0xe2, 0x3f, 0x7b, 0x5d, 0x3e, 0xe1, 0x3, 0x68, 0x89, 0xfe, 0x5f, 0xf8, 0x88, 0x56, 0xc0, 0x54, 0x5b, 0x9, 0xf6, 0x2f, 0xf8, 0xa5, 0x4a, 0xad, 0x8e, 0x5c, 0x19, 0x64, 0x49, 0x1d, 0x3a}, - output224: []byte{0x3d, 0xe2, 0x74, 0x84, 0xa9, 0xaa, 0xf9, 0x42, 0x7b, 0x6d, 0x7c, 0xe9, 0xf2, 0x34, 0x55, 0xda, 0x77, 0x1d, 0xcd, 0x2, 0x1a, 0x74, 0x3b, 0x4, 0x9c, 0xe8, 0x56, 0x42}, - output256: []byte{0x72, 0xf0, 0xbb, 0x32, 0xeb, 0x6e, 0x4b, 0xb9, 0x70, 0xa1, 0x2b, 0xac, 0xe8, 0xa, 0x7e, 0x3c, 0xa8, 0x61, 0x6a, 0x3f, 0xa5, 0x1f, 0x40, 0x43, 0x8f, 0xc9, 0xb, 0x32, 0x7f, 0xe, 0x75, 0xf6}, - output384: []byte{0x18, 0x3c, 0x13, 0xeb, 0x17, 0xc6, 0x6f, 0x15, 0xf2, 0xd7, 0x3d, 0x51, 0xca, 0x70, 0x17, 0x72, 0x82, 0x48, 0x95, 0x7d, 0x60, 0xe, 0x89, 0xa7, 0xcc, 0xb, 0xc0, 0x67, 0xc9, 0x75, 0xbc, 0x32, 0xf4, 0xe0, 0x78, 0x6f, 0xf4, 0xe, 0x62, 0x5c, 0xc7, 0xc0, 0xe0, 0xac, 0x78, 0x7f, 0x62, 0x36}, - output512: []byte{0xe, 0xa2, 0xc8, 0x58, 0x7e, 0x46, 0x46, 0x22, 0x6f, 0x46, 0x95, 0x23, 0x50, 0xe3, 0xbf, 0xe, 0x71, 0xb0, 0xb8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0xfa, 0x94, 0xbf, 0x69, 0xc7, 0xe5, 0xc, 0xb6, 0xd7, 0x8e, 0x48, 0x9f, 0x6d, 0xdf, 0xd2, 0x6e, 0x34, 0xed, 0xbd, 0xc9, 0xa6, 0xfe, 0xa4, 0xff, 0xcb, 0x76, 0x78, 0xfa, 0x60, 0x9c, 0x8d, 0x0, 0x69, 0x33, 0xf4, 0xbe, 0xcb, 0x85, 0x28, 0x3b, 0x13, 0xc0, 0x4c, 0x6a, 0x27, 0xa8, 0x9b, 0xc, 0x2c, 0xd2, 0x71, 0x25, 0xde, 0xc2, 0xc4, 0x96, 0x46, 0x49, 0x62, 0x88, 0xeb, 0xb1, 0x62, 0xce, 0xc4, 0xd5, 0xa3, 0xe, 0x3b, 0x83, 0xa9, 0xb, 0x54, 0xac, 0x61, 0x81, 0x2a, 0x90, 0x80, 0x14, 0xf9, 0xd2, 0x2c, 0xa2, 0x1f, 0x98, 0xc1, 0x23, 0x57, 0x2, 0x89, 0x71, 0x90, 0xe, 0x57, 0xac, 0xf8, 0xeb, 0xf0, 0x95, 0x68, 0x7e, 0x2d}, - output224: []byte{0xae, 0x53, 0x34, 0xfb, 0x23, 0x39, 0xd2, 0x88, 0xd3, 0x73, 0xf4, 0x36, 0x73, 0x25, 0xf6, 0xa0, 0x6a, 0x3e, 0x78, 0x16, 0x9b, 0xf8, 0x1b, 0x3c, 0xca, 0x8, 0x8a, 0x82}, - output256: []byte{0x62, 0xe8, 0x37, 0xa8, 0x3d, 0x1c, 0xc3, 0xf6, 0x30, 0x64, 0x20, 0xf0, 0x91, 0xea, 0x71, 0xf6, 0x1d, 0xdc, 0x73, 0xe4, 0xbc, 0x1d, 0x3a, 0xd6, 0x38, 0xae, 0x28, 0xda, 0xae, 0x69, 0xb5, 0x83}, - output384: []byte{0x68, 0x7a, 0xb7, 0xc4, 0xb4, 0xda, 0xc4, 0xa, 0xf8, 0x40, 0x80, 0xb3, 0xea, 0x25, 0x13, 0x7c, 0x1, 0xb0, 0x7b, 0x54, 0x66, 0x51, 0xdd, 0xbf, 0xa9, 0x8f, 0x35, 0x9e, 0xea, 0xf3, 0x4, 0x31, 0x3d, 0xd2, 0x7b, 0x95, 0x50, 0x0, 0xaa, 0x7b, 0x35, 0x66, 0x50, 0xf6, 0x85, 0x4c, 0x67, 0xee}, - output512: []byte{0xe, 0xd0, 0x15, 0x74, 0xe6, 0x5, 0x4a, 0x13, 0xdc, 0x63, 0x67, 0xfc, 0x47, 0xda, 0xa2, 0x42, 0x8, 0xf0, 0x25, 0x11, 0x51, 0x48, 0x84, 0x5b, 0x4, 0xb4, 0xa, 0xc2, 0x38, 0xf6, 0x15, 0x89, 0x37, 0x8d, 0xc1, 0x9c, 0x65, 0x2a, 0x50, 0x91, 0xd0, 0xc7, 0xf9, 0x25, 0xff, 0x1d, 0x5c, 0x7e, 0x6, 0x27, 0x28, 0xae, 0xf4, 0x6, 0xa2, 0xad, 0x75, 0xf6, 0x1f, 0xb8, 0x78, 0xfb, 0x5e, 0x78}}, - testcase{ - msg: []byte{0x6, 0x72, 0x90, 0x47, 0xc0, 0xd4, 0xa7, 0xb3, 0x2, 0x8, 0x65, 0xf5, 0x27, 0xf0, 0x65, 0x7e, 0xa5, 0x39, 0x7e, 0xb5, 0x80, 0x90, 0xab, 0xd0, 0x19, 0x12, 0xc4, 0x85, 0xe7, 0x38, 0x54, 0xaa, 0x9a, 0xa0, 0x39, 0x4c, 0xb5, 0x3d, 0x53, 0xe3, 0xd2, 0x40, 0xd1, 0xbd, 0x6c, 0xbd, 0x1e, 0x1e, 0x35, 0x35, 0x29, 0xcb, 0x87, 0x83, 0x3b, 0x5f, 0x47, 0x64, 0x83, 0xe6, 0x84, 0xf1, 0x17, 0x48, 0xd5, 0xab, 0x7a, 0x1f, 0x18, 0xf5, 0xb7, 0x6e, 0x59, 0x38, 0x45, 0x84, 0x86, 0xd4, 0xd5, 0xb1, 0xfe, 0x1a, 0xf7, 0xec, 0x2a, 0x13, 0x9c, 0xf5, 0xc4, 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, 0x12, 0xf6, 0xcd, 0x3a, 0x29, 0xae, 0x2c, 0x5c, 0x8f, 0x9a, 0x29, 0xfe, 0x83, 0x6c, 0x2, 0xb6, 0xe9, 0x8, 0x6a, 0xa4, 0xd9, 0x2c, 0x57, 0xc5, 0xaa, 0x89, 0x96, 0xf4, 0x56, 0x1f}, - output224: []byte{0xed, 0x18, 0xda, 0xe7, 0x7c, 0x77, 0x57, 0xf7, 0xae, 0x75, 0xfd, 0xb0, 0x85, 0xca, 0x7f, 0xd, 0x50, 0x29, 0x36, 0xe, 0xc0, 0xde, 0x88, 0x9d, 0x7, 0x9, 0xb, 0xc5}, - output256: []byte{0xfc, 0x98, 0xc1, 0x67, 0x23, 0xd8, 0xb8, 0x53, 0x12, 0x51, 0x97, 0x93, 0xbf, 0x97, 0xba, 0x50, 0xf4, 0x20, 0xdf, 0x68, 0x71, 0xc6, 0x18, 0x11, 0x77, 0x8f, 0xc1, 0x55, 0xc4, 0xac, 0xb2, 0x47}, - output384: []byte{0xae, 0x31, 0xed, 0xa8, 0xd6, 0xb7, 0x4f, 0x3e, 0x4a, 0x7d, 0xf3, 0x3d, 0xbe, 0x75, 0xa1, 0x46, 0xbc, 0xfe, 0xb5, 0x16, 0x1, 0x2d, 0xed, 0x58, 0xa7, 0xb, 0x32, 0xda, 0xce, 0x5, 0x5a, 0x79, 0xc8, 0x98, 0x20, 0x43, 0x13, 0x65, 0xd6, 0xa0, 0xe2, 0x8c, 0x8, 0x16, 0x28, 0xd9, 0x5e, 0x1f}, - output512: []byte{0x31, 0x9d, 0x56, 0x7c, 0xe6, 0xc7, 0x16, 0x29, 0xf4, 0xd0, 0x80, 0x1e, 0x38, 0x8a, 0x4b, 0xe3, 0x39, 0x33, 0x8f, 0x68, 0x94, 0xab, 0x47, 0x47, 0x50, 0x33, 0x2e, 0x95, 0x6e, 0xb3, 0xf1, 0xb0, 0xd4, 0x97, 0x83, 0xf, 0x8a, 0x4e, 0xce, 0xd8, 0xde, 0x90, 0xea, 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aa, 0xa, 0x22, 0xdb, 0x78, 0x4, 0x12, 0x50, 0xf6, 0x3b, 0x5a, 0x68, 0x3d, 0xc9, 0xff, 0xe7, 0x6a, 0xb0, 0x35}, - output224: []byte{0x62, 0xee, 0x8f, 0xc4, 0xe7, 0x72, 0xf3, 0xb2, 0xc5, 0x5, 0x15, 0x44, 0x43, 0xcc, 0xa1, 0x4d, 0xd4, 0xff, 0xc8, 0xd4, 0xf4, 0xf, 0x91, 0xc7, 0xc4, 0xb8, 0xc5, 0xe6}, - output256: []byte{0x95, 0xc8, 0xe6, 0x82, 0x59, 0xdc, 0xa8, 0xb8, 0x5e, 0x81, 0x68, 0x8c, 0x12, 0x82, 0x80, 0xb5, 0x9f, 0x7e, 0x10, 0x5d, 0x8e, 0xdd, 0x89, 0xcb, 0x9f, 0x29, 0x5b, 0x93, 0xea, 0x40, 0xe2, 0x91}, - output384: []byte{0xde, 0x42, 0xc7, 0xb0, 0x7, 0x9d, 0x73, 0x8b, 0x18, 0xc7, 0x2, 0xfe, 0x81, 0x28, 0x39, 0x1a, 0xe1, 0x3e, 0x5b, 0x9f, 0xb3, 0xc, 0xdc, 0x43, 0xe3, 0x3d, 0x2, 0xcd, 0x63, 0xd7, 0xca, 0x8c, 0xae, 0x2f, 0xd3, 0xc7, 0x17, 0xd7, 0xca, 0xce, 0x83, 0xc0, 0x7d, 0x41, 0x42, 0x5b, 0xa7, 0x37}, - output512: []byte{0x51, 0x46, 0xcc, 0x4c, 0x42, 0xa2, 0x65, 0x2e, 0x95, 0x8a, 0x2c, 0xe8, 0x67, 0x4f, 0x5e, 0x17, 0x48, 0xe3, 0xbd, 0x67, 0x4d, 0x49, 0x6c, 0x97, 0x6f, 0xe2, 0x8d, 0x9, 0x85, 0x17, 0xda, 0x3c, 0xd4, 0x4c, 0x1a, 0xcd, 0xd4, 0xbc, 0x47, 0x18, 0x26, 0x0, 0x15, 0x67, 0xb7, 0x66, 0x8c, 0xad, 0x39, 0x60, 0xf4, 0x55, 0x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b1, 0x3f, 0x50, 0x70, 0xd9, 0x88, 0x31, 0xb2, 0xc7, 0x63, 0x9f, 0xb6, 0xb9, 0xb0, 0x1c, 0x28, 0x88, 0x12, 0xdd, 0xfa, 0x88, 0x61, 0xdb, 0x32, 0xdc, 0x82, 0x68, 0xc0, 0x7d, 0x30, 0xcf, 0x96, 0x99, 0x53, 0x4, 0x2b, 0x3d, 0xad, 0x53, 0xd, 0x9d, 0x74, 0x4c, 0x6, 0xaa, 0xbe, 0x7a, 0x88, 0x6c, 0xf, 0xe5, 0x7b, 0x9, 0xb7, 0xf4, 0x2d, 0x19, 0x3f, 0xb3, 0xe9, 0xc0, 0x63, 0x29, 0x81, 0x82, 0x51, 0xa2, 0xf7, 0xe6, 0x47, 0x44, 0x62, 0xc9, 0x5d, 0xed}, - output224: []byte{0xc1, 0x75, 0x6c, 0x1, 0xc, 0x17, 0x3e, 0x99, 0x9b, 0x6c, 0xf1, 0x1e, 0x3b, 0x6b, 0xf4, 0x40, 0xc, 0x8c, 0x86, 0x6a, 0x18, 0xc2, 0x67, 0x3a, 0x47, 0x5, 0xdf, 0x79}, - output256: []byte{0x3d, 0x20, 0x74, 0x6d, 0xda, 0x87, 0x1a, 0x10, 0x42, 0x2, 0xec, 0x1a, 0xd7, 0xd6, 0xd, 0x8e, 0x16, 0x5f, 0xbf, 0x97, 0xaf, 0xc1, 0x92, 0x95, 0x11, 0xe4, 0x17, 0x81, 0xa3, 0x5c, 0xba, 0x45}, - output384: []byte{0x55, 0x31, 0xa3, 0x4d, 0x85, 0x65, 0xa9, 0x4b, 0x73, 0x57, 0xba, 0x71, 0x71, 0xae, 0x7e, 0xdd, 0x1e, 0x61, 0xac, 0xaf, 0xc1, 0x74, 0x7d, 0xba, 0xc4, 0xd4, 0xc0, 0x22, 0xb8, 0xac, 0xc6, 0x64, 0x9c, 0x8e, 0x44, 0xec, 0x2d, 0x64, 0x55, 0xe6, 0x23, 0xbc, 0xac, 0xf1, 0xc, 0x39, 0x15, 0xe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93, 0x9c, 0x6, 0xf9, 0x37, 0x85, 0x64, 0x8, 0xf7, 0x9}, - output224: []byte{0xb6, 0xcd, 0xea, 0x9d, 0xec, 0x93, 0x7e, 0x45, 0x7f, 0xb9, 0x45, 0x43, 0x3e, 0x14, 0x6, 0x10, 0xa5, 0xd5, 0xd9, 0x3d, 0xc2, 0x5f, 0x30, 0x7, 0x99, 0x24, 0x77, 0xca}, - output256: []byte{0xea, 0x2d, 0xbc, 0xe6, 0x65, 0x27, 0x8a, 0xa9, 0xbf, 0x9a, 0xfe, 0xe3, 0x4a, 0x0, 0x60, 0x21, 0x5f, 0x1d, 0x25, 0x71, 0x43, 0xd7, 0x3f, 0xf, 0xbe, 0x54, 0x1b, 0x29, 0x42, 0xf1, 0xbc, 0xbc}, - output384: []byte{0xb3, 0xfb, 0xb5, 0x6b, 0x7f, 0x1c, 0xe4, 0x4e, 0x8, 0x39, 0x4f, 0x8e, 0x21, 0xe2, 0x8b, 0x97, 0xb5, 0xec, 0x2d, 0x60, 0x37, 0xfc, 0xa4, 0x55, 0x67, 0x4b, 0x40, 0x64, 0x91, 0x57, 0x68, 0x4d, 0x5a, 0x19, 0x14, 0x3d, 0x8d, 0x9a, 0x9f, 0xc9, 0x51, 0xba, 0x98, 0xe5, 0x40, 0x7d, 0x2, 0x9a}, - output512: []byte{0xf2, 0xcd, 0x7, 0x45, 0xf5, 0x9f, 0x2e, 0x40, 0xd2, 0x9e, 0xc5, 0xc9, 0xc3, 0xf6, 0x69, 0x1a, 0x1b, 0xf6, 0x2d, 0x19, 0x46, 0x53, 0x93, 0x4f, 0x3d, 0xbc, 0x87, 0xb4, 0xa2, 0x7d, 0xe3, 0xe2, 0x15, 0x3a, 0xec, 0x97, 0xc, 0x51, 0xf5, 0x20, 0x1f, 0xb7, 0x55, 0x8, 0x44, 0xa7, 0xe4, 0xb6, 0x96, 0x45, 0x70, 0xb2, 0xa4, 0xbd, 0x87, 0x39, 0x4, 0xf9, 0xfd, 0x9c, 0x70, 0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x43, 0x27, 0x60, 0xc, 0xbf, 0x69, 0xe1, 0x9a, 0x76, 0x94, 0x4e, 0xe7}, - output224: []byte{0x5, 0x69, 0x2e, 0x46, 0xa9, 0x53, 0xae, 0x4a, 0x49, 0x57, 0x73, 0xc8, 0x7c, 0x6c, 0xcc, 0xa2, 0xd7, 0x6f, 0xfa, 0xbf, 0x55, 0x9e, 0xf2, 0xd, 0x24, 0x7, 0x9a, 0x54}, - output256: []byte{0x25, 0x97, 0xaa, 0xb9, 0x21, 0x4e, 0x2c, 0xa7, 0x37, 0x3c, 0x7e, 0x7e, 0x7, 0xb4, 0xf2, 0x4b, 0xc9, 0x29, 0x3c, 0x50, 0xff, 0x22, 0x6f, 0xfe, 0xd8, 0xf0, 0x20, 0x24, 0x12, 0x7d, 0xe8, 0x28}, - output384: []byte{0xa9, 0x8c, 0x5e, 0xff, 0x26, 0xd2, 0x7c, 0x8d, 0xda, 0x17, 0xe9, 0x19, 0xa4, 0x5b, 0xf9, 0xa, 0x60, 0xf, 0x23, 0x6e, 0x3f, 0xb, 0xd8, 0xdb, 0x1f, 0x2f, 0x61, 0x1f, 0xa, 0x77, 0x6, 0x96, 0xce, 0xe4, 0x59, 0x8e, 0xcd, 0xa, 0x15, 0xd3, 0xa1, 0xdb, 0x7e, 0xa9, 0x98, 0x94, 0x9f, 0xf6}, - output512: []byte{0x51, 0x8a, 0xa2, 0x64, 0xff, 0xe3, 0x82, 0x3, 0x82, 0xc9, 0x8e, 0xa1, 0x25, 0x4a, 0xc8, 0x2c, 0x30, 0x45, 0xbb, 0xcb, 0xc9, 0xaf, 0x9d, 0x7e, 0x7f, 0xa3, 0x68, 0x52, 0x5b, 0xb9, 0x5b, 0x7, 0x4c, 0xe3, 0xb4, 0x7c, 0xe6, 0xd6, 0xa7, 0x6f, 0xf1, 0x21, 0x2b, 0x79, 0x1a, 0xef, 0x6f, 0xf1, 0x91, 0xa0, 0xa0, 0x4a, 0xd3, 0x8e, 0x6a, 0x98, 0xc3, 0x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 0xc1, 0xa2, 0x12, 0xec, 0x3d, 0x4e, 0xc5, 0x21, 0x4a, 0x90, 0xd6, 0x56, 0xbb, 0x87, 0xe6, 0x2f, 0x7b, 0x25, 0xea, 0xbe, 0x97, 0xd0, 0x6, 0x6c, 0x69, 0x96, 0x3c, 0x73, 0x62, 0x8a, 0xea, 0xa3, 0x2a, 0x3f, 0xcf, 0x44, 0x3b, 0x29, 0xef, 0x1e, 0xe3, 0x89, 0x73, 0x6c, 0xbb, 0xdf, 0x99, 0xfc, 0x7e, 0x1b, 0x77, 0xd4, 0xf, 0x65, 0x1a, 0xe3, 0x58, 0x81, 0xd2, 0xff, 0x43, 0xe7, 0xd4, 0xa1, 0x3a, 0x56, 0xe8, 0xdd}, - output224: []byte{0xa, 0xf7, 0xe1, 0x35, 0x1c, 0x6a, 0x6b, 0x73, 0x59, 0xb5, 0x9e, 0x22, 0xbf, 0x9c, 0x9b, 0xa2, 0x41, 0x10, 0xa2, 0xce, 0xfb, 0x64, 0x7a, 0x79, 0xf, 0xab, 0x41, 0xf1}, - output256: []byte{0x3f, 0x3d, 0x3a, 0xfa, 0xf6, 0x17, 0x3d, 0xc5, 0xa3, 0x81, 0x1a, 0xdd, 0x40, 0x9f, 0xf2, 0x53, 0x1, 0x2, 0x9c, 0xc0, 0xbc, 0xbd, 0xe4, 0xc7, 0xd, 0x21, 0xec, 0xb5, 0x87, 0x2c, 0x1c, 0x12}, - output384: []byte{0x1, 0x63, 0xb6, 0xf7, 0x68, 0xa, 0xd7, 0x18, 0xf4, 0xcf, 0xcc, 0x39, 0x75, 0x4, 0x82, 0xcb, 0xb0, 0xcf, 0x6e, 0x93, 0xa8, 0x5e, 0x99, 0x6b, 0x9c, 0xde, 0xa9, 0xf8, 0x40, 0x97, 0xb0, 0x62, 0xd3, 0xb0, 0x1c, 0x66, 0xeb, 0xf8, 0x22, 0xdb, 0x3b, 0x8b, 0xdb, 0x27, 0x9, 0x1b, 0x8, 0x19}, - output512: []byte{0x91, 0x2e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, 0x9, 0x5, 0x49, 0x48, 0x93, 0x42, 0x25, 0xa3}, - output224: []byte{0xd6, 0x20, 0x41, 0x96, 0x40, 0x8a, 0xf4, 0xc7, 0x39, 0x1, 0xe8, 0xf2, 0xcb, 0xd, 0xa, 0xd2, 0x81, 0xfd, 0x60, 0x71, 0x30, 0x1c, 0x6b, 0x70, 0x46, 0xd8, 0x24, 0x7e}, - output256: []byte{0xa6, 0x3, 0x77, 0xb7, 0xdc, 0xb5, 0xe0, 0x23, 0x32, 0x85, 0xfd, 0xa3, 0xa5, 0x4e, 0x5b, 0x91, 0x11, 0x93, 0x80, 0xa8, 0x25, 0x1a, 0xf2, 0xf4, 0xc2, 0x16, 0xda, 0x33, 0x63, 0x75, 0x4e, 0x11}, - output384: []byte{0xed, 0x58, 0xeb, 0x86, 0xd5, 0x95, 0x70, 0x54, 0x7f, 0xef, 0x42, 0xbb, 0xe2, 0x46, 0x92, 0xd0, 0x67, 0x9d, 0xa7, 0x64, 0x11, 0x5d, 0xf8, 0x98, 0x74, 0xf3, 0x7f, 0xf0, 0xe0, 0xd4, 0x7b, 0xed, 0x71, 0x82, 0x56, 0xe0, 0x92, 0x6c, 0x85, 0xd0, 0x62, 0xed, 0x73, 0x50, 0x47, 0x4c, 0xb8, 0xf1}, - output512: []byte{0xee, 0xf3, 0x1f, 0x98, 0x11, 0xd7, 0x80, 0xb1, 0xa6, 0xf0, 0xed, 0xfc, 0x47, 0x63, 0x52, 0x80, 0x1e, 0x90, 0x84, 0xfc, 0xa3, 0xec, 0x4b, 0xb2, 0xbe, 0xf8, 0x22, 0xdf, 0xd, 0x95, 0x80, 0xa6, 0x98, 0xd3, 0x6c, 0x57, 0xd9, 0xd2, 0xd6, 0x66, 0x6d, 0x8b, 0xfc, 0xa, 0xae, 0x48, 0x59, 0x31, 0x59, 0x8, 0xd7, 0x55, 0xf6, 0x16, 0x7f, 0xd8, 0x6d, 0x46, 0x4d, 0xb0, 0xbd, 0x84, 0x87, 0x2f}}, - testcase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0xa7, 0xcf, 0x61, 0xff, 0xbd, 0x39, 0x11, 0xb4, 0x44, 0xe1, 0xc6, 0x3}, - output224: []byte{0x1a, 0x32, 0xe, 0xa5, 0xd2, 0xc3, 0xb7, 0x20, 0x9f, 0xe9, 0xaa, 0x5, 0x34, 0xc, 0xa2, 0x8e, 0x51, 0x4e, 0x18, 0x90, 0x80, 0x64, 0x6, 0xc5, 0x76, 0x81, 0xe4, 0x20}, - output256: []byte{0xa9, 0x32, 0x87, 0x95, 0x2d, 0xbf, 0x85, 0x98, 0xd6, 0x9d, 0x81, 0x77, 0x70, 0x55, 0x83, 0x30, 0xc5, 0xda, 0xe8, 0x7c, 0x12, 0x68, 0x82, 0x48, 0xe7, 0x0, 0x31, 0x4e, 0xe7, 0x89, 0x62, 0x8b}, - output384: []byte{0xa3, 0x32, 0x9b, 0xa, 0xb3, 0x58, 0xf0, 0x10, 0xce, 0xad, 0x13, 0x6f, 0xa0, 0x76, 0x7c, 0x84, 0xc9, 0x62, 0x4f, 0xa2, 0xa6, 0xde, 0x47, 0xf, 0x23, 0xda, 0x87, 0x32, 0xfe, 0x65, 0x63, 0x9f, 0x71, 0xb1, 0xdd, 0x47, 0x63, 0x3f, 0x9, 0xae, 0x86, 0x34, 0x9e, 0x97, 0x7e, 0x4d, 0xe8, 0x4}, - output512: []byte{0xb5, 0xbd, 0xb3, 0xfa, 0xd8, 0xb5, 0xb8, 0x9e, 0xd4, 0x7d, 0xb1, 0x48, 0x9e, 0x19, 0xe2, 0x7b, 0x84, 0x6d, 0xcc, 0x9d, 0x96, 0x5d, 0x32, 0x54, 0x3e, 0x94, 0xa5, 0x30, 0x51, 0x49, 0x9e, 0xee, 0xfe, 0x88, 0xcd, 0x12, 0x3c, 0x58, 0xd5, 0xee, 0x25, 0x81, 0x12, 0xd3, 0xec, 0x7f, 0x44, 0x34, 0x19, 0x99, 0x76, 0x23, 0x7f, 0x69, 0x97, 0x1f, 0x69, 0xba, 0x8a, 0xda, 0x7d, 0x8d,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 0x7b, 0x69, 0x46, 0x24, 0x7b, 0x5f, 0x69, 0xf8, 0x70, 0xde, 0x10, 0x77, 0x53, 0x25, 0xc6, 0x5a, 0xde, 0x56, 0xa7, 0xd0, 0x63, 0x75, 0x73, 0x71, 0x73, 0x9e, 0x5, 0x3e, 0x97, 0x11, 0x79, 0xd2, 0xbb, 0x65, 0x17, 0xc7, 0xd9, 0xf8, 0xef, 0x37, 0xa7, 0x8d, 0xd3, 0xb9, 0xd1, 0x5c, 0x9d, 0x2f, 0x2, 0x1d, 0x4b, 0x81, 0xff, 0xe9, 0x43, 0x73, 0x53, 0xa9, 0x65, 0xd7, 0x9b, 0x82, 0x17, 0x7b, 0x67, 0x98, 0xa7, 0xe, 0xf8, 0x51, 0x1d, 0x27, 0xff, 0xf2, 0x15, 0xb7, 0x41, 0xb9}, - output224: []byte{0xaf, 0x82, 0x8b, 0x69, 0x42, 0x3d, 0x5b, 0x66, 0x7a, 0xa9, 0x2c, 0xf1, 0x65, 0x8c, 0x9a, 0x70, 0xd2, 0x3b, 0xe6, 0x4f, 0x61, 0xbc, 0xd8, 0x7, 0x82, 0xde, 0x58, 0x86}, - output256: []byte{0xc8, 0xd6, 0x55, 0x66, 0xe3, 0x46, 0xb9, 0xd8, 0xd5, 0xee, 0x75, 0xc, 0x13, 0x45, 0x7d, 0xd, 0x5b, 0x18, 0x22, 0x3b, 0x5a, 0x92, 0xe3, 0xa5, 0x42, 0x1d, 0xd1, 0x5b, 0x33, 0x49, 0xfe, 0xef}, - output384: []byte{0x74, 0xb8, 0x63, 0x43, 0xaa, 0xfc, 0x1b, 0xb0, 0x7d, 0x40, 0xbe, 0x7b, 0xfe, 0xbe, 0xcc, 0xf4, 0xba, 0x3b, 0x12, 0xdc, 0xf6, 0x81, 0xf3, 0x45, 0x8d, 0xe2, 0x8, 0x82, 0x9f, 0x70, 0x4d, 0x35, 0x12, 0xb7, 0xc6, 0xc, 0x7d, 0x21, 0x1a, 0x54, 0x9e, 0xc8, 0xc9, 0xd4, 0xf4, 0x80, 0x62, 0x57}, - output512: []byte{0xc3, 0x4, 0xb2, 0x9c, 0x9f, 0x46, 0x71, 0x87, 0xfc, 0xad, 0xa4, 0x2b, 0xc3, 0x61, 0x16, 0x58, 0x4d, 0xee, 0x21, 0x52, 0x1, 0xd2, 0xe8, 0xb7, 0xd9, 0xcf, 0x95, 0x5, 0x88, 0x82, 0x22, 0xa4, 0x43, 0xd0, 0x58, 0xf3, 0x7a, 0x7e, 0x1d, 0xda, 0x5, 0xd9, 0x1a, 0xcc, 0x35, 0x39, 0x15, 0x95, 0xb6, 0xaa, 0x7b, 0x67, 0x86, 0xe2, 0x24, 0xfe, 0xbe, 0x70, 0x59, 0x70, 0x1d, 0x99, 0x64, 0xb2}}, - testcase{ - msg: []byte{0xae, 0x82, 0xef, 0x9, 0xb7, 0x11, 0x95, 0x1f, 0x60, 0x82, 0xb1, 0xbd, 0xc5, 0xb1, 0x75, 0xc8, 0x10, 0x10, 0xe3, 0x98, 0xb8, 0xf3, 0xb1, 0x8f, 0x5a, 0xb9, 0x9f, 0x78, 0xcb, 0x53, 0xa5, 0xf9, 0x53, 0xbe, 0x9, 0xc9, 0x8b, 0xd9, 0x72, 0x37, 0x40, 0xc7, 0xa4, 0xe6, 0xd2, 0x6a, 0x64, 0xaa, 0x62, 0xc6, 0x97, 0x3f, 0x60, 0xda, 0x56, 0xe, 0x14, 0xee, 0xd6, 0x3d, 0x0, 0x1f, 0x6e, 0x28, 0x17, 0x1, 0x77, 0x3c, 0x34, 0xa4, 0x12, 0x60, 0xa2, 0xae, 0x67, 0x5d, 0xe5, 0x43, 0xf2, 0xbf, 0x2f, 0xee, 0xa4, 0xb1, 0x7e, 0xbd, 0x92, 0x8a, 0xad, 0x65, 0xa1, 0x7f, 0x7f, 0xbc, 0x4b, 0x75, 0x70, 0xfe, 0xfc, 0xa8, 0x4, 0x95, 0x6d, 0x4d, 0x93, 0x53, 0x93, 0x7c, 0x3f, 0xaa, 0x15, 0x51, 0x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e0, 0xc6, 0xfc, 0x59, 0x66, 0x49, 0x30, 0x5, 0x57, 0xe3, 0xb7, 0xb5, 0x87, 0xbf, 0xc8, 0xd, 0xcb, 0x36, 0xc7, 0xe8, 0xfb, 0xa9}, - output224: []byte{0xd2, 0x5b, 0x2d, 0x47, 0x4f, 0x62, 0xf6, 0xca, 0x7d, 0xb, 0xb2, 0x8, 0xac, 0xfb, 0x8b, 0xd7, 0x7a, 0x71, 0xb, 0x26, 0x44, 0xe0, 0x3a, 0xff, 0x27, 0x5b, 0x13, 0x91}, - output256: []byte{0x31, 0x6d, 0xba, 0xab, 0xd7, 0x3c, 0xb3, 0x31, 0xe4, 0xca, 0xd8, 0x99, 0xb4, 0x46, 0xdf, 0xf6, 0x5e, 0xb8, 0x66, 0x8f, 0x5c, 0x4e, 0xf9, 0xa1, 0xdb, 0x8e, 0x8a, 0xe4, 0x24, 0x12, 0x8f, 0x66}, - output384: []byte{0xf7, 0x65, 0x2a, 0xb4, 0xec, 0x1e, 0xbe, 0xf1, 0x18, 0x3c, 0x8d, 0xb0, 0xbd, 0x21, 0x7f, 0x8b, 0xd5, 0x57, 0xf6, 0x4, 0xf4, 0x59, 0xf5, 0xa2, 0x6d, 0x17, 0xf5, 0xb3, 0xe5, 0xd, 0x9d, 0xad, 0xaf, 0x13, 0x85, 0x36, 0x7d, 0x1c, 0x37, 0x5f, 0xa9, 0xba, 0x42, 0xd2, 0x51, 0x4c, 0x78, 0xb5}, - output512: []byte{0xfd, 0x90, 0xed, 0x9a, 0x58, 0x20, 0x44, 0x3e, 0x58, 0xf1, 0x18, 0xfa, 0xd2, 0xed, 0xf, 0x65, 0x93, 0x89, 0x76, 0x87, 0x3e, 0x1c, 0xe6, 0xde, 0x77, 0xa3, 0x37, 0xfc, 0xfe, 0xc3, 0x92, 0xb3, 0x27, 0x5f, 0xd8, 0x5, 0xcc, 0xc6, 0x44, 0x26, 0x87, 0x1a, 0xbc, 0xca, 0x32, 0x50, 0xd3, 0x1a, 0x9f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, 0x90, 0xb4, 0x5d, 0x10, 0x4, 0x6a, 0x0, 0x17, 0x8e, 0x89, 0xbd, 0x51, 0x56, 0x16, 0xb8, 0xa4, 0x4e, 0x77, 0xbf, 0x57, 0x79, 0x5d, 0xab, 0xaf, 0x40, 0x68, 0x7b, 0x2c, 0xda, 0x7a, 0x50, 0x14, 0x16, 0x8f}, - output224: []byte{0x98, 0xe4, 0xc, 0x17, 0x6c, 0x8c, 0x8e, 0xc4, 0x6a, 0xb9, 0x40, 0x68, 0x8d, 0x47, 0x97, 0x8b, 0x8d, 0x1c, 0xac, 0xef, 0xf3, 0x7c, 0x70, 0xf, 0xdd, 0x6, 0xcb, 0xb5}, - output256: []byte{0x4b, 0xa1, 0x50, 0xc2, 0xf4, 0xdb, 0x24, 0x49, 0x51, 0x5c, 0xc9, 0xb5, 0x45, 0xec, 0x0, 0x12, 0x74, 0x73, 0x24, 0x70, 0xd, 0xa, 0xc1, 0xe5, 0x54, 0xea, 0xb8, 0x4a, 0x26, 0x2b, 0xaf, 0x0}, - output384: []byte{0x97, 0x8a, 0x5c, 0x74, 0xca, 0xb4, 0xd5, 0xb7, 0x73, 0xad, 0xf6, 0x4c, 0xab, 0xec, 0xd, 0xe0, 0x36, 0xd0, 0x87, 0xe0, 0x41, 0xf6, 0xc1, 0xa9, 0x85, 0x53, 0xc, 0x22, 0x50, 0xd2, 0x83, 0xfa, 0xaa, 0x7f, 0xfa, 0xa0, 0x14, 0x25, 0x88, 0x69, 0x4e, 0x67, 0x24, 0x5b, 0xba, 0x56, 0xb9, 0xc8}, - output512: []byte{0x29, 0xe5, 0xcd, 0x96, 0x9, 0x9c, 0x48, 0x34, 0xfd, 0xe, 0xcb, 0xe8, 0x13, 0x26, 0x21, 0xd0, 0x34, 0x5b, 0xe3, 0xdf, 0xc, 0x7a, 0xb9, 0xb8, 0xb8, 0x6d, 0x91, 0xe8, 0x7f, 0xd8, 0xaf, 0xa0, 0xa4, 0xf2, 0x9, 0x50, 0x6b, 0x8d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2b, 0xc3, 0x2d, 0x61, 0xe, 0x8, 0x3b, 0xf4, 0x95, 0x60, 0xd7, 0x6d, 0xba, 0xec, 0x82, 0x29, 0x28, 0x18, 0x37, 0x7e, 0xa5, 0xea, 0x68, 0xed, 0x76, 0xda, 0xa1, 0x5b, 0x2b, 0xfa, 0xe0, 0x9d, 0x17, 0x29, 0xb4, 0x4a, 0xde, 0xeb, 0x45, 0xbd, 0x47, 0x9, 0xcc, 0x30, 0x6e, 0x31, 0x95, 0x3c, 0x74, 0xfb, 0x6f, 0xf0, 0x57, 0x57, 0xcd, 0xa9, 0xb0, 0xb4, 0x22, 0x74, 0x6b, 0x1c, 0xca, 0x7f, 0xa6, 0x7c, 0x29, 0xa, 0x8c, 0x50, 0xa8, 0x3c, 0x24, 0x2f, 0xb, 0xdf, 0x8a, 0xdd, 0xae, 0x3d, 0xac, 0xc6, 0x87, 0xf4, 0xf8, 0xa8, 0x9f, 0xd9, 0x7, 0x75, 0x90, 0x63, 0x4f, 0x98, 0x4a, 0x18, 0x71, 0xaa, 0xfb, 0xd9, 0xf2, 0xc3, 0x5b}, - output224: []byte{0x35, 0x70, 0x7d, 0xd2, 0xa4, 0x4d, 0xe6, 0x66, 0x41, 0xdc, 0xfb, 0x35, 0xa0, 0x6f, 0xdc, 0x0, 0x1c, 0x74, 0xee, 0xc, 0x96, 0xec, 0xc1, 0x6b, 0x34, 0x69, 0x6f, 0xe1}, - output256: []byte{0x17, 0xc8, 0xa5, 0xf5, 0x23, 0x64, 0xc9, 0xf6, 0x51, 0xde, 0x5f, 0x10, 0x2, 0x1e, 0x5, 0xda, 0xf6, 0xcc, 0x63, 0xd6, 0x8f, 0x66, 0x66, 0x6e, 0x76, 0x2e, 0xdb, 0xd7, 0x57, 0x52, 0x58, 0x82}, - output384: []byte{0xd5, 0xf3, 0x78, 0x42, 0x1c, 0xac, 0x5, 0x82, 0xd1, 0xa2, 0xd1, 0x2c, 0x8c, 0x9b, 0x75, 0xc6, 0xa9, 0xa9, 0x5c, 0x74, 0x89, 0xb6, 0x94, 0xc0, 0xa6, 0x0, 0xae, 0xc6, 0x4, 0x7f, 0x54, 0xd3, 0x8b, 0x22, 0xdf, 0xff, 0xb6, 0x3b, 0x95, 0xe2, 0x35, 0xf3, 0x68, 0x28, 0x28, 0xae, 0xe6, 0x1e}, - output512: []byte{0x9b, 0x73, 0x59, 0xf3, 0x5d, 0xf4, 0x10, 0x49, 0xe9, 0xf2, 0xd8, 0x47, 0xfe, 0xdc, 0xf2, 0xb7, 0x49, 0xbd, 0xec, 0x88, 0x62, 0x8a, 0x58, 0xbd, 0xd2, 0xf, 0xa7, 0xee, 0x57, 0x73, 0x5b, 0xb5, 0x42, 0x84, 0x3c, 0x48, 0x32, 0x2d, 0xe5, 0xa6, 0x11, 0x44, 0x13, 0x54, 0x6e, 0xf5, 0xe4, 0x3c, 0x4, 0x34, 0x5d, 0x98, 0xa8, 0xb3, 0x9e, 0x1e, 0x4a, 0x6b, 0xb, 0x97, 0xd0, 0x90, 0x5f, 0x69}}, - testcase{ - msg: []byte{0xd8, 0xe, 0x6f, 0xe5, 0x9b, 0x72, 0x28, 0xd2, 0x5e, 0x78, 0x58, 0x6f, 0x94, 0xf2, 0x68, 0xea, 0x62, 0xeb, 0xe0, 0x42, 0x38, 0xab, 0x44, 0xe9, 0x73, 0x16, 0xb2, 0x2e, 0x96, 0xc9, 0x1d, 0x18, 0x6f, 0xac, 0x86, 0x2e, 0xba, 0x92, 0x12, 0xce, 0x84, 0x5b, 0xed, 0xc2, 0x3c, 0xec, 0x43, 0xfc, 0x3d, 0xa4, 0x2a, 0xa7, 0x2, 0x56, 0x37, 0xe0, 0xef, 0x65, 0x82, 0x3e, 0xba, 0x6f, 0xed, 0x26, 0x1a, 0xfe, 0x9a, 0x48, 0x7, 0x42, 0x58, 0xb2, 0x35, 0x55, 0x9a, 0x91, 0x6e, 0x64, 0x4b, 0xfb, 0xc9, 0xc3, 0xb6, 0xf4, 0x4d, 0x76, 0xe, 0x30,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, 0xfd, 0xf3, 0x8e, 0x23, 0xb, 0x18, 0x7d, 0x82, 0x2c, 0xc6, 0xa5, 0x4a, 0x2b, 0x64, 0x30, 0x29, 0xa5, 0xd9, 0xaf, 0x17, 0xc5, 0xc7, 0x5, 0xf4, 0x14, 0x3, 0xae, 0x62, 0x95, 0x6d, 0x97, 0x7b, 0xbb, 0xc7, 0xce, 0x90, 0xc, 0xee, 0xc2, 0xb7}, - output224: []byte{0x96, 0x56, 0xf2, 0x73, 0xcf, 0x78, 0xf3, 0x61, 0x3d, 0x93, 0x1d, 0x50, 0x27, 0x8e, 0x27, 0x36, 0x43, 0xcd, 0x66, 0x62, 0xc4, 0x8d, 0x24, 0x3a, 0x11, 0x5c, 0xad, 0x65}, - output256: []byte{0x2, 0x38, 0xb0, 0xa1, 0xe3, 0x57, 0xc7, 0x38, 0x21, 0x29, 0xad, 0x29, 0x40, 0xed, 0x71, 0x82, 0xf, 0x7d, 0x45, 0xa7, 0xf0, 0xf2, 0x62, 0x93, 0x91, 0xc1, 0x8, 0x29, 0xae, 0x80, 0x1b, 0xf5}, - output384: []byte{0x0, 0x6, 0x2a, 0x3e, 0xcb, 0x49, 0x1a, 0x34, 0x68, 0x1a, 0x52, 0xd1, 0x16, 0xde, 0x2f, 0xa, 0x66, 0x1a, 0x53, 0x52, 0x24, 0xca, 0xd8, 0x82, 0x86, 0x2f, 0xd8, 0xa6, 0x8b, 0x15, 0x2a, 0x5f, 0x54, 0xd3, 0x4, 0xbf, 0x8f, 0x1b, 0x7d, 0x61, 0x47, 0x16, 0x4c, 0xb6, 0x6a, 0x43, 0xc6, 0xb7}, - output512: []byte{0xe6, 0x67, 0x4b, 0x97, 0x8b, 0x94, 0xaa, 0xfa, 0x19, 0xe4, 0x49, 0xd3, 0xdb, 0xf9, 0xc8, 0xd5, 0x87, 0x1, 0x8, 0x4b, 0x0, 0x29, 0x62, 0xca, 0xd7, 0x99, 0xc5, 0x68, 0x83, 0x17, 0x10, 0x13, 0xd, 0xa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0x31, 0x97, 0x32, 0xc1, 0xa3, 0xd2, 0x5, 0x82, 0xd9, 0xef, 0x30, 0xc4, 0xb3, 0x53, 0x6b, 0x7c, 0x47, 0x19, 0x7c, 0x97, 0xc7, 0x67, 0x92, 0x14, 0x5c, 0xb8, 0x47, 0xbd, 0x2f, 0xb8, 0x4a, 0x7c, 0xb4, 0x60, 0x84, 0x2f, 0x9, 0x56, 0x2, 0xc, 0x32, 0xd, 0x48}, - output224: []byte{0x15, 0xe1, 0x5, 0x8, 0xa9, 0x79, 0x46, 0xcf, 0x7d, 0x8, 0x42, 0xc5, 0x1e, 0x63, 0xd3, 0x4b, 0xd9, 0x93, 0x56, 0x3d, 0x9b, 0x3c, 0x6b, 0x81, 0xb7, 0x56, 0xf6, 0xcd}, - output256: []byte{0xdf, 0x6e, 0x9b, 0x8, 0x44, 0x15, 0x3e, 0x3c, 0xd6, 0x54, 0xd4, 0x60, 0xd5, 0x37, 0xe, 0xe1, 0x91, 0x77, 0x62, 0xf6, 0x7d, 0xc2, 0x9b, 0xec, 0xe4, 0x4d, 0xf2, 0x65, 0x2e, 0xa6, 0xae, 0x59}, - output384: []byte{0xdb, 0x72, 0x2f, 0xd0, 0x96, 0x99, 0x2d, 0x5f, 0x25, 0xfb, 0xfe, 0xf7, 0x99, 0x1e, 0xa8, 0xc1, 0xbc, 0xe6, 0xb1, 0xc2, 0xad, 0x49, 0x21, 0xac, 0x61, 0x9f, 0xe1, 0x9c, 0x50, 0x5e, 0x3e, 0x2d, 0x82, 0xd1, 0xca, 0x64, 0x4d, 0xed, 0xad, 0xec, 0x87, 0x6f, 0x51, 0xfd, 0xb2, 0x15, 0x78, 0xb}, - output512: []byte{0x81, 0x30, 0x7d, 0xa5, 0x51, 0xcf, 0x5, 0x76, 0x6e, 0x29, 0xb8, 0xfe, 0x5c, 0x33, 0xfa, 0x5a, 0x12, 0x4b, 0xd0, 0x20, 0x2b, 0xc5, 0xe3, 0x9, 0xd6, 0x48, 0xe0, 0xec, 0x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43, 0x7a, 0x92, 0x1b, 0x29, 0xae, 0xce, 0xe0, 0x6b, 0x46, 0xa2, 0x6b, 0x8d, 0xde, 0x14, 0xdd, 0x95, 0xcb, 0x62, 0x43, 0x3d, 0x75, 0x52, 0xc9, 0xf9, 0x4c, 0xaf, 0x82, 0x99, 0xfb, 0xb6, 0xa0, 0xbd, 0xc8, 0x22, 0x94, 0xd3, 0x1, 0x6c, 0x25, 0x4b, 0x9a, 0x41, 0xca, 0xd9, 0xcc, 0x15}, - output512: []byte{0x56, 0x14, 0xa6, 0xd6, 0xf5, 0x52, 0xd4, 0xc9, 0xda, 0xd4, 0x86, 0x41, 0xec, 0xe0, 0xce, 0xf2, 0xa3, 0xf0, 0x50, 0x11, 0x45, 0x26, 0xf8, 0x12, 0x36, 0xae, 0x53, 0xad, 0x7e, 0x8f, 0x84, 0x99, 0x94, 0x6, 0x73, 0xa8, 0xac, 0x51, 0x31, 0x93, 0x69, 0xb8, 0x21, 0x4a, 0x35, 0x8b, 0x4e, 0x4, 0x76, 0xc9, 0x49, 0x69, 0x11, 0x22, 0xb4, 0x67, 0x7a, 0xb1, 0x3c, 0x3b, 0x98, 0xb2, 0x47, 0x9b}}, - testcase{ - msg: []byte{0xe6, 0x91, 0xe8, 0xfe, 0xb7, 0x44, 0x95, 0x7b, 0x27, 0x5e, 0x5f, 0xd8, 0x79, 0xa3, 0xab, 0xe5, 0x4d, 0x6d, 0x6c, 0x8c, 0x7f, 0x58, 0x9f, 0xb, 0x1a, 0x17, 0xc0, 0x8c, 0x29, 0x9c, 0x55, 0x9e, 0x5f, 0x7, 0xc9, 0xea, 0xa1, 0x2b, 0x3d, 0xbf, 0xe, 0x6, 0x34, 0x2e, 0x63, 0x44, 0x22, 0x9e, 0x99, 0x31, 0x21, 0x7e, 0x77, 0xf3, 0x4b, 0x53, 0x1, 0x45, 0x77, 0xab, 0x76, 0xfb, 0xee, 0x38, 0xec, 0x3f, 0x49, 0x1e, 0x7e, 0xa, 0x12, 0x95, 0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8, 0x97, 0xcc, 0x38, 0xbf, 0x60, 0xd, 0x51, 0xce, 0x9, 0x3b, 0x71, 0xc6, 0x3a, 0x1c, 0x8c, 0x36, 0xf4, 0x57, 0x30, 0xd1, 0x8e, 0xbd, 0x95, 0x1a, 0x6a, 0xb7, 0x4b, 0x1, 0x4d, 0x91, 0x5e, 0xb2, 0xa9, 0x51, 0x45, 0x8c, 0xbe, 0xec, 0xb4, 0x51, 0x22, 0x40, 0x34, 0x2a, 0x83, 0xc5, 0x83, 0x79, 0xb5, 0xc9, 0x86, 0x64, 0x20, 0x2f, 0x78, 0x34, 0x53, 0xb8, 0xc8, 0xca, 0xb8, 0x93, 0x2, 0x88, 0x31, 0x95}, - output224: []byte{0x85, 0x81, 0xaa, 0xd3, 0x9, 0xe2, 0x38, 0xd2, 0xdc, 0xd2, 0x83, 0xb9, 0x65, 0x49, 0x7b, 0x86, 0x74, 0xcc, 0x8f, 0x1b, 0x99, 0x9, 0x6f, 0x82, 0xd7, 0x80, 0x1, 0xf0}, - output256: []byte{0x31, 0x20, 0x83, 0xd9, 0x69, 0x68, 0x97, 0x40, 0xc2, 0x3c, 0xc2, 0x87, 0x7, 0x7b, 0x60, 0xad, 0x35, 0x31, 0x6a, 0x14, 0xf2, 0xeb, 0x1, 0x5f, 0xa0, 0xa1, 0x12, 0x5c, 0xb6, 0x34, 0x7f, 0x76}, - output384: []byte{0x55, 0x27, 0x4f, 0x25, 0x79, 0xa, 0xdf, 0x33, 0x32, 0x2a, 0xe0, 0x8f, 0xa3, 0x3b, 0x3e, 0x48, 0xb4, 0x93, 0x99, 0x1d, 0x11, 0x64, 0xcb, 0x7d, 0x11, 0xb7, 0x4f, 0x4c, 0x76, 0xec, 0x32, 0x72, 0x6, 0xec, 0x11, 0xee, 0x2f, 0x2b, 0x7b, 0x3b, 0x4, 0xee, 0x58, 0x1a, 0xa8, 0x35, 0xd5, 0x3f}, - output512: []byte{0x85, 0x47, 0x66, 0x87, 0x16, 0x77, 0xe0, 0x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, 0x2, 0xed, 0x13, 0xc2, 0x75, 0xb1, 0x29, 0x6, 0xfa, 0x1d, 0x6f, 0xfc, 0xc1, 0x14, 0x31, 0xc, 0xde, 0x81, 0x9d, 0x3b, 0x42, 0x84, 0x81, 0xaf, 0x47, 0x39, 0xe9, 0x62, 0xe3, 0xa2, 0xd9, 0xd, 0x86, 0x4d, 0x43, 0x19, 0xdc, 0x67, 0xf4, 0xbd, 0xda, 0xc7, 0x64, 0x48, 0xb6, 0x7f, 0xb4, 0x39, 0x79, 0x3b, 0x68, 0xb7, 0x9c, 0x1d, 0xea, 0xa6, 0xde, 0xf0, 0x4a, 0x44, 0xad, 0x66, 0xf2, 0x59, 0x6c, 0xbb, 0x3a, 0x9b, 0x54, 0x60, 0xdd, 0xf0, 0x52, 0x35, 0xd5}, - output224: []byte{0xe0, 0x1a, 0x40, 0xef, 0xa7, 0x8d, 0xe5, 0xbb, 0x50, 0x5, 0x13, 0xcc, 0x1a, 0xd7, 0x73, 0x26, 0xc9, 0x50, 0xd9, 0x91, 0xc0, 0x70, 0x6a, 0xc6, 0x67, 0x58, 0xef, 0xa1}, - output256: []byte{0x7, 0x12, 0x8f, 0x94, 0x52, 0xcf, 0x60, 0x1e, 0x2a, 0x30, 0x5a, 0xb7, 0x5c, 0xdd, 0x13, 0x1, 0x7b, 0xbf, 0x79, 0xb0, 0xae, 0x3b, 0x5b, 0x43, 0xc2, 0xce, 0x7, 0x71, 0xb0, 0x4f, 0x57, 0x19}, - output384: []byte{0x92, 0xb0, 0xef, 0xc8, 0x24, 0x8e, 0x8c, 0x6a, 0x96, 0x46, 0xdf, 0x49, 0xb8, 0x75, 0x99, 0x21, 0xbe, 0xa6, 0xf4, 0x4, 0x2e, 0x1b, 0xdd, 0x1c, 0x12, 0x8c, 0x42, 0x1e, 0x6c, 0xa6, 0xfe, 0xb4, 0xb7, 0x85, 0xcd, 0x8a, 0xe0, 0xa4, 0x8a, 0xd1, 0x8a, 0x1d, 0x5, 0xa6, 0x5d,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x8b, 0x85, 0x8b, 0x55, 0xed, 0x87, 0xfb, 0x14, 0xe3, 0x48, 0x9b, 0xa1, 0x18, 0x61, 0xed, 0x4, 0x34, 0xd1, 0xc3, 0xc4, 0xd2, 0x9, 0xd, 0x28, 0xbf, 0x72, 0xec, 0xd2, 0x52, 0xdf, 0x9d, 0xc3, 0x4b, 0xdc, 0x41, 0xdd, 0x40, 0x90, 0x49, 0x81, 0x1f, 0xab, 0x93, 0x25, 0x4b, 0x23, 0x95, 0x27, 0x12, 0x44, 0x77, 0x2d, 0xbd, 0xb5, 0x94, 0xe2, 0xda, 0x7, 0x69, 0x6, 0xd0, 0xe0, 0xf8, 0x5a, 0x2, 0x5b, 0x2f, 0xf3, 0xc6, 0xec, 0x10, 0x88, 0xc5, 0xc3, 0x7f, 0x85, 0xb9, 0x2f, 0x6e, 0xe7, 0xdb, 0x41, 0xf7, 0xc8, 0x67, 0xe3, 0x5b, 0x1a, 0xae, 0x99, 0xa4, 0xe6, 0xb6, 0xf, 0x73, 0x4e, 0x1, 0xe5, 0x98, 0xb, 0x60, 0x80, 0x22, 0xef, 0x24, 0x39, 0xd5, 0x82, 0x68, 0x5e, 0x5e, 0x12, 0x32, 0xb2, 0x5c, 0x71, 0xbc, 0xed, 0x4a, 0x91, 0xe3, 0xac, 0xee, 0xd3, 0xe6, 0xa1, 0x48, 0x8d, 0x8b, 0x58, 0x2d, 0x10, 0xb7, 0x97, 0x1e, 0x98, 0x71, 0xe5, 0xac, 0x2e, 0x69, 0x36, 0xef, 0x2d, 0x55, 0x35, 0x3d}, - output224: []byte{0x9b, 0xdb, 0xeb, 0x56, 0xbb, 0xf0, 0x60, 0xfd, 0x4, 0xe8, 0x54, 0xc7, 0x48, 0xa, 0x64, 0x6a, 0xca, 0x77, 0xc8, 0xee, 0x8a, 0x60, 0xae, 0x7, 0xa2, 0xce, 0x6d, 0x7c}, - output256: []byte{0xc6, 0xc2, 0x5c, 0xfb, 0x97, 0xe8, 0x5b, 0x3d, 0x59, 0xc5, 0xf7, 0xce, 0xae, 0xf6, 0xd0, 0x6f, 0xc3, 0x14, 0xc0, 0xb2, 0x3f, 0x37, 0xc3, 0xc0, 0x45, 0x48, 0x90, 0x82, 0x1a, 0x9c, 0xc8, 0x16}, - output384: []byte{0xbd, 0x9c, 0x83, 0xb7, 0x53, 0xe6, 0xce, 0xab, 0x4e, 0x92, 0xdf, 0x62, 0x6f, 0x64, 0x70, 0xf8, 0x81, 0xb5, 0x85, 0xbc, 0xee, 0xd8, 0x95, 0x9e, 0x51, 0x2d, 0x3a, 0x23, 0x8a, 0xc2, 0xd5, 0x81, 0xfe, 0x42, 0x94, 0xbd, 0x8e, 0xf, 0x69, 0xf8, 0x64, 0x72, 0x56, 0xcc, 0x29, 0xa9, 0x39, 0x3f}, - output512: []byte{0xcc, 0xa3, 0x47, 0xe, 0xf3, 0xca, 0xfc, 0x49, 0xc2, 0x3f, 0x74, 0xc8, 0xeb, 0xed, 0x8, 0x12, 0x75, 0x71, 0x3a, 0x8e, 0x5c, 0xea, 0x53, 0xd5, 0x90, 0x83, 0x5, 0x52, 0xe6, 0x69, 0x8f, 0xeb, 0x7f, 0xb9, 0xde, 0x3f, 0x72, 0x81, 0x17, 0x64, 0x68, 0xa1, 0xd6, 0xf3, 0x7d, 0xb7, 0xe4, 0xc1, 0x0, 0x68, 0x3a, 0x1a, 0x51, 0xda, 0x23, 0x3f, 0x90, 0x3b, 0x8, 0x2a, 0xbf, 0x64, 0x8d, 0xaa}}, - testcase{ - msg: []byte{0x16, 0x33, 0x25, 0x6a, 0xb0, 0x3b, 0x20, 0xce, 0x7, 0x91, 0x96, 0xb7, 0x8, 0xa1, 0xc0, 0x2d, 0x1b, 0x60, 0x72, 0x21, 0x90, 0x70, 0x71, 0x2c, 0x85, 0x89, 0xee, 0x21, 0x34, 0x1d, 0x50, 0x75, 0x2a, 0xcb, 0x6c, 0xfd, 0xa1, 0x7e, 0x98, 0x2d, 0x82, 0x8b, 0xbd, 0x6c, 0xdf,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7f, 0x78, 0xb3, 0x2e, 0xa7, 0x36, 0xb9, 0xb2, 0xb4, 0xa7, 0x95, 0xc3, 0x55, 0xc0, 0x31, 0x98, 0x11, 0x72, 0x9d, 0x9c, 0xc3, 0x99, 0xd2, 0x35, 0x19, 0x73, 0x3, 0x38, 0xd6, 0x2e, 0x16, 0xe5, 0x3, 0x5f, 0xc5, 0x2a, 0x81, 0x70, 0x90, 0x70, 0x3f, 0xe7, 0x76, 0xd6, 0x5e, 0xf9, 0xfe, 0xf5, 0xba, 0x5f, 0x4f, 0xfe, 0xc3, 0xcc, 0x8e, 0x9e, 0xb2, 0xe3, 0x12, 0xc5, 0xa, 0x47, 0x9b, 0xdd, 0x4e, 0x6a, 0xb0, 0xa5, 0x6c, 0x18, 0xc2, 0xdf, 0x69, 0xed, 0x40, 0x84, 0x17, 0xbe, 0xe2, 0x8b, 0xb4, 0x1d, 0xd1, 0x3f, 0x83, 0x66, 0xff, 0x6e, 0xda, 0x4b, 0x34, 0x9, 0xf, 0xc9, 0xbc, 0x4, 0x52, 0x71}, - output224: []byte{0x82, 0x69, 0x8a, 0xd7, 0x8d, 0xfc, 0x9e, 0x39, 0x66, 0x5c, 0x9d, 0xfd, 0x54, 0xc7, 0xbc, 0x44, 0xdb, 0xe, 0xbb, 0xa2, 0xe7, 0x41, 0xe8, 0xd, 0x52, 0x92, 0x66, 0x9b}, - output256: []byte{0x19, 0x2e, 0xae, 0xa8, 0x40, 0x38, 0xd5, 0x88, 0xad, 0x55, 0xdc, 0x51, 0x43, 0xf2, 0xbb, 0x10, 0x4, 0xe, 0xf7, 0x8b, 0xfc, 0x7f, 0xb9, 0x1f, 0x6b, 0x5e, 0x4c, 0x5, 0x34, 0x66, 0xaf, 0x0}, - output384: []byte{0xdd, 0x29, 0xed, 0x94, 0x68, 0xbb, 0x12, 0xde, 0x8f, 0x9c, 0xf6, 0x4a, 0xa7, 0x66, 0xb0, 0x44, 0x77, 0xd6, 0x59, 0xf0, 0x32, 0x74, 0x6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, 0xd3, 0x57, 0x44, 0xed, 0xf2, 0x14, 0xe3, 0xf8, 0x10, 0x7, 0x5e, 0x77, 0xbe, 0x79, 0x7d, 0xe0, 0x86, 0x2d, 0x4b, 0x3e, 0x77, 0x14, 0x6, 0xf6, 0x0, 0x7f, 0x7c, 0x29, 0x42, 0x6c, 0x16, 0xfb, 0x3c, 0xc5, 0x48, 0x34, 0x98, 0x64, 0x6f, 0xdd, 0xe6, 0x44, 0xc5, 0x54, 0x2b, 0x28, 0x37, 0x10, 0x19, 0xef, 0xef, 0xe5, 0xf, 0x29, 0xb2, 0x47, 0x9c, 0xc6, 0x8e, 0x7c, 0x40, 0xd6, 0x81, 0xd8, 0xe4, 0x96, 0x35, 0x6d, 0x71, 0xbe, 0x30, 0x79, 0x88, 0x97, 0xae, 0x49, 0x64, 0x16, 0xd7, 0xa3, 0xab, 0x97, 0x51, 0xcf, 0xeb, 0xb1, 0x43, 0xe0, 0xc, 0x3, 0x6c, 0x54, 0x2f, 0x79, 0xf6, 0x9f, 0x5, 0x18, 0x87, 0xe4, 0x29, 0x84, 0x95, 0x4e, 0xa5, 0x84, 0x4d, 0xad, 0xf5, 0x6b, 0x9b, 0xbd, 0x19, 0xe8, 0xd2, 0xc, 0xb9, 0xa4, 0xea}, - output224: []byte{0x1a, 0x74, 0x28, 0xb, 0x21, 0x7a, 0x3d, 0xa3, 0x2a, 0xce, 0x42, 0xd8, 0xae, 0x85, 0xdc, 0xf9, 0x4c, 0x33, 0x19, 0x98, 0xc2, 0xb1, 0x16, 0xff, 0x56, 0x86, 0x8d, 0x90}, - output256: []byte{0x7c, 0x96, 0xcf, 0xf2, 0xd7, 0xca, 0xf0, 0x2d, 0x6f, 0xcd, 0x46, 0xa3, 0x12, 0xc, 0x1d, 0xd9, 0x40, 0xfa, 0xb7, 0xbc, 0x5b, 0x70, 0xcf, 0x97, 0xe1, 0x82, 0xcc, 0xf7, 0x1a, 0xbe, 0xb6, 0x43}, - output384: []byte{0x6b, 0xdf, 0x6f, 0xd1, 0x83, 0xad, 0x49, 0xa1, 0xed, 0x91, 0xd9, 0xa0, 0x2d, 0xa0, 0x99, 0xf9, 0x56, 0x89, 0xf4, 0x37, 0x3e, 0xb5, 0x31, 0xd, 0xd4, 0xc1, 0xad, 0xd4, 0x51, 0xc8, 0xf6, 0x82, 0xe8, 0x89, 0x5e, 0xde, 0xf3, 0x4b, 0x5e, 0xf1, 0xe3, 0x5f, 0x3c, 0xab, 0x4e, 0x6e, 0xeb, 0x83}, - output512: []byte{0x1e, 0x63, 0x25, 0xee, 0xe, 0x57, 0xfc, 0x92, 0x97, 0xed, 0x58, 0xd3, 0x5c, 0xa2, 0x9e, 0xb0, 0x6b, 0x3, 0x4f, 0xc3, 0x37, 0xa0, 0xad, 0xb, 0x45, 0x3a, 0xf7, 0x67, 0x76, 0xc5, 0x9f, 0xc9, 0xa1, 0x15, 0xae, 0x1c, 0x3d, 0xf9, 0x1b, 0x2, 0x58, 0x32, 0x81, 0xaf, 0xf8, 0x3b, 0xff, 0x91, 0x8f, 0x63, 0xb1, 0xd, 0x98, 0x22, 0x25, 0xf, 0xc4, 0xe2, 0x97, 0xb1, 0x7, 0x72, 0xe1, 0x81}}, - testcase{ - msg: []byte{0x3, 0x97, 0x8f, 0xa9, 0xdb, 0xf1, 0xef, 0x4b, 0xea, 0xcb, 0x8f, 0x58, 0xd4, 0xc8, 0x2e, 0x29, 0x17, 0x70, 0x93, 0x52, 0xc, 0xdd, 0x8f, 0x3a, 0xf0, 0x19, 0xfd, 0x34, 0xee, 0x23, 0xb5, 0x89, 0x66, 0xbd, 0x79, 0x3d, 0x87, 0x83, 0xae, 0x53, 0xb4, 0xd0, 0x2, 0x38, 0xb8, 0x33, 0xeb, 0x41, 0xd7, 0x2a, 0x61, 0x69, 0x3, 0xa1, 0xc4, 0xd9, 0x72, 0xb, 0x6, 0x67, 0x45, 0xce, 0x4c, 0xb3, 0x20, 0x96, 0x7f, 0x9b, 0xee, 0xd5, 0x66, 0x90, 0x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, 0x1e, 0x57, 0xb9, 0x78, 0x2a, 0xb3, 0x62, 0x0, 0x53, 0xc8, 0x9d}, - output224: []byte{0x77, 0xab, 0x76, 0x68, 0x83, 0x2a, 0x56, 0x7e, 0x4f, 0x7f, 0x2e, 0xf3, 0x21, 0x3c, 0x59, 0x9a, 0xe9, 0x3a, 0x48, 0x51, 0xed, 0xa5, 0x6b, 0xfd, 0xb8, 0x14, 0x80, 0x9a}, - output256: []byte{0x96, 0x80, 0x5c, 0x12, 0xa7, 0x52, 0xa2, 0x69, 0x0, 0xcf, 0xbe, 0x7a, 0x47, 0xfb, 0x94, 0xd0, 0x3c, 0x94, 0x9a, 0x8d, 0xd3, 0xd7, 0xec, 0x15, 0x21, 0xdd, 0x1c, 0x9a, 0xef, 0x0, 0x68, 0xb2}, - output384: []byte{0xd2, 0x58, 0x71, 0x99, 0x4d, 0x47, 0x8f, 0xc, 0xc4, 0x6, 0x76, 0xf0, 0xc5, 0x3c, 0x9c, 0x60, 0x1d, 0x96, 0x2, 0xda, 0xc2, 0xb8, 0x42, 0x20, 0xaf, 0x46, 0xcd, 0xb3, 0x3c, 0x47, 0x59, 0xed, 0x97, 0x1c, 0x52, 0x92, 0x2e, 0x66, 0x23, 0x63, 0x90, 0xcb, 0xe9, 0x53, 0x68, 0xa2, 0x63, 0xa4}, - output512: []byte{0x2c, 0xb3, 0xf8, 0xe2, 0xd3, 0x22, 0x7d, 0x32, 0x13, 0x93, 0x1c, 0xc, 0xd4, 0x54, 0x6, 0xed, 0xe, 0xce, 0x37, 0x3e, 0x93, 0xa5, 0x74, 0x61, 0x8d, 0x5b, 0x6c, 0xfd, 0xc3, 0x1a, 0x75, 0x6f, 0xff, 0xe8, 0xe, 0xfa, 0xcf, 0xf9, 0x3a, 0x70, 0x8e, 0xe7, 0x2b, 0x76, 0xbc, 0x8e, 0xa0, 0xab, 0x40, 0xbf, 0x53, 0x3e, 0x44, 0x21, 0x10, 0x28, 0x43, 0x43, 0x72, 0x1b, 0x43, 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 0x85, 0x6e, 0xec, 0xb7, 0xb7, 0x2e, 0x76, 0xd8, 0x15, 0xf7, 0xae, 0x4, 0x24, 0x51, 0x9e, 0xb5, 0xb5, 0xc, 0x81, 0x28, 0xc4, 0xb1, 0x7d, 0x15, 0xdf, 0x1, 0x13, 0xbc, 0x30, 0x2a, 0xb}, - output384: []byte{0x85, 0xeb, 0x70, 0xf7, 0xc2, 0xbb, 0x4, 0x8, 0x53, 0x52, 0x33, 0x3d, 0xf7, 0x69, 0x38, 0x1, 0x2d, 0x15, 0x1d, 0x76, 0xa5, 0xe1, 0x65, 0xe6, 0xe1, 0x79, 0x6c, 0x69, 0x32, 0xf3, 0xa7, 0x19, 0x88, 0xab, 0xff, 0xae, 0xbe, 0x1b, 0x14, 0x8, 0xae, 0x4e, 0xcc, 0xde, 0xf7, 0x19, 0x8b, 0xd9}, - output512: []byte{0xa9, 0x17, 0xf7, 0x7e, 0xad, 0xc2, 0xb7, 0xa0, 0x14, 0x40, 0x9f, 0xd1, 0x24, 0xab, 0x38, 0x0, 0x5, 0xff, 0x9e, 0xa6, 0xda, 0xf9, 0x24, 0x54, 0xb, 0x72, 0x16, 0x42, 0xc0, 0xc7, 0x3d, 0x30, 0xd2, 0x40, 0x3c, 0xa7, 0x8b, 0xaa, 0x5b, 0x79, 0x13, 0x60, 0x46, 0x8d, 0xfb, 0x47, 0x5a, 0x55, 0x8e, 0x61, 0xe1, 0x5e, 0xf7, 0x12, 0xc7, 0x9f, 0xa2, 0xa8, 0xd6, 0xc3, 0x83, 0x41, 0xcb, 0x1b}}, - testcase{ - msg: []byte{0xe, 0x31, 0xc8, 0xa, 0x1c, 0x41, 0xdf, 0x5f, 0x70, 0x6d, 0xb8, 0xda, 0x40, 0xdc, 0xc0, 0x6e, 0x61, 0xb4, 0xd6, 0x96, 0x97, 0x15, 0xea, 0x2, 0x11, 0x3e, 0x2a, 0x63, 0x66, 0x3d, 0xa6, 0xaa, 0x3d, 0xf8, 0xba, 0x75, 0x51, 0x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 0x16, 0xcf, 0x81, 0x65, 0xa0, 0xb6, 0x1f, 0xca, 0xd8, 0x6f, 0x80, 0x38, 0xe0, 0xee, 0x83, 0x93, 0x94, 0x43, 0xf0, 0x14}, - output256: []byte{0xec, 0x23, 0xf3, 0xc4, 0x52, 0x43, 0x23, 0x39, 0x33, 0xa5, 0x81, 0xab, 0x55, 0x4e, 0xa3, 0x91, 0xac, 0xb3, 0xaf, 0xff, 0x8c, 0xed, 0x26, 0xe7, 0xed, 0x29, 0x44, 0x50, 0x40, 0xa8, 0xd5, 0x27}, - output384: []byte{0x9, 0x6a, 0xfc, 0x47, 0xcf, 0x56, 0x86, 0xfb, 0x78, 0x50, 0x70, 0xa2, 0xe0, 0x9f, 0xbf, 0x69, 0xf5, 0x9, 0xff, 0x92, 0x0, 0xb3, 0x45, 0x85, 0x7f, 0xb0, 0xb8, 0xe7, 0xc, 0xbb, 0xb0, 0x12, 0xb9, 0x28, 0x62, 0x71, 0x59, 0xab, 0xdb, 0x35, 0x63, 0x1a, 0xfa, 0xe8, 0x4c, 0x6d, 0xc, 0x58}, - output512: []byte{0xab, 0x2c, 0xd6, 0x17, 0x71, 0x32, 0x92, 0x54, 0x97, 0x7d, 0x33, 0x31, 0xb3, 0xbb, 0x8b, 0x94, 0x40, 0xba, 0x1b, 0x32, 0x36, 0xa, 0x58, 0x1f, 0x44, 0xc1, 0x7c, 0xc7, 0x83, 0x23, 0x17, 0x37, 0xaf, 0xf1, 0x4e, 0xa9, 0x52, 0x78, 0x6b, 0x2f, 0x5c, 0xe2, 0xdb, 0xe2, 0xb2, 0x76, 0xf2, 0x84, 0x8b, 0x25, 0xd7, 0xbd, 0x1d, 0x84, 0xf0, 0x73, 0xe5, 0x3, 0x6f, 0xc7, 0xb8, 0xd0, 0x8d, 0xa1}}, - testcase{ - msg: []byte{0x61, 0xcc, 0x4d, 0x97, 0xf4, 0x11, 0xd9, 0x59, 0x56, 0x2a, 0xf, 0xc4, 0x10, 0x9b, 0x44, 0x2a,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, 0x26, 0xc5, 0x68, 0x1f, 0xf0, 0xc1, 0xf9, 0xb6, 0x38, 0xcc, 0x8, 0xce, 0xd6, 0x15, 0x24, 0xec, 0x48, 0xa8, 0xe8, 0xbf, 0x93, 0xd2, 0x2, 0x8d, 0xc1, 0xf, 0xfe, 0x6, 0x3c, 0xb8, 0x7, 0xc9, 0x4c, 0xad, 0x3c, 0x2b, 0x69, 0x4e, 0xd9, 0x74, 0x73, 0x85, 0xef, 0x59, 0x34, 0xf4, 0xc8, 0x4f, 0x90, 0x7a, 0xf7, 0x99, 0x9e, 0x47, 0x6c, 0x27, 0x35, 0xe1, 0x31, 0x8a, 0xad, 0x6e, 0xbb, 0x79, 0x47, 0xd9, 0xa6, 0x4b, 0x2f, 0x62, 0x5e, 0x2d, 0xab, 0x7e, 0x77, 0xb6, 0xfd, 0xbf}, - output224: []byte{0x3b, 0xe8, 0x19, 0x8d, 0x48, 0x41, 0xd5, 0x7b, 0x66, 0x75, 0x57, 0x18, 0x50, 0x54, 0x36, 0x35, 0xdd, 0x9f, 0x22, 0x88, 0x2d, 0x49, 0x32, 0x8b, 0x75, 0x55, 0x98, 0xd9}, - output256: []byte{0x94, 0x71, 0x60, 0x79, 0x46, 0x3, 0x1a, 0x2e, 0x58, 0x9d, 0xdf, 0x6f, 0x7a, 0xe6, 0x89, 0x6c, 0xd9, 0x4e, 0x7d, 0xf, 0x86, 0x30, 0x6e, 0xd, 0x1a, 0x75, 0x77, 0x45, 0x13, 0xac, 0x95, 0x53}, - output384: []byte{0xa4, 0x1a, 0xa8, 0xf9, 0x43, 0x11, 0x7d, 0xe4, 0x1b, 0x2f, 0xa4, 0x24, 0x5b, 0xc9, 0x75, 0x8d, 0x67, 0x2f, 0x5d, 0xf, 0xec, 0xf4, 0x32, 0xac, 0x44, 0x63, 0x5b, 0xff, 0x2a, 0x46, 0xd3, 0x8f, 0x16, 0x8e, 0x23, 0x1e, 0xad, 0xef, 0x2c, 0x77, 0xd3, 0x44, 0x1f, 0x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, 0x7b, 0x37, 0xdf, 0xe3, 0xa1, 0xd5, 0x30, 0x18, 0x31, 0x11, 0xe2, 0xac, 0x6b, 0x30, 0x73, 0x6b, 0xe4, 0xff, 0xd6, 0xdb, 0xae, 0xc5, 0xdc, 0xbb, 0x71, 0x94, 0xb9, 0xf0, 0xcc, 0x73, 0x3f, 0xa, 0x3a}, - output224: []byte{0x93, 0x43, 0x6c, 0xf5, 0x50, 0x14, 0xb5, 0x33, 0xda, 0x3f, 0x89, 0xb, 0xd3, 0x18, 0x79, 0xb4, 0xdc, 0xdd, 0x88, 0xfb, 0xd8, 0x3, 0x43, 0xb6, 0x24, 0x8c, 0x8d, 0x7c}, - output256: []byte{0x89, 0xd2, 0x23, 0x1f, 0xc6, 0x58, 0xe2, 0x8b, 0xe2, 0xa1, 0xca, 0x23, 0x82, 0x18, 0x71, 0x37, 0x47, 0x9e, 0x38, 0x34, 0xb4, 0x98, 0xd8, 0xe0, 0x70, 0x71, 0x15, 0x15, 0xef, 0x67, 0xb, 0x4d}, - output384: []byte{0xe7, 0x3f, 0x2b, 0xa0, 0xdd, 0x0, 0x57, 0xb8, 0xe3, 0xa2, 0x9f, 0x8d, 0xc4, 0x3f, 0x52, 0x5c, 0x36, 0xa2, 0xe0, 0x3e, 0xc7, 0x71, 0xdb, 0x1d, 0x76, 0xd8, 0x7d, 0x86, 0xd5, 0x7c, 0x94, 0x80, 0x84, 0xae, 0xf3, 0x6d, 0x92, 0x31, 0xc7, 0xd0, 0x99, 0xb7, 0xb4, 0x2d, 0xf4, 0x56, 0x8d, 0x5b}, - output512: []byte{0x93, 0x61, 0x91, 0xdc, 0xb9, 0x6f, 0x5a, 0x3a, 0x3a, 0xc1, 0x6c, 0xd8, 0x17, 0x22, 0x38, 0xa5, 0x13, 0xcf, 0x1f, 0x9c, 0xc1, 0x96, 0x20, 0xbd, 0x7c, 0xcb, 0x7e, 0xb1, 0x13, 0x5a, 0x7a, 0xc5, 0x7f, 0xd2, 0xe7, 0x6b, 0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 0x38, 0x7e, 0x5, 0xb3, 0x1, 0x2c, 0x4, 0x58, 0xa3, 0x69, 0xe6, 0x21, 0x91, 0xf5, 0xbd, 0xc5, 0x7d, 0xd6, 0x3c, 0xe4, 0x2e, 0x94, 0x5f, 0x49, 0x3c, 0x2b, 0x42, 0x30, 0x6b, 0x80, 0x84, 0xf3, 0xb2, 0x5e, 0x94, 0xab, 0xac, 0xf0, 0x8e, 0xe1, 0x55, 0xf3, 0x62, 0x1a, 0xcc, 0x96, 0x26, 0xee, 0x48, 0x7c, 0x7a, 0x7e, 0x46, 0x67, 0xf0, 0x37, 0x7a, 0xe4, 0xb2}, - output224: []byte{0xba, 0xdf, 0x58, 0xa, 0x48, 0x5b, 0x27, 0x90, 0x58, 0x18, 0x3b, 0x4d, 0x53, 0x75, 0x5f, 0xba, 0xa8, 0x88, 0x9d, 0x34, 0xb0, 0x41, 0x61, 0x9b, 0xc2, 0x92, 0xe8, 0xd0}, - output256: []byte{0x86, 0xec, 0x53, 0x42, 0xab, 0x76, 0x7, 0x10, 0x35, 0x47, 0x98, 0x5b, 0xd8, 0x32, 0xa2, 0x71, 0x42, 0x6a, 0xcd, 0xe8, 0xdc, 0xac, 0x94, 0x1a, 0xa7, 0xc4, 0xff, 0x17, 0xcf, 0xb1, 0x76, 0x2}, - output384: []byte{0xbe, 0x96, 0x4d, 0x9a, 0xf6, 0x7d, 0x2a, 0x10, 0x60, 0x2d, 0xdc, 0x5f, 0x5e, 0x5c, 0x79, 0xd2, 0x39, 0x51, 0x11, 0x2c, 0x56, 0x24, 0x6e, 0xc7, 0x59, 0x31, 0xd9, 0xdf, 0xb3, 0xf0, 0xb0, 0x6d, 0xe4, 0x47, 0x88, 0x38, 0xda, 0xd9, 0xde, 0x9f, 0x8c, 0x76, 0xfe, 0xf0, 0xaa, 0xa7, 0xc6, 0x28}, - output512: []byte{0xdb, 0xd1, 0x99, 0x4, 0x88, 0x1f, 0x49, 0x12, 0xf9, 0x9e, 0xc3, 0x9b, 0x67, 0x3, 0x72, 0x70, 0x36, 0xc7, 0x67, 0xd2, 0x9, 0x7b, 0x9d, 0x14, 0x60, 0xb4, 0x83, 0xfb, 0x18, 0x2, 0xce, 0x5f, 0x6f, 0x5d, 0xe3, 0x83, 0xa3, 0xcf, 0x40, 0x67, 0x9d, 0x2a, 0x64, 0x15, 0xfe, 0x6e, 0xed, 0x2e, 0xbb, 0xff, 0xa3, 0xa5, 0xbd, 0xd4, 0x25, 0x29, 0x5b, 0xe, 0xbc, 0xf9, 0x81, 0xad, 0x1d, 0x3e}}, -} diff --git a/vendor/github.com/ebfe/keccak/sha3.go b/vendor/github.com/ebfe/keccak/sha3.go deleted file mode 100644 index d10c0f8..0000000 --- a/vendor/github.com/ebfe/keccak/sha3.go +++ /dev/null @@ -1,25 +0,0 @@ -package keccak - -import ( - "hash" -) - -// NewSHA3224 returns a new hash.Hash computing SHA3-224 as specified in the FIPS 202 draft. -func NewSHA3224() hash.Hash { - return newKeccak(224*2, 224, domainSHA3) -} - -// NewSHA3256 returns a new hash.Hash computing SHA3-256 as specified in the FIPS 202 draft. -func NewSHA3256() hash.Hash { - return newKeccak(256*2, 256, domainSHA3) -} - -// NewSHA3384 returns a new hash.Hash computing SHA3-384 as specified in the FIPS 202 draft. -func NewSHA3384() hash.Hash { - return newKeccak(384*2, 384, domainSHA3) -} - -// NewSHA3512 returns a new hash.Hash computing SHA3-512 as specified in the FIPS 202 draft. -func NewSHA3512() hash.Hash { - return newKeccak(512*2, 512, domainSHA3) -} diff --git a/vendor/github.com/ebfe/keccak/sha3_test.go b/vendor/github.com/ebfe/keccak/sha3_test.go deleted file mode 100644 index 5dc7449..0000000 --- a/vendor/github.com/ebfe/keccak/sha3_test.go +++ /dev/null @@ -1,54 +0,0 @@ -package keccak - -import ( - "bytes" - "testing" -) - -func TestSHA3224(t *testing.T) { - h := NewSHA3224() - for i := range tstShort { - h.Reset() - h.Write(sha3tests[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, sha3tests[i].output224) { - t.Errorf("testcase SHA3224 %d: expected %x got %x", i, sha3tests[i].output224, d) - } - } -} - -func TestSHA3256(t *testing.T) { - h := NewSHA3256() - for i := range sha3tests { - h.Reset() - h.Write(sha3tests[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, sha3tests[i].output256) { - t.Errorf("testcase SHA3256 %d: expected %x got %x", i, sha3tests[i].output256, d) - } - } -} - -func TestSHA3384(t *testing.T) { - h := NewSHA3384() - for i := range sha3tests { - h.Reset() - h.Write(sha3tests[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, sha3tests[i].output384) { - t.Errorf("testcase SHA3384 %d: expected %x got %x", i, sha3tests[i].output384, d) - } - } -} - -func TestSHA3512(t *testing.T) { - h := NewSHA3512() - for i := range sha3tests { - h.Reset() - h.Write(sha3tests[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, sha3tests[i].output512) { - t.Errorf("testcase SHA3512 %d: expected %x got %x", i, sha3tests[i].output512, d) - } - } -} diff --git a/vendor/github.com/ebfe/keccak/sha3_vectors_test.go b/vendor/github.com/ebfe/keccak/sha3_vectors_test.go deleted file mode 100644 index 5a3968d..0000000 --- a/vendor/github.com/ebfe/keccak/sha3_vectors_test.go +++ /dev/null @@ -1,1796 +0,0 @@ -package keccak - -var sha3tests = []testcase{ - { - msg: []byte{}, - output224: []byte{0x6b, 0x4e, 0x3, 0x42, 0x36, 0x67, 0xdb, 0xb7, 0x3b, 0x6e, 0x15, 0x45, 0x4f, 0xe, 0xb1, 0xab, 0xd4, 0x59, 0x7f, 0x9a, 0x1b, 0x7, 0x8e, 0x3f, 0x5b, 0x5a, 0x6b, 0xc7}, - output256: []byte{0xa7, 0xff, 0xc6, 0xf8, 0xbf, 0x1e, 0xd7, 0x66, 0x51, 0xc1, 0x47, 0x56, 0xa0, 0x61, 0xd6, 0x62, 0xf5, 0x80, 0xff, 0x4d, 0xe4, 0x3b, 0x49, 0xfa, 0x82, 0xd8, 0xa, 0x4b, 0x80, 0xf8, 0x43, 0x4a}, - output384: []byte{0xc, 0x63, 0xa7, 0x5b, 0x84, 0x5e, 0x4f, 0x7d, 0x1, 0x10, 0x7d, 0x85, 0x2e, 0x4c, 0x24, 0x85, 0xc5, 0x1a, 0x50, 0xaa, 0xaa, 0x94, 0xfc, 0x61, 0x99, 0x5e, 0x71, 0xbb, 0xee, 0x98, 0x3a, 0x2a, 0xc3, 0x71, 0x38, 0x31, 0x26, 0x4a, 0xdb, 0x47, 0xfb, 0x6b, 0xd1, 0xe0, 0x58, 0xd5, 0xf0, 0x4}, - output512: []byte{0xa6, 0x9f, 0x73, 0xcc, 0xa2, 0x3a, 0x9a, 0xc5, 0xc8, 0xb5, 0x67, 0xdc, 0x18, 0x5a, 0x75, 0x6e, 0x97, 0xc9, 0x82, 0x16, 0x4f, 0xe2, 0x58, 0x59, 0xe0, 0xd1, 0xdc, 0xc1, 0x47, 0x5c, 0x80, 0xa6, 0x15, 0xb2, 0x12, 0x3a, 0xf1, 0xf5, 0xf9, 0x4c, 0x11, 0xe3, 0xe9, 0x40, 0x2c, 0x3a, 0xc5, 0x58, 0xf5, 0x0, 0x19, 0x9d, 0x95, 0xb6, 0xd3, 0xe3, 0x1, 0x75, 0x85, 0x86, 0x28, 0x1d, 0xcd, 0x26}, - }, - { - msg: []byte{0xcc}, - output224: []byte{0xdf, 0x70, 0xad, 0xc4, 0x9b, 0x2e, 0x76, 0xee, 0xe3, 0xa6, 0x93, 0x1b, 0x93, 0xfa, 0x41, 0x84, 0x1c, 0x3a, 0xf2, 0xcd, 0xf5, 0xb3, 0x2a, 0x18, 0xb5, 0x47, 0x8c, 0x39}, - output256: []byte{0x67, 0x70, 0x35, 0x39, 0x1c, 0xd3, 0x70, 0x12, 0x93, 0xd3, 0x85, 0xf0, 0x37, 0xba, 0x32, 0x79, 0x62, 0x52, 0xbb, 0x7c, 0xe1, 0x80, 0xb0, 0xb, 0x58, 0x2d, 0xd9, 0xb2, 0xa, 0xaa, 0xd7, 0xf0}, - output384: []byte{0x5e, 0xe7, 0xf3, 0x74, 0x97, 0x3c, 0xd4, 0xbb, 0x3d, 0xc4, 0x1e, 0x30, 0x81, 0x34, 0x67, 0x98, 0x49, 0x7f, 0xf6, 0xe3, 0x6c, 0xb9, 0x35, 0x22, 0x81, 0xdf, 0xe0, 0x7d, 0x7, 0xfc, 0x53, 0xc, 0xa9, 0xad, 0x8e, 0xf7, 0xaa, 0xd5, 0x6e, 0xf5, 0xd4, 0x1b, 0xe8, 0x3d, 0x5e, 0x54, 0x38, 0x7}, - output512: []byte{0x39, 0x39, 0xfc, 0xc8, 0xb5, 0x7b, 0x63, 0x61, 0x25, 0x42, 0xda, 0x31, 0xa8, 0x34, 0xe5, 0xdc, 0xc3, 0x6e, 0x2e, 0xe0, 0xf6, 0x52, 0xac, 0x72, 0xe0, 0x26, 0x24, 0xfa, 0x2e, 0x5a, 0xde, 0xec, 0xc7, 0xdd, 0x6b, 0xb3, 0x58, 0x2, 0x24, 0xb4, 0xd6, 0x13, 0x87, 0x6, 0xfc, 0x6e, 0x80, 0x59, 0x7b, 0x52, 0x80, 0x51, 0x23, 0xb, 0x0, 0x62, 0x1c, 0xc2, 0xb2, 0x29, 0x99, 0xea, 0xa2, 0x5}, - }, - { - msg: []byte{0x41, 0xfb}, - output224: []byte{0xbf, 0xf2, 0x95, 0x86, 0x1d, 0xae, 0xdf, 0x33, 0xe7, 0x5, 0x19, 0xb1, 0xe2, 0xbc, 0xb4, 0xc2, 0xe9, 0xfe, 0x33, 0x64, 0xd7, 0x89, 0xbc, 0x3b, 0x17, 0x30, 0x1c, 0x15}, - output256: []byte{0x39, 0xf3, 0x1b, 0x6e, 0x65, 0x3d, 0xfc, 0xd9, 0xca, 0xed, 0x26, 0x2, 0xfd, 0x87, 0xf6, 0x1b, 0x62, 0x54, 0xf5, 0x81, 0x31, 0x2f, 0xb6, 0xee, 0xec, 0x4d, 0x71, 0x48, 0xfa, 0x2e, 0x72, 0xaa}, - output384: []byte{0x1d, 0xd8, 0x16, 0x9, 0xdc, 0xc2, 0x90, 0xef, 0xfd, 0x7a, 0xc0, 0xa9, 0x5d, 0x4a, 0x20, 0x82, 0x15, 0x80, 0xe5, 0x6b, 0xd5, 0xd, 0xbd, 0x84, 0x39, 0x20, 0x65, 0xb, 0xe7, 0xa8, 0xa, 0x17, 0x19, 0x57, 0x7d, 0xa3, 0x37, 0xcf, 0xdf, 0x86, 0xe5, 0x1c, 0x76, 0x4c, 0xaa, 0x2e, 0x10, 0xbd}, - output512: []byte{0xaa, 0x9, 0x28, 0x65, 0xa4, 0x6, 0x94, 0xd9, 0x17, 0x54, 0xdb, 0xc7, 0x67, 0xb5, 0x20, 0x2c, 0x54, 0x6e, 0x22, 0x68, 0x77, 0x14, 0x7a, 0x95, 0xcb, 0x8b, 0x4c, 0x8f, 0x87, 0x9, 0xfe, 0x8c, 0xd6, 0x90, 0x52, 0x56, 0xb0, 0x89, 0xda, 0x37, 0x89, 0x6e, 0xa5, 0xca, 0x19, 0xd2, 0xcd, 0x9a, 0xb9, 0x4c, 0x71, 0x92, 0xfc, 0x39, 0xf7, 0xcd, 0x4d, 0x59, 0x89, 0x75, 0xa3, 0x1, 0x3c, 0x69}, - }, - { - msg: []byte{0x1f, 0x87, 0x7c}, - output224: []byte{0x14, 0x88, 0x9d, 0xf4, 0x9c, 0x7, 0x6a, 0x9a, 0xf2, 0xf4, 0xbc, 0xb1, 0x63, 0x39, 0xbc, 0xc4, 0x5a, 0x24, 0xeb, 0xf9, 0xce, 0x4d, 0xcd, 0xce, 0x7e, 0xc1, 0x72, 0x17}, - output256: []byte{0xbc, 0x22, 0x34, 0x5e, 0x4b, 0xd3, 0xf7, 0x92, 0xa3, 0x41, 0xcf, 0x18, 0xac, 0x7, 0x89, 0xf1, 0xc9, 0xc9, 0x66, 0x71, 0x2a, 0x50, 0x1b, 0x19, 0xd1, 0xb6, 0x63, 0x2c, 0xcd, 0x40, 0x8e, 0xc5}, - output384: []byte{0x14, 0xf6, 0xf4, 0x86, 0xfb, 0x98, 0xed, 0x46, 0xa4, 0xa1, 0x98, 0x4, 0xd, 0xa8, 0x7, 0x9e, 0x79, 0xe4, 0x48, 0xda, 0xac, 0xeb, 0xe9, 0x5, 0xfb, 0x4c, 0xf0, 0xdf, 0x86, 0xef, 0x2a, 0x71, 0x51, 0xf6, 0x2f, 0xe0, 0x95, 0xbf, 0x85, 0x16, 0xeb, 0x6, 0x77, 0xfe, 0x60, 0x77, 0x34, 0xe2}, - output512: []byte{0xcb, 0x20, 0xdc, 0xf5, 0x49, 0x55, 0xf8, 0x9, 0x11, 0x11, 0x68, 0x8b, 0xec, 0xce, 0xf4, 0x8c, 0x1a, 0x2f, 0xd, 0x6, 0x8, 0xc3, 0xa5, 0x75, 0x16, 0x37, 0x51, 0xf0, 0x2, 0xdb, 0x30, 0xf4, 0xf, 0x2f, 0x67, 0x18, 0x34, 0xb2, 0x2d, 0x20, 0x85, 0x91, 0xcf, 0xaf, 0x1f, 0x5e, 0xcf, 0xe4, 0x3c, 0x49, 0x86, 0x3a, 0x53, 0xb3, 0x22, 0x5b, 0xdf, 0xd7, 0xc6, 0x59, 0x1b, 0xa7, 0x65, 0x8b}, - }, - { - msg: []byte{0xc1, 0xec, 0xfd, 0xfc}, - output224: []byte{0xa3, 0x3c, 0x58, 0xdf, 0x8a, 0x80, 0x26, 0xf0, 0xf9, 0x59, 0x19, 0x66, 0xbd, 0x6d, 0x0, 0xee, 0xd3, 0xb1, 0xe8, 0x29, 0x58, 0xa, 0xb9, 0xbe, 0x26, 0x8c, 0xaf, 0x39}, - output256: []byte{0xc5, 0x85, 0x9b, 0xe8, 0x25, 0x60, 0xcc, 0x87, 0x89, 0x13, 0x3f, 0x7c, 0x83, 0x4a, 0x6e, 0xe6, 0x28, 0xe3, 0x51, 0xe5, 0x4, 0xe6, 0x1, 0xe8, 0x5, 0x9a, 0x6, 0x67, 0xff, 0x62, 0xc1, 0x24}, - output384: []byte{0xd9, 0x2b, 0xbd, 0x60, 0x4b, 0xdd, 0x24, 0xb9, 0x88, 0x95, 0x8, 0xf8, 0x55, 0x8b, 0x13, 0xe9, 0x65, 0x95, 0xac, 0x90, 0xbc, 0x8a, 0x44, 0x1d, 0xaf, 0x9b, 0x51, 0xd6, 0xab, 0xc1, 0x4f, 0xfd, 0x8, 0x35, 0xfb, 0x93, 0x66, 0xe3, 0x91, 0x25, 0x4, 0x26, 0x4c, 0xe8, 0x7e, 0x42, 0x1c, 0xb8}, - output512: []byte{0xd4, 0xb4, 0xbd, 0xfe, 0xf5, 0x6b, 0x82, 0x1d, 0x36, 0xf4, 0xf7, 0xa, 0xb0, 0xd2, 0x31, 0xb8, 0xd0, 0xc9, 0x13, 0x46, 0x38, 0xfd, 0x54, 0xc4, 0x63, 0x9, 0xd1, 0x4f, 0xad, 0xa9, 0x2a, 0x28, 0x40, 0x18, 0x6e, 0xed, 0x54, 0x15, 0xad, 0x7c, 0xf3, 0x96, 0x9b, 0xdf, 0xbf, 0x2d, 0xaf, 0x8c, 0xca, 0x76, 0xab, 0xfe, 0x54, 0x9b, 0xe6, 0x57, 0x8c, 0x6f, 0x41, 0x43, 0x61, 0x7a, 0x4f, 0x1a}, - }, - { - msg: []byte{0x21, 0xf1, 0x34, 0xac, 0x57}, - output224: []byte{0x10, 0xe5, 0x80, 0xa3, 0x21, 0x99, 0x59, 0x61, 0x69, 0x33, 0x1a, 0xd4, 0x3c, 0xfc, 0xf1, 0x2, 0x64, 0xf8, 0x15, 0x65, 0x3, 0x70, 0x40, 0x2, 0x8a, 0x6, 0xb4, 0x58}, - output256: []byte{0x55, 0xbd, 0x92, 0x24, 0xaf, 0x4e, 0xed, 0xd, 0x12, 0x11, 0x49, 0xe3, 0x7f, 0xf4, 0xd7, 0xdd, 0x5b, 0xe2, 0x4b, 0xd9, 0xfb, 0xe5, 0x6e, 0x1, 0x71, 0xe8, 0x7d, 0xb7, 0xa6, 0xf4, 0xe0, 0x6d}, - output384: []byte{0xe2, 0x48, 0xd6, 0xff, 0x34, 0x2d, 0x35, 0xa3, 0xe, 0xc2, 0x30, 0xba, 0x51, 0xcd, 0xb1, 0x61, 0x2, 0x5d, 0x6f, 0x1c, 0x25, 0x1a, 0xca, 0x6a, 0xe3, 0x53, 0x1f, 0x6, 0x82, 0xc1, 0x64, 0xa1, 0xfc, 0x7, 0x25, 0xb1, 0xbe, 0xff, 0x80, 0x8a, 0x20, 0xc, 0x13, 0x15, 0x57, 0xa2, 0x28, 0x9}, - output512: []byte{0x58, 0x42, 0x19, 0xa8, 0x4e, 0x87, 0x96, 0x7, 0x6b, 0xf1, 0x17, 0x8b, 0x14, 0xb9, 0xd1, 0xe2, 0xf9, 0x6a, 0x4b, 0x4e, 0xf1, 0x1f, 0x10, 0xcc, 0x51, 0x6f, 0xbe, 0x1a, 0x29, 0x63, 0x9d, 0x6b, 0xa7, 0x4f, 0xb9, 0x28, 0x15, 0xf9, 0xe3, 0xc5, 0x19, 0x2e, 0xd4, 0xdc, 0xa2, 0xa, 0xea, 0x5b, 0x10, 0x9d, 0x52, 0x23, 0x7c, 0x99, 0x56, 0x40, 0x1f, 0xd4, 0x4b, 0x22, 0x1f, 0x82, 0xab, 0x37}, - }, - { - msg: []byte{0xc6, 0xf5, 0xb, 0xb7, 0x4e, 0x29}, - output224: []byte{0xfe, 0x52, 0xc3, 0xc, 0x95, 0xc1, 0xe5, 0x19, 0x32, 0x7, 0xe9, 0x7d, 0x35, 0x5f, 0xde, 0x9, 0x45, 0x34, 0x82, 0x70, 0x8c, 0x8, 0x76, 0xaa, 0x96, 0x15, 0x8, 0xf0}, - output256: []byte{0xae, 0xc, 0xbc, 0x75, 0x7d, 0x4a, 0xb0, 0x88, 0xe1, 0x72, 0xab, 0xfd, 0x87, 0x46, 0x28, 0x99, 0x50, 0xf9, 0x2d, 0x38, 0xa2, 0x52, 0x95, 0x65, 0x8d, 0xbf, 0x74, 0x4b, 0x56, 0x35, 0xaf, 0x4}, - output384: []byte{0xd6, 0xdd, 0x2e, 0xd0, 0x8c, 0x1f, 0x64, 0x48, 0x57, 0xa1, 0x5d, 0xaf, 0xaf, 0x80, 0x53, 0x8b, 0xee, 0x59, 0x72, 0x78, 0xc9, 0xab, 0xe0, 0x47, 0xbf, 0xba, 0xbf, 0xb8, 0xb1, 0xfc, 0xb7, 0x54, 0x3e, 0x80, 0xae, 0x9f, 0x71, 0x43, 0xd0, 0xf, 0x4d, 0xaa, 0xf3, 0x9b, 0x13, 0x8a, 0xb3, 0xff}, - output512: []byte{0x43, 0x45, 0xb9, 0x2a, 0x2a, 0xb7, 0xea, 0xdb, 0x6a, 0x24, 0xee, 0x1d, 0x17, 0x5a, 0xc2, 0x58, 0xcc, 0xf2, 0xf6, 0x94, 0xac, 0x9, 0xec, 0x9d, 0x47, 0x39, 0x9e, 0x4d, 0x96, 0xf6, 0x1f, 0x30, 0xb3, 0x22, 0xc5, 0x43, 0x8c, 0x51, 0xba, 0xcd, 0xd, 0x59, 0x7d, 0x0, 0x47, 0x1a, 0x41, 0xed, 0x8e, 0x9c, 0x9f, 0x14, 0x6b, 0xbc, 0x80, 0x7e, 0x6b, 0xc3, 0x85, 0xf8, 0x50, 0xfb, 0xab, 0xfe}, - }, - { - msg: []byte{0x11, 0x97, 0x13, 0xcc, 0x83, 0xee, 0xef}, - output224: []byte{0x8b, 0x44, 0x98, 0x49, 0xcb, 0x7c, 0x47, 0x76, 0xc5, 0x93, 0xde, 0x58, 0xfd, 0x5c, 0x2e, 0x32, 0x2c, 0xb5, 0x31, 0x6b, 0xe0, 0x8a, 0x75, 0x5, 0x7a, 0x1, 0xed, 0x6a}, - output256: []byte{0xe3, 0x40, 0xc9, 0xa4, 0x43, 0x73, 0xef, 0xcc, 0x21, 0x2f, 0x3c, 0xb6, 0x6a, 0x4, 0x7a, 0xc3, 0x4c, 0x87, 0xff, 0x1c, 0x58, 0xc4, 0xa1, 0x4b, 0x16, 0xa2, 0xbf, 0xc3, 0x46, 0x98, 0xbb, 0x1d}, - output384: []byte{0x49, 0xca, 0x1e, 0xb8, 0xd7, 0x1d, 0x1f, 0xdc, 0x7a, 0x72, 0xda, 0xa3, 0x20, 0xc8, 0xf9, 0xca, 0x54, 0x36, 0x71, 0xc2, 0xcb, 0x8f, 0xe9, 0xb2, 0x63, 0x8a, 0x84, 0x16, 0xdf, 0x50, 0xa7, 0x90, 0xa5, 0xd, 0xb, 0xb6, 0xb8, 0x87, 0x41, 0xd7, 0x81, 0x6d, 0x60, 0x61, 0xf4, 0x6a, 0xea, 0x89}, - output512: []byte{0x50, 0x8, 0x1c, 0x93, 0xbf, 0x73, 0xec, 0xc5, 0x4a, 0x5f, 0xfe, 0x43, 0xfc, 0x14, 0xf8, 0xba, 0xee, 0xdb, 0xe7, 0xda, 0x3, 0x2, 0xac, 0x98, 0x4c, 0x9e, 0x66, 0x83, 0x89, 0x88, 0x6b, 0xd0, 0x64, 0xba, 0xb2, 0x6d, 0xdc, 0xb6, 0x16, 0xeb, 0x4e, 0xe, 0x72, 0x60, 0x42, 0xb1, 0x9f, 0x3f, 0xd5, 0xb, 0xdd, 0xd, 0x2c, 0x5b, 0x34, 0x89, 0x2e, 0x0, 0xe6, 0xf3, 0x99, 0xde, 0x25, 0x4f}, - }, - { - msg: []byte{0x4a, 0x4f, 0x20, 0x24, 0x84, 0x51, 0x25, 0x26}, - output224: []byte{0x1, 0x38, 0x6c, 0xdd, 0x70, 0x58, 0x9b, 0x3b, 0x34, 0x94, 0x1e, 0xfe, 0x16, 0xb8, 0x50, 0x71, 0xe9, 0xba, 0x94, 0x81, 0x79, 0x92, 0x20, 0x44, 0xf6, 0x40, 0x86, 0x8e}, - output256: []byte{0xba, 0x4f, 0xb0, 0x9, 0xd5, 0x7a, 0x5c, 0xeb, 0x85, 0xfc, 0x64, 0xd5, 0x4e, 0x5c, 0x55, 0xa5, 0x58, 0x54, 0xb4, 0x1c, 0xc4, 0x7a, 0xd1, 0x52, 0x94, 0xbc, 0x41, 0xf3, 0x21, 0x65, 0xdf, 0xba}, - output384: []byte{0x89, 0xdb, 0xf4, 0xc3, 0x9b, 0x8f, 0xb4, 0x6f, 0xdf, 0xa, 0x69, 0x26, 0xce, 0xc0, 0x35, 0x5a, 0x4b, 0xdb, 0xf9, 0xc6, 0xa4, 0x46, 0xe1, 0x40, 0xb7, 0xc8, 0xbd, 0x8, 0xff, 0x6f, 0x48, 0x9f, 0x20, 0x5d, 0xaf, 0x8e, 0xff, 0xe1, 0x60, 0xf4, 0x37, 0xf6, 0x74, 0x91, 0xef, 0x89, 0x7c, 0x23}, - output512: []byte{0x15, 0xd, 0x78, 0x7d, 0x6e, 0xb4, 0x96, 0x70, 0xc2, 0xa4, 0xcc, 0xd1, 0x7e, 0x6c, 0xce, 0x7a, 0x4, 0xc1, 0xfe, 0x30, 0xfc, 0xe0, 0x3d, 0x1e, 0xf2, 0x50, 0x17, 0x52, 0xd9, 0x2a, 0xe0, 0x4c, 0xb3, 0x45, 0xfd, 0x42, 0xe5, 0x10, 0x38, 0xc8, 0x3b, 0x2b, 0x4f, 0x8f, 0xd4, 0x38, 0xd1, 0xb4, 0xb5, 0x5c, 0xc5, 0x88, 0xc6, 0xb9, 0x13, 0x13, 0x2f, 0x1a, 0x65, 0x8f, 0xb1, 0x22, 0xcb, 0x52}, - }, - { - msg: []byte{0x1f, 0x66, 0xab, 0x41, 0x85, 0xed, 0x9b, 0x63, 0x75}, - output224: []byte{0x86, 0x95, 0x3d, 0x8, 0x64, 0x1, 0x9c, 0x81, 0xfd, 0x3a, 0x80, 0x53, 0x57, 0xa1, 0x62, 0xfd, 0x76, 0xa1, 0x3a, 0x7c, 0xbf, 0x6f, 0xf0, 0xd6, 0x35, 0x1, 0x5d, 0xe}, - output256: []byte{0xb9, 0x88, 0x6e, 0xf9, 0x5, 0xc8, 0xbd, 0xd2, 0x72, 0xed, 0xa8, 0x29, 0x88, 0x65, 0xe0, 0x76, 0x98, 0x69, 0xf1, 0xc9, 0x64, 0x46, 0xd, 0x1a, 0xa9, 0xd7, 0xa0, 0xc6, 0x87, 0x70, 0x7c, 0xcd}, - output384: []byte{0xd6, 0x15, 0x46, 0x41, 0xd7, 0xd9, 0xdf, 0x62, 0xf0, 0xce, 0xdc, 0x2b, 0xd6, 0x4e, 0xe8, 0x24, 0x12, 0xb3, 0xa8, 0xf, 0x6e, 0xac, 0xe7, 0xc4, 0x5f, 0x97, 0x3, 0x37, 0x33, 0x79, 0x0, 0x7e, 0xab, 0xf5, 0x92, 0xd2, 0xd2, 0x11, 0x6e, 0x9, 0x3d, 0xc3, 0x3d, 0xcb, 0xba, 0x46, 0x49, 0xe9}, - output512: []byte{0xa1, 0x3c, 0x95, 0x1c, 0x6c, 0x51, 0xf2, 0x36, 0xa0, 0x19, 0x7a, 0x29, 0xa8, 0x99, 0x4b, 0x1c, 0x72, 0x94, 0xe1, 0x7b, 0xa5, 0x18, 0xed, 0x10, 0x29, 0xd6, 0xf5, 0x4a, 0xd7, 0x39, 0xd8, 0x76, 0x59, 0x20, 0x28, 0x1b, 0xbb, 0x85, 0x4d, 0x16, 0xfb, 0xb6, 0xe, 0x3, 0x85, 0xaf, 0xd6, 0xe6, 0xe4, 0x33, 0xe6, 0x3a, 0xaa, 0x77, 0xe7, 0x3b, 0x8b, 0xee, 0x7f, 0xde, 0x56, 0x9d, 0x68, 0x75}, - }, - { - msg: []byte{0xee, 0xd7, 0x42, 0x22, 0x27, 0x61, 0x3b, 0x6f, 0x53, 0xc9}, - output224: []byte{0xe5, 0x6f, 0xc2, 0xa5, 0xa5, 0x87, 0x9, 0x3, 0x1d, 0xf0, 0x2a, 0x2e, 0x46, 0xad, 0x95, 0xf9, 0x35, 0x83, 0xe2, 0x74, 0x56, 0x30, 0x54, 0xd, 0x8d, 0x97, 0xf7, 0x3}, - output256: []byte{0xfa, 0xb8, 0xf8, 0x8d, 0x31, 0x91, 0xe2, 0x1a, 0x72, 0x5b, 0x21, 0xc6, 0x3a, 0x2, 0xca, 0xd3, 0xfa, 0x7c, 0x45, 0xe, 0xf8, 0x58, 0x4b, 0x94, 0xcf, 0xa3, 0x82, 0xf3, 0x93, 0x42, 0x24, 0x55}, - output384: []byte{0x2e, 0xe5, 0xdf, 0x25, 0x91, 0xcf, 0xc4, 0xcb, 0x1e, 0x1d, 0xb, 0xd8, 0xb2, 0x87, 0x27, 0xf0, 0xfa, 0x53, 0x59, 0xa7, 0x5f, 0x78, 0x19, 0xa9, 0x2a, 0x3c, 0xb8, 0xd, 0xdb, 0x57, 0x8, 0xe4, 0x70, 0x51, 0x77, 0xb9, 0x81, 0x39, 0x6b, 0x48, 0x18, 0xd1, 0x1e, 0x3c, 0xa6, 0x15, 0xec, 0x93}, - output512: []byte{0x5a, 0x56, 0x6f, 0xb1, 0x81, 0xbe, 0x53, 0xa4, 0x10, 0x92, 0x75, 0x53, 0x7d, 0x80, 0xe5, 0xfd, 0xf, 0x31, 0x4d, 0x68, 0x88, 0x45, 0x29, 0xca, 0x66, 0xb8, 0xb0, 0xe9, 0xf2, 0x40, 0xa6, 0x73, 0xb6, 0x4b, 0x28, 0xff, 0xfe, 0x4c, 0x1e, 0xc4, 0xa5, 0xce, 0xf0, 0xf4, 0x30, 0x22, 0x9c, 0x57, 0x57, 0xeb, 0xd1, 0x72, 0xb4, 0xb0, 0xb6, 0x8a, 0x81, 0xd8, 0xc5, 0x8a, 0x9e, 0x96, 0xe1, 0x64}, - }, - { - msg: []byte{0xea, 0xee, 0xd5, 0xcd, 0xff, 0xd8, 0x9d, 0xec, 0xe4, 0x55, 0xf1}, - output224: []byte{0x1d, 0x78, 0x3c, 0x37, 0xc3, 0x2a, 0x2b, 0x71, 0xb5, 0x4, 0xbc, 0xaa, 0x5, 0xfc, 0x0, 0xb6, 0x39, 0xf1, 0xfa, 0xe7, 0xe8, 0xd8, 0xe3, 0xf3, 0xbc, 0x49, 0xf0, 0x41}, - output256: []byte{0x93, 0x63, 0xac, 0xd3, 0xf4, 0x8b, 0xb9, 0x1a, 0x89, 0x98, 0xaa, 0xe, 0x8d, 0xf7, 0x5c, 0x97, 0x17, 0x70, 0xa1, 0x6a, 0x71, 0xe7, 0xd2, 0x33, 0x44, 0x9, 0x73, 0x4c, 0xd7, 0xd0, 0xa9, 0xee}, - output384: []byte{0x78, 0x6c, 0x3f, 0x73, 0xfb, 0x9, 0x2b, 0xe1, 0x84, 0xfc, 0x2b, 0x19, 0xf5, 0x92, 0xf, 0x3d, 0x94, 0xf2, 0x5d, 0x45, 0x23, 0x16, 0x5a, 0xe8, 0x2f, 0x9b, 0x39, 0xb2, 0xc7, 0x24, 0xfd, 0x62, 0xdc, 0x9a, 0x32, 0x63, 0x9, 0x1a, 0x23, 0x9d, 0x5e, 0xf1, 0xad, 0x56, 0x2d, 0xd4, 0xfd, 0x26}, - output512: []byte{0x7c, 0x77, 0xe3, 0xe, 0xce, 0x98, 0xef, 0x88, 0x96, 0x44, 0x58, 0x68, 0x3c, 0x5e, 0x2, 0x87, 0xb5, 0x89, 0x6e, 0x16, 0x6c, 0xcc, 0xa7, 0x1d, 0x2b, 0xfd, 0x8d, 0x8b, 0xbc, 0x6d, 0x6f, 0xe5, 0x89, 0xa0, 0x22, 0x5e, 0xb1, 0xd6, 0xaa, 0x7b, 0x22, 0xf, 0x14, 0x10, 0xc9, 0xa9, 0xec, 0x6, 0x72, 0xcc, 0xdd, 0xaa, 0x17, 0x32, 0xc3, 0xe2, 0x87, 0x7f, 0xb5, 0xd2, 0x32, 0xc2, 0xa4, 0x28}, - }, - { - msg: []byte{0x5b, 0xe4, 0x3c, 0x90, 0xf2, 0x29, 0x2, 0xe4, 0xfe, 0x8e, 0xd2, 0xd3}, - output224: []byte{0x54, 0xc7, 0xe4, 0xbf, 0x3c, 0x73, 0xe1, 0x92, 0xad, 0xe2, 0x23, 0xdf, 0xea, 0x86, 0xf2, 0xd0, 0x4a, 0xcf, 0x95, 0x36, 0x12, 0x73, 0x19, 0x58, 0xf8, 0x54, 0xc7, 0xbd}, - output256: []byte{0x16, 0x93, 0x2f, 0x6f, 0x65, 0xde, 0xaa, 0xd5, 0x78, 0xe, 0x25, 0xab, 0x41, 0xc, 0x66, 0xb0, 0xe4, 0x19, 0x8e, 0xba, 0x9f, 0x4e, 0xd1, 0xa2, 0x5e, 0xe2, 0x4f, 0x78, 0x79, 0xfa, 0xef, 0xe2}, - output384: []byte{0x79, 0x18, 0x81, 0x39, 0xec, 0x2c, 0xad, 0x8d, 0x19, 0x7d, 0x30, 0x8b, 0x80, 0x6c, 0xf3, 0x83, 0x78, 0x2c, 0x29, 0xa8, 0xc2, 0x7e, 0xe2, 0x9c, 0x5e, 0x31, 0x42, 0x5b, 0x2d, 0xd1, 0x8b, 0x2f, 0x5f, 0x49, 0x1f, 0xbf, 0xb3, 0x8d, 0x70, 0x78, 0xf5, 0x85, 0x10, 0x12, 0x5c, 0x6, 0x4a, 0xa}, - output512: []byte{0xf5, 0xdf, 0x59, 0x52, 0x92, 0x4e, 0x93, 0x33, 0x30, 0xbd, 0x5b, 0xd7, 0x62, 0x7a, 0x62, 0xc3, 0x67, 0x2f, 0x24, 0xa4, 0x99, 0x1d, 0xad, 0xaf, 0x78, 0x81, 0x6e, 0x2, 0x37, 0x69, 0xc9, 0x1d, 0x19, 0x10, 0x53, 0x7f, 0x9c, 0x19, 0xfc, 0xde, 0x60, 0xfa, 0x6d, 0xe9, 0x27, 0x98, 0x2d, 0xd5, 0xf5, 0x97, 0xf, 0x74, 0xe3, 0xf, 0x2b, 0x4, 0xf, 0x67, 0x34, 0x8a, 0x33, 0x94, 0xc4, 0x8c}, - }, - { - msg: []byte{0xa7, 0x46, 0x27, 0x32, 0x28, 0x12, 0x2f, 0x38, 0x1c, 0x3b, 0x46, 0xe4, 0xf1}, - output224: []byte{0x77, 0xe5, 0x1c, 0xea, 0xda, 0x2a, 0xa1, 0xcb, 0xbf, 0x95, 0xac, 0xd8, 0x21, 0x0, 0x8b, 0x57, 0xe9, 0x46, 0xf7, 0x94, 0x2, 0x23, 0xb1, 0x9f, 0xc, 0x53, 0xe6, 0x2e}, - output256: []byte{0x1c, 0x28, 0x10, 0xe, 0xe, 0xf5, 0x6, 0x71, 0xc7, 0xea, 0x3e, 0x2, 0x4f, 0xa3, 0xba, 0x9d, 0xa2, 0xeb, 0xdd, 0xb4, 0xde, 0x26, 0x4c, 0x3a, 0x24, 0x26, 0xc3, 0x6a, 0xd3, 0xf9, 0x1c, 0x61}, - output384: []byte{0xc, 0x82, 0xb8, 0xc7, 0x5c, 0x5d, 0x54, 0xe, 0x7d, 0x62, 0x49, 0x28, 0x28, 0x1f, 0xba, 0x8b, 0x8d, 0xb, 0x15, 0x83, 0xd7, 0x4f, 0x3f, 0xe, 0xa4, 0xf2, 0x0, 0xf1, 0xce, 0x54, 0x75, 0x14, 0x9c, 0x28, 0x2e, 0x5, 0xdb, 0x69, 0x5d, 0xc6, 0x7b, 0xaf, 0x42, 0xde, 0xff, 0xdc, 0x3f, 0x55}, - output512: []byte{0x80, 0xa1, 0x31, 0x7e, 0xc5, 0x34, 0xed, 0x48, 0xd8, 0xa8, 0x13, 0xe0, 0xbc, 0xa0, 0xce, 0xe0, 0x4f, 0x70, 0x5a, 0x2f, 0x86, 0x35, 0x23, 0x6, 0xa9, 0x32, 0xed, 0xc5, 0x48, 0xb9, 0xa8, 0xf1, 0xcf, 0x79, 0xf9, 0x50, 0x27, 0xf4, 0x3b, 0xda, 0xda, 0x82, 0x13, 0x44, 0x9c, 0x54, 0xf6, 0x8f, 0x4d, 0xd8, 0x0, 0xb1, 0x5c, 0x4a, 0xba, 0xd8, 0x7a, 0xd7, 0xa3, 0xb3, 0x71, 0xa7, 0xc9, 0x18}, - }, - { - msg: []byte{0x3c, 0x58, 0x71, 0xcd, 0x61, 0x9c, 0x69, 0xa6, 0x3b, 0x54, 0xe, 0xb5, 0xa6, 0x25}, - output224: []byte{0x9e, 0xd5, 0x9e, 0xd1, 0x55, 0xe9, 0x71, 0x54, 0xe0, 0x67, 0xfa, 0xf, 0x5a, 0x13, 0x8, 0x39, 0xb5, 0x7b, 0xdb, 0xda, 0x6f, 0xeb, 0x82, 0xda, 0xbe, 0x0, 0x6f, 0x0}, - output256: []byte{0x81, 0x83, 0xbe, 0x48, 0x75, 0xfa, 0xb7, 0xec, 0x5f, 0x99, 0xed, 0x94, 0xf5, 0xf9, 0x0, 0xcf, 0x1d, 0x6b, 0x95, 0x3d, 0x8f, 0x71, 0xe1, 0xe7, 0xcc, 0x0, 0x86, 0x87, 0x98, 0xe, 0x61, 0x3a}, - output384: []byte{0x83, 0xd, 0x23, 0x25, 0xc0, 0x1, 0x62, 0x3e, 0xdf, 0xea, 0x97, 0xea, 0x1d, 0xe, 0x65, 0x98, 0x2d, 0x4e, 0xd7, 0xab, 0xb8, 0xe6, 0x4e, 0xa6, 0x1c, 0x85, 0xe9, 0xbc, 0x18, 0x82, 0xd1, 0x1f, 0xc4, 0x15, 0x3c, 0x30, 0xbe, 0x63, 0xfc, 0x66, 0xf5, 0xfb, 0xce, 0x74, 0xbb, 0x39, 0x45, 0x96}, - output512: []byte{0x54, 0xc2, 0x74, 0xc3, 0xdd, 0xf2, 0x6d, 0x82, 0x4f, 0x5f, 0xdf, 0xcb, 0x34, 0x9a, 0x60, 0x8, 0x90, 0x5, 0x7e, 0xb2, 0xe2, 0x2, 0x22, 0x45, 0xcb, 0xb8, 0xbd, 0xc0, 0xd2, 0x24, 0xc, 0xfa, 0x83, 0x48, 0xf0, 0x21, 0x91, 0xfa, 0xbc, 0xe, 0x10, 0xf9, 0x28, 0x71, 0x85, 0x21, 0x1c, 0x9f, 0x56, 0x91, 0x32, 0xee, 0x6d, 0xde, 0x4c, 0x39, 0x66, 0x68, 0xb4, 0xbb, 0x50, 0xae, 0xfc, 0x3f}, - }, - { - msg: []byte{0xfa, 0x22, 0x87, 0x4b, 0xcc, 0x6, 0x88, 0x79, 0xe8, 0xef, 0x11, 0xa6, 0x9f, 0x7, 0x22}, - output224: []byte{0x81, 0xb3, 0xe5, 0x6c, 0xfe, 0xee, 0x8e, 0x91, 0x38, 0xd3, 0xbf, 0xe2, 0x4b, 0xb7, 0xcc, 0xdf, 0xd4, 0xb5, 0xd, 0xb, 0x8c, 0xa1, 0x1a, 0xe7, 0xd4, 0xb0, 0xc9, 0x60}, - output256: []byte{0x3b, 0x1a, 0x6d, 0x21, 0xfe, 0x44, 0x69, 0x1d, 0xac, 0x4e, 0xb7, 0xc5, 0x93, 0xa6, 0xd8, 0x52, 0x3c, 0xb6, 0x6, 0xe6, 0x3c, 0xf0, 0xe, 0x94, 0xd7, 0x11, 0xa5, 0x74, 0x24, 0x8d, 0xac, 0xa5}, - output384: []byte{0x1d, 0xbe, 0x1b, 0xc6, 0xa, 0x9c, 0x6f, 0xbe, 0x10, 0xa7, 0x27, 0xe2, 0xa6, 0xd3, 0x97, 0x93, 0xd, 0x54, 0x7a, 0xd2, 0xc3, 0x90, 0x28, 0x69, 0x48, 0xc3, 0x16, 0x7e, 0xe7, 0x7f, 0xf6, 0xe2, 0x75, 0xec, 0x84, 0x31, 0xc5, 0xad, 0x4b, 0x4e, 0x4e, 0x5a, 0xe6, 0x7a, 0x4b, 0xc8, 0x8d, 0x5}, - output512: []byte{0x0, 0x76, 0x72, 0x36, 0xa7, 0x35, 0x25, 0x51, 0xb2, 0x83, 0xa8, 0xec, 0xf4, 0xc7, 0x92, 0x74, 0xf8, 0xc4, 0xce, 0xa5, 0x53, 0xab, 0x43, 0xfc, 0x71, 0xcf, 0x22, 0xfb, 0x2f, 0x68, 0x65, 0xad, 0x2, 0xc8, 0x8b, 0xf0, 0x9, 0x2f, 0x21, 0x30, 0x57, 0x34, 0xc, 0x85, 0xa5, 0x31, 0x8f, 0x62, 0xf4, 0x99, 0x1c, 0x0, 0xc6, 0x3c, 0xb0, 0x55, 0x8c, 0xbc, 0xf1, 0x3d, 0x6d, 0x84, 0xe7, 0x3d}, - }, - { - msg: []byte{0x52, 0xa6, 0x8, 0xab, 0x21, 0xcc, 0xdd, 0x8a, 0x44, 0x57, 0xa5, 0x7e, 0xde, 0x78, 0x21, 0x76}, - output224: []byte{0xb1, 0x57, 0x1b, 0xed, 0x52, 0xe5, 0x4e, 0xef, 0x37, 0x7d, 0x99, 0xdf, 0x7b, 0xe4, 0xbc, 0x66, 0x82, 0xc4, 0x33, 0x87, 0xf2, 0xbf, 0x9a, 0xcc, 0x92, 0xdf, 0x60, 0x8f}, - output256: []byte{0x2c, 0x7e, 0x7c, 0xb3, 0x56, 0xfd, 0xc6, 0x8e, 0xc8, 0x92, 0x7e, 0x49, 0x9d, 0x2a, 0x6b, 0xae, 0x2b, 0x78, 0x18, 0x17, 0x91, 0x9c, 0x82, 0x9e, 0xbb, 0xe8, 0x22, 0x5b, 0xae, 0xd4, 0x69, 0x67}, - output384: []byte{0xfe, 0xee, 0x2e, 0xf3, 0x32, 0x51, 0x52, 0x84, 0xe0, 0xba, 0x24, 0x7c, 0x62, 0xf2, 0x64, 0x19, 0x90, 0x44, 0xd0, 0x38, 0x77, 0xc5, 0x8e, 0x54, 0xb5, 0x1a, 0x62, 0xe3, 0x9e, 0x91, 0xc2, 0x7a, 0xaa, 0xe3, 0x84, 0x83, 0x7e, 0xb9, 0xd4, 0x79, 0xb4, 0xc0, 0x30, 0x8c, 0xfc, 0x6b, 0x77, 0x9b}, - output512: []byte{0x0, 0x16, 0x18, 0x37, 0x2e, 0x75, 0x14, 0x7a, 0xf9, 0xc, 0xc, 0xf1, 0x6c, 0x3b, 0xbd, 0xaa, 0x6, 0x9d, 0xdb, 0xc6, 0x24, 0x83, 0xb3, 0x92, 0xd0, 0x28, 0xde, 0xd4, 0x9f, 0x75, 0x8, 0x4a, 0x5d, 0xfc, 0xc5, 0x3a, 0xec, 0xd9, 0xf5, 0x7d, 0xdb, 0xb7, 0x3d, 0xaa, 0x4, 0x1f, 0xd7, 0x10, 0x89, 0xd8, 0xfb, 0x5e, 0xdf, 0x6c, 0xfa, 0xf6, 0xf1, 0xe4, 0xe2, 0x5a, 0xd3, 0xde, 0x26, 0x6c}, - }, - { - msg: []byte{0x82, 0xe1, 0x92, 0xe4, 0x4, 0x3d, 0xdc, 0xd1, 0x2e, 0xcf, 0x52, 0x96, 0x9d, 0xf, 0x80, 0x7e, 0xed}, - output224: []byte{0x8, 0x4, 0x5c, 0xf7, 0x8d, 0x23, 0x8d, 0x56, 0x97, 0x2f, 0x1c, 0x85, 0x4, 0x14, 0xbc, 0x40, 0x4f, 0xc6, 0xdc, 0xb1, 0x1f, 0x8d, 0x82, 0x10, 0xd0, 0x34, 0xc6, 0x10}, - output256: []byte{0xc7, 0xb1, 0x2e, 0xff, 0x69, 0x2d, 0x84, 0x21, 0x10, 0xcc, 0x39, 0xac, 0x60, 0x61, 0x67, 0x7, 0xac, 0xb3, 0xf9, 0xb0, 0xf1, 0xcb, 0x36, 0x1b, 0x94, 0x57, 0x7e, 0xfc, 0x52, 0x9c, 0xa2, 0x6c}, - output384: []byte{0x18, 0x88, 0xe9, 0x53, 0x72, 0x7c, 0xb8, 0x37, 0xde, 0x40, 0xc6, 0x98, 0x69, 0x56, 0xc, 0x20, 0x72, 0x9c, 0x50, 0x63, 0x8e, 0x45, 0x61, 0xb3, 0x85, 0x93, 0x7b, 0xfc, 0x4c, 0x29, 0x7e, 0x78, 0x9e, 0xa6, 0xc0, 0x3e, 0xfc, 0xf2, 0xdf, 0x32, 0x90, 0xb1, 0xfd, 0x36, 0xbe, 0x26, 0x8c, 0x32}, - output512: []byte{0x96, 0x44, 0xe3, 0xc9, 0xb, 0x67, 0xe2, 0x21, 0x24, 0xe9, 0x6d, 0xfe, 0xdc, 0xe5, 0x3d, 0x33, 0xc4, 0x60, 0xf1, 0x32, 0x86, 0x8f, 0x9, 0x75, 0xd1, 0x8b, 0x22, 0xcf, 0xd5, 0x9f, 0x63, 0x7d, 0xd8, 0x5a, 0xa4, 0x5, 0xe3, 0x98, 0x8, 0xa4, 0x55, 0x70, 0xa4, 0x98, 0xc0, 0xb8, 0xf2, 0xcb, 0xa5, 0x9f, 0x8e, 0x14, 0x37, 0xea, 0xef, 0x89, 0xf2, 0xb, 0x88, 0x29, 0x8a, 0xdf, 0xa2, 0xde}, - }, - { - msg: []byte{0x75, 0x68, 0x3d, 0xcb, 0x55, 0x61, 0x40, 0xc5, 0x22, 0x54, 0x3b, 0xb6, 0xe9, 0x9, 0x8b, 0x21, 0xa2, 0x1e}, - output224: []byte{0x9f, 0xfd, 0x84, 0xc, 0x55, 0xa, 0xd2, 0x39, 0x71, 0xeb, 0x5c, 0xe8, 0x9a, 0xe2, 0xfd, 0x62, 0x22, 0xab, 0xfb, 0x7f, 0xa, 0xaf, 0xd7, 0xeb, 0x0, 0x5, 0x71, 0x6b}, - output256: []byte{0x49, 0x3e, 0xba, 0xeb, 0xc0, 0x47, 0x76, 0xf4, 0xe0, 0x67, 0x55, 0x5a, 0xfa, 0x9, 0xb5, 0x8c, 0x85, 0xf, 0xdf, 0x1b, 0xe, 0x22, 0xd4, 0xbf, 0x0, 0x6c, 0xe4, 0x1c, 0x9, 0x1d, 0xc7, 0x62}, - output384: []byte{0x30, 0xde, 0x7b, 0x54, 0x42, 0x65, 0x42, 0x2c, 0xe6, 0x89, 0xe6, 0x67, 0xf4, 0x84, 0x98, 0xf4, 0x55, 0xe8, 0xbf, 0x10, 0x55, 0x65, 0x3f, 0x21, 0x29, 0x4e, 0xad, 0x7d, 0x2e, 0x89, 0x8b, 0x5, 0xfa, 0x75, 0xee, 0xca, 0x46, 0xdc, 0x25, 0x75, 0xc4, 0x75, 0xc4, 0x80, 0xaa, 0x49, 0xca, 0x62}, - output512: []byte{0x47, 0x39, 0x99, 0x43, 0x90, 0x72, 0x8f, 0x4a, 0x93, 0x8d, 0xf7, 0xb3, 0x20, 0x1c, 0xd6, 0x37, 0x71, 0x85, 0x84, 0x53, 0xf0, 0xff, 0x1d, 0xde, 0x9a, 0x2b, 0x9c, 0x38, 0xa2, 0x7a, 0xf, 0x6c, 0x86, 0x84, 0x60, 0xd0, 0xe, 0xe0, 0x3d, 0xdc, 0xb0, 0xf0, 0x63, 0xf5, 0xf8, 0xbb, 0x7c, 0xb0, 0x95, 0x9b, 0x7a, 0x22, 0x22, 0x59, 0xda, 0xf, 0x2c, 0x57, 0xfa, 0x40, 0xb, 0x50, 0x98, 0x5b}, - }, - { - msg: []byte{0x6, 0xe4, 0xef, 0xe4, 0x50, 0x35, 0xe6, 0x1f, 0xaa, 0xf4, 0x28, 0x7b, 0x4d, 0x8d, 0x1f, 0x12, 0xca, 0x97, 0xe5}, - output224: []byte{0x72, 0xde, 0xcb, 0x5e, 0xa1, 0xb2, 0x5a, 0x2d, 0xaa, 0xeb, 0x23, 0x4a, 0x8d, 0x96, 0xe0, 0xf5, 0x72, 0x11, 0x42, 0x66, 0x66, 0xa2, 0xee, 0x76, 0xb2, 0x38, 0x5c, 0x62}, - output256: []byte{0x1d, 0x1, 0xf3, 0x12, 0xe, 0xcf, 0xbd, 0xd2, 0x8d, 0xce, 0x44, 0x31, 0x76, 0x66, 0xcf, 0x86, 0x4f, 0x52, 0x39, 0x1b, 0x9e, 0xca, 0x38, 0x43, 0xdb, 0x45, 0x66, 0x7c, 0x2e, 0xa, 0x98, 0xad}, - output384: []byte{0x4, 0x1b, 0x7c, 0x89, 0xbd, 0x4b, 0x58, 0x2a, 0x7d, 0x20, 0xe5, 0x79, 0xc6, 0xfd, 0xb1, 0x8b, 0xa0, 0xc1, 0x25, 0x1d, 0xab, 0xac, 0xc6, 0x87, 0xaf, 0x44, 0x8e, 0xb4, 0x91, 0x51, 0xbb, 0xc0, 0x4a, 0xdc, 0xb8, 0x1d, 0x79, 0x7d, 0x4b, 0xc5, 0x1f, 0x3, 0xbf, 0xff, 0x23, 0xf, 0xfc, 0xc6}, - output512: []byte{0xaf, 0x69, 0xa4, 0x65, 0x27, 0xc1, 0x71, 0x17, 0xe6, 0xdf, 0xf3, 0x2c, 0xba, 0x28, 0x9e, 0xdd, 0xd1, 0xee, 0xcd, 0xa1, 0x3e, 0x53, 0x13, 0xe4, 0x66, 0x78, 0xeb, 0x80, 0x6, 0xe7, 0x63, 0x98, 0x54, 0xc3, 0x97, 0xd, 0xfe, 0xb4, 0xd9, 0x7, 0xdb, 0x11, 0x51, 0xc1, 0xc5, 0xee, 0x25, 0xca, 0x6f, 0x19, 0x5b, 0x9, 0xca, 0x5a, 0x5c, 0xc9, 0x7a, 0x4d, 0x64, 0xac, 0x4c, 0x75, 0x57, 0x8e}, - }, - { - msg: []byte{0xe2, 0x61, 0x93, 0x98, 0x9d, 0x6, 0x56, 0x8f, 0xe6, 0x88, 0xe7, 0x55, 0x40, 0xae, 0xa0, 0x67, 0x47, 0xd9, 0xf8, 0x51}, - output224: []byte{0xa5, 0x89, 0x93, 0x63, 0x70, 0xa3, 0xd2, 0x0, 0x39, 0xc4, 0x69, 0xd4, 0x4a, 0x1c, 0x26, 0xe6, 0x28, 0x23, 0xab, 0x28, 0xcc, 0x50, 0x17, 0x5a, 0x98, 0x97, 0xf9, 0x8e}, - output256: []byte{0x2c, 0x1e, 0x61, 0xe5, 0xd4, 0x52, 0x3, 0xf2, 0x7b, 0x86, 0xf1, 0x29, 0x3a, 0x80, 0xba, 0xb3, 0x41, 0x92, 0xda, 0xf4, 0x2b, 0x86, 0x23, 0xb1, 0x20, 0x5, 0xb2, 0xfb, 0x1c, 0x18, 0xac, 0xb1}, - output384: []byte{0xea, 0xf7, 0x51, 0xee, 0x6e, 0x75, 0xaa, 0x2c, 0x56, 0x45, 0x3f, 0x31, 0x6c, 0x1, 0x9b, 0xda, 0x7d, 0x7a, 0xe1, 0xfd, 0xa0, 0x3b, 0x79, 0xac, 0x41, 0x3b, 0xb1, 0xf2, 0x84, 0xd, 0x58, 0xaa, 0xaa, 0xc7, 0x7f, 0x2d, 0xc1, 0x6, 0xd2, 0x2f, 0x1a, 0x71, 0x15, 0x7f, 0x9f, 0x84, 0x1c, 0x4b}, - output512: []byte{0x19, 0x1c, 0xef, 0x1c, 0x6a, 0xa0, 0x9, 0xb1, 0xab, 0xa6, 0x74, 0xbe, 0x2b, 0x3f, 0xd, 0xa4, 0x18, 0xfd, 0xf9, 0xe6, 0xa7, 0xec, 0xf2, 0xbe, 0x42, 0xac, 0x14, 0xf7, 0xd6, 0xe0, 0x73, 0x31, 0x42, 0x51, 0x33, 0xa8, 0x3b, 0x4e, 0x1, 0x61, 0xcc, 0x7d, 0xeb, 0xf9, 0xdc, 0xd7, 0xfe, 0x37, 0x87, 0xdc, 0xb6, 0x62, 0x2a, 0x38, 0x47, 0x51, 0x89, 0xed, 0xfe, 0x1d, 0xe6, 0xb0, 0x53, 0xd6}, - }, - { - msg: []byte{0xd8, 0xdc, 0x8f, 0xde, 0xfb, 0xdc, 0xe9, 0xd4, 0x4e, 0x4c, 0xba, 0xfe, 0x78, 0x44, 0x7b, 0xae, 0x3b, 0x54, 0x36, 0x10, 0x2a}, - output224: []byte{0x96, 0xf4, 0x34, 0x1, 0xad, 0x49, 0xc5, 0x8d, 0x88, 0x70, 0x20, 0xf3, 0x95, 0xbd, 0xd0, 0x1f, 0x6d, 0xad, 0x4, 0x12, 0x8a, 0x85, 0xb1, 0x77, 0x80, 0x40, 0x8c, 0x37}, - output256: []byte{0xad, 0xe, 0x3f, 0x29, 0x76, 0x70, 0x67, 0xe9, 0x29, 0xd1, 0xce, 0xcd, 0x95, 0x58, 0x2d, 0xf8, 0xf2, 0xa9, 0xbe, 0xb9, 0x2e, 0xaa, 0x27, 0xee, 0xb3, 0x15, 0xf6, 0x20, 0x36, 0x5a, 0x92, 0x44}, - output384: []byte{0x16, 0xc4, 0xa7, 0xf7, 0xe8, 0xba, 0x7e, 0xa1, 0x3c, 0x59, 0x57, 0x6b, 0xe6, 0x2, 0xf8, 0x85, 0xe2, 0x1b, 0xe7, 0xc3, 0x4b, 0x3a, 0xc0, 0x5c, 0xac, 0x42, 0x62, 0xba, 0xad, 0x8a, 0xa3, 0xf9, 0x5b, 0xd9, 0x26, 0xf, 0x13, 0xf0, 0x85, 0x50, 0xce, 0x33, 0x1e, 0xc7, 0x73, 0xba, 0x75, 0x8c}, - output512: []byte{0xa6, 0xd, 0x75, 0x87, 0x42, 0x4b, 0x72, 0x42, 0xd9, 0x3b, 0xcc, 0xe5, 0x15, 0xf1, 0xc7, 0x5a, 0xe2, 0xbe, 0x77, 0x10, 0xf7, 0x2e, 0xd3, 0xf4, 0xe5, 0xea, 0x8b, 0xc2, 0xba, 0x8d, 0x64, 0x9, 0x9f, 0xe4, 0x2b, 0x88, 0xa2, 0x95, 0xe1, 0x2f, 0xda, 0xfa, 0xb4, 0x41, 0xd7, 0x72, 0xc4, 0xa9, 0xa7, 0xd7, 0x94, 0xb2, 0x77, 0x88, 0xed, 0xea, 0x27, 0x15, 0x71, 0xa0, 0x43, 0x5, 0xf2, 0x53}, - }, - { - msg: []byte{0x57, 0x8, 0x5f, 0xd7, 0xe1, 0x42, 0x16, 0xab, 0x10, 0x2d, 0x83, 0x17, 0xb0, 0xcb, 0x33, 0x8a, 0x78, 0x6d, 0x5f, 0xc3, 0x2d, 0x8f}, - output224: []byte{0xa3, 0xa0, 0xf0, 0xc5, 0x52, 0xe7, 0xcd, 0x27, 0x23, 0xfe, 0x22, 0xe1, 0xd5, 0x71, 0x9e, 0x21, 0x3d, 0x9a, 0x3d, 0xa1, 0xdb, 0x99, 0xe3, 0x2e, 0xff, 0xfd, 0xf, 0x46}, - output256: []byte{0x2b, 0x4e, 0xb5, 0xde, 0x20, 0xe8, 0x60, 0x74, 0xca, 0xbb, 0x55, 0xbf, 0xa6, 0x3a, 0x5c, 0x8c, 0x6a, 0xe1, 0x56, 0x79, 0x30, 0x20, 0x61, 0x84, 0x5b, 0x9c, 0xf2, 0x33, 0xe1, 0x7c, 0x90, 0x6b}, - output384: []byte{0x51, 0x19, 0xa4, 0xfc, 0x11, 0xda, 0xf2, 0xef, 0x5d, 0xeb, 0x7a, 0xeb, 0x35, 0x54, 0x91, 0x62, 0xd9, 0xaf, 0xc8, 0x27, 0x39, 0x2a, 0x88, 0x68, 0xe7, 0xf8, 0x59, 0x4a, 0x5c, 0x19, 0x4d, 0x9c, 0x8f, 0x6a, 0x43, 0xc, 0xb3, 0x86, 0xb8, 0xd8, 0x25, 0xcc, 0x6d, 0xab, 0x4e, 0xdb, 0x74, 0x2a}, - output512: []byte{0x9, 0xfc, 0xad, 0x97, 0xea, 0x3c, 0xb6, 0xb7, 0xfc, 0x61, 0x58, 0xd, 0xe0, 0x96, 0x8d, 0x23, 0x80, 0x6, 0xb7, 0xe7, 0x1f, 0xb, 0xd5, 0x8a, 0xba, 0x2a, 0xa9, 0xd4, 0xad, 0xb8, 0x55, 0xd7, 0x60, 0x6e, 0x76, 0x32, 0x13, 0x8c, 0xcc, 0xa, 0xa0, 0x65, 0xca, 0xb, 0x92, 0x42, 0x22, 0x62, 0xe0, 0x29, 0xda, 0x17, 0xd7, 0x3c, 0xd3, 0x1, 0x1f, 0xf2, 0x85, 0x70, 0x6c, 0x7f, 0xc1, 0xae}, - }, - { - msg: []byte{0xa0, 0x54, 0x4, 0xdf, 0x5d, 0xbb, 0x57, 0x69, 0x7e, 0x2c, 0x16, 0xfa, 0x29, 0xde, 0xfa, 0xc8, 0xab, 0x35, 0x60, 0xd6, 0x12, 0x6f, 0xa0}, - output224: []byte{0xe9, 0x91, 0xf4, 0xa1, 0x4b, 0x56, 0xdc, 0x6b, 0x22, 0x4e, 0xf3, 0x52, 0xae, 0x8b, 0xc8, 0xca, 0xe8, 0xb1, 0xaf, 0x1c, 0x25, 0xc6, 0x73, 0x3d, 0xfb, 0x7f, 0xfe, 0x1f}, - output256: []byte{0x6a, 0xe0, 0x4c, 0x6c, 0x6f, 0x36, 0x51, 0xf1, 0xf6, 0x4c, 0xa, 0xd6, 0x97, 0x33, 0x99, 0xb, 0x41, 0x74, 0x7c, 0x93, 0xf8, 0x7a, 0xcb, 0x81, 0x3b, 0xb2, 0x5b, 0xb1, 0xfc, 0xe, 0xff, 0x7}, - output384: []byte{0xa9, 0x1f, 0x1, 0x70, 0x45, 0x7e, 0x78, 0xb3, 0xbb, 0x15, 0xb0, 0xbd, 0xc0, 0xff, 0x4e, 0xfe, 0x8d, 0x73, 0x13, 0xd2, 0x72, 0x5d, 0x8e, 0x8d, 0xb8, 0x75, 0xbc, 0xaf, 0xbc, 0x11, 0x31, 0x41, 0x26, 0x55, 0x9f, 0x45, 0xe8, 0x6e, 0x78, 0x13, 0x6e, 0xb2, 0x14, 0xff, 0x2, 0x76, 0x4c, 0xab}, - output512: []byte{0xf6, 0x1f, 0xaa, 0xb0, 0x80, 0xcf, 0x9a, 0x5f, 0x75, 0x40, 0x7b, 0x8, 0x1a, 0x3, 0xde, 0xf4, 0xf4, 0x9a, 0x60, 0x1a, 0x2b, 0xb8, 0x32, 0xe8, 0xc6, 0x40, 0x1b, 0xe0, 0xc9, 0x8b, 0x3c, 0xeb, 0x3f, 0x75, 0xc9, 0x22, 0xa9, 0x1b, 0xd5, 0x6, 0xb, 0x32, 0x17, 0xf7, 0x37, 0x40, 0x4e, 0xf4, 0x61, 0x2b, 0x9a, 0x0, 0x9b, 0x69, 0xca, 0x64, 0x8b, 0x1e, 0x37, 0xb2, 0xed, 0x49, 0x22, 0x9d}, - }, - { - msg: []byte{0xae, 0xcb, 0xb0, 0x27, 0x59, 0xf7, 0x43, 0x3d, 0x6f, 0xcb, 0x6, 0x96, 0x3c, 0x74, 0x6, 0x1c, 0xd8, 0x3b, 0x5b, 0x3f, 0xfa, 0x6f, 0x13, 0xc6}, - output224: []byte{0x71, 0x88, 0x66, 0xc2, 0x1c, 0xbe, 0x3f, 0x29, 0x13, 0x64, 0xc0, 0x7b, 0x36, 0x7, 0x8a, 0x6b, 0xf0, 0xb8, 0x25, 0x8b, 0xe, 0xc1, 0x55, 0xe2, 0xe2, 0xb1, 0xaf, 0x23}, - output256: []byte{0x40, 0xf9, 0xf5, 0x5b, 0xc5, 0x5d, 0xa4, 0x66, 0xbc, 0x3d, 0xc1, 0xf8, 0x98, 0x35, 0xa6, 0x40, 0x94, 0x57, 0x2d, 0xe7, 0x3d, 0x64, 0xed, 0x66, 0x46, 0xa1, 0xd3, 0xb6, 0x67, 0xbe, 0x70, 0xa9}, - output384: []byte{0x98, 0xfe, 0x81, 0x74, 0x6c, 0xcf, 0x7c, 0xfe, 0x55, 0x71, 0xd6, 0xd8, 0xb0, 0x99, 0x43, 0xec, 0xae, 0x44, 0xf6, 0x6, 0x44, 0x4f, 0x9d, 0xab, 0xf1, 0xa5, 0x7f, 0xe4, 0xe8, 0x71, 0xf6, 0x96, 0x22, 0x66, 0xd1, 0x86, 0x52, 0xfd, 0x4e, 0xeb, 0xdb, 0xe4, 0x92, 0xcf, 0xc5, 0xb2, 0xb2, 0x1f}, - output512: []byte{0x51, 0xde, 0xa, 0x62, 0x2f, 0xc6, 0xfc, 0x70, 0x2c, 0x7c, 0x2d, 0xb5, 0xcc, 0xb0, 0x5c, 0xa0, 0xdd, 0xf7, 0x92, 0x98, 0x6e, 0x44, 0xb4, 0xd3, 0x36, 0xa7, 0xa5, 0xda, 0xf1, 0x9a, 0x20, 0xa3, 0x71, 0xd9, 0xbf, 0x7d, 0xde, 0x82, 0x2e, 0xcd, 0xd0, 0xa4, 0xce, 0x28, 0xe4, 0xa0, 0xb4, 0x6f, 0xe5, 0x1a, 0x2a, 0xab, 0xef, 0xa7, 0x86, 0x58, 0x7, 0xef, 0x3d, 0x3b, 0x18, 0x87, 0xf1, 0x4d}, - }, - { - msg: []byte{0xaa, 0xfd, 0xc9, 0x24, 0x3d, 0x3d, 0x4a, 0x9, 0x65, 0x58, 0xa3, 0x60, 0xcc, 0x27, 0xc8, 0xd8, 0x62, 0xf0, 0xbe, 0x73, 0xdb, 0x5e, 0x88, 0xaa, 0x55}, - output224: []byte{0x23, 0x60, 0x6d, 0x6, 0xfd, 0x8f, 0x87, 0xc2, 0x20, 0x5a, 0xbb, 0x5f, 0xd0, 0x4c, 0x33, 0xeb, 0xa3, 0x5, 0x9, 0x95, 0x52, 0x0, 0x56, 0x6a, 0xf, 0x77, 0x2b, 0x49}, - output256: []byte{0xc6, 0x4b, 0xec, 0xf7, 0xb7, 0x5f, 0xc8, 0x85, 0xd5, 0x85, 0x39, 0x24, 0xf2, 0xb7, 0xd3, 0x7a, 0xbc, 0xef, 0xd3, 0xda, 0x12, 0x6b, 0xb8, 0x17, 0x69, 0x7e, 0x1a, 0x9, 0x15, 0x2b, 0x1e, 0xbe}, - output384: []byte{0x3d, 0xd9, 0x5, 0x4c, 0x10, 0x5c, 0x40, 0x79, 0x8d, 0xf4, 0x5c, 0xfb, 0x58, 0x80, 0xf9, 0x7a, 0x95, 0x36, 0xfa, 0x7b, 0xd1, 0x3f, 0x1d, 0x81, 0x6b, 0x8e, 0xe8, 0x87, 0xfc, 0xba, 0xfc, 0x10, 0x2a, 0x7d, 0x4b, 0xde, 0x9f, 0xe6, 0xe2, 0x65, 0x53, 0x8e, 0xec, 0x25, 0x25, 0xb5, 0xd, 0x89}, - output512: []byte{0x62, 0x86, 0xc3, 0xdb, 0x87, 0xd3, 0xb4, 0x5c, 0xfd, 0x4d, 0xe8, 0x5a, 0x7a, 0xdd, 0x18, 0xe0, 0x7a, 0xe2, 0x2f, 0x1f, 0xf, 0x46, 0x75, 0xe1, 0xd4, 0xe1, 0xfc, 0x77, 0x63, 0x37, 0x34, 0xd7, 0x96, 0x28, 0x18, 0xa9, 0xf3, 0xb9, 0x6b, 0x37, 0xfe, 0x77, 0x4f, 0xc2, 0x6d, 0xea, 0x78, 0x74, 0x85, 0x31, 0x7b, 0x96, 0x22, 0x27, 0x5f, 0x63, 0xa7, 0xdd, 0x6d, 0x62, 0xd6, 0x50, 0xd3, 0x7}, - }, - { - msg: []byte{0x7b, 0xc8, 0x48, 0x67, 0xf6, 0xf9, 0xe9, 0xfd, 0xc3, 0xe1, 0x4, 0x6c, 0xae, 0x3a, 0x52, 0xc7, 0x7e, 0xd4, 0x85, 0x86, 0xe, 0xe2, 0x60, 0xe3, 0xb, 0x15}, - output224: []byte{0x5, 0x93, 0x5f, 0xa, 0xd2, 0x26, 0x44, 0x75, 0xdf, 0x34, 0xfa, 0x96, 0xf6, 0xa9, 0x11, 0x8c, 0x32, 0xb2, 0x17, 0xe8, 0x61, 0x69, 0xeb, 0x7a, 0xde, 0x4e, 0x2f, 0xdb}, - output256: []byte{0x57, 0xd4, 0x6a, 0x6b, 0xc8, 0xfa, 0xb3, 0x36, 0x1, 0x53, 0x8d, 0xad, 0x27, 0xf9, 0x8c, 0x66, 0x44, 0x30, 0x32, 0xcc, 0x39, 0x12, 0x43, 0x4c, 0x28, 0xeb, 0x88, 0xd0, 0xaf, 0x44, 0xc5, 0x2c}, - output384: []byte{0xde, 0xcd, 0x77, 0x8b, 0x89, 0xb4, 0x29, 0x50, 0x72, 0xdb, 0xf9, 0x86, 0x89, 0xe2, 0xeb, 0x60, 0x66, 0xe4, 0x6, 0x35, 0x6e, 0xa4, 0xb7, 0xca, 0xd5, 0x50, 0x1, 0x9f, 0x4a, 0x2a, 0xbb, 0x25, 0x16, 0x3e, 0x95, 0x71, 0xd0, 0xad, 0xb9, 0xad, 0xc6, 0xa8, 0x2, 0xb7, 0xe0, 0x3c, 0x15, 0x2c}, - output512: []byte{0x81, 0x46, 0xc4, 0x3a, 0xf, 0xfe, 0x48, 0x18, 0x72, 0x14, 0x2f, 0x56, 0xa9, 0xce, 0xa4, 0x43, 0x32, 0xed, 0xc7, 0x6b, 0x4e, 0x99, 0xc2, 0xbd, 0xc3, 0x9d, 0x7f, 0x80, 0xb2, 0xa6, 0xb5, 0x54, 0xc7, 0x59, 0x8f, 0x9, 0x85, 0x5b, 0xf7, 0xab, 0xc5, 0xe6, 0xc0, 0x48, 0xbe, 0x76, 0xf5, 0xf3, 0x69, 0xeb, 0xb2, 0x88, 0x4e, 0x6e, 0x37, 0xf1, 0x86, 0xe8, 0x71, 0x9d, 0xf3, 0xd5, 0x23, 0xe4}, - }, - { - msg: []byte{0xfa, 0xc5, 0x23, 0x57, 0x5a, 0x99, 0xec, 0x48, 0x27, 0x9a, 0x7a, 0x45, 0x9e, 0x98, 0xff, 0x90, 0x19, 0x18, 0xa4, 0x75, 0x3, 0x43, 0x27, 0xef, 0xb5, 0x58, 0x43}, - output224: []byte{0xfb, 0xec, 0x83, 0xcb, 0xdb, 0x6d, 0x8, 0xc7, 0xbf, 0xdd, 0xc2, 0xe3, 0x7f, 0x73, 0xb1, 0x6d, 0xc9, 0x29, 0x26, 0xa5, 0xc2, 0x3d, 0xab, 0x41, 0xde, 0xeb, 0xfb, 0x1b}, - output256: []byte{0x7c, 0x95, 0x65, 0x3, 0xd5, 0xb4, 0xdb, 0xb7, 0x64, 0xff, 0x8e, 0x66, 0xfa, 0x74, 0xce, 0xf, 0x91, 0x32, 0xda, 0x90, 0xea, 0x35, 0x43, 0xf6, 0x69, 0xc9, 0xdd, 0x8, 0xe4, 0x13, 0xe3, 0x3c}, - output384: []byte{0x37, 0xf1, 0x4b, 0x31, 0x7d, 0x46, 0xbd, 0xb3, 0xe5, 0xdd, 0x6f, 0x68, 0x98, 0x6a, 0x8, 0xa0, 0x98, 0xc4, 0x6b, 0x9d, 0x85, 0xd1, 0xf2, 0x54, 0xa1, 0x78, 0x78, 0xc0, 0x8, 0xf9, 0x79, 0x26, 0xc8, 0xa1, 0x3c, 0x38, 0x38, 0x72, 0x1c, 0xfe, 0x3a, 0x58, 0x7, 0x6f, 0x39, 0x92, 0xf2, 0x6c}, - output512: []byte{0x4b, 0x86, 0xfb, 0xf9, 0xdf, 0xb6, 0x76, 0x7e, 0xb6, 0x60, 0xaf, 0x9c, 0x30, 0x98, 0x3e, 0xd6, 0x5b, 0x6f, 0xd0, 0x51, 0x24, 0x7a, 0xb5, 0x47, 0x67, 0xdf, 0xb4, 0x95, 0x30, 0xeb, 0x3c, 0x1, 0x1, 0x4e, 0xb2, 0x6d, 0xf6, 0x3e, 0x53, 0x6c, 0xf5, 0x5e, 0xb, 0xce, 0x2f, 0x62, 0x65, 0x4f, 0xb2, 0xfc, 0xe3, 0x83, 0x9b, 0x4b, 0xfd, 0x30, 0x15, 0x70, 0xb1, 0xab, 0x79, 0x4d, 0xf6, 0x7d}, - }, - { - msg: []byte{0xf, 0x8b, 0x2d, 0x8f, 0xcf, 0xd9, 0xd6, 0x8c, 0xff, 0xc1, 0x7c, 0xcf, 0xb1, 0x17, 0x70, 0x9b, 0x53, 0xd2, 0x64, 0x62, 0xa3, 0xf3, 0x46, 0xfb, 0x7c, 0x79, 0xb8, 0x5e}, - output224: []byte{0x1e, 0x69, 0x3b, 0xb, 0xce, 0x23, 0x72, 0x55, 0xd, 0xae, 0xf3, 0x5b, 0x14, 0xf1, 0x3a, 0xb4, 0x34, 0x41, 0xed, 0x67, 0x42, 0xde, 0xe3, 0xe8, 0x6f, 0xd1, 0xd8, 0xef}, - output256: []byte{0x6d, 0xe1, 0x64, 0xa9, 0x62, 0x6d, 0x5a, 0x4f, 0x54, 0xd8, 0x54, 0xac, 0x15, 0x89, 0x94, 0xf3, 0x5a, 0x8e, 0x36, 0x2e, 0xcc, 0x75, 0x3f, 0x55, 0x18, 0x27, 0x90, 0x93, 0x4a, 0x2e, 0xd, 0x6}, - output384: []byte{0x64, 0x1a, 0x7a, 0xf1, 0x3b, 0x88, 0x9d, 0x1a, 0xf, 0x1a, 0xa3, 0xe4, 0xe4, 0xff, 0x8c, 0xc5, 0x90, 0x3c, 0x47, 0xe1, 0xa5, 0x2b, 0xde, 0xa2, 0x57, 0xd8, 0xe, 0x37, 0xe5, 0x96, 0x56, 0x4a, 0xb3, 0x3e, 0xea, 0xd0, 0x67, 0x17, 0xcd, 0xb6, 0xb7, 0x6, 0xcb, 0x69, 0x86, 0x29, 0x3d, 0x4f}, - output512: []byte{0x21, 0x13, 0x2f, 0xc1, 0x1f, 0x60, 0x40, 0xad, 0x49, 0x3d, 0x62, 0x70, 0x27, 0xc7, 0x52, 0xce, 0x29, 0x81, 0x65, 0x89, 0xde, 0x7b, 0xe7, 0x85, 0x62, 0x91, 0x4b, 0x63, 0xd1, 0xa9, 0x21, 0x98, 0x3, 0xdd, 0xbd, 0x96, 0x73, 0xaa, 0x74, 0x9f, 0x37, 0xff, 0x4d, 0x6e, 0x1b, 0x5a, 0xe2, 0xa1, 0x26, 0x33, 0xba, 0x8b, 0xc, 0x99, 0x94, 0xe0, 0x31, 0xeb, 0xf6, 0xc4, 0x2e, 0x58, 0xa7, 0x93}, - }, - { - msg: []byte{0xa9, 0x63, 0xc3, 0xe8, 0x95, 0xff, 0x5a, 0xb, 0xe4, 0x82, 0x44, 0x0, 0x51, 0x8d, 0x81, 0x41, 0x2f, 0x87, 0x5f, 0xa5, 0x5, 0x21, 0xe2, 0x6e, 0x85, 0xea, 0xc9, 0xc, 0x4}, - output224: []byte{0x17, 0x81, 0xf1, 0x34, 0x4d, 0xc1, 0x7f, 0x67, 0x85, 0x71, 0xf4, 0xe5, 0xdf, 0x39, 0x98, 0xb1, 0xd3, 0x8b, 0x1d, 0x83, 0x60, 0x2b, 0x53, 0xb9, 0xb6, 0xf2, 0x83, 0xd6}, - output256: []byte{0xb7, 0x60, 0x31, 0x2b, 0xd1, 0xb2, 0x79, 0xfc, 0x67, 0x24, 0x79, 0xd2, 0x1c, 0x5e, 0xd3, 0x49, 0xe5, 0xfe, 0x96, 0xf0, 0x89, 0x40, 0x23, 0x7b, 0x45, 0x15, 0x45, 0x27, 0x21, 0xc4, 0x9a, 0x16}, - output384: []byte{0x12, 0x2b, 0x8b, 0x86, 0x10, 0x3f, 0xe3, 0xc1, 0x8f, 0xf2, 0x81, 0x78, 0xa2, 0x56, 0xac, 0xb0, 0xca, 0xb8, 0x51, 0x83, 0x38, 0xd2, 0xcb, 0xa6, 0x97, 0xe3, 0xf5, 0x60, 0xec, 0xfe, 0xe0, 0x9b, 0x2, 0x4b, 0x97, 0xd8, 0xd1, 0xf6, 0x96, 0x32, 0xad, 0x1f, 0x2c, 0x5f, 0x56, 0x28, 0xd3, 0xef}, - output512: []byte{0x8a, 0x53, 0x74, 0xd9, 0x2f, 0xf9, 0xa5, 0x8e, 0x4, 0x51, 0xe6, 0x9, 0xaa, 0x5c, 0xc, 0x5c, 0x17, 0x2b, 0xb2, 0x6, 0x8c, 0x80, 0x56, 0x2d, 0x3, 0x24, 0xf9, 0xcb, 0x6a, 0x3, 0x74, 0x36, 0x91, 0xc, 0x65, 0x93, 0xf9, 0x50, 0xc4, 0x43, 0x74, 0xb4, 0xe5, 0xbf, 0x6f, 0x6d, 0x3a, 0x43, 0x6e, 0xce, 0x6d, 0xaa, 0xeb, 0x56, 0xd1, 0x47, 0xd8, 0xcd, 0x83, 0x9c, 0xca, 0x35, 0xea, 0xc3}, - }, - { - msg: []byte{0x3, 0xa1, 0x86, 0x88, 0xb1, 0xc, 0xc0, 0xed, 0xf8, 0x3a, 0xdf, 0xa, 0x84, 0x80, 0x8a, 0x97, 0x18, 0x38, 0x3c, 0x40, 0x70, 0xc6, 0xc4, 0xf2, 0x95, 0x9, 0x86, 0x99, 0xac, 0x2c}, - output224: []byte{0x3, 0xb7, 0x4b, 0x7d, 0x8f, 0xc1, 0xf2, 0x3f, 0x76, 0xba, 0xb2, 0xb6, 0xc3, 0x5f, 0x29, 0x2c, 0x15, 0x50, 0x6d, 0xe6, 0x49, 0x78, 0xfc, 0xf6, 0xd9, 0x97, 0x3f, 0xce}, - output256: []byte{0x94, 0xfc, 0x25, 0x5d, 0xe4, 0xef, 0x19, 0xc0, 0xda, 0x4b, 0x9, 0xb2, 0xe2, 0xfa, 0xc2, 0x1f, 0x20, 0x4, 0x8b, 0x46, 0xf1, 0x7c, 0x30, 0x68, 0x5a, 0xbe, 0x40, 0xd5, 0xc7, 0x43, 0xf3, 0x75}, - output384: []byte{0xf3, 0x5a, 0x29, 0x2e, 0x19, 0x70, 0x7, 0xe2, 0x8c, 0xe6, 0x52, 0xa0, 0x67, 0x17, 0x3f, 0x36, 0x59, 0xc5, 0x1b, 0x70, 0x43, 0x8a, 0xa9, 0xe4, 0x33, 0x8, 0x1d, 0x3d, 0xf7, 0x1b, 0x4a, 0x11, 0xe3, 0xf3, 0xbe, 0x5a, 0xf3, 0x2e, 0x2c, 0x8, 0xd2, 0x3a, 0xb, 0x44, 0xe3, 0xb, 0xb, 0xdf}, - output512: []byte{0x71, 0x2, 0x5d, 0x8, 0x9a, 0x39, 0xd2, 0x73, 0x27, 0xc4, 0x6c, 0x27, 0xbd, 0x4e, 0x75, 0x65, 0xdd, 0xbf, 0x9c, 0x28, 0x6f, 0x18, 0x5a, 0x8, 0x17, 0x86, 0x1, 0xc3, 0xba, 0xb4, 0x66, 0x7f, 0x36, 0x8a, 0x3a, 0x8b, 0xdd, 0xac, 0xf2, 0x5b, 0x2b, 0xa, 0xa5, 0xc9, 0xe0, 0xcd, 0x6c, 0x87, 0xdc, 0x32, 0xc8, 0x54, 0x2, 0x7a, 0x89, 0x54, 0xb5, 0xc6, 0xaf, 0xd3, 0xa8, 0x50, 0x97, 0xac}, - }, - { - msg: []byte{0x84, 0xfb, 0x51, 0xb5, 0x17, 0xdf, 0x6c, 0x5a, 0xcc, 0xb5, 0xd0, 0x22, 0xf8, 0xf2, 0x8d, 0xa0, 0x9b, 0x10, 0x23, 0x2d, 0x42, 0x32, 0xf, 0xfc, 0x32, 0xdb, 0xec, 0xc3, 0x83, 0x5b, 0x29}, - output224: []byte{0x6a, 0x68, 0x57, 0xfb, 0xa9, 0x3, 0xb9, 0xda, 0x27, 0x53, 0x69, 0xc, 0x39, 0xc5, 0x48, 0xbe, 0x0, 0x8e, 0x22, 0xeb, 0xb3, 0x72, 0xee, 0xaa, 0x16, 0xc8, 0x59, 0x18}, - output256: []byte{0x39, 0xa4, 0xa0, 0xff, 0xc4, 0x60, 0x36, 0x98, 0xae, 0xa, 0x4f, 0x3d, 0x24, 0xb1, 0xbc, 0x42, 0xac, 0x7a, 0x2d, 0x7d, 0x92, 0x3e, 0x7a, 0x5d, 0x60, 0x24, 0x53, 0xe8, 0x2d, 0x53, 0x23, 0xc5}, - output384: []byte{0x2e, 0xa5, 0x96, 0xb4, 0x46, 0xd5, 0xcc, 0xd8, 0xf0, 0x92, 0x7a, 0x2e, 0x37, 0x90, 0x91, 0x1e, 0x0, 0xf1, 0xf5, 0x2c, 0xfb, 0xfc, 0x41, 0xf1, 0x22, 0x90, 0xcb, 0xac, 0xd1, 0xc9, 0x3, 0xc7, 0x4d, 0xee, 0xf8, 0x40, 0xfd, 0x13, 0x98, 0xe1, 0x2e, 0xe8, 0x63, 0xac, 0xd9, 0x2b, 0xae, 0xbf}, - output512: []byte{0xdc, 0x29, 0xeb, 0x71, 0x30, 0x81, 0x2a, 0x65, 0x2a, 0xf3, 0xff, 0x9b, 0x77, 0x62, 0x96, 0x84, 0x63, 0x45, 0x2, 0xea, 0x66, 0x67, 0xe7, 0xe9, 0xf8, 0x0, 0x90, 0xec, 0x2a, 0x9d, 0x69, 0xc, 0x8c, 0x9a, 0x78, 0x64, 0x5f, 0xb0, 0x4d, 0x9c, 0xd2, 0x69, 0xe7, 0x6, 0xee, 0x2c, 0x96, 0xe7, 0x42, 0x7, 0xfb, 0xbd, 0xa5, 0x59, 0xdc, 0x28, 0x5c, 0x9b, 0xc5, 0x2f, 0x15, 0xa2, 0x56, 0xca}, - }, - { - msg: []byte{0x9f, 0x2f, 0xcc, 0x7c, 0x90, 0xde, 0x9, 0xd, 0x6b, 0x87, 0xcd, 0x7e, 0x97, 0x18, 0xc1, 0xea, 0x6c, 0xb2, 0x11, 0x18, 0xfc, 0x2d, 0x5d, 0xe9, 0xf9, 0x7e, 0x5d, 0xb6, 0xac, 0x1e, 0x9c, 0x10}, - output224: []byte{0x88, 0x79, 0x21, 0x84, 0x8a, 0xd9, 0x84, 0x58, 0xf3, 0xdb, 0x3e, 0xe, 0xcd, 0x5a, 0xd5, 0xdb, 0x1f, 0xb, 0xf9, 0xf2, 0xd0, 0xca, 0x8, 0x60, 0x10, 0x74, 0xd5, 0x97}, - output256: []byte{0x2f, 0x1a, 0x5f, 0x71, 0x59, 0xe3, 0x4e, 0xa1, 0x9c, 0xdd, 0xc7, 0xe, 0xbf, 0x9b, 0x81, 0xf1, 0xa6, 0x6d, 0xb4, 0x6, 0x15, 0xd7, 0xea, 0xd3, 0xcc, 0x1f, 0x1b, 0x95, 0x4d, 0x82, 0xa3, 0xaf}, - output384: []byte{0xba, 0xae, 0x7a, 0xae, 0xd4, 0xfb, 0xf4, 0x2f, 0x93, 0x16, 0xc7, 0xe8, 0xf7, 0x22, 0xee, 0xb0, 0x6a, 0x59, 0x8b, 0x50, 0x9f, 0x18, 0x4b, 0x22, 0xfb, 0xd5, 0xa8, 0x1c, 0x93, 0xd9, 0x5f, 0xff, 0x71, 0x1f, 0x5d, 0xe9, 0x8, 0x47, 0xb3, 0x24, 0x8b, 0x6d, 0xf7, 0x6c, 0xab, 0xce, 0x7, 0xee}, - output512: []byte{0xb0, 0x87, 0xc9, 0x4, 0x21, 0xae, 0xbf, 0x87, 0x91, 0x16, 0x47, 0xde, 0x9d, 0x46, 0x5c, 0xbd, 0xa1, 0x66, 0xb6, 0x72, 0xec, 0x47, 0xcc, 0xd4, 0x5, 0x4a, 0x71, 0x35, 0xa1, 0xef, 0x88, 0x5e, 0x79, 0x3, 0xb5, 0x2c, 0x3f, 0x2c, 0x3f, 0xe7, 0x22, 0xb1, 0xc1, 0x69, 0x29, 0x7a, 0x91, 0xb8, 0x24, 0x28, 0x95, 0x6a, 0x2, 0xc6, 0x31, 0xa2, 0x24, 0xf, 0x12, 0x16, 0x2c, 0x7b, 0xc7, 0x26}, - }, - { - msg: []byte{0xde, 0x8f, 0x1b, 0x3f, 0xaa, 0x4b, 0x70, 0x40, 0xed, 0x45, 0x63, 0xc3, 0xb8, 0xe5, 0x98, 0x25, 0x31, 0x78, 0xe8, 0x7e, 0x4d, 0xd, 0xf7, 0x5e, 0x4f, 0xf2, 0xf2, 0xde, 0xdd, 0x5a, 0xb, 0xe0, 0x46}, - output224: []byte{0xe0, 0x57, 0x3a, 0xd7, 0x6, 0xb4, 0x4d, 0x8c, 0x4d, 0x20, 0x4f, 0x88, 0x4b, 0x95, 0xab, 0x18, 0x91, 0x3e, 0x76, 0xf4, 0x1c, 0xf2, 0x9a, 0x16, 0xdb, 0xe3, 0x47, 0x94}, - output256: []byte{0x1c, 0x57, 0xfe, 0xe, 0x38, 0xcd, 0x3a, 0x12, 0x4e, 0xaa, 0x6c, 0xd8, 0x7f, 0x70, 0xa0, 0x79, 0xbc, 0xcc, 0x7, 0x3a, 0x34, 0x1e, 0x8c, 0xe, 0xb1, 0x97, 0x6f, 0xb3, 0xa3, 0xf7, 0xb7, 0x74}, - output384: []byte{0x32, 0xcf, 0xc8, 0xa1, 0x8a, 0x71, 0x16, 0xd4, 0xb9, 0x2, 0x90, 0x51, 0x94, 0x18, 0x8, 0xc3, 0xb3, 0x32, 0xef, 0xdb, 0x13, 0x2c, 0x51, 0x5f, 0x91, 0x10, 0xe1, 0x9b, 0x83, 0x54, 0x35, 0x5d, 0x94, 0x61, 0x6c, 0x99, 0x65, 0xbc, 0x2d, 0x1f, 0x24, 0x89, 0xf8, 0x45, 0x2a, 0xf7, 0xfb, 0x2f}, - output512: []byte{0xd2, 0xa9, 0x5c, 0x6f, 0xc0, 0xf3, 0x9c, 0x8f, 0x7a, 0x86, 0xc4, 0xdd, 0x62, 0x61, 0xa7, 0x9c, 0x94, 0xf, 0xcb, 0x31, 0x3b, 0xcf, 0xba, 0x9b, 0xf7, 0x15, 0x27, 0xf5, 0xbc, 0x70, 0xef, 0x82, 0x7c, 0xd9, 0x7d, 0xfa, 0x18, 0x28, 0xe, 0x5d, 0xde, 0xe5, 0xcc, 0xbc, 0x1d, 0x63, 0xce, 0x88, 0xce, 0x2b, 0xcd, 0xd8, 0x2d, 0xab, 0x61, 0xf, 0x79, 0x86, 0x7a, 0x7c, 0x20, 0xb1, 0x1e, 0x4f}, - }, - { - msg: []byte{0x62, 0xf1, 0x54, 0xec, 0x39, 0x4d, 0xb, 0xc7, 0x57, 0xd0, 0x45, 0xc7, 0x98, 0xc8, 0xb8, 0x7a, 0x0, 0xe0, 0x65, 0x5d, 0x4, 0x81, 0xa7, 0xd2, 0xd9, 0xfb, 0x58, 0xd9, 0x3a, 0xed, 0xc6, 0x76, 0xb5, 0xa0}, - output224: []byte{0xba, 0x31, 0x23, 0x30, 0x99, 0x5, 0x54, 0x83, 0xc9, 0x9f, 0x7a, 0xd8, 0x2d, 0xd, 0x24, 0xaf, 0x48, 0x7e, 0xd4, 0xb5, 0x3f, 0xff, 0x1a, 0x89, 0x2a, 0x55, 0xdd, 0xb3}, - output256: []byte{0xa9, 0x5, 0x60, 0x3b, 0x18, 0x6e, 0xf4, 0xf2, 0xd5, 0xb2, 0xd1, 0xbc, 0xfd, 0xa5, 0x4, 0xc6, 0x8e, 0xd5, 0xeb, 0x9b, 0xc, 0x7b, 0x7e, 0xa2, 0xa0, 0x1, 0x57, 0x5f, 0x5a, 0xa6, 0x9e, 0x68}, - output384: []byte{0x73, 0x44, 0x3e, 0xa3, 0x8a, 0x88, 0x1, 0x39, 0x5c, 0x4, 0x4e, 0x3c, 0xbe, 0xcd, 0x45, 0xdd, 0x62, 0xd6, 0xe3, 0x4, 0xc5, 0x44, 0xf, 0xa9, 0xfe, 0x96, 0x51, 0xa4, 0x38, 0xc0, 0x10, 0xa7, 0x67, 0x12, 0x75, 0x9b, 0xe2, 0x6, 0x81, 0xf1, 0x41, 0x66, 0x61, 0xe7, 0x46, 0xe5, 0xeb, 0x77}, - output512: []byte{0xaf, 0x8c, 0xf, 0xbd, 0x72, 0xb3, 0xf8, 0x7, 0xdb, 0x95, 0xc9, 0x23, 0x1b, 0xc4, 0xe9, 0x31, 0x53, 0xdc, 0x66, 0x8, 0xb2, 0x2f, 0x47, 0x7, 0x31, 0x6a, 0xab, 0x3d, 0x69, 0xaf, 0xe, 0x63, 0x29, 0x1b, 0x56, 0x9f, 0x11, 0x8b, 0x5c, 0x9e, 0x69, 0x3c, 0x5b, 0xac, 0x46, 0x30, 0xc4, 0xa9, 0x23, 0xa4, 0x74, 0x35, 0x81, 0x24, 0x6a, 0xd3, 0x44, 0x6d, 0xda, 0x4f, 0x90, 0x76, 0xfd, 0xdb}, - }, - { - msg: []byte{0xb2, 0xdc, 0xfe, 0x9f, 0xf1, 0x9e, 0x2b, 0x23, 0xce, 0x7d, 0xa2, 0xa4, 0x20, 0x7d, 0x3e, 0x5e, 0xc7, 0xc6, 0x11, 0x2a, 0x8a, 0x22, 0xae, 0xc9, 0x67, 0x5a, 0x88, 0x63, 0x78, 0xe1, 0x4e, 0x5b, 0xfb, 0xad, 0x4e}, - output224: []byte{0xbe, 0xfa, 0xa1, 0xcb, 0x47, 0xcf, 0x78, 0xdd, 0xd4, 0xe0, 0x96, 0xb8, 0x61, 0xbc, 0x34, 0xb, 0x77, 0x6f, 0x52, 0xe3, 0x51, 0xeb, 0xe3, 0x78, 0xad, 0xe3, 0x5, 0xba}, - output256: []byte{0xff, 0xfd, 0x39, 0xf7, 0xc4, 0x51, 0x78, 0x8e, 0xb0, 0x31, 0x6f, 0x42, 0x9e, 0xa0, 0xa7, 0xc0, 0xac, 0x80, 0x91, 0x65, 0x7a, 0xca, 0x28, 0xf1, 0x56, 0xe, 0xd5, 0x77, 0x5e, 0x8c, 0x4c, 0x12}, - output384: []byte{0x6e, 0x82, 0xf4, 0x60, 0x66, 0xf, 0x3d, 0x2c, 0xc3, 0x3a, 0xa5, 0x9a, 0x37, 0xf3, 0x25, 0xee, 0xd0, 0x13, 0x3f, 0xe2, 0x9a, 0x9c, 0xb4, 0x28, 0xa3, 0xc2, 0x25, 0x72, 0xb6, 0xbf, 0x6c, 0x5d, 0xa2, 0xd0, 0xd4, 0x64, 0x5c, 0x49, 0x13, 0x56, 0x53, 0xa0, 0x49, 0x79, 0x5d, 0x4e, 0x2a, 0xd0}, - output512: []byte{0xbf, 0xc7, 0xd9, 0x68, 0xd4, 0x53, 0x42, 0x6, 0x98, 0x7, 0xc5, 0xf1, 0xb9, 0x64, 0x25, 0xcf, 0xff, 0xe9, 0x9e, 0xd1, 0x36, 0xd4, 0x76, 0x65, 0xe9, 0x2, 0xe0, 0x26, 0xc1, 0x18, 0x70, 0x1b, 0xb7, 0xc3, 0xe7, 0xfd, 0x69, 0x17, 0x85, 0x11, 0x5c, 0xfd, 0xb2, 0xef, 0x23, 0x5a, 0x66, 0xbc, 0xc1, 0x38, 0x4a, 0x1d, 0x8, 0x8b, 0x8c, 0xca, 0x90, 0xd9, 0xd5, 0x60, 0x91, 0x35, 0x49, 0xde}, - }, - { - msg: []byte{0x47, 0xf5, 0x69, 0x7a, 0xc8, 0xc3, 0x14, 0x9, 0xc0, 0x86, 0x88, 0x27, 0x34, 0x7a, 0x61, 0x3a, 0x35, 0x62, 0x4, 0x1c, 0x63, 0x3c, 0xf1, 0xf1, 0xf8, 0x68, 0x65, 0xa5, 0x76, 0xe0, 0x28, 0x35, 0xed, 0x2c, 0x24, 0x92}, - output224: []byte{0xf1, 0xe7, 0xa1, 0xb2, 0x8e, 0xa4, 0xd6, 0xfb, 0x86, 0x57, 0xf, 0x66, 0x91, 0x1e, 0x32, 0x58, 0xc3, 0xf4, 0x9f, 0x89, 0x16, 0x54, 0xfb, 0xce, 0x9b, 0xc7, 0x9b, 0x8b}, - output256: []byte{0x6f, 0x55, 0xbe, 0xcd, 0x16, 0x8e, 0x9, 0x39, 0xba, 0x2f, 0xa0, 0x90, 0x25, 0x7b, 0x17, 0x27, 0xfc, 0x66, 0x49, 0x1a, 0x44, 0x49, 0x32, 0x79, 0xa5, 0xbe, 0xac, 0xb9, 0xe3, 0x43, 0x53, 0x24}, - output384: []byte{0x22, 0x91, 0x60, 0xa6, 0x1c, 0xf2, 0x84, 0x2b, 0x37, 0xea, 0x85, 0x78, 0x8b, 0xb1, 0xce, 0x82, 0x94, 0xde, 0xd9, 0xea, 0xd2, 0x66, 0x35, 0x9d, 0x61, 0xdf, 0x3d, 0x6d, 0xf9, 0x8e, 0xe1, 0x55, 0xed, 0x3, 0xab, 0x1a, 0x51, 0xd6, 0x29, 0x1b, 0x41, 0x68, 0xa, 0x0, 0x55, 0x32, 0x98, 0xeb}, - output512: []byte{0x9a, 0x34, 0x85, 0x40, 0xab, 0x66, 0x9c, 0xdd, 0x89, 0x14, 0x42, 0x6f, 0xbb, 0xad, 0x19, 0x2b, 0xa0, 0xdb, 0x16, 0x58, 0x3e, 0x8d, 0x4e, 0x86, 0x7b, 0x66, 0xcc, 0x78, 0xc6, 0x49, 0x6e, 0x4d, 0x83, 0xdd, 0xbf, 0x7b, 0x97, 0x2b, 0x6, 0x68, 0xdf, 0x79, 0x3, 0xb0, 0xfe, 0x9a, 0xb8, 0x2b, 0x65, 0x15, 0x3f, 0x94, 0x7c, 0xf2, 0xaf, 0x25, 0x91, 0x12, 0x1c, 0x9d, 0x1a, 0x78, 0xe5, 0x15}, - }, - { - msg: []byte{0x51, 0x2a, 0x6d, 0x29, 0x2e, 0x67, 0xec, 0xb2, 0xfe, 0x48, 0x6b, 0xfe, 0x92, 0x66, 0x9, 0x53, 0xa7, 0x54, 0x84, 0xff, 0x4c, 0x4f, 0x2e, 0xca, 0x2b, 0xa, 0xf0, 0xed, 0xcd, 0xd4, 0x33, 0x9c, 0x6b, 0x2e, 0xe4, 0xe5, 0x42}, - output224: []byte{0xc2, 0xb3, 0x17, 0x46, 0x44, 0x69, 0x34, 0xfe, 0x29, 0xe8, 0x4c, 0xfb, 0x5c, 0x25, 0xb0, 0x3b, 0xe3, 0x3e, 0x90, 0x4, 0xf7, 0x4e, 0x91, 0xc1, 0xaf, 0xd, 0xb7, 0x89}, - output256: []byte{0x84, 0x64, 0x9b, 0xff, 0xcd, 0x48, 0x52, 0x7b, 0x92, 0x88, 0xe8, 0xda, 0x5f, 0x52, 0xfb, 0xab, 0x26, 0x4, 0xdc, 0x5a, 0x91, 0xc4, 0xb0, 0xb8, 0x7d, 0x47, 0x7d, 0xbd, 0x7b, 0x40, 0xb6, 0xae}, - output384: []byte{0xf5, 0xd8, 0x38, 0xde, 0xdf, 0x7, 0xac, 0x3a, 0x56, 0x46, 0x22, 0x1a, 0xdc, 0x6c, 0xa5, 0x90, 0x45, 0x97, 0x6d, 0xf9, 0xc3, 0x33, 0x67, 0xfd, 0xaa, 0xb, 0xe3, 0xaf, 0xc5, 0x7e, 0xef, 0xd, 0x43, 0x4e, 0xe9, 0x2c, 0xd6, 0x18, 0xb3, 0xfa, 0x26, 0xc7, 0xea, 0xbd, 0x18, 0xd7, 0x87, 0x72}, - output512: []byte{0xff, 0xdb, 0x64, 0x9d, 0x1a, 0xa7, 0xff, 0x26, 0x9b, 0x9b, 0xb0, 0xae, 0x61, 0x92, 0xf7, 0xbc, 0xbc, 0x6, 0x61, 0x25, 0x28, 0xdf, 0xe, 0x68, 0x52, 0x1d, 0x5c, 0x89, 0x1e, 0x9b, 0xba, 0x12, 0x92, 0x71, 0xa0, 0x7d, 0xc5, 0x63, 0x93, 0xbb, 0x21, 0x21, 0x8f, 0x5e, 0x2f, 0xb9, 0x2c, 0xff, 0xf8, 0x33, 0x43, 0x20, 0x66, 0xaa, 0x63, 0x80, 0xf3, 0x55, 0x7a, 0x7, 0x48, 0xe6, 0x5b, 0x33}, - }, - { - msg: []byte{0x97, 0x3c, 0xf2, 0xb4, 0xdc, 0xf0, 0xbf, 0xa8, 0x72, 0xb4, 0x11, 0x94, 0xcb, 0x5, 0xbb, 0x4e, 0x16, 0x76, 0xa, 0x18, 0x40, 0xd8, 0x34, 0x33, 0x1, 0x80, 0x25, 0x76, 0x19, 0x7e, 0xc1, 0x9e, 0x2a, 0x14, 0x93, 0xd8, 0xf4, 0xfb}, - output224: []byte{0x3a, 0x80, 0x64, 0x5f, 0xe4, 0x27, 0x13, 0x46, 0xaa, 0xed, 0xc3, 0xae, 0x50, 0x11, 0xb7, 0x5d, 0xf1, 0x63, 0xfa, 0xd3, 0xee, 0x61, 0x28, 0xd8, 0x7f, 0x3d, 0x9d, 0xa3}, - output256: []byte{0xd4, 0x5, 0x5b, 0x4e, 0x3e, 0x2a, 0xea, 0x1c, 0x67, 0xcc, 0x99, 0xfd, 0x40, 0x9d, 0x57, 0x4e, 0x53, 0xe1, 0xe2, 0x96, 0xcf, 0x9e, 0xef, 0x73, 0xc4, 0x72, 0xab, 0x92, 0xa6, 0xcb, 0x66, 0x9}, - output384: []byte{0xd4, 0x1a, 0x32, 0x4a, 0x17, 0x39, 0xbb, 0xcf, 0xc9, 0x83, 0xa2, 0xb2, 0x50, 0x75, 0xa, 0x11, 0x17, 0xe5, 0x7b, 0xd2, 0x65, 0x12, 0xcc, 0x5d, 0xca, 0x70, 0x66, 0xd8, 0xb9, 0x72, 0xad, 0x9e, 0xb0, 0xbb, 0x3c, 0x7e, 0x36, 0xb9, 0xb8, 0x4f, 0xc0, 0xe8, 0x12, 0x9b, 0x69, 0xcd, 0x38, 0x47}, - output512: []byte{0x96, 0x65, 0x80, 0x8d, 0x39, 0xb4, 0xbe, 0xcf, 0xdd, 0x9a, 0xa8, 0x2, 0xa, 0xa, 0x72, 0xcf, 0xd4, 0xf8, 0x23, 0xa1, 0x5d, 0x67, 0xd, 0x51, 0x27, 0x8a, 0x4a, 0xe9, 0x55, 0x7, 0xe1, 0x60, 0x20, 0xae, 0xde, 0xd6, 0xe6, 0xc0, 0xe2, 0xda, 0xb0, 0xba, 0xd8, 0x90, 0xa9, 0xe7, 0x55, 0x24, 0x3, 0xd2, 0xaa, 0x8d, 0x1e, 0xbc, 0xb, 0x8e, 0xae, 0xc9, 0xa3, 0xa8, 0xdb, 0xb2, 0xa9, 0xef}, - }, - { - msg: []byte{0x80, 0xbe, 0xeb, 0xcd, 0x2e, 0x3f, 0x8a, 0x94, 0x51, 0xd4, 0x49, 0x99, 0x61, 0xc9, 0x73, 0x1a, 0xe6, 0x67, 0xcd, 0xc2, 0x4e, 0xa0, 0x20, 0xce, 0x3b, 0x9a, 0xa4, 0xbb, 0xc0, 0xa7, 0xf7, 0x9e, 0x30, 0xa9, 0x34, 0x46, 0x7d, 0xa4, 0xb0}, - output224: []byte{0x3c, 0x5e, 0xbe, 0x43, 0xa2, 0x57, 0x1b, 0xce, 0xf2, 0x5e, 0x4e, 0xa6, 0x7a, 0x4c, 0xa9, 0x83, 0x87, 0x70, 0xd2, 0x35, 0x99, 0x5, 0x99, 0x55, 0xaf, 0x93, 0xff, 0x83}, - output256: []byte{0x56, 0x94, 0xca, 0x2f, 0x3b, 0x99, 0x62, 0x22, 0x6a, 0x87, 0x16, 0x3a, 0xb3, 0x83, 0x25, 0xbc, 0xdc, 0x89, 0x8a, 0x73, 0x2d, 0xfe, 0xb2, 0xc3, 0x6d, 0xb4, 0xeb, 0x88, 0x61, 0x6b, 0x87, 0x41}, - output384: []byte{0x17, 0xd, 0x73, 0xba, 0xf7, 0x7e, 0xae, 0x7a, 0x85, 0x2a, 0x1b, 0xb1, 0x9b, 0xa6, 0x66, 0x5f, 0x9e, 0xf4, 0x25, 0xa6, 0x6f, 0x26, 0x49, 0xe9, 0x59, 0xb5, 0xca, 0xa8, 0x2d, 0x1, 0xfd, 0xb8, 0x9c, 0x8c, 0x7f, 0xa6, 0xf4, 0x7, 0x2, 0xf7, 0xc3, 0x39, 0x1b, 0x14, 0x6f, 0x6f, 0xa3, 0x3e}, - output512: []byte{0x7a, 0xba, 0x6b, 0x9f, 0x8f, 0x18, 0xd9, 0xd7, 0x2b, 0x88, 0x3e, 0xb9, 0x88, 0xa5, 0xf4, 0xff, 0xcc, 0x2, 0x17, 0xa3, 0xda, 0x31, 0x6a, 0xff, 0x11, 0xb3, 0x89, 0x76, 0xe9, 0xb, 0x7, 0x36, 0xcb, 0x0, 0xf, 0x52, 0x2d, 0xbf, 0x2d, 0xdc, 0xbb, 0x61, 0xba, 0x4b, 0xf4, 0x4c, 0x35, 0x6e, 0xc5, 0xb4, 0x6f, 0xc8, 0x6a, 0x51, 0x33, 0xf9, 0x71, 0xa9, 0x4f, 0xe2, 0xa9, 0x98, 0x32, 0x60}, - }, - { - msg: []byte{0x7a, 0xba, 0xa1, 0x2e, 0xc2, 0xa7, 0x34, 0x76, 0x74, 0xe4, 0x44, 0x14, 0xa, 0xe0, 0xfb, 0x65, 0x9d, 0x8, 0xe1, 0xc6, 0x6d, 0xec, 0xd8, 0xd6, 0xea, 0xe9, 0x25, 0xfa, 0x45, 0x1d, 0x65, 0xf3, 0xc0, 0x30, 0x8e, 0x29, 0x44, 0x6b, 0x8e, 0xd3}, - output224: []byte{0xaf, 0x71, 0xda, 0xb0, 0xf3, 0x3d, 0x3b, 0x48, 0x73, 0x3a, 0xd6, 0x33, 0x5c, 0xa6, 0x9, 0x39, 0x8d, 0x89, 0x4e, 0x6f, 0xa9, 0x6f, 0x55, 0x10, 0xae, 0x73, 0xe5, 0xd2}, - output256: []byte{0x8c, 0xf2, 0x87, 0xad, 0x3, 0xab, 0x4a, 0x74, 0x8, 0x66, 0x20, 0xcf, 0xa4, 0xcc, 0xe7, 0x4f, 0x48, 0xfa, 0x5c, 0xdb, 0x15, 0xec, 0x2, 0xb1, 0xf7, 0x21, 0x73, 0x6a, 0x4f, 0x84, 0x9e, 0x60}, - output384: []byte{0xa8, 0xf4, 0xa6, 0xa, 0x8f, 0xf5, 0xb3, 0xeb, 0xb4, 0xea, 0xdb, 0x9c, 0x46, 0xf1, 0xf4, 0x3, 0xab, 0x7f, 0xf6, 0x32, 0xc7, 0xa1, 0x1f, 0x80, 0xfc, 0x91, 0x53, 0x85, 0x8b, 0x48, 0x42, 0x91, 0xb3, 0x93, 0x67, 0x13, 0x7, 0x69, 0x55, 0x20, 0x7d, 0xc, 0x7e, 0x19, 0x64, 0xdc, 0x13, 0x46}, - output512: []byte{0x58, 0x9c, 0x46, 0x62, 0x5a, 0x6a, 0xc9, 0xa2, 0xc9, 0xc9, 0xa8, 0x84, 0xf4, 0x27, 0xc3, 0xc0, 0x32, 0x88, 0x7a, 0xe5, 0x3a, 0x69, 0x93, 0x2b, 0x72, 0xe1, 0xe3, 0x79, 0x6b, 0xb9, 0x56, 0x89, 0x29, 0xd1, 0x63, 0x39, 0x5a, 0x3a, 0xa8, 0xb2, 0xab, 0x23, 0xc5, 0x64, 0x93, 0x7c, 0xd7, 0x29, 0x20, 0x6d, 0x9b, 0x62, 0xcc, 0x60, 0x35, 0x3b, 0x68, 0xa6, 0x9a, 0x73, 0x96, 0x16, 0xeb, 0x35}, - }, - { - msg: []byte{0xc8, 0x8d, 0xee, 0x99, 0x27, 0x67, 0x9b, 0x8a, 0xf4, 0x22, 0xab, 0xcb, 0xac, 0xf2, 0x83, 0xb9, 0x4, 0xff, 0x31, 0xe1, 0xca, 0xc5, 0x8c, 0x78, 0x19, 0x80, 0x9f, 0x65, 0xd5, 0x80, 0x7d, 0x46, 0x72, 0x3b, 0x20, 0xf6, 0x7b, 0xa6, 0x10, 0xc2, 0xb7}, - output224: []byte{0xdd, 0x75, 0x12, 0xda, 0xa0, 0xc6, 0x34, 0xcc, 0x15, 0x88, 0x87, 0xb, 0x84, 0x69, 0x1d, 0x7d, 0xe2, 0xc1, 0x82, 0xe5, 0x57, 0xd, 0x57, 0x86, 0x8e, 0x7d, 0xda, 0x5d}, - output256: []byte{0xc5, 0xd5, 0xaf, 0x22, 0xa4, 0xdf, 0x9a, 0xcd, 0xc, 0x5, 0x6f, 0xa3, 0xd, 0x8e, 0x24, 0xb, 0x67, 0x9a, 0x20, 0xd4, 0xd2, 0x63, 0x2, 0x60, 0xf7, 0x79, 0xff, 0x81, 0x5c, 0xa8, 0x2d, 0x7d}, - output384: []byte{0x58, 0x15, 0xd7, 0x8a, 0xca, 0x96, 0x0, 0x63, 0x22, 0x39, 0xb7, 0xce, 0x83, 0x85, 0xd7, 0xe8, 0x37, 0xf8, 0x83, 0x85, 0x76, 0x1, 0xef, 0xb7, 0x8f, 0x9c, 0x2d, 0xac, 0x9a, 0x96, 0xae, 0xb, 0xfd, 0x10, 0x75, 0x26, 0xf2, 0x68, 0xd0, 0x6f, 0xb4, 0x22, 0x7d, 0x47, 0x74, 0xa9, 0xe7, 0x27}, - output512: []byte{0xf7, 0xcd, 0x87, 0x37, 0xa1, 0xab, 0x36, 0xb3, 0x76, 0x12, 0xe5, 0x7d, 0x1e, 0x5a, 0x3d, 0x4a, 0x26, 0x9d, 0x18, 0xcf, 0x2c, 0xb7, 0x64, 0x4a, 0x12, 0x54, 0xe, 0x3b, 0x18, 0x46, 0x31, 0x79, 0x4e, 0xc1, 0xa1, 0xda, 0x11, 0x8a, 0x10, 0x9a, 0xef, 0x51, 0x4d, 0xb3, 0x59, 0xf, 0xe2, 0x7b, 0xe0, 0x75, 0x2e, 0xc0, 0x82, 0x6a, 0xca, 0xf4, 0x58, 0xfb, 0xa, 0x75, 0x4b, 0xdc, 0x51, 0xf1}, - }, - { - msg: []byte{0x1, 0xe4, 0x3f, 0xe3, 0x50, 0xfc, 0xec, 0x45, 0xe, 0xc9, 0xb1, 0x2, 0x5, 0x3e, 0x6b, 0x5d, 0x56, 0xe0, 0x98, 0x96, 0xe0, 0xdd, 0xd9, 0x7, 0x4f, 0xe1, 0x38, 0xe6, 0x3, 0x82, 0x10, 0x27, 0xc, 0x83, 0x4c, 0xe6, 0xea, 0xdc, 0x2b, 0xb8, 0x6b, 0xf6}, - output224: []byte{0x6c, 0xb4, 0xf9, 0x29, 0x2b, 0xa3, 0x3c, 0xa8, 0xd2, 0x93, 0xb7, 0xa7, 0xef, 0x76, 0x61, 0x9e, 0x77, 0x30, 0x9b, 0xa2, 0x17, 0x8c, 0xd4, 0xa1, 0x30, 0xbf, 0x92, 0x18}, - output256: []byte{0xa, 0xc7, 0x52, 0x79, 0xad, 0xff, 0x65, 0x66, 0x4, 0x64, 0x55, 0xa, 0x28, 0x3f, 0xec, 0xd4, 0xe0, 0x61, 0xd, 0x88, 0xf3, 0x55, 0x74, 0xc3, 0xd7, 0xac, 0x5d, 0x22, 0x26, 0x2a, 0x2f, 0xe8}, - output384: []byte{0xa5, 0xd9, 0x1b, 0x1, 0x65, 0xd, 0x24, 0xb4, 0x75, 0x3f, 0x41, 0x87, 0x1f, 0xa7, 0x0, 0xe9, 0x97, 0xd5, 0xf1, 0xef, 0x9c, 0x6, 0xd8, 0xf9, 0xb3, 0xa9, 0xb2, 0xd3, 0x18, 0x71, 0x64, 0x8, 0xe1, 0x56, 0x6b, 0xb0, 0x4b, 0x49, 0xb8, 0x4e, 0x77, 0xf5, 0xf7, 0x3d, 0x8f, 0x64, 0x5, 0x41}, - output512: []byte{0xb2, 0x1b, 0xde, 0xde, 0x48, 0x4c, 0xa1, 0x8f, 0x67, 0x20, 0x58, 0x66, 0x7c, 0xb2, 0xf2, 0xdc, 0x92, 0x2c, 0x44, 0x35, 0x1e, 0x95, 0xc2, 0xcd, 0xa7, 0x5a, 0xf7, 0xe4, 0x55, 0x77, 0xbf, 0x50, 0xe3, 0xf2, 0x3, 0x13, 0x9f, 0x62, 0x62, 0x27, 0x9a, 0xdf, 0xc3, 0x22, 0x1b, 0x94, 0xa0, 0x72, 0x64, 0x1f, 0x8b, 0xdb, 0x55, 0xdc, 0xc0, 0x2f, 0x21, 0xd0, 0x87, 0x9e, 0xb5, 0xe7, 0x46, 0x6a}, - }, - { - msg: []byte{0x33, 0x70, 0x23, 0x37, 0xa, 0x48, 0xb6, 0x2e, 0xe4, 0x35, 0x46, 0xf1, 0x7c, 0x4e, 0xf2, 0xbf, 0x8d, 0x7e, 0xcd, 0x1d, 0x49, 0xf9, 0xb, 0xab, 0x60, 0x4b, 0x83, 0x9c, 0x2e, 0x6e, 0x5b, 0xd2, 0x15, 0x40, 0xd2, 0x9b, 0xa2, 0x7a, 0xb8, 0xe3, 0x9, 0xa4, 0xb7}, - output224: []byte{0xa9, 0xb8, 0x43, 0x5e, 0x55, 0xfc, 0x50, 0xfe, 0x93, 0x5e, 0xc9, 0x67, 0x98, 0xa6, 0x29, 0xc1, 0x3e, 0x85, 0x6c, 0x3c, 0x5c, 0xfd, 0x24, 0x81, 0x26, 0x97, 0x6e, 0xd}, - output256: []byte{0x81, 0x91, 0x7a, 0xe2, 0x90, 0xdb, 0xba, 0x17, 0x28, 0x9a, 0x8a, 0x67, 0xe5, 0xc2, 0xe8, 0xb1, 0x2d, 0x3d, 0xde, 0xe, 0xfe, 0x9f, 0x99, 0x1, 0x98, 0xa1, 0x76, 0x3f, 0xf4, 0xf3, 0xdd, 0xa7}, - output384: []byte{0xc7, 0xba, 0x6, 0x68, 0x81, 0xdb, 0x93, 0x1e, 0x9c, 0x67, 0x4d, 0x74, 0xce, 0x23, 0x9, 0xb3, 0x0, 0x2c, 0x6d, 0x5b, 0xc2, 0x20, 0x56, 0xc4, 0x54, 0x26, 0x1c, 0xdb, 0xc5, 0xd9, 0x3f, 0xe3, 0x10, 0xea, 0xdd, 0x75, 0x5e, 0x41, 0xfb, 0x1d, 0x78, 0x9f, 0xdb, 0x9a, 0x73, 0xfd, 0xa2, 0x8f}, - output512: []byte{0xdb, 0x56, 0x26, 0x5b, 0x93, 0x46, 0x96, 0x8a, 0x39, 0xe, 0x98, 0x41, 0xd5, 0xb7, 0x87, 0x8a, 0x15, 0x8b, 0xae, 0xd9, 0x46, 0x6, 0x8e, 0x80, 0x8e, 0x45, 0x67, 0x35, 0xa6, 0x7e, 0x49, 0x22, 0xf, 0xab, 0x66, 0x23, 0x9d, 0x5d, 0x50, 0x6d, 0xd7, 0x5a, 0x58, 0xf2, 0xc5, 0x6e, 0x25, 0xc9, 0xc1, 0x5, 0xa3, 0x82, 0x7c, 0x14, 0x34, 0xc6, 0x72, 0x55, 0xcf, 0xc9, 0x10, 0x1a, 0x5d, 0x9}, - }, - { - msg: []byte{0x68, 0x92, 0x54, 0xf, 0x96, 0x4c, 0x8c, 0x74, 0xbd, 0x2d, 0xb0, 0x2c, 0xa, 0xd8, 0x84, 0x51, 0xc, 0xb3, 0x8a, 0xfd, 0x44, 0x38, 0xaf, 0x31, 0xfc, 0x91, 0x27, 0x56, 0xf3, 0xef, 0xec, 0x6b, 0x32, 0xb5, 0x8e, 0xbc, 0x38, 0xfc, 0x2a, 0x6b, 0x91, 0x35, 0x96, 0xa8}, - output224: []byte{0x93, 0xe7, 0x98, 0x50, 0x62, 0x2b, 0x91, 0xf7, 0x29, 0xab, 0x5, 0x6e, 0xa4, 0x2, 0xe2, 0x7f, 0x1, 0xb5, 0x32, 0x31, 0x58, 0x11, 0x1b, 0x29, 0x36, 0x2a, 0x96, 0xd5}, - output256: []byte{0x13, 0x8e, 0x75, 0xe7, 0x2f, 0xdd, 0xd9, 0x27, 0xe5, 0x91, 0x31, 0x5a, 0xf8, 0xd3, 0xab, 0xa2, 0x80, 0xef, 0xa3, 0x62, 0x30, 0xa3, 0x30, 0x9a, 0x97, 0xbc, 0xde, 0x5a, 0x78, 0xc3, 0x15, 0x89}, - output384: []byte{0xa5, 0x2c, 0xa3, 0x41, 0x3b, 0xb8, 0x39, 0x34, 0xb1, 0xea, 0xd4, 0x68, 0x6f, 0x63, 0x9b, 0x90, 0xc5, 0xee, 0x3c, 0xb5, 0xbe, 0x7e, 0x29, 0xa1, 0xa5, 0x29, 0x3c, 0x86, 0x84, 0x41, 0xd7, 0x9b, 0xe2, 0xef, 0x24, 0x6b, 0x42, 0x7f, 0xfc, 0xf0, 0x56, 0x8d, 0x4d, 0x1, 0xbe, 0x54, 0xff, 0xd}, - output512: []byte{0x4c, 0x82, 0x5f, 0xd9, 0xa7, 0x95, 0xcc, 0xd2, 0xa, 0x8, 0x92, 0xda, 0x15, 0x72, 0xb9, 0xb1, 0xf7, 0xb, 0xa0, 0x5f, 0xf2, 0xd2, 0xda, 0x3a, 0x47, 0x26, 0xa7, 0x4f, 0x9a, 0xb5, 0x32, 0x3c, 0xcb, 0xc4, 0x29, 0x4, 0x59, 0xc1, 0xbb, 0x46, 0xf0, 0xa1, 0xe1, 0xff, 0xc3, 0x57, 0xff, 0x47, 0x66, 0xf4, 0xf4, 0x87, 0x9d, 0xaa, 0x91, 0xd3, 0x1e, 0xca, 0x98, 0x6a, 0xa3, 0xc, 0x7b, 0x0}, - }, - { - msg: []byte{0xf5, 0x96, 0x1d, 0xfd, 0x2b, 0x1f, 0xff, 0xfd, 0xa4, 0xff, 0xbf, 0x30, 0x56, 0xc, 0x16, 0x5b, 0xfe, 0xda, 0xb8, 0xce, 0xb, 0xe5, 0x25, 0x84, 0x5d, 0xeb, 0x8d, 0xc6, 0x10, 0x4, 0xb7, 0xdb, 0x38, 0x46, 0x72, 0x5, 0xf5, 0xdc, 0xfb, 0x34, 0xa2, 0xac, 0xfe, 0x96, 0xc0}, - output224: []byte{0x7e, 0x51, 0xd5, 0x53, 0x13, 0x82, 0x49, 0x6, 0x70, 0x11, 0x5d, 0xe1, 0x31, 0x37, 0xcb, 0x3a, 0xdb, 0x6e, 0x76, 0x21, 0xb7, 0xd9, 0xec, 0xa8, 0x17, 0xf, 0xaa, 0x96}, - output256: []byte{0x21, 0xbc, 0xda, 0xd3, 0xfe, 0xf3, 0xe5, 0xb8, 0x59, 0xcb, 0x9, 0x12, 0xa2, 0x99, 0x1e, 0xfa, 0x66, 0x1b, 0xad, 0x81, 0x27, 0x47, 0x29, 0x2e, 0xf0, 0xf7, 0x9a, 0x8f, 0xcc, 0x6b, 0x4e, 0x98}, - output384: []byte{0x13, 0xe6, 0x5, 0x54, 0xfa, 0x18, 0xce, 0xf8, 0x7c, 0xea, 0xbe, 0x14, 0x75, 0x41, 0x88, 0x6d, 0x97, 0xc2, 0xfb, 0x5f, 0x40, 0xf1, 0x63, 0xd9, 0x53, 0x30, 0x6d, 0x2a, 0x26, 0xb0, 0x13, 0xb3, 0x3c, 0xb2, 0x2, 0xd7, 0x8a, 0xef, 0x49, 0xfd, 0x47, 0xe7, 0xec, 0x1c, 0x74, 0x59, 0x20, 0xcd}, - output512: []byte{0x84, 0x45, 0xa0, 0x57, 0x66, 0xa3, 0xd, 0xdd, 0x0, 0x80, 0x58, 0x9f, 0x8e, 0x8c, 0xbf, 0x7e, 0xc5, 0x9f, 0xb7, 0xa3, 0xce, 0x73, 0xc0, 0x20, 0x97, 0x91, 0xb1, 0x9c, 0xf7, 0x12, 0xcf, 0x16, 0x35, 0xd6, 0x3c, 0x83, 0x56, 0x82, 0x22, 0x72, 0x30, 0x9c, 0x6b, 0x9f, 0x1, 0x63, 0x70, 0x88, 0x87, 0x8d, 0xbf, 0xfb, 0xed, 0xb2, 0x6d, 0x2a, 0x56, 0x61, 0x85, 0x22, 0x5c, 0x4d, 0xa5, 0x6b}, - }, - { - msg: []byte{0xca, 0x6, 0x1a, 0x2e, 0xb6, 0xce, 0xed, 0x88, 0x81, 0xce, 0x20, 0x57, 0x17, 0x2d, 0x86, 0x9d, 0x73, 0xa1, 0x95, 0x1e, 0x63, 0xd5, 0x72, 0x61, 0x38, 0x4b, 0x80, 0xce, 0xb5, 0x45, 0x1e, 0x77, 0xb0, 0x6c, 0xf0, 0xf5, 0xa0, 0xea, 0x15, 0xca, 0x90, 0x7e, 0xe1, 0xc2, 0x7e, 0xba}, - output224: []byte{0x95, 0xc3, 0x50, 0x37, 0xa8, 0x7, 0x69, 0x26, 0xfc, 0x5c, 0x42, 0x1c, 0x35, 0x16, 0xa, 0xc5, 0xfe, 0x53, 0x3a, 0x27, 0x82, 0xf2, 0xf, 0x2d, 0x3f, 0x4b, 0x1b, 0x7d}, - output256: []byte{0x8d, 0x6f, 0xd9, 0xc5, 0x59, 0xb0, 0xb4, 0x94, 0x8f, 0x91, 0x33, 0x79, 0x16, 0x8, 0x4c, 0x0, 0x82, 0xa1, 0x6a, 0x7, 0x55, 0xb0, 0xa0, 0x8, 0x11, 0x9, 0x6e, 0x97, 0x3e, 0x48, 0xb3, 0xc8}, - output384: []byte{0xe4, 0xe0, 0x3c, 0xcb, 0xa9, 0x2b, 0xbd, 0x28, 0x18, 0x2d, 0x0, 0x5f, 0x69, 0xde, 0x4e, 0x71, 0xc6, 0x1c, 0x62, 0xcd, 0x32, 0x3d, 0xec, 0xfb, 0x2a, 0xdd, 0xbe, 0xef, 0xf7, 0xee, 0x74, 0x93, 0x3a, 0xa7, 0xa1, 0x67, 0xe4, 0xe1, 0xdb, 0xb3, 0xdf, 0x7e, 0x5c, 0x91, 0x18, 0x4f, 0x2d, 0x88}, - output512: []byte{0x2d, 0xc2, 0x51, 0x65, 0xcf, 0x31, 0x7e, 0xd7, 0xde, 0x2b, 0x4f, 0x2f, 0xd0, 0x99, 0x5d, 0x77, 0x85, 0x97, 0x8c, 0xa8, 0x58, 0x1e, 0xa8, 0x3, 0x3e, 0x91, 0x2f, 0x2e, 0x44, 0xee, 0x61, 0x3d, 0xeb, 0xfc, 0x55, 0x35, 0xc4, 0x8d, 0x63, 0x83, 0x8f, 0x32, 0x5d, 0x14, 0x16, 0xb9, 0x18, 0xc, 0x20, 0xbd, 0xe8, 0x26, 0x14, 0x50, 0x4b, 0x71, 0x61, 0xf9, 0x86, 0x5, 0x30, 0xec, 0xa7, 0xc}, - }, - { - msg: []byte{0x17, 0x43, 0xa7, 0x72, 0x51, 0xd6, 0x92, 0x42, 0x75, 0xc, 0x4f, 0x11, 0x40, 0x53, 0x2c, 0xd3, 0xc3, 0x3f, 0x9b, 0x5c, 0xcd, 0xf7, 0x51, 0x4e, 0x85, 0x84, 0xd4, 0xa5, 0xf9, 0xfb, 0xd7, 0x30, 0xbc, 0xf8, 0x4d, 0xd, 0x47, 0x26, 0x36, 0x4b, 0x9b, 0xf9, 0x5a, 0xb2, 0x51, 0xd9, 0xbb}, - output224: []byte{0xbf, 0x2, 0x4a, 0x4f, 0xe4, 0x80, 0x63, 0x61, 0x18, 0xfc, 0xc8, 0x5b, 0x80, 0x77, 0x4, 0xd5, 0x9b, 0x64, 0xd1, 0x6a, 0x15, 0xa, 0xa5, 0x3c, 0xde, 0x41, 0xf0, 0x30}, - output256: []byte{0x1d, 0xd2, 0x3a, 0xe7, 0xaa, 0xdd, 0x61, 0xe7, 0x12, 0xbd, 0xd8, 0x2b, 0xd6, 0xa, 0x70, 0xdd, 0x9d, 0x66, 0xc9, 0xfd, 0x79, 0xdb, 0xfd, 0x86, 0x69, 0xe3, 0xea, 0xab, 0xf7, 0x90, 0x1c, 0xdc}, - output384: []byte{0x9b, 0x26, 0xe9, 0xbf, 0x13, 0xb6, 0xfc, 0x33, 0xfd, 0x33, 0x5d, 0xf9, 0x76, 0xc8, 0xe1, 0xb7, 0x81, 0xc8, 0x0, 0x89, 0x5e, 0xbd, 0x72, 0xe3, 0x4f, 0x96, 0xeb, 0x87, 0x5b, 0x41, 0xf0, 0x4a, 0xae, 0xe8, 0x25, 0xcd, 0x8f, 0xe, 0xb6, 0xc4, 0x3d, 0x80, 0x3f, 0x4e, 0x6e, 0xf6, 0x88, 0xa9}, - output512: []byte{0xcb, 0x61, 0x10, 0xa0, 0x2d, 0x7c, 0xa6, 0x36, 0x46, 0x3f, 0x6e, 0x35, 0x2, 0xcc, 0xf0, 0x17, 0x3b, 0x0, 0x4, 0x82, 0xc7, 0xe0, 0x2, 0xad, 0x92, 0x77, 0xc1, 0xd1, 0x3, 0x17, 0xbd, 0xde, 0xbc, 0x3d, 0xa7, 0xf9, 0x1d, 0x1, 0x73, 0xe3, 0xe2, 0xf9, 0x55, 0x2b, 0xdf, 0xde, 0xa4, 0xdd, 0x1a, 0xfb, 0xf7, 0x50, 0x8b, 0x9, 0x6a, 0xab, 0x18, 0x4, 0x92, 0x1e, 0x95, 0x75, 0x4e, 0x78}, - }, - { - msg: []byte{0xd8, 0xfa, 0xba, 0x1f, 0x51, 0x94, 0xc4, 0xdb, 0x5f, 0x17, 0x6f, 0xab, 0xff, 0xf8, 0x56, 0x92, 0x4e, 0xf6, 0x27, 0xa3, 0x7c, 0xd0, 0x8c, 0xf5, 0x56, 0x8, 0xbb, 0xa8, 0xf1, 0xe3, 0x24, 0xd7, 0xc7, 0xf1, 0x57, 0x29, 0x8e, 0xab, 0xc4, 0xdc, 0xe7, 0xd8, 0x9c, 0xe5, 0x16, 0x24, 0x99, 0xf9}, - output224: []byte{0xb7, 0xa5, 0x1f, 0xbb, 0x8, 0x4d, 0xee, 0xb5, 0x51, 0x36, 0xef, 0xd7, 0x26, 0xe, 0x5b, 0x11, 0x2e, 0x3c, 0x40, 0xd1, 0xa2, 0xd1, 0x4b, 0x14, 0x2d, 0xf9, 0x30, 0xdf}, - output256: []byte{0x34, 0xf8, 0x60, 0x7e, 0xc1, 0xc, 0x9, 0x2c, 0x1b, 0xa0, 0xb6, 0x56, 0x5c, 0xe6, 0x19, 0x70, 0x62, 0xc4, 0xe1, 0xa3, 0x5a, 0x8e, 0x8c, 0x72, 0x3e, 0x48, 0xa2, 0xd2, 0x41, 0x6c, 0x37, 0x90}, - output384: []byte{0xa1, 0x27, 0xfe, 0xfc, 0xdd, 0x24, 0xf, 0x76, 0x2c, 0xce, 0x3f, 0x5f, 0x15, 0x51, 0xfc, 0x7e, 0x1c, 0xde, 0xbc, 0x79, 0x50, 0xd1, 0xcd, 0x94, 0xc6, 0x88, 0x8f, 0x49, 0xc, 0xb2, 0x28, 0x5a, 0x10, 0xfd, 0xe, 0xe7, 0x97, 0xb1, 0x68, 0xc5, 0xca, 0x47, 0x61, 0xfa, 0x23, 0x2a, 0xaf, 0x5}, - output512: []byte{0x7e, 0xf3, 0xa2, 0x89, 0x4c, 0x6e, 0xcb, 0xc4, 0x20, 0x1b, 0x15, 0x34, 0x8f, 0x90, 0x67, 0x15, 0x15, 0xac, 0xcb, 0xa3, 0xc8, 0x16, 0x66, 0x21, 0xf8, 0x64, 0xa9, 0x18, 0x4b, 0xf0, 0x8c, 0x3f, 0x5a, 0x89, 0x5f, 0x6b, 0x59, 0x9d, 0x3c, 0xb4, 0x1f, 0x20, 0xa8, 0xa1, 0xdf, 0x25, 0xae, 0x84, 0xf1, 0xa6, 0xd7, 0xc8, 0xde, 0x74, 0xfb, 0x7c, 0xef, 0x48, 0xf7, 0xe9, 0x6f, 0xde, 0x8d, 0x43}, - }, - { - msg: []byte{0xbe, 0x96, 0x84, 0xbe, 0x70, 0x34, 0x8, 0x60, 0x37, 0x3c, 0x9c, 0x48, 0x2b, 0xa5, 0x17, 0xe8, 0x99, 0xfc, 0x81, 0xba, 0xaa, 0x12, 0xe5, 0xc6, 0xd7, 0x72, 0x79, 0x75, 0xd1, 0xd4, 0x1b, 0xa8, 0xbe, 0xf7, 0x88, 0xcd, 0xb5, 0xcf, 0x46, 0x6, 0xc9, 0xc1, 0xc7, 0xf6, 0x1a, 0xed, 0x59, 0xf9, 0x7d}, - output224: []byte{0x61, 0xcf, 0x83, 0xa, 0x2c, 0x4f, 0x8f, 0x48, 0xbc, 0x64, 0x3f, 0x97, 0xa2, 0x5f, 0x82, 0x2c, 0x1, 0x3f, 0x73, 0xbd, 0xf4, 0xcb, 0x41, 0x94, 0xbc, 0x8d, 0x55, 0xdf}, - output256: []byte{0x19, 0xa8, 0x57, 0x7f, 0xc9, 0xf, 0xae, 0x5d, 0x6a, 0x6b, 0x2e, 0xc, 0x1f, 0xf1, 0x55, 0x51, 0x55, 0x2, 0xcf, 0xa1, 0x75, 0x70, 0x29, 0xc0, 0x9b, 0xeb, 0xbf, 0xa2, 0x63, 0xd9, 0xa3, 0x63}, - output384: []byte{0xfe, 0xb5, 0xa2, 0x4e, 0xdb, 0x5, 0xbe, 0xf8, 0x46, 0xb0, 0xa1, 0xf3, 0xf4, 0x8d, 0xa2, 0x12, 0xdf, 0xc2, 0xd0, 0xba, 0xc7, 0x46, 0x89, 0xd, 0x4a, 0xd7, 0x2f, 0xbe, 0x3a, 0x7b, 0x4f, 0xf8, 0xe2, 0xb5, 0x42, 0xb8, 0x27, 0x77, 0x94, 0x67, 0x12, 0x22, 0x71, 0xb1, 0xe0, 0xdf, 0x2b, 0xd2}, - output512: []byte{0x39, 0xc7, 0xae, 0xf, 0x80, 0x12, 0x9d, 0x9d, 0x29, 0x80, 0xa6, 0x24, 0x6e, 0x2b, 0x6f, 0x10, 0xa3, 0x9e, 0xfa, 0xfd, 0x69, 0x4d, 0xed, 0x12, 0xa6, 0x8, 0x95, 0x9, 0xd9, 0x5e, 0xce, 0x50, 0x6d, 0xc3, 0x8c, 0xa, 0x9d, 0xe4, 0x87, 0xd9, 0xd4, 0x1, 0xdb, 0x1f, 0x15, 0x19, 0x34, 0x4, 0x91, 0x10, 0x69, 0x53, 0x3b, 0xca, 0xe4, 0xc4, 0x8c, 0x53, 0xf2, 0x7b, 0xee, 0x3c, 0xe0, 0xac}, - }, - { - msg: []byte{0x7e, 0x15, 0xd2, 0xb9, 0xea, 0x74, 0xca, 0x60, 0xf6, 0x6c, 0x8d, 0xfa, 0xb3, 0x77, 0xd9, 0x19, 0x8b, 0x7b, 0x16, 0xde, 0xb6, 0xa1, 0xba, 0xe, 0xa3, 0xc7, 0xee, 0x20, 0x42, 0xf8, 0x9d, 0x37, 0x86, 0xe7, 0x79, 0xcf, 0x5, 0x3c, 0x77, 0x78, 0x5a, 0xa9, 0xe6, 0x92, 0xf8, 0x21, 0xf1, 0x4a, 0x7f, 0x51}, - output224: []byte{0xd8, 0x7f, 0x62, 0xea, 0x81, 0x1a, 0x2f, 0x6b, 0xf3, 0xc5, 0xfd, 0xe1, 0x34, 0x75, 0xb9, 0xc6, 0x76, 0x62, 0xc, 0x1, 0x84, 0xf8, 0x71, 0x49, 0xdc, 0x86, 0x86, 0xc8}, - output256: []byte{0x9d, 0x9d, 0xbb, 0x4c, 0xe7, 0xd0, 0x1d, 0x0, 0x9e, 0x72, 0xa6, 0x60, 0x51, 0xac, 0xc1, 0x68, 0x5, 0xe4, 0x9f, 0x59, 0x8c, 0xbe, 0x43, 0xc, 0x5d, 0x4c, 0x22, 0xa8, 0x81, 0xa6, 0x4b, 0x3f}, - output384: []byte{0x8d, 0xa4, 0xf3, 0xd1, 0xa1, 0x31, 0x97, 0x17, 0x1b, 0x2, 0xe1, 0xcc, 0xb0, 0x7b, 0xf5, 0x1c, 0xdb, 0xab, 0xd8, 0x33, 0xfd, 0xc3, 0xc3, 0x79, 0x7a, 0x11, 0x3c, 0xfa, 0x5c, 0x71, 0x79, 0x57, 0x82, 0xc4, 0x7c, 0xe3, 0x6c, 0x38, 0x9f, 0xba, 0xd4, 0x61, 0xd0, 0xd5, 0xb5, 0x9c, 0xa6, 0x84}, - output512: []byte{0x9b, 0x8a, 0x7d, 0x2f, 0x85, 0x19, 0xad, 0x6d, 0xc3, 0xd2, 0xbc, 0x5b, 0x69, 0x6b, 0x35, 0x4c, 0x5a, 0x8b, 0x47, 0x96, 0x40, 0x2c, 0xe1, 0x24, 0x2c, 0x52, 0x63, 0x8e, 0xea, 0x68, 0x93, 0xa1, 0x26, 0x98, 0x20, 0xa6, 0x42, 0xbc, 0x9e, 0xfe, 0x56, 0xcd, 0x7e, 0x26, 0xdc, 0x46, 0xe9, 0x7a, 0x7f, 0xc5, 0x8f, 0xaf, 0x3f, 0x1a, 0x7a, 0x25, 0xf8, 0x6e, 0xcd, 0xc1, 0xf2, 0xf1, 0x7e, 0x64}, - }, - { - msg: []byte{0x9a, 0x21, 0x9b, 0xe4, 0x37, 0x13, 0xbd, 0x57, 0x80, 0x15, 0xe9, 0xfd, 0xa6, 0x6c, 0xf, 0x2d, 0x83, 0xca, 0xc5, 0x63, 0xb7, 0x76, 0xab, 0x9f, 0x38, 0xf3, 0xe4, 0xf7, 0xef, 0x22, 0x9c, 0xb4, 0x43, 0x30, 0x4f, 0xba, 0x40, 0x1e, 0xfb, 0x2b, 0xdb, 0xd7, 0xec, 0xe9, 0x39, 0x10, 0x22, 0x98, 0x65, 0x1c, 0x86}, - output224: []byte{0x2, 0x8a, 0x63, 0x9c, 0x7e, 0xc0, 0xba, 0x1d, 0xce, 0xc0, 0xb6, 0x89, 0xaa, 0x26, 0xe2, 0xc0, 0x16, 0x76, 0x22, 0x46, 0x26, 0x69, 0xa5, 0xc5, 0x20, 0x31, 0x60, 0x2b}, - output256: []byte{0x13, 0xf0, 0xd9, 0x51, 0xb6, 0x44, 0x81, 0x13, 0x54, 0x66, 0xcf, 0xcc, 0xbe, 0x52, 0x41, 0x8c, 0xc1, 0xd0, 0x3f, 0xb1, 0x6b, 0x5b, 0x69, 0x6c, 0x35, 0xd7, 0x24, 0xf6, 0xf5, 0x5c, 0xbb, 0x6d}, - output384: []byte{0xd1, 0x9f, 0xe4, 0xa5, 0xf9, 0x3b, 0xcd, 0x48, 0x3d, 0xaa, 0x7a, 0xf8, 0xcb, 0x63, 0x68, 0x7, 0x96, 0x2d, 0x40, 0xaf, 0x9a, 0x50, 0x7d, 0xc4, 0xfa, 0x4e, 0x1f, 0xd4, 0x80, 0xa6, 0xe8, 0xfa, 0x3c, 0x25, 0xfa, 0x30, 0xeb, 0x6b, 0x74, 0x97, 0x9e, 0xe4, 0x56, 0xc1, 0x64, 0x4a, 0x5c, 0x1d}, - output512: []byte{0xb5, 0xce, 0xef, 0x23, 0xf5, 0x6b, 0xe8, 0x7, 0xb6, 0x16, 0xc7, 0xfd, 0xa4, 0x86, 0x7a, 0x1d, 0x12, 0xd0, 0xa1, 0x68, 0x45, 0x45, 0x9f, 0xc7, 0x4, 0xce, 0x63, 0x1a, 0xd3, 0x27, 0x9a, 0xb2, 0x22, 0xdc, 0xa7, 0xad, 0xda, 0xe5, 0x95, 0xd2, 0x89, 0xcb, 0xa8, 0x99, 0x6d, 0x46, 0x65, 0x5f, 0xa9, 0xb6, 0xbe, 0x58, 0x70, 0x3, 0x2, 0xe6, 0x55, 0xc5, 0x1c, 0x82, 0x5f, 0x31, 0xbb, 0x2e}, - }, - { - msg: []byte{0xc8, 0xf2, 0xb6, 0x93, 0xbd, 0xd, 0x75, 0xef, 0x99, 0xca, 0xeb, 0xdc, 0x22, 0xad, 0xf4, 0x8, 0x8a, 0x95, 0xa3, 0x54, 0x2f, 0x63, 0x72, 0x3, 0xe2, 0x83, 0xbb, 0xc3, 0x26, 0x87, 0x80, 0xe7, 0x87, 0xd6, 0x8d, 0x28, 0xcc, 0x38, 0x97, 0x45, 0x2f, 0x6a, 0x22, 0xaa, 0x85, 0x73, 0xcc, 0xeb, 0xf2, 0x45, 0x97, 0x2a}, - output224: []byte{0x90, 0x8e, 0xf2, 0x8a, 0xb2, 0xb6, 0xcb, 0xb4, 0x49, 0xb9, 0xaf, 0x7f, 0xa7, 0x8b, 0x3d, 0x90, 0xe0, 0x19, 0xc3, 0x91, 0x65, 0x62, 0xeb, 0x48, 0x19, 0xa0, 0xc8, 0x7f}, - output256: []byte{0xfb, 0x2f, 0xe7, 0xb0, 0xb, 0x75, 0xc4, 0x23, 0x5, 0xcf, 0x31, 0xde, 0x14, 0xd9, 0x8f, 0x90, 0x4e, 0x8c, 0x46, 0xdc, 0x57, 0xbb, 0x6f, 0x94, 0xc2, 0x82, 0xca, 0x8c, 0x13, 0xdc, 0x45, 0xdb}, - output384: []byte{0x63, 0xff, 0x30, 0x53, 0xac, 0xe6, 0x87, 0xfb, 0x91, 0x7, 0xc, 0xa7, 0xfc, 0x6a, 0x51, 0xc2, 0x59, 0xe1, 0x3d, 0xa8, 0xac, 0xd, 0xd7, 0x41, 0xab, 0x36, 0xd1, 0xfa, 0x93, 0xe, 0x3b, 0xb9, 0xac, 0x6a, 0x1f, 0xad, 0x65, 0x4f, 0x72, 0x38, 0xcf, 0xc4, 0x48, 0x5c, 0x5f, 0x9f, 0x82, 0x52}, - output512: []byte{0x14, 0x3d, 0x2, 0x4f, 0xa7, 0x5c, 0x8d, 0x46, 0x27, 0x35, 0x89, 0xb8, 0xf7, 0x84, 0x32, 0xd4, 0x9e, 0xf1, 0x41, 0x78, 0xe4, 0xaa, 0xa2, 0x7d, 0xc3, 0x66, 0xc9, 0xcb, 0x78, 0x7f, 0x24, 0xb7, 0x3f, 0x41, 0x97, 0xa7, 0x22, 0xf1, 0x30, 0x31, 0x18, 0x1a, 0x6f, 0xa6, 0xe4, 0xf6, 0x61, 0x27, 0x89, 0x3d, 0xa7, 0xb2, 0x3a, 0x57, 0x9b, 0xb9, 0x3f, 0xe7, 0xd7, 0x37, 0xa4, 0x19, 0x40, 0x93}, - }, - { - msg: []byte{0xec, 0xf, 0x99, 0x71, 0x10, 0x16, 0xc6, 0xa2, 0xa0, 0x7a, 0xd8, 0xd, 0x16, 0x42, 0x75, 0x6, 0xce, 0x6f, 0x44, 0x10, 0x59, 0xfd, 0x26, 0x94, 0x42, 0xba, 0xaa, 0x28, 0xc6, 0xca, 0x3, 0x7b, 0x22, 0xee, 0xac, 0x49, 0xd5, 0xd8, 0x94, 0xc0, 0xbf, 0x66, 0x21, 0x9f, 0x2c, 0x8, 0xe9, 0xd0, 0xe8, 0xab, 0x21, 0xde, 0x52}, - output224: []byte{0x6a, 0xc8, 0x41, 0x49, 0xf8, 0x90, 0xe1, 0x35, 0x2c, 0x6d, 0x73, 0x97, 0xda, 0xc3, 0xb3, 0x77, 0x39, 0x47, 0xb3, 0x75, 0x7e, 0x8e, 0xd4, 0xec, 0x5, 0x9e, 0xf8, 0x99}, - output256: []byte{0xd5, 0x4c, 0xbf, 0x7d, 0x5c, 0x80, 0xae, 0x11, 0xa0, 0xd0, 0xba, 0xd4, 0xe9, 0x5a, 0xb1, 0x8b, 0x5f, 0x7, 0xc9, 0x70, 0x62, 0x1f, 0x39, 0x36, 0x44, 0x7a, 0x48, 0xee, 0xf8, 0x18, 0xd0, 0x6e}, - output384: []byte{0x39, 0xdd, 0xe0, 0x2a, 0x31, 0x9b, 0x5e, 0x86, 0x9f, 0x4c, 0x51, 0xa1, 0xd3, 0xf, 0xf4, 0xd4, 0xd8, 0x8e, 0xbe, 0x50, 0x4c, 0x54, 0xf1, 0x55, 0xaa, 0x5f, 0xad, 0x33, 0x16, 0x40, 0x4f, 0xdb, 0xd1, 0x91, 0x80, 0x74, 0xd3, 0x5d, 0x14, 0xba, 0xc8, 0x8d, 0x6f, 0x35, 0x91, 0x8, 0xa1, 0xdc}, - output512: []byte{0xf, 0x48, 0xd0, 0x8, 0xdd, 0x3a, 0xa6, 0x30, 0xe8, 0x26, 0x16, 0x58, 0xa5, 0x5b, 0x56, 0x5b, 0x67, 0x73, 0x99, 0x24, 0x26, 0xb0, 0x85, 0x92, 0xb4, 0xc1, 0xd7, 0x7a, 0x58, 0xb0, 0x67, 0xf0, 0x5e, 0x25, 0x97, 0x4e, 0x50, 0x16, 0x28, 0xa2, 0xdb, 0x63, 0x2f, 0x2d, 0xdd, 0xd7, 0x36, 0x73, 0x11, 0x9a, 0xda, 0x56, 0x74, 0xd0, 0xce, 0x92, 0xc7, 0xaa, 0x90, 0x8b, 0x9e, 0x9c, 0x43, 0x5e}, - }, - { - msg: []byte{0xd, 0xc4, 0x51, 0x81, 0x33, 0x7c, 0xa3, 0x2a, 0x82, 0x22, 0xfe, 0x7a, 0x3b, 0xf4, 0x2f, 0xc9, 0xf8, 0x97, 0x44, 0x25, 0x9c, 0xff, 0x65, 0x35, 0x4, 0xd6, 0x5, 0x1f, 0xe8, 0x4b, 0x1a, 0x7f, 0xfd, 0x20, 0xcb, 0x47, 0xd4, 0x69, 0x6c, 0xe2, 0x12, 0xa6, 0x86, 0xbb, 0x9b, 0xe9, 0xa8, 0xab, 0x1c, 0x69, 0x7b, 0x6d, 0x6a, 0x33}, - output224: []byte{0x45, 0xda, 0x27, 0x71, 0x5c, 0xd7, 0x5f, 0x58, 0x75, 0xbe, 0xb7, 0xd9, 0x14, 0xcf, 0x74, 0x88, 0x24, 0xd, 0x1b, 0x1f, 0x97, 0x5d, 0x43, 0xd, 0x2f, 0x49, 0xe9, 0xbf}, - output256: []byte{0xff, 0x5, 0xa, 0x45, 0xad, 0xee, 0xf4, 0xcf, 0xc7, 0xd9, 0x64, 0x10, 0x2b, 0xa8, 0x77, 0xc8, 0x3, 0x20, 0xa3, 0x77, 0x94, 0x89, 0x3e, 0x68, 0x65, 0x96, 0x5e, 0xc2, 0x54, 0x7c, 0xd4, 0xc9}, - output384: []byte{0x19, 0x59, 0x37, 0x8f, 0x32, 0x11, 0x7e, 0x58, 0xc0, 0x14, 0x11, 0x60, 0xe1, 0x6f, 0xac, 0xfe, 0x33, 0x65, 0x90, 0x19, 0x6b, 0xe8, 0x5, 0xd1, 0x49, 0xeb, 0x5a, 0xee, 0xa6, 0x41, 0xf9, 0xbb, 0x11, 0x9b, 0x3e, 0xdd, 0xfe, 0xfd, 0x81, 0x77, 0x1, 0xc8, 0x2d, 0x2f, 0x52, 0x8b, 0x82, 0x3e}, - output512: []byte{0x29, 0x74, 0x98, 0x63, 0x9f, 0xc7, 0xaa, 0x41, 0x52, 0x65, 0x4e, 0x46, 0x8e, 0x8, 0xf2, 0x9a, 0xff, 0xd7, 0x6, 0x1d, 0x44, 0xe3, 0xf5, 0x32, 0xbe, 0x4b, 0xac, 0x16, 0x9c, 0x87, 0x7a, 0x2e, 0xa7, 0xb4, 0xd7, 0xd, 0x6b, 0xc0, 0xf6, 0x78, 0xbe, 0x8, 0xaa, 0x6, 0x42, 0x58, 0xef, 0x57, 0x11, 0x13, 0x10, 0xd1, 0x3b, 0x88, 0x97, 0x12, 0xd0, 0x65, 0x30, 0xb6, 0x90, 0x84, 0x1d, 0xbe}, - }, - { - msg: []byte{0xde, 0x28, 0x6b, 0xa4, 0x20, 0x6e, 0x8b, 0x0, 0x57, 0x14, 0xf8, 0xf, 0xb1, 0xcd, 0xfa, 0xeb, 0xde, 0x91, 0xd2, 0x9f, 0x84, 0x60, 0x3e, 0x4a, 0x3e, 0xbc, 0x4, 0x68, 0x6f, 0x99, 0xa4, 0x6c, 0x9e, 0x88, 0xb, 0x96, 0xc5, 0x74, 0x82, 0x55, 0x82, 0xe8, 0x81, 0x2a, 0x26, 0xe5, 0xa8, 0x57, 0xff, 0xc6, 0x57, 0x9f, 0x63, 0x74, 0x2f}, - output224: []byte{0x63, 0xaf, 0xba, 0xbb, 0xec, 0x7, 0x21, 0x40, 0xdf, 0xce, 0xfe, 0x64, 0xcf, 0x7b, 0xc9, 0x53, 0x4d, 0xca, 0x10, 0x95, 0x60, 0x42, 0xe3, 0x1d, 0xbe, 0x58, 0xd0, 0xa5}, - output256: []byte{0x1b, 0xc1, 0xbc, 0xc7, 0xf, 0x63, 0x89, 0x58, 0xdb, 0x10, 0x6, 0xaf, 0x37, 0xb0, 0x2e, 0xbd, 0x89, 0x54, 0xec, 0x59, 0xb3, 0xac, 0xba, 0xd1, 0x2e, 0xac, 0xed, 0xbc, 0x5b, 0x21, 0xe9, 0x8}, - output384: []byte{0x7b, 0x17, 0x2a, 0x9b, 0xb3, 0x11, 0xb1, 0x37, 0x5e, 0x15, 0xec, 0xe1, 0xc1, 0xe8, 0xf0, 0x92, 0xbe, 0xcf, 0xaf, 0xec, 0x9f, 0x31, 0x44, 0xe9, 0x3f, 0x59, 0x6e, 0xb7, 0xe6, 0xab, 0xfb, 0x34, 0xfc, 0xed, 0xb0, 0x8e, 0xda, 0x78, 0x83, 0xeb, 0xbf, 0x40, 0x3, 0x8b, 0x7a, 0x75, 0x4f, 0x9f}, - output512: []byte{0x1b, 0x6d, 0xa1, 0x61, 0x51, 0xfc, 0xd1, 0x83, 0x83, 0x37, 0x26, 0x83, 0x48, 0x1, 0x19, 0xa3, 0x4, 0x79, 0x6b, 0x2a, 0x5e, 0x54, 0xf7, 0xed, 0xc6, 0xc7, 0xbc, 0x86, 0x81, 0x73, 0x59, 0xe7, 0x3f, 0x6f, 0xc5, 0x58, 0x7c, 0x77, 0xbf, 0xc7, 0x1b, 0x56, 0xec, 0x67, 0x90, 0x5f, 0xa7, 0xf1, 0x51, 0x93, 0xf9, 0xf1, 0x3c, 0xfa, 0x19, 0xb, 0xc7, 0xb0, 0x55, 0x3, 0xa5, 0x78, 0x2c, 0x8a}, - }, - { - msg: []byte{0xee, 0xbc, 0xc1, 0x80, 0x57, 0x25, 0x2c, 0xbf, 0x3f, 0x9c, 0x7, 0xf, 0x1a, 0x73, 0x21, 0x33, 0x56, 0xd5, 0xd4, 0xbc, 0x19, 0xac, 0x2a, 0x41, 0x1e, 0xc8, 0xcd, 0xee, 0xe7, 0xa5, 0x71, 0xe2, 0xe2, 0xe, 0xaf, 0x61, 0xfd, 0xc, 0x33, 0xa0, 0xff, 0xeb, 0x29, 0x7d, 0xdb, 0x77, 0xa9, 0x7f, 0xa, 0x41, 0x53, 0x47, 0xdb, 0x66, 0xbc, 0xaf}, - output224: []byte{0x64, 0x87, 0x19, 0x3d, 0x9c, 0xbe, 0x59, 0x3b, 0x3d, 0xaa, 0x50, 0xd4, 0xdf, 0xdf, 0x7d, 0xd2, 0x61, 0x23, 0x0, 0xbb, 0x93, 0xcb, 0x39, 0xe3, 0xee, 0xfa, 0x1a, 0xfa}, - output256: []byte{0xf7, 0xbd, 0xe2, 0x39, 0xad, 0x8, 0x7a, 0xa7, 0xda, 0xbe, 0x42, 0xcc, 0x4d, 0x3c, 0x49, 0x38, 0xa, 0x2, 0x6c, 0xd2, 0x39, 0xa7, 0xfa, 0xaf, 0x34, 0xa2, 0x23, 0x34, 0x69, 0xa4, 0x4a, 0x4d}, - output384: []byte{0x6b, 0xa3, 0x2e, 0xca, 0xaa, 0xa, 0xa9, 0xc5, 0x9e, 0x72, 0x17, 0x3f, 0x2a, 0x78, 0x16, 0xac, 0x51, 0xf3, 0x13, 0xc4, 0x67, 0xa0, 0x17, 0x19, 0xd, 0xb9, 0x83, 0x2c, 0x63, 0x11, 0xec, 0x23, 0xb8, 0xd5, 0x6b, 0x7b, 0x22, 0xf, 0xa0, 0x9a, 0x90, 0x81, 0x96, 0x2e, 0xfe, 0xd5, 0x18, 0x3e}, - output512: []byte{0xb2, 0xf4, 0x9, 0x35, 0xe7, 0xc9, 0x1, 0x88, 0x14, 0xc4, 0xe2, 0x72, 0x1d, 0x9b, 0x5a, 0xee, 0xed, 0x33, 0x70, 0x69, 0x3, 0x78, 0xe4, 0x72, 0xbd, 0x29, 0xf2, 0x27, 0x44, 0x2c, 0xa4, 0x94, 0x2b, 0x6, 0x18, 0x9c, 0x34, 0x6f, 0xda, 0x49, 0x81, 0x23, 0xec, 0xe5, 0x90, 0x18, 0xe4, 0x2c, 0x8b, 0x7e, 0xe3, 0x81, 0x91, 0xf9, 0x77, 0x89, 0xb4, 0xaa, 0x93, 0x22, 0x3a, 0x8d, 0x80, 0xef}, - }, - { - msg: []byte{0x41, 0x6b, 0x5c, 0xdc, 0x9f, 0xe9, 0x51, 0xbd, 0x36, 0x1b, 0xd7, 0xab, 0xfc, 0x12, 0xa, 0x50, 0x54, 0x75, 0x8e, 0xba, 0x88, 0xfd, 0xd6, 0x8f, 0xd8, 0x4e, 0x39, 0xd3, 0xb0, 0x9a, 0xc2, 0x54, 0x97, 0xd3, 0x6b, 0x43, 0xcb, 0xe7, 0xb8, 0x5a, 0x6a, 0x3c, 0xeb, 0xda, 0x8d, 0xb4, 0xe5, 0x54, 0x9c, 0x3e, 0xe5, 0x1b, 0xb6, 0xfc, 0xb6, 0xac, 0x1e}, - output224: []byte{0xd, 0xec, 0x25, 0xbe, 0x32, 0x77, 0xe2, 0x7d, 0x4f, 0x78, 0x4a, 0xd5, 0xff, 0x8f, 0x79, 0xd6, 0x1d, 0x9a, 0x30, 0x9b, 0xd6, 0x93, 0x51, 0x3a, 0xcb, 0xee, 0xd1, 0x2f}, - output256: []byte{0xef, 0x84, 0x5a, 0xac, 0x2a, 0xaf, 0xa, 0x79, 0x31, 0x8, 0x20, 0x4f, 0xf3, 0x80, 0xe0, 0xa3, 0xf, 0x25, 0x58, 0xe7, 0xac, 0xde, 0x45, 0x31, 0xab, 0x22, 0xf8, 0xec, 0x79, 0xe2, 0x6a, 0x69}, - output384: []byte{0x55, 0xfd, 0xf2, 0xec, 0x27, 0xd3, 0x34, 0xb5, 0xb5, 0x9e, 0xfb, 0x9b, 0x6d, 0x51, 0x8e, 0x25, 0xbe, 0xf, 0x5f, 0xf6, 0x37, 0x9f, 0x7b, 0x97, 0x94, 0x5f, 0x3e, 0x12, 0x35, 0xec, 0x70, 0x29, 0x5b, 0x39, 0xeb, 0xea, 0xbf, 0x70, 0xfc, 0xaf, 0x1e, 0x61, 0xed, 0xb1, 0xc2, 0x1a, 0x4c, 0x6}, - output512: []byte{0xc8, 0xd2, 0x42, 0xfb, 0x5f, 0xf1, 0xc6, 0xcd, 0x11, 0xa0, 0x40, 0xae, 0xaf, 0x35, 0xcc, 0x9, 0xe3, 0x55, 0xa9, 0x75, 0xe0, 0x4d, 0xed, 0x1d, 0x83, 0x41, 0x87, 0x8b, 0xed, 0x5d, 0xff, 0x8b, 0xbb, 0xd1, 0xb6, 0x9f, 0x4d, 0x12, 0x2c, 0xe5, 0x33, 0x9, 0xac, 0x8, 0x75, 0x3b, 0x95, 0xd2, 0xa5, 0x77, 0x21, 0xdf, 0xd1, 0x2e, 0x70, 0xa8, 0xef, 0x12, 0xe1, 0x1e, 0x16, 0xde, 0xf, 0xd9}, - }, - { - msg: []byte{0x5c, 0x5f, 0xaf, 0x66, 0xf3, 0x2e, 0xf, 0x83, 0x11, 0xc3, 0x2e, 0x8d, 0xa8, 0x28, 0x4a, 0x4e, 0xd6, 0x8, 0x91, 0xa5, 0xa7, 0xe5, 0xf, 0xb2, 0x95, 0x6b, 0x3c, 0xba, 0xa7, 0x9f, 0xc6, 0x6c, 0xa3, 0x76, 0x46, 0xe, 0x10, 0x4, 0x15, 0x40, 0x1f, 0xc2, 0xb8, 0x51, 0x8c, 0x64, 0x50, 0x2f, 0x18, 0x7e, 0xa1, 0x4b, 0xfc, 0x95, 0x3, 0x75, 0x97, 0x5}, - output224: []byte{0x13, 0xb, 0x67, 0xc6, 0xd1, 0xa5, 0x61, 0x62, 0x27, 0xab, 0xd7, 0x3a, 0xbf, 0x6f, 0xeb, 0x70, 0xfc, 0xe1, 0xd5, 0xa4, 0xbf, 0x33, 0x38, 0xc6, 0xdc, 0xcb, 0x39, 0xd5}, - output256: []byte{0x26, 0xdb, 0x51, 0x4e, 0x1, 0xe0, 0x34, 0xc6, 0x78, 0xb6, 0x36, 0xd4, 0xb, 0xa3, 0x67, 0xda, 0x2f, 0x37, 0xf6, 0x70, 0x78, 0xbb, 0x57, 0x6f, 0xf2, 0xb8, 0x55, 0x9b, 0x35, 0x17, 0x48, 0x4d}, - output384: []byte{0xd5, 0x1a, 0x3f, 0x33, 0x91, 0x9f, 0xe5, 0xda, 0xe, 0xfe, 0xa6, 0xed, 0xad, 0x20, 0x1f, 0x1, 0xfa, 0x84, 0x16, 0xc3, 0x85, 0xa8, 0x9d, 0x96, 0xdf, 0x74, 0x3d, 0x24, 0x3a, 0x6a, 0xab, 0xa5, 0xb7, 0x69, 0xd, 0x18, 0x7b, 0x95, 0xca, 0xff, 0xda, 0xcd, 0x1e, 0x85, 0xf5, 0x6b, 0x81, 0x3b}, - output512: []byte{0xd1, 0xd5, 0xd5, 0xdd, 0x7d, 0x19, 0x6b, 0x87, 0xbe, 0x4a, 0x38, 0xf2, 0xd9, 0xb4, 0xa6, 0x9d, 0xf9, 0xdf, 0xe0, 0xa6, 0xe8, 0xce, 0x71, 0xb0, 0x8c, 0xf2, 0x2c, 0x7f, 0x67, 0xe, 0xcf, 0x27, 0x3e, 0xaf, 0x39, 0x5d, 0x12, 0xfc, 0x63, 0xe1, 0x74, 0x1d, 0xef, 0x11, 0x3c, 0xc7, 0x10, 0x49, 0x70, 0x19, 0x4a, 0x7c, 0x7c, 0x80, 0x7e, 0x53, 0x19, 0xd7, 0xbb, 0x70, 0x2f, 0x20, 0xb5, 0x68}, - }, - { - msg: []byte{0x71, 0x67, 0xe1, 0xe0, 0x2b, 0xe1, 0xa7, 0xca, 0x69, 0xd7, 0x88, 0x66, 0x6f, 0x82, 0x3a, 0xe4, 0xee, 0xf3, 0x92, 0x71, 0xf3, 0xc2, 0x6a, 0x5c, 0xf7, 0xce, 0xe0, 0x5b, 0xca, 0x83, 0x16, 0x10, 0x66, 0xdc, 0x2e, 0x21, 0x7b, 0x33, 0xd, 0xf8, 0x21, 0x10, 0x37, 0x99, 0xdf, 0x6d, 0x74, 0x81, 0xe, 0xed, 0x36, 0x3a, 0xdc, 0x4a, 0xb9, 0x9f, 0x36, 0x4, 0x6a}, - output224: []byte{0x3a, 0xbb, 0x5a, 0xcb, 0x84, 0x85, 0xe2, 0xb, 0xb6, 0x20, 0xd4, 0xa0, 0x30, 0xb9, 0xc2, 0x5d, 0x31, 0x56, 0xa9, 0xb2, 0x68, 0x93, 0xae, 0x0, 0x7c, 0x79, 0xf3, 0x5}, - output256: []byte{0x5d, 0xbd, 0x4b, 0x55, 0x84, 0x63, 0x19, 0x62, 0x11, 0x46, 0x5c, 0x1f, 0xc3, 0x24, 0x1, 0xfc, 0x2d, 0x8e, 0x41, 0xeb, 0xc5, 0xe6, 0xba, 0xdd, 0x1d, 0x8f, 0x7c, 0x4f, 0x9, 0xf, 0x72, 0x8f}, - output384: []byte{0xf1, 0xd6, 0xe8, 0xf9, 0x5c, 0x49, 0x7d, 0x5b, 0xea, 0xfb, 0x42, 0x15, 0xe0, 0x7c, 0xdb, 0x59, 0xe0, 0xe3, 0x70, 0x9c, 0xf5, 0x61, 0x61, 0x8f, 0x67, 0xe3, 0x1, 0x93, 0x1d, 0x20, 0x4c, 0x6c, 0xe4, 0x77, 0xe0, 0xf7, 0x50, 0x9, 0x95, 0x84, 0xb6, 0x45, 0xe2, 0xf7, 0x18, 0x65, 0x8, 0x13}, - output512: []byte{0xd8, 0x12, 0x47, 0xb, 0x2d, 0x13, 0x5b, 0x6e, 0x1b, 0xc0, 0xc8, 0x5d, 0xc0, 0x65, 0x2b, 0xf9, 0xf6, 0xc2, 0xf9, 0xee, 0x70, 0x7a, 0x2e, 0x66, 0x71, 0x81, 0xcc, 0x9f, 0x68, 0x9b, 0xc7, 0xdf, 0x9c, 0xc9, 0x99, 0xb0, 0x87, 0x16, 0x86, 0x8a, 0xfa, 0xc7, 0x82, 0x44, 0xb1, 0x51, 0xb7, 0x25, 0xa0, 0x27, 0xd9, 0x25, 0xa, 0xb7, 0xa0, 0x73, 0xa4, 0x69, 0xe7, 0xf0, 0x9b, 0xdb, 0xb, 0x55}, - }, - { - msg: []byte{0x2f, 0xda, 0x31, 0x1d, 0xbb, 0xa2, 0x73, 0x21, 0xc5, 0x32, 0x95, 0x10, 0xfa, 0xe6, 0x94, 0x8f, 0x3, 0x21, 0xb, 0x76, 0xd4, 0x3e, 0x74, 0x48, 0xd1, 0x68, 0x9a, 0x6, 0x38, 0x77, 0xb6, 0xd1, 0x4c, 0x4f, 0x6d, 0xe, 0xaa, 0x96, 0xc1, 0x50, 0x5, 0x13, 0x71, 0xf7, 0xdd, 0x8a, 0x41, 0x19, 0xf7, 0xda, 0x5c, 0x48, 0x3c, 0xc3, 0xe6, 0x72, 0x3c, 0x1, 0xfb, 0x7d}, - output224: []byte{0x92, 0x2e, 0x21, 0x65, 0x29, 0xa9, 0x53, 0x5, 0x30, 0x7e, 0x90, 0x8c, 0x69, 0x36, 0x7e, 0xbb, 0x9a, 0xd9, 0x31, 0xec, 0xa3, 0x14, 0x56, 0x3a, 0xc3, 0x6a, 0xab, 0x80}, - output256: []byte{0x35, 0x5c, 0x79, 0xfd, 0x6e, 0x6f, 0xa8, 0x8e, 0xd4, 0x2, 0xb6, 0x97, 0x9f, 0xde, 0x1e, 0xd8, 0x5, 0x49, 0x8a, 0xbe, 0xb1, 0x1, 0xf4, 0x23, 0x1b, 0x5d, 0x64, 0xd1, 0x43, 0x9d, 0x55, 0x2d}, - output384: []byte{0xb1, 0xd3, 0x47, 0xd0, 0x57, 0xcc, 0xd7, 0x28, 0x67, 0xb1, 0x2b, 0xf0, 0xb, 0xf5, 0x11, 0xf8, 0x7d, 0xef, 0xcd, 0xf, 0xa6, 0xad, 0xad, 0xaf, 0x4b, 0xb1, 0xad, 0x79, 0xf, 0x6, 0xec, 0xbb, 0x1f, 0x44, 0x88, 0xa0, 0x31, 0x9b, 0x5, 0xc4, 0x6a, 0x78, 0x74, 0x85, 0x73, 0x70, 0xce, 0x76}, - output512: []byte{0x20, 0x3e, 0xf6, 0xbb, 0x51, 0x32, 0xa9, 0xd4, 0x4e, 0xae, 0x93, 0xc7, 0x20, 0x2b, 0x14, 0x69, 0xc2, 0xc2, 0xb9, 0x37, 0x6, 0xd0, 0xa3, 0x1b, 0x29, 0x22, 0x3c, 0x41, 0x1a, 0x39, 0x55, 0xf, 0x60, 0xf3, 0x9b, 0x95, 0x56, 0xfd, 0x4, 0xb, 0xfb, 0x5f, 0x9f, 0x70, 0x99, 0x31, 0x3b, 0x88, 0x74, 0xc8, 0xed, 0x67, 0x7c, 0xfc, 0x5f, 0x93, 0xd9, 0xa2, 0x94, 0x1a, 0x9b, 0x1, 0x39, 0xde}, - }, - { - msg: []byte{0x95, 0xd1, 0x47, 0x4a, 0x5a, 0xab, 0x5d, 0x24, 0x22, 0xac, 0xa6, 0xe4, 0x81, 0x18, 0x78, 0x33, 0xa6, 0x21, 0x2b, 0xd2, 0xd0, 0xf9, 0x14, 0x51, 0xa6, 0x7d, 0xd7, 0x86, 0xdf, 0xc9, 0x1d, 0xfe, 0xd5, 0x1b, 0x35, 0xf4, 0x7e, 0x1d, 0xeb, 0x8a, 0x8a, 0xb4, 0xb9, 0xcb, 0x67, 0xb7, 0x1, 0x79, 0xcc, 0x26, 0xf5, 0x53, 0xae, 0x7b, 0x56, 0x99, 0x69, 0xce, 0x15, 0x1b, 0x8d}, - output224: []byte{0xc7, 0x2e, 0x93, 0xa2, 0xc3, 0x9a, 0xbc, 0xd9, 0xa, 0xb1, 0x1c, 0xd3, 0xf1, 0x5d, 0x59, 0xda, 0x3c, 0x23, 0xc0, 0xf1, 0x7c, 0x4e, 0x26, 0xc9, 0xc5, 0x89, 0x8, 0x87}, - output256: []byte{0x3d, 0x9c, 0x9b, 0xf0, 0x9d, 0x88, 0x21, 0x1c, 0x7e, 0x0, 0x56, 0x11, 0x2d, 0x7, 0x3e, 0xe8, 0x5d, 0x0, 0xac, 0xaa, 0x4d, 0xa7, 0xa6, 0x68, 0xfa, 0x1, 0x7b, 0x32, 0x73, 0xcd, 0x4d, 0x4b}, - output384: []byte{0x4f, 0x19, 0x2e, 0xdf, 0xa5, 0x4f, 0xec, 0xe6, 0x4a, 0xc0, 0xb3, 0xec, 0x9e, 0x12, 0xb, 0x29, 0x1a, 0xde, 0x99, 0x94, 0x88, 0x5, 0xa8, 0x7b, 0xbb, 0x4, 0x94, 0x7e, 0x92, 0x8b, 0xb5, 0xeb, 0xa8, 0x7e, 0x2e, 0xe5, 0x99, 0x96, 0xc, 0x43, 0x6e, 0xa7, 0xc7, 0x88, 0x41, 0x87, 0xe7, 0x8c}, - output512: []byte{0x23, 0xbe, 0xad, 0x9, 0x70, 0x7a, 0x77, 0xb2, 0x95, 0xfd, 0x22, 0xfe, 0x0, 0x12, 0x82, 0x33, 0x8c, 0x2d, 0x36, 0x83, 0x2, 0xa0, 0x5f, 0xb1, 0x14, 0xba, 0x2a, 0x1, 0x2c, 0x4d, 0xef, 0xcf, 0x6, 0xf3, 0x88, 0x7d, 0x6d, 0xb7, 0xa0, 0xa1, 0xde, 0x4, 0xbc, 0x39, 0x9b, 0xde, 0x92, 0xd6, 0xbe, 0x71, 0x90, 0x4a, 0x9a, 0xa7, 0xb9, 0x2b, 0xed, 0xfa, 0x2, 0x3, 0xf1, 0xd8, 0xb0, 0x6f}, - }, - { - msg: []byte{0xc7, 0x1b, 0xd7, 0x94, 0x1f, 0x41, 0xdf, 0x4, 0x4a, 0x29, 0x27, 0xa8, 0xff, 0x55, 0xb4, 0xb4, 0x67, 0xc3, 0x3d, 0x8, 0x9f, 0x9, 0x88, 0xaa, 0x25, 0x3d, 0x29, 0x4a, 0xdd, 0xbd, 0xb3, 0x25, 0x30, 0xc0, 0xd4, 0x20, 0x8b, 0x10, 0xd9, 0x95, 0x98, 0x23, 0xf0, 0xc0, 0xf0, 0x73, 0x46, 0x84, 0x0, 0x6d, 0xf7, 0x9f, 0x70, 0x99, 0x87, 0xf, 0x6b, 0xf5, 0x32, 0x11, 0xa8, 0x8d}, - output224: []byte{0xcc, 0xcc, 0x3b, 0x59, 0xf2, 0x8c, 0x3f, 0xc4, 0x62, 0xdc, 0xa, 0x69, 0x61, 0x50, 0xf5, 0xae, 0xa6, 0x2d, 0xa0, 0xab, 0xa9, 0x7c, 0x47, 0x6b, 0xd0, 0xd8, 0x66, 0xc1}, - output256: []byte{0x67, 0x98, 0xd, 0x28, 0xe2, 0xe6, 0x58, 0xe7, 0xa2, 0x4a, 0x25, 0x93, 0xa2, 0x81, 0x67, 0xa1, 0x3d, 0x90, 0x7d, 0x6, 0xf4, 0x77, 0x29, 0xd4, 0x7c, 0xa4, 0xfe, 0x17, 0x72, 0xf8, 0xb3, 0xdf}, - output384: []byte{0x75, 0xe2, 0x3f, 0xed, 0x3b, 0x59, 0xdb, 0x6b, 0x1d, 0x33, 0x78, 0xb7, 0xe8, 0x77, 0x26, 0x42, 0xcb, 0xbf, 0xf7, 0x71, 0xd, 0x8a, 0x91, 0xb2, 0x49, 0xbb, 0x6c, 0x68, 0xe3, 0x84, 0xcd, 0x41, 0x6f, 0x19, 0xac, 0x1e, 0x8e, 0xd9, 0x2b, 0x71, 0xd0, 0xca, 0x30, 0x3d, 0x24, 0x7e, 0xe9, 0xbd}, - output512: []byte{0x93, 0xa8, 0xdb, 0x85, 0x77, 0x4b, 0x32, 0x10, 0x90, 0x80, 0x1d, 0xf4, 0xdc, 0x3c, 0xc7, 0x5e, 0x94, 0xaf, 0x63, 0xff, 0x6d, 0xcf, 0x50, 0xbd, 0x21, 0xe, 0x5b, 0x65, 0xfb, 0x35, 0xe1, 0xbe, 0xae, 0xde, 0xd5, 0x56, 0x2, 0xeb, 0x32, 0x38, 0x7, 0x26, 0x2, 0x98, 0x34, 0x98, 0x2d, 0x77, 0xb4, 0x34, 0xe9, 0x41, 0x79, 0xd0, 0xa3, 0xee, 0x10, 0x59, 0x34, 0x59, 0x10, 0xee, 0x1d, 0xcc}, - }, - { - msg: []byte{0xf5, 0x7c, 0x64, 0x0, 0x6d, 0x9e, 0xa7, 0x61, 0x89, 0x2e, 0x14, 0x5c, 0x99, 0xdf, 0x1b, 0x24, 0x64, 0x8, 0x83, 0xda, 0x79, 0xd9, 0xed, 0x52, 0x62, 0x85, 0x9d, 0xcd, 0xa8, 0xc3, 0xc3, 0x2e, 0x5, 0xb0, 0x3d, 0x98, 0x4f, 0x1a, 0xb4, 0xa2, 0x30, 0x24, 0x2a, 0xb6, 0xb7, 0x8d, 0x36, 0x8d, 0xc5, 0xaa, 0xa1, 0xe6, 0xd3, 0x49, 0x8d, 0x53, 0x37, 0x1e, 0x84, 0xb0, 0xc1, 0xd4, 0xba}, - output224: []byte{0x28, 0xcf, 0xd0, 0xc6, 0xf0, 0x20, 0x8d, 0x24, 0xaa, 0xa6, 0x9e, 0x6c, 0x39, 0xf5, 0x25, 0x7c, 0x13, 0x30, 0x3e, 0x91, 0xc2, 0xd6, 0x83, 0xa9, 0xaf, 0x29, 0xb9, 0x73}, - output256: []byte{0xa8, 0xdf, 0x6b, 0x76, 0xdf, 0x41, 0x99, 0x4f, 0x75, 0x93, 0xf1, 0xa8, 0x19, 0x67, 0xe7, 0x7e, 0xe1, 0x80, 0xe3, 0x11, 0x83, 0xd1, 0xc4, 0xa5, 0x69, 0xdb, 0x85, 0x4e, 0x61, 0xe9, 0x9b, 0x5}, - output384: []byte{0xc8, 0xd1, 0xe6, 0xbe, 0x54, 0x85, 0xfc, 0x13, 0xbf, 0x43, 0x3f, 0x11, 0xa5, 0x80, 0xab, 0xbe, 0x89, 0xb1, 0x2a, 0x66, 0xd0, 0xe5, 0xcb, 0x14, 0x1e, 0x1d, 0x62, 0xcd, 0xc6, 0xa3, 0x67, 0x72, 0x57, 0x93, 0xfb, 0x25, 0x84, 0xb, 0x36, 0xcb, 0x70, 0x3, 0xf2, 0xe7, 0xdf, 0x3e, 0x5f, 0x2f}, - output512: []byte{0x3b, 0x7d, 0x98, 0xff, 0x31, 0x52, 0xb2, 0x2, 0x4a, 0xad, 0x4f, 0xa0, 0xb4, 0xd, 0xc6, 0x42, 0xe8, 0x42, 0xd4, 0x53, 0x30, 0x5e, 0xce, 0xf2, 0x78, 0x57, 0x4e, 0x38, 0x61, 0x72, 0xf3, 0xc1, 0x64, 0xe4, 0xef, 0xb9, 0xc2, 0x95, 0x1a, 0x23, 0xfc, 0x73, 0xd8, 0x3c, 0x16, 0xb4, 0x90, 0xf, 0xb9, 0x2a, 0xeb, 0x8e, 0xfe, 0x6, 0xb5, 0x8f, 0x91, 0x8b, 0xc4, 0xa4, 0x81, 0xe4, 0xc2, 0x38}, - }, - { - msg: []byte{0xe9, 0x26, 0xae, 0x8b, 0xa, 0xf6, 0xe5, 0x31, 0x76, 0xdb, 0xff, 0xcc, 0x2a, 0x6b, 0x88, 0xc6, 0xbd, 0x76, 0x5f, 0x93, 0x9d, 0x3d, 0x17, 0x8a, 0x9b, 0xde, 0x9e, 0xf3, 0xaa, 0x13, 0x1c, 0x61, 0xe3, 0x1c, 0x1e, 0x42, 0xcd, 0xfa, 0xf4, 0xb4, 0xdc, 0xde, 0x57, 0x9a, 0x37, 0xe1, 0x50, 0xef, 0xbe, 0xf5, 0x55, 0x5b, 0x4c, 0x1c, 0xb4, 0x4, 0x39, 0xd8, 0x35, 0xa7, 0x24, 0xe2, 0xfa, 0xe7}, - output224: []byte{0xc1, 0x54, 0x60, 0x7f, 0x98, 0x6f, 0x9b, 0xf9, 0x2, 0xd8, 0x31, 0x29, 0x3c, 0x83, 0x86, 0xd3, 0x6b, 0x20, 0x1e, 0xab, 0xa6, 0xf6, 0xfb, 0xb, 0x67, 0x8b, 0x4b, 0x81}, - output256: []byte{0x27, 0xa6, 0x44, 0x1e, 0xe9, 0x39, 0xb4, 0x6e, 0x2c, 0x37, 0x8d, 0x7a, 0xfe, 0xb0, 0xe8, 0x91, 0xc4, 0x7a, 0x28, 0x12, 0xe, 0x48, 0x8e, 0xff, 0xa, 0xb7, 0x1a, 0xf0, 0x87, 0x88, 0xce, 0xb3}, - output384: []byte{0x42, 0x3b, 0xa1, 0x34, 0xd3, 0xbc, 0xb5, 0xe4, 0x40, 0xac, 0x83, 0x37, 0x2c, 0x7e, 0xdd, 0xba, 0x3a, 0xe3, 0xbd, 0xdf, 0x12, 0x22, 0xf5, 0x5, 0xc1, 0x9c, 0xde, 0x24, 0x6a, 0xd7, 0x6a, 0x2b, 0xd, 0x7, 0x23, 0x9a, 0x54, 0xe1, 0xd0, 0x93, 0x4c, 0x9b, 0x3d, 0x29, 0xd4, 0x9e, 0x5f, 0xbd}, - output512: []byte{0xeb, 0x50, 0x67, 0xbf, 0x76, 0x2a, 0x29, 0x1c, 0xf2, 0x58, 0xad, 0x69, 0xa8, 0x16, 0xa0, 0xb0, 0x89, 0xe0, 0xbd, 0x44, 0xf8, 0xe5, 0xb7, 0x4c, 0xf6, 0xb, 0xce, 0x64, 0x73, 0x4e, 0x59, 0x85, 0x3c, 0xcb, 0x8d, 0x9, 0x1c, 0xd2, 0xe3, 0x3f, 0x90, 0xaa, 0x6, 0x3f, 0xb7, 0x94, 0x2c, 0xf5, 0x96, 0x5d, 0x45, 0x92, 0x0, 0x14, 0x4c, 0x1a, 0x8, 0x1, 0xab, 0xd6, 0x9a, 0x9a, 0x9, 0x4a}, - }, - { - msg: []byte{0x16, 0xe8, 0xb3, 0xd8, 0xf9, 0x88, 0xe9, 0xbb, 0x4, 0xde, 0x9c, 0x96, 0xf2, 0x62, 0x78, 0x11, 0xc9, 0x73, 0xce, 0x4a, 0x52, 0x96, 0xb4, 0x77, 0x2c, 0xa3, 0xee, 0xfe, 0xb8, 0xa, 0x65, 0x2b, 0xdf, 0x21, 0xf5, 0xd, 0xf7, 0x9f, 0x32, 0xdb, 0x23, 0xf9, 0xf7, 0x3d, 0x39, 0x3b, 0x2d, 0x57, 0xd9, 0xa0, 0x29, 0x7f, 0x7a, 0x2f, 0x2e, 0x79, 0xcf, 0xda, 0x39, 0xfa, 0x39, 0x3d, 0xf1, 0xac, 0x0}, - output224: []byte{0x95, 0xe8, 0x7a, 0xc9, 0xf, 0x54, 0x1a, 0xb9, 0xc, 0xbc, 0xf7, 0xfd, 0x7e, 0xe, 0xc, 0x15, 0x2c, 0xef, 0x78, 0xd5, 0xee, 0x18, 0x30, 0xe9, 0xed, 0x8a, 0x1e, 0xd7}, - output256: []byte{0xc4, 0xbb, 0x6, 0x73, 0x83, 0x0, 0x2d, 0xb4, 0x4c, 0xa7, 0x73, 0x91, 0x8b, 0xb7, 0x41, 0x4, 0xb6, 0x4, 0xa5, 0x83, 0xe1, 0x2b, 0x6, 0xbe, 0x56, 0xc2, 0x70, 0xf8, 0xb4, 0x35, 0x12, 0xf2}, - output384: []byte{0x66, 0x2c, 0x48, 0x51, 0xd3, 0x11, 0xa7, 0x86, 0xde, 0x4c, 0xda, 0x7e, 0x9e,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 0x9a, 0x24, 0xc0, 0x7a, 0x38, 0xfd, 0x56, 0x3a, 0xba, 0x22, 0x7f, 0xf, 0x77, 0x6e, 0xa5, 0xe2}, - output256: []byte{0xae, 0x77, 0x39, 0x15, 0xca, 0x64, 0x2d, 0x80, 0x41, 0x33, 0x30, 0xc9, 0xe0, 0xee, 0x9b, 0xd0, 0x66, 0x53, 0xc0, 0x2, 0x3c, 0x5c, 0x2, 0x77, 0x10, 0xf, 0x3b, 0x15, 0x26, 0xea, 0xa5, 0x1d}, - output384: []byte{0x5f, 0x54, 0xb1, 0xda, 0xfa, 0x67, 0xed, 0x9b, 0x49, 0x81, 0x25, 0xe0, 0x64, 0xf0, 0xb0, 0x7f, 0x54, 0xe7, 0x54, 0xe3, 0xf3, 0x7, 0x20, 0xdd, 0x4a, 0x47, 0x1e, 0x9b, 0xb6, 0xe3, 0x7, 0xf0, 0x5f, 0xb6, 0x9b, 0xc8, 0x1d, 0x39, 0x1f, 0x50, 0x3c, 0x95, 0xc3, 0xbb, 0x67, 0x1e, 0x69, 0x73}, - output512: []byte{0x83, 0x2, 0x10, 0x62, 0x11, 0x7d, 0xa9, 0x93, 0x27, 0xe5, 0x21, 0xd7, 0xc9, 0x13, 0x31, 0x20, 0x8b, 0xf3, 0xf0, 0xa9, 0x72, 0xa6, 0xc7, 0x55, 0xec, 0xa4, 0x67, 0x60, 0xc0, 0x98, 0x48, 0x71, 0xfe, 0x3, 0x72, 0x4a, 0x51, 0xfb, 0x54, 0x41, 0xc3, 0xcd, 0xd3, 0xd2, 0x4f, 0xa1, 0xb8, 0x12, 0x75, 0x10, 0xd6, 0xa4, 0x2c, 0xfe, 0x18, 0xb0, 0x8e, 0x80, 0x96, 0xed, 0x70, 0x2e, 0xf3, 0x3c}, - }, - { - msg: []byte{0xab, 0xe3, 0x47, 0x2b, 0x54, 0xe7, 0x27, 0x34, 0xbd, 0xba, 0x7d, 0x91, 0x58, 0x73, 0x64, 0x64, 0x25, 0x1c, 0x4f, 0x21, 0xb3, 0x3f, 0xbb, 0xc9, 0x2d, 0x7f, 0xac, 0x9a, 0x35, 0xc4, 0xe3, 0x32, 0x2f, 0xf0, 0x1d, 0x23, 0x80, 0xcb, 0xaa, 0x4e, 0xf8, 0xfb, 0x7, 0xd2, 0x1a, 0x21, 0x28, 0xb7, 0xb9, 0xf5, 0xb6, 0xd9, 0xf3, 0x4e, 0x13, 0xf3, 0x9c, 0x7f, 0xfc, 0x2e, 0x72, 0xe4, 0x78, 0x88, 0x59, 0x9b, 0xa5}, - output224: []byte{0x99, 0xde, 0xcb, 0x8c, 0xf1, 0xd4, 0x74, 0x97, 0xb, 0x3c, 0xfa, 0x87, 0xfa, 0x46, 0x2b, 0x75, 0xe3, 0x28, 0x7b, 0x98, 0xb4, 0xbe, 0x40, 0x93, 0x42, 0x9e, 0x22, 0xd6}, - output256: []byte{0x1c, 0xf9, 0xd6, 0xce, 0x9c, 0xb6, 0x58, 0x55, 0x6b, 0x76, 0xcd, 0x7e, 0xba, 0x3e, 0x51, 0x39, 0x36, 0x99, 0xad, 0x50, 0xb, 0x1a, 0xb3, 0xf5, 0x61, 0x72, 0x74, 0x8d, 0xb7, 0xf5, 0x96, 0x67}, - output384: []byte{0xa2, 0x1b, 0x55, 0xde, 0xd8, 0xfe, 0x41, 0xfb, 0x2b, 0x19, 0x3f, 0xa4, 0x90, 0x42, 0xa, 0x8b, 0x62, 0xfc, 0xae, 0x9a, 0x18, 0x5d, 0xa8, 0x5e, 0x25, 0x3d, 0xae, 0xfe, 0x85, 0x27, 0xb, 0x69, 0x4, 0xba, 0x4e, 0xcc, 0x76, 0xbb, 0x51, 0x28, 0x92, 0x6f, 0xff, 0x9d, 0x79, 0xf7, 0x28, 0xad}, - output512: []byte{0xbc, 0xa9, 0xf0, 0x6b, 0x6b, 0x9a, 0xb8, 0xf7, 0x6c, 0x4f, 0x3d, 0xbe, 0x67, 0x7d, 0x5b, 0x4b, 0x31, 0x3, 0x42, 0x36, 0x44, 0x48, 0x4c, 0x77, 0xcd, 0xd8, 0xc5, 0xdd, 0x6c, 0x1a, 0xb, 0xf7, 0x17, 0xc7, 0x6e, 0x83, 0xda, 0x9b, 0x2b, 0x4e, 0xdf, 0xe4, 0xcc, 0x13, 0x3c, 0x1f, 0xc8, 0x63, 0x96, 0xe8, 0xc3, 0xa9, 0xe4, 0x2f, 0xdd, 0x20, 0x51, 0x9f, 0xca, 0xa1, 0x99, 0x69, 0x18, 0x9f}, - }, - { - msg: []byte{0x36, 0xf9, 0xf0, 0xa6, 0x5f, 0x2c, 0xa4, 0x98, 0xd7, 0x39, 0xb9, 0x44, 0xd6, 0xef, 0xf3, 0xda, 0x5e, 0xbb, 0xa5, 0x7e, 0x7d, 0x9c, 0x41, 0x59, 0x8a, 0x2b, 0xe, 0x43, 0x80, 0xf3, 0xcf, 0x4b, 0x47, 0x9e, 0xc2, 0x34, 0x8d, 0x1, 0x5f, 0xfe, 0x62, 0x56, 0x27, 0x35, 0x11, 0x15, 0x4a, 0xfc, 0xf3, 0xb4, 0xb4, 0xbf, 0x9, 0xd6, 0xc4, 0x74, 0x4f, 0xdd, 0xf, 0x62, 0xd7, 0x50, 0x79, 0xd4, 0x40, 0x70, 0x6b, 0x5}, - output224: []byte{0x8c, 0x20, 0xfd, 0x3d, 0x8e, 0x8, 0x23, 0x5b, 0x1, 0x72, 0x7a, 0x4d, 0xf4, 0x4d, 0x86, 0xe7, 0x1e, 0x82, 0x4f, 0x14, 0xb0, 0xc2, 0xfe, 0x4e, 0x8d, 0xa7, 0xf1, 0xbb}, - output256: []byte{0x8d, 0x60, 0xe8, 0x89, 0xe2, 0xb1, 0x2, 0xd, 0xad, 0x4b, 0x52, 0x33, 0x1, 0xf5, 0xf6, 0xbb, 0xab, 0x6c, 0x78, 0x1a, 0xf2, 0x76, 0x8, 0x5a, 0xf6, 0x76, 0x55, 0x46, 0xfc, 0xfb, 0x95, 0xac}, - output384: []byte{0x34, 0x1b, 0xe5, 0x67, 0x7a, 0x5, 0xee, 0xd8, 0x16, 0xa2, 0x19, 0x66, 0x9d, 0x68, 0xb, 0xbf, 0x18, 0x5b, 0x31, 0xcf, 0x3e, 0xb0, 0xd2, 0x89, 0xf9, 0x2, 0x10, 0xfb, 0x1a, 0x79, 0x40, 0xd9, 0xbf, 0xf4, 0x90, 0x93, 0x20, 0xae, 0x4e, 0x3b, 0x72, 0x74, 0xe5, 0xbe, 0x47, 0x9c, 0x46, 0xf1}, - output512: []byte{0xdc, 0xdf, 0x76, 0x17, 0xf7, 0x9d, 0xa8, 0x47, 0x5b, 0x3a, 0x4d, 0xb1, 0x30, 0x6c, 0x9c, 0xaf, 0x87, 0xf1, 0xae, 0x85, 0xec, 0x97, 0x72, 0x18, 0x92, 0xd8, 0xe2, 0xd, 0xe, 0x54, 0xec, 0x82, 0xee, 0x7a, 0xf, 0x2d, 0x17, 0xf2, 0x1a, 0x61, 0xae, 0xcd, 0x89, 0xa6, 0xc4, 0xcf, 0x50, 0x19, 0xd7, 0xb8, 0x7, 0x74, 0x47, 0xef, 0xe0, 0x3d, 0xef, 0x52, 0x8, 0x1, 0xa, 0x8a, 0x1e, 0x84}, - }, - { - msg: []byte{0xab, 0xc8, 0x77, 0x63, 0xca, 0xe1, 0xca, 0x98, 0xbd, 0x8c, 0x5b, 0x82, 0xca, 0xba, 0x54, 0xac, 0x83, 0x28, 0x6f, 0x87, 0xe9, 0x61, 0x1, 0x28, 0xae, 0x4d, 0xe6, 0x8a, 0xc9, 0x5d, 0xf5, 0xe3, 0x29, 0xc3, 0x60, 0x71, 0x7b, 0xd3, 0x49, 0xf2, 0x6b, 0x87, 0x25, 0x28, 0x49, 0x2c, 0xa7, 0xc9, 0x4c, 0x2c, 0x1e, 0x1e, 0xf5, 0x6b, 0x74, 0xdb, 0xb6, 0x5c, 0x2a, 0xc3, 0x51, 0x98, 0x1f, 0xdb, 0x31, 0xd0, 0x6c, 0x77, 0xa4}, - output224: []byte{0xe2, 0x9e, 0x68, 0x43, 0x9a, 0xec, 0xde, 0x56, 0xf5, 0x29, 0x7f, 0xb9, 0x35, 0xdc, 0x7d, 0xbe, 0x63, 0xd6, 0x1c, 0xe3, 0x60, 0xa1, 0x96, 0x29, 0x19, 0x5b, 0xd8, 0xaa}, - output256: []byte{0xdd, 0x4f, 0xf4, 0xb5, 0x30, 0x55, 0x2f, 0x48, 0xaf, 0x9a, 0x75, 0x30, 0xa6, 0x46, 0x48, 0x19, 0xed, 0x1a, 0x5b, 0x73, 0x30, 0x84, 0xf7, 0x9, 0xe4, 0x1d, 0xaf, 0x1a, 0xcb, 0x35, 0xec, 0xfd}, - output384: []byte{0xd7, 0xf, 0x78, 0x89, 0x4e, 0x29, 0x2b, 0x7, 0x5a, 0xf, 0xe5, 0x6f, 0xb9, 0x52, 0xb2, 0xce, 0x87, 0xa9, 0x4c, 0xa0, 0x29, 0x34, 0x71, 0x59, 0xfb, 0xb1, 0x2b, 0x22, 0x10, 0x3d, 0xd4, 0xdc, 0x4c, 0x26, 0x5b, 0x7a, 0xe8, 0x89, 0x50, 0xcc, 0xa8, 0x9c, 0x40, 0xb5, 0x31, 0x43, 0x7a, 0xa4}, - output512: []byte{0x9b, 0x8c, 0x71, 0x42, 0x18, 0xf, 0xe, 0xd8, 0x53, 0x59, 0xb6, 0xd1, 0x86, 0xae, 0x5, 0xb7, 0x7b, 0x2d, 0xb7, 0xc3, 0xe1, 0xf0, 0x66, 0x39, 0x2e, 0x73, 0x3b, 0x7e, 0xef, 0xfd, 0x7c, 0x11, 0xf7, 0xa6, 0xc0, 0xc5, 0x70, 0x27, 0x3a, 0x1f, 0x3f, 0xea, 0x1a, 0x9, 0x29, 0xd0, 0x17, 0xc7, 0xa4, 0xfa, 0x0, 0x17, 0x5b, 0x5a, 0xba, 0x76, 0x86, 0x1b, 0xca, 0x7e, 0xe8, 0x6, 0x45, 0x8b}, - }, - { - msg: []byte{0x94, 0xf7, 0xca, 0x8e, 0x1a, 0x54, 0x23, 0x4c, 0x6d, 0x53, 0xcc, 0x73, 0x4b, 0xb3, 0xd3, 0x15, 0xc, 0x8b, 0xa8, 0xc5, 0xf8, 0x80, 0xea, 0xb8, 0xd2, 0x5f, 0xed, 0x13, 0x79, 0x3a, 0x97, 0x1, 0xeb, 0xe3, 0x20, 0x50, 0x92, 0x86, 0xfd, 0x8e, 0x42, 0x2e, 0x93, 0x1d, 0x99, 0xc9, 0x8d, 0xa4, 0xdf, 0x7e, 0x70, 0xae, 0x44, 0x7b, 0xab, 0x8c, 0xff, 0xd9, 0x23, 0x82, 0xd8, 0xa7, 0x77, 0x60, 0xa2, 0x59, 0xfc, 0x4f, 0xbd, 0x72}, - output224: []byte{0x5d, 0x21, 0x64, 0xda, 0x84, 0xe7, 0x70, 0x7c, 0xd1, 0xe7, 0x89, 0x71, 0x1a, 0x66, 0x4a, 0xb2, 0xeb, 0xcf, 0x66, 0xeb, 0xa8, 0x99, 0xa9, 0x9, 0xa1, 0xd0, 0xcb, 0xec}, - output256: []byte{0x7a, 0xc8, 0xd4, 0xbb, 0x53, 0xfc, 0x43, 0x4d, 0xd8, 0x71, 0x2d, 0xae, 0xfe, 0xb4, 0x74, 0x66, 0x8f, 0x54, 0x14, 0x18, 0xe6, 0xf6, 0x17, 0xdb, 0xa5, 0x23, 0xd8, 0x39, 0x2e, 0xb0, 0x76, 0x6e}, - output384: []byte{0x89, 0xbd, 0x6b, 0x7c, 0xc9, 0xad, 0xdd, 0xff, 0xe4, 0x6b, 0xf8, 0x5c, 0x56, 0xb8, 0xce, 0x66, 0xe1, 0xb1, 0xb4, 0x69, 0x69, 0xb1, 0x97, 0xad, 0xbf, 0x2e, 0x34, 0xb7, 0x5, 0x9d, 0x8b, 0xb0, 0x5f, 0x9f, 0x53, 0xbd, 0x1a, 0x58, 0xa7, 0xe0, 0xa6, 0x6e, 0x5e, 0xf2, 0x8, 0xbf, 0x56, 0x95}, - output512: []byte{0x3a, 0xb7, 0x3a, 0xa, 0x75, 0xb9, 0x97, 0xc0, 0xee, 0x83, 0x29, 0xc3, 0x3e, 0x6e, 0xf1, 0x38, 0x9e, 0x98, 0x21, 0x71, 0x18, 0x67, 0xf7, 0x75, 0xaf, 0x29, 0x51, 0x7e, 0xdf, 0xfb, 0xe4, 0x10, 0xd0, 0x37, 0x14, 0x3c, 0x64, 0x31, 0xfd, 0xed, 0x3d, 0x8c, 0xe7, 0x28, 0x8, 0x6c, 0x35, 0x12, 0xe9, 0x4f, 0x3, 0x8b, 0x92, 0x43, 0xb5, 0xc, 0xb8, 0x20, 0xdc, 0x24, 0x45, 0x53, 0x5d, 0x91}, - }, - { - msg: []byte{0x13, 0xbd, 0x28, 0x11, 0xf6, 0xed, 0x2b, 0x6f, 0x4, 0xff, 0x38, 0x95, 0xac, 0xee, 0xd7, 0xbe, 0xf8, 0xdc, 0xd4, 0x5e, 0xb1, 0x21, 0x79, 0x1b, 0xc1, 0x94, 0xa0, 0xf8, 0x6, 0x20, 0x6b, 0xff, 0xc3, 0xb9, 0x28, 0x1c, 0x2b, 0x30, 0x8b, 0x1a, 0x72, 0x9c, 0xe0, 0x8, 0x11, 0x9d, 0xd3, 0x6, 0x6e, 0x93, 0x78, 0xac, 0xdc, 0xc5, 0xa, 0x98, 0xa8, 0x2e, 0x20, 0x73, 0x88, 0x0, 0xb6, 0xcd, 0xdb, 0xe5, 0xfe, 0x96, 0x94, 0xad, 0x6d}, - output224: []byte{0xfa, 0x26, 0x3b, 0x9, 0x3e, 0xa3, 0xf9, 0x6b, 0x52, 0xdb, 0x62, 0x51, 0xea, 0x25, 0xa5, 0x25, 0x4a, 0xda, 0x5b, 0x54, 0xd4, 0x76, 0xcb, 0x7, 0x94, 0xd3, 0x88, 0x89}, - output256: []byte{0xf7, 0xb0, 0xe1, 0x5a, 0x63, 0x23, 0x2a, 0x2b, 0x80, 0xb, 0x23, 0xb3, 0x11, 0xd3, 0x57, 0x61, 0x7d, 0xdf, 0xd1, 0x29, 0x3e, 0x1f, 0xfe, 0x3f, 0x77, 0x26, 0x92, 0xad, 0xe3, 0x42, 0x71, 0x52}, - output384: []byte{0xae, 0x65, 0x1e, 0xf5, 0xa, 0x20, 0xb0, 0xf4, 0x96, 0xf1, 0x4, 0xf5, 0x6f, 0x84, 0x52, 0x6, 0xed, 0x54, 0x4b, 0x28, 0xd0, 0x37, 0x4c, 0xbb, 0x77, 0x91, 0x46, 0xdf, 0xf2, 0xea, 0x58, 0x94, 0xeb, 0x29, 0x30, 0x1f, 0xe3, 0x38, 0x72, 0xf9, 0xb2, 0x99, 0xa7, 0x9c, 0xc, 0xf, 0x28, 0xc4}, - output512: []byte{0xde, 0xf4, 0xab, 0x6c, 0xda, 0x88, 0x39, 0x72, 0x9a, 0x3, 0xe0, 0x0, 0x84, 0x66, 0x4, 0xb1, 0x7f, 0x3, 0xc5, 0xd5, 0xd7, 0xec, 0x23, 0xc4, 0x83, 0x67, 0xa, 0x13, 0xe1, 0x15, 0x73, 0xc1, 0xe9, 0x34, 0x7a, 0x63, 0xec, 0x69, 0xa5, 0xab, 0xb2, 0x13, 0x5, 0xf9, 0x38, 0x2e, 0xcd, 0xaa, 0xab, 0xc6, 0x85, 0xf, 0x92, 0x84, 0xe, 0x86, 0xf8, 0x8f, 0x4d, 0xab, 0xfc, 0xd9, 0x3c, 0xc0}, - }, - { - msg: []byte{0x1e, 0xed, 0x9c, 0xba, 0x17, 0x9a, 0x0, 0x9e, 0xc2, 0xec, 0x55, 0x8, 0x77, 0x3d, 0xd3, 0x5, 0x47, 0x7c, 0xa1, 0x17, 0xe6, 0xd5, 0x69, 0xe6, 0x6b, 0x5f, 0x64, 0xc6, 0xbc, 0x64, 0x80, 0x1c, 0xe2, 0x5a, 0x84, 0x24, 0xce, 0x4a, 0x26, 0xd5, 0x75, 0xb8, 0xa6, 0xfb, 0x10, 0xea, 0xd3, 0xfd, 0x19, 0x92, 0xed, 0xdd, 0xee, 0xc2, 0xeb, 0xe7, 0x15, 0xd, 0xc9, 0x8f, 0x63, 0xad, 0xc3, 0x23, 0x7e, 0xf5, 0x7b, 0x91, 0x39, 0x7a, 0xa8, 0xa7}, - output224: []byte{0xd8, 0x3, 0xe3, 0x20, 0xa9, 0x86, 0x5e, 0xbf, 0x35, 0x55, 0xe8, 0xa3, 0xe3, 0x13, 0x47, 0x68, 0xa2, 0xee, 0x1b, 0x3e, 0x59, 0xfa, 0x15, 0xf3, 0x5c, 0x2e, 0xc5, 0x50}, - output256: []byte{0xb3, 0xd0, 0x5a, 0xf7, 0xe8, 0xc4, 0x6, 0xa7, 0xc2, 0x70, 0x92, 0x23, 0x79, 0x1d, 0x3f, 0x5f, 0x4b, 0x31, 0x29, 0x32, 0x99, 0x93, 0x22, 0x0, 0x53, 0xa3, 0x62, 0x93, 0xac, 0x2b, 0xe, 0x6}, - output384: []byte{0xa8, 0x42, 0x91, 0x8d, 0xfb, 0xbf, 0x3b, 0xff, 0xcc, 0xc5, 0x27, 0xb6, 0xdd, 0x2c, 0xd, 0xf4, 0xeb, 0x3f, 0x10, 0xf, 0x6, 0x92, 0x72, 0x7d, 0xa7, 0x7d, 0xaf, 0x44, 0xa6, 0x54, 0x87, 0x60, 0x13, 0xb3, 0x70, 0x31, 0xc4, 0x93, 0xac, 0x18, 0x95, 0x0, 0x3, 0xee, 0xbd, 0x10, 0x7a, 0x29}, - output512: []byte{0xa3, 0xe1, 0x68, 0xb0, 0xd6, 0xc1, 0x43, 0xee, 0x9e, 0x17, 0xea, 0xe9, 0x29, 0x30, 0xb9, 0x7e, 0x66, 0x0, 0x35, 0x6b, 0x73, 0xae, 0xbb, 0x5d, 0x68, 0x0, 0x5d, 0xd1, 0xd0, 0x74, 0x94, 0x45, 0x1a, 0x37, 0x5, 0x2f, 0x7b, 0x39, 0xff, 0x3, 0xc, 0x1a, 0xe1, 0xd7, 0xef, 0xc4, 0xe0, 0xc3, 0x66, 0x7e, 0xb7, 0xa7, 0x6c, 0x62, 0x7e, 0xc1, 0x43, 0x54, 0xc4, 0xf6, 0xa7, 0x96, 0xe2, 0xc6}, - }, - { - msg: []byte{0xba, 0x5b, 0x67, 0xb5, 0xec, 0x3a, 0x3f, 0xfa, 0xe2, 0xc1, 0x9d, 0xd8, 0x17, 0x6a, 0x2e, 0xf7, 0x5c, 0xc, 0xd9, 0x3, 0x72, 0x5d, 0x45, 0xc9, 0xcb, 0x70, 0x9, 0xa9, 0x0, 0xc0, 0xb0, 0xca, 0x7a, 0x29, 0x67, 0xa9, 0x5a, 0xe6, 0x82, 0x69, 0xa6, 0xdb, 0xf8, 0x46, 0x6c, 0x7b, 0x68, 0x44, 0xa1, 0xd6, 0x8, 0xac, 0x66, 0x1f, 0x7e, 0xff, 0x0, 0x53, 0x8e, 0x32, 0x3d, 0xb5, 0xf2, 0xc6, 0x44, 0xb7, 0x8b, 0x2d, 0x48, 0xde, 0x1a, 0x8, 0xaa}, - output224: []byte{0x10, 0x29, 0x25, 0xb6, 0x3b, 0x3e, 0x93, 0x95, 0xf8, 0x81, 0x24, 0xc3, 0xbf, 0xa7, 0x77, 0xf2, 0x9a, 0x5b, 0x41, 0xc1, 0x3b, 0x62, 0xad, 0xd7, 0xc2, 0x71, 0xcd, 0x6e}, - output256: []byte{0x6c, 0x47, 0xe2, 0xea, 0x4b, 0xa2, 0x9e, 0x17, 0x79, 0x2d, 0xef, 0xc4, 0xb7, 0x7, 0x75, 0x4c, 0x46, 0x64, 0xbd, 0xe1, 0x51, 0x68, 0xa5, 0x10, 0xb, 0xf8, 0x81, 0xec, 0x7c, 0x2, 0xb2, 0x58}, - output384: []byte{0x20, 0xd1, 0x6c, 0xc6, 0xaf, 0x5b, 0x4d, 0x5a, 0xec, 0xce, 0xad, 0x9, 0xf3, 0x0, 0xb1, 0xdc, 0x1d, 0xa9, 0x3a, 0x60, 0x83, 0x70, 0xee, 0xb, 0x2c, 0xf1, 0x5c, 0x31, 0x65, 0x8, 0xb5, 0xef, 0x8c, 0x9b, 0xe2, 0x7d, 0xf, 0x72, 0x88, 0x61, 0x7b, 0x1e, 0x52, 0x9f, 0xc2, 0x93, 0x20, 0x38}, - output512: []byte{0x63, 0x57, 0x41, 0xb3, 0x7f, 0x66, 0xcd, 0x5c, 0xe4, 0xdb, 0xd1, 0xf7, 0x8a, 0xcc, 0xd9, 0x7, 0xf9, 0x61, 0x46, 0xe7, 0x70, 0xb2, 0x39, 0x4, 0x6a, 0xfb, 0x91, 0x81, 0x91, 0xb, 0x61, 0x2d, 0xe, 0x65, 0x84, 0x1f, 0xf8, 0x66, 0x80, 0x6e, 0xed, 0x83, 0xc3, 0xae, 0x70, 0x12, 0xfc, 0x55, 0xe4, 0x2c, 0x3f, 0xfc, 0x9c, 0x6e, 0x3d, 0x3, 0xce, 0x28, 0x70, 0x44, 0x2f, 0x29, 0x3a, 0xb4}, - }, - { - msg: []byte{0xe, 0xfa, 0x26, 0xac, 0x56, 0x73, 0x16, 0x7d, 0xca, 0xca, 0xb8, 0x60, 0x93, 0x2e, 0xd6, 0x12, 0xf6, 0x5f, 0xf4, 0x9b, 0x80, 0xfa, 0x9a, 0xe6, 0x54, 0x65, 0xe5, 0x54, 0x2c, 0xb6, 0x20, 0x75, 0xdf, 0x1c, 0x5a, 0xe5, 0x4f, 0xba, 0x4d, 0xb8, 0x7, 0xbe, 0x25, 0xb0, 0x70, 0x3, 0x3e, 0xfa, 0x22, 0x3b, 0xdd, 0x5b, 0x1d, 0x3c, 0x94, 0xc6, 0xe1, 0x90, 0x9c, 0x2, 0xb6, 0x20, 0xd4, 0xb1, 0xb3, 0xa6, 0xc9, 0xfe, 0xd2, 0x4d, 0x70, 0x74, 0x96, 0x4}, - output224: []byte{0x6c, 0x4e, 0x83, 0xcd, 0x92, 0x58, 0x20, 0x5f, 0x3c, 0x2b, 0xcf, 0x64, 0x14, 0x9f, 0x4a, 0xcd, 0xce, 0xe7, 0x74, 0x2c, 0xb2, 0xd3, 0x60, 0x38, 0x53, 0x71, 0x71, 0xbd}, - output256: []byte{0x82, 0xa6, 0x6b, 0xed, 0x66, 0x8d, 0xcc, 0x14, 0xaf, 0x12, 0xc1, 0x4c, 0x97, 0x6c,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0xd0, 0x3, 0xcf, 0xde, 0xae, 0x87, 0x7c, 0xca, 0x4d, 0xa9, 0x46, 0x5, 0xb6, 0x76, 0x91, 0x91, 0x9d, 0x8b, 0x3, 0x3f, 0x77, 0xd3, 0x84, 0xca, 0x1, 0x59, 0x3c, 0x1b}, - output224: []byte{0xc7, 0x4c, 0x9e, 0xbb, 0x2e, 0xf9, 0xa9, 0x82, 0x2a, 0x62, 0x28, 0xbd, 0x11, 0x86, 0xdc, 0xc4, 0x41, 0x1b, 0xc5, 0x9e, 0xc9, 0x38, 0xdf, 0x27, 0xe5, 0x4b, 0x8, 0x15}, - output256: []byte{0x2f, 0x21, 0xd0, 0x7d, 0x7b, 0x10, 0x68, 0x3b, 0x9a, 0xc7, 0xa6, 0x3e, 0x9f, 0xcc, 0x70, 0xcf, 0x9f, 0x88, 0x7c, 0xb9, 0x5, 0xf9, 0xbf, 0xf5, 0x33, 0x25, 0x51, 0x28, 0x8b, 0x28, 0x85, 0x24}, - output384: []byte{0xd2, 0x39, 0xf2, 0xfa, 0x16, 0x75, 0xa1, 0xa0, 0x31, 0xe2, 0xf6, 0xe8, 0xa5, 0x3d, 0x6e, 0x2f, 0x37, 0xd0, 0x81, 0xcd, 0xb0, 0x29, 0x72, 0x7b, 0x3a, 0xcb, 0xdd, 0x7c, 0xbf, 0xc7, 0xd3, 0x58, 0x1b, 0xde, 0x8d, 0x30, 0x68, 0xaa, 0x9a, 0x30, 0xa, 0xe1, 0x2b, 0x72, 0x45, 0x12, 0x45, 0x8}, - output512: []byte{0x7, 0xf0, 0xa1, 0x84, 0x73, 0x4b, 0xa4, 0xbb, 0x72, 0x1f, 0x36, 0xd7, 0xb1, 0xb3, 0x83, 0xf6, 0xbf, 0x99, 0xcd, 0x5f, 0x75, 0x94, 0x1e, 0xcf, 0x1f, 0xf2, 0xb3, 0x25, 0xf0, 0x3a, 0xf9, 0x70, 0xd1, 0xdb, 0x1f, 0x3, 0x59, 0x75, 0x70, 0x20, 0x93, 0xf5, 0x9a, 0x76, 0x10, 0xbf, 0x5, 0x4d, 0x12, 0x1, 0x7e, 0xcd, 0x61, 0x9, 0x17, 0x7c, 0xf0, 0x61, 0xab, 0x14, 0x96, 0xf8, 0x78, 0x60}, - }, - { - msg: []byte{0x90, 0x7, 0x89, 0x99, 0xfd, 0x3c, 0x35, 0xb8, 0xaf, 0xbf, 0x40, 0x66, 0xcb, 0xde, 0x33, 0x58, 0x91, 0x36, 0x5f, 0xf, 0xc7, 0x5c, 0x12, 0x86, 0xcd, 0xd8, 0x8f, 0xa5, 0x1f, 0xab, 0x94, 0xf9, 0xb8, 0xde, 0xf7, 0xc9, 0xac, 0x58, 0x2a, 0x5d, 0xbc, 0xd9, 0x58, 0x17, 0xaf, 0xb7, 0xd1, 0xb4, 0x8f, 0x63, 0x70, 0x4e, 0x19, 0xc2, 0xba, 0xa4, 0xdf, 0x34, 0x7f, 0x48, 0xd4, 0xa6, 0xd6, 0x3, 0x1, 0x3c, 0x23, 0xf1, 0xe9, 0x61, 0x1d, 0x59, 0x5e, 0xba, 0xc3, 0x7c}, - output224: []byte{0xd2, 0x34, 0x20, 0xf9, 0x98, 0x5d, 0x66, 0xf0, 0x97, 0xd4, 0x3a, 0xf, 0xb2, 0x43, 0x41, 0x49, 0xd2, 0xb3, 0x3f, 0x21, 0xb5, 0xba, 0xd6, 0xcf, 0xc2, 0x50, 0xe0, 0x72}, - output256: []byte{0x80, 0x20, 0x2f, 0x1, 0xe7, 0x14, 0xd, 0xb4, 0xfe, 0xe4, 0x90, 0xdc, 0xc5, 0xa, 0xfa, 0xfd, 0xf6, 0xa4, 0x8c, 0xa3, 0x3d, 0x36, 0x2c, 0x78, 0x75, 0xb8, 0xe8, 0xdb, 0x9c, 0x9d, 0x6, 0x55}, - output384: []byte{0x2f, 0x8d, 0x74, 0x7d, 0xdf, 0x64, 0x32, 0x2, 0x97, 0xb4, 0x4f, 0x85, 0x47, 0xef, 0x42, 0xfc, 0xe7, 0x8a, 0x48, 0xf0, 0xa5, 0x9a, 0x18, 0xdb, 0x1c, 0xfb, 0x9f, 0x43, 0xc0, 0x49, 0x62, 0x8f, 0x97, 0xc0, 0xbb, 0x93, 0xad, 0xaa, 0xb9, 0x61, 0x71, 0x55, 0x27, 0x24, 0x24, 0xf7, 0x40, 0x27}, - output512: []byte{0x89, 0x7, 0xb, 0x8b, 0x1e, 0x32, 0x2c, 0xcf, 0x9d, 0x63, 0x7, 0xed, 0xc1, 0x1f, 0xc3, 0x4e, 0x13, 0x87, 0x4c, 0x49, 0x77, 0xda, 0x9f, 0x60, 0x35, 0xd0, 0x6f, 0xaf, 0x64, 0x7d, 0x7f, 0x7d, 0x54, 0xb8, 0x25, 0xb, 0x54, 0x17, 0x44, 0x29, 0x8a, 0xac, 0xd4, 0xc5, 0x4d, 0x9b, 0x41, 0xb4, 0x8, 0x5d, 0xd3, 0x5c, 0x49, 0x1a, 0x46, 0x1d, 0x50, 0x4b, 0xdb, 0x42, 0xfc, 0x12, 0xf0, 0x3c}, - }, - { - msg: []byte{0x64, 0x10, 0x5e, 0xca, 0x86, 0x35, 0x15, 0xc2, 0xe, 0x7c, 0xfb, 0xaa, 0xa, 0xb, 0x88, 0x9, 0x4, 0x61, 0x64, 0xf3, 0x74, 0xd6, 0x91, 0xcd, 0xbd, 0x65, 0x8, 0xaa, 0xab, 0xc1, 0x81, 0x9f, 0x9a, 0xc8, 0x4b, 0x52, 0xba, 0xfc, 0x1b, 0xf, 0xe7, 0xcd, 0xdb, 0xc5, 0x54, 0xb6, 0x8, 0xc0, 0x1c, 0x89, 0x4, 0xc6, 0x69, 0xd8, 0xdb, 0x31, 0x6a, 0x9, 0x53, 0xa4, 0xc6, 0x8e, 0xce, 0x32, 0x4e, 0xc5, 0xa4, 0x9f, 0xfd, 0xb5, 0x9a, 0x1b, 0xd6, 0xa2, 0x92, 0xaa, 0xe}, - output224: []byte{0x10, 0x2e, 0xdd, 0x2e, 0x94, 0x6f, 0x33, 0xdd, 0x7a, 0xa5, 0x53, 0xea, 0x4c, 0xe4, 0xe6, 0x59, 0xc7, 0xb2, 0x40, 0xe1, 0xe2, 0x8b, 0xc6, 0x62, 0x0, 0x84, 0x5d, 0x87}, - output256: []byte{0xb2, 0x33, 0xa, 0x18, 0x90, 0x47, 0xe3, 0x11, 0x74, 0x79, 0xa2, 0xf2, 0xb, 0x34, 0x7, 0xa7, 0xd1, 0x19, 0xe4, 0xad, 0x43, 0x1f, 0xe0, 0x6f, 0xf1, 0xff, 0x2a, 0x10, 0x6f, 0x2a, 0xb3, 0xa2}, - output384: []byte{0x71, 0x4b, 0xe6, 0xf2, 0xf9, 0x34, 0xe0, 0xb6, 0xfd, 0x69, 0xe3, 0x92, 0xd9, 0x9a, 0xcc, 0x98, 0x59, 0x2b, 0x1, 0x5e, 0x48, 0xa1, 0x63, 0x72, 0x62, 0xf9, 0x92, 0x86, 0x50, 0x2b, 0x6, 0x77, 0x47, 0x83, 0xbb, 0x9f, 0x37, 0x1c, 0x76, 0xc, 0x3e, 0xb7, 0x8a, 0xea, 0xdf, 0xbd, 0xd, 0xf0}, - output512: []byte{0x6c, 0x3f, 0xbe, 0x32, 0x55, 0x64, 0x45, 0xda, 0xd4, 0x30, 0xcf, 0x15, 0xfe, 0x12, 0x43, 0xb6, 0xab, 0x44, 0x34, 0x9e, 0xec, 0x2b, 0xe1, 0x13, 0x2b, 0x6, 0x80, 0xe5, 0xed, 0xf0, 0xb0, 0x8b, 0x55, 0xf1, 0xab, 0xe4, 0x73, 0x43, 0x9c, 0x5e, 0x7, 0x50, 0x13, 0x29, 0x96, 0x19, 0x5f, 0xd1, 0x20, 0xc2, 0x67, 0xb9, 0x10, 0xc, 0x47, 0x77, 0x7b, 0x33, 0x91, 0x32, 0xec, 0x34, 0xcc, 0x80}, - }, - { - msg: []byte{0xd4, 0x65, 0x4b, 0xe2, 0x88, 0xb9, 0xf3, 0xb7, 0x11, 0xc2, 0xd0, 0x20, 0x15, 0x97, 0x8a, 0x8c, 0xc5, 0x74, 0x71, 0xd5, 0x68, 0xa, 0x9, 0x2a, 0xa5, 0x34, 0xf7, 0x37, 0x2c, 0x71, 0xce, 0xaa, 0xb7, 0x25, 0xa3, 0x83, 0xc4, 0xfc, 0xf4, 0xd8, 0xde, 0xaa, 0x57, 0xfc, 0xa3, 0xce, 0x5, 0x6f, 0x31, 0x29, 0x61, 0xec, 0xcf, 0x9b, 0x86, 0xf1, 0x49, 0x81, 0xba, 0x5b, 0xed, 0x6a, 0xb5, 0xb4, 0x49, 0x8e, 0x1f, 0x6c, 0x82, 0xc6, 0xca, 0xe6, 0xfc, 0x14, 0x84, 0x5b, 0x3c, 0x8a}, - output224: []byte{0x7c, 0x8e, 0xb9, 0x8b, 0x73, 0x38, 0x40, 0x3c, 0x1, 0x3d, 0x65, 0xc0, 0xb5, 0xbb, 0x4b, 0x5d, 0x2c, 0xbf, 0x53, 0x9c, 0xb1, 0x10, 0x9c, 0xf4, 0x47, 0xfa, 0x66, 0x50}, - output256: []byte{0xbb, 0x9b, 0x9b, 0xb6, 0x85, 0xc2, 0x41, 0xf8, 0xd6, 0x3f, 0xdb, 0xf0, 0xdb, 0xaa, 0xbc, 0xef, 0x70, 0x75, 0xad, 0xd7, 0xba, 0x40, 0x5a, 0x2f, 0xff, 0xe7, 0xad, 0x5b, 0x23, 0xe0, 0x21, 0xc7}, - output384: []byte{0x22, 0xa4, 0x1b, 0x11, 0x74, 0x64, 0xf7, 0xf4, 0x96, 0x82, 0xe8, 0x13, 0x9a, 0xd, 0x5b, 0xd2, 0x3f, 0xe0, 0xd, 0x11, 0x90, 0xb1, 0xb4, 0x19, 0xf2, 0x7b, 0x49, 0xb, 0x72, 0x9b, 0x56, 0xbb, 0xa9, 0xde, 0x64, 0x9d, 0xd7, 0xc9, 0x88, 0xb6, 0xb3, 0x8, 0x3, 0x86, 0x61, 0xe1, 0xc3, 0x62}, - output512: []byte{0x6a, 0xe3, 0xe6, 0x56, 0xcf, 0x94, 0xdb, 0x10, 0xae, 0x3c, 0x18, 0x53, 0x62, 0xa6, 0x62, 0x5c, 0xec, 0x53, 0xe0, 0xba, 0x4d, 0xc7, 0xd1, 0x60, 0x8a, 0x3f, 0x2f, 0xca, 0x3c, 0x4f, 0x31, 0xf8, 0x9f, 0xe1, 0xb0, 0x6f, 0xe9, 0xca, 0x34, 0x5e, 0x3f, 0x5e, 0x96, 0x7a, 0x3e, 0xbc, 0xf6, 0xa1, 0xa1, 0x6e, 0x24, 0x52, 0x1d, 0x5c, 0x46, 0x90, 0xd9, 0xb6, 0x42, 0x48, 0x3a, 0xc7, 0xa8, 0x96}, - }, - { - msg: []byte{0x12, 0xd9, 0x39, 0x48, 0x88, 0x30, 0x5a, 0xc9, 0x6e, 0x65, 0xf2, 0xbf, 0xe, 0x1b, 0x18, 0xc2, 0x9c, 0x90, 0xfe, 0x9d, 0x71, 0x4d, 0xd5, 0x9f, 0x65, 0x1f, 0x52, 0xb8, 0x8b, 0x30, 0x8, 0xc5, 0x88, 0x43, 0x55, 0x48, 0x6, 0x6e, 0xa2, 0xfc, 0x4c, 0x10, 0x11, 0x18, 0xc9, 0x1f, 0x32, 0x55, 0x62, 0x24, 0xa5, 0x40, 0xde, 0x6e, 0xfd, 0xdb, 0xca, 0x29, 0x6e, 0xf1, 0xfb, 0x0, 0x34, 0x1f, 0x5b, 0x1, 0xfe, 0xcf, 0xc1, 0x46, 0xbd, 0xb2, 0x51, 0xb3, 0xbd, 0xad, 0x55, 0x6c, 0xd2}, - output224: []byte{0xc7, 0xb0, 0x7d, 0xe9, 0x1e, 0xfc, 0xe4, 0x2d, 0xab, 0x78, 0x19, 0x9e, 0xe2, 0xeb, 0x30, 0x14, 0xa4, 0x94, 0x99, 0x42, 0x36, 0xa1, 0x2b, 0x3d, 0xe2, 0x33, 0xc, 0x25}, - output256: []byte{0xf8, 0x31, 0x6a, 0x36, 0x7a, 0xa0, 0x31, 0x6d, 0xa3, 0x56, 0x2f, 0x31, 0x9d, 0x52, 0x2e, 0x81, 0xf4, 0xa8, 0xbd, 0x2e, 0x21, 0x8, 0xd2, 0x53, 0x21, 0x26, 0xf4, 0xa9, 0x3, 0x70, 0x4b, 0xa3}, - output384: []byte{0x77, 0x78, 0xf, 0x36, 0x46, 0xd2, 0x88, 0x29, 0x17, 0x90, 0xf2, 0xa5, 0xf4, 0xaa, 0x9c, 0x98, 0xa6, 0x4a, 0x11, 0x15, 0x30, 0x69, 0x94, 0xcd, 0x65, 0xc7, 0x62, 0xd, 0xde, 0x6, 0xd3, 0x51, 0x17, 0xce, 0x4b, 0x79, 0xda, 0xe0, 0x8b, 0x5b, 0x4e, 0x79, 0x84, 0x59, 0x1, 0x9, 0x41, 0xbb}, - output512: []byte{0xad, 0xa8, 0xe7, 0x8c, 0xe3, 0xe6, 0xd4, 0x47, 0xba, 0x2b, 0x7d, 0xcf, 0x98, 0x71, 0x8f, 0xe7, 0xd4, 0x3b, 0x38, 0xd6, 0x81, 0x17, 0xe5, 0x77, 0x9a, 0x41, 0xed, 0xd8, 0xfa, 0x72, 0x19, 0x8e, 0x3b, 0x3c, 0x1c, 0x2, 0x15, 0x92, 0x5b, 0xc9, 0xd0, 0x7, 0xfd, 0x2c, 0x35, 0x5e, 0xdd, 0x66, 0x8a, 0xc, 0x27, 0xef, 0xf, 0xf8, 0x9f, 0x76, 0xcf, 0x85, 0x36, 0x3d, 0x4c, 0x9e, 0xe0, 0x1}, - }, - { - msg: []byte{0x87, 0x1a, 0xd, 0x7a, 0x5f, 0x36, 0xc3, 0xda, 0x1d, 0xfc, 0xe5, 0x7a, 0xcd, 0x8a, 0xb8, 0x48, 0x7c, 0x27, 0x4f, 0xad, 0x33, 0x6b, 0xc1, 0x37, 0xeb, 0xd6, 0xff, 0x46, 0x58, 0xb5, 0x47, 0xc1, 0xdc, 0xfa, 0xb6, 0x5f, 0x3, 0x7a, 0xa5, 0x8f, 0x35, 0xef, 0x16, 0xaf, 0xf4, 0xab, 0xe7, 0x7b, 0xa6, 0x1f, 0x65, 0x82, 0x6f, 0x7b, 0xe6, 0x81, 0xb5, 0xb6, 0xd5, 0xa1, 0xea, 0x80, 0x85, 0xe2, 0xae, 0x9c, 0xd5, 0xcf, 0x9, 0x91, 0x87, 0x8a, 0x31, 0x1b, 0x54, 0x9a, 0x6d, 0x6a, 0xf2, 0x30}, - output224: []byte{0x2f, 0xce, 0xf2, 0x59, 0x4a, 0xe8, 0x55, 0xde, 0x4f, 0xc6, 0x6d, 0xcc, 0xc5, 0x17, 0xa6, 0x59, 0x11, 0x8b, 0x3a, 0x9f, 0x2e, 0x5f, 0xe6, 0x38, 0x98, 0xa, 0xdb, 0xfb}, - output256: []byte{0x89, 0xe3, 0xeb, 0xd0, 0x2b, 0x22, 0x9c, 0xd7, 0x59, 0x61, 0x2a, 0x55, 0x21, 0xd8, 0x67, 0xab, 0x2a, 0x15, 0x94, 0xbc, 0xb, 0x1f, 0xe6, 0xa7, 0x8b, 0x79, 0x54, 0xcc, 0xc8, 0x4c, 0xaf, 0x3}, - output384: []byte{0x5c, 0xed, 0x3b, 0x73, 0x68, 0x58, 0x2d, 0xd6, 0xde, 0xbf, 0xe4, 0x1d, 0x6a, 0xff, 0xd8, 0x2b, 0x72, 0x89, 0x4b, 0x51, 0xff, 0x4c, 0x4a, 0xcc, 0xba, 0x9, 0xc5, 0x95, 0xb3, 0x6e, 0x23, 0xe3, 0x47, 0xab, 0x4b, 0xaa, 0xb0, 0xe5, 0x19, 0x1d, 0x86, 0xe2, 0x6e, 0x65, 0x96, 0xd6, 0x2e, 0x23}, - output512: []byte{0x35, 0x69, 0xd9, 0xa0, 0x8d, 0xfb, 0x0, 0x1, 0xbe, 0x71, 0x39, 0x40, 0xc4, 0x64, 0xc1, 0x19, 0xf5, 0xa4, 0xc1, 0xb9, 0xff, 0x97, 0xd8, 0x29, 0x7d, 0x4, 0xc7, 0xb2, 0xdc, 0xe2, 0xd6, 0x84, 0xae, 0xe1, 0x64, 0x43, 0xc3, 0x2e, 0x5b, 0xb2, 0x35, 0x5a, 0xc8, 0xa3, 0x36, 0x24, 0x9d, 0x1b, 0xaa, 0xea, 0xb4, 0xfb, 0xd0, 0x4a, 0xb9, 0x82, 0xd6, 0xb1, 0x78, 0xdd, 0xa, 0x5b, 0x5b, 0xc8}, - }, - { - msg: []byte{0xe9, 0xb, 0x4f, 0xfe, 0xf4, 0xd4, 0x57, 0xbc, 0x77, 0x11, 0xff, 0x4a, 0xa7, 0x22, 0x31, 0xca, 0x25, 0xaf, 0x6b, 0x2e, 0x20, 0x6f, 0x8b, 0xf8, 0x59, 0xd8, 0x75, 0x8b, 0x89, 0xa7, 0xcd, 0x36, 0x10, 0x5d, 0xb2, 0x53, 0x8d, 0x6, 0xda, 0x83, 0xba, 0xd5, 0xf6, 0x63, 0xba, 0x11, 0xa5, 0xf6, 0xf6, 0x1f, 0x23, 0x6f, 0xd5, 0xf8, 0xd5, 0x3c, 0x5e, 0x89, 0xf1, 0x83, 0xa3, 0xce, 0xc6, 0x15, 0xb5, 0xc, 0x7c, 0x68, 0x1e, 0x77, 0x3d, 0x10, 0x9f, 0xf7, 0x49, 0x1b, 0x5c, 0xc2, 0x22, 0x96, 0xc5}, - output224: []byte{0xd4, 0x58, 0x73, 0xf0, 0x45, 0x3c, 0xbf, 0x38, 0x15, 0x6a, 0x13, 0x84, 0xe3, 0x3e, 0x5c, 0x76, 0x58, 0x8b, 0x7b, 0xfb, 0x48, 0xa7, 0x9, 0xb3, 0x94, 0x3d, 0x91, 0x86}, - output256: []byte{0x2e, 0x7c, 0xc8, 0x75, 0x30, 0x5e, 0xa6, 0xbb, 0x9c, 0x2f, 0xc7, 0x70, 0xb9, 0xd8, 0x4f, 0xd9, 0x3b, 0x96, 0x40, 0x5d, 0xf9, 0xb9, 0x33, 0x7, 0xf6, 0xb5, 0xde, 0x26, 0xe1, 0x35, 0x72, 0x4c}, - output384: []byte{0x14, 0x10, 0xef, 0x9a, 0xbb, 0x8d, 0x98, 0xb1, 0xc6, 0x5e, 0x11, 0x3a, 0x61, 0x91, 0x5b, 0xe, 0x69, 0x33, 0xbc, 0x59, 0xda, 0x31, 0xc8, 0xfc, 0xc3, 0x9b, 0x71, 0x65, 0xe7, 0x15, 0x91, 0x91, 0x84, 0x37, 0x5d, 0x82, 0x2a, 0x7, 0xc7, 0x78, 0xf6, 0x34, 0x31, 0xbe, 0x2a, 0xee, 0xcd, 0x99}, - output512: []byte{0x13, 0x43, 0xe3, 0xcd, 0x16, 0x2d, 0x79, 0x86, 0x43, 0x1b, 0xab, 0xe6, 0x63, 0x83, 0xb8, 0x40, 0x29, 0x66, 0x56, 0x91, 0xe3, 0x6c, 0xaf, 0x97, 0xcd, 0xac, 0xa1, 0x7e, 0xe9, 0xe9, 0x7d, 0x74, 0x20, 0x1d, 0x2a, 0x82, 0x8d, 0x72, 0xe9, 0xfb, 0xbd, 0x5e, 0x7, 0x83, 0x1d, 0x90, 0xf0, 0x9e, 0xaf, 0x3c, 0x86, 0x3b, 0xd1, 0x2, 0xcd, 0xb1, 0xed, 0xeb, 0xc8, 0xad, 0x58, 0xa5, 0x3e, 0xce}, - }, - { - msg: []byte{0xe7, 0x28, 0xde, 0x62, 0xd7, 0x58, 0x56, 0x50, 0xc, 0x4c, 0x77, 0xa4, 0x28, 0x61, 0x2c, 0xd8, 0x4, 0xf3, 0xc, 0x3f, 0x10, 0xd3, 0x6f, 0xb2, 0x19, 0xc5, 0xca, 0xa, 0xa3, 0x7, 0x26, 0xab, 0x19, 0xe, 0x5f, 0x3f, 0x27, 0x9e, 0x7, 0x33, 0xd7, 0x7e, 0x72, 0x67, 0xc1, 0x7b, 0xe2, 0x7d, 0x21, 0x65, 0xa, 0x9a, 0x4d, 0x1e, 0x32, 0xf6, 0x49, 0x62, 0x76, 0x38, 0xdb, 0xad, 0xa9, 0x70, 0x2c, 0x7c, 0xa3, 0x3, 0x26, 0x9e, 0xd1, 0x40, 0x14, 0xb2, 0xf3, 0xcf, 0x8b, 0x89, 0x4e, 0xac, 0x85, 0x54}, - output224: []byte{0x35, 0x43, 0xad, 0xd5, 0xb7, 0xed, 0xfc, 0x83, 0xaf, 0xe7, 0xc1, 0xf2, 0xd5, 0x51, 0x40, 0xae, 0xdb, 0x85, 0x83, 0x4, 0x62, 0x81, 0x9, 0xfd, 0x7, 0x7b, 0x38, 0x60}, - output256: []byte{0xec, 0xab, 0x75, 0xf2, 0x8a, 0x72, 0x84, 0x29, 0xcb, 0x43, 0x3e, 0xc1, 0x33, 0x10, 0xd1, 0xb8, 0x50, 0xcc, 0xf5, 0x22, 0xc3, 0x8d, 0x2f, 0xa6, 0xdf, 0xa4, 0x89, 0x96, 0x3d, 0x6d, 0x6c, 0xa7}, - output384: []byte{0x33, 0xe, 0xd5, 0x1b, 0x4, 0x54, 0x71, 0xde, 0xa8, 0xcf, 0xf2, 0x65, 0x10, 0xd6, 0x84, 0x94, 0x61, 0x1e, 0xcf, 0xd6, 0x14, 0xd4, 0x9e, 0x5a, 0x9c, 0xc8, 0x84, 0x6a, 0x13, 0x25, 0x19, 0xbb, 0xcf, 0x49, 0x90, 0x76, 0x91, 0xac, 0x5a, 0xcc, 0xfc, 0x5, 0x28, 0xda, 0xc, 0x14, 0xd4, 0x9e}, - output512: []byte{0xbb, 0xa0, 0x1d, 0xbe, 0xa9, 0x66, 0xf, 0x9c, 0x2a, 0xd7, 0x44, 0x60, 0xb6, 0x7a, 0x82, 0x44, 0x7, 0x1, 0xeb, 0x99, 0x51, 0x43, 0xff, 0xcf, 0x74, 0x34, 0xb5, 0xd2, 0xde, 0x4e, 0x35, 0xc8, 0x2c, 0xc7, 0x57, 0xdf, 0x77, 0x6d, 0x46, 0x19, 0x9d, 0xd8, 0xe7, 0x35, 0x5a, 0xeb, 0x1f, 0x42, 0xa8, 0x8f, 0x6f, 0xb, 0xb5, 0xf, 0xd2, 0x39, 0xc7, 0x38, 0x98, 0x15, 0x6e, 0x4d, 0xdb, 0xbc}, - }, - { - msg: []byte{0x63, 0x48, 0xf2, 0x29, 0xe7, 0xb1, 0xdf, 0x3b, 0x77, 0xc, 0x77, 0x54, 0x4e, 0x51, 0x66, 0xe0, 0x81, 0x85, 0xf, 0xa1, 0xc6, 0xc8, 0x81, 0x69, 0xdb, 0x74, 0xc7, 0x6e, 0x42, 0xeb, 0x98, 0x3f, 0xac, 0xb2, 0x76, 0xad, 0x6a, 0xd, 0x1f, 0xa7, 0xb5, 0xd, 0x3e, 0x3b, 0x6f, 0xcd, 0x79, 0x9e, 0xc9, 0x74, 0x70, 0x92, 0xa, 0x7a, 0xbe, 0xd4, 0x7d, 0x28, 0x8f, 0xf8, 0x83, 0xe2, 0x4c, 0xa2, 0x1c, 0x7f, 0x80, 0x16, 0xb9, 0x3b, 0xb9, 0xb9, 0xe0, 0x78, 0xbd, 0xb9, 0x70, 0x3d, 0x2b, 0x78, 0x1b, 0x61, 0x6e}, - output224: []byte{0x36, 0x78, 0x4f, 0x11, 0x49, 0x58, 0xd8, 0xb5, 0xb6, 0x25, 0xdd, 0x89, 0xa4, 0xe3, 0x97, 0x3a, 0x11, 0x3e, 0x5d, 0x16, 0x10, 0xdf, 0xa5, 0x5b, 0x4f, 0xb4, 0x5a, 0xec}, - output256: []byte{0x2, 0x1c, 0x94, 0x59, 0xd1, 0x45, 0x1f, 0x3d, 0xa4, 0xc0, 0x7c, 0x2, 0x9a, 0x86, 0x81, 0x94, 0x5c, 0x87, 0xc5, 0xbe, 0xbc, 0x6c, 0x30, 0xda, 0x1d, 0x95, 0xc5, 0xc4, 0x9d, 0x8a, 0xb9, 0x5c}, - output384: []byte{0x38, 0x71, 0x11, 0xa2, 0x6, 0xfc, 0x64, 0x88, 0xf7, 0x8d, 0x41, 0x78, 0x68, 0x86, 0xa9, 0xe5, 0xec, 0x9f, 0x73, 0xe1, 0x13, 0x1d, 0x92, 0xf2, 0x90, 0xf6, 0x85, 0x12, 0x32, 0xa, 0x40, 0x8d, 0x5f, 0x63, 0xea, 0xa5, 0xab, 0xa3, 0x2d, 0x98, 0x53, 0xeb, 0x11, 0xb5, 0xb0, 0x88, 0x7e, 0x62}, - output512: []byte{0x32, 0x68, 0xbc, 0x24, 0xe2, 0x93, 0x92, 0xdd, 0xa1, 0x67, 0x7b, 0x7a, 0x3c, 0xe3, 0x11, 0x19, 0x94, 0x48, 0x2d, 0x17, 0xba, 0xd1, 0xc1, 0x50, 0xac, 0x88, 0x5f, 0x1d, 0x29, 0xc3, 0x8, 0x65, 0x7c, 0x69, 0xfd, 0x4f, 0x7c, 0xe5, 0x96, 0x7d, 0x4, 0xfc, 0xcb, 0x92, 0xd, 0xac, 0xb0, 0xd, 0xc, 0xe0, 0x95, 0x36, 0xee, 0x92, 0xa6, 0x66, 0x4c, 0xb2, 0xe, 0x69, 0x2d, 0x91, 0xd8, 0xce}, - }, - { - msg: []byte{0x4b, 0x12, 0x7f, 0xde, 0x5d, 0xe7, 0x33, 0xa1, 0x68, 0xc, 0x27, 0x90, 0x36, 0x36, 0x27, 0xe6, 0x3a, 0xc8, 0xa3, 0xf1, 0xb4, 0x70, 0x7d, 0x98, 0x2c, 0xae, 0xa2, 0x58, 0x65, 0x5d, 0x9b, 0xf1, 0x8f, 0x89, 0xaf, 0xe5, 0x41, 0x27, 0x48, 0x2b, 0xa0, 0x1e, 0x8, 0x84, 0x55, 0x94, 0xb6, 0x71, 0x30, 0x6a, 0x2, 0x5c, 0x9a, 0x5c, 0x5b, 0x6f, 0x93, 0xb0, 0xa3, 0x95, 0x22, 0xdc, 0x87, 0x74, 0x37, 0xbe, 0x5c, 0x24, 0x36, 0xcb, 0xf3, 0x0, 0xce, 0x7a, 0xb6, 0x74, 0x79, 0x34, 0xfc, 0xfc, 0x30, 0xae, 0xaa, 0xf6}, - output224: []byte{0x41, 0x87, 0xfe, 0xae, 0xd4, 0xfb, 0xd3, 0xd5, 0x5, 0xa9, 0x6a, 0x8d, 0x60, 0x66, 0x8a, 0x88, 0x17, 0x2e, 0x4f, 0x7c, 0x84, 0x51, 0xa4, 0xa6, 0x80, 0x2c, 0x57, 0x47}, - output256: []byte{0x46, 0x42, 0xe2, 0x16, 0x22, 0xf1, 0x5b, 0x9, 0xb9, 0x41, 0x36, 0x59, 0x68, 0x1, 0x16, 0xbf, 0x2f, 0x96, 0xca, 0xc2, 0x38, 0x4b, 0x8c, 0x79, 0xf1, 0x32, 0x8d, 0x5d, 0xd3, 0x6d, 0x7a, 0x1}, - output384: []byte{0x78, 0x57, 0x3f, 0x5d, 0x7, 0x52, 0x0, 0xd3, 0x82, 0x31, 0x94, 0xa7, 0x1e, 0x55, 0x88, 0xf, 0x4f, 0xe7, 0x84, 0x89, 0x23, 0x4d, 0xbf, 0x3d, 0xf3, 0xe3, 0x73, 0x4c, 0xbc, 0xae, 0x8d, 0xc1, 0xd8, 0xc1, 0xae, 0x95, 0xf9, 0xef, 0xa9, 0x90, 0x3d, 0xc4, 0xc4, 0x58, 0x1b, 0x59, 0xdd, 0xde}, - output512: []byte{0xec, 0x13, 0xe3, 0x90, 0xfa, 0x65, 0xfd, 0xc1, 0x10, 0x54, 0xe3, 0x2c, 0x9f, 0x5b, 0xf5, 0xe6, 0xe9, 0x7f, 0xbc, 0x34, 0xc2, 0x80, 0x89, 0x34, 0x6f, 0xf2, 0x2d, 0x97, 0x62, 0xbe, 0xbf, 0x6a, 0x14, 0xfa, 0x7f, 0x9c, 0x2e, 0x66, 0x43, 0xd1, 0xed, 0x7e, 0xc6, 0x92, 0x5d, 0xf, 0xa2, 0x9, 0x8f, 0x81, 0x49, 0x5, 0x8e, 0x99, 0xd0, 0x2a, 0xd5, 0xcb, 0x61, 0xb4, 0xcc, 0xba, 0x64, 0x67}, - }, - { - msg: []byte{0x8, 0x46, 0x1f, 0x0, 0x6c, 0xff, 0x4c, 0xc6, 0x4b, 0x75, 0x2c, 0x95, 0x72, 0x87, 0xe5, 0xa0, 0xfa, 0xab, 0xc0, 0x5c, 0x9b, 0xff, 0x89, 0xd2, 0x3f, 0xd9, 0x2, 0xd3, 0x24, 0xc7, 0x99, 0x3, 0xb4, 0x8f, 0xcb, 0x8f, 0x8f, 0x4b, 0x1, 0xf3, 0xe4, 0xdd, 0xb4, 0x83, 0x59, 0x3d, 0x25, 0xf0, 0x0, 0x38, 0x66, 0x98, 0xf5, 0xad, 0xe7, 0xfa, 0xad, 0xe9, 0x61, 0x5f, 0xdc, 0x50, 0xd3, 0x27, 0x85, 0xea, 0x51, 0xd4, 0x98, 0x94, 0xe4, 0x5b, 0xaa, 0x3d, 0xc7, 0x7, 0xe2, 0x24, 0x68, 0x8c, 0x64, 0x8, 0xb6, 0x8b, 0x11}, - output224: []byte{0x6e, 0x47, 0x66, 0xdb, 0x4e, 0x9d, 0x11, 0x2, 0xce, 0xe6, 0xdf, 0xe0, 0xae, 0x22, 0x21, 0x32, 0x1b, 0x9c, 0xf, 0xe7, 0x7, 0xf0, 0xa7, 0x82, 0x5d, 0x75, 0x57, 0xec}, - output256: []byte{0x8d, 0xaa, 0x47, 0xc3, 0x57, 0x21, 0x57, 0x26, 0x6a, 0xd0, 0x27, 0x6d, 0x59, 0x26, 0xaf, 0xf2, 0x87, 0x2f, 0x6, 0xb0, 0xcd, 0x7b, 0x97, 0x4a, 0x80, 0xd7, 0xa6, 0x82, 0x7d, 0x41, 0xd7, 0x82}, - output384: []byte{0xfd, 0xfe, 0x4f, 0x1b, 0x3, 0x47, 0x33, 0xc2, 0xc9, 0x4a, 0x7b, 0x36, 0xe2, 0xb5, 0x27, 0x74, 0xa9, 0x5c, 0x2b, 0xde, 0x22, 0xfc, 0xdd, 0xfc, 0xef, 0x52, 0xf7, 0xfe, 0xf7, 0xc6, 0x7f, 0x8, 0xe2, 0xf7, 0xb9, 0xb8, 0x96, 0x7e, 0x44, 0x7f, 0x76, 0xef, 0x91, 0x96, 0xd, 0xa7, 0x62, 0x88}, - output512: []byte{0x6f, 0xd5, 0xa3, 0x34, 0xd4, 0xb7, 0xf9, 0xc7, 0x2a, 0x8d, 0xb1, 0x29, 0x2c, 0xc8, 0xf1, 0x9b, 0xf2, 0xa0, 0xf, 0x5c, 0x22, 0x6c, 0x16, 0x36, 0x24, 0x80, 0x24, 0x72, 0x3c, 0xb8, 0x76, 0x7, 0xa, 0x96, 0x57, 0xf4, 0x8a, 0xb3, 0xb1, 0xd4, 0x22, 0x92, 0x2, 0xb7, 0xbb, 0xc6, 0x40, 0x53, 0xa4, 0x8c, 0x3f, 0xf6, 0xb9, 0x3a, 0xb1, 0x1a, 0x2a, 0xf3, 0x23, 0x77, 0x21, 0xc9, 0xcc, 0x9}, - }, - { - msg: []byte{0x68, 0xc8, 0xf8, 0x84, 0x9b, 0x12, 0xe, 0x6e, 0xc, 0x99, 0x69, 0xa5, 0x86, 0x6a, 0xf5, 0x91, 0xa8, 0x29, 0xb9, 0x2f, 0x33, 0xcd, 0x9a, 0x4a, 0x31, 0x96, 0x95, 0x7a, 0x14, 0x8c, 0x49, 0x13, 0x8e, 0x1e, 0x2f, 0x5c, 0x76, 0x19, 0xa6, 0xd5, 0xed, 0xeb, 0xe9, 0x95, 0xac, 0xd8, 0x1e, 0xc8, 0xbb, 0x9c, 0x7b, 0x9c, 0xfc, 0xa6, 0x78, 0xd0, 0x81, 0xea, 0x9e, 0x25, 0xa7, 0x5d, 0x39, 0xdb, 0x4, 0xe1, 0x8d, 0x47, 0x59, 0x20, 0xce, 0x82, 0x8b, 0x94, 0xe7, 0x22, 0x41, 0xf2, 0x4d, 0xb7, 0x25, 0x46, 0xb3, 0x52, 0xa0, 0xe4}, - output224: []byte{0xe1, 0xfc, 0x97, 0x2b, 0xfb, 0x29, 0x41, 0x85, 0xf1, 0x98, 0xc, 0xa2, 0x93, 0x86, 0x55, 0xfb, 0x58, 0x3e, 0x81, 0x2a, 0xd3, 0xd6, 0x4f, 0xa5, 0xa4, 0xcf, 0x70, 0x3e}, - output256: []byte{0x34, 0x53, 0x65, 0x23, 0x2c, 0xe9, 0xaf, 0xc6, 0x55, 0xdc, 0xe4, 0xba, 0xc2, 0x3f, 0x43, 0xc8, 0xac, 0xbd, 0xf9, 0x1, 0x6d, 0x4b, 0xc2, 0x34, 0x4b, 0xe8, 0xd3, 0x96, 0xa4, 0x91, 0x9c, 0x34}, - output384: []byte{0x48, 0xd6, 0x6a, 0x41, 0x65, 0xaa, 0x54, 0x52, 0x8e, 0xce, 0x89, 0xbd, 0x9a, 0xa0, 0xe, 0xab, 0x19, 0x6f, 0x32, 0xdf, 0xdc, 0x4d, 0x76, 0xf2, 0x36, 0x65, 0x58, 0x35, 0x52, 0x7a, 0xaa, 0x16, 0x42, 0xe6, 0xbf, 0x4e, 0xdf, 0x24, 0xf0, 0x30, 0xf5, 0xee, 0xef, 0x7, 0xfa, 0x40, 0xf5, 0xd2}, - output512: []byte{0x1, 0x6c, 0x80, 0xcb, 0xab, 0xed, 0x7, 0xc5, 0xf, 0x2c, 0x1b, 0x67, 0x7c, 0x43, 0xe5, 0x2d, 0xe8, 0xd1, 0x17, 0x51, 0xe5, 0x4e, 0x59, 0x6e, 0xc, 0x4, 0xb3, 0x83, 0x7a, 0x7e, 0x34, 0xa9, 0xff, 0x5d, 0x2e, 0x98, 0xe7, 0xc5, 0x81, 0x82, 0x87, 0x9c, 0x15, 0x84, 0x7d, 0x18, 0xdc, 0xe8, 0x8e, 0xa9, 0x0, 0x33, 0x7b, 0xc4, 0x48, 0x11, 0x2e, 0x98, 0xce, 0x11, 0x18, 0x82, 0xc, 0x58}, - }, - { - msg: []byte{0xb8, 0xd5, 0x64, 0x72, 0x95, 0x4e, 0x31, 0xfb, 0x54, 0xe2, 0x8f, 0xca, 0x74, 0x3f, 0x84, 0xd8, 0xdc, 0x34, 0x89, 0x1c, 0xb5, 0x64, 0xc6, 0x4b, 0x8, 0xf7, 0xb7, 0x16, 0x36, 0xde, 0xbd, 0x64, 0xca, 0x1e, 0xdb, 0xdb, 0xa7, 0xfc, 0x5c, 0x3e, 0x40, 0x4, 0x9c, 0xe9, 0x82, 0xbb, 0xa8, 0xc7, 0xe0, 0x70, 0x30, 0x34, 0xe3, 0x31, 0x38, 0x46, 0x95, 0xe9, 0xde, 0x76, 0xb5, 0x10, 0x4f, 0x2f, 0xbc, 0x45, 0x35, 0xec, 0xbe, 0xeb, 0xc3, 0x3b, 0xc2, 0x7f, 0x29, 0xf1, 0x8f, 0x6f, 0x27, 0xe8, 0x2, 0x3b, 0xf, 0xbb, 0x6f, 0x56, 0x3c}, - output224: []byte{0xf6, 0xf2, 0x8e, 0x3b, 0x65, 0xb6, 0x84, 0xc9, 0xd9, 0x50, 0x60, 0x61, 0x98, 0x0, 0x46, 0x6, 0x13, 0x90, 0xcc, 0xde, 0x24, 0x58, 0xa2, 0xf, 0x9b, 0x8, 0x6b, 0xe5}, - output256: []byte{0xf5, 0x2e, 0x10, 0x2e, 0x57, 0x29, 0x38, 0x78, 0xc2, 0x8f, 0x29, 0xde, 0xb4, 0x77, 0x92, 0x32, 0x4f, 0xe4, 0x55, 0xa6, 0x2f, 0xa7, 0x44, 0x1a, 0xab, 0xcc, 0x16, 0xa9, 0xcf, 0xc4, 0xf, 0xfa}, - output384: []byte{0x3c, 0x25, 0x75, 0x37, 0x2c, 0xe1, 0xf3, 0x80, 0xa6, 0xe6, 0x6b, 0xb0, 0x75, 0xfb, 0xae, 0x98, 0xfc, 0x2e, 0x6d, 0x3d, 0x26, 0x7a, 0x20, 0xff, 0x3, 0x13, 0xab, 0xc3, 0xde, 0x25, 0x2e, 0x3, 0xfd, 0x5b, 0xdf, 0xa8, 0xbc, 0x2b, 0x79, 0xfc, 0x87, 0x4c, 0xcd, 0xa4, 0xab, 0xdb, 0xb4, 0xa6}, - output512: []byte{0xa4, 0xe8, 0x5f, 0xf8, 0x64, 0x82, 0xc1, 0xc, 0x6a, 0xaa, 0xbc, 0x79, 0xa5, 0x73, 0xcb, 0xf8, 0x9a, 0xa, 0x92, 0x71, 0x10, 0xd7, 0x55, 0xf2, 0x2b, 0x52, 0x9b, 0xd7, 0xcf, 0x3f, 0x6c, 0xc6, 0xcb, 0x98, 0x61, 0xe5, 0x9, 0x65, 0x72, 0x42, 0xa7, 0x8b, 0xc, 0xa, 0xf7, 0x8f, 0xf9, 0x7a, 0xbc, 0xc1, 0xa8, 0x38, 0x82, 0x70, 0xd6, 0xc8, 0xd3, 0x2, 0xd4, 0x5c, 0x9b, 0xa5, 0x84, 0x4}, - }, - { - msg: []byte{0xd, 0x58, 0xac, 0x66, 0x5f, 0xa8, 0x43, 0x42, 0xe6, 0xc, 0xef, 0xee, 0x31, 0xb1, 0xa4, 0xea, 0xcd, 0xb0, 0x92, 0xf1, 0x22, 0xdf, 0xc6, 0x83, 0x9, 0x7, 0x7a, 0xed, 0x1f, 0x3e, 0x52, 0x8f, 0x57, 0x88, 0x59, 0xee, 0x9e, 0x4c, 0xef, 0xb4, 0xa7, 0x28, 0xe9, 0x46, 0x32, 0x49, 0x27, 0xb6, 0x75, 0xcd, 0x4f, 0x4a, 0xc8, 0x4f, 0x64, 0xdb, 0x3d, 0xac, 0xfe, 0x85, 0xc, 0x1d, 0xd1, 0x87, 0x44, 0xc7, 0x4c, 0xec, 0xcd, 0x9f, 0xe4, 0xdc, 0x21, 0x40, 0x85, 0x10, 0x8f, 0x40, 0x4e, 0xab, 0x6d, 0x8f, 0x45, 0x2b, 0x54, 0x42, 0xa4, 0x7d}, - output224: []byte{0xf6, 0x86, 0xd2, 0xb1, 0x38, 0x6b, 0x2, 0xb0, 0x8f, 0x6b, 0x2, 0xbd, 0x5d, 0x50, 0x20, 0x6d, 0x5e, 0x13, 0x84, 0x40, 0xcb, 0xd, 0x93, 0xeb, 0xcc, 0x3b, 0x32, 0xa7}, - output256: []byte{0x2b, 0x89, 0xaa, 0x88, 0xb1, 0xb7, 0xf9, 0xf8, 0xea, 0x46, 0x1c, 0x4c, 0x5c, 0xae, 0x48, 0x29, 0x12, 0x5f, 0x45, 0xf5, 0x69, 0x7d, 0xea, 0xdb, 0x8d, 0xb2, 0xe9, 0x64, 0x52, 0x4c, 0xd, 0x91}, - output384: []byte{0xe, 0xe6, 0xae, 0xca, 0x8d, 0xd8, 0xb, 0x74, 0x22, 0x5a, 0xc4, 0x88, 0x2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, 0x8b, 0x78, 0x2d, 0xd3, 0x46, 0x9c, 0xcd}, - output224: []byte{0x46, 0x48, 0x33, 0x75, 0xd1, 0x12, 0xfc, 0x2b, 0xe7, 0xf6, 0x11, 0xbe, 0x4b, 0x98, 0xdf, 0xad, 0xa3, 0x88, 0x92, 0xc4, 0x3c, 0xef, 0xa5, 0x86, 0x72, 0x6b, 0x48, 0xbb}, - output256: []byte{0x3f, 0x30, 0x92, 0x36, 0x59, 0x82, 0xc0, 0xb4, 0x27, 0x80, 0x55, 0xbe, 0xee, 0x90, 0x32, 0xff, 0x9d, 0x10, 0x60, 0xe0, 0x3c, 0x3b, 0x8, 0x7e, 0x1a, 0x61, 0x97, 0xde, 0xfc, 0x70, 0x7e, 0x1a}, - output384: []byte{0x80, 0x27, 0xe5, 0x4, 0x49, 0x23, 0xf8, 0xee, 0xe1, 0xdf, 0x18, 0x48, 0x65, 0xcd, 0x97, 0xb6, 0x35, 0xa7, 0x8d, 0xa1, 0x99, 0xfd, 0x80, 0xad, 0x3d, 0x34, 0x3a, 0x5a, 0xe0, 0x3d, 0x1b, 0x16, 0x5e, 0x58, 0xd1, 0xb0, 0xbd, 0x9, 0x3e, 0xf9, 0x16, 0xa1, 0x6d, 0x66, 0x41, 0xbd, 0xa1, 0x7c}, - output512: []byte{0xab, 0x2f, 0xc5, 0x9a, 0x43, 0xa2, 0x66, 0x6c, 0x92, 0x6, 0xb9, 0x31, 0x74, 0x79, 0x28, 0x5e, 0x66, 0xb, 0x67, 0xc, 0x6f, 0x11, 0x1f, 0x99, 0x95, 0x56, 0xe8, 0x15, 0x1e, 0xe, 0xb8, 0xd1, 0x2b, 0xc8, 0x2c, 0x9a, 0x7e, 0x7b, 0x3f, 0x8d, 0x6f, 0x38, 0x2a, 0x8d, 0x96, 0x77, 0x5e, 0xa4, 0x17, 0xf7, 0x54, 0xff, 0x55, 0x2e, 0x1b, 0xac, 0x27, 0x1f, 0xbd, 0x8, 0x24, 0xf, 0x1b, 0x86}, - }, - { - msg: []byte{0xb1, 0x80, 0xde, 0x1a, 0x61, 0x11, 0x11, 0xee, 0x75, 0x84, 0xba, 0x2c, 0x4b, 0x2, 0x5, 0x98, 0xcd, 0x57, 0x4a, 0xc7, 0x7e, 0x40, 0x4e, 0x85, 0x3d, 0x15, 0xa1, 0x1, 0xc6, 0xf5, 0xa2, 0xe5, 0xc8, 0x1, 0xd7, 0xd8, 0x5d, 0xc9, 0x52, 0x86, 0xa1, 0x80, 0x4c, 0x87, 0xb, 0xb9, 0xf0, 0xf, 0xd4, 0xdc, 0xb0, 0x3a, 0xa8, 0x32, 0x82, 0x75, 0x15, 0x88, 0x19, 0xdc, 0xad, 0x72, 0x53, 0xf3, 0xe3, 0xd2, 0x37, 0xae, 0xaa, 0x79, 0x79, 0x26, 0x8a, 0x5d, 0xb1, 0xc6, 0xce, 0x8, 0xa9, 0xec, 0x7c, 0x25, 0x79, 0x78, 0x3c, 0x8a, 0xfc, 0x1f, 0x91, 0xa7}, - output224: []byte{0xe1, 0xe9, 0xad, 0x56, 0x8a, 0xe5, 0xb0, 0xd9, 0x73, 0x14, 0x0, 0xba, 0x4f, 0xc7, 0xdf, 0x3, 0x21, 0xa0, 0x4e, 0xa4, 0x13, 0x93, 0xba, 0x69, 0x79, 0xc7, 0x17, 0x9c}, - output256: []byte{0x3c, 0x74, 0xaa, 0xe2, 0xf3, 0x40, 0xa2, 0x41, 0x78, 0xcb, 0xab, 0x51, 0x0, 0x4c, 0xba, 0x1a, 0xac, 0x3d, 0x91, 0x13, 0x3c, 0x30, 0x7, 0x15, 0xea, 0x82, 0xc1, 0x77, 0x26, 0x9c, 0x5, 0x56}, - output384: []byte{0x79, 0x68, 0x18, 0xe0, 0x47, 0x91, 0x3d, 0x5a, 0xfb, 0x4a, 0xe4, 0xc5, 0xb7, 0xc5, 0xd5, 0xef, 0x69, 0x9a, 0x3a, 0x9e, 0xbe, 0xfb, 0x44, 0x46, 0x2e, 0xe8, 0xfe, 0x60, 0x3c, 0xa5, 0x62, 0x89, 0x73, 0x36, 0x9e, 0x4a, 0x9d, 0x8e, 0x10, 0x11, 0x5f, 0xdd, 0x75, 0xc8, 0x97, 0x7, 0xa8, 0xf9}, - output512: []byte{0xa, 0x67, 0x3a, 0xf8, 0x4e, 0x2d, 0x23, 0x17, 0xb8, 0xa, 0x87, 0x3b, 0xfe, 0x38, 0xb2, 0x52, 0x87, 0x27, 0x8, 0xb3, 0x8a, 0xf9, 0xb9, 0x56, 0xe3, 0x55, 0x4a, 0xc2, 0xdc, 0xe2, 0xf7, 0x7c, 0x81, 0x55, 0x93, 0xd9, 0x99, 0x30, 0xe7, 0xaa, 0x66, 0x6c, 0x57, 0xb5, 0x97, 0x30, 0x71, 0x2e, 0x5c, 0x4a, 0x9b, 0x57, 0x84, 0x9e, 0xdd, 0xd7, 0x12, 0xa3, 0x78, 0x4, 0xe, 0xb8, 0x24, 0xd8}, - }, - { - msg: []byte{0xcf, 0x35, 0x83, 0xcb, 0xdf, 0xd4, 0xcb, 0xc1, 0x70, 0x63, 0xb1, 0xe7, 0xd9, 0xb, 0x2, 0xf0, 0xe6, 0xe2, 0xee, 0x5, 0xf9, 0x9d, 0x77, 0xe2, 0x4e, 0x56, 0x3, 0x92, 0x53, 0x5e, 0x47, 0xe0, 0x50, 0x77, 0x15, 0x7f, 0x96, 0x81, 0x35, 0x44, 0xa1, 0x70, 0x46, 0x91, 0x4f, 0x9e, 0xfb, 0x64, 0x76, 0x2a, 0x23, 0xcf, 0x7a, 0x49, 0xfe, 0x52, 0xa0, 0xa4, 0xc0, 0x1c, 0x63, 0xc, 0xfe, 0x87, 0x27, 0xb8, 0x1f, 0xb9, 0x9a, 0x89, 0xff, 0x7c, 0xc1, 0x1d, 0xca, 0x51, 0x73, 0x5, 0x7e, 0x4, 0x17, 0xb8, 0xfe, 0x7a, 0x9e, 0xfb, 0xa6, 0xd9, 0x5c, 0x55, 0x5f}, - output224: []byte{0x13, 0x3f, 0x31, 0xd9, 0xfb, 0xc1, 0xb2, 0xa3, 0x3f, 0x1c, 0x98, 0xbf, 0xe2, 0x1e, 0x12, 0x9e, 0x7, 0x16, 0xa6, 0x9e, 0xe2, 0x74, 0x8, 0x74, 0x3f, 0xff, 0x17, 0xac}, - output256: []byte{0x1, 0x57, 0xc4, 0xba, 0x44, 0x61, 0x8d, 0xed, 0x11, 0xe9, 0x80, 0xa, 0xfa, 0x7, 0xa0, 0xd5, 0xb6, 0xc7, 0x11, 0xfc, 0x16, 0xa5, 0x76, 0xc5, 0xed, 0xb7, 0x1c, 0x4c, 0xc6, 0x89, 0x4f, 0x82}, - output384: []byte{0x1e, 0x96, 0xef, 0xf6, 0x2e, 0x9f, 0x46, 0x4b, 0x48, 0x2, 0x97, 0x2f, 0xda, 0xc7, 0x7c, 0x3e, 0xa1, 0x13, 0x1b, 0x28, 0x22, 0x61, 0x9d, 0x2c, 0x5d, 0x86, 0x3e, 0x35, 0x7d, 0x9, 0x45, 0xc1, 0x7f, 0x93, 0xed, 0xe6, 0x6a, 0xf0, 0x5d, 0x46, 0xe6, 0x3c, 0x28, 0x57, 0xa5, 0x4f, 0x67, 0xf4}, - output512: []byte{0x1d, 0x34, 0x64, 0x54, 0x63, 0xeb, 0xbd, 0x93, 0x2c, 0x73, 0xe, 0x59, 0x3d, 0x9c, 0x10, 0x8a, 0xa8, 0x68, 0x7, 0xdb, 0x67, 0x85, 0xf0, 0x5c, 0x4c, 0xe8, 0xf, 0x3e, 0x83, 0x2, 0xf8, 0x7e, 0xfb, 0xcc, 0xb1, 0xab, 0x88, 0x4e, 0x25, 0xf1, 0xdc, 0xd5, 0x48, 0x5d, 0x38, 0x55, 0x2, 0x99, 0x5e, 0x7a, 0xbe, 0x2e, 0xf1, 0x1b, 0xd3, 0x46, 0x9e, 0x3, 0x6d, 0x7e, 0xb9, 0x3b, 0x4f, 0x39}, - }, - { - msg: []byte{0x7, 0x2f, 0xc0, 0x23, 0x40, 0xef, 0x99, 0x11, 0x5b, 0xad, 0x72, 0xf9, 0x2c, 0x1, 0xe4, 0xc0, 0x93, 0xb9, 0x59, 0x9f, 0x6c, 0xfc, 0x45, 0xcb, 0x38, 0xe, 0xe6, 0x86, 0xcb, 0x5e, 0xb0, 0x19, 0xe8, 0x6, 0xab, 0x9b, 0xd5, 0x5e, 0x63, 0x4a, 0xb1, 0xa, 0xa6, 0x2a, 0x95, 0x10, 0xcc, 0x6, 0x72, 0xcd, 0x3e, 0xdd, 0xb5, 0x89, 0xc7, 0xdf, 0x2b, 0x67, 0xfc, 0xd3, 0x32, 0x9f, 0x61, 0xb1, 0xa4, 0x44, 0x1e, 0xca, 0x87, 0xa3, 0x3c, 0x8f, 0x55, 0xda, 0x4f, 0xbb, 0xad, 0x5c, 0xf2, 0xb2, 0x52, 0x7b, 0x8e, 0x98, 0x3b, 0xb3, 0x1a, 0x2f, 0xad, 0xec, 0x75, 0x23}, - output224: []byte{0x31, 0x32, 0x8f, 0x4, 0xca, 0x64, 0xe8, 0x52, 0x1a, 0x36, 0xa8, 0x94, 0x3c, 0x33, 0xce, 0xb9, 0x5b, 0xe1, 0xb9, 0x8, 0xf, 0x45, 0x33, 0xd6, 0xda, 0x7, 0x60, 0x6d}, - output256: []byte{0x8d, 0x53, 0xdb, 0xa1, 0x7, 0xaa, 0xac, 0xb8, 0x42, 0x2d, 0x66, 0x67, 0xf6, 0x77, 0x88, 0x39, 0xf8, 0x96, 0x5f, 0x8e, 0x4c, 0x8f, 0x4a, 0x85, 0x12, 0x84, 0xcc, 0x91, 0x16, 0x8a, 0x90, 0x30}, - output384: []byte{0x4c, 0xc4, 0x1c, 0x2f, 0xb7, 0xd7, 0x1d, 0xa1, 0xad, 0x36, 0xd1, 0x80, 0x29, 0xf7, 0x55, 0xda, 0xf3, 0x42, 0xe7, 0x32, 0xec, 0x31, 0xf0, 0xc0, 0x6e, 0x27, 0x9, 0x13, 0x7, 0x71, 0x8a, 0xcb, 0x53, 0xfa, 0x11, 0x3a, 0xe5, 0x8, 0xdf, 0x38, 0xb8, 0xc9, 0x68, 0x34, 0xde, 0x33, 0xf9, 0xf1}, - output512: []byte{0x3f, 0x57, 0xfa, 0x91, 0x5a, 0x78, 0x2e, 0x3c, 0xc6, 0x98, 0x15, 0xba, 0x21, 0x9f, 0x42, 0xaa, 0x2c, 0x22, 0x2c, 0xd7, 0xf3, 0x9, 0xf1, 0xa, 0xf8, 0x43, 0x38, 0x4b, 0x3d, 0x39, 0x39, 0xaa, 0xb, 0x92, 0xdd, 0x95, 0x71, 0x68, 0x6c, 0x79, 0x61, 0xe0, 0x6b, 0xfe, 0xe8, 0x18, 0x12, 0x7f, 0xc5, 0xb5, 0xf3, 0x2c, 0x67, 0xf4, 0xaa, 0x2a, 0xf1, 0xd, 0x4f, 0xa3, 0x8f, 0x65, 0xe9, 0xd}, - }, - { - msg: []byte{0x76, 0xee, 0xcf, 0x95, 0x6a, 0x52, 0x64, 0x9f, 0x87, 0x75, 0x28, 0x14, 0x6d, 0xe3, 0x3d, 0xf2, 0x49, 0xcd, 0x80, 0xe, 0x21, 0x83, 0xf, 0x65, 0xe9, 0xf, 0xf, 0x25, 0xca, 0x9d, 0x65, 0x40, 0xfd, 0xe4, 0x6, 0x3, 0x23, 0xe, 0xca, 0x67, 0x60, 0xf1, 0x13, 0x9c, 0x7f, 0x26, 0x8d, 0xeb, 0xa2, 0x6, 0x6, 0x31, 0xee, 0xa9, 0x2b, 0x1f, 0xff, 0x5, 0xf9, 0x3f, 0xd5, 0x57, 0x2f, 0xbe, 0x29, 0x57, 0x9e, 0xcd, 0x48, 0xbc, 0x3a, 0x8d, 0x6c, 0x2e, 0xb4, 0xa6, 0xb2, 0x6e, 0x38, 0xd6, 0xc5, 0xfb, 0xf2, 0xc0, 0x80, 0x44, 0xae, 0xea, 0x47, 0xa, 0x8f, 0x2f, 0x26}, - output224: []byte{0xad, 0xd3, 0x74, 0xb1, 0xd2, 0x79, 0x46, 0x9c, 0x8, 0xe7, 0xb2, 0x7a, 0xe3, 0xff, 0x1b, 0x4, 0xc3, 0xd0, 0xfb, 0x3e, 0xf6, 0xe5, 0x9a, 0xa3, 0xaf, 0x86, 0x66, 0xb}, - output256: []byte{0x51, 0x63, 0xf0, 0x22, 0x33, 0xe3, 0x32, 0xad, 0x9b, 0xe3, 0x2c, 0x23, 0x46, 0xc9, 0xfc, 0xfe, 0x39, 0xaf, 0xa5, 0xfb, 0xe9, 0xbc, 0x1c, 0xfe, 0xb9, 0x2f, 0x49, 0x20, 0x15, 0x5b, 0x20, 0xec}, - output384: []byte{0x9a, 0x8d, 0x4b, 0x56, 0x4, 0x21, 0xc8, 0x29, 0x91, 0xbd, 0xfc, 0xa0, 0x89, 0x8a, 0x29, 0xa5, 0x9b, 0xdb, 0x9, 0xd2, 0xf, 0x8a, 0x5b, 0x27, 0x90, 0x96, 0x72, 0x3b, 0xab, 0x38, 0x27, 0x89, 0xf0, 0x81, 0xea, 0xd5, 0xd, 0x27, 0x3e, 0xca, 0x43, 0x6c, 0x52, 0x6a, 0xba, 0x6d, 0x5c, 0xfc}, - output512: []byte{0x15, 0x13, 0x82, 0xca, 0x35, 0xfb, 0x20, 0xb8, 0x95, 0xa9, 0xdc, 0x7, 0x4d, 0x68, 0x7f, 0x2f, 0x33, 0x5e, 0xaf, 0x57, 0x45, 0x6d, 0x35, 0x7a, 0x68, 0x5e, 0xf7, 0x52, 0xda, 0x59, 0x17, 0x4d, 0x3f, 0x23, 0x9a, 0xa9, 0xe0, 0x4f, 0x14, 0x21, 0x38, 0xd9, 0x41, 0x3b, 0x21, 0x90, 0x46, 0x65, 0xef, 0x4d, 0xf2, 0xf6, 0x3e, 0x66, 0x3b, 0x49, 0x3, 0x83, 0x66, 0x4, 0x81, 0xf7, 0x83, 0x62}, - }, - { - msg: []byte{0x7a, 0xdc, 0xb, 0x66, 0x93, 0xe6, 0x1c, 0x26, 0x9f, 0x27, 0x8e, 0x69, 0x44, 0xa5, 0xa2, 0xd8, 0x30, 0x9, 0x81, 0xe4, 0x0, 0x22, 0xf8, 0x39, 0xac, 0x64, 0x43, 0x87, 0xbf, 0xac, 0x90, 0x86, 0x65, 0x0, 0x85, 0xc2, 0xcd, 0xc5, 0x85, 0xfe, 0xa4, 0x7b, 0x9d, 0x2e, 0x52, 0xd6, 0x5a, 0x2b, 0x29, 0xa7, 0xdc, 0x37, 0x4, 0x1, 0xef, 0x5d, 0x60, 0xdd, 0xd, 0x21, 0xf9, 0xe2, 0xb9, 0xf, 0xae, 0x91, 0x93, 0x19, 0xb1, 0x4b, 0x8c, 0x55, 0x65, 0xb0, 0x42, 0x3c, 0xef, 0xb8, 0x27, 0xd5, 0xf1, 0x20, 0x33, 0x2, 0xa9, 0xd0, 0x15, 0x23, 0x49, 0x8a, 0x4d, 0xb1, 0x3, 0x74}, - output224: []byte{0xfe, 0xd7, 0xfd, 0xe8, 0x94, 0xd9, 0x2c, 0xc3, 0xbb, 0x68, 0xfc, 0xc3, 0x96, 0xb5, 0xeb, 0x0, 0xc4, 0x15, 0x6f, 0x4, 0xfc, 0x9c, 0xed, 0x99, 0xd1, 0x2c, 0xfa, 0x5b}, - output256: []byte{0xfa, 0xaf, 0xe, 0x95, 0x21, 0x7c, 0xa4, 0xb1, 0x56, 0x87, 0x51, 0xef, 0x2e, 0x4c, 0xd3, 0x41, 0xd9, 0xec, 0x33, 0xe1, 0x66, 0x0, 0xbf, 0x9, 0xb9, 0x2c, 0x6f, 0x1a, 0x6d, 0xf8, 0x4d, 0x2e}, - output384: []byte{0x36, 0x7c, 0xb3, 0xfe, 0x3, 0xa3, 0xcb, 0xb5, 0xf, 0xae, 0x1f, 0xe7, 0xea, 0x88, 0x3a, 0xa, 0xe5, 0x3c, 0xbe, 0x77, 0x2f, 0x70, 0x9d, 0xc5, 0x50, 0x5f, 0x3c, 0x90, 0x75, 0x64, 0xc0, 0x8f, 0xc4, 0x97, 0x7, 0xcf, 0xf9, 0x63, 0x9b, 0x25, 0xc7, 0x46, 0xb6, 0x3, 0x9f, 0xf4, 0x8a, 0xe9}, - output512: []byte{0x23, 0xa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c3, 0x4d, 0xe6, 0xda}, - output256: []byte{0xb2, 0xc1, 0x75, 0xd9, 0xd9, 0x2a, 0xaa, 0x9e, 0xe7, 0x26, 0x72, 0xf9, 0x95, 0xb8, 0xdf, 0xd2, 0xda, 0xaf, 0x65, 0x55, 0xa0, 0x32, 0x7a, 0x50, 0x82, 0x18, 0xa9, 0xb4, 0x47, 0xf0, 0xb, 0xe8}, - output384: []byte{0xbb, 0xbd, 0x5, 0xd6, 0x9d, 0x7a, 0x8, 0x2f, 0xcd, 0xa8, 0xed, 0x53, 0x5d, 0x7e, 0x4e, 0x5d, 0xe1, 0x37, 0x7b, 0xd9, 0x1e, 0x72, 0xd4, 0x2d, 0xc9, 0x52, 0x95, 0xc9, 0xdb, 0x78, 0x1, 0x69, 0xe2, 0xf9, 0x62, 0xe, 0xc7, 0xa5, 0xaf, 0xf9, 0x59, 0xff, 0x2d, 0x94, 0x6f, 0xd2, 0xa, 0x72}, - output512: []byte{0x36, 0x5, 0xce, 0xc1, 0x6a, 0x7a, 0xa8, 0xb2, 0x52, 0x54, 0x79, 0xfc, 0xc1, 0x29, 0x54, 0x11, 0xb6, 0xa9, 0x52, 0xdc, 0xe2, 0x33, 0xc9, 0xac, 0xc8, 0x56, 0xd6, 0xd1, 0x7c, 0x98, 0x12, 0xc9, 0x20, 0x17, 0x85, 0x0, 0xcd, 0x0, 0x28, 0xb5, 0x99, 0x8d, 0x7, 0x4, 0x6c, 0x6a, 0x5c, 0xf3, 0x98, 0xee, 0x1e, 0xc9, 0x7d, 0xf9, 0x18, 0x2c, 0x33, 0xfc, 0xa8, 0x66, 0x47, 0x86, 0x18, 0x78}, - }, - { - msg: []byte{0x69, 0xf9, 0xab, 0xba, 0x65, 0x59, 0x2e, 0xe0, 0x1d, 0xb4, 0xdc, 0xe5, 0x2d, 0xba, 0xb9, 0xb, 0x8, 0xfc, 0x4, 0x19, 0x36, 0x2, 0x79, 0x2e, 0xe4, 0xda, 0xa2, 0x63, 0x3, 0x3d, 0x59, 0x8, 0x15, 0x87, 0xb0, 0x9b, 0xbe, 0x49, 0xd0, 0xb4, 0x9c, 0x98, 0x25, 0xd2, 0x28, 0x40, 0xb2, 0xff, 0x5d, 0x9c, 0x51, 0x55, 0xf9, 0x75, 0xf8, 0xf2, 0xc2, 0xe7, 0xa9, 0xc, 0x75, 0xd2, 0xe4, 0xa8, 0x4, 0xf, 0xe3, 0x9f, 0x63, 0xbb, 0xaf, 0xb4, 0x3, 0xd9, 0xe2, 0x8c, 0xc3, 0xb8, 0x6e, 0x4, 0xe3, 0x94, 0xa9, 0xc9, 0xe8, 0x6, 0x5b, 0xd3, 0xc8, 0x5f, 0xa9, 0xf0, 0xc7, 0x89, 0x16, 0x0}, - output224: []byte{0x88, 0xfe, 0xfb, 0xe8, 0x99, 0x5e, 0x29, 0x6a, 0x9d, 0xee, 0x4d, 0xa2, 0xb4, 0x14, 0xd5, 0xa7, 0xe1, 0x34, 0x4, 0x56, 0x39, 0xa6, 0xb1, 0x76, 0xc2, 0xd7, 0x36, 0xed}, - output256: []byte{0xfb, 0x53, 0x88, 0x12, 0x23, 0x6, 0xd3, 0x7c, 0xee, 0x79, 0xc, 0xad, 0x1d, 0x3c, 0xdd, 0xba, 0x8e, 0x9a, 0x93, 0xd5, 0xf9, 0xd7, 0x82, 0x88, 0xb0, 0x52, 0x48, 0x27, 0x39, 0xc8, 0x83, 0xfd}, - output384: []byte{0xbe, 0x8b, 0xec, 0xc, 0x2e, 0xc7, 0x21, 0xe0, 0xc3, 0x26, 0x3, 0x7c, 0xe8, 0x6a, 0x15, 0x18, 0xfb, 0x39, 0x5c, 0x3a, 0x98, 0x2, 0xde, 0x1, 0xc3, 0xe2, 0x34, 0x26, 0x8e, 0xbb, 0x9a, 0xc9, 0xa3, 0x9a, 0x6e, 0x40, 0x4f, 0x25, 0xfb, 0x7f, 0xeb, 0xdc, 0xf1, 0xf7, 0xf2, 0x5d, 0xc0, 0x83}, - output512: []byte{0xc5, 0xa5, 0x26, 0xd7,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21, 0x4c, 0x5f, 0xf0, 0x21, 0x92}, - output256: []byte{0x1c, 0x2f, 0x8d, 0x41, 0x8f, 0xf6, 0x71, 0x8b, 0x18, 0xdd, 0x4c, 0x75, 0x6d, 0xcc, 0x8e, 0xd0, 0xf4, 0x75, 0x5e, 0x8c, 0x22, 0x49, 0x7a, 0x6c, 0xc1, 0x9f, 0x8d, 0x7a, 0xe7, 0xfd, 0x2d, 0xa7}, - output384: []byte{0x2a, 0xee, 0xaf, 0x29, 0x2a, 0xd6, 0x25, 0x22, 0x1b, 0xa7, 0x9a, 0x62, 0x12, 0x17, 0xfd, 0x1b, 0x3f, 0x89, 0x78, 0xba, 0x83, 0xfe, 0x7f, 0xf1, 0x3b, 0x38, 0x57, 0x4f, 0xcf, 0xaf, 0xfb, 0xd2, 0x7, 0x29, 0x88, 0x54, 0xb6, 0xf9, 0xc2, 0x7d, 0x66, 0x77, 0x49, 0x42, 0x4, 0x22, 0x1f, 0xda}, - output512: []byte{0xb2, 0x39, 0x94, 0x1a, 0x31, 0x10, 0xa, 0xb1, 0xb2, 0x4a, 0xf2, 0xd1, 0xfe, 0xf1, 0x49, 0xdb, 0xa3, 0x0, 0x10, 0x5a, 0x31, 0xb7, 0x2a, 0x8f, 0x21, 0x7e, 0x30, 0x6a, 0x6, 0x2, 0xd7, 0x22, 0xcc, 0xd5, 0x93, 0xa2, 0x3e, 0x65, 0x39, 0xd3, 0xe4, 0x19, 0x5a, 0x7e, 0x12, 0xca, 0x19, 0xae, 0x2b, 0xae, 0x8b, 0x83, 0x99, 0xf7, 0xa9, 0xd5, 0xd, 0xb3, 0x2, 0x16, 0xe9, 0x73, 0xf2, 0xbf}, - }, - { - msg: []byte{0x6d, 0x8c, 0x6e, 0x44, 0x9b, 0xc1, 0x36, 0x34, 0xf1, 0x15, 0x74, 0x9c, 0x24, 0x8c, 0x17, 0xcd, 0x14, 0x8b, 0x72, 0x15, 0x7a, 0x2c, 0x37, 0xbf, 0x89, 0x69, 0xea, 0x83, 0xb4, 0xd6, 0xba, 0x8c, 0xe, 0xe2, 0x71, 0x1c, 0x28, 0xee, 0x11, 0x49, 0x5f, 0x43, 0x4, 0x95, 0x96, 0x52, 0xc, 0xe4, 0x36, 0x0, 0x4b, 0x2, 0x6b, 0x6c, 0x1f, 0x72, 0x92, 0xb9, 0xc4, 0x36, 0xb0, 0x55, 0xcb, 0xb7, 0x2d, 0x53, 0xd, 0x86, 0xd, 0x12, 0x76, 0xa1, 0x50, 0x2a, 0x51, 0x40, 0xe3, 0xc3, 0xf5, 0x4a, 0x93, 0x66, 0x3e, 0x4d, 0x20, 0xed, 0xec, 0x32, 0xd2, 0x84, 0xe2, 0x55, 0x64, 0xf6, 0x24, 0x95, 0x5b, 0x52}, - output224: []byte{0x44, 0xe9, 0x0, 0x2f, 0x9d, 0x97, 0xd9, 0x8b, 0xb4, 0x39, 0xaf, 0xc3, 0x61, 0xf9, 0x3b, 0xb9, 0x59, 0x52, 0x3e, 0x73, 0x13, 0x6a, 0x2c, 0x65, 0xb2, 0xe2, 0xb0, 0x66}, - output256: []byte{0x7e, 0xa8, 0x11, 0x6e, 0x64, 0x34, 0xc1, 0xca, 0xa0, 0x49, 0x6, 0x9d, 0xbb, 0xd9, 0xb6, 0xf0, 0xe9, 0xdc, 0x6c, 0xdf, 0xd6, 0xa8, 0x89, 0x34, 0x3d, 0x3b, 0x26, 0x52, 0x80, 0x30, 0x78, 0xfc}, - output384: []byte{0x9a, 0x17, 0x61, 0xc5, 0x75, 0x9c, 0xe6, 0x7c, 0x9c, 0x9, 0x3e, 0xc5, 0xc8, 0x31, 0xc1, 0xff, 0x7c, 0xab, 0x64, 0xac, 0x7c, 0x80, 0x2, 0x6, 0x6e, 0xdc, 0xae, 0xd0, 0x44, 0xde, 0xf5, 0x7c, 0xea, 0x3e, 0xf6, 0xbe, 0x98, 0x57, 0x83, 0x63, 0xd2, 0xce, 0x3d, 0x1f, 0x5b, 0xa4, 0x48, 0xf8}, - output512: []byte{0xd6, 0xab,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f5, 0x94, 0x79, 0xf5, 0x38, 0x7a, 0xb, 0x27}, - output256: []byte{0x73, 0x6d, 0x88, 0x87, 0x51, 0xfa, 0xac, 0x4d, 0x8e, 0x78, 0xb4, 0x5b, 0x95, 0xab, 0xb1, 0x5d, 0x40, 0xd9, 0x8d, 0x80, 0x38, 0xc7, 0x22, 0x5b, 0xe0, 0xf5, 0x23, 0xd5, 0x43, 0x9e, 0xa5, 0xb6}, - output384: []byte{0x4a, 0x24, 0xa1, 0xaf, 0x68, 0xdb, 0x65, 0xc3, 0x97, 0x74, 0x31, 0xee, 0x81, 0x9, 0x2c, 0x77, 0x6f, 0x7c, 0xb3, 0x3d, 0x6f, 0x8, 0x94, 0x1, 0x0, 0xea, 0x24, 0xa, 0x2d, 0x1f, 0x86, 0x23, 0xa4, 0x1d, 0x7, 0xce, 0x99, 0x37, 0xbc, 0xbe, 0xc8, 0xca, 0x10, 0x72, 0xa1, 0xa7, 0x8e, 0x8b}, - output512: []byte{0xbc, 0xa, 0x28, 0x45, 0x3, 0x68, 0xc2, 0x88, 0x1, 0x3e, 0x2e, 0xb1, 0x19, 0x6e, 0x58, 0x93, 0x3c, 0xe0, 0x58, 0x69, 0xcb, 0x55, 0xfa, 0x2b, 0xda, 0x61, 0xd9, 0xd9, 0x2f, 0x83, 0xb9, 0x3, 0xe5, 0x9d, 0xde, 0xb, 0x92, 0x7c, 0xa6, 0xdb, 0xc4, 0x6f, 0x5a, 0xf2, 0xeb, 0x7e, 0x88, 0x31, 0xe8, 0x66, 0x88, 0x88, 0xbf, 0xea, 0x46, 0xd7, 0x8f, 0x4d, 0x27, 0x48, 0x18, 0xd5, 0x63, 0x28}, - }, - { - msg: []byte{0x43, 0x3c, 0x53, 0x3, 0x13, 0x16, 0x24, 0xc0, 0x2, 0x1d, 0x86, 0x8a, 0x30, 0x82, 0x54, 0x75, 0xe8, 0xd0, 0xbd, 0x30, 0x52, 0xa0, 0x22, 0x18, 0x3, 0x98, 0xf4, 0xca, 0x44, 0x23, 0xb9, 0x82, 0x14, 0xb6, 0xbe, 0xaa, 0xc2, 0x1c, 0x88, 0x7, 0xa2, 0xc3, 0x3f, 0x8c, 0x93, 0xbd, 0x42, 0xb0, 0x92, 0xcc, 0x1b, 0x6, 0xce, 0xdf, 0x32, 0x24, 0xd5, 0xed, 0x1e, 0xc2, 0x97, 0x84, 0x44, 0x4f, 0x22, 0xe0, 0x8a, 0x55, 0xaa, 0x58, 0x54, 0x2b, 0x52, 0x4b, 0x2, 0xcd, 0x3d, 0x5d, 0x5f, 0x69, 0x7, 0xaf, 0xe7, 0x1c, 0x5d, 0x74, 0x62, 0x22, 0x4a, 0x3f, 0x9d, 0x9e, 0x53, 0xe7, 0xe0, 0x84, 0x6d, 0xcb, 0xb4, 0xce}, - output224: []byte{0x5e, 0xfd, 0xc3, 0xca, 0xa2, 0x2e, 0xe2, 0xc2, 0xeb, 0x63, 0x2d, 0x4c, 0x66, 0x45, 0xce, 0x3e, 0xc6, 0x39, 0x60, 0xdf, 0xd6, 0x9a, 0x4, 0xbb, 0xe0, 0x11, 0x56, 0xc5}, - output256: []byte{0x90, 0xe1, 0xb, 0x1c, 0xa8, 0xd3, 0x52, 0x79, 0x4d, 0x7d, 0xbd, 0x7b, 0xae, 0x41, 0xb, 0xef, 0x25, 0xf0, 0xec, 0x7d, 0x8, 0xe, 0x5, 0x3f, 0x48, 0x67, 0x42, 0x37, 0xe3, 0x3e, 0xa4, 0x5f}, - output384: []byte{0x92, 0x8e, 0x94, 0xd1, 0x9f, 0xc6, 0x0, 0x65, 0xa5, 0xef, 0x7e, 0x48, 0x1, 0x83, 0x87, 0xc8, 0xf, 0x2d, 0x35, 0xf, 0x30, 0x6d, 0xf, 0x61, 0x1, 0x73, 0x71, 0x9d, 0x5c, 0x87, 0x4d, 0x4a, 0x8a, 0xcc, 0x34, 0xf, 0xea, 0xd4, 0xbe, 0x35, 0x7e, 0x1f, 0x78, 0x12, 0x41, 0x98, 0xad, 0x77}, - output512: []byte{0x78,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x34, 0x9f, 0x2e, 0x5c, 0xde, 0x65, 0x84, 0xd8, 0xd7, 0xc3, 0x71}, - output256: []byte{0x8a, 0xa, 0x8d, 0x6d, 0x55, 0xcc, 0xcb, 0xe0, 0x5e, 0xc7, 0x4d, 0xc2, 0x73, 0xb1, 0x6d, 0x66, 0xc9, 0xb9, 0x0, 0x66, 0x65, 0xee, 0xcb, 0x5b, 0x60, 0x23, 0xd2, 0xea, 0x39, 0xc6, 0x45, 0x54}, - output384: []byte{0x78, 0xa1, 0x8d, 0x62, 0xf8, 0xa7, 0xef, 0xf5, 0xc6, 0xdd, 0x75, 0xb8, 0xcb, 0x7, 0x3f, 0xd3, 0xe, 0xe6, 0x8c, 0x87, 0x8c, 0x2e, 0xc5, 0x8a, 0xad, 0x1c, 0x5d, 0xd0, 0xeb, 0xa, 0xe4, 0x36, 0x98, 0xa6, 0x17, 0xbb, 0xc, 0x67, 0xf, 0xce, 0x2a, 0xa0, 0x98, 0xe0, 0xad, 0xf4, 0x25, 0xb2}, - output512: []byte{0x9, 0x84, 0xa4, 0x32, 0x86, 0xa3, 0xcb, 0x22, 0xfb, 0x59, 0xf7, 0x88, 0xe, 0x11, 0x4e, 0x23, 0xe3, 0xad, 0x3b, 0xd, 0x43, 0x2, 0x5f, 0x39, 0x87, 0xd0, 0xaa, 0x6f, 0xa8, 0xe5, 0x3e, 0x60, 0x66, 0xf8, 0xf, 0x47, 0x69, 0x24, 0x1d, 0xcd, 0x6, 0x24, 0x31, 0xc7, 0xf6, 0x71, 0x2c, 0x57, 0xc6, 0xe3, 0x27, 0x5e, 0xd3, 0xf2, 0xbc, 0x59, 0x1d, 0xb6, 0xdc, 0x20, 0xe5, 0xbe, 0x9, 0x53}, - }, - { - msg: []byte{0x0, 0x69, 0x17, 0xb6, 0x4f, 0x9d, 0xcd, 0xf1, 0xd2, 0xd8, 0x7c, 0x8a, 0x61, 0x73, 0xb6, 0x4f, 0x65, 0x87, 0x16, 0x8e, 0x80, 0xfa, 0xa8, 0xf, 0x82, 0xd8, 0x4f, 0x60, 0x30, 0x1e, 0x56, 0x1e, 0x31, 0x2d, 0x9f, 0xbc, 0xe6, 0x2f, 0x39, 0xa6, 0xfb, 0x47, 0x6e, 0x1, 0xe9, 0x25, 0xf2, 0x6b, 0xcc, 0x91, 0xde, 0x62, 0x14, 0x49, 0xbe, 0x65, 0x4, 0xc5, 0x4, 0x83, 0xa, 0xae, 0x39, 0x40, 0x96, 0xc8, 0xfc, 0x76, 0x94, 0x65, 0x10, 0x51, 0x36, 0x5d, 0x4e, 0xe9, 0x7, 0x1, 0x1, 0xec, 0x9b, 0x68, 0x8, 0x6f, 0x2e, 0xa8, 0xf8, 0xab, 0x7b, 0x81, 0x1e, 0xa8, 0xad, 0x93, 0x4d, 0x5c, 0x9b, 0x62, 0xc6, 0xa, 0x47, 0x71}, - output224: []byte{0xdb, 0x22, 0x4b, 0xcc, 0xf5, 0xca, 0x86, 0xdf, 0xba, 0x3e, 0xa3, 0x72, 0xe2, 0x26, 0x97, 0x50, 0xb5, 0x32, 0x40, 0x9e, 0xa0, 0x4, 0xe8, 0x2d, 0x4b, 0x58, 0x35, 0xe8}, - output256: []byte{0x12, 0x28, 0x95, 0xd6, 0x3a, 0xa6, 0x3, 0xf, 0xc8, 0xf2, 0x39, 0x40, 0xc5, 0x28, 0xe7, 0xa5, 0xd9, 0xc7, 0xfb, 0x17, 0xa, 0x79, 0xfe, 0x7b, 0xc4, 0x23, 0x60, 0xce, 0x50, 0xe2, 0x5b, 0x7a}, - output384: []byte{0xee, 0xeb, 0x56, 0xc3, 0xe5, 0x4f, 0xa8, 0x33, 0xb9, 0x85, 0xef, 0xa5, 0x92, 0x3c, 0x3f, 0x2, 0x25, 0xf4, 0x19, 0x66, 0x4c, 0xed, 0xd8, 0x98, 0xc7, 0x9f, 0x64, 0xd7, 0x2d, 0x2a, 0xd4, 0xb1, 0x25, 0xa3, 0x8b, 0xe0, 0x20, 0x18, 0x46, 0xc4, 0x42, 0xea, 0xf0, 0x5, 0x1d, 0x51, 0x6d, 0xc9}, - output512: []byte{0xa6, 0x30, 0x4, 0x97, 0xf6, 0x50, 0x85, 0x9c, 0xd7, 0x44, 0x67, 0x98, 0x85, 0xcd, 0x54, 0x37, 0xa6, 0x4c, 0xc3, 0x96, 0x15, 0x74, 0xdc, 0xce, 0x65, 0xe1, 0x61, 0x16, 0x16, 0xa9, 0xf9, 0x71, 0x90, 0xf3, 0x91, 0x30, 0xba, 0x53, 0x20, 0x94, 0xbd, 0x62, 0x46, 0x4d, 0xb, 0x8b, 0x52, 0x29, 0x7a, 0x2c, 0x9c, 0x27, 0x9b, 0x2c, 0x98, 0x60, 0xc0, 0x72, 0xcd, 0x44, 0x44, 0x9a, 0x9c, 0xdf}, - }, - { - msg: []byte{0xf1, 0x3c, 0x97, 0x2c, 0x52, 0xcb, 0x3c, 0xc4, 0xa4, 0xdf, 0x28, 0xc9, 0x7f, 0x2d, 0xf1, 0x1c, 0xe0, 0x89, 0xb8, 0x15, 0x46, 0x6b, 0xe8, 0x88, 0x63, 0x24, 0x3e, 0xb3, 0x18, 0xc2, 0xad, 0xb1, 0xa4, 0x17, 0xcb, 0x10, 0x41, 0x30, 0x85, 0x98, 0x54, 0x17, 0x20, 0x19, 0x7b, 0x9b, 0x1c, 0xb5, 0xba, 0x23, 0x18, 0xbd, 0x55, 0x74, 0xd1, 0xdf, 0x21, 0x74, 0xaf, 0x14, 0x88, 0x41, 0x49, 0xba, 0x9b, 0x2f, 0x44, 0x6d, 0x60, 0x9d, 0xf2, 0x40, 0xce, 0x33, 0x55, 0x99, 0x95, 0x7b, 0x8e, 0xc8, 0x8, 0x76, 0xd9, 0xa0, 0x85, 0xae, 0x8, 0x49, 0x7, 0xbc, 0x59, 0x61, 0xb2, 0xb, 0xf5, 0xf6, 0xca, 0x58, 0xd5, 0xda, 0xb3, 0x8a, 0xdb}, - output224: []byte{0x4e, 0x28, 0x86, 0x7d, 0xce, 0xf3, 0xa7, 0xb7, 0x59, 0xca, 0x24, 0xd8, 0x10, 0x7b, 0xeb, 0xc, 0xbf, 0x9d, 0xb0, 0xf1, 0xa, 0x3c, 0x41, 0xa, 0x9b, 0x4b, 0xa8, 0xc8}, - output256: []byte{0x3e, 0x4, 0xee, 0x53, 0x95, 0x5, 0xc5, 0x2d, 0x81, 0x4c, 0xab, 0x3c, 0x5c, 0xdd, 0x7d, 0xf2, 0xd6, 0xee, 0xe6, 0x27, 0xea, 0x44, 0x18, 0x81, 0x53, 0xea, 0x6b, 0x8c, 0x8b, 0xe5, 0xf6, 0xc2}, - output384: []byte{0xa, 0x83, 0x4e, 0x11, 0x1b, 0x4e, 0x84, 0xe, 0x78, 0x7c, 0x19, 0x74, 0x84, 0x65, 0xa4, 0x7d, 0x88, 0xb3, 0xf0, 0xf3, 0xda, 0xaf, 0x15, 0xdb, 0x25, 0x53, 0x6b, 0xdc, 0x60, 0x78, 0xfa, 0x9c, 0x5, 0xe6, 0xc9, 0x53, 0x83, 0x2, 0x74, 0x22, 0x39, 0x68, 0x84, 0x7d, 0xa8, 0xbf, 0xd2, 0xd}, - output512: []byte{0xe2, 0x5, 0x28, 0x84, 0xd1, 0x12, 0x23, 0x88, 0x7, 0xc0, 0x2c, 0x13, 0x52, 0x47, 0xf7, 0x6e, 0xe, 0x39, 0x4b, 0xd6, 0x58, 0x3b, 0xa8, 0x3e, 0xd2, 0x73, 0x1c, 0xf6, 0x8f, 0x5, 0x72, 0x76, 0x27, 0x2b, 0x89, 0x1a, 0x76, 0x1c, 0xde, 0xc6, 0xd8, 0xad, 0x2e, 0x3f, 0x33, 0xe8, 0x6a, 0xe9, 0xd9, 0xa2, 0x34, 0x68, 0x2b, 0xce, 0x7a, 0x53, 0x81, 0x62, 0x35, 0x69, 0x2d, 0x2c, 0xf8, 0x21}, - }, - { - msg: []byte{0xe3, 0x57, 0x80, 0xeb, 0x97, 0x99, 0xad, 0x4c, 0x77, 0x53, 0x5d, 0x4d, 0xdb, 0x68, 0x3c, 0xf3, 0x3e, 0xf3, 0x67, 0x71, 0x53, 0x27, 0xcf, 0x4c, 0x4a, 0x58, 0xed, 0x9c, 0xbd, 0xcd, 0xd4, 0x86, 0xf6, 0x69, 0xf8, 0x1, 0x89, 0xd5, 0x49, 0xa9, 0x36, 0x4f, 0xa8, 0x2a, 0x51, 0xa5, 0x26, 0x54, 0xec, 0x72, 0x1b, 0xb3, 0xaa, 0xb9, 0x5d, 0xce, 0xb4, 0xa8, 0x6a, 0x6a, 0xfa, 0x93, 0x82, 0x6d, 0xb9, 0x23, 0x51, 0x7e, 0x92, 0x8f, 0x33, 0xe3, 0xfb, 0xa8, 0x50, 0xd4, 0x56, 0x60, 0xef, 0x83, 0xb9, 0x87, 0x6a, 0xcc, 0xaf, 0xa2, 0xa9, 0x98, 0x7a, 0x25, 0x4b, 0x13, 0x7c, 0x6e, 0x14, 0xa, 0x21, 0x69, 0x1e, 0x10, 0x69, 0x41, 0x38, 0x48}, - output224: []byte{0x5c, 0xc, 0x2d, 0xf1, 0x3a, 0x1f, 0xd6, 0x76, 0x2b, 0x6e, 0x50, 0xfb, 0x3e, 0x8, 0xe, 0x64, 0x9c, 0x3a, 0x7a, 0x8d, 0xda, 0x41, 0x5c, 0x42, 0xfb, 0x63, 0x71, 0x36}, - output256: []byte{0xe3, 0x60, 0xb4, 0x24, 0xa5, 0xc0, 0x67, 0x4, 0xd1, 0x48, 0x35, 0x2e, 0x4, 0xf4, 0x65, 0x1f, 0x8d, 0x3b, 0x38, 0x5c, 0x1, 0xf2, 0x4f, 0xda, 0x9, 0xd2, 0x66, 0xd4, 0xed, 0x7f, 0xf6, 0x62}, - output384: []byte{0xd1, 0xc0, 0xfa, 0x85, 0xc8, 0xd1, 0x83, 0xbe, 0xff, 0x99, 0xad, 0x9d, 0x75, 0x2b, 0x26, 0x3e, 0x28, 0x6b, 0x47, 0x7f, 0x79, 0xf0, 0x71, 0xb, 0x1, 0x3, 0x17, 0x1, 0x73, 0x97, 0x81, 0x33, 0x44, 0xb9, 0x9d,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x78, 0xd6}, - output224: []byte{0x36, 0xf5, 0x63, 0xe, 0xc2, 0x82, 0x9b, 0xf, 0xba, 0xd8, 0x4f, 0x15, 0x9, 0x32, 0xe4, 0x66, 0x47, 0xed, 0xcc, 0x45, 0x4e, 0x6, 0xb2, 0x31, 0x66, 0x66, 0x1d, 0x60}, - output256: []byte{0xd, 0x3b, 0xec, 0xb9, 0xe1, 0xb4, 0xae, 0x1f, 0x15, 0xc9, 0xee, 0x98, 0x73, 0x2b, 0x47, 0x96, 0xe9, 0x9f, 0xd7, 0x99, 0xf7, 0x6e, 0xd7, 0x33, 0x2a, 0x68, 0xab, 0x36, 0xc7, 0x7a, 0x1e, 0xf9}, - output384: []byte{0x6a, 0xed, 0xcf, 0x44, 0x26, 0xb2, 0x48, 0x3c, 0xd, 0xd, 0x4, 0x69, 0x5b, 0xcc, 0x5, 0x2b, 0xed, 0xd0, 0x4f, 0xa4, 0xd1, 0x7a, 0x1b, 0xbb, 0x27, 0x97, 0xf6, 0x27, 0x2f, 0xa4, 0x76, 0xbf, 0xc1, 0x38, 0xe4, 0x9, 0x14, 0x9, 0xfe, 0xb1, 0xac, 0xe, 0x8b, 0xff, 0x35, 0xa, 0x66, 0x63}, - output512: []byte{0x41, 0x83, 0xf9, 0x67, 0x59, 0xe7, 0xc0, 0x62, 0x8f, 0x2f, 0xc8, 0x19, 0x79, 0x27, 0x4f, 0x42, 0x11, 0x1a, 0x43, 0xbd, 0x5d, 0xbb, 0x36, 0x85, 0xbb, 0x21, 0x70, 0x4c, 0xe6, 0xb0, 0xed, 0x3d, 0x16, 0x4d, 0xec, 0xf2, 0x8a, 0x3a, 0x99, 0x1b, 0x30, 0x3e, 0x1d, 0x7b, 0x86, 0xe2, 0xb1, 0x75, 0xba, 0x89, 0x94, 0x5a, 0x85, 0x24, 0xf9, 0xc9, 0x31, 0x8f, 0x12, 0xb1, 0x60, 0xa1, 0xe4, 0xd1}, - }, - { - msg: []byte{0x59, 0x54, 0xba, 0xb5, 0x12, 0xcf, 0x32, 0x7d, 0x66, 0xb5, 0xd9, 0xf2, 0x96, 0x18, 0x0, 0x80, 0x40, 0x26, 0x24, 0xad, 0x76, 0x28, 0x50, 0x6b, 0x55, 0x5e, 0xea, 0x83, 0x82, 0x56, 0x23, 0x24, 0xcf, 0x45, 0x2f, 0xba, 0x4a, 0x21, 0x30, 0xde, 0x3e, 0x16, 0x5d, 0x11, 0x83, 0x1a, 0x27, 0xd, 0x9c, 0xb9, 0x7c, 0xe8, 0xc2, 0xd3, 0x2a, 0x96, 0xf5, 0xd, 0x71, 0x60, 0xb, 0xb4, 0xca, 0x26, 0x8c, 0xf9, 0x8e, 0x90, 0xd6, 0x49, 0x6b, 0xa, 0x66, 0x19, 0xa5, 0xa8, 0xc6, 0x3d, 0xb6, 0xd8, 0xa0, 0x63, 0x4d, 0xfc, 0x6c, 0x7e, 0xc8, 0xea, 0x9c, 0x0, 0x6b, 0x6c, 0x45, 0x6f, 0x1b, 0x20, 0xcd, 0x19, 0xe7, 0x81, 0xaf, 0x20, 0x45, 0x4a, 0xc8, 0x80}, - output224: []byte{0xda, 0xc2, 0x59, 0x4b, 0xcd, 0x35, 0x7e, 0x63, 0x92, 0x8a, 0x21, 0xe9, 0x83, 0x48, 0xf2, 0x7d, 0xf, 0xa2, 0xc7, 0xe, 0xb0, 0x7c, 0x7e, 0x8e, 0x93, 0xd6, 0xd8, 0x4e}, - output256: []byte{0x3a, 0xad, 0xd7, 0xe2, 0x8, 0x6d, 0x38, 0x38, 0x32, 0x48, 0x9a, 0xa3, 0x8, 0x8e, 0x90, 0x3f, 0x5c, 0x6f, 0xa8, 0xe3, 0x8d, 0xf2, 0xcf, 0x87, 0x6e, 0xb, 0x4d, 0xcd, 0xdc, 0xa5, 0xc9, 0x23}, - output384: []byte{0xac, 0xb7, 0x1, 0x3c, 0xe7, 0x51, 0x24, 0x38, 0x81, 0x87, 0xdc, 0xe, 0x74, 0x30, 0xcb, 0x74, 0xa3, 0x14, 0xd6, 0x1,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, 0x14, 0xe7, 0x39, 0xd7, 0xfe, 0xbf, 0xf, 0xe3, 0xc3, 0x2c, 0x17, 0xaa, 0x18, 0x8a, 0x86, 0x83}, - output224: []byte{0x24, 0x97, 0xd, 0xf3, 0xcf, 0x8c, 0x9e, 0x30, 0xdc, 0xbe, 0x66, 0x18, 0x17, 0xff, 0x74, 0x53, 0x8a, 0xd4, 0x3b, 0xc9, 0xb, 0x14, 0x9e, 0xd7, 0xca, 0xb7, 0x81, 0x1b}, - output256: []byte{0x71, 0x5c, 0xed, 0x57, 0x76, 0xa8, 0x2, 0xeb, 0x8e, 0xe0, 0x2c, 0x9d, 0x46, 0x54, 0x3f, 0xf4, 0x6f, 0xe7, 0xa9, 0xcd, 0x19, 0x2f, 0xa7, 0xd4, 0xff, 0xb6, 0xe8, 0x14, 0x27, 0xfe, 0x1b, 0x71}, - output384: []byte{0xf9, 0x47, 0x46, 0x9d, 0xb7, 0x12, 0xea, 0x26, 0xf2, 0x5f, 0x70, 0x9f, 0xf7, 0x87, 0x91, 0x36, 0xea, 0x2a, 0x79, 0xe0, 0xa2, 0xd0, 0xed, 0x5e, 0xe4, 0xad, 0xf0, 0xe1, 0x67, 0xf1, 0x6, 0xbc, 0x41, 0xc, 0x93, 0xae, 0x1d, 0x98, 0x6e, 0xc2, 0x11, 0xe0, 0xfd, 0x9a, 0x40, 0x74, 0x18, 0x57}, - output512: []byte{0x17, 0x2f, 0xc, 0x68, 0x3, 0x10, 0x37, 0x51, 0x56, 0x91, 0x1c, 0x7, 0xb1, 0x81, 0x9f, 0xb, 0x9d, 0x12, 0x45, 0x14, 0xec, 0x2c, 0x37, 0x50, 0xcb, 0x2e, 0x39, 0x92, 0x6a, 0x28, 0xa4, 0x63, 0x6a, 0xb7, 0xec, 0xdc, 0xdd, 0x9d, 0x6a, 0x96, 0xd, 0x16, 0xc8, 0x64, 0xdd, 0x58, 0x56, 0x45, 0xd8, 0x7f, 0x14, 0x5c, 0x5b, 0x31, 0x53, 0x81, 0xf3, 0x56, 0x65, 0x6d, 0x61, 0x7f, 0xe9, 0x7d}, - }, - { - msg: []byte{0xf3, 0x1e, 0x8b, 0x4f, 0x9e, 0x6, 0x21, 0xd5, 0x31, 0xd2, 0x2a, 0x38, 0xb, 0xe5, 0xd9, 0xab, 0xd5, 0x6f, 0xae, 0xc5, 0x3c, 0xbd, 0x39, 0xb1, 0xfa, 0xb2, 0x30, 0xea, 0x67, 0x18, 0x44, 0x40, 0xe5, 0xb1, 0xd1, 0x54, 0x57, 0xbd, 0x25, 0xf5, 0x62, 0x4, 0xfa, 0x91, 0x7f, 0xa4, 0x8e, 0x66, 0x90, 0x16, 0xcb, 0x48, 0xc1, 0xff, 0xc1, 0xe1, 0xe4, 0x52, 0x74, 0xb3, 0xb4, 0x73, 0x79, 0xe0, 0xa, 0x43, 0x84, 0x3c, 0xf8, 0x60, 0x1a, 0x55, 0x51, 0x41, 0x1e, 0xc1, 0x25, 0x3, 0xe5, 0xaa, 0xc4, 0x3d, 0x86, 0x76, 0xa1, 0xb2, 0x29, 0x7e, 0xc7, 0xa0, 0x80, 0xd, 0xbf, 0xee, 0x4, 0x29, 0x2e, 0x93, 0x7f, 0x21, 0xc0, 0x5, 0xf1, 0x74, 0x11, 0x47, 0x30, 0x41}, - output224: []byte{0xad, 0x9b, 0xf4, 0x20, 0xd2, 0xb5, 0x70, 0xeb, 0xe7, 0x92, 0x3a, 0x76, 0xb2, 0x53, 0xf1, 0x56, 0xf3, 0x51, 0x37, 0x12, 0x95, 0x5b, 0xcb, 0xb9, 0xa8, 0x73, 0x94, 0xdb}, - output256: []byte{0xdd, 0xe6, 0x1f, 0x8b, 0xe2, 0x5b, 0x8b, 0x23, 0xe1, 0x21, 0x2c, 0x1c, 0xb, 0x8a, 0x85, 0xa0, 0xd0, 0x2d, 0x85, 0x48, 0xbb, 0x17, 0xd3, 0x77, 0x13, 0x3e, 0x3c, 0x6, 0xdd, 0xb5, 0x8c, 0xa2}, - output384: []byte{0x65, 0x98, 0x9b, 0xf4, 0xeb, 0xbf, 0x4c, 0x21, 0xb3, 0xdd, 0x34, 0x55, 0x1d, 0x3f, 0x61, 0x67, 0x91, 0x2, 0x36, 0x67, 0x1b, 0xb7, 0xf3, 0x48, 0xdc, 0x55, 0x2a, 0xdb, 0x80, 0x28, 0xa4, 0x68, 0xfa, 0x40, 0xef, 0x4a, 0x8c, 0x12, 0x27, 0xa1, 0xa4, 0x1c, 0x28, 0x10, 0x5e, 0x64, 0xac, 0x20}, - output512: []byte{0x41, 0xd, 0xba, 0xa5, 0xe3, 0x45, 0x3f, 0x2d, 0xaf, 0xce, 0x13, 0x5d, 0xc0, 0x14, 0xf2, 0x8f, 0xbf, 0x69, 0x3c, 0x84, 0xeb, 0x7d, 0x4b, 0xec, 0xb8, 0xa, 0x3d, 0xb3, 0x2e, 0x16, 0xe8, 0x90, 0x62, 0xb3, 0xff, 0x59, 0xc1, 0xdf, 0xdf, 0xab, 0x32, 0xd8, 0x4d, 0x20, 0x28, 0x46, 0x32, 0xa2, 0xac, 0x7f, 0x8f, 0x88, 0xd4, 0xb7, 0x2, 0x3f, 0x87, 0x94, 0x63, 0xba, 0x18, 0xff, 0x65, 0x53}, - }, - { - msg: []byte{0x75, 0x8e, 0xa3, 0xfe, 0xa7, 0x38, 0x97, 0x3d, 0xb0, 0xb8, 0xbe, 0x7e, 0x59, 0x9b, 0xbe, 0xf4, 0x51, 0x93, 0x73, 0xd6, 0xe6, 0xdc, 0xd7, 0x19, 0x5e, 0xa8, 0x85, 0xfc, 0x99, 0x1d, 0x89, 0x67, 0x62, 0x99, 0x27, 0x59, 0xc2, 0xa0, 0x90, 0x2, 0x91, 0x2f, 0xb0, 0x8e, 0xc, 0xb5, 0xb7, 0x6f, 0x49, 0x16, 0x2a, 0xeb, 0x8c, 0xf8, 0x7b, 0x17, 0x2c, 0xf3, 0xad, 0x19, 0x2, 0x53, 0xdf, 0x61, 0x2f, 0x77, 0xb1, 0xf0, 0xc5, 0x32, 0xe3, 0xb5, 0xfc, 0x99, 0xc2, 0xd3, 0x1f, 0x8f, 0x65, 0x1, 0x16, 0x95, 0xa0, 0x87, 0xa3, 0x5e, 0xe4, 0xee, 0xe5, 0xe3, 0x34, 0xc3, 0x69, 0xd8, 0xee, 0x5d, 0x29, 0xf6, 0x95, 0x81, 0x5d, 0x86, 0x6d, 0xa9, 0x9d, 0xf3, 0xf7, 0x94, 0x3}, - output224: []byte{0x2f, 0x60, 0x92, 0x82, 0x63, 0xfe, 0x1d, 0x5f, 0xa5, 0x13, 0x6d, 0xa8, 0xde, 0x1d, 0x2c, 0x3b, 0x60, 0xbd, 0x4b, 0x70, 0xa, 0x3e, 0x2c, 0x25, 0x6e, 0x95, 0x36, 0xef}, - output256: []byte{0x5, 0x9f, 0x2b, 0xed, 0xf4, 0xa6, 0xee, 0xfb, 0x95, 0xfc, 0x5c, 0xa, 0xe1, 0x75, 0x56, 0xce, 0x8b, 0xdd, 0xc5, 0xe1, 0x88, 0xf, 0xab, 0x2f, 0x68, 0x8a, 0x3, 0xa4, 0x6b, 0xb2, 0x8c, 0x5f}, - output384: []byte{0xb7, 0x7a, 0x69, 0xe3, 0x73, 0xaf, 0xf, 0x73, 0x3c, 0xda, 0xd3, 0x99, 0xc9, 0xb1, 0x26, 0x42, 0xa0, 0x46, 0xe1, 0xa7, 0x89, 0x3d, 0x33, 0x82, 0x94, 0x3a, 0x83, 0x67, 0xd3, 0x77, 0x40, 0xdf, 0x53, 0x91, 0x6f, 0x6d, 0xaf, 0x90, 0x51, 0x7b, 0x39, 0x62, 0x1c, 0x14, 0x34, 0x37, 0x54, 0xa2}, - output512: []byte{0xf9, 0x3a, 0x9, 0x91, 0x59, 0xc3, 0x96, 0x17, 0xb7, 0x5b, 0x18, 0x8d, 0x52, 0x7f, 0xc4, 0xdb, 0x28, 0x7c, 0xbb, 0x4f, 0xdd, 0xdb, 0xa5, 0xad, 0x4d, 0xcb, 0x4c, 0xff, 0xc4, 0xdc, 0x59, 0x76, 0x2b, 0xbc,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x96, 0x5d, 0x9e, 0xb, 0x90, 0xd7, 0x9f, 0xff, 0xbc, 0x54, 0xa2, 0x1, 0x8f, 0x4c, 0x68, 0x22, 0x46, 0x82, 0xf3, 0x60, 0x3f, 0x3f}, - output384: []byte{0x3d, 0x14, 0xb6, 0xfa, 0xe6, 0x15, 0x6e, 0x78, 0x76, 0x36, 0x78, 0x97, 0xa4, 0x92, 0x69, 0x18, 0x1e, 0xa5, 0x8c, 0xc3, 0xca, 0x96, 0x21, 0xc0, 0xf8, 0x1d, 0x6a, 0x5f, 0xb6, 0xf6, 0x15, 0x68, 0xd, 0x90, 0x9b, 0x29, 0xf6, 0xaf, 0x7e, 0x62, 0xfa, 0xd0, 0x4d, 0x70, 0x4, 0x6b, 0xe9, 0x97}, - output512: []byte{0x5, 0xe6, 0x99, 0x84, 0xee, 0x99, 0xaa, 0x2b, 0xc8, 0x51, 0x8, 0x3a, 0xa4, 0x4e, 0xe5, 0x6f, 0xee, 0xf8, 0x6c, 0x45, 0x88, 0x88, 0x67, 0xcd, 0xcd, 0xd0, 0xc7, 0xa8, 0x4, 0x90, 0x80, 0xae, 0x78, 0x58, 0xb9, 0x3c, 0x19, 0x95, 0x3a, 0x88, 0x1b, 0xe5, 0xc0, 0x36, 0xbd, 0x8f, 0xe8, 0x36, 0x28, 0xc2, 0xe3, 0xaa, 0x99, 0x39, 0xa2, 0x88, 0xb4, 0xac, 0x4b, 0xc2, 0x87, 0x6c, 0x2f, 0xbc}, - }, - { - msg: []byte{0xf6, 0x90, 0xa1, 0x32, 0xab, 0x46, 0xb2, 0x8e, 0xdf, 0xa6, 0x47, 0x92, 0x83, 0xd6, 0x44, 0x4e, 0x37, 0x1c, 0x64, 0x59, 0x10, 0x8a, 0xfd, 0x9c, 0x35, 0xdb, 0xd2, 0x35, 0xe0, 0xb6, 0xb6, 0xff, 0x4c, 0x4e, 0xa5, 0x8e, 0x75, 0x54, 0xbd, 0x0, 0x24, 0x60, 0x43, 0x3b, 0x21, 0x64, 0xca, 0x51, 0xe8, 0x68, 0xf7, 0x94, 0x7d, 0x7d, 0x7a, 0xd, 0x79, 0x2e, 0x4a, 0xbf, 0xb, 0xe5, 0xf4, 0x50, 0x85, 0x3c, 0xc4, 0xd, 0x85, 0x48, 0x5b, 0x2b, 0x88, 0x57, 0xea, 0x31, 0xb5, 0xea, 0x6e, 0x4c, 0xcf, 0xa2, 0xf3, 0xa7, 0xef, 0x33, 0x80, 0x6, 0x6d, 0x7d, 0x89, 0x79, 0xfd, 0xac, 0x61, 0x8a, 0xad, 0x3d, 0x7e, 0x88, 0x6d, 0xea, 0x4f, 0x0, 0x5a, 0xe4, 0xad, 0x5, 0xe5, 0x6, 0x5f}, - output224: []byte{0x19, 0xe, 0x9f, 0xda, 0x8a, 0x7d, 0x78, 0x34, 0x3f, 0xf2, 0x4a, 0xde, 0x9f, 0xee, 0x69, 0x65, 0xc, 0x76, 0x31, 0xad, 0x63, 0x29, 0xd1, 0x7d, 0x4b, 0xd5, 0x75, 0xdb}, - output256: []byte{0x9a, 0x78, 0xe0, 0xb5, 0xa3, 0x4c, 0xbf, 0x17, 0x16, 0xf1, 0x4c, 0xf7, 0xb6, 0x7e, 0xfd, 0xc4, 0x54, 0xa, 0x75, 0xcc, 0x64, 0x65, 0x38, 0xa1, 0x1a, 0x8e, 0xfd, 0x9d, 0x7c, 0xd7, 0x52, 0x9f}, - output384: []byte{0x45, 0x6a, 0xd0, 0x19, 0x8, 0xe1, 0x87, 0xca, 0x2c, 0xe9, 0xe7, 0xa4, 0xda, 0xed, 0x87, 0x88, 0xc9, 0x9, 0xe9, 0xbc, 0x97, 0x4e, 0xfd, 0x1c, 0x9a, 0x44, 0xac, 0x36, 0xdb, 0x9b, 0x6d, 0xa9, 0x85, 0xc9, 0x47, 0xc7, 0xe0, 0xa4, 0x7a, 0xb2, 0x7b, 0xf1, 0xc, 0xd7, 0x60, 0xfa, 0x48, 0xaf}, - output512: []byte{0xbe, 0x22, 0xf3, 0xe2, 0x53, 0xc2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 0xd2, 0x16, 0xe3, 0xda, 0x51, 0xef, 0x7c, 0x55, 0x19, 0xb4, 0x83, 0xdb, 0x43, 0x9d, 0x37, 0x25, 0x6d, 0xbe}, - output256: []byte{0x42, 0x30, 0x5a, 0x25, 0x1a, 0x80, 0x9, 0xed, 0xfd, 0x62, 0xc7, 0xd9, 0x19, 0x10, 0xb9, 0x6b, 0x9b, 0x5d, 0xd8, 0xfd, 0xa5, 0xb1, 0x32, 0x6f, 0xe4, 0x1e, 0xf6, 0xee, 0xf9, 0x78, 0xd1, 0xbe}, - output384: []byte{0xc2, 0x6b, 0xda, 0xc4, 0x54, 0xe1, 0xad, 0xc0, 0xd0, 0x90, 0xd0, 0xc5, 0x25, 0x4a, 0x29, 0x96, 0x66, 0x11, 0xb6, 0x67, 0x30, 0x14, 0xcb, 0xac, 0xa2, 0x4d, 0x26, 0xb6, 0xf6, 0x3e, 0xc7, 0xe8, 0xf9, 0x93, 0xba, 0x3d, 0xf7, 0xdf, 0x89, 0x77, 0xe, 0x90, 0x2d, 0x5f, 0x65, 0x74, 0xf6, 0xa8}, - output512: []byte{0x1d, 0x18, 0x36, 0xc4, 0xe2, 0xc3, 0xeb, 0x27, 0xa7, 0x4a, 0x9c, 0xd6, 0x0, 0xc0, 0x64, 0x39, 0x1b, 0xd9, 0xed, 0xd4, 0x54, 0x64, 0xa5, 0x79, 0x51, 0x82, 0xc8, 0x79, 0x47, 0x48, 0xba, 0x51, 0xa3, 0x45, 0xc6, 0xfa, 0xe2, 0xb9, 0x1f, 0x57, 0x58, 0x40, 0x1e, 0x4f, 0x42, 0x7d, 0x50, 0xb6, 0x88, 0x2b, 0x1d, 0xf0, 0x97, 0x79, 0x76, 0xc2, 0xc9, 0x43, 0x2c, 0x1a, 0x9b, 0x3a, 0xe0, 0x3f}, - }, - { - msg: []byte{0xbe, 0xfa, 0xb5, 0x74, 0x39, 0x6d, 0x7f, 0x8b, 0x67, 0x5, 0xe2, 0xd5, 0xb5, 0x8b, 0x2c, 0x1c, 0x82, 0xb, 0xb2, 0x4e, 0x3f, 0x4b, 0xae, 0x3e, 0x8f, 0xbc, 0xd3, 0x6d, 0xbf, 0x73, 0x4e, 0xe1, 0x4e, 0x5d, 0x6a, 0xb9, 0x72, 0xae, 0xdd, 0x35, 0x40, 0x23, 0x54, 0x66, 0xe8, 0x25, 0x85, 0xe, 0xe4, 0xc5, 0x12, 0xea, 0x97, 0x95, 0xab, 0xfd, 0x33, 0xf3, 0x30, 0xd9, 0xfd, 0x7f, 0x79, 0xe6, 0x2b, 0xbb, 0x63, 0xa6, 0xea, 0x85, 0xde, 0x15, 0xbe, 0xae, 0xea, 0x6f, 0x8d, 0x20, 0x4a, 0x28, 0x95, 0x60, 0x59, 0xe2, 0x63, 0x2d, 0x11, 0x86, 0x1d, 0xfb, 0xe, 0x65, 0xbc, 0x7, 0xac, 0x8a, 0x15, 0x93, 0x88, 0xd5, 0xc3, 0x27, 0x7e, 0x22, 0x72, 0x86, 0xf6, 0x5f, 0xf5, 0xe5, 0xb5, 0xae, 0xc1}, - output224: []byte{0x6c, 0xaf, 0x80, 0x7f, 0x6a, 0xbc, 0x1a, 0x77, 0x21, 0xa5, 0xf2, 0x9, 0xfc, 0x9, 0xfd, 0x0, 0x47, 0x4b, 0x9e, 0x2a, 0x77, 0xef, 0x7b, 0x57, 0xe1, 0x32, 0x2, 0x71}, - output256: []byte{0x6b, 0x9e, 0x8f, 0x3e, 0x82, 0xea, 0x17, 0x4e, 0xbc, 0x88, 0xa5, 0x3c, 0x5d, 0xed, 0x6, 0x27, 0x1d, 0x38, 0xf7, 0x9e, 0x9c, 0xec, 0x57, 0x1a, 0x9d, 0x19, 0x5e, 0xf5, 0x49, 0x10, 0x2e, 0xb8}, - output384: []byte{0x1d, 0x85, 0xbf, 0x9a, 0xa2, 0xb6, 0xdc, 0xc3, 0x10, 0x5e, 0x7d, 0x7f, 0x91, 0x6, 0x9f, 0x1, 0xe4, 0xc9, 0x98, 0xd6, 0xf0, 0x3b, 0x77, 0x65, 0xd, 0x75, 0x83, 0x9d, 0x65, 0xa7, 0xa0, 0x49, 0x19, 0x6f, 0xd9, 0x35, 0xaf, 0xef, 0xfd, 0xeb, 0x65, 0x7b, 0xc8, 0xf9, 0x6b, 0x7c, 0x17, 0xb5}, - output512: []byte{0xcb, 0xd, 0x33, 0xc1, 0x73, 0xc7, 0x65, 0xbb, 0xa3, 0x71, 0x4d, 0x56, 0xa4, 0xcf, 0x48, 0xfd, 0x63, 0x20, 0xab, 0x8c, 0x53, 0x17, 0xe7, 0xab, 0x1a, 0x46, 0x47, 0x2a, 0xfb, 0x75, 0x62, 0x32, 0xcd, 0x27, 0xf5, 0x14, 0x73, 0xdc, 0xf9, 0xbd, 0x7d, 0xac, 0x1a, 0xa7, 0xf6, 0x69, 0x35, 0x3f, 0xd8, 0xf3, 0xd2, 0x7d, 0x17, 0xd3, 0xfe, 0x3e, 0xb3, 0x38, 0x68, 0x76, 0xec, 0xa3, 0x8a, 0x85}, - }, - { - msg: []byte{0x8e, 0x58, 0x14, 0x4f, 0xa9, 0x17, 0x9d, 0x68, 0x64, 0x78, 0x62, 0x2c, 0xe4, 0x50, 0xc7, 0x48, 0x26, 0xc, 0x95, 0xd1, 0xba, 0x43, 0xb8, 0xf9, 0xb5, 0x9a, 0xbe, 0xca, 0x8d, 0x93, 0x48, 0x8d, 0xa7, 0x34, 0x63, 0xef, 0x40, 0x19, 0x8b, 0x4d, 0x16, 0xfb, 0xb, 0x7, 0x7, 0x20, 0x13, 0x47, 0xe0, 0x50, 0x6f, 0xf1, 0x9d, 0x1, 0xbe, 0xa0, 0xf4, 0x2b, 0x8a, 0xf9, 0xe7, 0x1a, 0x1f, 0x1b, 0xd1, 0x68, 0x78, 0x10, 0x69, 0xd4, 0xd3, 0x38, 0xfd, 0xef, 0x0, 0xbf, 0x41, 0x9f, 0xbb, 0x0, 0x30, 0x31, 0xdf, 0x67, 0x1f, 0x4a, 0x37, 0x97, 0x95, 0x64, 0xf6, 0x92, 0x82, 0xde, 0x9c, 0x65, 0x40, 0x78, 0x47, 0xdd, 0xd, 0xa5, 0x5, 0xab, 0x16, 0x41, 0xc0, 0x2d, 0xea, 0x4f, 0xd, 0x83, 0x49, 0x86}, - output224: []byte{0x64, 0xcd, 0x52, 0x91, 0xa1, 0xa0, 0x80, 0x7b, 0xa7, 0xc1, 0x41, 0x3, 0xa0, 0xf4, 0x6c, 0x63, 0x67, 0x95, 0xf8, 0xf8, 0xd3, 0xa1, 0x2e, 0x59, 0xe8, 0x8d, 0x9c, 0x51}, - output256: []byte{0x35, 0x8d, 0xe4, 0xc1, 0xed, 0x30, 0xf4, 0x8b, 0x8, 0x4f, 0x96, 0x1f, 0x65, 0x3f, 0xeb, 0xc6, 0x93, 0x18, 0xf9, 0x38, 0x83, 0x61, 0x2d, 0x5a, 0x4, 0xb9, 0x13, 0x9a, 0x14, 0xec, 0x70, 0x2e}, - output384: []byte{0x8, 0x5c, 0xfa, 0x58, 0x1c, 0xf3, 0xf4, 0xf1, 0x94, 0x16, 0xbe, 0xe3, 0xed, 0x5a, 0xc2, 0x54, 0x46, 0x62, 0xaa, 0x51, 0xbd, 0xf1, 0xd2, 0xe3, 0x48, 0xd9, 0xbc, 0xc2, 0x73, 0x43, 0x48, 0x7d, 0xf2, 0xb, 0x18, 0xd9, 0xf6, 0xfb, 0x64, 0x56, 0x58, 0x68, 0x50, 0x4a, 0x68, 0x5, 0xd1, 0x76}, - output512: []byte{0xb5, 0x79, 0xad, 0xc, 0x75, 0xb, 0x91, 0xe0, 0x67, 0x1b, 0xb7, 0xf0, 0x48, 0x2a, 0x51, 0x98, 0x35, 0xd1, 0x55, 0xae, 0x1a, 0x4d, 0xb9, 0x21, 0x12, 0xe6, 0x6f, 0xbd, 0x15, 0x88, 0x35, 0xe0, 0xc2, 0x9e, 0x2f, 0x12, 0x2a, 0x8c, 0x54, 0xc5, 0x30, 0xf9, 0x26, 0x33, 0xf6, 0xec, 0x7b, 0x22, 0x2c, 0xa3, 0xce, 0xd4, 0x5b, 0x4b, 0x5a, 0x24, 0x42, 0x6d, 0x99, 0xc5, 0x9c, 0x1b, 0x66, 0x9}, - }, - { - msg: []byte{0xb5, 0x5c, 0x10, 0xea, 0xe0, 0xec, 0x68, 0x4c, 0x16, 0xd1, 0x34, 0x63, 0xf2, 0x92, 0x91, 0xbf, 0x26, 0xc8, 0x2e, 0x2f, 0xa0, 0x42, 0x2a, 0x99, 0xc7, 0x1d, 0xb4, 0xaf, 0x14, 0xdd, 0x9c, 0x7f, 0x33, 0xed, 0xa5, 0x2f, 0xd7, 0x3d, 0x1, 0x7c, 0xc0, 0xf2, 0xdb, 0xe7, 0x34, 0xd8, 0x31, 0xf0, 0xd8, 0x20, 0xd0, 0x6d, 0x5f, 0x89, 0xda, 0xcc, 0x48, 0x57, 0x39, 0x14, 0x4f, 0x8c, 0xfd, 0x47, 0x99, 0x22, 0x3b, 0x1a, 0xff, 0x90, 0x31, 0xa1, 0x5, 0xcb, 0x6a, 0x2, 0x9b, 0xa7, 0x1e, 0x6e, 0x58, 0x67, 0xd8, 0x5a, 0x55, 0x49, 0x91, 0xc3, 0x8d, 0xf3, 0xc9, 0xef, 0x8c, 0x1e, 0x1e, 0x9a, 0x76, 0x30, 0xbe, 0x61, 0xca, 0xab, 0xca, 0x69, 0x28, 0xc, 0x39, 0x9c, 0x1f, 0xb7, 0xa1, 0x2d, 0x12, 0xae, 0xfc}, - output224: []byte{0x29, 0x49, 0x12, 0x56, 0xa8, 0xb, 0xf1, 0xa9, 0x32, 0x53, 0x48, 0xb5, 0x84, 0x1e, 0xdc, 0x72, 0x6f, 0xa8, 0xa5, 0x31, 0x17, 0x26, 0x8c, 0x47, 0xf7, 0x4b, 0x5e, 0x49}, - output256: []byte{0x4a, 0x7b, 0xd1, 0x8a, 0xe1, 0xe, 0xb9, 0x45, 0x89, 0x24, 0xaa, 0x5c, 0xa0, 0xd, 0x3f, 0x63, 0x4a, 0xb9, 0x75, 0x36, 0x28, 0x10, 0x7f, 0x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fe, 0x75, 0xff, 0xcd, 0xdd, 0x6c, 0x5c, 0x2e, 0x2a, 0x4c, 0xd4, 0x5f, 0x63, 0xc9, 0x62, 0xd0, 0x10, 0x64, 0x50, 0x58, 0xd3, 0x65, 0x71, 0x40, 0x4a, 0x6d, 0x2b, 0x4f, 0x44, 0x75, 0x54, 0x34, 0xd7, 0x69, 0x98, 0xe8, 0x34, 0x9, 0xc3, 0x20, 0x5a, 0xa1, 0x61, 0x5d, 0xb4, 0x40, 0x57, 0xdb, 0x99, 0x12, 0x31, 0xd2, 0xcb, 0x42, 0x62, 0x45, 0x74, 0xf5, 0x45}, - output224: []byte{0xa5, 0x23, 0x44, 0x9b, 0x77, 0xa, 0x8d, 0xe3, 0xb3, 0x9c, 0xd4, 0x46, 0x4, 0x61, 0x49, 0xfe, 0xae, 0xe3, 0x27, 0xd6, 0xd5, 0xb3, 0x99, 0x29, 0xb9, 0xaa, 0xc9, 0x15}, - output256: []byte{0x98, 0x89, 0xe4, 0xb3, 0xb1, 0x29, 0x4a, 0x1, 0x55, 0x6f, 0xa9, 0xde, 0x6a, 0x6a, 0x50, 0x8a, 0x9a, 0x76, 0x3d, 0x51, 0x33, 0xfd, 0xcd, 0x49, 0x37, 0xb6, 0xbb, 0x23, 0xca, 0x3e, 0x19, 0x1}, - output384: []byte{0xcd, 0x40, 0xb3, 0x5f, 0xbd, 0x90, 0xb0, 0x4d, 0x6, 0x41, 0xf7, 0x10, 0x88, 0xf7, 0xc6, 0x15, 0x9d, 0x8e, 0xb1, 0x6d, 0xe8, 0xaa, 0xe0, 0x9f, 0x35, 0x58, 0x77, 0xa0, 0x33, 0x3b, 0x53, 0x15, 0xb, 0x81, 0xd3, 0x6c, 0x5c, 0x24, 0x46, 0xbf, 0x5a, 0xc4, 0x62, 0xef, 0x84, 0xd4, 0xe5, 0x72}, - output512: []byte{0x4e, 0x4d, 0xc4, 0x9e, 0x41, 0x4c, 0x79, 0x4a, 0x4b, 0x6d, 0x8d, 0x20, 0x93, 0xfe, 0xab, 0x46, 0xd9, 0x13, 0x21, 0xcf, 0xd0, 0x89, 0xb1, 0xfd, 0x8c, 0xb5, 0x15, 0x4f, 0x3e, 0x34, 0x26, 0x45, 0xf6, 0x23, 0x3a, 0x92, 0x16, 0xdb, 0x4, 0xf0, 0x80, 0xe5, 0xaf, 0x8b, 0x15, 0x6e, 0x78, 0x2a, 0xd1, 0x6e, 0xb, 0x15, 0xd8, 0x14, 0x17, 0x3e, 0x78, 0xfc, 0xf5, 0xe7, 0xcf, 0x8e, 0xa5, 0x1f}, - }, - { - msg: []byte{0xda, 0xb1, 0x1d, 0xc0, 0xb0, 0x47, 0xdb, 0x4, 0x20, 0xa5, 0x85, 0xf5, 0x6c, 0x42, 0xd9, 0x31, 0x75, 0x56, 0x28, 0x52, 0x42, 0x84, 0x99, 0xf6, 0x6a, 0xd, 0xb8, 0x11, 0xfc, 0xdd, 0xda, 0xb2, 0xf7, 0xcd, 0xff, 0xed, 0x15, 0x43, 0xe5, 0xfb, 0x72, 0x11, 0xb, 0x64, 0x68, 0x6b, 0xc7, 0xb6, 0x88, 0x7a, 0x53, 0x8a, 0xd4, 0x4c, 0x5, 0xf, 0x1e, 0x42, 0x63, 0x1b, 0xc4, 0xec, 0x8a, 0x9f, 0x2a, 0x4, 0x71, 0x63, 0xd8, 0x22, 0xa3, 0x89, 0x89, 0xee, 0x4a, 0xab, 0x1, 0xb4, 0xc1, 0xf1, 0x61, 0xb0, 0x62, 0xd8, 0x73, 0xb1, 0xcf, 0xa3, 0x88, 0xfd, 0x30, 0x15, 0x14, 0xf6, 0x22, 0x24, 0x15, 0x7b, 0x9b, 0xef, 0x42, 0x3c, 0x77, 0x83, 0xb7, 0xaa, 0xc8, 0xd3, 0xd, 0x65, 0xcd, 0x1b, 0xba, 0x8d, 0x68, 0x9c, 0x2d}, - output224: []byte{0xab, 0xb2, 0xfc, 0xe2, 0x13, 0xce, 0x16, 0x4c, 0x94, 0xab, 0x7a, 0x76, 0x3c, 0x21, 0xf6, 0x38, 0xa3, 0xbb, 0x8d, 0x72, 0xf8, 0x2, 0xde, 0xad, 0xac, 0xc0, 0x23, 0xae}, - output256: []byte{0x3d, 0x2, 0xb4, 0x19, 0x85, 0xbd, 0xd1, 0x83, 0x5c, 0xb4, 0x74, 0xfb, 0x36, 0x4c, 0x25, 0xc2, 0xcc, 0xa9, 0xda, 0xe, 0xd2, 0xfb, 0xba, 0xb7, 0x55, 0x24, 0xb4, 0x10, 0x90, 0x38, 0x15, 0xb9}, - output384: []byte{0xdb, 0x14, 0x44, 0x24, 0x0, 0x59, 0x78, 0x71, 0xfa, 0x56, 0xd1, 0xf, 0x53, 0xbe, 0x7b, 0xb4, 0x0, 0x2c, 0x44, 0x62, 0x4c, 0x44, 0xe8, 0x9c, 0x99, 0xb9, 0x51, 0x22, 0x67, 0x6a, 0x76, 0xff, 0x28, 0x84, 0x2, 0x85, 0x23, 0x9e, 0x2e, 0x4f, 0xbf, 0xb7, 0x51, 0xe4, 0x17, 0x95, 0x77, 0xd8}, - output512: []byte{0x2c, 0x8f, 0x45, 0x6f, 0x90, 0x91, 0x51, 0x7c, 0xaf, 0xa9, 0xdf, 0x1d, 0x9, 0xee, 0x62, 0x1e, 0xdf, 0xeb, 0x2c, 0x0, 0xda, 0xb9, 0x44, 0x35, 0x5d, 0x59, 0x2d, 0xfd, 0xa1, 0x28, 0xf8, 0x37, 0x22, 0x85, 0x78, 0xe3, 0x96, 0x5d, 0x37, 0x67, 0x95, 0x9d, 0x3c, 0xdd, 0xe4, 0xe7, 0xb6, 0x7e, 0x2, 0x24, 0x1f, 0x28, 0xc5, 0x41, 0x7e, 0x33, 0xea, 0x74, 0xe3, 0x90, 0x32, 0xf9, 0x38, 0xea}, - }, - { - msg: []byte{0x42, 0xe9, 0x9a, 0x2f, 0x80, 0xae, 0xe0, 0xe0, 0x1, 0x27, 0x9a, 0x24, 0x34, 0xf7, 0x31, 0xe0, 0x1d, 0x34, 0xa4, 0x4b, 0x1a, 0x81, 0x1, 0x72, 0x69, 0x21, 0xc0, 0x59, 0xc, 0x30, 0xf3, 0x12, 0xe, 0xb8, 0x30, 0x59, 0xf3, 0x25, 0xe8, 0x94, 0xa5, 0xac, 0x95, 0x9d, 0xca, 0x71, 0xce, 0x22, 0x14, 0x79, 0x99, 0x16, 0x42, 0x4e, 0x85, 0x9d, 0x27, 0xd7, 0x89, 0x43, 0x7b, 0x9d, 0x27, 0x24, 0xb, 0xf8, 0xc3, 0x5a, 0xdb, 0xaf, 0xce, 0xcc, 0x32, 0x2b, 0x48, 0xaa, 0x20, 0x5b, 0x29, 0x39, 0x62, 0xd8, 0x58, 0x65, 0x2a, 0xba, 0xcb, 0xd5, 0x88, 0xbc, 0xf6, 0xcb, 0xc3, 0x88, 0xd0, 0x99, 0x3b, 0xd6, 0x22, 0xf9, 0x6e, 0xd5, 0x46, 0x14, 0xc2, 0x5b, 0x6a, 0x9a, 0xa5, 0x27, 0x58, 0x9e, 0xaa, 0xff, 0xcf, 0x17, 0xdd, 0xf7}, - output224: []byte{0xc4, 0xd, 0x96, 0x9f, 0x72, 0x18, 0xd7, 0x1b, 0x90, 0x4c, 0x4e, 0x4e, 0xac, 0xeb, 0x4, 0x73, 0xba, 0xa, 0x2e, 0x73, 0x39, 0x64, 0x9d, 0xa5, 0xdf, 0xeb, 0x89, 0x38}, - output256: []byte{0x1c, 0xd9, 0x20, 0x39, 0xbe, 0x45, 0x80, 0xc6, 0x86, 0x79, 0x6d, 0x59, 0x0, 0xee, 0xd4, 0x31, 0xeb, 0xad, 0x6e, 0xa5, 0x66, 0xe9, 0x24, 0x4e, 0x76, 0xba, 0x68, 0x73, 0xef, 0xcb, 0x49, 0xab}, - output384: []byte{0x45, 0x9, 0xad, 0xb6, 0x17, 0x7b, 0xc6, 0xde, 0xbc, 0xa7, 0xe3, 0x69, 0x48, 0xf0, 0x70, 0x1, 0x15, 0x9a, 0x57, 0xec, 0x8c, 0xca, 0x2b, 0x76, 0xc7, 0x70, 0x73, 0x5c,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0x46, 0x17, 0x6e, 0xbf, 0x4, 0x4c, 0x47, 0x84, 0x46, 0x7c, 0x70, 0x4, 0x70, 0xd0, 0xc0, 0xb4, 0xc, 0x8a, 0x8, 0x8c, 0x81, 0x58, 0x16}, - output224: []byte{0x2e, 0xb2, 0x8f, 0xdf, 0x45, 0x8d, 0x4f, 0xec, 0xb5, 0xb4, 0x41, 0xd9, 0x10, 0xb5, 0x76, 0xf6, 0x30, 0xe6, 0x66, 0xbb, 0xf3, 0xa, 0xac, 0x90, 0xab, 0x64, 0x42, 0x5b}, - output256: []byte{0x68, 0xc, 0x70, 0xb2, 0x43, 0x16, 0x3b, 0xe6, 0xe5, 0x8e, 0xd3, 0xb8, 0xe2, 0xd8, 0x5e, 0x68, 0x94, 0xe5, 0xe8, 0x95, 0x1, 0xc4, 0x44, 0xc8, 0xc0, 0xa2, 0xd7, 0x76, 0xac, 0xad, 0x85, 0x99}, - output384: []byte{0x19, 0x3a, 0xf7, 0x1b, 0xdd, 0x22, 0x8a, 0xb3, 0xe8, 0xae, 0x50, 0xe1, 0xb1, 0xcb, 0xf1, 0x98, 0x4b, 0xa, 0xf9, 0x2a, 0xac, 0x5a, 0x71, 0xcb, 0xe6, 0x18, 0xaf, 0xd4, 0x18, 0x7d, 0xed, 0x6b, 0x46, 0x14, 0x11, 0xa3, 0x9e, 0x72, 0xea, 0x4e, 0x21, 0x3f, 0xe0, 0xa5, 0x23, 0x1c, 0x49, 0x8d}, - output512: []byte{0x6f, 0x3e, 0x12, 0x94, 0xb6, 0x7d, 0x87, 0x51, 0x65, 0xfd, 0x9, 0xdd, 0x49, 0x3d, 0xd5, 0x59, 0x24, 0xe9, 0xe2, 0x8e, 0x53, 0xaf, 0xa2, 0xda, 0x80, 0x91, 0x6d, 0x7d, 0x54, 0xe1, 0x9c, 0x17, 0x5, 0x12, 0x1d, 0x61, 0x7e, 0x53, 0xf5, 0x6e, 0xba, 0x47, 0x67, 0xd6, 0x43, 0x5e, 0x98, 0x6f, 0xee, 0xae, 0xb9, 0x65, 0xec, 0x49, 0x56, 0xfd, 0x3c, 0x2, 0xde, 0x12, 0x88, 0xfb, 0xc6, 0x61}, - }, - { - msg: []byte{0xd1, 0xe6, 0x54, 0xb7, 0x7c, 0xb1, 0x55, 0xf5, 0xc7, 0x79, 0x71, 0xa6, 0x4d, 0xf9, 0xe5, 0xd3, 0x4c, 0x26, 0xa3, 0xca, 0xd6, 0xc7, 0xf6, 0xb3, 0x0, 0xd3, 0x9d, 0xeb, 0x19, 0x10, 0x9, 0x46, 0x91, 0xad, 0xaa, 0x9, 0x5b, 0xe4, 0xba, 0x5d, 0x86, 0x69, 0xa, 0x97, 0x64, 0x28, 0x63, 0x5d, 0x55, 0x26, 0xf3, 0xe9, 0x46, 0xf7, 0xdc, 0x3b, 0xd4, 0xdb, 0xc7, 0x89, 0x99, 0xe6, 0x53, 0x44, 0x11, 0x87, 0xa8, 0x1f, 0x9a, 0xdc, 0xd5, 0xa3, 0xc5, 0xf2, 0x54, 0xbc, 0x82, 0x56, 0xb0, 0x15, 0x8f, 0x54, 0x67, 0x3d, 0xcc, 0x12, 0x32, 0xf6, 0xe9, 0x18, 0xeb, 0xfc, 0x6c, 0x51, 0xce, 0x67, 0xea, 0xeb, 0x4, 0x2d, 0x9f, 0x57, 0xee, 0xc4, 0xbf, 0xe9, 0x10, 0xe1, 0x69, 0xaf, 0x78, 0xb3, 0xde, 0x48, 0xd1, 0x37, 0xdf, 0x4f, 0x28, 0x40}, - output224: []byte{0xa3, 0x38, 0x7b, 0x2f, 0xa2, 0x3a, 0x13, 0xbf, 0xae, 0x77, 0x89, 0x5f, 0x1f, 0x93, 0x93, 0x5a, 0x7, 0x10, 0xee, 0x3a, 0x2, 0x7f, 0xf0, 0xd6, 0x39, 0x9d, 0x8e, 0xcc}, - output256: []byte{0xd6, 0x5e, 0x82, 0x3d, 0x2c, 0xe4, 0xef, 0xfb, 0x9b, 0x27, 0xdb, 0xbf, 0x6e, 0xfc, 0xda, 0x73, 0x8a, 0xd1, 0x52, 0xfb, 0xb1, 0x2d, 0x21, 0x8, 0xd2, 0xec, 0x6d, 0x5, 0xa, 0x3f, 0xb2, 0x95}, - output384: []byte{0x3e, 0x41, 0x95, 0x69, 0xa4, 0x19, 0x7b, 0xb7, 0x1b, 0xaf, 0x41, 0x6b, 0x38, 0x77, 0x2e, 0xed, 0xd9, 0xc1, 0xd5, 0xa3, 0x25, 0x21, 0x11, 0x60, 0x9f, 0xf, 0xf8, 0xa1, 0x8a, 0x74, 0x9d, 0x5a, 0x56, 0x14, 0x3a, 0x14, 0x92, 0x5a, 0x82, 0xcd, 0x35, 0xc4, 0x44, 0x0, 0xa4, 0x9a, 0xfd, 0xfb}, - output512: []byte{0xaa, 0x33, 0x98, 0xbc, 0x7d, 0xae, 0xb4, 0xf2, 0x2c, 0xa6, 0xd1, 0x93, 0x7b, 0xc, 0x60, 0x97, 0xa4, 0x9a, 0xdb, 0x6d, 0xbc, 0x3, 0xfc, 0xf, 0x52, 0x26, 0xa6, 0x44, 0xf2, 0x17, 0x29, 0x6b, 0xf5, 0x57, 0x47, 0x26, 0x9b, 0x86, 0x1f, 0xc7, 0xb2, 0x2b, 0xc5, 0x95, 0x6c, 0xe3, 0xd8, 0xda, 0x28, 0xe9, 0xf2, 0x5d, 0x8c, 0x95, 0x99, 0xbc, 0x65, 0x3c, 0xd0, 0xee, 0xc, 0x85, 0x24, 0x73}, - }, - { - msg: []byte{0x62, 0x6f, 0x68, 0xc1, 0x8a, 0x69, 0xa6, 0x59, 0x1, 0x59, 0xa9, 0xc4, 0x6b, 0xe0, 0x3d, 0x59, 0x65, 0x69, 0x8f, 0x2d, 0xac, 0x3d, 0xe7, 0x79, 0xb8, 0x78, 0xb3, 0xd9, 0xc4, 0x21, 0xe0, 0xf2, 0x1b, 0x95, 0x5a, 0x16, 0xc7, 0x15, 0xc1, 0xec, 0x1e, 0x22, 0xce, 0x3e, 0xb6, 0x45, 0xb8, 0xb4, 0xf2, 0x63, 0xf6, 0x6, 0x60, 0xea, 0x30, 0x28, 0x98, 0x1e, 0xeb, 0xd6, 0xc8, 0xc3, 0xa3, 0x67, 0x28, 0x5b, 0x69, 0x1c, 0x8e, 0xe5, 0x69, 0x44, 0xa7, 0xcd, 0x12, 0x17, 0x99, 0x7e, 0x1d, 0x9c, 0x21, 0x62, 0xb, 0x53, 0x6b, 0xdb, 0xd5, 0xde, 0x89, 0x25, 0xff, 0x71, 0xde, 0xc6, 0xfb, 0xc0, 0x66, 0x24, 0xab, 0x6b, 0x21, 0xe3, 0x29, 0x81, 0x3d, 0xe9, 0xd, 0x1e, 0x57, 0x2d, 0xfb, 0x89, 0xa1, 0x81, 0x20, 0xc3, 0xf6, 0x6, 0x35, 0x5d, 0x25}, - output224: []byte{0x75, 0x75, 0x5f, 0x46, 0xc2, 0xfc, 0x86, 0xbd, 0x4a, 0xae, 0x75, 0x91, 0x9c, 0x6c, 0xa5, 0xb1, 0xa7, 0x37, 0x5e, 0x46, 0x6c, 0xa3, 0x17, 0xf, 0x70, 0xee, 0xe4, 0x90}, - output256: []byte{0xce, 0x6d, 0x2d, 0xd8, 0xd5, 0x44, 0x1f, 0xc1, 0x5b, 0x88, 0x8f, 0xed, 0x72, 0x6, 0x1e, 0x12, 0x91, 0x25, 0x43, 0x1b, 0xed, 0xea, 0x32, 0xe0, 0xe, 0xe0, 0xa7, 0x65, 0x5c, 0x6, 0xc3, 0x58}, - output384: []byte{0x62, 0x15, 0xc0, 0x70, 0xd0, 0xcb, 0x38, 0x8a, 0x13, 0x47, 0x66, 0x3, 0x5c, 0x4b, 0xa9, 0x51, 0x43, 0xe6, 0x8, 0xd1, 0x5c, 0xaf, 0x74, 0x27, 0x96, 0x30, 0x4f, 0xfa, 0x1a, 0x62, 0xe5, 0x56, 0x60, 0xab, 0x9a, 0xb1, 0xf6, 0x53, 0x8b, 0x4a, 0xf1, 0xf3, 0xea, 0x89, 0xbe, 0x7d, 0x51, 0xff}, - output512: []byte{0x8b, 0xcb, 0xbe, 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output224: []byte{0x71, 0x84, 0xc6, 0x9e, 0xe1, 0xc4, 0x3f, 0xd5, 0x64, 0x10, 0x2c, 0xd6, 0x8e, 0xf8, 0x98, 0xd5, 0xd0, 0xd8, 0x26, 0x4b, 0x9b, 0xd, 0x4, 0x46, 0x91, 0xbc, 0x18, 0xaf}, - output256: []byte{0x28, 0x7, 0x13, 0xc0, 0xfa, 0x71, 0x60, 0x28, 0x9f, 0xbf, 0xee, 0x5a, 0xa5, 0x80, 0xad, 0x82, 0x51, 0x28, 0x39, 0x15, 0x3d, 0xae, 0x47, 0xde, 0xd, 0x15, 0x43, 0x84, 0xa4, 0xd8, 0xb3, 0xed}, - output384: []byte{0xe, 0x27, 0xab, 0xad, 0x85, 0x25, 0x5a, 0x66, 0x21, 0x77, 0x22, 0xb7, 0xd4, 0xe0, 0x32, 0xbf, 0x29, 0xf6, 0x38, 0xba, 0xe9, 0x65, 0xb9, 0x9f, 0x8e, 0xaf, 0x30, 0x90, 0x71, 0xff, 0x8c, 0x10, 0x7f, 0x5b, 0x6b, 0xbb, 0x6a, 0xb1, 0x98, 0x52, 0x28, 0xe6, 0x97, 0xde, 0x60, 0x59, 0x5d, 0xf6}, - output512: []byte{0x47, 0x82, 0xdf, 0xca, 0xb6, 0x50, 0xe7, 0xa8, 0xda, 0xe9, 0xa0, 0x10, 0xcb, 0x0, 0x2d, 0xd0, 0x37, 0x3b, 0xfb, 0xd3, 0x12, 0x47, 0xfa, 0x98, 0x60, 0x87, 0x6d, 0x7f, 0xff, 0xd2, 0xd5, 0x7c, 0x35, 0x5f, 0x20, 0x54, 0xcb, 0x2e, 0xfe, 0xb4, 0x5c, 0x58, 0x71, 0xf2, 0x84, 0xf4, 0x6b, 0x2, 0x57, 0x98, 0x34, 0x4a, 0x37, 0x19, 0xef, 0xab, 0x34, 0xd1, 0x51, 0x52, 0xdd, 0xb, 0xbc, 0x6c}, - }, - { - msg: []byte{0x8a, 0xaf, 0x7, 0x2f, 0xce, 0x8a, 0x2d, 0x96, 0xbc, 0x10, 0xb3, 0xc9, 0x1c, 0x80, 0x9e, 0xe9, 0x30, 0x72, 0xfb, 0x20, 0x5c, 0xa7, 0xf1, 0xa, 0xbd, 0x82, 0xec, 0xd8, 0x2c, 0xf0, 0x40, 0xb1, 0xbc, 0x49, 0xea, 0x13, 0xd1, 0x85, 0x78, 0x15, 0xc0, 0xe9, 0x97, 0x81, 0xde, 0x3a, 0xdb, 0xb5, 0x44, 0x3c, 0xe1, 0xc8, 0x97, 0xe5, 0x51, 0x88, 0xce, 0xaf, 0x22, 0x1a, 0xa9, 0x68, 0x16, 0x38, 0xde, 0x5, 0xae, 0x1b, 0x32, 0x29, 0x38, 0xf4, 0x6b, 0xce, 0x51, 0x54, 0x3b, 0x57, 0xec, 0xdb, 0x4c, 0x26, 0x62, 0x72, 0x25, 0x9d, 0x17, 0x98, 0xde, 0x13, 0xbe, 0x90, 0xe1, 0xe, 0xfe, 0xc2, 0xd0, 0x74, 0x84, 0xd9, 0xb2, 0x1a, 0x38, 0x70, 0xe2, 0xaa, 0x9e, 0x6, 0xc2, 0x1a, 0xa2, 0xd0, 0xc9, 0xcf, 0x42, 0x0, 0x80, 0xa8, 0xa, 0x91, 0xde, 0xe1, 0x6f}, - output224: []byte{0xf5, 0xc, 0xf7, 0x8f, 0xf4, 0x65, 0x13, 0xc9, 0x5, 0x39, 0x9c, 0xc2, 0x51, 0x6, 0x81, 0xa9, 0xc, 0xe0, 0x89, 0xfc, 0xed, 0x40, 0xfb, 0xc9, 0xcf, 0x21, 0x8c, 0xa4}, - output256: []byte{0x72, 0x1f, 0xd8, 0x72, 0x69, 0x6f, 0x21, 0xde, 0xaa, 0x95, 0x95, 0xc0, 0xce, 0xe7, 0xbc, 0x7, 0x24, 0x96, 0x1, 0x92, 0x7c, 0x96, 0xa6, 0x58, 0x26, 0xb4, 0x88, 0x7c, 0xdb, 0xa1, 0xae, 0x96}, - output384: []byte{0xab, 0x9f, 0xd5, 0x1b, 0x3a, 0xa4, 0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 0xe1, 0x1c, 0xd5, 0xe0, 0x95, 0xb7, 0x3d, 0xf5, 0xf8, 0x2c, 0x8a, 0xe3, 0xad, 0x0, 0x87, 0x79, 0x36, 0x89, 0x66, 0x71, 0xe9, 0x47, 0xcc, 0x52, 0xe2, 0xb2, 0x9d, 0xcd, 0x46, 0x3d, 0x90, 0xa0, 0xc9, 0x92, 0x91, 0x28, 0xda, 0x22, 0x2b, 0x5a, 0x21, 0x14, 0x50, 0xbb, 0xc0, 0xe0, 0x24, 0x48, 0xe2}, - output224: []byte{0xf2, 0xaa, 0xbe, 0x18, 0xd7, 0xb4, 0xdd, 0x8e, 0x4d, 0xc0, 0xac, 0x8d, 0xcf, 0x4e, 0x90, 0x19, 0xc7, 0xc9, 0xaf, 0x33, 0xd4, 0xb9, 0x52, 0xda, 0x41, 0x21, 0x9f, 0xe5}, - output256: []byte{0xb5, 0x3a, 0xf8, 0x62, 0xb, 0x39, 0xca, 0xd2, 0xd6, 0x98, 0xa1, 0x76, 0xa0, 0x70, 0xae, 0xaa, 0x9f, 0xb6, 0x7b, 0xd0, 0x33, 0x5c, 0x34, 0x85, 0xa3, 0xb6, 0xc7, 0x3a, 0x71, 0xdc, 0x5c, 0x5c}, - output384: []byte{0x3, 0x94, 0x53, 0x25, 0xac, 0x50, 0xe5, 0x6b, 0xc8, 0xb5, 0x15, 0x57, 0x65, 0x29, 0xab, 0xaa, 0x9a, 0x22, 0xbc, 0x2a, 0x7c, 0xed, 0x91, 0x42, 0xa7, 0x5c, 0xe9, 0x39, 0xa3, 0x88, 0xaf, 0x0, 0x22, 0xa4, 0xe7, 0x5a, 0x33, 0x96, 0x4b, 0xbb, 0x35, 0x80, 0x56, 0x4e, 0xa, 0xf8, 0x9, 0xd3}, - output512: []byte{0x87, 0x32, 0xd2, 0x43, 0xf1, 0xb3, 0x34, 0x9f, 0x90, 0xd, 0xf4, 0x30, 0x65, 0x9b, 0x9a, 0xb9, 0xed, 0x99, 0xf6, 0x26, 0xad, 0x35, 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e4, 0xd3, 0xd0, 0x78, 0x51, 0xeb, 0x2e, 0x58, 0xb1, 0x2b, 0xe0, 0xbe, 0xed, 0x95}, - output256: []byte{0x78, 0xa1, 0x8b, 0xf0, 0xa5, 0x2e, 0x6f, 0x77, 0xf1, 0x5f, 0x7f, 0xfe, 0x4c, 0xa3, 0xc9, 0x99, 0xe5, 0x7e, 0x1c, 0x3f, 0x6b, 0xf1, 0x9, 0x50, 0x58, 0x1f, 0x40, 0x34, 0x50, 0xed, 0xb7, 0x97}, - output384: []byte{0x59, 0x12, 0x69, 0x10, 0xa3, 0x46, 0x2e, 0x3b, 0x7a, 0xc2, 0x28, 0x92, 0xf6, 0x37, 0xd8, 0x7d, 0x90, 0x68, 0x6b, 0xc0, 0xa9, 0xbb, 0xd4, 0xa3, 0x2e, 0x2c, 0x4c, 0x71, 0xa1, 0x68, 0xba, 0x68, 0x5f, 0x21, 0x84, 0x56, 0xe, 0x12, 0x5d, 0xb3, 0xdc, 0x23, 0xd9, 0xb, 0x9e, 0x82, 0xf, 0x1a}, - output512: []byte{0x97, 0xdc, 0x26, 0x6, 0xe1, 0x4f, 0x7b, 0xff, 0xf1, 0xfc, 0xa4, 0x97, 0x96, 0x5e, 0x36, 0xca, 0xa3, 0xa8, 0x1c, 0xfd, 0x64, 0x59, 0xd0, 0x25, 0x45, 0x29, 0xf6, 0x4d, 0xa4, 0xf, 0xfe, 0x74, 0x42, 0xc0, 0x8a, 0x15, 0x1d, 0x6c, 0xee, 0x3b, 0x46, 0xbf, 0x34, 0x14, 0xe8, 0x1, 0x10, 0xa0, 0xf7, 0x1e, 0xee, 0x44, 0xd7, 0x94, 0x0, 0x27, 0xde, 0xe9, 0xe, 0x91, 0x9e, 0x49, 0x8d, 0x65}, - }, - { - msg: []byte{0xe, 0x3a, 0xb0, 0xe0, 0x54, 0x73, 0x9b, 0x0, 0xcd, 0xb6, 0xa8, 0x7b, 0xd1, 0x2c, 0xae, 0x2, 0x4b, 0x54, 0xcb, 0x5e, 0x55, 0xe, 0x6c, 0x42, 0x53, 0x60, 0xc2, 0xe8, 0x7e, 0x59, 0x40, 0x1f, 0x5e, 0xc2, 0x4e, 0xf0, 0x31, 0x48, 0x55, 0xf0, 0xf5, 0x6c, 0x47, 0x69, 0x5d, 0x56, 0xa7, 0xfb, 0x14, 0x17, 0x69, 0x3a, 0xf2, 0xa1, 0xed, 0x52, 0x91, 0xf2, 0xfe, 0xe9, 0x5f, 0x75, 0xee, 0xd5, 0x4a, 0x1b, 0x1c, 0x2e, 0x81, 0x22, 0x6f, 0xbf, 0xf6, 0xf6, 0x3a, 0xde, 0x58, 0x49, 0x11, 0xc7, 0x19, 0x67, 0xa8, 0xeb, 0x70, 0x93, 0x3b, 0xc3, 0xf5, 0xd1, 0x5b, 0xc9, 0x1b, 0x5c, 0x26, 0x44, 0xd9, 0x51, 0x6d, 0x3c, 0x3a, 0x8c, 0x15, 0x4e, 0xe4, 0x8e, 0x11, 0x8b, 0xd1, 0x44, 0x2c, 0x4, 0x3c, 0x7a, 0xd, 0xba, 0x5a, 0xc5, 0xb1, 0xd5, 0x36, 0xa, 0xae, 0x5b, 0x90, 0x65}, - output224: []byte{0xcb, 0x79, 0x79, 0xb4, 0xc6, 0xc2, 0x82, 0x6c, 0xde, 0xf7, 0xe1, 0xaa, 0xda, 0x85, 0xf8, 0xc4, 0x54, 0x6d, 0xd5, 0x9d, 0x29, 0xfc, 0xa, 0xea, 0x44, 0x4f, 0x80, 0x77}, - output256: []byte{0xa7, 0xf0, 0x15, 0x1e, 0xee, 0x6b, 0x21, 0xfe, 0x82, 0x7e, 0x69, 0x25, 0x6d, 0x56, 0xe, 0x1e, 0xa8, 0xd9, 0x39, 0xb8, 0x9, 0x62, 0xfc, 0x7f, 0xa8, 0x61, 0xa, 0xc1, 0x89, 0x40, 0x2a, 0xd2}, - output384: []byte{0xd3, 0x23, 0x9a, 0x33, 0xba, 0xa5, 0x5b, 0xf, 0x21, 0x16, 0x9e, 0xf, 0xde, 0x61, 0x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c, 0x37, 0x11, 0xb7, 0x69, 0xe3, 0xfd, 0xe4, 0x4a, 0x74, 0x1, 0x6f, 0xff, 0x82, 0xac, 0x46, 0xfa, 0x8f, 0x17, 0x97, 0xd3, 0xb2, 0xa7, 0x26, 0xb6, 0x96, 0xe3, 0xde, 0xa5, 0x53, 0x4, 0x39, 0xac, 0xee, 0x3a, 0x45, 0xc2, 0xa5, 0x1b, 0xc3, 0x2d, 0xd0, 0x55, 0x65, 0xb}, - output224: []byte{0xf9, 0xd8, 0xcc, 0xf6, 0x68, 0x46, 0x93, 0xc4, 0xc, 0x81, 0xeb, 0xbd, 0x0, 0x6c, 0x49, 0x98, 0x4f, 0xba, 0xf3, 0xa2, 0xb2, 0xe9, 0x5, 0xab, 0xe6, 0x7, 0x65, 0xdd}, - output256: []byte{0xa, 0x9, 0xc4, 0xb1, 0x8f, 0x51, 0x17, 0xf0, 0xe4, 0x5d, 0x43, 0xe2, 0x35, 0xbb, 0x14, 0xe5, 0x5b, 0x16, 0x2e, 0x99, 0xeb, 0x37, 0x44, 0x16, 0x51, 0x96, 0xd0, 0x4a, 0x85, 0x42, 0x29, 0xf9}, - output384: []byte{0x38, 0xa1, 0x15, 0x81, 0xd8, 0x74, 0xa5, 0x74, 0x92, 0x9c, 0x51, 0xf8, 0xdc, 0xc9, 0xe5, 0x1, 0x90, 0x7, 0x43, 0x86, 0x4a, 0xec, 0x3a, 0xc0, 0x88, 0x9e, 0x62, 0xc1, 0x7, 0x1c, 0xa5, 0xf8, 0xb6, 0xcc, 0xf9, 0xc0, 0xbd, 0xb3, 0xbb, 0x36, 0x59, 0x16, 0xeb, 0x43, 0x40, 0x97, 0x3d, 0xc7}, - output512: []byte{0x33, 0xab, 0xca, 0x29, 0xa8, 0xa7, 0x9, 0x4c, 0xfb, 0x10, 0xbe, 0x4a, 0x80, 0xe8, 0x1f, 0x80, 0x1, 0xeb, 0xb9, 0x33, 0xc0, 0xd4, 0xb9, 0x8a, 0x69, 0x5b, 0x22, 0xab, 0x55, 0x3f, 0x94, 0xf0, 0x76, 0x46, 0xab, 0xce, 0x6a, 0xdf, 0x49, 0x18, 0x17, 0xd1, 0x7b, 0x78, 0xc4, 0x7, 0x47, 0xd5, 0x6f, 0xaf, 0x88, 0xa6, 0x13, 0x13, 0x8c, 0xa0, 0xe5, 0x96, 0x63, 0x6c, 0x67, 0x23, 0x97, 0xb4}, - }, - { - msg: []byte{0x2b, 0x6d, 0xb7, 0xce, 0xd8, 0x66, 0x5e, 0xbe, 0x9d, 0xeb, 0x8, 0x2, 0x95, 0x21, 0x84, 0x26, 0xbd, 0xaa, 0x7c, 0x6d, 0xa9, 0xad, 0xd2, 0x8, 0x89, 0x32, 0xcd, 0xff, 0xba, 0xa1, 0xc1, 0x41, 0x29, 0xbc, 0xcd, 0xd7, 0xf, 0x36, 0x9e, 0xfb, 0x14, 0x92, 0x85, 0x85, 0x8d, 0x2b, 0x1d, 0x15, 0x5d, 0x14, 0xde, 0x2f, 0xdb, 0x68, 0xa, 0x8b, 0x2, 0x72, 0x84, 0x5, 0x51, 0x82, 0xa0, 0xca, 0xe2, 0x75, 0x23, 0x4c, 0xc9, 0xc9, 0x28, 0x63, 0xc1, 0xb4, 0xab, 0x66, 0xf3, 0x4, 0xcf, 0x6, 0x21, 0xcd, 0x54, 0x56, 0x5f, 0x5b, 0xff, 0x46, 0x1d, 0x3b, 0x46, 0x1b, 0xd4, 0xd, 0xf2, 0x81, 0x98, 0xe3, 0x73, 0x25, 0x1, 0xb4, 0x86, 0xe, 0xad, 0xd5, 0x3, 0xd2, 0x6d, 0x6e, 0x69, 0x33, 0x8f, 0x4e, 0x4, 0x56, 0xe9, 0xe9, 0xba, 0xf3, 0xd8, 0x27, 0xae, 0x68, 0x5f, 0xb1, 0xd8, 0x17}, - output224: []byte{0xed, 0x1f, 0x63, 0x87, 0xa7, 0xbe, 0x9, 0x2, 0x77, 0xb6, 0x5a, 0x5f, 0xcd, 0x70, 0x40, 0xc7, 0xbe, 0xe, 0xea, 0xf0, 0xfd, 0x7f, 0x14, 0x96, 0x80, 0x97, 0x87, 0x3b}, - output256: []byte{0xb7, 0xd0, 0x31, 0xaa, 0x69, 0xb7, 0xb4, 0xd2, 0x6a, 0x35, 0xb8, 0x96, 0xd7, 0x61, 0x31, 0x4f, 0x1d, 0x61, 0xeb, 0x12, 0xdc, 0xc1, 0xe7, 0x2a, 0xaf, 0x61, 0xb9, 0xcd, 0x48, 0x0, 0x3a, 0xf9}, - output384: []byte{0x8f, 0xd0, 0x19, 0x9, 0x38, 0x1e, 0xb7, 0x13, 0x80, 0x34, 0x19, 0x36, 0x1d, 0x8e, 0x82, 0xe9, 0x24, 0x76, 0xa0, 0x8e, 0xdc, 0xc2, 0x25, 0xbb, 0x8a, 0x13, 0x5d, 0x21, 0x5c, 0xb4, 0x8d, 0x7, 0xb0, 0x74, 0x62, 0x4f, 0xcf, 0x2e, 0x73, 0xe6, 0x66, 0xdb, 0xa5, 0x93, 0x34, 0x71, 0x98, 0x39}, - output512: []byte{0x4f, 0xab, 0x45, 0x80, 0x6b, 0x46, 0x28, 0x6, 0x84, 0x58, 0xb5, 0xd0, 0xa2, 0xd4, 0xbf, 0x10, 0x1b, 0x8b, 0xfc, 0x92, 0x76, 0xef, 0x86, 0xad, 0x5d, 0x88, 0x37, 0x65, 0xc4, 0x3f, 0x72, 0xce, 0x8a, 0x5f, 0x7b, 0x4c, 0x5b, 0x53, 0x5a, 0x91, 0x51, 0x30, 0xbb, 0x18, 0x5e, 0x69, 0x9a, 0xb6, 0x22, 0x28, 0x1, 0x4e, 0x54, 0xdf, 0x79, 0xc, 0xe, 0x93, 0xaa, 0xdb, 0xe7, 0xe3, 0x9e, 0x19}, - }, - { - msg: []byte{0x10, 0xdb, 0x50, 0x9b, 0x2c, 0xdc, 0xab, 0xa6, 0xc0, 0x62, 0xae, 0x33, 0xbe, 0x48, 0x11, 0x6a, 0x29, 0xeb, 0x18, 0xe3, 0x90, 0xe1, 0xbb, 0xad, 0xa5, 0xca, 0xa, 0x27, 0x18, 0xaf, 0xbc, 0xd2, 0x34, 0x31, 0x44, 0x1, 0x6, 0x59, 0x48, 0x93, 0x4, 0x3c, 0xc7, 0xf2, 0x62, 0x52, 0x81, 0xbf, 0x7d, 0xe2, 0x65, 0x58, 0x80, 0x96, 0x6a, 0x23, 0x70, 0x5f, 0xc, 0x51, 0x55, 0xc2, 0xf5, 0xcc, 0xa9, 0xf2, 0xc2, 0x14, 0x2e, 0x96, 0xd0, 0xa2, 0xe7, 0x63, 0xb7, 0x6, 0x86, 0xcd, 0x42, 0x1b, 0x5d, 0xb8, 0x12, 0xda, 0xce, 0xd0, 0xc6, 0xd6, 0x50, 0x35, 0xfd, 0xe5, 0x58, 0xe9, 0x4f, 0x26, 0xb3, 0xe6, 0xdd, 0xe5, 0xbd, 0x13, 0x98, 0xc, 0xc8, 0x2, 0x92, 0xb7, 0x23, 0x1, 0x3b, 0xd0, 0x33, 0x28, 0x45, 0x84, 0xbf, 0xf2, 0x76, 0x57, 0x87, 0x1b, 0xc, 0xf0, 0x7a, 0x84, 0x9f, 0x4a, 0xe2}, - output224: []byte{0xa, 0x27, 0xce, 0x69, 0x73, 0xcb, 0x22, 0xa8, 0xb1, 0x0, 0x57, 0xa8, 0xe7, 0xa6, 0x54, 0x5, 0x8b, 0x71, 0xe6, 0xd8, 0xc6, 0x9c, 0x65, 0x34, 0x15, 0xff, 0xc, 0x81}, - output256: []byte{0xec, 0x8, 0x58, 0xc9, 0xd0, 0x17, 0xa2, 0xd3, 0x72, 0x7c, 0xaa, 0xde, 0x7e, 0x48, 0x72, 0x68, 0x4f, 0x17, 0xb8, 0x22, 0xca, 0xfe, 0xcd, 0xa4, 0x45, 0xa1, 0x5c, 0xf3, 0xf, 0xac, 0x8c, 0xf0}, - output384: []byte{0x5d, 0x7d, 0xc5, 0xfc, 0x9d, 0xe8, 0x8b, 0x1c, 0xc, 0x46, 0xaa, 0x6d, 0x49, 0x27, 0x35, 0x5, 0xff, 0x7a, 0x76, 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 0x85, 0xf7, 0x40, 0x3e, 0xe2, 0x22, 0x3d, 0x52, 0xd3, 0x7b, 0x4b, 0xf4, 0x26, 0x42, 0x86, 0x13, 0xd6, 0xb4, 0x25, 0x79, 0x80, 0x97, 0x2a, 0xa, 0xca, 0xb5, 0x8, 0xa7, 0x62, 0xc, 0x1c, 0xb2, 0x8e, 0xb4, 0xe9, 0xd3, 0xf, 0xc4, 0x13, 0x61, 0xec}, - output224: []byte{0xbe, 0x3b, 0xe4, 0x99, 0x80, 0xf4, 0x3f, 0xb6, 0x59, 0x8b, 0xe9, 0x21, 0xd7, 0xd8, 0xfd, 0xa1, 0xf3, 0x97, 0xf6, 0x5, 0xd9, 0x70, 0x8c, 0x5d, 0x12, 0x5c, 0x4e, 0x9f}, - output256: []byte{0x71, 0xe1, 0xd6, 0x10, 0xb5, 0x76, 0x6, 0x3f, 0x2b, 0x12, 0xf6, 0x91, 0x22, 0xb, 0xea, 0xdf, 0x50, 0x6b, 0xec, 0xa, 0x3a, 0x8, 0x6b, 0xbe, 0x58, 0x64, 0xfb, 0x54, 0xf9, 0x3d, 0xb5, 0x56}, - output384: []byte{0x3d, 0x6b, 0xba, 0x14, 0x5d, 0x7e, 0x69, 0xdb, 0xbb, 0xf, 0x9, 0x9d, 0x47, 0xa1, 0xf2, 0x13, 0x8d, 0x4a, 0x0, 0xf2, 0x6b, 0x7, 0xc6, 0x2c, 0xf3, 0x84, 0x71, 0xf0, 0xfb, 0x9c, 0xa0, 0x22, 0xc6, 0x1f, 0x7a, 0x76, 0x90, 0x13, 0xa9, 0xbd, 0x8d, 0x5d, 0x87, 0xd8, 0xe0, 0x1d, 0x9b, 0x4d}, - output512: []byte{0xd3, 0x8e, 0xf3, 0xb1, 0x2e, 0xaa, 0xb, 0xf6, 0x2a, 0x75, 0xb6, 0xb6, 0x3c, 0xff, 0x3c, 0x9e, 0xf1, 0x71, 0xde, 0x1b, 0x75, 0xf5, 0xd0, 0x26, 0x29, 0x36, 0x5b, 0xcf, 0xe6, 0x5b, 0xa7, 0xdd, 0xd3, 0xf, 0xce, 0xf7, 0xfe, 0xbb, 0x82, 0xf1, 0x9f, 0x9b, 0xed, 0xcc, 0x1c, 0xc4, 0xc6, 0x79, 0xb4, 0x29, 0x2e, 0xa6, 0x2c, 0x2a, 0x90, 0xa7, 0x56, 0x2d, 0xa9, 0xa1, 0x31, 0x8f, 0xe2, 0x78}, - }, - { - msg: []byte{0xe8, 0x8a, 0xb0, 0x86, 0x89, 0x16, 0x93, 0xaa, 0x53, 0x5c, 0xeb, 0x20, 0xe6, 0x4c, 0x7a, 0xb9, 0x7c, 0x7d, 0xd3, 0x54, 0x8f, 0x37, 0x86, 0x33, 0x98, 0x97, 0xa5, 0xf0, 0xc3, 0x90, 0x31, 0x54, 0x9c, 0xa8, 0x70, 0x16, 0x6e, 0x47, 0x77, 0x43, 0xcc, 0xfb, 0xe0, 0x16, 0xb4, 0x42, 0x8d, 0x89, 0x73, 0x8e, 0x42, 0x6f, 0x5f, 0xfe, 0x81, 0x62, 0x61, 0x37, 0xf1, 0x7a, 0xec, 0xff, 0x61, 0xb7, 0x2d, 0xbe, 0xe2, 0xdc, 0x20, 0x96, 0x18, 0x80, 0xcf, 0xe2, 0x81, 0xdf, 0xab, 0x5e, 0xe3, 0x8b, 0x19, 0x21, 0x88, 0x14, 0x50, 0xe1, 0x60, 0x32, 0xde, 0x5e, 0x4d, 0x55, 0xad, 0x8d, 0x4f, 0xca, 0x60, 0x97, 0x21, 0xb0, 0x69, 0x2b, 0xac, 0x79, 0xbe, 0x5a, 0x6, 0xe1, 0x77, 0xfe, 0x8c, 0x80, 0xc0, 0xc8, 0x35, 0x19, 0xfb, 0x33, 0x47, 0xde, 0x9f, 0x43, 0xd5, 0x56, 0x1c, 0xb8, 0x10, 0x7b, 0x9b, 0x5e, 0xdc}, - output224: []byte{0x93, 0x21, 0x37, 0xbf, 0x2c, 0xd3, 0x2d, 0xdf, 0xd3, 0xba, 0x80, 0xc5, 0x25, 0x26, 0x87, 0x30, 0xb6, 0xf7, 0x45, 0x86, 0x1, 0xb5, 0x29, 0x6a, 0xeb, 0x32, 0x51, 0x83}, - output256: []byte{0x72, 0xa8, 0xa7, 0x49, 0x33, 0x9, 0x8, 0xa, 0xcc, 0xca, 0x2a, 0x2a, 0x21, 0xd6, 0x41, 0xf2, 0xb9, 0x68, 0x5b, 0x73, 0x62, 0xbe, 0x49, 0x6d, 0xc7, 0xbc, 0x33, 0x6, 0x59, 0xf8, 0xcf, 0xe1}, - output384: []byte{0xfb, 0xce, 0xf8, 0xd, 0xd0, 0x6e, 0x7e, 0xb, 0x3b, 0x7a, 0x54, 0x85, 0xca, 0x5b, 0xc2, 0xb3, 0x88, 0xcb, 0x91, 0xa2, 0x89, 0xf, 0x18, 0x1c, 0x85, 0x7b, 0x3e, 0xa, 0xbe, 0xfd, 0x60, 0x65, 0x49, 0x9d, 0x82, 0xdd, 0x55, 0xf3, 0xfc, 0xd1, 0x7e, 0x35, 0x1c, 0xa, 0x36, 0x36, 0xb8, 0x59}, - output512: []byte{0x60, 0xc9, 0x5c, 0x27, 0x4f, 0x99, 0xb8, 0x64, 0x3a, 0x18, 0x63, 0x44, 0xbc, 0x1, 0xd1, 0x27, 0x90, 0x10, 0xbe, 0x55, 0xd1, 0xbe, 0x76, 0xf4, 0xe6, 0xf9, 0x19, 0xf6, 0xb5, 0x4d, 0x33, 0x5e, 0xe0, 0xe1, 0xca, 0x92, 0x13, 0x3f, 0x3d, 0x7a, 0x25, 0x20, 0xcd, 0x82, 0xc4, 0x0, 0xe, 0x15, 0xef, 0xed, 0x8d, 0x8a, 0x66, 0xf3, 0x1b, 0x16, 0xb0, 0x97, 0x7c, 0x63, 0xde, 0x1b, 0xeb, 0x5}, - }, - { - msg: []byte{0xfd, 0x19, 0xe0, 0x1a, 0x83, 0xeb, 0x6e, 0xc8, 0x10, 0xb9, 0x45, 0x82, 0xcb, 0x8f, 0xbf, 0xa2, 0xfc, 0xb9, 0x92, 0xb5, 0x36, 0x84, 0xfb, 0x74, 0x8d, 0x22, 0x64, 0xf0, 0x20, 0xd3, 0xb9, 0x60, 0xcb, 0x1d, 0x6b, 0x8c, 0x34, 0x8c, 0x2b, 0x54, 0xa9, 0xfc, 0xea, 0x72, 0x33, 0xc, 0x2a, 0xaa, 0x9a, 0x24, 0xec, 0xdb, 0x0, 0xc4, 0x36, 0xab, 0xc7, 0x2, 0x36, 0x1a, 0x82, 0xbb, 0x88, 0x28, 0xb8, 0x53, 0x69, 0xb8, 0xc7, 0x2e, 0xce, 0x0, 0x82, 0xfe, 0x6, 0x55, 0x71, 0x63, 0x89, 0x9c, 0x2a, 0xe, 0xfa, 0x46, 0x6c, 0x33, 0xc0, 0x43, 0x43, 0xa8, 0x39, 0x41, 0x70, 0x57, 0x39, 0x9a, 0x63, 0xa3, 0x92, 0x9b, 0xe1, 0xee, 0x48, 0x5, 0xd6, 0xce, 0x3e, 0x5d, 0xd, 0x9, 0x67, 0xfe, 0x90, 0x4, 0x69, 0x6a, 0x56, 0x63, 0xf4, 0xca, 0xc9, 0x17, 0x90, 0x6, 0xa2, 0xce, 0xb7, 0x55, 0x42, 0xd7, 0x5d, 0x68}, - output224: []byte{0x79, 0x66, 0x98, 0xce, 0x24, 0xef, 0xcd, 0xa8, 0x21, 0x4d, 0x16, 0x11, 0x38, 0xf3, 0xc7, 0xda, 0x6d, 0x76, 0x15, 0xe4, 0xcf, 0x1d, 0xac, 0x63, 0xb6, 0x99, 0x41, 0xf9}, - output256: []byte{0xaf, 0x19, 0xe9, 0x88, 0xd3, 0x7e, 0x25, 0x77, 0xda, 0x4f, 0x43, 0x46, 0x37, 0x89, 0xb7, 0x36, 0x25, 0xd3, 0x54, 0xfc, 0xcc, 0xbd, 0x10, 0xcd, 0x2c, 0x61, 0xfb, 0xdc, 0x8b, 0xb0, 0x18, 0x27}, - output384: []byte{0x33, 0x8a, 0xac, 0xba, 0xc8, 0xac, 0x5b, 0xcc, 0x13, 0xfa, 0xfc, 0xe, 0xc6,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, 0x50, 0x7b, 0xf2, 0x1, 0x26, 0x3f, 0x30, 0x54, 0x38, 0x19, 0x51, 0xc, 0x12, 0xbc, 0x23, 0xe2, 0xdd, 0xb4, 0xf7, 0x11, 0xd0, 0x87, 0xa8, 0x6e, 0xdb, 0x1b, 0x35, 0x53, 0x13, 0x36, 0x3a, 0x2d, 0xe9, 0x96, 0xb8, 0x91, 0x2, 0x5e, 0x14, 0x70, 0x36, 0x8, 0x74, 0x1, 0xcc, 0xf3, 0xca, 0x78, 0x15, 0xbf, 0x3c, 0x49}, - output224: []byte{0xb2, 0x16, 0x93, 0xe, 0x15, 0x8d, 0x65, 0xfb, 0x1f, 0xf4, 0x24, 0xf9, 0xea, 0xb6, 0xcd, 0x28, 0x99, 0x62, 0x31, 0xef, 0x5e, 0xe1, 0xd6, 0x5d, 0xbe, 0x29, 0xd3, 0x70}, - output256: []byte{0xf1, 0xe9, 0xb9, 0xce, 0xf2, 0xb3, 0x7e, 0x4e, 0xc3, 0xa0, 0xfc, 0xd5, 0xef, 0xf5, 0xbf, 0x7e, 0x3d, 0x49, 0x10, 0xa, 0xeb, 0xf0, 0x18, 0xdc, 0x92, 0xfb, 0x6a, 0x40, 0xe4, 0x29, 0x77, 0x4}, - output384: []byte{0xff, 0xc9, 0x8d, 0x84, 0xc2, 0x68, 0xbd, 0x9, 0xca, 0xd0, 0x9c, 0xd7, 0xb4, 0xbf, 0x9d, 0x35, 0xed, 0xe9, 0x7e, 0xc5, 0x58, 0x85, 0xe8, 0x39, 0xe5, 0x57, 0xd2, 0x1e, 0xcc, 0xe, 0x28, 0xa8, 0x55, 0x0, 0x3, 0x86, 0xe6, 0x8f, 0xaa, 0xe3, 0xe6, 0x4a, 0x19, 0xb4, 0x43, 0xb2, 0x58, 0x7d}, - output512: []byte{0x74, 0x87, 0x16, 0x4d, 0x40, 0x88, 0x74, 0xaf, 0xdf, 0x7, 0xeb, 0xda, 0xde, 0x8c, 0x62, 0xe7, 0x56, 0x14, 0x7b, 0xea, 0xb3, 0x23, 0x8b, 0x87, 0x38, 0xae, 0xed, 0x92, 0x7f, 0x54, 0xfe, 0x6d, 0x33, 0xaf, 0x39, 0x17, 0xd4, 0xe1, 0x81, 0xb5, 0xc, 0xbc, 0x88, 0xa3, 0x79, 0xc7, 0x35, 0x85, 0xf9, 0xfb, 0xa4, 0xc1, 0xb6, 0x7b, 0x4b, 0xe4, 0x49, 0x0, 0x4e, 0xa0, 0xf6, 0x6d, 0x11, 0xad}, - }, - { - msg: []byte{0x77, 0xee, 0x80, 0x4b, 0x9f, 0x32, 0x95, 0xab, 0x23, 0x62, 0x79, 0x8b, 0x72, 0xb0, 0xa1, 0xb2, 0xd3, 0x29, 0x1d, 0xce, 0xb8, 0x13, 0x98, 0x96, 0x35, 0x58, 0x30, 0xf3, 0x4b, 0x3b, 0x32, 0x85, 0x61, 0x53, 0x1f, 0x80, 0x79, 0xb7, 0x9a, 0x6e, 0x99, 0x80, 0x70, 0x51, 0x50, 0x86, 0x64, 0x2, 0xfd, 0xc1, 0x76, 0xc0, 0x58, 0x97, 0xe3, 0x59, 0xa6, 0xcb, 0x1a, 0x7a, 0xb0, 0x67, 0x38, 0x3e, 0xb4, 0x97, 0x18, 0x2a, 0x7e, 0x5a, 0xef, 0x70, 0x38, 0xe4, 0xc9, 0x6d, 0x13, 0x3b, 0x27, 0x82, 0x91, 0x74, 0x17, 0xe3, 0x91, 0x53, 0x5b, 0x5e, 0x1b, 0x51, 0xf4, 0x7d, 0x8e, 0xd7, 0xe4, 0xd4, 0x2, 0x5f, 0xe9, 0x8d, 0xc8, 0x7b, 0x9c, 0x16, 0x22, 0x61, 0x4b, 0xff, 0x3d, 0x10, 0x29, 0xe6, 0x8e, 0x37, 0x2d, 0xe7, 0x19, 0x80, 0x38, 0x57, 0xca, 0x52, 0x6, 0x7c, 0xdd, 0xaa, 0xd9, 0x58, 0x95, 0x1c, 0xb2, 0x6, 0x8c, 0xc6}, - output224: []byte{0xaf, 0x6c, 0x67, 0x6a, 0x62, 0x28, 0x8b, 0x2d, 0x25, 0xa8, 0x62, 0xf8, 0x86, 0x6b, 0x26, 0x2a, 0x74, 0xe3, 0xd2, 0xa0, 0xd4, 0x14, 0xb9, 0x66, 0xce, 0x60, 0x1e, 0x14}, - output256: []byte{0xdd, 0x3e, 0xbe, 0xc, 0xca, 0xc, 0xad, 0x3a, 0xf7, 0x2a, 0xf7, 0x3f, 0xb4, 0x9d, 0x40, 0xdb, 0xdc, 0xc4, 0xb1, 0xf1, 0xff, 0x46, 0x5c, 0xca, 0xef, 0xe6, 0x72, 0xf7, 0x79, 0x92, 0xac, 0xa0}, - output384: []byte{0x47, 0x14, 0x65, 0x89, 0xc, 0x3b, 0x9c, 0x3, 0xed, 0xfb, 0xf0, 0xf6, 0x88, 0x3d, 0x56, 0x57, 0x40, 0xba, 0xda, 0x3b, 0x76, 0x28, 0xad, 0x6a, 0x27, 0xf7, 0x29, 0xc3, 0x5c, 0x1a, 0x86, 0x66, 0x95, 0x3e, 0x8b, 0x99, 0xd2, 0xc8, 0x9e, 0xde, 0xb, 0xd2, 0xd5, 0xd7, 0xf, 0xde, 0xf1, 0x1b}, - output512: []byte{0xf, 0x41, 0xab, 0x2d, 0x10, 0xc5, 0x1e, 0x28, 0x63, 0x8d, 0xad, 0x17, 0x86, 0x55, 0xf1, 0x60, 0xb2, 0xf7, 0x53, 0xdb, 0x44, 0xee, 0xd6, 0xce, 0x41, 0x4, 0x69, 0x3c, 0xc4, 0xa9, 0x38, 0xd8, 0x87, 0x61, 0x77, 0x74, 0xaf, 0xec, 0xb3, 0x3b, 0x89, 0xe, 0xe7, 0xfc, 0x57, 0x76, 0x56, 0xce, 0x16, 0x8e, 0xea, 0x42, 0xc6, 0x4, 0xd1, 0x52, 0xb9, 0x52, 0xc9, 0xb7, 0x72, 0xc9, 0xb5, 0x30}, - }, - { - msg: []byte{0xb7, 0x71, 0xd5, 0xce, 0xf5, 0xd1, 0xa4, 0x1a, 0x93, 0xd1, 0x56, 0x43, 0xd7, 0x18, 0x1d, 0x2a, 0x2e, 0xf0, 0xa8, 0xe8, 0x4d, 0x91, 0x81, 0x2f, 0x20, 0xed, 0x21, 0xf1, 0x47, 0xbe, 0xf7, 0x32, 0xbf, 0x3a, 0x60, 0xef, 0x40, 0x67, 0xc3, 0x73, 0x4b, 0x85, 0xbc, 0x8c, 0xd4, 0x71, 0x78, 0xf, 0x10, 0xdc, 0x9e, 0x82, 0x91, 0xb5, 0x83, 0x39, 0xa6, 0x77, 0xb9, 0x60, 0x21, 0x8f, 0x71, 0xe7, 0x93, 0xf2, 0x79, 0x7a, 0xea, 0x34, 0x94, 0x6, 0x51, 0x28, 0x29, 0x6, 0x5d, 0x37, 0xbb, 0x55, 0xea, 0x79, 0x6f, 0xa4, 0xf5, 0x6f, 0xd8, 0x89, 0x6b, 0x49, 0xb2, 0xcd, 0x19, 0xb4, 0x32, 0x15, 0xad, 0x96, 0x7c, 0x71, 0x2b, 0x24, 0xe5, 0x3, 0x2d, 0x6, 0x52, 0x32, 0xe0, 0x2c, 0x12, 0x74, 0x9, 0xd2, 0xed, 0x41, 0x46, 0xb9, 0xd7, 0x5d, 0x76, 0x3d, 0x52, 0xdb, 0x98, 0xd9, 0x49, 0xd3, 0xb0, 0xfe, 0xd6, 0xa8, 0x5, 0x2f, 0xbb}, - output224: []byte{0x41, 0x8c, 0x83, 0xeb, 0x1, 0x88, 0x1b, 0x4f, 0x38, 0x54, 0x46, 0x65, 0x20, 0x1d, 0xd0, 0x5c, 0x93, 0x9c, 0xa0, 0x47, 0xd3, 0x18, 0x34, 0xf6, 0x37, 0x34, 0x23, 0x42}, - output256: []byte{0xa1, 0x9e, 0xee, 0x92, 0xbb, 0x20, 0x97, 0xb6, 0x4e, 0x82, 0x3d, 0x59, 0x77, 0x98, 0xaa, 0x18, 0xbe, 0x9b, 0x7c, 0x73, 0x6b, 0x80, 0x59, 0xab, 0xfd, 0x67, 0x79, 0xac, 0x35, 0xac, 0x81, 0xb5}, - output384: []byte{0xf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 0x87, 0x40, 0xb6, 0xee, 0x2d, 0x3f, 0x71, 0xf7, 0x68, 0xdd, 0x41, 0x7f, 0x52, 0x4, 0x82, 0xbd, 0x3a, 0x8, 0xd4, 0xf2, 0x22, 0xb4, 0xee, 0x9d, 0xbd, 0x1, 0x54, 0x47, 0xb3, 0x35, 0x7, 0xdd, 0x50, 0xf3, 0xab, 0x42, 0x47, 0xc5, 0xde, 0x9a, 0x8a, 0xbd, 0x62, 0xa8, 0xde, 0xce, 0xa0, 0x1e, 0x3b, 0x87, 0xc8, 0xb9, 0x27, 0xf5, 0xb0, 0x8b, 0xeb, 0x37, 0x67, 0x4c, 0x6f, 0x8e, 0x38, 0xc, 0x4}, - output224: []byte{0x64, 0xd7, 0x88, 0x17, 0x71, 0x4f, 0xe0, 0x52, 0x72, 0xd3, 0x80, 0x5e, 0x6e, 0x19, 0x5, 0x6b, 0x16, 0x49, 0x3, 0x6c, 0xdc, 0xd5, 0x9, 0x4f, 0xd1, 0xcc, 0x89, 0xa}, - output256: []byte{0xdf, 0x67, 0x3f, 0x41, 0x5, 0x37, 0x9f, 0xf6, 0xb7, 0x55, 0xee, 0xab, 0x20, 0xce, 0xb0, 0xdc, 0x77, 0xb5, 0x28, 0x63, 0x64, 0xfe, 0x16, 0xc5, 0x9c, 0xc8, 0xa9, 0x7, 0xaf, 0xf0, 0x77, 0x32}, - output384: []byte{0xca, 0xd2, 0xd2, 0x8f, 0xbd, 0xcc, 0x3a, 0x5d, 0x71, 0xfb, 0x3a, 0xdc, 0xee, 0xc5, 0x23, 0x13, 0xad, 0x41, 0xd4, 0xff, 0x1f, 0x91, 0x5c, 0xaa, 0x34, 0xee, 0x12, 0x78, 0x39, 0xdb, 0xf2, 0xe9, 0xa7, 0xb0, 0x6e, 0x1c, 0x4e, 0xcd, 0x62, 0x55, 0x92, 0x6c, 0x16, 0xc0, 0x6e, 0x51, 0xef, 0xd0}, - output512: []byte{0x2e, 0x29, 0x37, 0x65, 0x2, 0x2d, 0x48, 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0x6d, 0xac, 0x57, 0xb3, 0xf2, 0x2d, 0xa8, 0x73, 0xc6, 0x1, 0x1, 0x6a, 0xd}, - output224: []byte{0x2c, 0x4e, 0x7c, 0x53, 0x7d, 0xe, 0x2a, 0xf2, 0x26, 0x1a, 0x66, 0x9b, 0xc2, 0x4b, 0xd0, 0xdf, 0x16, 0xd2, 0xc7, 0x2a, 0x7f, 0x98, 0xd7, 0xa5, 0xef, 0x6a, 0x81, 0x50}, - output256: []byte{0xd5, 0x24, 0x32, 0xcf, 0x3b, 0x6b, 0x4b, 0x94, 0x9a, 0xa8, 0x48, 0xe0, 0x58, 0xdc, 0xd6, 0x2d, 0x73, 0x5e, 0x1, 0x77, 0x27, 0x92, 0x22, 0xe7, 0xac, 0xa, 0xf8, 0x50, 0x47, 0x62, 0xfa, 0xa0}, - output384: []byte{0x5b, 0x19, 0x2e, 0xba, 0xb4, 0x72, 0x15, 0xa8, 0xe9, 0xfb, 0x8e, 0x4d, 0x56, 0x1b, 0x22, 0xb, 0x1d, 0xc3, 0x67, 0x7, 0xa3, 0xf0, 0x85, 0xf7, 0xbb, 0x1, 0x75, 0x33, 0x5c, 0x39, 0x32, 0x51, 0xe3, 0x46, 0x7f, 0x94, 0x55, 0x70, 0x42, 0xc, 0x74, 0x33, 0x65, 0xd0, 0xf0, 0x9b, 0x9e, 0x9}, - output512: []byte{0xbe, 0x8e, 0x14, 0xb6, 0x75, 0x7f, 0xfe, 0x53, 0xc9, 0xb7, 0x5f, 0x6d, 0xde, 0x9a, 0x7b, 0x6c, 0x40, 0x47, 0x40, 0x41, 0xde, 0x83, 0xd4, 0xa6, 0x6, 0x45, 0xa8, 0x26, 0xd7, 0xaf, 0x1a, 0xbe, 0x1e, 0xef, 0xcb, 0x7b, 0x74, 0xb6, 0x2c, 0xa6, 0xa5, 0x14, 0xe5, 0xf2, 0x69, 0x7d, 0x58, 0x5b, 0xfe, 0xce, 0xce, 0x12, 0x93, 0x1b, 0xbe, 0x1d, 0x4e, 0xd7, 0xeb, 0xf7, 0xb0, 0xbe, 0x66, 0xe}, - }, - { - msg: []byte{0x8b, 0x81, 0xe9, 0xba, 0xdd, 0xe0, 0x26, 0xf1, 0x4d, 0x95, 0xc0, 0x19, 0x97, 0x70, 0x24, 0xc9, 0xe1, 0x3d, 0xb7, 0xa5, 0xcd, 0x21, 0xf9, 0xe9, 0xfc, 0x49, 0x1d, 0x71, 0x61, 0x64, 0xbb, 0xac, 0xdc, 0x70, 0x60, 0xd8, 0x82, 0x61, 0x5d, 0x41, 0x14, 0x38, 0xae, 0xa0, 0x56, 0xc3, 0x40, 0xcd, 0xf9, 0x77, 0x78, 0x8f, 0x6e, 0x17, 0xd1, 0x18, 0xde, 0x55, 0x2, 0x68, 0x55, 0xf9, 0x32, 0x70, 0x47, 0x2d, 0x1f, 0xd1, 0x8b, 0x9e, 0x7e, 0x81, 0x2b, 0xae, 0x10, 0x7e, 0xd, 0xfd, 0xe7, 0x6, 0x33, 0x1, 0xb7, 0x1f, 0x6c, 0xfe, 0x4e, 0x22, 0x5c, 0xab, 0x3b, 0x23, 0x29, 0x5, 0xa5, 0x6e, 0x99, 0x4f, 0x8, 0xee, 0x28, 0x91, 0xba, 0x92, 0x2d, 0x49, 0xc3, 0xda, 0xfe, 0xb7, 0x5f, 0x7c, 0x69, 0x75, 0xc, 0xb6, 0x7d, 0x82, 0x2c, 0x96, 0x17, 0x6c, 0x46, 0xbd, 0x8a, 0x29, 0xf1, 0x70, 0x13, 0x73, 0xfb, 0x9, 0xa1, 0xa6, 0xe3, 0xc7, 0x15, 0x8f}, - output224: []byte{0xdf, 0x1f, 0xcb, 0x80, 0xab, 0x38, 0xc, 0xa3, 0x3b, 0xdb, 0x61, 0xf9, 0x6a, 0xda, 0xb3, 0x34, 0x93, 0x7e, 0x19, 0xf, 0x3, 0xc1, 0xb7, 0x8b, 0x21, 0x9e, 0x50, 0xf8}, - output256: []byte{0x7, 0xe6, 0x57, 0x54, 0xd6, 0x2e, 0x1, 0xb9, 0xa0, 0x49, 0xd1, 0x5d, 0xec, 0xd, 0x9, 0xc0, 0x2f, 0x47, 0x9c, 0xa2, 0xae, 0xb4, 0xb1, 0x8e, 0x37, 0x7, 0xb, 0x20, 0xf8, 0x5a, 0x1b, 0x26}, - output384: []byte{0xdf, 0x6f, 0x80, 0xb6, 0xd5, 0x6c, 0xff, 0xa8, 0x54, 0x5a, 0x27, 0xa2, 0x45, 0xa5, 0xe, 0x6c, 0x2d, 0x11, 0x7f, 0xc3, 0x59, 0x8f, 0x46, 0x5b, 0x6c, 0xd7, 0x85, 0x60, 0xf4, 0xb3, 0xc7, 0xd2, 0x12, 0x3f, 0x28, 0xf6, 0x7c, 0xa9, 0xe6, 0x5b, 0xfe, 0xb, 0x7f, 0x56, 0x6c, 0x57, 0xb9, 0xef}, - output512: []byte{0x6c, 0x7e, 0x64, 0xee, 0xd, 0x82, 0x60, 0x73, 0xd4, 0xf4, 0x4b, 0xcf, 0x15, 0x86, 0xa8, 0x3b, 0xac, 0xf3, 0xe2, 0xe1, 0x38, 0xdf, 0xdb, 0x65, 0xb8, 0xb8, 0xb3, 0x5f, 0xd7, 0xda, 0xe3, 0x0, 0xea, 0x6e, 0x32, 0xc6, 0x24, 0x5c, 0xca, 0x27, 0xc6, 0x74, 0xfe, 0xb2, 0x19, 0x67, 0x55, 0x94, 0x5a, 0xb7, 0xc5, 0xdc, 0xe9, 0x9e, 0xab, 0x91, 0x58, 0xa7, 0x55, 0x18, 0xac, 0x27, 0xc4, 0x31}, - }, - { - msg: []byte{0xfa, 0x6e, 0xed, 0x24, 0xda, 0x66, 0x66, 0xa2, 0x22, 0x8, 0x14, 0x6b, 0x19, 0xa5, 0x32, 0xc2, 0xec, 0x9b, 0xa9, 0x4f, 0x9, 0xf1, 0xde, 0xf1, 0xe7, 0xfc, 0x13, 0xc3, 0x99, 0xa4, 0x8e, 0x41, 0xac, 0xc2, 0xa5, 0x89, 0xd0, 0x99, 0x27, 0x62, 0x96, 0x34, 0x8f, 0x39, 0x62, 0x53, 0xb5, 0x7c, 0xb0, 0xe4, 0x2, 0x91, 0xbd, 0x28, 0x27, 0x73, 0x65, 0x6b, 0x6e, 0xd, 0x8b, 0xea, 0x1c, 0xda, 0x8, 0x4a, 0x37, 0x38, 0x81, 0x6a, 0x84, 0x4, 0x85, 0xfc, 0xf3, 0xfb, 0x30, 0x7f, 0x77, 0x7f, 0xa5, 0xfe, 0xac, 0x48, 0x69, 0x5c, 0x2a, 0xf4, 0x76, 0x97, 0x20, 0x25, 0x8c, 0x77, 0x94, 0x3f, 0xb4, 0x55, 0x6c, 0x36, 0x2d, 0x9c, 0xba, 0x8b, 0xf1, 0x3, 0xae, 0xb9, 0x3, 0x4b, 0xaa, 0x8e, 0xa8, 0xbf, 0xb9, 0xc4, 0xf8, 0xe6, 0x74, 0x2c, 0xe0, 0xd5, 0x2c, 0x49, 0xea, 0x8e, 0x97, 0x4f, 0x33, 0x96, 0x12, 0xe8, 0x30, 0xe9, 0xe7, 0xa9, 0xc2, 0x90, 0x65}, - output224: []byte{0xd, 0xd7, 0x7a, 0xda, 0x38, 0x4c, 0xab, 0x6a, 0x7a, 0xce, 0xd1, 0x9c, 0xfc, 0x80, 0x48, 0xc2, 0x56, 0x6d, 0x43, 0x3, 0xe2, 0x1, 0xc, 0x98, 0xd1, 0x6a, 0x5, 0x16}, - output256: []byte{0x17, 0xa4, 0x61, 0xb8, 0xee, 0x50, 0x7a, 0xbc, 0xfe, 0xd5, 0x1a, 0x50, 0xef, 0x14, 0x89, 0x13, 0x9, 0xfe, 0x40, 0x2c, 0x56, 0x9d, 0x94, 0x39, 0x4c, 0xa7, 0xa3, 0x3, 0x1b, 0xef, 0xcd, 0x50}, - output384: []byte{0xce, 0x97, 0xe9, 0xdf, 0x8, 0x78, 0x9d, 0x84, 0x15, 0x1a, 0x95, 0xc8, 0x13, 0x4f, 0xd, 0xb7, 0x4e, 0x5d, 0x4e, 0x7, 0x6e, 0xc, 0x15, 0x96, 0x68, 0x25, 0xc3,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8d, 0x62, 0x8c, 0x57, 0xe7, 0x7, 0xf0, 0xb0, 0xe8, 0x70, 0x7c, 0xaf, 0x91, 0xcd, 0x44, 0xbd, 0xb9, 0x15, 0xe0, 0x29, 0x6e, 0x1, 0x90, 0xd5, 0x6d, 0x33, 0xd8, 0xdd, 0xe1, 0xb, 0x5b, 0x60, 0x37, 0x78, 0x38, 0x97, 0x3c, 0x1d, 0x94, 0x3c, 0x22, 0xed, 0x33, 0x5e}, - output224: []byte{0xb2, 0x56, 0xd0, 0xd6, 0xb6, 0xd6, 0xa7, 0x2e, 0x11, 0x3d, 0x10, 0x5a, 0xd9, 0x60, 0x1c, 0x91, 0x93, 0x3d, 0x53, 0xb2, 0xa, 0x30, 0xd8, 0xe2, 0xcf, 0x33, 0xf9, 0x6d}, - output256: []byte{0xa0, 0x3c, 0x6b, 0x5b, 0x51, 0xae, 0x4a, 0xa0, 0x9, 0x12, 0xaf, 0x1c, 0xfb, 0x6c, 0x7b, 0x96, 0xe, 0xf5, 0x80, 0x36, 0x15, 0x64, 0x97, 0xcc, 0x56, 0x7b, 0x13, 0x69, 0x14, 0x9a, 0x59, 0x49}, - output384: []byte{0x89, 0xbf, 0x88, 0x9f, 0xbd, 0x7a, 0x38, 0x42, 0x90, 0xd3, 0xb1, 0xd5, 0x27, 0x9, 0xdb, 0xa6, 0x86, 0x35, 0x1e, 0x53, 0x93, 0x76, 0x30, 0xb7, 0xc7, 0xf0, 0x1b, 0xcd, 0xda, 0x19, 0xb1, 0x51, 0x7d, 0x31, 0x7d, 0x65, 0xe7, 0x99, 0xe6, 0x86, 0xc7, 0x1a, 0xa, 0xb4, 0xd6, 0x5b, 0x60, 0xb8}, - output512: []byte{0xf8, 0xb2, 0x45, 0x27, 0xb5, 0xc8, 0x4c, 0xa9, 0xa7, 0x2, 0xdb, 0x2f, 0x53, 0x5f, 0x78, 0xed, 0x3, 0x23, 0xc2, 0x93, 0x2a, 0x25, 0x5d, 0xb2, 0x4f, 0x87, 0x25, 0x51, 0xca, 0x7f, 0x5c, 0x4, 0x82, 0xb3, 0x69, 0xc, 0x62, 0xee, 0xc8, 0xad, 0x69, 0x30, 0x8d, 0xb2, 0xd7, 0x23, 0x8, 0xc4, 0xd6, 0x15, 0xcd, 0xe3, 0x83, 0x5b, 0x39, 0xb4, 0xf6, 0xff, 0x11, 0x54, 0x66, 0xf3, 0x27, 0x63}, - }, - { - msg: []byte{0x21, 0x67, 0xf0, 0x21, 0x18, 0xcc, 0x62, 0x4, 0x3e, 0x90, 0x91, 0xa6, 0x47, 0xca, 0xdb, 0xed, 0x95, 0x61, 0x1a, 0x52, 0x1f, 0xe0, 0xd6, 0x4e, 0x85, 0x18, 0xf1, 0x6c, 0x80, 0x8a, 0xb2, 0x97, 0x72, 0x55, 0x98, 0xae, 0x29, 0x68, 0x80, 0xa7, 0x73, 0x60, 0x7a, 0x79, 0x8f, 0x7c, 0x3c, 0xfc, 0xe8, 0xd, 0x25, 0x1e, 0xbe, 0xc6, 0x88, 0x50, 0x15, 0xf9, 0xab, 0xf7, 0xea, 0xab, 0xae, 0x46, 0x79, 0x8f, 0x82, 0xcb, 0x59, 0x26, 0xde, 0x5c, 0x23, 0xf4, 0x4a, 0x3f, 0x9f, 0x95, 0x34, 0xb3, 0xc6, 0xf4, 0x5, 0xb5, 0x36, 0x4c, 0x2f, 0x8a, 0x8b, 0xdc, 0x5c, 0xa4, 0x9c, 0x74, 0x9b, 0xed, 0x8c, 0xe4, 0xba, 0x48, 0x89, 0x70, 0x62, 0xae, 0x84, 0x24, 0xca, 0x6d, 0xde, 0x5f, 0x55, 0xc0, 0xe4, 0x2a, 0x95, 0xd1, 0xe2, 0x92, 0xca, 0x54, 0xfb, 0x46, 0xa8, 0x4f, 0xbc, 0x9c, 0xd8, 0x7f, 0x2d, 0xc, 0x9e, 0x74, 0x48, 0xde, 0x30, 0x43, 0xae, 0x22, 0xfd, 0xd2, 0x29}, - output224: []byte{0xb9, 0x5f, 0x72, 0x51, 0x25, 0x46, 0xe4, 0xaf, 0x68, 0x59, 0x31, 0x24, 0x67, 0x17, 0xbc, 0x48, 0x2b, 0xfe, 0x92, 0x27, 0x89, 0xa2, 0x6e, 0xef, 0x1, 0xbd, 0xe8, 0x2d}, - output256: []byte{0x14, 0xc6, 0x9c, 0x5e, 0xab, 0xde, 0xfc, 0x9e, 0x3a, 0x14, 0x61, 0xa3, 0x79, 0xec, 0x92, 0xc3, 0x2b, 0xc6, 0xb6, 0x90, 0x71, 0x2, 0x9c, 0xb3, 0x65, 0x51, 0x59, 0xdb, 0x1a, 0x52, 0x51, 0xa7}, - output384: []byte{0x5d, 0x40, 0xe3, 0x92, 0xc2, 0xe5, 0xb2, 0x9c, 0x80, 0xc2, 0xd7, 0x60, 0xa9, 0x3a, 0xa1, 0xe1, 0x93, 0x47, 0x2d, 0x7e, 0xe5, 0x9e, 0x20, 0x3d, 0xd4, 0x78, 0xfe, 0x24, 0xc5, 0xa6, 0x26, 0x4e, 0x28, 0x73, 0xaf, 0x31, 0xab, 0xde, 0x81, 0x82, 0x78, 0x62, 0x90, 0x1a, 0xe5, 0x95, 0x71, 0xbb}, - output512: []byte{0x8, 0xc6, 0xe3, 0x93, 0x8d, 0xe4, 0x81, 0x71, 0xa9, 0x96, 0x46, 0xbd, 0x9, 0xb, 0x7d, 0x53, 0xff, 0x42, 0x2a, 0xe6, 0x3f, 0x99, 0x85, 0x0, 0x32, 0xbd, 0x13, 0x1a, 0xc7, 0xbd, 0xfb, 0xa8, 0xf8, 0x34, 0x66, 0xad, 0x31, 0xfa, 0xd3, 0x16, 0x9d, 0x8a, 0x32, 0xf, 0xd9, 0x54, 0x8b, 0xdf, 0xf2, 0xc4, 0xb, 0xa2, 0xe, 0xd, 0x3, 0x1a, 0x80, 0x54, 0x1, 0x9c, 0x40, 0xed, 0x26, 0x62}, - }, - { - msg: []byte{0x94, 0xb7, 0xfa, 0xb, 0xc1, 0xc4, 0x4e, 0x94, 0x9b, 0x1d, 0x76, 0x17, 0xd3, 0x1b,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 0x82, 0x7a, 0x22, 0xa4, 0xd7}, - output384: []byte{0x7c, 0x63, 0xa0, 0xdc, 0x1c, 0x39, 0xcf, 0x4f, 0xab, 0x2d, 0x22, 0xf6, 0x2c, 0x1b, 0x0, 0x75, 0x7a, 0xa4, 0xb8, 0x9e, 0xd0, 0xd7, 0x12, 0x8d, 0xa2, 0x43, 0xd9, 0x8, 0x2a, 0xd0, 0xc7, 0x87, 0x84, 0xac, 0x24, 0xdf, 0x34, 0xf5, 0xab, 0x30, 0x37, 0x5f, 0x1d, 0x58, 0x1e, 0x74, 0x20, 0xbd}, - output512: []byte{0x69, 0x78, 0xad, 0x4b, 0xc4, 0xf0, 0xfc, 0x44, 0xc3, 0x5c, 0x66, 0x91, 0xca, 0x46, 0x62, 0x7d, 0x84, 0xb, 0xaa, 0x57, 0x2d, 0xe9, 0xb0, 0x21, 0x66, 0x73, 0xc9, 0x88, 0x19, 0x71, 0x91, 0xcd, 0xf8, 0x12, 0xcf, 0x21, 0x92, 0xe, 0x5, 0x2c, 0xc9, 0xce, 0x1d, 0x50, 0x7d, 0x1b, 0xa7, 0xdb, 0x6f, 0x15, 0x1d, 0x1, 0x62, 0xa, 0xda, 0x70, 0x2d, 0xc6, 0x37, 0xbf, 0x90, 0x80, 0x9c, 0x19}, - }, - { - msg: []byte{0xea, 0x40, 0xe8, 0x3c, 0xb1, 0x8b, 0x3a, 0x24, 0x2c, 0x1e, 0xcc, 0x6c, 0xcd, 0xb, 0x78, 0x53, 0xa4, 0x39, 0xda, 0xb2, 0xc5, 0x69, 0xcf, 0xc6, 0xdc, 0x38, 0xa1, 0x9f, 0x5c, 0x90, 0xac, 0xbf, 0x76, 0xae, 0xf9, 0xea, 0x37, 0x42, 0xff, 0x3b, 0x54, 0xef, 0x7d, 0x36, 0xeb, 0x7c, 0xe4, 0xff, 0x1c, 0x9a, 0xb3, 0xbc, 0x11, 0x9c, 0xff, 0x6b, 0xe9, 0x3c, 0x3, 0xe2, 0x8, 0x78, 0x33, 0x35, 0xc0, 0xab, 0x81, 0x37, 0xbe, 0x5b, 0x10, 0xcd, 0xc6, 0x6f, 0xf3, 0xf8, 0x9a, 0x1b, 0xdd, 0xc6, 0xa1, 0xee, 0xd7, 0x4f, 0x50, 0x4c, 0xbe, 0x72, 0x90, 0x69, 0xb, 0xb2, 0x95, 0xa8, 0x72, 0xb9, 0xe3, 0xfe, 0x2c, 0xee, 0x9e, 0x6c, 0x67, 0xc4, 0x1d, 0xb8, 0xef, 0xd7, 0xd8, 0x63, 0xcf, 0x10, 0xf8, 0x40, 0xfe, 0x61, 0x8e, 0x79, 0x36, 0xda, 0x3d, 0xca, 0x5c, 0xa6, 0xdf, 0x93, 0x3f, 0x24, 0xf6, 0x95, 0x4b, 0xa0, 0x80, 0x1a, 0x12, 0x94, 0xcd, 0x8d, 0x7e, 0x66, 0xdf, 0xaf, 0xec}, - output224: []byte{0xab, 0xf, 0xd3, 0x8, 0x59, 0x5, 0x74, 0xd6, 0xf6, 0x13, 0x2, 0x32, 0xd9, 0xfa, 0xfa, 0x9f, 0xfc, 0xfe, 0xa7, 0x85, 0x79, 0xa6, 0xa8, 0xf6, 0x7c, 0x59, 0x4, 0x20}, - output256: []byte{0xe5, 0x8a, 0x94, 0x7e, 0x98, 0xd6, 0xdd, 0x7e, 0x93, 0x2d, 0x2f, 0xe0, 0x2d, 0x99, 0x92, 0xe6, 0x11, 0x8c, 0xc, 0x2c, 0x60, 0x6b, 0xdc, 0xda, 0x6, 0xe7, 0x94, 0x3d, 0x2c, 0x95, 0xe0, 0xe5}, - output384: []byte{0xed, 0x8, 0x5d, 0x83, 0xa, 0xfd, 0x2d, 0x8f, 0x79, 0x62, 0x72, 0x81, 0xc2, 0xa8, 0x16, 0x3c, 0x39, 0x1f, 0xec, 0x2c, 0x58, 0x26, 0x8f, 0x66, 0xf7, 0x4c, 0xff, 0x97, 0x51, 0xbb, 0x29, 0xe0, 0xd0, 0x71, 0xea, 0x8f, 0xd2, 0xfc, 0xf9, 0x43,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 0xc5, 0x15, 0x11, 0xae, 0x49, 0x76, 0x6c, 0x79, 0x2a, 0x29, 0x52, 0x3, 0x88, 0x44, 0x4e, 0xbe, 0xfe, 0x28, 0x25, 0x6f, 0xb3, 0x3d, 0x42, 0x60, 0x43, 0x9c, 0xba, 0x73, 0xa9, 0x47, 0x9e, 0xe0, 0xc, 0x63}, - output224: []byte{0xd5, 0x13, 0x42, 0x0, 0xdc, 0x98, 0xf4, 0xca, 0x48, 0xc, 0xd2, 0x4d, 0x24, 0x49, 0x77, 0x37, 0x25, 0x2b, 0x55, 0x97, 0x7a, 0xe5, 0xa8, 0x69, 0xba, 0x27, 0x8, 0x9d}, - output256: []byte{0xa9, 0x36, 0xfb, 0x9a, 0xf8, 0x7f, 0xb6, 0x78, 0x57, 0xb3, 0xea, 0xd5, 0xc7, 0x62, 0x26, 0xad, 0x84, 0xda, 0x47, 0x67, 0x8f, 0x3c, 0x2f, 0xfe, 0x5a, 0x39, 0xfd, 0xb5, 0xf7, 0xe6, 0x3f, 0xfb}, - output384: []byte{0x29, 0x12, 0x47, 0x52, 0xcc, 0xd4, 0xac, 0x72, 0x4a, 0x9c, 0x3d, 0x53, 0xb0, 0xb3, 0x52, 0xaf, 0x2d, 0xbd, 0x76, 0x72, 0x9f, 0x8c, 0x5c, 0x64, 0x8b, 0x1e, 0x9d, 0x77, 0x81, 0x9f, 0x32, 0xe2, 0xa7, 0xde, 0xe, 0x15, 0x28, 0x64, 0x78, 0xa2, 0x4d, 0xf9, 0xbb, 0x37, 0xf, 0x85, 0x5c, 0x1c}, - output512: []byte{0xfe, 0x45, 0x28, 0x98, 0x74, 0x87, 0x97, 0x20, 0xce, 0x2a, 0x84, 0x4a, 0xe3, 0x4b, 0xb7, 0x35, 0x22, 0x77, 0x5d, 0xcb, 0x60, 0x19, 0xdc, 0xd2, 0x2b, 0x88, 0x85, 0x99, 0x46, 0x72, 0xa0, 0x88, 0x9c, 0x69, 0xe8, 0x11, 0x5c, 0x64, 0x1d, 0xc8, 0xb8, 0x3e, 0x39, 0xf7, 0x31, 0x18, 0x15, 0xa1, 0x64, 0xdc, 0x46, 0xe0, 0xba, 0x2f, 0xca, 0x34, 0x4d, 0x86, 0xd4, 0xbc, 0x2e, 0xf2, 0x53, 0x2c}, - }, - { - msg: []byte{0x83, 0x6b, 0x34, 0xb5, 0x15, 0x47, 0x6f, 0x61, 0x3f, 0xe4, 0x47, 0xa4, 0xe0, 0xc3, 0xf3, 0xb8, 0xf2, 0x9, 0x10, 0xac, 0x89, 0xa3, 0x97, 0x70, 0x55, 0xc9, 0x60, 0xd2, 0xd5, 0xd2, 0xb7, 0x2b, 0xd8, 0xac, 0xc7, 0x15, 0xa9, 0x3, 0x53, 0x21, 0xb8, 0x67, 0x3, 0xa4, 0x11, 0xdd, 0xe0, 0x46, 0x6d, 0x58, 0xa5, 0x97, 0x69, 0x67, 0x2a, 0xa6, 0xa, 0xd5, 0x87, 0xb8, 0x48, 0x1d, 0xe4, 0xbb, 0xa5, 0x52, 0xa1, 0x64, 0x57, 0x79, 0x78, 0x95, 0x1, 0xec, 0x53, 0xd5, 0x40, 0xb9, 0x4, 0x82, 0x1f, 0x32, 0xb0, 0xbd, 0x18, 0x55, 0xb0, 0x4e, 0x48, 0x48, 0xf9, 0xf8, 0xcf, 0xe9, 0xeb, 0xd8, 0x91, 0x1b, 0xe9, 0x57, 0x81, 0xa7, 0x59, 0xd7, 0xad, 0x97, 0x24, 0xa7, 0x10, 0x2d, 0xbe, 0x57, 0x67, 0x76, 0xb7, 0xc6, 0x32, 0xbc, 0x39, 0xb9, 0xb5, 0xe1, 0x90, 0x57, 0xe2, 0x26, 0x55, 0x2a, 0x59, 0x94, 0xc1, 0xdb, 0xb3, 0xb5, 0xc7, 0x87, 0x1a, 0x11, 0xf5, 0x53, 0x70, 0x11, 0x4, 0x4c, 0x53}, - output224: []byte{0x49, 0x4c, 0xbc, 0x9b, 0x64, 0x9e, 0x48, 0xec, 0x5a, 0xd7, 0x36, 0x4a, 0xeb, 0x9c, 0x8e, 0xdf, 0x4a, 0x4f, 0x40, 0x7, 0x89, 0xef, 0x20, 0x3f, 0x7b, 0x81, 0x8a, 0x44}, - output256: []byte{0x3a, 0x65, 0x4b, 0x88, 0xf8, 0x80, 0x86, 0xc2, 0x75, 0x1e, 0xda, 0xe6, 0xd3, 0x92, 0x48, 0x14, 0x3c, 0xf6, 0x23, 0x5c, 0x6b, 0xb, 0x79, 0x69, 0x34, 0x2c, 0x45, 0xa3, 0x51, 0x94, 0xb6, 0x7e}, - output384: []byte{0xfa, 0xea, 0xb5, 0x68, 0x7f, 0x39, 0xec, 0x98, 0x94, 0xc5, 0xcc, 0xff, 0xb5, 0x7e, 0x82, 0xa8, 0x4b, 0xbb, 0x7d, 0x49, 0x3c, 0xc6, 0xaf, 0xc0, 0x3d, 0x7, 0xac, 0x7b, 0x4f, 0x18, 0x1e, 0x61, 0x63, 0x9b, 0x9a, 0x47, 0x71, 0xc9, 0x99, 0x85, 0xed, 0x7f, 0xa1, 0x77, 0x3e, 0x1c, 0xa3, 0xf4}, - output512: []byte{0xaf, 0xf6, 0x1c, 0x6e, 0x11, 0xb9, 0x8e, 0x55, 0xac, 0x21, 0x3b, 0x1a, 0xb, 0xc7, 0xde, 0x4, 0x5, 0x22, 0x1a, 0xc5, 0xef, 0xb1, 0x22, 0x98, 0x42, 0xe4, 0x61, 0x4f, 0x4a, 0x2, 0x9c, 0x9b, 0xd1, 0x4a, 0xe, 0xd7, 0xfd, 0x99, 0xaf, 0x36, 0x81, 0x42, 0x9f, 0x3f, 0x30, 0x9f, 0xdb, 0x53, 0x16, 0x6a, 0xa9, 0xa3, 0xcd, 0x9f, 0x1f, 0x12, 0x23, 0xd0, 0x4b, 0x4a, 0x90, 0x15, 0xe9, 0x4a}, - }, - { - msg: []byte{0xcc, 0x77, 0x84, 0xa4, 0x91, 0x2a, 0x7a, 0xb5, 0xad, 0x36, 0x20, 0xaa, 0xb2, 0x9b, 0xa8, 0x70, 0x77, 0xcd, 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6e, 0x1e, 0xf2, 0xbd, 0xe, 0xe4, 0xae, 0x71, 0xbd, 0xe, 0x9b, 0x2f, 0x54, 0xf9, 0x1d, 0xaa, 0xdf, 0x1f, 0xeb, 0xfd, 0x70, 0x32, 0x38, 0x1d, 0x63, 0x6b, 0x73, 0x3d, 0xcb, 0x3b, 0xf7, 0x6f, 0xb1, 0x4e, 0x23, 0xaf, 0xf1, 0xf6, 0x8e, 0xd3, 0xdb, 0xcf, 0x75, 0xc9, 0xb9, 0x9c, 0x6f, 0x26}, - output224: []byte{0x29, 0xb6, 0xb5, 0x23, 0xc8, 0x2f, 0x49, 0x90, 0x78, 0xc7, 0x36, 0x30, 0xba, 0x38, 0x22, 0x7b, 0xbd, 0x8, 0xef, 0x1a, 0x2d, 0x67, 0xb4, 0x25, 0xc0, 0x58, 0xde, 0xf5}, - output256: []byte{0x9a, 0xe6, 0x70, 0xfa, 0x85, 0xab, 0x5c, 0x6b, 0x3b, 0xc7, 0x67, 0x97, 0xcf, 0x24, 0xcd, 0x38, 0x51, 0x10, 0x70, 0x81, 0x37, 0xb6, 0xf8, 0xef, 0xd8, 0xd1, 0xa2, 0x1c, 0x39, 0x88, 0x1c, 0x18}, - output384: []byte{0xe1, 0xb6, 0xda, 0xc3, 0xf1, 0x38, 0xb5, 0xf3, 0x36, 0xf1, 0xf7, 0x58, 0x94, 0xf8, 0x25, 0xff, 0xc1, 0x97, 0x83, 0x6c, 0x92, 0xbf, 0x35, 0x9b, 0x55, 0xbb, 0x2a, 0x78, 0x23, 0x9f, 0x24, 0xf9, 0xc4, 0xaa, 0x1e, 0x6, 0x3c, 0x9c, 0x2b, 0x27, 0x3b, 0x9c, 0xfa, 0x76, 0x6f, 0xbf, 0xba, 0xe5}, - output512: []byte{0xb2, 0x78, 0x28, 0xcf, 0xeb, 0xcf, 0x4d, 0x89, 0x6e, 0xab, 0xf1, 0xf8, 0x4d, 0x7, 0x98, 0x27, 0xb7, 0xdc, 0xc7, 0xf3, 0x8, 0xa2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xae, 0xd5, 0xfd, 0x2, 0xc3, 0x79, 0x44, 0xe7, 0x3b}, - output224: []byte{0x93, 0xce, 0xc, 0x8d, 0x43, 0x55, 0x30, 0xd, 0x4e, 0x63, 0xd6, 0x59, 0x91, 0x29, 0xde, 0xa7, 0x42, 0xe, 0x5b, 0x60, 0x9d, 0xbb, 0x35, 0xbe, 0x43, 0x2b, 0x12, 0xb5}, - output256: []byte{0xe3, 0x2d, 0xf6, 0x21, 0x8b, 0xa7, 0x5f, 0xd4, 0x78, 0x8a, 0x7e, 0x57, 0x27, 0xa7, 0xd6, 0x8c, 0x58, 0x29, 0xc4, 0x93, 0x46, 0x68, 0x3f, 0xc2, 0x13, 0xe4, 0x33, 0xaf, 0x3d, 0xba, 0x5a, 0xb5}, - output384: []byte{0x6e, 0x7, 0xb5, 0x9e, 0x93, 0xb2, 0x24, 0x75, 0x63, 0x3b, 0x5b, 0xa1, 0xaa, 0x68, 0x91, 0x11, 0x9c, 0xff, 0x69, 0x6, 0x97, 0xac, 0x67, 0x9e, 0x93, 0x49, 0xe8, 0x69, 0x4c, 0x65, 0x40, 0x74, 0xd9, 0x65, 0xf0, 0xc3, 0x2f, 0xf5, 0x17, 0xb1, 0xe, 0xe8, 0xf6, 0x99, 0x3f, 0x6e, 0x46, 0x46}, - output512: []byte{0x42, 0xfc, 0x6, 0xdc, 0xf9, 0x9b, 0x4e, 0x80, 0x4b, 0xb3, 0x49, 0x10, 0x1b, 0x46, 0xd6, 0xa6, 0xa7, 0x36, 0x6e, 0x47, 0x55, 0x54, 0x6, 0xea, 0x55, 0x42, 0x48, 0xba, 0xef, 0x52, 0xe1, 0x7a, 0xfa, 0x40, 0x82, 0x9f, 0x57, 0x9, 0xd0, 0x7f, 0xf4, 0x7, 0x88, 0x1d, 0xf1, 0x6, 0xf1, 0x56, 0xca, 0x73, 0x56, 0x22, 0xb0, 0xf0, 0x51, 0xd8, 0xc3, 0x72, 0xf6, 0xe8, 0x11, 0xcd, 0xae, 0x25}, - }, - { - msg: []byte{0x4c, 0xfa, 0x12, 0x78, 0x90, 0x30, 0x26, 0xf6, 0x6f, 0xed, 0xd4, 0x13, 0x74, 0x55, 0x8b, 0xe1, 0xb5, 0x85, 0xd0, 0x3c, 0x5c, 0x55, 0xda, 0xc9, 0x43, 0x61, 0xdf, 0x28, 0x6d, 0x4b, 0xd3, 0x9c, 0x7c, 0xb8, 0x3, 0x7e, 0xd3, 0xb2, 0x67, 0xb0, 0x7c, 0x34, 0x66, 0x26, 0x44, 0x9d, 0xc, 0xc5, 0xb0, 0xdd, 0x2c, 0xf2, 0x21, 0xf7, 0xe4, 0xc3, 0x44, 0x9a, 0x4b, 0xe9, 0x99, 0x85, 0xd2, 0xd5, 0xe6, 0x7b, 0xff, 0x29, 0x23, 0x35, 0x7d, 0xde, 0xab, 0x5a, 0xbc, 0xb4, 0x61, 0x9f, 0x3a, 0x3a, 0x57, 0xb2, 0xcf, 0x92, 0x8a, 0x2, 0x2e, 0xb2, 0x76, 0x76, 0xc6, 0xcf, 0x80, 0x56, 0x89, 0x0, 0x4f, 0xca, 0x4d, 0x41, 0xea, 0x6c, 0x2d, 0xa, 0x47, 0x89, 0xc7, 0x60, 0x5f, 0x7b, 0xb8, 0x38, 0xdd, 0x88, 0x3b, 0x3a, 0xd3, 0xe6, 0x2, 0x7e, 0x77, 0x5b, 0xcf, 0x26, 0x28, 0x81, 0x42, 0x80, 0x99, 0xc7, 0xff, 0xf9, 0x5b, 0x14, 0xc0, 0x95, 0xea, 0x13, 0xe, 0xb, 0x99, 0x38, 0xa5, 0xe2, 0x2f, 0xc5, 0x26, 0x50, 0xf5, 0x91}, - output224: []byte{0xd0, 0x28, 0x96, 0xd9, 0x57, 0xb5, 0x99, 0x86, 0x9f, 0x2b, 0x2a, 0x49, 0x92, 0xa4, 0x9e, 0xef, 0x7a, 0xb1, 0x30, 0x8f, 0x45, 0x6c, 0x78, 0xc8, 0x9, 0xbd, 0xac, 0x88}, - output256: []byte{0x2, 0x81, 0x73, 0xe3, 0xc6, 0xc3, 0x92, 0xe5, 0xd1, 0x3a, 0xf7, 0x48, 0xf3, 0x78, 0x8d, 0x43, 0x44, 0x9b, 0xc5, 0xdd, 0x59, 0x53, 0x12, 0x4e, 0xa5, 0xed, 0xf3, 0x93, 0x2, 0x75, 0xf6, 0x65}, - output384: []byte{0x19, 0xeb, 0x2e, 0x15, 0x26, 0x2a, 0x83, 0x95, 0x38, 0x84, 0x6f, 0x72, 0x52, 0x67, 0x69, 0x71, 0x20, 0x79, 0x13, 0x27, 0x9b, 0x9a, 0xe9, 0xb6, 0xba, 0x36, 0x50, 0xd8, 0xf3, 0xa8, 0xe5, 0x58, 0xb1, 0x3c, 0x35, 0xb3, 0x1f, 0x1a, 0xb7, 0x42, 0x9e, 0x37, 0x62, 0x55, 0x33, 0x8c, 0x4a, 0xa2}, - output512: []byte{0xc, 0xa8, 0x9c, 0x9b, 0x72, 0x73, 0xde, 0x38, 0x4f, 0xf3, 0x3f, 0x1b, 0xac, 0xbb, 0x85, 0x5, 0x62, 0x8c, 0x4d, 0x3e, 0x30, 0x35, 0xb, 0x33, 0x53, 0x61, 0x56, 0x3a, 0xd4, 0x16, 0xad, 0xa5, 0x23, 0x12, 0x2d, 0x37, 0xac, 0xbe, 0xc5, 0x77, 0x21, 0xf7, 0xbc, 0x5d, 0x9b, 0x4, 0x9e, 0x1f, 0x4f, 0xe3, 0xc4, 0xcf, 0xe0, 0x47, 0xe3, 0x3a, 0xe, 0x44, 0x8e, 0xf5, 0xd5, 0x53, 0x6c, 0xf0}, - }, - { - msg: []byte{0xd3, 0xe6, 0x5c, 0xb9, 0x2c, 0xfa, 0x79, 0x66, 0x2f, 0x6a, 0xf4, 0x93, 0xd6, 0x96, 0xa0, 0x7c, 0xcf, 0x32, 0xaa, 0xad, 0xcc, 0xef, 0xf0, 0x6e, 0x73, 0xe8, 0xd9, 0xf6, 0xf9, 0x9, 0x20, 0x9e, 0x66, 0x71, 0x5d, 0x6e, 0x97, 0x87, 0x88, 0xc4, 0x9e, 0xfb, 0x90, 0x87, 0xb1, 0x70, 0xec, 0xf3, 0xaa, 0x86, 0xd2, 0xd4, 0xd1, 0xa0, 0x65, 0xae, 0xe, 0xfc, 0x89, 0x24, 0xf3, 0x65, 0xd6, 0x76, 0xb3, 0xcb, 0x9e, 0x2b, 0xec, 0x91, 0x8f, 0xd9, 0x6d, 0xb, 0x43, 0xde, 0xe8, 0x37, 0x27, 0xc9, 0xa9, 0x3b, 0xf5, 0x6c, 0xa2, 0xb2, 0xe5, 0x9a, 0xdb, 0xa8, 0x56, 0x96, 0x54, 0x6a, 0x81, 0x50, 0x67, 0xfc, 0x7a, 0x78, 0x3, 0x96, 0x29, 0xd4, 0x94, 0x8d, 0x15, 0x7e, 0x7b, 0xd, 0x82, 0x6d, 0x1b, 0xf8, 0xe8, 0x12, 0x37, 0xba, 0xb7, 0x32, 0x13, 0x12, 0xfd, 0xaa, 0x4d, 0x52, 0x17, 0x44, 0xf9, 0x88, 0xdb, 0x6f, 0xdf, 0x4, 0x54, 0x9d, 0xf, 0xdc, 0xa3, 0x93, 0xd6, 0x39, 0xc7, 0x29, 0xaf, 0x71, 0x6e, 0x9c, 0x8b, 0xba, 0x48}, - output224: []byte{0x18, 0x1e, 0x23, 0x1, 0xf6, 0x29, 0xa5, 0x69, 0x27, 0x1b, 0xb7, 0x40, 0xd3, 0x2b, 0x1d, 0x3b, 0xd2, 0x5a, 0xcb, 0x17, 0x9e, 0x9a, 0xeb, 0xef, 0x98, 0x0, 0x9e, 0xd4}, - output256: []byte{0x97, 0x45, 0xf, 0xc4, 0x6f, 0x2e, 0x5d, 0xf8, 0xf8, 0x16, 0x23, 0xb1, 0xcc, 0xa4, 0x3f, 0xa5, 0xf, 0x51, 0xea, 0x73, 0x5e, 0x44, 0x21, 0xd7, 0xdf, 0xf6, 0x63, 0x14, 0xd8, 0xe2, 0x11, 0xbc}, - output384: []byte{0xf4, 0xda, 0x80, 0xb2, 0x6f, 0xb5, 0xe6, 0x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xe4, 0x96, 0x8, 0xad, 0x2d, 0x50, 0x30, 0x9e, 0x7d, 0x48, 0xd2, 0xd8, 0xde, 0x4f, 0xa5, 0x8a, 0xc3, 0xcf, 0xea, 0xfe, 0xee, 0x48, 0xc0, 0xa9, 0xee, 0xc8, 0x84, 0x98, 0xe3, 0xef, 0xc5, 0x1f, 0x54, 0xd3, 0x0, 0xd8, 0x28, 0xdd, 0xdc, 0xcb, 0x9d, 0xb, 0x6, 0xdd, 0x2, 0x1a, 0x29, 0xcf, 0x5c, 0xb5, 0xb2, 0x50, 0x69, 0x15, 0xbe, 0xb8, 0xa1, 0x19, 0x98, 0xb8, 0xb8, 0x86, 0xe0, 0xf9, 0xb7, 0xa8, 0xe, 0x97, 0xd9, 0x1a, 0x7d, 0x1, 0x27, 0xf, 0x9a, 0x77, 0x17}, - output224: []byte{0x5c, 0xd0, 0x17, 0xb2, 0x69, 0xa6, 0x36, 0x6c, 0x78, 0x9d, 0x9c, 0xec, 0xae, 0xf3, 0xee, 0x9c, 0x35, 0x75, 0x18, 0x1a, 0x8, 0x42, 0x66, 0xd7, 0x8a, 0x2, 0x8d, 0xb7}, - output256: []byte{0xab, 0x4e, 0x5a, 0x70, 0x39, 0x5, 0x77, 0xf8, 0xae, 0x26, 0xd, 0x53, 0xcb, 0xe, 0x70, 0x91, 0x4f, 0x8b, 0x93, 0x98, 0xab, 0xaa, 0x84, 0x1f, 0x78, 0x7, 0xf1, 0x47, 0x60, 0x46, 0xc6, 0x4f}, - output384: []byte{0xbd, 0xba, 0x78, 0x38, 0xa1, 0xe7, 0xa6, 0x1, 0xd5, 0x59, 0xf4, 0x9e, 0xc1, 0x32, 0x3b, 0x7c, 0x5f, 0xab, 0xe1, 0xe1, 0x9, 0xfd, 0xca, 0xff, 0x3f, 0x78, 0x65, 0xf9, 0xaf, 0x41, 0x96, 0xab, 0xbf, 0x60, 0xac, 0x12, 0x30, 0x97, 0xa7, 0xb8, 0x60, 0xfe, 0x43, 0x86, 0x84, 0x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 0x78, 0x2, 0xe6, 0x9e, 0x40, 0x5f, 0xe3, 0xc0, 0x4c, 0xeb, 0x55, 0x22, 0x79, 0x2a, 0x55, 0x3, 0xfa, 0x82, 0x9f, 0x70, 0x72, 0x72, 0x22, 0x66, 0x21, 0xf7, 0xc4, 0x88, 0xa7, 0x69, 0x8c, 0xd, 0x69, 0xaa, 0x56, 0x1b, 0xe9, 0xf3, 0x78}, - output224: []byte{0xac, 0x28, 0xa, 0x21, 0x1c, 0x98, 0xa0, 0x7f, 0x6f, 0xcb, 0xb7, 0x19, 0xf2, 0x50, 0xe3, 0xe5, 0xa6, 0xba, 0x2c, 0x93, 0xa8, 0x33, 0x97, 0x6c, 0x9f, 0x31, 0x47, 0xeb}, - output256: []byte{0x81, 0x18, 0xf2, 0xc1, 0x57, 0xdf, 0x12, 0x50, 0xdb, 0x43, 0xb3, 0x11, 0x83, 0xf4, 0x42, 0xf8, 0x9b, 0x32, 0x2e, 0x49, 0x69, 0x18, 0x83, 0x8c, 0x5b, 0x66, 0x8f, 0x96, 0x47, 0xac, 0x6d, 0x6b}, - output384: []byte{0x96, 0xdf, 0xe9, 0x99, 0x6b, 0xff, 0xa5, 0xe5, 0xd8, 0x3c, 0x39, 0xb1, 0x1f, 0x47, 0xf1, 0x2d, 0x11, 0x21, 0xf, 0x7d, 0x43, 0x0, 0xb7, 0x18, 0xd, 0x18, 0x91, 0xea, 0xaa, 0x7f, 0xe4, 0x80, 0x9f, 0x94, 0x89, 0xb1, 0xe2, 0x40, 0x7f, 0xf8, 0x7f, 0xb2, 0x62, 0x8d, 0xdf, 0x1f, 0xc0, 0x20}, - output512: []byte{0x33, 0xd6, 0x32, 0xe4, 0x3, 0xc9, 0xf9, 0xa9, 0x34, 0x9b, 0x28, 0xaa, 0x48, 0x21, 0xa1, 0x2b, 0x1d, 0xb5, 0x57, 0xd8, 0x92, 0x80, 0x3, 0xd3, 0xc, 0x57, 0xd7, 0x1, 0xcf, 0xf1, 0xc4, 0x9b, 0xac,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0xfa}, - output224: []byte{0xc2, 0x84, 0xc9, 0x30, 0x8a, 0x28, 0xb6, 0xd2, 0x9c, 0xca, 0xa7, 0x85, 0x3f, 0x8c, 0x41, 0xba, 0xdc, 0xdd, 0xbc, 0x1a, 0xa4, 0xe9, 0x94, 0x81, 0xa6, 0xee, 0x2f, 0x4d}, - output256: []byte{0x73, 0x6e, 0x30, 0xac, 0xcc, 0x55, 0x59, 0x18, 0x84, 0x12, 0xc7, 0x97, 0xa1, 0xa5, 0xbe, 0x61, 0xd1, 0xf9, 0xf, 0x14, 0x94, 0x1, 0xf6, 0x31, 0x59, 0x79, 0x44, 0x15, 0x5a, 0x85, 0xfa, 0xf7}, - output384: []byte{0x79, 0xcf, 0x2a, 0x30, 0x17, 0xf8, 0x26, 0x93, 0xc0, 0xa5, 0x31, 0xa3, 0x67, 0x18, 0x6d, 0x5, 0x5f, 0xce, 0x63, 0x8, 0x1e, 0xdf, 0x98, 0xc, 0x6a, 0xb, 0x96, 0x7b, 0x6e, 0xcc, 0xe7, 0x5d, 0x63, 0x5b, 0x98, 0x48, 0x5e, 0x9b, 0x6b, 0x28, 0x5b, 0x8, 0x33, 0x6f, 0xf3, 0x4e, 0x61, 0xc9}, - output512: []byte{0x95, 0x4c, 0x70, 0x9a, 0xbc, 0xb0, 0xbb, 0x88, 0x15, 0x92, 0xd9, 0x3f, 0x5c, 0x24, 0x63, 0xce, 0x8c, 0x6, 0xa, 0xd1, 0xdf, 0x30, 0x53, 0x30, 0x2e, 0xa7, 0xb1, 0x9f, 0x2b, 0x47, 0xbc, 0xf0, 0xfe, 0x35, 0x9a, 0x83, 0x2f, 0x9a, 0x86, 0x5a, 0x8d, 0x3d, 0xbd, 0x3b, 0xe5, 0x98, 0xdf, 0xd6, 0xd0, 0xfc, 0x1c, 0x57, 0x4e, 0xca, 0xa, 0xec, 0x78, 0xd8, 0xe3, 0x28, 0x83, 0x99, 0xbe, 0x5}, - }, - { - msg: []byte{0x83, 0x59, 0x9d, 0x93, 0xf5, 0x56, 0x1e, 0x82, 0x1b, 0xd0, 0x1a, 0x47, 0x23, 0x86, 0xbc, 0x2f, 0xf4, 0xef, 0xbd, 0x4a, 0xed, 0x60, 0xd5, 0x82, 0x1e, 0x84, 0xaa, 0xe7, 0x4d, 0x80, 0x71, 0x2, 0x98, 0x10, 0xf5, 0xe2, 0x86, 0xf8, 0xf1, 0x76, 0x51, 0xcd, 0x27, 0xda, 0x7, 0xb1, 0xeb, 0x43, 0x82, 0xf7, 0x54, 0xcd, 0x1c, 0x95, 0x26, 0x87, 0x83, 0xad, 0x9, 0x22, 0xf, 0x55, 0x2, 0x84, 0x3, 0x70, 0xd4, 0x94, 0xbe, 0xb1, 0x71, 0x24, 0x22, 0xf, 0x6a, 0xfc, 0xe9, 0x1e, 0xc8, 0xa0, 0xf5, 0x52, 0x31, 0xf9, 0x65, 0x24, 0x33, 0xe5, 0xce, 0x34, 0x89, 0xb7, 0x27, 0x71, 0x6c, 0xf4, 0xae, 0xba, 0x7d, 0xcd, 0xa2, 0xc, 0xd2, 0x9a, 0xa9, 0xa8, 0x59, 0x20, 0x12, 0x53, 0xf9, 0x48, 0xdd, 0x94, 0x39, 0x5a, 0xba, 0x9e, 0x38, 0x52, 0xbd, 0x1d, 0x60, 0xdd, 0xa7, 0xae, 0x5d, 0xc0, 0x45, 0xb2, 0x83, 0xda, 0x0, 0x6e, 0x1c, 0xba, 0xd8, 0x3c, 0xc1, 0x32, 0x92, 0xa3, 0x15, 0xdb, 0x55, 0x53, 0x30, 0x5c, 0x62, 0x8d, 0xd0, 0x91, 0x14, 0x65, 0x97}, - output224: []byte{0x3d, 0x9a, 0x97, 0x9b, 0x34, 0xd4, 0x55, 0x69, 0xe1, 0xc9, 0x8d, 0x9, 0xdc, 0x62, 0xd0, 0x36, 0x16, 0xc0, 0x25, 0x1c, 0x41, 0xa8, 0xb9, 0x1, 0x38, 0x75, 0xf, 0x1e}, - output256: []byte{0x95, 0x99, 0xde, 0xec, 0xcc, 0x69, 0x8a, 0x24, 0xa4, 0x61, 0xa7, 0x41, 0x9e, 0x91, 0x93, 0x9c, 0x74, 0x16, 0x13, 0xf4, 0xce, 0x88, 0x7d, 0xba, 0x89, 0xdc, 0x7e, 0x32, 0x7c, 0x51, 0xf5, 0xbf}, - output384: []byte{0xe, 0xd3, 0xca, 0x16, 0x20, 0xce, 0x3a, 0x92, 0x3a, 0x22, 0xe9, 0xd1, 0x3b, 0xbf, 0x75, 0x43, 0xac, 0xee, 0x5, 0xf6, 0x6b, 0x67, 0xe6, 0xd6, 0xf4, 0x35, 0xbc, 0x51, 0x3f, 0x46, 0x98, 0x94, 0x9c, 0x27, 0x52, 0x80, 0x68, 0xf8, 0x92, 0xf0, 0x87, 0x19, 0x16, 0xfe, 0x2d, 0x4, 0x33, 0xc3}, - output512: []byte{0xa3, 0x37, 0x6, 0x2f, 0x5e, 0x5c, 0x9c, 0x35, 0x34, 0x1a, 0x51, 0x22, 0x4f, 0x2a, 0x59, 0xe6, 0xcf, 0x91, 0x9a, 0x63, 0xbf, 0x59, 0xa6, 0xcf, 0xce, 0x26, 0x11, 0x94, 0xbb, 0xd6, 0x60, 0xf2, 0x8c, 0x29, 0x48, 0xd0, 0x3c, 0xdc, 0xe5, 0xc7, 0xc1, 0x51, 0xec, 0x5, 0xb4, 0x2a, 0xad, 0xd8, 0x30, 0x51, 0xa1, 0x6a, 0x62, 0xf0, 0xc7, 0xdf, 0x39, 0xaa, 0xa4, 0xef, 0xc8, 0x2c, 0xe4, 0xd3}, - }, - { - msg: []byte{0x2b, 0xe9, 0xbf, 0x52, 0x6c, 0x9d, 0x5a, 0x75, 0xd5, 0x65, 0xdd, 0x11, 0xef, 0x63, 0xb9, 0x79, 0xd0, 0x68, 0x65, 0x9c, 0x7f, 0x2, 0x6c, 0x8, 0xbe, 0xa4, 0xaf, 0x16, 0x1d, 0x85, 0xa4, 0x62, 0xd8, 0xe, 0x45, 0x4, 0xe, 0x91, 0xf4, 0x16, 0x5c, 0x7, 0x4c, 0x43, 0xac, 0x66, 0x13, 0x80, 0x31, 0x1a, 0x8c, 0xbe, 0xd5, 0x9c, 0xc8, 0xe4, 0xc4, 0x51, 0x8e, 0x80, 0xcd, 0x2c, 0x78, 0xab, 0x1c, 0xab, 0xf6, 0x6b, 0xff, 0x83, 0xea, 0xb3, 0xa8, 0x1, 0x48, 0x55, 0x3, 0x7, 0x31, 0x9, 0x50, 0xd0, 0x34, 0xa6, 0x28, 0x6c, 0x93, 0xa1, 0xec, 0xe8, 0x92, 0x9e, 0x63, 0x85, 0xc5, 0xe3, 0xbb, 0x6e, 0xa8, 0xa7, 0xc0, 0xfb, 0x6d, 0x63, 0x32, 0xe3, 0x20, 0xe7, 0x1c, 0xc4, 0xeb, 0x46, 0x2a, 0x2a, 0x62, 0xe2, 0xbf, 0xe0, 0x8f, 0xc, 0xca, 0xd9, 0x3e, 0x61, 0xbe, 0xdb, 0x5d, 0xd0, 0xb7, 0x86, 0xa7, 0x28, 0xab, 0x66, 0x6f, 0x7, 0xe0, 0x57, 0x6d, 0x18, 0x9c, 0x92, 0xbf, 0x9f, 0xb2, 0xd, 0xca, 0x49, 0xac, 0x2d, 0x39, 0x56, 0xd4, 0x73, 0x85, 0xe2}, - output224: []byte{0x8d, 0xdc, 0x9f, 0x1e, 0xf, 0x94, 0xc1, 0x24, 0x7a, 0x67, 0xd6, 0x11, 0x9a, 0x91, 0x69, 0x76, 0x2c, 0x6c, 0x7f, 0x1e, 0xc7, 0xf6, 0x11, 0xd6, 0x13, 0x53, 0xab, 0x30}, - output256: []byte{0xbe, 0xd, 0x87, 0x16, 0x6, 0xa4, 0xc1, 0x29, 0xce, 0xf6, 0x16, 0xf4, 0x38, 0x60, 0xd, 0x5c, 0xbc, 0xe, 0x9f, 0x49, 0xd2, 0xad, 0xc8, 0xa8, 0x65, 0x71, 0xc1, 0x92, 0x36, 0x1c, 0x3f, 0x4f}, - output384: []byte{0x69, 0xa2, 0x7b, 0xbf, 0x8, 0xe, 0x1, 0x55, 0x92, 0x89, 0x3d, 0x3b, 0x55, 0xd1, 0x95, 0x7d, 0x26, 0x77, 0x84, 0x56, 0x99, 0x23, 0xa4, 0x66, 0x16, 0x5a, 0x6f, 0xb1, 0x29, 0x61, 0x3d, 0x8e, 0xa6, 0xf6, 0x10, 0xf3, 0x76, 0xe, 0x34, 0x9d, 0x46, 0xb0, 0x92, 0x77, 0xcb, 0x85, 0x45, 0x46}, - output512: []byte{0x43, 0xe9, 0xd0, 0xea, 0x8e, 0x52, 0x6e, 0x83, 0x23, 0x4d, 0x7b, 0x63, 0xd8, 0x24, 0x4c, 0x7e, 0x7b, 0x12, 0xae, 0x2a, 0xcc, 0x80, 0x82, 0xf9, 0x86, 0x36, 0x72, 0x68, 0xf1, 0x1, 0x56, 0x57, 0x43, 0x0, 0x17, 0x28, 0x73, 0x84, 0x5b, 0x20, 0x7a, 0x72, 0x52, 0x62, 0x42, 0x46, 0xe7, 0xd3, 0x2c, 0xe0, 0xf7, 0x28, 0x2e, 0x0, 0xc4, 0x55, 0x2f, 0x61, 0x80, 0xf3, 0x4e, 0x59, 0xe, 0x2e}, - }, - { - msg: []byte{0xca, 0x76, 0xd3, 0xa1, 0x25, 0x95, 0xa8, 0x17, 0x68, 0x26, 0x17, 0x0, 0x68, 0x48, 0x67, 0x55, 0x47, 0xd3, 0xe8, 0xf5, 0xc, 0x22, 0x10, 0xf9, 0xaf, 0x90, 0x6c, 0xe, 0x7c, 0xe5, 0xb, 0x44, 0x60, 0x18, 0x6f, 0xe7, 0x4, 0x57, 0xa9, 0xe8, 0x79, 0xe7, 0x9f, 0xd4, 0xd1, 0xa6, 0x88, 0xc7, 0xa, 0x34, 0x73, 0x61, 0xc8, 0x47, 0xba, 0xd, 0xd6, 0xaa, 0x52, 0x93, 0x6e, 0xaf, 0x8e, 0x58, 0xa1, 0xbe, 0x2f, 0x5c, 0x1c, 0x70, 0x4e, 0x20, 0x14, 0x6d, 0x36, 0x6a, 0xeb, 0x38, 0x53, 0xbe, 0xd9, 0xde, 0x9b, 0xef, 0xe9, 0x56, 0x9a, 0xc8, 0xaa, 0xea, 0x37, 0xa9, 0xfb, 0x71, 0x39, 0xa1, 0xa1, 0xa7, 0xd5, 0xc7, 0x48, 0x60, 0x5a, 0x8d, 0xef, 0xb2, 0x97, 0x86, 0x9e, 0xbe, 0xdd, 0x71, 0xd6, 0x15, 0xa5, 0xda, 0x23, 0x49, 0x6d, 0x11, 0xe1, 0x1a, 0xbb, 0xb1, 0x26, 0xb2, 0x6, 0xfa, 0xa, 0x77, 0x97, 0xee, 0x7d, 0xe1, 0x17, 0x98, 0x60, 0x12, 0xd0, 0x36, 0x2d, 0xce, 0xf7, 0x75, 0xc2, 0xfe, 0x14, 0x5a, 0xda, 0x6b, 0xda, 0x1c, 0xcb, 0x32, 0x6b, 0xf6, 0x44}, - output224: []byte{0x46, 0xed, 0xa2, 0x62, 0x2d, 0x49, 0xb9, 0x14, 0x8b, 0x40, 0xb6, 0x1, 0x4c, 0x75, 0xa4, 0x8, 0x6e, 0xb9, 0xdd, 0x47, 0x40, 0xf0, 0xdd, 0x59, 0x1a, 0xca, 0x53, 0xb2}, - output256: []byte{0x4d, 0x30, 0x60, 0xc, 0x60, 0xed, 0x94, 0xa0, 0xd2, 0xbc, 0xc1, 0x75, 0x71, 0xa1, 0x9b, 0xd0, 0x17, 0xc, 0xda, 0xca, 0xc7, 0x8d, 0x4, 0x21, 0xe0, 0xbb, 0xae, 0x2a, 0x36, 0xa4, 0x8b, 0x6d}, - output384: []byte{0xe9, 0xc8, 0x83, 0x1, 0x40, 0x62, 0x96, 0x69, 0xa1, 0xdc, 0x5c, 0x8e, 0xe2, 0x7b, 0xe6, 0x69, 0xb7, 0x12, 0x2f, 0x4d, 0xc8, 0x82, 0x24, 0x63, 0x5c, 0xde, 0x33, 0x4a, 0xd9, 0x96, 0x15, 0xf3, 0xfd, 0xc4, 0x86, 0x9e, 0x56, 0x26, 0x3e, 0x3c, 0x7f, 0x44, 0x20, 0x73, 0x6f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xbd, 0xf7, 0xb6, 0x3b, 0xb, 0x33, 0x8e, 0x93, 0x1e, 0x31, 0xb8, 0x7c, 0x24, 0xb1, 0x46, 0xc6, 0xd0, 0x40, 0x60, 0x55, 0x67, 0xce, 0xef, 0x59, 0x60, 0xdf, 0x9e, 0x2, 0x2c, 0xb4, 0x69, 0xd4, 0xc7, 0x87, 0xf4, 0xcb, 0xa3, 0xc5, 0x44, 0xa1, 0xac, 0x91, 0xf9, 0x5f}, - output224: []byte{0x57, 0xcf, 0xa1, 0x37, 0x96, 0x8c, 0x39, 0xea, 0xa1, 0x25, 0x33, 0x4, 0x4b, 0x82, 0x65, 0xbb, 0x90, 0x3e, 0xc1, 0x6c, 0x8d, 0x17, 0xb6, 0xcf, 0x1f, 0x10, 0x6c, 0x57}, - output256: []byte{0x3b, 0xd6, 0xfb, 0x72, 0x76, 0x4f, 0x7a, 0xd4, 0x39, 0x1b, 0x7b, 0x40, 0xae, 0xa4, 0x24, 0xab, 0xd5, 0xf5, 0x56, 0x1a, 0xc5, 0x6f, 0x9e, 0x7, 0x2c, 0x75, 0x3d, 0x60, 0x90, 0xfa, 0x4b, 0xfb}, - output384: []byte{0x4d, 0xf0, 0x60, 0x27, 0x61, 0x5, 0xbf, 0x0, 0x2f, 0x8e, 0x9f, 0x3f, 0x8, 0xd5, 0xb5, 0x1f, 0x7c, 0x2a, 0xdf, 0xe5, 0xaa, 0xb9, 0xa1, 0xa6, 0x83, 0xc0, 0x53, 0xe0, 0x45, 0xc8, 0x9a, 0x88, 0x30, 0x28, 0xb1, 0x9, 0x34, 0x61, 0x36, 0x82, 0x62, 0xea, 0x85, 0xf5, 0x23, 0x9a, 0xc7, 0xb1}, - output512: []byte{0xd9, 0xa4, 0x27, 0x61, 0xf9, 0x80, 0xc7, 0x8c, 0x36, 0xcf, 0x54, 0xc4, 0x20, 0x7b, 0xa, 0x62, 0x95, 0x4e, 0x15, 0xa9, 0x7, 0xa7, 0xce, 0xa1, 0x49, 0xb3, 0x7a,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0x61, 0xe2, 0xa5, 0x8d, 0x7, 0x78, 0xf0, 0x91, 0x20, 0x6a, 0xab, 0xd5, 0xa1}, - output224: []byte{0x87, 0x30, 0xc2, 0x19, 0xe1, 0x9d, 0x9d, 0x37, 0xcb, 0x7a, 0x63, 0xa4, 0xdd, 0xd5, 0x5e, 0x84, 0xdc, 0xb0, 0x23, 0x6e, 0xf7, 0xc8, 0x82, 0x8b, 0x2a, 0x23, 0xc9, 0xb9}, - output256: []byte{0x66, 0x89, 0xbb, 0x25, 0xba, 0xee, 0xc, 0x58, 0x2f, 0x8f, 0x1b, 0xc, 0x87, 0x7, 0x3b, 0xe3, 0x66, 0x64, 0x4d, 0xa8, 0x59, 0x31, 0x3b, 0xec, 0xf4, 0x46, 0x43, 0x5d, 0x2f, 0x6e, 0x89, 0x9e}, - output384: []byte{0x81, 0x6a, 0xa6, 0xdb, 0x9b, 0x66, 0x32, 0x88, 0xe5, 0xf9, 0x32, 0xf0, 0xfe, 0xaf, 0xf0, 0xee, 0x78, 0x75, 0xc3, 0xb3, 0xe6, 0xfb, 0xac, 0xc, 0xdd, 0xc4, 0x58, 0xbd, 0x64, 0x63, 0x71, 0x96, 0x9c, 0xf5, 0xd, 0x2d, 0x9, 0x42, 0xfc, 0xc7, 0x40, 0x35, 0x73, 0xb0, 0x1b, 0x5, 0xb4, 0x55}, - output512: []byte{0xbb, 0x65, 0xd8, 0x94, 0x34, 0x13, 0xce, 0xf8, 0x9f, 0xdb, 0x5, 0xb3, 0x5a, 0x55, 0xec, 0x75, 0x3, 0xe4, 0x54, 0x6a, 0x50, 0xfc, 0x3e, 0xcc, 0x82, 0x5d, 0xab, 0xc1, 0xa1, 0xda, 0xe6, 0xc7, 0x71, 0xbb, 0x19, 0x7f, 0x32, 0x36, 0x25, 0x87, 0x7e, 0xb, 0xcc, 0xaa, 0x41, 0x25, 0x3c, 0x99, 0xb6, 0x69, 0x29, 0x76, 0xb9, 0x9f, 0xc6, 0x87, 0xb0, 0xb6, 0xb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x6, 0x37, 0x51, 0x95, 0xa, 0x1a, 0x8f, 0x93, 0x53, 0x9b, 0xea, 0x32, 0xf8, 0x4e, 0xa1}, - output256: []byte{0x26, 0x28, 0xdd, 0xc7, 0x75, 0x82, 0x8, 0xaa, 0x9f, 0x1e, 0x49, 0x49, 0x72, 0x24, 0xeb, 0x26, 0x8c, 0x6d, 0x2b, 0xcd, 0xaa, 0xb4, 0x82, 0xd, 0xe9, 0xc1, 0x6a, 0x65, 0xc6, 0xf6, 0x1, 0x7a}, - output384: []byte{0x12, 0x5b, 0x51, 0xc2, 0x53, 0x39, 0x16, 0x77, 0xc5, 0x9c, 0x3, 0x32, 0xc6, 0xa1, 0x3d, 0x7, 0xde, 0x55, 0xea, 0xb8, 0x8, 0x57, 0x59, 0x3f, 0x8, 0x39, 0xa5, 0x6f, 0xa6, 0x78, 0xc5, 0xe2, 0xf7, 0xcb, 0x2f, 0x93, 0x4a, 0xbe, 0x5e, 0x58, 0x87, 0x80, 0x4a, 0xab, 0x5d, 0x8f, 0x13, 0xe1}, - output512: []byte{0x54, 0xd, 0xf2, 0x21, 0x80, 0xb6, 0x9b, 0x9a, 0x83, 0x30, 0x66, 0x19, 0xb2, 0xca, 0x8c, 0xd8, 0xe0, 0x7a, 0x34, 0xbb, 0xeb, 0x22, 0x19, 0xac, 0x7c, 0xf8, 0x8b, 0x46, 0x8a, 0x94, 0x7c, 0x44, 0x48, 0x48, 0x9b, 0x30, 0x3b, 0xd6, 0x55, 0x6, 0xc9, 0xe1, 0xce, 0x59, 0x34, 0x8a, 0x9d, 0x86, 0x3a, 0xab, 0x51, 0x54, 0x84, 0x8e, 0x95, 0xb5, 0x38, 0x97, 0x83, 0xf6, 0xf5, 0xfb, 0x6a, 0xd8}, - }, - { - msg: []byte{0x4e, 0x45, 0x2b, 0xa4, 0x21, 0x27, 0xdc, 0xc9, 0x56, 0xef, 0x4f, 0x8f, 0x35, 0xdd, 0x68, 0xcb, 0x22, 0x5f, 0xb7, 0x3b, 0x5b, 0xc7, 0xe1, 0xec, 0x5a, 0x89, 0x8b, 0xba, 0x29, 0x31, 0x56, 0x3e, 0x74, 0xfa, 0xff, 0x3b, 0x67, 0x31, 0x4f, 0x24, 0x1e, 0xc4, 0x9f, 0x4a, 0x70, 0x61, 0xe3, 0xbd, 0x2, 0x13, 0xae, 0x82, 0x6b, 0xab, 0x38, 0xf, 0x1f, 0x14, 0xfa, 0xab, 0x8b, 0xe, 0xfd, 0xdd, 0x5f, 0xd1, 0xbb, 0x49, 0x37, 0x38, 0x53, 0xa0, 0x8f, 0x30, 0x55, 0x3d, 0x5a, 0x55, 0xcc, 0xbb, 0xb8, 0x15, 0x3d, 0xe4, 0x70, 0x4f, 0x29, 0xca, 0x2b, 0xde, 0xef, 0x4, 0x19, 0x46, 0x8e, 0x5, 0xdd, 0x51, 0x55, 0x7c, 0xcc, 0x80, 0xc0, 0xa9, 0x61, 0x90, 0xbb, 0xcc, 0x4d, 0x77, 0xec, 0xff, 0x21, 0xc6, 0x6b, 0xdf, 0x48, 0x64, 0x59, 0xd4, 0x27, 0xf9, 0x86, 0x41, 0xf, 0x88, 0x3a, 0x80, 0xa5, 0xbc, 0xc3, 0x2c, 0x20, 0xf0, 0x47, 0x8b, 0xb9, 0xa9, 0x7a, 0x12, 0x6f, 0xc5, 0xf9, 0x54, 0x51, 0xe4, 0xf, 0x29, 0x2a, 0x46, 0x14, 0x93, 0xd, 0x5, 0x4c, 0x85, 0x1a, 0xcd, 0x1, 0x9c, 0xcf}, - output224: []byte{0x14, 0x59, 0x4, 0x4d, 0xf9, 0xc2, 0x6f, 0x5e, 0x24, 0xf, 0x6a, 0x6b, 0x93, 0x80, 0x73, 0x4c, 0xad, 0x84, 0xb6, 0x59, 0x2f, 0xc9, 0x69, 0x3d, 0xdd, 0x9f, 0x97, 0x4e}, - output256: []byte{0xdf, 0x44, 0x89, 0x36, 0xee, 0x72, 0xd9, 0xfe, 0x6c, 0xcf, 0xb3, 0x7d, 0x18, 0x3a, 0xaf, 0xdd, 0xc7, 0x90, 0x8e, 0x1, 0x62, 0x71, 0xaf, 0xa8, 0x1e, 0xc0, 0x83, 0xa1, 0xa, 0x14, 0x4f, 0x5d}, - output384: []byte{0x13, 0xc, 0x4b, 0x6, 0xa5, 0x5f, 0x11, 0xc8, 0xc, 0x41, 0x60, 0x8a, 0xdf, 0xd7, 0xb4, 0xce, 0x87, 0x95, 0x87, 0x1b, 0xcf, 0x16, 0x90, 0xf, 0x20, 0xd2, 0x75, 0x1e, 0x12, 0x3b, 0x41, 0xd3, 0xb2, 0x4, 0x8f, 0xd0, 0x52, 0x67, 0xc2, 0xf9, 0x65, 0x3e, 0xce, 0x36, 0x30, 0xbd, 0xd3, 0x30}, - output512: []byte{0x6, 0x2e, 0x4a, 0x11, 0xa7, 0x9f, 0xdb, 0x9c, 0xbc, 0x3a, 0xe, 0x4c, 0x5f, 0x98, 0x75, 0xca, 0xaa, 0x56, 0x8b, 0xc7, 0x13, 0x6, 0x6e, 0x2, 0xd2, 0xa9, 0xca, 0x4d, 0x27, 0x88, 0x6c, 0xe2, 0x3f, 0x70, 0x8, 0x3a, 0x2b, 0xf4, 0xd0, 0xe7, 0xc5, 0x5b, 0x12, 0xf, 0xe6, 0xd1, 0x97, 0x20, 0x3d, 0xc1, 0xc2, 0xfd, 0x34, 0x69, 0x11, 0x2a, 0x8, 0x83, 0x67, 0x27, 0x85, 0x9e, 0x1f, 0x83}, - }, - { - msg: []byte{0xfa, 0x85, 0x67, 0x1d, 0xf7, 0xda, 0xdf, 0x99, 0xa6, 0xff, 0xee, 0x97, 0xa3, 0xab, 0x99, 0x91, 0x67, 0x1f, 0x56, 0x29, 0x19, 0x50, 0x49, 0x88, 0x4, 0x97, 0x48, 0x78, 0x67, 0xa6, 0xc4, 0x46, 0xb6, 0x0, 0x87, 0xfa, 0xc9, 0xa0, 0xf2, 0xfc, 0xc8, 0xe3, 0xb2, 0x4e, 0x97, 0xe4, 0x23, 0x45, 0xb9, 0x3b, 0x5f, 0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 0x40, 0xcb, 0xbe, 0x9a, 0x3c, 0x1c, 0x6f, 0x7e, 0x5a, 0x43, 0x7b, 0xa2, 0xf, 0x26, 0x73, 0x6f, 0x28, 0x95, 0xf8, 0x1d, 0x53, 0xbe, 0xc9, 0x2a, 0x18, 0x6e, 0x74, 0x76, 0x29, 0x10, 0xc4, 0xaa, 0x62, 0x56, 0x53, 0x73, 0xd3, 0x8b, 0x28, 0xd5, 0xfd}, - output512: []byte{0x9e, 0x1c, 0x6e, 0xe0, 0xc4, 0x7b, 0x2d, 0x2c, 0xb7, 0x7f, 0x60, 0x2c, 0xab, 0x53, 0xac, 0x4c, 0x69, 0xc6, 0x97, 0x78, 0x29, 0x78, 0x94, 0x55, 0x41, 0x96, 0xcb, 0x58, 0x6, 0x3, 0x32, 0xc9, 0xfd, 0x89, 0x23, 0xf4, 0x5c, 0x4b, 0x8e, 0xc2, 0x6e, 0x16, 0xa5, 0xd0, 0x4e, 0x63, 0x7, 0xfb, 0x99, 0x85, 0xa, 0x45, 0x40, 0xea, 0x83, 0xe3, 0xf2, 0x62, 0x6f, 0x33, 0x43, 0xe9, 0x72, 0x25}, - }, - { - msg: []byte{0xe9, 0x8, 0x47, 0xae, 0x67, 0x97, 0xfb, 0xc0, 0xb6, 0xb3, 0x6d, 0x6e, 0x58, 0x8c, 0xa, 0x74, 0x3d, 0x72, 0x57, 0x88, 0xca, 0x50, 0xb6, 0xd7, 0x92, 0x35, 0x2e, 0xa8, 0x29, 0x4f, 0x5b, 0xa6, 0x54, 0xa1, 0x53, 0x66, 0xb8, 0xe1, 0xb2, 0x88, 0xd8, 0x4f, 0x51, 0x78, 0x24, 0x8, 0x27, 0x97, 0x5a, 0x76, 0x3b, 0xc4, 0x5c, 0x7b, 0x4, 0x30, 0xe8, 0xa5, 0x59, 0xdf, 0x44, 0x88, 0x50, 0x5e, 0x0, 0x9c, 0x63, 0xda, 0x99, 0x4f, 0x14, 0x3, 0xf4, 0x7, 0x95, 0x82, 0x3, 0xce, 0xbb, 0x6e, 0x37, 0xd8, 0x9c, 0x94, 0xa5, 0xea, 0xcf, 0x60, 0x39, 0xa3, 0x27, 0xf6, 0xc4, 0xdb, 0xbc, 0x7a, 0x2a, 0x30, 0x7d, 0x97, 0x6a, 0xa3, 0x9e, 0x41, 0xaf, 0x65, 0x37, 0x24, 0x3f, 0xc2, 0x18, 0xdf, 0xa6, 0xab, 0x4d, 0xd8, 0x17, 0xb6, 0xa3, 0x97, 0xdf, 0x5c, 0xa6, 0x91, 0x7, 0xa9, 0x19, 0x87, 0x99, 0xed, 0x24, 0x86, 0x41, 0xb6, 0x3b, 0x42, 0xcb, 0x4c, 0x29, 0xbf, 0xdd, 0x79, 0x75, 0xac, 0x96, 0xed, 0xfc, 0x27, 0x4a, 0xc5, 0x62, 0xd0, 0x47, 0x4c, 0x60, 0x34, 0x7a, 0x7, 0x8c, 0xe4, 0xc2, 0x5e, 0x88}, - output224: []byte{0xa6, 0x40, 0xd4, 0x84, 0x13, 0x90, 0xf4, 0x7d, 0xc4, 0x7d, 0x4b, 0xfc, 0xf1, 0x30, 0xfc, 0xf5, 0x1c, 0x5f, 0x2d, 0x49, 0x1f, 0x91, 0xc1, 0x33, 0x74, 0xce, 0x59, 0x65}, - output256: []byte{0x14, 0x62, 0xf2, 0xea, 0x1c, 0x35, 0x80, 0xc0, 0xa2, 0xe8, 0xc0, 0xb3, 0xc, 0x27, 0xa6, 0x8, 0xd8, 0x2c, 0xd7, 0x7, 0xf6, 0xd1, 0xa0, 0xaa, 0xd5, 0xcc, 0x7c, 0x3d, 0x1b, 0x8d, 0x6c, 0x30}, - output384: []byte{0x7c, 0x1f, 0x1a, 0x46, 0xe4, 0x9, 0x4, 0x6b, 0x5a, 0x31, 0x47, 0x67, 0xe8, 0xb7, 0xe7, 0xb1, 0xd9, 0xa9, 0x29, 0x31, 0x44, 0x3c, 0x5d, 0x2, 0xa5, 0x81, 0x37, 0x1b, 0x38, 0xa, 0xfa, 0x18, 0x67, 0xe5, 0x54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 0xd3, 0x8e, 0x8e, 0x38, 0x53, 0x9a, 0x70, 0xe1, 0x94, 0xcc, 0x55, 0x13, 0xaa, 0xa4, 0x57, 0xc6, 0x99, 0x38, 0x3f, 0xd1, 0x90, 0xb, 0x1e, 0x72, 0xbd, 0xfb, 0x83, 0x5d, 0x1f, 0xd3, 0x21, 0xb3, 0x7b, 0xa8, 0x5, 0x49, 0xb0, 0x78, 0xa4, 0x9e, 0xa0, 0x81, 0x52, 0x86, 0x9a, 0x91, 0x8c, 0xa5, 0x7f, 0x5b, 0x54, 0xed, 0x71, 0xe4, 0xfd, 0x3a, 0xc5, 0xc0, 0x67, 0x29}, - output224: []byte{0x85, 0xbb, 0x3e, 0xd9, 0x8c, 0x48, 0x8, 0xd8, 0xf6, 0x7c, 0x72, 0x2c, 0x91, 0x19, 0xc5, 0x4e, 0x65, 0x43, 0xb2, 0x9e, 0x57, 0xbd, 0x4f, 0xb5, 0xcb, 0xc8, 0x78, 0xc7}, - output256: []byte{0x61, 0x7b, 0x41, 0x2e, 0xd6, 0x4f, 0x56, 0xd6, 0xdb, 0x36, 0xb7, 0xe5, 0x2e, 0xad, 0x61, 0x8d, 0x95, 0xa0, 0x91, 0xd6, 0x50, 0x52, 0xc3, 0xf3, 0x76, 0xa5, 0x32, 0xd8, 0xbb, 0xda, 0xf7, 0xc7}, - output384: []byte{0x2a, 0xd2, 0x38, 0x17, 0x0, 0x2c, 0x8f, 0x0, 0x89, 0xd4, 0x23, 0x76, 0xf, 0x55, 0x69, 0xeb, 0x67, 0xcb, 0xee, 0xd2, 0xf0, 0xf2, 0xaa, 0x12, 0xf8, 0xed, 0xe7, 0x85, 0x6e, 0xe2, 0x2a, 0xa6, 0xeb, 0x68, 0x4f, 0x86, 0xae, 0x91, 0x74, 0x1a, 0x4a, 0xa3, 0xc8, 0xa, 0xc9, 0x7c, 0x4a, 0xb}, - output512: []byte{0x28, 0x59, 0xa3, 0x16, 0x5f, 0x38, 0xcb, 0x59, 0xde, 0x42, 0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0x55, 0x15, 0x96, 0xfe, 0x4a, 0xb7, 0xcf, 0xae, 0x8f, 0xb9, 0xa9, 0xf, 0x69, 0x80, 0x48, 0xc, 0xe0, 0xc2, 0x29, 0xfd, 0x16, 0x75, 0x40, 0x9b, 0xd7, 0x88, 0x35, 0x4d, 0xaf, 0x31, 0x62, 0x40, 0xcf, 0xe0, 0xaf, 0x93, 0xeb}, - output224: []byte{0x50, 0xb7, 0xd0, 0xac, 0xb9, 0x32, 0x11, 0xe0, 0xfc, 0x93, 0x5f, 0x97, 0xb, 0xc4, 0x3a, 0x0, 0xbe, 0x82, 0x9d, 0x6b, 0x3c, 0x13, 0x7d, 0x4a, 0x7e, 0x3b, 0x2b, 0xc1}, - output256: []byte{0x82, 0xc5, 0x41, 0xea, 0x5c, 0xb1, 0x5d, 0x1a, 0x41, 0x25, 0xf5, 0x36, 0x82, 0x59, 0x38, 0xc2, 0x35, 0x8e, 0xec, 0x2b, 0xdd, 0xc5, 0xd1, 0xcc, 0x40, 0x42, 0xde, 0x3a, 0xf0, 0x36, 0xca, 0x55}, - output384: []byte{0xd3, 0x49, 0x74, 0x75, 0x9c, 0x6a, 0x4a, 0xa9, 0xd1, 0xa4, 0xed, 0x3d, 0xe3, 0x41, 0xa2, 0xba, 0x2, 0x2d, 0xf1, 0x27, 0xbe, 0x92, 0xeb, 0xb, 0xbc, 0x19, 0x0, 0xeb, 0x5a, 0xc7, 0xb8, 0xaf, 0xe9, 0x9, 0xb5, 0x2d, 0xa5, 0x71, 0x46, 0x68, 0xc3, 0xc4, 0xb7, 0xdb, 0x93, 0x9f, 0x24, 0x36}, - output512: []byte{0x92, 0x81, 0xbd, 0x3, 0xfe, 0x95, 0x54, 0x5e, 0x53, 0x21, 0xa9, 0x1a, 0xa, 0xd8, 0xfa, 0x75, 0xa0, 0x5, 0xb9, 0x28, 0xc8, 0x34, 0x50, 0xdf, 0x65, 0x74, 0x19, 0x87, 0xc, 0x4e, 0x98, 0xe, 0x32, 0x48, 0x4f,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8, 0x4e, 0x91, 0x18, 0x1a, 0xf4, 0x67, 0xbc, 0x75, 0xa9, 0xd1}, - output224: []byte{0x7c, 0xdc, 0x17, 0x82, 0xb3, 0x9f, 0xc0, 0xee, 0xb1, 0xf8, 0x74, 0xd9, 0x7c, 0x88, 0x5, 0x1c, 0xf1, 0x5, 0x8, 0xe0, 0x87, 0x5f, 0xa1, 0x73, 0xac, 0x41, 0xcc, 0x8e}, - output256: []byte{0x68, 0x4b, 0xb7, 0x93, 0x24, 0x33, 0x21, 0x8c, 0x61, 0x6f, 0x5, 0x90, 0xb0, 0x39, 0xce, 0xfa, 0xc9, 0x72, 0x82, 0x84, 0x70, 0x64, 0x7d, 0x15, 0x91, 0xce, 0xac, 0x88, 0x9c, 0x89, 0x32, 0x72}, - output384: []byte{0xf, 0xb3, 0x8a, 0xe2, 0x33, 0x52, 0xd, 0x4f, 0x57, 0x46, 0x94, 0x63, 0xe1, 0xe6, 0x8d, 0x55, 0x18, 0xea, 0x4e, 0x96, 0x57, 0x55, 0xc0, 0x3a, 0xd4, 0x58, 0xdd, 0x28, 0x5a, 0xfb, 0x2d, 0xf5, 0x18, 0xc3, 0xd3, 0x89, 0xbd, 0x36, 0x1c, 0xbd, 0xce, 0x46, 0xb6, 0x54, 0x63, 0x1a, 0x18, 0xc2}, - output512: []byte{0x6c, 0xa7, 0x2, 0x3e, 0x20, 0x73, 0x56, 0x24, 0xe8, 0x39, 0x95, 0xa9, 0xe8, 0xae, 0xba, 0x66, 0xb9, 0xbc, 0x8d, 0xa, 0x30, 0xdf, 0x67, 0x10, 0x8e, 0xff, 0x8a, 0xed, 0xeb, 0x3b, 0x3c, 0xa4, 0x84, 0x45, 0x7b, 0xd0, 0x27, 0x7c, 0x25, 0x52, 0xcb, 0xc7, 0xd6, 0x3d, 0xc8, 0x7e, 0xb5, 0x56, 0xf2, 0x19, 0x9c, 0x54, 0xea, 0x73, 0xba, 0xe6, 0x47, 0x76, 0x4d, 0xe1, 0x84, 0x89, 0xb1, 0xf1}, - }, - { - msg: []byte{0xd, 0x8d, 0x9, 0xae, 0xd1, 0x9f, 0x10, 0x13, 0x96, 0x9c, 0xe5, 0xe7, 0xeb, 0x92, 0xf8, 0x3a, 0x20, 0x9a, 0xe7, 0x6b, 0xe3, 0x1c, 0x75, 0x48, 0x44, 0xea, 0x91, 0x16, 0xce, 0xb3, 0x9a, 0x22, 0xeb, 0xb6, 0x0, 0x30, 0x17, 0xbb, 0xcf, 0x26, 0x55, 0x5f, 0xa6, 0x62, 0x41, 0x85, 0x18, 0x7d, 0xb8, 0xf0, 0xcb, 0x35, 0x64, 0xb8, 0xb1, 0xc0, 0x6b, 0xf6, 0x85, 0xd4, 0x7f, 0x32, 0x86, 0xed, 0xa2, 0xb, 0x83, 0x35, 0x8f, 0x59, 0x9d, 0x20, 0x44, 0xbb, 0xf0, 0x58, 0x3f, 0xab, 0x8d, 0x78, 0xf8, 0x54, 0xfe, 0xa, 0x59, 0x61, 0x83, 0x23, 0xc, 0x5e, 0xf8, 0xe5, 0x44, 0x26, 0x75, 0xe, 0xaf, 0x2c, 0xc4, 0xe2, 0x9d, 0x3b, 0xdd, 0x3, 0x7e, 0x73, 0x4d, 0x86, 0x3c, 0x2b, 0xd9, 0x78, 0x9b, 0x4c, 0x24, 0x30, 0x96, 0x13, 0x8f, 0x76, 0x72, 0xc2, 0x32, 0x31, 0x4e, 0xff, 0xdf, 0xc6, 0x51, 0x34, 0x27, 0xe2, 0xda, 0x76, 0x91, 0x6b, 0x52, 0x48, 0x93, 0x3b, 0xe3, 0x12, 0xeb, 0x5d, 0xde, 0x4c, 0xf7, 0x8, 0x4, 0xfb, 0x25, 0x8a, 0xc5, 0xfb, 0x82, 0xd5, 0x8d, 0x8, 0x17, 0x7a, 0xc6, 0xf4, 0x75, 0x60, 0x17, 0xff, 0xf5}, - output224: []byte{0xee, 0x5d, 0x50, 0x8a, 0x4e, 0x75, 0x90, 0x1, 0x93, 0xe9, 0x9a, 0x4, 0xb8, 0xd8, 0x38, 0xa1, 0x8d, 0xed, 0xfc, 0xc4, 0x31, 0xe7, 0xaf, 0x31, 0x82, 0xa4, 0x7d, 0xd6}, - output256: []byte{0x50, 0x8b, 0x2a, 0xf3, 0x76, 0xba, 0x64, 0x67, 0xcf, 0x98, 0x2c, 0x76, 0x7c, 0x84, 0x8d, 0x2b, 0xda, 0x8d, 0x6, 0x8a, 0x53, 0x41, 0x6f, 0x7, 0x4a, 0xc, 0x98, 0xc4, 0x73, 0xd0, 0x2f, 0x6b}, - output384: []byte{0xcb, 0x8f, 0x1c, 0xc9, 0xeb, 0x72, 0x46, 0x51, 0x76, 0xb9, 0x7b, 0x62, 0x26, 0xa8, 0x7e, 0x69, 0xd7, 0x7c, 0x65, 0x19, 0x1, 0x14, 0xcc, 0xe1, 0xf8, 0x30, 0xa3, 0xdf, 0xef, 0xa5, 0xa8, 0xa2, 0x78, 0xd5, 0xcf, 0x59, 0x4b, 0x17, 0x3a, 0xc5, 0x8c, 0x6, 0xec, 0x74, 0x95, 0x8f, 0xf8, 0xc6}, - output512: []byte{0xa9, 0x65, 0xe6, 0x99, 0xc1, 0xff, 0xae, 0xe3, 0x69, 0xb3, 0x65, 0x1c, 0x3a, 0x31, 0x85, 0x82, 0xae, 0x32, 0x9a, 0xe5, 0x1e, 0x6c, 0xcf, 0xb5, 0x27, 0x5f, 0x58, 0xf7, 0x48, 0xce, 0xdb, 0x8f, 0x6b, 0x84, 0x34, 0xfa, 0xc4, 0xa1, 0x13, 0x5a, 0xd9, 0xb5, 0x55, 0xaa, 0x8c, 0xc1, 0xff, 0x99, 0xa2, 0x22, 0xc, 0xbe, 0x83, 0xbf, 0xc1, 0xc3, 0x74, 0xff, 0xc9, 0x27, 0xbb, 0x0, 0xab, 0xd3}, - }, - { - msg: []byte{0xc3, 0x23, 0x6b, 0x73, 0xde, 0xb7, 0x66, 0x2b, 0xf3, 0xf3, 0xda, 0xa5, 0x8f, 0x13, 0x7b, 0x35, 0x8b, 0xa6, 0x10, 0x56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, 0x16, 0x42, 0xd0, 0x4, 0x37, 0x3d, 0x4e, 0x64, 0x7, 0xb7, 0x2a, 0x37, 0x38, 0x1d, 0x1b, 0xef, 0xfc, 0xbf, 0xbf, 0x9f, 0x5f, 0x6e, 0xa0, 0x93, 0xea}, - output384: []byte{0x87, 0x77, 0x6d, 0x70, 0x22, 0xdc, 0x18, 0x59, 0x2b, 0x57, 0x8c, 0x53, 0x4e, 0x2f, 0xcf, 0x57, 0x94, 0x6e, 0xf, 0x74, 0xc4, 0x7d, 0xf8, 0x56, 0x12, 0xf8, 0x9c, 0x65, 0x93, 0xfd, 0x50, 0xa9, 0xe4, 0x45, 0xc0, 0x48, 0xd6, 0xcd, 0xa9, 0xa1, 0xd1, 0xd1, 0xe, 0xa3, 0xb3, 0xc9, 0x73, 0xd0}, - output512: []byte{0x4b, 0x44, 0xec, 0x2d, 0x18, 0x48, 0xd0, 0xec, 0x43, 0xab, 0x7, 0x93, 0x39, 0xd, 0x24, 0x53, 0x5f, 0x33, 0x28, 0xad, 0x23, 0xc5, 0xf8, 0xfc, 0x43, 0xf5, 0x57, 0x9b, 0xd1, 0x6d, 0x84, 0xbb, 0xa0, 0x8b, 0x23, 0x3b, 0xb, 0x5e, 0x24, 0xe2, 0x2b, 0xf6, 0xca, 0x2d, 0xef, 0xea, 0xca, 0x16, 0xbb, 0x98, 0xf8, 0xcd, 0xea, 0xf2, 0x6e, 0xec, 0xf2, 0xfc, 0x94, 0xaf, 0xe4, 0x60, 0x4c, 0xf4}, - }, - { - msg: []byte{0xb3, 0x9f, 0xeb, 0x82, 0x83, 0xea, 0xdc, 0x63, 0xe8, 0x18, 0x4b, 0x51, 0xdf, 0x5a, 0xe3, 0xfd, 0x41, 0xaa, 0xc8, 0xa9, 0x63, 0xbb, 0xb, 0xe1, 0xcd, 0x8, 0xaa, 0x58, 0x67, 0xd8, 0xd9, 0x10, 0xc6, 0x69, 0x22, 0x1e, 0x73, 0x24, 0x33, 0x60, 0x64, 0x6f, 0x65,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xfb, 0x72, 0x90, 0x41}, - output384: []byte{0x83, 0xf4, 0x44, 0x21, 0x47, 0xfe, 0xfc, 0x8e, 0x5b, 0xad, 0x3e, 0x9e, 0xe4, 0xc6, 0x66, 0x1a, 0x77, 0x1a, 0xe8, 0xc8, 0x74, 0x58, 0xab, 0x67, 0x15, 0x3d, 0xec, 0xd3, 0x5d, 0xaf, 0x67, 0x56, 0xee, 0xf2, 0x8e, 0x4a, 0xe7, 0x2e, 0x65, 0xeb, 0xfa, 0xe0, 0x88, 0x86, 0xa6, 0xe7, 0x73, 0xe0}, - output512: []byte{0x73, 0x16, 0x9f, 0xb, 0xe2, 0x64, 0x56, 0x5e, 0x45, 0xfb, 0x8f, 0x46, 0x65, 0x75, 0x3e, 0x55, 0xf2, 0x40, 0x84, 0x6e, 0xb0, 0xd4, 0x81, 0xce, 0xf0, 0x27, 0x4e, 0x4a, 0x3d, 0x85, 0x95, 0x21, 0x76, 0x7d, 0x9f, 0x67, 0x5c, 0x6, 0x28, 0xdd, 0xce, 0x15, 0x52, 0x67, 0xba, 0x68, 0x6f, 0x21, 0x42, 0x80, 0x57, 0x13, 0xf2, 0xc, 0x4c, 0x25, 0xe0, 0xb2, 0x43, 0x98, 0xc6, 0x5e, 0x34, 0x80}, - }, - { - msg: []byte{0xa9, 0x83, 0xd5, 0x4f, 0x50, 0x38, 0x3, 0xe8, 0xc7, 0x99, 0x9f, 0x4e, 0xdb, 0xbe, 0x82, 0xe9, 0x8, 0x4f, 0x42, 0x21, 0x43, 0xa9, 0x32, 0xdd, 0xdd, 0xc4, 0x7a, 0x17, 0xb0, 0xb7, 0x56, 0x4a, 0x7f, 0x37, 0xa9, 0x9d, 0x7, 0x86, 0xe9, 0x94, 0x76, 0x42, 0x8d, 0x29, 0xe2, 0x9d, 0x3c, 0x19, 0x7a, 0x72, 0xbf, 0xab, 0x13, 0x42, 0xc1, 0x2a, 0xf, 0xc4, 0x78, 0x7f, 0xd7, 0x1, 0x7d, 0x7a, 0x61, 0x74, 0x4, 0x9e, 0xa4, 0x3b, 0x57, 0x79, 0x16, 0x9e, 0xf7, 0x47, 0x2b, 0xdb, 0xbd, 0x94, 0x1d, 0xcb, 0x82, 0xfc, 0x73, 0xaa, 0xc4, 0x5a, 0x8a, 0x94, 0xc9, 0xf2, 0xbd, 0x34, 0x77, 0xf6, 0x1f, 0xd3, 0xb7, 0x96, 0xf0, 0x2a, 0x1b, 0x82, 0x64, 0xa2, 0x14, 0xc6, 0xfe, 0xa7, 0x4b, 0x70, 0x51, 0xb2, 0x26, 0xc7, 0x22, 0x9, 0x9e, 0xc7, 0x88, 0x3a, 0x46, 0x2b, 0x83, 0xb6, 0xaf, 0xdd, 0x40, 0x9, 0x24, 0x8b, 0x8a, 0x23, 0x7f, 0x60, 0x5f, 0xe5, 0xa0, 0x8f, 0xe7, 0xd8, 0xb4, 0x53, 0x21, 0x42, 0x1e, 0xbb, 0xa6, 0x7b, 0xd7, 0xa, 0xb, 0x0, 0xdd, 0xbf, 0x94, 0xba, 0xab, 0x7f, 0x35, 0x9d, 0x5d, 0x1e, 0xea, 0x10, 0x5f, 0x28, 0xdc, 0xfb}, - output224: []byte{0x9a, 0xf1, 0x78, 0xb1, 0xdd, 0x3c, 0xef, 0xc9, 0x62, 0x27, 0xa2, 0x89, 0x17, 0x5b, 0xb6, 0x1d, 0x9f, 0x6b, 0xb, 0x35, 0x2d, 0x78, 0x4, 0xf5, 0xe0, 0x7e, 0xa4, 0x5d}, - output256: []byte{0xdc, 0xbc, 0x25, 0x82, 0x41, 0xad, 0xed, 0x37, 0x99, 0x99, 0x6c, 0x2a, 0xd6, 0xed, 0xe, 0x3d, 0x74, 0xcf, 0xcc, 0x67, 0x74, 0x9d, 0x34, 0x80, 0xb2, 0xa9, 0xa7, 0x8e, 0x5f, 0x8a, 0xff, 0x82}, - output384: []byte{0x51, 0x35, 0x81, 0x59, 0x7, 0x4d, 0x96, 0xc, 0xb, 0x9d, 0x73, 0xd5, 0xf1, 0x2a, 0xfd,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x8, 0x35, 0x9d, 0x36, 0x13, 0x84, 0x4d, 0x5e, 0xb3, 0x93, 0x0, 0x2, 0x83, 0xd5, 0xad, 0x34, 0x1, 0xa3, 0x18, 0xb1, 0x2f, 0xd1, 0x47, 0x4b, 0x86, 0x12, 0xf2, 0xbb, 0x50, 0xfb, 0x6a, 0x8b, 0x9e, 0x2, 0x3a, 0x54, 0xd7, 0xdd, 0xe2, 0x8c, 0x43, 0xd6, 0xd8, 0x85, 0x4c, 0x8d, 0x9d, 0x11, 0x55, 0x93, 0x5c, 0x19, 0x98, 0x11, 0xdb, 0xfc, 0x87, 0xe9, 0xe0, 0x7, 0x2e, 0x90, 0xeb, 0x88, 0x68, 0x1c, 0xc7, 0x52, 0x97, 0x14, 0xf8, 0xfb, 0x8a, 0x2c, 0x9d, 0x88, 0x56, 0x7a, 0xdf, 0xb9, 0x74, 0xee, 0x20, 0x5a, 0x9b, 0xf7, 0xb8, 0x48}, - output224: []byte{0xf5, 0x43, 0xb4, 0xd4, 0x23, 0xea, 0xac, 0x86, 0x33, 0x8b, 0xb6, 0xd8, 0xc6, 0x18, 0x1a, 0xd6, 0xdc, 0xa, 0x25, 0x73, 0x39, 0x53, 0xce, 0xd7, 0xeb, 0x83, 0x77, 0xf3}, - output256: []byte{0xcb, 0xe8, 0x31, 0x8e, 0x7b, 0x2f, 0xe7, 0x2b, 0xfc, 0xd2, 0x53, 0xc, 0xcc, 0xec, 0xea, 0x40, 0x18, 0xb1, 0x58, 0x7f, 0x48, 0x3b, 0x73, 0xf5, 0xc, 0xe5, 0xe8, 0x4c, 0xed, 0x65, 0xe0, 0x93}, - output384: []byte{0x3e, 0xce, 0xa8, 0xca, 0xf0, 0xd8, 0xef, 0xa4, 0x2d, 0x54, 0xac, 0x5e, 0xf3, 0x6e, 0x62, 0x42, 0x37, 0xd9, 0xf5, 0x50, 0x8e, 0xd6, 0xfc, 0xb6, 0x43, 0x4d, 0x67, 0xf3, 0xfb, 0x78, 0x8c, 0x53, 0x8c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, 0xa8, 0xd7, 0x21, 0x55, 0xed, 0x55, 0x1a, 0x1f, 0x87, 0xc8, 0xb, 0xf6, 0x5, 0x9b, 0x43, 0xfc, 0x76, 0x49, 0x0, 0xb1, 0x8a, 0x1c, 0x24, 0x41, 0xf7, 0x48, 0x77, 0x43, 0xcf, 0x84, 0xe5, 0x65, 0xf6, 0x1f, 0x8d, 0xd2, 0xec, 0xe6, 0xb6, 0xcc, 0xc9, 0x44, 0x40, 0x49, 0x19, 0x7a, 0xaa, 0xf5, 0x3e, 0x92, 0x6f, 0xbe, 0xe3, 0xbf, 0xca, 0x8b, 0xe5, 0x88, 0xec, 0x77, 0xf2, 0x9d, 0x21, 0x1b, 0xe8, 0x9d, 0xe1, 0x8b, 0x15, 0xf6}, - output224: []byte{0x77, 0xb4, 0x7, 0x9e, 0xee, 0x9d, 0x9e, 0x3f, 0xda, 0x5, 0x1e, 0xe0, 0xca, 0x43, 0xb, 0x4d, 0xf0, 0x11, 0xd0, 0x56, 0x61, 0x2c, 0x1a, 0xf4, 0x46, 0xa1, 0x87, 0xc2}, - output256: []byte{0x8c, 0xea, 0x29, 0x60, 0x8, 0x70, 0x48, 0xe6, 0xe6, 0xd4, 0x7e, 0x31, 0x55, 0x4f, 0x30, 0x5f, 0xcc, 0x81, 0xe0, 0x3e, 0x90, 0xba, 0x8f, 0x83, 0x32, 0xdd, 0x86, 0xc6, 0xb6, 0xb3, 0x8e, 0x3}, - output384: []byte{0xa8, 0x87, 0x6f, 0xe4, 0x65, 0x2a, 0xcf, 0x72, 0xdc, 0xc8, 0xfd, 0x51, 0x33, 0xe5, 0xd4, 0xca, 0x4e, 0x37, 0x66, 0xab, 0x98, 0x7c, 0xf6, 0x6e, 0xae, 0x5e, 0x37, 0x70, 0xe2, 0x52, 0xd2, 0xfd, 0x2a, 0x89, 0x5, 0x25, 0x1, 0x66, 0x23, 0xee, 0x69, 0x6, 0x46, 0x90, 0x82, 0x8c, 0x72, 0x7b}, - output512: []byte{0x70, 0x1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x4a, 0x2, 0x55, 0xb4, 0xd2, 0x31, 0xc0, 0xbe, 0x50, 0xf4, 0x4f, 0xd, 0xb0, 0xb7, 0x13, 0xaf, 0x3, 0xd9, 0x68, 0xfe, 0x7f, 0xf, 0x61, 0xed, 0x8, 0x24, 0xc5, 0x5c, 0x4b, 0x52, 0x65, 0x54, 0x8f, 0xeb, 0xd6, 0xaa, 0xd5, 0xc5, 0xee, 0xdf, 0x63, 0xef, 0xe7, 0x93, 0x48, 0x9c, 0x39, 0xb8, 0xfd, 0x29, 0xd1, 0x4, 0xce}, - output224: []byte{0x98, 0x7d, 0x30, 0x12, 0xc, 0x9a, 0xa4, 0x96, 0x46, 0x50, 0xa6, 0xa7, 0x30, 0xe9, 0x9c, 0x86, 0xf7, 0xfb, 0xdd, 0xb4, 0xea, 0x8d, 0x6b, 0x48, 0x15, 0xee, 0x4e, 0xbf}, - output256: []byte{0x44, 0xe2, 0x76, 0x99, 0x1e, 0x53, 0x82, 0xbd, 0x7e, 0xb5, 0xad, 0xcf, 0x1f, 0x79, 0x36, 0x28, 0x4, 0xd3, 0x46, 0xbe, 0xdf, 0xc6, 0x91, 0x6f, 0x4d, 0xca, 0x4b, 0x57, 0x24, 0xe, 0x9c, 0x99}, - output384: []byte{0x6a, 0x9, 0x73, 0x57, 0x36, 0x78, 0xf, 0x19, 0x9d, 0x75, 0xc6, 0x9, 0x3, 0xaa, 0x24, 0xd7, 0xf8, 0xaa, 0x17, 0x51, 0x66, 0x90, 0x85, 0x4f, 0x75, 0x22, 0xef, 0xb, 0xbf, 0x47, 0xd4, 0x1c, 0xbd, 0xc8, 0xbd, 0xb2, 0xcb, 0x2f, 0x3c, 0x55, 0x96, 0x51, 0x5, 0x39, 0x67, 0x76, 0x7, 0xe9}, - output512: []byte{0x90, 0x1c, 0x6d, 0x85, 0x50, 0x9f, 0x1, 0xa4, 0x7e, 0xa2, 0xe2, 0x79, 0x2a, 0x5d, 0xb7, 0x28, 0xea, 0x39, 0xe5, 0x70, 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, 0x2d, 0x1e, 0xb3, 0x8b, 0x5d, 0x53, 0x6b, 0x94, 0x73, 0x48, 0xa4, 0x58, 0xed, 0xe3, 0xdc, 0x6b, 0xd6, 0xec, 0x54, 0x7b, 0x1b, 0xc, 0xae, 0x5b, 0x25, 0x7b, 0xe3, 0x6a, 0x71, 0x24, 0xe1, 0x6, 0xc, 0x17, 0xf, 0xfa}, - output224: []byte{0x46, 0x19, 0x33, 0x59, 0x39, 0x7b, 0xc3, 0xea, 0xcd, 0x69, 0xbf, 0xf4, 0x10, 0x20, 0x35, 0x83, 0x38, 0x2d, 0xe9, 0x3e, 0xcc, 0x4d, 0x80, 0xdc, 0xfb, 0x4f, 0xc5, 0x1d}, - output256: []byte{0x80, 0x89, 0x1a, 0x8, 0x6a, 0xf3, 0x85, 0x2, 0x50, 0x68, 0x79, 0x9f, 0x19, 0x24, 0x11, 0xc6, 0x89, 0xcc, 0x4e, 0xd, 0x9a, 0x59, 0xf3, 0xf4, 0x1d, 0xbb, 0x2, 0xa3, 0x43, 0xf1, 0xa7, 0x59}, - output384: []byte{0x83, 0xfc, 0x2b, 0x91, 0xab, 0x81, 0xd4, 0xb1, 0x53, 0x63, 0xf1, 0x5e, 0x53, 0xbf, 0x63, 0x90, 0x63, 0xba, 0xc5, 0x55, 0x2, 0xb4, 0x42, 0x1c, 0xf9, 0xa5, 0x3b, 0xca, 0xb9, 0xff, 0x47, 0xfd, 0x77, 0xde, 0x5a, 0xc6, 0x93, 0x4f, 0x67, 0xa4, 0x12, 0xea, 0x19, 0x10, 0xfa, 0xd6, 0x77, 0x68}, - output512: []byte{0x4c, 0xc9, 0xa6, 0x1f, 0xfe, 0x8, 0x98, 0x44, 0x17, 0x71, 0x2b, 0x80, 0xf9, 0x62, 0x36, 0x5a, 0xf3, 0x6e, 0xd6, 0x6a, 0x8a, 0xab, 0x2a, 0x78, 0x8d, 0x22, 0xa5, 0xc6, 0xb2, 0x39, 0x62, 0xd2, 0x35, 0x84, 0x63, 0x8e, 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, 0x6a, 0x6b, 0x17, 0xa6, 0xd0, 0x48, 0xa, 0xb7, 0x9d, 0x4e, 0x64, 0x15, 0xb5, 0x20, 0xf1, 0xc4, 0x84, 0xd6, 0x75, 0xb1}, - output224: []byte{0xb, 0xc2, 0x91, 0x7, 0xc7, 0xe2, 0x5d, 0x44, 0xf8, 0xce, 0x83, 0xa4, 0x15, 0xb1, 0xde, 0x5d, 0xf3, 0x8a, 0x67, 0x19, 0x76, 0x96, 0x6, 0x76, 0x2b, 0x71, 0x92, 0xc2}, - output256: []byte{0x77, 0xdd, 0xf0, 0x34, 0xb7, 0xdf, 0xd6, 0xb2, 0x92, 0xaa, 0x3b, 0xc, 0x1e, 0x55, 0x2f, 0x47, 0xb1, 0xd8, 0xc2, 0x30, 0x78, 0x4, 0x2c, 0xc5, 0x8b, 0xb3, 0xdd, 0x47, 0x20, 0xb9, 0xee, 0x4d}, - output384: []byte{0x77, 0xc0, 0x48, 0xb, 0x91, 0xf3, 0x2e, 0xf8, 0x9, 0xd8, 0xc2, 0x3a, 0xb2, 0x36, 0x58, 0x1f, 0xb, 0xca, 0x8b, 0x94, 0x47, 0xa4, 0xd3, 0x62, 0x28, 0x5, 0x2b, 0x3a, 0xbb, 0x6a, 0xb6, 0x9c, 0x61, 0xd1, 0x9d, 0x72, 0x4, 0x86, 0xa3, 0xff, 0x49, 0x7a, 0x46, 0x73, 0xb8, 0x4c, 0xb9, 0x51}, - output512: []byte{0xb3, 0x6e, 0xa5, 0x6b, 0xb6, 0xbf, 0x80, 0xd9, 0x1d, 0x5a, 0x60, 0x5f, 0x84, 0x9, 0xae, 0x6b, 0x7d, 0x87, 0x9e, 0xc4, 0x8, 0x15, 0xb3, 0x5c, 0x66, 0x4c, 0xc6, 0xb0, 0x1b, 0xf6, 0xc7, 0x18, 0xad, 0x46, 0x4f, 0x15, 0xc3, 0x4d, 0xd1, 0x31, 0x5a, 0x79, 0xa5, 0x45, 0x6b, 0x6c, 0x3f, 0x8e, 0xd8, 0x9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0x89, 0x70, 0xd2, 0x98, 0x77, 0x60, 0x60}, - output224: []byte{0xb4, 0x85, 0x64, 0x4c, 0x32, 0x28, 0x3b, 0x28, 0x1, 0x79, 0xf7, 0xc9, 0x71, 0x43, 0x50, 0xf0, 0xb3, 0xac, 0xfd, 0x7c, 0x45, 0xa2, 0x47, 0xbf, 0x3b, 0x6c, 0xdb, 0x7}, - output256: []byte{0x23, 0xd2, 0x68, 0x8d, 0x86, 0x7a, 0x18, 0x4, 0xe, 0x82, 0xf7, 0x87, 0x6a, 0xcf, 0x4, 0xdc, 0x3a, 0x9c, 0x1, 0x40, 0xfe, 0xdd, 0x93, 0xeb, 0xe7, 0xad, 0xf9, 0x20, 0xb2, 0xf8, 0x3d, 0xa4}, - output384: []byte{0x78, 0x14, 0x66, 0xe2, 0x57, 0xd2, 0xfa, 0x59, 0x4e, 0x39, 0xdc, 0x22, 0xa, 0x26, 0xc, 0x74, 0x78, 0xd2, 0x15, 0x8b, 0xb7, 0xe, 0x42, 0x6f, 0x9e, 0x95, 0x87, 0xf5, 0xa5, 0x1a, 0x7c, 0x29, 0xfd, 0xc7, 0xaf, 0x23, 0xe7, 0xab, 0x9c, 0x77, 0x4e, 0x33, 0xc0, 0x8a, 0xb3, 0x8c, 0xed, 0xb7}, - output512: []byte{0x8e, 0xcb, 0x8f, 0x62, 0x2d, 0xab, 0x70, 0x87, 0xe9, 0xa9, 0x5c, 0xd0, 0x34, 0x11, 0x92, 0xfe, 0xa6, 0xb1, 0xc9, 0x56, 0xdf, 0x9a, 0xd3, 0xde, 0xd8, 0x23, 0x94, 0x8b, 0x78, 0x49, 0xc4, 0xf3, 0x15, 0xc, 0x95, 0x59, 0x52, 0x9, 0x53, 0xeb, 0xde, 0x98, 0xed, 0x76, 0xf6, 0xe4, 0x3b, 0xfe, 0x4f, 0xb2, 0x5f, 0xda, 0x71, 0x25, 0x25, 0xc6, 0xd3, 0xda, 0xa8, 0x3, 0x23, 0xbe, 0x8e, 0x4a}, - }, - { -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 0xef, 0xd2, 0x33, 0x81, 0xde, 0xbc, 0xd9, 0x12, 0x4c, 0x53, 0x9c, 0x40, 0xbf, 0xa7, 0xe, 0x51, 0x72, 0x80, 0xf5, 0x6a, 0x9, 0x20, 0xe1}, - output256: []byte{0x2d, 0xf6, 0x66, 0xfc, 0x5d, 0x4e, 0xad, 0x1c, 0x3b, 0x10, 0xb9, 0xf8, 0xd4, 0xbb, 0x81, 0xae, 0xa4, 0xf9, 0x3d, 0x38, 0x73, 0xd5, 0xce, 0x5c, 0xfb, 0xac, 0x4b, 0x69, 0x43, 0x5e, 0x1b, 0x7c}, - output384: []byte{0x51, 0xbe, 0xbf, 0xb5, 0xaa, 0xfe, 0x77, 0x7f, 0x39, 0xe, 0x28, 0x51, 0xb7, 0xeb, 0x9a, 0xa3, 0x80, 0x91, 0x94, 0xfe, 0x3b, 0xa1, 0x68, 0x9a, 0xbe, 0xe7, 0xe4, 0x3d, 0x44, 0xa5, 0x87, 0x4e, 0xc, 0x25, 0x27, 0x93, 0xdf, 0xd4, 0x2c, 0x12, 0x70, 0xc6, 0x3c, 0x40, 0x7a, 0xef, 0x67, 0x80}, - output512: []byte{0x51, 0x92, 0x15, 0xda, 0x34, 0xac, 0xfc, 0xd6, 0x2d, 0xd6, 0x17, 0xec, 0xd5, 0x97, 0x83, 0x65, 0x41, 0x7d, 0x57, 0xc2, 0x67, 0x1a, 0x7b, 0x48, 0x65, 0x5b, 0x89, 0xf4, 0x48, 0xb2, 0x3b, 0x12, 0x8d, 0x3a, 0xd0, 0x49, 0x10, 0xa1, 0xbb, 0xbd, 0xc0, 0xe, 0x95, 0x4a, 0x1e, 0x49, 0x76, 0x51, 0x76, 0xa8, 0xac, 0xa4, 0xc3, 0x7d, 0x56, 0xab, 0xf0, 0xe0, 0xb7, 0x2e, 0x33, 0x1a, 0x8d, 0x7c}, - }, - { - msg: []byte{0xf1, 0xc5, 0x28, 0xcf, 0x77, 0x39, 0x87, 0x47, 0x7, 0xd4, 0xd8, 0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 0xe4, 0xa8, 0x97, 0x73, 0x8f, 0x8d, 0x81, 0xb1, 0x27, 0x8b, 0xc4, 0x48}, - output256: []byte{0xaf, 0xc, 0x54, 0x74, 0x52, 0x80, 0x32, 0xe2, 0x62, 0x9b, 0x8f, 0xbb, 0xe, 0x34, 0x40, 0x5f, 0x7f, 0x25, 0x1d, 0x41, 0xe7, 0x3b, 0x56, 0x67, 0xbe, 0x3c, 0x7, 0xcc, 0xb2, 0xc1, 0xc9, 0x53}, - output384: []byte{0xfc, 0xdf, 0x0, 0x32, 0xf3, 0x4b, 0xa6, 0xc4, 0x2d, 0x67, 0x9b, 0x18, 0x2d, 0x7, 0xb1, 0xf, 0x4d, 0xff, 0x21, 0x89, 0xb0, 0xa5, 0xef, 0x66, 0x42, 0xfb, 0xb7, 0x1b, 0x16, 0xf9, 0x10, 0xe3, 0x24, 0xe, 0xd9, 0xb5, 0x2, 0xb1, 0xc6, 0xb3, 0x95, 0xbe, 0xe7, 0x4a, 0xd0, 0xfb, 0x41, 0x91}, - output512: []byte{0xd, 0x1c, 0x1a, 0xd4, 0xe1, 0xcf, 0xef, 0xee, 0x85, 0x4c, 0x4a, 0x73, 0x9a, 0x3, 0x42, 0xe3, 0x9d, 0x70, 0xd, 0xba, 0xf4, 0x89, 0x19, 0x78, 0xd7, 0xc8, 0x39, 0xe8, 0x7c, 0x68, 0x7, 0x17, 0xd6, 0x3a, 0xb4, 0xaa, 0x1e, 0xd7, 0xeb, 0x65, 0x7c, 0xed, 0x9f, 0x8d, 0x2c, 0xf4, 0x72, 0x4, 0x26, 0x2e, 0x60, 0x96, 0x10, 0x84, 0x2f, 0xc5, 0xb2, 0x19, 0xac, 0xff, 0x7e, 0xb1, 0x88, 0xc4}, - }, - { - msg: []byte{0x9d, 0x9f, 0x3a, 0x7e, 0xcd, 0x51, 0xb4, 0x1f, 0x65, 0x72, 0xfd, 0xd, 0x8, 0x81, 0xe3, 0x3, 0x90, 0xdf, 0xb7, 0x80, 0x99, 0x1d,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47}, - output256: []byte{0x9b, 0xbe, 0xf7, 0xa7, 0x53, 0x91, 0x35, 0x4a, 0x38, 0x8a, 0xaa, 0x7c, 0xa0, 0x35, 0xdc, 0x62, 0xd3, 0x23, 0x1b, 0x80, 0x9, 0x1b, 0xb7, 0x74, 0x8f, 0x76, 0xe5, 0x2d, 0x8e, 0x9f, 0x20, 0xf0}, - output384: []byte{0x92, 0xaa, 0xdc, 0x2, 0xbb, 0x97, 0x95, 0xa4, 0x8b, 0x3, 0x10, 0x34, 0xee, 0x6a, 0xb8, 0x73, 0xdf, 0x48, 0x1d, 0x23, 0x29, 0x32, 0xfb, 0x5f, 0xd6, 0xc3, 0x76, 0x2e, 0x50, 0xe5, 0x8d, 0xa4, 0x6d, 0x1f, 0x5e, 0x5e, 0x87, 0x45, 0x97, 0xf1, 0x5c, 0x83, 0x12, 0x7f, 0xa, 0x30, 0x42, 0xb1}, - output512: []byte{0xa, 0x5d, 0x9e, 0xf4, 0xb, 0xa2, 0xb9, 0x8e, 0xdb, 0xd7, 0x91, 0x8c, 0xc6, 0x77, 0x94, 0x83, 0xa1, 0xa0, 0xb, 0xd9, 0x4c, 0xc1, 0xe1, 0x49, 0x54, 0x95, 0xca, 0xf6, 0xcd, 0x47, 0xc6, 0x23, 0x95, 0x71, 0xc3, 0x82, 0x8f, 0x45, 0x65, 0xa0, 0xd5, 0x37, 0x86, 0x78, 0x1d, 0x71, 0x2c, 0x10, 0xef, 0x73, 0x33, 0x22, 0x7f, 0x65, 0x19, 0x74, 0x62, 0x88, 0x87, 0xd4, 0x42, 0xa5, 0xef, 0x9d}, - }, - { - msg: []byte{0x51, 0x79, 0x88, 0x87, 0x24, 0x81, 0x9f, 0xba, 0xd3, 0xaf, 0xa9, 0x27, 0xd3, 0x57, 0x77, 0x96, 0x66, 0xe, 0x6a, 0x81, 0xc5, 0x2d, 0x98, 0xe9, 0x30, 0x32, 0x61, 0xd5, 0xa4, 0xa8, 0x32, 0x32, 0xf6, 0xf7, 0x58, 0x93, 0x4d, 0x50, 0xaa, 0x83, 0xff, 0x9e, 0x20, 0xa5, 0x92, 0x6d, 0xfe, 0xba, 0xac, 0x49, 0x52, 0x9d, 0x0, 0x6e, 0xb9, 0x23, 0xc5, 0xae, 0x50, 0x48, 0xed, 0x54, 0x4e, 0xc4, 0x71, 0xed, 0x71, 0x91, 0xed, 0xf4, 0x63, 0x63, 0x38, 0x38, 0x24, 0xf9, 0x15, 0x76, 0x9b, 0x3e, 0x68, 0x80, 0x94, 0xc6, 0x82, 0xb0, 0x21, 0x51, 0xe5, 0xee, 0x1, 0xe5, 0x10, 0xb4, 0x31, 0xc8, 0x86, 0x5a, 0xff, 0x8b, 0x6b, 0x6f, 0x2f, 0x59, 0xcb, 0x6d, 0x12, 0x9d, 0xa7, 0x9e, 0x97, 0xc6, 0xd2, 0xb8, 0xfa, 0x6c, 0x6d, 0xa3, 0xf6, 0x3, 0x19, 0x9d, 0x2d, 0x1b, 0xca, 0xb5, 0x47, 0x68, 0x2a, 0x81, 0xcd, 0x6c, 0xf6, 0x5f, 0x65, 0x51, 0x12, 0x13, 0x91, 0xd7, 0x8b, 0xcc, 0x23, 0xb5, 0xbd, 0xe, 0x92, 0x2e, 0xc6, 0xd8, 0xbf, 0x97, 0xc9, 0x52, 0xe8, 0x4d, 0xd2, 0x8a, 0xef, 0x90, 0x9a, 0xba, 0x31, 0xed, 0xb9, 0x3, 0xb2, 0x8f, 0xbf, 0xc3, 0x3b, 0x77, 0x3, 0xcd, 0x99, 0x62, 0x15, 0xa1, 0x12, 0x38}, - output224: []byte{0x68, 0x65, 0x46, 0x4c, 0x6a, 0x23, 0xb, 0x4b, 0xf6, 0x4b, 0xa3, 0x3b, 0xf9, 0x74, 0x59, 0xd1, 0xd2, 0x2d, 0xaf, 0xb1, 0x9e, 0x8, 0xf4, 0xb7, 0xda, 0xce, 0x2, 0xff}, - output256: []byte{0xb1, 0x8, 0x45, 0x7a, 0x6b, 0xd3, 0x31, 0xbe, 0x43, 0xc9, 0xfe, 0x1e, 0x2a, 0x2, 0xe8, 0xc7, 0x44, 0xc2, 0xbc, 0xc9, 0x27, 0xa9, 0xc3, 0xc4, 0x86, 0xf1, 0x10, 0xdc, 0xcf, 0x90, 0x7f, 0x6b}, - output384: []byte{0xd, 0xc, 0xcd, 0xbf, 0xeb, 0xa, 0x93, 0x3f, 0x21, 0x1e, 0xaa, 0x94, 0xeb, 0x45, 0x29, 0x0, 0x32, 0x43, 0x40, 0x50, 0x5c, 0xcf, 0x8d, 0xb7, 0xad, 0x93, 0xe9, 0x76, 0x27, 0x1f, 0x81, 0x2f, 0xb8, 0x90, 0x78, 0x5, 0xf6, 0x31, 0x3d, 0xb, 0x9, 0x31, 0xf5, 0xc9, 0x20, 0x3b, 0xdb, 0xa5}, - output512: []byte{0xea, 0x83, 0xde, 0x9a, 0xe0, 0x57, 0x70, 0x1f, 0x6e, 0xc6, 0x8f, 0xf6, 0x7e, 0x92, 0xe0, 0x33, 0x4c, 0x18, 0xeb, 0xb7, 0x9a, 0xf1, 0x95, 0x3c, 0x25, 0x14, 0x40, 0x8d, 0x58, 0xe6, 0x9f, 0x10, 0x54, 0x41, 0x64, 0x2a, 0x1d, 0x5b, 0x7d, 0x60, 0x10, 0xf7, 0xcb, 0x15, 0xd1, 0x31, 0xdd, 0x53, 0x18, 0x55, 0xca, 0x33, 0x7a, 0x7b, 0xb, 0x79, 0x4f, 0xa6, 0xd6, 0x92, 0x3f, 0x1, 0x7a, 0xfa}, - }, - { - msg: []byte{0x57, 0x6e, 0xf3, 0x52, 0xd, 0x30, 0xb7, 0xa4, 0x89, 0x9b, 0x8c, 0xd, 0x5e, 0x35, 0x9e, 0x45, 0xc5, 0x18, 0x9a, 0xdd, 0x10, 0xe, 0x43, 0xbe, 0x42, 0x9a, 0x2, 0xfb, 0x3d, 0xe5, 0xff, 0x4f, 0x8f, 0xd0, 0xe7, 0x9d, 0x96, 0x63, 0xac, 0xca, 0x72, 0xcd, 0x29, 0xc9, 0x45, 0x82, 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 0x6b, 0x62, 0x28, 0xeb, 0xd9, 0x10, 0x25, 0x1, 0x2a, 0xf4, 0xcc, 0xe, 0xb4, 0x9}, - output384: []byte{0xfe, 0xf6, 0xb1, 0xf2, 0x7b, 0xc, 0xeb, 0xc4, 0x56, 0x85, 0x88, 0xe6, 0x27, 0xd2, 0x8d, 0xd5, 0x69, 0xa5, 0x8a, 0x8f, 0x9a, 0x51, 0xa1, 0xd2, 0x88, 0x7b, 0x40, 0xf5, 0x54, 0x7b, 0x2c, 0x67, 0xc7, 0x19, 0x17, 0xbe, 0x99, 0x8d, 0x19, 0x87, 0xac, 0x78, 0xe9, 0x7, 0x7c, 0xc7, 0x90, 0xab}, - output512: []byte{0x66, 0x51, 0xc2, 0x5d, 0x33, 0xd1, 0xb, 0x72, 0x53, 0x5f, 0x1d, 0xb2, 0x6a, 0x1d, 0xfe, 0x2e, 0xb9, 0x9c, 0xdd, 0x50, 0x54, 0x48, 0x1, 0x85, 0x89, 0xb5, 0xb8, 0x8b, 0x7c, 0xab, 0x63, 0xeb, 0x43, 0x9c, 0x31, 0xa4, 0x74, 0xc6, 0xf1, 0x19, 0x1d, 0xf1, 0x4e, 0xfc, 0x7d, 0x6, 0x65, 0xcc, 0x7b, 0x82, 0xa7, 0xdc, 0x54, 0xa7, 0xc6, 0xb0, 0xc2, 0xfd, 0x1f, 0x75, 0xc3, 0xd, 0x68, 0x72}, - }, - { - msg: []byte{0xd, 0xf2, 0x15, 0x2f, 0xa4, 0xf4, 0x35, 0x7c, 0x87, 0x41, 0x52, 0x9d, 0xd7, 0x7e, 0x78, 0x39, 0x25, 0xd3, 0xd7, 0x6e, 0x95, 0xba, 0xfa, 0x2b, 0x54, 0x2a, 0x2c, 0x33, 0xf3, 0xd1, 0xd1, 0x17, 0xd1, 0x59, 0xcf, 0x47, 0x3f, 0x82, 0x31, 0x3, 0x56, 0xfe, 0xe4, 0xc9, 0xa, 0x9e, 0x50, 0x5e, 0x70, 0xf8, 0xf2, 0x48, 0x59, 0x65, 0x63, 0x68, 0xba, 0x9, 0x38, 0x1f, 0xa2, 0x45, 0xeb, 0x6c, 0x3d, 0x76, 0x3f, 0x30, 0x93, 0xf0, 0xc8, 0x9b, 0x97, 0x2e, 0x66, 0xb5, 0x3d, 0x59, 0x40, 0x6d, 0x9f, 0x1, 0xae, 0xa0, 0x7f, 0x8b, 0x3b, 0x61, 0x5c, 0xac, 0x4e, 0xe4, 0xd0, 0x5f, 0x54, 0x2e, 0x7d, 0xd, 0xab, 0x45, 0xd6, 0x7c, 0xcc, 0xcd, 0x3a, 0x60, 0x6c, 0xcb, 0xeb, 0x31, 0xea, 0x1f, 0xa7, 0x0, 0x5b, 0xa0, 0x71, 0x76, 0xe6, 0xd, 0xab, 0x7d, 0x78, 0xf6, 0x81, 0xe, 0xf0, 0x86, 0xf4, 0x2f, 0x8, 0xe5, 0x95, 0xf0, 0xec, 0x21, 0x73, 0x72, 0xb9, 0x89, 0x70, 0xcc, 0x63, 0x21, 0x57, 0x6d, 0x92, 0xce, 0x38, 0xf7, 0xc3, 0x97, 0xa4, 0x3, 0xba, 0xda, 0x15, 0x48, 0xd2, 0x5, 0xc3, 0x43, 0xac, 0x9, 0xde, 0xca, 0x86, 0x32, 0x53, 0x73, 0xc3, 0xb7, 0x6d, 0x9f, 0x32, 0x2, 0x8f, 0xea, 0x8e, 0xb3, 0x25, 0x15}, - output224: []byte{0xe4, 0x38, 0xae, 0x41, 0x53, 0x46, 0x3b, 0x33, 0x3a, 0xe4, 0xfe, 0x57, 0xbf, 0x13, 0x15, 0x5, 0xc8, 0xc0, 0x4a, 0x53, 0x4a, 0x39, 0xa2, 0x5, 0x74, 0x15, 0x5e, 0x49}, - output256: []byte{0x4f, 0xf, 0x30, 0xc8, 0x90, 0xb0, 0xab, 0x40, 0x49, 0x61, 0x15, 0x85, 0x73, 0x53, 0x8f, 0xe9, 0xa2, 0xb2, 0x34, 0xb9, 0x4a, 0x9, 0x91, 0xf2, 0x6d, 0x5e, 0xa0, 0x4f, 0xdd, 0xc9, 0xc5, 0x65}, - output384: []byte{0xe9, 0x95, 0x77, 0x32, 0xe7, 0xda, 0xb6, 0x45, 0x50, 0xf0, 0x3, 0xee, 0x6d, 0x3, 0x53, 0xae, 0x89, 0xbd, 0xc6, 0xd6, 0x9d, 0x5, 0x76, 0x60, 0x24, 0xcf, 0xf1, 0x89, 0xe4, 0xfc, 0x8f, 0xaa, 0x41, 0xdb, 0x72, 0x95, 0x4e, 0x8e, 0x5a, 0xc0, 0xb2, 0x92, 0x65, 0xc8, 0xf7, 0x85, 0xe7, 0x37}, - output512: []byte{0xa7, 0x54, 0x65, 0x22, 0x47, 0xf7, 0x28, 0x5c, 0xe2, 0xdd, 0x8a, 0x10, 0x3, 0x5c, 0x69, 0x96, 0x1e, 0x4f, 0x9c, 0x2, 0x5e, 0x1f, 0xd0, 0x87, 0xcb, 0xd3, 0x12, 0x6e, 0x4, 0x9a, 0x9e, 0x83, 0x2c, 0x3f, 0x3a, 0x49, 0x1f, 0xcd, 0xe3, 0x38, 0xb8, 0xc0, 0x19, 0x46, 0xcd, 0xd7, 0xde, 0xc3, 0x2a, 0x8f, 0xd7, 0xed, 0x1c, 0xb3, 0x4, 0x5b, 0xca, 0xf3, 0x39, 0x89, 0x5, 0xb1, 0xbb, 0x42}, - }, - { - msg: []byte{0x3e, 0x15, 0x35, 0xd, 0x87, 0xd6, 0xeb, 0xb5, 0xc8, 0xad, 0x99, 0xd4, 0x25, 0x15, 0xcf, 0xe1, 0x79, 0x80, 0x93, 0x3c, 0x7a, 0x8f, 0x6b, 0x8b, 0xbb, 0xf0, 0xa6, 0x37, 0x28, 0xce, 0xfa, 0xad, 0x20, 0x52, 0x62, 0x3c, 0xb, 0xd5, 0x93, 0x18, 0x39, 0x11, 0x2a, 0x48, 0x63, 0x3f, 0xb3, 0xc2, 0x0, 0x4e, 0x7, 0x49, 0xc8, 0x7a, 0x41, 0xb2, 0x6a, 0x8b, 0x48, 0x94, 0x55, 0x39, 0xd1, 0xff, 0x41, 0xa4, 0xb2, 0x69, 0x46, 0x2f, 0xd1, 0x99, 0xbf, 0xec, 0xd4, 0x53, 0x74, 0x75, 0x6f, 0x55, 0xa9, 0x11, 0x6e, 0x92, 0x9, 0x3a, 0xc9, 0x94, 0x51, 0xae, 0xfb, 0x2a, 0xf9, 0xfd, 0x32, 0xd6, 0xd7, 0xf5, 0xfb, 0xc7, 0xf7, 0xa5, 0x40, 0xd5, 0x9, 0x7c, 0x9, 0x6e, 0xbc, 0x3b, 0x3a, 0x72, 0x15, 0x41, 0xde, 0x7, 0x3a, 0x1c, 0xc0, 0x2f, 0x7f, 0xb0, 0xfb, 0x1b, 0x93, 0x27, 0xfb, 0xb, 0x12, 0x18, 0xca, 0x49, 0xc9, 0x48, 0x7a, 0xb5, 0x39, 0x66, 0x22, 0xa1, 0x3a, 0xe5, 0x46, 0xc9, 0x7a, 0xbd, 0xef, 0x6b, 0x56, 0x38, 0xd, 0xda, 0x70, 0x12, 0xa8, 0x38, 0x40, 0x91, 0xb6, 0x65, 0x6d, 0xa, 0xb2, 0x72, 0xd3, 0x63, 0xce, 0xa7, 0x81, 0x63, 0xff, 0x76, 0x5c, 0xdd, 0x13, 0xab, 0x17, 0x38, 0xb9, 0x40, 0xd1, 0x6c, 0xae}, - output224: []byte{0x45, 0x47, 0x96, 0xc7, 0x21, 0x9c, 0x6f, 0x7e, 0x88, 0x50, 0x8d, 0xfc, 0x13, 0x66, 0x8b, 0x81, 0x74, 0x82, 0x11, 0xbd, 0x1, 0x6d, 0x84, 0xb5, 0x92, 0x93, 0xb4, 0x45}, - output256: []byte{0x85, 0x45, 0x9c, 0xfb, 0x2, 0x89, 0x59, 0x9c, 0xdd, 0x67, 0xc4, 0x73, 0xa0, 0xba, 0x6d, 0xa6, 0x16, 0xc6, 0x8, 0xe3, 0x67, 0xf5, 0x8c, 0x50, 0xa0, 0x35, 0x62, 0x42, 0x4d, 0xcf, 0x1d, 0x6}, - output384: []byte{0x98, 0xd7, 0x3b, 0x35, 0x55, 0xf0, 0x3, 0x5, 0x8f, 0x7b, 0x5a, 0x14, 0x5d, 0x89, 0xfa, 0xec, 0x46, 0xc1, 0x70, 0x99, 0xa3, 0x54, 0xef, 0x38, 0x34, 0xa2, 0x1, 0x42, 0xdb, 0xd5, 0xa, 0xe, 0x80, 0x54, 0x59, 0x8c, 0xe7, 0x94, 0x1b, 0xf5, 0xdd, 0x4d, 0xf7, 0xcc, 0xf2, 0x18, 0xf0, 0x2f}, - output512: []byte{0xfc, 0x11, 0x27, 0xf6, 0x65, 0xf, 0x32, 0x63, 0x84, 0x53, 0xab, 0x77, 0x3f, 0x5c, 0xe6, 0xf, 0x9f, 0x61, 0x65, 0xbc, 0x99, 0x28, 0xef, 0xf1, 0x8c, 0x7a, 0x32, 0x81, 0x54, 0xc, 0x7a, 0x61, 0x5d, 0x2d, 0x62, 0xa9, 0x2e, 0x55, 0x7d, 0x4a, 0x1e, 0xc1, 0x22, 0x9e, 0x84, 0x81, 0x9d, 0x2d, 0xbf, 0x6, 0xce, 0xd4, 0xde, 0xf, 0xf9, 0x0, 0x40, 0xec, 0xb9, 0x61, 0xd6, 0x78, 0xe1, 0x81}, - }, - { - msg: []byte{0xc3, 0x8d, 0x6b, 0xb, 0x75, 0x7c, 0xb5, 0x52, 0xbe, 0x40, 0x94, 0xe, 0xce, 0x0, 0x9, 0xef, 0x3b, 0xb, 0x59, 0x30, 0x7c, 0x14, 0x51, 0x68, 0x6f, 0x1a, 0x22, 0x70, 0x29, 0x22, 0x80, 0xd, 0x58, 0xbc, 0xe7, 0xa6, 0x36, 0xc1, 0x72, 0x7e, 0xe5, 0x47, 0xc0, 0x1b, 0x21, 0x47, 0x79, 0xe8, 0x98, 0xfc, 0xe, 0x56, 0xf, 0x8a, 0xe7, 0xf6, 0x1b, 0xef, 0x4d, 0x75, 0xea, 0xa6, 0x96, 0xb9, 0x21, 0xfd, 0x6b, 0x73, 0x5d, 0x17, 0x15, 0x35, 0xe9, 0xed, 0xd2, 0x67, 0xc1, 0x92, 0xb9, 0x98, 0x80, 0xc8, 0x79, 0x97, 0x71, 0x10, 0x2, 0x0, 0x90, 0x95, 0xd8, 0xa7, 0xa4, 0x37, 0xe2, 0x58, 0x10, 0x4a, 0x41, 0xa5, 0x5, 0xe5, 0xef, 0x71, 0xe5, 0x61, 0x3d, 0xdd, 0x20, 0x8, 0x19, 0x5f, 0xc, 0x57, 0x4e, 0x6b, 0xa3, 0xfe, 0x40, 0x9, 0x9c, 0xfa, 0x11, 0x6e, 0x5f, 0x1a, 0x2f, 0xa8, 0xa6, 0xda, 0x4, 0xba, 0xdc, 0xb4, 0xe2, 0xd5, 0xd0, 0xde, 0x31, 0xfd, 0xc4, 0x80, 0x8, 0x91, 0xc4, 0x57, 0x81, 0xa0, 0xaa, 0xc7, 0xc9, 0x7, 0xb5, 0x6d, 0x63, 0x1f, 0xca, 0x5c, 0xe8, 0xb2, 0xcd, 0xe6, 0x20, 0xd1, 0x1d, 0x17, 0x77, 0xed, 0x9f, 0xa6, 0x3, 0x54, 0x1d, 0xe7, 0x94, 0xdd, 0xc5, 0x75, 0x8f, 0xcd, 0x5f, 0xad, 0x78, 0xc0}, - output224: []byte{0xce, 0x15, 0x8a, 0xed, 0x6e, 0xd3, 0xc9, 0xd4, 0x43, 0x2e, 0x24, 0x22, 0xaf, 0x8d, 0x25, 0x5a, 0xb1, 0xf3, 0x89, 0x8f, 0x6f, 0x5b, 0x5c, 0x5a, 0x14, 0x78, 0x55, 0x2c}, - output256: []byte{0x55, 0x39, 0xd2, 0xe5, 0x2a, 0x5a, 0x1b, 0xb3, 0xc2, 0x46, 0xb0, 0x15, 0x83, 0x56, 0xe2, 0xb2, 0x78, 0x2f, 0xc1, 0x3c, 0x10, 0x24, 0x89, 0x37, 0xa0, 0xc4, 0xa4, 0xb, 0x9, 0x1f, 0x62, 0x47}, - output384: []byte{0x37, 0x95, 0xde, 0x49, 0xf, 0x43, 0xb9, 0x89, 0x99, 0x47, 0xc1, 0xc3, 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93, 0x77, 0x16, 0xc, 0xca, 0x4e, 0x67, 0x93, 0xd0, 0xa, 0x51, 0x5d, 0xc2, 0x99, 0x2c, 0xb7, 0xfc, 0x74, 0x1d, 0xac, 0xa1, 0x71, 0x43, 0x1d, 0xa9, 0x9c, 0xce, 0x6f, 0x77, 0x89, 0xf1, 0x29, 0xe2, 0xac, 0x5c, 0xf6, 0x5b, 0x40, 0xd7, 0x3, 0x3, 0x5c, 0xd2, 0x18, 0x5b, 0xb9, 0x36, 0xc8, 0x20, 0x2, 0xda, 0xf8, 0xcb, 0xc2, 0x7a, 0x7a, 0x9e, 0x55, 0x4b, 0x6, 0x19, 0x66, 0x30, 0x44, 0x6a, 0x6f, 0xa, 0x14, 0xba, 0x15, 0x5e, 0xd2, 0x6d, 0x95, 0xbd, 0x62, 0x7b, 0x72, 0x5, 0xc0, 0x72, 0xd0, 0x2b, 0x60, 0xdb, 0xf, 0xd7, 0xe4, 0x9e, 0xa0, 0x58, 0xc2, 0xe0, 0xba, 0x20, 0x2d, 0xaf, 0xf0, 0xde, 0x91, 0xe8, 0x45, 0xcf, 0x79}, - output224: []byte{0xa0, 0xa2, 0x1d, 0x95, 0xe6, 0x40, 0xf1, 0x3b, 0x25, 0x65, 0x24, 0x84, 0xe2, 0x44, 0xbe, 0x1b, 0x37, 0x3e, 0x9b, 0x6, 0x9, 0xb6, 0x85, 0xef, 0xce, 0x48, 0x10, 0x7a}, - output256: []byte{0x6d, 0x63, 0x41, 0x92, 0x7, 0xb9, 0x9d, 0x4d, 0xb1, 0xad, 0xd7, 0x95, 0xd8, 0x52, 0xa8, 0xda, 0xac, 0x11, 0xb7, 0x89, 0xaf, 0xc, 0x7d, 0x63, 0x53, 0x3, 0x6c, 0xb2, 0x3f, 0x64, 0x28, 0xb4}, - output384: []byte{0xe9, 0xf2, 0x89, 0xe6, 0x71, 0x54, 0x1f, 0xec, 0x45, 0x99, 0x91, 0x5a, 0xd, 0x99, 0x35, 0xbf, 0x5c, 0x20, 0xa1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, 0xc7, 0x4f, 0x48, 0xb6, 0xe7, 0xa1, 0xbf, 0xd5, 0xcc, 0x4d, 0xcf, 0x24, 0xe4, 0xd5, 0x2e, 0x92, 0xbd, 0x44, 0x55, 0x84, 0x8e, 0x49, 0x28, 0xb0, 0xea, 0xc8, 0xb7, 0x47, 0x6f, 0xe3, 0xcc, 0x3, 0xe8, 0x62, 0xaa, 0x4d, 0xff, 0x44, 0x70, 0xdb, 0xfe, 0xd6, 0xde, 0x48, 0xe4, 0x10, 0xf2, 0x50, 0x96, 0x48, 0x7e, 0xcf, 0xc3, 0x2a, 0x27, 0x27, 0x7f, 0x3f, 0x50, 0x23, 0xb2, 0x72, 0x5a, 0xde, 0x46, 0x1b, 0x13, 0x55, 0x88, 0x95, 0x54, 0xa8, 0x83, 0x6c, 0x9c, 0xf5, 0x3b, 0xd7, 0x67, 0xf5, 0x73, 0x7d, 0x55, 0x18, 0x4e, 0xea, 0x1a, 0xb3, 0xf5, 0x3e, 0xdd, 0x9, 0x76, 0xc4, 0x85}, - output224: []byte{0x57, 0x39, 0x7b, 0xb1, 0xf8, 0x47, 0x11, 0x64, 0x1e, 0x94, 0xf4, 0x13, 0xf5, 0xd7, 0x35, 0x56, 0xb9, 0x6b, 0xa5, 0xcf, 0xe1, 0x5f, 0x70, 0x95, 0x28, 0x62, 0x6d, 0x7}, - output256: []byte{0x23, 0x3b, 0xb, 0xc2, 0x81, 0x43, 0xc3, 0x2a, 0x66, 0x8b, 0xa, 0xb5, 0xd7, 0x6b, 0xe5, 0x71, 0x2c, 0x3, 0x87, 0x5, 0x6f, 0xb0, 0xe7, 0x9f, 0x2c, 0x2f, 0x7f, 0x1c, 0x31, 0xe4, 0xa8, 0x6a}, - output384: []byte{0x72, 0x1, 0x50, 0xfd, 0x5a, 0x1c, 0xf9, 0x4a, 0x42, 0xf9, 0x22, 0xef, 0xcb, 0xb7, 0x23, 0xff, 0x94, 0x8f, 0x74, 0xca, 0x6d, 0xa, 0x3f, 0x39, 0x9a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 0x7a, 0x7f, 0xd7, 0xce, 0xe, 0x21, 0x6, 0xf0, 0xc8, 0xb0, 0xab, 0xf4, 0x71, 0x5e, 0x2c, 0xa4, 0x8e, 0xf9, 0xf4, 0x54, 0xdc, 0x20, 0x3c, 0x96, 0x65, 0x66, 0x53, 0xb7, 0x27, 0x8, 0x35, 0x13, 0xf8, 0xef, 0xb8, 0x6e, 0x49, 0xc5, 0x13, 0xbb, 0x75, 0x8b, 0x3b, 0x5, 0x2f, 0xe2, 0x1f, 0x1c, 0x5, 0xbb, 0x33, 0xc3, 0x71, 0x29, 0xd6, 0xcc, 0x81, 0xf1, 0xae, 0xf6, 0xad, 0xc4, 0x5b, 0xe, 0x88, 0x27, 0xa8, 0x30, 0xfe, 0x54, 0x5c, 0xf5, 0x7d, 0x9, 0x55, 0x80, 0x2c, 0x11, 0x7d, 0x23, 0xcc, 0xb5, 0x5e, 0xa2, 0x8f, 0x95, 0xc0, 0xd8, 0xc2, 0xf9, 0xc5, 0xa2, 0x42, 0xb3, 0x3f}, - output224: []byte{0x68, 0xf6, 0xac, 0x42, 0x89, 0xfd, 0x52, 0x14, 0x26, 0x31, 0x30, 0x83, 0xf, 0xda, 0x4d, 0xa6, 0x1, 0xb8, 0x8b, 0x1f, 0x85, 0x33, 0xea, 0xc0, 0x7a, 0x3, 0x38, 0xd9}, - output256: []byte{0xb7, 0x9b, 0x5f, 0x81, 0x82, 0xd3, 0xfb, 0x4a, 0xba, 0xb6, 0x3e, 0x7c, 0xb2, 0x6a, 0x8e, 0x8, 0x65, 0xae, 0x8d, 0x79, 0xbd, 0x4c, 0x51, 0x4a, 0xd8, 0x91, 0x7d, 0x5e, 0xcb, 0x7f, 0xed, 0x8f}, - output384: []byte{0xfa, 0x6f, 0x90, 0x93, 0x58, 0x43, 0xd4, 0xf5, 0x8e, 0x77, 0xca, 0xbe, 0x4b, 0xa6, 0x62, 0xb4, 0xfa, 0xbc, 0x17, 0x32, 0x72, 0x5f, 0xaf, 0x95, 0x2e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, 0x13, 0x73, 0xf6, 0xf6, 0x72, 0x62, 0x4f, 0xce, 0xa8, 0xd1, 0xa9, 0xf8, 0x51, 0x70, 0xfa, 0xd3, 0xf, 0xa0, 0xbb, 0xd2, 0x50, 0x35, 0xc3, 0xb4, 0x1a, 0x61, 0x75, 0xd4, 0x67, 0x99, 0x8b, 0xd1, 0x21, 0x5f, 0x6f, 0x38, 0x66, 0xf5, 0x38, 0x47, 0xf9, 0xcf, 0x68, 0xef, 0x3e, 0x2f, 0xbb, 0x54, 0xbc, 0x99, 0x4d, 0xe2, 0x30, 0x2b, 0x82, 0x9c, 0x5e, 0xea, 0x68, 0xec, 0x44, 0x1f, 0xcb, 0xaf, 0xd7, 0xd1, 0x6a, 0xe4, 0xfe, 0x9f, 0xff, 0x98, 0xbf, 0x0, 0xe5, 0xbc, 0x2a, 0xd5, 0x4d, 0xd9, 0x1f, 0xf9, 0xfd, 0xa4, 0xdd, 0x77, 0xb6, 0xc7, 0x54, 0xa9, 0x19, 0x55, 0xd1, 0xfb, 0xaa, 0xd0}, - output224: []byte{0xf1, 0x45, 0xc4, 0x52, 0x12, 0x39, 0x28, 0x94, 0xe7, 0xf1, 0xc4, 0xe5, 0x27, 0x28, 0x47, 0xf, 0x8a, 0x2d, 0x96, 0x15, 0x14, 0x86, 0x99, 0x90, 0xef, 0xbe, 0x82, 0x32}, - output256: []byte{0xf6, 0x80, 0x19, 0x8d, 0xe2, 0x94, 0x3d, 0x20, 0xe9, 0xd8, 0x9, 0xfd, 0x83, 0x12, 0xd6, 0x74, 0xc9, 0xa2, 0x50, 0xda, 0x22, 0xba, 0x6e, 0x92, 0xe, 0x40, 0x8f, 0x6f, 0x2c, 0xe, 0x7, 0x39}, - output384: []byte{0x4e, 0x28, 0x32, 0xfe, 0xe2, 0x90, 0xd1, 0x91, 0x7c, 0x15, 0xb3, 0x18, 0x93, 0xf6, 0x57, 0x8c, 0x12, 0x99, 0x44, 0x5b, 0x99, 0xbc, 0x48, 0x70, 0x8e, 0x13, 0x34, 0x8a, 0x11, 0xeb, 0x2f, 0x27, 0xfe, 0x21, 0x7a, 0x63, 0xf5, 0x32, 0x58, 0x37, 0x93, 0xd1, 0x8c, 0xde, 0xcc, 0xaa, 0x78, 0xb9}, - output512: []byte{0xc9, 0x82, 0x65, 0x39, 0x6f, 0x32, 0x78, 0xfc, 0x53, 0x21, 0x25, 0xde, 0xd0, 0x97, 0xa6, 0x85, 0x1f, 0xc5, 0xbf, 0x37, 0xca, 0x32, 0xec, 0x26, 0xf4, 0x3e, 0x64, 0x87, 0x42, 0x41, 0x30, 0x9f, 0x56, 0x8a, 0x21, 0x71, 0x19, 0xba, 0x98, 0x4c, 0x54, 0x9, 0x9f, 0x88, 0x99, 0xac, 0x94, 0xb7, 0x90, 0xa, 0x4d, 0xd9, 0xd3, 0x87, 0x7e, 0x18, 0x37, 0x1f, 0x5d, 0xaf, 0xd1, 0x92, 0x1f, 0x8}, - }, - { - msg: []byte{0x58, 0x8e, 0x94, 0xb9, 0x5, 0x4a, 0xbc, 0x21, 0x89, 0xdf, 0x69, 0xb8, 0xba, 0x34, 0x34, 0x1b, 0x77, 0xcd, 0xd5, 0x28, 0xe7, 0x86, 0xe, 0x5d, 0xef, 0xca, 0xa7, 0x9b, 0xc, 0x9a, 0x45, 0x2a, 0xd4, 0xb8, 0x2a, 0xa3, 0x6, 0xbe, 0x84, 0x53, 0x6e, 0xb7, 0xce, 0xdc, 0xbe, 0x5, 0x8d, 0x7b, 0x84, 0xa6, 0xae, 0xf8, 0x26, 0xb0, 0x28, 0xb8, 0xa0, 0x27, 0x1b, 0x69, 0xac, 0x36, 0x5, 0xa9, 0x63, 0x5e, 0xa9, 0xf5, 0xea, 0xa, 0xa7, 0x0, 0xf3, 0xeb, 0x78, 0x35, 0xbc, 0x54, 0x61, 0x1b, 0x92, 0x29, 0x64, 0x30, 0xc, 0x95, 0x3e, 0xfe, 0x74, 0x91, 0xe3, 0x67, 0x7c, 0x2c, 0xeb, 0xe0, 0x82, 0x2e, 0x95, 0x6c, 0xd1, 0x64, 0x33, 0xb0, 0x2c, 0x68, 0xc4, 0xa2, 0x32, 0x52, 0xc3, 0xf9, 0xe1, 0x51, 0xa4, 0x16, 0xb4, 0x96, 0x32, 0x57, 0xb7, 0x83, 0xe0, 0x38, 0xf6, 0xb4, 0xd5, 0xc9, 0xf1, 0x10, 0xf8, 0x71, 0x65, 0x2c, 0x7a, 0x64, 0x9a, 0x7b, 0xce, 0xdc, 0xbc, 0xcc, 0x6f, 0x2d, 0x7, 0x25, 0xbb, 0x90, 0x3c, 0xc1, 0x96, 0xba, 0x76, 0xc7, 0x6a, 0xa9, 0xf1, 0xa, 0x19, 0xb, 0x1d, 0x11, 0x68, 0x99, 0x3b, 0xaa, 0x9f, 0xfc, 0x96, 0xa1, 0x65, 0x52, 0x16, 0x77, 0x34, 0x58, 0xbe, 0xc7, 0x2b, 0xe, 0x39, 0xc9, 0xf2, 0xc1, 0x21, 0x37, 0x8f, 0xea, 0xb4, 0xe7, 0x6a}, - output224: []byte{0x38, 0xce, 0x71, 0x0, 0xe9, 0x2e, 0xe4, 0xb6, 0x5c, 0xc8, 0x31, 0x91, 0x5a, 0x6, 0xcf, 0xc2, 0x10, 0x19, 0x90, 0xcb, 0x68, 0xe1, 0x0, 0x4f, 0x7e, 0x90, 0x17, 0xd4}, - output256: []byte{0xa1, 0x90, 0xdd, 0x73, 0x55, 0x60, 0x86, 0xea, 0x70, 0xbc, 0x31, 0x2, 0x2d, 0x6a, 0x4f, 0x95, 0xd8, 0x9d, 0xc0, 0x99, 0xe2, 0x3, 0xc, 0x19, 0x31, 0x1c, 0xc8, 0x98, 0x82, 0x81, 0x27, 0x8f}, - output384: []byte{0x1f, 0xb9, 0x7d, 0x6f, 0x42, 0x48, 0xe, 0x9f, 0x13, 0xc9, 0x34, 0xc4, 0xa8, 0x74, 0x87, 0x7a, 0x80, 0x8f, 0x1d, 0x73, 0x31, 0x4c, 0x54, 0x4d, 0x85, 0x70, 0xc0, 0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69, 0x87, 0x12, 0xe9, 0x63, 0x71, 0x59, 0x83, 0xfd, 0x7, 0x64, 0x1a, 0xe4, 0xb4, 0xe9, 0xdc, 0x73, 0x20, 0x3f, 0xac, 0x1a, 0xe1, 0x1f, 0xa1, 0xf8, 0xc7, 0x94, 0x1f, 0xcc, 0x82, 0xea, 0xb2, 0x47, 0xad, 0xdb, 0x56, 0xe2, 0x63, 0x84, 0x47, 0xe9, 0xd6, 0x9, 0xe6, 0x10, 0xb6, 0xc, 0xe0, 0x86, 0x65, 0x6a, 0xae, 0xbf, 0x1d, 0xa3, 0xc8, 0xa2, 0x31, 0xd7, 0xd9, 0x4e, 0x2f, 0xd0, 0xaf, 0xe4, 0x6b, 0x39, 0x1f, 0xf1, 0x4a, 0x72, 0xea, 0xeb, 0x3f, 0x44, 0xad, 0x4d, 0xf8, 0x58, 0x66, 0xde, 0xf4, 0x3d, 0x47, 0x81, 0xa0, 0xb3, 0x57, 0x8b, 0xc9, 0x96, 0xc8, 0x79, 0x70, 0xb1, 0x32}, - output224: []byte{0xbd, 0x63, 0xca, 0x84, 0xda, 0xc8, 0xbc, 0x58, 0x6d, 0xf, 0xb, 0xe3, 0x52, 0xdb, 0xbb, 0xa1, 0xf4, 0xcb, 0x43, 0xd, 0xea, 0xa8, 0x11, 0x9b, 0x8d, 0xa1, 0x3c, 0x6}, - output256: []byte{0x21, 0x16, 0x60, 0x64, 0xc5, 0x2b, 0x58, 0x8c, 0x1e, 0xc7, 0xea, 0x6d, 0xf1, 0x90, 0x5a, 0x2b, 0x59, 0xba, 0xd4, 0x99, 0xb4, 0x70, 0xf3, 0x8, 0xa2, 0x6b, 0x6e, 0x35, 0x4d, 0xdf, 0xe5, 0x8f}, - output384: []byte{0x86, 0xb3, 0xc8, 0x1a, 0xa3, 0x98, 0xc8, 0x81, 0x9a, 0xfc, 0x4f, 0x28, 0x2d, 0xfb, 0xce, 0x24, 0xf4, 0x19, 0x2b, 0x25, 0x30, 0xc2, 0x67, 0xa7, 0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x8f, 0x5, 0x2, 0x62, 0xdb, 0x5b, 0x54, 0x5b, 0x15, 0x9e, 0x1f, 0xf1, 0xdc, 0xa6, 0xeb, 0x73, 0x4b, 0x87, 0x23, 0x43, 0xb8, 0x42, 0xc5, 0x7e, 0xaf, 0xcf, 0xda, 0x84, 0x5, 0xee, 0xdb, 0xb4, 0x8e, 0xf3, 0x2e, 0x99, 0x69, 0x6d, 0x13, 0x59, 0x79, 0x23, 0x5c, 0x3a, 0x5, 0x36, 0x4e, 0x37, 0x1c, 0x2d, 0x76, 0xf1, 0x90, 0x2f, 0x1d, 0x83, 0x14, 0x6d, 0xf9, 0x49, 0x5c, 0xa, 0x6c, 0x57, 0xd7, 0xbf, 0x9e, 0xe7, 0x7e, 0x80, 0xf9, 0x78, 0x7a, 0xee, 0x27, 0xbe, 0x1f, 0xe1, 0x26, 0xcd, 0xc9, 0xef, 0x89, 0x3a, 0x4a, 0x7d, 0xcb, 0xbc, 0x36, 0x7e, 0x40, 0xfe, 0x4e, 0x1e, 0xe9, 0xb, 0x42, 0xea, 0x25, 0xaf, 0x1}, - output224: []byte{0x7e, 0xe4, 0xea, 0xea, 0x61, 0x27, 0xc6, 0x8e, 0xfc, 0xe6, 0x69, 0x91, 0xb8, 0xf0, 0x85, 0x1f, 0xe0, 0x72, 0xdf, 0x3b, 0x1e, 0xb, 0x5d, 0x7, 0xe3, 0xa4, 0xbe, 0x6}, - output256: []byte{0x5, 0x1e, 0x19, 0x90, 0x64, 0x64, 0xec, 0x7f, 0xdc, 0x3d, 0x37, 0xee, 0x3b, 0xce, 0xf6, 0x34, 0x38, 0xec, 0x5e, 0xdb, 0xea, 0x5a, 0xa2, 0x2, 0xa2, 0x4b, 0x7f, 0x71, 0x90, 0xb6, 0x89, 0xe0}, - output384: []byte{0xa6, 0xbf, 0x54, 0x8a, 0xb1, 0x9f, 0xf6, 0xd, 0x6a, 0x87, 0x29, 0xfa, 0x62, 0xfd, 0xc9, 0xb5, 0x92, 0x37, 0x84, 0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88, 0x20, 0x50, 0x5d, 0x4, 0xd, 0xa8, 0x10, 0x12, 0x6a, 0xbc, 0x3e, 0x65, 0x8, 0x8d, 0xc4, 0x21, 0xe4, 0x6d, 0x3e, 0x54, 0xdd, 0x31, 0x77, 0x7c, 0x53, 0x9a, 0xe0, 0x83, 0xb7, 0xb8, 0xa4, 0xe2, 0x30, 0x38, 0x36}, - output512: []byte{0x53, 0x37, 0x47, 0x74, 0x87, 0xa0, 0xaf, 0x43, 0xeb, 0x7b, 0x99, 0x52, 0x93, 0xca, 0x2b, 0xef, 0x6e, 0xab, 0x24, 0x32, 0xb1, 0x33, 0x3d, 0xca, 0xea, 0xd7, 0x6, 0x44, 0x6, 0xe2, 0x28, 0x61, 0xfc, 0xea, 0x62, 0x3f, 0xd8, 0xb8, 0x5b, 0x30, 0x46, 0x57, 0x87, 0x35, 0x2a, 0x36, 0xc9, 0x43, 0x61, 0xf, 0x14, 0x58, 0xfd, 0x22, 0xe3, 0xf5, 0x5d, 0xdd, 0x19, 0x5a, 0x6a, 0xca, 0xa3, 0x74}, - }, - { - msg: []byte{0x8f, 0x65, 0xf6, 0xbc, 0x59, 0xa8, 0x57, 0x5, 0x1, 0x6e, 0x2b, 0xae, 0x7f, 0xe5, 0x79, 0x80, 0xde, 0x31, 0x27, 0xe5, 0xab, 0x27, 0x5f, 0x57, 0x3d, 0x33, 0x4f, 0x73, 0xf8, 0x60, 0x31, 0x6, 0xec, 0x35, 0x53, 0x1, 0x66, 0x8, 0xef, 0x2d, 0xd6, 0xe6, 0x9b, 0x24, 0xbe, 0xb, 0x71, 0x13, 0xbf, 0x6a, 0x76, 0xb, 0xa6, 0xe9, 0xce, 0x1c, 0x48, 0xf9, 0xe1, 0x86, 0x1, 0x2c, 0xf9, 0x6a, 0x1d, 0x48, 0x49, 0xd7, 0x5d, 0xf5, 0xbb, 0x83, 0x15, 0x38, 0x7f, 0xd7, 0x8e, 0x9e, 0x15, 0x3e, 0x76, 0xf8, 0xba, 0x7e, 0xc6, 0xc8, 0x84, 0x98, 0x10, 0xf5, 0x9f, 0xb4, 0xbb, 0x9b, 0x0, 0x43, 0x18, 0x21, 0xb, 0x37, 0xf1, 0x29, 0x95, 0x26, 0x86, 0x6f, 0x44, 0x5, 0x9e, 0x1, 0x7e, 0x22, 0xe9, 0x6c, 0xbe, 0x41, 0x86, 0x99, 0xd0, 0x14, 0xc6, 0xea, 0x1, 0xc9, 0xf0, 0x3, 0x8b, 0x10, 0x29, 0x98, 0x84, 0xdb, 0xec, 0x31, 0x99, 0xbb, 0x5, 0xad, 0xc9, 0x4e, 0x95, 0x5a, 0x15, 0x33, 0x21, 0x9c, 0x11, 0x15, 0xfe, 0xd0, 0xe5, 0xf2, 0x12, 0x28, 0xb0, 0x71, 0xf4, 0xd, 0xd5, 0x7c, 0x42, 0x40, 0xd9, 0x8d, 0x37, 0xb7, 0x3e, 0x41, 0x2f, 0xe0, 0xfa, 0x47, 0x3, 0x12, 0xd, 0x7c, 0xc, 0x67, 0x97, 0x2e, 0xd2, 0x33, 0xe5, 0xde, 0xb3, 0x0, 0xa2, 0x26, 0x5, 0x47, 0x2f, 0xa3, 0xa3, 0xba, 0x86}, - output224: []byte{0xc9, 0xc2, 0x63, 0x96, 0xe5, 0x60, 0xcd, 0x1e, 0x68, 0x24, 0xd9, 0xe5, 0x6e, 0x17, 0x9f, 0xcc, 0x8a, 0xac, 0x4c, 0xd, 0x93, 0x2f, 0x76, 0x32, 0xba, 0x59, 0x4d, 0x4c}, - output256: []byte{0xbd, 0xb4, 0x26, 0x38, 0x92, 0x11, 0x99, 0xd6, 0x4, 0x29, 0x4b, 0x55, 0x78, 0xce, 0xba, 0xcc, 0xdf, 0x13, 0x2e, 0x1d, 0x7a, 0xf7, 0x67, 0x5b, 0x77, 0x68, 0xe5, 0x5, 0x53, 0xfc, 0xb6, 0x4}, - output384: []byte{0x48, 0xca, 0x59, 0x12, 0xc1, 0x11, 0xdb, 0x66, 0x7a, 0x77, 0xbe, 0x7c, 0x77, 0xf8, 0x41, 0xe8, 0xb3, 0x71, 0x30, 0x24, 0x83, 0x77, 0xa1, 0x9c, 0xd2, 0xfa, 0x3c, 0xd2, 0xee, 0xc4, 0x8b, 0x33, 0x7c, 0xfe, 0x7, 0xc2, 0x90, 0xf2, 0x69, 0xa, 0xd4, 0x9e, 0x79, 0xce, 0x3a, 0x9f, 0x9e, 0x53}, - output512: []byte{0x28, 0xab, 0x5c, 0x62, 0x98, 0xa6, 0x2, 0xae, 0x51, 0xee, 0xec, 0x40, 0x80, 0x24, 0x5f, 0x7c, 0xa1, 0xf, 0x9a, 0x8c, 0x30, 0x4f, 0x22, 0xb5, 0xaa, 0x88, 0xd0, 0xe4, 0x92, 0x26, 0xc0, 0x1c, 0x2f, 0xd3, 0xcc, 0x5d, 0x8e, 0x99, 0x30, 0x97, 0x67, 0x81, 0x6e, 0x4f, 0x6d, 0x52, 0x71, 0x98, 0x76, 0x6, 0x54, 0x95, 0xdd, 0xb6, 0x1d, 0xd1, 0x13, 0xcf, 0xff, 0x6, 0xb1, 0x1d, 0x86, 0x4}, - }, - { - msg: []byte{0x84, 0x89, 0x1e, 0x52, 0xe0, 0xd4, 0x51, 0x81, 0x32, 0x10, 0xc3, 0xfd, 0x63, 0x5b, 0x39, 0xa0, 0x3a, 0x6b, 0x7a, 0x73, 0x17, 0xb2, 0x21, 0xa7, 0xab, 0xc2, 0x70, 0xdf, 0xa9, 0x46, 0xc4, 0x26, 0x69, 0xaa, 0xcb, 0xbb, 0xdf, 0x80, 0x1e, 0x15, 0x84, 0xf3, 0x30, 0xe2, 0x8c, 0x72, 0x98, 0x47, 0xea, 0x14, 0x15, 0x2b, 0xd6, 0x37, 0xb3, 0xd0, 0xf2, 0xb3, 0x8b, 0x4b, 0xd5, 0xbf, 0x9c, 0x79, 0x1c, 0x58, 0x80, 0x62, 0x81, 0x10, 0x3a, 0x3e, 0xab, 0xba, 0xed, 0xe5, 0xe7, 0x11, 0xe5, 0x39, 0xe6, 0xa8, 0xb2, 0xcf, 0x29, 0x7c, 0xf3, 0x51, 0xc0, 0x78, 0xb4, 0xfa, 0x8f, 0x7f, 0x35, 0xcf, 0x61, 0xbe, 0xbf, 0x88, 0x14, 0xbf, 0x24, 0x8a, 0x1, 0xd4, 0x1e, 0x86, 0xc5, 0x71, 0x5e, 0xa4, 0xc, 0x63, 0xf7, 0x37, 0x53, 0x79, 0xa7, 0xeb, 0x1d, 0x78, 0xf2, 0x76, 0x22, 0xfb, 0x46, 0x8a, 0xb7, 0x84, 0xaa, 0xab, 0xa4, 0xe5, 0x34, 0xa6, 0xdf, 0xd1, 0xdf, 0x6f, 0xa1, 0x55, 0x11, 0x34, 0x1e, 0x72, 0x5e, 0xd2, 0xe8, 0x7f, 0x98, 0x73, 0x7c, 0xcb, 0x7b, 0x6a, 0x6d, 0xfa, 0xe4, 0x16, 0x47, 0x74, 0x72, 0xb0, 0x46, 0xbf, 0x18, 0x11, 0x18, 0x7d, 0x15, 0x1b, 0xfa, 0x9f, 0x7b, 0x2b, 0xf9, 0xac, 0xdb, 0x23, 0xa3, 0xbe, 0x50, 0x7c, 0xdf, 0x14, 0xcf, 0xdf, 0x51, 0x7d, 0x2c, 0xb5, 0xfb, 0x9e, 0x4a, 0xb6}, - output224: []byte{0xef, 0x30, 0x65, 0x2e, 0x3c, 0x6e, 0xa4, 0xec, 0x21, 0x44, 0x72, 0xbf, 0x96, 0xe5, 0xf3, 0xd, 0xca, 0x1d, 0x31, 0xa7, 0x8e, 0xb4, 0x22, 0x73, 0x46, 0x15, 0xea, 0xf1}, - output256: []byte{0xcb, 0xd8, 0x82, 0x9, 0xb5, 0x30, 0x1, 0x8a, 0x85, 0x6c, 0x5c, 0x23, 0x21, 0xd7, 0xe4, 0x85, 0x51, 0x1c, 0xa1, 0x51, 0x36, 0x61, 0xf1, 0xfd, 0xe1, 0xfa, 0x6, 0xf4, 0x60, 0x3d, 0xe1, 0x17}, - output384: []byte{0x4b, 0x38, 0x49, 0xb0, 0x91, 0x6d, 0x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9}, - output384: []byte{0x2, 0xc9, 0x8, 0x20, 0xd5, 0xfa, 0x9a, 0x91, 0x7, 0x29, 0x91, 0xe8, 0x7b, 0xfe, 0xec, 0x7f, 0x18, 0x31, 0x5f, 0x8c, 0xa1, 0x90, 0x8e, 0xdb, 0xf1, 0x98, 0x86, 0xc4, 0xca, 0x5b, 0xd5, 0x4a, 0xb9, 0xec, 0x96, 0xa6, 0xab, 0x7b, 0x81, 0x5b, 0x58, 0x53, 0x8f, 0x8, 0x88, 0x67, 0x3, 0xf}, - output512: []byte{0xd0, 0xa1, 0x19, 0x61, 0x7b, 0x7e, 0x30, 0xc2, 0xa8, 0x5e, 0xcb, 0xb3, 0xbb, 0xf3, 0x25, 0xdd, 0xd5, 0x89, 0x43, 0x1c, 0x8c, 0x2e, 0x2f, 0x9f, 0xc6, 0xe3, 0x24, 0xa6, 0xed, 0x8b, 0xaf, 0x11, 0x87, 0xa, 0x80, 0x55, 0x6c, 0xc0, 0x68, 0x8f, 0xee, 0x4d, 0xb7, 0xf, 0x22, 0xb9, 0x42, 0x4b, 0x4f, 0x37, 0xa0, 0xf1, 0xe7, 0xea, 0x31, 0x46, 0x84, 0xda, 0x31, 0xbf, 0x47, 0x3b, 0x3f, 0x34}, - }, - { - msg: []byte{0x70, 0xa4, 0xb, 0xfb, 0xef, 0x92, 0x27, 0x7a, 0x1a, 0xad, 0x72, 0xf6, 0xb7, 0x9d, 0x1, 0x77, 0x19, 0x7c, 0x4e, 0xbd, 0x43, 0x26, 0x68, 0xcf, 0xec, 0x5, 0xd0, 0x99, 0xac, 0xcb, 0x65, 0x10, 0x62, 0xb5, 0xdf, 0xf1, 0x56, 0xc0, 0xb2, 0x73, 0x36, 0x68, 0x7a, 0x94, 0xb2, 0x66, 0x79, 0xcf, 0xdd, 0x9d, 0xaf, 0x7a, 0xd2, 0x4, 0x33, 0x8d, 0xd9, 0xc4, 0xd1, 0x41, 0x14, 0x3, 0x3a, 0x5c, 0x22, 0x5b, 0xd1, 0x1f, 0x21, 0x7b, 0x5f, 0x47, 0x32, 0xda, 0x16, 0x7e, 0xe3, 0xf9, 0x39, 0x26, 0x2d, 0x40, 0x43, 0xfc, 0x9c, 0xba, 0x92, 0x30, 0x3b, 0x7b, 0x5e, 0x96, 0xae, 0xa1, 0x2a, 0xdd, 0xa6, 0x48, 0x59, 0xdf, 0x4b, 0x86, 0xe9, 0xee, 0xb, 0x58, 0xe3, 0x90, 0x91, 0xe6, 0xb1, 0x88, 0xb4, 0x8, 0xac, 0x94, 0xe1, 0x29, 0x4a, 0x89, 0x11, 0x24, 0x5e, 0xe3, 0x61, 0xe6, 0xe, 0x60, 0x1e, 0xff, 0x58, 0xd1, 0xd3, 0x76, 0x39, 0xf3, 0x75, 0x3b, 0xec, 0x80, 0xeb, 0xb4, 0xef, 0xde, 0x25, 0x81, 0x74, 0x36, 0x7, 0x66, 0x23, 0xfc, 0x65, 0x41, 0x5f, 0xe5, 0x1d, 0x1b, 0x2, 0x80, 0x36, 0x6d, 0x12, 0xc5, 0x54, 0xd8, 0x67, 0x43, 0xf3, 0xc3, 0xb6, 0x57, 0x2e, 0x40, 0x3, 0x61, 0xa6, 0x7, 0x26, 0x13, 0x14, 0x41, 0xba, 0x49, 0x3a, 0x83, 0xfb, 0xe9, 0xaf, 0xda, 0x90, 0xf7, 0xaf, 0x1a, 0xe7, 0x17, 0x23, 0x8d}, - output224: []byte{0x7, 0x41, 0x36, 0x65, 0xed, 0xcb, 0x8a, 0x35, 0x2, 0x18, 0x74, 0x98, 0x49, 0x10, 0xb4, 0x98, 0xcf, 0x74, 0x82, 0x30, 0x50, 0x64, 0x2, 0x43, 0xae, 0x7c, 0x84, 0xcd}, - output256: []byte{0xf2, 0x15, 0x7c, 0x16, 0x5e, 0xeb, 0xdf, 0xd0, 0x44, 0x51, 0xe9, 0xe6, 0xcf, 0xb, 0x11, 0x2b, 0xb1, 0x48, 0xeb, 0x9c, 0x40, 0xe8, 0xb2, 0x42, 0x7e, 0xe8, 0xea, 0x57, 0xe6, 0xd, 0x5d, 0xd6}, - output384: []byte{0x75, 0x96, 0x75, 0x1, 0xff, 0x78, 0x1e, 0xfc, 0x3c, 0x9d, 0x59, 0x71, 0x79, 0xc8, 0xcc, 0xae, 0xe4, 0x37, 0x3d, 0x9b, 0xf6, 0xaa, 0x6a, 0x5b, 0xed, 0x51, 0x18, 0x30, 0x3e, 0xdc, 0x8b, 0x74, 0x78, 0xa4, 0x7f, 0x2c, 0xea, 0xf0, 0xa6, 0xb5, 0xb7, 0x22, 0x4e, 0x53, 0xd5, 0xf1, 0xcd, 0xb3}, - output512: []byte{0x1c, 0x88, 0x78, 0x98, 0x85, 0xdc, 0xcc, 0x9a, 0xe8, 0x10, 0x29, 0xac, 0xf0, 0xb6, 0xc9, 0xd0, 0x83, 0xcd, 0xb9, 0x77, 0x4c, 0x34, 0x5f, 0x1c, 0x75, 0x5e, 0x54, 0xc4, 0x5e, 0x9a, 0xf6, 0x3a, 0x70, 0xdc, 0x2a, 0xba, 0xef, 0xeb, 0x1a, 0xd4, 0x16, 0xf1, 0xbd, 0x3d, 0x9b, 0x69, 0xd4, 0xc4, 0x40, 0x4d, 0x22, 0xc8, 0x5e, 0x63, 0x6a, 0x47, 0x3, 0x76, 0x9c, 0x1, 0x12, 0xb5, 0x50, 0xb8}, - }, - { - msg: []byte{0x74, 0x35, 0x6e, 0x44, 0x9f, 0x4b, 0xf8, 0x64, 0x4f, 0x77, 0xb1, 0x4f, 0x4d, 0x67, 0xcb, 0x6b, 0xd9, 0xc1, 0xf5, 0xae, 0x35, 0x76, 0x21, 0xd5, 0xb8, 0x14, 0x7e, 0x56, 0x2b, 0x65, 0xc6, 0x65, 0x85, 0xca, 0xf2, 0xe4, 0x91, 0xb4, 0x85, 0x29, 0xa0, 0x1a, 0x34, 0xd2, 0x26, 0xd4, 0x36, 0x95, 0x91, 0x53, 0x81, 0x53, 0x80, 0xd5, 0x68, 0x9e, 0x30, 0xb3, 0x53, 0x57, 0xcd, 0xac, 0x6e, 0x8, 0xd3, 0xf2, 0xb0, 0xe8, 0x8e, 0x20, 0x6, 0x0, 0xd6, 0x2b, 0xd9, 0xf5, 0xea, 0xf4, 0x88, 0xdf, 0x86, 0xa4, 0x47, 0xe, 0xa2, 0x27, 0x0, 0x61, 0x82, 0xe4, 0x48, 0x9, 0x0, 0x98, 0x68, 0xc4, 0xc2, 0x80, 0xc4, 0x3d, 0x7d, 0x64, 0xa5, 0x26, 0x8f, 0xa7, 0x19, 0x7, 0x49, 0x60, 0x8, 0x7b, 0x3a, 0x6a, 0xbc, 0x83, 0x78, 0x82, 0xf8, 0x82, 0xc8, 0x37, 0x83, 0x45, 0x35, 0x92, 0x93, 0x89, 0xa1, 0x2b, 0x2c, 0x78, 0x18, 0x7e, 0x2e, 0xa0, 0x7e, 0xf8, 0xb8, 0xee, 0xf2, 0x7d, 0xc8, 0x50, 0x2, 0xc3, 0xae, 0x35, 0xf1, 0xa5, 0xb, 0xee, 0x6a, 0x1c, 0x48, 0xba, 0x7e, 0x17, 0x5f, 0x33, 0x16, 0x67, 0xb, 0x27, 0x98, 0x34, 0x72, 0xaa, 0x6a, 0x61, 0xee, 0xd0, 0xa6, 0x83, 0xa3, 0x9e, 0xe3, 0x23, 0x8, 0x6, 0x20, 0xea, 0x44, 0xa9, 0xf7, 0x44, 0x11, 0xae, 0x5c, 0xe9, 0x90, 0x30, 0x52, 0x8f, 0x9a, 0xb4, 0x9c, 0x79, 0xf2}, - output224: []byte{0xfc, 0xc9, 0xea, 0xd1, 0x60, 0x83, 0x2f, 0x5f, 0xf, 0xaf, 0xed, 0x63, 0x81, 0xaf, 0xd5, 0x7f, 0xe1, 0x33, 0x5f, 0xbf, 0xb0, 0x5b, 0x7f, 0xb1, 0xf0, 0x7, 0x5d, 0x37}, - output256: []byte{0x8, 0x36, 0xab, 0xbf, 0x77, 0xef, 0x78, 0xe1, 0x62, 0xde, 0x8f, 0xb6, 0x64, 0xb9, 0x99, 0x6d, 0x5a, 0x3, 0x91, 0x9b, 0x74, 0x1e, 0xb4, 0xa3, 0xf0, 0x2e, 0x7b, 0x97, 0x82, 0x65, 0x69, 0xfa}, - output384: []byte{0x29, 0x83, 0x87, 0xba, 0x8a, 0x3e, 0xb8, 0x8e, 0xe3, 0x6b, 0x42, 0x6, 0xe5, 0x41, 0x93, 0xbc, 0x58, 0x57, 0xf2, 0xa3, 0x3, 0xce, 0x41, 0xdf, 0xf7, 0xc3, 0xbd, 0x53, 0xef, 0x7e, 0xe3, 0xd3, 0x4a, 0xe7, 0xe0, 0xc7, 0x14, 0x31, 0x1a, 0x7b, 0xd8, 0xd2, 0x55, 0x2, 0xca, 0xb4, 0x14, 0xb7}, - output512: []byte{0xf5, 0x2d, 0x7d, 0xd7, 0xff, 0x24, 0x8a, 0x1b, 0xca, 0x7b, 0x71, 0x4f, 0x14, 0xa7, 0x9d, 0xf5, 0x76, 0x6f, 0xd6, 0x7c, 0x0, 0x31, 0xa4, 0x71, 0xcc, 0x50, 0x9f, 0x35, 0x16, 0xd7, 0xc3, 0x48, 0xc3, 0x3f, 0x7d, 0x4b, 0x1c, 0xa3, 0x31, 0xb9, 0x32, 0x38, 0x96, 0xb7, 0x7, 0x4e, 0x10, 0xa8, 0x91, 0xce, 0xa8, 0x51, 0xf9, 0xac, 0x20, 0x24, 0x58, 0x12, 0xb8, 0xcf, 0xaa, 0x55, 0x63, 0x52}, - }, - { - msg: []byte{0x8c, 0x37, 0x98, 0xe5, 0x1b, 0xc6, 0x84, 0x82, 0xd7, 0x33, 0x7d, 0x3a, 0xbb, 0x75, 0xdc, 0x9f, 0xfe, 0x86, 0x7, 0x14, 0xa9, 0xad, 0x73, 0x55, 0x1e, 0x12, 0x0, 0x59, 0x86, 0xd, 0xde, 0x24, 0xab, 0x87, 0x32, 0x72, 0x22, 0xb6, 0x4c, 0xf7, 0x74, 0x41, 0x5a, 0x70, 0xf7, 0x24, 0xcd, 0xf2, 0x70, 0xde, 0x3f, 0xe4, 0x7d, 0xda, 0x7, 0xb6,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 0x2b, 0x18, 0x6a, 0x69, 0xdb, 0x1a, 0x4c, 0x3e, 0x33, 0xc7, 0xa3, 0x76, 0xb4, 0x5c, 0x1b, 0x79, 0xbd, 0x34, 0x6d, 0xd3, 0x3e, 0xf4, 0xce}, - output384: []byte{0x27, 0xce, 0xf6, 0x5d, 0x1a, 0xec, 0xb7, 0x5, 0x1b, 0xad, 0x55, 0xda, 0xd, 0x60, 0x1b, 0xc9, 0xd7, 0xa1, 0x6d, 0x93, 0x8a, 0x57, 0x15, 0x37, 0x4a, 0x43, 0x10, 0x9d, 0xd4, 0x1b, 0x5c, 0x27, 0xd2, 0x6c, 0x91, 0xcb, 0x44, 0xe4, 0xb4, 0x70, 0x2, 0xd9, 0xb9, 0xa, 0xba, 0x5, 0x84, 0xd1}, - output512: []byte{0xa8, 0xae, 0xe4, 0x2a, 0x77, 0xc9, 0xb6, 0x38, 0x7d, 0xc9, 0x73, 0x19, 0x58, 0x19, 0x59, 0xd9, 0xbd, 0x87, 0x8d, 0x6, 0x14, 0x87, 0xfd, 0x6, 0x9a, 0xca, 0x4, 0xd6, 0xf8, 0x4d, 0x34, 0x7e, 0x23, 0x58, 0x7a, 0x6c, 0x7c, 0x56, 0x32, 0x9b, 0x2d, 0xf8, 0x8c, 0x56, 0xc7, 0x10, 0xe, 0xd5, 0x1a, 0xce, 0x5b, 0x5f, 0x77, 0x8d, 0x65, 0x47, 0x8f, 0x5, 0x9c, 0xaf, 0xd6, 0xc0, 0x98, 0xfd}, - }, - { - msg: []byte{0xfa, 0x56, 0xbf, 0x73, 0xc, 0x4f, 0x83, 0x95, 0x87, 0x51, 0x89, 0xc1, 0xc, 0x4f, 0xb2, 0x51, 0x60, 0x57, 0x57, 0xa8, 0xfe, 0xcc, 0x31, 0xf9, 0x73, 0x7e, 0x3c, 0x25, 0x3, 0xb0, 0x26, 0x8, 0xe6, 0x73, 0x1e, 0x85, 0xd7, 0xa3, 0x83, 0x93, 0xc6, 0x7d, 0xe5, 0x16, 0xb8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0x73, 0x3f}, - output256: []byte{0x6, 0xed, 0x2e, 0xbc, 0x41, 0x9d, 0x5, 0x39, 0x49, 0xe8, 0x8c, 0xc9, 0xc0, 0x40, 0xb1, 0xeb, 0xce, 0x74, 0x37, 0x5a, 0xd0, 0xce, 0x9, 0xc0, 0xcd, 0x4d, 0x56, 0x2c, 0x62, 0xf8, 0x49, 0x7d}, - output384: []byte{0x4a, 0xc9, 0xbd, 0xfd, 0x9f, 0x71, 0x7d, 0x1, 0x59, 0x89, 0x8, 0xba, 0x45, 0x76, 0x27, 0xd3, 0xaf, 0x7c, 0x81, 0x23, 0xf7, 0x11, 0xd, 0xd7, 0xfd, 0xb4, 0xe, 0x91, 0xee, 0x6c, 0xac, 0x20, 0x1a, 0x8b, 0x72, 0x8a, 0x38, 0x4e, 0x66, 0x38, 0x90, 0x84, 0x7d, 0xfd, 0x4d, 0xe7, 0xfa, 0x76}, - output512: []byte{0x4b, 0x96, 0x1c, 0x4b, 0xb6, 0x3, 0x5e, 0x7b, 0xdd, 0xa2, 0xe1, 0xa3, 0xb6, 0xf9, 0xcd, 0x52, 0xd1, 0x78, 0x98, 0x66, 0x4, 0x4c, 0x4a, 0x92, 0x56, 0x93, 0xbe, 0xa8, 0x8f, 0x65, 0xd0, 0x46, 0x23, 0x8b, 0xbe, 0xb4, 0xe7, 0xd3, 0xb0, 0x60, 0xe4, 0x72, 0x88, 0x4, 0x14, 0x7, 0x39, 0x2b, 0x29, 0x1a, 0xe6, 0x10, 0xba, 0x70, 0xd6, 0xb4, 0xd6, 0x4e, 0x74, 0xe7, 0xa7, 0xd0, 0x25, 0x6f}, - }, - { - msg: []byte{0xb6, 0x13, 0x4f, 0x9c, 0x3e, 0x91, 0xdd, 0x80, 0x0, 0x74, 0xd, 0x0, 0x9d, 0xd8, 0x6, 0x24, 0x8, 0x11, 0xd5, 0x1a, 0xb1, 0x54, 0x6a, 0x97, 0x4b, 0xcb, 0x18, 0xd3, 0x44, 0x64, 0x2b, 0xaa, 0x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x56, 0x6d, 0xc0, 0xe9, 0x5b, 0x17, 0xac, 0x83, 0x4f, 0x1e, 0x9e, 0x3d, 0xad}, - output256: []byte{0xcf, 0x90, 0x60, 0xaf, 0x3e, 0x4e, 0xd4, 0x73, 0x16, 0xac, 0xf5, 0x1e, 0x5b, 0x92, 0x12, 0x3c, 0xdc, 0x48, 0x27, 0xbd, 0x4a, 0xef, 0x99, 0x15, 0x88, 0xdc, 0xd8, 0x7, 0x8b, 0x9e, 0xea, 0x40}, - output384: []byte{0xf0, 0x3f, 0xa0, 0x3e, 0x4c, 0xf9, 0xc2, 0x34, 0x43, 0xd7, 0xdb, 0xdb, 0xb6, 0x6d, 0x9a, 0xbb, 0xaf, 0xef, 0xb6, 0x50, 0x1, 0x43, 0xff, 0xb, 0xfb, 0x5d, 0x7d, 0x6c, 0xa2, 0xbf, 0x1d, 0x7c, 0xd0, 0x43, 0xa7, 0xba, 0x7e, 0xfb, 0x48, 0xf1, 0x5e, 0xbc, 0x68, 0xd1, 0xf9, 0x45, 0x98, 0xe7}, - output512: []byte{0xc0, 0x51, 0x5b, 0x65, 0xb6, 0x40, 0xb3, 0xff, 0xd0, 0xa1, 0x58, 0x2a, 0x54, 0xf4, 0xc8, 0xfb, 0x35, 0xc1, 0x9, 0xb7, 0xfb, 0x47, 0x26, 0x66, 0xe0, 0x43, 0xd3, 0xc0, 0xa, 0xe3, 0xe0, 0xe0, 0xfa, 0x15, 0x6c, 0x4c, 0xef, 0xb4, 0x6b, 0x5b, 0x7b, 0x4c, 0xe, 0x48, 0x6, 0x23, 0xe1, 0xa2, 0x60, 0x18, 0xbd, 0xae, 0xdc, 0x3e, 0x27, 0xd9, 0xc0, 0xd4, 0x4c, 0x3e, 0x1d, 0x86, 0x20, 0x15}, - }, - { - msg: []byte{0xc9, 0x41, 0xcd, 0xb9, 0xc2, 0x8a, 0xb0, 0xa7, 0x91, 0xf2, 0xe5, 0xc8, 0xe8, 0xbb, 0x52, 0x85, 0x6, 0x26, 0xaa, 0x89, 0x20, 0x5b, 0xec, 0x3a, 0x7e, 0x22, 0x68, 0x23, 0x13, 0xd1, 0x98, 0xb1, 0xfa, 0x33, 0xfc, 0x72, 0x95, 0x38, 0x13, 0x54, 0x85, 0x87, 0x58, 0xae, 0x6c, 0x8e, 0xc6, 0xfa, 0xc3, 0x24, 0x5c, 0x6e, 0x45, 0x4d, 0x16, 0xfa, 0x2f, 0x51, 0xc4, 0x16, 0x6f, 0xab, 0x51, 0xdf, 0x27, 0x28, 0x58, 0xf2, 0xd6, 0x3, 0x77, 0xc, 0x40, 0x98, 0x7f, 0x64, 0x44, 0x2d, 0x48, 0x7a, 0xf4, 0x9c, 0xd5, 0xc3, 0x99, 0x1c, 0xe8, 0x58, 0xea, 0x2a, 0x60, 0xda, 0xb6, 0xa6, 0x5a, 0x34, 0x41, 0x49, 0x65, 0x93, 0x39, 0x73, 0xac, 0x24, 0x57, 0x8, 0x9e, 0x35, 0x91, 0x60, 0xb7, 0xcd, 0xed, 0xc4, 0x2f, 0x29, 0xe1, 0xa, 0x91, 0x92, 0x17, 0x85, 0xf6, 0xb7, 0x22, 0x4e, 0xe0, 0xb3, 0x49, 0x39, 0x3c, 0xdc, 0xff, 0x61, 0x51, 0xb5, 0xb, 0x37, 0x7d, 0x60, 0x95, 0x59, 0x92, 0x3d, 0x9, 0x84, 0xcd, 0xa6, 0x0, 0x8, 0x29, 0xb9, 0x16, 0xab, 0x68, 0x96, 0x69, 0x3e, 0xf6, 0xa2, 0x19, 0x9b, 0x3c, 0x22, 0xf7, 0xdc, 0x55, 0x0, 0xa1, 0x5b, 0x82, 0x58, 0x42, 0xe, 0x31, 0x4c, 0x22, 0x2b, 0xc0, 0x0, 0xbc, 0x4e, 0x54, 0x13, 0xe6, 0xdd, 0x82, 0xc9, 0x93, 0xf8, 0x33, 0xf, 0x5c, 0x6d, 0x1b, 0xe4, 0xbc, 0x79, 0xf0, 0x8a, 0x1a, 0xa, 0x46}, - output224: []byte{0xc6, 0xac, 0x9d, 0x54, 0x64, 0x85, 0x5e, 0x5c, 0x2f, 0x83, 0xf2, 0xa5, 0x6f, 0x9a, 0x99, 0x21, 0x37, 0xda, 0x47, 0xec, 0x5, 0xc5, 0x41, 0x29, 0x5f, 0x8c, 0x43, 0xe7}, - output256: []byte{0x63, 0xe4, 0x7, 0x30, 0xf, 0x99, 0xff, 0x23, 0x60, 0xf0, 0x2a, 0xae, 0xa, 0xda, 0x35, 0xf6, 0xc1, 0xa9, 0xa, 0xed, 0x2c, 0x63, 0x28, 0x2b, 0x23, 0xa7, 0x99, 0xb, 0xae, 0x30, 0x72, 0x54}, - output384: []byte{0x9c, 0x77, 0x9d, 0x98, 0x1f, 0x9b, 0x7e, 0x49, 0x1f, 0xf8, 0x68, 0xbe, 0x22, 0xb3, 0x7f, 0xa9, 0xdf, 0x72, 0xde, 0x55, 0x67, 0x2a, 0x2, 0x26, 0xa8, 0x21, 0xb2, 0x9c, 0x4, 0x5d, 0xf4, 0xff, 0x78, 0x8f, 0xa7, 0x27, 0x1d, 0x55, 0x7e, 0xf6, 0x2, 0x5e, 0xea, 0x25, 0x58, 0x9, 0xf2, 0x41}, - output512: []byte{0x45, 0xc5, 0x84, 0x56, 0x4d, 0x9e, 0xb, 0x82, 0x39, 0xcc, 0x12, 0x84, 0x93, 0x9b, 0xa4, 0x7, 0xa8, 0xe5, 0xe9, 0x81, 0x69, 0x1e, 0xab, 0x6a, 0x4, 0xd9, 0x35, 0x4c, 0x9c, 0x85, 0x5e, 0x40, 0xb, 0x30, 0x37, 0x15, 0x11, 0x22, 0xce, 0xd2, 0x37, 0x63, 0x6e, 0x61, 0xa7, 0xff, 0x29, 0x5, 0xe0, 0x21, 0x3a, 0x6d, 0x7, 0x30, 0x6c, 0x45, 0x9e, 0x21, 0x89, 0xe3, 0xe6, 0xa9, 0xe0, 0xb8}, - }, - { - msg: []byte{0x44, 0x99, 0xef, 0xff, 0xac, 0x4b, 0xce, 0xa5, 0x27, 0x47, 0xef, 0xd1, 0xe4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, 0x86, 0x47, 0xd0, 0x43}, - output224: []byte{0x4e, 0xe2, 0xf9, 0x3c, 0x18, 0x97, 0x4d, 0x97, 0x8d, 0xd3, 0xa1, 0xcb, 0xf8, 0xb1, 0xda, 0xc4, 0x73, 0x80, 0x70, 0x67, 0xb8, 0x80, 0x7d, 0x2, 0x61, 0x82, 0xb9, 0x1}, - output256: []byte{0x42, 0x77, 0x41, 0x57, 0xd, 0x5e, 0x21, 0x59, 0xe, 0x50, 0x45, 0xa8, 0x45, 0x2, 0x16, 0x36, 0x5b, 0xa9, 0x5c, 0x2e, 0x72, 0x45, 0x5a, 0x3d, 0xbd, 0x69, 0x4f, 0x13, 0x15, 0x5d, 0xe1, 0xb7}, - output384: []byte{0x2c, 0xb, 0xc5, 0x4a, 0x67, 0xb0, 0xa, 0xd7, 0x3, 0xfc, 0x59, 0x57, 0x51, 0x7, 0x4c, 0x4e, 0x44, 0x7e, 0xfd, 0xe0, 0xc, 0xaa, 0xf8, 0xc8, 0xfc, 0xad, 0xf5, 0x76, 0x8c, 0x33, 0xb, 0x6c, 0x7f, 0x19, 0x18, 0xf0, 0x44, 0xf5, 0xc5, 0xc5, 0x58, 0x10, 0xd0, 0x78, 0x53, 0x4a, 0x7b, 0xb3}, - output512: []byte{0x13, 0x67, 0x23, 0x35, 0x8, 0x57, 0xe0, 0x37, 0x56, 0xf0, 0x2e, 0x60, 0x45, 0x1a, 0x28, 0xe7, 0x11, 0x61, 0x19, 0x27, 0xb8, 0x13, 0x6d, 0xcf, 0xf3, 0xe5, 0x67, 0xdc, 0x61, 0x8f, 0xf3, 0x6b, 0x31, 0x0, 0x73, 0x7c, 0x97, 0x81, 0xb9, 0xc8, 0x4a, 0x57, 0x67, 0x45, 0xc1, 0xe6, 0xbe, 0x3, 0xd, 0xac, 0x88, 0x3, 0xa7, 0x14, 0x64, 0xaf, 0x39, 0xdb, 0x94, 0xd0, 0x2, 0x53, 0xaf, 0x3e}, - }, - { - msg: []byte{0xee, 0xcb, 0xb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xa5, 0x35, 0x35, 0xab, 0x2f, 0x23, 0x15, 0x90, 0xbf, 0x2c, 0x40, 0x62, 0xfd, 0x2a, 0xd5, 0x8f, 0x90, 0x6a, 0x2d, 0xd}, - output224: []byte{0xd6, 0x4a, 0xee, 0x17, 0xed, 0x8e, 0x2b, 0x85, 0xe6, 0xb0, 0x97, 0xdb, 0x49, 0x55, 0x4d, 0x35, 0x6f, 0x3, 0x2a, 0x34, 0xa1, 0x5b, 0x7e, 0x84, 0x4e, 0xc8, 0xd8, 0x89}, - output256: []byte{0xb5, 0xe6, 0xa, 0x1, 0x9e, 0x84, 0x14, 0xd4, 0x70, 0xae, 0x70, 0x27, 0x38, 0xbc, 0x35, 0x8f, 0x1c, 0x80, 0xbb, 0x6f, 0xf7, 0xbd, 0xe4, 0xf2, 0xdb, 0xb5, 0x6c, 0x29, 0x9c, 0x76, 0x4b, 0x16}, - output384: []byte{0x2d, 0xb1, 0x9c, 0xa5, 0x57, 0x72, 0x3c, 0xd3, 0xc1, 0x7e, 0x7d, 0x81, 0x40, 0xca, 0x30, 0x1a, 0x5a, 0x2c, 0xb7, 0x7e, 0x3f, 0x1f, 0x59, 0x5f, 0x5b, 0x85, 0xa, 0x78, 0x94, 0x3c, 0x7f, 0x36, 0xfc, 0x37, 0x5, 0x6d, 0xcf, 0x2b, 0xad, 0xb9, 0xd, 0xda, 0x77, 0xbf, 0xa9, 0x69, 0xc0, 0xaa}, - output512: []byte{0xc0, 0xf7, 0x71, 0x3a, 0xa0, 0x21, 0xa0, 0x45, 0x25, 0xf7, 0x51, 0x72, 0x2a, 0x9a, 0xe5, 0xc4, 0xc7, 0x93, 0x4d, 0xa, 0x28, 0x6f, 0x1f, 0xb0, 0x58, 0x23, 0xd8, 0x6a, 0x96, 0x25, 0x1c, 0x4, 0xde, 0xcd, 0x96, 0xd, 0x8d, 0x4d, 0x66, 0xe2, 0xc5, 0x65, 0xe6, 0x20, 0x7a, 0x49, 0x61, 0x2e, 0x1e, 0xfd, 0x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x6, 0x1f, 0x4a, 0x81, 0xfa, 0xc8, 0x34, 0x47, 0x1e, 0xc, 0x59, 0x55, 0x3f, 0x10, 0x84, 0x75, 0xfe, 0x29, 0xd, 0x43, 0xe6, 0xa0, 0x55, 0xae, 0x3e, 0xe4, 0x6f, 0xb6, 0x74, 0x22, 0xf8, 0x14, 0xa6, 0x8c, 0x4b, 0xe3, 0xe8, 0xc9}, - output224: []byte{0x1b, 0xdd, 0xc9, 0x2b, 0xe8, 0x9a, 0x67, 0x2c, 0x1b, 0xd9, 0x56, 0xb4, 0x50, 0xb9, 0xd7, 0xb4, 0x7b, 0x4b, 0xb0, 0xbc, 0x58, 0xac, 0x51, 0xf1, 0x5f, 0x7e, 0x5, 0x4d}, - output256: []byte{0xc9, 0x86, 0xbd, 0xae, 0x9b, 0x13, 0xfb, 0xc9, 0x27, 0x93, 0x61, 0x9e, 0x49, 0x70, 0xab, 0xc3, 0x33, 0x98, 0xf2, 0xb5, 0xa5, 0x7a, 0x6c, 0xbb, 0x40, 0xa6, 0x22, 0x59, 0x2e, 0x26, 0x95, 0xdf}, - output384: []byte{0x71, 0xe5, 0xdd, 0x7, 0x55, 0xcf, 0x8b, 0x82, 0xbc, 0x79, 0xae, 0xd6, 0xfb, 0x61, 0xc9, 0xe4, 0xff, 0x83, 0x61, 0xc9, 0xaf, 0xc5, 0xad, 0x98, 0x8, 0x8, 0xa8, 0xbc, 0x48, 0xe, 0x9, 0xd5, 0x9b, 0x23, 0x40, 0x74, 0x47, 0x28, 0x51, 0x8, 0x7, 0x14, 0xe0, 0x27, 0x5c, 0xe7, 0x2d, 0xc5}, - output512: []byte{0xfe, 0x1c, 0xb6, 0x7d, 0x77, 0xfb, 0x46, 0x3f, 0x77, 0x74, 0x7f, 0xed, 0x29, 0x2a, 0x98, 0x9a, 0x34, 0x10, 0x44, 0xa8, 0xb6, 0x5f, 0xa1, 0xdf, 0x14, 0x41, 0xaa, 0x41, 0xa5, 0xc7, 0x95, 0x91, 0x66, 0x26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 0xbb, 0xe5, 0x78, 0xff, 0x45, 0x19, 0x84, 0x4d, 0xb3, 0x60, 0xe0, 0xa9, 0x6c, 0x67, 0x1, 0x29, 0xe, 0x76, 0xbb, 0x95, 0xd2, 0x6f, 0xf, 0x80, 0x4c, 0x8a, 0x4f, 0x27, 0x17, 0xea, 0xc4, 0xe7, 0xde, 0x9f, 0x2c, 0xff, 0x3b, 0xbc, 0x55, 0xa1, 0x7e, 0x77, 0x6c, 0xd, 0x2, 0x85, 0x60, 0x32, 0xa6, 0xcd, 0x10, 0xad, 0x28, 0x38}, - output224: []byte{0xc, 0x8a, 0xc2, 0x40, 0x17, 0xc, 0x65, 0x46, 0xde, 0xbf, 0x4b, 0xfb, 0x5b, 0x38, 0xf8, 0xf3, 0xe, 0xa5, 0xdc, 0x6e, 0xf8, 0x6c, 0x16, 0x6e, 0x8e, 0x13, 0x6d, 0x6b}, - output256: []byte{0x22, 0x4c, 0x7f, 0xc8, 0xa0, 0xec, 0x38, 0x95, 0xe8, 0x96, 0x9c, 0xe7, 0xc7, 0xf7, 0xec, 0xaa, 0x54, 0xfe, 0x2e, 0xec, 0x9a, 0xb3, 0x12, 0x7, 0x26, 0x10, 0x6f, 0x22, 0xaa, 0x29, 0x75, 0x41}, - output384: []byte{0x51, 0xf9, 0x51, 0xb8, 0xf1, 0x1, 0x3b, 0xa9, 0xbc, 0xed, 0x90, 0x47, 0x8e, 0x24, 0x8c, 0xd8, 0x9d, 0x4d, 0xeb, 0xc6, 0xa1, 0x9c, 0xeb, 0x6e, 0xf8, 0x1b, 0xa1, 0xa5, 0xd8, 0xd3, 0x33, 0x9d, 0x42, 0x6d, 0x50, 0xa9, 0x4c, 0x7c, 0xe3, 0xd1, 0x43, 0xc4, 0x5d, 0xec, 0xce, 0xf9, 0x49, 0x65}, - output512: []byte{0x40, 0x43, 0xcd, 0xd3, 0xf0, 0xea, 0x79, 0x3e, 0x49, 0xa8, 0xec, 0x38, 0x2f, 0x80, 0x71, 0xf6, 0x2,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5, 0x77, 0x75, 0xe, 0x3e, 0xfb, 0xd3, 0x70, 0xe8, 0xa8, 0xca, 0xc1, 0x58, 0x25, 0x81, 0x97, 0x1f, 0xba, 0x3b, 0xa4, 0xbd, 0xd, 0x76, 0xe7, 0x18, 0xda, 0xcf, 0x84, 0x33, 0xd3, 0x3a, 0x59, 0xd2, 0x87, 0xf8, 0xcc, 0x92, 0x23, 0x4e, 0x7a, 0x27, 0x10, 0x41, 0xb5, 0x26, 0xe3, 0x89, 0xef, 0xb0, 0xe4, 0xb, 0x6a, 0x18, 0xb3, 0xaa, 0xf6, 0x58, 0xe8, 0x2e, 0xd1, 0xc7, 0x86, 0x31, 0xfd, 0x23, 0xb4, 0xc3, 0xeb, 0x27, 0xc3, 0xfa, 0xec, 0x86, 0x85}, - output224: []byte{0x2f, 0xd9, 0xfd, 0xfd, 0x24, 0x4b, 0xa, 0x73, 0x42, 0xf8, 0x86, 0xb8, 0x7b, 0x3d, 0xdd, 0xce, 0x54, 0xc8, 0x87, 0xf, 0xb2, 0x6a, 0x71, 0xa8, 0xf6, 0x52, 0x2, 0x31}, - output256: []byte{0xfa, 0xf5, 0xe3, 0xb7, 0xa6, 0x46, 0x29, 0xff, 0xee, 0xe0, 0x7a, 0x67, 0xed, 0x77, 0xa3, 0xa4, 0xf6, 0x7f, 0x18, 0xc9, 0x38, 0x1f, 0xe9, 0xb1, 0x9f, 0x6e, 0xe6, 0x1, 0xf5, 0xfb, 0x99, 0xaf}, - output384: []byte{0x21, 0xe, 0xbc, 0x15, 0x56, 0xe3, 0x1a, 0x27, 0xea, 0xf6, 0xa, 0x5f, 0xe3, 0xe1, 0x81, 0x13, 0x5c, 0x5e, 0xa1, 0x17, 0xe3, 0xff, 0x21, 0xaf, 0x2d, 0x4, 0xbe, 0xab, 0x9a, 0x24, 0x3f, 0xff, 0xf6, 0x32, 0xe3, 0xd7, 0x77, 0x8f, 0x9a, 0x6d, 0x3, 0x4, 0xc1, 0xac, 0xf3, 0x65, 0x9a, 0x3c}, - output512: []byte{0x73, 0x92, 0xbd, 0x44, 0x5f, 0x58, 0xcd, 0x5d, 0x7d, 0x3c, 0xa9, 0x85, 0x79, 0xcb, 0xaa, 0x9a, 0x94, 0x37, 0xd0, 0xc9, 0x5e, 0x79, 0x32, 0xb4, 0x0, 0x41, 0x17, 0xf2, 0x7, 0xf8, 0xaa, 0x39, 0x15, 0x6b, 0xc4, 0x25, 0x37, 0xb0, 0xc7, 0x90, 0x15, 0xd, 0x44, 0x3c, 0x2d, 0x68, 0xc2, 0xc4, 0x3e, 0x36, 0x2d, 0xf9, 0xd0, 0x19, 0x60, 0x17, 0x97, 0x16, 0x2e, 0x63, 0x7, 0x69, 0x36, 0xc3}, - }, - { - msg: []byte{0x44, 0x77, 0x97, 0xe2, 0x89, 0x9b, 0x72, 0xa3, 0x56, 0xba, 0x55, 0xbf, 0x4d, 0xf3, 0xac, 0xca, 0x6c, 0xdb, 0x10, 0x41, 0xeb, 0x47, 0x7b, 0xd1, 0x83, 0x4a, 0x9f, 0x9a, 0xcb, 0xc3, 0x40, 0xa2, 0x94, 0xd7, 0x29, 0xf2, 0xf9, 0x7d, 0xf3, 0xa6, 0x10, 0xbe, 0xf, 0xf1, 0x5e, 0xdb, 0x9c, 0x6d, 0x5d, 0xb4, 0x16, 0x44, 0xb9, 0x87, 0x43, 0x60, 0x14, 0xf, 0xc6, 0x4f, 0x52, 0xaa, 0x3, 0xf0, 0x28, 0x6c, 0x8a, 0x64, 0x6, 0x70, 0x6, 0x7a, 0x84, 0xe0, 0x17, 0x92, 0x6a, 0x70, 0x43, 0x8d, 0xb1, 0xbb, 0x36, 0x1d, 0xef, 0xee, 0x73, 0x17, 0x2, 0x14, 0x25, 0xf8, 0x82, 0x1d, 0xef, 0x26, 0xd1, 0xef, 0xd7, 0x7f, 0xc8, 0x53, 0xb8, 0x18, 0x54, 0x5d, 0x5, 0x5a, 0xdc, 0x92, 0x84, 0x79, 0x6e, 0x58, 0x3c, 0x76, 0xe6, 0xfe, 0x74, 0xc9, 0xac, 0x25, 0x87, 0xaa, 0x46, 0xaa, 0x8f, 0x88, 0x4, 0xf2, 0xfe, 0xb5, 0x83, 0x6c, 0xc4, 0xb3, 0xab, 0xab, 0xab, 0x84, 0x29, 0xa5, 0x78, 0x3e, 0x17, 0xd5, 0x99, 0x9f, 0x32, 0x24, 0x2e, 0xb5, 0x9e, 0xf3, 0xc, 0xd7, 0xad, 0xab, 0xc1, 0x6d, 0x72, 0xdb, 0xdb, 0x9, 0x76, 0x23, 0x4, 0x7c, 0x98, 0x98, 0x9f, 0x88, 0xd1, 0x4e, 0xaf, 0x2, 0xa7, 0x21, 0x2b, 0xe1, 0x6e, 0xc2, 0xd0, 0x79, 0x81, 0xaa, 0xa9, 0x99, 0x49, 0xdd, 0xf8, 0x9e, 0xcd, 0x90, 0x33, 0x3a, 0x77, 0xbc, 0x4e, 0x19, 0x88, 0xa8, 0x2a, 0xbf, 0x7c, 0x7c, 0xaf, 0x32, 0x91}, - output224: []byte{0x1b, 0x6b, 0xe1, 0x9d, 0x72, 0x19, 0x9b, 0xf7, 0x5f, 0xd4, 0x7, 0x5e, 0x54, 0x97, 0x5a, 0xfa, 0x4, 0x33, 0xb9, 0xbf, 0x51, 0x5b, 0xd3, 0x0, 0xce, 0x54, 0x3d, 0x41}, - output256: []byte{0xa8, 0xa9, 0x8e, 0x6b, 0x3a, 0x0, 0x5f, 0xcb, 0x31, 0x9f, 0xee, 0x58, 0xc5, 0x45, 0x7d, 0x4, 0xb6, 0x9d, 0x59, 0xf5, 0x38, 0x73, 0xf6, 0xfc, 0xc6, 0x6, 0x5d, 0x68, 0xf8, 0x80, 0x83, 0x3f}, - output384: []byte{0xf5, 0xf6, 0x59, 0xf6, 0x99, 0x9b, 0xad, 0x8c, 0xdc, 0x77, 0xc4, 0x29, 0x1, 0xa8, 0xd6, 0x4c, 0x1f, 0xa8, 0x27, 0xf7, 0x84, 0x89, 0x85, 0x13, 0x61, 0x40, 0xbf, 0x5d, 0x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, 0xb3, 0xc2, 0xd, 0x32, 0x74, 0x3f, 0x40, 0x26, 0xb5, 0x9a, 0x4c, 0xcc, 0x38, 0x5a, 0x23, 0x1, 0xf8, 0x3c, 0xb, 0xa, 0x19, 0xb, 0xf, 0x2d, 0x1, 0xac, 0xb8, 0xf0, 0xd4, 0x11, 0x11, 0xe1, 0xf, 0x2f, 0x4e, 0x14, 0x93, 0x79, 0x27, 0x55, 0x99, 0xa5, 0x2d, 0xc0, 0x89, 0xb3, 0x5f, 0xdd, 0x52, 0x34, 0xb0, 0xcf, 0xb7, 0xb6, 0xd8, 0xae, 0xbd, 0x56, 0x3c, 0xa1, 0xfa, 0x65, 0x3c, 0x5c, 0x2, 0x1d, 0xfd, 0x6f, 0x59, 0x20, 0xe6, 0xf1, 0x8b, 0xfa, 0xfd, 0xbe, 0xcb, 0xf0, 0xab, 0x0, 0x28, 0x13, 0x33, 0xed, 0x50, 0xb9, 0xa9, 0x99, 0x54, 0x9c, 0x1c, 0x8f, 0x8c, 0x63, 0xd7, 0x62, 0x6c, 0x48, 0x32, 0x2e, 0x97, 0x91, 0xd5, 0xff, 0x72, 0x29, 0x40, 0x49, 0xbd, 0xe9, 0x1e, 0x73, 0xf8}, - output224: []byte{0xa4, 0x6b, 0x89, 0xb6, 0x4b, 0xc, 0x79, 0x30, 0xdd, 0x45, 0xf5, 0xb2, 0x58, 0x2f, 0xd7, 0x9c, 0x7a, 0xd9, 0xa, 0x58, 0xc9, 0x4c, 0x52, 0xf9, 0xbf, 0xa5, 0x5c, 0xfc}, - output256: []byte{0xc8, 0x9f, 0x2b, 0x34, 0x61, 0x27, 0xea, 0xb9, 0xe2, 0x80, 0x95, 0xdc, 0x44, 0x91, 0x8c, 0x1a, 0x1a, 0xae, 0xae, 0x4, 0x86, 0x1c, 0x1d, 0xd0, 0x14, 0x4a, 0x1e, 0xe0, 0x7f, 0x82, 0x3c, 0x18}, - output384: []byte{0xb1, 0x51, 0xbf, 0x98, 0xc5, 0x2f, 0x63,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 0xcf, 0xf9, 0xac, 0xf4, 0x1f, 0x2c, 0x8a, 0xdd, 0x28, 0x74, 0x36, 0x88, 0xae, 0x1}, - output384: []byte{0x47, 0xd7, 0x4f, 0xdd, 0x9a, 0x19, 0xa5, 0x38, 0x93, 0x13, 0x61, 0x6, 0x43, 0xfa, 0x85, 0x9f, 0xf0, 0xbd, 0x7b, 0x58, 0x3b, 0x9, 0x9f, 0xdd, 0xb9, 0xc9, 0x80, 0xdc, 0xc0, 0x0, 0xaf, 0xeb, 0x63, 0x9d, 0xd9, 0x90, 0x71, 0xea, 0x31, 0x97, 0x6d, 0xa3, 0x5b, 0x7b, 0xc9, 0x49, 0xbd, 0x4e}, - output512: []byte{0x89, 0x2, 0x5c, 0x13, 0xbc, 0x6b, 0x61, 0xa1, 0xbf, 0xad, 0xb1, 0xd3, 0x7d, 0x67, 0x6e, 0x49, 0xe6, 0x75, 0x4e, 0x9d, 0xfc, 0x0, 0xd5, 0x2c, 0x5e, 0xf1, 0x3b, 0xa5, 0x7c, 0x84, 0x5d, 0x14, 0xac, 0x75, 0xd5, 0xae, 0x6f, 0x6, 0x71, 0x40, 0x28, 0x10, 0x3c, 0x34, 0x24, 0x71, 0x7f, 0x4c, 0x2f, 0xbf, 0x6d, 0x88, 0xd0, 0x55, 0x69, 0x9, 0x87, 0x62, 0xa, 0xc5, 0xb4, 0x40, 0x57, 0x6a}, - }, - { - msg: []byte{0x3b, 0x8e, 0x97, 0xc5, 0xff, 0xc2, 0xd6, 0xa4, 0xf, 0xa7, 0xde, 0x7f, 0xce, 0xfc, 0x90, 0xf3, 0xb1, 0x2c, 0x94, 0xe, 0x7a, 0xb4, 0x15, 0x32, 0x1e, 0x29, 0xee, 0x69, 0x2d, 0xfa, 0xc7, 0x99, 0xb0, 0x9, 0xc9, 0x9d, 0xcd, 0xdb, 0x70, 0x8f, 0xce, 0x5a, 0x17, 0x8c, 0x5c, 0x35, 0xee, 0x2b, 0x86, 0x17, 0x14, 0x3e, 0xdc, 0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x21, 0xf, 0x8f, 0xea, 0x57}, - output256: []byte{0xd8, 0x12, 0x49, 0x14, 0x3a, 0x69, 0xea, 0x1c, 0x9d, 0xc1, 0x68, 0xb5, 0x5f, 0xfe, 0x6, 0xd4, 0x6d, 0xf, 0xbc, 0x0, 0x70, 0x65, 0x11, 0x3, 0x53, 0xd7, 0x6c, 0x6c, 0xce, 0x4f, 0xfe, 0x66}, - output384: []byte{0x9b, 0x80, 0x91, 0x98, 0xdc, 0xce, 0x24, 0x17, 0x5e, 0x33, 0x9, 0x83, 0x31, 0xd3, 0xa4, 0x2, 0xa8, 0x21, 0xae, 0x93, 0x26, 0xe7, 0x27, 0x75, 0xaa, 0xe3, 0x4d, 0x1a, 0x9b, 0xb5, 0x3d, 0x2b, 0x57, 0x86, 0x39, 0x5, 0xcf, 0xd6, 0x5, 0x43, 0xbb, 0xc4, 0x2b, 0x45, 0x40, 0x7, 0xc3, 0x15}, - output512: []byte{0x15, 0x45, 0xd8, 0x33, 0x48, 0x36, 0xf7, 0x43, 0x6f, 0x77, 0xf2, 0x15, 0x32, 0xf5, 0xd3, 0x5, 0x8e, 0x35, 0x1d, 0xb8, 0x35, 0x7e, 0xfc, 0x1e, 0x8, 0x95, 0x83, 0xa0, 0xc4, 0xa, 0xd3, 0xa6, 0xaf, 0x5f, 0x2f, 0xee, 0x79, 0x3d, 0x3f, 0xe1, 0xb4, 0x72, 0x1f, 0x68, 0x17, 0xa3, 0x73, 0x49, 0x9b, 0x20, 0x91, 0x2a, 0x35, 0xc4, 0x60, 0x9f, 0xa9, 0xd8, 0x4b, 0xd2, 0x74, 0xe9, 0x78, 0xfc}, - }, - { - msg: []byte{0x34, 0x34, 0xec, 0x31, 0xb1, 0xf, 0xaf, 0xdb, 0xfe, 0xec, 0xd, 0xd6, 0xbd, 0x94, 0xe8, 0xf, 0x7b, 0xa9, 0xdc, 0xa1, 0x9e, 0xf0, 0x75, 0xf7, 0xeb, 0x1, 0x75, 0x12, 0xaf, 0x66, 0xd6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x27, 0x8d, 0xd8, 0xa3, 0xf3, 0x20, 0x81, 0x91, 0xcf, 0xf6, 0x58, 0xb8, 0xd6, 0xdb, 0x35, 0xe1, 0x33, 0xa1, 0x6e, 0x47, 0xaa, 0x37, 0x5e, 0xdb, 0x92, 0xc6, 0xa7, 0x37}, - output256: []byte{0xaa, 0x8b, 0xbd, 0x48, 0x12, 0x14, 0x22, 0x11, 0x21, 0x27, 0x63, 0xbf, 0x8e, 0xe4, 0xd6, 0xe0, 0xaa, 0xda, 0xfe, 0x5e, 0x52, 0x8a, 0xea, 0x1f, 0xb1, 0xbe, 0x11, 0x88, 0x6, 0xe4, 0x9f, 0x66}, - output384: []byte{0x93, 0xc9, 0x83, 0x45, 0x1, 0xfc, 0x72, 0x85, 0x8, 0xa1, 0x5e, 0xb9, 0x20, 0x5e, 0x67, 0x89, 0x83, 0xf3, 0xbd, 0xb0, 0xba, 0x44, 0x7e, 0xe7, 0x39, 0xae, 0x50, 0x82, 0xdb, 0x37, 0xf2, 0xf2, 0xd4, 0x85, 0x8, 0x81, 0x30, 0xe0, 0xb1, 0xcb, 0xf0, 0x3, 0x9d, 0x18, 0xbd, 0xf4, 0x29, 0xf7}, - output512: []byte{0xaf, 0xaf, 0x20, 0x1b, 0xa3, 0x53, 0x31, 0x6c, 0x1a, 0x7b, 0x81, 0xf, 0x12, 0xc, 0xff, 0x94, 0x1b, 0xb6, 0x58, 0xb0, 0x76, 0x3e, 0xef, 0x59, 0x43, 0x34, 0x3, 0xd8, 0x31, 0x3b, 0x8f, 0x0, 0xbf, 0x18, 0x17, 0x78, 0x98, 0xae, 0x71, 0x90, 0x7d, 0x3b, 0x52, 0x4e, 0x68, 0xbb, 0x2, 0x8e, 0xa1, 0x44, 0x28, 0x66, 0x85, 0x61, 0x11, 0xb1, 0x20, 0x89, 0xbc, 0xbe, 0xd1, 0x77, 0xfd, 0x46}, - }, - { - msg: []byte{0x7c, 0x79, 0x53, 0xd8, 0x1c, 0x8d, 0x20, 0x8f, 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14, 0x98, 0xcc, 0x95, 0xf0, 0x71, 0x22, 0x84, 0x60, 0xc7, 0xc5, 0xd5, 0xce, 0xb4, 0xa7, 0xbd, 0xe5, 0x88, 0xe7, 0xf2, 0x1c}, - output224: []byte{0xb5, 0x5, 0x27, 0x71, 0x1c, 0x4, 0x7d, 0xef, 0x70, 0xb1, 0x7c, 0xf2, 0xf, 0x97, 0xb, 0xed, 0x79, 0xc1, 0xc1, 0xb9, 0x52, 0x75, 0xc2, 0x78, 0x4c, 0x39, 0x3, 0xde}, - output256: []byte{0x40, 0x89, 0xb1, 0x81, 0xdf, 0x5e, 0xca, 0x5f, 0x14, 0xda, 0xb1, 0x5, 0x7a, 0xaa, 0xee, 0xca, 0xba, 0x15, 0xf2, 0x0, 0xfd, 0xda, 0xd, 0xe4, 0x93, 0x57, 0xd6, 0x19, 0x6f, 0xaa, 0xb4, 0x4b}, - output384: []byte{0xc0, 0xad, 0x8c, 0x3e, 0x7e, 0xa5, 0x95, 0x10, 0x4d, 0x4b, 0xc0, 0xa0, 0x8d, 0xcb, 0xc8, 0x50, 0x42, 0xed, 0x50, 0xdd, 0x8d, 0x9b, 0x1, 0xab, 0x47, 0xc9, 0xf0, 0x66, 0xf9, 0x1a, 0xd3, 0xbf, 0xfe, 0xde, 0x41, 0x7, 0xf1, 0xeb, 0x1f, 0x5b, 0x61, 0xca, 0x7d, 0x40, 0x91, 0xd6, 0x83, 0x27}, - output512: []byte{0x3f, 0xb4, 0xf2, 0x1a, 0x23, 0x19, 0x73, 0xd2, 0x24, 0x7f, 0x20, 0x6d, 0x47, 0xb1, 0x9e, 0xe1, 0x55, 0x16, 0x47, 0xfd, 0x4d, 0x4f, 0x21, 0xfb, 0xcd, 0x6f, 0x65, 0x35, 0x77, 0xc1, 0xac, 0x69, 0xea, 0xe4, 0xdb, 0x43, 0x2c, 0x2, 0x34, 0xac, 0xbe, 0x17, 0xb2, 0xce, 0xd0, 0x23, 0x8a, 0x56, 0xac, 0xc3, 0x4d, 0x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 0x52, 0x39, 0xbc, 0x1, 0x31, 0x5c, 0x46, 0xfd, 0xb6, 0x78, 0x87, 0x5b, 0x3c, 0x81, 0xe0, 0x53, 0xa4, 0xf, 0x58, 0x1c, 0xfb, 0xec, 0x24, 0xa1, 0x40, 0x4b, 0x16, 0x71, 0xa1, 0xb8, 0x8a, 0x6d, 0x6, 0x12, 0x2, 0x29, 0x51, 0x8f, 0xb1, 0x3a, 0x74, 0xca, 0xa, 0xc5, 0xae}, - output224: []byte{0xf7, 0x7c, 0xb5, 0x27, 0x52, 0x12, 0xc9, 0x2f, 0xa0, 0xda, 0xd9, 0x21, 0xb6, 0x5f, 0x50, 0x81, 0x48, 0x22, 0xe3, 0xd6, 0xd5, 0x84, 0xc8, 0x95, 0x28, 0x99, 0xf, 0x2}, - output256: []byte{0xde, 0xbf, 0x59, 0xbb, 0x23, 0x3d, 0x5, 0x54, 0x98, 0x53, 0x80, 0x4f, 0xc6, 0x78, 0x40, 0x82, 0x1b, 0xd5, 0x80, 0x2f, 0x87, 0xfc, 0x8a, 0x91, 0x5b, 0x71, 0xd, 0x3e, 0x82, 0x7, 0x9, 0x50}, - output384: []byte{0xaa, 0x8d, 0xaa, 0x2, 0xab, 0xcb, 0xc5, 0xa4, 0xb3, 0x0, 0x3b, 0xff, 0x5c, 0xbc, 0x2c, 0x84, 0x59, 0x4c, 0x5a, 0xf, 0x84, 0xbd, 0x44, 0x9a, 0x1a, 0x56, 0xbe, 0x59, 0x56, 0x6e, 0x13, 0xec, 0x68, 0x3, 0x1, 0xd, 0x42, 0x2a, 0x4c, 0x24, 0x4b, 0x99, 0x81, 0x2f, 0x45, 0x37, 0xc9, 0x3d}, - output512: []byte{0xb, 0x1c, 0x53, 0xe6, 0x86, 0x67, 0x31, 0x4b, 0x5f, 0x3f, 0xf, 0x30, 0xe2, 0x5c, 0x62, 0x2b, 0x1a, 0x86, 0xd1, 0x7, 0x1, 0xd4, 0xa0, 0x47, 0x3f, 0xd4, 0xf, 0x22, 0xc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x1, 0x7f, 0x34, 0x69, 0x75, 0xdb, 0x56, 0x6f, 0x9b, 0x4d, 0x13, 0x7f, 0x4e, 0xe1, 0x6, 0x44, 0xc2, 0xa2, 0xda, 0x66, 0xde, 0xec, 0xa5, 0x34, 0x2e, 0x23, 0x64, 0x95, 0xc3, 0xc6, 0x28, 0x5, 0x28, 0xbf, 0xd3, 0x2e, 0x90, 0xaf, 0x4c, 0xd9, 0xbb, 0x90, 0x8f, 0x34, 0x1, 0x2b, 0x52, 0xb4, 0xbc, 0x56, 0xd4, 0x8c, 0xc8, 0xa6, 0xb5, 0x9b, 0xab, 0x1, 0x49, 0x88, 0xea, 0xbd, 0x12, 0xe1, 0xa0, 0xa1, 0xc2, 0xe1, 0x70, 0xe7}, - output224: []byte{0x76, 0xca, 0x9e, 0x68, 0x5d, 0xfa, 0xdc, 0x67, 0x57, 0x6d, 0x44, 0xe8, 0xc1, 0xa8, 0x2e, 0x8c, 0xf7, 0xe9, 0x2f, 0xb0, 0xa8, 0x1f, 0xe4, 0x9e, 0x21, 0x10, 0x8e, 0x9}, - output256: []byte{0xf, 0xdb, 0xa1, 0xc7, 0x9f, 0x55, 0xf2, 0x33, 0xa1, 0x21, 0x7f, 0x52, 0x2d, 0x6c, 0x81, 0xf7, 0x77, 0xf3, 0x30, 0xfa, 0xdb, 0x56, 0x5e, 0x11, 0x71, 0xf3, 0x9e, 0x17, 0x88, 0x91, 0x33, 0x42}, - output384: []byte{0xca, 0xeb, 0x4f, 0x82, 0x9a, 0x92, 0x56, 0x79, 0x41, 0x6f, 0x7c, 0xb1, 0x77, 0xed, 0x4c, 0x99, 0x72, 0x1b, 0x85, 0x1a, 0xb5, 0x9d, 0x52, 0x97, 0x9b, 0xfe, 0xc6, 0xd2, 0xaa, 0xa1, 0xe6, 0x2, 0xf4, 0x31, 0xb, 0x15, 0x62, 0x4f, 0x9d, 0x7b, 0xf2, 0xd3, 0x51, 0xdb, 0x73, 0xbf, 0xb5, 0xea}, - output512: []byte{0xd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xa1, 0x45, 0x86, 0xf6, 0xba, 0x42, 0xf5, 0xfe, 0x30, 0xaf, 0xa8, 0xae, 0x40, 0xc5, 0xdf, 0x29, 0x96, 0x6f, 0x93, 0x46, 0xda, 0x5f, 0x8b, 0x35, 0xf1, 0x6a, 0x1d, 0xe3, 0xab, 0x6d, 0xe0, 0xf4, 0x77, 0xd8, 0xd8, 0x66, 0x9, 0x18, 0x6, 0xe, 0x88, 0xb9, 0xb9, 0xe9, 0xca, 0x6a, 0x42, 0x7, 0x3, 0x3b, 0x87, 0xa8, 0x12, 0xdb, 0xf5, 0x54, 0x4d, 0x39, 0xe4, 0x88, 0x20, 0x10, 0xf8, 0x2b, 0x6c, 0xe0, 0x5, 0xf8, 0xe8, 0xff, 0x6f, 0xe3, 0xc3, 0x80, 0x6b, 0xc2, 0xb7, 0x3c, 0x2b, 0x83, 0xaf, 0xb7, 0x4, 0x34, 0x56, 0x29, 0x30, 0x4f, 0x9f, 0x86, 0x35, 0x87, 0x12, 0xe9, 0xfa, 0xe3, 0xca, 0x3e}, - output224: []byte{0xab, 0xd3, 0x13, 0xbc, 0x70, 0xb7, 0xfa, 0xb0, 0xeb, 0xc1, 0x67, 0xd7, 0x39, 0xb5, 0x4c, 0x97, 0x38, 0x9e, 0x75, 0x2e, 0xe1, 0xa3, 0x13, 0xb1, 0x26, 0x73, 0xf5, 0x1c}, - output256: []byte{0xed, 0x45, 0xa0, 0x6e, 0x95, 0xa6, 0x53, 0x92, 0x70, 0xb0, 0x22, 0x90, 0xd7, 0x10, 0x5, 0xf0, 0x1c, 0x55, 0xba, 0x7, 0x74, 0x14, 0xc3, 0xbc, 0xdb, 0x37, 0x95, 0x37, 0xe6, 0xdb, 0xef, 0xc9}, - output384: []byte{0xfc, 0x1f, 0xc7, 0xf1, 0x9f, 0x6c, 0x9d, 0xa, 0xd1, 0x46, 0x2b, 0x24, 0xc1, 0x21, 0xc8, 0x9b, 0x1, 0xb4, 0xe0, 0x83, 0xed, 0xad, 0x2, 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xeb, 0x32, 0x5c, 0x78, 0xcc}, - output384: []byte{0x84, 0x80, 0x3e, 0x50, 0xde, 0xc9, 0x1, 0xff, 0x93, 0xc, 0x8a, 0x76, 0xeb, 0xc1, 0xf9, 0x8e, 0xc7, 0x28, 0x74, 0xde, 0xef, 0xd, 0x24, 0x90, 0x20, 0xb1, 0xdb, 0xeb, 0x4e, 0xa7, 0xd8, 0xc7, 0xda, 0x47, 0x61, 0xed, 0xe0, 0x77, 0x15, 0x84, 0x60, 0xe0, 0x54, 0xa7, 0xf7, 0x1d, 0x19, 0x94}, - output512: []byte{0xb8, 0x47, 0xb2, 0x92, 0x81, 0x8e, 0x80, 0xb, 0xaa, 0x41, 0x5c, 0x25, 0x21, 0xa8, 0x15, 0x8a, 0x6a, 0xb7, 0x49, 0x93, 0x4d, 0xb6, 0x93, 0xd0, 0xd2, 0xe4, 0x61, 0x3c, 0xda, 0xe6, 0xb, 0xd5, 0x60, 0x75, 0xcf, 0x2c, 0x29, 0xf5, 0x87, 0xdc, 0x35, 0x30, 0x16, 0x41, 0x90, 0xbc, 0x2c, 0x2, 0xd9, 0x7c, 0xa3, 0x23, 0x47, 0xfa, 0x2a, 0xa4, 0x31, 0xe5, 0x11, 0xbb, 0x7d, 0x1c, 0x87, 0xe8}, - }, - { - msg: []byte{0xc8, 0xe9, 0x76, 0xab, 0x46, 0x38, 0x90, 0x93, 0x87, 0xce, 0x3b, 0x8d, 0x4e, 0x51, 0xc, 0x32, 0x30, 0xe5, 0x69, 0xe, 0x2, 0xc4, 0x50, 0x93, 0xb1, 0xd2, 0x97, 0x91, 0xa, 0xbc, 0x48, 0x1e, 0x56, 0xee, 0xa0, 0xf2, 0x96, 0xf9, 0x83, 0x79, 0xdf, 0xc9, 0x8, 0xa, 0xf6, 0x9e, 0x73, 0xb2, 0x39, 0x9d, 0x1c, 0x14, 0x3b, 0xee, 0x80, 0xae, 0x13, 0x28, 0x16, 0x2c, 0xe1, 0xba, 0x7f, 0x6a, 0x83, 0x74, 0x67, 0x9b, 0x20, 0xaa, 0xcd, 0x38, 0xe, 0xb4, 0xe6, 0x13, 0x82, 0xc9, 0x99, 0x98, 0x70, 0x4d, 0x62, 0x70, 0x1a, 0xfa, 0x91, 0x4f, 0x9a, 0x27, 0x5, 0xcd, 0xb0, 0x65, 0x88, 0x5f, 0x50, 0xd0, 0x86, 0xc3, 0xeb, 0x57, 0x53, 0x70, 0xc, 0x38, 0x71, 0x18, 0xbb, 0x14, 0x2f, 0x3e, 0x6d, 0xa1, 0xe9, 0x88, 0xdf, 0xb3, 0x1a, 0xc7, 0x5d, 0x73, 0x68, 0x93, 0x1e, 0x45, 0xd1, 0x39, 0x1a, 0x27, 0x4b, 0x22, 0xf8, 0x3c, 0xeb, 0x7, 0x2f, 0x9b, 0xca, 0xbc, 0xb, 0x21, 0x66, 0x85, 0xbf, 0xd7, 0x89, 0xf5, 0x2, 0x39, 0x71, 0x2, 0x4b, 0x18, 0x78, 0xa2, 0x5, 0x44, 0x25, 0x22, 0xf9, 0xea, 0x7d, 0x87, 0x97, 0xa4, 0x10, 0x2a, 0x3d, 0xf4, 0x17, 0x3, 0x76, 0x82, 0x51, 0xfd, 0x5e, 0x1, 0x7c, 0x85, 0xd1, 0x20, 0xa, 0x46, 0x41, 0x18, 0xaa, 0x35, 0x65, 0x4e, 0x7c, 0xa3, 0x9f, 0x3c, 0x37, 0x5b, 0x8e, 0xf8, 0xcb, 0xe7, 0x53, 0x4d, 0xbc, 0x64, 0xbc, 0x20, 0xbe, 0xfb, 0x41, 0x7c, 0xf6, 0xe, 0xc9, 0x2f, 0x63, 0xd9, 0xee, 0x73, 0x97}, - output224: []byte{0x29, 0x9d, 0x62, 0xf8, 0xdf, 0x5e, 0xad, 0xe6, 0x87, 0x18, 0x83, 0xb0, 0x33, 0xb8, 0x30, 0xa9, 0x95, 0x2a, 0x74, 0xb1, 0x2f, 0x3d, 0x55, 0xaf, 0x79, 0x8c, 0x69, 0x97}, - output256: []byte{0x37, 0x37, 0x4, 0xf6, 0x41, 0xfa, 0xf2, 0xb9, 0x18, 0xe2, 0x2e, 0x91, 0x42, 0xab, 0xf6, 0xb4, 0xac, 0x71, 0xb6, 0x88, 0x3a, 0xc4, 0xd7, 0xa0, 0x75, 0xf6, 0x26, 0xe9, 0x47, 0x83, 0x7d, 0x3f}, - output384: []byte{0x5, 0x58, 0x6b, 0xcb, 0x80, 0x77, 0xe1, 0x9f, 0x3f, 0x43, 0x1, 0x52, 0x16, 0xd6, 0x23, 0xb1, 0x43, 0x9c, 0x49, 0xec, 0xdd, 0x3c, 0x53, 0x25, 0x55, 0x53, 0xe9, 0x13, 0x3f, 0xd1, 0xa9, 0x0, 0x88, 0x91, 0x52, 0xd, 0x2e, 0xeb, 0xe5, 0x68, 0x4c, 0x54, 0x60, 0x28, 0xca, 0x2c, 0xdd, 0xfe}, - output512: []byte{0x95, 0xed, 0x6d, 0x85, 0x67, 0x77, 0x4e, 0x66, 0x40, 0x4f, 0xc3, 0x2b, 0x7a, 0x1, 0xe1, 0xc6, 0x25, 0xfc, 0x83, 0x22, 0xab, 0x9b, 0xe0, 0xcd, 0x7c, 0x93, 0x67, 0x31, 0x63, 0x8b, 0x4, 0xc0, 0x97, 0x48, 0x97, 0x3d, 0x95, 0x66, 0x5a, 0x35, 0xb2, 0x18, 0xd1, 0x53, 0x14, 0x11, 0xf3, 0xaa, 0x5e, 0x5c, 0x47, 0xe6, 0x5d, 0x85, 0x7a, 0x43, 0x78, 0x3e, 0x2b, 0xd3, 0xc9, 0xd2, 0x90, 0x5}, - }, - { - msg: []byte{0x71, 0x45, 0xfa, 0x12, 0x4b, 0x74, 0x29, 0xa1, 0xfc, 0x22, 0x31, 0x23, 0x7a, 0x94, 0x9b, 0xa7, 0x20, 0x1b, 0xcc, 0x18, 0x22, 0xd3, 0x27, 0x2d, 0xe0, 0x5, 0xb6, 0x82, 0x39, 0x81, 0x96, 0xc2, 0x5f, 0x7e, 0x5c, 0xc2, 0xf2, 0x89, 0xfb, 0xf4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x2b, 0x8d, 0x65, 0xe1, 0x4f, 0xda, 0xc5, 0x1f, 0x60, 0x9f, 0x88, 0x88, 0x81, 0xdb, 0x80, 0x70, 0xa0, 0xb7, 0xd, 0x78, 0x92, 0xc0, 0x9, 0xa1, 0xad, 0x28}, - output256: []byte{0xee, 0x59, 0x94, 0xb3, 0xd3, 0x2b, 0xda, 0xe5, 0x8e, 0x72, 0x56, 0x6f, 0xc2, 0x4b, 0x88, 0x64, 0x61, 0x21, 0x7f, 0xdd, 0x72, 0x73, 0xe1, 0x60, 0x8f, 0xb, 0x29, 0x26, 0xb7, 0x92, 0x35, 0x46}, - output384: []byte{0xa2, 0x0, 0xd8, 0xef, 0x3d, 0x12, 0xb, 0x91, 0x75, 0x61, 0xed, 0xc8, 0x42, 0xb, 0xde, 0x2, 0x2b, 0x3a, 0xce, 0x79, 0x29, 0x25, 0xc8, 0xfa, 0xbf, 0x25, 0xad, 0x9b, 0xf, 0xa6, 0x76, 0xd2, 0x26, 0xa, 0xbd, 0x80, 0x98, 0xf3, 0x83, 0xc0, 0xf9, 0x30, 0x43, 0xd5, 0xd3, 0xf5, 0x6c, 0x47}, - output512: []byte{0x98, 0x35, 0x7, 0x93, 0xfc, 0x15, 0x40, 0xae, 0x72, 0x75, 0x7c, 0x2d, 0x1b, 0xa0, 0xfa, 0x34, 0xdf, 0x19, 0x23, 0xc9, 0x87, 0xf3, 0x65, 0x75, 0x27, 0x88, 0xe3, 0xc6, 0x59, 0x31, 0x74, 0x6c, 0x36, 0xd1, 0x3f, 0xd2, 0x93, 0xdb, 0x8e, 0xa1, 0xb6, 0x37, 0x48, 0x72, 0xcc, 0xf7, 0x4e, 0x9b, 0xc, 0xff, 0x67, 0xc6, 0xde, 0xbb, 0x42, 0x63, 0x39, 0xc, 0xd9, 0x6e, 0x2b, 0xdd, 0x86, 0x4f}, - }, - { - msg: []byte{0x7f, 0xdf, 0xad, 0xcc, 0x9d, 0x29, 0xba, 0xd2, 0x3a, 0xe0, 0x38, 0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x9a, 0xee, 0x31, 0x1c, 0xa1, 0xab, 0xdc, 0x83, 0x19, 0xe0, 0x50, 0xd6, 0x79, 0x72, 0xcb, 0x35, 0xa6, 0xb1, 0x60, 0x1b, 0x25, 0xdb, 0xf4, 0x87}, - output224: []byte{0xf8, 0xe5, 0x21, 0x8d, 0xb0, 0x87, 0xd3, 0x8b, 0x1c, 0x77, 0x32, 0x47, 0xfc, 0x22, 0x70, 0x4c, 0x1f, 0xbd, 0xb2, 0xb, 0x15, 0x0, 0xe2, 0x6a, 0xfa, 0xb, 0x75, 0x72}, - output256: []byte{0x6a, 0x58, 0x4f, 0x9f, 0x4a, 0xcd, 0x8f, 0xc8, 0xe1, 0x5d, 0xac, 0xd3, 0x26, 0x29, 0x1f, 0xe9, 0x31, 0x1c, 0x20, 0x98, 0x72, 0x25, 0xc5, 0x1c, 0xf4, 0x25, 0x1e, 0x52, 0xb4, 0x7f, 0xa2, 0x23}, - output384: []byte{0xa8, 0x90, 0x5d, 0x1e, 0x9f, 0x4f, 0xc9, 0x6f, 0x2d, 0x76, 0x9d, 0x31, 0xc9, 0xa1, 0x20, 0xde, 0x43, 0xa0, 0xb2, 0x1, 0x15, 0xc8, 0xd1, 0x7b, 0xf0, 0x31, 0x32, 0x6, 0xeb, 0x9c, 0xd8, 0x7a, 0xe4, 0x1d, 0xf2, 0xd4, 0x44, 0xc9, 0xd7, 0x5f, 0x93, 0x66, 0x99, 0x82, 0x63, 0xd6, 0x1c, 0x7}, - output512: []byte{0xc2, 0x49, 0x3d, 0x60, 0xe1, 0xef, 0xa6, 0xb4, 0x72, 0x93, 0x3e, 0xde, 0x64, 0xd1, 0xf4, 0x9e, 0xff, 0x77, 0x36, 0x35, 0xf6, 0x6c, 0x64, 0x54, 0xe5, 0x7e, 0x47, 0x93, 0x5a, 0xf, 0x4c, 0x5b, 0x94, 0x54, 0x8d, 0xa5, 0xc3, 0x69, 0xbd, 0xac, 0x71, 0x46, 0xe5, 0x4f, 0x1, 0x7c, 0x3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1, 0xaf, 0x81, 0x1a, 0x13, 0xf1, 0x56, 0xbe, 0xb7, 0xa2, 0x88, 0xaa, 0xe5, 0x93, 0xeb, 0xd1, 0x47, 0x1b, 0x62, 0x4a, 0xa1, 0xa7, 0xc6, 0xad, 0xf0, 0x1e, 0x22, 0x0, 0xb3, 0xd7, 0x2d, 0x88, 0xa3, 0xae, 0xd3, 0x10, 0xc, 0x88, 0x23, 0x1e, 0x41, 0xef, 0xc3, 0x76, 0x90, 0x6f, 0xb, 0x58, 0xd, 0xc8, 0x95, 0xf0, 0x80, 0xfd, 0xa5, 0x74, 0x1d, 0xb1, 0xcb}, - output224: []byte{0xfa, 0x60, 0x2f, 0x9, 0xb2, 0x8f, 0x86, 0x79, 0x77, 0x1e, 0x9c, 0x39, 0x66, 0x3, 0x2b, 0x80, 0xfa, 0x2f, 0xf, 0x33, 0xe8, 0x4f, 0x3e, 0xd6, 0x9b, 0xe7, 0xae, 0x9c}, - output256: []byte{0x4f, 0x92, 0x83, 0x9c, 0xdd, 0xb0, 0xdf, 0x31, 0xd1, 0x6a, 0xd, 0xb5, 0x3b, 0xbe, 0x7, 0x69, 0x8a, 0x7c, 0x19, 0x12, 0xd5, 0x59, 0xd, 0x21, 0x15, 0x5d, 0x45, 0xdb, 0x1b, 0x48, 0xca, 0xb4}, - output384: []byte{0x88, 0x24, 0x9a, 0xf8, 0x4a, 0x7f, 0x1e, 0x49, 0xd1, 0x44, 0x86, 0x9a, 0x3d, 0x4f, 0xe8, 0xaa, 0x6e, 0x1a, 0x48, 0x74, 0xee, 0x46, 0x7b, 0xc9, 0x9e, 0x9c, 0x33, 0xe2, 0x10, 0x5a, 0xf2, 0xd0, 0x97, 0x41, 0x7d, 0x6b, 0x78, 0x53, 0x79, 0x25, 0x39, 0x2d, 0xb2, 0xc5, 0xcb, 0x1e, 0xb, 0x92}, - output512: []byte{0x70, 0xd7, 0xba, 0x65, 0x85, 0xcd, 0x2e, 0xf9, 0x1b, 0xb2, 0x61, 0x2, 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0xc2, 0xcd, 0xd1, 0x36, 0xe1, 0x22, 0xc6, 0x59, 0xbe, 0x25, 0x9d, 0x98, 0xe5, 0x84, 0x1d, 0xf4, 0xc2, 0xf6, 0x3, 0x30, 0xd4, 0xd8, 0xcd, 0xee, 0x7b, 0xf1, 0xa0, 0xa2, 0x44, 0x52, 0x4e, 0xec, 0xc6, 0x8f, 0xf2, 0xae, 0xf5, 0xbf, 0x0, 0x69, 0xc9, 0xe8, 0x7a, 0x11, 0xc6, 0xe5, 0x19, 0xde, 0x1a, 0x40, 0x62, 0xa1, 0xc, 0x83, 0x83, 0x73, 0x88, 0xf7, 0xef, 0x58, 0x59, 0x8a, 0x38, 0x46, 0xf4, 0x9d, 0x49, 0x96, 0x82, 0xb6, 0x83, 0xc4, 0xa0, 0x62, 0xb4, 0x21, 0x59, 0x4f, 0xaf, 0xbc, 0x13, 0x83, 0xc9, 0x43, 0xba, 0x83, 0xbd, 0xef, 0x51, 0x5e, 0xfc, 0xf1, 0xd}, - output224: []byte{0xc8, 0xd7, 0x56, 0x88, 0x89, 0xdd, 0x6f, 0xcb, 0xc3, 0xb8, 0x87, 0x4e, 0xd7, 0x90, 0x51, 0x87, 0x5d, 0x3c, 0xe2, 0x91, 0x2, 0xdf, 0xc, 0x5d, 0xac, 0x8a, 0xeb, 0x8a}, - output256: []byte{0xea, 0xfd, 0x66, 0x1f, 0x34, 0x3a, 0xe8, 0x34, 0xc6, 0x21, 0xe0, 0x74, 0xac, 0x69, 0x3, 0xa2, 0xe3, 0xe6, 0x32, 0x4f, 0x36, 0x5b, 0x34, 0x32, 0xdf, 0xfa, 0x73, 0x2f, 0x47, 0x7a, 0xc1, 0x29}, - output384: []byte{0xc4, 0x61, 0x22, 0xd0, 0xb, 0x61, 0xe7, 0x9d, 0xf0, 0x25, 0xa4, 0xd5, 0x25, 0xb8, 0xa6, 0x2, 0xc7, 0xac, 0x0, 0x43, 0x4, 0xa9, 0x93, 0x87, 0x2e, 0x3a, 0x8a, 0xa3,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xd3, 0xfa, 0xef, 0x48, 0x20, 0xbe}, - output384: []byte{0xab, 0xa0, 0xee, 0x3c, 0x16, 0xd3, 0xdc, 0x75, 0x3f, 0x6e, 0x46, 0x6c, 0x33, 0xa9, 0x98, 0xa7, 0x32, 0x82, 0xc0, 0xdb, 0xea, 0xf5, 0x13, 0x24, 0x97, 0x9a, 0x58, 0x43, 0x76, 0x36, 0x88, 0x6e, 0x55, 0x21, 0xb5, 0x67, 0xc9, 0xa6, 0x2d, 0x40, 0x5e, 0xe5, 0x58, 0xff, 0xeb, 0xae, 0x91, 0xbc}, - output512: []byte{0x83, 0x75, 0x2a, 0x88, 0xc9, 0x15, 0xd4, 0x19, 0x32, 0x96, 0x72, 0x5d, 0xec, 0xc5, 0xc, 0x9c, 0x5, 0xd2, 0x5d, 0x6b, 0xbd, 0x9a, 0xf2, 0xe0, 0xef, 0x6, 0x28, 0x6e, 0xcf, 0xee, 0x96, 0x1d, 0xe9, 0x59, 0xbe, 0xdb, 0xb1, 0x30, 0x70, 0x4d, 0x43, 0x2c, 0x2b, 0xc8, 0x99, 0x30, 0x20, 0x8f, 0x45, 0xe, 0xa, 0x2, 0x26, 0x61, 0x72, 0x40, 0x43, 0xd2, 0x68, 0xcb, 0x24, 0xe7, 0xfc, 0x47}, - }, - { - msg: []byte{0x8c, 0xff, 0x1f, 0x67, 0xfe, 0x53, 0xc0, 0x98, 0x89, 0x6d, 0x91, 0x36, 0x38, 0x9b, 0xd8, 0x88, 0x18, 0x16, 0xcc, 0xab, 0x34, 0x86, 0x2b, 0xb6, 0x7a, 0x65, 0x6e, 0x3d, 0x98, 0x89, 0x6f, 0x3c, 0xe6, 0xff, 0xd4, 0xda, 0x73, 0x97, 0x58, 0x9, 0xfc, 0xdf, 0x96, 0x66, 0x76, 0xd, 0x6e, 0x56, 0x1c, 0x55, 0x23, 0x8b, 0x20, 0x5d, 0x80, 0x49, 0xc1, 0xce, 0xde, 0xef, 0x37, 0x4d, 0x17, 0x35, 0xda, 0x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xb2, 0xb5, 0x82}, - output256: []byte{0x4b, 0xdf, 0x73, 0x1b, 0xbb, 0x3d, 0xe, 0x2a, 0xb0, 0xeb, 0x3d, 0x97, 0x21, 0x23, 0xa7, 0xa0, 0xa0, 0x85, 0xe8, 0xa9, 0x8a, 0xc6, 0xaf, 0x8a, 0xdb, 0xd3, 0x35, 0xb3, 0x72, 0x75, 0xdd, 0xff}, - output384: []byte{0x28, 0xb3, 0x71, 0x25, 0xf2, 0x33, 0xba, 0x8d, 0x52, 0x7e, 0x52, 0x84, 0xa1, 0x6e, 0x6e, 0xfe, 0x9a, 0xe8, 0x4d, 0x3e, 0xbc, 0x6e, 0xe4, 0xc8, 0x8a, 0xee, 0xa, 0xb1, 0x65, 0xc1, 0x11, 0xa3, 0x2f, 0xf2, 0xcd, 0xcc, 0x42, 0x13, 0xac, 0x32, 0x67, 0xb0, 0x54, 0x6d, 0xc0, 0xd7, 0x4c, 0x84}, - output512: []byte{0x72, 0x88, 0x42, 0x4b, 0xa8, 0x55, 0xa7, 0x6c, 0x74, 0x80, 0xb6, 0x6, 0xf8, 0xf3, 0x2e, 0x94, 0x39, 0x67, 0x99, 0xba, 0xb8, 0xbb, 0x3f, 0xc8, 0xfd, 0x21, 0xd1, 0x80, 0x96, 0x6c, 0x64, 0x97, 0x10, 0x71, 0xe2, 0x64, 0x56, 0x22, 0x52, 0x4e, 0xc7, 0xd1, 0x64, 0x5e, 0xea, 0x7b, 0x7c, 0x1f, 0xa2, 0x1f, 0x7f, 0x5b, 0x6b, 0x90, 0xf3, 0xe5, 0xbe, 0xb9, 0x92, 0x22, 0xf0, 0x5e, 0xa9, 0x5}, - }, - { - msg: []byte{0xea, 0xcd, 0x7, 0x97, 0x1c, 0xff, 0x9b, 0x99, 0x39, 0x90, 0x3f, 0x8c, 0x1d, 0x8c, 0xbb, 0x5d, 0x4d, 0xb1, 0xb5, 0x48, 0xa8, 0x5d, 0x4, 0xe0, 0x37, 0x51, 0x4a, 0x58, 0x36, 0x4,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d, 0xa3, 0xb1, 0x96, 0x50, 0x7e, 0x9f, 0x33, 0xca, 0x35, 0x64, 0x27}, - output224: []byte{0xa6, 0x9c, 0xc, 0x18, 0xa7, 0x12, 0x40, 0x8d, 0x8f, 0xa2, 0x38, 0x9a, 0xca, 0xbc, 0x3b, 0xf6, 0xf6, 0x41, 0x2f, 0x69, 0x78, 0x3e, 0x9f, 0x37, 0x96, 0xd, 0xb, 0x56}, - output256: []byte{0x47, 0xf9, 0x4, 0xfe, 0xea, 0x60, 0x72, 0x25, 0xca, 0xb2, 0xe3, 0xc5, 0x27, 0x48, 0x87, 0x89, 0x64, 0xbf, 0xed, 0xcf, 0xe0, 0x68, 0x72, 0x7d, 0xe6, 0x10, 0xf6, 0x34, 0x21, 0x36, 0x7b, 0xcf}, - output384: []byte{0x25, 0x89, 0x88, 0xe5, 0x4d, 0x66, 0xe0, 0xc5, 0x3b, 0x26, 0x3b, 0xa6, 0x8d, 0x9e, 0x3a, 0xa4, 0x7d, 0x27, 0x8d, 0xf8, 0x7c, 0x51, 0x21, 0x9c, 0xce, 0x6f, 0x25, 0x47, 0x28, 0x1e, 0xa6, 0x58, 0x15, 0x40, 0xe2, 0x8c, 0x1d, 0x7e, 0x6, 0x92, 0x54, 0x79, 0x1f, 0xd, 0x38, 0x5e, 0xa6, 0x94}, - output512: []byte{0xe9, 0x39, 0x93, 0x76, 0xd8, 0x9c, 0x4d, 0xd4, 0x46, 0x4e, 0x45, 0x82, 0x5f, 0x43, 0x2, 0xcd, 0xcc, 0xd4, 0xc4, 0x1d, 0xb4, 0xe8, 0x95, 0x1b, 0xe1, 0x7b, 0xcc, 0x64, 0x51, 0x85, 0x83, 0x32, 0x39, 0x8b, 0x7e, 0x4e, 0x7f, 0x5e, 0xee, 0x68, 0x30, 0xc7, 0x15, 0x45, 0x1e, 0x4a, 0xac, 0xdb, 0x17, 0x9d, 0xd5, 0x24, 0x7b, 0xa6, 0xd5, 0x72, 0x8c, 0xbd, 0x40, 0x60, 0xae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xa6, 0x17, 0xd3, 0x7e, 0xfd, 0x54, 0xcc, 0x1, 0x97, 0xa, 0x4a, 0x41, 0xd1, 0xa8, 0xd3, 0xdd, 0xce, 0x46, 0xed, 0xbb, 0xa4, 0xab, 0x7c, 0x90, 0xad, 0x56, 0x53, 0x98, 0xd3, 0x76, 0xf4, 0x31, 0x18, 0x9c, 0xe8, 0xc1, 0xc3, 0x3e, 0x13, 0x2f, 0xea, 0xe6, 0xa8, 0xcd, 0x17, 0xa6, 0x1c, 0x63, 0x0, 0x12}, - output224: []byte{0x6, 0x99, 0xfd, 0x35, 0x41, 0x6d, 0x83, 0x79, 0x1d, 0xc8, 0xe6, 0x56, 0xf2, 0x27, 0x18, 0xb0, 0x9d, 0xa9, 0xe3, 0xdf, 0x6e, 0x7f, 0x37, 0xa2, 0x50, 0xe2, 0x2d, 0xcd}, - output256: []byte{0x32, 0x49, 0x37, 0x60, 0x7d, 0x9f, 0x16, 0xaf, 0x81, 0x57, 0x1, 0x74, 0x9f, 0x3, 0x77, 0xb3, 0x28, 0x1a, 0xf9, 0xc5, 0xbb, 0x56, 0x5d, 0x6f, 0x2b, 0x96, 0x11, 0x53, 0x2b, 0x6b, 0xf0, 0x44}, - output384: []byte{0xf6, 0xa9, 0x39, 0x9b, 0x48, 0x2a, 0x3a, 0x5e, 0xa6, 0xfe, 0x79, 0xa2, 0xdb, 0x7b, 0xae, 0x7e, 0x58, 0x8c, 0x9b, 0x7d, 0xa0, 0x3d, 0xd8, 0x5c, 0x12, 0x1, 0x12, 0xfd, 0xbc, 0x23, 0x43, 0x50, 0x52, 0x9a, 0x1f, 0x37, 0xab, 0xbe, 0xbe, 0xb7, 0x70, 0x29, 0x9e, 0x14, 0x1e, 0xea, 0x7b, 0xa3}, - output512: []byte{0xcc, 0xea, 0x44, 0x7e, 0xfe, 0x6f, 0x8b, 0x6, 0xac, 0x42, 0x7, 0x62, 0x80, 0x37, 0x76, 0x35, 0xf5, 0xfd, 0x7, 0x67, 0xf4, 0x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35, 0xb7, 0x79, 0x67, 0x9b, 0xda, 0xde, 0x56, 0x6f, 0xe5, 0x57, 0x0, 0x85, 0x86, 0x18, 0xe6, 0x26, 0xb4, 0xa0, 0xfa, 0xf8, 0x95, 0xbc, 0xce, 0x90, 0x11, 0x50, 0x4a, 0x49, 0xe0, 0x5f, 0xd5, 0x61, 0x27, 0xea, 0xe3, 0xd1, 0xf8, 0x91, 0x7a, 0xfb, 0x54, 0x8e, 0xca, 0xda, 0xbd, 0xa1, 0x2, 0x1, 0x11, 0xfe, 0xc9, 0x31, 0x4c, 0x41, 0x34, 0x98, 0xa3, 0x60, 0xb0, 0x86, 0x40, 0x54, 0x9a, 0x22, 0xcb, 0x23, 0xc7, 0x31, 0xac, 0xe7, 0x43, 0x25, 0x2a, 0x82, 0x27, 0xa0, 0xd2, 0x68, 0x9d, 0x4c, 0x60, 0x1, 0x60, 0x66, 0x78, 0xdf, 0xb9, 0x21}, - output224: []byte{0xbf, 0x6a, 0x35, 0x98, 0xa1, 0x5e, 0x28, 0xb7, 0x76, 0x22, 0x9f, 0x4d, 0x12, 0x4d, 0x40, 0x3f, 0xad, 0x9d, 0xf, 0xbc, 0x2b, 0x76, 0x68, 0xc9, 0x5d, 0x8b, 0x50, 0x46}, - output256: []byte{0xb9, 0x84, 0xc2, 0xd6, 0xb6, 0xfd, 0xc2, 0x85, 0x74, 0xaa, 0xd5, 0x51, 0xfc, 0x16, 0xb6, 0x8f, 0x85, 0xbf, 0x6c, 0xc4, 0x80, 0xa1, 0x5c, 0x12, 0x8a, 0xe5, 0x61, 0x65, 0x61, 0xd4, 0x67, 0x21}, - output384: []byte{0xc0, 0xf9, 0x57, 0xe5, 0x2e, 0x40, 0xf9, 0xb8, 0xea, 0x94, 0x5d, 0x40, 0x77, 0x92, 0x86, 0xf7, 0x25, 0x7a, 0xd4, 0x63, 0xa9, 0x34, 0xb0, 0x49, 0xdf, 0x40, 0xc3, 0x1d, 0x35, 0x47, 0xae, 0xf4, 0x1a, 0xea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f, 0x17, 0x42, 0xcd, 0xeb, 0x38, 0x95, 0x59, 0xc7, 0x88, 0x13, 0x1a, 0x67, 0x93, 0xe1, 0x93, 0x85, 0x66, 0x61, 0x37, 0x6c, 0x81, 0xce, 0x95, 0x68, 0xda, 0x19, 0xaa, 0x69, 0x25, 0xb4, 0x7f, 0xfd, 0x77, 0xa4, 0x3c, 0x7a, 0xe, 0x75, 0x8c, 0x37, 0xd6, 0x92, 0x54, 0x90, 0x9f, 0xf0, 0xfb, 0xd4, 0x15, 0xef, 0x8e, 0xb9, 0x37, 0xbc, 0xd4, 0x9f, 0x91, 0x46, 0x8b, 0x49, 0x97, 0x4c, 0x7, 0xdc, 0x81, 0x9a, 0xbd, 0x67, 0x39, 0x5d, 0xb0, 0xe0, 0x58, 0x74, 0xff, 0x83, 0xdd, 0xda, 0xb8, 0x95, 0x34, 0x4a, 0xbd, 0xe, 0x71, 0x11, 0xb2, 0xdf, 0x9e, 0x58, 0xd7, 0x6d, 0x85, 0xad, 0x98, 0x10, 0x6b, 0x36, 0x29, 0x58, 0x26, 0xbe, 0x4, 0xd4, 0x35, 0x61, 0x55, 0x95, 0x60, 0x5e, 0x4b, 0x4b, 0xb8, 0x24, 0xb3, 0x3c, 0x4a, 0xfe, 0xb5, 0xe7, 0xbb, 0xd, 0x19, 0xf9, 0x9}, - output224: []byte{0x56, 0xf8, 0xe9, 0xf6, 0x9a, 0x39, 0x9e, 0x52, 0x89, 0x96, 0xc4, 0x63, 0xd6, 0x5f, 0x20, 0xdb, 0x41, 0x40, 0x65, 0x33, 0xc7, 0xdf, 0x2b, 0xa1, 0xaf, 0xa2, 0x49, 0x4a}, - output256: []byte{0x91, 0xa5, 0xb9, 0xfc, 0x2d, 0xcc, 0x5f, 0xae, 0xda, 0x57, 0xd2, 0xe7, 0xa4, 0x1e, 0x92, 0x2d, 0xc3, 0x2d, 0x57, 0x2a, 0xeb, 0xdf, 0x6d, 0x54, 0xcb, 0x8c, 0x3a, 0xe4, 0x24, 0x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e, 0x94, 0x26, 0xb2, 0x18, 0xe0, 0x28, 0xf8, 0x7b, 0x3c, 0xc}, - output256: []byte{0x97, 0xdc, 0xa1, 0x5, 0xa, 0x46, 0x5b, 0x60, 0xe9, 0x1e, 0xbe, 0x26, 0xe2, 0x9a, 0xdb, 0x5a, 0x28, 0x6a, 0x5, 0x82, 0xee, 0xe2, 0xe8, 0x9b, 0x8b, 0x90, 0x19, 0x54, 0x29, 0x3f, 0x61, 0x46}, - output384: []byte{0x3d, 0x64, 0x95, 0xeb, 0x3d, 0xa4, 0xe8, 0x1d, 0x34, 0x70, 0xa0, 0x50, 0xf4, 0x16, 0xe2, 0xc8, 0xab, 0xf6, 0x57, 0xa2, 0x6d, 0x4f, 0xd6, 0x4a, 0xf3, 0x57, 0x35, 0xb5, 0x78, 0x2b, 0x61, 0x1f, 0xb7, 0x98, 0xa7, 0x2f, 0xe7, 0xa6, 0x1c, 0xe7, 0x9d, 0x4, 0x96, 0xf6, 0x96, 0x54, 0xcc, 0x80}, - output512: []byte{0x91, 0xb8, 0xcd, 0x79, 0x5d, 0x1a, 0x68, 0x28, 0x60, 0x1e, 0x0, 0xdb, 0xc, 0x91, 0xff, 0x9a, 0x6f, 0x83, 0x74, 0x44, 0xf5, 0x3f, 0xcf, 0x89, 0xe9, 0x90, 0xb8, 0x8f, 0x5f, 0x3e, 0x34, 0xeb, 0x49, 0xe, 0x72, 0xa1, 0x79, 0x5f, 0xab, 0x84, 0xf7, 0x8d, 0xa3, 0xf7, 0xaf, 0xc8, 0x98, 0x96, 0xc7, 0xcd, 0xe5, 0x86, 0x5d, 0x1b, 0xcd, 0x74, 0xd5, 0x63, 0x9e, 0x49, 0x3, 0xc6, 0x83, 0xfe}, - }, - { - msg: []byte{0x57, 0xaf, 0x97, 0x1f, 0xcc, 0xae, 0xc9, 0x74, 0x35, 0xdc, 0x2e, 0xc9, 0xef, 0x4, 0x29, 0xbc, 0xed, 0xc6, 0xb6, 0x47, 0x72, 0x9e, 0xa1, 0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xb1, 0xd0, 0x12, 0x85, 0x22, 0xc2, 0xf8, 0xbf, 0xf5, 0x6a, 0x7f, 0xe6, 0x79, 0x69, 0x42, 0x2c, 0xe8, 0x39, 0xa9, 0xd4, 0x60, 0x8f, 0x3}, - output224: []byte{0xff, 0x70, 0x13, 0x67, 0x9a, 0xb2, 0xbe, 0x65, 0xae, 0xdd, 0x9, 0x73, 0x9f, 0x56, 0xf8, 0xdd, 0x0, 0x72, 0x73, 0x8b, 0x86, 0xe7, 0x1a, 0x24, 0x70, 0x47, 0x6c, 0x8c}, - output256: []byte{0x6d, 0x3, 0x3d, 0x85, 0xda, 0xed, 0x33, 0x66, 0xd5, 0xf7, 0xd5, 0xe4, 0xf0, 0x3b, 0x3d, 0x5, 0xb6, 0x57, 0x78, 0xee, 0xea, 0x7, 0x4b, 0xc, 0x68, 0x3c, 0xff, 0xcd, 0x6f, 0x51, 0xd5, 0xbd}, - output384: []byte{0xf8, 0x18, 0x8e, 0xaf, 0xd0, 0xe2, 0xf9, 0xc7, 0xf4, 0x4e, 0x70, 0xb3, 0x8d, 0xb1, 0xfe, 0x3e, 0x12, 0xb1, 0x46, 0x97, 0x39, 0xca, 0x6a, 0x13, 0xed, 0x5a, 0x86, 0x61, 0x67, 0x3a, 0x31, 0x82, 0x96, 0xff, 0xaf, 0x8d, 0x37, 0xf6, 0xfc, 0xec, 0x22, 0xa2, 0xd0, 0xe, 0xee, 0x2a, 0xbe, 0xba}, - output512: []byte{0x76, 0x35, 0xd7, 0x9c, 0x1b, 0x32, 0xe4, 0x93, 0x4e, 0xb0, 0x9, 0xc, 0x6d, 0x46, 0xc0, 0xb2, 0x40, 0xf6, 0x26, 0xc7, 0x7d, 0x84, 0xf8, 0xea, 0xbf, 0x57, 0x1b, 0xa8, 0xfd, 0xe9, 0x24, 0xf4, 0xa1, 0xcf, 0x45, 0x67, 0x4, 0xb1, 0x1, 0xf6, 0x67, 0xf9, 0x12, 0xde, 0xdb, 0xbc, 0xbe, 0xff, 0x21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x5a, 0x44, 0xf7, 0x38, 0x90, 0x60, 0x7d, 0x6, 0xd5, 0x7, 0xa4, 0xf8, 0x39, 0x36, 0x58, 0x78, 0x86, 0x69, 0xf6, 0xef, 0x4d, 0xeb, 0x58, 0xd0, 0x8c, 0x50, 0xca, 0x7, 0x56, 0xd5, 0xe2, 0xf4, 0x9d, 0x1a, 0x7a, 0xd7, 0x3e, 0xf, 0xb, 0x3d, 0x3b, 0x5f, 0x9, 0xa, 0xcf, 0x62, 0x2b, 0x18, 0x78, 0xc5, 0x91, 0x33, 0xe4, 0xa8, 0x48, 0xe0, 0x51, 0x53, 0x59, 0x2e, 0xa8, 0x1c, 0x6f, 0xbf}, - output224: []byte{0x9d, 0xfb, 0x6a, 0x85, 0x4a, 0x33, 0x91, 0x4e, 0xae, 0x15, 0x96, 0xdc, 0xd2, 0xbe, 0x36, 0x3a, 0x96, 0xe7, 0xe0, 0x88, 0xbe, 0x52, 0xf, 0x60, 0xe5, 0xa6, 0x5c, 0x7f}, - output256: []byte{0x1, 0xeb, 0xbb, 0x73, 0x41, 0xe, 0xeb, 0xac, 0x66, 0x5c, 0x3b, 0x40, 0x6, 0x3d, 0x0, 0x1f, 0x43, 0xdb, 0xe9, 0xd1, 0x72, 0x2e, 0xb3, 0x23, 0xfe, 0x8, 0x76, 0x3d, 0x7f, 0xf0, 0x61, 0x6c}, - output384: []byte{0x7d, 0x83, 0xc3, 0xf2, 0x26, 0x5c, 0x90, 0xfe, 0xf4, 0xbc, 0x6b, 0xd0, 0xd1, 0x7a, 0x21, 0x8f, 0xe, 0x19, 0x64, 0x89, 0xcb, 0x2d, 0x84, 0x55, 0xbb, 0xee, 0x80, 0xab, 0x98, 0x9f, 0xfe, 0xa4, 0x6d, 0xe7, 0x53, 0x34, 0x6e, 0xdb, 0xd5, 0xc8, 0x84, 0x48, 0xfe, 0xdb, 0xd, 0x4a, 0xad, 0x4d}, - output512: []byte{0xdd, 0xd0, 0xc5, 0x21, 0xed, 0x60, 0xc5, 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xfa, 0x52, 0x39, 0xfb, 0x67, 0xf2, 0x9c, 0x18, 0xcb, 0xaa, 0x2a, 0xf6, 0xed, 0x4b, 0xf4, 0x28, 0x39, 0x36, 0x82, 0x3a, 0xc1, 0x79, 0x1, 0x64, 0xfe, 0xc5, 0x45, 0x7a, 0x9c, 0xba, 0x7c, 0x76, 0x7c, 0xa5, 0x93, 0x92, 0xd9, 0x4c, 0xab, 0x74, 0x48, 0xf5, 0xe, 0xb3, 0x4e, 0x9a, 0x93, 0xa8, 0x0, 0x27, 0x47, 0x1c, 0xe5, 0x97, 0x36, 0xf0, 0x99, 0xc8, 0x86, 0xde, 0xa1, 0xab, 0x4c, 0xba, 0x4d, 0x89, 0xf5, 0xfc, 0x7a, 0xe2, 0xf2, 0x1c, 0xcd, 0x27, 0xf6, 0x11, 0xec, 0xa4, 0x62, 0x6b, 0x2d, 0x8, 0xdc, 0x22, 0x38, 0x2e, 0x92, 0xc1, 0xef, 0xb2, 0xf6, 0xaf, 0xdc, 0x8f, 0xdc, 0x3d, 0x21, 0x72, 0x60, 0x4f, 0x50, 0x35, 0xc4, 0x6b, 0x81, 0x97, 0xd3}, - output224: []byte{0xc2, 0x7e, 0x80, 0xc3, 0x73, 0xb2, 0x16, 0x70, 0x3d, 0x3d, 0x9e, 0x67, 0x22, 0x3c, 0xfc, 0x54, 0x97, 0xc3, 0xe7, 0x44, 0x55, 0xd4, 0x9b, 0x4, 0x9a, 0xe3, 0xf5, 0xf4}, - output256: []byte{0x8d, 0x3a, 0x49, 0xcb, 0x57, 0x2a, 0xb9, 0x9c, 0x9b, 0xf0, 0x23, 0x13, 0x66, 0xbb, 0x1, 0x7c, 0x9a, 0xdf, 0x25, 0x47, 0x9d, 0x35, 0x44, 0x3a, 0x97, 0x1e, 0x45, 0x78, 0x7e, 0x73, 0x8c, 0xe5}, - output384: []byte{0xfc, 0xc5, 0xfc, 0xfe, 0xf5, 0xba, 0x87, 0x4a, 0x31, 0x7b, 0x73, 0xc9, 0xb1,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xab, 0x1a, 0x3b, 0x4c, 0x4f, 0xa5, 0x6a, 0xdb, 0x1c, 0x95, 0x31, 0xeb, 0x99, 0x79, 0xc5, 0x54, 0x90, 0x30, 0x53, 0x1, 0x3c, 0x20, 0xfe, 0xfd, 0x3f, 0x57, 0xb5, 0xcc, 0xdb}, - output384: []byte{0x9b, 0x33, 0x6b, 0x4c, 0x2b, 0x53, 0xf, 0x65, 0xc0, 0x1a, 0xf3, 0xf0, 0xa4, 0x6c, 0xf1, 0xb6, 0x26, 0xd5, 0xdb, 0xf1, 0xb2, 0xe5, 0xf, 0x79, 0xb, 0x9f, 0x34, 0xcc, 0xa3, 0x67, 0x31, 0x5f, 0xdf, 0xbf, 0x7d, 0x96, 0x19, 0xcd, 0xa4, 0xda, 0x22, 0xe3, 0x9f, 0x93, 0x15, 0x30, 0x38, 0x16}, - output512: []byte{0xb4, 0x56, 0x31, 0x91, 0x67, 0x51, 0x91, 0xed, 0x4d, 0x61, 0x7, 0xe5, 0x2f, 0xa1, 0x5a, 0xdc, 0x9d, 0x70, 0x64, 0x23, 0x58, 0xd8, 0xc3, 0xe3, 0x4d, 0xf1, 0x2, 0x74, 0xe2, 0x5d, 0x37, 0x3f, 0xd8, 0xd1, 0x9e, 0x92, 0x47, 0x2b, 0x82, 0x3e, 0x28, 0xbb, 0xdd, 0x1d, 0x54, 0x1a, 0x95, 0xfd, 0xdd, 0xd, 0x43, 0xc7, 0x9f, 0xcb, 0x3b, 0xa1, 0x8a, 0x7e, 0xc0, 0x38, 0xd3, 0xef, 0x69, 0xa6}, - }, - { - msg: []byte{0xd8, 0x55, 0x88, 0x69, 0x6f, 0x57, 0x6e, 0x65, 0xec, 0xa0, 0x15, 0x5f, 0x39, 0x5f, 0xc, 0xfa, 0xcd, 0x83, 0xf3, 0x6a, 0x99, 0x11, 0x1e, 0xd5, 0x76, 0x8d, 0xf2, 0xd1, 0x16, 0xd2, 0x12, 0x1e, 0x32, 0x35, 0x7b, 0xa4, 0xf5, 0x4e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87, 0xe4, 0x6c, 0x90, 0xe8, 0xc4, 0xd1, 0x0, 0xac, 0xd9, 0xee, 0xd2, 0x1e}, - output224: []byte{0x25, 0x85, 0xbd, 0x8d, 0x91, 0x58, 0xd6, 0x95, 0x2b, 0xee, 0x95, 0xb0, 0x4, 0xf5, 0xfe, 0xd7, 0xf, 0xaf, 0x6, 0x1b, 0x68, 0xab, 0x2d, 0x6a, 0x40, 0x46, 0x9b, 0xe7}, - output256: []byte{0x6b, 0x3d, 0xcc, 0x7a, 0xc6, 0xa5, 0xcb, 0x85, 0xb6, 0x7f, 0xc7, 0x1b, 0x40, 0x55, 0xd3, 0x79, 0x81, 0x34, 0xde, 0xef, 0x26, 0xfd, 0x3e, 0xb0, 0x3a, 0x4, 0x2e, 0xd, 0xaa, 0x35, 0xcc, 0x85}, - output384: []byte{0xca, 0xc4, 0x42, 0x22, 0x7f, 0x10, 0xc4, 0x93, 0x5d, 0x42, 0xc2, 0x91, 0x40, 0x43, 0x16, 0x78, 0x90, 0xc3, 0xee, 0x1f, 0x45, 0x56, 0xd3, 0x8d, 0x20, 0x76, 0x7e, 0x84, 0x2, 0xae, 0xc4, 0xd7, 0x1, 0x11, 0xf2, 0x3, 0x42, 0x76, 0xe9, 0xf, 0x28, 0x10, 0x2d, 0xe6, 0x34, 0xe2, 0x6a, 0xfd}, - output512: []byte{0xa3, 0xb, 0xd8, 0xc, 0xb3, 0xac, 0xb3, 0xbf, 0xa7, 0xe0, 0x37, 0xa3, 0xd0, 0xd2, 0x50, 0x9, 0x74, 0xd7, 0x19, 0x57, 0xf6, 0x81, 0x35, 0x13, 0x30, 0x20, 0xc3, 0x2e, 0xb4, 0xd6, 0x88, 0xf1, 0x32, 0xd0, 0xfb, 0x4, 0x5b, 0xe0, 0x27, 0xf1, 0x24, 0xb3, 0xd9, 0x35, 0xcb, 0x88, 0x9e, 0x3c, 0xbc, 0x4a, 0x4a, 0x42, 0x0, 0x26, 0xbb, 0x2a, 0xc2, 0xa4, 0xb1,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b, 0x86, 0x1a, 0xf8, 0xaf, 0x6, 0x46, 0xb6, 0xe3, 0x99, 0xb3, 0x8b, 0x61, 0x40, 0x51, 0xd3, 0x4f, 0x68, 0x42, 0x56, 0x3a, 0xf, 0x37, 0xec, 0x0, 0xcb, 0x3d, 0x86, 0x5f, 0xc5, 0xd7, 0x46, 0xc4, 0x98, 0x7d, 0xe2, 0xa6, 0x50, 0x71, 0x10, 0x8, 0x83, 0xa2, 0xa9, 0xc7, 0xa2, 0xbf, 0xe1, 0xe2, 0xdd, 0x60, 0x3d, 0x9e, 0xa2, 0x4d, 0xc7, 0xc5, 0xfd, 0x6, 0xbe}, - output224: []byte{0x7e, 0x64, 0xf3, 0xc5, 0x89, 0x5d, 0x5, 0x86, 0xcc, 0x5b, 0x54, 0x3b, 0x27, 0xde, 0x1b, 0x66, 0xa9, 0x35, 0x17, 0x1e, 0x2e, 0x7f, 0x3c, 0xa4, 0x8d, 0xd3, 0x71, 0x8e}, - output256: []byte{0x5d, 0x1d, 0xba, 0x8f, 0x15, 0x84, 0xac, 0x3f, 0x36, 0xb3, 0xac, 0x92, 0x5e, 0xc1, 0x3a, 0xc2, 0x84, 0x1, 0x3b, 0x96, 0x64, 0x96, 0x5a, 0xb6, 0x26, 0x5b, 0x94, 0x24, 0x66, 0xb5, 0xd8, 0xec}, - output384: []byte{0x5, 0xe3, 0xfb, 0x83, 0xee, 0x8d, 0x60, 0x98, 0x74, 0xd5, 0x93, 0x52, 0x83, 0x70, 0x2f, 0x29, 0xe5, 0xe8, 0x96, 0xbb, 0x9, 0xc, 0x48, 0x3, 0x34, 0x89, 0x29, 0x59, 0x89, 0xc4, 0x5d, 0xd2, 0xc0, 0x6f, 0x5b, 0xd5, 0x58, 0xb6, 0xbc, 0x78, 0x6a, 0xb1, 0x25, 0x1f, 0x75, 0x66, 0x4b, 0x6}, - output512: []byte{0x4a, 0x58, 0x9, 0xe4, 0x57, 0xf5, 0x4d, 0x9c, 0x7e, 0x82, 0x9, 0xf6,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0x73, 0x41, 0x7f, 0x36, 0xd4, 0xd2, 0x50, 0x5d, 0x16, 0xb7, 0x57, 0x7f, 0x45, 0x26, 0xc9, 0xd9, 0x4a, 0x27, 0xa, 0x2d, 0xfe, 0x45, 0xd, 0x6, 0xda, 0x8f, 0x6f, 0xa9, 0x56, 0x87, 0x9a, 0xa, 0x55, 0xcf, 0xe9, 0x9e, 0x74, 0x2e, 0xa5, 0x55, 0xea, 0x47, 0x7b, 0xa3, 0xe9, 0xb4, 0x4c, 0xcd, 0x50, 0x8c, 0x37, 0x54, 0x23, 0x61, 0x1a, 0xf9, 0x2e, 0x55, 0x34, 0x5d, 0xc2, 0x15, 0x77, 0x9b, 0x2d, 0x51, 0x19, 0xeb, 0xa4, 0x9c, 0x71, 0xd4, 0x9b, 0x9f, 0xe3, 0xf1, 0x56, 0x9f, 0xa2, 0x4e, 0x5c, 0xa3, 0xe3, 0x32, 0xd0, 0x42, 0x42, 0x2a, 0x8b, 0x81, 0x58, 0xd3, 0xec, 0x66, 0xa8, 0x0, 0x12, 0x97, 0x6f, 0x31, 0xff, 0xdf, 0x30, 0x5f, 0xc, 0x9c, 0x5e}, - output224: []byte{0xf, 0x83, 0x77, 0x8, 0xe0, 0x10, 0x37, 0x5a, 0xf8, 0x7f, 0x75, 0x41, 0x5e, 0xd6, 0x99, 0x88, 0xfe, 0x60, 0xeb, 0x2f, 0x26, 0x69, 0xad, 0x5, 0x1f, 0xa9, 0x97, 0x27}, - output256: []byte{0x89, 0xc6, 0xc8, 0x6d, 0xb0, 0xa8, 0x89, 0xaa, 0x67, 0xd8, 0xcb, 0x8, 0x5f, 0x9f, 0x43, 0x12, 0x64, 0x59, 0x72, 0xd9, 0x77, 0xc5, 0xb9, 0x52, 0xd9, 0xf6, 0x24, 0x3d, 0x7d, 0x3b, 0xe4, 0xd5}, - output384: []byte{0x6e, 0x46, 0x3c, 0x7f, 0xb5, 0xcf, 0x43, 0x6b, 0x14, 0x44, 0x92, 0x1a, 0xfe, 0x76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0xf6, 0x63, 0xae, 0x6a, 0xab, 0x45, 0x51, 0x9d, 0xf, 0x53, 0x91, 0xa5, 0x41, 0x70, 0x7d, 0x47, 0x90, 0x34, 0xe7, 0x3a, 0x6a, 0xd8, 0x5, 0xae, 0x35, 0x98, 0x9, 0x6a, 0xf0, 0x78, 0xf1, 0x39, 0x33, 0x1, 0x49, 0x3d, 0x66, 0x3d, 0xd7, 0x1f, 0x83, 0x86, 0x9c, 0xa2, 0x7b, 0xa5, 0x8, 0xb7, 0xe9, 0x1e, 0x81, 0xe1, 0x28, 0xc1, 0x71, 0x6d, 0xc3, 0xac, 0xfe, 0x30, 0x84, 0xb2, 0x20, 0x1e, 0x4, 0xcf, 0x80, 0x6, 0x61, 0x7e, 0xec, 0xf1, 0xb6, 0x40, 0x47, 0x4a, 0x5d, 0x45, 0xcf, 0xde, 0x9f, 0x4d, 0x3e, 0xf9, 0x2d, 0x6d, 0x5, 0x5b, 0x90, 0x98, 0x92, 0x19, 0x4d, 0x8a, 0x82, 0x18, 0xdb, 0x6d, 0x82, 0x3, 0xa8, 0x42, 0x61, 0xd2, 0x0, 0xd7, 0x14, 0x73, 0xd7, 0x48, 0x8f, 0x34, 0x27, 0x41, 0x6b, 0x68, 0x96, 0xc1, 0x37, 0xd4, 0x55, 0xf2, 0x31, 0x7, 0x1c, 0xac, 0xbc, 0x86, 0xe0, 0x41, 0x5a, 0xb8, 0x8a, 0xec, 0x84, 0x1d, 0x96, 0xb7, 0xb8, 0xaf, 0x41, 0xe0, 0x5b, 0xb4, 0x61, 0xa4, 0x6, 0x45, 0xbf, 0x17, 0x66, 0x1, 0xf1, 0xe7, 0x60, 0xde, 0x5f}, - output224: []byte{0xc7, 0x9d, 0xe3, 0x97, 0x78, 0x59, 0x38, 0x10, 0xc0, 0x35, 0x83, 0xd5, 0x96, 0x2b, 0x36, 0xe0, 0x4f, 0x34, 0x36, 0x53, 0x7, 0x47, 0x66, 0xd1, 0x57, 0xa1, 0x59, 0x93}, - output256: []byte{0xac, 0x2, 0x43, 0x2a, 0x55, 0x41, 0xc2, 0x62, 0x38, 0xc6, 0xf9, 0x9f, 0xad, 0xb2, 0xb2, 0x3b, 0x5f, 0xfc, 0xad, 0x8f, 0x4, 0xbd, 0x4c, 0x3b, 0x9a, 0x66, 0x20, 0xca, 0xb1, 0x26, 0x6e, 0x6b}, - output384: []byte{0x90, 0x45, 0x7e, 0x3d, 0x33, 0xfc, 0xe1, 0x3, 0x42, 0x0, 0x56, 0xa1, 0xc7, 0x12, 0x44, 0x1e, 0x4, 0x85, 0x6b, 0x17, 0xcf, 0x37, 0xa4, 0xe1, 0x33, 0x84, 0x1e, 0x6d, 0x9a, 0x94, 0x4b, 0x5e, 0xbe, 0xf9, 0x8c, 0xb1, 0xc1, 0xcc, 0xd5, 0x75, 0x63, 0x2c, 0xd3, 0xb5, 0xc1, 0x77, 0x66, 0x9e}, - output512: []byte{0x60, 0x3f, 0x7b, 0x9, 0x56, 0x56, 0x34, 0xd4, 0x41, 0xb, 0x57, 0x4a, 0x4d, 0xc9, 0xea, 0x46, 0x74, 0x37, 0x96, 0x45, 0x17, 0xe5, 0xef, 0xa5, 0x1a, 0x36, 0x2a, 0x30, 0xe8, 0xc6, 0x32, 0xc5, 0x51, 0x62, 0xa3, 0x35, 0x1b, 0xb5, 0x53, 0x2e, 0x40, 0x94, 0x8a, 0xa9, 0xa1, 0xe3, 0xa8, 0x78, 0x6c, 0x4, 0x22, 0xae, 0xc3, 0xec, 0x33, 0x8c, 0x7f, 0x4b, 0x57, 0x67, 0x92, 0x0, 0x45, 0x2b}, - }, - { - msg: []byte{0xd7, 0x82, 0xab, 0xb7, 0x2a, 0x5b, 0xe3, 0x39, 0x27, 0x57, 0xbe, 0x2, 0xd3, 0xe4, 0x5b, 0xe6, 0xe2, 0x9, 0x9d, 0x6f, 0x0, 0xd, 0x4, 0x2c, 0x8a, 0x54, 0x3f, 0x50, 0xed, 0x6e, 0xbc, 0x5, 0x5a, 0x7f, 0x13, 0x3b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xc9, 0x17, 0x31, 0x86, 0xc2, 0x26, 0x16, 0x9f, 0xf2, 0x57, 0x95, 0x4e, 0xbd, 0xa8, 0x1c, 0xe, 0x5f, 0x99}, - output224: []byte{0x95, 0xcc, 0x81, 0x1c, 0xc5, 0x65, 0x21, 0xa4, 0xe, 0x3c, 0xed, 0x8d, 0x9a, 0x23, 0xe, 0x21, 0x1, 0xe8, 0x6, 0x1f, 0xb0, 0x1e, 0x38, 0x8b, 0x99, 0x64, 0xbf, 0x29}, - output256: []byte{0xf5, 0x5a, 0xa0, 0x1d, 0xea, 0xb1, 0x21, 0x48, 0xe3, 0x57, 0x59, 0xdb, 0x81, 0x8f, 0x10, 0x59, 0x35, 0x11, 0x65, 0xe9, 0xe6, 0xf9, 0x3d, 0x34, 0x2f, 0xa, 0xbf, 0xca, 0x10, 0x2e, 0x8, 0x1}, - output384: []byte{0xe5, 0xfc, 0x73, 0xc7, 0x0, 0x28, 0xd1, 0xb8, 0x2a, 0x9a, 0xa9, 0x76, 0xd3, 0x4f, 0x5f, 0xc7, 0x29, 0x16, 0x83, 0x90, 0x27, 0x3, 0x8e, 0x79, 0xdf, 0x2e, 0x29, 0x14, 0x9e, 0x86, 0x1f, 0x9, 0xa4, 0x1a, 0x82, 0x3, 0xce, 0x92, 0x22, 0x3, 0xf7, 0x10, 0x96, 0x4b, 0x4f, 0x5b, 0xec, 0x2e}, - output512: []byte{0x10, 0x18, 0x69, 0x2d, 0x53, 0xc, 0x55, 0xba, 0xa5, 0x80, 0xae, 0x1e, 0x73, 0x84, 0x35, 0x11, 0x0, 0xd4, 0x63, 0x7c, 0xd3, 0x38, 0x69, 0xc7, 0x1e, 0x60, 0x76, 0xa3, 0xd4, 0xe3, 0x10, 0xd9, 0x64, 0xb8, 0x1d, 0x59, 0x3e, 0x89, 0x71, 0x88, 0x45, 0xac, 0x7a, 0x89, 0xe8, 0xad, 0x50, 0x73, 0x50, 0x64, 0x27, 0xc6, 0xc8, 0xf7, 0xfa, 0xdf, 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e8, 0xb6, 0xd0, 0xba, 0x21, 0x9a, 0x20, 0xa2, 0x3b, 0xb5, 0xe1, 0xf, 0xf4, 0x34, 0xd3, 0x9d, 0xb3, 0xf5, 0x83, 0x30, 0x5e, 0x9f, 0x5c, 0x3, 0x9d, 0x98, 0x56, 0x9e, 0x37, 0x7b, 0x75, 0xa7, 0xa, 0xb8, 0x37, 0xd1, 0xdf, 0x26, 0x9b, 0x8a, 0x4b, 0x56, 0x6f, 0x40, 0xbb, 0x91, 0xb5, 0x77, 0x45, 0x5f, 0xd3, 0xc3, 0x56, 0xc9, 0x14, 0xfa, 0x6, 0xb9, 0xa7, 0xce, 0x24, 0xc7, 0x31, 0x7a, 0x17, 0x2d}, - output224: []byte{0x2e, 0xbe, 0x13, 0xf1, 0x2e, 0xc4, 0x3e, 0x3f, 0x6b, 0x5, 0x6, 0xd7, 0xab, 0x21, 0x6e, 0x1c, 0x31, 0x13, 0x94, 0xf7, 0xc8, 0x9d, 0x69, 0xa9, 0x20, 0xcd, 0x0, 0xc0}, - output256: []byte{0x7c, 0xb, 0xda, 0x7c, 0xb4, 0x2d, 0xad, 0xbd, 0x3, 0x7f, 0x50, 0xa5, 0xf2, 0x7e, 0x3a, 0xb5, 0xda, 0x25, 0x8d, 0x46, 0x70, 0xf1, 0xbe, 0xa9, 0x1, 0x54, 0xc8, 0x7c, 0x98, 0x13, 0x6b, 0xa1}, - output384: []byte{0xb0, 0xa1, 0xbb, 0xa9, 0x12, 0xda, 0xa6, 0xd8, 0xe, 0xdc, 0x65, 0x19, 0xb5, 0x1, 0xb6, 0x29, 0x45, 0x63, 0x94, 0xd7, 0xbd, 0xa2, 0x4d, 0x46, 0xaf, 0xc9, 0xfc, 0x1d, 0x93, 0xa0, 0xb5, 0x96, 0x2f, 0xa4, 0xf9, 0x52, 0x14, 0x27, 0x32, 0x90, 0xd3, 0x2b, 0x3e, 0xae, 0xff, 0x6f, 0x9d, 0xfe}, - output512: []byte{0xe3, 0xc0, 0xea, 0xff,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, 0xf0, 0xc8, 0xf9, 0xd1, 0xb0, 0x4c, 0x64, 0x5b, 0xa1, 0x4, 0x1c, 0x7d, 0x8d, 0xbf, 0x22, 0x3, 0xa, 0x62, 0x3a, 0xa1, 0x56, 0x38, 0xb3, 0xd9, 0x9a, 0x2c, 0x40, 0xf, 0xf7, 0x6f, 0x32, 0x52, 0x7, 0x9a, 0xf8, 0x8d, 0x2b, 0x37, 0xf3, 0x5e, 0xe6, 0x6c, 0x1a, 0xd7, 0x80, 0x1a, 0x28, 0xd3, 0xd3, 0x88, 0xac, 0x45, 0xb, 0x97, 0xd5, 0xf0, 0xf7, 0x9e, 0x45, 0x41, 0x75, 0x53, 0x56, 0xb3, 0xb1, 0xa5, 0x69, 0x6b, 0x2, 0x3f, 0x39, 0xab, 0x7a, 0xb5, 0xf2, 0x8d, 0xf4, 0x20, 0x29, 0x36, 0xbc, 0x97, 0x39, 0x3b, 0x93, 0xbc, 0x91, 0x5c, 0xb1, 0x59, 0xea, 0x1b, 0xd7, 0xa0, 0xa4, 0x14, 0xcb, 0x4b, 0x7a, 0x1a, 0xc3, 0xaf, 0x68, 0xf5, 0xd, 0x79, 0xf0, 0xc9, 0xc7, 0x31, 0x4e, 0x75, 0xf, 0x7d, 0x2, 0xfa, 0xa5, 0x8b, 0xfa}, - output224: []byte{0x82, 0x1, 0x1, 0xf5, 0x43, 0x5d, 0x86, 0xe1, 0x9b, 0xec, 0x58, 0xed, 0xe, 0x1c, 0x7e, 0x63, 0xf, 0xe8, 0x2d, 0xd9, 0x2d, 0x77, 0x4, 0xe4, 0x14, 0x80, 0x2a, 0x16}, - output256: []byte{0xf6, 0xc, 0x53, 0xba, 0x21, 0x32, 0x29, 0x3b, 0x88, 0x1f, 0x5, 0x13, 0xe7, 0xab, 0x47, 0xfe, 0x97, 0x46, 0xed, 0x4a, 0x6a, 0xc9, 0xca, 0xde, 0x61, 0xe6, 0xd8, 0x2, 0xd5, 0x87, 0x23, 0x72}, - output384: []byte{0xfc, 0x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, 0xbb, 0x61, 0x15, 0x12, 0x61, 0x49, 0x29, 0x62, 0x78, 0xbf, 0xf3, 0xd5, 0x39, 0x5c, 0xf5, 0xf1, 0x12, 0xd4}, - output256: []byte{0x1c, 0x66, 0xb9, 0xa7, 0xc5, 0xe, 0xd7, 0x7d, 0x17, 0x9a, 0xc, 0x43, 0x7d, 0x58, 0x90, 0xc9, 0x83, 0x5a, 0x13, 0xf9, 0xa, 0x73, 0xa0, 0x13, 0x32, 0xab, 0x7, 0x31, 0xa4, 0x1a, 0x11, 0x5e}, - output384: []byte{0x2b, 0x54, 0x71, 0xfa, 0xe3, 0x80, 0x58, 0x52, 0xf4, 0xcf, 0x39, 0x54, 0x1f, 0x8a, 0xa, 0x37, 0x74, 0x81, 0x8f, 0x79, 0xfe, 0x50, 0x47, 0x6e, 0x22, 0x5d, 0x89, 0xb6, 0x2e, 0x43, 0xbe, 0x32, 0x55, 0xe9, 0x6d, 0x19, 0xcb, 0xc3, 0x34, 0xae, 0xf0, 0x41, 0x92, 0x84, 0xf, 0x7, 0x5c, 0x7d}, - output512: []byte{0x6b, 0xcd, 0x7e, 0x7c, 0x35, 0x9f, 0xdd, 0x93, 0xa5, 0x6d, 0x79, 0xf9, 0x7f, 0xc2, 0xd5, 0x34, 0x61, 0x9f, 0x14, 0xfe, 0x44, 0x3a, 0xc8, 0xc9, 0xe0, 0x42, 0xc5, 0x10, 0x5f, 0xba, 0xf2, 0x77, 0x77, 0x18, 0xde, 0x7, 0x42, 0x4a, 0x62, 0x33, 0x3f, 0xfd, 0x43, 0xa5, 0x1, 0xa8, 0x54, 0x44, 0x49, 0xa7, 0xca, 0xc3, 0xc8, 0xd8, 0x21, 0xe3, 0x80, 0xb0, 0xcb, 0x81, 0x72, 0xb9, 0x49, 0x3b}, - }, - { - msg: []byte{0x3, 0xd6, 0x25, 0x48, 0x83, 0x54, 0xdf, 0x30, 0xe3, 0xf8, 0x75, 0xa6, 0x8e, 0xdf, 0xcf, 0x34, 0xe, 0x83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89, 0xcb, 0x32, 0x82, 0xae, 0x3e, 0xaa, 0xc6, 0x15, 0x2e, 0xd2, 0x4d, 0x2c, 0x92, 0xba, 0xe5, 0xa7, 0x65, 0x82, 0x52, 0xa5, 0x3c, 0x49, 0xb7, 0xb0, 0x2d, 0xfe, 0x54, 0xfd, 0xb2, 0xe9, 0x0, 0x74, 0xb6, 0xcf, 0x31, 0xa, 0xc6, 0x61}, - output224: []byte{0xb6, 0x2, 0x72, 0x2d, 0x1b, 0x9f, 0x31, 0xb9, 0xc5, 0x9, 0x1e, 0xf, 0xf7, 0x20, 0xf1, 0xd1, 0xa8, 0xa5, 0x1e, 0xb6, 0xf9, 0x5e, 0xd3, 0xb4, 0x12, 0xde, 0x6, 0x3d}, - output256: []byte{0x48, 0xa0, 0xb, 0xa2, 0x24, 0xac, 0x55, 0x58, 0xf4, 0x1a, 0x79, 0xf5, 0x21, 0x37, 0xdb, 0x91, 0x82, 0xa9, 0x3f, 0x10, 0x45, 0xd4, 0x37, 0x89, 0xe5, 0x91, 0x3d, 0x7b, 0xe4, 0x4, 0x8, 0xc2}, - output384: []byte{0xd4, 0xd3, 0xb4, 0x98, 0x78, 0xae, 0xc7, 0x2e, 0x2e, 0x7f, 0xaf, 0xb6, 0x87, 0xda, 0x7e, 0xfe, 0x24, 0x2c, 0xb6, 0xa, 0xdf, 0x5c, 0x65, 0xc5, 0x77, 0xc4, 0x44, 0xcf, 0xc9, 0x5a, 0x2a, 0x2e, 0xc6, 0x70, 0x0, 0xc, 0x8a, 0x78, 0x89, 0x8a, 0x7, 0x40, 0xe, 0x35, 0x2, 0xd7, 0x3f, 0x27}, - output512: []byte{0x1f, 0xcd, 0x1e, 0x38, 0xab, 0x3, 0xc7, 0x50, 0x36, 0x6c, 0xf8, 0x6d, 0xd7, 0x2e, 0xc3, 0xbf, 0x22, 0xf5, 0xbb, 0xf7, 0xfe, 0xa0, 0x14, 0x9d, 0x31, 0xb6, 0xa6, 0x7b, 0x68, 0xb5, 0x37, 0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, 0x9a, 0xa0, 0xad, 0xe, 0x30, 0x6c, 0xb2, 0x8b, 0xf0, 0xac, 0xf1, 0x6, 0xf8, 0x9a, 0xf3, 0x74, 0x5f, 0xe, 0xc7, 0x2d, 0x53, 0x49, 0x68, 0xcc, 0xa5, 0x43, 0xcd, 0x2c, 0xa5, 0xc, 0x94, 0xb1, 0x45, 0x67, 0x43, 0x25, 0x4e, 0x35, 0x8c, 0x13, 0x17, 0xc0, 0x7a, 0x7, 0xbf, 0x2b, 0xe, 0xca, 0x43, 0x8a, 0x70, 0x93, 0x67, 0xfa, 0xfc, 0x89, 0xa5, 0x72, 0x39, 0x2, 0x8f, 0xc5, 0xfe, 0xcf, 0xd5, 0x3b, 0x8e, 0xf9, 0x58, 0xef, 0x10, 0xee, 0x6, 0x8, 0xb7, 0xf5, 0xcb, 0x99, 0x23, 0xad, 0x97, 0x5, 0x8e, 0xc0, 0x67, 0x70, 0xc, 0xc7, 0x46, 0xc1, 0x27, 0xa6, 0x1e, 0xe3}, - output224: []byte{0x13, 0x68, 0x45, 0x4e, 0x84, 0x9f, 0x2d, 0x22, 0x99, 0x7, 0x7f, 0x40, 0x82, 0x6b, 0x40, 0x72, 0xe6, 0xfe, 0xe4, 0x9b, 0x20, 0x62, 0xcb, 0x8e, 0x3b, 0x45, 0x23, 0xc9}, - output256: []byte{0x24, 0xa, 0x85, 0xea, 0xf7, 0xf3, 0x1, 0x6c, 0x19, 0x2a, 0xd5, 0xe1, 0x7e, 0x5f, 0x93, 0xb6, 0x43, 0xfe, 0x3e, 0xdb, 0xa7, 0x19, 0xf4, 0x23, 0x69, 0x3a, 0x34, 0xda, 0x37, 0x84, 0x82, 0x7a}, - output384: []byte{0xfe, 0x1c, 0x21, 0x43, 0xf2, 0x95, 0x78, 0x19, 0xdf, 0x9c, 0x9d, 0xd0, 0x5d, 0x0, 0x4b, 0xe0, 0xe5, 0x57, 0xee, 0xd8, 0xc5, 0xa2, 0xb7, 0xce, 0x45, 0x7d, 0x58, 0x56, 0x13, 0x2b, 0x1c, 0x43, 0xee, 0xce, 0xc3, 0x6a, 0xd7, 0x4, 0xa9, 0x30, 0xa8, 0x54, 0x85, 0xa3, 0x4c, 0x38, 0x60, 0xfe}, - output512: []byte{0xf3, 0x9e, 0xf0, 0x62, 0x6d, 0x3f, 0xbd, 0x9c, 0xd4, 0x35, 0xa9, 0x3e, 0x7e, 0xee, 0x41, 0xe4, 0xa2, 0xff, 0x53, 0x62, 0xf5, 0x6c, 0x98, 0x8b, 0x20, 0x87, 0xa, 0x3b, 0xef, 0xa5, 0x4, 0x70, 0xdc, 0x5f, 0xab, 0xe3, 0x98, 0x95, 0xc0, 0x76, 0x12, 0x89, 0xfa, 0xfd, 0x91, 0x47, 0xab, 0xab, 0x2, 0x56, 0x1f, 0x30, 0xd, 0xc, 0xeb, 0x9a, 0x73, 0x2e, 0x14, 0xca, 0x88, 0x7c, 0xaf, 0x18}, - }, - { - msg: []byte{0x90, 0xb2, 0x8a, 0x6a, 0xa1, 0xfe, 0x53, 0x39, 0x15, 0xbc, 0xb8, 0xe8, 0x1e, 0xd6, 0xca, 0xcd, 0xc1, 0x9, 0x62, 0xb7, 0xff, 0x82, 0x47, 0x4f, 0x84, 0x5e, 0xeb, 0x86, 0x97, 0x76, 0x0, 0xcf, 0x70, 0xb0, 0x7b, 0xa8, 0xe3, 0x79, 0x61, 0x41, 0xee, 0x34, 0xe, 0x3f, 0xce, 0x84, 0x2a, 0x38, 0xa5, 0xa, 0xfb, 0xe9, 0x3, 0x1, 0xa3, 0xbd, 0xcc, 0x59, 0x1f, 0x2e, 0x7d, 0x9d, 0xe5, 0x3e, 0x49, 0x55, 0x25, 0x56, 0xb, 0x90, 0x8c, 0x89, 0x24, 0x39, 0x99, 0xa, 0x2c, 0xa2, 0x67, 0x9c, 0x55, 0x39, 0xff, 0xdf, 0x63, 0x67, 0x77, 0xad, 0x9c, 0x1c, 0xde, 0xf8, 0x9, 0xcd, 0xa9, 0xe8, 0xdc, 0xdb, 0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, 0x91, 0xb4, 0xb8, 0x64, 0x1e, 0x68, 0xd4, 0x54, 0xd2, 0xd9, 0xc3, 0x4c, 0xe4, 0x3a, 0x5b, 0x55, 0xdd, 0x57, 0x59, 0x7, 0x16, 0xb8, 0xa4, 0x6c, 0xf7}, - output384: []byte{0x4d, 0x1f, 0x62, 0x66, 0x88, 0xe6, 0x89, 0x9b, 0x5f, 0xcc, 0xd4, 0x7f, 0xaa, 0xb4, 0x5e, 0x96, 0xc6, 0x1e, 0x16, 0x98, 0x69, 0xca, 0xbe, 0xf4, 0x2, 0x83, 0xb2, 0x41, 0x8d, 0xfb, 0x28, 0x88, 0xfb, 0x80, 0xcc, 0x9f, 0x2c, 0x52, 0x64, 0x97, 0xc5, 0xc, 0x52, 0x44, 0x78, 0x4f, 0x19, 0x5c}, - output512: []byte{0x81, 0xe8, 0xb5, 0x9d, 0xdc, 0xd2, 0x48, 0x11, 0xb4, 0x5, 0xf7, 0x52, 0x9d, 0xa1, 0x25, 0xf0, 0xdc, 0x19, 0xae, 0x21, 0xe8, 0x79, 0x5c, 0xe9, 0xe6, 0x69, 0x2d, 0xab, 0x64, 0x5b, 0x79, 0x59, 0x44, 0x6a, 0xdc, 0xaa, 0x30, 0x61, 0xdc, 0x46, 0x42, 0xa5, 0x1d, 0x8a, 0x56, 0x2e, 0xfb, 0x3, 0xa7, 0x68, 0xa, 0xf0, 0xf5, 0x2c, 0x1, 0x40, 0x6d, 0x5c, 0x21, 0x3e, 0xaa, 0xc6, 0xbe, 0x55}, - }, - { - msg: []byte{0x29, 0x69, 0x44, 0x7d, 0x17, 0x54, 0x90, 0xf2, 0xaa, 0x9b, 0xb0, 0x55, 0x1, 0x4d, 0xbe, 0xf2, 0xe6, 0x85, 0x4c, 0x95, 0xf8, 0xd6, 0x9, 0x50, 0xbf, 0xe8, 0xc0, 0xbe, 0x8d, 0xe2, 0x54, 0xc2, 0x6b, 0x2d, 0x31, 0xb9, 0xe4, 0xde, 0x9c, 0x68, 0xc9, 0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, 0x2a, 0x54, 0x7e, 0xf2, 0xbb, 0xe5, 0x79, 0x9a, 0xbe, 0xdc, 0xf5, 0xe1, 0xf3, 0x72, 0xea, 0x80, 0x92, 0x33, 0xf0, 0x6}, - output224: []byte{0xb8, 0xfb, 0x31, 0x82, 0x45, 0xb4, 0x4, 0x22, 0x22, 0xb4, 0x6, 0x3a, 0x5, 0x3f, 0x15, 0xda, 0x6b, 0x89, 0x4f, 0x22, 0x73, 0x6f, 0x3f, 0x9e, 0x26, 0xf7, 0x21, 0x75}, - output256: []byte{0x58, 0xc4, 0x69, 0xe1, 0xa7, 0x68, 0x35, 0xcc, 0x1a, 0x89, 0x7b, 0x88, 0x5b, 0x1b, 0x2a, 0x33, 0xb0, 0xaa, 0xbc, 0xe4, 0xcf, 0xbb, 0x65, 0x52, 0x3d, 0x2e, 0xd, 0x8, 0xd6, 0xd1, 0xa4, 0x13}, - output384: []byte{0xa0, 0x63, 0xd7, 0x78, 0xb0, 0xa2, 0xa1, 0x1d, 0x3a, 0x9c, 0xba, 0x42, 0x5e, 0xe5, 0x93, 0x8f, 0xca, 0xa6, 0xe2, 0xbf, 0x1f, 0x30, 0xa6, 0x65, 0xfa, 0x81, 0x16, 0x1, 0x44, 0x4d, 0x57, 0x49, 0xaf, 0xa1, 0x87, 0x66, 0xdb, 0x5f, 0x4, 0x26, 0xc5, 0xb8, 0x39, 0x22, 0x38, 0xb7, 0x86, 0x2e}, - output512: []byte{0x63, 0x42, 0x4b, 0x9, 0x6, 0x9f, 0xbd, 0x2d, 0xf, 0xac, 0x0, 0x80, 0x5a, 0xad, 0x7, 0xfd, 0x56, 0xe3, 0xb, 0xb8, 0x11, 0x6b, 0x54, 0x76, 0xae, 0x90, 0xbf, 0x6a, 0xce, 0xc8, 0x4c, 0x3b, 0x45, 0x36, 0x8a, 0x9e, 0xbb, 0x7f, 0xce, 0xa8, 0xd6, 0x59, 0x65, 0xf5, 0x25, 0x14, 0xa2, 0xa5, 0x9a, 0x6, 0xe6, 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95, 0x92, 0x14, 0x6f, 0xfb, 0xe, 0xf3, 0xf3, 0xdb, 0x30, 0x8f, 0xb3, 0x42, 0xdf, 0x5e, 0xb5, 0x92, 0x4a, 0x48, 0x25, 0x6f, 0xc7, 0x63, 0x14, 0x1a, 0x27, 0x88, 0x14, 0xc8, 0x2d, 0x6d, 0x63, 0x48, 0x57, 0x75, 0x45, 0x87, 0xa, 0xe3, 0xa8, 0x3c, 0x72, 0x30, 0xac, 0x2, 0xa1, 0x54, 0xf, 0xe1, 0x79, 0x8f, 0x7e, 0xf0, 0x9e, 0x33, 0x5a, 0x86, 0x5a, 0x2a, 0xe0, 0x94, 0x9b, 0x21, 0xe4, 0xf7, 0x48, 0xfb, 0x8a, 0x51, 0xf4, 0x47, 0x50, 0xe2, 0x13, 0xa8, 0xfb}, - output224: []byte{0x35, 0x36, 0x22, 0xe9, 0x2c, 0x79, 0x7, 0xf5, 0x56, 0x3b, 0xaf, 0x8f, 0x4e, 0x7a, 0xf0, 0xc2, 0xf8, 0x72, 0xf4, 0xfb, 0x58, 0x3b, 0x1, 0xaf, 0x9e, 0xb3, 0xd9, 0x7}, - output256: []byte{0x6c, 0x8d, 0xf8, 0x1b, 0x1e, 0x1e, 0xd7, 0xa, 0x54, 0x13, 0x36, 0x80, 0x18, 0xdb, 0x96, 0x28, 0xb0, 0xe0, 0xb4, 0x56, 0x34, 0x23, 0xc0, 0x51, 0xa5, 0x4d, 0x0, 0xa, 0xad, 0xde, 0xc, 0x6}, - output384: []byte{0x47, 0xe, 0xe6, 0xd3, 0x51, 0x57, 0x84, 0x68, 0x90, 0xa0, 0x1b, 0x38, 0x9, 0xeb, 0x92, 0x3c, 0xc4, 0x5d, 0xff, 0xf2, 0xfc, 0xa2, 0x82, 0x6f, 0x45, 0x83, 0x25, 0x46, 0x6c, 0x98, 0x3b, 0x1c, 0x64, 0xbe, 0xa3, 0x8b, 0xca, 0xec, 0xa9, 0x21, 0xc9, 0xd, 0xd0, 0x4, 0x32, 0xec, 0xcf, 0x89}, - output512: []byte{0x1e, 0x70, 0x9f, 0xb3, 0x50, 0x1f, 0xa8, 0x18, 0xf5, 0x7e, 0x70, 0xc3, 0x65, 0xdb, 0x45, 0xcc, 0xf2, 0xeb, 0x8a, 0x8f, 0xa6, 0x6d, 0xe9, 0xb5, 0xf2, 0x11, 0xd6, 0xf0, 0xcc, 0x97, 0x22, 0xad, 0xe9, 0x63, 0xc9, 0x65, 0xad, 0x5f, 0x69, 0x37, 0xba, 0x62, 0xed, 0xc2, 0xd8, 0x98, 0x38, 0x43, 0xe0, 0xf3, 0x67, 0x9d, 0x9c, 0x97, 0xb3, 0xc, 0xd5, 0x4f, 0x24, 0x9, 0xdd, 0xa5, 0xf4, 0x74}, - }, - { - msg: []byte{0x6b, 0x86, 0xd, 0x39, 0x72, 0x5a, 0x14, 0xb4, 0x98, 0xbb, 0x71, 0x45, 0x74, 0xb4, 0xd3, 0x7c, 0xa7, 0x87, 0x40, 0x47, 0x68, 0xf6, 0x4c, 0x64, 0x8b, 0x17, 0x51, 0xb3, 0x53, 0xac, 0x92, 0xba, 0xc2, 0xc3, 0xa2, 0x8e, 0xa9, 0x9, 0xfd, 0xf0, 0x42, 0x33, 0x36, 0x40, 0x1a, 0x2, 0xe6, 0x3e, 0xc2, 0x43, 0x25, 0x30, 0xd, 0x82, 0x3b, 0x68, 0x64, 0xbb, 0x70, 0x1f, 0x9d, 0x7c, 0x7a, 0x1f, 0x8e, 0xc9, 0xd0, 0xae, 0x35, 0x84, 0xaa, 0x6d, 0xd6, 0x2e, 0xa1, 0x99, 0x7c, 0xd8, 0x31, 0xb4, 0xba, 0xbd, 0x9a, 0x4d, 0xa5, 0x9, 0x32, 0xd4, 0xef, 0xda, 0x74, 0x5c, 0x61, 0xe4, 0x13, 0x8, 0x90, 0xe1, 0x56, 0xae, 0xe6, 0x11, 0x37, 0x16, 0xda, 0xf9, 0x57, 0x64, 0x22, 0x2a, 0x91, 0x18, 0x7d, 0xb2, 0xef, 0xfe, 0xa4, 0x9d, 0x5d, 0x5, 0x96, 0x10, 0x2d, 0x61, 0x9b, 0xd2, 0x6a, 0x61, 0x6b, 0xbf, 0xda, 0x83, 0x35, 0x50, 0x5f, 0xbb, 0xd, 0x90, 0xb4, 0xc1, 0x80, 0xd1, 0xa2, 0x33, 0x5b, 0x91, 0x53, 0x8e, 0x16, 0x68, 0xf9, 0xf9, 0x64, 0x27, 0x90, 0xb4, 0xe5, 0x5f, 0x9c, 0xab, 0xf, 0xe2, 0xbd, 0xd2, 0x93, 0x5d, 0x0, 0x1e, 0xe6, 0x41, 0x9a, 0xba, 0xb5, 0x45, 0x78, 0x80, 0xd0, 0xdb, 0xff, 0x20, 0xed, 0x87, 0x58, 0xf4, 0xc2, 0xf, 0xe7, 0x59, 0xef, 0xb3, 0x31, 0x41, 0xcf, 0xe, 0x89, 0x25, 0x87, 0xfe, 0x81, 0x87, 0xe5, 0xfb, 0xc5, 0x77, 0x86, 0xb7, 0xe8, 0xb0, 0x89, 0x61, 0x2c, 0x93, 0x6d, 0xfc, 0x3, 0xd2, 0x7e, 0xfb, 0xbe, 0x7c, 0x86, 0x73, 0xf1, 0x60, 0x6b, 0xd5, 0x1d, 0x5f, 0xf3, 0x86, 0xf4, 0xa7, 0xab, 0x68, 0xed, 0xf5, 0x9f, 0x38, 0x5e, 0xb1, 0x29, 0x1f, 0x11, 0x7b, 0xfe, 0x71, 0x73, 0x99}, - output224: []byte{0x87, 0x21, 0x5a, 0xf7, 0x3d, 0x5c, 0xde, 0x98, 0xb3, 0x55, 0x47, 0x9a, 0xfb, 0x82, 0xa5, 0x11, 0x18, 0xb, 0x7d, 0xc3, 0xd5, 0x34, 0x2c, 0x88, 0xe1, 0x33, 0xae, 0xd8}, - output256: []byte{0x10, 0x8f, 0xff, 0x41, 0xd5, 0xbc, 0xf6, 0x54, 0x7, 0x1b, 0x44, 0x14, 0xe6, 0x66, 0xfd, 0xeb, 0xbe, 0x87, 0x8c, 0x30, 0x9d, 0x6d, 0xdc, 0x90, 0xaf, 0xaf, 0x5c, 0x61, 0xdf, 0x85, 0x59, 0xf0}, - output384: []byte{0xa8, 0xf0, 0xa3, 0xc8, 0x9c, 0xf7, 0xe5, 0x6a, 0xcc, 0x18, 0xac, 0xe1, 0x63, 0x8b, 0xcf, 0x13, 0x30, 0x94, 0xfd, 0x9f, 0x75, 0xf0, 0x56, 0x77, 0xc3, 0xcd, 0xe, 0xd3, 0x61, 0x4a, 0x59, 0x3c, 0xbc, 0xeb, 0x9, 0xc7, 0x8c, 0x86, 0xe3, 0x50, 0xfd, 0x7, 0xff, 0x44, 0x29, 0xa6, 0xa1, 0x65}, - output512: []byte{0x5b, 0x9f, 0xc, 0x54, 0x46, 0x27, 0xfa, 0xad, 0xea, 0x82, 0x82, 0x5a, 0x56, 0x9d, 0xa3, 0x3a, 0x75, 0xc5, 0xda, 0x6c, 0xc1, 0x69, 0x92, 0x6d, 0xe0, 0x55, 0x6a, 0x73, 0x7e, 0x4d, 0xaa, 0x7, 0xab, 0xf1, 0xdc, 0x3d, 0xb0, 0x70, 0x4f, 0x5d, 0x67, 0xfc, 0xbc, 0x4c, 0xb6, 0x2a, 0xac, 0x44, 0x2e, 0xce, 0xc8, 0x67, 0xa2, 0xc1, 0x68, 0x46, 0xf1, 0xd5, 0x3d, 0x20, 0x5c, 0xb8, 0x72, 0xac}, - }, - { - msg: []byte{0x6a, 0x1, 0x83, 0xa, 0xf3, 0x88, 0x9a, 0x25, 0x18, 0x32, 0x44, 0xde, 0xcb, 0x50, 0x8b, 0xd0, 0x12, 0x53, 0xd5, 0xb5, 0x8, 0xab, 0x49, 0xd, 0x31, 0x24, 0xaf, 0xbf, 0x42, 0x62, 0x6b, 0x2e, 0x70, 0x89, 0x4e, 0x9b, 0x56, 0x2b, 0x28, 0x8d, 0xa, 0x24, 0x50, 0xcf, 0xac, 0xf1, 0x4a, 0xd, 0xda, 0xe5, 0xc0, 0x47, 0x16, 0xe5, 0xa0, 0x8, 0x2c, 0x33, 0x98, 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 0xaf, 0x7b}, - output224: []byte{0x25, 0xae, 0x85, 0x2d, 0xba, 0x36, 0xb8, 0xd5, 0x8a, 0x94, 0xdd, 0x5c, 0xfd, 0x83, 0x45, 0x14, 0x1f, 0xf5, 0x7e, 0x7d, 0xb7, 0xd7, 0x81, 0x6c, 0x4f, 0x72, 0x52, 0xbb}, - output256: []byte{0x75, 0x1e, 0xaa, 0xaf, 0xa4, 0xae, 0xc8, 0xac, 0xd2, 0x66, 0x6, 0xd6, 0x43, 0x9c, 0x55, 0xb5, 0xc6, 0x6e, 0xc7, 0xdb, 0x80, 0x75, 0x79, 0xed, 0xc6, 0x89, 0x94, 0xb3, 0x0, 0xf7, 0xa0, 0x77}, - output384: []byte{0xc8, 0xa9, 0xa2, 0x44, 0x64, 0xf2, 0x1b, 0x13, 0x3e, 0xbe, 0x20, 0xba, 0x42, 0x1a, 0x81, 0xee, 0x34, 0xdc, 0xea, 0xcd, 0x5f, 0x4, 0xdc, 0xfb, 0x66, 0xd2, 0x19, 0xf7, 0xf4, 0x14, 0x56, 0x33, 0x69, 0x2c, 0x57, 0x2b, 0x63, 0x0, 0x78, 0x34, 0xa4, 0x6, 0xec, 0xfb, 0x93, 0x8a, 0x14, 0xf6}, - output512: []byte{0x93, 0xa, 0xb4, 0x2a, 0x9f, 0x5f, 0x5b, 0xc5, 0xf2, 0x22, 0x2c, 0x74, 0x8f, 0x24, 0x78, 0xa0, 0xf, 0x40, 0xc3, 0xb6, 0xd6, 0x48, 0x7d, 0x6d, 0x7e, 0xd0, 0xd7, 0x11, 0x0, 0xf4, 0xf, 0xcb, 0xb2, 0xc6, 0x65, 0x66, 0xea, 0x26, 0xad, 0xa, 0x41, 0x76, 0x29, 0xf5, 0xa6, 0x1d, 0xca, 0x41, 0x1c, 0xcd, 0x21, 0xf7, 0x36, 0x7d, 0x30, 0x8f, 0x3b, 0x1b, 0x24, 0x90, 0x18, 0x24, 0xfa, 0x9b}, - }, - { - msg: []byte{0xb3, 0xc5, 0xe7,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d, 0xff, 0x6a, 0xb0, 0x75, 0x89, 0x99, 0xaa, 0xd2, 0x14, 0xd0, 0x7b, 0xd4, 0xf1, 0x33, 0xa6, 0x73, 0x4f, 0xde, 0x44, 0x5f, 0xe4, 0x74, 0x71, 0x1b, 0x69, 0xa9, 0x8f, 0x7e, 0x2b}, - output224: []byte{0xec, 0xe0, 0x39, 0x44, 0x18, 0xf0, 0x66, 0xf5, 0x50, 0x23, 0x79, 0x75, 0x51, 0xe0, 0x6f, 0x6a, 0x7d, 0x16, 0x45, 0x68, 0x2a, 0xa4, 0xd9, 0xdd, 0x75, 0xaf, 0x8e, 0x76}, - output256: []byte{0x90, 0xc2, 0xd5, 0xf8, 0xe2, 0x6b, 0xb, 0xdd, 0xea, 0x71, 0x90, 0x64, 0xbb, 0x2, 0xa6, 0x24, 0x2f, 0x2c, 0xc5, 0xa4, 0x29, 0x36, 0xb1, 0x4f, 0xe1, 0x7f, 0x86, 0x1b, 0x47, 0xb7, 0xe1, 0x86}, - output384: []byte{0x91, 0xba, 0xda, 0x31, 0xb5, 0x7a, 0x4b, 0xf3, 0xd2, 0xeb, 0x19, 0xa3, 0x4f, 0xf9, 0x21, 0xdb, 0x10, 0xbd, 0x64, 0x6, 0x19, 0x14, 0x86, 0xd2, 0x5d, 0x5c, 0xa4, 0xde, 0x5e, 0x0, 0xb5, 0xe2, 0x81, 0x5d, 0xae, 0x74, 0x10, 0x64, 0xe5, 0xb8, 0x77, 0xac, 0x57, 0x51, 0x1b, 0x94, 0x9f, 0x91}, - output512: []byte{0x8, 0x20, 0x39, 0x43, 0xc5, 0x82, 0x10, 0xd3, 0xf8, 0x27, 0x58, 0x27, 0x2b, 0xef, 0xbb, 0x92, 0x34, 0xfe, 0x91, 0x34, 0x9, 0xa0, 0x79, 0x44, 0x64, 0x59, 0x59, 0xb1, 0xa6, 0xaf, 0x2f, 0x43, 0x63, 0xab, 0xd7, 0x45, 0x12, 0x32, 0x62, 0x3d, 0xaa, 0x8e, 0x65, 0x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, 0x41, 0x72, 0x92, 0x8c, 0xb1, 0xe, 0x16, 0xab, 0x3c, 0xdb, 0x33, 0xf8, 0x15, 0x10, 0x3b, 0x0, 0xa, 0x6c, 0x7d, 0x62, 0x37, 0x6c, 0xad, 0x29, 0xaf, 0x3, 0xf4, 0xb2, 0xb0, 0xe1, 0x3}, - output384: []byte{0xcf, 0xd0, 0x5e, 0x8, 0x9, 0x94, 0xfc, 0x6d, 0x7a, 0xef, 0x2d, 0x8c, 0x6e, 0x44, 0xd8, 0xa5, 0xe9, 0xf, 0x5a, 0x23, 0x16, 0x76, 0xe0, 0xfa, 0xe0, 0xd2, 0xb8, 0xce, 0x16, 0x2c, 0xa9, 0xd0, 0x67, 0x12, 0x58, 0xc, 0x99, 0x99, 0x7a, 0x77, 0x9, 0xa0, 0x61, 0x80, 0xdd, 0x42, 0xfb, 0x91}, - output512: []byte{0xcd, 0x1e, 0xd5, 0xff, 0xf6, 0xfa, 0x3d, 0x45, 0x38, 0x72, 0x51, 0xb, 0x6b, 0x27, 0x12, 0xec, 0x9c, 0x6e, 0xba, 0x95, 0x43, 0x73, 0x4d, 0x88, 0x51, 0x1e, 0xd4, 0x75, 0x90, 0x5e, 0x12, 0x3e, 0xd6, 0xef, 0x66, 0x24, 0xf2, 0x20, 0x44, 0x5f, 0xe8, 0x9c, 0x25, 0x7a, 0x9f, 0x9c, 0x51, 0x66, 0xa2, 0x77, 0x2e, 0xf7, 0x68, 0xb5, 0xe, 0x92, 0x90, 0xfb, 0x1d, 0x47, 0x61, 0xec, 0xa6, 0xc8}, - }, - { - msg: []byte{0xa6, 0xfe, 0x30, 0xdc, 0xfc, 0xda, 0x1a, 0x32, 0x9e, 0x82, 0xab, 0x50, 0xe3, 0x2b, 0x5f, 0x50, 0xeb, 0x25, 0xc8, 0x73, 0xc5, 0xd2, 0x30, 0x58, 0x60, 0xa8, 0x35, 0xae, 0xce, 0xe6, 0x26, 0x4a, 0xa3, 0x6a, 0x47, 0x42, 0x99, 0x22, 0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xd9, 0x34, 0x7c, 0x24, 0x36, 0xdf, 0xf3, 0x2c, 0x77, 0x1f, 0x34, 0xa3, 0x85, 0x87, 0xa4, 0x4a, 0x82, 0xc5, 0xd3, 0xd1, 0x37, 0xa0, 0x3c, 0xaa, 0x27, 0xe6, 0x6c, 0x8f, 0xf6}, - output224: []byte{0xd8, 0xc2, 0x57, 0xdb, 0x76, 0x53, 0x6f, 0x7e, 0xf1, 0xdc, 0xfb, 0x24, 0x97, 0x6e, 0xb7, 0x16, 0xd9, 0x49, 0x1c, 0xd8, 0x65, 0x1e, 0x2, 0x54, 0xe7, 0xc4, 0xa5, 0xbb}, - output256: []byte{0xf5, 0xcf, 0xb4, 0xdf, 0x3f, 0x7c, 0x5a, 0x77, 0x8f, 0x38, 0xa3, 0xb4, 0x3b, 0x26, 0x47, 0x9a, 0xe, 0x8a, 0x49, 0x3, 0xc, 0x59, 0xac, 0x19, 0xfb, 0xc, 0xfa, 0x80, 0x60, 0x81, 0xca, 0x4a}, - output384: []byte{0x8f, 0xa2, 0x6d, 0xd5, 0xa5, 0x4b, 0xf9, 0x4a, 0x3, 0x7a, 0x16, 0x5e, 0xc5, 0xce, 0x3e, 0xd8, 0x61, 0x47, 0xa0, 0x8d, 0xcf, 0xe3, 0xb4, 0x88, 0x18, 0xb0, 0xc0, 0xbe, 0xee, 0xfa, 0x33, 0xb1, 0x45, 0x32, 0x3b, 0x59, 0x8f, 0x76, 0x1d, 0xe2, 0xb6, 0x39, 0xd0, 0x51, 0x27, 0xf1, 0xcf, 0x3e}, - output512: []byte{0xcf, 0xaa, 0xe, 0xb1, 0xc9, 0xf0, 0x2c, 0x4, 0x69, 0xee, 0xfb, 0x31, 0xa1, 0xa5, 0x3c, 0xa1, 0xa4, 0x76, 0x5f, 0x78, 0xec, 0x17, 0x1c, 0xf1, 0x5d, 0xa7, 0xd5, 0xc5, 0x12, 0x81, 0x7b, 0x8b, 0xf7, 0xd7, 0xcd, 0x7b, 0x14, 0x16, 0xb3, 0x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0x5b, 0x2, 0x91, 0x94, 0x4c, 0x8b, 0x73, 0xa, 0xd3, 0xd4, 0x78, 0x92, 0x73, 0xfa, 0x44, 0xfb, 0x98, 0xd7, 0x8a, 0x36, 0xc3, 0xc3, 0x76, 0x4a, 0xbe, 0xea, 0xc7, 0xc5, 0x69, 0xc1, 0xe4, 0x3a, 0x35, 0x2e, 0x5b, 0x77, 0xc, 0x35, 0x4, 0xf8, 0x70, 0x90, 0xde, 0xe0, 0x75, 0xa1, 0xc4, 0xc8, 0x5c, 0xc, 0x39, 0xcf, 0x42, 0x1b, 0xdc, 0xc6, 0x15, 0xf9, 0xef, 0xf6, 0xcb, 0x4f, 0xe6, 0x46, 0x80, 0x4, 0xae, 0xce, 0x5f, 0x30, 0xe1, 0xec, 0xc6, 0xdb, 0x22, 0xad, 0x99, 0x39, 0xbb, 0x2b, 0xc, 0xcc, 0x96, 0x52, 0x1d, 0xfb, 0xf4, 0xae, 0x0, 0x8b, 0x5b, 0x46, 0xbc, 0x0, 0x6e}, - output224: []byte{0xf8, 0x1d, 0x8e, 0xe4, 0x8, 0x69, 0xbb, 0x38, 0xa1, 0x3a, 0x4f, 0x75, 0x58, 0x8f, 0xa3, 0x30, 0x80, 0x68, 0xdd, 0x1c, 0xdc, 0x27, 0x26, 0x7d, 0x66, 0xfa, 0xc1, 0x98}, - output256: []byte{0x6, 0xab, 0x8f, 0xdb, 0xe4, 0xdc, 0xe9, 0x35, 0xe4, 0x20, 0x3, 0xc1, 0x7f, 0xf6, 0xb, 0xa2, 0x36, 0xf4, 0x3a, 0x84, 0x39, 0x95, 0xb7, 0xfe, 0xf3, 0xa2, 0x9d, 0xfe, 0xc, 0x82, 0xf1, 0xd4}, - output384: []byte{0x28, 0x3f, 0xd6, 0x1d, 0x1e, 0x50, 0x57, 0x2e, 0xf4, 0x3, 0xbf, 0x9c, 0x55, 0x4d, 0x76, 0xd6, 0x94, 0xa5, 0x4f, 0x90, 0x2c, 0x49, 0x79, 0x5d, 0x1c, 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c, 0x60, 0x85, 0xd5, 0x2b, 0xed}, - output256: []byte{0xc1, 0x1f, 0x35, 0x22, 0xa8, 0xfb, 0x7b, 0x35, 0x32, 0xd8, 0xb, 0x6d, 0x40, 0x2, 0x3a, 0x92, 0xb4, 0x89, 0xad, 0xda, 0xd9, 0x3b, 0xf5, 0xd6, 0x4b, 0x23, 0xf3, 0x5e, 0x96, 0x63, 0x52, 0x1c}, - output384: []byte{0x12, 0x8d, 0xc6, 0x11, 0x76, 0x2b, 0xe9, 0xb1, 0x35, 0xb3, 0x73, 0x94, 0x84, 0xcf, 0xaa, 0xdc, 0xa7, 0x48, 0x1d, 0x68, 0x51, 0x4f, 0x3d, 0xfd, 0x6f, 0x5d, 0x78, 0xbb, 0x18, 0x63, 0xae, 0x68, 0x13, 0x8, 0x35, 0xcd, 0xc7, 0x6, 0x1a, 0x7e, 0xd9, 0x64, 0xb3, 0x2f, 0x1d, 0xb7, 0x5e, 0xe1}, - output512: []byte{0x6e, 0x8b, 0x8b, 0xd1, 0x95, 0xbd, 0xd5, 0x60, 0x68, 0x9a, 0xf2, 0x34, 0x8b, 0xdc, 0x74, 0xab, 0x7c, 0xd0, 0x5e, 0xd8, 0xb9, 0xa5, 0x77, 0x11, 0xe9, 0xbe, 0x71, 0xe9, 0x72, 0x6f, 0xda, 0x45, 0x91, 0xfe, 0xe1, 0x22, 0x5, 0xed, 0xac, 0xaf, 0x82, 0xff, 0xbb, 0xaf, 0x16, 0xdf, 0xf9, 0xe7, 0x2, 0xa7, 0x8, 0x86, 0x20, 0x80, 0x16, 0x6c, 0x2f, 0xf6, 0xba, 0x37, 0x9b, 0xc7, 0xff, 0xc2}, - }, -} diff --git a/vendor/github.com/ebfe/keccak/shake.go b/vendor/github.com/ebfe/keccak/shake.go deleted file mode 100644 index 9970b2d..0000000 --- a/vendor/github.com/ebfe/keccak/shake.go +++ /dev/null @@ -1,15 +0,0 @@ -package keccak - -import ( - "hash" -) - -// NewSHAKE128 returns a new hash.Hash computing SHAKE128 with a n*8 bit output as specified in the FIPS 202 draft. -func NewSHAKE128(n int) hash.Hash { - return newKeccak(128*2, n*8, domainSHAKE) -} - -// NewSHAKE256 returns a new hash.Hash computing SHAKE256 with a n*8 bit output as specified in the FIPS 202 draft. -func NewSHAKE256(n int) hash.Hash { - return newKeccak(256*2, n*8, domainSHAKE) -} diff --git a/vendor/github.com/ebfe/keccak/shake_test.go b/vendor/github.com/ebfe/keccak/shake_test.go deleted file mode 100644 index 8f88cca..0000000 --- a/vendor/github.com/ebfe/keccak/shake_test.go +++ /dev/null @@ -1,28 +0,0 @@ -package keccak - -import ( - "bytes" - "testing" -) - -func TestSHAKE128(t *testing.T) { - for i := range shaketests { - h := NewSHAKE128(len(shaketests[i].output128)) - h.Write(shaketests[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, shaketests[i].output128) { - t.Errorf("testcase SHAKE128 %d: expected %x got %x", i, shaketests[i].output128, d) - } - } -} - -func TestSHAKE256(t *testing.T) { - for i := range shaketests { - h := NewSHAKE256(len(shaketests[i].output256)) - h.Write(shaketests[i].msg) - d := h.Sum(nil) - if !bytes.Equal(d, shaketests[i].output256) { - t.Errorf("testcase SHAKE256 %d: expected %x got %x", i, shaketests[i].output256, d) - } - } -} diff --git a/vendor/github.com/ebfe/keccak/shake_vectors_test.go b/vendor/github.com/ebfe/keccak/shake_vectors_test.go deleted file mode 100644 index bc4a6ec..0000000 --- a/vendor/github.com/ebfe/keccak/shake_vectors_test.go +++ /dev/null @@ -1,1290 +0,0 @@ -package keccak - -type shaketestcase struct { - msg []byte - output128 []byte - output256 []byte -} - -var shaketests = []shaketestcase{ - { - msg: []byte{}, - output128: []byte{0x7f, 0x9c, 0x2b, 0xa4, 0xe8, 0x8f, 0x82, 0x7d, 0x61, 0x60, 0x45, 0x50, 0x76, 0x5, 0x85, 0x3e, 0xd7, 0x3b, 0x80, 0x93, 0xf6, 0xef, 0xbc, 0x88, 0xeb, 0x1a, 0x6e, 0xac, 0xfa, 0x66, 0x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, 0x4e, 0x2b, 0x27, 0xaa, 0x53, 0x39, 0x87, 0x65, 0xd5, 0x35, 0x2b, 0xd1, 0xed, 0xe, 0x9c, 0x7b, 0x3f, 0xb2, 0x64, 0xd1, 0x41, 0x74, 0x16, 0x59, 0xf7, 0xd8, 0xfd, 0xe, 0xee, 0xc9, 0xf9, 0x16, 0x3c, 0x42, 0xaf, 0xdb, 0x54, 0xd, 0x5f, 0x2c, 0x87, 0x83, 0x38, 0x80, 0xa0, 0xc9, 0x42, 0xae, 0x4c, 0xce, 0xa7, 0xff, 0xf2, 0xf4, 0xc7, 0x98, 0xb8, 0xaa, 0xf2, 0x4c, 0x33, 0xbe, 0x80, 0x54, 0xa0, 0x94, 0x59, 0xa3, 0xaf, 0x72, 0x0, 0xd5, 0x55, 0x33, 0x42, 0x41, 0x70, 0x9a, 0x18, 0xec, 0xf8, 0x8c, 0xe9, 0x3c, 0x99, 0x23, 0x4d, 0x6a, 0xb0, 0x28, 0x59, 0x16, 0xae}, - }, - { - msg: []byte{0x1f, 0x87, 0x7c}, - output128: []byte{0xe2, 0xd3, 0x14, 0x46, 0x69, 0xab, 0x57, 0x83, 0x47, 0xfc, 0xca, 0xb, 0x57, 0x27, 0x83, 0xa2, 0x69, 0xa8, 0xcf, 0x9a, 0xdd, 0xa4, 0xd8, 0x77, 0x82, 0x5, 0x3d, 0x80, 0xd5, 0xf0, 0xfd, 0xd2, 0x78, 0x35, 0xcf, 0x88, 0x30, 0x36, 0xe5, 0x36, 0xce, 0x76, 0xfe, 0xf6, 0x89, 0xa5, 0xe7, 0xbd, 0x64, 0x6a, 0x7f, 0xb7, 0xd7, 0x4f, 0x9, 0x1, 0x93, 0xb2, 0x39, 0xe, 0x61, 0x47, 0x59, 0xb7, 0xeb, 0x7d, 0xe9, 0x15, 0xa3, 0x83, 0x28, 0x74, 0x58, 0x90, 0xb1, 0xef, 0x1e, 0x7a, 0xed, 0x78, 0x16, 0x8e, 0x99, 0x6d, 0x7a, 0xc7, 0x74,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x5, 0xd2, 0xaa, 0xeb, 0x56, 0xd1, 0xda, 0x55, 0x27, 0x59, 0x8e, 0x17, 0xe5, 0x68, 0xd, 0x30, 0x97, 0x88, 0xe0, 0x99, 0x10, 0xbe, 0xb7, 0x4d, 0xf7, 0xd3, 0xc3, 0xcd, 0x4e, 0xc6, 0x80, 0x8, 0x3f, 0x58, 0x45, 0xf4, 0xa1, 0xc1, 0x50, 0x70, 0xe5, 0x79, 0x79, 0xc0, 0x1b, 0x89, 0xdf, 0x7b, 0xe6, 0x44, 0x35, 0xea, 0x48, 0x17, 0xbc, 0xa, 0xd2, 0x3a, 0xcc, 0xa6, 0xcb, 0x87, 0x8f, 0x71, 0x31, 0xf0, 0x2f, 0x92, 0x15, 0xe2, 0xd5, 0xc1, 0x2c, 0xf3, 0xb4, 0xd2, 0x4b, 0x29, 0x62, 0xc, 0x89, 0x1a, 0x54, 0xac, 0x8b, 0xe6, 0xe3, 0xde, 0xc0, 0x83, 0x97, 0x88, 0x7d, 0xe0, 0xea, 0x86, 0xb8, 0x1a, 0x54, 0x59, 0xb9, 0x68, 0xfb, 0xae, 0x18, 0xb4, 0xb0, 0x32, 0x4d, 0xe7, 0xe7, 0xc1, 0xae, 0xef, 0xc7, 0x59, 0x86, 0x44, 0xce, 0x1f, 0xf8, 0xf9}, - }, - { - msg: []byte{0x21, 0xf1, 0x34, 0xac, 0x57}, - output128: []byte{0x7b, 0xfb, 0xb4, 0xd, 0xa3, 0x70, 0x4a, 0x55, 0x82, 0x91, 0xb3, 0x9e, 0x1e, 0x56, 0xed, 0x9f, 0x6f, 0x56, 0xae, 0x78, 0x32, 0x70, 0xab, 0x2, 0xa2, 0x2, 0x6, 0xc, 0x91, 0x73, 0xfb, 0xb0, 0xb4, 0x55, 0x75, 0xb3, 0x23, 0x48, 0xa6, 0xed, 0x2c, 0x92, 0x7a, 0x39, 0xa3, 0xd, 0xa0, 0xa2, 0xbb, 0xc1, 0x80, 0x74, 0x97, 0xad, 0x50, 0xf2, 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 0xa1, 0x80, 0x22, 0x15, 0x4c, 0xf0, 0x10, 0xc7, 0x22, 0xc2, 0x79, 0xae, 0x60, 0xaa, 0x98, 0x45, 0x97, 0xec, 0x65, 0x42, 0xee, 0x1a, 0xbd, 0xca, 0xae, 0x8d, 0x55, 0x45, 0xff, 0x45, 0xe7, 0x81, 0xab, 0xc7, 0x14, 0x5a, 0xe2, 0xa3, 0x12, 0x49}, - }, - { - msg: []byte{0xc6, 0xf5, 0xb, 0xb7, 0x4e, 0x29}, - output128: []byte{0x8d, 0x87, 0x6c, 0x67, 0xa5, 0xcc, 0x15, 0xa5, 0x44, 0xeb, 0x81, 0xe9, 0x3b, 0x6f, 0xc1, 0x57, 0x13, 0xfd, 0x1c, 0x55, 0xd7, 0x78, 0x20, 0x4e, 0xb6, 0xaf, 0x70, 0x86, 0xaf, 0x3f, 0xe9, 0x7d, 0x12, 0xb4, 0xdd, 0x22, 0xc7, 0xaa, 0xd5, 0x4e, 0xb9, 0xc9, 0xe3, 0x91, 0xb9, 0xa, 0x7c, 0x55, 0xab, 0xac, 0xc3, 0xc8, 0x1d, 0xd1, 0x78, 0x88, 0x95, 0xf1, 0x70, 0x33, 0xd5, 0x61, 0x6, 0xe, 0x2b, 0x9c, 0xff, 0xd4, 0x79, 0x74, 0xf1, 0x96, 0xc6, 0x90, 0x79, 0x7, 0xdf, 0xdc, 0x65, 0xcd, 0xf3, 0x3b, 0xaa, 0xfa, 0x70, 0x49, 0x63, 0x5a, 0x70, 0x35, 0x3d, 0x92, 0xa5, 0x6a, 0x59, 0xec, 0xf0, 0xcd, 0x29, 0x1a, 0xb9, 0xb5, 0x9, 0xd2, 0x96, 0x35, 0x6e, 0x8b, 0xc, 0x91, 0x98, 0x3d, 0x15, 0x8d, 0xb1, 0x56, 0x86, 0x81, 0xde, 0x3, 0x5e, 0x56, 0xb8, 0x6e, 0xae, 0x32, 0xad, 0x3e, 0x1, 0x93, 0xcb, 0x81, 0x6b, 0xd2, 0xd1, 0x11, 0x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, 0xc2, 0x5c, 0x92, 0x9f, 0xbf, 0x66, 0x2, 0x6f, 0x91, 0x66, 0x49, 0x98, 0xbc, 0x34, 0xf9, 0x68, 0x93, 0x75, 0xd0, 0x6f, 0xf9, 0x5d, 0x20, 0x8d, 0x4a, 0xcc, 0x77, 0x91, 0x63, 0x3b, 0x22, 0x2a, 0xcf, 0xd3, 0xea, 0x26, 0xf8, 0xb5, 0xc4, 0x85, 0x89, 0x97, 0xa1, 0xff, 0x77, 0x5, 0xf, 0x28, 0xa, 0xc7, 0xb7, 0xe5, 0x32, 0x5a, 0xbe, 0x9e, 0x55, 0xfc, 0x27, 0xea, 0x8e, 0xd1, 0xd9, 0xd3, 0x21, 0x94, 0xb0, 0xc5, 0xd8, 0x80, 0x7f, 0x94, 0xae, 0x6f, 0x73, 0x72, 0x76, 0x6, 0x5c, 0xa0, 0x8c, 0x32, 0x3e, 0x9e, 0xd4, 0x21}, - }, - { - msg: []byte{0x4a, 0x4f, 0x20, 0x24, 0x84, 0x51, 0x25, 0x26}, - output128: []byte{0x97, 0x77, 0x35, 0xa8, 0x53, 0xd8, 0x72, 0xff, 0x7c, 0x17, 0xc4, 0xa8, 0x25, 0xaf, 0xd9, 0xdf, 0x88, 0x6a, 0xc4, 0x33, 0x87, 0xdf, 0x24, 0x5c, 0x37, 0xa6, 0x8, 0xac, 0x7f, 0x4e, 0xe, 0xd0, 0x15, 0x81, 0x11, 0x67, 0x22, 0x20, 0x0, 0xae, 0xe1, 0x96, 0x89, 0x60, 0x17, 0x4e, 0xe5, 0xa3, 0x93, 0x69, 0xa2, 0x3c, 0x5d, 0xff, 0xb4, 0x99, 0x1a, 0xd2, 0x47, 0xb8, 0x80, 0x1d, 0xe7, 0x1b, 0xea, 0x97, 0x6, 0x9e, 0xa7, 0x72, 0x2, 0x99, 0x9f, 0x8e, 0x8c, 0xf3, 0x82, 0x98, 0x16, 0xee, 0x59, 0x8b, 0x0, 0xc4, 0x4, 0x92, 0x65, 0xdf, 0xbb, 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, 0xbf, 0x69, 0xeb, 0xd3, 0x59, 0xb8, 0x95, 0x32, 0xa}, - }, - { - msg: []byte{0x1f, 0x66, 0xab, 0x41, 0x85, 0xed, 0x9b, 0x63, 0x75}, - output128: []byte{0x1d, 0x96, 0xe0, 0x45, 0x4b, 0xe0, 0x37, 0xd8, 0x90, 0xfb, 0xeb, 0x77, 0x6c, 0xe5, 0xc9, 0x22, 0xbd, 0xfb, 0x82, 0x7a, 0xf1, 0xd1, 0xab, 0xee, 0x1b, 0xc8, 0xb3, 0xae, 0x95, 0x45, 0x35, 0x32, 0xd4, 0xc, 0xb, 0x3f, 0x9c, 0x93, 0xe4, 0x0, 0xff, 0x70, 0xf6, 0xfb, 0xd4, 0xdd, 0x4, 0x70, 0xdf, 0x1f, 0x6, 0xe0, 0x4a, 0xb4, 0xa5, 0x96, 0xb6, 0xf9, 0x2b, 0xbc, 0xaa, 0xd3, 0x65, 0xd, 0x60, 0xb9, 0x40, 0x9, 0x62, 0x60, 0x22, 0x69, 0x13, 0x43, 0x5c, 0x9b, 0xbf, 0x5f, 0x29, 0xde, 0x8b, 0xcc, 0x97, 0x21, 0x74, 0x8e, 0x3f, 0x1d, 0xeb, 0x7f, 0xae, 0x88, 0x74, 0x10, 0x84, 0x50, 0x7e, 0x1b, 0xa7, 0x2a, 0x26, 0x7c, 0x2c, 0x22, 0x76, 0xd8, 0xbd, 0x8e, 0xd2, 0x84, 0x57, 0x8b, 0x46, 0xae, 0x81, 0x23, 0xf, 0x38, 0x32, 0x14, 0x13, 0x7c, 0xd7, 0xc1, 0x90, 0x52, 0x48, 0x18, 0x57, 0x6f, 0x77, 0xb0, 0xa5, 0x3c, 0x34, 0x21, 0xe0, 0x47, 0x6d, 0x91, 0xe1, 0x1b, 0xae, 0x79, 0xac, 0xc4, 0x99, 0x5a, 0x24, 0xfd, 0x13, 0x98, 0xf6, 0xf6, 0x7e, 0x22, 0x3, 0x3b, 0xc3, 0x81, 0xab, 0xe6, 0xde, 0x4e, 0x5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d7, 0x96, 0x56, 0xeb, 0x44, 0xf9, 0x5c, 0x78, 0xbb, 0xda, 0xfa, 0xa5, 0x9b, 0x7e, 0x36, 0xda, 0x8, 0xa5, 0x8a, 0xf3, 0xda, 0xee, 0x99, 0x53, 0x6e, 0xfb, 0x56, 0x31, 0x96, 0x43, 0xff, 0x42, 0x2c, 0xfb, 0x53, 0xd1, 0x52, 0xea, 0x30, 0x2a, 0x64, 0x58, 0xf5, 0x8b, 0x5e, 0xb9, 0xf2, 0xc8, 0x1c, 0x31, 0xc4}, - }, - { - msg: []byte{0xea, 0xee, 0xd5, 0xcd, 0xff, 0xd8, 0x9d, 0xec, 0xe4, 0x55, 0xf1}, - output128: []byte{0x5, 0x5c, 0xa, 0x82, 0x91, 0x25, 0xf2, 0xa, 0xd, 0xba, 0xa6, 0x10, 0x6d, 0xe9, 0x55, 0x79, 0xbe, 0x41, 0x88, 0x36, 0x3c, 0x7d, 0x7e, 0x3f, 0x3e, 0xfc, 0x40, 0xaf, 0xf3, 0x60, 0x29, 0x88, 0x97, 0x96, 0x8b, 0x25, 0xb, 0x84, 0x10, 0x82, 0x9c, 0xdd, 0xce, 0x5e, 0xdc, 0x80, 0xb7, 0x64, 0xa5, 0xaf, 0xf1, 0x6f, 0xff, 0x1c, 0x3d, 0x29, 0x61, 0x4c, 0x6b, 0xc4, 0xc8, 0xd, 0x9, 0x5f, 0xc, 0x73, 0x44, 0x3e, 0x8f, 0xe5, 0x96, 0xc8, 0x6c, 0x83, 0xac, 0x1d, 0x9b, 0xa6, 0x98, 0x47, 0xf6, 0xe6, 0x4c, 0xa6, 0x43, 0xef, 0x3d, 0x70, 0x10, 0xc5, 0xf9, 0x94, 0x4a, 0x66, 0xb, 0x14, 0x55, 0x9f, 0xf2, 0x7d, 0x4a, 0x5a, 0xa9, 0x86, 0x2c, 0xff, 0xb6, 0x7b, 0x47, 0x81, 0xd, 0x4, 0xc7, 0x36, 0xbf, 0x84, 0x24, 0x50, 0xa7, 0xe5, 0x23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2a, 0x75, 0x87, 0x2c, 0x59, 0x54, 0x78, 0x80, 0x97, 0xe0, 0x48, 0x45}, - }, - { - msg: []byte{0xe2, 0x61, 0x93, 0x98, 0x9d, 0x6, 0x56, 0x8f, 0xe6, 0x88, 0xe7, 0x55, 0x40, 0xae, 0xa0, 0x67, 0x47, 0xd9, 0xf8, 0x51}, - output128: []byte{0xbf, 0xcb, 0xfb, 0x53, 0x1c, 0x16, 0x89, 0x12, 0x6c, 0x23, 0x23, 0xf9, 0x29, 0x4c, 0x1b, 0xea, 0x28, 0x0, 0x13, 0xa2, 0x31, 0x5a, 0x59, 0x6a, 0xda, 0x34, 0xf0, 0x22, 0xbb, 0x6d, 0x3d, 0x8a, 0x69, 0x9b, 0xa8, 0xe2, 0xc5, 0x4a, 0xe3, 0xbb, 0x7b, 0x32, 0xc4, 0x22, 0xc7, 0x27, 0xb4, 0x16, 0x78, 0xf7, 0x81, 0xd6, 0x52, 0xdc, 0xbf, 0x1a, 0x40, 0xb8, 0x62, 0x7b, 0x56, 0xe0, 0x4, 0xaa, 0x5f, 0x17, 0x53, 0xb1, 0x15, 0x29, 0x20, 0x12, 0x1b, 0x1a, 0x2d, 0x8c, 0xd5, 0xe9, 0xca, 0x2, 0x92, 0x9b, 0xe7, 0xf2, 0xeb, 0x43, 0x3b, 0xaa, 0xe2, 0xfa, 0x41, 0x83, 0xf, 0x14, 0x6c, 0x72, 0xa1, 0x2a, 0xaa, 0x97, 0xe8, 0xf8, 0xb8, 0x63, 0x74, 0x9b, 0x30, 0x26, 0xe9, 0x9e, 0xb, 0xb7, 0xe0, 0xa9, 0x37, 0xf0, 0x3, 0x60, 0x4b, 0x47, 0xc, 0x91, 0x35, 0x46, 0xe7, 0x34, 0x13, 0xa8, 0x6e, 0xe2, 0xe9, 0x89, 0x2f, 0xca, 0x2a, 0x78, 0x39, 0xb2, 0x3, 0x9, 0xaf, 0xc1, 0xfc, 0x9a, 0xe, 0xf1, 0x44, 0x78, 0xce, 0xc, 0xcb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, 0xc, 0x9, 0x90, 0x78, 0xc7, 0xc1, 0xc5, 0x7, 0x72, 0x5, 0x7f, 0xe6, 0x5e, 0x95, 0x4f, 0xbf, 0x28, 0xcc, 0x41, 0x4c, 0xbd, 0x5c, 0x2e, 0xb1, 0x2a, 0xe8, 0x6a, 0x9, 0x12, 0xd3, 0x81, 0x2a, 0x4, 0xad, 0xfd}, - }, - { - msg: []byte{0x7b, 0xc8, 0x48, 0x67, 0xf6, 0xf9, 0xe9, 0xfd, 0xc3, 0xe1, 0x4, 0x6c, 0xae, 0x3a, 0x52, 0xc7, 0x7e, 0xd4, 0x85, 0x86, 0xe, 0xe2, 0x60, 0xe3, 0xb, 0x15}, - output128: []byte{0x50, 0x10, 0x2c, 0xb3, 0x9f, 0xfb, 0xd9, 0x8f, 0x34, 0x99, 0xff, 0x53, 0x91, 0x48, 0x70, 0xcb, 0xe4, 0x44, 0xc, 0xa8, 0xb6, 0xd6, 0x1b, 0x79, 0xb7, 0xe6, 0x48, 0x1b, 0x94, 0x3d, 0x8e, 0x53, 0x29, 0x47, 0xd0, 0x6a, 0x5e, 0x4, 0xa6, 0xec, 0x8e, 0x59, 0x59, 0x58, 0x24, 0x50, 0x88, 0xfa, 0x80, 0x76, 0x0, 0xb1, 0x30, 0xe, 0xd4, 0xde, 0x47, 0xa2, 0xe8, 0x0, 0xd8, 0x12, 0xba, 0xda, 0x53, 0x8e, 0x35, 0x1d, 0xac, 0x64, 0xdd, 0x30, 0x43, 0xe7, 0xf6, 0x55, 0xb4, 0x11, 0x24, 0x1c, 0x90, 0x31, 0xed, 0x27, 0x65, 0x26, 0x4e, 0x37, 0x2c, 0x6f, 0x59, 0x43, 0x59, 0x88, 0x96, 0x3e, 0xf8, 0x30, 0x98, 0x45, 0x20, 0x29, 0x76, 0x1d, 0x43, 0xe4, 0xd3, 0x29, 0xcb, 0xbd, 0x4, 0x82, 0x57, 0x19, 0xad, 0xab, 0x19, 0x20, 0xdb, 0xed, 0x99, 0x9c, 0x1c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x12, 0xe6, 0xdd, 0xde, 0x81, 0x3e, 0x33, 0x38, 0xd1, 0x6c, 0x4c, 0x34, 0xd4, 0xc, 0x2e, 0x6e, 0x1c, 0xa6, 0x1f, 0xae, 0xcb, 0x93, 0x4d, 0x4e, 0xd0, 0xbb, 0xa, 0x19, 0xd3, 0xab, 0x88, 0xea, 0x32, 0xf7, 0xe2, 0x77, 0xbf, 0x85, 0x21, 0xaa, 0x73, 0x3d, 0x72, 0x40, 0x39, 0x47, 0x33, 0xa3, 0xa1, 0xfd, 0x76, 0x23, 0x46, 0x38, 0x57, 0xe1, 0x63, 0x3f, 0xf, 0xac, 0xe8, 0xbb, 0x83, 0x43, 0x7d, 0xcc, 0x30, 0x8e, 0x4f, 0x67, 0x91, 0xd8, 0x79, 0xa, 0x54, 0xff, 0x8e, 0x6, 0xf8}, - }, - { - msg: []byte{0x47, 0xf5, 0x69, 0x7a, 0xc8, 0xc3, 0x14, 0x9, 0xc0, 0x86, 0x88, 0x27, 0x34, 0x7a, 0x61, 0x3a, 0x35, 0x62, 0x4, 0x1c, 0x63, 0x3c, 0xf1, 0xf1, 0xf8, 0x68, 0x65, 0xa5, 0x76, 0xe0, 0x28, 0x35, 0xed, 0x2c, 0x24, 0x92}, - output128: []byte{0x6, 0x22, 0xec, 0xab, 0xcd, 0xd9, 0xa8, 0xc2, 0xbc, 0x20, 0xfe, 0xb, 0x9b, 0x39, 0xce, 0x1a, 0x6a, 0x83, 0x5b, 0x51, 0x81, 0x32, 0x77, 0x94, 0xdb, 0x2e, 0x1b, 0x40, 0x7, 0xf, 0xd9, 0xd8, 0x9a, 0x49, 0x8d, 0x24, 0x2a, 0xaa, 0xa8, 0xfb, 0x50, 0x63, 0xd5, 0xe2, 0xaf, 0x45, 0xa1, 0xcd, 0x4, 0xcb, 0x28, 0xb9, 0x6e, 0xdf, 0x84, 0x4a, 0xa3, 0x7c, 0x7c, 0xf6, 0xef, 0xe3, 0x93, 0x63, 0xaa, 0xe5, 0x6e, 0x1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 0x93, 0x14, 0x13, 0x3e, 0x62, 0xc1, 0x4e, 0x5, 0x46, 0x7e, 0xc5, 0x82, 0x99, 0x67, 0x85, 0x68, 0x17, 0xe7, 0xaf, 0x85, 0xdc, 0xa, 0x83, 0xaf, 0x3e, 0x87, 0x9, 0x72, 0x10, 0xe7, 0x1d, 0x73, 0x25, 0x74, 0x80, 0x22, 0xe2, 0x51, 0x94, 0x51, 0x2e, 0x54, 0xb9, 0xb1, 0x86, 0x97, 0xc3, 0xb7, 0xb, 0x96, 0xca, 0x8d, 0x57, 0x28, 0x61, 0xd2, 0x51, 0x78, 0xcb, 0xa9, 0xe, 0x50, 0x3b, 0x84, 0x93, 0xb, 0xf7, 0x14, 0xaa, 0xfc, 0xe9, 0x1c, 0xec, 0xc9, 0x95, 0xb2, 0x62, 0x3c, 0x63, 0xf1, 0x5a, 0x1f, 0xf, 0x50, 0x84, 0x9f, 0x57, 0xf5, 0x3, 0x7b, 0xee, 0xc1, 0x5, 0x6d, 0x41, 0x63, 0xd7, 0x28, 0xc5, 0x9b, 0xde, 0x6f, 0x52, 0x6f, 0x33, 0x1d, 0xf1, 0x7b, 0x5a, 0x34, 0x17, 0x7d, 0x7b, 0x5, 0x10, 0x37, 0x35, 0x46, 0x1c, 0xd3, 0x25, 0xee, 0xc3, 0x32, 0xfe, 0x2, 0xa8, 0x5b, 0x15}, - }, - { - msg: []byte{0x80, 0xbe, 0xeb, 0xcd, 0x2e, 0x3f, 0x8a, 0x94, 0x51, 0xd4, 0x49, 0x99, 0x61, 0xc9, 0x73, 0x1a, 0xe6, 0x67, 0xcd, 0xc2, 0x4e, 0xa0, 0x20, 0xce, 0x3b, 0x9a, 0xa4, 0xbb, 0xc0, 0xa7, 0xf7, 0x9e, 0x30, 0xa9, 0x34, 0x46, 0x7d, 0xa4, 0xb0}, - output128: []byte{0x1, 0x5b, 0xb0, 0xde, 0x6a, 0x28, 0x73, 0x7d, 0x36, 0x53, 0x53, 0xe9, 0xf0, 0x5, 0x2e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x2d, 0x6, 0xf2, 0xb, 0xd0, 0x43, 0x16, 0x18, 0x11, 0x50, 0x97, 0x62, 0x1a, 0x36, 0xc4, 0x1c, 0x97, 0x88, 0xdc, 0x68, 0xb9, 0x59, 0x55, 0xea, 0x5e, 0x9, 0x71, 0x77, 0xd6, 0x6b, 0x8, 0x97, 0xc7, 0xbf, 0xda, 0xed, 0x84, 0x87, 0xa7, 0x9e, 0x14, 0xdc, 0xda}, - }, - { - msg: []byte{0xc8, 0x8d, 0xee, 0x99, 0x27, 0x67, 0x9b, 0x8a, 0xf4, 0x22, 0xab, 0xcb, 0xac, 0xf2, 0x83, 0xb9, 0x4, 0xff, 0x31, 0xe1, 0xca, 0xc5, 0x8c, 0x78, 0x19, 0x80, 0x9f, 0x65, 0xd5, 0x80, 0x7d, 0x46, 0x72, 0x3b, 0x20, 0xf6, 0x7b, 0xa6, 0x10, 0xc2, 0xb7}, - output128: []byte{0x64, 0x81, 0x67, 0x77, 0x4b, 0x9, 0xa9, 0xfb, 0xfb, 0xfd, 0x35, 0x10, 0x51, 0xd1, 0x8f, 0x91, 0x12, 0xd6, 0x3b, 0x6, 0x6b, 0xea, 0xf5, 0x7, 0xd, 0x37, 0x80, 0x18, 0x96, 0x58, 0xfe, 0xbe, 0xa0, 0xa4, 0x58, 0x1d, 0xaf, 0xc6, 0x94, 0x8e, 0xc1, 0xfa, 0x96, 0xf0, 0x36, 0x4e, 0xf3, 0xd1, 0xf2, 0x32, 0x3e, 0xfe, 0x52, 0x94, 0xbd, 0x76, 0xc2, 0x86, 0x32, 0xfd, 0xde, 0xda, 0x51, 0x7, 0x9e, 0x9b, 0xca, 0x5c, 0x1e, 0xfe, 0x95, 0xf7, 0x6b, 0xcd, 0x45, 0x93, 0x83, 0x6b, 0x9c, 0x64, 0xd8, 0x2d, 0xd6, 0xed, 0x2, 0xad, 0x7, 0x62, 0x2b, 0xf2, 0xb1, 0xf7, 0xf0, 0xb0, 0x73, 0x8e, 0xe, 0x39, 0x29, 0x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 0xbe, 0xcc, 0x51}, - output256: []byte{0x83, 0x2b, 0xef, 0xae, 0xca, 0x90, 0xfe, 0xf4, 0x15, 0x77, 0x64, 0x9b, 0x63, 0x48, 0x18, 0x27, 0x53, 0xeb, 0xee, 0x32, 0xea, 0x68, 0x83, 0x6, 0xdb, 0xee, 0xf8, 0x66, 0x5d, 0x6f, 0xfc, 0x6c, 0x5a, 0x26, 0xec, 0x69, 0xec, 0x8c, 0x90, 0xa0, 0xfe, 0xa8, 0x54, 0x89, 0x3c, 0xc, 0x48, 0x85, 0xa2, 0xdc, 0xa4, 0xae, 0x77, 0x24, 0x3f, 0x73, 0x50, 0x48, 0xff, 0x31, 0xb8, 0xd, 0x1a, 0x4c, 0x84, 0xf0, 0x55, 0xde, 0xb1, 0xc1, 0x1f, 0x76, 0xbf, 0x45, 0xda, 0xd9, 0x51, 0x68, 0x99, 0x55, 0x5a, 0xaf, 0xea, 0x86, 0xa1, 0x29, 0xc4, 0xee, 0xd1, 0xd4, 0xcf, 0xc7, 0x60, 0x40, 0x45, 0xd2, 0x21, 0x20, 0xc8, 0xe0, 0x6f, 0x67, 0x79, 0x36, 0x44, 0x53, 0x32, 0x2, 0xa6, 0x9b, 0x68, 0x3b, 0x2e, 0xcb, 0x19, 0xae, 0xd3, 0xdb, 0x15, 0x83, 0x97, 0xc9, 0x22, 0xdc, 0x3a, 0x90, 0xb6, 0x4a, 0x88, 0x25, 0x54, 0x1b, 0xa5, 0xdd, 0x9a, 0xfd, 0x7f, 0x82, 0xdb, 0xc6, 0x3, 0xf1, 0x56, 0xb9, 0xf6, 0x19, 0xa8, 0x3c, 0x71, 0x32, 0xa0, 0xd8, 0xad, 0x71, 0x20, 0x5c, 0x83, 0xaa, 0x4a, 0x52, 0xb6, 0x22, 0x35, 0x7, 0x49, 0x3e, 0xf, 0x9f, 0xab, 0x95, 0x30, 0x76, 0x2a, 0x19, 0xc, 0x9f, 0xc5, 0x96, 0x80, 0xc9, 0x61, 0xb0, 0x8c, 0x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 0x87, 0x61, 0x3d, 0x11, 0xba, 0xa5, 0x71, 0x60, 0xa5, 0x13, 0xf4, 0xb6, 0x4d, 0x91, 0x73, 0x9e, 0x3, 0x2e, 0xd7, 0x2b, 0xb2, 0xdc, 0xfa, 0xfe, 0x6b, 0xa6, 0x13, 0x6f, 0xb3, 0x81, 0x85, 0x70, 0x71, 0x25, 0xc, 0xf6, 0x30, 0x51, 0x5, 0x9f, 0x9b, 0xa3, 0x71, 0x93, 0x5, 0xd3, 0x3e, 0xf9, 0xdc, 0x8d, 0x33, 0xfd, 0x6d, 0x42, 0x74, 0x2, 0xee, 0x34, 0x83, 0x24, 0xc7, 0x89, 0x20, 0x27, 0x8d, 0x6e, 0x5b, 0x26, 0x78, 0xc1, 0xc4, 0xfd, 0x40, 0x87, 0x60}, - }, - { - msg: []byte{0xf5, 0x96, 0x1d, 0xfd, 0x2b, 0x1f, 0xff, 0xfd, 0xa4, 0xff, 0xbf, 0x30, 0x56, 0xc, 0x16, 0x5b, 0xfe, 0xda, 0xb8, 0xce, 0xb, 0xe5, 0x25, 0x84, 0x5d, 0xeb, 0x8d, 0xc6, 0x10, 0x4, 0xb7, 0xdb, 0x38, 0x46, 0x72, 0x5, 0xf5, 0xdc, 0xfb, 0x34, 0xa2, 0xac, 0xfe, 0x96, 0xc0}, - output128: []byte{0x1, 0x28, 0xb0, 0x9a, 0x1, 0x81, 0x53, 0x73, 0x84, 0x6e, 0xb6, 0x20, 0x37, 0x24, 0x5b, 0x4b, 0xf5, 0x22, 0x30, 0x3f, 0xff, 0x74, 0xa7, 0x6b, 0xa, 0xc1, 0x74, 0x82, 0xad, 0x79, 0xe0, 0xbb, 0x26, 0x86, 0x87, 0x1b, 0x19, 0x16, 0xdf, 0x15, 0x4a, 0x75, 0x6, 0x98, 0x5f, 0x2a, 0x3a, 0x6d, 0x86, 0x7, 0x4c, 0x98, 0x8c, 0x2f, 0xa2, 0x55, 0xdd, 0xc2, 0x66, 0xcb, 0x8e, 0xff, 0xde,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x3f, 0x4e, 0x7c, 0x26, 0xcb, 0x16, 0x4, 0xd4, 0x7, 0xae, 0x95, 0xce, 0x96, 0x74, 0x6, 0xe7, 0x3, 0x96, 0x55, 0x8c, 0xa2, 0x7a, 0xbd, 0x91, 0xfa, 0x71, 0x90, 0xa5, 0xd0, 0xf4, 0xac, 0x89, 0xa0, 0x70, 0xf4, 0x5b, 0x85, 0x8b, 0x86}, - }, - { - msg: []byte{0xca, 0x6, 0x1a, 0x2e, 0xb6, 0xce, 0xed, 0x88, 0x81, 0xce, 0x20, 0x57, 0x17, 0x2d, 0x86, 0x9d, 0x73, 0xa1, 0x95, 0x1e, 0x63, 0xd5, 0x72, 0x61, 0x38, 0x4b, 0x80, 0xce, 0xb5, 0x45, 0x1e, 0x77, 0xb0, 0x6c, 0xf0, 0xf5, 0xa0, 0xea, 0x15, 0xca, 0x90, 0x7e, 0xe1, 0xc2, 0x7e, 0xba}, - output128: []byte{0xfb, 0x20, 0x6d, 0x80, 0xaa, 0x1d, 0x2a, 0xf8, 0xce, 0x64, 0x89, 0xd, 0x3f, 0xa8, 0x46, 0x0, 0xf8, 0x4, 0x23, 0xaa, 0x98, 0x44, 0x77, 0x92, 0xf7, 0x32, 0xfc, 0xe4, 0x71, 0x6e, 0x55, 0x9f, 0x7f, 0xd4, 0x33, 0x8b, 0xaf, 0xa6, 0x9, 0x37, 0x78, 0x1b, 0x68, 0x73, 0x66, 0x3, 0xb7, 0xa8, 0x6f, 0x16, 0x88, 0xa2, 0xec, 0x60, 0x88, 0xf, 0x6a, 0x90, 0x78, 0x1d, 0xc8, 0xba, 0x3d, 0x9b, 0x32, 0x9d, 0x66, 0x2d, 0xe8, 0x42, 0x96, 0x1a, 0xc8, 0x4d, 0x8f, 0xc8, 0x76, 0x44, 0x9d, 0xd8, 0xc3, 0x93, 0x44, 0x17, 0x67, 0x20, 0x61, 0x88, 0xd5, 0x61, 0xaf, 0x59, 0xbe, 0xfe, 0x6b, 0x91, 0xe3, 0x65, 0x41,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4f}, - }, - { - msg: []byte{0x17, 0x43, 0xa7, 0x72, 0x51, 0xd6, 0x92, 0x42, 0x75, 0xc, 0x4f, 0x11, 0x40, 0x53, 0x2c, 0xd3, 0xc3, 0x3f, 0x9b, 0x5c, 0xcd, 0xf7, 0x51, 0x4e, 0x85, 0x84, 0xd4, 0xa5, 0xf9, 0xfb, 0xd7, 0x30, 0xbc, 0xf8, 0x4d, 0xd, 0x47, 0x26, 0x36, 0x4b, 0x9b, 0xf9, 0x5a, 0xb2, 0x51, 0xd9, 0xbb}, - output128: []byte{0xeb, 0x74, 0x35, 0x9a, 0xe3, 0x44, 0xb2, 0x6e, 0x35, 0x33, 0x94, 0x7e, 0x26, 0xce, 0xfb, 0xe8, 0x9, 0x93, 0x5c, 0xe7, 0xce, 0xd, 0x59, 0x7d, 0x1c, 0x41, 0x25, 0x54, 0x2f, 0xfb, 0xf1, 0x78, 0x30, 0x52, 0xe0, 0xf9, 0xa, 0x40, 0x2d, 0x78, 0x88, 0xcc, 0xa5, 0xf9, 0x6c, 0xe9, 0xd8, 0x74, 0xc6, 0x0, 0xb2, 0xe0, 0x26, 0xba, 0x4e, 0x79, 0xed, 0x42, 0x7f, 0x3d, 0xa9, 0x64, 0x48, 0xbe, 0xef, 0x47, 0x1, 0xc2, 0x7c, 0xa3, 0x18, 0x60, 0x79, 0x1, 0x56, 0xe9, 0x3b, 0x12, 0xa9, 0xf4, 0x29, 0x29, 0xa8, 0xf8, 0xd9, 0x77, 0x1c, 0xa3, 0xbb, 0x59, 0xac, 0xe0, 0xc, 0x47, 0x32, 0x98, 0x39, 0x97, 0xdc, 0xac, 0x10, 0x46, 0xe5, 0x74, 0xeb, 0x9e, 0x5c, 0x91, 0x2a, 0xd4, 0xe3, 0x81, 0x30, 0x1, 0xc8, 0x6c, 0x91, 0xb6, 0x38, 0x5e, 0x92, 0xdf, 0xe9, 0x2f, 0xf5, 0xcf, 0x90, 0x65, 0x26, 0x80, 0x39, 0x2a, 0x33, 0xf6, 0x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, 0xca, 0x67, 0x32, 0x83, 0x7d, 0x23, 0xf9, 0x85, 0xe1, 0xcc, 0x94, 0x44, 0xac, 0x4, 0xdf, 0xb, 0x2b, 0xbd, 0xbb, 0x44, 0xe2, 0x4d, 0x39, 0xdf, 0x2f, 0x44, 0x7d, 0x72, 0xff, 0xb9, 0xb, 0x7e, 0x9c, 0x68, 0xa4, 0x63, 0x29, 0xed, 0x63, 0xc, 0xda, 0xe9, 0x47, 0x7, 0x70, 0x44, 0x28}, - }, - { - msg: []byte{0x9a, 0x21, 0x9b, 0xe4, 0x37, 0x13, 0xbd, 0x57, 0x80, 0x15, 0xe9, 0xfd, 0xa6, 0x6c, 0xf, 0x2d, 0x83, 0xca, 0xc5, 0x63, 0xb7, 0x76, 0xab, 0x9f, 0x38, 0xf3, 0xe4, 0xf7, 0xef, 0x22, 0x9c, 0xb4, 0x43, 0x30, 0x4f, 0xba, 0x40, 0x1e, 0xfb, 0x2b, 0xdb, 0xd7, 0xec, 0xe9, 0x39, 0x10, 0x22, 0x98, 0x65, 0x1c, 0x86}, - output128: []byte{0x58, 0xb0, 0x40, 0xb4, 0x60, 0x2, 0xbc, 0x13, 0xd0, 0x5c, 0x76, 0xe8, 0x40, 0x3, 0x7b, 0x3e, 0xb0, 0x8d, 0xd5, 0x18, 0x81, 0xca, 0x62, 0x81, 0x59, 0x5d, 0x39, 0xb8, 0xb1, 0x2d, 0x1c, 0x15, 0xf9, 0xcd, 0x40, 0xd9, 0x4d, 0xad, 0x0, 0x46, 0x9b, 0xf5, 0xeb, 0x73, 0x20, 0x5f, 0xc6, 0x49, 0xc5, 0x1, 0xb5, 0x7a, 0x33, 0xf4, 0xeb, 0x39, 0xa7, 0xfd, 0x76, 0x76, 0x9a, 0x6e, 0xb0, 0xf8, 0x4b, 0xcf, 0x98, 0x5c, 0x6a, 0xcb, 0x28, 0x1e, 0x49, 0x89, 0xf5, 0xed, 0xa5, 0xe8, 0x23, 0xc3, 0x1e, 0x94, 0xf4, 0x1e,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xce, 0x6f, 0x44, 0x10, 0x59, 0xfd, 0x26, 0x94, 0x42, 0xba, 0xaa, 0x28, 0xc6, 0xca, 0x3, 0x7b, 0x22, 0xee, 0xac, 0x49, 0xd5, 0xd8, 0x94, 0xc0, 0xbf, 0x66, 0x21, 0x9f, 0x2c, 0x8, 0xe9, 0xd0, 0xe8, 0xab, 0x21, 0xde, 0x52}, - output128: []byte{0x1e, 0xae, 0x5d, 0xf5, 0x44, 0x90, 0x64, 0x7f, 0xf0, 0x39, 0x85, 0x65, 0x87, 0x85, 0xb5, 0xbc, 0x14, 0x80, 0xd5, 0xdd, 0xf3, 0xeb, 0x3a, 0x1f, 0xe6, 0x49, 0x52, 0xe, 0x7, 0xc0, 0x17, 0x4f, 0xdf, 0x1d, 0xde, 0x9a, 0x85, 0x18, 0x87, 0x98, 0x33, 0xd6, 0x4a, 0x99, 0xf3, 0x25, 0x55, 0x68, 0x22, 0x3e, 0x2d, 0xd0, 0xc9, 0xa6, 0x7b, 0xaa, 0xbd, 0xf2, 0x22, 0xc2, 0xa3, 0x14, 0x93, 0x6c, 0xd5, 0x75, 0x78, 0x39, 0x52, 0x88, 0xd4, 0xd, 0xd0, 0x47, 0xd6, 0x7a, 0xdf, 0x82, 0x89, 0x20, 0x7c, 0x6c, 0x67, 0x20, 0x23, 0xe2, 0x5a, 0x5f, 0x66, 0xd2, 0xba, 0xad, 0xbe, 0x29, 0x72, 0xea, 0x32, 0x51, 0x6a, 0xb7, 0x53, 0xca, 0x37, 0xad, 0x5f, 0x43, 0x6a, 0x94, 0xcf, 0xd6, 0x21, 0x82, 0xb7, 0xd6, 0x8e, 0xe0, 0xe7, 0xa0, 0x16, 0xc8, 0x54, 0x8, 0x40, 0xd1, 0xea, 0xdb, 0x3a, 0x15, 0x8d, 0x88, 0xa9, 0xe7, 0xc9, 0xf, 0x55, 0x1f, 0xe8, 0x57, 0xc1, 0x72, 0x65, 0xac, 0x59, 0xbb, 0xa6, 0x94, 0x7f, 0x24, 0x58, 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xdc, 0x20, 0xa3, 0x8d, 0x62, 0xc5, 0x97, 0x1d, 0x9, 0xd0, 0x6f, 0xfd, 0xc3, 0xf8, 0x93, 0x79, 0xa9, 0x99, 0x23, 0xf2, 0xbe, 0x2f, 0xb6, 0x65, 0x14, 0x7, 0xee, 0x37, 0xf4, 0xbc, 0x80, 0x73, 0xe3, 0x96, 0x88, 0x71, 0x66, 0xad, 0x4f, 0xa, 0x4e, 0x15, 0x6c, 0x72, 0x46, 0x3a, 0x52, 0x4e, 0xdb, 0xf4, 0x62, 0xf6, 0x2a, 0xab, 0x25, 0x1e, 0x32, 0x15, 0x9c, 0xb3, 0xd7, 0x9a, 0x2c, 0xb3, 0xa8, 0xfc, 0xbc, 0x19, 0x67, 0x21, 0x64, 0x26, 0x82, 0x64, 0x6a, 0x83, 0xee, 0x60, 0x42, 0x5d, 0xd7, 0x20, 0x7f, 0x73, 0x60}, - }, - { - msg: []byte{0xee, 0xbc, 0xc1, 0x80, 0x57, 0x25, 0x2c, 0xbf, 0x3f, 0x9c, 0x7, 0xf, 0x1a, 0x73, 0x21, 0x33, 0x56, 0xd5, 0xd4, 0xbc, 0x19, 0xac, 0x2a, 0x41, 0x1e, 0xc8, 0xcd, 0xee, 0xe7, 0xa5, 0x71, 0xe2, 0xe2, 0xe, 0xaf, 0x61, 0xfd, 0xc, 0x33, 0xa0, 0xff, 0xeb, 0x29, 0x7d, 0xdb, 0x77, 0xa9, 0x7f, 0xa, 0x41, 0x53, 0x47, 0xdb, 0x66, 0xbc, 0xaf}, - output128: []byte{0xf0, 0xfc, 0x56, 0x62, 0xd4, 0xd2, 0x8b, 0x32, 0x35, 0xe4, 0x9c, 0xff, 0x70, 0x8d, 0x90, 0xbc, 0xab, 0x50, 0x76, 0x4c, 0x40, 0x81, 0xe2, 0xf3, 0xf, 0x4, 0x79, 0x57, 0x3e, 0xd4, 0xfc, 0xad, 0xa1, 0xa8, 0x54, 0x43, 0xd1, 0x36, 0x9e, 0x9, 0xca, 0xad, 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0xcb, 0xd4, 0xda, 0xc4, 0xac, 0x9d, 0x66, 0x62, 0xd3, 0x69, 0x4b, 0x38, 0xbf, 0x12, 0x16, 0x93, 0x20, 0xb5, 0x24, 0x90, 0x21, 0xc8, 0x5a, 0x74, 0x77, 0xe2, 0x58, 0x7d, 0xf9, 0x61, 0x7d, 0x7d, 0x44, 0xe0, 0x9b, 0xf7, 0xfd, 0xae, 0xd7, 0x1e, 0x3d, 0x58, 0x18, 0xda, 0x9, 0x3e, 0x6d, 0x1, 0x92, 0x43, 0xa1, 0x7d, 0x9f, 0x32, 0xa5, 0x4, 0x6f, 0xc6, 0xba, 0x19, 0xed, 0xb0, 0xae, 0x63, 0x49}, - output256: []byte{0xef, 0xae, 0xe0, 0x39, 0xc0, 0x41, 0x2f, 0xce, 0x8f, 0x55, 0xf6, 0xe7, 0x77, 0x28, 0x89, 0xec, 0x18, 0xd0, 0x60, 0x4f, 0xb1, 0x80, 0x40, 0xdc, 0x1e, 0x57, 0x83, 0x59, 0x6c, 0xd8, 0x20, 0xb4, 0x21, 0xa0, 0xdc, 0xaa, 0x52, 0x8c, 0x8a, 0x62, 0xb1, 0x7a, 0x22, 0x16, 0x44, 0x30, 0x67, 0x2d, 0xa6, 0xd8, 0x18, 0xe2, 0xe5, 0x55, 0xaa, 0x8e, 0x79, 0x66, 0x5a, 0x6f, 0x8f, 0x57, 0x21, 0xa4, 0xe1, 0x7f, 0xe8, 0xfe, 0xda, 0x55, 0x1a, 0xcc, 0x91, 0x16, 0xf1, 0xf5, 0xe, 0x95, 0x83, 0x9f, 0xff, 0x24, 0x27, 0xdc, 0x1d, 0x98, 0x8b, 0x2, 0x69, 0x83, 0x81, 0x2, 0x54, 0x7d, 0x4d, 0x46, 0xc1, 0x1d, 0x25, 0x48, 0xbe, 0x3f, 0x88, 0x51, 0x11, 0xd5, 0x3f, 0x30, 0x61, 0xa7, 0x49, 0x72, 0xc5, 0x65, 0x79, 0xc6, 0x81, 0xc2, 0xb, 0xd5, 0xd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 0xc9, 0xbe, 0x1f, 0x50, 0xda, 0x36}, - }, - { - msg: []byte{0xab, 0xc8, 0x77, 0x63, 0xca, 0xe1, 0xca, 0x98, 0xbd, 0x8c, 0x5b, 0x82, 0xca, 0xba, 0x54, 0xac, 0x83, 0x28, 0x6f, 0x87, 0xe9, 0x61, 0x1, 0x28, 0xae, 0x4d, 0xe6, 0x8a, 0xc9, 0x5d, 0xf5, 0xe3, 0x29, 0xc3, 0x60, 0x71, 0x7b, 0xd3, 0x49, 0xf2, 0x6b, 0x87, 0x25, 0x28, 0x49, 0x2c, 0xa7, 0xc9, 0x4c, 0x2c, 0x1e, 0x1e, 0xf5, 0x6b, 0x74, 0xdb, 0xb6, 0x5c, 0x2a, 0xc3, 0x51, 0x98, 0x1f, 0xdb, 0x31, 0xd0, 0x6c, 0x77, 0xa4}, - output128: []byte{0xff, 0xd, 0xb4, 0x5e, 0x2e, 0x89, 0x59, 0x37, 0x5d, 0x39, 0x15, 0xdb, 0xb4, 0x5f, 0xc3, 0x2d, 0xc6, 0xcf, 0xe7, 0xd2, 0xbb, 0x22, 0x76, 0x47, 0xf6, 0x87, 0x76, 0x19, 0xbb, 0x68, 0x84, 0xd8, 0xbb, 0xf9, 0x66, 0x8f, 0x40, 0x77, 0x84, 0x73, 0x9d, 0x34, 0x97, 0x55, 0x76, 0xb9, 0x9a, 0xb1, 0x32, 0x57, 0x16, 0xc2, 0xb8, 0x32, 0x12, 0xdb, 0xe9, 0xe5, 0xe3, 0x3b, 0x5a, 0x6e, 0xc6, 0x8f, 0xd7, 0x50, 0x15, 0x12, 0x4f, 0x1d, 0xa7, 0x31, 0xf5, 0x19, 0xf9, 0x83, 0xcc, 0x78, 0x3f, 0x17, 0x62, 0x86, 0x22, 0x8e, 0x59, 0x6, 0x8a, 0xec, 0x62, 0x41, 0xb2, 0x48, 0x8, 0x40, 0x6c, 0xd6, 0xf, 0x67, 0xd5, 0xa1, 0xab, 0x70, 0x83, 0xd7, 0x85, 0x49, 0x84, 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x92, 0x8a, 0xde, 0x31, 0x2, 0xb6, 0x12, 0x84, 0xc6, 0x76, 0xc1, 0x40, 0xf3, 0x3a, 0x17, 0xfa, 0xb4, 0x80, 0x2, 0x39, 0x4e, 0xb3, 0x62, 0x65, 0xd1}, - output256: []byte{0xa9, 0x0, 0x53, 0xa8, 0xf7, 0x38, 0xa6, 0x8c, 0x18, 0xcb, 0x87, 0xfb, 0xaa, 0x83, 0x70, 0xbd, 0x14, 0x27, 0x4, 0x12, 0xd0, 0x1, 0x4c, 0x5d, 0xe8, 0x0, 0x8f, 0xbb, 0x74, 0xe6, 0x19, 0x18, 0x2a, 0x4, 0x42, 0xc1, 0x21, 0xf7, 0xe2, 0x44, 0x9a, 0x5b, 0x1, 0x9d, 0xc0, 0xce, 0x59, 0x7b, 0xf1, 0xd7, 0xd3, 0xe6, 0x4d, 0x11, 0x84, 0x94, 0x6d, 0x45, 0x20, 0x8a, 0x86, 0x47, 0x23, 0xa7, 0x3c, 0xc1, 0xe2, 0x42, 0xf7, 0x18, 0x78, 0x11, 0xc5, 0x22, 0xf8, 0x80, 0xac, 0xf5, 0x30, 0x56, 0xd8, 0x35, 0xbd, 0x15, 0xf, 0xcb, 0x7d, 0xb6, 0x13, 0x63, 0xd2, 0x20, 0x74, 0x34, 0x9f, 0xf5, 0x4a, 0x3e, 0x5f, 0xf2, 0x57, 0x12, 0x72, 0x91, 0xa, 0x73, 0x33, 0x95, 0x9d, 0x8c, 0xc2, 0x9f, 0x69, 0xb5, 0x40, 0xe5, 0xec, 0xca, 0x50, 0xdf, 0x77, 0x99, 0x23, 0x63, 0x38, 0xe2, 0x92, 0x55, 0x65, 0x69, 0x30, 0xe2, 0x26, 0x79, 0xa3, 0xa5, 0x85, 0xe3, 0x2b, 0x88, 0xc2, 0x74, 0x52, 0xbe, 0x75, 0xbd, 0xe7, 0x37, 0x89, 0xb4, 0x56, 0x23, 0xe6, 0x95, 0xfb, 0x74, 0x8, 0xdc, 0x51, 0x89, 0x1d, 0x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te{0x6b, 0xb1, 0x8c, 0x45, 0xbe, 0x71, 0x50, 0x84, 0x41, 0xee, 0x81, 0x50, 0x61, 0xed, 0x78, 0x2f, 0x4b, 0xb5, 0xac, 0xf5, 0x39, 0x3b, 0xc9, 0xbb, 0x82, 0x5f, 0xc7, 0x9c, 0xad, 0x2, 0x5c, 0x6d, 0x97, 0xd, 0x61, 0x5f, 0x42, 0x85, 0x18, 0x56, 0x96, 0xce, 0x22, 0x69, 0x69, 0xd5, 0xe0, 0x6e, 0x16, 0x43, 0xf8, 0xba, 0x93, 0xf5, 0x61, 0x7a, 0xfb, 0x9, 0x6a, 0xbf, 0x46, 0xde, 0x2e, 0xe7, 0xd3, 0x2b, 0xba, 0xa3, 0x35, 0x62, 0x8c, 0x41, 0xf1, 0xff, 0x30, 0x84, 0x18, 0x55, 0x6c, 0x51, 0xe6, 0xda, 0x30, 0x63, 0x9b, 0xa5, 0xda, 0x36, 0xa1, 0x49, 0x76, 0xdf, 0xdc, 0x1, 0x35, 0x51, 0xf6, 0x32, 0x13, 0x37, 0x23, 0xaa, 0x95, 0x55, 0xb8, 0xb1, 0x1b, 0xf0, 0x59, 0x44, 0x57, 0xa6, 0xb2, 0x88, 0xb0, 0x11, 0x85, 0x92, 0x7a, 0x48, 0x41, 0x20, 0x19, 0xe5, 0x86, 0x21, 0x80, 0x6f, 0xaa, 0x96, 0x8c, 0xa2, 0x63, 0x66, 0xb8, 0x84, 0xc4, 0x28, 0x60, 0x7d, 0x2d, 0x6f, 0xe9, 0xe8, 0x92, 0x4e, 0x6d, 0x8d, 0x76, 0x9a, 0x7d, 0x2d, 0xe9, 0x1, 0x95, 0xab, 0x6d, 0xee, 0x48, 0x96, 0xab, 0xac, 0x31, 0x19, 0xfd, 0x15, 0xee, 0x61, 0x25, 0x1f, 0xca, 0xb1, 0xd3, 0x85, 0x85, 0x27, 0xe2, 0xe6, 0xe1, 0xb8, 0xec, 0x5, 0xbf, 0x86, 0x59, 0xea, 0x34, 0x5e, 0x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14, 0x53, 0x49, 0xf5}, - output256: []byte{0x51, 0xf3, 0xde, 0x30, 0x53, 0x13, 0x35, 0xb0, 0x2c, 0xa, 0x8c, 0xda, 0x52, 0x85, 0xfb, 0xef, 0x9a, 0xf6, 0x18, 0xe4, 0x33, 0x14, 0x2e, 0x9e, 0x97, 0x13, 0x38, 0x86, 0x2, 0xb0, 0x48, 0x6a, 0x99, 0x70, 0x7b, 0xe4, 0x20, 0xae, 0xab, 0x53, 0xdc, 0xfa, 0xca, 0x68, 0xcc, 0x6c, 0xc6, 0xa3, 0x13, 0x30, 0x75, 0xa5, 0x18, 0xd2, 0xeb, 0x1c, 0x50, 0xf, 0xa, 0xc2, 0xe0, 0xb8, 0xa9, 0x1d, 0x33, 0x3, 0x59, 0x4b, 0xb3, 0x8f, 0xfc, 0x45, 0xb8, 0xa, 0xfb, 0x8e, 0x25, 0xc4, 0x30, 0x4a, 0x85, 0x28, 0xe, 0x61, 0x24, 0x89, 0x1e, 0x73, 0x9f, 0xc9, 0xdf, 0x8e, 0x34, 0xab, 0xd9, 0x26, 0x2d, 0xcb, 0x43, 0x30, 0xc2, 0xc0, 0xf2, 0x2e, 0x78, 0x44, 0x7b, 0x3f, 0xa6, 0x76, 0x77, 0xac, 0xc1, 0xf3, 0xd8, 0xe8, 0x36, 0xee, 0xa9, 0x4a, 0xea, 0x4d, 0x61, 0x61, 0x32, 0x65, 0xc, 0x92, 0x88, 0x80, 0x4c, 0x3c, 0xca, 0x5f, 0x1c, 0x1, 0x39, 0x62, 0x4e, 0x19, 0x86, 0x43, 0xd5, 0x2c, 0x42, 0x96, 0x0, 0x52, 0xfb, 0xbc, 0xf8, 0x9a, 0xf0, 0xd, 0x58, 0x60, 0xa, 0x95, 0x97, 0xbd, 0x12, 0xa3, 0x9a, 0x33, 0xae, 0xce, 0xeb, 0x16, 0x1e, 0xe5, 0x27, 0x39, 0x8b, 0xd9, 0x15, 0xab, 0xf6, 0x42, 0x74, 0x6e, 0x4c, 0x96, 0x5a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x7a, 0xa, 0x9a, 0xa0, 0x26, 0x43, 0x3f, 0x32, 0x5, 0x30, 0x63, 0x2e, 0x5f, 0x72, 0x12, 0x2b, 0x63, 0xac, 0xf0, 0x1f, 0x2b, 0xcc, 0xda, 0x9b, 0xd4, 0xfc, 0x57, 0x9e, 0x6d, 0xdc, 0x13, 0x71, 0xdf, 0xcb, 0xf7, 0x34, 0x7b}, - }, - { - msg: []byte{0x6d, 0x8c, 0x6e, 0x44, 0x9b, 0xc1, 0x36, 0x34, 0xf1, 0x15, 0x74, 0x9c, 0x24, 0x8c, 0x17, 0xcd, 0x14, 0x8b, 0x72, 0x15, 0x7a, 0x2c, 0x37, 0xbf, 0x89, 0x69, 0xea, 0x83, 0xb4, 0xd6, 0xba, 0x8c, 0xe, 0xe2, 0x71, 0x1c, 0x28, 0xee, 0x11, 0x49, 0x5f, 0x43, 0x4, 0x95, 0x96, 0x52, 0xc, 0xe4, 0x36, 0x0, 0x4b, 0x2, 0x6b, 0x6c, 0x1f, 0x72, 0x92, 0xb9, 0xc4, 0x36, 0xb0, 0x55, 0xcb, 0xb7, 0x2d, 0x53, 0xd, 0x86, 0xd, 0x12, 0x76, 0xa1, 0x50, 0x2a, 0x51, 0x40, 0xe3, 0xc3, 0xf5, 0x4a, 0x93, 0x66, 0x3e, 0x4d, 0x20, 0xed, 0xec, 0x32, 0xd2, 0x84, 0xe2, 0x55, 0x64, 0xf6, 0x24, 0x95, 0x5b, 0x52}, - output128: []byte{0xe4, 0x10, 0x27, 0xe7, 0x6a, 0x5, 0x5f, 0xa, 0x82, 0x64, 0x81, 0xc6, 0x50, 0xfc, 0x24, 0xf7, 0x81, 0x64, 0x60, 0xed, 0x51, 0x9a, 0xf8, 0x80, 0x2a, 0xb1, 0x91, 0xe4, 0x11, 0xec, 0xa7, 0x19, 0xca, 0x16, 0x96, 0xea, 0x14, 0xcd, 0x62, 0x30, 0x60, 0x71, 0xd4, 0xe1, 0xdd, 0x65, 0x33, 0x36, 0x19, 0xd0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 0x6e, 0xaa, 0xb, 0x6e, 0x1e, 0x93}, - }, - { - msg: []byte{0x59, 0x54, 0xba, 0xb5, 0x12, 0xcf, 0x32, 0x7d, 0x66, 0xb5, 0xd9, 0xf2, 0x96, 0x18, 0x0, 0x80, 0x40, 0x26, 0x24, 0xad, 0x76, 0x28, 0x50, 0x6b, 0x55, 0x5e, 0xea, 0x83, 0x82, 0x56, 0x23, 0x24, 0xcf, 0x45, 0x2f, 0xba, 0x4a, 0x21, 0x30, 0xde, 0x3e, 0x16, 0x5d, 0x11, 0x83, 0x1a, 0x27, 0xd, 0x9c, 0xb9, 0x7c, 0xe8, 0xc2, 0xd3, 0x2a, 0x96, 0xf5, 0xd, 0x71, 0x60, 0xb, 0xb4, 0xca, 0x26, 0x8c, 0xf9, 0x8e, 0x90, 0xd6, 0x49, 0x6b, 0xa, 0x66, 0x19, 0xa5, 0xa8, 0xc6, 0x3d, 0xb6, 0xd8, 0xa0, 0x63, 0x4d, 0xfc, 0x6c, 0x7e, 0xc8, 0xea, 0x9c, 0x0, 0x6b, 0x6c, 0x45, 0x6f, 0x1b, 0x20, 0xcd, 0x19, 0xe7, 0x81, 0xaf, 0x20, 0x45, 0x4a, 0xc8, 0x80}, - output128: []byte{0x93, 0xbf, 0x13, 0xdc, 0xdd, 0xef, 0x17, 0x7e, 0xec, 0xfa, 0xc1, 0xd8, 0x73, 0x12, 0x37, 0xcb, 0xf8, 0xce, 0x44, 0x59, 0xad, 0xff, 0xc3, 0x42, 0x89, 0x1, 0x6a, 0x68, 0x9e, 0x88, 0xe5, 0xb0, 0x0, 0x55, 0x3f, 0x8, 0x98, 0x9e, 0xf2, 0xb0, 0x7, 0xac, 0xb4, 0xac, 0x69, 0xed, 0xeb, 0x6c, 0xe2, 0xe5, 0xa7, 0xf8, 0x5c, 0x9d, 0x75, 0xf7, 0x65, 0x68, 0x58, 0xa7, 0xb8, 0x24, 0x47, 0x2b, 0xb8, 0x9c, 0x2d, 0x25, 0x70, 0x1c, 0xce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 0x3a, 0xa8, 0x91, 0xbb, 0xa0, 0xb6, 0xb2, 0xb2, 0xfa, 0x37, 0x8d, 0x26, 0xd6, 0x29, 0xb4, 0xce, 0x42, 0x8f, 0x37, 0x5b, 0xae, 0x3f, 0xea, 0x5e, 0x5c, 0x6b, 0x4, 0x89, 0x28, 0xec, 0x92, 0x9, 0x9f, 0x3c, 0x3e}, - }, - { - msg: []byte{0x8e, 0x58, 0x14, 0x4f, 0xa9, 0x17, 0x9d, 0x68, 0x64, 0x78, 0x62, 0x2c, 0xe4, 0x50, 0xc7, 0x48, 0x26, 0xc, 0x95, 0xd1, 0xba, 0x43, 0xb8, 0xf9, 0xb5, 0x9a, 0xbe, 0xca, 0x8d, 0x93, 0x48, 0x8d, 0xa7, 0x34, 0x63, 0xef, 0x40, 0x19, 0x8b, 0x4d, 0x16, 0xfb, 0xb, 0x7, 0x7, 0x20, 0x13, 0x47, 0xe0, 0x50, 0x6f, 0xf1, 0x9d, 0x1, 0xbe, 0xa0, 0xf4, 0x2b, 0x8a, 0xf9, 0xe7, 0x1a, 0x1f, 0x1b, 0xd1, 0x68, 0x78, 0x10, 0x69, 0xd4, 0xd3, 0x38, 0xfd, 0xef, 0x0, 0xbf, 0x41, 0x9f, 0xbb, 0x0, 0x30, 0x31, 0xdf, 0x67, 0x1f, 0x4a, 0x37, 0x97, 0x95, 0x64, 0xf6, 0x92, 0x82, 0xde, 0x9c, 0x65, 0x40, 0x78, 0x47, 0xdd, 0xd, 0xa5, 0x5, 0xab, 0x16, 0x41, 0xc0, 0x2d, 0xea, 0x4f, 0xd, 0x83, 0x49, 0x86}, - output128: []byte{0x60, 0x56, 0x5a, 0x24, 0xb7, 0xc, 0x76, 0x46, 0x3c, 0xdc, 0x53, 0x97, 0xbd, 0xc, 0x7, 0x7b, 0x77, 0xcc, 0x70, 0xcf, 0x33, 0x12, 0x8a, 0x3, 0x66, 0xa7, 0xc3, 0x1, 0x61, 0xe2, 0x1c, 0x32, 0xf2, 0xf0, 0x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, 0xe3, 0x29, 0x81, 0x3d, 0xe9, 0xd, 0x1e, 0x57, 0x2d, 0xfb, 0x89, 0xa1, 0x81, 0x20, 0xc3, 0xf6, 0x6, 0x35, 0x5d, 0x25}, - output128: []byte{0x76, 0x5a, 0x48, 0xe2, 0x5e, 0xe4, 0x3a, 0xc1, 0x63, 0xc, 0x65, 0xbf, 0x51, 0x38, 0xf5, 0xf7, 0x92, 0x9, 0x5e, 0x18, 0x24, 0x83, 0xde, 0x88, 0x87, 0xf0, 0xf5, 0x6a, 0xbd, 0xfc, 0x5, 0x26, 0xa5, 0xb9, 0xee, 0x79, 0x2a, 0x25, 0x33, 0x40, 0x9f, 0x3f, 0xca, 0xd2, 0xb9, 0xcd, 0x43, 0xd7, 0xcf, 0xb5, 0x45, 0x41, 0x94, 0x34, 0x41, 0x69, 0xde, 0xa3, 0xfc, 0x67, 0xcc, 0xb5, 0xb9, 0x96, 0x94, 0x49, 0x45, 0x4e, 0x18, 0x86, 0x9e, 0x7c, 0xfd, 0x82, 0x1e, 0xd0, 0xf3, 0xd6, 0x55, 0xf5, 0xb3, 0x3c, 0x52, 0x8b, 0xed, 0x17, 0x78, 0xbd, 0x50, 0x4b, 0x2c, 0x84, 0xbd, 0x38, 0xdb, 0xcb, 0xfb, 0xf5, 0xca, 0xd7, 0xe4, 0x6f, 0x37, 0x39, 0x46, 0x22, 0xc4, 0xb0, 0x65, 0x68, 0x67, 0x73, 0xac, 0x1, 0x71, 0xef, 0x70, 0x71, 0x7e, 0x8c, 0x6a, 0x88, 0x7a, 0xd9, 0x52, 0x34, 0x3d, 0x2, 0xee, 0x96, 0xb4, 0x12, 0x9b, 0x3f, 0x18, 0x9c, 0x63, 0x1a, 0x71, 0x99, 0x10, 0xf5, 0x43, 0x54, 0xd, 0xe4, 0xad, 0x65, 0x99, 0x3b, 0x63, 0x4a, 0xfc, 0xf3, 0x13, 0x10, 0x7, 0x71, 0x46, 0x8c, 0x81, 0xb0, 0xe2, 0x70, 0x76, 0x9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, 0xa8, 0x58, 0x3a, 0xcc, 0xd1, 0x95, 0x6a}, - }, - { - msg: []byte{0xfd, 0x19, 0xe0, 0x1a, 0x83, 0xeb, 0x6e, 0xc8, 0x10, 0xb9, 0x45, 0x82, 0xcb, 0x8f, 0xbf, 0xa2, 0xfc, 0xb9, 0x92, 0xb5, 0x36, 0x84, 0xfb, 0x74, 0x8d, 0x22, 0x64, 0xf0, 0x20, 0xd3, 0xb9, 0x60, 0xcb, 0x1d, 0x6b, 0x8c, 0x34, 0x8c, 0x2b, 0x54, 0xa9, 0xfc, 0xea, 0x72, 0x33, 0xc, 0x2a, 0xaa, 0x9a, 0x24, 0xec, 0xdb, 0x0, 0xc4, 0x36, 0xab, 0xc7, 0x2, 0x36, 0x1a, 0x82, 0xbb, 0x88, 0x28, 0xb8, 0x53, 0x69, 0xb8, 0xc7, 0x2e, 0xce, 0x0, 0x82, 0xfe, 0x6, 0x55, 0x71, 0x63, 0x89, 0x9c, 0x2a, 0xe, 0xfa, 0x46, 0x6c, 0x33, 0xc0, 0x43, 0x43, 0xa8, 0x39, 0x41, 0x70, 0x57, 0x39, 0x9a, 0x63, 0xa3, 0x92, 0x9b, 0xe1, 0xee, 0x48, 0x5, 0xd6, 0xce, 0x3e, 0x5d, 0xd, 0x9, 0x67, 0xfe, 0x90, 0x4, 0x69, 0x6a, 0x56, 0x63, 0xf4, 0xca, 0xc9, 0x17, 0x90, 0x6, 0xa2, 0xce, 0xb7, 0x55, 0x42, 0xd7, 0x5d, 0x68}, - output128: []byte{0x31, 0xed, 0xb6, 0x3f, 0xa1, 0x82, 0xa6, 0xda, 0xad, 0xae, 0x56, 0xc0, 0x8b, 0xc7, 0x94, 0xe7, 0x46, 0x77, 0x45, 0x7c, 0x69, 0xcb, 0x23, 0xec, 0x82, 0xd2, 0xb8, 0xf7, 0x4b, 0x86, 0x49, 0xf7, 0x97, 0x54, 0xa8, 0xd9, 0xbd, 0x42, 0xba, 0x3b, 0xda, 0xbe, 0xc, 0x4a,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0x7, 0xe8, 0xcb, 0xbf, 0x34, 0xef, 0x95, 0x17, 0x67, 0x43, 0x50, 0x97, 0x3e, 0x75, 0x79, 0x9a, 0x25, 0x1e, 0x72, 0xa3, 0x52, 0xd2, 0x70, 0x2, 0x91, 0xcc, 0x3f, 0x1a, 0xad, 0x40, 0xad, 0xc9, 0x5, 0xb, 0xef, 0x98, 0x81, 0x17, 0xe, 0xac, 0xd3, 0x20, 0x7a, 0xc0, 0xc5, 0x73, 0xe2, 0x38, 0xb6, 0x55, 0x0, 0xb9, 0x97, 0xdc, 0xeb, 0x34, 0x7b, 0x94, 0xfc, 0xd5, 0x6, 0x9c, 0xf4, 0x3b, 0xf1, 0x5a, 0xee, 0xf1, 0x5e, 0x4c, 0x13, 0x5d, 0xd2, 0x1b, 0x40, 0x46, 0xb2, 0x1, 0xf4, 0x11, 0x51, 0x3a, 0xea, 0x96, 0x29, 0xb9, 0x88, 0x7d, 0x21, 0xcd, 0xc4, 0x37, 0x68, 0xfc, 0x1c, 0x1b, 0x12, 0xea, 0x4c, 0xa4, 0x59, 0x5a, 0xd4, 0x63}, - }, - { - msg: []byte{0x77, 0xee, 0x80, 0x4b, 0x9f, 0x32, 0x95, 0xab, 0x23, 0x62, 0x79, 0x8b, 0x72, 0xb0, 0xa1, 0xb2, 0xd3, 0x29, 0x1d, 0xce, 0xb8, 0x13, 0x98, 0x96, 0x35, 0x58, 0x30, 0xf3, 0x4b, 0x3b, 0x32, 0x85, 0x61, 0x53, 0x1f, 0x80, 0x79, 0xb7, 0x9a, 0x6e, 0x99, 0x80, 0x70, 0x51, 0x50, 0x86, 0x64, 0x2, 0xfd, 0xc1, 0x76, 0xc0, 0x58, 0x97, 0xe3, 0x59, 0xa6, 0xcb, 0x1a, 0x7a, 0xb0, 0x67, 0x38, 0x3e, 0xb4, 0x97, 0x18, 0x2a, 0x7e, 0x5a, 0xef, 0x70, 0x38, 0xe4, 0xc9, 0x6d, 0x13, 0x3b, 0x27, 0x82, 0x91, 0x74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89, 0x3a, 0x68}, - }, - { - msg: []byte{0x51, 0x79, 0x88, 0x87, 0x24, 0x81, 0x9f, 0xba, 0xd3, 0xaf, 0xa9, 0x27, 0xd3, 0x57, 0x77, 0x96, 0x66, 0xe, 0x6a, 0x81, 0xc5, 0x2d, 0x98, 0xe9, 0x30, 0x32, 0x61, 0xd5, 0xa4, 0xa8, 0x32, 0x32, 0xf6, 0xf7, 0x58, 0x93, 0x4d, 0x50, 0xaa, 0x83, 0xff, 0x9e, 0x20, 0xa5, 0x92, 0x6d, 0xfe, 0xba, 0xac, 0x49, 0x52, 0x9d, 0x0, 0x6e, 0xb9, 0x23, 0xc5, 0xae, 0x50, 0x48, 0xed, 0x54, 0x4e, 0xc4, 0x71, 0xed, 0x71, 0x91, 0xed, 0xf4, 0x63, 0x63, 0x38, 0x38, 0x24, 0xf9, 0x15, 0x76, 0x9b, 0x3e, 0x68, 0x80, 0x94, 0xc6, 0x82, 0xb0, 0x21, 0x51, 0xe5, 0xee, 0x1, 0xe5, 0x10, 0xb4, 0x31, 0xc8, 0x86, 0x5a, 0xff, 0x8b, 0x6b, 0x6f, 0x2f, 0x59, 0xcb, 0x6d, 0x12, 0x9d, 0xa7, 0x9e, 0x97, 0xc6, 0xd2, 0xb8, 0xfa, 0x6c, 0x6d, 0xa3, 0xf6, 0x3, 0x19, 0x9d, 0x2d, 0x1b, 0xca, 0xb5, 0x47, 0x68, 0x2a, 0x81, 0xcd, 0x6c, 0xf6, 0x5f, 0x65, 0x51, 0x12, 0x13, 0x91, 0xd7, 0x8b, 0xcc, 0x23, 0xb5, 0xbd, 0xe, 0x92, 0x2e, 0xc6, 0xd8, 0xbf, 0x97, 0xc9, 0x52, 0xe8, 0x4d, 0xd2, 0x8a, 0xef, 0x90, 0x9a, 0xba, 0x31, 0xed, 0xb9, 0x3, 0xb2, 0x8f, 0xbf, 0xc3, 0x3b, 0x77, 0x3, 0xcd, 0x99, 0x62, 0x15, 0xa1, 0x12, 0x38}, - output128: []byte{0x7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c, 0xb9, 0x1, 0x94, 0x95, 0x90, 0x27, 0x9, 0x3a, 0x93, 0xf7, 0x4, 0x8f, 0x35, 0xe3, 0xa5, 0xb0, 0xae, 0xf9, 0xa, 0x79, 0x28, 0x20, 0xb2, 0x42, 0xc3, 0x47, 0x0, 0xfb, 0xe7, 0xf7, 0xe0, 0xc, 0x0, 0xd6, 0xab, 0xdf, 0xae, 0x26, 0xdd, 0xc9, 0x5c, 0xa4, 0x7a, 0x72, 0x13, 0x3f, 0x97, 0x92, 0x4d, 0x67, 0x29, 0x1c, 0x6f}, - output256: []byte{0x97, 0x92, 0x2e, 0x82, 0x71, 0x63, 0xb8, 0x86, 0x9d, 0x9a, 0x76, 0x54, 0xae, 0x45, 0x32, 0xea, 0x26, 0xf9, 0x89, 0x56, 0x25, 0x15, 0x20, 0x12, 0xf1, 0x47, 0xbe, 0x1e, 0x81, 0x8d, 0xf8, 0x2, 0x68, 0x9d, 0x96, 0xb4, 0x69, 0xc8, 0xb0, 0xe9, 0x1, 0xd, 0x4, 0x23, 0xda, 0x90, 0xab, 0x6e, 0xed, 0x2c, 0x83, 0x5a, 0x1, 0xca, 0x4c, 0x38, 0x6c, 0x63, 0xa, 0x22, 0xd8, 0x85, 0xb5, 0x11, 0xf1, 0x27, 0x99, 0xea, 0xce, 0xa9, 0x6d, 0x15, 0x7a, 0x44, 0x32, 0xa3, 0x20, 0xf3, 0xec, 0x1c, 0xbb, 0xb6, 0xb8, 0xef, 0xed, 0xe3, 0xe9, 0x2d, 0x99, 0xb1, 0xe7, 0x93, 0x89, 0xb9, 0x3a, 0xf7, 0xac, 0xb2, 0x7d, 0x7d, 0xc9, 0x7c, 0xf8, 0x84, 0x85, 0xde, 0x6c, 0x85, 0x40, 0xa, 0x2d, 0xd8, 0x8a, 0xca, 0x54, 0xb, 0x3c, 0x92, 0x11, 0x80, 0x0, 0x28, 0x47, 0xb3, 0x4a, 0x45, 0x44, 0x65, 0xd0, 0x14, 0xf4, 0x74, 0x28, 0x15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x8e, 0xb3, 0x25, 0x15}, - output128: []byte{0xee, 0xdf, 0x84, 0x14, 0xac, 0xba, 0x39, 0x31, 0xcc, 0xb5, 0xc4, 0x1b, 0x4, 0x5e, 0x70, 0x89, 0x26, 0xcc, 0x68, 0xc5, 0x13, 0x37, 0x2b, 0x2a, 0x5c, 0x9f, 0x8b, 0xeb, 0x76, 0xc0, 0x60, 0x46, 0x1c, 0xdb, 0xde, 0x48, 0x6f, 0x81, 0x95, 0x21, 0x69, 0xb4, 0x65, 0x6, 0x15, 0x41, 0xe3, 0x97, 0x19, 0x2c, 0xab, 0x92, 0xb6, 0x4c, 0xd5, 0xae, 0x0, 0x72, 0x81, 0x10, 0x17, 0x14, 0xd, 0x53, 0x86, 0x1f, 0x56, 0xa9, 0x6a, 0x66, 0x21, 0x1f, 0xb3, 0xb, 0xd1, 0xe9, 0x11, 0xd3, 0x1f, 0xdd, 0x29, 0xce, 0x66, 0x88, 0x25, 0x29, 0x87, 0x47, 0x24, 0xa6, 0x42, 0x16, 0xc1, 0x3a, 0xee, 0x81, 0x10, 0xb9, 0x63, 0xec, 0xc9, 0x9c, 0xf4, 0x6d, 0x2c, 0x13, 0x84, 0xcb, 0x39, 0xb2, 0x7f, 0x2e, 0xb8, 0x5b, 0x51, 0x78, 0x93, 0xac, 0x45, 0xa1, 0x26, 0xf5, 0x7e, 0x93, 0xde, 0xde, 0xc7, 0x8c, 0xd2, 0x70, 0x8e, 0x2c, 0x71, 0x8d, 0x78, 0x3d, 0x84, 0x7e, 0x2f, 0xbc, 0x8b, 0x3f, 0xdc, 0x67, 0x26, 0xb, 0x33, 0x85, 0x25, 0x76, 0x91, 0xd, 0x2e, 0x43, 0x92, 0x3b, 0xcb, 0x88, 0x82, 0xd3, 0x18, 0xac, 0x54, 0x21, 0xb9, 0x9b, 0xe5, 0xe5, 0x32, 0x10, 0x18, 0x33, 0x58, 0x5e, 0x74, 0x4b, 0x65, 0xee, 0xa3, 0x10, 0x43, 0x37, 0xff, 0xaf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0x7b, 0xad, 0xe2, 0x4e, 0xfb, 0x25, 0x51, 0x8e, 0x59, 0xe2, 0x7f, 0xc9, 0x21, 0xd8, 0xdb, 0x6d, 0x3a, 0xc2, 0x86, 0xbd, 0x1a, 0xba, 0x53, 0xd4, 0x89, 0x83, 0xdf, 0x63, 0xd4, 0x93, 0xf9, 0x5b, 0x88, 0x61, 0xc, 0xbc, 0xf6, 0xde, 0x21, 0x30, 0xad, 0x63, 0xfb, 0x98, 0x60, 0xa8, 0x39, 0xc3, 0xf9, 0x8f, 0x55, 0x32, 0xb9, 0x2, 0x25, 0xd1, 0xad, 0xad, 0x79, 0xb4, 0x78, 0xf5, 0xc9, 0xd8, 0x36, 0x43, 0x5a, 0x9c, 0x9c, 0xe, 0xbe, 0x22, 0x9f, 0xa4, 0x94, 0xb5, 0xf4, 0x25, 0x3d, 0xa9, 0x2c, 0x73, 0x82, 0xab, 0x38, 0x8c, 0x4f, 0x5, 0x29, 0x11, 0xe9, 0xff, 0x28, 0xcc, 0x43, 0x41, 0x5c, 0x8a, 0x82, 0x6, 0x54, 0x33, 0xd8, 0xcd, 0xab, 0x91, 0x52, 0xcc, 0x13, 0x19, 0x1f, 0x17, 0x29, 0xea, 0x95, 0x69, 0x3b, 0x4b, 0xbe, 0xbc, 0x3b, 0x3, 0xf2, 0x98, 0xef, 0x6b, 0x37, 0x39, 0xa0, 0xf3, 0x4a, 0x54, 0x51, 0x98, 0xff, 0x5d, 0x2b, 0x42, 0x92, 0xaa, 0x8d, 0x6a, 0x4, 0x27, 0x14, 0x63, 0xdf, 0x95, 0x14, 0x5c, 0x99, 0xec, 0x76, 0x91, 0x67, 0x76, 0x16, 0x90, 0xc9, 0x73, 0x61, 0x98, 0x4a, 0x66, 0x5b, 0xd, 0x5c, 0x21, 0x69, 0xad, 0xde, 0xd2}, - }, - { - msg: []byte{0xea, 0xcd, 0x7, 0x97, 0x1c, 0xff, 0x9b, 0x99, 0x39, 0x90, 0x3f, 0x8c, 0x1d, 0x8c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x10, 0x60, 0x97, 0xa9, 0x6b, 0x66, 0x8f, 0x97, 0xc3, 0xbd, 0xe8, 0xcf, 0xdc, 0x96, 0x0, 0x41, 0x9b, 0x46, 0xea, 0x24, 0x83, 0x9d, 0x27, 0xa5, 0x74, 0xbf, 0x63, 0x14, 0x7a, 0x97, 0xb2, 0xb4, 0x8c, 0xee, 0x1c, 0x6f, 0xda, 0x32, 0xf3, 0xb9, 0x45, 0xe3, 0x6f, 0xc0, 0x3e, 0xab, 0x48, 0x5b, 0x4b}, - }, - { - msg: []byte{0x38, 0x75, 0xb9, 0x24, 0xc, 0xf3, 0xe0, 0xa8, 0xb5, 0x9c, 0x65, 0x85, 0x40, 0xf2, 0x6a, 0x70, 0x1c, 0xf1, 0x88, 0x49, 0x6e, 0x2c, 0x21, 0x74, 0x78, 0x8b, 0x12, 0x6f, 0xd2, 0x94, 0x2, 0xd6, 0xa7, 0x54, 0x53, 0xba, 0x6, 0x35, 0x28, 0x4d, 0x8, 0x83, 0x5f, 0x40, 0x5, 0x1a, 0x2a, 0x96, 0x83, 0xdc, 0x92, 0xaf, 0xb9, 0x38, 0x37, 0x19, 0x19, 0x12, 0x31, 0x17, 0x3, 0x79, 0xba, 0x6f, 0x4a, 0xdc, 0x81, 0x6f, 0xec, 0xbb, 0xf, 0x9c, 0x44, 0x6b, 0x78, 0x5b, 0xf5, 0x20, 0x79, 0x68, 0x41, 0xe5, 0x88, 0x78, 0xb7, 0x3c, 0x58, 0xd3, 0xeb, 0xb0, 0x97, 0xce, 0x47, 0x61, 0xfd, 0xea, 0xbe, 0x15, 0xde, 0x2f, 0x31, 0x9d, 0xfb, 0xaf, 0x17, 0x42, 0xcd, 0xeb, 0x38, 0x95, 0x59, 0xc7, 0x88, 0x13, 0x1a, 0x67, 0x93, 0xe1, 0x93, 0x85, 0x66, 0x61, 0x37, 0x6c, 0x81, 0xce, 0x95, 0x68, 0xda, 0x19, 0xaa, 0x69, 0x25, 0xb4, 0x7f, 0xfd, 0x77, 0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a, 0xbc, 0xec, 0x34, 0x50, 0xf4, 0xe2, 0xee, 0xc9, 0x83, 0x8f, 0x89, 0x54, 0x23, 0xef, 0x63, 0xd2, 0x61, 0x13, 0x8b, 0xaa, 0xf5, 0xd9, 0xf1, 0x4, 0xcb, 0x5a, 0x95, 0x7a, 0xea, 0x6, 0xc0, 0xb9, 0xb8, 0xc7, 0x8b, 0xd, 0x44, 0x17, 0x96, 0xdc, 0x3, 0x50, 0xdd, 0xea, 0xbb, 0x78, 0xa3, 0x3b, 0x6f, 0x1f, 0x9e, 0x68, 0xed, 0xe3, 0xd1, 0x80, 0x5c, 0x7b, 0x7e, 0x2c, 0xfd, 0x54, 0xe0, 0xfa, 0xd6, 0x2f, 0xd, 0x8c, 0xa6, 0x7a, 0x77, 0x5d, 0xc4, 0x54, 0x6a, 0xf9, 0x9, 0x6f, 0x2e, 0xdb, 0x22, 0x1d, 0xb4, 0x28, 0x43, 0xd6, 0x53, 0x27, 0x86, 0x12, 0x82, 0xdc, 0x94, 0x6a, 0xb, 0xa0, 0x1a, 0x11, 0x86, 0x3a, 0xb2, 0xd1, 0xdf, 0xd1, 0x6e, 0x39, 0x73, 0xd4}, - }, -} diff --git a/vendor/github.com/fxamacker/cbor/.github/FUNDING.yml b/vendor/github.com/fxamacker/cbor/.github/FUNDING.yml new file mode 100644 index 0000000..20920bc --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/FUNDING.yml @@ -0,0 +1 @@ +github: [fxamacker] diff --git a/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/1-bug-report.md b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/1-bug-report.md new file mode 100644 index 0000000..3b8f10a --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/1-bug-report.md @@ -0,0 +1,36 @@ +--- +name: "\U0001F41E Bug report" +about: Create a report to help us improve +title: 'bug: ' +labels: '' +assignees: '' + +--- + +### What version of fxamacker/cbor are you using? + + +### Does this issue reproduce with the latest release? + + +### What OS and CPU architecture are you using (`go env`)? + +
go env Output
+$ go env
+
+
+ +### What did you do? + + + + + + +### What did you expect to see? + + + +### What did you see instead? diff --git a/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/2-feature-request.md b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/2-feature-request.md new file mode 100644 index 0000000..4cf33f4 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/2-feature-request.md @@ -0,0 +1,20 @@ +--- +name: "\U0001F4A1 Feature request" +about: Suggest an idea for this project +title: 'feature: ' +labels: '' +assignees: '' + +--- + +**Is your feature request related to a problem? Please describe.** +A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] + +**Describe the solution you'd like** +A clear and concise description of what you want to happen. + +**Describe alternatives you've considered** +A clear and concise description of any alternative solutions or features you've considered. + +**Additional context** +Add any other context or screenshots about the feature request here. diff --git a/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/3-docs-wiki-or-website-issue.md b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/3-docs-wiki-or-website-issue.md new file mode 100644 index 0000000..a044111 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/3-docs-wiki-or-website-issue.md @@ -0,0 +1,16 @@ +--- +name: "\U0001F4DA Docs, wiki, or website issue" +about: Report an issue regarding documentation, wiki, or website +title: 'docs: ' +labels: '' +assignees: '' + +--- + +### What is the URL of the content? + + +### Please describe the problem. + + +### Screenshot (if applicable). diff --git a/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/4-security-issue-disclosure.md b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/4-security-issue-disclosure.md new file mode 100644 index 0000000..03f02d2 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/ISSUE_TEMPLATE/4-security-issue-disclosure.md @@ -0,0 +1,16 @@ +--- +name: "\U0001F513 Security issue disclosure" +about: Report a security issue in fxamacker/cbor +title: '' +labels: '' +assignees: '' + +--- + + diff --git a/vendor/github.com/fxamacker/cbor/.github/pull_request_template.md b/vendor/github.com/fxamacker/cbor/.github/pull_request_template.md new file mode 100644 index 0000000..70ef8ca --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/pull_request_template.md @@ -0,0 +1,69 @@ + + +#### Description (motivation) + + + + + +#### PR Was Proposed and Welcomed in Currently Open Issue +This PR was proposed and welcomed by maintainer(s) in issue # + +Closes # + +#### Checklist (for code PR only, ignore for docs PR) + +- [ ] Include unit tests that cover the new code +- [ ] Pass all unit tests +- [ ] Pass all 18 ci linters (golint, gosec, staticcheck, etc.) +- [ ] Sign each commit with your real name and email. + Last line of each commit message should be in this format: + Signed-off-by: Firstname Lastname +- [ ] Certify the Developer's Certificate of Origin 1.1 + (see next section). + +#### Certify the Developer's Certificate of Origin 1.1 + +- [ ] By marking this item as completed, I certify + the Developer Certificate of Origin 1.1. + +``` +Developer Certificate of Origin +Version 1.1 + +Copyright (C) 2004, 2006 The Linux Foundation and its contributors. +660 York Street, Suite 102, +San Francisco, CA 94110 USA + +Everyone is permitted to copy and distribute verbatim copies of this +license document, but changing it is not allowed. + +Developer's Certificate of Origin 1.1 + +By making a contribution to this project, I certify that: + +(a) The contribution was created in whole or in part by me and I + have the right to submit it under the open source license + indicated in the file; or + +(b) The contribution is based upon previous work that, to the best + of my knowledge, is covered under an appropriate open source + license and I have the right under that license to submit that + work with modifications, whether created in whole or in part + by me, under the same open source license (unless I am + permitted to submit under a different license), as indicated + in the file; or + +(c) The contribution was provided directly to me by some other + person who certified (a), (b) or (c) and I have not modified + it. + +(d) I understand and agree that this project and the contribution + are public and that a record of the contribution (including all + personal information I submit with it, including my sign-off) is + maintained indefinitely and may be redistributed consistent with + this project or the open source license(s) involved. +``` + diff --git a/vendor/github.com/fxamacker/cbor/.github/workflows/ci-go-cover.yml b/vendor/github.com/fxamacker/cbor/.github/workflows/ci-go-cover.yml new file mode 100644 index 0000000..deb2035 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/workflows/ci-go-cover.yml @@ -0,0 +1,33 @@ +# Copyright 2020-present Montgomery Edwards⁴⁴⁸ (github.com/x448). +# This file is licensed under the MIT License. See LICENSE at https://github.com/x448/workflows for the full text. +# +# CI Go Cover 2020.1.28. +# This GitHub Actions workflow checks if Go (Golang) code coverage satisfies the required minimum. +# The required minimum is specified in the workflow name to keep badge.svg and verified minimum in sync. +# +# To help protect your privacy, this workflow avoids external services. +# This workflow simply runs `go test -short -cover` --> grep --> python. +# The python script is embedded and readable in this file. +# +# Steps to install and set minimum required coverage: +# 0. Copy this file to github.com/OWNER_NAME/REPO_NAME/.github/workflows/ci-go-cover.yml +# 1. Change workflow name from "cover 100%" to "cover ≥92.5%". Script will automatically use 92.5%. +# 2. Update README.md to use the new path to badge.svg because the path includes the workflow name. + +name: cover ≥98% +on: [push] +jobs: + + # Verify minimum coverage is reached using `go test -short -cover` on latest-ubuntu with default version of Go. + # The grep expression can't be too strict, it needed to be relaxed to work with different versions of Go. + cover: + name: Coverage + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Go Coverage + run: | + go version + go test -short -cover | grep "^.*coverage:.*of statements$" | python -c "import os,re,sys; cover_rpt = sys.stdin.read(); print(cover_rpt) if len(cover_rpt) != 0 and len(cover_rpt.splitlines()) == 1 else sys.exit(1); min_cover = float(re.findall(r'\d*\.\d+|\d+', os.environ['GITHUB_WORKFLOW'])[0]); cover = float(re.findall(r'\d*\.\d+|\d+', cover_rpt)[0]); sys.exit(1) if (cover > 100) or (cover < min_cover) else sys.exit(0)" + shell: bash diff --git a/vendor/github.com/fxamacker/cbor/.github/workflows/ci.yml b/vendor/github.com/fxamacker/cbor/.github/workflows/ci.yml new file mode 100644 index 0000000..91cdbd6 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/workflows/ci.yml @@ -0,0 +1,26 @@ +# GitHub Actions - CI for Go to build & test. See ci-go-cover.yml and linters.yml for code coverage and linters. +# https://github.com/fxamacker/cbor/workflows/ci.yml +name: ci +on: [push] +jobs: + + # Test on various OS with default Go version. + tests: + name: Test on ${{matrix.os}} + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [macos-latest, ubuntu-latest] + steps: + - name: Checkout code + uses: actions/checkout@v1 + with: + fetch-depth: 1 + - name: Get dependencies + run: go get -v -t -d ./... + - name: Build project + run: go build ./... + - name: Run tests + run: | + go version + go test -short -race -v ./... diff --git a/vendor/github.com/fxamacker/cbor/.github/workflows/linters.yml b/vendor/github.com/fxamacker/cbor/.github/workflows/linters.yml new file mode 100644 index 0000000..6153141 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.github/workflows/linters.yml @@ -0,0 +1,20 @@ +# Go Linters - GitHub Actions +name: linters +on: [push] +jobs: + + # Check linters on latest-ubuntu with default version of Go. + lint: + name: Lint + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Install golangci-lint + run: | + go version + curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.23.8 + - name: Run required linters in .golangci.yml plus hard-coded ones here + run: $(go env GOPATH)/bin/golangci-lint run --timeout=3m + - name: Run optional linters (not required to pass) + run: $(go env GOPATH)/bin/golangci-lint run --timeout=3m --issues-exit-code=0 -E dupl -E gocritic -E gosimple -E lll -E prealloc diff --git a/vendor/github.com/fxamacker/cbor/.gitignore b/vendor/github.com/fxamacker/cbor/.gitignore new file mode 100644 index 0000000..f1c181e --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.gitignore @@ -0,0 +1,12 @@ +# Binaries for programs and plugins +*.exe +*.exe~ +*.dll +*.so +*.dylib + +# Test binary, build with `go test -c` +*.test + +# Output of the go coverage tool, specifically when used with LiteIDE +*.out diff --git a/vendor/github.com/fxamacker/cbor/.golangci.yml b/vendor/github.com/fxamacker/cbor/.golangci.yml new file mode 100644 index 0000000..0448042 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/.golangci.yml @@ -0,0 +1,86 @@ +# Do not delete linter settings. Linters like gocritic can be enabled on the command line. + +linters-settings: + dupl: + threshold: 100 + funlen: + lines: 100 + statements: 50 + goconst: + min-len: 2 + min-occurrences: 3 + gocritic: + enabled-tags: + - diagnostic + - experimental + - opinionated + - performance + - style + disabled-checks: + - dupImport # https://github.com/go-critic/go-critic/issues/845 + - ifElseChain + - octalLiteral + - paramTypeCombine + - whyNoLint + - wrapperFunc + gofmt: + simplify: false + goimports: + local-prefixes: github.com/fxamacker/cbor + golint: + min-confidence: 0 + govet: + check-shadowing: true + lll: + line-length: 140 + maligned: + suggest-new: true + misspell: + locale: US + +linters: + disable-all: true + enable: + - deadcode + - errcheck + - goconst + - gocyclo + - gofmt + - goimports + - golint + - gosec + - govet + - ineffassign + - maligned + - misspell + - staticcheck + - structcheck + - typecheck + - unconvert + - unused + - varcheck + + +issues: + # max-issues-per-linter default is 50. Set to 0 to disable limit. + max-issues-per-linter: 0 + # max-same-issues default is 3. Set to 0 to disable limit. + max-same-issues: 0 + # Excluding configuration per-path, per-linter, per-text and per-source + exclude-rules: + - path: _test\.go + linters: + - goconst + - dupl + - gomnd + - lll + - path: doc\.go + linters: + - goimports + - gomnd + - lll + +# golangci.com configuration +# https://github.com/golangci/golangci/wiki/Configuration +service: + golangci-lint-version: 1.23.x # use the fixed version to not introduce new linters unexpectedly diff --git a/vendor/github.com/fxamacker/cbor/CBOR_BENCHMARKS.md b/vendor/github.com/fxamacker/cbor/CBOR_BENCHMARKS.md new file mode 100644 index 0000000..d4ea189 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/CBOR_BENCHMARKS.md @@ -0,0 +1,264 @@ +# CBOR Benchmarks for fxamacker/cbor + +See [bench_test.go](bench_test.go). + +Benchmarks on Feb. 22, 2020 with cbor v2.2.0: +* [Go builtin types](#go-builtin-types) +* [Go structs](#go-structs) +* [Go structs with "keyasint" struct tag](#go-structs-with-keyasint-struct-tag) +* [Go structs with "toarray" struct tag](#go-structs-with-toarray-struct-tag) +* [COSE data](#cose-data) +* [CWT claims data](#cwt-claims-data) +* [SenML data](#SenML-data) + +## Go builtin types + +Benchmarks use data representing the following values: + +* Boolean: `true` +* Positive integer: `18446744073709551615` +* Negative integer: `-1000` +* Float: `-4.1` +* Byte string: `h'0102030405060708090a0b0c0d0e0f101112131415161718191a'` +* Text string: `"The quick brown fox jumps over the lazy dog"` +* Array: `[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26]` +* Map: `{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}}` + +Decoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkUnmarshal/CBOR_bool_to_Go_interface_{}-2 | 110 ns/op | 16 B/op | 1 allocs/op +BenchmarkUnmarshal/CBOR_bool_to_Go_bool-2 | 99.3 ns/op | 1 B/op | 1 allocs/op +BenchmarkUnmarshal/CBOR_positive_int_to_Go_interface_{}-2 | 135 ns/op | 24 B/op | 2 allocs/op +BenchmarkUnmarshal/CBOR_positive_int_to_Go_uint64-2 | 116 ns/op | 8 B/op | 1 allocs/op +BenchmarkUnmarshal/CBOR_negative_int_to_Go_interface_{}-2 | 133 ns/op | 24 B/op | 2 allocs/op +BenchmarkUnmarshal/CBOR_negative_int_to_Go_int64-2 | 113 ns/op | 8 B/op | 1 allocs/op +BenchmarkUnmarshal/CBOR_float_to_Go_interface_{}-2 | 137 ns/op | 24 B/op | 2 allocs/op +BenchmarkUnmarshal/CBOR_float_to_Go_float64-2 | 115 ns/op | 8 B/op | 1 allocs/op +BenchmarkUnmarshal/CBOR_bytes_to_Go_interface_{}-2 | 179 ns/op | 80 B/op | 3 allocs/op +BenchmarkUnmarshal/CBOR_bytes_to_Go_[]uint8-2 | 194 ns/op | 64 B/op | 2 allocs/op +BenchmarkUnmarshal/CBOR_text_to_Go_interface_{}-2 | 209 ns/op | 80 B/op | 3 allocs/op +BenchmarkUnmarshal/CBOR_text_to_Go_string-2 | 193 ns/op | 64 B/op | 2 allocs/op +BenchmarkUnmarshal/CBOR_array_to_Go_interface_{}-2 |1068 ns/op | 672 B/op | 29 allocs/op +BenchmarkUnmarshal/CBOR_array_to_Go_[]int-2 | 1073 ns/op | 272 B/op | 3 allocs/op +BenchmarkUnmarshal/CBOR_map_to_Go_interface_{}-2 | 2926 ns/op | 1420 B/op | 30 allocs/op +BenchmarkUnmarshal/CBOR_map_to_Go_map[string]interface_{}-2 | 3755 ns/op | 965 B/op | 19 allocs/op +BenchmarkUnmarshal/CBOR_map_to_Go_map[string]string-2 | 2586 ns/op | 740 B/op | 5 allocs/op + +Encoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkMarshal/Go_bool_to_CBOR_bool-2 | 86.1 ns/op | 1 B/op | 1 allocs/op +BenchmarkMarshal/Go_uint64_to_CBOR_positive_int-2 | 97.0 ns/op | 16 B/op | 1 allocs/op +BenchmarkMarshal/Go_int64_to_CBOR_negative_int-2 | 90.3 ns/op | 3 B/op | 1 allocs/op +BenchmarkMarshal/Go_float64_to_CBOR_float-2 | 97.9 ns/op | 16 B/op | 1 allocs/op +BenchmarkMarshal/Go_[]uint8_to_CBOR_bytes-2 | 121 ns/op | 32 B/op | 1 allocs/op +BenchmarkMarshal/Go_string_to_CBOR_text-2 | 115 ns/op | 48 B/op | 1 allocs/op +BenchmarkMarshal/Go_[]int_to_CBOR_array-2 | 529 ns/op | 32 B/op | 1 allocs/op +BenchmarkMarshal/Go_map[string]string_to_CBOR_map-2 | 2115 ns/op | 576 B/op | 28 allocs/op + +## Go structs + +Benchmarks use struct and map[string]interface{} representing the following value: + +``` +{ + "T": true, + "Ui": uint(18446744073709551615), + "I": -1000, + "F": -4.1, + "B": []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + "S": "The quick brown fox jumps over the lazy dog", + "Slci": []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + "Mss": map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, +} +``` + +Decoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkUnmarshal/CBOR_map_to_Go_map[string]interface{}-2 | 6221 ns/op | 2621 B/op | 73 allocs/op +BenchmarkUnmarshal/CBOR_map_to_Go_struct-2 | 4458 ns/op | 1172 B/op | 10 allocs/op + +Encoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkMarshal/Go_map[string]interface{}_to_CBOR_map-2 | 4441 ns/op | 1072 B/op | 45 allocs/op +BenchmarkMarshal/Go_struct_to_CBOR_map-2 | 2866 ns/op | 720 B/op | 28 allocs/op + +## Go structs with "keyasint" struct tag + +Benchmarks use struct (with keyasint struct tag) and map[int]interface{} representing the following value: + +``` +{ + 1: true, + 2: uint(18446744073709551615), + 3: -1000, + 4: -4.1, + 5: []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + 6: "The quick brown fox jumps over the lazy dog", + 7: []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + 8: map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, +} +``` + +Struct type with keyasint struct tag is used to handle CBOR map with integer keys. + +``` +type T struct { + T bool `cbor:"1,keyasint"` + Ui uint `cbor:"2,keyasint"` + I int `cbor:"3,keyasint"` + F float64 `cbor:"4,keyasint"` + B []byte `cbor:"5,keyasint"` + S string `cbor:"6,keyasint"` + Slci []int `cbor:"7,keyasint"` + Mss map[string]string `cbor:"8,keyasint"` +} +``` + +Decoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkUnmarshal/CBOR_map_to_Go_map[int]interface{}-2| 6030 ns/op | 2517 B/op | 70 allocs/op +BenchmarkUnmarshal/CBOR_map_to_Go_struct_keyasint-2 | 4332 ns/op | 1173 B/op | 10 allocs/op + +Encoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkMarshal/Go_map[int]interface{}_to_CBOR_map-2 | 4348 ns/op | 992 B/op | 45 allocs/op +BenchmarkMarshal/Go_struct_keyasint_to_CBOR_map-2 | 2847 ns/op | 704 B/op | 28 allocs/op + +## Go structs with "toarray" struct tag + +Benchmarks use struct (with toarray struct tag) and []interface{} representing the following value: + +``` +[ + true, + uint(18446744073709551615), + -1000, + -4.1, + []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + "The quick brown fox jumps over the lazy dog", + []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"} +] +``` + +Struct type with toarray struct tag is used to handle CBOR array. + +``` +type T struct { + _ struct{} `cbor:",toarray"` + T bool + Ui uint + I int + F float64 + B []byte + S string + Slci []int + Mss map[string]string +} +``` + +Decoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkUnmarshal/CBOR_array_to_Go_[]interface{}-2 | 4863 ns/op | 2404 B/op | 67 allocs/op +BenchmarkUnmarshal/CBOR_array_to_Go_struct_toarray-2 | 4173 ns/op | 1164 B/op | 9 allocs/op + +Encoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkMarshal/Go_[]interface{}_to_CBOR_map-2 | 3240 ns/op | 704 B/op | 28 allocs/op +BenchmarkMarshal/Go_struct_toarray_to_CBOR_array-2 | 2823 ns/op | 704 B/op | 28 allocs/op + +## COSE data + +Benchmarks use COSE data from https://tools.ietf.org/html/rfc8392#appendix-A section A.2 + +``` +// 128-Bit Symmetric COSE_Key +{ + / k / -1: h'231f4c4d4d3051fdc2ec0a3851d5b383' + / kty / 1: 4 / Symmetric /, + / kid / 2: h'53796d6d6574726963313238' / 'Symmetric128' /, + / alg / 3: 10 / AES-CCM-16-64-128 / +} +// 256-Bit Symmetric COSE_Key +{ + / k / -1: h'403697de87af64611c1d32a05dab0fe1fcb715a86ab435f1 + ec99192d79569388' + / kty / 1: 4 / Symmetric /, + / kid / 4: h'53796d6d6574726963323536' / 'Symmetric256' /, + / alg / 3: 4 / HMAC 256/64 / +} +// ECDSA 256-Bit COSE Key +{ + / d / -4: h'6c1382765aec5358f117733d281c1c7bdc39884d04a45a1e + 6c67c858bc206c19', + / y / -3: h'60f7f1a780d8a783bfb7a2dd6b2796e8128dbbcef9d3d168 + db9529971a36e7b9', + / x / -2: h'143329cce7868e416927599cf65a34f3ce2ffda55a7eca69 + ed8919a394d42f0f', + / crv / -1: 1 / P-256 /, + / kty / 1: 2 / EC2 /, + / kid / 2: h'4173796d6d657472696345434453413 + 23536' / 'AsymmetricECDSA256' /, + / alg / 3: -7 / ECDSA 256 / +} +``` + +Decoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkUnmarshalCOSE/128-Bit_Symmetric_Key-2 | 562 ns/op | 240 B/op | 4 allocs/op +BenchmarkUnmarshalCOSE/256-Bit_Symmetric_Key-2 | 568 ns/op | 256 B/op | 4 allocs/op +BenchmarkUnmarshalCOSE/ECDSA_P256_256-Bit_Key-2 | 968 ns/op | 360 B/op | 7 allocs/op + +Encoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkMarshalCOSE/128-Bit_Symmetric_Key-2 | 523 ns/op | 224 B/op | 2 allocs/op +BenchmarkMarshalCOSE/256-Bit_Symmetric_Key-2 | 521 ns/op | 240 B/op | 2 allocs/op +BenchmarkMarshalCOSE/ECDSA_P256_256-Bit_Key-2 | 668 ns/op | 320 B/op | 2 allocs/op + +## CWT claims data + +Benchmarks use CTW claims data from https://tools.ietf.org/html/rfc8392#appendix-A section A.1 + +``` +{ + / iss / 1: "coap://as.example.com", + / sub / 2: "erikw", + / aud / 3: "coap://light.example.com", + / exp / 4: 1444064944, + / nbf / 5: 1443944944, + / iat / 6: 1443944944, + / cti / 7: h'0b71' +} +``` + +Decoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkUnmarshalCWTClaims-2 | 765 ns/op | 176 B/op | 6 allocs/op + +Encoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkMarshalCWTClaims-2 | 451 ns/op | 176 B/op | 2 allocs/op + +## SenML data + +Benchmarks use SenML data from https://tools.ietf.org/html/rfc8428#section-6 + +``` +[ + {-2: "urn:dev:ow:10e2073a0108006:", -3: 1276020076.001, -4: "A", -1: 5, 0: "voltage", 1: "V", 2: 120.1}, + {0: "current", 6: -5, 2: 1.2}, + {0: "current", 6: -4, 2: 1.3}, + {0: "current", 6: -3, 2: 1.4}, + {0: "current", 6: -2, 2: 1.5}, + {0: "current", 6: -1, 2: 1.6}, + {0: "current", 6: 0, 2: 1.7} +] +``` + +Decoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkUnmarshalSenML-2 | 3106 ns/op | 1544 B/op | 18 allocs/op + +Encoding Benchmark | Time | Memory | Allocs +--- | ---: | ---: | ---: +BenchmarkMarshalSenML-2 | 2976 ns/op | 272 B/op | 2 allocs/op diff --git a/vendor/github.com/fxamacker/cbor/CBOR_GOLANG.md b/vendor/github.com/fxamacker/cbor/CBOR_GOLANG.md new file mode 100644 index 0000000..c9360ca --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/CBOR_GOLANG.md @@ -0,0 +1,32 @@ +👉 [Comparisons](https://github.com/fxamacker/cbor#comparisons) • [Status](https://github.com/fxamacker/cbor#current-status) • [Design Goals](https://github.com/fxamacker/cbor#design-goals) • [Features](https://github.com/fxamacker/cbor#features) • [Standards](https://github.com/fxamacker/cbor#standards) • [Fuzzing](https://github.com/fxamacker/cbor#fuzzing-and-code-coverage) • [Usage](https://github.com/fxamacker/cbor#usage) • [Security Policy](https://github.com/fxamacker/cbor#security-policy) • [License](https://github.com/fxamacker/cbor#license) + +# CBOR +[CBOR](https://en.wikipedia.org/wiki/CBOR) is a data format designed to allow small code size and small message size. CBOR is defined in [RFC 7049 Concise Binary Object Representation](https://tools.ietf.org/html/rfc7049), an [IETF](http://ietf.org/) Internet Standards Document. + +CBOR is also designed to be stable for decades, be extensible without need for version negotiation, and not require a schema. + +While JSON uses text, CBOR uses binary. CDDL can be used to express CBOR (and JSON) in an easy and unambiguous way. CDDL is defined in (RFC 8610 Concise Data Definition Language). + +## CBOR in Golang (Go) +[Golang](https://golang.org/) is a nickname for the Go programming language. Go is specified in [The Go Programming Language Specification](https://golang.org/ref/spec). + +__[fxamacker/cbor](https://github.com/fxamacker/cbor)__ is a library (written in Go) that encodes and decodes CBOR. The API design of fxamacker/cbor is based on Go's [`encoding/json`](https://golang.org/pkg/encoding/json/). The design and reliability of fxamacker/cbor makes it ideal for encoding and decoding COSE. + +## COSE +COSE is a protocol using CBOR for basic security services. COSE is defined in ([RFC 8152 CBOR Object Signing and Encryption](https://tools.ietf.org/html/rfc8152)). + +COSE describes how to create and process signatures, message authentication codes, and encryption using CBOR for serialization. COSE specification also describes how to represent cryptographic keys using CBOR. COSE is used by WebAuthn. + +## CWT +CBOR Web Token (CWT) is defined in [RFC 8392](http://tools.ietf.org/html/rfc8392). CWT is based on COSE and was derived in part from JSON Web Token (JWT). CWT is a compact way to securely represent claims to be transferred between two parties. + +## WebAuthn +[WebAuthn](https://en.wikipedia.org/wiki/WebAuthn) (Web Authentication) is a web standard for authenticating users to web-based apps and services. It's a core component of FIDO2, the successor of FIDO U2F legacy protocol. + +__[fxamacker/webauthn](https://github.com/fxamacker/webauthn)__ is a library (written in Go) that performs server-side authentication for clients using FIDO2 keys, legacy FIDO U2F keys, tpm, and etc. + +Copyright (c) Faye Amacker and contributors. + +
+ +👉 [Comparisons](https://github.com/fxamacker/cbor#comparisons) • [Status](https://github.com/fxamacker/cbor#current-status) • [Design Goals](https://github.com/fxamacker/cbor#design-goals) • [Features](https://github.com/fxamacker/cbor#features) • [Standards](https://github.com/fxamacker/cbor#standards) • [Fuzzing](https://github.com/fxamacker/cbor#fuzzing-and-code-coverage) • [Usage](https://github.com/fxamacker/cbor#usage) • [Security Policy](https://github.com/fxamacker/cbor#security-policy) • [License](https://github.com/fxamacker/cbor#license) diff --git a/vendor/github.com/rivo/tview/CODE_OF_CONDUCT.md b/vendor/github.com/fxamacker/cbor/CODE_OF_CONDUCT.md similarity index 86% rename from vendor/github.com/rivo/tview/CODE_OF_CONDUCT.md rename to vendor/github.com/fxamacker/cbor/CODE_OF_CONDUCT.md index 601e63b..bc1f077 100644 --- a/vendor/github.com/rivo/tview/CODE_OF_CONDUCT.md +++ b/vendor/github.com/fxamacker/cbor/CODE_OF_CONDUCT.md @@ -5,9 +5,9 @@ In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body -size, disability, ethnicity, gender identity and expression, level of experience, -education, socio-economic status, nationality, personal appearance, race, -religion, or sexual identity and orientation. +size, disability, ethnicity, sex characteristics, gender identity and expression, +level of experience, education, socio-economic status, nationality, personal +appearance, race, religion, or sexual identity and orientation. ## Our Standards @@ -23,13 +23,13 @@ include: Examples of unacceptable behavior by participants include: * The use of sexualized language or imagery and unwelcome sexual attention or - advances + advances * Trolling, insulting/derogatory comments, and personal or political attacks * Public or private harassment * Publishing others' private information, such as a physical or electronic - address, without explicit permission + address, without explicit permission * Other conduct which could reasonably be considered inappropriate in a - professional setting + professional setting ## Our Responsibilities @@ -55,7 +55,7 @@ further defined and clarified by project maintainers. ## Enforcement Instances of abusive, harassing, or otherwise unacceptable behavior may be -reported by contacting the project team at https://rentafounder.com/page/about-me/. All +reported by contacting the project team at faye.github@gmail.com. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. @@ -71,3 +71,6 @@ This Code of Conduct is adapted from the [Contributor Covenant][homepage], versi available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html [homepage]: https://www.contributor-covenant.org + +For answers to common questions about this code of conduct, see +https://www.contributor-covenant.org/faq diff --git a/vendor/github.com/fxamacker/cbor/CONTRIBUTING.md b/vendor/github.com/fxamacker/cbor/CONTRIBUTING.md new file mode 100644 index 0000000..1a2321c --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/CONTRIBUTING.md @@ -0,0 +1,47 @@ +# How to contribute + +This project started because I needed an easy, small, and crash-proof CBOR library for my [WebAuthn (FIDO2) server library](https://github.com/fxamacker/webauthn). I believe this was the first and still only standalone CBOR library (in Go) that is fuzz tested as of November 10, 2019. + +To my surprise, Stefan Tatschner (rumpelsepp) submitted the first 2 issues when I didn't expect this project to be noticed. So I decided to make it more full-featured for others by announcing releases and asking for feedback. Even this document exists because Montgomery Edwards⁴⁴⁸ (x448) opened [issue #22](https://github.com/fxamacker/cbor/issues/22). In other words, you can contribute by opening an issue that helps the project improve. Especially in the early stages. + +When I announced v1.2 on Go Forum, Jakob Borg (calmh) responded with a thumbs up and encouragement. Another project of equal priority needed my time and Jakob's kind words tipped the scale for me to work on this one (speedups for [milestone v1.3](https://github.com/fxamacker/cbor/issues?q=is%3Aopen+is%3Aissue+milestone%3Av1.3.0).) So words of appreciation or encouragement is nice way to contribute to open source projects. + +Another way is by using this library in your project. It can lead to features that benefit both projects, which is what happened when oasislabs/oasis-core switched to this CBOR libary -- thanks Yawning Angel (yawning) for requesting BinaryMarshaler/BinaryUnmarshaler and Jernej Kos (kostco) for requesting RawMessage! + +If you'd like to contribute code or send CBOR data, please read on (it can save you time!) + +## Private reports +Usually, all issues are tracked publicly on [GitHub](https://github.com/fxamacker/cbor/issues). + +To report security vulnerabilities, please email faye.github@gmail.com and allow time for the problem to be resolved before disclosing it to the public. For more info, see [Security Policy](https://github.com/fxamacker/cbor#security-policy). + +Please do not send data that might contain personally identifiable information, even if you think you have permission. That type of support requires payment and a contract where I'm indemnified, held harmless, and defended for any data you send to me. + +## Prerequisites to pull requests +Please [create an issue](https://github.com/fxamacker/cbor/issues/new/choose), if one doesn't already exist, and describe your concern. You'll need a [GitHub account](https://github.com/signup/free) to do this. + +If you submit a pull request without creating an issue and getting a response, you risk having your work unused because the bugfix or feature was already done by others and being reviewed before reaching Github. + +## Describe your issue +Clearly describe the issue: +* If it's a bug, please provide: **version of this library** and **Go** (`go version`), **unmodified error message**, and describe **how to reproduce it**. Also state **what you expected to happen** instead of the error. +* If you propose a change or addition, try to give an example how the improved code could look like or how to use it. +* If you found a compilation error, please confirm you're using a supported version of Go. If you are, then provide the output of `go version` first, followed by the complete error message. + +## Please don't +Please don't send data containing personally identifiable information, even if you think you have permission. That type of support requires payment and a contract where I'm indemnified, held harmless, and defended for any data you send to me. + +Please don't send CBOR data larger than 512 bytes. If you want to send crash-producing CBOR data > 512 bytes, please get my permission before sending it to me. + +## Wanted +* Opening issues that are helpful to the project +* Using this library in your project and letting me know +* Sending well-formed CBOR data (<= 512 bytes) that causes crashes (none found yet). +* Sending malformed CBOR data (<= 512 bytes) that causes crashes (none found yet, but bad actors are better than me at breaking things). +* Sending tests or data for unit tests that increase code coverage (currently at 97.8% for v1.2.) +* Pull requests with small changes that are well-documented and easily understandable. +* Sponsors, donations, bounties, subscriptions: I'd like to run uninterrupted fuzzing between releases on a server with dedicated CPUs (after v1.3 or v1.4.) + +## Credits +This guide used nlohmann/json contribution guidelines for inspiration as suggested in issue #22. + diff --git a/vendor/github.com/rivo/tview/LICENSE.txt b/vendor/github.com/fxamacker/cbor/LICENSE similarity index 95% rename from vendor/github.com/rivo/tview/LICENSE.txt rename to vendor/github.com/fxamacker/cbor/LICENSE index 9d69430..eaa8504 100644 --- a/vendor/github.com/rivo/tview/LICENSE.txt +++ b/vendor/github.com/fxamacker/cbor/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2018 Oliver Kuederle +Copyright (c) 2019-present Faye Amacker Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -18,4 +18,4 @@ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +SOFTWARE. \ No newline at end of file diff --git a/vendor/github.com/fxamacker/cbor/README.md b/vendor/github.com/fxamacker/cbor/README.md new file mode 100644 index 0000000..b7e5268 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/README.md @@ -0,0 +1,1079 @@ +[![CBOR Library - Slideshow and Latest Docs.](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_slides.gif)](https://github.com/fxamacker/cbor/blob/master/README.md) + +# CBOR library in Go +[__fxamacker/cbor__](https://github.com/fxamacker/cbor) is a CBOR encoder & decoder in [Go](https://golang.org). It has a standard API, CBOR tags, options for duplicate map keys, float64→32→16, `toarray`, `keyasint`, etc. Each release passes 375+ tests and 250+ million execs fuzzing. + +[CBOR](CBOR_GOLANG.md) ([RFC 7049](https://tools.ietf.org/html/rfc7049)) is a binary data format inspired by JSON and MessagePack. CBOR is an [Internet Standard](https://en.wikipedia.org/wiki/Internet_Standard) by [IETF](https://www.ietf.org) used in W3C [WebAuthn](https://en.wikipedia.org/wiki/WebAuthn), COSE ([RFC 8152](https://tools.ietf.org/html/rfc8152)), CWT ([RFC 8392 CBOR Web Token](https://tools.ietf.org/html/rfc8392)), and more. + +[![](https://github.com/fxamacker/cbor/workflows/ci/badge.svg)](https://github.com/fxamacker/cbor/actions?query=workflow%3Aci) +[![](https://github.com/fxamacker/cbor/workflows/cover%20%E2%89%A598%25/badge.svg)](https://github.com/fxamacker/cbor/actions?query=workflow%3A%22cover+%E2%89%A598%25%22) +[![](https://github.com/fxamacker/cbor/workflows/linters/badge.svg)](https://github.com/fxamacker/cbor/actions?query=workflow%3Alinters) +[![Go Report Card](https://goreportcard.com/badge/github.com/fxamacker/cbor)](https://goreportcard.com/report/github.com/fxamacker/cbor) +[![](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/release_version_badge.svg?sanitize=1)](https://github.com/fxamacker/cbor/releases) +[![](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/license_badge.svg?sanitize=1)](https://raw.githubusercontent.com/fxamacker/cbor/master/LICENSE) + +__fxamacker/cbor__ is secure. It rejects malformed CBOR data, can detect duplicate map keys, and more. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_security_table.svg?sanitize=1 "CBOR Security Comparison") + +For more info, see [RFC 7049 Section 8 (Security Considerations)](https://tools.ietf.org/html/rfc7049#section-8). + +
+ +__fxamacker/cbor__ is easy. It provides standard API and interfaces. + +__Standard API__. Function signatures identical to [`encoding/json`](https://golang.org/pkg/encoding/json/) include: +`Marshal`, `Unmarshal`, `NewEncoder`, `NewDecoder`, `(*Encoder).Encode`, and `(*Decoder).Decode`. + +__Standard Interfaces__. Custom encoding and decoding is handled by implementing: +`BinaryMarshaler`, `BinaryUnmarshaler`, `Marshaler`, and `Unmarshaler`. + +It's also designed to simplify concurrency and allow fast parallelism. CBOR options can be used without creating unintended runtime side-effects. + +
+ +__fxamacker/cbor__ saves time. It has killer features like __`toarray`__ and __`keyasint`__ struct tags. + +
+ +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_struct_tags_api.svg?sanitize=1 "CBOR API and Go Struct Tags") + +
+ +__fxamacker/cbor__ is a full-featured CBOR encoder and decoder. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_features.svg?sanitize=1 "CBOR Features") + +
+ +__fxamacker/cbor__ can produce smaller programs that are faster and use less memory. + +__Click to expand:__ + +
+ CBOR Program Size Comparison

+ +__fxamacker/cbor__ can produce smaller programs. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_size_comparison.png "CBOR library and program size comparison chart") + +

+ +
+ CBOR Speed Comparison

+ +__fxamacker/cbor__ can be faster for CBOR data such as CBOR Web Tokens. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_speed_comparison.png "CBOR library speed comparison chart") + +

+ +
+ CBOR Memory Comparison

+ +__fxamacker/cbor__ can use less memory for CBOR data such as CBOR Web Tokens. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_memory_table.svg?sanitize=1 "CBOR Memory Comparison") + +

+ +Benchmarks used example data from [RFC 8392 Appendix A.1](https://tools.ietf.org/html/rfc8392#appendix-A.1) and default options for CBOR libraries. + +
+ +⚓ [__Installation__](#installation) • [__System Requirements__](#system-requirements) • [__Quick Start Guide__](#quick-start) + +
+ +__Why this CBOR library?__ It doesn't crash and it has well-balanced qualities: small, fast, safe and easy. It also has a standard API, CBOR tags (built-in and user-defined), float64→32→16, and duplicate map key options. + +* __Standard API__. Codec functions with signatures identical to [`encoding/json`](https://golang.org/pkg/encoding/json/) include: +`Marshal`, `Unmarshal`, `NewEncoder`, `NewDecoder`, `(*Encoder).Encode`, and `(*Decoder).Decode`. + +* __Customizable__. Standard interfaces are provided to allow user-implemented encoding or decoding: +`BinaryMarshaler`, `BinaryUnmarshaler`, `Marshaler`, and `Unmarshaler`. + +* __Small apps__. Same programs are 4-9 MB smaller by switching to this library. No code gen and the only imported pkg is [x448/float16](https://github.com/x448/float16) which is maintained by the same team as this library. + +* __Small data__. The `toarray`, `keyasint`, and `omitempty` struct tags shrink size of Go structs encoded to CBOR. Integers encode to smallest form that fits. Floats can shrink from float64 -> float32 -> float16 if values fit. + +* __Fast__. v1.3 became faster than a well-known library that uses `unsafe` optimizations and code gen. Faster libraries will always exist, but speed is only one factor. This library doesn't use `unsafe` optimizations or code gen. + +* __Safe__ and reliable. It prevents crashes on malicious CBOR data by using extensive tests, coverage-guided fuzzing, data validation, and avoiding Go's [`unsafe`](https://golang.org/pkg/unsafe/) pkg. Decoder settings include: `MaxNestedLevels`, `MaxArrayElements`, `MaxMapPairs`, and `IndefLength`. + +* __Easy__ and saves time. Simple (no param) functions return preset `EncOptions` so you don't have to know the differences between Canonical CBOR and CTAP2 Canonical CBOR to use those standards. + +💡 Struct tags are a Go language feature. CBOR tags relate to a CBOR data type (major type 6). + +Struct tags for CBOR and JSON like `` `cbor:"name,omitempty"` `` and `` `json:"name,omitempty"` `` are supported so you can leverage your existing code. If both `cbor:` and `json:` tags exist then it will use `cbor:`. + +New struct tags like __`keyasint`__ and __`toarray`__ make compact CBOR data such as COSE, CWT, and SenML easier to use. + +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Installation + +Using Go modules is recommended. + +Use "/v2" when using `go get`. + +``` +$ GO111MODULE=on go get github.com/fxamacker/cbor/v2 +``` + +Also use "/v2" when importing. + +```go +import ( + "github.com/fxamacker/cbor/v2" // imports as package "cbor" +) +``` + +If Go modules aren't used, delete or modify example_test.go to change the import +from `"github.com/fxamacker/cbor/v2"` to `"github.com/fxamacker/cbor"` + +## System Requirements + +Using Go modules is recommended but not required. + +* Go 1.12 (or newer). +* amd64, arm64, ppc64le and s390x. Other architectures may also work but they are not tested as frequently. + +If Go modules feature isn't used, please see [Installation](#installation) about deleting or modifying example_test.go. + +## Quick Start +🛡️ Use Go's `io.LimitReader` to limit size when decoding very large or indefinite size data. + +Import using "/v2" like this: `import "github.com/fxamacker/cbor/v2"`, and +it will import version 2.x as package "cbor" (when using Go modules). + +Functions with identical signatures to encoding/json include: +`Marshal`, `Unmarshal`, `NewEncoder`, `NewDecoder`, `(*Encoder).Encode`, `(*Decoder).Decode`. + +__Default Mode__ + +If default options are acceptable, package level functions can be used for encoding and decoding. + +```go +b, err := cbor.Marshal(v) // encode v to []byte b + +err := cbor.Unmarshal(b, &v) // decode []byte b to v + +encoder := cbor.NewEncoder(w) // create encoder with io.Writer w + +decoder := cbor.NewDecoder(r) // create decoder with io.Reader r +``` + +__Modes__ + +If you need to use options or CBOR tags, then you'll want to create a mode. + +"Mode" means defined way of encoding or decoding -- it links the standard API to your CBOR options and CBOR tags. This way, you don't pass around options and the API remains identical to `encoding/json`. + +EncMode and DecMode are interfaces created from EncOptions or DecOptions structs. +For example, `em, err := cbor.EncOptions{...}.EncMode()` or `em, err := cbor.CanonicalEncOptions().EncMode()`. + +EncMode and DecMode use immutable options so their behavior won't accidentally change at runtime. Modes are reusable, safe for concurrent use, and allow fast parallelism. + +__Creating and Using Encoding Modes__ + +💡 Avoid using init(). For best performance, reuse EncMode and DecMode after creating them. + +Most apps will probably create one EncMode and DecMode before init(). There's no limit and each can use different options. + +```go +// Create EncOptions using either struct literal or a function. +opts := cbor.CanonicalEncOptions() + +// If needed, modify opts. For example: opts.Time = cbor.TimeUnix + +// Create reusable EncMode interface with immutable options, safe for concurrent use. +em, err := opts.EncMode() + +// Use EncMode like encoding/json, with same function signatures. +b, err := em.Marshal(v) // encode v to []byte b + +encoder := em.NewEncoder(w) // create encoder with io.Writer w +err := encoder.Encode(v) // encode v to io.Writer w +``` + +Both `em.Marshal(v)` and `encoder.Encode(v)` use encoding options specified during creation of encoding mode `em`. + +__Creating Modes With CBOR Tags__ + +A TagSet is used to specify CBOR tags. + +```go +em, err := opts.EncMode() // no tags +em, err := opts.EncModeWithTags(ts) // immutable tags +em, err := opts.EncModeWithSharedTags(ts) // mutable shared tags +``` + +TagSet and all modes using it are safe for concurrent use. Equivalent API is available for DecMode. + +__Predefined Encoding Options__ + +```go +func CanonicalEncOptions() EncOptions {} // settings for RFC 7049 Canonical CBOR +func CTAP2EncOptions() EncOptions {} // settings for FIDO2 CTAP2 Canonical CBOR +func CoreDetEncOptions() EncOptions {} // settings from a draft RFC (subject to change) +func PreferredUnsortedEncOptions() EncOptions {} // settings from a draft RFC (subject to change) +``` + +The empty curly braces prevent a syntax highlighting bug on GitHub, please ignore them. + +__Struct Tags (keyasint, toarray, omitempty)__ + +The `keyasint`, `toarray`, and `omitempty` struct tags make it easy to use compact CBOR message formats. Internet standards often use CBOR arrays and CBOR maps with int keys to save space. + +The following sections provide more info: + +* [Struct Tags](#struct-tags-1) +* [Decoding Options](#decoding-options) +* [Encoding Options](#encoding-options) +* [API](#api) +* [Usage](#usage) + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Current Status +Latest version is v2.x, which has: + +* __Stable API__ – Six codec function signatures will never change. No breaking API changes for other funcs in same major version. And these two functions are subject to change until the draft RFC is approved by IETF (est. in 2020): + * CoreDetEncOptions() is subject to change because it uses draft standard. + * PreferredUnsortedEncOptions() is subject to change because it uses draft standard. +* __Passed all tests__ – v2.x passed all 375+ tests on amd64, arm64, ppc64le and s390x with linux. +* __Passed fuzzing__ – v2.2 passed 459+ million execs in coverage-guided fuzzing on Feb 24 (release date) +and 3.2+ billion execs on March 7, 2020. + +__Why v2.x?__: + +v1 required breaking API changes to support new features like CBOR tags, detection of duplicate map keys, and having more functions with identical signatures to `encoding/json`. + +v2.1 is roughly 26% faster and uses 57% fewer allocs than v1.x when decoding COSE and CWT using default options. + +__Recent Activity__: + +* Release v2.1 (Feb. 17, 2020) + - [x] CBOR tags (major type 6) for encoding and decoding. + - [x] Decoding options for duplicate map key detection: `DupMapKeyQuiet` (default) and `DupMapKeyEnforcedAPF` + - [x] Decoding optimizations. Structs using keyasint tag (like COSE and CWT) is + 24-28% faster and 53-61% fewer allocs than both v1.5 and v2.0.1. + +* Release v2.2 (Feb. 24, 2020) + - [x] CBOR BSTR <--> Go byte array (byte slices were already supported) + - [x] Add more encoding and decoding options (MaxNestedLevels, MaxArrayElements, MaxMapKeyPairs, TagsMd, etc.) + - [x] Fix potential error when decoding shorter CBOR indef length array to Go array (slice wasn't affected). This bug affects all prior versions of 1.x and 2.x. It was found by a recently updated fxamacker/cbor-fuzz. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Design Goals +This library is designed to be a generic CBOR encoder and decoder. It was initially created for a [WebAuthn (FIDO2) server library](https://github.com/fxamacker/webauthn), because existing CBOR libraries (in Go) didn't meet certain criteria in 2019. + +This library is designed to be: + +* __Easy__ – API is like `encoding/json` plus `keyasint` and `toarray` struct tags. +* __Small__ – Programs in cisco/senml are 4 MB smaller by switching to this library. In extreme cases programs can be smaller by 9+ MB. No code gen and the only imported pkg is x448/float16 which is maintained by the same team. +* __Safe and reliable__ – No `unsafe` pkg, coverage >95%, coverage-guided fuzzing, and data validation to avoid crashes on malformed or malicious data. Decoder settings include: `MaxNestedLevels`, `MaxArrayElements`, `MaxMapPairs`, and `IndefLength`. + +Avoiding `unsafe` package has benefits. The `unsafe` package [warns](https://golang.org/pkg/unsafe/): + +> Packages that import unsafe may be non-portable and are not protected by the Go 1 compatibility guidelines. + +All releases prioritize reliability to avoid crashes on decoding malformed CBOR data. See [Fuzzing and Coverage](#fuzzing-and-code-coverage). + +Competing factors are balanced: + +* __Speed__ vs __safety__ vs __size__ – to keep size small, avoid code generation. For safety, validate data and avoid Go's `unsafe` pkg. For speed, use safe optimizations such as caching struct metadata. This library is faster than a well-known library that uses `unsafe` and code gen. +* __Standards compliance__ vs __size__ – Supports CBOR RFC 7049 with minor [limitations](#limitations). To limit bloat, CBOR tags are supported but not all tags are built-in. The API allows users to add tags that aren't built-in. The API also allows custom encoding and decoding of user-defined Go types. + +__Click to expand topic:__ + +
+ Supported CBOR Features (Highlights)

+ +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_features.svg?sanitize=1 "CBOR Features") + +

+ +
+ v2.0 API Design

+ +v2.0 decoupled options from CBOR encoding & decoding functions: + +* More encoding/decoding function signatures are identical to encoding/json. +* More function signatures can remain stable forever. +* More flexibility for evolving internal data types, optimizations, and concurrency. +* Features like CBOR tags can be added without more breaking API changes. +* Options to handle duplicate map keys can be added without more breaking API changes. + +

+ +Features not in Go's standard library are usually not added. However, the __`toarray`__ struct tag in __ugorji/go__ was too useful to ignore. It was added in v1.3 when a project mentioned they were using it with CBOR to save disk space. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Features + +### Standard API + +Many function signatures are identical to encoding/json, including: +`Marshal`, `Unmarshal`, `NewEncoder`, `NewDecoder`, `(*Encoder).Encode`, `(*Decoder).Decode`. + +`RawMessage` can be used to delay CBOR decoding or precompute CBOR encoding, like `encoding/json`. + +Standard interfaces allow user-defined types to have custom CBOR encoding and decoding. They include: +`BinaryMarshaler`, `BinaryUnmarshaler`, `Marshaler`, and `Unmarshaler`. + +`Marshaler` and `Unmarshaler` interfaces are satisfied by `MarshalCBOR` and `UnmarshalCBOR` functions using same params and return types as Go's MarshalJSON and UnmarshalJSON. + +### Struct Tags + +Support "cbor" and "json" keys in Go's struct tags. If both are specified for the same field, then "cbor" is used. + +* a different field name can be specified, like encoding/json. +* `omitempty` omits (ignores) field if value is empty, like encoding/json. +* `-` always omits (ignores) field, like encoding/json. +* `keyasint` treats fields as elements of CBOR maps with specified int key. +* `toarray` treats fields as elements of CBOR arrays. + +See [Struct Tags](#struct-tags-1) for more info. + +### CBOR Tags (New in v2.1) + +There are three broad categories of CBOR tags: + +* __Default built-in CBOR tags__ currently include tag numbers 0 and 1 (Time). Additional default built-in tags in future releases may include tag numbers 2 and 3 (Bignum). + +* __Optional built-in CBOR tags__ may be provided in the future via build flags or optional package(s) to help reduce bloat. + +* __User-defined CBOR tags__ are easy by using TagSet to associate tag numbers to user-defined Go types. + +### Preferred Serialization + +Preferred serialization encodes integers and floating-point values using the fewest bytes possible. + +* Integers are always encoded using the fewest bytes possible. +* Floating-point values can optionally encode from float64->float32->float16 when values fit. + +### Compact Data Size + +The combination of preferred serialization and struct tags (toarray, keyasint, omitempty) allows very compact data size. + +### Predefined Encoding Options + +Easy-to-use functions (no params) return preset EncOptions struct: +`CanonicalEncOptions`, `CTAP2EncOptions`, `CoreDetEncOptions`, `PreferredUnsortedEncOptions` + +### Encoding Options + +Integers always encode to the shortest form that preserves value. By default, time values are encoded without tags. + +Encoding of other data types and map key sort order are determined by encoder options. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_encoptions.svg?sanitize=1 "CBOR Encoding Options") + +See [Options](#options) section for details about each setting. + +### Decoding Options + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_decoptions.svg?sanitize=1 "CBOR Decoding Options") + +See [Options](#options) section for details about each setting. + +### Additional Features + +* Decoder always checks for invalid UTF-8 string errors. +* Decoder always decodes in-place to slices, maps, and structs. +* Decoder tries case-sensitive first and falls back to case-insensitive field name match when decoding to structs. +* Both encoder and decoder support indefinite length CBOR data (["streaming"](https://tools.ietf.org/html/rfc7049#section-2.2)). +* Both encoder and decoder correctly handles nil slice, map, pointer, and interface values. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Standards +This library is a full-featured generic CBOR [(RFC 7049)](https://tools.ietf.org/html/rfc7049) encoder and decoder. Notable CBOR features include: + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_features.svg?sanitize=1 "CBOR Features") + +See the Features section for list of [Encoding Options](#encoding-options) and [Decoding Options](#decoding-options). + +Known limitations are noted in the [Limitations section](#limitations). + +Go nil values for slices, maps, pointers, etc. are encoded as CBOR null. Empty slices, maps, etc. are encoded as empty CBOR arrays and maps. + +Decoder checks for all required well-formedness errors, including all "subkinds" of syntax errors and too little data. + +After well-formedness is verified, basic validity errors are handled as follows: + +* Invalid UTF-8 string: Decoder always checks and returns invalid UTF-8 string error. +* Duplicate keys in a map: Decoder has options to ignore or enforce rejection of duplicate map keys. + +When decoding well-formed CBOR arrays and maps, decoder saves the first error it encounters and continues with the next item. Options to handle this differently may be added in the future. + +By default, decoder treats time values of floating-point NaN and Infinity as if they are CBOR Null or CBOR Undefined. + +See [Options](#options) section for detailed settings or [Features](#features) section for a summary of options. + +__Click to expand topic:__ + +
+ Duplicate Map Keys

+ +This library provides options for fast detection and rejection of duplicate map keys based on applying a Go-specific data model to CBOR's extended generic data model in order to determine duplicate vs distinct map keys. Detection relies on whether the CBOR map key would be a duplicate "key" when decoded and applied to the user-provided Go map or struct. + +`DupMapKeyQuiet` turns off detection of duplicate map keys. It tries to use a "keep fastest" method by choosing either "keep first" or "keep last" depending on the Go data type. + +`DupMapKeyEnforcedAPF` enforces detection and rejection of duplidate map keys. Decoding stops immediately and returns `DupMapKeyError` when the first duplicate key is detected. The error includes the duplicate map key and the index number. + +APF suffix means "Allow Partial Fill" so the destination map or struct can contain some decoded values at the time of error. It is the caller's responsibility to respond to the `DupMapKeyError` by discarding the partially filled result if that's required by their protocol. + +

+ +
+ Tag Validity

+ +This library checks tag validity for built-in tags (currently tag numbers 0 and 1): + +* Inadmissible type for tag content +* Inadmissible value for tag content + +Unknown tag data items (not tag number 0 or 1) are handled in two ways: + +* When decoding into an empty interface, unknown tag data item will be decoded into `cbor.Tag` data type, which contains tag number and tag content. The tag content will be decoded into the default Go data type for the CBOR data type. +* When decoding into other Go types, unknown tag data item is decoded into the specified Go type. If Go type is registered with a tag number, the tag number can optionally be verified. + +Decoder also has an option to forbid tag data items (treat any tag data item as error) which is specified by protocols such as CTAP2 Canonical CBOR. + +For more information, see [decoding options](#decoding-options-1) and [tag options](#tag-options). + +

+ +## Limitations + +If any of these limitations prevent you from using this library, please open an issue along with a link to your project. + +* CBOR `Undefined` (0xf7) value decodes to Go's `nil` value. CBOR `Null` (0xf6) more closely matches Go's `nil`. +* CBOR map keys with data types not supported by Go for map keys are ignored and an error is returned after continuing to decode remaining items. +* When using io.Reader interface to read very large or indefinite length CBOR data, Go's `io.LimitReader` should be used to limit size. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## API +Many function signatures are identical to Go's encoding/json, such as: +`Marshal`, `Unmarshal`, `NewEncoder`, `NewDecoder`, `(*Encoder).Encode`, and `(*Decoder).Decode`. + +Interfaces identical or comparable to Go's encoding, encoding/json, or encoding/gob include: +`Marshaler`, `Unmarshaler`, `BinaryMarshaler`, and `BinaryUnmarshaler`. + +Like `encoding/json`, `RawMessage` can be used to delay CBOR decoding or precompute CBOR encoding. + +"Mode" in this API means defined way of encoding or decoding -- it links the standard API to CBOR options and CBOR tags. + +EncMode and DecMode are interfaces created from EncOptions or DecOptions structs. +For example, `em, err := cbor.EncOptions{...}.EncMode()` or `em, err := cbor.CanonicalEncOptions().EncMode()`. + +EncMode and DecMode use immutable options so their behavior won't accidentally change at runtime. Modes are intended to be reused and are safe for concurrent use. + +__API for Default Mode__ + +If default options are acceptable, then you don't need to create EncMode or DecMode. + +```go +Marshal(v interface{}) ([]byte, error) +NewEncoder(w io.Writer) *Encoder + +Unmarshal(data []byte, v interface{}) error +NewDecoder(r io.Reader) *Decoder +``` + +__API for Creating & Using Encoding Modes__ + +```go +// EncMode interface uses immutable options and is safe for concurrent use. +type EncMode interface { + Marshal(v interface{}) ([]byte, error) + NewEncoder(w io.Writer) *Encoder + EncOptions() EncOptions // returns copy of options +} + +// EncOptions specifies encoding options. +type EncOptions struct { +... +} + +// EncMode returns an EncMode interface created from EncOptions. +func (opts EncOptions) EncMode() (EncMode, error) {} + +// EncModeWithTags returns EncMode with options and tags that are both immutable. +func (opts EncOptions) EncModeWithTags(tags TagSet) (EncMode, error) {} + +// EncModeWithSharedTags returns EncMode with immutable options and mutable shared tags. +func (opts EncOptions) EncModeWithSharedTags(tags TagSet) (EncMode, error) {} +``` + +The empty curly braces prevent a syntax highlighting bug, please ignore them. + +__API for Predefined Encoding Options__ + +```go +func CanonicalEncOptions() EncOptions {} // settings for RFC 7049 Canonical CBOR +func CTAP2EncOptions() EncOptions {} // settings for FIDO2 CTAP2 Canonical CBOR +func CoreDetEncOptions() EncOptions {} // settings from a draft RFC (subject to change) +func PreferredUnsortedEncOptions() EncOptions {} // settings from a draft RFC (subject to change) +``` + +__API for Creating & Using Decoding Modes__ + +```go +// DecMode interface uses immutable options and is safe for concurrent use. +type DecMode interface { + Unmarshal(data []byte, v interface{}) error + NewDecoder(r io.Reader) *Decoder + DecOptions() DecOptions // returns copy of options +} + +// DecOptions specifies decoding options. +type DecOptions struct { +... +} + +// DecMode returns a DecMode interface created from DecOptions. +func (opts DecOptions) DecMode() (DecMode, error) {} + +// DecModeWithTags returns DecMode with options and tags that are both immutable. +func (opts DecOptions) DecModeWithTags(tags TagSet) (DecMode, error) {} + +// DecModeWithSharedTags returns DecMode with immutable options and mutable shared tags. +func (opts DecOptions) DecModeWithSharedTags(tags TagSet) (DecMode, error) {} +``` + +The empty curly braces prevent a syntax highlighting bug, please ignore them. + +__API for Using CBOR Tags__ + +`TagSet` can be used to associate user-defined Go type(s) to tag number(s). It's also used to create EncMode or DecMode. For example, `em := EncOptions{...}.EncModeWithTags(ts)` or `em := EncOptions{...}.EncModeWithSharedTags(ts)`. This allows every standard API exported by em (like `Marshal` and `NewEncoder`) to use the specified tags automatically. + +`Tag` and `RawTag` can be used to encode/decode a tag number with a Go value, but `TagSet` is generally recommended. + +```go +type TagSet interface { + // Add adds given tag number(s), content type, and tag options to TagSet. + Add(opts TagOptions, contentType reflect.Type, num uint64, nestedNum ...uint64) error + + // Remove removes given tag content type from TagSet. + Remove(contentType reflect.Type) +} +``` + +`Tag` and `RawTag` types can also be used to encode/decode tag number with Go value. + +```go +type Tag struct { + Number uint64 + Content interface{} +} + +type RawTag struct { + Number uint64 + Content RawMessage +} +``` + +See [API docs (godoc.org)](https://godoc.org/github.com/fxamacker/cbor) for more details and more functions. See [Usage section](#usage) for usage and code examples. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Options + +Struct tags, decoding options, and encoding options. + +### Struct Tags + +This library supports both "cbor" and "json" key for some (not all) struct tags. If "cbor" and "json" keys are both present for the same field, then "cbor" key will be used. + +| Key | Format Str | Scope | Description | +| --- | ---------- | ----- | ------------| +| cbor or json | "myName" | field | Name of field to use such as "myName", etc. like encoding/json. | +| cbor or json | ",omitempty" | field | Omit (ignore) this field if value is empty, like encoding/json. | +| cbor or json | "-" | field | Omit (ignore) this field always, like encoding/json. | +| cbor | ",keyasint" | field | Treat field as an element of CBOR map with specified int as key. | +| cbor | ",toarray" | struct | Treat each field as an element of CBOR array. This automatically disables "omitempty" and "keyasint" for all fields in the struct. | + +The "keyasint" struct tag requires an integer key to be specified: + +``` +type myStruct struct { + MyField int64 `cbor:-1,keyasint,omitempty` + OurField string `cbor:0,keyasint,omitempty` + FooField Foo `cbor:5,keyasint,omitempty` + BarField Bar `cbor:hello,omitempty` + ... +} +``` + +The "toarray" struct tag requires a special field "_" (underscore) to indicate "toarray" applies to the entire struct: + +``` +type myStruct struct { + _ struct{} `cbor:",toarray"` + MyField int64 + OurField string + ... +} +``` + +__Click to expand:__ + +
+ Example Using CBOR Web Tokens

+ +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_struct_tags_api.svg?sanitize=1 "CBOR API and Go Struct Tags") + +

+ +### Decoding Options + +| DecOptions.TimeTag | Description | +| ------------------ | ----------- | +| DecTagIgnored (default) | Tag numbers are ignored (if present) for time values. | +| DecTagOptional | Tag numbers are only checked for validity if present for time values. | +| DecTagRequired | Tag numbers must be provided for time values except for CBOR Null and CBOR Undefined. | + +The following CBOR time values are decoded as Go's "zero time instant": + +* CBOR Null +* CBOR Undefined +* CBOR floating-point NaN +* CBOR floating-point Infinity + +Go's `time` package provides `IsZero` function, which reports whether t represents "zero time instant" +(January 1, year 1, 00:00:00 UTC). + +
+ +| DecOptions.DupMapKey | Description | +| -------------------- | ----------- | +| DupMapKeyQuiet (default) | turns off detection of duplicate map keys. It uses a "keep fastest" method by choosing either "keep first" or "keep last" depending on the Go data type. | +| DupMapKeyEnforcedAPF | enforces detection and rejection of duplidate map keys. Decoding stops immediately and returns `DupMapKeyError` when the first duplicate key is detected. The error includes the duplicate map key and the index number. | + +`DupMapKeyEnforcedAPF` uses "Allow Partial Fill" so the destination map or struct can contain some decoded values at the time of error. Users can respond to the `DupMapKeyError` by discarding the partially filled result if that's required by their protocol. + +
+ +| DecOptions.IndefLength | Description | +| ---------------------- | ----------- | +|IndefLengthAllowed (default) | allow indefinite length data | +|IndefLengthForbidden | forbid indefinite length data | + +
+ +| DecOptions.TagsMd | Description | +| ----------------- | ----------- | +|TagsAllowed (default) | allow CBOR tags (major type 6) | +|TagsForbidden | forbid CBOR tags (major type 6) | + +
+ +| DecOptions.MaxNestedLevels | Description | +| -------------------------- | ----------- | +| 32 (default) | allowed setting is [4, 256] | + +
+ +| DecOptions.MaxArrayElements | Description | +| --------------------------- | ----------- | +| 131072 (default) | allowed setting is [16, 2147483647] | + +
+ +| DecOptions.MaxMapPairs | Description | +| ---------------------- | ----------- | +| 131072 (default) | allowed setting is [16, 2147483647] | + +### Encoding Options + +__Integers always encode to the shortest form that preserves value__. Encoding of other data types and map key sort order are determined by encoding options. + +These functions are provided to create and return a modifiable EncOptions struct with predefined settings. + +| Predefined EncOptions | Description | +| --------------------- | ----------- | +| CanonicalEncOptions() |[Canonical CBOR (RFC 7049 Section 3.9)](https://tools.ietf.org/html/rfc7049#section-3.9). | +| CTAP2EncOptions() |[CTAP2 Canonical CBOR (FIDO2 CTAP2)](https://fidoalliance.org/specs/fido-v2.0-id-20180227/fido-client-to-authenticator-protocol-v2.0-id-20180227.html#ctap2-canonical-cbor-encoding-form). | +| PreferredUnsortedEncOptions() |Unsorted, encode float64->float32->float16 when values fit, NaN values encoded as float16 0x7e00. | +| CoreDetEncOptions() |PreferredUnsortedEncOptions() + map keys are sorted bytewise lexicographic. | + +🌱 CoreDetEncOptions() and PreferredUnsortedEncOptions() are subject to change until the draft RFC they used is approved by IETF. + +
+ +| EncOptions.Sort | Description | +| --------------- | ----------- | +| SortNone (default) |No sorting for map keys. | +| SortLengthFirst |Length-first map key ordering. | +| SortBytewiseLexical |Bytewise lexicographic map key ordering | +| SortCanonical |(alias) Same as SortLengthFirst [(RFC 7049 Section 3.9)](https://tools.ietf.org/html/rfc7049#section-3.9) | +| SortCTAP2 |(alias) Same as SortBytewiseLexical [(CTAP2 Canonical CBOR)](https://fidoalliance.org/specs/fido-v2.0-id-20180227/fido-client-to-authenticator-protocol-v2.0-id-20180227.html#ctap2-canonical-cbor-encoding-form). | +| SortCoreDeterministic |(alias) Same as SortBytewiseLexical. | + +
+ +| EncOptions.Time | Description | +| --------------- | ----------- | +| TimeUnix (default) | (seconds) Encode as integer. | +| TimeUnixMicro | (microseconds) Encode as floating-point. ShortestFloat option determines size. | +| TimeUnixDynamic | (seconds or microseconds) Encode as integer if time doesn't have fractional seconds, otherwise encode as floating-point rounded to microseconds. | +| TimeRFC3339 | (seconds) Encode as RFC 3339 formatted string. | +| TimeRFC3339Nano | (nanoseconds) Encode as RFC3339 formatted string. | + +
+ +| EncOptions.TimeTag | Description | +| ------------------ | ----------- | +| EncTagNone (default) | Tag number will not be encoded for time values. | +| EncTagRequired | Tag number (0 or 1) will be encoded unless time value is undefined/zero-instant. | + +__Undefined Time Values__ + +By default, undefined (zero instant) time values will encode as CBOR Null without tag number for both EncTagNone and EncTagRequired. Although CBOR Undefined might be technically more correct for EncTagRequired, CBOR Undefined might not be supported by other generic decoders and it isn't supported by JSON. + +Go's `time` package provides `IsZero` function, which reports whether t represents the zero time instant, January 1, year 1, 00:00:00 UTC. + +
+ +__Floating-Point Options__ + +Encoder has 3 types of options for floating-point data: ShortestFloatMode, InfConvertMode, and NaNConvertMode. + +| EncOptions.ShortestFloat | Description | +| ------------------------ | ----------- | +| ShortestFloatNone (default) | No size conversion. Encode float32 and float64 to CBOR floating-point of same bit-size. | +| ShortestFloat16 | Encode float64 -> float32 -> float16 ([IEEE 754 binary16](https://en.wikipedia.org/wiki/Half-precision_floating-point_format)) when values fit. | + +Conversions for infinity and NaN use InfConvert and NaNConvert settings. + +| EncOptions.InfConvert | Description | +| --------------------- | ----------- | +| InfConvertFloat16 (default) | Convert +- infinity to float16 since they always preserve value (recommended) | +| InfConvertNone |Don't convert +- infinity to other representations -- used by CTAP2 Canonical CBOR | + +
+ +| EncOptions.NaNConvert | Description | +| --------------------- | ----------- | +| NaNConvert7e00 (default) | Encode to 0xf97e00 (CBOR float16 = 0x7e00) -- used by RFC 7049 Canonical CBOR. | +| NaNConvertNone | Don't convert NaN to other representations -- used by CTAP2 Canonical CBOR. | +| NaNConvertQuiet | Force quiet bit = 1 and use shortest form that preserves NaN payload. | +| NaNConvertPreserveSignal | Convert to smallest form that preserves value (quit bit unmodified and NaN payload preserved). | + +
+ +| EncOptions.IndefLength | Description | +| ---------------------- | ----------- | +|IndefLengthAllowed (default) | allow indefinite length data | +|IndefLengthForbidden | forbid indefinite length data | + +
+ +| EncOptions.TagsMd | Description | +| ----------------- | ----------- | +|TagsAllowed (default) | allow CBOR tags (major type 6) | +|TagsForbidden | forbid CBOR tags (major type 6) | + + +### Tag Options + +TagOptions specifies how encoder and decoder handle tag number registered with TagSet. + +| TagOptions.DecTag | Description | +| ------------------ | ----------- | +| DecTagIgnored (default) | Tag numbers are ignored (if present). | +| DecTagOptional | Tag numbers are only checked for validity if present. | +| DecTagRequired | Tag numbers must be provided except for CBOR Null and CBOR Undefined. | + +
+ +| TagOptions.EncTag | Description | +| ------------------ | ----------- | +| EncTagNone (default) | Tag number will not be encoded. | +| EncTagRequired | Tag number will be encoded. | + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Usage +🛡️ Use Go's `io.LimitReader` to limit size when decoding very large or indefinite size data. + +Functions with identical signatures to encoding/json include: +`Marshal`, `Unmarshal`, `NewEncoder`, `NewDecoder`, `(*Encoder).Encode`, `(*Decoder).Decode`. + +__Default Mode__ + +If default options are acceptable, package level functions can be used for encoding and decoding. + +```go +b, err := cbor.Marshal(v) // encode v to []byte b + +err := cbor.Unmarshal(b, &v) // decode []byte b to v + +encoder := cbor.NewEncoder(w) // create encoder with io.Writer w + +decoder := cbor.NewDecoder(r) // create decoder with io.Reader r +``` + +__Modes__ + +If you need to use options or CBOR tags, then you'll want to create a mode. + +"Mode" means defined way of encoding or decoding -- it links the standard API to your CBOR options and CBOR tags. This way, you don't pass around options and the API remains identical to `encoding/json`. + +EncMode and DecMode are interfaces created from EncOptions or DecOptions structs. +For example, `em, err := cbor.EncOptions{...}.EncMode()` or `em, err := cbor.CanonicalEncOptions().EncMode()`. + +EncMode and DecMode use immutable options so their behavior won't accidentally change at runtime. Modes are reusable, safe for concurrent use, and allow fast parallelism. + +__Creating and Using Encoding Modes__ + +EncMode is an interface ([API](#api)) created from EncOptions struct. EncMode uses immutable options after being created and is safe for concurrent use. For best performance, EncMode should be reused. + +```go +// Create EncOptions using either struct literal or a function. +opts := cbor.CanonicalEncOptions() + +// If needed, modify opts. For example: opts.Time = cbor.TimeUnix + +// Create reusable EncMode interface with immutable options, safe for concurrent use. +em, err := opts.EncMode() + +// Use EncMode like encoding/json, with same function signatures. +b, err := em.Marshal(v) // encode v to []byte b + +encoder := em.NewEncoder(w) // create encoder with io.Writer w +err := encoder.Encode(v) // encode v to io.Writer w +``` + +__Struct Tags (keyasint, toarray, omitempty)__ + +The `keyasint`, `toarray`, and `omitempty` struct tags make it easy to use compact CBOR message formats. Internet standards often use CBOR arrays and CBOR maps with int keys to save space. + +
+ +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_struct_tags_api.svg?sanitize=1 "CBOR API and Struct Tags") + +
+ +__Decoding CWT (CBOR Web Token)__ using `keyasint` and `toarray` struct tags: + +```go +// Signed CWT is defined in RFC 8392 +type signedCWT struct { + _ struct{} `cbor:",toarray"` + Protected []byte + Unprotected coseHeader + Payload []byte + Signature []byte +} + +// Part of COSE header definition +type coseHeader struct { + Alg int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` +} + +// data is []byte containing signed CWT + +var v signedCWT +if err := cbor.Unmarshal(data, &v); err != nil { + return err +} +``` + +__Encoding CWT (CBOR Web Token)__ using `keyasint` and `toarray` struct tags: + +```go +// Use signedCWT struct defined in "Decoding CWT" example. + +var v signedCWT +... +if data, err := cbor.Marshal(v); err != nil { + return err +} +``` + +__Encoding and Decoding CWT (CBOR Web Token) with CBOR Tags__ + +```go +// Use signedCWT struct defined in "Decoding CWT" example. + +// Create TagSet (safe for concurrency). +tags := cbor.NewTagSet() +// Register tag COSE_Sign1 18 with signedCWT type. +tags.Add( + cbor.TagOptions{EncTag: cbor.EncTagRequired, DecTag: cbor.DecTagRequired}, + reflect.TypeOf(signedCWT{}), + 18) + +// Create DecMode with immutable tags. +dm, _ := cbor.DecOptions{}.DecModeWithTags(tags) + +// Unmarshal to signedCWT with tag support. +var v signedCWT +if err := dm.Unmarshal(data, &v); err != nil { + return err +} + +// Create EncMode with immutable tags. +em, _ := cbor.EncOptions{}.EncModeWithTags(tags) + +// Marshal signedCWT with tag number. +if data, err := cbor.Marshal(v); err != nil { + return err +} +``` + +For more examples, see [examples_test.go](example_test.go). + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Comparisons + +Comparisons are between this newer library and a well-known library that had 1,000+ stars before this library was created. Default build settings for each library were used for all comparisons. + +__This library is safer__. Small malicious CBOR messages are rejected quickly before they exhaust system resources. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_security_table.svg?sanitize=1 "CBOR Security Comparison") + +__This library is smaller__. Programs like senmlCat can be 4 MB smaller by switching to this library. Programs using more complex CBOR data types can be 9.2 MB smaller. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_size_comparison.png "CBOR library and program size comparison chart") + +__This library is faster__ for encoding and decoding CBOR Web Token (CWT). However, speed is only one factor and it can vary depending on data types and sizes. Unlike the other library, this one doesn't use Go's ```unsafe``` package or code gen. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_speed_comparison.png "CBOR library speed comparison chart") + +__This library uses less memory__ for encoding and decoding CBOR Web Token (CWT) using test data from RFC 8392 A.1. + +![alt text](https://github.com/fxamacker/images/raw/master/cbor/v2.2.0/cbor_memory_table.svg?sanitize=1 "CBOR Memory Comparison") + +Doing your own comparisons is highly recommended. Use your most common message sizes and data types. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Benchmarks + +Go structs are faster than maps with string keys: + +* decoding into struct is >28% faster than decoding into map. +* encoding struct is >35% faster than encoding map. + +Go structs with `keyasint` struct tag are faster than maps with integer keys: + +* decoding into struct is >28% faster than decoding into map. +* encoding struct is >34% faster than encoding map. + +Go structs with `toarray` struct tag are faster than slice: + +* decoding into struct is >15% faster than decoding into slice. +* encoding struct is >12% faster than encoding slice. + +Doing your own benchmarks is highly recommended. Use your most common message sizes and data types. + +See [Benchmarks for fxamacker/cbor](CBOR_BENCHMARKS.md). + +## Fuzzing and Code Coverage + +__Over 375 tests__ must pass on 4 architectures before tagging a release. They include all RFC 7049 examples, bugs found by fuzzing, maliciously crafted CBOR data, and over 87 tests with malformed data. + +__Code coverage__ must not fall below 95% when tagging a release. Code coverage is 98.6% (`go test -cover`) for cbor v2.2 which is among the highest for libraries (in Go) of this type. + +__Coverage-guided fuzzing__ must pass 250+ million execs before tagging a release. Fuzzing uses [fxamacker/cbor-fuzz](https://github.com/fxamacker/cbor-fuzz). Default corpus has: + +* 2 files related to WebAuthn (FIDO U2F key). +* 3 files with custom struct. +* 9 files with [CWT examples (RFC 8392 Appendix A)](https://tools.ietf.org/html/rfc8392#appendix-A). +* 17 files with [COSE examples (RFC 8152 Appendix B & C)](https://github.com/cose-wg/Examples/tree/master/RFC8152). +* 81 files with [CBOR examples (RFC 7049 Appendix A) ](https://tools.ietf.org/html/rfc7049#appendix-A). It excludes 1 errata first reported in [issue #46](https://github.com/fxamacker/cbor/issues/46). + +Over 1,100 files (corpus) are used for fuzzing because it includes fuzz-generated corpus. + +To prevent excessive delays, fuzzing is not restarted for a release if changes are limited to docs and comments. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) + +## Versions and API Changes +This project uses [Semantic Versioning](https://semver.org), so the API is always backwards compatible unless the major version number changes. + +These functions have signatures identical to encoding/json and they will likely never change even after major new releases: +`Marshal`, `Unmarshal`, `NewEncoder`, `NewDecoder`, `(*Encoder).Encode`, and `(*Decoder).Decode`. + +Newly added API documented as "subject to change" are excluded from SemVer. + +Newly added API in the master branch that has never been release tagged are excluded from SemVer. + +## Code of Conduct +This project has adopted the [Contributor Covenant Code of Conduct](CODE_OF_CONDUCT.md). Contact [faye.github@gmail.com](mailto:faye.github@gmail.com) with any questions or comments. + +## Contributing +Please refer to [How to Contribute](CONTRIBUTING.md). + +## Security Policy +Security fixes are provided for the latest released version of fxamacker/cbor. + +For the full text of the Security Policy, see [SECURITY.md](SECURITY.md). + +## Disclaimers +Phrases like "no crashes", "doesn't crash", and "is secure" mean there are no known crash bugs in the latest version based on results of unit tests and coverage-guided fuzzing. They don't imply the software is 100% bug-free or 100% invulnerable to all known and unknown attacks. + +Please read the license for additional disclaimers and terms. + +## Special Thanks + +__Making this library better__ + +* Stefan Tatschner for using this library in [sep](https://git.sr.ht/~rumpelsepp/sep), being the 1st to discover my CBOR library, requesting time.Time in issue #1, and submitting this library in a [PR to cbor.io](https://github.com/cbor/cbor.github.io/pull/56) on Aug 12, 2019. +* Yawning Angel for using this library to [oasis-core](https://github.com/oasislabs/oasis-core), and requesting BinaryMarshaler in issue #5. +* Jernej Kos for requesting RawMessage in issue #11 and offering feedback on v2.1 API for CBOR tags. +* ZenGround0 for using this library in [go-filecoin](https://github.com/filecoin-project/go-filecoin), filing "toarray" bug in issue #129, and requesting +CBOR BSTR <--> Go array in #133. +* Keith Randall for [fixing Go bugs and providing workarounds](https://github.com/golang/go/issues/36400) so we don't have to wait for new versions of Go. + +__Help clarifying CBOR RFC 7049 or 7049bis__ + +* Carsten Bormann for RFC 7049 (CBOR), adding this library to cbor.io, his fast confirmation to my RFC 7049 errata, approving my pull request to 7049bis, and his patience when I misread a line in 7049bis. +* Laurence Lundblade for his help on the IETF mailing list for 7049bis and for pointing out on a CBORbis issue that CBOR Undefined might be problematic translating to JSON. +* Jeffrey Yasskin for his help on the IETF mailing list for 7049bis. + +__Words of encouragement and support__ + +* Jakob Borg for his words of encouragement about this library at Go Forum. This is especially appreciated in the early stages when there's a lot of rough edges. + + +## License +Copyright © 2019-present [Faye Amacker](https://github.com/fxamacker). + +fxamacker/cbor is licensed under the MIT License. See [LICENSE](LICENSE) for the full license text. + +
+ +⚓ [Quick Start](#quick-start) • [Status](#current-status) • [Design Goals](#design-goals) • [Features](#features) • [Standards](#standards) • [API](#api) • [Options](#options) • [Usage](#usage) • [Fuzzing](#fuzzing-and-code-coverage) • [License](#license) diff --git a/vendor/github.com/fxamacker/cbor/SECURITY.md b/vendor/github.com/fxamacker/cbor/SECURITY.md new file mode 100644 index 0000000..9c05146 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/SECURITY.md @@ -0,0 +1,7 @@ +# Security Policy + +Security fixes are provided for the latest released version of fxamacker/cbor. + +If the security vulnerability is already known to the public, then you can open an issue as a bug report. + +To report security vulnerabilities not yet known to the public, please email faye.github@gmail.com and allow time for the problem to be resolved before reporting it to the public. diff --git a/vendor/github.com/fxamacker/cbor/bench_test.go b/vendor/github.com/fxamacker/cbor/bench_test.go new file mode 100644 index 0000000..cd36ee4 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/bench_test.go @@ -0,0 +1,674 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "bytes" + "io/ioutil" + "reflect" + "testing" +) + +const rounds = 100 + +type claims struct { + Iss string `cbor:"1,keyasint"` + Sub string `cbor:"2,keyasint"` + Aud string `cbor:"3,keyasint"` + Exp int `cbor:"4,keyasint"` + Nbf int `cbor:"5,keyasint"` + Iat int `cbor:"6,keyasint"` + Cti []byte `cbor:"7,keyasint"` +} + +type coseHeader struct { + Alg int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` +} + +type macedCOSE struct { + _ struct{} `cbor:",toarray"` + Protected []byte + Unprotected coseHeader + Payload []byte + Tag []byte +} + +type coseKey struct { + Kty int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"2,keyasint,omitempty"` + Alg int `cbor:"3,keyasint,omitempty"` + KeyOpts int `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` + CrvOrNOrK RawMessage `cbor:"-1,keyasint,omitempty"` // K for symmetric keys, Crv for elliptic curve keys, N for RSA modulus + XOrE RawMessage `cbor:"-2,keyasint,omitempty"` // X for curve x-coordinate, E for RSA public exponent + Y RawMessage `cbor:"-3,keyasint,omitempty"` // Y for curve y-cooridate + D []byte `cbor:"-4,keyasint,omitempty"` +} + +type attestationObject struct { + AuthnData []byte `cbor:"authData"` + Fmt string `cbor:"fmt"` + AttStmt RawMessage `cbor:"attStmt"` +} + +type SenMLRecord struct { + BaseName string `cbor:"-2,keyasint,omitempty"` + BaseTime float64 `cbor:"-3,keyasint,omitempty"` + BaseUnit string `cbor:"-4,keyasint,omitempty"` + BaseValue float64 `cbor:"-5,keyasint,omitempty"` + BaseSum float64 `cbor:"-6,keyasint,omitempty"` + BaseVersion int `cbor:"-1,keyasint,omitempty"` + Name string `cbor:"0,keyasint,omitempty"` + Unit string `cbor:"1,keyasint,omitempty"` + Time float64 `cbor:"6,keyasint,omitempty"` + UpdateTime float64 `cbor:"7,keyasint,omitempty"` + Value float64 `cbor:"2,keyasint,omitempty"` + ValueS string `cbor:"3,keyasint,omitempty"` + ValueB bool `cbor:"4,keyasint,omitempty"` + ValueD string `cbor:"8,keyasint,omitempty"` + Sum float64 `cbor:"5,keyasint,omitempty"` +} + +type T1 struct { + T bool + UI uint + I int + F float64 + B []byte + S string + Slci []int + Mss map[string]string +} + +type T2 struct { + T bool `cbor:"1,keyasint"` + UI uint `cbor:"2,keyasint"` + I int `cbor:"3,keyasint"` + F float64 `cbor:"4,keyasint"` + B []byte `cbor:"5,keyasint"` + S string `cbor:"6,keyasint"` + Slci []int `cbor:"7,keyasint"` + Mss map[string]string `cbor:"8,keyasint"` +} + +type T3 struct { + _ struct{} `cbor:",toarray"` + T bool + UI uint + I int + F float64 + B []byte + S string + Slci []int + Mss map[string]string +} + +var decodeBenchmarks = []struct { + name string + cborData []byte + decodeToTypes []reflect.Type +}{ + {"bool", hexDecode("f5"), []reflect.Type{typeIntf, typeBool}}, // true + {"positive int", hexDecode("1bffffffffffffffff"), []reflect.Type{typeIntf, typeUint64}}, // uint64(18446744073709551615) + {"negative int", hexDecode("3903e7"), []reflect.Type{typeIntf, typeInt64}}, // int64(-1000) + {"float", hexDecode("fbc010666666666666"), []reflect.Type{typeIntf, typeFloat64}}, // float64(-4.1) + {"bytes", hexDecode("581a0102030405060708090a0b0c0d0e0f101112131415161718191a"), []reflect.Type{typeIntf, typeByteSlice}}, // []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26} + {"bytes indef len", hexDecode("5f410141024103410441054106410741084109410a410b410c410d410e410f4110411141124113411441154116411741184119411aff"), []reflect.Type{typeIntf, typeByteSlice}}, // []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26} + {"text", hexDecode("782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f67"), []reflect.Type{typeIntf, typeString}}, // "The quick brown fox jumps over the lazy dog" + {"text indef len", hexDecode("7f61546168616561206171617561696163616b612061626172616f6177616e61206166616f61786120616a6175616d617061736120616f61766165617261206174616861656120616c6161617a617961206164616f6167ff"), []reflect.Type{typeIntf, typeString}}, // "The quick brown fox jumps over the lazy dog" + {"array", hexDecode("981a0102030405060708090a0b0c0d0e0f101112131415161718181819181a"), []reflect.Type{typeIntf, typeIntSlice}}, // []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26} + {"array indef len", hexDecode("9f0102030405060708090a0b0c0d0e0f101112131415161718181819181aff"), []reflect.Type{typeIntf, typeIntSlice}}, // []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26} + {"map", hexDecode("ad616161416162614261636143616461446165614561666146616761476168614861696149616a614a616c614c616d614d616e614e"), []reflect.Type{typeIntf, typeMapStringIntf, typeMapStringString}}, // map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}} + {"map indef len", hexDecode("bf616161416162614261636143616461446165614561666146616761476168614861696149616a614a616b614b616c614c616d614d616e614eff"), []reflect.Type{typeIntf, typeMapStringIntf, typeMapStringString}}, // map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}} +} + +var encodeBenchmarks = []struct { + name string + cborData []byte + values []interface{} +}{ + {"bool", hexDecode("f5"), []interface{}{true}}, + {"positive int", hexDecode("1bffffffffffffffff"), []interface{}{uint64(18446744073709551615)}}, + {"negative int", hexDecode("3903e7"), []interface{}{int64(-1000)}}, + {"float", hexDecode("fbc010666666666666"), []interface{}{float64(-4.1)}}, + {"bytes", hexDecode("581a0102030405060708090a0b0c0d0e0f101112131415161718191a"), []interface{}{[]byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}}}, + {"text", hexDecode("782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f67"), []interface{}{"The quick brown fox jumps over the lazy dog"}}, + {"array", hexDecode("981a0102030405060708090a0b0c0d0e0f101112131415161718181819181a"), []interface{}{[]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}}}, + {"map", hexDecode("ad616161416162614261636143616461446165614561666146616761476168614861696149616a614a616c614c616d614d616e614e"), []interface{}{map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}}}, +} + +func BenchmarkUnmarshal(b *testing.B) { + for _, bm := range decodeBenchmarks { + for _, t := range bm.decodeToTypes { + name := "CBOR " + bm.name + " to Go " + t.String() + if t.Kind() == reflect.Struct { + name = "CBOR " + bm.name + " to Go " + t.Kind().String() + } + b.Run(name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + vPtr := reflect.New(t).Interface() + if err := Unmarshal(bm.cborData, vPtr); err != nil { + b.Fatal("Unmarshal:", err) + } + } + }) + } + } + var moreBenchmarks = []struct { + name string + cborData []byte + decodeToType reflect.Type + }{ + // Unmarshal CBOR map with string key to map[string]interface{}. + { + "CBOR map to Go map[string]interface{}", + hexDecode("a86154f56255691bffffffffffffffff61493903e76146fbc0106666666666666142581a0102030405060708090a0b0c0d0e0f101112131415161718191a6153782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f6764536c6369981a0102030405060708090a0b0c0d0e0f101112131415161718181819181a634d7373ad6163614361656145616661466167614761686148616e614e616d614d61616141616261426164614461696149616a614a616c614c"), + reflect.TypeOf(map[string]interface{}{}), + }, + // Unmarshal CBOR map with string key to struct. + { + "CBOR map to Go struct", + hexDecode("a86154f56255491bffffffffffffffff61493903e76146fbc0106666666666666142581a0102030405060708090a0b0c0d0e0f101112131415161718191a6153782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f6764536c6369981a0102030405060708090a0b0c0d0e0f101112131415161718181819181a634d7373ad6163614361656145616661466167614761686148616e614e616d614d61616141616261426164614461696149616a614a616c614c"), + reflect.TypeOf(T1{}), + }, + // Unmarshal CBOR map with integer key, such as COSE Key and SenML, to map[int]interface{}. + { + "CBOR map to Go map[int]interface{}", + hexDecode("a801f5021bffffffffffffffff033903e704fbc01066666666666605581a0102030405060708090a0b0c0d0e0f101112131415161718191a06782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f6707981a0102030405060708090a0b0c0d0e0f101112131415161718181819181a08ad61646144616661466167614761686148616d614d616e614e6161614161626142616361436165614561696149616a614a616c614c"), + reflect.TypeOf(map[int]interface{}{}), + }, + // Unmarshal CBOR map with integer key, such as COSE Key and SenML, to struct. + { + "CBOR map to Go struct keyasint", + hexDecode("a801f5021bffffffffffffffff033903e704fbc01066666666666605581a0102030405060708090a0b0c0d0e0f101112131415161718191a06782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f6707981a0102030405060708090a0b0c0d0e0f101112131415161718181819181a08ad61646144616661466167614761686148616d614d616e614e6161614161626142616361436165614561696149616a614a616c614c"), + reflect.TypeOf(T2{}), + }, + // Unmarshal CBOR array of known sequence of data types, such as signed/maced/encrypted CWT, to []interface{}. + { + "CBOR array to Go []interface{}", + hexDecode("88f51bffffffffffffffff3903e7fbc010666666666666581a0102030405060708090a0b0c0d0e0f101112131415161718191a782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f67981a0102030405060708090a0b0c0d0e0f101112131415161718181819181aad616261426163614361646144616561456166614661696149616e614e616161416167614761686148616a614a616c614c616d614d"), + reflect.TypeOf([]interface{}{}), + }, + // Unmarshal CBOR array of known sequence of data types, such as signed/maced/encrypted CWT, to struct. + { + "CBOR array to Go struct toarray", + hexDecode("88f51bffffffffffffffff3903e7fbc010666666666666581a0102030405060708090a0b0c0d0e0f101112131415161718191a782b54686520717569636b2062726f776e20666f78206a756d7073206f76657220746865206c617a7920646f67981a0102030405060708090a0b0c0d0e0f101112131415161718181819181aad616261426163614361646144616561456166614661696149616e614e616161416167614761686148616a614a616c614c616d614d"), + reflect.TypeOf(T3{}), + }, + } + for _, bm := range moreBenchmarks { + b.Run(bm.name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + vPtr := reflect.New(bm.decodeToType).Interface() + if err := Unmarshal(bm.cborData, vPtr); err != nil { + b.Fatal("Unmarshal:", err) + } + } + }) + } +} + +func BenchmarkDecode(b *testing.B) { + for _, bm := range decodeBenchmarks { + for _, t := range bm.decodeToTypes { + name := "CBOR " + bm.name + " to Go " + t.String() + if t.Kind() == reflect.Struct { + name = "CBOR " + bm.name + " to Go " + t.Kind().String() + } + buf := bytes.NewReader(bm.cborData) + decoder := NewDecoder(buf) + b.Run(name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + vPtr := reflect.New(t).Interface() + if err := decoder.Decode(vPtr); err != nil { + b.Fatal("Decode:", err) + } + buf.Seek(0, 0) //nolint:errcheck + } + }) + } + } +} + +func BenchmarkDecodeStream(b *testing.B) { + var cborData []byte + for _, bm := range decodeBenchmarks { + for i := 0; i < len(bm.decodeToTypes); i++ { + cborData = append(cborData, bm.cborData...) + } + } + + b.ResetTimer() + for i := 0; i < b.N; i++ { + buf := bytes.NewReader(cborData) + decoder := NewDecoder(buf) + for j := 0; j < rounds; j++ { + for _, bm := range decodeBenchmarks { + for _, t := range bm.decodeToTypes { + vPtr := reflect.New(t).Interface() + if err := decoder.Decode(vPtr); err != nil { + b.Fatal("Decode:", err) + } + } + } + buf.Seek(0, 0) //nolint:errcheck + } + } +} + +func BenchmarkMarshal(b *testing.B) { + for _, bm := range encodeBenchmarks { + for _, v := range bm.values { + name := "Go " + reflect.TypeOf(v).String() + " to CBOR " + bm.name + if reflect.TypeOf(v).Kind() == reflect.Struct { + name = "Go " + reflect.TypeOf(v).Kind().String() + " to CBOR " + bm.name + } + b.Run(name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + if _, err := Marshal(v); err != nil { + b.Fatal("Marshal:", err) + } + } + }) + } + } + // Marshal map[string]interface{} to CBOR map + m1 := map[string]interface{}{ //nolint:dupl + "T": true, + "UI": uint(18446744073709551615), + "I": -1000, + "F": -4.1, + "B": []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + "S": "The quick brown fox jumps over the lazy dog", + "Slci": []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + "Mss": map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, + } + // Marshal struct to CBOR map + v1 := T1{ //nolint:dupl + T: true, + UI: 18446744073709551615, + I: -1000, + F: -4.1, + B: []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + S: "The quick brown fox jumps over the lazy dog", + Slci: []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + Mss: map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, + } + // Marshal map[int]interface{} to CBOR map + m2 := map[int]interface{}{ //nolint:dupl + 1: true, + 2: uint(18446744073709551615), + 3: -1000, + 4: -4.1, + 5: []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + 6: "The quick brown fox jumps over the lazy dog", + 7: []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + 8: map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, + } + // Marshal struct keyasint, such as COSE Key and SenML + v2 := T2{ //nolint:dupl + T: true, + UI: 18446744073709551615, + I: -1000, + F: -4.1, + B: []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + S: "The quick brown fox jumps over the lazy dog", + Slci: []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + Mss: map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, + } + // Marshal []interface to CBOR array. + slc := []interface{}{ + true, + uint(18446744073709551615), + -1000, + -4.1, + []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + "The quick brown fox jumps over the lazy dog", + []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, + } + // Marshal struct toarray to CBOR array, such as signed/maced/encrypted CWT. + v3 := T3{ //nolint:dupl + T: true, + UI: 18446744073709551615, + I: -1000, + F: -4.1, + B: []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + S: "The quick brown fox jumps over the lazy dog", + Slci: []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26}, + Mss: map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, + } + var moreBenchmarks = []struct { + name string + value interface{} + }{ + {"Go map[string]interface{} to CBOR map", m1}, + {"Go struct to CBOR map", v1}, + {"Go map[int]interface{} to CBOR map", m2}, + {"Go struct keyasint to CBOR map", v2}, + {"Go []interface{} to CBOR map", slc}, + {"Go struct toarray to CBOR array", v3}, + } + for _, bm := range moreBenchmarks { + b.Run(bm.name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + if _, err := Marshal(bm.value); err != nil { + b.Fatal("Marshal:", err) + } + } + }) + } +} + +func BenchmarkMarshalCanonical(b *testing.B) { + type strc struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + F string `cbor:"f"` + G string `cbor:"g"` + H string `cbor:"h"` + I string `cbor:"i"` + J string `cbor:"j"` + L string `cbor:"l"` + M string `cbor:"m"` + N string `cbor:"n"` + } + for _, bm := range []struct { + name string + cborData []byte + values []interface{} + }{ + {"map", hexDecode("ad616161416162614261636143616461446165614561666146616761476168614861696149616a614a616c614c616d614d616e614e"), []interface{}{map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E", "f": "F", "g": "G", "h": "H", "i": "I", "j": "J", "l": "L", "m": "M", "n": "N"}, strc{A: "A", B: "B", C: "C", D: "D", E: "E", F: "F", G: "G", H: "H", I: "I", J: "J", L: "L", M: "M", N: "N"}}}, + } { + for _, v := range bm.values { + name := "Go " + reflect.TypeOf(v).String() + " to CBOR " + bm.name + if reflect.TypeOf(v).Kind() == reflect.Struct { + name = "Go " + reflect.TypeOf(v).Kind().String() + " to CBOR " + bm.name + } + b.Run(name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + if _, err := Marshal(v); err != nil { + b.Fatal("Marshal:", err) + } + } + }) + // Canonical encoding + name = "Go " + reflect.TypeOf(v).String() + " to CBOR " + bm.name + " canonical" + if reflect.TypeOf(v).Kind() == reflect.Struct { + name = "Go " + reflect.TypeOf(v).Kind().String() + " to CBOR " + bm.name + " canonical" + } + em, _ := EncOptions{Sort: SortCanonical}.EncMode() + b.Run(name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + if _, err := em.Marshal(v); err != nil { + b.Fatal("Marshal:", err) + } + } + }) + } + } +} + +func BenchmarkEncode(b *testing.B) { + for _, bm := range encodeBenchmarks { + for _, v := range bm.values { + name := "Go " + reflect.TypeOf(v).String() + " to CBOR " + bm.name + if reflect.TypeOf(v).Kind() == reflect.Struct { + name = "Go " + reflect.TypeOf(v).Kind().String() + " to CBOR " + bm.name + } + b.Run(name, func(b *testing.B) { + encoder := NewEncoder(ioutil.Discard) + b.ResetTimer() + for i := 0; i < b.N; i++ { + if err := encoder.Encode(v); err != nil { + b.Fatal("Encode:", err) + } + } + }) + } + } +} + +func BenchmarkEncodeStream(b *testing.B) { + for i := 0; i < b.N; i++ { + encoder := NewEncoder(ioutil.Discard) + for i := 0; i < rounds; i++ { + for _, bm := range encodeBenchmarks { + for _, v := range bm.values { + if err := encoder.Encode(v); err != nil { + b.Fatal("Encode:", err) + } + } + } + } + } +} + +func BenchmarkUnmarshalCOSE(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.2 + testCases := []struct { + name string + cborData []byte + }{ + {"128-Bit Symmetric Key", hexDecode("a42050231f4c4d4d3051fdc2ec0a3851d5b3830104024c53796d6d6574726963313238030a")}, + {"256-Bit Symmetric Key", hexDecode("a4205820403697de87af64611c1d32a05dab0fe1fcb715a86ab435f1ec99192d795693880104024c53796d6d6574726963323536030a")}, + {"ECDSA P256 256-Bit Key", hexDecode("a72358206c1382765aec5358f117733d281c1c7bdc39884d04a45a1e6c67c858bc206c1922582060f7f1a780d8a783bfb7a2dd6b2796e8128dbbcef9d3d168db9529971a36e7b9215820143329cce7868e416927599cf65a34f3ce2ffda55a7eca69ed8919a394d42f0f2001010202524173796d6d657472696345434453413235360326")}, + } + for _, tc := range testCases { + b.Run(tc.name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + var v coseKey + if err := Unmarshal(tc.cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + } + }) + } +} + +func BenchmarkMarshalCOSE(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.2 + testCases := []struct { + name string + cborData []byte + }{ + {"128-Bit Symmetric Key", hexDecode("a42050231f4c4d4d3051fdc2ec0a3851d5b3830104024c53796d6d6574726963313238030a")}, + {"256-Bit Symmetric Key", hexDecode("a4205820403697de87af64611c1d32a05dab0fe1fcb715a86ab435f1ec99192d795693880104024c53796d6d6574726963323536030a")}, + {"ECDSA P256 256-Bit Key", hexDecode("a72358206c1382765aec5358f117733d281c1c7bdc39884d04a45a1e6c67c858bc206c1922582060f7f1a780d8a783bfb7a2dd6b2796e8128dbbcef9d3d168db9529971a36e7b9215820143329cce7868e416927599cf65a34f3ce2ffda55a7eca69ed8919a394d42f0f2001010202524173796d6d657472696345434453413235360326")}, + } + for _, tc := range testCases { + var v coseKey + if err := Unmarshal(tc.cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + b.Run(tc.name, func(b *testing.B) { + for i := 0; i < b.N; i++ { + if _, err := Marshal(v); err != nil { + b.Fatal("Marshal:", err) + } + } + }) + } +} + +func BenchmarkUnmarshalCWTClaims(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.1 + cborData := hexDecode("a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b71") + for i := 0; i < b.N; i++ { + var v claims + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkUnmarshalCWTClaimsWithDupMapKeyOpt(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.1 + cborData := hexDecode("a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b71") + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + for i := 0; i < b.N; i++ { + var v claims + if err := dm.Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkMarshalCWTClaims(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.1 + cborData := hexDecode("a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b71") + var v claims + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + for i := 0; i < b.N; i++ { + if _, err := Marshal(v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkUnmarshalSenML(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8428#section-6 + cborData := hexDecode("87a721781b75726e3a6465763a6f773a3130653230373361303130383030363a22fb41d303a15b00106223614120050067766f6c7461676501615602fb405e066666666666a3006763757272656e74062402fb3ff3333333333333a3006763757272656e74062302fb3ff4cccccccccccda3006763757272656e74062202fb3ff6666666666666a3006763757272656e74062102f93e00a3006763757272656e74062002fb3ff999999999999aa3006763757272656e74060002fb3ffb333333333333") + for i := 0; i < b.N; i++ { + var v []SenMLRecord + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkMarshalSenML(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8428#section-6 + cborData := hexDecode("87a721781b75726e3a6465763a6f773a3130653230373361303130383030363a22fb41d303a15b00106223614120050067766f6c7461676501615602fb405e066666666666a3006763757272656e74062402fb3ff3333333333333a3006763757272656e74062302fb3ff4cccccccccccda3006763757272656e74062202fb3ff6666666666666a3006763757272656e74062102f93e00a3006763757272656e74062002fb3ff999999999999aa3006763757272656e74060002fb3ffb333333333333") + var v []SenMLRecord + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + for i := 0; i < b.N; i++ { + if _, err := Marshal(v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkMarshalSenMLShortestFloat16(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8428#section-6 + cborData := hexDecode("87a721781b75726e3a6465763a6f773a3130653230373361303130383030363a22fb41d303a15b00106223614120050067766f6c7461676501615602fb405e066666666666a3006763757272656e74062402fb3ff3333333333333a3006763757272656e74062302fb3ff4cccccccccccda3006763757272656e74062202fb3ff6666666666666a3006763757272656e74062102f93e00a3006763757272656e74062002fb3ff999999999999aa3006763757272656e74060002fb3ffb333333333333") + var v []SenMLRecord + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + em, _ := EncOptions{ShortestFloat: ShortestFloat16}.EncMode() + for i := 0; i < b.N; i++ { + if _, err := em.Marshal(v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkUnmarshalWebAuthn(b *testing.B) { + // Data generated from Yubico security key + cborData := hexDecode("a363666d74686669646f2d7532666761747453746d74a26373696758483046022100e7ab373cfbd99fcd55fd59b0f6f17fef5b77a20ddec3db7f7e4d55174e366236022100828336b4822125fb56541fb14a8a273876acd339395ec2dad95cf41c1dd2a9ae637835638159024e3082024a30820132a0030201020204124a72fe300d06092a864886f70d01010b0500302e312c302a0603550403132359756269636f2055324620526f6f742043412053657269616c203435373230303633313020170d3134303830313030303030305a180f32303530303930343030303030305a302c312a302806035504030c2159756269636f205532462045452053657269616c203234393431343937323135383059301306072a8648ce3d020106082a8648ce3d030107034200043d8b1bbd2fcbf6086e107471601468484153c1c6d3b4b68a5e855e6e40757ee22bcd8988bf3befd7cdf21cb0bf5d7a150d844afe98103c6c6607d9faae287c02a33b3039302206092b0601040182c40a020415312e332e362e312e342e312e34313438322e312e313013060b2b0601040182e51c020101040403020520300d06092a864886f70d01010b05000382010100a14f1eea0076f6b8476a10a2be72e60d0271bb465b2dfbfc7c1bd12d351989917032631d795d097fa30a26a325634e85721bc2d01a86303f6bc075e5997319e122148b0496eec8d1f4f94cf4110de626c289443d1f0f5bbb239ca13e81d1d5aa9df5af8e36126475bfc23af06283157252762ff68879bcf0ef578d55d67f951b4f32b63c8aea5b0f99c67d7d814a7ff5a6f52df83e894a3a5d9c8b82e7f8bc8daf4c80175ff8972fda79333ec465d806eacc948f1bab22045a95558a48c20226dac003d41fbc9e05ea28a6bb5e10a49de060a0a4f6a2676a34d68c4abe8c61874355b9027e828ca9e064b002d62e8d8cf0744921753d35e3c87c5d5779453e7768617574684461746158c449960de5880e8c687434170f6476605b8fe4aeb9a28632c7995cf3ba831d976341000000000000000000000000000000000000000000408903fd7dfd2c9770e98cae0123b13a2c27828a106349bc6277140e7290b7e9eb7976aa3c04ed347027caf7da3a2fa76304751c02208acfc4e7fc6c7ebbc375c8a5010203262001215820ad7f7992c335b90d882b2802061b97a4fabca7e2ee3e7a51e728b8055e4eb9c7225820e0966ba7005987fece6f0e0e13447aa98cec248e4000a594b01b74c1cb1d40b3") + for i := 0; i < b.N; i++ { + var v attestationObject + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkMarshalWebAuthn(b *testing.B) { + // Data generated from Yubico security key + cborData := hexDecode("a363666d74686669646f2d7532666761747453746d74a26373696758483046022100e7ab373cfbd99fcd55fd59b0f6f17fef5b77a20ddec3db7f7e4d55174e366236022100828336b4822125fb56541fb14a8a273876acd339395ec2dad95cf41c1dd2a9ae637835638159024e3082024a30820132a0030201020204124a72fe300d06092a864886f70d01010b0500302e312c302a0603550403132359756269636f2055324620526f6f742043412053657269616c203435373230303633313020170d3134303830313030303030305a180f32303530303930343030303030305a302c312a302806035504030c2159756269636f205532462045452053657269616c203234393431343937323135383059301306072a8648ce3d020106082a8648ce3d030107034200043d8b1bbd2fcbf6086e107471601468484153c1c6d3b4b68a5e855e6e40757ee22bcd8988bf3befd7cdf21cb0bf5d7a150d844afe98103c6c6607d9faae287c02a33b3039302206092b0601040182c40a020415312e332e362e312e342e312e34313438322e312e313013060b2b0601040182e51c020101040403020520300d06092a864886f70d01010b05000382010100a14f1eea0076f6b8476a10a2be72e60d0271bb465b2dfbfc7c1bd12d351989917032631d795d097fa30a26a325634e85721bc2d01a86303f6bc075e5997319e122148b0496eec8d1f4f94cf4110de626c289443d1f0f5bbb239ca13e81d1d5aa9df5af8e36126475bfc23af06283157252762ff68879bcf0ef578d55d67f951b4f32b63c8aea5b0f99c67d7d814a7ff5a6f52df83e894a3a5d9c8b82e7f8bc8daf4c80175ff8972fda79333ec465d806eacc948f1bab22045a95558a48c20226dac003d41fbc9e05ea28a6bb5e10a49de060a0a4f6a2676a34d68c4abe8c61874355b9027e828ca9e064b002d62e8d8cf0744921753d35e3c87c5d5779453e7768617574684461746158c449960de5880e8c687434170f6476605b8fe4aeb9a28632c7995cf3ba831d976341000000000000000000000000000000000000000000408903fd7dfd2c9770e98cae0123b13a2c27828a106349bc6277140e7290b7e9eb7976aa3c04ed347027caf7da3a2fa76304751c02208acfc4e7fc6c7ebbc375c8a5010203262001215820ad7f7992c335b90d882b2802061b97a4fabca7e2ee3e7a51e728b8055e4eb9c7225820e0966ba7005987fece6f0e0e13447aa98cec248e4000a594b01b74c1cb1d40b3") + var v attestationObject + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + for i := 0; i < b.N; i++ { + if _, err := Marshal(v); err != nil { + b.Fatal("Marshal:", err) + } + } +} + +func BenchmarkUnmarshalCOSEMAC(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.4 + cborData := hexDecode("d83dd18443a10104a1044c53796d6d65747269633235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7148093101ef6d789200") + + for i := 0; i < b.N; i++ { + var v macedCOSE + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} + +func BenchmarkUnmarshalCOSEMACWithTag(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.4 + cborData := hexDecode("d83dd18443a10104a1044c53796d6d65747269633235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7148093101ef6d789200") + + // Register tag CBOR Web Token (CWT) 61 and COSE_Mac0 17 with macedCOSE type + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, reflect.TypeOf(macedCOSE{}), 61, 17); err != nil { + b.Fatal("TagSet.Add:", err) + } + + // Create DecMode with tags + dm, _ := DecOptions{}.DecModeWithTags(tags) + + for i := 0; i < b.N; i++ { + var v macedCOSE + if err := dm.Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal:", err) + } + } +} +func BenchmarkMarshalCOSEMAC(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.4 + cborData := hexDecode("d83dd18443a10104a1044c53796d6d65747269633235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7148093101ef6d789200") + + var v macedCOSE + if err := Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal():", err) + } + + for i := 0; i < b.N; i++ { + if _, err := Marshal(v); err != nil { + b.Fatal("Marshal():", v, err) + } + } +} + +func BenchmarkMarshalCOSEMACWithTag(b *testing.B) { + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.4 + cborData := hexDecode("d83dd18443a10104a1044c53796d6d65747269633235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7148093101ef6d789200") + + // Register tag CBOR Web Token (CWT) 61 and COSE_Mac0 17 with macedCOSE type + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, reflect.TypeOf(macedCOSE{}), 61, 17); err != nil { + b.Fatal("TagSet.Add:", err) + } + + // Create EncMode with tags. + dm, _ := DecOptions{}.DecModeWithTags(tags) + em, _ := EncOptions{}.EncModeWithTags(tags) + + var v macedCOSE + if err := dm.Unmarshal(cborData, &v); err != nil { + b.Fatal("Unmarshal():", err) + } + + for i := 0; i < b.N; i++ { + if _, err := em.Marshal(v); err != nil { + b.Fatal("Marshal():", v, err) + } + } +} diff --git a/vendor/github.com/fxamacker/cbor/cache.go b/vendor/github.com/fxamacker/cbor/cache.go new file mode 100644 index 0000000..3054bd4 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/cache.go @@ -0,0 +1,310 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "bytes" + "errors" + "reflect" + "sort" + "strconv" + "strings" + "sync" +) + +type encodeFuncs struct { + ef encodeFunc + ief isEmptyFunc +} + +var ( + decodingStructTypeCache sync.Map // map[reflect.Type]*decodingStructType + encodingStructTypeCache sync.Map // map[reflect.Type]*encodingStructType + encodeFuncCache sync.Map // map[reflect.Type]encodeFuncs + typeInfoCache sync.Map // map[reflect.Type]*typeInfo +) + +type specialType int + +const ( + specialTypeNone specialType = iota + specialTypeUnmarshalerIface + specialTypeEmptyIface + specialTypeTag + specialTypeTime +) + +type typeInfo struct { + elemTypeInfo *typeInfo + keyTypeInfo *typeInfo + typ reflect.Type + kind reflect.Kind + nonPtrType reflect.Type + nonPtrKind reflect.Kind + spclType specialType +} + +func newTypeInfo(t reflect.Type) *typeInfo { + tInfo := typeInfo{typ: t, kind: t.Kind()} + + for t.Kind() == reflect.Ptr { + t = t.Elem() + } + + k := t.Kind() + + tInfo.nonPtrType = t + tInfo.nonPtrKind = k + + if k == reflect.Interface && t.NumMethod() == 0 { + tInfo.spclType = specialTypeEmptyIface + } else if t == typeTag { + tInfo.spclType = specialTypeTag + } else if t == typeTime { + tInfo.spclType = specialTypeTime + } else if reflect.PtrTo(t).Implements(typeUnmarshaler) { + tInfo.spclType = specialTypeUnmarshalerIface + } + + switch k { + case reflect.Array, reflect.Slice: + tInfo.elemTypeInfo = getTypeInfo(t.Elem()) + case reflect.Map: + tInfo.keyTypeInfo = getTypeInfo(t.Key()) + tInfo.elemTypeInfo = getTypeInfo(t.Elem()) + } + + return &tInfo +} + +type decodingStructType struct { + fields fields + err error + toArray bool +} + +func getDecodingStructType(t reflect.Type) *decodingStructType { + if v, _ := decodingStructTypeCache.Load(t); v != nil { + return v.(*decodingStructType) + } + + flds, structOptions := getFields(t) + + toArray := hasToArrayOption(structOptions) + + var err error + for i := 0; i < len(flds); i++ { + if flds[i].keyAsInt { + nameAsInt, numErr := strconv.Atoi(flds[i].name) + if numErr != nil { + err = errors.New("cbor: failed to parse field name \"" + flds[i].name + "\" to int (" + numErr.Error() + ")") + break + } + flds[i].nameAsInt = int64(nameAsInt) + } + + flds[i].typInfo = getTypeInfo(flds[i].typ) + } + + structType := &decodingStructType{fields: flds, err: err, toArray: toArray} + decodingStructTypeCache.Store(t, structType) + return structType +} + +type encodingStructType struct { + fields fields + bytewiseFields fields + lengthFirstFields fields + omitEmptyFieldsIdx []int + err error + toArray bool + fixedLength bool // Struct type doesn't have any omitempty or anonymous fields. +} + +func (st *encodingStructType) getFields(em *encMode) fields { + if em.sort == SortNone { + return st.fields + } + if em.sort == SortLengthFirst { + return st.lengthFirstFields + } + return st.bytewiseFields +} + +type bytewiseFieldSorter struct { + fields fields +} + +func (x *bytewiseFieldSorter) Len() int { + return len(x.fields) +} + +func (x *bytewiseFieldSorter) Swap(i, j int) { + x.fields[i], x.fields[j] = x.fields[j], x.fields[i] +} + +func (x *bytewiseFieldSorter) Less(i, j int) bool { + return bytes.Compare(x.fields[i].cborName, x.fields[j].cborName) <= 0 +} + +type lengthFirstFieldSorter struct { + fields fields +} + +func (x *lengthFirstFieldSorter) Len() int { + return len(x.fields) +} + +func (x *lengthFirstFieldSorter) Swap(i, j int) { + x.fields[i], x.fields[j] = x.fields[j], x.fields[i] +} + +func (x *lengthFirstFieldSorter) Less(i, j int) bool { + if len(x.fields[i].cborName) != len(x.fields[j].cborName) { + return len(x.fields[i].cborName) < len(x.fields[j].cborName) + } + return bytes.Compare(x.fields[i].cborName, x.fields[j].cborName) <= 0 +} + +func getEncodingStructType(t reflect.Type) (*encodingStructType, error) { + if v, _ := encodingStructTypeCache.Load(t); v != nil { + structType := v.(*encodingStructType) + return structType, structType.err + } + + flds, structOptions := getFields(t) + + if hasToArrayOption(structOptions) { + return getEncodingStructToArrayType(t, flds) + } + + var err error + var hasKeyAsInt bool + var hasKeyAsStr bool + var omitEmptyIdx []int + fixedLength := true + e := getEncoderBuffer() + for i := 0; i < len(flds); i++ { + // Get field's encodeFunc + flds[i].ef, flds[i].ief = getEncodeFunc(flds[i].typ) + if flds[i].ef == nil { + err = &UnsupportedTypeError{t} + break + } + + // Encode field name + if flds[i].keyAsInt { + nameAsInt, numErr := strconv.Atoi(flds[i].name) + if numErr != nil { + err = errors.New("cbor: failed to parse field name \"" + flds[i].name + "\" to int (" + numErr.Error() + ")") + break + } + flds[i].nameAsInt = int64(nameAsInt) + if nameAsInt >= 0 { + encodeHead(e, byte(cborTypePositiveInt), uint64(nameAsInt)) + } else { + n := nameAsInt*(-1) - 1 + encodeHead(e, byte(cborTypeNegativeInt), uint64(n)) + } + flds[i].cborName = make([]byte, e.Len()) + copy(flds[i].cborName, e.Bytes()) + e.Reset() + + hasKeyAsInt = true + } else { + encodeHead(e, byte(cborTypeTextString), uint64(len(flds[i].name))) + flds[i].cborName = make([]byte, e.Len()+len(flds[i].name)) + n := copy(flds[i].cborName, e.Bytes()) + copy(flds[i].cborName[n:], flds[i].name) + e.Reset() + + hasKeyAsStr = true + } + + // Check if field is from embedded struct + if len(flds[i].idx) > 1 { + fixedLength = false + } + + // Check if field can be omitted when empty + if flds[i].omitEmpty { + fixedLength = false + omitEmptyIdx = append(omitEmptyIdx, i) + } + } + putEncoderBuffer(e) + + if err != nil { + structType := &encodingStructType{err: err} + encodingStructTypeCache.Store(t, structType) + return structType, structType.err + } + + // Sort fields by canonical order + bytewiseFields := make(fields, len(flds)) + copy(bytewiseFields, flds) + sort.Sort(&bytewiseFieldSorter{bytewiseFields}) + + lengthFirstFields := bytewiseFields + if hasKeyAsInt && hasKeyAsStr { + lengthFirstFields = make(fields, len(flds)) + copy(lengthFirstFields, flds) + sort.Sort(&lengthFirstFieldSorter{lengthFirstFields}) + } + + structType := &encodingStructType{ + fields: flds, + bytewiseFields: bytewiseFields, + lengthFirstFields: lengthFirstFields, + omitEmptyFieldsIdx: omitEmptyIdx, + fixedLength: fixedLength, + } + encodingStructTypeCache.Store(t, structType) + return structType, structType.err +} + +func getEncodingStructToArrayType(t reflect.Type, flds fields) (*encodingStructType, error) { + for i := 0; i < len(flds); i++ { + // Get field's encodeFunc + flds[i].ef, flds[i].ief = getEncodeFunc(flds[i].typ) + if flds[i].ef == nil { + structType := &encodingStructType{err: &UnsupportedTypeError{t}} + encodingStructTypeCache.Store(t, structType) + return structType, structType.err + } + } + + structType := &encodingStructType{ + fields: flds, + toArray: true, + fixedLength: true, + } + encodingStructTypeCache.Store(t, structType) + return structType, structType.err +} + +func getEncodeFunc(t reflect.Type) (encodeFunc, isEmptyFunc) { + if v, _ := encodeFuncCache.Load(t); v != nil { + fs := v.(encodeFuncs) + return fs.ef, fs.ief + } + ef, ief := getEncodeFuncInternal(t) + encodeFuncCache.Store(t, encodeFuncs{ef, ief}) + return ef, ief +} + +func getTypeInfo(t reflect.Type) *typeInfo { + if v, _ := typeInfoCache.Load(t); v != nil { + return v.(*typeInfo) + } + tInfo := newTypeInfo(t) + typeInfoCache.Store(t, tInfo) + return tInfo +} + +func hasToArrayOption(tag string) bool { + s := ",toarray" + idx := strings.Index(tag, s) + return idx >= 0 && (len(tag) == idx+len(s) || tag[idx+len(s)] == ',') +} diff --git a/vendor/github.com/fxamacker/cbor/decode.go b/vendor/github.com/fxamacker/cbor/decode.go new file mode 100644 index 0000000..14367f8 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/decode.go @@ -0,0 +1,1875 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "encoding" + "encoding/binary" + "errors" + "fmt" + "io" + "math" + "math/big" + "reflect" + "strconv" + "strings" + "time" + "unicode/utf8" + + "github.com/x448/float16" +) + +// Unmarshal parses the CBOR-encoded data into the value pointed to by v +// using default decoding options. If v is nil, not a pointer, or +// a nil pointer, Unmarshal returns an error. +// +// To unmarshal CBOR into a value implementing the Unmarshaler interface, +// Unmarshal calls that value's UnmarshalCBOR method with a valid +// CBOR value. +// +// To unmarshal CBOR byte string into a value implementing the +// encoding.BinaryUnmarshaler interface, Unmarshal calls that value's +// UnmarshalBinary method with decoded CBOR byte string. +// +// To unmarshal CBOR into a pointer, Unmarshal sets the pointer to nil +// if CBOR data is null (0xf6) or undefined (0xf7). Otherwise, Unmarshal +// unmarshals CBOR into the value pointed to by the pointer. If the +// pointer is nil, Unmarshal creates a new value for it to point to. +// +// To unmarshal CBOR into an empty interface value, Unmarshal uses the +// following rules: +// +// CBOR booleans decode to bool. +// CBOR positive integers decode to uint64. +// CBOR negative integers decode to int64 (big.Int if value overflows). +// CBOR floating points decode to float64. +// CBOR byte strings decode to []byte. +// CBOR text strings decode to string. +// CBOR arrays decode to []interface{}. +// CBOR maps decode to map[interface{}]interface{}. +// CBOR null and undefined values decode to nil. +// CBOR times (tag 0 and 1) decode to time.Time. +// CBOR bignums (tag 2 and 3) decode to big.Int. +// +// To unmarshal a CBOR array into a slice, Unmarshal allocates a new slice +// if the CBOR array is empty or slice capacity is less than CBOR array length. +// Otherwise Unmarshal overwrites existing elements, and sets slice length +// to CBOR array length. +// +// To unmarshal a CBOR array into a Go array, Unmarshal decodes CBOR array +// elements into Go array elements. If the Go array is smaller than the +// CBOR array, the extra CBOR array elements are discarded. If the CBOR +// array is smaller than the Go array, the extra Go array elements are +// set to zero values. +// +// To unmarshal a CBOR array into a struct, struct must have a special field "_" +// with struct tag `cbor:",toarray"`. Go array elements are decoded into struct +// fields. Any "omitempty" struct field tag option is ignored in this case. +// +// To unmarshal a CBOR map into a map, Unmarshal allocates a new map only if the +// map is nil. Otherwise Unmarshal reuses the existing map and keeps existing +// entries. Unmarshal stores key-value pairs from the CBOR map into Go map. +// See DecOptions.DupMapKey to enable duplicate map key detection. +// +// To unmarshal a CBOR map into a struct, Unmarshal matches CBOR map keys to the +// keys in the following priority: +// +// 1. "cbor" key in struct field tag, +// 2. "json" key in struct field tag, +// 3. struct field name. +// +// Unmarshal tries an exact match for field name, then a case-insensitive match. +// Map key-value pairs without corresponding struct fields are ignored. See +// DecOptions.ExtraReturnErrors to return error at unknown field. +// +// To unmarshal a CBOR text string into a time.Time value, Unmarshal parses text +// string formatted in RFC3339. To unmarshal a CBOR integer/float into a +// time.Time value, Unmarshal creates an unix time with integer/float as seconds +// and fractional seconds since January 1, 1970 UTC. +// +// To unmarshal CBOR null (0xf6) and undefined (0xf7) values into a +// slice/map/pointer, Unmarshal sets Go value to nil. Because null is often +// used to mean "not present", unmarshalling CBOR null and undefined value +// into any other Go type has no effect and returns no error. +// +// Unmarshal supports CBOR tag 55799 (self-describe CBOR), tag 0 and 1 (time), +// and tag 2 and 3 (bignum). +func Unmarshal(data []byte, v interface{}) error { + return defaultDecMode.Unmarshal(data, v) +} + +// Valid checks whether the CBOR data is complete and well-formed. +func Valid(data []byte) error { + return defaultDecMode.Valid(data) +} + +// Unmarshaler is the interface implemented by types that wish to unmarshal +// CBOR data themselves. The input is a valid CBOR value. UnmarshalCBOR +// must copy the CBOR data if it needs to use it after returning. +type Unmarshaler interface { + UnmarshalCBOR([]byte) error +} + +// InvalidUnmarshalError describes an invalid argument passed to Unmarshal. +type InvalidUnmarshalError struct { + s string +} + +func (e *InvalidUnmarshalError) Error() string { + return e.s +} + +// UnmarshalTypeError describes a CBOR value that can't be decoded to a Go type. +type UnmarshalTypeError struct { + CBORType string // type of CBOR value + GoType string // type of Go value it could not be decoded into + StructFieldName string // name of the struct field holding the Go value (optional) + errorMsg string // additional error message (optional) +} + +func (e *UnmarshalTypeError) Error() string { + var s string + if e.StructFieldName != "" { + s = "cbor: cannot unmarshal " + e.CBORType + " into Go struct field " + e.StructFieldName + " of type " + e.GoType + } else { + s = "cbor: cannot unmarshal " + e.CBORType + " into Go value of type " + e.GoType + } + if e.errorMsg != "" { + s += " (" + e.errorMsg + ")" + } + return s +} + +// DupMapKeyError describes detected duplicate map key in CBOR map. +type DupMapKeyError struct { + Key interface{} + Index int +} + +func (e *DupMapKeyError) Error() string { + return fmt.Sprintf("cbor: found duplicate map key \"%v\" at map element index %d", e.Key, e.Index) +} + +// UnknownFieldError describes detected unknown field in CBOR map when decoding to Go struct. +type UnknownFieldError struct { + Index int +} + +func (e *UnknownFieldError) Error() string { + return fmt.Sprintf("cbor: found unknown field at map element index %d", e.Index) +} + +// DupMapKeyMode specifies how to enforce duplicate map key. +type DupMapKeyMode int + +const ( + // DupMapKeyQuiet doesn't enforce duplicate map key. Decoder quietly (no error) + // uses faster of "keep first" or "keep last" depending on Go data type and other factors. + DupMapKeyQuiet DupMapKeyMode = iota + + // DupMapKeyEnforcedAPF enforces detection and rejection of duplicate map keys. + // APF means "Allow Partial Fill" and the destination map or struct can be partially filled. + // If a duplicate map key is detected, DupMapKeyError is returned without further decoding + // of the map. It's the caller's responsibility to respond to DupMapKeyError by + // discarding the partially filled result if their protocol requires it. + // WARNING: using DupMapKeyEnforcedAPF will decrease performance and increase memory use. + DupMapKeyEnforcedAPF + + maxDupMapKeyMode +) + +func (dmkm DupMapKeyMode) valid() bool { + return dmkm < maxDupMapKeyMode +} + +// IndefLengthMode specifies whether to allow indefinite length items. +type IndefLengthMode int + +const ( + // IndefLengthAllowed allows indefinite length items. + IndefLengthAllowed IndefLengthMode = iota + + // IndefLengthForbidden disallows indefinite length items. + IndefLengthForbidden + + maxIndefLengthMode +) + +func (m IndefLengthMode) valid() bool { + return m < maxIndefLengthMode +} + +// TagsMode specifies whether to allow CBOR tags. +type TagsMode int + +const ( + // TagsAllowed allows CBOR tags. + TagsAllowed TagsMode = iota + + // TagsForbidden disallows CBOR tags. + TagsForbidden + + maxTagsMode +) + +func (tm TagsMode) valid() bool { + return tm < maxTagsMode +} + +// IntDecMode specifies which Go int type (int64 or uint64) should +// be used when decoding CBOR int (major type 0 and 1) to Go interface{}. +type IntDecMode int + +const ( + // IntDecConvertNone affects how CBOR int (major type 0 and 1) decodes to Go interface{}. + // It makes CBOR positive int (major type 0) decode to uint64 value, and + // CBOR negative int (major type 1) decode to int64 value. + IntDecConvertNone IntDecMode = iota + + // IntDecConvertSigned affects how CBOR int (major type 0 and 1) decodes to Go interface{}. + // It makes CBOR positive/negative int (major type 0 and 1) decode to int64 value. + // If value overflows int64, UnmarshalTypeError is returned. + IntDecConvertSigned + + maxIntDec +) + +func (idm IntDecMode) valid() bool { + return idm < maxIntDec +} + +// ExtraDecErrorCond specifies extra conditions that should be treated as errors. +type ExtraDecErrorCond uint + +// ExtraDecErrorNone indicates no extra error condition. +const ExtraDecErrorNone ExtraDecErrorCond = 0 + +const ( + // ExtraDecErrorUnknownField indicates error condition when destination + // Go struct doesn't have a field matching a CBOR map key. + ExtraDecErrorUnknownField ExtraDecErrorCond = 1 << iota + + maxExtraDecError +) + +func (ec ExtraDecErrorCond) valid() bool { + return ec < maxExtraDecError +} + +// DecOptions specifies decoding options. +type DecOptions struct { + // DupMapKey specifies whether to enforce duplicate map key. + DupMapKey DupMapKeyMode + + // TimeTag specifies whether to check validity of time.Time (e.g. valid tag number and tag content type). + // For now, valid tag number means 0 or 1 as specified in RFC 7049 if the Go type is time.Time. + TimeTag DecTagMode + + // MaxNestedLevels specifies the max nested levels allowed for any combination of CBOR array, maps, and tags. + // Default is 32 levels and it can be set to [4, 256]. + MaxNestedLevels int + + // MaxArrayElements specifies the max number of elements for CBOR arrays. + // Default is 128*1024=131072 and it can be set to [16, 2147483647] + MaxArrayElements int + + // MaxMapPairs specifies the max number of key-value pairs for CBOR maps. + // Default is 128*1024=131072 and it can be set to [16, 2147483647] + MaxMapPairs int + + // IndefLength specifies whether to allow indefinite length CBOR items. + IndefLength IndefLengthMode + + // TagsMd specifies whether to allow CBOR tags (major type 6). + TagsMd TagsMode + + // IntDec specifies which Go integer type (int64 or uint64) to use + // when decoding CBOR int (major type 0 and 1) to Go interface{}. + IntDec IntDecMode + + // ExtraReturnErrors specifies extra conditions that should be treated as errors. + ExtraReturnErrors ExtraDecErrorCond +} + +// DecMode returns DecMode with immutable options and no tags (safe for concurrency). +func (opts DecOptions) DecMode() (DecMode, error) { + return opts.decMode() +} + +// DecModeWithTags returns DecMode with options and tags that are both immutable (safe for concurrency). +func (opts DecOptions) DecModeWithTags(tags TagSet) (DecMode, error) { + if opts.TagsMd == TagsForbidden { + return nil, errors.New("cbor: cannot create DecMode with TagSet when TagsMd is TagsForbidden") + } + if tags == nil { + return nil, errors.New("cbor: cannot create DecMode with nil value as TagSet") + } + + dm, err := opts.decMode() + if err != nil { + return nil, err + } + + // Copy tags + ts := tagSet(make(map[reflect.Type]*tagItem)) + syncTags := tags.(*syncTagSet) + syncTags.RLock() + for contentType, tag := range syncTags.t { + if tag.opts.DecTag != DecTagIgnored { + ts[contentType] = tag + } + } + syncTags.RUnlock() + + if len(ts) > 0 { + dm.tags = ts + } + + return dm, nil +} + +// DecModeWithSharedTags returns DecMode with immutable options and mutable shared tags (safe for concurrency). +func (opts DecOptions) DecModeWithSharedTags(tags TagSet) (DecMode, error) { + if opts.TagsMd == TagsForbidden { + return nil, errors.New("cbor: cannot create DecMode with TagSet when TagsMd is TagsForbidden") + } + if tags == nil { + return nil, errors.New("cbor: cannot create DecMode with nil value as TagSet") + } + dm, err := opts.decMode() + if err != nil { + return nil, err + } + dm.tags = tags + return dm, nil +} + +const ( + defaultMaxArrayElements = 131072 + minMaxArrayElements = 16 + maxMaxArrayElements = 2147483647 + + defaultMaxMapPairs = 131072 + minMaxMapPairs = 16 + maxMaxMapPairs = 2147483647 +) + +func (opts DecOptions) decMode() (*decMode, error) { + if !opts.DupMapKey.valid() { + return nil, errors.New("cbor: invalid DupMapKey " + strconv.Itoa(int(opts.DupMapKey))) + } + if !opts.TimeTag.valid() { + return nil, errors.New("cbor: invalid TimeTag " + strconv.Itoa(int(opts.TimeTag))) + } + if !opts.IndefLength.valid() { + return nil, errors.New("cbor: invalid IndefLength " + strconv.Itoa(int(opts.IndefLength))) + } + if !opts.TagsMd.valid() { + return nil, errors.New("cbor: invalid TagsMd " + strconv.Itoa(int(opts.TagsMd))) + } + if !opts.IntDec.valid() { + return nil, errors.New("cbor: invalid IntDec " + strconv.Itoa(int(opts.IntDec))) + } + if opts.MaxNestedLevels == 0 { + opts.MaxNestedLevels = 32 + } else if opts.MaxNestedLevels < 4 || opts.MaxNestedLevels > 256 { + return nil, errors.New("cbor: invalid MaxNestedLevels " + strconv.Itoa(opts.MaxNestedLevels) + " (range is [4, 256])") + } + if opts.MaxArrayElements == 0 { + opts.MaxArrayElements = defaultMaxArrayElements + } else if opts.MaxArrayElements < minMaxArrayElements || opts.MaxArrayElements > maxMaxArrayElements { + return nil, errors.New("cbor: invalid MaxArrayElements " + strconv.Itoa(opts.MaxArrayElements) + " (range is [" + strconv.Itoa(minMaxArrayElements) + ", " + strconv.Itoa(maxMaxArrayElements) + "])") + } + if opts.MaxMapPairs == 0 { + opts.MaxMapPairs = defaultMaxMapPairs + } else if opts.MaxMapPairs < minMaxMapPairs || opts.MaxMapPairs > maxMaxMapPairs { + return nil, errors.New("cbor: invalid MaxMapPairs " + strconv.Itoa(opts.MaxMapPairs) + " (range is [" + strconv.Itoa(minMaxMapPairs) + ", " + strconv.Itoa(maxMaxMapPairs) + "])") + } + if !opts.ExtraReturnErrors.valid() { + return nil, errors.New("cbor: invalid ExtraReturnErrors " + strconv.Itoa(int(opts.ExtraReturnErrors))) + } + dm := decMode{ + dupMapKey: opts.DupMapKey, + timeTag: opts.TimeTag, + maxNestedLevels: opts.MaxNestedLevels, + maxArrayElements: opts.MaxArrayElements, + maxMapPairs: opts.MaxMapPairs, + indefLength: opts.IndefLength, + tagsMd: opts.TagsMd, + intDec: opts.IntDec, + extraReturnErrors: opts.ExtraReturnErrors, + } + return &dm, nil +} + +// DecMode is the main interface for CBOR decoding. +type DecMode interface { + // Unmarshal parses the CBOR-encoded data into the value pointed to by v + // using the decoding mode. If v is nil, not a pointer, or a nil pointer, + // Unmarshal returns an error. + // + // See the documentation for Unmarshal for details. + Unmarshal(data []byte, v interface{}) error + // Valid checks whether the CBOR data is complete and well-formed. + Valid(data []byte) error + // NewDecoder returns a new decoder that reads from r using dm DecMode. + NewDecoder(r io.Reader) *Decoder + // DecOptions returns user specified options used to create this DecMode. + DecOptions() DecOptions +} + +type decMode struct { + tags tagProvider + dupMapKey DupMapKeyMode + timeTag DecTagMode + maxNestedLevels int + maxArrayElements int + maxMapPairs int + indefLength IndefLengthMode + tagsMd TagsMode + intDec IntDecMode + extraReturnErrors ExtraDecErrorCond +} + +var defaultDecMode, _ = DecOptions{}.decMode() + +// DecOptions returns user specified options used to create this DecMode. +func (dm *decMode) DecOptions() DecOptions { + return DecOptions{ + DupMapKey: dm.dupMapKey, + TimeTag: dm.timeTag, + MaxNestedLevels: dm.maxNestedLevels, + MaxArrayElements: dm.maxArrayElements, + MaxMapPairs: dm.maxMapPairs, + IndefLength: dm.indefLength, + TagsMd: dm.tagsMd, + IntDec: dm.intDec, + ExtraReturnErrors: dm.extraReturnErrors, + } +} + +// Unmarshal parses the CBOR-encoded data into the value pointed to by v +// using dm decoding mode. If v is nil, not a pointer, or a nil pointer, +// Unmarshal returns an error. +// +// See the documentation for Unmarshal for details. +func (dm *decMode) Unmarshal(data []byte, v interface{}) error { + d := decoder{data: data, dm: dm} + return d.value(v) +} + +// Valid checks whether the CBOR data is complete and well-formed. +func (dm *decMode) Valid(data []byte) error { + d := decoder{data: data, dm: dm} + return d.valid() +} + +// NewDecoder returns a new decoder that reads from r using dm DecMode. +func (dm *decMode) NewDecoder(r io.Reader) *Decoder { + return &Decoder{r: r, d: decoder{dm: dm}} +} + +type decoder struct { + data []byte + off int // next read offset in data + dm *decMode +} + +func (d *decoder) value(v interface{}) error { + // v can't be nil, non-pointer, or nil pointer value. + if v == nil { + return &InvalidUnmarshalError{"cbor: Unmarshal(nil)"} + } + rv := reflect.ValueOf(v) + if rv.Kind() != reflect.Ptr { + return &InvalidUnmarshalError{"cbor: Unmarshal(non-pointer " + rv.Type().String() + ")"} + } else if rv.IsNil() { + return &InvalidUnmarshalError{"cbor: Unmarshal(nil " + rv.Type().String() + ")"} + } + + off := d.off // Save offset before data validation + err := d.valid() + d.off = off // Restore offset + if err != nil { + return err + } + + rv = rv.Elem() + return d.parseToValue(rv, getTypeInfo(rv.Type())) +} + +type cborType uint8 + +const ( + cborTypePositiveInt cborType = 0x00 + cborTypeNegativeInt cborType = 0x20 + cborTypeByteString cborType = 0x40 + cborTypeTextString cborType = 0x60 + cborTypeArray cborType = 0x80 + cborTypeMap cborType = 0xa0 + cborTypeTag cborType = 0xc0 + cborTypePrimitives cborType = 0xe0 +) + +func (t cborType) String() string { + switch t { + case cborTypePositiveInt: + return "positive integer" + case cborTypeNegativeInt: + return "negative integer" + case cborTypeByteString: + return "byte string" + case cborTypeTextString: + return "UTF-8 text string" + case cborTypeArray: + return "array" + case cborTypeMap: + return "map" + case cborTypeTag: + return "tag" + case cborTypePrimitives: + return "primitives" + default: + return "Invalid type " + strconv.Itoa(int(t)) + } +} + +const ( + selfDescribedCBORTagNum = 55799 +) + +// parseToValue decodes CBOR data to value. It assumes data is well-formed, +// and does not perform bounds checking. +func (d *decoder) parseToValue(v reflect.Value, tInfo *typeInfo) error { //nolint:gocyclo + // Create new value for the pointer v to point to if CBOR value is not nil/undefined. + if !d.nextCBORNil() { + for v.Kind() == reflect.Ptr { + if v.IsNil() { + if !v.CanSet() { + d.skip() + return errors.New("cbor: cannot set new value for " + v.Type().String()) + } + v.Set(reflect.New(v.Type().Elem())) + } + v = v.Elem() + } + } + + // Strip self-described CBOR tag number. + for d.nextCBORType() == cborTypeTag { + off := d.off + _, _, tagNum := d.getHead() + if tagNum != selfDescribedCBORTagNum { + d.off = off + break + } + } + + // Check validity of supported built-in tags. + if d.nextCBORType() == cborTypeTag { + off := d.off + _, _, tagNum := d.getHead() + if err := validBuiltinTag(tagNum, d.data[d.off]); err != nil { + d.skip() + return err + } + d.off = off + } + + if tInfo.spclType != specialTypeNone { + switch tInfo.spclType { + case specialTypeEmptyIface: + iv, err := d.parse(false) // Skipped self-described CBOR tag number already. + if iv != nil { + v.Set(reflect.ValueOf(iv)) + } + return err + case specialTypeTag: + return d.parseToTag(v) + case specialTypeTime: + if d.nextCBORNil() { + // Decoding CBOR null and undefined to time.Time is no-op. + d.skip() + return nil + } + tm, err := d.parseToTime() + if err != nil { + return err + } + v.Set(reflect.ValueOf(tm)) + return nil + case specialTypeUnmarshalerIface: + return d.parseToUnmarshaler(v) + } + } + + // Check registered tag number + if tagItem := d.getRegisteredTagItem(tInfo.nonPtrType); tagItem != nil { + t := d.nextCBORType() + if t != cborTypeTag { + if tagItem.opts.DecTag == DecTagRequired { + d.skip() // Required tag number is absent, skip entire tag + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: tInfo.typ.String(), + errorMsg: "expect CBOR tag value"} + } + } else if err := d.validRegisteredTagNums(tagItem); err != nil { + d.skip() // Skip tag content + return err + } + } + + t := d.nextCBORType() + + switch t { + case cborTypePositiveInt: + _, _, val := d.getHead() + return fillPositiveInt(t, val, v) + case cborTypeNegativeInt: + _, _, val := d.getHead() + if val > math.MaxInt64 { + // CBOR negative integer overflows int64, use big.Int to store value. + bi := new(big.Int) + bi.SetUint64(val) + bi.Add(bi, big.NewInt(1)) + bi.Neg(bi) + + if tInfo.nonPtrType == typeBigInt { + v.Set(reflect.ValueOf(*bi)) + return nil + } + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: tInfo.nonPtrType.String(), + errorMsg: bi.String() + " overflows Go's int64", + } + } + nValue := int64(-1) ^ int64(val) + return fillNegativeInt(t, nValue, v) + case cborTypeByteString: + b := d.parseByteString() + return fillByteString(t, b, v) + case cborTypeTextString: + b, err := d.parseTextString() + if err != nil { + return err + } + return fillTextString(t, b, v) + case cborTypePrimitives: + _, ai, val := d.getHead() + if ai < 20 || ai == 24 { + return fillPositiveInt(t, val, v) + } + switch ai { + case 20, 21: + return fillBool(t, ai == 21, v) + case 22, 23: + return fillNil(t, v) + case 25: + f := float64(float16.Frombits(uint16(val)).Float32()) + return fillFloat(t, f, v) + case 26: + f := float64(math.Float32frombits(uint32(val))) + return fillFloat(t, f, v) + case 27: + f := math.Float64frombits(val) + return fillFloat(t, f, v) + } + case cborTypeTag: + _, _, tagNum := d.getHead() + switch tagNum { + case 2: + // Bignum (tag 2) can be decoded to uint, int, float, slice, array, or big.Int. + b := d.parseByteString() + bi := new(big.Int).SetBytes(b) + + if tInfo.nonPtrType == typeBigInt { + v.Set(reflect.ValueOf(*bi)) + return nil + } + if tInfo.nonPtrKind == reflect.Slice || tInfo.nonPtrKind == reflect.Array { + return fillByteString(t, b, v) + } + if bi.IsUint64() { + return fillPositiveInt(t, bi.Uint64(), v) + } + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: tInfo.nonPtrType.String(), + errorMsg: bi.String() + " overflows " + v.Type().String(), + } + case 3: + // Bignum (tag 3) can be decoded to int, float, slice, array, or big.Int. + b := d.parseByteString() + bi := new(big.Int).SetBytes(b) + bi.Add(bi, big.NewInt(1)) + bi.Neg(bi) + + if tInfo.nonPtrType == typeBigInt { + v.Set(reflect.ValueOf(*bi)) + return nil + } + if tInfo.nonPtrKind == reflect.Slice || tInfo.nonPtrKind == reflect.Array { + return fillByteString(t, b, v) + } + if bi.IsInt64() { + return fillNegativeInt(t, bi.Int64(), v) + } + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: tInfo.nonPtrType.String(), + errorMsg: bi.String() + " overflows " + v.Type().String(), + } + } + return d.parseToValue(v, tInfo) + case cborTypeArray: + if tInfo.nonPtrKind == reflect.Slice { + return d.parseArrayToSlice(v, tInfo) + } else if tInfo.nonPtrKind == reflect.Array { + return d.parseArrayToArray(v, tInfo) + } else if tInfo.nonPtrKind == reflect.Struct { + return d.parseArrayToStruct(v, tInfo) + } + d.skip() + return &UnmarshalTypeError{CBORType: t.String(), GoType: tInfo.nonPtrType.String()} + case cborTypeMap: + if tInfo.nonPtrKind == reflect.Struct { + return d.parseMapToStruct(v, tInfo) + } else if tInfo.nonPtrKind == reflect.Map { + return d.parseMapToMap(v, tInfo) + } + d.skip() + return &UnmarshalTypeError{CBORType: t.String(), GoType: tInfo.nonPtrType.String()} + } + return nil +} + +func (d *decoder) parseToTag(v reflect.Value) error { + if d.nextCBORNil() { + // Decoding CBOR null and undefined to cbor.Tag is no-op. + d.skip() + return nil + } + + t := d.nextCBORType() + if t != cborTypeTag { + d.skip() + return &UnmarshalTypeError{CBORType: t.String(), GoType: typeTag.String()} + } + + // Unmarshal tag number + _, _, num := d.getHead() + + // Unmarshal tag content + content, err := d.parse(false) + if err != nil { + return err + } + + v.Set(reflect.ValueOf(Tag{num, content})) + return nil +} + +func (d *decoder) parseToTime() (tm time.Time, err error) { + t := d.nextCBORType() + + // Verify that tag number or absence of tag number is acceptable to specified timeTag. + if t == cborTypeTag { + if d.dm.timeTag == DecTagIgnored { + // Skip tag number + for t == cborTypeTag { + d.getHead() + t = d.nextCBORType() + } + } else { + // Read tag number + _, _, tagNum := d.getHead() + if tagNum != 0 && tagNum != 1 { + d.skip() + err = errors.New("cbor: wrong tag number for time.Time, got " + strconv.Itoa(int(tagNum)) + ", expect 0 or 1") + return + } + } + } else { + if d.dm.timeTag == DecTagRequired { + d.skip() + err = &UnmarshalTypeError{CBORType: t.String(), GoType: typeTime.String(), errorMsg: "expect CBOR tag value"} + return + } + } + + var content interface{} + content, err = d.parse(false) + if err != nil { + return + } + + switch c := content.(type) { + case nil: + return + case uint64: + return time.Unix(int64(c), 0), nil + case int64: + return time.Unix(c, 0), nil + case float64: + if math.IsNaN(c) || math.IsInf(c, 0) { + return + } + f1, f2 := math.Modf(c) + return time.Unix(int64(f1), int64(f2*1e9)), nil + case string: + tm, err = time.Parse(time.RFC3339, c) + if err != nil { + tm = time.Time{} + err = errors.New("cbor: cannot set " + c + " for time.Time: " + err.Error()) + return + } + return + default: + err = &UnmarshalTypeError{CBORType: t.String(), GoType: typeTime.String()} + return + } +} + +// parseToUnmarshaler parses CBOR data to value implementing Unmarshaler interface. +// It assumes data is well-formed, and does not perform bounds checking. +func (d *decoder) parseToUnmarshaler(v reflect.Value) error { + if d.nextCBORNil() && v.Kind() == reflect.Ptr && v.IsNil() { + d.skip() + return nil + } + + if v.Kind() != reflect.Ptr && v.CanAddr() { + v = v.Addr() + } + if u, ok := v.Interface().(Unmarshaler); ok { + start := d.off + d.skip() + return u.UnmarshalCBOR(d.data[start:d.off]) + } + d.skip() + return errors.New("cbor: failed to assert " + v.Type().String() + " as cbor.Unmarshaler") +} + +// parse parses CBOR data and returns value in default Go type. +// It assumes data is well-formed, and does not perform bounds checking. +func (d *decoder) parse(skipSelfDescribedTag bool) (interface{}, error) { //nolint:gocyclo + // Strip self-described CBOR tag number. + if skipSelfDescribedTag { + for d.nextCBORType() == cborTypeTag { + off := d.off + _, _, tagNum := d.getHead() + if tagNum != selfDescribedCBORTagNum { + d.off = off + break + } + } + } + + // Check validity of supported built-in tags. + if d.nextCBORType() == cborTypeTag { + off := d.off + _, _, tagNum := d.getHead() + if err := validBuiltinTag(tagNum, d.data[d.off]); err != nil { + d.skip() + return nil, err + } + d.off = off + } + + t := d.nextCBORType() + switch t { + case cborTypePositiveInt: + _, _, val := d.getHead() + if d.dm.intDec == IntDecConvertNone { + return val, nil + } + if val > math.MaxInt64 { + return nil, &UnmarshalTypeError{ + CBORType: t.String(), + GoType: reflect.TypeOf(int64(0)).String(), + errorMsg: strconv.FormatUint(val, 10) + " overflows Go's int64", + } + } + return int64(val), nil + case cborTypeNegativeInt: + _, _, val := d.getHead() + if val > math.MaxInt64 { + // CBOR negative integer value overflows Go int64, use big.Int instead. + bi := new(big.Int).SetUint64(val) + bi.Add(bi, big.NewInt(1)) + bi.Neg(bi) + return *bi, nil + } + nValue := int64(-1) ^ int64(val) + return nValue, nil + case cborTypeByteString: + return d.parseByteString(), nil + case cborTypeTextString: + b, err := d.parseTextString() + if err != nil { + return nil, err + } + return string(b), nil + case cborTypeTag: + tagOff := d.off + _, _, tagNum := d.getHead() + contentOff := d.off + + switch tagNum { + case 0, 1: + d.off = tagOff + return d.parseToTime() + case 2: + b := d.parseByteString() + bi := new(big.Int).SetBytes(b) + return *bi, nil + case 3: + b := d.parseByteString() + bi := new(big.Int).SetBytes(b) + bi.Add(bi, big.NewInt(1)) + bi.Neg(bi) + return *bi, nil + } + + if d.dm.tags != nil { + // Parse to specified type if tag number is registered. + tagNums := []uint64{tagNum} + for d.nextCBORType() == cborTypeTag { + _, _, num := d.getHead() + tagNums = append(tagNums, num) + } + registeredType := d.dm.tags.getTypeFromTagNum(tagNums) + if registeredType != nil { + d.off = tagOff + rv := reflect.New(registeredType) + if err := d.parseToValue(rv.Elem(), getTypeInfo(registeredType)); err != nil { + return nil, err + } + return rv.Elem().Interface(), nil + } + } + + // Parse tag content + d.off = contentOff + content, err := d.parse(false) + if err != nil { + return nil, err + } + return Tag{tagNum, content}, nil + case cborTypePrimitives: + _, ai, val := d.getHead() + if ai < 20 || ai == 24 { + return val, nil + } + switch ai { + case 20, 21: + return (ai == 21), nil + case 22, 23: + return nil, nil + case 25: + f := float64(float16.Frombits(uint16(val)).Float32()) + return f, nil + case 26: + f := float64(math.Float32frombits(uint32(val))) + return f, nil + case 27: + f := math.Float64frombits(val) + return f, nil + } + case cborTypeArray: + return d.parseArray() + case cborTypeMap: + return d.parseMap() + } + return nil, nil +} + +// parseByteString parses CBOR encoded byte string. It returns a byte slice +// pointing to a copy of parsed data. +func (d *decoder) parseByteString() []byte { + _, ai, val := d.getHead() + if ai != 31 { + b := make([]byte, int(val)) + copy(b, d.data[d.off:d.off+int(val)]) + d.off += int(val) + return b + } + // Process indefinite length string chunks. + b := []byte{} + for !d.foundBreak() { + _, _, val = d.getHead() + b = append(b, d.data[d.off:d.off+int(val)]...) + d.off += int(val) + } + return b +} + +// parseTextString parses CBOR encoded text string. It returns a byte slice +// to prevent creating an extra copy of string. Caller should wrap returned +// byte slice as string when needed. +func (d *decoder) parseTextString() ([]byte, error) { + _, ai, val := d.getHead() + if ai != 31 { + b := d.data[d.off : d.off+int(val)] + d.off += int(val) + if !utf8.Valid(b) { + return nil, &SemanticError{"cbor: invalid UTF-8 string"} + } + return b, nil + } + // Process indefinite length string chunks. + b := []byte{} + for !d.foundBreak() { + _, _, val = d.getHead() + x := d.data[d.off : d.off+int(val)] + d.off += int(val) + if !utf8.Valid(x) { + for !d.foundBreak() { + d.skip() // Skip remaining chunk on error + } + return nil, &SemanticError{"cbor: invalid UTF-8 string"} + } + b = append(b, x...) + } + return b, nil +} + +func (d *decoder) parseArray() ([]interface{}, error) { + _, ai, val := d.getHead() + hasSize := (ai != 31) + count := int(val) + if !hasSize { + count = d.numOfItemsUntilBreak() // peek ahead to get array size to preallocate slice for better performance + } + v := make([]interface{}, count) + var e interface{} + var err, lastErr error + for i := 0; (hasSize && i < count) || (!hasSize && !d.foundBreak()); i++ { + if e, lastErr = d.parse(true); lastErr != nil { + if err == nil { + err = lastErr + } + continue + } + v[i] = e + } + return v, err +} + +func (d *decoder) parseArrayToSlice(v reflect.Value, tInfo *typeInfo) error { + _, ai, val := d.getHead() + hasSize := (ai != 31) + count := int(val) + if !hasSize { + count = d.numOfItemsUntilBreak() // peek ahead to get array size to preallocate slice for better performance + } + if v.IsNil() || v.Cap() < count || count == 0 { + v.Set(reflect.MakeSlice(tInfo.nonPtrType, count, count)) + } + v.SetLen(count) + var err error + for i := 0; (hasSize && i < count) || (!hasSize && !d.foundBreak()); i++ { + if lastErr := d.parseToValue(v.Index(i), tInfo.elemTypeInfo); lastErr != nil { + if err == nil { + err = lastErr + } + } + } + return err +} + +func (d *decoder) parseArrayToArray(v reflect.Value, tInfo *typeInfo) error { + _, ai, val := d.getHead() + hasSize := (ai != 31) + count := int(val) + gi := 0 + vLen := v.Len() + var err error + for ci := 0; (hasSize && ci < count) || (!hasSize && !d.foundBreak()); ci++ { + if gi < vLen { + // Read CBOR array element and set array element + if lastErr := d.parseToValue(v.Index(gi), tInfo.elemTypeInfo); lastErr != nil { + if err == nil { + err = lastErr + } + } + gi++ + } else { + d.skip() // Skip remaining CBOR array element + } + } + // Set remaining Go array elements to zero values. + if gi < vLen { + zeroV := reflect.Zero(tInfo.elemTypeInfo.typ) + for ; gi < vLen; gi++ { + v.Index(gi).Set(zeroV) + } + } + return err +} + +func (d *decoder) parseMap() (map[interface{}]interface{}, error) { + _, ai, val := d.getHead() + hasSize := (ai != 31) + count := int(val) + m := make(map[interface{}]interface{}) + var k, e interface{} + var err, lastErr error + keyCount := 0 + for i := 0; (hasSize && i < count) || (!hasSize && !d.foundBreak()); i++ { + // Parse CBOR map key. + if k, lastErr = d.parse(true); lastErr != nil { + if err == nil { + err = lastErr + } + d.skip() + continue + } + + // Detect if CBOR map key can be used as Go map key. + rv := reflect.ValueOf(k) + if !isHashableValue(rv) { + if err == nil { + err = errors.New("cbor: invalid map key type: " + rv.Type().String()) + } + d.skip() + continue + } + + // Parse CBOR map value. + if e, lastErr = d.parse(true); lastErr != nil { + if err == nil { + err = lastErr + } + continue + } + + // Add key-value pair to Go map. + m[k] = e + + // Detect duplicate map key. + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + newKeyCount := len(m) + if newKeyCount == keyCount { + m[k] = nil + err = &DupMapKeyError{k, i} + i++ + // skip the rest of the map + for ; (hasSize && i < count) || (!hasSize && !d.foundBreak()); i++ { + d.skip() // Skip map key + d.skip() // Skip map value + } + return m, err + } + keyCount = newKeyCount + } + } + return m, err +} + +func (d *decoder) parseMapToMap(v reflect.Value, tInfo *typeInfo) error { //nolint:gocyclo + _, ai, val := d.getHead() + hasSize := (ai != 31) + count := int(val) + if v.IsNil() { + mapsize := count + if !hasSize { + mapsize = 0 + } + v.Set(reflect.MakeMapWithSize(tInfo.nonPtrType, mapsize)) + } + keyType, eleType := tInfo.keyTypeInfo.typ, tInfo.elemTypeInfo.typ + reuseKey, reuseEle := isImmutableKind(tInfo.keyTypeInfo.kind), isImmutableKind(tInfo.elemTypeInfo.kind) + var keyValue, eleValue, zeroKeyValue, zeroEleValue reflect.Value + keyIsInterfaceType := keyType == typeIntf // If key type is interface{}, need to check if key value is hashable. + var err, lastErr error + keyCount := v.Len() + var existingKeys map[interface{}]bool // Store existing map keys, used for detecting duplicate map key. + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + existingKeys = make(map[interface{}]bool, keyCount) + if keyCount > 0 { + vKeys := v.MapKeys() + for i := 0; i < len(vKeys); i++ { + existingKeys[vKeys[i].Interface()] = true + } + } + } + for i := 0; (hasSize && i < count) || (!hasSize && !d.foundBreak()); i++ { + // Parse CBOR map key. + if !keyValue.IsValid() { + keyValue = reflect.New(keyType).Elem() + } else if !reuseKey { + if !zeroKeyValue.IsValid() { + zeroKeyValue = reflect.Zero(keyType) + } + keyValue.Set(zeroKeyValue) + } + if lastErr = d.parseToValue(keyValue, tInfo.keyTypeInfo); lastErr != nil { + if err == nil { + err = lastErr + } + d.skip() + continue + } + + // Detect if CBOR map key can be used as Go map key. + if keyIsInterfaceType && keyValue.Elem().IsValid() { + if !isHashableValue(keyValue.Elem()) { + if err == nil { + err = errors.New("cbor: invalid map key type: " + keyValue.Elem().Type().String()) + } + d.skip() + continue + } + } + + // Parse CBOR map value. + if !eleValue.IsValid() { + eleValue = reflect.New(eleType).Elem() + } else if !reuseEle { + if !zeroEleValue.IsValid() { + zeroEleValue = reflect.Zero(eleType) + } + eleValue.Set(zeroEleValue) + } + if lastErr := d.parseToValue(eleValue, tInfo.elemTypeInfo); lastErr != nil { + if err == nil { + err = lastErr + } + continue + } + + // Add key-value pair to Go map. + v.SetMapIndex(keyValue, eleValue) + + // Detect duplicate map key. + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + newKeyCount := v.Len() + if newKeyCount == keyCount { + kvi := keyValue.Interface() + if !existingKeys[kvi] { + v.SetMapIndex(keyValue, reflect.New(eleType).Elem()) + err = &DupMapKeyError{kvi, i} + i++ + // skip the rest of the map + for ; (hasSize && i < count) || (!hasSize && !d.foundBreak()); i++ { + d.skip() // skip map key + d.skip() // skip map value + } + return err + } + delete(existingKeys, kvi) + } + keyCount = newKeyCount + } + } + return err +} + +func (d *decoder) parseArrayToStruct(v reflect.Value, tInfo *typeInfo) error { + structType := getDecodingStructType(tInfo.nonPtrType) + if structType.err != nil { + return structType.err + } + + if !structType.toArray { + t := d.nextCBORType() + d.skip() + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: tInfo.nonPtrType.String(), + errorMsg: "cannot decode CBOR array to struct without toarray option", + } + } + + start := d.off + t, ai, val := d.getHead() + hasSize := (ai != 31) + count := int(val) + if !hasSize { + count = d.numOfItemsUntilBreak() // peek ahead to get array size + } + if count != len(structType.fields) { + d.off = start + d.skip() + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: tInfo.typ.String(), + errorMsg: "cannot decode CBOR array to struct with different number of elements", + } + } + var err, lastErr error + for i := 0; (hasSize && i < count) || (!hasSize && !d.foundBreak()); i++ { + f := structType.fields[i] + + // Get field value by index + var fv reflect.Value + if len(f.idx) == 1 { + fv = v.Field(f.idx[0]) + } else { + fv, lastErr = getFieldValue(v, f.idx, func(v reflect.Value) (reflect.Value, error) { + // Return a new value for embedded field null pointer to point to, or return error. + if !v.CanSet() { + return reflect.Value{}, errors.New("cbor: cannot set embedded pointer to unexported struct: " + v.Type().String()) + } + v.Set(reflect.New(v.Type().Elem())) + return v, nil + }) + if lastErr != nil && err == nil { + err = lastErr + } + if !fv.IsValid() { + d.skip() + continue + } + } + + if lastErr = d.parseToValue(fv, f.typInfo); lastErr != nil { + if err == nil { + if typeError, ok := lastErr.(*UnmarshalTypeError); ok { + typeError.StructFieldName = tInfo.typ.String() + "." + f.name + err = typeError + } else { + err = lastErr + } + } + } + } + return err +} + +// parseMapToStruct needs to be fast so gocyclo can be ignored for now. +func (d *decoder) parseMapToStruct(v reflect.Value, tInfo *typeInfo) error { //nolint:gocyclo + structType := getDecodingStructType(tInfo.nonPtrType) + if structType.err != nil { + return structType.err + } + + if structType.toArray { + t := d.nextCBORType() + d.skip() + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: tInfo.nonPtrType.String(), + errorMsg: "cannot decode CBOR map to struct with toarray option", + } + } + + var err, lastErr error + + // Get CBOR map size + _, ai, val := d.getHead() + hasSize := (ai != 31) + count := int(val) + + // Keeps track of matched struct fields + foundFldIdx := make([]bool, len(structType.fields)) + + // Keeps track of CBOR map keys to detect duplicate map key + keyCount := 0 + var mapKeys map[interface{}]struct{} + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + mapKeys = make(map[interface{}]struct{}, len(structType.fields)) + } + + errOnUnknownField := (d.dm.extraReturnErrors & ExtraDecErrorUnknownField) > 0 + + for j := 0; (hasSize && j < count) || (!hasSize && !d.foundBreak()); j++ { + var f *field + var k interface{} // Used by duplicate map key detection + + t := d.nextCBORType() + if t == cborTypeTextString { + var keyBytes []byte + keyBytes, lastErr = d.parseTextString() + if lastErr != nil { + if err == nil { + err = lastErr + } + d.skip() // skip value + continue + } + + keyLen := len(keyBytes) + // Find field with exact match + for i := 0; i < len(structType.fields); i++ { + fld := structType.fields[i] + if !foundFldIdx[i] && len(fld.name) == keyLen && fld.name == string(keyBytes) { + f = fld + foundFldIdx[i] = true + break + } + } + // Find field with case-insensitive match + if f == nil { + keyString := string(keyBytes) + for i := 0; i < len(structType.fields); i++ { + fld := structType.fields[i] + if !foundFldIdx[i] && len(fld.name) == keyLen && strings.EqualFold(fld.name, keyString) { + f = fld + foundFldIdx[i] = true + break + } + } + } + + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + k = string(keyBytes) + } + } else if t <= cborTypeNegativeInt { // uint/int + var nameAsInt int64 + + if t == cborTypePositiveInt { + _, _, val := d.getHead() + nameAsInt = int64(val) + } else { + _, _, val := d.getHead() + if val > math.MaxInt64 { + if err == nil { + err = &UnmarshalTypeError{ + CBORType: t.String(), + GoType: reflect.TypeOf(int64(0)).String(), + errorMsg: "-1-" + strconv.FormatUint(val, 10) + " overflows Go's int64", + } + } + d.skip() // skip value + continue + } + nameAsInt = int64(-1) ^ int64(val) + } + + // Find field + for i := 0; i < len(structType.fields); i++ { + fld := structType.fields[i] + if !foundFldIdx[i] && fld.keyAsInt && fld.nameAsInt == nameAsInt { + f = fld + foundFldIdx[i] = true + break + } + } + + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + k = nameAsInt + } + } else { + if err == nil { + err = &UnmarshalTypeError{ + CBORType: t.String(), + GoType: reflect.TypeOf("").String(), + errorMsg: "map key is of type " + t.String() + " and cannot be used to match struct field name", + } + } + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + // parse key + k, lastErr = d.parse(true) + if lastErr != nil { + d.skip() // skip value + continue + } + // Detect if CBOR map key can be used as Go map key. + if !isHashableValue(reflect.ValueOf(k)) { + d.skip() // skip value + continue + } + } else { + d.skip() // skip key + } + } + + if d.dm.dupMapKey == DupMapKeyEnforcedAPF { + mapKeys[k] = struct{}{} + newKeyCount := len(mapKeys) + if newKeyCount == keyCount { + err = &DupMapKeyError{k, j} + d.skip() // skip value + j++ + // skip the rest of the map + for ; (hasSize && j < count) || (!hasSize && !d.foundBreak()); j++ { + d.skip() + d.skip() + } + return err + } + keyCount = newKeyCount + } + + if f == nil { + if errOnUnknownField { + err = &UnknownFieldError{j} + d.skip() // Skip value + j++ + // skip the rest of the map + for ; (hasSize && j < count) || (!hasSize && !d.foundBreak()); j++ { + d.skip() + d.skip() + } + return err + } + d.skip() // Skip value + continue + } + + // Get field value by index + var fv reflect.Value + if len(f.idx) == 1 { + fv = v.Field(f.idx[0]) + } else { + fv, lastErr = getFieldValue(v, f.idx, func(v reflect.Value) (reflect.Value, error) { + // Return a new value for embedded field null pointer to point to, or return error. + if !v.CanSet() { + return reflect.Value{}, errors.New("cbor: cannot set embedded pointer to unexported struct: " + v.Type().String()) + } + v.Set(reflect.New(v.Type().Elem())) + return v, nil + }) + if lastErr != nil && err == nil { + err = lastErr + } + if !fv.IsValid() { + d.skip() + continue + } + } + + if lastErr = d.parseToValue(fv, f.typInfo); lastErr != nil { + if err == nil { + if typeError, ok := lastErr.(*UnmarshalTypeError); ok { + typeError.StructFieldName = tInfo.nonPtrType.String() + "." + f.name + err = typeError + } else { + err = lastErr + } + } + } + } + return err +} + +// validRegisteredTagNums verifies that tag numbers match registered tag numbers of type t. +// validRegisteredTagNums assumes next CBOR data type is tag. It scans all tag numbers, and stops at tag content. +func (d *decoder) validRegisteredTagNums(registeredTag *tagItem) error { + // Scan until next cbor data is tag content. + tagNums := make([]uint64, 0, 1) + for d.nextCBORType() == cborTypeTag { + _, _, val := d.getHead() + tagNums = append(tagNums, val) + } + + if !registeredTag.equalTagNum(tagNums) { + return &WrongTagError{registeredTag.contentType, registeredTag.num, tagNums} + } + return nil +} + +func (d *decoder) getRegisteredTagItem(vt reflect.Type) *tagItem { + if d.dm.tags != nil { + return d.dm.tags.getTagItemFromType(vt) + } + return nil +} + +// skip moves data offset to the next item. skip assumes data is well-formed, +// and does not perform bounds checking. +func (d *decoder) skip() { + t, ai, val := d.getHead() + + if ai == 31 { + switch t { + case cborTypeByteString, cborTypeTextString, cborTypeArray, cborTypeMap: + for { + if d.data[d.off] == 0xff { + d.off++ + return + } + d.skip() + } + } + } + + switch t { + case cborTypeByteString, cborTypeTextString: + d.off += int(val) + case cborTypeArray: + for i := 0; i < int(val); i++ { + d.skip() + } + case cborTypeMap: + for i := 0; i < int(val)*2; i++ { + d.skip() + } + case cborTypeTag: + d.skip() + } +} + +// getHead assumes data is well-formed, and does not perform bounds checking. +func (d *decoder) getHead() (t cborType, ai byte, val uint64) { + t = cborType(d.data[d.off] & 0xe0) + ai = d.data[d.off] & 0x1f + val = uint64(ai) + d.off++ + + if ai < 24 { + return + } + if ai == 24 { + val = uint64(d.data[d.off]) + d.off++ + return + } + if ai == 25 { + val = uint64(binary.BigEndian.Uint16(d.data[d.off : d.off+2])) + d.off += 2 + return + } + if ai == 26 { + val = uint64(binary.BigEndian.Uint32(d.data[d.off : d.off+4])) + d.off += 4 + return + } + if ai == 27 { + val = binary.BigEndian.Uint64(d.data[d.off : d.off+8]) + d.off += 8 + return + } + return +} + +func (d *decoder) numOfItemsUntilBreak() int { + savedOff := d.off + i := 0 + for !d.foundBreak() { + d.skip() + i++ + } + d.off = savedOff + return i +} + +// foundBreak assumes data is well-formed, and does not perform bounds checking. +func (d *decoder) foundBreak() bool { + if d.data[d.off] == 0xff { + d.off++ + return true + } + return false +} + +func (d *decoder) reset(data []byte) { + d.data = data + d.off = 0 +} + +func (d *decoder) nextCBORType() cborType { + return cborType(d.data[d.off] & 0xe0) +} + +func (d *decoder) nextCBORNil() bool { + return d.data[d.off] == 0xf6 || d.data[d.off] == 0xf7 +} + +var ( + typeIntf = reflect.TypeOf([]interface{}(nil)).Elem() + typeTime = reflect.TypeOf(time.Time{}) + typeBigInt = reflect.TypeOf(big.Int{}) + typeUnmarshaler = reflect.TypeOf((*Unmarshaler)(nil)).Elem() + typeBinaryUnmarshaler = reflect.TypeOf((*encoding.BinaryUnmarshaler)(nil)).Elem() +) + +func fillNil(t cborType, v reflect.Value) error { + switch v.Kind() { + case reflect.Slice, reflect.Map, reflect.Interface, reflect.Ptr: + v.Set(reflect.Zero(v.Type())) + return nil + } + return nil +} + +func fillPositiveInt(t cborType, val uint64, v reflect.Value) error { + switch v.Kind() { + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + if val > math.MaxInt64 { + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: v.Type().String(), + errorMsg: strconv.FormatUint(val, 10) + " overflows " + v.Type().String(), + } + } + if v.OverflowInt(int64(val)) { + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: v.Type().String(), + errorMsg: strconv.FormatUint(val, 10) + " overflows " + v.Type().String(), + } + } + v.SetInt(int64(val)) + return nil + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + if v.OverflowUint(val) { + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: v.Type().String(), + errorMsg: strconv.FormatUint(val, 10) + " overflows " + v.Type().String(), + } + } + v.SetUint(val) + return nil + case reflect.Float32, reflect.Float64: + f := float64(val) + v.SetFloat(f) + return nil + } + if v.Type() == typeBigInt { + i := new(big.Int).SetUint64(val) + v.Set(reflect.ValueOf(*i)) + return nil + } + return &UnmarshalTypeError{CBORType: t.String(), GoType: v.Type().String()} +} + +func fillNegativeInt(t cborType, val int64, v reflect.Value) error { + switch v.Kind() { + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + if v.OverflowInt(val) { + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: v.Type().String(), + errorMsg: strconv.FormatInt(val, 10) + " overflows " + v.Type().String(), + } + } + v.SetInt(val) + return nil + case reflect.Float32, reflect.Float64: + f := float64(val) + v.SetFloat(f) + return nil + } + if v.Type() == typeBigInt { + i := new(big.Int).SetInt64(val) + v.Set(reflect.ValueOf(*i)) + return nil + } + return &UnmarshalTypeError{CBORType: t.String(), GoType: v.Type().String()} +} + +func fillBool(t cborType, val bool, v reflect.Value) error { + if v.Kind() == reflect.Bool { + v.SetBool(val) + return nil + } + return &UnmarshalTypeError{CBORType: t.String(), GoType: v.Type().String()} +} + +func fillFloat(t cborType, val float64, v reflect.Value) error { + switch v.Kind() { + case reflect.Float32, reflect.Float64: + if v.OverflowFloat(val) { + return &UnmarshalTypeError{ + CBORType: t.String(), + GoType: v.Type().String(), + errorMsg: strconv.FormatFloat(val, 'E', -1, 64) + " overflows " + v.Type().String(), + } + } + v.SetFloat(val) + return nil + } + return &UnmarshalTypeError{CBORType: t.String(), GoType: v.Type().String()} +} + +func fillByteString(t cborType, val []byte, v reflect.Value) error { + if reflect.PtrTo(v.Type()).Implements(typeBinaryUnmarshaler) { + if v.CanAddr() { + v = v.Addr() + if u, ok := v.Interface().(encoding.BinaryUnmarshaler); ok { + return u.UnmarshalBinary(val) + } + } + return errors.New("cbor: cannot set new value for " + v.Type().String()) + } + if v.Kind() == reflect.Slice && v.Type().Elem().Kind() == reflect.Uint8 { + v.SetBytes(val) + return nil + } + if v.Kind() == reflect.Array && v.Type().Elem().Kind() == reflect.Uint8 { + vLen := v.Len() + i := 0 + for ; i < vLen && i < len(val); i++ { + v.Index(i).SetUint(uint64(val[i])) + } + // Set remaining Go array elements to zero values. + if i < vLen { + zeroV := reflect.Zero(reflect.TypeOf(byte(0))) + for ; i < vLen; i++ { + v.Index(i).Set(zeroV) + } + } + return nil + } + return &UnmarshalTypeError{CBORType: t.String(), GoType: v.Type().String()} +} + +func fillTextString(t cborType, val []byte, v reflect.Value) error { + if v.Kind() == reflect.String { + v.SetString(string(val)) + return nil + } + return &UnmarshalTypeError{CBORType: t.String(), GoType: v.Type().String()} +} + +func isImmutableKind(k reflect.Kind) bool { + switch k { + case reflect.Bool, + reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64, + reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, + reflect.Float32, reflect.Float64, + reflect.String: + return true + default: + return false + } +} + +func isHashableValue(rv reflect.Value) bool { + switch rv.Kind() { + case reflect.Slice, reflect.Map, reflect.Func: + return false + case reflect.Struct: + switch rv.Type() { + case typeTag: + tag := rv.Interface().(Tag) + return isHashableValue(reflect.ValueOf(tag.Content)) + case typeBigInt: + return false + } + } + return true +} + +// validBuiltinTag checks that supported built-in tag numbers are followed by expected content types. +func validBuiltinTag(tagNum uint64, contentHead byte) error { + t := cborType(contentHead & 0xe0) + switch tagNum { + case 0: + // Tag content (date/time text string in RFC 3339 format) must be string type. + if t != cborTypeTextString { + return errors.New("cbor: tag number 0 must be followed by text string, got " + t.String()) + } + return nil + case 1: + // Tag content (epoch date/time) must be uint, int, or float type. + if t != cborTypePositiveInt && t != cborTypeNegativeInt && (contentHead < 0xf9 || contentHead > 0xfb) { + return errors.New("cbor: tag number 1 must be followed by integer or floating-point number, got " + t.String()) + } + return nil + case 2, 3: + // Tag content (bignum) must be byte type. + if t != cborTypeByteString { + return errors.New("cbor: tag number 2 or 3 must be followed by byte string, got " + t.String()) + } + return nil + } + return nil +} diff --git a/vendor/github.com/fxamacker/cbor/decode_test.go b/vendor/github.com/fxamacker/cbor/decode_test.go new file mode 100644 index 0000000..21e7c80 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/decode_test.go @@ -0,0 +1,5180 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "bytes" + "encoding/binary" + "encoding/hex" + "errors" + "fmt" + "io" + "math" + "math/big" + "reflect" + "strings" + "testing" + "time" +) + +var ( + typeBool = reflect.TypeOf(true) + typeUint8 = reflect.TypeOf(uint8(0)) + typeUint16 = reflect.TypeOf(uint16(0)) + typeUint32 = reflect.TypeOf(uint32(0)) + typeUint64 = reflect.TypeOf(uint64(0)) + typeInt8 = reflect.TypeOf(int8(0)) + typeInt16 = reflect.TypeOf(int16(0)) + typeInt32 = reflect.TypeOf(int32(0)) + typeInt64 = reflect.TypeOf(int64(0)) + typeFloat32 = reflect.TypeOf(float32(0)) + typeFloat64 = reflect.TypeOf(float64(0)) + typeString = reflect.TypeOf("") + typeByteSlice = reflect.TypeOf([]byte(nil)) + typeByteArray = reflect.TypeOf([5]byte{}) + typeIntSlice = reflect.TypeOf([]int{}) + typeStringSlice = reflect.TypeOf([]string{}) + typeMapStringInt = reflect.TypeOf(map[string]int{}) + typeMapStringString = reflect.TypeOf(map[string]string{}) + typeMapStringIntf = reflect.TypeOf(map[string]interface{}{}) +) + +type unmarshalTest struct { + cborData []byte + emptyInterfaceValue interface{} + values []interface{} + wrongTypes []reflect.Type +} + +var unmarshalTests = []unmarshalTest{ + // CBOR test data are from https://tools.ietf.org/html/rfc7049#appendix-A. + // positive integer + { + hexDecode("00"), + uint64(0), + []interface{}{uint8(0), uint16(0), uint32(0), uint64(0), uint(0), int8(0), int16(0), int32(0), int64(0), int(0), float32(0), float64(0), bigIntOrPanic("0")}, + []reflect.Type{typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("01"), + uint64(1), + []interface{}{uint8(1), uint16(1), uint32(1), uint64(1), uint(1), int8(1), int16(1), int32(1), int64(1), int(1), float32(1), float64(1), bigIntOrPanic("1")}, + []reflect.Type{typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("0a"), + uint64(10), + []interface{}{uint8(10), uint16(10), uint32(10), uint64(10), uint(10), int8(10), int16(10), int32(10), int64(10), int(10), float32(10), float64(10), bigIntOrPanic("10")}, + []reflect.Type{typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("17"), + uint64(23), + []interface{}{uint8(23), uint16(23), uint32(23), uint64(23), uint(23), int8(23), int16(23), int32(23), int64(23), int(23), float32(23), float64(23), bigIntOrPanic("23")}, + []reflect.Type{typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("1818"), + uint64(24), + []interface{}{uint8(24), uint16(24), uint32(24), uint64(24), uint(24), int8(24), int16(24), int32(24), int64(24), int(24), float32(24), float64(24), bigIntOrPanic("24")}, + []reflect.Type{typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("1819"), + uint64(25), + []interface{}{uint8(25), uint16(25), uint32(25), uint64(25), uint(25), int8(25), int16(25), int32(25), int64(25), int(25), float32(25), float64(25), bigIntOrPanic("25")}, + []reflect.Type{typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("1864"), + uint64(100), + []interface{}{uint8(100), uint16(100), uint32(100), uint64(100), uint(100), int8(100), int16(100), int32(100), int64(100), int(100), float32(100), float64(100), bigIntOrPanic("100")}, + []reflect.Type{typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("1903e8"), + uint64(1000), + []interface{}{uint16(1000), uint32(1000), uint64(1000), uint(1000), int16(1000), int32(1000), int64(1000), int(1000), float32(1000), float64(1000), bigIntOrPanic("1000")}, + []reflect.Type{typeUint8, typeInt8, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("1a000f4240"), + uint64(1000000), + []interface{}{uint32(1000000), uint64(1000000), uint(1000000), int32(1000000), int64(1000000), int(1000000), float32(1000000), float64(1000000), bigIntOrPanic("1000000")}, + []reflect.Type{typeUint8, typeUint16, typeInt8, typeInt16, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("1b000000e8d4a51000"), + uint64(1000000000000), + []interface{}{uint64(1000000000000), uint(1000000000000), int64(1000000000000), int(1000000000000), float32(1000000000000), float64(1000000000000), bigIntOrPanic("1000000000000")}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeInt8, typeInt16, typeInt32, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("1bffffffffffffffff"), + uint64(18446744073709551615), + []interface{}{uint64(18446744073709551615), uint(18446744073709551615), float32(18446744073709551615), float64(18446744073709551615), bigIntOrPanic("18446744073709551615")}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeInt8, typeInt16, typeInt32, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + // negative integer + { + hexDecode("20"), + int64(-1), + []interface{}{int8(-1), int16(-1), int32(-1), int64(-1), int(-1), float32(-1), float64(-1), bigIntOrPanic("-1")}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("29"), + int64(-10), + []interface{}{int8(-10), int16(-10), int32(-10), int64(-10), int(-10), float32(-10), float64(-10), bigIntOrPanic("-10")}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("3863"), + int64(-100), + []interface{}{int8(-100), int16(-100), int32(-100), int64(-100), int(-100), float32(-100), float64(-100), bigIntOrPanic("-100")}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("3903e7"), + int64(-1000), + []interface{}{int16(-1000), int32(-1000), int64(-1000), int(-1000), float32(-1000), float64(-1000), bigIntOrPanic("-1000")}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("3bffffffffffffffff"), + bigIntOrPanic("-18446744073709551616"), + []interface{}{bigIntOrPanic("-18446744073709551616")}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, // CBOR value -18446744073709551616 overflows Go's int64, see TestNegIntOverflow + // byte string + { + hexDecode("40"), + []byte{}, + []interface{}{[]byte{}, [0]byte{}, [1]byte{0}, [5]byte{0, 0, 0, 0, 0}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("4401020304"), + []byte{1, 2, 3, 4}, + []interface{}{[]byte{1, 2, 3, 4}, [0]byte{}, [1]byte{1}, [5]byte{1, 2, 3, 4, 0}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("5f42010243030405ff"), + []byte{1, 2, 3, 4, 5}, + []interface{}{[]byte{1, 2, 3, 4, 5}, [0]byte{}, [1]byte{1}, [5]byte{1, 2, 3, 4, 5}, [6]byte{1, 2, 3, 4, 5, 0}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + // text string + { + hexDecode("60"), + "", + []interface{}{""}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("6161"), + "a", + []interface{}{"a"}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("6449455446"), + "IETF", + []interface{}{"IETF"}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("62225c"), + "\"\\", + []interface{}{"\"\\"}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("62c3bc"), + "ü", + []interface{}{"ü"}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("63e6b0b4"), + "水", + []interface{}{"水"}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("64f0908591"), + "𐅑", + []interface{}{"𐅑"}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("7f657374726561646d696e67ff"), + "streaming", + []interface{}{"streaming"}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + // array + { + hexDecode("80"), + []interface{}{}, + []interface{}{[]interface{}{}, []byte{}, []string{}, []int{}, [0]int{}, [1]int{0}, [5]int{0}, []float32{}, []float64{}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("83010203"), + []interface{}{uint64(1), uint64(2), uint64(3)}, + []interface{}{[]interface{}{uint64(1), uint64(2), uint64(3)}, []byte{1, 2, 3}, []int{1, 2, 3}, []uint{1, 2, 3}, [0]int{}, [1]int{1}, [3]int{1, 2, 3}, [5]int{1, 2, 3, 0, 0}, []float32{1, 2, 3}, []float64{1, 2, 3}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("8301820203820405"), + []interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, + []interface{}{[]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, [...]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("83018202039f0405ff"), + []interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, + []interface{}{[]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, [...]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("83019f0203ff820405"), + []interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, + []interface{}{[]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, [...]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("98190102030405060708090a0b0c0d0e0f101112131415161718181819"), + []interface{}{uint64(1), uint64(2), uint64(3), uint64(4), uint64(5), uint64(6), uint64(7), uint64(8), uint64(9), uint64(10), uint64(11), uint64(12), uint64(13), uint64(14), uint64(15), uint64(16), uint64(17), uint64(18), uint64(19), uint64(20), uint64(21), uint64(22), uint64(23), uint64(24), uint64(25)}, + []interface{}{ + []interface{}{uint64(1), uint64(2), uint64(3), uint64(4), uint64(5), uint64(6), uint64(7), uint64(8), uint64(9), uint64(10), uint64(11), uint64(12), uint64(13), uint64(14), uint64(15), uint64(16), uint64(17), uint64(18), uint64(19), uint64(20), uint64(21), uint64(22), uint64(23), uint64(24), uint64(25)}, + []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []uint{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + [0]int{}, + [1]int{1}, + [...]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + [30]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 0, 0, 0, 0, 0}, + []float32{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []float64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("9fff"), + []interface{}{}, + []interface{}{[]interface{}{}, []byte{}, []string{}, []int{}, [0]int{}, [1]int{0}, [5]int{0, 0, 0, 0, 0}, []float32{}, []float64{}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("9f018202039f0405ffff"), + []interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, + []interface{}{[]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, [...]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("9f01820203820405ff"), + []interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, + []interface{}{[]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}, [...]interface{}{uint64(1), []interface{}{uint64(2), uint64(3)}, []interface{}{uint64(4), uint64(5)}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("9f0102030405060708090a0b0c0d0e0f101112131415161718181819ff"), + []interface{}{uint64(1), uint64(2), uint64(3), uint64(4), uint64(5), uint64(6), uint64(7), uint64(8), uint64(9), uint64(10), uint64(11), uint64(12), uint64(13), uint64(14), uint64(15), uint64(16), uint64(17), uint64(18), uint64(19), uint64(20), uint64(21), uint64(22), uint64(23), uint64(24), uint64(25)}, + []interface{}{ + []interface{}{uint64(1), uint64(2), uint64(3), uint64(4), uint64(5), uint64(6), uint64(7), uint64(8), uint64(9), uint64(10), uint64(11), uint64(12), uint64(13), uint64(14), uint64(15), uint64(16), uint64(17), uint64(18), uint64(19), uint64(20), uint64(21), uint64(22), uint64(23), uint64(24), uint64(25)}, + []byte{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []uint{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + [0]int{}, + [1]int{1}, + [...]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + [30]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 0, 0, 0, 0, 0}, + []float32{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []float64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("826161a161626163"), + []interface{}{"a", map[interface{}]interface{}{"b": "c"}}, + []interface{}{[]interface{}{"a", map[interface{}]interface{}{"b": "c"}}, [...]interface{}{"a", map[interface{}]interface{}{"b": "c"}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeByteArray, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("826161bf61626163ff"), + []interface{}{"a", map[interface{}]interface{}{"b": "c"}}, + []interface{}{[]interface{}{"a", map[interface{}]interface{}{"b": "c"}}, [...]interface{}{"a", map[interface{}]interface{}{"b": "c"}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeByteArray, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag, typeBigInt}, + }, + // map + { + hexDecode("a0"), + map[interface{}]interface{}{}, + []interface{}{map[interface{}]interface{}{}, map[string]bool{}, map[string]int{}, map[int]string{}, map[int]bool{}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeTag, typeRawTag}, + }, + { + hexDecode("a201020304"), + map[interface{}]interface{}{uint64(1): uint64(2), uint64(3): uint64(4)}, + []interface{}{map[interface{}]interface{}{uint64(1): uint64(2), uint64(3): uint64(4)}, map[uint]int{1: 2, 3: 4}, map[int]uint{1: 2, 3: 4}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("a26161016162820203"), + map[interface{}]interface{}{"a": uint64(1), "b": []interface{}{uint64(2), uint64(3)}}, + []interface{}{map[interface{}]interface{}{"a": uint64(1), "b": []interface{}{uint64(2), uint64(3)}}, + map[string]interface{}{"a": uint64(1), "b": []interface{}{uint64(2), uint64(3)}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("a56161614161626142616361436164614461656145"), + map[interface{}]interface{}{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E"}, + []interface{}{map[interface{}]interface{}{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E"}, + map[string]interface{}{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E"}, + map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E"}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("bf61610161629f0203ffff"), + map[interface{}]interface{}{"a": uint64(1), "b": []interface{}{uint64(2), uint64(3)}}, + []interface{}{map[interface{}]interface{}{"a": uint64(1), "b": []interface{}{uint64(2), uint64(3)}}, + map[string]interface{}{"a": uint64(1), "b": []interface{}{uint64(2), uint64(3)}}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("bf6346756ef563416d7421ff"), + map[interface{}]interface{}{"Fun": true, "Amt": int64(-2)}, + []interface{}{map[interface{}]interface{}{"Fun": true, "Amt": int64(-2)}, + map[string]interface{}{"Fun": true, "Amt": int64(-2)}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + // tag + { + hexDecode("c074323031332d30332d32315432303a30343a30305a"), + time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), // 2013-03-21 20:04:00 +0000 UTC + []interface{}{"2013-03-21T20:04:00Z", time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), Tag{0, "2013-03-21T20:04:00Z"}, RawTag{0, hexDecode("74323031332d30332d32315432303a30343a30305a")}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeBigInt}, + }, // 0: standard date/time + { + hexDecode("c11a514b67b0"), + time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), // 2013-03-21 20:04:00 +0000 UTC + []interface{}{uint32(1363896240), uint64(1363896240), int32(1363896240), int64(1363896240), float32(1363896240), float64(1363896240), time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), Tag{1, uint64(1363896240)}, RawTag{1, hexDecode("1a514b67b0")}}, + []reflect.Type{typeUint8, typeUint16, typeInt8, typeInt16, typeByteSlice, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt}, + }, // 1: epoch-based date/time + { + hexDecode("c249010000000000000000"), + bigIntOrPanic("18446744073709551616"), + []interface{}{ + // Decode to byte slice + []byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, + // Decode to array of various lengths + [0]byte{}, + [1]byte{0x01}, + [3]byte{0x01, 0x00, 0x00}, + [...]byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, + [10]byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, + // Decode to Tag and RawTag + Tag{2, []byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}}, + RawTag{2, hexDecode("49010000000000000000")}, + // Decode to big.Int + bigIntOrPanic("18446744073709551616"), + }, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt}, + }, // 2: positive bignum: 18446744073709551616 + { + hexDecode("c349010000000000000000"), + bigIntOrPanic("-18446744073709551617"), + []interface{}{ + // Decode to byte slice + []byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, + // Decode to array of various lengths + [0]byte{}, + [1]byte{0x01}, + [3]byte{0x01, 0x00, 0x00}, + [...]byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, + [10]byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}, + // Decode to Tag and RawTag + Tag{3, []byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}}, + RawTag{3, hexDecode("49010000000000000000")}, + // Decode to big.Int + bigIntOrPanic("-18446744073709551617"), + }, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt}, + }, // 3: negative bignum: -18446744073709551617 + { + hexDecode("c1fb41d452d9ec200000"), + time.Date(2013, 3, 21, 20, 4, 0, 500000000, time.UTC), // 2013-03-21 20:04:00.5 +0000 UTC + []interface{}{float32(1363896240.5), float64(1363896240.5), time.Date(2013, 3, 21, 20, 4, 0, 500000000, time.UTC), Tag{1, float64(1363896240.5)}, RawTag{1, hexDecode("fb41d452d9ec200000")}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeMapStringInt, typeBigInt}, + }, // 1: epoch-based date/time + { + hexDecode("d74401020304"), + Tag{23, []byte{0x01, 0x02, 0x03, 0x04}}, + []interface{}{[]byte{0x01, 0x02, 0x03, 0x04}, [0]byte{}, [1]byte{0x01}, [3]byte{0x01, 0x02, 0x03}, [...]byte{0x01, 0x02, 0x03, 0x04}, [5]byte{0x01, 0x02, 0x03, 0x04, 0x00}, Tag{23, []byte{0x01, 0x02, 0x03, 0x04}}, RawTag{23, hexDecode("4401020304")}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt, typeBigInt}, + }, // 23: expected conversion to base16 encoding + { + hexDecode("d818456449455446"), + Tag{24, []byte{0x64, 0x49, 0x45, 0x54, 0x46}}, + []interface{}{[]byte{0x64, 0x49, 0x45, 0x54, 0x46}, [0]byte{}, [1]byte{0x64}, [3]byte{0x64, 0x49, 0x45}, [...]byte{0x64, 0x49, 0x45, 0x54, 0x46}, [6]byte{0x64, 0x49, 0x45, 0x54, 0x46, 0x00}, Tag{24, []byte{0x64, 0x49, 0x45, 0x54, 0x46}}, RawTag{24, hexDecode("456449455446")}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt, typeBigInt}, + }, // 24: encoded cborBytes data item + { + hexDecode("d82076687474703a2f2f7777772e6578616d706c652e636f6d"), + Tag{32, "http://www.example.com"}, + []interface{}{"http://www.example.com", Tag{32, "http://www.example.com"}, RawTag{32, hexDecode("76687474703a2f2f7777772e6578616d706c652e636f6d")}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeBigInt}, + }, // 32: URI + // primitives + { + hexDecode("f4"), + false, + []interface{}{false}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteArray, typeByteSlice, typeString, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("f5"), + true, + []interface{}{true}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteArray, typeByteSlice, typeString, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("f6"), + nil, + []interface{}{false, uint(0), uint8(0), uint16(0), uint32(0), uint64(0), int(0), int8(0), int16(0), int32(0), int64(0), float32(0.0), float64(0.0), "", []byte(nil), []int(nil), []string(nil), map[string]int(nil), time.Time{}, bigIntOrPanic("0"), Tag{}, RawTag{}}, + nil, + }, + { + hexDecode("f7"), + nil, + []interface{}{false, uint(0), uint8(0), uint16(0), uint32(0), uint64(0), int(0), int8(0), int16(0), int32(0), int64(0), float32(0.0), float64(0.0), "", []byte(nil), []int(nil), []string(nil), map[string]int(nil), time.Time{}, bigIntOrPanic("0"), Tag{}, RawTag{}}, + nil, + }, + { + hexDecode("f0"), + uint64(16), + []interface{}{uint8(16), uint16(16), uint32(16), uint64(16), uint(16), int8(16), int16(16), int32(16), int64(16), int(16), float32(16), float64(16), bigIntOrPanic("16")}, + []reflect.Type{typeByteSlice, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + // This example is not well-formed because Simple value (with 5-bit value 24) must be >= 32. + // See RFC 7049 section 2.3 for details, instead of the incorrect example in RFC 7049 Appendex A. + // I reported an errata to RFC 7049 and Carsten Bormann confirmed at https://github.com/fxamacker/cbor/issues/46 + /* + { + hexDecode("f818"), + uint64(24), + []interface{}{uint8(24), uint16(24), uint32(24), uint64(24), uint(24), int8(24), int16(24), int32(24), int64(24), int(24), float32(24), float64(24)}, + []reflect.Type{typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt}, + }, + */ + { + hexDecode("f820"), + uint64(32), + []interface{}{uint8(32), uint16(32), uint32(32), uint64(32), uint(32), int8(32), int16(32), int32(32), int64(32), int(32), float32(32), float64(32), bigIntOrPanic("32")}, + []reflect.Type{typeByteSlice, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + { + hexDecode("f8ff"), + uint64(255), + []interface{}{uint8(255), uint16(255), uint32(255), uint64(255), uint(255), int16(255), int32(255), int64(255), int(255), float32(255), float64(255), bigIntOrPanic("255")}, + []reflect.Type{typeByteSlice, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + // More testcases not covered by https://tools.ietf.org/html/rfc7049#appendix-A. + { + hexDecode("5fff"), // empty indefinite length byte string + []byte{}, + []interface{}{[]byte{}, [0]byte{}, [1]byte{0x00}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("7fff"), // empty indefinite length text string + "", + []interface{}{""}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeBool, typeByteArray, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + }, + { + hexDecode("bfff"), // empty indefinite length map + map[interface{}]interface{}{}, + []interface{}{map[interface{}]interface{}{}, map[string]bool{}, map[string]int{}, map[int]string{}, map[int]bool{}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeTag, typeRawTag}, + }, + // More test data with tags + { + hexDecode("c13a0177f2cf"), // 1969-03-21T20:04:00Z, tag 1 with negative integer as epoch time + time.Date(1969, 3, 21, 20, 4, 0, 0, time.UTC), + []interface{}{int32(-24638160), int64(-24638160), int32(-24638160), int64(-24638160), float32(-24638160), float64(-24638160), time.Date(1969, 3, 21, 20, 4, 0, 0, time.UTC), Tag{1, int64(-24638160)}, RawTag{1, hexDecode("3a0177f2cf")}, bigIntOrPanic("-24638160")}, + []reflect.Type{typeUint8, typeUint16, typeInt8, typeInt16, typeByteSlice, typeString, typeBool, typeByteArray, typeIntSlice, typeMapStringInt}, + }, + { + hexDecode("d83dd183010203"), // 61(17([1, 2, 3])), nested tags 61 and 17 + Tag{61, Tag{17, []interface{}{uint64(1), uint64(2), uint64(3)}}}, + []interface{}{[]interface{}{uint64(1), uint64(2), uint64(3)}, []byte{1, 2, 3}, [0]byte{}, [1]byte{1}, [3]byte{1, 2, 3}, [5]byte{1, 2, 3, 0, 0}, []int{1, 2, 3}, []uint{1, 2, 3}, [...]int{1, 2, 3}, []float32{1, 2, 3}, []float64{1, 2, 3}, Tag{61, Tag{17, []interface{}{uint64(1), uint64(2), uint64(3)}}}, RawTag{61, hexDecode("d183010203")}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{})}, + }, +} + +type unmarshalFloatTest struct { + cborData []byte + emptyInterfaceValue interface{} + values []interface{} + wrongTypes []reflect.Type + equalityThreshold float64 // Not used for +inf, -inf, and NaN. +} + +// unmarshalFloatTests includes test values for float16, float32, and float64. +// Note: the function for float16 to float32 conversion was tested with all +// 65536 values, which is too many to include here. +var unmarshalFloatTests = []unmarshalFloatTest{ + // CBOR test data are from https://tools.ietf.org/html/rfc7049#appendix-A. + // float16 + { + hexDecode("f90000"), + float64(0.0), + []interface{}{float32(0.0), float64(0.0)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f98000"), + float64(-0.0), + []interface{}{float32(-0.0), float64(-0.0)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f93c00"), + float64(1.0), + []interface{}{float32(1.0), float64(1.0)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f93e00"), + float64(1.5), + []interface{}{float32(1.5), float64(1.5)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f97bff"), + float64(65504.0), + []interface{}{float32(65504.0), float64(65504.0)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f90001"), // float16 subnormal value + float64(5.960464477539063e-08), + []interface{}{float32(5.960464477539063e-08), float64(5.960464477539063e-08)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-16, + }, + { + hexDecode("f90400"), + float64(6.103515625e-05), + []interface{}{float32(6.103515625e-05), float64(6.103515625e-05)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-16, + }, + { + hexDecode("f9c400"), + float64(-4.0), + []interface{}{float32(-4.0), float64(-4.0)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f97c00"), + math.Inf(1), + []interface{}{math.Float32frombits(0x7f800000), math.Inf(1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f97e00"), + math.NaN(), + []interface{}{math.Float32frombits(0x7fc00000), math.NaN()}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f9fc00"), + math.Inf(-1), + []interface{}{math.Float32frombits(0xff800000), math.Inf(-1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + // float32 + { + hexDecode("fa47c35000"), + float64(100000.0), + []interface{}{float32(100000.0), float64(100000.0)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fa7f7fffff"), + float64(3.4028234663852886e+38), + []interface{}{float32(3.4028234663852886e+38), float64(3.4028234663852886e+38)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + { + hexDecode("fa7f800000"), + math.Inf(1), + []interface{}{math.Float32frombits(0x7f800000), math.Inf(1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fa7fc00000"), + math.NaN(), + []interface{}{math.Float32frombits(0x7fc00000), math.NaN()}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("faff800000"), + math.Inf(-1), + []interface{}{math.Float32frombits(0xff800000), math.Inf(-1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + // float64 + { + hexDecode("fb3ff199999999999a"), + float64(1.1), + []interface{}{float32(1.1), float64(1.1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + { + hexDecode("fb7e37e43c8800759c"), + float64(1.0e+300), + []interface{}{float64(1.0e+300)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + { + hexDecode("fbc010666666666666"), + float64(-4.1), + []interface{}{float32(-4.1), float64(-4.1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + { + hexDecode("fb7ff0000000000000"), + math.Inf(1), + []interface{}{math.Float32frombits(0x7f800000), math.Inf(1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fb7ff8000000000000"), + math.NaN(), + []interface{}{math.Float32frombits(0x7fc00000), math.NaN()}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fbfff0000000000000"), + math.Inf(-1), + []interface{}{math.Float32frombits(0xff800000), math.Inf(-1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + + // float16 test data from https://en.wikipedia.org/wiki/Half-precision_floating-point_format + { + hexDecode("f903ff"), + float64(0.000060976), + []interface{}{float32(0.000060976), float64(0.000060976)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + { + hexDecode("f93bff"), + float64(0.999511719), + []interface{}{float32(0.999511719), float64(0.999511719)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + { + hexDecode("f93c01"), + float64(1.000976563), + []interface{}{float32(1.000976563), float64(1.000976563)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + { + hexDecode("f93555"), + float64(0.333251953125), + []interface{}{float32(0.333251953125), float64(0.333251953125)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 1e-9, + }, + // CBOR test data "canonNums" are from https://github.com/cbor-wg/cbor-test-vectors + { + hexDecode("f9bd00"), + float64(-1.25), + []interface{}{float32(-1.25), float64(-1.25)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f93e00"), + float64(1.5), + []interface{}{float32(1.5), float64(1.5)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fb4024333333333333"), + float64(10.1), + []interface{}{float32(10.1), float64(10.1)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f90001"), + float64(5.960464477539063e-8), + []interface{}{float32(5.960464477539063e-8), float64(5.960464477539063e-8)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fa7f7fffff"), + float64(3.4028234663852886e+38), + []interface{}{float32(3.4028234663852886e+38), float64(3.4028234663852886e+38)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f90400"), + float64(0.00006103515625), + []interface{}{float32(0.00006103515625), float64(0.00006103515625)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("f933ff"), + float64(0.2498779296875), + []interface{}{float32(0.2498779296875), float64(0.2498779296875)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fa33000000"), + float64(2.9802322387695312e-8), + []interface{}{float32(2.9802322387695312e-8), float64(2.9802322387695312e-8)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fa33333866"), + float64(4.1727979294137185e-8), + []interface{}{float32(4.1727979294137185e-8), float64(4.1727979294137185e-8)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, + { + hexDecode("fa37002000"), + float64(0.000007636845111846924), + []interface{}{float32(0.000007636845111846924), float64(0.000007636845111846924)}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeByteArray, typeByteSlice, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag, typeBigInt}, + 0.0, + }, +} + +const invalidUTF8ErrorMsg = "cbor: invalid UTF-8 string" + +func hexDecode(s string) []byte { + data, err := hex.DecodeString(s) + if err != nil { + panic(err) + } + return data +} + +func bigIntOrPanic(s string) big.Int { + bi, ok := new(big.Int).SetString(s, 10) + if !ok { + panic("failed to convert " + s + " to big.Int") + } + return *bi +} + +func TestUnmarshal(t *testing.T) { + for _, tc := range unmarshalTests { + // Test unmarshalling CBOR into empty interface. + var v interface{} + if err := Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + if tm, ok := tc.emptyInterfaceValue.(time.Time); ok { + if vt, ok := v.(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } else if !reflect.DeepEqual(v, tc.emptyInterfaceValue) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } + // Test unmarshalling CBOR into RawMessage. + var r RawMessage + if err := Unmarshal(tc.cborData, &r); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else if !bytes.Equal(r, tc.cborData) { + t.Errorf("Unmarshal(0x%x) returned RawMessage %v, want %v", tc.cborData, r, tc.cborData) + } + // Test unmarshalling CBOR into compatible data types. + for _, value := range tc.values { + v := reflect.New(reflect.TypeOf(value)) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + if tm, ok := value.(time.Time); ok { + if vt, ok := v.Elem().Interface().(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v.Elem().Interface(), v.Elem().Interface(), value, value) + } + } else if !reflect.DeepEqual(v.Elem().Interface(), value) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v.Elem().Interface(), v.Elem().Interface(), value, value) + } + } + } + // Test unmarshalling CBOR into incompatible data types. + for _, typ := range tc.wrongTypes { + v := reflect.New(typ) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", tc.cborData, typ.String()) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", tc.cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborData, err.Error(), "cannot unmarshal") + } + } + } +} + +func TestUnmarshalFloat(t *testing.T) { + for _, tc := range unmarshalFloatTests { + // Test unmarshalling CBOR into empty interface. + var v interface{} + if err := Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + testFloat(t, tc.cborData, v, tc.emptyInterfaceValue, tc.equalityThreshold) + } + // Test unmarshalling CBOR into RawMessage. + var r RawMessage + if err := Unmarshal(tc.cborData, &r); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else if !bytes.Equal(r, tc.cborData) { + t.Errorf("Unmarshal(0x%x) returned RawMessage %v, want %v", tc.cborData, r, tc.cborData) + } + // Test unmarshalling CBOR into compatible data types. + for _, value := range tc.values { + v := reflect.New(reflect.TypeOf(value)) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + testFloat(t, tc.cborData, v.Elem().Interface(), value, tc.equalityThreshold) + } + } + // Test unmarshalling CBOR into incompatible data types. + for _, typ := range tc.wrongTypes { + v := reflect.New(typ) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", tc.cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborData, err.Error(), "cannot unmarshal") + } + } + } +} + +func testFloat(t *testing.T, cborData []byte, f interface{}, wantf interface{}, equalityThreshold float64) { + switch wantf := wantf.(type) { + case float32: + f, ok := f.(float32) + if !ok { + t.Errorf("Unmarshal(0x%x) returned value of type %T, want float32", cborData, f) + return + } + if math.IsNaN(float64(wantf)) { + if !math.IsNaN(float64(f)) { + t.Errorf("Unmarshal(0x%x) = %f, want NaN", cborData, f) + } + } else if math.IsInf(float64(wantf), 0) { + if f != wantf { + t.Errorf("Unmarshal(0x%x) = %f, want %f", cborData, f, wantf) + } + } else if math.Abs(float64(f-wantf)) > equalityThreshold { + t.Errorf("Unmarshal(0x%x) = %.18f, want %.18f, diff %.18f > threshold %.18f", cborData, f, wantf, math.Abs(float64(f-wantf)), equalityThreshold) + } + case float64: + f, ok := f.(float64) + if !ok { + t.Errorf("Unmarshal(0x%x) returned value of type %T, want float64", cborData, f) + return + } + if math.IsNaN(wantf) { + if !math.IsNaN(f) { + t.Errorf("Unmarshal(0x%x) = %f, want NaN", cborData, f) + } + } else if math.IsInf(wantf, 0) { + if f != wantf { + t.Errorf("Unmarshal(0x%x) = %f, want %f", cborData, f, wantf) + } + } else if math.Abs(f-wantf) > equalityThreshold { + t.Errorf("Unmarshal(0x%x) = %.18f, want %.18f, diff %.18f > threshold %.18f", cborData, f, wantf, math.Abs(f-wantf), equalityThreshold) + } + } +} + +func TestNegIntOverflow(t *testing.T) { + cborData := hexDecode("3bffffffffffffffff") // -18446744073709551616 + + // Decode CBOR neg int that overflows Go int64 to empty interface + var v1 interface{} + wantObj := bigIntOrPanic("-18446744073709551616") + if err := Unmarshal(cborData, &v1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", cborData, err) + } else if !reflect.DeepEqual(v1, wantObj) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", cborData, v1, v1, wantObj, wantObj) + } + + // Decode CBOR neg int that overflows Go int64 to big.Int + var v2 big.Int + if err := Unmarshal(cborData, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", cborData, err) + } else if !reflect.DeepEqual(v2, wantObj) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", cborData, v2, v2, wantObj, wantObj) + } + + // Decode CBOR neg int that overflows Go int64 to int64 + var v3 int64 + if err := Unmarshal(cborData, &v3); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), "cannot unmarshal") + } +} + +func TestUnmarshalIntoPtrPrimitives(t *testing.T) { + cborDataInt := hexDecode("1818") // 24 + cborDataString := hexDecode("7f657374726561646d696e67ff") // "streaming" + + const wantInt = 24 + const wantString = "streaming" + + var p1 *int + var p2 *string + var p3 *RawMessage + + var i int + pi := &i + ppi := &pi + + var s string + ps := &s + pps := &ps + + var r RawMessage + pr := &r + ppr := &pr + + // Unmarshal CBOR integer into a non-nil pointer. + if err := Unmarshal(cborDataInt, &ppi); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborDataInt, err) + } else if i != wantInt { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %d", cborDataInt, i, i, wantInt) + } + // Unmarshal CBOR integer into a nil pointer. + if err := Unmarshal(cborDataInt, &p1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborDataInt, err) + } else if *p1 != wantInt { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %d", cborDataInt, *pi, pi, wantInt) + } + + // Unmarshal CBOR string into a non-nil pointer. + if err := Unmarshal(cborDataString, &pps); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborDataString, err) + } else if s != wantString { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborDataString, s, s, wantString) + } + // Unmarshal CBOR string into a nil pointer. + if err := Unmarshal(cborDataString, &p2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborDataString, err) + } else if *p2 != wantString { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborDataString, *p2, p2, wantString) + } + + // Unmarshal CBOR string into a non-nil RawMessage. + if err := Unmarshal(cborDataString, &ppr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborDataString, err) + } else if !bytes.Equal(r, cborDataString) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborDataString, r, r, cborDataString) + } + // Unmarshal CBOR string into a nil pointer to RawMessage. + if err := Unmarshal(cborDataString, &p3); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborDataString, err) + } else if !bytes.Equal(*p3, cborDataString) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborDataString, *p3, p3, cborDataString) + } +} + +func TestUnmarshalIntoPtrArrayPtrElem(t *testing.T) { + cborData := hexDecode("83010203") // []int{1, 2, 3} + + n1, n2, n3 := 1, 2, 3 + + wantArray := []*int{&n1, &n2, &n3} + + var p *[]*int + + var slc []*int + pslc := &slc + ppslc := &pslc + + // Unmarshal CBOR array into a non-nil pointer. + if err := Unmarshal(cborData, &ppslc); err != nil { + t.Errorf("Unmarshal(0x%x, %s) returned error %v", cborData, reflect.TypeOf(ppslc), err) + } else if !reflect.DeepEqual(slc, wantArray) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborData, slc, slc, wantArray) + } + // Unmarshal CBOR array into a nil pointer. + if err := Unmarshal(cborData, &p); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(*p, wantArray) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborData, *p, p, wantArray) + } +} + +func TestUnmarshalIntoPtrMapPtrElem(t *testing.T) { + cborData := hexDecode("a201020304") // {1: 2, 3: 4} + + n1, n2, n3, n4 := 1, 2, 3, 4 + + wantMap := map[int]*int{n1: &n2, n3: &n4} + + var p *map[int]*int + + var m map[int]*int + pm := &m + ppm := &pm + + // Unmarshal CBOR map into a non-nil pointer. + if err := Unmarshal(cborData, &ppm); err != nil { + t.Errorf("Unmarshal(0x%x, %s) returned error %v", cborData, reflect.TypeOf(ppm), err) + } else if !reflect.DeepEqual(m, wantMap) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborData, m, m, wantMap) + } + // Unmarshal CBOR map into a nil pointer. + if err := Unmarshal(cborData, &p); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(*p, wantMap) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborData, *p, p, wantMap) + } +} + +func TestUnmarshalIntoPtrStructPtrElem(t *testing.T) { + type s1 struct { + A *string `cbor:"a"` + B *string `cbor:"b"` + C *string `cbor:"c"` + D *string `cbor:"d"` + E *string `cbor:"e"` + } + + cborData := hexDecode("a56161614161626142616361436164614461656145") // map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E"} + + a, b, c, d, e := "A", "B", "C", "D", "E" + wantObj := s1{A: &a, B: &b, C: &c, D: &d, E: &e} + + var p *s1 + + var s s1 + ps := &s + pps := &ps + + // Unmarshal CBOR map into a non-nil pointer. + if err := Unmarshal(cborData, &pps); err != nil { + t.Errorf("Unmarshal(0x%x, %s) returned error %v", cborData, reflect.TypeOf(pps), err) + } else if !reflect.DeepEqual(s, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborData, s, s, wantObj) + } + // Unmarshal CBOR map into a nil pointer. + if err := Unmarshal(cborData, &p); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(*p, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v", cborData, *p, p, wantObj) + } +} + +func TestUnmarshalIntoArray(t *testing.T) { + cborData := hexDecode("83010203") // []int{1, 2, 3} + + // Unmarshal CBOR array into Go array. + var arr1 [3]int + if err := Unmarshal(cborData, &arr1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if arr1 != [3]int{1, 2, 3} { + t.Errorf("Unmarshal(0x%x) = %v (%T), want [3]int{1, 2, 3}", cborData, arr1, arr1) + } + + // Unmarshal CBOR array into Go array with more elements. + var arr2 [5]int + if err := Unmarshal(cborData, &arr2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if arr2 != [5]int{1, 2, 3, 0, 0} { + t.Errorf("Unmarshal(0x%x) = %v (%T), want [5]int{1, 2, 3, 0, 0}", cborData, arr2, arr2) + } + + // Unmarshal CBOR array into Go array with less elements. + var arr3 [1]int + if err := Unmarshal(cborData, &arr3); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if arr3 != [1]int{1} { + t.Errorf("Unmarshal(0x%x) = %v (%T), want [0]int{1}", cborData, arr3, arr3) + } +} + +type nilUnmarshaler string + +func (s *nilUnmarshaler) UnmarshalCBOR(data []byte) error { + if len(data) == 1 && (data[0] == 0xf6 || data[0] == 0xf7) { + *s = "null" + } else { + *s = nilUnmarshaler(data) + } + return nil +} + +func TestUnmarshalNil(t *testing.T) { + type T struct { + I int + } + + cborData := [][]byte{hexDecode("f6"), hexDecode("f7")} // CBOR null and undefined values + + testCases := []struct { + name string + value interface{} + wantValue interface{} + }{ + // Unmarshalling CBOR null to the following types is a no-op. + {"bool", true, true}, + {"int", int(-1), int(-1)}, + {"int8", int8(-2), int8(-2)}, + {"int16", int16(-3), int16(-3)}, + {"int32", int32(-4), int32(-4)}, + {"int64", int64(-5), int64(-5)}, + {"uint", uint(1), uint(1)}, + {"uint8", uint8(2), uint8(2)}, + {"uint16", uint16(3), uint16(3)}, + {"uint32", uint32(4), uint32(4)}, + {"uint64", uint64(5), uint64(5)}, + {"float32", float32(1.23), float32(1.23)}, + {"float64", float64(4.56), float64(4.56)}, + {"string", "hello", "hello"}, + {"array", [3]int{1, 2, 3}, [3]int{1, 2, 3}}, + + // Unmarshalling CBOR null to slice/map sets Go values to nil. + {"[]byte", []byte{1, 2, 3}, []byte(nil)}, + {"slice", []string{"hello", "world"}, []string(nil)}, + {"map", map[string]bool{"hello": true, "goodbye": false}, map[string]bool(nil)}, + + // Unmarshalling CBOR null to time.Time is a no-op. + {"time.Time", time.Date(2020, time.January, 2, 3, 4, 5, 6, time.UTC), time.Date(2020, time.January, 2, 3, 4, 5, 6, time.UTC)}, + + // Unmarshalling CBOR null to big.Int is a no-op. + {"big.Int", bigIntOrPanic("123"), bigIntOrPanic("123")}, + + // Unmarshalling CBOR null to user defined struct types is a no-op. + {"user defined struct", T{I: 123}, T{I: 123}}, + + // Unmarshalling CBOR null to cbor.Tag and cbor.RawTag is a no-op. + {"cbor.RawTag", RawTag{123, []byte{4, 5, 6}}, RawTag{123, []byte{4, 5, 6}}}, + {"cbor.Tag", Tag{123, "hello world"}, Tag{123, "hello world"}}, + + // Unmarshalling to cbor.RawMessage sets cbor.RawMessage to raw CBOR bytes (0xf6 or 0xf7). + // It's tested in TestUnmarshal(). + + // Unmarshalling to types implementing cbor.BinaryUnmarshaler is a no-op. + //{"cbor.BinaryUnmarshaler", nilBinaryUnmarshaler("hello world"), nilBinaryUnmarshaler("hello world")}, + {"cbor.BinaryUnmarshaler", number(456), number(456)}, + + // When unmarshalling to types implementing cbor.Unmarshaler, + // UnmarshalCBOR function receives raw CBOR bytes (0xf6 or 0xf7). + {"cbor.Unmarshaler", nilUnmarshaler("hello world"), nilUnmarshaler("null")}, + } + + // Unmarshalling to values of specified Go types. + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + for _, data := range cborData { + v := reflect.New(reflect.TypeOf(tc.value)) + v.Elem().Set(reflect.ValueOf(tc.value)) + + if err := Unmarshal(data, v.Interface()); err != nil { + t.Errorf("Unmarshal(0x%x) to %T returned error %v", data, v.Elem().Interface(), err) + } else if !reflect.DeepEqual(v.Elem().Interface(), tc.wantValue) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", data, v.Elem().Interface(), v.Elem().Interface(), tc.wantValue, tc.wantValue) + } + } + }) + } +} + +var invalidUnmarshalTests = []struct { + name string + v interface{} + wantErrorMsg string +}{ + {"unmarshal into nil interface{}", nil, "cbor: Unmarshal(nil)"}, + {"unmarshal into non-pointer value", 5, "cbor: Unmarshal(non-pointer int)"}, + {"unmarshal into nil pointer", (*int)(nil), "cbor: Unmarshal(nil *int)"}, +} + +func TestInvalidUnmarshal(t *testing.T) { + cborData := []byte{0x00} + + for _, tc := range invalidUnmarshalTests { + t.Run(tc.name, func(t *testing.T) { + err := Unmarshal(cborData, tc.v) + if err == nil { + t.Errorf("Unmarshal(0x%x, %v) didn't return an error", cborData, tc.v) + } else if _, ok := err.(*InvalidUnmarshalError); !ok { + t.Errorf("Unmarshal(0x%x, %v) error type %T, want *InvalidUnmarshalError", cborData, tc.v, err) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x, %v) error %q, want %q", cborData, tc.v, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +var invalidCBORUnmarshalTests = []struct { + name string + cborData []byte + wantErrorMsg string + errorMsgPartialMatch bool +}{ + {"Nil data", []byte(nil), "EOF", false}, + {"Empty data", []byte{}, "EOF", false}, + {"Tag number not followed by tag content", []byte{0xc0}, "unexpected EOF", false}, + {"Definite length strings with tagged chunk", hexDecode("5fc64401020304ff"), "cbor: wrong element type tag for indefinite-length byte string", false}, + {"Definite length strings with tagged chunk", hexDecode("7fc06161ff"), "cbor: wrong element type tag for indefinite-length UTF-8 text string", false}, + {"Indefinite length strings with invalid head", hexDecode("7f61"), "unexpected EOF", false}, + {"Invalid nested tag number", hexDecode("d864dc1a514b67b0"), "cbor: invalid additional information", true}, + // Data from 7049bis G.1 + // Premature end of the input + {"End of input in a head", hexDecode("18"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("19"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("1a"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("1b"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("1901"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("1a0102"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("1b01020304050607"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("38"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("58"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("78"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("98"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("9a01ff00"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("b8"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("d8"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("f8"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("f900"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("fa0000"), "unexpected EOF", false}, + {"End of input in a head", hexDecode("fb000000"), "unexpected EOF", false}, + {"Definite length strings with short data", hexDecode("41"), "unexpected EOF", false}, + {"Definite length strings with short data", hexDecode("61"), "unexpected EOF", false}, + {"Definite length strings with short data", hexDecode("5affffffff00"), "unexpected EOF", false}, + {"Definite length strings with short data", hexDecode("5bffffffffffffffff010203"), "cbor: byte string length 18446744073709551615 is too large, causing integer overflow", false}, + {"Definite length strings with short data", hexDecode("7affffffff00"), "unexpected EOF", false}, + {"Definite length strings with short data", hexDecode("7b7fffffffffffffff010203"), "unexpected EOF", false}, + {"Definite length maps and arrays not closed with enough items", hexDecode("81"), "unexpected EOF", false}, + {"Definite length maps and arrays not closed with enough items", hexDecode("818181818181818181"), "unexpected EOF", false}, + {"Definite length maps and arrays not closed with enough items", hexDecode("8200"), "unexpected EOF", false}, + {"Definite length maps and arrays not closed with enough items", hexDecode("a1"), "unexpected EOF", false}, + {"Definite length maps and arrays not closed with enough items", hexDecode("a20102"), "unexpected EOF", false}, + {"Definite length maps and arrays not closed with enough items", hexDecode("a100"), "unexpected EOF", false}, + {"Definite length maps and arrays not closed with enough items", hexDecode("a2000000"), "unexpected EOF", false}, + {"Indefinite length strings not closed by a break stop code", hexDecode("5f4100"), "unexpected EOF", false}, + {"Indefinite length strings not closed by a break stop code", hexDecode("7f6100"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("9f"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("9f0102"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("bf"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("bf01020102"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("819f"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("9f8000"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("9f9f9f9f9fffffffff"), "unexpected EOF", false}, + {"Indefinite length maps and arrays not closed by a break stop code", hexDecode("9f819f819f9fffffff"), "unexpected EOF", false}, + // Five subkinds of well-formedness error kind 3 (syntax error) + {"Reserved additional information values", hexDecode("3e"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("5c"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("5d"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("5e"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("7c"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("7d"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("7e"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("9c"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("9d"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("9e"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("bc"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("bd"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("be"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("dc"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("dd"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("de"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("fc"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("fd"), "cbor: invalid additional information", true}, + {"Reserved additional information values", hexDecode("fe"), "cbor: invalid additional information", true}, + {"Reserved two-byte encodings of simple types", hexDecode("f800"), "cbor: invalid simple value 0 for type primitives", true}, + {"Reserved two-byte encodings of simple types", hexDecode("f801"), "cbor: invalid simple value 1 for type primitives", true}, + {"Reserved two-byte encodings of simple types", hexDecode("f818"), "cbor: invalid simple value 24 for type primitives", true}, + {"Reserved two-byte encodings of simple types", hexDecode("f81f"), "cbor: invalid simple value 31 for type primitives", true}, + {"Indefinite length string chunks not of the correct type", hexDecode("5f00ff"), "cbor: wrong element type positive integer for indefinite-length byte string", false}, + {"Indefinite length string chunks not of the correct type", hexDecode("5f21ff"), "cbor: wrong element type negative integer for indefinite-length byte string", false}, + {"Indefinite length string chunks not of the correct type", hexDecode("5f6100ff"), "cbor: wrong element type UTF-8 text string for indefinite-length byte string", false}, + {"Indefinite length string chunks not of the correct type", hexDecode("5f80ff"), "cbor: wrong element type array for indefinite-length byte string", false}, + {"Indefinite length string chunks not of the correct type", hexDecode("5fa0ff"), "cbor: wrong element type map for indefinite-length byte string", false}, + {"Indefinite length string chunks not of the correct type", hexDecode("5fc000ff"), "cbor: wrong element type tag for indefinite-length byte string", false}, + {"Indefinite length string chunks not of the correct type", hexDecode("5fe0ff"), "cbor: wrong element type primitives for indefinite-length byte string", false}, + {"Indefinite length string chunks not of the correct type", hexDecode("7f4100ff"), "cbor: wrong element type byte string for indefinite-length UTF-8 text string", false}, + {"Indefinite length string chunks not definite length", hexDecode("5f5f4100ffff"), "cbor: indefinite-length byte string chunk is not definite-length", false}, + {"Indefinite length string chunks not definite length", hexDecode("7f7f6100ffff"), "cbor: indefinite-length UTF-8 text string chunk is not definite-length", false}, + {"Break occurring on its own outside of an indefinite length item", hexDecode("ff"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("81ff"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("8200ff"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("a1ff"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("a1ff00"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("a100ff"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("a20000ff"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("9f81ff"), "cbor: unexpected \"break\" code", true}, + {"Break occurring in a definite length array or map or a tag", hexDecode("9f829f819f9fffffffff"), "cbor: unexpected \"break\" code", true}, + {"Break in indefinite length map would lead to odd number of items (break in a value position)", hexDecode("bf00ff"), "cbor: unexpected \"break\" code", true}, + {"Break in indefinite length map would lead to odd number of items (break in a value position)", hexDecode("bf000000ff"), "cbor: unexpected \"break\" code", true}, + {"Major type 0 with additional information 31", hexDecode("1f"), "cbor: invalid additional information 31 for type positive integer", true}, + {"Major type 1 with additional information 31", hexDecode("3f"), "cbor: invalid additional information 31 for type negative integer", true}, + {"Major type 6 with additional information 31", hexDecode("df"), "cbor: invalid additional information 31 for type tag", true}, +} + +func TestInvalidCBORUnmarshal(t *testing.T) { + for _, tc := range invalidCBORUnmarshalTests { + t.Run(tc.name, func(t *testing.T) { + var i interface{} + err := Unmarshal(tc.cborData, &i) + if err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if !tc.errorMsgPartialMatch && err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } else if tc.errorMsgPartialMatch && !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestInvalidUTF8TextString(t *testing.T) { + invalidUTF8TextStringTests := []struct { + name string + cborData []byte + wantErrorMsg string + }{ + {"definite length text string", hexDecode("61fe"), invalidUTF8ErrorMsg}, + {"indefinite length text string", hexDecode("7f62e6b061b4ff"), invalidUTF8ErrorMsg}, + } + for _, tc := range invalidUTF8TextStringTests { + t.Run(tc.name, func(t *testing.T) { + var i interface{} + if err := Unmarshal(tc.cborData, &i); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + + var s string + if err := Unmarshal(tc.cborData, &s); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } + // Test decoding of mixed invalid text string and valid text string + cborData := hexDecode("7f62e6b061b4ff7f657374726561646d696e67ff") + dec := NewDecoder(bytes.NewReader(cborData)) + var s string + if err := dec.Decode(&s); err == nil { + t.Errorf("Decode() didn't return an error") + } else if s != "" { + t.Errorf("Decode() returned %q, want %q", s, "") + } + if err := dec.Decode(&s); err != nil { + t.Errorf("Decode() returned error %v", err) + } else if s != "streaming" { + t.Errorf("Decode() returned %q, want %q", s, "streaming") + } +} + +func TestUnmarshalStruct(t *testing.T) { + want := outer{ + IntField: 123, + FloatField: 100000.0, + BoolField: true, + StringField: "test", + ByteStringField: []byte{1, 3, 5}, + ArrayField: []string{"hello", "world"}, + MapField: map[string]bool{"morning": true, "afternoon": false}, + NestedStructField: &inner{X: 1000, Y: 1000000}, + unexportedField: 0, + } + + tests := []struct { + name string + cborData []byte + want interface{} + }{ + {"case-insensitive field name match", hexDecode("a868696e746669656c64187b6a666c6f61746669656c64fa47c3500069626f6f6c6669656c64f56b537472696e674669656c6464746573746f42797465537472696e674669656c64430103056a41727261794669656c64826568656c6c6f65776f726c64684d61704669656c64a2676d6f726e696e67f56961667465726e6f6f6ef4714e65737465645374727563744669656c64a261581903e861591a000f4240"), want}, + {"exact field name match", hexDecode("a868496e744669656c64187b6a466c6f61744669656c64fa47c3500069426f6f6c4669656c64f56b537472696e674669656c6464746573746f42797465537472696e674669656c64430103056a41727261794669656c64826568656c6c6f65776f726c64684d61704669656c64a2676d6f726e696e67f56961667465726e6f6f6ef4714e65737465645374727563744669656c64a261581903e861591a000f4240"), want}, + } + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + var v outer + if err := Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v, v, want, want) + } + }) + } +} + +func TestUnmarshalStructError1(t *testing.T) { + type outer2 struct { + IntField int + FloatField float32 + BoolField bool + StringField string + ByteStringField []byte + ArrayField []int // wrong type + MapField map[string]bool + NestedStructField map[int]string // wrong type + unexportedField int64 + } + want := outer2{ + IntField: 123, + FloatField: 100000.0, + BoolField: true, + StringField: "test", + ByteStringField: []byte{1, 3, 5}, + ArrayField: []int{0, 0}, + MapField: map[string]bool{"morning": true, "afternoon": false}, + NestedStructField: map[int]string{}, + unexportedField: 0, + } + + cborData := hexDecode("a868496e744669656c64187b6a466c6f61744669656c64fa47c3500069426f6f6c4669656c64f56b537472696e674669656c6464746573746f42797465537472696e674669656c64430103056a41727261794669656c64826568656c6c6f65776f726c64684d61704669656c64a2676d6f726e696e67f56961667465726e6f6f6ef4714e65737465645374727563744669656c64a261581903e861591a000f4240") + wantCBORType := "UTF-8 text string" + wantGoType := "int" + wantStructFieldName := "cbor.outer2.ArrayField" + wantErrorMsg := "cannot unmarshal UTF-8 text string into Go struct field cbor.outer2.ArrayField of type int" + + var v outer2 + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else { + if typeError, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*UnmarshalTypeError)", cborData, err) + } else { + if typeError.CBORType != wantCBORType { + t.Errorf("Unmarshal(0x%x) returned (*UnmarshalTypeError).CBORType %s, want %s", cborData, typeError.CBORType, wantCBORType) + } + if typeError.GoType != wantGoType { + t.Errorf("Unmarshal(0x%x) returned (*UnmarshalTypeError).GoType %s, want %s", cborData, typeError.GoType, wantGoType) + } + if typeError.StructFieldName != wantStructFieldName { + t.Errorf("Unmarshal(0x%x) returned (*UnmarshalTypeError).StructFieldName %s, want %s", cborData, typeError.StructFieldName, wantStructFieldName) + } + if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + } + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, want, want) + } +} + +func TestUnmarshalStructError2(t *testing.T) { + // Unmarshal integer and invalid UTF8 string as field name into struct + type strc struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + } + want := strc{ + A: "A", + } + + // Unmarshal returns first error encountered, which is *UnmarshalTypeError (failed to unmarshal int into Go string) + cborData := hexDecode("a3fa47c35000026161614161fe6142") // {100000.0:2, "a":"A", 0xfe: B} + wantCBORType := "primitives" + wantGoType := "string" + wantErrorMsg := "cannot unmarshal primitives into Go value of type string" + + v := strc{} + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else { + if typeError, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*UnmarshalTypeError)", cborData, err) + } else { + if typeError.CBORType != wantCBORType { + t.Errorf("Unmarshal(0x%x) returned (*UnmarshalTypeError).CBORType %s, want %s", cborData, typeError.CBORType, wantCBORType) + } + if typeError.GoType != wantGoType { + t.Errorf("Unmarshal(0x%x) returned (*UnmarshalTypeError).GoType %s, want %s", cborData, typeError.GoType, wantGoType) + } + if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + } + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, want, want) + } + + // Unmarshal returns first error encountered, which is *cbor.SemanticError (invalid UTF8 string) + cborData = hexDecode("a361fe6142010261616141") // {0xfe: B, 1:2, "a":"A"} + v = strc{} + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else { + if _, ok := err.(*SemanticError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*SemanticError)", cborData, err) + } else if err.Error() != invalidUTF8ErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want error %q", cborData, err.Error(), invalidUTF8ErrorMsg) + } + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, want, want) + } + + // Unmarshal returns first error encountered, which is *cbor.SemanticError (invalid UTF8 string) + cborData = hexDecode("a3616261fe010261616141") // {"b": 0xfe, 1:2, "a":"A"} + v = strc{} + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else { + if _, ok := err.(*SemanticError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*SemanticError)", cborData, err) + } else if err.Error() != invalidUTF8ErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want error %q", cborData, err.Error(), invalidUTF8ErrorMsg) + } + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, want, want) + } +} + +func TestUnmarshalPrefilledArray(t *testing.T) { + prefilledArr := []int{1, 2, 3, 4, 5} + want := []int{10, 11, 3, 4, 5} + cborData := hexDecode("820a0b") // []int{10, 11} + if err := Unmarshal(cborData, &prefilledArr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if len(prefilledArr) != 2 || cap(prefilledArr) != 5 { + t.Errorf("Unmarshal(0x%x) = %v (len %d, cap %d), want len == 2, cap == 5", cborData, prefilledArr, len(prefilledArr), cap(prefilledArr)) + } + if !reflect.DeepEqual(prefilledArr[:cap(prefilledArr)], want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, prefilledArr, prefilledArr, want, want) + } + + cborData = hexDecode("80") // empty array + if err := Unmarshal(cborData, &prefilledArr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if len(prefilledArr) != 0 || cap(prefilledArr) != 0 { + t.Errorf("Unmarshal(0x%x) = %v (len %d, cap %d), want len == 0, cap == 0", cborData, prefilledArr, len(prefilledArr), cap(prefilledArr)) + } +} + +func TestUnmarshalPrefilledMap(t *testing.T) { + prefilledMap := map[string]string{"key": "value", "a": "1"} + want := map[string]string{"key": "value", "a": "A", "b": "B", "c": "C", "d": "D", "e": "E"} + cborData := hexDecode("a56161614161626142616361436164614461656145") // map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E"} + if err := Unmarshal(cborData, &prefilledMap); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(prefilledMap, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, prefilledMap, prefilledMap, want, want) + } + + prefilledMap = map[string]string{"key": "value"} + want = map[string]string{"key": "value"} + cborData = hexDecode("a0") // map[string]string{} + if err := Unmarshal(cborData, &prefilledMap); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(prefilledMap, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, prefilledMap, prefilledMap, want, want) + } +} + +func TestUnmarshalPrefilledStruct(t *testing.T) { + type s struct { + a int + B []int + C bool + } + prefilledStruct := s{a: 100, B: []int{200, 300, 400, 500}, C: true} + want := s{a: 100, B: []int{2, 3}, C: true} + cborData := hexDecode("a26161016162820203") // map[string]interface{} {"a": 1, "b": []int{2, 3}} + if err := Unmarshal(cborData, &prefilledStruct); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(prefilledStruct, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, prefilledStruct, prefilledStruct, want, want) + } + if len(prefilledStruct.B) != 2 || cap(prefilledStruct.B) != 4 { + t.Errorf("Unmarshal(0x%x) = %v (len %d, cap %d), want len == 2, cap == 5", cborData, prefilledStruct.B, len(prefilledStruct.B), cap(prefilledStruct.B)) + } + if !reflect.DeepEqual(prefilledStruct.B[:cap(prefilledStruct.B)], []int{2, 3, 400, 500}) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, prefilledStruct.B, prefilledStruct.B, []int{2, 3, 400, 500}, []int{2, 3, 400, 500}) + } +} + +func TestStructFieldNil(t *testing.T) { + type TestStruct struct { + I int + PI *int + PPI **int + } + var struc TestStruct + cborData, err := Marshal(struc) + if err != nil { + t.Fatalf("Marshal(%+v) returned error %v", struc, err) + } + var struc2 TestStruct + err = Unmarshal(cborData, &struc2) + if err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(struc, struc2) { + t.Errorf("Unmarshal(0x%x) returned %+v, want %+v", cborData, struc2, struc) + } +} + +func TestLengthOverflowsInt(t *testing.T) { + // Data is generating by go-fuzz. + // string/slice/map length in uint64 cast to int causes integer overflow. + cborData := [][]byte{ + hexDecode("bbcf30303030303030cfd697829782"), + hexDecode("5bcf30303030303030cfd697829782"), + } + wantErrorMsg := "is too large" + for _, data := range cborData { + var intf interface{} + if err := Unmarshal(data, &intf); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error containing substring %q", data, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing substring %q", data, err.Error(), wantErrorMsg) + } + } +} + +func TestMapKeyUnhashable(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantErrorMsg string + }{ + {"slice as map key", hexDecode("bf8030ff"), "cbor: invalid map key type: []interface {}"}, // {[]: -17} + {"slice as map key", hexDecode("a1813030"), "cbor: invalid map key type: []interface {}"}, // {[-17]: -17} + {"slice as map key", hexDecode("bfd1a388f730303030303030303030303030ff"), "cbor: invalid map key type: []interface {}"}, // {17({[undefined, -17, -17, -17, -17, -17, -17, -17]: -17, -17: -17}): -17}} + {"byte slice as map key", hexDecode("8f3030a730304430303030303030303030303030303030303030303030303030303030"), "cbor: invalid map key type: []uint8"}, // [-17, -17, {-17: -17, h'30303030': -17}, -17, -17, -17, -17, -17, -17, -17, -17, -17, -17, -17, -17] + {"map as map key", hexDecode("bf30a1a030ff"), "cbor: invalid map key type: map"}, // {-17: {{}: -17}}, empty map as map key + {"map as map key", hexDecode("bfb0303030303030303030303030303030303030303030303030303030303030303030ff"), "cbor: invalid map key type: map"}, // {{-17: -17}: -17}, map as key + {"tagged slice as map key", hexDecode("a1c84c30303030303030303030303030"), "cbor: invalid map key type: cbor.Tag"}, // {8(h'303030303030303030303030'): -17} + {"nested-tagged slice as map key", hexDecode("a33030306430303030d1cb4030"), "cbor: invalid map key type: cbor.Tag"}, // {-17: "0000", 17(11(h'')): -17} + {"big.Int as map key", hexDecode("a13bbd3030303030303030"), "cbor: invalid map key type: big.Int"}, // {-13632449055575519281: -17} + {"tagged big.Int as map key", hexDecode("a1c24901000000000000000030"), "cbor: invalid map key type: big.Int"}, // {18446744073709551616: -17} + {"tagged big.Int as map key", hexDecode("a1c34901000000000000000030"), "cbor: invalid map key type: big.Int"}, //{-18446744073709551617: -17} + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v interface{} + if err := Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + if _, ok := v.(map[interface{}]interface{}); ok { + var v map[interface{}]interface{} + if err := Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + } + }) + } +} + +func TestMapKeyNaN(t *testing.T) { + // Data is generating by go-fuzz. + cborData := hexDecode("b0303030303030303030303030303030303038303030faffff30303030303030303030303030") // {-17: -17, NaN: -17} + var intf interface{} + if err := Unmarshal(cborData, &intf); err != nil { + t.Fatalf("Unmarshal(0x%x) returned error %v", cborData, err) + } + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + if _, err := em.Marshal(intf); err != nil { + t.Errorf("Marshal(%v) returned error %v", intf, err) + } +} + +func TestUnmarshalUndefinedElement(t *testing.T) { + // Data is generating by go-fuzz. + cborData := hexDecode("bfd1a388f730303030303030303030303030ff") // {17({[undefined, -17, -17, -17, -17, -17, -17, -17]: -17, -17: -17}): -17} + var intf interface{} + wantErrorMsg := "invalid map key type" + if err := Unmarshal(cborData, &intf); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error containing substring %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing substring %q", cborData, err.Error(), wantErrorMsg) + } +} + +func TestMapKeyNil(t *testing.T) { + testData := [][]byte{ + hexDecode("a1f630"), // {null: -17} + } + want := map[interface{}]interface{}{nil: int64(-17)} + for _, data := range testData { + var intf interface{} + if err := Unmarshal(data, &intf); err != nil { + t.Fatalf("Unmarshal(0x%x) returned error %v", data, err) + } else if !reflect.DeepEqual(intf, want) { + t.Errorf("Unmarshal(0x%x) returned %+v, want %+v", data, intf, want) + } + if _, err := Marshal(intf); err != nil { + t.Errorf("Marshal(%v) returned error %v", intf, err) + } + + var v map[interface{}]interface{} + if err := Unmarshal(data, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", data, err) + } else if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) returned %+v, want %+v", data, v, want) + } + if _, err := Marshal(v); err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + } +} + +func TestDecodeTime(t *testing.T) { + testCases := []struct { + name string + cborRFC3339Time []byte + cborUnixTime []byte + wantTime time.Time + }{ + // Decoding CBOR null/defined to time.Time is no-op. See TestUnmarshalNil. + { + name: "NaN", + cborRFC3339Time: hexDecode("f97e00"), + cborUnixTime: hexDecode("f97e00"), + wantTime: time.Time{}, + }, + { + name: "positive infinity", + cborRFC3339Time: hexDecode("f97c00"), + cborUnixTime: hexDecode("f97c00"), + wantTime: time.Time{}, + }, + { + name: "negative infinity", + cborRFC3339Time: hexDecode("f9fc00"), + cborUnixTime: hexDecode("f9fc00"), + wantTime: time.Time{}, + }, + { + name: "time without fractional seconds", // positive integer + cborRFC3339Time: hexDecode("74323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("1a514b67b0"), + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + { + name: "time with fractional seconds", // float + cborRFC3339Time: hexDecode("7819313937302d30312d30315432313a34363a34302d30363a3030"), + cborUnixTime: hexDecode("fa47c35000"), + wantTime: parseTime(time.RFC3339Nano, "1970-01-01T21:46:40-06:00"), + }, + { + name: "time with fractional seconds", // float + cborRFC3339Time: hexDecode("76323031332d30332d32315432303a30343a30302e355a"), + cborUnixTime: hexDecode("fb41d452d9ec200000"), + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00.5Z"), + }, + { + name: "time before January 1, 1970 UTC without fractional seconds", // negative integer + cborRFC3339Time: hexDecode("74313936392d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("3a0177f2cf"), + wantTime: parseTime(time.RFC3339Nano, "1969-03-21T20:04:00Z"), + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + tm := time.Now() + if err := Unmarshal(tc.cborRFC3339Time, &tm); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborRFC3339Time, err) + } else if !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborRFC3339Time, tm, tm, tc.wantTime, tc.wantTime) + } + tm = time.Now() + if err := Unmarshal(tc.cborUnixTime, &tm); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborUnixTime, err) + } else if !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborUnixTime, tm, tm, tc.wantTime, tc.wantTime) + } + }) + } +} + +func TestDecodeTimeWithTag(t *testing.T) { + testCases := []struct { + name string + cborRFC3339Time []byte + cborUnixTime []byte + wantTime time.Time + }{ + { + name: "time without fractional seconds", // positive integer + cborRFC3339Time: hexDecode("c074323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c11a514b67b0"), + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + { + name: "time with fractional seconds", // float + cborRFC3339Time: hexDecode("c076323031332d30332d32315432303a30343a30302e355a"), + cborUnixTime: hexDecode("c1fb41d452d9ec200000"), + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00.5Z"), + }, + { + name: "time before January 1, 1970 UTC without fractional seconds", // negative integer + cborRFC3339Time: hexDecode("c074313936392d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c13a0177f2cf"), + wantTime: parseTime(time.RFC3339Nano, "1969-03-21T20:04:00Z"), + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + tm := time.Now() + if err := Unmarshal(tc.cborRFC3339Time, &tm); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborRFC3339Time, err) + } else if !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborRFC3339Time, tm, tm, tc.wantTime, tc.wantTime) + } + tm = time.Now() + if err := Unmarshal(tc.cborUnixTime, &tm); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborUnixTime, err) + } else if !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborUnixTime, tm, tm, tc.wantTime, tc.wantTime) + } + + var v interface{} + if err := Unmarshal(tc.cborRFC3339Time, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborRFC3339Time, err) + } else if tm, ok := v.(time.Time); !ok || !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborRFC3339Time, v, v, tc.wantTime, tc.wantTime) + } + v = nil + if err := Unmarshal(tc.cborUnixTime, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborUnixTime, err) + } else if tm, ok := v.(time.Time); !ok || !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborUnixTime, v, v, tc.wantTime, tc.wantTime) + } + }) + } +} + +func TestDecodeTimeError(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantErrorMsg string + }{ + { + name: "invalid RFC3339 time string", + cborData: hexDecode("7f657374726561646d696e67ff"), + wantErrorMsg: "cbor: cannot set streaming for time.Time", + }, + { + name: "byte string data cannot be decoded into time.Time", + cborData: hexDecode("4f013030303030303030e03031ed3030"), + wantErrorMsg: "cbor: cannot unmarshal byte string into Go value of type time.Time", + }, + { + name: "bool cannot be decoded into time.Time", + cborData: hexDecode("f4"), + wantErrorMsg: "cbor: cannot unmarshal primitives into Go value of type time.Time", + }, + { + name: "invalid UTF-8 string", + cborData: hexDecode("7f62e6b061b4ff"), + wantErrorMsg: "cbor: invalid UTF-8 string", + }, + { + name: "negative integer overflow", + cborData: hexDecode("3bffffffffffffffff"), + wantErrorMsg: "cbor: cannot unmarshal negative integer into Go value of type time.Time", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + tm := time.Now() + if err := Unmarshal(tc.cborData, &tm); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error msg %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestDecodeInvalidTagTime(t *testing.T) { + typeTimeSlice := reflect.TypeOf([]time.Time{}) + + testCases := []struct { + name string + cborData []byte + decodeToTypes []reflect.Type + wantErrorMsg string + }{ + { + name: "Tag 0 with invalid RFC3339 time string", + cborData: hexDecode("c07f657374726561646d696e67ff"), + decodeToTypes: []reflect.Type{typeIntf, typeTime}, + wantErrorMsg: "cbor: cannot set streaming for time.Time", + }, + { + name: "Tag 0 with invalid UTF-8 string", + cborData: hexDecode("c07f62e6b061b4ff"), + decodeToTypes: []reflect.Type{typeIntf, typeTime}, + wantErrorMsg: "cbor: invalid UTF-8 string", + }, + { + name: "Tag 0 with integer content", + cborData: hexDecode("c01a514b67b0"), + decodeToTypes: []reflect.Type{typeIntf, typeTime}, + wantErrorMsg: "cbor: tag number 0 must be followed by text string, got positive integer", + }, + { + name: "Tag 0 with byte string content", + cborData: hexDecode("c04f013030303030303030e03031ed3030"), + decodeToTypes: []reflect.Type{typeIntf, typeTime}, + wantErrorMsg: "cbor: tag number 0 must be followed by text string, got byte string", + }, + { + name: "Tag 0 with integer content as array element", + cborData: hexDecode("81c01a514b67b0"), + decodeToTypes: []reflect.Type{typeIntf, typeTimeSlice}, + wantErrorMsg: "cbor: tag number 0 must be followed by text string, got positive integer", + }, + { + name: "Tag 1 with negative integer overflow", + cborData: hexDecode("c13bffffffffffffffff"), + decodeToTypes: []reflect.Type{typeIntf, typeTime}, + wantErrorMsg: "cbor: cannot unmarshal tag into Go value of type time.Time", + }, + { + name: "Tag 1 with string content", + cborData: hexDecode("c174323031332d30332d32315432303a30343a30305a"), + decodeToTypes: []reflect.Type{typeIntf, typeTime}, + wantErrorMsg: "cbor: tag number 1 must be followed by integer or floating-point number, got UTF-8 text string", + }, + { + name: "Tag 1 with simple value", + cborData: hexDecode("d801f6"), // 1(null) + decodeToTypes: []reflect.Type{typeIntf, typeTime}, + wantErrorMsg: "cbor: tag number 1 must be followed by integer or floating-point number, got primitive", + }, + { + name: "Tag 1 with string content as array element", + cborData: hexDecode("81c174323031332d30332d32315432303a30343a30305a"), + decodeToTypes: []reflect.Type{typeIntf, typeTimeSlice}, + wantErrorMsg: "cbor: tag number 1 must be followed by integer or floating-point number, got UTF-8 text string", + }, + } + dm, _ := DecOptions{TimeTag: DecTagOptional}.DecMode() + for _, tc := range testCases { + for _, decodeToType := range tc.decodeToTypes { + t.Run(tc.name+" decode to "+decodeToType.String(), func(t *testing.T) { + v := reflect.New(decodeToType) + if err := dm.Unmarshal(tc.cborData, v.Interface()); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err, tc.wantErrorMsg) + } + }) + } + } +} + +func TestDecodeTag0Error(t *testing.T) { + cborData := hexDecode("c01a514b67b0") // 0(1363896240) + wantErrorMsg := "cbor: tag number 0 must be followed by text string, got positive integer" + + timeTagIgnoredDM, _ := DecOptions{TimeTag: DecTagIgnored}.DecMode() + timeTagOptionalDM, _ := DecOptions{TimeTag: DecTagOptional}.DecMode() + timeTagRequiredDM, _ := DecOptions{TimeTag: DecTagRequired}.DecMode() + + testCases := []struct { + name string + dm DecMode + }{ + {name: "DecTagIgnored", dm: timeTagIgnoredDM}, + {name: "DecTagOptional", dm: timeTagOptionalDM}, + {name: "DecTagRequired", dm: timeTagRequiredDM}, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + // Decode to interface{} + var v interface{} + if err := tc.dm.Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err, wantErrorMsg) + } + + // Decode to time.Time + var tm time.Time + if err := tc.dm.Unmarshal(cborData, &tm); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err, wantErrorMsg) + } + + // Decode to uint64 + var ui uint64 + if err := tc.dm.Unmarshal(cborData, &ui); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err, wantErrorMsg) + } + }) + } +} + +func TestDecodeTag1Error(t *testing.T) { + cborData := hexDecode("c174323031332d30332d32315432303a30343a30305a") // 1("2013-03-21T20:04:00Z") + wantErrorMsg := "cbor: tag number 1 must be followed by integer or floating-point number, got UTF-8 text string" + + timeTagIgnoredDM, _ := DecOptions{TimeTag: DecTagIgnored}.DecMode() + timeTagOptionalDM, _ := DecOptions{TimeTag: DecTagOptional}.DecMode() + timeTagRequiredDM, _ := DecOptions{TimeTag: DecTagRequired}.DecMode() + + testCases := []struct { + name string + dm DecMode + }{ + {name: "DecTagIgnored", dm: timeTagIgnoredDM}, + {name: "DecTagOptional", dm: timeTagOptionalDM}, + {name: "DecTagRequired", dm: timeTagRequiredDM}, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + // Decode to interface{} + var v interface{} + if err := tc.dm.Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err, wantErrorMsg) + } + + // Decode to time.Time + var tm time.Time + if err := tc.dm.Unmarshal(cborData, &tm); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err, wantErrorMsg) + } + + // Decode to string + var s string + if err := tc.dm.Unmarshal(cborData, &s); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err, wantErrorMsg) + } + }) + } +} + +func TestDecodeTimeStreaming(t *testing.T) { + // Decoder decodes from mixed invalid and valid time. + testCases := []struct { + cborData []byte + wantErrorMsg string + wantObj time.Time + }{ + { + cborData: hexDecode("c07f62e6b061b4ff"), + wantErrorMsg: "cbor: invalid UTF-8 string", + }, + { + cborData: hexDecode("c074323031332d30332d32315432303a30343a30305a"), + wantObj: time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), + }, + { + cborData: hexDecode("c01a514b67b0"), + wantErrorMsg: "cbor: tag number 0 must be followed by text string, got positive integer", + }, + { + cborData: hexDecode("c074323031332d30332d32315432303a30343a30305a"), + wantObj: time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), + }, + { + cborData: hexDecode("c13bffffffffffffffff"), + wantErrorMsg: "cbor: cannot unmarshal tag into Go value of type time.Time", + }, + { + cborData: hexDecode("c11a514b67b0"), + wantObj: time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), + }, + { + cborData: hexDecode("c174323031332d30332d32315432303a30343a30305a"), + wantErrorMsg: "tag number 1 must be followed by integer or floating-point number, got UTF-8 text string", + }, + { + cborData: hexDecode("c11a514b67b0"), + wantObj: time.Date(2013, 3, 21, 20, 4, 0, 0, time.UTC), + }, + } + // Data is a mixed stream of valid and invalid time data + var cborData []byte + for _, tc := range testCases { + cborData = append(cborData, tc.cborData...) + } + dm, _ := DecOptions{TimeTag: DecTagOptional}.DecMode() + dec := dm.NewDecoder(bytes.NewReader(cborData)) + for _, tc := range testCases { + var v interface{} + err := dec.Decode(&v) + if tc.wantErrorMsg != "" { + if err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error msg %q, want %q", tc.cborData, err, tc.wantErrorMsg) + } + } else { + tm, ok := v.(time.Time) + if !ok { + t.Errorf("Unmarshal(0x%x) returned %s (%T), want time.Time", tc.cborData, v, v) + } + if !tc.wantObj.Equal(tm) { + t.Errorf("Unmarshal(0x%x) returned %s, want %s", tc.cborData, tm, tc.wantObj) + } + } + } + dec = dm.NewDecoder(bytes.NewReader(cborData)) + for _, tc := range testCases { + var tm time.Time + err := dec.Decode(&tm) + if tc.wantErrorMsg != "" { + if err == nil { + t.Errorf("Unmarshal(0x%x) did't return error, want error msg %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error msg %q, want %q", tc.cborData, err, tc.wantErrorMsg) + } + } else { + if !tc.wantObj.Equal(tm) { + t.Errorf("Unmarshal(0x%x) returned %s, want %s", tc.cborData, tm, tc.wantObj) + } + } + } +} + +func TestDecTimeTagOption(t *testing.T) { + timeTagIgnoredDecMode, _ := DecOptions{TimeTag: DecTagIgnored}.DecMode() + timeTagOptionalDecMode, _ := DecOptions{TimeTag: DecTagOptional}.DecMode() + timeTagRequiredDecMode, _ := DecOptions{TimeTag: DecTagRequired}.DecMode() + + testCases := []struct { + name string + cborRFC3339Time []byte + cborUnixTime []byte + decMode DecMode + wantTime time.Time + wantErrorMsg string + }{ + // not-tagged time CBOR data + { + name: "not-tagged data with DecTagIgnored option", + cborRFC3339Time: hexDecode("74323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("1a514b67b0"), + decMode: timeTagIgnoredDecMode, + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + { + name: "not-tagged data with timeTagOptionalDecMode option", + cborRFC3339Time: hexDecode("74323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("1a514b67b0"), + decMode: timeTagOptionalDecMode, + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + { + name: "not-tagged data with timeTagRequiredDecMode option", + cborRFC3339Time: hexDecode("74323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("1a514b67b0"), + decMode: timeTagRequiredDecMode, + wantErrorMsg: "expect CBOR tag value", + }, + // tagged time CBOR data + { + name: "tagged data with timeTagIgnoredDecMode option", + cborRFC3339Time: hexDecode("c074323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c11a514b67b0"), + decMode: timeTagIgnoredDecMode, + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + { + name: "tagged data with timeTagOptionalDecMode option", + cborRFC3339Time: hexDecode("c074323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c11a514b67b0"), + decMode: timeTagOptionalDecMode, + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + { + name: "tagged data with timeTagRequiredDecMode option", + cborRFC3339Time: hexDecode("c074323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c11a514b67b0"), + decMode: timeTagRequiredDecMode, + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + // mis-tagged time CBOR data + { + name: "mis-tagged data with timeTagIgnoredDecMode option", + cborRFC3339Time: hexDecode("c8c974323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c8c91a514b67b0"), + decMode: timeTagIgnoredDecMode, + wantTime: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + }, + { + name: "mis-tagged data with timeTagOptionalDecMode option", + cborRFC3339Time: hexDecode("c8c974323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c8c91a514b67b0"), + decMode: timeTagOptionalDecMode, + wantErrorMsg: "cbor: wrong tag number for time.Time, got 8, expect 0 or 1", + }, + { + name: "mis-tagged data with timeTagRequiredDecMode option", + cborRFC3339Time: hexDecode("c8c974323031332d30332d32315432303a30343a30305a"), + cborUnixTime: hexDecode("c8c91a514b67b0"), + decMode: timeTagRequiredDecMode, + wantErrorMsg: "cbor: wrong tag number for time.Time, got 8, expect 0 or 1", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + tm := time.Now() + err := tc.decMode.Unmarshal(tc.cborRFC3339Time, &tm) + if tc.wantErrorMsg != "" { + if err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error", tc.cborRFC3339Time) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborRFC3339Time, err.Error(), tc.wantErrorMsg) + } + } else { + if !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborRFC3339Time, tm, tm, tc.wantTime, tc.wantTime) + } + } + + tm = time.Now() + err = tc.decMode.Unmarshal(tc.cborUnixTime, &tm) + if tc.wantErrorMsg != "" { + if err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error", tc.cborRFC3339Time) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborRFC3339Time, err.Error(), tc.wantErrorMsg) + } + } else { + if !tc.wantTime.Equal(tm) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborRFC3339Time, tm, tm, tc.wantTime, tc.wantTime) + } + } + }) + } +} + +func TestUnmarshalStructTag1(t *testing.T) { + type strc struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + } + want := strc{ + A: "A", + B: "B", + C: "C", + } + cborData := hexDecode("a3616161416162614261636143") // {"a":"A", "b":"B", "c":"C"} + + var v strc + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, want, want) + } +} + +func TestUnmarshalStructTag2(t *testing.T) { + type strc struct { + A string `json:"a"` + B string `json:"b"` + C string `json:"c"` + } + want := strc{ + A: "A", + B: "B", + C: "C", + } + cborData := hexDecode("a3616161416162614261636143") // {"a":"A", "b":"B", "c":"C"} + + var v strc + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, want, want) + } +} + +func TestUnmarshalStructTag3(t *testing.T) { + type strc struct { + A string `json:"x" cbor:"a"` + B string `json:"y" cbor:"b"` + C string `json:"z"` + } + want := strc{ + A: "A", + B: "B", + C: "C", + } + cborData := hexDecode("a36161614161626142617a6143") // {"a":"A", "b":"B", "z":"C"} + + var v strc + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, v, v, want, want) + } +} + +func TestUnmarshalStructTag4(t *testing.T) { + type strc struct { + A string `json:"x" cbor:"a"` + B string `json:"y" cbor:"b"` + C string `json:"-"` + } + want := strc{ + A: "A", + B: "B", + } + cborData := hexDecode("a3616161416162614261636143") // {"a":"A", "b":"B", "c":"C"} + + var v strc + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, v, v, want, want) + } +} + +type number uint64 + +func (n number) MarshalBinary() (data []byte, err error) { + if n == 0 { + return []byte{}, nil + } + data = make([]byte, 8) + binary.BigEndian.PutUint64(data, uint64(n)) + return +} + +func (n *number) UnmarshalBinary(data []byte) (err error) { + if len(data) == 0 { + *n = 0 + return nil + } + if len(data) != 8 { + return errors.New("number:UnmarshalBinary: invalid length") + } + *n = number(binary.BigEndian.Uint64(data)) + return +} + +type stru struct { + a, b, c string +} + +func (s *stru) MarshalBinary() ([]byte, error) { + if s.a == "" && s.b == "" && s.c == "" { + return []byte{}, nil + } + return []byte(fmt.Sprintf("%s,%s,%s", s.a, s.b, s.c)), nil +} + +func (s *stru) UnmarshalBinary(data []byte) (err error) { + if len(data) == 0 { + s.a, s.b, s.c = "", "", "" + return nil + } + ss := strings.Split(string(data), ",") + if len(ss) != 3 { + return errors.New("stru:UnmarshalBinary: invalid element count") + } + s.a, s.b, s.c = ss[0], ss[1], ss[2] + return +} + +type marshalBinaryError string + +func (n marshalBinaryError) MarshalBinary() (data []byte, err error) { + return nil, errors.New(string(n)) +} + +func TestBinaryMarshalerUnmarshaler(t *testing.T) { + testCases := []roundTripTest{ + { + name: "primitive obj", + obj: number(1234567890), + wantCborData: hexDecode("4800000000499602d2"), + }, + { + name: "struct obj", + obj: stru{a: "a", b: "b", c: "c"}, + wantCborData: hexDecode("45612C622C63"), + }, + } + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, testCases, em, dm) +} + +func TestBinaryUnmarshalerError(t *testing.T) { //nolint:dupl + testCases := []struct { + name string + typ reflect.Type + cborData []byte + wantErrorMsg string + }{ + { + name: "primitive type", + typ: reflect.TypeOf(number(0)), + cborData: hexDecode("44499602d2"), + wantErrorMsg: "number:UnmarshalBinary: invalid length", + }, + { + name: "struct type", + typ: reflect.TypeOf(stru{}), + cborData: hexDecode("47612C622C632C64"), + wantErrorMsg: "stru:UnmarshalBinary: invalid element count", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + v := reflect.New(tc.typ) + if err := Unmarshal(tc.cborData, v.Interface()); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error msg %q", tc.cborData, tc.wantErrorMsg) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestBinaryMarshalerError(t *testing.T) { + wantErrorMsg := "MarshalBinary: error" + v := marshalBinaryError(wantErrorMsg) + if _, err := Marshal(v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error msg %q", v, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", v, err.Error(), wantErrorMsg) + } +} + +type number2 uint64 + +func (n number2) MarshalCBOR() (data []byte, err error) { + m := map[string]uint64{"num": uint64(n)} + return Marshal(m) +} + +func (n *number2) UnmarshalCBOR(data []byte) (err error) { + var v map[string]uint64 + if err := Unmarshal(data, &v); err != nil { + return err + } + *n = number2(v["num"]) + return nil +} + +type stru2 struct { + a, b, c string +} + +func (s *stru2) MarshalCBOR() ([]byte, error) { + v := []string{s.a, s.b, s.c} + return Marshal(v) +} + +func (s *stru2) UnmarshalCBOR(data []byte) (err error) { + var v []string + if err := Unmarshal(data, &v); err != nil { + return err + } + if len(v) > 0 { + s.a = v[0] + } + if len(v) > 1 { + s.b = v[1] + } + if len(v) > 2 { + s.c = v[2] + } + return nil +} + +type marshalCBORError string + +func (n marshalCBORError) MarshalCBOR() (data []byte, err error) { + return nil, errors.New(string(n)) +} + +func TestMarshalerUnmarshaler(t *testing.T) { + testCases := []roundTripTest{ + { + name: "primitive obj", + obj: number2(1), + wantCborData: hexDecode("a1636e756d01"), + }, + { + name: "struct obj", + obj: stru2{a: "a", b: "b", c: "c"}, + wantCborData: hexDecode("83616161626163"), + }, + } + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, testCases, em, dm) +} + +func TestUnmarshalerError(t *testing.T) { //nolint:dupl + testCases := []struct { + name string + typ reflect.Type + cborData []byte + wantErrorMsg string + }{ + { + name: "primitive type", + typ: reflect.TypeOf(number2(0)), + cborData: hexDecode("44499602d2"), + wantErrorMsg: "cbor: cannot unmarshal byte string into Go value of type map[string]uint64", + }, + { + name: "struct type", + typ: reflect.TypeOf(stru2{}), + cborData: hexDecode("47612C622C632C64"), + wantErrorMsg: "cbor: cannot unmarshal byte string into Go value of type []string", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + v := reflect.New(tc.typ) + if err := Unmarshal(tc.cborData, v.Interface()); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error msg %q", tc.cborData, tc.wantErrorMsg) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestMarshalerError(t *testing.T) { + wantErrorMsg := "MarshalCBOR: error" + v := marshalCBORError(wantErrorMsg) + if _, err := Marshal(v); err == nil { + t.Errorf("Marshal(%+v) didn't return an error, want error msg %q", v, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Marshal(%+v) returned error %q, want %q", v, err.Error(), wantErrorMsg) + } +} + +// Found at https://github.com/oasislabs/oasis-core/blob/master/go/common/cbor/cbor_test.go +func TestOutOfMem1(t *testing.T) { + cborData := []byte("\x9b\x00\x00000000") + var f []byte + if err := Unmarshal(cborData, &f); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } +} + +// Found at https://github.com/oasislabs/oasis-core/blob/master/go/common/cbor/cbor_test.go +func TestOutOfMem2(t *testing.T) { + cborData := []byte("\x9b\x00\x00\x81112233") + var f []byte + if err := Unmarshal(cborData, &f); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } +} + +// Found at https://github.com/cose-wg/Examples/tree/master/RFC8152 +func TestCOSEExamples(t *testing.T) { + cborData := [][]byte{ + hexDecode("D8608443A10101A1054C02D1F7E6F26C43D4868D87CE582464F84D913BA60A76070A9A48F26E97E863E2852948658F0811139868826E89218A75715B818440A101225818DBD43C4E9D719C27C6275C67D628D493F090593DB8218F11818344A1013818A220A401022001215820B2ADD44368EA6D641F9CA9AF308B4079AEB519F11E9B8A55A600B21233E86E6822F40458246D65726961646F632E6272616E64796275636B406275636B6C616E642E6578616D706C6540"), + hexDecode("D8628440A054546869732069732074686520636F6E74656E742E818343A10126A1044231315840E2AEAFD40D69D19DFE6E52077C5D7FF4E408282CBEFB5D06CBF414AF2E19D982AC45AC98B8544C908B4507DE1E90B717C3D34816FE926A2B98F53AFD2FA0F30A"), + hexDecode("D8628440A054546869732069732074686520636F6E74656E742E828343A10126A1044231315840E2AEAFD40D69D19DFE6E52077C5D7FF4E408282CBEFB5D06CBF414AF2E19D982AC45AC98B8544C908B4507DE1E90B717C3D34816FE926A2B98F53AFD2FA0F30A8344A1013823A104581E62696C626F2E62616767696E7340686F626269746F6E2E6578616D706C65588400A2D28A7C2BDB1587877420F65ADF7D0B9A06635DD1DE64BB62974C863F0B160DD2163734034E6AC003B01E8705524C5C4CA479A952F0247EE8CB0B4FB7397BA08D009E0C8BF482270CC5771AA143966E5A469A09F613488030C5B07EC6D722E3835ADB5B2D8C44E95FFB13877DD2582866883535DE3BB03D01753F83AB87BB4F7A0297"), + hexDecode("D8628440A1078343A10126A10442313158405AC05E289D5D0E1B0A7F048A5D2B643813DED50BC9E49220F4F7278F85F19D4A77D655C9D3B51E805A74B099E1E085AACD97FC29D72F887E8802BB6650CCEB2C54546869732069732074686520636F6E74656E742E818343A10126A1044231315840E2AEAFD40D69D19DFE6E52077C5D7FF4E408282CBEFB5D06CBF414AF2E19D982AC45AC98B8544C908B4507DE1E90B717C3D34816FE926A2B98F53AFD2FA0F30A"), + hexDecode("D8628456A2687265736572766564F40281687265736572766564A054546869732069732074686520636F6E74656E742E818343A10126A10442313158403FC54702AA56E1B2CB20284294C9106A63F91BAC658D69351210A031D8FC7C5FF3E4BE39445B1A3E83E1510D1ACA2F2E8A7C081C7645042B18ABA9D1FAD1BD9C"), + hexDecode("D28443A10126A10442313154546869732069732074686520636F6E74656E742E58408EB33E4CA31D1C465AB05AAC34CC6B23D58FEF5C083106C4D25A91AEF0B0117E2AF9A291AA32E14AB834DC56ED2A223444547E01F11D3B0916E5A4C345CACB36"), + hexDecode("D8608443A10101A1054CC9CF4DF2FE6C632BF788641358247ADBE2709CA818FB415F1E5DF66F4E1A51053BA6D65A1A0C52A357DA7A644B8070A151B0818344A1013818A220A40102200121582098F50A4FF6C05861C8860D13A638EA56C3F5AD7590BBFBF054E1C7B4D91D628022F50458246D65726961646F632E6272616E64796275636B406275636B6C616E642E6578616D706C6540"), + hexDecode("D8608443A1010AA1054D89F52F65A1C580933B5261A76C581C753548A19B1307084CA7B2056924ED95F2E3B17006DFE931B687B847818343A10129A2335061616262636364646565666667676868044A6F75722D73656372657440"), + hexDecode("D8608443A10101A2054CC9CF4DF2FE6C632BF7886413078344A1013823A104581E62696C626F2E62616767696E7340686F626269746F6E2E6578616D706C65588400929663C8789BB28177AE28467E66377DA12302D7F9594D2999AFA5DFA531294F8896F2B6CDF1740014F4C7F1A358E3A6CF57F4ED6FB02FCF8F7AA989F5DFD07F0700A3A7D8F3C604BA70FA9411BD10C2591B483E1D2C31DE003183E434D8FBA18F17A4C7E3DFA003AC1CF3D30D44D2533C4989D3AC38C38B71481CC3430C9D65E7DDFF58247ADBE2709CA818FB415F1E5DF66F4E1A51053BA6D65A1A0C52A357DA7A644B8070A151B0818344A1013818A220A40102200121582098F50A4FF6C05861C8860D13A638EA56C3F5AD7590BBFBF054E1C7B4D91D628022F50458246D65726961646F632E6272616E64796275636B406275636B6C616E642E6578616D706C6540"), + hexDecode("D8608443A10101A1054C02D1F7E6F26C43D4868D87CE582464F84D913BA60A76070A9A48F26E97E863E28529D8F5335E5F0165EEE976B4A5F6C6F09D818344A101381FA3225821706572656772696E2E746F6F6B407475636B626F726F7567682E6578616D706C650458246D65726961646F632E6272616E64796275636B406275636B6C616E642E6578616D706C6535420101581841E0D76F579DBD0D936A662D54D8582037DE2E366FDE1C62"), + hexDecode("D08343A1010AA1054D89F52F65A1C580933B5261A78C581C5974E1B99A3A4CC09A659AA2E9E7FFF161D38CE71CB45CE460FFB569"), + hexDecode("D08343A1010AA1064261A7581C252A8911D465C125B6764739700F0141ED09192DE139E053BD09ABCA"), + hexDecode("D8618543A1010FA054546869732069732074686520636F6E74656E742E489E1226BA1F81B848818340A20125044A6F75722D73656372657440"), + hexDecode("D8618543A10105A054546869732069732074686520636F6E74656E742E582081A03448ACD3D305376EAA11FB3FE416A955BE2CBE7EC96F012C994BC3F16A41818344A101381AA3225821706572656772696E2E746F6F6B407475636B626F726F7567682E6578616D706C650458246D65726961646F632E6272616E64796275636B406275636B6C616E642E6578616D706C653558404D8553E7E74F3C6A3A9DD3EF286A8195CBF8A23D19558CCFEC7D34B824F42D92BD06BD2C7F0271F0214E141FB779AE2856ABF585A58368B017E7F2A9E5CE4DB540"), + hexDecode("D8618543A1010EA054546869732069732074686520636F6E74656E742E4836F5AFAF0BAB5D43818340A2012404582430313863306165352D346439622D343731622D626664362D6565663331346263373033375818711AB0DC2FC4585DCE27EFFA6781C8093EBA906F227B6EB0"), + hexDecode("D8618543A10105A054546869732069732074686520636F6E74656E742E5820BF48235E809B5C42E995F2B7D5FA13620E7ED834E337F6AA43DF161E49E9323E828344A101381CA220A4010220032158420043B12669ACAC3FD27898FFBA0BCD2E6C366D53BC4DB71F909A759304ACFB5E18CDC7BA0B13FF8C7636271A6924B1AC63C02688075B55EF2D613574E7DC242F79C322F504581E62696C626F2E62616767696E7340686F626269746F6E2E6578616D706C655828339BC4F79984CDC6B3E6CE5F315A4C7D2B0AC466FCEA69E8C07DFBCA5BB1F661BC5F8E0DF9E3EFF58340A2012404582430313863306165352D346439622D343731622D626664362D65656633313462633730333758280B2C7CFCE04E98276342D6476A7723C090DFDD15F9A518E7736549E998370695E6D6A83B4AE507BB"), + hexDecode("D18443A1010FA054546869732069732074686520636F6E74656E742E48726043745027214F"), + } + for _, d := range cborData { + var v interface{} + if err := Unmarshal(d, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", d, err) + } + } +} + +func TestUnmarshalStructKeyAsIntError(t *testing.T) { + type T1 struct { + F1 int `cbor:"1,keyasint"` + } + cborData := hexDecode("a13bffffffffffffffff01") // {1: -18446744073709551616} + var v T1 + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), "cannot unmarshal") + } +} + +func TestUnmarshalArrayToStruct(t *testing.T) { + type T struct { + _ struct{} `cbor:",toarray"` + A int + B int + C int + } + testCases := []struct { + name string + cborData []byte + }{ + {"definite length array", hexDecode("83010203")}, + {"indefinite length array", hexDecode("9f010203ff")}, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v T + if err := Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } + }) + } +} + +func TestUnmarshalArrayToStructNoToArrayOptionError(t *testing.T) { + type T struct { + A int + B int + C int + } + cborData := hexDecode("8301020383010203") + var v1 T + wantT := T{} + dec := NewDecoder(bytes.NewReader(cborData)) + if err := dec.Decode(&v1); err == nil { + t.Errorf("Decode(%+v) didn't return an error", v1) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Decode(%+v) returned wrong error type %T, want (*UnmarshalTypeError)", v1, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Decode(%+v) returned error %q, want error containing %q", err.Error(), v1, "cannot unmarshal") + } + if !reflect.DeepEqual(v1, wantT) { + t.Errorf("Decode() = %+v (%T), want %+v (%T)", v1, v1, wantT, wantT) + } + var v2 []int + want := []int{1, 2, 3} + if err := dec.Decode(&v2); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(v2, want) { + t.Errorf("Decode() = %+v (%T), want %+v (%T)", v2, v2, want, want) + } +} + +func TestUnmarshalNonArrayDataToStructToArray(t *testing.T) { + type T struct { + _ struct{} `cbor:",toarray"` + A int + B int + C int + } + testCases := []struct { + name string + cborData []byte + }{ + {"CBOR positive int", hexDecode("00")}, // 0 + {"CBOR negative int", hexDecode("20")}, // -1 + {"CBOR byte string", hexDecode("4401020304")}, // h`01020304` + {"CBOR text string", hexDecode("7f657374726561646d696e67ff")}, // streaming + {"CBOR map", hexDecode("a3614101614202614303")}, // {"A": 1, "B": 2, "C": 3} + {"CBOR bool", hexDecode("f5")}, // true + {"CBOR float", hexDecode("fa7f7fffff")}, // 3.4028234663852886e+38 + } + wantT := T{} + wantErrorMsg := "cannot unmarshal" + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v T + if err := Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", tc.cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v, wantT) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", tc.cborData, v, v, wantT, wantT) + } + }) + } +} + +func TestUnmarshalArrayToStructWrongSizeError(t *testing.T) { + type T struct { + _ struct{} `cbor:",toarray"` + A int + B int + } + cborData := hexDecode("8301020383010203") + var v1 T + wantT := T{} + dec := NewDecoder(bytes.NewReader(cborData)) + if err := dec.Decode(&v1); err == nil { + t.Errorf("Decode(%+v) didn't return an error", v1) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Decode(%+v) returned wrong error type %T, want (*UnmarshalTypeError)", v1, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Decode(%+v) returned error %q, want error containing %q", v1, err.Error(), "cannot unmarshal") + } + if !reflect.DeepEqual(v1, wantT) { + t.Errorf("Decode() = %+v (%T), want %+v (%T)", v1, v1, wantT, wantT) + } + var v2 []int + want := []int{1, 2, 3} + if err := dec.Decode(&v2); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(v2, want) { + t.Errorf("Decode() = %+v (%T), want %+v (%T)", v2, v2, want, want) + } +} + +func TestUnmarshalArrayToStructWrongFieldTypeError(t *testing.T) { + type T struct { + _ struct{} `cbor:",toarray"` + A int + B string + C int + } + testCases := []struct { + name string + cborData []byte + wantErrorMsg string + wantV interface{} + }{ + // [1, 2, 3] + {"wrong field type", hexDecode("83010203"), "cannot unmarshal", T{A: 1, C: 3}}, + // [1, 0xfe, 3] + {"invalid UTF-8 string", hexDecode("830161fe03"), invalidUTF8ErrorMsg, T{A: 1, C: 3}}, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v T + if err := Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + if !reflect.DeepEqual(v, tc.wantV) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", tc.cborData, v, v, tc.wantV, tc.wantV) + } + }) + } +} + +func TestUnmarshalArrayToStructCannotSetEmbeddedPointerError(t *testing.T) { + type ( + s1 struct { + x int //nolint:unused,structcheck + X int + } + S2 struct { + y int //nolint:unused,structcheck + Y int + } + S struct { + _ struct{} `cbor:",toarray"` + *s1 + *S2 + } + ) + cborData := []byte{0x82, 0x02, 0x04} // [2, 4] + const wantErrorMsg = "cannot set embedded pointer to unexported struct" + wantV := S{S2: &S2{Y: 4}} + var v S + err := Unmarshal(cborData, &v) + if err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error %q", cborData, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v, wantV) { + t.Errorf("Decode() = %+v (%T), want %+v (%T)", v, v, wantV, wantV) + } +} + +func TestUnmarshalIntoSliceError(t *testing.T) { + cborData := []byte{0x83, 0x61, 0x61, 0x61, 0xfe, 0x61, 0x62} // ["a", 0xfe, "b"] + wantErrorMsg := invalidUTF8ErrorMsg + var want interface{} + + // Unmarshal CBOR array into Go empty interface. + var v1 interface{} + want = []interface{}{"a", interface{}(nil), "b"} + if err := Unmarshal(cborData, &v1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", cborData, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v1, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", cborData, v1, want) + } + + // Unmarshal CBOR array into Go slice. + var v2 []string + want = []string{"a", "", "b"} + if err := Unmarshal(cborData, &v2); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", cborData, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v2, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", cborData, v2, want) + } + + // Unmarshal CBOR array into Go array. + var v3 [3]string + want = [3]string{"a", "", "b"} + if err := Unmarshal(cborData, &v3); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", cborData, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v3, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", cborData, v3, want) + } + + // Unmarshal CBOR array into populated Go slice. + v4 := []string{"hello", "to", "you"} + want = []string{"a", "to", "b"} + if err := Unmarshal(cborData, &v4); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", cborData, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v4, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", cborData, v4, want) + } +} + +func TestUnmarshalIntoMapError(t *testing.T) { + cborData := [][]byte{ + {0xa3, 0x61, 0x61, 0x61, 0x41, 0x61, 0xfe, 0x61, 0x43, 0x61, 0x62, 0x61, 0x42}, // {"a":"A", 0xfe: "C", "b":"B"} + {0xa3, 0x61, 0x61, 0x61, 0x41, 0x61, 0x63, 0x61, 0xfe, 0x61, 0x62, 0x61, 0x42}, // {"a":"A", "c": 0xfe, "b":"B"} + } + wantErrorMsg := invalidUTF8ErrorMsg + var want interface{} + + for _, data := range cborData { + // Unmarshal CBOR map into Go empty interface. + var v1 interface{} + want = map[interface{}]interface{}{"a": "A", "b": "B"} + if err := Unmarshal(data, &v1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", data, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", data, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v1, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", data, v1, want) + } + + // Unmarshal CBOR map into Go map[interface{}]interface{}. + var v2 map[interface{}]interface{} + want = map[interface{}]interface{}{"a": "A", "b": "B"} + if err := Unmarshal(data, &v2); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", data, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", data, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v2, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", data, v2, want) + } + + // Unmarshal CBOR array into Go map[string]string. + var v3 map[string]string + want = map[string]string{"a": "A", "b": "B"} + if err := Unmarshal(data, &v3); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", data, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", data, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v3, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", data, v3, want) + } + + // Unmarshal CBOR array into populated Go map[string]string. + v4 := map[string]string{"c": "D"} + want = map[string]string{"a": "A", "b": "B", "c": "D"} + if err := Unmarshal(data, &v4); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", data, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", data, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v4, want) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", data, v4, want) + } + } +} + +func TestStructToArrayError(t *testing.T) { + type coseHeader struct { + Alg int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` + } + type nestedCWT struct { + _ struct{} `cbor:",toarray"` + Protected []byte + Unprotected coseHeader + Ciphertext []byte + } + for _, tc := range []struct { + cborData []byte + wantErrorMsg string + }{ + // [-17, [-17, -17], -17] + {hexDecode("9f3082303030ff"), "cbor: cannot unmarshal negative integer into Go struct field cbor.nestedCWT.Protected of type []uint8"}, + // [[], [], ["\x930000", -17]] + {hexDecode("9f9fff9fff9f65933030303030ffff"), "cbor: cannot unmarshal array into Go struct field cbor.nestedCWT.Unprotected of type cbor.coseHeader (cannot decode CBOR array to struct without toarray option)"}, + } { + var v nestedCWT + if err := Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", tc.cborData, tc.wantErrorMsg) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + } +} + +func TestStructKeyAsIntError(t *testing.T) { + type claims struct { + Iss string `cbor:"1,keyasint"` + Sub string `cbor:"2,keyasint"` + Aud string `cbor:"3,keyasint"` + Exp float64 `cbor:"4,keyasint"` + Nbf float64 `cbor:"5,keyasint"` + Iat float64 `cbor:"6,keyasint"` + Cti []byte `cbor:"7,keyasint"` + } + cborData := hexDecode("bf0783e662f03030ff") // {7: [simple(6), "\xF00", -17]} + wantErrorMsg := invalidUTF8ErrorMsg + wantV := claims{Cti: []byte{6, 0, 0}} + var v claims + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", cborData, wantErrorMsg) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v, wantV) { + t.Errorf("Unmarshal(0x%x) = %v, want %v", cborData, v, wantV) + } +} + +func TestUnmarshalToNotNilInterface(t *testing.T) { + cborData := hexDecode("83010203") // []uint64{1, 2, 3} + s := "hello" //nolint:goconst + var v interface{} = s // Unmarshal() sees v as type inteface{} and sets CBOR data as default Go type. s is unmodified. Same behavior as encoding/json. + wantV := []interface{}{uint64(1), uint64(2), uint64(3)} + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantV, wantV) + } else if s != "hello" { + t.Errorf("Unmarshal(0x%x) modified s %q", cborData, s) + } +} + +func TestDecOptions(t *testing.T) { + opts1 := DecOptions{ + TimeTag: DecTagRequired, + DupMapKey: DupMapKeyEnforcedAPF, + IndefLength: IndefLengthForbidden, + MaxNestedLevels: 100, + MaxMapPairs: 101, + MaxArrayElements: 102, + TagsMd: TagsForbidden, + IntDec: IntDecConvertSigned, + ExtraReturnErrors: ExtraDecErrorUnknownField, + } + dm, err := opts1.DecMode() + if err != nil { + t.Errorf("DecMode() returned an error %v", err) + } else { + opts2 := dm.DecOptions() + if !reflect.DeepEqual(opts1, opts2) { + t.Errorf("DecOptions->DecMode->DecOptions returned different values: %v, %v", opts1, opts2) + } + } +} + +type roundTripTest struct { + name string + obj interface{} + wantCborData []byte +} + +func testRoundTrip(t *testing.T, testCases []roundTripTest, em EncMode, dm DecMode) { + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := em.Marshal(tc.obj) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.obj, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.obj, b, tc.wantCborData) + } + v := reflect.New(reflect.TypeOf(tc.obj)) + if err := dm.Unmarshal(b, v.Interface()); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + if !reflect.DeepEqual(tc.obj, v.Elem().Interface()) { + t.Errorf("Marshal-Unmarshal returned different values: %v, %v", tc.obj, v.Elem().Interface()) + } + }) + } +} + +func TestDecModeInvalidTimeTag(t *testing.T) { + wantErrorMsg := "cbor: invalid TimeTag 101" + _, err := DecOptions{TimeTag: 101}.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestDecModeInvalidDuplicateMapKey(t *testing.T) { + wantErrorMsg := "cbor: invalid DupMapKey 101" + _, err := DecOptions{DupMapKey: 101}.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestDecModeDefaultMaxNestedLevel(t *testing.T) { + dm, err := DecOptions{}.DecMode() + if err != nil { + t.Errorf("DecMode() returned error %v", err) + } else { + maxNestedLevels := dm.DecOptions().MaxNestedLevels + if maxNestedLevels != 32 { + t.Errorf("DecOptions().MaxNestedLevels = %d, want %v", maxNestedLevels, 32) + } + } +} + +func TestDecModeInvalidMaxNestedLevel(t *testing.T) { + testCases := []struct { + name string + opts DecOptions + wantErrorMsg string + }{ + { + name: "MaxNestedLevels < 4", + opts: DecOptions{MaxNestedLevels: 1}, + wantErrorMsg: "cbor: invalid MaxNestedLevels 1 (range is [4, 256])", + }, + { + name: "MaxNestedLevels > 256", + opts: DecOptions{MaxNestedLevels: 257}, + wantErrorMsg: "cbor: invalid MaxNestedLevels 257 (range is [4, 256])", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + _, err := tc.opts.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestDecModeDefaultMaxMapPairs(t *testing.T) { + dm, err := DecOptions{}.DecMode() + if err != nil { + t.Errorf("DecMode() returned error %v", err) + } else { + maxMapPairs := dm.DecOptions().MaxMapPairs + if maxMapPairs != defaultMaxMapPairs { + t.Errorf("DecOptions().MaxMapPairs = %d, want %v", maxMapPairs, defaultMaxMapPairs) + } + } +} + +func TestDecModeInvalidMaxMapPairs(t *testing.T) { + testCases := []struct { + name string + opts DecOptions + wantErrorMsg string + }{ + { + name: "MaxMapPairs < 16", + opts: DecOptions{MaxMapPairs: 1}, + wantErrorMsg: "cbor: invalid MaxMapPairs 1 (range is [16, 2147483647])", + }, + { + name: "MaxMapPairs > 2147483647", + opts: DecOptions{MaxMapPairs: 2147483648}, + wantErrorMsg: "cbor: invalid MaxMapPairs 2147483648 (range is [16, 2147483647])", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + _, err := tc.opts.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestDecModeDefaultMaxArrayElements(t *testing.T) { + dm, err := DecOptions{}.DecMode() + if err != nil { + t.Errorf("DecMode() returned error %v", err) + } else { + maxArrayElements := dm.DecOptions().MaxArrayElements + if maxArrayElements != defaultMaxArrayElements { + t.Errorf("DecOptions().MaxArrayElementsr = %d, want %v", maxArrayElements, defaultMaxArrayElements) + } + } +} + +func TestDecModeInvalidMaxArrayElements(t *testing.T) { + testCases := []struct { + name string + opts DecOptions + wantErrorMsg string + }{ + { + name: "MaxArrayElements < 16", + opts: DecOptions{MaxArrayElements: 1}, + wantErrorMsg: "cbor: invalid MaxArrayElements 1 (range is [16, 2147483647])", + }, + { + name: "MaxArrayElements > 2147483647", + opts: DecOptions{MaxArrayElements: 2147483648}, + wantErrorMsg: "cbor: invalid MaxArrayElements 2147483648 (range is [16, 2147483647])", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + _, err := tc.opts.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestDecModeInvalidIndefiniteLengthMode(t *testing.T) { + wantErrorMsg := "cbor: invalid IndefLength 101" + _, err := DecOptions{IndefLength: 101}.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestDecModeInvalidTagsMode(t *testing.T) { + wantErrorMsg := "cbor: invalid TagsMd 101" + _, err := DecOptions{TagsMd: 101}.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestUnmarshalStructKeyAsIntNumError(t *testing.T) { + type T1 struct { + F1 int `cbor:"a,keyasint"` + } + type T2 struct { + F1 int `cbor:"-18446744073709551616,keyasint"` + } + testCases := []struct { + name string + cborData []byte + obj interface{} + wantErrorMsg string + }{ + { + name: "string as key", + cborData: hexDecode("a1616101"), + obj: T1{}, + wantErrorMsg: "cbor: failed to parse field name \"a\" to int", + }, + { + name: "out of range int as key", + cborData: hexDecode("a13bffffffffffffffff01"), + obj: T2{}, + wantErrorMsg: "cbor: failed to parse field name \"-18446744073709551616\" to int", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + v := reflect.New(reflect.TypeOf(tc.obj)) + err := Unmarshal(tc.cborData, v.Interface()) + if err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) error %v, want %v", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestUnmarshalEmptyMapWithDupMapKeyOpt(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantV interface{} + }{ + { + name: "empty map", + cborData: hexDecode("a0"), + wantV: map[interface{}]interface{}{}, + }, + { + name: "indefinite empty map", + cborData: hexDecode("bfff"), + wantV: map[interface{}]interface{}{}, + }, + } + + dm, err := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + if err != nil { + t.Errorf("DecMode() returned error %v", err) + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v interface{} + if err := dm.Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } + if !reflect.DeepEqual(v, tc.wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v, v, tc.wantV, tc.wantV) + } + }) + } +} + +func TestUnmarshalDupMapKeyToEmptyInterface(t *testing.T) { + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + // Duplicate key overwrites previous value (default). + wantV := map[interface{}]interface{}{"a": "F", "b": "B", "c": "C", "d": "D", "e": "E"} + var v interface{} + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantV, wantV) + } + + // Duplicate key triggers error. + wantV = map[interface{}]interface{}{"a": nil, "b": "B", "c": "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var v2 interface{} + if err := dm.Unmarshal(cborData, &v2); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v2, wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v2, v2, wantV, wantV) + } +} + +func TestStreamDupMapKeyToEmptyInterface(t *testing.T) { + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // map with duplicate key "c": {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + // Duplicate key overwrites previous value (default). + wantV := map[interface{}]interface{}{"a": "F", "b": "B", "c": "C", "d": "D", "e": "E"} + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var v1 interface{} + if err := dec.Decode(&v1); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(v1, wantV) { + t.Errorf("Decode() = %v (%T), want %v (%T)", v1, v1, wantV, wantV) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantV = map[interface{}]interface{}{"a": nil, "b": "B", "c": "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var v2 interface{} + if err := dec.Decode(&v2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v2, wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v2, v2, wantV, wantV) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +func TestUnmarshalDupMapKeyToEmptyMap(t *testing.T) { + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + // Duplicate key overwrites previous value (default). + wantM := map[string]string{"a": "F", "b": "B", "c": "C", "d": "D", "e": "E"} + var m map[string]string + if err := Unmarshal(cborData, &m); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(m, wantM) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, m, m, wantM, wantM) + } + + // Duplicate key triggers error. + wantM = map[string]string{"a": "", "b": "B", "c": "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var m2 map[string]string + if err := dm.Unmarshal(cborData, &m2); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(m2, wantM) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, m2, m2, wantM, wantM) + } +} + +func TestStreamDupMapKeyToEmptyMap(t *testing.T) { + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + // Duplicate key overwrites previous value (default). + wantM := map[string]string{"a": "F", "b": "B", "c": "C", "d": "D", "e": "E"} + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var m1 map[string]string + if err := dec.Decode(&m1); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(m1, wantM) { + t.Errorf("Decode() = %v (%T), want %v (%T)", m1, m1, wantM, wantM) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantM = map[string]string{"a": "", "b": "B", "c": "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var m2 map[string]string + if err := dec.Decode(&m2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(m2, wantM) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, m2, m2, wantM, wantM) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +func TestUnmarshalDupMapKeyToNotEmptyMap(t *testing.T) { + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + // Duplicate key overwrites previous value (default). + m := map[string]string{"a": "Z", "b": "Z", "c": "Z", "d": "Z", "e": "Z", "f": "Z"} + wantM := map[string]string{"a": "F", "b": "B", "c": "C", "d": "D", "e": "E", "f": "Z"} + if err := Unmarshal(cborData, &m); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(m, wantM) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, m, m, wantM, wantM) + } + + // Duplicate key triggers error. + m2 := map[string]string{"a": "Z", "b": "Z", "c": "Z", "d": "Z", "e": "Z", "f": "Z"} + wantM = map[string]string{"a": "", "b": "B", "c": "C", "d": "Z", "e": "Z", "f": "Z"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + if err := dm.Unmarshal(cborData, &m2); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(m2, wantM) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, m2, m2, wantM, wantM) + } +} + +func TestStreamDupMapKeyToNotEmptyMap(t *testing.T) { + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + // Duplicate key overwrites previous value (default). + wantM := map[string]string{"a": "F", "b": "B", "c": "C", "d": "D", "e": "E", "f": "Z"} + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + m1 := map[string]string{"a": "Z", "b": "Z", "c": "Z", "d": "Z", "e": "Z", "f": "Z"} + if err := dec.Decode(&m1); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(m1, wantM) { + t.Errorf("Decode() = %v (%T), want %v (%T)", m1, m1, wantM, wantM) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantM = map[string]string{"a": "", "b": "B", "c": "C", "d": "Z", "e": "Z", "f": "Z"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + m2 := map[string]string{"a": "Z", "b": "Z", "c": "Z", "d": "Z", "e": "Z", "f": "Z"} + if err := dec.Decode(&m2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(m2, wantM) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, m2, m2, wantM, wantM) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +func TestUnmarshalDupMapKeyToStruct(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + // Duplicate key doesn't overwrite previous value (default). + wantS := s{A: "A", B: "B", C: "C", D: "D", E: "E"} + var s1 s + if err := Unmarshal(cborData, &s1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error. + wantS = s{A: "A", B: "B", C: "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestStreamDupMapKeyToStruct(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + // Duplicate key overwrites previous value (default). + wantS := s{A: "A", B: "B", C: "C", D: "D", E: "E"} + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s1 s + if err := dec.Decode(&s1); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Decode() = %v (%T), want %v (%T)", s1, s1, wantS, wantS) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantS = s{A: "A", B: "B", C: "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s2 s + if err := dec.Decode(&s2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +// dupl map key is a struct field +func TestUnmarshalDupMapKeyToStructKeyAsInt(t *testing.T) { + type s struct { + A int `cbor:"1,keyasint"` + B int `cbor:"3,keyasint"` + C int `cbor:"5,keyasint"` + } + cborData := hexDecode("a40102030401030506") // {1:2, 3:4, 1:3, 5:6} + + // Duplicate key doesn't overwrite previous value (default). + wantS := s{A: 2, B: 4, C: 6} + var s1 s + if err := Unmarshal(cborData, &s1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error. + wantS = s{A: 2, B: 4} + wantErrorMsg := "cbor: found duplicate map key \"1\" at map element index 2" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestStreamDupMapKeyToStructKeyAsInt(t *testing.T) { + type s struct { + A int `cbor:"1,keyasint"` + B int `cbor:"3,keyasint"` + C int `cbor:"5,keyasint"` + } + cborData := hexDecode("a40102030401030506") // {1:2, 3:4, 1:3, 5:6} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + // Duplicate key overwrites previous value (default). + wantS := s{A: 2, B: 4, C: 6} + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s1 s + if err := dec.Decode(&s1); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Decode() = %v (%T), want %v (%T)", s1, s1, wantS, wantS) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantS = s{A: 2, B: 4} + wantErrorMsg := "cbor: found duplicate map key \"1\" at map element index 2" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s2 s + if err := dec.Decode(&s2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +func TestUnmarshalDupMapKeyToStructNoMatchingField(t *testing.T) { + type s struct { + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + wantS := s{B: "B", C: "C", D: "D", E: "E"} + var s1 s + if err := Unmarshal(cborData, &s1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error even though map key "a" doesn't have a corresponding struct field. + wantS = s{B: "B", C: "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestStreamDupMapKeyToStructNoMatchingField(t *testing.T) { + type s struct { + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a6616161416162614261636143616161466164614461656145") // {"a": "A", "b": "B", "c": "C", "a": "F", "d": "D", "e": "E"} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + // Duplicate key overwrites previous value (default). + wantS := s{B: "B", C: "C", D: "D", E: "E"} + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s1 s + if err := dec.Decode(&s1); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Decode() = %v (%T), want %v (%T)", s1, s1, wantS, wantS) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantS = s{B: "B", C: "C"} + wantErrorMsg := "cbor: found duplicate map key \"a\" at map element index 3" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s2 s + if err := dec.Decode(&s2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Decode() = %v (%T), want %v (%T)", s2, s2, wantS, wantS) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +func TestUnmarshalDupMapKeyToStructKeyAsIntNoMatchingField(t *testing.T) { + type s struct { + B int `cbor:"3,keyasint"` + C int `cbor:"5,keyasint"` + } + cborData := hexDecode("a40102030401030506") // {1:2, 3:4, 1:3, 5:6} + + wantS := s{B: 4, C: 6} + var s1 s + if err := Unmarshal(cborData, &s1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error even though map key "a" doesn't have a corresponding struct field. + wantS = s{B: 4} + wantErrorMsg := "cbor: found duplicate map key \"1\" at map element index 2" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestStreamDupMapKeyToStructKeyAsIntNoMatchingField(t *testing.T) { + type s struct { + B int `cbor:"3,keyasint"` + C int `cbor:"5,keyasint"` + } + cborData := hexDecode("a40102030401030506") // {1:2, 3:4, 1:3, 5:6} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + // Duplicate key overwrites previous value (default). + wantS := s{B: 4, C: 6} + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s1 s + if err := dec.Decode(&s1); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Decode() = %v (%T), want %v (%T)", s1, s1, wantS, wantS) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantS = s{B: 4} + wantErrorMsg := "cbor: found duplicate map key \"1\" at map element index 2" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s2 s + if err := dec.Decode(&s2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Decode() = %v (%T), want %v (%T)", s2, s2, wantS, wantS) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +func TestUnmarshalDupMapKeyToStructWrongType(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a861616141fa47c35000026162614261636143fa47c3500003616161466164614461656145") // {"a": "A", 100000.0:2, "b": "B", "c": "C", 100000.0:3, "a": "F", "d": "D", "e": "E"} + + var s1 s + wantS := s{A: "A", B: "B", C: "C", D: "D", E: "E"} + wantErrorMsg := "cbor: cannot unmarshal" + if err := Unmarshal(cborData, &s1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + wantS = s{A: "A", B: "B", C: "C"} + wantErrorMsg = "cbor: found duplicate map key \"100000\" at map element index 4" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*DupMapKeyError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestStreamDupMapKeyToStructWrongType(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a861616141fa47c35000026162614261636143fa47c3500003616161466164614461656145") // {"a": "A", 100000.0:2, "b": "B", "c": "C", 100000.0:3, "a": "F", "d": "D", "e": "E"} + + var b []byte + for i := 0; i < 3; i++ { + b = append(b, cborData...) + } + + wantS := s{A: "A", B: "B", C: "C", D: "D", E: "E"} + wantErrorMsg := "cbor: cannot unmarshal" + dec := NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s1 s + if err := dec.Decode(&s1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + } + var v interface{} + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } + + // Duplicate key triggers error. + wantS = s{A: "A", B: "B", C: "C"} + wantErrorMsg = "cbor: found duplicate map key \"100000\" at map element index 4" + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + dec = dm.NewDecoder(bytes.NewReader(b)) + for i := 0; i < 3; i++ { + var s2 s + if err := dec.Decode(&s2); err == nil { + t.Errorf("Decode() didn't return an error") + } else if _, ok := err.(*DupMapKeyError); !ok { + t.Errorf("Decode() returned wrong error type %T, want (*DupMapKeyError)", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("Decode() returned error %q, want error containing %q", err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } + } + if err := dec.Decode(&v); err != io.EOF { + t.Errorf("Decode() returned error %v, want %v", err, io.EOF) + } +} + +func TestUnmarshalDupMapKeyToStructStringParseError(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a661fe6141616261426163614361fe61466164614461656145") // {"\xFE": "A", "b": "B", "c": "C", "\xFE": "F", "d": "D", "e": "E"} + wantS := s{A: "", B: "B", C: "C", D: "D", E: "E"} + wantErrorMsg := "cbor: invalid UTF-8 string" + + // Duplicate key doesn't overwrite previous value (default). + var s1 s + if err := Unmarshal(cborData, &s1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*SemanticError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*SemanticError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error. + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*SemanticError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*SemanticError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestUnmarshalDupMapKeyToStructIntParseError(t *testing.T) { + type s struct { + A int `cbor:"1,keyasint"` + B int `cbor:"3,keyasint"` + C int `cbor:"5,keyasint"` + } + cborData := hexDecode("a43bffffffffffffffff0203043bffffffffffffffff030506") // {-18446744073709551616:2, 3:4, -18446744073709551616:3, 5:6} + + // Duplicate key doesn't overwrite previous value (default). + wantS := s{B: 4, C: 6} + wantErrorMsg := "cbor: cannot unmarshal" + var s1 s + if err := Unmarshal(cborData, &s1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error. + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestUnmarshalDupMapKeyToStructWrongTypeParseError(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a68161fe614161626142616361438161fe61466164614461656145") // {["\xFE"]: "A", "b": "B", "c": "C", ["\xFE"]: "F", "d": "D", "e": "E"} + + // Duplicate key doesn't overwrite previous value (default). + wantS := s{A: "", B: "B", C: "C", D: "D", E: "E"} + wantErrorMsg := "cbor: cannot unmarshal" + var s1 s + if err := Unmarshal(cborData, &s1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error. + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestUnmarshalDupMapKeyToStructWrongTypeUnhashableError(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a6810061416162614261636143810061466164614461656145") // {[0]: "A", "b": "B", "c": "C", [0]: "F", "d": "D", "e": "E"} + wantS := s{A: "", B: "B", C: "C", D: "D", E: "E"} + + // Duplicate key doesn't overwrite previous value (default). + wantErrorMsg := "cbor: cannot unmarshal" + var s1 s + if err := Unmarshal(cborData, &s1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error. + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestUnmarshalDupMapKeyToStructTagTypeError(t *testing.T) { + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + D string `cbor:"d"` + E string `cbor:"e"` + } + cborData := hexDecode("a6c24901000000000000000061416162614261636143c24901000000000000000061466164614461656145") // {bignum(18446744073709551616): "A", "b": "B", "c": "C", bignum(18446744073709551616): "F", "d": "D", "e": "E"} + wantS := s{A: "", B: "B", C: "C", D: "D", E: "E"} + + // Duplicate key doesn't overwrite previous value (default). + wantErrorMsg := "cbor: cannot unmarshal" + var s1 s + if err := Unmarshal(cborData, &s1); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s1, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s1, s1, wantS, wantS) + } + + // Duplicate key triggers error. + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + var s2 s + if err := dm.Unmarshal(cborData, &s2); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, reflect.TypeOf(s2)) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(s2, wantS) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", cborData, s2, s2, wantS, wantS) + } +} + +func TestIndefiniteLengthArrayToArray(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantV interface{} + }{ + { + name: "CBOR empty array to Go 5 elem array", + cborData: hexDecode("9fff"), + wantV: [5]byte{}, + }, + { + name: "CBOR 3 elem array to Go 5 elem array", + cborData: hexDecode("9f010203ff"), + wantV: [5]byte{1, 2, 3, 0, 0}, + }, + { + name: "CBOR 10 elem array to Go 5 elem array", + cborData: hexDecode("9f0102030405060708090aff"), + wantV: [5]byte{1, 2, 3, 4, 5}, + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + v := reflect.New(reflect.TypeOf(tc.wantV)) + if err := Unmarshal(tc.cborData, v.Interface()); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } + if !reflect.DeepEqual(v.Elem().Interface(), tc.wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v.Elem().Interface(), v.Elem().Interface(), tc.wantV, tc.wantV) + } + }) + } +} + +func TestExceedMaxArrayElements(t *testing.T) { + testCases := []struct { + name string + opts DecOptions + cborData []byte + wantErrorMsg string + }{ + { + name: "array", + opts: DecOptions{MaxArrayElements: 16}, + cborData: hexDecode("910101010101010101010101010101010101"), + wantErrorMsg: "cbor: exceeded max number of elements 16 for CBOR array", + }, + { + name: "indefinite length array", + opts: DecOptions{MaxArrayElements: 16}, + cborData: hexDecode("9f0101010101010101010101010101010101ff"), + wantErrorMsg: "cbor: exceeded max number of elements 16 for CBOR array", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + dm, _ := tc.opts.DecMode() + var v interface{} + if err := dm.Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestExceedMaxMapPairs(t *testing.T) { + testCases := []struct { + name string + opts DecOptions + cborData []byte + wantErrorMsg string + }{ + { + name: "array", + opts: DecOptions{MaxMapPairs: 16}, + cborData: hexDecode("b101010101010101010101010101010101010101010101010101010101010101010101"), + wantErrorMsg: "cbor: exceeded max number of key-value pairs 16 for CBOR map", + }, + { + name: "indefinite length array", + opts: DecOptions{MaxMapPairs: 16}, + cborData: hexDecode("bf01010101010101010101010101010101010101010101010101010101010101010101ff"), + wantErrorMsg: "cbor: exceeded max number of key-value pairs 16 for CBOR map", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + dm, _ := tc.opts.DecMode() + var v interface{} + if err := dm.Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestDecIndefiniteLengthOption(t *testing.T) { + testCases := []struct { + name string + opts DecOptions + cborData []byte + wantErrorMsg string + }{ + { + name: "byte string", + opts: DecOptions{IndefLength: IndefLengthForbidden}, + cborData: hexDecode("5fff"), + wantErrorMsg: "cbor: indefinite-length byte string isn't allowed", + }, + { + name: "text string", + opts: DecOptions{IndefLength: IndefLengthForbidden}, + cborData: hexDecode("7fff"), + wantErrorMsg: "cbor: indefinite-length UTF-8 text string isn't allowed", + }, + { + name: "array", + opts: DecOptions{IndefLength: IndefLengthForbidden}, + cborData: hexDecode("9fff"), + wantErrorMsg: "cbor: indefinite-length array isn't allowed", + }, + { + name: "indefinite length array", + opts: DecOptions{IndefLength: IndefLengthForbidden}, + cborData: hexDecode("bfff"), + wantErrorMsg: "cbor: indefinite-length map isn't allowed", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + // Default option allows indefinite length items + var v interface{} + if err := Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned an error %v", tc.cborData, err) + } + + dm, _ := tc.opts.DecMode() + if err := dm.Unmarshal(tc.cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} + +func TestDecTagsMdOption(t *testing.T) { + cborData := hexDecode("c074323031332d30332d32315432303a30343a30305a") + wantErrorMsg := "cbor: CBOR tag isn't allowed" + + // Default option allows CBOR tags + var v interface{} + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned an error %v", cborData, err) + } + + // Decoding CBOR tags with TagsForbidden option returns error + dm, _ := DecOptions{TagsMd: TagsForbidden}.DecMode() + if err := dm.Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if err.Error() != wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err.Error(), wantErrorMsg) + } + + // Create DecMode with TagSet and TagsForbidden option returns error + wantErrorMsg = "cbor: cannot create DecMode with TagSet when TagsMd is TagsForbidden" + tags := NewTagSet() + _, err := DecOptions{TagsMd: TagsForbidden}.DecModeWithTags(tags) + if err == nil { + t.Errorf("DecModeWithTags() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecModeWithTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } + _, err = DecOptions{TagsMd: TagsForbidden}.DecModeWithSharedTags(tags) + if err == nil { + t.Errorf("DecModeWithSharedTags() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecModeWithSharedTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestDecModeInvalidIntDec(t *testing.T) { + wantErrorMsg := "cbor: invalid IntDec 101" + _, err := DecOptions{IntDec: 101}.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestIntDec(t *testing.T) { + dm, err := DecOptions{IntDec: IntDecConvertSigned}.DecMode() + if err != nil { + t.Errorf("DecMode() returned an error %+v", err) + } + + testCases := []struct { + name string + cborData []byte + wantObj interface{} + wantErrorMsg string + }{ + { + name: "CBOR pos int", + cborData: hexDecode("1a000f4240"), + wantObj: int64(1000000), + }, + { + name: "CBOR pos int overflows int64", + cborData: hexDecode("1bffffffffffffffff"), + wantErrorMsg: "18446744073709551615 overflows Go's int64", + }, + { + name: "CBOR neg int", + cborData: hexDecode("3903e7"), + wantObj: int64(-1000), + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v interface{} + err := dm.Unmarshal(tc.cborData, &v) + if err == nil { + if tc.wantErrorMsg != "" { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", tc.cborData, tc.wantErrorMsg) + } else if !reflect.DeepEqual(v, tc.wantObj) { + t.Errorf("Unmarshal(0x%x) return %v (%T), want %v (%T)", tc.cborData, v, v, tc.wantObj, tc.wantObj) + } + } else { + if tc.wantErrorMsg == "" { + t.Errorf("Unmarshal(0x%x) returned error %q", tc.cborData, err) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + } + }) + } +} + +func TestDecModeInvalidExtraError(t *testing.T) { + wantErrorMsg := "cbor: invalid ExtraReturnErrors 3" + _, err := DecOptions{ExtraReturnErrors: 3}.DecMode() + if err == nil { + t.Errorf("DecMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("DecMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestExtraErrorCondUnknowField(t *testing.T) { + type s struct { + A string + B string + C string + } + + dm, _ := DecOptions{}.DecMode() + dmUnknownFieldError, _ := DecOptions{ExtraReturnErrors: ExtraDecErrorUnknownField}.DecMode() + + testCases := []struct { + name string + cborData []byte + dm DecMode + wantObj interface{} + wantErrorMsg string + }{ + { + name: "field by field match", + cborData: hexDecode("a3614161616142616261436163"), // map[string]string{"A": "a", "B": "b", "C": "c"} + dm: dm, + wantObj: s{A: "a", B: "b", C: "c"}, + }, + { + name: "field by field match with ExtraDecErrorUnknownField", + cborData: hexDecode("a3614161616142616261436163"), // map[string]string{"A": "a", "B": "b", "C": "c"} + dm: dmUnknownFieldError, + wantObj: s{A: "a", B: "b", C: "c"}, + }, + { + name: "CBOR map less field", + cborData: hexDecode("a26141616161426162"), // map[string]string{"A": "a", "B": "b"} + dm: dm, + wantObj: s{A: "a", B: "b", C: ""}, + }, + { + name: "CBOR map less field with ExtraDecErrorUnknownField", + cborData: hexDecode("a26141616161426162"), // map[string]string{"A": "a", "B": "b"} + dm: dmUnknownFieldError, + wantObj: s{A: "a", B: "b", C: ""}, + }, + { + name: "CBOR map unknown field", + cborData: hexDecode("a461416161614261626143616361446164"), // map[string]string{"A": "a", "B": "b", "C": "c", "D": "d"} + dm: dm, + wantObj: s{A: "a", B: "b", C: "c"}, + }, + { + name: "CBOR map unknown field with ExtraDecErrorUnknownField", + cborData: hexDecode("a461416161614261626143616361446164"), // map[string]string{"A": "a", "B": "b", "C": "c", "D": "d"} + dm: dmUnknownFieldError, + wantErrorMsg: "cbor: found unknown field at map element index 3", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v s + err := tc.dm.Unmarshal(tc.cborData, &v) + if err == nil { + if tc.wantErrorMsg != "" { + t.Errorf("Unmarshal(0x%x) didn't return an error, want %q", tc.cborData, tc.wantErrorMsg) + } else if !reflect.DeepEqual(v, tc.wantObj) { + t.Errorf("Unmarshal(0x%x) return %v (%T), want %v (%T)", tc.cborData, v, v, tc.wantObj, tc.wantObj) + } + } else { + if tc.wantErrorMsg == "" { + t.Errorf("Unmarshal(0x%x) returned error %q", tc.cborData, err) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + } + }) + } +} + +func TestStreamExtraErrorCondUnknowField(t *testing.T) { + type s struct { + A string + B string + C string + } + + cborData := hexDecode("a461416161614461646142616261436163a3614161616142616261436163") // map[string]string{"A": "a", "D": "d", "B": "b", "C": "c"}, map[string]string{"A": "a", "B": "b", "C": "c"} + wantErrorMsg := "cbor: found unknown field at map element index 1" + wantObj := s{A: "a", B: "b", C: "c"} + + dmUnknownFieldError, _ := DecOptions{ExtraReturnErrors: ExtraDecErrorUnknownField}.DecMode() + dec := dmUnknownFieldError.NewDecoder(bytes.NewReader(cborData)) + + var v1 s + err := dec.Decode(&v1) + if err == nil { + t.Errorf("Decode() didn't return an error, want %q", wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Decode() returned error %q, want %q", err.Error(), wantErrorMsg) + } + + var v2 s + err = dec.Decode(&v2) + if err != nil { + t.Errorf("Decode() returned an error %v", err) + } else if !reflect.DeepEqual(v2, wantObj) { + t.Errorf("Decode() return %v (%T), want %v (%T)", v2, v2, wantObj, wantObj) + } +} + +// TestUnmarshalTagNum55799 is identical to TestUnmarshal, +// except that CBOR test data is prefixed with tag number 55799 (0xd9d9f7). +func TestUnmarshalTagNum55799(t *testing.T) { + tagNum55799 := hexDecode("d9d9f7") + + for _, tc := range unmarshalTests { + // Prefix tag number 55799 to CBOR test data + cborData := make([]byte, len(tc.cborData)+6) + copy(cborData, tagNum55799) + copy(cborData[3:], tagNum55799) + copy(cborData[6:], tc.cborData) + + // Test unmarshalling CBOR into empty interface. + var v interface{} + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else { + if tm, ok := tc.emptyInterfaceValue.(time.Time); ok { + if vt, ok := v.(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } else if !reflect.DeepEqual(v, tc.emptyInterfaceValue) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } + + // Test unmarshalling CBOR into RawMessage. + var r RawMessage + if err := Unmarshal(cborData, &r); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !bytes.Equal(r, tc.cborData) { + t.Errorf("Unmarshal(0x%x) returned RawMessage %v, want %v", cborData, r, tc.cborData) + } + + // Test unmarshalling CBOR into compatible data types. + for _, value := range tc.values { + v := reflect.New(reflect.TypeOf(value)) + vPtr := v.Interface() + if err := Unmarshal(cborData, vPtr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else { + if tm, ok := value.(time.Time); ok { + if vt, ok := v.Elem().Interface().(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v.Elem().Interface(), v.Elem().Interface(), value, value) + } + } else if !reflect.DeepEqual(v.Elem().Interface(), value) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v.Elem().Interface(), v.Elem().Interface(), value, value) + } + } + } + + // Test unmarshalling CBOR into incompatible data types. + for _, typ := range tc.wrongTypes { + v := reflect.New(typ) + vPtr := v.Interface() + if err := Unmarshal(cborData, vPtr); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", cborData, typ.String()) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), "cannot unmarshal") + } + } + } +} + +// TestUnmarshalFloatWithTagNum55799 is identical to TestUnmarshalFloat, +// except that CBOR test data is prefixed with tag number 55799 (0xd9d9f7). +func TestUnmarshalFloatWithTagNum55799(t *testing.T) { + tagNum55799 := hexDecode("d9d9f7") + + for _, tc := range unmarshalFloatTests { + // Prefix tag number 55799 to CBOR test data + cborData := make([]byte, len(tc.cborData)+3) + copy(cborData, tagNum55799) + copy(cborData[3:], tc.cborData) + + // Test unmarshalling CBOR into empty interface. + var v interface{} + if err := Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + testFloat(t, tc.cborData, v, tc.emptyInterfaceValue, tc.equalityThreshold) + } + + // Test unmarshalling CBOR into RawMessage. + var r RawMessage + if err := Unmarshal(tc.cborData, &r); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else if !bytes.Equal(r, tc.cborData) { + t.Errorf("Unmarshal(0x%x) returned RawMessage %v, want %v", tc.cborData, r, tc.cborData) + } + + // Test unmarshalling CBOR into compatible data types. + for _, value := range tc.values { + v := reflect.New(reflect.TypeOf(value)) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + testFloat(t, tc.cborData, v.Elem().Interface(), value, tc.equalityThreshold) + } + } + + // Test unmarshalling CBOR into incompatible data types. + for _, typ := range tc.wrongTypes { + v := reflect.New(typ) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", tc.cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborData, err.Error(), "cannot unmarshal") + } + } + } +} + +func TestUnmarshalTagNum55799AsElement(t *testing.T) { + testCases := []struct { + name string + cborData []byte + emptyInterfaceValue interface{} + values []interface{} + wrongTypes []reflect.Type + }{ + { + "array", + hexDecode("d9d9f783d9d9f701d9d9f702d9d9f703"), // 55799([55799(1), 55799(2), 55799(3)]) + []interface{}{uint64(1), uint64(2), uint64(3)}, + []interface{}{[]interface{}{uint64(1), uint64(2), uint64(3)}, []byte{1, 2, 3}, []int{1, 2, 3}, []uint{1, 2, 3}, [0]int{}, [1]int{1}, [3]int{1, 2, 3}, [5]int{1, 2, 3, 0, 0}, []float32{1, 2, 3}, []float64{1, 2, 3}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeString, typeBool, typeStringSlice, typeMapStringInt, reflect.TypeOf([3]string{}), typeTag, typeRawTag}, + }, + { + "map", + hexDecode("d9d9f7a2d9d9f701d9d9f702d9d9f703d9d9f704"), // 55799({55799(1): 55799(2), 55799(3): 55799(4)}) + map[interface{}]interface{}{uint64(1): uint64(2), uint64(3): uint64(4)}, + []interface{}{map[interface{}]interface{}{uint64(1): uint64(2), uint64(3): uint64(4)}, map[uint]int{1: 2, 3: 4}, map[int]uint{1: 2, 3: 4}}, + []reflect.Type{typeUint8, typeUint16, typeUint32, typeUint64, typeInt8, typeInt16, typeInt32, typeInt64, typeFloat32, typeFloat64, typeByteSlice, typeByteArray, typeString, typeBool, typeIntSlice, typeMapStringInt, typeTag, typeRawTag}, + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + // Test unmarshalling CBOR into empty interface. + var v interface{} + if err := Unmarshal(tc.cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + if tm, ok := tc.emptyInterfaceValue.(time.Time); ok { + if vt, ok := v.(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } else if !reflect.DeepEqual(v, tc.emptyInterfaceValue) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } + + // Test unmarshalling CBOR into compatible data types. + for _, value := range tc.values { + v := reflect.New(reflect.TypeOf(value)) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", tc.cborData, err) + } else { + if tm, ok := value.(time.Time); ok { + if vt, ok := v.Elem().Interface().(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v.Elem().Interface(), v.Elem().Interface(), value, value) + } + } else if !reflect.DeepEqual(v.Elem().Interface(), value) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", tc.cborData, v.Elem().Interface(), v.Elem().Interface(), value, value) + } + } + } + + // Test unmarshalling CBOR into incompatible data types. + for _, typ := range tc.wrongTypes { + v := reflect.New(typ) + vPtr := v.Interface() + if err := Unmarshal(tc.cborData, vPtr); err == nil { + t.Errorf("Unmarshal(0x%x, %s) didn't return an error", tc.cborData, typ.String()) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", tc.cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.cborData, err.Error(), "cannot unmarshal") + } + } + }) + } +} + +func TestUnmarshalTagNum55799ToBinaryUnmarshaler(t *testing.T) { + cborData := hexDecode("d9d9f74800000000499602d2") // 55799(h'00000000499602D2') + wantObj := number(1234567890) + + var v number + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantObj, wantObj) + } +} + +func TestUnmarshalTagNum55799ToUnmarshaler(t *testing.T) { + cborData := hexDecode("d9d9f7d864a1636e756d01") // 55799(100({"num": 1})) + wantObj := number3(1) + + var v number3 + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantObj, wantObj) + } +} + +func TestUnmarshalTagNum55799ToRegisteredGoType(t *testing.T) { + type myInt int + typ := reflect.TypeOf(myInt(0)) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, typ, 125); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", typ, 125, err) + } + + dm, _ := DecOptions{}.DecModeWithTags(tags) + + cborData := hexDecode("d9d9f7d87d01") // 55799(125(1)) + wantObj := myInt(1) + + var v myInt + if err := dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantObj, wantObj) + } +} + +// TODO: wait for clarification from 7049bis https://github.com/cbor-wg/CBORbis/issues/183 +// Nested tag number 55799 may be stripeed as well depending on 7049bis clarification. +func TestUnmarshalNestedTagNum55799ToEmptyInterface(t *testing.T) { + cborData := hexDecode("d864d9d9f701") // 100(55799(1)) + wantObj := Tag{100, Tag{55799, uint64(1)}} + + var v interface{} + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantObj, wantObj) + } +} + +func TestUnmarshalNestedTagNum55799ToValue(t *testing.T) { + cborData := hexDecode("d864d9d9f701") // 100(55799(1)) + wantObj := 1 + + var v int + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantObj, wantObj) + } +} + +func TestUnmarshalNestedTagNum55799ToTag(t *testing.T) { + cborData := hexDecode("d864d9d9f701") // 100(55799(1)) + wantObj := Tag{100, Tag{55799, uint64(1)}} + + var v Tag + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantObj, wantObj) + } +} + +func TestUnmarshalNestedTagNum55799ToTime(t *testing.T) { + cborData := hexDecode("c0d9d9f774323031332d30332d32315432303a30343a30305a") // 0(55799("2013-03-21T20:04:00Z")) + wantErrorMsg := "tag number 0 must be followed by text string, got tag" + + var v time.Time + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error", cborData) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %s, want %s", cborData, err.Error(), wantErrorMsg) + } +} + +func TestUnmarshalNestedTagNum55799ToBinaryUnmarshaler(t *testing.T) { + cborData := hexDecode("d864d9d9f74800000000499602d2") // 100(55799(h'00000000499602D2')) + wantObj := number(1234567890) + + var v number + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } else if !reflect.DeepEqual(v, wantObj) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantObj, wantObj) + } +} + +func TestUnmarshalNestedTagNum55799ToUnmarshaler(t *testing.T) { + cborData := hexDecode("d864d9d9f7a1636e756d01") // 100(55799({"num": 1})) + wantErrorMsg := "wrong tag content type" + + var v number3 + if err := Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error", cborData) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %s, want %s", cborData, err.Error(), wantErrorMsg) + } +} + +func TestUnmarshalNestedTagNum55799ToRegisteredGoType(t *testing.T) { + type myInt int + typ := reflect.TypeOf(myInt(0)) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, typ, 125); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", typ, 125, err) + } + + dm, _ := DecOptions{}.DecModeWithTags(tags) + + cborData := hexDecode("d87dd9d9f701") // 125(55799(1)) + wantErrorMsg := "cbor: wrong tag number for cbor.myInt, got [125 55799], expected [125]" + + var v myInt + if err := dm.Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal() didn't return error") + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %s, want %s", cborData, err.Error(), wantErrorMsg) + } +} + +func TestUnmarshalPosIntToBigInt(t *testing.T) { + cborData := hexDecode("1bffffffffffffffff") // 18446744073709551615 + wantEmptyInterfaceValue := uint64(18446744073709551615) + wantBigIntValue := bigIntOrPanic("18446744073709551615") + + var v1 interface{} + if err := Unmarshal(cborData, &v1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", cborData, err) + } else if !reflect.DeepEqual(v1, wantEmptyInterfaceValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", cborData, v1, v1, wantEmptyInterfaceValue, wantEmptyInterfaceValue) + } + + var v2 big.Int + if err := Unmarshal(cborData, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", cborData, err) + } else if !reflect.DeepEqual(v2, wantBigIntValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", cborData, v2, v2, wantBigIntValue, wantBigIntValue) + } +} + +func TestUnmarshalNegIntToBigInt(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantEmptyInterfaceValue interface{} + wantBigIntValue big.Int + }{ + { + name: "fit Go int64", + cborData: hexDecode("3b7fffffffffffffff"), // -9223372036854775808 + wantEmptyInterfaceValue: int64(-9223372036854775808), + wantBigIntValue: bigIntOrPanic("-9223372036854775808"), + }, + { + name: "overflow Go int64", + cborData: hexDecode("3b8000000000000000"), // -9223372036854775809 + wantEmptyInterfaceValue: bigIntOrPanic("-9223372036854775809"), + wantBigIntValue: bigIntOrPanic("-9223372036854775809"), + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v1 interface{} + if err := Unmarshal(tc.cborData, &v1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", tc.cborData, err) + } else if !reflect.DeepEqual(v1, tc.wantEmptyInterfaceValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", tc.cborData, v1, v1, tc.wantEmptyInterfaceValue, tc.wantEmptyInterfaceValue) + } + + var v2 big.Int + if err := Unmarshal(tc.cborData, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", tc.cborData, err) + } else if !reflect.DeepEqual(v2, tc.wantBigIntValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", tc.cborData, v2, v2, tc.wantBigIntValue, tc.wantBigIntValue) + } + }) + } +} + +func TestUnmarshalTag2(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantEmptyInterfaceValue interface{} + wantValues []interface{} + }{ + { + name: "fit Go int64", + cborData: hexDecode("c2430f4240"), // 2(1000000) + wantEmptyInterfaceValue: bigIntOrPanic("1000000"), + wantValues: []interface{}{ + int64(1000000), + uint64(1000000), + float32(1000000), + float64(1000000), + bigIntOrPanic("1000000"), + }, + }, + { + name: "fit Go uint64", + cborData: hexDecode("c248ffffffffffffffff"), // 2(18446744073709551615) + wantEmptyInterfaceValue: bigIntOrPanic("18446744073709551615"), + wantValues: []interface{}{ + uint64(18446744073709551615), + float32(18446744073709551615), + float64(18446744073709551615), + bigIntOrPanic("18446744073709551615"), + }, + }, + { + name: "fit Go uint64 with leading zeros", + cborData: hexDecode("c24900ffffffffffffffff"), // 2(18446744073709551615) + wantEmptyInterfaceValue: bigIntOrPanic("18446744073709551615"), + wantValues: []interface{}{ + uint64(18446744073709551615), + float32(18446744073709551615), + float64(18446744073709551615), + bigIntOrPanic("18446744073709551615"), + }, + }, + { + name: "overflow Go uint64", + cborData: hexDecode("c249010000000000000000"), // 2(18446744073709551616) + wantEmptyInterfaceValue: bigIntOrPanic("18446744073709551616"), + wantValues: []interface{}{ + bigIntOrPanic("18446744073709551616"), + }, + }, + { + name: "overflow Go uint64 with leading zeros", + cborData: hexDecode("c24b0000010000000000000000"), // 2(18446744073709551616) + wantEmptyInterfaceValue: bigIntOrPanic("18446744073709551616"), + wantValues: []interface{}{ + bigIntOrPanic("18446744073709551616"), + }, + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v1 interface{} + if err := Unmarshal(tc.cborData, &v1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", tc.cborData, err) + } else if !reflect.DeepEqual(v1, tc.wantEmptyInterfaceValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", tc.cborData, v1, v1, tc.wantEmptyInterfaceValue, tc.wantEmptyInterfaceValue) + } + + for _, wantValue := range tc.wantValues { + v := reflect.New(reflect.TypeOf(wantValue)) + if err := Unmarshal(tc.cborData, v.Interface()); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", tc.cborData, err) + } else if !reflect.DeepEqual(v.Elem().Interface(), wantValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", tc.cborData, v.Elem().Interface(), v.Elem().Interface(), wantValue, wantValue) + } + } + }) + } +} + +func TestUnmarshalTag3(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantEmptyInterfaceValue interface{} + wantValues []interface{} + }{ + { + name: "fit Go int64", + cborData: hexDecode("c3487fffffffffffffff"), // 3(-9223372036854775808) + wantEmptyInterfaceValue: bigIntOrPanic("-9223372036854775808"), + wantValues: []interface{}{ + int64(-9223372036854775808), + float32(-9223372036854775808), + float64(-9223372036854775808), + bigIntOrPanic("-9223372036854775808"), + }, + }, + { + name: "fit Go int64 with leading zeros", + cborData: hexDecode("c349007fffffffffffffff"), // 3(-9223372036854775808) + wantEmptyInterfaceValue: bigIntOrPanic("-9223372036854775808"), + wantValues: []interface{}{ + int64(-9223372036854775808), + float32(-9223372036854775808), + float64(-9223372036854775808), + bigIntOrPanic("-9223372036854775808"), + }, + }, + { + name: "overflow Go int64", + cborData: hexDecode("c349010000000000000000"), // 3(-18446744073709551617) + wantEmptyInterfaceValue: bigIntOrPanic("-18446744073709551617"), + wantValues: []interface{}{ + bigIntOrPanic("-18446744073709551617"), + }, + }, + { + name: "overflow Go int64 with leading zeros", + cborData: hexDecode("c34b0000010000000000000000"), // 3(-18446744073709551617) + wantEmptyInterfaceValue: bigIntOrPanic("-18446744073709551617"), + wantValues: []interface{}{ + bigIntOrPanic("-18446744073709551617"), + }, + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v1 interface{} + if err := Unmarshal(tc.cborData, &v1); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", tc.cborData, err) + } else if !reflect.DeepEqual(v1, tc.wantEmptyInterfaceValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", tc.cborData, v1, v1, tc.wantEmptyInterfaceValue, tc.wantEmptyInterfaceValue) + } + + for _, wantValue := range tc.wantValues { + v := reflect.New(reflect.TypeOf(wantValue)) + if err := Unmarshal(tc.cborData, v.Interface()); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %+v", tc.cborData, err) + } else if !reflect.DeepEqual(v.Elem().Interface(), wantValue) { + t.Errorf("Unmarshal(0x%x) returned %v (%T), want %v (%T)", tc.cborData, v.Elem().Interface(), v.Elem().Interface(), wantValue, wantValue) + } + } + }) + } +} + +func TestUnmarshalInvalidTagBignum(t *testing.T) { + typeBigIntSlice := reflect.TypeOf([]big.Int{}) + + testCases := []struct { + name string + cborData []byte + decodeToTypes []reflect.Type + wantErrorMsg string + }{ + { + name: "Tag 2 with string", + cborData: hexDecode("c27f657374726561646d696e67ff"), + decodeToTypes: []reflect.Type{typeIntf, typeBigInt}, + wantErrorMsg: "cbor: tag number 2 or 3 must be followed by byte string, got UTF-8 text string", + }, + { + name: "Tag 3 with string", + cborData: hexDecode("c37f657374726561646d696e67ff"), + decodeToTypes: []reflect.Type{typeIntf, typeBigInt}, + wantErrorMsg: "cbor: tag number 2 or 3 must be followed by byte string, got UTF-8 text string", + }, + { + name: "Tag 3 with negavtive int", + cborData: hexDecode("81C330"), // [3(-17)] + decodeToTypes: []reflect.Type{typeIntf, typeBigIntSlice}, + wantErrorMsg: "cbor: tag number 2 or 3 must be followed by byte string, got negative integer", + }, + } + for _, tc := range testCases { + for _, decodeToType := range tc.decodeToTypes { + t.Run(tc.name+" decode to "+decodeToType.String(), func(t *testing.T) { + v := reflect.New(decodeToType) + if err := Unmarshal(tc.cborData, v.Interface()); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error, want error msg %q", tc.cborData, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", tc.cborData, err, tc.wantErrorMsg) + } + }) + } + } +} diff --git a/vendor/github.com/fxamacker/cbor/doc.go b/vendor/github.com/fxamacker/cbor/doc.go new file mode 100644 index 0000000..51db0e0 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/doc.go @@ -0,0 +1,130 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +/* +Package cbor is a fast & safe CBOR encoder & decoder (RFC 7049) with a +standard API + toarray & keyasint struct tags, CBOR tags, float64->32->16, +CTAP2 & Canonical CBOR, duplicate map key options, and is customizable via +simple API. + +Encoding options allow "preferred serialization" by encoding integers and floats +to their smallest forms (e.g. float16) when values fit. + +Struct tags like "keyasint", "toarray" and "omitempty" make CBOR data smaller +and easier to use with structs. + +For example, "toarray" tag makes struct fields encode to CBOR array elements. And +"keyasint" makes a field encode to an element of CBOR map with specified int key. + +Latest docs can be viewed at https://github.com/fxamacker/cbor#cbor-library-in-go + +Basics + +The Quick Start guide is at https://github.com/fxamacker/cbor#quick-start + +Function signatures identical to encoding/json include: + + Marshal, Unmarshal, NewEncoder, NewDecoder, (*Encoder).Encode, (*Decoder).Decode. + +Standard interfaces include: + + BinaryMarshaler, BinaryUnmarshaler, Marshaler, and Unmarshaler. + +Custom encoding and decoding is possible by implementing standard interfaces for +user-defined Go types. + +Codec functions are available at package-level (using defaults options) or by +creating modes from options at runtime. + +"Mode" in this API means definite way of encoding (EncMode) or decoding (DecMode). + +EncMode and DecMode interfaces are created from EncOptions or DecOptions structs. + + em := cbor.EncOptions{...}.EncMode() + em := cbor.CanonicalEncOptions().EncMode() + em := cbor.CTAP2EncOptions().EncMode() + +Modes use immutable options to avoid side-effects and simplify concurrency. Behavior of +modes won't accidentally change at runtime after they're created. + +Modes are intended to be reused and are safe for concurrent use. + +EncMode and DecMode Interfaces + + // EncMode interface uses immutable options and is safe for concurrent use. + type EncMode interface { + Marshal(v interface{}) ([]byte, error) + NewEncoder(w io.Writer) *Encoder + EncOptions() EncOptions // returns copy of options + } + + // DecMode interface uses immutable options and is safe for concurrent use. + type DecMode interface { + Unmarshal(data []byte, v interface{}) error + NewDecoder(r io.Reader) *Decoder + DecOptions() DecOptions // returns copy of options + } + +Using Default Encoding Mode + + b, err := cbor.Marshal(v) + + encoder := cbor.NewEncoder(w) + err = encoder.Encode(v) + +Using Default Decoding Mode + + err := cbor.Unmarshal(b, &v) + + decoder := cbor.NewDecoder(r) + err = decoder.Decode(&v) + +Creating and Using Encoding Modes + + // Create EncOptions using either struct literal or a function. + opts := cbor.CanonicalEncOptions() + + // If needed, modify encoding options + opts.Time = cbor.TimeUnix + + // Create reusable EncMode interface with immutable options, safe for concurrent use. + em, err := opts.EncMode() + + // Use EncMode like encoding/json, with same function signatures. + b, err := em.Marshal(v) + // or + encoder := em.NewEncoder(w) + err := encoder.Encode(v) + + // NOTE: Both em.Marshal(v) and encoder.Encode(v) use encoding options + // specified during creation of em (encoding mode). + +CBOR Options + +Predefined Encoding Options: https://github.com/fxamacker/cbor#predefined-encoding-options + +Encoding Options: https://github.com/fxamacker/cbor#encoding-options + +Decoding Options: https://github.com/fxamacker/cbor#decoding-options + +Struct Tags + +Struct tags like `cbor:"name,omitempty"` and `json:"name,omitempty"` work as expected. +If both struct tags are specified then `cbor` is used. + +Struct tags like "keyasint", "toarray", and "omitempty" make it easy to use +very compact formats like COSE and CWT (CBOR Web Tokens) with structs. + +For example, "toarray" makes struct fields encode to array elements. And "keyasint" +makes struct fields encode to elements of CBOR map with int keys. + +https://raw.githubusercontent.com/fxamacker/images/master/cbor/v2.0.0/cbor_easy_api.png + +Struct tags are listed at https://github.com/fxamacker/cbor#struct-tags-1 + +Tests and Fuzzing + +Over 375 tests are included in this package. Cover-guided fuzzing is handled by +fxamacker/cbor-fuzz. +*/ +package cbor diff --git a/vendor/github.com/fxamacker/cbor/encode.go b/vendor/github.com/fxamacker/cbor/encode.go new file mode 100644 index 0000000..95d2c23 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/encode.go @@ -0,0 +1,1481 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "bytes" + "encoding" + "encoding/binary" + "errors" + "io" + "math" + "math/big" + "reflect" + "sort" + "strconv" + "sync" + "time" + + "github.com/x448/float16" +) + +// Marshal returns the CBOR encoding of v using default encoding options. +// See EncOptions for encoding options. +// +// Marshal uses the following encoding rules: +// +// If value implements the Marshaler interface, Marshal calls its +// MarshalCBOR method. +// +// If value implements encoding.BinaryMarshaler, Marhsal calls its +// MarshalBinary method and encode it as CBOR byte string. +// +// Boolean values encode as CBOR booleans (type 7). +// +// Positive integer values encode as CBOR positive integers (type 0). +// +// Negative integer values encode as CBOR negative integers (type 1). +// +// Floating point values encode as CBOR floating points (type 7). +// +// String values encode as CBOR text strings (type 3). +// +// []byte values encode as CBOR byte strings (type 2). +// +// Array and slice values encode as CBOR arrays (type 4). +// +// Map values encode as CBOR maps (type 5). +// +// Struct values encode as CBOR maps (type 5). Each exported struct field +// becomes a pair with field name encoded as CBOR text string (type 3) and +// field value encoded based on its type. See struct tag option "keyasint" +// to encode field name as CBOR integer (type 0 and 1). Also see struct +// tag option "toarray" for special field "_" to encode struct values as +// CBOR array (type 4). +// +// Marshal supports format string stored under the "cbor" key in the struct +// field's tag. CBOR format string can specify the name of the field, +// "omitempty" and "keyasint" options, and special case "-" for field omission. +// If "cbor" key is absent, Marshal uses "json" key. +// +// Struct field name is treated as integer if it has "keyasint" option in +// its format string. The format string must specify an integer as its +// field name. +// +// Special struct field "_" is used to specify struct level options, such as +// "toarray". "toarray" option enables Go struct to be encoded as CBOR array. +// "omitempty" is disabled by "toarray" to ensure that the same number +// of elements are encoded every time. +// +// Anonymous struct fields are marshaled as if their exported fields +// were fields in the outer struct. Marshal follows the same struct fields +// visibility rules used by JSON encoding package. +// +// time.Time values encode as text strings specified in RFC3339 or numerical +// representation of seconds since January 1, 1970 UTC depending on +// EncOptions.Time setting. Also See EncOptions.TimeTag to encode +// time.Time as CBOR tag with tag number 0 or 1. +// +// big.Int values encode as CBOR integers (type 0 and 1) if values fit. +// Otherwise, big.Int values encode as CBOR bignums (tag 2 and 3). See +// EncOptions.BigIntConvert to always encode big.Int values as CBOR +// bignums. +// +// Pointer values encode as the value pointed to. +// +// Interface values encode as the value stored in the interface. +// +// Nil slice/map/pointer/interface values encode as CBOR nulls (type 7). +// +// Values of other types cannot be encoded in CBOR. Attempting +// to encode such a value causes Marshal to return an UnsupportedTypeError. +func Marshal(v interface{}) ([]byte, error) { + return defaultEncMode.Marshal(v) +} + +// Marshaler is the interface implemented by types that can marshal themselves +// into valid CBOR. +type Marshaler interface { + MarshalCBOR() ([]byte, error) +} + +// UnsupportedTypeError is returned by Marshal when attempting to encode value +// of an unsupported type. +type UnsupportedTypeError struct { + Type reflect.Type +} + +func (e *UnsupportedTypeError) Error() string { + return "cbor: unsupported type: " + e.Type.String() +} + +// SortMode identifies supported sorting order. +type SortMode int + +const ( + // SortNone means no sorting. + SortNone SortMode = 0 + + // SortLengthFirst causes map keys or struct fields to be sorted such that: + // - If two keys have different lengths, the shorter one sorts earlier; + // - If two keys have the same length, the one with the lower value in + // (byte-wise) lexical order sorts earlier. + // It is used in "Canonical CBOR" encoding in RFC 7049 3.9. + SortLengthFirst SortMode = 1 + + // SortBytewiseLexical causes map keys or struct fields to be sorted in the + // bytewise lexicographic order of their deterministic CBOR encodings. + // It is used in "CTAP2 Canonical CBOR" and "Core Deterministic Encoding" + // in RFC 7049bis. + SortBytewiseLexical SortMode = 2 + + // SortCanonical is used in "Canonical CBOR" encoding in RFC 7049 3.9. + SortCanonical SortMode = SortLengthFirst + + // SortCTAP2 is used in "CTAP2 Canonical CBOR". + SortCTAP2 SortMode = SortBytewiseLexical + + // SortCoreDeterministic is used in "Core Deterministic Encoding" in RFC 7049bis. + SortCoreDeterministic SortMode = SortBytewiseLexical + + maxSortMode SortMode = 3 +) + +func (sm SortMode) valid() bool { + return sm < maxSortMode +} + +// ShortestFloatMode specifies which floating-point format should +// be used as the shortest possible format for CBOR encoding. +// It is not used for encoding Infinity and NaN values. +type ShortestFloatMode int + +const ( + // ShortestFloatNone makes float values encode without any conversion. + // This is the default for ShortestFloatMode in v1. + // E.g. a float32 in Go will encode to CBOR float32. And + // a float64 in Go will encode to CBOR float64. + ShortestFloatNone ShortestFloatMode = iota + + // ShortestFloat16 specifies float16 as the shortest form that preserves value. + // E.g. if float64 can convert to float32 while preserving value, then + // encoding will also try to convert float32 to float16. So a float64 might + // encode as CBOR float64, float32 or float16 depending on the value. + ShortestFloat16 + + maxShortestFloat +) + +func (sfm ShortestFloatMode) valid() bool { + return sfm < maxShortestFloat +} + +// NaNConvertMode specifies how to encode NaN and overrides ShortestFloatMode. +// ShortestFloatMode is not used for encoding Infinity and NaN values. +type NaNConvertMode int + +const ( + // NaNConvert7e00 always encodes NaN to 0xf97e00 (CBOR float16 = 0x7e00). + NaNConvert7e00 NaNConvertMode = iota + + // NaNConvertNone never modifies or converts NaN to other representations + // (float64 NaN stays float64, etc. even if it can use float16 without losing + // any bits). + NaNConvertNone + + // NaNConvertPreserveSignal converts NaN to the smallest form that preserves + // value (quiet bit + payload) as described in RFC 7049bis Draft 12. + NaNConvertPreserveSignal + + // NaNConvertQuiet always forces quiet bit = 1 and shortest form that preserves + // NaN payload. + NaNConvertQuiet + + maxNaNConvert +) + +func (ncm NaNConvertMode) valid() bool { + return ncm < maxNaNConvert +} + +// InfConvertMode specifies how to encode Infinity and overrides ShortestFloatMode. +// ShortestFloatMode is not used for encoding Infinity and NaN values. +type InfConvertMode int + +const ( + // InfConvertFloat16 always converts Inf to lossless IEEE binary16 (float16). + InfConvertFloat16 InfConvertMode = iota + + // InfConvertNone never converts (used by CTAP2 Canonical CBOR). + InfConvertNone + + maxInfConvert +) + +func (icm InfConvertMode) valid() bool { + return icm < maxInfConvert +} + +// TimeMode specifies how to encode time.Time values. +type TimeMode int + +const ( + // TimeUnix causes time.Time to be encoded as epoch time in integer with second precision. + TimeUnix TimeMode = iota + + // TimeUnixMicro causes time.Time to be encoded as epoch time in float-point rounded to microsecond precision. + TimeUnixMicro + + // TimeUnixDynamic causes time.Time to be encoded as integer if time.Time doesn't have fractional seconds, + // otherwise float-point rounded to microsecond precision. + TimeUnixDynamic + + // TimeRFC3339 causes time.Time to be encoded as RFC3339 formatted string with second precision. + TimeRFC3339 + + // TimeRFC3339Nano causes time.Time to be encoded as RFC3339 formatted string with nanosecond precision. + TimeRFC3339Nano + + maxTimeMode +) + +func (tm TimeMode) valid() bool { + return tm < maxTimeMode +} + +// BigIntConvertMode specifies how to encode big.Int values. +type BigIntConvertMode int + +const ( + // BigIntConvertShortest makes big.Int encode to CBOR integer if value fits. + // E.g. if big.Int value can be converted to CBOR integer while preserving + // value, encoder will encode it to CBOR interger (major type 0 or 1). + BigIntConvertShortest BigIntConvertMode = iota + + // BigIntConvertNone makes big.Int encode to CBOR bignum (tag 2 or 3) without + // converting it to another CBOR type. + BigIntConvertNone + + maxBigIntConvert +) + +func (bim BigIntConvertMode) valid() bool { + return bim < maxBigIntConvert +} + +// EncOptions specifies encoding options. +type EncOptions struct { + // Sort specifies sorting order. + Sort SortMode + + // ShortestFloat specifies the shortest floating-point encoding that preserves + // the value being encoded. + ShortestFloat ShortestFloatMode + + // NaNConvert specifies how to encode NaN and it overrides ShortestFloatMode. + NaNConvert NaNConvertMode + + // InfConvert specifies how to encode Inf and it overrides ShortestFloatMode. + InfConvert InfConvertMode + + // BigIntConvert specifies how to encode big.Int values. + BigIntConvert BigIntConvertMode + + // Time specifies how to encode time.Time. + Time TimeMode + + // TimeTag allows time.Time to be encoded with a tag number. + // RFC3339 format gets tag number 0, and numeric epoch time tag number 1. + TimeTag EncTagMode + + // IndefLength specifies whether to allow indefinite length CBOR items. + IndefLength IndefLengthMode + + // TagsMd specifies whether to allow CBOR tags (major type 6). + TagsMd TagsMode +} + +// CanonicalEncOptions returns EncOptions for "Canonical CBOR" encoding, +// defined in RFC 7049 Section 3.9 with the following rules: +// +// 1. "Integers must be as small as possible." +// 2. "The expression of lengths in major types 2 through 5 must be as short as possible." +// 3. The keys in every map must be sorted in length-first sorting order. +// See SortLengthFirst for details. +// 4. "Indefinite-length items must be made into definite-length items." +// 5. "If a protocol allows for IEEE floats, then additional canonicalization rules might +// need to be added. One example rule might be to have all floats start as a 64-bit +// float, then do a test conversion to a 32-bit float; if the result is the same numeric +// value, use the shorter value and repeat the process with a test conversion to a +// 16-bit float. (This rule selects 16-bit float for positive and negative Infinity +// as well.) Also, there are many representations for NaN. If NaN is an allowed value, +// it must always be represented as 0xf97e00." +// +func CanonicalEncOptions() EncOptions { + return EncOptions{ + Sort: SortCanonical, + ShortestFloat: ShortestFloat16, + NaNConvert: NaNConvert7e00, + InfConvert: InfConvertFloat16, + IndefLength: IndefLengthForbidden, + } +} + +// CTAP2EncOptions returns EncOptions for "CTAP2 Canonical CBOR" encoding, +// defined in CTAP specification, with the following rules: +// +// 1. "Integers must be encoded as small as possible." +// 2. "The representations of any floating-point values are not changed." +// 3. "The expression of lengths in major types 2 through 5 must be as short as possible." +// 4. "Indefinite-length items must be made into definite-length items."" +// 5. The keys in every map must be sorted in bytewise lexicographic order. +// See SortBytewiseLexical for details. +// 6. "Tags as defined in Section 2.4 in [RFC7049] MUST NOT be present." +// +func CTAP2EncOptions() EncOptions { + return EncOptions{ + Sort: SortCTAP2, + ShortestFloat: ShortestFloatNone, + NaNConvert: NaNConvertNone, + InfConvert: InfConvertNone, + IndefLength: IndefLengthForbidden, + TagsMd: TagsForbidden, + } +} + +// CoreDetEncOptions returns EncOptions for "Core Deterministic" encoding, +// defined in RFC 7049bis with the following rules: +// +// 1. "Preferred serialization MUST be used. In particular, this means that arguments +// (see Section 3) for integers, lengths in major types 2 through 5, and tags MUST +// be as short as possible" +// "Floating point values also MUST use the shortest form that preserves the value" +// 2. "Indefinite-length items MUST NOT appear." +// 3. "The keys in every map MUST be sorted in the bytewise lexicographic order of +// their deterministic encodings." +// +func CoreDetEncOptions() EncOptions { + return EncOptions{ + Sort: SortCoreDeterministic, + ShortestFloat: ShortestFloat16, + NaNConvert: NaNConvert7e00, + InfConvert: InfConvertFloat16, + IndefLength: IndefLengthForbidden, + } +} + +// PreferredUnsortedEncOptions returns EncOptions for "Preferred Serialization" encoding, +// defined in RFC 7049bis with the following rules: +// +// 1. "The preferred serialization always uses the shortest form of representing the argument +// (Section 3);" +// 2. "it also uses the shortest floating-point encoding that preserves the value being +// encoded (see Section 5.5)." +// "The preferred encoding for a floating-point value is the shortest floating-point encoding +// that preserves its value, e.g., 0xf94580 for the number 5.5, and 0xfa45ad9c00 for the +// number 5555.5, unless the CBOR-based protocol specifically excludes the use of the shorter +// floating-point encodings. For NaN values, a shorter encoding is preferred if zero-padding +// the shorter significand towards the right reconstitutes the original NaN value (for many +// applications, the single NaN encoding 0xf97e00 will suffice)." +// 3. "Definite length encoding is preferred whenever the length is known at the time the +// serialization of the item starts." +// +func PreferredUnsortedEncOptions() EncOptions { + return EncOptions{ + Sort: SortNone, + ShortestFloat: ShortestFloat16, + NaNConvert: NaNConvert7e00, + InfConvert: InfConvertFloat16, + } +} + +// EncMode returns EncMode with immutable options and no tags (safe for concurrency). +func (opts EncOptions) EncMode() (EncMode, error) { + return opts.encMode() +} + +// EncModeWithTags returns EncMode with options and tags that are both immutable (safe for concurrency). +func (opts EncOptions) EncModeWithTags(tags TagSet) (EncMode, error) { + if opts.TagsMd == TagsForbidden { + return nil, errors.New("cbor: cannot create EncMode with TagSet when TagsMd is TagsForbidden") + } + if tags == nil { + return nil, errors.New("cbor: cannot create EncMode with nil value as TagSet") + } + em, err := opts.encMode() + if err != nil { + return nil, err + } + // Copy tags + ts := tagSet(make(map[reflect.Type]*tagItem)) + syncTags := tags.(*syncTagSet) + syncTags.RLock() + for contentType, tag := range syncTags.t { + if tag.opts.EncTag != EncTagNone { + ts[contentType] = tag + } + } + syncTags.RUnlock() + if len(ts) > 0 { + em.tags = ts + } + return em, nil +} + +// EncModeWithSharedTags returns EncMode with immutable options and mutable shared tags (safe for concurrency). +func (opts EncOptions) EncModeWithSharedTags(tags TagSet) (EncMode, error) { + if opts.TagsMd == TagsForbidden { + return nil, errors.New("cbor: cannot create EncMode with TagSet when TagsMd is TagsForbidden") + } + if tags == nil { + return nil, errors.New("cbor: cannot create EncMode with nil value as TagSet") + } + em, err := opts.encMode() + if err != nil { + return nil, err + } + em.tags = tags + return em, nil +} + +func (opts EncOptions) encMode() (*encMode, error) { + if !opts.Sort.valid() { + return nil, errors.New("cbor: invalid SortMode " + strconv.Itoa(int(opts.Sort))) + } + if !opts.ShortestFloat.valid() { + return nil, errors.New("cbor: invalid ShortestFloatMode " + strconv.Itoa(int(opts.ShortestFloat))) + } + if !opts.NaNConvert.valid() { + return nil, errors.New("cbor: invalid NaNConvertMode " + strconv.Itoa(int(opts.NaNConvert))) + } + if !opts.InfConvert.valid() { + return nil, errors.New("cbor: invalid InfConvertMode " + strconv.Itoa(int(opts.InfConvert))) + } + if !opts.BigIntConvert.valid() { + return nil, errors.New("cbor: invalid BigIntConvertMode " + strconv.Itoa(int(opts.BigIntConvert))) + } + if !opts.Time.valid() { + return nil, errors.New("cbor: invalid TimeMode " + strconv.Itoa(int(opts.Time))) + } + if !opts.TimeTag.valid() { + return nil, errors.New("cbor: invalid TimeTag " + strconv.Itoa(int(opts.TimeTag))) + } + if !opts.IndefLength.valid() { + return nil, errors.New("cbor: invalid IndefLength " + strconv.Itoa(int(opts.IndefLength))) + } + if !opts.TagsMd.valid() { + return nil, errors.New("cbor: invalid TagsMd " + strconv.Itoa(int(opts.TagsMd))) + } + if opts.TagsMd == TagsForbidden && opts.TimeTag == EncTagRequired { + return nil, errors.New("cbor: cannot set TagsMd to TagsForbidden when TimeTag is EncTagRequired") + } + em := encMode{ + sort: opts.Sort, + shortestFloat: opts.ShortestFloat, + nanConvert: opts.NaNConvert, + infConvert: opts.InfConvert, + bigIntConvert: opts.BigIntConvert, + time: opts.Time, + timeTag: opts.TimeTag, + indefLength: opts.IndefLength, + tagsMd: opts.TagsMd, + } + return &em, nil +} + +// EncMode is the main interface for CBOR encoding. +type EncMode interface { + Marshal(v interface{}) ([]byte, error) + NewEncoder(w io.Writer) *Encoder + EncOptions() EncOptions +} + +type encMode struct { + tags tagProvider + sort SortMode + shortestFloat ShortestFloatMode + nanConvert NaNConvertMode + infConvert InfConvertMode + bigIntConvert BigIntConvertMode + time TimeMode + timeTag EncTagMode + indefLength IndefLengthMode + tagsMd TagsMode +} + +var defaultEncMode = &encMode{} + +// EncOptions returns user specified options used to create this EncMode. +func (em *encMode) EncOptions() EncOptions { + return EncOptions{ + Sort: em.sort, + ShortestFloat: em.shortestFloat, + NaNConvert: em.nanConvert, + InfConvert: em.infConvert, + BigIntConvert: em.bigIntConvert, + Time: em.time, + TimeTag: em.timeTag, + IndefLength: em.indefLength, + TagsMd: em.tagsMd, + } +} + +func (em *encMode) encTagBytes(t reflect.Type) []byte { + if em.tags != nil { + if tagItem := em.tags.getTagItemFromType(t); tagItem != nil { + return tagItem.cborTagNum + } + } + return nil +} + +// Marshal returns the CBOR encoding of v using em encoding mode. +// +// See the documentation for Marshal for details. +func (em *encMode) Marshal(v interface{}) ([]byte, error) { + e := getEncoderBuffer() + + if err := encode(e, em, reflect.ValueOf(v)); err != nil { + putEncoderBuffer(e) + return nil, err + } + + buf := make([]byte, e.Len()) + copy(buf, e.Bytes()) + + putEncoderBuffer(e) + return buf, nil +} + +// NewEncoder returns a new encoder that writes to w using em EncMode. +func (em *encMode) NewEncoder(w io.Writer) *Encoder { + return &Encoder{w: w, em: em, e: getEncoderBuffer()} +} + +type encoderBuffer struct { + bytes.Buffer + scratch [16]byte +} + +// encoderBufferPool caches unused encoderBuffer objects for later reuse. +var encoderBufferPool = sync.Pool{ + New: func() interface{} { + e := new(encoderBuffer) + e.Grow(32) // TODO: make this configurable + return e + }, +} + +func getEncoderBuffer() *encoderBuffer { + return encoderBufferPool.Get().(*encoderBuffer) +} + +func putEncoderBuffer(e *encoderBuffer) { + e.Reset() + encoderBufferPool.Put(e) +} + +type encodeFunc func(e *encoderBuffer, em *encMode, v reflect.Value) error +type isEmptyFunc func(v reflect.Value) (empty bool, err error) + +var ( + cborFalse = []byte{0xf4} + cborTrue = []byte{0xf5} + cborNil = []byte{0xf6} + cborNaN = []byte{0xf9, 0x7e, 0x00} + cborPositiveInfinity = []byte{0xf9, 0x7c, 0x00} + cborNegativeInfinity = []byte{0xf9, 0xfc, 0x00} +) + +func encode(e *encoderBuffer, em *encMode, v reflect.Value) error { + if !v.IsValid() { + // v is zero value + e.Write(cborNil) + return nil + } + vt := v.Type() + f, _ := getEncodeFunc(vt) + if f == nil { + return &UnsupportedTypeError{vt} + } + + return f(e, em, v) +} + +func encodeBool(e *encoderBuffer, em *encMode, v reflect.Value) error { + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + b := cborFalse + if v.Bool() { + b = cborTrue + } + e.Write(b) + return nil +} + +func encodeInt(e *encoderBuffer, em *encMode, v reflect.Value) error { + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + i := v.Int() + if i >= 0 { + encodeHead(e, byte(cborTypePositiveInt), uint64(i)) + return nil + } + i = i*(-1) - 1 + encodeHead(e, byte(cborTypeNegativeInt), uint64(i)) + return nil +} + +func encodeUint(e *encoderBuffer, em *encMode, v reflect.Value) error { + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + encodeHead(e, byte(cborTypePositiveInt), v.Uint()) + return nil +} + +func encodeFloat(e *encoderBuffer, em *encMode, v reflect.Value) error { + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + f64 := v.Float() + if math.IsNaN(f64) { + return encodeNaN(e, em, v) + } + if math.IsInf(f64, 0) { + return encodeInf(e, em, v) + } + fopt := em.shortestFloat + if v.Kind() == reflect.Float64 && (fopt == ShortestFloatNone || cannotFitFloat32(f64)) { + // Encode float64 + // Don't use encodeFloat64() because it cannot be inlined. + e.scratch[0] = byte(cborTypePrimitives) | byte(27) + binary.BigEndian.PutUint64(e.scratch[1:], math.Float64bits(f64)) + e.Write(e.scratch[:9]) + return nil + } + + f32 := float32(f64) + if fopt == ShortestFloat16 { + var f16 float16.Float16 + p := float16.PrecisionFromfloat32(f32) + if p == float16.PrecisionExact { + // Roundtrip float32->float16->float32 test isn't needed. + f16 = float16.Fromfloat32(f32) + } else if p == float16.PrecisionUnknown { + // Try roundtrip float32->float16->float32 to determine if float32 can fit into float16. + f16 = float16.Fromfloat32(f32) + if f16.Float32() == f32 { + p = float16.PrecisionExact + } + } + if p == float16.PrecisionExact { + // Encode float16 + // Don't use encodeFloat16() because it cannot be inlined. + e.scratch[0] = byte(cborTypePrimitives) | byte(25) + binary.BigEndian.PutUint16(e.scratch[1:], uint16(f16)) + e.Write(e.scratch[:3]) + return nil + } + } + + // Encode float32 + // Don't use encodeFloat32() because it cannot be inlined. + e.scratch[0] = byte(cborTypePrimitives) | byte(26) + binary.BigEndian.PutUint32(e.scratch[1:], math.Float32bits(f32)) + e.Write(e.scratch[:5]) + return nil +} + +func encodeInf(e *encoderBuffer, em *encMode, v reflect.Value) error { + f64 := v.Float() + if em.infConvert == InfConvertFloat16 { + if f64 > 0 { + e.Write(cborPositiveInfinity) + } else { + e.Write(cborNegativeInfinity) + } + return nil + } + if v.Kind() == reflect.Float64 { + return encodeFloat64(e, f64) + } + return encodeFloat32(e, float32(f64)) +} + +func encodeNaN(e *encoderBuffer, em *encMode, v reflect.Value) error { + switch em.nanConvert { + case NaNConvert7e00: + e.Write(cborNaN) + return nil + + case NaNConvertNone: + if v.Kind() == reflect.Float64 { + return encodeFloat64(e, v.Float()) + } + f32 := float32NaNFromReflectValue(v) + return encodeFloat32(e, f32) + + default: // NaNConvertPreserveSignal, NaNConvertQuiet + if v.Kind() == reflect.Float64 { + f64 := v.Float() + f64bits := math.Float64bits(f64) + if em.nanConvert == NaNConvertQuiet && f64bits&(1<<51) == 0 { + f64bits |= 1 << 51 // Set quiet bit = 1 + f64 = math.Float64frombits(f64bits) + } + // The lower 29 bits are dropped when converting from float64 to float32. + if f64bits&0x1fffffff != 0 { + // Encode NaN as float64 because dropped coef bits from float64 to float32 are not all 0s. + return encodeFloat64(e, f64) + } + // Create float32 from float64 manually because float32(f64) always turns on NaN's quiet bits. + sign := uint32(f64bits>>32) & (1 << 31) + exp := uint32(0x7f800000) + coef := uint32((f64bits & 0xfffffffffffff) >> 29) + f32bits := sign | exp | coef + f32 := math.Float32frombits(f32bits) + // The lower 13 bits are dropped when converting from float32 to float16. + if f32bits&0x1fff != 0 { + // Encode NaN as float32 because dropped coef bits from float32 to float16 are not all 0s. + return encodeFloat32(e, f32) + } + // Encode NaN as float16 + f16, _ := float16.FromNaN32ps(f32) // Ignore err because it only returns error when f32 is not a NaN. + return encodeFloat16(e, f16) + } + + f32 := float32NaNFromReflectValue(v) + f32bits := math.Float32bits(f32) + if em.nanConvert == NaNConvertQuiet && f32bits&(1<<22) == 0 { + f32bits |= 1 << 22 // Set quiet bit = 1 + f32 = math.Float32frombits(f32bits) + } + // The lower 13 bits are dropped coef bits when converting from float32 to float16. + if f32bits&0x1fff != 0 { + // Encode NaN as float32 because dropped coef bits from float32 to float16 are not all 0s. + return encodeFloat32(e, f32) + } + f16, _ := float16.FromNaN32ps(f32) // Ignore err because it only returns error when f32 is not a NaN. + return encodeFloat16(e, f16) + } +} + +func encodeFloat16(e *encoderBuffer, f16 float16.Float16) error { + e.scratch[0] = byte(cborTypePrimitives) | byte(25) + binary.BigEndian.PutUint16(e.scratch[1:], uint16(f16)) + e.Write(e.scratch[:3]) + return nil +} + +func encodeFloat32(e *encoderBuffer, f32 float32) error { + e.scratch[0] = byte(cborTypePrimitives) | byte(26) + binary.BigEndian.PutUint32(e.scratch[1:], math.Float32bits(f32)) + e.Write(e.scratch[:5]) + return nil +} + +func encodeFloat64(e *encoderBuffer, f64 float64) error { + e.scratch[0] = byte(cborTypePrimitives) | byte(27) + binary.BigEndian.PutUint64(e.scratch[1:], math.Float64bits(f64)) + e.Write(e.scratch[:9]) + return nil +} + +func encodeByteString(e *encoderBuffer, em *encMode, v reflect.Value) error { + vk := v.Kind() + if vk == reflect.Slice && v.IsNil() { + e.Write(cborNil) + return nil + } + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + slen := v.Len() + if slen == 0 { + return e.WriteByte(byte(cborTypeByteString)) + } + encodeHead(e, byte(cborTypeByteString), uint64(slen)) + if vk == reflect.Array { + for i := 0; i < slen; i++ { + e.WriteByte(byte(v.Index(i).Uint())) + } + return nil + } + e.Write(v.Bytes()) + return nil +} + +func encodeString(e *encoderBuffer, em *encMode, v reflect.Value) error { + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + s := v.String() + encodeHead(e, byte(cborTypeTextString), uint64(len(s))) + e.WriteString(s) + return nil +} + +type arrayEncodeFunc struct { + f encodeFunc +} + +func (ae arrayEncodeFunc) encode(e *encoderBuffer, em *encMode, v reflect.Value) error { + if v.Kind() == reflect.Slice && v.IsNil() { + e.Write(cborNil) + return nil + } + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + alen := v.Len() + if alen == 0 { + return e.WriteByte(byte(cborTypeArray)) + } + encodeHead(e, byte(cborTypeArray), uint64(alen)) + for i := 0; i < alen; i++ { + if err := ae.f(e, em, v.Index(i)); err != nil { + return err + } + } + return nil +} + +type mapEncodeFunc struct { + kf, ef encodeFunc +} + +func (me mapEncodeFunc) encode(e *encoderBuffer, em *encMode, v reflect.Value) error { + if v.IsNil() { + e.Write(cborNil) + return nil + } + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + mlen := v.Len() + if mlen == 0 { + return e.WriteByte(byte(cborTypeMap)) + } + if em.sort != SortNone { + return me.encodeCanonical(e, em, v) + } + encodeHead(e, byte(cborTypeMap), uint64(mlen)) + iter := v.MapRange() + for iter.Next() { + if err := me.kf(e, em, iter.Key()); err != nil { + return err + } + if err := me.ef(e, em, iter.Value()); err != nil { + return err + } + } + return nil +} + +type keyValue struct { + keyCBORData, keyValueCBORData []byte + keyLen, keyValueLen int +} + +type bytewiseKeyValueSorter struct { + kvs []keyValue +} + +func (x *bytewiseKeyValueSorter) Len() int { + return len(x.kvs) +} + +func (x *bytewiseKeyValueSorter) Swap(i, j int) { + x.kvs[i], x.kvs[j] = x.kvs[j], x.kvs[i] +} + +func (x *bytewiseKeyValueSorter) Less(i, j int) bool { + return bytes.Compare(x.kvs[i].keyCBORData, x.kvs[j].keyCBORData) <= 0 +} + +type lengthFirstKeyValueSorter struct { + kvs []keyValue +} + +func (x *lengthFirstKeyValueSorter) Len() int { + return len(x.kvs) +} + +func (x *lengthFirstKeyValueSorter) Swap(i, j int) { + x.kvs[i], x.kvs[j] = x.kvs[j], x.kvs[i] +} + +func (x *lengthFirstKeyValueSorter) Less(i, j int) bool { + if len(x.kvs[i].keyCBORData) != len(x.kvs[j].keyCBORData) { + return len(x.kvs[i].keyCBORData) < len(x.kvs[j].keyCBORData) + } + return bytes.Compare(x.kvs[i].keyCBORData, x.kvs[j].keyCBORData) <= 0 +} + +var keyValuePool = sync.Pool{} + +func getKeyValues(length int) *[]keyValue { + v := keyValuePool.Get() + if v == nil { + y := make([]keyValue, length) + return &y + } + x := v.(*[]keyValue) + if cap(*x) >= length { + *x = (*x)[:length] + return x + } + // []keyValue from the pool does not have enough capacity. + // Return it back to the pool and create a new one. + keyValuePool.Put(x) + y := make([]keyValue, length) + return &y +} + +func putKeyValues(x *[]keyValue) { + *x = (*x)[:0] + keyValuePool.Put(x) +} + +func (me mapEncodeFunc) encodeCanonical(e *encoderBuffer, em *encMode, v reflect.Value) error { + kve := getEncoderBuffer() // accumulated cbor encoded key-values + kvsp := getKeyValues(v.Len()) // for sorting keys + kvs := *kvsp + iter := v.MapRange() + for i := 0; iter.Next(); i++ { + off := kve.Len() + if err := me.kf(kve, em, iter.Key()); err != nil { + putEncoderBuffer(kve) + putKeyValues(kvsp) + return err + } + n1 := kve.Len() - off + if err := me.ef(kve, em, iter.Value()); err != nil { + putEncoderBuffer(kve) + putKeyValues(kvsp) + return err + } + n2 := kve.Len() - off + // Save key and keyvalue length to create slice later. + kvs[i] = keyValue{keyLen: n1, keyValueLen: n2} + } + + b := kve.Bytes() + for i, off := 0, 0; i < len(kvs); i++ { + kvs[i].keyCBORData = b[off : off+kvs[i].keyLen] + kvs[i].keyValueCBORData = b[off : off+kvs[i].keyValueLen] + off += kvs[i].keyValueLen + } + + if em.sort == SortBytewiseLexical { + sort.Sort(&bytewiseKeyValueSorter{kvs}) + } else { + sort.Sort(&lengthFirstKeyValueSorter{kvs}) + } + + encodeHead(e, byte(cborTypeMap), uint64(len(kvs))) + for i := 0; i < len(kvs); i++ { + e.Write(kvs[i].keyValueCBORData) + } + + putEncoderBuffer(kve) + putKeyValues(kvsp) + return nil +} + +func encodeStructToArray(e *encoderBuffer, em *encMode, v reflect.Value) (err error) { + structType, err := getEncodingStructType(v.Type()) + if err != nil { + return err + } + + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + + flds := structType.fields + + encodeHead(e, byte(cborTypeArray), uint64(len(flds))) + for i := 0; i < len(flds); i++ { + f := flds[i] + + var fv reflect.Value + if len(f.idx) == 1 { + fv = v.Field(f.idx[0]) + } else { + // Get embedded field value. No error is expected. + fv, _ = getFieldValue(v, f.idx, func(v reflect.Value) (reflect.Value, error) { + // Write CBOR nil for null pointer to embedded struct + e.Write(cborNil) + return reflect.Value{}, nil + }) + if !fv.IsValid() { + continue + } + } + + if err := f.ef(e, em, fv); err != nil { + return err + } + } + return nil +} + +func encodeFixedLengthStruct(e *encoderBuffer, em *encMode, v reflect.Value, flds fields) error { + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + + encodeHead(e, byte(cborTypeMap), uint64(len(flds))) + + for i := 0; i < len(flds); i++ { + f := flds[i] + e.Write(f.cborName) + + fv := v.Field(f.idx[0]) + if err := f.ef(e, em, fv); err != nil { + return err + } + } + + return nil +} + +func encodeStruct(e *encoderBuffer, em *encMode, v reflect.Value) (err error) { + structType, err := getEncodingStructType(v.Type()) + if err != nil { + return err + } + + flds := structType.getFields(em) + + if structType.fixedLength { + return encodeFixedLengthStruct(e, em, v, flds) + } + + kve := getEncoderBuffer() // encode key-value pairs based on struct field tag options + kvcount := 0 + for i := 0; i < len(flds); i++ { + f := flds[i] + + var fv reflect.Value + if len(f.idx) == 1 { + fv = v.Field(f.idx[0]) + } else { + // Get embedded field value. No error is expected. + fv, _ = getFieldValue(v, f.idx, func(v reflect.Value) (reflect.Value, error) { + // Skip null pointer to embedded struct + return reflect.Value{}, nil + }) + if !fv.IsValid() { + continue + } + } + + if f.omitEmpty { + empty, err := f.ief(fv) + if err != nil { + putEncoderBuffer(kve) + return err + } + if empty { + continue + } + } + + kve.Write(f.cborName) + + if err := f.ef(kve, em, fv); err != nil { + putEncoderBuffer(kve) + return err + } + kvcount++ + } + + if b := em.encTagBytes(v.Type()); b != nil { + e.Write(b) + } + + encodeHead(e, byte(cborTypeMap), uint64(kvcount)) + e.Write(kve.Bytes()) + + putEncoderBuffer(kve) + return nil +} + +func encodeIntf(e *encoderBuffer, em *encMode, v reflect.Value) error { + if v.IsNil() { + e.Write(cborNil) + return nil + } + return encode(e, em, v.Elem()) +} + +func encodeTime(e *encoderBuffer, em *encMode, v reflect.Value) error { + t := v.Interface().(time.Time) + if t.IsZero() { + e.Write(cborNil) // Even if tag is required, encode as CBOR null. + return nil + } + if em.timeTag == EncTagRequired { + tagNumber := 1 + if em.time == TimeRFC3339 || em.time == TimeRFC3339Nano { + tagNumber = 0 + } + encodeHead(e, byte(cborTypeTag), uint64(tagNumber)) + } + switch em.time { + case TimeUnix: + secs := t.Unix() + return encodeInt(e, em, reflect.ValueOf(secs)) + case TimeUnixMicro: + t = t.UTC().Round(time.Microsecond) + f := float64(t.UnixNano()) / 1e9 + return encodeFloat(e, em, reflect.ValueOf(f)) + case TimeUnixDynamic: + t = t.UTC().Round(time.Microsecond) + secs, nsecs := t.Unix(), uint64(t.Nanosecond()) + if nsecs == 0 { + return encodeInt(e, em, reflect.ValueOf(secs)) + } + f := float64(secs) + float64(nsecs)/1e9 + return encodeFloat(e, em, reflect.ValueOf(f)) + case TimeRFC3339: + s := t.Format(time.RFC3339) + return encodeString(e, em, reflect.ValueOf(s)) + default: // TimeRFC3339Nano + s := t.Format(time.RFC3339Nano) + return encodeString(e, em, reflect.ValueOf(s)) + } +} + +func encodeBigInt(e *encoderBuffer, em *encMode, v reflect.Value) error { + vbi := v.Interface().(big.Int) + sign := vbi.Sign() + bi := new(big.Int).SetBytes(vbi.Bytes()) // bi is absolute value of v + if sign < 0 { + // For negative number, convert to CBOR encoded number (-v-1). + bi.Sub(bi, big.NewInt(1)) + } + + if em.bigIntConvert == BigIntConvertShortest { + if bi.IsUint64() { + if sign >= 0 { + // Encode as CBOR pos int (major type 0) + encodeHead(e, byte(cborTypePositiveInt), bi.Uint64()) + return nil + } + // Encode as CBOR neg int (major type 1) + encodeHead(e, byte(cborTypeNegativeInt), bi.Uint64()) + return nil + } + } + + tagNum := 2 + if sign < 0 { + tagNum = 3 + } + // Write tag number + encodeHead(e, byte(cborTypeTag), uint64(tagNum)) + // Write bignum byte string + b := bi.Bytes() + encodeHead(e, byte(cborTypeByteString), uint64(len(b))) + e.Write(b) + return nil +} + +func encodeBinaryMarshalerType(e *encoderBuffer, em *encMode, v reflect.Value) error { + vt := v.Type() + m, ok := v.Interface().(encoding.BinaryMarshaler) + if !ok { + pv := reflect.New(vt) + pv.Elem().Set(v) + m = pv.Interface().(encoding.BinaryMarshaler) + } + data, err := m.MarshalBinary() + if err != nil { + return err + } + if b := em.encTagBytes(vt); b != nil { + e.Write(b) + } + encodeHead(e, byte(cborTypeByteString), uint64(len(data))) + e.Write(data) + return nil +} + +func encodeMarshalerType(e *encoderBuffer, em *encMode, v reflect.Value) error { + if em.tagsMd == TagsForbidden && v.Type() == typeRawTag { + return errors.New("cbor: cannot encode cbor.RawTag when TagsMd is TagsForbidden") + } + m, ok := v.Interface().(Marshaler) + if !ok { + pv := reflect.New(v.Type()) + pv.Elem().Set(v) + m = pv.Interface().(Marshaler) + } + data, err := m.MarshalCBOR() + if err != nil { + return err + } + e.Write(data) + return nil +} + +func encodeTag(e *encoderBuffer, em *encMode, v reflect.Value) error { + if em.tagsMd == TagsForbidden { + return errors.New("cbor: cannot encode cbor.Tag when TagsMd is TagsForbidden") + } + + t := v.Interface().(Tag) + + if t.Number == 0 && t.Content == nil { + // Marshal uninitialized cbor.Tag + e.Write(cborNil) + return nil + } + + // Marshal tag number + encodeHead(e, byte(cborTypeTag), t.Number) + + // Marshal tag content + if err := encode(e, em, reflect.ValueOf(t.Content)); err != nil { + return err + } + + return nil +} + +func encodeHead(e *encoderBuffer, t byte, n uint64) { + if n <= 23 { + e.WriteByte(t | byte(n)) + return + } + if n <= math.MaxUint8 { + e.scratch[0] = t | byte(24) + e.scratch[1] = byte(n) + e.Write(e.scratch[:2]) + return + } + if n <= math.MaxUint16 { + e.scratch[0] = t | byte(25) + binary.BigEndian.PutUint16(e.scratch[1:], uint16(n)) + e.Write(e.scratch[:3]) + return + } + if n <= math.MaxUint32 { + e.scratch[0] = t | byte(26) + binary.BigEndian.PutUint32(e.scratch[1:], uint32(n)) + e.Write(e.scratch[:5]) + return + } + e.scratch[0] = t | byte(27) + binary.BigEndian.PutUint64(e.scratch[1:], n) + e.Write(e.scratch[:9]) +} + +var ( + typeMarshaler = reflect.TypeOf((*Marshaler)(nil)).Elem() + typeBinaryMarshaler = reflect.TypeOf((*encoding.BinaryMarshaler)(nil)).Elem() + typeRawMessage = reflect.TypeOf(RawMessage(nil)) +) + +func getEncodeFuncInternal(t reflect.Type) (encodeFunc, isEmptyFunc) { + k := t.Kind() + if k == reflect.Ptr { + return getEncodeIndirectValueFunc(t), isEmptyPtr + } + switch t { + case typeTag: + return encodeTag, alwaysNotEmpty + case typeTime: + return encodeTime, alwaysNotEmpty + case typeBigInt: + return encodeBigInt, alwaysNotEmpty + case typeRawMessage: + return encodeMarshalerType, isEmptySlice + } + if reflect.PtrTo(t).Implements(typeMarshaler) { + return encodeMarshalerType, alwaysNotEmpty + } + if reflect.PtrTo(t).Implements(typeBinaryMarshaler) { + return encodeBinaryMarshalerType, isEmptyBinaryMarshaler + } + switch k { + case reflect.Bool: + return encodeBool, isEmptyBool + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + return encodeInt, isEmptyInt + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + return encodeUint, isEmptyUint + case reflect.Float32, reflect.Float64: + return encodeFloat, isEmptyFloat + case reflect.String: + return encodeString, isEmptyString + case reflect.Slice, reflect.Array: + if t.Elem().Kind() == reflect.Uint8 { + return encodeByteString, isEmptySlice + } + f, _ := getEncodeFunc(t.Elem()) + if f == nil { + return nil, nil + } + return arrayEncodeFunc{f: f}.encode, isEmptySlice + case reflect.Map: + kf, _ := getEncodeFunc(t.Key()) + ef, _ := getEncodeFunc(t.Elem()) + if kf == nil || ef == nil { + return nil, nil + } + return mapEncodeFunc{kf: kf, ef: ef}.encode, isEmptyMap + case reflect.Struct: + // Get struct's special field "_" tag options + if f, ok := t.FieldByName("_"); ok { + tag := f.Tag.Get("cbor") + if tag != "-" { + if hasToArrayOption(tag) { + return encodeStructToArray, isEmptyStruct + } + } + } + return encodeStruct, isEmptyStruct + case reflect.Interface: + return encodeIntf, isEmptyIntf + } + return nil, nil +} + +func getEncodeIndirectValueFunc(t reflect.Type) encodeFunc { + for t.Kind() == reflect.Ptr { + t = t.Elem() + } + f, _ := getEncodeFunc(t) + if f == nil { + return nil + } + return func(e *encoderBuffer, em *encMode, v reflect.Value) error { + for v.Kind() == reflect.Ptr && !v.IsNil() { + v = v.Elem() + } + if v.Kind() == reflect.Ptr && v.IsNil() { + e.Write(cborNil) + return nil + } + return f(e, em, v) + } +} + +func alwaysNotEmpty(v reflect.Value) (empty bool, err error) { + return false, nil +} + +func isEmptyBool(v reflect.Value) (bool, error) { + return !v.Bool(), nil +} + +func isEmptyInt(v reflect.Value) (bool, error) { + return v.Int() == 0, nil +} + +func isEmptyUint(v reflect.Value) (bool, error) { + return v.Uint() == 0, nil +} + +func isEmptyFloat(v reflect.Value) (bool, error) { + return v.Float() == 0.0, nil +} + +func isEmptyString(v reflect.Value) (bool, error) { + return v.Len() == 0, nil +} + +func isEmptySlice(v reflect.Value) (bool, error) { + return v.Len() == 0, nil +} + +func isEmptyMap(v reflect.Value) (bool, error) { + return v.Len() == 0, nil +} + +func isEmptyPtr(v reflect.Value) (bool, error) { + return v.IsNil(), nil +} + +func isEmptyIntf(v reflect.Value) (bool, error) { + return v.IsNil(), nil +} + +func isEmptyStruct(v reflect.Value) (bool, error) { + structType, err := getEncodingStructType(v.Type()) + if err != nil { + return false, err + } + + if structType.toArray { + return len(structType.fields) == 0, nil + } + + if len(structType.fields) > len(structType.omitEmptyFieldsIdx) { + return false, nil + } + + for _, i := range structType.omitEmptyFieldsIdx { + f := structType.fields[i] + + // Get field value + var fv reflect.Value + if len(f.idx) == 1 { + fv = v.Field(f.idx[0]) + } else { + // Get embedded field value. No error is expected. + fv, _ = getFieldValue(v, f.idx, func(v reflect.Value) (reflect.Value, error) { + // Skip null pointer to embedded struct + return reflect.Value{}, nil + }) + if !fv.IsValid() { + continue + } + } + + empty, err := f.ief(fv) + if err != nil { + return false, err + } + if !empty { + return false, nil + } + } + return true, nil +} + +func isEmptyBinaryMarshaler(v reflect.Value) (bool, error) { + m, ok := v.Interface().(encoding.BinaryMarshaler) + if !ok { + pv := reflect.New(v.Type()) + pv.Elem().Set(v) + m = pv.Interface().(encoding.BinaryMarshaler) + } + data, err := m.MarshalBinary() + if err != nil { + return false, err + } + return len(data) == 0, nil +} + +func cannotFitFloat32(f64 float64) bool { + f32 := float32(f64) + return float64(f32) != f64 +} + +// float32NaNFromReflectValue extracts float32 NaN from reflect.Value while preserving NaN's quiet bit. +func float32NaNFromReflectValue(v reflect.Value) float32 { + // Keith Randall's workaround for issue https://github.com/golang/go/issues/36400 + p := reflect.New(v.Type()) + p.Elem().Set(v) + f32 := p.Convert(reflect.TypeOf((*float32)(nil))).Elem().Interface().(float32) + return f32 +} diff --git a/vendor/github.com/fxamacker/cbor/encode_test.go b/vendor/github.com/fxamacker/cbor/encode_test.go new file mode 100644 index 0000000..7d2f278 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/encode_test.go @@ -0,0 +1,3592 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "bytes" + "encoding/binary" + "fmt" + "io" + "io/ioutil" + "math" + "math/big" + "reflect" + "strings" + "testing" + "time" +) + +type marshalTest struct { + cborData []byte + values []interface{} +} + +type marshalErrorTest struct { + name string + value interface{} + wantErrorMsg string +} + +type inner struct { + X, Y, z int64 +} + +type outer struct { + IntField int + FloatField float32 + BoolField bool + StringField string + ByteStringField []byte + ArrayField []string + MapField map[string]bool + NestedStructField *inner + unexportedField int64 +} + +// CBOR test data are from https://tools.ietf.org/html/rfc7049#appendix-A. +var marshalTests = []marshalTest{ + // positive integer + {hexDecode("00"), []interface{}{uint(0), uint8(0), uint16(0), uint32(0), uint64(0), int(0), int8(0), int16(0), int32(0), int64(0)}}, + {hexDecode("01"), []interface{}{uint(1), uint8(1), uint16(1), uint32(1), uint64(1), int(1), int8(1), int16(1), int32(1), int64(1)}}, + {hexDecode("0a"), []interface{}{uint(10), uint8(10), uint16(10), uint32(10), uint64(10), int(10), int8(10), int16(10), int32(10), int64(10)}}, + {hexDecode("17"), []interface{}{uint(23), uint8(23), uint16(23), uint32(23), uint64(23), int(23), int8(23), int16(23), int32(23), int64(23)}}, + {hexDecode("1818"), []interface{}{uint(24), uint8(24), uint16(24), uint32(24), uint64(24), int(24), int8(24), int16(24), int32(24), int64(24)}}, + {hexDecode("1819"), []interface{}{uint(25), uint8(25), uint16(25), uint32(25), uint64(25), int(25), int8(25), int16(25), int32(25), int64(25)}}, + {hexDecode("1864"), []interface{}{uint(100), uint8(100), uint16(100), uint32(100), uint64(100), int(100), int8(100), int16(100), int32(100), int64(100)}}, + {hexDecode("18ff"), []interface{}{uint(255), uint8(255), uint16(255), uint32(255), uint64(255), int(255), int16(255), int32(255), int64(255)}}, + {hexDecode("190100"), []interface{}{uint(256), uint16(256), uint32(256), uint64(256), int(256), int16(256), int32(256), int64(256)}}, + {hexDecode("1903e8"), []interface{}{uint(1000), uint16(1000), uint32(1000), uint64(1000), int(1000), int16(1000), int32(1000), int64(1000)}}, + {hexDecode("19ffff"), []interface{}{uint(65535), uint16(65535), uint32(65535), uint64(65535), int(65535), int32(65535), int64(65535)}}, + {hexDecode("1a00010000"), []interface{}{uint(65536), uint32(65536), uint64(65536), int(65536), int32(65536), int64(65536)}}, + {hexDecode("1a000f4240"), []interface{}{uint(1000000), uint32(1000000), uint64(1000000), int(1000000), int32(1000000), int64(1000000)}}, + {hexDecode("1affffffff"), []interface{}{uint(4294967295), uint32(4294967295), uint64(4294967295), int64(4294967295)}}, + {hexDecode("1b000000e8d4a51000"), []interface{}{uint64(1000000000000), int64(1000000000000)}}, + {hexDecode("1bffffffffffffffff"), []interface{}{uint64(18446744073709551615)}}, + // negative integer + {hexDecode("20"), []interface{}{int(-1), int8(-1), int16(-1), int32(-1), int64(-1)}}, + {hexDecode("29"), []interface{}{int(-10), int8(-10), int16(-10), int32(-10), int64(-10)}}, + {hexDecode("37"), []interface{}{int(-24), int8(-24), int16(-24), int32(-24), int64(-24)}}, + {hexDecode("3818"), []interface{}{int(-25), int8(-25), int16(-25), int32(-25), int64(-25)}}, + {hexDecode("3863"), []interface{}{int(-100), int8(-100), int16(-100), int32(-100), int64(-100)}}, + {hexDecode("38ff"), []interface{}{int(-256), int16(-256), int32(-256), int64(-256)}}, + {hexDecode("390100"), []interface{}{int(-257), int16(-257), int32(-257), int64(-257)}}, + {hexDecode("3903e7"), []interface{}{int(-1000), int16(-1000), int32(-1000), int64(-1000)}}, + {hexDecode("39ffff"), []interface{}{int(-65536), int32(-65536), int64(-65536)}}, + {hexDecode("3a00010000"), []interface{}{int(-65537), int32(-65537), int64(-65537)}}, + {hexDecode("3affffffff"), []interface{}{int64(-4294967296)}}, + // byte string + {hexDecode("40"), []interface{}{[]byte{}}}, + {hexDecode("4401020304"), []interface{}{[]byte{1, 2, 3, 4}, [...]byte{1, 2, 3, 4}}}, + // text string + {hexDecode("60"), []interface{}{""}}, + {hexDecode("6161"), []interface{}{"a"}}, + {hexDecode("6449455446"), []interface{}{"IETF"}}, + {hexDecode("62225c"), []interface{}{"\"\\"}}, + {hexDecode("62c3bc"), []interface{}{"ü"}}, + {hexDecode("63e6b0b4"), []interface{}{"水"}}, + {hexDecode("64f0908591"), []interface{}{"𐅑"}}, + // array + { + hexDecode("80"), + []interface{}{ + [0]int{}, + []uint{}, + // []uint8{}, + []uint16{}, + []uint32{}, + []uint64{}, + []int{}, + []int8{}, + []int16{}, + []int32{}, + []int64{}, + []string{}, + []bool{}, []float32{}, []float64{}, []interface{}{}, + }, + }, + { + hexDecode("83010203"), + []interface{}{ + [...]int{1, 2, 3}, + []uint{1, 2, 3}, + // []uint8{1, 2, 3}, + []uint16{1, 2, 3}, + []uint32{1, 2, 3}, + []uint64{1, 2, 3}, + []int{1, 2, 3}, + []int8{1, 2, 3}, + []int16{1, 2, 3}, + []int32{1, 2, 3}, + []int64{1, 2, 3}, + []interface{}{1, 2, 3}, + }, + }, + { + hexDecode("8301820203820405"), + []interface{}{ + [...]interface{}{1, [...]int{2, 3}, [...]int{4, 5}}, + []interface{}{1, []uint{2, 3}, []uint{4, 5}}, + // []interface{}{1, []uint8{2, 3}, []uint8{4, 5}}, + []interface{}{1, []uint16{2, 3}, []uint16{4, 5}}, + []interface{}{1, []uint32{2, 3}, []uint32{4, 5}}, + []interface{}{1, []uint64{2, 3}, []uint64{4, 5}}, + []interface{}{1, []int{2, 3}, []int{4, 5}}, + []interface{}{1, []int8{2, 3}, []int8{4, 5}}, + []interface{}{1, []int16{2, 3}, []int16{4, 5}}, + []interface{}{1, []int32{2, 3}, []int32{4, 5}}, + []interface{}{1, []int64{2, 3}, []int64{4, 5}}, + []interface{}{1, []interface{}{2, 3}, []interface{}{4, 5}}, + }, + }, + { + hexDecode("98190102030405060708090a0b0c0d0e0f101112131415161718181819"), + []interface{}{ + [...]int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []uint{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + // []uint8{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []uint16{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []uint32{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []int{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []int8{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []int16{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []int32{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []int64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + []interface{}{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25}, + }, + }, + { + hexDecode("826161a161626163"), + []interface{}{ + [...]interface{}{"a", map[string]string{"b": "c"}}, + []interface{}{"a", map[string]string{"b": "c"}}, + []interface{}{"a", map[interface{}]interface{}{"b": "c"}}, + }, + }, + // map + { + hexDecode("a0"), + []interface{}{ + map[uint]bool{}, + map[uint8]bool{}, + map[uint16]bool{}, + map[uint32]bool{}, + map[uint64]bool{}, + map[int]bool{}, + map[int8]bool{}, + map[int16]bool{}, + map[int32]bool{}, + map[int64]bool{}, + map[float32]bool{}, + map[float64]bool{}, + map[bool]bool{}, + map[string]bool{}, + map[interface{}]interface{}{}, + }, + }, + { + hexDecode("a201020304"), + []interface{}{ + map[uint]uint{3: 4, 1: 2}, + map[uint8]uint8{3: 4, 1: 2}, + map[uint16]uint16{3: 4, 1: 2}, + map[uint32]uint32{3: 4, 1: 2}, + map[uint64]uint64{3: 4, 1: 2}, + map[int]int{3: 4, 1: 2}, + map[int8]int8{3: 4, 1: 2}, + map[int16]int16{3: 4, 1: 2}, + map[int32]int32{3: 4, 1: 2}, + map[int64]int64{3: 4, 1: 2}, + map[interface{}]interface{}{3: 4, 1: 2}, + }, + }, + { + hexDecode("a26161016162820203"), + []interface{}{ + map[string]interface{}{"a": 1, "b": []interface{}{2, 3}}, + map[interface{}]interface{}{"b": []interface{}{2, 3}, "a": 1}, + }, + }, + { + hexDecode("a56161614161626142616361436164614461656145"), + []interface{}{ + map[string]string{"a": "A", "b": "B", "c": "C", "d": "D", "e": "E"}, + map[interface{}]interface{}{"b": "B", "a": "A", "c": "C", "e": "E", "d": "D"}, + }, + }, + // tag + { + hexDecode("c074323031332d30332d32315432303a30343a30305a"), + []interface{}{Tag{0, "2013-03-21T20:04:00Z"}, RawTag{0, hexDecode("74323031332d30332d32315432303a30343a30305a")}}, + }, // 0: standard date/time + { + hexDecode("c11a514b67b0"), + []interface{}{Tag{1, uint64(1363896240)}, RawTag{1, hexDecode("1a514b67b0")}}, + }, // 1: epoch-based date/time + { + hexDecode("c249010000000000000000"), + []interface{}{ + bigIntOrPanic("18446744073709551616"), + Tag{2, []byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}}, + RawTag{2, hexDecode("49010000000000000000")}, + }, + }, // 2: positive bignum: 18446744073709551616 + { + hexDecode("c349010000000000000000"), + []interface{}{ + bigIntOrPanic("-18446744073709551617"), + Tag{3, []byte{0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}}, + RawTag{3, hexDecode("49010000000000000000")}, + }, + }, // 3: negative bignum: -18446744073709551617 + { + hexDecode("c1fb41d452d9ec200000"), + []interface{}{Tag{1, float64(1363896240.5)}, RawTag{1, hexDecode("fb41d452d9ec200000")}}, + }, // 1: epoch-based date/time + { + hexDecode("d74401020304"), + []interface{}{Tag{23, []byte{0x01, 0x02, 0x03, 0x04}}, RawTag{23, hexDecode("4401020304")}}, + }, // 23: expected conversion to base16 encoding + { + hexDecode("d818456449455446"), + []interface{}{Tag{24, []byte{0x64, 0x49, 0x45, 0x54, 0x46}}, RawTag{24, hexDecode("456449455446")}}, + }, // 24: encoded cborBytes data item + { + hexDecode("d82076687474703a2f2f7777772e6578616d706c652e636f6d"), + []interface{}{Tag{32, "http://www.example.com"}, RawTag{32, hexDecode("76687474703a2f2f7777772e6578616d706c652e636f6d")}}, + }, // 32: URI + // primitives + {hexDecode("f4"), []interface{}{false}}, + {hexDecode("f5"), []interface{}{true}}, + {hexDecode("f6"), []interface{}{nil, []byte(nil), []int(nil), map[uint]bool(nil), (*int)(nil), io.Reader(nil)}}, + // nan, positive and negative inf + {hexDecode("f97c00"), []interface{}{math.Inf(1)}}, + {hexDecode("f97e00"), []interface{}{math.NaN()}}, + {hexDecode("f9fc00"), []interface{}{math.Inf(-1)}}, + // float32 + {hexDecode("fa47c35000"), []interface{}{float32(100000.0)}}, + {hexDecode("fa7f7fffff"), []interface{}{float32(3.4028234663852886e+38)}}, + // float64 + {hexDecode("fb3ff199999999999a"), []interface{}{float64(1.1)}}, + {hexDecode("fb7e37e43c8800759c"), []interface{}{float64(1.0e+300)}}, + {hexDecode("fbc010666666666666"), []interface{}{float64(-4.1)}}, + // More testcases not covered by https://tools.ietf.org/html/rfc7049#appendix-A. + { + hexDecode("d83dd183010203"), // 61(17([1, 2, 3])), nested tags 61 and 17 + []interface{}{Tag{61, Tag{17, []interface{}{uint64(1), uint64(2), uint64(3)}}}, RawTag{61, hexDecode("d183010203")}}, + }, +} + +var exMarshalTests = []marshalTest{ + { + // array of nils + hexDecode("83f6f6f6"), + []interface{}{ + []interface{}{nil, nil, nil}, + }, + }, +} + +func TestMarshal(t *testing.T) { + testMarshal(t, marshalTests) + testMarshal(t, exMarshalTests) +} + +func TestInvalidTypeMarshal(t *testing.T) { + type s1 struct { + Chan chan bool + } + type s2 struct { + _ struct{} `cbor:",toarray"` + Chan chan bool + } + var marshalErrorTests = []marshalErrorTest{ + {"channel cannot be marshaled", make(chan bool), "cbor: unsupported type: chan bool"}, + {"slice of channel cannot be marshaled", make([]chan bool, 10), "cbor: unsupported type: []chan bool"}, + {"slice of pointer to channel cannot be marshaled", make([]*chan bool, 10), "cbor: unsupported type: []*chan bool"}, + {"map of channel cannot be marshaled", make(map[string]chan bool), "cbor: unsupported type: map[string]chan bool"}, + {"struct of channel cannot be marshaled", s1{}, "cbor: unsupported type: cbor.s1"}, + {"struct of channel cannot be marshaled", s2{}, "cbor: unsupported type: cbor.s2"}, + {"function cannot be marshaled", func(i int) int { return i * i }, "cbor: unsupported type: func(int) int"}, + {"complex cannot be marshaled", complex(100, 8), "cbor: unsupported type: complex128"}, + } + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + for _, tc := range marshalErrorTests { + t.Run(tc.name, func(t *testing.T) { + b, err := Marshal(&tc.value) + if err == nil { + t.Errorf("Marshal(%v) didn't return an error, want error %q", tc.value, tc.wantErrorMsg) + } else if _, ok := err.(*UnsupportedTypeError); !ok { + t.Errorf("Marshal(%v) error type %T, want *UnsupportedTypeError", tc.value, err) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Marshal(%v) error %q, want %q", tc.value, err.Error(), tc.wantErrorMsg) + } else if b != nil { + t.Errorf("Marshal(%v) = 0x%x, want nil", tc.value, b) + } + + b, err = em.Marshal(&tc.value) + if err == nil { + t.Errorf("Marshal(%v) didn't return an error, want error %q", tc.value, tc.wantErrorMsg) + } else if _, ok := err.(*UnsupportedTypeError); !ok { + t.Errorf("Marshal(%v) error type %T, want *UnsupportedTypeError", tc.value, err) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Marshal(%v) error %q, want %q", tc.value, err.Error(), tc.wantErrorMsg) + } else if b != nil { + t.Errorf("Marshal(%v) = 0x%x, want nil", tc.value, b) + } + }) + } +} + +func TestMarshalLargeByteString(t *testing.T) { + // []byte{100, 100, 100, ...} + lengths := []int{0, 1, 2, 22, 23, 24, 254, 255, 256, 65534, 65535, 65536, 10000000} + tests := make([]marshalTest, len(lengths)) + for i, length := range lengths { + cborData := bytes.NewBuffer(encodeCborHeader(cborTypeByteString, uint64(length))) + value := make([]byte, length) + for j := 0; j < length; j++ { + cborData.WriteByte(100) + value[j] = 100 + } + tests[i] = marshalTest{cborData.Bytes(), []interface{}{value}} + } + + testMarshal(t, tests) +} + +func TestMarshalLargeTextString(t *testing.T) { + // "ddd..." + lengths := []int{0, 1, 2, 22, 23, 24, 254, 255, 256, 65534, 65535, 65536, 10000000} + tests := make([]marshalTest, len(lengths)) + for i, length := range lengths { + cborData := bytes.NewBuffer(encodeCborHeader(cborTypeTextString, uint64(length))) + value := make([]byte, length) + for j := 0; j < length; j++ { + cborData.WriteByte(100) + value[j] = 100 + } + tests[i] = marshalTest{cborData.Bytes(), []interface{}{string(value)}} + } + + testMarshal(t, tests) +} + +func TestMarshalLargeArray(t *testing.T) { + // []string{"水", "水", "水", ...} + lengths := []int{0, 1, 2, 22, 23, 24, 254, 255, 256, 65534, 65535, 65536, 131072} + tests := make([]marshalTest, len(lengths)) + for i, length := range lengths { + cborData := bytes.NewBuffer(encodeCborHeader(cborTypeArray, uint64(length))) + value := make([]string, length) + for j := 0; j < length; j++ { + cborData.Write([]byte{0x63, 0xe6, 0xb0, 0xb4}) + value[j] = "水" + } + tests[i] = marshalTest{cborData.Bytes(), []interface{}{value}} + } + + testMarshal(t, tests) +} + +func TestMarshalLargeMapCanonical(t *testing.T) { + // map[int]int {0:0, 1:1, 2:2, ...} + lengths := []int{0, 1, 2, 22, 23, 24, 254, 255, 256, 65534, 65535, 65536, 131072} + tests := make([]marshalTest, len(lengths)) + for i, length := range lengths { + cborData := bytes.NewBuffer(encodeCborHeader(cborTypeMap, uint64(length))) + value := make(map[int]int, length) + for j := 0; j < length; j++ { + d := encodeCborHeader(cborTypePositiveInt, uint64(j)) + cborData.Write(d) + cborData.Write(d) + value[j] = j + } + tests[i] = marshalTest{cborData.Bytes(), []interface{}{value}} + } + + testMarshal(t, tests) +} + +func TestMarshalLargeMap(t *testing.T) { + // map[int]int {0:0, 1:1, 2:2, ...} + lengths := []int{0, 1, 2, 22, 23, 24, 254, 255, 256, 65534, 65535, 65536, 131072} + for _, length := range lengths { + m1 := make(map[int]int, length) + for i := 0; i < length; i++ { + m1[i] = i + } + + cborData, err := Marshal(m1) + if err != nil { + t.Fatalf("Marshal(%v) returned error %v", m1, err) + } + + m2 := make(map[int]int) + if err = Unmarshal(cborData, &m2); err != nil { + t.Fatalf("Unmarshal(0x%x) returned error %v", cborData, err) + } + + if !reflect.DeepEqual(m1, m2) { + t.Errorf("Unmarshal() = %v, want %v", m2, m1) + } + } +} + +func encodeCborHeader(t cborType, n uint64) []byte { + b := make([]byte, 9) + if n <= 23 { + b[0] = byte(t) | byte(n) + return b[:1] + } else if n <= math.MaxUint8 { + b[0] = byte(t) | byte(24) + b[1] = byte(n) + return b[:2] + } else if n <= math.MaxUint16 { + b[0] = byte(t) | byte(25) + binary.BigEndian.PutUint16(b[1:], uint16(n)) + return b[:3] + } else if n <= math.MaxUint32 { + b[0] = byte(t) | byte(26) + binary.BigEndian.PutUint32(b[1:], uint32(n)) + return b[:5] + } else { + b[0] = byte(t) | byte(27) + binary.BigEndian.PutUint64(b[1:], n) + return b[:9] + } +} + +func testMarshal(t *testing.T, testCases []marshalTest) { + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + for _, tc := range testCases { + for _, value := range tc.values { + if _, err := Marshal(value); err != nil { + t.Errorf("Marshal(%v) returned error %v", value, err) + } + if b, err := em.Marshal(value); err != nil { + t.Errorf("Marshal(%v) returned error %v", value, err) + } else if !bytes.Equal(b, tc.cborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", value, b, tc.cborData) + } + } + r := RawMessage(tc.cborData) + if b, err := Marshal(r); err != nil { + t.Errorf("Marshal(%v) returned error %v", r, err) + } else if !bytes.Equal(b, r) { + t.Errorf("Marshal(%v) returned %v, want %v", r, b, r) + } + } +} + +func TestMarshalStruct(t *testing.T) { + v1 := outer{ + IntField: 123, + FloatField: 100000.0, + BoolField: true, + StringField: "test", + ByteStringField: []byte{1, 3, 5}, + ArrayField: []string{"hello", "world"}, + MapField: map[string]bool{"afternoon": false, "morning": true}, + NestedStructField: &inner{X: 1000, Y: 1000000, z: 10000000}, + unexportedField: 6, + } + unmarshalWant := outer{ + IntField: 123, + FloatField: 100000.0, + BoolField: true, + StringField: "test", + ByteStringField: []byte{1, 3, 5}, + ArrayField: []string{"hello", "world"}, + MapField: map[string]bool{"afternoon": false, "morning": true}, + NestedStructField: &inner{X: 1000, Y: 1000000}, + } + + cborData, err := Marshal(v1) + if err != nil { + t.Fatalf("Marshal(%v) returned error %v", v1, err) + } + + var v2 outer + if err = Unmarshal(cborData, &v2); err != nil { + t.Fatalf("Unmarshal(0x%x) returned error %v", cborData, err) + } + + if !reflect.DeepEqual(unmarshalWant, v2) { + t.Errorf("Unmarshal() = %v, want %v", v2, unmarshalWant) + } +} +func TestMarshalStructCanonical(t *testing.T) { + v := outer{ + IntField: 123, + FloatField: 100000.0, + BoolField: true, + StringField: "test", + ByteStringField: []byte{1, 3, 5}, + ArrayField: []string{"hello", "world"}, + MapField: map[string]bool{"afternoon": false, "morning": true}, + NestedStructField: &inner{X: 1000, Y: 1000000, z: 10000000}, + unexportedField: 6, + } + var cborData bytes.Buffer + cborData.WriteByte(byte(cborTypeMap) | 8) // CBOR header: map type with 8 items (exported fields) + + cborData.WriteByte(byte(cborTypeTextString) | 8) // "IntField" + cborData.WriteString("IntField") + cborData.WriteByte(byte(cborTypePositiveInt) | 24) + cborData.WriteByte(123) + + cborData.WriteByte(byte(cborTypeTextString) | 8) // "MapField" + cborData.WriteString("MapField") + cborData.WriteByte(byte(cborTypeMap) | 2) + cborData.WriteByte(byte(cborTypeTextString) | 7) + cborData.WriteString("morning") + cborData.WriteByte(byte(cborTypePrimitives) | 21) + cborData.WriteByte(byte(cborTypeTextString) | 9) + cborData.WriteString("afternoon") + cborData.WriteByte(byte(cborTypePrimitives) | 20) + + cborData.WriteByte(byte(cborTypeTextString) | 9) // "BoolField" + cborData.WriteString("BoolField") + cborData.WriteByte(byte(cborTypePrimitives) | 21) + + cborData.WriteByte(byte(cborTypeTextString) | 10) // "ArrayField" + cborData.WriteString("ArrayField") + cborData.WriteByte(byte(cborTypeArray) | 2) + cborData.WriteByte(byte(cborTypeTextString) | 5) + cborData.WriteString("hello") + cborData.WriteByte(byte(cborTypeTextString) | 5) + cborData.WriteString("world") + + cborData.WriteByte(byte(cborTypeTextString) | 10) // "FloatField" + cborData.WriteString("FloatField") + cborData.Write([]byte{0xfa, 0x47, 0xc3, 0x50, 0x00}) + + cborData.WriteByte(byte(cborTypeTextString) | 11) // "StringField" + cborData.WriteString("StringField") + cborData.WriteByte(byte(cborTypeTextString) | 4) + cborData.WriteString("test") + + cborData.WriteByte(byte(cborTypeTextString) | 15) // "ByteStringField" + cborData.WriteString("ByteStringField") + cborData.WriteByte(byte(cborTypeByteString) | 3) + cborData.Write([]byte{1, 3, 5}) + + cborData.WriteByte(byte(cborTypeTextString) | 17) // "NestedStructField" + cborData.WriteString("NestedStructField") + cborData.WriteByte(byte(cborTypeMap) | 2) + cborData.WriteByte(byte(cborTypeTextString) | 1) + cborData.WriteString("X") + cborData.WriteByte(byte(cborTypePositiveInt) | 25) + b := make([]byte, 2) + binary.BigEndian.PutUint16(b, uint16(1000)) + cborData.Write(b) + cborData.WriteByte(byte(cborTypeTextString) | 1) + cborData.WriteString("Y") + cborData.WriteByte(byte(cborTypePositiveInt) | 26) + b = make([]byte, 4) + binary.BigEndian.PutUint32(b, uint32(1000000)) + cborData.Write(b) + + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %q", err) + } + if b, err := em.Marshal(v); err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, cborData.Bytes()) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, cborData.Bytes()) + } +} + +func TestMarshalNullPointerToEmbeddedStruct(t *testing.T) { + type ( + T1 struct { + X int + } + T2 struct { + *T1 + } + ) + v := T2{} + wantCborData := []byte{0xa0} // {} + cborData, err := Marshal(v) + if err != nil { + t.Fatalf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(wantCborData, cborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, cborData, wantCborData) + } +} + +func TestMarshalNullPointerToStruct(t *testing.T) { + type ( + T1 struct { + X int + } + T2 struct { + T *T1 + } + ) + v := T2{} + wantCborData := []byte{0xa1, 0x61, 0x54, 0xf6} // {X: nil} + cborData, err := Marshal(v) + if err != nil { + t.Fatalf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(wantCborData, cborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, cborData, wantCborData) + } +} + +// Struct fields encoding follows the same struct fields visibility +// rules used by JSON encoding package. Some struct types are from +// tests in JSON encoding package to ensure that the same rules are +// followed. +func TestAnonymousFields1(t *testing.T) { + // Fields (T1.X, T2.X) with the same name at the same level are ignored + type ( + T1 struct{ x, X int } + T2 struct{ x, X int } + T struct { + T1 + T2 + } + ) + v := T{T1{1, 2}, T2{3, 4}} + want := []byte{0xa0} // {} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } +} + +func TestAnonymousFields2(t *testing.T) { + // Field (T.X) with the same name at a less nested level is serialized + type ( + T1 struct{ x, X int } + T2 struct{ x, X int } + T struct { + T1 + T2 + x, X int + } + ) + v := T{T1{1, 2}, T2{3, 4}, 5, 6} + want := []byte{0xa1, 0x61, 0x58, 0x06} // {X:6} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + unmarshalWant := T{X: 6} + if err := Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestAnonymousFields3(t *testing.T) { + // Unexported embedded field (myInt) of non-struct type is ignored + type ( + myInt int + T struct { + myInt + } + ) + v := T{5} + want := []byte{0xa0} // {} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } +} + +func TestAnonymousFields4(t *testing.T) { + // Exported embedded field (MyInt) of non-struct type is serialized + type ( + MyInt int + T struct { + MyInt + } + ) + v := T{5} + want := []byte{0xa1, 0x65, 0x4d, 0x79, 0x49, 0x6e, 0x74, 0x05} // {MyInt: 5} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v, v2) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v, v, v2, v2) + } +} + +func TestAnonymousFields5(t *testing.T) { + // Unexported embedded field (*myInt) of pointer to non-struct type is ignored + type ( + myInt int + T struct { + *myInt + } + ) + v := T{new(myInt)} + *v.myInt = 5 + want := []byte{0xa0} // {} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } +} + +func TestAnonymousFields6(t *testing.T) { + // Exported embedded field (*MyInt) of pointer to non-struct type should be serialized + type ( + MyInt int + T struct { + *MyInt + } + ) + v := T{new(MyInt)} + *v.MyInt = 5 + want := []byte{0xa1, 0x65, 0x4d, 0x79, 0x49, 0x6e, 0x74, 0x05} // {MyInt: 5} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v, v2) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v, v, v2, v2) + } +} + +func TestAnonymousFields7(t *testing.T) { + // Exported fields (t1.X, T2.Y) of embedded structs should have their exported fields be serialized + type ( + t1 struct{ x, X int } + T2 struct{ y, Y int } + T struct { + t1 + T2 + } + ) + v := T{t1{1, 2}, T2{3, 4}} + want := []byte{0xa2, 0x61, 0x58, 0x02, 0x61, 0x59, 0x04} // {X:2, Y:4} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + unmarshalWant := T{t1{X: 2}, T2{Y: 4}} + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestAnonymousFields8(t *testing.T) { + // Exported fields of pointers (t1.X, T2.Y) + type ( + t1 struct{ x, X int } + T2 struct{ y, Y int } + T struct { + *t1 + *T2 + } + ) + v := T{&t1{1, 2}, &T2{3, 4}} + want := []byte{0xa2, 0x61, 0x58, 0x02, 0x61, 0x59, 0x04} // {X:2, Y:4} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + // v1 cannot be unmarshaled to because reflect cannot allocate unexported field s1. + var v1 T + wantErrorMsg := "cannot set embedded pointer to unexported struct" + wantV := T{T2: &T2{Y: 4}} + err = Unmarshal(b, &v1) + if err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error %q", b, wantErrorMsg) + } else if !strings.Contains(err.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error %q", b, err.Error(), wantErrorMsg) + } + if !reflect.DeepEqual(v1, wantV) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", b, v1, v1, wantV, wantV) + } + + // v2 can be unmarshaled to because unexported field t1 is already allocated. + var v2 T + v2.t1 = &t1{} + unmarshalWant := T{&t1{X: 2}, &T2{Y: 4}} + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestAnonymousFields9(t *testing.T) { + // Multiple levels of nested anonymous fields + type ( + MyInt1 int + MyInt2 int + myInt int + t2 struct { + MyInt2 + myInt + } + t1 struct { + MyInt1 + myInt + t2 + } + T struct { + t1 + myInt + } + ) + v := T{t1{1, 2, t2{3, 4}}, 6} + want := []byte{0xa2, 0x66, 0x4d, 0x79, 0x49, 0x6e, 0x74, 0x31, 0x01, 0x66, 0x4d, 0x79, 0x49, 0x6e, 0x74, 0x32, 0x03} // {MyInt1: 1, MyInt2: 3} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + unmarshalWant := T{t1: t1{MyInt1: 1, t2: t2{MyInt2: 3}}} + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestAnonymousFields10(t *testing.T) { + // Fields of the same struct type at the same level + type ( + t3 struct { + Z int + } + t1 struct { + X int + t3 + } + t2 struct { + Y int + t3 + } + T struct { + t1 + t2 + } + ) + v := T{t1{1, t3{2}}, t2{3, t3{4}}} + want := []byte{0xa2, 0x61, 0x58, 0x01, 0x61, 0x59, 0x03} // {X: 1, Y: 3} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + unmarshalWant := T{t1: t1{X: 1}, t2: t2{Y: 3}} + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestAnonymousFields11(t *testing.T) { + // Fields (T.t2.X, T.t1.t2.X) of the same struct type at different levels + type ( + t2 struct { + X int + } + t1 struct { + Y int + t2 + } + T struct { + t1 + t2 + } + ) + v := T{t1{1, t2{2}}, t2{3}} + want := []byte{0xa2, 0x61, 0x59, 0x01, 0x61, 0x58, 0x03} // {Y: 1, X: 3} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + unmarshalWant := T{t1: t1{Y: 1}, t2: t2{X: 3}} + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestOmitAndRenameStructField(t *testing.T) { + type T struct { + I int // never omit + Io int `cbor:",omitempty"` // omit empty + Iao int `cbor:"-"` // always omit + R int `cbor:"omitempty"` // renamed to omitempty + } + + v1 := T{} + // {"I": 0, "omitempty": 0} + want1 := []byte{0xa2, + 0x61, 0x49, 0x00, + 0x69, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x00} + + v2 := T{I: 1, Io: 2, Iao: 0, R: 3} + // {"I": 1, "Io": 2, "omitempty": 3} + want2 := []byte{0xa3, + 0x61, 0x49, 0x01, + 0x62, 0x49, 0x6f, 0x02, + 0x69, 0x6f, 0x6d, 0x69, 0x74, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x03} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + tests := []roundTripTest{ + {"default values", v1, want1}, + {"non-default values", v2, want2}} + testRoundTrip(t, tests, em, dm) +} + +func TestOmitEmptyForBuiltinType(t *testing.T) { + type T struct { + B bool `cbor:"b"` + Bo bool `cbor:"bo,omitempty"` + UI uint `cbor:"ui"` + UIo uint `cbor:"uio,omitempty"` + I int `cbor:"i"` + Io int `cbor:"io,omitempty"` + F float64 `cbor:"f"` + Fo float64 `cbor:"fo,omitempty"` + S string `cbor:"s"` + So string `cbor:"so,omitempty"` + Slc []string `cbor:"slc"` + Slco []string `cbor:"slco,omitempty"` + M map[int]string `cbor:"m"` + Mo map[int]string `cbor:"mo,omitempty"` + P *int `cbor:"p"` + Po *int `cbor:"po,omitempty"` + Intf interface{} `cbor:"intf"` + Intfo interface{} `cbor:"intfo,omitempty"` + } + + v := T{} + // {"b": false, "ui": 0, "i":0, "f": 0, "s": "", "slc": null, "m": {}, "p": nil, "intf": nil } + want := []byte{0xa9, + 0x61, 0x62, 0xf4, + 0x62, 0x75, 0x69, 0x00, + 0x61, 0x69, 0x00, + 0x61, 0x66, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x61, 0x73, 0x60, + 0x63, 0x73, 0x6c, 0x63, 0xf6, + 0x61, 0x6d, 0xf6, + 0x61, 0x70, 0xf6, + 0x64, 0x69, 0x6e, 0x74, 0x66, 0xf6, + } + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"default values", v, want}}, em, dm) +} + +func TestOmitEmptyForAnonymousStruct(t *testing.T) { + type T struct { + Str struct{} `cbor:"str"` + Stro struct{} `cbor:"stro,omitempty"` + } + + v := T{} + want := []byte{0xa1, 0x63, 0x73, 0x74, 0x72, 0xa0} // {"str": {}} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"default values", v, want}}, em, dm) +} + +func TestOmitEmptyForStruct1(t *testing.T) { + type T1 struct { + Bo bool `cbor:"bo,omitempty"` + UIo uint `cbor:"uio,omitempty"` + Io int `cbor:"io,omitempty"` + Fo float64 `cbor:"fo,omitempty"` + So string `cbor:"so,omitempty"` + Slco []string `cbor:"slco,omitempty"` + Mo map[int]string `cbor:"mo,omitempty"` + Po *int `cbor:"po,omitempty"` + Intfo interface{} `cbor:"intfo,omitempty"` + } + type T struct { + Str T1 `cbor:"str"` + Stro T1 `cbor:"stro,omitempty"` + } + + v := T{} + want := []byte{0xa1, 0x63, 0x73, 0x74, 0x72, 0xa0} // {"str": {}} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"default values", v, want}}, em, dm) +} + +func TestOmitEmptyForStruct2(t *testing.T) { + type T1 struct { + Bo bool `cbor:"bo,omitempty"` + UIo uint `cbor:"uio,omitempty"` + Io int `cbor:"io,omitempty"` + Fo float64 `cbor:"fo,omitempty"` + So string `cbor:"so,omitempty"` + Slco []string `cbor:"slco,omitempty"` + Mo map[int]string `cbor:"mo,omitempty"` + Po *int `cbor:"po,omitempty"` + Intfo interface{} `cbor:"intfo"` + } + type T struct { + Stro T1 `cbor:"stro,omitempty"` + } + + v := T{} + want := []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0xa1, 0x65, 0x69, 0x6e, 0x74, 0x66, 0x6f, 0xf6} // {"stro": {intfo: nil}} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"non-default values", v, want}}, em, dm) +} + +func TestOmitEmptyForNestedStruct(t *testing.T) { + type T1 struct { + Bo bool `cbor:"bo,omitempty"` + UIo uint `cbor:"uio,omitempty"` + Io int `cbor:"io,omitempty"` + Fo float64 `cbor:"fo,omitempty"` + So string `cbor:"so,omitempty"` + Slco []string `cbor:"slco,omitempty"` + Mo map[int]string `cbor:"mo,omitempty"` + Po *int `cbor:"po,omitempty"` + Intfo interface{} `cbor:"intfo,omitempty"` + } + type T2 struct { + Stro T1 `cbor:"stro,omitempty"` + } + type T struct { + Str T2 `cbor:"str"` + Stro T2 `cbor:"stro,omitempty"` + } + + v := T{} + want := []byte{0xa1, 0x63, 0x73, 0x74, 0x72, 0xa0} // {"str": {}} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"default values", v, want}}, em, dm) +} + +func TestOmitEmptyForToArrayStruct1(t *testing.T) { + type T1 struct { + _ struct{} `cbor:",toarray"` + b bool + ui uint + i int + f float64 + s string + slc []string + m map[int]string + p *int + intf interface{} + } + type T struct { + Str T1 `cbor:"str"` + Stro T1 `cbor:"stro,omitempty"` + } + + v := T{ + Str: T1{b: false, ui: 0, i: 0, f: 0.0, s: "", slc: nil, m: nil, p: nil, intf: nil}, + Stro: T1{b: false, ui: 0, i: 0, f: 0.0, s: "", slc: nil, m: nil, p: nil, intf: nil}, + } + want := []byte{0xa1, 0x63, 0x73, 0x74, 0x72, 0x80} // {"str": []} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"no exportable fields", v, want}}, em, dm) +} + +func TestOmitEmptyForToArrayStruct2(t *testing.T) { + type T1 struct { + _ struct{} `cbor:",toarray"` + Bo bool `cbor:"bo"` + UIo uint `cbor:"uio"` + Io int `cbor:"io"` + Fo float64 `cbor:"fo"` + So string `cbor:"so"` + Slco []string `cbor:"slco"` + Mo map[int]string `cbor:"mo"` + Po *int `cbor:"po"` + Intfo interface{} `cbor:"intfo"` + } + type T struct { + Stro T1 `cbor:"stro,omitempty"` + } + + v := T{} + // {"stro": [false, 0, 0, 0.0, "", [], {}, nil, nil]} + want := []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0x89, 0xf4, 0x00, 0x00, 0xfb, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0xf6, 0xf6, 0xf6, 0xf6} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"has exportable fields", v, want}}, em, dm) +} + +func TestOmitEmptyForStructWithPtrToAnonymousField(t *testing.T) { + type ( + T1 struct { + X int `cbor:"x,omitempty"` + Y int `cbor:"y,omitempty"` + } + T2 struct { + *T1 + } + T struct { + Stro T2 `cbor:"stro,omitempty"` + } + ) + + testCases := []struct { + name string + obj interface{} + wantCborData []byte + }{ + { + name: "null pointer to anonymous field", + obj: T{}, + wantCborData: []byte{0xa0}, // {} + }, + { + name: "not-null pointer to anonymous field", + obj: T{T2{&T1{}}}, + wantCborData: []byte{0xa0}, // {} + }, + { + name: "not empty value in field 1", + obj: T{T2{&T1{X: 1}}}, + wantCborData: []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0xa1, 0x61, 0x78, 0x01}, // {stro:{x:1}} + }, + { + name: "not empty value in field 2", + obj: T{T2{&T1{Y: 2}}}, + wantCborData: []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0xa1, 0x61, 0x79, 0x02}, // {stro:{y:2}} + }, + { + name: "not empty value in all fields", + obj: T{T2{&T1{X: 1, Y: 2}}}, + wantCborData: []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0xa2, 0x61, 0x78, 0x01, 0x61, 0x79, 0x02}, // {stro:{x:1, y:2}} + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := Marshal(tc.obj) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.obj, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.obj, b, tc.wantCborData) + } + }) + } +} + +func TestOmitEmptyForStructWithAnonymousField(t *testing.T) { + type ( + T1 struct { + X int `cbor:"x,omitempty"` + Y int `cbor:"y,omitempty"` + } + T2 struct { + T1 + } + T struct { + Stro T2 `cbor:"stro,omitempty"` + } + ) + + testCases := []struct { + name string + obj interface{} + wantCborData []byte + }{ + { + name: "default values", + obj: T{}, + wantCborData: []byte{0xa0}, // {} + }, + { + name: "default values", + obj: T{T2{T1{}}}, + wantCborData: []byte{0xa0}, // {} + }, + { + name: "not empty value in field 1", + obj: T{T2{T1{X: 1}}}, + wantCborData: []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0xa1, 0x61, 0x78, 0x01}, // {stro:{x:1}} + }, + { + name: "not empty value in field 2", + obj: T{T2{T1{Y: 2}}}, + wantCborData: []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0xa1, 0x61, 0x79, 0x02}, // {stro:{y:2}} + }, + { + name: "not empty value in all fields", + obj: T{T2{T1{X: 1, Y: 2}}}, + wantCborData: []byte{0xa1, 0x64, 0x73, 0x74, 0x72, 0x6f, 0xa2, 0x61, 0x78, 0x01, 0x61, 0x79, 0x02}, // {stro:{x:1, y:2}} + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := Marshal(tc.obj) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.obj, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.obj, b, tc.wantCborData) + } + }) + } +} + +func TestOmitEmptyForBinaryMarshaler1(t *testing.T) { + type T1 struct { + No number `cbor:"no,omitempty"` + } + type T struct { + Str T1 `cbor:"str"` + Stro T1 `cbor:"stro,omitempty"` + } + + testCases := []roundTripTest{ + { + "empty BinaryMarshaler", + T1{}, + []byte{0xa0}, // {} + }, + { + "empty struct containing empty BinaryMarshaler", + T{}, + []byte{0xa1, 0x63, 0x73, 0x74, 0x72, 0xa0}, // {str: {}} + }, + } + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, testCases, em, dm) +} + +func TestOmitEmptyForBinaryMarshaler2(t *testing.T) { + type T1 struct { + So stru `cbor:"so,omitempty"` + } + type T struct { + Str T1 `cbor:"str"` + Stro T1 `cbor:"stro,omitempty"` + } + + testCases := []roundTripTest{ + { + "empty BinaryMarshaler", + T1{}, + []byte{0xa0}, // {} + }, + { + "empty struct containing empty BinaryMarshaler", + T{}, + []byte{0xa1, 0x63, 0x73, 0x74, 0x72, 0xa0}, // {str: {}} + }, + } + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, testCases, em, dm) +} + +// omitempty is a no-op for time.Time. +func TestOmitEmptyForTime(t *testing.T) { + type T struct { + Tm time.Time `cbor:"t,omitempty"` + } + + v := T{} + want := []byte{0xa1, 0x61, 0x74, 0xf6} // {"t": nil} + + em, _ := EncOptions{}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"default values", v, want}}, em, dm) +} + +// omitempty is a no-op for big.Int. +func TestOmitEmptyForBigInt(t *testing.T) { + type T struct { + I big.Int `cbor:"bi,omitempty"` + } + + v := T{} + want := []byte{0xa1, 0x62, 0x62, 0x69, 0xc2, 0x40} // {"bi": 2([])} + + em, _ := EncOptions{BigIntConvert: BigIntConvertNone}.EncMode() + dm, _ := DecOptions{}.DecMode() + testRoundTrip(t, []roundTripTest{{"default values", v, want}}, em, dm) +} + +func TestTaggedField(t *testing.T) { + // A field (T2.X) with a tag dominates untagged field. + type ( + T1 struct { + S string + } + T2 struct { + X string `cbor:"S"` + } + T struct { + T1 + T2 + } + ) + v := T{T1{"T1"}, T2{"T2"}} + want := []byte{0xa1, 0x61, 0x53, 0x62, 0x54, 0x32} // {"S":"T2"} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + unmarshalWant := T{T2: T2{"T2"}} + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestDuplicatedFields(t *testing.T) { + // Duplicate fields (T.T1.S, T.T2.S) are ignored. + type ( + T1 struct { + S string + } + T2 struct { + S string + } + T3 struct { + X string `cbor:"S"` + } + T4 struct { + T1 + T3 + } + T struct { + T1 + T2 + T4 // Contains a tagged S field through T3; should not dominate. + } + ) + v := T{ + T1{"T1"}, + T2{"T2"}, + T4{ + T1{"nested T1"}, + T3{"nested T3"}, + }, + } + want := []byte{0xa0} // {} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } +} + +type TReader struct { + X int +} + +func (s TReader) Read(p []byte) (n int, err error) { + return 0, nil +} + +func TestTaggedAnonymousField(t *testing.T) { + // Anonymous field with a name given in its CBOR tag is treated as having that name, rather than being anonymous. + type ( + T1 struct { + X int + } + T struct { + X int + T1 `cbor:"T1"` + } + ) + v := T{X: 1, T1: T1{X: 2}} + want := []byte{0xa2, 0x61, 0x58, 0x01, 0x62, 0x54, 0x31, 0xa1, 0x61, 0x58, 0x02} // {X: 1, T1: {X:2}} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + unmarshalWant := T{X: 1, T1: T1{X: 2}} + if err = Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if !reflect.DeepEqual(v2, unmarshalWant) { + t.Errorf("Unmarshal(0x%x) = %+v (%T), want %+v (%T)", b, v2, v2, unmarshalWant, unmarshalWant) + } +} + +func TestAnonymousInterfaceField(t *testing.T) { + // Anonymous field of interface type is treated the same as having that type as its name, rather than being anonymous. + type ( + T struct { + X int + io.Reader + } + ) + v := T{X: 1, Reader: TReader{X: 2}} + want := []byte{0xa2, 0x61, 0x58, 0x01, 0x66, 0x52, 0x65, 0x61, 0x64, 0x65, 0x72, 0xa1, 0x61, 0x58, 0x02} // {X: 1, Reader: {X:2}} + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", v, b, want) + } + + var v2 T + const wantErrorMsg = "cannot unmarshal map into Go struct field cbor.T.Reader of type io.Reader" + if err = Unmarshal(b, &v2); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error (*UnmarshalTypeError)", b) + } else { + if typeError, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*UnmarshalTypeError)", b, err) + } else if !strings.Contains(typeError.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", b, err.Error(), wantErrorMsg) + } + } +} + +func TestEncodeInterface(t *testing.T) { + var r io.Reader = TReader{X: 2} + want := []byte{0xa1, 0x61, 0x58, 0x02} // {X:2} + b, err := Marshal(r) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", r, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", r, b, want) + } + + var v io.Reader + const wantErrorMsg = "cannot unmarshal map into Go value of type io.Reader" + if err = Unmarshal(b, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error, want error (*UnmarshalTypeError)", b) + } else { + if typeError, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*UnmarshalTypeError)", b, err) + } else if !strings.Contains(typeError.Error(), wantErrorMsg) { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", b, err.Error(), wantErrorMsg) + } + } +} + +func TestEncodeTime(t *testing.T) { + timeUnixOpt := EncOptions{Time: TimeUnix} + timeUnixMicroOpt := EncOptions{Time: TimeUnixMicro} + timeUnixDynamicOpt := EncOptions{Time: TimeUnixDynamic} + timeRFC3339Opt := EncOptions{Time: TimeRFC3339} + timeRFC3339NanoOpt := EncOptions{Time: TimeRFC3339Nano} + + type timeConvert struct { + opt EncOptions + wantCborData []byte + } + testCases := []struct { + name string + tm time.Time + convert []timeConvert + }{ + { + name: "zero time", + tm: time.Time{}, + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + }, + }, + { + name: "time without fractional seconds", + tm: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("1a514b67b0"), // 1363896240 + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("fb41d452d9ec000000"), // 1363896240.0 + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("1a514b67b0"), // 1363896240 + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("74323031332d30332d32315432303a30343a30305a"), // "2013-03-21T20:04:00Z" + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("74323031332d30332d32315432303a30343a30305a"), // "2013-03-21T20:04:00Z" + }, + }, + }, + { + name: "time with fractional seconds", + tm: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00.5Z"), + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("1a514b67b0"), // 1363896240 + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("fb41d452d9ec200000"), // 1363896240.5 + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("fb41d452d9ec200000"), // 1363896240.5 + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("74323031332d30332d32315432303a30343a30305a"), // "2013-03-21T20:04:00Z" + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("76323031332d30332d32315432303a30343a30302e355a"), // "2013-03-21T20:04:00.5Z" + }, + }, + }, + { + name: "time before January 1, 1970 UTC without fractional seconds", + tm: parseTime(time.RFC3339Nano, "1969-03-21T20:04:00Z"), + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("3a0177f2cf"), // -24638160 + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("fbc1777f2d00000000"), // -24638160.0 + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("3a0177f2cf"), // -24638160 + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("74313936392d30332d32315432303a30343a30305a"), // "1969-03-21T20:04:00Z" + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("74313936392d30332d32315432303a30343a30305a"), // "1969-03-21T20:04:00Z" + }, + }, + }, + } + for _, tc := range testCases { + for _, convert := range tc.convert { + var convertName string + switch convert.opt.Time { + case TimeUnix: + convertName = "TimeUnix" + case TimeUnixMicro: + convertName = "TimeUnixMicro" + case TimeUnixDynamic: + convertName = "TimeUnixDynamic" + case TimeRFC3339: + convertName = "TimeRFC3339" + case TimeRFC3339Nano: + convertName = "TimeRFC3339Nano" + } + name := tc.name + " with " + convertName + " option" + t.Run(name, func(t *testing.T) { + em, err := convert.opt.EncMode() + if err != nil { + t.Errorf("EncMode() returned error %v", err) + } + b, err := em.Marshal(tc.tm) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.tm, err) + } else if !bytes.Equal(b, convert.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.tm, b, convert.wantCborData) + } + }) + } + } +} + +func TestEncodeTimeWithTag(t *testing.T) { + timeUnixOpt := EncOptions{Time: TimeUnix, TimeTag: EncTagRequired} + timeUnixMicroOpt := EncOptions{Time: TimeUnixMicro, TimeTag: EncTagRequired} + timeUnixDynamicOpt := EncOptions{Time: TimeUnixDynamic, TimeTag: EncTagRequired} + timeRFC3339Opt := EncOptions{Time: TimeRFC3339, TimeTag: EncTagRequired} + timeRFC3339NanoOpt := EncOptions{Time: TimeRFC3339Nano, TimeTag: EncTagRequired} + + type timeConvert struct { + opt EncOptions + wantCborData []byte + } + testCases := []struct { + name string + tm time.Time + convert []timeConvert + }{ + { + name: "zero time", + tm: time.Time{}, + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("f6"), // encode as CBOR null + }, + }, + }, + { + name: "time without fractional seconds", + tm: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00Z"), + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("c11a514b67b0"), // 1363896240 + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("c1fb41d452d9ec000000"), // 1363896240.0 + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("c11a514b67b0"), // 1363896240 + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("c074323031332d30332d32315432303a30343a30305a"), // "2013-03-21T20:04:00Z" + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("c074323031332d30332d32315432303a30343a30305a"), // "2013-03-21T20:04:00Z" + }, + }, + }, + { + name: "time with fractional seconds", + tm: parseTime(time.RFC3339Nano, "2013-03-21T20:04:00.5Z"), + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("c11a514b67b0"), // 1363896240 + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("c1fb41d452d9ec200000"), // 1363896240.5 + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("c1fb41d452d9ec200000"), // 1363896240.5 + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("c074323031332d30332d32315432303a30343a30305a"), // "2013-03-21T20:04:00Z" + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("c076323031332d30332d32315432303a30343a30302e355a"), // "2013-03-21T20:04:00.5Z" + }, + }, + }, + { + name: "time before January 1, 1970 UTC without fractional seconds", + tm: parseTime(time.RFC3339Nano, "1969-03-21T20:04:00Z"), + convert: []timeConvert{ + { + opt: timeUnixOpt, + wantCborData: hexDecode("c13a0177f2cf"), // -24638160 + }, + { + opt: timeUnixMicroOpt, + wantCborData: hexDecode("c1fbc1777f2d00000000"), // -24638160.0 + }, + { + opt: timeUnixDynamicOpt, + wantCborData: hexDecode("c13a0177f2cf"), // -24638160 + }, + { + opt: timeRFC3339Opt, + wantCborData: hexDecode("c074313936392d30332d32315432303a30343a30305a"), // "1969-03-21T20:04:00Z" + }, + { + opt: timeRFC3339NanoOpt, + wantCborData: hexDecode("c074313936392d30332d32315432303a30343a30305a"), // "1969-03-21T20:04:00Z" + }, + }, + }, + } + for _, tc := range testCases { + for _, convert := range tc.convert { + var convertName string + switch convert.opt.Time { + case TimeUnix: + convertName = "TimeUnix" + case TimeUnixMicro: + convertName = "TimeUnixMicro" + case TimeUnixDynamic: + convertName = "TimeUnixDynamic" + case TimeRFC3339: + convertName = "TimeRFC3339" + case TimeRFC3339Nano: + convertName = "TimeRFC3339Nano" + } + name := tc.name + " with " + convertName + " option" + t.Run(name, func(t *testing.T) { + em, err := convert.opt.EncMode() + if err != nil { + t.Errorf("EncMode() returned error %v", err) + } + b, err := em.Marshal(tc.tm) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.tm, err) + } else if !bytes.Equal(b, convert.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.tm, b, convert.wantCborData) + } + }) + } + } +} + +func parseTime(layout string, value string) time.Time { + tm, err := time.Parse(layout, value) + if err != nil { + panic(err) + } + return tm +} + +func TestInvalidTimeMode(t *testing.T) { + wantErrorMsg := "cbor: invalid TimeMode 100" + _, err := EncOptions{Time: TimeMode(100)}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestMarshalStructTag1(t *testing.T) { + type strc struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + } + v := strc{ + A: "A", + B: "B", + C: "C", + } + want := hexDecode("a3616161416162614261636143") // {"a":"A", "b":"B", "c":"C"} + if b, err := Marshal(v); err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = %v, want %v", v, b, want) + } +} + +func TestMarshalStructTag2(t *testing.T) { + type strc struct { + A string `json:"a"` + B string `json:"b"` + C string `json:"c"` + } + v := strc{ + A: "A", + B: "B", + C: "C", + } + want := hexDecode("a3616161416162614261636143") // {"a":"A", "b":"B", "c":"C"} + if b, err := Marshal(v); err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = %v, want %v", v, b, want) + } +} + +func TestMarshalStructTag3(t *testing.T) { + type strc struct { + A string `json:"x" cbor:"a"` + B string `json:"y" cbor:"b"` + C string `json:"z"` + } + v := strc{ + A: "A", + B: "B", + C: "C", + } + want := hexDecode("a36161614161626142617a6143") // {"a":"A", "b":"B", "z":"C"} + if b, err := Marshal(v); err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = %v, want %v", v, b, want) + } +} + +func TestMarshalStructTag4(t *testing.T) { + type strc struct { + A string `json:"x" cbor:"a"` + B string `json:"y" cbor:"b"` + C string `json:"-"` + } + v := strc{ + A: "A", + B: "B", + C: "C", + } + want := hexDecode("a26161614161626142") // {"a":"A", "b":"B"} + if b, err := Marshal(v); err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = %v, want %v", v, b, want) + } +} + +func TestMarshalStructLongFieldName(t *testing.T) { + type strc struct { + A string `cbor:"a"` + B string `cbor:"abcdefghijklmnopqrstuvwxyz"` + C string `cbor:"abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmn"` + } + v := strc{ + A: "A", + B: "B", + C: "C", + } + want := hexDecode("a361616141781a6162636465666768696a6b6c6d6e6f707172737475767778797a614278426162636465666768696a6b6c6d6e6f707172737475767778797a6162636465666768696a6b6c6d6e6f707172737475767778797a6162636465666768696a6b6c6d6e6143") // {"a":"A", "abcdefghijklmnopqrstuvwxyz":"B", "abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmn":"C"} + if b, err := Marshal(v); err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } else if !bytes.Equal(b, want) { + t.Errorf("Marshal(%+v) = %v, want %v", v, b, want) + } +} + +func TestMarshalRawMessageValue(t *testing.T) { + type ( + T1 struct { + M RawMessage `cbor:",omitempty"` + } + T2 struct { + M *RawMessage `cbor:",omitempty"` + } + ) + + var ( + rawNil = RawMessage(nil) + rawEmpty = RawMessage([]byte{}) + raw = RawMessage([]byte{0x01}) + ) + + tests := []struct { + obj interface{} + want []byte + }{ + // Test with nil RawMessage. + {rawNil, []byte{0xf6}}, + {&rawNil, []byte{0xf6}}, + {[]interface{}{rawNil}, []byte{0x81, 0xf6}}, + {&[]interface{}{rawNil}, []byte{0x81, 0xf6}}, + {[]interface{}{&rawNil}, []byte{0x81, 0xf6}}, + {&[]interface{}{&rawNil}, []byte{0x81, 0xf6}}, + {struct{ M RawMessage }{rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&struct{ M RawMessage }{rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {struct{ M *RawMessage }{&rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&struct{ M *RawMessage }{&rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {map[string]interface{}{"M": rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&map[string]interface{}{"M": rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {map[string]interface{}{"M": &rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&map[string]interface{}{"M": &rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {T1{rawNil}, []byte{0xa0}}, + {T2{&rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&T1{rawNil}, []byte{0xa0}}, + {&T2{&rawNil}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + + // Test with empty, but non-nil, RawMessage. + {rawEmpty, []byte{0xf6}}, + {&rawEmpty, []byte{0xf6}}, + {[]interface{}{rawEmpty}, []byte{0x81, 0xf6}}, + {&[]interface{}{rawEmpty}, []byte{0x81, 0xf6}}, + {[]interface{}{&rawEmpty}, []byte{0x81, 0xf6}}, + {&[]interface{}{&rawEmpty}, []byte{0x81, 0xf6}}, + {struct{ M RawMessage }{rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&struct{ M RawMessage }{rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {struct{ M *RawMessage }{&rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&struct{ M *RawMessage }{&rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {map[string]interface{}{"M": rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&map[string]interface{}{"M": rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {map[string]interface{}{"M": &rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&map[string]interface{}{"M": &rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {T1{rawEmpty}, []byte{0xa0}}, + {T2{&rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + {&T1{rawEmpty}, []byte{0xa0}}, + {&T2{&rawEmpty}, []byte{0xa1, 0x61, 0x4d, 0xf6}}, + + // Test with RawMessage with some data. + {raw, []byte{0x01}}, + {&raw, []byte{0x01}}, + {[]interface{}{raw}, []byte{0x81, 0x01}}, + {&[]interface{}{raw}, []byte{0x81, 0x01}}, + {[]interface{}{&raw}, []byte{0x81, 0x01}}, + {&[]interface{}{&raw}, []byte{0x81, 0x01}}, + {struct{ M RawMessage }{raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {&struct{ M RawMessage }{raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {struct{ M *RawMessage }{&raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {&struct{ M *RawMessage }{&raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {map[string]interface{}{"M": raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {&map[string]interface{}{"M": raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {map[string]interface{}{"M": &raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {&map[string]interface{}{"M": &raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {T1{raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {T2{&raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {&T1{raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + {&T2{&raw}, []byte{0xa1, 0x61, 0x4d, 0x01}}, + } + + for _, tc := range tests { + b, err := Marshal(tc.obj) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.obj, err) + } + if !bytes.Equal(b, tc.want) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.obj, b, tc.want) + } + } +} + +func TestCyclicDataStructure(t *testing.T) { + type Node struct { + V int `cbor:"v"` + N *Node `cbor:"n,omitempty"` + } + v := Node{1, &Node{2, &Node{3, nil}}} // linked list: 1, 2, 3 + wantCborData := []byte{0xa2, 0x61, 0x76, 0x01, 0x61, 0x6e, 0xa2, 0x61, 0x76, 0x02, 0x61, 0x6e, 0xa1, 0x61, 0x76, 0x03} // {v: 1, n: {v: 2, n: {v: 3}}} + cborData, err := Marshal(v) + if err != nil { + t.Fatalf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(wantCborData, cborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, cborData, wantCborData) + } + var v1 Node + if err = Unmarshal(cborData, &v1); err != nil { + t.Fatalf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, v1) { + t.Errorf("Unmarshal(0x%x) returned %+v, want %+v", cborData, v1, v) + } +} + +func TestMarshalUnmarshalStructKeyAsInt(t *testing.T) { + type T struct { + F1 int `cbor:"1,omitempty,keyasint"` + F2 int `cbor:"2,omitempty"` + F3 int `cbor:"-3,omitempty,keyasint"` + } + testCases := []struct { + name string + obj interface{} + wantCborData []byte + }{ + { + "Zero value struct", + T{}, + hexDecode("a0"), // {} + }, + { + "Initialized value struct", + T{F1: 1, F2: 2, F3: 3}, + hexDecode("a301012203613202"), // {1: 1, -3: 3, "2": 2} + }, + } + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned error %v", err) + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := em.Marshal(tc.obj) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.obj, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.obj, b, tc.wantCborData) + } + + var v2 T + if err := Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } + if !reflect.DeepEqual(tc.obj, v2) { + t.Errorf("Unmarshal(0x%x) returned %+v, want %+v", b, v2, tc.obj) + } + }) + } +} + +func TestMarshalStructKeyAsIntNumError(t *testing.T) { + type T1 struct { + F1 int `cbor:"2.0,keyasint"` + } + type T2 struct { + F1 int `cbor:"-18446744073709551616,keyasint"` + } + testCases := []struct { + name string + obj interface{} + wantErrorMsg string + }{ + { + name: "float as key", + obj: T1{}, + wantErrorMsg: "cbor: failed to parse field name \"2.0\" to int", + }, + { + name: "out of range int as key", + obj: T2{}, + wantErrorMsg: "cbor: failed to parse field name \"-18446744073709551616\" to int", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := Marshal(tc.obj) + if err == nil { + t.Errorf("Marshal(%+v) didn't return an error, want error %q", tc.obj, tc.wantErrorMsg) + } else if !strings.Contains(err.Error(), tc.wantErrorMsg) { + t.Errorf("Marshal(%v) error %v, want %v", tc.obj, err.Error(), tc.wantErrorMsg) + } else if b != nil { + t.Errorf("Marshal(%v) = 0x%x, want nil", tc.obj, b) + } + }) + } +} + +func TestMarshalUnmarshalStructToArray(t *testing.T) { + type T1 struct { + M int `cbor:",omitempty"` + } + type T2 struct { + N int `cbor:",omitempty"` + O int `cbor:",omitempty"` + } + type T struct { + _ struct{} `cbor:",toarray"` + A int `cbor:",omitempty"` + B T1 // nested struct + T1 // embedded struct + *T2 // embedded struct + } + testCases := []struct { + name string + obj T + wantCborData []byte + }{ + { + "Zero value struct (test omitempty)", + T{}, + hexDecode("8500a000f6f6"), // [0, {}, 0, nil, nil] + }, + { + "Initialized struct", + T{A: 24, B: T1{M: 1}, T1: T1{M: 2}, T2: &T2{N: 3, O: 4}}, + hexDecode("851818a1614d01020304"), // [24, {M: 1}, 2, 3, 4] + }, + { + "Null pointer to embedded struct", + T{A: 24, B: T1{M: 1}, T1: T1{M: 2}}, + hexDecode("851818a1614d0102f6f6"), // [24, {M: 1}, 2, nil, nil] + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := Marshal(tc.obj) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.obj, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.obj, b, tc.wantCborData) + } + + // SortMode should be ignored for struct to array encoding + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned error %v", err) + } + b, err = em.Marshal(tc.obj) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", tc.obj, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", tc.obj, b, tc.wantCborData) + } + + var v2 T + if err := Unmarshal(b, &v2); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } + if tc.obj.T2 == nil { + if !reflect.DeepEqual(*(v2.T2), T2{}) { + t.Errorf("Unmarshal(0x%x) returned %+v, want %+v", b, v2, tc.obj) + } + v2.T2 = nil + } + if !reflect.DeepEqual(tc.obj, v2) { + t.Errorf("Unmarshal(0x%x) returned %+v, want %+v", b, v2, tc.obj) + } + }) + } +} + +func TestMapSort(t *testing.T) { + m := make(map[interface{}]bool) + m[10] = true + m[100] = true + m[-1] = true + m["z"] = true + m["aa"] = true + m[[1]int{100}] = true + m[[1]int{-1}] = true + m[false] = true + + lenFirstSortedCborData := hexDecode("a80af520f5f4f51864f5617af58120f5626161f5811864f5") // sorted keys: 10, -1, false, 100, "z", [-1], "aa", [100] + bytewiseSortedCborData := hexDecode("a80af51864f520f5617af5626161f5811864f58120f5f4f5") // sorted keys: 10, 100, -1, "z", "aa", [100], [-1], false + + testCases := []struct { + name string + opts EncOptions + wantCborData []byte + }{ + {"Length first sort", EncOptions{Sort: SortLengthFirst}, lenFirstSortedCborData}, + {"Bytewise sort", EncOptions{Sort: SortBytewiseLexical}, bytewiseSortedCborData}, + {"CBOR canonical sort", EncOptions{Sort: SortCanonical}, lenFirstSortedCborData}, + {"CTAP2 canonical sort", EncOptions{Sort: SortCTAP2}, bytewiseSortedCborData}, + {"Core deterministic sort", EncOptions{Sort: SortCoreDeterministic}, bytewiseSortedCborData}, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + em, err := tc.opts.EncMode() + if err != nil { + t.Errorf("EncMode() returned error %v", err) + } + b, err := em.Marshal(m) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", m, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", m, b, tc.wantCborData) + } + }) + } +} + +func TestStructSort(t *testing.T) { + type T struct { + A bool `cbor:"aa"` + B bool `cbor:"z"` + C bool `cbor:"-1,keyasint"` + D bool `cbor:"100,keyasint"` + E bool `cbor:"10,keyasint"` + } + var v T + + unsortedCborData := hexDecode("a5626161f4617af420f41864f40af4") // unsorted fields: "aa", "z", -1, 100, 10 + lenFirstSortedCborData := hexDecode("a50af420f41864f4617af4626161f4") // sorted fields: 10, -1, 100, "z", "aa", + bytewiseSortedCborData := hexDecode("a50af41864f420f4617af4626161f4") // sorted fields: 10, 100, -1, "z", "aa" + + testCases := []struct { + name string + opts EncOptions + wantCborData []byte + }{ + {"No sort", EncOptions{}, unsortedCborData}, + {"No sort", EncOptions{Sort: SortNone}, unsortedCborData}, + {"Length first sort", EncOptions{Sort: SortLengthFirst}, lenFirstSortedCborData}, + {"Bytewise sort", EncOptions{Sort: SortBytewiseLexical}, bytewiseSortedCborData}, + {"CBOR canonical sort", EncOptions{Sort: SortCanonical}, lenFirstSortedCborData}, + {"CTAP2 canonical sort", EncOptions{Sort: SortCTAP2}, bytewiseSortedCborData}, + {"Core deterministic sort", EncOptions{Sort: SortCoreDeterministic}, bytewiseSortedCborData}, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + em, err := tc.opts.EncMode() + if err != nil { + t.Errorf("EncMode() returned error %v", err) + } + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, tc.wantCborData) + } + }) + } +} + +func TestInvalidSort(t *testing.T) { + wantErrorMsg := "cbor: invalid SortMode 100" + _, err := EncOptions{Sort: SortMode(100)}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestTypeAlias(t *testing.T) { //nolint:dupl,unconvert + type myBool = bool + type myUint = uint + type myUint8 = uint8 + type myUint16 = uint16 + type myUint32 = uint32 + type myUint64 = uint64 + type myInt = int + type myInt8 = int8 + type myInt16 = int16 + type myInt32 = int32 + type myInt64 = int64 + type myFloat32 = float32 + type myFloat64 = float64 + type myString = string + type myByteSlice = []byte + type myIntSlice = []int + type myIntArray = [4]int + type myMapIntInt = map[int]int + + testCases := []roundTripTest{ + { + name: "bool alias", + obj: myBool(true), + wantCborData: hexDecode("f5"), + }, + { + name: "uint alias", + obj: myUint(0), + wantCborData: hexDecode("00"), + }, + { + name: "uint8 alias", + obj: myUint8(0), + wantCborData: hexDecode("00"), + }, + { + name: "uint16 alias", + obj: myUint16(1000), + wantCborData: hexDecode("1903e8"), + }, + { + name: "uint32 alias", + obj: myUint32(1000000), + wantCborData: hexDecode("1a000f4240"), + }, + { + name: "uint64 alias", + obj: myUint64(1000000000000), + wantCborData: hexDecode("1b000000e8d4a51000"), + }, + { + name: "int alias", + obj: myInt(-1), + wantCborData: hexDecode("20"), + }, + { + name: "int8 alias", + obj: myInt8(-1), + wantCborData: hexDecode("20"), + }, + { + name: "int16 alias", + obj: myInt16(-1000), + wantCborData: hexDecode("3903e7"), + }, + { + name: "int32 alias", + obj: myInt32(-1000), + wantCborData: hexDecode("3903e7"), + }, + { + name: "int64 alias", + obj: myInt64(-1000), + wantCborData: hexDecode("3903e7"), + }, + { + name: "float32 alias", + obj: myFloat32(100000.0), + wantCborData: hexDecode("fa47c35000"), + }, + { + name: "float64 alias", + obj: myFloat64(1.1), + wantCborData: hexDecode("fb3ff199999999999a"), + }, + { + name: "string alias", + obj: myString("a"), + wantCborData: hexDecode("6161"), + }, + { + name: "[]byte alias", + obj: myByteSlice([]byte{1, 2, 3, 4}), //nolint:unconvert + wantCborData: hexDecode("4401020304"), + }, + { + name: "[]int alias", + obj: myIntSlice([]int{1, 2, 3, 4}), //nolint:unconvert + wantCborData: hexDecode("8401020304"), + }, + { + name: "[4]int alias", + obj: myIntArray([...]int{1, 2, 3, 4}), //nolint:unconvert + wantCborData: hexDecode("8401020304"), + }, + { + name: "map[int]int alias", + obj: myMapIntInt(map[int]int{1: 2, 3: 4}), //nolint:unconvert + wantCborData: hexDecode("a201020304"), + }, + } + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + dm, err := DecOptions{}.DecMode() + if err != nil { + t.Errorf("DecMode() returned an error %v", err) + } + testRoundTrip(t, testCases, em, dm) +} + +func TestNewTypeWithBuiltinUnderlyingType(t *testing.T) { //nolint:dupl + type myBool bool + type myUint uint + type myUint8 uint8 + type myUint16 uint16 + type myUint32 uint32 + type myUint64 uint64 + type myInt int + type myInt8 int8 + type myInt16 int16 + type myInt32 int32 + type myInt64 int64 + type myFloat32 float32 + type myFloat64 float64 + type myString string + type myByteSlice []byte + type myIntSlice []int + type myIntArray [4]int + type myMapIntInt map[int]int + + testCases := []roundTripTest{ + { + name: "bool alias", + obj: myBool(true), + wantCborData: hexDecode("f5"), + }, + { + name: "uint alias", + obj: myUint(0), + wantCborData: hexDecode("00"), + }, + { + name: "uint8 alias", + obj: myUint8(0), + wantCborData: hexDecode("00"), + }, + { + name: "uint16 alias", + obj: myUint16(1000), + wantCborData: hexDecode("1903e8"), + }, + { + name: "uint32 alias", + obj: myUint32(1000000), + wantCborData: hexDecode("1a000f4240"), + }, + { + name: "uint64 alias", + obj: myUint64(1000000000000), + wantCborData: hexDecode("1b000000e8d4a51000"), + }, + { + name: "int alias", + obj: myInt(-1), + wantCborData: hexDecode("20"), + }, + { + name: "int8 alias", + obj: myInt8(-1), + wantCborData: hexDecode("20"), + }, + { + name: "int16 alias", + obj: myInt16(-1000), + wantCborData: hexDecode("3903e7"), + }, + { + name: "int32 alias", + obj: myInt32(-1000), + wantCborData: hexDecode("3903e7"), + }, + { + name: "int64 alias", + obj: myInt64(-1000), + wantCborData: hexDecode("3903e7"), + }, + { + name: "float32 alias", + obj: myFloat32(100000.0), + wantCborData: hexDecode("fa47c35000"), + }, + { + name: "float64 alias", + obj: myFloat64(1.1), + wantCborData: hexDecode("fb3ff199999999999a"), + }, + { + name: "string alias", + obj: myString("a"), + wantCborData: hexDecode("6161"), + }, + { + name: "[]byte alias", + obj: myByteSlice([]byte{1, 2, 3, 4}), + wantCborData: hexDecode("4401020304"), + }, + { + name: "[]int alias", + obj: myIntSlice([]int{1, 2, 3, 4}), + wantCborData: hexDecode("8401020304"), + }, + { + name: "[4]int alias", + obj: myIntArray([...]int{1, 2, 3, 4}), + wantCborData: hexDecode("8401020304"), + }, + { + name: "map[int]int alias", + obj: myMapIntInt(map[int]int{1: 2, 3: 4}), + wantCborData: hexDecode("a201020304"), + }, + } + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + dm, err := DecOptions{}.DecMode() + if err != nil { + t.Errorf("DecMode() returned an error %v", err) + } + testRoundTrip(t, testCases, em, dm) +} + +func TestShortestFloat16(t *testing.T) { + testCases := []struct { + name string + f64 float64 + wantCborData []byte + }{ + // Data from RFC 7049 appendix A + {"Shrink to float16", 0.0, hexDecode("f90000")}, + {"Shrink to float16", 1.0, hexDecode("f93c00")}, + {"Shrink to float16", 1.5, hexDecode("f93e00")}, + {"Shrink to float16", 65504.0, hexDecode("f97bff")}, + {"Shrink to float16", 5.960464477539063e-08, hexDecode("f90001")}, + {"Shrink to float16", 6.103515625e-05, hexDecode("f90400")}, + {"Shrink to float16", -4.0, hexDecode("f9c400")}, + // Data from https://en.wikipedia.org/wiki/Half-precision_floating-point_format + {"Shrink to float16", 0.333251953125, hexDecode("f93555")}, + // Data from 7049bis 4.2.1 and 5.5 + {"Shrink to float16", 5.5, hexDecode("f94580")}, + // Data from RFC 7049 appendix A + {"Shrink to float32", 100000.0, hexDecode("fa47c35000")}, + {"Shrink to float32", 3.4028234663852886e+38, hexDecode("fa7f7fffff")}, + // Data from 7049bis 4.2.1 and 5.5 + {"Shrink to float32", 5555.5, hexDecode("fa45ad9c00")}, + {"Shrink to float32", 1000000.5, hexDecode("fa49742408")}, + // Data from RFC 7049 appendix A + {"Shrink to float64", 1.0e+300, hexDecode("fb7e37e43c8800759c")}, + } + em, err := EncOptions{ShortestFloat: ShortestFloat16}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := em.Marshal(tc.f64) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.f64, err) + } else if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.f64, b, tc.wantCborData) + } + var f64 float64 + if err = Unmarshal(b, &f64); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if f64 != tc.f64 { + t.Errorf("Unmarshal(0x%x) = %f, want %f", b, f64, tc.f64) + } + }) + } +} + +/* +func TestShortestFloat32(t *testing.T) { + testCases := []struct { + name string + f64 float64 + wantCborData []byte + }{ + // Data from RFC 7049 appendix A + {"Shrink to float32", 0.0, hexDecode("fa00000000")}, + {"Shrink to float32", 1.0, hexDecode("fa3f800000")}, + {"Shrink to float32", 1.5, hexDecode("fa3fc00000")}, + {"Shrink to float32", 65504.0, hexDecode("fa477fe000")}, + {"Shrink to float32", 5.960464477539063e-08, hexDecode("fa33800000")}, + {"Shrink to float32", 6.103515625e-05, hexDecode("fa38800000")}, + {"Shrink to float32", -4.0, hexDecode("fac0800000")}, + // Data from https://en.wikipedia.org/wiki/Half-precision_floating-point_format + {"Shrink to float32", 0.333251953125, hexDecode("fa3eaaa000")}, + // Data from 7049bis 4.2.1 and 5.5 + {"Shrink to float32", 5.5, hexDecode("fa40b00000")}, + // Data from RFC 7049 appendix A + {"Shrink to float32", 100000.0, hexDecode("fa47c35000")}, + {"Shrink to float32", 3.4028234663852886e+38, hexDecode("fa7f7fffff")}, + // Data from 7049bis 4.2.1 and 5.5 + {"Shrink to float32", 5555.5, hexDecode("fa45ad9c00")}, + {"Shrink to float32", 1000000.5, hexDecode("fa49742408")}, + // Data from RFC 7049 appendix A + {"Shrink to float64", 1.0e+300, hexDecode("fb7e37e43c8800759c")}, + } + em, err := EncOptions{ShortestFloat: ShortestFloat32}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := em.Marshal(tc.f64) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.f64, err) + } else if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.f64, b, tc.wantCborData) + } + var f64 float64 + if err = Unmarshal(b, &f64); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if f64 != tc.f64 { + t.Errorf("Unmarshal(0x%x) = %f, want %f", b, f64, tc.f64) + } + }) + } +} + +func TestShortestFloat64(t *testing.T) { + testCases := []struct { + name string + f64 float64 + wantCborData []byte + }{ + // Data from RFC 7049 appendix A + {"Shrink to float64", 0.0, hexDecode("fb0000000000000000")}, + {"Shrink to float64", 1.0, hexDecode("fb3ff0000000000000")}, + {"Shrink to float64", 1.5, hexDecode("fb3ff8000000000000")}, + {"Shrink to float64", 65504.0, hexDecode("fb40effc0000000000")}, + {"Shrink to float64", 5.960464477539063e-08, hexDecode("fb3e70000000000000")}, + {"Shrink to float64", 6.103515625e-05, hexDecode("fb3f10000000000000")}, + {"Shrink to float64", -4.0, hexDecode("fbc010000000000000")}, + // Data from https://en.wikipedia.org/wiki/Half-precision_floating-point_format + {"Shrink to float64", 0.333251953125, hexDecode("fb3fd5540000000000")}, + // Data from 7049bis 4.2.1 and 5.5 + {"Shrink to float64", 5.5, hexDecode("fb4016000000000000")}, + // Data from RFC 7049 appendix A + {"Shrink to float64", 100000.0, hexDecode("fb40f86a0000000000")}, + {"Shrink to float64", 3.4028234663852886e+38, hexDecode("fb47efffffe0000000")}, + // Data from 7049bis 4.2.1 and 5.5 + {"Shrink to float64", 5555.5, hexDecode("fb40b5b38000000000")}, + {"Shrink to float64", 1000000.5, hexDecode("fb412e848100000000")}, + // Data from RFC 7049 appendix A + {"Shrink to float64", 1.0e+300, hexDecode("fb7e37e43c8800759c")}, + } + em, err := EncOptions{ShortestFloat: ShortestFloat64}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := em.Marshal(tc.f64) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.f64, err) + } else if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.f64, b, tc.wantCborData) + } + var f64 float64 + if err = Unmarshal(b, &f64); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if f64 != tc.f64 { + t.Errorf("Unmarshal(0x%x) = %f, want %f", b, f64, tc.f64) + } + }) + } +} +*/ +func TestShortestFloatNone(t *testing.T) { + testCases := []struct { + name string + f interface{} + wantCborData []byte + }{ + // Data from RFC 7049 appendix A + {"float32", float32(0.0), hexDecode("fa00000000")}, + {"float64", float64(0.0), hexDecode("fb0000000000000000")}, + {"float32", float32(1.0), hexDecode("fa3f800000")}, + {"float64", float64(1.0), hexDecode("fb3ff0000000000000")}, + {"float32", float32(1.5), hexDecode("fa3fc00000")}, + {"float64", float64(1.5), hexDecode("fb3ff8000000000000")}, + {"float32", float32(65504.0), hexDecode("fa477fe000")}, + {"float64", float64(65504.0), hexDecode("fb40effc0000000000")}, + {"float32", float32(5.960464477539063e-08), hexDecode("fa33800000")}, + {"float64", float64(5.960464477539063e-08), hexDecode("fb3e70000000000000")}, + {"float32", float32(6.103515625e-05), hexDecode("fa38800000")}, + {"float64", float64(6.103515625e-05), hexDecode("fb3f10000000000000")}, + {"float32", float32(-4.0), hexDecode("fac0800000")}, + {"float64", float64(-4.0), hexDecode("fbc010000000000000")}, + // Data from https://en.wikipedia.org/wiki/Half-precision_floating-point_format + {"float32", float32(0.333251953125), hexDecode("fa3eaaa000")}, + {"float64", float64(0.333251953125), hexDecode("fb3fd5540000000000")}, + // Data from 7049bis 4.2.1 and 5.5 + {"float32", float32(5.5), hexDecode("fa40b00000")}, + {"float64", float64(5.5), hexDecode("fb4016000000000000")}, + // Data from RFC 7049 appendix A + {"float32", float32(100000.0), hexDecode("fa47c35000")}, + {"float64", float64(100000.0), hexDecode("fb40f86a0000000000")}, + {"float32", float32(3.4028234663852886e+38), hexDecode("fa7f7fffff")}, + {"float64", float64(3.4028234663852886e+38), hexDecode("fb47efffffe0000000")}, + // Data from 7049bis 4.2.1 and 5.5 + {"float32", float32(5555.5), hexDecode("fa45ad9c00")}, + {"float64", float64(5555.5), hexDecode("fb40b5b38000000000")}, + {"float32", float32(1000000.5), hexDecode("fa49742408")}, + {"float64", float64(1000000.5), hexDecode("fb412e848100000000")}, + {"float64", float64(1.0e+300), hexDecode("fb7e37e43c8800759c")}, + } + em, err := EncOptions{ShortestFloat: ShortestFloatNone}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + b, err := em.Marshal(tc.f) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.f, err) + } else if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.f, b, tc.wantCborData) + } + if reflect.ValueOf(tc.f).Kind() == reflect.Float32 { + var f32 float32 + if err = Unmarshal(b, &f32); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if f32 != tc.f { + t.Errorf("Unmarshal(0x%x) = %f, want %f", b, f32, tc.f) + } + } else { + var f64 float64 + if err = Unmarshal(b, &f64); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", b, err) + } else if f64 != tc.f { + t.Errorf("Unmarshal(0x%x) = %f, want %f", b, f64, tc.f) + } + } + }) + } +} + +func TestInvalidShortestFloat(t *testing.T) { + wantErrorMsg := "cbor: invalid ShortestFloatMode 100" + _, err := EncOptions{ShortestFloat: ShortestFloatMode(100)}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestInfConvert(t *testing.T) { + infConvertNoneOpt := EncOptions{InfConvert: InfConvertNone} + infConvertFloat16Opt := EncOptions{InfConvert: InfConvertFloat16} + testCases := []struct { + name string + v interface{} + opts EncOptions + wantCborData []byte + }{ + {"float32 -inf no conversion", float32(math.Inf(-1)), infConvertNoneOpt, hexDecode("faff800000")}, + {"float32 +inf no conversion", float32(math.Inf(1)), infConvertNoneOpt, hexDecode("fa7f800000")}, + {"float64 -inf no conversion", math.Inf(-1), infConvertNoneOpt, hexDecode("fbfff0000000000000")}, + {"float64 +inf no conversion", math.Inf(1), infConvertNoneOpt, hexDecode("fb7ff0000000000000")}, + {"float32 -inf to float16", float32(math.Inf(-1)), infConvertFloat16Opt, hexDecode("f9fc00")}, + {"float32 +inf to float16", float32(math.Inf(1)), infConvertFloat16Opt, hexDecode("f97c00")}, + {"float64 -inf to float16", math.Inf(-1), infConvertFloat16Opt, hexDecode("f9fc00")}, + {"float64 +inf to float16", math.Inf(1), infConvertFloat16Opt, hexDecode("f97c00")}, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + em, err := tc.opts.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + b, err := em.Marshal(tc.v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.v, err) + } else if !bytes.Equal(b, tc.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.v, b, tc.wantCborData) + } + }) + } +} + +func TestInvalidInfConvert(t *testing.T) { + wantErrorMsg := "cbor: invalid InfConvertMode 100" + _, err := EncOptions{InfConvert: InfConvertMode(100)}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +// Keith Randall's workaround for constant propagation issue https://github.com/golang/go/issues/36400 +const ( + // qnan 32 bits constants + qnanConst0xffc00001 uint32 = 0xffc00001 + qnanConst0x7fc00001 uint32 = 0x7fc00001 + qnanConst0xffc02000 uint32 = 0xffc02000 + qnanConst0x7fc02000 uint32 = 0x7fc02000 + // snan 32 bits constants + snanConst0xff800001 uint32 = 0xff800001 + snanConst0x7f800001 uint32 = 0x7f800001 + snanConst0xff802000 uint32 = 0xff802000 + snanConst0x7f802000 uint32 = 0x7f802000 + // qnan 64 bits constants + qnanConst0xfff8000000000001 uint64 = 0xfff8000000000001 + qnanConst0x7ff8000000000001 uint64 = 0x7ff8000000000001 + qnanConst0xfff8000020000000 uint64 = 0xfff8000020000000 + qnanConst0x7ff8000020000000 uint64 = 0x7ff8000020000000 + qnanConst0xfffc000000000000 uint64 = 0xfffc000000000000 + qnanConst0x7ffc000000000000 uint64 = 0x7ffc000000000000 + // snan 64 bits constants + snanConst0xfff0000000000001 uint64 = 0xfff0000000000001 + snanConst0x7ff0000000000001 uint64 = 0x7ff0000000000001 + snanConst0xfff0000020000000 uint64 = 0xfff0000020000000 + snanConst0x7ff0000020000000 uint64 = 0x7ff0000020000000 + snanConst0xfff4000000000000 uint64 = 0xfff4000000000000 + snanConst0x7ff4000000000000 uint64 = 0x7ff4000000000000 +) + +var ( + // qnan 32 bits variables + qnanVar0xffc00001 uint32 = qnanConst0xffc00001 + qnanVar0x7fc00001 uint32 = qnanConst0x7fc00001 + qnanVar0xffc02000 uint32 = qnanConst0xffc02000 + qnanVar0x7fc02000 uint32 = qnanConst0x7fc02000 + // snan 32 bits variables + snanVar0xff800001 uint32 = snanConst0xff800001 + snanVar0x7f800001 uint32 = snanConst0x7f800001 + snanVar0xff802000 uint32 = snanConst0xff802000 + snanVar0x7f802000 uint32 = snanConst0x7f802000 + // qnan 64 bits variables + qnanVar0xfff8000000000001 uint64 = qnanConst0xfff8000000000001 + qnanVar0x7ff8000000000001 uint64 = qnanConst0x7ff8000000000001 + qnanVar0xfff8000020000000 uint64 = qnanConst0xfff8000020000000 + qnanVar0x7ff8000020000000 uint64 = qnanConst0x7ff8000020000000 + qnanVar0xfffc000000000000 uint64 = qnanConst0xfffc000000000000 + qnanVar0x7ffc000000000000 uint64 = qnanConst0x7ffc000000000000 + // snan 64 bits variables + snanVar0xfff0000000000001 uint64 = snanConst0xfff0000000000001 + snanVar0x7ff0000000000001 uint64 = snanConst0x7ff0000000000001 + snanVar0xfff0000020000000 uint64 = snanConst0xfff0000020000000 + snanVar0x7ff0000020000000 uint64 = snanConst0x7ff0000020000000 + snanVar0xfff4000000000000 uint64 = snanConst0xfff4000000000000 + snanVar0x7ff4000000000000 uint64 = snanConst0x7ff4000000000000 +) + +func TestNaNConvert(t *testing.T) { + nanConvert7e00Opt := EncOptions{NaNConvert: NaNConvert7e00} + nanConvertNoneOpt := EncOptions{NaNConvert: NaNConvertNone} + nanConvertPreserveSignalOpt := EncOptions{NaNConvert: NaNConvertPreserveSignal} + nanConvertQuietOpt := EncOptions{NaNConvert: NaNConvertQuiet} + + type nanConvert struct { + opt EncOptions + wantCborData []byte + } + testCases := []struct { + v interface{} + convert []nanConvert + }{ + // float32 qNaN dropped payload not zero + {math.Float32frombits(qnanVar0xffc00001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("faffc00001")}, + {nanConvertPreserveSignalOpt, hexDecode("faffc00001")}, + {nanConvertQuietOpt, hexDecode("faffc00001")}, + }}, + // float32 qNaN dropped payload not zero + {math.Float32frombits(qnanVar0x7fc00001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fa7fc00001")}, + {nanConvertPreserveSignalOpt, hexDecode("fa7fc00001")}, + {nanConvertQuietOpt, hexDecode("fa7fc00001")}, + }}, + // float32 -qNaN dropped payload zero + {math.Float32frombits(qnanVar0xffc02000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("faffc02000")}, + {nanConvertPreserveSignalOpt, hexDecode("f9fe01")}, + {nanConvertQuietOpt, hexDecode("f9fe01")}, + }}, + // float32 qNaN dropped payload zero + {math.Float32frombits(qnanVar0x7fc02000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fa7fc02000")}, + {nanConvertPreserveSignalOpt, hexDecode("f97e01")}, + {nanConvertQuietOpt, hexDecode("f97e01")}, + }}, + // float32 -sNaN dropped payload not zero + {math.Float32frombits(snanVar0xff800001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("faff800001")}, + {nanConvertPreserveSignalOpt, hexDecode("faff800001")}, + {nanConvertQuietOpt, hexDecode("faffc00001")}, + }}, + // float32 sNaN dropped payload not zero + {math.Float32frombits(snanVar0x7f800001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fa7f800001")}, + {nanConvertPreserveSignalOpt, hexDecode("fa7f800001")}, + {nanConvertQuietOpt, hexDecode("fa7fc00001")}, + }}, + // float32 -sNaN dropped payload zero + {math.Float32frombits(snanVar0xff802000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("faff802000")}, + {nanConvertPreserveSignalOpt, hexDecode("f9fc01")}, + {nanConvertQuietOpt, hexDecode("f9fe01")}, + }}, + // float32 sNaN dropped payload zero + {math.Float32frombits(snanVar0x7f802000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fa7f802000")}, + {nanConvertPreserveSignalOpt, hexDecode("f97c01")}, + {nanConvertQuietOpt, hexDecode("f97e01")}, + }}, + // float64 -qNaN dropped payload not zero + {math.Float64frombits(qnanVar0xfff8000000000001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fbfff8000000000001")}, + {nanConvertPreserveSignalOpt, hexDecode("fbfff8000000000001")}, + {nanConvertQuietOpt, hexDecode("fbfff8000000000001")}, + }}, + // float64 qNaN dropped payload not zero + {math.Float64frombits(qnanVar0x7ff8000000000001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fb7ff8000000000001")}, + {nanConvertPreserveSignalOpt, hexDecode("fb7ff8000000000001")}, + {nanConvertQuietOpt, hexDecode("fb7ff8000000000001")}, + }}, + // float64 -qNaN dropped payload zero + {math.Float64frombits(qnanVar0xfff8000020000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fbfff8000020000000")}, + {nanConvertPreserveSignalOpt, hexDecode("faffc00001")}, + {nanConvertQuietOpt, hexDecode("faffc00001")}, + }}, + // float64 qNaN dropped payload zero + {math.Float64frombits(qnanVar0x7ff8000020000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fb7ff8000020000000")}, + {nanConvertPreserveSignalOpt, hexDecode("fa7fc00001")}, + {nanConvertQuietOpt, hexDecode("fa7fc00001")}, + }}, + // float64 -qNaN dropped payload zero + {math.Float64frombits(qnanVar0xfffc000000000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fbfffc000000000000")}, + {nanConvertPreserveSignalOpt, hexDecode("f9ff00")}, + {nanConvertQuietOpt, hexDecode("f9ff00")}, + }}, + // float64 qNaN dropped payload zero + {math.Float64frombits(qnanVar0x7ffc000000000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fb7ffc000000000000")}, + {nanConvertPreserveSignalOpt, hexDecode("f97f00")}, + {nanConvertQuietOpt, hexDecode("f97f00")}, + }}, + // float64 -sNaN dropped payload not zero + {math.Float64frombits(snanVar0xfff0000000000001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fbfff0000000000001")}, + {nanConvertPreserveSignalOpt, hexDecode("fbfff0000000000001")}, + {nanConvertQuietOpt, hexDecode("fbfff8000000000001")}, + }}, + // float64 sNaN dropped payload not zero + {math.Float64frombits(snanVar0x7ff0000000000001), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fb7ff0000000000001")}, + {nanConvertPreserveSignalOpt, hexDecode("fb7ff0000000000001")}, + {nanConvertQuietOpt, hexDecode("fb7ff8000000000001")}, + }}, + // float64 -sNaN dropped payload zero + {math.Float64frombits(snanVar0xfff0000020000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fbfff0000020000000")}, + {nanConvertPreserveSignalOpt, hexDecode("faff800001")}, + {nanConvertQuietOpt, hexDecode("faffc00001")}, + }}, + // float64 sNaN dropped payload zero + {math.Float64frombits(snanVar0x7ff0000020000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fb7ff0000020000000")}, + {nanConvertPreserveSignalOpt, hexDecode("fa7f800001")}, + {nanConvertQuietOpt, hexDecode("fa7fc00001")}, + }}, + // float64 -sNaN dropped payload zero + {math.Float64frombits(snanVar0xfff4000000000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fbfff4000000000000")}, + {nanConvertPreserveSignalOpt, hexDecode("f9fd00")}, + {nanConvertQuietOpt, hexDecode("f9ff00")}, + }}, + // float64 sNaN dropped payload zero + {math.Float64frombits(snanVar0x7ff4000000000000), []nanConvert{ + {nanConvert7e00Opt, hexDecode("f97e00")}, + {nanConvertNoneOpt, hexDecode("fb7ff4000000000000")}, + {nanConvertPreserveSignalOpt, hexDecode("f97d00")}, + {nanConvertQuietOpt, hexDecode("f97f00")}, + }}, + } + for _, tc := range testCases { + for _, convert := range tc.convert { + var convertName string + switch convert.opt.NaNConvert { + case NaNConvert7e00: + convertName = "Convert7e00" + case NaNConvertNone: + convertName = "ConvertNone" + case NaNConvertPreserveSignal: + convertName = "ConvertPreserveSignal" + case NaNConvertQuiet: + convertName = "ConvertQuiet" + } + var vName string + switch v := tc.v.(type) { + case float32: + vName = fmt.Sprintf("0x%x", math.Float32bits(v)) + case float64: + vName = fmt.Sprintf("0x%x", math.Float64bits(v)) + } + name := convertName + "_" + vName + t.Run(name, func(t *testing.T) { + em, err := convert.opt.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + b, err := em.Marshal(tc.v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.v, err) + } else if !bytes.Equal(b, convert.wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.v, b, convert.wantCborData) + } + }) + } + } +} + +func TestInvalidNaNConvert(t *testing.T) { + wantErrorMsg := "cbor: invalid NaNConvertMode 100" + _, err := EncOptions{NaNConvert: NaNConvertMode(100)}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestMarshalSenML(t *testing.T) { + // Data from https://tools.ietf.org/html/rfc8428#section-6 + // Data contains 13 floating-point numbers. + cborData := hexDecode("87a721781b75726e3a6465763a6f773a3130653230373361303130383030363a22fb41d303a15b00106223614120050067766f6c7461676501615602fb405e066666666666a3006763757272656e74062402fb3ff3333333333333a3006763757272656e74062302fb3ff4cccccccccccda3006763757272656e74062202fb3ff6666666666666a3006763757272656e74062102f93e00a3006763757272656e74062002fb3ff999999999999aa3006763757272656e74060002fb3ffb333333333333") + testCases := []struct { + name string + opts EncOptions + }{ + {"EncOptions ShortestFloatNone", EncOptions{}}, + {"EncOptions ShortestFloat16", EncOptions{ShortestFloat: ShortestFloat16}}, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v []SenMLRecord + if err := Unmarshal(cborData, &v); err != nil { + t.Errorf("Marshal() returned error %v", err) + } + em, err := tc.opts.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Unmarshal() returned error %v ", err) + } + var v2 []SenMLRecord + if err := Unmarshal(b, &v2); err != nil { + t.Errorf("Marshal() returned error %v", err) + } + if !reflect.DeepEqual(v, v2) { + t.Errorf("SenML round-trip failed: v1 %+v, v2 %+v", v, v2) + } + }) + } +} + +func TestCanonicalEncOptions(t *testing.T) { //nolint:dupl + wantSortMode := SortCanonical + wantShortestFloat := ShortestFloat16 + wantNaNConvert := NaNConvert7e00 + wantInfConvert := InfConvertFloat16 + wantErrorMsg := "cbor: indefinite-length array isn't allowed" + em, err := CanonicalEncOptions().EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + opts := em.EncOptions() + if opts.Sort != wantSortMode { + t.Errorf("CanonicalEncOptions() returned EncOptions with Sort %d, want %d", opts.Sort, wantSortMode) + } + if opts.ShortestFloat != wantShortestFloat { + t.Errorf("CanonicalEncOptions() returned EncOptions with ShortestFloat %d, want %d", opts.ShortestFloat, wantShortestFloat) + } + if opts.NaNConvert != wantNaNConvert { + t.Errorf("CanonicalEncOptions() returned EncOptions with NaNConvert %d, want %d", opts.NaNConvert, wantNaNConvert) + } + if opts.InfConvert != wantInfConvert { + t.Errorf("CanonicalEncOptions() returned EncOptions with InfConvert %d, want %d", opts.InfConvert, wantInfConvert) + } + enc := em.NewEncoder(ioutil.Discard) + if err := enc.StartIndefiniteArray(); err == nil { + t.Errorf("StartIndefiniteArray() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("StartIndefiniteArray() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestCTAP2EncOptions(t *testing.T) { //nolint:dupl + wantSortMode := SortCTAP2 + wantShortestFloat := ShortestFloatNone + wantNaNConvert := NaNConvertNone + wantInfConvert := InfConvertNone + wantErrorMsg := "cbor: indefinite-length array isn't allowed" + em, err := CTAP2EncOptions().EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + opts := em.EncOptions() + if opts.Sort != wantSortMode { + t.Errorf("CTAP2EncOptions() returned EncOptions with Sort %d, want %d", opts.Sort, wantSortMode) + } + if opts.ShortestFloat != wantShortestFloat { + t.Errorf("CTAP2EncOptions() returned EncOptions with ShortestFloat %d, want %d", opts.ShortestFloat, wantShortestFloat) + } + if opts.NaNConvert != wantNaNConvert { + t.Errorf("CTAP2EncOptions() returned EncOptions with NaNConvert %d, want %d", opts.NaNConvert, wantNaNConvert) + } + if opts.InfConvert != wantInfConvert { + t.Errorf("CTAP2EncOptions() returned EncOptions with InfConvert %d, want %d", opts.InfConvert, wantInfConvert) + } + enc := em.NewEncoder(ioutil.Discard) + if err := enc.StartIndefiniteArray(); err == nil { + t.Errorf("StartIndefiniteArray() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("StartIndefiniteArray() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestCoreDetEncOptions(t *testing.T) { //nolint:dupl + wantSortMode := SortCoreDeterministic + wantShortestFloat := ShortestFloat16 + wantNaNConvert := NaNConvert7e00 + wantInfConvert := InfConvertFloat16 + wantErrorMsg := "cbor: indefinite-length array isn't allowed" + em, err := CoreDetEncOptions().EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + opts := em.EncOptions() + if opts.Sort != wantSortMode { + t.Errorf("CoreDetEncOptions() returned EncOptions with Sort %d, want %d", opts.Sort, wantSortMode) + } + if opts.ShortestFloat != wantShortestFloat { + t.Errorf("CoreDetEncOptions() returned EncOptions with ShortestFloat %d, want %d", opts.ShortestFloat, wantShortestFloat) + } + if opts.NaNConvert != wantNaNConvert { + t.Errorf("CoreDetEncOptions() returned EncOptions with NaNConvert %d, want %d", opts.NaNConvert, wantNaNConvert) + } + if opts.InfConvert != wantInfConvert { + t.Errorf("CoreDetEncOptions() returned EncOptions with InfConvert %d, want %d", opts.InfConvert, wantInfConvert) + } + enc := em.NewEncoder(ioutil.Discard) + if err := enc.StartIndefiniteArray(); err == nil { + t.Errorf("StartIndefiniteArray() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("StartIndefiniteArray() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestPreferredUnsortedEncOptions(t *testing.T) { + wantSortMode := SortNone + wantShortestFloat := ShortestFloat16 + wantNaNConvert := NaNConvert7e00 + wantInfConvert := InfConvertFloat16 + em, err := PreferredUnsortedEncOptions().EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + opts := em.EncOptions() + if opts.Sort != wantSortMode { + t.Errorf("PreferredUnsortedEncOptions() returned EncOptions with Sort %d, want %d", opts.Sort, wantSortMode) + } + if opts.ShortestFloat != wantShortestFloat { + t.Errorf("PreferredUnsortedEncOptions() returned EncOptions with ShortestFloat %d, want %d", opts.ShortestFloat, wantShortestFloat) + } + if opts.NaNConvert != wantNaNConvert { + t.Errorf("PreferredUnsortedEncOptions() returned EncOptions with NaNConvert %d, want %d", opts.NaNConvert, wantNaNConvert) + } + if opts.InfConvert != wantInfConvert { + t.Errorf("PreferredUnsortedEncOptions() returned EncOptions with InfConvert %d, want %d", opts.InfConvert, wantInfConvert) + } + enc := em.NewEncoder(ioutil.Discard) + if err := enc.StartIndefiniteArray(); err != nil { + t.Errorf("StartIndefiniteArray() returned error %v", err) + } +} + +func TestEncModeInvalidIndefiniteLengthMode(t *testing.T) { + wantErrorMsg := "cbor: invalid IndefLength 101" + _, err := EncOptions{IndefLength: 101}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestEncModeInvalidTagsMode(t *testing.T) { + wantErrorMsg := "cbor: invalid TagsMd 101" + _, err := EncOptions{TagsMd: 101}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestEncModeInvalidBigIntConvertMode(t *testing.T) { + wantErrorMsg := "cbor: invalid BigIntConvertMode 101" + _, err := EncOptions{BigIntConvert: 101}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestEncOptions(t *testing.T) { + opts1 := EncOptions{ + Sort: SortBytewiseLexical, + ShortestFloat: ShortestFloat16, + NaNConvert: NaNConvertPreserveSignal, + InfConvert: InfConvertNone, + BigIntConvert: BigIntConvertNone, + Time: TimeRFC3339Nano, + TimeTag: EncTagRequired, + IndefLength: IndefLengthForbidden, + TagsMd: TagsAllowed, + } + em, err := opts1.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } else { + opts2 := em.EncOptions() + if !reflect.DeepEqual(opts1, opts2) { + t.Errorf("EncOptions->EncMode->EncOptions returned different values: %v, %v", opts1, opts2) + } + } +} + +func TestEncModeInvalidTimeTag(t *testing.T) { + wantErrorMsg := "cbor: invalid TimeTag 100" + _, err := EncOptions{TimeTag: 100}.EncMode() + if err == nil { + t.Errorf("EncMode() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncMode() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestEncIndefiniteLengthOption(t *testing.T) { + // Default option allows indefinite length items + var buf bytes.Buffer + enc := NewEncoder(&buf) + if err := enc.StartIndefiniteByteString(); err != nil { + t.Errorf("StartIndefiniteByteString() returned an error %v", err) + } + if err := enc.StartIndefiniteTextString(); err != nil { + t.Errorf("StartIndefiniteTextString() returned an error %v", err) + } + if err := enc.StartIndefiniteArray(); err != nil { + t.Errorf("StartIndefiniteArray() returned an error %v", err) + } + if err := enc.StartIndefiniteMap(); err != nil { + t.Errorf("StartIndefiniteMap() returned an error %v", err) + } + + // StartIndefiniteXXX returns error when IndefLength = IndefLengthForbidden + em, _ := EncOptions{IndefLength: IndefLengthForbidden}.EncMode() + enc = em.NewEncoder(&buf) + wantErrorMsg := "cbor: indefinite-length byte string isn't allowed" + if err := enc.StartIndefiniteByteString(); err == nil { + t.Errorf("StartIndefiniteByteString() didn't return an error") + } else if _, ok := err.(*IndefiniteLengthError); !ok { + t.Errorf("StartIndefiniteByteString() error type %T, want *IndefiniteLengthError", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("StartIndefiniteByteString() returned error %q, want %q", err.Error(), wantErrorMsg) + } + + wantErrorMsg = "cbor: indefinite-length UTF-8 text string isn't allowed" + if err := enc.StartIndefiniteTextString(); err == nil { + t.Errorf("StartIndefiniteTextString() didn't return an error") + } else if _, ok := err.(*IndefiniteLengthError); !ok { + t.Errorf("StartIndefiniteTextString() error type %T, want *IndefiniteLengthError", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("StartIndefiniteTextString() returned error %q, want %q", err.Error(), wantErrorMsg) + } + + wantErrorMsg = "cbor: indefinite-length array isn't allowed" + if err := enc.StartIndefiniteArray(); err == nil { + t.Errorf("StartIndefiniteArray() didn't return an error") + } else if _, ok := err.(*IndefiniteLengthError); !ok { + t.Errorf("StartIndefiniteArray() error type %T, want *IndefiniteLengthError", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("StartIndefiniteArray() returned error %q, want %q", err.Error(), wantErrorMsg) + } + + wantErrorMsg = "cbor: indefinite-length map isn't allowed" + if err := enc.StartIndefiniteMap(); err == nil { + t.Errorf("StartIndefiniteMap() didn't return an error") + } else if _, ok := err.(*IndefiniteLengthError); !ok { + t.Errorf("StartIndefiniteMap() error type %T, want *IndefiniteLengthError", err) + } else if err.Error() != wantErrorMsg { + t.Errorf("StartIndefiniteMap() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestEncTagsMdOption(t *testing.T) { + // Default option allows encoding CBOR tags + tag := Tag{123, "hello"} + if _, err := Marshal(tag); err != nil { + t.Errorf("Marshal() returned an error %v", err) + } + + // Create EncMode with TimeTag = EncTagRequired and TagsForbidden option returns error + wantErrorMsg := "cbor: cannot set TagsMd to TagsForbidden when TimeTag is EncTagRequired" + _, err := EncOptions{TimeTag: EncTagRequired, TagsMd: TagsForbidden}.EncMode() + if err == nil { + t.Errorf("EncModeWithTags() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncModeWithTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } + + // Create EncMode with TagSet and TagsForbidden option returns error + wantErrorMsg = "cbor: cannot create EncMode with TagSet when TagsMd is TagsForbidden" + tags := NewTagSet() + _, err = EncOptions{TagsMd: TagsForbidden}.EncModeWithTags(tags) + if err == nil { + t.Errorf("EncModeWithTags() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncModeWithTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } + _, err = EncOptions{TagsMd: TagsForbidden}.EncModeWithSharedTags(tags) + if err == nil { + t.Errorf("EncModeWithSharedTags() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("EncModeWithSharedTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } + + // Encoding Tag and TagsForbidden option returns error + wantErrorMsg = "cbor: cannot encode cbor.Tag when TagsMd is TagsForbidden" + em, _ := EncOptions{TagsMd: TagsForbidden}.EncMode() + if _, err := em.Marshal(&tag); err == nil { + t.Errorf("Marshal() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("Marshal() returned error %q, want %q", err.Error(), wantErrorMsg) + } + + // Encoding RawTag and TagsForbidden option returns error + wantErrorMsg = "cbor: cannot encode cbor.RawTag when TagsMd is TagsForbidden" + rawTag := RawTag{123, []byte{01}} + if _, err := em.Marshal(&rawTag); err == nil { + t.Errorf("Marshal() didn't return an error") + } else if err.Error() != wantErrorMsg { + t.Errorf("Marshal() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestMarshalPosBigInt(t *testing.T) { + testCases := []struct { + name string + cborDataShortest []byte + cborDataBigInt []byte + value big.Int + }{ + { + name: "fit uint8", + cborDataShortest: hexDecode("00"), + cborDataBigInt: hexDecode("c240"), + value: bigIntOrPanic("0"), + }, + { + name: "fit uint16", + cborDataShortest: hexDecode("1903e8"), + cborDataBigInt: hexDecode("c24203e8"), + value: bigIntOrPanic("1000"), + }, + { + name: "fit uint32", + cborDataShortest: hexDecode("1a000f4240"), + cborDataBigInt: hexDecode("c2430f4240"), + value: bigIntOrPanic("1000000"), + }, + { + name: "fit uint64", + cborDataShortest: hexDecode("1b000000e8d4a51000"), + cborDataBigInt: hexDecode("c245e8d4a51000"), + value: bigIntOrPanic("1000000000000"), + }, + { + name: "max uint64", + cborDataShortest: hexDecode("1bffffffffffffffff"), + cborDataBigInt: hexDecode("c248ffffffffffffffff"), + value: bigIntOrPanic("18446744073709551615"), + }, + { + name: "overflow uint64", + cborDataShortest: hexDecode("c249010000000000000000"), + cborDataBigInt: hexDecode("c249010000000000000000"), + value: bigIntOrPanic("18446744073709551616"), + }, + } + + dmShortest, err := EncOptions{}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + dmBigInt, err := EncOptions{BigIntConvert: BigIntConvertNone}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + if b, err := dmShortest.Marshal(tc.value); err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.value, err) + } else if !bytes.Equal(b, tc.cborDataShortest) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.value, b, tc.cborDataShortest) + } + + if b, err := dmBigInt.Marshal(tc.value); err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.value, err) + } else if !bytes.Equal(b, tc.cborDataBigInt) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.value, b, tc.cborDataBigInt) + } + }) + } +} + +func TestMarshalNegBigInt(t *testing.T) { + testCases := []struct { + name string + cborDataShortest []byte + cborDataBigInt []byte + value big.Int + }{ + { + name: "fit int8", + cborDataShortest: hexDecode("20"), + cborDataBigInt: hexDecode("c340"), + value: bigIntOrPanic("-1"), + }, + { + name: "fit int16", + cborDataShortest: hexDecode("3903e7"), + cborDataBigInt: hexDecode("c34203e7"), + value: bigIntOrPanic("-1000"), + }, + { + name: "fit int32", + cborDataShortest: hexDecode("3a000f423f"), + cborDataBigInt: hexDecode("c3430f423f"), + value: bigIntOrPanic("-1000000"), + }, + { + name: "fit int64", + cborDataShortest: hexDecode("3b000000e8d4a50fff"), + cborDataBigInt: hexDecode("c345e8d4a50fff"), + value: bigIntOrPanic("-1000000000000"), + }, + { + name: "min int64", + cborDataShortest: hexDecode("3b7fffffffffffffff"), + cborDataBigInt: hexDecode("c3487fffffffffffffff"), + value: bigIntOrPanic("-9223372036854775808"), + }, + { + name: "overflow Go int64 fit CBOR neg int", + cborDataShortest: hexDecode("3b8000000000000000"), + cborDataBigInt: hexDecode("c3488000000000000000"), + value: bigIntOrPanic("-9223372036854775809"), + }, + { + name: "min CBOR neg int", + cborDataShortest: hexDecode("3bffffffffffffffff"), + cborDataBigInt: hexDecode("c348ffffffffffffffff"), + value: bigIntOrPanic("-18446744073709551616"), + }, + { + name: "overflow CBOR neg int", + cborDataShortest: hexDecode("c349010000000000000000"), + cborDataBigInt: hexDecode("c349010000000000000000"), + value: bigIntOrPanic("-18446744073709551617"), + }, + } + + dmShortest, err := EncOptions{}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + dmBigInt, err := EncOptions{BigIntConvert: BigIntConvertNone}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + if b, err := dmShortest.Marshal(tc.value); err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.value, err) + } else if !bytes.Equal(b, tc.cborDataShortest) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.value, b, tc.cborDataShortest) + } + + if b, err := dmBigInt.Marshal(tc.value); err != nil { + t.Errorf("Marshal(%v) returned error %v", tc.value, err) + } else if !bytes.Equal(b, tc.cborDataBigInt) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", tc.value, b, tc.cborDataBigInt) + } + }) + } +} diff --git a/vendor/github.com/fxamacker/cbor/example_test.go b/vendor/github.com/fxamacker/cbor/example_test.go new file mode 100644 index 0000000..3c46ffc --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/example_test.go @@ -0,0 +1,571 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor_test + +import ( + "bytes" + "encoding/hex" + "fmt" + "io" + "reflect" + "time" + + "github.com/fxamacker/cbor/v2" // remove "/v2" suffix if you're not using Go modules (see README.md) +) + +func ExampleMarshal() { + type Animal struct { + Age int + Name string + Owners []string + Male bool + } + animal := Animal{Age: 4, Name: "Candy", Owners: []string{"Mary", "Joe"}} + b, err := cbor.Marshal(animal) + if err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", b) + // Output: + // a46341676504644e616d656543616e6479664f776e65727382644d617279634a6f65644d616c65f4 +} + +func ExampleMarshal_time() { + tm, _ := time.Parse(time.RFC3339, "2013-03-21T20:04:00Z") + + // Encode time as string in RFC3339 format with second precision. + em, err := cbor.EncOptions{Time: cbor.TimeRFC3339}.EncMode() + if err != nil { + fmt.Println("error:", err) + } + b, err := em.Marshal(tm) + if err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", b) + + // Encode time as numerical representation of seconds since January 1, 1970 UTC. + em, err = cbor.EncOptions{Time: cbor.TimeUnix}.EncMode() + if err != nil { + fmt.Println("error:", err) + } + b, err = em.Marshal(tm) + if err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", b) + // Output: + // 74323031332d30332d32315432303a30343a30305a + // 1a514b67b0 +} + +// This example uses Marshal to encode struct and map in canonical form. +func ExampleMarshal_canonical() { + type Animal struct { + Age int + Name string + Contacts map[string]string + Male bool + } + animal := Animal{Age: 4, Name: "Candy", Contacts: map[string]string{"Mary": "111-111-1111", "Joe": "222-222-2222"}} + em, err := cbor.CanonicalEncOptions().EncMode() + if err != nil { + fmt.Println("error:", err) + } + b, err := em.Marshal(animal) + if err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", b) + // Output: + // a46341676504644d616c65f4644e616d656543616e647968436f6e7461637473a2634a6f656c3232322d3232322d32323232644d6172796c3131312d3131312d31313131 +} + +// This example uses "toarray" struct tag to encode struct as CBOR array. +func ExampleMarshal_toarray() { + type Record struct { + _ struct{} `cbor:",toarray"` + Name string + Unit string + Measurement int + } + rec := Record{Name: "current", Unit: "V", Measurement: 1} + b, err := cbor.Marshal(rec) + if err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", b) + // Output: + // 836763757272656e74615601 +} + +// This example uses "keyasint" struct tag to encode struct's fiele names as integer. +// This feautre is very useful in handling COSE, CWT, SenML data. +func ExampleMarshal_keyasint() { + type Record struct { + Name string `cbor:"1,keyasint"` + Unit string `cbor:"2,keyasint"` + Measurement int `cbor:"3,keyasint"` + } + rec := Record{Name: "current", Unit: "V", Measurement: 1} + b, err := cbor.Marshal(rec) + if err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", b) + // Output: + // a3016763757272656e740261560301 +} + +func ExampleUnmarshal() { + type Animal struct { + Age int + Name string + Owners []string + Male bool + } + cborData, _ := hex.DecodeString("a46341676504644e616d656543616e6479664f776e65727382644d617279634a6f65644d616c65f4") + var animal Animal + err := cbor.Unmarshal(cborData, &animal) + if err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v", animal) + // Output: + // {Age:4 Name:Candy Owners:[Mary Joe] Male:false} +} + +func ExampleUnmarshal_time() { + cborRFC3339Time, _ := hex.DecodeString("74323031332d30332d32315432303a30343a30305a") + tm := time.Time{} + if err := cbor.Unmarshal(cborRFC3339Time, &tm); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v\n", tm.UTC().Format(time.RFC3339Nano)) + cborUnixTime, _ := hex.DecodeString("1a514b67b0") + tm = time.Time{} + if err := cbor.Unmarshal(cborUnixTime, &tm); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v\n", tm.UTC().Format(time.RFC3339Nano)) + // Output: + // 2013-03-21T20:04:00Z + // 2013-03-21T20:04:00Z +} + +func ExampleEncoder() { + type Animal struct { + Age int + Name string + Owners []string + Male bool + } + animals := []Animal{ + {Age: 4, Name: "Candy", Owners: []string{"Mary", "Joe"}, Male: false}, + {Age: 6, Name: "Rudy", Owners: []string{"Cindy"}, Male: true}, + {Age: 2, Name: "Duke", Owners: []string{"Norton"}, Male: true}, + } + var buf bytes.Buffer + em, err := cbor.CanonicalEncOptions().EncMode() + if err != nil { + fmt.Println("error:", err) + } + enc := em.NewEncoder(&buf) + for _, animal := range animals { + err := enc.Encode(animal) + if err != nil { + fmt.Println("error:", err) + } + } + fmt.Printf("%x\n", buf.Bytes()) + // Output: + // a46341676504644d616c65f4644e616d656543616e6479664f776e65727382644d617279634a6f65a46341676506644d616c65f5644e616d656452756479664f776e657273816543696e6479a46341676502644d616c65f5644e616d656444756b65664f776e65727381664e6f72746f6e +} + +// ExampleEncoder_indefiniteLengthByteString encodes a stream of definite +// length byte string ("chunks") as an indefinite length byte string. +func ExampleEncoder_indefiniteLengthByteString() { + var buf bytes.Buffer + encoder := cbor.NewEncoder(&buf) + // Start indefinite length byte string encoding. + if err := encoder.StartIndefiniteByteString(); err != nil { + fmt.Println("error:", err) + } + // Encode definite length byte string. + if err := encoder.Encode([]byte{1, 2}); err != nil { + fmt.Println("error:", err) + } + // Encode definite length byte string. + if err := encoder.Encode([3]byte{3, 4, 5}); err != nil { + fmt.Println("error:", err) + } + // Close indefinite length byte string. + if err := encoder.EndIndefinite(); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", buf.Bytes()) + // Output: + // 5f42010243030405ff +} + +// ExampleEncoder_indefiniteLengthTextString encodes a stream of definite +// length text string ("chunks") as an indefinite length text string. +func ExampleEncoder_indefiniteLengthTextString() { + var buf bytes.Buffer + encoder := cbor.NewEncoder(&buf) + // Start indefinite length text string encoding. + if err := encoder.StartIndefiniteTextString(); err != nil { + fmt.Println("error:", err) + } + // Encode definite length text string. + if err := encoder.Encode("strea"); err != nil { + fmt.Println("error:", err) + } + // Encode definite length text string. + if err := encoder.Encode("ming"); err != nil { + fmt.Println("error:", err) + } + // Close indefinite length text string. + if err := encoder.EndIndefinite(); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", buf.Bytes()) + // Output: + // 7f657374726561646d696e67ff +} + +// ExampleEncoder_indefiniteLengthArray encodes a stream of elements as an +// indefinite length array. Encoder supports nested indefinite length values. +func ExampleEncoder_indefiniteLengthArray() { + var buf bytes.Buffer + enc := cbor.NewEncoder(&buf) + // Start indefinite length array encoding. + if err := enc.StartIndefiniteArray(); err != nil { + fmt.Println("error:", err) + } + // Encode array element. + if err := enc.Encode(1); err != nil { + fmt.Println("error:", err) + } + // Encode array element. + if err := enc.Encode([]int{2, 3}); err != nil { + fmt.Println("error:", err) + } + // Start a nested indefinite length array as array element. + if err := enc.StartIndefiniteArray(); err != nil { + fmt.Println("error:", err) + } + // Encode nested array element. + if err := enc.Encode(4); err != nil { + fmt.Println("error:", err) + } + // Encode nested array element. + if err := enc.Encode(5); err != nil { + fmt.Println("error:", err) + } + // Close nested indefinite length array. + if err := enc.EndIndefinite(); err != nil { + fmt.Println("error:", err) + } + // Close outer indefinite length array. + if err := enc.EndIndefinite(); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", buf.Bytes()) + // Output: + // 9f018202039f0405ffff +} + +// ExampleEncoder_indefiniteLengthMap encodes a stream of elements as an +// indefinite length map. Encoder supports nested indefinite length values. +func ExampleEncoder_indefiniteLengthMap() { + var buf bytes.Buffer + em, err := cbor.EncOptions{Sort: cbor.SortCanonical}.EncMode() + if err != nil { + fmt.Println("error:", err) + } + enc := em.NewEncoder(&buf) + // Start indefinite length map encoding. + if err := enc.StartIndefiniteMap(); err != nil { + fmt.Println("error:", err) + } + // Encode map key. + if err := enc.Encode("a"); err != nil { + fmt.Println("error:", err) + } + // Encode map value. + if err := enc.Encode(1); err != nil { + fmt.Println("error:", err) + } + // Encode map key. + if err := enc.Encode("b"); err != nil { + fmt.Println("error:", err) + } + // Start an indefinite length array as map value. + if err := enc.StartIndefiniteArray(); err != nil { + fmt.Println("error:", err) + } + // Encoded array element. + if err := enc.Encode(2); err != nil { + fmt.Println("error:", err) + } + // Encoded array element. + if err := enc.Encode(3); err != nil { + fmt.Println("error:", err) + } + // Close indefinite length array. + if err := enc.EndIndefinite(); err != nil { + fmt.Println("error:", err) + } + // Close indefinite length map. + if err := enc.EndIndefinite(); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%x\n", buf.Bytes()) + // Output: + // bf61610161629f0203ffff +} + +func ExampleDecoder() { + type Animal struct { + Age int + Name string + Owners []string + Male bool + } + cborData, _ := hex.DecodeString("a46341676504644d616c65f4644e616d656543616e6479664f776e65727382644d617279634a6f65a46341676506644d616c65f5644e616d656452756479664f776e657273816543696e6479a46341676502644d616c65f5644e616d656444756b65664f776e65727381664e6f72746f6e") + dec := cbor.NewDecoder(bytes.NewReader(cborData)) + for { + var animal Animal + if err := dec.Decode(&animal); err != nil { + if err != io.EOF { + fmt.Println("error:", err) + } + break + } + fmt.Printf("%+v\n", animal) + } + // Output: + // {Age:4 Name:Candy Owners:[Mary Joe] Male:false} + // {Age:6 Name:Rudy Owners:[Cindy] Male:true} + // {Age:2 Name:Duke Owners:[Norton] Male:true} +} + +func Example_cWT() { + // Use "keyasint" struct tag to encode/decode struct to/from CBOR map. + type claims struct { + Iss string `cbor:"1,keyasint"` + Sub string `cbor:"2,keyasint"` + Aud string `cbor:"3,keyasint"` + Exp int `cbor:"4,keyasint"` + Nbf int `cbor:"5,keyasint"` + Iat int `cbor:"6,keyasint"` + Cti []byte `cbor:"7,keyasint"` + } + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.1 + cborData, _ := hex.DecodeString("a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b71") + var v claims + if err := cbor.Unmarshal(cborData, &v); err != nil { + fmt.Println("error:", err) + } + if _, err := cbor.Marshal(v); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v", v) + // Output: + // {Iss:coap://as.example.com Sub:erikw Aud:coap://light.example.com Exp:1444064944 Nbf:1443944944 Iat:1443944944 Cti:[11 113]} +} + +func Example_cWTWithDupMapKeyOption() { + type claims struct { + Iss string `cbor:"1,keyasint"` + Sub string `cbor:"2,keyasint"` + Aud string `cbor:"3,keyasint"` + Exp int `cbor:"4,keyasint"` + Nbf int `cbor:"5,keyasint"` + Iat int `cbor:"6,keyasint"` + Cti []byte `cbor:"7,keyasint"` + } + + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.1 + cborData, _ := hex.DecodeString("a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b71") + + dm, _ := cbor.DecOptions{DupMapKey: cbor.DupMapKeyEnforcedAPF}.DecMode() + + var v claims + if err := dm.Unmarshal(cborData, &v); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v", v) + // Output: + // {Iss:coap://as.example.com Sub:erikw Aud:coap://light.example.com Exp:1444064944 Nbf:1443944944 Iat:1443944944 Cti:[11 113]} +} + +func Example_signedCWT() { + // Use "keyasint" struct tag to encode/decode struct to/from CBOR map. + // Partial COSE header definition + type coseHeader struct { + Alg int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` + } + // Use "toarray" struct tag to encode/decode struct to/from CBOR array. + type signedCWT struct { + _ struct{} `cbor:",toarray"` + Protected []byte + Unprotected coseHeader + Payload []byte + Signature []byte + } + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.3 + cborData, _ := hex.DecodeString("d28443a10126a104524173796d6d657472696345434453413235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7158405427c1ff28d23fbad1f29c4c7c6a555e601d6fa29f9179bc3d7438bacaca5acd08c8d4d4f96131680c429a01f85951ecee743a52b9b63632c57209120e1c9e30") + var v signedCWT + if err := cbor.Unmarshal(cborData, &v); err != nil { + fmt.Println("error:", err) + } + if _, err := cbor.Marshal(v); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v", v) + // Output: + // {_:{} Protected:[161 1 38] Unprotected:{Alg:0 Kid:[65 115 121 109 109 101 116 114 105 99 69 67 68 83 65 50 53 54] IV:[]} Payload:[167 1 117 99 111 97 112 58 47 47 97 115 46 101 120 97 109 112 108 101 46 99 111 109 2 101 101 114 105 107 119 3 120 24 99 111 97 112 58 47 47 108 105 103 104 116 46 101 120 97 109 112 108 101 46 99 111 109 4 26 86 18 174 176 5 26 86 16 217 240 6 26 86 16 217 240 7 66 11 113] Signature:[84 39 193 255 40 210 63 186 209 242 156 76 124 106 85 94 96 29 111 162 159 145 121 188 61 116 56 186 202 202 90 205 8 200 212 212 249 97 49 104 12 66 154 1 248 89 81 236 238 116 58 82 185 182 54 50 197 114 9 18 14 28 158 48]} +} + +func Example_signedCWTWithTag() { + // Use "keyasint" struct tag to encode/decode struct to/from CBOR map. + // Partial COSE header definition + type coseHeader struct { + Alg int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` + } + // Use "toarray" struct tag to encode/decode struct to/from CBOR array. + type signedCWT struct { + _ struct{} `cbor:",toarray"` + Protected []byte + Unprotected coseHeader + Payload []byte + Signature []byte + } + + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.3 + cborData, _ := hex.DecodeString("d28443a10126a104524173796d6d657472696345434453413235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7158405427c1ff28d23fbad1f29c4c7c6a555e601d6fa29f9179bc3d7438bacaca5acd08c8d4d4f96131680c429a01f85951ecee743a52b9b63632c57209120e1c9e30") + + // Register tag COSE_Sign1 18 with signedCWT type. + tags := cbor.NewTagSet() + if err := tags.Add( + cbor.TagOptions{EncTag: cbor.EncTagRequired, DecTag: cbor.DecTagRequired}, + reflect.TypeOf(signedCWT{}), + 18); err != nil { + fmt.Println("error:", err) + } + + dm, _ := cbor.DecOptions{}.DecModeWithTags(tags) + em, _ := cbor.EncOptions{}.EncModeWithTags(tags) + + var v signedCWT + if err := dm.Unmarshal(cborData, &v); err != nil { + fmt.Println("error:", err) + } + + if _, err := em.Marshal(v); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v", v) + // Output: + // {_:{} Protected:[161 1 38] Unprotected:{Alg:0 Kid:[65 115 121 109 109 101 116 114 105 99 69 67 68 83 65 50 53 54] IV:[]} Payload:[167 1 117 99 111 97 112 58 47 47 97 115 46 101 120 97 109 112 108 101 46 99 111 109 2 101 101 114 105 107 119 3 120 24 99 111 97 112 58 47 47 108 105 103 104 116 46 101 120 97 109 112 108 101 46 99 111 109 4 26 86 18 174 176 5 26 86 16 217 240 6 26 86 16 217 240 7 66 11 113] Signature:[84 39 193 255 40 210 63 186 209 242 156 76 124 106 85 94 96 29 111 162 159 145 121 188 61 116 56 186 202 202 90 205 8 200 212 212 249 97 49 104 12 66 154 1 248 89 81 236 238 116 58 82 185 182 54 50 197 114 9 18 14 28 158 48]} +} + +func Example_cOSE() { + // Use "keyasint" struct tag to encode/decode struct to/from CBOR map. + // Use cbor.RawMessage to delay unmarshaling (CrvOrNOrK's data type depends on Kty's value). + type coseKey struct { + Kty int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"2,keyasint,omitempty"` + Alg int `cbor:"3,keyasint,omitempty"` + KeyOpts int `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` + CrvOrNOrK cbor.RawMessage `cbor:"-1,keyasint,omitempty"` // K for symmetric keys, Crv for elliptic curve keys, N for RSA modulus + XOrE cbor.RawMessage `cbor:"-2,keyasint,omitempty"` // X for curve x-coordinate, E for RSA public exponent + Y cbor.RawMessage `cbor:"-3,keyasint,omitempty"` // Y for curve y-cooridate + D []byte `cbor:"-4,keyasint,omitempty"` + } + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.2 + // 128-Bit Symmetric Key + cborData, _ := hex.DecodeString("a42050231f4c4d4d3051fdc2ec0a3851d5b3830104024c53796d6d6574726963313238030a") + var v coseKey + if err := cbor.Unmarshal(cborData, &v); err != nil { + fmt.Println("error:", err) + } + if _, err := cbor.Marshal(v); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v", v) + // Output: + // {Kty:4 Kid:[83 121 109 109 101 116 114 105 99 49 50 56] Alg:10 KeyOpts:0 IV:[] CrvOrNOrK:[80 35 31 76 77 77 48 81 253 194 236 10 56 81 213 179 131] XOrE:[] Y:[] D:[]} +} + +func Example_senML() { + // Use "keyasint" struct tag to encode/decode struct to/from CBOR map. + type SenMLRecord struct { + BaseName string `cbor:"-2,keyasint,omitempty"` + BaseTime float64 `cbor:"-3,keyasint,omitempty"` + BaseUnit string `cbor:"-4,keyasint,omitempty"` + BaseValue float64 `cbor:"-5,keyasint,omitempty"` + BaseSum float64 `cbor:"-6,keyasint,omitempty"` + BaseVersion int `cbor:"-1,keyasint,omitempty"` + Name string `cbor:"0,keyasint,omitempty"` + Unit string `cbor:"1,keyasint,omitempty"` + Time float64 `cbor:"6,keyasint,omitempty"` + UpdateTime float64 `cbor:"7,keyasint,omitempty"` + Value float64 `cbor:"2,keyasint,omitempty"` + ValueS string `cbor:"3,keyasint,omitempty"` + ValueB bool `cbor:"4,keyasint,omitempty"` + ValueD string `cbor:"8,keyasint,omitempty"` + Sum float64 `cbor:"5,keyasint,omitempty"` + } + // Data from https://tools.ietf.org/html/rfc8428#section-6 + cborData, _ := hex.DecodeString("87a721781b75726e3a6465763a6f773a3130653230373361303130383030363a22fb41d303a15b00106223614120050067766f6c7461676501615602fb405e066666666666a3006763757272656e74062402fb3ff3333333333333a3006763757272656e74062302fb3ff4cccccccccccda3006763757272656e74062202fb3ff6666666666666a3006763757272656e74062102f93e00a3006763757272656e74062002fb3ff999999999999aa3006763757272656e74060002fb3ffb333333333333") + var v []*SenMLRecord + if err := cbor.Unmarshal(cborData, &v); err != nil { + fmt.Println("error:", err) + } + // Encoder uses ShortestFloat16 option to use float16 as the shortest form that preserves floating-point value. + em, err := cbor.EncOptions{ShortestFloat: cbor.ShortestFloat16}.EncMode() + if err != nil { + fmt.Println("error:", err) + } + if _, err := em.Marshal(v); err != nil { + fmt.Println("error:", err) + } + for _, rec := range v { + fmt.Printf("%+v\n", *rec) + } + // Output: + // {BaseName:urn:dev:ow:10e2073a0108006: BaseTime:1.276020076001e+09 BaseUnit:A BaseValue:0 BaseSum:0 BaseVersion:5 Name:voltage Unit:V Time:0 UpdateTime:0 Value:120.1 ValueS: ValueB:false ValueD: Sum:0} + // {BaseName: BaseTime:0 BaseUnit: BaseValue:0 BaseSum:0 BaseVersion:0 Name:current Unit: Time:-5 UpdateTime:0 Value:1.2 ValueS: ValueB:false ValueD: Sum:0} + // {BaseName: BaseTime:0 BaseUnit: BaseValue:0 BaseSum:0 BaseVersion:0 Name:current Unit: Time:-4 UpdateTime:0 Value:1.3 ValueS: ValueB:false ValueD: Sum:0} + // {BaseName: BaseTime:0 BaseUnit: BaseValue:0 BaseSum:0 BaseVersion:0 Name:current Unit: Time:-3 UpdateTime:0 Value:1.4 ValueS: ValueB:false ValueD: Sum:0} + // {BaseName: BaseTime:0 BaseUnit: BaseValue:0 BaseSum:0 BaseVersion:0 Name:current Unit: Time:-2 UpdateTime:0 Value:1.5 ValueS: ValueB:false ValueD: Sum:0} + // {BaseName: BaseTime:0 BaseUnit: BaseValue:0 BaseSum:0 BaseVersion:0 Name:current Unit: Time:-1 UpdateTime:0 Value:1.6 ValueS: ValueB:false ValueD: Sum:0} + // {BaseName: BaseTime:0 BaseUnit: BaseValue:0 BaseSum:0 BaseVersion:0 Name:current Unit: Time:0 UpdateTime:0 Value:1.7 ValueS: ValueB:false ValueD: Sum:0} +} + +func Example_webAuthn() { + // Use cbor.RawMessage to delay unmarshaling (AttStmt's data type depends on Fmt's value). + type attestationObject struct { + AuthnData []byte `cbor:"authData"` + Fmt string `cbor:"fmt"` + AttStmt cbor.RawMessage `cbor:"attStmt"` + } + cborData, _ := hex.DecodeString("a363666d74686669646f2d7532666761747453746d74a26373696758483046022100e7ab373cfbd99fcd55fd59b0f6f17fef5b77a20ddec3db7f7e4d55174e366236022100828336b4822125fb56541fb14a8a273876acd339395ec2dad95cf41c1dd2a9ae637835638159024e3082024a30820132a0030201020204124a72fe300d06092a864886f70d01010b0500302e312c302a0603550403132359756269636f2055324620526f6f742043412053657269616c203435373230303633313020170d3134303830313030303030305a180f32303530303930343030303030305a302c312a302806035504030c2159756269636f205532462045452053657269616c203234393431343937323135383059301306072a8648ce3d020106082a8648ce3d030107034200043d8b1bbd2fcbf6086e107471601468484153c1c6d3b4b68a5e855e6e40757ee22bcd8988bf3befd7cdf21cb0bf5d7a150d844afe98103c6c6607d9faae287c02a33b3039302206092b0601040182c40a020415312e332e362e312e342e312e34313438322e312e313013060b2b0601040182e51c020101040403020520300d06092a864886f70d01010b05000382010100a14f1eea0076f6b8476a10a2be72e60d0271bb465b2dfbfc7c1bd12d351989917032631d795d097fa30a26a325634e85721bc2d01a86303f6bc075e5997319e122148b0496eec8d1f4f94cf4110de626c289443d1f0f5bbb239ca13e81d1d5aa9df5af8e36126475bfc23af06283157252762ff68879bcf0ef578d55d67f951b4f32b63c8aea5b0f99c67d7d814a7ff5a6f52df83e894a3a5d9c8b82e7f8bc8daf4c80175ff8972fda79333ec465d806eacc948f1bab22045a95558a48c20226dac003d41fbc9e05ea28a6bb5e10a49de060a0a4f6a2676a34d68c4abe8c61874355b9027e828ca9e064b002d62e8d8cf0744921753d35e3c87c5d5779453e7768617574684461746158c449960de5880e8c687434170f6476605b8fe4aeb9a28632c7995cf3ba831d976341000000000000000000000000000000000000000000408903fd7dfd2c9770e98cae0123b13a2c27828a106349bc6277140e7290b7e9eb7976aa3c04ed347027caf7da3a2fa76304751c02208acfc4e7fc6c7ebbc375c8a5010203262001215820ad7f7992c335b90d882b2802061b97a4fabca7e2ee3e7a51e728b8055e4eb9c7225820e0966ba7005987fece6f0e0e13447aa98cec248e4000a594b01b74c1cb1d40b3") + var v attestationObject + if err := cbor.Unmarshal(cborData, &v); err != nil { + fmt.Println("error:", err) + } + if _, err := cbor.Marshal(v); err != nil { + fmt.Println("error:", err) + } + fmt.Printf("%+v", v) +} diff --git a/vendor/github.com/fxamacker/cbor/go.mod b/vendor/github.com/fxamacker/cbor/go.mod new file mode 100644 index 0000000..49d74db --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/go.mod @@ -0,0 +1,5 @@ +module github.com/fxamacker/cbor/v2 + +go 1.12 + +require github.com/x448/float16 v0.8.4 diff --git a/vendor/github.com/fxamacker/cbor/go.sum b/vendor/github.com/fxamacker/cbor/go.sum new file mode 100644 index 0000000..dad8c42 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/go.sum @@ -0,0 +1,2 @@ +github.com/x448/float16 v0.8.4 h1:qLwI1I70+NjRFUR3zs1JPUCgaCXSh3SW62uAKT1mSBM= +github.com/x448/float16 v0.8.4/go.mod h1:14CWIYCyZA/cWjXOioeEpHeN/83MdbZDRQHoFcYsOfg= diff --git a/vendor/github.com/fxamacker/cbor/stream.go b/vendor/github.com/fxamacker/cbor/stream.go new file mode 100644 index 0000000..29172b9 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/stream.go @@ -0,0 +1,199 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "errors" + "io" + "reflect" +) + +// Decoder reads and decodes CBOR values from io.Reader. +type Decoder struct { + r io.Reader + d decoder + buf []byte + off int // next read offset in buf + bytesRead int +} + +// NewDecoder returns a new decoder that reads and decodes from r using +// the default decoding options. +func NewDecoder(r io.Reader) *Decoder { + return defaultDecMode.NewDecoder(r) +} + +// Decode reads CBOR value and decodes it into the value pointed to by v. +func (dec *Decoder) Decode(v interface{}) error { + if len(dec.buf) == dec.off { + if n, err := dec.read(); n == 0 { + return err + } + } + + dec.d.reset(dec.buf[dec.off:]) + err := dec.d.value(v) + dec.off += dec.d.off + dec.bytesRead += dec.d.off + if err != nil { + if err != io.ErrUnexpectedEOF { + return err + } + // Need to read more data. + if n, e := dec.read(); n == 0 { + return e + } + return dec.Decode(v) + } + return nil +} + +// NumBytesRead returns the number of bytes read. +func (dec *Decoder) NumBytesRead() int { + return dec.bytesRead +} + +func (dec *Decoder) read() (int, error) { + // Grow buf if needed. + const minRead = 512 + if cap(dec.buf)-len(dec.buf)+dec.off < minRead { + oldUnreadBuf := dec.buf[dec.off:] + dec.buf = make([]byte, len(dec.buf)-dec.off, 2*cap(dec.buf)+minRead) + dec.overwriteBuf(oldUnreadBuf) + } + + // Copy unread data over read data and reset off to 0. + if dec.off > 0 { + dec.overwriteBuf(dec.buf[dec.off:]) + } + + // Read from reader and reslice buf. + n, err := dec.r.Read(dec.buf[len(dec.buf):cap(dec.buf)]) + dec.buf = dec.buf[0 : len(dec.buf)+n] + return n, err +} + +func (dec *Decoder) overwriteBuf(newBuf []byte) { + n := copy(dec.buf, newBuf) + dec.buf = dec.buf[:n] + dec.off = 0 +} + +// Encoder writes CBOR values to io.Writer. +type Encoder struct { + w io.Writer + em *encMode + e *encoderBuffer + indefTypes []cborType +} + +// NewEncoder returns a new encoder that writes to w using the default encoding options. +func NewEncoder(w io.Writer) *Encoder { + return defaultEncMode.NewEncoder(w) +} + +// Encode writes the CBOR encoding of v. +func (enc *Encoder) Encode(v interface{}) error { + if len(enc.indefTypes) > 0 && v != nil { + indefType := enc.indefTypes[len(enc.indefTypes)-1] + if indefType == cborTypeTextString { + k := reflect.TypeOf(v).Kind() + if k != reflect.String { + return errors.New("cbor: cannot encode item type " + k.String() + " for indefinite-length text string") + } + } else if indefType == cborTypeByteString { + t := reflect.TypeOf(v) + k := t.Kind() + if (k != reflect.Array && k != reflect.Slice) || t.Elem().Kind() != reflect.Uint8 { + return errors.New("cbor: cannot encode item type " + k.String() + " for indefinite-length byte string") + } + } + } + + err := encode(enc.e, enc.em, reflect.ValueOf(v)) + if err == nil { + _, err = enc.e.WriteTo(enc.w) + } + enc.e.Reset() + return err +} + +// StartIndefiniteByteString starts byte string encoding of indefinite length. +// Subsequent calls of (*Encoder).Encode() encodes definite length byte strings +// ("chunks") as one continguous string until EndIndefinite is called. +func (enc *Encoder) StartIndefiniteByteString() error { + return enc.startIndefinite(cborTypeByteString) +} + +// StartIndefiniteTextString starts text string encoding of indefinite length. +// Subsequent calls of (*Encoder).Encode() encodes definite length text strings +// ("chunks") as one continguous string until EndIndefinite is called. +func (enc *Encoder) StartIndefiniteTextString() error { + return enc.startIndefinite(cborTypeTextString) +} + +// StartIndefiniteArray starts array encoding of indefinite length. +// Subsequent calls of (*Encoder).Encode() encodes elements of the array +// until EndIndefinite is called. +func (enc *Encoder) StartIndefiniteArray() error { + return enc.startIndefinite(cborTypeArray) +} + +// StartIndefiniteMap starts array encoding of indefinite length. +// Subsequent calls of (*Encoder).Encode() encodes elements of the map +// until EndIndefinite is called. +func (enc *Encoder) StartIndefiniteMap() error { + return enc.startIndefinite(cborTypeMap) +} + +// EndIndefinite closes last opened indefinite length value. +func (enc *Encoder) EndIndefinite() error { + if len(enc.indefTypes) == 0 { + return errors.New("cbor: cannot encode \"break\" code outside indefinite length values") + } + _, err := enc.w.Write([]byte{0xff}) + if err == nil { + enc.indefTypes = enc.indefTypes[:len(enc.indefTypes)-1] + } + return err +} + +var cborIndefHeader = map[cborType][]byte{ + cborTypeByteString: {0x5f}, + cborTypeTextString: {0x7f}, + cborTypeArray: {0x9f}, + cborTypeMap: {0xbf}, +} + +func (enc *Encoder) startIndefinite(typ cborType) error { + if enc.em.indefLength == IndefLengthForbidden { + return &IndefiniteLengthError{typ} + } + _, err := enc.w.Write(cborIndefHeader[typ]) + if err == nil { + enc.indefTypes = append(enc.indefTypes, typ) + } + return err +} + +// RawMessage is a raw encoded CBOR value. +type RawMessage []byte + +// MarshalCBOR returns m or CBOR nil if m is nil. +func (m RawMessage) MarshalCBOR() ([]byte, error) { + if len(m) == 0 { + return cborNil, nil + } + return m, nil +} + +// UnmarshalCBOR creates a copy of data and saves to *m. +func (m *RawMessage) UnmarshalCBOR(data []byte) error { + if m == nil { + return errors.New("cbor.RawMessage: UnmarshalCBOR on nil pointer") + } + *m = make([]byte, len(data)) + copy(*m, data) + return nil +} diff --git a/vendor/github.com/fxamacker/cbor/stream_test.go b/vendor/github.com/fxamacker/cbor/stream_test.go new file mode 100644 index 0000000..6469628 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/stream_test.go @@ -0,0 +1,425 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "bytes" + "io" + "reflect" + "testing" + "time" +) + +func TestDecoder(t *testing.T) { + var buf bytes.Buffer + for i := 0; i < 5; i++ { + for _, tc := range unmarshalTests { + buf.Write(tc.cborData) + } + } + decoder := NewDecoder(&buf) + bytesRead := 0 + for i := 0; i < 5; i++ { + for _, tc := range unmarshalTests { + var v interface{} + if err := decoder.Decode(&v); err != nil { + t.Fatalf("Decode() returned error %v", err) + } + if tm, ok := tc.emptyInterfaceValue.(time.Time); ok { + if vt, ok := v.(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Decode() = %v (%T), want %v (%T)", v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } else if !reflect.DeepEqual(v, tc.emptyInterfaceValue) { + t.Errorf("Decode() = %v (%T), want %v (%T)", v, v, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + bytesRead += len(tc.cborData) + if decoder.NumBytesRead() != bytesRead { + t.Errorf("NumBytesRead() = %v, want %v", decoder.NumBytesRead(), bytesRead) + } + } + } + // no more data + var v interface{} + err := decoder.Decode(&v) + if v != nil { + t.Errorf("Decode() = %v (%T), want nil (no more data)", v, v) + } + if err != io.EOF { + t.Errorf("Decode() returned error %v, want io.EOF (no more data)", err) + } +} + +func TestDecoderUnmarshalTypeError(t *testing.T) { + var buf bytes.Buffer + for i := 0; i < 5; i++ { + for _, tc := range unmarshalTests { + for j := 0; j < len(tc.wrongTypes)*2; j++ { + buf.Write(tc.cborData) + } + } + } + decoder := NewDecoder(&buf) + bytesRead := 0 + for i := 0; i < 5; i++ { + for _, tc := range unmarshalTests { + for _, typ := range tc.wrongTypes { + v := reflect.New(typ) + if err := decoder.Decode(v.Interface()); err == nil { + t.Errorf("Decode(0x%x) didn't return an error, want UnmarshalTypeError", tc.cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Decode(0x%x) returned wrong error type %T, want UnmarshalTypeError", tc.cborData, err) + } + bytesRead += len(tc.cborData) + if decoder.NumBytesRead() != bytesRead { + t.Errorf("NumBytesRead() = %v, want %v", decoder.NumBytesRead(), bytesRead) + } + + var vi interface{} + if err := decoder.Decode(&vi); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if tm, ok := tc.emptyInterfaceValue.(time.Time); ok { + if vt, ok := vi.(time.Time); !ok || !tm.Equal(vt) { + t.Errorf("Decode() = %v (%T), want %v (%T)", vi, vi, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + } else if !reflect.DeepEqual(vi, tc.emptyInterfaceValue) { + t.Errorf("Decode() = %v (%T), want %v (%T)", vi, vi, tc.emptyInterfaceValue, tc.emptyInterfaceValue) + } + bytesRead += len(tc.cborData) + if decoder.NumBytesRead() != bytesRead { + t.Errorf("NumBytesRead() = %v, want %v", decoder.NumBytesRead(), bytesRead) + } + } + } + } + // no more data + var v interface{} + err := decoder.Decode(&v) + if v != nil { + t.Errorf("Decode() = %v (%T), want nil (no more data)", v, v) + } + if err != io.EOF { + t.Errorf("Decode() returned error %v, want io.EOF (no more data)", err) + } +} + +func TestDecoderStructTag(t *testing.T) { + type strc struct { + A string `json:"x" cbor:"a"` + B string `json:"y" cbor:"b"` + C string `json:"z"` + } + want := strc{ + A: "A", + B: "B", + C: "C", + } + cborData := hexDecode("a36161614161626142617a6143") // {"a":"A", "b":"B", "z":"C"} + + var v strc + dec := NewDecoder(bytes.NewReader(cborData)) + if err := dec.Decode(&v); err != nil { + t.Errorf("Decode() returned error %v", err) + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Decode() = %+v (%T), want %+v (%T)", v, v, want, want) + } +} + +func TestEncoder(t *testing.T) { + var want bytes.Buffer + var w bytes.Buffer + em, err := CanonicalEncOptions().EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + encoder := em.NewEncoder(&w) + for _, tc := range marshalTests { + for _, value := range tc.values { + want.Write(tc.cborData) + + if err := encoder.Encode(value); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + } + } + if !bytes.Equal(w.Bytes(), want.Bytes()) { + t.Errorf("Encoding mismatch: got %v, want %v", w.Bytes(), want.Bytes()) + } +} + +func TestEncoderError(t *testing.T) { + testcases := []struct { + name string + value interface{} + wantErrorMsg string + }{ + {"channel cannot be marshaled", make(chan bool), "cbor: unsupported type: chan bool"}, + {"function cannot be marshaled", func(i int) int { return i * i }, "cbor: unsupported type: func(int) int"}, + {"complex cannot be marshaled", complex(100, 8), "cbor: unsupported type: complex128"}, + } + var w bytes.Buffer + encoder := NewEncoder(&w) + for _, tc := range testcases { + t.Run(tc.name, func(t *testing.T) { + err := encoder.Encode(&tc.value) + if err == nil { + t.Errorf("Encode(%v) didn't return an error, want error %q", tc.value, tc.wantErrorMsg) + } else if _, ok := err.(*UnsupportedTypeError); !ok { + t.Errorf("Encode(%v) error type %T, want *UnsupportedTypeError", tc.value, err) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Encode(%v) error %q, want %q", tc.value, err.Error(), tc.wantErrorMsg) + } + }) + } + if w.Len() != 0 { + t.Errorf("Encoder's writer has %d bytes of data, want empty data", w.Len()) + } +} + +func TestIndefiniteByteString(t *testing.T) { + want := hexDecode("5f42010243030405ff") + var w bytes.Buffer + encoder := NewEncoder(&w) + if err := encoder.StartIndefiniteByteString(); err != nil { + t.Fatalf("StartIndefiniteByteString() returned error %v", err) + } + if err := encoder.Encode([]byte{1, 2}); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.Encode([3]byte{3, 4, 5}); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.EndIndefinite(); err != nil { + t.Fatalf("EndIndefinite() returned error %v", err) + } + if !bytes.Equal(w.Bytes(), want) { + t.Errorf("Encoding mismatch: got %v, want %v", w.Bytes(), want) + } +} + +func TestIndefiniteByteStringError(t *testing.T) { + var w bytes.Buffer + encoder := NewEncoder(&w) + if err := encoder.StartIndefiniteByteString(); err != nil { + t.Fatalf("StartIndefiniteByteString() returned error %v", err) + } + if err := encoder.Encode([]int{1, 2}); err == nil { + t.Errorf("Encode() didn't return an error") + } else if err.Error() != "cbor: cannot encode item type slice for indefinite-length byte string" { + t.Errorf("Encode() returned error %q, want %q", err.Error(), "cbor: cannot encode item type slice for indefinite-length byte string") + } + if err := encoder.Encode("hello"); err == nil { + t.Errorf("Encode() didn't return an error") + } else if err.Error() != "cbor: cannot encode item type string for indefinite-length byte string" { + t.Errorf("Encode() returned error %q, want %q", err.Error(), "cbor: cannot encode item type string for indefinite-length byte string") + } +} + +func TestIndefiniteTextString(t *testing.T) { + want := hexDecode("7f657374726561646d696e67ff") + var w bytes.Buffer + encoder := NewEncoder(&w) + if err := encoder.StartIndefiniteTextString(); err != nil { + t.Fatalf("StartIndefiniteTextString() returned error %v", err) + } + if err := encoder.Encode("strea"); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.Encode("ming"); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.EndIndefinite(); err != nil { + t.Fatalf("EndIndefinite() returned error %v", err) + } + if !bytes.Equal(w.Bytes(), want) { + t.Errorf("Encoding mismatch: got %v, want %v", w.Bytes(), want) + } +} + +func TestIndefiniteTextStringError(t *testing.T) { + var w bytes.Buffer + encoder := NewEncoder(&w) + if err := encoder.StartIndefiniteTextString(); err != nil { + t.Fatalf("StartIndefiniteTextString() returned error %v", err) + } + if err := encoder.Encode([]byte{1, 2}); err == nil { + t.Errorf("Encode() didn't return an error") + } else if err.Error() != "cbor: cannot encode item type slice for indefinite-length text string" { + t.Errorf("Encode() returned error %q, want %q", err.Error(), "cbor: cannot encode item type slice for indefinite-length text string") + } +} + +func TestIndefiniteArray(t *testing.T) { + want := hexDecode("9f018202039f0405ffff") + var w bytes.Buffer + encoder := NewEncoder(&w) + if err := encoder.StartIndefiniteArray(); err != nil { + t.Fatalf("StartIndefiniteArray() returned error %v", err) + } + if err := encoder.Encode(1); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.Encode([]int{2, 3}); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.StartIndefiniteArray(); err != nil { + t.Fatalf("StartIndefiniteArray() returned error %v", err) + } + if err := encoder.Encode(4); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.Encode(5); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.EndIndefinite(); err != nil { + t.Fatalf("EndIndefinite() returned error %v", err) + } + if err := encoder.EndIndefinite(); err != nil { + t.Fatalf("EndIndefinite() returned error %v", err) + } + if !bytes.Equal(w.Bytes(), want) { + t.Errorf("Encoding mismatch: got %v, want %v", w.Bytes(), want) + } +} + +func TestIndefiniteMap(t *testing.T) { + want := hexDecode("bf61610161629f0203ffff") + var w bytes.Buffer + em, err := EncOptions{Sort: SortCanonical}.EncMode() + if err != nil { + t.Errorf("EncMode() returned an error %v", err) + } + encoder := em.NewEncoder(&w) + if err := encoder.StartIndefiniteMap(); err != nil { + t.Fatalf("StartIndefiniteMap() returned error %v", err) + } + if err := encoder.Encode("a"); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.Encode(1); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.Encode("b"); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.StartIndefiniteArray(); err != nil { + t.Fatalf("StartIndefiniteArray() returned error %v", err) + } + if err := encoder.Encode(2); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.Encode(3); err != nil { + t.Fatalf("Encode() returned error %v", err) + } + if err := encoder.EndIndefinite(); err != nil { + t.Fatalf("EndIndefinite() returned error %v", err) + } + if err := encoder.EndIndefinite(); err != nil { + t.Fatalf("EndIndefinite() returned error %v", err) + } + if !bytes.Equal(w.Bytes(), want) { + t.Errorf("Encoding mismatch: got %v, want %v", w.Bytes(), want) + } +} + +func TestIndefiniteLengthError(t *testing.T) { + var w bytes.Buffer + encoder := NewEncoder(&w) + if err := encoder.StartIndefiniteByteString(); err != nil { + t.Fatalf("StartIndefiniteByteString() returned error %v", err) + } + if err := encoder.EndIndefinite(); err != nil { + t.Fatalf("EndIndefinite() returned error %v", err) + } + if err := encoder.EndIndefinite(); err == nil { + t.Fatalf("EndIndefinite() didn't return an error") + } +} + +func TestEncoderStructTag(t *testing.T) { + type strc struct { + A string `json:"x" cbor:"a"` + B string `json:"y" cbor:"b"` + C string `json:"z"` + } + v := strc{ + A: "A", + B: "B", + C: "C", + } + want := hexDecode("a36161614161626142617a6143") // {"a":"A", "b":"B", "z":"C"} + + var w bytes.Buffer + encoder := NewEncoder(&w) + if err := encoder.Encode(v); err != nil { + t.Errorf("Encode(%+v) returned error %v", v, err) + } + if !bytes.Equal(w.Bytes(), want) { + t.Errorf("Encoding mismatch: got %v, want %v", w.Bytes(), want) + } +} + +func TestRawMessage(t *testing.T) { + type strc struct { + A RawMessage `cbor:"a"` + B *RawMessage `cbor:"b"` + C *RawMessage `cbor:"c"` + } + cborData := hexDecode("a361610161628202036163f6") // {"a": 1, "b": [2, 3], "c": nil}, + r := RawMessage(hexDecode("820203")) + want := strc{ + A: RawMessage([]byte{0x01}), + B: &r, + } + var v strc + if err := Unmarshal(cborData, &v); err != nil { + t.Fatalf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, want) { + t.Errorf("Unmarshal(0x%x) returned v %v, want %v", cborData, v, want) + } + b, err := Marshal(v) + if err != nil { + t.Fatalf("Marshal(%+v) returned error %v", v, err) + } + if !bytes.Equal(b, cborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", v, b, cborData) + } +} + +func TestNullRawMessage(t *testing.T) { + r := RawMessage(nil) + wantCborData := []byte{0xf6} + b, err := Marshal(r) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", r, err) + } + if !bytes.Equal(b, wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", r, b, wantCborData) + } +} + +func TestEmptyRawMessage(t *testing.T) { + var r RawMessage + wantCborData := []byte{0xf6} + b, err := Marshal(r) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", r, err) + } + if !bytes.Equal(b, wantCborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", r, b, wantCborData) + } +} + +func TestNilRawMessageUnmarshalCBORError(t *testing.T) { + wantErrorMsg := "cbor.RawMessage: UnmarshalCBOR on nil pointer" + var r *RawMessage + cborData := hexDecode("01") + if err := r.UnmarshalCBOR(cborData); err == nil { + t.Errorf("UnmarshalCBOR() didn't return error") + } else if err.Error() != wantErrorMsg { + t.Errorf("UnmarshalCBOR() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} diff --git a/vendor/github.com/fxamacker/cbor/structfields.go b/vendor/github.com/fxamacker/cbor/structfields.go new file mode 100644 index 0000000..7c5974f --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/structfields.go @@ -0,0 +1,251 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "reflect" + "sort" + "strings" +) + +type field struct { + name string + nameAsInt int64 // used to decoder to match field name with CBOR int + cborName []byte + idx []int + typ reflect.Type + ef encodeFunc + ief isEmptyFunc + typInfo *typeInfo // used to decoder to reuse type info + tagged bool // used to choose dominant field (at the same level tagged fields dominate untagged fields) + omitEmpty bool // used to skip empty field + keyAsInt bool // used to encode/decode field name as int +} + +type fields []*field + +// indexFieldSorter sorts fields by field idx at each level, breaking ties with idx depth. +type indexFieldSorter struct { + fields fields +} + +func (x *indexFieldSorter) Len() int { + return len(x.fields) +} + +func (x *indexFieldSorter) Swap(i, j int) { + x.fields[i], x.fields[j] = x.fields[j], x.fields[i] +} + +func (x *indexFieldSorter) Less(i, j int) bool { + iIdx, jIdx := x.fields[i].idx, x.fields[j].idx + for k := 0; k < len(iIdx) && k < len(jIdx); k++ { + if iIdx[k] != jIdx[k] { + return iIdx[k] < jIdx[k] + } + } + return len(iIdx) <= len(jIdx) +} + +// nameLevelAndTagFieldSorter sorts fields by field name, idx depth, and presence of tag. +type nameLevelAndTagFieldSorter struct { + fields fields +} + +func (x *nameLevelAndTagFieldSorter) Len() int { + return len(x.fields) +} + +func (x *nameLevelAndTagFieldSorter) Swap(i, j int) { + x.fields[i], x.fields[j] = x.fields[j], x.fields[i] +} + +func (x *nameLevelAndTagFieldSorter) Less(i, j int) bool { + fi, fj := x.fields[i], x.fields[j] + if fi.name != fj.name { + return fi.name < fj.name + } + if len(fi.idx) != len(fj.idx) { + return len(fi.idx) < len(fj.idx) + } + if fi.tagged != fj.tagged { + return fi.tagged + } + return i < j // Field i and j have the same name, depth, and tagged status. Nothing else matters. +} + +// getFields returns visible fields of struct type t following visibility rules for JSON encoding. +func getFields(t reflect.Type) (flds fields, structOptions string) { + // Get special field "_" tag options + if f, ok := t.FieldByName("_"); ok { + tag := f.Tag.Get("cbor") + if tag != "-" { + structOptions = tag + } + } + + // nTypes contains next level anonymous fields' types and indexes + // (there can be multiple fields of the same type at the same level) + flds, nTypes := appendFields(t, nil, nil, nil) + + if len(nTypes) > 0 { + + var cTypes map[reflect.Type][][]int // current level anonymous fields' types and indexes + vTypes := map[reflect.Type]bool{t: true} // visited field types at less nested levels + + for len(nTypes) > 0 { + cTypes, nTypes = nTypes, nil + + for t, idx := range cTypes { + // If there are multiple anonymous fields of the same struct type at the same level, all are ignored. + if len(idx) > 1 { + continue + } + + // Anonymous field of the same type at deeper nested level is ignored. + if vTypes[t] { + continue + } + vTypes[t] = true + + flds, nTypes = appendFields(t, idx[0], flds, nTypes) + } + } + } + + sort.Sort(&nameLevelAndTagFieldSorter{flds}) + + // Keep visible fields. + j := 0 // index of next unique field + for i := 0; i < len(flds); { + name := flds[i].name + if i == len(flds)-1 || // last field + name != flds[i+1].name || // field i has unique field name + len(flds[i].idx) < len(flds[i+1].idx) || // field i is at a less nested level than field i+1 + (flds[i].tagged && !flds[i+1].tagged) { // field i is tagged while field i+1 is not + flds[j] = flds[i] + j++ + } + + // Skip fields with the same field name. + for i++; i < len(flds) && name == flds[i].name; i++ { + } + } + if j != len(flds) { + flds = flds[:j] + } + + // Sort fields by field index + sort.Sort(&indexFieldSorter{flds}) + + return flds, structOptions +} + +// appendFields appends type t's exportable fields to flds and anonymous struct fields to nTypes . +func appendFields(t reflect.Type, idx []int, flds fields, nTypes map[reflect.Type][][]int) (fields, map[reflect.Type][][]int) { + for i := 0; i < t.NumField(); i++ { + f := t.Field(i) + + ft := f.Type + for ft.Kind() == reflect.Ptr { + ft = ft.Elem() + } + + if !isFieldExportable(f, ft.Kind()) { + continue + } + + tag := f.Tag.Get("cbor") + if tag == "" { + tag = f.Tag.Get("json") + } + if tag == "-" { + continue + } + + tagged := len(tag) > 0 + + // Parse field tag options + var tagFieldName string + var omitempty, keyasint bool + for j := 0; len(tag) > 0; j++ { + var token string + idx := strings.IndexByte(tag, ',') + if idx == -1 { + token, tag = tag, "" + } else { + token, tag = tag[:idx], tag[idx+1:] + } + if j == 0 { + tagFieldName = token + } else { + switch token { + case "omitempty": + omitempty = true + case "keyasint": + keyasint = true + } + } + } + + fieldName := tagFieldName + if tagFieldName == "" { + fieldName = f.Name + } + + fIdx := make([]int, len(idx)+1) + copy(fIdx, idx) + fIdx[len(fIdx)-1] = i + + if !f.Anonymous || ft.Kind() != reflect.Struct || len(tagFieldName) > 0 { + flds = append(flds, &field{ + name: fieldName, + idx: fIdx, + typ: f.Type, + omitEmpty: omitempty, + keyAsInt: keyasint, + tagged: tagged}) + } else { + if nTypes == nil { + nTypes = make(map[reflect.Type][][]int) + } + nTypes[ft] = append(nTypes[ft], fIdx) + } + } + + return flds, nTypes +} + +// isFieldExportable returns true if f is an exportable (regular or anonymous) field or +// a nonexportable anonymous field of struct type. +// Nonexportable anonymous field of struct type can contain exportable fields. +func isFieldExportable(f reflect.StructField, fk reflect.Kind) bool { + exportable := f.PkgPath == "" + return exportable || (f.Anonymous && fk == reflect.Struct) +} + +type embeddedFieldNullPtrFunc func(reflect.Value) (reflect.Value, error) + +// getFieldValue returns field value of struct v by index. When encountering null pointer +// to anonymous (embedded) struct field, f is called with the last traversed field value. +func getFieldValue(v reflect.Value, idx []int, f embeddedFieldNullPtrFunc) (fv reflect.Value, err error) { + fv = v + for i, n := range idx { + fv = fv.Field(n) + + if i < len(idx)-1 { + if fv.Kind() == reflect.Ptr && fv.Type().Elem().Kind() == reflect.Struct { + if fv.IsNil() { + // Null pointer to embedded struct field + fv, err = f(fv) + if err != nil || !fv.IsValid() { + return fv, err + } + } + fv = fv.Elem() + } + } + } + return fv, nil +} diff --git a/vendor/github.com/fxamacker/cbor/tag.go b/vendor/github.com/fxamacker/cbor/tag.go new file mode 100644 index 0000000..db29149 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/tag.go @@ -0,0 +1,303 @@ +package cbor + +import ( + "errors" + "fmt" + "reflect" + "sync" +) + +// Tag represents CBOR tag data, including tag number and unmarshaled tag content. +type Tag struct { + Number uint64 + Content interface{} +} + +// RawTag represents CBOR tag data, including tag number and raw tag content. +// RawTag implements Unmarshaler and Marshaler interfaces. +type RawTag struct { + Number uint64 + Content RawMessage +} + +// UnmarshalCBOR sets *t with tag number and raw tag content copied from data. +func (t *RawTag) UnmarshalCBOR(data []byte) error { + if t == nil { + return errors.New("cbor.RawTag: UnmarshalCBOR on nil pointer") + } + + // Decoding CBOR null and undefined to cbor.RawTag is no-op. + if len(data) == 1 && (data[0] == 0xf6 || data[0] == 0xf7) { + return nil + } + + d := decoder{data: data, dm: defaultDecMode} + + // Unmarshal tag number. + typ, _, num := d.getHead() + if typ != cborTypeTag { + return &UnmarshalTypeError{CBORType: typ.String(), GoType: typeRawTag.String()} + } + t.Number = num + + // Unmarshal tag content. + c := d.data[d.off:] + t.Content = make([]byte, len(c)) + copy(t.Content, c) + return nil +} + +// MarshalCBOR returns CBOR encoding of t. +func (t RawTag) MarshalCBOR() ([]byte, error) { + if t.Number == 0 && len(t.Content) == 0 { + // Marshal uninitialized cbor.RawTag + b := make([]byte, len(cborNil)) + copy(b, cborNil) + return b, nil + } + + e := getEncoderBuffer() + + encodeHead(e, byte(cborTypeTag), t.Number) + + content := t.Content + if len(content) == 0 { + content = cborNil + } + + buf := make([]byte, len(e.Bytes())+len(content)) + n := copy(buf, e.Bytes()) + copy(buf[n:], content) + + putEncoderBuffer(e) + return buf, nil +} + +// DecTagMode specifies how decoder handles tag number. +type DecTagMode int + +const ( + // DecTagIgnored makes decoder ignore tag number (skips if present). + DecTagIgnored DecTagMode = iota + + // DecTagOptional makes decoder verify tag number if it's present. + DecTagOptional + + // DecTagRequired makes decoder verify tag number and tag number must be present. + DecTagRequired + + maxDecTagMode +) + +func (dtm DecTagMode) valid() bool { + return dtm < maxDecTagMode +} + +// EncTagMode specifies how encoder handles tag number. +type EncTagMode int + +const ( + // EncTagNone makes encoder not encode tag number. + EncTagNone EncTagMode = iota + + // EncTagRequired makes encoder encode tag number. + EncTagRequired + + maxEncTagMode +) + +func (etm EncTagMode) valid() bool { + return etm < maxEncTagMode +} + +// TagOptions specifies how encoder and decoder handle tag number. +type TagOptions struct { + DecTag DecTagMode + EncTag EncTagMode +} + +// TagSet is an interface to add and remove tag info. It is used by EncMode and DecMode +// to provide CBOR tag support. +type TagSet interface { + // Add adds given tag number(s), content type, and tag options to TagSet. + Add(opts TagOptions, contentType reflect.Type, num uint64, nestedNum ...uint64) error + + // Remove removes given tag content type from TagSet. + Remove(contentType reflect.Type) + + tagProvider +} + +type tagProvider interface { + getTagItemFromType(t reflect.Type) *tagItem + getTypeFromTagNum(num []uint64) reflect.Type +} + +type tagItem struct { + num []uint64 + cborTagNum []byte + contentType reflect.Type + opts TagOptions +} + +func (t *tagItem) equalTagNum(num []uint64) bool { + // Fast path to compare 1 tag number + if len(t.num) == 1 && len(num) == 1 && t.num[0] == num[0] { + return true + } + + if len(t.num) != len(num) { + return false + } + + for i := 0; i < len(t.num); i++ { + if t.num[i] != num[i] { + return false + } + } + + return true +} + +type ( + tagSet map[reflect.Type]*tagItem + + syncTagSet struct { + sync.RWMutex + t tagSet + } +) + +func (t tagSet) getTagItemFromType(typ reflect.Type) *tagItem { + return t[typ] +} + +func (t tagSet) getTypeFromTagNum(num []uint64) reflect.Type { + for typ, tag := range t { + if tag.equalTagNum(num) { + return typ + } + } + return nil +} + +// NewTagSet returns TagSet (safe for concurrency). +func NewTagSet() TagSet { + return &syncTagSet{t: make(map[reflect.Type]*tagItem)} +} + +// Add adds given tag number(s), content type, and tag options to TagSet. +func (t *syncTagSet) Add(opts TagOptions, contentType reflect.Type, num uint64, nestedNum ...uint64) error { + if contentType == nil { + return errors.New("cbor: cannot add nil content type to TagSet") + } + for contentType.Kind() == reflect.Ptr { + contentType = contentType.Elem() + } + tag, err := newTagItem(opts, contentType, num, nestedNum...) + if err != nil { + return err + } + t.Lock() + defer t.Unlock() + for typ, ti := range t.t { + if typ == contentType { + return errors.New("cbor: content type " + contentType.String() + " already exists in TagSet") + } + if ti.equalTagNum(tag.num) { + return fmt.Errorf("cbor: tag number %v already exists in TagSet", tag.num) + } + } + t.t[contentType] = tag + return nil +} + +// Remove removes given tag content type from TagSet. +func (t *syncTagSet) Remove(contentType reflect.Type) { + for contentType.Kind() == reflect.Ptr { + contentType = contentType.Elem() + } + t.Lock() + delete(t.t, contentType) + t.Unlock() +} + +func (t *syncTagSet) getTagItemFromType(typ reflect.Type) *tagItem { + t.RLock() + ti := t.t[typ] + t.RUnlock() + return ti +} + +func (t *syncTagSet) getTypeFromTagNum(num []uint64) reflect.Type { + t.RLock() + rt := t.t.getTypeFromTagNum(num) + t.RUnlock() + return rt +} + +func newTagItem(opts TagOptions, contentType reflect.Type, num uint64, nestedNum ...uint64) (*tagItem, error) { + if opts.DecTag == DecTagIgnored && opts.EncTag == EncTagNone { + return nil, errors.New("cbor: cannot add tag with DecTagIgnored and EncTagNone options to TagSet") + } + if contentType.PkgPath() == "" || contentType.Kind() == reflect.Interface { + return nil, errors.New("cbor: can only add named types to TagSet, got " + contentType.String()) + } + if contentType == typeTime { + return nil, errors.New("cbor: cannot add time.Time to TagSet, use EncOptions.TimeTag and DecOptions.TimeTag instead") + } + if contentType == typeBigInt { + return nil, errors.New("cbor: cannot add big.Int to TagSet, it's built-in and supported automatically") + } + if contentType == typeTag { + return nil, errors.New("cbor: cannot add cbor.Tag to TagSet") + } + if contentType == typeRawTag { + return nil, errors.New("cbor: cannot add cbor.RawTag to TagSet") + } + if num == 0 || num == 1 { + return nil, errors.New("cbor: cannot add tag number 0 or 1 to TagSet, use EncOptions.TimeTag and DecOptions.TimeTag instead") + } + if num == 2 || num == 3 { + return nil, errors.New("cbor: cannot add tag number 2 or 3 to TagSet, it's built-in and supported automatically") + } + if num == selfDescribedCBORTagNum { + return nil, errors.New("cbor: cannot add tag number 55799 to TagSet, it's built-in and ignored automatically") + } + //if reflect.PtrTo(contentType).Implements(typeMarshaler) && opts.EncTag != EncTagNone { + //return nil, errors.New("cbor: cannot add cbor.Marshaler to TagSet with EncTag != EncTagNone") + //} + //if reflect.PtrTo(contentType).Implements(typeUnmarshaler) && opts.DecTag != DecTagIgnored { + //return nil, errors.New("cbor: cannot add cbor.Unmarshaler to TagSet with DecTag != DecTagIgnored") + //} + + te := tagItem{num: []uint64{num}, opts: opts, contentType: contentType} + te.num = append(te.num, nestedNum...) + + // Cache encoded tag numbers + e := getEncoderBuffer() + for _, n := range te.num { + encodeHead(e, byte(cborTypeTag), n) + } + te.cborTagNum = make([]byte, e.Len()) + copy(te.cborTagNum, e.Bytes()) + putEncoderBuffer(e) + + return &te, nil +} + +var ( + typeTag = reflect.TypeOf(Tag{}) + typeRawTag = reflect.TypeOf(RawTag{}) +) + +// WrongTagError describes mismatch between CBOR tag and registered tag. +type WrongTagError struct { + RegisteredType reflect.Type + RegisteredTagNum []uint64 + TagNum []uint64 +} + +func (e *WrongTagError) Error() string { + return fmt.Sprintf("cbor: wrong tag number for %s, got %v, expected %v", e.RegisteredType.String(), e.TagNum, e.RegisteredTagNum) +} diff --git a/vendor/github.com/fxamacker/cbor/tag_test.go b/vendor/github.com/fxamacker/cbor/tag_test.go new file mode 100644 index 0000000..560af47 --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/tag_test.go @@ -0,0 +1,1446 @@ +package cbor + +import ( + "bytes" + "fmt" + "io" + "math/big" + "reflect" + "strings" + "testing" + "time" +) + +func TestTagNewTypeWithBuiltinUnderlyingType(t *testing.T) { + type myBool bool + type myUint uint + type myUint8 uint8 + type myUint16 uint16 + type myUint32 uint32 + type myUint64 uint64 + type myInt int + type myInt8 int8 + type myInt16 int16 + type myInt32 int32 + type myInt64 int64 + type myFloat32 float32 + type myFloat64 float64 + type myString string + type myByteSlice []byte + type myIntSlice []int + type myIntArray [4]int + type myMapIntInt map[int]int + + types := []reflect.Type{ + reflect.TypeOf(myBool(false)), + reflect.TypeOf(myUint(0)), + reflect.TypeOf(myUint8(0)), + reflect.TypeOf(myUint16(0)), + reflect.TypeOf(myUint32(0)), + reflect.TypeOf(myUint64(0)), + reflect.TypeOf(myInt(0)), + reflect.TypeOf(myInt8(0)), + reflect.TypeOf(myInt16(0)), + reflect.TypeOf(myInt32(0)), + reflect.TypeOf(myInt64(0)), + reflect.TypeOf(myFloat32(0)), + reflect.TypeOf(myFloat64(0)), + reflect.TypeOf(myString("")), + reflect.TypeOf(myByteSlice([]byte{})), + reflect.TypeOf(myIntSlice([]int{})), + reflect.TypeOf(myIntArray([4]int{})), + reflect.TypeOf(myMapIntInt(map[int]int{})), + } + + tags := NewTagSet() + for i, typ := range types { + tagNum := uint64(100 + i) + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, typ, tagNum); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", typ, tagNum, err) + } + } + + em, _ := EncOptions{Sort: SortCanonical}.EncModeWithTags(tags) + dm, _ := DecOptions{}.DecModeWithTags(tags) + + testCases := []roundTripTest{ + { + name: "bool", + obj: myBool(true), + wantCborData: hexDecode("d864f5"), + }, + { + name: "uint", + obj: myUint(0), + wantCborData: hexDecode("d86500"), + }, + { + name: "uint8", + obj: myUint8(0), + wantCborData: hexDecode("d86600"), + }, + { + name: "uint16", + obj: myUint16(1000), + wantCborData: hexDecode("d8671903e8"), + }, + { + name: "uint32", + obj: myUint32(1000000), + wantCborData: hexDecode("d8681a000f4240"), + }, + { + name: "uint64", + obj: myUint64(1000000000000), + wantCborData: hexDecode("d8691b000000e8d4a51000"), + }, + { + name: "int", + obj: myInt(-1), + wantCborData: hexDecode("d86a20"), + }, + { + name: "int8", + obj: myInt8(-1), + wantCborData: hexDecode("d86b20"), + }, + { + name: "int16", + obj: myInt16(-1000), + wantCborData: hexDecode("d86c3903e7"), + }, + { + name: "int32", + obj: myInt32(-1000), + wantCborData: hexDecode("d86d3903e7"), + }, + { + name: "int64", + obj: myInt64(-1000), + wantCborData: hexDecode("d86e3903e7"), + }, + { + name: "float32", + obj: myFloat32(100000.0), + wantCborData: hexDecode("d86ffa47c35000"), + }, + { + name: "float64", + obj: myFloat64(1.1), + wantCborData: hexDecode("d870fb3ff199999999999a"), + }, + { + name: "string", + obj: myString("a"), + wantCborData: hexDecode("d8716161"), + }, + { + name: "[]byte", + obj: myByteSlice([]byte{1, 2, 3, 4}), + wantCborData: hexDecode("d8724401020304"), + }, + { + name: "[]int", + obj: myIntSlice([]int{1, 2, 3, 4}), + wantCborData: hexDecode("d8738401020304"), + }, + { + name: "[4]int", + obj: myIntArray([...]int{1, 2, 3, 4}), + wantCborData: hexDecode("d8748401020304"), + }, + { + name: "map[int]int", + obj: myMapIntInt(map[int]int{1: 2, 3: 4}), + wantCborData: hexDecode("d875a201020304"), + }, + } + + testRoundTrip(t, testCases, em, dm) +} + +func TestTagBinaryMarshalerUnmarshaler(t *testing.T) { + t1 := reflect.TypeOf((*number)(nil)) // Use *number for testing purpose + t2 := reflect.TypeOf(stru{}) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, t1, 123); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", t1, 123, err) + } + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, t2, 124); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", t2, 124, err) + } + + em, _ := EncOptions{}.EncModeWithTags(tags) + dm, _ := DecOptions{}.DecModeWithTags(tags) + + testCases := []roundTripTest{ + { + name: "primitive obj", + obj: number(1234567890), + wantCborData: hexDecode("d87b4800000000499602d2"), + }, + { + name: "struct obj", + obj: stru{a: "a", b: "b", c: "c"}, + wantCborData: hexDecode("d87c45612C622C63"), + }, + } + + testRoundTrip(t, testCases, em, dm) +} + +func TestTagStruct(t *testing.T) { + type T struct { + S string `cbor:"s,omitempty"` + } + + t1 := reflect.TypeOf(T{}) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, t1, 100); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", t1, 100, err) + } + + em, _ := EncOptions{}.EncModeWithTags(tags) + dm, _ := DecOptions{}.DecModeWithTags(tags) + + cborData := hexDecode("d864a0") // {} + var v T + if err := dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } + if !bytes.Equal(b, cborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", v, b, cborData) + } +} + +func TestTagFixedLengthStruct(t *testing.T) { + type T struct { + S string `cbor:"s"` + } + + t1 := reflect.TypeOf(T{}) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, t1, 100); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", t1, 100, err) + } + + em, _ := EncOptions{}.EncModeWithTags(tags) + dm, _ := DecOptions{}.DecModeWithTags(tags) + + cborData := hexDecode("d864a1617360") // {"s":""} + var v T + if err := dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } + if !bytes.Equal(b, cborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", v, b, cborData) + } +} + +func TestTagToArrayStruct(t *testing.T) { + type coseHeader struct { + Alg int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` + } + type signedCWT struct { + _ struct{} `cbor:",toarray"` + Protected []byte + Unprotected coseHeader + Payload []byte + Signature []byte + } + + t1 := reflect.TypeOf(signedCWT{}) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, t1, 18); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", t1, 18, err) + } + + em, _ := EncOptions{}.EncModeWithTags(tags) + dm, _ := DecOptions{}.DecModeWithTags(tags) + + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.3 + cborData := hexDecode("d28443a10126a104524173796d6d657472696345434453413235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7158405427c1ff28d23fbad1f29c4c7c6a555e601d6fa29f9179bc3d7438bacaca5acd08c8d4d4f96131680c429a01f85951ecee743a52b9b63632c57209120e1c9e30") + var v signedCWT + if err := dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } + if !bytes.Equal(b, cborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", v, b, cborData) + } +} + +func TestNestedTagStruct(t *testing.T) { + type coseHeader struct { + Alg int `cbor:"1,keyasint,omitempty"` + Kid []byte `cbor:"4,keyasint,omitempty"` + IV []byte `cbor:"5,keyasint,omitempty"` + } + type macedCOSE struct { + _ struct{} `cbor:",toarray"` + Protected []byte + Unprotected coseHeader + Payload []byte + Tag []byte + } + + t1 := reflect.TypeOf(macedCOSE{}) + + // Register tag CBOR Web Token (CWT) 61 and COSE_Mac0 17 with macedCOSE type + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, t1, 61, 17); err != nil { + t.Fatalf("TagSet.Add(%s, %d, %v) returned error %v", t1, 61, 17, err) + } + + em, _ := EncOptions{}.EncModeWithTags(tags) + dm, _ := DecOptions{}.DecModeWithTags(tags) + + // Data from https://tools.ietf.org/html/rfc8392#appendix-A section A.4 + cborData := hexDecode("d83dd18443a10104a1044c53796d6d65747269633235365850a70175636f61703a2f2f61732e6578616d706c652e636f6d02656572696b77037818636f61703a2f2f6c696768742e6578616d706c652e636f6d041a5612aeb0051a5610d9f0061a5610d9f007420b7148093101ef6d789200") + var v macedCOSE + if err := dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%+v) returned error %v", v, err) + } + if !bytes.Equal(b, cborData) { + t.Errorf("Marshal(%+v) = 0x%x, want 0x%x", v, b, cborData) + } +} + +func TestAddTagError(t *testing.T) { + type myInt int + testCases := []struct { + name string + typ reflect.Type + num uint64 + opts TagOptions + wantErrorMsg string + }{ + { + name: "nil type", + typ: nil, + num: 100, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add nil content type to TagSet", + }, + { + name: "DecTag is DecTagIgnored && EncTag is EncTagNone", + typ: reflect.TypeOf(myInt(0)), + num: 100, + opts: TagOptions{DecTag: DecTagIgnored, EncTag: EncTagNone}, + wantErrorMsg: "cbor: cannot add tag with DecTagIgnored and EncTagNone options to TagSet", + }, + { + name: "time.Time", + typ: reflect.TypeOf(time.Time{}), + num: 101, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add time.Time to TagSet, use EncOptions.TimeTag and DecOptions.TimeTag instead", + }, + { + name: "builtin type string", + typ: reflect.TypeOf(""), + num: 102, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: can only add named types to TagSet, got string", + }, + { + name: "unnamed type struct{}", + typ: reflect.TypeOf(struct{}{}), + num: 103, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: can only add named types to TagSet, got struct {}", + }, + { + name: "interface", + typ: reflect.TypeOf((*io.Reader)(nil)).Elem(), + num: 104, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: can only add named types to TagSet, got io.Reader", + }, + { + name: "cbor.Tag", + typ: reflect.TypeOf(Tag{}), + num: 105, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add cbor.Tag to TagSet", + }, + { + name: "cbor.RawTag", + typ: reflect.TypeOf(RawTag{}), + num: 106, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add cbor.RawTag to TagSet", + }, + { + name: "big.Int", + typ: reflect.TypeOf(big.Int{}), + num: 107, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add big.Int to TagSet, it's built-in and supported automatically", + }, + /* + { + name: "cbor.Unmarshaler", + typ: reflect.TypeOf(number2(0)), + num: 107, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagNone}, + wantErrorMsg: "cbor: cannot add cbor.Unmarshaler to TagSet with DecTag != DecTagIgnored", + }, + { + name: "cbor.Marshaler", + typ: reflect.TypeOf(number2(0)), + num: 108, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add cbor.Marshaler to TagSet with EncTag != EncTagNone", + }, + */ + { + name: "tag number 0", + typ: reflect.TypeOf(myInt(0)), + num: 0, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add tag number 0 or 1 to TagSet, use EncOptions.TimeTag and DecOptions.TimeTag instead", + }, + { + name: "tag number 1", + typ: reflect.TypeOf(myInt(0)), + num: 1, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add tag number 0 or 1 to TagSet, use EncOptions.TimeTag and DecOptions.TimeTag instead", + }, + { + name: "tag number 2", + typ: reflect.TypeOf(myInt(0)), + num: 2, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add tag number 2 or 3 to TagSet, it's built-in and supported automatically", + }, + { + name: "tag number 3", + typ: reflect.TypeOf(myInt(0)), + num: 3, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add tag number 2 or 3 to TagSet, it's built-in and supported automatically", + }, + { + name: "tag number 55799", + typ: reflect.TypeOf(myInt(0)), + num: 55799, + opts: TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, + wantErrorMsg: "cbor: cannot add tag number 55799 to TagSet, it's built-in and ignored automatically", + }, + } + tags := NewTagSet() + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + if err := tags.Add(tc.opts, tc.typ, tc.num); err == nil { + t.Errorf("TagSet.Add(%s, %d) didn't return an error", tc.typ.String(), tc.num) + } else if err.Error() != tc.wantErrorMsg { + var typeString string + if tc.typ == nil { + typeString = "nil" + } else { + typeString = tc.typ.String() + } + t.Errorf("TagSet.Add(%s, %d) returned error msg %q, want %q", typeString, tc.num, err, tc.wantErrorMsg) + } + }) + } +} + +func TestAddDuplicateTagContentTypeError(t *testing.T) { + type myInt int + myIntType := reflect.TypeOf(myInt(0)) + wantErrorMsg := "cbor: content type cbor.myInt already exists in TagSet" + + tags := NewTagSet() + // Add myIntType and 100 to tags + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myIntType, 100); err != nil { + t.Errorf("TagSet.Add(%s, %d) returned error %v", myIntType.String(), 100, err) + } + // Add myIntType and 101 to tags + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myIntType, 101); err == nil { + t.Errorf("TagSet.Add(%s, %d) didn't return an error", myIntType.String(), 101) + } else if err.Error() != wantErrorMsg { + t.Errorf("TagSet.Add(%s, %d) returned error msg %q, want %q", myIntType, 101, err, wantErrorMsg) + } +} + +func TestAddDuplicateTagNumError(t *testing.T) { + type myBool bool + type myInt int + myBoolType := reflect.TypeOf(myBool(false)) + myIntType := reflect.TypeOf(myInt(0)) + wantErrorMsg := "cbor: tag number [100] already exists in TagSet" + + tags := NewTagSet() + + // Add myIntType and 100 to tags + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myIntType, 100); err != nil { + t.Errorf("TagSet.Add(%s, %d) returned error %v", myIntType.String(), 100, err) + } + // Add myBoolType and 100 to tags + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myBoolType, 100); err == nil { + t.Errorf("TagSet.Add(%s, %d) didn't return an error", myBoolType.String(), 100) + } else if err.Error() != wantErrorMsg { + t.Errorf("TagSet.Add(%s, %d) returned error msg %q, want %q", myBoolType, 100, err, wantErrorMsg) + } +} + +func TestAddDuplicateTagNumsError(t *testing.T) { + type myBool bool + type myInt int + myBoolType := reflect.TypeOf(myBool(false)) + myIntType := reflect.TypeOf(myInt(0)) + wantErrorMsg := "cbor: tag number [100 101] already exists in TagSet" + + tags := NewTagSet() + + // Add myIntType and [100, 101] to tags + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myIntType, 100, 101); err != nil { + t.Errorf("TagSet.Add(%s, %d, %d) returned error %v", myIntType.String(), 100, 101, err) + } + // Add myBoolType and [100, 101] to tags + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myBoolType, 100, 101); err == nil { + t.Errorf("TagSet.Add(%s, %d, %d) didn't return an error", myBoolType.String(), 100, 101) + } else if err.Error() != wantErrorMsg { + t.Errorf("TagSet.Add(%s, %d, %d) returned error msg %q, want %q", myBoolType, 100, 101, err, wantErrorMsg) + } +} + +func TestAddRemoveTag(t *testing.T) { + type myInt int + type myFloat float64 + myIntType := reflect.TypeOf(myInt(0)) + myFloatType := reflect.TypeOf(myFloat(0.0)) + pMyIntType := reflect.TypeOf((*myInt)(nil)) + pMyFloatType := reflect.TypeOf((*myFloat)(nil)) + + tags := NewTagSet() + stags := tags.(*syncTagSet) + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myIntType, 100); err != nil { + t.Errorf("TagSet.Add(%s, %d) returned error %v", myIntType.String(), 100, err) + } + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, myFloatType, 101); err != nil { + t.Errorf("TagSet.Add(%s, %d) returned error %v", myFloatType.String(), 101, err) + } + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, pMyIntType, 102); err == nil { + t.Errorf("TagSet.Add(%s, %d) didn't return an error", pMyIntType.String(), 102) + } + if err := tags.Add(TagOptions{DecTag: DecTagRequired, EncTag: EncTagRequired}, pMyFloatType, 103); err == nil { + t.Errorf("TagSet.Add(%s, %d) didn't return an error", pMyFloatType.String(), 103) + } + if len(stags.t) != 2 { + t.Errorf("TagSet len is %d, want %d", len(stags.t), 2) + } + tags.Remove(pMyIntType) + if len(stags.t) != 1 { + t.Errorf("TagSet len is %d, want %d", len(stags.t), 1) + } + tags.Remove(pMyFloatType) + if len(stags.t) != 0 { + t.Errorf("TagSet len is %d, want %d", len(stags.t), 0) + } + tags.Remove(myIntType) + tags.Remove(myFloatType) +} + +func TestAddTagTypeAliasError(t *testing.T) { + type myBool = bool + type myUint = uint + type myUint8 = uint8 + type myUint16 = uint16 + type myUint32 = uint32 + type myUint64 = uint64 + type myInt = int + type myInt8 = int8 + type myInt16 = int16 + type myInt32 = int32 + type myInt64 = int64 + type myFloat32 = float32 + type myFloat64 = float64 + type myString = string + type myByteSlice = []byte + type myIntSlice = []int + type myIntArray = [4]int + type myMapIntInt = map[int]int + + testCases := []struct { + name string + typ reflect.Type + wantErrorMsg string + }{ + { + name: "bool", + typ: reflect.TypeOf(myBool(false)), + wantErrorMsg: "cbor: can only add named types to TagSet, got bool", + }, + { + name: "uint", + typ: reflect.TypeOf(myUint(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got uint", + }, + { + name: "uint8", + typ: reflect.TypeOf(myUint8(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got uint8", + }, + { + name: "uint16", + typ: reflect.TypeOf(myUint16(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got uint16", + }, + { + name: "uint32", + typ: reflect.TypeOf(myUint32(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got uint32", + }, + { + name: "uint64", + typ: reflect.TypeOf(myUint64(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got uint64", + }, + { + name: "int", + typ: reflect.TypeOf(myInt(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got int", + }, + { + name: "int8", + typ: reflect.TypeOf(myInt8(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got int8", + }, + { + name: "int16", + typ: reflect.TypeOf(myInt16(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got int16", + }, + { + name: "int32", + typ: reflect.TypeOf(myInt32(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got int32", + }, + { + name: "int64", + typ: reflect.TypeOf(myInt64(0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got int64", + }, + { + name: "float32", + typ: reflect.TypeOf(myFloat32(0.0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got float32", + }, + { + name: "float64", + typ: reflect.TypeOf(myFloat64(0.0)), + wantErrorMsg: "cbor: can only add named types to TagSet, got float64", + }, + { + name: "string", + typ: reflect.TypeOf(myString("")), + wantErrorMsg: "cbor: can only add named types to TagSet, got string", + }, + { + name: "[]byte", + typ: reflect.TypeOf(myByteSlice([]byte{})), //nolint:unconvert + wantErrorMsg: "cbor: can only add named types to TagSet, got []uint8", + }, + { + name: "[]int", + typ: reflect.TypeOf(myIntSlice([]int{})), //nolint:unconvert + wantErrorMsg: "cbor: can only add named types to TagSet, got []int", + }, + { + name: "[4]int", + typ: reflect.TypeOf(myIntArray([4]int{})), //nolint:unconvert + wantErrorMsg: "cbor: can only add named types to TagSet, got [4]int", + }, + { + name: "map[int]int", + typ: reflect.TypeOf(myMapIntInt(map[int]int{})), //nolint:unconvert + wantErrorMsg: "cbor: can only add named types to TagSet, got map[int]int", + }, + } + + tags := NewTagSet() + for i, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, tc.typ, uint64(100+i)); err == nil { + t.Errorf("TagSet.Add(%s, %d) didn't return an error", tc.typ.String(), 0) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("TagSet.Add(%s, %d) returned error msg %q, want %q", tc.typ.String(), 0, err, tc.wantErrorMsg) + } + }) + } +} + +// TestDecodeTag decodes tag data with DecTagRequired/EncTagOptional/EncTagNone options. +func TestDecodeTagData(t *testing.T) { + type myInt int + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + } + + type tagInfo struct { + t reflect.Type + n []uint64 + } + tagInfos := []tagInfo{ + {reflect.TypeOf((*number)(nil)), []uint64{123}}, // BinaryMarshaler *number + {reflect.TypeOf(stru{}), []uint64{124}}, // BinaryMarshaler stru + {reflect.TypeOf(myInt(0)), []uint64{125}}, // non-struct type + {reflect.TypeOf(s{}), []uint64{126}}, // struct type + } + + tagsDecRequired := NewTagSet() + tagsDecOptional := NewTagSet() + tagsDecIgnored := NewTagSet() + for _, tag := range tagInfos { + if err := tagsDecRequired.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + if err := tagsDecOptional.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagOptional}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + if err := tagsDecIgnored.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagIgnored}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + } + + type tag struct { + name string + tagSet TagSet + } + tags := []tag{ + {"EncTagRequired_DecTagRequired", tagsDecRequired}, + {"EncTagRequired_DecTagOptional", tagsDecOptional}, + {"EncTagRequired_DecTagIgnored", tagsDecIgnored}, + } + + testCases := []roundTripTest{ + { + name: "BinaryMarshaler non-struct", + obj: number(1234567890), + wantCborData: hexDecode("d87b4800000000499602d2"), + }, + { + name: "BinaryMarshaler struct", + obj: stru{a: "a", b: "b", c: "c"}, + wantCborData: hexDecode("d87c45612C622C63"), + }, + { + name: "non-struct", + obj: myInt(1), + wantCborData: hexDecode("d87d01"), + }, + { + name: "struct", + obj: s{A: "A", B: "B", C: "C"}, + wantCborData: hexDecode("d87ea3616161416162614261636143"), // {"a":"A", "b":"B", "c":"C"} + }, + } + for _, tag := range tags { + t.Run(tag.name, func(t *testing.T) { + em, _ := EncOptions{}.EncModeWithTags(tag.tagSet) + dm, _ := DecOptions{}.DecModeWithTags(tag.tagSet) + testRoundTrip(t, testCases, em, dm) + }) + } +} + +// TestDecodeNoTag decodes no-tag data with DecTagRequired/EncTagOptional/EncTagNone options +func TestDecodeNoTagData(t *testing.T) { + type myInt int + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + } + + type tagInfo struct { + t reflect.Type + n []uint64 + } + tagInfos := []tagInfo{ + {reflect.TypeOf((*number)(nil)), []uint64{123}}, // BinaryMarshaler *number + {reflect.TypeOf(stru{}), []uint64{124}}, // BinaryMarshaler stru + {reflect.TypeOf(myInt(0)), []uint64{125}}, // non-struct type + {reflect.TypeOf(s{}), []uint64{126}}, // struct type + } + + tagsDecRequired := NewTagSet() + tagsDecOptional := NewTagSet() + for _, tag := range tagInfos { + if err := tagsDecRequired.Add(TagOptions{EncTag: EncTagNone, DecTag: DecTagRequired}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + if err := tagsDecOptional.Add(TagOptions{EncTag: EncTagNone, DecTag: DecTagOptional}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + } + + type tag struct { + name string + tagSet TagSet + } + tags := []tag{ + {"EncTagIgnored_DecTagOptional", tagsDecOptional}, + } + + testCases := []roundTripTest{ + { + name: "BinaryMarshaler non-struct", + obj: number(1234567890), + wantCborData: hexDecode("4800000000499602d2"), + }, + { + name: "BinaryMarshaler struct", + obj: stru{a: "a", b: "b", c: "c"}, + wantCborData: hexDecode("45612C622C63"), + }, + { + name: "non-struct", + obj: myInt(1), + wantCborData: hexDecode("01"), + }, + { + name: "struct", + obj: s{A: "A", B: "B", C: "C"}, + wantCborData: hexDecode("a3616161416162614261636143"), // {"a":"A", "b":"B", "c":"C"} + }, + } + + for _, tag := range tags { + t.Run(tag.name, func(t *testing.T) { + em, _ := EncOptions{}.EncModeWithTags(tag.tagSet) + dm, _ := DecOptions{}.DecModeWithTags(tag.tagSet) + testRoundTrip(t, testCases, em, dm) + }) + } + + // Decode non-tag data with DecTagRequired option returns UnmarshalTypeError + for _, tc := range testCases { + name := "EncTagIgnored_DecTagRequired " + tc.name + t.Run(name, func(t *testing.T) { + dm, _ := DecOptions{}.DecModeWithTags(tagsDecRequired) + v := reflect.New(reflect.TypeOf(tc.obj)) + if err := dm.Unmarshal(tc.wantCborData, v.Interface()); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.wantCborData) + } else { + if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*UnmarshalTypeError)", tc.wantCborData, err) + } else if !strings.Contains(err.Error(), "expect CBOR tag value") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", tc.wantCborData, err.Error(), "expect CBOR tag value") + } + } + }) + } +} + +// TestDecodeWrongTag decodes wrong tag data with DecTagRequired/EncTagOptional/EncTagNone options +func TestDecodeWrongTag(t *testing.T) { + type myInt int + type s struct { + A string `cbor:"a"` + B string `cbor:"b"` + C string `cbor:"c"` + } + + type tagInfo struct { + t reflect.Type + n []uint64 + } + tagInfos := []tagInfo{ + {reflect.TypeOf((*number)(nil)), []uint64{123}}, // BinaryMarshaler *number + {reflect.TypeOf(stru{}), []uint64{124}}, // BinaryMarshaler stru + {reflect.TypeOf(myInt(0)), []uint64{100}}, // non-struct type + {reflect.TypeOf(s{}), []uint64{101, 102}}, // struct type + } + + tagsDecRequired := NewTagSet() + tagsDecOptional := NewTagSet() + tagsDecIgnored := NewTagSet() + for _, tag := range tagInfos { + if err := tagsDecRequired.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + if err := tagsDecOptional.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagOptional}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + if err := tagsDecIgnored.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagIgnored}, tag.t, tag.n[0], tag.n[1:]...); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", tag.t, tag.n, err) + } + } + type tag struct { + name string + tagSet TagSet + } + tags := []tag{ + {"EncTagRequired_DecTagRequired", tagsDecRequired}, + {"EncTagRequired_DecTagOptional", tagsDecOptional}, + } + + testCases := []struct { + name string + obj interface{} + cborData []byte + wantErrorMsg string + }{ + { + name: "BinaryMarshaler non-struct", + obj: number(1234567890), + cborData: hexDecode("d87d4800000000499602d2"), + wantErrorMsg: "cbor: wrong tag number for cbor.number, got [125], expected [123]", + }, + { + name: "BinaryMarshaler struct", + obj: stru{a: "a", b: "b", c: "c"}, + cborData: hexDecode("d87d45612C622C63"), + wantErrorMsg: "cbor: wrong tag number for cbor.stru, got [125], expected [124]", + }, + { + name: "non-struct", + obj: myInt(1), + cborData: hexDecode("d87d01"), + wantErrorMsg: "cbor: wrong tag number for cbor.myInt, got [125], expected [100]", + }, + { + name: "struct", + obj: s{A: "A", B: "B", C: "C"}, + cborData: hexDecode("d87ea3616161416162614261636143"), // {"a":"A", "b":"B", "c":"C"} + wantErrorMsg: "cbor: wrong tag number for cbor.s, got [126], expected [101 102]", + }, + } + + for _, tc := range testCases { + for _, tag := range tags { + name := tag.name + " " + tc.name + t.Run(name, func(t *testing.T) { + dm, _ := DecOptions{}.DecModeWithTags(tag.tagSet) + v := reflect.New(reflect.TypeOf(tc.obj)) + if err := dm.Unmarshal(tc.cborData, v.Interface()); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", tc.cborData) + } else { + if _, ok := err.(*WrongTagError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong type of error %T, want (*WrongTagError)", tc.cborData, err) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want error %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + } + }) + } + } + + // Decode wrong tag data with DecTagIgnored option returns no error. + for _, tc := range testCases { + name := "EncTagRequired_DecTagIgnored " + tc.name + t.Run(name, func(t *testing.T) { + dm, _ := DecOptions{}.DecModeWithTags(tagsDecIgnored) + v := reflect.New(reflect.TypeOf(tc.obj)) + if err := dm.Unmarshal(tc.cborData, v.Interface()); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + if !reflect.DeepEqual(tc.obj, v.Elem().Interface()) { + t.Errorf("Marshal-Unmarshal returned different values: %v, %v", tc.obj, v.Elem().Interface()) + } + }) + } +} + +func TestEncodeSharedTag(t *testing.T) { + type myInt int + + myIntType := reflect.TypeOf(myInt(0)) + + sharedTagSet := NewTagSet() + + em, err := EncOptions{}.EncModeWithSharedTags(sharedTagSet) + if err != nil { + t.Errorf("EncModeWithSharedTags() returned error %v", err) + } + + // Register myInt type with tag number 123 + if err = sharedTagSet.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, myIntType, 123); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", myIntType, 100, err) + } + + // Encode myInt with tag number 123 + v := myInt(1) + wantCborData := hexDecode("d87b01") + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, wantCborData) + } + + // Unregister myInt type + sharedTagSet.Remove(myIntType) + + // Encode myInt without tag number 123 + v = myInt(2) + wantCborData = hexDecode("02") + b, err = em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, wantCborData) + } + + // Register myInt type with tag number 234 + if err = sharedTagSet.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, myIntType, 234); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", myIntType, 100, err) + } + + // Encode myInt with tag number 234 + v = myInt(3) + wantCborData = hexDecode("d8ea03") + b, err = em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, wantCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, wantCborData) + } + +} + +func TestDecodeSharedTag(t *testing.T) { + type myInt int + + myIntType := reflect.TypeOf(myInt(0)) + + sharedTagSet := NewTagSet() + + dm, err := DecOptions{}.DecModeWithSharedTags(sharedTagSet) + if err != nil { + t.Errorf("DecModeWithSharedTags() returned error %v", err) + } + + // Register myInt type with tag number 123 + if err = sharedTagSet.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, myIntType, 123); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", myIntType, 100, err) + } + + // Decode myInt with tag number 123 + var v myInt + wantV := myInt(1) + cborData := hexDecode("d87b01") + if err = dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantV, wantV) + } + + // Unregister myInt type + sharedTagSet.Remove(myIntType) + + // Decode myInt without tag number + wantV = myInt(2) + cborData = hexDecode("02") + if err := dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantV, wantV) + } + + // Register myInt type with tag number 234 + if err := sharedTagSet.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, myIntType, 234); err != nil { + t.Fatalf("TagSet.Add(%s, %v) returned error %v", myIntType, 100, err) + } + + // Decode myInt with tag number 234 + wantV = myInt(3) + cborData = hexDecode("d8ea03") + if err := dm.Unmarshal(cborData, &v); err != nil { + t.Errorf("Unmarshal(0x%x) returned error %v", cborData, err) + } + if !reflect.DeepEqual(v, wantV) { + t.Errorf("Unmarshal(0x%x) = %v (%T), want %v (%T)", cborData, v, v, wantV, wantV) + } +} + +func TestDecModeWithTagsError(t *testing.T) { + // Create DecMode with nil as TagSet + wantErrorMsg := "cbor: cannot create DecMode with nil value as TagSet" + dm, err := DecOptions{}.DecModeWithTags(nil) + if dm != nil { + t.Errorf("DecModeWithTags(nil) returned %v", dm) + } + if err.Error() != wantErrorMsg { + t.Errorf("DecModeWithTags(nil) returned error %q, want %q", err.Error(), wantErrorMsg) + } + dm, err = DecOptions{}.DecModeWithSharedTags(nil) + if dm != nil { + t.Errorf("DecModeWithSharedTags(nil) returned %v", dm) + } + if err.Error() != wantErrorMsg { + t.Errorf("DecModeWithSharedTags(nil) returned error %q, want %q", err.Error(), wantErrorMsg) + } + + // Create DecMode with invalid EncOptions + wantErrorMsg = "cbor: invalid TimeTag 100" + dm, err = DecOptions{TimeTag: 100}.DecModeWithTags(NewTagSet()) + if dm != nil { + t.Errorf("DecModeWithTags() returned %v", dm) + } + if err.Error() != wantErrorMsg { + t.Errorf("DecModeWithTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } + dm, err = DecOptions{TimeTag: 100}.DecModeWithSharedTags(NewTagSet()) + if dm != nil { + t.Errorf("DecModeWithSharedTags() returned %v", dm) + } + if err.Error() != wantErrorMsg { + t.Errorf("DecModeWithSharedTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestEncModeWithTagsError(t *testing.T) { + // Create EncMode with nil as TagSet + wantErrorMsg := "cbor: cannot create EncMode with nil value as TagSet" + em, err := EncOptions{}.EncModeWithTags(nil) + if em != nil { + t.Errorf("EncModeWithTags(nil) returned %v", em) + } + if err.Error() != wantErrorMsg { + t.Errorf("EncModeWithTags(nil) returned error %q, want %q", err.Error(), wantErrorMsg) + } + em, err = EncOptions{}.EncModeWithSharedTags(nil) + if em != nil { + t.Errorf("EncModeWithSharedTags(nil) returned %v", em) + } + if err.Error() != wantErrorMsg { + t.Errorf("EncModeWithSharedTags(nil) returned error %q, want %q", err.Error(), wantErrorMsg) + } + + // Create EncMode with invalid EncOptions + wantErrorMsg = "cbor: invalid TimeTag 100" + em, err = EncOptions{TimeTag: 100}.EncModeWithTags(NewTagSet()) + if em != nil { + t.Errorf("EncModeWithTags() returned %v", em) + } + if err.Error() != wantErrorMsg { + t.Errorf("EncModeWithTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } + em, err = EncOptions{TimeTag: 100}.EncModeWithSharedTags(NewTagSet()) + if em != nil { + t.Errorf("EncModeWithSharedTags() returned %v", em) + } + if err.Error() != wantErrorMsg { + t.Errorf("EncModeWithSharedTags() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestNilRawTagUnmarshalCBORError(t *testing.T) { + wantErrorMsg := "cbor.RawTag: UnmarshalCBOR on nil pointer" + var tag *RawTag + cborData := hexDecode("c249010000000000000000") + if err := tag.UnmarshalCBOR(cborData); err == nil { + t.Errorf("UnmarshalCBOR() didn't return error") + } else if err.Error() != wantErrorMsg { + t.Errorf("UnmarshalCBOR() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestTagUnmarshalError(t *testing.T) { + cborData := hexDecode("d87b61fe") // invalid UTF-8 string + var tag Tag + if err := Unmarshal(cborData, &tag); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return error", cborData) + } else if err.Error() != invalidUTF8ErrorMsg { + t.Errorf("Unmarshal(0x%x) returned error %q, want %q", cborData, err.Error(), invalidUTF8ErrorMsg) + } +} + +func TestTagMarshalError(t *testing.T) { + wantErrorMsg := "cbor: unsupported type: chan bool" + tag := Tag{ + Number: 123, + Content: make(chan bool), + } + if _, err := Marshal(tag); err == nil { + t.Errorf("Marshal() didn't return error") + } else if err.Error() != wantErrorMsg { + t.Errorf("Marshal() returned error %q, want %q", err.Error(), wantErrorMsg) + } +} + +func TestMarshalUninitializedTag(t *testing.T) { + var v Tag + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, cborNil) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, cborNil) + } +} + +func TestMarshalUninitializedRawTag(t *testing.T) { + var v RawTag + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, cborNil) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, cborNil) + } +} + +func TestMarshalTagWithEmptyContent(t *testing.T) { + v := Tag{Number: 100} // Tag.Content is empty + want := hexDecode("d864f6") // 100(null) + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } +} + +func TestMarshalRawTagWithEmptyContent(t *testing.T) { + v := RawTag{Number: 100} // RawTag.Content is empty + want := hexDecode("d864f6") // 100(null) + b, err := Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, want) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, want) + } +} + +func TestEncodeTag(t *testing.T) { + m := make(map[interface{}]bool) + m[10] = true + m[100] = true + m[-1] = true + m["z"] = true + m["aa"] = true + m[[1]int{100}] = true + m[[1]int{-1}] = true + m[false] = true + + v := Tag{100, m} + + lenFirstSortedCborData := hexDecode("d864a80af520f5f4f51864f5617af58120f5626161f5811864f5") // tag number: 100, value: map with sorted keys: 10, -1, false, 100, "z", [-1], "aa", [100] + bytewiseSortedCborData := hexDecode("d864a80af51864f520f5617af5626161f5811864f58120f5f4f5") // tag number: 100, value: map with sorted keys: 10, 100, -1, "z", "aa", [100], [-1], false + + em, _ := EncOptions{Sort: SortLengthFirst}.EncMode() + b, err := em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, lenFirstSortedCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, lenFirstSortedCborData) + } + + em, _ = EncOptions{Sort: SortBytewiseLexical}.EncMode() + b, err = em.Marshal(v) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v, err) + } + if !bytes.Equal(b, bytewiseSortedCborData) { + t.Errorf("Marshal(%v) = 0x%x, want 0x%x", v, b, bytewiseSortedCborData) + } +} + +func TestDecodeTagToEmptyIface(t *testing.T) { + type myBool bool + type myUint uint + + typeMyBool := reflect.TypeOf(myBool(false)) + typeMyUint := reflect.TypeOf(myUint(0)) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, typeMyBool, 100); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", typeMyBool, 100, err) + } + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, typeMyUint, 101, 102); err != nil { + t.Fatalf("TagSet.Add(%s, %d, %d) returned error %v", typeMyUint, 101, 102, err) + } + + dm, _ := DecOptions{}.DecModeWithTags(tags) + dmSharedTags, _ := DecOptions{}.DecModeWithSharedTags(tags) + + testCases := []struct { + name string + cborData []byte + wantObj interface{} + }{ + { + name: "registered myBool", + cborData: hexDecode("d864f5"), // 100(true) + wantObj: myBool(true), + }, + { + name: "registered myUint", + cborData: hexDecode("d865d86600"), // 101(102(0)) + wantObj: myUint(0), + }, + { + name: "not registered bool", + cborData: hexDecode("d865f5"), // 101(true) + wantObj: Tag{101, true}, + }, + { + name: "not registered uint", + cborData: hexDecode("d865d86700"), // 101(103(0)) + wantObj: Tag{101, Tag{103, uint64(0)}}, + }, + { + name: "not registered uint", + cborData: hexDecode("d865d866d86700"), // 101(102(103(0))) + wantObj: Tag{101, Tag{102, Tag{103, uint64(0)}}}, + }, + } + + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + var v1 interface{} + if err := dm.Unmarshal(tc.cborData, &v1); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + if !reflect.DeepEqual(tc.wantObj, v1) { + t.Errorf("Unmarshal to interface{} returned different values: %v, %v", tc.wantObj, v1) + } + + var v2 interface{} + if err := dmSharedTags.Unmarshal(tc.cborData, &v2); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + if !reflect.DeepEqual(tc.wantObj, v2) { + t.Errorf("Unmarshal to interface{} returned different values: %v, %v", tc.wantObj, v2) + } + }) + } +} + +func TestDecodeRegisteredTagToEmptyIfaceError(t *testing.T) { + type myInt int + + typeMyInt := reflect.TypeOf(myInt(0)) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, typeMyInt, 101, 102); err != nil { + t.Fatalf("TagSet.Add(%s, %d, %d) returned error %v", typeMyInt, 101, 102, err) + } + + dm, _ := DecOptions{}.DecModeWithTags(tags) + + cborData := hexDecode("d865d8663bffffffffffffffff") // 101(102(-18446744073709551616)) + + var v interface{} + if err := dm.Unmarshal(cborData, &v); err == nil { + t.Errorf("Unmarshal(0x%x) didn't return an error", cborData) + } else if _, ok := err.(*UnmarshalTypeError); !ok { + t.Errorf("Unmarshal(0x%x) returned wrong error type %T, want (*UnmarshalTypeError)", cborData, err) + } else if !strings.Contains(err.Error(), "cannot unmarshal") { + t.Errorf("Unmarshal(0x%x) returned error %q, want error containing %q", cborData, err.Error(), "cannot unmarshal") + } +} + +type number3 uint64 + +// MarshalCBOR marshals number3 to CBOR tagged map (tag number 100) +func (n number3) MarshalCBOR() (data []byte, err error) { + m := map[string]uint64{"num": uint64(n)} + return Marshal(Tag{100, m}) +} + +// UnmarshalCBOR unmarshals CBOR tagged map to number3 +func (n *number3) UnmarshalCBOR(data []byte) (err error) { + var rawTag RawTag + if err := Unmarshal(data, &rawTag); err != nil { + return err + } + + if rawTag.Number != 100 { + return fmt.Errorf("wrong tag number %d, want %d", rawTag.Number, 100) + } + + if rawTag.Content[0]&0xe0 != 0xa0 { + return fmt.Errorf("wrong tag content type, want map") + } + + var v map[string]uint64 + if err := Unmarshal(rawTag.Content, &v); err != nil { + return err + } + *n = number3(v["num"]) + return nil +} + +func TestDecodeRegisterTagForUnmarshaler(t *testing.T) { + typ := reflect.TypeOf(number3(0)) + + tags := NewTagSet() + if err := tags.Add(TagOptions{EncTag: EncTagRequired, DecTag: DecTagRequired}, typ, 100); err != nil { + t.Fatalf("TagSet.Add(%s, %d) returned error %v", typ, 100, err) + } + + cborData := hexDecode("d864a1636e756d01") // 100({"num": 1}) + wantObj := number3(1) + + dm, _ := DecOptions{}.DecModeWithTags(tags) + em, _ := EncOptions{}.EncModeWithTags(tags) + + // Decode to empty interface. Unmarshal() should return object of registered type. + var v1 interface{} + if err := dm.Unmarshal(cborData, &v1); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + if !reflect.DeepEqual(wantObj, v1) { + t.Errorf("Unmarshal() returned different values: %v (%T), %v (%T)", wantObj, wantObj, v1, v1) + } + b, err := em.Marshal(v1) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v1, err) + } else if !bytes.Equal(b, cborData) { + t.Errorf("Marshal(%v) returned %v, want %v", v1, b, cborData) + } + + // Decode to registered type. + var v2 number3 + if err = dm.Unmarshal(cborData, &v2); err != nil { + t.Errorf("Unmarshal() returned error %v", err) + } + if !reflect.DeepEqual(wantObj, v2) { + t.Errorf("Unmarshal() returned different values: %v, %v", wantObj, v2) + } + b, err = em.Marshal(v2) + if err != nil { + t.Errorf("Marshal(%v) returned error %v", v2, err) + } else if !bytes.Equal(b, cborData) { + t.Errorf("Marshal(%v) returned %v, want %v", v2, b, cborData) + } +} diff --git a/vendor/github.com/fxamacker/cbor/valid.go b/vendor/github.com/fxamacker/cbor/valid.go new file mode 100644 index 0000000..f775afb --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/valid.go @@ -0,0 +1,300 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "encoding/binary" + "errors" + "io" + "strconv" +) + +// SyntaxError is a description of a CBOR syntax error. +type SyntaxError struct { + msg string +} + +func (e *SyntaxError) Error() string { return e.msg } + +// SemanticError is a description of a CBOR semantic error. +type SemanticError struct { + msg string +} + +func (e *SemanticError) Error() string { return e.msg } + +// MaxNestedLevelError indicates exceeded max nested level of any combination of CBOR arrays/maps/tags. +type MaxNestedLevelError struct { + maxNestedLevels int +} + +func (e *MaxNestedLevelError) Error() string { + return "cbor: exceeded max nested level " + strconv.Itoa(e.maxNestedLevels) +} + +// MaxArrayElementsError indicates exceeded max number of elements for CBOR arrays. +type MaxArrayElementsError struct { + maxArrayElements int +} + +func (e *MaxArrayElementsError) Error() string { + return "cbor: exceeded max number of elements " + strconv.Itoa(e.maxArrayElements) + " for CBOR array" +} + +// MaxMapPairsError indicates exceeded max number of key-value pairs for CBOR maps. +type MaxMapPairsError struct { + maxMapPairs int +} + +func (e *MaxMapPairsError) Error() string { + return "cbor: exceeded max number of key-value pairs " + strconv.Itoa(e.maxMapPairs) + " for CBOR map" +} + +// IndefiniteLengthError indicates found disallowed indefinite length items. +type IndefiniteLengthError struct { + t cborType +} + +func (e *IndefiniteLengthError) Error() string { + return "cbor: indefinite-length " + e.t.String() + " isn't allowed" +} + +// TagsMdError indicates found disallowed CBOR tags. +type TagsMdError struct { +} + +func (e *TagsMdError) Error() string { + return "cbor: CBOR tag isn't allowed" +} + +// valid checks whether the CBOR data is complete and well-formed. +func (d *decoder) valid() error { + if len(d.data) == d.off { + return io.EOF + } + _, err := d.validInternal(0) + return err +} + +// validInternal checks data's well-formedness and returns max depth and error. +func (d *decoder) validInternal(depth int) (int, error) { + t, ai, val, err := d.validHead() + if err != nil { + return 0, err + } + + switch t { + case cborTypeByteString, cborTypeTextString: + if ai == 31 { + if d.dm.indefLength == IndefLengthForbidden { + return 0, &IndefiniteLengthError{t} + } + return d.validIndefiniteString(t, depth) + } + valInt := int(val) + if valInt < 0 { + // Detect integer overflow + return 0, errors.New("cbor: " + t.String() + " length " + strconv.FormatUint(val, 10) + " is too large, causing integer overflow") + } + if len(d.data)-d.off < valInt { // valInt+off may overflow integer + return 0, io.ErrUnexpectedEOF + } + d.off += valInt + case cborTypeArray, cborTypeMap: + depth++ + if depth > d.dm.maxNestedLevels { + return 0, &MaxNestedLevelError{d.dm.maxNestedLevels} + } + + if ai == 31 { + if d.dm.indefLength == IndefLengthForbidden { + return 0, &IndefiniteLengthError{t} + } + return d.validIndefiniteArrayOrMap(t, depth) + } + + valInt := int(val) + if valInt < 0 { + // Detect integer overflow + return 0, errors.New("cbor: " + t.String() + " length " + strconv.FormatUint(val, 10) + " is too large, it would cause integer overflow") + } + + if t == cborTypeArray { + if valInt > d.dm.maxArrayElements { + return 0, &MaxArrayElementsError{d.dm.maxArrayElements} + } + } else { + if valInt > d.dm.maxMapPairs { + return 0, &MaxMapPairsError{d.dm.maxMapPairs} + } + } + + count := 1 + if t == cborTypeMap { + count = 2 + } + maxDepth := depth + for j := 0; j < count; j++ { + for i := 0; i < valInt; i++ { + var dpt int + if dpt, err = d.validInternal(depth); err != nil { + return 0, err + } + if dpt > maxDepth { + maxDepth = dpt // Save max depth + } + } + } + depth = maxDepth + case cborTypeTag: + if d.dm.tagsMd == TagsForbidden { + return 0, &TagsMdError{} + } + + // Scan nested tag numbers to avoid recursion. + for { + if len(d.data) == d.off { // Tag number must be followed by tag content. + return 0, io.ErrUnexpectedEOF + } + if cborType(d.data[d.off]&0xe0) != cborTypeTag { + break + } + if _, _, _, err = d.validHead(); err != nil { + return 0, err + } + depth++ + if depth > d.dm.maxNestedLevels { + return 0, &MaxNestedLevelError{d.dm.maxNestedLevels} + } + } + // Check tag content. + return d.validInternal(depth) + } + return depth, nil +} + +// validIndefiniteString checks indefinite length byte/text string's well-formedness and returns max depth and error. +func (d *decoder) validIndefiniteString(t cborType, depth int) (int, error) { + var err error + for { + if len(d.data) == d.off { + return 0, io.ErrUnexpectedEOF + } + if d.data[d.off] == 0xff { + d.off++ + break + } + // Peek ahead to get next type and indefinite length status. + nt := cborType(d.data[d.off] & 0xe0) + if t != nt { + return 0, &SyntaxError{"cbor: wrong element type " + nt.String() + " for indefinite-length " + t.String()} + } + if (d.data[d.off] & 0x1f) == 31 { + return 0, &SyntaxError{"cbor: indefinite-length " + t.String() + " chunk is not definite-length"} + } + if depth, err = d.validInternal(depth); err != nil { + return 0, err + } + } + return depth, nil +} + +// validIndefiniteArrayOrMap checks indefinite length array/map's well-formedness and returns max depth and error. +func (d *decoder) validIndefiniteArrayOrMap(t cborType, depth int) (int, error) { + var err error + maxDepth := depth + i := 0 + for { + if len(d.data) == d.off { + return 0, io.ErrUnexpectedEOF + } + if d.data[d.off] == 0xff { + d.off++ + break + } + var dpt int + if dpt, err = d.validInternal(depth); err != nil { + return 0, err + } + if dpt > maxDepth { + maxDepth = dpt + } + i++ + if t == cborTypeArray { + if i > d.dm.maxArrayElements { + return 0, &MaxArrayElementsError{d.dm.maxArrayElements} + } + } else { + if i%2 == 0 && i/2 > d.dm.maxMapPairs { + return 0, &MaxMapPairsError{d.dm.maxMapPairs} + } + } + } + if t == cborTypeMap && i%2 == 1 { + return 0, &SyntaxError{"cbor: unexpected \"break\" code"} + } + return maxDepth, nil +} + +func (d *decoder) validHead() (t cborType, ai byte, val uint64, err error) { + dataLen := len(d.data) - d.off + if dataLen == 0 { + return 0, 0, 0, io.ErrUnexpectedEOF + } + + t = cborType(d.data[d.off] & 0xe0) + ai = d.data[d.off] & 0x1f + val = uint64(ai) + d.off++ + + if ai < 24 { + return t, ai, val, nil + } + if ai == 24 { + if dataLen < 2 { + return 0, 0, 0, io.ErrUnexpectedEOF + } + val = uint64(d.data[d.off]) + d.off++ + if t == cborTypePrimitives && val < 32 { + return 0, 0, 0, &SyntaxError{"cbor: invalid simple value " + strconv.Itoa(int(val)) + " for type " + t.String()} + } + return t, ai, val, nil + } + if ai == 25 { + if dataLen < 3 { + return 0, 0, 0, io.ErrUnexpectedEOF + } + val = uint64(binary.BigEndian.Uint16(d.data[d.off : d.off+2])) + d.off += 2 + return t, ai, val, nil + } + if ai == 26 { + if dataLen < 5 { + return 0, 0, 0, io.ErrUnexpectedEOF + } + val = uint64(binary.BigEndian.Uint32(d.data[d.off : d.off+4])) + d.off += 4 + return t, ai, val, nil + } + if ai == 27 { + if dataLen < 9 { + return 0, 0, 0, io.ErrUnexpectedEOF + } + val = binary.BigEndian.Uint64(d.data[d.off : d.off+8]) + d.off += 8 + return t, ai, val, nil + } + if ai == 31 { + switch t { + case cborTypePositiveInt, cborTypeNegativeInt, cborTypeTag: + return 0, 0, 0, &SyntaxError{"cbor: invalid additional information " + strconv.Itoa(int(ai)) + " for type " + t.String()} + case cborTypePrimitives: // 0xff (break code) should not be outside validIndefinite(). + return 0, 0, 0, &SyntaxError{"cbor: unexpected \"break\" code"} + } + return t, ai, val, nil + } + // ai == 28, 29, 30 + return 0, 0, 0, &SyntaxError{"cbor: invalid additional information " + strconv.Itoa(int(ai)) + " for type " + t.String()} +} diff --git a/vendor/github.com/fxamacker/cbor/valid_test.go b/vendor/github.com/fxamacker/cbor/valid_test.go new file mode 100644 index 0000000..109ca2c --- /dev/null +++ b/vendor/github.com/fxamacker/cbor/valid_test.go @@ -0,0 +1,157 @@ +// Copyright (c) Faye Amacker. All rights reserved. +// Licensed under the MIT License. See LICENSE in the project root for license information. + +package cbor + +import ( + "bytes" + "testing" +) + +func TestValid1(t *testing.T) { + for _, mt := range marshalTests { + if err := Valid(mt.cborData); err != nil { + t.Errorf("Valid() returned error %v", err) + } + } +} + +func TestValid2(t *testing.T) { + for _, mt := range marshalTests { + dm, _ := DecOptions{DupMapKey: DupMapKeyEnforcedAPF}.DecMode() + if err := dm.Valid(mt.cborData); err != nil { + t.Errorf("Valid() returned error %v", err) + } + } +} + +func TestValidOnStreamingData(t *testing.T) { + var buf bytes.Buffer + for _, t := range marshalTests { + buf.Write(t.cborData) + } + d := decoder{data: buf.Bytes(), dm: defaultDecMode} + for i := 0; i < len(marshalTests); i++ { + if err := d.valid(); err != nil { + t.Errorf("valid() returned error %v", err) + } + } +} + +func TestDepth(t *testing.T) { + testCases := []struct { + name string + cborData []byte + wantDepth int + }{ + {"uint", hexDecode("00"), 0}, // 0 + {"int", hexDecode("20"), 0}, // -1 + {"bool", hexDecode("f4"), 0}, // false + {"nil", hexDecode("f6"), 0}, // nil + {"float", hexDecode("fa47c35000"), 0}, // 100000.0 + {"byte string", hexDecode("40"), 0}, // []byte{} + {"indefinite length byte string", hexDecode("5f42010243030405ff"), 0}, // []byte{1, 2, 3, 4, 5} + {"text string", hexDecode("60"), 0}, // "" + {"indefinite length text string", hexDecode("7f657374726561646d696e67ff"), 0}, // "streaming" + {"empty array", hexDecode("80"), 1}, // [] + {"indefinite length empty array", hexDecode("9fff"), 1}, // [] + {"array", hexDecode("98190102030405060708090a0b0c0d0e0f101112131415161718181819"), 1}, // [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25] + {"indefinite length array", hexDecode("9f0102030405060708090a0b0c0d0e0f101112131415161718181819ff"), 1}, // [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25] + {"nested array", hexDecode("8301820203820405"), 2}, // [1,[2,3],[4,5]] + {"indefinite length nested array", hexDecode("83018202039f0405ff"), 2}, // [1,[2,3],[4,5]] + {"array and map", hexDecode("826161a161626163"), 2}, // [a", {"b": "c"}] + {"indefinite length array and map", hexDecode("826161bf61626163ff"), 2}, // [a", {"b": "c"}] + {"empty map", hexDecode("a0"), 1}, // {} + {"indefinite length empty map", hexDecode("bfff"), 1}, // {} + {"map", hexDecode("a201020304"), 1}, // {1:2, 3:4} + {"nested map", hexDecode("a26161016162820203"), 2}, // {"a": 1, "b": [2, 3]} + {"indefinite length nested map", hexDecode("bf61610161629f0203ffff"), 2}, // {"a": 1, "b": [2, 3]} + {"tag", hexDecode("c074323031332d30332d32315432303a30343a30305a"), 0}, // 0("2013-03-21T20:04:00Z") + {"tagged map", hexDecode("d864a26161016162820203"), 2}, // 100({"a": 1, "b": [2, 3]}) + {"tagged map and array", hexDecode("d864a26161016162d865820203"), 2}, // 100({"a": 1, "b": 101([2, 3])}) + {"tagged map and array", hexDecode("d864a26161016162d865d866820203"), 3}, // 100({"a": 1, "b": 101(102([2, 3]))}) + {"nested tag", hexDecode("d864d865d86674323031332d30332d32315432303a30343a30305a"), 2}, // 100(101(102("2013-03-21T20:04:00Z"))) + {"32-level array", hexDecode("82018181818181818181818181818181818181818181818181818181818181818101"), 32}, + {"32-level indefinite length array", hexDecode("9f018181818181818181818181818181818181818181818181818181818181818101ff"), 32}, + {"32-level map", hexDecode("a1018181818181818181818181818181818181818181818181818181818181818101"), 32}, + {"32-level indefinite length map", hexDecode("bf018181818181818181818181818181818181818181818181818181818181818101ff"), 32}, + {"32-level tag", hexDecode("d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d86474323031332d30332d32315432303a30343a30305a"), 32}, // 100(100(...("2013-03-21T20:04:00Z"))) + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + d := decoder{data: tc.cborData, dm: defaultDecMode} + depth, err := d.validInternal(0) + if err != nil { + t.Errorf("valid(0x%x) returned error %v", tc.cborData, err) + } + if depth != tc.wantDepth { + t.Errorf("valid(0x%x) returned depth %d, want %d", tc.cborData, depth, tc.wantDepth) + } + }) + } +} + +func TestDepthError(t *testing.T) { + testCases := []struct { + name string + cborData []byte + opts DecOptions + wantErrorMsg string + }{ + { + name: "33-level array", + cborData: hexDecode("82018181818181818181818181818181818181818181818181818181818181818101"), + opts: DecOptions{MaxNestedLevels: 4}, + wantErrorMsg: "cbor: exceeded max nested level 4", + }, + { + name: "33-level array", + cborData: hexDecode("82018181818181818181818181818181818181818181818181818181818181818101"), + opts: DecOptions{MaxNestedLevels: 10}, + wantErrorMsg: "cbor: exceeded max nested level 10", + }, + { + name: "33-level array", + cborData: hexDecode("8201818181818181818181818181818181818181818181818181818181818181818101"), + opts: DecOptions{}, + wantErrorMsg: "cbor: exceeded max nested level 32", + }, + { + name: "33-level indefinite length array", + cborData: hexDecode("9f01818181818181818181818181818181818181818181818181818181818181818101ff"), + opts: DecOptions{}, + wantErrorMsg: "cbor: exceeded max nested level 32", + }, + { + name: "33-level map", + cborData: hexDecode("a101818181818181818181818181818181818181818181818181818181818181818101"), + opts: DecOptions{}, + wantErrorMsg: "cbor: exceeded max nested level 32", + }, + { + name: "33-level indefinite length map", + cborData: hexDecode("bf01818181818181818181818181818181818181818181818181818181818181818101ff"), + opts: DecOptions{}, + wantErrorMsg: "cbor: exceeded max nested level 32", + }, + { + name: "33-level tag", + cborData: hexDecode("d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d864d86474323031332d30332d32315432303a30343a30305a"), + opts: DecOptions{}, + wantErrorMsg: "cbor: exceeded max nested level 32", + }, + } + for _, tc := range testCases { + t.Run(tc.name, func(t *testing.T) { + dm, _ := tc.opts.decMode() + d := decoder{data: tc.cborData, dm: dm} + if _, err := d.validInternal(0); err == nil { + t.Errorf("valid(0x%x) didn't return an error", tc.cborData) + } else if _, ok := err.(*MaxNestedLevelError); !ok { + t.Errorf("valid(0x%x) returned wrong error type %T, want (*MaxNestedLevelError)", tc.cborData, err) + } else if err.Error() != tc.wantErrorMsg { + t.Errorf("valid(0x%x) returned error %q, want error %q", tc.cborData, err.Error(), tc.wantErrorMsg) + } + }) + } +} diff --git a/vendor/github.com/gdamore/encoding/.appveyor.yml b/vendor/github.com/gdamore/encoding/.appveyor.yml deleted file mode 100644 index 19a4c5d..0000000 --- a/vendor/github.com/gdamore/encoding/.appveyor.yml +++ /dev/null @@ -1,13 +0,0 @@ -version: 1.0.{build} -clone_folder: c:\gopath\src\github.com\gdamore\encoding -environment: - GOPATH: c:\gopath -build_script: -- go version -- go env -- SET PATH=%LOCALAPPDATA%\atom\bin;%GOPATH%\bin;%PATH% -- go get -t ./... -- go build -- go install ./... -test_script: -- go test ./... diff --git a/vendor/github.com/gdamore/encoding/.travis.yml b/vendor/github.com/gdamore/encoding/.travis.yml deleted file mode 100644 index 5042413..0000000 --- a/vendor/github.com/gdamore/encoding/.travis.yml +++ /dev/null @@ -1,7 +0,0 @@ -language: go - -go: - - 1.9.x - - 1.10.x - - 1.11.x - - tip diff --git a/vendor/github.com/gdamore/encoding/LICENSE b/vendor/github.com/gdamore/encoding/LICENSE deleted file mode 100644 index d645695..0000000 --- a/vendor/github.com/gdamore/encoding/LICENSE +++ /dev/null @@ -1,202 +0,0 @@ - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/vendor/github.com/gdamore/encoding/README.md b/vendor/github.com/gdamore/encoding/README.md deleted file mode 100644 index 3db2b4c..0000000 --- a/vendor/github.com/gdamore/encoding/README.md +++ /dev/null @@ -1,19 +0,0 @@ -## encoding - -[![Linux Status](https://img.shields.io/travis/gdamore/encoding.svg?label=linux)](https://travis-ci.org/gdamore/encoding) -[![Windows Status](https://img.shields.io/appveyor/ci/gdamore/encoding.svg?label=windows)](https://ci.appveyor.com/project/gdamore/encoding) -[![Apache License](https://img.shields.io/badge/license-APACHE2-blue.svg)](https://github.com/gdamore/encoding/blob/master/LICENSE) -[![GoDoc](https://img.shields.io/badge/godoc-reference-blue.svg)](https://godoc.org/github.com/gdamore/encoding) -[![Go Report Card](http://goreportcard.com/badge/gdamore/encoding)](http://goreportcard.com/report/gdamore/encoding) - -Package encoding provides a number of encodings that are missing from the -standard Go [encoding]("https://godoc.org/golang.org/x/text/encoding") package. - -We hope that we can contribute these to the standard Go library someday. It -turns out that some of these are useful for dealing with I/O streams coming -from non-UTF friendly sources. - -The UTF8 Encoder is also useful for situations where valid UTF-8 might be -carried in streams that contain non-valid UTF; in particular I use it for -helping me cope with terminals that embed escape sequences in otherwise -valid UTF-8. diff --git a/vendor/github.com/gdamore/encoding/ascii.go b/vendor/github.com/gdamore/encoding/ascii.go deleted file mode 100644 index b7321f4..0000000 --- a/vendor/github.com/gdamore/encoding/ascii.go +++ /dev/null @@ -1,36 +0,0 @@ -// Copyright 2015 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "golang.org/x/text/encoding" -) - -// ASCII represents the 7-bit US-ASCII scheme. It decodes directly to -// UTF-8 without change, as all ASCII values are legal UTF-8. -// Unicode values less than 128 (i.e. 7 bits) map 1:1 with ASCII. -// It encodes runes outside of that to 0x1A, the ASCII substitution character. -var ASCII encoding.Encoding - -func init() { - amap := make(map[byte]rune) - for i := 128; i <= 255; i++ { - amap[byte(i)] = RuneError - } - - cm := &Charmap{Map: amap} - cm.Init() - ASCII = cm -} diff --git a/vendor/github.com/gdamore/encoding/ascii_test.go b/vendor/github.com/gdamore/encoding/ascii_test.go deleted file mode 100644 index 23320b4..0000000 --- a/vendor/github.com/gdamore/encoding/ascii_test.go +++ /dev/null @@ -1,39 +0,0 @@ -// Copyright 2018 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "testing" -) - -func TestASCII(t *testing.T) { - t.Logf("ASCII identity transforms") - for i := 0; i < 128; i++ { - verifyMap(t, ASCII, byte(i), rune(i)) - } - - t.Logf("High order bytes map to RuneError") - for i := 128; i < 256; i++ { - verifyToUTF(t, ASCII, byte(i), RuneError) - } - - t.Logf("High order UTF maps to ASCIISub") - for i := 128; i < 256; i++ { - verifyFromUTF(t, ASCII, ASCIISub, rune(i)) - } - - t.Logf("Large UTF maps to ASCIISub") - verifyFromUTF(t, ASCII, ASCIISub, '㿿') -} diff --git a/vendor/github.com/gdamore/encoding/charmap.go b/vendor/github.com/gdamore/encoding/charmap.go deleted file mode 100644 index db1c33e..0000000 --- a/vendor/github.com/gdamore/encoding/charmap.go +++ /dev/null @@ -1,196 +0,0 @@ -// Copyright 2015 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "sync" - "unicode/utf8" - - "golang.org/x/text/encoding" - "golang.org/x/text/transform" -) - -const ( - // RuneError is an alias for the UTF-8 replacement rune, '\uFFFD'. - RuneError = '\uFFFD' - - // RuneSelf is the rune below which UTF-8 and the Unicode values are - // identical. Its also the limit for ASCII. - RuneSelf = 0x80 - - // ASCIISub is the ASCII substitution character. - ASCIISub = '\x1a' -) - -// Charmap is a structure for setting up encodings for 8-bit character sets, -// for transforming between UTF8 and that other character set. It has some -// ideas borrowed from golang.org/x/text/encoding/charmap, but it uses a -// different implementation. This implementation uses maps, and supports -// user-defined maps. -// -// We do assume that a character map has a reasonable substitution character, -// and that valid encodings are stable (exactly a 1:1 map) and stateless -// (that is there is no shift character or anything like that.) Hence this -// approach will not work for many East Asian character sets. -// -// Measurement shows little or no measurable difference in the performance of -// the two approaches. The difference was down to a couple of nsec/op, and -// no consistent pattern as to which ran faster. With the conversion to -// UTF-8 the code takes about 25 nsec/op. The conversion in the reverse -// direction takes about 100 nsec/op. (The larger cost for conversion -// from UTF-8 is most likely due to the need to convert the UTF-8 byte stream -// to a rune before conversion. -// -type Charmap struct { - transform.NopResetter - bytes map[rune]byte - runes [256][]byte - once sync.Once - - // The map between bytes and runes. To indicate that a specific - // byte value is invalid for a charcter set, use the rune - // utf8.RuneError. Values that are absent from this map will - // be assumed to have the identity mapping -- that is the default - // is to assume ISO8859-1, where all 8-bit characters have the same - // numeric value as their Unicode runes. (Not to be confused with - // the UTF-8 values, which *will* be different for non-ASCII runes.) - // - // If no values less than RuneSelf are changed (or have non-identity - // mappings), then the character set is assumed to be an ASCII - // superset, and certain assumptions and optimizations become - // available for ASCII bytes. - Map map[byte]rune - - // The ReplacementChar is the byte value to use for substitution. - // It should normally be ASCIISub for ASCII encodings. This may be - // unset (left to zero) for mappings that are strictly ASCII supersets. - // In that case ASCIISub will be assumed instead. - ReplacementChar byte -} - -type cmapDecoder struct { - transform.NopResetter - runes [256][]byte -} - -type cmapEncoder struct { - transform.NopResetter - bytes map[rune]byte - replace byte -} - -// Init initializes internal values of a character map. This should -// be done early, to minimize the cost of allocation of transforms -// later. It is not strictly necessary however, as the allocation -// functions will arrange to call it if it has not already been done. -func (c *Charmap) Init() { - c.once.Do(c.initialize) -} - -func (c *Charmap) initialize() { - c.bytes = make(map[rune]byte) - ascii := true - - for i := 0; i < 256; i++ { - r, ok := c.Map[byte(i)] - if !ok { - r = rune(i) - } - if r < 128 && r != rune(i) { - ascii = false - } - if r != RuneError { - c.bytes[r] = byte(i) - } - utf := make([]byte, utf8.RuneLen(r)) - utf8.EncodeRune(utf, r) - c.runes[i] = utf - } - if ascii && c.ReplacementChar == '\x00' { - c.ReplacementChar = ASCIISub - } -} - -// NewDecoder returns a Decoder the converts from the 8-bit -// character set to UTF-8. Unknown mappings, if any, are mapped -// to '\uFFFD'. -func (c *Charmap) NewDecoder() *encoding.Decoder { - c.Init() - return &encoding.Decoder{Transformer: &cmapDecoder{runes: c.runes}} -} - -// NewEncoder returns a Transformer that converts from UTF8 to the -// 8-bit character set. Unknown mappings are mapped to 0x1A. -func (c *Charmap) NewEncoder() *encoding.Encoder { - c.Init() - return &encoding.Encoder{ - Transformer: &cmapEncoder{ - bytes: c.bytes, - replace: c.ReplacementChar, - }, - } -} - -func (d *cmapDecoder) Transform(dst, src []byte, atEOF bool) (int, int, error) { - var e error - var ndst, nsrc int - - for _, c := range src { - b := d.runes[c] - l := len(b) - - if ndst+l > len(dst) { - e = transform.ErrShortDst - break - } - for i := 0; i < l; i++ { - dst[ndst] = b[i] - ndst++ - } - nsrc++ - } - return ndst, nsrc, e -} - -func (d *cmapEncoder) Transform(dst, src []byte, atEOF bool) (int, int, error) { - var e error - var ndst, nsrc int - for nsrc < len(src) { - if ndst >= len(dst) { - e = transform.ErrShortDst - break - } - - r, sz := utf8.DecodeRune(src[nsrc:]) - if r == utf8.RuneError && sz == 1 { - // If its inconclusive due to insufficient data in - // in the source, report it - if !atEOF && !utf8.FullRune(src[nsrc:]) { - e = transform.ErrShortSrc - break - } - } - - if c, ok := d.bytes[r]; ok { - dst[ndst] = c - } else { - dst[ndst] = d.replace - } - nsrc += sz - ndst++ - } - - return ndst, nsrc, e -} diff --git a/vendor/github.com/gdamore/encoding/common_test.go b/vendor/github.com/gdamore/encoding/common_test.go deleted file mode 100644 index ad6f54a..0000000 --- a/vendor/github.com/gdamore/encoding/common_test.go +++ /dev/null @@ -1,71 +0,0 @@ -// Copyright 2018 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "bytes" - "testing" - "unicode/utf8" - - "golang.org/x/text/encoding" -) - -func verifyMap(t *testing.T, enc encoding.Encoding, b byte, r rune) { - verifyFromUTF(t, enc, b, r) - verifyToUTF(t, enc, b, r) -} - -func verifyFromUTF(t *testing.T, enc encoding.Encoding, b byte, r rune) { - - encoder := enc.NewEncoder() - - out := make([]byte, 6) - utf := make([]byte, utf8.RuneLen(r)) - utf8.EncodeRune(utf, r) - - ndst, nsrc, err := encoder.Transform(out, utf, true) - if err != nil { - t.Errorf("Transform failed: %v", err) - } - if nsrc != len(utf) { - t.Errorf("Length of source incorrect: %d != %d", nsrc, len(utf)) - } - if ndst != 1 { - t.Errorf("Dest length (%d) != 1", ndst) - } - if b != out[0] { - t.Errorf("From UTF incorrect map %v != %v", b, out[0]) - } -} - -func verifyToUTF(t *testing.T, enc encoding.Encoding, b byte, r rune) { - decoder := enc.NewDecoder() - - out := make([]byte, 6) - nat := []byte{b} - utf := make([]byte, utf8.RuneLen(r)) - utf8.EncodeRune(utf, r) - - ndst, nsrc, err := decoder.Transform(out, nat, true) - if err != nil { - t.Errorf("Transform failed: %v", err) - } - if nsrc != 1 { - t.Errorf("Src length (%d) != 1", nsrc) - } - if !bytes.Equal(utf, out[:ndst]) { - t.Errorf("UTF expected %v, but got %v for %x\n", utf, out, b) - } -} diff --git a/vendor/github.com/gdamore/encoding/doc.go b/vendor/github.com/gdamore/encoding/doc.go deleted file mode 100644 index 8a7b48d..0000000 --- a/vendor/github.com/gdamore/encoding/doc.go +++ /dev/null @@ -1,17 +0,0 @@ -// Copyright 2015 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Package encoding provides a few of the encoding structures that are -// missing from the Go x/text/encoding tree. -package encoding diff --git a/vendor/github.com/gdamore/encoding/ebcdic.go b/vendor/github.com/gdamore/encoding/ebcdic.go deleted file mode 100644 index 8e13f1a..0000000 --- a/vendor/github.com/gdamore/encoding/ebcdic.go +++ /dev/null @@ -1,273 +0,0 @@ -// Copyright 2015 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "golang.org/x/text/encoding" -) - -// EBCDIC represents the 8-bit EBCDIC scheme, found in some mainframe -// environments. If you don't know what this is, consider yourself lucky. -var EBCDIC encoding.Encoding - -func init() { - cm := &Charmap{ - ReplacementChar: '\x3f', - Map: map[byte]rune{ - // 0x00-0x03 match - 0x04: RuneError, - 0x05: '\t', - 0x06: RuneError, - 0x07: '\x7f', - 0x08: RuneError, - 0x09: RuneError, - 0x0a: RuneError, - // 0x0b-0x13 match - 0x14: RuneError, - 0x15: '\x85', // Not in any ISO code - 0x16: '\x08', - 0x17: RuneError, - // 0x18-0x19 match - 0x1a: RuneError, - 0x1b: RuneError, - // 0x1c-0x1f match - 0x20: RuneError, - 0x21: RuneError, - 0x22: RuneError, - 0x23: RuneError, - 0x24: RuneError, - 0x25: '\n', - 0x26: '\x17', - 0x27: '\x1b', - 0x28: RuneError, - 0x29: RuneError, - 0x2a: RuneError, - 0x2b: RuneError, - 0x2c: RuneError, - 0x2d: '\x05', - 0x2e: '\x06', - 0x2f: '\x07', - 0x30: RuneError, - 0x31: RuneError, - 0x32: '\x16', - 0x33: RuneError, - 0x34: RuneError, - 0x35: RuneError, - 0x36: RuneError, - 0x37: '\x04', - 0x38: RuneError, - 0x39: RuneError, - 0x3a: RuneError, - 0x3b: RuneError, - 0x3c: '\x14', - 0x3d: '\x15', - 0x3e: RuneError, - 0x3f: '\x1a', // also replacement char - 0x40: ' ', - 0x41: '\xa0', - 0x42: RuneError, - 0x43: RuneError, - 0x44: RuneError, - 0x45: RuneError, - 0x46: RuneError, - 0x47: RuneError, - 0x48: RuneError, - 0x49: RuneError, - 0x4a: RuneError, - 0x4b: '.', - 0x4c: '<', - 0x4d: '(', - 0x4e: '+', - 0x4f: '|', - 0x50: '&', - 0x51: RuneError, - 0x52: RuneError, - 0x53: RuneError, - 0x54: RuneError, - 0x55: RuneError, - 0x56: RuneError, - 0x57: RuneError, - 0x58: RuneError, - 0x59: RuneError, - 0x5a: '!', - 0x5b: '$', - 0x5c: '*', - 0x5d: ')', - 0x5e: ';', - 0x5f: '¬', - 0x60: '-', - 0x61: '/', - 0x62: RuneError, - 0x63: RuneError, - 0x64: RuneError, - 0x65: RuneError, - 0x66: RuneError, - 0x67: RuneError, - 0x68: RuneError, - 0x69: RuneError, - 0x6a: '¦', - 0x6b: ',', - 0x6c: '%', - 0x6d: '_', - 0x6e: '>', - 0x6f: '?', - 0x70: RuneError, - 0x71: RuneError, - 0x72: RuneError, - 0x73: RuneError, - 0x74: RuneError, - 0x75: RuneError, - 0x76: RuneError, - 0x77: RuneError, - 0x78: RuneError, - 0x79: '`', - 0x7a: ':', - 0x7b: '#', - 0x7c: '@', - 0x7d: '\'', - 0x7e: '=', - 0x7f: '"', - 0x80: RuneError, - 0x81: 'a', - 0x82: 'b', - 0x83: 'c', - 0x84: 'd', - 0x85: 'e', - 0x86: 'f', - 0x87: 'g', - 0x88: 'h', - 0x89: 'i', - 0x8a: RuneError, - 0x8b: RuneError, - 0x8c: RuneError, - 0x8d: RuneError, - 0x8e: RuneError, - 0x8f: '±', - 0x90: RuneError, - 0x91: 'j', - 0x92: 'k', - 0x93: 'l', - 0x94: 'm', - 0x95: 'n', - 0x96: 'o', - 0x97: 'p', - 0x98: 'q', - 0x99: 'r', - 0x9a: RuneError, - 0x9b: RuneError, - 0x9c: RuneError, - 0x9d: RuneError, - 0x9e: RuneError, - 0x9f: RuneError, - 0xa0: RuneError, - 0xa1: '~', - 0xa2: 's', - 0xa3: 't', - 0xa4: 'u', - 0xa5: 'v', - 0xa6: 'w', - 0xa7: 'x', - 0xa8: 'y', - 0xa9: 'z', - 0xaa: RuneError, - 0xab: RuneError, - 0xac: RuneError, - 0xad: RuneError, - 0xae: RuneError, - 0xaf: RuneError, - 0xb0: '^', - 0xb1: RuneError, - 0xb2: RuneError, - 0xb3: RuneError, - 0xb4: RuneError, - 0xb5: RuneError, - 0xb6: RuneError, - 0xb7: RuneError, - 0xb8: RuneError, - 0xb9: RuneError, - 0xba: '[', - 0xbb: ']', - 0xbc: RuneError, - 0xbd: RuneError, - 0xbe: RuneError, - 0xbf: RuneError, - 0xc0: '{', - 0xc1: 'A', - 0xc2: 'B', - 0xc3: 'C', - 0xc4: 'D', - 0xc5: 'E', - 0xc6: 'F', - 0xc7: 'G', - 0xc8: 'H', - 0xc9: 'I', - 0xca: '\xad', // NB: soft hyphen - 0xcb: RuneError, - 0xcc: RuneError, - 0xcd: RuneError, - 0xce: RuneError, - 0xcf: RuneError, - 0xd0: '}', - 0xd1: 'J', - 0xd2: 'K', - 0xd3: 'L', - 0xd4: 'M', - 0xd5: 'N', - 0xd6: 'O', - 0xd7: 'P', - 0xd8: 'Q', - 0xd9: 'R', - 0xda: RuneError, - 0xdb: RuneError, - 0xdc: RuneError, - 0xdd: RuneError, - 0xde: RuneError, - 0xdf: RuneError, - 0xe0: '\\', - 0xe1: '\u2007', // Non-breaking space - 0xe2: 'S', - 0xe3: 'T', - 0xe4: 'U', - 0xe5: 'V', - 0xe6: 'W', - 0xe7: 'X', - 0xe8: 'Y', - 0xe9: 'Z', - 0xea: RuneError, - 0xeb: RuneError, - 0xec: RuneError, - 0xed: RuneError, - 0xee: RuneError, - 0xef: RuneError, - 0xf0: '0', - 0xf1: '1', - 0xf2: '2', - 0xf3: '3', - 0xf4: '4', - 0xf5: '5', - 0xf6: '6', - 0xf7: '7', - 0xf8: '8', - 0xf9: '9', - 0xfa: RuneError, - 0xfb: RuneError, - 0xfc: RuneError, - 0xfd: RuneError, - 0xfe: RuneError, - 0xff: RuneError, - }} - cm.Init() - EBCDIC = cm -} diff --git a/vendor/github.com/gdamore/encoding/ebcdic_test.go b/vendor/github.com/gdamore/encoding/ebcdic_test.go deleted file mode 100644 index 19f160f..0000000 --- a/vendor/github.com/gdamore/encoding/ebcdic_test.go +++ /dev/null @@ -1,146 +0,0 @@ -// Copyright 2018 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "testing" -) - -type mapRange struct { - first byte - last byte - r rune -} - -var mapRanges = []mapRange{ - {0, 3, '\x00'}, - {4, 4, RuneError}, - {5, 5, '\x09'}, - {6, 6, RuneError}, - {7, 7, '\x7f'}, - {8, 10, RuneError}, - {11, 19, '\x0b'}, - {20, 20, RuneError}, - {21, 21, '\u0085'}, - {22, 22, '\x08'}, - {23, 23, RuneError}, - {24, 25, '\x18'}, - {26, 27, RuneError}, - {28, 31, '\x1c'}, - {32, 36, RuneError}, - {37, 37, '\x0a'}, - {38, 38, '\x17'}, - {39, 39, '\x1b'}, - {40, 44, RuneError}, - {45, 47, '\x05'}, - {48, 49, RuneError}, - {50, 50, '\x16'}, - {51, 54, RuneError}, - {55, 55, '\x04'}, - {56, 59, RuneError}, - {60, 61, '\x14'}, - {62, 62, RuneError}, - {63, 63, '\x1a'}, - {64, 64, '\x20'}, - {65, 65, '\xa0'}, - {66, 74, RuneError}, - {75, 75, '.'}, - {76, 76, '<'}, - {77, 77, '('}, - {78, 78, '+'}, - {79, 79, '|'}, - {80, 80, '&'}, - {81, 89, RuneError}, - {90, 90, '!'}, - {91, 91, '$'}, - {92, 92, '*'}, - {93, 93, ')'}, - {94, 94, ';'}, - {95, 95, '\u00ac'}, - {96, 96, '\x2d'}, - {97, 97, '\x2f'}, - {98, 105, RuneError}, - {106, 106, '\u00a6'}, - {107, 107, '\x2c'}, - {108, 108, '%'}, - {109, 109, '\x5f'}, - {110, 111, '\x3e'}, - {112, 120, RuneError}, - {121, 121, '\x60'}, - {122, 122, ':'}, - {123, 123, '#'}, - {124, 124, '@'}, - {125, 125, '\x27'}, - {126, 126, '='}, - {127, 127, '\x22'}, - {128, 128, RuneError}, - {129, 137, 'a'}, - {138, 142, RuneError}, - {143, 143, '\u00b1'}, - {144, 144, RuneError}, - {145, 153, 'j'}, - {154, 160, RuneError}, - {161, 161, '~'}, - {162, 169, 's'}, - {170, 175, RuneError}, - {176, 176, '\x5e'}, - {177, 185, RuneError}, - {186, 186, '['}, - {187, 187, ']'}, - {188, 191, RuneError}, - {192, 192, '{'}, - {193, 201, 'A'}, - {202, 202, '\u00ad'}, - {203, 207, RuneError}, - {208, 208, '}'}, - {209, 217, 'J'}, - {218, 223, RuneError}, - {224, 224, '\x5c'}, - {226, 233, 'S'}, - {234, 239, RuneError}, - {240, 249, '0'}, - {250, 255, RuneError}, -} - -func TestEBCDICvsASCII(t *testing.T) { - t.Logf("EBCDIC/ASCII identity values") - for _, rng := range mapRanges { - if rng.r == RuneError { - continue - } - for j := 0; j <= int(rng.last-rng.first); j++ { - b := rng.first + byte(j) - r := rng.r + rune(j) - verifyMap(t, EBCDIC, b, r) - } - } -} -func TestEBDICvsInvalid(t *testing.T) { - t.Logf("EBCDIC invalid transforms") - for _, rng := range mapRanges { - if rng.r != RuneError { - continue - } - for j := 0; j <= int(rng.last-rng.first); j++ { - b := rng.first + byte(j) - verifyToUTF(t, EBCDIC, b, RuneError) - } - } -} - -func TestEBDICvsLargeUTF(t *testing.T) { - t.Logf("Large UTF maps to subst char") - verifyFromUTF(t, EBCDIC, '\x3F', '㿿') -} diff --git a/vendor/github.com/gdamore/encoding/go.mod b/vendor/github.com/gdamore/encoding/go.mod deleted file mode 100644 index e91b30d..0000000 --- a/vendor/github.com/gdamore/encoding/go.mod +++ /dev/null @@ -1,5 +0,0 @@ -module github.com/gdamore/encoding - -go 1.9 - -require golang.org/x/text v0.3.0 diff --git a/vendor/github.com/gdamore/encoding/go.sum b/vendor/github.com/gdamore/encoding/go.sum deleted file mode 100644 index 6bad37b..0000000 --- a/vendor/github.com/gdamore/encoding/go.sum +++ /dev/null @@ -1,2 +0,0 @@ -golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= diff --git a/vendor/github.com/gdamore/encoding/latin1.go b/vendor/github.com/gdamore/encoding/latin1.go deleted file mode 100644 index 226bf01..0000000 --- a/vendor/github.com/gdamore/encoding/latin1.go +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2015 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "golang.org/x/text/encoding" -) - -// ISO8859_1 represents the 8-bit ISO8859-1 scheme. It decodes directly to -// UTF-8 without change, as all ISO8859-1 values are legal UTF-8. -// Unicode values less than 256 (i.e. 8 bits) map 1:1 with 8859-1. -// It encodes runes outside of that to 0x1A, the ASCII substitution character. -var ISO8859_1 encoding.Encoding - -func init() { - cm := &Charmap{} - cm.Init() - - // 8859-1 is the 8-bit identity map for Unicode. - ISO8859_1 = cm -} diff --git a/vendor/github.com/gdamore/encoding/latin1_test.go b/vendor/github.com/gdamore/encoding/latin1_test.go deleted file mode 100644 index 7750955..0000000 --- a/vendor/github.com/gdamore/encoding/latin1_test.go +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2018 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "testing" -) - -func TestISO8859_1(t *testing.T) { - t.Logf("8859-1 identity transforms") - for i := 0; i < 256; i++ { - verifyMap(t, ISO8859_1, byte(i), rune(i)) - } - - t.Logf("Large UTF maps to ASCIISub") - verifyFromUTF(t, ISO8859_1, ASCIISub, '㿿') -} diff --git a/vendor/github.com/gdamore/encoding/latin5.go b/vendor/github.com/gdamore/encoding/latin5.go deleted file mode 100644 index c75ecf2..0000000 --- a/vendor/github.com/gdamore/encoding/latin5.go +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright 2015 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "golang.org/x/text/encoding" -) - -// ISO8859_9 represents the 8-bit ISO8859-9 scheme. -var ISO8859_9 encoding.Encoding - -func init() { - cm := &Charmap{Map: map[byte]rune{ - 0xD0: 'Ğ', - 0xDD: 'İ', - 0xDE: 'Ş', - 0xF0: 'ğ', - 0xFD: 'ı', - 0xFE: 'ş', - }} - cm.Init() - ISO8859_9 = cm -} diff --git a/vendor/github.com/gdamore/encoding/latin5_test.go b/vendor/github.com/gdamore/encoding/latin5_test.go deleted file mode 100644 index 648eb9f..0000000 --- a/vendor/github.com/gdamore/encoding/latin5_test.go +++ /dev/null @@ -1,44 +0,0 @@ -// Copyright 2018 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "testing" -) - -func TestISO8859_9(t *testing.T) { - t.Logf("8859-9 identity transforms") - for i := 0; i < 256; i++ { - r := rune(i) - switch i { - case 0xd0: - r = 'Ğ' - case 0xdd: - r = 'İ' - case 0xde: - r = 'Ş' - case 0xf0: - r = 'ğ' - case 0xfd: - r = 'ı' - case 0xfe: - r = 'ş' - } - verifyMap(t, ISO8859_9, byte(i), r) - } - - t.Logf("Large UTF maps to ASCIISub") - verifyFromUTF(t, ISO8859_9, ASCIISub, '㿿') -} diff --git a/vendor/github.com/gdamore/encoding/utf8.go b/vendor/github.com/gdamore/encoding/utf8.go deleted file mode 100644 index 2d59f4b..0000000 --- a/vendor/github.com/gdamore/encoding/utf8.go +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright 2015 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "golang.org/x/text/encoding" -) - -type validUtf8 struct{} - -// UTF8 is an encoding for UTF-8. All it does is verify that the UTF-8 -// in is valid. The main reason for its existence is that it will detect -// and report ErrSrcShort or ErrDstShort, whereas the Nop encoding just -// passes every byte, blithely. -var UTF8 encoding.Encoding = validUtf8{} - -func (validUtf8) NewDecoder() *encoding.Decoder { - return &encoding.Decoder{Transformer: encoding.UTF8Validator} -} - -func (validUtf8) NewEncoder() *encoding.Encoder { - return &encoding.Encoder{Transformer: encoding.UTF8Validator} -} diff --git a/vendor/github.com/gdamore/encoding/utf8_test.go b/vendor/github.com/gdamore/encoding/utf8_test.go deleted file mode 100644 index ef8fc72..0000000 --- a/vendor/github.com/gdamore/encoding/utf8_test.go +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2018 Garrett D'Amore -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "testing" -) - -func TestUTF8(t *testing.T) { - t.Logf("ASCII UTF8 identity transforms") - for i := 0; i < 128; i++ { - verifyMap(t, UTF8, byte(i), rune(i)) - } - - // We need to add tests for ErrSrcShort, ErrDstShort, and - // larger rune values. -} diff --git a/vendor/github.com/gdamore/tcell/v2/.appveyor.yml b/vendor/github.com/gdamore/tcell/v2/.appveyor.yml deleted file mode 100644 index 435dfe3..0000000 --- a/vendor/github.com/gdamore/tcell/v2/.appveyor.yml +++ /dev/null @@ -1,13 +0,0 @@ -version: 1.0.{build} -clone_folder: c:\gopath\src\github.com\gdamore\tcell -environment: - GOPATH: c:\gopath -build_script: -- go version -- go env -- SET PATH=%LOCALAPPDATA%\atom\bin;%GOPATH%\bin;%PATH% -- go get -t ./... -- go build -- go install ./... -test_script: -- go test ./... diff --git a/vendor/github.com/gdamore/tcell/v2/.github/FUNDING.yml b/vendor/github.com/gdamore/tcell/v2/.github/FUNDING.yml deleted file mode 100644 index 859aaf9..0000000 --- a/vendor/github.com/gdamore/tcell/v2/.github/FUNDING.yml +++ /dev/null @@ -1,3 +0,0 @@ -patreon: gedamore -github: gdamore -tidelift: go/github.com/gdamore/tcell diff --git a/vendor/github.com/gdamore/tcell/v2/.github/workflows/go.yml b/vendor/github.com/gdamore/tcell/v2/.github/workflows/go.yml deleted file mode 100644 index 14bd4f2..0000000 --- a/vendor/github.com/gdamore/tcell/v2/.github/workflows/go.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: Go -on: [push] -jobs: - - build: - name: Build - runs-on: ubuntu-latest - steps: - - - name: Set up Go 1.13 - uses: actions/setup-go@v1 - with: - go-version: 1.13 - id: go - - - name: Check out code into the Go module directory - uses: actions/checkout@v1 - - - name: Get dependencies - run: | - go get -v -t -d ./... - if [ -f Gopkg.toml ]; then - curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh - dep ensure - fi - - - name: Build - run: go build -v . diff --git a/vendor/github.com/gdamore/tcell/v2/.gitignore b/vendor/github.com/gdamore/tcell/v2/.gitignore deleted file mode 100644 index c57100a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/.gitignore +++ /dev/null @@ -1 +0,0 @@ -coverage.txt diff --git a/vendor/github.com/gdamore/tcell/v2/.travis.yml b/vendor/github.com/gdamore/tcell/v2/.travis.yml deleted file mode 100644 index 2d0ecee..0000000 --- a/vendor/github.com/gdamore/tcell/v2/.travis.yml +++ /dev/null @@ -1,19 +0,0 @@ -language: go - -go: - - 1.11.x - - 1.15.x - - master - -arch: - - amd64 - - ppc64le - -before_install: - - go get -t -v ./... - -script: - - go test -race -coverprofile=coverage.txt -covermode=atomic - -after_success: - - bash <(curl -s https://codecov.io/bash) diff --git a/vendor/github.com/gdamore/tcell/v2/AUTHORS b/vendor/github.com/gdamore/tcell/v2/AUTHORS deleted file mode 100644 index 53f87ee..0000000 --- a/vendor/github.com/gdamore/tcell/v2/AUTHORS +++ /dev/null @@ -1,4 +0,0 @@ -Garrett D'Amore -Zachary Yedidia -Junegunn Choi -Staysail Systems, Inc. diff --git a/vendor/github.com/gdamore/tcell/v2/CHANGESv2.adoc b/vendor/github.com/gdamore/tcell/v2/CHANGESv2.adoc deleted file mode 100644 index 65d1548..0000000 --- a/vendor/github.com/gdamore/tcell/v2/CHANGESv2.adoc +++ /dev/null @@ -1,82 +0,0 @@ -== Breaking Changes in _Tcell_ v2 - -A number of changes were made to _Tcell_ for version two, and some of these -are breaking. - -=== Import Path - -The import path for tcell has changed to `github.com/gdamore/tcell/v2` to reflect a new major version. - -=== Style Is Not Numeric - -The type `Style` has changed to a structure, to allow us to add additional data such as flags for color setting, more attribute bits, and so forth. -Applications that relied on this being a number will need to be updated to use the accessor methods. - -=== Mouse Event Changes - -The middle mouse button was reported as button 2 on Linux, but as button 3 on Windows, -and the right mouse button was reported the reverse way. -_Tcell_ now always reports the right mouse button as button 2, and the middle button as button 3. -To help make this clearer, new symbols `ButtonPrimary`, `ButtonSecondary`, and -`ButtonMiddle` are provided. -(Note that which button is right vs. left may be impacted by user preferences. -Usually the left button will be considered the Primary, and the right will be the Secondary.) -Applications may need to adjust their handling of mouse buttons 2 and 3 accordingly. - -=== Terminals Removed - -A number of terminals have been removed. -These are mostly ancient definitions unlikely to be used by anyone, such as `adm3a`. - -=== High Number Function Keys - -Historically terminfo reported function keys with modifiers set as a different -function key altogether. For example, Shift-F1 was reported as F13 on XTerm. -_Tcell_ now prefers to report these using the base key (such as F1) with modifiers added. -This works on XTerm and VTE based emulators, but some emulators may not support this. -The new behavior more closely aligns with behavior on Windows platforms. - -== New Features in _Tcell_ v2 - -These features are not breaking, but are introduced in version 2. - -=== Improved Modifier Support - -For terminals that appear to behave like the venerable XTerm, _tcell_ -automatically adds modifier reporting for ALT, CTRL, SHIFT, and META keys -when the terminal reports them. - -=== Better Support for Palettes (Themes) - -When using a color by its name or palette entry, _Tcell_ now tries to -use that palette entry as is; this should avoid some inconsistency and undesirable -overriding of colors where colors would override settings made in the terminal. - -When true fidelity to RGB values is needed, the new `TrueColor()` API can be used -to create a direct color, which bypasses the palette altogether. - -=== Automatic TrueColor Detection - -For some terminals, if the `Tc` or `RGB` properties are present in terminfo, -_Tcell_ will automatically assume the terminal supports 24-bit color. - -=== ColorReset - -A new color value, `ColorReset` can be used on the foreground or background -to reset the color the default used by the terminal. - -=== tmux Support - -_Tcell_ now has improved support for tmux, when the `$TERM` variable is set to "tmux". - -=== Strikethrough Support - -_Tcell_ has support for strikethrough when the terminal supports it, using the new `StrikeThrough()` API. - -=== Bracketed Paste Support - -_Tcell_ provides the long requested capability to discriminate paste event by using the -bracketed-paste capability present in some terminals. This is automatically available on -terminals that support XTerm style mouse handling, but applications must opt-in to this -by using the new `EnablePaste()` function. A new `EventPaste` type of event will be -delivered when starting and finishing a paste operation. \ No newline at end of file diff --git a/vendor/github.com/gdamore/tcell/v2/LICENSE b/vendor/github.com/gdamore/tcell/v2/LICENSE deleted file mode 100644 index d645695..0000000 --- a/vendor/github.com/gdamore/tcell/v2/LICENSE +++ /dev/null @@ -1,202 +0,0 @@ - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/vendor/github.com/gdamore/tcell/v2/README.adoc b/vendor/github.com/gdamore/tcell/v2/README.adoc deleted file mode 100644 index c49da32..0000000 --- a/vendor/github.com/gdamore/tcell/v2/README.adoc +++ /dev/null @@ -1,280 +0,0 @@ -= tcell - - -image:https://img.shields.io/travis/gdamore/tcell.svg?label=linux[Linux Status,link="https://travis-ci.org/gdamore/tcell"] -image:https://img.shields.io/appveyor/ci/gdamore/tcell.svg?label=windows[Windows Status,link="https://ci.appveyor.com/project/gdamore/tcell"] -image:https://img.shields.io/badge/license-APACHE2-blue.svg[Apache License,link="https://github.com/gdamore/tcell/blob/master/LICENSE"] -image:https://img.shields.io/badge/godoc-reference-blue.svg[GoDoc,link="https://godoc.org/github.com/gdamore/tcell"] -image:http://goreportcard.com/badge/gdamore/tcell[Go Report Card,link="http://goreportcard.com/report/gdamore/tcell"] -image:https://img.shields.io/discord/639503822733180969?label=discord[Discord,link="https://discord.gg/urTTxDN"] -image:https://codecov.io/gh/gdamore/tcell/branch/master/graph/badge.svg[codecov,link="https://codecov.io/gh/gdamore/tcell"] - -[cols="2",grid="none"] -|=== -|_Tcell_ is a _Go_ package that provides a cell based view for text terminals, like _XTerm_. -It was inspired by _termbox_, but includes many additional improvements. -a|[.right] -image::logos/tcell.png[float="right"] -|=== - -NOTE: This is version 2 of _Tcell_. There are breaking changes relative to version 1. -Version 1.x remains available using the import `github.com/gdamore/tcell`. - -== Examples - -* https://github.com/gdamore/proxima5[proxima5] - space shooter (https://youtu.be/jNxKTCmY_bQ[video]) -* https://github.com/gdamore/govisor[govisor] - service management UI (http://2.bp.blogspot.com/--OsvnfzSNow/Vf7aqMw3zXI/AAAAAAAAARo/uOMtOvw4Sbg/s1600/Screen%2BShot%2B2015-09-20%2Bat%2B9.08.41%2BAM.png[screenshot]) -* mouse demo - included mouse test (http://2.bp.blogspot.com/-fWvW5opT0es/VhIdItdKqJI/AAAAAAAAATE/7Ojc0L1SpB0/s1600/Screen%2BShot%2B2015-10-04%2Bat%2B11.47.13%2BPM.png[screenshot]) -* https://github.com/gdamore/gomatrix[gomatrix] - converted from Termbox -* https://github.com/zyedidia/micro/[micro] - lightweight text editor with syntax-highlighting and themes -* https://github.com/viktomas/godu[godu] - simple golang utility helping to discover large files/folders. -* https://github.com/rivo/tview[tview] - rich interactive widgets for terminal UIs -* https://github.com/marcusolsson/tui-go[tui-go] - UI library for terminal apps (_deprecated_) -* https://github.com/rgm3/gomandelbrot[gomandelbrot] - Mandelbrot! -* https://github.com/senorprogrammer/wtf[WTF]- Personal information dashboard for your terminal -* https://github.com/browsh-org/browsh[browsh] - A fully-modern text-based browser, rendering to TTY and browsers (https://www.youtube.com/watch?v=HZq86XfBoRo[video]) -* https://github.com/sachaos/go-life[go-life] - Conway's Game of Life. -* https://github.com/gcla/gowid[gowid] - compositional widgets for terminal UIs, inspired by urwid -* https://termshark.io[termshark] - a terminal UI for tshark, inspired by Wireshark, built on gowid -* https://github.com/MichaelS11/go-tetris[go-tetris] - Go Tetris with AI option -* https://github.com/junegunn/fzf[fzf] - A command-line fuzzy finder -* https://github.com/esimov/ascii-fluid[ascii-fluid] - A terminal based ASCII fluid simulation controlled by webcam -* https://gitlab.com/tslocum/cbind[cbind] - Provides key event encoding, decoding and handling -* https://github.com/spinzed/tpong[tpong] - The old-school Pong remade in terminal -* https://git.sr.ht/~sircmpwn/aerc[aerc] - An email client for your terminal. -* https://github.com/ezeoleaf/tblogs[tblogs] - A terminal based development blogs reader -* https://github.com/lallassu/spinc[spinc] - An irssi inspired terminal chat application for Cisco Spark/WebEx -* https://github.com/lallassu/gorss[gorss] - A RSS/Atom feed reader for your terminal -* https://github.com/Bios-Marcel/memoryalike[memoryalike] - A game where you have to memorize runes and hit their respective keys -* https://github.com/gokcehan/lf[lf] - Terminal file manager -* https://github.com/bunyk/gokeybr[gokeybr] - program that helps to deliberately practice your typing. - -== Pure Go Terminfo Database - -_Tcell_ includes a full parser and expander for terminfo capability strings, -so that it can avoid hard coding escape strings for formatting. It also favors -portability, and includes support for all POSIX systems. - -The database is also flexible & extensible, and can modified by either running -a program to build the entire database, or an entry for just a single terminal. - -== More Portable - -_Tcell_ is portable to a wide variety of systems, and is pure Go, without -any need for CGO. -_Tcell_ is believed to work with mainstream systems officially supported by golang. - -== No Async IO - -_Tcell_ is able to operate without requiring `SIGIO` signals (unlike _termbox_), -or asynchronous I/O, and can instead use standard Go file -objects and Go routines. -This means it should be safe, especially for -use with programs that use exec, or otherwise need to manipulate the -tty streams. -This model is also much closer to idiomatic Go, leading -to fewer surprises. - -== Rich Unicode & non-Unicode support - -_Tcell_ includes enhanced support for Unicode, including wide characters and -combining characters, provided your terminal can support them. -Note that -Windows terminals generally don't support the full Unicode repertoire. - -It will also convert to and from Unicode locales, so that the program -can work with UTF-8 internally, and get reasonable output in other locales. -_Tcell_ tries hard to convert to native characters on both input and output, and -on output _Tcell_ even makes use of the alternate character set to facilitate -drawing certain characters. - -== More Function Keys - -_Tcell_ also has richer support for a larger number of special keys that some terminals can send. - -== Better Color Handling - -_Tcell_ will respect your terminal's color space as specified within your terminfo -entries, so that for example attempts to emit color sequences on VT100 terminals -won't result in unintended consequences. - -In legacy Windows mode, _Tcell_ supports 16 colors, bold, dim, and reverse, -instead of just termbox's 8 colors with reverse. (Note that there is some -conflation with bold/dim and colors.) -Modern Windows 10 can benefit from much richer colors however. - -_Tcell_ maps 16 colors down to 8, for terminals that need it. -(The upper 8 colors are just brighter versions of the lower 8.) - -== Better Mouse Support - -_Tcell_ supports enhanced mouse tracking mode, so your application can receive -regular mouse motion events, and wheel events, if your terminal supports it. - -(Note: The Windows 10 Terminal application suffers from a flaw in this regard, -and does not support mouse interaction. The stock Windows 10 console host -fired up with cmd.exe or PowerShell works fine however.) - -== _Termbox_ Compatibility - -A compatibility layer for _termbox_ is provided in the `compat` directory. -To use it, try importing `github.com/gdamore/tcell/termbox` instead. -Most _termbox-go_ programs will probably work without further modification. - -== Working With Unicode - -Internally Tcell uses UTF-8, just like Go. -However, Tcell understands how to -convert to and from other character sets, using the capabilities of -the `golang.org/x/text/encoding packages`. -Your application must supply -them, as the full set of the most common ones bloats the program by about 2MB. -If you're lazy, and want them all anyway, see the `encoding` sub-directory. - -== Wide & Combining Characters - -The `SetContent()` API takes a primary rune, and an optional list of combining runes. -If any of the runes is a wide (East Asian) rune occupying two cells, -then the library will skip output from the following cell, but care must be -taken in the application to avoid explicitly attempting to set content in the -next cell, otherwise the results are undefined. (Normally wide character -is displayed, and the other character is not; do not depend on that behavior.) - -Older terminal applications (especially on systems like Windows 8) lack support -for advanced Unicode, and thus may not fare well. - -== Colors - -_Tcell_ assumes the ANSI/XTerm color model, including the 256 color map that -XTerm uses when it supports 256 colors. The terminfo guidance will be -honored, with respect to the number of colors supported. Also, only -terminals which expose ANSI style `setaf` and `setab` will support color; -if you have a color terminal that only has `setf` and `setb`, please submit -a ticket; it wouldn't be hard to add that if there is need. - -== 24-bit Color - -_Tcell_ _supports true color_! (That is, if your terminal can support it, -_Tcell_ can accurately display 24-bit color.) - -NOTE: Technically the approach of using 24-bit RGB values for color is more -accurately described as "direct color", but most people use the term "true color", -and so we follow the (inaccurate) common convention. - -There are a few ways you can enable (or disable) true color. - -* For many terminals, we can detect it automatically if your terminal -includes the `RGB` or `Tc` capabilities (or rather it did when the database -was updated.) - -* You can force this one by setting the `COLORTERM` environment variable to -"24-bit", "truecolor" or "24bit". This is the same method used -by most other terminal applications that support 24-bit color. - -* If you set your `TERM` environment variable to a value with the suffix `-truecolor` -then 24-bit color compatible with XTerm will be assumed (and the terminal will -otherwise use the same escape sequences as the base terminal definition.) - -NOTE: This feature is for compatibility with older _Tcell_ versions. -It is recommended to use one of other methods instead. - -* You can disable 24-bit color by setting `TCELL_TRUECOLOR=disable` in your -environment. - -When using TrueColor, programs will display the colors that the programmer -intended, overriding any "`themes`" you may have set in your terminal -emulator. (For some cases, accurate color fidelity is more important -than respecting themes. For other cases, such as typical text apps that -only use a few colors, its more desirable to respect the themes that -the user has established.) - -== Performance - -Reasonable attempts have been made to minimize sending data to terminals, -avoiding repeated sequences or drawing the same cell on refresh updates. - -== Terminfo - -(Not relevant for Windows users.) - -The Terminfo implementation operates with a built-in database. -This should satisfy most users. However, it can also (on systems -with ncurses installed), dynamically parse the output from `infocmp` -for terminals it does not already know about. - -See the `terminfo/` directory for more information about generating -new entries for the built-in database. - -_Tcell_ requires that the terminal support the `cup` mode of cursor addressing. -Ancient terminals without the ability to position the cursor directly -are not supported. -This is unlikely to be a problem; such terminals have not been mass-produced -since the early 1970s. - -== Mouse Support - -Mouse support is detected via the `kmous` terminfo variable, however, -enablement/disablement and decoding mouse events is done using hard coded -sequences based on the XTerm X11 model. As of this writing all popular -terminals with mouse tracking support this model. (Full terminfo support -is not possible as terminfo sequences are not defined.) - -On Windows, the mouse works normally. - -Mouse wheel buttons on various terminals are known to work, but the support -in terminal emulators, as well as support for various buttons and -live mouse tracking, varies widely. Modern _xterm_, macOS _Terminal_, and _iTerm_ all work well. - -== Bracketed Paste - -Terminals that appear to support the XTerm mouse model also can support -bracketed paste, for applications that opt-in. See `EnablePaste()` for details. - -== Testability - -There is a `SimulationScreen`, that can be used to simulate a real screen -for automated testing. The supplied tests do this. The simulation contains -event delivery, screen resizing support, and capabilities to inject events -and examine "`physical`" screen contents. - -== Platforms - -=== POSIX (Linux, FreeBSD, macOS, Solaris, etc.) - -Everything works using pure Go on mainstream platforms. Some more esoteric -platforms (e.g. AIX) may need to be added. Pull requests are welcome! - -=== Windows - -Windows console mode applications are supported. Unfortunately _mintty_ -and other _cygwin_ style applications are not supported, and are -unlikely to be supportable due to limitations in their design. - -Modern console applications like ConEmu and the Windows 10 terminal, -support all the good features (resize, mouse tracking, etc.) - -=== Plan9, WASM, and others - -These platforms won't work, but compilation stubs are supplied -for folks that want to include parts of this in software for those -platforms. The Simulation screen works, but as _Tcell_ doesn't know how to -allocate a real screen object on those platforms, `NewScreen()` will fail. - -If anyone has wisdom about how to improve support for these, -please let me know. PRs are especially welcome. - -=== Commercial Support - -_Tcell_ is absolutely free, but if you want to obtain commercial, professional support, there are options. - -[cols="2",align="center",frame="none", grid="none"] -|=== -^.^| -image:logos/tidelift.png[100,100] -a| -https://tidelift.com/[Tidelift] subscriptions include support for _Tcell_, as well as many other open source packages. - -^.^| -image:logos/staysail.png[100,100] -a| -mailto:info@staysail.tech[Staysail Systems, Inc.] offers direct support, and custom development around _Tcell_ on an hourly basis. diff --git a/vendor/github.com/gdamore/tcell/v2/TUTORIAL.adoc b/vendor/github.com/gdamore/tcell/v2/TUTORIAL.adoc deleted file mode 100644 index c5d6a1a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/TUTORIAL.adoc +++ /dev/null @@ -1,325 +0,0 @@ -= tcell tutorial - -tcell provides a low-level, portable API for building terminal-based programs. -A https://en.wikipedia.org/wiki/Terminal_emulator[terminal emulator] is used to -interact with such a program. - -Applications typically initialize a screen and enter an event loop, then -finalize the screen before exiting. - -Application frameworks such as https://github.com/rivo/tview[tview] and -https://gitlab.com/tslocum/cview[cview] provide widgets and additional features. - -== Resize events - -Applications receive an event of type `EventResize` when they are first initialized and each time the terminal is resized. -The new size is available as `Size`. - -[source,go] ----- -switch ev := ev.(type) { -case *tcell.EventResize: - w, h := ev.Size() - logMessage(fmt.Sprintf("Resized to %dx%d", w, h)) -} ----- - -== Key events - -When a key is pressed, applications receive an event of type `EventKey`. -This event describes the modifier keys pressed (if any) and the pressed key or rune. - -When a rune key is pressed, an event with its `Key` set to `KeyRune` is dispatched. - -When a non-rune key is pressed, it is available as the `Key` of the event. - -[source,go] ----- -switch ev := ev.(type) { -case *tcell.EventKey: - mod, key, ch := ev.Mod(), ev.Key(), ev.Rune() - logMessage(fmt.Sprintf("EventKey Modifiers: %d Key: %d Rune: %d", mod, key, ch)) -} ----- - -=== Key event restrictions - -Terminal-based programs have less visibility into keyboard activity than graphical applications. - -When a key is pressed and held, additional key press events are sent by the terminal emulator. -The rate of these repeated events depends on the emulator's configuration. -Key release events are not available. - -It is not possible to distinguish runes typed while holding shift and runes typed using caps lock. -Capital letters are reported without the Shift modifier. - -=== Key event handling library - -https://gitlab.com/tslocum/cbind[cbind] provides key event encoding and decoding -to and from human-readable strings. It also provides keybinding-based input handling. - -== Mouse events - -Applications receive an event of type `EventMouse` when the mouse moves, or a mouse button is pressed or released. -Mouse events are only delivered if -`EnableMouse` has been called. - -The mouse buttons being pressed (if any) are available as `Buttons`, and the position of the mouse is available as `Position`. - -[source,go] ----- -switch ev := ev.(type) { -case *tcell.EventMouse: - mod := ev.Modifiers() - btns := ev.Buttons() - x, y := ev.Position() - logMessage(fmt.Sprintf("EventMouse Modifiers: %d Buttons: %d Position: %d,%d", mod, btns, x, y)) -} ----- - -=== Mouse buttons - -[cols=3*,options=header] -|=== - -|Identifier -|Alias -|Description - -|Button1 -|ButtonPrimary -|Left button - -|Button2 -|ButtonSecondary -|Right button - -|Button3 -|ButtonMiddle -|Middle button - -|Button4 -| -|Side button (thumb/next) - -|Button5 -| -|Side button (thumb/prev) - -|=== - -== Usage - -To create a tcell application, first initialize a screen to hold it. - -[source,go] ----- -// Initialize screen -s, err := tcell.NewScreen() -if err != nil { - log.Fatalf("%+v", err) -} -if err := s.Init(); err != nil { - log.Fatalf("%+v", err) -} - -// Set default text style -defStyle := tcell.StyleDefault.Background(tcell.ColorReset).Foreground(tcell.ColorReset) -s.SetStyle(defStyle) - -// Clear screen -s.Clear() ----- - -Text may be drawn on the screen using `SetContent`. - -[source,go] ----- -s.SetContent(0, 0, 'H', nil, defStyle) -s.SetContent(1, 0, 'i', nil, defStyle) -s.SetContent(2, 0, '!', nil, defStyle) ----- - -To draw text more easily, define a render function. - -[source,go] ----- -func drawText(s tcell.Screen, x1, y1, x2, y2 int, style tcell.Style, text string) { - row := y1 - col := x1 - for _, r := range []rune(text) { - s.SetContent(col, row, r, nil, style) - col++ - if col >= x2 { - row++ - col = x1 - } - if row > y2 { - break - } - } -} ----- - -Lastly, define an event loop to handle user input and update application state. - -[source,go] ----- -quit := func() { - s.Fini() - os.Exit(0) -} -for { - // Update screen - s.Show() - - // Poll event - ev := s.PollEvent() - - // Process event - switch ev := ev.(type) { - case *tcell.EventResize: - s.Sync() - case *tcell.EventKey: - if ev.Key() == tcell.KeyEscape || ev.Key() == tcell.KeyCtrlC { - quit() - } - } -} ----- - -== Demo application - -The following demonstrates how to initialize a screen, draw text/graphics and handle user input. - -[source,go] ----- -package main - -import ( - "fmt" - "log" - "os" - - "github.com/gdamore/tcell/v2" -) - -func drawText(s tcell.Screen, x1, y1, x2, y2 int, style tcell.Style, text string) { - row := y1 - col := x1 - for _, r := range []rune(text) { - s.SetContent(col, row, r, nil, style) - col++ - if col >= x2 { - row++ - col = x1 - } - if row > y2 { - break - } - } -} - -func drawBox(s tcell.Screen, x1, y1, x2, y2 int, style tcell.Style, text string) { - if y2 < y1 { - y1, y2 = y2, y1 - } - if x2 < x1 { - x1, x2 = x2, x1 - } - - // Fill background - for row := y1; row <= y2; row++ { - for col := x1; col <= x2; col++ { - s.SetContent(col, row, ' ', nil, style) - } - } - - // Draw borders - for col := x1; col <= x2; col++ { - s.SetContent(col, y1, tcell.RuneHLine, nil, style) - s.SetContent(col, y2, tcell.RuneHLine, nil, style) - } - for row := y1 + 1; row < y2; row++ { - s.SetContent(x1, row, tcell.RuneVLine, nil, style) - s.SetContent(x2, row, tcell.RuneVLine, nil, style) - } - - // Only draw corners if necessary - if y1 != y2 && x1 != x2 { - s.SetContent(x1, y1, tcell.RuneULCorner, nil, style) - s.SetContent(x2, y1, tcell.RuneURCorner, nil, style) - s.SetContent(x1, y2, tcell.RuneLLCorner, nil, style) - s.SetContent(x2, y2, tcell.RuneLRCorner, nil, style) - } - - drawText(s, x1+1, y1+1, x2-1, y2-1, style, text) -} - -func main() { - defStyle := tcell.StyleDefault.Background(tcell.ColorReset).Foreground(tcell.ColorReset) - boxStyle := tcell.StyleDefault.Foreground(tcell.ColorWhite).Background(tcell.ColorPurple) - - // Initialize screen - s, err := tcell.NewScreen() - if err != nil { - log.Fatalf("%+v", err) - } - if err := s.Init(); err != nil { - log.Fatalf("%+v", err) - } - s.SetStyle(defStyle) - s.EnableMouse() - s.EnablePaste() - s.Clear() - - // Draw initial boxes - drawBox(s, 1, 1, 42, 7, boxStyle, "Click and drag to draw a box") - drawBox(s, 5, 9, 32, 14, boxStyle, "Press C to reset") - - // Event loop - ox, oy := -1, -1 - quit := func() { - s.Fini() - os.Exit(0) - } - for { - // Update screen - s.Show() - - // Poll event - ev := s.PollEvent() - - // Process event - switch ev := ev.(type) { - case *tcell.EventResize: - s.Sync() - case *tcell.EventKey: - if ev.Key() == tcell.KeyEscape || ev.Key() == tcell.KeyCtrlC { - quit() - } else if ev.Key() == tcell.KeyCtrlL { - s.Sync() - } else if ev.Rune() == 'C' || ev.Rune() == 'c' { - s.Clear() - } - case *tcell.EventMouse: - x, y := ev.Position() - button := ev.Buttons() - // Only process button events, not wheel events - button &= tcell.ButtonMask(0xff) - - if button != tcell.ButtonNone && ox < 0 { - ox, oy = x, y - } - switch ev.Buttons() { - case tcell.ButtonNone: - if ox >= 0 { - label := fmt.Sprintf("%d,%d to %d,%d", ox, oy, x, y) - drawBox(s, ox, oy, x, y, boxStyle, label) - ox, oy = -1, -1 - } - } - } - } -} ----- diff --git a/vendor/github.com/gdamore/tcell/v2/_demos/beep.go b/vendor/github.com/gdamore/tcell/v2/_demos/beep.go deleted file mode 100644 index cf0457b..0000000 --- a/vendor/github.com/gdamore/tcell/v2/_demos/beep.go +++ /dev/null @@ -1,75 +0,0 @@ -// +build ignore - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// beep makes a beep every second until you press ESC -package main - -import ( - "fmt" - "os" - "time" - - "github.com/gdamore/tcell/v2" -) - -func main() { - tcell.SetEncodingFallback(tcell.EncodingFallbackASCII) - s, e := tcell.NewScreen() - if e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - if e = s.Init(); e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - - s.SetStyle(tcell.StyleDefault) - s.Clear() - - quit := make(chan struct{}) - go func() { - for { - ev := s.PollEvent() - switch ev := ev.(type) { - case *tcell.EventKey: - switch ev.Key() { - case tcell.KeyEscape, tcell.KeyEnter, tcell.KeyCtrlC: - close(quit) - return - case tcell.KeyCtrlL: - s.Sync() - } - case *tcell.EventResize: - s.Sync() - } - } - }() - beep(s, quit) - s.Fini() -} - -func beep(s tcell.Screen, quit <-chan struct{}) { - t := time.NewTicker(time.Second) - for { - select { - case <-quit: - return - case <-t.C: - s.Beep() - } - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/_demos/boxes.go b/vendor/github.com/gdamore/tcell/v2/_demos/boxes.go deleted file mode 100644 index e974371..0000000 --- a/vendor/github.com/gdamore/tcell/v2/_demos/boxes.go +++ /dev/null @@ -1,118 +0,0 @@ -// +build ignore - -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// boxes just displays random colored boxes on your terminal screen. -// Press ESC to exit the program. -package main - -import ( - "fmt" - "math/rand" - "os" - "time" - - "github.com/gdamore/tcell/v2" -) - -func makebox(s tcell.Screen) { - w, h := s.Size() - - if w == 0 || h == 0 { - return - } - - glyphs := []rune{'@', '#', '&', '*', '=', '%', 'Z', 'A'} - - lx := rand.Int() % w - ly := rand.Int() % h - lw := rand.Int() % (w - lx) - lh := rand.Int() % (h - ly) - st := tcell.StyleDefault - gl := ' ' - if s.Colors() > 256 { - rgb := tcell.NewHexColor(int32(rand.Int() & 0xffffff)) - st = st.Background(rgb) - } else if s.Colors() > 1 { - st = st.Background(tcell.Color(rand.Int() % s.Colors()) | tcell.ColorValid) - } else { - st = st.Reverse(rand.Int()%2 == 0) - gl = glyphs[rand.Int()%len(glyphs)] - } - - for row := 0; row < lh; row++ { - for col := 0; col < lw; col++ { - s.SetCell(lx+col, ly+row, st, gl) - } - } - s.Show() -} - -func main() { - - tcell.SetEncodingFallback(tcell.EncodingFallbackASCII) - s, e := tcell.NewScreen() - if e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - if e = s.Init(); e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - - s.SetStyle(tcell.StyleDefault. - Foreground(tcell.ColorBlack). - Background(tcell.ColorWhite)) - s.Clear() - - quit := make(chan struct{}) - go func() { - for { - ev := s.PollEvent() - switch ev := ev.(type) { - case *tcell.EventKey: - switch ev.Key() { - case tcell.KeyEscape, tcell.KeyEnter: - close(quit) - return - case tcell.KeyCtrlL: - s.Sync() - } - case *tcell.EventResize: - s.Sync() - } - } - }() - - cnt := 0 - dur := time.Duration(0) -loop: - for { - select { - case <-quit: - break loop - case <-time.After(time.Millisecond * 50): - } - start := time.Now() - makebox(s) - cnt++ - dur += time.Now().Sub(start) - } - - s.Fini() - fmt.Printf("Finished %d boxes in %s\n", cnt, dur) - fmt.Printf("Average is %0.3f ms / box\n", (float64(dur)/float64(cnt))/1000000.0) -} diff --git a/vendor/github.com/gdamore/tcell/v2/_demos/colors.go b/vendor/github.com/gdamore/tcell/v2/_demos/colors.go deleted file mode 100644 index 5ebe369..0000000 --- a/vendor/github.com/gdamore/tcell/v2/_demos/colors.go +++ /dev/null @@ -1,163 +0,0 @@ -// +build ignore - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// colors just displays a single centered rectangle that should pulse -// through available colors. It uses the RGB color cube, bumping at -// predefined larger intervals (values of about 8) in order that the -// changes happen quickly enough to be appreciable. -// -// Press ESC to exit the program. -package main - -import ( - "fmt" - "math/rand" - "os" - "time" - - "github.com/gdamore/tcell/v2" -) - -var red = int32(rand.Int() % 256) -var grn = int32(rand.Int() % 256) -var blu = int32(rand.Int() % 256) -var inc = int32(8) // rate of color change -var redi = int32(inc) -var grni = int32(inc) -var blui = int32(inc) - -func makebox(s tcell.Screen) { - w, h := s.Size() - - if w == 0 || h == 0 { - return - } - - glyphs := []rune{'@', '#', '&', '*', '=', '%', 'Z', 'A'} - - lh := h / 2 - lw := w / 2 - lx := w / 4 - ly := h / 4 - st := tcell.StyleDefault - gl := ' ' - - if s.Colors() == 0 { - st = st.Reverse(rand.Int()%2 == 0) - gl = glyphs[rand.Int()%len(glyphs)] - } else { - - red += redi - if (red >= 256) || (red < 0) { - redi = -redi - red += redi - } - grn += grni - if (grn >= 256) || (grn < 0) { - grni = -grni - grn += grni - } - blu += blui - if (blu >= 256) || (blu < 0) { - blui = -blui - blu += blui - - } - st = st.Background(tcell.NewRGBColor(red, grn, blu)) - } - for row := 0; row < lh; row++ { - for col := 0; col < lw; col++ { - s.SetCell(lx+col, ly+row, st, gl) - } - } - s.Show() -} - -func flipcoin() bool { - if rand.Int()&1 == 0 { - return false - } - return true -} - -func main() { - - rand.Seed(time.Now().UnixNano()) - tcell.SetEncodingFallback(tcell.EncodingFallbackASCII) - s, e := tcell.NewScreen() - if e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - if e = s.Init(); e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - - s.SetStyle(tcell.StyleDefault. - Foreground(tcell.ColorBlack). - Background(tcell.ColorWhite)) - s.Clear() - - quit := make(chan struct{}) - go func() { - for { - ev := s.PollEvent() - switch ev := ev.(type) { - case *tcell.EventKey: - switch ev.Key() { - case tcell.KeyEscape, tcell.KeyEnter: - close(quit) - return - case tcell.KeyCtrlL: - s.Sync() - } - case *tcell.EventResize: - s.Sync() - } - } - }() - - cnt := 0 - dur := time.Duration(0) -loop: - for { - select { - case <-quit: - break loop - case <-time.After(time.Millisecond * 50): - } - start := time.Now() - makebox(s) - dur += time.Now().Sub(start) - cnt++ - if cnt%(256/int(inc)) == 0 { - if flipcoin() { - redi = -redi - } - if flipcoin() { - grni = -grni - } - if flipcoin() { - blui = -blui - } - } - } - - s.Fini() - fmt.Printf("Finished %d boxes in %s\n", cnt, dur) - fmt.Printf("Average is %0.3f ms / box\n", (float64(dur)/float64(cnt))/1000000.0) -} diff --git a/vendor/github.com/gdamore/tcell/v2/_demos/hello_world.go b/vendor/github.com/gdamore/tcell/v2/_demos/hello_world.go deleted file mode 100644 index 231d412..0000000 --- a/vendor/github.com/gdamore/tcell/v2/_demos/hello_world.go +++ /dev/null @@ -1,84 +0,0 @@ -// +build ignore - -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package main - -import ( - "fmt" - "os" - - "github.com/gdamore/tcell/v2" - "github.com/gdamore/tcell/v2/encoding" - - "github.com/mattn/go-runewidth" -) - -func emitStr(s tcell.Screen, x, y int, style tcell.Style, str string) { - for _, c := range str { - var comb []rune - w := runewidth.RuneWidth(c) - if w == 0 { - comb = []rune{c} - c = ' ' - w = 1 - } - s.SetContent(x, y, c, comb, style) - x += w - } -} - -func displayHelloWorld(s tcell.Screen) { - w, h := s.Size() - s.Clear() - emitStr(s, w/2-7, h/2, tcell.StyleDefault, "Hello, World!") - emitStr(s, w/2-9, h/2+1, tcell.StyleDefault, "Press ESC to exit.") - s.Show() -} - -// This program just prints "Hello, World!". Press ESC to exit. -func main() { - encoding.Register() - - s, e := tcell.NewScreen() - if e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - if e := s.Init(); e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - - defStyle := tcell.StyleDefault. - Background(tcell.ColorBlack). - Foreground(tcell.ColorWhite) - s.SetStyle(defStyle) - - displayHelloWorld(s) - - for { - switch ev := s.PollEvent().(type) { - case *tcell.EventResize: - s.Sync() - displayHelloWorld(s) - case *tcell.EventKey: - if ev.Key() == tcell.KeyEscape { - s.Fini() - os.Exit(0) - } - } - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/_demos/mouse.go b/vendor/github.com/gdamore/tcell/v2/_demos/mouse.go deleted file mode 100644 index 9dbaee7..0000000 --- a/vendor/github.com/gdamore/tcell/v2/_demos/mouse.go +++ /dev/null @@ -1,276 +0,0 @@ -// +build ignore - -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// mouse displays a text box and tests mouse interaction. As you click -// and drag, boxes are displayed on screen. Other events are reported in -// the box. Press ESC twice to exit the program. -package main - -import ( - "fmt" - "os" - - "github.com/gdamore/tcell/v2" - "github.com/gdamore/tcell/v2/encoding" - - "github.com/mattn/go-runewidth" -) - -var defStyle tcell.Style - -func emitStr(s tcell.Screen, x, y int, style tcell.Style, str string) { - for _, c := range str { - var comb []rune - w := runewidth.RuneWidth(c) - if w == 0 { - comb = []rune{c} - c = ' ' - w = 1 - } - s.SetContent(x, y, c, comb, style) - x += w - } -} - -func drawBox(s tcell.Screen, x1, y1, x2, y2 int, style tcell.Style, r rune) { - if y2 < y1 { - y1, y2 = y2, y1 - } - if x2 < x1 { - x1, x2 = x2, x1 - } - - for col := x1; col <= x2; col++ { - s.SetContent(col, y1, tcell.RuneHLine, nil, style) - s.SetContent(col, y2, tcell.RuneHLine, nil, style) - } - for row := y1 + 1; row < y2; row++ { - s.SetContent(x1, row, tcell.RuneVLine, nil, style) - s.SetContent(x2, row, tcell.RuneVLine, nil, style) - } - if y1 != y2 && x1 != x2 { - // Only add corners if we need to - s.SetContent(x1, y1, tcell.RuneULCorner, nil, style) - s.SetContent(x2, y1, tcell.RuneURCorner, nil, style) - s.SetContent(x1, y2, tcell.RuneLLCorner, nil, style) - s.SetContent(x2, y2, tcell.RuneLRCorner, nil, style) - } - for row := y1 + 1; row < y2; row++ { - for col := x1 + 1; col < x2; col++ { - s.SetContent(col, row, r, nil, style) - } - } -} - -func drawSelect(s tcell.Screen, x1, y1, x2, y2 int, sel bool) { - - if y2 < y1 { - y1, y2 = y2, y1 - } - if x2 < x1 { - x1, x2 = x2, x1 - } - for row := y1; row <= y2; row++ { - for col := x1; col <= x2; col++ { - mainc, combc, style, width := s.GetContent(col, row) - if style == tcell.StyleDefault { - style = defStyle - } - style = style.Reverse(sel) - s.SetContent(col, row, mainc, combc, style) - col += width - 1 - } - } -} - -// This program just shows simple mouse and keyboard events. Press ESC twice to -// exit. -func main() { - - encoding.Register() - - s, e := tcell.NewScreen() - if e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - if e := s.Init(); e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - defStyle = tcell.StyleDefault. - Background(tcell.ColorReset). - Foreground(tcell.ColorReset) - s.SetStyle(defStyle) - s.EnableMouse() - s.EnablePaste() - s.Clear() - - posfmt := "Mouse: %d, %d " - btnfmt := "Buttons: %s" - keyfmt := "Keys: %s" - pastefmt := "Paste: [%d] %s" - white := tcell.StyleDefault. - Foreground(tcell.ColorWhite).Background(tcell.ColorRed) - - mx, my := -1, -1 - ox, oy := -1, -1 - bx, by := -1, -1 - w, h := s.Size() - lchar := '*' - bstr := "" - lks := "" - pstr := "" - ecnt := 0 - pasting := false - - for { - drawBox(s, 1, 1, 42, 7, white, ' ') - emitStr(s, 2, 2, white, "Press ESC twice to exit, C to clear.") - emitStr(s, 2, 3, white, fmt.Sprintf(posfmt, mx, my)) - emitStr(s, 2, 4, white, fmt.Sprintf(btnfmt, bstr)) - emitStr(s, 2, 5, white, fmt.Sprintf(keyfmt, lks)) - - ps := pstr - if len(ps) > 26 { - ps = "..." + ps[len(ps)-24:] - } - emitStr(s, 2, 6, white, fmt.Sprintf(pastefmt, len(pstr), ps)) - - s.Show() - bstr = "" - ev := s.PollEvent() - st := tcell.StyleDefault.Background(tcell.ColorRed) - up := tcell.StyleDefault. - Background(tcell.ColorBlue). - Foreground(tcell.ColorBlack) - w, h = s.Size() - - // always clear any old selection box - if ox >= 0 && oy >= 0 && bx >= 0 { - drawSelect(s, ox, oy, bx, by, false) - } - - switch ev := ev.(type) { - case *tcell.EventResize: - s.Sync() - s.SetContent(w-1, h-1, 'R', nil, st) - case *tcell.EventKey: - s.SetContent(w-2, h-2, ev.Rune(), nil, st) - if pasting { - s.SetContent(w-1, h-1, 'P', nil, st) - if ev.Key() == tcell.KeyRune { - pstr = pstr + string(ev.Rune()) - } else { - pstr = pstr + "\ufffd" // replacement for now - } - lks = "" - continue - } - pstr = "" - s.SetContent(w-1, h-1, 'K', nil, st) - if ev.Key() == tcell.KeyEscape { - ecnt++ - if ecnt > 1 { - s.Fini() - os.Exit(0) - } - } else if ev.Key() == tcell.KeyCtrlL { - s.Sync() - } else { - ecnt = 0 - if ev.Rune() == 'C' || ev.Rune() == 'c' { - s.Clear() - } - } - lks = ev.Name() - case *tcell.EventPaste: - pasting = ev.Start() - if pasting { - pstr = "" - } - case *tcell.EventMouse: - x, y := ev.Position() - button := ev.Buttons() - for i := uint(0); i < 8; i++ { - if int(button)&(1<= 0 { - bg := tcell.Color((lchar-'0')*2) | tcell.ColorValid - drawBox(s, ox, oy, x, y, - up.Background(bg), - lchar) - ox, oy = -1, -1 - bx, by = -1, -1 - } - case tcell.Button1: - ch = '1' - case tcell.Button2: - ch = '2' - case tcell.Button3: - ch = '3' - case tcell.Button4: - ch = '4' - case tcell.Button5: - ch = '5' - case tcell.Button6: - ch = '6' - case tcell.Button7: - ch = '7' - case tcell.Button8: - ch = '8' - default: - ch = '*' - - } - if button != tcell.ButtonNone { - bx, by = x, y - } - lchar = ch - s.SetContent(w-1, h-1, 'M', nil, st) - mx, my = x, y - default: - s.SetContent(w-1, h-1, 'X', nil, st) - } - - if ox >= 0 && bx >= 0 { - drawSelect(s, ox, oy, bx, by, true) - } - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/_demos/unicode.go b/vendor/github.com/gdamore/tcell/v2/_demos/unicode.go deleted file mode 100644 index 39144c4..0000000 --- a/vendor/github.com/gdamore/tcell/v2/_demos/unicode.go +++ /dev/null @@ -1,193 +0,0 @@ -// +build ignore - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// unicode just displays a Unicode test on your screen. -// Press ESC to exit the program. -package main - -import ( - "fmt" - "os" - - "github.com/gdamore/tcell/v2" - "github.com/gdamore/tcell/v2/encoding" - runewidth "github.com/mattn/go-runewidth" -) - -var row = 0 -var style = tcell.StyleDefault - -func putln(s tcell.Screen, str string) { - - puts(s, style, 1, row, str) - row++ -} - -func puts(s tcell.Screen, style tcell.Style, x, y int, str string) { - i := 0 - var deferred []rune - dwidth := 0 - zwj := false - for _, r := range str { - if r == '\u200d' { - if len(deferred) == 0 { - deferred = append(deferred, ' ') - dwidth = 1 - } - deferred = append(deferred, r) - zwj = true - continue - } - if zwj { - deferred = append(deferred, r) - zwj = false - continue - } - switch runewidth.RuneWidth(r) { - case 0: - if len(deferred) == 0 { - deferred = append(deferred, ' ') - dwidth = 1 - } - case 1: - if len(deferred) != 0 { - s.SetContent(x+i, y, deferred[0], deferred[1:], style) - i += dwidth - } - deferred = nil - dwidth = 1 - case 2: - if len(deferred) != 0 { - s.SetContent(x+i, y, deferred[0], deferred[1:], style) - i += dwidth - } - deferred = nil - dwidth = 2 - } - deferred = append(deferred, r) - } - if len(deferred) != 0 { - s.SetContent(x+i, y, deferred[0], deferred[1:], style) - i += dwidth - } -} - -func main() { - - s, e := tcell.NewScreen() - if e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - - encoding.Register() - - if e = s.Init(); e != nil { - fmt.Fprintf(os.Stderr, "%v\n", e) - os.Exit(1) - } - - plain := tcell.StyleDefault - bold := style.Bold(true) - - s.SetStyle(tcell.StyleDefault. - Foreground(tcell.ColorBlack). - Background(tcell.ColorWhite)) - s.Clear() - - quit := make(chan struct{}) - - style = bold - putln(s, "Press ESC to Exit") - putln(s, "Character set: "+s.CharacterSet()) - style = plain - - putln(s, "English: October") - putln(s, "Icelandic: október") - putln(s, "Arabic: أكتوبر") - putln(s, "Russian: октября") - putln(s, "Greek: Οκτωβρίου") - putln(s, "Chinese: 十月 (note, two double wide characters)") - putln(s, "Combining: A\u030a (should look like Angstrom)") - putln(s, "Emoticon: \U0001f618 (blowing a kiss)") - putln(s, "Airplane: \u2708 (fly away)") - putln(s, "Command: \u2318 (mac clover key)") - putln(s, "Enclose: !\u20e3 (should be enclosed exclamation)") - putln(s, "ZWJ: \U0001f9db\u200d\u2640 (female vampire)") - putln(s, "ZWJ: \U0001f9db\u200d\u2642 (male vampire)") - putln(s, "Family: \U0001f469\u200d\U0001f467\u200d\U0001f467 (woman girl girl)\n") - putln(s, "Region: \U0001f1fa\U0001f1f8 (USA! USA!)\n") - putln(s, "") - putln(s, "Box:") - putln(s, string([]rune{ - tcell.RuneULCorner, - tcell.RuneHLine, - tcell.RuneTTee, - tcell.RuneHLine, - tcell.RuneURCorner, - })) - putln(s, string([]rune{ - tcell.RuneVLine, - tcell.RuneBullet, - tcell.RuneVLine, - tcell.RuneLantern, - tcell.RuneVLine, - })+" (bullet, lantern/section)") - putln(s, string([]rune{ - tcell.RuneLTee, - tcell.RuneHLine, - tcell.RunePlus, - tcell.RuneHLine, - tcell.RuneRTee, - })) - putln(s, string([]rune{ - tcell.RuneVLine, - tcell.RuneDiamond, - tcell.RuneVLine, - tcell.RuneUArrow, - tcell.RuneVLine, - })+" (diamond, up arrow)") - putln(s, string([]rune{ - tcell.RuneLLCorner, - tcell.RuneHLine, - tcell.RuneBTee, - tcell.RuneHLine, - tcell.RuneLRCorner, - })) - - s.Show() - go func() { - for { - ev := s.PollEvent() - switch ev := ev.(type) { - case *tcell.EventKey: - switch ev.Key() { - case tcell.KeyEscape, tcell.KeyEnter: - close(quit) - return - case tcell.KeyCtrlL: - s.Sync() - } - case *tcell.EventResize: - s.Sync() - } - } - }() - - <-quit - - s.Fini() -} diff --git a/vendor/github.com/gdamore/tcell/v2/attr.go b/vendor/github.com/gdamore/tcell/v2/attr.go deleted file mode 100644 index 8b1eab7..0000000 --- a/vendor/github.com/gdamore/tcell/v2/attr.go +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// AttrMask represents a mask of text attributes, apart from color. -// Note that support for attributes may vary widely across terminals. -type AttrMask int - -// Attributes are not colors, but affect the display of text. They can -// be combined. -const ( - AttrBold AttrMask = 1 << iota - AttrBlink - AttrReverse - AttrUnderline - AttrDim - AttrItalic - AttrStrikeThrough - AttrInvalid // Mark the style or attributes invalid - AttrNone AttrMask = 0 // Just normal text. -) diff --git a/vendor/github.com/gdamore/tcell/v2/cell.go b/vendor/github.com/gdamore/tcell/v2/cell.go deleted file mode 100644 index c7f8f1a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/cell.go +++ /dev/null @@ -1,177 +0,0 @@ -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - runewidth "github.com/mattn/go-runewidth" -) - -type cell struct { - currMain rune - currComb []rune - currStyle Style - lastMain rune - lastStyle Style - lastComb []rune - width int -} - -// CellBuffer represents a two dimensional array of character cells. -// This is primarily intended for use by Screen implementors; it -// contains much of the common code they need. To create one, just -// declare a variable of its type; no explicit initialization is necessary. -// -// CellBuffer is not thread safe. -type CellBuffer struct { - w int - h int - cells []cell -} - -// SetContent sets the contents (primary rune, combining runes, -// and style) for a cell at a given location. -func (cb *CellBuffer) SetContent(x int, y int, - mainc rune, combc []rune, style Style) { - - if x >= 0 && y >= 0 && x < cb.w && y < cb.h { - c := &cb.cells[(y*cb.w)+x] - - c.currComb = append([]rune{}, combc...) - - if c.currMain != mainc { - c.width = runewidth.RuneWidth(mainc) - } - c.currMain = mainc - c.currStyle = style - } -} - -// GetContent returns the contents of a character cell, including the -// primary rune, any combining character runes (which will usually be -// nil), the style, and the display width in cells. (The width can be -// either 1, normally, or 2 for East Asian full-width characters.) -func (cb *CellBuffer) GetContent(x, y int) (rune, []rune, Style, int) { - var mainc rune - var combc []rune - var style Style - var width int - if x >= 0 && y >= 0 && x < cb.w && y < cb.h { - c := &cb.cells[(y*cb.w)+x] - mainc, combc, style = c.currMain, c.currComb, c.currStyle - if width = c.width; width == 0 || mainc < ' ' { - width = 1 - mainc = ' ' - } - } - return mainc, combc, style, width -} - -// Size returns the (width, height) in cells of the buffer. -func (cb *CellBuffer) Size() (int, int) { - return cb.w, cb.h -} - -// Invalidate marks all characters within the buffer as dirty. -func (cb *CellBuffer) Invalidate() { - for i := range cb.cells { - cb.cells[i].lastMain = rune(0) - } -} - -// Dirty checks if a character at the given location needs an -// to be refreshed on the physical display. This returns true -// if the cell content is different since the last time it was -// marked clean. -func (cb *CellBuffer) Dirty(x, y int) bool { - if x >= 0 && y >= 0 && x < cb.w && y < cb.h { - c := &cb.cells[(y*cb.w)+x] - if c.lastMain == rune(0) { - return true - } - if c.lastMain != c.currMain { - return true - } - if c.lastStyle != c.currStyle { - return true - } - if len(c.lastComb) != len(c.currComb) { - return true - } - for i := range c.lastComb { - if c.lastComb[i] != c.currComb[i] { - return true - } - } - } - return false -} - -// SetDirty is normally used to indicate that a cell has -// been displayed (in which case dirty is false), or to manually -// force a cell to be marked dirty. -func (cb *CellBuffer) SetDirty(x, y int, dirty bool) { - if x >= 0 && y >= 0 && x < cb.w && y < cb.h { - c := &cb.cells[(y*cb.w)+x] - if dirty { - c.lastMain = rune(0) - } else { - if c.currMain == rune(0) { - c.currMain = ' ' - } - c.lastMain = c.currMain - c.lastComb = c.currComb - c.lastStyle = c.currStyle - } - } -} - -// Resize is used to resize the cells array, with different dimensions, -// while preserving the original contents. The cells will be invalidated -// so that they can be redrawn. -func (cb *CellBuffer) Resize(w, h int) { - - if cb.h == h && cb.w == w { - return - } - - newc := make([]cell, w*h) - for y := 0; y < h && y < cb.h; y++ { - for x := 0; x < w && x < cb.w; x++ { - oc := &cb.cells[(y*cb.w)+x] - nc := &newc[(y*w)+x] - nc.currMain = oc.currMain - nc.currComb = oc.currComb - nc.currStyle = oc.currStyle - nc.width = oc.width - nc.lastMain = rune(0) - } - } - cb.cells = newc - cb.h = h - cb.w = w -} - -// Fill fills the entire cell buffer array with the specified character -// and style. Normally choose ' ' to clear the screen. This API doesn't -// support combining characters, or characters with a width larger than one. -func (cb *CellBuffer) Fill(r rune, style Style) { - for i := range cb.cells { - c := &cb.cells[i] - c.currMain = r - c.currComb = nil - c.currStyle = style - c.width = 1 - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/charset_stub.go b/vendor/github.com/gdamore/tcell/v2/charset_stub.go deleted file mode 100644 index c1c1594..0000000 --- a/vendor/github.com/gdamore/tcell/v2/charset_stub.go +++ /dev/null @@ -1,21 +0,0 @@ -// +build plan9 nacl - -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -func getCharset() string { - return "" -} diff --git a/vendor/github.com/gdamore/tcell/v2/charset_unix.go b/vendor/github.com/gdamore/tcell/v2/charset_unix.go deleted file mode 100644 index d9f9d8e..0000000 --- a/vendor/github.com/gdamore/tcell/v2/charset_unix.go +++ /dev/null @@ -1,49 +0,0 @@ -// +build !windows,!nacl,!plan9 - -// Copyright 2016 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "os" - "strings" -) - -func getCharset() string { - // Determine the character set. This can help us later. - // Per POSIX, we search for LC_ALL first, then LC_CTYPE, and - // finally LANG. First one set wins. - locale := "" - if locale = os.Getenv("LC_ALL"); locale == "" { - if locale = os.Getenv("LC_CTYPE"); locale == "" { - locale = os.Getenv("LANG") - } - } - if locale == "POSIX" || locale == "C" { - return "US-ASCII" - } - if i := strings.IndexRune(locale, '@'); i >= 0 { - locale = locale[:i] - } - if i := strings.IndexRune(locale, '.'); i >= 0 { - locale = locale[i+1:] - } else { - // Default assumption, and on Linux we can see LC_ALL - // without a character set, which we assume implies UTF-8. - return "UTF-8" - } - // XXX: add support for aliases - return locale -} diff --git a/vendor/github.com/gdamore/tcell/v2/charset_windows.go b/vendor/github.com/gdamore/tcell/v2/charset_windows.go deleted file mode 100644 index 2400aa8..0000000 --- a/vendor/github.com/gdamore/tcell/v2/charset_windows.go +++ /dev/null @@ -1,21 +0,0 @@ -// +build windows - -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -func getCharset() string { - return "UTF-16" -} diff --git a/vendor/github.com/gdamore/tcell/v2/color.go b/vendor/github.com/gdamore/tcell/v2/color.go deleted file mode 100644 index 8a13a07..0000000 --- a/vendor/github.com/gdamore/tcell/v2/color.go +++ /dev/null @@ -1,1069 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import "strconv" - -// Color represents a color. The low numeric values are the same as used -// by ECMA-48, and beyond that XTerm. A 24-bit RGB value may be used by -// adding in the ColorIsRGB flag. For Color names we use the W3C approved -// color names. -// -// We use a 64-bit integer to allow future expansion if we want to add an -// 8-bit alpha, while still leaving us some room for extra options. -// -// Note that on various terminals colors may be approximated however, or -// not supported at all. If no suitable representation for a color is known, -// the library will simply not set any color, deferring to whatever default -// attributes the terminal uses. -type Color uint64 - -const ( - // ColorDefault is used to leave the Color unchanged from whatever - // system or terminal default may exist. It's also the zero value. - ColorDefault Color = 0 - - // ColorIsValid is used to indicate the color value is actually - // valid (initialized). This is useful to permit the zero value - // to be treated as the default. - ColorValid Color = 1 << 32 - - // ColorIsRGB is used to indicate that the numeric value is not - // a known color constant, but rather an RGB value. The lower - // order 3 bytes are RGB. - ColorIsRGB Color = 1 << 33 - - // ColorSpecial is a flag used to indicate that the values have - // special meaning, and live outside of the color space(s). - ColorSpecial Color = 1 << 34 -) - -// Note that the order of these options is important -- it follows the -// definitions used by ECMA and XTerm. Hence any further named colors -// must begin at a value not less than 256. -const ( - ColorBlack = ColorValid + iota - ColorMaroon - ColorGreen - ColorOlive - ColorNavy - ColorPurple - ColorTeal - ColorSilver - ColorGray - ColorRed - ColorLime - ColorYellow - ColorBlue - ColorFuchsia - ColorAqua - ColorWhite - Color16 - Color17 - Color18 - Color19 - Color20 - Color21 - Color22 - Color23 - Color24 - Color25 - Color26 - Color27 - Color28 - Color29 - Color30 - Color31 - Color32 - Color33 - Color34 - Color35 - Color36 - Color37 - Color38 - Color39 - Color40 - Color41 - Color42 - Color43 - Color44 - Color45 - Color46 - Color47 - Color48 - Color49 - Color50 - Color51 - Color52 - Color53 - Color54 - Color55 - Color56 - Color57 - Color58 - Color59 - Color60 - Color61 - Color62 - Color63 - Color64 - Color65 - Color66 - Color67 - Color68 - Color69 - Color70 - Color71 - Color72 - Color73 - Color74 - Color75 - Color76 - Color77 - Color78 - Color79 - Color80 - Color81 - Color82 - Color83 - Color84 - Color85 - Color86 - Color87 - Color88 - Color89 - Color90 - Color91 - Color92 - Color93 - Color94 - Color95 - Color96 - Color97 - Color98 - Color99 - Color100 - Color101 - Color102 - Color103 - Color104 - Color105 - Color106 - Color107 - Color108 - Color109 - Color110 - Color111 - Color112 - Color113 - Color114 - Color115 - Color116 - Color117 - Color118 - Color119 - Color120 - Color121 - Color122 - Color123 - Color124 - Color125 - Color126 - Color127 - Color128 - Color129 - Color130 - Color131 - Color132 - Color133 - Color134 - Color135 - Color136 - Color137 - Color138 - Color139 - Color140 - Color141 - Color142 - Color143 - Color144 - Color145 - Color146 - Color147 - Color148 - Color149 - Color150 - Color151 - Color152 - Color153 - Color154 - Color155 - Color156 - Color157 - Color158 - Color159 - Color160 - Color161 - Color162 - Color163 - Color164 - Color165 - Color166 - Color167 - Color168 - Color169 - Color170 - Color171 - Color172 - Color173 - Color174 - Color175 - Color176 - Color177 - Color178 - Color179 - Color180 - Color181 - Color182 - Color183 - Color184 - Color185 - Color186 - Color187 - Color188 - Color189 - Color190 - Color191 - Color192 - Color193 - Color194 - Color195 - Color196 - Color197 - Color198 - Color199 - Color200 - Color201 - Color202 - Color203 - Color204 - Color205 - Color206 - Color207 - Color208 - Color209 - Color210 - Color211 - Color212 - Color213 - Color214 - Color215 - Color216 - Color217 - Color218 - Color219 - Color220 - Color221 - Color222 - Color223 - Color224 - Color225 - Color226 - Color227 - Color228 - Color229 - Color230 - Color231 - Color232 - Color233 - Color234 - Color235 - Color236 - Color237 - Color238 - Color239 - Color240 - Color241 - Color242 - Color243 - Color244 - Color245 - Color246 - Color247 - Color248 - Color249 - Color250 - Color251 - Color252 - Color253 - Color254 - Color255 - ColorAliceBlue - ColorAntiqueWhite - ColorAquaMarine - ColorAzure - ColorBeige - ColorBisque - ColorBlanchedAlmond - ColorBlueViolet - ColorBrown - ColorBurlyWood - ColorCadetBlue - ColorChartreuse - ColorChocolate - ColorCoral - ColorCornflowerBlue - ColorCornsilk - ColorCrimson - ColorDarkBlue - ColorDarkCyan - ColorDarkGoldenrod - ColorDarkGray - ColorDarkGreen - ColorDarkKhaki - ColorDarkMagenta - ColorDarkOliveGreen - ColorDarkOrange - ColorDarkOrchid - ColorDarkRed - ColorDarkSalmon - ColorDarkSeaGreen - ColorDarkSlateBlue - ColorDarkSlateGray - ColorDarkTurquoise - ColorDarkViolet - ColorDeepPink - ColorDeepSkyBlue - ColorDimGray - ColorDodgerBlue - ColorFireBrick - ColorFloralWhite - ColorForestGreen - ColorGainsboro - ColorGhostWhite - ColorGold - ColorGoldenrod - ColorGreenYellow - ColorHoneydew - ColorHotPink - ColorIndianRed - ColorIndigo - ColorIvory - ColorKhaki - ColorLavender - ColorLavenderBlush - ColorLawnGreen - ColorLemonChiffon - ColorLightBlue - ColorLightCoral - ColorLightCyan - ColorLightGoldenrodYellow - ColorLightGray - ColorLightGreen - ColorLightPink - ColorLightSalmon - ColorLightSeaGreen - ColorLightSkyBlue - ColorLightSlateGray - ColorLightSteelBlue - ColorLightYellow - ColorLimeGreen - ColorLinen - ColorMediumAquamarine - ColorMediumBlue - ColorMediumOrchid - ColorMediumPurple - ColorMediumSeaGreen - ColorMediumSlateBlue - ColorMediumSpringGreen - ColorMediumTurquoise - ColorMediumVioletRed - ColorMidnightBlue - ColorMintCream - ColorMistyRose - ColorMoccasin - ColorNavajoWhite - ColorOldLace - ColorOliveDrab - ColorOrange - ColorOrangeRed - ColorOrchid - ColorPaleGoldenrod - ColorPaleGreen - ColorPaleTurquoise - ColorPaleVioletRed - ColorPapayaWhip - ColorPeachPuff - ColorPeru - ColorPink - ColorPlum - ColorPowderBlue - ColorRebeccaPurple - ColorRosyBrown - ColorRoyalBlue - ColorSaddleBrown - ColorSalmon - ColorSandyBrown - ColorSeaGreen - ColorSeashell - ColorSienna - ColorSkyblue - ColorSlateBlue - ColorSlateGray - ColorSnow - ColorSpringGreen - ColorSteelBlue - ColorTan - ColorThistle - ColorTomato - ColorTurquoise - ColorViolet - ColorWheat - ColorWhiteSmoke - ColorYellowGreen -) - -// These are aliases for the color gray, because some of us spell -// it as grey. -const ( - ColorGrey = ColorGray - ColorDimGrey = ColorDimGray - ColorDarkGrey = ColorDarkGray - ColorDarkSlateGrey = ColorDarkSlateGray - ColorLightGrey = ColorLightGray - ColorLightSlateGrey = ColorLightSlateGray - ColorSlateGrey = ColorSlateGray -) - -// ColorValues maps color constants to their RGB values. -var ColorValues = map[Color]int32{ - ColorBlack: 0x000000, - ColorMaroon: 0x800000, - ColorGreen: 0x008000, - ColorOlive: 0x808000, - ColorNavy: 0x000080, - ColorPurple: 0x800080, - ColorTeal: 0x008080, - ColorSilver: 0xC0C0C0, - ColorGray: 0x808080, - ColorRed: 0xFF0000, - ColorLime: 0x00FF00, - ColorYellow: 0xFFFF00, - ColorBlue: 0x0000FF, - ColorFuchsia: 0xFF00FF, - ColorAqua: 0x00FFFF, - ColorWhite: 0xFFFFFF, - Color16: 0x000000, // black - Color17: 0x00005F, - Color18: 0x000087, - Color19: 0x0000AF, - Color20: 0x0000D7, - Color21: 0x0000FF, // blue - Color22: 0x005F00, - Color23: 0x005F5F, - Color24: 0x005F87, - Color25: 0x005FAF, - Color26: 0x005FD7, - Color27: 0x005FFF, - Color28: 0x008700, - Color29: 0x00875F, - Color30: 0x008787, - Color31: 0x0087Af, - Color32: 0x0087D7, - Color33: 0x0087FF, - Color34: 0x00AF00, - Color35: 0x00AF5F, - Color36: 0x00AF87, - Color37: 0x00AFAF, - Color38: 0x00AFD7, - Color39: 0x00AFFF, - Color40: 0x00D700, - Color41: 0x00D75F, - Color42: 0x00D787, - Color43: 0x00D7AF, - Color44: 0x00D7D7, - Color45: 0x00D7FF, - Color46: 0x00FF00, // lime - Color47: 0x00FF5F, - Color48: 0x00FF87, - Color49: 0x00FFAF, - Color50: 0x00FFd7, - Color51: 0x00FFFF, // aqua - Color52: 0x5F0000, - Color53: 0x5F005F, - Color54: 0x5F0087, - Color55: 0x5F00AF, - Color56: 0x5F00D7, - Color57: 0x5F00FF, - Color58: 0x5F5F00, - Color59: 0x5F5F5F, - Color60: 0x5F5F87, - Color61: 0x5F5FAF, - Color62: 0x5F5FD7, - Color63: 0x5F5FFF, - Color64: 0x5F8700, - Color65: 0x5F875F, - Color66: 0x5F8787, - Color67: 0x5F87AF, - Color68: 0x5F87D7, - Color69: 0x5F87FF, - Color70: 0x5FAF00, - Color71: 0x5FAF5F, - Color72: 0x5FAF87, - Color73: 0x5FAFAF, - Color74: 0x5FAFD7, - Color75: 0x5FAFFF, - Color76: 0x5FD700, - Color77: 0x5FD75F, - Color78: 0x5FD787, - Color79: 0x5FD7AF, - Color80: 0x5FD7D7, - Color81: 0x5FD7FF, - Color82: 0x5FFF00, - Color83: 0x5FFF5F, - Color84: 0x5FFF87, - Color85: 0x5FFFAF, - Color86: 0x5FFFD7, - Color87: 0x5FFFFF, - Color88: 0x870000, - Color89: 0x87005F, - Color90: 0x870087, - Color91: 0x8700AF, - Color92: 0x8700D7, - Color93: 0x8700FF, - Color94: 0x875F00, - Color95: 0x875F5F, - Color96: 0x875F87, - Color97: 0x875FAF, - Color98: 0x875FD7, - Color99: 0x875FFF, - Color100: 0x878700, - Color101: 0x87875F, - Color102: 0x878787, - Color103: 0x8787AF, - Color104: 0x8787D7, - Color105: 0x8787FF, - Color106: 0x87AF00, - Color107: 0x87AF5F, - Color108: 0x87AF87, - Color109: 0x87AFAF, - Color110: 0x87AFD7, - Color111: 0x87AFFF, - Color112: 0x87D700, - Color113: 0x87D75F, - Color114: 0x87D787, - Color115: 0x87D7AF, - Color116: 0x87D7D7, - Color117: 0x87D7FF, - Color118: 0x87FF00, - Color119: 0x87FF5F, - Color120: 0x87FF87, - Color121: 0x87FFAF, - Color122: 0x87FFD7, - Color123: 0x87FFFF, - Color124: 0xAF0000, - Color125: 0xAF005F, - Color126: 0xAF0087, - Color127: 0xAF00AF, - Color128: 0xAF00D7, - Color129: 0xAF00FF, - Color130: 0xAF5F00, - Color131: 0xAF5F5F, - Color132: 0xAF5F87, - Color133: 0xAF5FAF, - Color134: 0xAF5FD7, - Color135: 0xAF5FFF, - Color136: 0xAF8700, - Color137: 0xAF875F, - Color138: 0xAF8787, - Color139: 0xAF87AF, - Color140: 0xAF87D7, - Color141: 0xAF87FF, - Color142: 0xAFAF00, - Color143: 0xAFAF5F, - Color144: 0xAFAF87, - Color145: 0xAFAFAF, - Color146: 0xAFAFD7, - Color147: 0xAFAFFF, - Color148: 0xAFD700, - Color149: 0xAFD75F, - Color150: 0xAFD787, - Color151: 0xAFD7AF, - Color152: 0xAFD7D7, - Color153: 0xAFD7FF, - Color154: 0xAFFF00, - Color155: 0xAFFF5F, - Color156: 0xAFFF87, - Color157: 0xAFFFAF, - Color158: 0xAFFFD7, - Color159: 0xAFFFFF, - Color160: 0xD70000, - Color161: 0xD7005F, - Color162: 0xD70087, - Color163: 0xD700AF, - Color164: 0xD700D7, - Color165: 0xD700FF, - Color166: 0xD75F00, - Color167: 0xD75F5F, - Color168: 0xD75F87, - Color169: 0xD75FAF, - Color170: 0xD75FD7, - Color171: 0xD75FFF, - Color172: 0xD78700, - Color173: 0xD7875F, - Color174: 0xD78787, - Color175: 0xD787AF, - Color176: 0xD787D7, - Color177: 0xD787FF, - Color178: 0xD7AF00, - Color179: 0xD7AF5F, - Color180: 0xD7AF87, - Color181: 0xD7AFAF, - Color182: 0xD7AFD7, - Color183: 0xD7AFFF, - Color184: 0xD7D700, - Color185: 0xD7D75F, - Color186: 0xD7D787, - Color187: 0xD7D7AF, - Color188: 0xD7D7D7, - Color189: 0xD7D7FF, - Color190: 0xD7FF00, - Color191: 0xD7FF5F, - Color192: 0xD7FF87, - Color193: 0xD7FFAF, - Color194: 0xD7FFD7, - Color195: 0xD7FFFF, - Color196: 0xFF0000, // red - Color197: 0xFF005F, - Color198: 0xFF0087, - Color199: 0xFF00AF, - Color200: 0xFF00D7, - Color201: 0xFF00FF, // fuchsia - Color202: 0xFF5F00, - Color203: 0xFF5F5F, - Color204: 0xFF5F87, - Color205: 0xFF5FAF, - Color206: 0xFF5FD7, - Color207: 0xFF5FFF, - Color208: 0xFF8700, - Color209: 0xFF875F, - Color210: 0xFF8787, - Color211: 0xFF87AF, - Color212: 0xFF87D7, - Color213: 0xFF87FF, - Color214: 0xFFAF00, - Color215: 0xFFAF5F, - Color216: 0xFFAF87, - Color217: 0xFFAFAF, - Color218: 0xFFAFD7, - Color219: 0xFFAFFF, - Color220: 0xFFD700, - Color221: 0xFFD75F, - Color222: 0xFFD787, - Color223: 0xFFD7AF, - Color224: 0xFFD7D7, - Color225: 0xFFD7FF, - Color226: 0xFFFF00, // yellow - Color227: 0xFFFF5F, - Color228: 0xFFFF87, - Color229: 0xFFFFAF, - Color230: 0xFFFFD7, - Color231: 0xFFFFFF, // white - Color232: 0x080808, - Color233: 0x121212, - Color234: 0x1C1C1C, - Color235: 0x262626, - Color236: 0x303030, - Color237: 0x3A3A3A, - Color238: 0x444444, - Color239: 0x4E4E4E, - Color240: 0x585858, - Color241: 0x626262, - Color242: 0x6C6C6C, - Color243: 0x767676, - Color244: 0x808080, // grey - Color245: 0x8A8A8A, - Color246: 0x949494, - Color247: 0x9E9E9E, - Color248: 0xA8A8A8, - Color249: 0xB2B2B2, - Color250: 0xBCBCBC, - Color251: 0xC6C6C6, - Color252: 0xD0D0D0, - Color253: 0xDADADA, - Color254: 0xE4E4E4, - Color255: 0xEEEEEE, - ColorAliceBlue: 0xF0F8FF, - ColorAntiqueWhite: 0xFAEBD7, - ColorAquaMarine: 0x7FFFD4, - ColorAzure: 0xF0FFFF, - ColorBeige: 0xF5F5DC, - ColorBisque: 0xFFE4C4, - ColorBlanchedAlmond: 0xFFEBCD, - ColorBlueViolet: 0x8A2BE2, - ColorBrown: 0xA52A2A, - ColorBurlyWood: 0xDEB887, - ColorCadetBlue: 0x5F9EA0, - ColorChartreuse: 0x7FFF00, - ColorChocolate: 0xD2691E, - ColorCoral: 0xFF7F50, - ColorCornflowerBlue: 0x6495ED, - ColorCornsilk: 0xFFF8DC, - ColorCrimson: 0xDC143C, - ColorDarkBlue: 0x00008B, - ColorDarkCyan: 0x008B8B, - ColorDarkGoldenrod: 0xB8860B, - ColorDarkGray: 0xA9A9A9, - ColorDarkGreen: 0x006400, - ColorDarkKhaki: 0xBDB76B, - ColorDarkMagenta: 0x8B008B, - ColorDarkOliveGreen: 0x556B2F, - ColorDarkOrange: 0xFF8C00, - ColorDarkOrchid: 0x9932CC, - ColorDarkRed: 0x8B0000, - ColorDarkSalmon: 0xE9967A, - ColorDarkSeaGreen: 0x8FBC8F, - ColorDarkSlateBlue: 0x483D8B, - ColorDarkSlateGray: 0x2F4F4F, - ColorDarkTurquoise: 0x00CED1, - ColorDarkViolet: 0x9400D3, - ColorDeepPink: 0xFF1493, - ColorDeepSkyBlue: 0x00BFFF, - ColorDimGray: 0x696969, - ColorDodgerBlue: 0x1E90FF, - ColorFireBrick: 0xB22222, - ColorFloralWhite: 0xFFFAF0, - ColorForestGreen: 0x228B22, - ColorGainsboro: 0xDCDCDC, - ColorGhostWhite: 0xF8F8FF, - ColorGold: 0xFFD700, - ColorGoldenrod: 0xDAA520, - ColorGreenYellow: 0xADFF2F, - ColorHoneydew: 0xF0FFF0, - ColorHotPink: 0xFF69B4, - ColorIndianRed: 0xCD5C5C, - ColorIndigo: 0x4B0082, - ColorIvory: 0xFFFFF0, - ColorKhaki: 0xF0E68C, - ColorLavender: 0xE6E6FA, - ColorLavenderBlush: 0xFFF0F5, - ColorLawnGreen: 0x7CFC00, - ColorLemonChiffon: 0xFFFACD, - ColorLightBlue: 0xADD8E6, - ColorLightCoral: 0xF08080, - ColorLightCyan: 0xE0FFFF, - ColorLightGoldenrodYellow: 0xFAFAD2, - ColorLightGray: 0xD3D3D3, - ColorLightGreen: 0x90EE90, - ColorLightPink: 0xFFB6C1, - ColorLightSalmon: 0xFFA07A, - ColorLightSeaGreen: 0x20B2AA, - ColorLightSkyBlue: 0x87CEFA, - ColorLightSlateGray: 0x778899, - ColorLightSteelBlue: 0xB0C4DE, - ColorLightYellow: 0xFFFFE0, - ColorLimeGreen: 0x32CD32, - ColorLinen: 0xFAF0E6, - ColorMediumAquamarine: 0x66CDAA, - ColorMediumBlue: 0x0000CD, - ColorMediumOrchid: 0xBA55D3, - ColorMediumPurple: 0x9370DB, - ColorMediumSeaGreen: 0x3CB371, - ColorMediumSlateBlue: 0x7B68EE, - ColorMediumSpringGreen: 0x00FA9A, - ColorMediumTurquoise: 0x48D1CC, - ColorMediumVioletRed: 0xC71585, - ColorMidnightBlue: 0x191970, - ColorMintCream: 0xF5FFFA, - ColorMistyRose: 0xFFE4E1, - ColorMoccasin: 0xFFE4B5, - ColorNavajoWhite: 0xFFDEAD, - ColorOldLace: 0xFDF5E6, - ColorOliveDrab: 0x6B8E23, - ColorOrange: 0xFFA500, - ColorOrangeRed: 0xFF4500, - ColorOrchid: 0xDA70D6, - ColorPaleGoldenrod: 0xEEE8AA, - ColorPaleGreen: 0x98FB98, - ColorPaleTurquoise: 0xAFEEEE, - ColorPaleVioletRed: 0xDB7093, - ColorPapayaWhip: 0xFFEFD5, - ColorPeachPuff: 0xFFDAB9, - ColorPeru: 0xCD853F, - ColorPink: 0xFFC0CB, - ColorPlum: 0xDDA0DD, - ColorPowderBlue: 0xB0E0E6, - ColorRebeccaPurple: 0x663399, - ColorRosyBrown: 0xBC8F8F, - ColorRoyalBlue: 0x4169E1, - ColorSaddleBrown: 0x8B4513, - ColorSalmon: 0xFA8072, - ColorSandyBrown: 0xF4A460, - ColorSeaGreen: 0x2E8B57, - ColorSeashell: 0xFFF5EE, - ColorSienna: 0xA0522D, - ColorSkyblue: 0x87CEEB, - ColorSlateBlue: 0x6A5ACD, - ColorSlateGray: 0x708090, - ColorSnow: 0xFFFAFA, - ColorSpringGreen: 0x00FF7F, - ColorSteelBlue: 0x4682B4, - ColorTan: 0xD2B48C, - ColorThistle: 0xD8BFD8, - ColorTomato: 0xFF6347, - ColorTurquoise: 0x40E0D0, - ColorViolet: 0xEE82EE, - ColorWheat: 0xF5DEB3, - ColorWhiteSmoke: 0xF5F5F5, - ColorYellowGreen: 0x9ACD32, -} - -// Special colors. -const ( - // ColorReset is used to indicate that the color should use the - // vanilla terminal colors. (Basically go back to the defaults.) - ColorReset = ColorSpecial | iota -) - -// ColorNames holds the written names of colors. Useful to present a list of -// recognized named colors. -var ColorNames = map[string]Color{ - "black": ColorBlack, - "maroon": ColorMaroon, - "green": ColorGreen, - "olive": ColorOlive, - "navy": ColorNavy, - "purple": ColorPurple, - "teal": ColorTeal, - "silver": ColorSilver, - "gray": ColorGray, - "red": ColorRed, - "lime": ColorLime, - "yellow": ColorYellow, - "blue": ColorBlue, - "fuchsia": ColorFuchsia, - "aqua": ColorAqua, - "white": ColorWhite, - "aliceblue": ColorAliceBlue, - "antiquewhite": ColorAntiqueWhite, - "aquamarine": ColorAquaMarine, - "azure": ColorAzure, - "beige": ColorBeige, - "bisque": ColorBisque, - "blanchedalmond": ColorBlanchedAlmond, - "blueviolet": ColorBlueViolet, - "brown": ColorBrown, - "burlywood": ColorBurlyWood, - "cadetblue": ColorCadetBlue, - "chartreuse": ColorChartreuse, - "chocolate": ColorChocolate, - "coral": ColorCoral, - "cornflowerblue": ColorCornflowerBlue, - "cornsilk": ColorCornsilk, - "crimson": ColorCrimson, - "darkblue": ColorDarkBlue, - "darkcyan": ColorDarkCyan, - "darkgoldenrod": ColorDarkGoldenrod, - "darkgray": ColorDarkGray, - "darkgreen": ColorDarkGreen, - "darkkhaki": ColorDarkKhaki, - "darkmagenta": ColorDarkMagenta, - "darkolivegreen": ColorDarkOliveGreen, - "darkorange": ColorDarkOrange, - "darkorchid": ColorDarkOrchid, - "darkred": ColorDarkRed, - "darksalmon": ColorDarkSalmon, - "darkseagreen": ColorDarkSeaGreen, - "darkslateblue": ColorDarkSlateBlue, - "darkslategray": ColorDarkSlateGray, - "darkturquoise": ColorDarkTurquoise, - "darkviolet": ColorDarkViolet, - "deeppink": ColorDeepPink, - "deepskyblue": ColorDeepSkyBlue, - "dimgray": ColorDimGray, - "dodgerblue": ColorDodgerBlue, - "firebrick": ColorFireBrick, - "floralwhite": ColorFloralWhite, - "forestgreen": ColorForestGreen, - "gainsboro": ColorGainsboro, - "ghostwhite": ColorGhostWhite, - "gold": ColorGold, - "goldenrod": ColorGoldenrod, - "greenyellow": ColorGreenYellow, - "honeydew": ColorHoneydew, - "hotpink": ColorHotPink, - "indianred": ColorIndianRed, - "indigo": ColorIndigo, - "ivory": ColorIvory, - "khaki": ColorKhaki, - "lavender": ColorLavender, - "lavenderblush": ColorLavenderBlush, - "lawngreen": ColorLawnGreen, - "lemonchiffon": ColorLemonChiffon, - "lightblue": ColorLightBlue, - "lightcoral": ColorLightCoral, - "lightcyan": ColorLightCyan, - "lightgoldenrodyellow": ColorLightGoldenrodYellow, - "lightgray": ColorLightGray, - "lightgreen": ColorLightGreen, - "lightpink": ColorLightPink, - "lightsalmon": ColorLightSalmon, - "lightseagreen": ColorLightSeaGreen, - "lightskyblue": ColorLightSkyBlue, - "lightslategray": ColorLightSlateGray, - "lightsteelblue": ColorLightSteelBlue, - "lightyellow": ColorLightYellow, - "limegreen": ColorLimeGreen, - "linen": ColorLinen, - "mediumaquamarine": ColorMediumAquamarine, - "mediumblue": ColorMediumBlue, - "mediumorchid": ColorMediumOrchid, - "mediumpurple": ColorMediumPurple, - "mediumseagreen": ColorMediumSeaGreen, - "mediumslateblue": ColorMediumSlateBlue, - "mediumspringgreen": ColorMediumSpringGreen, - "mediumturquoise": ColorMediumTurquoise, - "mediumvioletred": ColorMediumVioletRed, - "midnightblue": ColorMidnightBlue, - "mintcream": ColorMintCream, - "mistyrose": ColorMistyRose, - "moccasin": ColorMoccasin, - "navajowhite": ColorNavajoWhite, - "oldlace": ColorOldLace, - "olivedrab": ColorOliveDrab, - "orange": ColorOrange, - "orangered": ColorOrangeRed, - "orchid": ColorOrchid, - "palegoldenrod": ColorPaleGoldenrod, - "palegreen": ColorPaleGreen, - "paleturquoise": ColorPaleTurquoise, - "palevioletred": ColorPaleVioletRed, - "papayawhip": ColorPapayaWhip, - "peachpuff": ColorPeachPuff, - "peru": ColorPeru, - "pink": ColorPink, - "plum": ColorPlum, - "powderblue": ColorPowderBlue, - "rebeccapurple": ColorRebeccaPurple, - "rosybrown": ColorRosyBrown, - "royalblue": ColorRoyalBlue, - "saddlebrown": ColorSaddleBrown, - "salmon": ColorSalmon, - "sandybrown": ColorSandyBrown, - "seagreen": ColorSeaGreen, - "seashell": ColorSeashell, - "sienna": ColorSienna, - "skyblue": ColorSkyblue, - "slateblue": ColorSlateBlue, - "slategray": ColorSlateGray, - "snow": ColorSnow, - "springgreen": ColorSpringGreen, - "steelblue": ColorSteelBlue, - "tan": ColorTan, - "thistle": ColorThistle, - "tomato": ColorTomato, - "turquoise": ColorTurquoise, - "violet": ColorViolet, - "wheat": ColorWheat, - "whitesmoke": ColorWhiteSmoke, - "yellowgreen": ColorYellowGreen, - "grey": ColorGray, - "dimgrey": ColorDimGray, - "darkgrey": ColorDarkGray, - "darkslategrey": ColorDarkSlateGray, - "lightgrey": ColorLightGray, - "lightslategrey": ColorLightSlateGray, - "slategrey": ColorSlateGray, -} - -// Valid indicates the color is a valid value (has been set). -func (c Color) Valid() bool { - return c&ColorValid != 0 -} - -// IsRGB is true if the color is an RGB specific value. -func (c Color) IsRGB() bool { - return c&(ColorValid|ColorIsRGB) == (ColorValid | ColorIsRGB) -} - -// Hex returns the color's hexadecimal RGB 24-bit value with each component -// consisting of a single byte, ala R << 16 | G << 8 | B. If the color -// is unknown or unset, -1 is returned. -func (c Color) Hex() int32 { - if !c.Valid() { - return -1 - } - if c&ColorIsRGB != 0 { - return int32(c) & 0xffffff - } - if v, ok := ColorValues[c]; ok { - return v - } - return -1 -} - -// RGB returns the red, green, and blue components of the color, with -// each component represented as a value 0-255. In the event that the -// color cannot be broken up (not set usually), -1 is returned for each value. -func (c Color) RGB() (int32, int32, int32) { - v := c.Hex() - if v < 0 { - return -1, -1, -1 - } - return (v >> 16) & 0xff, (v >> 8) & 0xff, v & 0xff -} - -// TrueColor returns the true color (RGB) version of the provided color. -// This is useful for ensuring color accuracy when using named colors. -// This will override terminal theme colors. -func (c Color) TrueColor() Color { - if !c.Valid() { - return ColorDefault - } - if c&ColorIsRGB != 0 { - return c - } - return Color(c.Hex()) | ColorIsRGB | ColorValid -} - -// NewRGBColor returns a new color with the given red, green, and blue values. -// Each value must be represented in the range 0-255. -func NewRGBColor(r, g, b int32) Color { - return NewHexColor(((r & 0xff) << 16) | ((g & 0xff) << 8) | (b & 0xff)) -} - -// NewHexColor returns a color using the given 24-bit RGB value. -func NewHexColor(v int32) Color { - return ColorIsRGB | Color(v) | ColorValid -} - -// GetColor creates a Color from a color name (W3C name). A hex value may -// be supplied as a string in the format "#ffffff". -func GetColor(name string) Color { - if c, ok := ColorNames[name]; ok { - return c - } - if len(name) == 7 && name[0] == '#' { - if v, e := strconv.ParseInt(name[1:], 16, 32); e == nil { - return NewHexColor(int32(v)) - } - } - return ColorDefault -} - -// PaletteColor creates a color based on the palette index. -func PaletteColor(index int) Color { - return Color(index) | ColorValid -} \ No newline at end of file diff --git a/vendor/github.com/gdamore/tcell/v2/color_test.go b/vendor/github.com/gdamore/tcell/v2/color_test.go deleted file mode 100644 index a724f1f..0000000 --- a/vendor/github.com/gdamore/tcell/v2/color_test.go +++ /dev/null @@ -1,112 +0,0 @@ -// Copyright 2018 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "testing" -) - -func TestColorValues(t *testing.T) { - var values = []struct { - color Color - hex int32 - }{ - {ColorRed, 0x00FF0000}, - {ColorGreen, 0x00008000}, - {ColorLime, 0x0000FF00}, - {ColorBlue, 0x000000FF}, - {ColorBlack, 0x00000000}, - {ColorWhite, 0x00FFFFFF}, - {ColorSilver, 0x00C0C0C0}, - } - - for _, tc := range values { - if tc.color.Hex() != tc.hex { - t.Errorf("Color: %x != %x", tc.color.Hex(), tc.hex) - } - } -} - -func TestColorFitting(t *testing.T) { - pal := []Color{} - for i := 0; i < 255; i++ { - pal = append(pal, PaletteColor(i)) - } - - // Exact color fitting on ANSI colors - for i := 0; i < 7; i++ { - if FindColor(PaletteColor(i), pal[:8]) != PaletteColor(i) { - t.Errorf("Color ANSI fit fail at %d", i) - } - } - // Grey is closest to Silver - if FindColor(PaletteColor(8), pal[:8]) != PaletteColor(7) { - t.Errorf("Grey does not fit to silver") - } - // Color fitting of upper 8 colors. - for i := 9; i < 16; i++ { - if FindColor(PaletteColor(i), pal[:8]) != PaletteColor(i%8) { - t.Errorf("Color fit fail at %d", i) - } - } - // Imperfect fit - if FindColor(ColorOrangeRed, pal[:16]) != ColorRed || - FindColor(ColorAliceBlue, pal[:16]) != ColorWhite || - FindColor(ColorPink, pal) != Color217 || - FindColor(ColorSienna, pal) != Color173 || - FindColor(GetColor("#00FD00"), pal) != ColorLime { - t.Errorf("Imperfect color fit") - } - -} - -func TestColorNameLookup(t *testing.T) { - var values = []struct { - name string - color Color - rgb bool - }{ - {"#FF0000", ColorRed, true}, - {"black", ColorBlack, false}, - {"orange", ColorOrange, false}, - {"door", ColorDefault, false}, - } - for _, v := range values { - c := GetColor(v.name) - if c.Hex() != v.color.Hex() { - t.Errorf("Wrong color for %v: %v", v.name, c.Hex()) - } - if v.rgb { - if c & ColorIsRGB == 0 { - t.Errorf("Color should have RGB") - } - } else { - if c & ColorIsRGB != 0 { - t.Errorf("Named color should not be RGB") - } - } - - if c.TrueColor().Hex() != v.color.Hex() { - t.Errorf("TrueColor did not match") - } - } -} - -func TestColorRGB(t *testing.T) { - r, g, b := GetColor("#112233").RGB() - if r != 0x11 || g != 0x22 || b != 0x33 { - t.Errorf("RGB wrong (%x, %x, %x)", r, g, b) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/colorfit.go b/vendor/github.com/gdamore/tcell/v2/colorfit.go deleted file mode 100644 index b7740b8..0000000 --- a/vendor/github.com/gdamore/tcell/v2/colorfit.go +++ /dev/null @@ -1,52 +0,0 @@ -// Copyright 2016 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "github.com/lucasb-eyer/go-colorful" - "math" -) - -// FindColor attempts to find a given color, or the best match possible for it, -// from the palette given. This is an expensive operation, so results should -// be cached by the caller. -func FindColor(c Color, palette []Color) Color { - match := ColorDefault - dist := float64(0) - r, g, b := c.RGB() - c1 := colorful.Color{ - R: float64(r) / 255.0, - G: float64(g) / 255.0, - B: float64(b) / 255.0, - } - for _, d := range palette { - r, g, b = d.RGB() - c2 := colorful.Color{ - R: float64(r) / 255.0, - G: float64(g) / 255.0, - B: float64(b) / 255.0, - } - // CIE94 is more accurate, but really really expensive. - nd := c1.DistanceCIE76(c2) - if math.IsNaN(nd) { - nd = math.Inf(1) - } - if match == ColorDefault || nd < dist { - match = d - dist = nd - } - } - return match -} diff --git a/vendor/github.com/gdamore/tcell/v2/console_stub.go b/vendor/github.com/gdamore/tcell/v2/console_stub.go deleted file mode 100644 index fda2f09..0000000 --- a/vendor/github.com/gdamore/tcell/v2/console_stub.go +++ /dev/null @@ -1,23 +0,0 @@ -// +build !windows - -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// NewConsoleScreen returns a console based screen. This platform -// doesn't have support for any, so it returns nil and a suitable error. -func NewConsoleScreen() (Screen, error) { - return nil, ErrNoScreen -} diff --git a/vendor/github.com/gdamore/tcell/v2/console_win.go b/vendor/github.com/gdamore/tcell/v2/console_win.go deleted file mode 100644 index 0c2493b..0000000 --- a/vendor/github.com/gdamore/tcell/v2/console_win.go +++ /dev/null @@ -1,1187 +0,0 @@ -// +build windows - -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "errors" - "fmt" - "os" - "strings" - "sync" - "syscall" - "unicode/utf16" - "unsafe" -) - -type cScreen struct { - in syscall.Handle - out syscall.Handle - cancelflag syscall.Handle - scandone chan struct{} - evch chan Event - quit chan struct{} - curx int - cury int - style Style - clear bool - fini bool - vten bool - truecolor bool - - w int - h int - - oscreen consoleInfo - ocursor cursorInfo - oimode uint32 - oomode uint32 - cells CellBuffer - - finiOnce sync.Once - - sync.Mutex -} - -var winLock sync.Mutex - -var winPalette = []Color{ - ColorBlack, - ColorMaroon, - ColorGreen, - ColorNavy, - ColorOlive, - ColorPurple, - ColorTeal, - ColorSilver, - ColorGray, - ColorRed, - ColorLime, - ColorBlue, - ColorYellow, - ColorFuchsia, - ColorAqua, - ColorWhite, -} - -var winColors = map[Color]Color{ - ColorBlack: ColorBlack, - ColorMaroon: ColorMaroon, - ColorGreen: ColorGreen, - ColorNavy: ColorNavy, - ColorOlive: ColorOlive, - ColorPurple: ColorPurple, - ColorTeal: ColorTeal, - ColorSilver: ColorSilver, - ColorGray: ColorGray, - ColorRed: ColorRed, - ColorLime: ColorLime, - ColorBlue: ColorBlue, - ColorYellow: ColorYellow, - ColorFuchsia: ColorFuchsia, - ColorAqua: ColorAqua, - ColorWhite: ColorWhite, -} - -var ( - k32 = syscall.NewLazyDLL("kernel32.dll") - u32 = syscall.NewLazyDLL("user32.dll") -) - -// We have to bring in the kernel32 and user32 DLLs directly, so we can get -// access to some system calls that the core Go API lacks. -// -// Note that Windows appends some functions with W to indicate that wide -// characters (Unicode) are in use. The documentation refers to them -// without this suffix, as the resolution is made via preprocessor. -var ( - procReadConsoleInput = k32.NewProc("ReadConsoleInputW") - procWaitForMultipleObjects = k32.NewProc("WaitForMultipleObjects") - procCreateEvent = k32.NewProc("CreateEventW") - procSetEvent = k32.NewProc("SetEvent") - procGetConsoleCursorInfo = k32.NewProc("GetConsoleCursorInfo") - procSetConsoleCursorInfo = k32.NewProc("SetConsoleCursorInfo") - procSetConsoleCursorPosition = k32.NewProc("SetConsoleCursorPosition") - procSetConsoleMode = k32.NewProc("SetConsoleMode") - procGetConsoleMode = k32.NewProc("GetConsoleMode") - procGetConsoleScreenBufferInfo = k32.NewProc("GetConsoleScreenBufferInfo") - procFillConsoleOutputAttribute = k32.NewProc("FillConsoleOutputAttribute") - procFillConsoleOutputCharacter = k32.NewProc("FillConsoleOutputCharacterW") - procSetConsoleWindowInfo = k32.NewProc("SetConsoleWindowInfo") - procSetConsoleScreenBufferSize = k32.NewProc("SetConsoleScreenBufferSize") - procSetConsoleTextAttribute = k32.NewProc("SetConsoleTextAttribute") - procMessageBeep = u32.NewProc("MessageBeep") -) - -const ( - w32Infinite = ^uintptr(0) - w32WaitObject0 = uintptr(0) -) - -const ( - // VT100/XTerm escapes understood by the console - vtShowCursor = "\x1b[?25h" - vtHideCursor = "\x1b[?25l" - vtCursorPos = "\x1b[%d;%dH" // Note that it is Y then X - vtSgr0 = "\x1b[0m" - vtBold = "\x1b[1m" - vtUnderline = "\x1b[4m" - vtBlink = "\x1b[5m" // Not sure this is processed - vtReverse = "\x1b[7m" - vtSetFg = "\x1b[38;5;%dm" - vtSetBg = "\x1b[48;5;%dm" - vtSetFgRGB = "\x1b[38;2;%d;%d;%dm" // RGB - vtSetBgRGB = "\x1b[48;2;%d;%d;%dm" // RGB -) - -// NewConsoleScreen returns a Screen for the Windows console associated -// with the current process. The Screen makes use of the Windows Console -// API to display content and read events. -func NewConsoleScreen() (Screen, error) { - return &cScreen{}, nil -} - -func (s *cScreen) Init() error { - s.evch = make(chan Event, 10) - s.quit = make(chan struct{}) - s.scandone = make(chan struct{}) - - in, e := syscall.Open("CONIN$", syscall.O_RDWR, 0) - if e != nil { - return e - } - s.in = in - out, e := syscall.Open("CONOUT$", syscall.O_RDWR, 0) - if e != nil { - syscall.Close(s.in) - return e - } - s.out = out - - s.truecolor = true - - // ConEmu handling of colors and scrolling when in terminal - // mode is extremely problematic at the best. The color - // palette will scroll even though characters do not, when - // emiting stuff for the last character. In the future we - // might change this to look at specific versions of ConEmu - // if they fix the bug. - if os.Getenv("ConEmuPID") != "" { - s.truecolor = false - } - switch os.Getenv("TCELL_TRUECOLOR") { - case "disable": - s.truecolor = false - case "enable": - s.truecolor = true - } - - cf, _, e := procCreateEvent.Call( - uintptr(0), - uintptr(1), - uintptr(0), - uintptr(0)) - if cf == uintptr(0) { - return e - } - s.cancelflag = syscall.Handle(cf) - - s.Lock() - - s.curx = -1 - s.cury = -1 - s.style = StyleDefault - s.getCursorInfo(&s.ocursor) - s.getConsoleInfo(&s.oscreen) - s.getOutMode(&s.oomode) - s.getInMode(&s.oimode) - s.resize() - - s.fini = false - s.setInMode(modeResizeEn | modeExtndFlg) - - // 24-bit color is opt-in for now, because we can't figure out - // to make it work consistently. - if s.truecolor { - s.setOutMode(modeVtOutput | modeNoAutoNL | modeCookedOut) - var omode uint32 - s.getOutMode(&omode) - if omode&modeVtOutput == modeVtOutput { - s.vten = true - } else { - s.truecolor = false - s.setOutMode(0) - } - } else { - s.setOutMode(0) - } - - s.clearScreen(s.style) - s.hideCursor() - s.Unlock() - go s.scanInput() - - return nil -} - -func (s *cScreen) CharacterSet() string { - // We are always UTF-16LE on Windows - return "UTF-16LE" -} - -func (s *cScreen) EnableMouse() { - s.setInMode(modeResizeEn | modeMouseEn | modeExtndFlg) -} - -func (s *cScreen) DisableMouse() { - s.setInMode(modeResizeEn | modeExtndFlg) -} - -func (s *cScreen) EnablePaste() {} - -func (s *cScreen) DisablePaste() {} - -func (s *cScreen) Fini() { - s.finiOnce.Do(s.finish) -} - -func (s *cScreen) finish() { - s.Lock() - s.style = StyleDefault - s.curx = -1 - s.cury = -1 - s.fini = true - s.vten = false - s.Unlock() - - s.setCursorInfo(&s.ocursor) - s.setInMode(s.oimode) - s.setOutMode(s.oomode) - s.setBufferSize(int(s.oscreen.size.x), int(s.oscreen.size.y)) - s.clearScreen(StyleDefault) - s.setCursorPos(0, 0) - procSetConsoleTextAttribute.Call( - uintptr(s.out), - uintptr(s.mapStyle(StyleDefault))) - - close(s.quit) - procSetEvent.Call(uintptr(s.cancelflag)) - // Block until scanInput returns; this prevents a race condition on Win 8+ - // which causes syscall.Close to block until another keypress is read. - <-s.scandone - syscall.Close(s.in) - syscall.Close(s.out) -} - -func (s *cScreen) PostEventWait(ev Event) { - s.evch <- ev -} - -func (s *cScreen) PostEvent(ev Event) error { - select { - case s.evch <- ev: - return nil - default: - return ErrEventQFull - } -} - -func (s *cScreen) PollEvent() Event { - select { - case <-s.quit: - return nil - case ev := <-s.evch: - return ev - } -} - -type cursorInfo struct { - size uint32 - visible uint32 -} - -type coord struct { - x int16 - y int16 -} - -func (c coord) uintptr() uintptr { - // little endian, put x first - return uintptr(c.x) | (uintptr(c.y) << 16) -} - -type rect struct { - left int16 - top int16 - right int16 - bottom int16 -} - -func (s *cScreen) emitVtString(vs string) { - esc := utf16.Encode([]rune(vs)) - syscall.WriteConsole(s.out, &esc[0], uint32(len(esc)), nil, nil) -} - -func (s *cScreen) showCursor() { - if s.vten { - s.emitVtString(vtShowCursor) - } else { - s.setCursorInfo(&cursorInfo{size: 100, visible: 1}) - } -} - -func (s *cScreen) hideCursor() { - if s.vten { - s.emitVtString(vtHideCursor) - } else { - s.setCursorInfo(&cursorInfo{size: 1, visible: 0}) - } -} - -func (s *cScreen) ShowCursor(x, y int) { - s.Lock() - if !s.fini { - s.curx = x - s.cury = y - } - s.doCursor() - s.Unlock() -} - -func (s *cScreen) doCursor() { - x, y := s.curx, s.cury - - if x < 0 || y < 0 || x >= s.w || y >= s.h { - s.hideCursor() - } else { - s.setCursorPos(x, y) - s.showCursor() - } -} - -func (s *cScreen) HideCursor() { - s.ShowCursor(-1, -1) -} - -type inputRecord struct { - typ uint16 - _ uint16 - data [16]byte -} - -const ( - keyEvent uint16 = 1 - mouseEvent uint16 = 2 - resizeEvent uint16 = 4 - menuEvent uint16 = 8 // don't use - focusEvent uint16 = 16 // don't use -) - -type mouseRecord struct { - x int16 - y int16 - btns uint32 - mod uint32 - flags uint32 -} - -const ( - mouseDoubleClick uint32 = 0x2 - mouseHWheeled uint32 = 0x8 - mouseVWheeled uint32 = 0x4 - mouseMoved uint32 = 0x1 -) - -type resizeRecord struct { - x int16 - y int16 -} - -type keyRecord struct { - isdown int32 - repeat uint16 - kcode uint16 - scode uint16 - ch uint16 - mod uint32 -} - -const ( - // Constants per Microsoft. We don't put the modifiers - // here. - vkCancel = 0x03 - vkBack = 0x08 // Backspace - vkTab = 0x09 - vkClear = 0x0c - vkReturn = 0x0d - vkPause = 0x13 - vkEscape = 0x1b - vkSpace = 0x20 - vkPrior = 0x21 // PgUp - vkNext = 0x22 // PgDn - vkEnd = 0x23 - vkHome = 0x24 - vkLeft = 0x25 - vkUp = 0x26 - vkRight = 0x27 - vkDown = 0x28 - vkPrint = 0x2a - vkPrtScr = 0x2c - vkInsert = 0x2d - vkDelete = 0x2e - vkHelp = 0x2f - vkF1 = 0x70 - vkF2 = 0x71 - vkF3 = 0x72 - vkF4 = 0x73 - vkF5 = 0x74 - vkF6 = 0x75 - vkF7 = 0x76 - vkF8 = 0x77 - vkF9 = 0x78 - vkF10 = 0x79 - vkF11 = 0x7a - vkF12 = 0x7b - vkF13 = 0x7c - vkF14 = 0x7d - vkF15 = 0x7e - vkF16 = 0x7f - vkF17 = 0x80 - vkF18 = 0x81 - vkF19 = 0x82 - vkF20 = 0x83 - vkF21 = 0x84 - vkF22 = 0x85 - vkF23 = 0x86 - vkF24 = 0x87 -) - -var vkKeys = map[uint16]Key{ - vkCancel: KeyCancel, - vkBack: KeyBackspace, - vkTab: KeyTab, - vkClear: KeyClear, - vkPause: KeyPause, - vkPrint: KeyPrint, - vkPrtScr: KeyPrint, - vkPrior: KeyPgUp, - vkNext: KeyPgDn, - vkReturn: KeyEnter, - vkEnd: KeyEnd, - vkHome: KeyHome, - vkLeft: KeyLeft, - vkUp: KeyUp, - vkRight: KeyRight, - vkDown: KeyDown, - vkInsert: KeyInsert, - vkDelete: KeyDelete, - vkHelp: KeyHelp, - vkF1: KeyF1, - vkF2: KeyF2, - vkF3: KeyF3, - vkF4: KeyF4, - vkF5: KeyF5, - vkF6: KeyF6, - vkF7: KeyF7, - vkF8: KeyF8, - vkF9: KeyF9, - vkF10: KeyF10, - vkF11: KeyF11, - vkF12: KeyF12, - vkF13: KeyF13, - vkF14: KeyF14, - vkF15: KeyF15, - vkF16: KeyF16, - vkF17: KeyF17, - vkF18: KeyF18, - vkF19: KeyF19, - vkF20: KeyF20, - vkF21: KeyF21, - vkF22: KeyF22, - vkF23: KeyF23, - vkF24: KeyF24, -} - -// NB: All Windows platforms are little endian. We assume this -// never, ever change. The following code is endian safe. and does -// not use unsafe pointers. -func getu32(v []byte) uint32 { - return uint32(v[0]) + (uint32(v[1]) << 8) + (uint32(v[2]) << 16) + (uint32(v[3]) << 24) -} -func geti32(v []byte) int32 { - return int32(getu32(v)) -} -func getu16(v []byte) uint16 { - return uint16(v[0]) + (uint16(v[1]) << 8) -} -func geti16(v []byte) int16 { - return int16(getu16(v)) -} - -// Convert windows dwControlKeyState to modifier mask -func mod2mask(cks uint32) ModMask { - mm := ModNone - // Left or right control - if (cks & (0x0008 | 0x0004)) != 0 { - mm |= ModCtrl - } - // Left or right alt - if (cks & (0x0002 | 0x0001)) != 0 { - mm |= ModAlt - } - // Any shift - if (cks & 0x0010) != 0 { - mm |= ModShift - } - return mm -} - -func mrec2btns(mbtns, flags uint32) ButtonMask { - btns := ButtonNone - if mbtns&0x1 != 0 { - btns |= Button1 - } - if mbtns&0x2 != 0 { - btns |= Button2 - } - if mbtns&0x4 != 0 { - btns |= Button3 - } - if mbtns&0x8 != 0 { - btns |= Button4 - } - if mbtns&0x10 != 0 { - btns |= Button5 - } - if mbtns&0x20 != 0 { - btns |= Button6 - } - if mbtns&0x40 != 0 { - btns |= Button7 - } - if mbtns&0x80 != 0 { - btns |= Button8 - } - - if flags&mouseVWheeled != 0 { - if mbtns&0x80000000 == 0 { - btns |= WheelUp - } else { - btns |= WheelDown - } - } - if flags&mouseHWheeled != 0 { - if mbtns&0x80000000 == 0 { - btns |= WheelRight - } else { - btns |= WheelLeft - } - } - return btns -} - -func (s *cScreen) getConsoleInput() error { - // cancelFlag comes first as WaitForMultipleObjects returns the lowest index - // in the event that both events are signalled. - waitObjects := []syscall.Handle{s.cancelflag, s.in} - // As arrays are contiguous in memory, a pointer to the first object is the - // same as a pointer to the array itself. - pWaitObjects := unsafe.Pointer(&waitObjects[0]) - - rv, _, er := procWaitForMultipleObjects.Call( - uintptr(len(waitObjects)), - uintptr(pWaitObjects), - uintptr(0), - w32Infinite) - // WaitForMultipleObjects returns WAIT_OBJECT_0 + the index. - switch rv { - case w32WaitObject0: // s.cancelFlag - return errors.New("cancelled") - case w32WaitObject0 + 1: // s.in - rec := &inputRecord{} - var nrec int32 - rv, _, er := procReadConsoleInput.Call( - uintptr(s.in), - uintptr(unsafe.Pointer(rec)), - uintptr(1), - uintptr(unsafe.Pointer(&nrec))) - if rv == 0 { - return er - } - if nrec != 1 { - return nil - } - switch rec.typ { - case keyEvent: - krec := &keyRecord{} - krec.isdown = geti32(rec.data[0:]) - krec.repeat = getu16(rec.data[4:]) - krec.kcode = getu16(rec.data[6:]) - krec.scode = getu16(rec.data[8:]) - krec.ch = getu16(rec.data[10:]) - krec.mod = getu32(rec.data[12:]) - - if krec.isdown == 0 || krec.repeat < 1 { - // its a key release event, ignore it - return nil - } - if krec.ch != 0 { - // synthesized key code - for krec.repeat > 0 { - // convert shift+tab to backtab - if mod2mask(krec.mod) == ModShift && krec.ch == vkTab { - s.PostEventWait(NewEventKey(KeyBacktab, 0, - ModNone)) - } else { - s.PostEventWait(NewEventKey(KeyRune, rune(krec.ch), - mod2mask(krec.mod))) - } - krec.repeat-- - } - return nil - } - key := KeyNUL // impossible on Windows - ok := false - if key, ok = vkKeys[krec.kcode]; !ok { - return nil - } - for krec.repeat > 0 { - s.PostEventWait(NewEventKey(key, rune(krec.ch), - mod2mask(krec.mod))) - krec.repeat-- - } - - case mouseEvent: - var mrec mouseRecord - mrec.x = geti16(rec.data[0:]) - mrec.y = geti16(rec.data[2:]) - mrec.btns = getu32(rec.data[4:]) - mrec.mod = getu32(rec.data[8:]) - mrec.flags = getu32(rec.data[12:]) - btns := mrec2btns(mrec.btns, mrec.flags) - // we ignore double click, events are delivered normally - s.PostEventWait(NewEventMouse(int(mrec.x), int(mrec.y), btns, - mod2mask(mrec.mod))) - - case resizeEvent: - var rrec resizeRecord - rrec.x = geti16(rec.data[0:]) - rrec.y = geti16(rec.data[2:]) - s.PostEventWait(NewEventResize(int(rrec.x), int(rrec.y))) - - default: - } - default: - return er - } - - return nil -} - -func (s *cScreen) scanInput() { - for { - if e := s.getConsoleInput(); e != nil { - close(s.scandone) - return - } - } -} - -// Windows console can display 8 characters, in either low or high intensity -func (s *cScreen) Colors() int { - if s.vten { - return 1 << 24 - } - return 16 -} - -var vgaColors = map[Color]uint16{ - ColorBlack: 0, - ColorMaroon: 0x4, - ColorGreen: 0x2, - ColorNavy: 0x1, - ColorOlive: 0x6, - ColorPurple: 0x5, - ColorTeal: 0x3, - ColorSilver: 0x7, - ColorGrey: 0x8, - ColorRed: 0xc, - ColorLime: 0xa, - ColorBlue: 0x9, - ColorYellow: 0xe, - ColorFuchsia: 0xd, - ColorAqua: 0xb, - ColorWhite: 0xf, -} - -// Windows uses RGB signals -func mapColor2RGB(c Color) uint16 { - winLock.Lock() - if v, ok := winColors[c]; ok { - c = v - } else { - v = FindColor(c, winPalette) - winColors[c] = v - c = v - } - winLock.Unlock() - - if vc, ok := vgaColors[c]; ok { - return vc - } - return 0 -} - -// Map a tcell style to Windows attributes -func (s *cScreen) mapStyle(style Style) uint16 { - f, b, a := style.Decompose() - fa := s.oscreen.attrs & 0xf - ba := (s.oscreen.attrs) >> 4 & 0xf - if f != ColorDefault && f != ColorReset { - fa = mapColor2RGB(f) - } - if b != ColorDefault && b != ColorReset { - ba = mapColor2RGB(b) - } - var attr uint16 - // We simulate reverse by doing the color swap ourselves. - // Apparently windows cannot really do this except in DBCS - // views. - if a&AttrReverse != 0 { - attr = ba - attr |= (fa << 4) - } else { - attr = fa - attr |= (ba << 4) - } - if a&AttrBold != 0 { - attr |= 0x8 - } - if a&AttrDim != 0 { - attr &^= 0x8 - } - if a&AttrUnderline != 0 { - // Best effort -- doesn't seem to work though. - attr |= 0x8000 - } - // Blink is unsupported - return attr -} - -func (s *cScreen) SetCell(x, y int, style Style, ch ...rune) { - if len(ch) > 0 { - s.SetContent(x, y, ch[0], ch[1:], style) - } else { - s.SetContent(x, y, ' ', nil, style) - } -} - -func (s *cScreen) SetContent(x, y int, mainc rune, combc []rune, style Style) { - s.Lock() - if !s.fini { - s.cells.SetContent(x, y, mainc, combc, style) - } - s.Unlock() -} - -func (s *cScreen) GetContent(x, y int) (rune, []rune, Style, int) { - s.Lock() - mainc, combc, style, width := s.cells.GetContent(x, y) - s.Unlock() - return mainc, combc, style, width -} - -func (s *cScreen) sendVtStyle(style Style) { - esc := &strings.Builder{} - - fg, bg, attrs := style.Decompose() - - esc.WriteString(vtSgr0) - - if attrs&(AttrBold|AttrDim) == AttrBold { - esc.WriteString(vtBold) - } - if attrs&AttrBlink != 0 { - esc.WriteString(vtBlink) - } - if attrs&AttrUnderline != 0 { - esc.WriteString(vtUnderline) - } - if attrs&AttrReverse != 0 { - esc.WriteString(vtReverse) - } - if fg.IsRGB() { - r, g, b := fg.RGB() - fmt.Fprintf(esc, vtSetFgRGB, r, g, b) - } else if fg.Valid() { - fmt.Fprintf(esc, vtSetFg, fg&0xff) - } - if bg.IsRGB() { - r, g, b := bg.RGB() - fmt.Fprintf(esc, vtSetBgRGB, r, g, b) - } else if bg.Valid() { - fmt.Fprintf(esc, vtSetBg, bg&0xff) - } - s.emitVtString(esc.String()) -} - -func (s *cScreen) writeString(x, y int, style Style, ch []uint16) { - // we assume the caller has hidden the cursor - if len(ch) == 0 { - return - } - s.setCursorPos(x, y) - - if s.vten { - s.sendVtStyle(style) - } else { - procSetConsoleTextAttribute.Call( - uintptr(s.out), - uintptr(s.mapStyle(style))) - } - syscall.WriteConsole(s.out, &ch[0], uint32(len(ch)), nil, nil) -} - -func (s *cScreen) draw() { - // allocate a scratch line bit enough for no combining chars. - // if you have combining characters, you may pay for extra allocs. - if s.clear { - s.clearScreen(s.style) - s.clear = false - s.cells.Invalidate() - } - buf := make([]uint16, 0, s.w) - wcs := buf[:] - lstyle := styleInvalid - - lx, ly := -1, -1 - ra := make([]rune, 1) - - for y := 0; y < s.h; y++ { - for x := 0; x < s.w; x++ { - mainc, combc, style, width := s.cells.GetContent(x, y) - dirty := s.cells.Dirty(x, y) - if style == StyleDefault { - style = s.style - } - - if !dirty || style != lstyle { - // write out any data queued thus far - // because we are going to skip over some - // cells, or because we need to change styles - s.writeString(lx, ly, lstyle, wcs) - wcs = buf[0:0] - lstyle = StyleDefault - if !dirty { - continue - } - } - if x > s.w-width { - mainc = ' ' - combc = nil - width = 1 - } - if len(wcs) == 0 { - lstyle = style - lx = x - ly = y - } - ra[0] = mainc - wcs = append(wcs, utf16.Encode(ra)...) - if len(combc) != 0 { - wcs = append(wcs, utf16.Encode(combc)...) - } - for dx := 0; dx < width; dx++ { - s.cells.SetDirty(x+dx, y, false) - } - x += width - 1 - } - s.writeString(lx, ly, lstyle, wcs) - wcs = buf[0:0] - lstyle = styleInvalid - } -} - -func (s *cScreen) Show() { - s.Lock() - if !s.fini { - s.hideCursor() - s.resize() - s.draw() - s.doCursor() - } - s.Unlock() -} - -func (s *cScreen) Sync() { - s.Lock() - if !s.fini { - s.cells.Invalidate() - s.hideCursor() - s.resize() - s.draw() - s.doCursor() - } - s.Unlock() -} - -type consoleInfo struct { - size coord - pos coord - attrs uint16 - win rect - maxsz coord -} - -func (s *cScreen) getConsoleInfo(info *consoleInfo) { - procGetConsoleScreenBufferInfo.Call( - uintptr(s.out), - uintptr(unsafe.Pointer(info))) -} - -func (s *cScreen) getCursorInfo(info *cursorInfo) { - procGetConsoleCursorInfo.Call( - uintptr(s.out), - uintptr(unsafe.Pointer(info))) -} - -func (s *cScreen) setCursorInfo(info *cursorInfo) { - procSetConsoleCursorInfo.Call( - uintptr(s.out), - uintptr(unsafe.Pointer(info))) - -} - -func (s *cScreen) setCursorPos(x, y int) { - if s.vten { - // Note that the string is Y first. Origin is 1,1. - s.emitVtString(fmt.Sprintf(vtCursorPos, y+1, x+1)) - } else { - procSetConsoleCursorPosition.Call( - uintptr(s.out), - coord{int16(x), int16(y)}.uintptr()) - } -} - -func (s *cScreen) setBufferSize(x, y int) { - procSetConsoleScreenBufferSize.Call( - uintptr(s.out), - coord{int16(x), int16(y)}.uintptr()) -} - -func (s *cScreen) Size() (int, int) { - s.Lock() - w, h := s.w, s.h - s.Unlock() - - return w, h -} - -func (s *cScreen) resize() { - info := consoleInfo{} - s.getConsoleInfo(&info) - - w := int((info.win.right - info.win.left) + 1) - h := int((info.win.bottom - info.win.top) + 1) - - if s.w == w && s.h == h { - return - } - - s.cells.Resize(w, h) - s.w = w - s.h = h - - s.setBufferSize(w, h) - - r := rect{0, 0, int16(w - 1), int16(h - 1)} - procSetConsoleWindowInfo.Call( - uintptr(s.out), - uintptr(1), - uintptr(unsafe.Pointer(&r))) - s.PostEvent(NewEventResize(w, h)) -} - -func (s *cScreen) Clear() { - s.Fill(' ', s.style) -} - -func (s *cScreen) Fill(r rune, style Style) { - s.Lock() - if !s.fini { - s.cells.Fill(r, style) - s.clear = true - } - s.Unlock() -} - -func (s *cScreen) clearScreen(style Style) { - if s.vten { - s.sendVtStyle(style) - row := strings.Repeat(" ", s.w) - for y := 0; y < s.h; y++ { - s.setCursorPos(0, y) - s.emitVtString(row) - } - s.setCursorPos(0, 0) - - } else { - pos := coord{0, 0} - attr := s.mapStyle(style) - x, y := s.w, s.h - scratch := uint32(0) - count := uint32(x * y) - - procFillConsoleOutputAttribute.Call( - uintptr(s.out), - uintptr(attr), - uintptr(count), - pos.uintptr(), - uintptr(unsafe.Pointer(&scratch))) - procFillConsoleOutputCharacter.Call( - uintptr(s.out), - uintptr(' '), - uintptr(count), - pos.uintptr(), - uintptr(unsafe.Pointer(&scratch))) - } -} - -const ( - // Input modes - modeExtndFlg uint32 = 0x0080 - modeMouseEn = 0x0010 - modeResizeEn = 0x0008 - modeCooked = 0x0001 - modeVtInput = 0x0200 - - // Output modes - modeCookedOut uint32 = 0x0001 - modeWrapEOL = 0x0002 - modeVtOutput = 0x0004 - modeNoAutoNL = 0x0008 -) - -func (s *cScreen) setInMode(mode uint32) error { - rv, _, err := procSetConsoleMode.Call( - uintptr(s.in), - uintptr(mode)) - if rv == 0 { - return err - } - return nil -} - -func (s *cScreen) setOutMode(mode uint32) error { - rv, _, err := procSetConsoleMode.Call( - uintptr(s.out), - uintptr(mode)) - if rv == 0 { - return err - } - return nil -} - -func (s *cScreen) getInMode(v *uint32) { - procGetConsoleMode.Call( - uintptr(s.in), - uintptr(unsafe.Pointer(v))) -} - -func (s *cScreen) getOutMode(v *uint32) { - procGetConsoleMode.Call( - uintptr(s.out), - uintptr(unsafe.Pointer(v))) -} - -func (s *cScreen) SetStyle(style Style) { - s.Lock() - s.style = style - s.Unlock() -} - -// No fallback rune support, since we have Unicode. Yay! - -func (s *cScreen) RegisterRuneFallback(r rune, subst string) { -} - -func (s *cScreen) UnregisterRuneFallback(r rune) { -} - -func (s *cScreen) CanDisplay(r rune, checkFallbacks bool) bool { - // We presume we can display anything -- we're Unicode. - // (Sadly this not precisely true. Combinings are especially - // poorly supported under Windows.) - return true -} - -func (s *cScreen) HasMouse() bool { - return true -} - -func (s *cScreen) Resize(int, int, int, int) {} - -func (s *cScreen) HasKey(k Key) bool { - // Microsoft has codes for some keys, but they are unusual, - // so we don't include them. We include all the typical - // 101, 105 key layout keys. - valid := map[Key]bool{ - KeyBackspace: true, - KeyTab: true, - KeyEscape: true, - KeyPause: true, - KeyPrint: true, - KeyPgUp: true, - KeyPgDn: true, - KeyEnter: true, - KeyEnd: true, - KeyHome: true, - KeyLeft: true, - KeyUp: true, - KeyRight: true, - KeyDown: true, - KeyInsert: true, - KeyDelete: true, - KeyF1: true, - KeyF2: true, - KeyF3: true, - KeyF4: true, - KeyF5: true, - KeyF6: true, - KeyF7: true, - KeyF8: true, - KeyF9: true, - KeyF10: true, - KeyF11: true, - KeyF12: true, - KeyRune: true, - } - - return valid[k] -} - -func (s *cScreen) Beep() error { - // A simple beep. If the sound card is not available, the sound is generated - // using the speaker. - // - // Reference: - // https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-messagebeep - const simpleBeep = 0xffffffff - if rv, _, err := procMessageBeep.Call(simpleBeep); rv == 0 { - return err - } - return nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/doc.go b/vendor/github.com/gdamore/tcell/v2/doc.go deleted file mode 100644 index b671961..0000000 --- a/vendor/github.com/gdamore/tcell/v2/doc.go +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright 2018 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Package tcell provides a lower-level, portable API for building -// programs that interact with terminals or consoles. It works with -// both common (and many uncommon!) terminals or terminal emulators, -// and Windows console implementations. -// -// It provides support for up to 256 colors, text attributes, and box drawing -// elements. A database of terminals built from a real terminfo database -// is provided, along with code to generate new database entries. -// -// Tcell offers very rich support for mice, dependent upon the terminal -// of course. (Windows, XTerm, and iTerm 2 are known to work very well.) -// -// If the environment is not Unicode by default, such as an ISO8859 based -// locale or GB18030, Tcell can convert input and output, so that your -// terminal can operate in whatever locale is most convenient, while the -// application program can just assume "everything is UTF-8". Reasonable -// defaults are used for updating characters to something suitable for -// display. Unicode box drawing characters will be converted to use the -// alternate character set of your terminal, if native conversions are -// not available. If no ACS is available, then some ASCII fallbacks will -// be used. -// -// Note that support for non-UTF-8 locales (other than C) must be enabled -// by the application using RegisterEncoding() -- we don't have them all -// enabled by default to avoid bloating the application unneccessarily. -// (These days UTF-8 is good enough for almost everyone, and nobody should -// be using legacy locales anymore.) Also, actual glyphs for various code -// point will only be displayed if your terminal or emulator (or the font -// the emulator is using) supports them. -// -// A rich set of keycodes is supported, with support for up to 65 function -// keys, and various other special keys. -// -package tcell diff --git a/vendor/github.com/gdamore/tcell/v2/encoding.go b/vendor/github.com/gdamore/tcell/v2/encoding.go deleted file mode 100644 index 596a6e8..0000000 --- a/vendor/github.com/gdamore/tcell/v2/encoding.go +++ /dev/null @@ -1,139 +0,0 @@ -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "strings" - "sync" - - "golang.org/x/text/encoding" - - gencoding "github.com/gdamore/encoding" -) - -var encodings map[string]encoding.Encoding -var encodingLk sync.Mutex -var encodingFallback EncodingFallback = EncodingFallbackFail - -// RegisterEncoding may be called by the application to register an encoding. -// The presence of additional encodings will facilitate application usage with -// terminal environments where the I/O subsystem does not support Unicode. -// -// Windows systems use Unicode natively, and do not need any of the encoding -// subsystem when using Windows Console screens. -// -// Please see the Go documentation for golang.org/x/text/encoding -- most of -// the common ones exist already as stock variables. For example, ISO8859-15 -// can be registered using the following code: -// -// import "golang.org/x/text/encoding/charmap" -// -// ... -// RegisterEncoding("ISO8859-15", charmap.ISO8859_15) -// -// Aliases can be registered as well, for example "8859-15" could be an alias -// for "ISO8859-15". -// -// For POSIX systems, the tcell package will check the environment variables -// LC_ALL, LC_CTYPE, and LANG (in that order) to determine the character set. -// These are expected to have the following pattern: -// -// $language[.$codeset[@$variant] -// -// We extract only the $codeset part, which will usually be something like -// UTF-8 or ISO8859-15 or KOI8-R. Note that if the locale is either "POSIX" -// or "C", then we assume US-ASCII (the POSIX 'portable character set' -// and assume all other characters are somehow invalid.) -// -// Modern POSIX systems and terminal emulators may use UTF-8, and for those -// systems, this API is also unnecessary. For example, Darwin (MacOS X) and -// modern Linux running modern xterm generally will out of the box without -// any of this. Use of UTF-8 is recommended when possible, as it saves -// quite a lot processing overhead. -// -// Note that some encodings are quite large (for example GB18030 which is a -// superset of Unicode) and so the application size can be expected ot -// increase quite a bit as each encoding is added. The East Asian encodings -// have been seen to add 100-200K per encoding to the application size. -// -func RegisterEncoding(charset string, enc encoding.Encoding) { - encodingLk.Lock() - charset = strings.ToLower(charset) - encodings[charset] = enc - encodingLk.Unlock() -} - -// EncodingFallback describes how the system behavees when the locale -// requires a character set that we do not support. The system always -// supports UTF-8 and US-ASCII. On Windows consoles, UTF-16LE is also -// supported automatically. Other character sets must be added using the -// RegisterEncoding API. (A large group of nearly all of them can be -// added using the RegisterAll function in the encoding sub package.) -type EncodingFallback int - -const ( - // EncodingFallbackFail behavior causes GetEncoding to fail - // when it cannot find an encoding. - EncodingFallbackFail = iota - - // EncodingFallbackASCII behaviore causes GetEncoding to fall back - // to a 7-bit ASCII encoding, if no other encoding can be found. - EncodingFallbackASCII - - // EncodingFallbackUTF8 behavior causes GetEncoding to assume - // UTF8 can pass unmodified upon failure. Note that this behavior - // is not recommended, unless you are sure your terminal can cope - // with real UTF8 sequences. - EncodingFallbackUTF8 -) - -// SetEncodingFallback changes the behavior of GetEncoding when a suitable -// encoding is not found. The default is EncodingFallbackFail, which -// causes GetEncoding to simply return nil. -func SetEncodingFallback(fb EncodingFallback) { - encodingLk.Lock() - encodingFallback = fb - encodingLk.Unlock() -} - -// GetEncoding is used by Screen implementors who want to locate an encoding -// for the given character set name. Note that this will return nil for -// either the Unicode (UTF-8) or ASCII encodings, since we don't use -// encodings for them but instead have our own native methods. -func GetEncoding(charset string) encoding.Encoding { - charset = strings.ToLower(charset) - encodingLk.Lock() - defer encodingLk.Unlock() - if enc, ok := encodings[charset]; ok { - return enc - } - switch encodingFallback { - case EncodingFallbackASCII: - return gencoding.ASCII - case EncodingFallbackUTF8: - return encoding.Nop - } - return nil -} - -func init() { - // We always support UTF-8 and ASCII. - encodings = make(map[string]encoding.Encoding) - encodings["utf-8"] = gencoding.UTF8 - encodings["utf8"] = gencoding.UTF8 - encodings["us-ascii"] = gencoding.ASCII - encodings["ascii"] = gencoding.ASCII - encodings["iso646"] = gencoding.ASCII -} diff --git a/vendor/github.com/gdamore/tcell/v2/encoding/all.go b/vendor/github.com/gdamore/tcell/v2/encoding/all.go deleted file mode 100644 index ca3ddeb..0000000 --- a/vendor/github.com/gdamore/tcell/v2/encoding/all.go +++ /dev/null @@ -1,115 +0,0 @@ -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package encoding - -import ( - "github.com/gdamore/encoding" - "github.com/gdamore/tcell/v2" - - "golang.org/x/text/encoding/charmap" - "golang.org/x/text/encoding/japanese" - "golang.org/x/text/encoding/korean" - "golang.org/x/text/encoding/simplifiedchinese" - "golang.org/x/text/encoding/traditionalchinese" -) - -// Register registers all known encodings. This is a short-cut to -// add full character set support to your program. Note that this can -// add several megabytes to your program's size, because some of the encodings -// are rather large (particularly those from East Asia.) -func Register() { - // We supply latin1 and latin5, because Go doesn't - tcell.RegisterEncoding("ISO8859-1", encoding.ISO8859_1) - tcell.RegisterEncoding("ISO8859-9", encoding.ISO8859_9) - - tcell.RegisterEncoding("ISO8859-10", charmap.ISO8859_10) - tcell.RegisterEncoding("ISO8859-13", charmap.ISO8859_13) - tcell.RegisterEncoding("ISO8859-14", charmap.ISO8859_14) - tcell.RegisterEncoding("ISO8859-15", charmap.ISO8859_15) - tcell.RegisterEncoding("ISO8859-16", charmap.ISO8859_16) - tcell.RegisterEncoding("ISO8859-2", charmap.ISO8859_2) - tcell.RegisterEncoding("ISO8859-3", charmap.ISO8859_3) - tcell.RegisterEncoding("ISO8859-4", charmap.ISO8859_4) - tcell.RegisterEncoding("ISO8859-5", charmap.ISO8859_5) - tcell.RegisterEncoding("ISO8859-6", charmap.ISO8859_6) - tcell.RegisterEncoding("ISO8859-7", charmap.ISO8859_7) - tcell.RegisterEncoding("ISO8859-8", charmap.ISO8859_8) - tcell.RegisterEncoding("KOI8-R", charmap.KOI8R) - tcell.RegisterEncoding("KOI8-U", charmap.KOI8U) - - // Asian stuff - tcell.RegisterEncoding("EUC-JP", japanese.EUCJP) - tcell.RegisterEncoding("SHIFT_JIS", japanese.ShiftJIS) - tcell.RegisterEncoding("ISO2022JP", japanese.ISO2022JP) - - tcell.RegisterEncoding("EUC-KR", korean.EUCKR) - - tcell.RegisterEncoding("GB18030", simplifiedchinese.GB18030) - tcell.RegisterEncoding("GB2312", simplifiedchinese.HZGB2312) - tcell.RegisterEncoding("GBK", simplifiedchinese.GBK) - - tcell.RegisterEncoding("Big5", traditionalchinese.Big5) - - // Common aliaess - aliases := map[string]string{ - "8859-1": "ISO8859-1", - "ISO-8859-1": "ISO8859-1", - "8859-13": "ISO8859-13", - "ISO-8859-13": "ISO8859-13", - "8859-14": "ISO8859-14", - "ISO-8859-14": "ISO8859-14", - "8859-15": "ISO8859-15", - "ISO-8859-15": "ISO8859-15", - "8859-16": "ISO8859-16", - "ISO-8859-16": "ISO8859-16", - "8859-2": "ISO8859-2", - "ISO-8859-2": "ISO8859-2", - "8859-3": "ISO8859-3", - "ISO-8859-3": "ISO8859-3", - "8859-4": "ISO8859-4", - "ISO-8859-4": "ISO8859-4", - "8859-5": "ISO8859-5", - "ISO-8859-5": "ISO8859-5", - "8859-6": "ISO8859-6", - "ISO-8859-6": "ISO8859-6", - "8859-7": "ISO8859-7", - "ISO-8859-7": "ISO8859-7", - "8859-8": "ISO8859-8", - "ISO-8859-8": "ISO8859-8", - "8859-9": "ISO8859-9", - "ISO-8859-9": "ISO8859-9", - - "SJIS": "Shift_JIS", - "EUCJP": "EUC-JP", - "2022-JP": "ISO2022JP", - "ISO-2022-JP": "ISO2022JP", - - "EUCKR": "EUC-KR", - - // ISO646 isn't quite exactly ASCII, but the 1991 IRV - // (international reference version) is so. This helps - // some older systems that may use "646" for POSIX locales. - "646": "US-ASCII", - "ISO646": "US-ASCII", - - // Other names for UTF-8 - "UTF8": "UTF-8", - } - for n, v := range aliases { - if enc := tcell.GetEncoding(v); enc != nil { - tcell.RegisterEncoding(n, enc) - } - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/errors.go b/vendor/github.com/gdamore/tcell/v2/errors.go deleted file mode 100644 index 201dff9..0000000 --- a/vendor/github.com/gdamore/tcell/v2/errors.go +++ /dev/null @@ -1,73 +0,0 @@ -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "errors" - "time" - - "github.com/gdamore/tcell/v2/terminfo" -) - -var ( - // ErrTermNotFound indicates that a suitable terminal entry could - // not be found. This can result from either not having TERM set, - // or from the TERM failing to support certain minimal functionality, - // in particular absolute cursor addressability (the cup capability) - // is required. For example, legacy "adm3" lacks this capability, - // whereas the slightly newer "adm3a" supports it. This failure - // occurs most often with "dumb". - ErrTermNotFound = terminfo.ErrTermNotFound - - // ErrNoScreen indicates that no suitable screen could be found. - // This may result from attempting to run on a platform where there - // is no support for either termios or console I/O (such as nacl), - // or from running in an environment where there is no access to - // a suitable console/terminal device. (For example, running on - // without a controlling TTY or with no /dev/tty on POSIX platforms.) - ErrNoScreen = errors.New("no suitable screen available") - - // ErrNoCharset indicates that the locale environment the - // program is not supported by the program, because no suitable - // encoding was found for it. This problem never occurs if - // the environment is UTF-8 or UTF-16. - ErrNoCharset = errors.New("character set not supported") - - // ErrEventQFull indicates that the event queue is full, and - // cannot accept more events. - ErrEventQFull = errors.New("event queue full") -) - -// An EventError is an event representing some sort of error, and carries -// an error payload. -type EventError struct { - t time.Time - err error -} - -// When returns the time when the event was created. -func (ev *EventError) When() time.Time { - return ev.t -} - -// Error implements the error. -func (ev *EventError) Error() string { - return ev.err.Error() -} - -// NewEventError creates an ErrorEvent with the given error payload. -func NewEventError(err error) *EventError { - return &EventError{t: time.Now(), err: err} -} diff --git a/vendor/github.com/gdamore/tcell/v2/event.go b/vendor/github.com/gdamore/tcell/v2/event.go deleted file mode 100644 index a3b7700..0000000 --- a/vendor/github.com/gdamore/tcell/v2/event.go +++ /dev/null @@ -1,53 +0,0 @@ -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "time" -) - -// Event is a generic interface used for passing around Events. -// Concrete types follow. -type Event interface { - // When reports the time when the event was generated. - When() time.Time -} - -// EventTime is a simple base event class, suitable for easy reuse. -// It can be used to deliver actual timer events as well. -type EventTime struct { - when time.Time -} - -// When returns the time stamp when the event occurred. -func (e *EventTime) When() time.Time { - return e.when -} - -// SetEventTime sets the time of occurrence for the event. -func (e *EventTime) SetEventTime(t time.Time) { - e.when = t -} - -// SetEventNow sets the time of occurrence for the event to the current time. -func (e *EventTime) SetEventNow() { - e.SetEventTime(time.Now()) -} - -// EventHandler is anything that handles events. If the handler has -// consumed the event, it should return true. False otherwise. -type EventHandler interface { - HandleEvent(Event) bool -} diff --git a/vendor/github.com/gdamore/tcell/v2/event_test.go b/vendor/github.com/gdamore/tcell/v2/event_test.go deleted file mode 100644 index f8ede20..0000000 --- a/vendor/github.com/gdamore/tcell/v2/event_test.go +++ /dev/null @@ -1,70 +0,0 @@ -// Copyright 2018 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "testing" - "time" -) - -func eventLoop(s SimulationScreen, evch chan Event) { - for { - ev := s.PollEvent() - if ev == nil { - close(evch) - return - } - select { - case evch <- ev: - case <-time.After(time.Second): - } - } -} - -func TestMouseEvents(t *testing.T) { - - s := mkTestScreen(t, "") - defer s.Fini() - - s.EnableMouse() - s.InjectMouse(4, 9, Button1, ModCtrl) - evch := make(chan Event) - em := &EventMouse{} - done := false - go eventLoop(s, evch) - - for !done { - select { - case ev := <-evch: - if evm, ok := ev.(*EventMouse); ok { - em = evm - done = true - } - continue - case <-time.After(time.Second): - done = true - } - } - - if x, y := em.Position(); x != 4 || y != 9 { - t.Errorf("Mouse position wrong (%v, %v)", x, y) - } - if em.Buttons() != Button1 { - t.Errorf("Should be Button1") - } - if em.Modifiers() != ModCtrl { - t.Errorf("Modifiers should be control") - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/go.mod b/vendor/github.com/gdamore/tcell/v2/go.mod deleted file mode 100644 index f1829ae..0000000 --- a/vendor/github.com/gdamore/tcell/v2/go.mod +++ /dev/null @@ -1,11 +0,0 @@ -module github.com/gdamore/tcell/v2 - -go 1.12 - -require ( - github.com/gdamore/encoding v1.0.0 - github.com/lucasb-eyer/go-colorful v1.0.3 - github.com/mattn/go-runewidth v0.0.7 - golang.org/x/sys v0.0.0-20190626150813-e07cf5db2756 - golang.org/x/text v0.3.0 -) diff --git a/vendor/github.com/gdamore/tcell/v2/go.sum b/vendor/github.com/gdamore/tcell/v2/go.sum deleted file mode 100644 index 9f8691f..0000000 --- a/vendor/github.com/gdamore/tcell/v2/go.sum +++ /dev/null @@ -1,10 +0,0 @@ -github.com/gdamore/encoding v1.0.0 h1:+7OoQ1Bc6eTm5niUzBa0Ctsh6JbMW6Ra+YNuAtDBdko= -github.com/gdamore/encoding v1.0.0/go.mod h1:alR0ol34c49FCSBLjhosxzcPHQbf2trDkoo5dl+VrEg= -github.com/lucasb-eyer/go-colorful v1.0.3 h1:QIbQXiugsb+q10B+MI+7DI1oQLdmnep86tWFlaaUAac= -github.com/lucasb-eyer/go-colorful v1.0.3/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= -github.com/mattn/go-runewidth v0.0.7 h1:Ei8KR0497xHyKJPAv59M1dkC+rOZCMBJ+t3fZ+twI54= -github.com/mattn/go-runewidth v0.0.7/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -golang.org/x/sys v0.0.0-20190626150813-e07cf5db2756 h1:9nuHUbU8dRnRRfj9KjWUVrJeoexdbeMjttk6Oh1rD10= -golang.org/x/sys v0.0.0-20190626150813-e07cf5db2756/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= diff --git a/vendor/github.com/gdamore/tcell/v2/interrupt.go b/vendor/github.com/gdamore/tcell/v2/interrupt.go deleted file mode 100644 index 70dddfc..0000000 --- a/vendor/github.com/gdamore/tcell/v2/interrupt.go +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "time" -) - -// EventInterrupt is a generic wakeup event. Its can be used to -// to request a redraw. It can carry an arbitrary payload, as well. -type EventInterrupt struct { - t time.Time - v interface{} -} - -// When returns the time when this event was created. -func (ev *EventInterrupt) When() time.Time { - return ev.t -} - -// Data is used to obtain the opaque event payload. -func (ev *EventInterrupt) Data() interface{} { - return ev.v -} - -// NewEventInterrupt creates an EventInterrupt with the given payload. -func NewEventInterrupt(data interface{}) *EventInterrupt { - return &EventInterrupt{t: time.Now(), v: data} -} diff --git a/vendor/github.com/gdamore/tcell/v2/key.go b/vendor/github.com/gdamore/tcell/v2/key.go deleted file mode 100644 index 9741e69..0000000 --- a/vendor/github.com/gdamore/tcell/v2/key.go +++ /dev/null @@ -1,470 +0,0 @@ -// Copyright 2016 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "fmt" - "strings" - "time" -) - -// EventKey represents a key press. Usually this is a key press followed -// by a key release, but since terminal programs don't have a way to report -// key release events, we usually get just one event. If a key is held down -// then the terminal may synthesize repeated key presses at some predefined -// rate. We have no control over that, nor visibility into it. -// -// In some cases, we can have a modifier key, such as ModAlt, that can be -// generated with a key press. (This usually is represented by having the -// high bit set, or in some cases, by sending an ESC prior to the rune.) -// -// If the value of Key() is KeyRune, then the actual key value will be -// available with the Rune() method. This will be the case for most keys. -// In most situations, the modifiers will not be set. For example, if the -// rune is 'A', this will be reported without the ModShift bit set, since -// really can't tell if the Shift key was pressed (it might have been CAPSLOCK, -// or a terminal that only can send capitals, or keyboard with separate -// capital letters from lower case letters). -// -// Generally, terminal applications have far less visibility into keyboard -// activity than graphical applications. Hence, they should avoid depending -// overly much on availability of modifiers, or the availability of any -// specific keys. -type EventKey struct { - t time.Time - mod ModMask - key Key - ch rune -} - -// When returns the time when this Event was created, which should closely -// match the time when the key was pressed. -func (ev *EventKey) When() time.Time { - return ev.t -} - -// Rune returns the rune corresponding to the key press, if it makes sense. -// The result is only defined if the value of Key() is KeyRune. -func (ev *EventKey) Rune() rune { - return ev.ch -} - -// Key returns a virtual key code. We use this to identify specific key -// codes, such as KeyEnter, etc. Most control and function keys are reported -// with unique Key values. Normal alphanumeric and punctuation keys will -// generally return KeyRune here; the specific key can be further decoded -// using the Rune() function. -func (ev *EventKey) Key() Key { - return ev.key -} - -// Modifiers returns the modifiers that were present with the key press. Note -// that not all platforms and terminals support this equally well, and some -// cases we will not not know for sure. Hence, applications should avoid -// using this in most circumstances. -func (ev *EventKey) Modifiers() ModMask { - return ev.mod -} - -// KeyNames holds the written names of special keys. Useful to echo back a key -// name, or to look up a key from a string value. -var KeyNames = map[Key]string{ - KeyEnter: "Enter", - KeyBackspace: "Backspace", - KeyTab: "Tab", - KeyBacktab: "Backtab", - KeyEsc: "Esc", - KeyBackspace2: "Backspace2", - KeyDelete: "Delete", - KeyInsert: "Insert", - KeyUp: "Up", - KeyDown: "Down", - KeyLeft: "Left", - KeyRight: "Right", - KeyHome: "Home", - KeyEnd: "End", - KeyUpLeft: "UpLeft", - KeyUpRight: "UpRight", - KeyDownLeft: "DownLeft", - KeyDownRight: "DownRight", - KeyCenter: "Center", - KeyPgDn: "PgDn", - KeyPgUp: "PgUp", - KeyClear: "Clear", - KeyExit: "Exit", - KeyCancel: "Cancel", - KeyPause: "Pause", - KeyPrint: "Print", - KeyF1: "F1", - KeyF2: "F2", - KeyF3: "F3", - KeyF4: "F4", - KeyF5: "F5", - KeyF6: "F6", - KeyF7: "F7", - KeyF8: "F8", - KeyF9: "F9", - KeyF10: "F10", - KeyF11: "F11", - KeyF12: "F12", - KeyF13: "F13", - KeyF14: "F14", - KeyF15: "F15", - KeyF16: "F16", - KeyF17: "F17", - KeyF18: "F18", - KeyF19: "F19", - KeyF20: "F20", - KeyF21: "F21", - KeyF22: "F22", - KeyF23: "F23", - KeyF24: "F24", - KeyF25: "F25", - KeyF26: "F26", - KeyF27: "F27", - KeyF28: "F28", - KeyF29: "F29", - KeyF30: "F30", - KeyF31: "F31", - KeyF32: "F32", - KeyF33: "F33", - KeyF34: "F34", - KeyF35: "F35", - KeyF36: "F36", - KeyF37: "F37", - KeyF38: "F38", - KeyF39: "F39", - KeyF40: "F40", - KeyF41: "F41", - KeyF42: "F42", - KeyF43: "F43", - KeyF44: "F44", - KeyF45: "F45", - KeyF46: "F46", - KeyF47: "F47", - KeyF48: "F48", - KeyF49: "F49", - KeyF50: "F50", - KeyF51: "F51", - KeyF52: "F52", - KeyF53: "F53", - KeyF54: "F54", - KeyF55: "F55", - KeyF56: "F56", - KeyF57: "F57", - KeyF58: "F58", - KeyF59: "F59", - KeyF60: "F60", - KeyF61: "F61", - KeyF62: "F62", - KeyF63: "F63", - KeyF64: "F64", - KeyCtrlA: "Ctrl-A", - KeyCtrlB: "Ctrl-B", - KeyCtrlC: "Ctrl-C", - KeyCtrlD: "Ctrl-D", - KeyCtrlE: "Ctrl-E", - KeyCtrlF: "Ctrl-F", - KeyCtrlG: "Ctrl-G", - KeyCtrlJ: "Ctrl-J", - KeyCtrlK: "Ctrl-K", - KeyCtrlL: "Ctrl-L", - KeyCtrlN: "Ctrl-N", - KeyCtrlO: "Ctrl-O", - KeyCtrlP: "Ctrl-P", - KeyCtrlQ: "Ctrl-Q", - KeyCtrlR: "Ctrl-R", - KeyCtrlS: "Ctrl-S", - KeyCtrlT: "Ctrl-T", - KeyCtrlU: "Ctrl-U", - KeyCtrlV: "Ctrl-V", - KeyCtrlW: "Ctrl-W", - KeyCtrlX: "Ctrl-X", - KeyCtrlY: "Ctrl-Y", - KeyCtrlZ: "Ctrl-Z", - KeyCtrlSpace: "Ctrl-Space", - KeyCtrlUnderscore: "Ctrl-_", - KeyCtrlRightSq: "Ctrl-]", - KeyCtrlBackslash: "Ctrl-\\", - KeyCtrlCarat: "Ctrl-^", -} - -// Name returns a printable value or the key stroke. This can be used -// when printing the event, for example. -func (ev *EventKey) Name() string { - s := "" - m := []string{} - if ev.mod&ModShift != 0 { - m = append(m, "Shift") - } - if ev.mod&ModAlt != 0 { - m = append(m, "Alt") - } - if ev.mod&ModMeta != 0 { - m = append(m, "Meta") - } - if ev.mod&ModCtrl != 0 { - m = append(m, "Ctrl") - } - - ok := false - if s, ok = KeyNames[ev.key]; !ok { - if ev.key == KeyRune { - s = "Rune[" + string(ev.ch) + "]" - } else { - s = fmt.Sprintf("Key[%d,%d]", ev.key, int(ev.ch)) - } - } - if len(m) != 0 { - if ev.mod&ModCtrl != 0 && strings.HasPrefix(s, "Ctrl-") { - s = s[5:] - } - return fmt.Sprintf("%s+%s", strings.Join(m, "+"), s) - } - return s -} - -// NewEventKey attempts to create a suitable event. It parses the various -// ASCII control sequences if KeyRune is passed for Key, but if the caller -// has more precise information it should set that specifically. Callers -// that aren't sure about modifier state (most) should just pass ModNone. -func NewEventKey(k Key, ch rune, mod ModMask) *EventKey { - if k == KeyRune && (ch < ' ' || ch == 0x7f) { - // Turn specials into proper key codes. This is for - // control characters and the DEL. - k = Key(ch) - if mod == ModNone && ch < ' ' { - switch Key(ch) { - case KeyBackspace, KeyTab, KeyEsc, KeyEnter: - // these keys are directly typeable without CTRL - default: - // most likely entered with a CTRL keypress - mod = ModCtrl - } - } - } - return &EventKey{t: time.Now(), key: k, ch: ch, mod: mod} -} - -// ModMask is a mask of modifier keys. Note that it will not always be -// possible to report modifier keys. -type ModMask int16 - -// These are the modifiers keys that can be sent either with a key press, -// or a mouse event. Note that as of now, due to the confusion associated -// with Meta, and the lack of support for it on many/most platforms, the -// current implementations never use it. Instead, they use ModAlt, even for -// events that could possibly have been distinguished from ModAlt. -const ( - ModShift ModMask = 1 << iota - ModCtrl - ModAlt - ModMeta - ModNone ModMask = 0 -) - -// Key is a generic value for representing keys, and especially special -// keys (function keys, cursor movement keys, etc.) For normal keys, like -// ASCII letters, we use KeyRune, and then expect the application to -// inspect the Rune() member of the EventKey. -type Key int16 - -// This is the list of named keys. KeyRune is special however, in that it is -// a place holder key indicating that a printable character was sent. The -// actual value of the rune will be transported in the Rune of the associated -// EventKey. -const ( - KeyRune Key = iota + 256 - KeyUp - KeyDown - KeyRight - KeyLeft - KeyUpLeft - KeyUpRight - KeyDownLeft - KeyDownRight - KeyCenter - KeyPgUp - KeyPgDn - KeyHome - KeyEnd - KeyInsert - KeyDelete - KeyHelp - KeyExit - KeyClear - KeyCancel - KeyPrint - KeyPause - KeyBacktab - KeyF1 - KeyF2 - KeyF3 - KeyF4 - KeyF5 - KeyF6 - KeyF7 - KeyF8 - KeyF9 - KeyF10 - KeyF11 - KeyF12 - KeyF13 - KeyF14 - KeyF15 - KeyF16 - KeyF17 - KeyF18 - KeyF19 - KeyF20 - KeyF21 - KeyF22 - KeyF23 - KeyF24 - KeyF25 - KeyF26 - KeyF27 - KeyF28 - KeyF29 - KeyF30 - KeyF31 - KeyF32 - KeyF33 - KeyF34 - KeyF35 - KeyF36 - KeyF37 - KeyF38 - KeyF39 - KeyF40 - KeyF41 - KeyF42 - KeyF43 - KeyF44 - KeyF45 - KeyF46 - KeyF47 - KeyF48 - KeyF49 - KeyF50 - KeyF51 - KeyF52 - KeyF53 - KeyF54 - KeyF55 - KeyF56 - KeyF57 - KeyF58 - KeyF59 - KeyF60 - KeyF61 - KeyF62 - KeyF63 - KeyF64 -) - -const ( - // These key codes are used internally, and will never appear to applications. - keyPasteStart Key = iota + 16384 - keyPasteEnd -) - -// These are the control keys. Note that they overlap with other keys, -// perhaps. For example, KeyCtrlH is the same as KeyBackspace. -const ( - KeyCtrlSpace Key = iota - KeyCtrlA - KeyCtrlB - KeyCtrlC - KeyCtrlD - KeyCtrlE - KeyCtrlF - KeyCtrlG - KeyCtrlH - KeyCtrlI - KeyCtrlJ - KeyCtrlK - KeyCtrlL - KeyCtrlM - KeyCtrlN - KeyCtrlO - KeyCtrlP - KeyCtrlQ - KeyCtrlR - KeyCtrlS - KeyCtrlT - KeyCtrlU - KeyCtrlV - KeyCtrlW - KeyCtrlX - KeyCtrlY - KeyCtrlZ - KeyCtrlLeftSq // Escape - KeyCtrlBackslash - KeyCtrlRightSq - KeyCtrlCarat - KeyCtrlUnderscore -) - -// Special values - these are fixed in an attempt to make it more likely -// that aliases will encode the same way. - -// These are the defined ASCII values for key codes. They generally match -// with KeyCtrl values. -const ( - KeyNUL Key = iota - KeySOH - KeySTX - KeyETX - KeyEOT - KeyENQ - KeyACK - KeyBEL - KeyBS - KeyTAB - KeyLF - KeyVT - KeyFF - KeyCR - KeySO - KeySI - KeyDLE - KeyDC1 - KeyDC2 - KeyDC3 - KeyDC4 - KeyNAK - KeySYN - KeyETB - KeyCAN - KeyEM - KeySUB - KeyESC - KeyFS - KeyGS - KeyRS - KeyUS - KeyDEL Key = 0x7F -) - -// These keys are aliases for other names. -const ( - KeyBackspace = KeyBS - KeyTab = KeyTAB - KeyEsc = KeyESC - KeyEscape = KeyESC - KeyEnter = KeyCR - KeyBackspace2 = KeyDEL -) diff --git a/vendor/github.com/gdamore/tcell/v2/logos/patreon.png b/vendor/github.com/gdamore/tcell/v2/logos/patreon.png deleted file mode 100644 index d2a0d52..0000000 Binary files a/vendor/github.com/gdamore/tcell/v2/logos/patreon.png and /dev/null differ diff --git a/vendor/github.com/gdamore/tcell/v2/logos/staysail.png b/vendor/github.com/gdamore/tcell/v2/logos/staysail.png deleted file mode 100644 index b955532..0000000 Binary files a/vendor/github.com/gdamore/tcell/v2/logos/staysail.png and /dev/null differ diff --git a/vendor/github.com/gdamore/tcell/v2/logos/tcell.png b/vendor/github.com/gdamore/tcell/v2/logos/tcell.png deleted file mode 100644 index 24333c4..0000000 Binary files a/vendor/github.com/gdamore/tcell/v2/logos/tcell.png and /dev/null differ diff --git a/vendor/github.com/gdamore/tcell/v2/logos/tidelift.png b/vendor/github.com/gdamore/tcell/v2/logos/tidelift.png deleted file mode 100644 index 924071f..0000000 Binary files a/vendor/github.com/gdamore/tcell/v2/logos/tidelift.png and /dev/null differ diff --git a/vendor/github.com/gdamore/tcell/v2/mouse.go b/vendor/github.com/gdamore/tcell/v2/mouse.go deleted file mode 100644 index 008c2e2..0000000 --- a/vendor/github.com/gdamore/tcell/v2/mouse.go +++ /dev/null @@ -1,103 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "time" -) - -// EventMouse is a mouse event. It is sent on either mouse up or mouse down -// events. It is also sent on mouse motion events - if the terminal supports -// it. We make every effort to ensure that mouse release events are delivered. -// Hence, click drag can be identified by a motion event with the mouse down, -// without any intervening button release. On some terminals only the initiating -// press and terminating release event will be delivered. -// -// Mouse wheel events, when reported, may appear on their own as individual -// impulses; that is, there will normally not be a release event delivered -// for mouse wheel movements. -// -// Most terminals cannot report the state of more than one button at a time -- -// and some cannot report motion events unless a button is pressed. -// -// Applications can inspect the time between events to resolve double or -// triple clicks. -type EventMouse struct { - t time.Time - btn ButtonMask - mod ModMask - x int - y int -} - -// When returns the time when this EventMouse was created. -func (ev *EventMouse) When() time.Time { - return ev.t -} - -// Buttons returns the list of buttons that were pressed or wheel motions. -func (ev *EventMouse) Buttons() ButtonMask { - return ev.btn -} - -// Modifiers returns a list of keyboard modifiers that were pressed -// with the mouse button(s). -func (ev *EventMouse) Modifiers() ModMask { - return ev.mod -} - -// Position returns the mouse position in character cells. The origin -// 0, 0 is at the upper left corner. -func (ev *EventMouse) Position() (int, int) { - return ev.x, ev.y -} - -// NewEventMouse is used to create a new mouse event. Applications -// shouldn't need to use this; its mostly for screen implementors. -func NewEventMouse(x, y int, btn ButtonMask, mod ModMask) *EventMouse { - return &EventMouse{t: time.Now(), x: x, y: y, btn: btn, mod: mod} -} - -// ButtonMask is a mask of mouse buttons and wheel events. Mouse button presses -// are normally delivered as both press and release events. Mouse wheel events -// are normally just single impulse events. Windows supports up to eight -// separate buttons plus all four wheel directions, but XTerm can only support -// mouse buttons 1-3 and wheel up/down. Its not unheard of for terminals -// to support only one or two buttons (think Macs). Old terminals, and true -// emulations (such as vt100) won't support mice at all, of course. -type ButtonMask int16 - -// These are the actual button values. Note that tcell version 1.x reversed buttons -// two and three on *nix based terminals. We use button 1 as the primary, and -// button 2 as the secondary, and button 3 (which is often missing) as the middle. -const ( - Button1 ButtonMask = 1 << iota // Usually the left (primary) mouse button. - Button2 // Usually the right (secondary) mouse button. - Button3 // Usually the middle mouse button. - Button4 // Often a side button (thumb/next). - Button5 // Often a side button (thumb/prev). - Button6 - Button7 - Button8 - WheelUp // Wheel motion up/away from user. - WheelDown // Wheel motion down/towards user. - WheelLeft // Wheel motion to left. - WheelRight // Wheel motion to right. - ButtonNone ButtonMask = 0 // No button or wheel events. - - ButtonPrimary = Button1 - ButtonSecondary = Button2 - ButtonMiddle = Button3 -) diff --git a/vendor/github.com/gdamore/tcell/v2/paste.go b/vendor/github.com/gdamore/tcell/v2/paste.go deleted file mode 100644 index 71cf8b1..0000000 --- a/vendor/github.com/gdamore/tcell/v2/paste.go +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "time" -) - -// EventPaste is used to mark the start and end of a bracketed paste. -// An event with .Start() true will be sent to mark the start. -// Then a number of keys will be sent to indicate that the content -// is pasted in. At the end, an event with .Start() false will be sent. -type EventPaste struct { - start bool - t time.Time -} - -// When returns the time when this EventMouse was created. -func (ev *EventPaste) When() time.Time { - return ev.t -} - -// Start returns true if this is the start of a paste. -func (ev *EventPaste) Start() bool { - return ev.start -} - -// End returns true if this is the end of a paste. -func (ev *EventPaste) End() bool { - return !ev.start -} - -// NewEventPaste returns a new EventPaste. -func NewEventPaste(start bool) *EventPaste { - return &EventPaste{t: time.Now(), start: start} -} diff --git a/vendor/github.com/gdamore/tcell/v2/resize.go b/vendor/github.com/gdamore/tcell/v2/resize.go deleted file mode 100644 index 0385673..0000000 --- a/vendor/github.com/gdamore/tcell/v2/resize.go +++ /dev/null @@ -1,42 +0,0 @@ -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "time" -) - -// EventResize is sent when the window size changes. -type EventResize struct { - t time.Time - w int - h int -} - -// NewEventResize creates an EventResize with the new updated window size, -// which is given in character cells. -func NewEventResize(width, height int) *EventResize { - return &EventResize{t: time.Now(), w: width, h: height} -} - -// When returns the time when the Event was created. -func (ev *EventResize) When() time.Time { - return ev.t -} - -// Size returns the new window size as width, height in character cells. -func (ev *EventResize) Size() (int, int) { - return ev.w, ev.h -} diff --git a/vendor/github.com/gdamore/tcell/v2/runes.go b/vendor/github.com/gdamore/tcell/v2/runes.go deleted file mode 100644 index ed9c63b..0000000 --- a/vendor/github.com/gdamore/tcell/v2/runes.go +++ /dev/null @@ -1,111 +0,0 @@ -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// The names of these constants are chosen to match Terminfo names, -// modulo case, and changing the prefix from ACS_ to Rune. These are -// the runes we provide extra special handling for, with ASCII fallbacks -// for terminals that lack them. -const ( - RuneSterling = '£' - RuneDArrow = '↓' - RuneLArrow = '←' - RuneRArrow = '→' - RuneUArrow = '↑' - RuneBullet = '·' - RuneBoard = '░' - RuneCkBoard = '▒' - RuneDegree = '°' - RuneDiamond = '◆' - RuneGEqual = '≥' - RunePi = 'π' - RuneHLine = '─' - RuneLantern = '§' - RunePlus = '┼' - RuneLEqual = '≤' - RuneLLCorner = '└' - RuneLRCorner = '┘' - RuneNEqual = '≠' - RunePlMinus = '±' - RuneS1 = '⎺' - RuneS3 = '⎻' - RuneS7 = '⎼' - RuneS9 = '⎽' - RuneBlock = '█' - RuneTTee = '┬' - RuneRTee = '┤' - RuneLTee = '├' - RuneBTee = '┴' - RuneULCorner = '┌' - RuneURCorner = '┐' - RuneVLine = '│' -) - -// RuneFallbacks is the default map of fallback strings that will be -// used to replace a rune when no other more appropriate transformation -// is available, and the rune cannot be displayed directly. -// -// New entries may be added to this map over time, as it becomes clear -// that such is desirable. Characters that represent either letters or -// numbers should not be added to this list unless it is certain that -// the meaning will still convey unambiguously. -// -// As an example, it would be appropriate to add an ASCII mapping for -// the full width form of the letter 'A', but it would not be appropriate -// to do so a glyph representing the country China. -// -// Programs that desire richer fallbacks may register additional ones, -// or change or even remove these mappings with Screen.RegisterRuneFallback -// Screen.UnregisterRuneFallback methods. -// -// Note that Unicode is presumed to be able to display all glyphs. -// This is a pretty poor assumption, but there is no easy way to -// figure out which glyphs are supported in a given font. Hence, -// some care in selecting the characters you support in your application -// is still appropriate. -var RuneFallbacks = map[rune]string{ - RuneSterling: "f", - RuneDArrow: "v", - RuneLArrow: "<", - RuneRArrow: ">", - RuneUArrow: "^", - RuneBullet: "o", - RuneBoard: "#", - RuneCkBoard: ":", - RuneDegree: "\\", - RuneDiamond: "+", - RuneGEqual: ">", - RunePi: "*", - RuneHLine: "-", - RuneLantern: "#", - RunePlus: "+", - RuneLEqual: "<", - RuneLLCorner: "+", - RuneLRCorner: "+", - RuneNEqual: "!", - RunePlMinus: "#", - RuneS1: "~", - RuneS3: "-", - RuneS7: "-", - RuneS9: "_", - RuneBlock: "#", - RuneTTee: "+", - RuneRTee: "+", - RuneLTee: "+", - RuneBTee: "+", - RuneULCorner: "+", - RuneURCorner: "+", - RuneVLine: "|", -} diff --git a/vendor/github.com/gdamore/tcell/v2/runes_test.go b/vendor/github.com/gdamore/tcell/v2/runes_test.go deleted file mode 100644 index 88bca5d..0000000 --- a/vendor/github.com/gdamore/tcell/v2/runes_test.go +++ /dev/null @@ -1,95 +0,0 @@ -// Copyright 2018 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "testing" -) - -func TestCanDisplayUTF8(t *testing.T) { - s := mkTestScreen(t, "UTF-8") - defer s.Fini() - - if s.CharacterSet() != "UTF-8" { - t.Errorf("Bad charset: %v", s.CharacterSet()) - } - if !s.CanDisplay('a', true) { - t.Errorf("Should be able to display 'a'") - } - if !s.CanDisplay(RuneHLine, true) { - t.Errorf("Should be able to display hline (with fallback)") - } - if !s.CanDisplay(RuneHLine, false) { - t.Errorf("Should be able to display hline (no fallback)") - } - if !s.CanDisplay('⌀', false) { - t.Errorf("Should be able to display null") - } -} -func TestCanDisplayASCII(t *testing.T) { - s := mkTestScreen(t, "US-ASCII") - defer s.Fini() - - if s.CharacterSet() != "US-ASCII" { - t.Errorf("Wrong character set: %v", s.CharacterSet()) - } - if !s.CanDisplay('a', true) { - t.Errorf("Should be able to display 'a'") - } - if !s.CanDisplay(RuneHLine, true) { - t.Errorf("Should be able to display hline (with fallback)") - } - if s.CanDisplay(RunePi, false) { - t.Errorf("Should not be able to display Pi (no fallback)") - } - if s.CanDisplay('⌀', false) { - t.Errorf("Should not be able to display null") - } -} - -func TestRuneFallbacks(t *testing.T) { - s := mkTestScreen(t, "US-ASCII") - defer s.Fini() - if s.CharacterSet() != "US-ASCII" { - t.Errorf("Wrong character set: %v", s.CharacterSet()) - } - - // Test registering a fallback - s.RegisterRuneFallback('⌀', "o") - if s.CanDisplay('⌀', false) { - t.Errorf("Should not be able to display null (no fallback)") - } - if !s.CanDisplay('⌀', true) { - t.Errorf("Should be able to display null (with fallback)") - } - - // Test unregistering custom fallback - s.UnregisterRuneFallback('⌀') - if s.CanDisplay('⌀', false) { - t.Errorf("Should not be able to display null (no fallback)") - } - if s.CanDisplay('⌀', true) { - t.Errorf("Should not be able to display null (with fallback)") - } - - // Test unregistering builtin fallback - if !s.CanDisplay(RuneHLine, true) { - t.Errorf("Should be able to display hline") - } - s.UnregisterRuneFallback(RuneHLine) - if s.CanDisplay(RuneHLine, true) { - t.Errorf("Should not be able to display hline") - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/screen.go b/vendor/github.com/gdamore/tcell/v2/screen.go deleted file mode 100644 index a3c9e46..0000000 --- a/vendor/github.com/gdamore/tcell/v2/screen.go +++ /dev/null @@ -1,219 +0,0 @@ -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// Screen represents the physical (or emulated) screen. -// This can be a terminal window or a physical console. Platforms implement -// this differerently. -type Screen interface { - // Init initializes the screen for use. - Init() error - - // Fini finalizes the screen also releasing resources. - Fini() - - // Clear erases the screen. The contents of any screen buffers - // will also be cleared. This has the logical effect of - // filling the screen with spaces, using the global default style. - Clear() - - // Fill fills the screen with the given character and style. - Fill(rune, Style) - - // SetCell is an older API, and will be removed. Please use - // SetContent instead; SetCell is implemented in terms of SetContent. - SetCell(x int, y int, style Style, ch ...rune) - - // GetContent returns the contents at the given location. If the - // coordinates are out of range, then the values will be 0, nil, - // StyleDefault. Note that the contents returned are logical contents - // and may not actually be what is displayed, but rather are what will - // be displayed if Show() or Sync() is called. The width is the width - // in screen cells; most often this will be 1, but some East Asian - // characters require two cells. - GetContent(x, y int) (mainc rune, combc []rune, style Style, width int) - - // SetContent sets the contents of the given cell location. If - // the coordinates are out of range, then the operation is ignored. - // - // The first rune is the primary non-zero width rune. The array - // that follows is a possible list of combining characters to append, - // and will usually be nil (no combining characters.) - // - // The results are not displayd until Show() or Sync() is called. - // - // Note that wide (East Asian full width) runes occupy two cells, - // and attempts to place character at next cell to the right will have - // undefined effects. Wide runes that are printed in the - // last column will be replaced with a single width space on output. - SetContent(x int, y int, mainc rune, combc []rune, style Style) - - // SetStyle sets the default style to use when clearing the screen - // or when StyleDefault is specified. If it is also StyleDefault, - // then whatever system/terminal default is relevant will be used. - SetStyle(style Style) - - // ShowCursor is used to display the cursor at a given location. - // If the coordinates -1, -1 are given or are otherwise outside the - // dimensions of the screen, the cursor will be hidden. - ShowCursor(x int, y int) - - // HideCursor is used to hide the cursor. Its an alias for - // ShowCursor(-1, -1). - HideCursor() - - // Size returns the screen size as width, height. This changes in - // response to a call to Clear or Flush. - Size() (int, int) - - // PollEvent waits for events to arrive. Main application loops - // must spin on this to prevent the application from stalling. - // Furthermore, this will return nil if the Screen is finalized. - PollEvent() Event - - // PostEvent tries to post an event into the event stream. This - // can fail if the event queue is full. In that case, the event - // is dropped, and ErrEventQFull is returned. - PostEvent(ev Event) error - - // PostEventWait is like PostEvent, but if the queue is full, it - // blocks until there is space in the queue, making delivery - // reliable. However, it is VERY important that this function - // never be called from within whatever event loop is polling - // with PollEvent(), otherwise a deadlock may arise. - // - // For this reason, when using this function, the use of a - // Goroutine is recommended to ensure no deadlock can occur. - PostEventWait(ev Event) - - // EnableMouse enables the mouse. (If your terminal supports it.) - EnableMouse() - - // DisableMouse disables the mouse. - DisableMouse() - - // EnablePaste enables bracketed paste mode, if supported. - EnablePaste() - - // DisablePaste() disables bracketed paste mode. - DisablePaste() - - // HasMouse returns true if the terminal (apparently) supports a - // mouse. Note that the a return value of true doesn't guarantee that - // a mouse/pointing device is present; a false return definitely - // indicates no mouse support is available. - HasMouse() bool - - // Colors returns the number of colors. All colors are assumed to - // use the ANSI color map. If a terminal is monochrome, it will - // return 0. - Colors() int - - // Show makes all the content changes made using SetContent() visible - // on the display. - // - // It does so in the most efficient and least visually disruptive - // manner possible. - Show() - - // Sync works like Show(), but it updates every visible cell on the - // physical display, assuming that it is not synchronized with any - // internal model. This may be both expensive and visually jarring, - // so it should only be used when believed to actually be necessary. - // - // Typically this is called as a result of a user-requested redraw - // (e.g. to clear up on screen corruption caused by some other program), - // or during a resize event. - Sync() - - // CharacterSet returns information about the character set. - // This isn't the full locale, but it does give us the input/output - // character set. Note that this is just for diagnostic purposes, - // we normally translate input/output to/from UTF-8, regardless of - // what the user's environment is. - CharacterSet() string - - // RegisterRuneFallback adds a fallback for runes that are not - // part of the character set -- for example one coudld register - // o as a fallback for ø. This should be done cautiously for - // characters that might be displayed ordinarily in language - // specific text -- characters that could change the meaning of - // of written text would be dangerous. The intention here is to - // facilitate fallback characters in pseudo-graphical applications. - // - // If the terminal has fallbacks already in place via an alternate - // character set, those are used in preference. Also, standard - // fallbacks for graphical characters in the ACSC terminfo string - // are registered implicitly. - - // The display string should be the same width as original rune. - // This makes it possible to register two character replacements - // for full width East Asian characters, for example. - // - // It is recommended that replacement strings consist only of - // 7-bit ASCII, since other characters may not display everywhere. - RegisterRuneFallback(r rune, subst string) - - // UnregisterRuneFallback unmaps a replacement. It will unmap - // the implicit ASCII replacements for alternate characters as well. - // When an unmapped char needs to be displayed, but no suitable - // glyph is available, '?' is emitted instead. It is not possible - // to "disable" the use of alternate characters that are supported - // by your terminal except by changing the terminal database. - UnregisterRuneFallback(r rune) - - // CanDisplay returns true if the given rune can be displayed on - // this screen. Note that this is a best guess effort -- whether - // your fonts support the character or not may be questionable. - // Mostly this is for folks who work outside of Unicode. - // - // If checkFallbacks is true, then if any (possibly imperfect) - // fallbacks are registered, this will return true. This will - // also return true if the terminal can replace the glyph with - // one that is visually indistinguishable from the one requested. - CanDisplay(r rune, checkFallbacks bool) bool - - // Resize does nothing, since its generally not possible to - // ask a screen to resize, but it allows the Screen to implement - // the View interface. - Resize(int, int, int, int) - - // HasKey returns true if the keyboard is believed to have the - // key. In some cases a keyboard may have keys with this name - // but no support for them, while in others a key may be reported - // as supported but not actually be usable (such as some emulators - // that hijack certain keys). Its best not to depend to strictly - // on this function, but it can be used for hinting when building - // menus, displayed hot-keys, etc. Note that KeyRune (literal - // runes) is always true. - HasKey(Key) bool - - // Beep attempts to sound an OS-dependent audible alert and returns an error - // when unsuccessful. - Beep() error -} - -// NewScreen returns a default Screen suitable for the user's terminal -// environment. -func NewScreen() (Screen, error) { - // Windows is happier if we try for a console screen first. - if s, _ := NewConsoleScreen(); s != nil { - return s, nil - } else if s, e := NewTerminfoScreen(); s != nil { - return s, nil - } else { - return nil, e - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/sim_test.go b/vendor/github.com/gdamore/tcell/v2/sim_test.go deleted file mode 100644 index 8cd7370..0000000 --- a/vendor/github.com/gdamore/tcell/v2/sim_test.go +++ /dev/null @@ -1,152 +0,0 @@ -// Copyright 2018 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "testing" -) - -func mkTestScreen(t *testing.T, charset string) SimulationScreen { - s := NewSimulationScreen(charset) - if s == nil { - t.Fatalf("Failed to get simulation screen") - } - if e := s.Init(); e != nil { - t.Fatalf("Failed to initialize screen: %v", e) - } - return s -} - -func TestInitScreen(t *testing.T) { - - s := mkTestScreen(t, "") - defer s.Fini() - - if x, y := s.Size(); x != 80 || y != 25 { - t.Fatalf("Size should be 80, 25, was %v, %v", x, y) - } - if s.CharacterSet() != "UTF-8" { - t.Fatalf("Character Set (%v) not UTF-8", s.CharacterSet()) - } - if b, x, y := s.GetContents(); len(b) != x*y || x != 80 || y != 25 { - t.Fatalf("Contents (%v, %v, %v) wrong", len(b), x, y) - } -} - -func TestClearScreen(t *testing.T) { - s := mkTestScreen(t, "") - defer s.Fini() - s.Clear() - b, x, y := s.GetContents() - if len(b) != x*y || x != 80 || y != 25 { - t.Fatalf("Contents (%v, %v, %v) wrong", len(b), x, y) - } - for i := 0; i < x*y; i++ { - if len(b[i].Runes) == 1 && b[i].Runes[0] != ' ' { - t.Errorf("Incorrect contents at %v: %v", i, b[i].Runes) - } - if b[i].Style != StyleDefault { - t.Errorf("Incorrect style at %v: %v", i, b[i].Style) - } - } -} - -func TestSetCell(t *testing.T) { - st := StyleDefault.Background(ColorRed).Blink(true) - s := mkTestScreen(t, "") - defer s.Fini() - s.SetCell(2, 5, st, '@') - b, _, _ := s.GetContents() - s.Show() - if len(b) != 80*25 { - t.Fatalf("Wrong content size") - } - cell := &b[5*80+2] - if len(cell.Runes) != 1 || len(cell.Bytes) != 1 || - cell.Runes[0] != '@' || cell.Bytes[0] != '@' || - cell.Style != st { - t.Errorf("Incorrect cell content: %v", cell) - } -} - -func TestResize(t *testing.T) { - st := StyleDefault.Background(ColorYellow).Underline(true) - s := mkTestScreen(t, "") - defer s.Fini() - s.SetCell(2, 5, st, '&') - b, x, y := s.GetContents() - s.Show() - - cell := &b[5*80+2] - if len(cell.Runes) != 1 || len(cell.Bytes) != 1 || - cell.Runes[0] != '&' || cell.Bytes[0] != '&' || - cell.Style != st { - t.Errorf("Incorrect cell content: %v", cell) - } - s.SetSize(30, 10) - s.Show() - b2, x2, y2 := s.GetContents() - if len(b2) == len(b) || x2 == x || y2 == y { - t.Errorf("Screen parameters should not match") - } - - cell2 := &b[5*80+2] - if len(cell2.Runes) != 1 || len(cell2.Bytes) != 1 || - cell2.Runes[0] != '&' || cell2.Bytes[0] != '&' || - cell2.Style != st { - t.Errorf("Incorrect cell content after resize: %v", cell2) - } -} - -func TestBeep(t *testing.T) { - s := mkTestScreen(t, "") - defer s.Fini() - - b0, x0, y0 := s.GetContents() - - if err := s.Beep(); err != nil { - t.Errorf("could not beep: %v", err) - } - s.Show() - - b1, x1, y1 := s.GetContents() - if x0 != x1 { - t.Fatalf("screen width changed unexpectedly from %d to %d", x0, x1) - } - if y0 != y1 { - t.Fatalf("screen height changed unexpectedly from %d to %d", y0, y1) - } - if len(b0) != len(b1) { - t.Fatalf("screen size changed unexpectedly (had %d cells, has %d cells)", - len(b0), len(b1)) - } - for i := 0; i < len(b0); i++ { - cell0 := b0[i] - cell1 := b1[i] - if len(cell0.Runes) != len(cell1.Runes) { - t.Errorf("incorrect cell content: had %d runes, has %d runes", - len(cell0.Runes), len(cell1.Runes)) - continue - } - for j := 0; j < len(cell0.Runes); j++ { - r0 := cell0.Runes[j] - r1 := cell1.Runes[j] - if r0 != r1 { - t.Errorf("incorrect content: cell %d rune %d changed from %v to %v", - i, j, r0, r1) - } - } - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/simulation.go b/vendor/github.com/gdamore/tcell/v2/simulation.go deleted file mode 100644 index 211a21f..0000000 --- a/vendor/github.com/gdamore/tcell/v2/simulation.go +++ /dev/null @@ -1,522 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "sync" - "unicode/utf8" - - "golang.org/x/text/transform" -) - -// NewSimulationScreen returns a SimulationScreen. Note that -// SimulationScreen is also a Screen. -func NewSimulationScreen(charset string) SimulationScreen { - if charset == "" { - charset = "UTF-8" - } - s := &simscreen{charset: charset} - return s -} - -// SimulationScreen represents a screen simulation. This is intended to -// be a superset of normal Screens, but also adds some important interfaces -// for testing. -type SimulationScreen interface { - // InjectKeyBytes injects a stream of bytes corresponding to - // the native encoding (see charset). It turns true if the entire - // set of bytes were processed and delivered as KeyEvents, false - // if any bytes were not fully understood. Any bytes that are not - // fully converted are discarded. - InjectKeyBytes(buf []byte) bool - - // InjectKey injects a key event. The rune is a UTF-8 rune, post - // any translation. - InjectKey(key Key, r rune, mod ModMask) - - // InjectMouse injects a mouse event. - InjectMouse(x, y int, buttons ButtonMask, mod ModMask) - - // SetSize resizes the underlying physical screen. It also causes - // a resize event to be injected during the next Show() or Sync(). - // A new physical contents array will be allocated (with data from - // the old copied), so any prior value obtained with GetContents - // won't be used anymore - SetSize(width, height int) - - // GetContents returns screen contents as an array of - // cells, along with the physical width & height. Note that the - // physical contents will be used until the next time SetSize() - // is called. - GetContents() (cells []SimCell, width int, height int) - - // GetCursor returns the cursor details. - GetCursor() (x int, y int, visible bool) - - Screen -} - -// SimCell represents a simulated screen cell. The purpose of this -// is to track on screen content. -type SimCell struct { - // Bytes is the actual character bytes. Normally this is - // rune data, but it could be be data in another encoding system. - Bytes []byte - - // Style is the style used to display the data. - Style Style - - // Runes is the list of runes, unadulterated, in UTF-8. - Runes []rune -} - -type simscreen struct { - physw int - physh int - fini bool - style Style - evch chan Event - quit chan struct{} - - front []SimCell - back CellBuffer - clear bool - cursorx int - cursory int - cursorvis bool - mouse bool - paste bool - charset string - encoder transform.Transformer - decoder transform.Transformer - fillchar rune - fillstyle Style - fallback map[rune]string - - sync.Mutex -} - -func (s *simscreen) Init() error { - s.evch = make(chan Event, 10) - s.quit = make(chan struct{}) - s.fillchar = 'X' - s.fillstyle = StyleDefault - s.mouse = false - s.physw = 80 - s.physh = 25 - s.cursorx = -1 - s.cursory = -1 - s.style = StyleDefault - - if enc := GetEncoding(s.charset); enc != nil { - s.encoder = enc.NewEncoder() - s.decoder = enc.NewDecoder() - } else { - return ErrNoCharset - } - - s.front = make([]SimCell, s.physw*s.physh) - s.back.Resize(80, 25) - - // default fallbacks - s.fallback = make(map[rune]string) - for k, v := range RuneFallbacks { - s.fallback[k] = v - } - return nil -} - -func (s *simscreen) Fini() { - s.Lock() - s.fini = true - s.back.Resize(0, 0) - s.Unlock() - if s.quit != nil { - close(s.quit) - } - s.physw = 0 - s.physh = 0 - s.front = nil -} - -func (s *simscreen) SetStyle(style Style) { - s.Lock() - s.style = style - s.Unlock() -} - -func (s *simscreen) Clear() { - s.Fill(' ', s.style) -} - -func (s *simscreen) Fill(r rune, style Style) { - s.Lock() - s.back.Fill(r, style) - s.Unlock() -} - -func (s *simscreen) SetCell(x, y int, style Style, ch ...rune) { - - if len(ch) > 0 { - s.SetContent(x, y, ch[0], ch[1:], style) - } else { - s.SetContent(x, y, ' ', nil, style) - } -} - -func (s *simscreen) SetContent(x, y int, mainc rune, combc []rune, st Style) { - - s.Lock() - s.back.SetContent(x, y, mainc, combc, st) - s.Unlock() -} - -func (s *simscreen) GetContent(x, y int) (rune, []rune, Style, int) { - var mainc rune - var combc []rune - var style Style - var width int - s.Lock() - mainc, combc, style, width = s.back.GetContent(x, y) - s.Unlock() - return mainc, combc, style, width -} - -func (s *simscreen) drawCell(x, y int) int { - - mainc, combc, style, width := s.back.GetContent(x, y) - if !s.back.Dirty(x, y) { - return width - } - if x >= s.physw || y >= s.physh || x < 0 || y < 0 { - return width - } - simc := &s.front[(y*s.physw)+x] - - if style == StyleDefault { - style = s.style - } - simc.Style = style - simc.Runes = append([]rune{mainc}, combc...) - - // now emit runes - taking care to not overrun width with a - // wide character, and to ensure that we emit exactly one regular - // character followed up by any residual combing characters - - simc.Bytes = nil - - if x > s.physw-width { - simc.Runes = []rune{' '} - simc.Bytes = []byte{' '} - return width - } - - lbuf := make([]byte, 12) - ubuf := make([]byte, 12) - nout := 0 - - for _, r := range simc.Runes { - - l := utf8.EncodeRune(ubuf, r) - - nout, _, _ = s.encoder.Transform(lbuf, ubuf[:l], true) - - if nout == 0 || lbuf[0] == '\x1a' { - - // skip combining - - if subst, ok := s.fallback[r]; ok { - simc.Bytes = append(simc.Bytes, - []byte(subst)...) - - } else if r >= ' ' && r <= '~' { - simc.Bytes = append(simc.Bytes, byte(r)) - - } else if simc.Bytes == nil { - simc.Bytes = append(simc.Bytes, '?') - } - } else { - simc.Bytes = append(simc.Bytes, lbuf[:nout]...) - } - } - s.back.SetDirty(x, y, false) - return width -} - -func (s *simscreen) ShowCursor(x, y int) { - s.Lock() - s.cursorx, s.cursory = x, y - s.showCursor() - s.Unlock() -} - -func (s *simscreen) HideCursor() { - s.ShowCursor(-1, -1) -} - -func (s *simscreen) showCursor() { - - x, y := s.cursorx, s.cursory - if x < 0 || y < 0 || x >= s.physw || y >= s.physh { - s.cursorvis = false - } else { - s.cursorvis = true - } -} - -func (s *simscreen) hideCursor() { - // does not update cursor position - s.cursorvis = false -} - -func (s *simscreen) Show() { - s.Lock() - s.resize() - s.draw() - s.Unlock() -} - -func (s *simscreen) clearScreen() { - // We emulate a hardware clear by filling with a specific pattern - for i := range s.front { - s.front[i].Style = s.fillstyle - s.front[i].Runes = []rune{s.fillchar} - s.front[i].Bytes = []byte{byte(s.fillchar)} - } - s.clear = false -} - -func (s *simscreen) draw() { - s.hideCursor() - if s.clear { - s.clearScreen() - } - - w, h := s.back.Size() - for y := 0; y < h; y++ { - for x := 0; x < w; x++ { - width := s.drawCell(x, y) - x += width - 1 - } - } - s.showCursor() -} - -func (s *simscreen) EnableMouse() { - s.mouse = true -} - -func (s *simscreen) DisableMouse() { - s.mouse = false -} - -func (s *simscreen) EnablePaste() { - s.paste = true -} - -func (s *simscreen) DisablePaste() { - s.paste = false -} - -func (s *simscreen) Size() (int, int) { - s.Lock() - w, h := s.back.Size() - s.Unlock() - return w, h -} - -func (s *simscreen) resize() { - w, h := s.physw, s.physh - ow, oh := s.back.Size() - if w != ow || h != oh { - s.back.Resize(w, h) - ev := NewEventResize(w, h) - s.PostEvent(ev) - } -} - -func (s *simscreen) Colors() int { - return 256 -} - -func (s *simscreen) PollEvent() Event { - select { - case <-s.quit: - return nil - case ev := <-s.evch: - return ev - } -} - -func (s *simscreen) PostEventWait(ev Event) { - s.evch <- ev -} - -func (s *simscreen) PostEvent(ev Event) error { - select { - case s.evch <- ev: - return nil - default: - return ErrEventQFull - } -} - -func (s *simscreen) InjectMouse(x, y int, buttons ButtonMask, mod ModMask) { - ev := NewEventMouse(x, y, buttons, mod) - s.PostEvent(ev) -} - -func (s *simscreen) InjectKey(key Key, r rune, mod ModMask) { - ev := NewEventKey(key, r, mod) - s.PostEvent(ev) -} - -func (s *simscreen) InjectKeyBytes(b []byte) bool { - failed := false - -outer: - for len(b) > 0 { - if b[0] >= ' ' && b[0] <= 0x7F { - // printable ASCII easy to deal with -- no encodings - ev := NewEventKey(KeyRune, rune(b[0]), ModNone) - s.PostEvent(ev) - b = b[1:] - continue - } - - if b[0] < 0x80 { - mod := ModNone - // No encodings start with low numbered values - if Key(b[0]) >= KeyCtrlA && Key(b[0]) <= KeyCtrlZ { - mod = ModCtrl - } - ev := NewEventKey(Key(b[0]), 0, mod) - s.PostEvent(ev) - b = b[1:] - continue - } - - utfb := make([]byte, len(b)*4) // worst case - for l := 1; l < len(b); l++ { - s.decoder.Reset() - nout, nin, _ := s.decoder.Transform(utfb, b[:l], true) - - if nout != 0 { - r, _ := utf8.DecodeRune(utfb[:nout]) - if r != utf8.RuneError { - ev := NewEventKey(KeyRune, r, ModNone) - s.PostEvent(ev) - } - b = b[nin:] - continue outer - } - } - failed = true - b = b[1:] - continue - } - - return !failed -} - -func (s *simscreen) Sync() { - s.Lock() - s.clear = true - s.resize() - s.back.Invalidate() - s.draw() - s.Unlock() -} - -func (s *simscreen) CharacterSet() string { - return s.charset -} - -func (s *simscreen) SetSize(w, h int) { - s.Lock() - newc := make([]SimCell, w*h) - for row := 0; row < h && row < s.physh; row++ { - for col := 0; col < w && col < s.physw; col++ { - newc[(row*w)+col] = s.front[(row*s.physw)+col] - } - } - s.cursorx, s.cursory = -1, -1 - s.physw, s.physh = w, h - s.front = newc - s.back.Resize(w, h) - s.Unlock() -} - -func (s *simscreen) GetContents() ([]SimCell, int, int) { - s.Lock() - cells, w, h := s.front, s.physw, s.physh - s.Unlock() - return cells, w, h -} - -func (s *simscreen) GetCursor() (int, int, bool) { - s.Lock() - x, y, vis := s.cursorx, s.cursory, s.cursorvis - s.Unlock() - return x, y, vis -} - -func (s *simscreen) RegisterRuneFallback(r rune, subst string) { - s.Lock() - s.fallback[r] = subst - s.Unlock() -} - -func (s *simscreen) UnregisterRuneFallback(r rune) { - s.Lock() - delete(s.fallback, r) - s.Unlock() -} - -func (s *simscreen) CanDisplay(r rune, checkFallbacks bool) bool { - - if enc := s.encoder; enc != nil { - nb := make([]byte, 6) - ob := make([]byte, 6) - num := utf8.EncodeRune(ob, r) - - enc.Reset() - dst, _, err := enc.Transform(nb, ob[:num], true) - if dst != 0 && err == nil && nb[0] != '\x1A' { - return true - } - } - if !checkFallbacks { - return false - } - if _, ok := s.fallback[r]; ok { - return true - } - return false -} - -func (s *simscreen) HasMouse() bool { - return false -} - -func (s *simscreen) Resize(int, int, int, int) {} - -func (s *simscreen) HasKey(Key) bool { - return true -} - -func (s *simscreen) Beep() error { - return nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/style.go b/vendor/github.com/gdamore/tcell/v2/style.go deleted file mode 100644 index 8359e28..0000000 --- a/vendor/github.com/gdamore/tcell/v2/style.go +++ /dev/null @@ -1,137 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// Style represents a complete text style, including both foreground color, -// background color, and additional attributes such as "bold" or "underline". -// -// Note that not all terminals can display all colors or attributes, and -// many might have specific incompatibilities between specific attributes -// and color combinations. -// -// To use Style, just declare a variable of its type. -type Style struct { - fg Color - bg Color - attrs AttrMask -} - -// StyleDefault represents a default style, based upon the context. -// It is the zero value. -var StyleDefault Style - -// styleInvalid is just an arbitrary invalid style used internally. -var styleInvalid = Style{attrs: AttrInvalid} - -// Foreground returns a new style based on s, with the foreground color set -// as requested. ColorDefault can be used to select the global default. -func (s Style) Foreground(c Color) Style { - return Style{ - fg: c, - bg: s.bg, - attrs: s.attrs, - } -} - -// Background returns a new style based on s, with the background color set -// as requested. ColorDefault can be used to select the global default. -func (s Style) Background(c Color) Style { - return Style{ - fg: s.fg, - bg: c, - attrs: s.attrs, - } -} - -// Decompose breaks a style up, returning the foreground, background, -// and other attributes. -func (s Style) Decompose() (fg Color, bg Color, attr AttrMask) { - return s.fg, s.bg, s.attrs -} - -func (s Style) setAttrs(attrs AttrMask, on bool) Style { - if on { - return Style{ - fg: s.fg, - bg: s.bg, - attrs: s.attrs | attrs, - } - } - return Style{ - fg: s.fg, - bg: s.bg, - attrs: s.attrs &^ attrs, - } -} - -// Normal returns the style with all attributes disabled. -func (s Style) Normal() Style { - return Style{ - fg: s.fg, - bg: s.bg, - } -} - -// Bold returns a new style based on s, with the bold attribute set -// as requested. -func (s Style) Bold(on bool) Style { - return s.setAttrs(AttrBold, on) -} - -// Blink returns a new style based on s, with the blink attribute set -// as requested. -func (s Style) Blink(on bool) Style { - return s.setAttrs(AttrBlink, on) -} - -// Dim returns a new style based on s, with the dim attribute set -// as requested. -func (s Style) Dim(on bool) Style { - return s.setAttrs(AttrDim, on) -} - -// Italic returns a new style based on s, with the italic attribute set -// as requested. -func (s Style) Italic(on bool) Style { - return s.setAttrs(AttrItalic, on) -} - -// Reverse returns a new style based on s, with the reverse attribute set -// as requested. (Reverse usually changes the foreground and background -// colors.) -func (s Style) Reverse(on bool) Style { - return s.setAttrs(AttrReverse, on) -} - -// Underline returns a new style based on s, with the underline attribute set -// as requested. -func (s Style) Underline(on bool) Style { - return s.setAttrs(AttrUnderline, on) -} - -// StrikeThrough sets strikethrough mode. -func (s Style) StrikeThrough(on bool) Style { - return s.setAttrs(AttrStrikeThrough, on) -} - -// Attributes returns a new style based on s, with its attributes set as -// specified. -func (s Style) Attributes(attrs AttrMask) Style { - return Style{ - fg: s.fg, - bg: s.bg, - attrs: attrs, - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/style_test.go b/vendor/github.com/gdamore/tcell/v2/style_test.go deleted file mode 100644 index 861c65f..0000000 --- a/vendor/github.com/gdamore/tcell/v2/style_test.go +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2018 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "testing" -) - -func TestStyle(t *testing.T) { - s := mkTestScreen(t, "") - defer s.Fini() - - style := StyleDefault - fg, bg, attr := style.Decompose() - - if fg != ColorDefault || bg != ColorDefault || attr != AttrNone { - t.Errorf("Bad default style (%v, %v, %v)", fg, bg, attr) - } - - s2 := style. - Background(ColorRed). - Foreground(ColorBlue). - Blink(true) - - fg, bg, attr = s2.Decompose() - if fg != ColorBlue || bg != ColorRed || attr != AttrBlink { - t.Errorf("Bad custom style (%v, %v, %v)", fg, bg, attr) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/termbox/compat.go b/vendor/github.com/gdamore/tcell/v2/termbox/compat.go deleted file mode 100644 index e1bc4c6..0000000 --- a/vendor/github.com/gdamore/tcell/v2/termbox/compat.go +++ /dev/null @@ -1,379 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Package termbox is a compatibility layer to allow tcell to emulate -// the github.com/nsf/termbox package. -package termbox - -import ( - "errors" - - "github.com/gdamore/tcell/v2" -) - -var screen tcell.Screen -var outMode OutputMode - -// Init initializes the screen for use. -func Init() error { - outMode = OutputNormal - if s, e := tcell.NewScreen(); e != nil { - return e - } else if e = s.Init(); e != nil { - return e - } else { - screen = s - return nil - } -} - -// Close cleans up the terminal, restoring terminal modes, etc. -func Close() { - screen.Fini() -} - -// Flush updates the screen. -func Flush() error { - screen.Show() - return nil -} - -// SetCursor displays the terminal cursor at the given location. -func SetCursor(x, y int) { - screen.ShowCursor(x, y) -} - -// HideCursor hides the terminal cursor. -func HideCursor() { - SetCursor(-1, -1) -} - -// Size returns the screen size as width, height in character cells. -func Size() (int, int) { - return screen.Size() -} - -// Attribute affects the presentation of characters, such as color, boldness, -// and so forth. -type Attribute uint16 - -// Colors first. The order here is significant. -const ( - ColorDefault Attribute = iota - ColorBlack - ColorRed - ColorGreen - ColorYellow - ColorBlue - ColorMagenta - ColorCyan - ColorWhite -) - -// Other attributes. -const ( - AttrBold Attribute = 1 << (9 + iota) - AttrUnderline - AttrReverse -) - -func fixColor(c tcell.Color) tcell.Color { - if c == tcell.ColorDefault { - return c - } - switch outMode { - case OutputNormal: - c %= tcell.Color(16) - case Output256: - c %= tcell.Color(256) - case Output216: - c %= tcell.Color(216) - c += tcell.Color(16) - case OutputGrayscale: - c %= tcell.Color(24) - c += tcell.Color(232) - default: - c = tcell.ColorDefault - } - return c -} - -func mkStyle(fg, bg Attribute) tcell.Style { - st := tcell.StyleDefault - - f := tcell.Color(int(fg)&0x1ff) - 1 - b := tcell.Color(int(bg)&0x1ff) - 1 - - f = fixColor(f) - b = fixColor(b) - st = st.Foreground(f).Background(b) - if (fg|bg)&AttrBold != 0 { - st = st.Bold(true) - } - if (fg|bg)&AttrUnderline != 0 { - st = st.Underline(true) - } - if (fg|bg)&AttrReverse != 0 { - st = st.Reverse(true) - } - return st -} - -// Clear clears the screen with the given attributes. -func Clear(fg, bg Attribute) { - st := mkStyle(fg, bg) - w, h := screen.Size() - for row := 0; row < h; row++ { - for col := 0; col < w; col++ { - screen.SetContent(col, row, ' ', nil, st) - } - } -} - -// InputMode is not used. -type InputMode int - -// Unused input modes; here for compatibility. -const ( - InputCurrent InputMode = iota - InputEsc - InputAlt - InputMouse -) - -// SetInputMode does not do anything in this version. -func SetInputMode(mode InputMode) InputMode { - // We don't do anything else right now - return InputEsc -} - -// OutputMode represents an output mode, which determines how colors -// are used. See the termbox documentation for an explanation. -type OutputMode int - -// OutputMode values. -const ( - OutputCurrent OutputMode = iota - OutputNormal - Output256 - Output216 - OutputGrayscale -) - -// SetOutputMode is used to set the color palette used. -func SetOutputMode(mode OutputMode) OutputMode { - if screen.Colors() < 256 { - mode = OutputNormal - } - switch mode { - case OutputCurrent: - return outMode - case OutputNormal, Output256, Output216, OutputGrayscale: - outMode = mode - return mode - default: - return outMode - } -} - -// Sync forces a resync of the screen. -func Sync() error { - screen.Sync() - return nil -} - -// SetCell sets the character cell at a given location to the given -// content (rune) and attributes. -func SetCell(x, y int, ch rune, fg, bg Attribute) { - st := mkStyle(fg, bg) - screen.SetContent(x, y, ch, nil, st) -} - -// EventType represents the type of event. -type EventType uint8 - -// Modifier represents the possible modifier keys. -type Modifier tcell.ModMask - -// Key is a key press. -type Key tcell.Key - -// Event represents an event like a key press, mouse action, or window resize. -type Event struct { - Type EventType - Mod Modifier - Key Key - Ch rune - Width int - Height int - Err error - MouseX int - MouseY int - N int -} - -// Event types. -const ( - EventNone EventType = iota - EventKey - EventResize - EventMouse - EventInterrupt - EventError - EventRaw -) - -// Keys codes. -const ( - KeyF1 = Key(tcell.KeyF1) - KeyF2 = Key(tcell.KeyF2) - KeyF3 = Key(tcell.KeyF3) - KeyF4 = Key(tcell.KeyF4) - KeyF5 = Key(tcell.KeyF5) - KeyF6 = Key(tcell.KeyF6) - KeyF7 = Key(tcell.KeyF7) - KeyF8 = Key(tcell.KeyF8) - KeyF9 = Key(tcell.KeyF9) - KeyF10 = Key(tcell.KeyF10) - KeyF11 = Key(tcell.KeyF11) - KeyF12 = Key(tcell.KeyF12) - KeyInsert = Key(tcell.KeyInsert) - KeyDelete = Key(tcell.KeyDelete) - KeyHome = Key(tcell.KeyHome) - KeyEnd = Key(tcell.KeyEnd) - KeyArrowUp = Key(tcell.KeyUp) - KeyArrowDown = Key(tcell.KeyDown) - KeyArrowRight = Key(tcell.KeyRight) - KeyArrowLeft = Key(tcell.KeyLeft) - KeyCtrlA = Key(tcell.KeyCtrlA) - KeyCtrlB = Key(tcell.KeyCtrlB) - KeyCtrlC = Key(tcell.KeyCtrlC) - KeyCtrlD = Key(tcell.KeyCtrlD) - KeyCtrlE = Key(tcell.KeyCtrlE) - KeyCtrlF = Key(tcell.KeyCtrlF) - KeyCtrlG = Key(tcell.KeyCtrlG) - KeyCtrlH = Key(tcell.KeyCtrlH) - KeyCtrlI = Key(tcell.KeyCtrlI) - KeyCtrlJ = Key(tcell.KeyCtrlJ) - KeyCtrlK = Key(tcell.KeyCtrlK) - KeyCtrlL = Key(tcell.KeyCtrlL) - KeyCtrlM = Key(tcell.KeyCtrlM) - KeyCtrlN = Key(tcell.KeyCtrlN) - KeyCtrlO = Key(tcell.KeyCtrlO) - KeyCtrlP = Key(tcell.KeyCtrlP) - KeyCtrlQ = Key(tcell.KeyCtrlQ) - KeyCtrlR = Key(tcell.KeyCtrlR) - KeyCtrlS = Key(tcell.KeyCtrlS) - KeyCtrlT = Key(tcell.KeyCtrlT) - KeyCtrlU = Key(tcell.KeyCtrlU) - KeyCtrlV = Key(tcell.KeyCtrlV) - KeyCtrlW = Key(tcell.KeyCtrlW) - KeyCtrlX = Key(tcell.KeyCtrlX) - KeyCtrlY = Key(tcell.KeyCtrlY) - KeyCtrlZ = Key(tcell.KeyCtrlZ) - KeyCtrlUnderscore = Key(tcell.KeyCtrlUnderscore) - KeyBackspace = Key(tcell.KeyBackspace) - KeyBackspace2 = Key(tcell.KeyBackspace2) - KeyTab = Key(tcell.KeyTab) - KeyEnter = Key(tcell.KeyEnter) - KeyEsc = Key(tcell.KeyEscape) - KeyPgdn = Key(tcell.KeyPgDn) - KeyPgup = Key(tcell.KeyPgUp) - KeySpace = Key(tcell.Key(' ')) - KeyTilde = Key(tcell.Key('~')) - - // The following assignments are provided for termbox - // compatibility. Their use in applications is discouraged. - // The mouse keys are completely not supported as tcell uses - // a separate mouse event instead of key strokes. - MouseLeft = Key(tcell.KeyF63) // arbitrary assignments - MouseRight = Key(tcell.KeyF62) - MouseMiddle = Key(tcell.KeyF61) - MouseRelease = Key(tcell.KeyF60) - MouseWheelUp = Key(tcell.KeyF59) - MouseWheelDown = Key(tcell.KeyF58) - KeyCtrl2 = Key(tcell.KeyNUL) // termbox defines theses - KeyCtrl3 = Key(tcell.KeyEscape) - KeyCtrl4 = Key(tcell.KeyCtrlBackslash) - KeyCtrl5 = Key(tcell.KeyCtrlRightSq) - KeyCtrl6 = Key(tcell.KeyCtrlCarat) - KeyCtrl7 = Key(tcell.KeyCtrlUnderscore) - KeyCtrlSlash = Key(tcell.KeyCtrlUnderscore) - KeyCtrlRsqBracket = Key(tcell.KeyCtrlRightSq) - KeyCtrlBackslash = Key(tcell.KeyCtrlBackslash) - KeyCtrlLsqBracket = Key(tcell.KeyCtrlLeftSq) -) - -// Modifiers. -const ( - ModAlt = Modifier(tcell.ModAlt) -) - -func makeEvent(tev tcell.Event) Event { - switch tev := tev.(type) { - case *tcell.EventInterrupt: - return Event{Type: EventInterrupt} - case *tcell.EventResize: - w, h := tev.Size() - return Event{Type: EventResize, Width: w, Height: h} - case *tcell.EventKey: - k := tev.Key() - ch := rune(0) - if k == tcell.KeyRune { - ch = tev.Rune() - if ch == ' ' { - k = tcell.Key(' ') - } - } - mod := tev.Modifiers() - return Event{ - Type: EventKey, - Key: Key(k), - Ch: ch, - Mod: Modifier(mod), - } - default: - return Event{Type: EventNone} - } -} - -// ParseEvent is not supported. -func ParseEvent(data []byte) Event { - // Not supported - return Event{Type: EventError, Err: errors.New("no raw events")} -} - -// PollRawEvent is not supported. -func PollRawEvent(data []byte) Event { - // Not supported - return Event{Type: EventError, Err: errors.New("no raw events")} -} - -// PollEvent blocks until an event is ready, and then returns it. -func PollEvent() Event { - ev := screen.PollEvent() - return makeEvent(ev) -} - -// Interrupt posts an interrupt event. -func Interrupt() { - screen.PostEvent(tcell.NewEventInterrupt(nil)) -} - -// Cell represents a single character cell on screen. -type Cell struct { - Ch rune - Fg Attribute - Bg Attribute -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/.gitignore b/vendor/github.com/gdamore/tcell/v2/terminfo/.gitignore deleted file mode 100644 index 74f3c04..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/.gitignore +++ /dev/null @@ -1 +0,0 @@ -mkinfo diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/README.md b/vendor/github.com/gdamore/tcell/v2/terminfo/README.md deleted file mode 100644 index 20ae937..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/README.md +++ /dev/null @@ -1,25 +0,0 @@ -This package represents the parent for all terminals. - -In older versions of tcell we had (a couple of) different -external file formats for the terminal database. Those are -now removed. All terminal definitions are supplied by -one of two methods: - -1. Compiled Go code - -2. For systems with terminfo and infocmp, dynamically - generated at runtime. - -The Go code can be generated using the mkinfo utility in -this directory. The database entry should be generated -into a package in a directory named as the first character -of the package name. (This permits us to group them all -without having a huge directory of little packages.) - -It may be desirable to add new packages to the extended -package, or -- rarely -- the base package. - -Applications which want to have the large set of terminal -descriptions built into the binary can simply import the -extended package. Otherwise a smaller reasonable default -set (the base package) will be included instead. diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/TERMINALS.md b/vendor/github.com/gdamore/tcell/v2/terminfo/TERMINALS.md deleted file mode 100644 index 85c1e61..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/TERMINALS.md +++ /dev/null @@ -1,7 +0,0 @@ -TERMINALS -========= - -The best way to populate terminals on Debian is to install ncurses, -ncurses-term, screen, tmux, rxvt-unicode, and dvtm. This populates the -the terminfo database so that we can have a reasonable set of starting -terminals. diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/a/aixterm/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/a/aixterm/term.go deleted file mode 100644 index 566df7b..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/a/aixterm/term.go +++ /dev/null @@ -1,82 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package aixterm - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // IBM Aixterm Terminal Emulator - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "aixterm", - Columns: 80, - Lines: 25, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - AttrOff: "\x1b[0;10m\x1b(B", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Reverse: "\x1b[7m", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[32m\x1b[40m", - PadChar: "\x00", - AltChars: "jjkkllmmnnqqttuuvvwwxx", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[139q", - KeyDelete: "\x1b[P", - KeyBackspace: "\b", - KeyHome: "\x1b[H", - KeyEnd: "\x1b[146q", - KeyPgUp: "\x1b[150q", - KeyPgDn: "\x1b[154q", - KeyF1: "\x1b[001q", - KeyF2: "\x1b[002q", - KeyF3: "\x1b[003q", - KeyF4: "\x1b[004q", - KeyF5: "\x1b[005q", - KeyF6: "\x1b[006q", - KeyF7: "\x1b[007q", - KeyF8: "\x1b[008q", - KeyF9: "\x1b[009q", - KeyF10: "\x1b[010q", - KeyF11: "\x1b[011q", - KeyF12: "\x1b[012q", - KeyF13: "\x1b[013q", - KeyF14: "\x1b[014q", - KeyF15: "\x1b[015q", - KeyF16: "\x1b[016q", - KeyF17: "\x1b[017q", - KeyF18: "\x1b[018q", - KeyF19: "\x1b[019q", - KeyF20: "\x1b[020q", - KeyF21: "\x1b[021q", - KeyF22: "\x1b[022q", - KeyF23: "\x1b[023q", - KeyF24: "\x1b[024q", - KeyF25: "\x1b[025q", - KeyF26: "\x1b[026q", - KeyF27: "\x1b[027q", - KeyF28: "\x1b[028q", - KeyF29: "\x1b[029q", - KeyF30: "\x1b[030q", - KeyF31: "\x1b[031q", - KeyF32: "\x1b[032q", - KeyF33: "\x1b[033q", - KeyF34: "\x1b[034q", - KeyF35: "\x1b[035q", - KeyF36: "\x1b[036q", - KeyClear: "\x1b[144q", - KeyBacktab: "\x1b[Z", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/a/alacritty/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/a/alacritty/term.go deleted file mode 100644 index 7257c65..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/a/alacritty/term.go +++ /dev/null @@ -1,69 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package alacritty - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // alacritty terminal emulator - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "alacritty", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h\x1b[22;0;0t", - ExitCA: "\x1b[?1049l\x1b[23;0;0t", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b(B\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[<", - MouseMode: "\x1b[?1006;1000%?%p1%{1}%=%th%el%;", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/a/ansi/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/a/ansi/term.go deleted file mode 100644 index 53e4e49..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/a/ansi/term.go +++ /dev/null @@ -1,42 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package ansi - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // ansi/pc-term compatible with color - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "ansi", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - AttrOff: "\x1b[0;10m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "+\x10,\x11-\x18.\x190\xdb`\x04a\xb1f\xf8g\xf1h\xb0j\xd9k\xbfl\xdam\xc0n\xc5o~p\xc4q\xc4r\xc4s_t\xc3u\xb4v\xc1w\xc2x\xb3y\xf3z\xf2{\xe3|\xd8}\x9c~\xfe", - EnterAcs: "\x1b[11m", - ExitAcs: "\x1b[10m", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\x1b[D", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[L", - KeyBackspace: "\b", - KeyHome: "\x1b[H", - KeyBacktab: "\x1b[Z", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/b/beterm/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/b/beterm/term.go deleted file mode 100644 index de2c992..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/b/beterm/term.go +++ /dev/null @@ -1,55 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package beterm - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // BeOS Terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "beterm", - Columns: 80, - Lines: 25, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - AttrOff: "\x1b[0;10m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?4h", - ExitKeypad: "\x1b[?4l", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[m", - PadChar: "\x00", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\b", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[16~", - KeyF7: "\x1b[17~", - KeyF8: "\x1b[18~", - KeyF9: "\x1b[19~", - KeyF10: "\x1b[20~", - KeyF11: "\x1b[21~", - KeyF12: "\x1b[22~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/base/base.go b/vendor/github.com/gdamore/tcell/v2/terminfo/base/base.go deleted file mode 100644 index fbecdfa..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/base/base.go +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// This is just a "minimalist" set of the base terminal descriptions. -// It should be sufficient for most applications. - -// Package base contains the base terminal descriptions that are likely -// to be needed by any stock application. It is imported by default in the -// terminfo package, so terminal types listed here will be available to any -// tcell application. -package base - -import ( - // The following imports just register themselves -- - // thse are the terminal types we aggregate in this package. - _ "github.com/gdamore/tcell/v2/terminfo/a/ansi" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt100" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt102" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt220" - _ "github.com/gdamore/tcell/v2/terminfo/x/xterm" -) diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/c/cygwin/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/c/cygwin/term.go deleted file mode 100644 index 8877b35..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/c/cygwin/term.go +++ /dev/null @@ -1,64 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package cygwin - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // ANSI emulation for Cygwin - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "cygwin", - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - AttrOff: "\x1b[0;10m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Reverse: "\x1b[7m", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "+\x10,\x11-\x18.\x190\xdb`\x04a\xb1f\xf8g\xf1h\xb0j\xd9k\xbfl\xdam\xc0n\xc5o~p\xc4q\xc4r\xc4s_t\xc3u\xb4v\xc1w\xc2x\xb3y\xf3z\xf2{\xe3|\xd8}\x9c~\xfe", - EnterAcs: "\x1b[11m", - ExitAcs: "\x1b[10m", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\b", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[[A", - KeyF2: "\x1b[[B", - KeyF3: "\x1b[[C", - KeyF4: "\x1b[[D", - KeyF5: "\x1b[[E", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/d/dtterm/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/d/dtterm/term.go deleted file mode 100644 index 83fff47..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/d/dtterm/term.go +++ /dev/null @@ -1,68 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package dtterm - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // CDE desktop terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "dtterm", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\b", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyHelp: "\x1b[28~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/dynamic/dynamic.go b/vendor/github.com/gdamore/tcell/v2/terminfo/dynamic/dynamic.go deleted file mode 100644 index db253ca..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/dynamic/dynamic.go +++ /dev/null @@ -1,447 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// The dynamic package is used to generate a terminal description dynamically, -// using infocmp. This is really a method of last resort, as the performance -// will be slow, and it requires a working infocmp. But, the hope is that it -// will assist folks who have to deal with a terminal description that isn't -// already built in. This requires infocmp to be in the user's path, and to -// support reasonably the -1 option. - -package dynamic - -import ( - "bytes" - "errors" - "os/exec" - "regexp" - "strconv" - "strings" - - "github.com/gdamore/tcell/v2/terminfo" -) - -type termcap struct { - name string - desc string - aliases []string - bools map[string]bool - nums map[string]int - strs map[string]string -} - -func (tc *termcap) getnum(s string) int { - return (tc.nums[s]) -} - -func (tc *termcap) getflag(s string) bool { - return (tc.bools[s]) -} - -func (tc *termcap) getstr(s string) string { - return (tc.strs[s]) -} - -const ( - none = iota - control - escaped -) - -var errNotAddressable = errors.New("terminal not cursor addressable") - -func unescape(s string) string { - // Various escapes are in \x format. Control codes are - // encoded as ^M (carat followed by ASCII equivalent). - // escapes are: \e, \E - escape - // \0 NULL, \n \l \r \t \b \f \s for equivalent C escape. - buf := &bytes.Buffer{} - esc := none - - for i := 0; i < len(s); i++ { - c := s[i] - switch esc { - case none: - switch c { - case '\\': - esc = escaped - case '^': - esc = control - default: - buf.WriteByte(c) - } - case control: - buf.WriteByte(c ^ 1<<6) - esc = none - case escaped: - switch c { - case 'E', 'e': - buf.WriteByte(0x1b) - case '0', '1', '2', '3', '4', '5', '6', '7': - if i+2 < len(s) && s[i+1] >= '0' && s[i+1] <= '7' && s[i+2] >= '0' && s[i+2] <= '7' { - buf.WriteByte(((c - '0') * 64) + ((s[i+1] - '0') * 8) + (s[i+2] - '0')) - i = i + 2 - } else if c == '0' { - buf.WriteByte(0) - } - case 'n': - buf.WriteByte('\n') - case 'r': - buf.WriteByte('\r') - case 't': - buf.WriteByte('\t') - case 'b': - buf.WriteByte('\b') - case 'f': - buf.WriteByte('\f') - case 's': - buf.WriteByte(' ') - default: - buf.WriteByte(c) - } - esc = none - } - } - return (buf.String()) -} - -func (tc *termcap) setupterm(name string) error { - cmd := exec.Command("infocmp", "-1", name) - output := &bytes.Buffer{} - cmd.Stdout = output - - tc.strs = make(map[string]string) - tc.bools = make(map[string]bool) - tc.nums = make(map[string]int) - - if err := cmd.Run(); err != nil { - return err - } - - // Now parse the output. - // We get comment lines (starting with "#"), followed by - // a header line that looks like "||...|" - // then capabilities, one per line, starting with a tab and ending - // with a comma and newline. - lines := strings.Split(output.String(), "\n") - for len(lines) > 0 && strings.HasPrefix(lines[0], "#") { - lines = lines[1:] - } - - // Ditch trailing empty last line - if lines[len(lines)-1] == "" { - lines = lines[:len(lines)-1] - } - header := lines[0] - if strings.HasSuffix(header, ",") { - header = header[:len(header)-1] - } - names := strings.Split(header, "|") - tc.name = names[0] - names = names[1:] - if len(names) > 0 { - tc.desc = names[len(names)-1] - names = names[:len(names)-1] - } - tc.aliases = names - for _, val := range lines[1:] { - if (!strings.HasPrefix(val, "\t")) || - (!strings.HasSuffix(val, ",")) { - return (errors.New("malformed infocmp: " + val)) - } - - val = val[1:] - val = val[:len(val)-1] - - if k := strings.SplitN(val, "=", 2); len(k) == 2 { - tc.strs[k[0]] = unescape(k[1]) - } else if k := strings.SplitN(val, "#", 2); len(k) == 2 { - u, err := strconv.ParseUint(k[1], 0, 0) - if err != nil { - return (err) - } - tc.nums[k[0]] = int(u) - } else { - tc.bools[val] = true - } - } - return nil -} - -// LoadTerminfo creates a Terminfo by for named terminal by attempting to parse -// the output from infocmp. This returns the terminfo entry, a description of -// the terminal, and either nil or an error. -func LoadTerminfo(name string) (*terminfo.Terminfo, string, error) { - var tc termcap - if err := tc.setupterm(name); err != nil { - if err != nil { - return nil, "", err - } - } - t := &terminfo.Terminfo{} - // If this is an alias record, then just emit the alias - t.Name = tc.name - if t.Name != name { - return t, "", nil - } - t.Aliases = tc.aliases - t.Colors = tc.getnum("colors") - t.Columns = tc.getnum("cols") - t.Lines = tc.getnum("lines") - t.Bell = tc.getstr("bel") - t.Clear = tc.getstr("clear") - t.EnterCA = tc.getstr("smcup") - t.ExitCA = tc.getstr("rmcup") - t.ShowCursor = tc.getstr("cnorm") - t.HideCursor = tc.getstr("civis") - t.AttrOff = tc.getstr("sgr0") - t.Underline = tc.getstr("smul") - t.Bold = tc.getstr("bold") - t.Blink = tc.getstr("blink") - t.Dim = tc.getstr("dim") - t.Italic = tc.getstr("sitm") - t.Reverse = tc.getstr("rev") - t.EnterKeypad = tc.getstr("smkx") - t.ExitKeypad = tc.getstr("rmkx") - t.SetFg = tc.getstr("setaf") - t.SetBg = tc.getstr("setab") - t.SetCursor = tc.getstr("cup") - t.CursorBack1 = tc.getstr("cub1") - t.CursorUp1 = tc.getstr("cuu1") - t.KeyF1 = tc.getstr("kf1") - t.KeyF2 = tc.getstr("kf2") - t.KeyF3 = tc.getstr("kf3") - t.KeyF4 = tc.getstr("kf4") - t.KeyF5 = tc.getstr("kf5") - t.KeyF6 = tc.getstr("kf6") - t.KeyF7 = tc.getstr("kf7") - t.KeyF8 = tc.getstr("kf8") - t.KeyF9 = tc.getstr("kf9") - t.KeyF10 = tc.getstr("kf10") - t.KeyF11 = tc.getstr("kf11") - t.KeyF12 = tc.getstr("kf12") - t.KeyF13 = tc.getstr("kf13") - t.KeyF14 = tc.getstr("kf14") - t.KeyF15 = tc.getstr("kf15") - t.KeyF16 = tc.getstr("kf16") - t.KeyF17 = tc.getstr("kf17") - t.KeyF18 = tc.getstr("kf18") - t.KeyF19 = tc.getstr("kf19") - t.KeyF20 = tc.getstr("kf20") - t.KeyF21 = tc.getstr("kf21") - t.KeyF22 = tc.getstr("kf22") - t.KeyF23 = tc.getstr("kf23") - t.KeyF24 = tc.getstr("kf24") - t.KeyF25 = tc.getstr("kf25") - t.KeyF26 = tc.getstr("kf26") - t.KeyF27 = tc.getstr("kf27") - t.KeyF28 = tc.getstr("kf28") - t.KeyF29 = tc.getstr("kf29") - t.KeyF30 = tc.getstr("kf30") - t.KeyF31 = tc.getstr("kf31") - t.KeyF32 = tc.getstr("kf32") - t.KeyF33 = tc.getstr("kf33") - t.KeyF34 = tc.getstr("kf34") - t.KeyF35 = tc.getstr("kf35") - t.KeyF36 = tc.getstr("kf36") - t.KeyF37 = tc.getstr("kf37") - t.KeyF38 = tc.getstr("kf38") - t.KeyF39 = tc.getstr("kf39") - t.KeyF40 = tc.getstr("kf40") - t.KeyF41 = tc.getstr("kf41") - t.KeyF42 = tc.getstr("kf42") - t.KeyF43 = tc.getstr("kf43") - t.KeyF44 = tc.getstr("kf44") - t.KeyF45 = tc.getstr("kf45") - t.KeyF46 = tc.getstr("kf46") - t.KeyF47 = tc.getstr("kf47") - t.KeyF48 = tc.getstr("kf48") - t.KeyF49 = tc.getstr("kf49") - t.KeyF50 = tc.getstr("kf50") - t.KeyF51 = tc.getstr("kf51") - t.KeyF52 = tc.getstr("kf52") - t.KeyF53 = tc.getstr("kf53") - t.KeyF54 = tc.getstr("kf54") - t.KeyF55 = tc.getstr("kf55") - t.KeyF56 = tc.getstr("kf56") - t.KeyF57 = tc.getstr("kf57") - t.KeyF58 = tc.getstr("kf58") - t.KeyF59 = tc.getstr("kf59") - t.KeyF60 = tc.getstr("kf60") - t.KeyF61 = tc.getstr("kf61") - t.KeyF62 = tc.getstr("kf62") - t.KeyF63 = tc.getstr("kf63") - t.KeyF64 = tc.getstr("kf64") - t.KeyInsert = tc.getstr("kich1") - t.KeyDelete = tc.getstr("kdch1") - t.KeyBackspace = tc.getstr("kbs") - t.KeyHome = tc.getstr("khome") - t.KeyEnd = tc.getstr("kend") - t.KeyUp = tc.getstr("kcuu1") - t.KeyDown = tc.getstr("kcud1") - t.KeyRight = tc.getstr("kcuf1") - t.KeyLeft = tc.getstr("kcub1") - t.KeyPgDn = tc.getstr("knp") - t.KeyPgUp = tc.getstr("kpp") - t.KeyBacktab = tc.getstr("kcbt") - t.KeyExit = tc.getstr("kext") - t.KeyCancel = tc.getstr("kcan") - t.KeyPrint = tc.getstr("kprt") - t.KeyHelp = tc.getstr("khlp") - t.KeyClear = tc.getstr("kclr") - t.AltChars = tc.getstr("acsc") - t.EnterAcs = tc.getstr("smacs") - t.ExitAcs = tc.getstr("rmacs") - t.EnableAcs = tc.getstr("enacs") - t.Mouse = tc.getstr("kmous") - t.KeyShfRight = tc.getstr("kRIT") - t.KeyShfLeft = tc.getstr("kLFT") - t.KeyShfHome = tc.getstr("kHOM") - t.KeyShfEnd = tc.getstr("kEND") - - // Terminfo lacks descriptions for a bunch of modified keys, - // but modern XTerm and emulators often have them. Let's add them, - // if the shifted right and left arrows are defined. - if t.KeyShfRight == "\x1b[1;2C" && t.KeyShfLeft == "\x1b[1;2D" { - t.KeyShfUp = "\x1b[1;2A" - t.KeyShfDown = "\x1b[1;2B" - t.KeyMetaUp = "\x1b[1;9A" - t.KeyMetaDown = "\x1b[1;9B" - t.KeyMetaRight = "\x1b[1;9C" - t.KeyMetaLeft = "\x1b[1;9D" - t.KeyAltUp = "\x1b[1;3A" - t.KeyAltDown = "\x1b[1;3B" - t.KeyAltRight = "\x1b[1;3C" - t.KeyAltLeft = "\x1b[1;3D" - t.KeyCtrlUp = "\x1b[1;5A" - t.KeyCtrlDown = "\x1b[1;5B" - t.KeyCtrlRight = "\x1b[1;5C" - t.KeyCtrlLeft = "\x1b[1;5D" - t.KeyAltShfUp = "\x1b[1;4A" - t.KeyAltShfDown = "\x1b[1;4B" - t.KeyAltShfRight = "\x1b[1;4C" - t.KeyAltShfLeft = "\x1b[1;4D" - - t.KeyMetaShfUp = "\x1b[1;10A" - t.KeyMetaShfDown = "\x1b[1;10B" - t.KeyMetaShfRight = "\x1b[1;10C" - t.KeyMetaShfLeft = "\x1b[1;10D" - - t.KeyCtrlShfUp = "\x1b[1;6A" - t.KeyCtrlShfDown = "\x1b[1;6B" - t.KeyCtrlShfRight = "\x1b[1;6C" - t.KeyCtrlShfLeft = "\x1b[1;6D" - - t.KeyShfPgUp = "\x1b[5;2~" - t.KeyShfPgDn = "\x1b[6;2~" - } - // And also for Home and End - if t.KeyShfHome == "\x1b[1;2H" && t.KeyShfEnd == "\x1b[1;2F" { - t.KeyCtrlHome = "\x1b[1;5H" - t.KeyCtrlEnd = "\x1b[1;5F" - t.KeyAltHome = "\x1b[1;9H" - t.KeyAltEnd = "\x1b[1;9F" - t.KeyCtrlShfHome = "\x1b[1;6H" - t.KeyCtrlShfEnd = "\x1b[1;6F" - t.KeyAltShfHome = "\x1b[1;4H" - t.KeyAltShfEnd = "\x1b[1;4F" - t.KeyMetaShfHome = "\x1b[1;10H" - t.KeyMetaShfEnd = "\x1b[1;10F" - } - - // And the same thing for rxvt and workalikes (Eterm, aterm, etc.) - // It seems that urxvt at least send escaped as ALT prefix for these, - // although some places seem to indicate a separate ALT key sesquence. - if t.KeyShfRight == "\x1b[c" && t.KeyShfLeft == "\x1b[d" { - t.KeyShfUp = "\x1b[a" - t.KeyShfDown = "\x1b[b" - t.KeyCtrlUp = "\x1b[Oa" - t.KeyCtrlDown = "\x1b[Ob" - t.KeyCtrlRight = "\x1b[Oc" - t.KeyCtrlLeft = "\x1b[Od" - } - if t.KeyShfHome == "\x1b[7$" && t.KeyShfEnd == "\x1b[8$" { - t.KeyCtrlHome = "\x1b[7^" - t.KeyCtrlEnd = "\x1b[8^" - } - - // Technically the RGB flag that is provided for xterm-direct is not - // quite right. The problem is that the -direct flag that was introduced - // with ncurses 6.1 requires a parsing for the parameters that we lack. - // For this case we'll just assume it's XTerm compatible. Someday this - // may be incorrect, but right now it is correct, and nobody uses it - // anyway. - if tc.getflag("Tc") { - // This presumes XTerm 24-bit true color. - t.TrueColor = true - } else if tc.getflag("RGB") { - // This is for xterm-direct, which uses a different scheme entirely. - // (ncurses went a very different direction from everyone else, and - // so it's unlikely anything is using this definition.) - t.TrueColor = true - t.SetBg = "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m" - t.SetFg = "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m" - } - - // If the kmous entry is present, then we need to record the - // the codes to enter and exit mouse mode. Sadly, this is not - // part of the terminfo databases anywhere that I've found, but - // is an extension. The escapedape codes are documented in the XTerm - // manual, and all terminals that have kmous are expected to - // use these same codes, unless explicitly configured otherwise - // vi XM. Note that in any event, we only known how to parse either - // x11 or SGR mouse events -- if your terminal doesn't support one - // of these two forms, you maybe out of luck. - t.MouseMode = tc.getstr("XM") - if t.Mouse != "" && t.MouseMode == "" { - // we anticipate that all xterm mouse tracking compatible - // terminals understand mouse tracking (1000), but we hope - // that those that don't understand any-event tracking (1003) - // will at least ignore it. Likewise we hope that terminals - // that don't understand SGR reporting (1006) just ignore it. - t.MouseMode = "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;" + - "\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c" - } - - // We only support colors in ANSI 8 or 256 color mode. - if t.Colors < 8 || t.SetFg == "" { - t.Colors = 0 - } - if t.SetCursor == "" { - return nil, "", errNotAddressable - } - - // For padding, we lookup the pad char. If that isn't present, - // and npc is *not* set, then we assume a null byte. - t.PadChar = tc.getstr("pad") - if t.PadChar == "" { - if !tc.getflag("npc") { - t.PadChar = "\u0000" - } - } - - // For terminals that use "standard" SGR sequences, lets combine the - // foreground and background together. - if strings.HasPrefix(t.SetFg, "\x1b[") && - strings.HasPrefix(t.SetBg, "\x1b[") && - strings.HasSuffix(t.SetFg, "m") && - strings.HasSuffix(t.SetBg, "m") { - fg := t.SetFg[:len(t.SetFg)-1] - r := regexp.MustCompile("%p1") - bg := r.ReplaceAllString(t.SetBg[2:], "%p2") - t.SetFgBg = fg + ";" + bg - } - - return t, tc.desc, nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/e/emacs/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/e/emacs/term.go deleted file mode 100644 index e5a41fb..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/e/emacs/term.go +++ /dev/null @@ -1,61 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package emacs - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // gnu emacs term.el terminal emulation - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "eterm", - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - AttrOff: "\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Reverse: "\x1b[7m", - PadChar: "\x00", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - }) - - // Emacs term.el terminal emulator term-protocol-version 0.96 - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "eterm-color", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - AttrOff: "\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - SetFg: "\x1b[%p1%{30}%+%dm", - SetBg: "\x1b[%p1%'('%+%dm", - SetFgBg: "\x1b[%p1%{30}%+%d;%p2%'('%+%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/extended/extended.go b/vendor/github.com/gdamore/tcell/v2/terminfo/extended/extended.go deleted file mode 100644 index 14e6bf1..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/extended/extended.go +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Package extended contains an extended set of terminal descriptions. -// Applications desiring to have a better chance of Just Working by -// default should include this package. This will significantly increase -// the size of the program. -package extended - -import ( - // The following imports just register themselves -- - // these are the terminal types we aggregate in this package. - _ "github.com/gdamore/tcell/v2/terminfo/a/aixterm" - _ "github.com/gdamore/tcell/v2/terminfo/a/alacritty" - _ "github.com/gdamore/tcell/v2/terminfo/a/ansi" - _ "github.com/gdamore/tcell/v2/terminfo/b/beterm" - _ "github.com/gdamore/tcell/v2/terminfo/c/cygwin" - _ "github.com/gdamore/tcell/v2/terminfo/d/dtterm" - _ "github.com/gdamore/tcell/v2/terminfo/e/emacs" - _ "github.com/gdamore/tcell/v2/terminfo/g/gnome" - _ "github.com/gdamore/tcell/v2/terminfo/h/hpterm" - _ "github.com/gdamore/tcell/v2/terminfo/k/konsole" - _ "github.com/gdamore/tcell/v2/terminfo/k/kterm" - _ "github.com/gdamore/tcell/v2/terminfo/l/linux" - _ "github.com/gdamore/tcell/v2/terminfo/p/pcansi" - _ "github.com/gdamore/tcell/v2/terminfo/r/rxvt" - _ "github.com/gdamore/tcell/v2/terminfo/s/screen" - _ "github.com/gdamore/tcell/v2/terminfo/s/simpleterm" - _ "github.com/gdamore/tcell/v2/terminfo/s/sun" - _ "github.com/gdamore/tcell/v2/terminfo/t/termite" - _ "github.com/gdamore/tcell/v2/terminfo/t/tmux" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt100" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt102" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt220" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt320" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt400" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt420" - _ "github.com/gdamore/tcell/v2/terminfo/v/vt52" - _ "github.com/gdamore/tcell/v2/terminfo/w/wy50" - _ "github.com/gdamore/tcell/v2/terminfo/w/wy60" - _ "github.com/gdamore/tcell/v2/terminfo/w/wy99_ansi" - _ "github.com/gdamore/tcell/v2/terminfo/x/xfce" - _ "github.com/gdamore/tcell/v2/terminfo/x/xterm" - _ "github.com/gdamore/tcell/v2/terminfo/x/xterm_kitty" - _ "github.com/gdamore/tcell/v2/terminfo/x/xterm_termite" -) diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/g/gnome/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/g/gnome/term.go deleted file mode 100644 index 1e976c7..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/g/gnome/term.go +++ /dev/null @@ -1,130 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package gnome - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // GNOME Terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "gnome", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[0m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) - - // GNOME Terminal with xterm 256-colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "gnome-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[0m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/gen.sh b/vendor/github.com/gdamore/tcell/v2/terminfo/gen.sh deleted file mode 100644 index 2fc0611..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/gen.sh +++ /dev/null @@ -1,18 +0,0 @@ -while read line -do - case "$line" in - *'|'*) - alias=${line#*|} - line=${line%|*} - ;; - *) - alias=${line%%,*} - ;; - esac - - alias=${alias//-/_} - direc=${alias:0:1} - - mkdir -p ${direc}/${alias} - go run mkinfo.go -P ${alias} -go ${direc}/${alias}/term.go ${line//,/ } -done < models.txt diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/h/hpterm/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/h/hpterm/term.go deleted file mode 100644 index 01135c9..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/h/hpterm/term.go +++ /dev/null @@ -1,50 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package hpterm - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // hp X11 terminal emulator - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "hpterm", - Aliases: []string{"X-hpterm"}, - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b&a0y0C\x1bJ", - AttrOff: "\x1b&d@\x0f", - Underline: "\x1b&dD", - Bold: "\x1b&dB", - Dim: "\x1b&dH", - Reverse: "\x1b&dB", - EnterKeypad: "\x1b&s1A", - ExitKeypad: "\x1b&s0A", - PadChar: "\x00", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - SetCursor: "\x1b&a%p1%dy%p2%dC", - CursorBack1: "\b", - CursorUp1: "\x1bA", - KeyUp: "\x1bA", - KeyDown: "\x1bB", - KeyRight: "\x1bC", - KeyLeft: "\x1bD", - KeyInsert: "\x1bQ", - KeyDelete: "\x1bP", - KeyBackspace: "\b", - KeyHome: "\x1bh", - KeyPgUp: "\x1bV", - KeyPgDn: "\x1bU", - KeyF1: "\x1bp", - KeyF2: "\x1bq", - KeyF3: "\x1br", - KeyF4: "\x1bs", - KeyF5: "\x1bt", - KeyF6: "\x1bu", - KeyF7: "\x1bv", - KeyF8: "\x1bw", - KeyClear: "\x1bJ", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/k/konsole/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/k/konsole/term.go deleted file mode 100644 index dbd739d..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/k/konsole/term.go +++ /dev/null @@ -1,130 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package konsole - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // KDE console window - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "konsole", - Columns: 80, - Lines: 24, - Colors: 8, - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[0m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[<", - MouseMode: "\x1b[?1006;1000%?%p1%{1}%=%th%el%;", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) - - // KDE console window with xterm 256-colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "konsole-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[0m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[<", - MouseMode: "\x1b[?1006;1000%?%p1%{1}%=%th%el%;", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/k/kterm/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/k/kterm/term.go deleted file mode 100644 index e0eb0c8..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/k/kterm/term.go +++ /dev/null @@ -1,68 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package kterm - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // kterm kanji terminal emulator (X window system) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "kterm", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - AttrOff: "\x1b[m\x1b(B", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aajjkkllmmnnooppqqrrssttuuvvwwxx~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/l/linux/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/l/linux/term.go deleted file mode 100644 index 29875a3..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/l/linux/term.go +++ /dev/null @@ -1,70 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package linux - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // linux console - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "linux", - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - ShowCursor: "\x1b[?25h\x1b[?0c", - HideCursor: "\x1b[?25l\x1b[?1c", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "++,,--..00__``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}c~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[[A", - KeyF2: "\x1b[[B", - KeyF3: "\x1b[[C", - KeyF4: "\x1b[[D", - KeyF5: "\x1b[[E", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyBacktab: "\x1b[Z", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/mkinfo.go b/vendor/github.com/gdamore/tcell/v2/terminfo/mkinfo.go deleted file mode 100644 index 7d683d4..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/mkinfo.go +++ /dev/null @@ -1,717 +0,0 @@ -// +build ignore - -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// This command is used to generate suitable configuration files in either -// go syntax or in JSON. It defaults to JSON output on stdout. If no -// term values are specified on the command line, then $TERM is used. -// -// Usage is like this: -// -// mkinfo [-go file.go] [-quiet] [-nofatal] [-I ] [-P ...] -// -// -go specifies Go output into the named file. Use - for stdout. -// -nofatal indicates that errors loading definitions should not be fatal -// -P pkg use the supplied package name -// -I import use the named import instead of github.com/gdamore/tcell/v2/terminfo -// - -package main - -import ( - "bytes" - "errors" - "flag" - "fmt" - "io" - "os" - "os/exec" - "regexp" - "strconv" - "strings" - - "github.com/gdamore/tcell/v2/terminfo" -) - -type termcap struct { - name string - desc string - aliases []string - bools map[string]bool - nums map[string]int - strs map[string]string -} - -func (tc *termcap) getnum(s string) int { - return (tc.nums[s]) -} - -func (tc *termcap) getflag(s string) bool { - return (tc.bools[s]) -} - -func (tc *termcap) getstr(s string) string { - return (tc.strs[s]) -} - -const ( - NONE = iota - CTRL - ESC -) - -var notaddressable = errors.New("terminal not cursor addressable") - -func unescape(s string) string { - // Various escapes are in \x format. Control codes are - // encoded as ^M (carat followed by ASCII equivalent). - // Escapes are: \e, \E - escape - // \0 NULL, \n \l \r \t \b \f \s for equivalent C escape. - buf := &bytes.Buffer{} - esc := NONE - - for i := 0; i < len(s); i++ { - c := s[i] - switch esc { - case NONE: - switch c { - case '\\': - esc = ESC - case '^': - esc = CTRL - default: - buf.WriteByte(c) - } - case CTRL: - buf.WriteByte(c ^ 1<<6) - esc = NONE - case ESC: - switch c { - case 'E', 'e': - buf.WriteByte(0x1b) - case '0', '1', '2', '3', '4', '5', '6', '7': - if i+2 < len(s) && s[i+1] >= '0' && s[i+1] <= '7' && s[i+2] >= '0' && s[i+2] <= '7' { - buf.WriteByte(((c - '0') * 64) + ((s[i+1] - '0') * 8) + (s[i+2] - '0')) - i = i + 2 - } else if c == '0' { - buf.WriteByte(0) - } - case 'n': - buf.WriteByte('\n') - case 'r': - buf.WriteByte('\r') - case 't': - buf.WriteByte('\t') - case 'b': - buf.WriteByte('\b') - case 'f': - buf.WriteByte('\f') - case 's': - buf.WriteByte(' ') - case 'l': - panic("WTF: weird format: " + s) - default: - buf.WriteByte(c) - } - esc = NONE - } - } - return (buf.String()) -} - -func (tc *termcap) setupterm(name string) error { - cmd := exec.Command("infocmp", "-x", "-1", name) - output := &bytes.Buffer{} - cmd.Stdout = output - - tc.strs = make(map[string]string) - tc.bools = make(map[string]bool) - tc.nums = make(map[string]int) - - err := cmd.Run() - if err != nil { - return err - } - - // Now parse the output. - // We get comment lines (starting with "#"), followed by - // a header line that looks like "||...|" - // then capabilities, one per line, starting with a tab and ending - // with a comma and newline. - lines := strings.Split(output.String(), "\n") - for len(lines) > 0 && strings.HasPrefix(lines[0], "#") { - lines = lines[1:] - } - - // Ditch trailing empty last line - if lines[len(lines)-1] == "" { - lines = lines[:len(lines)-1] - } - header := lines[0] - if strings.HasSuffix(header, ",") { - header = header[:len(header)-1] - } - names := strings.Split(header, "|") - tc.name = names[0] - names = names[1:] - if len(names) > 0 { - tc.desc = names[len(names)-1] - names = names[:len(names)-1] - } - tc.aliases = names - for _, val := range lines[1:] { - if (!strings.HasPrefix(val, "\t")) || - (!strings.HasSuffix(val, ",")) { - return (errors.New("malformed infocmp: " + val)) - } - - val = val[1:] - val = val[:len(val)-1] - - if k := strings.SplitN(val, "=", 2); len(k) == 2 { - tc.strs[k[0]] = unescape(k[1]) - } else if k := strings.SplitN(val, "#", 2); len(k) == 2 { - if u, err := strconv.ParseUint(k[1], 0, 0); err != nil { - return (err) - } else { - tc.nums[k[0]] = int(u) - } - } else { - tc.bools[val] = true - } - } - return nil -} - -// This program is used to collect data from the system's terminfo library, -// and write it into Go source code. That is, we maintain our terminfo -// capabilities encoded in the program. It should never need to be run by -// an end user, but developers can use this to add codes for additional -// terminal types. -func getinfo(name string) (*terminfo.Terminfo, string, error) { - var tc termcap - if err := tc.setupterm(name); err != nil { - if err != nil { - return nil, "", err - } - } - t := &terminfo.Terminfo{} - // If this is an alias record, then just emit the alias - t.Name = tc.name - if t.Name != name { - return t, "", nil - } - t.Aliases = tc.aliases - t.Colors = tc.getnum("colors") - t.Columns = tc.getnum("cols") - t.Lines = tc.getnum("lines") - t.Bell = tc.getstr("bel") - t.Clear = tc.getstr("clear") - t.EnterCA = tc.getstr("smcup") - t.ExitCA = tc.getstr("rmcup") - t.ShowCursor = tc.getstr("cnorm") - t.HideCursor = tc.getstr("civis") - t.AttrOff = tc.getstr("sgr0") - t.Underline = tc.getstr("smul") - t.Bold = tc.getstr("bold") - t.Blink = tc.getstr("blink") - t.Dim = tc.getstr("dim") - t.Italic = tc.getstr("sitm") - t.Reverse = tc.getstr("rev") - t.EnterKeypad = tc.getstr("smkx") - t.ExitKeypad = tc.getstr("rmkx") - t.SetFg = tc.getstr("setaf") - t.SetBg = tc.getstr("setab") - t.ResetFgBg = tc.getstr("op") - t.SetCursor = tc.getstr("cup") - t.CursorBack1 = tc.getstr("cub1") - t.CursorUp1 = tc.getstr("cuu1") - t.KeyF1 = tc.getstr("kf1") - t.KeyF2 = tc.getstr("kf2") - t.KeyF3 = tc.getstr("kf3") - t.KeyF4 = tc.getstr("kf4") - t.KeyF5 = tc.getstr("kf5") - t.KeyF6 = tc.getstr("kf6") - t.KeyF7 = tc.getstr("kf7") - t.KeyF8 = tc.getstr("kf8") - t.KeyF9 = tc.getstr("kf9") - t.KeyF10 = tc.getstr("kf10") - t.KeyF11 = tc.getstr("kf11") - t.KeyF12 = tc.getstr("kf12") - t.KeyInsert = tc.getstr("kich1") - t.KeyDelete = tc.getstr("kdch1") - t.KeyBackspace = tc.getstr("kbs") - t.KeyHome = tc.getstr("khome") - t.KeyEnd = tc.getstr("kend") - t.KeyUp = tc.getstr("kcuu1") - t.KeyDown = tc.getstr("kcud1") - t.KeyRight = tc.getstr("kcuf1") - t.KeyLeft = tc.getstr("kcub1") - t.KeyPgDn = tc.getstr("knp") - t.KeyPgUp = tc.getstr("kpp") - t.KeyBacktab = tc.getstr("kcbt") - t.KeyExit = tc.getstr("kext") - t.KeyCancel = tc.getstr("kcan") - t.KeyPrint = tc.getstr("kprt") - t.KeyHelp = tc.getstr("khlp") - t.KeyClear = tc.getstr("kclr") - t.AltChars = tc.getstr("acsc") - t.EnterAcs = tc.getstr("smacs") - t.ExitAcs = tc.getstr("rmacs") - t.EnableAcs = tc.getstr("enacs") - t.StrikeThrough = tc.getstr("smxx") - t.Mouse = tc.getstr("kmous") - - t.Modifiers = terminfo.ModifiersNone - - // Terminfo lacks descriptions for a bunch of modified keys, - // but modern XTerm and emulators often have them. We detect - // this based on compatible definitions for shifted right. - // We also choose to use our modifiers for function keys -- - // the terminfo entries list these all as higher coded escape - // keys, but it's nicer to match them to modifiers. - if tc.getstr("kRIT") == "\x1b[1;2C" { - t.Modifiers = terminfo.ModifiersXTerm - } else { - // Lookup high level function keys. - t.KeyShfInsert = tc.getstr("kIC") - t.KeyShfDelete = tc.getstr("kDC") - t.KeyShfRight = tc.getstr("kRIT") - t.KeyShfLeft = tc.getstr("kLFT") - t.KeyShfHome = tc.getstr("kHOM") - t.KeyShfEnd = tc.getstr("kEND") - t.KeyF13 = tc.getstr("kf13") - t.KeyF14 = tc.getstr("kf14") - t.KeyF15 = tc.getstr("kf15") - t.KeyF16 = tc.getstr("kf16") - t.KeyF17 = tc.getstr("kf17") - t.KeyF18 = tc.getstr("kf18") - t.KeyF19 = tc.getstr("kf19") - t.KeyF20 = tc.getstr("kf20") - t.KeyF21 = tc.getstr("kf21") - t.KeyF22 = tc.getstr("kf22") - t.KeyF23 = tc.getstr("kf23") - t.KeyF24 = tc.getstr("kf24") - t.KeyF25 = tc.getstr("kf25") - t.KeyF26 = tc.getstr("kf26") - t.KeyF27 = tc.getstr("kf27") - t.KeyF28 = tc.getstr("kf28") - t.KeyF29 = tc.getstr("kf29") - t.KeyF30 = tc.getstr("kf30") - t.KeyF31 = tc.getstr("kf31") - t.KeyF32 = tc.getstr("kf32") - t.KeyF33 = tc.getstr("kf33") - t.KeyF34 = tc.getstr("kf34") - t.KeyF35 = tc.getstr("kf35") - t.KeyF36 = tc.getstr("kf36") - t.KeyF37 = tc.getstr("kf37") - t.KeyF38 = tc.getstr("kf38") - t.KeyF39 = tc.getstr("kf39") - t.KeyF40 = tc.getstr("kf40") - t.KeyF41 = tc.getstr("kf41") - t.KeyF42 = tc.getstr("kf42") - t.KeyF43 = tc.getstr("kf43") - t.KeyF44 = tc.getstr("kf44") - t.KeyF45 = tc.getstr("kf45") - t.KeyF46 = tc.getstr("kf46") - t.KeyF47 = tc.getstr("kf47") - t.KeyF48 = tc.getstr("kf48") - t.KeyF49 = tc.getstr("kf49") - t.KeyF50 = tc.getstr("kf50") - t.KeyF51 = tc.getstr("kf51") - t.KeyF52 = tc.getstr("kf52") - t.KeyF53 = tc.getstr("kf53") - t.KeyF54 = tc.getstr("kf54") - t.KeyF55 = tc.getstr("kf55") - t.KeyF56 = tc.getstr("kf56") - t.KeyF57 = tc.getstr("kf57") - t.KeyF58 = tc.getstr("kf58") - t.KeyF59 = tc.getstr("kf59") - t.KeyF60 = tc.getstr("kf60") - t.KeyF61 = tc.getstr("kf61") - t.KeyF62 = tc.getstr("kf62") - t.KeyF63 = tc.getstr("kf63") - t.KeyF64 = tc.getstr("kf64") - } - - // And the same thing for rxvt. - // It seems that urxvt at least send ESC as ALT prefix for these, - // although some places seem to indicate a separate ALT key sequence. - // Users are encouraged to update to an emulator that more closely - // matches xterm for better functionality. - if t.KeyShfRight == "\x1b[c" && t.KeyShfLeft == "\x1b[d" { - t.KeyShfUp = "\x1b[a" - t.KeyShfDown = "\x1b[b" - t.KeyCtrlUp = "\x1b[Oa" - t.KeyCtrlDown = "\x1b[Ob" - t.KeyCtrlRight = "\x1b[Oc" - t.KeyCtrlLeft = "\x1b[Od" - } - if t.KeyShfHome == "\x1b[7$" && t.KeyShfEnd == "\x1b[8$" { - t.KeyCtrlHome = "\x1b[7^" - t.KeyCtrlEnd = "\x1b[8^" - } - - // Technically the RGB flag that is provided for xterm-direct is not - // quite right. The problem is that the -direct flag that was introduced - // with ncurses 6.1 requires a parsing for the parameters that we lack. - // For this case we'll just assume it's XTerm compatible. Someday this - // may be incorrect, but right now it is correct, and nobody uses it - // anyway. - if tc.getflag("Tc") { - // This presumes XTerm 24-bit true color. - t.TrueColor = true - } else if tc.getflag("RGB") { - // This is for xterm-direct, which uses a different scheme entirely. - // (ncurses went a very different direction from everyone else, and - // so it's unlikely anything is using this definition.) - t.TrueColor = true - t.SetBg = "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m" - t.SetFg = "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m" - } - - // If the kmous entry is present, then we need to record the - // the codes to enter and exit mouse mode. Sadly, this is not - // part of the terminfo databases anywhere that I've found, but - // is an extension. The escape codes are documented in the XTerm - // manual, and all terminals that have kmous are expected to - // use these same codes, unless explicitly configured otherwise - // vi XM. Note that in any event, we only known how to parse either - // x11 or SGR mouse events -- if your terminal doesn't support one - // of these two forms, you maybe out of luck. - t.MouseMode = tc.getstr("XM") - if t.Mouse != "" && t.MouseMode == "" { - // we anticipate that all xterm mouse tracking compatible - // terminals understand mouse tracking (1000), but we hope - // that those that don't understand any-event tracking (1003) - // will at least ignore it. Likewise we hope that terminals - // that don't understand SGR reporting (1006) just ignore it. - t.MouseMode = "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;" + - "\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c" - } - - // We only support colors in ANSI 8 or 256 color mode. - if t.Colors < 8 || t.SetFg == "" { - t.Colors = 0 - } - if t.SetCursor == "" { - return nil, "", notaddressable - } - - // For padding, we lookup the pad char. If that isn't present, - // and npc is *not* set, then we assume a null byte. - t.PadChar = tc.getstr("pad") - if t.PadChar == "" { - if !tc.getflag("npc") { - t.PadChar = "\u0000" - } - } - - // For terminals that use "standard" SGR sequences, lets combine the - // foreground and background together. - if strings.HasPrefix(t.SetFg, "\x1b[") && - strings.HasPrefix(t.SetBg, "\x1b[") && - strings.HasSuffix(t.SetFg, "m") && - strings.HasSuffix(t.SetBg, "m") { - fg := t.SetFg[:len(t.SetFg)-1] - r := regexp.MustCompile("%p1") - bg := r.ReplaceAllString(t.SetBg[2:], "%p2") - t.SetFgBg = fg + ";" + bg - } - - return t, tc.desc, nil -} - -func dotGoAddInt(w io.Writer, n string, i int) { - if i == 0 { - // initialized to 0, ignore - return - } - fmt.Fprintf(w, "\t\t%-13s %d,\n", n+":", i) -} -func dotGoAddStr(w io.Writer, n string, s string) { - if s == "" { - return - } - fmt.Fprintf(w, "\t\t%-13s %q,\n", n+":", s) -} -func dotGoAddFlag(w io.Writer, n string, b bool) { - if !b { - // initialized to 0, ignore - return - } - fmt.Fprintf(w, "\t\t%-13s true,\n", n+":") -} - -func dotGoAddArr(w io.Writer, n string, a []string) { - if len(a) == 0 { - return - } - fmt.Fprintf(w, "\t\t%-13s []string{", n+":") - did := false - for _, b := range a { - if did { - fmt.Fprint(w, ", ") - } - did = true - fmt.Fprintf(w, "%q", b) - } - fmt.Fprintln(w, "},") -} - -func dotGoHeader(w io.Writer, packname, tipackname string) { - fmt.Fprintln(w, "// Generated automatically. DO NOT HAND-EDIT.") - fmt.Fprintln(w, "") - fmt.Fprintf(w, "package %s\n", packname) - fmt.Fprintln(w, "") - fmt.Fprintf(w, "import \"%s\"\n", tipackname) - fmt.Fprintln(w, "") -} - -func dotGoTrailer(w io.Writer) { -} - -func dotGoInfo(w io.Writer, terms []*TData) { - - fmt.Fprintln(w, "func init() {") - for _, t := range terms { - fmt.Fprintf(w, "\n\t// %s\n", t.Desc) - fmt.Fprintln(w, "\tterminfo.AddTerminfo(&terminfo.Terminfo{") - dotGoAddStr(w, "Name", t.Name) - dotGoAddArr(w, "Aliases", t.Aliases) - dotGoAddInt(w, "Columns", t.Columns) - dotGoAddInt(w, "Lines", t.Lines) - dotGoAddInt(w, "Colors", t.Colors) - dotGoAddStr(w, "Bell", t.Bell) - dotGoAddStr(w, "Clear", t.Clear) - dotGoAddStr(w, "EnterCA", t.EnterCA) - dotGoAddStr(w, "ExitCA", t.ExitCA) - dotGoAddStr(w, "ShowCursor", t.ShowCursor) - dotGoAddStr(w, "HideCursor", t.HideCursor) - dotGoAddStr(w, "AttrOff", t.AttrOff) - dotGoAddStr(w, "Underline", t.Underline) - dotGoAddStr(w, "Bold", t.Bold) - dotGoAddStr(w, "Dim", t.Dim) - dotGoAddStr(w, "Italic", t.Italic) - dotGoAddStr(w, "Blink", t.Blink) - dotGoAddStr(w, "Reverse", t.Reverse) - dotGoAddStr(w, "EnterKeypad", t.EnterKeypad) - dotGoAddStr(w, "ExitKeypad", t.ExitKeypad) - dotGoAddStr(w, "SetFg", t.SetFg) - dotGoAddStr(w, "SetBg", t.SetBg) - dotGoAddStr(w, "SetFgBg", t.SetFgBg) - dotGoAddStr(w, "ResetFgBg", t.ResetFgBg) - dotGoAddStr(w, "PadChar", t.PadChar) - dotGoAddStr(w, "AltChars", t.AltChars) - dotGoAddStr(w, "EnterAcs", t.EnterAcs) - dotGoAddStr(w, "ExitAcs", t.ExitAcs) - dotGoAddStr(w, "EnableAcs", t.EnableAcs) - dotGoAddStr(w, "SetFgRGB", t.SetFgRGB) - dotGoAddStr(w, "SetBgRGB", t.SetBgRGB) - dotGoAddStr(w, "SetFgBgRGB", t.SetFgBgRGB) - dotGoAddStr(w, "StrikeThrough", t.StrikeThrough) - dotGoAddStr(w, "Mouse", t.Mouse) - dotGoAddStr(w, "MouseMode", t.MouseMode) - dotGoAddStr(w, "SetCursor", t.SetCursor) - dotGoAddStr(w, "CursorBack1", t.CursorBack1) - dotGoAddStr(w, "CursorUp1", t.CursorUp1) - dotGoAddStr(w, "KeyUp", t.KeyUp) - dotGoAddStr(w, "KeyDown", t.KeyDown) - dotGoAddStr(w, "KeyRight", t.KeyRight) - dotGoAddStr(w, "KeyLeft", t.KeyLeft) - dotGoAddStr(w, "KeyInsert", t.KeyInsert) - dotGoAddStr(w, "KeyDelete", t.KeyDelete) - dotGoAddStr(w, "KeyBackspace", t.KeyBackspace) - dotGoAddStr(w, "KeyHome", t.KeyHome) - dotGoAddStr(w, "KeyEnd", t.KeyEnd) - dotGoAddStr(w, "KeyPgUp", t.KeyPgUp) - dotGoAddStr(w, "KeyPgDn", t.KeyPgDn) - dotGoAddStr(w, "KeyF1", t.KeyF1) - dotGoAddStr(w, "KeyF2", t.KeyF2) - dotGoAddStr(w, "KeyF3", t.KeyF3) - dotGoAddStr(w, "KeyF4", t.KeyF4) - dotGoAddStr(w, "KeyF5", t.KeyF5) - dotGoAddStr(w, "KeyF6", t.KeyF6) - dotGoAddStr(w, "KeyF7", t.KeyF7) - dotGoAddStr(w, "KeyF8", t.KeyF8) - dotGoAddStr(w, "KeyF9", t.KeyF9) - dotGoAddStr(w, "KeyF10", t.KeyF10) - dotGoAddStr(w, "KeyF11", t.KeyF11) - dotGoAddStr(w, "KeyF12", t.KeyF12) - // Extended keys. We don't report these if they are going to be - // handled as if they were XTerm sequences. - dotGoAddStr(w, "KeyF13", t.KeyF13) - dotGoAddStr(w, "KeyF14", t.KeyF14) - dotGoAddStr(w, "KeyF15", t.KeyF15) - dotGoAddStr(w, "KeyF16", t.KeyF16) - dotGoAddStr(w, "KeyF17", t.KeyF17) - dotGoAddStr(w, "KeyF18", t.KeyF18) - dotGoAddStr(w, "KeyF19", t.KeyF19) - dotGoAddStr(w, "KeyF20", t.KeyF20) - dotGoAddStr(w, "KeyF21", t.KeyF21) - dotGoAddStr(w, "KeyF22", t.KeyF22) - dotGoAddStr(w, "KeyF23", t.KeyF23) - dotGoAddStr(w, "KeyF24", t.KeyF24) - dotGoAddStr(w, "KeyF25", t.KeyF25) - dotGoAddStr(w, "KeyF26", t.KeyF26) - dotGoAddStr(w, "KeyF27", t.KeyF27) - dotGoAddStr(w, "KeyF28", t.KeyF28) - dotGoAddStr(w, "KeyF29", t.KeyF29) - dotGoAddStr(w, "KeyF30", t.KeyF30) - dotGoAddStr(w, "KeyF31", t.KeyF31) - dotGoAddStr(w, "KeyF32", t.KeyF32) - dotGoAddStr(w, "KeyF33", t.KeyF33) - dotGoAddStr(w, "KeyF34", t.KeyF34) - dotGoAddStr(w, "KeyF35", t.KeyF35) - dotGoAddStr(w, "KeyF36", t.KeyF36) - dotGoAddStr(w, "KeyF37", t.KeyF37) - dotGoAddStr(w, "KeyF38", t.KeyF38) - dotGoAddStr(w, "KeyF39", t.KeyF39) - dotGoAddStr(w, "KeyF40", t.KeyF40) - dotGoAddStr(w, "KeyF41", t.KeyF41) - dotGoAddStr(w, "KeyF42", t.KeyF42) - dotGoAddStr(w, "KeyF43", t.KeyF43) - dotGoAddStr(w, "KeyF44", t.KeyF44) - dotGoAddStr(w, "KeyF45", t.KeyF45) - dotGoAddStr(w, "KeyF46", t.KeyF46) - dotGoAddStr(w, "KeyF47", t.KeyF47) - dotGoAddStr(w, "KeyF48", t.KeyF48) - dotGoAddStr(w, "KeyF49", t.KeyF49) - dotGoAddStr(w, "KeyF50", t.KeyF50) - dotGoAddStr(w, "KeyF51", t.KeyF51) - dotGoAddStr(w, "KeyF52", t.KeyF52) - dotGoAddStr(w, "KeyF53", t.KeyF53) - dotGoAddStr(w, "KeyF54", t.KeyF54) - dotGoAddStr(w, "KeyF55", t.KeyF55) - dotGoAddStr(w, "KeyF56", t.KeyF56) - dotGoAddStr(w, "KeyF57", t.KeyF57) - dotGoAddStr(w, "KeyF58", t.KeyF58) - dotGoAddStr(w, "KeyF59", t.KeyF59) - dotGoAddStr(w, "KeyF60", t.KeyF60) - dotGoAddStr(w, "KeyF61", t.KeyF61) - dotGoAddStr(w, "KeyF62", t.KeyF62) - dotGoAddStr(w, "KeyF63", t.KeyF63) - dotGoAddStr(w, "KeyF64", t.KeyF64) - dotGoAddStr(w, "KeyCancel", t.KeyCancel) - dotGoAddStr(w, "KeyPrint", t.KeyPrint) - dotGoAddStr(w, "KeyExit", t.KeyExit) - dotGoAddStr(w, "KeyHelp", t.KeyHelp) - dotGoAddStr(w, "KeyClear", t.KeyClear) - dotGoAddStr(w, "KeyBacktab", t.KeyBacktab) - dotGoAddStr(w, "KeyShfLeft", t.KeyShfLeft) - dotGoAddStr(w, "KeyShfRight", t.KeyShfRight) - dotGoAddStr(w, "KeyShfUp", t.KeyShfUp) - dotGoAddStr(w, "KeyShfDown", t.KeyShfDown) - dotGoAddStr(w, "KeyShfHome", t.KeyShfHome) - dotGoAddStr(w, "KeyShfEnd", t.KeyShfEnd) - dotGoAddStr(w, "KeyShfInsert", t.KeyShfInsert) - dotGoAddStr(w, "KeyShfDelete", t.KeyShfDelete) - dotGoAddStr(w, "KeyCtrlUp", t.KeyCtrlUp) - dotGoAddStr(w, "KeyCtrlDown", t.KeyCtrlDown) - dotGoAddStr(w, "KeyCtrlRight", t.KeyCtrlRight) - dotGoAddStr(w, "KeyCtrlLeft", t.KeyCtrlLeft) - dotGoAddStr(w, "KeyCtrlHome", t.KeyCtrlHome) - dotGoAddStr(w, "KeyCtrlEnd", t.KeyCtrlEnd) - dotGoAddInt(w, "Modifiers", t.Modifiers) - dotGoAddFlag(w, "TrueColor", t.TrueColor) - fmt.Fprintln(w, "\t})") - } - fmt.Fprintln(w, "}") -} - -var packname = "" -var tipackname = "github.com/gdamore/tcell/v2/terminfo" - -func dotGoFile(fname string, terms []*TData) error { - w := os.Stdout - var e error - if fname != "-" && fname != "" { - if w, e = os.Create(fname); e != nil { - return e - } - } - if packname == "" { - packname = strings.Replace(terms[0].Name, "-", "_", -1) - } - dotGoHeader(w, packname, tipackname) - dotGoInfo(w, terms) - dotGoTrailer(w) - if w != os.Stdout { - w.Close() - } - cmd := exec.Command("go", "fmt", fname) - cmd.Run() - return nil -} - -type TData struct { - Desc string - - terminfo.Terminfo -} - -func main() { - gofile := "" - nofatal := false - quiet := false - all := false - - flag.StringVar(&gofile, "go", "", "generate go source in named file") - flag.StringVar(&tipackname, "I", tipackname, "import package path") - flag.StringVar(&packname, "P", packname, "package name (go source)") - flag.BoolVar(&nofatal, "nofatal", false, "errors are not fatal") - flag.BoolVar(&quiet, "quiet", false, "suppress error messages") - flag.BoolVar(&all, "all", false, "load all terminals from terminfo") - flag.Parse() - var e error - - args := flag.Args() - if len(args) == 0 { - args = []string{os.Getenv("TERM")} - } - - tdata := make([]*TData, 0) - - for _, term := range args { - if t, desc, e := getinfo(term); e != nil { - if all && e == notaddressable { - continue - } - if !quiet { - fmt.Fprintf(os.Stderr, - "Failed loading %s: %v\n", term, e) - } - if !nofatal { - os.Exit(1) - } - } else { - tdata = append(tdata, &TData{ - Desc: desc, - Terminfo: *t, - }) - } - } - - if len(tdata) == 0 { - // No data. - os.Exit(0) - } - - e = dotGoFile(gofile, tdata) - if e != nil { - fmt.Fprintf(os.Stderr, "Failed %s: %v", gofile, e) - os.Exit(1) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/models.txt b/vendor/github.com/gdamore/tcell/v2/terminfo/models.txt deleted file mode 100644 index 60905e0..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/models.txt +++ /dev/null @@ -1,32 +0,0 @@ -aixterm -alacritty -ansi -beterm -cygwin -dtterm -eterm,eterm-color|emacs -gnome,gnome-256color -hpterm -konsole,konsole-256color -kterm -linux -pcansi -rxvt,rxvt-256color,rxvt-88color,rxvt-unicode,rxvt-unicode-256color -screen,screen-256color -st,st-256color|simpleterm -sun,sun-color -termite -tmux -vt52 -vt100 -vt102 -vt220 -vt320 -vt400 -vt420 -wy50 -wy60 -wy99-ansi,wy99a-ansi -xfce -xterm,xterm-88color,xterm-256color -xterm-kitty diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/p/pcansi/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/p/pcansi/term.go deleted file mode 100644 index dbde120..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/p/pcansi/term.go +++ /dev/null @@ -1,40 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package pcansi - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // ibm-pc terminal programs claiming to be ansi - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "pcansi", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - AttrOff: "\x1b[0;10m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[37;40m", - PadChar: "\x00", - AltChars: "+\x10,\x11-\x18.\x190\xdb`\x04a\xb1f\xf8g\xf1h\xb0j\xd9k\xbfl\xdam\xc0n\xc5o~p\xc4q\xc4r\xc4s_t\xc3u\xb4v\xc1w\xc2x\xb3y\xf3z\xf2{\xe3|\xd8}\x9c~\xfe", - EnterAcs: "\x1b[12m", - ExitAcs: "\x1b[10m", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\x1b[D", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyBackspace: "\b", - KeyHome: "\x1b[H", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/r/rxvt/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/r/rxvt/term.go deleted file mode 100644 index 820db72..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/r/rxvt/term.go +++ /dev/null @@ -1,480 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package rxvt - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // rxvt terminal emulator (X Window System) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "rxvt", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b=", - ExitKeypad: "\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[7~", - KeyEnd: "\x1b[8~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyF21: "\x1b[23$", - KeyF22: "\x1b[24$", - KeyF23: "\x1b[11^", - KeyF24: "\x1b[12^", - KeyF25: "\x1b[13^", - KeyF26: "\x1b[14^", - KeyF27: "\x1b[15^", - KeyF28: "\x1b[17^", - KeyF29: "\x1b[18^", - KeyF30: "\x1b[19^", - KeyF31: "\x1b[20^", - KeyF32: "\x1b[21^", - KeyF33: "\x1b[23^", - KeyF34: "\x1b[24^", - KeyF35: "\x1b[25^", - KeyF36: "\x1b[26^", - KeyF37: "\x1b[28^", - KeyF38: "\x1b[29^", - KeyF39: "\x1b[31^", - KeyF40: "\x1b[32^", - KeyF41: "\x1b[33^", - KeyF42: "\x1b[34^", - KeyF43: "\x1b[23@", - KeyF44: "\x1b[24@", - KeyBacktab: "\x1b[Z", - KeyShfLeft: "\x1b[d", - KeyShfRight: "\x1b[c", - KeyShfUp: "\x1b[a", - KeyShfDown: "\x1b[b", - KeyShfHome: "\x1b[7$", - KeyShfEnd: "\x1b[8$", - KeyShfDelete: "\x1b[3$", - KeyCtrlUp: "\x1b[Oa", - KeyCtrlDown: "\x1b[Ob", - KeyCtrlRight: "\x1b[Oc", - KeyCtrlLeft: "\x1b[Od", - KeyCtrlHome: "\x1b[7^", - KeyCtrlEnd: "\x1b[8^", - }) - - // rxvt 2.7.9 with xterm 256-colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "rxvt-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b=", - ExitKeypad: "\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[7~", - KeyEnd: "\x1b[8~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyF21: "\x1b[23$", - KeyF22: "\x1b[24$", - KeyF23: "\x1b[11^", - KeyF24: "\x1b[12^", - KeyF25: "\x1b[13^", - KeyF26: "\x1b[14^", - KeyF27: "\x1b[15^", - KeyF28: "\x1b[17^", - KeyF29: "\x1b[18^", - KeyF30: "\x1b[19^", - KeyF31: "\x1b[20^", - KeyF32: "\x1b[21^", - KeyF33: "\x1b[23^", - KeyF34: "\x1b[24^", - KeyF35: "\x1b[25^", - KeyF36: "\x1b[26^", - KeyF37: "\x1b[28^", - KeyF38: "\x1b[29^", - KeyF39: "\x1b[31^", - KeyF40: "\x1b[32^", - KeyF41: "\x1b[33^", - KeyF42: "\x1b[34^", - KeyF43: "\x1b[23@", - KeyF44: "\x1b[24@", - KeyBacktab: "\x1b[Z", - KeyShfLeft: "\x1b[d", - KeyShfRight: "\x1b[c", - KeyShfUp: "\x1b[a", - KeyShfDown: "\x1b[b", - KeyShfHome: "\x1b[7$", - KeyShfEnd: "\x1b[8$", - KeyShfDelete: "\x1b[3$", - KeyCtrlUp: "\x1b[Oa", - KeyCtrlDown: "\x1b[Ob", - KeyCtrlRight: "\x1b[Oc", - KeyCtrlLeft: "\x1b[Od", - KeyCtrlHome: "\x1b[7^", - KeyCtrlEnd: "\x1b[8^", - }) - - // rxvt 2.7.9 with xterm 88-colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "rxvt-88color", - Columns: 80, - Lines: 24, - Colors: 88, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b=", - ExitKeypad: "\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[7~", - KeyEnd: "\x1b[8~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyF21: "\x1b[23$", - KeyF22: "\x1b[24$", - KeyF23: "\x1b[11^", - KeyF24: "\x1b[12^", - KeyF25: "\x1b[13^", - KeyF26: "\x1b[14^", - KeyF27: "\x1b[15^", - KeyF28: "\x1b[17^", - KeyF29: "\x1b[18^", - KeyF30: "\x1b[19^", - KeyF31: "\x1b[20^", - KeyF32: "\x1b[21^", - KeyF33: "\x1b[23^", - KeyF34: "\x1b[24^", - KeyF35: "\x1b[25^", - KeyF36: "\x1b[26^", - KeyF37: "\x1b[28^", - KeyF38: "\x1b[29^", - KeyF39: "\x1b[31^", - KeyF40: "\x1b[32^", - KeyF41: "\x1b[33^", - KeyF42: "\x1b[34^", - KeyF43: "\x1b[23@", - KeyF44: "\x1b[24@", - KeyBacktab: "\x1b[Z", - KeyShfLeft: "\x1b[d", - KeyShfRight: "\x1b[c", - KeyShfUp: "\x1b[a", - KeyShfDown: "\x1b[b", - KeyShfHome: "\x1b[7$", - KeyShfEnd: "\x1b[8$", - KeyShfDelete: "\x1b[3$", - KeyCtrlUp: "\x1b[Oa", - KeyCtrlDown: "\x1b[Ob", - KeyCtrlRight: "\x1b[Oc", - KeyCtrlLeft: "\x1b[Od", - KeyCtrlHome: "\x1b[7^", - KeyCtrlEnd: "\x1b[8^", - }) - - // rxvt-unicode terminal (X Window System) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "rxvt-unicode", - Columns: 80, - Lines: 24, - Colors: 88, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[r\x1b[?1049l", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x1b(B", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b=", - ExitKeypad: "\x1b>", - SetFg: "\x1b[38;5;%p1%dm", - SetBg: "\x1b[48;5;%p1%dm", - SetFgBg: "\x1b[38;5;%p1%d;48;5;%p2%dm", - ResetFgBg: "\x1b[39;49m", - AltChars: "+C,D-A.B0E``aaffgghFiGjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[7~", - KeyEnd: "\x1b[8~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyBacktab: "\x1b[Z", - KeyShfLeft: "\x1b[d", - KeyShfRight: "\x1b[c", - KeyShfUp: "\x1b[a", - KeyShfDown: "\x1b[b", - KeyShfHome: "\x1b[7$", - KeyShfEnd: "\x1b[8$", - KeyShfInsert: "\x1b[2$", - KeyShfDelete: "\x1b[3$", - KeyCtrlUp: "\x1b[Oa", - KeyCtrlDown: "\x1b[Ob", - KeyCtrlRight: "\x1b[Oc", - KeyCtrlLeft: "\x1b[Od", - KeyCtrlHome: "\x1b[7^", - KeyCtrlEnd: "\x1b[8^", - }) - - // rxvt-unicode terminal with 256 colors (X Window System) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "rxvt-unicode-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[r\x1b[?1049l", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x1b(B", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b=", - ExitKeypad: "\x1b>", - SetFg: "\x1b[38;5;%p1%dm", - SetBg: "\x1b[48;5;%p1%dm", - SetFgBg: "\x1b[38;5;%p1%d;48;5;%p2%dm", - ResetFgBg: "\x1b[39;49m", - AltChars: "+C,D-A.B0E``aaffgghFiGjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[7~", - KeyEnd: "\x1b[8~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1b[11~", - KeyF2: "\x1b[12~", - KeyF3: "\x1b[13~", - KeyF4: "\x1b[14~", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyBacktab: "\x1b[Z", - KeyShfLeft: "\x1b[d", - KeyShfRight: "\x1b[c", - KeyShfUp: "\x1b[a", - KeyShfDown: "\x1b[b", - KeyShfHome: "\x1b[7$", - KeyShfEnd: "\x1b[8$", - KeyShfInsert: "\x1b[2$", - KeyShfDelete: "\x1b[3$", - KeyCtrlUp: "\x1b[Oa", - KeyCtrlDown: "\x1b[Ob", - KeyCtrlRight: "\x1b[Oc", - KeyCtrlLeft: "\x1b[Od", - KeyCtrlHome: "\x1b[7^", - KeyCtrlEnd: "\x1b[8^", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/s/screen/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/s/screen/term.go deleted file mode 100644 index 25ca770..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/s/screen/term.go +++ /dev/null @@ -1,128 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package screen - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // VT 100/ANSI X3.64 virtual terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "screen", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[34h\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "++,,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1bM", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - }) - - // GNU Screen with 256 colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "screen-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[34h\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "++,,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1bM", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/s/simpleterm/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/s/simpleterm/term.go deleted file mode 100644 index c46a7c1..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/s/simpleterm/term.go +++ /dev/null @@ -1,136 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package simpleterm - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // simpleterm - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "st", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[0m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - AltChars: "+C,D-A.B0E``aaffgghFiGjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - EnableAcs: "\x1b)0", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyClear: "\x1b[3;5~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - TrueColor: true, - }) - - // simpleterm with 256 colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "st-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[0m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "+C,D-A.B0E``aaffgghFiGjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - EnableAcs: "\x1b)0", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyClear: "\x1b[3;5~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - TrueColor: true, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/s/sun/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/s/sun/term.go deleted file mode 100644 index 6fc3c71..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/s/sun/term.go +++ /dev/null @@ -1,91 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package sun - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // Sun Microsystems Inc. workstation console - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "sun", - Aliases: []string{"sun1", "sun2"}, - Columns: 80, - Lines: 34, - Bell: "\a", - Clear: "\f", - AttrOff: "\x1b[m", - Reverse: "\x1b[7m", - PadChar: "\x00", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[247z", - KeyDelete: "\u007f", - KeyBackspace: "\b", - KeyHome: "\x1b[214z", - KeyEnd: "\x1b[220z", - KeyPgUp: "\x1b[216z", - KeyPgDn: "\x1b[222z", - KeyF1: "\x1b[224z", - KeyF2: "\x1b[225z", - KeyF3: "\x1b[226z", - KeyF4: "\x1b[227z", - KeyF5: "\x1b[228z", - KeyF6: "\x1b[229z", - KeyF7: "\x1b[230z", - KeyF8: "\x1b[231z", - KeyF9: "\x1b[232z", - KeyF10: "\x1b[233z", - KeyF11: "\x1b[234z", - KeyF12: "\x1b[235z", - }) - - // Sun Microsystems Workstation console with color support (IA systems) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "sun-color", - Columns: 80, - Lines: 34, - Colors: 8, - Bell: "\a", - Clear: "\f", - AttrOff: "\x1b[m", - Bold: "\x1b[1m", - Reverse: "\x1b[7m", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[0m", - PadChar: "\x00", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[247z", - KeyDelete: "\u007f", - KeyBackspace: "\b", - KeyHome: "\x1b[214z", - KeyEnd: "\x1b[220z", - KeyPgUp: "\x1b[216z", - KeyPgDn: "\x1b[222z", - KeyF1: "\x1b[224z", - KeyF2: "\x1b[225z", - KeyF3: "\x1b[226z", - KeyF4: "\x1b[227z", - KeyF5: "\x1b[228z", - KeyF6: "\x1b[229z", - KeyF7: "\x1b[230z", - KeyF8: "\x1b[231z", - KeyF9: "\x1b[232z", - KeyF10: "\x1b[233z", - KeyF11: "\x1b[234z", - KeyF12: "\x1b[235z", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/t/termite/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/t/termite/term.go deleted file mode 100644 index 507941a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/t/termite/term.go +++ /dev/null @@ -1,66 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package termite - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // VTE-based terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "termite", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b(B\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Italic: "\x1b[3m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "++,,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/t/tmux/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/t/tmux/term.go deleted file mode 100644 index 86fe46a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/t/tmux/term.go +++ /dev/null @@ -1,134 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package tmux - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // tmux terminal multiplexer - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "tmux", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[34h\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "++,,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - StrikeThrough: "\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1bM", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) - - // tmux with 256 colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "tmux-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[34h\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "++,,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - StrikeThrough: "\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1bM", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyEnd: "\x1b[4~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/terminfo.go b/vendor/github.com/gdamore/tcell/v2/terminfo/terminfo.go deleted file mode 100644 index 5e875e8..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/terminfo.go +++ /dev/null @@ -1,803 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package terminfo - -import ( - "bytes" - "errors" - "fmt" - "io" - "os" - "strconv" - "strings" - "sync" - "time" -) - -var ( - // ErrTermNotFound indicates that a suitable terminal entry could - // not be found. This can result from either not having TERM set, - // or from the TERM failing to support certain minimal functionality, - // in particular absolute cursor addressability (the cup capability) - // is required. For example, legacy "adm3" lacks this capability, - // whereas the slightly newer "adm3a" supports it. This failure - // occurs most often with "dumb". - ErrTermNotFound = errors.New("terminal entry not found") -) - -// Terminfo represents a terminfo entry. Note that we use friendly names -// in Go, but when we write out JSON, we use the same names as terminfo. -// The name, aliases and smous, rmous fields do not come from terminfo directly. -type Terminfo struct { - Name string - Aliases []string - Columns int // cols - Lines int // lines - Colors int // colors - Bell string // bell - Clear string // clear - EnterCA string // smcup - ExitCA string // rmcup - ShowCursor string // cnorm - HideCursor string // civis - AttrOff string // sgr0 - Underline string // smul - Bold string // bold - Blink string // blink - Reverse string // rev - Dim string // dim - Italic string // sitm - EnterKeypad string // smkx - ExitKeypad string // rmkx - SetFg string // setaf - SetBg string // setab - ResetFgBg string // op - SetCursor string // cup - CursorBack1 string // cub1 - CursorUp1 string // cuu1 - PadChar string // pad - KeyBackspace string // kbs - KeyF1 string // kf1 - KeyF2 string // kf2 - KeyF3 string // kf3 - KeyF4 string // kf4 - KeyF5 string // kf5 - KeyF6 string // kf6 - KeyF7 string // kf7 - KeyF8 string // kf8 - KeyF9 string // kf9 - KeyF10 string // kf10 - KeyF11 string // kf11 - KeyF12 string // kf12 - KeyF13 string // kf13 - KeyF14 string // kf14 - KeyF15 string // kf15 - KeyF16 string // kf16 - KeyF17 string // kf17 - KeyF18 string // kf18 - KeyF19 string // kf19 - KeyF20 string // kf20 - KeyF21 string // kf21 - KeyF22 string // kf22 - KeyF23 string // kf23 - KeyF24 string // kf24 - KeyF25 string // kf25 - KeyF26 string // kf26 - KeyF27 string // kf27 - KeyF28 string // kf28 - KeyF29 string // kf29 - KeyF30 string // kf30 - KeyF31 string // kf31 - KeyF32 string // kf32 - KeyF33 string // kf33 - KeyF34 string // kf34 - KeyF35 string // kf35 - KeyF36 string // kf36 - KeyF37 string // kf37 - KeyF38 string // kf38 - KeyF39 string // kf39 - KeyF40 string // kf40 - KeyF41 string // kf41 - KeyF42 string // kf42 - KeyF43 string // kf43 - KeyF44 string // kf44 - KeyF45 string // kf45 - KeyF46 string // kf46 - KeyF47 string // kf47 - KeyF48 string // kf48 - KeyF49 string // kf49 - KeyF50 string // kf50 - KeyF51 string // kf51 - KeyF52 string // kf52 - KeyF53 string // kf53 - KeyF54 string // kf54 - KeyF55 string // kf55 - KeyF56 string // kf56 - KeyF57 string // kf57 - KeyF58 string // kf58 - KeyF59 string // kf59 - KeyF60 string // kf60 - KeyF61 string // kf61 - KeyF62 string // kf62 - KeyF63 string // kf63 - KeyF64 string // kf64 - KeyInsert string // kich1 - KeyDelete string // kdch1 - KeyHome string // khome - KeyEnd string // kend - KeyHelp string // khlp - KeyPgUp string // kpp - KeyPgDn string // knp - KeyUp string // kcuu1 - KeyDown string // kcud1 - KeyLeft string // kcub1 - KeyRight string // kcuf1 - KeyBacktab string // kcbt - KeyExit string // kext - KeyClear string // kclr - KeyPrint string // kprt - KeyCancel string // kcan - Mouse string // kmous - MouseMode string // XM - AltChars string // acsc - EnterAcs string // smacs - ExitAcs string // rmacs - EnableAcs string // enacs - KeyShfRight string // kRIT - KeyShfLeft string // kLFT - KeyShfHome string // kHOM - KeyShfEnd string // kEND - KeyShfInsert string // kIC - KeyShfDelete string // kDC - - // These are non-standard extensions to terminfo. This includes - // true color support, and some additional keys. Its kind of bizarre - // that shifted variants of left and right exist, but not up and down. - // Terminal support for these are going to vary amongst XTerm - // emulations, so don't depend too much on them in your application. - - StrikeThrough string // smxx - SetFgBg string // setfgbg - SetFgBgRGB string // setfgbgrgb - SetFgRGB string // setfrgb - SetBgRGB string // setbrgb - KeyShfUp string // shift-up - KeyShfDown string // shift-down - KeyShfPgUp string // shift-kpp - KeyShfPgDn string // shift-knp - KeyCtrlUp string // ctrl-up - KeyCtrlDown string // ctrl-left - KeyCtrlRight string // ctrl-right - KeyCtrlLeft string // ctrl-left - KeyMetaUp string // meta-up - KeyMetaDown string // meta-left - KeyMetaRight string // meta-right - KeyMetaLeft string // meta-left - KeyAltUp string // alt-up - KeyAltDown string // alt-left - KeyAltRight string // alt-right - KeyAltLeft string // alt-left - KeyCtrlHome string - KeyCtrlEnd string - KeyMetaHome string - KeyMetaEnd string - KeyAltHome string - KeyAltEnd string - KeyAltShfUp string - KeyAltShfDown string - KeyAltShfLeft string - KeyAltShfRight string - KeyMetaShfUp string - KeyMetaShfDown string - KeyMetaShfLeft string - KeyMetaShfRight string - KeyCtrlShfUp string - KeyCtrlShfDown string - KeyCtrlShfLeft string - KeyCtrlShfRight string - KeyCtrlShfHome string - KeyCtrlShfEnd string - KeyAltShfHome string - KeyAltShfEnd string - KeyMetaShfHome string - KeyMetaShfEnd string - EnablePaste string // bracketed paste mode - DisablePaste string - PasteStart string - PasteEnd string - Modifiers int - TrueColor bool // true if the terminal supports direct color -} - -const ( - ModifiersNone = 0 - ModifiersXTerm = 1 -) - -type stackElem struct { - s string - i int - isStr bool - isInt bool -} - -type stack []stackElem - -func (st stack) Push(v string) stack { - e := stackElem{ - s: v, - isStr: true, - } - return append(st, e) -} - -func (st stack) Pop() (string, stack) { - v := "" - if len(st) > 0 { - e := st[len(st)-1] - st = st[:len(st)-1] - if e.isStr { - v = e.s - } else { - v = strconv.Itoa(e.i) - } - } - return v, st -} - -func (st stack) PopInt() (int, stack) { - if len(st) > 0 { - e := st[len(st)-1] - st = st[:len(st)-1] - if e.isInt { - return e.i, st - } else if e.isStr { - // If the string that was pushed was the representation - // of a number e.g. '123', then return the number. If the - // conversion doesn't work, assume the string pushed was - // intended to return, as an int, the ascii representation - // of the (one and only) character. - i, err := strconv.Atoi(e.s) - if err == nil { - return i, st - } else if len(e.s) >= 1 { - return int(e.s[0]), st - } - } - } - return 0, st -} - -func (st stack) PopBool() (bool, stack) { - if len(st) > 0 { - e := st[len(st)-1] - st = st[:len(st)-1] - if e.isStr { - if e.s == "1" { - return true, st - } - return false, st - } else if e.i == 1 { - return true, st - } else { - return false, st - } - } - return false, st -} - -func (st stack) PushInt(i int) stack { - e := stackElem{ - i: i, - isInt: true, - } - return append(st, e) -} - -func (st stack) PushBool(i bool) stack { - if i { - return st.PushInt(1) - } - return st.PushInt(0) -} - -// static vars -var svars [26]string - -// paramsBuffer handles some persistent state for TParam. Technically we -// could probably dispense with this, but caching buffer arrays gives us -// a nice little performance boost. Furthermore, we know that TParam is -// rarely (never?) called re-entrantly, so we can just reuse the same -// buffers, making it thread-safe by stashing a lock. -type paramsBuffer struct { - out bytes.Buffer - buf bytes.Buffer - lk sync.Mutex -} - -// Start initializes the params buffer with the initial string data. -// It also locks the paramsBuffer. The caller must call End() when -// finished. -func (pb *paramsBuffer) Start(s string) { - pb.lk.Lock() - pb.out.Reset() - pb.buf.Reset() - pb.buf.WriteString(s) -} - -// End returns the final output from TParam, but it also releases the lock. -func (pb *paramsBuffer) End() string { - s := pb.out.String() - pb.lk.Unlock() - return s -} - -// NextCh returns the next input character to the expander. -func (pb *paramsBuffer) NextCh() (byte, error) { - return pb.buf.ReadByte() -} - -// PutCh "emits" (rather schedules for output) a single byte character. -func (pb *paramsBuffer) PutCh(ch byte) { - pb.out.WriteByte(ch) -} - -// PutString schedules a string for output. -func (pb *paramsBuffer) PutString(s string) { - pb.out.WriteString(s) -} - -var pb = ¶msBuffer{} - -// TParm takes a terminfo parameterized string, such as setaf or cup, and -// evaluates the string, and returns the result with the parameter -// applied. -func (t *Terminfo) TParm(s string, p ...int) string { - var stk stack - var a, b string - var ai, bi int - var ab bool - var dvars [26]string - var params [9]int - - pb.Start(s) - - // make sure we always have 9 parameters -- makes it easier - // later to skip checks - for i := 0; i < len(params) && i < len(p); i++ { - params[i] = p[i] - } - - nest := 0 - - for { - - ch, err := pb.NextCh() - if err != nil { - break - } - - if ch != '%' { - pb.PutCh(ch) - continue - } - - ch, err = pb.NextCh() - if err != nil { - // XXX Error - break - } - - switch ch { - case '%': // quoted % - pb.PutCh(ch) - - case 'i': // increment both parameters (ANSI cup support) - params[0]++ - params[1]++ - - case 'c', 's': - // NB: these, and 'd' below are special cased for - // efficiency. They could be handled by the richer - // format support below, less efficiently. - a, stk = stk.Pop() - pb.PutString(a) - - case 'd': - ai, stk = stk.PopInt() - pb.PutString(strconv.Itoa(ai)) - - case '0', '1', '2', '3', '4', 'x', 'X', 'o', ':': - // This is pretty suboptimal, but this is rarely used. - // None of the mainstream terminals use any of this, - // and it would surprise me if this code is ever - // executed outside of test cases. - f := "%" - if ch == ':' { - ch, _ = pb.NextCh() - } - f += string(ch) - for ch == '+' || ch == '-' || ch == '#' || ch == ' ' { - ch, _ = pb.NextCh() - f += string(ch) - } - for (ch >= '0' && ch <= '9') || ch == '.' { - ch, _ = pb.NextCh() - f += string(ch) - } - switch ch { - case 'd', 'x', 'X', 'o': - ai, stk = stk.PopInt() - pb.PutString(fmt.Sprintf(f, ai)) - case 'c', 's': - a, stk = stk.Pop() - pb.PutString(fmt.Sprintf(f, a)) - } - - case 'p': // push parameter - ch, _ = pb.NextCh() - ai = int(ch - '1') - if ai >= 0 && ai < len(params) { - stk = stk.PushInt(params[ai]) - } else { - stk = stk.PushInt(0) - } - - case 'P': // pop & store variable - ch, _ = pb.NextCh() - if ch >= 'A' && ch <= 'Z' { - svars[int(ch-'A')], stk = stk.Pop() - } else if ch >= 'a' && ch <= 'z' { - dvars[int(ch-'a')], stk = stk.Pop() - } - - case 'g': // recall & push variable - ch, _ = pb.NextCh() - if ch >= 'A' && ch <= 'Z' { - stk = stk.Push(svars[int(ch-'A')]) - } else if ch >= 'a' && ch <= 'z' { - stk = stk.Push(dvars[int(ch-'a')]) - } - - case '\'': // push(char) - ch, _ = pb.NextCh() - pb.NextCh() // must be ' but we don't check - stk = stk.Push(string(ch)) - - case '{': // push(int) - ai = 0 - ch, _ = pb.NextCh() - for ch >= '0' && ch <= '9' { - ai *= 10 - ai += int(ch - '0') - ch, _ = pb.NextCh() - } - // ch must be '}' but no verification - stk = stk.PushInt(ai) - - case 'l': // push(strlen(pop)) - a, stk = stk.Pop() - stk = stk.PushInt(len(a)) - - case '+': - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushInt(ai + bi) - - case '-': - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushInt(ai - bi) - - case '*': - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushInt(ai * bi) - - case '/': - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - if bi != 0 { - stk = stk.PushInt(ai / bi) - } else { - stk = stk.PushInt(0) - } - - case 'm': // push(pop mod pop) - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - if bi != 0 { - stk = stk.PushInt(ai % bi) - } else { - stk = stk.PushInt(0) - } - - case '&': // AND - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushInt(ai & bi) - - case '|': // OR - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushInt(ai | bi) - - case '^': // XOR - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushInt(ai ^ bi) - - case '~': // bit complement - ai, stk = stk.PopInt() - stk = stk.PushInt(ai ^ -1) - - case '!': // logical NOT - ai, stk = stk.PopInt() - stk = stk.PushBool(ai != 0) - - case '=': // numeric compare or string compare - b, stk = stk.Pop() - a, stk = stk.Pop() - stk = stk.PushBool(a == b) - - case '>': // greater than, numeric - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushBool(ai > bi) - - case '<': // less than, numeric - bi, stk = stk.PopInt() - ai, stk = stk.PopInt() - stk = stk.PushBool(ai < bi) - - case '?': // start conditional - - case 't': - ab, stk = stk.PopBool() - if ab { - // just keep going - break - } - nest = 0 - ifloop: - // this loop consumes everything until we hit our else, - // or the end of the conditional - for { - ch, err = pb.NextCh() - if err != nil { - break - } - if ch != '%' { - continue - } - ch, _ = pb.NextCh() - switch ch { - case ';': - if nest == 0 { - break ifloop - } - nest-- - case '?': - nest++ - case 'e': - if nest == 0 { - break ifloop - } - } - } - - case 'e': - // if we got here, it means we didn't use the else - // in the 't' case above, and we should skip until - // the end of the conditional - nest = 0 - elloop: - for { - ch, err = pb.NextCh() - if err != nil { - break - } - if ch != '%' { - continue - } - ch, _ = pb.NextCh() - switch ch { - case ';': - if nest == 0 { - break elloop - } - nest-- - case '?': - nest++ - } - } - - case ';': // endif - - } - } - - return pb.End() -} - -// TPuts emits the string to the writer, but expands inline padding -// indications (of the form $<[delay]> where [delay] is msec) to -// a suitable time (unless the terminfo string indicates this isn't needed -// by specifying npc - no padding). All Terminfo based strings should be -// emitted using this function. -func (t *Terminfo) TPuts(w io.Writer, s string) { - for { - beg := strings.Index(s, "$<") - if beg < 0 { - // Most strings don't need padding, which is good news! - io.WriteString(w, s) - return - } - io.WriteString(w, s[:beg]) - s = s[beg+2:] - end := strings.Index(s, ">") - if end < 0 { - // unterminated.. just emit bytes unadulterated - io.WriteString(w, "$<"+s) - return - } - val := s[:end] - s = s[end+1:] - padus := 0 - unit := time.Millisecond - dot := false - loop: - for i := range val { - switch val[i] { - case '0', '1', '2', '3', '4', '5', '6', '7', '8', '9': - padus *= 10 - padus += int(val[i] - '0') - if dot { - unit /= 10 - } - case '.': - if !dot { - dot = true - } else { - break loop - } - default: - break loop - } - } - - // Curses historically uses padding to achieve "fine grained" - // delays. We have much better clocks these days, and so we - // do not rely on padding but simply sleep a bit. - if len(t.PadChar) > 0 { - time.Sleep(unit * time.Duration(padus)) - } - } -} - -// TGoto returns a string suitable for addressing the cursor at the given -// row and column. The origin 0, 0 is in the upper left corner of the screen. -func (t *Terminfo) TGoto(col, row int) string { - return t.TParm(t.SetCursor, row, col) -} - -// TColor returns a string corresponding to the given foreground and background -// colors. Either fg or bg can be set to -1 to elide. -func (t *Terminfo) TColor(fi, bi int) string { - rv := "" - // As a special case, we map bright colors to lower versions if the - // color table only holds 8. For the remaining 240 colors, the user - // is out of luck. Someday we could create a mapping table, but its - // not worth it. - if t.Colors == 8 { - if fi > 7 && fi < 16 { - fi -= 8 - } - if bi > 7 && bi < 16 { - bi -= 8 - } - } - if t.Colors > fi && fi >= 0 { - rv += t.TParm(t.SetFg, fi) - } - if t.Colors > bi && bi >= 0 { - rv += t.TParm(t.SetBg, bi) - } - return rv -} - -var ( - dblock sync.Mutex - terminfos = make(map[string]*Terminfo) - aliases = make(map[string]string) -) - -// AddTerminfo can be called to register a new Terminfo entry. -func AddTerminfo(t *Terminfo) { - dblock.Lock() - terminfos[t.Name] = t - for _, x := range t.Aliases { - terminfos[x] = t - } - dblock.Unlock() -} - -// LookupTerminfo attempts to find a definition for the named $TERM. -func LookupTerminfo(name string) (*Terminfo, error) { - if name == "" { - // else on windows: index out of bounds - // on the name[0] reference below - return nil, ErrTermNotFound - } - - addtruecolor := false - switch os.Getenv("COLORTERM") { - case "truecolor", "24bit", "24-bit": - addtruecolor = true - } - dblock.Lock() - t := terminfos[name] - dblock.Unlock() - - // If the name ends in -truecolor, then fabricate an entry - // from the corresponding -256color, -color, or bare terminal. - if t != nil && t.TrueColor { - addtruecolor = true - } else if t == nil && strings.HasSuffix(name, "-truecolor") { - - suffixes := []string{ - "-256color", - "-88color", - "-color", - "", - } - base := name[:len(name)-len("-truecolor")] - for _, s := range suffixes { - if t, _ = LookupTerminfo(base + s); t != nil { - addtruecolor = true - break - } - } - } - - if t == nil { - return nil, ErrTermNotFound - } - - switch os.Getenv("TCELL_TRUECOLOR") { - case "": - case "disable": - addtruecolor = false - default: - addtruecolor = true - } - - // If the user has requested 24-bit color with $COLORTERM, then - // amend the value (unless already present). This means we don't - // need to have a value present. - if addtruecolor && - t.SetFgBgRGB == "" && - t.SetFgRGB == "" && - t.SetBgRGB == "" { - - // Supply vanilla ISO 8613-6:1994 24-bit color sequences. - t.SetFgRGB = "\x1b[38;2;%p1%d;%p2%d;%p3%dm" - t.SetBgRGB = "\x1b[48;2;%p1%d;%p2%d;%p3%dm" - t.SetFgBgRGB = "\x1b[38;2;%p1%d;%p2%d;%p3%d;" + - "48;2;%p4%d;%p5%d;%p6%dm" - } - - return t, nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/terminfo_test.go b/vendor/github.com/gdamore/tcell/v2/terminfo/terminfo_test.go deleted file mode 100644 index bba685d..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/terminfo_test.go +++ /dev/null @@ -1,100 +0,0 @@ -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package terminfo - -import ( - "bytes" - "testing" - "time" -) - -// This terminfo entry is a stripped down version from -// xterm-256color, but I've added some of my own entries. -var testTerminfo = &Terminfo{ - Name: "simulation_test", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Blink: "\x1b2ms$<20>something", - Reverse: "\x1b[7m", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - PadChar: "\x00", -} - -func TestTerminfoExpansion(t *testing.T) { - - ti := testTerminfo - - // Tests %i and basic parameter strings too - if ti.TGoto(7, 9) != "\x1b[10;8H" { - t.Error("TGoto expansion failed") - } - - // This tests some conditionals - if ti.TParm("A[%p1%2.2X]B", 47) != "A[2F]B" { - t.Error("TParm conditionals failed") - } - - // Color tests. - if ti.TParm(ti.SetFg, 7) != "\x1b[37m" { - t.Error("SetFg(7) failed") - } - if ti.TParm(ti.SetFg, 15) != "\x1b[97m" { - t.Error("SetFg(15) failed") - } - if ti.TParm(ti.SetFg, 200) != "\x1b[38;5;200m" { - t.Error("SetFg(200) failed") - } - - if ti.TParm(ti.MouseMode, 1) != "\x1b[?1000h\x1b[?1003h\x1b[?1006h" { - t.Error("Enable mouse mode failed") - } - if ti.TParm(ti.MouseMode, 0) != "\x1b[?1000l\x1b[?1003l\x1b[?1006l" { - t.Error("Disable mouse mode failed") - } -} - -func TestTerminfoDelay(t *testing.T) { - ti := testTerminfo - buf := bytes.NewBuffer(nil) - now := time.Now() - ti.TPuts(buf, ti.Blink) - then := time.Now() - s := string(buf.Bytes()) - if s != "\x1b2mssomething" { - t.Errorf("Terminfo delay failed: %s", s) - } - if then.Sub(now) < time.Millisecond*20 { - t.Error("Too short delay") - } - if then.Sub(now) > time.Millisecond*50 { - t.Error("Too late delay") - } -} - -func BenchmarkSetFgBg(b *testing.B) { - ti := testTerminfo - - for i := 0; i < b.N; i++ { - ti.TParm(ti.SetFg, 100, 200) - ti.TParm(ti.SetBg, 100, 200) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt100/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt100/term.go deleted file mode 100644 index d43a8a2..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt100/term.go +++ /dev/null @@ -1,48 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package vt100 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // dec vt100 (w/advanced video) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "vt100", - Aliases: []string{"vt100-am"}, - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b[H\x1b[J$<50>", - AttrOff: "\x1b[m\x0f$<2>", - Underline: "\x1b[4m$<2>", - Bold: "\x1b[1m$<2>", - Blink: "\x1b[5m$<2>", - Reverse: "\x1b[7m$<2>", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - SetCursor: "\x1b[%i%p1%d;%p2%dH$<5>", - CursorBack1: "\b", - CursorUp1: "\x1b[A$<2>", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyBackspace: "\b", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1bOt", - KeyF6: "\x1bOu", - KeyF7: "\x1bOv", - KeyF8: "\x1bOl", - KeyF9: "\x1bOw", - KeyF10: "\x1bOx", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt102/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt102/term.go deleted file mode 100644 index 93b8e4c..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt102/term.go +++ /dev/null @@ -1,47 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package vt102 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // dec vt102 - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "vt102", - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b[H\x1b[J$<50>", - AttrOff: "\x1b[m\x0f$<2>", - Underline: "\x1b[4m$<2>", - Bold: "\x1b[1m$<2>", - Blink: "\x1b[5m$<2>", - Reverse: "\x1b[7m$<2>", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b(B\x1b)0", - SetCursor: "\x1b[%i%p1%d;%p2%dH$<5>", - CursorBack1: "\b", - CursorUp1: "\x1b[A$<2>", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyBackspace: "\b", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1bOt", - KeyF6: "\x1bOu", - KeyF7: "\x1bOv", - KeyF8: "\x1bOl", - KeyF9: "\x1bOw", - KeyF10: "\x1bOx", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt220/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt220/term.go deleted file mode 100644 index 11efadc..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt220/term.go +++ /dev/null @@ -1,58 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package vt220 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // dec vt220 - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "vt220", - Aliases: []string{"vt200"}, - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b[H\x1b[J", - AttrOff: "\x1b[m\x1b(B", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0$<2>", - ExitAcs: "\x1b(B$<4>", - EnableAcs: "\x1b)0", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\b", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - KeyHelp: "\x1b[28~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt320/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt320/term.go deleted file mode 100644 index 428e450..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt320/term.go +++ /dev/null @@ -1,63 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package vt320 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // dec vt320 7 bit terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "vt320", - Aliases: []string{"vt300"}, - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x1b(B", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1b[1~", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF13: "\x1b[25~", - KeyF14: "\x1b[26~", - KeyF15: "\x1b[28~", - KeyF16: "\x1b[29~", - KeyF17: "\x1b[31~", - KeyF18: "\x1b[32~", - KeyF19: "\x1b[33~", - KeyF20: "\x1b[34~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt400/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt400/term.go deleted file mode 100644 index aea0efb..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt400/term.go +++ /dev/null @@ -1,46 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package vt400 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // dec vt400 24x80 column autowrap - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "vt400", - Aliases: []string{"vt400-24", "dec-vt400"}, - Columns: 80, - Lines: 24, - Clear: "\x1b[H\x1b[J$<10/>", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x1b(B", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyBackspace: "\b", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt420/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt420/term.go deleted file mode 100644 index dbfb9f9..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt420/term.go +++ /dev/null @@ -1,53 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package vt420 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // DEC VT420 - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "vt420", - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b[H\x1b[2J$<50>", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x1b(B$<2>", - Underline: "\x1b[4m", - Bold: "\x1b[1m$<2>", - Blink: "\x1b[5m$<2>", - Reverse: "\x1b[7m$<2>", - EnterKeypad: "\x1b=", - ExitKeypad: "\x1b>", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0$<2>", - ExitAcs: "\x1b(B$<4>", - EnableAcs: "\x1b)0", - SetCursor: "\x1b[%i%p1%d;%p2%dH$<10>", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1b[A", - KeyDown: "\x1b[B", - KeyRight: "\x1b[C", - KeyLeft: "\x1b[D", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\b", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[17~", - KeyF6: "\x1b[18~", - KeyF7: "\x1b[19~", - KeyF8: "\x1b[20~", - KeyF9: "\x1b[21~", - KeyF10: "\x1b[29~", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt52/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt52/term.go deleted file mode 100644 index ba49f7f..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/v/vt52/term.go +++ /dev/null @@ -1,29 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package vt52 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // dec vt52 - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "vt52", - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1bH\x1bJ", - PadChar: "\x00", - AltChars: "+h.k0affggolpnqprrss", - EnterAcs: "\x1bF", - ExitAcs: "\x1bG", - SetCursor: "\x1bY%p1%' '%+%c%p2%' '%+%c", - CursorBack1: "\x1bD", - CursorUp1: "\x1bA", - KeyUp: "\x1bA", - KeyDown: "\x1bB", - KeyRight: "\x1bC", - KeyLeft: "\x1bD", - KeyBackspace: "\b", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy50/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy50/term.go deleted file mode 100644 index 542a4da..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy50/term.go +++ /dev/null @@ -1,59 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package wy50 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // Wyse 50 - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "wy50", - Aliases: []string{"wyse50"}, - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b+$<20>", - ShowCursor: "\x1b`1", - HideCursor: "\x1b`0", - AttrOff: "\x1b(\x1bH\x03", - Dim: "\x1b`7\x1b)", - Reverse: "\x1b`6\x1b)", - PadChar: "\x00", - AltChars: "a;j5k3l2m1n8q:t4u9v=w0x6", - EnterAcs: "\x1bH\x02", - ExitAcs: "\x1bH\x03", - SetCursor: "\x1b=%p1%' '%+%c%p2%' '%+%c", - CursorBack1: "\b", - CursorUp1: "\v", - KeyUp: "\v", - KeyDown: "\n", - KeyRight: "\f", - KeyLeft: "\b", - KeyInsert: "\x1bQ", - KeyDelete: "\x1bW", - KeyBackspace: "\b", - KeyHome: "\x1e", - KeyPgUp: "\x1bJ", - KeyPgDn: "\x1bK", - KeyF1: "\x01@\r", - KeyF2: "\x01A\r", - KeyF3: "\x01B\r", - KeyF4: "\x01C\r", - KeyF5: "\x01D\r", - KeyF6: "\x01E\r", - KeyF7: "\x01F\r", - KeyF8: "\x01G\r", - KeyF9: "\x01H\r", - KeyF10: "\x01I\r", - KeyF11: "\x01J\r", - KeyF12: "\x01K\r", - KeyF13: "\x01L\r", - KeyF14: "\x01M\r", - KeyF15: "\x01N\r", - KeyF16: "\x01O\r", - KeyPrint: "\x1bP", - KeyBacktab: "\x1bI", - KeyShfHome: "\x1b{", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy60/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy60/term.go deleted file mode 100644 index fdf7f53..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy60/term.go +++ /dev/null @@ -1,63 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package wy60 - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // Wyse 60 - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "wy60", - Aliases: []string{"wyse60"}, - Columns: 80, - Lines: 24, - Bell: "\a", - Clear: "\x1b+$<100>", - EnterCA: "\x1bw0", - ExitCA: "\x1bw1", - ShowCursor: "\x1b`1", - HideCursor: "\x1b`0", - AttrOff: "\x1b(\x1bH\x03\x1bG0\x1bcD", - Underline: "\x1bG8", - Dim: "\x1bGp", - Blink: "\x1bG2", - Reverse: "\x1bG4", - PadChar: "\x00", - AltChars: "+/,.0[a2fxgqh1ihjYk?lZm@nEqDtCu4vAwBx3yszr{c~~", - EnterAcs: "\x1bcE", - ExitAcs: "\x1bcD", - SetCursor: "\x1b=%p1%' '%+%c%p2%' '%+%c", - CursorBack1: "\b", - CursorUp1: "\v", - KeyUp: "\v", - KeyDown: "\n", - KeyRight: "\f", - KeyLeft: "\b", - KeyInsert: "\x1bQ", - KeyDelete: "\x1bW", - KeyBackspace: "\b", - KeyHome: "\x1e", - KeyPgUp: "\x1bJ", - KeyPgDn: "\x1bK", - KeyF1: "\x01@\r", - KeyF2: "\x01A\r", - KeyF3: "\x01B\r", - KeyF4: "\x01C\r", - KeyF5: "\x01D\r", - KeyF6: "\x01E\r", - KeyF7: "\x01F\r", - KeyF8: "\x01G\r", - KeyF9: "\x01H\r", - KeyF10: "\x01I\r", - KeyF11: "\x01J\r", - KeyF12: "\x01K\r", - KeyF13: "\x01L\r", - KeyF14: "\x01M\r", - KeyF15: "\x01N\r", - KeyF16: "\x01O\r", - KeyPrint: "\x1bP", - KeyBacktab: "\x1bI", - KeyShfHome: "\x1b{", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy99_ansi/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy99_ansi/term.go deleted file mode 100644 index dc7aecb..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/w/wy99_ansi/term.go +++ /dev/null @@ -1,114 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package wy99_ansi - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // Wyse WY-99GT in ansi mode (int'l PC keyboard) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "wy99-ansi", - Columns: 80, - Lines: 25, - Bell: "\a", - Clear: "\x1b[H\x1b[J$<200>", - ShowCursor: "\x1b[34h\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f\x1b[\"q", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h", - ExitKeypad: "\x1b[?1l", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooqqssttuuvvwwxx{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b$<1>", - CursorUp1: "\x1bM", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyBackspace: "\b", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[M", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF17: "\x1b[K", - KeyF18: "\x1b[31~", - KeyF19: "\x1b[32~", - KeyF20: "\x1b[33~", - KeyF21: "\x1b[34~", - KeyF22: "\x1b[35~", - KeyF23: "\x1b[1~", - KeyF24: "\x1b[2~", - KeyBacktab: "\x1b[z", - }) - - // Wyse WY-99GT in ansi mode (US PC keyboard) - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "wy99a-ansi", - Columns: 80, - Lines: 25, - Bell: "\a", - Clear: "\x1b[H\x1b[J$<200>", - ShowCursor: "\x1b[34h\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[m\x0f\x1b[\"q", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h", - ExitKeypad: "\x1b[?1l", - PadChar: "\x00", - AltChars: "``aaffggjjkkllmmnnooqqssttuuvvwwxx{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b$<1>", - CursorUp1: "\x1bM", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyBackspace: "\b", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[M", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyF17: "\x1b[K", - KeyF18: "\x1b[31~", - KeyF19: "\x1b[32~", - KeyF20: "\x1b[33~", - KeyF21: "\x1b[34~", - KeyF22: "\x1b[35~", - KeyF23: "\x1b[1~", - KeyF24: "\x1b[2~", - KeyBacktab: "\x1b[z", - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xfce/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/x/xfce/term.go deleted file mode 100644 index 0059db0..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xfce/term.go +++ /dev/null @@ -1,67 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package xfce - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // Xfce Terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "xfce", - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b7\x1b[?47h", - ExitCA: "\x1b[2J\x1b[?47l\x1b8", - ShowCursor: "\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b[0m\x0f", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - PadChar: "\x00", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x0e", - ExitAcs: "\x0f", - EnableAcs: "\x1b)0", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm/term.go deleted file mode 100644 index a230b67..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm/term.go +++ /dev/null @@ -1,192 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package xterm - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // X11 terminal emulator - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "xterm", - Aliases: []string{"xterm-debian"}, - Columns: 80, - Lines: 24, - Colors: 8, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h\x1b[22;0;0t", - ExitCA: "\x1b[?1049l\x1b[23;0;0t", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b(B\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[3%p1%dm", - SetBg: "\x1b[4%p1%dm", - SetFgBg: "\x1b[3%p1%d;4%p2%dm", - ResetFgBg: "\x1b[39;49m", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) - - // xterm with 88 colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "xterm-88color", - Columns: 80, - Lines: 24, - Colors: 88, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h\x1b[22;0;0t", - ExitCA: "\x1b[?1049l\x1b[23;0;0t", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b(B\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) - - // xterm with 256 colors - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "xterm-256color", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h\x1b[22;0;0t", - ExitCA: "\x1b[?1049l\x1b[23;0;0t", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b(B\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Blink: "\x1b[5m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm_kitty/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm_kitty/term.go deleted file mode 100644 index f486f4a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm_kitty/term.go +++ /dev/null @@ -1,69 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package xterm_kitty - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // KovIdTTY - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "xterm-kitty", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b(B\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h", - ExitKeypad: "\x1b[?1l", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "++,,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - StrikeThrough:"\x1b[9m", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - TrueColor: true, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm_termite/term.go b/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm_termite/term.go deleted file mode 100644 index c048db0..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terminfo/x/xterm_termite/term.go +++ /dev/null @@ -1,67 +0,0 @@ -// Generated automatically. DO NOT HAND-EDIT. - -package xterm_termite - -import "github.com/gdamore/tcell/v2/terminfo" - -func init() { - - // VTE-based terminal - terminfo.AddTerminfo(&terminfo.Terminfo{ - Name: "xterm-termite", - Columns: 80, - Lines: 24, - Colors: 256, - Bell: "\a", - Clear: "\x1b[H\x1b[2J", - EnterCA: "\x1b[?1049h", - ExitCA: "\x1b[?1049l", - ShowCursor: "\x1b[?12l\x1b[?25h", - HideCursor: "\x1b[?25l", - AttrOff: "\x1b(B\x1b[m", - Underline: "\x1b[4m", - Bold: "\x1b[1m", - Dim: "\x1b[2m", - Italic: "\x1b[3m", - Reverse: "\x1b[7m", - EnterKeypad: "\x1b[?1h\x1b=", - ExitKeypad: "\x1b[?1l\x1b>", - SetFg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m", - SetBg: "\x1b[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m", - SetFgBg: "\x1b[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;;%?%p2%{8}%<%t4%p2%d%e%p2%{16}%<%t10%p2%{8}%-%d%e48;5;%p2%d%;m", - ResetFgBg: "\x1b[39;49m", - AltChars: "++,,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~", - EnterAcs: "\x1b(0", - ExitAcs: "\x1b(B", - Mouse: "\x1b[M", - MouseMode: "%?%p1%{1}%=%t%'h'%Pa%e%'l'%Pa%;\x1b[?1000%ga%c\x1b[?1002%ga%c\x1b[?1003%ga%c\x1b[?1006%ga%c", - SetCursor: "\x1b[%i%p1%d;%p2%dH", - CursorBack1: "\b", - CursorUp1: "\x1b[A", - KeyUp: "\x1bOA", - KeyDown: "\x1bOB", - KeyRight: "\x1bOC", - KeyLeft: "\x1bOD", - KeyInsert: "\x1b[2~", - KeyDelete: "\x1b[3~", - KeyBackspace: "\u007f", - KeyHome: "\x1bOH", - KeyEnd: "\x1bOF", - KeyPgUp: "\x1b[5~", - KeyPgDn: "\x1b[6~", - KeyF1: "\x1bOP", - KeyF2: "\x1bOQ", - KeyF3: "\x1bOR", - KeyF4: "\x1bOS", - KeyF5: "\x1b[15~", - KeyF6: "\x1b[17~", - KeyF7: "\x1b[18~", - KeyF8: "\x1b[19~", - KeyF9: "\x1b[20~", - KeyF10: "\x1b[21~", - KeyF11: "\x1b[23~", - KeyF12: "\x1b[24~", - KeyBacktab: "\x1b[Z", - Modifiers: 1, - }) -} diff --git a/vendor/github.com/gdamore/tcell/v2/terms_default.go b/vendor/github.com/gdamore/tcell/v2/terms_default.go deleted file mode 100644 index 4ce7637..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terms_default.go +++ /dev/null @@ -1,23 +0,0 @@ -// +build !tcell_minimal - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - // This imports the default terminal entries. To disable, use the - // tcell_minimal build tag. - _ "github.com/gdamore/tcell/v2/terminfo/extended" -) diff --git a/vendor/github.com/gdamore/tcell/v2/terms_dynamic.go b/vendor/github.com/gdamore/tcell/v2/terms_dynamic.go deleted file mode 100644 index 8f0994a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terms_dynamic.go +++ /dev/null @@ -1,37 +0,0 @@ -// +build !tcell_minimal,!nacl,!js,!zos,!plan9,!windows,!android - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - // This imports a dynamic version of the terminal database, which - // is built using infocmp. This relies on a working installation - // of infocmp (typically supplied with ncurses). We only do this - // for systems likely to have that -- i.e. UNIX based hosts. We - // also don't support Android here, because you really don't want - // to run external programs there. Generally the android terminals - // will be automatically included anyway. - "github.com/gdamore/tcell/v2/terminfo" - "github.com/gdamore/tcell/v2/terminfo/dynamic" -) - -func loadDynamicTerminfo(term string) (*terminfo.Terminfo, error) { - ti, _, e := dynamic.LoadTerminfo(term) - if e != nil { - return nil, e - } - return ti, nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/terms_static.go b/vendor/github.com/gdamore/tcell/v2/terms_static.go deleted file mode 100644 index 8b3fe12..0000000 --- a/vendor/github.com/gdamore/tcell/v2/terms_static.go +++ /dev/null @@ -1,27 +0,0 @@ -// +build tcell_minimal nacl js zos plan9 windows android - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "errors" - - "github.com/gdamore/tcell/v2/terminfo" -) - -func loadDynamicTerminfo(_ string) (*terminfo.Terminfo, error) { - return nil, errors.New("terminal type unsupported") -} diff --git a/vendor/github.com/gdamore/tcell/v2/tscreen.go b/vendor/github.com/gdamore/tcell/v2/tscreen.go deleted file mode 100644 index 4674035..0000000 --- a/vendor/github.com/gdamore/tcell/v2/tscreen.go +++ /dev/null @@ -1,1544 +0,0 @@ -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "bytes" - "io" - "os" - "strconv" - "strings" - "sync" - "time" - "unicode/utf8" - - "golang.org/x/text/transform" - - "github.com/gdamore/tcell/v2/terminfo" - - // import the stock terminals - _ "github.com/gdamore/tcell/v2/terminfo/base" -) - -// NewTerminfoScreen returns a Screen that uses the stock TTY interface -// and POSIX terminal control, combined with a terminfo description taken from -// the $TERM environment variable. It returns an error if the terminal -// is not supported for any reason. -// -// For terminals that do not support dynamic resize events, the $LINES -// $COLUMNS environment variables can be set to the actual window size, -// otherwise defaults taken from the terminal database are used. -func NewTerminfoScreen() (Screen, error) { - ti, e := terminfo.LookupTerminfo(os.Getenv("TERM")) - if e != nil { - ti, e = loadDynamicTerminfo(os.Getenv("TERM")) - if e != nil { - return nil, e - } - terminfo.AddTerminfo(ti) - } - t := &tScreen{ti: ti} - - t.keyexist = make(map[Key]bool) - t.keycodes = make(map[string]*tKeyCode) - if len(ti.Mouse) > 0 { - t.mouse = []byte(ti.Mouse) - } - t.prepareKeys() - t.buildAcsMap() - t.sigwinch = make(chan os.Signal, 10) - t.fallback = make(map[rune]string) - for k, v := range RuneFallbacks { - t.fallback[k] = v - } - - return t, nil -} - -// tKeyCode represents a combination of a key code and modifiers. -type tKeyCode struct { - key Key - mod ModMask -} - -// tScreen represents a screen backed by a terminfo implementation. -type tScreen struct { - ti *terminfo.Terminfo - h int - w int - fini bool - cells CellBuffer - in *os.File - out *os.File - buffering bool // true if we are collecting writes to buf instead of sending directly to out - buf bytes.Buffer - curstyle Style - style Style - evch chan Event - sigwinch chan os.Signal - quit chan struct{} - indoneq chan struct{} - keyexist map[Key]bool - keycodes map[string]*tKeyCode - keychan chan []byte - keytimer *time.Timer - keyexpire time.Time - cx int - cy int - mouse []byte - clear bool - cursorx int - cursory int - tiosp *termiosPrivate - wasbtn bool - acs map[rune]string - charset string - encoder transform.Transformer - decoder transform.Transformer - fallback map[rune]string - colors map[Color]Color - palette []Color - truecolor bool - escaped bool - buttondn bool - finiOnce sync.Once - enablePaste string - disablePaste string - - sync.Mutex -} - -func (t *tScreen) Init() error { - t.evch = make(chan Event, 10) - t.indoneq = make(chan struct{}) - t.keychan = make(chan []byte, 10) - t.keytimer = time.NewTimer(time.Millisecond * 50) - t.charset = "UTF-8" - - t.charset = getCharset() - if enc := GetEncoding(t.charset); enc != nil { - t.encoder = enc.NewEncoder() - t.decoder = enc.NewDecoder() - } else { - return ErrNoCharset - } - ti := t.ti - - // environment overrides - w := ti.Columns - h := ti.Lines - if i, _ := strconv.Atoi(os.Getenv("LINES")); i != 0 { - h = i - } - if i, _ := strconv.Atoi(os.Getenv("COLUMNS")); i != 0 { - w = i - } - if e := t.termioInit(); e != nil { - return e - } - - if t.ti.SetFgBgRGB != "" || t.ti.SetFgRGB != "" || t.ti.SetBgRGB != "" { - t.truecolor = true - } - // A user who wants to have his themes honored can - // set this environment variable. - if os.Getenv("TCELL_TRUECOLOR") == "disable" { - t.truecolor = false - } - t.colors = make(map[Color]Color) - t.palette = make([]Color, t.nColors()) - for i := 0; i < t.nColors(); i++ { - t.palette[i] = Color(i) | ColorValid - // identity map for our builtin colors - t.colors[Color(i)|ColorValid] = Color(i) | ColorValid - } - - t.TPuts(ti.EnterCA) - t.TPuts(ti.HideCursor) - t.TPuts(ti.EnableAcs) - t.TPuts(ti.Clear) - - t.quit = make(chan struct{}) - - t.Lock() - t.cx = -1 - t.cy = -1 - t.style = StyleDefault - t.cells.Resize(w, h) - t.cursorx = -1 - t.cursory = -1 - t.resize() - t.Unlock() - - go t.mainLoop() - go t.inputLoop() - - return nil -} - -func (t *tScreen) prepareKeyMod(key Key, mod ModMask, val string) { - if val != "" { - // Do not override codes that already exist - if _, exist := t.keycodes[val]; !exist { - t.keyexist[key] = true - t.keycodes[val] = &tKeyCode{key: key, mod: mod} - } - } -} - -func (t *tScreen) prepareKeyModReplace(key Key, replace Key, mod ModMask, val string) { - if val != "" { - // Do not override codes that already exist - if old, exist := t.keycodes[val]; !exist || old.key == replace { - t.keyexist[key] = true - t.keycodes[val] = &tKeyCode{key: key, mod: mod} - } - } -} - -func (t *tScreen) prepareKeyModXTerm(key Key, val string) { - - if strings.HasPrefix(val, "\x1b[") && strings.HasSuffix(val, "~") { - - // Drop the trailing ~ - val = val[:len(val)-1] - - // These suffixes are calculated assuming Xterm style modifier suffixes. - // Please see https://invisible-island.net/xterm/ctlseqs/ctlseqs.pdf for - // more information (specifically "PC-Style Function Keys"). - t.prepareKeyModReplace(key, key+12, ModShift, val+";2~") - t.prepareKeyModReplace(key, key+48, ModAlt, val+";3~") - t.prepareKeyModReplace(key, key+60, ModAlt|ModShift, val+";4~") - t.prepareKeyModReplace(key, key+24, ModCtrl, val+";5~") - t.prepareKeyModReplace(key, key+36, ModCtrl|ModShift, val+";6~") - t.prepareKeyMod(key, ModAlt|ModCtrl, val+";7~") - t.prepareKeyMod(key, ModShift|ModAlt|ModCtrl, val+";8~") - t.prepareKeyMod(key, ModMeta, val+";9~") - t.prepareKeyMod(key, ModMeta|ModShift, val+";10~") - t.prepareKeyMod(key, ModMeta|ModAlt, val+";11~") - t.prepareKeyMod(key, ModMeta|ModAlt|ModShift, val+";12~") - t.prepareKeyMod(key, ModMeta|ModCtrl, val+";13~") - t.prepareKeyMod(key, ModMeta|ModCtrl|ModShift, val+";14~") - t.prepareKeyMod(key, ModMeta|ModCtrl|ModAlt, val+";15~") - t.prepareKeyMod(key, ModMeta|ModCtrl|ModAlt|ModShift, val+";16~") - } else if strings.HasPrefix(val, "\x1bO") && len(val) == 3 { - val = val[2:] - t.prepareKeyModReplace(key, key+12, ModShift, "\x1b[1;2"+val) - t.prepareKeyModReplace(key, key+48, ModAlt, "\x1b[1;3"+val) - t.prepareKeyModReplace(key, key+24, ModCtrl, "\x1b[1;5"+val) - t.prepareKeyModReplace(key, key+36, ModCtrl|ModShift, "\x1b[1;6"+val) - t.prepareKeyModReplace(key, key+60, ModAlt|ModShift, "\x1b[1;4"+val) - t.prepareKeyMod(key, ModAlt|ModCtrl, "\x1b[1;7"+val) - t.prepareKeyMod(key, ModShift|ModAlt|ModCtrl, "\x1b[1;8"+val) - t.prepareKeyMod(key, ModMeta, "\x1b[1;9"+val) - t.prepareKeyMod(key, ModMeta|ModShift, "\x1b[1;10"+val) - t.prepareKeyMod(key, ModMeta|ModAlt, "\x1b[1;11"+val) - t.prepareKeyMod(key, ModMeta|ModAlt|ModShift, "\x1b[1;12"+val) - t.prepareKeyMod(key, ModMeta|ModCtrl, "\x1b[1;13"+val) - t.prepareKeyMod(key, ModMeta|ModCtrl|ModShift, "\x1b[1;14"+val) - t.prepareKeyMod(key, ModMeta|ModCtrl|ModAlt, "\x1b[1;15"+val) - t.prepareKeyMod(key, ModMeta|ModCtrl|ModAlt|ModShift, "\x1b[1;16"+val) - } -} - -func (t *tScreen) prepareXtermModifiers() { - if t.ti.Modifiers != terminfo.ModifiersXTerm { - return - } - t.prepareKeyModXTerm(KeyRight, t.ti.KeyRight) - t.prepareKeyModXTerm(KeyLeft, t.ti.KeyLeft) - t.prepareKeyModXTerm(KeyUp, t.ti.KeyUp) - t.prepareKeyModXTerm(KeyDown, t.ti.KeyDown) - t.prepareKeyModXTerm(KeyInsert, t.ti.KeyInsert) - t.prepareKeyModXTerm(KeyDelete, t.ti.KeyDelete) - t.prepareKeyModXTerm(KeyPgUp, t.ti.KeyPgUp) - t.prepareKeyModXTerm(KeyPgDn, t.ti.KeyPgDn) - t.prepareKeyModXTerm(KeyHome, t.ti.KeyHome) - t.prepareKeyModXTerm(KeyEnd, t.ti.KeyEnd) - t.prepareKeyModXTerm(KeyF1, t.ti.KeyF1) - t.prepareKeyModXTerm(KeyF2, t.ti.KeyF2) - t.prepareKeyModXTerm(KeyF3, t.ti.KeyF3) - t.prepareKeyModXTerm(KeyF4, t.ti.KeyF4) - t.prepareKeyModXTerm(KeyF5, t.ti.KeyF5) - t.prepareKeyModXTerm(KeyF6, t.ti.KeyF6) - t.prepareKeyModXTerm(KeyF7, t.ti.KeyF7) - t.prepareKeyModXTerm(KeyF8, t.ti.KeyF8) - t.prepareKeyModXTerm(KeyF9, t.ti.KeyF9) - t.prepareKeyModXTerm(KeyF10, t.ti.KeyF10) - t.prepareKeyModXTerm(KeyF11, t.ti.KeyF11) - t.prepareKeyModXTerm(KeyF12, t.ti.KeyF12) -} - -func (t *tScreen) prepareBracketedPaste() { - // Another workaround for lack of reporting in terminfo. - // We assume if the terminal has a mouse entry, that it - // offers bracketed paste. But we allow specific overrides - // via our terminal database. - if t.ti.EnablePaste != "" { - t.enablePaste = t.ti.EnablePaste - t.disablePaste = t.ti.DisablePaste - t.prepareKey(keyPasteStart, t.ti.PasteStart) - t.prepareKey(keyPasteEnd, t.ti.PasteEnd) - } else if t.ti.MouseMode != "" { - t.enablePaste = "\x1b[?2004h" - t.disablePaste = "\x1b[?2004l" - t.prepareKey(keyPasteStart, "\x1b[200~") - t.prepareKey(keyPasteEnd, "\x1b[201~") - } -} - -func (t *tScreen) prepareKey(key Key, val string) { - t.prepareKeyMod(key, ModNone, val) -} - -func (t *tScreen) prepareKeys() { - ti := t.ti - t.prepareKey(KeyBackspace, ti.KeyBackspace) - t.prepareKey(KeyF1, ti.KeyF1) - t.prepareKey(KeyF2, ti.KeyF2) - t.prepareKey(KeyF3, ti.KeyF3) - t.prepareKey(KeyF4, ti.KeyF4) - t.prepareKey(KeyF5, ti.KeyF5) - t.prepareKey(KeyF6, ti.KeyF6) - t.prepareKey(KeyF7, ti.KeyF7) - t.prepareKey(KeyF8, ti.KeyF8) - t.prepareKey(KeyF9, ti.KeyF9) - t.prepareKey(KeyF10, ti.KeyF10) - t.prepareKey(KeyF11, ti.KeyF11) - t.prepareKey(KeyF12, ti.KeyF12) - t.prepareKey(KeyF13, ti.KeyF13) - t.prepareKey(KeyF14, ti.KeyF14) - t.prepareKey(KeyF15, ti.KeyF15) - t.prepareKey(KeyF16, ti.KeyF16) - t.prepareKey(KeyF17, ti.KeyF17) - t.prepareKey(KeyF18, ti.KeyF18) - t.prepareKey(KeyF19, ti.KeyF19) - t.prepareKey(KeyF20, ti.KeyF20) - t.prepareKey(KeyF21, ti.KeyF21) - t.prepareKey(KeyF22, ti.KeyF22) - t.prepareKey(KeyF23, ti.KeyF23) - t.prepareKey(KeyF24, ti.KeyF24) - t.prepareKey(KeyF25, ti.KeyF25) - t.prepareKey(KeyF26, ti.KeyF26) - t.prepareKey(KeyF27, ti.KeyF27) - t.prepareKey(KeyF28, ti.KeyF28) - t.prepareKey(KeyF29, ti.KeyF29) - t.prepareKey(KeyF30, ti.KeyF30) - t.prepareKey(KeyF31, ti.KeyF31) - t.prepareKey(KeyF32, ti.KeyF32) - t.prepareKey(KeyF33, ti.KeyF33) - t.prepareKey(KeyF34, ti.KeyF34) - t.prepareKey(KeyF35, ti.KeyF35) - t.prepareKey(KeyF36, ti.KeyF36) - t.prepareKey(KeyF37, ti.KeyF37) - t.prepareKey(KeyF38, ti.KeyF38) - t.prepareKey(KeyF39, ti.KeyF39) - t.prepareKey(KeyF40, ti.KeyF40) - t.prepareKey(KeyF41, ti.KeyF41) - t.prepareKey(KeyF42, ti.KeyF42) - t.prepareKey(KeyF43, ti.KeyF43) - t.prepareKey(KeyF44, ti.KeyF44) - t.prepareKey(KeyF45, ti.KeyF45) - t.prepareKey(KeyF46, ti.KeyF46) - t.prepareKey(KeyF47, ti.KeyF47) - t.prepareKey(KeyF48, ti.KeyF48) - t.prepareKey(KeyF49, ti.KeyF49) - t.prepareKey(KeyF50, ti.KeyF50) - t.prepareKey(KeyF51, ti.KeyF51) - t.prepareKey(KeyF52, ti.KeyF52) - t.prepareKey(KeyF53, ti.KeyF53) - t.prepareKey(KeyF54, ti.KeyF54) - t.prepareKey(KeyF55, ti.KeyF55) - t.prepareKey(KeyF56, ti.KeyF56) - t.prepareKey(KeyF57, ti.KeyF57) - t.prepareKey(KeyF58, ti.KeyF58) - t.prepareKey(KeyF59, ti.KeyF59) - t.prepareKey(KeyF60, ti.KeyF60) - t.prepareKey(KeyF61, ti.KeyF61) - t.prepareKey(KeyF62, ti.KeyF62) - t.prepareKey(KeyF63, ti.KeyF63) - t.prepareKey(KeyF64, ti.KeyF64) - t.prepareKey(KeyInsert, ti.KeyInsert) - t.prepareKey(KeyDelete, ti.KeyDelete) - t.prepareKey(KeyHome, ti.KeyHome) - t.prepareKey(KeyEnd, ti.KeyEnd) - t.prepareKey(KeyUp, ti.KeyUp) - t.prepareKey(KeyDown, ti.KeyDown) - t.prepareKey(KeyLeft, ti.KeyLeft) - t.prepareKey(KeyRight, ti.KeyRight) - t.prepareKey(KeyPgUp, ti.KeyPgUp) - t.prepareKey(KeyPgDn, ti.KeyPgDn) - t.prepareKey(KeyHelp, ti.KeyHelp) - t.prepareKey(KeyPrint, ti.KeyPrint) - t.prepareKey(KeyCancel, ti.KeyCancel) - t.prepareKey(KeyExit, ti.KeyExit) - t.prepareKey(KeyBacktab, ti.KeyBacktab) - - t.prepareKeyMod(KeyRight, ModShift, ti.KeyShfRight) - t.prepareKeyMod(KeyLeft, ModShift, ti.KeyShfLeft) - t.prepareKeyMod(KeyUp, ModShift, ti.KeyShfUp) - t.prepareKeyMod(KeyDown, ModShift, ti.KeyShfDown) - t.prepareKeyMod(KeyHome, ModShift, ti.KeyShfHome) - t.prepareKeyMod(KeyEnd, ModShift, ti.KeyShfEnd) - t.prepareKeyMod(KeyPgUp, ModShift, ti.KeyShfPgUp) - t.prepareKeyMod(KeyPgDn, ModShift, ti.KeyShfPgDn) - - t.prepareKeyMod(KeyRight, ModCtrl, ti.KeyCtrlRight) - t.prepareKeyMod(KeyLeft, ModCtrl, ti.KeyCtrlLeft) - t.prepareKeyMod(KeyUp, ModCtrl, ti.KeyCtrlUp) - t.prepareKeyMod(KeyDown, ModCtrl, ti.KeyCtrlDown) - t.prepareKeyMod(KeyHome, ModCtrl, ti.KeyCtrlHome) - t.prepareKeyMod(KeyEnd, ModCtrl, ti.KeyCtrlEnd) - - // Sadly, xterm handling of keycodes is somewhat erratic. In - // particular, different codes are sent depending on application - // mode is in use or not, and the entries for many of these are - // simply absent from terminfo on many systems. So we insert - // a number of escape sequences if they are not already used, in - // order to have the widest correct usage. Note that prepareKey - // will not inject codes if the escape sequence is already known. - // We also only do this for terminals that have the application - // mode present. - - // Cursor mode - if ti.EnterKeypad != "" { - t.prepareKey(KeyUp, "\x1b[A") - t.prepareKey(KeyDown, "\x1b[B") - t.prepareKey(KeyRight, "\x1b[C") - t.prepareKey(KeyLeft, "\x1b[D") - t.prepareKey(KeyEnd, "\x1b[F") - t.prepareKey(KeyHome, "\x1b[H") - t.prepareKey(KeyDelete, "\x1b[3~") - t.prepareKey(KeyHome, "\x1b[1~") - t.prepareKey(KeyEnd, "\x1b[4~") - t.prepareKey(KeyPgUp, "\x1b[5~") - t.prepareKey(KeyPgDn, "\x1b[6~") - - // Application mode - t.prepareKey(KeyUp, "\x1bOA") - t.prepareKey(KeyDown, "\x1bOB") - t.prepareKey(KeyRight, "\x1bOC") - t.prepareKey(KeyLeft, "\x1bOD") - t.prepareKey(KeyHome, "\x1bOH") - } - - t.prepareKey(keyPasteStart, ti.PasteStart) - t.prepareKey(keyPasteEnd, ti.PasteEnd) - t.prepareXtermModifiers() - t.prepareBracketedPaste() - -outer: - // Add key mappings for control keys. - for i := 0; i < ' '; i++ { - // Do not insert direct key codes for ambiguous keys. - // For example, ESC is used for lots of other keys, so - // when parsing this we don't want to fast path handling - // of it, but instead wait a bit before parsing it as in - // isolation. - for esc := range t.keycodes { - if []byte(esc)[0] == byte(i) { - continue outer - } - } - - t.keyexist[Key(i)] = true - - mod := ModCtrl - switch Key(i) { - case KeyBS, KeyTAB, KeyESC, KeyCR: - // directly type-able- no control sequence - mod = ModNone - } - t.keycodes[string(rune(i))] = &tKeyCode{key: Key(i), mod: mod} - } -} - -func (t *tScreen) Fini() { - t.finiOnce.Do(t.finish) -} - -func (t *tScreen) finish() { - t.Lock() - defer t.Unlock() - - ti := t.ti - t.cells.Resize(0, 0) - t.TPuts(ti.ShowCursor) - t.TPuts(ti.AttrOff) - t.TPuts(ti.Clear) - t.TPuts(ti.ExitCA) - t.TPuts(ti.ExitKeypad) - t.TPuts(ti.TParm(ti.MouseMode, 0)) - t.TPuts(t.disablePaste) - t.curstyle = styleInvalid - t.clear = false - t.fini = true - - select { - case <-t.quit: - // do nothing, already closed - - default: - close(t.quit) - } - - t.termioFini() -} - -func (t *tScreen) SetStyle(style Style) { - t.Lock() - if !t.fini { - t.style = style - } - t.Unlock() -} - -func (t *tScreen) Clear() { - t.Fill(' ', t.style) -} - -func (t *tScreen) Fill(r rune, style Style) { - t.Lock() - if !t.fini { - t.cells.Fill(r, style) - } - t.Unlock() -} - -func (t *tScreen) SetContent(x, y int, mainc rune, combc []rune, style Style) { - t.Lock() - if !t.fini { - t.cells.SetContent(x, y, mainc, combc, style) - } - t.Unlock() -} - -func (t *tScreen) GetContent(x, y int) (rune, []rune, Style, int) { - t.Lock() - mainc, combc, style, width := t.cells.GetContent(x, y) - t.Unlock() - return mainc, combc, style, width -} - -func (t *tScreen) SetCell(x, y int, style Style, ch ...rune) { - if len(ch) > 0 { - t.SetContent(x, y, ch[0], ch[1:], style) - } else { - t.SetContent(x, y, ' ', nil, style) - } -} - -func (t *tScreen) encodeRune(r rune, buf []byte) []byte { - - nb := make([]byte, 6) - ob := make([]byte, 6) - num := utf8.EncodeRune(ob, r) - ob = ob[:num] - dst := 0 - var err error - if enc := t.encoder; enc != nil { - enc.Reset() - dst, _, err = enc.Transform(nb, ob, true) - } - if err != nil || dst == 0 || nb[0] == '\x1a' { - // Combining characters are elided - if len(buf) == 0 { - if acs, ok := t.acs[r]; ok { - buf = append(buf, []byte(acs)...) - } else if fb, ok := t.fallback[r]; ok { - buf = append(buf, []byte(fb)...) - } else { - buf = append(buf, '?') - } - } - } else { - buf = append(buf, nb[:dst]...) - } - - return buf -} - -func (t *tScreen) sendFgBg(fg Color, bg Color) { - ti := t.ti - if ti.Colors == 0 { - return - } - if fg == ColorReset || bg == ColorReset { - t.TPuts(ti.ResetFgBg) - } - if t.truecolor { - if ti.SetFgBgRGB != "" && fg.IsRGB() && bg.IsRGB() { - r1, g1, b1 := fg.RGB() - r2, g2, b2 := bg.RGB() - t.TPuts(ti.TParm(ti.SetFgBgRGB, - int(r1), int(g1), int(b1), - int(r2), int(g2), int(b2))) - return - } - - if fg.IsRGB() && ti.SetFgRGB != "" { - r, g, b := fg.RGB() - t.TPuts(ti.TParm(ti.SetFgRGB, int(r), int(g), int(b))) - fg = ColorDefault - } - - if bg.IsRGB() && ti.SetBgRGB != "" { - r, g, b := bg.RGB() - t.TPuts(ti.TParm(ti.SetBgRGB, - int(r), int(g), int(b))) - bg = ColorDefault - } - } - - if fg.Valid() { - if v, ok := t.colors[fg]; ok { - fg = v - } else { - v = FindColor(fg, t.palette) - t.colors[fg] = v - fg = v - } - } - - if bg.Valid() { - if v, ok := t.colors[bg]; ok { - bg = v - } else { - v = FindColor(bg, t.palette) - t.colors[bg] = v - bg = v - } - } - - if fg.Valid() && bg.Valid() && ti.SetFgBg != "" { - t.TPuts(ti.TParm(ti.SetFgBg, int(fg&0xff), int(bg&0xff))) - } else { - if fg.Valid() && ti.SetFg != "" { - t.TPuts(ti.TParm(ti.SetFg, int(fg&0xff))) - } - if bg.Valid() && ti.SetBg != "" { - t.TPuts(ti.TParm(ti.SetBg, int(bg&0xff))) - } - } -} - -func (t *tScreen) drawCell(x, y int) int { - - ti := t.ti - - mainc, combc, style, width := t.cells.GetContent(x, y) - if !t.cells.Dirty(x, y) { - return width - } - - if t.cy != y || t.cx != x { - t.TPuts(ti.TGoto(x, y)) - t.cx = x - t.cy = y - } - - if style == StyleDefault { - style = t.style - } - if style != t.curstyle { - fg, bg, attrs := style.Decompose() - - t.TPuts(ti.AttrOff) - - t.sendFgBg(fg, bg) - if attrs&AttrBold != 0 { - t.TPuts(ti.Bold) - } - if attrs&AttrUnderline != 0 { - t.TPuts(ti.Underline) - } - if attrs&AttrReverse != 0 { - t.TPuts(ti.Reverse) - } - if attrs&AttrBlink != 0 { - t.TPuts(ti.Blink) - } - if attrs&AttrDim != 0 { - t.TPuts(ti.Dim) - } - if attrs&AttrItalic != 0 { - t.TPuts(ti.Italic) - } - if attrs&AttrStrikeThrough != 0 { - t.TPuts(ti.StrikeThrough) - } - t.curstyle = style - } - // now emit runes - taking care to not overrun width with a - // wide character, and to ensure that we emit exactly one regular - // character followed up by any residual combing characters - - if width < 1 { - width = 1 - } - - var str string - - buf := make([]byte, 0, 6) - - buf = t.encodeRune(mainc, buf) - for _, r := range combc { - buf = t.encodeRune(r, buf) - } - - str = string(buf) - if width > 1 && str == "?" { - // No FullWidth character support - str = "? " - t.cx = -1 - } - - if x > t.w-width { - // too wide to fit; emit a single space instead - width = 1 - str = " " - } - t.writeString(str) - t.cx += width - t.cells.SetDirty(x, y, false) - if width > 1 { - t.cx = -1 - } - - return width -} - -func (t *tScreen) ShowCursor(x, y int) { - t.Lock() - t.cursorx = x - t.cursory = y - t.Unlock() -} - -func (t *tScreen) HideCursor() { - t.ShowCursor(-1, -1) -} - -func (t *tScreen) showCursor() { - - x, y := t.cursorx, t.cursory - w, h := t.cells.Size() - if x < 0 || y < 0 || x >= w || y >= h { - t.hideCursor() - return - } - t.TPuts(t.ti.TGoto(x, y)) - t.TPuts(t.ti.ShowCursor) - t.cx = x - t.cy = y -} - -// writeString sends a string to the terminal. The string is sent as-is and -// this function does not expand inline padding indications (of the form -// $<[delay]> where [delay] is msec). In order to have these expanded, use -// TPuts. If the screen is "buffering", the string is collected in a buffer, -// with the intention that the entire buffer be sent to the terminal in one -// write operation at some point later. -func (t *tScreen) writeString(s string) { - if t.buffering { - _, _ = io.WriteString(&t.buf, s) - } else { - _, _ = io.WriteString(t.out, s) - } -} - -func (t *tScreen) TPuts(s string) { - if t.buffering { - t.ti.TPuts(&t.buf, s) - } else { - t.ti.TPuts(t.out, s) - } -} - -func (t *tScreen) Show() { - t.Lock() - if !t.fini { - t.resize() - t.draw() - } - t.Unlock() -} - -func (t *tScreen) clearScreen() { - fg, bg, _ := t.style.Decompose() - t.sendFgBg(fg, bg) - t.TPuts(t.ti.Clear) - t.clear = false -} - -func (t *tScreen) hideCursor() { - // does not update cursor position - if t.ti.HideCursor != "" { - t.TPuts(t.ti.HideCursor) - } else { - // No way to hide cursor, stick it - // at bottom right of screen - t.cx, t.cy = t.cells.Size() - t.TPuts(t.ti.TGoto(t.cx, t.cy)) - } -} - -func (t *tScreen) draw() { - // clobber cursor position, because we're gonna change it all - t.cx = -1 - t.cy = -1 - - t.buf.Reset() - t.buffering = true - defer func() { - t.buffering = false - }() - - // hide the cursor while we move stuff around - t.hideCursor() - - if t.clear { - t.clearScreen() - } - - for y := 0; y < t.h; y++ { - for x := 0; x < t.w; x++ { - width := t.drawCell(x, y) - if width > 1 { - if x+1 < t.w { - // this is necessary so that if we ever - // go back to drawing that cell, we - // actually will *draw* it. - t.cells.SetDirty(x+1, y, true) - } - } - x += width - 1 - } - } - - // restore the cursor - t.showCursor() - - _, _ = t.buf.WriteTo(t.out) -} - -func (t *tScreen) EnableMouse() { - if len(t.mouse) != 0 { - t.TPuts(t.ti.TParm(t.ti.MouseMode, 1)) - } -} - -func (t *tScreen) DisableMouse() { - if len(t.mouse) != 0 { - t.TPuts(t.ti.TParm(t.ti.MouseMode, 0)) - } -} - -func (t *tScreen) EnablePaste() { - t.TPuts(t.enablePaste) -} - -func (t *tScreen) DisablePaste() { - t.TPuts(t.disablePaste) -} - -func (t *tScreen) Size() (int, int) { - t.Lock() - w, h := t.w, t.h - t.Unlock() - return w, h -} - -func (t *tScreen) resize() { - if w, h, e := t.getWinSize(); e == nil { - if w != t.w || h != t.h { - t.cx = -1 - t.cy = -1 - - t.cells.Resize(w, h) - t.cells.Invalidate() - t.h = h - t.w = w - ev := NewEventResize(w, h) - _ = t.PostEvent(ev) - } - } -} - -func (t *tScreen) Colors() int { - // this doesn't change, no need for lock - if t.truecolor { - return 1 << 24 - } - return t.ti.Colors -} - -// nColors returns the size of the built-in palette. -// This is distinct from Colors(), as it will generally -// always be a small number. (<= 256) -func (t *tScreen) nColors() int { - return t.ti.Colors -} - -func (t *tScreen) PollEvent() Event { - select { - case <-t.quit: - return nil - case ev := <-t.evch: - return ev - } -} - -// vtACSNames is a map of bytes defined by terminfo that are used in -// the terminals Alternate Character Set to represent other glyphs. -// For example, the upper left corner of the box drawing set can be -// displayed by printing "l" while in the alternate character set. -// Its not quite that simple, since the "l" is the terminfo name, -// and it may be necessary to use a different character based on -// the terminal implementation (or the terminal may lack support for -// this altogether). See buildAcsMap below for detail. -var vtACSNames = map[byte]rune{ - '+': RuneRArrow, - ',': RuneLArrow, - '-': RuneUArrow, - '.': RuneDArrow, - '0': RuneBlock, - '`': RuneDiamond, - 'a': RuneCkBoard, - 'b': '␉', // VT100, Not defined by terminfo - 'c': '␌', // VT100, Not defined by terminfo - 'd': '␋', // VT100, Not defined by terminfo - 'e': '␊', // VT100, Not defined by terminfo - 'f': RuneDegree, - 'g': RunePlMinus, - 'h': RuneBoard, - 'i': RuneLantern, - 'j': RuneLRCorner, - 'k': RuneURCorner, - 'l': RuneULCorner, - 'm': RuneLLCorner, - 'n': RunePlus, - 'o': RuneS1, - 'p': RuneS3, - 'q': RuneHLine, - 'r': RuneS7, - 's': RuneS9, - 't': RuneLTee, - 'u': RuneRTee, - 'v': RuneBTee, - 'w': RuneTTee, - 'x': RuneVLine, - 'y': RuneLEqual, - 'z': RuneGEqual, - '{': RunePi, - '|': RuneNEqual, - '}': RuneSterling, - '~': RuneBullet, -} - -// buildAcsMap builds a map of characters that we translate from Unicode to -// alternate character encodings. To do this, we use the standard VT100 ACS -// maps. This is only done if the terminal lacks support for Unicode; we -// always prefer to emit Unicode glyphs when we are able. -func (t *tScreen) buildAcsMap() { - acsstr := t.ti.AltChars - t.acs = make(map[rune]string) - for len(acsstr) > 2 { - srcv := acsstr[0] - dstv := string(acsstr[1]) - if r, ok := vtACSNames[srcv]; ok { - t.acs[r] = t.ti.EnterAcs + dstv + t.ti.ExitAcs - } - acsstr = acsstr[2:] - } -} - -func (t *tScreen) PostEventWait(ev Event) { - t.evch <- ev -} - -func (t *tScreen) PostEvent(ev Event) error { - select { - case t.evch <- ev: - return nil - default: - return ErrEventQFull - } -} - -func (t *tScreen) clip(x, y int) (int, int) { - w, h := t.cells.Size() - if x < 0 { - x = 0 - } - if y < 0 { - y = 0 - } - if x > w-1 { - x = w - 1 - } - if y > h-1 { - y = h - 1 - } - return x, y -} - -// buildMouseEvent returns an event based on the supplied coordinates and button -// state. Note that the screen's mouse button state is updated based on the -// input to this function (i.e. it mutates the receiver). -func (t *tScreen) buildMouseEvent(x, y, btn int) *EventMouse { - - // XTerm mouse events only report at most one button at a time, - // which may include a wheel button. Wheel motion events are - // reported as single impulses, while other button events are reported - // as separate press & release events. - - button := ButtonNone - mod := ModNone - - // Mouse wheel has bit 6 set, no release events. It should be noted - // that wheel events are sometimes misdelivered as mouse button events - // during a click-drag, so we debounce these, considering them to be - // button press events unless we see an intervening release event. - switch btn & 0x43 { - case 0: - button = Button1 - t.wasbtn = true - case 1: - button = Button3 // Note we prefer to treat right as button 2 - t.wasbtn = true - case 2: - button = Button2 // And the middle button as button 3 - t.wasbtn = true - case 3: - button = ButtonNone - t.wasbtn = false - case 0x40: - if !t.wasbtn { - button = WheelUp - } else { - button = Button1 - } - case 0x41: - if !t.wasbtn { - button = WheelDown - } else { - button = Button2 - } - } - - if btn&0x4 != 0 { - mod |= ModShift - } - if btn&0x8 != 0 { - mod |= ModAlt - } - if btn&0x10 != 0 { - mod |= ModCtrl - } - - // Some terminals will report mouse coordinates outside the - // screen, especially with click-drag events. Clip the coordinates - // to the screen in that case. - x, y = t.clip(x, y) - - return NewEventMouse(x, y, button, mod) -} - -// parseSgrMouse attempts to locate an SGR mouse record at the start of the -// buffer. It returns true, true if it found one, and the associated bytes -// be removed from the buffer. It returns true, false if the buffer might -// contain such an event, but more bytes are necessary (partial match), and -// false, false if the content is definitely *not* an SGR mouse record. -func (t *tScreen) parseSgrMouse(buf *bytes.Buffer, evs *[]Event) (bool, bool) { - - b := buf.Bytes() - - var x, y, btn, state int - dig := false - neg := false - motion := false - i := 0 - val := 0 - - for i = range b { - switch b[i] { - case '\x1b': - if state != 0 { - return false, false - } - state = 1 - - case '\x9b': - if state != 0 { - return false, false - } - state = 2 - - case '[': - if state != 1 { - return false, false - } - state = 2 - - case '<': - if state != 2 { - return false, false - } - val = 0 - dig = false - neg = false - state = 3 - - case '-': - if state != 3 && state != 4 && state != 5 { - return false, false - } - if dig || neg { - return false, false - } - neg = true // stay in state - - case '0', '1', '2', '3', '4', '5', '6', '7', '8', '9': - if state != 3 && state != 4 && state != 5 { - return false, false - } - val *= 10 - val += int(b[i] - '0') - dig = true // stay in state - - case ';': - if neg { - val = -val - } - switch state { - case 3: - btn, val = val, 0 - neg, dig, state = false, false, 4 - case 4: - x, val = val-1, 0 - neg, dig, state = false, false, 5 - default: - return false, false - } - - case 'm', 'M': - if state != 5 { - return false, false - } - if neg { - val = -val - } - y = val - 1 - - motion = (btn & 32) != 0 - btn &^= 32 - if b[i] == 'm' { - // mouse release, clear all buttons - btn |= 3 - btn &^= 0x40 - t.buttondn = false - } else if motion { - /* - * Some broken terminals appear to send - * mouse button one motion events, instead of - * encoding 35 (no buttons) into these events. - * We resolve these by looking for a non-motion - * event first. - */ - if !t.buttondn { - btn |= 3 - btn &^= 0x40 - } - } else { - t.buttondn = true - } - // consume the event bytes - for i >= 0 { - _, _ = buf.ReadByte() - i-- - } - *evs = append(*evs, t.buildMouseEvent(x, y, btn)) - return true, true - } - } - - // incomplete & inconclusive at this point - return true, false -} - -// parseXtermMouse is like parseSgrMouse, but it parses a legacy -// X11 mouse record. -func (t *tScreen) parseXtermMouse(buf *bytes.Buffer, evs *[]Event) (bool, bool) { - - b := buf.Bytes() - - state := 0 - btn := 0 - x := 0 - y := 0 - - for i := range b { - switch state { - case 0: - switch b[i] { - case '\x1b': - state = 1 - case '\x9b': - state = 2 - default: - return false, false - } - case 1: - if b[i] != '[' { - return false, false - } - state = 2 - case 2: - if b[i] != 'M' { - return false, false - } - state++ - case 3: - btn = int(b[i]) - state++ - case 4: - x = int(b[i]) - 32 - 1 - state++ - case 5: - y = int(b[i]) - 32 - 1 - for i >= 0 { - _, _ = buf.ReadByte() - i-- - } - *evs = append(*evs, t.buildMouseEvent(x, y, btn)) - return true, true - } - } - return true, false -} - -func (t *tScreen) parseFunctionKey(buf *bytes.Buffer, evs *[]Event) (bool, bool) { - b := buf.Bytes() - partial := false - for e, k := range t.keycodes { - esc := []byte(e) - if (len(esc) == 1) && (esc[0] == '\x1b') { - continue - } - if bytes.HasPrefix(b, esc) { - // matched - var r rune - if len(esc) == 1 { - r = rune(b[0]) - } - mod := k.mod - if t.escaped { - mod |= ModAlt - t.escaped = false - } - switch k.key { - case keyPasteStart: - *evs = append(*evs, NewEventPaste(true)) - case keyPasteEnd: - *evs = append(*evs, NewEventPaste(false)) - default: - *evs = append(*evs, NewEventKey(k.key, r, mod)) - } - for i := 0; i < len(esc); i++ { - _, _ = buf.ReadByte() - } - return true, true - } - if bytes.HasPrefix(esc, b) { - partial = true - } - } - return partial, false -} - -func (t *tScreen) parseRune(buf *bytes.Buffer, evs *[]Event) (bool, bool) { - b := buf.Bytes() - if b[0] >= ' ' && b[0] <= 0x7F { - // printable ASCII easy to deal with -- no encodings - mod := ModNone - if t.escaped { - mod = ModAlt - t.escaped = false - } - *evs = append(*evs, NewEventKey(KeyRune, rune(b[0]), mod)) - _, _ = buf.ReadByte() - return true, true - } - - if b[0] < 0x80 { - // Low numbered values are control keys, not runes. - return false, false - } - - utf := make([]byte, 12) - for l := 1; l <= len(b); l++ { - t.decoder.Reset() - nOut, nIn, e := t.decoder.Transform(utf, b[:l], true) - if e == transform.ErrShortSrc { - continue - } - if nOut != 0 { - r, _ := utf8.DecodeRune(utf[:nOut]) - if r != utf8.RuneError { - mod := ModNone - if t.escaped { - mod = ModAlt - t.escaped = false - } - *evs = append(*evs, NewEventKey(KeyRune, r, mod)) - } - for nIn > 0 { - _, _ = buf.ReadByte() - nIn-- - } - return true, true - } - } - // Looks like potential escape - return true, false -} - -func (t *tScreen) scanInput(buf *bytes.Buffer, expire bool) { - evs := t.collectEventsFromInput(buf, expire) - - for _, ev := range evs { - t.PostEventWait(ev) - } -} - -// Return an array of Events extracted from the supplied buffer. This is done -// while holding the screen's lock - the events can then be queued for -// application processing with the lock released. -func (t *tScreen) collectEventsFromInput(buf *bytes.Buffer, expire bool) []Event { - - res := make([]Event, 0, 20) - - t.Lock() - defer t.Unlock() - - for { - b := buf.Bytes() - if len(b) == 0 { - buf.Reset() - return res - } - - partials := 0 - - if part, comp := t.parseRune(buf, &res); comp { - continue - } else if part { - partials++ - } - - if part, comp := t.parseFunctionKey(buf, &res); comp { - continue - } else if part { - partials++ - } - - // Only parse mouse records if this term claims to have - // mouse support - - if t.ti.Mouse != "" { - if part, comp := t.parseXtermMouse(buf, &res); comp { - continue - } else if part { - partials++ - } - - if part, comp := t.parseSgrMouse(buf, &res); comp { - continue - } else if part { - partials++ - } - } - - if partials == 0 || expire { - if b[0] == '\x1b' { - if len(b) == 1 { - res = append(res, NewEventKey(KeyEsc, 0, ModNone)) - t.escaped = false - } else { - t.escaped = true - } - _, _ = buf.ReadByte() - continue - } - // Nothing was going to match, or we timed out - // waiting for more data -- just deliver the characters - // to the app & let them sort it out. Possibly we - // should only do this for control characters like ESC. - by, _ := buf.ReadByte() - mod := ModNone - if t.escaped { - t.escaped = false - mod = ModAlt - } - res = append(res, NewEventKey(KeyRune, rune(by), mod)) - continue - } - - // well we have some partial data, wait until we get - // some more - break - } - - return res -} - -func (t *tScreen) mainLoop() { - buf := &bytes.Buffer{} - for { - select { - case <-t.quit: - close(t.indoneq) - return - case <-t.sigwinch: - t.Lock() - t.cx = -1 - t.cy = -1 - t.resize() - t.cells.Invalidate() - t.draw() - t.Unlock() - continue - case <-t.keytimer.C: - // If the timer fired, and the current time - // is after the expiration of the escape sequence, - // then we assume the escape sequence reached it's - // conclusion, and process the chunk independently. - // This lets us detect conflicts such as a lone ESC. - if buf.Len() > 0 { - if time.Now().After(t.keyexpire) { - t.scanInput(buf, true) - } - } - if buf.Len() > 0 { - if !t.keytimer.Stop() { - select { - case <-t.keytimer.C: - default: - } - } - t.keytimer.Reset(time.Millisecond * 50) - } - case chunk := <-t.keychan: - buf.Write(chunk) - t.keyexpire = time.Now().Add(time.Millisecond * 50) - t.scanInput(buf, false) - if !t.keytimer.Stop() { - select { - case <-t.keytimer.C: - default: - } - } - if buf.Len() > 0 { - t.keytimer.Reset(time.Millisecond * 50) - } - } - } -} - -func (t *tScreen) inputLoop() { - - for { - chunk := make([]byte, 128) - n, e := t.in.Read(chunk) - switch e { - case io.EOF: - case nil: - default: - _ = t.PostEvent(NewEventError(e)) - return - } - t.keychan <- chunk[:n] - } -} - -func (t *tScreen) Sync() { - t.Lock() - t.cx = -1 - t.cy = -1 - if !t.fini { - t.resize() - t.clear = true - t.cells.Invalidate() - t.draw() - } - t.Unlock() -} - -func (t *tScreen) CharacterSet() string { - return t.charset -} - -func (t *tScreen) RegisterRuneFallback(orig rune, fallback string) { - t.Lock() - t.fallback[orig] = fallback - t.Unlock() -} - -func (t *tScreen) UnregisterRuneFallback(orig rune) { - t.Lock() - delete(t.fallback, orig) - t.Unlock() -} - -func (t *tScreen) CanDisplay(r rune, checkFallbacks bool) bool { - - if enc := t.encoder; enc != nil { - nb := make([]byte, 6) - ob := make([]byte, 6) - num := utf8.EncodeRune(ob, r) - - enc.Reset() - dst, _, err := enc.Transform(nb, ob[:num], true) - if dst != 0 && err == nil && nb[0] != '\x1A' { - return true - } - } - // Terminal fallbacks always permitted, since we assume they are - // basically nearly perfect renditions. - if _, ok := t.acs[r]; ok { - return true - } - if !checkFallbacks { - return false - } - if _, ok := t.fallback[r]; ok { - return true - } - return false -} - -func (t *tScreen) HasMouse() bool { - return len(t.mouse) != 0 -} - -func (t *tScreen) HasKey(k Key) bool { - if k == KeyRune { - return true - } - return t.keyexist[k] -} - -func (t *tScreen) Resize(int, int, int, int) {} diff --git a/vendor/github.com/gdamore/tcell/v2/tscreen_bsd.go b/vendor/github.com/gdamore/tcell/v2/tscreen_bsd.go deleted file mode 100644 index 85bf2ab..0000000 --- a/vendor/github.com/gdamore/tcell/v2/tscreen_bsd.go +++ /dev/null @@ -1,121 +0,0 @@ -// +build freebsd netbsd openbsd dragonfly - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "os" - "os/signal" - "syscall" - "unsafe" -) - -type termiosPrivate syscall.Termios - -func (t *tScreen) termioInit() error { - var e error - var newtios termiosPrivate - var fd uintptr - var tios uintptr - var ioc uintptr - t.tiosp = &termiosPrivate{} - - if t.in, e = os.OpenFile("/dev/tty", os.O_RDONLY, 0); e != nil { - goto failed - } - if t.out, e = os.OpenFile("/dev/tty", os.O_WRONLY, 0); e != nil { - goto failed - } - - tios = uintptr(unsafe.Pointer(t.tiosp)) - ioc = uintptr(syscall.TIOCGETA) - fd = uintptr(t.out.Fd()) - if _, _, e1 := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioc, tios, 0, 0, 0); e1 != 0 { - e = e1 - goto failed - } - - newtios = *t.tiosp - newtios.Iflag &^= syscall.IGNBRK | syscall.BRKINT | syscall.PARMRK | - syscall.ISTRIP | syscall.INLCR | syscall.IGNCR | - syscall.ICRNL | syscall.IXON - newtios.Oflag &^= syscall.OPOST - newtios.Lflag &^= syscall.ECHO | syscall.ECHONL | syscall.ICANON | - syscall.ISIG | syscall.IEXTEN - newtios.Cflag &^= syscall.CSIZE | syscall.PARENB - newtios.Cflag |= syscall.CS8 - - tios = uintptr(unsafe.Pointer(&newtios)) - - ioc = uintptr(syscall.TIOCSETA) - if _, _, e1 := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioc, tios, 0, 0, 0); e1 != 0 { - e = e1 - goto failed - } - - signal.Notify(t.sigwinch, syscall.SIGWINCH) - - if w, h, e := t.getWinSize(); e == nil && w != 0 && h != 0 { - t.cells.Resize(w, h) - } - - return nil - -failed: - if t.in != nil { - t.in.Close() - } - if t.out != nil { - t.out.Close() - } - return e -} - -func (t *tScreen) termioFini() { - - signal.Stop(t.sigwinch) - - <-t.indoneq - - if t.out != nil { - fd := uintptr(t.out.Fd()) - ioc := uintptr(syscall.TIOCSETAF) - tios := uintptr(unsafe.Pointer(t.tiosp)) - syscall.Syscall6(syscall.SYS_IOCTL, fd, ioc, tios, 0, 0, 0) - t.out.Close() - } - if t.in != nil { - t.in.Close() - } -} - -func (t *tScreen) getWinSize() (int, int, error) { - - fd := uintptr(t.out.Fd()) - dim := [4]uint16{} - dimp := uintptr(unsafe.Pointer(&dim)) - ioc := uintptr(syscall.TIOCGWINSZ) - if _, _, err := syscall.Syscall6(syscall.SYS_IOCTL, - fd, ioc, dimp, 0, 0, 0); err != 0 { - return -1, -1, err - } - return int(dim[1]), int(dim[0]), nil -} - -func (t *tScreen) Beep() error { - t.writeString(string(byte(7))) - return nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/tscreen_darwin.go b/vendor/github.com/gdamore/tcell/v2/tscreen_darwin.go deleted file mode 100644 index 2e30648..0000000 --- a/vendor/github.com/gdamore/tcell/v2/tscreen_darwin.go +++ /dev/null @@ -1,142 +0,0 @@ -// +build darwin - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// The Darwin system is *almost* a real BSD system, but it suffers from -// a brain damaged TTY driver. This TTY driver does not actually -// wake up in poll() or similar calls, which means that we cannot reliably -// shut down the terminal without resorting to obscene custom C code -// and a dedicated poller thread. -// -// So instead, we do a best effort, and simply try to do the close in the -// background. Probably this will cause a leak of two goroutines and -// maybe also the file descriptor, meaning that applications on Darwin -// can't reinitialize the screen, but that's probably a very rare behavior, -// and accepting that is the best of some very poor alternative options. -// -// Maybe someday Apple will fix there tty driver, but its been broken for -// a long time (probably forever) so holding one's breath is contraindicated. - -import ( - "os" - "os/signal" - "syscall" - "unsafe" -) - -type termiosPrivate syscall.Termios - -func (t *tScreen) termioInit() error { - var e error - var newtios termiosPrivate - var fd uintptr - var tios uintptr - var ioc uintptr - t.tiosp = &termiosPrivate{} - - if t.in, e = os.OpenFile("/dev/tty", os.O_RDONLY, 0); e != nil { - goto failed - } - if t.out, e = os.OpenFile("/dev/tty", os.O_WRONLY, 0); e != nil { - goto failed - } - - tios = uintptr(unsafe.Pointer(t.tiosp)) - ioc = uintptr(syscall.TIOCGETA) - fd = uintptr(t.out.Fd()) - if _, _, e1 := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioc, tios, 0, 0, 0); e1 != 0 { - e = e1 - goto failed - } - - newtios = *t.tiosp - newtios.Iflag &^= syscall.IGNBRK | syscall.BRKINT | syscall.PARMRK | - syscall.ISTRIP | syscall.INLCR | syscall.IGNCR | - syscall.ICRNL | syscall.IXON - newtios.Oflag &^= syscall.OPOST - newtios.Lflag &^= syscall.ECHO | syscall.ECHONL | syscall.ICANON | - syscall.ISIG | syscall.IEXTEN - newtios.Cflag &^= syscall.CSIZE | syscall.PARENB - newtios.Cflag |= syscall.CS8 - - tios = uintptr(unsafe.Pointer(&newtios)) - - ioc = uintptr(syscall.TIOCSETA) - if _, _, e1 := syscall.Syscall6(syscall.SYS_IOCTL, fd, ioc, tios, 0, 0, 0); e1 != 0 { - e = e1 - goto failed - } - - signal.Notify(t.sigwinch, syscall.SIGWINCH) - - if w, h, e := t.getWinSize(); e == nil && w != 0 && h != 0 { - t.cells.Resize(w, h) - } - - return nil - -failed: - if t.in != nil { - t.in.Close() - } - if t.out != nil { - t.out.Close() - } - return e -} - -func (t *tScreen) termioFini() { - - signal.Stop(t.sigwinch) - - <-t.indoneq - - if t.out != nil { - fd := uintptr(t.out.Fd()) - ioc := uintptr(syscall.TIOCSETAF) - tios := uintptr(unsafe.Pointer(t.tiosp)) - syscall.Syscall6(syscall.SYS_IOCTL, fd, ioc, tios, 0, 0, 0) - t.out.Close() - } - - // See above -- we background this call which might help, but - // really the tty is probably open. - - go func() { - if t.in != nil { - t.in.Close() - } - }() -} - -func (t *tScreen) getWinSize() (int, int, error) { - - fd := uintptr(t.out.Fd()) - dim := [4]uint16{} - dimp := uintptr(unsafe.Pointer(&dim)) - ioc := uintptr(syscall.TIOCGWINSZ) - if _, _, err := syscall.Syscall6(syscall.SYS_IOCTL, - fd, ioc, dimp, 0, 0, 0); err != 0 { - return -1, -1, err - } - return int(dim[1]), int(dim[0]), nil -} - -func (t *tScreen) Beep() error { - t.writeString(string(byte(7))) - return nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/tscreen_linux.go b/vendor/github.com/gdamore/tcell/v2/tscreen_linux.go deleted file mode 100644 index 6e9866a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/tscreen_linux.go +++ /dev/null @@ -1,147 +0,0 @@ -// +build linux - -// Copyright 2019 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "os" - "os/signal" - "strconv" - "syscall" - - "golang.org/x/sys/unix" -) - -type termiosPrivate struct { - tio *unix.Termios -} - -func (t *tScreen) termioInit() error { - var e error - var raw *unix.Termios - var tio *unix.Termios - - if t.in, e = os.OpenFile("/dev/tty", os.O_RDONLY, 0); e != nil { - goto failed - } - if t.out, e = os.OpenFile("/dev/tty", os.O_WRONLY, 0); e != nil { - goto failed - } - - tio, e = unix.IoctlGetTermios(int(t.out.Fd()), unix.TCGETS) - if e != nil { - goto failed - } - - t.tiosp = &termiosPrivate{tio: tio} - - // make a local copy, to make it raw - raw = &unix.Termios{ - Cflag: tio.Cflag, - Oflag: tio.Oflag, - Iflag: tio.Iflag, - Lflag: tio.Lflag, - Cc: tio.Cc, - } - raw.Iflag &^= (unix.IGNBRK | unix.BRKINT | unix.PARMRK | unix.ISTRIP | - unix.INLCR | unix.IGNCR | unix.ICRNL | unix.IXON) - raw.Oflag &^= unix.OPOST - raw.Lflag &^= (unix.ECHO | unix.ECHONL | unix.ICANON | unix.ISIG | - unix.IEXTEN) - raw.Cflag &^= (unix.CSIZE | unix.PARENB) - raw.Cflag |= unix.CS8 - - // This is setup for blocking reads. In the past we attempted to - // use non-blocking reads, but now a separate input loop and timer - // copes with the problems we had on some systems (BSD/Darwin) - // where close hung forever. - raw.Cc[unix.VMIN] = 1 - raw.Cc[unix.VTIME] = 0 - - e = unix.IoctlSetTermios(int(t.out.Fd()), unix.TCSETS, raw) - if e != nil { - goto failed - } - - signal.Notify(t.sigwinch, syscall.SIGWINCH) - - if w, h, e := t.getWinSize(); e == nil && w != 0 && h != 0 { - t.cells.Resize(w, h) - } - - return nil - -failed: - if t.in != nil { - t.in.Close() - } - if t.out != nil { - t.out.Close() - } - return e -} - -func (t *tScreen) termioFini() { - - signal.Stop(t.sigwinch) - - <-t.indoneq - - if t.out != nil && t.tiosp != nil { - unix.IoctlSetTermios(int(t.out.Fd()), unix.TCSETSF, t.tiosp.tio) - t.out.Close() - } - - if t.in != nil { - t.in.Close() - } -} - -func (t *tScreen) getWinSize() (int, int, error) { - - wsz, err := unix.IoctlGetWinsize(int(t.out.Fd()), unix.TIOCGWINSZ) - if err != nil { - return -1, -1, err - } - cols := int(wsz.Col) - rows := int(wsz.Row) - if cols == 0 { - colsEnv := os.Getenv("COLUMNS") - if colsEnv != "" { - if cols, err = strconv.Atoi(colsEnv); err != nil { - return -1, -1, err - } - } else { - cols = t.ti.Columns - } - } - if rows == 0 { - rowsEnv := os.Getenv("LINES") - if rowsEnv != "" { - if rows, err = strconv.Atoi(rowsEnv); err != nil { - return -1, -1, err - } - } else { - rows = t.ti.Lines - } - } - return cols, rows, nil -} - -func (t *tScreen) Beep() error { - t.writeString(string(byte(7))) - return nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/tscreen_solaris.go b/vendor/github.com/gdamore/tcell/v2/tscreen_solaris.go deleted file mode 100644 index 60b94b9..0000000 --- a/vendor/github.com/gdamore/tcell/v2/tscreen_solaris.go +++ /dev/null @@ -1,122 +0,0 @@ -// +build solaris illumos - -// Copyright 2020 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -import ( - "os" - "os/signal" - "syscall" - - "golang.org/x/sys/unix" -) - -type termiosPrivate struct { - tio *unix.Termios -} - -func (t *tScreen) termioInit() error { - var e error - var raw *unix.Termios - var tio *unix.Termios - - if t.in, e = os.OpenFile("/dev/tty", os.O_RDONLY, 0); e != nil { - goto failed - } - if t.out, e = os.OpenFile("/dev/tty", os.O_WRONLY, 0); e != nil { - goto failed - } - - tio, e = unix.IoctlGetTermios(int(t.out.Fd()), unix.TCGETS) - if e != nil { - goto failed - } - - t.tiosp = &termiosPrivate{tio: tio} - - // make a local copy, to make it raw - raw = &unix.Termios{ - Cflag: tio.Cflag, - Oflag: tio.Oflag, - Iflag: tio.Iflag, - Lflag: tio.Lflag, - Cc: tio.Cc, - } - - raw.Iflag &^= (unix.IGNBRK | unix.BRKINT | unix.PARMRK | unix.INLCR | - unix.IGNCR | unix.ICRNL | unix.IXON) - raw.Oflag &^= unix.OPOST - raw.Lflag &^= (unix.ECHO | unix.ECHONL | unix.ICANON | unix.ISIG | unix.IEXTEN) - raw.Cflag &^= (unix.CSIZE | unix.PARENB) - raw.Cflag |= unix.CS8 - - // This is setup for blocking reads. In the past we attempted to - // use non-blocking reads, but now a separate input loop and timer - // copes with the problems we had on some systems (BSD/Darwin) - // where close hung forever. - raw.Cc[unix.VMIN] = 1 - raw.Cc[unix.VTIME] = 0 - - e = unix.IoctlSetTermios(int(t.out.Fd()), unix.TCSETS, raw) - if e != nil { - goto failed - } - - signal.Notify(t.sigwinch, syscall.SIGWINCH) - - if w, h, e := t.getWinSize(); e == nil && w != 0 && h != 0 { - t.cells.Resize(w, h) - } - - return nil - -failed: - if t.in != nil { - t.in.Close() - } - if t.out != nil { - t.out.Close() - } - return e -} - -func (t *tScreen) termioFini() { - - signal.Stop(t.sigwinch) - - <-t.indoneq - - if t.out != nil && t.tiosp != nil { - unix.IoctlSetTermios(int(t.out.Fd()), unix.TCSETSF, t.tiosp.tio) - t.out.Close() - } - if t.in != nil { - t.in.Close() - } -} - -func (t *tScreen) getWinSize() (int, int, error) { - wsz, err := unix.IoctlGetWinsize(int(t.out.Fd()), unix.TIOCGWINSZ) - if err != nil { - return -1, -1, err - } - return int(wsz.Col), int(wsz.Row), nil -} - -func (t *tScreen) Beep() error { - t.writeString(string(byte(7))) - return nil -} diff --git a/vendor/github.com/gdamore/tcell/v2/tscreen_stub.go b/vendor/github.com/gdamore/tcell/v2/tscreen_stub.go deleted file mode 100644 index 0c7d012..0000000 --- a/vendor/github.com/gdamore/tcell/v2/tscreen_stub.go +++ /dev/null @@ -1,36 +0,0 @@ -// +build nacl plan9 - -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// This stub file is for systems that have no termios. - -type termiosPrivate struct{} - -func (t *tScreen) termioInit() error { - return ErrNoScreen -} - -func (t *tScreen) termioFini() { -} - -func (t *tScreen) getWinSize() (int, int, error) { - return 0, 0, ErrNoScreen -} - -func (t *tScreen) Beep() error { - return ErrNoScreen -} diff --git a/vendor/github.com/gdamore/tcell/v2/tscreen_windows.go b/vendor/github.com/gdamore/tcell/v2/tscreen_windows.go deleted file mode 100644 index e0ae2ee..0000000 --- a/vendor/github.com/gdamore/tcell/v2/tscreen_windows.go +++ /dev/null @@ -1,44 +0,0 @@ -// +build windows - -// Copyright 2015 The TCell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package tcell - -// On Windows we don't have support for termios. We probably could, and -// may should, in a cygwin type environment. Its not clear how to make -// this all work nicely with both cygwin and Windows console, so we -// decline to do so here. - -func (t *tScreen) termioInit() error { - return ErrNoScreen -} - -func (t *tScreen) termioFini() { - return -} - -func (t *tScreen) getWinSize() (int, int, error) { - return 0, 0, ErrNoScreen -} - -func (t *tScreen) getCharset() string { - return "UTF-16LE" -} - -func (t *tScreen) Beep() error { - return ErrNoScreen -} - -type termiosPrivate struct{} diff --git a/vendor/github.com/gdamore/tcell/v2/views/README.md b/vendor/github.com/gdamore/tcell/v2/views/README.md deleted file mode 100644 index 694b9a6..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/README.md +++ /dev/null @@ -1,7 +0,0 @@ -## tcell views - -This package provides some enhanced functionality on top of base tcell. -In particular, support for logical views, and a few different kinds of -widgets like title bars, and scrollable areas, are provided. - -These make up a higher level interface than tcell itself. diff --git a/vendor/github.com/gdamore/tcell/v2/views/_demos/cellview.go b/vendor/github.com/gdamore/tcell/v2/views/_demos/cellview.go deleted file mode 100644 index 8e30686..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/_demos/cellview.go +++ /dev/null @@ -1,222 +0,0 @@ -// +build ignore - -// Copyright 2016 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package main - -import ( - "fmt" - "os" - - "github.com/gdamore/tcell/v2" - "github.com/gdamore/tcell/v2/views" -) - -var app = &views.Application{} -var window = &mainWindow{} - -type model struct { - x int - y int - endx int - endy int - hide bool - enab bool - loc string -} - -func (m *model) GetBounds() (int, int) { - return m.endx, m.endy -} - -func (m *model) MoveCursor(offx, offy int) { - m.x += offx - m.y += offy - m.limitCursor() -} - -func (m *model) limitCursor() { - if m.x < 0 { - m.x = 0 - } - if m.x > m.endx-1 { - m.x = m.endx - 1 - } - if m.y < 0 { - m.y = 0 - } - if m.y > m.endy-1 { - m.y = m.endy - 1 - } - m.loc = fmt.Sprintf("Cursor is %d,%d", m.x, m.y) -} - -func (m *model) GetCursor() (int, int, bool, bool) { - return m.x, m.y, m.enab, !m.hide -} - -func (m *model) SetCursor(x int, y int) { - m.x = x - m.y = y - - m.limitCursor() -} - -func (m *model) GetCell(x, y int) (rune, tcell.Style, []rune, int) { - dig := []rune{'0', '1', '2', '3', '4', '5', '6', '7', '8', '9'} - var ch rune - style := tcell.StyleDefault - if x >= 60 || y >= 15 { - return ch, style, nil, 1 - } - colors := []tcell.Color{ - tcell.ColorWhite, - tcell.ColorGreen, - tcell.ColorMaroon, - tcell.ColorNavy, - tcell.ColorOlive, - } - if y == 0 && x < len(m.loc) { - style = style. - Foreground(tcell.ColorWhite). - Background(tcell.ColorLime) - ch = rune(m.loc[x]) - } else { - ch = dig[(x)%len(dig)] - style = style. - Foreground(colors[(y)%len(colors)]). - Background(tcell.ColorBlack) - } - return ch, style, nil, 1 -} - -type mainWindow struct { - main *views.CellView - keybar *views.SimpleStyledText - status *views.SimpleStyledTextBar - model *model - - views.Panel -} - -func (a *mainWindow) HandleEvent(ev tcell.Event) bool { - - switch ev := ev.(type) { - case *tcell.EventKey: - switch ev.Key() { - case tcell.KeyCtrlL: - app.Refresh() - return true - case tcell.KeyRune: - switch ev.Rune() { - case 'Q', 'q': - app.Quit() - return true - case 'S', 's': - a.model.hide = false - a.updateKeys() - return true - case 'H', 'h': - a.model.hide = true - a.updateKeys() - return true - case 'E', 'e': - a.model.enab = true - a.updateKeys() - return true - case 'D', 'd': - a.model.enab = false - a.updateKeys() - return true - } - } - } - return a.Panel.HandleEvent(ev) -} - -func (a *mainWindow) Draw() { - a.status.SetLeft(a.model.loc) - a.Panel.Draw() -} - -func (a *mainWindow) updateKeys() { - m := a.model - w := "[%AQ%N] Quit" - if !m.enab { - w += " [%AE%N] Enable cursor" - } else { - w += " [%AD%N] Disable cursor" - if !m.hide { - w += " [%AH%N] Hide cursor" - } else { - w += " [%AS%N] Show cursor" - } - } - a.keybar.SetMarkup(w) - app.Update() -} - -func main() { - - window.model = &model{endx: 60, endy: 15} - - title := views.NewTextBar() - title.SetStyle(tcell.StyleDefault. - Background(tcell.ColorTeal). - Foreground(tcell.ColorWhite)) - title.SetCenter("CellView Test", tcell.StyleDefault) - title.SetRight("Example v1.0", tcell.StyleDefault) - - window.keybar = views.NewSimpleStyledText() - window.keybar.RegisterStyle('N', tcell.StyleDefault. - Background(tcell.ColorSilver). - Foreground(tcell.ColorBlack)) - window.keybar.RegisterStyle('A', tcell.StyleDefault. - Background(tcell.ColorSilver). - Foreground(tcell.ColorRed)) - - window.status = views.NewSimpleStyledTextBar() - window.status.SetStyle(tcell.StyleDefault. - Background(tcell.ColorBlue). - Foreground(tcell.ColorYellow)) - window.status.RegisterLeftStyle('N', tcell.StyleDefault. - Background(tcell.ColorYellow). - Foreground(tcell.ColorBlack)) - - window.status.SetLeft("My status is here.") - window.status.SetRight("%UCellView%N demo!") - window.status.SetCenter("Cen%ST%Ner") - - window.main = views.NewCellView() - window.main.SetModel(window.model) - window.main.SetStyle(tcell.StyleDefault. - Background(tcell.ColorBlack)) - - window.SetMenu(window.keybar) - window.SetTitle(title) - window.SetContent(window.main) - window.SetStatus(window.status) - - window.updateKeys() - - app.SetStyle(tcell.StyleDefault. - Foreground(tcell.ColorWhite). - Background(tcell.ColorBlack)) - app.SetRootWidget(window) - if e := app.Run(); e != nil { - fmt.Fprintln(os.Stderr, e.Error()) - os.Exit(1) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/_demos/hbox.go b/vendor/github.com/gdamore/tcell/v2/views/_demos/hbox.go deleted file mode 100644 index 2d38f53..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/_demos/hbox.go +++ /dev/null @@ -1,88 +0,0 @@ -// +build ignore - -// Copyright 2015 The Tops'l Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package main - -import ( - "fmt" - "os" - - "github.com/gdamore/tcell/v2" - "github.com/gdamore/tcell/v2/views" -) - -type boxL struct { - views.BoxLayout -} - -var app = &views.Application{} -var box = &boxL{} - -func (m *boxL) HandleEvent(ev tcell.Event) bool { - switch ev := ev.(type) { - case *tcell.EventKey: - if ev.Key() == tcell.KeyEscape { - app.Quit() - return true - } - } - return m.BoxLayout.HandleEvent(ev) -} - -func main() { - - title := &views.TextBar{} - title.SetStyle(tcell.StyleDefault. - Background(tcell.ColorYellow). - Foreground(tcell.ColorBlack)) - title.SetCenter("Horizontal Boxes", tcell.StyleDefault) - title.SetLeft("ESC to exit", tcell.StyleDefault. - Background(tcell.ColorBlue). - Foreground(tcell.ColorWhite)) - title.SetRight("==>X", tcell.StyleDefault) - - inner := views.NewBoxLayout(views.Horizontal) - - l := views.NewText() - m := views.NewText() - r := views.NewText() - - l.SetText("Left (0.0)") - m.SetText("Middle (0.7)") - r.SetText("Right (0.3)") - l.SetStyle(tcell.StyleDefault.Foreground(tcell.ColorWhite). - Background(tcell.ColorRed)) - m.SetStyle(tcell.StyleDefault.Foreground(tcell.ColorWhite). - Background(tcell.ColorLime)) - r.SetStyle(tcell.StyleDefault.Foreground(tcell.ColorWhite). - Background(tcell.ColorBlue)) - l.SetAlignment(views.AlignBegin) - m.SetAlignment(views.AlignMiddle) - r.SetAlignment(views.AlignEnd) - - inner.AddWidget(l, 0) - inner.AddWidget(m, 0.7) - inner.AddWidget(r, 0.3) - - box.SetOrientation(views.Vertical) - box.AddWidget(title, 0) - box.AddWidget(inner, 1) - app.SetRootWidget(box) - if e := app.Run(); e != nil { - fmt.Fprintln(os.Stderr, e.Error()) - os.Exit(1) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/_demos/vbox.go b/vendor/github.com/gdamore/tcell/v2/views/_demos/vbox.go deleted file mode 100644 index 587ca0d..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/_demos/vbox.go +++ /dev/null @@ -1,81 +0,0 @@ -// +build ignore - -// Copyright 2015 The Tops'l Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package main - -import ( - "fmt" - "os" - - "github.com/gdamore/tcell/v2" - "github.com/gdamore/tcell/v2/views" -) - -type boxL struct { - views.BoxLayout -} - -var box = &boxL{} -var app = &views.Application{} - -func (m *boxL) HandleEvent(ev tcell.Event) bool { - switch ev := ev.(type) { - case *tcell.EventKey: - if ev.Key() == tcell.KeyEscape { - app.Quit() - return true - } - } - return m.BoxLayout.HandleEvent(ev) -} - -func main() { - - title := views.NewTextBar() - title.SetStyle(tcell.StyleDefault. - Foreground(tcell.ColorBlack). - Background(tcell.ColorYellow)) - title.SetCenter("Vertical Layout", tcell.StyleDefault) - top := views.NewText() - mid := views.NewText() - bot := views.NewText() - - top.SetText("Top-Right (0.0)\nLine Two") - mid.SetText("Center (0.7)") - bot.SetText("Bottom-Left (0.3)") - top.SetStyle(tcell.StyleDefault.Foreground(tcell.ColorWhite). - Background(tcell.ColorRed)) - mid.SetStyle(tcell.StyleDefault.Foreground(tcell.ColorWhite). - Background(tcell.ColorLime)) - bot.SetStyle(tcell.StyleDefault.Foreground(tcell.ColorWhite). - Background(tcell.ColorBlue)) - - top.SetAlignment(views.VAlignTop | views.HAlignRight) - mid.SetAlignment(views.VAlignCenter | views.HAlignCenter) - bot.SetAlignment(views.VAlignBottom | views.HAlignLeft) - - box.SetOrientation(views.Vertical) - box.AddWidget(title, 0) - box.AddWidget(top, 0) - box.AddWidget(mid, 0.7) - box.AddWidget(bot, 0.3) - - app.SetRootWidget(box) - if e := app.Run(); e != nil { - fmt.Fprintln(os.Stderr, e.Error()) - os.Exit(1) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/app.go b/vendor/github.com/gdamore/tcell/v2/views/app.go deleted file mode 100644 index 239fe05..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/app.go +++ /dev/null @@ -1,195 +0,0 @@ -// Copyright 2018 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "sync" - - "github.com/gdamore/tcell/v2" -) - -// Application represents an event-driven application running on a screen. -type Application struct { - widget Widget - screen tcell.Screen - style tcell.Style - err error - wg sync.WaitGroup -} - -// SetRootWidget sets the primary (root, main) Widget to be displayed. -func (app *Application) SetRootWidget(widget Widget) { - app.widget = widget -} - -// initialize initializes the application. It will normally attempt to -// allocate a default screen if one is not already established. -func (app *Application) initialize() error { - if app.screen == nil { - if app.screen, app.err = tcell.NewScreen(); app.err != nil { - return app.err - } - app.screen.SetStyle(app.style) - } - return nil -} - -// Quit causes the application to shutdown gracefully. It does not wait -// for the application to exit, but returns immediately. -func (app *Application) Quit() { - ev := &eventAppQuit{} - ev.SetEventNow() - if scr := app.screen; scr != nil { - go func() { scr.PostEventWait(ev) }() - } -} - -// Refresh causes the application forcibly redraw everything. Use this -// to clear up screen corruption, etc. -func (app *Application) Refresh() { - ev := &eventAppRefresh{} - ev.SetEventNow() - if scr := app.screen; scr != nil { - go func() { scr.PostEventWait(ev) }() - } -} - -// Update asks the application to draw any screen updates that have not -// been drawn yet. -func (app *Application) Update() { - ev := &eventAppUpdate{} - ev.SetEventNow() - if scr := app.screen; scr != nil { - go func() { scr.PostEventWait(ev) }() - } -} - -// PostFunc posts a function to be executed in the context of the -// application's event loop. Functions that need to update displayed -// state, etc. can do this to avoid holding locks. -func (app *Application) PostFunc(fn func()) { - ev := &eventAppFunc{fn: fn} - ev.SetEventNow() - if scr := app.screen; scr != nil { - go func() { scr.PostEventWait(ev) }() - } -} - -// SetScreen sets the screen to use for the application. This must be -// done before the application starts to run or is initialized. -func (app *Application) SetScreen(scr tcell.Screen) { - if app.screen == nil { - app.screen = scr - app.err = nil - } -} - -// SetStyle sets the default style (background) to be used for Widgets -// that have not specified any other style. -func (app *Application) SetStyle(style tcell.Style) { - app.style = style - if app.screen != nil { - app.screen.SetStyle(style) - } -} - -func (app *Application) run() { - - screen := app.screen - widget := app.widget - - if widget == nil { - app.wg.Done() - return - } - if screen == nil { - if e := app.initialize(); e != nil { - app.wg.Done() - return - } - screen = app.screen - } - defer func() { - screen.Fini() - app.wg.Done() - }() - screen.Init() - screen.Clear() - widget.SetView(screen) - -loop: - for { - if widget = app.widget; widget == nil { - break - } - widget.Draw() - screen.Show() - - ev := screen.PollEvent() - switch nev := ev.(type) { - case *eventAppQuit: - break loop - case *eventAppUpdate: - screen.Show() - case *eventAppRefresh: - screen.Sync() - case *eventAppFunc: - nev.fn() - case *tcell.EventResize: - screen.Sync() - widget.Resize() - default: - widget.HandleEvent(ev) - } - } -} - -// Start starts the application loop, initializing the screen -// and starting the Event loop. The application will run in a goroutine -// until Quit is called. -func (app *Application) Start() { - app.wg.Add(1) - go app.run() -} - -// Wait waits until the application finishes. -func (app *Application) Wait() error { - app.wg.Wait() - return app.err -} - -// Run runs the application, waiting until the application loop exits. -// It is equivalent to app.Start() followed by app.Wait() -func (app *Application) Run() error { - app.Start() - return app.Wait() -} - -type eventAppUpdate struct { - tcell.EventTime -} - -type eventAppQuit struct { - tcell.EventTime -} - -type eventAppRefresh struct { - tcell.EventTime -} - -type eventAppFunc struct { - tcell.EventTime - fn func() -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/boxlayout.go b/vendor/github.com/gdamore/tcell/v2/views/boxlayout.go deleted file mode 100644 index 47093b5..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/boxlayout.go +++ /dev/null @@ -1,331 +0,0 @@ -// Copyright 2016 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "github.com/gdamore/tcell/v2" -) - -// BoxLayout is a container Widget that lays out its child widgets in -// either a horizontal row or a vertical column. -type BoxLayout struct { - view View - orient Orientation - style tcell.Style // backing style - cells []*boxLayoutCell - width int - height int - changed bool - - WidgetWatchers -} - -type boxLayoutCell struct { - widget Widget - fill float64 // fill factor - 0.0 means no expansion - pad int // count of padding spaces (stretch) - frac float64 // calculated residual spacing, used internally - view *ViewPort -} - -func (b *BoxLayout) hLayout() { - w, h := b.view.Size() - - totf := 0.0 - for _, c := range b.cells { - x, y := c.widget.Size() - totf += c.fill - b.width += x - if y > b.height { - b.height = y - } - c.pad = 0 - c.frac = 0 - } - - extra := w - b.width - if extra < 0 { - extra = 0 - } - resid := extra - if totf == 0 { - resid = 0 - } - - for _, c := range b.cells { - if c.fill > 0 { - c.frac = float64(extra) * c.fill / totf - c.pad = int(c.frac) - c.frac -= float64(c.pad) - resid -= c.pad - } - } - - // Distribute any left over padding. We try to give it to the - // the cells with the highest residual fraction. It should be - // the case that no single cell gets more than one more cell. - for resid > 0 { - var best *boxLayoutCell - for _, c := range b.cells { - if c.fill == 0 { - continue - } - if best == nil || c.frac > best.frac { - best = c - } - } - best.pad++ - best.frac = 0 - resid-- - } - - x, y, xinc := 0, 0, 0 - for _, c := range b.cells { - cw, _ := c.widget.Size() - - xinc = cw + c.pad - cw += c.pad - - c.view.Resize(x, y, cw, h) - c.widget.Resize() - x += xinc - } -} - -func (b *BoxLayout) vLayout() { - w, h := b.view.Size() - - totf := 0.0 - for _, c := range b.cells { - x, y := c.widget.Size() - b.height += y - totf += c.fill - if x > b.width { - b.width = x - } - c.pad = 0 - c.frac = 0 - } - - extra := h - b.height - if extra < 0 { - extra = 0 - } - - resid := extra - if totf == 0 { - resid = 0 - } - - for _, c := range b.cells { - if c.fill > 0 { - c.frac = float64(extra) * c.fill / totf - c.pad = int(c.frac) - c.frac -= float64(c.pad) - resid -= c.pad - } - } - - // Distribute any left over padding. We try to give it to the - // the cells with the highest residual fraction. It should be - // the case that no single cell gets more than one more cell. - for resid > 0 { - var best *boxLayoutCell - for _, c := range b.cells { - if c.fill == 0 { - continue - } - if best == nil || c.frac > best.frac { - best = c - } - } - best.pad++ - best.frac = 0 - resid-- - } - - x, y, yinc := 0, 0, 0 - for _, c := range b.cells { - _, ch := c.widget.Size() - - yinc = ch + c.pad - ch += c.pad - c.view.Resize(x, y, w, ch) - c.widget.Resize() - y += yinc - } -} - -func (b *BoxLayout) layout() { - if b.view == nil { - return - } - b.width, b.height = 0, 0 - switch b.orient { - case Horizontal: - b.hLayout() - case Vertical: - b.vLayout() - default: - panic("Bad orientation") - } - b.changed = false -} - -// Resize adjusts the layout when the underlying View changes size. -func (b *BoxLayout) Resize() { - b.layout() - - // Now also let the children know we resized. - for i := range b.cells { - b.cells[i].widget.Resize() - } - b.PostEventWidgetResize(b) -} - -// Draw is called to update the displayed content. -func (b *BoxLayout) Draw() { - - if b.view == nil { - return - } - if b.changed { - b.layout() - } - b.view.Fill(' ', b.style) - for i := range b.cells { - b.cells[i].widget.Draw() - } -} - -// Size returns the preferred size in character cells (width, height). -func (b *BoxLayout) Size() (int, int) { - return b.width, b.height -} - -// SetView sets the View object used for the text bar. -func (b *BoxLayout) SetView(view View) { - b.changed = true - b.view = view - for _, c := range b.cells { - c.view.SetView(view) - } -} - -// HandleEvent implements a tcell.EventHandler. The only events -// we care about are Widget change events from our children. We -// watch for those so that if the child changes, we can arrange -// to update our layout. -func (b *BoxLayout) HandleEvent(ev tcell.Event) bool { - switch ev.(type) { - case *EventWidgetContent: - // This can only have come from one of our children. - b.changed = true - b.PostEventWidgetContent(b) - return true - } - for _, c := range b.cells { - if c.widget.HandleEvent(ev) { - return true - } - } - return false -} - -// AddWidget adds a widget to the end of the BoxLayout. -func (b *BoxLayout) AddWidget(widget Widget, fill float64) { - c := &boxLayoutCell{ - widget: widget, - fill: fill, - view: NewViewPort(b.view, 0, 0, 0, 0), - } - widget.SetView(c.view) - b.cells = append(b.cells, c) - b.changed = true - widget.Watch(b) - b.layout() - b.PostEventWidgetContent(b) -} - -// InsertWidget inserts a widget at the given offset. Offset 0 is the -// front. If the index is longer than the number of widgets, then it -// just gets appended to the end. -func (b *BoxLayout) InsertWidget(index int, widget Widget, fill float64) { - c := &boxLayoutCell{ - widget: widget, - fill: fill, - view: NewViewPort(b.view, 0, 0, 0, 0), - } - c.widget.SetView(c.view) - if index < 0 { - index = 0 - } - if index > len(b.cells) { - index = len(b.cells) - } - b.cells = append(b.cells, c) - copy(b.cells[index+1:], b.cells[index:]) - b.cells[index] = c - widget.Watch(b) - b.layout() - b.PostEventWidgetContent(b) -} - -// RemoveWidget removes a Widget from the layout. -func (b *BoxLayout) RemoveWidget(widget Widget) { - changed := false - for i := 0; i < len(b.cells); i++ { - if b.cells[i].widget == widget { - b.cells = append(b.cells[:i], b.cells[i+1:]...) - changed = true - } - } - if !changed { - return - } - b.changed = true - widget.Unwatch(b) - b.layout() - b.PostEventWidgetContent(b) -} - -// Widgets returns the list of Widgets for this BoxLayout. -func (b *BoxLayout) Widgets() []Widget { - w := make([]Widget, 0, len(b.cells)) - for _, c := range b.cells { - w = append(w, c.widget) - } - return w -} - -// SetOrientation sets the orientation as either Horizontal or Vertical. -func (b *BoxLayout) SetOrientation(orient Orientation) { - if b.orient != orient { - b.orient = orient - b.changed = true - b.PostEventWidgetContent(b) - } -} - -// SetStyle sets the style used. -func (b *BoxLayout) SetStyle(style tcell.Style) { - b.style = style - b.PostEventWidgetContent(b) -} - -// NewBoxLayout creates an empty BoxLayout. -func NewBoxLayout(orient Orientation) *BoxLayout { - return &BoxLayout{orient: orient} -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/cellarea.go b/vendor/github.com/gdamore/tcell/v2/views/cellarea.go deleted file mode 100644 index 68ff9d6..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/cellarea.go +++ /dev/null @@ -1,318 +0,0 @@ -// Copyright 2016 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "sync" - - "github.com/gdamore/tcell/v2" -) - -// CellModel models the content of a CellView. The dimensions used within -// a CellModel are always logical, and have origin 0, 0. -type CellModel interface { - GetCell(x, y int) (rune, tcell.Style, []rune, int) - GetBounds() (int, int) - SetCursor(int, int) - GetCursor() (int, int, bool, bool) - MoveCursor(offx, offy int) -} - -// CellView is a flexible view of a CellModel, offering both cursor -// management and a panning. -type CellView struct { - port *ViewPort - view View - content Widget - contentV *ViewPort - style tcell.Style - lines []string - model CellModel - once sync.Once - - WidgetWatchers -} - -// Draw draws the content. -func (a *CellView) Draw() { - - port := a.port - model := a.model - port.Fill(' ', a.style) - - if a.view == nil { - return - } - if model == nil { - return - } - vw, vh := a.view.Size() - for y := 0; y < vh; y++ { - for x := 0; x < vw; x++ { - a.view.SetContent(x, y, ' ', nil, a.style) - } - } - - ex, ey := model.GetBounds() - vx, vy := port.Size() - if ex < vx { - ex = vx - } - if ey < vy { - ey = vy - } - - cx, cy, en, sh := a.model.GetCursor() - for y := 0; y < ey; y++ { - for x := 0; x < ex; x++ { - ch, style, comb, wid := model.GetCell(x, y) - if ch == 0 { - ch = ' ' - style = a.style - } - if en && x == cx && y == cy && sh { - style = style.Reverse(true) - } - port.SetContent(x, y, ch, comb, style) - x += wid - 1 - } - } -} - -func (a *CellView) keyUp() { - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollUp(1) - return - } - a.model.MoveCursor(0, -1) - a.MakeCursorVisible() -} - -func (a *CellView) keyDown() { - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollDown(1) - return - } - a.model.MoveCursor(0, 1) - a.MakeCursorVisible() -} - -func (a *CellView) keyLeft() { - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollLeft(1) - return - } - a.model.MoveCursor(-1, 0) - a.MakeCursorVisible() -} - -func (a *CellView) keyRight() { - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollRight(1) - return - } - a.model.MoveCursor(+1, 0) - a.MakeCursorVisible() -} - -func (a *CellView) keyPgUp() { - _, vy := a.port.Size() - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollUp(vy) - return - } - a.model.MoveCursor(0, -vy) - a.MakeCursorVisible() -} - -func (a *CellView) keyPgDn() { - _, vy := a.port.Size() - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollDown(vy) - return - } - a.model.MoveCursor(0, +vy) - a.MakeCursorVisible() -} - -func (a *CellView) keyHome() { - vx, vy := a.model.GetBounds() - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollUp(vy) - a.port.ScrollLeft(vx) - return - } - a.model.SetCursor(0, 0) - a.MakeCursorVisible() -} - -func (a *CellView) keyEnd() { - vx, vy := a.model.GetBounds() - if _, _, en, _ := a.model.GetCursor(); !en { - a.port.ScrollDown(vy) - a.port.ScrollRight(vx) - return - } - a.model.SetCursor(vx, vy) - a.MakeCursorVisible() -} - -// MakeCursorVisible ensures that the cursor is visible, panning the ViewPort -// as necessary, if the cursor is enabled. -func (a *CellView) MakeCursorVisible() { - if a.model == nil { - return - } - x, y, enabled, _ := a.model.GetCursor() - if enabled { - a.MakeVisible(x, y) - } -} - -// HandleEvent handles events. In particular, it handles certain key events -// to move the cursor or pan the view. -func (a *CellView) HandleEvent(e tcell.Event) bool { - if a.model == nil { - return false - } - switch e := e.(type) { - case *tcell.EventKey: - switch e.Key() { - case tcell.KeyUp, tcell.KeyCtrlP: - a.keyUp() - return true - case tcell.KeyDown, tcell.KeyCtrlN: - a.keyDown() - return true - case tcell.KeyRight, tcell.KeyCtrlF: - a.keyRight() - return true - case tcell.KeyLeft, tcell.KeyCtrlB: - a.keyLeft() - return true - case tcell.KeyPgDn: - a.keyPgDn() - return true - case tcell.KeyPgUp: - a.keyPgUp() - return true - case tcell.KeyEnd: - a.keyEnd() - return true - case tcell.KeyHome: - a.keyHome() - return true - } - } - return false -} - -// Size returns the content size, based on the model. -func (a *CellView) Size() (int, int) { - // We always return a minimum of two rows, and two columns. - w, h := a.model.GetBounds() - // Clip to a 2x2 minimum square; we can scroll within that. - if w > 2 { - w = 2 - } - if h > 2 { - h = 2 - } - return w, h -} - -// GetModel gets the model for this CellView -func (a *CellView) GetModel() CellModel { - return a.model -} - -// SetModel sets the model for this CellView. -func (a *CellView) SetModel(model CellModel) { - w, h := model.GetBounds() - a.model = model - a.port.SetContentSize(w, h, true) - a.port.ValidateView() - a.PostEventWidgetContent(a) -} - -// SetView sets the View context. -func (a *CellView) SetView(view View) { - port := a.port - port.SetView(view) - a.view = view - if view == nil { - return - } - width, height := view.Size() - a.port.Resize(0, 0, width, height) - if a.model != nil { - w, h := a.model.GetBounds() - a.port.SetContentSize(w, h, true) - } - a.Resize() -} - -// Resize is called when the View is resized. It will ensure that the -// cursor is visible, if present. -func (a *CellView) Resize() { - // We might want to reflow text - width, height := a.view.Size() - a.port.Resize(0, 0, width, height) - a.port.ValidateView() - a.MakeCursorVisible() -} - -// SetCursor sets the the cursor position. -func (a *CellView) SetCursor(x, y int) { - a.model.SetCursor(x, y) -} - -// SetCursorX sets the the cursor column. -func (a *CellView) SetCursorX(x int) { - _, y, _, _ := a.model.GetCursor() - a.SetCursor(x, y) -} - -// SetCursorY sets the the cursor row. -func (a *CellView) SetCursorY(y int) { - x, _, _, _ := a.model.GetCursor() - a.SetCursor(x, y) -} - -// MakeVisible makes the given coordinates visible, if they are not already. -// It does this by moving the ViewPort for the CellView. -func (a *CellView) MakeVisible(x, y int) { - a.port.MakeVisible(x, y) -} - -// SetStyle sets the the default fill style. -func (a *CellView) SetStyle(s tcell.Style) { - a.style = s -} - -// Init initializes a new CellView for use. -func (a *CellView) Init() { - a.once.Do(func() { - a.port = NewViewPort(nil, 0, 0, 0, 0) - a.style = tcell.StyleDefault - }) -} - -// NewCellView creates a CellView. -func NewCellView() *CellView { - cv := &CellView{} - cv.Init() - return cv -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/constants.go b/vendor/github.com/gdamore/tcell/v2/views/constants.go deleted file mode 100644 index b76894a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/constants.go +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright 2015 The Tops'l Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -// Alignment represents the alignment of an object, and consists of -// either or both of horizontal and vertical alignment. -type Alignment int - -const ( - // HAlignLeft indicates alignment on the left edge. - HAlignLeft Alignment = 1 << iota - - // HAlignCenter indicates horizontally centered. - HAlignCenter - - // HAlignRight indicates alignment on the right edge. - HAlignRight - - // VAlignTop indicates alignment on the top edge. - VAlignTop - - // VAlignCenter indicates vertically centered. - VAlignCenter - - // VAlignBottom indicates alignment on the bottom edge. - VAlignBottom -) -const ( - // AlignBegin indicates alignment at the top left corner. - AlignBegin = HAlignLeft | VAlignTop - - // AlignEnd indicates alignment at the bottom right corner. - AlignEnd = HAlignRight | VAlignBottom - - // AlignMiddle indicates full centering. - AlignMiddle = HAlignCenter | VAlignCenter -) - -// Orientation represents the direction of a widget or layout. -type Orientation int - -const ( - // Horizontal indicates left to right orientation. - Horizontal = iota - - // Vertical indicates top to bottom orientation. - Vertical -) diff --git a/vendor/github.com/gdamore/tcell/v2/views/panel.go b/vendor/github.com/gdamore/tcell/v2/views/panel.go deleted file mode 100644 index 9d46bb3..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/panel.go +++ /dev/null @@ -1,111 +0,0 @@ -// Copyright 2015 The Tops'l Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -// Panel is a modified Layout that includes a primary content pane, -// prefixed with an optional title, and an optional menubar, and then -// suffixed by an optional status. -// -// Only the content pane is resizable. The panel will be formatted -// like this: -// -// +---------- -// | title -// | menu -// | content.... -// | -// | status -// +---------- -// -// Each of these components may be any valid widget; their names are -// only meant to be indicative of conventional use, not prescriptive. -type Panel struct { - title Widget - menu Widget - content Widget - status Widget - inited bool - BoxLayout -} - -// Draw draws the Panel. -func (p *Panel) Draw() { - p.BoxLayout.SetOrientation(Vertical) - p.BoxLayout.Draw() -} - -// SetTitle sets the Widget to display in the title area. -func (p *Panel) SetTitle(w Widget) { - if p.title != nil { - p.RemoveWidget(p.title) - } - p.InsertWidget(0, w, 0.0) - p.title = w -} - -// SetMenu sets the Widget to display in the menu area, which is -// just below the title. -func (p *Panel) SetMenu(w Widget) { - index := 0 - if p.title != nil { - index++ - } - if p.menu != nil { - p.RemoveWidget(p.menu) - } - p.InsertWidget(index, w, 0.0) - p.menu = w -} - -// SetContent sets the Widget to display in the content area. -func (p *Panel) SetContent(w Widget) { - index := 0 - if p.title != nil { - index++ - } - if p.menu != nil { - index++ - } - if p.content != nil { - p.RemoveWidget(p.content) - } - p.InsertWidget(index, w, 1.0) - p.content = w -} - -// SetStatus sets the Widget to display in the status area, which is at -// the bottom of the panel. -func (p *Panel) SetStatus(w Widget) { - index := 0 - if p.title != nil { - index++ - } - if p.menu != nil { - index++ - } - if p.content != nil { - index++ - } - if p.status != nil { - p.RemoveWidget(p.status) - } - p.InsertWidget(index, w, 0.0) - p.status = w -} - -// NewPanel creates a new Panel. A zero valued panel can be created too. -func NewPanel() *Panel { - return &Panel{} -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/spacer.go b/vendor/github.com/gdamore/tcell/v2/views/spacer.go deleted file mode 100644 index 7bba7b7..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/spacer.go +++ /dev/null @@ -1,53 +0,0 @@ -// Copyright 2015 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "github.com/gdamore/tcell/v2" -) - -// Spacer is a Widget that occupies no visible real-estate. It is useful to -// add this to layouts when expansion space is required. It expands as needed -// with blank space. -type Spacer struct { - WidgetWatchers -} - -// Draw is called to update the displayed content. -func (*Spacer) Draw() {} - -// Size always returns 0, 0, since no size is ever *requird* to display nothing. -func (*Spacer) Size() (int, int) { - return 0, 0 -} - -// SetView sets the View object used for the text bar. -func (*Spacer) SetView(View) {} - -// HandleEvent implements a tcell.EventHandler, but does nothing. -func (*Spacer) HandleEvent(tcell.Event) bool { - return false -} - -// Resize is called when our View changes sizes. -func (s *Spacer) Resize() { - s.PostEventWidgetResize(s) -} - -// NewSpacer creates an empty Spacer. It's probably easier just to declare it -// directly. -func NewSpacer() *Spacer { - return &Spacer{} -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/sstext.go b/vendor/github.com/gdamore/tcell/v2/views/sstext.go deleted file mode 100644 index 9e233e6..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/sstext.go +++ /dev/null @@ -1,127 +0,0 @@ -// Copyright 2016 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "unicode" - - "github.com/gdamore/tcell/v2" -) - -// SimpleStyledText is a form of Text that offers highlighting of the text -// using simple in-line markup. Its intention is to make it easier to mark -// up hot // keys for menubars, etc. -type SimpleStyledText struct { - styles map[rune]tcell.Style - markup []rune - Text -} - -// SetMarkup sets the text used for the string. It applies markup as follows -// (modeled on tcsh style prompt markup): -// -// * %% - emit a single % in current style -// * %N - normal style -// * %A - alternate style -// * %S - start standout (reverse) style -// * %B - start bold style -// * %U - start underline style -// -// Other styles can be set using %, if styles are registered. -// Upper case characters and punctuation are reserved for use by the system. -// Lower case are available for use by the user. (Users may define mappings -// for upper case letters to override system defined styles.) -// -// Note that for simplicity, combining styles is not supported. By default -// the alternate style is the same as standout (reverse) mode. -// -// Arguably we could have used Markdown syntax instead, but properly doing all -// of Markdown is not trivial, and these escape sequences make it clearer that -// we are not even attempting to do that. -func (t *SimpleStyledText) SetMarkup(s string) { - - markup := []rune(s) - styl := make([]tcell.Style, 0, len(markup)) - text := make([]rune, 0, len(markup)) - - style := t.styles['N'] - - esc := false - for _, r := range markup { - if esc { - esc = false - switch r { - case '%': - text = append(text, '%') - styl = append(styl, style) - default: - style = t.styles[r] - } - continue - } - switch r { - case '%': - esc = true - continue - default: - text = append(text, r) - styl = append(styl, style) - } - } - - t.Text.SetText(string(text)) - for i, s := range styl { - t.SetStyleAt(i, s) - } - t.markup = markup -} - -// Registers a style for the given rune. This style will be used for -// text marked with %. See SetMarkup() for more detail. Note that -// this must be done before using any of the styles with SetMarkup(). -// Only letters may be used when registering styles, and be advised that -// the system may have predefined uses for upper case letters. -func (t *SimpleStyledText) RegisterStyle(r rune, style tcell.Style) { - if r == 'N' { - t.Text.SetStyle(style) - } - if unicode.IsLetter(r) { - t.styles[r] = style - } -} - -// LookupStyle returns the style registered for the given rune. -// Returns tcell.StyleDefault if no style was previously registered -// for the rune. -func (t *SimpleStyledText) LookupStyle(r rune) tcell.Style { - return t.styles[r] -} - -// Markup returns the text that was set, including markup. -func (t *SimpleStyledText) Markup() string { - return string(t.markup) -} - -// NewSimpleStyledText creates an empty Text. -func NewSimpleStyledText() *SimpleStyledText { - ss := &SimpleStyledText{} - // Create map and establish default styles. - ss.styles = make(map[rune]tcell.Style) - ss.styles['N'] = tcell.StyleDefault - ss.styles['S'] = tcell.StyleDefault.Reverse(true) - ss.styles['U'] = tcell.StyleDefault.Underline(true) - ss.styles['B'] = tcell.StyleDefault.Bold(true) - return ss -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/sstextbar.go b/vendor/github.com/gdamore/tcell/v2/views/sstextbar.go deleted file mode 100644 index 7ef2c28..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/sstextbar.go +++ /dev/null @@ -1,113 +0,0 @@ -// Copyright 2016 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "sync" - - "github.com/gdamore/tcell/v2" -) - -// SimpleStyledTextBar is a Widget that provides a single line of text, but -// with distinct left, center, and right areas. Each of the areas can be -// styled differently, and can contain internal style markup. -// They align to the left, center, and right respectively. -// This is basically a convenience type on top SimpleStyledText and BoxLayout. -type SimpleStyledTextBar struct { - left *SimpleStyledText - right *SimpleStyledText - center *SimpleStyledText - once sync.Once - - BoxLayout -} - -// SetRight sets the right text for the textbar. -// It is always right-aligned. -func (s *SimpleStyledTextBar) SetRight(m string) { - s.initialize() - s.right.SetMarkup(m) -} - -// SetLeft sets the left text for the textbar. -// It is always left-aligned. -func (s *SimpleStyledTextBar) SetLeft(m string) { - s.initialize() - s.left.SetMarkup(m) -} - -// SetCenter sets the center text for the textbar. -// It is always centered. -func (s *SimpleStyledTextBar) SetCenter(m string) { - s.initialize() - s.center.SetMarkup(m) -} - -func (s *SimpleStyledTextBar) RegisterRightStyle(r rune, style tcell.Style) { - s.initialize() - s.right.RegisterStyle(r, style) -} - -func (s *SimpleStyledTextBar) RegisterLeftStyle(r rune, style tcell.Style) { - s.initialize() - s.left.RegisterStyle(r, style) -} - -func (s *SimpleStyledTextBar) RegisterCenterStyle(r rune, style tcell.Style) { - s.initialize() - s.center.RegisterStyle(r, style) -} - -func (s *SimpleStyledTextBar) Size() (int, int) { - s.initialize() - w, h := s.BoxLayout.Size() - if h < 1 { - h = 1 - } - if w < 1 { - w = 1 - } - return w, h -} - -func (s *SimpleStyledTextBar) initialize() { - s.once.Do(func() { - s.center = NewSimpleStyledText() - s.left = NewSimpleStyledText() - s.right = NewSimpleStyledText() - s.center.SetAlignment(VAlignTop | HAlignCenter) - s.left.SetAlignment(VAlignTop | HAlignLeft) - s.right.SetAlignment(VAlignTop | HAlignRight) - s.BoxLayout.SetOrientation(Horizontal) - s.BoxLayout.AddWidget(s.left, 0.0) - s.BoxLayout.AddWidget(NewSpacer(), 1.0) - s.BoxLayout.AddWidget(s.center, 0.0) - s.BoxLayout.AddWidget(NewSpacer(), 1.0) - s.BoxLayout.AddWidget(s.right, 0.0) - }) -} - -// Init prepares the widget for use, ensuring resources needed are -// allocated, etc. -func (s *SimpleStyledTextBar) Init() { - s.initialize() -} - -// NewSimpleStyledTextBar creates an empty, initialized TextBar. -func NewSimpleStyledTextBar() *SimpleStyledTextBar { - s := &SimpleStyledTextBar{} - s.initialize() - return s -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/text.go b/vendor/github.com/gdamore/tcell/v2/views/text.go deleted file mode 100644 index 16d5afd..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/text.go +++ /dev/null @@ -1,278 +0,0 @@ -// Copyright 2015 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "github.com/mattn/go-runewidth" - - "github.com/gdamore/tcell/v2" -) - -// Text is a Widget with containing a block of text, which can optionally -// be styled. -type Text struct { - view View - align Alignment - style tcell.Style - text []rune - widths []int - styles []tcell.Style - lengths []int - width int - height int - - WidgetWatchers -} - -func (t *Text) clear() { - v := t.view - w, h := v.Size() - v.Clear() - for y := 0; y < h; y++ { - for x := 0; x < w; x++ { - v.SetContent(x, y, ' ', nil, t.style) - } - } -} - -// calcY figures the initial Y offset. Alignment is top by default. -func (t *Text) calcY(height int) int { - if t.align&VAlignCenter != 0 { - return (height - len(t.lengths)) / 2 - } - if t.align&VAlignBottom != 0 { - return height - len(t.lengths) - } - return 0 -} - -// calcX figures the initial X offset for the given line. -// Alignment is left by default. -func (t *Text) calcX(width, line int) int { - if t.align&HAlignCenter != 0 { - return (width - t.lengths[line]) / 2 - } - if t.align&HAlignRight != 0 { - return width - t.lengths[line] - } - return 0 -} - -// Draw draws the Text. -func (t *Text) Draw() { - v := t.view - if v == nil { - return - } - - width, height := v.Size() - if width == 0 || height == 0 { - return - } - - t.clear() - - // Note that we might wind up with a negative X if the width - // is larger than the length. That's OK, and correct even. - // The view will clip it properly in that case. - - // We align to the left & top by default. - y := t.calcY(height) - r := rune(0) - w := 0 - x := 0 - var styl tcell.Style - var comb []rune - line := 0 - newline := true - for i, l := range t.text { - - if newline { - x = t.calcX(width, line) - newline = false - } - if l == '\n' { - if w != 0 { - v.SetContent(x, y, r, comb, styl) - } - newline = true - w = 0 - comb = nil - line++ - y++ - continue - } - if t.widths[i] == 0 { - comb = append(comb, l) - continue - } - if w != 0 { - v.SetContent(x, y, r, comb, styl) - x += w - } - r = l - w = t.widths[i] - styl = t.styles[i] - comb = nil - } - if w != 0 { - v.SetContent(x, y, r, comb, styl) - } -} - -// Size returns the width and height in character cells of the Text. -func (t *Text) Size() (int, int) { - if len(t.text) != 0 { - return t.width, t.height - } - return 0, 0 -} - -// SetAlignment sets the alignment. Negative values -// indicate right justification, positive values are left, -// and zero indicates center aligned. -func (t *Text) SetAlignment(align Alignment) { - if align != t.align { - t.align = align - t.PostEventWidgetContent(t) - } -} - -// Alignment returns the alignment of the Text. -func (t *Text) Alignment() Alignment { - return t.align -} - -// SetView sets the View object used for the text bar. -func (t *Text) SetView(view View) { - t.view = view -} - -// HandleEvent implements a tcell.EventHandler, but does nothing. -func (t *Text) HandleEvent(tcell.Event) bool { - return false -} - -// SetText sets the text used for the string. Any previously set -// styles on individual rune indices are reset, and the default style -// for the widget is set. -func (t *Text) SetText(s string) { - t.width = 0 - t.text = []rune(s) - if len(t.widths) < len(t.text) { - t.widths = make([]int, len(t.text)) - } else { - t.widths = t.widths[0:len(t.text)] - } - if len(t.styles) < len(t.text) { - t.styles = make([]tcell.Style, len(t.text)) - } else { - t.styles = t.styles[0:len(t.text)] - } - t.lengths = []int{} - length := 0 - for i, r := range t.text { - t.widths[i] = runewidth.RuneWidth(r) - t.styles[i] = t.style - if r == '\n' { - t.lengths = append(t.lengths, length) - if length > t.width { - t.width = length - } - length = 0 - } else if t.widths[i] == 0 && length == 0 { - // If first character on line is combining, inject - // a leading space. (Shame on the caller!) - t.widths = append(t.widths, 0) - copy(t.widths[i+1:], t.widths[i:]) - t.widths[i] = 1 - - t.text = append(t.text, ' ') - copy(t.text[i+1:], t.text[i:]) - t.text[i] = ' ' - - t.styles = append(t.styles, t.style) - copy(t.styles[i+1:], t.styles[i:]) - t.styles[i] = t.style - length++ - } else { - length += t.widths[i] - } - } - if length > 0 { - t.lengths = append(t.lengths, length) - if length > t.width { - t.width = length - } - } - t.height = len(t.lengths) - t.PostEventWidgetContent(t) -} - -// Text returns the text that was set. -func (t *Text) Text() string { - return string(t.text) -} - -// SetStyle sets the style used. This applies to every cell in the -// in the text. -func (t *Text) SetStyle(style tcell.Style) { - t.style = style - for i := 0; i < len(t.text); i++ { - if t.widths[i] != 0 { - t.styles[i] = t.style - } - } - t.PostEventWidgetContent(t) -} - -// Style returns the previously set default style. Note that -// individual characters may have different styles. -func (t *Text) Style() tcell.Style { - return t.style -} - -// SetStyleAt sets the style at the given rune index. Note that for -// strings containing combining characters, it is not possible to -// change the style at the position of the combining character, but -// those positions *do* count for calculating the index. A lot of -// complexity can be avoided by avoiding the use of combining characters. -func (t *Text) SetStyleAt(pos int, style tcell.Style) { - if pos < 0 || pos >= len(t.text) || t.widths[pos] < 1 { - return - } - t.styles[pos] = style - t.PostEventWidgetContent(t) -} - -// StyleAt gets the style at the given rune index. If an invalid -// index is given, or the index is a combining character, then -// tcell.StyleDefault is returned. -func (t *Text) StyleAt(pos int) tcell.Style { - if pos < 0 || pos >= len(t.text) || t.widths[pos] < 1 { - return tcell.StyleDefault - } - return t.styles[pos] -} - -// Resize is called when our View changes sizes. -func (t *Text) Resize() { - t.PostEventWidgetResize(t) -} - -// NewText creates an empty Text. -func NewText() *Text { - return &Text{} -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/text_test.go b/vendor/github.com/gdamore/tcell/v2/views/text_test.go deleted file mode 100644 index 1d57e84..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/text_test.go +++ /dev/null @@ -1,19 +0,0 @@ -package views - -import "testing" - -func TestText(t *testing.T) { - text := &Text{} - - text.SetText(` -This -String -Is -Pretty -Long -12345678901234567890 -`) - if text.width != 20 { - t.Errorf("Incorrect width: %d, expected: %d", text.width, 20) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/textarea.go b/vendor/github.com/gdamore/tcell/v2/views/textarea.go deleted file mode 100644 index 2f19c66..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/textarea.go +++ /dev/null @@ -1,155 +0,0 @@ -// Copyright 2016 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "strings" - "sync" - - "github.com/gdamore/tcell/v2" -) - -// TextArea is a pannable 2 dimensional text widget. It wraps both -// the view and the model for text in a single, convenient widget. -// Text is provided as an array of strings, each of which represents -// a single line to display. All text in the TextArea has the same -// style. An optional soft cursor is available. -type TextArea struct { - model *linesModel - once sync.Once - CellView -} - -type linesModel struct { - runes [][]rune - width int - height int - x int - y int - hide bool - cursor bool - style tcell.Style -} - -func (m *linesModel) GetCell(x, y int) (rune, tcell.Style, []rune, int) { - if x < 0 || y < 0 || y >= m.height || x >= len(m.runes[y]) { - return 0, m.style, nil, 1 - } - // XXX: extend this to support combining and full width chars - return m.runes[y][x], m.style, nil, 1 -} - -func (m *linesModel) GetBounds() (int, int) { - return m.width, m.height -} - -func (m *linesModel) limitCursor() { - if m.x > m.width-1 { - m.x = m.width - 1 - } - if m.y > m.height-1 { - m.y = m.height - 1 - } - if m.x < 0 { - m.x = 0 - } - if m.y < 0 { - m.y = 0 - } -} - -func (m *linesModel) SetCursor(x, y int) { - m.x = x - m.y = y - m.limitCursor() -} - -func (m *linesModel) MoveCursor(x, y int) { - m.x += x - m.y += y - m.limitCursor() -} - -func (m *linesModel) GetCursor() (int, int, bool, bool) { - return m.x, m.y, m.cursor, !m.hide -} - -// SetLines sets the content text to display. -func (ta *TextArea) SetLines(lines []string) { - ta.Init() - m := ta.model - m.width =0 - - // extend slice before using m.runes[row] to avoid panic - slice := make([][]rune, len(lines)) - m.runes = slice - - for row, line := range lines { - for _, ch := range line { - m.runes[row] = append(m.runes[row], ch) - } - if len(m.runes[row]) > m.width { - m.width = len(m.runes[row]) - } - } - - m.height = len(m.runes) - - ta.CellView.SetModel(m) -} - -func (ta *TextArea) SetStyle(style tcell.Style) { - ta.model.style = style - ta.CellView.SetStyle(style) -} - -// EnableCursor enables a soft cursor in the TextArea. -func (ta *TextArea) EnableCursor(on bool) { - ta.Init() - ta.model.cursor = on -} - -// HideCursor hides or shows the cursor in the TextArea. -// If on is true, the cursor is hidden. Note that a cursor is only -// shown if it is enabled. -func (ta *TextArea) HideCursor(on bool) { - ta.Init() - ta.model.hide = on -} - -// SetContent is used to set the textual content, passed as a -// single string. Lines within the string are delimited by newlines. -func (ta *TextArea) SetContent(text string) { - ta.Init() - lines := strings.Split(strings.Trim(text, "\n"), "\n") - ta.SetLines(lines) -} - -// Init initializes the TextArea. -func (ta *TextArea) Init() { - ta.once.Do(func() { - lm := &linesModel{runes: [][]rune{}, width: 0} - ta.model = lm - ta.CellView.Init() - ta.CellView.SetModel(lm) - }) -} - -// NewTextArea creates a blank TextArea. -func NewTextArea() *TextArea { - ta := &TextArea{} - ta.Init() - return ta -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/textarea_test.go b/vendor/github.com/gdamore/tcell/v2/views/textarea_test.go deleted file mode 100644 index b569e58..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/textarea_test.go +++ /dev/null @@ -1,17 +0,0 @@ -package views - -import "testing" - -func TestSetContent(t *testing.T) { - ta := &TextArea{} - - ta.SetContent("This is a quite long line.") // This line is longer than 11. - ta.SetContent("Four.\nFive...\n...and Six.") //"...and Six." should be 11 long. - - if ta.model.height != 3 { - t.Errorf("Incorrect height: %d, expected: %d", ta.model.height, 3) - } - if ta.model.width != 11 { - t.Errorf("Incorrect width: %d, expected: %d", ta.model.width, 11) - } -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/textbar.go b/vendor/github.com/gdamore/tcell/v2/views/textbar.go deleted file mode 100644 index 5157b8e..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/textbar.go +++ /dev/null @@ -1,193 +0,0 @@ -// Copyright 2015 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "sync" - - "github.com/gdamore/tcell/v2" -) - -// TextBar is a Widget that provides a single line of text, but with -// distinct left, center, and right areas. Each of the areas can be styled -// differently, and they align to the left, center, and right respectively. -// This is basically a convenience type on top Text and BoxLayout. -type TextBar struct { - changed bool - style tcell.Style - left Text - right Text - center Text - view View - lview ViewPort - rview ViewPort - cview ViewPort - once sync.Once - - WidgetWatchers -} - -// SetCenter sets the center text for the textbar. The text is -// always center aligned. -func (t *TextBar) SetCenter(s string, style tcell.Style) { - t.initialize() - if style == tcell.StyleDefault { - style = t.style - } - t.center.SetText(s) - t.center.SetStyle(style) -} - -// SetLeft sets the left text for the textbar. It is always left-aligned. -func (t *TextBar) SetLeft(s string, style tcell.Style) { - t.initialize() - if style == tcell.StyleDefault { - style = t.style - } - t.left.SetText(s) - t.left.SetStyle(style) -} - -// SetRight sets the right text for the textbar. It is always right-aligned. -func (t *TextBar) SetRight(s string, style tcell.Style) { - t.initialize() - if style == tcell.StyleDefault { - style = t.style - } - t.right.SetText(s) - t.right.SetStyle(style) -} - -// SetStyle is used to set a default style to use for the textbar, including -// areas where no text is present. Note that this will not change the text -// already displayed, so call this before changing or setting text. -func (t *TextBar) SetStyle(style tcell.Style) { - t.initialize() - t.style = style -} - -func (t *TextBar) initialize() { - t.once.Do(func() { - t.center.SetView(&t.cview) - t.left.SetView(&t.lview) - t.right.SetView(&t.rview) - t.center.SetAlignment(VAlignTop | HAlignCenter) - t.left.SetAlignment(VAlignTop | HAlignLeft) - t.right.SetAlignment(VAlignTop | HAlignRight) - t.center.Watch(t) - t.left.Watch(t) - t.right.Watch(t) - }) -} - -func (t *TextBar) layout() { - w, _ := t.view.Size() - ww, wh := t.left.Size() - t.lview.Resize(0, 0, ww, wh) - - ww, wh = t.center.Size() - t.cview.Resize((w-ww)/2, 0, ww, wh) - - ww, wh = t.right.Size() - t.rview.Resize(w-ww, 0, ww, wh) - - t.changed = false -} - -// SetView sets the View drawing context for this TextBar. -func (t *TextBar) SetView(view View) { - t.initialize() - t.view = view - t.lview.SetView(view) - t.rview.SetView(view) - t.cview.SetView(view) - t.changed = true -} - -// Draw draws the TextBar into its View context. -func (t *TextBar) Draw() { - - t.initialize() - if t.changed { - t.layout() - } - w, h := t.view.Size() - for y := 0; y < h; y++ { - for x := 0; x < w; x++ { - t.view.SetContent(x, y, ' ', nil, t.style) - } - } - - // Draw in reverse order -- if we clip, we will clip at the - // right side. - t.right.Draw() - t.center.Draw() - t.left.Draw() -} - -// Resize is called when the TextBar's View changes size, and -// updates the layout. -func (t *TextBar) Resize() { - t.initialize() - t.layout() - - t.left.Resize() - t.center.Resize() - t.right.Resize() - - t.PostEventWidgetResize(t) -} - -// Size implements the Size method for Widget, returning the width -// and height in character cells. -func (t *TextBar) Size() (int, int) { - w, h := 0, 0 - - ww, wh := t.left.Size() - w += ww - if wh > h { - h = wh - } - ww, wh = t.center.Size() - w += ww - if wh > h { - h = wh - } - ww, wh = t.right.Size() - w += ww - if wh > h { - h = wh - } - return w, h -} - -// HandleEvent handles incoming events. The only events handled are -// those for the Text objects; when those change, the TextBar adjusts -// the layout to accommodate. -func (t *TextBar) HandleEvent(ev tcell.Event) bool { - switch ev.(type) { - case *EventWidgetContent: - t.changed = true - return true - } - return false -} - -// NewTextBar creates an empty, initialized TextBar. -func NewTextBar() *TextBar { - t := &TextBar{} - t.initialize() - return t -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/view.go b/vendor/github.com/gdamore/tcell/v2/views/view.go deleted file mode 100644 index aac7db5..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/view.go +++ /dev/null @@ -1,300 +0,0 @@ -// Copyright 2016 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "github.com/gdamore/tcell/v2" -) - -// View represents a logical view on an area. It will have some underlying -// physical area as well, generally. Views are operated on by Widgets. -type View interface { - // SetContent is used to update the content of the View at the given - // location. This will generally be called by the Draw() method of - // a Widget. - SetContent(x int, y int, ch rune, comb []rune, style tcell.Style) - - // Size represents the visible size. The actual content may be - // larger or smaller. - Size() (int, int) - - // Resize tells the View that its visible dimensions have changed. - // It also tells it that it has a new offset relative to any parent - // view. - Resize(x, y, width, height int) - - // Fill fills the displayed content with the given rune and style. - Fill(rune, tcell.Style) - - // Clear clears the content. Often just Fill(' ', tcell.StyleDefault) - Clear() -} - -// ViewPort is an implementation of a View, that provides a smaller logical -// view of larger content area. For example, a scrollable window of text, -// the visible window would be the ViewPort, on the underlying content. -// ViewPorts have a two dimensional size, and a two dimensional offset. -// -// In some ways, as the underlying content is not kept persistently by the -// view port, it can be thought perhaps a little more precisely as a clipping -// region. -type ViewPort struct { - physx int // Anchor to the real world, usually 0 - physy int // Again, anchor to the real world, usually 3 - viewx int // Logical offset of the view - viewy int // Logical offset of the view - limx int // Content limits -- can't right scroll past this - limy int // Content limits -- can't down scroll past this - width int // View width - height int // View height - locked bool // if true, don't autogrow - v View -} - -// Clear clears the displayed content, filling it with spaces of default -// text attributes. -func (v *ViewPort) Clear() { - v.Fill(' ', tcell.StyleDefault) -} - -// Fill fills the displayed view port with the given character and style. -func (v *ViewPort) Fill(ch rune, style tcell.Style) { - if v.v != nil { - for y := 0; y < v.height; y++ { - for x := 0; x < v.width; x++ { - v.v.SetContent(x+v.physx, y+v.physy, ch, nil, style) - } - } - } -} - -// Size returns the visible size of the ViewPort in character cells. -func (v *ViewPort) Size() (int, int) { - return v.width, v.height -} - -// Reset resets the record of content, and also resets the offset back -// to the origin. It doesn't alter the dimensions of the view port, nor -// the physical location relative to its parent. -func (v *ViewPort) Reset() { - v.limx = 0 - v.limy = 0 - v.viewx = 0 - v.viewy = 0 -} - -// SetContent is used to place data at the given cell location. Note that -// since the ViewPort doesn't retain this data, if the location is outside -// of the visible area, it is simply discarded. -// -// Generally, this is called during the Draw() phase by the object that -// represents the content. -func (v *ViewPort) SetContent(x, y int, ch rune, comb []rune, s tcell.Style) { - if v.v == nil { - return - } - if x > v.limx && !v.locked { - v.limx = x - } - if y > v.limy && !v.locked { - v.limy = y - } - if x < v.viewx || y < v.viewy { - return - } - if x >= (v.viewx + v.width) { - return - } - if y >= (v.viewy + v.height) { - return - } - v.v.SetContent(x-v.viewx+v.physx, y-v.viewy+v.physy, ch, comb, s) -} - -// MakeVisible moves the ViewPort the minimum necessary to make the given -// point visible. This should be called before any content is changed with -// SetContent, since otherwise it may be possible to move the location onto -// a region whose contents have been discarded. -func (v *ViewPort) MakeVisible(x, y int) { - if x < v.limx && x >= v.viewx+v.width { - v.viewx = x - (v.width - 1) - } - if x >= 0 && x < v.viewx { - v.viewx = x - } - if y < v.limy && y >= v.viewy+v.height { - v.viewy = y - (v.height - 1) - } - if y >= 0 && y < v.viewy { - v.viewy = y - } - v.ValidateView() -} - -// ValidateViewY ensures that the Y offset of the view port is limited so that -// it cannot scroll away from the content. -func (v *ViewPort) ValidateViewY() { - if v.viewy >= v.limy-v.height { - v.viewy = (v.limy - v.height) - } - if v.viewy < 0 { - v.viewy = 0 - } -} - -// ValidateViewX ensures that the X offset of the view port is limited so that -// it cannot scroll away from the content. -func (v *ViewPort) ValidateViewX() { - if v.viewx >= v.limx-v.width { - v.viewx = (v.limx - v.width) - } - if v.viewx < 0 { - v.viewx = 0 - } -} - -// ValidateView does both ValidateViewX and ValidateViewY, ensuring both -// offsets are valid. -func (v *ViewPort) ValidateView() { - v.ValidateViewX() - v.ValidateViewY() -} - -// Center centers the point, if possible, in the View. -func (v *ViewPort) Center(x, y int) { - if x < 0 || y < 0 || x >= v.limx || y >= v.limy || v.v == nil { - return - } - v.viewx = x - (v.width / 2) - v.viewy = y - (v.height / 2) - v.ValidateView() -} - -// ScrollUp moves the view up, showing lower numbered rows of content. -func (v *ViewPort) ScrollUp(rows int) { - v.viewy -= rows - v.ValidateViewY() -} - -// ScrollDown moves the view down, showingh higher numbered rows of content. -func (v *ViewPort) ScrollDown(rows int) { - v.viewy += rows - v.ValidateViewY() -} - -// ScrollLeft moves the view to the left. -func (v *ViewPort) ScrollLeft(cols int) { - v.viewx -= cols - v.ValidateViewX() -} - -// ScrollRight moves the view to the left. -func (v *ViewPort) ScrollRight(cols int) { - v.viewx += cols - v.ValidateViewX() -} - -// SetSize is used to set the visible size of the view. Enclosing views or -// layout managers can use this to inform the View of its correct visible size. -func (v *ViewPort) SetSize(width, height int) { - v.height = height - v.width = width - v.ValidateView() -} - -// GetVisible returns the upper left and lower right coordinates of the visible -// content. That is, it will return x1, y1, x2, y2 where the upper left cell -// is position x1, y1, and the lower right is x2, y2. These coordinates are -// in the space of the content, that is the content area uses coordinate 0,0 -// as its first cell position. -func (v *ViewPort) GetVisible() (int, int, int, int) { - return v.viewx, v.viewy, v.viewx + v.width - 1, v.viewy + v.height - 1 -} - -// GetPhysical returns the upper left and lower right coordinates of the visible -// content in the coordinate space of the parent. This is may be the physical -// coordinates of the screen, if the screen is the view's parent. -func (v *ViewPort) GetPhysical() (int, int, int, int) { - return v.physx, v.physy, v.physx + v.width - 1, v.physy + v.height - 1 -} - -// SetContentSize sets the size of the content area; this is used to limit -// scrolling and view moment. If locked is true, then the content size will -// not automatically grow even if content is placed outside of this area -// with the SetContent() method. If false, and content is drawn outside -// of the existing size, then the size will automatically grow to include -// the new content. -func (v *ViewPort) SetContentSize(width, height int, locked bool) { - v.limx = width - v.limy = height - v.locked = locked - v.ValidateView() -} - -// GetContentSize returns the size of content as width, height in character -// cells. -func (v *ViewPort) GetContentSize() (int, int) { - return v.limx, v.limy -} - -// Resize is called by the enclosing view to change the size of the ViewPort, -// usually in response to a window resize event. The x, y refer are the -// ViewPort's location relative to the parent View. A negative value for either -// width or height will cause the ViewPort to expand to fill to the end of parent -// View in the relevant dimension. -func (v *ViewPort) Resize(x, y, width, height int) { - if v.v == nil { - return - } - px, py := v.v.Size() - if x >= 0 && x < px { - v.physx = x - } - if y >= 0 && y < py { - v.physy = y - } - if width < 0 { - width = px - x - } - if height < 0 { - height = py - y - } - if width <= x+px { - v.width = width - } - if height <= y+py { - v.height = height - } -} - -// SetView is called during setup, to provide the parent View. -func (v *ViewPort) SetView(view View) { - v.v = view -} - -// NewViewPort returns a new ViewPort (and hence also a View). -// The x and y coordinates are an offset relative to the parent. -// The origin 0,0 represents the upper left. The width and height -// indicate a width and height. If the value -1 is supplied, then the -// dimension is calculated from the parent. -func NewViewPort(view View, x, y, width, height int) *ViewPort { - v := &ViewPort{v: view} - // initial (and possibly poor) assumptions -- all visible - // cells are addressible, but none beyond that. - v.limx = width - v.limy = height - v.Resize(x, y, width, height) - return v -} diff --git a/vendor/github.com/gdamore/tcell/v2/views/widget.go b/vendor/github.com/gdamore/tcell/v2/views/widget.go deleted file mode 100644 index 626c43a..0000000 --- a/vendor/github.com/gdamore/tcell/v2/views/widget.go +++ /dev/null @@ -1,160 +0,0 @@ -// Copyright 2015 The Tcell Authors -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use file except in compliance with the License. -// You may obtain a copy of the license at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package views - -import ( - "github.com/gdamore/tcell/v2" -) - -// Widget is the base object that all onscreen elements implement. -type Widget interface { - // Draw is called to inform the widget to draw itself. A containing - // Widget will generally call this during the application draw loop. - Draw() - - // Resize is called in response to a resize of the View. Unlike with - // other events, Resize performed by parents first, and they must - // then call their children. This is because the children need to - // see the updated sizes from the parents before they are called. - // In general this is done *after* the views have updated. - Resize() - - // HandleEvent is called to ask the widget to handle any events. - // If the widget has consumed the event, it should return true. - // Generally, events are handled by the lower layers first, that - // is for example, a button may have a chance to handle an event - // before the enclosing window or panel. - // - // Its expected that Resize events are consumed by the outermost - // Widget, and the turned into a Resize() call. - HandleEvent(ev tcell.Event) bool - - // SetView is used by callers to set the visual context of the - // Widget. The Widget should use the View as a context for - // drawing. - SetView(view View) - - // Size returns the size of the widget (content size) as width, height - // in columns. Layout managers should attempt to ensure that at least - // this much space is made available to the View for this Widget. Extra - // space may be allocated on as an needed basis. - Size() (int, int) - - // Watch is used to register an interest in this widget's events. - // The handler will receive EventWidget events for this widget. - // The order of event delivery when there are multiple watchers is - // not specified, and may change from one event to the next. - Watch(handler tcell.EventHandler) - - // Unwatch is used to urnegister an interest in this widget's events. - Unwatch(handler tcell.EventHandler) -} - -// EventWidget is an event delivered by a specific widget. -type EventWidget interface { - Widget() Widget - tcell.Event -} - -type widgetEvent struct { - widget Widget - tcell.EventTime -} - -func (wev *widgetEvent) Widget() Widget { - return wev.widget -} - -func (wev *widgetEvent) SetWidget(widget Widget) { - wev.widget = widget -} - -// WidgetWatchers provides a common implementation for base Widget -// Watch and Unwatch interfaces, suitable for embedding in more concrete -// widget implementations. -type WidgetWatchers struct { - watchers map[tcell.EventHandler]struct{} -} - -// Watch monitors this WidgetWatcher, causing the handler to be fired -// with EventWidget as they are occur on the watched Widget. -func (ww *WidgetWatchers) Watch(handler tcell.EventHandler) { - if ww.watchers == nil { - ww.watchers = make(map[tcell.EventHandler]struct{}) - } - ww.watchers[handler] = struct{}{} -} - -// Unwatch stops monitoring this WidgetWatcher. The handler will no longer -// be fired for Widget events. -func (ww *WidgetWatchers) Unwatch(handler tcell.EventHandler) { - if ww.watchers != nil { - delete(ww.watchers, handler) - } -} - -// PostEvent delivers the EventWidget to all registered watchers. It is -// to be called by the Widget implementation. -func (ww *WidgetWatchers) PostEvent(wev EventWidget) { - for watcher := range ww.watchers { - // Deliver events to all listeners, ignoring return value. - watcher.HandleEvent(wev) - } -} - -// PostEventWidgetContent is called by the Widget when its content is -// changed, delivering EventWidgetContent to all watchers. -func (ww *WidgetWatchers) PostEventWidgetContent(w Widget) { - ev := &EventWidgetContent{} - ev.SetWidget(w) - ev.SetEventNow() - ww.PostEvent(ev) -} - -// PostEventWidgetResize is called by the Widget when the underlying View -// has resized, delivering EventWidgetResize to all watchers. -func (ww *WidgetWatchers) PostEventWidgetResize(w Widget) { - ev := &EventWidgetResize{} - ev.SetWidget(w) - ev.SetEventNow() - ww.PostEvent(ev) -} - -// PostEventWidgetMove is called by the Widget when it is moved to a new -// location, delivering EventWidgetMove to all watchers. -func (ww *WidgetWatchers) PostEventWidgetMove(w Widget) { - ev := &EventWidgetMove{} - ev.SetWidget(w) - ev.SetEventNow() - ww.PostEvent(ev) -} - -// XXX: WidgetExposed, Hidden? -// XXX: WidgetExposed, Hidden? - -// EventWidgetContent is fired whenever a widget's content changes. -type EventWidgetContent struct { - widgetEvent -} - -// EventWidgetResize is fired whenever a widget is resized. -type EventWidgetResize struct { - widgetEvent -} - -// EventWidgetMove is fired whenver a widget changes location. -type EventWidgetMove struct { - widgetEvent -} diff --git a/vendor/github.com/golang/snappy/.gitignore b/vendor/github.com/golang/snappy/.gitignore deleted file mode 100644 index 042091d..0000000 --- a/vendor/github.com/golang/snappy/.gitignore +++ /dev/null @@ -1,16 +0,0 @@ -cmd/snappytool/snappytool -testdata/bench - -# These explicitly listed benchmark data files are for an obsolete version of -# snappy_test.go. -testdata/alice29.txt -testdata/asyoulik.txt -testdata/fireworks.jpeg -testdata/geo.protodata -testdata/html -testdata/html_x_4 -testdata/kppkn.gtb -testdata/lcet10.txt -testdata/paper-100k.pdf -testdata/plrabn12.txt -testdata/urls.10K diff --git a/vendor/github.com/golang/snappy/AUTHORS b/vendor/github.com/golang/snappy/AUTHORS deleted file mode 100644 index bcfa195..0000000 --- a/vendor/github.com/golang/snappy/AUTHORS +++ /dev/null @@ -1,15 +0,0 @@ -# This is the official list of Snappy-Go authors for copyright purposes. -# This file is distinct from the CONTRIBUTORS files. -# See the latter for an explanation. - -# Names should be added to this file as -# Name or Organization -# The email address is not required for organizations. - -# Please keep the list sorted. - -Damian Gryski -Google Inc. -Jan Mercl <0xjnml@gmail.com> -Rodolfo Carvalho -Sebastien Binet diff --git a/vendor/github.com/golang/snappy/CONTRIBUTORS b/vendor/github.com/golang/snappy/CONTRIBUTORS deleted file mode 100644 index 931ae31..0000000 --- a/vendor/github.com/golang/snappy/CONTRIBUTORS +++ /dev/null @@ -1,37 +0,0 @@ -# This is the official list of people who can contribute -# (and typically have contributed) code to the Snappy-Go repository. -# The AUTHORS file lists the copyright holders; this file -# lists people. For example, Google employees are listed here -# but not in AUTHORS, because Google holds the copyright. -# -# The submission process automatically checks to make sure -# that people submitting code are listed in this file (by email address). -# -# Names should be added to this file only after verifying that -# the individual or the individual's organization has agreed to -# the appropriate Contributor License Agreement, found here: -# -# http://code.google.com/legal/individual-cla-v1.0.html -# http://code.google.com/legal/corporate-cla-v1.0.html -# -# The agreement for individuals can be filled out on the web. -# -# When adding J Random Contributor's name to this file, -# either J's name or J's organization's name should be -# added to the AUTHORS file, depending on whether the -# individual or corporate CLA was used. - -# Names should be added to this file like so: -# Name - -# Please keep the list sorted. - -Damian Gryski -Jan Mercl <0xjnml@gmail.com> -Kai Backman -Marc-Antoine Ruel -Nigel Tao -Rob Pike -Rodolfo Carvalho -Russ Cox -Sebastien Binet diff --git a/vendor/github.com/golang/snappy/LICENSE b/vendor/github.com/golang/snappy/LICENSE deleted file mode 100644 index 6050c10..0000000 --- a/vendor/github.com/golang/snappy/LICENSE +++ /dev/null @@ -1,27 +0,0 @@ -Copyright (c) 2011 The Snappy-Go Authors. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above -copyright notice, this list of conditions and the following disclaimer -in the documentation and/or other materials provided with the -distribution. - * Neither the name of Google Inc. nor the names of its -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/github.com/golang/snappy/README b/vendor/github.com/golang/snappy/README deleted file mode 100644 index cea1287..0000000 --- a/vendor/github.com/golang/snappy/README +++ /dev/null @@ -1,107 +0,0 @@ -The Snappy compression format in the Go programming language. - -To download and install from source: -$ go get github.com/golang/snappy - -Unless otherwise noted, the Snappy-Go source files are distributed -under the BSD-style license found in the LICENSE file. - - - -Benchmarks. - -The golang/snappy benchmarks include compressing (Z) and decompressing (U) ten -or so files, the same set used by the C++ Snappy code (github.com/google/snappy -and note the "google", not "golang"). On an "Intel(R) Core(TM) i7-3770 CPU @ -3.40GHz", Go's GOARCH=amd64 numbers as of 2016-05-29: - -"go test -test.bench=." - -_UFlat0-8 2.19GB/s ± 0% html -_UFlat1-8 1.41GB/s ± 0% urls -_UFlat2-8 23.5GB/s ± 2% jpg -_UFlat3-8 1.91GB/s ± 0% jpg_200 -_UFlat4-8 14.0GB/s ± 1% pdf -_UFlat5-8 1.97GB/s ± 0% html4 -_UFlat6-8 814MB/s ± 0% txt1 -_UFlat7-8 785MB/s ± 0% txt2 -_UFlat8-8 857MB/s ± 0% txt3 -_UFlat9-8 719MB/s ± 1% txt4 -_UFlat10-8 2.84GB/s ± 0% pb -_UFlat11-8 1.05GB/s ± 0% gaviota - -_ZFlat0-8 1.04GB/s ± 0% html -_ZFlat1-8 534MB/s ± 0% urls -_ZFlat2-8 15.7GB/s ± 1% jpg -_ZFlat3-8 740MB/s ± 3% jpg_200 -_ZFlat4-8 9.20GB/s ± 1% pdf -_ZFlat5-8 991MB/s ± 0% html4 -_ZFlat6-8 379MB/s ± 0% txt1 -_ZFlat7-8 352MB/s ± 0% txt2 -_ZFlat8-8 396MB/s ± 1% txt3 -_ZFlat9-8 327MB/s ± 1% txt4 -_ZFlat10-8 1.33GB/s ± 1% pb -_ZFlat11-8 605MB/s ± 1% gaviota - - - -"go test -test.bench=. -tags=noasm" - -_UFlat0-8 621MB/s ± 2% html -_UFlat1-8 494MB/s ± 1% urls -_UFlat2-8 23.2GB/s ± 1% jpg -_UFlat3-8 1.12GB/s ± 1% jpg_200 -_UFlat4-8 4.35GB/s ± 1% pdf -_UFlat5-8 609MB/s ± 0% html4 -_UFlat6-8 296MB/s ± 0% txt1 -_UFlat7-8 288MB/s ± 0% txt2 -_UFlat8-8 309MB/s ± 1% txt3 -_UFlat9-8 280MB/s ± 1% txt4 -_UFlat10-8 753MB/s ± 0% pb -_UFlat11-8 400MB/s ± 0% gaviota - -_ZFlat0-8 409MB/s ± 1% html -_ZFlat1-8 250MB/s ± 1% urls -_ZFlat2-8 12.3GB/s ± 1% jpg -_ZFlat3-8 132MB/s ± 0% jpg_200 -_ZFlat4-8 2.92GB/s ± 0% pdf -_ZFlat5-8 405MB/s ± 1% html4 -_ZFlat6-8 179MB/s ± 1% txt1 -_ZFlat7-8 170MB/s ± 1% txt2 -_ZFlat8-8 189MB/s ± 1% txt3 -_ZFlat9-8 164MB/s ± 1% txt4 -_ZFlat10-8 479MB/s ± 1% pb -_ZFlat11-8 270MB/s ± 1% gaviota - - - -For comparison (Go's encoded output is byte-for-byte identical to C++'s), here -are the numbers from C++ Snappy's - -make CXXFLAGS="-O2 -DNDEBUG -g" clean snappy_unittest.log && cat snappy_unittest.log - -BM_UFlat/0 2.4GB/s html -BM_UFlat/1 1.4GB/s urls -BM_UFlat/2 21.8GB/s jpg -BM_UFlat/3 1.5GB/s jpg_200 -BM_UFlat/4 13.3GB/s pdf -BM_UFlat/5 2.1GB/s html4 -BM_UFlat/6 1.0GB/s txt1 -BM_UFlat/7 959.4MB/s txt2 -BM_UFlat/8 1.0GB/s txt3 -BM_UFlat/9 864.5MB/s txt4 -BM_UFlat/10 2.9GB/s pb -BM_UFlat/11 1.2GB/s gaviota - -BM_ZFlat/0 944.3MB/s html (22.31 %) -BM_ZFlat/1 501.6MB/s urls (47.78 %) -BM_ZFlat/2 14.3GB/s jpg (99.95 %) -BM_ZFlat/3 538.3MB/s jpg_200 (73.00 %) -BM_ZFlat/4 8.3GB/s pdf (83.30 %) -BM_ZFlat/5 903.5MB/s html4 (22.52 %) -BM_ZFlat/6 336.0MB/s txt1 (57.88 %) -BM_ZFlat/7 312.3MB/s txt2 (61.91 %) -BM_ZFlat/8 353.1MB/s txt3 (54.99 %) -BM_ZFlat/9 289.9MB/s txt4 (66.26 %) -BM_ZFlat/10 1.2GB/s pb (19.68 %) -BM_ZFlat/11 527.4MB/s gaviota (37.72 %) diff --git a/vendor/github.com/golang/snappy/cmd/snappytool/main.cpp b/vendor/github.com/golang/snappy/cmd/snappytool/main.cpp deleted file mode 100644 index fc31f51..0000000 --- a/vendor/github.com/golang/snappy/cmd/snappytool/main.cpp +++ /dev/null @@ -1,77 +0,0 @@ -/* -To build the snappytool binary: -g++ main.cpp /usr/lib/libsnappy.a -o snappytool -or, if you have built the C++ snappy library from source: -g++ main.cpp /path/to/your/snappy/.libs/libsnappy.a -o snappytool -after running "make" from your snappy checkout directory. -*/ - -#include -#include -#include -#include - -#include "snappy.h" - -#define N 1000000 - -char dst[N]; -char src[N]; - -int main(int argc, char** argv) { - // Parse args. - if (argc != 2) { - fprintf(stderr, "exactly one of -d or -e must be given\n"); - return 1; - } - bool decode = strcmp(argv[1], "-d") == 0; - bool encode = strcmp(argv[1], "-e") == 0; - if (decode == encode) { - fprintf(stderr, "exactly one of -d or -e must be given\n"); - return 1; - } - - // Read all of stdin into src[:s]. - size_t s = 0; - while (1) { - if (s == N) { - fprintf(stderr, "input too large\n"); - return 1; - } - ssize_t n = read(0, src+s, N-s); - if (n == 0) { - break; - } - if (n < 0) { - fprintf(stderr, "read error: %s\n", strerror(errno)); - // TODO: handle EAGAIN, EINTR? - return 1; - } - s += n; - } - - // Encode or decode src[:s] to dst[:d], and write to stdout. - size_t d = 0; - if (encode) { - if (N < snappy::MaxCompressedLength(s)) { - fprintf(stderr, "input too large after encoding\n"); - return 1; - } - snappy::RawCompress(src, s, dst, &d); - } else { - if (!snappy::GetUncompressedLength(src, s, &d)) { - fprintf(stderr, "could not get uncompressed length\n"); - return 1; - } - if (N < d) { - fprintf(stderr, "input too large after decoding\n"); - return 1; - } - if (!snappy::RawUncompress(src, s, dst)) { - fprintf(stderr, "input was not valid Snappy-compressed data\n"); - return 1; - } - } - write(1, dst, d); - return 0; -} diff --git a/vendor/github.com/golang/snappy/decode.go b/vendor/github.com/golang/snappy/decode.go deleted file mode 100644 index 72efb03..0000000 --- a/vendor/github.com/golang/snappy/decode.go +++ /dev/null @@ -1,237 +0,0 @@ -// Copyright 2011 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package snappy - -import ( - "encoding/binary" - "errors" - "io" -) - -var ( - // ErrCorrupt reports that the input is invalid. - ErrCorrupt = errors.New("snappy: corrupt input") - // ErrTooLarge reports that the uncompressed length is too large. - ErrTooLarge = errors.New("snappy: decoded block is too large") - // ErrUnsupported reports that the input isn't supported. - ErrUnsupported = errors.New("snappy: unsupported input") - - errUnsupportedLiteralLength = errors.New("snappy: unsupported literal length") -) - -// DecodedLen returns the length of the decoded block. -func DecodedLen(src []byte) (int, error) { - v, _, err := decodedLen(src) - return v, err -} - -// decodedLen returns the length of the decoded block and the number of bytes -// that the length header occupied. -func decodedLen(src []byte) (blockLen, headerLen int, err error) { - v, n := binary.Uvarint(src) - if n <= 0 || v > 0xffffffff { - return 0, 0, ErrCorrupt - } - - const wordSize = 32 << (^uint(0) >> 32 & 1) - if wordSize == 32 && v > 0x7fffffff { - return 0, 0, ErrTooLarge - } - return int(v), n, nil -} - -const ( - decodeErrCodeCorrupt = 1 - decodeErrCodeUnsupportedLiteralLength = 2 -) - -// Decode returns the decoded form of src. The returned slice may be a sub- -// slice of dst if dst was large enough to hold the entire decoded block. -// Otherwise, a newly allocated slice will be returned. -// -// The dst and src must not overlap. It is valid to pass a nil dst. -func Decode(dst, src []byte) ([]byte, error) { - dLen, s, err := decodedLen(src) - if err != nil { - return nil, err - } - if dLen <= len(dst) { - dst = dst[:dLen] - } else { - dst = make([]byte, dLen) - } - switch decode(dst, src[s:]) { - case 0: - return dst, nil - case decodeErrCodeUnsupportedLiteralLength: - return nil, errUnsupportedLiteralLength - } - return nil, ErrCorrupt -} - -// NewReader returns a new Reader that decompresses from r, using the framing -// format described at -// https://github.com/google/snappy/blob/master/framing_format.txt -func NewReader(r io.Reader) *Reader { - return &Reader{ - r: r, - decoded: make([]byte, maxBlockSize), - buf: make([]byte, maxEncodedLenOfMaxBlockSize+checksumSize), - } -} - -// Reader is an io.Reader that can read Snappy-compressed bytes. -type Reader struct { - r io.Reader - err error - decoded []byte - buf []byte - // decoded[i:j] contains decoded bytes that have not yet been passed on. - i, j int - readHeader bool -} - -// Reset discards any buffered data, resets all state, and switches the Snappy -// reader to read from r. This permits reusing a Reader rather than allocating -// a new one. -func (r *Reader) Reset(reader io.Reader) { - r.r = reader - r.err = nil - r.i = 0 - r.j = 0 - r.readHeader = false -} - -func (r *Reader) readFull(p []byte, allowEOF bool) (ok bool) { - if _, r.err = io.ReadFull(r.r, p); r.err != nil { - if r.err == io.ErrUnexpectedEOF || (r.err == io.EOF && !allowEOF) { - r.err = ErrCorrupt - } - return false - } - return true -} - -// Read satisfies the io.Reader interface. -func (r *Reader) Read(p []byte) (int, error) { - if r.err != nil { - return 0, r.err - } - for { - if r.i < r.j { - n := copy(p, r.decoded[r.i:r.j]) - r.i += n - return n, nil - } - if !r.readFull(r.buf[:4], true) { - return 0, r.err - } - chunkType := r.buf[0] - if !r.readHeader { - if chunkType != chunkTypeStreamIdentifier { - r.err = ErrCorrupt - return 0, r.err - } - r.readHeader = true - } - chunkLen := int(r.buf[1]) | int(r.buf[2])<<8 | int(r.buf[3])<<16 - if chunkLen > len(r.buf) { - r.err = ErrUnsupported - return 0, r.err - } - - // The chunk types are specified at - // https://github.com/google/snappy/blob/master/framing_format.txt - switch chunkType { - case chunkTypeCompressedData: - // Section 4.2. Compressed data (chunk type 0x00). - if chunkLen < checksumSize { - r.err = ErrCorrupt - return 0, r.err - } - buf := r.buf[:chunkLen] - if !r.readFull(buf, false) { - return 0, r.err - } - checksum := uint32(buf[0]) | uint32(buf[1])<<8 | uint32(buf[2])<<16 | uint32(buf[3])<<24 - buf = buf[checksumSize:] - - n, err := DecodedLen(buf) - if err != nil { - r.err = err - return 0, r.err - } - if n > len(r.decoded) { - r.err = ErrCorrupt - return 0, r.err - } - if _, err := Decode(r.decoded, buf); err != nil { - r.err = err - return 0, r.err - } - if crc(r.decoded[:n]) != checksum { - r.err = ErrCorrupt - return 0, r.err - } - r.i, r.j = 0, n - continue - - case chunkTypeUncompressedData: - // Section 4.3. Uncompressed data (chunk type 0x01). - if chunkLen < checksumSize { - r.err = ErrCorrupt - return 0, r.err - } - buf := r.buf[:checksumSize] - if !r.readFull(buf, false) { - return 0, r.err - } - checksum := uint32(buf[0]) | uint32(buf[1])<<8 | uint32(buf[2])<<16 | uint32(buf[3])<<24 - // Read directly into r.decoded instead of via r.buf. - n := chunkLen - checksumSize - if n > len(r.decoded) { - r.err = ErrCorrupt - return 0, r.err - } - if !r.readFull(r.decoded[:n], false) { - return 0, r.err - } - if crc(r.decoded[:n]) != checksum { - r.err = ErrCorrupt - return 0, r.err - } - r.i, r.j = 0, n - continue - - case chunkTypeStreamIdentifier: - // Section 4.1. Stream identifier (chunk type 0xff). - if chunkLen != len(magicBody) { - r.err = ErrCorrupt - return 0, r.err - } - if !r.readFull(r.buf[:len(magicBody)], false) { - return 0, r.err - } - for i := 0; i < len(magicBody); i++ { - if r.buf[i] != magicBody[i] { - r.err = ErrCorrupt - return 0, r.err - } - } - continue - } - - if chunkType <= 0x7f { - // Section 4.5. Reserved unskippable chunks (chunk types 0x02-0x7f). - r.err = ErrUnsupported - return 0, r.err - } - // Section 4.4 Padding (chunk type 0xfe). - // Section 4.6. Reserved skippable chunks (chunk types 0x80-0xfd). - if !r.readFull(r.buf[:chunkLen], false) { - return 0, r.err - } - } -} diff --git a/vendor/github.com/golang/snappy/decode_amd64.go b/vendor/github.com/golang/snappy/decode_amd64.go deleted file mode 100644 index fcd192b..0000000 --- a/vendor/github.com/golang/snappy/decode_amd64.go +++ /dev/null @@ -1,14 +0,0 @@ -// Copyright 2016 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build !appengine -// +build gc -// +build !noasm - -package snappy - -// decode has the same semantics as in decode_other.go. -// -//go:noescape -func decode(dst, src []byte) int diff --git a/vendor/github.com/golang/snappy/decode_amd64.s b/vendor/github.com/golang/snappy/decode_amd64.s deleted file mode 100644 index e6179f6..0000000 --- a/vendor/github.com/golang/snappy/decode_amd64.s +++ /dev/null @@ -1,490 +0,0 @@ -// Copyright 2016 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build !appengine -// +build gc -// +build !noasm - -#include "textflag.h" - -// The asm code generally follows the pure Go code in decode_other.go, except -// where marked with a "!!!". - -// func decode(dst, src []byte) int -// -// All local variables fit into registers. The non-zero stack size is only to -// spill registers and push args when issuing a CALL. The register allocation: -// - AX scratch -// - BX scratch -// - CX length or x -// - DX offset -// - SI &src[s] -// - DI &dst[d] -// + R8 dst_base -// + R9 dst_len -// + R10 dst_base + dst_len -// + R11 src_base -// + R12 src_len -// + R13 src_base + src_len -// - R14 used by doCopy -// - R15 used by doCopy -// -// The registers R8-R13 (marked with a "+") are set at the start of the -// function, and after a CALL returns, and are not otherwise modified. -// -// The d variable is implicitly DI - R8, and len(dst)-d is R10 - DI. -// The s variable is implicitly SI - R11, and len(src)-s is R13 - SI. -TEXT ·decode(SB), NOSPLIT, $48-56 - // Initialize SI, DI and R8-R13. - MOVQ dst_base+0(FP), R8 - MOVQ dst_len+8(FP), R9 - MOVQ R8, DI - MOVQ R8, R10 - ADDQ R9, R10 - MOVQ src_base+24(FP), R11 - MOVQ src_len+32(FP), R12 - MOVQ R11, SI - MOVQ R11, R13 - ADDQ R12, R13 - -loop: - // for s < len(src) - CMPQ SI, R13 - JEQ end - - // CX = uint32(src[s]) - // - // switch src[s] & 0x03 - MOVBLZX (SI), CX - MOVL CX, BX - ANDL $3, BX - CMPL BX, $1 - JAE tagCopy - - // ---------------------------------------- - // The code below handles literal tags. - - // case tagLiteral: - // x := uint32(src[s] >> 2) - // switch - SHRL $2, CX - CMPL CX, $60 - JAE tagLit60Plus - - // case x < 60: - // s++ - INCQ SI - -doLit: - // This is the end of the inner "switch", when we have a literal tag. - // - // We assume that CX == x and x fits in a uint32, where x is the variable - // used in the pure Go decode_other.go code. - - // length = int(x) + 1 - // - // Unlike the pure Go code, we don't need to check if length <= 0 because - // CX can hold 64 bits, so the increment cannot overflow. - INCQ CX - - // Prepare to check if copying length bytes will run past the end of dst or - // src. - // - // AX = len(dst) - d - // BX = len(src) - s - MOVQ R10, AX - SUBQ DI, AX - MOVQ R13, BX - SUBQ SI, BX - - // !!! Try a faster technique for short (16 or fewer bytes) copies. - // - // if length > 16 || len(dst)-d < 16 || len(src)-s < 16 { - // goto callMemmove // Fall back on calling runtime·memmove. - // } - // - // The C++ snappy code calls this TryFastAppend. It also checks len(src)-s - // against 21 instead of 16, because it cannot assume that all of its input - // is contiguous in memory and so it needs to leave enough source bytes to - // read the next tag without refilling buffers, but Go's Decode assumes - // contiguousness (the src argument is a []byte). - CMPQ CX, $16 - JGT callMemmove - CMPQ AX, $16 - JLT callMemmove - CMPQ BX, $16 - JLT callMemmove - - // !!! Implement the copy from src to dst as a 16-byte load and store. - // (Decode's documentation says that dst and src must not overlap.) - // - // This always copies 16 bytes, instead of only length bytes, but that's - // OK. If the input is a valid Snappy encoding then subsequent iterations - // will fix up the overrun. Otherwise, Decode returns a nil []byte (and a - // non-nil error), so the overrun will be ignored. - // - // Note that on amd64, it is legal and cheap to issue unaligned 8-byte or - // 16-byte loads and stores. This technique probably wouldn't be as - // effective on architectures that are fussier about alignment. - MOVOU 0(SI), X0 - MOVOU X0, 0(DI) - - // d += length - // s += length - ADDQ CX, DI - ADDQ CX, SI - JMP loop - -callMemmove: - // if length > len(dst)-d || length > len(src)-s { etc } - CMPQ CX, AX - JGT errCorrupt - CMPQ CX, BX - JGT errCorrupt - - // copy(dst[d:], src[s:s+length]) - // - // This means calling runtime·memmove(&dst[d], &src[s], length), so we push - // DI, SI and CX as arguments. Coincidentally, we also need to spill those - // three registers to the stack, to save local variables across the CALL. - MOVQ DI, 0(SP) - MOVQ SI, 8(SP) - MOVQ CX, 16(SP) - MOVQ DI, 24(SP) - MOVQ SI, 32(SP) - MOVQ CX, 40(SP) - CALL runtime·memmove(SB) - - // Restore local variables: unspill registers from the stack and - // re-calculate R8-R13. - MOVQ 24(SP), DI - MOVQ 32(SP), SI - MOVQ 40(SP), CX - MOVQ dst_base+0(FP), R8 - MOVQ dst_len+8(FP), R9 - MOVQ R8, R10 - ADDQ R9, R10 - MOVQ src_base+24(FP), R11 - MOVQ src_len+32(FP), R12 - MOVQ R11, R13 - ADDQ R12, R13 - - // d += length - // s += length - ADDQ CX, DI - ADDQ CX, SI - JMP loop - -tagLit60Plus: - // !!! This fragment does the - // - // s += x - 58; if uint(s) > uint(len(src)) { etc } - // - // checks. In the asm version, we code it once instead of once per switch case. - ADDQ CX, SI - SUBQ $58, SI - MOVQ SI, BX - SUBQ R11, BX - CMPQ BX, R12 - JA errCorrupt - - // case x == 60: - CMPL CX, $61 - JEQ tagLit61 - JA tagLit62Plus - - // x = uint32(src[s-1]) - MOVBLZX -1(SI), CX - JMP doLit - -tagLit61: - // case x == 61: - // x = uint32(src[s-2]) | uint32(src[s-1])<<8 - MOVWLZX -2(SI), CX - JMP doLit - -tagLit62Plus: - CMPL CX, $62 - JA tagLit63 - - // case x == 62: - // x = uint32(src[s-3]) | uint32(src[s-2])<<8 | uint32(src[s-1])<<16 - MOVWLZX -3(SI), CX - MOVBLZX -1(SI), BX - SHLL $16, BX - ORL BX, CX - JMP doLit - -tagLit63: - // case x == 63: - // x = uint32(src[s-4]) | uint32(src[s-3])<<8 | uint32(src[s-2])<<16 | uint32(src[s-1])<<24 - MOVL -4(SI), CX - JMP doLit - -// The code above handles literal tags. -// ---------------------------------------- -// The code below handles copy tags. - -tagCopy4: - // case tagCopy4: - // s += 5 - ADDQ $5, SI - - // if uint(s) > uint(len(src)) { etc } - MOVQ SI, BX - SUBQ R11, BX - CMPQ BX, R12 - JA errCorrupt - - // length = 1 + int(src[s-5])>>2 - SHRQ $2, CX - INCQ CX - - // offset = int(uint32(src[s-4]) | uint32(src[s-3])<<8 | uint32(src[s-2])<<16 | uint32(src[s-1])<<24) - MOVLQZX -4(SI), DX - JMP doCopy - -tagCopy2: - // case tagCopy2: - // s += 3 - ADDQ $3, SI - - // if uint(s) > uint(len(src)) { etc } - MOVQ SI, BX - SUBQ R11, BX - CMPQ BX, R12 - JA errCorrupt - - // length = 1 + int(src[s-3])>>2 - SHRQ $2, CX - INCQ CX - - // offset = int(uint32(src[s-2]) | uint32(src[s-1])<<8) - MOVWQZX -2(SI), DX - JMP doCopy - -tagCopy: - // We have a copy tag. We assume that: - // - BX == src[s] & 0x03 - // - CX == src[s] - CMPQ BX, $2 - JEQ tagCopy2 - JA tagCopy4 - - // case tagCopy1: - // s += 2 - ADDQ $2, SI - - // if uint(s) > uint(len(src)) { etc } - MOVQ SI, BX - SUBQ R11, BX - CMPQ BX, R12 - JA errCorrupt - - // offset = int(uint32(src[s-2])&0xe0<<3 | uint32(src[s-1])) - MOVQ CX, DX - ANDQ $0xe0, DX - SHLQ $3, DX - MOVBQZX -1(SI), BX - ORQ BX, DX - - // length = 4 + int(src[s-2])>>2&0x7 - SHRQ $2, CX - ANDQ $7, CX - ADDQ $4, CX - -doCopy: - // This is the end of the outer "switch", when we have a copy tag. - // - // We assume that: - // - CX == length && CX > 0 - // - DX == offset - - // if offset <= 0 { etc } - CMPQ DX, $0 - JLE errCorrupt - - // if d < offset { etc } - MOVQ DI, BX - SUBQ R8, BX - CMPQ BX, DX - JLT errCorrupt - - // if length > len(dst)-d { etc } - MOVQ R10, BX - SUBQ DI, BX - CMPQ CX, BX - JGT errCorrupt - - // forwardCopy(dst[d:d+length], dst[d-offset:]); d += length - // - // Set: - // - R14 = len(dst)-d - // - R15 = &dst[d-offset] - MOVQ R10, R14 - SUBQ DI, R14 - MOVQ DI, R15 - SUBQ DX, R15 - - // !!! Try a faster technique for short (16 or fewer bytes) forward copies. - // - // First, try using two 8-byte load/stores, similar to the doLit technique - // above. Even if dst[d:d+length] and dst[d-offset:] can overlap, this is - // still OK if offset >= 8. Note that this has to be two 8-byte load/stores - // and not one 16-byte load/store, and the first store has to be before the - // second load, due to the overlap if offset is in the range [8, 16). - // - // if length > 16 || offset < 8 || len(dst)-d < 16 { - // goto slowForwardCopy - // } - // copy 16 bytes - // d += length - CMPQ CX, $16 - JGT slowForwardCopy - CMPQ DX, $8 - JLT slowForwardCopy - CMPQ R14, $16 - JLT slowForwardCopy - MOVQ 0(R15), AX - MOVQ AX, 0(DI) - MOVQ 8(R15), BX - MOVQ BX, 8(DI) - ADDQ CX, DI - JMP loop - -slowForwardCopy: - // !!! If the forward copy is longer than 16 bytes, or if offset < 8, we - // can still try 8-byte load stores, provided we can overrun up to 10 extra - // bytes. As above, the overrun will be fixed up by subsequent iterations - // of the outermost loop. - // - // The C++ snappy code calls this technique IncrementalCopyFastPath. Its - // commentary says: - // - // ---- - // - // The main part of this loop is a simple copy of eight bytes at a time - // until we've copied (at least) the requested amount of bytes. However, - // if d and d-offset are less than eight bytes apart (indicating a - // repeating pattern of length < 8), we first need to expand the pattern in - // order to get the correct results. For instance, if the buffer looks like - // this, with the eight-byte and patterns marked as - // intervals: - // - // abxxxxxxxxxxxx - // [------] d-offset - // [------] d - // - // a single eight-byte copy from to will repeat the pattern - // once, after which we can move two bytes without moving : - // - // ababxxxxxxxxxx - // [------] d-offset - // [------] d - // - // and repeat the exercise until the two no longer overlap. - // - // This allows us to do very well in the special case of one single byte - // repeated many times, without taking a big hit for more general cases. - // - // The worst case of extra writing past the end of the match occurs when - // offset == 1 and length == 1; the last copy will read from byte positions - // [0..7] and write to [4..11], whereas it was only supposed to write to - // position 1. Thus, ten excess bytes. - // - // ---- - // - // That "10 byte overrun" worst case is confirmed by Go's - // TestSlowForwardCopyOverrun, which also tests the fixUpSlowForwardCopy - // and finishSlowForwardCopy algorithm. - // - // if length > len(dst)-d-10 { - // goto verySlowForwardCopy - // } - SUBQ $10, R14 - CMPQ CX, R14 - JGT verySlowForwardCopy - -makeOffsetAtLeast8: - // !!! As above, expand the pattern so that offset >= 8 and we can use - // 8-byte load/stores. - // - // for offset < 8 { - // copy 8 bytes from dst[d-offset:] to dst[d:] - // length -= offset - // d += offset - // offset += offset - // // The two previous lines together means that d-offset, and therefore - // // R15, is unchanged. - // } - CMPQ DX, $8 - JGE fixUpSlowForwardCopy - MOVQ (R15), BX - MOVQ BX, (DI) - SUBQ DX, CX - ADDQ DX, DI - ADDQ DX, DX - JMP makeOffsetAtLeast8 - -fixUpSlowForwardCopy: - // !!! Add length (which might be negative now) to d (implied by DI being - // &dst[d]) so that d ends up at the right place when we jump back to the - // top of the loop. Before we do that, though, we save DI to AX so that, if - // length is positive, copying the remaining length bytes will write to the - // right place. - MOVQ DI, AX - ADDQ CX, DI - -finishSlowForwardCopy: - // !!! Repeat 8-byte load/stores until length <= 0. Ending with a negative - // length means that we overrun, but as above, that will be fixed up by - // subsequent iterations of the outermost loop. - CMPQ CX, $0 - JLE loop - MOVQ (R15), BX - MOVQ BX, (AX) - ADDQ $8, R15 - ADDQ $8, AX - SUBQ $8, CX - JMP finishSlowForwardCopy - -verySlowForwardCopy: - // verySlowForwardCopy is a simple implementation of forward copy. In C - // parlance, this is a do/while loop instead of a while loop, since we know - // that length > 0. In Go syntax: - // - // for { - // dst[d] = dst[d - offset] - // d++ - // length-- - // if length == 0 { - // break - // } - // } - MOVB (R15), BX - MOVB BX, (DI) - INCQ R15 - INCQ DI - DECQ CX - JNZ verySlowForwardCopy - JMP loop - -// The code above handles copy tags. -// ---------------------------------------- - -end: - // This is the end of the "for s < len(src)". - // - // if d != len(dst) { etc } - CMPQ DI, R10 - JNE errCorrupt - - // return 0 - MOVQ $0, ret+48(FP) - RET - -errCorrupt: - // return decodeErrCodeCorrupt - MOVQ $1, ret+48(FP) - RET diff --git a/vendor/github.com/golang/snappy/decode_other.go b/vendor/github.com/golang/snappy/decode_other.go deleted file mode 100644 index 8c9f204..0000000 --- a/vendor/github.com/golang/snappy/decode_other.go +++ /dev/null @@ -1,101 +0,0 @@ -// Copyright 2016 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build !amd64 appengine !gc noasm - -package snappy - -// decode writes the decoding of src to dst. It assumes that the varint-encoded -// length of the decompressed bytes has already been read, and that len(dst) -// equals that length. -// -// It returns 0 on success or a decodeErrCodeXxx error code on failure. -func decode(dst, src []byte) int { - var d, s, offset, length int - for s < len(src) { - switch src[s] & 0x03 { - case tagLiteral: - x := uint32(src[s] >> 2) - switch { - case x < 60: - s++ - case x == 60: - s += 2 - if uint(s) > uint(len(src)) { // The uint conversions catch overflow from the previous line. - return decodeErrCodeCorrupt - } - x = uint32(src[s-1]) - case x == 61: - s += 3 - if uint(s) > uint(len(src)) { // The uint conversions catch overflow from the previous line. - return decodeErrCodeCorrupt - } - x = uint32(src[s-2]) | uint32(src[s-1])<<8 - case x == 62: - s += 4 - if uint(s) > uint(len(src)) { // The uint conversions catch overflow from the previous line. - return decodeErrCodeCorrupt - } - x = uint32(src[s-3]) | uint32(src[s-2])<<8 | uint32(src[s-1])<<16 - case x == 63: - s += 5 - if uint(s) > uint(len(src)) { // The uint conversions catch overflow from the previous line. - return decodeErrCodeCorrupt - } - x = uint32(src[s-4]) | uint32(src[s-3])<<8 | uint32(src[s-2])<<16 | uint32(src[s-1])<<24 - } - length = int(x) + 1 - if length <= 0 { - return decodeErrCodeUnsupportedLiteralLength - } - if length > len(dst)-d || length > len(src)-s { - return decodeErrCodeCorrupt - } - copy(dst[d:], src[s:s+length]) - d += length - s += length - continue - - case tagCopy1: - s += 2 - if uint(s) > uint(len(src)) { // The uint conversions catch overflow from the previous line. - return decodeErrCodeCorrupt - } - length = 4 + int(src[s-2])>>2&0x7 - offset = int(uint32(src[s-2])&0xe0<<3 | uint32(src[s-1])) - - case tagCopy2: - s += 3 - if uint(s) > uint(len(src)) { // The uint conversions catch overflow from the previous line. - return decodeErrCodeCorrupt - } - length = 1 + int(src[s-3])>>2 - offset = int(uint32(src[s-2]) | uint32(src[s-1])<<8) - - case tagCopy4: - s += 5 - if uint(s) > uint(len(src)) { // The uint conversions catch overflow from the previous line. - return decodeErrCodeCorrupt - } - length = 1 + int(src[s-5])>>2 - offset = int(uint32(src[s-4]) | uint32(src[s-3])<<8 | uint32(src[s-2])<<16 | uint32(src[s-1])<<24) - } - - if offset <= 0 || d < offset || length > len(dst)-d { - return decodeErrCodeCorrupt - } - // Copy from an earlier sub-slice of dst to a later sub-slice. Unlike - // the built-in copy function, this byte-by-byte copy always runs - // forwards, even if the slices overlap. Conceptually, this is: - // - // d += forwardCopy(dst[d:d+length], dst[d-offset:]) - for end := d + length; d != end; d++ { - dst[d] = dst[d-offset] - } - } - if d != len(dst) { - return decodeErrCodeCorrupt - } - return 0 -} diff --git a/vendor/github.com/golang/snappy/encode.go b/vendor/github.com/golang/snappy/encode.go deleted file mode 100644 index 8d393e9..0000000 --- a/vendor/github.com/golang/snappy/encode.go +++ /dev/null @@ -1,285 +0,0 @@ -// Copyright 2011 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package snappy - -import ( - "encoding/binary" - "errors" - "io" -) - -// Encode returns the encoded form of src. The returned slice may be a sub- -// slice of dst if dst was large enough to hold the entire encoded block. -// Otherwise, a newly allocated slice will be returned. -// -// The dst and src must not overlap. It is valid to pass a nil dst. -func Encode(dst, src []byte) []byte { - if n := MaxEncodedLen(len(src)); n < 0 { - panic(ErrTooLarge) - } else if len(dst) < n { - dst = make([]byte, n) - } - - // The block starts with the varint-encoded length of the decompressed bytes. - d := binary.PutUvarint(dst, uint64(len(src))) - - for len(src) > 0 { - p := src - src = nil - if len(p) > maxBlockSize { - p, src = p[:maxBlockSize], p[maxBlockSize:] - } - if len(p) < minNonLiteralBlockSize { - d += emitLiteral(dst[d:], p) - } else { - d += encodeBlock(dst[d:], p) - } - } - return dst[:d] -} - -// inputMargin is the minimum number of extra input bytes to keep, inside -// encodeBlock's inner loop. On some architectures, this margin lets us -// implement a fast path for emitLiteral, where the copy of short (<= 16 byte) -// literals can be implemented as a single load to and store from a 16-byte -// register. That literal's actual length can be as short as 1 byte, so this -// can copy up to 15 bytes too much, but that's OK as subsequent iterations of -// the encoding loop will fix up the copy overrun, and this inputMargin ensures -// that we don't overrun the dst and src buffers. -const inputMargin = 16 - 1 - -// minNonLiteralBlockSize is the minimum size of the input to encodeBlock that -// could be encoded with a copy tag. This is the minimum with respect to the -// algorithm used by encodeBlock, not a minimum enforced by the file format. -// -// The encoded output must start with at least a 1 byte literal, as there are -// no previous bytes to copy. A minimal (1 byte) copy after that, generated -// from an emitCopy call in encodeBlock's main loop, would require at least -// another inputMargin bytes, for the reason above: we want any emitLiteral -// calls inside encodeBlock's main loop to use the fast path if possible, which -// requires being able to overrun by inputMargin bytes. Thus, -// minNonLiteralBlockSize equals 1 + 1 + inputMargin. -// -// The C++ code doesn't use this exact threshold, but it could, as discussed at -// https://groups.google.com/d/topic/snappy-compression/oGbhsdIJSJ8/discussion -// The difference between Go (2+inputMargin) and C++ (inputMargin) is purely an -// optimization. It should not affect the encoded form. This is tested by -// TestSameEncodingAsCppShortCopies. -const minNonLiteralBlockSize = 1 + 1 + inputMargin - -// MaxEncodedLen returns the maximum length of a snappy block, given its -// uncompressed length. -// -// It will return a negative value if srcLen is too large to encode. -func MaxEncodedLen(srcLen int) int { - n := uint64(srcLen) - if n > 0xffffffff { - return -1 - } - // Compressed data can be defined as: - // compressed := item* literal* - // item := literal* copy - // - // The trailing literal sequence has a space blowup of at most 62/60 - // since a literal of length 60 needs one tag byte + one extra byte - // for length information. - // - // Item blowup is trickier to measure. Suppose the "copy" op copies - // 4 bytes of data. Because of a special check in the encoding code, - // we produce a 4-byte copy only if the offset is < 65536. Therefore - // the copy op takes 3 bytes to encode, and this type of item leads - // to at most the 62/60 blowup for representing literals. - // - // Suppose the "copy" op copies 5 bytes of data. If the offset is big - // enough, it will take 5 bytes to encode the copy op. Therefore the - // worst case here is a one-byte literal followed by a five-byte copy. - // That is, 6 bytes of input turn into 7 bytes of "compressed" data. - // - // This last factor dominates the blowup, so the final estimate is: - n = 32 + n + n/6 - if n > 0xffffffff { - return -1 - } - return int(n) -} - -var errClosed = errors.New("snappy: Writer is closed") - -// NewWriter returns a new Writer that compresses to w. -// -// The Writer returned does not buffer writes. There is no need to Flush or -// Close such a Writer. -// -// Deprecated: the Writer returned is not suitable for many small writes, only -// for few large writes. Use NewBufferedWriter instead, which is efficient -// regardless of the frequency and shape of the writes, and remember to Close -// that Writer when done. -func NewWriter(w io.Writer) *Writer { - return &Writer{ - w: w, - obuf: make([]byte, obufLen), - } -} - -// NewBufferedWriter returns a new Writer that compresses to w, using the -// framing format described at -// https://github.com/google/snappy/blob/master/framing_format.txt -// -// The Writer returned buffers writes. Users must call Close to guarantee all -// data has been forwarded to the underlying io.Writer. They may also call -// Flush zero or more times before calling Close. -func NewBufferedWriter(w io.Writer) *Writer { - return &Writer{ - w: w, - ibuf: make([]byte, 0, maxBlockSize), - obuf: make([]byte, obufLen), - } -} - -// Writer is an io.Writer that can write Snappy-compressed bytes. -type Writer struct { - w io.Writer - err error - - // ibuf is a buffer for the incoming (uncompressed) bytes. - // - // Its use is optional. For backwards compatibility, Writers created by the - // NewWriter function have ibuf == nil, do not buffer incoming bytes, and - // therefore do not need to be Flush'ed or Close'd. - ibuf []byte - - // obuf is a buffer for the outgoing (compressed) bytes. - obuf []byte - - // wroteStreamHeader is whether we have written the stream header. - wroteStreamHeader bool -} - -// Reset discards the writer's state and switches the Snappy writer to write to -// w. This permits reusing a Writer rather than allocating a new one. -func (w *Writer) Reset(writer io.Writer) { - w.w = writer - w.err = nil - if w.ibuf != nil { - w.ibuf = w.ibuf[:0] - } - w.wroteStreamHeader = false -} - -// Write satisfies the io.Writer interface. -func (w *Writer) Write(p []byte) (nRet int, errRet error) { - if w.ibuf == nil { - // Do not buffer incoming bytes. This does not perform or compress well - // if the caller of Writer.Write writes many small slices. This - // behavior is therefore deprecated, but still supported for backwards - // compatibility with code that doesn't explicitly Flush or Close. - return w.write(p) - } - - // The remainder of this method is based on bufio.Writer.Write from the - // standard library. - - for len(p) > (cap(w.ibuf)-len(w.ibuf)) && w.err == nil { - var n int - if len(w.ibuf) == 0 { - // Large write, empty buffer. - // Write directly from p to avoid copy. - n, _ = w.write(p) - } else { - n = copy(w.ibuf[len(w.ibuf):cap(w.ibuf)], p) - w.ibuf = w.ibuf[:len(w.ibuf)+n] - w.Flush() - } - nRet += n - p = p[n:] - } - if w.err != nil { - return nRet, w.err - } - n := copy(w.ibuf[len(w.ibuf):cap(w.ibuf)], p) - w.ibuf = w.ibuf[:len(w.ibuf)+n] - nRet += n - return nRet, nil -} - -func (w *Writer) write(p []byte) (nRet int, errRet error) { - if w.err != nil { - return 0, w.err - } - for len(p) > 0 { - obufStart := len(magicChunk) - if !w.wroteStreamHeader { - w.wroteStreamHeader = true - copy(w.obuf, magicChunk) - obufStart = 0 - } - - var uncompressed []byte - if len(p) > maxBlockSize { - uncompressed, p = p[:maxBlockSize], p[maxBlockSize:] - } else { - uncompressed, p = p, nil - } - checksum := crc(uncompressed) - - // Compress the buffer, discarding the result if the improvement - // isn't at least 12.5%. - compressed := Encode(w.obuf[obufHeaderLen:], uncompressed) - chunkType := uint8(chunkTypeCompressedData) - chunkLen := 4 + len(compressed) - obufEnd := obufHeaderLen + len(compressed) - if len(compressed) >= len(uncompressed)-len(uncompressed)/8 { - chunkType = chunkTypeUncompressedData - chunkLen = 4 + len(uncompressed) - obufEnd = obufHeaderLen - } - - // Fill in the per-chunk header that comes before the body. - w.obuf[len(magicChunk)+0] = chunkType - w.obuf[len(magicChunk)+1] = uint8(chunkLen >> 0) - w.obuf[len(magicChunk)+2] = uint8(chunkLen >> 8) - w.obuf[len(magicChunk)+3] = uint8(chunkLen >> 16) - w.obuf[len(magicChunk)+4] = uint8(checksum >> 0) - w.obuf[len(magicChunk)+5] = uint8(checksum >> 8) - w.obuf[len(magicChunk)+6] = uint8(checksum >> 16) - w.obuf[len(magicChunk)+7] = uint8(checksum >> 24) - - if _, err := w.w.Write(w.obuf[obufStart:obufEnd]); err != nil { - w.err = err - return nRet, err - } - if chunkType == chunkTypeUncompressedData { - if _, err := w.w.Write(uncompressed); err != nil { - w.err = err - return nRet, err - } - } - nRet += len(uncompressed) - } - return nRet, nil -} - -// Flush flushes the Writer to its underlying io.Writer. -func (w *Writer) Flush() error { - if w.err != nil { - return w.err - } - if len(w.ibuf) == 0 { - return nil - } - w.write(w.ibuf) - w.ibuf = w.ibuf[:0] - return w.err -} - -// Close calls Flush and then closes the Writer. -func (w *Writer) Close() error { - w.Flush() - ret := w.err - if w.err == nil { - w.err = errClosed - } - return ret -} diff --git a/vendor/github.com/golang/snappy/encode_amd64.go b/vendor/github.com/golang/snappy/encode_amd64.go deleted file mode 100644 index 150d91b..0000000 --- a/vendor/github.com/golang/snappy/encode_amd64.go +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2016 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build !appengine -// +build gc -// +build !noasm - -package snappy - -// emitLiteral has the same semantics as in encode_other.go. -// -//go:noescape -func emitLiteral(dst, lit []byte) int - -// emitCopy has the same semantics as in encode_other.go. -// -//go:noescape -func emitCopy(dst []byte, offset, length int) int - -// extendMatch has the same semantics as in encode_other.go. -// -//go:noescape -func extendMatch(src []byte, i, j int) int - -// encodeBlock has the same semantics as in encode_other.go. -// -//go:noescape -func encodeBlock(dst, src []byte) (d int) diff --git a/vendor/github.com/golang/snappy/encode_amd64.s b/vendor/github.com/golang/snappy/encode_amd64.s deleted file mode 100644 index adfd979..0000000 --- a/vendor/github.com/golang/snappy/encode_amd64.s +++ /dev/null @@ -1,730 +0,0 @@ -// Copyright 2016 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build !appengine -// +build gc -// +build !noasm - -#include "textflag.h" - -// The XXX lines assemble on Go 1.4, 1.5 and 1.7, but not 1.6, due to a -// Go toolchain regression. See https://github.com/golang/go/issues/15426 and -// https://github.com/golang/snappy/issues/29 -// -// As a workaround, the package was built with a known good assembler, and -// those instructions were disassembled by "objdump -d" to yield the -// 4e 0f b7 7c 5c 78 movzwq 0x78(%rsp,%r11,2),%r15 -// style comments, in AT&T asm syntax. Note that rsp here is a physical -// register, not Go/asm's SP pseudo-register (see https://golang.org/doc/asm). -// The instructions were then encoded as "BYTE $0x.." sequences, which assemble -// fine on Go 1.6. - -// The asm code generally follows the pure Go code in encode_other.go, except -// where marked with a "!!!". - -// ---------------------------------------------------------------------------- - -// func emitLiteral(dst, lit []byte) int -// -// All local variables fit into registers. The register allocation: -// - AX len(lit) -// - BX n -// - DX return value -// - DI &dst[i] -// - R10 &lit[0] -// -// The 24 bytes of stack space is to call runtime·memmove. -// -// The unusual register allocation of local variables, such as R10 for the -// source pointer, matches the allocation used at the call site in encodeBlock, -// which makes it easier to manually inline this function. -TEXT ·emitLiteral(SB), NOSPLIT, $24-56 - MOVQ dst_base+0(FP), DI - MOVQ lit_base+24(FP), R10 - MOVQ lit_len+32(FP), AX - MOVQ AX, DX - MOVL AX, BX - SUBL $1, BX - - CMPL BX, $60 - JLT oneByte - CMPL BX, $256 - JLT twoBytes - -threeBytes: - MOVB $0xf4, 0(DI) - MOVW BX, 1(DI) - ADDQ $3, DI - ADDQ $3, DX - JMP memmove - -twoBytes: - MOVB $0xf0, 0(DI) - MOVB BX, 1(DI) - ADDQ $2, DI - ADDQ $2, DX - JMP memmove - -oneByte: - SHLB $2, BX - MOVB BX, 0(DI) - ADDQ $1, DI - ADDQ $1, DX - -memmove: - MOVQ DX, ret+48(FP) - - // copy(dst[i:], lit) - // - // This means calling runtime·memmove(&dst[i], &lit[0], len(lit)), so we push - // DI, R10 and AX as arguments. - MOVQ DI, 0(SP) - MOVQ R10, 8(SP) - MOVQ AX, 16(SP) - CALL runtime·memmove(SB) - RET - -// ---------------------------------------------------------------------------- - -// func emitCopy(dst []byte, offset, length int) int -// -// All local variables fit into registers. The register allocation: -// - AX length -// - SI &dst[0] -// - DI &dst[i] -// - R11 offset -// -// The unusual register allocation of local variables, such as R11 for the -// offset, matches the allocation used at the call site in encodeBlock, which -// makes it easier to manually inline this function. -TEXT ·emitCopy(SB), NOSPLIT, $0-48 - MOVQ dst_base+0(FP), DI - MOVQ DI, SI - MOVQ offset+24(FP), R11 - MOVQ length+32(FP), AX - -loop0: - // for length >= 68 { etc } - CMPL AX, $68 - JLT step1 - - // Emit a length 64 copy, encoded as 3 bytes. - MOVB $0xfe, 0(DI) - MOVW R11, 1(DI) - ADDQ $3, DI - SUBL $64, AX - JMP loop0 - -step1: - // if length > 64 { etc } - CMPL AX, $64 - JLE step2 - - // Emit a length 60 copy, encoded as 3 bytes. - MOVB $0xee, 0(DI) - MOVW R11, 1(DI) - ADDQ $3, DI - SUBL $60, AX - -step2: - // if length >= 12 || offset >= 2048 { goto step3 } - CMPL AX, $12 - JGE step3 - CMPL R11, $2048 - JGE step3 - - // Emit the remaining copy, encoded as 2 bytes. - MOVB R11, 1(DI) - SHRL $8, R11 - SHLB $5, R11 - SUBB $4, AX - SHLB $2, AX - ORB AX, R11 - ORB $1, R11 - MOVB R11, 0(DI) - ADDQ $2, DI - - // Return the number of bytes written. - SUBQ SI, DI - MOVQ DI, ret+40(FP) - RET - -step3: - // Emit the remaining copy, encoded as 3 bytes. - SUBL $1, AX - SHLB $2, AX - ORB $2, AX - MOVB AX, 0(DI) - MOVW R11, 1(DI) - ADDQ $3, DI - - // Return the number of bytes written. - SUBQ SI, DI - MOVQ DI, ret+40(FP) - RET - -// ---------------------------------------------------------------------------- - -// func extendMatch(src []byte, i, j int) int -// -// All local variables fit into registers. The register allocation: -// - DX &src[0] -// - SI &src[j] -// - R13 &src[len(src) - 8] -// - R14 &src[len(src)] -// - R15 &src[i] -// -// The unusual register allocation of local variables, such as R15 for a source -// pointer, matches the allocation used at the call site in encodeBlock, which -// makes it easier to manually inline this function. -TEXT ·extendMatch(SB), NOSPLIT, $0-48 - MOVQ src_base+0(FP), DX - MOVQ src_len+8(FP), R14 - MOVQ i+24(FP), R15 - MOVQ j+32(FP), SI - ADDQ DX, R14 - ADDQ DX, R15 - ADDQ DX, SI - MOVQ R14, R13 - SUBQ $8, R13 - -cmp8: - // As long as we are 8 or more bytes before the end of src, we can load and - // compare 8 bytes at a time. If those 8 bytes are equal, repeat. - CMPQ SI, R13 - JA cmp1 - MOVQ (R15), AX - MOVQ (SI), BX - CMPQ AX, BX - JNE bsf - ADDQ $8, R15 - ADDQ $8, SI - JMP cmp8 - -bsf: - // If those 8 bytes were not equal, XOR the two 8 byte values, and return - // the index of the first byte that differs. The BSF instruction finds the - // least significant 1 bit, the amd64 architecture is little-endian, and - // the shift by 3 converts a bit index to a byte index. - XORQ AX, BX - BSFQ BX, BX - SHRQ $3, BX - ADDQ BX, SI - - // Convert from &src[ret] to ret. - SUBQ DX, SI - MOVQ SI, ret+40(FP) - RET - -cmp1: - // In src's tail, compare 1 byte at a time. - CMPQ SI, R14 - JAE extendMatchEnd - MOVB (R15), AX - MOVB (SI), BX - CMPB AX, BX - JNE extendMatchEnd - ADDQ $1, R15 - ADDQ $1, SI - JMP cmp1 - -extendMatchEnd: - // Convert from &src[ret] to ret. - SUBQ DX, SI - MOVQ SI, ret+40(FP) - RET - -// ---------------------------------------------------------------------------- - -// func encodeBlock(dst, src []byte) (d int) -// -// All local variables fit into registers, other than "var table". The register -// allocation: -// - AX . . -// - BX . . -// - CX 56 shift (note that amd64 shifts by non-immediates must use CX). -// - DX 64 &src[0], tableSize -// - SI 72 &src[s] -// - DI 80 &dst[d] -// - R9 88 sLimit -// - R10 . &src[nextEmit] -// - R11 96 prevHash, currHash, nextHash, offset -// - R12 104 &src[base], skip -// - R13 . &src[nextS], &src[len(src) - 8] -// - R14 . len(src), bytesBetweenHashLookups, &src[len(src)], x -// - R15 112 candidate -// -// The second column (56, 64, etc) is the stack offset to spill the registers -// when calling other functions. We could pack this slightly tighter, but it's -// simpler to have a dedicated spill map independent of the function called. -// -// "var table [maxTableSize]uint16" takes up 32768 bytes of stack space. An -// extra 56 bytes, to call other functions, and an extra 64 bytes, to spill -// local variables (registers) during calls gives 32768 + 56 + 64 = 32888. -TEXT ·encodeBlock(SB), 0, $32888-56 - MOVQ dst_base+0(FP), DI - MOVQ src_base+24(FP), SI - MOVQ src_len+32(FP), R14 - - // shift, tableSize := uint32(32-8), 1<<8 - MOVQ $24, CX - MOVQ $256, DX - -calcShift: - // for ; tableSize < maxTableSize && tableSize < len(src); tableSize *= 2 { - // shift-- - // } - CMPQ DX, $16384 - JGE varTable - CMPQ DX, R14 - JGE varTable - SUBQ $1, CX - SHLQ $1, DX - JMP calcShift - -varTable: - // var table [maxTableSize]uint16 - // - // In the asm code, unlike the Go code, we can zero-initialize only the - // first tableSize elements. Each uint16 element is 2 bytes and each MOVOU - // writes 16 bytes, so we can do only tableSize/8 writes instead of the - // 2048 writes that would zero-initialize all of table's 32768 bytes. - SHRQ $3, DX - LEAQ table-32768(SP), BX - PXOR X0, X0 - -memclr: - MOVOU X0, 0(BX) - ADDQ $16, BX - SUBQ $1, DX - JNZ memclr - - // !!! DX = &src[0] - MOVQ SI, DX - - // sLimit := len(src) - inputMargin - MOVQ R14, R9 - SUBQ $15, R9 - - // !!! Pre-emptively spill CX, DX and R9 to the stack. Their values don't - // change for the rest of the function. - MOVQ CX, 56(SP) - MOVQ DX, 64(SP) - MOVQ R9, 88(SP) - - // nextEmit := 0 - MOVQ DX, R10 - - // s := 1 - ADDQ $1, SI - - // nextHash := hash(load32(src, s), shift) - MOVL 0(SI), R11 - IMULL $0x1e35a7bd, R11 - SHRL CX, R11 - -outer: - // for { etc } - - // skip := 32 - MOVQ $32, R12 - - // nextS := s - MOVQ SI, R13 - - // candidate := 0 - MOVQ $0, R15 - -inner0: - // for { etc } - - // s := nextS - MOVQ R13, SI - - // bytesBetweenHashLookups := skip >> 5 - MOVQ R12, R14 - SHRQ $5, R14 - - // nextS = s + bytesBetweenHashLookups - ADDQ R14, R13 - - // skip += bytesBetweenHashLookups - ADDQ R14, R12 - - // if nextS > sLimit { goto emitRemainder } - MOVQ R13, AX - SUBQ DX, AX - CMPQ AX, R9 - JA emitRemainder - - // candidate = int(table[nextHash]) - // XXX: MOVWQZX table-32768(SP)(R11*2), R15 - // XXX: 4e 0f b7 7c 5c 78 movzwq 0x78(%rsp,%r11,2),%r15 - BYTE $0x4e - BYTE $0x0f - BYTE $0xb7 - BYTE $0x7c - BYTE $0x5c - BYTE $0x78 - - // table[nextHash] = uint16(s) - MOVQ SI, AX - SUBQ DX, AX - - // XXX: MOVW AX, table-32768(SP)(R11*2) - // XXX: 66 42 89 44 5c 78 mov %ax,0x78(%rsp,%r11,2) - BYTE $0x66 - BYTE $0x42 - BYTE $0x89 - BYTE $0x44 - BYTE $0x5c - BYTE $0x78 - - // nextHash = hash(load32(src, nextS), shift) - MOVL 0(R13), R11 - IMULL $0x1e35a7bd, R11 - SHRL CX, R11 - - // if load32(src, s) != load32(src, candidate) { continue } break - MOVL 0(SI), AX - MOVL (DX)(R15*1), BX - CMPL AX, BX - JNE inner0 - -fourByteMatch: - // As per the encode_other.go code: - // - // A 4-byte match has been found. We'll later see etc. - - // !!! Jump to a fast path for short (<= 16 byte) literals. See the comment - // on inputMargin in encode.go. - MOVQ SI, AX - SUBQ R10, AX - CMPQ AX, $16 - JLE emitLiteralFastPath - - // ---------------------------------------- - // Begin inline of the emitLiteral call. - // - // d += emitLiteral(dst[d:], src[nextEmit:s]) - - MOVL AX, BX - SUBL $1, BX - - CMPL BX, $60 - JLT inlineEmitLiteralOneByte - CMPL BX, $256 - JLT inlineEmitLiteralTwoBytes - -inlineEmitLiteralThreeBytes: - MOVB $0xf4, 0(DI) - MOVW BX, 1(DI) - ADDQ $3, DI - JMP inlineEmitLiteralMemmove - -inlineEmitLiteralTwoBytes: - MOVB $0xf0, 0(DI) - MOVB BX, 1(DI) - ADDQ $2, DI - JMP inlineEmitLiteralMemmove - -inlineEmitLiteralOneByte: - SHLB $2, BX - MOVB BX, 0(DI) - ADDQ $1, DI - -inlineEmitLiteralMemmove: - // Spill local variables (registers) onto the stack; call; unspill. - // - // copy(dst[i:], lit) - // - // This means calling runtime·memmove(&dst[i], &lit[0], len(lit)), so we push - // DI, R10 and AX as arguments. - MOVQ DI, 0(SP) - MOVQ R10, 8(SP) - MOVQ AX, 16(SP) - ADDQ AX, DI // Finish the "d +=" part of "d += emitLiteral(etc)". - MOVQ SI, 72(SP) - MOVQ DI, 80(SP) - MOVQ R15, 112(SP) - CALL runtime·memmove(SB) - MOVQ 56(SP), CX - MOVQ 64(SP), DX - MOVQ 72(SP), SI - MOVQ 80(SP), DI - MOVQ 88(SP), R9 - MOVQ 112(SP), R15 - JMP inner1 - -inlineEmitLiteralEnd: - // End inline of the emitLiteral call. - // ---------------------------------------- - -emitLiteralFastPath: - // !!! Emit the 1-byte encoding "uint8(len(lit)-1)<<2". - MOVB AX, BX - SUBB $1, BX - SHLB $2, BX - MOVB BX, (DI) - ADDQ $1, DI - - // !!! Implement the copy from lit to dst as a 16-byte load and store. - // (Encode's documentation says that dst and src must not overlap.) - // - // This always copies 16 bytes, instead of only len(lit) bytes, but that's - // OK. Subsequent iterations will fix up the overrun. - // - // Note that on amd64, it is legal and cheap to issue unaligned 8-byte or - // 16-byte loads and stores. This technique probably wouldn't be as - // effective on architectures that are fussier about alignment. - MOVOU 0(R10), X0 - MOVOU X0, 0(DI) - ADDQ AX, DI - -inner1: - // for { etc } - - // base := s - MOVQ SI, R12 - - // !!! offset := base - candidate - MOVQ R12, R11 - SUBQ R15, R11 - SUBQ DX, R11 - - // ---------------------------------------- - // Begin inline of the extendMatch call. - // - // s = extendMatch(src, candidate+4, s+4) - - // !!! R14 = &src[len(src)] - MOVQ src_len+32(FP), R14 - ADDQ DX, R14 - - // !!! R13 = &src[len(src) - 8] - MOVQ R14, R13 - SUBQ $8, R13 - - // !!! R15 = &src[candidate + 4] - ADDQ $4, R15 - ADDQ DX, R15 - - // !!! s += 4 - ADDQ $4, SI - -inlineExtendMatchCmp8: - // As long as we are 8 or more bytes before the end of src, we can load and - // compare 8 bytes at a time. If those 8 bytes are equal, repeat. - CMPQ SI, R13 - JA inlineExtendMatchCmp1 - MOVQ (R15), AX - MOVQ (SI), BX - CMPQ AX, BX - JNE inlineExtendMatchBSF - ADDQ $8, R15 - ADDQ $8, SI - JMP inlineExtendMatchCmp8 - -inlineExtendMatchBSF: - // If those 8 bytes were not equal, XOR the two 8 byte values, and return - // the index of the first byte that differs. The BSF instruction finds the - // least significant 1 bit, the amd64 architecture is little-endian, and - // the shift by 3 converts a bit index to a byte index. - XORQ AX, BX - BSFQ BX, BX - SHRQ $3, BX - ADDQ BX, SI - JMP inlineExtendMatchEnd - -inlineExtendMatchCmp1: - // In src's tail, compare 1 byte at a time. - CMPQ SI, R14 - JAE inlineExtendMatchEnd - MOVB (R15), AX - MOVB (SI), BX - CMPB AX, BX - JNE inlineExtendMatchEnd - ADDQ $1, R15 - ADDQ $1, SI - JMP inlineExtendMatchCmp1 - -inlineExtendMatchEnd: - // End inline of the extendMatch call. - // ---------------------------------------- - - // ---------------------------------------- - // Begin inline of the emitCopy call. - // - // d += emitCopy(dst[d:], base-candidate, s-base) - - // !!! length := s - base - MOVQ SI, AX - SUBQ R12, AX - -inlineEmitCopyLoop0: - // for length >= 68 { etc } - CMPL AX, $68 - JLT inlineEmitCopyStep1 - - // Emit a length 64 copy, encoded as 3 bytes. - MOVB $0xfe, 0(DI) - MOVW R11, 1(DI) - ADDQ $3, DI - SUBL $64, AX - JMP inlineEmitCopyLoop0 - -inlineEmitCopyStep1: - // if length > 64 { etc } - CMPL AX, $64 - JLE inlineEmitCopyStep2 - - // Emit a length 60 copy, encoded as 3 bytes. - MOVB $0xee, 0(DI) - MOVW R11, 1(DI) - ADDQ $3, DI - SUBL $60, AX - -inlineEmitCopyStep2: - // if length >= 12 || offset >= 2048 { goto inlineEmitCopyStep3 } - CMPL AX, $12 - JGE inlineEmitCopyStep3 - CMPL R11, $2048 - JGE inlineEmitCopyStep3 - - // Emit the remaining copy, encoded as 2 bytes. - MOVB R11, 1(DI) - SHRL $8, R11 - SHLB $5, R11 - SUBB $4, AX - SHLB $2, AX - ORB AX, R11 - ORB $1, R11 - MOVB R11, 0(DI) - ADDQ $2, DI - JMP inlineEmitCopyEnd - -inlineEmitCopyStep3: - // Emit the remaining copy, encoded as 3 bytes. - SUBL $1, AX - SHLB $2, AX - ORB $2, AX - MOVB AX, 0(DI) - MOVW R11, 1(DI) - ADDQ $3, DI - -inlineEmitCopyEnd: - // End inline of the emitCopy call. - // ---------------------------------------- - - // nextEmit = s - MOVQ SI, R10 - - // if s >= sLimit { goto emitRemainder } - MOVQ SI, AX - SUBQ DX, AX - CMPQ AX, R9 - JAE emitRemainder - - // As per the encode_other.go code: - // - // We could immediately etc. - - // x := load64(src, s-1) - MOVQ -1(SI), R14 - - // prevHash := hash(uint32(x>>0), shift) - MOVL R14, R11 - IMULL $0x1e35a7bd, R11 - SHRL CX, R11 - - // table[prevHash] = uint16(s-1) - MOVQ SI, AX - SUBQ DX, AX - SUBQ $1, AX - - // XXX: MOVW AX, table-32768(SP)(R11*2) - // XXX: 66 42 89 44 5c 78 mov %ax,0x78(%rsp,%r11,2) - BYTE $0x66 - BYTE $0x42 - BYTE $0x89 - BYTE $0x44 - BYTE $0x5c - BYTE $0x78 - - // currHash := hash(uint32(x>>8), shift) - SHRQ $8, R14 - MOVL R14, R11 - IMULL $0x1e35a7bd, R11 - SHRL CX, R11 - - // candidate = int(table[currHash]) - // XXX: MOVWQZX table-32768(SP)(R11*2), R15 - // XXX: 4e 0f b7 7c 5c 78 movzwq 0x78(%rsp,%r11,2),%r15 - BYTE $0x4e - BYTE $0x0f - BYTE $0xb7 - BYTE $0x7c - BYTE $0x5c - BYTE $0x78 - - // table[currHash] = uint16(s) - ADDQ $1, AX - - // XXX: MOVW AX, table-32768(SP)(R11*2) - // XXX: 66 42 89 44 5c 78 mov %ax,0x78(%rsp,%r11,2) - BYTE $0x66 - BYTE $0x42 - BYTE $0x89 - BYTE $0x44 - BYTE $0x5c - BYTE $0x78 - - // if uint32(x>>8) == load32(src, candidate) { continue } - MOVL (DX)(R15*1), BX - CMPL R14, BX - JEQ inner1 - - // nextHash = hash(uint32(x>>16), shift) - SHRQ $8, R14 - MOVL R14, R11 - IMULL $0x1e35a7bd, R11 - SHRL CX, R11 - - // s++ - ADDQ $1, SI - - // break out of the inner1 for loop, i.e. continue the outer loop. - JMP outer - -emitRemainder: - // if nextEmit < len(src) { etc } - MOVQ src_len+32(FP), AX - ADDQ DX, AX - CMPQ R10, AX - JEQ encodeBlockEnd - - // d += emitLiteral(dst[d:], src[nextEmit:]) - // - // Push args. - MOVQ DI, 0(SP) - MOVQ $0, 8(SP) // Unnecessary, as the callee ignores it, but conservative. - MOVQ $0, 16(SP) // Unnecessary, as the callee ignores it, but conservative. - MOVQ R10, 24(SP) - SUBQ R10, AX - MOVQ AX, 32(SP) - MOVQ AX, 40(SP) // Unnecessary, as the callee ignores it, but conservative. - - // Spill local variables (registers) onto the stack; call; unspill. - MOVQ DI, 80(SP) - CALL ·emitLiteral(SB) - MOVQ 80(SP), DI - - // Finish the "d +=" part of "d += emitLiteral(etc)". - ADDQ 48(SP), DI - -encodeBlockEnd: - MOVQ dst_base+0(FP), AX - SUBQ AX, DI - MOVQ DI, d+48(FP) - RET diff --git a/vendor/github.com/golang/snappy/encode_other.go b/vendor/github.com/golang/snappy/encode_other.go deleted file mode 100644 index dbcae90..0000000 --- a/vendor/github.com/golang/snappy/encode_other.go +++ /dev/null @@ -1,238 +0,0 @@ -// Copyright 2016 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build !amd64 appengine !gc noasm - -package snappy - -func load32(b []byte, i int) uint32 { - b = b[i : i+4 : len(b)] // Help the compiler eliminate bounds checks on the next line. - return uint32(b[0]) | uint32(b[1])<<8 | uint32(b[2])<<16 | uint32(b[3])<<24 -} - -func load64(b []byte, i int) uint64 { - b = b[i : i+8 : len(b)] // Help the compiler eliminate bounds checks on the next line. - return uint64(b[0]) | uint64(b[1])<<8 | uint64(b[2])<<16 | uint64(b[3])<<24 | - uint64(b[4])<<32 | uint64(b[5])<<40 | uint64(b[6])<<48 | uint64(b[7])<<56 -} - -// emitLiteral writes a literal chunk and returns the number of bytes written. -// -// It assumes that: -// dst is long enough to hold the encoded bytes -// 1 <= len(lit) && len(lit) <= 65536 -func emitLiteral(dst, lit []byte) int { - i, n := 0, uint(len(lit)-1) - switch { - case n < 60: - dst[0] = uint8(n)<<2 | tagLiteral - i = 1 - case n < 1<<8: - dst[0] = 60<<2 | tagLiteral - dst[1] = uint8(n) - i = 2 - default: - dst[0] = 61<<2 | tagLiteral - dst[1] = uint8(n) - dst[2] = uint8(n >> 8) - i = 3 - } - return i + copy(dst[i:], lit) -} - -// emitCopy writes a copy chunk and returns the number of bytes written. -// -// It assumes that: -// dst is long enough to hold the encoded bytes -// 1 <= offset && offset <= 65535 -// 4 <= length && length <= 65535 -func emitCopy(dst []byte, offset, length int) int { - i := 0 - // The maximum length for a single tagCopy1 or tagCopy2 op is 64 bytes. The - // threshold for this loop is a little higher (at 68 = 64 + 4), and the - // length emitted down below is is a little lower (at 60 = 64 - 4), because - // it's shorter to encode a length 67 copy as a length 60 tagCopy2 followed - // by a length 7 tagCopy1 (which encodes as 3+2 bytes) than to encode it as - // a length 64 tagCopy2 followed by a length 3 tagCopy2 (which encodes as - // 3+3 bytes). The magic 4 in the 64±4 is because the minimum length for a - // tagCopy1 op is 4 bytes, which is why a length 3 copy has to be an - // encodes-as-3-bytes tagCopy2 instead of an encodes-as-2-bytes tagCopy1. - for length >= 68 { - // Emit a length 64 copy, encoded as 3 bytes. - dst[i+0] = 63<<2 | tagCopy2 - dst[i+1] = uint8(offset) - dst[i+2] = uint8(offset >> 8) - i += 3 - length -= 64 - } - if length > 64 { - // Emit a length 60 copy, encoded as 3 bytes. - dst[i+0] = 59<<2 | tagCopy2 - dst[i+1] = uint8(offset) - dst[i+2] = uint8(offset >> 8) - i += 3 - length -= 60 - } - if length >= 12 || offset >= 2048 { - // Emit the remaining copy, encoded as 3 bytes. - dst[i+0] = uint8(length-1)<<2 | tagCopy2 - dst[i+1] = uint8(offset) - dst[i+2] = uint8(offset >> 8) - return i + 3 - } - // Emit the remaining copy, encoded as 2 bytes. - dst[i+0] = uint8(offset>>8)<<5 | uint8(length-4)<<2 | tagCopy1 - dst[i+1] = uint8(offset) - return i + 2 -} - -// extendMatch returns the largest k such that k <= len(src) and that -// src[i:i+k-j] and src[j:k] have the same contents. -// -// It assumes that: -// 0 <= i && i < j && j <= len(src) -func extendMatch(src []byte, i, j int) int { - for ; j < len(src) && src[i] == src[j]; i, j = i+1, j+1 { - } - return j -} - -func hash(u, shift uint32) uint32 { - return (u * 0x1e35a7bd) >> shift -} - -// encodeBlock encodes a non-empty src to a guaranteed-large-enough dst. It -// assumes that the varint-encoded length of the decompressed bytes has already -// been written. -// -// It also assumes that: -// len(dst) >= MaxEncodedLen(len(src)) && -// minNonLiteralBlockSize <= len(src) && len(src) <= maxBlockSize -func encodeBlock(dst, src []byte) (d int) { - // Initialize the hash table. Its size ranges from 1<<8 to 1<<14 inclusive. - // The table element type is uint16, as s < sLimit and sLimit < len(src) - // and len(src) <= maxBlockSize and maxBlockSize == 65536. - const ( - maxTableSize = 1 << 14 - // tableMask is redundant, but helps the compiler eliminate bounds - // checks. - tableMask = maxTableSize - 1 - ) - shift := uint32(32 - 8) - for tableSize := 1 << 8; tableSize < maxTableSize && tableSize < len(src); tableSize *= 2 { - shift-- - } - // In Go, all array elements are zero-initialized, so there is no advantage - // to a smaller tableSize per se. However, it matches the C++ algorithm, - // and in the asm versions of this code, we can get away with zeroing only - // the first tableSize elements. - var table [maxTableSize]uint16 - - // sLimit is when to stop looking for offset/length copies. The inputMargin - // lets us use a fast path for emitLiteral in the main loop, while we are - // looking for copies. - sLimit := len(src) - inputMargin - - // nextEmit is where in src the next emitLiteral should start from. - nextEmit := 0 - - // The encoded form must start with a literal, as there are no previous - // bytes to copy, so we start looking for hash matches at s == 1. - s := 1 - nextHash := hash(load32(src, s), shift) - - for { - // Copied from the C++ snappy implementation: - // - // Heuristic match skipping: If 32 bytes are scanned with no matches - // found, start looking only at every other byte. If 32 more bytes are - // scanned (or skipped), look at every third byte, etc.. When a match - // is found, immediately go back to looking at every byte. This is a - // small loss (~5% performance, ~0.1% density) for compressible data - // due to more bookkeeping, but for non-compressible data (such as - // JPEG) it's a huge win since the compressor quickly "realizes" the - // data is incompressible and doesn't bother looking for matches - // everywhere. - // - // The "skip" variable keeps track of how many bytes there are since - // the last match; dividing it by 32 (ie. right-shifting by five) gives - // the number of bytes to move ahead for each iteration. - skip := 32 - - nextS := s - candidate := 0 - for { - s = nextS - bytesBetweenHashLookups := skip >> 5 - nextS = s + bytesBetweenHashLookups - skip += bytesBetweenHashLookups - if nextS > sLimit { - goto emitRemainder - } - candidate = int(table[nextHash&tableMask]) - table[nextHash&tableMask] = uint16(s) - nextHash = hash(load32(src, nextS), shift) - if load32(src, s) == load32(src, candidate) { - break - } - } - - // A 4-byte match has been found. We'll later see if more than 4 bytes - // match. But, prior to the match, src[nextEmit:s] are unmatched. Emit - // them as literal bytes. - d += emitLiteral(dst[d:], src[nextEmit:s]) - - // Call emitCopy, and then see if another emitCopy could be our next - // move. Repeat until we find no match for the input immediately after - // what was consumed by the last emitCopy call. - // - // If we exit this loop normally then we need to call emitLiteral next, - // though we don't yet know how big the literal will be. We handle that - // by proceeding to the next iteration of the main loop. We also can - // exit this loop via goto if we get close to exhausting the input. - for { - // Invariant: we have a 4-byte match at s, and no need to emit any - // literal bytes prior to s. - base := s - - // Extend the 4-byte match as long as possible. - // - // This is an inlined version of: - // s = extendMatch(src, candidate+4, s+4) - s += 4 - for i := candidate + 4; s < len(src) && src[i] == src[s]; i, s = i+1, s+1 { - } - - d += emitCopy(dst[d:], base-candidate, s-base) - nextEmit = s - if s >= sLimit { - goto emitRemainder - } - - // We could immediately start working at s now, but to improve - // compression we first update the hash table at s-1 and at s. If - // another emitCopy is not our next move, also calculate nextHash - // at s+1. At least on GOARCH=amd64, these three hash calculations - // are faster as one load64 call (with some shifts) instead of - // three load32 calls. - x := load64(src, s-1) - prevHash := hash(uint32(x>>0), shift) - table[prevHash&tableMask] = uint16(s - 1) - currHash := hash(uint32(x>>8), shift) - candidate = int(table[currHash&tableMask]) - table[currHash&tableMask] = uint16(s) - if uint32(x>>8) != load32(src, candidate) { - nextHash = hash(uint32(x>>16), shift) - s++ - break - } - } - } - -emitRemainder: - if nextEmit < len(src) { - d += emitLiteral(dst[d:], src[nextEmit:]) - } - return d -} diff --git a/vendor/github.com/golang/snappy/golden_test.go b/vendor/github.com/golang/snappy/golden_test.go deleted file mode 100644 index e4496f9..0000000 --- a/vendor/github.com/golang/snappy/golden_test.go +++ /dev/null @@ -1,1965 +0,0 @@ -// Copyright 2016 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package snappy - -// extendMatchGoldenTestCases is the i and j arguments, and the returned value, -// for every extendMatch call issued when encoding the -// testdata/Mark.Twain-Tom.Sawyer.txt file. It is used to benchmark the -// extendMatch implementation. -// -// It was generated manually by adding some print statements to the (pure Go) -// extendMatch implementation: -// -// func extendMatch(src []byte, i, j int) int { -// i0, j0 := i, j -// for ; j < len(src) && src[i] == src[j]; i, j = i+1, j+1 { -// } -// println("{", i0, ",", j0, ",", j, "},") -// return j -// } -// -// and running "go test -test.run=EncodeGoldenInput -tags=noasm". -var extendMatchGoldenTestCases = []struct { - i, j, want int -}{ - {11, 61, 62}, - {80, 81, 82}, - {86, 87, 101}, - {85, 133, 149}, - {152, 153, 162}, - {133, 168, 193}, - {168, 207, 225}, - {81, 255, 275}, - {278, 279, 283}, - {306, 417, 417}, - {373, 428, 430}, - {389, 444, 447}, - {474, 510, 512}, - {465, 533, 533}, - {47, 547, 547}, - {307, 551, 554}, - {420, 582, 587}, - {309, 604, 604}, - {604, 625, 625}, - {538, 629, 629}, - {328, 640, 640}, - {573, 645, 645}, - {319, 657, 657}, - {30, 664, 664}, - {45, 679, 680}, - {621, 684, 684}, - {376, 700, 700}, - {33, 707, 708}, - {601, 733, 733}, - {334, 744, 745}, - {625, 758, 759}, - {382, 763, 763}, - {550, 769, 771}, - {533, 789, 789}, - {804, 813, 813}, - {342, 841, 842}, - {742, 847, 847}, - {74, 852, 852}, - {810, 864, 864}, - {758, 868, 869}, - {714, 883, 883}, - {582, 889, 891}, - {61, 934, 935}, - {894, 942, 942}, - {939, 949, 949}, - {785, 956, 957}, - {886, 978, 978}, - {792, 998, 998}, - {998, 1005, 1005}, - {572, 1032, 1032}, - {698, 1051, 1053}, - {599, 1067, 1069}, - {1056, 1079, 1079}, - {942, 1089, 1090}, - {831, 1094, 1096}, - {1088, 1100, 1103}, - {732, 1113, 1114}, - {1037, 1118, 1118}, - {872, 1128, 1130}, - {1079, 1140, 1142}, - {332, 1162, 1162}, - {207, 1168, 1186}, - {1189, 1190, 1225}, - {105, 1229, 1230}, - {79, 1256, 1257}, - {1190, 1261, 1283}, - {255, 1306, 1306}, - {1319, 1339, 1358}, - {364, 1370, 1370}, - {955, 1378, 1380}, - {122, 1403, 1403}, - {1325, 1407, 1419}, - {664, 1423, 1424}, - {941, 1461, 1463}, - {867, 1477, 1478}, - {757, 1488, 1489}, - {1140, 1499, 1499}, - {31, 1506, 1506}, - {1487, 1510, 1512}, - {1089, 1520, 1521}, - {1467, 1525, 1529}, - {1394, 1537, 1537}, - {1499, 1541, 1541}, - {367, 1558, 1558}, - {1475, 1564, 1564}, - {1525, 1568, 1571}, - {1541, 1582, 1583}, - {864, 1587, 1588}, - {704, 1597, 1597}, - {336, 1602, 1602}, - {1383, 1613, 1613}, - {1498, 1617, 1618}, - {1051, 1623, 1625}, - {401, 1643, 1645}, - {1072, 1654, 1655}, - {1067, 1667, 1669}, - {699, 1673, 1674}, - {1587, 1683, 1684}, - {920, 1696, 1696}, - {1505, 1710, 1710}, - {1550, 1723, 1723}, - {996, 1727, 1727}, - {833, 1733, 1734}, - {1638, 1739, 1740}, - {1654, 1744, 1744}, - {753, 1761, 1761}, - {1548, 1773, 1773}, - {1568, 1777, 1780}, - {1683, 1793, 1794}, - {948, 1801, 1801}, - {1666, 1805, 1808}, - {1502, 1814, 1814}, - {1696, 1822, 1822}, - {502, 1836, 1837}, - {917, 1843, 1843}, - {1733, 1854, 1855}, - {970, 1859, 1859}, - {310, 1863, 1863}, - {657, 1872, 1872}, - {1005, 1876, 1876}, - {1662, 1880, 1880}, - {904, 1892, 1892}, - {1427, 1910, 1910}, - {1772, 1929, 1930}, - {1822, 1937, 1940}, - {1858, 1949, 1950}, - {1602, 1956, 1956}, - {1150, 1962, 1962}, - {1504, 1966, 1967}, - {51, 1971, 1971}, - {1605, 1979, 1979}, - {1458, 1983, 1988}, - {1536, 2001, 2006}, - {1373, 2014, 2018}, - {1494, 2025, 2025}, - {1667, 2029, 2031}, - {1592, 2035, 2035}, - {330, 2045, 2045}, - {1376, 2053, 2053}, - {1991, 2058, 2059}, - {1635, 2065, 2065}, - {1992, 2073, 2074}, - {2014, 2080, 2081}, - {1546, 2085, 2087}, - {59, 2099, 2099}, - {1996, 2106, 2106}, - {1836, 2110, 2110}, - {2068, 2114, 2114}, - {1338, 2122, 2122}, - {1562, 2128, 2130}, - {1934, 2134, 2134}, - {2114, 2141, 2142}, - {977, 2149, 2150}, - {956, 2154, 2155}, - {1407, 2162, 2162}, - {1773, 2166, 2166}, - {883, 2171, 2171}, - {623, 2175, 2178}, - {1520, 2191, 2192}, - {1162, 2200, 2200}, - {912, 2204, 2204}, - {733, 2208, 2208}, - {1777, 2212, 2215}, - {1532, 2219, 2219}, - {718, 2223, 2225}, - {2069, 2229, 2229}, - {2207, 2245, 2246}, - {1139, 2264, 2264}, - {677, 2274, 2274}, - {2099, 2279, 2279}, - {1863, 2283, 2283}, - {1966, 2305, 2306}, - {2279, 2313, 2313}, - {1628, 2319, 2319}, - {755, 2329, 2329}, - {1461, 2334, 2334}, - {2117, 2340, 2340}, - {2313, 2349, 2349}, - {1859, 2353, 2353}, - {1048, 2362, 2362}, - {895, 2366, 2366}, - {2278, 2373, 2373}, - {1884, 2377, 2377}, - {1402, 2387, 2392}, - {700, 2398, 2398}, - {1971, 2402, 2402}, - {2009, 2419, 2419}, - {1441, 2426, 2428}, - {2208, 2432, 2432}, - {2038, 2436, 2436}, - {932, 2443, 2443}, - {1759, 2447, 2448}, - {744, 2452, 2452}, - {1875, 2458, 2458}, - {2405, 2468, 2468}, - {1596, 2472, 2473}, - {1953, 2480, 2482}, - {736, 2487, 2487}, - {1913, 2493, 2493}, - {774, 2497, 2497}, - {1484, 2506, 2508}, - {2432, 2512, 2512}, - {752, 2519, 2519}, - {2497, 2523, 2523}, - {2409, 2528, 2529}, - {2122, 2533, 2533}, - {2396, 2537, 2538}, - {2410, 2547, 2548}, - {1093, 2555, 2560}, - {551, 2564, 2565}, - {2268, 2569, 2569}, - {1362, 2580, 2580}, - {1916, 2584, 2585}, - {994, 2589, 2590}, - {1979, 2596, 2596}, - {1041, 2602, 2602}, - {2104, 2614, 2616}, - {2609, 2621, 2628}, - {2329, 2638, 2638}, - {2211, 2657, 2658}, - {2638, 2662, 2667}, - {2578, 2676, 2679}, - {2153, 2685, 2686}, - {2608, 2696, 2697}, - {598, 2712, 2712}, - {2620, 2719, 2720}, - {1888, 2724, 2728}, - {2709, 2732, 2732}, - {1365, 2739, 2739}, - {784, 2747, 2748}, - {424, 2753, 2753}, - {2204, 2759, 2759}, - {812, 2768, 2769}, - {2455, 2773, 2773}, - {1722, 2781, 2781}, - {1917, 2792, 2792}, - {2705, 2799, 2799}, - {2685, 2806, 2807}, - {2742, 2811, 2811}, - {1370, 2818, 2818}, - {2641, 2830, 2830}, - {2512, 2837, 2837}, - {2457, 2841, 2841}, - {2756, 2845, 2845}, - {2719, 2855, 2855}, - {1423, 2859, 2859}, - {2849, 2863, 2865}, - {1474, 2871, 2871}, - {1161, 2875, 2876}, - {2282, 2880, 2881}, - {2746, 2888, 2888}, - {1783, 2893, 2893}, - {2401, 2899, 2900}, - {2632, 2920, 2923}, - {2422, 2928, 2930}, - {2715, 2939, 2939}, - {2162, 2943, 2943}, - {2859, 2947, 2947}, - {1910, 2951, 2951}, - {1431, 2955, 2956}, - {1439, 2964, 2964}, - {2501, 2968, 2969}, - {2029, 2973, 2976}, - {689, 2983, 2984}, - {1658, 2988, 2988}, - {1031, 2996, 2996}, - {2149, 3001, 3002}, - {25, 3009, 3013}, - {2964, 3023, 3023}, - {953, 3027, 3028}, - {2359, 3036, 3036}, - {3023, 3049, 3049}, - {2880, 3055, 3056}, - {2973, 3076, 3077}, - {2874, 3090, 3090}, - {2871, 3094, 3094}, - {2532, 3100, 3100}, - {2938, 3107, 3108}, - {350, 3115, 3115}, - {2196, 3119, 3121}, - {1133, 3127, 3129}, - {1797, 3134, 3150}, - {3032, 3158, 3158}, - {3016, 3172, 3172}, - {2533, 3179, 3179}, - {3055, 3187, 3188}, - {1384, 3192, 3193}, - {2799, 3199, 3199}, - {2126, 3203, 3207}, - {2334, 3215, 3215}, - {2105, 3220, 3221}, - {3199, 3229, 3229}, - {2891, 3233, 3233}, - {855, 3240, 3240}, - {1852, 3253, 3256}, - {2140, 3263, 3263}, - {1682, 3268, 3270}, - {3243, 3274, 3274}, - {924, 3279, 3279}, - {2212, 3283, 3283}, - {2596, 3287, 3287}, - {2999, 3291, 3291}, - {2353, 3295, 3295}, - {2480, 3302, 3304}, - {1959, 3308, 3311}, - {3000, 3318, 3318}, - {845, 3330, 3330}, - {2283, 3334, 3334}, - {2519, 3342, 3342}, - {3325, 3346, 3348}, - {2397, 3353, 3354}, - {2763, 3358, 3358}, - {3198, 3363, 3364}, - {3211, 3368, 3372}, - {2950, 3376, 3377}, - {3245, 3388, 3391}, - {2264, 3398, 3398}, - {795, 3403, 3403}, - {3287, 3407, 3407}, - {3358, 3411, 3411}, - {3317, 3415, 3415}, - {3232, 3431, 3431}, - {2128, 3435, 3437}, - {3236, 3441, 3441}, - {3398, 3445, 3446}, - {2814, 3450, 3450}, - {3394, 3466, 3466}, - {2425, 3470, 3470}, - {3330, 3476, 3476}, - {1612, 3480, 3480}, - {1004, 3485, 3486}, - {2732, 3490, 3490}, - {1117, 3494, 3495}, - {629, 3501, 3501}, - {3087, 3514, 3514}, - {684, 3518, 3518}, - {3489, 3522, 3524}, - {1760, 3529, 3529}, - {617, 3537, 3537}, - {3431, 3541, 3541}, - {997, 3547, 3547}, - {882, 3552, 3553}, - {2419, 3558, 3558}, - {610, 3562, 3563}, - {1903, 3567, 3569}, - {3005, 3575, 3575}, - {3076, 3585, 3586}, - {3541, 3590, 3590}, - {3490, 3594, 3594}, - {1899, 3599, 3599}, - {3545, 3606, 3606}, - {3290, 3614, 3615}, - {2056, 3619, 3620}, - {3556, 3625, 3625}, - {3294, 3632, 3633}, - {637, 3643, 3644}, - {3609, 3648, 3650}, - {3175, 3658, 3658}, - {3498, 3665, 3665}, - {1597, 3669, 3669}, - {1983, 3673, 3673}, - {3215, 3682, 3682}, - {3544, 3689, 3689}, - {3694, 3698, 3698}, - {3228, 3715, 3716}, - {2594, 3720, 3722}, - {3573, 3726, 3726}, - {2479, 3732, 3735}, - {3191, 3741, 3742}, - {1113, 3746, 3747}, - {2844, 3751, 3751}, - {3445, 3756, 3757}, - {3755, 3766, 3766}, - {3421, 3775, 3780}, - {3593, 3784, 3786}, - {3263, 3796, 3796}, - {3469, 3806, 3806}, - {2602, 3815, 3815}, - {723, 3819, 3821}, - {1608, 3826, 3826}, - {3334, 3830, 3830}, - {2198, 3835, 3835}, - {2635, 3840, 3840}, - {3702, 3852, 3853}, - {3406, 3858, 3859}, - {3681, 3867, 3870}, - {3407, 3880, 3880}, - {340, 3889, 3889}, - {3772, 3893, 3893}, - {593, 3897, 3897}, - {2563, 3914, 3916}, - {2981, 3929, 3929}, - {1835, 3933, 3934}, - {3906, 3951, 3951}, - {1459, 3958, 3958}, - {3889, 3974, 3974}, - {2188, 3982, 3982}, - {3220, 3986, 3987}, - {3585, 3991, 3993}, - {3712, 3997, 4001}, - {2805, 4007, 4007}, - {1879, 4012, 4013}, - {3618, 4018, 4018}, - {1145, 4031, 4032}, - {3901, 4037, 4037}, - {2772, 4046, 4047}, - {2802, 4053, 4054}, - {3299, 4058, 4058}, - {3725, 4066, 4066}, - {2271, 4070, 4070}, - {385, 4075, 4076}, - {3624, 4089, 4090}, - {3745, 4096, 4098}, - {1563, 4102, 4102}, - {4045, 4106, 4111}, - {3696, 4115, 4119}, - {3376, 4125, 4126}, - {1880, 4130, 4130}, - {2048, 4140, 4141}, - {2724, 4149, 4149}, - {1767, 4156, 4156}, - {2601, 4164, 4164}, - {2757, 4168, 4168}, - {3974, 4172, 4172}, - {3914, 4178, 4178}, - {516, 4185, 4185}, - {1032, 4189, 4190}, - {3462, 4197, 4198}, - {3805, 4202, 4203}, - {3910, 4207, 4212}, - {3075, 4221, 4221}, - {3756, 4225, 4226}, - {1872, 4236, 4237}, - {3844, 4241, 4241}, - {3991, 4245, 4249}, - {2203, 4258, 4258}, - {3903, 4267, 4268}, - {705, 4272, 4272}, - {1896, 4276, 4276}, - {1955, 4285, 4288}, - {3746, 4302, 4303}, - {2672, 4311, 4311}, - {3969, 4317, 4317}, - {3883, 4322, 4322}, - {1920, 4339, 4340}, - {3527, 4344, 4346}, - {1160, 4358, 4358}, - {3648, 4364, 4366}, - {2711, 4387, 4387}, - {3619, 4391, 4392}, - {1944, 4396, 4396}, - {4369, 4400, 4400}, - {2736, 4404, 4407}, - {2546, 4411, 4412}, - {4390, 4422, 4422}, - {3610, 4426, 4427}, - {4058, 4431, 4431}, - {4374, 4435, 4435}, - {3463, 4445, 4446}, - {1813, 4452, 4452}, - {3669, 4456, 4456}, - {3830, 4460, 4460}, - {421, 4464, 4465}, - {1719, 4471, 4471}, - {3880, 4475, 4475}, - {1834, 4485, 4487}, - {3590, 4491, 4491}, - {442, 4496, 4497}, - {4435, 4501, 4501}, - {3814, 4509, 4509}, - {987, 4513, 4513}, - {4494, 4518, 4521}, - {3218, 4526, 4529}, - {4221, 4537, 4537}, - {2778, 4543, 4545}, - {4422, 4552, 4552}, - {4031, 4558, 4559}, - {4178, 4563, 4563}, - {3726, 4567, 4574}, - {4027, 4578, 4578}, - {4339, 4585, 4587}, - {3796, 4592, 4595}, - {543, 4600, 4613}, - {2855, 4620, 4621}, - {2795, 4627, 4627}, - {3440, 4631, 4632}, - {4279, 4636, 4639}, - {4245, 4643, 4645}, - {4516, 4649, 4650}, - {3133, 4654, 4654}, - {4042, 4658, 4659}, - {3422, 4663, 4663}, - {4046, 4667, 4668}, - {4267, 4672, 4672}, - {4004, 4676, 4677}, - {2490, 4682, 4682}, - {2451, 4697, 4697}, - {3027, 4705, 4705}, - {4028, 4717, 4717}, - {4460, 4721, 4721}, - {2471, 4725, 4727}, - {3090, 4735, 4735}, - {3192, 4739, 4740}, - {3835, 4760, 4760}, - {4540, 4764, 4764}, - {4007, 4772, 4774}, - {619, 4784, 4784}, - {3561, 4789, 4791}, - {3367, 4805, 4805}, - {4490, 4810, 4811}, - {2402, 4815, 4815}, - {3352, 4819, 4822}, - {2773, 4828, 4828}, - {4552, 4832, 4832}, - {2522, 4840, 4841}, - {316, 4847, 4852}, - {4715, 4858, 4858}, - {2959, 4862, 4862}, - {4858, 4868, 4869}, - {2134, 4873, 4873}, - {578, 4878, 4878}, - {4189, 4889, 4890}, - {2229, 4894, 4894}, - {4501, 4898, 4898}, - {2297, 4903, 4903}, - {2933, 4909, 4909}, - {3008, 4913, 4913}, - {3153, 4917, 4917}, - {4819, 4921, 4921}, - {4921, 4932, 4933}, - {4920, 4944, 4945}, - {4814, 4954, 4955}, - {576, 4966, 4966}, - {1854, 4970, 4971}, - {1374, 4975, 4976}, - {3307, 4980, 4980}, - {974, 4984, 4988}, - {4721, 4992, 4992}, - {4898, 4996, 4996}, - {4475, 5006, 5006}, - {3819, 5012, 5012}, - {1948, 5019, 5021}, - {4954, 5027, 5029}, - {3740, 5038, 5040}, - {4763, 5044, 5045}, - {1936, 5051, 5051}, - {4844, 5055, 5060}, - {4215, 5069, 5072}, - {1146, 5076, 5076}, - {3845, 5082, 5082}, - {4865, 5090, 5090}, - {4624, 5094, 5094}, - {4815, 5098, 5098}, - {5006, 5105, 5105}, - {4980, 5109, 5109}, - {4795, 5113, 5115}, - {5043, 5119, 5121}, - {4782, 5129, 5129}, - {3826, 5139, 5139}, - {3876, 5156, 5156}, - {3111, 5167, 5171}, - {1470, 5177, 5177}, - {4431, 5181, 5181}, - {546, 5189, 5189}, - {4225, 5193, 5193}, - {1672, 5199, 5201}, - {4207, 5205, 5209}, - {4220, 5216, 5217}, - {4658, 5224, 5225}, - {3295, 5235, 5235}, - {2436, 5239, 5239}, - {2349, 5246, 5246}, - {2175, 5250, 5250}, - {5180, 5257, 5258}, - {3161, 5263, 5263}, - {5105, 5272, 5272}, - {3552, 5282, 5282}, - {4944, 5299, 5300}, - {4130, 5312, 5313}, - {902, 5323, 5323}, - {913, 5327, 5327}, - {2987, 5333, 5334}, - {5150, 5344, 5344}, - {5249, 5348, 5348}, - {1965, 5358, 5359}, - {5330, 5364, 5364}, - {2012, 5373, 5377}, - {712, 5384, 5386}, - {5235, 5390, 5390}, - {5044, 5398, 5399}, - {564, 5406, 5406}, - {39, 5410, 5410}, - {4642, 5422, 5425}, - {4421, 5437, 5438}, - {2347, 5449, 5449}, - {5333, 5453, 5454}, - {4136, 5458, 5459}, - {3793, 5468, 5468}, - {2243, 5480, 5480}, - {4889, 5492, 5493}, - {4295, 5504, 5504}, - {2785, 5511, 5511}, - {2377, 5518, 5518}, - {3662, 5525, 5525}, - {5097, 5529, 5530}, - {4781, 5537, 5538}, - {4697, 5547, 5548}, - {436, 5552, 5553}, - {5542, 5558, 5558}, - {3692, 5562, 5562}, - {2696, 5568, 5569}, - {4620, 5578, 5578}, - {2898, 5590, 5590}, - {5557, 5596, 5618}, - {2797, 5623, 5625}, - {2792, 5629, 5629}, - {5243, 5633, 5633}, - {5348, 5637, 5637}, - {5547, 5643, 5643}, - {4296, 5654, 5655}, - {5568, 5662, 5662}, - {3001, 5670, 5671}, - {3794, 5679, 5679}, - {4006, 5685, 5686}, - {4969, 5690, 5692}, - {687, 5704, 5704}, - {4563, 5708, 5708}, - {1723, 5738, 5738}, - {649, 5742, 5742}, - {5163, 5748, 5755}, - {3907, 5759, 5759}, - {3074, 5764, 5764}, - {5326, 5771, 5771}, - {2951, 5776, 5776}, - {5181, 5780, 5780}, - {2614, 5785, 5788}, - {4709, 5794, 5794}, - {2784, 5799, 5799}, - {5518, 5803, 5803}, - {4155, 5812, 5815}, - {921, 5819, 5819}, - {5224, 5823, 5824}, - {2853, 5830, 5836}, - {5776, 5840, 5840}, - {2955, 5844, 5845}, - {5745, 5853, 5853}, - {3291, 5857, 5857}, - {2988, 5861, 5861}, - {2647, 5865, 5865}, - {5398, 5869, 5870}, - {1085, 5874, 5875}, - {4906, 5881, 5881}, - {802, 5886, 5886}, - {5119, 5890, 5893}, - {5802, 5899, 5900}, - {3415, 5904, 5904}, - {5629, 5908, 5908}, - {3714, 5912, 5914}, - {5558, 5921, 5921}, - {2710, 5927, 5928}, - {1094, 5932, 5934}, - {2653, 5940, 5941}, - {4735, 5954, 5954}, - {5861, 5958, 5958}, - {1040, 5971, 5971}, - {5514, 5977, 5977}, - {5048, 5981, 5982}, - {5953, 5992, 5993}, - {3751, 5997, 5997}, - {4991, 6001, 6002}, - {5885, 6006, 6007}, - {5529, 6011, 6012}, - {4974, 6019, 6020}, - {5857, 6024, 6024}, - {3483, 6032, 6032}, - {3594, 6036, 6036}, - {1997, 6040, 6040}, - {5997, 6044, 6047}, - {5197, 6051, 6051}, - {1764, 6055, 6055}, - {6050, 6059, 6059}, - {5239, 6063, 6063}, - {5049, 6067, 6067}, - {5957, 6073, 6074}, - {1022, 6078, 6078}, - {3414, 6083, 6084}, - {3809, 6090, 6090}, - {4562, 6095, 6096}, - {5878, 6104, 6104}, - {594, 6108, 6109}, - {3353, 6115, 6116}, - {4992, 6120, 6121}, - {2424, 6125, 6125}, - {4484, 6130, 6130}, - {3900, 6134, 6135}, - {5793, 6139, 6141}, - {3562, 6145, 6145}, - {1438, 6152, 6153}, - {6058, 6157, 6158}, - {4411, 6162, 6163}, - {4590, 6167, 6171}, - {4748, 6175, 6175}, - {5517, 6183, 6184}, - {6095, 6191, 6192}, - {1471, 6203, 6203}, - {2643, 6209, 6210}, - {450, 6220, 6220}, - {5266, 6226, 6226}, - {2576, 6233, 6233}, - {2607, 6239, 6240}, - {5164, 6244, 6251}, - {6054, 6255, 6255}, - {1789, 6260, 6261}, - {5250, 6265, 6265}, - {6062, 6273, 6278}, - {5990, 6282, 6282}, - {3283, 6286, 6286}, - {5436, 6290, 6290}, - {6059, 6294, 6294}, - {5668, 6298, 6300}, - {3072, 6324, 6329}, - {3132, 6338, 6339}, - {3246, 6343, 6344}, - {28, 6348, 6349}, - {1503, 6353, 6355}, - {6067, 6359, 6359}, - {3384, 6364, 6364}, - {545, 6375, 6376}, - {5803, 6380, 6380}, - {5522, 6384, 6385}, - {5908, 6389, 6389}, - {2796, 6393, 6396}, - {4831, 6403, 6404}, - {6388, 6412, 6412}, - {6005, 6417, 6420}, - {4450, 6430, 6430}, - {4050, 6435, 6435}, - {5372, 6441, 6441}, - {4378, 6447, 6447}, - {6199, 6452, 6452}, - {3026, 6456, 6456}, - {2642, 6460, 6462}, - {6392, 6470, 6470}, - {6459, 6474, 6474}, - {2829, 6487, 6488}, - {2942, 6499, 6504}, - {5069, 6508, 6511}, - {5341, 6515, 6516}, - {5853, 6521, 6525}, - {6104, 6531, 6531}, - {5759, 6535, 6538}, - {4672, 6542, 6543}, - {2443, 6550, 6550}, - {5109, 6554, 6554}, - {6494, 6558, 6560}, - {6006, 6570, 6572}, - {6424, 6576, 6580}, - {4693, 6591, 6592}, - {6439, 6596, 6597}, - {3179, 6601, 6601}, - {5299, 6606, 6607}, - {4148, 6612, 6613}, - {3774, 6617, 6617}, - {3537, 6623, 6624}, - {4975, 6628, 6629}, - {3848, 6636, 6636}, - {856, 6640, 6640}, - {5724, 6645, 6645}, - {6632, 6651, 6651}, - {4630, 6656, 6658}, - {1440, 6662, 6662}, - {4281, 6666, 6667}, - {4302, 6671, 6672}, - {2589, 6676, 6677}, - {5647, 6681, 6687}, - {6082, 6691, 6693}, - {6144, 6698, 6698}, - {6103, 6709, 6710}, - {3710, 6714, 6714}, - {4253, 6718, 6721}, - {2467, 6730, 6730}, - {4778, 6734, 6734}, - {6528, 6738, 6738}, - {4358, 6747, 6747}, - {5889, 6753, 6753}, - {5193, 6757, 6757}, - {5797, 6761, 6761}, - {3858, 6765, 6766}, - {5951, 6776, 6776}, - {6487, 6781, 6782}, - {3282, 6786, 6787}, - {4667, 6797, 6799}, - {1927, 6803, 6806}, - {6583, 6810, 6810}, - {4937, 6814, 6814}, - {6099, 6824, 6824}, - {4415, 6835, 6836}, - {6332, 6840, 6841}, - {5160, 6850, 6850}, - {4764, 6854, 6854}, - {6814, 6858, 6859}, - {3018, 6864, 6864}, - {6293, 6868, 6869}, - {6359, 6877, 6877}, - {3047, 6884, 6886}, - {5262, 6890, 6891}, - {5471, 6900, 6900}, - {3268, 6910, 6912}, - {1047, 6916, 6916}, - {5904, 6923, 6923}, - {5798, 6933, 6938}, - {4149, 6942, 6942}, - {1821, 6946, 6946}, - {3599, 6952, 6952}, - {6470, 6957, 6957}, - {5562, 6961, 6961}, - {6268, 6965, 6967}, - {6389, 6971, 6971}, - {6596, 6975, 6976}, - {6553, 6980, 6981}, - {6576, 6985, 6989}, - {1375, 6993, 6993}, - {652, 6998, 6998}, - {4876, 7002, 7003}, - {5768, 7011, 7013}, - {3973, 7017, 7017}, - {6802, 7025, 7025}, - {6955, 7034, 7036}, - {6974, 7040, 7040}, - {5944, 7044, 7044}, - {6992, 7048, 7054}, - {6872, 7059, 7059}, - {2943, 7063, 7063}, - {6923, 7067, 7067}, - {5094, 7071, 7071}, - {4873, 7075, 7075}, - {5819, 7079, 7079}, - {5945, 7085, 7085}, - {1540, 7090, 7091}, - {2090, 7095, 7095}, - {5024, 7104, 7105}, - {6900, 7109, 7109}, - {6024, 7113, 7114}, - {6000, 7118, 7120}, - {2187, 7124, 7125}, - {6760, 7129, 7130}, - {5898, 7134, 7136}, - {7032, 7144, 7144}, - {4271, 7148, 7148}, - {3706, 7152, 7152}, - {6970, 7156, 7157}, - {7088, 7161, 7163}, - {2718, 7168, 7169}, - {5674, 7175, 7175}, - {4631, 7182, 7182}, - {7070, 7188, 7189}, - {6220, 7196, 7196}, - {3458, 7201, 7202}, - {2041, 7211, 7212}, - {1454, 7216, 7216}, - {5199, 7225, 7227}, - {3529, 7234, 7234}, - {6890, 7238, 7238}, - {3815, 7242, 7243}, - {5490, 7250, 7253}, - {6554, 7257, 7263}, - {5890, 7267, 7269}, - {6877, 7273, 7273}, - {4877, 7277, 7277}, - {2502, 7285, 7285}, - {1483, 7289, 7295}, - {7210, 7304, 7308}, - {6845, 7313, 7316}, - {7219, 7320, 7320}, - {7001, 7325, 7329}, - {6853, 7333, 7334}, - {6120, 7338, 7338}, - {6606, 7342, 7343}, - {7020, 7348, 7350}, - {3509, 7354, 7354}, - {7133, 7359, 7363}, - {3434, 7371, 7374}, - {2787, 7384, 7384}, - {7044, 7388, 7388}, - {6960, 7394, 7395}, - {6676, 7399, 7400}, - {7161, 7404, 7404}, - {7285, 7417, 7418}, - {4558, 7425, 7426}, - {4828, 7430, 7430}, - {6063, 7436, 7436}, - {3597, 7442, 7442}, - {914, 7446, 7446}, - {7320, 7452, 7454}, - {7267, 7458, 7460}, - {5076, 7464, 7464}, - {7430, 7468, 7469}, - {6273, 7473, 7474}, - {7440, 7478, 7487}, - {7348, 7491, 7494}, - {1021, 7510, 7510}, - {7473, 7515, 7515}, - {2823, 7519, 7519}, - {6264, 7527, 7527}, - {7302, 7531, 7531}, - {7089, 7535, 7535}, - {7342, 7540, 7541}, - {3688, 7547, 7551}, - {3054, 7558, 7560}, - {4177, 7566, 7567}, - {6691, 7574, 7575}, - {7156, 7585, 7586}, - {7147, 7590, 7592}, - {7407, 7598, 7598}, - {7403, 7602, 7603}, - {6868, 7607, 7607}, - {6636, 7611, 7611}, - {4805, 7617, 7617}, - {5779, 7623, 7623}, - {7063, 7627, 7627}, - {5079, 7632, 7632}, - {7377, 7637, 7637}, - {7337, 7641, 7642}, - {6738, 7655, 7655}, - {7338, 7659, 7659}, - {6541, 7669, 7671}, - {595, 7675, 7675}, - {7658, 7679, 7680}, - {7647, 7685, 7686}, - {2477, 7690, 7690}, - {5823, 7694, 7694}, - {4156, 7699, 7699}, - {5931, 7703, 7706}, - {6854, 7712, 7712}, - {4931, 7718, 7718}, - {6979, 7722, 7722}, - {5085, 7727, 7727}, - {6965, 7732, 7732}, - {7201, 7736, 7737}, - {3639, 7741, 7743}, - {7534, 7749, 7749}, - {4292, 7753, 7753}, - {3427, 7759, 7763}, - {7273, 7767, 7767}, - {940, 7778, 7778}, - {4838, 7782, 7785}, - {4216, 7790, 7792}, - {922, 7800, 7801}, - {7256, 7810, 7811}, - {7789, 7815, 7819}, - {7225, 7823, 7825}, - {7531, 7829, 7829}, - {6997, 7833, 7833}, - {7757, 7837, 7838}, - {4129, 7842, 7842}, - {7333, 7848, 7849}, - {6776, 7855, 7855}, - {7527, 7859, 7859}, - {4370, 7863, 7863}, - {4512, 7868, 7868}, - {5679, 7880, 7880}, - {3162, 7884, 7885}, - {3933, 7892, 7894}, - {7804, 7899, 7902}, - {6363, 7906, 7907}, - {7848, 7911, 7912}, - {5584, 7917, 7921}, - {874, 7926, 7926}, - {3342, 7930, 7930}, - {4507, 7935, 7937}, - {3672, 7943, 7944}, - {7911, 7948, 7949}, - {6402, 7956, 7956}, - {7940, 7960, 7960}, - {7113, 7964, 7964}, - {1073, 7968, 7968}, - {7740, 7974, 7974}, - {7601, 7978, 7982}, - {6797, 7987, 7988}, - {3528, 7994, 7995}, - {5483, 7999, 7999}, - {5717, 8011, 8011}, - {5480, 8017, 8017}, - {7770, 8023, 8030}, - {2452, 8034, 8034}, - {5282, 8047, 8047}, - {7967, 8051, 8051}, - {1128, 8058, 8066}, - {6348, 8070, 8070}, - {8055, 8077, 8077}, - {7925, 8081, 8086}, - {6810, 8090, 8090}, - {5051, 8101, 8101}, - {4696, 8109, 8110}, - {5129, 8119, 8119}, - {4449, 8123, 8123}, - {7222, 8127, 8127}, - {4649, 8131, 8134}, - {7994, 8138, 8138}, - {5954, 8148, 8148}, - {475, 8152, 8153}, - {7906, 8157, 8157}, - {7458, 8164, 8166}, - {7632, 8171, 8173}, - {3874, 8177, 8183}, - {4391, 8187, 8187}, - {561, 8191, 8191}, - {2417, 8195, 8195}, - {2357, 8204, 8204}, - {2269, 8216, 8218}, - {3968, 8222, 8222}, - {2200, 8226, 8227}, - {3453, 8247, 8247}, - {2439, 8251, 8252}, - {7175, 8257, 8257}, - {976, 8262, 8264}, - {4953, 8273, 8273}, - {4219, 8278, 8278}, - {6, 8285, 8291}, - {5703, 8295, 8296}, - {5272, 8300, 8300}, - {8037, 8304, 8304}, - {8186, 8314, 8314}, - {8304, 8318, 8318}, - {8051, 8326, 8326}, - {8318, 8330, 8330}, - {2671, 8334, 8335}, - {2662, 8339, 8339}, - {8081, 8349, 8350}, - {3328, 8356, 8356}, - {2879, 8360, 8362}, - {8050, 8370, 8371}, - {8330, 8375, 8376}, - {8375, 8386, 8386}, - {4961, 8390, 8390}, - {1017, 8403, 8405}, - {3533, 8416, 8416}, - {4555, 8422, 8422}, - {6445, 8426, 8426}, - {8169, 8432, 8432}, - {990, 8436, 8436}, - {4102, 8440, 8440}, - {7398, 8444, 8446}, - {3480, 8450, 8450}, - {6324, 8462, 8462}, - {7948, 8466, 8467}, - {5950, 8471, 8471}, - {5189, 8476, 8476}, - {4026, 8490, 8490}, - {8374, 8494, 8495}, - {4682, 8501, 8501}, - {7387, 8506, 8506}, - {8164, 8510, 8515}, - {4079, 8524, 8524}, - {8360, 8529, 8531}, - {7446, 8540, 8543}, - {7971, 8547, 8548}, - {4311, 8552, 8552}, - {5204, 8556, 8557}, - {7968, 8562, 8562}, - {7847, 8571, 8573}, - {8547, 8577, 8577}, - {5320, 8581, 8581}, - {8556, 8585, 8586}, - {8504, 8590, 8590}, - {7669, 8602, 8604}, - {5874, 8608, 8609}, - {5828, 8613, 8613}, - {7998, 8617, 8617}, - {8519, 8625, 8625}, - {7250, 8637, 8637}, - {426, 8641, 8641}, - {8436, 8645, 8645}, - {5986, 8649, 8656}, - {8157, 8660, 8660}, - {7182, 8665, 8665}, - {8421, 8675, 8675}, - {8509, 8681, 8681}, - {5137, 8688, 8689}, - {8625, 8694, 8695}, - {5228, 8701, 8702}, - {6661, 8714, 8714}, - {1010, 8719, 8719}, - {6648, 8723, 8723}, - {3500, 8728, 8728}, - {2442, 8735, 8735}, - {8494, 8740, 8741}, - {8171, 8753, 8755}, - {7242, 8763, 8764}, - {4739, 8768, 8769}, - {7079, 8773, 8773}, - {8386, 8777, 8777}, - {8624, 8781, 8787}, - {661, 8791, 8794}, - {8631, 8801, 8801}, - {7753, 8805, 8805}, - {4783, 8809, 8810}, - {1673, 8814, 8815}, - {6623, 8819, 8819}, - {4404, 8823, 8823}, - {8089, 8827, 8828}, - {8773, 8832, 8832}, - {5394, 8836, 8836}, - {6231, 8841, 8843}, - {1015, 8852, 8853}, - {6873, 8857, 8857}, - {6289, 8865, 8865}, - {8577, 8869, 8869}, - {8114, 8873, 8875}, - {8534, 8883, 8883}, - {3007, 8887, 8888}, - {8827, 8892, 8893}, - {4788, 8897, 8900}, - {5698, 8906, 8907}, - {7690, 8911, 8911}, - {6643, 8919, 8919}, - {7206, 8923, 8924}, - {7866, 8929, 8931}, - {8880, 8942, 8942}, - {8630, 8951, 8952}, - {6027, 8958, 8958}, - {7749, 8966, 8967}, - {4932, 8972, 8973}, - {8892, 8980, 8981}, - {634, 9003, 9003}, - {8109, 9007, 9008}, - {8777, 9012, 9012}, - {3981, 9016, 9017}, - {5723, 9025, 9025}, - {7662, 9034, 9038}, - {8955, 9042, 9042}, - {8070, 9060, 9062}, - {8910, 9066, 9066}, - {5363, 9070, 9071}, - {7699, 9075, 9076}, - {8991, 9081, 9081}, - {6850, 9085, 9085}, - {5811, 9092, 9094}, - {9079, 9098, 9102}, - {6456, 9106, 9106}, - {2259, 9111, 9111}, - {4752, 9116, 9116}, - {9060, 9120, 9123}, - {8090, 9127, 9127}, - {5305, 9131, 9132}, - {8623, 9137, 9137}, - {7417, 9141, 9141}, - {6564, 9148, 9149}, - {9126, 9157, 9158}, - {4285, 9169, 9170}, - {8698, 9174, 9174}, - {8869, 9178, 9178}, - {2572, 9182, 9183}, - {6482, 9188, 9190}, - {9181, 9201, 9201}, - {2968, 9208, 9209}, - {2506, 9213, 9215}, - {9127, 9219, 9219}, - {7910, 9225, 9227}, - {5422, 9235, 9239}, - {8813, 9244, 9246}, - {9178, 9250, 9250}, - {8748, 9255, 9255}, - {7354, 9265, 9265}, - {7767, 9269, 9269}, - {7710, 9281, 9283}, - {8826, 9288, 9290}, - {861, 9295, 9295}, - {4482, 9301, 9301}, - {9264, 9305, 9306}, - {8805, 9310, 9310}, - {4995, 9314, 9314}, - {6730, 9318, 9318}, - {7457, 9328, 9328}, - {2547, 9335, 9336}, - {6298, 9340, 9343}, - {9305, 9353, 9354}, - {9269, 9358, 9358}, - {6338, 9370, 9370}, - {7289, 9376, 9379}, - {5780, 9383, 9383}, - {7607, 9387, 9387}, - {2065, 9392, 9392}, - {7238, 9396, 9396}, - {8856, 9400, 9400}, - {8069, 9412, 9413}, - {611, 9420, 9420}, - {7071, 9424, 9424}, - {3089, 9430, 9431}, - {7117, 9435, 9438}, - {1976, 9445, 9445}, - {6640, 9449, 9449}, - {5488, 9453, 9453}, - {8739, 9457, 9459}, - {5958, 9466, 9466}, - {7985, 9470, 9470}, - {8735, 9475, 9475}, - {5009, 9479, 9479}, - {8073, 9483, 9484}, - {2328, 9490, 9491}, - {9250, 9495, 9495}, - {4043, 9502, 9502}, - {7712, 9506, 9506}, - {9012, 9510, 9510}, - {9028, 9514, 9515}, - {2190, 9521, 9524}, - {9029, 9528, 9528}, - {9519, 9532, 9532}, - {9495, 9536, 9536}, - {8527, 9540, 9540}, - {2137, 9550, 9550}, - {8419, 9557, 9557}, - {9383, 9561, 9562}, - {8970, 9575, 9578}, - {8911, 9582, 9582}, - {7828, 9595, 9596}, - {6180, 9600, 9600}, - {8738, 9604, 9607}, - {7540, 9611, 9612}, - {9599, 9616, 9618}, - {9187, 9623, 9623}, - {9294, 9628, 9629}, - {4536, 9639, 9639}, - {3867, 9643, 9643}, - {6305, 9648, 9648}, - {1617, 9654, 9657}, - {5762, 9666, 9666}, - {8314, 9670, 9670}, - {9666, 9674, 9675}, - {9506, 9679, 9679}, - {9669, 9685, 9686}, - {9683, 9690, 9690}, - {8763, 9697, 9698}, - {7468, 9702, 9702}, - {460, 9707, 9707}, - {3115, 9712, 9712}, - {9424, 9716, 9717}, - {7359, 9721, 9724}, - {7547, 9728, 9729}, - {7151, 9733, 9738}, - {7627, 9742, 9742}, - {2822, 9747, 9747}, - {8247, 9751, 9753}, - {9550, 9758, 9758}, - {7585, 9762, 9763}, - {1002, 9767, 9767}, - {7168, 9772, 9773}, - {6941, 9777, 9780}, - {9728, 9784, 9786}, - {9770, 9792, 9796}, - {6411, 9801, 9802}, - {3689, 9806, 9808}, - {9575, 9814, 9816}, - {7025, 9820, 9821}, - {2776, 9826, 9826}, - {9806, 9830, 9830}, - {9820, 9834, 9835}, - {9800, 9839, 9847}, - {9834, 9851, 9852}, - {9829, 9856, 9862}, - {1400, 9866, 9866}, - {3197, 9870, 9871}, - {9851, 9875, 9876}, - {9742, 9883, 9884}, - {3362, 9888, 9889}, - {9883, 9893, 9893}, - {5711, 9899, 9910}, - {7806, 9915, 9915}, - {9120, 9919, 9919}, - {9715, 9925, 9934}, - {2580, 9938, 9938}, - {4907, 9942, 9944}, - {6239, 9953, 9954}, - {6961, 9963, 9963}, - {5295, 9967, 9968}, - {1915, 9972, 9973}, - {3426, 9983, 9985}, - {9875, 9994, 9995}, - {6942, 9999, 9999}, - {6621, 10005, 10005}, - {7589, 10010, 10012}, - {9286, 10020, 10020}, - {838, 10024, 10024}, - {9980, 10028, 10031}, - {9994, 10035, 10041}, - {2702, 10048, 10051}, - {2621, 10059, 10059}, - {10054, 10065, 10065}, - {8612, 10073, 10074}, - {7033, 10078, 10078}, - {916, 10082, 10082}, - {10035, 10086, 10087}, - {8613, 10097, 10097}, - {9919, 10107, 10108}, - {6133, 10114, 10115}, - {10059, 10119, 10119}, - {10065, 10126, 10127}, - {7732, 10131, 10131}, - {7155, 10135, 10136}, - {6728, 10140, 10140}, - {6162, 10144, 10145}, - {4724, 10150, 10150}, - {1665, 10154, 10154}, - {10126, 10163, 10163}, - {9783, 10168, 10168}, - {1715, 10172, 10173}, - {7152, 10177, 10182}, - {8760, 10187, 10187}, - {7829, 10191, 10191}, - {9679, 10196, 10196}, - {9369, 10201, 10201}, - {2928, 10206, 10208}, - {6951, 10214, 10217}, - {5633, 10221, 10221}, - {7199, 10225, 10225}, - {10118, 10230, 10231}, - {9999, 10235, 10236}, - {10045, 10240, 10249}, - {5565, 10256, 10256}, - {9866, 10261, 10261}, - {10163, 10268, 10268}, - {9869, 10272, 10272}, - {9789, 10276, 10283}, - {10235, 10287, 10288}, - {10214, 10298, 10299}, - {6971, 10303, 10303}, - {3346, 10307, 10307}, - {10185, 10311, 10312}, - {9993, 10318, 10320}, - {2779, 10332, 10334}, - {1726, 10338, 10338}, - {741, 10354, 10360}, - {10230, 10372, 10373}, - {10260, 10384, 10385}, - {10131, 10389, 10398}, - {6946, 10406, 10409}, - {10158, 10413, 10420}, - {10123, 10424, 10424}, - {6157, 10428, 10429}, - {4518, 10434, 10434}, - {9893, 10438, 10438}, - {9865, 10442, 10446}, - {7558, 10454, 10454}, - {10434, 10460, 10460}, - {10064, 10466, 10468}, - {2703, 10472, 10474}, - {9751, 10478, 10479}, - {6714, 10485, 10485}, - {8020, 10490, 10490}, - {10303, 10494, 10494}, - {3521, 10499, 10500}, - {9281, 10513, 10515}, - {6028, 10519, 10523}, - {9387, 10527, 10527}, - {7614, 10531, 10531}, - {3611, 10536, 10536}, - {9162, 10540, 10540}, - {10081, 10546, 10547}, - {10034, 10560, 10562}, - {6726, 10567, 10571}, - {8237, 10575, 10575}, - {10438, 10579, 10583}, - {10140, 10587, 10587}, - {5784, 10592, 10592}, - {9819, 10597, 10600}, - {10567, 10604, 10608}, - {9335, 10613, 10613}, - {8300, 10617, 10617}, - {10575, 10621, 10621}, - {9678, 10625, 10626}, - {9962, 10632, 10633}, - {10535, 10637, 10638}, - {8199, 10642, 10642}, - {10372, 10647, 10648}, - {10637, 10656, 10657}, - {10579, 10667, 10668}, - {10465, 10677, 10680}, - {6702, 10684, 10685}, - {10073, 10691, 10692}, - {4505, 10696, 10697}, - {9042, 10701, 10701}, - {6460, 10705, 10706}, - {10010, 10714, 10716}, - {10656, 10720, 10722}, - {7282, 10727, 10729}, - {2327, 10733, 10733}, - {2491, 10740, 10741}, - {10704, 10748, 10750}, - {6465, 10754, 10754}, - {10647, 10758, 10759}, - {10424, 10763, 10763}, - {10748, 10776, 10776}, - {10546, 10780, 10781}, - {10758, 10785, 10786}, - {10287, 10790, 10797}, - {10785, 10801, 10807}, - {10240, 10811, 10826}, - {9509, 10830, 10830}, - {2579, 10836, 10838}, - {9801, 10843, 10845}, - {7555, 10849, 10850}, - {10776, 10860, 10865}, - {8023, 10869, 10869}, - {10046, 10876, 10884}, - {10253, 10888, 10892}, - {9941, 10897, 10897}, - {7898, 10901, 10905}, - {6725, 10909, 10913}, - {10757, 10921, 10923}, - {10160, 10931, 10931}, - {10916, 10935, 10942}, - {10261, 10946, 10946}, - {10318, 10952, 10954}, - {5911, 10959, 10961}, - {10801, 10965, 10966}, - {10946, 10970, 10977}, - {10592, 10982, 10984}, - {9913, 10988, 10990}, - {8510, 10994, 10996}, - {9419, 11000, 11001}, - {6765, 11006, 11007}, - {10725, 11011, 11011}, - {5537, 11017, 11019}, - {9208, 11024, 11025}, - {5850, 11030, 11030}, - {9610, 11034, 11036}, - {8846, 11041, 11047}, - {9697, 11051, 11051}, - {1622, 11055, 11058}, - {2370, 11062, 11062}, - {8393, 11067, 11067}, - {9756, 11071, 11071}, - {10172, 11076, 11076}, - {27, 11081, 11081}, - {7357, 11087, 11092}, - {8151, 11104, 11106}, - {6115, 11110, 11110}, - {10667, 11114, 11115}, - {11099, 11121, 11123}, - {10705, 11127, 11127}, - {8938, 11131, 11131}, - {11114, 11135, 11136}, - {1390, 11140, 11141}, - {10964, 11146, 11148}, - {11140, 11152, 11155}, - {9813, 11159, 11166}, - {624, 11171, 11172}, - {3118, 11177, 11179}, - {11029, 11184, 11186}, - {10186, 11190, 11190}, - {10306, 11196, 11196}, - {8665, 11201, 11201}, - {7382, 11205, 11205}, - {1100, 11210, 11210}, - {2337, 11216, 11217}, - {1609, 11221, 11223}, - {5763, 11228, 11229}, - {5220, 11233, 11233}, - {11061, 11241, 11241}, - {10617, 11246, 11246}, - {11190, 11250, 11251}, - {10144, 11255, 11256}, - {11232, 11260, 11260}, - {857, 11264, 11265}, - {10994, 11269, 11271}, - {3879, 11280, 11281}, - {11184, 11287, 11289}, - {9611, 11293, 11295}, - {11250, 11299, 11299}, - {4495, 11304, 11304}, - {7574, 11308, 11309}, - {9814, 11315, 11317}, - {1713, 11321, 11324}, - {1905, 11328, 11328}, - {8745, 11335, 11340}, - {8883, 11351, 11351}, - {8119, 11358, 11358}, - {1842, 11363, 11364}, - {11237, 11368, 11368}, - {8814, 11373, 11374}, - {5684, 11378, 11378}, - {11011, 11382, 11382}, - {6520, 11389, 11389}, - {11183, 11393, 11396}, - {1790, 11404, 11404}, - {9536, 11408, 11408}, - {11298, 11418, 11419}, - {3929, 11425, 11425}, - {5588, 11429, 11429}, - {8476, 11436, 11436}, - {4096, 11440, 11442}, - {11084, 11446, 11454}, - {10603, 11458, 11463}, - {7332, 11472, 11474}, - {7611, 11483, 11486}, - {4836, 11490, 11491}, - {10024, 11495, 11495}, - {4917, 11501, 11506}, - {6486, 11510, 11512}, - {11269, 11516, 11518}, - {3603, 11522, 11525}, - {11126, 11535, 11535}, - {11418, 11539, 11541}, - {11408, 11545, 11545}, - {9021, 11549, 11552}, - {6745, 11557, 11557}, - {5118, 11561, 11564}, - {7590, 11568, 11569}, - {4426, 11573, 11578}, - {9790, 11582, 11583}, - {6447, 11587, 11587}, - {10229, 11591, 11594}, - {10457, 11598, 11598}, - {10168, 11604, 11604}, - {10543, 11608, 11608}, - {7404, 11612, 11612}, - {11127, 11616, 11616}, - {3337, 11620, 11620}, - {11501, 11624, 11628}, - {4543, 11633, 11635}, - {8449, 11642, 11642}, - {4943, 11646, 11648}, - {10526, 11652, 11654}, - {11620, 11659, 11659}, - {8927, 11664, 11669}, - {532, 11673, 11673}, - {10513, 11677, 11679}, - {10428, 11683, 11683}, - {10999, 11689, 11690}, - {9469, 11695, 11695}, - {3606, 11699, 11699}, - {9560, 11708, 11709}, - {1564, 11714, 11714}, - {10527, 11718, 11718}, - {3071, 11723, 11726}, - {11590, 11731, 11732}, - {6605, 11737, 11737}, - {11624, 11741, 11745}, - {7822, 11749, 11752}, - {5269, 11757, 11758}, - {1339, 11767, 11767}, - {1363, 11771, 11773}, - {3704, 11777, 11777}, - {10952, 11781, 11783}, - {6764, 11793, 11795}, - {8675, 11800, 11800}, - {9963, 11804, 11804}, - {11573, 11808, 11809}, - {9548, 11813, 11813}, - {11591, 11817, 11818}, - {11446, 11822, 11822}, - {9224, 11828, 11828}, - {3158, 11836, 11836}, - {10830, 11840, 11840}, - {7234, 11846, 11846}, - {11299, 11850, 11850}, - {11544, 11854, 11855}, - {11498, 11859, 11859}, - {10993, 11865, 11868}, - {9720, 11872, 11878}, - {10489, 11882, 11890}, - {11712, 11898, 11904}, - {11516, 11908, 11910}, - {11568, 11914, 11915}, - {10177, 11919, 11924}, - {11363, 11928, 11929}, - {10494, 11933, 11933}, - {9870, 11937, 11938}, - {9427, 11942, 11942}, - {11481, 11949, 11949}, - {6030, 11955, 11957}, - {11718, 11961, 11961}, - {10531, 11965, 11983}, - {5126, 11987, 11987}, - {7515, 11991, 11991}, - {10646, 11996, 11997}, - {2947, 12001, 12001}, - {9582, 12009, 12010}, - {6202, 12017, 12018}, - {11714, 12022, 12022}, - {9235, 12033, 12037}, - {9721, 12041, 12044}, - {11932, 12051, 12052}, - {12040, 12056, 12056}, - {12051, 12060, 12060}, - {11601, 12066, 12066}, - {8426, 12070, 12070}, - {4053, 12077, 12077}, - {4262, 12081, 12081}, - {9761, 12086, 12088}, - {11582, 12092, 12093}, - {10965, 12097, 12098}, - {11803, 12103, 12104}, - {11933, 12108, 12109}, - {10688, 12117, 12117}, - {12107, 12125, 12126}, - {6774, 12130, 12132}, - {6286, 12137, 12137}, - {9543, 12141, 12141}, - {12097, 12145, 12146}, - {10790, 12150, 12150}, - {10125, 12154, 12156}, - {12125, 12164, 12164}, - {12064, 12168, 12172}, - {10811, 12178, 12188}, - {12092, 12192, 12193}, - {10058, 12197, 12198}, - {11611, 12211, 12212}, - {3459, 12216, 12216}, - {10291, 12225, 12228}, - {12191, 12232, 12234}, - {12145, 12238, 12238}, - {12001, 12242, 12250}, - {3840, 12255, 12255}, - {12216, 12259, 12259}, - {674, 12272, 12272}, - {12141, 12276, 12276}, - {10766, 12280, 12280}, - {11545, 12284, 12284}, - {6496, 12290, 12290}, - {11381, 12294, 12295}, - {603, 12302, 12303}, - {12276, 12308, 12308}, - {11850, 12313, 12314}, - {565, 12319, 12319}, - {9351, 12324, 12324}, - {11822, 12328, 12328}, - {2691, 12333, 12334}, - {11840, 12338, 12338}, - {11070, 12343, 12343}, - {9510, 12347, 12347}, - {11024, 12352, 12353}, - {7173, 12359, 12359}, - {517, 12363, 12363}, - {6311, 12367, 12368}, - {11367, 12372, 12373}, - {12008, 12377, 12377}, - {11372, 12382, 12384}, - {11358, 12391, 12392}, - {11382, 12396, 12396}, - {6882, 12400, 12401}, - {11246, 12405, 12405}, - {8359, 12409, 12412}, - {10154, 12418, 12418}, - {12016, 12425, 12426}, - {8972, 12434, 12435}, - {10478, 12439, 12440}, - {12395, 12449, 12449}, - {11612, 12454, 12454}, - {12347, 12458, 12458}, - {10700, 12466, 12467}, - {3637, 12471, 12476}, - {1042, 12480, 12481}, - {6747, 12488, 12488}, - {12396, 12492, 12493}, - {9420, 12497, 12497}, - {11285, 12501, 12510}, - {4470, 12515, 12515}, - {9374, 12519, 12519}, - {11293, 12528, 12528}, - {2058, 12534, 12535}, - {6521, 12539, 12539}, - {12492, 12543, 12543}, - {3043, 12547, 12547}, - {2982, 12551, 12553}, - {11030, 12557, 12563}, - {7636, 12568, 12568}, - {9639, 12572, 12572}, - {12543, 12576, 12576}, - {5989, 12580, 12583}, - {11051, 12587, 12587}, - {1061, 12592, 12594}, - {12313, 12599, 12601}, - {11846, 12605, 12605}, - {12576, 12609, 12609}, - {11040, 12618, 12625}, - {12479, 12629, 12629}, - {6903, 12633, 12633}, - {12322, 12639, 12639}, - {12253, 12643, 12645}, - {5594, 12651, 12651}, - {12522, 12655, 12655}, - {11703, 12659, 12659}, - {1377, 12665, 12665}, - {8022, 12669, 12669}, - {12280, 12674, 12674}, - {9023, 12680, 12681}, - {12328, 12685, 12685}, - {3085, 12689, 12693}, - {4700, 12698, 12698}, - {10224, 12702, 12702}, - {8781, 12706, 12706}, - {1651, 12710, 12710}, - {12458, 12714, 12714}, - {12005, 12718, 12721}, - {11908, 12725, 12726}, - {8202, 12733, 12733}, - {11708, 12739, 12740}, - {12599, 12744, 12745}, - {12284, 12749, 12749}, - {5285, 12756, 12756}, - {12055, 12775, 12777}, - {6919, 12782, 12782}, - {12242, 12786, 12786}, - {12009, 12790, 12790}, - {9628, 12794, 12796}, - {11354, 12801, 12802}, - {10225, 12806, 12807}, - {579, 12813, 12813}, - {8935, 12817, 12822}, - {8753, 12827, 12829}, - {11006, 12835, 12835}, - {858, 12841, 12845}, - {476, 12849, 12849}, - {7667, 12854, 12854}, - {12760, 12860, 12871}, - {11677, 12875, 12877}, - {12714, 12881, 12881}, - {12731, 12885, 12890}, - {7108, 12894, 12896}, - {1165, 12900, 12900}, - {4021, 12906, 12906}, - {10829, 12910, 12911}, - {12331, 12915, 12915}, - {8887, 12919, 12921}, - {11639, 12925, 12925}, - {7964, 12929, 12929}, - {12528, 12937, 12937}, - {8148, 12941, 12941}, - {12770, 12948, 12950}, - {12609, 12954, 12954}, - {12685, 12958, 12958}, - {2803, 12962, 12962}, - {9561, 12966, 12966}, - {6671, 12972, 12973}, - {12056, 12977, 12977}, - {6380, 12981, 12981}, - {12048, 12985, 12985}, - {11961, 12989, 12993}, - {3368, 12997, 12999}, - {6634, 13004, 13004}, - {6775, 13009, 13010}, - {12136, 13014, 13019}, - {10341, 13023, 13023}, - {13002, 13027, 13027}, - {10587, 13031, 13031}, - {10307, 13035, 13035}, - {12736, 13039, 13039}, - {12744, 13043, 13044}, - {6175, 13048, 13048}, - {9702, 13053, 13054}, - {662, 13059, 13061}, - {12718, 13065, 13068}, - {12893, 13072, 13075}, - {8299, 13086, 13091}, - {12604, 13095, 13096}, - {12848, 13100, 13101}, - {12749, 13105, 13105}, - {12526, 13109, 13114}, - {9173, 13122, 13122}, - {12769, 13128, 13128}, - {13038, 13132, 13132}, - {12725, 13136, 13137}, - {12639, 13146, 13146}, - {9711, 13150, 13151}, - {12137, 13155, 13155}, - {13039, 13159, 13159}, - {4681, 13163, 13164}, - {12954, 13168, 13168}, - {13158, 13175, 13176}, - {13105, 13180, 13180}, - {10754, 13184, 13184}, - {13167, 13188, 13188}, - {12658, 13192, 13192}, - {4294, 13199, 13200}, - {11682, 13204, 13205}, - {11695, 13209, 13209}, - {11076, 13214, 13214}, - {12232, 13218, 13218}, - {9399, 13223, 13224}, - {12880, 13228, 13229}, - {13048, 13234, 13234}, - {9701, 13238, 13239}, - {13209, 13243, 13243}, - {3658, 13248, 13248}, - {3698, 13252, 13254}, - {12237, 13260, 13260}, - {8872, 13266, 13266}, - {12957, 13272, 13273}, - {1393, 13281, 13281}, - {2013, 13285, 13288}, - {4244, 13296, 13299}, - {9428, 13303, 13303}, - {12702, 13307, 13307}, - {13078, 13311, 13311}, - {6071, 13315, 13315}, - {3061, 13319, 13319}, - {2051, 13324, 13324}, - {11560, 13328, 13331}, - {6584, 13336, 13336}, - {8482, 13340, 13340}, - {5331, 13344, 13344}, - {4171, 13348, 13348}, - {8501, 13352, 13352}, - {9219, 13356, 13356}, - {9473, 13360, 13363}, - {12881, 13367, 13367}, - {13065, 13371, 13375}, - {2979, 13379, 13384}, - {1518, 13388, 13388}, - {11177, 13392, 13392}, - {9457, 13398, 13398}, - {12293, 13407, 13410}, - {3697, 13414, 13417}, - {10338, 13425, 13425}, - {13367, 13429, 13429}, - {11074, 13433, 13437}, - {4201, 13441, 13443}, - {1812, 13447, 13448}, - {13360, 13452, 13456}, - {13188, 13463, 13463}, - {9732, 13470, 13470}, - {11332, 13477, 13477}, - {9918, 13487, 13487}, - {6337, 13497, 13497}, - {13429, 13501, 13501}, - {11413, 13505, 13505}, - {4685, 13512, 13513}, - {13136, 13517, 13519}, - {7416, 13528, 13530}, - {12929, 13534, 13534}, - {11110, 13539, 13539}, - {11521, 13543, 13543}, - {12825, 13553, 13553}, - {13447, 13557, 13558}, - {12299, 13562, 13563}, - {9003, 13570, 13570}, - {12500, 13577, 13577}, - {13501, 13581, 13581}, - {9392, 13586, 13586}, - {12454, 13590, 13590}, - {6189, 13595, 13595}, - {13053, 13599, 13599}, - {11881, 13604, 13604}, - {13159, 13608, 13608}, - {4894, 13612, 13612}, - {13221, 13621, 13621}, - {8950, 13625, 13625}, - {13533, 13629, 13629}, - {9633, 13633, 13633}, - {7892, 13637, 13639}, - {13581, 13643, 13643}, - {13616, 13647, 13649}, - {12794, 13653, 13654}, - {8919, 13659, 13659}, - {9674, 13663, 13663}, - {13577, 13668, 13668}, - {12966, 13672, 13672}, - {12659, 13676, 13683}, - {6124, 13688, 13688}, - {9225, 13693, 13695}, - {11833, 13702, 13702}, - {12904, 13709, 13717}, - {13647, 13721, 13722}, - {11687, 13726, 13727}, - {12434, 13731, 13732}, - {12689, 13736, 13742}, - {13168, 13746, 13746}, - {6151, 13751, 13752}, - {11821, 13756, 13757}, - {6467, 13764, 13764}, - {5730, 13769, 13769}, - {5136, 13780, 13780}, - {724, 13784, 13785}, - {13517, 13789, 13791}, - {640, 13795, 13796}, - {7721, 13800, 13802}, - {11121, 13806, 13807}, - {5791, 13811, 13815}, - {12894, 13819, 13819}, - {11100, 13824, 13824}, - {7011, 13830, 13830}, - {7129, 13834, 13837}, - {13833, 13841, 13841}, - {11276, 13847, 13847}, - {13621, 13853, 13853}, - {13589, 13862, 13863}, - {12989, 13867, 13867}, - {12789, 13871, 13871}, - {1239, 13875, 13875}, - {4675, 13879, 13881}, - {4686, 13885, 13885}, - {707, 13889, 13889}, - {5449, 13897, 13898}, - {13867, 13902, 13903}, - {10613, 13908, 13908}, - {13789, 13912, 13914}, - {4451, 13918, 13919}, - {9200, 13924, 13924}, - {2011, 13930, 13930}, - {11433, 13934, 13936}, - {4695, 13942, 13943}, - {9435, 13948, 13951}, - {13688, 13955, 13957}, - {11694, 13961, 13962}, - {5712, 13966, 13966}, - {5991, 13970, 13972}, - {13477, 13976, 13976}, - {10213, 13987, 13987}, - {11839, 13991, 13993}, - {12272, 13997, 13997}, - {6206, 14001, 14001}, - {13179, 14006, 14007}, - {2939, 14011, 14011}, - {12972, 14016, 14017}, - {13918, 14021, 14022}, - {7436, 14026, 14027}, - {7678, 14032, 14034}, - {13586, 14040, 14040}, - {13347, 14044, 14044}, - {13109, 14048, 14051}, - {9244, 14055, 14057}, - {13315, 14061, 14061}, - {13276, 14067, 14067}, - {11435, 14073, 14074}, - {13853, 14078, 14078}, - {13452, 14082, 14082}, - {14044, 14087, 14087}, - {4440, 14091, 14095}, - {4479, 14100, 14103}, - {9395, 14107, 14109}, - {6834, 14119, 14119}, - {10458, 14123, 14124}, - {1429, 14129, 14129}, - {8443, 14135, 14135}, - {10365, 14140, 14140}, - {5267, 14145, 14145}, - {11834, 14151, 14153}, -} diff --git a/vendor/github.com/golang/snappy/snappy.go b/vendor/github.com/golang/snappy/snappy.go deleted file mode 100644 index 0cf5e37..0000000 --- a/vendor/github.com/golang/snappy/snappy.go +++ /dev/null @@ -1,87 +0,0 @@ -// Copyright 2011 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package snappy implements the snappy block-based compression format. -// It aims for very high speeds and reasonable compression. -// -// The C++ snappy implementation is at https://github.com/google/snappy -package snappy // import "github.com/golang/snappy" - -import ( - "hash/crc32" -) - -/* -Each encoded block begins with the varint-encoded length of the decoded data, -followed by a sequence of chunks. Chunks begin and end on byte boundaries. The -first byte of each chunk is broken into its 2 least and 6 most significant bits -called l and m: l ranges in [0, 4) and m ranges in [0, 64). l is the chunk tag. -Zero means a literal tag. All other values mean a copy tag. - -For literal tags: - - If m < 60, the next 1 + m bytes are literal bytes. - - Otherwise, let n be the little-endian unsigned integer denoted by the next - m - 59 bytes. The next 1 + n bytes after that are literal bytes. - -For copy tags, length bytes are copied from offset bytes ago, in the style of -Lempel-Ziv compression algorithms. In particular: - - For l == 1, the offset ranges in [0, 1<<11) and the length in [4, 12). - The length is 4 + the low 3 bits of m. The high 3 bits of m form bits 8-10 - of the offset. The next byte is bits 0-7 of the offset. - - For l == 2, the offset ranges in [0, 1<<16) and the length in [1, 65). - The length is 1 + m. The offset is the little-endian unsigned integer - denoted by the next 2 bytes. - - For l == 3, this tag is a legacy format that is no longer issued by most - encoders. Nonetheless, the offset ranges in [0, 1<<32) and the length in - [1, 65). The length is 1 + m. The offset is the little-endian unsigned - integer denoted by the next 4 bytes. -*/ -const ( - tagLiteral = 0x00 - tagCopy1 = 0x01 - tagCopy2 = 0x02 - tagCopy4 = 0x03 -) - -const ( - checksumSize = 4 - chunkHeaderSize = 4 - magicChunk = "\xff\x06\x00\x00" + magicBody - magicBody = "sNaPpY" - - // maxBlockSize is the maximum size of the input to encodeBlock. It is not - // part of the wire format per se, but some parts of the encoder assume - // that an offset fits into a uint16. - // - // Also, for the framing format (Writer type instead of Encode function), - // https://github.com/google/snappy/blob/master/framing_format.txt says - // that "the uncompressed data in a chunk must be no longer than 65536 - // bytes". - maxBlockSize = 65536 - - // maxEncodedLenOfMaxBlockSize equals MaxEncodedLen(maxBlockSize), but is - // hard coded to be a const instead of a variable, so that obufLen can also - // be a const. Their equivalence is confirmed by - // TestMaxEncodedLenOfMaxBlockSize. - maxEncodedLenOfMaxBlockSize = 76490 - - obufHeaderLen = len(magicChunk) + checksumSize + chunkHeaderSize - obufLen = obufHeaderLen + maxEncodedLenOfMaxBlockSize -) - -const ( - chunkTypeCompressedData = 0x00 - chunkTypeUncompressedData = 0x01 - chunkTypePadding = 0xfe - chunkTypeStreamIdentifier = 0xff -) - -var crcTable = crc32.MakeTable(crc32.Castagnoli) - -// crc implements the checksum specified in section 3 of -// https://github.com/google/snappy/blob/master/framing_format.txt -func crc(b []byte) uint32 { - c := crc32.Update(0, crcTable, b) - return uint32(c>>15|c<<17) + 0xa282ead8 -} diff --git a/vendor/github.com/golang/snappy/snappy_test.go b/vendor/github.com/golang/snappy/snappy_test.go deleted file mode 100644 index 2712710..0000000 --- a/vendor/github.com/golang/snappy/snappy_test.go +++ /dev/null @@ -1,1353 +0,0 @@ -// Copyright 2011 The Snappy-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package snappy - -import ( - "bytes" - "encoding/binary" - "flag" - "fmt" - "io" - "io/ioutil" - "math/rand" - "net/http" - "os" - "os/exec" - "path/filepath" - "runtime" - "strings" - "testing" -) - -var ( - download = flag.Bool("download", false, "If true, download any missing files before running benchmarks") - testdataDir = flag.String("testdataDir", "testdata", "Directory containing the test data") - benchdataDir = flag.String("benchdataDir", "testdata/bench", "Directory containing the benchmark data") -) - -// goEncoderShouldMatchCppEncoder is whether to test that the algorithm used by -// Go's encoder matches byte-for-byte what the C++ snappy encoder produces, on -// this GOARCH. There is more than one valid encoding of any given input, and -// there is more than one good algorithm along the frontier of trading off -// throughput for output size. Nonetheless, we presume that the C++ encoder's -// algorithm is a good one and has been tested on a wide range of inputs, so -// matching that exactly should mean that the Go encoder's algorithm is also -// good, without needing to gather our own corpus of test data. -// -// The exact algorithm used by the C++ code is potentially endian dependent, as -// it puns a byte pointer to a uint32 pointer to load, hash and compare 4 bytes -// at a time. The Go implementation is endian agnostic, in that its output is -// the same (as little-endian C++ code), regardless of the CPU's endianness. -// -// Thus, when comparing Go's output to C++ output generated beforehand, such as -// the "testdata/pi.txt.rawsnappy" file generated by C++ code on a little- -// endian system, we can run that test regardless of the runtime.GOARCH value. -// -// When comparing Go's output to dynamically generated C++ output, i.e. the -// result of fork/exec'ing a C++ program, we can run that test only on -// little-endian systems, because the C++ output might be different on -// big-endian systems. The runtime package doesn't export endianness per se, -// but we can restrict this match-C++ test to common little-endian systems. -const goEncoderShouldMatchCppEncoder = runtime.GOARCH == "386" || runtime.GOARCH == "amd64" || runtime.GOARCH == "arm" - -func TestMaxEncodedLenOfMaxBlockSize(t *testing.T) { - got := maxEncodedLenOfMaxBlockSize - want := MaxEncodedLen(maxBlockSize) - if got != want { - t.Fatalf("got %d, want %d", got, want) - } -} - -func cmp(a, b []byte) error { - if bytes.Equal(a, b) { - return nil - } - if len(a) != len(b) { - return fmt.Errorf("got %d bytes, want %d", len(a), len(b)) - } - for i := range a { - if a[i] != b[i] { - return fmt.Errorf("byte #%d: got 0x%02x, want 0x%02x", i, a[i], b[i]) - } - } - return nil -} - -func roundtrip(b, ebuf, dbuf []byte) error { - d, err := Decode(dbuf, Encode(ebuf, b)) - if err != nil { - return fmt.Errorf("decoding error: %v", err) - } - if err := cmp(d, b); err != nil { - return fmt.Errorf("roundtrip mismatch: %v", err) - } - return nil -} - -func TestEmpty(t *testing.T) { - if err := roundtrip(nil, nil, nil); err != nil { - t.Fatal(err) - } -} - -func TestSmallCopy(t *testing.T) { - for _, ebuf := range [][]byte{nil, make([]byte, 20), make([]byte, 64)} { - for _, dbuf := range [][]byte{nil, make([]byte, 20), make([]byte, 64)} { - for i := 0; i < 32; i++ { - s := "aaaa" + strings.Repeat("b", i) + "aaaabbbb" - if err := roundtrip([]byte(s), ebuf, dbuf); err != nil { - t.Errorf("len(ebuf)=%d, len(dbuf)=%d, i=%d: %v", len(ebuf), len(dbuf), i, err) - } - } - } - } -} - -func TestSmallRand(t *testing.T) { - rng := rand.New(rand.NewSource(1)) - for n := 1; n < 20000; n += 23 { - b := make([]byte, n) - for i := range b { - b[i] = uint8(rng.Intn(256)) - } - if err := roundtrip(b, nil, nil); err != nil { - t.Fatal(err) - } - } -} - -func TestSmallRegular(t *testing.T) { - for n := 1; n < 20000; n += 23 { - b := make([]byte, n) - for i := range b { - b[i] = uint8(i%10 + 'a') - } - if err := roundtrip(b, nil, nil); err != nil { - t.Fatal(err) - } - } -} - -func TestInvalidVarint(t *testing.T) { - testCases := []struct { - desc string - input string - }{{ - "invalid varint, final byte has continuation bit set", - "\xff", - }, { - "invalid varint, value overflows uint64", - "\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\x00", - }, { - // https://github.com/google/snappy/blob/master/format_description.txt - // says that "the stream starts with the uncompressed length [as a - // varint] (up to a maximum of 2^32 - 1)". - "valid varint (as uint64), but value overflows uint32", - "\x80\x80\x80\x80\x10", - }} - - for _, tc := range testCases { - input := []byte(tc.input) - if _, err := DecodedLen(input); err != ErrCorrupt { - t.Errorf("%s: DecodedLen: got %v, want ErrCorrupt", tc.desc, err) - } - if _, err := Decode(nil, input); err != ErrCorrupt { - t.Errorf("%s: Decode: got %v, want ErrCorrupt", tc.desc, err) - } - } -} - -func TestDecode(t *testing.T) { - lit40Bytes := make([]byte, 40) - for i := range lit40Bytes { - lit40Bytes[i] = byte(i) - } - lit40 := string(lit40Bytes) - - testCases := []struct { - desc string - input string - want string - wantErr error - }{{ - `decodedLen=0; valid input`, - "\x00", - "", - nil, - }, { - `decodedLen=3; tagLiteral, 0-byte length; length=3; valid input`, - "\x03" + "\x08\xff\xff\xff", - "\xff\xff\xff", - nil, - }, { - `decodedLen=2; tagLiteral, 0-byte length; length=3; not enough dst bytes`, - "\x02" + "\x08\xff\xff\xff", - "", - ErrCorrupt, - }, { - `decodedLen=3; tagLiteral, 0-byte length; length=3; not enough src bytes`, - "\x03" + "\x08\xff\xff", - "", - ErrCorrupt, - }, { - `decodedLen=40; tagLiteral, 0-byte length; length=40; valid input`, - "\x28" + "\x9c" + lit40, - lit40, - nil, - }, { - `decodedLen=1; tagLiteral, 1-byte length; not enough length bytes`, - "\x01" + "\xf0", - "", - ErrCorrupt, - }, { - `decodedLen=3; tagLiteral, 1-byte length; length=3; valid input`, - "\x03" + "\xf0\x02\xff\xff\xff", - "\xff\xff\xff", - nil, - }, { - `decodedLen=1; tagLiteral, 2-byte length; not enough length bytes`, - "\x01" + "\xf4\x00", - "", - ErrCorrupt, - }, { - `decodedLen=3; tagLiteral, 2-byte length; length=3; valid input`, - "\x03" + "\xf4\x02\x00\xff\xff\xff", - "\xff\xff\xff", - nil, - }, { - `decodedLen=1; tagLiteral, 3-byte length; not enough length bytes`, - "\x01" + "\xf8\x00\x00", - "", - ErrCorrupt, - }, { - `decodedLen=3; tagLiteral, 3-byte length; length=3; valid input`, - "\x03" + "\xf8\x02\x00\x00\xff\xff\xff", - "\xff\xff\xff", - nil, - }, { - `decodedLen=1; tagLiteral, 4-byte length; not enough length bytes`, - "\x01" + "\xfc\x00\x00\x00", - "", - ErrCorrupt, - }, { - `decodedLen=1; tagLiteral, 4-byte length; length=3; not enough dst bytes`, - "\x01" + "\xfc\x02\x00\x00\x00\xff\xff\xff", - "", - ErrCorrupt, - }, { - `decodedLen=4; tagLiteral, 4-byte length; length=3; not enough src bytes`, - "\x04" + "\xfc\x02\x00\x00\x00\xff", - "", - ErrCorrupt, - }, { - `decodedLen=3; tagLiteral, 4-byte length; length=3; valid input`, - "\x03" + "\xfc\x02\x00\x00\x00\xff\xff\xff", - "\xff\xff\xff", - nil, - }, { - `decodedLen=4; tagCopy1, 1 extra length|offset byte; not enough extra bytes`, - "\x04" + "\x01", - "", - ErrCorrupt, - }, { - `decodedLen=4; tagCopy2, 2 extra length|offset bytes; not enough extra bytes`, - "\x04" + "\x02\x00", - "", - ErrCorrupt, - }, { - `decodedLen=4; tagCopy4, 4 extra length|offset bytes; not enough extra bytes`, - "\x04" + "\x03\x00\x00\x00", - "", - ErrCorrupt, - }, { - `decodedLen=4; tagLiteral (4 bytes "abcd"); valid input`, - "\x04" + "\x0cabcd", - "abcd", - nil, - }, { - `decodedLen=13; tagLiteral (4 bytes "abcd"); tagCopy1; length=9 offset=4; valid input`, - "\x0d" + "\x0cabcd" + "\x15\x04", - "abcdabcdabcda", - nil, - }, { - `decodedLen=8; tagLiteral (4 bytes "abcd"); tagCopy1; length=4 offset=4; valid input`, - "\x08" + "\x0cabcd" + "\x01\x04", - "abcdabcd", - nil, - }, { - `decodedLen=8; tagLiteral (4 bytes "abcd"); tagCopy1; length=4 offset=2; valid input`, - "\x08" + "\x0cabcd" + "\x01\x02", - "abcdcdcd", - nil, - }, { - `decodedLen=8; tagLiteral (4 bytes "abcd"); tagCopy1; length=4 offset=1; valid input`, - "\x08" + "\x0cabcd" + "\x01\x01", - "abcddddd", - nil, - }, { - `decodedLen=8; tagLiteral (4 bytes "abcd"); tagCopy1; length=4 offset=0; zero offset`, - "\x08" + "\x0cabcd" + "\x01\x00", - "", - ErrCorrupt, - }, { - `decodedLen=9; tagLiteral (4 bytes "abcd"); tagCopy1; length=4 offset=4; inconsistent dLen`, - "\x09" + "\x0cabcd" + "\x01\x04", - "", - ErrCorrupt, - }, { - `decodedLen=8; tagLiteral (4 bytes "abcd"); tagCopy1; length=4 offset=5; offset too large`, - "\x08" + "\x0cabcd" + "\x01\x05", - "", - ErrCorrupt, - }, { - `decodedLen=7; tagLiteral (4 bytes "abcd"); tagCopy1; length=4 offset=4; length too large`, - "\x07" + "\x0cabcd" + "\x01\x04", - "", - ErrCorrupt, - }, { - `decodedLen=6; tagLiteral (4 bytes "abcd"); tagCopy2; length=2 offset=3; valid input`, - "\x06" + "\x0cabcd" + "\x06\x03\x00", - "abcdbc", - nil, - }, { - `decodedLen=6; tagLiteral (4 bytes "abcd"); tagCopy4; length=2 offset=3; valid input`, - "\x06" + "\x0cabcd" + "\x07\x03\x00\x00\x00", - "abcdbc", - nil, - }} - - const ( - // notPresentXxx defines a range of byte values [0xa0, 0xc5) that are - // not present in either the input or the output. It is written to dBuf - // to check that Decode does not write bytes past the end of - // dBuf[:dLen]. - // - // The magic number 37 was chosen because it is prime. A more 'natural' - // number like 32 might lead to a false negative if, for example, a - // byte was incorrectly copied 4*8 bytes later. - notPresentBase = 0xa0 - notPresentLen = 37 - ) - - var dBuf [100]byte -loop: - for i, tc := range testCases { - input := []byte(tc.input) - for _, x := range input { - if notPresentBase <= x && x < notPresentBase+notPresentLen { - t.Errorf("#%d (%s): input shouldn't contain %#02x\ninput: % x", i, tc.desc, x, input) - continue loop - } - } - - dLen, n := binary.Uvarint(input) - if n <= 0 { - t.Errorf("#%d (%s): invalid varint-encoded dLen", i, tc.desc) - continue - } - if dLen > uint64(len(dBuf)) { - t.Errorf("#%d (%s): dLen %d is too large", i, tc.desc, dLen) - continue - } - - for j := range dBuf { - dBuf[j] = byte(notPresentBase + j%notPresentLen) - } - g, gotErr := Decode(dBuf[:], input) - if got := string(g); got != tc.want || gotErr != tc.wantErr { - t.Errorf("#%d (%s):\ngot %q, %v\nwant %q, %v", - i, tc.desc, got, gotErr, tc.want, tc.wantErr) - continue - } - for j, x := range dBuf { - if uint64(j) < dLen { - continue - } - if w := byte(notPresentBase + j%notPresentLen); x != w { - t.Errorf("#%d (%s): Decode overrun: dBuf[%d] was modified: got %#02x, want %#02x\ndBuf: % x", - i, tc.desc, j, x, w, dBuf) - continue loop - } - } - } -} - -func TestDecodeCopy4(t *testing.T) { - dots := strings.Repeat(".", 65536) - - input := strings.Join([]string{ - "\x89\x80\x04", // decodedLen = 65545. - "\x0cpqrs", // 4-byte literal "pqrs". - "\xf4\xff\xff" + dots, // 65536-byte literal dots. - "\x13\x04\x00\x01\x00", // tagCopy4; length=5 offset=65540. - }, "") - - gotBytes, err := Decode(nil, []byte(input)) - if err != nil { - t.Fatal(err) - } - got := string(gotBytes) - want := "pqrs" + dots + "pqrs." - if len(got) != len(want) { - t.Fatalf("got %d bytes, want %d", len(got), len(want)) - } - if got != want { - for i := 0; i < len(got); i++ { - if g, w := got[i], want[i]; g != w { - t.Fatalf("byte #%d: got %#02x, want %#02x", i, g, w) - } - } - } -} - -// TestDecodeLengthOffset tests decoding an encoding of the form literal + -// copy-length-offset + literal. For example: "abcdefghijkl" + "efghij" + "AB". -func TestDecodeLengthOffset(t *testing.T) { - const ( - prefix = "abcdefghijklmnopqr" - suffix = "ABCDEFGHIJKLMNOPQR" - - // notPresentXxx defines a range of byte values [0xa0, 0xc5) that are - // not present in either the input or the output. It is written to - // gotBuf to check that Decode does not write bytes past the end of - // gotBuf[:totalLen]. - // - // The magic number 37 was chosen because it is prime. A more 'natural' - // number like 32 might lead to a false negative if, for example, a - // byte was incorrectly copied 4*8 bytes later. - notPresentBase = 0xa0 - notPresentLen = 37 - ) - var gotBuf, wantBuf, inputBuf [128]byte - for length := 1; length <= 18; length++ { - for offset := 1; offset <= 18; offset++ { - loop: - for suffixLen := 0; suffixLen <= 18; suffixLen++ { - totalLen := len(prefix) + length + suffixLen - - inputLen := binary.PutUvarint(inputBuf[:], uint64(totalLen)) - inputBuf[inputLen] = tagLiteral + 4*byte(len(prefix)-1) - inputLen++ - inputLen += copy(inputBuf[inputLen:], prefix) - inputBuf[inputLen+0] = tagCopy2 + 4*byte(length-1) - inputBuf[inputLen+1] = byte(offset) - inputBuf[inputLen+2] = 0x00 - inputLen += 3 - if suffixLen > 0 { - inputBuf[inputLen] = tagLiteral + 4*byte(suffixLen-1) - inputLen++ - inputLen += copy(inputBuf[inputLen:], suffix[:suffixLen]) - } - input := inputBuf[:inputLen] - - for i := range gotBuf { - gotBuf[i] = byte(notPresentBase + i%notPresentLen) - } - got, err := Decode(gotBuf[:], input) - if err != nil { - t.Errorf("length=%d, offset=%d; suffixLen=%d: %v", length, offset, suffixLen, err) - continue - } - - wantLen := 0 - wantLen += copy(wantBuf[wantLen:], prefix) - for i := 0; i < length; i++ { - wantBuf[wantLen] = wantBuf[wantLen-offset] - wantLen++ - } - wantLen += copy(wantBuf[wantLen:], suffix[:suffixLen]) - want := wantBuf[:wantLen] - - for _, x := range input { - if notPresentBase <= x && x < notPresentBase+notPresentLen { - t.Errorf("length=%d, offset=%d; suffixLen=%d: input shouldn't contain %#02x\ninput: % x", - length, offset, suffixLen, x, input) - continue loop - } - } - for i, x := range gotBuf { - if i < totalLen { - continue - } - if w := byte(notPresentBase + i%notPresentLen); x != w { - t.Errorf("length=%d, offset=%d; suffixLen=%d; totalLen=%d: "+ - "Decode overrun: gotBuf[%d] was modified: got %#02x, want %#02x\ngotBuf: % x", - length, offset, suffixLen, totalLen, i, x, w, gotBuf) - continue loop - } - } - for _, x := range want { - if notPresentBase <= x && x < notPresentBase+notPresentLen { - t.Errorf("length=%d, offset=%d; suffixLen=%d: want shouldn't contain %#02x\nwant: % x", - length, offset, suffixLen, x, want) - continue loop - } - } - - if !bytes.Equal(got, want) { - t.Errorf("length=%d, offset=%d; suffixLen=%d:\ninput % x\ngot % x\nwant % x", - length, offset, suffixLen, input, got, want) - continue - } - } - } - } -} - -const ( - goldenText = "Mark.Twain-Tom.Sawyer.txt" - goldenCompressed = goldenText + ".rawsnappy" -) - -func TestDecodeGoldenInput(t *testing.T) { - tDir := filepath.FromSlash(*testdataDir) - src, err := ioutil.ReadFile(filepath.Join(tDir, goldenCompressed)) - if err != nil { - t.Fatalf("ReadFile: %v", err) - } - got, err := Decode(nil, src) - if err != nil { - t.Fatalf("Decode: %v", err) - } - want, err := ioutil.ReadFile(filepath.Join(tDir, goldenText)) - if err != nil { - t.Fatalf("ReadFile: %v", err) - } - if err := cmp(got, want); err != nil { - t.Fatal(err) - } -} - -func TestEncodeGoldenInput(t *testing.T) { - tDir := filepath.FromSlash(*testdataDir) - src, err := ioutil.ReadFile(filepath.Join(tDir, goldenText)) - if err != nil { - t.Fatalf("ReadFile: %v", err) - } - got := Encode(nil, src) - want, err := ioutil.ReadFile(filepath.Join(tDir, goldenCompressed)) - if err != nil { - t.Fatalf("ReadFile: %v", err) - } - if err := cmp(got, want); err != nil { - t.Fatal(err) - } -} - -func TestExtendMatchGoldenInput(t *testing.T) { - tDir := filepath.FromSlash(*testdataDir) - src, err := ioutil.ReadFile(filepath.Join(tDir, goldenText)) - if err != nil { - t.Fatalf("ReadFile: %v", err) - } - for i, tc := range extendMatchGoldenTestCases { - got := extendMatch(src, tc.i, tc.j) - if got != tc.want { - t.Errorf("test #%d: i, j = %5d, %5d: got %5d (= j + %6d), want %5d (= j + %6d)", - i, tc.i, tc.j, got, got-tc.j, tc.want, tc.want-tc.j) - } - } -} - -func TestExtendMatch(t *testing.T) { - // ref is a simple, reference implementation of extendMatch. - ref := func(src []byte, i, j int) int { - for ; j < len(src) && src[i] == src[j]; i, j = i+1, j+1 { - } - return j - } - - nums := []int{0, 1, 2, 7, 8, 9, 29, 30, 31, 32, 33, 34, 38, 39, 40} - for yIndex := 40; yIndex > 30; yIndex-- { - xxx := bytes.Repeat([]byte("x"), 40) - if yIndex < len(xxx) { - xxx[yIndex] = 'y' - } - for _, i := range nums { - for _, j := range nums { - if i >= j { - continue - } - got := extendMatch(xxx, i, j) - want := ref(xxx, i, j) - if got != want { - t.Errorf("yIndex=%d, i=%d, j=%d: got %d, want %d", yIndex, i, j, got, want) - } - } - } - } -} - -const snappytoolCmdName = "cmd/snappytool/snappytool" - -func skipTestSameEncodingAsCpp() (msg string) { - if !goEncoderShouldMatchCppEncoder { - return fmt.Sprintf("skipping testing that the encoding is byte-for-byte identical to C++: GOARCH=%s", runtime.GOARCH) - } - if _, err := os.Stat(snappytoolCmdName); err != nil { - return fmt.Sprintf("could not find snappytool: %v", err) - } - return "" -} - -func runTestSameEncodingAsCpp(src []byte) error { - got := Encode(nil, src) - - cmd := exec.Command(snappytoolCmdName, "-e") - cmd.Stdin = bytes.NewReader(src) - want, err := cmd.Output() - if err != nil { - return fmt.Errorf("could not run snappytool: %v", err) - } - return cmp(got, want) -} - -func TestSameEncodingAsCppShortCopies(t *testing.T) { - if msg := skipTestSameEncodingAsCpp(); msg != "" { - t.Skip(msg) - } - src := bytes.Repeat([]byte{'a'}, 20) - for i := 0; i <= len(src); i++ { - if err := runTestSameEncodingAsCpp(src[:i]); err != nil { - t.Errorf("i=%d: %v", i, err) - } - } -} - -func TestSameEncodingAsCppLongFiles(t *testing.T) { - if msg := skipTestSameEncodingAsCpp(); msg != "" { - t.Skip(msg) - } - bDir := filepath.FromSlash(*benchdataDir) - failed := false - for i, tf := range testFiles { - if err := downloadBenchmarkFiles(t, tf.filename); err != nil { - t.Fatalf("failed to download testdata: %s", err) - } - data := readFile(t, filepath.Join(bDir, tf.filename)) - if n := tf.sizeLimit; 0 < n && n < len(data) { - data = data[:n] - } - if err := runTestSameEncodingAsCpp(data); err != nil { - t.Errorf("i=%d: %v", i, err) - failed = true - } - } - if failed { - t.Errorf("was the snappytool program built against the C++ snappy library version " + - "d53de187 or later, commited on 2016-04-05? See " + - "https://github.com/google/snappy/commit/d53de18799418e113e44444252a39b12a0e4e0cc") - } -} - -// TestSlowForwardCopyOverrun tests the "expand the pattern" algorithm -// described in decode_amd64.s and its claim of a 10 byte overrun worst case. -func TestSlowForwardCopyOverrun(t *testing.T) { - const base = 100 - - for length := 1; length < 18; length++ { - for offset := 1; offset < 18; offset++ { - highWaterMark := base - d := base - l := length - o := offset - - // makeOffsetAtLeast8 - for o < 8 { - if end := d + 8; highWaterMark < end { - highWaterMark = end - } - l -= o - d += o - o += o - } - - // fixUpSlowForwardCopy - a := d - d += l - - // finishSlowForwardCopy - for l > 0 { - if end := a + 8; highWaterMark < end { - highWaterMark = end - } - a += 8 - l -= 8 - } - - dWant := base + length - overrun := highWaterMark - dWant - if d != dWant || overrun < 0 || 10 < overrun { - t.Errorf("length=%d, offset=%d: d and overrun: got (%d, %d), want (%d, something in [0, 10])", - length, offset, d, overrun, dWant) - } - } - } -} - -// TestEncodeNoiseThenRepeats encodes input for which the first half is very -// incompressible and the second half is very compressible. The encoded form's -// length should be closer to 50% of the original length than 100%. -func TestEncodeNoiseThenRepeats(t *testing.T) { - for _, origLen := range []int{256 * 1024, 2048 * 1024} { - src := make([]byte, origLen) - rng := rand.New(rand.NewSource(1)) - firstHalf, secondHalf := src[:origLen/2], src[origLen/2:] - for i := range firstHalf { - firstHalf[i] = uint8(rng.Intn(256)) - } - for i := range secondHalf { - secondHalf[i] = uint8(i >> 8) - } - dst := Encode(nil, src) - if got, want := len(dst), origLen*3/4; got >= want { - t.Errorf("origLen=%d: got %d encoded bytes, want less than %d", origLen, got, want) - } - } -} - -func TestFramingFormat(t *testing.T) { - // src is comprised of alternating 1e5-sized sequences of random - // (incompressible) bytes and repeated (compressible) bytes. 1e5 was chosen - // because it is larger than maxBlockSize (64k). - src := make([]byte, 1e6) - rng := rand.New(rand.NewSource(1)) - for i := 0; i < 10; i++ { - if i%2 == 0 { - for j := 0; j < 1e5; j++ { - src[1e5*i+j] = uint8(rng.Intn(256)) - } - } else { - for j := 0; j < 1e5; j++ { - src[1e5*i+j] = uint8(i) - } - } - } - - buf := new(bytes.Buffer) - if _, err := NewWriter(buf).Write(src); err != nil { - t.Fatalf("Write: encoding: %v", err) - } - dst, err := ioutil.ReadAll(NewReader(buf)) - if err != nil { - t.Fatalf("ReadAll: decoding: %v", err) - } - if err := cmp(dst, src); err != nil { - t.Fatal(err) - } -} - -func TestWriterGoldenOutput(t *testing.T) { - buf := new(bytes.Buffer) - w := NewBufferedWriter(buf) - defer w.Close() - w.Write([]byte("abcd")) // Not compressible. - w.Flush() - w.Write(bytes.Repeat([]byte{'A'}, 150)) // Compressible. - w.Flush() - // The next chunk is also compressible, but a naive, greedy encoding of the - // overall length 67 copy as a length 64 copy (the longest expressible as a - // tagCopy1 or tagCopy2) plus a length 3 remainder would be two 3-byte - // tagCopy2 tags (6 bytes), since the minimum length for a tagCopy1 is 4 - // bytes. Instead, we could do it shorter, in 5 bytes: a 3-byte tagCopy2 - // (of length 60) and a 2-byte tagCopy1 (of length 7). - w.Write(bytes.Repeat([]byte{'B'}, 68)) - w.Write([]byte("efC")) // Not compressible. - w.Write(bytes.Repeat([]byte{'C'}, 20)) // Compressible. - w.Write(bytes.Repeat([]byte{'B'}, 20)) // Compressible. - w.Write([]byte("g")) // Not compressible. - w.Flush() - - got := buf.String() - want := strings.Join([]string{ - magicChunk, - "\x01\x08\x00\x00", // Uncompressed chunk, 8 bytes long (including 4 byte checksum). - "\x68\x10\xe6\xb6", // Checksum. - "\x61\x62\x63\x64", // Uncompressed payload: "abcd". - "\x00\x11\x00\x00", // Compressed chunk, 17 bytes long (including 4 byte checksum). - "\x5f\xeb\xf2\x10", // Checksum. - "\x96\x01", // Compressed payload: Uncompressed length (varint encoded): 150. - "\x00\x41", // Compressed payload: tagLiteral, length=1, "A". - "\xfe\x01\x00", // Compressed payload: tagCopy2, length=64, offset=1. - "\xfe\x01\x00", // Compressed payload: tagCopy2, length=64, offset=1. - "\x52\x01\x00", // Compressed payload: tagCopy2, length=21, offset=1. - "\x00\x18\x00\x00", // Compressed chunk, 24 bytes long (including 4 byte checksum). - "\x30\x85\x69\xeb", // Checksum. - "\x70", // Compressed payload: Uncompressed length (varint encoded): 112. - "\x00\x42", // Compressed payload: tagLiteral, length=1, "B". - "\xee\x01\x00", // Compressed payload: tagCopy2, length=60, offset=1. - "\x0d\x01", // Compressed payload: tagCopy1, length=7, offset=1. - "\x08\x65\x66\x43", // Compressed payload: tagLiteral, length=3, "efC". - "\x4e\x01\x00", // Compressed payload: tagCopy2, length=20, offset=1. - "\x4e\x5a\x00", // Compressed payload: tagCopy2, length=20, offset=90. - "\x00\x67", // Compressed payload: tagLiteral, length=1, "g". - }, "") - if got != want { - t.Fatalf("\ngot: % x\nwant: % x", got, want) - } -} - -func TestEmitLiteral(t *testing.T) { - testCases := []struct { - length int - want string - }{ - {1, "\x00"}, - {2, "\x04"}, - {59, "\xe8"}, - {60, "\xec"}, - {61, "\xf0\x3c"}, - {62, "\xf0\x3d"}, - {254, "\xf0\xfd"}, - {255, "\xf0\xfe"}, - {256, "\xf0\xff"}, - {257, "\xf4\x00\x01"}, - {65534, "\xf4\xfd\xff"}, - {65535, "\xf4\xfe\xff"}, - {65536, "\xf4\xff\xff"}, - } - - dst := make([]byte, 70000) - nines := bytes.Repeat([]byte{0x99}, 65536) - for _, tc := range testCases { - lit := nines[:tc.length] - n := emitLiteral(dst, lit) - if !bytes.HasSuffix(dst[:n], lit) { - t.Errorf("length=%d: did not end with that many literal bytes", tc.length) - continue - } - got := string(dst[:n-tc.length]) - if got != tc.want { - t.Errorf("length=%d:\ngot % x\nwant % x", tc.length, got, tc.want) - continue - } - } -} - -func TestEmitCopy(t *testing.T) { - testCases := []struct { - offset int - length int - want string - }{ - {8, 04, "\x01\x08"}, - {8, 11, "\x1d\x08"}, - {8, 12, "\x2e\x08\x00"}, - {8, 13, "\x32\x08\x00"}, - {8, 59, "\xea\x08\x00"}, - {8, 60, "\xee\x08\x00"}, - {8, 61, "\xf2\x08\x00"}, - {8, 62, "\xf6\x08\x00"}, - {8, 63, "\xfa\x08\x00"}, - {8, 64, "\xfe\x08\x00"}, - {8, 65, "\xee\x08\x00\x05\x08"}, - {8, 66, "\xee\x08\x00\x09\x08"}, - {8, 67, "\xee\x08\x00\x0d\x08"}, - {8, 68, "\xfe\x08\x00\x01\x08"}, - {8, 69, "\xfe\x08\x00\x05\x08"}, - {8, 80, "\xfe\x08\x00\x3e\x08\x00"}, - - {256, 04, "\x21\x00"}, - {256, 11, "\x3d\x00"}, - {256, 12, "\x2e\x00\x01"}, - {256, 13, "\x32\x00\x01"}, - {256, 59, "\xea\x00\x01"}, - {256, 60, "\xee\x00\x01"}, - {256, 61, "\xf2\x00\x01"}, - {256, 62, "\xf6\x00\x01"}, - {256, 63, "\xfa\x00\x01"}, - {256, 64, "\xfe\x00\x01"}, - {256, 65, "\xee\x00\x01\x25\x00"}, - {256, 66, "\xee\x00\x01\x29\x00"}, - {256, 67, "\xee\x00\x01\x2d\x00"}, - {256, 68, "\xfe\x00\x01\x21\x00"}, - {256, 69, "\xfe\x00\x01\x25\x00"}, - {256, 80, "\xfe\x00\x01\x3e\x00\x01"}, - - {2048, 04, "\x0e\x00\x08"}, - {2048, 11, "\x2a\x00\x08"}, - {2048, 12, "\x2e\x00\x08"}, - {2048, 13, "\x32\x00\x08"}, - {2048, 59, "\xea\x00\x08"}, - {2048, 60, "\xee\x00\x08"}, - {2048, 61, "\xf2\x00\x08"}, - {2048, 62, "\xf6\x00\x08"}, - {2048, 63, "\xfa\x00\x08"}, - {2048, 64, "\xfe\x00\x08"}, - {2048, 65, "\xee\x00\x08\x12\x00\x08"}, - {2048, 66, "\xee\x00\x08\x16\x00\x08"}, - {2048, 67, "\xee\x00\x08\x1a\x00\x08"}, - {2048, 68, "\xfe\x00\x08\x0e\x00\x08"}, - {2048, 69, "\xfe\x00\x08\x12\x00\x08"}, - {2048, 80, "\xfe\x00\x08\x3e\x00\x08"}, - } - - dst := make([]byte, 1024) - for _, tc := range testCases { - n := emitCopy(dst, tc.offset, tc.length) - got := string(dst[:n]) - if got != tc.want { - t.Errorf("offset=%d, length=%d:\ngot % x\nwant % x", tc.offset, tc.length, got, tc.want) - } - } -} - -func TestNewBufferedWriter(t *testing.T) { - // Test all 32 possible sub-sequences of these 5 input slices. - // - // Their lengths sum to 400,000, which is over 6 times the Writer ibuf - // capacity: 6 * maxBlockSize is 393,216. - inputs := [][]byte{ - bytes.Repeat([]byte{'a'}, 40000), - bytes.Repeat([]byte{'b'}, 150000), - bytes.Repeat([]byte{'c'}, 60000), - bytes.Repeat([]byte{'d'}, 120000), - bytes.Repeat([]byte{'e'}, 30000), - } -loop: - for i := 0; i < 1< 0; { - i := copy(x, src) - x = x[i:] - } - return dst -} - -func benchWords(b *testing.B, n int, decode bool) { - // Note: the file is OS-language dependent so the resulting values are not - // directly comparable for non-US-English OS installations. - data := expand(readFile(b, "/usr/share/dict/words"), n) - if decode { - benchDecode(b, data) - } else { - benchEncode(b, data) - } -} - -func BenchmarkWordsDecode1e1(b *testing.B) { benchWords(b, 1e1, true) } -func BenchmarkWordsDecode1e2(b *testing.B) { benchWords(b, 1e2, true) } -func BenchmarkWordsDecode1e3(b *testing.B) { benchWords(b, 1e3, true) } -func BenchmarkWordsDecode1e4(b *testing.B) { benchWords(b, 1e4, true) } -func BenchmarkWordsDecode1e5(b *testing.B) { benchWords(b, 1e5, true) } -func BenchmarkWordsDecode1e6(b *testing.B) { benchWords(b, 1e6, true) } -func BenchmarkWordsEncode1e1(b *testing.B) { benchWords(b, 1e1, false) } -func BenchmarkWordsEncode1e2(b *testing.B) { benchWords(b, 1e2, false) } -func BenchmarkWordsEncode1e3(b *testing.B) { benchWords(b, 1e3, false) } -func BenchmarkWordsEncode1e4(b *testing.B) { benchWords(b, 1e4, false) } -func BenchmarkWordsEncode1e5(b *testing.B) { benchWords(b, 1e5, false) } -func BenchmarkWordsEncode1e6(b *testing.B) { benchWords(b, 1e6, false) } - -func BenchmarkRandomEncode(b *testing.B) { - rng := rand.New(rand.NewSource(1)) - data := make([]byte, 1<<20) - for i := range data { - data[i] = uint8(rng.Intn(256)) - } - benchEncode(b, data) -} - -// testFiles' values are copied directly from -// https://raw.githubusercontent.com/google/snappy/master/snappy_unittest.cc -// The label field is unused in snappy-go. -var testFiles = []struct { - label string - filename string - sizeLimit int -}{ - {"html", "html", 0}, - {"urls", "urls.10K", 0}, - {"jpg", "fireworks.jpeg", 0}, - {"jpg_200", "fireworks.jpeg", 200}, - {"pdf", "paper-100k.pdf", 0}, - {"html4", "html_x_4", 0}, - {"txt1", "alice29.txt", 0}, - {"txt2", "asyoulik.txt", 0}, - {"txt3", "lcet10.txt", 0}, - {"txt4", "plrabn12.txt", 0}, - {"pb", "geo.protodata", 0}, - {"gaviota", "kppkn.gtb", 0}, -} - -const ( - // The benchmark data files are at this canonical URL. - benchURL = "https://raw.githubusercontent.com/google/snappy/master/testdata/" -) - -func downloadBenchmarkFiles(b testing.TB, basename string) (errRet error) { - bDir := filepath.FromSlash(*benchdataDir) - filename := filepath.Join(bDir, basename) - if stat, err := os.Stat(filename); err == nil && stat.Size() != 0 { - return nil - } - - if !*download { - b.Skipf("test data not found; skipping %s without the -download flag", testOrBenchmark(b)) - } - // Download the official snappy C++ implementation reference test data - // files for benchmarking. - if err := os.MkdirAll(bDir, 0777); err != nil && !os.IsExist(err) { - return fmt.Errorf("failed to create %s: %s", bDir, err) - } - - f, err := os.Create(filename) - if err != nil { - return fmt.Errorf("failed to create %s: %s", filename, err) - } - defer f.Close() - defer func() { - if errRet != nil { - os.Remove(filename) - } - }() - url := benchURL + basename - resp, err := http.Get(url) - if err != nil { - return fmt.Errorf("failed to download %s: %s", url, err) - } - defer resp.Body.Close() - if s := resp.StatusCode; s != http.StatusOK { - return fmt.Errorf("downloading %s: HTTP status code %d (%s)", url, s, http.StatusText(s)) - } - _, err = io.Copy(f, resp.Body) - if err != nil { - return fmt.Errorf("failed to download %s to %s: %s", url, filename, err) - } - return nil -} - -func benchFile(b *testing.B, i int, decode bool) { - if err := downloadBenchmarkFiles(b, testFiles[i].filename); err != nil { - b.Fatalf("failed to download testdata: %s", err) - } - bDir := filepath.FromSlash(*benchdataDir) - data := readFile(b, filepath.Join(bDir, testFiles[i].filename)) - if n := testFiles[i].sizeLimit; 0 < n && n < len(data) { - data = data[:n] - } - if decode { - benchDecode(b, data) - } else { - benchEncode(b, data) - } -} - -// Naming convention is kept similar to what snappy's C++ implementation uses. -func Benchmark_UFlat0(b *testing.B) { benchFile(b, 0, true) } -func Benchmark_UFlat1(b *testing.B) { benchFile(b, 1, true) } -func Benchmark_UFlat2(b *testing.B) { benchFile(b, 2, true) } -func Benchmark_UFlat3(b *testing.B) { benchFile(b, 3, true) } -func Benchmark_UFlat4(b *testing.B) { benchFile(b, 4, true) } -func Benchmark_UFlat5(b *testing.B) { benchFile(b, 5, true) } -func Benchmark_UFlat6(b *testing.B) { benchFile(b, 6, true) } -func Benchmark_UFlat7(b *testing.B) { benchFile(b, 7, true) } -func Benchmark_UFlat8(b *testing.B) { benchFile(b, 8, true) } -func Benchmark_UFlat9(b *testing.B) { benchFile(b, 9, true) } -func Benchmark_UFlat10(b *testing.B) { benchFile(b, 10, true) } -func Benchmark_UFlat11(b *testing.B) { benchFile(b, 11, true) } -func Benchmark_ZFlat0(b *testing.B) { benchFile(b, 0, false) } -func Benchmark_ZFlat1(b *testing.B) { benchFile(b, 1, false) } -func Benchmark_ZFlat2(b *testing.B) { benchFile(b, 2, false) } -func Benchmark_ZFlat3(b *testing.B) { benchFile(b, 3, false) } -func Benchmark_ZFlat4(b *testing.B) { benchFile(b, 4, false) } -func Benchmark_ZFlat5(b *testing.B) { benchFile(b, 5, false) } -func Benchmark_ZFlat6(b *testing.B) { benchFile(b, 6, false) } -func Benchmark_ZFlat7(b *testing.B) { benchFile(b, 7, false) } -func Benchmark_ZFlat8(b *testing.B) { benchFile(b, 8, false) } -func Benchmark_ZFlat9(b *testing.B) { benchFile(b, 9, false) } -func Benchmark_ZFlat10(b *testing.B) { benchFile(b, 10, false) } -func Benchmark_ZFlat11(b *testing.B) { benchFile(b, 11, false) } - -func BenchmarkExtendMatch(b *testing.B) { - tDir := filepath.FromSlash(*testdataDir) - src, err := ioutil.ReadFile(filepath.Join(tDir, goldenText)) - if err != nil { - b.Fatalf("ReadFile: %v", err) - } - b.ResetTimer() - for i := 0; i < b.N; i++ { - for _, tc := range extendMatchGoldenTestCases { - extendMatch(src, tc.i, tc.j) - } - } -} diff --git a/vendor/github.com/golang/snappy/testdata/Mark.Twain-Tom.Sawyer.txt b/vendor/github.com/golang/snappy/testdata/Mark.Twain-Tom.Sawyer.txt deleted file mode 100644 index 86a1875..0000000 --- a/vendor/github.com/golang/snappy/testdata/Mark.Twain-Tom.Sawyer.txt +++ /dev/null @@ -1,396 +0,0 @@ -Produced by David Widger. The previous edition was updated by Jose -Menendez. - - - - - - THE ADVENTURES OF TOM SAWYER - BY - MARK TWAIN - (Samuel Langhorne Clemens) - - - - - P R E F A C E - -MOST of the adventures recorded in this book really occurred; one or -two were experiences of my own, the rest those of boys who were -schoolmates of mine. Huck Finn is drawn from life; Tom Sawyer also, but -not from an individual--he is a combination of the characteristics of -three boys whom I knew, and therefore belongs to the composite order of -architecture. - -The odd superstitions touched upon were all prevalent among children -and slaves in the West at the period of this story--that is to say, -thirty or forty years ago. - -Although my book is intended mainly for the entertainment of boys and -girls, I hope it will not be shunned by men and women on that account, -for part of my plan has been to try to pleasantly remind adults of what -they once were themselves, and of how they felt and thought and talked, -and what queer enterprises they sometimes engaged in. - - THE AUTHOR. - -HARTFORD, 1876. - - - - T O M S A W Y E R - - - -CHAPTER I - -"TOM!" - -No answer. - -"TOM!" - -No answer. - -"What's gone with that boy, I wonder? You TOM!" - -No answer. - -The old lady pulled her spectacles down and looked over them about the -room; then she put them up and looked out under them. She seldom or -never looked THROUGH them for so small a thing as a boy; they were her -state pair, the pride of her heart, and were built for "style," not -service--she could have seen through a pair of stove-lids just as well. -She looked perplexed for a moment, and then said, not fiercely, but -still loud enough for the furniture to hear: - -"Well, I lay if I get hold of you I'll--" - -She did not finish, for by this time she was bending down and punching -under the bed with the broom, and so she needed breath to punctuate the -punches with. She resurrected nothing but the cat. - -"I never did see the beat of that boy!" - -She went to the open door and stood in it and looked out among the -tomato vines and "jimpson" weeds that constituted the garden. No Tom. -So she lifted up her voice at an angle calculated for distance and -shouted: - -"Y-o-u-u TOM!" - -There was a slight noise behind her and she turned just in time to -seize a small boy by the slack of his roundabout and arrest his flight. - -"There! I might 'a' thought of that closet. What you been doing in -there?" - -"Nothing." - -"Nothing! Look at your hands. And look at your mouth. What IS that -truck?" - -"I don't know, aunt." - -"Well, I know. It's jam--that's what it is. Forty times I've said if -you didn't let that jam alone I'd skin you. Hand me that switch." - -The switch hovered in the air--the peril was desperate-- - -"My! Look behind you, aunt!" - -The old lady whirled round, and snatched her skirts out of danger. The -lad fled on the instant, scrambled up the high board-fence, and -disappeared over it. - -His aunt Polly stood surprised a moment, and then broke into a gentle -laugh. - -"Hang the boy, can't I never learn anything? Ain't he played me tricks -enough like that for me to be looking out for him by this time? But old -fools is the biggest fools there is. Can't learn an old dog new tricks, -as the saying is. But my goodness, he never plays them alike, two days, -and how is a body to know what's coming? He 'pears to know just how -long he can torment me before I get my dander up, and he knows if he -can make out to put me off for a minute or make me laugh, it's all down -again and I can't hit him a lick. I ain't doing my duty by that boy, -and that's the Lord's truth, goodness knows. Spare the rod and spile -the child, as the Good Book says. I'm a laying up sin and suffering for -us both, I know. He's full of the Old Scratch, but laws-a-me! he's my -own dead sister's boy, poor thing, and I ain't got the heart to lash -him, somehow. Every time I let him off, my conscience does hurt me so, -and every time I hit him my old heart most breaks. Well-a-well, man -that is born of woman is of few days and full of trouble, as the -Scripture says, and I reckon it's so. He'll play hookey this evening, * -and [* Southwestern for "afternoon"] I'll just be obleeged to make him -work, to-morrow, to punish him. It's mighty hard to make him work -Saturdays, when all the boys is having holiday, but he hates work more -than he hates anything else, and I've GOT to do some of my duty by him, -or I'll be the ruination of the child." - -Tom did play hookey, and he had a very good time. He got back home -barely in season to help Jim, the small colored boy, saw next-day's -wood and split the kindlings before supper--at least he was there in -time to tell his adventures to Jim while Jim did three-fourths of the -work. Tom's younger brother (or rather half-brother) Sid was already -through with his part of the work (picking up chips), for he was a -quiet boy, and had no adventurous, troublesome ways. - -While Tom was eating his supper, and stealing sugar as opportunity -offered, Aunt Polly asked him questions that were full of guile, and -very deep--for she wanted to trap him into damaging revealments. Like -many other simple-hearted souls, it was her pet vanity to believe she -was endowed with a talent for dark and mysterious diplomacy, and she -loved to contemplate her most transparent devices as marvels of low -cunning. Said she: - -"Tom, it was middling warm in school, warn't it?" - -"Yes'm." - -"Powerful warm, warn't it?" - -"Yes'm." - -"Didn't you want to go in a-swimming, Tom?" - -A bit of a scare shot through Tom--a touch of uncomfortable suspicion. -He searched Aunt Polly's face, but it told him nothing. So he said: - -"No'm--well, not very much." - -The old lady reached out her hand and felt Tom's shirt, and said: - -"But you ain't too warm now, though." And it flattered her to reflect -that she had discovered that the shirt was dry without anybody knowing -that that was what she had in her mind. But in spite of her, Tom knew -where the wind lay, now. So he forestalled what might be the next move: - -"Some of us pumped on our heads--mine's damp yet. See?" - -Aunt Polly was vexed to think she had overlooked that bit of -circumstantial evidence, and missed a trick. Then she had a new -inspiration: - -"Tom, you didn't have to undo your shirt collar where I sewed it, to -pump on your head, did you? Unbutton your jacket!" - -The trouble vanished out of Tom's face. He opened his jacket. His -shirt collar was securely sewed. - -"Bother! Well, go 'long with you. I'd made sure you'd played hookey -and been a-swimming. But I forgive ye, Tom. I reckon you're a kind of a -singed cat, as the saying is--better'n you look. THIS time." - -She was half sorry her sagacity had miscarried, and half glad that Tom -had stumbled into obedient conduct for once. - -But Sidney said: - -"Well, now, if I didn't think you sewed his collar with white thread, -but it's black." - -"Why, I did sew it with white! Tom!" - -But Tom did not wait for the rest. As he went out at the door he said: - -"Siddy, I'll lick you for that." - -In a safe place Tom examined two large needles which were thrust into -the lapels of his jacket, and had thread bound about them--one needle -carried white thread and the other black. He said: - -"She'd never noticed if it hadn't been for Sid. Confound it! sometimes -she sews it with white, and sometimes she sews it with black. I wish to -geeminy she'd stick to one or t'other--I can't keep the run of 'em. But -I bet you I'll lam Sid for that. I'll learn him!" - -He was not the Model Boy of the village. He knew the model boy very -well though--and loathed him. - -Within two minutes, or even less, he had forgotten all his troubles. -Not because his troubles were one whit less heavy and bitter to him -than a man's are to a man, but because a new and powerful interest bore -them down and drove them out of his mind for the time--just as men's -misfortunes are forgotten in the excitement of new enterprises. This -new interest was a valued novelty in whistling, which he had just -acquired from a negro, and he was suffering to practise it undisturbed. -It consisted in a peculiar bird-like turn, a sort of liquid warble, -produced by touching the tongue to the roof of the mouth at short -intervals in the midst of the music--the reader probably remembers how -to do it, if he has ever been a boy. Diligence and attention soon gave -him the knack of it, and he strode down the street with his mouth full -of harmony and his soul full of gratitude. He felt much as an -astronomer feels who has discovered a new planet--no doubt, as far as -strong, deep, unalloyed pleasure is concerned, the advantage was with -the boy, not the astronomer. - -The summer evenings were long. It was not dark, yet. Presently Tom -checked his whistle. A stranger was before him--a boy a shade larger -than himself. A new-comer of any age or either sex was an impressive -curiosity in the poor little shabby village of St. Petersburg. This boy -was well dressed, too--well dressed on a week-day. This was simply -astounding. His cap was a dainty thing, his close-buttoned blue cloth -roundabout was new and natty, and so were his pantaloons. He had shoes -on--and it was only Friday. He even wore a necktie, a bright bit of -ribbon. He had a citified air about him that ate into Tom's vitals. The -more Tom stared at the splendid marvel, the higher he turned up his -nose at his finery and the shabbier and shabbier his own outfit seemed -to him to grow. Neither boy spoke. If one moved, the other moved--but -only sidewise, in a circle; they kept face to face and eye to eye all -the time. Finally Tom said: - -"I can lick you!" - -"I'd like to see you try it." - -"Well, I can do it." - -"No you can't, either." - -"Yes I can." - -"No you can't." - -"I can." - -"You can't." - -"Can!" - -"Can't!" - -An uncomfortable pause. Then Tom said: - -"What's your name?" - -"'Tisn't any of your business, maybe." - -"Well I 'low I'll MAKE it my business." - -"Well why don't you?" - -"If you say much, I will." - -"Much--much--MUCH. There now." - -"Oh, you think you're mighty smart, DON'T you? I could lick you with -one hand tied behind me, if I wanted to." - -"Well why don't you DO it? You SAY you can do it." - -"Well I WILL, if you fool with me." - -"Oh yes--I've seen whole families in the same fix." - -"Smarty! You think you're SOME, now, DON'T you? Oh, what a hat!" - -"You can lump that hat if you don't like it. I dare you to knock it -off--and anybody that'll take a dare will suck eggs." - -"You're a liar!" - -"You're another." - -"You're a fighting liar and dasn't take it up." - -"Aw--take a walk!" - -"Say--if you give me much more of your sass I'll take and bounce a -rock off'n your head." - -"Oh, of COURSE you will." - -"Well I WILL." - -"Well why don't you DO it then? What do you keep SAYING you will for? -Why don't you DO it? It's because you're afraid." - -"I AIN'T afraid." - -"You are." - -"I ain't." - -"You are." - -Another pause, and more eying and sidling around each other. Presently -they were shoulder to shoulder. Tom said: - -"Get away from here!" - -"Go away yourself!" - -"I won't." - -"I won't either." - -So they stood, each with a foot placed at an angle as a brace, and -both shoving with might and main, and glowering at each other with -hate. But neither could get an advantage. After struggling till both -were hot and flushed, each relaxed his strain with watchful caution, -and Tom said: - -"You're a coward and a pup. I'll tell my big brother on you, and he -can thrash you with his little finger, and I'll make him do it, too." - -"What do I care for your big brother? I've got a brother that's bigger -than he is--and what's more, he can throw him over that fence, too." -[Both brothers were imaginary.] - -"That's a lie." - -"YOUR saying so don't make it so." - -Tom drew a line in the dust with his big toe, and said: - -"I dare you to step over that, and I'll lick you till you can't stand -up. Anybody that'll take a dare will steal sheep." - -The new boy stepped over promptly, and said: - -"Now you said you'd do it, now let's see you do it." - -"Don't you crowd me now; you better look out." - -"Well, you SAID you'd do it--why don't you do it?" - -"By jingo! for two cents I WILL do it." - -The new boy took two broad coppers out of his pocket and held them out -with derision. Tom struck them to the ground. In an instant both boys -were rolling and tumbling in the dirt, gripped together like cats; and -for the space of a minute they tugged and tore at each other's hair and -clothes, punched and scratched each other's nose, and covered -themselves with dust and glory. Presently the confusion took form, and -through the fog of battle Tom appeared, seated astride the new boy, and -pounding him with his fists. "Holler 'nuff!" said he. - -The boy only struggled to free himself. He was crying--mainly from rage. - -"Holler 'nuff!"--and the pounding went on. - -At last the stranger got out a smothered "'Nuff!" and Tom let him up -and said: - -"Now that'll learn you. Better look out who you're fooling with next -time." - -The new boy went off brushing the dust from his clothes, sobbing, -snuffling, and occasionally looking back and shaking his head and -threatening what he would do to Tom the "next time he caught him out." -To which Tom responded with jeers, and started off in high feather, and -as soon as his back was turned the new boy snatched up a stone, threw -it and hit him between the shoulders and then turned tail and ran like -an antelope. Tom chased the traitor home, and thus found out where he -lived. He then held a position at the gate for some time, daring the -enemy to come outside, but the enemy only made faces at him through the -window and declined. At last the enemy's mother appeared, and called -Tom a bad, vicious, vulgar child, and ordered him away. So he went -away; but he said he "'lowed" to "lay" for that boy. - -He got home pretty late that night, and when he climbed cautiously in -at the window, he uncovered an ambuscade, in the person of his aunt; -and when she saw the state his clothes were in her resolution to turn -his Saturday holiday into captivity at hard labor became adamantine in -its firmness. diff --git a/vendor/github.com/golang/snappy/testdata/Mark.Twain-Tom.Sawyer.txt.rawsnappy b/vendor/github.com/golang/snappy/testdata/Mark.Twain-Tom.Sawyer.txt.rawsnappy deleted file mode 100644 index 9c56d98..0000000 Binary files a/vendor/github.com/golang/snappy/testdata/Mark.Twain-Tom.Sawyer.txt.rawsnappy and /dev/null differ diff --git a/vendor/github.com/dgryski/go-farm/.gitignore b/vendor/github.com/hashicorp/yamux/.gitignore similarity index 94% rename from vendor/github.com/dgryski/go-farm/.gitignore rename to vendor/github.com/hashicorp/yamux/.gitignore index 36029ab..8365624 100644 --- a/vendor/github.com/dgryski/go-farm/.gitignore +++ b/vendor/github.com/hashicorp/yamux/.gitignore @@ -17,8 +17,7 @@ _cgo_defun.c _cgo_gotypes.go _cgo_export.* +_testmain.go + *.exe *.test -*.prof - -target diff --git a/vendor/github.com/hashicorp/yamux/LICENSE b/vendor/github.com/hashicorp/yamux/LICENSE new file mode 100644 index 0000000..f0e5c79 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/LICENSE @@ -0,0 +1,362 @@ +Mozilla Public License, version 2.0 + +1. Definitions + +1.1. "Contributor" + + means each individual or legal entity that creates, contributes to the + creation of, or owns Covered Software. + +1.2. "Contributor Version" + + means the combination of the Contributions of others (if any) used by a + Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + + means Source Code Form to which the initial Contributor has attached the + notice in Exhibit A, the Executable Form of such Source Code Form, and + Modifications of such Source Code Form, in each case including portions + thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + a. that the initial Contributor has attached the notice described in + Exhibit B to the Covered Software; or + + b. that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the terms of + a Secondary License. + +1.6. "Executable Form" + + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + + means a work that combines Covered Software with other material, in a + separate file or files, that is not Covered Software. + +1.8. "License" + + means this document. + +1.9. "Licensable" + + means having the right to grant, to the maximum extent possible, whether + at the time of the initial grant or subsequently, any and all of the + rights conveyed by this License. + +1.10. "Modifications" + + means any of the following: + + a. any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered Software; or + + b. any new file in Source Code Form that contains any Covered Software. + +1.11. "Patent Claims" of a Contributor + + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the License, + by the making, using, selling, offering for sale, having made, import, + or transfer of either its Contributions or its Contributor Version. + +1.12. "Secondary License" + + means either the GNU General Public License, Version 2.0, the GNU Lesser + General Public License, Version 2.1, the GNU Affero General Public + License, Version 3.0, or any later versions of those licenses. + +1.13. "Source Code Form" + + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that controls, is + controlled by, or is under common control with You. For purposes of this + definition, "control" means (a) the power, direct or indirect, to cause + the direction or management of such entity, whether by contract or + otherwise, or (b) ownership of more than fifty percent (50%) of the + outstanding shares or beneficial ownership of such entity. + + +2. License Grants and Conditions + +2.1. Grants + + Each Contributor hereby grants You a world-wide, royalty-free, + non-exclusive license: + + a. under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + + b. under Patent Claims of such Contributor to make, use, sell, offer for + sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + + The licenses granted in Section 2.1 with respect to any Contribution + become effective for each Contribution on the date the Contributor first + distributes such Contribution. + +2.3. Limitations on Grant Scope + + The licenses granted in this Section 2 are the only rights granted under + this License. No additional rights or licenses will be implied from the + distribution or licensing of Covered Software under this License. + Notwithstanding Section 2.1(b) above, no patent license is granted by a + Contributor: + + a. for any code that a Contributor has removed from Covered Software; or + + b. for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + + c. under Patent Claims infringed by Covered Software in the absence of + its Contributions. + + This License does not grant any rights in the trademarks, service marks, + or logos of any Contributor (except as may be necessary to comply with + the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + + No Contributor makes additional grants as a result of Your choice to + distribute the Covered Software under a subsequent version of this + License (see Section 10.2) or under the terms of a Secondary License (if + permitted under the terms of Section 3.3). + +2.5. Representation + + Each Contributor represents that the Contributor believes its + Contributions are its original creation(s) or it has sufficient rights to + grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + + This License is not intended to limit any rights You have under + applicable copyright doctrines of fair use, fair dealing, or other + equivalents. + +2.7. Conditions + + Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted in + Section 2.1. + + +3. Responsibilities + +3.1. Distribution of Source Form + + All distribution of Covered Software in Source Code Form, including any + Modifications that You create or to which You contribute, must be under + the terms of this License. You must inform recipients that the Source + Code Form of the Covered Software is governed by the terms of this + License, and how they can obtain a copy of this License. You may not + attempt to alter or restrict the recipients' rights in the Source Code + Form. + +3.2. Distribution of Executable Form + + If You distribute Covered Software in Executable Form then: + + a. such Covered Software must also be made available in Source Code Form, + as described in Section 3.1, and You must inform recipients of the + Executable Form how they can obtain a copy of such Source Code Form by + reasonable means in a timely manner, at a charge no more than the cost + of distribution to the recipient; and + + b. You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter the + recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + + You may create and distribute a Larger Work under terms of Your choice, + provided that You also comply with the requirements of this License for + the Covered Software. If the Larger Work is a combination of Covered + Software with a work governed by one or more Secondary Licenses, and the + Covered Software is not Incompatible With Secondary Licenses, this + License permits You to additionally distribute such Covered Software + under the terms of such Secondary License(s), so that the recipient of + the Larger Work may, at their option, further distribute the Covered + Software under the terms of either this License or such Secondary + License(s). + +3.4. Notices + + You may not remove or alter the substance of any license notices + (including copyright notices, patent notices, disclaimers of warranty, or + limitations of liability) contained within the Source Code Form of the + Covered Software, except that You may alter any license notices to the + extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + + You may choose to offer, and to charge a fee for, warranty, support, + indemnity or liability obligations to one or more recipients of Covered + Software. However, You may do so only on Your own behalf, and not on + behalf of any Contributor. You must make it absolutely clear that any + such warranty, support, indemnity, or liability obligation is offered by + You alone, and You hereby agree to indemnify every Contributor for any + liability incurred by such Contributor as a result of warranty, support, + indemnity or liability terms You offer. You may include additional + disclaimers of warranty and limitations of liability specific to any + jurisdiction. + +4. Inability to Comply Due to Statute or Regulation + + If it is impossible for You to comply with any of the terms of this License + with respect to some or all of the Covered Software due to statute, + judicial order, or regulation then You must: (a) comply with the terms of + this License to the maximum extent possible; and (b) describe the + limitations and the code they affect. Such description must be placed in a + text file included with all distributions of the Covered Software under + this License. Except to the extent prohibited by statute or regulation, + such description must be sufficiently detailed for a recipient of ordinary + skill to be able to understand it. + +5. Termination + +5.1. The rights granted under this License will terminate automatically if You + fail to comply with any of its terms. However, if You become compliant, + then the rights granted under this License from a particular Contributor + are reinstated (a) provisionally, unless and until such Contributor + explicitly and finally terminates Your grants, and (b) on an ongoing + basis, if such Contributor fails to notify You of the non-compliance by + some reasonable means prior to 60 days after You have come back into + compliance. Moreover, Your grants from a particular Contributor are + reinstated on an ongoing basis if such Contributor notifies You of the + non-compliance by some reasonable means, this is the first time You have + received notice of non-compliance with this License from such + Contributor, and You become compliant prior to 30 days after Your receipt + of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent + infringement claim (excluding declaratory judgment actions, + counter-claims, and cross-claims) alleging that a Contributor Version + directly or indirectly infringes any patent, then the rights granted to + You by any and all Contributors for the Covered Software under Section + 2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all end user + license agreements (excluding distributors and resellers) which have been + validly granted by You or Your distributors under this License prior to + termination shall survive termination. + +6. Disclaimer of Warranty + + Covered Software is provided under this License on an "as is" basis, + without warranty of any kind, either expressed, implied, or statutory, + including, without limitation, warranties that the Covered Software is free + of defects, merchantable, fit for a particular purpose or non-infringing. + The entire risk as to the quality and performance of the Covered Software + is with You. Should any Covered Software prove defective in any respect, + You (not any Contributor) assume the cost of any necessary servicing, + repair, or correction. This disclaimer of warranty constitutes an essential + part of this License. No use of any Covered Software is authorized under + this License except under this disclaimer. + +7. Limitation of Liability + + Under no circumstances and under no legal theory, whether tort (including + negligence), contract, or otherwise, shall any Contributor, or anyone who + distributes Covered Software as permitted above, be liable to You for any + direct, indirect, special, incidental, or consequential damages of any + character including, without limitation, damages for lost profits, loss of + goodwill, work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses, even if such party shall have been + informed of the possibility of such damages. This limitation of liability + shall not apply to liability for death or personal injury resulting from + such party's negligence to the extent applicable law prohibits such + limitation. Some jurisdictions do not allow the exclusion or limitation of + incidental or consequential damages, so this exclusion and limitation may + not apply to You. + +8. Litigation + + Any litigation relating to this License may be brought only in the courts + of a jurisdiction where the defendant maintains its principal place of + business and such litigation shall be governed by laws of that + jurisdiction, without reference to its conflict-of-law provisions. Nothing + in this Section shall prevent a party's ability to bring cross-claims or + counter-claims. + +9. Miscellaneous + + This License represents the complete agreement concerning the subject + matter hereof. If any provision of this License is held to be + unenforceable, such provision shall be reformed only to the extent + necessary to make it enforceable. Any law or regulation which provides that + the language of a contract shall be construed against the drafter shall not + be used to construe this License against a Contributor. + + +10. Versions of the License + +10.1. New Versions + + Mozilla Foundation is the license steward. Except as provided in Section + 10.3, no one other than the license steward has the right to modify or + publish new versions of this License. Each version will be given a + distinguishing version number. + +10.2. Effect of New Versions + + You may distribute the Covered Software under the terms of the version + of the License under which You originally received the Covered Software, + or under the terms of any subsequent version published by the license + steward. + +10.3. Modified Versions + + If you create software not governed by this License, and you want to + create a new license for such software, you may create and use a + modified version of this License if you rename the license and remove + any references to the name of the license steward (except to note that + such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary + Licenses If You choose to distribute Source Code Form that is + Incompatible With Secondary Licenses under the terms of this version of + the License, the notice described in Exhibit B of this License must be + attached. + +Exhibit A - Source Code Form License Notice + + This Source Code Form is subject to the + terms of the Mozilla Public License, v. + 2.0. If a copy of the MPL was not + distributed with this file, You can + obtain one at + http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular file, +then You may include the notice in a location (such as a LICENSE file in a +relevant directory) where a recipient would be likely to look for such a +notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice + + This Source Code Form is "Incompatible + With Secondary Licenses", as defined by + the Mozilla Public License, v. 2.0. \ No newline at end of file diff --git a/vendor/github.com/hashicorp/yamux/README.md b/vendor/github.com/hashicorp/yamux/README.md new file mode 100644 index 0000000..d4db7fc --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/README.md @@ -0,0 +1,86 @@ +# Yamux + +Yamux (Yet another Multiplexer) is a multiplexing library for Golang. +It relies on an underlying connection to provide reliability +and ordering, such as TCP or Unix domain sockets, and provides +stream-oriented multiplexing. It is inspired by SPDY but is not +interoperable with it. + +Yamux features include: + +* Bi-directional streams + * Streams can be opened by either client or server + * Useful for NAT traversal + * Server-side push support +* Flow control + * Avoid starvation + * Back-pressure to prevent overwhelming a receiver +* Keep Alives + * Enables persistent connections over a load balancer +* Efficient + * Enables thousands of logical streams with low overhead + +## Documentation + +For complete documentation, see the associated [Godoc](http://godoc.org/github.com/hashicorp/yamux). + +## Specification + +The full specification for Yamux is provided in the `spec.md` file. +It can be used as a guide to implementors of interoperable libraries. + +## Usage + +Using Yamux is remarkably simple: + +```go + +func client() { + // Get a TCP connection + conn, err := net.Dial(...) + if err != nil { + panic(err) + } + + // Setup client side of yamux + session, err := yamux.Client(conn, nil) + if err != nil { + panic(err) + } + + // Open a new stream + stream, err := session.Open() + if err != nil { + panic(err) + } + + // Stream implements net.Conn + stream.Write([]byte("ping")) +} + +func server() { + // Accept a TCP connection + conn, err := listener.Accept() + if err != nil { + panic(err) + } + + // Setup server side of yamux + session, err := yamux.Server(conn, nil) + if err != nil { + panic(err) + } + + // Accept a stream + stream, err := session.Accept() + if err != nil { + panic(err) + } + + // Listen for a message + buf := make([]byte, 4) + stream.Read(buf) +} + +``` + diff --git a/vendor/github.com/hashicorp/yamux/addr.go b/vendor/github.com/hashicorp/yamux/addr.go new file mode 100644 index 0000000..f6a0019 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/addr.go @@ -0,0 +1,60 @@ +package yamux + +import ( + "fmt" + "net" +) + +// hasAddr is used to get the address from the underlying connection +type hasAddr interface { + LocalAddr() net.Addr + RemoteAddr() net.Addr +} + +// yamuxAddr is used when we cannot get the underlying address +type yamuxAddr struct { + Addr string +} + +func (*yamuxAddr) Network() string { + return "yamux" +} + +func (y *yamuxAddr) String() string { + return fmt.Sprintf("yamux:%s", y.Addr) +} + +// Addr is used to get the address of the listener. +func (s *Session) Addr() net.Addr { + return s.LocalAddr() +} + +// LocalAddr is used to get the local address of the +// underlying connection. +func (s *Session) LocalAddr() net.Addr { + addr, ok := s.conn.(hasAddr) + if !ok { + return &yamuxAddr{"local"} + } + return addr.LocalAddr() +} + +// RemoteAddr is used to get the address of remote end +// of the underlying connection +func (s *Session) RemoteAddr() net.Addr { + addr, ok := s.conn.(hasAddr) + if !ok { + return &yamuxAddr{"remote"} + } + return addr.RemoteAddr() +} + +// LocalAddr returns the local address +func (s *Stream) LocalAddr() net.Addr { + return s.session.LocalAddr() +} + +// RemoteAddr returns the remote address +func (s *Stream) RemoteAddr() net.Addr { + return s.session.RemoteAddr() +} diff --git a/vendor/github.com/hashicorp/yamux/bench_test.go b/vendor/github.com/hashicorp/yamux/bench_test.go new file mode 100644 index 0000000..d6b7348 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/bench_test.go @@ -0,0 +1,254 @@ +package yamux + +import ( + "io" + "io/ioutil" + "testing" +) + +func BenchmarkPing(b *testing.B) { + client, server := testClientServer() + defer func() { + client.Close() + server.Close() + }() + + b.ReportAllocs() + b.ResetTimer() + + for i := 0; i < b.N; i++ { + rtt, err := client.Ping() + if err != nil { + b.Fatalf("err: %v", err) + } + if rtt == 0 { + b.Fatalf("bad: %v", rtt) + } + } +} + +func BenchmarkAccept(b *testing.B) { + client, server := testClientServer() + defer func() { + client.Close() + server.Close() + }() + + doneCh := make(chan struct{}) + b.ReportAllocs() + b.ResetTimer() + + go func() { + defer close(doneCh) + + for i := 0; i < b.N; i++ { + stream, err := server.AcceptStream() + if err != nil { + return + } + stream.Close() + } + }() + + for i := 0; i < b.N; i++ { + stream, err := client.Open() + if err != nil { + b.Fatalf("err: %v", err) + } + stream.Close() + } + <-doneCh +} + +func BenchmarkSendRecv32(b *testing.B) { + const payloadSize = 32 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecv64(b *testing.B) { + const payloadSize = 64 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecv128(b *testing.B) { + const payloadSize = 128 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecv256(b *testing.B) { + const payloadSize = 256 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecv512(b *testing.B) { + const payloadSize = 512 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecv1024(b *testing.B) { + const payloadSize = 1024 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecv2048(b *testing.B) { + const payloadSize = 2048 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecv4096(b *testing.B) { + const payloadSize = 4096 + benchmarkSendRecv(b, payloadSize, payloadSize) +} + +func BenchmarkSendRecvLarge(b *testing.B) { + const sendSize = 512 * 1024 * 1024 //512 MB + const recvSize = 4 * 1024 //4 KB + benchmarkSendRecv(b, sendSize, recvSize) +} + +func benchmarkSendRecv(b *testing.B, sendSize, recvSize int) { + client, server := testClientServer() + defer func() { + client.Close() + server.Close() + }() + + sendBuf := make([]byte, sendSize) + recvBuf := make([]byte, recvSize) + doneCh := make(chan struct{}) + + b.SetBytes(int64(sendSize)) + b.ReportAllocs() + b.ResetTimer() + + go func() { + defer close(doneCh) + + stream, err := server.AcceptStream() + if err != nil { + return + } + defer stream.Close() + + switch { + case sendSize == recvSize: + for i := 0; i < b.N; i++ { + if _, err := stream.Read(recvBuf); err != nil { + b.Fatalf("err: %v", err) + } + } + + case recvSize > sendSize: + b.Fatalf("bad test case; recvSize was: %d and sendSize was: %d, but recvSize must be <= sendSize!", recvSize, sendSize) + + default: + chunks := sendSize / recvSize + for i := 0; i < b.N; i++ { + for j := 0; j < chunks; j++ { + if _, err := stream.Read(recvBuf); err != nil { + b.Fatalf("err: %v", err) + } + } + } + } + }() + + stream, err := client.Open() + if err != nil { + b.Fatalf("err: %v", err) + } + defer stream.Close() + + for i := 0; i < b.N; i++ { + if _, err := stream.Write(sendBuf); err != nil { + b.Fatalf("err: %v", err) + } + } + <-doneCh +} + +func BenchmarkSendRecvParallel32(b *testing.B) { + const payloadSize = 32 + benchmarkSendRecvParallel(b, payloadSize) +} + +func BenchmarkSendRecvParallel64(b *testing.B) { + const payloadSize = 64 + benchmarkSendRecvParallel(b, payloadSize) +} + +func BenchmarkSendRecvParallel128(b *testing.B) { + const payloadSize = 128 + benchmarkSendRecvParallel(b, payloadSize) +} + +func BenchmarkSendRecvParallel256(b *testing.B) { + const payloadSize = 256 + benchmarkSendRecvParallel(b, payloadSize) +} + +func BenchmarkSendRecvParallel512(b *testing.B) { + const payloadSize = 512 + benchmarkSendRecvParallel(b, payloadSize) +} + +func BenchmarkSendRecvParallel1024(b *testing.B) { + const payloadSize = 1024 + benchmarkSendRecvParallel(b, payloadSize) +} + +func BenchmarkSendRecvParallel2048(b *testing.B) { + const payloadSize = 2048 + benchmarkSendRecvParallel(b, payloadSize) +} + +func BenchmarkSendRecvParallel4096(b *testing.B) { + const payloadSize = 4096 + benchmarkSendRecvParallel(b, payloadSize) +} + +func benchmarkSendRecvParallel(b *testing.B, sendSize int) { + client, server := testClientServer() + defer func() { + client.Close() + server.Close() + }() + + sendBuf := make([]byte, sendSize) + discarder := ioutil.Discard.(io.ReaderFrom) + b.SetBytes(int64(sendSize)) + b.ReportAllocs() + b.ResetTimer() + + b.RunParallel(func(pb *testing.PB) { + doneCh := make(chan struct{}) + + go func() { + defer close(doneCh) + + stream, err := server.AcceptStream() + if err != nil { + return + } + defer stream.Close() + + if _, err := discarder.ReadFrom(stream); err != nil { + b.Fatalf("err: %v", err) + } + }() + + stream, err := client.Open() + if err != nil { + b.Fatalf("err: %v", err) + } + + for pb.Next() { + if _, err := stream.Write(sendBuf); err != nil { + b.Fatalf("err: %v", err) + } + } + + stream.Close() + <-doneCh + }) +} diff --git a/vendor/github.com/hashicorp/yamux/const.go b/vendor/github.com/hashicorp/yamux/const.go new file mode 100644 index 0000000..4f52938 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/const.go @@ -0,0 +1,157 @@ +package yamux + +import ( + "encoding/binary" + "fmt" +) + +var ( + // ErrInvalidVersion means we received a frame with an + // invalid version + ErrInvalidVersion = fmt.Errorf("invalid protocol version") + + // ErrInvalidMsgType means we received a frame with an + // invalid message type + ErrInvalidMsgType = fmt.Errorf("invalid msg type") + + // ErrSessionShutdown is used if there is a shutdown during + // an operation + ErrSessionShutdown = fmt.Errorf("session shutdown") + + // ErrStreamsExhausted is returned if we have no more + // stream ids to issue + ErrStreamsExhausted = fmt.Errorf("streams exhausted") + + // ErrDuplicateStream is used if a duplicate stream is + // opened inbound + ErrDuplicateStream = fmt.Errorf("duplicate stream initiated") + + // ErrReceiveWindowExceeded indicates the window was exceeded + ErrRecvWindowExceeded = fmt.Errorf("recv window exceeded") + + // ErrTimeout is used when we reach an IO deadline + ErrTimeout = fmt.Errorf("i/o deadline reached") + + // ErrStreamClosed is returned when using a closed stream + ErrStreamClosed = fmt.Errorf("stream closed") + + // ErrUnexpectedFlag is set when we get an unexpected flag + ErrUnexpectedFlag = fmt.Errorf("unexpected flag") + + // ErrRemoteGoAway is used when we get a go away from the other side + ErrRemoteGoAway = fmt.Errorf("remote end is not accepting connections") + + // ErrConnectionReset is sent if a stream is reset. This can happen + // if the backlog is exceeded, or if there was a remote GoAway. + ErrConnectionReset = fmt.Errorf("connection reset") + + // ErrConnectionWriteTimeout indicates that we hit the "safety valve" + // timeout writing to the underlying stream connection. + ErrConnectionWriteTimeout = fmt.Errorf("connection write timeout") + + // ErrKeepAliveTimeout is sent if a missed keepalive caused the stream close + ErrKeepAliveTimeout = fmt.Errorf("keepalive timeout") +) + +const ( + // protoVersion is the only version we support + protoVersion uint8 = 0 +) + +const ( + // Data is used for data frames. They are followed + // by length bytes worth of payload. + typeData uint8 = iota + + // WindowUpdate is used to change the window of + // a given stream. The length indicates the delta + // update to the window. + typeWindowUpdate + + // Ping is sent as a keep-alive or to measure + // the RTT. The StreamID and Length value are echoed + // back in the response. + typePing + + // GoAway is sent to terminate a session. The StreamID + // should be 0 and the length is an error code. + typeGoAway +) + +const ( + // SYN is sent to signal a new stream. May + // be sent with a data payload + flagSYN uint16 = 1 << iota + + // ACK is sent to acknowledge a new stream. May + // be sent with a data payload + flagACK + + // FIN is sent to half-close the given stream. + // May be sent with a data payload. + flagFIN + + // RST is used to hard close a given stream. + flagRST +) + +const ( + // initialStreamWindow is the initial stream window size + initialStreamWindow uint32 = 256 * 1024 +) + +const ( + // goAwayNormal is sent on a normal termination + goAwayNormal uint32 = iota + + // goAwayProtoErr sent on a protocol error + goAwayProtoErr + + // goAwayInternalErr sent on an internal error + goAwayInternalErr +) + +const ( + sizeOfVersion = 1 + sizeOfType = 1 + sizeOfFlags = 2 + sizeOfStreamID = 4 + sizeOfLength = 4 + headerSize = sizeOfVersion + sizeOfType + sizeOfFlags + + sizeOfStreamID + sizeOfLength +) + +type header []byte + +func (h header) Version() uint8 { + return h[0] +} + +func (h header) MsgType() uint8 { + return h[1] +} + +func (h header) Flags() uint16 { + return binary.BigEndian.Uint16(h[2:4]) +} + +func (h header) StreamID() uint32 { + return binary.BigEndian.Uint32(h[4:8]) +} + +func (h header) Length() uint32 { + return binary.BigEndian.Uint32(h[8:12]) +} + +func (h header) String() string { + return fmt.Sprintf("Vsn:%d Type:%d Flags:%d StreamID:%d Length:%d", + h.Version(), h.MsgType(), h.Flags(), h.StreamID(), h.Length()) +} + +func (h header) encode(msgType uint8, flags uint16, streamID uint32, length uint32) { + h[0] = protoVersion + h[1] = msgType + binary.BigEndian.PutUint16(h[2:4], flags) + binary.BigEndian.PutUint32(h[4:8], streamID) + binary.BigEndian.PutUint32(h[8:12], length) +} diff --git a/vendor/github.com/hashicorp/yamux/const_test.go b/vendor/github.com/hashicorp/yamux/const_test.go new file mode 100644 index 0000000..153da18 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/const_test.go @@ -0,0 +1,72 @@ +package yamux + +import ( + "testing" +) + +func TestConst(t *testing.T) { + if protoVersion != 0 { + t.Fatalf("bad: %v", protoVersion) + } + + if typeData != 0 { + t.Fatalf("bad: %v", typeData) + } + if typeWindowUpdate != 1 { + t.Fatalf("bad: %v", typeWindowUpdate) + } + if typePing != 2 { + t.Fatalf("bad: %v", typePing) + } + if typeGoAway != 3 { + t.Fatalf("bad: %v", typeGoAway) + } + + if flagSYN != 1 { + t.Fatalf("bad: %v", flagSYN) + } + if flagACK != 2 { + t.Fatalf("bad: %v", flagACK) + } + if flagFIN != 4 { + t.Fatalf("bad: %v", flagFIN) + } + if flagRST != 8 { + t.Fatalf("bad: %v", flagRST) + } + + if goAwayNormal != 0 { + t.Fatalf("bad: %v", goAwayNormal) + } + if goAwayProtoErr != 1 { + t.Fatalf("bad: %v", goAwayProtoErr) + } + if goAwayInternalErr != 2 { + t.Fatalf("bad: %v", goAwayInternalErr) + } + + if headerSize != 12 { + t.Fatalf("bad header size") + } +} + +func TestEncodeDecode(t *testing.T) { + hdr := header(make([]byte, headerSize)) + hdr.encode(typeWindowUpdate, flagACK|flagRST, 1234, 4321) + + if hdr.Version() != protoVersion { + t.Fatalf("bad: %v", hdr) + } + if hdr.MsgType() != typeWindowUpdate { + t.Fatalf("bad: %v", hdr) + } + if hdr.Flags() != flagACK|flagRST { + t.Fatalf("bad: %v", hdr) + } + if hdr.StreamID() != 1234 { + t.Fatalf("bad: %v", hdr) + } + if hdr.Length() != 4321 { + t.Fatalf("bad: %v", hdr) + } +} diff --git a/vendor/github.com/hashicorp/yamux/go.mod b/vendor/github.com/hashicorp/yamux/go.mod new file mode 100644 index 0000000..672a0e5 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/go.mod @@ -0,0 +1 @@ +module github.com/hashicorp/yamux diff --git a/vendor/github.com/hashicorp/yamux/mux.go b/vendor/github.com/hashicorp/yamux/mux.go new file mode 100644 index 0000000..18a078c --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/mux.go @@ -0,0 +1,98 @@ +package yamux + +import ( + "fmt" + "io" + "log" + "os" + "time" +) + +// Config is used to tune the Yamux session +type Config struct { + // AcceptBacklog is used to limit how many streams may be + // waiting an accept. + AcceptBacklog int + + // EnableKeepalive is used to do a period keep alive + // messages using a ping. + EnableKeepAlive bool + + // KeepAliveInterval is how often to perform the keep alive + KeepAliveInterval time.Duration + + // ConnectionWriteTimeout is meant to be a "safety valve" timeout after + // we which will suspect a problem with the underlying connection and + // close it. This is only applied to writes, where's there's generally + // an expectation that things will move along quickly. + ConnectionWriteTimeout time.Duration + + // MaxStreamWindowSize is used to control the maximum + // window size that we allow for a stream. + MaxStreamWindowSize uint32 + + // LogOutput is used to control the log destination. Either Logger or + // LogOutput can be set, not both. + LogOutput io.Writer + + // Logger is used to pass in the logger to be used. Either Logger or + // LogOutput can be set, not both. + Logger *log.Logger +} + +// DefaultConfig is used to return a default configuration +func DefaultConfig() *Config { + return &Config{ + AcceptBacklog: 256, + EnableKeepAlive: true, + KeepAliveInterval: 30 * time.Second, + ConnectionWriteTimeout: 10 * time.Second, + MaxStreamWindowSize: initialStreamWindow, + LogOutput: os.Stderr, + } +} + +// VerifyConfig is used to verify the sanity of configuration +func VerifyConfig(config *Config) error { + if config.AcceptBacklog <= 0 { + return fmt.Errorf("backlog must be positive") + } + if config.KeepAliveInterval == 0 { + return fmt.Errorf("keep-alive interval must be positive") + } + if config.MaxStreamWindowSize < initialStreamWindow { + return fmt.Errorf("MaxStreamWindowSize must be larger than %d", initialStreamWindow) + } + if config.LogOutput != nil && config.Logger != nil { + return fmt.Errorf("both Logger and LogOutput may not be set, select one") + } else if config.LogOutput == nil && config.Logger == nil { + return fmt.Errorf("one of Logger or LogOutput must be set, select one") + } + return nil +} + +// Server is used to initialize a new server-side connection. +// There must be at most one server-side connection. If a nil config is +// provided, the DefaultConfiguration will be used. +func Server(conn io.ReadWriteCloser, config *Config) (*Session, error) { + if config == nil { + config = DefaultConfig() + } + if err := VerifyConfig(config); err != nil { + return nil, err + } + return newSession(config, conn, false), nil +} + +// Client is used to initialize a new client-side connection. +// There must be at most one client-side connection. +func Client(conn io.ReadWriteCloser, config *Config) (*Session, error) { + if config == nil { + config = DefaultConfig() + } + + if err := VerifyConfig(config); err != nil { + return nil, err + } + return newSession(config, conn, true), nil +} diff --git a/vendor/github.com/hashicorp/yamux/session.go b/vendor/github.com/hashicorp/yamux/session.go new file mode 100644 index 0000000..a80ddec --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/session.go @@ -0,0 +1,653 @@ +package yamux + +import ( + "bufio" + "fmt" + "io" + "io/ioutil" + "log" + "math" + "net" + "strings" + "sync" + "sync/atomic" + "time" +) + +// Session is used to wrap a reliable ordered connection and to +// multiplex it into multiple streams. +type Session struct { + // remoteGoAway indicates the remote side does + // not want futher connections. Must be first for alignment. + remoteGoAway int32 + + // localGoAway indicates that we should stop + // accepting futher connections. Must be first for alignment. + localGoAway int32 + + // nextStreamID is the next stream we should + // send. This depends if we are a client/server. + nextStreamID uint32 + + // config holds our configuration + config *Config + + // logger is used for our logs + logger *log.Logger + + // conn is the underlying connection + conn io.ReadWriteCloser + + // bufRead is a buffered reader + bufRead *bufio.Reader + + // pings is used to track inflight pings + pings map[uint32]chan struct{} + pingID uint32 + pingLock sync.Mutex + + // streams maps a stream id to a stream, and inflight has an entry + // for any outgoing stream that has not yet been established. Both are + // protected by streamLock. + streams map[uint32]*Stream + inflight map[uint32]struct{} + streamLock sync.Mutex + + // synCh acts like a semaphore. It is sized to the AcceptBacklog which + // is assumed to be symmetric between the client and server. This allows + // the client to avoid exceeding the backlog and instead blocks the open. + synCh chan struct{} + + // acceptCh is used to pass ready streams to the client + acceptCh chan *Stream + + // sendCh is used to mark a stream as ready to send, + // or to send a header out directly. + sendCh chan sendReady + + // recvDoneCh is closed when recv() exits to avoid a race + // between stream registration and stream shutdown + recvDoneCh chan struct{} + + // shutdown is used to safely close a session + shutdown bool + shutdownErr error + shutdownCh chan struct{} + shutdownLock sync.Mutex +} + +// sendReady is used to either mark a stream as ready +// or to directly send a header +type sendReady struct { + Hdr []byte + Body io.Reader + Err chan error +} + +// newSession is used to construct a new session +func newSession(config *Config, conn io.ReadWriteCloser, client bool) *Session { + logger := config.Logger + if logger == nil { + logger = log.New(config.LogOutput, "", log.LstdFlags) + } + + s := &Session{ + config: config, + logger: logger, + conn: conn, + bufRead: bufio.NewReader(conn), + pings: make(map[uint32]chan struct{}), + streams: make(map[uint32]*Stream), + inflight: make(map[uint32]struct{}), + synCh: make(chan struct{}, config.AcceptBacklog), + acceptCh: make(chan *Stream, config.AcceptBacklog), + sendCh: make(chan sendReady, 64), + recvDoneCh: make(chan struct{}), + shutdownCh: make(chan struct{}), + } + if client { + s.nextStreamID = 1 + } else { + s.nextStreamID = 2 + } + go s.recv() + go s.send() + if config.EnableKeepAlive { + go s.keepalive() + } + return s +} + +// IsClosed does a safe check to see if we have shutdown +func (s *Session) IsClosed() bool { + select { + case <-s.shutdownCh: + return true + default: + return false + } +} + +// CloseChan returns a read-only channel which is closed as +// soon as the session is closed. +func (s *Session) CloseChan() <-chan struct{} { + return s.shutdownCh +} + +// NumStreams returns the number of currently open streams +func (s *Session) NumStreams() int { + s.streamLock.Lock() + num := len(s.streams) + s.streamLock.Unlock() + return num +} + +// Open is used to create a new stream as a net.Conn +func (s *Session) Open() (net.Conn, error) { + conn, err := s.OpenStream() + if err != nil { + return nil, err + } + return conn, nil +} + +// OpenStream is used to create a new stream +func (s *Session) OpenStream() (*Stream, error) { + if s.IsClosed() { + return nil, ErrSessionShutdown + } + if atomic.LoadInt32(&s.remoteGoAway) == 1 { + return nil, ErrRemoteGoAway + } + + // Block if we have too many inflight SYNs + select { + case s.synCh <- struct{}{}: + case <-s.shutdownCh: + return nil, ErrSessionShutdown + } + +GET_ID: + // Get an ID, and check for stream exhaustion + id := atomic.LoadUint32(&s.nextStreamID) + if id >= math.MaxUint32-1 { + return nil, ErrStreamsExhausted + } + if !atomic.CompareAndSwapUint32(&s.nextStreamID, id, id+2) { + goto GET_ID + } + + // Register the stream + stream := newStream(s, id, streamInit) + s.streamLock.Lock() + s.streams[id] = stream + s.inflight[id] = struct{}{} + s.streamLock.Unlock() + + // Send the window update to create + if err := stream.sendWindowUpdate(); err != nil { + select { + case <-s.synCh: + default: + s.logger.Printf("[ERR] yamux: aborted stream open without inflight syn semaphore") + } + return nil, err + } + return stream, nil +} + +// Accept is used to block until the next available stream +// is ready to be accepted. +func (s *Session) Accept() (net.Conn, error) { + conn, err := s.AcceptStream() + if err != nil { + return nil, err + } + return conn, err +} + +// AcceptStream is used to block until the next available stream +// is ready to be accepted. +func (s *Session) AcceptStream() (*Stream, error) { + select { + case stream := <-s.acceptCh: + if err := stream.sendWindowUpdate(); err != nil { + return nil, err + } + return stream, nil + case <-s.shutdownCh: + return nil, s.shutdownErr + } +} + +// Close is used to close the session and all streams. +// Attempts to send a GoAway before closing the connection. +func (s *Session) Close() error { + s.shutdownLock.Lock() + defer s.shutdownLock.Unlock() + + if s.shutdown { + return nil + } + s.shutdown = true + if s.shutdownErr == nil { + s.shutdownErr = ErrSessionShutdown + } + close(s.shutdownCh) + s.conn.Close() + <-s.recvDoneCh + + s.streamLock.Lock() + defer s.streamLock.Unlock() + for _, stream := range s.streams { + stream.forceClose() + } + return nil +} + +// exitErr is used to handle an error that is causing the +// session to terminate. +func (s *Session) exitErr(err error) { + s.shutdownLock.Lock() + if s.shutdownErr == nil { + s.shutdownErr = err + } + s.shutdownLock.Unlock() + s.Close() +} + +// GoAway can be used to prevent accepting further +// connections. It does not close the underlying conn. +func (s *Session) GoAway() error { + return s.waitForSend(s.goAway(goAwayNormal), nil) +} + +// goAway is used to send a goAway message +func (s *Session) goAway(reason uint32) header { + atomic.SwapInt32(&s.localGoAway, 1) + hdr := header(make([]byte, headerSize)) + hdr.encode(typeGoAway, 0, 0, reason) + return hdr +} + +// Ping is used to measure the RTT response time +func (s *Session) Ping() (time.Duration, error) { + // Get a channel for the ping + ch := make(chan struct{}) + + // Get a new ping id, mark as pending + s.pingLock.Lock() + id := s.pingID + s.pingID++ + s.pings[id] = ch + s.pingLock.Unlock() + + // Send the ping request + hdr := header(make([]byte, headerSize)) + hdr.encode(typePing, flagSYN, 0, id) + if err := s.waitForSend(hdr, nil); err != nil { + return 0, err + } + + // Wait for a response + start := time.Now() + select { + case <-ch: + case <-time.After(s.config.ConnectionWriteTimeout): + s.pingLock.Lock() + delete(s.pings, id) // Ignore it if a response comes later. + s.pingLock.Unlock() + return 0, ErrTimeout + case <-s.shutdownCh: + return 0, ErrSessionShutdown + } + + // Compute the RTT + return time.Now().Sub(start), nil +} + +// keepalive is a long running goroutine that periodically does +// a ping to keep the connection alive. +func (s *Session) keepalive() { + for { + select { + case <-time.After(s.config.KeepAliveInterval): + _, err := s.Ping() + if err != nil { + if err != ErrSessionShutdown { + s.logger.Printf("[ERR] yamux: keepalive failed: %v", err) + s.exitErr(ErrKeepAliveTimeout) + } + return + } + case <-s.shutdownCh: + return + } + } +} + +// waitForSendErr waits to send a header, checking for a potential shutdown +func (s *Session) waitForSend(hdr header, body io.Reader) error { + errCh := make(chan error, 1) + return s.waitForSendErr(hdr, body, errCh) +} + +// waitForSendErr waits to send a header with optional data, checking for a +// potential shutdown. Since there's the expectation that sends can happen +// in a timely manner, we enforce the connection write timeout here. +func (s *Session) waitForSendErr(hdr header, body io.Reader, errCh chan error) error { + t := timerPool.Get() + timer := t.(*time.Timer) + timer.Reset(s.config.ConnectionWriteTimeout) + defer func() { + timer.Stop() + select { + case <-timer.C: + default: + } + timerPool.Put(t) + }() + + ready := sendReady{Hdr: hdr, Body: body, Err: errCh} + select { + case s.sendCh <- ready: + case <-s.shutdownCh: + return ErrSessionShutdown + case <-timer.C: + return ErrConnectionWriteTimeout + } + + select { + case err := <-errCh: + return err + case <-s.shutdownCh: + return ErrSessionShutdown + case <-timer.C: + return ErrConnectionWriteTimeout + } +} + +// sendNoWait does a send without waiting. Since there's the expectation that +// the send happens right here, we enforce the connection write timeout if we +// can't queue the header to be sent. +func (s *Session) sendNoWait(hdr header) error { + t := timerPool.Get() + timer := t.(*time.Timer) + timer.Reset(s.config.ConnectionWriteTimeout) + defer func() { + timer.Stop() + select { + case <-timer.C: + default: + } + timerPool.Put(t) + }() + + select { + case s.sendCh <- sendReady{Hdr: hdr}: + return nil + case <-s.shutdownCh: + return ErrSessionShutdown + case <-timer.C: + return ErrConnectionWriteTimeout + } +} + +// send is a long running goroutine that sends data +func (s *Session) send() { + for { + select { + case ready := <-s.sendCh: + // Send a header if ready + if ready.Hdr != nil { + sent := 0 + for sent < len(ready.Hdr) { + n, err := s.conn.Write(ready.Hdr[sent:]) + if err != nil { + s.logger.Printf("[ERR] yamux: Failed to write header: %v", err) + asyncSendErr(ready.Err, err) + s.exitErr(err) + return + } + sent += n + } + } + + // Send data from a body if given + if ready.Body != nil { + _, err := io.Copy(s.conn, ready.Body) + if err != nil { + s.logger.Printf("[ERR] yamux: Failed to write body: %v", err) + asyncSendErr(ready.Err, err) + s.exitErr(err) + return + } + } + + // No error, successful send + asyncSendErr(ready.Err, nil) + case <-s.shutdownCh: + return + } + } +} + +// recv is a long running goroutine that accepts new data +func (s *Session) recv() { + if err := s.recvLoop(); err != nil { + s.exitErr(err) + } +} + +// Ensure that the index of the handler (typeData/typeWindowUpdate/etc) matches the message type +var ( + handlers = []func(*Session, header) error{ + typeData: (*Session).handleStreamMessage, + typeWindowUpdate: (*Session).handleStreamMessage, + typePing: (*Session).handlePing, + typeGoAway: (*Session).handleGoAway, + } +) + +// recvLoop continues to receive data until a fatal error is encountered +func (s *Session) recvLoop() error { + defer close(s.recvDoneCh) + hdr := header(make([]byte, headerSize)) + for { + // Read the header + if _, err := io.ReadFull(s.bufRead, hdr); err != nil { + if err != io.EOF && !strings.Contains(err.Error(), "closed") && !strings.Contains(err.Error(), "reset by peer") { + s.logger.Printf("[ERR] yamux: Failed to read header: %v", err) + } + return err + } + + // Verify the version + if hdr.Version() != protoVersion { + s.logger.Printf("[ERR] yamux: Invalid protocol version: %d", hdr.Version()) + return ErrInvalidVersion + } + + mt := hdr.MsgType() + if mt < typeData || mt > typeGoAway { + return ErrInvalidMsgType + } + + if err := handlers[mt](s, hdr); err != nil { + return err + } + } +} + +// handleStreamMessage handles either a data or window update frame +func (s *Session) handleStreamMessage(hdr header) error { + // Check for a new stream creation + id := hdr.StreamID() + flags := hdr.Flags() + if flags&flagSYN == flagSYN { + if err := s.incomingStream(id); err != nil { + return err + } + } + + // Get the stream + s.streamLock.Lock() + stream := s.streams[id] + s.streamLock.Unlock() + + // If we do not have a stream, likely we sent a RST + if stream == nil { + // Drain any data on the wire + if hdr.MsgType() == typeData && hdr.Length() > 0 { + s.logger.Printf("[WARN] yamux: Discarding data for stream: %d", id) + if _, err := io.CopyN(ioutil.Discard, s.bufRead, int64(hdr.Length())); err != nil { + s.logger.Printf("[ERR] yamux: Failed to discard data: %v", err) + return nil + } + } else { + s.logger.Printf("[WARN] yamux: frame for missing stream: %v", hdr) + } + return nil + } + + // Check if this is a window update + if hdr.MsgType() == typeWindowUpdate { + if err := stream.incrSendWindow(hdr, flags); err != nil { + if sendErr := s.sendNoWait(s.goAway(goAwayProtoErr)); sendErr != nil { + s.logger.Printf("[WARN] yamux: failed to send go away: %v", sendErr) + } + return err + } + return nil + } + + // Read the new data + if err := stream.readData(hdr, flags, s.bufRead); err != nil { + if sendErr := s.sendNoWait(s.goAway(goAwayProtoErr)); sendErr != nil { + s.logger.Printf("[WARN] yamux: failed to send go away: %v", sendErr) + } + return err + } + return nil +} + +// handlePing is invokde for a typePing frame +func (s *Session) handlePing(hdr header) error { + flags := hdr.Flags() + pingID := hdr.Length() + + // Check if this is a query, respond back in a separate context so we + // don't interfere with the receiving thread blocking for the write. + if flags&flagSYN == flagSYN { + go func() { + hdr := header(make([]byte, headerSize)) + hdr.encode(typePing, flagACK, 0, pingID) + if err := s.sendNoWait(hdr); err != nil { + s.logger.Printf("[WARN] yamux: failed to send ping reply: %v", err) + } + }() + return nil + } + + // Handle a response + s.pingLock.Lock() + ch := s.pings[pingID] + if ch != nil { + delete(s.pings, pingID) + close(ch) + } + s.pingLock.Unlock() + return nil +} + +// handleGoAway is invokde for a typeGoAway frame +func (s *Session) handleGoAway(hdr header) error { + code := hdr.Length() + switch code { + case goAwayNormal: + atomic.SwapInt32(&s.remoteGoAway, 1) + case goAwayProtoErr: + s.logger.Printf("[ERR] yamux: received protocol error go away") + return fmt.Errorf("yamux protocol error") + case goAwayInternalErr: + s.logger.Printf("[ERR] yamux: received internal error go away") + return fmt.Errorf("remote yamux internal error") + default: + s.logger.Printf("[ERR] yamux: received unexpected go away") + return fmt.Errorf("unexpected go away received") + } + return nil +} + +// incomingStream is used to create a new incoming stream +func (s *Session) incomingStream(id uint32) error { + // Reject immediately if we are doing a go away + if atomic.LoadInt32(&s.localGoAway) == 1 { + hdr := header(make([]byte, headerSize)) + hdr.encode(typeWindowUpdate, flagRST, id, 0) + return s.sendNoWait(hdr) + } + + // Allocate a new stream + stream := newStream(s, id, streamSYNReceived) + + s.streamLock.Lock() + defer s.streamLock.Unlock() + + // Check if stream already exists + if _, ok := s.streams[id]; ok { + s.logger.Printf("[ERR] yamux: duplicate stream declared") + if sendErr := s.sendNoWait(s.goAway(goAwayProtoErr)); sendErr != nil { + s.logger.Printf("[WARN] yamux: failed to send go away: %v", sendErr) + } + return ErrDuplicateStream + } + + // Register the stream + s.streams[id] = stream + + // Check if we've exceeded the backlog + select { + case s.acceptCh <- stream: + return nil + default: + // Backlog exceeded! RST the stream + s.logger.Printf("[WARN] yamux: backlog exceeded, forcing connection reset") + delete(s.streams, id) + stream.sendHdr.encode(typeWindowUpdate, flagRST, id, 0) + return s.sendNoWait(stream.sendHdr) + } +} + +// closeStream is used to close a stream once both sides have +// issued a close. If there was an in-flight SYN and the stream +// was not yet established, then this will give the credit back. +func (s *Session) closeStream(id uint32) { + s.streamLock.Lock() + if _, ok := s.inflight[id]; ok { + select { + case <-s.synCh: + default: + s.logger.Printf("[ERR] yamux: SYN tracking out of sync") + } + } + delete(s.streams, id) + s.streamLock.Unlock() +} + +// establishStream is used to mark a stream that was in the +// SYN Sent state as established. +func (s *Session) establishStream(id uint32) { + s.streamLock.Lock() + if _, ok := s.inflight[id]; ok { + delete(s.inflight, id) + } else { + s.logger.Printf("[ERR] yamux: established stream without inflight SYN (no tracking entry)") + } + select { + case <-s.synCh: + default: + s.logger.Printf("[ERR] yamux: established stream without inflight SYN (didn't have semaphore)") + } + s.streamLock.Unlock() +} diff --git a/vendor/github.com/hashicorp/yamux/session_test.go b/vendor/github.com/hashicorp/yamux/session_test.go new file mode 100644 index 0000000..4bbdfde --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/session_test.go @@ -0,0 +1,1353 @@ +package yamux + +import ( + "bytes" + "fmt" + "io" + "io/ioutil" + "log" + "reflect" + "runtime" + "strings" + "sync" + "testing" + "time" +) + +type logCapture struct{ bytes.Buffer } + +func (l *logCapture) logs() []string { + return strings.Split(strings.TrimSpace(l.String()), "\n") +} + +func (l *logCapture) match(expect []string) bool { + return reflect.DeepEqual(l.logs(), expect) +} + +func captureLogs(s *Session) *logCapture { + buf := new(logCapture) + s.logger = log.New(buf, "", 0) + return buf +} + +type pipeConn struct { + reader *io.PipeReader + writer *io.PipeWriter + writeBlocker sync.Mutex +} + +func (p *pipeConn) Read(b []byte) (int, error) { + return p.reader.Read(b) +} + +func (p *pipeConn) Write(b []byte) (int, error) { + p.writeBlocker.Lock() + defer p.writeBlocker.Unlock() + return p.writer.Write(b) +} + +func (p *pipeConn) Close() error { + p.reader.Close() + return p.writer.Close() +} + +func testConn() (io.ReadWriteCloser, io.ReadWriteCloser) { + read1, write1 := io.Pipe() + read2, write2 := io.Pipe() + conn1 := &pipeConn{reader: read1, writer: write2} + conn2 := &pipeConn{reader: read2, writer: write1} + return conn1, conn2 +} + +func testConf() *Config { + conf := DefaultConfig() + conf.AcceptBacklog = 64 + conf.KeepAliveInterval = 100 * time.Millisecond + conf.ConnectionWriteTimeout = 250 * time.Millisecond + return conf +} + +func testConfNoKeepAlive() *Config { + conf := testConf() + conf.EnableKeepAlive = false + return conf +} + +func testClientServer() (*Session, *Session) { + return testClientServerConfig(testConf()) +} + +func testClientServerConfig(conf *Config) (*Session, *Session) { + conn1, conn2 := testConn() + client, _ := Client(conn1, conf) + server, _ := Server(conn2, conf) + return client, server +} + +func TestPing(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + rtt, err := client.Ping() + if err != nil { + t.Fatalf("err: %v", err) + } + if rtt == 0 { + t.Fatalf("bad: %v", rtt) + } + + rtt, err = server.Ping() + if err != nil { + t.Fatalf("err: %v", err) + } + if rtt == 0 { + t.Fatalf("bad: %v", rtt) + } +} + +func TestPing_Timeout(t *testing.T) { + client, server := testClientServerConfig(testConfNoKeepAlive()) + defer client.Close() + defer server.Close() + + // Prevent the client from responding + clientConn := client.conn.(*pipeConn) + clientConn.writeBlocker.Lock() + + errCh := make(chan error, 1) + go func() { + _, err := server.Ping() // Ping via the server session + errCh <- err + }() + + select { + case err := <-errCh: + if err != ErrTimeout { + t.Fatalf("err: %v", err) + } + case <-time.After(client.config.ConnectionWriteTimeout * 2): + t.Fatalf("failed to timeout within expected %v", client.config.ConnectionWriteTimeout) + } + + // Verify that we recover, even if we gave up + clientConn.writeBlocker.Unlock() + + go func() { + _, err := server.Ping() // Ping via the server session + errCh <- err + }() + + select { + case err := <-errCh: + if err != nil { + t.Fatalf("err: %v", err) + } + case <-time.After(client.config.ConnectionWriteTimeout): + t.Fatalf("timeout") + } +} + +func TestCloseBeforeAck(t *testing.T) { + cfg := testConf() + cfg.AcceptBacklog = 8 + client, server := testClientServerConfig(cfg) + + defer client.Close() + defer server.Close() + + for i := 0; i < 8; i++ { + s, err := client.OpenStream() + if err != nil { + t.Fatal(err) + } + s.Close() + } + + for i := 0; i < 8; i++ { + s, err := server.AcceptStream() + if err != nil { + t.Fatal(err) + } + s.Close() + } + + done := make(chan struct{}) + go func() { + defer close(done) + s, err := client.OpenStream() + if err != nil { + t.Fatal(err) + } + s.Close() + }() + + select { + case <-done: + case <-time.After(time.Second * 5): + t.Fatal("timed out trying to open stream") + } +} + +func TestAccept(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + if client.NumStreams() != 0 { + t.Fatalf("bad") + } + if server.NumStreams() != 0 { + t.Fatalf("bad") + } + + wg := &sync.WaitGroup{} + wg.Add(4) + + go func() { + defer wg.Done() + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + if id := stream.StreamID(); id != 1 { + t.Fatalf("bad: %v", id) + } + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + go func() { + defer wg.Done() + stream, err := client.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + if id := stream.StreamID(); id != 2 { + t.Fatalf("bad: %v", id) + } + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + go func() { + defer wg.Done() + stream, err := server.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + if id := stream.StreamID(); id != 2 { + t.Fatalf("bad: %v", id) + } + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + go func() { + defer wg.Done() + stream, err := client.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + if id := stream.StreamID(); id != 1 { + t.Fatalf("bad: %v", id) + } + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + doneCh := make(chan struct{}) + go func() { + wg.Wait() + close(doneCh) + }() + + select { + case <-doneCh: + case <-time.After(time.Second): + panic("timeout") + } +} + +func TestNonNilInterface(t *testing.T) { + _, server := testClientServer() + server.Close() + + conn, err := server.Accept() + if err != nil && conn != nil { + t.Error("bad: accept should return a connection of nil value") + } + + conn, err = server.Open() + if err != nil && conn != nil { + t.Error("bad: open should return a connection of nil value") + } +} + +func TestSendData_Small(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + wg := &sync.WaitGroup{} + wg.Add(2) + + go func() { + defer wg.Done() + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + + if server.NumStreams() != 1 { + t.Fatalf("bad") + } + + buf := make([]byte, 4) + for i := 0; i < 1000; i++ { + n, err := stream.Read(buf) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 4 { + t.Fatalf("short read: %d", n) + } + if string(buf) != "test" { + t.Fatalf("bad: %s", buf) + } + } + + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + go func() { + defer wg.Done() + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + + if client.NumStreams() != 1 { + t.Fatalf("bad") + } + + for i := 0; i < 1000; i++ { + n, err := stream.Write([]byte("test")) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 4 { + t.Fatalf("short write %d", n) + } + } + + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + doneCh := make(chan struct{}) + go func() { + wg.Wait() + close(doneCh) + }() + select { + case <-doneCh: + case <-time.After(time.Second): + panic("timeout") + } + + if client.NumStreams() != 0 { + t.Fatalf("bad") + } + if server.NumStreams() != 0 { + t.Fatalf("bad") + } +} + +func TestSendData_Large(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + const ( + sendSize = 250 * 1024 * 1024 + recvSize = 4 * 1024 + ) + + data := make([]byte, sendSize) + for idx := range data { + data[idx] = byte(idx % 256) + } + + wg := &sync.WaitGroup{} + wg.Add(2) + + go func() { + defer wg.Done() + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + var sz int + buf := make([]byte, recvSize) + for i := 0; i < sendSize/recvSize; i++ { + n, err := stream.Read(buf) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != recvSize { + t.Fatalf("short read: %d", n) + } + sz += n + for idx := range buf { + if buf[idx] != byte(idx%256) { + t.Fatalf("bad: %v %v %v", i, idx, buf[idx]) + } + } + } + + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + + t.Logf("cap=%d, n=%d\n", stream.recvBuf.Cap(), sz) + }() + + go func() { + defer wg.Done() + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + + n, err := stream.Write(data) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != len(data) { + t.Fatalf("short write %d", n) + } + + if err := stream.Close(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + doneCh := make(chan struct{}) + go func() { + wg.Wait() + close(doneCh) + }() + select { + case <-doneCh: + case <-time.After(5 * time.Second): + panic("timeout") + } +} + +func TestGoAway(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + if err := server.GoAway(); err != nil { + t.Fatalf("err: %v", err) + } + + _, err := client.Open() + if err != ErrRemoteGoAway { + t.Fatalf("err: %v", err) + } +} + +func TestManyStreams(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + wg := &sync.WaitGroup{} + + acceptor := func(i int) { + defer wg.Done() + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + buf := make([]byte, 512) + for { + n, err := stream.Read(buf) + if err == io.EOF { + return + } + if err != nil { + t.Fatalf("err: %v", err) + } + if n == 0 { + t.Fatalf("err: %v", err) + } + } + } + sender := func(i int) { + defer wg.Done() + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + msg := fmt.Sprintf("%08d", i) + for i := 0; i < 1000; i++ { + n, err := stream.Write([]byte(msg)) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != len(msg) { + t.Fatalf("short write %d", n) + } + } + } + + for i := 0; i < 50; i++ { + wg.Add(2) + go acceptor(i) + go sender(i) + } + + wg.Wait() +} + +func TestManyStreams_PingPong(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + wg := &sync.WaitGroup{} + + ping := []byte("ping") + pong := []byte("pong") + + acceptor := func(i int) { + defer wg.Done() + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + buf := make([]byte, 4) + for { + // Read the 'ping' + n, err := stream.Read(buf) + if err == io.EOF { + return + } + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 4 { + t.Fatalf("err: %v", err) + } + if !bytes.Equal(buf, ping) { + t.Fatalf("bad: %s", buf) + } + + // Shrink the internal buffer! + stream.Shrink() + + // Write out the 'pong' + n, err = stream.Write(pong) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 4 { + t.Fatalf("err: %v", err) + } + } + } + sender := func(i int) { + defer wg.Done() + stream, err := client.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + buf := make([]byte, 4) + for i := 0; i < 1000; i++ { + // Send the 'ping' + n, err := stream.Write(ping) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 4 { + t.Fatalf("short write %d", n) + } + + // Read the 'pong' + n, err = stream.Read(buf) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 4 { + t.Fatalf("err: %v", err) + } + if !bytes.Equal(buf, pong) { + t.Fatalf("bad: %s", buf) + } + + // Shrink the buffer + stream.Shrink() + } + } + + for i := 0; i < 50; i++ { + wg.Add(2) + go acceptor(i) + go sender(i) + } + + wg.Wait() +} + +func TestHalfClose(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + if _, err = stream.Write([]byte("a")); err != nil { + t.Fatalf("err: %v", err) + } + + stream2, err := server.Accept() + if err != nil { + t.Fatalf("err: %v", err) + } + stream2.Close() // Half close + + buf := make([]byte, 4) + n, err := stream2.Read(buf) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 1 { + t.Fatalf("bad: %v", n) + } + + // Send more + if _, err = stream.Write([]byte("bcd")); err != nil { + t.Fatalf("err: %v", err) + } + stream.Close() + + // Read after close + n, err = stream2.Read(buf) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != 3 { + t.Fatalf("bad: %v", n) + } + + // EOF after close + n, err = stream2.Read(buf) + if err != io.EOF { + t.Fatalf("err: %v", err) + } + if n != 0 { + t.Fatalf("bad: %v", n) + } +} + +func TestReadDeadline(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + stream2, err := server.Accept() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream2.Close() + + if err := stream.SetReadDeadline(time.Now().Add(5 * time.Millisecond)); err != nil { + t.Fatalf("err: %v", err) + } + + buf := make([]byte, 4) + if _, err := stream.Read(buf); err != ErrTimeout { + t.Fatalf("err: %v", err) + } +} + +func TestReadDeadline_BlockedRead(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + stream2, err := server.Accept() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream2.Close() + + // Start a read that will block + errCh := make(chan error, 1) + go func() { + buf := make([]byte, 4) + _, err := stream.Read(buf) + errCh <- err + close(errCh) + }() + + // Wait to ensure the read has started. + time.Sleep(5 * time.Millisecond) + + // Update the read deadline + if err := stream.SetReadDeadline(time.Now().Add(5 * time.Millisecond)); err != nil { + t.Fatalf("err: %v", err) + } + + select { + case <-time.After(100 * time.Millisecond): + t.Fatal("expected read timeout") + case err := <-errCh: + if err != ErrTimeout { + t.Fatalf("expected ErrTimeout; got %v", err) + } + } +} + +func TestWriteDeadline(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + stream2, err := server.Accept() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream2.Close() + + if err := stream.SetWriteDeadline(time.Now().Add(50 * time.Millisecond)); err != nil { + t.Fatalf("err: %v", err) + } + + buf := make([]byte, 512) + for i := 0; i < int(initialStreamWindow); i++ { + _, err := stream.Write(buf) + if err != nil && err == ErrTimeout { + return + } else if err != nil { + t.Fatalf("err: %v", err) + } + } + t.Fatalf("Expected timeout") +} + +func TestWriteDeadline_BlockedWrite(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + stream2, err := server.Accept() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream2.Close() + + // Start a goroutine making writes that will block + errCh := make(chan error, 1) + go func() { + buf := make([]byte, 512) + for i := 0; i < int(initialStreamWindow); i++ { + _, err := stream.Write(buf) + if err == nil { + continue + } + + errCh <- err + close(errCh) + return + } + + close(errCh) + }() + + // Wait to ensure the write has started. + time.Sleep(5 * time.Millisecond) + + // Update the write deadline + if err := stream.SetWriteDeadline(time.Now().Add(5 * time.Millisecond)); err != nil { + t.Fatalf("err: %v", err) + } + + select { + case <-time.After(1 * time.Second): + t.Fatal("expected write timeout") + case err := <-errCh: + if err != ErrTimeout { + t.Fatalf("expected ErrTimeout; got %v", err) + } + } +} + +func TestBacklogExceeded(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + // Fill the backlog + max := client.config.AcceptBacklog + for i := 0; i < max; i++ { + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + if _, err := stream.Write([]byte("foo")); err != nil { + t.Fatalf("err: %v", err) + } + } + + // Attempt to open a new stream + errCh := make(chan error, 1) + go func() { + _, err := client.Open() + errCh <- err + }() + + // Shutdown the server + go func() { + time.Sleep(10 * time.Millisecond) + server.Close() + }() + + select { + case err := <-errCh: + if err == nil { + t.Fatalf("open should fail") + } + case <-time.After(time.Second): + t.Fatalf("timeout") + } +} + +func TestKeepAlive(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + time.Sleep(200 * time.Millisecond) + + // Ping value should increase + client.pingLock.Lock() + defer client.pingLock.Unlock() + if client.pingID == 0 { + t.Fatalf("should ping") + } + + server.pingLock.Lock() + defer server.pingLock.Unlock() + if server.pingID == 0 { + t.Fatalf("should ping") + } +} + +func TestKeepAlive_Timeout(t *testing.T) { + conn1, conn2 := testConn() + + clientConf := testConf() + clientConf.ConnectionWriteTimeout = time.Hour // We're testing keep alives, not connection writes + clientConf.EnableKeepAlive = false // Just test one direction, so it's deterministic who hangs up on whom + client, _ := Client(conn1, clientConf) + defer client.Close() + + server, _ := Server(conn2, testConf()) + defer server.Close() + + _ = captureLogs(client) // Client logs aren't part of the test + serverLogs := captureLogs(server) + + errCh := make(chan error, 1) + go func() { + _, err := server.Accept() // Wait until server closes + errCh <- err + }() + + // Prevent the client from responding + clientConn := client.conn.(*pipeConn) + clientConn.writeBlocker.Lock() + + select { + case err := <-errCh: + if err != ErrKeepAliveTimeout { + t.Fatalf("unexpected error: %v", err) + } + case <-time.After(1 * time.Second): + t.Fatalf("timeout waiting for timeout") + } + + if !server.IsClosed() { + t.Fatalf("server should have closed") + } + + if !serverLogs.match([]string{"[ERR] yamux: keepalive failed: i/o deadline reached"}) { + t.Fatalf("server log incorect: %v", serverLogs.logs()) + } +} + +func TestLargeWindow(t *testing.T) { + conf := DefaultConfig() + conf.MaxStreamWindowSize *= 2 + + client, server := testClientServerConfig(conf) + defer client.Close() + defer server.Close() + + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + stream2, err := server.Accept() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream2.Close() + + stream.SetWriteDeadline(time.Now().Add(10 * time.Millisecond)) + buf := make([]byte, conf.MaxStreamWindowSize) + n, err := stream.Write(buf) + if err != nil { + t.Fatalf("err: %v", err) + } + if n != len(buf) { + t.Fatalf("short write: %d", n) + } +} + +type UnlimitedReader struct{} + +func (u *UnlimitedReader) Read(p []byte) (int, error) { + runtime.Gosched() + return len(p), nil +} + +func TestSendData_VeryLarge(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + var n int64 = 1 * 1024 * 1024 * 1024 + var workers int = 16 + + wg := &sync.WaitGroup{} + wg.Add(workers * 2) + + for i := 0; i < workers; i++ { + go func() { + defer wg.Done() + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + buf := make([]byte, 4) + _, err = stream.Read(buf) + if err != nil { + t.Fatalf("err: %v", err) + } + if !bytes.Equal(buf, []byte{0, 1, 2, 3}) { + t.Fatalf("bad header") + } + + recv, err := io.Copy(ioutil.Discard, stream) + if err != nil { + t.Fatalf("err: %v", err) + } + if recv != n { + t.Fatalf("bad: %v", recv) + } + }() + } + for i := 0; i < workers; i++ { + go func() { + defer wg.Done() + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + _, err = stream.Write([]byte{0, 1, 2, 3}) + if err != nil { + t.Fatalf("err: %v", err) + } + + unlimited := &UnlimitedReader{} + sent, err := io.Copy(stream, io.LimitReader(unlimited, n)) + if err != nil { + t.Fatalf("err: %v", err) + } + if sent != n { + t.Fatalf("bad: %v", sent) + } + }() + } + + doneCh := make(chan struct{}) + go func() { + wg.Wait() + close(doneCh) + }() + select { + case <-doneCh: + case <-time.After(20 * time.Second): + panic("timeout") + } +} + +func TestBacklogExceeded_Accept(t *testing.T) { + client, server := testClientServer() + defer client.Close() + defer server.Close() + + max := 5 * client.config.AcceptBacklog + go func() { + for i := 0; i < max; i++ { + stream, err := server.Accept() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + } + }() + + // Fill the backlog + for i := 0; i < max; i++ { + stream, err := client.Open() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + if _, err := stream.Write([]byte("foo")); err != nil { + t.Fatalf("err: %v", err) + } + } +} + +func TestSession_WindowUpdateWriteDuringRead(t *testing.T) { + client, server := testClientServerConfig(testConfNoKeepAlive()) + defer client.Close() + defer server.Close() + + var wg sync.WaitGroup + wg.Add(2) + + // Choose a huge flood size that we know will result in a window update. + flood := int64(client.config.MaxStreamWindowSize) - 1 + + // The server will accept a new stream and then flood data to it. + go func() { + defer wg.Done() + + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + n, err := stream.Write(make([]byte, flood)) + if err != nil { + t.Fatalf("err: %v", err) + } + if int64(n) != flood { + t.Fatalf("short write: %d", n) + } + }() + + // The client will open a stream, block outbound writes, and then + // listen to the flood from the server, which should time out since + // it won't be able to send the window update. + go func() { + defer wg.Done() + + stream, err := client.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + conn := client.conn.(*pipeConn) + conn.writeBlocker.Lock() + + _, err = stream.Read(make([]byte, flood)) + if err != ErrConnectionWriteTimeout { + t.Fatalf("err: %v", err) + } + }() + + wg.Wait() +} + +func TestSession_PartialReadWindowUpdate(t *testing.T) { + client, server := testClientServerConfig(testConfNoKeepAlive()) + defer client.Close() + defer server.Close() + + var wg sync.WaitGroup + wg.Add(1) + + // Choose a huge flood size that we know will result in a window update. + flood := int64(client.config.MaxStreamWindowSize) + var wr *Stream + + // The server will accept a new stream and then flood data to it. + go func() { + defer wg.Done() + + var err error + wr, err = server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer wr.Close() + + if wr.sendWindow != client.config.MaxStreamWindowSize { + t.Fatalf("sendWindow: exp=%d, got=%d", client.config.MaxStreamWindowSize, wr.sendWindow) + } + + n, err := wr.Write(make([]byte, flood)) + if err != nil { + t.Fatalf("err: %v", err) + } + if int64(n) != flood { + t.Fatalf("short write: %d", n) + } + if wr.sendWindow != 0 { + t.Fatalf("sendWindow: exp=%d, got=%d", 0, wr.sendWindow) + } + }() + + stream, err := client.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + wg.Wait() + + _, err = stream.Read(make([]byte, flood/2+1)) + + if exp := uint32(flood/2 + 1); wr.sendWindow != exp { + t.Errorf("sendWindow: exp=%d, got=%d", exp, wr.sendWindow) + } +} + +func TestSession_sendNoWait_Timeout(t *testing.T) { + client, server := testClientServerConfig(testConfNoKeepAlive()) + defer client.Close() + defer server.Close() + + var wg sync.WaitGroup + wg.Add(2) + + go func() { + defer wg.Done() + + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + }() + + // The client will open the stream and then block outbound writes, we'll + // probe sendNoWait once it gets into that state. + go func() { + defer wg.Done() + + stream, err := client.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + conn := client.conn.(*pipeConn) + conn.writeBlocker.Lock() + + hdr := header(make([]byte, headerSize)) + hdr.encode(typePing, flagACK, 0, 0) + for { + err = client.sendNoWait(hdr) + if err == nil { + continue + } else if err == ErrConnectionWriteTimeout { + break + } else { + t.Fatalf("err: %v", err) + } + } + }() + + wg.Wait() +} + +func TestSession_PingOfDeath(t *testing.T) { + client, server := testClientServerConfig(testConfNoKeepAlive()) + defer client.Close() + defer server.Close() + + var wg sync.WaitGroup + wg.Add(2) + + var doPingOfDeath sync.Mutex + doPingOfDeath.Lock() + + // This is used later to block outbound writes. + conn := server.conn.(*pipeConn) + + // The server will accept a stream, block outbound writes, and then + // flood its send channel so that no more headers can be queued. + go func() { + defer wg.Done() + + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + conn.writeBlocker.Lock() + for { + hdr := header(make([]byte, headerSize)) + hdr.encode(typePing, 0, 0, 0) + err = server.sendNoWait(hdr) + if err == nil { + continue + } else if err == ErrConnectionWriteTimeout { + break + } else { + t.Fatalf("err: %v", err) + } + } + + doPingOfDeath.Unlock() + }() + + // The client will open a stream and then send the server a ping once it + // can no longer write. This makes sure the server doesn't deadlock reads + // while trying to reply to the ping with no ability to write. + go func() { + defer wg.Done() + + stream, err := client.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + // This ping will never unblock because the ping id will never + // show up in a response. + doPingOfDeath.Lock() + go func() { client.Ping() }() + + // Wait for a while to make sure the previous ping times out, + // then turn writes back on and make sure a ping works again. + time.Sleep(2 * server.config.ConnectionWriteTimeout) + conn.writeBlocker.Unlock() + if _, err = client.Ping(); err != nil { + t.Fatalf("err: %v", err) + } + }() + + wg.Wait() +} + +func TestSession_ConnectionWriteTimeout(t *testing.T) { + client, server := testClientServerConfig(testConfNoKeepAlive()) + defer client.Close() + defer server.Close() + + var wg sync.WaitGroup + wg.Add(2) + + go func() { + defer wg.Done() + + stream, err := server.AcceptStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + }() + + // The client will open the stream and then block outbound writes, we'll + // tee up a write and make sure it eventually times out. + go func() { + defer wg.Done() + + stream, err := client.OpenStream() + if err != nil { + t.Fatalf("err: %v", err) + } + defer stream.Close() + + conn := client.conn.(*pipeConn) + conn.writeBlocker.Lock() + + // Since the write goroutine is blocked then this will return a + // timeout since it can't get feedback about whether the write + // worked. + n, err := stream.Write([]byte("hello")) + if err != ErrConnectionWriteTimeout { + t.Fatalf("err: %v", err) + } + if n != 0 { + t.Fatalf("lied about writes: %d", n) + } + }() + + wg.Wait() +} diff --git a/vendor/github.com/hashicorp/yamux/spec.md b/vendor/github.com/hashicorp/yamux/spec.md new file mode 100644 index 0000000..183d797 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/spec.md @@ -0,0 +1,140 @@ +# Specification + +We use this document to detail the internal specification of Yamux. +This is used both as a guide for implementing Yamux, but also for +alternative interoperable libraries to be built. + +# Framing + +Yamux uses a streaming connection underneath, but imposes a message +framing so that it can be shared between many logical streams. Each +frame contains a header like: + +* Version (8 bits) +* Type (8 bits) +* Flags (16 bits) +* StreamID (32 bits) +* Length (32 bits) + +This means that each header has a 12 byte overhead. +All fields are encoded in network order (big endian). +Each field is described below: + +## Version Field + +The version field is used for future backward compatibility. At the +current time, the field is always set to 0, to indicate the initial +version. + +## Type Field + +The type field is used to switch the frame message type. The following +message types are supported: + +* 0x0 Data - Used to transmit data. May transmit zero length payloads + depending on the flags. + +* 0x1 Window Update - Used to updated the senders receive window size. + This is used to implement per-session flow control. + +* 0x2 Ping - Used to measure RTT. It can also be used to heart-beat + and do keep-alives over TCP. + +* 0x3 Go Away - Used to close a session. + +## Flag Field + +The flags field is used to provide additional information related +to the message type. The following flags are supported: + +* 0x1 SYN - Signals the start of a new stream. May be sent with a data or + window update message. Also sent with a ping to indicate outbound. + +* 0x2 ACK - Acknowledges the start of a new stream. May be sent with a data + or window update message. Also sent with a ping to indicate response. + +* 0x4 FIN - Performs a half-close of a stream. May be sent with a data + message or window update. + +* 0x8 RST - Reset a stream immediately. May be sent with a data or + window update message. + +## StreamID Field + +The StreamID field is used to identify the logical stream the frame +is addressing. The client side should use odd ID's, and the server even. +This prevents any collisions. Additionally, the 0 ID is reserved to represent +the session. + +Both Ping and Go Away messages should always use the 0 StreamID. + +## Length Field + +The meaning of the length field depends on the message type: + +* Data - provides the length of bytes following the header +* Window update - provides a delta update to the window size +* Ping - Contains an opaque value, echoed back +* Go Away - Contains an error code + +# Message Flow + +There is no explicit connection setup, as Yamux relies on an underlying +transport to be provided. However, there is a distinction between client +and server side of the connection. + +## Opening a stream + +To open a stream, an initial data or window update frame is sent +with a new StreamID. The SYN flag should be set to signal a new stream. + +The receiver must then reply with either a data or window update frame +with the StreamID along with the ACK flag to accept the stream or with +the RST flag to reject the stream. + +Because we are relying on the reliable stream underneath, a connection +can begin sending data once the SYN flag is sent. The corresponding +ACK does not need to be received. This is particularly well suited +for an RPC system where a client wants to open a stream and immediately +fire a request without waiting for the RTT of the ACK. + +This does introduce the possibility of a connection being rejected +after data has been sent already. This is a slight semantic difference +from TCP, where the conection cannot be refused after it is opened. +Clients should be prepared to handle this by checking for an error +that indicates a RST was received. + +## Closing a stream + +To close a stream, either side sends a data or window update frame +along with the FIN flag. This does a half-close indicating the sender +will send no further data. + +Once both sides have closed the connection, the stream is closed. + +Alternatively, if an error occurs, the RST flag can be used to +hard close a stream immediately. + +## Flow Control + +When Yamux is initially starts each stream with a 256KB window size. +There is no window size for the session. + +To prevent the streams from stalling, window update frames should be +sent regularly. Yamux can be configured to provide a larger limit for +windows sizes. Both sides assume the initial 256KB window, but can +immediately send a window update as part of the SYN/ACK indicating a +larger window. + +Both sides should track the number of bytes sent in Data frames +only, as only they are tracked as part of the window size. + +## Session termination + +When a session is being terminated, the Go Away message should +be sent. The Length should be set to one of the following to +provide an error code: + +* 0x0 Normal termination +* 0x1 Protocol error +* 0x2 Internal error diff --git a/vendor/github.com/hashicorp/yamux/stream.go b/vendor/github.com/hashicorp/yamux/stream.go new file mode 100644 index 0000000..e951c22 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/stream.go @@ -0,0 +1,472 @@ +package yamux + +import ( + "bytes" + "io" + "sync" + "sync/atomic" + "time" +) + +type streamState int + +const ( + streamInit streamState = iota + streamSYNSent + streamSYNReceived + streamEstablished + streamLocalClose + streamRemoteClose + streamClosed + streamReset +) + +// Stream is used to represent a logical stream +// within a session. +type Stream struct { + recvWindow uint32 + sendWindow uint32 + + id uint32 + session *Session + + state streamState + stateLock sync.Mutex + + recvBuf *bytes.Buffer + recvLock sync.Mutex + + controlHdr header + controlErr chan error + controlHdrLock sync.Mutex + + sendHdr header + sendErr chan error + sendLock sync.Mutex + + recvNotifyCh chan struct{} + sendNotifyCh chan struct{} + + readDeadline atomic.Value // time.Time + writeDeadline atomic.Value // time.Time +} + +// newStream is used to construct a new stream within +// a given session for an ID +func newStream(session *Session, id uint32, state streamState) *Stream { + s := &Stream{ + id: id, + session: session, + state: state, + controlHdr: header(make([]byte, headerSize)), + controlErr: make(chan error, 1), + sendHdr: header(make([]byte, headerSize)), + sendErr: make(chan error, 1), + recvWindow: initialStreamWindow, + sendWindow: initialStreamWindow, + recvNotifyCh: make(chan struct{}, 1), + sendNotifyCh: make(chan struct{}, 1), + } + s.readDeadline.Store(time.Time{}) + s.writeDeadline.Store(time.Time{}) + return s +} + +// Session returns the associated stream session +func (s *Stream) Session() *Session { + return s.session +} + +// StreamID returns the ID of this stream +func (s *Stream) StreamID() uint32 { + return s.id +} + +// Read is used to read from the stream +func (s *Stream) Read(b []byte) (n int, err error) { + defer asyncNotify(s.recvNotifyCh) +START: + s.stateLock.Lock() + switch s.state { + case streamLocalClose: + fallthrough + case streamRemoteClose: + fallthrough + case streamClosed: + s.recvLock.Lock() + if s.recvBuf == nil || s.recvBuf.Len() == 0 { + s.recvLock.Unlock() + s.stateLock.Unlock() + return 0, io.EOF + } + s.recvLock.Unlock() + case streamReset: + s.stateLock.Unlock() + return 0, ErrConnectionReset + } + s.stateLock.Unlock() + + // If there is no data available, block + s.recvLock.Lock() + if s.recvBuf == nil || s.recvBuf.Len() == 0 { + s.recvLock.Unlock() + goto WAIT + } + + // Read any bytes + n, _ = s.recvBuf.Read(b) + s.recvLock.Unlock() + + // Send a window update potentially + err = s.sendWindowUpdate() + return n, err + +WAIT: + var timeout <-chan time.Time + var timer *time.Timer + readDeadline := s.readDeadline.Load().(time.Time) + if !readDeadline.IsZero() { + delay := readDeadline.Sub(time.Now()) + timer = time.NewTimer(delay) + timeout = timer.C + } + select { + case <-s.recvNotifyCh: + if timer != nil { + timer.Stop() + } + goto START + case <-timeout: + return 0, ErrTimeout + } +} + +// Write is used to write to the stream +func (s *Stream) Write(b []byte) (n int, err error) { + s.sendLock.Lock() + defer s.sendLock.Unlock() + total := 0 + for total < len(b) { + n, err := s.write(b[total:]) + total += n + if err != nil { + return total, err + } + } + return total, nil +} + +// write is used to write to the stream, may return on +// a short write. +func (s *Stream) write(b []byte) (n int, err error) { + var flags uint16 + var max uint32 + var body io.Reader +START: + s.stateLock.Lock() + switch s.state { + case streamLocalClose: + fallthrough + case streamClosed: + s.stateLock.Unlock() + return 0, ErrStreamClosed + case streamReset: + s.stateLock.Unlock() + return 0, ErrConnectionReset + } + s.stateLock.Unlock() + + // If there is no data available, block + window := atomic.LoadUint32(&s.sendWindow) + if window == 0 { + goto WAIT + } + + // Determine the flags if any + flags = s.sendFlags() + + // Send up to our send window + max = min(window, uint32(len(b))) + body = bytes.NewReader(b[:max]) + + // Send the header + s.sendHdr.encode(typeData, flags, s.id, max) + if err = s.session.waitForSendErr(s.sendHdr, body, s.sendErr); err != nil { + return 0, err + } + + // Reduce our send window + atomic.AddUint32(&s.sendWindow, ^uint32(max-1)) + + // Unlock + return int(max), err + +WAIT: + var timeout <-chan time.Time + writeDeadline := s.writeDeadline.Load().(time.Time) + if !writeDeadline.IsZero() { + delay := writeDeadline.Sub(time.Now()) + timeout = time.After(delay) + } + select { + case <-s.sendNotifyCh: + goto START + case <-timeout: + return 0, ErrTimeout + } + return 0, nil +} + +// sendFlags determines any flags that are appropriate +// based on the current stream state +func (s *Stream) sendFlags() uint16 { + s.stateLock.Lock() + defer s.stateLock.Unlock() + var flags uint16 + switch s.state { + case streamInit: + flags |= flagSYN + s.state = streamSYNSent + case streamSYNReceived: + flags |= flagACK + s.state = streamEstablished + } + return flags +} + +// sendWindowUpdate potentially sends a window update enabling +// further writes to take place. Must be invoked with the lock. +func (s *Stream) sendWindowUpdate() error { + s.controlHdrLock.Lock() + defer s.controlHdrLock.Unlock() + + // Determine the delta update + max := s.session.config.MaxStreamWindowSize + var bufLen uint32 + s.recvLock.Lock() + if s.recvBuf != nil { + bufLen = uint32(s.recvBuf.Len()) + } + delta := (max - bufLen) - s.recvWindow + + // Determine the flags if any + flags := s.sendFlags() + + // Check if we can omit the update + if delta < (max/2) && flags == 0 { + s.recvLock.Unlock() + return nil + } + + // Update our window + s.recvWindow += delta + s.recvLock.Unlock() + + // Send the header + s.controlHdr.encode(typeWindowUpdate, flags, s.id, delta) + if err := s.session.waitForSendErr(s.controlHdr, nil, s.controlErr); err != nil { + return err + } + return nil +} + +// sendClose is used to send a FIN +func (s *Stream) sendClose() error { + s.controlHdrLock.Lock() + defer s.controlHdrLock.Unlock() + + flags := s.sendFlags() + flags |= flagFIN + s.controlHdr.encode(typeWindowUpdate, flags, s.id, 0) + if err := s.session.waitForSendErr(s.controlHdr, nil, s.controlErr); err != nil { + return err + } + return nil +} + +// Close is used to close the stream +func (s *Stream) Close() error { + closeStream := false + s.stateLock.Lock() + switch s.state { + // Opened means we need to signal a close + case streamSYNSent: + fallthrough + case streamSYNReceived: + fallthrough + case streamEstablished: + s.state = streamLocalClose + goto SEND_CLOSE + + case streamLocalClose: + case streamRemoteClose: + s.state = streamClosed + closeStream = true + goto SEND_CLOSE + + case streamClosed: + case streamReset: + default: + panic("unhandled state") + } + s.stateLock.Unlock() + return nil +SEND_CLOSE: + s.stateLock.Unlock() + s.sendClose() + s.notifyWaiting() + if closeStream { + s.session.closeStream(s.id) + } + return nil +} + +// forceClose is used for when the session is exiting +func (s *Stream) forceClose() { + s.stateLock.Lock() + s.state = streamClosed + s.stateLock.Unlock() + s.notifyWaiting() +} + +// processFlags is used to update the state of the stream +// based on set flags, if any. Lock must be held +func (s *Stream) processFlags(flags uint16) error { + // Close the stream without holding the state lock + closeStream := false + defer func() { + if closeStream { + s.session.closeStream(s.id) + } + }() + + s.stateLock.Lock() + defer s.stateLock.Unlock() + if flags&flagACK == flagACK { + if s.state == streamSYNSent { + s.state = streamEstablished + } + s.session.establishStream(s.id) + } + if flags&flagFIN == flagFIN { + switch s.state { + case streamSYNSent: + fallthrough + case streamSYNReceived: + fallthrough + case streamEstablished: + s.state = streamRemoteClose + s.notifyWaiting() + case streamLocalClose: + s.state = streamClosed + closeStream = true + s.notifyWaiting() + default: + s.session.logger.Printf("[ERR] yamux: unexpected FIN flag in state %d", s.state) + return ErrUnexpectedFlag + } + } + if flags&flagRST == flagRST { + s.state = streamReset + closeStream = true + s.notifyWaiting() + } + return nil +} + +// notifyWaiting notifies all the waiting channels +func (s *Stream) notifyWaiting() { + asyncNotify(s.recvNotifyCh) + asyncNotify(s.sendNotifyCh) +} + +// incrSendWindow updates the size of our send window +func (s *Stream) incrSendWindow(hdr header, flags uint16) error { + if err := s.processFlags(flags); err != nil { + return err + } + + // Increase window, unblock a sender + atomic.AddUint32(&s.sendWindow, hdr.Length()) + asyncNotify(s.sendNotifyCh) + return nil +} + +// readData is used to handle a data frame +func (s *Stream) readData(hdr header, flags uint16, conn io.Reader) error { + if err := s.processFlags(flags); err != nil { + return err + } + + // Check that our recv window is not exceeded + length := hdr.Length() + if length == 0 { + return nil + } + + // Wrap in a limited reader + conn = &io.LimitedReader{R: conn, N: int64(length)} + + // Copy into buffer + s.recvLock.Lock() + + if length > s.recvWindow { + s.session.logger.Printf("[ERR] yamux: receive window exceeded (stream: %d, remain: %d, recv: %d)", s.id, s.recvWindow, length) + return ErrRecvWindowExceeded + } + + if s.recvBuf == nil { + // Allocate the receive buffer just-in-time to fit the full data frame. + // This way we can read in the whole packet without further allocations. + s.recvBuf = bytes.NewBuffer(make([]byte, 0, length)) + } + if _, err := io.Copy(s.recvBuf, conn); err != nil { + s.session.logger.Printf("[ERR] yamux: Failed to read stream data: %v", err) + s.recvLock.Unlock() + return err + } + + // Decrement the receive window + s.recvWindow -= length + s.recvLock.Unlock() + + // Unblock any readers + asyncNotify(s.recvNotifyCh) + return nil +} + +// SetDeadline sets the read and write deadlines +func (s *Stream) SetDeadline(t time.Time) error { + if err := s.SetReadDeadline(t); err != nil { + return err + } + if err := s.SetWriteDeadline(t); err != nil { + return err + } + return nil +} + +// SetReadDeadline sets the deadline for blocked and future Read calls. +func (s *Stream) SetReadDeadline(t time.Time) error { + s.readDeadline.Store(t) + asyncNotify(s.recvNotifyCh) + return nil +} + +// SetWriteDeadline sets the deadline for blocked and future Write calls +func (s *Stream) SetWriteDeadline(t time.Time) error { + s.writeDeadline.Store(t) + asyncNotify(s.sendNotifyCh) + return nil +} + +// Shrink is used to compact the amount of buffers utilized +// This is useful when using Yamux in a connection pool to reduce +// the idle memory utilization. +func (s *Stream) Shrink() { + s.recvLock.Lock() + if s.recvBuf != nil && s.recvBuf.Len() == 0 { + s.recvBuf = nil + } + s.recvLock.Unlock() +} diff --git a/vendor/github.com/hashicorp/yamux/util.go b/vendor/github.com/hashicorp/yamux/util.go new file mode 100644 index 0000000..8a73e92 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/util.go @@ -0,0 +1,43 @@ +package yamux + +import ( + "sync" + "time" +) + +var ( + timerPool = &sync.Pool{ + New: func() interface{} { + timer := time.NewTimer(time.Hour * 1e6) + timer.Stop() + return timer + }, + } +) + +// asyncSendErr is used to try an async send of an error +func asyncSendErr(ch chan error, err error) { + if ch == nil { + return + } + select { + case ch <- err: + default: + } +} + +// asyncNotify is used to signal a waiting goroutine +func asyncNotify(ch chan struct{}) { + select { + case ch <- struct{}{}: + default: + } +} + +// min computes the minimum of two values +func min(a, b uint32) uint32 { + if a < b { + return a + } + return b +} diff --git a/vendor/github.com/hashicorp/yamux/util_test.go b/vendor/github.com/hashicorp/yamux/util_test.go new file mode 100644 index 0000000..dd14623 --- /dev/null +++ b/vendor/github.com/hashicorp/yamux/util_test.go @@ -0,0 +1,50 @@ +package yamux + +import ( + "testing" +) + +func TestAsyncSendErr(t *testing.T) { + ch := make(chan error) + asyncSendErr(ch, ErrTimeout) + select { + case <-ch: + t.Fatalf("should not get") + default: + } + + ch = make(chan error, 1) + asyncSendErr(ch, ErrTimeout) + select { + case <-ch: + default: + t.Fatalf("should get") + } +} + +func TestAsyncNotify(t *testing.T) { + ch := make(chan struct{}) + asyncNotify(ch) + select { + case <-ch: + t.Fatalf("should not get") + default: + } + + ch = make(chan struct{}, 1) + asyncNotify(ch) + select { + case <-ch: + default: + t.Fatalf("should get") + } +} + +func TestMin(t *testing.T) { + if min(1, 2) != 1 { + t.Fatalf("bad") + } + if min(2, 1) != 1 { + t.Fatalf("bad") + } +} diff --git a/vendor/github.com/rivo/tview/CONTRIBUTING.md b/vendor/github.com/rivo/tview/CONTRIBUTING.md deleted file mode 100644 index 92f6886..0000000 --- a/vendor/github.com/rivo/tview/CONTRIBUTING.md +++ /dev/null @@ -1,35 +0,0 @@ -# Contributing to tview - -First of all, thank you for taking the time to contribute. - -The following provides you with some guidance on how to contribute to this project. Mainly, it is meant to save us all some time so please read it, it's not long. - -Please note that this document is work in progress so I might add to it in the future. - -## Issues - -- Please include enough information so everybody understands your request. -- Screenshots or code that illustrates your point always helps. -- It's fine to ask for help. But you should have checked out the [documentation](https://godoc.org/github.com/rivo/tview) first in any case. -- If you request a new feature, state your motivation and share a use case that you faced where you needed that new feature. It should be something that others will also need. - -## Pull Requests - -In my limited time I can spend on this project, I will always go through issues first before looking at pull requests. It takes a _lot_ of time to look at code that you submitted and I may not have that time. So be prepared to have your pull requests lying around for a long time. - -Therefore, if you have a feature request, open an issue first before sending me a pull request, and allow for some discussion. It may save you from writing code that will get rejected. If your case is strong, there is a good chance that I will add the feature for you. - -I'm very picky about the code that goes into this repo. So if you violate any of the following guidelines, there is a good chance I won't merge your pull request. - -- There must be a strong case for your additions/changes, such as: - - Bug fixes - - Features that are needed (see "Issues" above; state your motivation) - - Improvements in stability or performance (if readability does not suffer) -- Your code must follow the structure of the existing code. Don't just patch something on. Try to understand how `tview` is currently designed and follow that design. Your code needs to be consistent with existing code. -- If you're adding code that increases the work required to maintain the project, you must be willing to take responsibility for that extra work. I will ask you to maintain your part of the code in the long run. -- Function/type/variable/constant names must be as descriptive as they are right now. Follow the conventions of the package. -- All functions/types/variables/constants, even private ones, must have comments in good English. These comments must be elaborate enough so that new users of the package understand them and can follow them. Provide examples if you have to. Start all sentences upper-case, as is common in English, and end them with a period. -- A new function should be located close to related functions in the file. For example, `GetColor()` should come after (or before) `SetColor()`. -- Your changes must not decrease the project's [Go Report](https://goreportcard.com/report/github.com/rivo/tview) rating. -- No breaking changes unless there is absolutely no other way. -- If an issue accompanies your pull request, reference it in the PR's comments, e.g. "Fixes #123", so it is closed automatically when the PR is closed. diff --git a/vendor/github.com/rivo/tview/README.md b/vendor/github.com/rivo/tview/README.md deleted file mode 100644 index 56e0522..0000000 --- a/vendor/github.com/rivo/tview/README.md +++ /dev/null @@ -1,108 +0,0 @@ -# Rich Interactive Widgets for Terminal UIs - -[![PkgGoDev](https://pkg.go.dev/badge/github.com/rivo/tview)](https://pkg.go.dev/github.com/rivo/tview) -[![Go Report](https://img.shields.io/badge/go%20report-A%2B-brightgreen.svg)](https://goreportcard.com/report/github.com/rivo/tview) - -This Go package provides commonly needed components for terminal based user interfaces. - -![Screenshot](tview.gif) - -Among these components are: - -- __Input forms__ (include __input/password fields__, __drop-down selections__, __checkboxes__, and __buttons__) -- Navigable multi-color __text views__ -- Sophisticated navigable __table views__ -- Flexible __tree views__ -- Selectable __lists__ -- __Grid__, __Flexbox__ and __page layouts__ -- Modal __message windows__ -- An __application__ wrapper - -They come with lots of customization options and can be easily extended to fit your needs. - -## Installation - -```bash -go get github.com/rivo/tview -``` - -## Hello World - -This basic example creates a box titled "Hello, World!" and displays it in your terminal: - -```go -package main - -import ( - "github.com/rivo/tview" -) - -func main() { - box := tview.NewBox().SetBorder(true).SetTitle("Hello, world!") - if err := tview.NewApplication().SetRoot(box, true).Run(); err != nil { - panic(err) - } -} -``` - -Check out the [GitHub Wiki](https://github.com/rivo/tview/wiki) for more examples along with screenshots. Or try the examples in the "demos" subdirectory. - -For a presentation highlighting this package, compile and run the program found in the "demos/presentation" subdirectory. - -## Projects using `tview` - -- [IRCCloud Terminal Client](https://github.com/termoose/irccloud) -- [Window manager for `tview`](https://github.com/epiclabs-io/winman) -- [Password manager](https://github.com/7onetella/password) -- [CLI bookmark manager](https://github.com/Endi1/drawer) -- [A caving database interface written in Go](https://github.com/IdlePhysicist/cave-logger) -- [App for rental of electic bikes](https://github.com/MrDienns/bike-commerce) -- [Interactive file browse and exec any command.](https://github.com/bannzai/itree) -- [A simple CRM](https://github.com/broadcastle/crm) -- [Terminal UI for todist](https://github.com/cyberdummy/todoista) -- [Graphical kubectl wrapper](https://github.com/dcaiafa/kpick) -- [Decred Decentralized Exchange ](https://github.com/decred/dcrdex) -- [Kubernetes CLI To Manage Your Clusters In Style! ](https://github.com/derailed/k9s) -- [A CLI file browser for Raspberry PI](https://github.com/destinmoulton/pixi) -- [A tool to manage projects.](https://github.com/divramod/dp) -- [A simple app for BMI monitoring](https://github.com/erleene/go-bmi) -- [Stream TIDAL from command line](https://github.com/godsic/vibe) -- [Secure solution for fully decentralized password management](https://github.com/guillaumemichel/passtor/) -- [A growing collection of convenient little tools to work with systemd services](https://github.com/muesli/service-tools/) -- [A terminal based browser for Redis written in Go](https://github.com/nitishm/redis-terminal) -- [First project for the Computer Networks course.](https://github.com/pablogadhi/XMPPClient) -- [CLI tool build in Golang for managing ssh connection](https://github.com/patilsuraj767/connection-master) -- [Test your typing speed in the terminal!](https://github.com/shilangyu/typer-go) -- [TUI Client for Docker](https://github.com/skanehira/docui) -- [SSH client using certificates signed by HashiCorp Vault](https://github.com/stephane-martin/vssh) -- [A go terminal based pos software.](https://github.com/thebmw/y2kpos) -- [VMware vCenter Text UI](https://github.com/thebsdbox/vctui) -- [Bookmarks on terminal](https://github.com/tryffel/bookmarker) -- [A UDP testing utility](https://github.com/vaelen/udp-tester) -- [A simple Kanban board for your terminal](https://github.com/witchard/toukan) -- [The personal information dashboard for your terminal. ](https://github.com/wtfutil/wtf) -- [MySQL database to Golang struct](https://github.com/xxjwxc/gormt) -- [Cryptowatch Go SDK](https://github.com/y3sh/cw-sdk-go) -- [Discord, TUI and SIXEL.](https://gitlab.com/diamondburned/6cord) -- [A CLI Audio Player](https://www.github.com/dhulihan/grump) -- [GLab, a GitLab CLI tool](https://gitlab.com/profclems/glab) - -## Documentation - -Refer to https://pkg.go.dev/github.com/rivo/tview for the package's documentation. Also check out the [Wiki](https://github.com/rivo/tview/wiki). - -## Dependencies - -This package is based on [github.com/gdamore/tcell](https://github.com/gdamore/tcell) (and its dependencies) as well as on [github.com/rivo/uniseg](https://github.com/rivo/uniseg). - -## Versioning and Backwards-Compatibility - -I try really hard to keep this project backwards compatible. Your software should not break when you upgrade `tview`. But this also means that some of its shortcomings that were present in the initial versions will remain. In addition, at least for the time being, you won't find any version tags in this repo. The newest version should be the one to upgrade to. It has all the bugfixes and latest features. Having said that, backwards compatibility may still break when: - -- a new version of an imported package (most likely [`tcell`](https://github.com/gdamore/tcell)) changes in such a way that forces me to make changes in `tview` as well, -- I fix something that I consider a bug, rather than a feature, something that does not work as originally intended, -- I make changes to "internal" interfaces such as [`Primitive`](https://pkg.go.dev/github.com/rivo/tview#Primitive). You shouldn't need these interfaces unless you're writing your own primitives for `tview`. (Yes, I realize these are public interfaces. This has advantages as well as disadvantages. For the time being, it is what it is.) - -## Your Feedback - -Add your issue here on GitHub. Feel free to get in touch if you have any questions. diff --git a/vendor/github.com/rivo/tview/ansi.go b/vendor/github.com/rivo/tview/ansi.go deleted file mode 100644 index 49b2e92..0000000 --- a/vendor/github.com/rivo/tview/ansi.go +++ /dev/null @@ -1,258 +0,0 @@ -package tview - -import ( - "bytes" - "fmt" - "io" - "strconv" - "strings" -) - -// The states of the ANSI escape code parser. -const ( - ansiText = iota - ansiEscape - ansiSubstring - ansiControlSequence -) - -// ansi is a io.Writer which translates ANSI escape codes into tview color -// tags. -type ansi struct { - io.Writer - - // Reusable buffers. - buffer *bytes.Buffer // The entire output text of one Write(). - csiParameter, csiIntermediate *bytes.Buffer // Partial CSI strings. - attributes string // The buffer's current text attributes (a tview attribute string). - - // The current state of the parser. One of the ansi constants. - state int -} - -// ANSIWriter returns an io.Writer which translates any ANSI escape codes -// written to it into tview color tags. Other escape codes don't have an effect -// and are simply removed. The translated text is written to the provided -// writer. -func ANSIWriter(writer io.Writer) io.Writer { - return &ansi{ - Writer: writer, - buffer: new(bytes.Buffer), - csiParameter: new(bytes.Buffer), - csiIntermediate: new(bytes.Buffer), - state: ansiText, - } -} - -// Write parses the given text as a string of runes, translates ANSI escape -// codes to color tags and writes them to the output writer. -func (a *ansi) Write(text []byte) (int, error) { - defer func() { - a.buffer.Reset() - }() - - for _, r := range string(text) { - switch a.state { - - // We just entered an escape sequence. - case ansiEscape: - switch r { - case '[': // Control Sequence Introducer. - a.csiParameter.Reset() - a.csiIntermediate.Reset() - a.state = ansiControlSequence - case 'c': // Reset. - fmt.Fprint(a.buffer, "[-:-:-]") - a.state = ansiText - case 'P', ']', 'X', '^', '_': // Substrings and commands. - a.state = ansiSubstring - default: // Ignore. - a.state = ansiText - } - - // CSI Sequences. - case ansiControlSequence: - switch { - case r >= 0x30 && r <= 0x3f: // Parameter bytes. - if _, err := a.csiParameter.WriteRune(r); err != nil { - return 0, err - } - case r >= 0x20 && r <= 0x2f: // Intermediate bytes. - if _, err := a.csiIntermediate.WriteRune(r); err != nil { - return 0, err - } - case r >= 0x40 && r <= 0x7e: // Final byte. - switch r { - case 'E': // Next line. - count, _ := strconv.Atoi(a.csiParameter.String()) - if count == 0 { - count = 1 - } - fmt.Fprint(a.buffer, strings.Repeat("\n", count)) - case 'm': // Select Graphic Rendition. - var background, foreground string - params := a.csiParameter.String() - fields := strings.Split(params, ";") - if len(params) == 0 || len(fields) == 1 && fields[0] == "0" { - // Reset. - a.attributes = "" - if _, err := a.buffer.WriteString("[-:-:-]"); err != nil { - return 0, err - } - break - } - lookupColor := func(colorNumber int) string { - if colorNumber < 0 || colorNumber > 15 { - return "black" - } - return []string{ - "black", - "maroon", - "green", - "olive", - "navy", - "purple", - "teal", - "silver", - "gray", - "red", - "lime", - "yellow", - "blue", - "fuchsia", - "aqua", - "white", - }[colorNumber] - } - FieldLoop: - for index, field := range fields { - switch field { - case "1", "01": - if strings.IndexRune(a.attributes, 'b') < 0 { - a.attributes += "b" - } - case "2", "02": - if strings.IndexRune(a.attributes, 'd') < 0 { - a.attributes += "d" - } - case "4", "04": - if strings.IndexRune(a.attributes, 'u') < 0 { - a.attributes += "u" - } - case "5", "05": - if strings.IndexRune(a.attributes, 'l') < 0 { - a.attributes += "l" - } - case "22": - if i := strings.IndexRune(a.attributes, 'b'); i >= 0 { - a.attributes = a.attributes[:i] + a.attributes[i+1:] - } - if i := strings.IndexRune(a.attributes, 'd'); i >= 0 { - a.attributes = a.attributes[:i] + a.attributes[i+1:] - } - case "24": - if i := strings.IndexRune(a.attributes, 'u'); i >= 0 { - a.attributes = a.attributes[:i] + a.attributes[i+1:] - } - case "25": - if i := strings.IndexRune(a.attributes, 'l'); i >= 0 { - a.attributes = a.attributes[:i] + a.attributes[i+1:] - } - case "30", "31", "32", "33", "34", "35", "36", "37": - colorNumber, _ := strconv.Atoi(field) - foreground = lookupColor(colorNumber - 30) - case "39": - foreground = "-" - case "40", "41", "42", "43", "44", "45", "46", "47": - colorNumber, _ := strconv.Atoi(field) - background = lookupColor(colorNumber - 40) - case "49": - background = "-" - case "90", "91", "92", "93", "94", "95", "96", "97": - colorNumber, _ := strconv.Atoi(field) - foreground = lookupColor(colorNumber - 82) - case "100", "101", "102", "103", "104", "105", "106", "107": - colorNumber, _ := strconv.Atoi(field) - background = lookupColor(colorNumber - 92) - case "38", "48": - var color string - if len(fields) > index+1 { - if fields[index+1] == "5" && len(fields) > index+2 { // 8-bit colors. - colorNumber, _ := strconv.Atoi(fields[index+2]) - if colorNumber <= 15 { - color = lookupColor(colorNumber) - } else if colorNumber <= 231 { - red := (colorNumber - 16) / 36 - green := ((colorNumber - 16) / 6) % 6 - blue := (colorNumber - 16) % 6 - color = fmt.Sprintf("#%02x%02x%02x", 255*red/5, 255*green/5, 255*blue/5) - } else if colorNumber <= 255 { - grey := 255 * (colorNumber - 232) / 23 - color = fmt.Sprintf("#%02x%02x%02x", grey, grey, grey) - } - } else if fields[index+1] == "2" && len(fields) > index+4 { // 24-bit colors. - red, _ := strconv.Atoi(fields[index+2]) - green, _ := strconv.Atoi(fields[index+3]) - blue, _ := strconv.Atoi(fields[index+4]) - color = fmt.Sprintf("#%02x%02x%02x", red, green, blue) - } - } - if len(color) > 0 { - if field == "38" { - foreground = color - } else { - background = color - } - } - break FieldLoop - } - } - var colon string - if len(a.attributes) > 0 { - colon = ":" - } - if len(foreground) > 0 || len(background) > 0 || len(a.attributes) > 0 { - fmt.Fprintf(a.buffer, "[%s:%s%s%s]", foreground, background, colon, a.attributes) - } - } - a.state = ansiText - default: // Undefined byte. - a.state = ansiText // Abort CSI. - } - - // We just entered a substring/command sequence. - case ansiSubstring: - if r == 27 { // Most likely the end of the substring. - a.state = ansiEscape - } // Ignore all other characters. - - // "ansiText" and all others. - default: - if r == 27 { - // This is the start of an escape sequence. - a.state = ansiEscape - } else { - // Just a regular rune. Send to buffer. - if _, err := a.buffer.WriteRune(r); err != nil { - return 0, err - } - } - } - } - - // Write buffer to target writer. - n, err := a.buffer.WriteTo(a.Writer) - if err != nil { - return int(n), err - } - return len(text), nil -} - -// TranslateANSI replaces ANSI escape sequences found in the provided string -// with tview's color tags and returns the resulting string. -func TranslateANSI(text string) string { - var buffer bytes.Buffer - writer := ANSIWriter(&buffer) - writer.Write([]byte(text)) - return buffer.String() -} diff --git a/vendor/github.com/rivo/tview/application.go b/vendor/github.com/rivo/tview/application.go deleted file mode 100644 index 19aeeeb..0000000 --- a/vendor/github.com/rivo/tview/application.go +++ /dev/null @@ -1,737 +0,0 @@ -package tview - -import ( - "sync" - "time" - - "github.com/gdamore/tcell/v2" -) - -const ( - // The size of the event/update/redraw channels. - queueSize = 100 - - // The minimum time between two consecutive redraws. - redrawPause = 50 * time.Millisecond -) - -// DoubleClickInterval specifies the maximum time between clicks to register a -// double click rather than click. -var DoubleClickInterval = 500 * time.Millisecond - -// MouseAction indicates one of the actions the mouse is logically doing. -type MouseAction int16 - -// Available mouse actions. -const ( - MouseMove MouseAction = iota - MouseLeftDown - MouseLeftUp - MouseLeftClick - MouseLeftDoubleClick - MouseMiddleDown - MouseMiddleUp - MouseMiddleClick - MouseMiddleDoubleClick - MouseRightDown - MouseRightUp - MouseRightClick - MouseRightDoubleClick - MouseScrollUp - MouseScrollDown - MouseScrollLeft - MouseScrollRight -) - -// queuedUpdate represented the execution of f queued by -// Application.QueueUpdate(). The "done" channel receives exactly one element -// after f has executed. -type queuedUpdate struct { - f func() - done chan struct{} -} - -// Application represents the top node of an application. -// -// It is not strictly required to use this class as none of the other classes -// depend on it. However, it provides useful tools to set up an application and -// plays nicely with all widgets. -// -// The following command displays a primitive p on the screen until Ctrl-C is -// pressed: -// -// if err := tview.NewApplication().SetRoot(p, true).Run(); err != nil { -// panic(err) -// } -type Application struct { - sync.RWMutex - - // The application's screen. Apart from Run(), this variable should never be - // set directly. Always use the screenReplacement channel after calling - // Fini(), to set a new screen (or nil to stop the application). - screen tcell.Screen - - // The primitive which currently has the keyboard focus. - focus Primitive - - // The root primitive to be seen on the screen. - root Primitive - - // Whether or not the application resizes the root primitive. - rootFullscreen bool - - // Set to true if mouse events are enabled. - enableMouse bool - - // An optional capture function which receives a key event and returns the - // event to be forwarded to the default input handler (nil if nothing should - // be forwarded). - inputCapture func(event *tcell.EventKey) *tcell.EventKey - - // An optional callback function which is invoked just before the root - // primitive is drawn. - beforeDraw func(screen tcell.Screen) bool - - // An optional callback function which is invoked after the root primitive - // was drawn. - afterDraw func(screen tcell.Screen) - - // Used to send screen events from separate goroutine to main event loop - events chan tcell.Event - - // Functions queued from goroutines, used to serialize updates to primitives. - updates chan queuedUpdate - - // An object that the screen variable will be set to after Fini() was called. - // Use this channel to set a new screen object for the application - // (screen.Init() and draw() will be called implicitly). A value of nil will - // stop the application. - screenReplacement chan tcell.Screen - - // An optional capture function which receives a mouse event and returns the - // event to be forwarded to the default mouse handler (nil if nothing should - // be forwarded). - mouseCapture func(event *tcell.EventMouse, action MouseAction) (*tcell.EventMouse, MouseAction) - - mouseCapturingPrimitive Primitive // A Primitive returned by a MouseHandler which will capture future mouse events. - lastMouseX, lastMouseY int // The last position of the mouse. - mouseDownX, mouseDownY int // The position of the mouse when its button was last pressed. - lastMouseClick time.Time // The time when a mouse button was last clicked. - lastMouseButtons tcell.ButtonMask // The last mouse button state. -} - -// NewApplication creates and returns a new application. -func NewApplication() *Application { - return &Application{ - events: make(chan tcell.Event, queueSize), - updates: make(chan queuedUpdate, queueSize), - screenReplacement: make(chan tcell.Screen, 1), - } -} - -// SetInputCapture sets a function which captures all key events before they are -// forwarded to the key event handler of the primitive which currently has -// focus. This function can then choose to forward that key event (or a -// different one) by returning it or stop the key event processing by returning -// nil. -// -// Note that this also affects the default event handling of the application -// itself: Such a handler can intercept the Ctrl-C event which closes the -// application. -func (a *Application) SetInputCapture(capture func(event *tcell.EventKey) *tcell.EventKey) *Application { - a.inputCapture = capture - return a -} - -// GetInputCapture returns the function installed with SetInputCapture() or nil -// if no such function has been installed. -func (a *Application) GetInputCapture() func(event *tcell.EventKey) *tcell.EventKey { - return a.inputCapture -} - -// SetMouseCapture sets a function which captures mouse events (consisting of -// the original tcell mouse event and the semantic mouse action) before they are -// forwarded to the appropriate mouse event handler. This function can then -// choose to forward that event (or a different one) by returning it or stop -// the event processing by returning a nil mouse event. -func (a *Application) SetMouseCapture(capture func(event *tcell.EventMouse, action MouseAction) (*tcell.EventMouse, MouseAction)) *Application { - a.mouseCapture = capture - return a -} - -// GetMouseCapture returns the function installed with SetMouseCapture() or nil -// if no such function has been installed. -func (a *Application) GetMouseCapture() func(event *tcell.EventMouse, action MouseAction) (*tcell.EventMouse, MouseAction) { - return a.mouseCapture -} - -// SetScreen allows you to provide your own tcell.Screen object. For most -// applications, this is not needed and you should be familiar with -// tcell.Screen when using this function. -// -// This function is typically called before the first call to Run(). Init() need -// not be called on the screen. -func (a *Application) SetScreen(screen tcell.Screen) *Application { - if screen == nil { - return a // Invalid input. Do nothing. - } - - a.Lock() - if a.screen == nil { - // Run() has not been called yet. - a.screen = screen - a.Unlock() - return a - } - - // Run() is already in progress. Exchange screen. - oldScreen := a.screen - a.Unlock() - oldScreen.Fini() - a.screenReplacement <- screen - - return a -} - -// EnableMouse enables mouse events. -func (a *Application) EnableMouse(enable bool) *Application { - a.Lock() - defer a.Unlock() - if enable != a.enableMouse && a.screen != nil { - if enable { - a.screen.EnableMouse() - } else { - a.screen.DisableMouse() - } - } - a.enableMouse = enable - return a -} - -// Run starts the application and thus the event loop. This function returns -// when Stop() was called. -func (a *Application) Run() error { - var ( - err error - lastRedraw time.Time // The time the screen was last redrawn. - redrawTimer *time.Timer // A timer to schedule the next redraw. - ) - a.Lock() - - // Make a screen if there is none yet. - if a.screen == nil { - a.screen, err = tcell.NewScreen() - if err != nil { - a.Unlock() - return err - } - if err = a.screen.Init(); err != nil { - a.Unlock() - return err - } - if a.enableMouse { - a.screen.EnableMouse() - } - } - - // We catch panics to clean up because they mess up the terminal. - defer func() { - if p := recover(); p != nil { - if a.screen != nil { - a.screen.Fini() - } - panic(p) - } - }() - - // Draw the screen for the first time. - a.Unlock() - a.draw() - - // Separate loop to wait for screen events. - var wg sync.WaitGroup - wg.Add(1) - go func() { - defer wg.Done() - for { - a.RLock() - screen := a.screen - a.RUnlock() - if screen == nil { - // We have no screen. Let's stop. - a.QueueEvent(nil) - break - } - - // Wait for next event and queue it. - event := screen.PollEvent() - if event != nil { - // Regular event. Queue. - a.QueueEvent(event) - continue - } - - // A screen was finalized (event is nil). Wait for a new scren. - screen = <-a.screenReplacement - if screen == nil { - // No new screen. We're done. - a.QueueEvent(nil) - return - } - - // We have a new screen. Keep going. - a.Lock() - a.screen = screen - a.Unlock() - - // Initialize and draw this screen. - if err := screen.Init(); err != nil { - panic(err) - } - a.draw() - } - }() - - // Start event loop. -EventLoop: - for { - select { - case event := <-a.events: - if event == nil { - break EventLoop - } - - switch event := event.(type) { - case *tcell.EventKey: - a.RLock() - root := a.root - inputCapture := a.inputCapture - a.RUnlock() - - // Intercept keys. - var draw bool - if inputCapture != nil { - event = inputCapture(event) - if event == nil { - a.draw() - continue // Don't forward event. - } - draw = true - } - - // Ctrl-C closes the application. - if event.Key() == tcell.KeyCtrlC { - a.Stop() - } - - // Pass other key events to the root primitive. - if root != nil && root.HasFocus() { - if handler := root.InputHandler(); handler != nil { - handler(event, func(p Primitive) { - a.SetFocus(p) - }) - draw = true - } - } - - // Redraw. - if draw { - a.draw() - } - case *tcell.EventResize: - if time.Since(lastRedraw) < redrawPause { - if redrawTimer != nil { - redrawTimer.Stop() - } - redrawTimer = time.AfterFunc(redrawPause, func() { - a.events <- event - }) - } - a.RLock() - screen := a.screen - a.RUnlock() - if screen == nil { - continue - } - lastRedraw = time.Now() - screen.Clear() - a.draw() - case *tcell.EventMouse: - consumed, isMouseDownAction := a.fireMouseActions(event) - if consumed { - a.draw() - } - a.lastMouseButtons = event.Buttons() - if isMouseDownAction { - a.mouseDownX, a.mouseDownY = event.Position() - } - } - - // If we have updates, now is the time to execute them. - case update := <-a.updates: - update.f() - update.done <- struct{}{} - } - } - - // Wait for the event loop to finish. - wg.Wait() - a.screen = nil - - return nil -} - -// fireMouseActions analyzes the provided mouse event, derives mouse actions -// from it and then forwards them to the corresponding primitives. -func (a *Application) fireMouseActions(event *tcell.EventMouse) (consumed, isMouseDownAction bool) { - // We want to relay follow-up events to the same target primitive. - var targetPrimitive Primitive - - // Helper function to fire a mouse action. - fire := func(action MouseAction) { - switch action { - case MouseLeftDown, MouseMiddleDown, MouseRightDown: - isMouseDownAction = true - } - - // Intercept event. - if a.mouseCapture != nil { - event, action = a.mouseCapture(event, action) - if event == nil { - consumed = true - return // Don't forward event. - } - } - - // Determine the target primitive. - var primitive, capturingPrimitive Primitive - if a.mouseCapturingPrimitive != nil { - primitive = a.mouseCapturingPrimitive - targetPrimitive = a.mouseCapturingPrimitive - } else if targetPrimitive != nil { - primitive = targetPrimitive - } else { - primitive = a.root - } - if primitive != nil { - if handler := primitive.MouseHandler(); handler != nil { - var wasConsumed bool - wasConsumed, capturingPrimitive = handler(action, event, func(p Primitive) { - a.SetFocus(p) - }) - if wasConsumed { - consumed = true - } - } - } - a.mouseCapturingPrimitive = capturingPrimitive - } - - x, y := event.Position() - buttons := event.Buttons() - clickMoved := x != a.mouseDownX || y != a.mouseDownY - buttonChanges := buttons ^ a.lastMouseButtons - - if x != a.lastMouseX || y != a.lastMouseY { - fire(MouseMove) - a.lastMouseX = x - a.lastMouseY = y - } - - for _, buttonEvent := range []struct { - button tcell.ButtonMask - down, up, click, dclick MouseAction - }{ - {tcell.Button1, MouseLeftDown, MouseLeftUp, MouseLeftClick, MouseLeftDoubleClick}, - {tcell.Button2, MouseMiddleDown, MouseMiddleUp, MouseMiddleClick, MouseMiddleDoubleClick}, - {tcell.Button3, MouseRightDown, MouseRightUp, MouseRightClick, MouseRightDoubleClick}, - } { - if buttonChanges&buttonEvent.button != 0 { - if buttons&buttonEvent.button != 0 { - fire(buttonEvent.down) - } else { - fire(buttonEvent.up) - if !clickMoved { - if a.lastMouseClick.Add(DoubleClickInterval).Before(time.Now()) { - fire(buttonEvent.click) - a.lastMouseClick = time.Now() - } else { - fire(buttonEvent.dclick) - a.lastMouseClick = time.Time{} // reset - } - } - } - } - } - - for _, wheelEvent := range []struct { - button tcell.ButtonMask - action MouseAction - }{ - {tcell.WheelUp, MouseScrollUp}, - {tcell.WheelDown, MouseScrollDown}, - {tcell.WheelLeft, MouseScrollLeft}, - {tcell.WheelRight, MouseScrollRight}} { - if buttons&wheelEvent.button != 0 { - fire(wheelEvent.action) - } - } - - return consumed, isMouseDownAction -} - -// Stop stops the application, causing Run() to return. -func (a *Application) Stop() { - a.Lock() - defer a.Unlock() - screen := a.screen - if screen == nil { - return - } - a.screen = nil - screen.Fini() - a.screenReplacement <- nil -} - -// Suspend temporarily suspends the application by exiting terminal UI mode and -// invoking the provided function "f". When "f" returns, terminal UI mode is -// entered again and the application resumes. -// -// A return value of true indicates that the application was suspended and "f" -// was called. If false is returned, the application was already suspended, -// terminal UI mode was not exited, and "f" was not called. -func (a *Application) Suspend(f func()) bool { - a.RLock() - screen := a.screen - a.RUnlock() - if screen == nil { - return false // Screen has not yet been initialized. - } - - // Enter suspended mode. - screen.Fini() - - // Wait for "f" to return. - f() - - // If stop was called in the meantime (a.screen is nil), we're done already. - a.RLock() - screen = a.screen - a.RUnlock() - if screen == nil { - return true - } - - // Make a new screen. - var err error - screen, err = tcell.NewScreen() - if err != nil { - panic(err) - } - a.screenReplacement <- screen - // One key event will get lost, see https://github.com/gdamore/tcell/issues/194 - - // Continue application loop. - return true -} - -// Draw refreshes the screen (during the next update cycle). It calls the Draw() -// function of the application's root primitive and then syncs the screen -// buffer. It is almost never necessary to call this function. Please see -// https://github.com/rivo/tview/wiki/Concurrency for details. -func (a *Application) Draw() *Application { - a.QueueUpdate(func() { - a.draw() - }) - return a -} - -// ForceDraw refreshes the screen immediately. Use this function with caution as -// it may lead to race conditions with updates to primitives in other -// goroutines. It is always preferrable to use Draw() instead. Never call this -// function from a goroutine. -// -// It is safe to call this function during queued updates and direct event -// handling. -func (a *Application) ForceDraw() *Application { - return a.draw() -} - -// draw actually does what Draw() promises to do. -func (a *Application) draw() *Application { - a.Lock() - defer a.Unlock() - - screen := a.screen - root := a.root - fullscreen := a.rootFullscreen - before := a.beforeDraw - after := a.afterDraw - - // Maybe we're not ready yet or not anymore. - if screen == nil || root == nil { - return a - } - - // Resize if requested. - if fullscreen && root != nil { - width, height := screen.Size() - root.SetRect(0, 0, width, height) - } - - // Call before handler if there is one. - if before != nil { - if before(screen) { - screen.Show() - return a - } - } - - // Draw all primitives. - root.Draw(screen) - - // Call after handler if there is one. - if after != nil { - after(screen) - } - - // Sync screen. - screen.Show() - - return a -} - -// SetBeforeDrawFunc installs a callback function which is invoked just before -// the root primitive is drawn during screen updates. If the function returns -// true, drawing will not continue, i.e. the root primitive will not be drawn -// (and an after-draw-handler will not be called). -// -// Note that the screen is not cleared by the application. To clear the screen, -// you may call screen.Clear(). -// -// Provide nil to uninstall the callback function. -func (a *Application) SetBeforeDrawFunc(handler func(screen tcell.Screen) bool) *Application { - a.beforeDraw = handler - return a -} - -// GetBeforeDrawFunc returns the callback function installed with -// SetBeforeDrawFunc() or nil if none has been installed. -func (a *Application) GetBeforeDrawFunc() func(screen tcell.Screen) bool { - return a.beforeDraw -} - -// SetAfterDrawFunc installs a callback function which is invoked after the root -// primitive was drawn during screen updates. -// -// Provide nil to uninstall the callback function. -func (a *Application) SetAfterDrawFunc(handler func(screen tcell.Screen)) *Application { - a.afterDraw = handler - return a -} - -// GetAfterDrawFunc returns the callback function installed with -// SetAfterDrawFunc() or nil if none has been installed. -func (a *Application) GetAfterDrawFunc() func(screen tcell.Screen) { - return a.afterDraw -} - -// SetRoot sets the root primitive for this application. If "fullscreen" is set -// to true, the root primitive's position will be changed to fill the screen. -// -// This function must be called at least once or nothing will be displayed when -// the application starts. -// -// It also calls SetFocus() on the primitive. -func (a *Application) SetRoot(root Primitive, fullscreen bool) *Application { - a.Lock() - a.root = root - a.rootFullscreen = fullscreen - if a.screen != nil { - a.screen.Clear() - } - a.Unlock() - - a.SetFocus(root) - - return a -} - -// ResizeToFullScreen resizes the given primitive such that it fills the entire -// screen. -func (a *Application) ResizeToFullScreen(p Primitive) *Application { - a.RLock() - width, height := a.screen.Size() - a.RUnlock() - p.SetRect(0, 0, width, height) - return a -} - -// SetFocus sets the focus on a new primitive. All key events will be redirected -// to that primitive. Callers must ensure that the primitive will handle key -// events. -// -// Blur() will be called on the previously focused primitive. Focus() will be -// called on the new primitive. -func (a *Application) SetFocus(p Primitive) *Application { - a.Lock() - if a.focus != nil { - a.focus.Blur() - } - a.focus = p - if a.screen != nil { - a.screen.HideCursor() - } - a.Unlock() - if p != nil { - p.Focus(func(p Primitive) { - a.SetFocus(p) - }) - } - - return a -} - -// GetFocus returns the primitive which has the current focus. If none has it, -// nil is returned. -func (a *Application) GetFocus() Primitive { - a.RLock() - defer a.RUnlock() - return a.focus -} - -// QueueUpdate is used to synchronize access to primitives from non-main -// goroutines. The provided function will be executed as part of the event loop -// and thus will not cause race conditions with other such update functions or -// the Draw() function. -// -// Note that Draw() is not implicitly called after the execution of f as that -// may not be desirable. You can call Draw() from f if the screen should be -// refreshed after each update. Alternatively, use QueueUpdateDraw() to follow -// up with an immediate refresh of the screen. -// -// This function returns after f has executed. -func (a *Application) QueueUpdate(f func()) *Application { - ch := make(chan struct{}) - a.updates <- queuedUpdate{f: f, done: ch} - <-ch - return a -} - -// QueueUpdateDraw works like QueueUpdate() except it refreshes the screen -// immediately after executing f. -func (a *Application) QueueUpdateDraw(f func()) *Application { - a.QueueUpdate(func() { - f() - a.draw() - }) - return a -} - -// QueueEvent sends an event to the Application event loop. -// -// It is not recommended for event to be nil. -func (a *Application) QueueEvent(event tcell.Event) *Application { - a.events <- event - return a -} diff --git a/vendor/github.com/rivo/tview/borders.go b/vendor/github.com/rivo/tview/borders.go deleted file mode 100644 index 946c878..0000000 --- a/vendor/github.com/rivo/tview/borders.go +++ /dev/null @@ -1,45 +0,0 @@ -package tview - -// Borders defines various borders used when primitives are drawn. -// These may be changed to accommodate a different look and feel. -var Borders = struct { - Horizontal rune - Vertical rune - TopLeft rune - TopRight rune - BottomLeft rune - BottomRight rune - - LeftT rune - RightT rune - TopT rune - BottomT rune - Cross rune - - HorizontalFocus rune - VerticalFocus rune - TopLeftFocus rune - TopRightFocus rune - BottomLeftFocus rune - BottomRightFocus rune -}{ - Horizontal: BoxDrawingsLightHorizontal, - Vertical: BoxDrawingsLightVertical, - TopLeft: BoxDrawingsLightDownAndRight, - TopRight: BoxDrawingsLightDownAndLeft, - BottomLeft: BoxDrawingsLightUpAndRight, - BottomRight: BoxDrawingsLightUpAndLeft, - - LeftT: BoxDrawingsLightVerticalAndRight, - RightT: BoxDrawingsLightVerticalAndLeft, - TopT: BoxDrawingsLightDownAndHorizontal, - BottomT: BoxDrawingsLightUpAndHorizontal, - Cross: BoxDrawingsLightVerticalAndHorizontal, - - HorizontalFocus: BoxDrawingsDoubleHorizontal, - VerticalFocus: BoxDrawingsDoubleVertical, - TopLeftFocus: BoxDrawingsDoubleDownAndRight, - TopRightFocus: BoxDrawingsDoubleDownAndLeft, - BottomLeftFocus: BoxDrawingsDoubleUpAndRight, - BottomRightFocus: BoxDrawingsDoubleUpAndLeft, -} diff --git a/vendor/github.com/rivo/tview/box.go b/vendor/github.com/rivo/tview/box.go deleted file mode 100644 index 62bc896..0000000 --- a/vendor/github.com/rivo/tview/box.go +++ /dev/null @@ -1,410 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// Box implements the Primitive interface with an empty background and optional -// elements such as a border and a title. Box itself does not hold any content -// but serves as the superclass of all other primitives. Subclasses add their -// own content, typically (but not necessarily) keeping their content within the -// box's rectangle. -// -// Box provides a number of utility functions available to all primitives. -// -// See https://github.com/rivo/tview/wiki/Box for an example. -type Box struct { - // The position of the rect. - x, y, width, height int - - // The inner rect reserved for the box's content. - innerX, innerY, innerWidth, innerHeight int - - // Border padding. - paddingTop, paddingBottom, paddingLeft, paddingRight int - - // The box's background color. - backgroundColor tcell.Color - - // Whether or not a border is drawn, reducing the box's space for content by - // two in width and height. - border bool - - // The border style. - borderStyle tcell.Style - - // The title. Only visible if there is a border, too. - title string - - // The color of the title. - titleColor tcell.Color - - // The alignment of the title. - titleAlign int - - // Whether or not this box has focus. - hasFocus bool - - // An optional capture function which receives a key event and returns the - // event to be forwarded to the primitive's default input handler (nil if - // nothing should be forwarded). - inputCapture func(event *tcell.EventKey) *tcell.EventKey - - // An optional function which is called before the box is drawn. - draw func(screen tcell.Screen, x, y, width, height int) (int, int, int, int) - - // An optional capture function which receives a mouse event and returns the - // event to be forwarded to the primitive's default mouse event handler (at - // least one nil if nothing should be forwarded). - mouseCapture func(action MouseAction, event *tcell.EventMouse) (MouseAction, *tcell.EventMouse) -} - -// NewBox returns a Box without a border. -func NewBox() *Box { - b := &Box{ - width: 15, - height: 10, - innerX: -1, // Mark as uninitialized. - backgroundColor: Styles.PrimitiveBackgroundColor, - borderStyle: tcell.StyleDefault.Foreground(Styles.BorderColor), - titleColor: Styles.TitleColor, - titleAlign: AlignCenter, - } - return b -} - -// SetBorderPadding sets the size of the borders around the box content. -func (b *Box) SetBorderPadding(top, bottom, left, right int) *Box { - b.paddingTop, b.paddingBottom, b.paddingLeft, b.paddingRight = top, bottom, left, right - return b -} - -// GetRect returns the current position of the rectangle, x, y, width, and -// height. -func (b *Box) GetRect() (int, int, int, int) { - return b.x, b.y, b.width, b.height -} - -// GetInnerRect returns the position of the inner rectangle (x, y, width, -// height), without the border and without any padding. Width and height values -// will clamp to 0 and thus never be negative. -func (b *Box) GetInnerRect() (int, int, int, int) { - if b.innerX >= 0 { - return b.innerX, b.innerY, b.innerWidth, b.innerHeight - } - x, y, width, height := b.GetRect() - if b.border { - x++ - y++ - width -= 2 - height -= 2 - } - x, y, width, height = x+b.paddingLeft, - y+b.paddingTop, - width-b.paddingLeft-b.paddingRight, - height-b.paddingTop-b.paddingBottom - if width < 0 { - width = 0 - } - if height < 0 { - height = 0 - } - return x, y, width, height -} - -// SetRect sets a new position of the primitive. Note that this has no effect -// if this primitive is part of a layout (e.g. Flex, Grid) or if it was added -// like this: -// -// application.SetRoot(b, true) -func (b *Box) SetRect(x, y, width, height int) { - b.x = x - b.y = y - b.width = width - b.height = height - b.innerX = -1 // Mark inner rect as uninitialized. -} - -// SetDrawFunc sets a callback function which is invoked after the box primitive -// has been drawn. This allows you to add a more individual style to the box -// (and all primitives which extend it). -// -// The function is provided with the box's dimensions (set via SetRect()). It -// must return the box's inner dimensions (x, y, width, height) which will be -// returned by GetInnerRect(), used by descendent primitives to draw their own -// content. -func (b *Box) SetDrawFunc(handler func(screen tcell.Screen, x, y, width, height int) (int, int, int, int)) *Box { - b.draw = handler - return b -} - -// GetDrawFunc returns the callback function which was installed with -// SetDrawFunc() or nil if no such function has been installed. -func (b *Box) GetDrawFunc() func(screen tcell.Screen, x, y, width, height int) (int, int, int, int) { - return b.draw -} - -// WrapInputHandler wraps an input handler (see InputHandler()) with the -// functionality to capture input (see SetInputCapture()) before passing it -// on to the provided (default) input handler. -// -// This is only meant to be used by subclassing primitives. -func (b *Box) WrapInputHandler(inputHandler func(*tcell.EventKey, func(p Primitive))) func(*tcell.EventKey, func(p Primitive)) { - return func(event *tcell.EventKey, setFocus func(p Primitive)) { - if b.inputCapture != nil { - event = b.inputCapture(event) - } - if event != nil && inputHandler != nil { - inputHandler(event, setFocus) - } - } -} - -// InputHandler returns nil. -func (b *Box) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return b.WrapInputHandler(nil) -} - -// SetInputCapture installs a function which captures key events before they are -// forwarded to the primitive's default key event handler. This function can -// then choose to forward that key event (or a different one) to the default -// handler by returning it. If nil is returned, the default handler will not -// be called. -// -// Providing a nil handler will remove a previously existing handler. -// -// Note that this function will not have an effect on primitives composed of -// other primitives, such as Form, Flex, or Grid. Key events are only captured -// by the primitives that have focus (e.g. InputField) and only one primitive -// can have focus at a time. Composing primitives such as Form pass the focus on -// to their contained primitives and thus never receive any key events -// themselves. Therefore, they cannot intercept key events. -func (b *Box) SetInputCapture(capture func(event *tcell.EventKey) *tcell.EventKey) *Box { - b.inputCapture = capture - return b -} - -// GetInputCapture returns the function installed with SetInputCapture() or nil -// if no such function has been installed. -func (b *Box) GetInputCapture() func(event *tcell.EventKey) *tcell.EventKey { - return b.inputCapture -} - -// WrapMouseHandler wraps a mouse event handler (see MouseHandler()) with the -// functionality to capture mouse events (see SetMouseCapture()) before passing -// them on to the provided (default) event handler. -// -// This is only meant to be used by subclassing primitives. -func (b *Box) WrapMouseHandler(mouseHandler func(MouseAction, *tcell.EventMouse, func(p Primitive)) (bool, Primitive)) func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if b.mouseCapture != nil { - action, event = b.mouseCapture(action, event) - } - if event != nil && mouseHandler != nil { - consumed, capture = mouseHandler(action, event, setFocus) - } - return - } -} - -// MouseHandler returns nil. -func (b *Box) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return b.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if action == MouseLeftClick && b.InRect(event.Position()) { - setFocus(b) - consumed = true - } - return - }) -} - -// SetMouseCapture sets a function which captures mouse events (consisting of -// the original tcell mouse event and the semantic mouse action) before they are -// forwarded to the primitive's default mouse event handler. This function can -// then choose to forward that event (or a different one) by returning it or -// returning a nil mouse event, in which case the default handler will not be -// called. -// -// Providing a nil handler will remove a previously existing handler. -func (b *Box) SetMouseCapture(capture func(action MouseAction, event *tcell.EventMouse) (MouseAction, *tcell.EventMouse)) *Box { - b.mouseCapture = capture - return b -} - -// InRect returns true if the given coordinate is within the bounds of the box's -// rectangle. -func (b *Box) InRect(x, y int) bool { - rectX, rectY, width, height := b.GetRect() - return x >= rectX && x < rectX+width && y >= rectY && y < rectY+height -} - -// GetMouseCapture returns the function installed with SetMouseCapture() or nil -// if no such function has been installed. -func (b *Box) GetMouseCapture() func(action MouseAction, event *tcell.EventMouse) (MouseAction, *tcell.EventMouse) { - return b.mouseCapture -} - -// SetBackgroundColor sets the box's background color. -func (b *Box) SetBackgroundColor(color tcell.Color) *Box { - b.backgroundColor = color - return b -} - -// SetBorder sets the flag indicating whether or not the box should have a -// border. -func (b *Box) SetBorder(show bool) *Box { - b.border = show - return b -} - -// SetBorderColor sets the box's border color. -func (b *Box) SetBorderColor(color tcell.Color) *Box { - b.borderStyle = b.borderStyle.Foreground(color) - return b -} - -// SetBorderAttributes sets the border's style attributes. You can combine -// different attributes using bitmask operations: -// -// box.SetBorderAttributes(tcell.AttrUnderline | tcell.AttrBold) -func (b *Box) SetBorderAttributes(attr tcell.AttrMask) *Box { - b.borderStyle = b.borderStyle.Attributes(attr) - return b -} - -// GetBorderAttributes returns the border's style attributes. -func (b *Box) GetBorderAttributes() tcell.AttrMask { - _, _, attr := b.borderStyle.Decompose() - return attr -} - -// GetBorderColor returns the box's border color. -func (b *Box) GetBorderColor() tcell.Color { - color, _, _ := b.borderStyle.Decompose() - return color -} - -// GetBackgroundColor returns the box's background color. -func (b *Box) GetBackgroundColor() tcell.Color { - return b.backgroundColor -} - -// SetTitle sets the box's title. -func (b *Box) SetTitle(title string) *Box { - b.title = title - return b -} - -// GetTitle returns the box's current title. -func (b *Box) GetTitle() string { - return b.title -} - -// SetTitleColor sets the box's title color. -func (b *Box) SetTitleColor(color tcell.Color) *Box { - b.titleColor = color - return b -} - -// SetTitleAlign sets the alignment of the title, one of AlignLeft, AlignCenter, -// or AlignRight. -func (b *Box) SetTitleAlign(align int) *Box { - b.titleAlign = align - return b -} - -// Draw draws this primitive onto the screen. -func (b *Box) Draw(screen tcell.Screen) { - b.DrawForSubclass(screen, b) -} - -// DrawForSubclass draws this box under the assumption that primitive p is a -// subclass of this box. This is needed e.g. to draw proper box frames which -// depend on the subclass's focus. -// -// Only call this function from your own custom primitives. It is not needed in -// applications that have no custom primitives. -func (b *Box) DrawForSubclass(screen tcell.Screen, p Primitive) { - // Don't draw anything if there is no space. - if b.width <= 0 || b.height <= 0 { - return - } - - def := tcell.StyleDefault - - // Fill background. - background := def.Background(b.backgroundColor) - if b.backgroundColor != tcell.ColorDefault { - for y := b.y; y < b.y+b.height; y++ { - for x := b.x; x < b.x+b.width; x++ { - screen.SetContent(x, y, ' ', nil, background) - } - } - } - - // Draw border. - if b.border && b.width >= 2 && b.height >= 2 { - var vertical, horizontal, topLeft, topRight, bottomLeft, bottomRight rune - if p.HasFocus() { - horizontal = Borders.HorizontalFocus - vertical = Borders.VerticalFocus - topLeft = Borders.TopLeftFocus - topRight = Borders.TopRightFocus - bottomLeft = Borders.BottomLeftFocus - bottomRight = Borders.BottomRightFocus - } else { - horizontal = Borders.Horizontal - vertical = Borders.Vertical - topLeft = Borders.TopLeft - topRight = Borders.TopRight - bottomLeft = Borders.BottomLeft - bottomRight = Borders.BottomRight - } - for x := b.x + 1; x < b.x+b.width-1; x++ { - screen.SetContent(x, b.y, horizontal, nil, b.borderStyle) - screen.SetContent(x, b.y+b.height-1, horizontal, nil, b.borderStyle) - } - for y := b.y + 1; y < b.y+b.height-1; y++ { - screen.SetContent(b.x, y, vertical, nil, b.borderStyle) - screen.SetContent(b.x+b.width-1, y, vertical, nil, b.borderStyle) - } - screen.SetContent(b.x, b.y, topLeft, nil, b.borderStyle) - screen.SetContent(b.x+b.width-1, b.y, topRight, nil, b.borderStyle) - screen.SetContent(b.x, b.y+b.height-1, bottomLeft, nil, b.borderStyle) - screen.SetContent(b.x+b.width-1, b.y+b.height-1, bottomRight, nil, b.borderStyle) - - // Draw title. - if b.title != "" && b.width >= 4 { - printed, _ := Print(screen, b.title, b.x+1, b.y, b.width-2, b.titleAlign, b.titleColor) - if len(b.title)-printed > 0 && printed > 0 { - _, _, style, _ := screen.GetContent(b.x+b.width-2, b.y) - fg, _, _ := style.Decompose() - Print(screen, string(SemigraphicsHorizontalEllipsis), b.x+b.width-2, b.y, 1, AlignLeft, fg) - } - } - } - - // Call custom draw function. - if b.draw != nil { - b.innerX, b.innerY, b.innerWidth, b.innerHeight = b.draw(screen, b.x, b.y, b.width, b.height) - } else { - // Remember the inner rect. - b.innerX = -1 - b.innerX, b.innerY, b.innerWidth, b.innerHeight = b.GetInnerRect() - } -} - -// Focus is called when this primitive receives focus. -func (b *Box) Focus(delegate func(p Primitive)) { - b.hasFocus = true -} - -// Blur is called when this primitive loses focus. -func (b *Box) Blur() { - b.hasFocus = false -} - -// HasFocus returns whether or not this primitive has focus. -func (b *Box) HasFocus() bool { - return b.hasFocus -} diff --git a/vendor/github.com/rivo/tview/button.go b/vendor/github.com/rivo/tview/button.go deleted file mode 100644 index 97e9ff5..0000000 --- a/vendor/github.com/rivo/tview/button.go +++ /dev/null @@ -1,157 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// Button is labeled box that triggers an action when selected. -// -// See https://github.com/rivo/tview/wiki/Button for an example. -type Button struct { - *Box - - // The text to be displayed before the input area. - label string - - // The label color. - labelColor tcell.Color - - // The label color when the button is in focus. - labelColorActivated tcell.Color - - // The background color when the button is in focus. - backgroundColorActivated tcell.Color - - // An optional function which is called when the button was selected. - selected func() - - // An optional function which is called when the user leaves the button. A - // key is provided indicating which key was pressed to leave (tab or backtab). - blur func(tcell.Key) -} - -// NewButton returns a new input field. -func NewButton(label string) *Button { - box := NewBox().SetBackgroundColor(Styles.ContrastBackgroundColor) - box.SetRect(0, 0, TaggedStringWidth(label)+4, 1) - return &Button{ - Box: box, - label: label, - labelColor: Styles.PrimaryTextColor, - labelColorActivated: Styles.InverseTextColor, - backgroundColorActivated: Styles.PrimaryTextColor, - } -} - -// SetLabel sets the button text. -func (b *Button) SetLabel(label string) *Button { - b.label = label - return b -} - -// GetLabel returns the button text. -func (b *Button) GetLabel() string { - return b.label -} - -// SetLabelColor sets the color of the button text. -func (b *Button) SetLabelColor(color tcell.Color) *Button { - b.labelColor = color - return b -} - -// SetLabelColorActivated sets the color of the button text when the button is -// in focus. -func (b *Button) SetLabelColorActivated(color tcell.Color) *Button { - b.labelColorActivated = color - return b -} - -// SetBackgroundColorActivated sets the background color of the button text when -// the button is in focus. -func (b *Button) SetBackgroundColorActivated(color tcell.Color) *Button { - b.backgroundColorActivated = color - return b -} - -// SetSelectedFunc sets a handler which is called when the button was selected. -func (b *Button) SetSelectedFunc(handler func()) *Button { - b.selected = handler - return b -} - -// SetBlurFunc sets a handler which is called when the user leaves the button. -// The callback function is provided with the key that was pressed, which is one -// of the following: -// -// - KeyEscape: Leaving the button with no specific direction. -// - KeyTab: Move to the next field. -// - KeyBacktab: Move to the previous field. -func (b *Button) SetBlurFunc(handler func(key tcell.Key)) *Button { - b.blur = handler - return b -} - -// Draw draws this primitive onto the screen. -func (b *Button) Draw(screen tcell.Screen) { - // Draw the box. - borderColor := b.GetBorderColor() - backgroundColor := b.GetBackgroundColor() - if b.HasFocus() { - b.SetBackgroundColor(b.backgroundColorActivated) - b.SetBorderColor(b.labelColorActivated) - defer func() { - b.SetBorderColor(borderColor) - }() - } - b.Box.DrawForSubclass(screen, b) - b.backgroundColor = backgroundColor - - // Draw label. - x, y, width, height := b.GetInnerRect() - if width > 0 && height > 0 { - y = y + height/2 - labelColor := b.labelColor - if b.HasFocus() { - labelColor = b.labelColorActivated - } - Print(screen, b.label, x, y, width, AlignCenter, labelColor) - } -} - -// InputHandler returns the handler for this primitive. -func (b *Button) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return b.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - // Process key event. - switch key := event.Key(); key { - case tcell.KeyEnter: // Selected. - if b.selected != nil { - b.selected() - } - case tcell.KeyBacktab, tcell.KeyTab, tcell.KeyEscape: // Leave. No action. - if b.blur != nil { - b.blur(key) - } - } - }) -} - -// MouseHandler returns the mouse handler for this primitive. -func (b *Button) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return b.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if !b.InRect(event.Position()) { - return false, nil - } - - // Process mouse event. - if action == MouseLeftClick { - setFocus(b) - if b.selected != nil { - b.selected() - } - consumed = true - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/checkbox.go b/vendor/github.com/rivo/tview/checkbox.go deleted file mode 100644 index c494088..0000000 --- a/vendor/github.com/rivo/tview/checkbox.go +++ /dev/null @@ -1,240 +0,0 @@ -package tview - -import ( - "strings" - - "github.com/gdamore/tcell/v2" -) - -// Checkbox implements a simple box for boolean values which can be checked and -// unchecked. -// -// See https://github.com/rivo/tview/wiki/Checkbox for an example. -type Checkbox struct { - *Box - - // Whether or not this box is checked. - checked bool - - // The text to be displayed before the input area. - label string - - // The screen width of the label area. A value of 0 means use the width of - // the label text. - labelWidth int - - // The label color. - labelColor tcell.Color - - // The background color of the input area. - fieldBackgroundColor tcell.Color - - // The text color of the input area. - fieldTextColor tcell.Color - - // The string use to display a checked box. - checkedString string - - // An optional function which is called when the user changes the checked - // state of this checkbox. - changed func(checked bool) - - // An optional function which is called when the user indicated that they - // are done entering text. The key which was pressed is provided (tab, - // shift-tab, or escape). - done func(tcell.Key) - - // A callback function set by the Form class and called when the user leaves - // this form item. - finished func(tcell.Key) -} - -// NewCheckbox returns a new input field. -func NewCheckbox() *Checkbox { - return &Checkbox{ - Box: NewBox(), - labelColor: Styles.SecondaryTextColor, - fieldBackgroundColor: Styles.ContrastBackgroundColor, - fieldTextColor: Styles.PrimaryTextColor, - checkedString: "X", - } -} - -// SetChecked sets the state of the checkbox. -func (c *Checkbox) SetChecked(checked bool) *Checkbox { - c.checked = checked - return c -} - -// IsChecked returns whether or not the box is checked. -func (c *Checkbox) IsChecked() bool { - return c.checked -} - -// SetLabel sets the text to be displayed before the input area. -func (c *Checkbox) SetLabel(label string) *Checkbox { - c.label = label - return c -} - -// GetLabel returns the text to be displayed before the input area. -func (c *Checkbox) GetLabel() string { - return c.label -} - -// SetLabelWidth sets the screen width of the label. A value of 0 will cause the -// primitive to use the width of the label string. -func (c *Checkbox) SetLabelWidth(width int) *Checkbox { - c.labelWidth = width - return c -} - -// SetLabelColor sets the color of the label. -func (c *Checkbox) SetLabelColor(color tcell.Color) *Checkbox { - c.labelColor = color - return c -} - -// SetFieldBackgroundColor sets the background color of the input area. -func (c *Checkbox) SetFieldBackgroundColor(color tcell.Color) *Checkbox { - c.fieldBackgroundColor = color - return c -} - -// SetFieldTextColor sets the text color of the input area. -func (c *Checkbox) SetFieldTextColor(color tcell.Color) *Checkbox { - c.fieldTextColor = color - return c -} - -// SetCheckedString sets the string to be displayed when the checkbox is -// checked (defaults to "X"). -func (c *Checkbox) SetCheckedString(checked string) *Checkbox { - c.checkedString = checked - return c -} - -// SetFormAttributes sets attributes shared by all form items. -func (c *Checkbox) SetFormAttributes(labelWidth int, labelColor, bgColor, fieldTextColor, fieldBgColor tcell.Color) FormItem { - c.labelWidth = labelWidth - c.labelColor = labelColor - c.backgroundColor = bgColor - c.fieldTextColor = fieldTextColor - c.fieldBackgroundColor = fieldBgColor - return c -} - -// GetFieldWidth returns this primitive's field width. -func (c *Checkbox) GetFieldWidth() int { - return 1 -} - -// SetChangedFunc sets a handler which is called when the checked state of this -// checkbox was changed by the user. The handler function receives the new -// state. -func (c *Checkbox) SetChangedFunc(handler func(checked bool)) *Checkbox { - c.changed = handler - return c -} - -// SetDoneFunc sets a handler which is called when the user is done using the -// checkbox. The callback function is provided with the key that was pressed, -// which is one of the following: -// -// - KeyEscape: Abort text input. -// - KeyTab: Move to the next field. -// - KeyBacktab: Move to the previous field. -func (c *Checkbox) SetDoneFunc(handler func(key tcell.Key)) *Checkbox { - c.done = handler - return c -} - -// SetFinishedFunc sets a callback invoked when the user leaves this form item. -func (c *Checkbox) SetFinishedFunc(handler func(key tcell.Key)) FormItem { - c.finished = handler - return c -} - -// Draw draws this primitive onto the screen. -func (c *Checkbox) Draw(screen tcell.Screen) { - c.Box.DrawForSubclass(screen, c) - - // Prepare - x, y, width, height := c.GetInnerRect() - rightLimit := x + width - if height < 1 || rightLimit <= x { - return - } - - // Draw label. - if c.labelWidth > 0 { - labelWidth := c.labelWidth - if labelWidth > rightLimit-x { - labelWidth = rightLimit - x - } - Print(screen, c.label, x, y, labelWidth, AlignLeft, c.labelColor) - x += labelWidth - } else { - _, drawnWidth := Print(screen, c.label, x, y, rightLimit-x, AlignLeft, c.labelColor) - x += drawnWidth - } - - // Draw checkbox. - fieldStyle := tcell.StyleDefault.Background(c.fieldBackgroundColor).Foreground(c.fieldTextColor) - if c.HasFocus() { - fieldStyle = fieldStyle.Background(c.fieldTextColor).Foreground(c.fieldBackgroundColor) - } - checkboxWidth := stringWidth(c.checkedString) - checkedString := c.checkedString - if !c.checked { - checkedString = strings.Repeat(" ", checkboxWidth) - } - printWithStyle(screen, checkedString, x, y, checkboxWidth, AlignLeft, fieldStyle) -} - -// InputHandler returns the handler for this primitive. -func (c *Checkbox) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return c.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - // Process key event. - switch key := event.Key(); key { - case tcell.KeyRune, tcell.KeyEnter: // Check. - if key == tcell.KeyRune && event.Rune() != ' ' { - break - } - c.checked = !c.checked - if c.changed != nil { - c.changed(c.checked) - } - case tcell.KeyTab, tcell.KeyBacktab, tcell.KeyEscape: // We're done. - if c.done != nil { - c.done(key) - } - if c.finished != nil { - c.finished(key) - } - } - }) -} - -// MouseHandler returns the mouse handler for this primitive. -func (c *Checkbox) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return c.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - x, y := event.Position() - _, rectY, _, _ := c.GetInnerRect() - if !c.InRect(x, y) { - return false, nil - } - - // Process mouse event. - if action == MouseLeftClick && y == rectY { - setFocus(c) - c.checked = !c.checked - if c.changed != nil { - c.changed(c.checked) - } - consumed = true - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/demos/box/README.md b/vendor/github.com/rivo/tview/demos/box/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/box/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/box/main.go b/vendor/github.com/rivo/tview/demos/box/main.go deleted file mode 100644 index 9de4b8d..0000000 --- a/vendor/github.com/rivo/tview/demos/box/main.go +++ /dev/null @@ -1,17 +0,0 @@ -// Demo code for the Box primitive. -package main - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -func main() { - box := tview.NewBox(). - SetBorder(true). - SetBorderAttributes(tcell.AttrBold). - SetTitle("A [red]c[yellow]o[green]l[darkcyan]o[blue]r[darkmagenta]f[red]u[yellow]l[white] [black:red]c[:yellow]o[:green]l[:darkcyan]o[:blue]r[:darkmagenta]f[:red]u[:yellow]l[white:] [::bu]title") - if err := tview.NewApplication().SetRoot(box, true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/box/screenshot.png b/vendor/github.com/rivo/tview/demos/box/screenshot.png deleted file mode 100644 index 1af39b4..0000000 Binary files a/vendor/github.com/rivo/tview/demos/box/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/button/README.md b/vendor/github.com/rivo/tview/demos/button/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/button/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/button/main.go b/vendor/github.com/rivo/tview/demos/button/main.go deleted file mode 100644 index 10e52f9..0000000 --- a/vendor/github.com/rivo/tview/demos/button/main.go +++ /dev/null @@ -1,15 +0,0 @@ -// Demo code for the Button primitive. -package main - -import "github.com/rivo/tview" - -func main() { - app := tview.NewApplication() - button := tview.NewButton("Hit Enter to close").SetSelectedFunc(func() { - app.Stop() - }) - button.SetBorder(true).SetRect(0, 0, 22, 3) - if err := app.SetRoot(button, false).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/button/screenshot.png b/vendor/github.com/rivo/tview/demos/button/screenshot.png deleted file mode 100644 index 985811a..0000000 Binary files a/vendor/github.com/rivo/tview/demos/button/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/checkbox/README.md b/vendor/github.com/rivo/tview/demos/checkbox/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/checkbox/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/checkbox/main.go b/vendor/github.com/rivo/tview/demos/checkbox/main.go deleted file mode 100644 index 0a6bc70..0000000 --- a/vendor/github.com/rivo/tview/demos/checkbox/main.go +++ /dev/null @@ -1,12 +0,0 @@ -// Demo code for the Checkbox primitive. -package main - -import "github.com/rivo/tview" - -func main() { - app := tview.NewApplication() - checkbox := tview.NewCheckbox().SetLabel("Hit Enter to check box: ") - if err := app.SetRoot(checkbox, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/checkbox/screenshot.png b/vendor/github.com/rivo/tview/demos/checkbox/screenshot.png deleted file mode 100644 index f609319..0000000 Binary files a/vendor/github.com/rivo/tview/demos/checkbox/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/dropdown/README.md b/vendor/github.com/rivo/tview/demos/dropdown/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/dropdown/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/dropdown/main.go b/vendor/github.com/rivo/tview/demos/dropdown/main.go deleted file mode 100644 index 3d9510b..0000000 --- a/vendor/github.com/rivo/tview/demos/dropdown/main.go +++ /dev/null @@ -1,14 +0,0 @@ -// Demo code for the DropDown primitive. -package main - -import "github.com/rivo/tview" - -func main() { - app := tview.NewApplication() - dropdown := tview.NewDropDown(). - SetLabel("Select an option (hit Enter): "). - SetOptions([]string{"First", "Second", "Third", "Fourth", "Fifth"}, nil) - if err := app.SetRoot(dropdown, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/dropdown/screenshot.png b/vendor/github.com/rivo/tview/demos/dropdown/screenshot.png deleted file mode 100644 index 83baef0..0000000 Binary files a/vendor/github.com/rivo/tview/demos/dropdown/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/flex/README.md b/vendor/github.com/rivo/tview/demos/flex/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/flex/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/flex/main.go b/vendor/github.com/rivo/tview/demos/flex/main.go deleted file mode 100644 index 2df2466..0000000 --- a/vendor/github.com/rivo/tview/demos/flex/main.go +++ /dev/null @@ -1,20 +0,0 @@ -// Demo code for the Flex primitive. -package main - -import ( - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - flex := tview.NewFlex(). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Left (1/2 x width of Top)"), 0, 1, false). - AddItem(tview.NewFlex().SetDirection(tview.FlexRow). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Top"), 0, 1, false). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Middle (3 x height of Top)"), 0, 3, false). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Bottom (5 rows)"), 5, 1, false), 0, 2, false). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Right (20 cols)"), 20, 1, false) - if err := app.SetRoot(flex, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/flex/screenshot.png b/vendor/github.com/rivo/tview/demos/flex/screenshot.png deleted file mode 100644 index 527ff56..0000000 Binary files a/vendor/github.com/rivo/tview/demos/flex/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/form/README.md b/vendor/github.com/rivo/tview/demos/form/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/form/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/form/main.go b/vendor/github.com/rivo/tview/demos/form/main.go deleted file mode 100644 index 1b50c13..0000000 --- a/vendor/github.com/rivo/tview/demos/form/main.go +++ /dev/null @@ -1,24 +0,0 @@ -// Demo code for the Form primitive. -package main - -import ( - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - form := tview.NewForm(). - AddDropDown("Title", []string{"Mr.", "Ms.", "Mrs.", "Dr.", "Prof."}, 0, nil). - AddInputField("First name", "", 20, nil, nil). - AddInputField("Last name", "", 20, nil, nil). - AddCheckbox("Age 18+", false, nil). - AddPasswordField("Password", "", 10, '*', nil). - AddButton("Save", nil). - AddButton("Quit", func() { - app.Stop() - }) - form.SetBorder(true).SetTitle("Enter some data").SetTitleAlign(tview.AlignLeft) - if err := app.SetRoot(form, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/form/screenshot.png b/vendor/github.com/rivo/tview/demos/form/screenshot.png deleted file mode 100644 index a7c0379..0000000 Binary files a/vendor/github.com/rivo/tview/demos/form/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/frame/README.md b/vendor/github.com/rivo/tview/demos/frame/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/frame/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/frame/main.go b/vendor/github.com/rivo/tview/demos/frame/main.go deleted file mode 100644 index eb32179..0000000 --- a/vendor/github.com/rivo/tview/demos/frame/main.go +++ /dev/null @@ -1,22 +0,0 @@ -// Demo code for the Frame primitive. -package main - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - frame := tview.NewFrame(tview.NewBox().SetBackgroundColor(tcell.ColorBlue)). - SetBorders(2, 2, 2, 2, 4, 4). - AddText("Header left", true, tview.AlignLeft, tcell.ColorWhite). - AddText("Header middle", true, tview.AlignCenter, tcell.ColorWhite). - AddText("Header right", true, tview.AlignRight, tcell.ColorWhite). - AddText("Header second middle", true, tview.AlignCenter, tcell.ColorRed). - AddText("Footer middle", false, tview.AlignCenter, tcell.ColorGreen). - AddText("Footer second middle", false, tview.AlignCenter, tcell.ColorGreen) - if err := app.SetRoot(frame, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/frame/screenshot.png b/vendor/github.com/rivo/tview/demos/frame/screenshot.png deleted file mode 100644 index 1cd3c83..0000000 Binary files a/vendor/github.com/rivo/tview/demos/frame/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/grid/README.md b/vendor/github.com/rivo/tview/demos/grid/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/grid/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/grid/main.go b/vendor/github.com/rivo/tview/demos/grid/main.go deleted file mode 100644 index 57efe1e..0000000 --- a/vendor/github.com/rivo/tview/demos/grid/main.go +++ /dev/null @@ -1,38 +0,0 @@ -// Demo code for the Grid primitive. -package main - -import ( - "github.com/rivo/tview" -) - -func main() { - newPrimitive := func(text string) tview.Primitive { - return tview.NewTextView(). - SetTextAlign(tview.AlignCenter). - SetText(text) - } - menu := newPrimitive("Menu") - main := newPrimitive("Main content") - sideBar := newPrimitive("Side Bar") - - grid := tview.NewGrid(). - SetRows(3, 0, 3). - SetColumns(30, 0, 30). - SetBorders(true). - AddItem(newPrimitive("Header"), 0, 0, 1, 3, 0, 0, false). - AddItem(newPrimitive("Footer"), 2, 0, 1, 3, 0, 0, false) - - // Layout for screens narrower than 100 cells (menu and side bar are hidden). - grid.AddItem(menu, 0, 0, 0, 0, 0, 0, false). - AddItem(main, 1, 0, 1, 3, 0, 0, false). - AddItem(sideBar, 0, 0, 0, 0, 0, 0, false) - - // Layout for screens wider than 100 cells. - grid.AddItem(menu, 1, 0, 1, 1, 0, 100, false). - AddItem(main, 1, 1, 1, 1, 0, 100, false). - AddItem(sideBar, 1, 2, 1, 1, 0, 100, false) - - if err := tview.NewApplication().SetRoot(grid, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/grid/screenshot.png b/vendor/github.com/rivo/tview/demos/grid/screenshot.png deleted file mode 100644 index af55cd7..0000000 Binary files a/vendor/github.com/rivo/tview/demos/grid/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/inputfield/README.md b/vendor/github.com/rivo/tview/demos/inputfield/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/inputfield/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/inputfield/autocomplete/main.go b/vendor/github.com/rivo/tview/demos/inputfield/autocomplete/main.go deleted file mode 100644 index 7459369..0000000 --- a/vendor/github.com/rivo/tview/demos/inputfield/autocomplete/main.go +++ /dev/null @@ -1,39 +0,0 @@ -package main - -import ( - "strings" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// 1,000 most common English words. -const wordList = "ability,able,about,above,accept,according,account,across,act,action,activity,actually,add,address,administration,admit,adult,affect,after,again,against,age,agency,agent,ago,agree,agreement,ahead,air,all,allow,almost,alone,along,already,also,although,always,American,among,amount,analysis,and,animal,another,answer,any,anyone,anything,appear,apply,approach,area,argue,arm,around,arrive,art,article,artist,as,ask,assume,at,attack,attention,attorney,audience,author,authority,available,avoid,away,baby,back,bad,bag,ball,bank,bar,base,be,beat,beautiful,because,become,bed,before,begin,behavior,behind,believe,benefit,best,better,between,beyond,big,bill,billion,bit,black,blood,blue,board,body,book,born,both,box,boy,break,bring,brother,budget,build,building,business,but,buy,by,call,camera,campaign,can,cancer,candidate,capital,car,card,care,career,carry,case,catch,cause,cell,center,central,century,certain,certainly,chair,challenge,chance,change,character,charge,check,child,choice,choose,church,citizen,city,civil,claim,class,clear,clearly,close,coach,cold,collection,college,color,come,commercial,common,community,company,compare,computer,concern,condition,conference,Congress,consider,consumer,contain,continue,control,cost,could,country,couple,course,court,cover,create,crime,cultural,culture,cup,current,customer,cut,dark,data,daughter,day,dead,deal,death,debate,decade,decide,decision,deep,defense,degree,Democrat,democratic,describe,design,despite,detail,determine,develop,development,die,difference,different,difficult,dinner,direction,director,discover,discuss,discussion,disease,do,doctor,dog,door,down,draw,dream,drive,drop,drug,during,each,early,east,easy,eat,economic,economy,edge,education,effect,effort,eight,either,election,else,employee,end,energy,enjoy,enough,enter,entire,environment,environmental,especially,establish,even,evening,event,ever,every,everybody,everyone,everything,evidence,exactly,example,executive,exist,expect,experience,expert,explain,eye,face,fact,factor,fail,fall,family,far,fast,father,fear,federal,feel,feeling,few,field,fight,figure,fill,film,final,finally,financial,find,fine,finger,finish,fire,firm,first,fish,five,floor,fly,focus,follow,food,foot,for,force,foreign,forget,form,former,forward,four,free,friend,from,front,full,fund,future,game,garden,gas,general,generation,get,girl,give,glass,go,goal,good,government,great,green,ground,group,grow,growth,guess,gun,guy,hair,half,hand,hang,happen,happy,hard,have,he,head,health,hear,heart,heat,heavy,help,her,here,herself,high,him,himself,his,history,hit,hold,home,hope,hospital,hot,hotel,hour,house,how,however,huge,human,hundred,husband,idea,identify,if,image,imagine,impact,important,improve,in,include,including,increase,indeed,indicate,individual,industry,information,inside,instead,institution,interest,interesting,international,interview,into,investment,involve,issue,it,item,its,itself,job,join,just,keep,key,kid,kill,kind,kitchen,know,knowledge,land,language,large,last,late,later,laugh,law,lawyer,lay,lead,leader,learn,least,leave,left,leg,legal,less,let,letter,level,lie,life,light,like,likely,line,list,listen,little,live,local,long,look,lose,loss,lot,love,low,machine,magazine,main,maintain,major,majority,make,man,manage,management,manager,many,market,marriage,material,matter,may,maybe,me,mean,measure,media,medical,meet,meeting,member,memory,mention,message,method,middle,might,military,million,mind,minute,miss,mission,model,modern,moment,money,month,more,morning,most,mother,mouth,move,movement,movie,Mr,Mrs,much,music,must,my,myself,n't,name,nation,national,natural,nature,near,nearly,necessary,need,network,never,new,news,newspaper,next,nice,night,no,none,nor,north,not,note,nothing,notice,now,number,occur,of,off,offer,office,officer,official,often,oh,oil,ok,old,on,once,one,only,onto,open,operation,opportunity,option,or,order,organization,other,others,our,out,outside,over,own,owner,page,pain,painting,paper,parent,part,participant,particular,particularly,partner,party,pass,past,patient,pattern,pay,peace,people,per,perform,performance,perhaps,period,person,personal,phone,physical,pick,picture,piece,place,plan,plant,play,player,PM,point,police,policy,political,politics,poor,popular,population,position,positive,possible,power,practice,prepare,present,president,pressure,pretty,prevent,price,private,probably,problem,process,produce,product,production,professional,professor,program,project,property,protect,prove,provide,public,pull,purpose,push,put,quality,question,quickly,quite,race,radio,raise,range,rate,rather,reach,read,ready,real,reality,realize,really,reason,receive,recent,recently,recognize,record,red,reduce,reflect,region,relate,relationship,religious,remain,remember,remove,report,represent,Republican,require,research,resource,respond,response,responsibility,rest,result,return,reveal,rich,right,rise,risk,road,rock,role,room,rule,run,safe,same,save,say,scene,school,science,scientist,score,sea,season,seat,second,section,security,see,seek,seem,sell,send,senior,sense,series,serious,serve,service,set,seven,several,sex,sexual,shake,share,she,shoot,short,shot,should,shoulder,show,side,sign,significant,similar,simple,simply,since,sing,single,sister,sit,site,situation,six,size,skill,skin,small,smile,so,social,society,soldier,some,somebody,someone,something,sometimes,son,song,soon,sort,sound,source,south,southern,space,speak,special,specific,speech,spend,sport,spring,staff,stage,stand,standard,star,start,state,statement,station,stay,step,still,stock,stop,store,story,strategy,street,strong,structure,student,study,stuff,style,subject,success,successful,such,suddenly,suffer,suggest,summer,support,sure,surface,system,table,take,talk,task,tax,teach,teacher,team,technology,television,tell,ten,tend,term,test,than,thank,that,the,their,them,themselves,then,theory,there,these,they,thing,think,third,this,those,though,thought,thousand,threat,three,through,throughout,throw,thus,time,to,today,together,tonight,too,top,total,tough,toward,town,trade,traditional,training,travel,treat,treatment,tree,trial,trip,trouble,true,truth,try,turn,TV,two,type,under,understand,unit,until,up,upon,us,use,usually,value,various,very,victim,view,violence,visit,voice,vote,wait,walk,wall,want,war,watch,water,way,we,weapon,wear,week,weight,well,west,western,what,whatever,when,where,whether,which,while,white,who,whole,whom,whose,why,wide,wife,will,win,wind,window,wish,with,within,without,woman,wonder,word,work,worker,world,worry,would,write,writer,wrong,yard,yeah,year,yes,yet,you,young,your,yourself" - -func main() { - words := strings.Split(wordList, ",") - app := tview.NewApplication() - inputField := tview.NewInputField(). - SetLabel("Enter a word: "). - SetFieldWidth(30). - SetDoneFunc(func(key tcell.Key) { - app.Stop() - }) - inputField.SetAutocompleteFunc(func(currentText string) (entries []string) { - if len(currentText) == 0 { - return - } - for _, word := range words { - if strings.HasPrefix(strings.ToLower(word), strings.ToLower(currentText)) { - entries = append(entries, word) - } - } - if len(entries) <= 1 { - entries = nil - } - return - }) - if err := app.SetRoot(inputField, true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/inputfield/autocompleteasync/main.go b/vendor/github.com/rivo/tview/demos/inputfield/autocompleteasync/main.go deleted file mode 100644 index 0cfe75c..0000000 --- a/vendor/github.com/rivo/tview/demos/inputfield/autocompleteasync/main.go +++ /dev/null @@ -1,81 +0,0 @@ -package main - -import ( - "encoding/json" - "net/http" - "net/url" - "strings" - "sync" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -type company struct { - Name string `json:name` -} - -func main() { - app := tview.NewApplication() - inputField := tview.NewInputField(). - SetLabel("Enter a company name: "). - SetFieldWidth(30). - SetDoneFunc(func(key tcell.Key) { - app.Stop() - }) - - // Set up autocomplete function. - var mutex sync.Mutex - prefixMap := make(map[string][]string) - inputField.SetAutocompleteFunc(func(currentText string) []string { - // Ignore empty text. - prefix := strings.TrimSpace(strings.ToLower(currentText)) - if prefix == "" { - return nil - } - - // Do we have entries for this text already? - mutex.Lock() - defer mutex.Unlock() - entries, ok := prefixMap[prefix] - if ok { - return entries - } - - // No entries yet. Issue a request to the API in a goroutine. - go func() { - // Ignore errors in this demo. - url := "https://autocomplete.clearbit.com/v1/companies/suggest?query=" + url.QueryEscape(prefix) - res, err := http.Get(url) - if err != nil { - return - } - - // Store the result in the prefix map. - var companies []*company - dec := json.NewDecoder(res.Body) - if err := dec.Decode(&companies); err != nil { - return - } - entries := make([]string, 0, len(companies)) - for _, c := range companies { - entries = append(entries, c.Name) - } - mutex.Lock() - prefixMap[prefix] = entries - mutex.Unlock() - - // Trigger an update to the input field. - inputField.Autocomplete() - - // Also redraw the screen. - app.Draw() - }() - - return nil - }) - - if err := app.SetRoot(inputField, true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/inputfield/main.go b/vendor/github.com/rivo/tview/demos/inputfield/main.go deleted file mode 100644 index 1666ac8..0000000 --- a/vendor/github.com/rivo/tview/demos/inputfield/main.go +++ /dev/null @@ -1,22 +0,0 @@ -// Demo code for the InputField primitive. -package main - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - inputField := tview.NewInputField(). - SetLabel("Enter a number: "). - SetPlaceholder("E.g. 1234"). - SetFieldWidth(10). - SetAcceptanceFunc(tview.InputFieldInteger). - SetDoneFunc(func(key tcell.Key) { - app.Stop() - }) - if err := app.SetRoot(inputField, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/inputfield/screenshot.png b/vendor/github.com/rivo/tview/demos/inputfield/screenshot.png deleted file mode 100644 index ac970d0..0000000 Binary files a/vendor/github.com/rivo/tview/demos/inputfield/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/list/README.md b/vendor/github.com/rivo/tview/demos/list/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/list/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/list/main.go b/vendor/github.com/rivo/tview/demos/list/main.go deleted file mode 100644 index 402703a..0000000 --- a/vendor/github.com/rivo/tview/demos/list/main.go +++ /dev/null @@ -1,21 +0,0 @@ -// Demo code for the List primitive. -package main - -import ( - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - list := tview.NewList(). - AddItem("List item 1", "Some explanatory text", 'a', nil). - AddItem("List item 2", "Some explanatory text", 'b', nil). - AddItem("List item 3", "Some explanatory text", 'c', nil). - AddItem("List item 4", "Some explanatory text", 'd', nil). - AddItem("Quit", "Press to exit", 'q', func() { - app.Stop() - }) - if err := app.SetRoot(list, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/list/screenshot.png b/vendor/github.com/rivo/tview/demos/list/screenshot.png deleted file mode 100644 index 69204b7..0000000 Binary files a/vendor/github.com/rivo/tview/demos/list/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/modal/README.md b/vendor/github.com/rivo/tview/demos/modal/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/modal/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/modal/centered.png b/vendor/github.com/rivo/tview/demos/modal/centered.png deleted file mode 100644 index 7511a05..0000000 Binary files a/vendor/github.com/rivo/tview/demos/modal/centered.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/modal/main.go b/vendor/github.com/rivo/tview/demos/modal/main.go deleted file mode 100644 index e7ef1f8..0000000 --- a/vendor/github.com/rivo/tview/demos/modal/main.go +++ /dev/null @@ -1,21 +0,0 @@ -// Demo code for the Modal primitive. -package main - -import ( - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - modal := tview.NewModal(). - SetText("Do you want to quit the application?"). - AddButtons([]string{"Quit", "Cancel"}). - SetDoneFunc(func(buttonIndex int, buttonLabel string) { - if buttonLabel == "Quit" { - app.Stop() - } - }) - if err := app.SetRoot(modal, false).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/modal/screenshot.png b/vendor/github.com/rivo/tview/demos/modal/screenshot.png deleted file mode 100644 index dcb7c8e..0000000 Binary files a/vendor/github.com/rivo/tview/demos/modal/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/pages/README.md b/vendor/github.com/rivo/tview/demos/pages/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/pages/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/pages/main.go b/vendor/github.com/rivo/tview/demos/pages/main.go deleted file mode 100644 index 67c06e0..0000000 --- a/vendor/github.com/rivo/tview/demos/pages/main.go +++ /dev/null @@ -1,35 +0,0 @@ -// Demo code for the Pages primitive. -package main - -import ( - "fmt" - - "github.com/rivo/tview" -) - -const pageCount = 5 - -func main() { - app := tview.NewApplication() - pages := tview.NewPages() - for page := 0; page < pageCount; page++ { - func(page int) { - pages.AddPage(fmt.Sprintf("page-%d", page), - tview.NewModal(). - SetText(fmt.Sprintf("This is page %d. Choose where to go next.", page+1)). - AddButtons([]string{"Next", "Quit"}). - SetDoneFunc(func(buttonIndex int, buttonLabel string) { - if buttonIndex == 0 { - pages.SwitchToPage(fmt.Sprintf("page-%d", (page+1)%pageCount)) - } else { - app.Stop() - } - }), - false, - page == 0) - }(page) - } - if err := app.SetRoot(pages, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/pages/screenshot.png b/vendor/github.com/rivo/tview/demos/pages/screenshot.png deleted file mode 100644 index 70c59a9..0000000 Binary files a/vendor/github.com/rivo/tview/demos/pages/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/postgres.png b/vendor/github.com/rivo/tview/demos/postgres.png deleted file mode 100644 index e6a12d7..0000000 Binary files a/vendor/github.com/rivo/tview/demos/postgres.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/presentation/center.go b/vendor/github.com/rivo/tview/demos/presentation/center.go deleted file mode 100644 index dd34da0..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/center.go +++ /dev/null @@ -1,16 +0,0 @@ -package main - -import "github.com/rivo/tview" - -// Center returns a new primitive which shows the provided primitive in its -// center, given the provided primitive's size. -func Center(width, height int, p tview.Primitive) tview.Primitive { - return tview.NewFlex(). - AddItem(nil, 0, 1, false). - AddItem(tview.NewFlex(). - SetDirection(tview.FlexRow). - AddItem(nil, 0, 1, false). - AddItem(p, height, 1, true). - AddItem(nil, 0, 1, false), width, 1, true). - AddItem(nil, 0, 1, false) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/code.go b/vendor/github.com/rivo/tview/demos/presentation/code.go deleted file mode 100644 index 59fd048..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/code.go +++ /dev/null @@ -1,25 +0,0 @@ -package main - -import ( - "fmt" - - "github.com/rivo/tview" -) - -// The width of the code window. -const codeWidth = 56 - -// Code returns a primitive which displays the given primitive (with the given -// size) on the left side and its source code on the right side. -func Code(p tview.Primitive, width, height int, code string) tview.Primitive { - // Set up code view. - codeView := tview.NewTextView(). - SetWrap(false). - SetDynamicColors(true) - codeView.SetBorderPadding(1, 1, 2, 0) - fmt.Fprint(codeView, code) - - return tview.NewFlex(). - AddItem(Center(width, height, p), 0, 1, true). - AddItem(codeView, codeWidth, 1, false) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/colors.go b/vendor/github.com/rivo/tview/demos/presentation/colors.go deleted file mode 100644 index 3b0ae81..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/colors.go +++ /dev/null @@ -1,33 +0,0 @@ -package main - -import ( - "strings" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const colorsText = `You can use color tags almost everywhere to partially change the color of a string. Simply put a color name or hex string in square brackets to change the following characters' color. H[green]er[white]e i[yellow]s a[darkcyan]n ex[red]amp[white]le. The [black:red]tags [black:green]look [black:yellow]like [::u]this: [blue:yellow:u[] [#00ff00[]` - -// Colors demonstrates how to use colors. -func Colors(nextSlide func()) (title string, content tview.Primitive) { - table := tview.NewTable(). - SetBorders(true). - SetBordersColor(tcell.ColorBlue). - SetDoneFunc(func(key tcell.Key) { - nextSlide() - }) - var row, column int - for _, word := range strings.Split(colorsText, " ") { - table.SetCellSimple(row, column, word) - column++ - if column > 6 { - column = 0 - row++ - } - } - table.SetBorderPadding(1, 1, 2, 2). - SetBorder(true). - SetTitle("A [red]c[yellow]o[green]l[darkcyan]o[blue]r[darkmagenta]f[red]u[yellow]l[white] [black:red]c[:yellow]o[:green]l[:darkcyan]o[:blue]r[:darkmagenta]f[:red]u[:yellow]l[white:] [::bu]title") - return "Colors", Center(78, 19, table) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/cover.go b/vendor/github.com/rivo/tview/demos/presentation/cover.go deleted file mode 100644 index eaeea9d..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/cover.go +++ /dev/null @@ -1,63 +0,0 @@ -package main - -import ( - "fmt" - "strings" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const logo = ` - __ _ - / /__ __(_)__ _ __ - / __/ | / / / _ \ | /| / / -/ /_ | |/ / / __/ |/ |/ / -\__/ |___/_/\___/|__/|__/ - -` - -const ( - subtitle = `tview - Rich Widgets for Terminal UIs` - navigation = `Ctrl-N: Next slide Ctrl-P: Previous slide Ctrl-C: Exit` - mouse = `(or use your mouse)` -) - -// Cover returns the cover page. -func Cover(nextSlide func()) (title string, content tview.Primitive) { - // What's the size of the logo? - lines := strings.Split(logo, "\n") - logoWidth := 0 - logoHeight := len(lines) - for _, line := range lines { - if len(line) > logoWidth { - logoWidth = len(line) - } - } - logoBox := tview.NewTextView(). - SetTextColor(tcell.ColorGreen). - SetDoneFunc(func(key tcell.Key) { - nextSlide() - }) - fmt.Fprint(logoBox, logo) - - // Create a frame for the subtitle and navigation infos. - frame := tview.NewFrame(tview.NewBox()). - SetBorders(0, 0, 0, 0, 0, 0). - AddText(subtitle, true, tview.AlignCenter, tcell.ColorWhite). - AddText("", true, tview.AlignCenter, tcell.ColorWhite). - AddText(navigation, true, tview.AlignCenter, tcell.ColorDarkMagenta). - AddText(mouse, true, tview.AlignCenter, tcell.ColorDarkMagenta) - - // Create a Flex layout that centers the logo and subtitle. - flex := tview.NewFlex(). - SetDirection(tview.FlexRow). - AddItem(tview.NewBox(), 0, 7, false). - AddItem(tview.NewFlex(). - AddItem(tview.NewBox(), 0, 1, false). - AddItem(logoBox, logoWidth, 1, true). - AddItem(tview.NewBox(), 0, 1, false), logoHeight, 1, true). - AddItem(frame, 0, 10, false) - - return "Start", flex -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/end.go b/vendor/github.com/rivo/tview/demos/presentation/end.go deleted file mode 100644 index c085b31..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/end.go +++ /dev/null @@ -1,18 +0,0 @@ -package main - -import ( - "fmt" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// End shows the final slide. -func End(nextSlide func()) (title string, content tview.Primitive) { - textView := tview.NewTextView().SetDoneFunc(func(key tcell.Key) { - nextSlide() - }) - url := "https://github.com/rivo/tview" - fmt.Fprint(textView, url) - return "End", Center(len(url), 1, textView) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/flex.go b/vendor/github.com/rivo/tview/demos/presentation/flex.go deleted file mode 100644 index 2e8e5dd..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/flex.go +++ /dev/null @@ -1,38 +0,0 @@ -package main - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// Flex demonstrates flexbox layout. -func Flex(nextSlide func()) (title string, content tview.Primitive) { - modalShown := false - pages := tview.NewPages() - flex := tview.NewFlex(). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Flexible width, twice of middle column"), 0, 2, true). - AddItem(tview.NewFlex(). - SetDirection(tview.FlexRow). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Flexible width"), 0, 1, false). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Fixed height"), 15, 1, false). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Flexible height"), 0, 1, false), 0, 1, false). - AddItem(tview.NewBox().SetBorder(true).SetTitle("Fixed width"), 30, 1, false) - flex.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { - if modalShown { - nextSlide() - modalShown = false - } else { - pages.ShowPage("modal") - modalShown = true - } - return event - }) - modal := tview.NewModal(). - SetText("Resize the window to see the effect of the flexbox parameters"). - AddButtons([]string{"Ok"}).SetDoneFunc(func(buttonIndex int, buttonLabel string) { - pages.HidePage("modal") - }) - pages.AddPage("flex", flex, true, true). - AddPage("modal", modal, false, false) - return "Flex", pages -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/form.go b/vendor/github.com/rivo/tview/demos/presentation/form.go deleted file mode 100644 index f2b0c0f..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/form.go +++ /dev/null @@ -1,43 +0,0 @@ -package main - -import ( - "github.com/rivo/tview" -) - -const form = `[green]package[white] main - -[green]import[white] ( - [red]"github.com/rivo/tview"[white] -) - -[green]func[white] [yellow]main[white]() { - form := tview.[yellow]NewForm[white](). - [yellow]AddInputField[white]([red]"First name:"[white], [red]""[white], [red]20[white], nil, nil). - [yellow]AddInputField[white]([red]"Last name:"[white], [red]""[white], [red]20[white], nil, nil). - [yellow]AddDropDown[white]([red]"Role:"[white], [][green]string[white]{ - [red]"Engineer"[white], - [red]"Manager"[white], - [red]"Administration"[white], - }, [red]0[white], nil). - [yellow]AddCheckbox[white]([red]"On vacation:"[white], false, nil). - [yellow]AddPasswordField[white]([red]"Password:"[white], [red]""[white], [red]10[white], [red]'*'[white], nil). - [yellow]AddButton[white]([red]"Save"[white], [yellow]func[white]() { [blue]/* Save data */[white] }). - [yellow]AddButton[white]([red]"Cancel"[white], [yellow]func[white]() { [blue]/* Cancel */[white] }) - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](form, true). - [yellow]Run[white]() -}` - -// Form demonstrates forms. -func Form(nextSlide func()) (title string, content tview.Primitive) { - f := tview.NewForm(). - AddInputField("First name:", "", 20, nil, nil). - AddInputField("Last name:", "", 20, nil, nil). - AddDropDown("Role:", []string{"Engineer", "Manager", "Administration"}, 0, nil). - AddCheckbox("On vacation:", false, nil). - AddPasswordField("Password:", "", 10, '*', nil). - AddButton("Save", nextSlide). - AddButton("Cancel", nextSlide) - f.SetBorder(true).SetTitle("Employee Information") - return "Forms", Code(f, 36, 15, form) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/grid.go b/vendor/github.com/rivo/tview/demos/presentation/grid.go deleted file mode 100644 index 38d325e..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/grid.go +++ /dev/null @@ -1,60 +0,0 @@ -package main - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// Grid demonstrates the grid layout. -func Grid(nextSlide func()) (title string, content tview.Primitive) { - modalShown := false - pages := tview.NewPages() - - newPrimitive := func(text string) tview.Primitive { - return tview.NewFrame(nil). - SetBorders(0, 0, 0, 0, 0, 0). - AddText(text, true, tview.AlignCenter, tcell.ColorWhite) - } - - menu := newPrimitive("Menu") - main := newPrimitive("Main content") - sideBar := newPrimitive("Side Bar") - - grid := tview.NewGrid(). - SetRows(3, 0, 3). - SetColumns(0, -4, 0). - SetBorders(true). - AddItem(newPrimitive("Header"), 0, 0, 1, 3, 0, 0, true). - AddItem(newPrimitive("Footer"), 2, 0, 1, 3, 0, 0, false) - grid.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { - if modalShown { - nextSlide() - modalShown = false - } else { - pages.ShowPage("modal") - modalShown = true - } - return event - }) - - // Layout for screens narrower than 100 cells (menu and side bar are hidden). - grid.AddItem(menu, 0, 0, 0, 0, 0, 0, false). - AddItem(main, 1, 0, 1, 3, 0, 0, false). - AddItem(sideBar, 0, 0, 0, 0, 0, 0, false) - - // Layout for screens wider than 100 cells. - grid.AddItem(menu, 1, 0, 1, 1, 0, 100, false). - AddItem(main, 1, 1, 1, 1, 0, 100, false). - AddItem(sideBar, 1, 2, 1, 1, 0, 100, false) - - modal := tview.NewModal(). - SetText("Resize the window to see how the grid layout adapts"). - AddButtons([]string{"Ok"}).SetDoneFunc(func(buttonIndex int, buttonLabel string) { - pages.HidePage("modal") - }) - - pages.AddPage("grid", grid, true, true). - AddPage("modal", modal, false, false) - - return "Grid", pages -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/helloworld.go b/vendor/github.com/rivo/tview/demos/presentation/helloworld.go deleted file mode 100644 index 86fb527..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/helloworld.go +++ /dev/null @@ -1,31 +0,0 @@ -package main - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const helloWorld = `[green]package[white] main - -[green]import[white] ( - [red]"github.com/rivo/tview"[white] -) - -[green]func[white] [yellow]main[white]() { - box := tview.[yellow]NewBox[white](). - [yellow]SetBorder[white](true). - [yellow]SetTitle[white]([red]"Hello, world!"[white]) - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](box, true). - [yellow]Run[white]() -}` - -// HelloWorld shows a simple "Hello world" example. -func HelloWorld(nextSlide func()) (title string, content tview.Primitive) { - // We use a text view because we want to capture keyboard input. - textView := tview.NewTextView().SetDoneFunc(func(key tcell.Key) { - nextSlide() - }) - textView.SetBorder(true).SetTitle("Hello, world!") - return "Hello, world", Code(textView, 30, 10, helloWorld) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/inputfield.go b/vendor/github.com/rivo/tview/demos/presentation/inputfield.go deleted file mode 100644 index dde6d4f..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/inputfield.go +++ /dev/null @@ -1,40 +0,0 @@ -package main - -import ( - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const inputField = `[green]package[white] main - -[green]import[white] ( - [red]"strconv"[white] - - [red]"github.com/gdamore/tcell/v2"[white] - [red]"github.com/rivo/tview"[white] -) - -[green]func[white] [yellow]main[white]() { - input := tview.[yellow]NewInputField[white](). - [yellow]SetLabel[white]([red]"Enter a number: "[white]). - [yellow]SetAcceptanceFunc[white]( - tview.InputFieldInteger, - ).[yellow]SetDoneFunc[white]([yellow]func[white](key tcell.Key) { - text := input.[yellow]GetText[white]() - n, _ := strconv.[yellow]Atoi[white](text) - [blue]// We have a number.[white] - }) - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](input, true). - [yellow]Run[white]() -}` - -// InputField demonstrates the InputField. -func InputField(nextSlide func()) (title string, content tview.Primitive) { - input := tview.NewInputField(). - SetLabel("Enter a number: "). - SetAcceptanceFunc(tview.InputFieldInteger).SetDoneFunc(func(key tcell.Key) { - nextSlide() - }) - return "Input", Code(input, 30, 1, inputField) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/introduction.go b/vendor/github.com/rivo/tview/demos/presentation/introduction.go deleted file mode 100644 index 8dc0f0c..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/introduction.go +++ /dev/null @@ -1,14 +0,0 @@ -package main - -import "github.com/rivo/tview" - -// Introduction returns a tview.List with the highlights of the tview package. -func Introduction(nextSlide func()) (title string, content tview.Primitive) { - list := tview.NewList(). - AddItem("A Go package for terminal based UIs", "with a special focus on rich interactive widgets", '1', nextSlide). - AddItem("Based on github.com/gdamore/tcell", "Like termbox but better (see tcell docs)", '2', nextSlide). - AddItem("Designed to be simple", `"Hello world" is 5 lines of code`, '3', nextSlide). - AddItem("Good for data entry", `For charts, use "termui" - for low-level views, use "gocui" - ...`, '4', nextSlide). - AddItem("Extensive documentation", "Everything is documented, examples in GitHub wiki, demo code for each widget", '5', nextSlide) - return "Introduction", Center(80, 10, list) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/main.go b/vendor/github.com/rivo/tview/demos/presentation/main.go deleted file mode 100644 index 42172cb..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/main.go +++ /dev/null @@ -1,103 +0,0 @@ -/* -A presentation of the tview package, implemented with tview. - -Navigation - -The presentation will advance to the next slide when the primitive demonstrated -in the current slide is left (usually by hitting Enter or Escape). Additionally, -the following shortcuts can be used: - - - Ctrl-N: Jump to next slide - - Ctrl-P: Jump to previous slide -*/ -package main - -import ( - "fmt" - "strconv" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// Slide is a function which returns the slide's main primitive and its title. -// It receives a "nextSlide" function which can be called to advance the -// presentation to the next slide. -type Slide func(nextSlide func()) (title string, content tview.Primitive) - -// The application. -var app = tview.NewApplication() - -// Starting point for the presentation. -func main() { - // The presentation slides. - slides := []Slide{ - Cover, - Introduction, - HelloWorld, - InputField, - Form, - TextView1, - TextView2, - Table, - TreeView, - Flex, - Grid, - Colors, - End, - } - - pages := tview.NewPages() - - // The bottom row has some info on where we are. - info := tview.NewTextView(). - SetDynamicColors(true). - SetRegions(true). - SetWrap(false). - SetHighlightedFunc(func(added, removed, remaining []string) { - pages.SwitchToPage(added[0]) - }) - - // Create the pages for all slides. - previousSlide := func() { - slide, _ := strconv.Atoi(info.GetHighlights()[0]) - slide = (slide - 1 + len(slides)) % len(slides) - info.Highlight(strconv.Itoa(slide)). - ScrollToHighlight() - } - nextSlide := func() { - slide, _ := strconv.Atoi(info.GetHighlights()[0]) - slide = (slide + 1) % len(slides) - info.Highlight(strconv.Itoa(slide)). - ScrollToHighlight() - } - for index, slide := range slides { - title, primitive := slide(nextSlide) - pages.AddPage(strconv.Itoa(index), primitive, true, index == 0) - fmt.Fprintf(info, `%d ["%d"][darkcyan]%s[white][""] `, index+1, index, title) - } - info.Highlight("0") - - // Create the main layout. - layout := tview.NewFlex(). - SetDirection(tview.FlexRow). - AddItem(pages, 0, 1, true). - AddItem(info, 1, 1, false) - - // Shortcuts to navigate the slides. - app.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { - if event.Key() == tcell.KeyCtrlN { - nextSlide() - return nil - } else if event.Key() == tcell.KeyCtrlP { - previousSlide() - return nil - } - return event - }) - - // Start the application. - if err := app.SetRoot(layout, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/table.go b/vendor/github.com/rivo/tview/demos/presentation/table.go deleted file mode 100644 index 36600b9..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/table.go +++ /dev/null @@ -1,362 +0,0 @@ -package main - -import ( - "fmt" - "strings" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const tableData = `OrderDate|Region|Rep|Item|Units|UnitCost|Total -1/6/2017|East|Jones|Pencil|95|1.99|189.05 -1/23/2017|Central|Kivell|Binder|50|19.99|999.50 -2/9/2017|Central|Jardine|Pencil|36|4.99|179.64 -2/26/2017|Central|Gill|Pen|27|19.99|539.73 -3/15/2017|West|Sorvino|Pencil|56|2.99|167.44 -4/1/2017|East|Jones|Binder|60|4.99|299.40 -4/18/2017|Central|Andrews|Pencil|75|1.99|149.25 -5/5/2017|Central|Jardine|Pencil|90|4.99|449.10 -5/22/2017|West|Thompson|Pencil|32|1.99|63.68 -6/8/2017|East|Jones|Binder|60|8.99|539.40 -6/25/2017|Central|Morgan|Pencil|90|4.99|449.10 -7/12/2017|East|Howard|Binder|29|1.99|57.71 -7/29/2017|East|Parent|Binder|81|19.99|1,619.19 -8/15/2017|East|Jones|Pencil|35|4.99|174.65 -9/1/2017|Central|Smith|Desk|2|125.00|250.00 -9/18/2017|East|Jones|Pen Set|16|15.99|255.84 -10/5/2017|Central|Morgan|Binder|28|8.99|251.72 -10/22/2017|East|Jones|Pen|64|8.99|575.36 -11/8/2017|East|Parent|Pen|15|19.99|299.85 -11/25/2017|Central|Kivell|Pen Set|96|4.99|479.04 -12/12/2017|Central|Smith|Pencil|67|1.29|86.43 -12/29/2017|East|Parent|Pen Set|74|15.99|1,183.26 -1/15/2018|Central|Gill|Binder|46|8.99|413.54 -2/1/2018|Central|Smith|Binder|87|15.00|1,305.00 -2/18/2018|East|Jones|Binder|4|4.99|19.96 -3/7/2018|West|Sorvino|Binder|7|19.99|139.93 -3/24/2018|Central|Jardine|Pen Set|50|4.99|249.50 -4/10/2018|Central|Andrews|Pencil|66|1.99|131.34 -4/27/2018|East|Howard|Pen|96|4.99|479.04 -5/14/2018|Central|Gill|Pencil|53|1.29|68.37 -5/31/2018|Central|Gill|Binder|80|8.99|719.20 -6/17/2018|Central|Kivell|Desk|5|125.00|625.00 -7/4/2018|East|Jones|Pen Set|62|4.99|309.38 -7/21/2018|Central|Morgan|Pen Set|55|12.49|686.95 -8/7/2018|Central|Kivell|Pen Set|42|23.95|1,005.90 -8/24/2018|West|Sorvino|Desk|3|275.00|825.00 -9/10/2018|Central|Gill|Pencil|7|1.29|9.03 -9/27/2018|West|Sorvino|Pen|76|1.99|151.24 -10/14/2018|West|Thompson|Binder|57|19.99|1,139.43 -10/31/2018|Central|Andrews|Pencil|14|1.29|18.06 -11/17/2018|Central|Jardine|Binder|11|4.99|54.89 -12/4/2018|Central|Jardine|Binder|94|19.99|1,879.06 -12/21/2018|Central|Andrews|Binder|28|4.99|139.72` - -const tableBasic = `[green]func[white] [yellow]main[white]() { - table := tview.[yellow]NewTable[white](). - [yellow]SetFixed[white]([red]1[white], [red]1[white]) - [yellow]for[white] row := [red]0[white]; row < [red]40[white]; row++ { - [yellow]for[white] column := [red]0[white]; column < [red]7[white]; column++ { - color := tcell.ColorWhite - [yellow]if[white] row == [red]0[white] { - color = tcell.ColorYellow - } [yellow]else[white] [yellow]if[white] column == [red]0[white] { - color = tcell.ColorDarkCyan - } - align := tview.AlignLeft - [yellow]if[white] row == [red]0[white] { - align = tview.AlignCenter - } [yellow]else[white] [yellow]if[white] column == [red]0[white] || column >= [red]4[white] { - align = tview.AlignRight - } - table.[yellow]SetCell[white](row, - column, - &tview.TableCell{ - Text: [red]"..."[white], - Color: color, - Align: align, - }) - } - } - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](table, true). - [yellow]Run[white]() -}` - -const tableSeparator = `[green]func[white] [yellow]main[white]() { - table := tview.[yellow]NewTable[white](). - [yellow]SetFixed[white]([red]1[white], [red]1[white]). - [yellow]SetSeparator[white](Borders.Vertical) - [yellow]for[white] row := [red]0[white]; row < [red]40[white]; row++ { - [yellow]for[white] column := [red]0[white]; column < [red]7[white]; column++ { - color := tcell.ColorWhite - [yellow]if[white] row == [red]0[white] { - color = tcell.ColorYellow - } [yellow]else[white] [yellow]if[white] column == [red]0[white] { - color = tcell.ColorDarkCyan - } - align := tview.AlignLeft - [yellow]if[white] row == [red]0[white] { - align = tview.AlignCenter - } [yellow]else[white] [yellow]if[white] column == [red]0[white] || column >= [red]4[white] { - align = tview.AlignRight - } - table.[yellow]SetCell[white](row, - column, - &tview.TableCell{ - Text: [red]"..."[white], - Color: color, - Align: align, - }) - } - } - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](table, true). - [yellow]Run[white]() -}` - -const tableBorders = `[green]func[white] [yellow]main[white]() { - table := tview.[yellow]NewTable[white](). - [yellow]SetFixed[white]([red]1[white], [red]1[white]). - [yellow]SetBorders[white](true) - [yellow]for[white] row := [red]0[white]; row < [red]40[white]; row++ { - [yellow]for[white] column := [red]0[white]; column < [red]7[white]; column++ { - color := tcell.ColorWhite - [yellow]if[white] row == [red]0[white] { - color = tcell.ColorYellow - } [yellow]else[white] [yellow]if[white] column == [red]0[white] { - color = tcell.ColorDarkCyan - } - align := tview.AlignLeft - [yellow]if[white] row == [red]0[white] { - align = tview.AlignCenter - } [yellow]else[white] [yellow]if[white] column == [red]0[white] || column >= [red]4[white] { - align = tview.AlignRight - } - table.[yellow]SetCell[white](row, - column, - &tview.TableCell{ - Text: [red]"..."[white], - Color: color, - Align: align, - }) - } - } - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](table, true). - [yellow]Run[white]() -}` - -const tableSelectRow = `[green]func[white] [yellow]main[white]() { - table := tview.[yellow]NewTable[white](). - [yellow]SetFixed[white]([red]1[white], [red]1[white]). - [yellow]SetSelectable[white](true, false) - [yellow]for[white] row := [red]0[white]; row < [red]40[white]; row++ { - [yellow]for[white] column := [red]0[white]; column < [red]7[white]; column++ { - color := tcell.ColorWhite - [yellow]if[white] row == [red]0[white] { - color = tcell.ColorYellow - } [yellow]else[white] [yellow]if[white] column == [red]0[white] { - color = tcell.ColorDarkCyan - } - align := tview.AlignLeft - [yellow]if[white] row == [red]0[white] { - align = tview.AlignCenter - } [yellow]else[white] [yellow]if[white] column == [red]0[white] || column >= [red]4[white] { - align = tview.AlignRight - } - table.[yellow]SetCell[white](row, - column, - &tview.TableCell{ - Text: [red]"..."[white], - Color: color, - Align: align, - NotSelectable: row == [red]0[white] || column == [red]0[white], - }) - } - } - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](table, true). - [yellow]Run[white]() -}` - -const tableSelectColumn = `[green]func[white] [yellow]main[white]() { - table := tview.[yellow]NewTable[white](). - [yellow]SetFixed[white]([red]1[white], [red]1[white]). - [yellow]SetSelectable[white](false, true) - [yellow]for[white] row := [red]0[white]; row < [red]40[white]; row++ { - [yellow]for[white] column := [red]0[white]; column < [red]7[white]; column++ { - color := tcell.ColorWhite - [yellow]if[white] row == [red]0[white] { - color = tcell.ColorYellow - } [yellow]else[white] [yellow]if[white] column == [red]0[white] { - color = tcell.ColorDarkCyan - } - align := tview.AlignLeft - [yellow]if[white] row == [red]0[white] { - align = tview.AlignCenter - } [yellow]else[white] [yellow]if[white] column == [red]0[white] || column >= [red]4[white] { - align = tview.AlignRight - } - table.[yellow]SetCell[white](row, - column, - &tview.TableCell{ - Text: [red]"..."[white], - Color: color, - Align: align, - NotSelectable: row == [red]0[white] || column == [red]0[white], - }) - } - } - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](table, true). - [yellow]Run[white]() -}` - -const tableSelectCell = `[green]func[white] [yellow]main[white]() { - table := tview.[yellow]NewTable[white](). - [yellow]SetFixed[white]([red]1[white], [red]1[white]). - [yellow]SetSelectable[white](true, true) - [yellow]for[white] row := [red]0[white]; row < [red]40[white]; row++ { - [yellow]for[white] column := [red]0[white]; column < [red]7[white]; column++ { - color := tcell.ColorWhite - [yellow]if[white] row == [red]0[white] { - color = tcell.ColorYellow - } [yellow]else[white] [yellow]if[white] column == [red]0[white] { - color = tcell.ColorDarkCyan - } - align := tview.AlignLeft - [yellow]if[white] row == [red]0[white] { - align = tview.AlignCenter - } [yellow]else[white] [yellow]if[white] column == [red]0[white] || column >= [red]4[white] { - align = tview.AlignRight - } - table.[yellow]SetCell[white](row, - column, - &tview.TableCell{ - Text: [red]"..."[white], - Color: color, - Align: align, - NotSelectable: row == [red]0[white] || column == [red]0[white], - }) - } - } - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](table, true). - [yellow]Run[white]() -}` - -// Table demonstrates the Table. -func Table(nextSlide func()) (title string, content tview.Primitive) { - table := tview.NewTable(). - SetFixed(1, 1) - for row, line := range strings.Split(tableData, "\n") { - for column, cell := range strings.Split(line, "|") { - color := tcell.ColorWhite - if row == 0 { - color = tcell.ColorYellow - } else if column == 0 { - color = tcell.ColorDarkCyan - } - align := tview.AlignLeft - if row == 0 { - align = tview.AlignCenter - } else if column == 0 || column >= 4 { - align = tview.AlignRight - } - tableCell := tview.NewTableCell(cell). - SetTextColor(color). - SetAlign(align). - SetSelectable(row != 0 && column != 0) - if column >= 1 && column <= 3 { - tableCell.SetExpansion(1) - } - table.SetCell(row, column, tableCell) - } - } - table.SetBorder(true).SetTitle("Table") - - code := tview.NewTextView(). - SetWrap(false). - SetDynamicColors(true) - code.SetBorderPadding(1, 1, 2, 0) - - list := tview.NewList() - - basic := func() { - table.SetBorders(false). - SetSelectable(false, false). - SetSeparator(' ') - code.Clear() - fmt.Fprint(code, tableBasic) - } - - separator := func() { - table.SetBorders(false). - SetSelectable(false, false). - SetSeparator(tview.Borders.Vertical) - code.Clear() - fmt.Fprint(code, tableSeparator) - } - - borders := func() { - table.SetBorders(true). - SetSelectable(false, false) - code.Clear() - fmt.Fprint(code, tableBorders) - } - - selectRow := func() { - table.SetBorders(false). - SetSelectable(true, false). - SetSeparator(' ') - code.Clear() - fmt.Fprint(code, tableSelectRow) - } - - selectColumn := func() { - table.SetBorders(false). - SetSelectable(false, true). - SetSeparator(' ') - code.Clear() - fmt.Fprint(code, tableSelectColumn) - } - - selectCell := func() { - table.SetBorders(false). - SetSelectable(true, true). - SetSeparator(' ') - code.Clear() - fmt.Fprint(code, tableSelectCell) - } - - navigate := func() { - app.SetFocus(table) - table.SetDoneFunc(func(key tcell.Key) { - app.SetFocus(list) - }).SetSelectedFunc(func(row int, column int) { - app.SetFocus(list) - }) - } - - list.ShowSecondaryText(false). - AddItem("Basic table", "", 'b', basic). - AddItem("Table with separator", "", 's', separator). - AddItem("Table with borders", "", 'o', borders). - AddItem("Selectable rows", "", 'r', selectRow). - AddItem("Selectable columns", "", 'c', selectColumn). - AddItem("Selectable cells", "", 'l', selectCell). - AddItem("Navigate", "", 'n', navigate). - AddItem("Next slide", "", 'x', nextSlide) - list.SetBorderPadding(1, 1, 2, 2) - - basic() - - return "Table", tview.NewFlex(). - AddItem(tview.NewFlex(). - SetDirection(tview.FlexRow). - AddItem(list, 10, 1, true). - AddItem(table, 0, 1, false), 0, 1, true). - AddItem(code, codeWidth, 1, false) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/textview.go b/vendor/github.com/rivo/tview/demos/presentation/textview.go deleted file mode 100644 index 5c6f282..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/textview.go +++ /dev/null @@ -1,160 +0,0 @@ -package main - -import ( - "fmt" - "strconv" - "time" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const textView1 = `[green]func[white] [yellow]main[white]() { - app := tview.[yellow]NewApplication[white]() - textView := tview.[yellow]NewTextView[white](). - [yellow]SetTextColor[white](tcell.ColorYellow). - [yellow]SetScrollable[white](false). - [yellow]SetChangedFunc[white]([yellow]func[white]() { - app.[yellow]Draw[white]() - }) - [green]go[white] [yellow]func[white]() { - [green]var[white] n [green]int -[white] [yellow]for[white] { - n++ - fmt.[yellow]Fprintf[white](textView, [red]"%d "[white], n) - time.[yellow]Sleep[white]([red]200[white] * time.Millisecond) - } - }() - app.[yellow]SetRoot[white](textView, true). - [yellow]Run[white]() -}` - -// TextView1 demonstrates the basic text view. -func TextView1(nextSlide func()) (title string, content tview.Primitive) { - textView := tview.NewTextView(). - SetTextColor(tcell.ColorYellow). - SetScrollable(false). - SetDoneFunc(func(key tcell.Key) { - nextSlide() - }) - textView.SetChangedFunc(func() { - if textView.HasFocus() { - app.Draw() - } - }) - go func() { - var n int - for { - if textView.HasFocus() { - n++ - if n > 512 { - n = 1 - textView.SetText("") - } - - fmt.Fprintf(textView, "%d ", n) - time.Sleep(200 * time.Millisecond) - } else { - time.Sleep(time.Second) - } - } - }() - textView.SetBorder(true).SetTitle("TextView implements io.Writer") - return "Text 1", Code(textView, 36, 13, textView1) -} - -const textView2 = `[green]package[white] main - -[green]import[white] ( - [red]"strconv"[white] - - [red]"github.com/gdamore/tcell/v2"[white] - [red]"github.com/rivo/tview"[white] -) - -[green]func[white] [yellow]main[white]() { - ["0"]textView[""] := tview.[yellow]NewTextView[white]() - ["1"]textView[""].[yellow]SetDynamicColors[white](true). - [yellow]SetWrap[white](false). - [yellow]SetRegions[white](true). - [yellow]SetDoneFunc[white]([yellow]func[white](key tcell.Key) { - highlights := ["2"]textView[""].[yellow]GetHighlights[white]() - hasHighlights := [yellow]len[white](highlights) > [red]0 - [yellow]switch[white] key { - [yellow]case[white] tcell.KeyEnter: - [yellow]if[white] hasHighlights { - ["3"]textView[""].[yellow]Highlight[white]() - } [yellow]else[white] { - ["4"]textView[""].[yellow]Highlight[white]([red]"0"[white]). - [yellow]ScrollToHighlight[white]() - } - [yellow]case[white] tcell.KeyTab: - [yellow]if[white] hasHighlights { - current, _ := strconv.[yellow]Atoi[white](highlights[[red]0[white]]) - next := (current + [red]1[white]) % [red]9 - ["5"]textView[""].[yellow]Highlight[white](strconv.[yellow]Itoa[white](next)). - [yellow]ScrollToHighlight[white]() - } - [yellow]case[white] tcell.KeyBacktab: - [yellow]if[white] hasHighlights { - current, _ := strconv.[yellow]Atoi[white](highlights[[red]0[white]]) - next := (current - [red]1[white] + [red]9[white]) % [red]9 - ["6"]textView[""].[yellow]Highlight[white](strconv.[yellow]Itoa[white](next)). - [yellow]ScrollToHighlight[white]() - } - } - }) - fmt.[yellow]Fprint[white](["7"]textView[""], content) - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](["8"]textView[""], true). - [yellow]Run[white]() -}` - -// TextView2 demonstrates the extended text view. -func TextView2(nextSlide func()) (title string, content tview.Primitive) { - codeView := tview.NewTextView(). - SetWrap(false) - fmt.Fprint(codeView, textView2) - codeView.SetBorder(true).SetTitle("Buffer content") - - textView := tview.NewTextView() - textView.SetDynamicColors(true). - SetWrap(false). - SetRegions(true). - SetDoneFunc(func(key tcell.Key) { - if key == tcell.KeyEscape { - nextSlide() - return - } - highlights := textView.GetHighlights() - hasHighlights := len(highlights) > 0 - switch key { - case tcell.KeyEnter: - if hasHighlights { - textView.Highlight() - } else { - textView.Highlight("0"). - ScrollToHighlight() - } - case tcell.KeyTab: - if hasHighlights { - current, _ := strconv.Atoi(highlights[0]) - next := (current + 1) % 9 - textView.Highlight(strconv.Itoa(next)). - ScrollToHighlight() - } - case tcell.KeyBacktab: - if hasHighlights { - current, _ := strconv.Atoi(highlights[0]) - next := (current - 1 + 9) % 9 - textView.Highlight(strconv.Itoa(next)). - ScrollToHighlight() - } - } - }) - fmt.Fprint(textView, textView2) - textView.SetBorder(true).SetTitle("TextView output") - return "Text 2", tview.NewFlex(). - AddItem(textView, 0, 1, true). - AddItem(codeView, 0, 1, false) -} diff --git a/vendor/github.com/rivo/tview/demos/presentation/treeview.go b/vendor/github.com/rivo/tview/demos/presentation/treeview.go deleted file mode 100644 index 0dd8b86..0000000 --- a/vendor/github.com/rivo/tview/demos/presentation/treeview.go +++ /dev/null @@ -1,149 +0,0 @@ -package main - -import ( - "strings" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const treeAllCode = `[green]package[white] main - -[green]import[white] [red]"github.com/rivo/tview"[white] - -[green]func[white] [yellow]main[white]() { - $$$ - - root := tview.[yellow]NewTreeNode[white]([red]"Root"[white]). - [yellow]AddChild[white](tview.[yellow]NewTreeNode[white]([red]"First child"[white]). - [yellow]AddChild[white](tview.[yellow]NewTreeNode[white]([red]"Grandchild A"[white])). - [yellow]AddChild[white](tview.[yellow]NewTreeNode[white]([red]"Grandchild B"[white]))). - [yellow]AddChild[white](tview.[yellow]NewTreeNode[white]([red]"Second child"[white]). - [yellow]AddChild[white](tview.[yellow]NewTreeNode[white]([red]"Grandchild C"[white])). - [yellow]AddChild[white](tview.[yellow]NewTreeNode[white]([red]"Grandchild D"[white]))). - [yellow]AddChild[white](tview.[yellow]NewTreeNode[white]([red]"Third child"[white])) - - tree.[yellow]SetRoot[white](root). - [yellow]SetCurrentNode[white](root) - - tview.[yellow]NewApplication[white](). - [yellow]SetRoot[white](tree, true). - [yellow]Run[white]() -}` - -const treeBasicCode = `tree := tview.[yellow]NewTreeView[white]()` - -const treeTopLevelCode = `tree := tview.[yellow]NewTreeView[white](). - [yellow]SetTopLevel[white]([red]1[white])` - -const treeAlignCode = `tree := tview.[yellow]NewTreeView[white](). - [yellow]SetAlign[white](true)` - -const treePrefixCode = `tree := tview.[yellow]NewTreeView[white](). - [yellow]SetGraphics[white](false). - [yellow]SetTopLevel[white]([red]1[white]). - [yellow]SetPrefixes[white]([][green]string[white]{ - [red]"[red[]* "[white], - [red]"[darkcyan[]- "[white], - [red]"[darkmagenta[]- "[white], - })` - -type node struct { - text string - expand bool - selected func() - children []*node -} - -var ( - tree = tview.NewTreeView() - treeNextSlide func() - treeCode = tview.NewTextView().SetWrap(false).SetDynamicColors(true) -) - -var rootNode = &node{ - text: "Root", - children: []*node{ - {text: "Expand all", selected: func() { tree.GetRoot().ExpandAll() }}, - {text: "Collapse all", selected: func() { - for _, child := range tree.GetRoot().GetChildren() { - child.CollapseAll() - } - }}, - {text: "Hide root node", expand: true, children: []*node{ - {text: "Tree list starts one level down"}, - {text: "Works better for lists where no top node is needed"}, - {text: "Switch to this layout", selected: func() { - tree.SetAlign(false).SetTopLevel(1).SetGraphics(true).SetPrefixes(nil) - treeCode.SetText(strings.Replace(treeAllCode, "$$$", treeTopLevelCode, -1)) - }}, - }}, - {text: "Align node text", expand: true, children: []*node{ - {text: "For trees that are similar to lists"}, - {text: "Hierarchy shown only in line drawings"}, - {text: "Switch to this layout", selected: func() { - tree.SetAlign(true).SetTopLevel(0).SetGraphics(true).SetPrefixes(nil) - treeCode.SetText(strings.Replace(treeAllCode, "$$$", treeAlignCode, -1)) - }}, - }}, - {text: "Prefixes", expand: true, children: []*node{ - {text: "Best for hierarchical bullet point lists"}, - {text: "You can define your own prefixes per level"}, - {text: "Switch to this layout", selected: func() { - tree.SetAlign(false).SetTopLevel(1).SetGraphics(false).SetPrefixes([]string{"[red]* ", "[darkcyan]- ", "[darkmagenta]- "}) - treeCode.SetText(strings.Replace(treeAllCode, "$$$", treePrefixCode, -1)) - }}, - }}, - {text: "Basic tree with graphics", expand: true, children: []*node{ - {text: "Lines illustrate hierarchy"}, - {text: "Basic indentation"}, - {text: "Switch to this layout", selected: func() { - tree.SetAlign(false).SetTopLevel(0).SetGraphics(true).SetPrefixes(nil) - treeCode.SetText(strings.Replace(treeAllCode, "$$$", treeBasicCode, -1)) - }}, - }}, - {text: "Next slide", selected: func() { treeNextSlide() }}, - }} - -// TreeView demonstrates the tree view. -func TreeView(nextSlide func()) (title string, content tview.Primitive) { - treeNextSlide = nextSlide - tree.SetBorder(true). - SetTitle("TreeView") - - // Add nodes. - var add func(target *node) *tview.TreeNode - add = func(target *node) *tview.TreeNode { - node := tview.NewTreeNode(target.text). - SetSelectable(target.expand || target.selected != nil). - SetExpanded(target == rootNode). - SetReference(target) - if target.expand { - node.SetColor(tcell.ColorGreen) - } else if target.selected != nil { - node.SetColor(tcell.ColorRed) - } - for _, child := range target.children { - node.AddChild(add(child)) - } - return node - } - root := add(rootNode) - tree.SetRoot(root). - SetCurrentNode(root). - SetSelectedFunc(func(n *tview.TreeNode) { - original := n.GetReference().(*node) - if original.expand { - n.SetExpanded(!n.IsExpanded()) - } else if original.selected != nil { - original.selected() - } - }) - - treeCode.SetText(strings.Replace(treeAllCode, "$$$", treeBasicCode, -1)). - SetBorderPadding(1, 1, 2, 0) - - return "Tree", tview.NewFlex(). - AddItem(tree, 0, 1, true). - AddItem(treeCode, codeWidth, 1, false) -} diff --git a/vendor/github.com/rivo/tview/demos/primitive/README.md b/vendor/github.com/rivo/tview/demos/primitive/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/primitive/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/primitive/boxwithcenterline.png b/vendor/github.com/rivo/tview/demos/primitive/boxwithcenterline.png deleted file mode 100644 index 104ee5b..0000000 Binary files a/vendor/github.com/rivo/tview/demos/primitive/boxwithcenterline.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/primitive/main.go b/vendor/github.com/rivo/tview/demos/primitive/main.go deleted file mode 100644 index 398a45e..0000000 --- a/vendor/github.com/rivo/tview/demos/primitive/main.go +++ /dev/null @@ -1,92 +0,0 @@ -// Demo code which illustrates how to implement your own primitive. -package main - -import ( - "fmt" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// RadioButtons implements a simple primitive for radio button selections. -type RadioButtons struct { - *tview.Box - options []string - currentOption int -} - -// NewRadioButtons returns a new radio button primitive. -func NewRadioButtons(options []string) *RadioButtons { - return &RadioButtons{ - Box: tview.NewBox(), - options: options, - } -} - -// Draw draws this primitive onto the screen. -func (r *RadioButtons) Draw(screen tcell.Screen) { - r.Box.DrawForSubclass(screen, r) - x, y, width, height := r.GetInnerRect() - - for index, option := range r.options { - if index >= height { - break - } - radioButton := "\u25ef" // Unchecked. - if index == r.currentOption { - radioButton = "\u25c9" // Checked. - } - line := fmt.Sprintf(`%s[white] %s`, radioButton, option) - tview.Print(screen, line, x, y+index, width, tview.AlignLeft, tcell.ColorYellow) - } -} - -// InputHandler returns the handler for this primitive. -func (r *RadioButtons) InputHandler() func(event *tcell.EventKey, setFocus func(p tview.Primitive)) { - return r.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p tview.Primitive)) { - switch event.Key() { - case tcell.KeyUp: - r.currentOption-- - if r.currentOption < 0 { - r.currentOption = 0 - } - case tcell.KeyDown: - r.currentOption++ - if r.currentOption >= len(r.options) { - r.currentOption = len(r.options) - 1 - } - } - }) -} - -// MouseHandler returns the mouse handler for this primitive. -func (r *RadioButtons) MouseHandler() func(action tview.MouseAction, event *tcell.EventMouse, setFocus func(p tview.Primitive)) (consumed bool, capture tview.Primitive) { - return r.WrapMouseHandler(func(action tview.MouseAction, event *tcell.EventMouse, setFocus func(p tview.Primitive)) (consumed bool, capture tview.Primitive) { - x, y := event.Position() - _, rectY, _, _ := r.GetInnerRect() - if !r.InRect(x, y) { - return false, nil - } - - if action == tview.MouseLeftClick { - setFocus(r) - index := y - rectY - if index >= 0 && index < len(r.options) { - r.currentOption = index - consumed = true - } - } - - return - }) -} - -func main() { - radioButtons := NewRadioButtons([]string{"Lions", "Elephants", "Giraffes"}) - radioButtons.SetBorder(true). - SetTitle("Radio Button Demo"). - SetRect(0, 0, 30, 5) - if err := tview.NewApplication().SetRoot(radioButtons, false).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/primitive/screenshot.png b/vendor/github.com/rivo/tview/demos/primitive/screenshot.png deleted file mode 100644 index 1c04526..0000000 Binary files a/vendor/github.com/rivo/tview/demos/primitive/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/primitive/textviewwithcenterline.png b/vendor/github.com/rivo/tview/demos/primitive/textviewwithcenterline.png deleted file mode 100644 index 0376ff5..0000000 Binary files a/vendor/github.com/rivo/tview/demos/primitive/textviewwithcenterline.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/table/README.md b/vendor/github.com/rivo/tview/demos/table/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/table/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/table/main.go b/vendor/github.com/rivo/tview/demos/table/main.go deleted file mode 100644 index e67a83d..0000000 --- a/vendor/github.com/rivo/tview/demos/table/main.go +++ /dev/null @@ -1,45 +0,0 @@ -// Demo code for the Table primitive. -package main - -import ( - "strings" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - table := tview.NewTable(). - SetBorders(true) - lorem := strings.Split("Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.", " ") - cols, rows := 10, 40 - word := 0 - for r := 0; r < rows; r++ { - for c := 0; c < cols; c++ { - color := tcell.ColorWhite - if c < 1 || r < 1 { - color = tcell.ColorYellow - } - table.SetCell(r, c, - tview.NewTableCell(lorem[word]). - SetTextColor(color). - SetAlign(tview.AlignCenter)) - word = (word + 1) % len(lorem) - } - } - table.Select(0, 0).SetFixed(1, 1).SetDoneFunc(func(key tcell.Key) { - if key == tcell.KeyEscape { - app.Stop() - } - if key == tcell.KeyEnter { - table.SetSelectable(true, true) - } - }).SetSelectedFunc(func(row int, column int) { - table.GetCell(row, column).SetTextColor(tcell.ColorRed) - table.SetSelectable(false, false) - }) - if err := app.SetRoot(table, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/table/screenshot.png b/vendor/github.com/rivo/tview/demos/table/screenshot.png deleted file mode 100644 index b473aef..0000000 Binary files a/vendor/github.com/rivo/tview/demos/table/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/textview/README.md b/vendor/github.com/rivo/tview/demos/textview/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/textview/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/textview/main.go b/vendor/github.com/rivo/tview/demos/textview/main.go deleted file mode 100644 index 1235a83..0000000 --- a/vendor/github.com/rivo/tview/demos/textview/main.go +++ /dev/null @@ -1,69 +0,0 @@ -// Demo code for the TextView primitive. -package main - -import ( - "fmt" - "strconv" - "strings" - "time" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -const corporate = `Leverage agile frameworks to provide a robust synopsis for high level overviews. Iterative approaches to corporate strategy foster collaborative thinking to further the overall value proposition. Organically grow the holistic world view of disruptive innovation via workplace diversity and empowerment. - -Bring to the table win-win survival strategies to ensure proactive domination. At the end of the day, going forward, a new normal that has evolved from generation X is on the runway heading towards a streamlined cloud solution. User generated content in real-time will have multiple touchpoints for offshoring. - -Capitalize on low hanging fruit to identify a ballpark value added activity to beta test. Override the digital divide with additional clickthroughs from DevOps. Nanotechnology immersion along the information highway will close the loop on focusing solely on the bottom line. - -[yellow]Press Enter, then Tab/Backtab for word selections` - -func main() { - app := tview.NewApplication() - textView := tview.NewTextView(). - SetDynamicColors(true). - SetRegions(true). - SetWordWrap(true). - SetChangedFunc(func() { - app.Draw() - }) - numSelections := 0 - go func() { - for _, word := range strings.Split(corporate, " ") { - if word == "the" { - word = "[#ff0000]the[white]" - } - if word == "to" { - word = fmt.Sprintf(`["%d"]to[""]`, numSelections) - numSelections++ - } - fmt.Fprintf(textView, "%s ", word) - time.Sleep(200 * time.Millisecond) - } - }() - textView.SetDoneFunc(func(key tcell.Key) { - currentSelection := textView.GetHighlights() - if key == tcell.KeyEnter { - if len(currentSelection) > 0 { - textView.Highlight() - } else { - textView.Highlight("0").ScrollToHighlight() - } - } else if len(currentSelection) > 0 { - index, _ := strconv.Atoi(currentSelection[0]) - if key == tcell.KeyTab { - index = (index + 1) % numSelections - } else if key == tcell.KeyBacktab { - index = (index - 1 + numSelections) % numSelections - } else { - return - } - textView.Highlight(strconv.Itoa(index)).ScrollToHighlight() - } - }) - textView.SetBorder(true) - if err := app.SetRoot(textView, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/textview/screenshot.png b/vendor/github.com/rivo/tview/demos/textview/screenshot.png deleted file mode 100644 index 8d7f0bb..0000000 Binary files a/vendor/github.com/rivo/tview/demos/textview/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/treeview/README.md b/vendor/github.com/rivo/tview/demos/treeview/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/treeview/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/treeview/main.go b/vendor/github.com/rivo/tview/demos/treeview/main.go deleted file mode 100644 index ee81d4a..0000000 --- a/vendor/github.com/rivo/tview/demos/treeview/main.go +++ /dev/null @@ -1,62 +0,0 @@ -// Demo code for the TreeView primitive. -package main - -import ( - "io/ioutil" - "path/filepath" - - "github.com/gdamore/tcell/v2" - "github.com/rivo/tview" -) - -// Show a navigable tree view of the current directory. -func main() { - rootDir := "." - root := tview.NewTreeNode(rootDir). - SetColor(tcell.ColorRed) - tree := tview.NewTreeView(). - SetRoot(root). - SetCurrentNode(root) - - // A helper function which adds the files and directories of the given path - // to the given target node. - add := func(target *tview.TreeNode, path string) { - files, err := ioutil.ReadDir(path) - if err != nil { - panic(err) - } - for _, file := range files { - node := tview.NewTreeNode(file.Name()). - SetReference(filepath.Join(path, file.Name())). - SetSelectable(file.IsDir()) - if file.IsDir() { - node.SetColor(tcell.ColorGreen) - } - target.AddChild(node) - } - } - - // Add the current directory to the root node. - add(root, rootDir) - - // If a directory was selected, open it. - tree.SetSelectedFunc(func(node *tview.TreeNode) { - reference := node.GetReference() - if reference == nil { - return // Selecting the root node does nothing. - } - children := node.GetChildren() - if len(children) == 0 { - // Load and show files in this directory. - path := reference.(string) - add(node, path) - } else { - // Collapse if visible, expand if collapsed. - node.SetExpanded(!node.IsExpanded()) - } - }) - - if err := tview.NewApplication().SetRoot(tree, true).EnableMouse(true).Run(); err != nil { - panic(err) - } -} diff --git a/vendor/github.com/rivo/tview/demos/treeview/screenshot.png b/vendor/github.com/rivo/tview/demos/treeview/screenshot.png deleted file mode 100644 index c25fcf5..0000000 Binary files a/vendor/github.com/rivo/tview/demos/treeview/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/demos/unicode/README.md b/vendor/github.com/rivo/tview/demos/unicode/README.md deleted file mode 100644 index 4a14e6c..0000000 --- a/vendor/github.com/rivo/tview/demos/unicode/README.md +++ /dev/null @@ -1 +0,0 @@ -![Screenshot](screenshot.png) diff --git a/vendor/github.com/rivo/tview/demos/unicode/main.go b/vendor/github.com/rivo/tview/demos/unicode/main.go deleted file mode 100644 index 761b100..0000000 --- a/vendor/github.com/rivo/tview/demos/unicode/main.go +++ /dev/null @@ -1,49 +0,0 @@ -// Demo code for unicode support (demonstrates wide Chinese characters). -package main - -import ( - "fmt" - - "github.com/rivo/tview" -) - -func main() { - app := tview.NewApplication() - pages := tview.NewPages() - - form := tview.NewForm() - form.AddDropDown("称谓", []string{"先生", "女士", "博士", "老师", "师傅"}, 0, nil). - AddInputField("姓名", "", 20, nil, nil). - AddCheckbox("年龄 18+", false, nil). - AddPasswordField("密码", "", 10, '*', nil). - AddButton("保存", func() { - _, title := form.GetFormItem(0).(*tview.DropDown).GetCurrentOption() - userName := form.GetFormItem(1).(*tview.InputField).GetText() - - alert(pages, "alert-dialog", fmt.Sprintf("保存成功,%s %s!", userName, title)) - }). - AddButton("退出", func() { - app.Stop() - }) - form.SetBorder(true).SetTitle("输入一些内容").SetTitleAlign(tview.AlignLeft) - pages.AddPage("base", form, true, true) - - if err := app.SetRoot(pages, true).Run(); err != nil { - panic(err) - } -} - -// alert shows a confirmation dialog. -func alert(pages *tview.Pages, id string, message string) *tview.Pages { - return pages.AddPage( - id, - tview.NewModal(). - SetText(message). - AddButtons([]string{"确定"}). - SetDoneFunc(func(buttonIndex int, buttonLabel string) { - pages.HidePage(id).RemovePage(id) - }), - false, - true, - ) -} diff --git a/vendor/github.com/rivo/tview/demos/unicode/screenshot.png b/vendor/github.com/rivo/tview/demos/unicode/screenshot.png deleted file mode 100644 index 5d0d974..0000000 Binary files a/vendor/github.com/rivo/tview/demos/unicode/screenshot.png and /dev/null differ diff --git a/vendor/github.com/rivo/tview/doc.go b/vendor/github.com/rivo/tview/doc.go deleted file mode 100644 index 1e11412..0000000 --- a/vendor/github.com/rivo/tview/doc.go +++ /dev/null @@ -1,179 +0,0 @@ -/* -Package tview implements rich widgets for terminal based user interfaces. The -widgets provided with this package are useful for data exploration and data -entry. - -Widgets - -The package implements the following widgets: - - - TextView: A scrollable window that display multi-colored text. Text may also - be highlighted. - - Table: A scrollable display of tabular data. Table cells, rows, or columns - may also be highlighted. - - TreeView: A scrollable display for hierarchical data. Tree nodes can be - highlighted, collapsed, expanded, and more. - - List: A navigable text list with optional keyboard shortcuts. - - InputField: One-line input fields to enter text. - - DropDown: Drop-down selection fields. - - Checkbox: Selectable checkbox for boolean values. - - Button: Buttons which get activated when the user selects them. - - Form: Forms composed of input fields, drop down selections, checkboxes, and - buttons. - - Modal: A centered window with a text message and one or more buttons. - - Grid: A grid based layout manager. - - Flex: A Flexbox based layout manager. - - Pages: A page based layout manager. - -The package also provides Application which is used to poll the event queue and -draw widgets on screen. - -Hello World - -The following is a very basic example showing a box with the title "Hello, -world!": - - package main - - import ( - "github.com/rivo/tview" - ) - - func main() { - box := tview.NewBox().SetBorder(true).SetTitle("Hello, world!") - if err := tview.NewApplication().SetRoot(box, true).Run(); err != nil { - panic(err) - } - } - -First, we create a box primitive with a border and a title. Then we create an -application, set the box as its root primitive, and run the event loop. The -application exits when the application's Stop() function is called or when -Ctrl-C is pressed. - -If we have a primitive which consumes key presses, we call the application's -SetFocus() function to redirect all key presses to that primitive. Most -primitives then offer ways to install handlers that allow you to react to any -actions performed on them. - -More Demos - -You will find more demos in the "demos" subdirectory. It also contains a -presentation (written using tview) which gives an overview of the different -widgets and how they can be used. - -Colors - -Throughout this package, colors are specified using the tcell.Color type. -Functions such as tcell.GetColor(), tcell.NewHexColor(), and tcell.NewRGBColor() -can be used to create colors from W3C color names or RGB values. - -Almost all strings which are displayed can contain color tags. Color tags are -W3C color names or six hexadecimal digits following a hash tag, wrapped in -square brackets. Examples: - - This is a [red]warning[white]! - The sky is [#8080ff]blue[#ffffff]. - -A color tag changes the color of the characters following that color tag. This -applies to almost everything from box titles, list text, form item labels, to -table cells. In a TextView, this functionality has to be switched on explicitly. -See the TextView documentation for more information. - -Color tags may contain not just the foreground (text) color but also the -background color and additional flags. In fact, the full definition of a color -tag is as follows: - - [::] - -Each of the three fields can be left blank and trailing fields can be omitted. -(Empty square brackets "[]", however, are not considered color tags.) Colors -that are not specified will be left unchanged. A field with just a dash ("-") -means "reset to default". - -You can specify the following flags (some flags may not be supported by your -terminal): - - l: blink - b: bold - d: dim - r: reverse (switch foreground and background color) - u: underline - -Examples: - - [yellow]Yellow text - [yellow:red]Yellow text on red background - [:red]Red background, text color unchanged - [yellow::u]Yellow text underlined - [::bl]Bold, blinking text - [::-]Colors unchanged, flags reset - [-]Reset foreground color - [-:-:-]Reset everything - [:]No effect - []Not a valid color tag, will print square brackets as they are - -In the rare event that you want to display a string such as "[red]" or -"[#00ff1a]" without applying its effect, you need to put an opening square -bracket before the closing square bracket. Note that the text inside the -brackets will be matched less strictly than region or colors tags. I.e. any -character that may be used in color or region tags will be recognized. Examples: - - [red[] will be output as [red] - ["123"[] will be output as ["123"] - [#6aff00[[] will be output as [#6aff00[] - [a#"[[[] will be output as [a#"[[] - [] will be output as [] (see color tags above) - [[] will be output as [[] (not an escaped tag) - -You can use the Escape() function to insert brackets automatically where needed. - -Styles - -When primitives are instantiated, they are initialized with colors taken from -the global Styles variable. You may change this variable to adapt the look and -feel of the primitives to your preferred style. - -Unicode Support - -This package supports unicode characters including wide characters. - -Concurrency - -Many functions in this package are not thread-safe. For many applications, this -may not be an issue: If your code makes changes in response to key events, it -will execute in the main goroutine and thus will not cause any race conditions. - -If you access your primitives from other goroutines, however, you will need to -synchronize execution. The easiest way to do this is to call -Application.QueueUpdate() or Application.QueueUpdateDraw() (see the function -documentation for details): - - go func() { - app.QueueUpdateDraw(func() { - table.SetCellSimple(0, 0, "Foo bar") - }) - }() - -One exception to this is the io.Writer interface implemented by TextView. You -can safely write to a TextView from any goroutine. See the TextView -documentation for details. - -You can also call Application.Draw() from any goroutine without having to wrap -it in QueueUpdate(). And, as mentioned above, key event callbacks are executed -in the main goroutine and thus should not use QueueUpdate() as that may lead to -deadlocks. - -Type Hierarchy - -All widgets listed above contain the Box type. All of Box's functions are -therefore available for all widgets, too. - -All widgets also implement the Primitive interface. - -The tview package is based on https://github.com/gdamore/tcell. It uses types -and constants from that package (e.g. colors and keyboard values). - -This package does not process mouse input (yet). -*/ -package tview diff --git a/vendor/github.com/rivo/tview/dropdown.go b/vendor/github.com/rivo/tview/dropdown.go deleted file mode 100644 index a4a26ac..0000000 --- a/vendor/github.com/rivo/tview/dropdown.go +++ /dev/null @@ -1,553 +0,0 @@ -package tview - -import ( - "strings" - - "github.com/gdamore/tcell/v2" -) - -// dropDownOption is one option that can be selected in a drop-down primitive. -type dropDownOption struct { - Text string // The text to be displayed in the drop-down. - Selected func() // The (optional) callback for when this option was selected. -} - -// DropDown implements a selection widget whose options become visible in a -// drop-down list when activated. -// -// See https://github.com/rivo/tview/wiki/DropDown for an example. -type DropDown struct { - *Box - - // The options from which the user can choose. - options []*dropDownOption - - // Strings to be placed before and after each drop-down option. - optionPrefix, optionSuffix string - - // The index of the currently selected option. Negative if no option is - // currently selected. - currentOption int - - // Strings to be placed beefore and after the current option. - currentOptionPrefix, currentOptionSuffix string - - // The text to be displayed when no option has yet been selected. - noSelection string - - // Set to true if the options are visible and selectable. - open bool - - // The runes typed so far to directly access one of the list items. - prefix string - - // The list element for the options. - list *List - - // The text to be displayed before the input area. - label string - - // The label color. - labelColor tcell.Color - - // The background color of the input area. - fieldBackgroundColor tcell.Color - - // The text color of the input area. - fieldTextColor tcell.Color - - // The color for prefixes. - prefixTextColor tcell.Color - - // The screen width of the label area. A value of 0 means use the width of - // the label text. - labelWidth int - - // The screen width of the input area. A value of 0 means extend as much as - // possible. - fieldWidth int - - // An optional function which is called when the user indicated that they - // are done selecting options. The key which was pressed is provided (tab, - // shift-tab, or escape). - done func(tcell.Key) - - // A callback function set by the Form class and called when the user leaves - // this form item. - finished func(tcell.Key) - - // A callback function which is called when the user changes the drop-down's - // selection. - selected func(text string, index int) - - dragging bool // Set to true when mouse dragging is in progress. -} - -// NewDropDown returns a new drop-down. -func NewDropDown() *DropDown { - list := NewList() - list.ShowSecondaryText(false). - SetMainTextColor(Styles.PrimitiveBackgroundColor). - SetSelectedTextColor(Styles.PrimitiveBackgroundColor). - SetSelectedBackgroundColor(Styles.PrimaryTextColor). - SetHighlightFullLine(true). - SetBackgroundColor(Styles.MoreContrastBackgroundColor) - - d := &DropDown{ - Box: NewBox(), - currentOption: -1, - list: list, - labelColor: Styles.SecondaryTextColor, - fieldBackgroundColor: Styles.ContrastBackgroundColor, - fieldTextColor: Styles.PrimaryTextColor, - prefixTextColor: Styles.ContrastSecondaryTextColor, - } - - return d -} - -// SetCurrentOption sets the index of the currently selected option. This may -// be a negative value to indicate that no option is currently selected. Calling -// this function will also trigger the "selected" callback (if there is one). -func (d *DropDown) SetCurrentOption(index int) *DropDown { - if index >= 0 && index < len(d.options) { - d.currentOption = index - d.list.SetCurrentItem(index) - if d.selected != nil { - d.selected(d.options[index].Text, index) - } - if d.options[index].Selected != nil { - d.options[index].Selected() - } - } else { - d.currentOption = -1 - d.list.SetCurrentItem(0) // Set to 0 because -1 means "last item". - if d.selected != nil { - d.selected("", -1) - } - } - return d -} - -// GetCurrentOption returns the index of the currently selected option as well -// as its text. If no option was selected, -1 and an empty string is returned. -func (d *DropDown) GetCurrentOption() (int, string) { - var text string - if d.currentOption >= 0 && d.currentOption < len(d.options) { - text = d.options[d.currentOption].Text - } - return d.currentOption, text -} - -// SetTextOptions sets the text to be placed before and after each drop-down -// option (prefix/suffix), the text placed before and after the currently -// selected option (currentPrefix/currentSuffix) as well as the text to be -// displayed when no option is currently selected. Per default, all of these -// strings are empty. -func (d *DropDown) SetTextOptions(prefix, suffix, currentPrefix, currentSuffix, noSelection string) *DropDown { - d.currentOptionPrefix = currentPrefix - d.currentOptionSuffix = currentSuffix - d.noSelection = noSelection - d.optionPrefix = prefix - d.optionSuffix = suffix - for index := 0; index < d.list.GetItemCount(); index++ { - d.list.SetItemText(index, prefix+d.options[index].Text+suffix, "") - } - return d -} - -// SetLabel sets the text to be displayed before the input area. -func (d *DropDown) SetLabel(label string) *DropDown { - d.label = label - return d -} - -// GetLabel returns the text to be displayed before the input area. -func (d *DropDown) GetLabel() string { - return d.label -} - -// SetLabelWidth sets the screen width of the label. A value of 0 will cause the -// primitive to use the width of the label string. -func (d *DropDown) SetLabelWidth(width int) *DropDown { - d.labelWidth = width - return d -} - -// SetLabelColor sets the color of the label. -func (d *DropDown) SetLabelColor(color tcell.Color) *DropDown { - d.labelColor = color - return d -} - -// SetFieldBackgroundColor sets the background color of the options area. -func (d *DropDown) SetFieldBackgroundColor(color tcell.Color) *DropDown { - d.fieldBackgroundColor = color - return d -} - -// SetFieldTextColor sets the text color of the options area. -func (d *DropDown) SetFieldTextColor(color tcell.Color) *DropDown { - d.fieldTextColor = color - return d -} - -// SetPrefixTextColor sets the color of the prefix string. The prefix string is -// shown when the user starts typing text, which directly selects the first -// option that starts with the typed string. -func (d *DropDown) SetPrefixTextColor(color tcell.Color) *DropDown { - d.prefixTextColor = color - return d -} - -// SetFormAttributes sets attributes shared by all form items. -func (d *DropDown) SetFormAttributes(labelWidth int, labelColor, bgColor, fieldTextColor, fieldBgColor tcell.Color) FormItem { - d.labelWidth = labelWidth - d.labelColor = labelColor - d.backgroundColor = bgColor - d.fieldTextColor = fieldTextColor - d.fieldBackgroundColor = fieldBgColor - return d -} - -// SetFieldWidth sets the screen width of the options area. A value of 0 means -// extend to as long as the longest option text. -func (d *DropDown) SetFieldWidth(width int) *DropDown { - d.fieldWidth = width - return d -} - -// GetFieldWidth returns this primitive's field screen width. -func (d *DropDown) GetFieldWidth() int { - if d.fieldWidth > 0 { - return d.fieldWidth - } - fieldWidth := 0 - for _, option := range d.options { - width := TaggedStringWidth(option.Text) - if width > fieldWidth { - fieldWidth = width - } - } - return fieldWidth -} - -// AddOption adds a new selectable option to this drop-down. The "selected" -// callback is called when this option was selected. It may be nil. -func (d *DropDown) AddOption(text string, selected func()) *DropDown { - d.options = append(d.options, &dropDownOption{Text: text, Selected: selected}) - d.list.AddItem(d.optionPrefix+text+d.optionSuffix, "", 0, nil) - return d -} - -// SetOptions replaces all current options with the ones provided and installs -// one callback function which is called when one of the options is selected. -// It will be called with the option's text and its index into the options -// slice. The "selected" parameter may be nil. -func (d *DropDown) SetOptions(texts []string, selected func(text string, index int)) *DropDown { - d.list.Clear() - d.options = nil - for index, text := range texts { - func(t string, i int) { - d.AddOption(text, nil) - }(text, index) - } - d.selected = selected - return d -} - -// SetSelectedFunc sets a handler which is called when the user changes the -// drop-down's option. This handler will be called in addition and prior to -// an option's optional individual handler. The handler is provided with the -// selected option's text and index. If "no option" was selected, these values -// are an empty string and -1. -func (d *DropDown) SetSelectedFunc(handler func(text string, index int)) *DropDown { - d.selected = handler - return d -} - -// SetDoneFunc sets a handler which is called when the user is done selecting -// options. The callback function is provided with the key that was pressed, -// which is one of the following: -// -// - KeyEscape: Abort selection. -// - KeyTab: Move to the next field. -// - KeyBacktab: Move to the previous field. -func (d *DropDown) SetDoneFunc(handler func(key tcell.Key)) *DropDown { - d.done = handler - return d -} - -// SetFinishedFunc sets a callback invoked when the user leaves this form item. -func (d *DropDown) SetFinishedFunc(handler func(key tcell.Key)) FormItem { - d.finished = handler - return d -} - -// Draw draws this primitive onto the screen. -func (d *DropDown) Draw(screen tcell.Screen) { - d.Box.DrawForSubclass(screen, d) - - // Prepare. - x, y, width, height := d.GetInnerRect() - rightLimit := x + width - if height < 1 || rightLimit <= x { - return - } - - // Draw label. - if d.labelWidth > 0 { - labelWidth := d.labelWidth - if labelWidth > rightLimit-x { - labelWidth = rightLimit - x - } - Print(screen, d.label, x, y, labelWidth, AlignLeft, d.labelColor) - x += labelWidth - } else { - _, drawnWidth := Print(screen, d.label, x, y, rightLimit-x, AlignLeft, d.labelColor) - x += drawnWidth - } - - // What's the longest option text? - maxWidth := 0 - optionWrapWidth := TaggedStringWidth(d.optionPrefix + d.optionSuffix) - for _, option := range d.options { - strWidth := TaggedStringWidth(option.Text) + optionWrapWidth - if strWidth > maxWidth { - maxWidth = strWidth - } - } - - // Draw selection area. - fieldWidth := d.fieldWidth - if fieldWidth == 0 { - fieldWidth = maxWidth - if d.currentOption < 0 { - noSelectionWidth := TaggedStringWidth(d.noSelection) - if noSelectionWidth > fieldWidth { - fieldWidth = noSelectionWidth - } - } else if d.currentOption < len(d.options) { - currentOptionWidth := TaggedStringWidth(d.currentOptionPrefix + d.options[d.currentOption].Text + d.currentOptionSuffix) - if currentOptionWidth > fieldWidth { - fieldWidth = currentOptionWidth - } - } - } - if rightLimit-x < fieldWidth { - fieldWidth = rightLimit - x - } - fieldStyle := tcell.StyleDefault.Background(d.fieldBackgroundColor) - if d.HasFocus() && !d.open { - fieldStyle = fieldStyle.Background(d.fieldTextColor) - } - for index := 0; index < fieldWidth; index++ { - screen.SetContent(x+index, y, ' ', nil, fieldStyle) - } - - // Draw selected text. - if d.open && len(d.prefix) > 0 { - // Show the prefix. - currentOptionPrefixWidth := TaggedStringWidth(d.currentOptionPrefix) - prefixWidth := stringWidth(d.prefix) - listItemText := d.options[d.list.GetCurrentItem()].Text - Print(screen, d.currentOptionPrefix, x, y, fieldWidth, AlignLeft, d.fieldTextColor) - Print(screen, d.prefix, x+currentOptionPrefixWidth, y, fieldWidth-currentOptionPrefixWidth, AlignLeft, d.prefixTextColor) - if len(d.prefix) < len(listItemText) { - Print(screen, listItemText[len(d.prefix):]+d.currentOptionSuffix, x+prefixWidth+currentOptionPrefixWidth, y, fieldWidth-prefixWidth-currentOptionPrefixWidth, AlignLeft, d.fieldTextColor) - } - } else { - color := d.fieldTextColor - text := d.noSelection - if d.currentOption >= 0 && d.currentOption < len(d.options) { - text = d.currentOptionPrefix + d.options[d.currentOption].Text + d.currentOptionSuffix - } - // Just show the current selection. - if d.HasFocus() && !d.open { - color = d.fieldBackgroundColor - } - Print(screen, text, x, y, fieldWidth, AlignLeft, color) - } - - // Draw options list. - if d.HasFocus() && d.open { - // We prefer to drop down but if there is no space, maybe drop up? - lx := x - ly := y + 1 - lwidth := maxWidth - lheight := len(d.options) - _, sheight := screen.Size() - if ly+lheight >= sheight && ly-2 > lheight-ly { - ly = y - lheight - if ly < 0 { - ly = 0 - } - } - if ly+lheight >= sheight { - lheight = sheight - ly - } - d.list.SetRect(lx, ly, lwidth, lheight) - d.list.Draw(screen) - } -} - -// InputHandler returns the handler for this primitive. -func (d *DropDown) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return d.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - // If the list has focus, let it process its own key events. - if d.list.HasFocus() { - if handler := d.list.InputHandler(); handler != nil { - handler(event, setFocus) - } - return - } - - // Process key event. - switch key := event.Key(); key { - case tcell.KeyEnter, tcell.KeyRune, tcell.KeyDown: - d.prefix = "" - - // If the first key was a letter already, it becomes part of the prefix. - if r := event.Rune(); key == tcell.KeyRune && r != ' ' { - d.prefix += string(r) - d.evalPrefix() - } - - d.openList(setFocus) - case tcell.KeyEscape, tcell.KeyTab, tcell.KeyBacktab: - if d.done != nil { - d.done(key) - } - if d.finished != nil { - d.finished(key) - } - } - }) -} - -// evalPrefix selects an item in the drop-down list based on the current prefix. -func (d *DropDown) evalPrefix() { - if len(d.prefix) > 0 { - for index, option := range d.options { - if strings.HasPrefix(strings.ToLower(option.Text), d.prefix) { - d.list.SetCurrentItem(index) - return - } - } - - // Prefix does not match any item. Remove last rune. - r := []rune(d.prefix) - d.prefix = string(r[:len(r)-1]) - } -} - -// openList hands control over to the embedded List primitive. -func (d *DropDown) openList(setFocus func(Primitive)) { - d.open = true - optionBefore := d.currentOption - - d.list.SetSelectedFunc(func(index int, mainText, secondaryText string, shortcut rune) { - if d.dragging { - return // If we're dragging the mouse, we don't want to trigger any events. - } - - // An option was selected. Close the list again. - d.currentOption = index - d.closeList(setFocus) - - // Trigger "selected" event. - if d.selected != nil { - d.selected(d.options[d.currentOption].Text, d.currentOption) - } - if d.options[d.currentOption].Selected != nil { - d.options[d.currentOption].Selected() - } - }).SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { - if event.Key() == tcell.KeyRune { - d.prefix += string(event.Rune()) - d.evalPrefix() - } else if event.Key() == tcell.KeyBackspace || event.Key() == tcell.KeyBackspace2 { - if len(d.prefix) > 0 { - r := []rune(d.prefix) - d.prefix = string(r[:len(r)-1]) - } - d.evalPrefix() - } else if event.Key() == tcell.KeyEscape { - d.currentOption = optionBefore - d.closeList(setFocus) - } else { - d.prefix = "" - } - - return event - }) - - setFocus(d.list) -} - -// closeList closes the embedded List element by hiding it and removing focus -// from it. -func (d *DropDown) closeList(setFocus func(Primitive)) { - d.open = false - if d.list.HasFocus() { - setFocus(d) - } -} - -// Focus is called by the application when the primitive receives focus. -func (d *DropDown) Focus(delegate func(p Primitive)) { - d.Box.Focus(delegate) - if d.open { - delegate(d.list) - } -} - -// HasFocus returns whether or not this primitive has focus. -func (d *DropDown) HasFocus() bool { - if d.open { - return d.list.HasFocus() - } - return d.hasFocus -} - -// MouseHandler returns the mouse handler for this primitive. -func (d *DropDown) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return d.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - // Was the mouse event in the drop-down box itself (or on its label)? - x, y := event.Position() - _, rectY, _, _ := d.GetInnerRect() - inRect := y == rectY - if !d.open && !inRect { - return d.InRect(x, y), nil // No, and it's not expanded either. Ignore. - } - - // Handle dragging. Clicks are implicitly handled by this logic. - switch action { - case MouseLeftDown: - consumed = d.open || inRect - capture = d - if !d.open { - d.openList(setFocus) - d.dragging = true - } else if consumed, _ := d.list.MouseHandler()(MouseLeftClick, event, setFocus); !consumed { - d.closeList(setFocus) // Close drop-down if clicked outside of it. - } - case MouseMove: - if d.dragging { - // We pretend it's a left click so we can see the selection during - // dragging. Because we don't act upon it, it's not a problem. - d.list.MouseHandler()(MouseLeftClick, event, setFocus) - consumed = true - capture = d - } - case MouseLeftUp: - if d.dragging { - d.dragging = false - d.list.MouseHandler()(MouseLeftClick, event, setFocus) - consumed = true - } - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/flex.go b/vendor/github.com/rivo/tview/flex.go deleted file mode 100644 index a574d3c..0000000 --- a/vendor/github.com/rivo/tview/flex.go +++ /dev/null @@ -1,238 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// Configuration values. -const ( - FlexRow = iota - FlexColumn -) - -// flexItem holds layout options for one item. -type flexItem struct { - Item Primitive // The item to be positioned. May be nil for an empty item. - FixedSize int // The item's fixed size which may not be changed, 0 if it has no fixed size. - Proportion int // The item's proportion. - Focus bool // Whether or not this item attracts the layout's focus. -} - -// Flex is a basic implementation of the Flexbox layout. The contained -// primitives are arranged horizontally or vertically. The way they are -// distributed along that dimension depends on their layout settings, which is -// either a fixed length or a proportional length. See AddItem() for details. -// -// See https://github.com/rivo/tview/wiki/Flex for an example. -type Flex struct { - *Box - - // The items to be positioned. - items []*flexItem - - // FlexRow or FlexColumn. - direction int - - // If set to true, Flex will use the entire screen as its available space - // instead its box dimensions. - fullScreen bool -} - -// NewFlex returns a new flexbox layout container with no primitives and its -// direction set to FlexColumn. To add primitives to this layout, see AddItem(). -// To change the direction, see SetDirection(). -// -// Note that Box, the superclass of Flex, will have its background color set to -// transparent so that any nil flex items will leave their background unchanged. -// To clear a Flex's background before any items are drawn, set it to the -// desired color: -// -// flex.SetBackgroundColor(tview.Styles.PrimitiveBackgroundColor) -func NewFlex() *Flex { - f := &Flex{ - Box: NewBox().SetBackgroundColor(tcell.ColorDefault), - direction: FlexColumn, - } - return f -} - -// SetDirection sets the direction in which the contained primitives are -// distributed. This can be either FlexColumn (default) or FlexRow. -func (f *Flex) SetDirection(direction int) *Flex { - f.direction = direction - return f -} - -// SetFullScreen sets the flag which, when true, causes the flex layout to use -// the entire screen space instead of whatever size it is currently assigned to. -func (f *Flex) SetFullScreen(fullScreen bool) *Flex { - f.fullScreen = fullScreen - return f -} - -// AddItem adds a new item to the container. The "fixedSize" argument is a width -// or height that may not be changed by the layout algorithm. A value of 0 means -// that its size is flexible and may be changed. The "proportion" argument -// defines the relative size of the item compared to other flexible-size items. -// For example, items with a proportion of 2 will be twice as large as items -// with a proportion of 1. The proportion must be at least 1 if fixedSize == 0 -// (ignored otherwise). -// -// If "focus" is set to true, the item will receive focus when the Flex -// primitive receives focus. If multiple items have the "focus" flag set to -// true, the first one will receive focus. -// -// You can provide a nil value for the primitive. This will still consume screen -// space but nothing will be drawn. -func (f *Flex) AddItem(item Primitive, fixedSize, proportion int, focus bool) *Flex { - f.items = append(f.items, &flexItem{Item: item, FixedSize: fixedSize, Proportion: proportion, Focus: focus}) - return f -} - -// RemoveItem removes all items for the given primitive from the container, -// keeping the order of the remaining items intact. -func (f *Flex) RemoveItem(p Primitive) *Flex { - for index := len(f.items) - 1; index >= 0; index-- { - if f.items[index].Item == p { - f.items = append(f.items[:index], f.items[index+1:]...) - } - } - return f -} - -// Clear removes all items from the container. -func (f *Flex) Clear() *Flex { - f.items = nil - return f -} - -// ResizeItem sets a new size for the item(s) with the given primitive. If there -// are multiple Flex items with the same primitive, they will all receive the -// same size. For details regarding the size parameters, see AddItem(). -func (f *Flex) ResizeItem(p Primitive, fixedSize, proportion int) *Flex { - for _, item := range f.items { - if item.Item == p { - item.FixedSize = fixedSize - item.Proportion = proportion - } - } - return f -} - -// Draw draws this primitive onto the screen. -func (f *Flex) Draw(screen tcell.Screen) { - f.Box.DrawForSubclass(screen, f) - - // Calculate size and position of the items. - - // Do we use the entire screen? - if f.fullScreen { - width, height := screen.Size() - f.SetRect(0, 0, width, height) - } - - // How much space can we distribute? - x, y, width, height := f.GetInnerRect() - var proportionSum int - distSize := width - if f.direction == FlexRow { - distSize = height - } - for _, item := range f.items { - if item.FixedSize > 0 { - distSize -= item.FixedSize - } else { - proportionSum += item.Proportion - } - } - - // Calculate positions and draw items. - pos := x - if f.direction == FlexRow { - pos = y - } - for _, item := range f.items { - size := item.FixedSize - if size <= 0 { - if proportionSum > 0 { - size = distSize * item.Proportion / proportionSum - distSize -= size - proportionSum -= item.Proportion - } else { - size = 0 - } - } - if item.Item != nil { - if f.direction == FlexColumn { - item.Item.SetRect(pos, y, size, height) - } else { - item.Item.SetRect(x, pos, width, size) - } - } - pos += size - - if item.Item != nil { - if item.Item.HasFocus() { - defer item.Item.Draw(screen) - } else { - item.Item.Draw(screen) - } - } - } -} - -// Focus is called when this primitive receives focus. -func (f *Flex) Focus(delegate func(p Primitive)) { - for _, item := range f.items { - if item.Item != nil && item.Focus { - delegate(item.Item) - return - } - } -} - -// HasFocus returns whether or not this primitive has focus. -func (f *Flex) HasFocus() bool { - for _, item := range f.items { - if item.Item != nil && item.Item.HasFocus() { - return true - } - } - return false -} - -// MouseHandler returns the mouse handler for this primitive. -func (f *Flex) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return f.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if !f.InRect(event.Position()) { - return false, nil - } - - // Pass mouse events along to the first child item that takes it. - for _, item := range f.items { - if item.Item == nil { - continue - } - consumed, capture = item.Item.MouseHandler()(action, event, setFocus) - if consumed { - return - } - } - - return - }) -} - -// InputHandler returns the handler for this primitive. -func (f *Flex) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return f.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - for _, item := range f.items { - if item.Item != nil && item.Item.HasFocus() { - if handler := item.Item.InputHandler(); handler != nil { - handler(event, setFocus) - return - } - } - } - }) -} diff --git a/vendor/github.com/rivo/tview/form.go b/vendor/github.com/rivo/tview/form.go deleted file mode 100644 index 6567e8d..0000000 --- a/vendor/github.com/rivo/tview/form.go +++ /dev/null @@ -1,684 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// DefaultFormFieldWidth is the default field screen width of form elements -// whose field width is flexible (0). This is used in the Form class for -// horizontal layouts. -var DefaultFormFieldWidth = 10 - -// FormItem is the interface all form items must implement to be able to be -// included in a form. -type FormItem interface { - Primitive - - // GetLabel returns the item's label text. - GetLabel() string - - // SetFormAttributes sets a number of item attributes at once. - SetFormAttributes(labelWidth int, labelColor, bgColor, fieldTextColor, fieldBgColor tcell.Color) FormItem - - // GetFieldWidth returns the width of the form item's field (the area which - // is manipulated by the user) in number of screen cells. A value of 0 - // indicates the the field width is flexible and may use as much space as - // required. - GetFieldWidth() int - - // SetFinishedFunc sets the handler function for when the user finished - // entering data into the item. The handler may receive events for the - // Enter key (we're done), the Escape key (cancel input), the Tab key (move to - // next field), and the Backtab key (move to previous field). - SetFinishedFunc(handler func(key tcell.Key)) FormItem -} - -// Form allows you to combine multiple one-line form elements into a vertical -// or horizontal layout. Form elements include types such as InputField or -// Checkbox. These elements can be optionally followed by one or more buttons -// for which you can define form-wide actions (e.g. Save, Clear, Cancel). -// -// See https://github.com/rivo/tview/wiki/Form for an example. -type Form struct { - *Box - - // The items of the form (one row per item). - items []FormItem - - // The buttons of the form. - buttons []*Button - - // If set to true, instead of position items and buttons from top to bottom, - // they are positioned from left to right. - horizontal bool - - // The alignment of the buttons. - buttonsAlign int - - // The number of empty rows between items. - itemPadding int - - // The index of the item or button which has focus. (Items are counted first, - // buttons are counted last.) This is only used when the form itself receives - // focus so that the last element that had focus keeps it. - focusedElement int - - // The label color. - labelColor tcell.Color - - // The background color of the input area. - fieldBackgroundColor tcell.Color - - // The text color of the input area. - fieldTextColor tcell.Color - - // The background color of the buttons. - buttonBackgroundColor tcell.Color - - // The color of the button text. - buttonTextColor tcell.Color - - // An optional function which is called when the user hits Escape. - cancel func() -} - -// NewForm returns a new form. -func NewForm() *Form { - box := NewBox().SetBorderPadding(1, 1, 1, 1) - - f := &Form{ - Box: box, - itemPadding: 1, - labelColor: Styles.SecondaryTextColor, - fieldBackgroundColor: Styles.ContrastBackgroundColor, - fieldTextColor: Styles.PrimaryTextColor, - buttonBackgroundColor: Styles.ContrastBackgroundColor, - buttonTextColor: Styles.PrimaryTextColor, - } - - return f -} - -// SetItemPadding sets the number of empty rows between form items for vertical -// layouts and the number of empty cells between form items for horizontal -// layouts. -func (f *Form) SetItemPadding(padding int) *Form { - f.itemPadding = padding - return f -} - -// SetHorizontal sets the direction the form elements are laid out. If set to -// true, instead of positioning them from top to bottom (the default), they are -// positioned from left to right, moving into the next row if there is not -// enough space. -func (f *Form) SetHorizontal(horizontal bool) *Form { - f.horizontal = horizontal - return f -} - -// SetLabelColor sets the color of the labels. -func (f *Form) SetLabelColor(color tcell.Color) *Form { - f.labelColor = color - return f -} - -// SetFieldBackgroundColor sets the background color of the input areas. -func (f *Form) SetFieldBackgroundColor(color tcell.Color) *Form { - f.fieldBackgroundColor = color - return f -} - -// SetFieldTextColor sets the text color of the input areas. -func (f *Form) SetFieldTextColor(color tcell.Color) *Form { - f.fieldTextColor = color - return f -} - -// SetButtonsAlign sets how the buttons align horizontally, one of AlignLeft -// (the default), AlignCenter, and AlignRight. This is only -func (f *Form) SetButtonsAlign(align int) *Form { - f.buttonsAlign = align - return f -} - -// SetButtonBackgroundColor sets the background color of the buttons. -func (f *Form) SetButtonBackgroundColor(color tcell.Color) *Form { - f.buttonBackgroundColor = color - return f -} - -// SetButtonTextColor sets the color of the button texts. -func (f *Form) SetButtonTextColor(color tcell.Color) *Form { - f.buttonTextColor = color - return f -} - -// SetFocus shifts the focus to the form element with the given index, counting -// non-button items first and buttons last. Note that this index is only used -// when the form itself receives focus. -func (f *Form) SetFocus(index int) *Form { - if index < 0 { - f.focusedElement = 0 - } else if index >= len(f.items)+len(f.buttons) { - f.focusedElement = len(f.items) + len(f.buttons) - } else { - f.focusedElement = index - } - return f -} - -// AddInputField adds an input field to the form. It has a label, an optional -// initial value, a field width (a value of 0 extends it as far as possible), -// an optional accept function to validate the item's value (set to nil to -// accept any text), and an (optional) callback function which is invoked when -// the input field's text has changed. -func (f *Form) AddInputField(label, value string, fieldWidth int, accept func(textToCheck string, lastChar rune) bool, changed func(text string)) *Form { - f.items = append(f.items, NewInputField(). - SetLabel(label). - SetText(value). - SetFieldWidth(fieldWidth). - SetAcceptanceFunc(accept). - SetChangedFunc(changed)) - return f -} - -// AddPasswordField adds a password field to the form. This is similar to an -// input field except that the user's input not shown. Instead, a "mask" -// character is displayed. The password field has a label, an optional initial -// value, a field width (a value of 0 extends it as far as possible), and an -// (optional) callback function which is invoked when the input field's text has -// changed. -func (f *Form) AddPasswordField(label, value string, fieldWidth int, mask rune, changed func(text string)) *Form { - if mask == 0 { - mask = '*' - } - f.items = append(f.items, NewInputField(). - SetLabel(label). - SetText(value). - SetFieldWidth(fieldWidth). - SetMaskCharacter(mask). - SetChangedFunc(changed)) - return f -} - -// AddDropDown adds a drop-down element to the form. It has a label, options, -// and an (optional) callback function which is invoked when an option was -// selected. The initial option may be a negative value to indicate that no -// option is currently selected. -func (f *Form) AddDropDown(label string, options []string, initialOption int, selected func(option string, optionIndex int)) *Form { - f.items = append(f.items, NewDropDown(). - SetLabel(label). - SetOptions(options, selected). - SetCurrentOption(initialOption)) - return f -} - -// AddCheckbox adds a checkbox to the form. It has a label, an initial state, -// and an (optional) callback function which is invoked when the state of the -// checkbox was changed by the user. -func (f *Form) AddCheckbox(label string, checked bool, changed func(checked bool)) *Form { - f.items = append(f.items, NewCheckbox(). - SetLabel(label). - SetChecked(checked). - SetChangedFunc(changed)) - return f -} - -// AddButton adds a new button to the form. The "selected" function is called -// when the user selects this button. It may be nil. -func (f *Form) AddButton(label string, selected func()) *Form { - f.buttons = append(f.buttons, NewButton(label).SetSelectedFunc(selected)) - return f -} - -// GetButton returns the button at the specified 0-based index. Note that -// buttons have been specially prepared for this form and modifying some of -// their attributes may have unintended side effects. -func (f *Form) GetButton(index int) *Button { - return f.buttons[index] -} - -// RemoveButton removes the button at the specified position, starting with 0 -// for the button that was added first. -func (f *Form) RemoveButton(index int) *Form { - f.buttons = append(f.buttons[:index], f.buttons[index+1:]...) - return f -} - -// GetButtonCount returns the number of buttons in this form. -func (f *Form) GetButtonCount() int { - return len(f.buttons) -} - -// GetButtonIndex returns the index of the button with the given label, starting -// with 0 for the button that was added first. If no such label was found, -1 -// is returned. -func (f *Form) GetButtonIndex(label string) int { - for index, button := range f.buttons { - if button.GetLabel() == label { - return index - } - } - return -1 -} - -// Clear removes all input elements from the form, including the buttons if -// specified. -func (f *Form) Clear(includeButtons bool) *Form { - f.items = nil - if includeButtons { - f.ClearButtons() - } - f.focusedElement = 0 - return f -} - -// ClearButtons removes all buttons from the form. -func (f *Form) ClearButtons() *Form { - f.buttons = nil - return f -} - -// AddFormItem adds a new item to the form. This can be used to add your own -// objects to the form. Note, however, that the Form class will override some -// of its attributes to make it work in the form context. Specifically, these -// are: -// -// - The label width -// - The label color -// - The background color -// - The field text color -// - The field background color -func (f *Form) AddFormItem(item FormItem) *Form { - f.items = append(f.items, item) - return f -} - -// GetFormItemCount returns the number of items in the form (not including the -// buttons). -func (f *Form) GetFormItemCount() int { - return len(f.items) -} - -// GetFormItem returns the form item at the given position, starting with index -// 0. Elements are referenced in the order they were added. Buttons are not -// included. -func (f *Form) GetFormItem(index int) FormItem { - return f.items[index] -} - -// RemoveFormItem removes the form element at the given position, starting with -// index 0. Elements are referenced in the order they were added. Buttons are -// not included. -func (f *Form) RemoveFormItem(index int) *Form { - f.items = append(f.items[:index], f.items[index+1:]...) - return f -} - -// GetFormItemByLabel returns the first form element with the given label. If -// no such element is found, nil is returned. Buttons are not searched and will -// therefore not be returned. -func (f *Form) GetFormItemByLabel(label string) FormItem { - for _, item := range f.items { - if item.GetLabel() == label { - return item - } - } - return nil -} - -// GetFormItemIndex returns the index of the first form element with the given -// label. If no such element is found, -1 is returned. Buttons are not searched -// and will therefore not be returned. -func (f *Form) GetFormItemIndex(label string) int { - for index, item := range f.items { - if item.GetLabel() == label { - return index - } - } - return -1 -} - -// GetFocusedItemIndex returns the indices of the form element or button which -// currently has focus. If they don't, -1 is returned resepectively. -func (f *Form) GetFocusedItemIndex() (formItem, button int) { - index := f.focusIndex() - if index < 0 { - return -1, -1 - } - if index < len(f.items) { - return index, -1 - } - return -1, index - len(f.items) -} - -// SetCancelFunc sets a handler which is called when the user hits the Escape -// key. -func (f *Form) SetCancelFunc(callback func()) *Form { - f.cancel = callback - return f -} - -// Draw draws this primitive onto the screen. -func (f *Form) Draw(screen tcell.Screen) { - f.Box.DrawForSubclass(screen, f) - - // Determine the actual item that has focus. - if index := f.focusIndex(); index >= 0 { - f.focusedElement = index - } - - // Determine the dimensions. - x, y, width, height := f.GetInnerRect() - topLimit := y - bottomLimit := y + height - rightLimit := x + width - startX := x - - // Find the longest label. - var maxLabelWidth int - for _, item := range f.items { - labelWidth := TaggedStringWidth(item.GetLabel()) - if labelWidth > maxLabelWidth { - maxLabelWidth = labelWidth - } - } - maxLabelWidth++ // Add one space. - - // Calculate positions of form items. - positions := make([]struct{ x, y, width, height int }, len(f.items)+len(f.buttons)) - var focusedPosition struct{ x, y, width, height int } - for index, item := range f.items { - // Calculate the space needed. - labelWidth := TaggedStringWidth(item.GetLabel()) - var itemWidth int - if f.horizontal { - fieldWidth := item.GetFieldWidth() - if fieldWidth == 0 { - fieldWidth = DefaultFormFieldWidth - } - labelWidth++ - itemWidth = labelWidth + fieldWidth - } else { - // We want all fields to align vertically. - labelWidth = maxLabelWidth - itemWidth = width - } - - // Advance to next line if there is no space. - if f.horizontal && x+labelWidth+1 >= rightLimit { - x = startX - y += 2 - } - - // Adjust the item's attributes. - if x+itemWidth >= rightLimit { - itemWidth = rightLimit - x - } - item.SetFormAttributes( - labelWidth, - f.labelColor, - f.backgroundColor, - f.fieldTextColor, - f.fieldBackgroundColor, - ) - - // Save position. - positions[index].x = x - positions[index].y = y - positions[index].width = itemWidth - positions[index].height = 1 - if item.HasFocus() { - focusedPosition = positions[index] - } - - // Advance to next item. - if f.horizontal { - x += itemWidth + f.itemPadding - } else { - y += 1 + f.itemPadding - } - } - - // How wide are the buttons? - buttonWidths := make([]int, len(f.buttons)) - buttonsWidth := 0 - for index, button := range f.buttons { - w := TaggedStringWidth(button.GetLabel()) + 4 - buttonWidths[index] = w - buttonsWidth += w + 1 - } - buttonsWidth-- - - // Where do we place them? - if !f.horizontal && x+buttonsWidth < rightLimit { - if f.buttonsAlign == AlignRight { - x = rightLimit - buttonsWidth - } else if f.buttonsAlign == AlignCenter { - x = (x + rightLimit - buttonsWidth) / 2 - } - - // In vertical layouts, buttons always appear after an empty line. - if f.itemPadding == 0 { - y++ - } - } - - // Calculate positions of buttons. - for index, button := range f.buttons { - space := rightLimit - x - buttonWidth := buttonWidths[index] - if f.horizontal { - if space < buttonWidth-4 { - x = startX - y += 2 - space = width - } - } else { - if space < 1 { - break // No space for this button anymore. - } - } - if buttonWidth > space { - buttonWidth = space - } - button.SetLabelColor(f.buttonTextColor). - SetLabelColorActivated(f.buttonBackgroundColor). - SetBackgroundColorActivated(f.buttonTextColor). - SetBackgroundColor(f.buttonBackgroundColor) - - buttonIndex := index + len(f.items) - positions[buttonIndex].x = x - positions[buttonIndex].y = y - positions[buttonIndex].width = buttonWidth - positions[buttonIndex].height = 1 - - if button.HasFocus() { - focusedPosition = positions[buttonIndex] - } - - x += buttonWidth + 1 - } - - // Determine vertical offset based on the position of the focused item. - var offset int - if focusedPosition.y+focusedPosition.height > bottomLimit { - offset = focusedPosition.y + focusedPosition.height - bottomLimit - if focusedPosition.y-offset < topLimit { - offset = focusedPosition.y - topLimit - } - } - - // Draw items. - for index, item := range f.items { - // Set position. - y := positions[index].y - offset - height := positions[index].height - item.SetRect(positions[index].x, y, positions[index].width, height) - - // Is this item visible? - if y+height <= topLimit || y >= bottomLimit { - continue - } - - // Draw items with focus last (in case of overlaps). - if item.HasFocus() { - defer item.Draw(screen) - } else { - item.Draw(screen) - } - } - - // Draw buttons. - for index, button := range f.buttons { - // Set position. - buttonIndex := index + len(f.items) - y := positions[buttonIndex].y - offset - height := positions[buttonIndex].height - button.SetRect(positions[buttonIndex].x, y, positions[buttonIndex].width, height) - - // Is this button visible? - if y+height <= topLimit || y >= bottomLimit { - continue - } - - // Draw button. - button.Draw(screen) - } -} - -// Focus is called by the application when the primitive receives focus. -func (f *Form) Focus(delegate func(p Primitive)) { - if len(f.items)+len(f.buttons) == 0 { - f.hasFocus = true - return - } - f.hasFocus = false - - // Hand on the focus to one of our child elements. - if f.focusedElement < 0 || f.focusedElement >= len(f.items)+len(f.buttons) { - f.focusedElement = 0 - } - handler := func(key tcell.Key) { - switch key { - case tcell.KeyTab, tcell.KeyEnter: - f.focusedElement++ - f.Focus(delegate) - case tcell.KeyBacktab: - f.focusedElement-- - if f.focusedElement < 0 { - f.focusedElement = len(f.items) + len(f.buttons) - 1 - } - f.Focus(delegate) - case tcell.KeyEscape: - if f.cancel != nil { - f.cancel() - } else { - f.focusedElement = 0 - f.Focus(delegate) - } - } - } - - if f.focusedElement < len(f.items) { - // We're selecting an item. - item := f.items[f.focusedElement] - item.SetFinishedFunc(handler) - delegate(item) - } else { - // We're selecting a button. - button := f.buttons[f.focusedElement-len(f.items)] - button.SetBlurFunc(handler) - delegate(button) - } -} - -// HasFocus returns whether or not this primitive has focus. -func (f *Form) HasFocus() bool { - if f.hasFocus { - return true - } - return f.focusIndex() >= 0 -} - -// focusIndex returns the index of the currently focused item, counting form -// items first, then buttons. A negative value indicates that no containeed item -// has focus. -func (f *Form) focusIndex() int { - for index, item := range f.items { - if item.HasFocus() { - return index - } - } - for index, button := range f.buttons { - if button.HasFocus() { - return len(f.items) + index - } - } - return -1 -} - -// MouseHandler returns the mouse handler for this primitive. -func (f *Form) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return f.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if !f.InRect(event.Position()) { - return false, nil - } - - // At the end, update f.focusedElement and prepare current item/button. - defer func() { - if consumed { - index := f.focusIndex() - if index >= 0 { - f.focusedElement = index - } - f.Focus(setFocus) - } - }() - - // Determine items to pass mouse events to. - for _, item := range f.items { - consumed, capture = item.MouseHandler()(action, event, setFocus) - if consumed { - return - } - } - for _, button := range f.buttons { - consumed, capture = button.MouseHandler()(action, event, setFocus) - if consumed { - return - } - } - - // A mouse click anywhere else will return the focus to the last selected - // element. - if action == MouseLeftClick { - consumed = true - } - - return - }) -} - -// InputHandler returns the handler for this primitive. -func (f *Form) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return f.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - for _, item := range f.items { - if item != nil && item.HasFocus() { - if handler := item.InputHandler(); handler != nil { - handler(event, setFocus) - return - } - } - } - - for _, button := range f.buttons { - if button.HasFocus() { - if handler := button.InputHandler(); handler != nil { - handler(event, setFocus) - return - } - } - } - }) -} diff --git a/vendor/github.com/rivo/tview/frame.go b/vendor/github.com/rivo/tview/frame.go deleted file mode 100644 index 47e5640..0000000 --- a/vendor/github.com/rivo/tview/frame.go +++ /dev/null @@ -1,192 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// frameText holds information about a line of text shown in the frame. -type frameText struct { - Text string // The text to be displayed. - Header bool // true = place in header, false = place in footer. - Align int // One of the Align constants. - Color tcell.Color // The text color. -} - -// Frame is a wrapper which adds space around another primitive. In addition, -// the top area (header) and the bottom area (footer) may also contain text. -// -// See https://github.com/rivo/tview/wiki/Frame for an example. -type Frame struct { - *Box - - // The contained primitive. May be nil. - primitive Primitive - - // The lines of text to be displayed. - text []*frameText - - // Border spacing. - top, bottom, header, footer, left, right int -} - -// NewFrame returns a new frame around the given primitive. The primitive's -// size will be changed to fit within this frame. The primitive may be nil, in -// which case no other primitive is embedded in the frame. -func NewFrame(primitive Primitive) *Frame { - box := NewBox() - - f := &Frame{ - Box: box, - primitive: primitive, - top: 1, - bottom: 1, - header: 1, - footer: 1, - left: 1, - right: 1, - } - - return f -} - -// AddText adds text to the frame. Set "header" to true if the text is to appear -// in the header, above the contained primitive. Set it to false for it to -// appear in the footer, below the contained primitive. "align" must be one of -// the Align constants. Rows in the header are printed top to bottom, rows in -// the footer are printed bottom to top. Note that long text can overlap as -// different alignments will be placed on the same row. -func (f *Frame) AddText(text string, header bool, align int, color tcell.Color) *Frame { - f.text = append(f.text, &frameText{ - Text: text, - Header: header, - Align: align, - Color: color, - }) - return f -} - -// Clear removes all text from the frame. -func (f *Frame) Clear() *Frame { - f.text = nil - return f -} - -// SetBorders sets the width of the frame borders as well as "header" and -// "footer", the vertical space between the header and footer text and the -// contained primitive (does not apply if there is no text). -func (f *Frame) SetBorders(top, bottom, header, footer, left, right int) *Frame { - f.top, f.bottom, f.header, f.footer, f.left, f.right = top, bottom, header, footer, left, right - return f -} - -// Draw draws this primitive onto the screen. -func (f *Frame) Draw(screen tcell.Screen) { - f.Box.DrawForSubclass(screen, f) - - // Calculate start positions. - x, top, width, height := f.GetInnerRect() - bottom := top + height - 1 - x += f.left - top += f.top - bottom -= f.bottom - width -= f.left + f.right - if width <= 0 || top >= bottom { - return // No space left. - } - - // Draw text. - var rows [6]int // top-left, top-center, top-right, bottom-left, bottom-center, bottom-right. - topMax := top - bottomMin := bottom - for _, text := range f.text { - // Where do we place this text? - var y int - if text.Header { - y = top + rows[text.Align] - rows[text.Align]++ - if y >= bottomMin { - continue - } - if y+1 > topMax { - topMax = y + 1 - } - } else { - y = bottom - rows[3+text.Align] - rows[3+text.Align]++ - if y <= topMax { - continue - } - if y-1 < bottomMin { - bottomMin = y - 1 - } - } - - // Draw text. - Print(screen, text.Text, x, y, width, text.Align, text.Color) - } - - // Set the size of the contained primitive. - if f.primitive != nil { - if topMax > top { - top = topMax + f.header - } - if bottomMin < bottom { - bottom = bottomMin - f.footer - } - if top > bottom { - return // No space for the primitive. - } - f.primitive.SetRect(x, top, width, bottom+1-top) - - // Finally, draw the contained primitive. - f.primitive.Draw(screen) - } -} - -// Focus is called when this primitive receives focus. -func (f *Frame) Focus(delegate func(p Primitive)) { - if f.primitive != nil { - delegate(f.primitive) - } else { - f.hasFocus = true - } -} - -// HasFocus returns whether or not this primitive has focus. -func (f *Frame) HasFocus() bool { - if f.primitive == nil { - return f.hasFocus - } - return f.primitive.HasFocus() -} - -// MouseHandler returns the mouse handler for this primitive. -func (f *Frame) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return f.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if !f.InRect(event.Position()) { - return false, nil - } - - // Pass mouse events on to contained primitive. - if f.primitive != nil { - return f.primitive.MouseHandler()(action, event, setFocus) - } - - return false, nil - }) -} - -// InputHandler returns the handler for this primitive. -func (f *Frame) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return f.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - if f.primitive == nil { - return - } - if f.primitive.HasFocus() { - if handler := f.primitive.InputHandler(); handler != nil { - handler(event, setFocus) - return - } - } - }) -} diff --git a/vendor/github.com/rivo/tview/go.mod b/vendor/github.com/rivo/tview/go.mod deleted file mode 100644 index a65d097..0000000 --- a/vendor/github.com/rivo/tview/go.mod +++ /dev/null @@ -1,12 +0,0 @@ -module github.com/rivo/tview - -go 1.12 - -require ( - github.com/gdamore/tcell/v2 v2.0.1-0.20201017141208-acf90d56d591 - github.com/lucasb-eyer/go-colorful v1.0.3 - github.com/mattn/go-runewidth v0.0.9 - github.com/rivo/uniseg v0.2.0 - golang.org/x/sys v0.0.0-20201017003518-b09fb700fbb7 // indirect - golang.org/x/text v0.3.3 // indirect -) diff --git a/vendor/github.com/rivo/tview/go.sum b/vendor/github.com/rivo/tview/go.sum deleted file mode 100644 index aa939dd..0000000 --- a/vendor/github.com/rivo/tview/go.sum +++ /dev/null @@ -1,24 +0,0 @@ -github.com/gdamore/encoding v1.0.0 h1:+7OoQ1Bc6eTm5niUzBa0Ctsh6JbMW6Ra+YNuAtDBdko= -github.com/gdamore/encoding v1.0.0/go.mod h1:alR0ol34c49FCSBLjhosxzcPHQbf2trDkoo5dl+VrEg= -github.com/gdamore/tcell/v2 v2.0.0 h1:GRWG8aLfWAlekj9Q6W29bVvkHENc6hp79XOqG4AWDOs= -github.com/gdamore/tcell/v2 v2.0.0/go.mod h1:vSVL/GV5mCSlPC6thFP5kfOFdM9MGZcalipmpTxTgQA= -github.com/gdamore/tcell/v2 v2.0.1-0.20201017141208-acf90d56d591 h1:0WWUDZ1oxq7NxVyGo8M3KI5jbkiwNAdZFFzAdC68up4= -github.com/gdamore/tcell/v2 v2.0.1-0.20201017141208-acf90d56d591/go.mod h1:vSVL/GV5mCSlPC6thFP5kfOFdM9MGZcalipmpTxTgQA= -github.com/lucasb-eyer/go-colorful v1.0.3 h1:QIbQXiugsb+q10B+MI+7DI1oQLdmnep86tWFlaaUAac= -github.com/lucasb-eyer/go-colorful v1.0.3/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= -github.com/mattn/go-runewidth v0.0.7/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -github.com/mattn/go-runewidth v0.0.9 h1:Lm995f3rfxdpd6TSmuVCHVb/QhupuXlYr8sCI/QdE+0= -github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -github.com/rivo/uniseg v0.1.0 h1:+2KBaVoUmb9XzDsrx/Ct0W/EYOSFf/nWTauy++DprtY= -github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= -github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= -github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= -golang.org/x/sys v0.0.0-20190626150813-e07cf5db2756 h1:9nuHUbU8dRnRRfj9KjWUVrJeoexdbeMjttk6Oh1rD10= -golang.org/x/sys v0.0.0-20190626150813-e07cf5db2756/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201017003518-b09fb700fbb7 h1:XtNJkfEjb4zR3q20BBBcYUykVOEMgZeIUOpBPfNYgxg= -golang.org/x/sys v0.0.0-20201017003518-b09fb700fbb7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.3 h1:cokOdA+Jmi5PJGXLlLllQSgYigAEfHXJAERHVMaCc2k= -golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= diff --git a/vendor/github.com/rivo/tview/grid.go b/vendor/github.com/rivo/tview/grid.go deleted file mode 100644 index ceabcfc..0000000 --- a/vendor/github.com/rivo/tview/grid.go +++ /dev/null @@ -1,697 +0,0 @@ -package tview - -import ( - "math" - - "github.com/gdamore/tcell/v2" -) - -// gridItem represents one primitive and its possible position on a grid. -type gridItem struct { - Item Primitive // The item to be positioned. May be nil for an empty item. - Row, Column int // The top-left grid cell where the item is placed. - Width, Height int // The number of rows and columns the item occupies. - MinGridWidth, MinGridHeight int // The minimum grid width/height for which this item is visible. - Focus bool // Whether or not this item attracts the layout's focus. - - visible bool // Whether or not this item was visible the last time the grid was drawn. - x, y, w, h int // The last position of the item relative to the top-left corner of the grid. Undefined if visible is false. -} - -// Grid is an implementation of a grid-based layout. It works by defining the -// size of the rows and columns, then placing primitives into the grid. -// -// Some settings can lead to the grid exceeding its available space. SetOffset() -// can then be used to scroll in steps of rows and columns. These offset values -// can also be controlled with the arrow keys (or the "g","G", "j", "k", "h", -// and "l" keys) while the grid has focus and none of its contained primitives -// do. -// -// See https://github.com/rivo/tview/wiki/Grid for an example. -type Grid struct { - *Box - - // The items to be positioned. - items []*gridItem - - // The definition of the rows and columns of the grid. See - // SetRows()/SetColumns() for details. - rows, columns []int - - // The minimum sizes for rows and columns. - minWidth, minHeight int - - // The size of the gaps between neighboring primitives. This is automatically - // set to 1 if borders is true. - gapRows, gapColumns int - - // The number of rows and columns skipped before drawing the top-left corner - // of the grid. - rowOffset, columnOffset int - - // Whether or not borders are drawn around grid items. If this is set to true, - // a gap size of 1 is automatically assumed (which is filled with the border - // graphics). - borders bool - - // The color of the borders around grid items. - bordersColor tcell.Color -} - -// NewGrid returns a new grid-based layout container with no initial primitives. -// -// Note that Box, the superclass of Grid, will have its background color set to -// transparent so that any grid areas not covered by any primitives will leave -// their background unchanged. To clear a Grid's background before any items are -// drawn, set it to the desired color: -// -// grid.SetBackgroundColor(tview.Styles.PrimitiveBackgroundColor) -func NewGrid() *Grid { - g := &Grid{ - Box: NewBox().SetBackgroundColor(tcell.ColorDefault), - bordersColor: Styles.GraphicsColor, - } - return g -} - -// SetColumns defines how the columns of the grid are distributed. Each value -// defines the size of one column, starting with the leftmost column. Values -// greater 0 represent absolute column widths (gaps not included). Values less -// or equal 0 represent proportional column widths or fractions of the remaining -// free space, where 0 is treated the same as -1. That is, a column with a value -// of -3 will have three times the width of a column with a value of -1 (or 0). -// The minimum width set with SetMinSize() is always observed. -// -// Primitives may extend beyond the columns defined explicitly with this -// function. A value of 0 is assumed for any undefined column. In fact, if you -// never call this function, all columns occupied by primitives will have the -// same width. On the other hand, unoccupied columns defined with this function -// will always take their place. -// -// Assuming a total width of the grid of 100 cells and a minimum width of 0, the -// following call will result in columns with widths of 30, 10, 15, 15, and 30 -// cells: -// -// grid.Setcolumns(30, 10, -1, -1, -2) -// -// If a primitive were then placed in the 6th and 7th column, the resulting -// widths would be: 30, 10, 10, 10, 20, 10, and 10 cells. -// -// If you then called SetMinSize() as follows: -// -// grid.SetMinSize(15, 20) -// -// The resulting widths would be: 30, 15, 15, 15, 20, 15, and 15 cells, a total -// of 125 cells, 25 cells wider than the available grid width. -func (g *Grid) SetColumns(columns ...int) *Grid { - g.columns = columns - return g -} - -// SetRows defines how the rows of the grid are distributed. These values behave -// the same as the column values provided with SetColumns(), see there for a -// definition and examples. -// -// The provided values correspond to row heights, the first value defining -// the height of the topmost row. -func (g *Grid) SetRows(rows ...int) *Grid { - g.rows = rows - return g -} - -// SetSize is a shortcut for SetRows() and SetColumns() where all row and column -// values are set to the given size values. See SetColumns() for details on sizes. -func (g *Grid) SetSize(numRows, numColumns, rowSize, columnSize int) *Grid { - g.rows = make([]int, numRows) - for index := range g.rows { - g.rows[index] = rowSize - } - g.columns = make([]int, numColumns) - for index := range g.columns { - g.columns[index] = columnSize - } - return g -} - -// SetMinSize sets an absolute minimum width for rows and an absolute minimum -// height for columns. Panics if negative values are provided. -func (g *Grid) SetMinSize(row, column int) *Grid { - if row < 0 || column < 0 { - panic("Invalid minimum row/column size") - } - g.minHeight, g.minWidth = row, column - return g -} - -// SetGap sets the size of the gaps between neighboring primitives on the grid. -// If borders are drawn (see SetBorders()), these values are ignored and a gap -// of 1 is assumed. Panics if negative values are provided. -func (g *Grid) SetGap(row, column int) *Grid { - if row < 0 || column < 0 { - panic("Invalid gap size") - } - g.gapRows, g.gapColumns = row, column - return g -} - -// SetBorders sets whether or not borders are drawn around grid items. Setting -// this value to true will cause the gap values (see SetGap()) to be ignored and -// automatically assumed to be 1 where the border graphics are drawn. -func (g *Grid) SetBorders(borders bool) *Grid { - g.borders = borders - return g -} - -// SetBordersColor sets the color of the item borders. -func (g *Grid) SetBordersColor(color tcell.Color) *Grid { - g.bordersColor = color - return g -} - -// AddItem adds a primitive and its position to the grid. The top-left corner -// of the primitive will be located in the top-left corner of the grid cell at -// the given row and column and will span "rowSpan" rows and "colSpan" columns. -// For example, for a primitive to occupy rows 2, 3, and 4 and columns 5 and 6: -// -// grid.AddItem(p, 2, 5, 3, 2, 0, 0, true) -// -// If rowSpan or colSpan is 0, the primitive will not be drawn. -// -// You can add the same primitive multiple times with different grid positions. -// The minGridWidth and minGridHeight values will then determine which of those -// positions will be used. This is similar to CSS media queries. These minimum -// values refer to the overall size of the grid. If multiple items for the same -// primitive apply, the one that has at least one highest minimum value will be -// used, or the primitive added last if those values are the same. Example: -// -// grid.AddItem(p, 0, 0, 0, 0, 0, 0, true). // Hide in small grids. -// AddItem(p, 0, 0, 1, 2, 100, 0, true). // One-column layout for medium grids. -// AddItem(p, 1, 1, 3, 2, 300, 0, true) // Multi-column layout for large grids. -// -// To use the same grid layout for all sizes, simply set minGridWidth and -// minGridHeight to 0. -// -// If the item's focus is set to true, it will receive focus when the grid -// receives focus. If there are multiple items with a true focus flag, the last -// visible one that was added will receive focus. -func (g *Grid) AddItem(p Primitive, row, column, rowSpan, colSpan, minGridHeight, minGridWidth int, focus bool) *Grid { - g.items = append(g.items, &gridItem{ - Item: p, - Row: row, - Column: column, - Height: rowSpan, - Width: colSpan, - MinGridHeight: minGridHeight, - MinGridWidth: minGridWidth, - Focus: focus, - }) - return g -} - -// RemoveItem removes all items for the given primitive from the grid, keeping -// the order of the remaining items intact. -func (g *Grid) RemoveItem(p Primitive) *Grid { - for index := len(g.items) - 1; index >= 0; index-- { - if g.items[index].Item == p { - g.items = append(g.items[:index], g.items[index+1:]...) - } - } - return g -} - -// Clear removes all items from the grid. -func (g *Grid) Clear() *Grid { - g.items = nil - return g -} - -// SetOffset sets the number of rows and columns which are skipped before -// drawing the first grid cell in the top-left corner. As the grid will never -// completely move off the screen, these values may be adjusted the next time -// the grid is drawn. The actual position of the grid may also be adjusted such -// that contained primitives that have focus remain visible. -func (g *Grid) SetOffset(rows, columns int) *Grid { - g.rowOffset, g.columnOffset = rows, columns - return g -} - -// GetOffset returns the current row and column offset (see SetOffset() for -// details). -func (g *Grid) GetOffset() (rows, columns int) { - return g.rowOffset, g.columnOffset -} - -// Focus is called when this primitive receives focus. -func (g *Grid) Focus(delegate func(p Primitive)) { - for _, item := range g.items { - if item.Focus { - delegate(item.Item) - return - } - } - g.hasFocus = true -} - -// Blur is called when this primitive loses focus. -func (g *Grid) Blur() { - g.hasFocus = false -} - -// HasFocus returns whether or not this primitive has focus. -func (g *Grid) HasFocus() bool { - for _, item := range g.items { - if item.visible && item.Item.HasFocus() { - return true - } - } - return g.hasFocus -} - -// InputHandler returns the handler for this primitive. -func (g *Grid) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return g.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - if !g.hasFocus { - // Pass event on to child primitive. - for _, item := range g.items { - if item != nil && item.Item.HasFocus() { - if handler := item.Item.InputHandler(); handler != nil { - handler(event, setFocus) - return - } - } - } - return - } - - // Process our own key events if we have direct focus. - switch event.Key() { - case tcell.KeyRune: - switch event.Rune() { - case 'g': - g.rowOffset, g.columnOffset = 0, 0 - case 'G': - g.rowOffset = math.MaxInt32 - case 'j': - g.rowOffset++ - case 'k': - g.rowOffset-- - case 'h': - g.columnOffset-- - case 'l': - g.columnOffset++ - } - case tcell.KeyHome: - g.rowOffset, g.columnOffset = 0, 0 - case tcell.KeyEnd: - g.rowOffset = math.MaxInt32 - case tcell.KeyUp: - g.rowOffset-- - case tcell.KeyDown: - g.rowOffset++ - case tcell.KeyLeft: - g.columnOffset-- - case tcell.KeyRight: - g.columnOffset++ - } - }) -} - -// Draw draws this primitive onto the screen. -func (g *Grid) Draw(screen tcell.Screen) { - g.Box.DrawForSubclass(screen, g) - x, y, width, height := g.GetInnerRect() - screenWidth, screenHeight := screen.Size() - - // Make a list of items which apply. - items := make(map[Primitive]*gridItem) - for _, item := range g.items { - item.visible = false - if item.Width <= 0 || item.Height <= 0 || width < item.MinGridWidth || height < item.MinGridHeight { - continue - } - previousItem, ok := items[item.Item] - if ok && item.MinGridWidth < previousItem.MinGridWidth && item.MinGridHeight < previousItem.MinGridHeight { - continue - } - items[item.Item] = item - } - - // How many rows and columns do we have? - rows := len(g.rows) - columns := len(g.columns) - for _, item := range items { - rowEnd := item.Row + item.Height - if rowEnd > rows { - rows = rowEnd - } - columnEnd := item.Column + item.Width - if columnEnd > columns { - columns = columnEnd - } - } - if rows == 0 || columns == 0 { - return // No content. - } - - // Where are they located? - rowPos := make([]int, rows) - rowHeight := make([]int, rows) - columnPos := make([]int, columns) - columnWidth := make([]int, columns) - - // How much space do we distribute? - remainingWidth := width - remainingHeight := height - proportionalWidth := 0 - proportionalHeight := 0 - for index, row := range g.rows { - if row > 0 { - if row < g.minHeight { - row = g.minHeight - } - remainingHeight -= row - rowHeight[index] = row - } else if row == 0 { - proportionalHeight++ - } else { - proportionalHeight += -row - } - } - for index, column := range g.columns { - if column > 0 { - if column < g.minWidth { - column = g.minWidth - } - remainingWidth -= column - columnWidth[index] = column - } else if column == 0 { - proportionalWidth++ - } else { - proportionalWidth += -column - } - } - if g.borders { - remainingHeight -= rows + 1 - remainingWidth -= columns + 1 - } else { - remainingHeight -= (rows - 1) * g.gapRows - remainingWidth -= (columns - 1) * g.gapColumns - } - if rows > len(g.rows) { - proportionalHeight += rows - len(g.rows) - } - if columns > len(g.columns) { - proportionalWidth += columns - len(g.columns) - } - - // Distribute proportional rows/columns. - for index := 0; index < rows; index++ { - row := 0 - if index < len(g.rows) { - row = g.rows[index] - } - if row > 0 { - if row < g.minHeight { - row = g.minHeight - } - continue // Not proportional. We already know the width. - } else if row == 0 { - row = 1 - } else { - row = -row - } - rowAbs := row * remainingHeight / proportionalHeight - remainingHeight -= rowAbs - proportionalHeight -= row - if rowAbs < g.minHeight { - rowAbs = g.minHeight - } - rowHeight[index] = rowAbs - } - for index := 0; index < columns; index++ { - column := 0 - if index < len(g.columns) { - column = g.columns[index] - } - if column > 0 { - if column < g.minWidth { - column = g.minWidth - } - continue // Not proportional. We already know the height. - } else if column == 0 { - column = 1 - } else { - column = -column - } - columnAbs := column * remainingWidth / proportionalWidth - remainingWidth -= columnAbs - proportionalWidth -= column - if columnAbs < g.minWidth { - columnAbs = g.minWidth - } - columnWidth[index] = columnAbs - } - - // Calculate row/column positions. - var columnX, rowY int - if g.borders { - columnX++ - rowY++ - } - for index, row := range rowHeight { - rowPos[index] = rowY - gap := g.gapRows - if g.borders { - gap = 1 - } - rowY += row + gap - } - for index, column := range columnWidth { - columnPos[index] = columnX - gap := g.gapColumns - if g.borders { - gap = 1 - } - columnX += column + gap - } - - // Calculate primitive positions. - var focus *gridItem // The item which has focus. - for primitive, item := range items { - px := columnPos[item.Column] - py := rowPos[item.Row] - var pw, ph int - for index := 0; index < item.Height; index++ { - ph += rowHeight[item.Row+index] - } - for index := 0; index < item.Width; index++ { - pw += columnWidth[item.Column+index] - } - if g.borders { - pw += item.Width - 1 - ph += item.Height - 1 - } else { - pw += (item.Width - 1) * g.gapColumns - ph += (item.Height - 1) * g.gapRows - } - item.x, item.y, item.w, item.h = px, py, pw, ph - item.visible = true - if primitive.HasFocus() { - focus = item - } - } - - // Calculate screen offsets. - var offsetX, offsetY int - add := 1 - if !g.borders { - add = g.gapRows - } - for index, height := range rowHeight { - if index >= g.rowOffset { - break - } - offsetY += height + add - } - if !g.borders { - add = g.gapColumns - } - for index, width := range columnWidth { - if index >= g.columnOffset { - break - } - offsetX += width + add - } - - // Line up the last row/column with the end of the available area. - var border int - if g.borders { - border = 1 - } - last := len(rowPos) - 1 - if rowPos[last]+rowHeight[last]+border-offsetY < height { - offsetY = rowPos[last] - height + rowHeight[last] + border - } - last = len(columnPos) - 1 - if columnPos[last]+columnWidth[last]+border-offsetX < width { - offsetX = columnPos[last] - width + columnWidth[last] + border - } - - // The focused item must be within the visible area. - if focus != nil { - if focus.y+focus.h-offsetY >= height { - offsetY = focus.y - height + focus.h - } - if focus.y-offsetY < 0 { - offsetY = focus.y - } - if focus.x+focus.w-offsetX >= width { - offsetX = focus.x - width + focus.w - } - if focus.x-offsetX < 0 { - offsetX = focus.x - } - } - - // Adjust row/column offsets based on this value. - var from, to int - for index, pos := range rowPos { - if pos-offsetY < 0 { - from = index + 1 - } - if pos-offsetY < height { - to = index - } - } - if g.rowOffset < from { - g.rowOffset = from - } - if g.rowOffset > to { - g.rowOffset = to - } - from, to = 0, 0 - for index, pos := range columnPos { - if pos-offsetX < 0 { - from = index + 1 - } - if pos-offsetX < width { - to = index - } - } - if g.columnOffset < from { - g.columnOffset = from - } - if g.columnOffset > to { - g.columnOffset = to - } - - // Draw primitives and borders. - for primitive, item := range items { - // Final primitive position. - if !item.visible { - continue - } - item.x -= offsetX - item.y -= offsetY - if item.x >= width || item.x+item.w <= 0 || item.y >= height || item.y+item.h <= 0 { - item.visible = false - continue - } - if item.x+item.w > width { - item.w = width - item.x - } - if item.y+item.h > height { - item.h = height - item.y - } - if item.x < 0 { - item.w += item.x - item.x = 0 - } - if item.y < 0 { - item.h += item.y - item.y = 0 - } - if item.w <= 0 || item.h <= 0 { - item.visible = false - continue - } - item.x += x - item.y += y - primitive.SetRect(item.x, item.y, item.w, item.h) - - // Draw primitive. - if item == focus { - defer primitive.Draw(screen) - } else { - primitive.Draw(screen) - } - - // Draw border around primitive. - if g.borders { - for bx := item.x; bx < item.x+item.w; bx++ { // Top/bottom lines. - if bx < 0 || bx >= screenWidth { - continue - } - by := item.y - 1 - if by >= 0 && by < screenHeight { - PrintJoinedSemigraphics(screen, bx, by, Borders.Horizontal, g.bordersColor) - } - by = item.y + item.h - if by >= 0 && by < screenHeight { - PrintJoinedSemigraphics(screen, bx, by, Borders.Horizontal, g.bordersColor) - } - } - for by := item.y; by < item.y+item.h; by++ { // Left/right lines. - if by < 0 || by >= screenHeight { - continue - } - bx := item.x - 1 - if bx >= 0 && bx < screenWidth { - PrintJoinedSemigraphics(screen, bx, by, Borders.Vertical, g.bordersColor) - } - bx = item.x + item.w - if bx >= 0 && bx < screenWidth { - PrintJoinedSemigraphics(screen, bx, by, Borders.Vertical, g.bordersColor) - } - } - bx, by := item.x-1, item.y-1 // Top-left corner. - if bx >= 0 && bx < screenWidth && by >= 0 && by < screenHeight { - PrintJoinedSemigraphics(screen, bx, by, Borders.TopLeft, g.bordersColor) - } - bx, by = item.x+item.w, item.y-1 // Top-right corner. - if bx >= 0 && bx < screenWidth && by >= 0 && by < screenHeight { - PrintJoinedSemigraphics(screen, bx, by, Borders.TopRight, g.bordersColor) - } - bx, by = item.x-1, item.y+item.h // Bottom-left corner. - if bx >= 0 && bx < screenWidth && by >= 0 && by < screenHeight { - PrintJoinedSemigraphics(screen, bx, by, Borders.BottomLeft, g.bordersColor) - } - bx, by = item.x+item.w, item.y+item.h // Bottom-right corner. - if bx >= 0 && bx < screenWidth && by >= 0 && by < screenHeight { - PrintJoinedSemigraphics(screen, bx, by, Borders.BottomRight, g.bordersColor) - } - } - } -} - -// MouseHandler returns the mouse handler for this primitive. -func (g *Grid) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return g.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if !g.InRect(event.Position()) { - return false, nil - } - - // Pass mouse events along to the first child item that takes it. - for _, item := range g.items { - if item.Item == nil { - continue - } - consumed, capture = item.Item.MouseHandler()(action, event, setFocus) - if consumed { - return - } - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/inputfield.go b/vendor/github.com/rivo/tview/inputfield.go deleted file mode 100644 index 635da32..0000000 --- a/vendor/github.com/rivo/tview/inputfield.go +++ /dev/null @@ -1,627 +0,0 @@ -package tview - -import ( - "math" - "regexp" - "strings" - "sync" - "unicode/utf8" - - "github.com/gdamore/tcell/v2" -) - -// InputField is a one-line box (three lines if there is a title) where the -// user can enter text. Use SetAcceptanceFunc() to accept or reject input, -// SetChangedFunc() to listen for changes, and SetMaskCharacter() to hide input -// from onlookers (e.g. for password input). -// -// The following keys can be used for navigation and editing: -// -// - Left arrow: Move left by one character. -// - Right arrow: Move right by one character. -// - Home, Ctrl-A, Alt-a: Move to the beginning of the line. -// - End, Ctrl-E, Alt-e: Move to the end of the line. -// - Alt-left, Alt-b: Move left by one word. -// - Alt-right, Alt-f: Move right by one word. -// - Backspace: Delete the character before the cursor. -// - Delete: Delete the character after the cursor. -// - Ctrl-K: Delete from the cursor to the end of the line. -// - Ctrl-W: Delete the last word before the cursor. -// - Ctrl-U: Delete the entire line. -// -// See https://github.com/rivo/tview/wiki/InputField for an example. -type InputField struct { - *Box - - // The text that was entered. - text string - - // The text to be displayed before the input area. - label string - - // The text to be displayed in the input area when "text" is empty. - placeholder string - - // The label color. - labelColor tcell.Color - - // The background color of the input area. - fieldBackgroundColor tcell.Color - - // The text color of the input area. - fieldTextColor tcell.Color - - // The text color of the placeholder. - placeholderTextColor tcell.Color - - // The screen width of the label area. A value of 0 means use the width of - // the label text. - labelWidth int - - // The screen width of the input area. A value of 0 means extend as much as - // possible. - fieldWidth int - - // A character to mask entered text (useful for password fields). A value of 0 - // disables masking. - maskCharacter rune - - // The cursor position as a byte index into the text string. - cursorPos int - - // An optional autocomplete function which receives the current text of the - // input field and returns a slice of strings to be displayed in a drop-down - // selection. - autocomplete func(text string) []string - - // The List object which shows the selectable autocomplete entries. If not - // nil, the list's main texts represent the current autocomplete entries. - autocompleteList *List - autocompleteListMutex sync.Mutex - - // An optional function which may reject the last character that was entered. - accept func(text string, ch rune) bool - - // An optional function which is called when the input has changed. - changed func(text string) - - // An optional function which is called when the user indicated that they - // are done entering text. The key which was pressed is provided (tab, - // shift-tab, enter, or escape). - done func(tcell.Key) - - // A callback function set by the Form class and called when the user leaves - // this form item. - finished func(tcell.Key) - - fieldX int // The x-coordinate of the input field as determined during the last call to Draw(). - offset int // The number of bytes of the text string skipped ahead while drawing. -} - -// NewInputField returns a new input field. -func NewInputField() *InputField { - return &InputField{ - Box: NewBox(), - labelColor: Styles.SecondaryTextColor, - fieldBackgroundColor: Styles.ContrastBackgroundColor, - fieldTextColor: Styles.PrimaryTextColor, - placeholderTextColor: Styles.ContrastSecondaryTextColor, - } -} - -// SetText sets the current text of the input field. -func (i *InputField) SetText(text string) *InputField { - i.text = text - i.cursorPos = len(text) - if i.changed != nil { - i.changed(text) - } - return i -} - -// GetText returns the current text of the input field. -func (i *InputField) GetText() string { - return i.text -} - -// SetLabel sets the text to be displayed before the input area. -func (i *InputField) SetLabel(label string) *InputField { - i.label = label - return i -} - -// GetLabel returns the text to be displayed before the input area. -func (i *InputField) GetLabel() string { - return i.label -} - -// SetLabelWidth sets the screen width of the label. A value of 0 will cause the -// primitive to use the width of the label string. -func (i *InputField) SetLabelWidth(width int) *InputField { - i.labelWidth = width - return i -} - -// SetPlaceholder sets the text to be displayed when the input text is empty. -func (i *InputField) SetPlaceholder(text string) *InputField { - i.placeholder = text - return i -} - -// SetLabelColor sets the color of the label. -func (i *InputField) SetLabelColor(color tcell.Color) *InputField { - i.labelColor = color - return i -} - -// SetFieldBackgroundColor sets the background color of the input area. -func (i *InputField) SetFieldBackgroundColor(color tcell.Color) *InputField { - i.fieldBackgroundColor = color - return i -} - -// SetFieldTextColor sets the text color of the input area. -func (i *InputField) SetFieldTextColor(color tcell.Color) *InputField { - i.fieldTextColor = color - return i -} - -// SetPlaceholderTextColor sets the text color of placeholder text. -func (i *InputField) SetPlaceholderTextColor(color tcell.Color) *InputField { - i.placeholderTextColor = color - return i -} - -// SetFormAttributes sets attributes shared by all form items. -func (i *InputField) SetFormAttributes(labelWidth int, labelColor, bgColor, fieldTextColor, fieldBgColor tcell.Color) FormItem { - i.labelWidth = labelWidth - i.labelColor = labelColor - i.backgroundColor = bgColor - i.fieldTextColor = fieldTextColor - i.fieldBackgroundColor = fieldBgColor - return i -} - -// SetFieldWidth sets the screen width of the input area. A value of 0 means -// extend as much as possible. -func (i *InputField) SetFieldWidth(width int) *InputField { - i.fieldWidth = width - return i -} - -// GetFieldWidth returns this primitive's field width. -func (i *InputField) GetFieldWidth() int { - return i.fieldWidth -} - -// SetMaskCharacter sets a character that masks user input on a screen. A value -// of 0 disables masking. -func (i *InputField) SetMaskCharacter(mask rune) *InputField { - i.maskCharacter = mask - return i -} - -// SetAutocompleteFunc sets an autocomplete callback function which may return -// strings to be selected from a drop-down based on the current text of the -// input field. The drop-down appears only if len(entries) > 0. The callback is -// invoked in this function and whenever the current text changes or when -// Autocomplete() is called. Entries are cleared when the user selects an entry -// or presses Escape. -func (i *InputField) SetAutocompleteFunc(callback func(currentText string) (entries []string)) *InputField { - i.autocomplete = callback - i.Autocomplete() - return i -} - -// Autocomplete invokes the autocomplete callback (if there is one). If the -// length of the returned autocomplete entries slice is greater than 0, the -// input field will present the user with a corresponding drop-down list the -// next time the input field is drawn. -// -// It is safe to call this function from any goroutine. Note that the input -// field is not redrawn automatically unless called from the main goroutine -// (e.g. in response to events). -func (i *InputField) Autocomplete() *InputField { - i.autocompleteListMutex.Lock() - defer i.autocompleteListMutex.Unlock() - if i.autocomplete == nil { - return i - } - - // Do we have any autocomplete entries? - entries := i.autocomplete(i.text) - if len(entries) == 0 { - // No entries, no list. - i.autocompleteList = nil - return i - } - - // Make a list if we have none. - if i.autocompleteList == nil { - i.autocompleteList = NewList() - i.autocompleteList.ShowSecondaryText(false). - SetMainTextColor(Styles.PrimitiveBackgroundColor). - SetSelectedTextColor(Styles.PrimitiveBackgroundColor). - SetSelectedBackgroundColor(Styles.PrimaryTextColor). - SetHighlightFullLine(true). - SetBackgroundColor(Styles.MoreContrastBackgroundColor) - } - - // Fill it with the entries. - currentEntry := -1 - i.autocompleteList.Clear() - for index, entry := range entries { - i.autocompleteList.AddItem(entry, "", 0, nil) - if currentEntry < 0 && entry == i.text { - currentEntry = index - } - } - - // Set the selection if we have one. - if currentEntry >= 0 { - i.autocompleteList.SetCurrentItem(currentEntry) - } - - return i -} - -// SetAcceptanceFunc sets a handler which may reject the last character that was -// entered (by returning false). -// -// This package defines a number of variables prefixed with InputField which may -// be used for common input (e.g. numbers, maximum text length). -func (i *InputField) SetAcceptanceFunc(handler func(textToCheck string, lastChar rune) bool) *InputField { - i.accept = handler - return i -} - -// SetChangedFunc sets a handler which is called whenever the text of the input -// field has changed. It receives the current text (after the change). -func (i *InputField) SetChangedFunc(handler func(text string)) *InputField { - i.changed = handler - return i -} - -// SetDoneFunc sets a handler which is called when the user is done entering -// text. The callback function is provided with the key that was pressed, which -// is one of the following: -// -// - KeyEnter: Done entering text. -// - KeyEscape: Abort text input. -// - KeyTab: Move to the next field. -// - KeyBacktab: Move to the previous field. -func (i *InputField) SetDoneFunc(handler func(key tcell.Key)) *InputField { - i.done = handler - return i -} - -// SetFinishedFunc sets a callback invoked when the user leaves this form item. -func (i *InputField) SetFinishedFunc(handler func(key tcell.Key)) FormItem { - i.finished = handler - return i -} - -// Draw draws this primitive onto the screen. -func (i *InputField) Draw(screen tcell.Screen) { - i.Box.DrawForSubclass(screen, i) - - // Prepare - x, y, width, height := i.GetInnerRect() - rightLimit := x + width - if height < 1 || rightLimit <= x { - return - } - - // Draw label. - if i.labelWidth > 0 { - labelWidth := i.labelWidth - if labelWidth > rightLimit-x { - labelWidth = rightLimit - x - } - Print(screen, i.label, x, y, labelWidth, AlignLeft, i.labelColor) - x += labelWidth - } else { - _, drawnWidth := Print(screen, i.label, x, y, rightLimit-x, AlignLeft, i.labelColor) - x += drawnWidth - } - - // Draw input area. - i.fieldX = x - fieldWidth := i.fieldWidth - if fieldWidth == 0 { - fieldWidth = math.MaxInt32 - } - if rightLimit-x < fieldWidth { - fieldWidth = rightLimit - x - } - fieldStyle := tcell.StyleDefault.Background(i.fieldBackgroundColor) - for index := 0; index < fieldWidth; index++ { - screen.SetContent(x+index, y, ' ', nil, fieldStyle) - } - - // Text. - var cursorScreenPos int - text := i.text - if text == "" && i.placeholder != "" { - // Draw placeholder text. - Print(screen, Escape(i.placeholder), x, y, fieldWidth, AlignLeft, i.placeholderTextColor) - i.offset = 0 - } else { - // Draw entered text. - if i.maskCharacter > 0 { - text = strings.Repeat(string(i.maskCharacter), utf8.RuneCountInString(i.text)) - } - if fieldWidth >= stringWidth(text) { - // We have enough space for the full text. - Print(screen, Escape(text), x, y, fieldWidth, AlignLeft, i.fieldTextColor) - i.offset = 0 - iterateString(text, func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - if textPos >= i.cursorPos { - return true - } - cursorScreenPos += screenWidth - return false - }) - } else { - // The text doesn't fit. Where is the cursor? - if i.cursorPos < 0 { - i.cursorPos = 0 - } else if i.cursorPos > len(text) { - i.cursorPos = len(text) - } - // Shift the text so the cursor is inside the field. - var shiftLeft int - if i.offset > i.cursorPos { - i.offset = i.cursorPos - } else if subWidth := stringWidth(text[i.offset:i.cursorPos]); subWidth > fieldWidth-1 { - shiftLeft = subWidth - fieldWidth + 1 - } - currentOffset := i.offset - iterateString(text, func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - if textPos >= currentOffset { - if shiftLeft > 0 { - i.offset = textPos + textWidth - shiftLeft -= screenWidth - } else { - if textPos+textWidth > i.cursorPos { - return true - } - cursorScreenPos += screenWidth - } - } - return false - }) - Print(screen, Escape(text[i.offset:]), x, y, fieldWidth, AlignLeft, i.fieldTextColor) - } - } - - // Draw autocomplete list. - i.autocompleteListMutex.Lock() - defer i.autocompleteListMutex.Unlock() - if i.autocompleteList != nil { - // How much space do we need? - lheight := i.autocompleteList.GetItemCount() - lwidth := 0 - for index := 0; index < lheight; index++ { - entry, _ := i.autocompleteList.GetItemText(index) - width := TaggedStringWidth(entry) - if width > lwidth { - lwidth = width - } - } - - // We prefer to drop down but if there is no space, maybe drop up? - lx := x - ly := y + 1 - _, sheight := screen.Size() - if ly+lheight >= sheight && ly-2 > lheight-ly { - ly = y - lheight - if ly < 0 { - ly = 0 - } - } - if ly+lheight >= sheight { - lheight = sheight - ly - } - i.autocompleteList.SetRect(lx, ly, lwidth, lheight) - i.autocompleteList.Draw(screen) - } - - // Set cursor. - if i.HasFocus() { - screen.ShowCursor(x+cursorScreenPos, y) - } -} - -// InputHandler returns the handler for this primitive. -func (i *InputField) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return i.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - // Trigger changed events. - currentText := i.text - defer func() { - if i.text != currentText { - i.Autocomplete() - if i.changed != nil { - i.changed(i.text) - } - } - }() - - // Movement functions. - home := func() { i.cursorPos = 0 } - end := func() { i.cursorPos = len(i.text) } - moveLeft := func() { - iterateStringReverse(i.text[:i.cursorPos], func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - i.cursorPos -= textWidth - return true - }) - } - moveRight := func() { - iterateString(i.text[i.cursorPos:], func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - i.cursorPos += textWidth - return true - }) - } - moveWordLeft := func() { - i.cursorPos = len(regexp.MustCompile(`\S+\s*$`).ReplaceAllString(i.text[:i.cursorPos], "")) - } - moveWordRight := func() { - i.cursorPos = len(i.text) - len(regexp.MustCompile(`^\s*\S+\s*`).ReplaceAllString(i.text[i.cursorPos:], "")) - } - - // Add character function. Returns whether or not the rune character is - // accepted. - add := func(r rune) bool { - newText := i.text[:i.cursorPos] + string(r) + i.text[i.cursorPos:] - if i.accept != nil && !i.accept(newText, r) { - return false - } - i.text = newText - i.cursorPos += len(string(r)) - return true - } - - // Finish up. - finish := func(key tcell.Key) { - if i.done != nil { - i.done(key) - } - if i.finished != nil { - i.finished(key) - } - } - - // Process key event. - i.autocompleteListMutex.Lock() - defer i.autocompleteListMutex.Unlock() - switch key := event.Key(); key { - case tcell.KeyRune: // Regular character. - if event.Modifiers()&tcell.ModAlt > 0 { - // We accept some Alt- key combinations. - switch event.Rune() { - case 'a': // Home. - home() - case 'e': // End. - end() - case 'b': // Move word left. - moveWordLeft() - case 'f': // Move word right. - moveWordRight() - default: - if !add(event.Rune()) { - return - } - } - } else { - // Other keys are simply accepted as regular characters. - if !add(event.Rune()) { - return - } - } - case tcell.KeyCtrlU: // Delete all. - i.text = "" - i.cursorPos = 0 - case tcell.KeyCtrlK: // Delete until the end of the line. - i.text = i.text[:i.cursorPos] - case tcell.KeyCtrlW: // Delete last word. - lastWord := regexp.MustCompile(`\S+\s*$`) - newText := lastWord.ReplaceAllString(i.text[:i.cursorPos], "") + i.text[i.cursorPos:] - i.cursorPos -= len(i.text) - len(newText) - i.text = newText - case tcell.KeyBackspace, tcell.KeyBackspace2: // Delete character before the cursor. - iterateStringReverse(i.text[:i.cursorPos], func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - i.text = i.text[:textPos] + i.text[textPos+textWidth:] - i.cursorPos -= textWidth - return true - }) - if i.offset >= i.cursorPos { - i.offset = 0 - } - case tcell.KeyDelete: // Delete character after the cursor. - iterateString(i.text[i.cursorPos:], func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - i.text = i.text[:i.cursorPos] + i.text[i.cursorPos+textWidth:] - return true - }) - case tcell.KeyLeft: - if event.Modifiers()&tcell.ModAlt > 0 { - moveWordLeft() - } else { - moveLeft() - } - case tcell.KeyRight: - if event.Modifiers()&tcell.ModAlt > 0 { - moveWordRight() - } else { - moveRight() - } - case tcell.KeyHome, tcell.KeyCtrlA: - home() - case tcell.KeyEnd, tcell.KeyCtrlE: - end() - case tcell.KeyEnter, tcell.KeyEscape: // We might be done. - if i.autocompleteList != nil { - i.autocompleteList = nil - } else { - finish(key) - } - case tcell.KeyDown, tcell.KeyTab: // Autocomplete selection. - if i.autocompleteList != nil { - count := i.autocompleteList.GetItemCount() - newEntry := i.autocompleteList.GetCurrentItem() + 1 - if newEntry >= count { - newEntry = 0 - } - i.autocompleteList.SetCurrentItem(newEntry) - currentText, _ = i.autocompleteList.GetItemText(newEntry) // Don't trigger changed function twice. - currentText = stripTags(currentText) - i.SetText(currentText) - } else { - finish(key) - } - case tcell.KeyUp, tcell.KeyBacktab: // Autocomplete selection. - if i.autocompleteList != nil { - newEntry := i.autocompleteList.GetCurrentItem() - 1 - if newEntry < 0 { - newEntry = i.autocompleteList.GetItemCount() - 1 - } - i.autocompleteList.SetCurrentItem(newEntry) - currentText, _ = i.autocompleteList.GetItemText(newEntry) // Don't trigger changed function twice. - currentText = stripTags(currentText) - i.SetText(currentText) - } else { - finish(key) - } - } - }) -} - -// MouseHandler returns the mouse handler for this primitive. -func (i *InputField) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return i.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - x, y := event.Position() - _, rectY, _, _ := i.GetInnerRect() - if !i.InRect(x, y) { - return false, nil - } - - // Process mouse event. - if action == MouseLeftClick && y == rectY { - // Determine where to place the cursor. - if x >= i.fieldX { - if !iterateString(i.text[i.offset:], func(main rune, comb []rune, textPos int, textWidth int, screenPos int, screenWidth int) bool { - if x-i.fieldX < screenPos+screenWidth { - i.cursorPos = textPos + i.offset - return true - } - return false - }) { - i.cursorPos = len(i.text) - } - } - setFocus(i) - consumed = true - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/list.go b/vendor/github.com/rivo/tview/list.go deleted file mode 100644 index c291a53..0000000 --- a/vendor/github.com/rivo/tview/list.go +++ /dev/null @@ -1,628 +0,0 @@ -package tview - -import ( - "fmt" - "strings" - - "github.com/gdamore/tcell/v2" -) - -// listItem represents one item in a List. -type listItem struct { - MainText string // The main text of the list item. - SecondaryText string // A secondary text to be shown underneath the main text. - Shortcut rune // The key to select the list item directly, 0 if there is no shortcut. - Selected func() // The optional function which is called when the item is selected. -} - -// List displays rows of items, each of which can be selected. -// -// See https://github.com/rivo/tview/wiki/List for an example. -type List struct { - *Box - - // The items of the list. - items []*listItem - - // The index of the currently selected item. - currentItem int - - // Whether or not to show the secondary item texts. - showSecondaryText bool - - // The item main text color. - mainTextColor tcell.Color - - // The item secondary text color. - secondaryTextColor tcell.Color - - // The item shortcut text color. - shortcutColor tcell.Color - - // The text color for selected items. - selectedTextColor tcell.Color - - // The background color for selected items. - selectedBackgroundColor tcell.Color - - // If true, the selection is only shown when the list has focus. - selectedFocusOnly bool - - // If true, the entire row is highlighted when selected. - highlightFullLine bool - - // Whether or not navigating the list will wrap around. - wrapAround bool - - // The number of list items skipped at the top before the first item is drawn. - offset int - - // An optional function which is called when the user has navigated to a list - // item. - changed func(index int, mainText, secondaryText string, shortcut rune) - - // An optional function which is called when a list item was selected. This - // function will be called even if the list item defines its own callback. - selected func(index int, mainText, secondaryText string, shortcut rune) - - // An optional function which is called when the user presses the Escape key. - done func() -} - -// NewList returns a new form. -func NewList() *List { - return &List{ - Box: NewBox(), - showSecondaryText: true, - wrapAround: true, - mainTextColor: Styles.PrimaryTextColor, - secondaryTextColor: Styles.TertiaryTextColor, - shortcutColor: Styles.SecondaryTextColor, - selectedTextColor: Styles.PrimitiveBackgroundColor, - selectedBackgroundColor: Styles.PrimaryTextColor, - } -} - -// SetCurrentItem sets the currently selected item by its index, starting at 0 -// for the first item. If a negative index is provided, items are referred to -// from the back (-1 = last item, -2 = second-to-last item, and so on). Out of -// range indices are clamped to the beginning/end. -// -// Calling this function triggers a "changed" event if the selection changes. -func (l *List) SetCurrentItem(index int) *List { - if index < 0 { - index = len(l.items) + index - } - if index >= len(l.items) { - index = len(l.items) - 1 - } - if index < 0 { - index = 0 - } - - if index != l.currentItem && l.changed != nil { - item := l.items[index] - l.changed(index, item.MainText, item.SecondaryText, item.Shortcut) - } - - l.currentItem = index - - return l -} - -// GetCurrentItem returns the index of the currently selected list item, -// starting at 0 for the first item. -func (l *List) GetCurrentItem() int { - return l.currentItem -} - -// RemoveItem removes the item with the given index (starting at 0) from the -// list. If a negative index is provided, items are referred to from the back -// (-1 = last item, -2 = second-to-last item, and so on). Out of range indices -// are clamped to the beginning/end, i.e. unless the list is empty, an item is -// always removed. -// -// The currently selected item is shifted accordingly. If it is the one that is -// removed, a "changed" event is fired. -func (l *List) RemoveItem(index int) *List { - if len(l.items) == 0 { - return l - } - - // Adjust index. - if index < 0 { - index = len(l.items) + index - } - if index >= len(l.items) { - index = len(l.items) - 1 - } - if index < 0 { - index = 0 - } - - // Remove item. - l.items = append(l.items[:index], l.items[index+1:]...) - - // If there is nothing left, we're done. - if len(l.items) == 0 { - return l - } - - // Shift current item. - previousCurrentItem := l.currentItem - if l.currentItem >= index { - l.currentItem-- - } - - // Fire "changed" event for removed items. - if previousCurrentItem == index && l.changed != nil { - item := l.items[l.currentItem] - l.changed(l.currentItem, item.MainText, item.SecondaryText, item.Shortcut) - } - - return l -} - -// SetMainTextColor sets the color of the items' main text. -func (l *List) SetMainTextColor(color tcell.Color) *List { - l.mainTextColor = color - return l -} - -// SetSecondaryTextColor sets the color of the items' secondary text. -func (l *List) SetSecondaryTextColor(color tcell.Color) *List { - l.secondaryTextColor = color - return l -} - -// SetShortcutColor sets the color of the items' shortcut. -func (l *List) SetShortcutColor(color tcell.Color) *List { - l.shortcutColor = color - return l -} - -// SetSelectedTextColor sets the text color of selected items. -func (l *List) SetSelectedTextColor(color tcell.Color) *List { - l.selectedTextColor = color - return l -} - -// SetSelectedBackgroundColor sets the background color of selected items. -func (l *List) SetSelectedBackgroundColor(color tcell.Color) *List { - l.selectedBackgroundColor = color - return l -} - -// SetSelectedFocusOnly sets a flag which determines when the currently selected -// list item is highlighted. If set to true, selected items are only highlighted -// when the list has focus. If set to false, they are always highlighted. -func (l *List) SetSelectedFocusOnly(focusOnly bool) *List { - l.selectedFocusOnly = focusOnly - return l -} - -// SetHighlightFullLine sets a flag which determines whether the colored -// background of selected items spans the entire width of the view. If set to -// true, the highlight spans the entire view. If set to false, only the text of -// the selected item from beginning to end is highlighted. -func (l *List) SetHighlightFullLine(highlight bool) *List { - l.highlightFullLine = highlight - return l -} - -// ShowSecondaryText determines whether or not to show secondary item texts. -func (l *List) ShowSecondaryText(show bool) *List { - l.showSecondaryText = show - return l -} - -// SetWrapAround sets the flag that determines whether navigating the list will -// wrap around. That is, navigating downwards on the last item will move the -// selection to the first item (similarly in the other direction). If set to -// false, the selection won't change when navigating downwards on the last item -// or navigating upwards on the first item. -func (l *List) SetWrapAround(wrapAround bool) *List { - l.wrapAround = wrapAround - return l -} - -// SetChangedFunc sets the function which is called when the user navigates to -// a list item. The function receives the item's index in the list of items -// (starting with 0), its main text, secondary text, and its shortcut rune. -// -// This function is also called when the first item is added or when -// SetCurrentItem() is called. -func (l *List) SetChangedFunc(handler func(index int, mainText string, secondaryText string, shortcut rune)) *List { - l.changed = handler - return l -} - -// SetSelectedFunc sets the function which is called when the user selects a -// list item by pressing Enter on the current selection. The function receives -// the item's index in the list of items (starting with 0), its main text, -// secondary text, and its shortcut rune. -func (l *List) SetSelectedFunc(handler func(int, string, string, rune)) *List { - l.selected = handler - return l -} - -// SetDoneFunc sets a function which is called when the user presses the Escape -// key. -func (l *List) SetDoneFunc(handler func()) *List { - l.done = handler - return l -} - -// AddItem calls InsertItem() with an index of -1. -func (l *List) AddItem(mainText, secondaryText string, shortcut rune, selected func()) *List { - l.InsertItem(-1, mainText, secondaryText, shortcut, selected) - return l -} - -// InsertItem adds a new item to the list at the specified index. An index of 0 -// will insert the item at the beginning, an index of 1 before the second item, -// and so on. An index of GetItemCount() or higher will insert the item at the -// end of the list. Negative indices are also allowed: An index of -1 will -// insert the item at the end of the list, an index of -2 before the last item, -// and so on. An index of -GetItemCount()-1 or lower will insert the item at the -// beginning. -// -// An item has a main text which will be highlighted when selected. It also has -// a secondary text which is shown underneath the main text (if it is set to -// visible) but which may remain empty. -// -// The shortcut is a key binding. If the specified rune is entered, the item -// is selected immediately. Set to 0 for no binding. -// -// The "selected" callback will be invoked when the user selects the item. You -// may provide nil if no such callback is needed or if all events are handled -// through the selected callback set with SetSelectedFunc(). -// -// The currently selected item will shift its position accordingly. If the list -// was previously empty, a "changed" event is fired because the new item becomes -// selected. -func (l *List) InsertItem(index int, mainText, secondaryText string, shortcut rune, selected func()) *List { - item := &listItem{ - MainText: mainText, - SecondaryText: secondaryText, - Shortcut: shortcut, - Selected: selected, - } - - // Shift index to range. - if index < 0 { - index = len(l.items) + index + 1 - } - if index < 0 { - index = 0 - } else if index > len(l.items) { - index = len(l.items) - } - - // Shift current item. - if l.currentItem < len(l.items) && l.currentItem >= index { - l.currentItem++ - } - - // Insert item (make space for the new item, then shift and insert). - l.items = append(l.items, nil) - if index < len(l.items)-1 { // -1 because l.items has already grown by one item. - copy(l.items[index+1:], l.items[index:]) - } - l.items[index] = item - - // Fire a "change" event for the first item in the list. - if len(l.items) == 1 && l.changed != nil { - item := l.items[0] - l.changed(0, item.MainText, item.SecondaryText, item.Shortcut) - } - - return l -} - -// GetItemCount returns the number of items in the list. -func (l *List) GetItemCount() int { - return len(l.items) -} - -// GetItemText returns an item's texts (main and secondary). Panics if the index -// is out of range. -func (l *List) GetItemText(index int) (main, secondary string) { - return l.items[index].MainText, l.items[index].SecondaryText -} - -// SetItemText sets an item's main and secondary text. Panics if the index is -// out of range. -func (l *List) SetItemText(index int, main, secondary string) *List { - item := l.items[index] - item.MainText = main - item.SecondaryText = secondary - return l -} - -// FindItems searches the main and secondary texts for the given strings and -// returns a list of item indices in which those strings are found. One of the -// two search strings may be empty, it will then be ignored. Indices are always -// returned in ascending order. -// -// If mustContainBoth is set to true, mainSearch must be contained in the main -// text AND secondarySearch must be contained in the secondary text. If it is -// false, only one of the two search strings must be contained. -// -// Set ignoreCase to true for case-insensitive search. -func (l *List) FindItems(mainSearch, secondarySearch string, mustContainBoth, ignoreCase bool) (indices []int) { - if mainSearch == "" && secondarySearch == "" { - return - } - - if ignoreCase { - mainSearch = strings.ToLower(mainSearch) - secondarySearch = strings.ToLower(secondarySearch) - } - - for index, item := range l.items { - mainText := item.MainText - secondaryText := item.SecondaryText - if ignoreCase { - mainText = strings.ToLower(mainText) - secondaryText = strings.ToLower(secondaryText) - } - - // strings.Contains() always returns true for a "" search. - mainContained := strings.Contains(mainText, mainSearch) - secondaryContained := strings.Contains(secondaryText, secondarySearch) - if mustContainBoth && mainContained && secondaryContained || - !mustContainBoth && (mainText != "" && mainContained || secondaryText != "" && secondaryContained) { - indices = append(indices, index) - } - } - - return -} - -// Clear removes all items from the list. -func (l *List) Clear() *List { - l.items = nil - l.currentItem = 0 - return l -} - -// Draw draws this primitive onto the screen. -func (l *List) Draw(screen tcell.Screen) { - l.Box.DrawForSubclass(screen, l) - - // Determine the dimensions. - x, y, width, height := l.GetInnerRect() - bottomLimit := y + height - _, totalHeight := screen.Size() - if bottomLimit > totalHeight { - bottomLimit = totalHeight - } - - // Do we show any shortcuts? - var showShortcuts bool - for _, item := range l.items { - if item.Shortcut != 0 { - showShortcuts = true - x += 4 - width -= 4 - break - } - } - - // Adjust offset to keep the current selection in view. - if l.currentItem < l.offset { - l.offset = l.currentItem - } else if l.showSecondaryText { - if 2*(l.currentItem-l.offset) >= height-1 { - l.offset = (2*l.currentItem + 3 - height) / 2 - } - } else { - if l.currentItem-l.offset >= height { - l.offset = l.currentItem + 1 - height - } - } - - // Draw the list items. - for index, item := range l.items { - if index < l.offset { - continue - } - - if y >= bottomLimit { - break - } - - // Shortcuts. - if showShortcuts && item.Shortcut != 0 { - Print(screen, fmt.Sprintf("(%s)", string(item.Shortcut)), x-5, y, 4, AlignRight, l.shortcutColor) - } - - // Main text. - Print(screen, item.MainText, x, y, width, AlignLeft, l.mainTextColor) - - // Background color of selected text. - if index == l.currentItem && (!l.selectedFocusOnly || l.HasFocus()) { - textWidth := width - if !l.highlightFullLine { - if w := TaggedStringWidth(item.MainText); w < textWidth { - textWidth = w - } - } - - for bx := 0; bx < textWidth; bx++ { - m, c, style, _ := screen.GetContent(x+bx, y) - fg, _, _ := style.Decompose() - if fg == l.mainTextColor { - fg = l.selectedTextColor - } - style = style.Background(l.selectedBackgroundColor).Foreground(fg) - screen.SetContent(x+bx, y, m, c, style) - } - } - - y++ - - if y >= bottomLimit { - break - } - - // Secondary text. - if l.showSecondaryText { - Print(screen, item.SecondaryText, x, y, width, AlignLeft, l.secondaryTextColor) - y++ - } - } -} - -// InputHandler returns the handler for this primitive. -func (l *List) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return l.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - if event.Key() == tcell.KeyEscape { - if l.done != nil { - l.done() - } - return - } else if len(l.items) == 0 { - return - } - - previousItem := l.currentItem - - switch key := event.Key(); key { - case tcell.KeyTab, tcell.KeyDown, tcell.KeyRight: - l.currentItem++ - case tcell.KeyBacktab, tcell.KeyUp, tcell.KeyLeft: - l.currentItem-- - case tcell.KeyHome: - l.currentItem = 0 - case tcell.KeyEnd: - l.currentItem = len(l.items) - 1 - case tcell.KeyPgDn: - _, _, _, height := l.GetInnerRect() - l.currentItem += height - case tcell.KeyPgUp: - _, _, _, height := l.GetInnerRect() - l.currentItem -= height - case tcell.KeyEnter: - if l.currentItem >= 0 && l.currentItem < len(l.items) { - item := l.items[l.currentItem] - if item.Selected != nil { - item.Selected() - } - if l.selected != nil { - l.selected(l.currentItem, item.MainText, item.SecondaryText, item.Shortcut) - } - } - case tcell.KeyRune: - ch := event.Rune() - if ch != ' ' { - // It's not a space bar. Is it a shortcut? - var found bool - for index, item := range l.items { - if item.Shortcut == ch { - // We have a shortcut. - found = true - l.currentItem = index - break - } - } - if !found { - break - } - } - item := l.items[l.currentItem] - if item.Selected != nil { - item.Selected() - } - if l.selected != nil { - l.selected(l.currentItem, item.MainText, item.SecondaryText, item.Shortcut) - } - } - - if l.currentItem < 0 { - if l.wrapAround { - l.currentItem = len(l.items) - 1 - } else { - l.currentItem = 0 - } - } else if l.currentItem >= len(l.items) { - if l.wrapAround { - l.currentItem = 0 - } else { - l.currentItem = len(l.items) - 1 - } - } - - if l.currentItem != previousItem && l.currentItem < len(l.items) && l.changed != nil { - item := l.items[l.currentItem] - l.changed(l.currentItem, item.MainText, item.SecondaryText, item.Shortcut) - } - }) -} - -// indexAtPoint returns the index of the list item found at the given position -// or a negative value if there is no such list item. -func (l *List) indexAtPoint(x, y int) int { - rectX, rectY, width, height := l.GetInnerRect() - if rectX < 0 || rectX >= rectX+width || y < rectY || y >= rectY+height { - return -1 - } - - index := y - rectY - if l.showSecondaryText { - index /= 2 - } - index += l.offset - - if index >= len(l.items) { - return -1 - } - return index -} - -// MouseHandler returns the mouse handler for this primitive. -func (l *List) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return l.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if !l.InRect(event.Position()) { - return false, nil - } - - // Process mouse event. - switch action { - case MouseLeftClick: - setFocus(l) - index := l.indexAtPoint(event.Position()) - if index != -1 { - item := l.items[index] - if item.Selected != nil { - item.Selected() - } - if l.selected != nil { - l.selected(index, item.MainText, item.SecondaryText, item.Shortcut) - } - if index != l.currentItem && l.changed != nil { - l.changed(index, item.MainText, item.SecondaryText, item.Shortcut) - } - l.currentItem = index - } - consumed = true - case MouseScrollUp: - if l.offset > 0 { - l.offset-- - } - consumed = true - case MouseScrollDown: - lines := len(l.items) - l.offset - if l.showSecondaryText { - lines *= 2 - } - if _, _, _, height := l.GetInnerRect(); lines > height { - l.offset++ - } - consumed = true - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/modal.go b/vendor/github.com/rivo/tview/modal.go deleted file mode 100644 index 4e9aa5c..0000000 --- a/vendor/github.com/rivo/tview/modal.go +++ /dev/null @@ -1,201 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// Modal is a centered message window used to inform the user or prompt them -// for an immediate decision. It needs to have at least one button (added via -// AddButtons()) or it will never disappear. -// -// See https://github.com/rivo/tview/wiki/Modal for an example. -type Modal struct { - *Box - - // The frame embedded in the modal. - frame *Frame - - // The form embedded in the modal's frame. - form *Form - - // The message text (original, not word-wrapped). - text string - - // The text color. - textColor tcell.Color - - // The optional callback for when the user clicked one of the buttons. It - // receives the index of the clicked button and the button's label. - done func(buttonIndex int, buttonLabel string) -} - -// NewModal returns a new modal message window. -func NewModal() *Modal { - m := &Modal{ - Box: NewBox(), - textColor: Styles.PrimaryTextColor, - } - m.form = NewForm(). - SetButtonsAlign(AlignCenter). - SetButtonBackgroundColor(Styles.PrimitiveBackgroundColor). - SetButtonTextColor(Styles.PrimaryTextColor) - m.form.SetBackgroundColor(Styles.ContrastBackgroundColor).SetBorderPadding(0, 0, 0, 0) - m.form.SetCancelFunc(func() { - if m.done != nil { - m.done(-1, "") - } - }) - m.frame = NewFrame(m.form).SetBorders(0, 0, 1, 0, 0, 0) - m.frame.SetBorder(true). - SetBackgroundColor(Styles.ContrastBackgroundColor). - SetBorderPadding(1, 1, 1, 1) - return m -} - -// SetBackgroundColor sets the color of the modal frame background. -func (m *Modal) SetBackgroundColor(color tcell.Color) *Modal { - m.form.SetBackgroundColor(color) - m.frame.SetBackgroundColor(color) - return m -} - -// SetTextColor sets the color of the message text. -func (m *Modal) SetTextColor(color tcell.Color) *Modal { - m.textColor = color - return m -} - -// SetButtonBackgroundColor sets the background color of the buttons. -func (m *Modal) SetButtonBackgroundColor(color tcell.Color) *Modal { - m.form.SetButtonBackgroundColor(color) - return m -} - -// SetButtonTextColor sets the color of the button texts. -func (m *Modal) SetButtonTextColor(color tcell.Color) *Modal { - m.form.SetButtonTextColor(color) - return m -} - -// SetDoneFunc sets a handler which is called when one of the buttons was -// pressed. It receives the index of the button as well as its label text. The -// handler is also called when the user presses the Escape key. The index will -// then be negative and the label text an emptry string. -func (m *Modal) SetDoneFunc(handler func(buttonIndex int, buttonLabel string)) *Modal { - m.done = handler - return m -} - -// SetText sets the message text of the window. The text may contain line -// breaks. Note that words are wrapped, too, based on the final size of the -// window. -func (m *Modal) SetText(text string) *Modal { - m.text = text - return m -} - -// AddButtons adds buttons to the window. There must be at least one button and -// a "done" handler so the window can be closed again. -func (m *Modal) AddButtons(labels []string) *Modal { - for index, label := range labels { - func(i int, l string) { - m.form.AddButton(label, func() { - if m.done != nil { - m.done(i, l) - } - }) - button := m.form.GetButton(m.form.GetButtonCount() - 1) - button.SetInputCapture(func(event *tcell.EventKey) *tcell.EventKey { - switch event.Key() { - case tcell.KeyDown, tcell.KeyRight: - return tcell.NewEventKey(tcell.KeyTab, 0, tcell.ModNone) - case tcell.KeyUp, tcell.KeyLeft: - return tcell.NewEventKey(tcell.KeyBacktab, 0, tcell.ModNone) - } - return event - }) - }(index, label) - } - return m -} - -// ClearButtons removes all buttons from the window. -func (m *Modal) ClearButtons() *Modal { - m.form.ClearButtons() - return m -} - -// SetFocus shifts the focus to the button with the given index. -func (m *Modal) SetFocus(index int) *Modal { - m.form.SetFocus(index) - return m -} - -// Focus is called when this primitive receives focus. -func (m *Modal) Focus(delegate func(p Primitive)) { - delegate(m.form) -} - -// HasFocus returns whether or not this primitive has focus. -func (m *Modal) HasFocus() bool { - return m.form.HasFocus() -} - -// Draw draws this primitive onto the screen. -func (m *Modal) Draw(screen tcell.Screen) { - // Calculate the width of this modal. - buttonsWidth := 0 - for _, button := range m.form.buttons { - buttonsWidth += TaggedStringWidth(button.label) + 4 + 2 - } - buttonsWidth -= 2 - screenWidth, screenHeight := screen.Size() - width := screenWidth / 3 - if width < buttonsWidth { - width = buttonsWidth - } - // width is now without the box border. - - // Reset the text and find out how wide it is. - m.frame.Clear() - lines := WordWrap(m.text, width) - for _, line := range lines { - m.frame.AddText(line, true, AlignCenter, m.textColor) - } - - // Set the modal's position and size. - height := len(lines) + 6 - width += 4 - x := (screenWidth - width) / 2 - y := (screenHeight - height) / 2 - m.SetRect(x, y, width, height) - - // Draw the frame. - m.frame.SetRect(x, y, width, height) - m.frame.Draw(screen) -} - -// MouseHandler returns the mouse handler for this primitive. -func (m *Modal) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return m.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - // Pass mouse events on to the form. - consumed, capture = m.form.MouseHandler()(action, event, setFocus) - if !consumed && action == MouseLeftClick && m.InRect(event.Position()) { - setFocus(m) - consumed = true - } - return - }) -} - -// InputHandler returns the handler for this primitive. -func (m *Modal) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return m.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - if m.frame.HasFocus() { - if handler := m.frame.InputHandler(); handler != nil { - handler(event, setFocus) - return - } - } - }) -} diff --git a/vendor/github.com/rivo/tview/pages.go b/vendor/github.com/rivo/tview/pages.go deleted file mode 100644 index 9dca792..0000000 --- a/vendor/github.com/rivo/tview/pages.go +++ /dev/null @@ -1,315 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// page represents one page of a Pages object. -type page struct { - Name string // The page's name. - Item Primitive // The page's primitive. - Resize bool // Whether or not to resize the page when it is drawn. - Visible bool // Whether or not this page is visible. -} - -// Pages is a container for other primitives often used as the application's -// root primitive. It allows to easily switch the visibility of the contained -// primitives. -// -// See https://github.com/rivo/tview/wiki/Pages for an example. -type Pages struct { - *Box - - // The contained pages. (Visible) pages are drawn from back to front. - pages []*page - - // We keep a reference to the function which allows us to set the focus to - // a newly visible page. - setFocus func(p Primitive) - - // An optional handler which is called whenever the visibility or the order of - // pages changes. - changed func() -} - -// NewPages returns a new Pages object. -func NewPages() *Pages { - p := &Pages{ - Box: NewBox(), - } - return p -} - -// SetChangedFunc sets a handler which is called whenever the visibility or the -// order of any visible pages changes. This can be used to redraw the pages. -func (p *Pages) SetChangedFunc(handler func()) *Pages { - p.changed = handler - return p -} - -// GetPageCount returns the number of pages currently stored in this object. -func (p *Pages) GetPageCount() int { - return len(p.pages) -} - -// AddPage adds a new page with the given name and primitive. If there was -// previously a page with the same name, it is overwritten. Leaving the name -// empty may cause conflicts in other functions so always specify a non-empty -// name. -// -// Visible pages will be drawn in the order they were added (unless that order -// was changed in one of the other functions). If "resize" is set to true, the -// primitive will be set to the size available to the Pages primitive whenever -// the pages are drawn. -func (p *Pages) AddPage(name string, item Primitive, resize, visible bool) *Pages { - hasFocus := p.HasFocus() - for index, pg := range p.pages { - if pg.Name == name { - p.pages = append(p.pages[:index], p.pages[index+1:]...) - break - } - } - p.pages = append(p.pages, &page{Item: item, Name: name, Resize: resize, Visible: visible}) - if p.changed != nil { - p.changed() - } - if hasFocus { - p.Focus(p.setFocus) - } - return p -} - -// AddAndSwitchToPage calls AddPage(), then SwitchToPage() on that newly added -// page. -func (p *Pages) AddAndSwitchToPage(name string, item Primitive, resize bool) *Pages { - p.AddPage(name, item, resize, true) - p.SwitchToPage(name) - return p -} - -// RemovePage removes the page with the given name. If that page was the only -// visible page, visibility is assigned to the last page. -func (p *Pages) RemovePage(name string) *Pages { - var isVisible bool - hasFocus := p.HasFocus() - for index, page := range p.pages { - if page.Name == name { - isVisible = page.Visible - p.pages = append(p.pages[:index], p.pages[index+1:]...) - if page.Visible && p.changed != nil { - p.changed() - } - break - } - } - if isVisible { - for index, page := range p.pages { - if index < len(p.pages)-1 { - if page.Visible { - break // There is a remaining visible page. - } - } else { - page.Visible = true // We need at least one visible page. - } - } - } - if hasFocus { - p.Focus(p.setFocus) - } - return p -} - -// HasPage returns true if a page with the given name exists in this object. -func (p *Pages) HasPage(name string) bool { - for _, page := range p.pages { - if page.Name == name { - return true - } - } - return false -} - -// ShowPage sets a page's visibility to "true" (in addition to any other pages -// which are already visible). -func (p *Pages) ShowPage(name string) *Pages { - for _, page := range p.pages { - if page.Name == name { - page.Visible = true - if p.changed != nil { - p.changed() - } - break - } - } - if p.HasFocus() { - p.Focus(p.setFocus) - } - return p -} - -// HidePage sets a page's visibility to "false". -func (p *Pages) HidePage(name string) *Pages { - for _, page := range p.pages { - if page.Name == name { - page.Visible = false - if p.changed != nil { - p.changed() - } - break - } - } - if p.HasFocus() { - p.Focus(p.setFocus) - } - return p -} - -// SwitchToPage sets a page's visibility to "true" and all other pages' -// visibility to "false". -func (p *Pages) SwitchToPage(name string) *Pages { - for _, page := range p.pages { - if page.Name == name { - page.Visible = true - } else { - page.Visible = false - } - } - if p.changed != nil { - p.changed() - } - if p.HasFocus() { - p.Focus(p.setFocus) - } - return p -} - -// SendToFront changes the order of the pages such that the page with the given -// name comes last, causing it to be drawn last with the next update (if -// visible). -func (p *Pages) SendToFront(name string) *Pages { - for index, page := range p.pages { - if page.Name == name { - if index < len(p.pages)-1 { - p.pages = append(append(p.pages[:index], p.pages[index+1:]...), page) - } - if page.Visible && p.changed != nil { - p.changed() - } - break - } - } - if p.HasFocus() { - p.Focus(p.setFocus) - } - return p -} - -// SendToBack changes the order of the pages such that the page with the given -// name comes first, causing it to be drawn first with the next update (if -// visible). -func (p *Pages) SendToBack(name string) *Pages { - for index, pg := range p.pages { - if pg.Name == name { - if index > 0 { - p.pages = append(append([]*page{pg}, p.pages[:index]...), p.pages[index+1:]...) - } - if pg.Visible && p.changed != nil { - p.changed() - } - break - } - } - if p.HasFocus() { - p.Focus(p.setFocus) - } - return p -} - -// GetFrontPage returns the front-most visible page. If there are no visible -// pages, ("", nil) is returned. -func (p *Pages) GetFrontPage() (name string, item Primitive) { - for index := len(p.pages) - 1; index >= 0; index-- { - if p.pages[index].Visible { - return p.pages[index].Name, p.pages[index].Item - } - } - return -} - -// HasFocus returns whether or not this primitive has focus. -func (p *Pages) HasFocus() bool { - for _, page := range p.pages { - if page.Item.HasFocus() { - return true - } - } - return false -} - -// Focus is called by the application when the primitive receives focus. -func (p *Pages) Focus(delegate func(p Primitive)) { - if delegate == nil { - return // We cannot delegate so we cannot focus. - } - p.setFocus = delegate - var topItem Primitive - for _, page := range p.pages { - if page.Visible { - topItem = page.Item - } - } - if topItem != nil { - delegate(topItem) - } -} - -// Draw draws this primitive onto the screen. -func (p *Pages) Draw(screen tcell.Screen) { - p.Box.DrawForSubclass(screen, p) - for _, page := range p.pages { - if !page.Visible { - continue - } - if page.Resize { - x, y, width, height := p.GetInnerRect() - page.Item.SetRect(x, y, width, height) - } - page.Item.Draw(screen) - } -} - -// MouseHandler returns the mouse handler for this primitive. -func (p *Pages) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return p.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - if !p.InRect(event.Position()) { - return false, nil - } - - // Pass mouse events along to the last visible page item that takes it. - for index := len(p.pages) - 1; index >= 0; index-- { - page := p.pages[index] - if page.Visible { - consumed, capture = page.Item.MouseHandler()(action, event, setFocus) - if consumed { - return - } - } - } - - return - }) -} - -// InputHandler returns the handler for this primitive. -func (p *Pages) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return p.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - for _, page := range p.pages { - if page.Item.HasFocus() { - if handler := page.Item.InputHandler(); handler != nil { - handler(event, setFocus) - return - } - } - } - }) -} diff --git a/vendor/github.com/rivo/tview/primitive.go b/vendor/github.com/rivo/tview/primitive.go deleted file mode 100644 index 71a4ce9..0000000 --- a/vendor/github.com/rivo/tview/primitive.go +++ /dev/null @@ -1,58 +0,0 @@ -package tview - -import "github.com/gdamore/tcell/v2" - -// Primitive is the top-most interface for all graphical primitives. -type Primitive interface { - // Draw draws this primitive onto the screen. Implementers can call the - // screen's ShowCursor() function but should only do so when they have focus. - // (They will need to keep track of this themselves.) - Draw(screen tcell.Screen) - - // GetRect returns the current position of the primitive, x, y, width, and - // height. - GetRect() (int, int, int, int) - - // SetRect sets a new position of the primitive. - SetRect(x, y, width, height int) - - // InputHandler returns a handler which receives key events when it has focus. - // It is called by the Application class. - // - // A value of nil may also be returned, in which case this primitive cannot - // receive focus and will not process any key events. - // - // The handler will receive the key event and a function that allows it to - // set the focus to a different primitive, so that future key events are sent - // to that primitive. - // - // The Application's Draw() function will be called automatically after the - // handler returns. - // - // The Box class provides functionality to intercept keyboard input. If you - // subclass from Box, it is recommended that you wrap your handler using - // Box.WrapInputHandler() so you inherit that functionality. - InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) - - // Focus is called by the application when the primitive receives focus. - // Implementers may call delegate() to pass the focus on to another primitive. - Focus(delegate func(p Primitive)) - - // HasFocus determines if the primitive has focus. This function must return - // true also if one of this primitive's child elements has focus. - HasFocus() bool - - // Blur is called by the application when the primitive loses focus. - Blur() - - // MouseHandler returns a handler which receives mouse events. - // It is called by the Application class. - // - // A value of nil may also be returned to stop the downward propagation of - // mouse events. - // - // The Box class provides functionality to intercept mouse events. If you - // subclass from Box, it is recommended that you wrap your handler using - // Box.WrapMouseHandler() so you inherit that functionality. - MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) -} diff --git a/vendor/github.com/rivo/tview/semigraphics.go b/vendor/github.com/rivo/tview/semigraphics.go deleted file mode 100644 index 1815bfa..0000000 --- a/vendor/github.com/rivo/tview/semigraphics.go +++ /dev/null @@ -1,296 +0,0 @@ -package tview - -import "github.com/gdamore/tcell/v2" - -// Semigraphics provides an easy way to access unicode characters for drawing. -// -// Named like the unicode characters, 'Semigraphics'-prefix used if unicode block -// isn't prefixed itself. -const ( - // Block: General Punctation U+2000-U+206F (http://unicode.org/charts/PDF/U2000.pdf) - SemigraphicsHorizontalEllipsis rune = '\u2026' // … - - // Block: Box Drawing U+2500-U+257F (http://unicode.org/charts/PDF/U2500.pdf) - BoxDrawingsLightHorizontal rune = '\u2500' // ─ - BoxDrawingsHeavyHorizontal rune = '\u2501' // ━ - BoxDrawingsLightVertical rune = '\u2502' // │ - BoxDrawingsHeavyVertical rune = '\u2503' // ┃ - BoxDrawingsLightTripleDashHorizontal rune = '\u2504' // ┄ - BoxDrawingsHeavyTripleDashHorizontal rune = '\u2505' // ┅ - BoxDrawingsLightTripleDashVertical rune = '\u2506' // ┆ - BoxDrawingsHeavyTripleDashVertical rune = '\u2507' // ┇ - BoxDrawingsLightQuadrupleDashHorizontal rune = '\u2508' // ┈ - BoxDrawingsHeavyQuadrupleDashHorizontal rune = '\u2509' // ┉ - BoxDrawingsLightQuadrupleDashVertical rune = '\u250a' // ┊ - BoxDrawingsHeavyQuadrupleDashVertical rune = '\u250b' // ┋ - BoxDrawingsLightDownAndRight rune = '\u250c' // ┌ - BoxDrawingsDownLighAndRightHeavy rune = '\u250d' // ┍ - BoxDrawingsDownHeavyAndRightLight rune = '\u250e' // ┎ - BoxDrawingsHeavyDownAndRight rune = '\u250f' // ┏ - BoxDrawingsLightDownAndLeft rune = '\u2510' // ┐ - BoxDrawingsDownLighAndLeftHeavy rune = '\u2511' // ┑ - BoxDrawingsDownHeavyAndLeftLight rune = '\u2512' // ┒ - BoxDrawingsHeavyDownAndLeft rune = '\u2513' // ┓ - BoxDrawingsLightUpAndRight rune = '\u2514' // └ - BoxDrawingsUpLightAndRightHeavy rune = '\u2515' // ┕ - BoxDrawingsUpHeavyAndRightLight rune = '\u2516' // ┖ - BoxDrawingsHeavyUpAndRight rune = '\u2517' // ┗ - BoxDrawingsLightUpAndLeft rune = '\u2518' // ┘ - BoxDrawingsUpLightAndLeftHeavy rune = '\u2519' // ┙ - BoxDrawingsUpHeavyAndLeftLight rune = '\u251a' // ┚ - BoxDrawingsHeavyUpAndLeft rune = '\u251b' // ┛ - BoxDrawingsLightVerticalAndRight rune = '\u251c' // ├ - BoxDrawingsVerticalLightAndRightHeavy rune = '\u251d' // ┝ - BoxDrawingsUpHeavyAndRightDownLight rune = '\u251e' // ┞ - BoxDrawingsDownHeacyAndRightUpLight rune = '\u251f' // ┟ - BoxDrawingsVerticalHeavyAndRightLight rune = '\u2520' // ┠ - BoxDrawingsDownLightAnbdRightUpHeavy rune = '\u2521' // ┡ - BoxDrawingsUpLightAndRightDownHeavy rune = '\u2522' // ┢ - BoxDrawingsHeavyVerticalAndRight rune = '\u2523' // ┣ - BoxDrawingsLightVerticalAndLeft rune = '\u2524' // ┤ - BoxDrawingsVerticalLightAndLeftHeavy rune = '\u2525' // ┥ - BoxDrawingsUpHeavyAndLeftDownLight rune = '\u2526' // ┦ - BoxDrawingsDownHeavyAndLeftUpLight rune = '\u2527' // ┧ - BoxDrawingsVerticalheavyAndLeftLight rune = '\u2528' // ┨ - BoxDrawingsDownLightAndLeftUpHeavy rune = '\u2529' // ┨ - BoxDrawingsUpLightAndLeftDownHeavy rune = '\u252a' // ┪ - BoxDrawingsHeavyVerticalAndLeft rune = '\u252b' // ┫ - BoxDrawingsLightDownAndHorizontal rune = '\u252c' // ┬ - BoxDrawingsLeftHeavyAndRightDownLight rune = '\u252d' // ┭ - BoxDrawingsRightHeavyAndLeftDownLight rune = '\u252e' // ┮ - BoxDrawingsDownLightAndHorizontalHeavy rune = '\u252f' // ┯ - BoxDrawingsDownHeavyAndHorizontalLight rune = '\u2530' // ┰ - BoxDrawingsRightLightAndLeftDownHeavy rune = '\u2531' // ┱ - BoxDrawingsLeftLightAndRightDownHeavy rune = '\u2532' // ┲ - BoxDrawingsHeavyDownAndHorizontal rune = '\u2533' // ┳ - BoxDrawingsLightUpAndHorizontal rune = '\u2534' // ┴ - BoxDrawingsLeftHeavyAndRightUpLight rune = '\u2535' // ┵ - BoxDrawingsRightHeavyAndLeftUpLight rune = '\u2536' // ┶ - BoxDrawingsUpLightAndHorizontalHeavy rune = '\u2537' // ┷ - BoxDrawingsUpHeavyAndHorizontalLight rune = '\u2538' // ┸ - BoxDrawingsRightLightAndLeftUpHeavy rune = '\u2539' // ┹ - BoxDrawingsLeftLightAndRightUpHeavy rune = '\u253a' // ┺ - BoxDrawingsHeavyUpAndHorizontal rune = '\u253b' // ┻ - BoxDrawingsLightVerticalAndHorizontal rune = '\u253c' // ┼ - BoxDrawingsLeftHeavyAndRightVerticalLight rune = '\u253d' // ┽ - BoxDrawingsRightHeavyAndLeftVerticalLight rune = '\u253e' // ┾ - BoxDrawingsVerticalLightAndHorizontalHeavy rune = '\u253f' // ┿ - BoxDrawingsUpHeavyAndDownHorizontalLight rune = '\u2540' // ╀ - BoxDrawingsDownHeavyAndUpHorizontalLight rune = '\u2541' // ╁ - BoxDrawingsVerticalHeavyAndHorizontalLight rune = '\u2542' // ╂ - BoxDrawingsLeftUpHeavyAndRightDownLight rune = '\u2543' // ╃ - BoxDrawingsRightUpHeavyAndLeftDownLight rune = '\u2544' // ╄ - BoxDrawingsLeftDownHeavyAndRightUpLight rune = '\u2545' // ╅ - BoxDrawingsRightDownHeavyAndLeftUpLight rune = '\u2546' // ╆ - BoxDrawingsDownLightAndUpHorizontalHeavy rune = '\u2547' // ╇ - BoxDrawingsUpLightAndDownHorizontalHeavy rune = '\u2548' // ╈ - BoxDrawingsRightLightAndLeftVerticalHeavy rune = '\u2549' // ╉ - BoxDrawingsLeftLightAndRightVerticalHeavy rune = '\u254a' // ╊ - BoxDrawingsHeavyVerticalAndHorizontal rune = '\u254b' // ╋ - BoxDrawingsLightDoubleDashHorizontal rune = '\u254c' // ╌ - BoxDrawingsHeavyDoubleDashHorizontal rune = '\u254d' // ╍ - BoxDrawingsLightDoubleDashVertical rune = '\u254e' // ╎ - BoxDrawingsHeavyDoubleDashVertical rune = '\u254f' // ╏ - BoxDrawingsDoubleHorizontal rune = '\u2550' // ═ - BoxDrawingsDoubleVertical rune = '\u2551' // ║ - BoxDrawingsDownSingleAndRightDouble rune = '\u2552' // ╒ - BoxDrawingsDownDoubleAndRightSingle rune = '\u2553' // ╓ - BoxDrawingsDoubleDownAndRight rune = '\u2554' // ╔ - BoxDrawingsDownSingleAndLeftDouble rune = '\u2555' // ╕ - BoxDrawingsDownDoubleAndLeftSingle rune = '\u2556' // ╖ - BoxDrawingsDoubleDownAndLeft rune = '\u2557' // ╗ - BoxDrawingsUpSingleAndRightDouble rune = '\u2558' // ╘ - BoxDrawingsUpDoubleAndRightSingle rune = '\u2559' // ╙ - BoxDrawingsDoubleUpAndRight rune = '\u255a' // ╚ - BoxDrawingsUpSingleAndLeftDouble rune = '\u255b' // ╛ - BoxDrawingsUpDobuleAndLeftSingle rune = '\u255c' // ╜ - BoxDrawingsDoubleUpAndLeft rune = '\u255d' // ╝ - BoxDrawingsVerticalSingleAndRightDouble rune = '\u255e' // ╞ - BoxDrawingsVerticalDoubleAndRightSingle rune = '\u255f' // ╟ - BoxDrawingsDoubleVerticalAndRight rune = '\u2560' // ╠ - BoxDrawingsVerticalSingleAndLeftDouble rune = '\u2561' // ╡ - BoxDrawingsVerticalDoubleAndLeftSingle rune = '\u2562' // ╢ - BoxDrawingsDoubleVerticalAndLeft rune = '\u2563' // ╣ - BoxDrawingsDownSingleAndHorizontalDouble rune = '\u2564' // ╤ - BoxDrawingsDownDoubleAndHorizontalSingle rune = '\u2565' // ╥ - BoxDrawingsDoubleDownAndHorizontal rune = '\u2566' // ╦ - BoxDrawingsUpSingleAndHorizontalDouble rune = '\u2567' // ╧ - BoxDrawingsUpDoubleAndHorizontalSingle rune = '\u2568' // ╨ - BoxDrawingsDoubleUpAndHorizontal rune = '\u2569' // ╩ - BoxDrawingsVerticalSingleAndHorizontalDouble rune = '\u256a' // ╪ - BoxDrawingsVerticalDoubleAndHorizontalSingle rune = '\u256b' // ╫ - BoxDrawingsDoubleVerticalAndHorizontal rune = '\u256c' // ╬ - BoxDrawingsLightArcDownAndRight rune = '\u256d' // ╭ - BoxDrawingsLightArcDownAndLeft rune = '\u256e' // ╮ - BoxDrawingsLightArcUpAndLeft rune = '\u256f' // ╯ - BoxDrawingsLightArcUpAndRight rune = '\u2570' // ╰ - BoxDrawingsLightDiagonalUpperRightToLowerLeft rune = '\u2571' // ╱ - BoxDrawingsLightDiagonalUpperLeftToLowerRight rune = '\u2572' // ╲ - BoxDrawingsLightDiagonalCross rune = '\u2573' // ╳ - BoxDrawingsLightLeft rune = '\u2574' // ╴ - BoxDrawingsLightUp rune = '\u2575' // ╵ - BoxDrawingsLightRight rune = '\u2576' // ╶ - BoxDrawingsLightDown rune = '\u2577' // ╷ - BoxDrawingsHeavyLeft rune = '\u2578' // ╸ - BoxDrawingsHeavyUp rune = '\u2579' // ╹ - BoxDrawingsHeavyRight rune = '\u257a' // ╺ - BoxDrawingsHeavyDown rune = '\u257b' // ╻ - BoxDrawingsLightLeftAndHeavyRight rune = '\u257c' // ╼ - BoxDrawingsLightUpAndHeavyDown rune = '\u257d' // ╽ - BoxDrawingsHeavyLeftAndLightRight rune = '\u257e' // ╾ - BoxDrawingsHeavyUpAndLightDown rune = '\u257f' // ╿ -) - -// SemigraphicJoints is a map for joining semigraphic (or otherwise) runes. -// So far only light lines are supported but if you want to change the border -// styling you need to provide the joints, too. -// The matching will be sorted ascending by rune value, so you don't need to -// provide all rune combinations, -// e.g. (─) + (│) = (┼) will also match (│) + (─) = (┼) -var SemigraphicJoints = map[string]rune{ - // (─) + (│) = (┼) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightVertical}): BoxDrawingsLightVerticalAndHorizontal, - // (─) + (┌) = (┬) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightDownAndRight}): BoxDrawingsLightDownAndHorizontal, - // (─) + (┐) = (┬) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightDownAndLeft}): BoxDrawingsLightDownAndHorizontal, - // (─) + (└) = (┴) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightUpAndRight}): BoxDrawingsLightUpAndHorizontal, - // (─) + (┘) = (┴) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightUpAndLeft}): BoxDrawingsLightUpAndHorizontal, - // (─) + (├) = (┼) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightVerticalAndRight}): BoxDrawingsLightVerticalAndHorizontal, - // (─) + (┤) = (┼) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightVerticalAndLeft}): BoxDrawingsLightVerticalAndHorizontal, - // (─) + (┬) = (┬) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightDownAndHorizontal, - // (─) + (┴) = (┴) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightUpAndHorizontal, - // (─) + (┼) = (┼) - string([]rune{BoxDrawingsLightHorizontal, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (│) + (┌) = (├) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightDownAndRight}): BoxDrawingsLightVerticalAndRight, - // (│) + (┐) = (┤) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightDownAndLeft}): BoxDrawingsLightVerticalAndLeft, - // (│) + (└) = (├) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightUpAndRight}): BoxDrawingsLightVerticalAndRight, - // (│) + (┘) = (┤) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightUpAndLeft}): BoxDrawingsLightVerticalAndLeft, - // (│) + (├) = (├) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightVerticalAndRight}): BoxDrawingsLightVerticalAndRight, - // (│) + (┤) = (┤) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightVerticalAndLeft}): BoxDrawingsLightVerticalAndLeft, - // (│) + (┬) = (┼) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (│) + (┴) = (┼) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (│) + (┼) = (┼) - string([]rune{BoxDrawingsLightVertical, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (┌) + (┐) = (┬) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightDownAndLeft}): BoxDrawingsLightDownAndHorizontal, - // (┌) + (└) = (├) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightUpAndRight}): BoxDrawingsLightVerticalAndRight, - // (┌) + (┘) = (┼) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightUpAndLeft}): BoxDrawingsLightVerticalAndHorizontal, - // (┌) + (├) = (├) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightVerticalAndRight}): BoxDrawingsLightVerticalAndRight, - // (┌) + (┤) = (┼) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightVerticalAndLeft}): BoxDrawingsLightVerticalAndHorizontal, - // (┌) + (┬) = (┬) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightDownAndHorizontal, - // (┌) + (┴) = (┼) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (┌) + (┴) = (┼) - string([]rune{BoxDrawingsLightDownAndRight, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (┐) + (└) = (┼) - string([]rune{BoxDrawingsLightDownAndLeft, BoxDrawingsLightUpAndRight}): BoxDrawingsLightVerticalAndHorizontal, - // (┐) + (┘) = (┤) - string([]rune{BoxDrawingsLightDownAndLeft, BoxDrawingsLightUpAndLeft}): BoxDrawingsLightVerticalAndLeft, - // (┐) + (├) = (┼) - string([]rune{BoxDrawingsLightDownAndLeft, BoxDrawingsLightVerticalAndRight}): BoxDrawingsLightVerticalAndHorizontal, - // (┐) + (┤) = (┤) - string([]rune{BoxDrawingsLightDownAndLeft, BoxDrawingsLightVerticalAndLeft}): BoxDrawingsLightVerticalAndLeft, - // (┐) + (┬) = (┬) - string([]rune{BoxDrawingsLightDownAndLeft, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightDownAndHorizontal, - // (┐) + (┴) = (┼) - string([]rune{BoxDrawingsLightDownAndLeft, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (┐) + (┼) = (┼) - string([]rune{BoxDrawingsLightDownAndLeft, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (└) + (┘) = (┴) - string([]rune{BoxDrawingsLightUpAndRight, BoxDrawingsLightUpAndLeft}): BoxDrawingsLightUpAndHorizontal, - // (└) + (├) = (├) - string([]rune{BoxDrawingsLightUpAndRight, BoxDrawingsLightVerticalAndRight}): BoxDrawingsLightVerticalAndRight, - // (└) + (┤) = (┼) - string([]rune{BoxDrawingsLightUpAndRight, BoxDrawingsLightVerticalAndLeft}): BoxDrawingsLightVerticalAndHorizontal, - // (└) + (┬) = (┼) - string([]rune{BoxDrawingsLightUpAndRight, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (└) + (┴) = (┴) - string([]rune{BoxDrawingsLightUpAndRight, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightUpAndHorizontal, - // (└) + (┼) = (┼) - string([]rune{BoxDrawingsLightUpAndRight, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (┘) + (├) = (┼) - string([]rune{BoxDrawingsLightUpAndLeft, BoxDrawingsLightVerticalAndRight}): BoxDrawingsLightVerticalAndHorizontal, - // (┘) + (┤) = (┤) - string([]rune{BoxDrawingsLightUpAndLeft, BoxDrawingsLightVerticalAndLeft}): BoxDrawingsLightVerticalAndLeft, - // (┘) + (┬) = (┼) - string([]rune{BoxDrawingsLightUpAndLeft, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (┘) + (┴) = (┴) - string([]rune{BoxDrawingsLightUpAndLeft, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightUpAndHorizontal, - // (┘) + (┼) = (┼) - string([]rune{BoxDrawingsLightUpAndLeft, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (├) + (┤) = (┼) - string([]rune{BoxDrawingsLightVerticalAndRight, BoxDrawingsLightVerticalAndLeft}): BoxDrawingsLightVerticalAndHorizontal, - // (├) + (┬) = (┼) - string([]rune{BoxDrawingsLightVerticalAndRight, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (├) + (┴) = (┼) - string([]rune{BoxDrawingsLightVerticalAndRight, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (├) + (┼) = (┼) - string([]rune{BoxDrawingsLightVerticalAndRight, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (┤) + (┬) = (┼) - string([]rune{BoxDrawingsLightVerticalAndLeft, BoxDrawingsLightDownAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (┤) + (┴) = (┼) - string([]rune{BoxDrawingsLightVerticalAndLeft, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (┤) + (┼) = (┼) - string([]rune{BoxDrawingsLightVerticalAndLeft, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (┬) + (┴) = (┼) - string([]rune{BoxDrawingsLightDownAndHorizontal, BoxDrawingsLightUpAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - // (┬) + (┼) = (┼) - string([]rune{BoxDrawingsLightDownAndHorizontal, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, - - // (┴) + (┼) = (┼) - string([]rune{BoxDrawingsLightUpAndHorizontal, BoxDrawingsLightVerticalAndHorizontal}): BoxDrawingsLightVerticalAndHorizontal, -} - -// PrintJoinedSemigraphics prints a semigraphics rune into the screen at the given -// position with the given color, joining it with any existing semigraphics -// rune. Background colors are preserved. At this point, only regular single -// line borders are supported. -func PrintJoinedSemigraphics(screen tcell.Screen, x, y int, ch rune, color tcell.Color) { - previous, _, style, _ := screen.GetContent(x, y) - style = style.Foreground(color) - - // What's the resulting rune? - var result rune - if ch == previous { - result = ch - } else { - if ch < previous { - previous, ch = ch, previous - } - result = SemigraphicJoints[string([]rune{previous, ch})] - } - if result == 0 { - result = ch - } - - // We only print something if we have something. - screen.SetContent(x, y, result, nil, style) -} diff --git a/vendor/github.com/rivo/tview/styles.go b/vendor/github.com/rivo/tview/styles.go deleted file mode 100644 index 16f1fef..0000000 --- a/vendor/github.com/rivo/tview/styles.go +++ /dev/null @@ -1,35 +0,0 @@ -package tview - -import "github.com/gdamore/tcell/v2" - -// Theme defines the colors used when primitives are initialized. -type Theme struct { - PrimitiveBackgroundColor tcell.Color // Main background color for primitives. - ContrastBackgroundColor tcell.Color // Background color for contrasting elements. - MoreContrastBackgroundColor tcell.Color // Background color for even more contrasting elements. - BorderColor tcell.Color // Box borders. - TitleColor tcell.Color // Box titles. - GraphicsColor tcell.Color // Graphics. - PrimaryTextColor tcell.Color // Primary text. - SecondaryTextColor tcell.Color // Secondary text (e.g. labels). - TertiaryTextColor tcell.Color // Tertiary text (e.g. subtitles, notes). - InverseTextColor tcell.Color // Text on primary-colored backgrounds. - ContrastSecondaryTextColor tcell.Color // Secondary text on ContrastBackgroundColor-colored backgrounds. -} - -// Styles defines the theme for applications. The default is for a black -// background and some basic colors: black, white, yellow, green, cyan, and -// blue. -var Styles = Theme{ - PrimitiveBackgroundColor: tcell.ColorBlack, - ContrastBackgroundColor: tcell.ColorBlue, - MoreContrastBackgroundColor: tcell.ColorGreen, - BorderColor: tcell.ColorWhite, - TitleColor: tcell.ColorWhite, - GraphicsColor: tcell.ColorWhite, - PrimaryTextColor: tcell.ColorWhite, - SecondaryTextColor: tcell.ColorYellow, - TertiaryTextColor: tcell.ColorGreen, - InverseTextColor: tcell.ColorBlue, - ContrastSecondaryTextColor: tcell.ColorDarkCyan, -} diff --git a/vendor/github.com/rivo/tview/table.go b/vendor/github.com/rivo/tview/table.go deleted file mode 100644 index c1c5c4b..0000000 --- a/vendor/github.com/rivo/tview/table.go +++ /dev/null @@ -1,1290 +0,0 @@ -package tview - -import ( - "sort" - - "github.com/gdamore/tcell/v2" - colorful "github.com/lucasb-eyer/go-colorful" -) - -// TableCell represents one cell inside a Table. You can instantiate this type -// directly but all colors (background and text) will be set to their default -// which is black. -type TableCell struct { - // The reference object. - Reference interface{} - - // The text to be displayed in the table cell. - Text string - - // The alignment of the cell text. One of AlignLeft (default), AlignCenter, - // or AlignRight. - Align int - - // The maximum width of the cell in screen space. This is used to give a - // column a maximum width. Any cell text whose screen width exceeds this width - // is cut off. Set to 0 if there is no maximum width. - MaxWidth int - - // If the total table width is less than the available width, this value is - // used to add extra width to a column. See SetExpansion() for details. - Expansion int - - // The color of the cell text. - Color tcell.Color - - // The background color of the cell. - BackgroundColor tcell.Color - - // The style attributes of the cell. - Attributes tcell.AttrMask - - // If set to true, this cell cannot be selected. - NotSelectable bool - - // An optional handler for mouse clicks. This also fires if the cell is not - // selectable. If true is returned, no additional "selected" event is fired - // on selectable cells. - Clicked func() bool - - // The position and width of the cell the last time table was drawn. - x, y, width int -} - -// NewTableCell returns a new table cell with sensible defaults. That is, left -// aligned text with the primary text color (see Styles) and a transparent -// background (using the background of the Table). -func NewTableCell(text string) *TableCell { - return &TableCell{ - Text: text, - Align: AlignLeft, - Color: Styles.PrimaryTextColor, - BackgroundColor: tcell.ColorDefault, - } -} - -// SetText sets the cell's text. -func (c *TableCell) SetText(text string) *TableCell { - c.Text = text - return c -} - -// SetAlign sets the cell's text alignment, one of AlignLeft, AlignCenter, or -// AlignRight. -func (c *TableCell) SetAlign(align int) *TableCell { - c.Align = align - return c -} - -// SetMaxWidth sets maximum width of the cell in screen space. This is used to -// give a column a maximum width. Any cell text whose screen width exceeds this -// width is cut off. Set to 0 if there is no maximum width. -func (c *TableCell) SetMaxWidth(maxWidth int) *TableCell { - c.MaxWidth = maxWidth - return c -} - -// SetExpansion sets the value by which the column of this cell expands if the -// available width for the table is more than the table width (prior to applying -// this expansion value). This is a proportional value. The amount of unused -// horizontal space is divided into widths to be added to each column. How much -// extra width a column receives depends on the expansion value: A value of 0 -// (the default) will not cause the column to increase in width. Other values -// are proportional, e.g. a value of 2 will cause a column to grow by twice -// the amount of a column with a value of 1. -// -// Since this value affects an entire column, the maximum over all visible cells -// in that column is used. -// -// This function panics if a negative value is provided. -func (c *TableCell) SetExpansion(expansion int) *TableCell { - if expansion < 0 { - panic("Table cell expansion values may not be negative") - } - c.Expansion = expansion - return c -} - -// SetTextColor sets the cell's text color. -func (c *TableCell) SetTextColor(color tcell.Color) *TableCell { - c.Color = color - return c -} - -// SetBackgroundColor sets the cell's background color. Set to -// tcell.ColorDefault to use the table's background color. -func (c *TableCell) SetBackgroundColor(color tcell.Color) *TableCell { - c.BackgroundColor = color - return c -} - -// SetAttributes sets the cell's text attributes. You can combine different -// attributes using bitmask operations: -// -// cell.SetAttributes(tcell.AttrUnderline | tcell.AttrBold) -func (c *TableCell) SetAttributes(attr tcell.AttrMask) *TableCell { - c.Attributes = attr - return c -} - -// SetStyle sets the cell's style (foreground color, background color, and -// attributes) all at once. -func (c *TableCell) SetStyle(style tcell.Style) *TableCell { - c.Color, c.BackgroundColor, c.Attributes = style.Decompose() - return c -} - -// SetSelectable sets whether or not this cell can be selected by the user. -func (c *TableCell) SetSelectable(selectable bool) *TableCell { - c.NotSelectable = !selectable - return c -} - -// SetReference allows you to store a reference of any type in this cell. This -// will allow you to establish a mapping between the cell and your -// actual data. -func (c *TableCell) SetReference(reference interface{}) *TableCell { - c.Reference = reference - return c -} - -// GetReference returns this cell's reference object. -func (c *TableCell) GetReference() interface{} { - return c.Reference -} - -// GetLastPosition returns the position of the table cell the last time it was -// drawn on screen. If the cell is not on screen, the return values are -// undefined. -// -// Because the Table class will attempt to keep selected cells on screen, this -// function is most useful in response to a "selected" event (see -// SetSelectedFunc()) or a "selectionChanged" event (see -// SetSelectionChangedFunc()). -func (c *TableCell) GetLastPosition() (x, y, width int) { - return c.x, c.y, c.width -} - -// SetClickedFunc sets a handler which fires when this cell is clicked. This is -// independent of whether the cell is selectable or not. But for selectable -// cells, if the function returns "true", the "selected" event is not fired. -func (c *TableCell) SetClickedFunc(clicked func() bool) *TableCell { - c.Clicked = clicked - return c -} - -// Table visualizes two-dimensional data consisting of rows and columns. Each -// Table cell is defined via SetCell() by the TableCell type. They can be added -// dynamically to the table and changed any time. -// -// The most compact display of a table is without borders. Each row will then -// occupy one row on screen and columns are separated by the rune defined via -// SetSeparator() (a space character by default). -// -// When borders are turned on (via SetBorders()), each table cell is surrounded -// by lines. Therefore one table row will require two rows on screen. -// -// Columns will use as much horizontal space as they need. You can constrain -// their size with the MaxWidth parameter of the TableCell type. -// -// Fixed Columns -// -// You can define fixed rows and rolumns via SetFixed(). They will always stay -// in their place, even when the table is scrolled. Fixed rows are always the -// top rows. Fixed columns are always the leftmost columns. -// -// Selections -// -// You can call SetSelectable() to set columns and/or rows to "selectable". If -// the flag is set only for columns, entire columns can be selected by the user. -// If it is set only for rows, entire rows can be selected. If both flags are -// set, individual cells can be selected. The "selected" handler set via -// SetSelectedFunc() is invoked when the user presses Enter on a selection. -// -// Navigation -// -// If the table extends beyond the available space, it can be navigated with -// key bindings similar to Vim: -// -// - h, left arrow: Move left by one column. -// - l, right arrow: Move right by one column. -// - j, down arrow: Move down by one row. -// - k, up arrow: Move up by one row. -// - g, home: Move to the top. -// - G, end: Move to the bottom. -// - Ctrl-F, page down: Move down by one page. -// - Ctrl-B, page up: Move up by one page. -// -// When there is no selection, this affects the entire table (except for fixed -// rows and columns). When there is a selection, the user moves the selection. -// The class will attempt to keep the selection from moving out of the screen. -// -// Use SetInputCapture() to override or modify keyboard input. -// -// See https://github.com/rivo/tview/wiki/Table for an example. -type Table struct { - *Box - - // Whether or not this table has borders around each cell. - borders bool - - // The color of the borders or the separator. - bordersColor tcell.Color - - // If there are no borders, the column separator. - separator rune - - // The cells of the table. Rows first, then columns. - cells [][]*TableCell - - // The rightmost column in the data set. - lastColumn int - - // If true, when calculating the widths of the columns, all rows are evaluated - // instead of only the visible ones. - evaluateAllRows bool - - // The number of fixed rows / columns. - fixedRows, fixedColumns int - - // Whether or not rows or columns can be selected. If both are set to true, - // cells can be selected. - rowsSelectable, columnsSelectable bool - - // The currently selected row and column. - selectedRow, selectedColumn int - - // The number of rows/columns by which the table is scrolled down/to the - // right. - rowOffset, columnOffset int - - // If set to true, the table's last row will always be visible. - trackEnd bool - - // The number of visible rows the last time the table was drawn. - visibleRows int - - // The indices of the visible columns as of the last time the table was drawn. - visibleColumnIndices []int - - // The net widths of the visible columns as of the last time the table was - // drawn. - visibleColumnWidths []int - - // The style of the selected rows. If this value is the empty struct, - // selected rows are simply inverted. - selectedStyle tcell.Style - - // An optional function which gets called when the user presses Enter on a - // selected cell. If entire rows selected, the column value is undefined. - // Likewise for entire columns. - selected func(row, column int) - - // An optional function which gets called when the user changes the selection. - // If entire rows selected, the column value is undefined. - // Likewise for entire columns. - selectionChanged func(row, column int) - - // An optional function which gets called when the user presses Escape, Tab, - // or Backtab. Also when the user presses Enter if nothing is selectable. - done func(key tcell.Key) -} - -// NewTable returns a new table. -func NewTable() *Table { - return &Table{ - Box: NewBox(), - bordersColor: Styles.GraphicsColor, - separator: ' ', - lastColumn: -1, - } -} - -// Clear removes all table data. -func (t *Table) Clear() *Table { - t.cells = nil - t.lastColumn = -1 - return t -} - -// SetBorders sets whether or not each cell in the table is surrounded by a -// border. -func (t *Table) SetBorders(show bool) *Table { - t.borders = show - return t -} - -// SetBordersColor sets the color of the cell borders. -func (t *Table) SetBordersColor(color tcell.Color) *Table { - t.bordersColor = color - return t -} - -// SetSelectedStyle sets a specific style for selected cells. If no such style -// is set, per default, selected cells are inverted (i.e. their foreground and -// background colors are swapped). -// -// To reset a previous setting to its default, make the following call: -// -// table.SetSelectedStyle(tcell.ColorDefault, tcell.ColorDefault, 0) -func (t *Table) SetSelectedStyle(style tcell.Style) *Table { - t.selectedStyle = style - return t -} - -// SetSeparator sets the character used to fill the space between two -// neighboring cells. This is a space character ' ' per default but you may -// want to set it to Borders.Vertical (or any other rune) if the column -// separation should be more visible. If cell borders are activated, this is -// ignored. -// -// Separators have the same color as borders. -func (t *Table) SetSeparator(separator rune) *Table { - t.separator = separator - return t -} - -// SetFixed sets the number of fixed rows and columns which are always visible -// even when the rest of the cells are scrolled out of view. Rows are always the -// top-most ones. Columns are always the left-most ones. -func (t *Table) SetFixed(rows, columns int) *Table { - t.fixedRows, t.fixedColumns = rows, columns - return t -} - -// SetSelectable sets the flags which determine what can be selected in a table. -// There are three selection modi: -// -// - rows = false, columns = false: Nothing can be selected. -// - rows = true, columns = false: Rows can be selected. -// - rows = false, columns = true: Columns can be selected. -// - rows = true, columns = true: Individual cells can be selected. -func (t *Table) SetSelectable(rows, columns bool) *Table { - t.rowsSelectable, t.columnsSelectable = rows, columns - return t -} - -// GetSelectable returns what can be selected in a table. Refer to -// SetSelectable() for details. -func (t *Table) GetSelectable() (rows, columns bool) { - return t.rowsSelectable, t.columnsSelectable -} - -// GetSelection returns the position of the current selection. -// If entire rows are selected, the column index is undefined. -// Likewise for entire columns. -func (t *Table) GetSelection() (row, column int) { - return t.selectedRow, t.selectedColumn -} - -// Select sets the selected cell. Depending on the selection settings -// specified via SetSelectable(), this may be an entire row or column, or even -// ignored completely. The "selection changed" event is fired if such a callback -// is available (even if the selection ends up being the same as before and even -// if cells are not selectable). -func (t *Table) Select(row, column int) *Table { - t.selectedRow, t.selectedColumn = row, column - if t.selectionChanged != nil { - t.selectionChanged(row, column) - } - return t -} - -// SetOffset sets how many rows and columns should be skipped when drawing the -// table. This is useful for large tables that do not fit on the screen. -// Navigating a selection can change these values. -// -// Fixed rows and columns are never skipped. -func (t *Table) SetOffset(row, column int) *Table { - t.rowOffset, t.columnOffset = row, column - t.trackEnd = false - return t -} - -// GetOffset returns the current row and column offset. This indicates how many -// rows and columns the table is scrolled down and to the right. -func (t *Table) GetOffset() (row, column int) { - return t.rowOffset, t.columnOffset -} - -// SetEvaluateAllRows sets a flag which determines the rows to be evaluated when -// calculating the widths of the table's columns. When false, only visible rows -// are evaluated. When true, all rows in the table are evaluated. -// -// Set this flag to true to avoid shifting column widths when the table is -// scrolled. (May be slower for large tables.) -func (t *Table) SetEvaluateAllRows(all bool) *Table { - t.evaluateAllRows = all - return t -} - -// SetSelectedFunc sets a handler which is called whenever the user presses the -// Enter key on a selected cell/row/column. The handler receives the position of -// the selection and its cell contents. If entire rows are selected, the column -// index is undefined. Likewise for entire columns. -func (t *Table) SetSelectedFunc(handler func(row, column int)) *Table { - t.selected = handler - return t -} - -// SetSelectionChangedFunc sets a handler which is called whenever the current -// selection changes. The handler receives the position of the new selection. -// If entire rows are selected, the column index is undefined. Likewise for -// entire columns. -func (t *Table) SetSelectionChangedFunc(handler func(row, column int)) *Table { - t.selectionChanged = handler - return t -} - -// SetDoneFunc sets a handler which is called whenever the user presses the -// Escape, Tab, or Backtab key. If nothing is selected, it is also called when -// user presses the Enter key (because pressing Enter on a selection triggers -// the "selected" handler set via SetSelectedFunc()). -func (t *Table) SetDoneFunc(handler func(key tcell.Key)) *Table { - t.done = handler - return t -} - -// SetCell sets the content of a cell the specified position. It is ok to -// directly instantiate a TableCell object. If the cell has content, at least -// the Text and Color fields should be set. -// -// Note that setting cells in previously unknown rows and columns will -// automatically extend the internal table representation with empty TableCell -// objects, e.g. starting with a row of 100,000 will immediately create 100,000 -// empty rows. -// -// To avoid unnecessary garbage collection, fill columns from left to right. -func (t *Table) SetCell(row, column int, cell *TableCell) *Table { - if row >= len(t.cells) { - t.cells = append(t.cells, make([][]*TableCell, row-len(t.cells)+1)...) - } - rowLen := len(t.cells[row]) - if column >= rowLen { - t.cells[row] = append(t.cells[row], make([]*TableCell, column-rowLen+1)...) - for c := rowLen; c < column; c++ { - t.cells[row][c] = &TableCell{} - } - } - t.cells[row][column] = cell - if column > t.lastColumn { - t.lastColumn = column - } - return t -} - -// SetCellSimple calls SetCell() with the given text, left-aligned, in white. -func (t *Table) SetCellSimple(row, column int, text string) *Table { - t.SetCell(row, column, NewTableCell(text)) - return t -} - -// GetCell returns the contents of the cell at the specified position. A valid -// TableCell object is always returned but it will be uninitialized if the cell -// was not previously set. Such an uninitialized object will not automatically -// be inserted. Therefore, repeated calls to this function may return different -// pointers for uninitialized cells. -func (t *Table) GetCell(row, column int) *TableCell { - if row >= len(t.cells) || column >= len(t.cells[row]) { - return &TableCell{} - } - return t.cells[row][column] -} - -// RemoveRow removes the row at the given position from the table. If there is -// no such row, this has no effect. -func (t *Table) RemoveRow(row int) *Table { - if row < 0 || row >= len(t.cells) { - return t - } - - t.cells = append(t.cells[:row], t.cells[row+1:]...) - - return t -} - -// RemoveColumn removes the column at the given position from the table. If -// there is no such column, this has no effect. -func (t *Table) RemoveColumn(column int) *Table { - for row := range t.cells { - if column < 0 || column >= len(t.cells[row]) { - continue - } - t.cells[row] = append(t.cells[row][:column], t.cells[row][column+1:]...) - } - - return t -} - -// InsertRow inserts a row before the row with the given index. Cells on the -// given row and below will be shifted to the bottom by one row. If "row" is -// equal or larger than the current number of rows, this function has no effect. -func (t *Table) InsertRow(row int) *Table { - if row >= len(t.cells) { - return t - } - t.cells = append(t.cells, nil) // Extend by one. - copy(t.cells[row+1:], t.cells[row:]) // Shift down. - t.cells[row] = nil // New row is uninitialized. - return t -} - -// InsertColumn inserts a column before the column with the given index. Cells -// in the given column and to its right will be shifted to the right by one -// column. Rows that have fewer initialized cells than "column" will remain -// unchanged. -func (t *Table) InsertColumn(column int) *Table { - for row := range t.cells { - if column >= len(t.cells[row]) { - continue - } - t.cells[row] = append(t.cells[row], nil) // Extend by one. - copy(t.cells[row][column+1:], t.cells[row][column:]) // Shift to the right. - t.cells[row][column] = &TableCell{} // New element is an uninitialized table cell. - } - return t -} - -// GetRowCount returns the number of rows in the table. -func (t *Table) GetRowCount() int { - return len(t.cells) -} - -// GetColumnCount returns the (maximum) number of columns in the table. -func (t *Table) GetColumnCount() int { - if len(t.cells) == 0 { - return 0 - } - return t.lastColumn + 1 -} - -// cellAt returns the row and column located at the given screen coordinates. -// Each returned value may be negative if there is no row and/or cell. This -// function will also process coordinates outside the table's inner rectangle so -// callers will need to check for bounds themselves. -func (t *Table) cellAt(x, y int) (row, column int) { - rectX, rectY, _, _ := t.GetInnerRect() - - // Determine row as seen on screen. - if t.borders { - row = (y - rectY - 1) / 2 - } else { - row = y - rectY - } - - // Respect fixed rows and row offset. - if row >= 0 { - if row >= t.fixedRows { - row += t.rowOffset - } - if row >= len(t.cells) { - row = -1 - } - } - - // Saerch for the clicked column. - column = -1 - if x >= rectX { - columnX := rectX - if t.borders { - columnX++ - } - for index, width := range t.visibleColumnWidths { - columnX += width + 1 - if x < columnX { - column = t.visibleColumnIndices[index] - break - } - } - } - - return -} - -// ScrollToBeginning scrolls the table to the beginning to that the top left -// corner of the table is shown. Note that this position may be corrected if -// there is a selection. -func (t *Table) ScrollToBeginning() *Table { - t.trackEnd = false - t.columnOffset = 0 - t.rowOffset = 0 - return t -} - -// ScrollToEnd scrolls the table to the beginning to that the bottom left corner -// of the table is shown. Adding more rows to the table will cause it to -// automatically scroll with the new data. Note that this position may be -// corrected if there is a selection. -func (t *Table) ScrollToEnd() *Table { - t.trackEnd = true - t.columnOffset = 0 - t.rowOffset = len(t.cells) - return t -} - -// Draw draws this primitive onto the screen. -func (t *Table) Draw(screen tcell.Screen) { - t.Box.DrawForSubclass(screen, t) - - // What's our available screen space? - _, totalHeight := screen.Size() - x, y, width, height := t.GetInnerRect() - if t.borders { - t.visibleRows = height / 2 - } else { - t.visibleRows = height - } - - // Return the cell at the specified position (nil if it doesn't exist). - getCell := func(row, column int) *TableCell { - if row < 0 || column < 0 || row >= len(t.cells) || column >= len(t.cells[row]) { - return nil - } - return t.cells[row][column] - } - - // If this cell is not selectable, find the next one. - if t.rowsSelectable || t.columnsSelectable { - if t.selectedColumn < 0 { - t.selectedColumn = 0 - } - if t.selectedRow < 0 { - t.selectedRow = 0 - } - for t.selectedRow < len(t.cells) { - cell := getCell(t.selectedRow, t.selectedColumn) - if cell != nil && !cell.NotSelectable { - break - } - t.selectedColumn++ - if t.selectedColumn > t.lastColumn { - t.selectedColumn = 0 - t.selectedRow++ - } - } - } - - // Clamp row offsets. - if t.rowsSelectable { - if t.selectedRow >= t.fixedRows && t.selectedRow < t.fixedRows+t.rowOffset { - t.rowOffset = t.selectedRow - t.fixedRows - t.trackEnd = false - } - if t.borders { - if 2*(t.selectedRow+1-t.rowOffset) >= height { - t.rowOffset = t.selectedRow + 1 - height/2 - t.trackEnd = false - } - } else { - if t.selectedRow+1-t.rowOffset >= height { - t.rowOffset = t.selectedRow + 1 - height - t.trackEnd = false - } - } - } - if t.borders { - if 2*(len(t.cells)-t.rowOffset) < height { - t.trackEnd = true - } - } else { - if len(t.cells)-t.rowOffset < height { - t.trackEnd = true - } - } - if t.trackEnd { - if t.borders { - t.rowOffset = len(t.cells) - height/2 - } else { - t.rowOffset = len(t.cells) - height - } - } - if t.rowOffset < 0 { - t.rowOffset = 0 - } - - // Clamp column offset. (Only left side here. The right side is more - // difficult and we'll do it below.) - if t.columnsSelectable && t.selectedColumn >= t.fixedColumns && t.selectedColumn < t.fixedColumns+t.columnOffset { - t.columnOffset = t.selectedColumn - t.fixedColumns - } - if t.columnOffset < 0 { - t.columnOffset = 0 - } - if t.selectedColumn < 0 { - t.selectedColumn = 0 - } - - // Determine the indices and widths of the columns and rows which fit on the - // screen. - var ( - columns, rows, allRows, widths []int - tableHeight, tableWidth int - ) - rowStep := 1 - if t.borders { - rowStep = 2 // With borders, every table row takes two screen rows. - tableWidth = 1 // We start at the second character because of the left table border. - } - if t.evaluateAllRows { - allRows = make([]int, len(t.cells)) - for row := range t.cells { - allRows[row] = row - } - } - indexRow := func(row int) bool { // Determine if this row is visible, store its index. - if tableHeight >= height { - return false - } - rows = append(rows, row) - tableHeight += rowStep - return true - } - for row := 0; row < t.fixedRows && row < len(t.cells); row++ { // Do the fixed rows first. - if !indexRow(row) { - break - } - } - for row := t.fixedRows + t.rowOffset; row < len(t.cells); row++ { // Then the remaining rows. - if !indexRow(row) { - break - } - } - var ( - skipped, lastTableWidth, expansionTotal int - expansions []int - ) -ColumnLoop: - for column := 0; ; column++ { - // If we've moved beyond the right border, we stop or skip a column. - for tableWidth-1 >= width { // -1 because we include one extra column if the separator falls on the right end of the box. - // We've moved beyond the available space. - if column < t.fixedColumns { - break ColumnLoop // We're in the fixed area. We're done. - } - if !t.columnsSelectable && skipped >= t.columnOffset { - break ColumnLoop // There is no selection and we've already reached the offset. - } - if t.columnsSelectable && t.selectedColumn-skipped == t.fixedColumns { - break ColumnLoop // The selected column reached the leftmost point before disappearing. - } - if t.columnsSelectable && skipped >= t.columnOffset && - (t.selectedColumn < column && lastTableWidth < width-1 && tableWidth < width-1 || t.selectedColumn < column-1) { - break ColumnLoop // We've skipped as many as requested and the selection is visible. - } - if len(columns) <= t.fixedColumns { - break // Nothing to skip. - } - - // We need to skip a column. - skipped++ - lastTableWidth -= widths[t.fixedColumns] + 1 - tableWidth -= widths[t.fixedColumns] + 1 - columns = append(columns[:t.fixedColumns], columns[t.fixedColumns+1:]...) - widths = append(widths[:t.fixedColumns], widths[t.fixedColumns+1:]...) - expansions = append(expansions[:t.fixedColumns], expansions[t.fixedColumns+1:]...) - } - - // What's this column's width (without expansion)? - maxWidth := -1 - expansion := 0 - evaluationRows := rows - if t.evaluateAllRows { - evaluationRows = allRows - } - for _, row := range evaluationRows { - if cell := getCell(row, column); cell != nil { - _, _, _, _, _, _, cellWidth := decomposeString(cell.Text, true, false) - if cell.MaxWidth > 0 && cell.MaxWidth < cellWidth { - cellWidth = cell.MaxWidth - } - if cellWidth > maxWidth { - maxWidth = cellWidth - } - if cell.Expansion > expansion { - expansion = cell.Expansion - } - } - } - if maxWidth < 0 { - break // No more cells found in this column. - } - - // Store new column info at the end. - columns = append(columns, column) - widths = append(widths, maxWidth) - lastTableWidth = tableWidth - tableWidth += maxWidth + 1 - expansions = append(expansions, expansion) - expansionTotal += expansion - } - t.columnOffset = skipped - - // If we have space left, distribute it. - if tableWidth < width { - toDistribute := width - tableWidth - for index, expansion := range expansions { - if expansionTotal <= 0 { - break - } - expWidth := toDistribute * expansion / expansionTotal - widths[index] += expWidth - toDistribute -= expWidth - expansionTotal -= expansion - } - } - - // Helper function which draws border runes. - borderStyle := tcell.StyleDefault.Background(t.backgroundColor).Foreground(t.bordersColor) - drawBorder := func(colX, rowY int, ch rune) { - screen.SetContent(x+colX, y+rowY, ch, nil, borderStyle) - } - - // Draw the cells (and borders). - var columnX int - if !t.borders { - columnX-- - } - for columnIndex, column := range columns { - columnWidth := widths[columnIndex] - for rowY, row := range rows { - if t.borders { - // Draw borders. - rowY *= 2 - for pos := 0; pos < columnWidth && columnX+1+pos < width; pos++ { - drawBorder(columnX+pos+1, rowY, Borders.Horizontal) - } - ch := Borders.Cross - if columnIndex == 0 { - if rowY == 0 { - ch = Borders.TopLeft - } else { - ch = Borders.LeftT - } - } else if rowY == 0 { - ch = Borders.TopT - } - drawBorder(columnX, rowY, ch) - rowY++ - if rowY >= height || y+rowY >= totalHeight { - break // No space for the text anymore. - } - drawBorder(columnX, rowY, Borders.Vertical) - } else if columnIndex > 0 { - // Draw separator. - drawBorder(columnX, rowY, t.separator) - } - - // Get the cell. - cell := getCell(row, column) - if cell == nil { - continue - } - - // Draw text. - finalWidth := columnWidth - if columnX+1+columnWidth >= width { - finalWidth = width - columnX - 1 - } - cell.x, cell.y, cell.width = x+columnX+1, y+rowY, finalWidth - _, printed := printWithStyle(screen, cell.Text, x+columnX+1, y+rowY, finalWidth, cell.Align, tcell.StyleDefault.Foreground(cell.Color).Attributes(cell.Attributes)) - if TaggedStringWidth(cell.Text)-printed > 0 && printed > 0 { - _, _, style, _ := screen.GetContent(x+columnX+finalWidth, y+rowY) - printWithStyle(screen, string(SemigraphicsHorizontalEllipsis), x+columnX+finalWidth, y+rowY, 1, AlignLeft, style) - } - } - - // Draw bottom border. - if rowY := 2 * len(rows); t.borders && rowY < height { - for pos := 0; pos < columnWidth && columnX+1+pos < width; pos++ { - drawBorder(columnX+pos+1, rowY, Borders.Horizontal) - } - ch := Borders.BottomT - if columnIndex == 0 { - ch = Borders.BottomLeft - } - drawBorder(columnX, rowY, ch) - } - - columnX += columnWidth + 1 - } - - // Draw right border. - if t.borders && len(t.cells) > 0 && columnX < width { - for rowY := range rows { - rowY *= 2 - if rowY+1 < height { - drawBorder(columnX, rowY+1, Borders.Vertical) - } - ch := Borders.RightT - if rowY == 0 { - ch = Borders.TopRight - } - drawBorder(columnX, rowY, ch) - } - if rowY := 2 * len(rows); rowY < height { - drawBorder(columnX, rowY, Borders.BottomRight) - } - } - - // Helper function which colors the background of a box. - // backgroundColor == tcell.ColorDefault => Don't color the background. - // textColor == tcell.ColorDefault => Don't change the text color. - // attr == 0 => Don't change attributes. - // invert == true => Ignore attr, set text to backgroundColor or t.backgroundColor; - // set background to textColor. - colorBackground := func(fromX, fromY, w, h int, backgroundColor, textColor tcell.Color, attr tcell.AttrMask, invert bool) { - for by := 0; by < h && fromY+by < y+height; by++ { - for bx := 0; bx < w && fromX+bx < x+width; bx++ { - m, c, style, _ := screen.GetContent(fromX+bx, fromY+by) - fg, bg, a := style.Decompose() - if invert { - if fg == textColor || fg == t.bordersColor { - fg = backgroundColor - } - if fg == tcell.ColorDefault { - fg = t.backgroundColor - } - style = style.Background(textColor).Foreground(fg) - } else { - if backgroundColor != tcell.ColorDefault { - bg = backgroundColor - } - if textColor != tcell.ColorDefault { - fg = textColor - } - if attr != 0 { - a = attr - } - style = style.Background(bg).Foreground(fg).Attributes(a) - } - screen.SetContent(fromX+bx, fromY+by, m, c, style) - } - } - } - - // Color the cell backgrounds. To avoid undesirable artefacts, we combine - // the drawing of a cell by background color, selected cells last. - type cellInfo struct { - x, y, w, h int - text tcell.Color - selected bool - } - cellsByBackgroundColor := make(map[tcell.Color][]*cellInfo) - var backgroundColors []tcell.Color - for rowY, row := range rows { - columnX := 0 - rowSelected := t.rowsSelectable && !t.columnsSelectable && row == t.selectedRow - for columnIndex, column := range columns { - columnWidth := widths[columnIndex] - cell := getCell(row, column) - if cell == nil { - continue - } - bx, by, bw, bh := x+columnX, y+rowY, columnWidth+1, 1 - if t.borders { - by = y + rowY*2 - bw++ - bh = 3 - } - columnSelected := t.columnsSelectable && !t.rowsSelectable && column == t.selectedColumn - cellSelected := !cell.NotSelectable && (columnSelected || rowSelected || t.rowsSelectable && t.columnsSelectable && column == t.selectedColumn && row == t.selectedRow) - entries, ok := cellsByBackgroundColor[cell.BackgroundColor] - cellsByBackgroundColor[cell.BackgroundColor] = append(entries, &cellInfo{ - x: bx, - y: by, - w: bw, - h: bh, - text: cell.Color, - selected: cellSelected, - }) - if !ok { - backgroundColors = append(backgroundColors, cell.BackgroundColor) - } - columnX += columnWidth + 1 - } - } - sort.Slice(backgroundColors, func(i int, j int) bool { - // Draw brightest colors last (i.e. on top). - r, g, b := backgroundColors[i].RGB() - c := colorful.Color{R: float64(r) / 255, G: float64(g) / 255, B: float64(b) / 255} - _, _, li := c.Hcl() - r, g, b = backgroundColors[j].RGB() - c = colorful.Color{R: float64(r) / 255, G: float64(g) / 255, B: float64(b) / 255} - _, _, lj := c.Hcl() - return li < lj - }) - selFg, selBg, selAttr := t.selectedStyle.Decompose() - for _, bgColor := range backgroundColors { - entries := cellsByBackgroundColor[bgColor] - for _, cell := range entries { - if cell.selected { - if t.selectedStyle != (tcell.Style{}) { - defer colorBackground(cell.x, cell.y, cell.w, cell.h, selBg, selFg, selAttr, false) - } else { - defer colorBackground(cell.x, cell.y, cell.w, cell.h, bgColor, cell.text, 0, true) - } - } else { - colorBackground(cell.x, cell.y, cell.w, cell.h, bgColor, tcell.ColorDefault, 0, false) - } - } - } - - // Remember column infos. - t.visibleColumnIndices, t.visibleColumnWidths = columns, widths -} - -// InputHandler returns the handler for this primitive. -func (t *Table) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return t.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - key := event.Key() - - if (!t.rowsSelectable && !t.columnsSelectable && key == tcell.KeyEnter) || - key == tcell.KeyEscape || - key == tcell.KeyTab || - key == tcell.KeyBacktab { - if t.done != nil { - t.done(key) - } - return - } - - // Movement functions. - previouslySelectedRow, previouslySelectedColumn := t.selectedRow, t.selectedColumn - var ( - getCell = func(row, column int) *TableCell { - if row < 0 || column < 0 || row >= len(t.cells) || column >= len(t.cells[row]) { - return nil - } - return t.cells[row][column] - } - - previous = func() { - for t.selectedRow >= 0 { - cell := getCell(t.selectedRow, t.selectedColumn) - if cell != nil && !cell.NotSelectable { - return - } - t.selectedColumn-- - if t.selectedColumn < 0 { - t.selectedColumn = t.lastColumn - t.selectedRow-- - } - } - } - - next = func() { - if t.selectedColumn > t.lastColumn { - t.selectedColumn = 0 - t.selectedRow++ - if t.selectedRow >= len(t.cells) { - t.selectedRow = len(t.cells) - 1 - } - } - for t.selectedRow < len(t.cells) { - cell := getCell(t.selectedRow, t.selectedColumn) - if cell != nil && !cell.NotSelectable { - return - } - t.selectedColumn++ - if t.selectedColumn > t.lastColumn { - t.selectedColumn = 0 - t.selectedRow++ - } - } - t.selectedColumn = t.lastColumn - t.selectedRow = len(t.cells) - 1 - previous() - } - - home = func() { - if t.rowsSelectable { - t.selectedRow = 0 - t.selectedColumn = 0 - next() - } else { - t.trackEnd = false - t.rowOffset = 0 - t.columnOffset = 0 - } - } - - end = func() { - if t.rowsSelectable { - t.selectedRow = len(t.cells) - 1 - t.selectedColumn = t.lastColumn - previous() - } else { - t.trackEnd = true - t.columnOffset = 0 - } - } - - down = func() { - if t.rowsSelectable { - t.selectedRow++ - if t.selectedRow >= len(t.cells) { - t.selectedRow = len(t.cells) - 1 - } - next() - } else { - t.rowOffset++ - } - } - - up = func() { - if t.rowsSelectable { - t.selectedRow-- - if t.selectedRow < 0 { - t.selectedRow = 0 - } - previous() - } else { - t.trackEnd = false - t.rowOffset-- - } - } - - left = func() { - if t.columnsSelectable { - t.selectedColumn-- - if t.selectedColumn < 0 { - t.selectedColumn = 0 - } - previous() - } else { - t.columnOffset-- - } - } - - right = func() { - if t.columnsSelectable { - t.selectedColumn++ - next() - } else { - t.columnOffset++ - } - } - - pageDown = func() { - offsetAmount := t.visibleRows - t.fixedRows - if offsetAmount < 0 { - offsetAmount = 0 - } - - if t.rowsSelectable { - t.selectedRow += offsetAmount - if t.selectedRow >= len(t.cells) { - t.selectedRow = len(t.cells) - 1 - } - next() - } else { - t.rowOffset += offsetAmount - } - } - - pageUp = func() { - offsetAmount := t.visibleRows - t.fixedRows - if offsetAmount < 0 { - offsetAmount = 0 - } - - if t.rowsSelectable { - t.selectedRow -= offsetAmount - if t.selectedRow < 0 { - t.selectedRow = 0 - } - previous() - } else { - t.trackEnd = false - t.rowOffset -= offsetAmount - } - } - ) - - switch key { - case tcell.KeyRune: - switch event.Rune() { - case 'g': - home() - case 'G': - end() - case 'j': - down() - case 'k': - up() - case 'h': - left() - case 'l': - right() - } - case tcell.KeyHome: - home() - case tcell.KeyEnd: - end() - case tcell.KeyUp: - up() - case tcell.KeyDown: - down() - case tcell.KeyLeft: - left() - case tcell.KeyRight: - right() - case tcell.KeyPgDn, tcell.KeyCtrlF: - pageDown() - case tcell.KeyPgUp, tcell.KeyCtrlB: - pageUp() - case tcell.KeyEnter: - if (t.rowsSelectable || t.columnsSelectable) && t.selected != nil { - t.selected(t.selectedRow, t.selectedColumn) - } - } - - // If the selection has changed, notify the handler. - if t.selectionChanged != nil && - (t.rowsSelectable && previouslySelectedRow != t.selectedRow || - t.columnsSelectable && previouslySelectedColumn != t.selectedColumn) { - t.selectionChanged(t.selectedRow, t.selectedColumn) - } - }) -} - -// MouseHandler returns the mouse handler for this primitive. -func (t *Table) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return t.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - x, y := event.Position() - if !t.InRect(x, y) { - return false, nil - } - - switch action { - case MouseLeftClick: - selectEvent := true - row, column := t.cellAt(x, y) - if row >= 0 && row < len(t.cells) && column >= 0 { - cells := t.cells[row] - if column < len(cells) { - cell := cells[column] - if cell != nil && cell.Clicked != nil { - if noSelect := cell.Clicked(); noSelect { - selectEvent = false - } - } - } - } - if selectEvent && (t.rowsSelectable || t.columnsSelectable) { - t.Select(row, column) - } - setFocus(t) - consumed = true - case MouseScrollUp: - t.trackEnd = false - t.rowOffset-- - consumed = true - case MouseScrollDown: - t.rowOffset++ - consumed = true - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/textview.go b/vendor/github.com/rivo/tview/textview.go deleted file mode 100644 index de08642..0000000 --- a/vendor/github.com/rivo/tview/textview.go +++ /dev/null @@ -1,1185 +0,0 @@ -package tview - -import ( - "bytes" - "fmt" - "regexp" - "strings" - "sync" - "unicode/utf8" - - "github.com/gdamore/tcell/v2" - colorful "github.com/lucasb-eyer/go-colorful" - runewidth "github.com/mattn/go-runewidth" - "github.com/rivo/uniseg" -) - -var ( - openColorRegex = regexp.MustCompile(`\[([a-zA-Z]*|#[0-9a-zA-Z]*)$`) - openRegionRegex = regexp.MustCompile(`\["[a-zA-Z0-9_,;: \-\.]*"?$`) - newLineRegex = regexp.MustCompile(`\r?\n`) - - // TabSize is the number of spaces with which a tab character will be replaced. - TabSize = 4 -) - -// textViewIndex contains information about each line displayed in the text -// view. -type textViewIndex struct { - Line int // The index into the "buffer" variable. - Pos int // The index into the "buffer" string (byte position). - NextPos int // The (byte) index of the next character in this buffer line. - Width int // The screen width of this line. - ForegroundColor string // The starting foreground color ("" = don't change, "-" = reset). - BackgroundColor string // The starting background color ("" = don't change, "-" = reset). - Attributes string // The starting attributes ("" = don't change, "-" = reset). - Region string // The starting region ID. -} - -// textViewRegion contains information about a region. -type textViewRegion struct { - // The region ID. - ID string - - // The starting and end screen position of the region as determined the last - // time Draw() was called. A negative value indicates out-of-rect positions. - FromX, FromY, ToX, ToY int -} - -// TextView is a box which displays text. It implements the io.Writer interface -// so you can stream text to it. This does not trigger a redraw automatically -// but if a handler is installed via SetChangedFunc(), you can cause it to be -// redrawn. (See SetChangedFunc() for more details.) -// -// Navigation -// -// If the text view is scrollable (the default), text is kept in a buffer which -// may be larger than the screen and can be navigated similarly to Vim: -// -// - h, left arrow: Move left. -// - l, right arrow: Move right. -// - j, down arrow: Move down. -// - k, up arrow: Move up. -// - g, home: Move to the top. -// - G, end: Move to the bottom. -// - Ctrl-F, page down: Move down by one page. -// - Ctrl-B, page up: Move up by one page. -// -// If the text is not scrollable, any text above the top visible line is -// discarded. -// -// Use SetInputCapture() to override or modify keyboard input. -// -// Colors -// -// If dynamic colors are enabled via SetDynamicColors(), text color can be -// changed dynamically by embedding color strings in square brackets. This works -// the same way as anywhere else. Please see the package documentation for more -// information. -// -// Regions and Highlights -// -// If regions are enabled via SetRegions(), you can define text regions within -// the text and assign region IDs to them. Text regions start with region tags. -// Region tags are square brackets that contain a region ID in double quotes, -// for example: -// -// We define a ["rg"]region[""] here. -// -// A text region ends with the next region tag. Tags with no region ID ([""]) -// don't start new regions. They can therefore be used to mark the end of a -// region. Region IDs must satisfy the following regular expression: -// -// [a-zA-Z0-9_,;: \-\.]+ -// -// Regions can be highlighted by calling the Highlight() function with one or -// more region IDs. This can be used to display search results, for example. -// -// The ScrollToHighlight() function can be used to jump to the currently -// highlighted region once when the text view is drawn the next time. -// -// See https://github.com/rivo/tview/wiki/TextView for an example. -type TextView struct { - sync.Mutex - *Box - - // The text buffer. - buffer []string - - // The last bytes that have been received but are not part of the buffer yet. - recentBytes []byte - - // The processed line index. This is nil if the buffer has changed and needs - // to be re-indexed. - index []*textViewIndex - - // The text alignment, one of AlignLeft, AlignCenter, or AlignRight. - align int - - // Information about visible regions as of the last call to Draw(). - regionInfos []*textViewRegion - - // Indices into the "index" slice which correspond to the first line of the - // first highlight and the last line of the last highlight. This is calculated - // during re-indexing. Set to -1 if there is no current highlight. - fromHighlight, toHighlight int - - // The screen space column of the highlight in its first line. Set to -1 if - // there is no current highlight. - posHighlight int - - // A set of region IDs that are currently highlighted. - highlights map[string]struct{} - - // The last width for which the current table is drawn. - lastWidth int - - // The screen width of the longest line in the index (not the buffer). - longestLine int - - // The index of the first line shown in the text view. - lineOffset int - - // If set to true, the text view will always remain at the end of the content. - trackEnd bool - - // The number of characters to be skipped on each line (not in wrap mode). - columnOffset int - - // The height of the content the last time the text view was drawn. - pageSize int - - // If set to true, the text view will keep a buffer of text which can be - // navigated when the text is longer than what fits into the box. - scrollable bool - - // If set to true, lines that are longer than the available width are wrapped - // onto the next line. If set to false, any characters beyond the available - // width are discarded. - wrap bool - - // If set to true and if wrap is also true, lines are split at spaces or - // after punctuation characters. - wordWrap bool - - // The (starting) color of the text. - textColor tcell.Color - - // If set to true, the text color can be changed dynamically by piping color - // strings in square brackets to the text view. - dynamicColors bool - - // If set to true, region tags can be used to define regions. - regions bool - - // A temporary flag which, when true, will automatically bring the current - // highlight(s) into the visible screen. - scrollToHighlights bool - - // If true, setting new highlights will be a XOR instead of an overwrite - // operation. - toggleHighlights bool - - // An optional function which is called when the content of the text view has - // changed. - changed func() - - // An optional function which is called when the user presses one of the - // following keys: Escape, Enter, Tab, Backtab. - done func(tcell.Key) - - // An optional function which is called when one or more regions were - // highlighted. - highlighted func(added, removed, remaining []string) -} - -// NewTextView returns a new text view. -func NewTextView() *TextView { - return &TextView{ - Box: NewBox(), - highlights: make(map[string]struct{}), - lineOffset: -1, - scrollable: true, - align: AlignLeft, - wrap: true, - textColor: Styles.PrimaryTextColor, - regions: false, - dynamicColors: false, - } -} - -// SetScrollable sets the flag that decides whether or not the text view is -// scrollable. If true, text is kept in a buffer and can be navigated. If false, -// the last line will always be visible. -func (t *TextView) SetScrollable(scrollable bool) *TextView { - t.scrollable = scrollable - if !scrollable { - t.trackEnd = true - } - return t -} - -// SetWrap sets the flag that, if true, leads to lines that are longer than the -// available width being wrapped onto the next line. If false, any characters -// beyond the available width are not displayed. -func (t *TextView) SetWrap(wrap bool) *TextView { - if t.wrap != wrap { - t.index = nil - } - t.wrap = wrap - return t -} - -// SetWordWrap sets the flag that, if true and if the "wrap" flag is also true -// (see SetWrap()), wraps the line at spaces or after punctuation marks. Note -// that trailing spaces will not be printed. -// -// This flag is ignored if the "wrap" flag is false. -func (t *TextView) SetWordWrap(wrapOnWords bool) *TextView { - if t.wordWrap != wrapOnWords { - t.index = nil - } - t.wordWrap = wrapOnWords - return t -} - -// SetTextAlign sets the text alignment within the text view. This must be -// either AlignLeft, AlignCenter, or AlignRight. -func (t *TextView) SetTextAlign(align int) *TextView { - if t.align != align { - t.index = nil - } - t.align = align - return t -} - -// SetTextColor sets the initial color of the text (which can be changed -// dynamically by sending color strings in square brackets to the text view if -// dynamic colors are enabled). -func (t *TextView) SetTextColor(color tcell.Color) *TextView { - t.textColor = color - return t -} - -// SetText sets the text of this text view to the provided string. Previously -// contained text will be removed. -func (t *TextView) SetText(text string) *TextView { - t.Clear() - fmt.Fprint(t, text) - return t -} - -// GetText returns the current text of this text view. If "stripAllTags" is set -// to true, any region/color tags are stripped from the text. -func (t *TextView) GetText(stripAllTags bool) string { - // Get the buffer. - buffer := make([]string, len(t.buffer), len(t.buffer)+1) - copy(buffer, t.buffer) - if !stripAllTags { - buffer = append(buffer, string(t.recentBytes)) - } - - // Add newlines again. - text := strings.Join(buffer, "\n") - - // Strip from tags if required. - if stripAllTags { - if t.regions { - text = regionPattern.ReplaceAllString(text, "") - } - if t.dynamicColors { - text = stripTags(text) - } - if t.regions && !t.dynamicColors { - text = escapePattern.ReplaceAllString(text, `[$1$2]`) - } - } - - return text -} - -// SetDynamicColors sets the flag that allows the text color to be changed -// dynamically. See class description for details. -func (t *TextView) SetDynamicColors(dynamic bool) *TextView { - if t.dynamicColors != dynamic { - t.index = nil - } - t.dynamicColors = dynamic - return t -} - -// SetRegions sets the flag that allows to define regions in the text. See class -// description for details. -func (t *TextView) SetRegions(regions bool) *TextView { - if t.regions != regions { - t.index = nil - } - t.regions = regions - return t -} - -// SetChangedFunc sets a handler function which is called when the text of the -// text view has changed. This is useful when text is written to this io.Writer -// in a separate goroutine. Doing so does not automatically cause the screen to -// be refreshed so you may want to use the "changed" handler to redraw the -// screen. -// -// Note that to avoid race conditions or deadlocks, there are a few rules you -// should follow: -// -// - You can call Application.Draw() from this handler. -// - You can call TextView.HasFocus() from this handler. -// - During the execution of this handler, access to any other variables from -// this primitive or any other primitive must be queued using -// Application.QueueUpdate(). -// -// See package description for details on dealing with concurrency. -func (t *TextView) SetChangedFunc(handler func()) *TextView { - t.changed = handler - return t -} - -// SetDoneFunc sets a handler which is called when the user presses on the -// following keys: Escape, Enter, Tab, Backtab. The key is passed to the -// handler. -func (t *TextView) SetDoneFunc(handler func(key tcell.Key)) *TextView { - t.done = handler - return t -} - -// SetHighlightedFunc sets a handler which is called when the list of currently -// highlighted regions change. It receives a list of region IDs which were newly -// highlighted, those that are not highlighted anymore, and those that remain -// highlighted. -// -// Note that because regions are only determined during drawing, this function -// can only fire for regions that have existed during the last call to Draw(). -func (t *TextView) SetHighlightedFunc(handler func(added, removed, remaining []string)) *TextView { - t.highlighted = handler - return t -} - -// ScrollTo scrolls to the specified row and column (both starting with 0). -func (t *TextView) ScrollTo(row, column int) *TextView { - if !t.scrollable { - return t - } - t.lineOffset = row - t.columnOffset = column - t.trackEnd = false - return t -} - -// ScrollToBeginning scrolls to the top left corner of the text if the text view -// is scrollable. -func (t *TextView) ScrollToBeginning() *TextView { - if !t.scrollable { - return t - } - t.trackEnd = false - t.lineOffset = 0 - t.columnOffset = 0 - return t -} - -// ScrollToEnd scrolls to the bottom left corner of the text if the text view -// is scrollable. Adding new rows to the end of the text view will cause it to -// scroll with the new data. -func (t *TextView) ScrollToEnd() *TextView { - if !t.scrollable { - return t - } - t.trackEnd = true - t.columnOffset = 0 - return t -} - -// GetScrollOffset returns the number of rows and columns that are skipped at -// the top left corner when the text view has been scrolled. -func (t *TextView) GetScrollOffset() (row, column int) { - return t.lineOffset, t.columnOffset -} - -// Clear removes all text from the buffer. -func (t *TextView) Clear() *TextView { - t.buffer = nil - t.recentBytes = nil - t.index = nil - return t -} - -// Highlight specifies which regions should be highlighted. If highlight -// toggling is set to true (see SetToggleHighlights()), the highlight of the -// provided regions is toggled (highlighted regions are un-highlighted and vice -// versa). If toggling is set to false, the provided regions are highlighted and -// all other regions will not be highlighted (you may also provide nil to turn -// off all highlights). -// -// For more information on regions, see class description. Empty region strings -// are ignored. -// -// Text in highlighted regions will be drawn inverted, i.e. with their -// background and foreground colors swapped. -func (t *TextView) Highlight(regionIDs ...string) *TextView { - // Toggle highlights. - if t.toggleHighlights { - var newIDs []string - HighlightLoop: - for regionID := range t.highlights { - for _, id := range regionIDs { - if regionID == id { - continue HighlightLoop - } - } - newIDs = append(newIDs, regionID) - } - for _, regionID := range regionIDs { - if _, ok := t.highlights[regionID]; !ok { - newIDs = append(newIDs, regionID) - } - } - regionIDs = newIDs - } // Now we have a list of region IDs that end up being highlighted. - - // Determine added and removed regions. - var added, removed, remaining []string - if t.highlighted != nil { - for _, regionID := range regionIDs { - if _, ok := t.highlights[regionID]; ok { - remaining = append(remaining, regionID) - delete(t.highlights, regionID) - } else { - added = append(added, regionID) - } - } - for regionID := range t.highlights { - removed = append(removed, regionID) - } - } - - // Make new selection. - t.highlights = make(map[string]struct{}) - for _, id := range regionIDs { - if id == "" { - continue - } - t.highlights[id] = struct{}{} - } - t.index = nil - - // Notify. - if t.highlighted != nil && len(added) > 0 || len(removed) > 0 { - t.highlighted(added, removed, remaining) - } - - return t -} - -// GetHighlights returns the IDs of all currently highlighted regions. -func (t *TextView) GetHighlights() (regionIDs []string) { - for id := range t.highlights { - regionIDs = append(regionIDs, id) - } - return -} - -// SetToggleHighlights sets a flag to determine how regions are highlighted. -// When set to true, the Highlight() function (or a mouse click) will toggle the -// provided/selected regions. When set to false, Highlight() (or a mouse click) -// will simply highlight the provided regions. -func (t *TextView) SetToggleHighlights(toggle bool) *TextView { - t.toggleHighlights = toggle - return t -} - -// ScrollToHighlight will cause the visible area to be scrolled so that the -// highlighted regions appear in the visible area of the text view. This -// repositioning happens the next time the text view is drawn. It happens only -// once so you will need to call this function repeatedly to always keep -// highlighted regions in view. -// -// Nothing happens if there are no highlighted regions or if the text view is -// not scrollable. -func (t *TextView) ScrollToHighlight() *TextView { - if len(t.highlights) == 0 || !t.scrollable || !t.regions { - return t - } - t.index = nil - t.scrollToHighlights = true - t.trackEnd = false - return t -} - -// GetRegionText returns the text of the region with the given ID. If dynamic -// colors are enabled, color tags are stripped from the text. Newlines are -// always returned as '\n' runes. -// -// If the region does not exist or if regions are turned off, an empty string -// is returned. -func (t *TextView) GetRegionText(regionID string) string { - if !t.regions || regionID == "" { - return "" - } - - var ( - buffer bytes.Buffer - currentRegionID string - ) - - for _, str := range t.buffer { - // Find all color tags in this line. - var colorTagIndices [][]int - if t.dynamicColors { - colorTagIndices = colorPattern.FindAllStringIndex(str, -1) - } - - // Find all regions in this line. - var ( - regionIndices [][]int - regions [][]string - ) - if t.regions { - regionIndices = regionPattern.FindAllStringIndex(str, -1) - regions = regionPattern.FindAllStringSubmatch(str, -1) - } - - // Analyze this line. - var currentTag, currentRegion int - for pos, ch := range str { - // Skip any color tags. - if currentTag < len(colorTagIndices) && pos >= colorTagIndices[currentTag][0] && pos < colorTagIndices[currentTag][1] { - if pos == colorTagIndices[currentTag][1]-1 { - currentTag++ - } - if colorTagIndices[currentTag][1]-colorTagIndices[currentTag][0] > 2 { - continue - } - } - - // Skip any regions. - if currentRegion < len(regionIndices) && pos >= regionIndices[currentRegion][0] && pos < regionIndices[currentRegion][1] { - if pos == regionIndices[currentRegion][1]-1 { - if currentRegionID == regionID { - // This is the end of the requested region. We're done. - return buffer.String() - } - currentRegionID = regions[currentRegion][1] - currentRegion++ - } - continue - } - - // Add this rune. - if currentRegionID == regionID { - buffer.WriteRune(ch) - } - } - - // Add newline. - if currentRegionID == regionID { - buffer.WriteRune('\n') - } - } - - return escapePattern.ReplaceAllString(buffer.String(), `[$1$2]`) -} - -// Focus is called when this primitive receives focus. -func (t *TextView) Focus(delegate func(p Primitive)) { - // Implemented here with locking because this is used by layout primitives. - t.Lock() - defer t.Unlock() - t.hasFocus = true -} - -// HasFocus returns whether or not this primitive has focus. -func (t *TextView) HasFocus() bool { - // Implemented here with locking because this may be used in the "changed" - // callback. - t.Lock() - defer t.Unlock() - return t.hasFocus -} - -// Write lets us implement the io.Writer interface. Tab characters will be -// replaced with TabSize space characters. A "\n" or "\r\n" will be interpreted -// as a new line. -func (t *TextView) Write(p []byte) (n int, err error) { - // Notify at the end. - t.Lock() - changed := t.changed - t.Unlock() - if changed != nil { - defer func() { - // We always call the "changed" function in a separate goroutine to avoid - // deadlocks. - go changed() - }() - } - - t.Lock() - defer t.Unlock() - - // Copy data over. - newBytes := append(t.recentBytes, p...) - t.recentBytes = nil - - // If we have a trailing invalid UTF-8 byte, we'll wait. - if r, _ := utf8.DecodeLastRune(p); r == utf8.RuneError { - t.recentBytes = newBytes - return len(p), nil - } - - // If we have a trailing open dynamic color, exclude it. - if t.dynamicColors { - location := openColorRegex.FindIndex(newBytes) - if location != nil { - t.recentBytes = newBytes[location[0]:] - newBytes = newBytes[:location[0]] - } - } - - // If we have a trailing open region, exclude it. - if t.regions { - location := openRegionRegex.FindIndex(newBytes) - if location != nil { - t.recentBytes = newBytes[location[0]:] - newBytes = newBytes[:location[0]] - } - } - - // Transform the new bytes into strings. - newBytes = bytes.Replace(newBytes, []byte{'\t'}, bytes.Repeat([]byte{' '}, TabSize), -1) - for index, line := range newLineRegex.Split(string(newBytes), -1) { - if index == 0 { - if len(t.buffer) == 0 { - t.buffer = []string{line} - } else { - t.buffer[len(t.buffer)-1] += line - } - } else { - t.buffer = append(t.buffer, line) - } - } - - // Reset the index. - t.index = nil - - return len(p), nil -} - -// reindexBuffer re-indexes the buffer such that we can use it to easily draw -// the buffer onto the screen. Each line in the index will contain a pointer -// into the buffer from which on we will print text. It will also contain the -// color with which the line starts. -func (t *TextView) reindexBuffer(width int) { - if t.index != nil { - return // Nothing has changed. We can still use the current index. - } - t.index = nil - t.fromHighlight, t.toHighlight, t.posHighlight = -1, -1, -1 - - // If there's no space, there's no index. - if width < 1 { - return - } - - // Initial states. - regionID := "" - var ( - highlighted bool - foregroundColor, backgroundColor, attributes string - ) - - // Go through each line in the buffer. - for bufferIndex, str := range t.buffer { - colorTagIndices, colorTags, regionIndices, regions, escapeIndices, strippedStr, _ := decomposeString(str, t.dynamicColors, t.regions) - - // Split the line if required. - var splitLines []string - str = strippedStr - if t.wrap && len(str) > 0 { - for len(str) > 0 { - extract := runewidth.Truncate(str, width, "") - if len(extract) == 0 { - // We'll extract at least one grapheme cluster. - gr := uniseg.NewGraphemes(str) - gr.Next() - _, to := gr.Positions() - extract = str[:to] - } - if t.wordWrap && len(extract) < len(str) { - // Add any spaces from the next line. - if spaces := spacePattern.FindStringIndex(str[len(extract):]); spaces != nil && spaces[0] == 0 { - extract = str[:len(extract)+spaces[1]] - } - - // Can we split before the mandatory end? - matches := boundaryPattern.FindAllStringIndex(extract, -1) - if len(matches) > 0 { - // Yes. Let's split there. - extract = extract[:matches[len(matches)-1][1]] - } - } - splitLines = append(splitLines, extract) - str = str[len(extract):] - } - } else { - // No need to split the line. - splitLines = []string{str} - } - - // Create index from split lines. - var originalPos, colorPos, regionPos, escapePos int - for _, splitLine := range splitLines { - line := &textViewIndex{ - Line: bufferIndex, - Pos: originalPos, - ForegroundColor: foregroundColor, - BackgroundColor: backgroundColor, - Attributes: attributes, - Region: regionID, - } - - // Shift original position with tags. - lineLength := len(splitLine) - remainingLength := lineLength - tagEnd := originalPos - totalTagLength := 0 - for { - // Which tag comes next? - nextTag := make([][3]int, 0, 3) - if colorPos < len(colorTagIndices) { - nextTag = append(nextTag, [3]int{colorTagIndices[colorPos][0], colorTagIndices[colorPos][1], 0}) // 0 = color tag. - } - if regionPos < len(regionIndices) { - nextTag = append(nextTag, [3]int{regionIndices[regionPos][0], regionIndices[regionPos][1], 1}) // 1 = region tag. - } - if escapePos < len(escapeIndices) { - nextTag = append(nextTag, [3]int{escapeIndices[escapePos][0], escapeIndices[escapePos][1], 2}) // 2 = escape tag. - } - minPos := -1 - tagIndex := -1 - for index, pair := range nextTag { - if minPos < 0 || pair[0] < minPos { - minPos = pair[0] - tagIndex = index - } - } - - // Is the next tag in range? - if tagIndex < 0 || minPos > tagEnd+remainingLength { - break // No. We're done with this line. - } - - // Advance. - strippedTagStart := nextTag[tagIndex][0] - originalPos - totalTagLength - tagEnd = nextTag[tagIndex][1] - tagLength := tagEnd - nextTag[tagIndex][0] - if nextTag[tagIndex][2] == 2 { - tagLength = 1 - } - totalTagLength += tagLength - remainingLength = lineLength - (tagEnd - originalPos - totalTagLength) - - // Process the tag. - switch nextTag[tagIndex][2] { - case 0: - // Process color tags. - foregroundColor, backgroundColor, attributes = styleFromTag(foregroundColor, backgroundColor, attributes, colorTags[colorPos]) - colorPos++ - case 1: - // Process region tags. - regionID = regions[regionPos][1] - _, highlighted = t.highlights[regionID] - - // Update highlight range. - if highlighted { - line := len(t.index) - if t.fromHighlight < 0 { - t.fromHighlight, t.toHighlight = line, line - t.posHighlight = stringWidth(splitLine[:strippedTagStart]) - } else if line > t.toHighlight { - t.toHighlight = line - } - } - - regionPos++ - case 2: - // Process escape tags. - escapePos++ - } - } - - // Advance to next line. - originalPos += lineLength + totalTagLength - - // Append this line. - line.NextPos = originalPos - line.Width = stringWidth(splitLine) - t.index = append(t.index, line) - } - - // Word-wrapped lines may have trailing whitespace. Remove it. - if t.wrap && t.wordWrap { - for _, line := range t.index { - str := t.buffer[line.Line][line.Pos:line.NextPos] - spaces := spacePattern.FindAllStringIndex(str, -1) - if spaces != nil && spaces[len(spaces)-1][1] == len(str) { - oldNextPos := line.NextPos - line.NextPos -= spaces[len(spaces)-1][1] - spaces[len(spaces)-1][0] - line.Width -= stringWidth(t.buffer[line.Line][line.NextPos:oldNextPos]) - } - } - } - } - - // Calculate longest line. - t.longestLine = 0 - for _, line := range t.index { - if line.Width > t.longestLine { - t.longestLine = line.Width - } - } -} - -// Draw draws this primitive onto the screen. -func (t *TextView) Draw(screen tcell.Screen) { - t.Box.DrawForSubclass(screen, t) - t.Lock() - defer t.Unlock() - totalWidth, totalHeight := screen.Size() - - // Get the available size. - x, y, width, height := t.GetInnerRect() - t.pageSize = height - - // If the width has changed, we need to reindex. - if width != t.lastWidth && t.wrap { - t.index = nil - } - t.lastWidth = width - - // Re-index. - t.reindexBuffer(width) - if t.regions { - t.regionInfos = nil - } - - // If we don't have an index, there's nothing to draw. - if t.index == nil { - return - } - - // Move to highlighted regions. - if t.regions && t.scrollToHighlights && t.fromHighlight >= 0 { - // Do we fit the entire height? - if t.toHighlight-t.fromHighlight+1 < height { - // Yes, let's center the highlights. - t.lineOffset = (t.fromHighlight + t.toHighlight - height) / 2 - } else { - // No, let's move to the start of the highlights. - t.lineOffset = t.fromHighlight - } - - // If the highlight is too far to the right, move it to the middle. - if t.posHighlight-t.columnOffset > 3*width/4 { - t.columnOffset = t.posHighlight - width/2 - } - - // If the highlight is off-screen on the left, move it on-screen. - if t.posHighlight-t.columnOffset < 0 { - t.columnOffset = t.posHighlight - width/4 - } - } - t.scrollToHighlights = false - - // Adjust line offset. - if t.lineOffset+height > len(t.index) { - t.trackEnd = true - } - if t.trackEnd { - t.lineOffset = len(t.index) - height - } - if t.lineOffset < 0 { - t.lineOffset = 0 - } - - // Adjust column offset. - if t.align == AlignLeft { - if t.columnOffset+width > t.longestLine { - t.columnOffset = t.longestLine - width - } - if t.columnOffset < 0 { - t.columnOffset = 0 - } - } else if t.align == AlignRight { - if t.columnOffset-width < -t.longestLine { - t.columnOffset = width - t.longestLine - } - if t.columnOffset > 0 { - t.columnOffset = 0 - } - } else { // AlignCenter. - half := (t.longestLine - width) / 2 - if half > 0 { - if t.columnOffset > half { - t.columnOffset = half - } - if t.columnOffset < -half { - t.columnOffset = -half - } - } else { - t.columnOffset = 0 - } - } - - // Draw the buffer. - defaultStyle := tcell.StyleDefault.Foreground(t.textColor) - for line := t.lineOffset; line < len(t.index); line++ { - // Are we done? - if line-t.lineOffset >= height || y+line-t.lineOffset >= totalHeight { - break - } - - // Get the text for this line. - index := t.index[line] - text := t.buffer[index.Line][index.Pos:index.NextPos] - foregroundColor := index.ForegroundColor - backgroundColor := index.BackgroundColor - attributes := index.Attributes - regionID := index.Region - if t.regions && regionID != "" && (len(t.regionInfos) == 0 || t.regionInfos[len(t.regionInfos)-1].ID != regionID) { - t.regionInfos = append(t.regionInfos, &textViewRegion{ - ID: regionID, - FromX: x, - FromY: y + line - t.lineOffset, - ToX: -1, - ToY: -1, - }) - } - - // Process tags. - colorTagIndices, colorTags, regionIndices, regions, escapeIndices, strippedText, _ := decomposeString(text, t.dynamicColors, t.regions) - - // Calculate the position of the line. - var skip, posX int - if t.align == AlignLeft { - posX = -t.columnOffset - } else if t.align == AlignRight { - posX = width - index.Width - t.columnOffset - } else { // AlignCenter. - posX = (width-index.Width)/2 - t.columnOffset - } - if posX < 0 { - skip = -posX - posX = 0 - } - - // Print the line. - if y+line-t.lineOffset >= 0 { - var colorPos, regionPos, escapePos, tagOffset, skipped int - iterateString(strippedText, func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - // Process tags. - for { - if colorPos < len(colorTags) && textPos+tagOffset >= colorTagIndices[colorPos][0] && textPos+tagOffset < colorTagIndices[colorPos][1] { - // Get the color. - foregroundColor, backgroundColor, attributes = styleFromTag(foregroundColor, backgroundColor, attributes, colorTags[colorPos]) - tagOffset += colorTagIndices[colorPos][1] - colorTagIndices[colorPos][0] - colorPos++ - } else if regionPos < len(regionIndices) && textPos+tagOffset >= regionIndices[regionPos][0] && textPos+tagOffset < regionIndices[regionPos][1] { - // Get the region. - if regionID != "" && len(t.regionInfos) > 0 && t.regionInfos[len(t.regionInfos)-1].ID == regionID { - // End last region. - t.regionInfos[len(t.regionInfos)-1].ToX = x + posX - t.regionInfos[len(t.regionInfos)-1].ToY = y + line - t.lineOffset - } - regionID = regions[regionPos][1] - if regionID != "" { - // Start new region. - t.regionInfos = append(t.regionInfos, &textViewRegion{ - ID: regionID, - FromX: x + posX, - FromY: y + line - t.lineOffset, - ToX: -1, - ToY: -1, - }) - } - tagOffset += regionIndices[regionPos][1] - regionIndices[regionPos][0] - regionPos++ - } else { - break - } - } - - // Skip the second-to-last character of an escape tag. - if escapePos < len(escapeIndices) && textPos+tagOffset == escapeIndices[escapePos][1]-2 { - tagOffset++ - escapePos++ - } - - // Mix the existing style with the new style. - _, _, existingStyle, _ := screen.GetContent(x+posX, y+line-t.lineOffset) - _, background, _ := existingStyle.Decompose() - style := overlayStyle(background, defaultStyle, foregroundColor, backgroundColor, attributes) - - // Do we highlight this character? - var highlighted bool - if regionID != "" { - if _, ok := t.highlights[regionID]; ok { - highlighted = true - } - } - if highlighted { - fg, bg, _ := style.Decompose() - if bg == tcell.ColorDefault { - r, g, b := fg.RGB() - c := colorful.Color{R: float64(r) / 255, G: float64(g) / 255, B: float64(b) / 255} - _, _, li := c.Hcl() - if li < .5 { - bg = tcell.ColorWhite - } else { - bg = tcell.ColorBlack - } - } - style = style.Background(fg).Foreground(bg) - } - - // Skip to the right. - if !t.wrap && skipped < skip { - skipped += screenWidth - return false - } - - // Stop at the right border. - if posX+screenWidth > width || x+posX >= totalWidth { - return true - } - - // Draw the character. - for offset := screenWidth - 1; offset >= 0; offset-- { - if offset == 0 { - screen.SetContent(x+posX+offset, y+line-t.lineOffset, main, comb, style) - } else { - screen.SetContent(x+posX+offset, y+line-t.lineOffset, ' ', nil, style) - } - } - - // Advance. - posX += screenWidth - return false - }) - } - } - - // If this view is not scrollable, we'll purge the buffer of lines that have - // scrolled out of view. - if !t.scrollable && t.lineOffset > 0 { - if t.lineOffset >= len(t.index) { - t.buffer = nil - } else { - t.buffer = t.buffer[t.index[t.lineOffset].Line:] - } - t.index = nil - t.lineOffset = 0 - } -} - -// InputHandler returns the handler for this primitive. -func (t *TextView) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return t.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - key := event.Key() - - if key == tcell.KeyEscape || key == tcell.KeyEnter || key == tcell.KeyTab || key == tcell.KeyBacktab { - if t.done != nil { - t.done(key) - } - return - } - - if !t.scrollable { - return - } - - switch key { - case tcell.KeyRune: - switch event.Rune() { - case 'g': // Home. - t.trackEnd = false - t.lineOffset = 0 - t.columnOffset = 0 - case 'G': // End. - t.trackEnd = true - t.columnOffset = 0 - case 'j': // Down. - t.lineOffset++ - case 'k': // Up. - t.trackEnd = false - t.lineOffset-- - case 'h': // Left. - t.columnOffset-- - case 'l': // Right. - t.columnOffset++ - } - case tcell.KeyHome: - t.trackEnd = false - t.lineOffset = 0 - t.columnOffset = 0 - case tcell.KeyEnd: - t.trackEnd = true - t.columnOffset = 0 - case tcell.KeyUp: - t.trackEnd = false - t.lineOffset-- - case tcell.KeyDown: - t.lineOffset++ - case tcell.KeyLeft: - t.columnOffset-- - case tcell.KeyRight: - t.columnOffset++ - case tcell.KeyPgDn, tcell.KeyCtrlF: - t.lineOffset += t.pageSize - case tcell.KeyPgUp, tcell.KeyCtrlB: - t.trackEnd = false - t.lineOffset -= t.pageSize - } - }) -} - -// MouseHandler returns the mouse handler for this primitive. -func (t *TextView) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return t.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - x, y := event.Position() - if !t.InRect(x, y) { - return false, nil - } - - switch action { - case MouseLeftClick: - if t.regions { - // Find a region to highlight. - for _, region := range t.regionInfos { - if y == region.FromY && x < region.FromX || - y == region.ToY && x >= region.ToX || - region.FromY >= 0 && y < region.FromY || - region.ToY >= 0 && y > region.ToY { - continue - } - t.Highlight(region.ID) - break - } - } - setFocus(t) - consumed = true - case MouseScrollUp: - t.trackEnd = false - t.lineOffset-- - consumed = true - case MouseScrollDown: - t.lineOffset++ - consumed = true - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/treeview.go b/vendor/github.com/rivo/tview/treeview.go deleted file mode 100644 index 2deb7cd..0000000 --- a/vendor/github.com/rivo/tview/treeview.go +++ /dev/null @@ -1,787 +0,0 @@ -package tview - -import ( - "github.com/gdamore/tcell/v2" -) - -// Tree navigation events. -const ( - treeNone int = iota - treeHome - treeEnd - treeUp - treeDown - treePageUp - treePageDown -) - -// TreeNode represents one node in a tree view. -type TreeNode struct { - // The reference object. - reference interface{} - - // This node's child nodes. - children []*TreeNode - - // The item's text. - text string - - // The text color. - color tcell.Color - - // Whether or not this node can be selected. - selectable bool - - // Whether or not this node's children should be displayed. - expanded bool - - // The additional horizontal indent of this node's text. - indent int - - // An optional function which is called when the user selects this node. - selected func() - - // The hierarchy level (0 for the root, 1 for its children, and so on). This - // is only up to date immediately after a call to process() (e.g. via - // Draw()). - level int - - // Temporary member variables. - parent *TreeNode // The parent node (nil for the root). - graphicsX int // The x-coordinate of the left-most graphics rune. - textX int // The x-coordinate of the first rune of the text. -} - -// NewTreeNode returns a new tree node. -func NewTreeNode(text string) *TreeNode { - return &TreeNode{ - text: text, - color: Styles.PrimaryTextColor, - indent: 2, - expanded: true, - selectable: true, - } -} - -// Walk traverses this node's subtree in depth-first, pre-order (NLR) order and -// calls the provided callback function on each traversed node (which includes -// this node) with the traversed node and its parent node (nil for this node). -// The callback returns whether traversal should continue with the traversed -// node's child nodes (true) or not recurse any deeper (false). -func (n *TreeNode) Walk(callback func(node, parent *TreeNode) bool) *TreeNode { - n.parent = nil - nodes := []*TreeNode{n} - for len(nodes) > 0 { - // Pop the top node and process it. - node := nodes[len(nodes)-1] - nodes = nodes[:len(nodes)-1] - if !callback(node, node.parent) { - // Don't add any children. - continue - } - - // Add children in reverse order. - for index := len(node.children) - 1; index >= 0; index-- { - node.children[index].parent = node - nodes = append(nodes, node.children[index]) - } - } - - return n -} - -// SetReference allows you to store a reference of any type in this node. This -// will allow you to establish a mapping between the TreeView hierarchy and your -// internal tree structure. -func (n *TreeNode) SetReference(reference interface{}) *TreeNode { - n.reference = reference - return n -} - -// GetReference returns this node's reference object. -func (n *TreeNode) GetReference() interface{} { - return n.reference -} - -// SetChildren sets this node's child nodes. -func (n *TreeNode) SetChildren(childNodes []*TreeNode) *TreeNode { - n.children = childNodes - return n -} - -// GetText returns this node's text. -func (n *TreeNode) GetText() string { - return n.text -} - -// GetChildren returns this node's children. -func (n *TreeNode) GetChildren() []*TreeNode { - return n.children -} - -// ClearChildren removes all child nodes from this node. -func (n *TreeNode) ClearChildren() *TreeNode { - n.children = nil - return n -} - -// AddChild adds a new child node to this node. -func (n *TreeNode) AddChild(node *TreeNode) *TreeNode { - n.children = append(n.children, node) - return n -} - -// SetSelectable sets a flag indicating whether this node can be selected by -// the user. -func (n *TreeNode) SetSelectable(selectable bool) *TreeNode { - n.selectable = selectable - return n -} - -// SetSelectedFunc sets a function which is called when the user selects this -// node by hitting Enter when it is selected. -func (n *TreeNode) SetSelectedFunc(handler func()) *TreeNode { - n.selected = handler - return n -} - -// SetExpanded sets whether or not this node's child nodes should be displayed. -func (n *TreeNode) SetExpanded(expanded bool) *TreeNode { - n.expanded = expanded - return n -} - -// Expand makes the child nodes of this node appear. -func (n *TreeNode) Expand() *TreeNode { - n.expanded = true - return n -} - -// Collapse makes the child nodes of this node disappear. -func (n *TreeNode) Collapse() *TreeNode { - n.expanded = false - return n -} - -// ExpandAll expands this node and all descendent nodes. -func (n *TreeNode) ExpandAll() *TreeNode { - n.Walk(func(node, parent *TreeNode) bool { - node.expanded = true - return true - }) - return n -} - -// CollapseAll collapses this node and all descendent nodes. -func (n *TreeNode) CollapseAll() *TreeNode { - n.Walk(func(node, parent *TreeNode) bool { - n.expanded = false - return true - }) - return n -} - -// IsExpanded returns whether the child nodes of this node are visible. -func (n *TreeNode) IsExpanded() bool { - return n.expanded -} - -// SetText sets the node's text which is displayed. -func (n *TreeNode) SetText(text string) *TreeNode { - n.text = text - return n -} - -// GetColor returns the node's color. -func (n *TreeNode) GetColor() tcell.Color { - return n.color -} - -// SetColor sets the node's text color. -func (n *TreeNode) SetColor(color tcell.Color) *TreeNode { - n.color = color - return n -} - -// SetIndent sets an additional indentation for this node's text. A value of 0 -// keeps the text as far left as possible with a minimum of line graphics. Any -// value greater than that moves the text to the right. -func (n *TreeNode) SetIndent(indent int) *TreeNode { - n.indent = indent - return n -} - -// GetLevel returns the node's level within the hierarchy, where 0 corresponds -// to the root node, 1 corresponds to its children, and so on. This is only -// guaranteed to be up to date immediately after the tree that contains this -// node is drawn. -func (n *TreeNode) GetLevel() int { - return n.level -} - -// TreeView displays tree structures. A tree consists of nodes (TreeNode -// objects) where each node has zero or more child nodes and exactly one parent -// node (except for the root node which has no parent node). -// -// The SetRoot() function is used to specify the root of the tree. Other nodes -// are added locally to the root node or any of its descendents. See the -// TreeNode documentation for details on node attributes. (You can use -// SetReference() to store a reference to nodes of your own tree structure.) -// -// Nodes can be selected by calling SetCurrentNode(). The user can navigate the -// selection or the tree by using the following keys: -// -// - j, down arrow, right arrow: Move (the selection) down by one node. -// - k, up arrow, left arrow: Move (the selection) up by one node. -// - g, home: Move (the selection) to the top. -// - G, end: Move (the selection) to the bottom. -// - Ctrl-F, page down: Move (the selection) down by one page. -// - Ctrl-B, page up: Move (the selection) up by one page. -// -// Selected nodes can trigger the "selected" callback when the user hits Enter. -// -// The root node corresponds to level 0, its children correspond to level 1, -// their children to level 2, and so on. Per default, the first level that is -// displayed is 0, i.e. the root node. You can call SetTopLevel() to hide -// levels. -// -// If graphics are turned on (see SetGraphics()), lines indicate the tree's -// hierarchy. Alternative (or additionally), you can set different prefixes -// using SetPrefixes() for different levels, for example to display hierarchical -// bullet point lists. -// -// See https://github.com/rivo/tview/wiki/TreeView for an example. -type TreeView struct { - *Box - - // The root node. - root *TreeNode - - // The currently selected node or nil if no node is selected. - currentNode *TreeNode - - // The movement to be performed during the call to Draw(), one of the - // constants defined above. - movement int - - // The top hierarchical level shown. (0 corresponds to the root level.) - topLevel int - - // Strings drawn before the nodes, based on their level. - prefixes []string - - // Vertical scroll offset. - offsetY int - - // If set to true, all node texts will be aligned horizontally. - align bool - - // If set to true, the tree structure is drawn using lines. - graphics bool - - // The color of the lines. - graphicsColor tcell.Color - - // An optional function which is called when the user has navigated to a new - // tree node. - changed func(node *TreeNode) - - // An optional function which is called when a tree item was selected. - selected func(node *TreeNode) - - // An optional function which is called when the user moves away from this - // primitive. - done func(key tcell.Key) - - // The visible nodes, top-down, as set by process(). - nodes []*TreeNode -} - -// NewTreeView returns a new tree view. -func NewTreeView() *TreeView { - return &TreeView{ - Box: NewBox(), - graphics: true, - graphicsColor: Styles.GraphicsColor, - } -} - -// SetRoot sets the root node of the tree. -func (t *TreeView) SetRoot(root *TreeNode) *TreeView { - t.root = root - return t -} - -// GetRoot returns the root node of the tree. If no such node was previously -// set, nil is returned. -func (t *TreeView) GetRoot() *TreeNode { - return t.root -} - -// SetCurrentNode sets the currently selected node. Provide nil to clear all -// selections. Selected nodes must be visible and selectable, or else the -// selection will be changed to the top-most selectable and visible node. -// -// This function does NOT trigger the "changed" callback. -func (t *TreeView) SetCurrentNode(node *TreeNode) *TreeView { - t.currentNode = node - return t -} - -// GetCurrentNode returns the currently selected node or nil of no node is -// currently selected. -func (t *TreeView) GetCurrentNode() *TreeNode { - return t.currentNode -} - -// SetTopLevel sets the first tree level that is visible with 0 referring to the -// root, 1 to the root's child nodes, and so on. Nodes above the top level are -// not displayed. -func (t *TreeView) SetTopLevel(topLevel int) *TreeView { - t.topLevel = topLevel - return t -} - -// SetPrefixes defines the strings drawn before the nodes' texts. This is a -// slice of strings where each element corresponds to a node's hierarchy level, -// i.e. 0 for the root, 1 for the root's children, and so on (levels will -// cycle). -// -// For example, to display a hierarchical list with bullet points: -// -// treeView.SetGraphics(false). -// SetPrefixes([]string{"* ", "- ", "x "}) -func (t *TreeView) SetPrefixes(prefixes []string) *TreeView { - t.prefixes = prefixes - return t -} - -// SetAlign controls the horizontal alignment of the node texts. If set to true, -// all texts except that of top-level nodes will be placed in the same column. -// If set to false, they will indent with the hierarchy. -func (t *TreeView) SetAlign(align bool) *TreeView { - t.align = align - return t -} - -// SetGraphics sets a flag which determines whether or not line graphics are -// drawn to illustrate the tree's hierarchy. -func (t *TreeView) SetGraphics(showGraphics bool) *TreeView { - t.graphics = showGraphics - return t -} - -// SetGraphicsColor sets the colors of the lines used to draw the tree structure. -func (t *TreeView) SetGraphicsColor(color tcell.Color) *TreeView { - t.graphicsColor = color - return t -} - -// SetChangedFunc sets the function which is called when the user navigates to -// a new tree node. -func (t *TreeView) SetChangedFunc(handler func(node *TreeNode)) *TreeView { - t.changed = handler - return t -} - -// SetSelectedFunc sets the function which is called when the user selects a -// node by pressing Enter on the current selection. -func (t *TreeView) SetSelectedFunc(handler func(node *TreeNode)) *TreeView { - t.selected = handler - return t -} - -// SetDoneFunc sets a handler which is called whenever the user presses the -// Escape, Tab, or Backtab key. -func (t *TreeView) SetDoneFunc(handler func(key tcell.Key)) *TreeView { - t.done = handler - return t -} - -// GetScrollOffset returns the number of node rows that were skipped at the top -// of the tree view. Note that when the user navigates the tree view, this value -// is only updated after the tree view has been redrawn. -func (t *TreeView) GetScrollOffset() int { - return t.offsetY -} - -// GetRowCount returns the number of "visible" nodes. This includes nodes which -// fall outside the tree view's box but notably does not include the children -// of collapsed nodes. Note that this value is only up to date after the tree -// view has been drawn. -func (t *TreeView) GetRowCount() int { - return len(t.nodes) -} - -// process builds the visible tree, populates the "nodes" slice, and processes -// pending selection actions. -func (t *TreeView) process() { - _, _, _, height := t.GetInnerRect() - - // Determine visible nodes and their placement. - var graphicsOffset, maxTextX int - t.nodes = nil - if t.root == nil { - return - } - selectedIndex := -1 - topLevelGraphicsX := -1 - if t.graphics { - graphicsOffset = 1 - } - t.root.Walk(func(node, parent *TreeNode) bool { - // Set node attributes. - node.parent = parent - if parent == nil { - node.level = 0 - node.graphicsX = 0 - node.textX = 0 - } else { - node.level = parent.level + 1 - node.graphicsX = parent.textX - node.textX = node.graphicsX + graphicsOffset + node.indent - } - if !t.graphics && t.align { - // Without graphics, we align nodes on the first column. - node.textX = 0 - } - if node.level == t.topLevel { - // No graphics for top level nodes. - node.graphicsX = 0 - node.textX = 0 - } - - // Add the node to the list. - if node.level >= t.topLevel { - // This node will be visible. - if node.textX > maxTextX { - maxTextX = node.textX - } - if node == t.currentNode && node.selectable { - selectedIndex = len(t.nodes) - } - - // Maybe we want to skip this level. - if t.topLevel == node.level && (topLevelGraphicsX < 0 || node.graphicsX < topLevelGraphicsX) { - topLevelGraphicsX = node.graphicsX - } - - t.nodes = append(t.nodes, node) - } - - // Recurse if desired. - return node.expanded - }) - - // Post-process positions. - for _, node := range t.nodes { - // If text must align, we correct the positions. - if t.align && node.level > t.topLevel { - node.textX = maxTextX - } - - // If we skipped levels, shift to the left. - if topLevelGraphicsX > 0 { - node.graphicsX -= topLevelGraphicsX - node.textX -= topLevelGraphicsX - } - } - - // Process selection. (Also trigger events if necessary.) - if selectedIndex >= 0 { - // Move the selection. - newSelectedIndex := selectedIndex - MovementSwitch: - switch t.movement { - case treeUp: - for newSelectedIndex > 0 { - newSelectedIndex-- - if t.nodes[newSelectedIndex].selectable { - break MovementSwitch - } - } - newSelectedIndex = selectedIndex - case treeDown: - for newSelectedIndex < len(t.nodes)-1 { - newSelectedIndex++ - if t.nodes[newSelectedIndex].selectable { - break MovementSwitch - } - } - newSelectedIndex = selectedIndex - case treeHome: - for newSelectedIndex = 0; newSelectedIndex < len(t.nodes); newSelectedIndex++ { - if t.nodes[newSelectedIndex].selectable { - break MovementSwitch - } - } - newSelectedIndex = selectedIndex - case treeEnd: - for newSelectedIndex = len(t.nodes) - 1; newSelectedIndex >= 0; newSelectedIndex-- { - if t.nodes[newSelectedIndex].selectable { - break MovementSwitch - } - } - newSelectedIndex = selectedIndex - case treePageDown: - if newSelectedIndex+height < len(t.nodes) { - newSelectedIndex += height - } else { - newSelectedIndex = len(t.nodes) - 1 - } - for ; newSelectedIndex < len(t.nodes); newSelectedIndex++ { - if t.nodes[newSelectedIndex].selectable { - break MovementSwitch - } - } - newSelectedIndex = selectedIndex - case treePageUp: - if newSelectedIndex >= height { - newSelectedIndex -= height - } else { - newSelectedIndex = 0 - } - for ; newSelectedIndex >= 0; newSelectedIndex-- { - if t.nodes[newSelectedIndex].selectable { - break MovementSwitch - } - } - newSelectedIndex = selectedIndex - } - t.currentNode = t.nodes[newSelectedIndex] - if newSelectedIndex != selectedIndex { - t.movement = treeNone - if t.changed != nil { - t.changed(t.currentNode) - } - } - selectedIndex = newSelectedIndex - - // Move selection into viewport. - if selectedIndex-t.offsetY >= height { - t.offsetY = selectedIndex - height + 1 - } - if selectedIndex < t.offsetY { - t.offsetY = selectedIndex - } - } else { - // If selection is not visible or selectable, select the first candidate. - if t.currentNode != nil { - for index, node := range t.nodes { - if node.selectable { - selectedIndex = index - t.currentNode = node - break - } - } - } - if selectedIndex < 0 { - t.currentNode = nil - } - } -} - -// Draw draws this primitive onto the screen. -func (t *TreeView) Draw(screen tcell.Screen) { - t.Box.DrawForSubclass(screen, t) - if t.root == nil { - return - } - _, totalHeight := screen.Size() - - t.process() - - // Scroll the tree. - x, y, width, height := t.GetInnerRect() - switch t.movement { - case treeUp: - t.offsetY-- - case treeDown: - t.offsetY++ - case treeHome: - t.offsetY = 0 - case treeEnd: - t.offsetY = len(t.nodes) - case treePageUp: - t.offsetY -= height - case treePageDown: - t.offsetY += height - } - t.movement = treeNone - - // Fix invalid offsets. - if t.offsetY >= len(t.nodes)-height { - t.offsetY = len(t.nodes) - height - } - if t.offsetY < 0 { - t.offsetY = 0 - } - - // Draw the tree. - posY := y - lineStyle := tcell.StyleDefault.Background(t.backgroundColor).Foreground(t.graphicsColor) - for index, node := range t.nodes { - // Skip invisible parts. - if posY >= y+height+1 || posY >= totalHeight { - break - } - if index < t.offsetY { - continue - } - - // Draw the graphics. - if t.graphics { - // Draw ancestor branches. - ancestor := node.parent - for ancestor != nil && ancestor.parent != nil && ancestor.parent.level >= t.topLevel { - if ancestor.graphicsX >= width { - continue - } - - // Draw a branch if this ancestor is not a last child. - if ancestor.parent.children[len(ancestor.parent.children)-1] != ancestor { - if posY-1 >= y && ancestor.textX > ancestor.graphicsX { - PrintJoinedSemigraphics(screen, x+ancestor.graphicsX, posY-1, Borders.Vertical, t.graphicsColor) - } - if posY < y+height { - screen.SetContent(x+ancestor.graphicsX, posY, Borders.Vertical, nil, lineStyle) - } - } - ancestor = ancestor.parent - } - - if node.textX > node.graphicsX && node.graphicsX < width { - // Connect to the node above. - if posY-1 >= y && t.nodes[index-1].graphicsX <= node.graphicsX && t.nodes[index-1].textX > node.graphicsX { - PrintJoinedSemigraphics(screen, x+node.graphicsX, posY-1, Borders.TopLeft, t.graphicsColor) - } - - // Join this node. - if posY < y+height { - screen.SetContent(x+node.graphicsX, posY, Borders.BottomLeft, nil, lineStyle) - for pos := node.graphicsX + 1; pos < node.textX && pos < width; pos++ { - screen.SetContent(x+pos, posY, Borders.Horizontal, nil, lineStyle) - } - } - } - } - - // Draw the prefix and the text. - if node.textX < width && posY < y+height { - // Prefix. - var prefixWidth int - if len(t.prefixes) > 0 { - _, prefixWidth = Print(screen, t.prefixes[(node.level-t.topLevel)%len(t.prefixes)], x+node.textX, posY, width-node.textX, AlignLeft, node.color) - } - - // Text. - if node.textX+prefixWidth < width { - style := tcell.StyleDefault.Foreground(node.color) - if node == t.currentNode { - style = tcell.StyleDefault.Background(node.color).Foreground(t.backgroundColor) - } - printWithStyle(screen, node.text, x+node.textX+prefixWidth, posY, width-node.textX-prefixWidth, AlignLeft, style) - } - } - - // Advance. - posY++ - } -} - -// InputHandler returns the handler for this primitive. -func (t *TreeView) InputHandler() func(event *tcell.EventKey, setFocus func(p Primitive)) { - return t.WrapInputHandler(func(event *tcell.EventKey, setFocus func(p Primitive)) { - selectNode := func() { - node := t.currentNode - if node != nil { - if t.selected != nil { - t.selected(node) - } - if node.selected != nil { - node.selected() - } - } - } - - // Because the tree is flattened into a list only at drawing time, we also - // postpone the (selection) movement to drawing time. - switch key := event.Key(); key { - case tcell.KeyTab, tcell.KeyBacktab, tcell.KeyEscape: - if t.done != nil { - t.done(key) - } - case tcell.KeyDown, tcell.KeyRight: - t.movement = treeDown - case tcell.KeyUp, tcell.KeyLeft: - t.movement = treeUp - case tcell.KeyHome: - t.movement = treeHome - case tcell.KeyEnd: - t.movement = treeEnd - case tcell.KeyPgDn, tcell.KeyCtrlF: - t.movement = treePageDown - case tcell.KeyPgUp, tcell.KeyCtrlB: - t.movement = treePageUp - case tcell.KeyRune: - switch event.Rune() { - case 'g': - t.movement = treeHome - case 'G': - t.movement = treeEnd - case 'j': - t.movement = treeDown - case 'k': - t.movement = treeUp - case ' ': - selectNode() - } - case tcell.KeyEnter: - selectNode() - } - - t.process() - }) -} - -// MouseHandler returns the mouse handler for this primitive. -func (t *TreeView) MouseHandler() func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - return t.WrapMouseHandler(func(action MouseAction, event *tcell.EventMouse, setFocus func(p Primitive)) (consumed bool, capture Primitive) { - x, y := event.Position() - if !t.InRect(x, y) { - return false, nil - } - - switch action { - case MouseLeftClick: - setFocus(t) - _, rectY, _, _ := t.GetInnerRect() - y += t.offsetY - rectY - if y >= 0 && y < len(t.nodes) { - node := t.nodes[y] - if node.selectable { - previousNode := t.currentNode - t.currentNode = node - if previousNode != node && t.changed != nil { - t.changed(node) - } - if t.selected != nil { - t.selected(node) - } - if node.selected != nil { - node.selected() - } - } - } - consumed = true - case MouseScrollUp: - t.movement = treeUp - consumed = true - case MouseScrollDown: - t.movement = treeDown - consumed = true - } - - return - }) -} diff --git a/vendor/github.com/rivo/tview/tview.gif b/vendor/github.com/rivo/tview/tview.gif deleted file mode 100644 index 0583d7b..0000000 Binary files a/vendor/github.com/rivo/tview/tview.gif and /dev/null differ diff --git a/vendor/github.com/rivo/tview/util.go b/vendor/github.com/rivo/tview/util.go deleted file mode 100644 index 2e19160..0000000 --- a/vendor/github.com/rivo/tview/util.go +++ /dev/null @@ -1,642 +0,0 @@ -package tview - -import ( - "math" - "regexp" - "sort" - "strconv" - - "github.com/gdamore/tcell/v2" - runewidth "github.com/mattn/go-runewidth" - "github.com/rivo/uniseg" -) - -// Text alignment within a box. -const ( - AlignLeft = iota - AlignCenter - AlignRight -) - -// Common regular expressions. -var ( - colorPattern = regexp.MustCompile(`\[([a-zA-Z]+|#[0-9a-zA-Z]{6}|\-)?(:([a-zA-Z]+|#[0-9a-zA-Z]{6}|\-)?(:([lbdru]+|\-)?)?)?\]`) - regionPattern = regexp.MustCompile(`\["([a-zA-Z0-9_,;: \-\.]*)"\]`) - escapePattern = regexp.MustCompile(`\[([a-zA-Z0-9_,;: \-\."#]+)\[(\[*)\]`) - nonEscapePattern = regexp.MustCompile(`(\[[a-zA-Z0-9_,;: \-\."#]+\[*)\]`) - boundaryPattern = regexp.MustCompile(`(([,\.\-:;!\?&#+]|\n)[ \t\f\r]*|([ \t\f\r]+))`) - spacePattern = regexp.MustCompile(`\s+`) -) - -// Positions of substrings in regular expressions. -const ( - colorForegroundPos = 1 - colorBackgroundPos = 3 - colorFlagPos = 5 -) - -// Predefined InputField acceptance functions. -var ( - // InputFieldInteger accepts integers. - InputFieldInteger func(text string, ch rune) bool - - // InputFieldFloat accepts floating-point numbers. - InputFieldFloat func(text string, ch rune) bool - - // InputFieldMaxLength returns an input field accept handler which accepts - // input strings up to a given length. Use it like this: - // - // inputField.SetAcceptanceFunc(InputFieldMaxLength(10)) // Accept up to 10 characters. - InputFieldMaxLength func(maxLength int) func(text string, ch rune) bool -) - -// Package initialization. -func init() { - // We'll use zero width joiners. - runewidth.ZeroWidthJoiner = true - - // Initialize the predefined input field handlers. - InputFieldInteger = func(text string, ch rune) bool { - if text == "-" { - return true - } - _, err := strconv.Atoi(text) - return err == nil - } - InputFieldFloat = func(text string, ch rune) bool { - if text == "-" || text == "." || text == "-." { - return true - } - _, err := strconv.ParseFloat(text, 64) - return err == nil - } - InputFieldMaxLength = func(maxLength int) func(text string, ch rune) bool { - return func(text string, ch rune) bool { - return len([]rune(text)) <= maxLength - } - } -} - -// styleFromTag takes the given style, defined by a foreground color (fgColor), -// a background color (bgColor), and style attributes, and modifies it based on -// the substrings (tagSubstrings) extracted by the regular expression for color -// tags. The new colors and attributes are returned where empty strings mean -// "don't modify" and a dash ("-") means "reset to default". -func styleFromTag(fgColor, bgColor, attributes string, tagSubstrings []string) (newFgColor, newBgColor, newAttributes string) { - if tagSubstrings[colorForegroundPos] != "" { - color := tagSubstrings[colorForegroundPos] - if color == "-" { - fgColor = "-" - } else if color != "" { - fgColor = color - } - } - - if tagSubstrings[colorBackgroundPos-1] != "" { - color := tagSubstrings[colorBackgroundPos] - if color == "-" { - bgColor = "-" - } else if color != "" { - bgColor = color - } - } - - if tagSubstrings[colorFlagPos-1] != "" { - flags := tagSubstrings[colorFlagPos] - if flags == "-" { - attributes = "-" - } else if flags != "" { - attributes = flags - } - } - - return fgColor, bgColor, attributes -} - -// overlayStyle mixes a background color with a foreground color (fgColor), -// a (possibly new) background color (bgColor), and style attributes, and -// returns the resulting style. For a definition of the colors and attributes, -// see styleFromTag(). Reset instructions cause the corresponding part of the -// default style to be used. -func overlayStyle(background tcell.Color, defaultStyle tcell.Style, fgColor, bgColor, attributes string) tcell.Style { - defFg, defBg, defAttr := defaultStyle.Decompose() - style := defaultStyle.Background(background) - - style = style.Foreground(defFg) - if fgColor != "" { - if fgColor == "-" { - style = style.Foreground(defFg) - } else { - style = style.Foreground(tcell.GetColor(fgColor)) - } - } - - if bgColor == "-" || bgColor == "" && defBg != tcell.ColorDefault { - style = style.Background(defBg) - } else if bgColor != "" { - style = style.Background(tcell.GetColor(bgColor)) - } - - if attributes == "-" { - style = style.Bold(defAttr&tcell.AttrBold > 0) - style = style.Blink(defAttr&tcell.AttrBlink > 0) - style = style.Reverse(defAttr&tcell.AttrReverse > 0) - style = style.Underline(defAttr&tcell.AttrUnderline > 0) - style = style.Dim(defAttr&tcell.AttrDim > 0) - } else if attributes != "" { - style = style.Normal() - for _, flag := range attributes { - switch flag { - case 'l': - style = style.Blink(true) - case 'b': - style = style.Bold(true) - case 'd': - style = style.Dim(true) - case 'r': - style = style.Reverse(true) - case 'u': - style = style.Underline(true) - } - } - } - - return style -} - -// decomposeString returns information about a string which may contain color -// tags or region tags, depending on which ones are requested to be found. It -// returns the indices of the color tags (as returned by -// re.FindAllStringIndex()), the color tags themselves (as returned by -// re.FindAllStringSubmatch()), the indices of region tags and the region tags -// themselves, the indices of an escaped tags (only if at least color tags or -// region tags are requested), the string stripped by any tags and escaped, and -// the screen width of the stripped string. -func decomposeString(text string, findColors, findRegions bool) (colorIndices [][]int, colors [][]string, regionIndices [][]int, regions [][]string, escapeIndices [][]int, stripped string, width int) { - // Shortcut for the trivial case. - if !findColors && !findRegions { - return nil, nil, nil, nil, nil, text, stringWidth(text) - } - - // Get positions of any tags. - if findColors { - colorIndices = colorPattern.FindAllStringIndex(text, -1) - colors = colorPattern.FindAllStringSubmatch(text, -1) - } - if findRegions { - regionIndices = regionPattern.FindAllStringIndex(text, -1) - regions = regionPattern.FindAllStringSubmatch(text, -1) - } - escapeIndices = escapePattern.FindAllStringIndex(text, -1) - - // Because the color pattern detects empty tags, we need to filter them out. - for i := len(colorIndices) - 1; i >= 0; i-- { - if colorIndices[i][1]-colorIndices[i][0] == 2 { - colorIndices = append(colorIndices[:i], colorIndices[i+1:]...) - colors = append(colors[:i], colors[i+1:]...) - } - } - - // Make a (sorted) list of all tags. - allIndices := make([][3]int, 0, len(colorIndices)+len(regionIndices)+len(escapeIndices)) - for indexType, index := range [][][]int{colorIndices, regionIndices, escapeIndices} { - for _, tag := range index { - allIndices = append(allIndices, [3]int{tag[0], tag[1], indexType}) - } - } - sort.Slice(allIndices, func(i int, j int) bool { - return allIndices[i][0] < allIndices[j][0] - }) - - // Remove the tags from the original string. - var from int - buf := make([]byte, 0, len(text)) - for _, indices := range allIndices { - if indices[2] == 2 { // Escape sequences are not simply removed. - buf = append(buf, []byte(text[from:indices[1]-2])...) - buf = append(buf, ']') - from = indices[1] - } else { - buf = append(buf, []byte(text[from:indices[0]])...) - from = indices[1] - } - } - buf = append(buf, text[from:]...) - stripped = string(buf) - - // Get the width of the stripped string. - width = stringWidth(stripped) - - return -} - -// Print prints text onto the screen into the given box at (x,y,maxWidth,1), -// not exceeding that box. "align" is one of AlignLeft, AlignCenter, or -// AlignRight. The screen's background color will not be changed. -// -// You can change the colors and text styles mid-text by inserting a color tag. -// See the package description for details. -// -// Returns the number of actual bytes of the text printed (including color tags) -// and the actual width used for the printed runes. -func Print(screen tcell.Screen, text string, x, y, maxWidth, align int, color tcell.Color) (int, int) { - return printWithStyle(screen, text, x, y, maxWidth, align, tcell.StyleDefault.Foreground(color)) -} - -// printWithStyle works like Print() but it takes a style instead of just a -// foreground color. -func printWithStyle(screen tcell.Screen, text string, x, y, maxWidth, align int, style tcell.Style) (int, int) { - totalWidth, totalHeight := screen.Size() - if maxWidth <= 0 || len(text) == 0 || y < 0 || y >= totalHeight { - return 0, 0 - } - - // Decompose the text. - colorIndices, colors, _, _, escapeIndices, strippedText, strippedWidth := decomposeString(text, true, false) - - // We want to reduce all alignments to AlignLeft. - if align == AlignRight { - if strippedWidth <= maxWidth { - // There's enough space for the entire text. - return printWithStyle(screen, text, x+maxWidth-strippedWidth, y, maxWidth, AlignLeft, style) - } - // Trim characters off the beginning. - var ( - bytes, width, colorPos, escapePos, tagOffset int - foregroundColor, backgroundColor, attributes string - ) - _, originalBackground, _ := style.Decompose() - iterateString(strippedText, func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - // Update color/escape tag offset and style. - if colorPos < len(colorIndices) && textPos+tagOffset >= colorIndices[colorPos][0] && textPos+tagOffset < colorIndices[colorPos][1] { - foregroundColor, backgroundColor, attributes = styleFromTag(foregroundColor, backgroundColor, attributes, colors[colorPos]) - style = overlayStyle(originalBackground, style, foregroundColor, backgroundColor, attributes) - tagOffset += colorIndices[colorPos][1] - colorIndices[colorPos][0] - colorPos++ - } - if escapePos < len(escapeIndices) && textPos+tagOffset >= escapeIndices[escapePos][0] && textPos+tagOffset < escapeIndices[escapePos][1] { - tagOffset++ - escapePos++ - } - if strippedWidth-screenPos < maxWidth { - // We chopped off enough. - if escapePos > 0 && textPos+tagOffset-1 >= escapeIndices[escapePos-1][0] && textPos+tagOffset-1 < escapeIndices[escapePos-1][1] { - // Unescape open escape sequences. - escapeCharPos := escapeIndices[escapePos-1][1] - 2 - text = text[:escapeCharPos] + text[escapeCharPos+1:] - } - // Print and return. - bytes, width = printWithStyle(screen, text[textPos+tagOffset:], x, y, maxWidth, AlignLeft, style) - return true - } - return false - }) - return bytes, width - } else if align == AlignCenter { - if strippedWidth == maxWidth { - // Use the exact space. - return printWithStyle(screen, text, x, y, maxWidth, AlignLeft, style) - } else if strippedWidth < maxWidth { - // We have more space than we need. - half := (maxWidth - strippedWidth) / 2 - return printWithStyle(screen, text, x+half, y, maxWidth-half, AlignLeft, style) - } else { - // Chop off runes until we have a perfect fit. - var choppedLeft, choppedRight, leftIndex, rightIndex int - rightIndex = len(strippedText) - for rightIndex-1 > leftIndex && strippedWidth-choppedLeft-choppedRight > maxWidth { - if choppedLeft < choppedRight { - // Iterate on the left by one character. - iterateString(strippedText[leftIndex:], func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - choppedLeft += screenWidth - leftIndex += textWidth - return true - }) - } else { - // Iterate on the right by one character. - iterateStringReverse(strippedText[leftIndex:rightIndex], func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - choppedRight += screenWidth - rightIndex -= textWidth - return true - }) - } - } - - // Add tag offsets and determine start style. - var ( - colorPos, escapePos, tagOffset int - foregroundColor, backgroundColor, attributes string - ) - _, originalBackground, _ := style.Decompose() - for index := range strippedText { - // We only need the offset of the left index. - if index > leftIndex { - // We're done. - if escapePos > 0 && leftIndex+tagOffset-1 >= escapeIndices[escapePos-1][0] && leftIndex+tagOffset-1 < escapeIndices[escapePos-1][1] { - // Unescape open escape sequences. - escapeCharPos := escapeIndices[escapePos-1][1] - 2 - text = text[:escapeCharPos] + text[escapeCharPos+1:] - } - break - } - - // Update color/escape tag offset. - if colorPos < len(colorIndices) && index+tagOffset >= colorIndices[colorPos][0] && index+tagOffset < colorIndices[colorPos][1] { - if index <= leftIndex { - foregroundColor, backgroundColor, attributes = styleFromTag(foregroundColor, backgroundColor, attributes, colors[colorPos]) - style = overlayStyle(originalBackground, style, foregroundColor, backgroundColor, attributes) - } - tagOffset += colorIndices[colorPos][1] - colorIndices[colorPos][0] - colorPos++ - } - if escapePos < len(escapeIndices) && index+tagOffset >= escapeIndices[escapePos][0] && index+tagOffset < escapeIndices[escapePos][1] { - tagOffset++ - escapePos++ - } - } - return printWithStyle(screen, text[leftIndex+tagOffset:], x, y, maxWidth, AlignLeft, style) - } - } - - // Draw text. - var ( - drawn, drawnWidth, colorPos, escapePos, tagOffset int - foregroundColor, backgroundColor, attributes string - ) - iterateString(strippedText, func(main rune, comb []rune, textPos, length, screenPos, screenWidth int) bool { - // Only continue if there is still space. - if drawnWidth+screenWidth > maxWidth || x+drawnWidth >= totalWidth { - return true - } - - // Handle color tags. - for colorPos < len(colorIndices) && textPos+tagOffset >= colorIndices[colorPos][0] && textPos+tagOffset < colorIndices[colorPos][1] { - foregroundColor, backgroundColor, attributes = styleFromTag(foregroundColor, backgroundColor, attributes, colors[colorPos]) - tagOffset += colorIndices[colorPos][1] - colorIndices[colorPos][0] - colorPos++ - } - - // Handle scape tags. - if escapePos < len(escapeIndices) && textPos+tagOffset >= escapeIndices[escapePos][0] && textPos+tagOffset < escapeIndices[escapePos][1] { - if textPos+tagOffset == escapeIndices[escapePos][1]-2 { - tagOffset++ - escapePos++ - } - } - - // Print the rune sequence. - finalX := x + drawnWidth - _, _, finalStyle, _ := screen.GetContent(finalX, y) - _, background, _ := finalStyle.Decompose() - finalStyle = overlayStyle(background, style, foregroundColor, backgroundColor, attributes) - for offset := screenWidth - 1; offset >= 0; offset-- { - // To avoid undesired effects, we populate all cells. - if offset == 0 { - screen.SetContent(finalX+offset, y, main, comb, finalStyle) - } else { - screen.SetContent(finalX+offset, y, ' ', nil, finalStyle) - } - } - - // Advance. - drawn += length - drawnWidth += screenWidth - - return false - }) - - return drawn + tagOffset + len(escapeIndices), drawnWidth -} - -// PrintSimple prints white text to the screen at the given position. -func PrintSimple(screen tcell.Screen, text string, x, y int) { - Print(screen, text, x, y, math.MaxInt32, AlignLeft, Styles.PrimaryTextColor) -} - -// TaggedStringWidth returns the width of the given string needed to print it on -// screen. The text may contain color tags which are not counted. -func TaggedStringWidth(text string) int { - _, _, _, _, _, _, width := decomposeString(text, true, false) - return width -} - -// stringWidth returns the number of horizontal cells needed to print the given -// text. It splits the text into its grapheme clusters, calculates each -// cluster's width, and adds them up to a total. -func stringWidth(text string) (width int) { - g := uniseg.NewGraphemes(text) - for g.Next() { - var chWidth int - for _, r := range g.Runes() { - chWidth = runewidth.RuneWidth(r) - if chWidth > 0 { - break // Our best guess at this point is to use the width of the first non-zero-width rune. - } - } - width += chWidth - } - return -} - -// WordWrap splits a text such that each resulting line does not exceed the -// given screen width. Possible split points are after any punctuation or -// whitespace. Whitespace after split points will be dropped. -// -// This function considers color tags to have no width. -// -// Text is always split at newline characters ('\n'). -func WordWrap(text string, width int) (lines []string) { - colorTagIndices, _, _, _, escapeIndices, strippedText, _ := decomposeString(text, true, false) - - // Find candidate breakpoints. - breakpoints := boundaryPattern.FindAllStringSubmatchIndex(strippedText, -1) - // Results in one entry for each candidate. Each entry is an array a of - // indices into strippedText where a[6] < 0 for newline/punctuation matches - // and a[4] < 0 for whitespace matches. - - // Process stripped text one character at a time. - var ( - colorPos, escapePos, breakpointPos, tagOffset int - lastBreakpoint, lastContinuation, currentLineStart int - lineWidth, overflow int - forceBreak bool - ) - unescape := func(substr string, startIndex int) string { - // A helper function to unescape escaped tags. - for index := escapePos; index >= 0; index-- { - if index < len(escapeIndices) && startIndex > escapeIndices[index][0] && startIndex < escapeIndices[index][1]-1 { - pos := escapeIndices[index][1] - 2 - startIndex - return substr[:pos] + substr[pos+1:] - } - } - return substr - } - iterateString(strippedText, func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool { - // Handle tags. - for { - if colorPos < len(colorTagIndices) && textPos+tagOffset >= colorTagIndices[colorPos][0] && textPos+tagOffset < colorTagIndices[colorPos][1] { - // Colour tags. - tagOffset += colorTagIndices[colorPos][1] - colorTagIndices[colorPos][0] - colorPos++ - } else if escapePos < len(escapeIndices) && textPos+tagOffset == escapeIndices[escapePos][1]-2 { - // Escape tags. - tagOffset++ - escapePos++ - } else { - break - } - } - - // Is this a breakpoint? - if breakpointPos < len(breakpoints) && textPos+tagOffset == breakpoints[breakpointPos][0] { - // Yes, it is. Set up breakpoint infos depending on its type. - lastBreakpoint = breakpoints[breakpointPos][0] + tagOffset - lastContinuation = breakpoints[breakpointPos][1] + tagOffset - overflow = 0 - forceBreak = main == '\n' - if breakpoints[breakpointPos][6] < 0 && !forceBreak { - lastBreakpoint++ // Don't skip punctuation. - } - breakpointPos++ - } - - // Check if a break is warranted. - if forceBreak || lineWidth > 0 && lineWidth+screenWidth > width { - breakpoint := lastBreakpoint - continuation := lastContinuation - if forceBreak { - breakpoint = textPos + tagOffset - continuation = textPos + tagOffset + 1 - lastBreakpoint = 0 - overflow = 0 - } else if lastBreakpoint <= currentLineStart { - breakpoint = textPos + tagOffset - continuation = textPos + tagOffset - overflow = 0 - } - lines = append(lines, unescape(text[currentLineStart:breakpoint], currentLineStart)) - currentLineStart, lineWidth, forceBreak = continuation, overflow, false - } - - // Remember the characters since the last breakpoint. - if lastBreakpoint > 0 && lastContinuation <= textPos+tagOffset { - overflow += screenWidth - } - - // Advance. - lineWidth += screenWidth - - // But if we're still inside a breakpoint, skip next character (whitespace). - if textPos+tagOffset < currentLineStart { - lineWidth -= screenWidth - } - - return false - }) - - // Flush the rest. - if currentLineStart < len(text) { - lines = append(lines, unescape(text[currentLineStart:], currentLineStart)) - } - - return -} - -// Escape escapes the given text such that color and/or region tags are not -// recognized and substituted by the print functions of this package. For -// example, to include a tag-like string in a box title or in a TextView: -// -// box.SetTitle(tview.Escape("[squarebrackets]")) -// fmt.Fprint(textView, tview.Escape(`["quoted"]`)) -func Escape(text string) string { - return nonEscapePattern.ReplaceAllString(text, "$1[]") -} - -// iterateString iterates through the given string one printed character at a -// time. For each such character, the callback function is called with the -// Unicode code points of the character (the first rune and any combining runes -// which may be nil if there aren't any), the starting position (in bytes) -// within the original string, its length in bytes, the screen position of the -// character, and the screen width of it. The iteration stops if the callback -// returns true. This function returns true if the iteration was stopped before -// the last character. -func iterateString(text string, callback func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool) bool { - var screenPos int - - gr := uniseg.NewGraphemes(text) - for gr.Next() { - r := gr.Runes() - from, to := gr.Positions() - width := stringWidth(gr.Str()) - var comb []rune - if len(r) > 1 { - comb = r[1:] - } - - if callback(r[0], comb, from, to-from, screenPos, width) { - return true - } - - screenPos += width - } - - return false -} - -// iterateStringReverse iterates through the given string in reverse, starting -// from the end of the string, one printed character at a time. For each such -// character, the callback function is called with the Unicode code points of -// the character (the first rune and any combining runes which may be nil if -// there aren't any), the starting position (in bytes) within the original -// string, its length in bytes, the screen position of the character, and the -// screen width of it. The iteration stops if the callback returns true. This -// function returns true if the iteration was stopped before the last character. -func iterateStringReverse(text string, callback func(main rune, comb []rune, textPos, textWidth, screenPos, screenWidth int) bool) bool { - type cluster struct { - main rune - comb []rune - textPos, textWidth, screenPos, screenWidth int - } - - // Create the grapheme clusters. - var clusters []cluster - iterateString(text, func(main rune, comb []rune, textPos int, textWidth int, screenPos int, screenWidth int) bool { - clusters = append(clusters, cluster{ - main: main, - comb: comb, - textPos: textPos, - textWidth: textWidth, - screenPos: screenPos, - screenWidth: screenWidth, - }) - return false - }) - - // Iterate in reverse. - for index := len(clusters) - 1; index >= 0; index-- { - if callback( - clusters[index].main, - clusters[index].comb, - clusters[index].textPos, - clusters[index].textWidth, - clusters[index].screenPos, - clusters[index].screenWidth, - ) { - return true - } - } - - return false -} - -// stripTags strips colour tags from the given string. (Region tags are not -// stripped.) -func stripTags(text string) string { - stripped := colorPattern.ReplaceAllStringFunc(text, func(match string) string { - if len(match) > 2 { - return "" - } - return match - }) - return escapePattern.ReplaceAllString(stripped, `[$1$2]`) -} diff --git a/vendor/github.com/rivo/uniseg/README.md b/vendor/github.com/rivo/uniseg/README.md deleted file mode 100644 index f8da293..0000000 --- a/vendor/github.com/rivo/uniseg/README.md +++ /dev/null @@ -1,62 +0,0 @@ -# Unicode Text Segmentation for Go - -[![Godoc Reference](https://img.shields.io/badge/godoc-reference-blue.svg)](https://godoc.org/github.com/rivo/uniseg) -[![Go Report](https://img.shields.io/badge/go%20report-A%2B-brightgreen.svg)](https://goreportcard.com/report/github.com/rivo/uniseg) - -This Go package implements Unicode Text Segmentation according to [Unicode Standard Annex #29](http://unicode.org/reports/tr29/) (Unicode version 12.0.0). - -At this point, only the determination of grapheme cluster boundaries is implemented. - -## Background - -In Go, [strings are read-only slices of bytes](https://blog.golang.org/strings). They can be turned into Unicode code points using the `for` loop or by casting: `[]rune(str)`. However, multiple code points may be combined into one user-perceived character or what the Unicode specification calls "grapheme cluster". Here are some examples: - -|String|Bytes (UTF-8)|Code points (runes)|Grapheme clusters| -|-|-|-|-| -|Käse|6 bytes: `4b 61 cc 88 73 65`|5 code points: `4b 61 308 73 65`|4 clusters: `[4b],[61 308],[73],[65]`| -|🏳️‍🌈|14 bytes: `f0 9f 8f b3 ef b8 8f e2 80 8d f0 9f 8c 88`|4 code points: `1f3f3 fe0f 200d 1f308`|1 cluster: `[1f3f3 fe0f 200d 1f308]`| -|🇩🇪|8 bytes: `f0 9f 87 a9 f0 9f 87 aa`|2 code points: `1f1e9 1f1ea`|1 cluster: `[1f1e9 1f1ea]`| - -This package provides a tool to iterate over these grapheme clusters. This may be used to determine the number of user-perceived characters, to split strings in their intended places, or to extract individual characters which form a unit. - -## Installation - -```bash -go get github.com/rivo/uniseg -``` - -## Basic Example - -```go -package uniseg - -import ( - "fmt" - - "github.com/rivo/uniseg" -) - -func main() { - gr := uniseg.NewGraphemes("👍🏼!") - for gr.Next() { - fmt.Printf("%x ", gr.Runes()) - } - // Output: [1f44d 1f3fc] [21] -} -``` - -## Documentation - -Refer to https://godoc.org/github.com/rivo/uniseg for the package's documentation. - -## Dependencies - -This package does not depend on any packages outside the standard library. - -## Your Feedback - -Add your issue here on GitHub. Feel free to get in touch if you have any questions. - -## Version - -Version tags will be introduced once Golang modules are official. Consider this version 0.1. diff --git a/vendor/github.com/rivo/uniseg/doc.go b/vendor/github.com/rivo/uniseg/doc.go deleted file mode 100644 index 60c737d..0000000 --- a/vendor/github.com/rivo/uniseg/doc.go +++ /dev/null @@ -1,8 +0,0 @@ -/* -Package uniseg implements Unicode Text Segmentation according to Unicode -Standard Annex #29 (http://unicode.org/reports/tr29/). - -At this point, only the determination of grapheme cluster boundaries is -implemented. -*/ -package uniseg diff --git a/vendor/github.com/rivo/uniseg/go.mod b/vendor/github.com/rivo/uniseg/go.mod deleted file mode 100644 index a54280b..0000000 --- a/vendor/github.com/rivo/uniseg/go.mod +++ /dev/null @@ -1,3 +0,0 @@ -module github.com/rivo/uniseg - -go 1.12 diff --git a/vendor/github.com/rivo/uniseg/grapheme.go b/vendor/github.com/rivo/uniseg/grapheme.go deleted file mode 100644 index 207157f..0000000 --- a/vendor/github.com/rivo/uniseg/grapheme.go +++ /dev/null @@ -1,268 +0,0 @@ -package uniseg - -import "unicode/utf8" - -// The states of the grapheme cluster parser. -const ( - grAny = iota - grCR - grControlLF - grL - grLVV - grLVTT - grPrepend - grExtendedPictographic - grExtendedPictographicZWJ - grRIOdd - grRIEven -) - -// The grapheme cluster parser's breaking instructions. -const ( - grNoBoundary = iota - grBoundary -) - -// The grapheme cluster parser's state transitions. Maps (state, property) to -// (new state, breaking instruction, rule number). The breaking instruction -// always refers to the boundary between the last and next code point. -// -// This map is queried as follows: -// -// 1. Find specific state + specific property. Stop if found. -// 2. Find specific state + any property. -// 3. Find any state + specific property. -// 4. If only (2) or (3) (but not both) was found, stop. -// 5. If both (2) and (3) were found, use state and breaking instruction from -// the transition with the lower rule number, prefer (3) if rule numbers -// are equal. Stop. -// 6. Assume grAny and grBoundary. -var grTransitions = map[[2]int][3]int{ - // GB5 - {grAny, prCR}: {grCR, grBoundary, 50}, - {grAny, prLF}: {grControlLF, grBoundary, 50}, - {grAny, prControl}: {grControlLF, grBoundary, 50}, - - // GB4 - {grCR, prAny}: {grAny, grBoundary, 40}, - {grControlLF, prAny}: {grAny, grBoundary, 40}, - - // GB3. - {grCR, prLF}: {grAny, grNoBoundary, 30}, - - // GB6. - {grAny, prL}: {grL, grBoundary, 9990}, - {grL, prL}: {grL, grNoBoundary, 60}, - {grL, prV}: {grLVV, grNoBoundary, 60}, - {grL, prLV}: {grLVV, grNoBoundary, 60}, - {grL, prLVT}: {grLVTT, grNoBoundary, 60}, - - // GB7. - {grAny, prLV}: {grLVV, grBoundary, 9990}, - {grAny, prV}: {grLVV, grBoundary, 9990}, - {grLVV, prV}: {grLVV, grNoBoundary, 70}, - {grLVV, prT}: {grLVTT, grNoBoundary, 70}, - - // GB8. - {grAny, prLVT}: {grLVTT, grBoundary, 9990}, - {grAny, prT}: {grLVTT, grBoundary, 9990}, - {grLVTT, prT}: {grLVTT, grNoBoundary, 80}, - - // GB9. - {grAny, prExtend}: {grAny, grNoBoundary, 90}, - {grAny, prZWJ}: {grAny, grNoBoundary, 90}, - - // GB9a. - {grAny, prSpacingMark}: {grAny, grNoBoundary, 91}, - - // GB9b. - {grAny, prPreprend}: {grPrepend, grBoundary, 9990}, - {grPrepend, prAny}: {grAny, grNoBoundary, 92}, - - // GB11. - {grAny, prExtendedPictographic}: {grExtendedPictographic, grBoundary, 9990}, - {grExtendedPictographic, prExtend}: {grExtendedPictographic, grNoBoundary, 110}, - {grExtendedPictographic, prZWJ}: {grExtendedPictographicZWJ, grNoBoundary, 110}, - {grExtendedPictographicZWJ, prExtendedPictographic}: {grExtendedPictographic, grNoBoundary, 110}, - - // GB12 / GB13. - {grAny, prRegionalIndicator}: {grRIOdd, grBoundary, 9990}, - {grRIOdd, prRegionalIndicator}: {grRIEven, grNoBoundary, 120}, - {grRIEven, prRegionalIndicator}: {grRIOdd, grBoundary, 120}, -} - -// Graphemes implements an iterator over Unicode extended grapheme clusters, -// specified in the Unicode Standard Annex #29. Grapheme clusters correspond to -// "user-perceived characters". These characters often consist of multiple -// code points (e.g. the "woman kissing woman" emoji consists of 8 code points: -// woman + ZWJ + heavy black heart (2 code points) + ZWJ + kiss mark + ZWJ + -// woman) and the rules described in Annex #29 must be applied to group those -// code points into clusters perceived by the user as one character. -type Graphemes struct { - // The code points over which this class iterates. - codePoints []rune - - // The (byte-based) indices of the code points into the original string plus - // len(original string). Thus, len(indices) = len(codePoints) + 1. - indices []int - - // The current grapheme cluster to be returned. These are indices into - // codePoints/indices. If start == end, we either haven't started iterating - // yet (0) or the iteration has already completed (1). - start, end int - - // The index of the next code point to be parsed. - pos int - - // The current state of the code point parser. - state int -} - -// NewGraphemes returns a new grapheme cluster iterator. -func NewGraphemes(s string) *Graphemes { - l := utf8.RuneCountInString(s) - codePoints := make([]rune, l) - indices := make([]int, l+1) - i := 0 - for pos, r := range s { - codePoints[i] = r - indices[i] = pos - i++ - } - indices[l] = len(s) - g := &Graphemes{ - codePoints: codePoints, - indices: indices, - } - g.Next() // Parse ahead. - return g -} - -// Next advances the iterator by one grapheme cluster and returns false if no -// clusters are left. This function must be called before the first cluster is -// accessed. -func (g *Graphemes) Next() bool { - g.start = g.end - - // The state transition gives us a boundary instruction BEFORE the next code - // point so we always need to stay ahead by one code point. - - // Parse the next code point. - for g.pos <= len(g.codePoints) { - // GB2. - if g.pos == len(g.codePoints) { - g.end = g.pos - g.pos++ - break - } - - // Determine the property of the next character. - nextProperty := property(g.codePoints[g.pos]) - g.pos++ - - // Find the applicable transition. - var boundary bool - transition, ok := grTransitions[[2]int{g.state, nextProperty}] - if ok { - // We have a specific transition. We'll use it. - g.state = transition[0] - boundary = transition[1] == grBoundary - } else { - // No specific transition found. Try the less specific ones. - transAnyProp, okAnyProp := grTransitions[[2]int{g.state, prAny}] - transAnyState, okAnyState := grTransitions[[2]int{grAny, nextProperty}] - if okAnyProp && okAnyState { - // Both apply. We'll use a mix (see comments for grTransitions). - g.state = transAnyState[0] - boundary = transAnyState[1] == grBoundary - if transAnyProp[2] < transAnyState[2] { - g.state = transAnyProp[0] - boundary = transAnyProp[1] == grBoundary - } - } else if okAnyProp { - // We only have a specific state. - g.state = transAnyProp[0] - boundary = transAnyProp[1] == grBoundary - // This branch will probably never be reached because okAnyState will - // always be true given the current transition map. But we keep it here - // for future modifications to the transition map where this may not be - // true anymore. - } else if okAnyState { - // We only have a specific property. - g.state = transAnyState[0] - boundary = transAnyState[1] == grBoundary - } else { - // No known transition. GB999: Any x Any. - g.state = grAny - boundary = true - } - } - - // If we found a cluster boundary, let's stop here. The current cluster will - // be the one that just ended. - if g.pos-1 == 0 /* GB1 */ || boundary { - g.end = g.pos - 1 - break - } - } - - return g.start != g.end -} - -// Runes returns a slice of runes (code points) which corresponds to the current -// grapheme cluster. If the iterator is already past the end or Next() has not -// yet been called, nil is returned. -func (g *Graphemes) Runes() []rune { - if g.start == g.end { - return nil - } - return g.codePoints[g.start:g.end] -} - -// Str returns a substring of the original string which corresponds to the -// current grapheme cluster. If the iterator is already past the end or Next() -// has not yet been called, an empty string is returned. -func (g *Graphemes) Str() string { - if g.start == g.end { - return "" - } - return string(g.codePoints[g.start:g.end]) -} - -// Bytes returns a byte slice which corresponds to the current grapheme cluster. -// If the iterator is already past the end or Next() has not yet been called, -// nil is returned. -func (g *Graphemes) Bytes() []byte { - if g.start == g.end { - return nil - } - return []byte(string(g.codePoints[g.start:g.end])) -} - -// Positions returns the interval of the current grapheme cluster as byte -// positions into the original string. The first returned value "from" indexes -// the first byte and the second returned value "to" indexes the first byte that -// is not included anymore, i.e. str[from:to] is the current grapheme cluster of -// the original string "str". If Next() has not yet been called, both values are -// 0. If the iterator is already past the end, both values are 1. -func (g *Graphemes) Positions() (int, int) { - return g.indices[g.start], g.indices[g.end] -} - -// Reset puts the iterator into its initial state such that the next call to -// Next() sets it to the first grapheme cluster again. -func (g *Graphemes) Reset() { - g.start, g.end, g.pos, g.state = 0, 0, 0, grAny - g.Next() // Parse ahead again. -} - -// GraphemeClusterCount returns the number of user-perceived characters -// (grapheme clusters) for the given string. To calculate this number, it -// iterates through the string using the Graphemes iterator. -func GraphemeClusterCount(s string) (n int) { - g := NewGraphemes(s) - for g.Next() { - n++ - } - return -} diff --git a/vendor/github.com/rivo/uniseg/grapheme_test.go b/vendor/github.com/rivo/uniseg/grapheme_test.go deleted file mode 100644 index 3125434..0000000 --- a/vendor/github.com/rivo/uniseg/grapheme_test.go +++ /dev/null @@ -1,812 +0,0 @@ -package uniseg - -import ( - "fmt" - "testing" -) - -// Type example. -func ExampleGraphemes() { - gr := NewGraphemes("👍🏼!") - for gr.Next() { - fmt.Printf("%x ", gr.Runes()) - } - // Output: [1f44d 1f3fc] [21] -} - -// The test cases for the simple test function. -var testCases = []struct { - original string - expected [][]rune -}{ - {original: "", expected: [][]rune{}}, - {original: "x", expected: [][]rune{{0x78}}}, - {original: "basic", expected: [][]rune{{0x62}, {0x61}, {0x73}, {0x69}, {0x63}}}, - {original: "möp", expected: [][]rune{{0x6d}, {0x6f, 0x308}, {0x70}}}, - {original: "\r\n", expected: [][]rune{{0xd, 0xa}}}, - {original: "\n\n", expected: [][]rune{{0xa}, {0xa}}}, - {original: "\t*", expected: [][]rune{{0x9}, {0x2a}}}, - {original: "뢴", expected: [][]rune{{0x1105, 0x116c, 0x11ab}}}, - {original: "ܐ܏ܒܓܕ", expected: [][]rune{{0x710}, {0x70f, 0x712}, {0x713}, {0x715}}}, - {original: "ำ", expected: [][]rune{{0xe33}}}, - {original: "ำำ", expected: [][]rune{{0xe33, 0xe33}}}, - {original: "สระอำ", expected: [][]rune{{0xe2a}, {0xe23}, {0xe30}, {0xe2d, 0xe33}}}, - {original: "*뢴*", expected: [][]rune{{0x2a}, {0x1105, 0x116c, 0x11ab}, {0x2a}}}, - {original: "*👩‍❤️‍💋‍👩*", expected: [][]rune{{0x2a}, {0x1f469, 0x200d, 0x2764, 0xfe0f, 0x200d, 0x1f48b, 0x200d, 0x1f469}, {0x2a}}}, - {original: "👩‍❤️‍💋‍👩", expected: [][]rune{{0x1f469, 0x200d, 0x2764, 0xfe0f, 0x200d, 0x1f48b, 0x200d, 0x1f469}}}, - {original: "🏋🏽‍♀️", expected: [][]rune{{0x1f3cb, 0x1f3fd, 0x200d, 0x2640, 0xfe0f}}}, - {original: "🙂", expected: [][]rune{{0x1f642}}}, - {original: "🙂🙂", expected: [][]rune{{0x1f642}, {0x1f642}}}, - {original: "🇩🇪", expected: [][]rune{{0x1f1e9, 0x1f1ea}}}, - {original: "🏳️‍🌈", expected: [][]rune{{0x1f3f3, 0xfe0f, 0x200d, 0x1f308}}}, - - // The following tests are taken from - // http://www.unicode.org/Public/12.0.0/ucd/auxiliary/GraphemeBreakTest.txt, - // see https://www.unicode.org/license.html for the Unicode license agreement. - {original: "\u0020\u0020", expected: [][]rune{{0x0020}, {0x0020}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0020\u0308\u0020", expected: [][]rune{{0x0020, 0x0308}, {0x0020}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0020\u000D", expected: [][]rune{{0x0020}, {0x000D}}}, // ÷ [0.2] SPACE (Other) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0020\u0308\u000D", expected: [][]rune{{0x0020, 0x0308}, {0x000D}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0020\u000A", expected: [][]rune{{0x0020}, {0x000A}}}, // ÷ [0.2] SPACE (Other) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0020\u0308\u000A", expected: [][]rune{{0x0020, 0x0308}, {0x000A}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0020\u0001", expected: [][]rune{{0x0020}, {0x0001}}}, // ÷ [0.2] SPACE (Other) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0020\u0308\u0001", expected: [][]rune{{0x0020, 0x0308}, {0x0001}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0020\u034F", expected: [][]rune{{0x0020, 0x034F}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0020\u0308\u034F", expected: [][]rune{{0x0020, 0x0308, 0x034F}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0020\U0001F1E6", expected: [][]rune{{0x0020}, {0x1F1E6}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0020\u0308\U0001F1E6", expected: [][]rune{{0x0020, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0020\u0600", expected: [][]rune{{0x0020}, {0x0600}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0020\u0308\u0600", expected: [][]rune{{0x0020, 0x0308}, {0x0600}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0020\u0903", expected: [][]rune{{0x0020, 0x0903}}}, // ÷ [0.2] SPACE (Other) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0020\u0308\u0903", expected: [][]rune{{0x0020, 0x0308, 0x0903}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0020\u1100", expected: [][]rune{{0x0020}, {0x1100}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0020\u0308\u1100", expected: [][]rune{{0x0020, 0x0308}, {0x1100}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0020\u1160", expected: [][]rune{{0x0020}, {0x1160}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0020\u0308\u1160", expected: [][]rune{{0x0020, 0x0308}, {0x1160}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0020\u11A8", expected: [][]rune{{0x0020}, {0x11A8}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0020\u0308\u11A8", expected: [][]rune{{0x0020, 0x0308}, {0x11A8}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0020\uAC00", expected: [][]rune{{0x0020}, {0xAC00}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0020\u0308\uAC00", expected: [][]rune{{0x0020, 0x0308}, {0xAC00}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0020\uAC01", expected: [][]rune{{0x0020}, {0xAC01}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0020\u0308\uAC01", expected: [][]rune{{0x0020, 0x0308}, {0xAC01}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0020\u231A", expected: [][]rune{{0x0020}, {0x231A}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0020\u0308\u231A", expected: [][]rune{{0x0020, 0x0308}, {0x231A}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0020\u0300", expected: [][]rune{{0x0020, 0x0300}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0020\u0308\u0300", expected: [][]rune{{0x0020, 0x0308, 0x0300}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0020\u200D", expected: [][]rune{{0x0020, 0x200D}}}, // ÷ [0.2] SPACE (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0020\u0308\u200D", expected: [][]rune{{0x0020, 0x0308, 0x200D}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0020\u0378", expected: [][]rune{{0x0020}, {0x0378}}}, // ÷ [0.2] SPACE (Other) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0020\u0308\u0378", expected: [][]rune{{0x0020, 0x0308}, {0x0378}}}, // ÷ [0.2] SPACE (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u000D\u0020", expected: [][]rune{{0x000D}, {0x0020}}}, // ÷ [0.2] (CR) ÷ [4.0] SPACE (Other) ÷ [0.3] - {original: "\u000D\u0308\u0020", expected: [][]rune{{0x000D}, {0x0308}, {0x0020}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u000D\u000D", expected: [][]rune{{0x000D}, {0x000D}}}, // ÷ [0.2] (CR) ÷ [4.0] (CR) ÷ [0.3] - {original: "\u000D\u0308\u000D", expected: [][]rune{{0x000D}, {0x0308}, {0x000D}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u000D\u000A", expected: [][]rune{{0x000D, 0x000A}}}, // ÷ [0.2] (CR) × [3.0] (LF) ÷ [0.3] - {original: "\u000D\u0308\u000A", expected: [][]rune{{0x000D}, {0x0308}, {0x000A}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u000D\u0001", expected: [][]rune{{0x000D}, {0x0001}}}, // ÷ [0.2] (CR) ÷ [4.0] (Control) ÷ [0.3] - {original: "\u000D\u0308\u0001", expected: [][]rune{{0x000D}, {0x0308}, {0x0001}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u000D\u034F", expected: [][]rune{{0x000D}, {0x034F}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u000D\u0308\u034F", expected: [][]rune{{0x000D}, {0x0308, 0x034F}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u000D\U0001F1E6", expected: [][]rune{{0x000D}, {0x1F1E6}}}, // ÷ [0.2] (CR) ÷ [4.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u000D\u0308\U0001F1E6", expected: [][]rune{{0x000D}, {0x0308}, {0x1F1E6}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u000D\u0600", expected: [][]rune{{0x000D}, {0x0600}}}, // ÷ [0.2] (CR) ÷ [4.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u000D\u0308\u0600", expected: [][]rune{{0x000D}, {0x0308}, {0x0600}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u000D\u0903", expected: [][]rune{{0x000D}, {0x0903}}}, // ÷ [0.2] (CR) ÷ [4.0] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u000D\u0308\u0903", expected: [][]rune{{0x000D}, {0x0308, 0x0903}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u000D\u1100", expected: [][]rune{{0x000D}, {0x1100}}}, // ÷ [0.2] (CR) ÷ [4.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u000D\u0308\u1100", expected: [][]rune{{0x000D}, {0x0308}, {0x1100}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u000D\u1160", expected: [][]rune{{0x000D}, {0x1160}}}, // ÷ [0.2] (CR) ÷ [4.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u000D\u0308\u1160", expected: [][]rune{{0x000D}, {0x0308}, {0x1160}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u000D\u11A8", expected: [][]rune{{0x000D}, {0x11A8}}}, // ÷ [0.2] (CR) ÷ [4.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u000D\u0308\u11A8", expected: [][]rune{{0x000D}, {0x0308}, {0x11A8}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u000D\uAC00", expected: [][]rune{{0x000D}, {0xAC00}}}, // ÷ [0.2] (CR) ÷ [4.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u000D\u0308\uAC00", expected: [][]rune{{0x000D}, {0x0308}, {0xAC00}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u000D\uAC01", expected: [][]rune{{0x000D}, {0xAC01}}}, // ÷ [0.2] (CR) ÷ [4.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u000D\u0308\uAC01", expected: [][]rune{{0x000D}, {0x0308}, {0xAC01}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u000D\u231A", expected: [][]rune{{0x000D}, {0x231A}}}, // ÷ [0.2] (CR) ÷ [4.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u000D\u0308\u231A", expected: [][]rune{{0x000D}, {0x0308}, {0x231A}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u000D\u0300", expected: [][]rune{{0x000D}, {0x0300}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u000D\u0308\u0300", expected: [][]rune{{0x000D}, {0x0308, 0x0300}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u000D\u200D", expected: [][]rune{{0x000D}, {0x200D}}}, // ÷ [0.2] (CR) ÷ [4.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u000D\u0308\u200D", expected: [][]rune{{0x000D}, {0x0308, 0x200D}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u000D\u0378", expected: [][]rune{{0x000D}, {0x0378}}}, // ÷ [0.2] (CR) ÷ [4.0] (Other) ÷ [0.3] - {original: "\u000D\u0308\u0378", expected: [][]rune{{0x000D}, {0x0308}, {0x0378}}}, // ÷ [0.2] (CR) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u000A\u0020", expected: [][]rune{{0x000A}, {0x0020}}}, // ÷ [0.2] (LF) ÷ [4.0] SPACE (Other) ÷ [0.3] - {original: "\u000A\u0308\u0020", expected: [][]rune{{0x000A}, {0x0308}, {0x0020}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u000A\u000D", expected: [][]rune{{0x000A}, {0x000D}}}, // ÷ [0.2] (LF) ÷ [4.0] (CR) ÷ [0.3] - {original: "\u000A\u0308\u000D", expected: [][]rune{{0x000A}, {0x0308}, {0x000D}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u000A\u000A", expected: [][]rune{{0x000A}, {0x000A}}}, // ÷ [0.2] (LF) ÷ [4.0] (LF) ÷ [0.3] - {original: "\u000A\u0308\u000A", expected: [][]rune{{0x000A}, {0x0308}, {0x000A}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u000A\u0001", expected: [][]rune{{0x000A}, {0x0001}}}, // ÷ [0.2] (LF) ÷ [4.0] (Control) ÷ [0.3] - {original: "\u000A\u0308\u0001", expected: [][]rune{{0x000A}, {0x0308}, {0x0001}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u000A\u034F", expected: [][]rune{{0x000A}, {0x034F}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u000A\u0308\u034F", expected: [][]rune{{0x000A}, {0x0308, 0x034F}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u000A\U0001F1E6", expected: [][]rune{{0x000A}, {0x1F1E6}}}, // ÷ [0.2] (LF) ÷ [4.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u000A\u0308\U0001F1E6", expected: [][]rune{{0x000A}, {0x0308}, {0x1F1E6}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u000A\u0600", expected: [][]rune{{0x000A}, {0x0600}}}, // ÷ [0.2] (LF) ÷ [4.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u000A\u0308\u0600", expected: [][]rune{{0x000A}, {0x0308}, {0x0600}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u000A\u0903", expected: [][]rune{{0x000A}, {0x0903}}}, // ÷ [0.2] (LF) ÷ [4.0] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u000A\u0308\u0903", expected: [][]rune{{0x000A}, {0x0308, 0x0903}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u000A\u1100", expected: [][]rune{{0x000A}, {0x1100}}}, // ÷ [0.2] (LF) ÷ [4.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u000A\u0308\u1100", expected: [][]rune{{0x000A}, {0x0308}, {0x1100}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u000A\u1160", expected: [][]rune{{0x000A}, {0x1160}}}, // ÷ [0.2] (LF) ÷ [4.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u000A\u0308\u1160", expected: [][]rune{{0x000A}, {0x0308}, {0x1160}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u000A\u11A8", expected: [][]rune{{0x000A}, {0x11A8}}}, // ÷ [0.2] (LF) ÷ [4.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u000A\u0308\u11A8", expected: [][]rune{{0x000A}, {0x0308}, {0x11A8}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u000A\uAC00", expected: [][]rune{{0x000A}, {0xAC00}}}, // ÷ [0.2] (LF) ÷ [4.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u000A\u0308\uAC00", expected: [][]rune{{0x000A}, {0x0308}, {0xAC00}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u000A\uAC01", expected: [][]rune{{0x000A}, {0xAC01}}}, // ÷ [0.2] (LF) ÷ [4.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u000A\u0308\uAC01", expected: [][]rune{{0x000A}, {0x0308}, {0xAC01}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u000A\u231A", expected: [][]rune{{0x000A}, {0x231A}}}, // ÷ [0.2] (LF) ÷ [4.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u000A\u0308\u231A", expected: [][]rune{{0x000A}, {0x0308}, {0x231A}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u000A\u0300", expected: [][]rune{{0x000A}, {0x0300}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u000A\u0308\u0300", expected: [][]rune{{0x000A}, {0x0308, 0x0300}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u000A\u200D", expected: [][]rune{{0x000A}, {0x200D}}}, // ÷ [0.2] (LF) ÷ [4.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u000A\u0308\u200D", expected: [][]rune{{0x000A}, {0x0308, 0x200D}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u000A\u0378", expected: [][]rune{{0x000A}, {0x0378}}}, // ÷ [0.2] (LF) ÷ [4.0] (Other) ÷ [0.3] - {original: "\u000A\u0308\u0378", expected: [][]rune{{0x000A}, {0x0308}, {0x0378}}}, // ÷ [0.2] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0001\u0020", expected: [][]rune{{0x0001}, {0x0020}}}, // ÷ [0.2] (Control) ÷ [4.0] SPACE (Other) ÷ [0.3] - {original: "\u0001\u0308\u0020", expected: [][]rune{{0x0001}, {0x0308}, {0x0020}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0001\u000D", expected: [][]rune{{0x0001}, {0x000D}}}, // ÷ [0.2] (Control) ÷ [4.0] (CR) ÷ [0.3] - {original: "\u0001\u0308\u000D", expected: [][]rune{{0x0001}, {0x0308}, {0x000D}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0001\u000A", expected: [][]rune{{0x0001}, {0x000A}}}, // ÷ [0.2] (Control) ÷ [4.0] (LF) ÷ [0.3] - {original: "\u0001\u0308\u000A", expected: [][]rune{{0x0001}, {0x0308}, {0x000A}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0001\u0001", expected: [][]rune{{0x0001}, {0x0001}}}, // ÷ [0.2] (Control) ÷ [4.0] (Control) ÷ [0.3] - {original: "\u0001\u0308\u0001", expected: [][]rune{{0x0001}, {0x0308}, {0x0001}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0001\u034F", expected: [][]rune{{0x0001}, {0x034F}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0001\u0308\u034F", expected: [][]rune{{0x0001}, {0x0308, 0x034F}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0001\U0001F1E6", expected: [][]rune{{0x0001}, {0x1F1E6}}}, // ÷ [0.2] (Control) ÷ [4.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0001\u0308\U0001F1E6", expected: [][]rune{{0x0001}, {0x0308}, {0x1F1E6}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0001\u0600", expected: [][]rune{{0x0001}, {0x0600}}}, // ÷ [0.2] (Control) ÷ [4.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0001\u0308\u0600", expected: [][]rune{{0x0001}, {0x0308}, {0x0600}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0001\u0903", expected: [][]rune{{0x0001}, {0x0903}}}, // ÷ [0.2] (Control) ÷ [4.0] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0001\u0308\u0903", expected: [][]rune{{0x0001}, {0x0308, 0x0903}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0001\u1100", expected: [][]rune{{0x0001}, {0x1100}}}, // ÷ [0.2] (Control) ÷ [4.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0001\u0308\u1100", expected: [][]rune{{0x0001}, {0x0308}, {0x1100}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0001\u1160", expected: [][]rune{{0x0001}, {0x1160}}}, // ÷ [0.2] (Control) ÷ [4.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0001\u0308\u1160", expected: [][]rune{{0x0001}, {0x0308}, {0x1160}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0001\u11A8", expected: [][]rune{{0x0001}, {0x11A8}}}, // ÷ [0.2] (Control) ÷ [4.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0001\u0308\u11A8", expected: [][]rune{{0x0001}, {0x0308}, {0x11A8}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0001\uAC00", expected: [][]rune{{0x0001}, {0xAC00}}}, // ÷ [0.2] (Control) ÷ [4.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0001\u0308\uAC00", expected: [][]rune{{0x0001}, {0x0308}, {0xAC00}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0001\uAC01", expected: [][]rune{{0x0001}, {0xAC01}}}, // ÷ [0.2] (Control) ÷ [4.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0001\u0308\uAC01", expected: [][]rune{{0x0001}, {0x0308}, {0xAC01}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0001\u231A", expected: [][]rune{{0x0001}, {0x231A}}}, // ÷ [0.2] (Control) ÷ [4.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0001\u0308\u231A", expected: [][]rune{{0x0001}, {0x0308}, {0x231A}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0001\u0300", expected: [][]rune{{0x0001}, {0x0300}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0001\u0308\u0300", expected: [][]rune{{0x0001}, {0x0308, 0x0300}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0001\u200D", expected: [][]rune{{0x0001}, {0x200D}}}, // ÷ [0.2] (Control) ÷ [4.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0001\u0308\u200D", expected: [][]rune{{0x0001}, {0x0308, 0x200D}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0001\u0378", expected: [][]rune{{0x0001}, {0x0378}}}, // ÷ [0.2] (Control) ÷ [4.0] (Other) ÷ [0.3] - {original: "\u0001\u0308\u0378", expected: [][]rune{{0x0001}, {0x0308}, {0x0378}}}, // ÷ [0.2] (Control) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u034F\u0020", expected: [][]rune{{0x034F}, {0x0020}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u034F\u0308\u0020", expected: [][]rune{{0x034F, 0x0308}, {0x0020}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u034F\u000D", expected: [][]rune{{0x034F}, {0x000D}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u034F\u0308\u000D", expected: [][]rune{{0x034F, 0x0308}, {0x000D}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u034F\u000A", expected: [][]rune{{0x034F}, {0x000A}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u034F\u0308\u000A", expected: [][]rune{{0x034F, 0x0308}, {0x000A}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u034F\u0001", expected: [][]rune{{0x034F}, {0x0001}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u034F\u0308\u0001", expected: [][]rune{{0x034F, 0x0308}, {0x0001}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u034F\u034F", expected: [][]rune{{0x034F, 0x034F}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u034F\u0308\u034F", expected: [][]rune{{0x034F, 0x0308, 0x034F}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u034F\U0001F1E6", expected: [][]rune{{0x034F}, {0x1F1E6}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u034F\u0308\U0001F1E6", expected: [][]rune{{0x034F, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u034F\u0600", expected: [][]rune{{0x034F}, {0x0600}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u034F\u0308\u0600", expected: [][]rune{{0x034F, 0x0308}, {0x0600}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u034F\u0903", expected: [][]rune{{0x034F, 0x0903}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u034F\u0308\u0903", expected: [][]rune{{0x034F, 0x0308, 0x0903}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u034F\u1100", expected: [][]rune{{0x034F}, {0x1100}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u034F\u0308\u1100", expected: [][]rune{{0x034F, 0x0308}, {0x1100}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u034F\u1160", expected: [][]rune{{0x034F}, {0x1160}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u034F\u0308\u1160", expected: [][]rune{{0x034F, 0x0308}, {0x1160}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u034F\u11A8", expected: [][]rune{{0x034F}, {0x11A8}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u034F\u0308\u11A8", expected: [][]rune{{0x034F, 0x0308}, {0x11A8}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u034F\uAC00", expected: [][]rune{{0x034F}, {0xAC00}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u034F\u0308\uAC00", expected: [][]rune{{0x034F, 0x0308}, {0xAC00}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u034F\uAC01", expected: [][]rune{{0x034F}, {0xAC01}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u034F\u0308\uAC01", expected: [][]rune{{0x034F, 0x0308}, {0xAC01}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u034F\u231A", expected: [][]rune{{0x034F}, {0x231A}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u034F\u0308\u231A", expected: [][]rune{{0x034F, 0x0308}, {0x231A}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u034F\u0300", expected: [][]rune{{0x034F, 0x0300}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u034F\u0308\u0300", expected: [][]rune{{0x034F, 0x0308, 0x0300}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u034F\u200D", expected: [][]rune{{0x034F, 0x200D}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u034F\u0308\u200D", expected: [][]rune{{0x034F, 0x0308, 0x200D}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u034F\u0378", expected: [][]rune{{0x034F}, {0x0378}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u034F\u0308\u0378", expected: [][]rune{{0x034F, 0x0308}, {0x0378}}}, // ÷ [0.2] COMBINING GRAPHEME JOINER (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\U0001F1E6\u0020", expected: [][]rune{{0x1F1E6}, {0x0020}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\U0001F1E6\u0308\u0020", expected: [][]rune{{0x1F1E6, 0x0308}, {0x0020}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\U0001F1E6\u000D", expected: [][]rune{{0x1F1E6}, {0x000D}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [5.0] (CR) ÷ [0.3] - {original: "\U0001F1E6\u0308\u000D", expected: [][]rune{{0x1F1E6, 0x0308}, {0x000D}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\U0001F1E6\u000A", expected: [][]rune{{0x1F1E6}, {0x000A}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [5.0] (LF) ÷ [0.3] - {original: "\U0001F1E6\u0308\u000A", expected: [][]rune{{0x1F1E6, 0x0308}, {0x000A}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\U0001F1E6\u0001", expected: [][]rune{{0x1F1E6}, {0x0001}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [5.0] (Control) ÷ [0.3] - {original: "\U0001F1E6\u0308\u0001", expected: [][]rune{{0x1F1E6, 0x0308}, {0x0001}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\U0001F1E6\u034F", expected: [][]rune{{0x1F1E6, 0x034F}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\U0001F1E6\u0308\u034F", expected: [][]rune{{0x1F1E6, 0x0308, 0x034F}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\U0001F1E6\U0001F1E6", expected: [][]rune{{0x1F1E6, 0x1F1E6}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [12.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\U0001F1E6\u0308\U0001F1E6", expected: [][]rune{{0x1F1E6, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\U0001F1E6\u0600", expected: [][]rune{{0x1F1E6}, {0x0600}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\U0001F1E6\u0308\u0600", expected: [][]rune{{0x1F1E6, 0x0308}, {0x0600}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\U0001F1E6\u0903", expected: [][]rune{{0x1F1E6, 0x0903}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\U0001F1E6\u0308\u0903", expected: [][]rune{{0x1F1E6, 0x0308, 0x0903}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\U0001F1E6\u1100", expected: [][]rune{{0x1F1E6}, {0x1100}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\U0001F1E6\u0308\u1100", expected: [][]rune{{0x1F1E6, 0x0308}, {0x1100}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\U0001F1E6\u1160", expected: [][]rune{{0x1F1E6}, {0x1160}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\U0001F1E6\u0308\u1160", expected: [][]rune{{0x1F1E6, 0x0308}, {0x1160}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\U0001F1E6\u11A8", expected: [][]rune{{0x1F1E6}, {0x11A8}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\U0001F1E6\u0308\u11A8", expected: [][]rune{{0x1F1E6, 0x0308}, {0x11A8}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\U0001F1E6\uAC00", expected: [][]rune{{0x1F1E6}, {0xAC00}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\U0001F1E6\u0308\uAC00", expected: [][]rune{{0x1F1E6, 0x0308}, {0xAC00}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\U0001F1E6\uAC01", expected: [][]rune{{0x1F1E6}, {0xAC01}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\U0001F1E6\u0308\uAC01", expected: [][]rune{{0x1F1E6, 0x0308}, {0xAC01}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\U0001F1E6\u231A", expected: [][]rune{{0x1F1E6}, {0x231A}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\U0001F1E6\u0308\u231A", expected: [][]rune{{0x1F1E6, 0x0308}, {0x231A}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\U0001F1E6\u0300", expected: [][]rune{{0x1F1E6, 0x0300}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\U0001F1E6\u0308\u0300", expected: [][]rune{{0x1F1E6, 0x0308, 0x0300}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\U0001F1E6\u200D", expected: [][]rune{{0x1F1E6, 0x200D}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\U0001F1E6\u0308\u200D", expected: [][]rune{{0x1F1E6, 0x0308, 0x200D}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\U0001F1E6\u0378", expected: [][]rune{{0x1F1E6}, {0x0378}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [999.0] (Other) ÷ [0.3] - {original: "\U0001F1E6\u0308\u0378", expected: [][]rune{{0x1F1E6, 0x0308}, {0x0378}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0600\u0020", expected: [][]rune{{0x0600, 0x0020}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] SPACE (Other) ÷ [0.3] - {original: "\u0600\u0308\u0020", expected: [][]rune{{0x0600, 0x0308}, {0x0020}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0600\u000D", expected: [][]rune{{0x0600}, {0x000D}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0600\u0308\u000D", expected: [][]rune{{0x0600, 0x0308}, {0x000D}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0600\u000A", expected: [][]rune{{0x0600}, {0x000A}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0600\u0308\u000A", expected: [][]rune{{0x0600, 0x0308}, {0x000A}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0600\u0001", expected: [][]rune{{0x0600}, {0x0001}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0600\u0308\u0001", expected: [][]rune{{0x0600, 0x0308}, {0x0001}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0600\u034F", expected: [][]rune{{0x0600, 0x034F}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0600\u0308\u034F", expected: [][]rune{{0x0600, 0x0308, 0x034F}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0600\U0001F1E6", expected: [][]rune{{0x0600, 0x1F1E6}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0600\u0308\U0001F1E6", expected: [][]rune{{0x0600, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0600\u0600", expected: [][]rune{{0x0600, 0x0600}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0600\u0308\u0600", expected: [][]rune{{0x0600, 0x0308}, {0x0600}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0600\u0903", expected: [][]rune{{0x0600, 0x0903}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0600\u0308\u0903", expected: [][]rune{{0x0600, 0x0308, 0x0903}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0600\u1100", expected: [][]rune{{0x0600, 0x1100}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0600\u0308\u1100", expected: [][]rune{{0x0600, 0x0308}, {0x1100}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0600\u1160", expected: [][]rune{{0x0600, 0x1160}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0600\u0308\u1160", expected: [][]rune{{0x0600, 0x0308}, {0x1160}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0600\u11A8", expected: [][]rune{{0x0600, 0x11A8}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0600\u0308\u11A8", expected: [][]rune{{0x0600, 0x0308}, {0x11A8}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0600\uAC00", expected: [][]rune{{0x0600, 0xAC00}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0600\u0308\uAC00", expected: [][]rune{{0x0600, 0x0308}, {0xAC00}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0600\uAC01", expected: [][]rune{{0x0600, 0xAC01}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0600\u0308\uAC01", expected: [][]rune{{0x0600, 0x0308}, {0xAC01}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0600\u231A", expected: [][]rune{{0x0600, 0x231A}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] WATCH (ExtPict) ÷ [0.3] - {original: "\u0600\u0308\u231A", expected: [][]rune{{0x0600, 0x0308}, {0x231A}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0600\u0300", expected: [][]rune{{0x0600, 0x0300}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0600\u0308\u0300", expected: [][]rune{{0x0600, 0x0308, 0x0300}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0600\u200D", expected: [][]rune{{0x0600, 0x200D}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0600\u0308\u200D", expected: [][]rune{{0x0600, 0x0308, 0x200D}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0600\u0378", expected: [][]rune{{0x0600, 0x0378}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.2] (Other) ÷ [0.3] - {original: "\u0600\u0308\u0378", expected: [][]rune{{0x0600, 0x0308}, {0x0378}}}, // ÷ [0.2] ARABIC NUMBER SIGN (Prepend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0903\u0020", expected: [][]rune{{0x0903}, {0x0020}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0903\u0308\u0020", expected: [][]rune{{0x0903, 0x0308}, {0x0020}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0903\u000D", expected: [][]rune{{0x0903}, {0x000D}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0903\u0308\u000D", expected: [][]rune{{0x0903, 0x0308}, {0x000D}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0903\u000A", expected: [][]rune{{0x0903}, {0x000A}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0903\u0308\u000A", expected: [][]rune{{0x0903, 0x0308}, {0x000A}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0903\u0001", expected: [][]rune{{0x0903}, {0x0001}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0903\u0308\u0001", expected: [][]rune{{0x0903, 0x0308}, {0x0001}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0903\u034F", expected: [][]rune{{0x0903, 0x034F}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0903\u0308\u034F", expected: [][]rune{{0x0903, 0x0308, 0x034F}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0903\U0001F1E6", expected: [][]rune{{0x0903}, {0x1F1E6}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0903\u0308\U0001F1E6", expected: [][]rune{{0x0903, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0903\u0600", expected: [][]rune{{0x0903}, {0x0600}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0903\u0308\u0600", expected: [][]rune{{0x0903, 0x0308}, {0x0600}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0903\u0903", expected: [][]rune{{0x0903, 0x0903}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0903\u0308\u0903", expected: [][]rune{{0x0903, 0x0308, 0x0903}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0903\u1100", expected: [][]rune{{0x0903}, {0x1100}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0903\u0308\u1100", expected: [][]rune{{0x0903, 0x0308}, {0x1100}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0903\u1160", expected: [][]rune{{0x0903}, {0x1160}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0903\u0308\u1160", expected: [][]rune{{0x0903, 0x0308}, {0x1160}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0903\u11A8", expected: [][]rune{{0x0903}, {0x11A8}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0903\u0308\u11A8", expected: [][]rune{{0x0903, 0x0308}, {0x11A8}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0903\uAC00", expected: [][]rune{{0x0903}, {0xAC00}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0903\u0308\uAC00", expected: [][]rune{{0x0903, 0x0308}, {0xAC00}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0903\uAC01", expected: [][]rune{{0x0903}, {0xAC01}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0903\u0308\uAC01", expected: [][]rune{{0x0903, 0x0308}, {0xAC01}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0903\u231A", expected: [][]rune{{0x0903}, {0x231A}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0903\u0308\u231A", expected: [][]rune{{0x0903, 0x0308}, {0x231A}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0903\u0300", expected: [][]rune{{0x0903, 0x0300}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0903\u0308\u0300", expected: [][]rune{{0x0903, 0x0308, 0x0300}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0903\u200D", expected: [][]rune{{0x0903, 0x200D}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0903\u0308\u200D", expected: [][]rune{{0x0903, 0x0308, 0x200D}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0903\u0378", expected: [][]rune{{0x0903}, {0x0378}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0903\u0308\u0378", expected: [][]rune{{0x0903, 0x0308}, {0x0378}}}, // ÷ [0.2] DEVANAGARI SIGN VISARGA (SpacingMark) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u1100\u0020", expected: [][]rune{{0x1100}, {0x0020}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u1100\u0308\u0020", expected: [][]rune{{0x1100, 0x0308}, {0x0020}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u1100\u000D", expected: [][]rune{{0x1100}, {0x000D}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u1100\u0308\u000D", expected: [][]rune{{0x1100, 0x0308}, {0x000D}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u1100\u000A", expected: [][]rune{{0x1100}, {0x000A}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u1100\u0308\u000A", expected: [][]rune{{0x1100, 0x0308}, {0x000A}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u1100\u0001", expected: [][]rune{{0x1100}, {0x0001}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u1100\u0308\u0001", expected: [][]rune{{0x1100, 0x0308}, {0x0001}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u1100\u034F", expected: [][]rune{{0x1100, 0x034F}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u1100\u0308\u034F", expected: [][]rune{{0x1100, 0x0308, 0x034F}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u1100\U0001F1E6", expected: [][]rune{{0x1100}, {0x1F1E6}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u1100\u0308\U0001F1E6", expected: [][]rune{{0x1100, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u1100\u0600", expected: [][]rune{{0x1100}, {0x0600}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u1100\u0308\u0600", expected: [][]rune{{0x1100, 0x0308}, {0x0600}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u1100\u0903", expected: [][]rune{{0x1100, 0x0903}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u1100\u0308\u0903", expected: [][]rune{{0x1100, 0x0308, 0x0903}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u1100\u1100", expected: [][]rune{{0x1100, 0x1100}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [6.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u1100\u0308\u1100", expected: [][]rune{{0x1100, 0x0308}, {0x1100}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u1100\u1160", expected: [][]rune{{0x1100, 0x1160}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [6.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u1100\u0308\u1160", expected: [][]rune{{0x1100, 0x0308}, {0x1160}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u1100\u11A8", expected: [][]rune{{0x1100}, {0x11A8}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u1100\u0308\u11A8", expected: [][]rune{{0x1100, 0x0308}, {0x11A8}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u1100\uAC00", expected: [][]rune{{0x1100, 0xAC00}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [6.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u1100\u0308\uAC00", expected: [][]rune{{0x1100, 0x0308}, {0xAC00}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u1100\uAC01", expected: [][]rune{{0x1100, 0xAC01}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [6.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u1100\u0308\uAC01", expected: [][]rune{{0x1100, 0x0308}, {0xAC01}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u1100\u231A", expected: [][]rune{{0x1100}, {0x231A}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u1100\u0308\u231A", expected: [][]rune{{0x1100, 0x0308}, {0x231A}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u1100\u0300", expected: [][]rune{{0x1100, 0x0300}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u1100\u0308\u0300", expected: [][]rune{{0x1100, 0x0308, 0x0300}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u1100\u200D", expected: [][]rune{{0x1100, 0x200D}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u1100\u0308\u200D", expected: [][]rune{{0x1100, 0x0308, 0x200D}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u1100\u0378", expected: [][]rune{{0x1100}, {0x0378}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u1100\u0308\u0378", expected: [][]rune{{0x1100, 0x0308}, {0x0378}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u1160\u0020", expected: [][]rune{{0x1160}, {0x0020}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u1160\u0308\u0020", expected: [][]rune{{0x1160, 0x0308}, {0x0020}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u1160\u000D", expected: [][]rune{{0x1160}, {0x000D}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u1160\u0308\u000D", expected: [][]rune{{0x1160, 0x0308}, {0x000D}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u1160\u000A", expected: [][]rune{{0x1160}, {0x000A}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u1160\u0308\u000A", expected: [][]rune{{0x1160, 0x0308}, {0x000A}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u1160\u0001", expected: [][]rune{{0x1160}, {0x0001}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u1160\u0308\u0001", expected: [][]rune{{0x1160, 0x0308}, {0x0001}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u1160\u034F", expected: [][]rune{{0x1160, 0x034F}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u1160\u0308\u034F", expected: [][]rune{{0x1160, 0x0308, 0x034F}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u1160\U0001F1E6", expected: [][]rune{{0x1160}, {0x1F1E6}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u1160\u0308\U0001F1E6", expected: [][]rune{{0x1160, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u1160\u0600", expected: [][]rune{{0x1160}, {0x0600}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u1160\u0308\u0600", expected: [][]rune{{0x1160, 0x0308}, {0x0600}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u1160\u0903", expected: [][]rune{{0x1160, 0x0903}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u1160\u0308\u0903", expected: [][]rune{{0x1160, 0x0308, 0x0903}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u1160\u1100", expected: [][]rune{{0x1160}, {0x1100}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u1160\u0308\u1100", expected: [][]rune{{0x1160, 0x0308}, {0x1100}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u1160\u1160", expected: [][]rune{{0x1160, 0x1160}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [7.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u1160\u0308\u1160", expected: [][]rune{{0x1160, 0x0308}, {0x1160}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u1160\u11A8", expected: [][]rune{{0x1160, 0x11A8}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [7.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u1160\u0308\u11A8", expected: [][]rune{{0x1160, 0x0308}, {0x11A8}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u1160\uAC00", expected: [][]rune{{0x1160}, {0xAC00}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u1160\u0308\uAC00", expected: [][]rune{{0x1160, 0x0308}, {0xAC00}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u1160\uAC01", expected: [][]rune{{0x1160}, {0xAC01}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u1160\u0308\uAC01", expected: [][]rune{{0x1160, 0x0308}, {0xAC01}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u1160\u231A", expected: [][]rune{{0x1160}, {0x231A}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u1160\u0308\u231A", expected: [][]rune{{0x1160, 0x0308}, {0x231A}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u1160\u0300", expected: [][]rune{{0x1160, 0x0300}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u1160\u0308\u0300", expected: [][]rune{{0x1160, 0x0308, 0x0300}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u1160\u200D", expected: [][]rune{{0x1160, 0x200D}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u1160\u0308\u200D", expected: [][]rune{{0x1160, 0x0308, 0x200D}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u1160\u0378", expected: [][]rune{{0x1160}, {0x0378}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u1160\u0308\u0378", expected: [][]rune{{0x1160, 0x0308}, {0x0378}}}, // ÷ [0.2] HANGUL JUNGSEONG FILLER (V) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u11A8\u0020", expected: [][]rune{{0x11A8}, {0x0020}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u11A8\u0308\u0020", expected: [][]rune{{0x11A8, 0x0308}, {0x0020}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u11A8\u000D", expected: [][]rune{{0x11A8}, {0x000D}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u11A8\u0308\u000D", expected: [][]rune{{0x11A8, 0x0308}, {0x000D}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u11A8\u000A", expected: [][]rune{{0x11A8}, {0x000A}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u11A8\u0308\u000A", expected: [][]rune{{0x11A8, 0x0308}, {0x000A}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u11A8\u0001", expected: [][]rune{{0x11A8}, {0x0001}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u11A8\u0308\u0001", expected: [][]rune{{0x11A8, 0x0308}, {0x0001}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u11A8\u034F", expected: [][]rune{{0x11A8, 0x034F}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u11A8\u0308\u034F", expected: [][]rune{{0x11A8, 0x0308, 0x034F}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u11A8\U0001F1E6", expected: [][]rune{{0x11A8}, {0x1F1E6}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u11A8\u0308\U0001F1E6", expected: [][]rune{{0x11A8, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u11A8\u0600", expected: [][]rune{{0x11A8}, {0x0600}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u11A8\u0308\u0600", expected: [][]rune{{0x11A8, 0x0308}, {0x0600}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u11A8\u0903", expected: [][]rune{{0x11A8, 0x0903}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u11A8\u0308\u0903", expected: [][]rune{{0x11A8, 0x0308, 0x0903}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u11A8\u1100", expected: [][]rune{{0x11A8}, {0x1100}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u11A8\u0308\u1100", expected: [][]rune{{0x11A8, 0x0308}, {0x1100}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u11A8\u1160", expected: [][]rune{{0x11A8}, {0x1160}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u11A8\u0308\u1160", expected: [][]rune{{0x11A8, 0x0308}, {0x1160}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u11A8\u11A8", expected: [][]rune{{0x11A8, 0x11A8}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [8.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u11A8\u0308\u11A8", expected: [][]rune{{0x11A8, 0x0308}, {0x11A8}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u11A8\uAC00", expected: [][]rune{{0x11A8}, {0xAC00}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u11A8\u0308\uAC00", expected: [][]rune{{0x11A8, 0x0308}, {0xAC00}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u11A8\uAC01", expected: [][]rune{{0x11A8}, {0xAC01}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u11A8\u0308\uAC01", expected: [][]rune{{0x11A8, 0x0308}, {0xAC01}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u11A8\u231A", expected: [][]rune{{0x11A8}, {0x231A}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u11A8\u0308\u231A", expected: [][]rune{{0x11A8, 0x0308}, {0x231A}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u11A8\u0300", expected: [][]rune{{0x11A8, 0x0300}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u11A8\u0308\u0300", expected: [][]rune{{0x11A8, 0x0308, 0x0300}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u11A8\u200D", expected: [][]rune{{0x11A8, 0x200D}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u11A8\u0308\u200D", expected: [][]rune{{0x11A8, 0x0308, 0x200D}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u11A8\u0378", expected: [][]rune{{0x11A8}, {0x0378}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u11A8\u0308\u0378", expected: [][]rune{{0x11A8, 0x0308}, {0x0378}}}, // ÷ [0.2] HANGUL JONGSEONG KIYEOK (T) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\uAC00\u0020", expected: [][]rune{{0xAC00}, {0x0020}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\uAC00\u0308\u0020", expected: [][]rune{{0xAC00, 0x0308}, {0x0020}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\uAC00\u000D", expected: [][]rune{{0xAC00}, {0x000D}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [5.0] (CR) ÷ [0.3] - {original: "\uAC00\u0308\u000D", expected: [][]rune{{0xAC00, 0x0308}, {0x000D}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\uAC00\u000A", expected: [][]rune{{0xAC00}, {0x000A}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [5.0] (LF) ÷ [0.3] - {original: "\uAC00\u0308\u000A", expected: [][]rune{{0xAC00, 0x0308}, {0x000A}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\uAC00\u0001", expected: [][]rune{{0xAC00}, {0x0001}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [5.0] (Control) ÷ [0.3] - {original: "\uAC00\u0308\u0001", expected: [][]rune{{0xAC00, 0x0308}, {0x0001}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\uAC00\u034F", expected: [][]rune{{0xAC00, 0x034F}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\uAC00\u0308\u034F", expected: [][]rune{{0xAC00, 0x0308, 0x034F}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\uAC00\U0001F1E6", expected: [][]rune{{0xAC00}, {0x1F1E6}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\uAC00\u0308\U0001F1E6", expected: [][]rune{{0xAC00, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\uAC00\u0600", expected: [][]rune{{0xAC00}, {0x0600}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\uAC00\u0308\u0600", expected: [][]rune{{0xAC00, 0x0308}, {0x0600}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\uAC00\u0903", expected: [][]rune{{0xAC00, 0x0903}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\uAC00\u0308\u0903", expected: [][]rune{{0xAC00, 0x0308, 0x0903}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\uAC00\u1100", expected: [][]rune{{0xAC00}, {0x1100}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\uAC00\u0308\u1100", expected: [][]rune{{0xAC00, 0x0308}, {0x1100}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\uAC00\u1160", expected: [][]rune{{0xAC00, 0x1160}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [7.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\uAC00\u0308\u1160", expected: [][]rune{{0xAC00, 0x0308}, {0x1160}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\uAC00\u11A8", expected: [][]rune{{0xAC00, 0x11A8}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [7.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\uAC00\u0308\u11A8", expected: [][]rune{{0xAC00, 0x0308}, {0x11A8}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\uAC00\uAC00", expected: [][]rune{{0xAC00}, {0xAC00}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\uAC00\u0308\uAC00", expected: [][]rune{{0xAC00, 0x0308}, {0xAC00}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\uAC00\uAC01", expected: [][]rune{{0xAC00}, {0xAC01}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\uAC00\u0308\uAC01", expected: [][]rune{{0xAC00, 0x0308}, {0xAC01}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\uAC00\u231A", expected: [][]rune{{0xAC00}, {0x231A}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\uAC00\u0308\u231A", expected: [][]rune{{0xAC00, 0x0308}, {0x231A}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\uAC00\u0300", expected: [][]rune{{0xAC00, 0x0300}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\uAC00\u0308\u0300", expected: [][]rune{{0xAC00, 0x0308, 0x0300}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\uAC00\u200D", expected: [][]rune{{0xAC00, 0x200D}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\uAC00\u0308\u200D", expected: [][]rune{{0xAC00, 0x0308, 0x200D}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\uAC00\u0378", expected: [][]rune{{0xAC00}, {0x0378}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) ÷ [999.0] (Other) ÷ [0.3] - {original: "\uAC00\u0308\u0378", expected: [][]rune{{0xAC00, 0x0308}, {0x0378}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\uAC01\u0020", expected: [][]rune{{0xAC01}, {0x0020}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\uAC01\u0308\u0020", expected: [][]rune{{0xAC01, 0x0308}, {0x0020}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\uAC01\u000D", expected: [][]rune{{0xAC01}, {0x000D}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [5.0] (CR) ÷ [0.3] - {original: "\uAC01\u0308\u000D", expected: [][]rune{{0xAC01, 0x0308}, {0x000D}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\uAC01\u000A", expected: [][]rune{{0xAC01}, {0x000A}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [5.0] (LF) ÷ [0.3] - {original: "\uAC01\u0308\u000A", expected: [][]rune{{0xAC01, 0x0308}, {0x000A}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\uAC01\u0001", expected: [][]rune{{0xAC01}, {0x0001}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [5.0] (Control) ÷ [0.3] - {original: "\uAC01\u0308\u0001", expected: [][]rune{{0xAC01, 0x0308}, {0x0001}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\uAC01\u034F", expected: [][]rune{{0xAC01, 0x034F}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\uAC01\u0308\u034F", expected: [][]rune{{0xAC01, 0x0308, 0x034F}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\uAC01\U0001F1E6", expected: [][]rune{{0xAC01}, {0x1F1E6}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\uAC01\u0308\U0001F1E6", expected: [][]rune{{0xAC01, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\uAC01\u0600", expected: [][]rune{{0xAC01}, {0x0600}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\uAC01\u0308\u0600", expected: [][]rune{{0xAC01, 0x0308}, {0x0600}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\uAC01\u0903", expected: [][]rune{{0xAC01, 0x0903}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\uAC01\u0308\u0903", expected: [][]rune{{0xAC01, 0x0308, 0x0903}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\uAC01\u1100", expected: [][]rune{{0xAC01}, {0x1100}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\uAC01\u0308\u1100", expected: [][]rune{{0xAC01, 0x0308}, {0x1100}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\uAC01\u1160", expected: [][]rune{{0xAC01}, {0x1160}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\uAC01\u0308\u1160", expected: [][]rune{{0xAC01, 0x0308}, {0x1160}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\uAC01\u11A8", expected: [][]rune{{0xAC01, 0x11A8}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [8.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\uAC01\u0308\u11A8", expected: [][]rune{{0xAC01, 0x0308}, {0x11A8}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\uAC01\uAC00", expected: [][]rune{{0xAC01}, {0xAC00}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\uAC01\u0308\uAC00", expected: [][]rune{{0xAC01, 0x0308}, {0xAC00}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\uAC01\uAC01", expected: [][]rune{{0xAC01}, {0xAC01}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\uAC01\u0308\uAC01", expected: [][]rune{{0xAC01, 0x0308}, {0xAC01}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\uAC01\u231A", expected: [][]rune{{0xAC01}, {0x231A}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\uAC01\u0308\u231A", expected: [][]rune{{0xAC01, 0x0308}, {0x231A}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\uAC01\u0300", expected: [][]rune{{0xAC01, 0x0300}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\uAC01\u0308\u0300", expected: [][]rune{{0xAC01, 0x0308, 0x0300}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\uAC01\u200D", expected: [][]rune{{0xAC01, 0x200D}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\uAC01\u0308\u200D", expected: [][]rune{{0xAC01, 0x0308, 0x200D}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\uAC01\u0378", expected: [][]rune{{0xAC01}, {0x0378}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) ÷ [999.0] (Other) ÷ [0.3] - {original: "\uAC01\u0308\u0378", expected: [][]rune{{0xAC01, 0x0308}, {0x0378}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u231A\u0020", expected: [][]rune{{0x231A}, {0x0020}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u231A\u0308\u0020", expected: [][]rune{{0x231A, 0x0308}, {0x0020}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u231A\u000D", expected: [][]rune{{0x231A}, {0x000D}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u231A\u0308\u000D", expected: [][]rune{{0x231A, 0x0308}, {0x000D}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u231A\u000A", expected: [][]rune{{0x231A}, {0x000A}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u231A\u0308\u000A", expected: [][]rune{{0x231A, 0x0308}, {0x000A}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u231A\u0001", expected: [][]rune{{0x231A}, {0x0001}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u231A\u0308\u0001", expected: [][]rune{{0x231A, 0x0308}, {0x0001}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u231A\u034F", expected: [][]rune{{0x231A, 0x034F}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u231A\u0308\u034F", expected: [][]rune{{0x231A, 0x0308, 0x034F}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u231A\U0001F1E6", expected: [][]rune{{0x231A}, {0x1F1E6}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u231A\u0308\U0001F1E6", expected: [][]rune{{0x231A, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u231A\u0600", expected: [][]rune{{0x231A}, {0x0600}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u231A\u0308\u0600", expected: [][]rune{{0x231A, 0x0308}, {0x0600}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u231A\u0903", expected: [][]rune{{0x231A, 0x0903}}}, // ÷ [0.2] WATCH (ExtPict) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u231A\u0308\u0903", expected: [][]rune{{0x231A, 0x0308, 0x0903}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u231A\u1100", expected: [][]rune{{0x231A}, {0x1100}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u231A\u0308\u1100", expected: [][]rune{{0x231A, 0x0308}, {0x1100}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u231A\u1160", expected: [][]rune{{0x231A}, {0x1160}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u231A\u0308\u1160", expected: [][]rune{{0x231A, 0x0308}, {0x1160}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u231A\u11A8", expected: [][]rune{{0x231A}, {0x11A8}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u231A\u0308\u11A8", expected: [][]rune{{0x231A, 0x0308}, {0x11A8}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u231A\uAC00", expected: [][]rune{{0x231A}, {0xAC00}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u231A\u0308\uAC00", expected: [][]rune{{0x231A, 0x0308}, {0xAC00}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u231A\uAC01", expected: [][]rune{{0x231A}, {0xAC01}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u231A\u0308\uAC01", expected: [][]rune{{0x231A, 0x0308}, {0xAC01}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u231A\u231A", expected: [][]rune{{0x231A}, {0x231A}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u231A\u0308\u231A", expected: [][]rune{{0x231A, 0x0308}, {0x231A}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u231A\u0300", expected: [][]rune{{0x231A, 0x0300}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u231A\u0308\u0300", expected: [][]rune{{0x231A, 0x0308, 0x0300}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u231A\u200D", expected: [][]rune{{0x231A, 0x200D}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u231A\u0308\u200D", expected: [][]rune{{0x231A, 0x0308, 0x200D}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u231A\u0378", expected: [][]rune{{0x231A}, {0x0378}}}, // ÷ [0.2] WATCH (ExtPict) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u231A\u0308\u0378", expected: [][]rune{{0x231A, 0x0308}, {0x0378}}}, // ÷ [0.2] WATCH (ExtPict) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0300\u0020", expected: [][]rune{{0x0300}, {0x0020}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0300\u0308\u0020", expected: [][]rune{{0x0300, 0x0308}, {0x0020}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0300\u000D", expected: [][]rune{{0x0300}, {0x000D}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0300\u0308\u000D", expected: [][]rune{{0x0300, 0x0308}, {0x000D}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0300\u000A", expected: [][]rune{{0x0300}, {0x000A}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0300\u0308\u000A", expected: [][]rune{{0x0300, 0x0308}, {0x000A}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0300\u0001", expected: [][]rune{{0x0300}, {0x0001}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0300\u0308\u0001", expected: [][]rune{{0x0300, 0x0308}, {0x0001}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0300\u034F", expected: [][]rune{{0x0300, 0x034F}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0300\u0308\u034F", expected: [][]rune{{0x0300, 0x0308, 0x034F}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0300\U0001F1E6", expected: [][]rune{{0x0300}, {0x1F1E6}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0300\u0308\U0001F1E6", expected: [][]rune{{0x0300, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0300\u0600", expected: [][]rune{{0x0300}, {0x0600}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0300\u0308\u0600", expected: [][]rune{{0x0300, 0x0308}, {0x0600}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0300\u0903", expected: [][]rune{{0x0300, 0x0903}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0300\u0308\u0903", expected: [][]rune{{0x0300, 0x0308, 0x0903}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0300\u1100", expected: [][]rune{{0x0300}, {0x1100}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0300\u0308\u1100", expected: [][]rune{{0x0300, 0x0308}, {0x1100}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0300\u1160", expected: [][]rune{{0x0300}, {0x1160}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0300\u0308\u1160", expected: [][]rune{{0x0300, 0x0308}, {0x1160}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0300\u11A8", expected: [][]rune{{0x0300}, {0x11A8}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0300\u0308\u11A8", expected: [][]rune{{0x0300, 0x0308}, {0x11A8}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0300\uAC00", expected: [][]rune{{0x0300}, {0xAC00}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0300\u0308\uAC00", expected: [][]rune{{0x0300, 0x0308}, {0xAC00}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0300\uAC01", expected: [][]rune{{0x0300}, {0xAC01}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0300\u0308\uAC01", expected: [][]rune{{0x0300, 0x0308}, {0xAC01}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0300\u231A", expected: [][]rune{{0x0300}, {0x231A}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0300\u0308\u231A", expected: [][]rune{{0x0300, 0x0308}, {0x231A}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0300\u0300", expected: [][]rune{{0x0300, 0x0300}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0300\u0308\u0300", expected: [][]rune{{0x0300, 0x0308, 0x0300}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0300\u200D", expected: [][]rune{{0x0300, 0x200D}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0300\u0308\u200D", expected: [][]rune{{0x0300, 0x0308, 0x200D}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0300\u0378", expected: [][]rune{{0x0300}, {0x0378}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0300\u0308\u0378", expected: [][]rune{{0x0300, 0x0308}, {0x0378}}}, // ÷ [0.2] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u200D\u0020", expected: [][]rune{{0x200D}, {0x0020}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u200D\u0308\u0020", expected: [][]rune{{0x200D, 0x0308}, {0x0020}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u200D\u000D", expected: [][]rune{{0x200D}, {0x000D}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u200D\u0308\u000D", expected: [][]rune{{0x200D, 0x0308}, {0x000D}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u200D\u000A", expected: [][]rune{{0x200D}, {0x000A}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u200D\u0308\u000A", expected: [][]rune{{0x200D, 0x0308}, {0x000A}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u200D\u0001", expected: [][]rune{{0x200D}, {0x0001}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u200D\u0308\u0001", expected: [][]rune{{0x200D, 0x0308}, {0x0001}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u200D\u034F", expected: [][]rune{{0x200D, 0x034F}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u200D\u0308\u034F", expected: [][]rune{{0x200D, 0x0308, 0x034F}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u200D\U0001F1E6", expected: [][]rune{{0x200D}, {0x1F1E6}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u200D\u0308\U0001F1E6", expected: [][]rune{{0x200D, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u200D\u0600", expected: [][]rune{{0x200D}, {0x0600}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u200D\u0308\u0600", expected: [][]rune{{0x200D, 0x0308}, {0x0600}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u200D\u0903", expected: [][]rune{{0x200D, 0x0903}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u200D\u0308\u0903", expected: [][]rune{{0x200D, 0x0308, 0x0903}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u200D\u1100", expected: [][]rune{{0x200D}, {0x1100}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u200D\u0308\u1100", expected: [][]rune{{0x200D, 0x0308}, {0x1100}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u200D\u1160", expected: [][]rune{{0x200D}, {0x1160}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u200D\u0308\u1160", expected: [][]rune{{0x200D, 0x0308}, {0x1160}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u200D\u11A8", expected: [][]rune{{0x200D}, {0x11A8}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u200D\u0308\u11A8", expected: [][]rune{{0x200D, 0x0308}, {0x11A8}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u200D\uAC00", expected: [][]rune{{0x200D}, {0xAC00}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u200D\u0308\uAC00", expected: [][]rune{{0x200D, 0x0308}, {0xAC00}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u200D\uAC01", expected: [][]rune{{0x200D}, {0xAC01}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u200D\u0308\uAC01", expected: [][]rune{{0x200D, 0x0308}, {0xAC01}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u200D\u231A", expected: [][]rune{{0x200D}, {0x231A}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u200D\u0308\u231A", expected: [][]rune{{0x200D, 0x0308}, {0x231A}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u200D\u0300", expected: [][]rune{{0x200D, 0x0300}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u200D\u0308\u0300", expected: [][]rune{{0x200D, 0x0308, 0x0300}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u200D\u200D", expected: [][]rune{{0x200D, 0x200D}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u200D\u0308\u200D", expected: [][]rune{{0x200D, 0x0308, 0x200D}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u200D\u0378", expected: [][]rune{{0x200D}, {0x0378}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u200D\u0308\u0378", expected: [][]rune{{0x200D, 0x0308}, {0x0378}}}, // ÷ [0.2] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0378\u0020", expected: [][]rune{{0x0378}, {0x0020}}}, // ÷ [0.2] (Other) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0378\u0308\u0020", expected: [][]rune{{0x0378, 0x0308}, {0x0020}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u0378\u000D", expected: [][]rune{{0x0378}, {0x000D}}}, // ÷ [0.2] (Other) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0378\u0308\u000D", expected: [][]rune{{0x0378, 0x0308}, {0x000D}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (CR) ÷ [0.3] - {original: "\u0378\u000A", expected: [][]rune{{0x0378}, {0x000A}}}, // ÷ [0.2] (Other) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0378\u0308\u000A", expected: [][]rune{{0x0378, 0x0308}, {0x000A}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (LF) ÷ [0.3] - {original: "\u0378\u0001", expected: [][]rune{{0x0378}, {0x0001}}}, // ÷ [0.2] (Other) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0378\u0308\u0001", expected: [][]rune{{0x0378, 0x0308}, {0x0001}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [5.0] (Control) ÷ [0.3] - {original: "\u0378\u034F", expected: [][]rune{{0x0378, 0x034F}}}, // ÷ [0.2] (Other) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0378\u0308\u034F", expected: [][]rune{{0x0378, 0x0308, 0x034F}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAPHEME JOINER (Extend) ÷ [0.3] - {original: "\u0378\U0001F1E6", expected: [][]rune{{0x0378}, {0x1F1E6}}}, // ÷ [0.2] (Other) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0378\u0308\U0001F1E6", expected: [][]rune{{0x0378, 0x0308}, {0x1F1E6}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) ÷ [0.3] - {original: "\u0378\u0600", expected: [][]rune{{0x0378}, {0x0600}}}, // ÷ [0.2] (Other) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0378\u0308\u0600", expected: [][]rune{{0x0378, 0x0308}, {0x0600}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) ÷ [0.3] - {original: "\u0378\u0903", expected: [][]rune{{0x0378, 0x0903}}}, // ÷ [0.2] (Other) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0378\u0308\u0903", expected: [][]rune{{0x0378, 0x0308, 0x0903}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [0.3] - {original: "\u0378\u1100", expected: [][]rune{{0x0378}, {0x1100}}}, // ÷ [0.2] (Other) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0378\u0308\u1100", expected: [][]rune{{0x0378, 0x0308}, {0x1100}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\u0378\u1160", expected: [][]rune{{0x0378}, {0x1160}}}, // ÷ [0.2] (Other) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0378\u0308\u1160", expected: [][]rune{{0x0378, 0x0308}, {0x1160}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JUNGSEONG FILLER (V) ÷ [0.3] - {original: "\u0378\u11A8", expected: [][]rune{{0x0378}, {0x11A8}}}, // ÷ [0.2] (Other) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0378\u0308\u11A8", expected: [][]rune{{0x0378, 0x0308}, {0x11A8}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL JONGSEONG KIYEOK (T) ÷ [0.3] - {original: "\u0378\uAC00", expected: [][]rune{{0x0378}, {0xAC00}}}, // ÷ [0.2] (Other) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0378\u0308\uAC00", expected: [][]rune{{0x0378, 0x0308}, {0xAC00}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GA (LV) ÷ [0.3] - {original: "\u0378\uAC01", expected: [][]rune{{0x0378}, {0xAC01}}}, // ÷ [0.2] (Other) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0378\u0308\uAC01", expected: [][]rune{{0x0378, 0x0308}, {0xAC01}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] HANGUL SYLLABLE GAG (LVT) ÷ [0.3] - {original: "\u0378\u231A", expected: [][]rune{{0x0378}, {0x231A}}}, // ÷ [0.2] (Other) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0378\u0308\u231A", expected: [][]rune{{0x0378, 0x0308}, {0x231A}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] WATCH (ExtPict) ÷ [0.3] - {original: "\u0378\u0300", expected: [][]rune{{0x0378, 0x0300}}}, // ÷ [0.2] (Other) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0378\u0308\u0300", expected: [][]rune{{0x0378, 0x0308, 0x0300}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] COMBINING GRAVE ACCENT (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0378\u200D", expected: [][]rune{{0x0378, 0x200D}}}, // ÷ [0.2] (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0378\u0308\u200D", expected: [][]rune{{0x0378, 0x0308, 0x200D}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0378\u0378", expected: [][]rune{{0x0378}, {0x0378}}}, // ÷ [0.2] (Other) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u0378\u0308\u0378", expected: [][]rune{{0x0378, 0x0308}, {0x0378}}}, // ÷ [0.2] (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] (Other) ÷ [0.3] - {original: "\u000D\u000A\u0061\u000A\u0308", expected: [][]rune{{0x000D, 0x000A}, {0x0061}, {0x000A}, {0x0308}}}, // ÷ [0.2] (CR) × [3.0] (LF) ÷ [4.0] LATIN SMALL LETTER A (Other) ÷ [5.0] (LF) ÷ [4.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0061\u0308", expected: [][]rune{{0x0061, 0x0308}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [0.3] - {original: "\u0020\u200D\u0646", expected: [][]rune{{0x0020, 0x200D}, {0x0646}}}, // ÷ [0.2] SPACE (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] ARABIC LETTER NOON (Other) ÷ [0.3] - {original: "\u0646\u200D\u0020", expected: [][]rune{{0x0646, 0x200D}, {0x0020}}}, // ÷ [0.2] ARABIC LETTER NOON (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] SPACE (Other) ÷ [0.3] - {original: "\u1100\u1100", expected: [][]rune{{0x1100, 0x1100}}}, // ÷ [0.2] HANGUL CHOSEONG KIYEOK (L) × [6.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\uAC00\u11A8\u1100", expected: [][]rune{{0xAC00, 0x11A8}, {0x1100}}}, // ÷ [0.2] HANGUL SYLLABLE GA (LV) × [7.0] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\uAC01\u11A8\u1100", expected: [][]rune{{0xAC01, 0x11A8}, {0x1100}}}, // ÷ [0.2] HANGUL SYLLABLE GAG (LVT) × [8.0] HANGUL JONGSEONG KIYEOK (T) ÷ [999.0] HANGUL CHOSEONG KIYEOK (L) ÷ [0.3] - {original: "\U0001F1E6\U0001F1E7\U0001F1E8\u0062", expected: [][]rune{{0x1F1E6, 0x1F1E7}, {0x1F1E8}, {0x0062}}}, // ÷ [0.2] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [12.0] REGIONAL INDICATOR SYMBOL LETTER B (RI) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER C (RI) ÷ [999.0] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\u0061\U0001F1E6\U0001F1E7\U0001F1E8\u0062", expected: [][]rune{{0x0061}, {0x1F1E6, 0x1F1E7}, {0x1F1E8}, {0x0062}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [13.0] REGIONAL INDICATOR SYMBOL LETTER B (RI) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER C (RI) ÷ [999.0] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\u0061\U0001F1E6\U0001F1E7\u200D\U0001F1E8\u0062", expected: [][]rune{{0x0061}, {0x1F1E6, 0x1F1E7, 0x200D}, {0x1F1E8}, {0x0062}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [13.0] REGIONAL INDICATOR SYMBOL LETTER B (RI) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER C (RI) ÷ [999.0] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\u0061\U0001F1E6\u200D\U0001F1E7\U0001F1E8\u0062", expected: [][]rune{{0x0061}, {0x1F1E6, 0x200D}, {0x1F1E7, 0x1F1E8}, {0x0062}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER B (RI) × [13.0] REGIONAL INDICATOR SYMBOL LETTER C (RI) ÷ [999.0] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\u0061\U0001F1E6\U0001F1E7\U0001F1E8\U0001F1E9\u0062", expected: [][]rune{{0x0061}, {0x1F1E6, 0x1F1E7}, {0x1F1E8, 0x1F1E9}, {0x0062}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER A (RI) × [13.0] REGIONAL INDICATOR SYMBOL LETTER B (RI) ÷ [999.0] REGIONAL INDICATOR SYMBOL LETTER C (RI) × [13.0] REGIONAL INDICATOR SYMBOL LETTER D (RI) ÷ [999.0] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\u0061\u200D", expected: [][]rune{{0x0061, 0x200D}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [0.3] - {original: "\u0061\u0308\u0062", expected: [][]rune{{0x0061, 0x0308}, {0x0062}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) ÷ [999.0] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\u0061\u0903\u0062", expected: [][]rune{{0x0061, 0x0903}, {0x0062}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.1] DEVANAGARI SIGN VISARGA (SpacingMark) ÷ [999.0] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\u0061\u0600\u0062", expected: [][]rune{{0x0061}, {0x0600, 0x0062}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) ÷ [999.0] ARABIC NUMBER SIGN (Prepend) × [9.2] LATIN SMALL LETTER B (Other) ÷ [0.3] - {original: "\U0001F476\U0001F3FF\U0001F476", expected: [][]rune{{0x1F476, 0x1F3FF}, {0x1F476}}}, // ÷ [0.2] BABY (ExtPict) × [9.0] EMOJI MODIFIER FITZPATRICK TYPE-6 (Extend) ÷ [999.0] BABY (ExtPict) ÷ [0.3] - {original: "\u0061\U0001F3FF\U0001F476", expected: [][]rune{{0x0061, 0x1F3FF}, {0x1F476}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.0] EMOJI MODIFIER FITZPATRICK TYPE-6 (Extend) ÷ [999.0] BABY (ExtPict) ÷ [0.3] - {original: "\u0061\U0001F3FF\U0001F476\u200D\U0001F6D1", expected: [][]rune{{0x0061, 0x1F3FF}, {0x1F476, 0x200D, 0x1F6D1}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.0] EMOJI MODIFIER FITZPATRICK TYPE-6 (Extend) ÷ [999.0] BABY (ExtPict) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [11.0] OCTAGONAL SIGN (ExtPict) ÷ [0.3] - {original: "\U0001F476\U0001F3FF\u0308\u200D\U0001F476\U0001F3FF", expected: [][]rune{{0x1F476, 0x1F3FF, 0x0308, 0x200D, 0x1F476, 0x1F3FF}}}, // ÷ [0.2] BABY (ExtPict) × [9.0] EMOJI MODIFIER FITZPATRICK TYPE-6 (Extend) × [9.0] COMBINING DIAERESIS (Extend_ExtCccZwj) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [11.0] BABY (ExtPict) × [9.0] EMOJI MODIFIER FITZPATRICK TYPE-6 (Extend) ÷ [0.3] - {original: "\U0001F6D1\u200D\U0001F6D1", expected: [][]rune{{0x1F6D1, 0x200D, 0x1F6D1}}}, // ÷ [0.2] OCTAGONAL SIGN (ExtPict) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [11.0] OCTAGONAL SIGN (ExtPict) ÷ [0.3] - {original: "\u0061\u200D\U0001F6D1", expected: [][]rune{{0x0061, 0x200D}, {0x1F6D1}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] OCTAGONAL SIGN (ExtPict) ÷ [0.3] - {original: "\u2701\u200D\u2701", expected: [][]rune{{0x2701, 0x200D, 0x2701}}}, // ÷ [0.2] UPPER BLADE SCISSORS (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) × [11.0] UPPER BLADE SCISSORS (Other) ÷ [0.3] - {original: "\u0061\u200D\u2701", expected: [][]rune{{0x0061, 0x200D}, {0x2701}}}, // ÷ [0.2] LATIN SMALL LETTER A (Other) × [9.0] ZERO WIDTH JOINER (ZWJ_ExtCccZwj) ÷ [999.0] UPPER BLADE SCISSORS (Other) ÷ [0.3] -} - -// decomposed returns a grapheme cluster decomposition. -func decomposed(s string) (runes [][]rune) { - gr := NewGraphemes(s) - for gr.Next() { - runes = append(runes, gr.Runes()) - } - return -} - -// Run the testCases slice above. -func TestSimple(t *testing.T) { - for testNum, testCase := range testCases { - /*t.Logf(`Test case %d "%s": Expecting %x, getting %x, code points %x"`, - testNum, - strings.TrimSpace(testCase.original), - testCase.expected, - decomposed(testCase.original), - []rune(testCase.original))*/ - gr := NewGraphemes(testCase.original) - var index int - GraphemeLoop: - for index = 0; gr.Next(); index++ { - if index >= len(testCase.expected) { - t.Errorf(`Test case %d "%s" failed: More grapheme clusters returned than expected %d`, - testNum, - testCase.original, - len(testCase.expected)) - break - } - cluster := gr.Runes() - if len(cluster) != len(testCase.expected[index]) { - t.Errorf(`Test case %d "%s" failed: Grapheme cluster at index %d has %d codepoints %x, %d expected %x`, - testNum, - testCase.original, - index, - len(cluster), - cluster, - len(testCase.expected[index]), - testCase.expected[index]) - break - } - for i, r := range cluster { - if r != testCase.expected[index][i] { - t.Errorf(`Test case %d "%s" failed: Grapheme cluster at index %d is %x, expected %x`, - testNum, - testCase.original, - index, - cluster, - testCase.expected[index]) - break GraphemeLoop - } - } - } - if index < len(testCase.expected) { - t.Errorf(`Test case %d "%s" failed: Fewer grapheme clusters returned (%d) than expected (%d)`, - testNum, - testCase.original, - index, - len(testCase.expected)) - } - } -} - -// Test the Str() function. -func TestStr(t *testing.T) { - gr := NewGraphemes("möp") - gr.Next() - gr.Next() - gr.Next() - if str := gr.Str(); str != "p" { - t.Errorf(`Expected "p", got "%s"`, str) - } -} - -// Test the Bytes() function. -func TestBytes(t *testing.T) { - gr := NewGraphemes("A👩‍❤️‍💋‍👩B") - gr.Next() - gr.Next() - gr.Next() - b := gr.Bytes() - if len(b) != 1 { - t.Fatalf(`Expected len("B") == 1, got %d`, len(b)) - } - if b[0] != 'B' { - t.Errorf(`Expected "B", got "%s"`, string(b[0])) - } -} - -// Test the Positions() function. -func TestPositions(t *testing.T) { - gr := NewGraphemes("A👩‍❤️‍💋‍👩B") - gr.Next() - gr.Next() - from, to := gr.Positions() - if from != 1 || to != 28 { - t.Errorf(`Expected from=%d to=%d, got from=%d to=%d`, 1, 28, from, to) - } -} - -// Test the Reset() function. -func TestReset(t *testing.T) { - gr := NewGraphemes("möp") - gr.Next() - gr.Next() - gr.Next() - gr.Reset() - gr.Next() - if str := gr.Str(); str != "m" { - t.Errorf(`Expected "m", got "%s"`, str) - } -} - -// Test retrieving clusters before calling Next(). -func TestEarly(t *testing.T) { - gr := NewGraphemes("test") - r := gr.Runes() - if r != nil { - t.Errorf(`Expected nil rune slice, got %x`, r) - } - str := gr.Str() - if str != "" { - t.Errorf(`Expected empty string, got "%s"`, str) - } - b := gr.Bytes() - if b != nil { - t.Errorf(`Expected byte rune slice, got %x`, b) - } - from, to := gr.Positions() - if from != 0 || to != 0 { - t.Errorf(`Expected from=%d to=%d, got from=%d to=%d`, 0, 0, from, to) - } -} - -// Test retrieving more clusters after retrieving the last cluster. -func TestLate(t *testing.T) { - gr := NewGraphemes("x") - gr.Next() - gr.Next() - r := gr.Runes() - if r != nil { - t.Errorf(`Expected nil rune slice, got %x`, r) - } - str := gr.Str() - if str != "" { - t.Errorf(`Expected empty string, got "%s"`, str) - } - b := gr.Bytes() - if b != nil { - t.Errorf(`Expected byte rune slice, got %x`, b) - } - from, to := gr.Positions() - if from != 1 || to != 1 { - t.Errorf(`Expected from=%d to=%d, got from=%d to=%d`, 1, 1, from, to) - } -} - -// Test the GraphemeClusterCount function. -func TestCount(t *testing.T) { - if n := GraphemeClusterCount("🇩🇪🏳️‍🌈"); n != 2 { - t.Errorf(`Expected 2 grapheme clusters, got %d`, n) - } -} diff --git a/vendor/github.com/rivo/uniseg/properties.go b/vendor/github.com/rivo/uniseg/properties.go deleted file mode 100644 index a75ab58..0000000 --- a/vendor/github.com/rivo/uniseg/properties.go +++ /dev/null @@ -1,1658 +0,0 @@ -package uniseg - -// The unicode properties. Only the ones needed in the context of this package -// are included. -const ( - prAny = iota - prPreprend - prCR - prLF - prControl - prExtend - prRegionalIndicator - prSpacingMark - prL - prV - prT - prLV - prLVT - prZWJ - prExtendedPictographic -) - -// Maps code point ranges to their properties. In the context of this package, -// any code point that is not contained may map to "prAny". The code point -// ranges in this slice are numerically sorted. -// -// These ranges were taken from -// http://www.unicode.org/Public/UCD/latest/ucd/auxiliary/GraphemeBreakProperty.txt -// as well as -// https://unicode.org/Public/emoji/latest/emoji-data.txt -// ("Extended_Pictographic" only) on March 11, 2019. See -// https://www.unicode.org/license.html for the Unicode license agreement. -var codePoints = [][3]int{ - {0x0000, 0x0009, prControl}, // Cc [10] .. - {0x000A, 0x000A, prLF}, // Cc - {0x000B, 0x000C, prControl}, // Cc [2] .. - {0x000D, 0x000D, prCR}, // Cc - {0x000E, 0x001F, prControl}, // Cc [18] .. - {0x007F, 0x009F, prControl}, // Cc [33] .. - {0x00A9, 0x00A9, prExtendedPictographic}, // 1.1 [1] (©️) copyright - {0x00AD, 0x00AD, prControl}, // Cf SOFT HYPHEN - {0x00AE, 0x00AE, prExtendedPictographic}, // 1.1 [1] (®️) registered - {0x0300, 0x036F, prExtend}, // Mn [112] COMBINING GRAVE ACCENT..COMBINING LATIN SMALL LETTER X - {0x0483, 0x0487, prExtend}, // Mn [5] COMBINING CYRILLIC TITLO..COMBINING CYRILLIC POKRYTIE - {0x0488, 0x0489, prExtend}, // Me [2] COMBINING CYRILLIC HUNDRED THOUSANDS SIGN..COMBINING CYRILLIC MILLIONS SIGN - {0x0591, 0x05BD, prExtend}, // Mn [45] HEBREW ACCENT ETNAHTA..HEBREW POINT METEG - {0x05BF, 0x05BF, prExtend}, // Mn HEBREW POINT RAFE - {0x05C1, 0x05C2, prExtend}, // Mn [2] HEBREW POINT SHIN DOT..HEBREW POINT SIN DOT - {0x05C4, 0x05C5, prExtend}, // Mn [2] HEBREW MARK UPPER DOT..HEBREW MARK LOWER DOT - {0x05C7, 0x05C7, prExtend}, // Mn HEBREW POINT QAMATS QATAN - {0x0600, 0x0605, prPreprend}, // Cf [6] ARABIC NUMBER SIGN..ARABIC NUMBER MARK ABOVE - {0x0610, 0x061A, prExtend}, // Mn [11] ARABIC SIGN SALLALLAHOU ALAYHE WASSALLAM..ARABIC SMALL KASRA - {0x061C, 0x061C, prControl}, // Cf ARABIC LETTER MARK - {0x064B, 0x065F, prExtend}, // Mn [21] ARABIC FATHATAN..ARABIC WAVY HAMZA BELOW - {0x0670, 0x0670, prExtend}, // Mn ARABIC LETTER SUPERSCRIPT ALEF - {0x06D6, 0x06DC, prExtend}, // Mn [7] ARABIC SMALL HIGH LIGATURE SAD WITH LAM WITH ALEF MAKSURA..ARABIC SMALL HIGH SEEN - {0x06DD, 0x06DD, prPreprend}, // Cf ARABIC END OF AYAH - {0x06DF, 0x06E4, prExtend}, // Mn [6] ARABIC SMALL HIGH ROUNDED ZERO..ARABIC SMALL HIGH MADDA - {0x06E7, 0x06E8, prExtend}, // Mn [2] ARABIC SMALL HIGH YEH..ARABIC SMALL HIGH NOON - {0x06EA, 0x06ED, prExtend}, // Mn [4] ARABIC EMPTY CENTRE LOW STOP..ARABIC SMALL LOW MEEM - {0x070F, 0x070F, prPreprend}, // Cf SYRIAC ABBREVIATION MARK - {0x0711, 0x0711, prExtend}, // Mn SYRIAC LETTER SUPERSCRIPT ALAPH - {0x0730, 0x074A, prExtend}, // Mn [27] SYRIAC PTHAHA ABOVE..SYRIAC BARREKH - {0x07A6, 0x07B0, prExtend}, // Mn [11] THAANA ABAFILI..THAANA SUKUN - {0x07EB, 0x07F3, prExtend}, // Mn [9] NKO COMBINING SHORT HIGH TONE..NKO COMBINING DOUBLE DOT ABOVE - {0x07FD, 0x07FD, prExtend}, // Mn NKO DANTAYALAN - {0x0816, 0x0819, prExtend}, // Mn [4] SAMARITAN MARK IN..SAMARITAN MARK DAGESH - {0x081B, 0x0823, prExtend}, // Mn [9] SAMARITAN MARK EPENTHETIC YUT..SAMARITAN VOWEL SIGN A - {0x0825, 0x0827, prExtend}, // Mn [3] SAMARITAN VOWEL SIGN SHORT A..SAMARITAN VOWEL SIGN U - {0x0829, 0x082D, prExtend}, // Mn [5] SAMARITAN VOWEL SIGN LONG I..SAMARITAN MARK NEQUDAA - {0x0859, 0x085B, prExtend}, // Mn [3] MANDAIC AFFRICATION MARK..MANDAIC GEMINATION MARK - {0x08D3, 0x08E1, prExtend}, // Mn [15] ARABIC SMALL LOW WAW..ARABIC SMALL HIGH SIGN SAFHA - {0x08E2, 0x08E2, prPreprend}, // Cf ARABIC DISPUTED END OF AYAH - {0x08E3, 0x0902, prExtend}, // Mn [32] ARABIC TURNED DAMMA BELOW..DEVANAGARI SIGN ANUSVARA - {0x0903, 0x0903, prSpacingMark}, // Mc DEVANAGARI SIGN VISARGA - {0x093A, 0x093A, prExtend}, // Mn DEVANAGARI VOWEL SIGN OE - {0x093B, 0x093B, prSpacingMark}, // Mc DEVANAGARI VOWEL SIGN OOE - {0x093C, 0x093C, prExtend}, // Mn DEVANAGARI SIGN NUKTA - {0x093E, 0x0940, prSpacingMark}, // Mc [3] DEVANAGARI VOWEL SIGN AA..DEVANAGARI VOWEL SIGN II - {0x0941, 0x0948, prExtend}, // Mn [8] DEVANAGARI VOWEL SIGN U..DEVANAGARI VOWEL SIGN AI - {0x0949, 0x094C, prSpacingMark}, // Mc [4] DEVANAGARI VOWEL SIGN CANDRA O..DEVANAGARI VOWEL SIGN AU - {0x094D, 0x094D, prExtend}, // Mn DEVANAGARI SIGN VIRAMA - {0x094E, 0x094F, prSpacingMark}, // Mc [2] DEVANAGARI VOWEL SIGN PRISHTHAMATRA E..DEVANAGARI VOWEL SIGN AW - {0x0951, 0x0957, prExtend}, // Mn [7] DEVANAGARI STRESS SIGN UDATTA..DEVANAGARI VOWEL SIGN UUE - {0x0962, 0x0963, prExtend}, // Mn [2] DEVANAGARI VOWEL SIGN VOCALIC L..DEVANAGARI VOWEL SIGN VOCALIC LL - {0x0981, 0x0981, prExtend}, // Mn BENGALI SIGN CANDRABINDU - {0x0982, 0x0983, prSpacingMark}, // Mc [2] BENGALI SIGN ANUSVARA..BENGALI SIGN VISARGA - {0x09BC, 0x09BC, prExtend}, // Mn BENGALI SIGN NUKTA - {0x09BE, 0x09BE, prExtend}, // Mc BENGALI VOWEL SIGN AA - {0x09BF, 0x09C0, prSpacingMark}, // Mc [2] BENGALI VOWEL SIGN I..BENGALI VOWEL SIGN II - {0x09C1, 0x09C4, prExtend}, // Mn [4] BENGALI VOWEL SIGN U..BENGALI VOWEL SIGN VOCALIC RR - {0x09C7, 0x09C8, prSpacingMark}, // Mc [2] BENGALI VOWEL SIGN E..BENGALI VOWEL SIGN AI - {0x09CB, 0x09CC, prSpacingMark}, // Mc [2] BENGALI VOWEL SIGN O..BENGALI VOWEL SIGN AU - {0x09CD, 0x09CD, prExtend}, // Mn BENGALI SIGN VIRAMA - {0x09D7, 0x09D7, prExtend}, // Mc BENGALI AU LENGTH MARK - {0x09E2, 0x09E3, prExtend}, // Mn [2] BENGALI VOWEL SIGN VOCALIC L..BENGALI VOWEL SIGN VOCALIC LL - {0x09FE, 0x09FE, prExtend}, // Mn BENGALI SANDHI MARK - {0x0A01, 0x0A02, prExtend}, // Mn [2] GURMUKHI SIGN ADAK BINDI..GURMUKHI SIGN BINDI - {0x0A03, 0x0A03, prSpacingMark}, // Mc GURMUKHI SIGN VISARGA - {0x0A3C, 0x0A3C, prExtend}, // Mn GURMUKHI SIGN NUKTA - {0x0A3E, 0x0A40, prSpacingMark}, // Mc [3] GURMUKHI VOWEL SIGN AA..GURMUKHI VOWEL SIGN II - {0x0A41, 0x0A42, prExtend}, // Mn [2] GURMUKHI VOWEL SIGN U..GURMUKHI VOWEL SIGN UU - {0x0A47, 0x0A48, prExtend}, // Mn [2] GURMUKHI VOWEL SIGN EE..GURMUKHI VOWEL SIGN AI - {0x0A4B, 0x0A4D, prExtend}, // Mn [3] GURMUKHI VOWEL SIGN OO..GURMUKHI SIGN VIRAMA - {0x0A51, 0x0A51, prExtend}, // Mn GURMUKHI SIGN UDAAT - {0x0A70, 0x0A71, prExtend}, // Mn [2] GURMUKHI TIPPI..GURMUKHI ADDAK - {0x0A75, 0x0A75, prExtend}, // Mn GURMUKHI SIGN YAKASH - {0x0A81, 0x0A82, prExtend}, // Mn [2] GUJARATI SIGN CANDRABINDU..GUJARATI SIGN ANUSVARA - {0x0A83, 0x0A83, prSpacingMark}, // Mc GUJARATI SIGN VISARGA - {0x0ABC, 0x0ABC, prExtend}, // Mn GUJARATI SIGN NUKTA - {0x0ABE, 0x0AC0, prSpacingMark}, // Mc [3] GUJARATI VOWEL SIGN AA..GUJARATI VOWEL SIGN II - {0x0AC1, 0x0AC5, prExtend}, // Mn [5] GUJARATI VOWEL SIGN U..GUJARATI VOWEL SIGN CANDRA E - {0x0AC7, 0x0AC8, prExtend}, // Mn [2] GUJARATI VOWEL SIGN E..GUJARATI VOWEL SIGN AI - {0x0AC9, 0x0AC9, prSpacingMark}, // Mc GUJARATI VOWEL SIGN CANDRA O - {0x0ACB, 0x0ACC, prSpacingMark}, // Mc [2] GUJARATI VOWEL SIGN O..GUJARATI VOWEL SIGN AU - {0x0ACD, 0x0ACD, prExtend}, // Mn GUJARATI SIGN VIRAMA - {0x0AE2, 0x0AE3, prExtend}, // Mn [2] GUJARATI VOWEL SIGN VOCALIC L..GUJARATI VOWEL SIGN VOCALIC LL - {0x0AFA, 0x0AFF, prExtend}, // Mn [6] GUJARATI SIGN SUKUN..GUJARATI SIGN TWO-CIRCLE NUKTA ABOVE - {0x0B01, 0x0B01, prExtend}, // Mn ORIYA SIGN CANDRABINDU - {0x0B02, 0x0B03, prSpacingMark}, // Mc [2] ORIYA SIGN ANUSVARA..ORIYA SIGN VISARGA - {0x0B3C, 0x0B3C, prExtend}, // Mn ORIYA SIGN NUKTA - {0x0B3E, 0x0B3E, prExtend}, // Mc ORIYA VOWEL SIGN AA - {0x0B3F, 0x0B3F, prExtend}, // Mn ORIYA VOWEL SIGN I - {0x0B40, 0x0B40, prSpacingMark}, // Mc ORIYA VOWEL SIGN II - {0x0B41, 0x0B44, prExtend}, // Mn [4] ORIYA VOWEL SIGN U..ORIYA VOWEL SIGN VOCALIC RR - {0x0B47, 0x0B48, prSpacingMark}, // Mc [2] ORIYA VOWEL SIGN E..ORIYA VOWEL SIGN AI - {0x0B4B, 0x0B4C, prSpacingMark}, // Mc [2] ORIYA VOWEL SIGN O..ORIYA VOWEL SIGN AU - {0x0B4D, 0x0B4D, prExtend}, // Mn ORIYA SIGN VIRAMA - {0x0B56, 0x0B56, prExtend}, // Mn ORIYA AI LENGTH MARK - {0x0B57, 0x0B57, prExtend}, // Mc ORIYA AU LENGTH MARK - {0x0B62, 0x0B63, prExtend}, // Mn [2] ORIYA VOWEL SIGN VOCALIC L..ORIYA VOWEL SIGN VOCALIC LL - {0x0B82, 0x0B82, prExtend}, // Mn TAMIL SIGN ANUSVARA - {0x0BBE, 0x0BBE, prExtend}, // Mc TAMIL VOWEL SIGN AA - {0x0BBF, 0x0BBF, prSpacingMark}, // Mc TAMIL VOWEL SIGN I - {0x0BC0, 0x0BC0, prExtend}, // Mn TAMIL VOWEL SIGN II - {0x0BC1, 0x0BC2, prSpacingMark}, // Mc [2] TAMIL VOWEL SIGN U..TAMIL VOWEL SIGN UU - {0x0BC6, 0x0BC8, prSpacingMark}, // Mc [3] TAMIL VOWEL SIGN E..TAMIL VOWEL SIGN AI - {0x0BCA, 0x0BCC, prSpacingMark}, // Mc [3] TAMIL VOWEL SIGN O..TAMIL VOWEL SIGN AU - {0x0BCD, 0x0BCD, prExtend}, // Mn TAMIL SIGN VIRAMA - {0x0BD7, 0x0BD7, prExtend}, // Mc TAMIL AU LENGTH MARK - {0x0C00, 0x0C00, prExtend}, // Mn TELUGU SIGN COMBINING CANDRABINDU ABOVE - {0x0C01, 0x0C03, prSpacingMark}, // Mc [3] TELUGU SIGN CANDRABINDU..TELUGU SIGN VISARGA - {0x0C04, 0x0C04, prExtend}, // Mn TELUGU SIGN COMBINING ANUSVARA ABOVE - {0x0C3E, 0x0C40, prExtend}, // Mn [3] TELUGU VOWEL SIGN AA..TELUGU VOWEL SIGN II - {0x0C41, 0x0C44, prSpacingMark}, // Mc [4] TELUGU VOWEL SIGN U..TELUGU VOWEL SIGN VOCALIC RR - {0x0C46, 0x0C48, prExtend}, // Mn [3] TELUGU VOWEL SIGN E..TELUGU VOWEL SIGN AI - {0x0C4A, 0x0C4D, prExtend}, // Mn [4] TELUGU VOWEL SIGN O..TELUGU SIGN VIRAMA - {0x0C55, 0x0C56, prExtend}, // Mn [2] TELUGU LENGTH MARK..TELUGU AI LENGTH MARK - {0x0C62, 0x0C63, prExtend}, // Mn [2] TELUGU VOWEL SIGN VOCALIC L..TELUGU VOWEL SIGN VOCALIC LL - {0x0C81, 0x0C81, prExtend}, // Mn KANNADA SIGN CANDRABINDU - {0x0C82, 0x0C83, prSpacingMark}, // Mc [2] KANNADA SIGN ANUSVARA..KANNADA SIGN VISARGA - {0x0CBC, 0x0CBC, prExtend}, // Mn KANNADA SIGN NUKTA - {0x0CBE, 0x0CBE, prSpacingMark}, // Mc KANNADA VOWEL SIGN AA - {0x0CBF, 0x0CBF, prExtend}, // Mn KANNADA VOWEL SIGN I - {0x0CC0, 0x0CC1, prSpacingMark}, // Mc [2] KANNADA VOWEL SIGN II..KANNADA VOWEL SIGN U - {0x0CC2, 0x0CC2, prExtend}, // Mc KANNADA VOWEL SIGN UU - {0x0CC3, 0x0CC4, prSpacingMark}, // Mc [2] KANNADA VOWEL SIGN VOCALIC R..KANNADA VOWEL SIGN VOCALIC RR - {0x0CC6, 0x0CC6, prExtend}, // Mn KANNADA VOWEL SIGN E - {0x0CC7, 0x0CC8, prSpacingMark}, // Mc [2] KANNADA VOWEL SIGN EE..KANNADA VOWEL SIGN AI - {0x0CCA, 0x0CCB, prSpacingMark}, // Mc [2] KANNADA VOWEL SIGN O..KANNADA VOWEL SIGN OO - {0x0CCC, 0x0CCD, prExtend}, // Mn [2] KANNADA VOWEL SIGN AU..KANNADA SIGN VIRAMA - {0x0CD5, 0x0CD6, prExtend}, // Mc [2] KANNADA LENGTH MARK..KANNADA AI LENGTH MARK - {0x0CE2, 0x0CE3, prExtend}, // Mn [2] KANNADA VOWEL SIGN VOCALIC L..KANNADA VOWEL SIGN VOCALIC LL - {0x0D00, 0x0D01, prExtend}, // Mn [2] MALAYALAM SIGN COMBINING ANUSVARA ABOVE..MALAYALAM SIGN CANDRABINDU - {0x0D02, 0x0D03, prSpacingMark}, // Mc [2] MALAYALAM SIGN ANUSVARA..MALAYALAM SIGN VISARGA - {0x0D3B, 0x0D3C, prExtend}, // Mn [2] MALAYALAM SIGN VERTICAL BAR VIRAMA..MALAYALAM SIGN CIRCULAR VIRAMA - {0x0D3E, 0x0D3E, prExtend}, // Mc MALAYALAM VOWEL SIGN AA - {0x0D3F, 0x0D40, prSpacingMark}, // Mc [2] MALAYALAM VOWEL SIGN I..MALAYALAM VOWEL SIGN II - {0x0D41, 0x0D44, prExtend}, // Mn [4] MALAYALAM VOWEL SIGN U..MALAYALAM VOWEL SIGN VOCALIC RR - {0x0D46, 0x0D48, prSpacingMark}, // Mc [3] MALAYALAM VOWEL SIGN E..MALAYALAM VOWEL SIGN AI - {0x0D4A, 0x0D4C, prSpacingMark}, // Mc [3] MALAYALAM VOWEL SIGN O..MALAYALAM VOWEL SIGN AU - {0x0D4D, 0x0D4D, prExtend}, // Mn MALAYALAM SIGN VIRAMA - {0x0D4E, 0x0D4E, prPreprend}, // Lo MALAYALAM LETTER DOT REPH - {0x0D57, 0x0D57, prExtend}, // Mc MALAYALAM AU LENGTH MARK - {0x0D62, 0x0D63, prExtend}, // Mn [2] MALAYALAM VOWEL SIGN VOCALIC L..MALAYALAM VOWEL SIGN VOCALIC LL - {0x0D82, 0x0D83, prSpacingMark}, // Mc [2] SINHALA SIGN ANUSVARAYA..SINHALA SIGN VISARGAYA - {0x0DCA, 0x0DCA, prExtend}, // Mn SINHALA SIGN AL-LAKUNA - {0x0DCF, 0x0DCF, prExtend}, // Mc SINHALA VOWEL SIGN AELA-PILLA - {0x0DD0, 0x0DD1, prSpacingMark}, // Mc [2] SINHALA VOWEL SIGN KETTI AEDA-PILLA..SINHALA VOWEL SIGN DIGA AEDA-PILLA - {0x0DD2, 0x0DD4, prExtend}, // Mn [3] SINHALA VOWEL SIGN KETTI IS-PILLA..SINHALA VOWEL SIGN KETTI PAA-PILLA - {0x0DD6, 0x0DD6, prExtend}, // Mn SINHALA VOWEL SIGN DIGA PAA-PILLA - {0x0DD8, 0x0DDE, prSpacingMark}, // Mc [7] SINHALA VOWEL SIGN GAETTA-PILLA..SINHALA VOWEL SIGN KOMBUVA HAA GAYANUKITTA - {0x0DDF, 0x0DDF, prExtend}, // Mc SINHALA VOWEL SIGN GAYANUKITTA - {0x0DF2, 0x0DF3, prSpacingMark}, // Mc [2] SINHALA VOWEL SIGN DIGA GAETTA-PILLA..SINHALA VOWEL SIGN DIGA GAYANUKITTA - {0x0E31, 0x0E31, prExtend}, // Mn THAI CHARACTER MAI HAN-AKAT - {0x0E33, 0x0E33, prSpacingMark}, // Lo THAI CHARACTER SARA AM - {0x0E34, 0x0E3A, prExtend}, // Mn [7] THAI CHARACTER SARA I..THAI CHARACTER PHINTHU - {0x0E47, 0x0E4E, prExtend}, // Mn [8] THAI CHARACTER MAITAIKHU..THAI CHARACTER YAMAKKAN - {0x0EB1, 0x0EB1, prExtend}, // Mn LAO VOWEL SIGN MAI KAN - {0x0EB3, 0x0EB3, prSpacingMark}, // Lo LAO VOWEL SIGN AM - {0x0EB4, 0x0EBC, prExtend}, // Mn [9] LAO VOWEL SIGN I..LAO SEMIVOWEL SIGN LO - {0x0EC8, 0x0ECD, prExtend}, // Mn [6] LAO TONE MAI EK..LAO NIGGAHITA - {0x0F18, 0x0F19, prExtend}, // Mn [2] TIBETAN ASTROLOGICAL SIGN -KHYUD PA..TIBETAN ASTROLOGICAL SIGN SDONG TSHUGS - {0x0F35, 0x0F35, prExtend}, // Mn TIBETAN MARK NGAS BZUNG NYI ZLA - {0x0F37, 0x0F37, prExtend}, // Mn TIBETAN MARK NGAS BZUNG SGOR RTAGS - {0x0F39, 0x0F39, prExtend}, // Mn TIBETAN MARK TSA -PHRU - {0x0F3E, 0x0F3F, prSpacingMark}, // Mc [2] TIBETAN SIGN YAR TSHES..TIBETAN SIGN MAR TSHES - {0x0F71, 0x0F7E, prExtend}, // Mn [14] TIBETAN VOWEL SIGN AA..TIBETAN SIGN RJES SU NGA RO - {0x0F7F, 0x0F7F, prSpacingMark}, // Mc TIBETAN SIGN RNAM BCAD - {0x0F80, 0x0F84, prExtend}, // Mn [5] TIBETAN VOWEL SIGN REVERSED I..TIBETAN MARK HALANTA - {0x0F86, 0x0F87, prExtend}, // Mn [2] TIBETAN SIGN LCI RTAGS..TIBETAN SIGN YANG RTAGS - {0x0F8D, 0x0F97, prExtend}, // Mn [11] TIBETAN SUBJOINED SIGN LCE TSA CAN..TIBETAN SUBJOINED LETTER JA - {0x0F99, 0x0FBC, prExtend}, // Mn [36] TIBETAN SUBJOINED LETTER NYA..TIBETAN SUBJOINED LETTER FIXED-FORM RA - {0x0FC6, 0x0FC6, prExtend}, // Mn TIBETAN SYMBOL PADMA GDAN - {0x102D, 0x1030, prExtend}, // Mn [4] MYANMAR VOWEL SIGN I..MYANMAR VOWEL SIGN UU - {0x1031, 0x1031, prSpacingMark}, // Mc MYANMAR VOWEL SIGN E - {0x1032, 0x1037, prExtend}, // Mn [6] MYANMAR VOWEL SIGN AI..MYANMAR SIGN DOT BELOW - {0x1039, 0x103A, prExtend}, // Mn [2] MYANMAR SIGN VIRAMA..MYANMAR SIGN ASAT - {0x103B, 0x103C, prSpacingMark}, // Mc [2] MYANMAR CONSONANT SIGN MEDIAL YA..MYANMAR CONSONANT SIGN MEDIAL RA - {0x103D, 0x103E, prExtend}, // Mn [2] MYANMAR CONSONANT SIGN MEDIAL WA..MYANMAR CONSONANT SIGN MEDIAL HA - {0x1056, 0x1057, prSpacingMark}, // Mc [2] MYANMAR VOWEL SIGN VOCALIC R..MYANMAR VOWEL SIGN VOCALIC RR - {0x1058, 0x1059, prExtend}, // Mn [2] MYANMAR VOWEL SIGN VOCALIC L..MYANMAR VOWEL SIGN VOCALIC LL - {0x105E, 0x1060, prExtend}, // Mn [3] MYANMAR CONSONANT SIGN MON MEDIAL NA..MYANMAR CONSONANT SIGN MON MEDIAL LA - {0x1071, 0x1074, prExtend}, // Mn [4] MYANMAR VOWEL SIGN GEBA KAREN I..MYANMAR VOWEL SIGN KAYAH EE - {0x1082, 0x1082, prExtend}, // Mn MYANMAR CONSONANT SIGN SHAN MEDIAL WA - {0x1084, 0x1084, prSpacingMark}, // Mc MYANMAR VOWEL SIGN SHAN E - {0x1085, 0x1086, prExtend}, // Mn [2] MYANMAR VOWEL SIGN SHAN E ABOVE..MYANMAR VOWEL SIGN SHAN FINAL Y - {0x108D, 0x108D, prExtend}, // Mn MYANMAR SIGN SHAN COUNCIL EMPHATIC TONE - {0x109D, 0x109D, prExtend}, // Mn MYANMAR VOWEL SIGN AITON AI - {0x1100, 0x115F, prL}, // Lo [96] HANGUL CHOSEONG KIYEOK..HANGUL CHOSEONG FILLER - {0x1160, 0x11A7, prV}, // Lo [72] HANGUL JUNGSEONG FILLER..HANGUL JUNGSEONG O-YAE - {0x11A8, 0x11FF, prT}, // Lo [88] HANGUL JONGSEONG KIYEOK..HANGUL JONGSEONG SSANGNIEUN - {0x135D, 0x135F, prExtend}, // Mn [3] ETHIOPIC COMBINING GEMINATION AND VOWEL LENGTH MARK..ETHIOPIC COMBINING GEMINATION MARK - {0x1712, 0x1714, prExtend}, // Mn [3] TAGALOG VOWEL SIGN I..TAGALOG SIGN VIRAMA - {0x1732, 0x1734, prExtend}, // Mn [3] HANUNOO VOWEL SIGN I..HANUNOO SIGN PAMUDPOD - {0x1752, 0x1753, prExtend}, // Mn [2] BUHID VOWEL SIGN I..BUHID VOWEL SIGN U - {0x1772, 0x1773, prExtend}, // Mn [2] TAGBANWA VOWEL SIGN I..TAGBANWA VOWEL SIGN U - {0x17B4, 0x17B5, prExtend}, // Mn [2] KHMER VOWEL INHERENT AQ..KHMER VOWEL INHERENT AA - {0x17B6, 0x17B6, prSpacingMark}, // Mc KHMER VOWEL SIGN AA - {0x17B7, 0x17BD, prExtend}, // Mn [7] KHMER VOWEL SIGN I..KHMER VOWEL SIGN UA - {0x17BE, 0x17C5, prSpacingMark}, // Mc [8] KHMER VOWEL SIGN OE..KHMER VOWEL SIGN AU - {0x17C6, 0x17C6, prExtend}, // Mn KHMER SIGN NIKAHIT - {0x17C7, 0x17C8, prSpacingMark}, // Mc [2] KHMER SIGN REAHMUK..KHMER SIGN YUUKALEAPINTU - {0x17C9, 0x17D3, prExtend}, // Mn [11] KHMER SIGN MUUSIKATOAN..KHMER SIGN BATHAMASAT - {0x17DD, 0x17DD, prExtend}, // Mn KHMER SIGN ATTHACAN - {0x180B, 0x180D, prExtend}, // Mn [3] MONGOLIAN FREE VARIATION SELECTOR ONE..MONGOLIAN FREE VARIATION SELECTOR THREE - {0x180E, 0x180E, prControl}, // Cf MONGOLIAN VOWEL SEPARATOR - {0x1885, 0x1886, prExtend}, // Mn [2] MONGOLIAN LETTER ALI GALI BALUDA..MONGOLIAN LETTER ALI GALI THREE BALUDA - {0x18A9, 0x18A9, prExtend}, // Mn MONGOLIAN LETTER ALI GALI DAGALGA - {0x1920, 0x1922, prExtend}, // Mn [3] LIMBU VOWEL SIGN A..LIMBU VOWEL SIGN U - {0x1923, 0x1926, prSpacingMark}, // Mc [4] LIMBU VOWEL SIGN EE..LIMBU VOWEL SIGN AU - {0x1927, 0x1928, prExtend}, // Mn [2] LIMBU VOWEL SIGN E..LIMBU VOWEL SIGN O - {0x1929, 0x192B, prSpacingMark}, // Mc [3] LIMBU SUBJOINED LETTER YA..LIMBU SUBJOINED LETTER WA - {0x1930, 0x1931, prSpacingMark}, // Mc [2] LIMBU SMALL LETTER KA..LIMBU SMALL LETTER NGA - {0x1932, 0x1932, prExtend}, // Mn LIMBU SMALL LETTER ANUSVARA - {0x1933, 0x1938, prSpacingMark}, // Mc [6] LIMBU SMALL LETTER TA..LIMBU SMALL LETTER LA - {0x1939, 0x193B, prExtend}, // Mn [3] LIMBU SIGN MUKPHRENG..LIMBU SIGN SA-I - {0x1A17, 0x1A18, prExtend}, // Mn [2] BUGINESE VOWEL SIGN I..BUGINESE VOWEL SIGN U - {0x1A19, 0x1A1A, prSpacingMark}, // Mc [2] BUGINESE VOWEL SIGN E..BUGINESE VOWEL SIGN O - {0x1A1B, 0x1A1B, prExtend}, // Mn BUGINESE VOWEL SIGN AE - {0x1A55, 0x1A55, prSpacingMark}, // Mc TAI THAM CONSONANT SIGN MEDIAL RA - {0x1A56, 0x1A56, prExtend}, // Mn TAI THAM CONSONANT SIGN MEDIAL LA - {0x1A57, 0x1A57, prSpacingMark}, // Mc TAI THAM CONSONANT SIGN LA TANG LAI - {0x1A58, 0x1A5E, prExtend}, // Mn [7] TAI THAM SIGN MAI KANG LAI..TAI THAM CONSONANT SIGN SA - {0x1A60, 0x1A60, prExtend}, // Mn TAI THAM SIGN SAKOT - {0x1A62, 0x1A62, prExtend}, // Mn TAI THAM VOWEL SIGN MAI SAT - {0x1A65, 0x1A6C, prExtend}, // Mn [8] TAI THAM VOWEL SIGN I..TAI THAM VOWEL SIGN OA BELOW - {0x1A6D, 0x1A72, prSpacingMark}, // Mc [6] TAI THAM VOWEL SIGN OY..TAI THAM VOWEL SIGN THAM AI - {0x1A73, 0x1A7C, prExtend}, // Mn [10] TAI THAM VOWEL SIGN OA ABOVE..TAI THAM SIGN KHUEN-LUE KARAN - {0x1A7F, 0x1A7F, prExtend}, // Mn TAI THAM COMBINING CRYPTOGRAMMIC DOT - {0x1AB0, 0x1ABD, prExtend}, // Mn [14] COMBINING DOUBLED CIRCUMFLEX ACCENT..COMBINING PARENTHESES BELOW - {0x1ABE, 0x1ABE, prExtend}, // Me COMBINING PARENTHESES OVERLAY - {0x1B00, 0x1B03, prExtend}, // Mn [4] BALINESE SIGN ULU RICEM..BALINESE SIGN SURANG - {0x1B04, 0x1B04, prSpacingMark}, // Mc BALINESE SIGN BISAH - {0x1B34, 0x1B34, prExtend}, // Mn BALINESE SIGN REREKAN - {0x1B35, 0x1B35, prExtend}, // Mc BALINESE VOWEL SIGN TEDUNG - {0x1B36, 0x1B3A, prExtend}, // Mn [5] BALINESE VOWEL SIGN ULU..BALINESE VOWEL SIGN RA REPA - {0x1B3B, 0x1B3B, prSpacingMark}, // Mc BALINESE VOWEL SIGN RA REPA TEDUNG - {0x1B3C, 0x1B3C, prExtend}, // Mn BALINESE VOWEL SIGN LA LENGA - {0x1B3D, 0x1B41, prSpacingMark}, // Mc [5] BALINESE VOWEL SIGN LA LENGA TEDUNG..BALINESE VOWEL SIGN TALING REPA TEDUNG - {0x1B42, 0x1B42, prExtend}, // Mn BALINESE VOWEL SIGN PEPET - {0x1B43, 0x1B44, prSpacingMark}, // Mc [2] BALINESE VOWEL SIGN PEPET TEDUNG..BALINESE ADEG ADEG - {0x1B6B, 0x1B73, prExtend}, // Mn [9] BALINESE MUSICAL SYMBOL COMBINING TEGEH..BALINESE MUSICAL SYMBOL COMBINING GONG - {0x1B80, 0x1B81, prExtend}, // Mn [2] SUNDANESE SIGN PANYECEK..SUNDANESE SIGN PANGLAYAR - {0x1B82, 0x1B82, prSpacingMark}, // Mc SUNDANESE SIGN PANGWISAD - {0x1BA1, 0x1BA1, prSpacingMark}, // Mc SUNDANESE CONSONANT SIGN PAMINGKAL - {0x1BA2, 0x1BA5, prExtend}, // Mn [4] SUNDANESE CONSONANT SIGN PANYAKRA..SUNDANESE VOWEL SIGN PANYUKU - {0x1BA6, 0x1BA7, prSpacingMark}, // Mc [2] SUNDANESE VOWEL SIGN PANAELAENG..SUNDANESE VOWEL SIGN PANOLONG - {0x1BA8, 0x1BA9, prExtend}, // Mn [2] SUNDANESE VOWEL SIGN PAMEPET..SUNDANESE VOWEL SIGN PANEULEUNG - {0x1BAA, 0x1BAA, prSpacingMark}, // Mc SUNDANESE SIGN PAMAAEH - {0x1BAB, 0x1BAD, prExtend}, // Mn [3] SUNDANESE SIGN VIRAMA..SUNDANESE CONSONANT SIGN PASANGAN WA - {0x1BE6, 0x1BE6, prExtend}, // Mn BATAK SIGN TOMPI - {0x1BE7, 0x1BE7, prSpacingMark}, // Mc BATAK VOWEL SIGN E - {0x1BE8, 0x1BE9, prExtend}, // Mn [2] BATAK VOWEL SIGN PAKPAK E..BATAK VOWEL SIGN EE - {0x1BEA, 0x1BEC, prSpacingMark}, // Mc [3] BATAK VOWEL SIGN I..BATAK VOWEL SIGN O - {0x1BED, 0x1BED, prExtend}, // Mn BATAK VOWEL SIGN KARO O - {0x1BEE, 0x1BEE, prSpacingMark}, // Mc BATAK VOWEL SIGN U - {0x1BEF, 0x1BF1, prExtend}, // Mn [3] BATAK VOWEL SIGN U FOR SIMALUNGUN SA..BATAK CONSONANT SIGN H - {0x1BF2, 0x1BF3, prSpacingMark}, // Mc [2] BATAK PANGOLAT..BATAK PANONGONAN - {0x1C24, 0x1C2B, prSpacingMark}, // Mc [8] LEPCHA SUBJOINED LETTER YA..LEPCHA VOWEL SIGN UU - {0x1C2C, 0x1C33, prExtend}, // Mn [8] LEPCHA VOWEL SIGN E..LEPCHA CONSONANT SIGN T - {0x1C34, 0x1C35, prSpacingMark}, // Mc [2] LEPCHA CONSONANT SIGN NYIN-DO..LEPCHA CONSONANT SIGN KANG - {0x1C36, 0x1C37, prExtend}, // Mn [2] LEPCHA SIGN RAN..LEPCHA SIGN NUKTA - {0x1CD0, 0x1CD2, prExtend}, // Mn [3] VEDIC TONE KARSHANA..VEDIC TONE PRENKHA - {0x1CD4, 0x1CE0, prExtend}, // Mn [13] VEDIC SIGN YAJURVEDIC MIDLINE SVARITA..VEDIC TONE RIGVEDIC KASHMIRI INDEPENDENT SVARITA - {0x1CE1, 0x1CE1, prSpacingMark}, // Mc VEDIC TONE ATHARVAVEDIC INDEPENDENT SVARITA - {0x1CE2, 0x1CE8, prExtend}, // Mn [7] VEDIC SIGN VISARGA SVARITA..VEDIC SIGN VISARGA ANUDATTA WITH TAIL - {0x1CED, 0x1CED, prExtend}, // Mn VEDIC SIGN TIRYAK - {0x1CF4, 0x1CF4, prExtend}, // Mn VEDIC TONE CANDRA ABOVE - {0x1CF7, 0x1CF7, prSpacingMark}, // Mc VEDIC SIGN ATIKRAMA - {0x1CF8, 0x1CF9, prExtend}, // Mn [2] VEDIC TONE RING ABOVE..VEDIC TONE DOUBLE RING ABOVE - {0x1DC0, 0x1DF9, prExtend}, // Mn [58] COMBINING DOTTED GRAVE ACCENT..COMBINING WIDE INVERTED BRIDGE BELOW - {0x1DFB, 0x1DFF, prExtend}, // Mn [5] COMBINING DELETION MARK..COMBINING RIGHT ARROWHEAD AND DOWN ARROWHEAD BELOW - {0x200B, 0x200B, prControl}, // Cf ZERO WIDTH SPACE - {0x200C, 0x200C, prExtend}, // Cf ZERO WIDTH NON-JOINER - {0x200D, 0x200D, prZWJ}, // Cf ZERO WIDTH JOINER - {0x200E, 0x200F, prControl}, // Cf [2] LEFT-TO-RIGHT MARK..RIGHT-TO-LEFT MARK - {0x2028, 0x2028, prControl}, // Zl LINE SEPARATOR - {0x2029, 0x2029, prControl}, // Zp PARAGRAPH SEPARATOR - {0x202A, 0x202E, prControl}, // Cf [5] LEFT-TO-RIGHT EMBEDDING..RIGHT-TO-LEFT OVERRIDE - {0x203C, 0x203C, prExtendedPictographic}, // 1.1 [1] (‼️) double exclamation mark - {0x2049, 0x2049, prExtendedPictographic}, // 3.0 [1] (⁉️) exclamation question mark - {0x2060, 0x2064, prControl}, // Cf [5] WORD JOINER..INVISIBLE PLUS - {0x2065, 0x2065, prControl}, // Cn - {0x2066, 0x206F, prControl}, // Cf [10] LEFT-TO-RIGHT ISOLATE..NOMINAL DIGIT SHAPES - {0x20D0, 0x20DC, prExtend}, // Mn [13] COMBINING LEFT HARPOON ABOVE..COMBINING FOUR DOTS ABOVE - {0x20DD, 0x20E0, prExtend}, // Me [4] COMBINING ENCLOSING CIRCLE..COMBINING ENCLOSING CIRCLE BACKSLASH - {0x20E1, 0x20E1, prExtend}, // Mn COMBINING LEFT RIGHT ARROW ABOVE - {0x20E2, 0x20E4, prExtend}, // Me [3] COMBINING ENCLOSING SCREEN..COMBINING ENCLOSING UPWARD POINTING TRIANGLE - {0x20E5, 0x20F0, prExtend}, // Mn [12] COMBINING REVERSE SOLIDUS OVERLAY..COMBINING ASTERISK ABOVE - {0x2122, 0x2122, prExtendedPictographic}, // 1.1 [1] (™️) trade mark - {0x2139, 0x2139, prExtendedPictographic}, // 3.0 [1] (ℹ️) information - {0x2194, 0x2199, prExtendedPictographic}, // 1.1 [6] (↔️..↙️) left-right arrow..down-left arrow - {0x21A9, 0x21AA, prExtendedPictographic}, // 1.1 [2] (↩️..↪️) right arrow curving left..left arrow curving right - {0x231A, 0x231B, prExtendedPictographic}, // 1.1 [2] (⌚..⌛) watch..hourglass done - {0x2328, 0x2328, prExtendedPictographic}, // 1.1 [1] (⌨️) keyboard - {0x2388, 0x2388, prExtendedPictographic}, // 3.0 [1] (⎈) HELM SYMBOL - {0x23CF, 0x23CF, prExtendedPictographic}, // 4.0 [1] (⏏️) eject button - {0x23E9, 0x23F3, prExtendedPictographic}, // 6.0 [11] (⏩..⏳) fast-forward button..hourglass not done - {0x23F8, 0x23FA, prExtendedPictographic}, // 7.0 [3] (⏸️..⏺️) pause button..record button - {0x24C2, 0x24C2, prExtendedPictographic}, // 1.1 [1] (Ⓜ️) circled M - {0x25AA, 0x25AB, prExtendedPictographic}, // 1.1 [2] (▪️..▫️) black small square..white small square - {0x25B6, 0x25B6, prExtendedPictographic}, // 1.1 [1] (▶️) play button - {0x25C0, 0x25C0, prExtendedPictographic}, // 1.1 [1] (◀️) reverse button - {0x25FB, 0x25FE, prExtendedPictographic}, // 3.2 [4] (◻️..◾) white medium square..black medium-small square - {0x2600, 0x2605, prExtendedPictographic}, // 1.1 [6] (☀️..★) sun..BLACK STAR - {0x2607, 0x2612, prExtendedPictographic}, // 1.1 [12] (☇..☒) LIGHTNING..BALLOT BOX WITH X - {0x2614, 0x2615, prExtendedPictographic}, // 4.0 [2] (☔..☕) umbrella with rain drops..hot beverage - {0x2616, 0x2617, prExtendedPictographic}, // 3.2 [2] (☖..☗) WHITE SHOGI PIECE..BLACK SHOGI PIECE - {0x2618, 0x2618, prExtendedPictographic}, // 4.1 [1] (☘️) shamrock - {0x2619, 0x2619, prExtendedPictographic}, // 3.0 [1] (☙) REVERSED ROTATED FLORAL HEART BULLET - {0x261A, 0x266F, prExtendedPictographic}, // 1.1 [86] (☚..♯) BLACK LEFT POINTING INDEX..MUSIC SHARP SIGN - {0x2670, 0x2671, prExtendedPictographic}, // 3.0 [2] (♰..♱) WEST SYRIAC CROSS..EAST SYRIAC CROSS - {0x2672, 0x267D, prExtendedPictographic}, // 3.2 [12] (♲..♽) UNIVERSAL RECYCLING SYMBOL..PARTIALLY-RECYCLED PAPER SYMBOL - {0x267E, 0x267F, prExtendedPictographic}, // 4.1 [2] (♾️..♿) infinity..wheelchair symbol - {0x2680, 0x2685, prExtendedPictographic}, // 3.2 [6] (⚀..⚅) DIE FACE-1..DIE FACE-6 - {0x2690, 0x2691, prExtendedPictographic}, // 4.0 [2] (⚐..⚑) WHITE FLAG..BLACK FLAG - {0x2692, 0x269C, prExtendedPictographic}, // 4.1 [11] (⚒️..⚜️) hammer and pick..fleur-de-lis - {0x269D, 0x269D, prExtendedPictographic}, // 5.1 [1] (⚝) OUTLINED WHITE STAR - {0x269E, 0x269F, prExtendedPictographic}, // 5.2 [2] (⚞..⚟) THREE LINES CONVERGING RIGHT..THREE LINES CONVERGING LEFT - {0x26A0, 0x26A1, prExtendedPictographic}, // 4.0 [2] (⚠️..⚡) warning..high voltage - {0x26A2, 0x26B1, prExtendedPictographic}, // 4.1 [16] (⚢..⚱️) DOUBLED FEMALE SIGN..funeral urn - {0x26B2, 0x26B2, prExtendedPictographic}, // 5.0 [1] (⚲) NEUTER - {0x26B3, 0x26BC, prExtendedPictographic}, // 5.1 [10] (⚳..⚼) CERES..SESQUIQUADRATE - {0x26BD, 0x26BF, prExtendedPictographic}, // 5.2 [3] (⚽..⚿) soccer ball..SQUARED KEY - {0x26C0, 0x26C3, prExtendedPictographic}, // 5.1 [4] (⛀..⛃) WHITE DRAUGHTS MAN..BLACK DRAUGHTS KING - {0x26C4, 0x26CD, prExtendedPictographic}, // 5.2 [10] (⛄..⛍) snowman without snow..DISABLED CAR - {0x26CE, 0x26CE, prExtendedPictographic}, // 6.0 [1] (⛎) Ophiuchus - {0x26CF, 0x26E1, prExtendedPictographic}, // 5.2 [19] (⛏️..⛡) pick..RESTRICTED LEFT ENTRY-2 - {0x26E2, 0x26E2, prExtendedPictographic}, // 6.0 [1] (⛢) ASTRONOMICAL SYMBOL FOR URANUS - {0x26E3, 0x26E3, prExtendedPictographic}, // 5.2 [1] (⛣) HEAVY CIRCLE WITH STROKE AND TWO DOTS ABOVE - {0x26E4, 0x26E7, prExtendedPictographic}, // 6.0 [4] (⛤..⛧) PENTAGRAM..INVERTED PENTAGRAM - {0x26E8, 0x26FF, prExtendedPictographic}, // 5.2 [24] (⛨..⛿) BLACK CROSS ON SHIELD..WHITE FLAG WITH HORIZONTAL MIDDLE BLACK STRIPE - {0x2700, 0x2700, prExtendedPictographic}, // 7.0 [1] (✀) BLACK SAFETY SCISSORS - {0x2701, 0x2704, prExtendedPictographic}, // 1.1 [4] (✁..✄) UPPER BLADE SCISSORS..WHITE SCISSORS - {0x2705, 0x2705, prExtendedPictographic}, // 6.0 [1] (✅) check mark button - {0x2708, 0x2709, prExtendedPictographic}, // 1.1 [2] (✈️..✉️) airplane..envelope - {0x270A, 0x270B, prExtendedPictographic}, // 6.0 [2] (✊..✋) raised fist..raised hand - {0x270C, 0x2712, prExtendedPictographic}, // 1.1 [7] (✌️..✒️) victory hand..black nib - {0x2714, 0x2714, prExtendedPictographic}, // 1.1 [1] (✔️) check mark - {0x2716, 0x2716, prExtendedPictographic}, // 1.1 [1] (✖️) multiplication sign - {0x271D, 0x271D, prExtendedPictographic}, // 1.1 [1] (✝️) latin cross - {0x2721, 0x2721, prExtendedPictographic}, // 1.1 [1] (✡️) star of David - {0x2728, 0x2728, prExtendedPictographic}, // 6.0 [1] (✨) sparkles - {0x2733, 0x2734, prExtendedPictographic}, // 1.1 [2] (✳️..✴️) eight-spoked asterisk..eight-pointed star - {0x2744, 0x2744, prExtendedPictographic}, // 1.1 [1] (❄️) snowflake - {0x2747, 0x2747, prExtendedPictographic}, // 1.1 [1] (❇️) sparkle - {0x274C, 0x274C, prExtendedPictographic}, // 6.0 [1] (❌) cross mark - {0x274E, 0x274E, prExtendedPictographic}, // 6.0 [1] (❎) cross mark button - {0x2753, 0x2755, prExtendedPictographic}, // 6.0 [3] (❓..❕) question mark..white exclamation mark - {0x2757, 0x2757, prExtendedPictographic}, // 5.2 [1] (❗) exclamation mark - {0x2763, 0x2767, prExtendedPictographic}, // 1.1 [5] (❣️..❧) heart exclamation..ROTATED FLORAL HEART BULLET - {0x2795, 0x2797, prExtendedPictographic}, // 6.0 [3] (➕..➗) plus sign..division sign - {0x27A1, 0x27A1, prExtendedPictographic}, // 1.1 [1] (➡️) right arrow - {0x27B0, 0x27B0, prExtendedPictographic}, // 6.0 [1] (➰) curly loop - {0x27BF, 0x27BF, prExtendedPictographic}, // 6.0 [1] (➿) double curly loop - {0x2934, 0x2935, prExtendedPictographic}, // 3.2 [2] (⤴️..⤵️) right arrow curving up..right arrow curving down - {0x2B05, 0x2B07, prExtendedPictographic}, // 4.0 [3] (⬅️..⬇️) left arrow..down arrow - {0x2B1B, 0x2B1C, prExtendedPictographic}, // 5.1 [2] (⬛..⬜) black large square..white large square - {0x2B50, 0x2B50, prExtendedPictographic}, // 5.1 [1] (⭐) star - {0x2B55, 0x2B55, prExtendedPictographic}, // 5.2 [1] (⭕) hollow red circle - {0x2CEF, 0x2CF1, prExtend}, // Mn [3] COPTIC COMBINING NI ABOVE..COPTIC COMBINING SPIRITUS LENIS - {0x2D7F, 0x2D7F, prExtend}, // Mn TIFINAGH CONSONANT JOINER - {0x2DE0, 0x2DFF, prExtend}, // Mn [32] COMBINING CYRILLIC LETTER BE..COMBINING CYRILLIC LETTER IOTIFIED BIG YUS - {0x302A, 0x302D, prExtend}, // Mn [4] IDEOGRAPHIC LEVEL TONE MARK..IDEOGRAPHIC ENTERING TONE MARK - {0x302E, 0x302F, prExtend}, // Mc [2] HANGUL SINGLE DOT TONE MARK..HANGUL DOUBLE DOT TONE MARK - {0x3030, 0x3030, prExtendedPictographic}, // 1.1 [1] (〰️) wavy dash - {0x303D, 0x303D, prExtendedPictographic}, // 3.2 [1] (〽️) part alternation mark - {0x3099, 0x309A, prExtend}, // Mn [2] COMBINING KATAKANA-HIRAGANA VOICED SOUND MARK..COMBINING KATAKANA-HIRAGANA SEMI-VOICED SOUND MARK - {0x3297, 0x3297, prExtendedPictographic}, // 1.1 [1] (㊗️) Japanese “congratulations” button - {0x3299, 0x3299, prExtendedPictographic}, // 1.1 [1] (㊙️) Japanese “secret” button - {0xA66F, 0xA66F, prExtend}, // Mn COMBINING CYRILLIC VZMET - {0xA670, 0xA672, prExtend}, // Me [3] COMBINING CYRILLIC TEN MILLIONS SIGN..COMBINING CYRILLIC THOUSAND MILLIONS SIGN - {0xA674, 0xA67D, prExtend}, // Mn [10] COMBINING CYRILLIC LETTER UKRAINIAN IE..COMBINING CYRILLIC PAYEROK - {0xA69E, 0xA69F, prExtend}, // Mn [2] COMBINING CYRILLIC LETTER EF..COMBINING CYRILLIC LETTER IOTIFIED E - {0xA6F0, 0xA6F1, prExtend}, // Mn [2] BAMUM COMBINING MARK KOQNDON..BAMUM COMBINING MARK TUKWENTIS - {0xA802, 0xA802, prExtend}, // Mn SYLOTI NAGRI SIGN DVISVARA - {0xA806, 0xA806, prExtend}, // Mn SYLOTI NAGRI SIGN HASANTA - {0xA80B, 0xA80B, prExtend}, // Mn SYLOTI NAGRI SIGN ANUSVARA - {0xA823, 0xA824, prSpacingMark}, // Mc [2] SYLOTI NAGRI VOWEL SIGN A..SYLOTI NAGRI VOWEL SIGN I - {0xA825, 0xA826, prExtend}, // Mn [2] SYLOTI NAGRI VOWEL SIGN U..SYLOTI NAGRI VOWEL SIGN E - {0xA827, 0xA827, prSpacingMark}, // Mc SYLOTI NAGRI VOWEL SIGN OO - {0xA880, 0xA881, prSpacingMark}, // Mc [2] SAURASHTRA SIGN ANUSVARA..SAURASHTRA SIGN VISARGA - {0xA8B4, 0xA8C3, prSpacingMark}, // Mc [16] SAURASHTRA CONSONANT SIGN HAARU..SAURASHTRA VOWEL SIGN AU - {0xA8C4, 0xA8C5, prExtend}, // Mn [2] SAURASHTRA SIGN VIRAMA..SAURASHTRA SIGN CANDRABINDU - {0xA8E0, 0xA8F1, prExtend}, // Mn [18] COMBINING DEVANAGARI DIGIT ZERO..COMBINING DEVANAGARI SIGN AVAGRAHA - {0xA8FF, 0xA8FF, prExtend}, // Mn DEVANAGARI VOWEL SIGN AY - {0xA926, 0xA92D, prExtend}, // Mn [8] KAYAH LI VOWEL UE..KAYAH LI TONE CALYA PLOPHU - {0xA947, 0xA951, prExtend}, // Mn [11] REJANG VOWEL SIGN I..REJANG CONSONANT SIGN R - {0xA952, 0xA953, prSpacingMark}, // Mc [2] REJANG CONSONANT SIGN H..REJANG VIRAMA - {0xA960, 0xA97C, prL}, // Lo [29] HANGUL CHOSEONG TIKEUT-MIEUM..HANGUL CHOSEONG SSANGYEORINHIEUH - {0xA980, 0xA982, prExtend}, // Mn [3] JAVANESE SIGN PANYANGGA..JAVANESE SIGN LAYAR - {0xA983, 0xA983, prSpacingMark}, // Mc JAVANESE SIGN WIGNYAN - {0xA9B3, 0xA9B3, prExtend}, // Mn JAVANESE SIGN CECAK TELU - {0xA9B4, 0xA9B5, prSpacingMark}, // Mc [2] JAVANESE VOWEL SIGN TARUNG..JAVANESE VOWEL SIGN TOLONG - {0xA9B6, 0xA9B9, prExtend}, // Mn [4] JAVANESE VOWEL SIGN WULU..JAVANESE VOWEL SIGN SUKU MENDUT - {0xA9BA, 0xA9BB, prSpacingMark}, // Mc [2] JAVANESE VOWEL SIGN TALING..JAVANESE VOWEL SIGN DIRGA MURE - {0xA9BC, 0xA9BD, prExtend}, // Mn [2] JAVANESE VOWEL SIGN PEPET..JAVANESE CONSONANT SIGN KERET - {0xA9BE, 0xA9C0, prSpacingMark}, // Mc [3] JAVANESE CONSONANT SIGN PENGKAL..JAVANESE PANGKON - {0xA9E5, 0xA9E5, prExtend}, // Mn MYANMAR SIGN SHAN SAW - {0xAA29, 0xAA2E, prExtend}, // Mn [6] CHAM VOWEL SIGN AA..CHAM VOWEL SIGN OE - {0xAA2F, 0xAA30, prSpacingMark}, // Mc [2] CHAM VOWEL SIGN O..CHAM VOWEL SIGN AI - {0xAA31, 0xAA32, prExtend}, // Mn [2] CHAM VOWEL SIGN AU..CHAM VOWEL SIGN UE - {0xAA33, 0xAA34, prSpacingMark}, // Mc [2] CHAM CONSONANT SIGN YA..CHAM CONSONANT SIGN RA - {0xAA35, 0xAA36, prExtend}, // Mn [2] CHAM CONSONANT SIGN LA..CHAM CONSONANT SIGN WA - {0xAA43, 0xAA43, prExtend}, // Mn CHAM CONSONANT SIGN FINAL NG - {0xAA4C, 0xAA4C, prExtend}, // Mn CHAM CONSONANT SIGN FINAL M - {0xAA4D, 0xAA4D, prSpacingMark}, // Mc CHAM CONSONANT SIGN FINAL H - {0xAA7C, 0xAA7C, prExtend}, // Mn MYANMAR SIGN TAI LAING TONE-2 - {0xAAB0, 0xAAB0, prExtend}, // Mn TAI VIET MAI KANG - {0xAAB2, 0xAAB4, prExtend}, // Mn [3] TAI VIET VOWEL I..TAI VIET VOWEL U - {0xAAB7, 0xAAB8, prExtend}, // Mn [2] TAI VIET MAI KHIT..TAI VIET VOWEL IA - {0xAABE, 0xAABF, prExtend}, // Mn [2] TAI VIET VOWEL AM..TAI VIET TONE MAI EK - {0xAAC1, 0xAAC1, prExtend}, // Mn TAI VIET TONE MAI THO - {0xAAEB, 0xAAEB, prSpacingMark}, // Mc MEETEI MAYEK VOWEL SIGN II - {0xAAEC, 0xAAED, prExtend}, // Mn [2] MEETEI MAYEK VOWEL SIGN UU..MEETEI MAYEK VOWEL SIGN AAI - {0xAAEE, 0xAAEF, prSpacingMark}, // Mc [2] MEETEI MAYEK VOWEL SIGN AU..MEETEI MAYEK VOWEL SIGN AAU - {0xAAF5, 0xAAF5, prSpacingMark}, // Mc MEETEI MAYEK VOWEL SIGN VISARGA - {0xAAF6, 0xAAF6, prExtend}, // Mn MEETEI MAYEK VIRAMA - {0xABE3, 0xABE4, prSpacingMark}, // Mc [2] MEETEI MAYEK VOWEL SIGN ONAP..MEETEI MAYEK VOWEL SIGN INAP - {0xABE5, 0xABE5, prExtend}, // Mn MEETEI MAYEK VOWEL SIGN ANAP - {0xABE6, 0xABE7, prSpacingMark}, // Mc [2] MEETEI MAYEK VOWEL SIGN YENAP..MEETEI MAYEK VOWEL SIGN SOUNAP - {0xABE8, 0xABE8, prExtend}, // Mn MEETEI MAYEK VOWEL SIGN UNAP - {0xABE9, 0xABEA, prSpacingMark}, // Mc [2] MEETEI MAYEK VOWEL SIGN CHEINAP..MEETEI MAYEK VOWEL SIGN NUNG - {0xABEC, 0xABEC, prSpacingMark}, // Mc MEETEI MAYEK LUM IYEK - {0xABED, 0xABED, prExtend}, // Mn MEETEI MAYEK APUN IYEK - {0xAC00, 0xAC00, prLV}, // Lo HANGUL SYLLABLE GA - {0xAC01, 0xAC1B, prLVT}, // Lo [27] HANGUL SYLLABLE GAG..HANGUL SYLLABLE GAH - {0xAC1C, 0xAC1C, prLV}, // Lo HANGUL SYLLABLE GAE - {0xAC1D, 0xAC37, prLVT}, // Lo [27] HANGUL SYLLABLE GAEG..HANGUL SYLLABLE GAEH - {0xAC38, 0xAC38, prLV}, // Lo HANGUL SYLLABLE GYA - {0xAC39, 0xAC53, prLVT}, // Lo [27] HANGUL SYLLABLE GYAG..HANGUL SYLLABLE GYAH - {0xAC54, 0xAC54, prLV}, // Lo HANGUL SYLLABLE GYAE - {0xAC55, 0xAC6F, prLVT}, // Lo [27] HANGUL SYLLABLE GYAEG..HANGUL SYLLABLE GYAEH - {0xAC70, 0xAC70, prLV}, // Lo HANGUL SYLLABLE GEO - {0xAC71, 0xAC8B, prLVT}, // Lo [27] HANGUL SYLLABLE GEOG..HANGUL SYLLABLE GEOH - {0xAC8C, 0xAC8C, prLV}, // Lo HANGUL SYLLABLE GE - {0xAC8D, 0xACA7, prLVT}, // Lo [27] HANGUL SYLLABLE GEG..HANGUL SYLLABLE GEH - {0xACA8, 0xACA8, prLV}, // Lo HANGUL SYLLABLE GYEO - {0xACA9, 0xACC3, prLVT}, // Lo [27] HANGUL SYLLABLE GYEOG..HANGUL SYLLABLE GYEOH - {0xACC4, 0xACC4, prLV}, // Lo HANGUL SYLLABLE GYE - {0xACC5, 0xACDF, prLVT}, // Lo [27] HANGUL SYLLABLE GYEG..HANGUL SYLLABLE GYEH - {0xACE0, 0xACE0, prLV}, // Lo HANGUL SYLLABLE GO - {0xACE1, 0xACFB, prLVT}, // Lo [27] HANGUL SYLLABLE GOG..HANGUL SYLLABLE GOH - {0xACFC, 0xACFC, prLV}, // Lo HANGUL SYLLABLE GWA - {0xACFD, 0xAD17, prLVT}, // Lo [27] HANGUL SYLLABLE GWAG..HANGUL SYLLABLE GWAH - {0xAD18, 0xAD18, prLV}, // Lo HANGUL SYLLABLE GWAE - {0xAD19, 0xAD33, prLVT}, // Lo [27] HANGUL SYLLABLE GWAEG..HANGUL SYLLABLE GWAEH - {0xAD34, 0xAD34, prLV}, // Lo HANGUL SYLLABLE GOE - {0xAD35, 0xAD4F, prLVT}, // Lo [27] HANGUL SYLLABLE GOEG..HANGUL SYLLABLE GOEH - {0xAD50, 0xAD50, prLV}, // Lo HANGUL SYLLABLE GYO - {0xAD51, 0xAD6B, prLVT}, // Lo [27] HANGUL SYLLABLE GYOG..HANGUL SYLLABLE GYOH - {0xAD6C, 0xAD6C, prLV}, // Lo HANGUL SYLLABLE GU - {0xAD6D, 0xAD87, prLVT}, // Lo [27] HANGUL SYLLABLE GUG..HANGUL SYLLABLE GUH - {0xAD88, 0xAD88, prLV}, // Lo HANGUL SYLLABLE GWEO - {0xAD89, 0xADA3, prLVT}, // Lo [27] HANGUL SYLLABLE GWEOG..HANGUL SYLLABLE GWEOH - {0xADA4, 0xADA4, prLV}, // Lo HANGUL SYLLABLE GWE - {0xADA5, 0xADBF, prLVT}, // Lo [27] HANGUL SYLLABLE GWEG..HANGUL SYLLABLE GWEH - {0xADC0, 0xADC0, prLV}, // Lo HANGUL SYLLABLE GWI - {0xADC1, 0xADDB, prLVT}, // Lo [27] HANGUL SYLLABLE GWIG..HANGUL SYLLABLE GWIH - {0xADDC, 0xADDC, prLV}, // Lo HANGUL SYLLABLE GYU - {0xADDD, 0xADF7, prLVT}, // Lo [27] HANGUL SYLLABLE GYUG..HANGUL SYLLABLE GYUH - {0xADF8, 0xADF8, prLV}, // Lo HANGUL SYLLABLE GEU - {0xADF9, 0xAE13, prLVT}, // Lo [27] HANGUL SYLLABLE GEUG..HANGUL SYLLABLE GEUH - {0xAE14, 0xAE14, prLV}, // Lo HANGUL SYLLABLE GYI - {0xAE15, 0xAE2F, prLVT}, // Lo [27] HANGUL SYLLABLE GYIG..HANGUL SYLLABLE GYIH - {0xAE30, 0xAE30, prLV}, // Lo HANGUL SYLLABLE GI - {0xAE31, 0xAE4B, prLVT}, // Lo [27] HANGUL SYLLABLE GIG..HANGUL SYLLABLE GIH - {0xAE4C, 0xAE4C, prLV}, // Lo HANGUL SYLLABLE GGA - {0xAE4D, 0xAE67, prLVT}, // Lo [27] HANGUL SYLLABLE GGAG..HANGUL SYLLABLE GGAH - {0xAE68, 0xAE68, prLV}, // Lo HANGUL SYLLABLE GGAE - {0xAE69, 0xAE83, prLVT}, // Lo [27] HANGUL SYLLABLE GGAEG..HANGUL SYLLABLE GGAEH - {0xAE84, 0xAE84, prLV}, // Lo HANGUL SYLLABLE GGYA - {0xAE85, 0xAE9F, prLVT}, // Lo [27] HANGUL SYLLABLE GGYAG..HANGUL SYLLABLE GGYAH - {0xAEA0, 0xAEA0, prLV}, // Lo HANGUL SYLLABLE GGYAE - {0xAEA1, 0xAEBB, prLVT}, // Lo [27] HANGUL SYLLABLE GGYAEG..HANGUL SYLLABLE GGYAEH - {0xAEBC, 0xAEBC, prLV}, // Lo HANGUL SYLLABLE GGEO - {0xAEBD, 0xAED7, prLVT}, // Lo [27] HANGUL SYLLABLE GGEOG..HANGUL SYLLABLE GGEOH - {0xAED8, 0xAED8, prLV}, // Lo HANGUL SYLLABLE GGE - {0xAED9, 0xAEF3, prLVT}, // Lo [27] HANGUL SYLLABLE GGEG..HANGUL SYLLABLE GGEH - {0xAEF4, 0xAEF4, prLV}, // Lo HANGUL SYLLABLE GGYEO - {0xAEF5, 0xAF0F, prLVT}, // Lo [27] HANGUL SYLLABLE GGYEOG..HANGUL SYLLABLE GGYEOH - {0xAF10, 0xAF10, prLV}, // Lo HANGUL SYLLABLE GGYE - {0xAF11, 0xAF2B, prLVT}, // Lo [27] HANGUL SYLLABLE GGYEG..HANGUL SYLLABLE GGYEH - {0xAF2C, 0xAF2C, prLV}, // Lo HANGUL SYLLABLE GGO - {0xAF2D, 0xAF47, prLVT}, // Lo [27] HANGUL SYLLABLE GGOG..HANGUL SYLLABLE GGOH - {0xAF48, 0xAF48, prLV}, // Lo HANGUL SYLLABLE GGWA - {0xAF49, 0xAF63, prLVT}, // Lo [27] HANGUL SYLLABLE GGWAG..HANGUL SYLLABLE GGWAH - {0xAF64, 0xAF64, prLV}, // Lo HANGUL SYLLABLE GGWAE - {0xAF65, 0xAF7F, prLVT}, // Lo [27] HANGUL SYLLABLE GGWAEG..HANGUL SYLLABLE GGWAEH - {0xAF80, 0xAF80, prLV}, // Lo HANGUL SYLLABLE GGOE - {0xAF81, 0xAF9B, prLVT}, // Lo [27] HANGUL SYLLABLE GGOEG..HANGUL SYLLABLE GGOEH - {0xAF9C, 0xAF9C, prLV}, // Lo HANGUL SYLLABLE GGYO - {0xAF9D, 0xAFB7, prLVT}, // Lo [27] HANGUL SYLLABLE GGYOG..HANGUL SYLLABLE GGYOH - {0xAFB8, 0xAFB8, prLV}, // Lo HANGUL SYLLABLE GGU - {0xAFB9, 0xAFD3, prLVT}, // Lo [27] HANGUL SYLLABLE GGUG..HANGUL SYLLABLE GGUH - {0xAFD4, 0xAFD4, prLV}, // Lo HANGUL SYLLABLE GGWEO - {0xAFD5, 0xAFEF, prLVT}, // Lo [27] HANGUL SYLLABLE GGWEOG..HANGUL SYLLABLE GGWEOH - {0xAFF0, 0xAFF0, prLV}, // Lo HANGUL SYLLABLE GGWE - {0xAFF1, 0xB00B, prLVT}, // Lo [27] HANGUL SYLLABLE GGWEG..HANGUL SYLLABLE GGWEH - {0xB00C, 0xB00C, prLV}, // Lo HANGUL SYLLABLE GGWI - {0xB00D, 0xB027, prLVT}, // Lo [27] HANGUL SYLLABLE GGWIG..HANGUL SYLLABLE GGWIH - {0xB028, 0xB028, prLV}, // Lo HANGUL SYLLABLE GGYU - {0xB029, 0xB043, prLVT}, // Lo [27] HANGUL SYLLABLE GGYUG..HANGUL SYLLABLE GGYUH - {0xB044, 0xB044, prLV}, // Lo HANGUL SYLLABLE GGEU - {0xB045, 0xB05F, prLVT}, // Lo [27] HANGUL SYLLABLE GGEUG..HANGUL SYLLABLE GGEUH - {0xB060, 0xB060, prLV}, // Lo HANGUL SYLLABLE GGYI - {0xB061, 0xB07B, prLVT}, // Lo [27] HANGUL SYLLABLE GGYIG..HANGUL SYLLABLE GGYIH - {0xB07C, 0xB07C, prLV}, // Lo HANGUL SYLLABLE GGI - {0xB07D, 0xB097, prLVT}, // Lo [27] HANGUL SYLLABLE GGIG..HANGUL SYLLABLE GGIH - {0xB098, 0xB098, prLV}, // Lo HANGUL SYLLABLE NA - {0xB099, 0xB0B3, prLVT}, // Lo [27] HANGUL SYLLABLE NAG..HANGUL SYLLABLE NAH - {0xB0B4, 0xB0B4, prLV}, // Lo HANGUL SYLLABLE NAE - {0xB0B5, 0xB0CF, prLVT}, // Lo [27] HANGUL SYLLABLE NAEG..HANGUL SYLLABLE NAEH - {0xB0D0, 0xB0D0, prLV}, // Lo HANGUL SYLLABLE NYA - {0xB0D1, 0xB0EB, prLVT}, // Lo [27] HANGUL SYLLABLE NYAG..HANGUL SYLLABLE NYAH - {0xB0EC, 0xB0EC, prLV}, // Lo HANGUL SYLLABLE NYAE - {0xB0ED, 0xB107, prLVT}, // Lo [27] HANGUL SYLLABLE NYAEG..HANGUL SYLLABLE NYAEH - {0xB108, 0xB108, prLV}, // Lo HANGUL SYLLABLE NEO - {0xB109, 0xB123, prLVT}, // Lo [27] HANGUL SYLLABLE NEOG..HANGUL SYLLABLE NEOH - {0xB124, 0xB124, prLV}, // Lo HANGUL SYLLABLE NE - {0xB125, 0xB13F, prLVT}, // Lo [27] HANGUL SYLLABLE NEG..HANGUL SYLLABLE NEH - {0xB140, 0xB140, prLV}, // Lo HANGUL SYLLABLE NYEO - {0xB141, 0xB15B, prLVT}, // Lo [27] HANGUL SYLLABLE NYEOG..HANGUL SYLLABLE NYEOH - {0xB15C, 0xB15C, prLV}, // Lo HANGUL SYLLABLE NYE - {0xB15D, 0xB177, prLVT}, // Lo [27] HANGUL SYLLABLE NYEG..HANGUL SYLLABLE NYEH - {0xB178, 0xB178, prLV}, // Lo HANGUL SYLLABLE NO - {0xB179, 0xB193, prLVT}, // Lo [27] HANGUL SYLLABLE NOG..HANGUL SYLLABLE NOH - {0xB194, 0xB194, prLV}, // Lo HANGUL SYLLABLE NWA - {0xB195, 0xB1AF, prLVT}, // Lo [27] HANGUL SYLLABLE NWAG..HANGUL SYLLABLE NWAH - {0xB1B0, 0xB1B0, prLV}, // Lo HANGUL SYLLABLE NWAE - {0xB1B1, 0xB1CB, prLVT}, // Lo [27] HANGUL SYLLABLE NWAEG..HANGUL SYLLABLE NWAEH - {0xB1CC, 0xB1CC, prLV}, // Lo HANGUL SYLLABLE NOE - {0xB1CD, 0xB1E7, prLVT}, // Lo [27] HANGUL SYLLABLE NOEG..HANGUL SYLLABLE NOEH - {0xB1E8, 0xB1E8, prLV}, // Lo HANGUL SYLLABLE NYO - {0xB1E9, 0xB203, prLVT}, // Lo [27] HANGUL SYLLABLE NYOG..HANGUL SYLLABLE NYOH - {0xB204, 0xB204, prLV}, // Lo HANGUL SYLLABLE NU - {0xB205, 0xB21F, prLVT}, // Lo [27] HANGUL SYLLABLE NUG..HANGUL SYLLABLE NUH - {0xB220, 0xB220, prLV}, // Lo HANGUL SYLLABLE NWEO - {0xB221, 0xB23B, prLVT}, // Lo [27] HANGUL SYLLABLE NWEOG..HANGUL SYLLABLE NWEOH - {0xB23C, 0xB23C, prLV}, // Lo HANGUL SYLLABLE NWE - {0xB23D, 0xB257, prLVT}, // Lo [27] HANGUL SYLLABLE NWEG..HANGUL SYLLABLE NWEH - {0xB258, 0xB258, prLV}, // Lo HANGUL SYLLABLE NWI - {0xB259, 0xB273, prLVT}, // Lo [27] HANGUL SYLLABLE NWIG..HANGUL SYLLABLE NWIH - {0xB274, 0xB274, prLV}, // Lo HANGUL SYLLABLE NYU - {0xB275, 0xB28F, prLVT}, // Lo [27] HANGUL SYLLABLE NYUG..HANGUL SYLLABLE NYUH - {0xB290, 0xB290, prLV}, // Lo HANGUL SYLLABLE NEU - {0xB291, 0xB2AB, prLVT}, // Lo [27] HANGUL SYLLABLE NEUG..HANGUL SYLLABLE NEUH - {0xB2AC, 0xB2AC, prLV}, // Lo HANGUL SYLLABLE NYI - {0xB2AD, 0xB2C7, prLVT}, // Lo [27] HANGUL SYLLABLE NYIG..HANGUL SYLLABLE NYIH - {0xB2C8, 0xB2C8, prLV}, // Lo HANGUL SYLLABLE NI - {0xB2C9, 0xB2E3, prLVT}, // Lo [27] HANGUL SYLLABLE NIG..HANGUL SYLLABLE NIH - {0xB2E4, 0xB2E4, prLV}, // Lo HANGUL SYLLABLE DA - {0xB2E5, 0xB2FF, prLVT}, // Lo [27] HANGUL SYLLABLE DAG..HANGUL SYLLABLE DAH - {0xB300, 0xB300, prLV}, // Lo HANGUL SYLLABLE DAE - {0xB301, 0xB31B, prLVT}, // Lo [27] HANGUL SYLLABLE DAEG..HANGUL SYLLABLE DAEH - {0xB31C, 0xB31C, prLV}, // Lo HANGUL SYLLABLE DYA - {0xB31D, 0xB337, prLVT}, // Lo [27] HANGUL SYLLABLE DYAG..HANGUL SYLLABLE DYAH - {0xB338, 0xB338, prLV}, // Lo HANGUL SYLLABLE DYAE - {0xB339, 0xB353, prLVT}, // Lo [27] HANGUL SYLLABLE DYAEG..HANGUL SYLLABLE DYAEH - {0xB354, 0xB354, prLV}, // Lo HANGUL SYLLABLE DEO - {0xB355, 0xB36F, prLVT}, // Lo [27] HANGUL SYLLABLE DEOG..HANGUL SYLLABLE DEOH - {0xB370, 0xB370, prLV}, // Lo HANGUL SYLLABLE DE - {0xB371, 0xB38B, prLVT}, // Lo [27] HANGUL SYLLABLE DEG..HANGUL SYLLABLE DEH - {0xB38C, 0xB38C, prLV}, // Lo HANGUL SYLLABLE DYEO - {0xB38D, 0xB3A7, prLVT}, // Lo [27] HANGUL SYLLABLE DYEOG..HANGUL SYLLABLE DYEOH - {0xB3A8, 0xB3A8, prLV}, // Lo HANGUL SYLLABLE DYE - {0xB3A9, 0xB3C3, prLVT}, // Lo [27] HANGUL SYLLABLE DYEG..HANGUL SYLLABLE DYEH - {0xB3C4, 0xB3C4, prLV}, // Lo HANGUL SYLLABLE DO - {0xB3C5, 0xB3DF, prLVT}, // Lo [27] HANGUL SYLLABLE DOG..HANGUL SYLLABLE DOH - {0xB3E0, 0xB3E0, prLV}, // Lo HANGUL SYLLABLE DWA - {0xB3E1, 0xB3FB, prLVT}, // Lo [27] HANGUL SYLLABLE DWAG..HANGUL SYLLABLE DWAH - {0xB3FC, 0xB3FC, prLV}, // Lo HANGUL SYLLABLE DWAE - {0xB3FD, 0xB417, prLVT}, // Lo [27] HANGUL SYLLABLE DWAEG..HANGUL SYLLABLE DWAEH - {0xB418, 0xB418, prLV}, // Lo HANGUL SYLLABLE DOE - {0xB419, 0xB433, prLVT}, // Lo [27] HANGUL SYLLABLE DOEG..HANGUL SYLLABLE DOEH - {0xB434, 0xB434, prLV}, // Lo HANGUL SYLLABLE DYO - {0xB435, 0xB44F, prLVT}, // Lo [27] HANGUL SYLLABLE DYOG..HANGUL SYLLABLE DYOH - {0xB450, 0xB450, prLV}, // Lo HANGUL SYLLABLE DU - {0xB451, 0xB46B, prLVT}, // Lo [27] HANGUL SYLLABLE DUG..HANGUL SYLLABLE DUH - {0xB46C, 0xB46C, prLV}, // Lo HANGUL SYLLABLE DWEO - {0xB46D, 0xB487, prLVT}, // Lo [27] HANGUL SYLLABLE DWEOG..HANGUL SYLLABLE DWEOH - {0xB488, 0xB488, prLV}, // Lo HANGUL SYLLABLE DWE - {0xB489, 0xB4A3, prLVT}, // Lo [27] HANGUL SYLLABLE DWEG..HANGUL SYLLABLE DWEH - {0xB4A4, 0xB4A4, prLV}, // Lo HANGUL SYLLABLE DWI - {0xB4A5, 0xB4BF, prLVT}, // Lo [27] HANGUL SYLLABLE DWIG..HANGUL SYLLABLE DWIH - {0xB4C0, 0xB4C0, prLV}, // Lo HANGUL SYLLABLE DYU - {0xB4C1, 0xB4DB, prLVT}, // Lo [27] HANGUL SYLLABLE DYUG..HANGUL SYLLABLE DYUH - {0xB4DC, 0xB4DC, prLV}, // Lo HANGUL SYLLABLE DEU - {0xB4DD, 0xB4F7, prLVT}, // Lo [27] HANGUL SYLLABLE DEUG..HANGUL SYLLABLE DEUH - {0xB4F8, 0xB4F8, prLV}, // Lo HANGUL SYLLABLE DYI - {0xB4F9, 0xB513, prLVT}, // Lo [27] HANGUL SYLLABLE DYIG..HANGUL SYLLABLE DYIH - {0xB514, 0xB514, prLV}, // Lo HANGUL SYLLABLE DI - {0xB515, 0xB52F, prLVT}, // Lo [27] HANGUL SYLLABLE DIG..HANGUL SYLLABLE DIH - {0xB530, 0xB530, prLV}, // Lo HANGUL SYLLABLE DDA - {0xB531, 0xB54B, prLVT}, // Lo [27] HANGUL SYLLABLE DDAG..HANGUL SYLLABLE DDAH - {0xB54C, 0xB54C, prLV}, // Lo HANGUL SYLLABLE DDAE - {0xB54D, 0xB567, prLVT}, // Lo [27] HANGUL SYLLABLE DDAEG..HANGUL SYLLABLE DDAEH - {0xB568, 0xB568, prLV}, // Lo HANGUL SYLLABLE DDYA - {0xB569, 0xB583, prLVT}, // Lo [27] HANGUL SYLLABLE DDYAG..HANGUL SYLLABLE DDYAH - {0xB584, 0xB584, prLV}, // Lo HANGUL SYLLABLE DDYAE - {0xB585, 0xB59F, prLVT}, // Lo [27] HANGUL SYLLABLE DDYAEG..HANGUL SYLLABLE DDYAEH - {0xB5A0, 0xB5A0, prLV}, // Lo HANGUL SYLLABLE DDEO - {0xB5A1, 0xB5BB, prLVT}, // Lo [27] HANGUL SYLLABLE DDEOG..HANGUL SYLLABLE DDEOH - {0xB5BC, 0xB5BC, prLV}, // Lo HANGUL SYLLABLE DDE - {0xB5BD, 0xB5D7, prLVT}, // Lo [27] HANGUL SYLLABLE DDEG..HANGUL SYLLABLE DDEH - {0xB5D8, 0xB5D8, prLV}, // Lo HANGUL SYLLABLE DDYEO - {0xB5D9, 0xB5F3, prLVT}, // Lo [27] HANGUL SYLLABLE DDYEOG..HANGUL SYLLABLE DDYEOH - {0xB5F4, 0xB5F4, prLV}, // Lo HANGUL SYLLABLE DDYE - {0xB5F5, 0xB60F, prLVT}, // Lo [27] HANGUL SYLLABLE DDYEG..HANGUL SYLLABLE DDYEH - {0xB610, 0xB610, prLV}, // Lo HANGUL SYLLABLE DDO - {0xB611, 0xB62B, prLVT}, // Lo [27] HANGUL SYLLABLE DDOG..HANGUL SYLLABLE DDOH - {0xB62C, 0xB62C, prLV}, // Lo HANGUL SYLLABLE DDWA - {0xB62D, 0xB647, prLVT}, // Lo [27] HANGUL SYLLABLE DDWAG..HANGUL SYLLABLE DDWAH - {0xB648, 0xB648, prLV}, // Lo HANGUL SYLLABLE DDWAE - {0xB649, 0xB663, prLVT}, // Lo [27] HANGUL SYLLABLE DDWAEG..HANGUL SYLLABLE DDWAEH - {0xB664, 0xB664, prLV}, // Lo HANGUL SYLLABLE DDOE - {0xB665, 0xB67F, prLVT}, // Lo [27] HANGUL SYLLABLE DDOEG..HANGUL SYLLABLE DDOEH - {0xB680, 0xB680, prLV}, // Lo HANGUL SYLLABLE DDYO - {0xB681, 0xB69B, prLVT}, // Lo [27] HANGUL SYLLABLE DDYOG..HANGUL SYLLABLE DDYOH - {0xB69C, 0xB69C, prLV}, // Lo HANGUL SYLLABLE DDU - {0xB69D, 0xB6B7, prLVT}, // Lo [27] HANGUL SYLLABLE DDUG..HANGUL SYLLABLE DDUH - {0xB6B8, 0xB6B8, prLV}, // Lo HANGUL SYLLABLE DDWEO - {0xB6B9, 0xB6D3, prLVT}, // Lo [27] HANGUL SYLLABLE DDWEOG..HANGUL SYLLABLE DDWEOH - {0xB6D4, 0xB6D4, prLV}, // Lo HANGUL SYLLABLE DDWE - {0xB6D5, 0xB6EF, prLVT}, // Lo [27] HANGUL SYLLABLE DDWEG..HANGUL SYLLABLE DDWEH - {0xB6F0, 0xB6F0, prLV}, // Lo HANGUL SYLLABLE DDWI - {0xB6F1, 0xB70B, prLVT}, // Lo [27] HANGUL SYLLABLE DDWIG..HANGUL SYLLABLE DDWIH - {0xB70C, 0xB70C, prLV}, // Lo HANGUL SYLLABLE DDYU - {0xB70D, 0xB727, prLVT}, // Lo [27] HANGUL SYLLABLE DDYUG..HANGUL SYLLABLE DDYUH - {0xB728, 0xB728, prLV}, // Lo HANGUL SYLLABLE DDEU - {0xB729, 0xB743, prLVT}, // Lo [27] HANGUL SYLLABLE DDEUG..HANGUL SYLLABLE DDEUH - {0xB744, 0xB744, prLV}, // Lo HANGUL SYLLABLE DDYI - {0xB745, 0xB75F, prLVT}, // Lo [27] HANGUL SYLLABLE DDYIG..HANGUL SYLLABLE DDYIH - {0xB760, 0xB760, prLV}, // Lo HANGUL SYLLABLE DDI - {0xB761, 0xB77B, prLVT}, // Lo [27] HANGUL SYLLABLE DDIG..HANGUL SYLLABLE DDIH - {0xB77C, 0xB77C, prLV}, // Lo HANGUL SYLLABLE RA - {0xB77D, 0xB797, prLVT}, // Lo [27] HANGUL SYLLABLE RAG..HANGUL SYLLABLE RAH - {0xB798, 0xB798, prLV}, // Lo HANGUL SYLLABLE RAE - {0xB799, 0xB7B3, prLVT}, // Lo [27] HANGUL SYLLABLE RAEG..HANGUL SYLLABLE RAEH - {0xB7B4, 0xB7B4, prLV}, // Lo HANGUL SYLLABLE RYA - {0xB7B5, 0xB7CF, prLVT}, // Lo [27] HANGUL SYLLABLE RYAG..HANGUL SYLLABLE RYAH - {0xB7D0, 0xB7D0, prLV}, // Lo HANGUL SYLLABLE RYAE - {0xB7D1, 0xB7EB, prLVT}, // Lo [27] HANGUL SYLLABLE RYAEG..HANGUL SYLLABLE RYAEH - {0xB7EC, 0xB7EC, prLV}, // Lo HANGUL SYLLABLE REO - {0xB7ED, 0xB807, prLVT}, // Lo [27] HANGUL SYLLABLE REOG..HANGUL SYLLABLE REOH - {0xB808, 0xB808, prLV}, // Lo HANGUL SYLLABLE RE - {0xB809, 0xB823, prLVT}, // Lo [27] HANGUL SYLLABLE REG..HANGUL SYLLABLE REH - {0xB824, 0xB824, prLV}, // Lo HANGUL SYLLABLE RYEO - {0xB825, 0xB83F, prLVT}, // Lo [27] HANGUL SYLLABLE RYEOG..HANGUL SYLLABLE RYEOH - {0xB840, 0xB840, prLV}, // Lo HANGUL SYLLABLE RYE - {0xB841, 0xB85B, prLVT}, // Lo [27] HANGUL SYLLABLE RYEG..HANGUL SYLLABLE RYEH - {0xB85C, 0xB85C, prLV}, // Lo HANGUL SYLLABLE RO - {0xB85D, 0xB877, prLVT}, // Lo [27] HANGUL SYLLABLE ROG..HANGUL SYLLABLE ROH - {0xB878, 0xB878, prLV}, // Lo HANGUL SYLLABLE RWA - {0xB879, 0xB893, prLVT}, // Lo [27] HANGUL SYLLABLE RWAG..HANGUL SYLLABLE RWAH - {0xB894, 0xB894, prLV}, // Lo HANGUL SYLLABLE RWAE - {0xB895, 0xB8AF, prLVT}, // Lo [27] HANGUL SYLLABLE RWAEG..HANGUL SYLLABLE RWAEH - {0xB8B0, 0xB8B0, prLV}, // Lo HANGUL SYLLABLE ROE - {0xB8B1, 0xB8CB, prLVT}, // Lo [27] HANGUL SYLLABLE ROEG..HANGUL SYLLABLE ROEH - {0xB8CC, 0xB8CC, prLV}, // Lo HANGUL SYLLABLE RYO - {0xB8CD, 0xB8E7, prLVT}, // Lo [27] HANGUL SYLLABLE RYOG..HANGUL SYLLABLE RYOH - {0xB8E8, 0xB8E8, prLV}, // Lo HANGUL SYLLABLE RU - {0xB8E9, 0xB903, prLVT}, // Lo [27] HANGUL SYLLABLE RUG..HANGUL SYLLABLE RUH - {0xB904, 0xB904, prLV}, // Lo HANGUL SYLLABLE RWEO - {0xB905, 0xB91F, prLVT}, // Lo [27] HANGUL SYLLABLE RWEOG..HANGUL SYLLABLE RWEOH - {0xB920, 0xB920, prLV}, // Lo HANGUL SYLLABLE RWE - {0xB921, 0xB93B, prLVT}, // Lo [27] HANGUL SYLLABLE RWEG..HANGUL SYLLABLE RWEH - {0xB93C, 0xB93C, prLV}, // Lo HANGUL SYLLABLE RWI - {0xB93D, 0xB957, prLVT}, // Lo [27] HANGUL SYLLABLE RWIG..HANGUL SYLLABLE RWIH - {0xB958, 0xB958, prLV}, // Lo HANGUL SYLLABLE RYU - {0xB959, 0xB973, prLVT}, // Lo [27] HANGUL SYLLABLE RYUG..HANGUL SYLLABLE RYUH - {0xB974, 0xB974, prLV}, // Lo HANGUL SYLLABLE REU - {0xB975, 0xB98F, prLVT}, // Lo [27] HANGUL SYLLABLE REUG..HANGUL SYLLABLE REUH - {0xB990, 0xB990, prLV}, // Lo HANGUL SYLLABLE RYI - {0xB991, 0xB9AB, prLVT}, // Lo [27] HANGUL SYLLABLE RYIG..HANGUL SYLLABLE RYIH - {0xB9AC, 0xB9AC, prLV}, // Lo HANGUL SYLLABLE RI - {0xB9AD, 0xB9C7, prLVT}, // Lo [27] HANGUL SYLLABLE RIG..HANGUL SYLLABLE RIH - {0xB9C8, 0xB9C8, prLV}, // Lo HANGUL SYLLABLE MA - {0xB9C9, 0xB9E3, prLVT}, // Lo [27] HANGUL SYLLABLE MAG..HANGUL SYLLABLE MAH - {0xB9E4, 0xB9E4, prLV}, // Lo HANGUL SYLLABLE MAE - {0xB9E5, 0xB9FF, prLVT}, // Lo [27] HANGUL SYLLABLE MAEG..HANGUL SYLLABLE MAEH - {0xBA00, 0xBA00, prLV}, // Lo HANGUL SYLLABLE MYA - {0xBA01, 0xBA1B, prLVT}, // Lo [27] HANGUL SYLLABLE MYAG..HANGUL SYLLABLE MYAH - {0xBA1C, 0xBA1C, prLV}, // Lo HANGUL SYLLABLE MYAE - {0xBA1D, 0xBA37, prLVT}, // Lo [27] HANGUL SYLLABLE MYAEG..HANGUL SYLLABLE MYAEH - {0xBA38, 0xBA38, prLV}, // Lo HANGUL SYLLABLE MEO - {0xBA39, 0xBA53, prLVT}, // Lo [27] HANGUL SYLLABLE MEOG..HANGUL SYLLABLE MEOH - {0xBA54, 0xBA54, prLV}, // Lo HANGUL SYLLABLE ME - {0xBA55, 0xBA6F, prLVT}, // Lo [27] HANGUL SYLLABLE MEG..HANGUL SYLLABLE MEH - {0xBA70, 0xBA70, prLV}, // Lo HANGUL SYLLABLE MYEO - {0xBA71, 0xBA8B, prLVT}, // Lo [27] HANGUL SYLLABLE MYEOG..HANGUL SYLLABLE MYEOH - {0xBA8C, 0xBA8C, prLV}, // Lo HANGUL SYLLABLE MYE - {0xBA8D, 0xBAA7, prLVT}, // Lo [27] HANGUL SYLLABLE MYEG..HANGUL SYLLABLE MYEH - {0xBAA8, 0xBAA8, prLV}, // Lo HANGUL SYLLABLE MO - {0xBAA9, 0xBAC3, prLVT}, // Lo [27] HANGUL SYLLABLE MOG..HANGUL SYLLABLE MOH - {0xBAC4, 0xBAC4, prLV}, // Lo HANGUL SYLLABLE MWA - {0xBAC5, 0xBADF, prLVT}, // Lo [27] HANGUL SYLLABLE MWAG..HANGUL SYLLABLE MWAH - {0xBAE0, 0xBAE0, prLV}, // Lo HANGUL SYLLABLE MWAE - {0xBAE1, 0xBAFB, prLVT}, // Lo [27] HANGUL SYLLABLE MWAEG..HANGUL SYLLABLE MWAEH - {0xBAFC, 0xBAFC, prLV}, // Lo HANGUL SYLLABLE MOE - {0xBAFD, 0xBB17, prLVT}, // Lo [27] HANGUL SYLLABLE MOEG..HANGUL SYLLABLE MOEH - {0xBB18, 0xBB18, prLV}, // Lo HANGUL SYLLABLE MYO - {0xBB19, 0xBB33, prLVT}, // Lo [27] HANGUL SYLLABLE MYOG..HANGUL SYLLABLE MYOH - {0xBB34, 0xBB34, prLV}, // Lo HANGUL SYLLABLE MU - {0xBB35, 0xBB4F, prLVT}, // Lo [27] HANGUL SYLLABLE MUG..HANGUL SYLLABLE MUH - {0xBB50, 0xBB50, prLV}, // Lo HANGUL SYLLABLE MWEO - {0xBB51, 0xBB6B, prLVT}, // Lo [27] HANGUL SYLLABLE MWEOG..HANGUL SYLLABLE MWEOH - {0xBB6C, 0xBB6C, prLV}, // Lo HANGUL SYLLABLE MWE - {0xBB6D, 0xBB87, prLVT}, // Lo [27] HANGUL SYLLABLE MWEG..HANGUL SYLLABLE MWEH - {0xBB88, 0xBB88, prLV}, // Lo HANGUL SYLLABLE MWI - {0xBB89, 0xBBA3, prLVT}, // Lo [27] HANGUL SYLLABLE MWIG..HANGUL SYLLABLE MWIH - {0xBBA4, 0xBBA4, prLV}, // Lo HANGUL SYLLABLE MYU - {0xBBA5, 0xBBBF, prLVT}, // Lo [27] HANGUL SYLLABLE MYUG..HANGUL SYLLABLE MYUH - {0xBBC0, 0xBBC0, prLV}, // Lo HANGUL SYLLABLE MEU - {0xBBC1, 0xBBDB, prLVT}, // Lo [27] HANGUL SYLLABLE MEUG..HANGUL SYLLABLE MEUH - {0xBBDC, 0xBBDC, prLV}, // Lo HANGUL SYLLABLE MYI - {0xBBDD, 0xBBF7, prLVT}, // Lo [27] HANGUL SYLLABLE MYIG..HANGUL SYLLABLE MYIH - {0xBBF8, 0xBBF8, prLV}, // Lo HANGUL SYLLABLE MI - {0xBBF9, 0xBC13, prLVT}, // Lo [27] HANGUL SYLLABLE MIG..HANGUL SYLLABLE MIH - {0xBC14, 0xBC14, prLV}, // Lo HANGUL SYLLABLE BA - {0xBC15, 0xBC2F, prLVT}, // Lo [27] HANGUL SYLLABLE BAG..HANGUL SYLLABLE BAH - {0xBC30, 0xBC30, prLV}, // Lo HANGUL SYLLABLE BAE - {0xBC31, 0xBC4B, prLVT}, // Lo [27] HANGUL SYLLABLE BAEG..HANGUL SYLLABLE BAEH - {0xBC4C, 0xBC4C, prLV}, // Lo HANGUL SYLLABLE BYA - {0xBC4D, 0xBC67, prLVT}, // Lo [27] HANGUL SYLLABLE BYAG..HANGUL SYLLABLE BYAH - {0xBC68, 0xBC68, prLV}, // Lo HANGUL SYLLABLE BYAE - {0xBC69, 0xBC83, prLVT}, // Lo [27] HANGUL SYLLABLE BYAEG..HANGUL SYLLABLE BYAEH - {0xBC84, 0xBC84, prLV}, // Lo HANGUL SYLLABLE BEO - {0xBC85, 0xBC9F, prLVT}, // Lo [27] HANGUL SYLLABLE BEOG..HANGUL SYLLABLE BEOH - {0xBCA0, 0xBCA0, prLV}, // Lo HANGUL SYLLABLE BE - {0xBCA1, 0xBCBB, prLVT}, // Lo [27] HANGUL SYLLABLE BEG..HANGUL SYLLABLE BEH - {0xBCBC, 0xBCBC, prLV}, // Lo HANGUL SYLLABLE BYEO - {0xBCBD, 0xBCD7, prLVT}, // Lo [27] HANGUL SYLLABLE BYEOG..HANGUL SYLLABLE BYEOH - {0xBCD8, 0xBCD8, prLV}, // Lo HANGUL SYLLABLE BYE - {0xBCD9, 0xBCF3, prLVT}, // Lo [27] HANGUL SYLLABLE BYEG..HANGUL SYLLABLE BYEH - {0xBCF4, 0xBCF4, prLV}, // Lo HANGUL SYLLABLE BO - {0xBCF5, 0xBD0F, prLVT}, // Lo [27] HANGUL SYLLABLE BOG..HANGUL SYLLABLE BOH - {0xBD10, 0xBD10, prLV}, // Lo HANGUL SYLLABLE BWA - {0xBD11, 0xBD2B, prLVT}, // Lo [27] HANGUL SYLLABLE BWAG..HANGUL SYLLABLE BWAH - {0xBD2C, 0xBD2C, prLV}, // Lo HANGUL SYLLABLE BWAE - {0xBD2D, 0xBD47, prLVT}, // Lo [27] HANGUL SYLLABLE BWAEG..HANGUL SYLLABLE BWAEH - {0xBD48, 0xBD48, prLV}, // Lo HANGUL SYLLABLE BOE - {0xBD49, 0xBD63, prLVT}, // Lo [27] HANGUL SYLLABLE BOEG..HANGUL SYLLABLE BOEH - {0xBD64, 0xBD64, prLV}, // Lo HANGUL SYLLABLE BYO - {0xBD65, 0xBD7F, prLVT}, // Lo [27] HANGUL SYLLABLE BYOG..HANGUL SYLLABLE BYOH - {0xBD80, 0xBD80, prLV}, // Lo HANGUL SYLLABLE BU - {0xBD81, 0xBD9B, prLVT}, // Lo [27] HANGUL SYLLABLE BUG..HANGUL SYLLABLE BUH - {0xBD9C, 0xBD9C, prLV}, // Lo HANGUL SYLLABLE BWEO - {0xBD9D, 0xBDB7, prLVT}, // Lo [27] HANGUL SYLLABLE BWEOG..HANGUL SYLLABLE BWEOH - {0xBDB8, 0xBDB8, prLV}, // Lo HANGUL SYLLABLE BWE - {0xBDB9, 0xBDD3, prLVT}, // Lo [27] HANGUL SYLLABLE BWEG..HANGUL SYLLABLE BWEH - {0xBDD4, 0xBDD4, prLV}, // Lo HANGUL SYLLABLE BWI - {0xBDD5, 0xBDEF, prLVT}, // Lo [27] HANGUL SYLLABLE BWIG..HANGUL SYLLABLE BWIH - {0xBDF0, 0xBDF0, prLV}, // Lo HANGUL SYLLABLE BYU - {0xBDF1, 0xBE0B, prLVT}, // Lo [27] HANGUL SYLLABLE BYUG..HANGUL SYLLABLE BYUH - {0xBE0C, 0xBE0C, prLV}, // Lo HANGUL SYLLABLE BEU - {0xBE0D, 0xBE27, prLVT}, // Lo [27] HANGUL SYLLABLE BEUG..HANGUL SYLLABLE BEUH - {0xBE28, 0xBE28, prLV}, // Lo HANGUL SYLLABLE BYI - {0xBE29, 0xBE43, prLVT}, // Lo [27] HANGUL SYLLABLE BYIG..HANGUL SYLLABLE BYIH - {0xBE44, 0xBE44, prLV}, // Lo HANGUL SYLLABLE BI - {0xBE45, 0xBE5F, prLVT}, // Lo [27] HANGUL SYLLABLE BIG..HANGUL SYLLABLE BIH - {0xBE60, 0xBE60, prLV}, // Lo HANGUL SYLLABLE BBA - {0xBE61, 0xBE7B, prLVT}, // Lo [27] HANGUL SYLLABLE BBAG..HANGUL SYLLABLE BBAH - {0xBE7C, 0xBE7C, prLV}, // Lo HANGUL SYLLABLE BBAE - {0xBE7D, 0xBE97, prLVT}, // Lo [27] HANGUL SYLLABLE BBAEG..HANGUL SYLLABLE BBAEH - {0xBE98, 0xBE98, prLV}, // Lo HANGUL SYLLABLE BBYA - {0xBE99, 0xBEB3, prLVT}, // Lo [27] HANGUL SYLLABLE BBYAG..HANGUL SYLLABLE BBYAH - {0xBEB4, 0xBEB4, prLV}, // Lo HANGUL SYLLABLE BBYAE - {0xBEB5, 0xBECF, prLVT}, // Lo [27] HANGUL SYLLABLE BBYAEG..HANGUL SYLLABLE BBYAEH - {0xBED0, 0xBED0, prLV}, // Lo HANGUL SYLLABLE BBEO - {0xBED1, 0xBEEB, prLVT}, // Lo [27] HANGUL SYLLABLE BBEOG..HANGUL SYLLABLE BBEOH - {0xBEEC, 0xBEEC, prLV}, // Lo HANGUL SYLLABLE BBE - {0xBEED, 0xBF07, prLVT}, // Lo [27] HANGUL SYLLABLE BBEG..HANGUL SYLLABLE BBEH - {0xBF08, 0xBF08, prLV}, // Lo HANGUL SYLLABLE BBYEO - {0xBF09, 0xBF23, prLVT}, // Lo [27] HANGUL SYLLABLE BBYEOG..HANGUL SYLLABLE BBYEOH - {0xBF24, 0xBF24, prLV}, // Lo HANGUL SYLLABLE BBYE - {0xBF25, 0xBF3F, prLVT}, // Lo [27] HANGUL SYLLABLE BBYEG..HANGUL SYLLABLE BBYEH - {0xBF40, 0xBF40, prLV}, // Lo HANGUL SYLLABLE BBO - {0xBF41, 0xBF5B, prLVT}, // Lo [27] HANGUL SYLLABLE BBOG..HANGUL SYLLABLE BBOH - {0xBF5C, 0xBF5C, prLV}, // Lo HANGUL SYLLABLE BBWA - {0xBF5D, 0xBF77, prLVT}, // Lo [27] HANGUL SYLLABLE BBWAG..HANGUL SYLLABLE BBWAH - {0xBF78, 0xBF78, prLV}, // Lo HANGUL SYLLABLE BBWAE - {0xBF79, 0xBF93, prLVT}, // Lo [27] HANGUL SYLLABLE BBWAEG..HANGUL SYLLABLE BBWAEH - {0xBF94, 0xBF94, prLV}, // Lo HANGUL SYLLABLE BBOE - {0xBF95, 0xBFAF, prLVT}, // Lo [27] HANGUL SYLLABLE BBOEG..HANGUL SYLLABLE BBOEH - {0xBFB0, 0xBFB0, prLV}, // Lo HANGUL SYLLABLE BBYO - {0xBFB1, 0xBFCB, prLVT}, // Lo [27] HANGUL SYLLABLE BBYOG..HANGUL SYLLABLE BBYOH - {0xBFCC, 0xBFCC, prLV}, // Lo HANGUL SYLLABLE BBU - {0xBFCD, 0xBFE7, prLVT}, // Lo [27] HANGUL SYLLABLE BBUG..HANGUL SYLLABLE BBUH - {0xBFE8, 0xBFE8, prLV}, // Lo HANGUL SYLLABLE BBWEO - {0xBFE9, 0xC003, prLVT}, // Lo [27] HANGUL SYLLABLE BBWEOG..HANGUL SYLLABLE BBWEOH - {0xC004, 0xC004, prLV}, // Lo HANGUL SYLLABLE BBWE - {0xC005, 0xC01F, prLVT}, // Lo [27] HANGUL SYLLABLE BBWEG..HANGUL SYLLABLE BBWEH - {0xC020, 0xC020, prLV}, // Lo HANGUL SYLLABLE BBWI - {0xC021, 0xC03B, prLVT}, // Lo [27] HANGUL SYLLABLE BBWIG..HANGUL SYLLABLE BBWIH - {0xC03C, 0xC03C, prLV}, // Lo HANGUL SYLLABLE BBYU - {0xC03D, 0xC057, prLVT}, // Lo [27] HANGUL SYLLABLE BBYUG..HANGUL SYLLABLE BBYUH - {0xC058, 0xC058, prLV}, // Lo HANGUL SYLLABLE BBEU - {0xC059, 0xC073, prLVT}, // Lo [27] HANGUL SYLLABLE BBEUG..HANGUL SYLLABLE BBEUH - {0xC074, 0xC074, prLV}, // Lo HANGUL SYLLABLE BBYI - {0xC075, 0xC08F, prLVT}, // Lo [27] HANGUL SYLLABLE BBYIG..HANGUL SYLLABLE BBYIH - {0xC090, 0xC090, prLV}, // Lo HANGUL SYLLABLE BBI - {0xC091, 0xC0AB, prLVT}, // Lo [27] HANGUL SYLLABLE BBIG..HANGUL SYLLABLE BBIH - {0xC0AC, 0xC0AC, prLV}, // Lo HANGUL SYLLABLE SA - {0xC0AD, 0xC0C7, prLVT}, // Lo [27] HANGUL SYLLABLE SAG..HANGUL SYLLABLE SAH - {0xC0C8, 0xC0C8, prLV}, // Lo HANGUL SYLLABLE SAE - {0xC0C9, 0xC0E3, prLVT}, // Lo [27] HANGUL SYLLABLE SAEG..HANGUL SYLLABLE SAEH - {0xC0E4, 0xC0E4, prLV}, // Lo HANGUL SYLLABLE SYA - {0xC0E5, 0xC0FF, prLVT}, // Lo [27] HANGUL SYLLABLE SYAG..HANGUL SYLLABLE SYAH - {0xC100, 0xC100, prLV}, // Lo HANGUL SYLLABLE SYAE - {0xC101, 0xC11B, prLVT}, // Lo [27] HANGUL SYLLABLE SYAEG..HANGUL SYLLABLE SYAEH - {0xC11C, 0xC11C, prLV}, // Lo HANGUL SYLLABLE SEO - {0xC11D, 0xC137, prLVT}, // Lo [27] HANGUL SYLLABLE SEOG..HANGUL SYLLABLE SEOH - {0xC138, 0xC138, prLV}, // Lo HANGUL SYLLABLE SE - {0xC139, 0xC153, prLVT}, // Lo [27] HANGUL SYLLABLE SEG..HANGUL SYLLABLE SEH - {0xC154, 0xC154, prLV}, // Lo HANGUL SYLLABLE SYEO - {0xC155, 0xC16F, prLVT}, // Lo [27] HANGUL SYLLABLE SYEOG..HANGUL SYLLABLE SYEOH - {0xC170, 0xC170, prLV}, // Lo HANGUL SYLLABLE SYE - {0xC171, 0xC18B, prLVT}, // Lo [27] HANGUL SYLLABLE SYEG..HANGUL SYLLABLE SYEH - {0xC18C, 0xC18C, prLV}, // Lo HANGUL SYLLABLE SO - {0xC18D, 0xC1A7, prLVT}, // Lo [27] HANGUL SYLLABLE SOG..HANGUL SYLLABLE SOH - {0xC1A8, 0xC1A8, prLV}, // Lo HANGUL SYLLABLE SWA - {0xC1A9, 0xC1C3, prLVT}, // Lo [27] HANGUL SYLLABLE SWAG..HANGUL SYLLABLE SWAH - {0xC1C4, 0xC1C4, prLV}, // Lo HANGUL SYLLABLE SWAE - {0xC1C5, 0xC1DF, prLVT}, // Lo [27] HANGUL SYLLABLE SWAEG..HANGUL SYLLABLE SWAEH - {0xC1E0, 0xC1E0, prLV}, // Lo HANGUL SYLLABLE SOE - {0xC1E1, 0xC1FB, prLVT}, // Lo [27] HANGUL SYLLABLE SOEG..HANGUL SYLLABLE SOEH - {0xC1FC, 0xC1FC, prLV}, // Lo HANGUL SYLLABLE SYO - {0xC1FD, 0xC217, prLVT}, // Lo [27] HANGUL SYLLABLE SYOG..HANGUL SYLLABLE SYOH - {0xC218, 0xC218, prLV}, // Lo HANGUL SYLLABLE SU - {0xC219, 0xC233, prLVT}, // Lo [27] HANGUL SYLLABLE SUG..HANGUL SYLLABLE SUH - {0xC234, 0xC234, prLV}, // Lo HANGUL SYLLABLE SWEO - {0xC235, 0xC24F, prLVT}, // Lo [27] HANGUL SYLLABLE SWEOG..HANGUL SYLLABLE SWEOH - {0xC250, 0xC250, prLV}, // Lo HANGUL SYLLABLE SWE - {0xC251, 0xC26B, prLVT}, // Lo [27] HANGUL SYLLABLE SWEG..HANGUL SYLLABLE SWEH - {0xC26C, 0xC26C, prLV}, // Lo HANGUL SYLLABLE SWI - {0xC26D, 0xC287, prLVT}, // Lo [27] HANGUL SYLLABLE SWIG..HANGUL SYLLABLE SWIH - {0xC288, 0xC288, prLV}, // Lo HANGUL SYLLABLE SYU - {0xC289, 0xC2A3, prLVT}, // Lo [27] HANGUL SYLLABLE SYUG..HANGUL SYLLABLE SYUH - {0xC2A4, 0xC2A4, prLV}, // Lo HANGUL SYLLABLE SEU - {0xC2A5, 0xC2BF, prLVT}, // Lo [27] HANGUL SYLLABLE SEUG..HANGUL SYLLABLE SEUH - {0xC2C0, 0xC2C0, prLV}, // Lo HANGUL SYLLABLE SYI - {0xC2C1, 0xC2DB, prLVT}, // Lo [27] HANGUL SYLLABLE SYIG..HANGUL SYLLABLE SYIH - {0xC2DC, 0xC2DC, prLV}, // Lo HANGUL SYLLABLE SI - {0xC2DD, 0xC2F7, prLVT}, // Lo [27] HANGUL SYLLABLE SIG..HANGUL SYLLABLE SIH - {0xC2F8, 0xC2F8, prLV}, // Lo HANGUL SYLLABLE SSA - {0xC2F9, 0xC313, prLVT}, // Lo [27] HANGUL SYLLABLE SSAG..HANGUL SYLLABLE SSAH - {0xC314, 0xC314, prLV}, // Lo HANGUL SYLLABLE SSAE - {0xC315, 0xC32F, prLVT}, // Lo [27] HANGUL SYLLABLE SSAEG..HANGUL SYLLABLE SSAEH - {0xC330, 0xC330, prLV}, // Lo HANGUL SYLLABLE SSYA - {0xC331, 0xC34B, prLVT}, // Lo [27] HANGUL SYLLABLE SSYAG..HANGUL SYLLABLE SSYAH - {0xC34C, 0xC34C, prLV}, // Lo HANGUL SYLLABLE SSYAE - {0xC34D, 0xC367, prLVT}, // Lo [27] HANGUL SYLLABLE SSYAEG..HANGUL SYLLABLE SSYAEH - {0xC368, 0xC368, prLV}, // Lo HANGUL SYLLABLE SSEO - {0xC369, 0xC383, prLVT}, // Lo [27] HANGUL SYLLABLE SSEOG..HANGUL SYLLABLE SSEOH - {0xC384, 0xC384, prLV}, // Lo HANGUL SYLLABLE SSE - {0xC385, 0xC39F, prLVT}, // Lo [27] HANGUL SYLLABLE SSEG..HANGUL SYLLABLE SSEH - {0xC3A0, 0xC3A0, prLV}, // Lo HANGUL SYLLABLE SSYEO - {0xC3A1, 0xC3BB, prLVT}, // Lo [27] HANGUL SYLLABLE SSYEOG..HANGUL SYLLABLE SSYEOH - {0xC3BC, 0xC3BC, prLV}, // Lo HANGUL SYLLABLE SSYE - {0xC3BD, 0xC3D7, prLVT}, // Lo [27] HANGUL SYLLABLE SSYEG..HANGUL SYLLABLE SSYEH - {0xC3D8, 0xC3D8, prLV}, // Lo HANGUL SYLLABLE SSO - {0xC3D9, 0xC3F3, prLVT}, // Lo [27] HANGUL SYLLABLE SSOG..HANGUL SYLLABLE SSOH - {0xC3F4, 0xC3F4, prLV}, // Lo HANGUL SYLLABLE SSWA - {0xC3F5, 0xC40F, prLVT}, // Lo [27] HANGUL SYLLABLE SSWAG..HANGUL SYLLABLE SSWAH - {0xC410, 0xC410, prLV}, // Lo HANGUL SYLLABLE SSWAE - {0xC411, 0xC42B, prLVT}, // Lo [27] HANGUL SYLLABLE SSWAEG..HANGUL SYLLABLE SSWAEH - {0xC42C, 0xC42C, prLV}, // Lo HANGUL SYLLABLE SSOE - {0xC42D, 0xC447, prLVT}, // Lo [27] HANGUL SYLLABLE SSOEG..HANGUL SYLLABLE SSOEH - {0xC448, 0xC448, prLV}, // Lo HANGUL SYLLABLE SSYO - {0xC449, 0xC463, prLVT}, // Lo [27] HANGUL SYLLABLE SSYOG..HANGUL SYLLABLE SSYOH - {0xC464, 0xC464, prLV}, // Lo HANGUL SYLLABLE SSU - {0xC465, 0xC47F, prLVT}, // Lo [27] HANGUL SYLLABLE SSUG..HANGUL SYLLABLE SSUH - {0xC480, 0xC480, prLV}, // Lo HANGUL SYLLABLE SSWEO - {0xC481, 0xC49B, prLVT}, // Lo [27] HANGUL SYLLABLE SSWEOG..HANGUL SYLLABLE SSWEOH - {0xC49C, 0xC49C, prLV}, // Lo HANGUL SYLLABLE SSWE - {0xC49D, 0xC4B7, prLVT}, // Lo [27] HANGUL SYLLABLE SSWEG..HANGUL SYLLABLE SSWEH - {0xC4B8, 0xC4B8, prLV}, // Lo HANGUL SYLLABLE SSWI - {0xC4B9, 0xC4D3, prLVT}, // Lo [27] HANGUL SYLLABLE SSWIG..HANGUL SYLLABLE SSWIH - {0xC4D4, 0xC4D4, prLV}, // Lo HANGUL SYLLABLE SSYU - {0xC4D5, 0xC4EF, prLVT}, // Lo [27] HANGUL SYLLABLE SSYUG..HANGUL SYLLABLE SSYUH - {0xC4F0, 0xC4F0, prLV}, // Lo HANGUL SYLLABLE SSEU - {0xC4F1, 0xC50B, prLVT}, // Lo [27] HANGUL SYLLABLE SSEUG..HANGUL SYLLABLE SSEUH - {0xC50C, 0xC50C, prLV}, // Lo HANGUL SYLLABLE SSYI - {0xC50D, 0xC527, prLVT}, // Lo [27] HANGUL SYLLABLE SSYIG..HANGUL SYLLABLE SSYIH - {0xC528, 0xC528, prLV}, // Lo HANGUL SYLLABLE SSI - {0xC529, 0xC543, prLVT}, // Lo [27] HANGUL SYLLABLE SSIG..HANGUL SYLLABLE SSIH - {0xC544, 0xC544, prLV}, // Lo HANGUL SYLLABLE A - {0xC545, 0xC55F, prLVT}, // Lo [27] HANGUL SYLLABLE AG..HANGUL SYLLABLE AH - {0xC560, 0xC560, prLV}, // Lo HANGUL SYLLABLE AE - {0xC561, 0xC57B, prLVT}, // Lo [27] HANGUL SYLLABLE AEG..HANGUL SYLLABLE AEH - {0xC57C, 0xC57C, prLV}, // Lo HANGUL SYLLABLE YA - {0xC57D, 0xC597, prLVT}, // Lo [27] HANGUL SYLLABLE YAG..HANGUL SYLLABLE YAH - {0xC598, 0xC598, prLV}, // Lo HANGUL SYLLABLE YAE - {0xC599, 0xC5B3, prLVT}, // Lo [27] HANGUL SYLLABLE YAEG..HANGUL SYLLABLE YAEH - {0xC5B4, 0xC5B4, prLV}, // Lo HANGUL SYLLABLE EO - {0xC5B5, 0xC5CF, prLVT}, // Lo [27] HANGUL SYLLABLE EOG..HANGUL SYLLABLE EOH - {0xC5D0, 0xC5D0, prLV}, // Lo HANGUL SYLLABLE E - {0xC5D1, 0xC5EB, prLVT}, // Lo [27] HANGUL SYLLABLE EG..HANGUL SYLLABLE EH - {0xC5EC, 0xC5EC, prLV}, // Lo HANGUL SYLLABLE YEO - {0xC5ED, 0xC607, prLVT}, // Lo [27] HANGUL SYLLABLE YEOG..HANGUL SYLLABLE YEOH - {0xC608, 0xC608, prLV}, // Lo HANGUL SYLLABLE YE - {0xC609, 0xC623, prLVT}, // Lo [27] HANGUL SYLLABLE YEG..HANGUL SYLLABLE YEH - {0xC624, 0xC624, prLV}, // Lo HANGUL SYLLABLE O - {0xC625, 0xC63F, prLVT}, // Lo [27] HANGUL SYLLABLE OG..HANGUL SYLLABLE OH - {0xC640, 0xC640, prLV}, // Lo HANGUL SYLLABLE WA - {0xC641, 0xC65B, prLVT}, // Lo [27] HANGUL SYLLABLE WAG..HANGUL SYLLABLE WAH - {0xC65C, 0xC65C, prLV}, // Lo HANGUL SYLLABLE WAE - {0xC65D, 0xC677, prLVT}, // Lo [27] HANGUL SYLLABLE WAEG..HANGUL SYLLABLE WAEH - {0xC678, 0xC678, prLV}, // Lo HANGUL SYLLABLE OE - {0xC679, 0xC693, prLVT}, // Lo [27] HANGUL SYLLABLE OEG..HANGUL SYLLABLE OEH - {0xC694, 0xC694, prLV}, // Lo HANGUL SYLLABLE YO - {0xC695, 0xC6AF, prLVT}, // Lo [27] HANGUL SYLLABLE YOG..HANGUL SYLLABLE YOH - {0xC6B0, 0xC6B0, prLV}, // Lo HANGUL SYLLABLE U - {0xC6B1, 0xC6CB, prLVT}, // Lo [27] HANGUL SYLLABLE UG..HANGUL SYLLABLE UH - {0xC6CC, 0xC6CC, prLV}, // Lo HANGUL SYLLABLE WEO - {0xC6CD, 0xC6E7, prLVT}, // Lo [27] HANGUL SYLLABLE WEOG..HANGUL SYLLABLE WEOH - {0xC6E8, 0xC6E8, prLV}, // Lo HANGUL SYLLABLE WE - {0xC6E9, 0xC703, prLVT}, // Lo [27] HANGUL SYLLABLE WEG..HANGUL SYLLABLE WEH - {0xC704, 0xC704, prLV}, // Lo HANGUL SYLLABLE WI - {0xC705, 0xC71F, prLVT}, // Lo [27] HANGUL SYLLABLE WIG..HANGUL SYLLABLE WIH - {0xC720, 0xC720, prLV}, // Lo HANGUL SYLLABLE YU - {0xC721, 0xC73B, prLVT}, // Lo [27] HANGUL SYLLABLE YUG..HANGUL SYLLABLE YUH - {0xC73C, 0xC73C, prLV}, // Lo HANGUL SYLLABLE EU - {0xC73D, 0xC757, prLVT}, // Lo [27] HANGUL SYLLABLE EUG..HANGUL SYLLABLE EUH - {0xC758, 0xC758, prLV}, // Lo HANGUL SYLLABLE YI - {0xC759, 0xC773, prLVT}, // Lo [27] HANGUL SYLLABLE YIG..HANGUL SYLLABLE YIH - {0xC774, 0xC774, prLV}, // Lo HANGUL SYLLABLE I - {0xC775, 0xC78F, prLVT}, // Lo [27] HANGUL SYLLABLE IG..HANGUL SYLLABLE IH - {0xC790, 0xC790, prLV}, // Lo HANGUL SYLLABLE JA - {0xC791, 0xC7AB, prLVT}, // Lo [27] HANGUL SYLLABLE JAG..HANGUL SYLLABLE JAH - {0xC7AC, 0xC7AC, prLV}, // Lo HANGUL SYLLABLE JAE - {0xC7AD, 0xC7C7, prLVT}, // Lo [27] HANGUL SYLLABLE JAEG..HANGUL SYLLABLE JAEH - {0xC7C8, 0xC7C8, prLV}, // Lo HANGUL SYLLABLE JYA - {0xC7C9, 0xC7E3, prLVT}, // Lo [27] HANGUL SYLLABLE JYAG..HANGUL SYLLABLE JYAH - {0xC7E4, 0xC7E4, prLV}, // Lo HANGUL SYLLABLE JYAE - {0xC7E5, 0xC7FF, prLVT}, // Lo [27] HANGUL SYLLABLE JYAEG..HANGUL SYLLABLE JYAEH - {0xC800, 0xC800, prLV}, // Lo HANGUL SYLLABLE JEO - {0xC801, 0xC81B, prLVT}, // Lo [27] HANGUL SYLLABLE JEOG..HANGUL SYLLABLE JEOH - {0xC81C, 0xC81C, prLV}, // Lo HANGUL SYLLABLE JE - {0xC81D, 0xC837, prLVT}, // Lo [27] HANGUL SYLLABLE JEG..HANGUL SYLLABLE JEH - {0xC838, 0xC838, prLV}, // Lo HANGUL SYLLABLE JYEO - {0xC839, 0xC853, prLVT}, // Lo [27] HANGUL SYLLABLE JYEOG..HANGUL SYLLABLE JYEOH - {0xC854, 0xC854, prLV}, // Lo HANGUL SYLLABLE JYE - {0xC855, 0xC86F, prLVT}, // Lo [27] HANGUL SYLLABLE JYEG..HANGUL SYLLABLE JYEH - {0xC870, 0xC870, prLV}, // Lo HANGUL SYLLABLE JO - {0xC871, 0xC88B, prLVT}, // Lo [27] HANGUL SYLLABLE JOG..HANGUL SYLLABLE JOH - {0xC88C, 0xC88C, prLV}, // Lo HANGUL SYLLABLE JWA - {0xC88D, 0xC8A7, prLVT}, // Lo [27] HANGUL SYLLABLE JWAG..HANGUL SYLLABLE JWAH - {0xC8A8, 0xC8A8, prLV}, // Lo HANGUL SYLLABLE JWAE - {0xC8A9, 0xC8C3, prLVT}, // Lo [27] HANGUL SYLLABLE JWAEG..HANGUL SYLLABLE JWAEH - {0xC8C4, 0xC8C4, prLV}, // Lo HANGUL SYLLABLE JOE - {0xC8C5, 0xC8DF, prLVT}, // Lo [27] HANGUL SYLLABLE JOEG..HANGUL SYLLABLE JOEH - {0xC8E0, 0xC8E0, prLV}, // Lo HANGUL SYLLABLE JYO - {0xC8E1, 0xC8FB, prLVT}, // Lo [27] HANGUL SYLLABLE JYOG..HANGUL SYLLABLE JYOH - {0xC8FC, 0xC8FC, prLV}, // Lo HANGUL SYLLABLE JU - {0xC8FD, 0xC917, prLVT}, // Lo [27] HANGUL SYLLABLE JUG..HANGUL SYLLABLE JUH - {0xC918, 0xC918, prLV}, // Lo HANGUL SYLLABLE JWEO - {0xC919, 0xC933, prLVT}, // Lo [27] HANGUL SYLLABLE JWEOG..HANGUL SYLLABLE JWEOH - {0xC934, 0xC934, prLV}, // Lo HANGUL SYLLABLE JWE - {0xC935, 0xC94F, prLVT}, // Lo [27] HANGUL SYLLABLE JWEG..HANGUL SYLLABLE JWEH - {0xC950, 0xC950, prLV}, // Lo HANGUL SYLLABLE JWI - {0xC951, 0xC96B, prLVT}, // Lo [27] HANGUL SYLLABLE JWIG..HANGUL SYLLABLE JWIH - {0xC96C, 0xC96C, prLV}, // Lo HANGUL SYLLABLE JYU - {0xC96D, 0xC987, prLVT}, // Lo [27] HANGUL SYLLABLE JYUG..HANGUL SYLLABLE JYUH - {0xC988, 0xC988, prLV}, // Lo HANGUL SYLLABLE JEU - {0xC989, 0xC9A3, prLVT}, // Lo [27] HANGUL SYLLABLE JEUG..HANGUL SYLLABLE JEUH - {0xC9A4, 0xC9A4, prLV}, // Lo HANGUL SYLLABLE JYI - {0xC9A5, 0xC9BF, prLVT}, // Lo [27] HANGUL SYLLABLE JYIG..HANGUL SYLLABLE JYIH - {0xC9C0, 0xC9C0, prLV}, // Lo HANGUL SYLLABLE JI - {0xC9C1, 0xC9DB, prLVT}, // Lo [27] HANGUL SYLLABLE JIG..HANGUL SYLLABLE JIH - {0xC9DC, 0xC9DC, prLV}, // Lo HANGUL SYLLABLE JJA - {0xC9DD, 0xC9F7, prLVT}, // Lo [27] HANGUL SYLLABLE JJAG..HANGUL SYLLABLE JJAH - {0xC9F8, 0xC9F8, prLV}, // Lo HANGUL SYLLABLE JJAE - {0xC9F9, 0xCA13, prLVT}, // Lo [27] HANGUL SYLLABLE JJAEG..HANGUL SYLLABLE JJAEH - {0xCA14, 0xCA14, prLV}, // Lo HANGUL SYLLABLE JJYA - {0xCA15, 0xCA2F, prLVT}, // Lo [27] HANGUL SYLLABLE JJYAG..HANGUL SYLLABLE JJYAH - {0xCA30, 0xCA30, prLV}, // Lo HANGUL SYLLABLE JJYAE - {0xCA31, 0xCA4B, prLVT}, // Lo [27] HANGUL SYLLABLE JJYAEG..HANGUL SYLLABLE JJYAEH - {0xCA4C, 0xCA4C, prLV}, // Lo HANGUL SYLLABLE JJEO - {0xCA4D, 0xCA67, prLVT}, // Lo [27] HANGUL SYLLABLE JJEOG..HANGUL SYLLABLE JJEOH - {0xCA68, 0xCA68, prLV}, // Lo HANGUL SYLLABLE JJE - {0xCA69, 0xCA83, prLVT}, // Lo [27] HANGUL SYLLABLE JJEG..HANGUL SYLLABLE JJEH - {0xCA84, 0xCA84, prLV}, // Lo HANGUL SYLLABLE JJYEO - {0xCA85, 0xCA9F, prLVT}, // Lo [27] HANGUL SYLLABLE JJYEOG..HANGUL SYLLABLE JJYEOH - {0xCAA0, 0xCAA0, prLV}, // Lo HANGUL SYLLABLE JJYE - {0xCAA1, 0xCABB, prLVT}, // Lo [27] HANGUL SYLLABLE JJYEG..HANGUL SYLLABLE JJYEH - {0xCABC, 0xCABC, prLV}, // Lo HANGUL SYLLABLE JJO - {0xCABD, 0xCAD7, prLVT}, // Lo [27] HANGUL SYLLABLE JJOG..HANGUL SYLLABLE JJOH - {0xCAD8, 0xCAD8, prLV}, // Lo HANGUL SYLLABLE JJWA - {0xCAD9, 0xCAF3, prLVT}, // Lo [27] HANGUL SYLLABLE JJWAG..HANGUL SYLLABLE JJWAH - {0xCAF4, 0xCAF4, prLV}, // Lo HANGUL SYLLABLE JJWAE - {0xCAF5, 0xCB0F, prLVT}, // Lo [27] HANGUL SYLLABLE JJWAEG..HANGUL SYLLABLE JJWAEH - {0xCB10, 0xCB10, prLV}, // Lo HANGUL SYLLABLE JJOE - {0xCB11, 0xCB2B, prLVT}, // Lo [27] HANGUL SYLLABLE JJOEG..HANGUL SYLLABLE JJOEH - {0xCB2C, 0xCB2C, prLV}, // Lo HANGUL SYLLABLE JJYO - {0xCB2D, 0xCB47, prLVT}, // Lo [27] HANGUL SYLLABLE JJYOG..HANGUL SYLLABLE JJYOH - {0xCB48, 0xCB48, prLV}, // Lo HANGUL SYLLABLE JJU - {0xCB49, 0xCB63, prLVT}, // Lo [27] HANGUL SYLLABLE JJUG..HANGUL SYLLABLE JJUH - {0xCB64, 0xCB64, prLV}, // Lo HANGUL SYLLABLE JJWEO - {0xCB65, 0xCB7F, prLVT}, // Lo [27] HANGUL SYLLABLE JJWEOG..HANGUL SYLLABLE JJWEOH - {0xCB80, 0xCB80, prLV}, // Lo HANGUL SYLLABLE JJWE - {0xCB81, 0xCB9B, prLVT}, // Lo [27] HANGUL SYLLABLE JJWEG..HANGUL SYLLABLE JJWEH - {0xCB9C, 0xCB9C, prLV}, // Lo HANGUL SYLLABLE JJWI - {0xCB9D, 0xCBB7, prLVT}, // Lo [27] HANGUL SYLLABLE JJWIG..HANGUL SYLLABLE JJWIH - {0xCBB8, 0xCBB8, prLV}, // Lo HANGUL SYLLABLE JJYU - {0xCBB9, 0xCBD3, prLVT}, // Lo [27] HANGUL SYLLABLE JJYUG..HANGUL SYLLABLE JJYUH - {0xCBD4, 0xCBD4, prLV}, // Lo HANGUL SYLLABLE JJEU - {0xCBD5, 0xCBEF, prLVT}, // Lo [27] HANGUL SYLLABLE JJEUG..HANGUL SYLLABLE JJEUH - {0xCBF0, 0xCBF0, prLV}, // Lo HANGUL SYLLABLE JJYI - {0xCBF1, 0xCC0B, prLVT}, // Lo [27] HANGUL SYLLABLE JJYIG..HANGUL SYLLABLE JJYIH - {0xCC0C, 0xCC0C, prLV}, // Lo HANGUL SYLLABLE JJI - {0xCC0D, 0xCC27, prLVT}, // Lo [27] HANGUL SYLLABLE JJIG..HANGUL SYLLABLE JJIH - {0xCC28, 0xCC28, prLV}, // Lo HANGUL SYLLABLE CA - {0xCC29, 0xCC43, prLVT}, // Lo [27] HANGUL SYLLABLE CAG..HANGUL SYLLABLE CAH - {0xCC44, 0xCC44, prLV}, // Lo HANGUL SYLLABLE CAE - {0xCC45, 0xCC5F, prLVT}, // Lo [27] HANGUL SYLLABLE CAEG..HANGUL SYLLABLE CAEH - {0xCC60, 0xCC60, prLV}, // Lo HANGUL SYLLABLE CYA - {0xCC61, 0xCC7B, prLVT}, // Lo [27] HANGUL SYLLABLE CYAG..HANGUL SYLLABLE CYAH - {0xCC7C, 0xCC7C, prLV}, // Lo HANGUL SYLLABLE CYAE - {0xCC7D, 0xCC97, prLVT}, // Lo [27] HANGUL SYLLABLE CYAEG..HANGUL SYLLABLE CYAEH - {0xCC98, 0xCC98, prLV}, // Lo HANGUL SYLLABLE CEO - {0xCC99, 0xCCB3, prLVT}, // Lo [27] HANGUL SYLLABLE CEOG..HANGUL SYLLABLE CEOH - {0xCCB4, 0xCCB4, prLV}, // Lo HANGUL SYLLABLE CE - {0xCCB5, 0xCCCF, prLVT}, // Lo [27] HANGUL SYLLABLE CEG..HANGUL SYLLABLE CEH - {0xCCD0, 0xCCD0, prLV}, // Lo HANGUL SYLLABLE CYEO - {0xCCD1, 0xCCEB, prLVT}, // Lo [27] HANGUL SYLLABLE CYEOG..HANGUL SYLLABLE CYEOH - {0xCCEC, 0xCCEC, prLV}, // Lo HANGUL SYLLABLE CYE - {0xCCED, 0xCD07, prLVT}, // Lo [27] HANGUL SYLLABLE CYEG..HANGUL SYLLABLE CYEH - {0xCD08, 0xCD08, prLV}, // Lo HANGUL SYLLABLE CO - {0xCD09, 0xCD23, prLVT}, // Lo [27] HANGUL SYLLABLE COG..HANGUL SYLLABLE COH - {0xCD24, 0xCD24, prLV}, // Lo HANGUL SYLLABLE CWA - {0xCD25, 0xCD3F, prLVT}, // Lo [27] HANGUL SYLLABLE CWAG..HANGUL SYLLABLE CWAH - {0xCD40, 0xCD40, prLV}, // Lo HANGUL SYLLABLE CWAE - {0xCD41, 0xCD5B, prLVT}, // Lo [27] HANGUL SYLLABLE CWAEG..HANGUL SYLLABLE CWAEH - {0xCD5C, 0xCD5C, prLV}, // Lo HANGUL SYLLABLE COE - {0xCD5D, 0xCD77, prLVT}, // Lo [27] HANGUL SYLLABLE COEG..HANGUL SYLLABLE COEH - {0xCD78, 0xCD78, prLV}, // Lo HANGUL SYLLABLE CYO - {0xCD79, 0xCD93, prLVT}, // Lo [27] HANGUL SYLLABLE CYOG..HANGUL SYLLABLE CYOH - {0xCD94, 0xCD94, prLV}, // Lo HANGUL SYLLABLE CU - {0xCD95, 0xCDAF, prLVT}, // Lo [27] HANGUL SYLLABLE CUG..HANGUL SYLLABLE CUH - {0xCDB0, 0xCDB0, prLV}, // Lo HANGUL SYLLABLE CWEO - {0xCDB1, 0xCDCB, prLVT}, // Lo [27] HANGUL SYLLABLE CWEOG..HANGUL SYLLABLE CWEOH - {0xCDCC, 0xCDCC, prLV}, // Lo HANGUL SYLLABLE CWE - {0xCDCD, 0xCDE7, prLVT}, // Lo [27] HANGUL SYLLABLE CWEG..HANGUL SYLLABLE CWEH - {0xCDE8, 0xCDE8, prLV}, // Lo HANGUL SYLLABLE CWI - {0xCDE9, 0xCE03, prLVT}, // Lo [27] HANGUL SYLLABLE CWIG..HANGUL SYLLABLE CWIH - {0xCE04, 0xCE04, prLV}, // Lo HANGUL SYLLABLE CYU - {0xCE05, 0xCE1F, prLVT}, // Lo [27] HANGUL SYLLABLE CYUG..HANGUL SYLLABLE CYUH - {0xCE20, 0xCE20, prLV}, // Lo HANGUL SYLLABLE CEU - {0xCE21, 0xCE3B, prLVT}, // Lo [27] HANGUL SYLLABLE CEUG..HANGUL SYLLABLE CEUH - {0xCE3C, 0xCE3C, prLV}, // Lo HANGUL SYLLABLE CYI - {0xCE3D, 0xCE57, prLVT}, // Lo [27] HANGUL SYLLABLE CYIG..HANGUL SYLLABLE CYIH - {0xCE58, 0xCE58, prLV}, // Lo HANGUL SYLLABLE CI - {0xCE59, 0xCE73, prLVT}, // Lo [27] HANGUL SYLLABLE CIG..HANGUL SYLLABLE CIH - {0xCE74, 0xCE74, prLV}, // Lo HANGUL SYLLABLE KA - {0xCE75, 0xCE8F, prLVT}, // Lo [27] HANGUL SYLLABLE KAG..HANGUL SYLLABLE KAH - {0xCE90, 0xCE90, prLV}, // Lo HANGUL SYLLABLE KAE - {0xCE91, 0xCEAB, prLVT}, // Lo [27] HANGUL SYLLABLE KAEG..HANGUL SYLLABLE KAEH - {0xCEAC, 0xCEAC, prLV}, // Lo HANGUL SYLLABLE KYA - {0xCEAD, 0xCEC7, prLVT}, // Lo [27] HANGUL SYLLABLE KYAG..HANGUL SYLLABLE KYAH - {0xCEC8, 0xCEC8, prLV}, // Lo HANGUL SYLLABLE KYAE - {0xCEC9, 0xCEE3, prLVT}, // Lo [27] HANGUL SYLLABLE KYAEG..HANGUL SYLLABLE KYAEH - {0xCEE4, 0xCEE4, prLV}, // Lo HANGUL SYLLABLE KEO - {0xCEE5, 0xCEFF, prLVT}, // Lo [27] HANGUL SYLLABLE KEOG..HANGUL SYLLABLE KEOH - {0xCF00, 0xCF00, prLV}, // Lo HANGUL SYLLABLE KE - {0xCF01, 0xCF1B, prLVT}, // Lo [27] HANGUL SYLLABLE KEG..HANGUL SYLLABLE KEH - {0xCF1C, 0xCF1C, prLV}, // Lo HANGUL SYLLABLE KYEO - {0xCF1D, 0xCF37, prLVT}, // Lo [27] HANGUL SYLLABLE KYEOG..HANGUL SYLLABLE KYEOH - {0xCF38, 0xCF38, prLV}, // Lo HANGUL SYLLABLE KYE - {0xCF39, 0xCF53, prLVT}, // Lo [27] HANGUL SYLLABLE KYEG..HANGUL SYLLABLE KYEH - {0xCF54, 0xCF54, prLV}, // Lo HANGUL SYLLABLE KO - {0xCF55, 0xCF6F, prLVT}, // Lo [27] HANGUL SYLLABLE KOG..HANGUL SYLLABLE KOH - {0xCF70, 0xCF70, prLV}, // Lo HANGUL SYLLABLE KWA - {0xCF71, 0xCF8B, prLVT}, // Lo [27] HANGUL SYLLABLE KWAG..HANGUL SYLLABLE KWAH - {0xCF8C, 0xCF8C, prLV}, // Lo HANGUL SYLLABLE KWAE - {0xCF8D, 0xCFA7, prLVT}, // Lo [27] HANGUL SYLLABLE KWAEG..HANGUL SYLLABLE KWAEH - {0xCFA8, 0xCFA8, prLV}, // Lo HANGUL SYLLABLE KOE - {0xCFA9, 0xCFC3, prLVT}, // Lo [27] HANGUL SYLLABLE KOEG..HANGUL SYLLABLE KOEH - {0xCFC4, 0xCFC4, prLV}, // Lo HANGUL SYLLABLE KYO - {0xCFC5, 0xCFDF, prLVT}, // Lo [27] HANGUL SYLLABLE KYOG..HANGUL SYLLABLE KYOH - {0xCFE0, 0xCFE0, prLV}, // Lo HANGUL SYLLABLE KU - {0xCFE1, 0xCFFB, prLVT}, // Lo [27] HANGUL SYLLABLE KUG..HANGUL SYLLABLE KUH - {0xCFFC, 0xCFFC, prLV}, // Lo HANGUL SYLLABLE KWEO - {0xCFFD, 0xD017, prLVT}, // Lo [27] HANGUL SYLLABLE KWEOG..HANGUL SYLLABLE KWEOH - {0xD018, 0xD018, prLV}, // Lo HANGUL SYLLABLE KWE - {0xD019, 0xD033, prLVT}, // Lo [27] HANGUL SYLLABLE KWEG..HANGUL SYLLABLE KWEH - {0xD034, 0xD034, prLV}, // Lo HANGUL SYLLABLE KWI - {0xD035, 0xD04F, prLVT}, // Lo [27] HANGUL SYLLABLE KWIG..HANGUL SYLLABLE KWIH - {0xD050, 0xD050, prLV}, // Lo HANGUL SYLLABLE KYU - {0xD051, 0xD06B, prLVT}, // Lo [27] HANGUL SYLLABLE KYUG..HANGUL SYLLABLE KYUH - {0xD06C, 0xD06C, prLV}, // Lo HANGUL SYLLABLE KEU - {0xD06D, 0xD087, prLVT}, // Lo [27] HANGUL SYLLABLE KEUG..HANGUL SYLLABLE KEUH - {0xD088, 0xD088, prLV}, // Lo HANGUL SYLLABLE KYI - {0xD089, 0xD0A3, prLVT}, // Lo [27] HANGUL SYLLABLE KYIG..HANGUL SYLLABLE KYIH - {0xD0A4, 0xD0A4, prLV}, // Lo HANGUL SYLLABLE KI - {0xD0A5, 0xD0BF, prLVT}, // Lo [27] HANGUL SYLLABLE KIG..HANGUL SYLLABLE KIH - {0xD0C0, 0xD0C0, prLV}, // Lo HANGUL SYLLABLE TA - {0xD0C1, 0xD0DB, prLVT}, // Lo [27] HANGUL SYLLABLE TAG..HANGUL SYLLABLE TAH - {0xD0DC, 0xD0DC, prLV}, // Lo HANGUL SYLLABLE TAE - {0xD0DD, 0xD0F7, prLVT}, // Lo [27] HANGUL SYLLABLE TAEG..HANGUL SYLLABLE TAEH - {0xD0F8, 0xD0F8, prLV}, // Lo HANGUL SYLLABLE TYA - {0xD0F9, 0xD113, prLVT}, // Lo [27] HANGUL SYLLABLE TYAG..HANGUL SYLLABLE TYAH - {0xD114, 0xD114, prLV}, // Lo HANGUL SYLLABLE TYAE - {0xD115, 0xD12F, prLVT}, // Lo [27] HANGUL SYLLABLE TYAEG..HANGUL SYLLABLE TYAEH - {0xD130, 0xD130, prLV}, // Lo HANGUL SYLLABLE TEO - {0xD131, 0xD14B, prLVT}, // Lo [27] HANGUL SYLLABLE TEOG..HANGUL SYLLABLE TEOH - {0xD14C, 0xD14C, prLV}, // Lo HANGUL SYLLABLE TE - {0xD14D, 0xD167, prLVT}, // Lo [27] HANGUL SYLLABLE TEG..HANGUL SYLLABLE TEH - {0xD168, 0xD168, prLV}, // Lo HANGUL SYLLABLE TYEO - {0xD169, 0xD183, prLVT}, // Lo [27] HANGUL SYLLABLE TYEOG..HANGUL SYLLABLE TYEOH - {0xD184, 0xD184, prLV}, // Lo HANGUL SYLLABLE TYE - {0xD185, 0xD19F, prLVT}, // Lo [27] HANGUL SYLLABLE TYEG..HANGUL SYLLABLE TYEH - {0xD1A0, 0xD1A0, prLV}, // Lo HANGUL SYLLABLE TO - {0xD1A1, 0xD1BB, prLVT}, // Lo [27] HANGUL SYLLABLE TOG..HANGUL SYLLABLE TOH - {0xD1BC, 0xD1BC, prLV}, // Lo HANGUL SYLLABLE TWA - {0xD1BD, 0xD1D7, prLVT}, // Lo [27] HANGUL SYLLABLE TWAG..HANGUL SYLLABLE TWAH - {0xD1D8, 0xD1D8, prLV}, // Lo HANGUL SYLLABLE TWAE - {0xD1D9, 0xD1F3, prLVT}, // Lo [27] HANGUL SYLLABLE TWAEG..HANGUL SYLLABLE TWAEH - {0xD1F4, 0xD1F4, prLV}, // Lo HANGUL SYLLABLE TOE - {0xD1F5, 0xD20F, prLVT}, // Lo [27] HANGUL SYLLABLE TOEG..HANGUL SYLLABLE TOEH - {0xD210, 0xD210, prLV}, // Lo HANGUL SYLLABLE TYO - {0xD211, 0xD22B, prLVT}, // Lo [27] HANGUL SYLLABLE TYOG..HANGUL SYLLABLE TYOH - {0xD22C, 0xD22C, prLV}, // Lo HANGUL SYLLABLE TU - {0xD22D, 0xD247, prLVT}, // Lo [27] HANGUL SYLLABLE TUG..HANGUL SYLLABLE TUH - {0xD248, 0xD248, prLV}, // Lo HANGUL SYLLABLE TWEO - {0xD249, 0xD263, prLVT}, // Lo [27] HANGUL SYLLABLE TWEOG..HANGUL SYLLABLE TWEOH - {0xD264, 0xD264, prLV}, // Lo HANGUL SYLLABLE TWE - {0xD265, 0xD27F, prLVT}, // Lo [27] HANGUL SYLLABLE TWEG..HANGUL SYLLABLE TWEH - {0xD280, 0xD280, prLV}, // Lo HANGUL SYLLABLE TWI - {0xD281, 0xD29B, prLVT}, // Lo [27] HANGUL SYLLABLE TWIG..HANGUL SYLLABLE TWIH - {0xD29C, 0xD29C, prLV}, // Lo HANGUL SYLLABLE TYU - {0xD29D, 0xD2B7, prLVT}, // Lo [27] HANGUL SYLLABLE TYUG..HANGUL SYLLABLE TYUH - {0xD2B8, 0xD2B8, prLV}, // Lo HANGUL SYLLABLE TEU - {0xD2B9, 0xD2D3, prLVT}, // Lo [27] HANGUL SYLLABLE TEUG..HANGUL SYLLABLE TEUH - {0xD2D4, 0xD2D4, prLV}, // Lo HANGUL SYLLABLE TYI - {0xD2D5, 0xD2EF, prLVT}, // Lo [27] HANGUL SYLLABLE TYIG..HANGUL SYLLABLE TYIH - {0xD2F0, 0xD2F0, prLV}, // Lo HANGUL SYLLABLE TI - {0xD2F1, 0xD30B, prLVT}, // Lo [27] HANGUL SYLLABLE TIG..HANGUL SYLLABLE TIH - {0xD30C, 0xD30C, prLV}, // Lo HANGUL SYLLABLE PA - {0xD30D, 0xD327, prLVT}, // Lo [27] HANGUL SYLLABLE PAG..HANGUL SYLLABLE PAH - {0xD328, 0xD328, prLV}, // Lo HANGUL SYLLABLE PAE - {0xD329, 0xD343, prLVT}, // Lo [27] HANGUL SYLLABLE PAEG..HANGUL SYLLABLE PAEH - {0xD344, 0xD344, prLV}, // Lo HANGUL SYLLABLE PYA - {0xD345, 0xD35F, prLVT}, // Lo [27] HANGUL SYLLABLE PYAG..HANGUL SYLLABLE PYAH - {0xD360, 0xD360, prLV}, // Lo HANGUL SYLLABLE PYAE - {0xD361, 0xD37B, prLVT}, // Lo [27] HANGUL SYLLABLE PYAEG..HANGUL SYLLABLE PYAEH - {0xD37C, 0xD37C, prLV}, // Lo HANGUL SYLLABLE PEO - {0xD37D, 0xD397, prLVT}, // Lo [27] HANGUL SYLLABLE PEOG..HANGUL SYLLABLE PEOH - {0xD398, 0xD398, prLV}, // Lo HANGUL SYLLABLE PE - {0xD399, 0xD3B3, prLVT}, // Lo [27] HANGUL SYLLABLE PEG..HANGUL SYLLABLE PEH - {0xD3B4, 0xD3B4, prLV}, // Lo HANGUL SYLLABLE PYEO - {0xD3B5, 0xD3CF, prLVT}, // Lo [27] HANGUL SYLLABLE PYEOG..HANGUL SYLLABLE PYEOH - {0xD3D0, 0xD3D0, prLV}, // Lo HANGUL SYLLABLE PYE - {0xD3D1, 0xD3EB, prLVT}, // Lo [27] HANGUL SYLLABLE PYEG..HANGUL SYLLABLE PYEH - {0xD3EC, 0xD3EC, prLV}, // Lo HANGUL SYLLABLE PO - {0xD3ED, 0xD407, prLVT}, // Lo [27] HANGUL SYLLABLE POG..HANGUL SYLLABLE POH - {0xD408, 0xD408, prLV}, // Lo HANGUL SYLLABLE PWA - {0xD409, 0xD423, prLVT}, // Lo [27] HANGUL SYLLABLE PWAG..HANGUL SYLLABLE PWAH - {0xD424, 0xD424, prLV}, // Lo HANGUL SYLLABLE PWAE - {0xD425, 0xD43F, prLVT}, // Lo [27] HANGUL SYLLABLE PWAEG..HANGUL SYLLABLE PWAEH - {0xD440, 0xD440, prLV}, // Lo HANGUL SYLLABLE POE - {0xD441, 0xD45B, prLVT}, // Lo [27] HANGUL SYLLABLE POEG..HANGUL SYLLABLE POEH - {0xD45C, 0xD45C, prLV}, // Lo HANGUL SYLLABLE PYO - {0xD45D, 0xD477, prLVT}, // Lo [27] HANGUL SYLLABLE PYOG..HANGUL SYLLABLE PYOH - {0xD478, 0xD478, prLV}, // Lo HANGUL SYLLABLE PU - {0xD479, 0xD493, prLVT}, // Lo [27] HANGUL SYLLABLE PUG..HANGUL SYLLABLE PUH - {0xD494, 0xD494, prLV}, // Lo HANGUL SYLLABLE PWEO - {0xD495, 0xD4AF, prLVT}, // Lo [27] HANGUL SYLLABLE PWEOG..HANGUL SYLLABLE PWEOH - {0xD4B0, 0xD4B0, prLV}, // Lo HANGUL SYLLABLE PWE - {0xD4B1, 0xD4CB, prLVT}, // Lo [27] HANGUL SYLLABLE PWEG..HANGUL SYLLABLE PWEH - {0xD4CC, 0xD4CC, prLV}, // Lo HANGUL SYLLABLE PWI - {0xD4CD, 0xD4E7, prLVT}, // Lo [27] HANGUL SYLLABLE PWIG..HANGUL SYLLABLE PWIH - {0xD4E8, 0xD4E8, prLV}, // Lo HANGUL SYLLABLE PYU - {0xD4E9, 0xD503, prLVT}, // Lo [27] HANGUL SYLLABLE PYUG..HANGUL SYLLABLE PYUH - {0xD504, 0xD504, prLV}, // Lo HANGUL SYLLABLE PEU - {0xD505, 0xD51F, prLVT}, // Lo [27] HANGUL SYLLABLE PEUG..HANGUL SYLLABLE PEUH - {0xD520, 0xD520, prLV}, // Lo HANGUL SYLLABLE PYI - {0xD521, 0xD53B, prLVT}, // Lo [27] HANGUL SYLLABLE PYIG..HANGUL SYLLABLE PYIH - {0xD53C, 0xD53C, prLV}, // Lo HANGUL SYLLABLE PI - {0xD53D, 0xD557, prLVT}, // Lo [27] HANGUL SYLLABLE PIG..HANGUL SYLLABLE PIH - {0xD558, 0xD558, prLV}, // Lo HANGUL SYLLABLE HA - {0xD559, 0xD573, prLVT}, // Lo [27] HANGUL SYLLABLE HAG..HANGUL SYLLABLE HAH - {0xD574, 0xD574, prLV}, // Lo HANGUL SYLLABLE HAE - {0xD575, 0xD58F, prLVT}, // Lo [27] HANGUL SYLLABLE HAEG..HANGUL SYLLABLE HAEH - {0xD590, 0xD590, prLV}, // Lo HANGUL SYLLABLE HYA - {0xD591, 0xD5AB, prLVT}, // Lo [27] HANGUL SYLLABLE HYAG..HANGUL SYLLABLE HYAH - {0xD5AC, 0xD5AC, prLV}, // Lo HANGUL SYLLABLE HYAE - {0xD5AD, 0xD5C7, prLVT}, // Lo [27] HANGUL SYLLABLE HYAEG..HANGUL SYLLABLE HYAEH - {0xD5C8, 0xD5C8, prLV}, // Lo HANGUL SYLLABLE HEO - {0xD5C9, 0xD5E3, prLVT}, // Lo [27] HANGUL SYLLABLE HEOG..HANGUL SYLLABLE HEOH - {0xD5E4, 0xD5E4, prLV}, // Lo HANGUL SYLLABLE HE - {0xD5E5, 0xD5FF, prLVT}, // Lo [27] HANGUL SYLLABLE HEG..HANGUL SYLLABLE HEH - {0xD600, 0xD600, prLV}, // Lo HANGUL SYLLABLE HYEO - {0xD601, 0xD61B, prLVT}, // Lo [27] HANGUL SYLLABLE HYEOG..HANGUL SYLLABLE HYEOH - {0xD61C, 0xD61C, prLV}, // Lo HANGUL SYLLABLE HYE - {0xD61D, 0xD637, prLVT}, // Lo [27] HANGUL SYLLABLE HYEG..HANGUL SYLLABLE HYEH - {0xD638, 0xD638, prLV}, // Lo HANGUL SYLLABLE HO - {0xD639, 0xD653, prLVT}, // Lo [27] HANGUL SYLLABLE HOG..HANGUL SYLLABLE HOH - {0xD654, 0xD654, prLV}, // Lo HANGUL SYLLABLE HWA - {0xD655, 0xD66F, prLVT}, // Lo [27] HANGUL SYLLABLE HWAG..HANGUL SYLLABLE HWAH - {0xD670, 0xD670, prLV}, // Lo HANGUL SYLLABLE HWAE - {0xD671, 0xD68B, prLVT}, // Lo [27] HANGUL SYLLABLE HWAEG..HANGUL SYLLABLE HWAEH - {0xD68C, 0xD68C, prLV}, // Lo HANGUL SYLLABLE HOE - {0xD68D, 0xD6A7, prLVT}, // Lo [27] HANGUL SYLLABLE HOEG..HANGUL SYLLABLE HOEH - {0xD6A8, 0xD6A8, prLV}, // Lo HANGUL SYLLABLE HYO - {0xD6A9, 0xD6C3, prLVT}, // Lo [27] HANGUL SYLLABLE HYOG..HANGUL SYLLABLE HYOH - {0xD6C4, 0xD6C4, prLV}, // Lo HANGUL SYLLABLE HU - {0xD6C5, 0xD6DF, prLVT}, // Lo [27] HANGUL SYLLABLE HUG..HANGUL SYLLABLE HUH - {0xD6E0, 0xD6E0, prLV}, // Lo HANGUL SYLLABLE HWEO - {0xD6E1, 0xD6FB, prLVT}, // Lo [27] HANGUL SYLLABLE HWEOG..HANGUL SYLLABLE HWEOH - {0xD6FC, 0xD6FC, prLV}, // Lo HANGUL SYLLABLE HWE - {0xD6FD, 0xD717, prLVT}, // Lo [27] HANGUL SYLLABLE HWEG..HANGUL SYLLABLE HWEH - {0xD718, 0xD718, prLV}, // Lo HANGUL SYLLABLE HWI - {0xD719, 0xD733, prLVT}, // Lo [27] HANGUL SYLLABLE HWIG..HANGUL SYLLABLE HWIH - {0xD734, 0xD734, prLV}, // Lo HANGUL SYLLABLE HYU - {0xD735, 0xD74F, prLVT}, // Lo [27] HANGUL SYLLABLE HYUG..HANGUL SYLLABLE HYUH - {0xD750, 0xD750, prLV}, // Lo HANGUL SYLLABLE HEU - {0xD751, 0xD76B, prLVT}, // Lo [27] HANGUL SYLLABLE HEUG..HANGUL SYLLABLE HEUH - {0xD76C, 0xD76C, prLV}, // Lo HANGUL SYLLABLE HYI - {0xD76D, 0xD787, prLVT}, // Lo [27] HANGUL SYLLABLE HYIG..HANGUL SYLLABLE HYIH - {0xD788, 0xD788, prLV}, // Lo HANGUL SYLLABLE HI - {0xD789, 0xD7A3, prLVT}, // Lo [27] HANGUL SYLLABLE HIG..HANGUL SYLLABLE HIH - {0xD7B0, 0xD7C6, prV}, // Lo [23] HANGUL JUNGSEONG O-YEO..HANGUL JUNGSEONG ARAEA-E - {0xD7CB, 0xD7FB, prT}, // Lo [49] HANGUL JONGSEONG NIEUN-RIEUL..HANGUL JONGSEONG PHIEUPH-THIEUTH - {0xFB1E, 0xFB1E, prExtend}, // Mn HEBREW POINT JUDEO-SPANISH VARIKA - {0xFE00, 0xFE0F, prExtend}, // Mn [16] VARIATION SELECTOR-1..VARIATION SELECTOR-16 - {0xFE20, 0xFE2F, prExtend}, // Mn [16] COMBINING LIGATURE LEFT HALF..COMBINING CYRILLIC TITLO RIGHT HALF - {0xFEFF, 0xFEFF, prControl}, // Cf ZERO WIDTH NO-BREAK SPACE - {0xFF9E, 0xFF9F, prExtend}, // Lm [2] HALFWIDTH KATAKANA VOICED SOUND MARK..HALFWIDTH KATAKANA SEMI-VOICED SOUND MARK - {0xFFF0, 0xFFF8, prControl}, // Cn [9] .. - {0xFFF9, 0xFFFB, prControl}, // Cf [3] INTERLINEAR ANNOTATION ANCHOR..INTERLINEAR ANNOTATION TERMINATOR - {0x101FD, 0x101FD, prExtend}, // Mn PHAISTOS DISC SIGN COMBINING OBLIQUE STROKE - {0x102E0, 0x102E0, prExtend}, // Mn COPTIC EPACT THOUSANDS MARK - {0x10376, 0x1037A, prExtend}, // Mn [5] COMBINING OLD PERMIC LETTER AN..COMBINING OLD PERMIC LETTER SII - {0x10A01, 0x10A03, prExtend}, // Mn [3] KHAROSHTHI VOWEL SIGN I..KHAROSHTHI VOWEL SIGN VOCALIC R - {0x10A05, 0x10A06, prExtend}, // Mn [2] KHAROSHTHI VOWEL SIGN E..KHAROSHTHI VOWEL SIGN O - {0x10A0C, 0x10A0F, prExtend}, // Mn [4] KHAROSHTHI VOWEL LENGTH MARK..KHAROSHTHI SIGN VISARGA - {0x10A38, 0x10A3A, prExtend}, // Mn [3] KHAROSHTHI SIGN BAR ABOVE..KHAROSHTHI SIGN DOT BELOW - {0x10A3F, 0x10A3F, prExtend}, // Mn KHAROSHTHI VIRAMA - {0x10AE5, 0x10AE6, prExtend}, // Mn [2] MANICHAEAN ABBREVIATION MARK ABOVE..MANICHAEAN ABBREVIATION MARK BELOW - {0x10D24, 0x10D27, prExtend}, // Mn [4] HANIFI ROHINGYA SIGN HARBAHAY..HANIFI ROHINGYA SIGN TASSI - {0x10F46, 0x10F50, prExtend}, // Mn [11] SOGDIAN COMBINING DOT BELOW..SOGDIAN COMBINING STROKE BELOW - {0x11000, 0x11000, prSpacingMark}, // Mc BRAHMI SIGN CANDRABINDU - {0x11001, 0x11001, prExtend}, // Mn BRAHMI SIGN ANUSVARA - {0x11002, 0x11002, prSpacingMark}, // Mc BRAHMI SIGN VISARGA - {0x11038, 0x11046, prExtend}, // Mn [15] BRAHMI VOWEL SIGN AA..BRAHMI VIRAMA - {0x1107F, 0x11081, prExtend}, // Mn [3] BRAHMI NUMBER JOINER..KAITHI SIGN ANUSVARA - {0x11082, 0x11082, prSpacingMark}, // Mc KAITHI SIGN VISARGA - {0x110B0, 0x110B2, prSpacingMark}, // Mc [3] KAITHI VOWEL SIGN AA..KAITHI VOWEL SIGN II - {0x110B3, 0x110B6, prExtend}, // Mn [4] KAITHI VOWEL SIGN U..KAITHI VOWEL SIGN AI - {0x110B7, 0x110B8, prSpacingMark}, // Mc [2] KAITHI VOWEL SIGN O..KAITHI VOWEL SIGN AU - {0x110B9, 0x110BA, prExtend}, // Mn [2] KAITHI SIGN VIRAMA..KAITHI SIGN NUKTA - {0x110BD, 0x110BD, prPreprend}, // Cf KAITHI NUMBER SIGN - {0x110CD, 0x110CD, prPreprend}, // Cf KAITHI NUMBER SIGN ABOVE - {0x11100, 0x11102, prExtend}, // Mn [3] CHAKMA SIGN CANDRABINDU..CHAKMA SIGN VISARGA - {0x11127, 0x1112B, prExtend}, // Mn [5] CHAKMA VOWEL SIGN A..CHAKMA VOWEL SIGN UU - {0x1112C, 0x1112C, prSpacingMark}, // Mc CHAKMA VOWEL SIGN E - {0x1112D, 0x11134, prExtend}, // Mn [8] CHAKMA VOWEL SIGN AI..CHAKMA MAAYYAA - {0x11145, 0x11146, prSpacingMark}, // Mc [2] CHAKMA VOWEL SIGN AA..CHAKMA VOWEL SIGN EI - {0x11173, 0x11173, prExtend}, // Mn MAHAJANI SIGN NUKTA - {0x11180, 0x11181, prExtend}, // Mn [2] SHARADA SIGN CANDRABINDU..SHARADA SIGN ANUSVARA - {0x11182, 0x11182, prSpacingMark}, // Mc SHARADA SIGN VISARGA - {0x111B3, 0x111B5, prSpacingMark}, // Mc [3] SHARADA VOWEL SIGN AA..SHARADA VOWEL SIGN II - {0x111B6, 0x111BE, prExtend}, // Mn [9] SHARADA VOWEL SIGN U..SHARADA VOWEL SIGN O - {0x111BF, 0x111C0, prSpacingMark}, // Mc [2] SHARADA VOWEL SIGN AU..SHARADA SIGN VIRAMA - {0x111C2, 0x111C3, prPreprend}, // Lo [2] SHARADA SIGN JIHVAMULIYA..SHARADA SIGN UPADHMANIYA - {0x111C9, 0x111CC, prExtend}, // Mn [4] SHARADA SANDHI MARK..SHARADA EXTRA SHORT VOWEL MARK - {0x1122C, 0x1122E, prSpacingMark}, // Mc [3] KHOJKI VOWEL SIGN AA..KHOJKI VOWEL SIGN II - {0x1122F, 0x11231, prExtend}, // Mn [3] KHOJKI VOWEL SIGN U..KHOJKI VOWEL SIGN AI - {0x11232, 0x11233, prSpacingMark}, // Mc [2] KHOJKI VOWEL SIGN O..KHOJKI VOWEL SIGN AU - {0x11234, 0x11234, prExtend}, // Mn KHOJKI SIGN ANUSVARA - {0x11235, 0x11235, prSpacingMark}, // Mc KHOJKI SIGN VIRAMA - {0x11236, 0x11237, prExtend}, // Mn [2] KHOJKI SIGN NUKTA..KHOJKI SIGN SHADDA - {0x1123E, 0x1123E, prExtend}, // Mn KHOJKI SIGN SUKUN - {0x112DF, 0x112DF, prExtend}, // Mn KHUDAWADI SIGN ANUSVARA - {0x112E0, 0x112E2, prSpacingMark}, // Mc [3] KHUDAWADI VOWEL SIGN AA..KHUDAWADI VOWEL SIGN II - {0x112E3, 0x112EA, prExtend}, // Mn [8] KHUDAWADI VOWEL SIGN U..KHUDAWADI SIGN VIRAMA - {0x11300, 0x11301, prExtend}, // Mn [2] GRANTHA SIGN COMBINING ANUSVARA ABOVE..GRANTHA SIGN CANDRABINDU - {0x11302, 0x11303, prSpacingMark}, // Mc [2] GRANTHA SIGN ANUSVARA..GRANTHA SIGN VISARGA - {0x1133B, 0x1133C, prExtend}, // Mn [2] COMBINING BINDU BELOW..GRANTHA SIGN NUKTA - {0x1133E, 0x1133E, prExtend}, // Mc GRANTHA VOWEL SIGN AA - {0x1133F, 0x1133F, prSpacingMark}, // Mc GRANTHA VOWEL SIGN I - {0x11340, 0x11340, prExtend}, // Mn GRANTHA VOWEL SIGN II - {0x11341, 0x11344, prSpacingMark}, // Mc [4] GRANTHA VOWEL SIGN U..GRANTHA VOWEL SIGN VOCALIC RR - {0x11347, 0x11348, prSpacingMark}, // Mc [2] GRANTHA VOWEL SIGN EE..GRANTHA VOWEL SIGN AI - {0x1134B, 0x1134D, prSpacingMark}, // Mc [3] GRANTHA VOWEL SIGN OO..GRANTHA SIGN VIRAMA - {0x11357, 0x11357, prExtend}, // Mc GRANTHA AU LENGTH MARK - {0x11362, 0x11363, prSpacingMark}, // Mc [2] GRANTHA VOWEL SIGN VOCALIC L..GRANTHA VOWEL SIGN VOCALIC LL - {0x11366, 0x1136C, prExtend}, // Mn [7] COMBINING GRANTHA DIGIT ZERO..COMBINING GRANTHA DIGIT SIX - {0x11370, 0x11374, prExtend}, // Mn [5] COMBINING GRANTHA LETTER A..COMBINING GRANTHA LETTER PA - {0x11435, 0x11437, prSpacingMark}, // Mc [3] NEWA VOWEL SIGN AA..NEWA VOWEL SIGN II - {0x11438, 0x1143F, prExtend}, // Mn [8] NEWA VOWEL SIGN U..NEWA VOWEL SIGN AI - {0x11440, 0x11441, prSpacingMark}, // Mc [2] NEWA VOWEL SIGN O..NEWA VOWEL SIGN AU - {0x11442, 0x11444, prExtend}, // Mn [3] NEWA SIGN VIRAMA..NEWA SIGN ANUSVARA - {0x11445, 0x11445, prSpacingMark}, // Mc NEWA SIGN VISARGA - {0x11446, 0x11446, prExtend}, // Mn NEWA SIGN NUKTA - {0x1145E, 0x1145E, prExtend}, // Mn NEWA SANDHI MARK - {0x114B0, 0x114B0, prExtend}, // Mc TIRHUTA VOWEL SIGN AA - {0x114B1, 0x114B2, prSpacingMark}, // Mc [2] TIRHUTA VOWEL SIGN I..TIRHUTA VOWEL SIGN II - {0x114B3, 0x114B8, prExtend}, // Mn [6] TIRHUTA VOWEL SIGN U..TIRHUTA VOWEL SIGN VOCALIC LL - {0x114B9, 0x114B9, prSpacingMark}, // Mc TIRHUTA VOWEL SIGN E - {0x114BA, 0x114BA, prExtend}, // Mn TIRHUTA VOWEL SIGN SHORT E - {0x114BB, 0x114BC, prSpacingMark}, // Mc [2] TIRHUTA VOWEL SIGN AI..TIRHUTA VOWEL SIGN O - {0x114BD, 0x114BD, prExtend}, // Mc TIRHUTA VOWEL SIGN SHORT O - {0x114BE, 0x114BE, prSpacingMark}, // Mc TIRHUTA VOWEL SIGN AU - {0x114BF, 0x114C0, prExtend}, // Mn [2] TIRHUTA SIGN CANDRABINDU..TIRHUTA SIGN ANUSVARA - {0x114C1, 0x114C1, prSpacingMark}, // Mc TIRHUTA SIGN VISARGA - {0x114C2, 0x114C3, prExtend}, // Mn [2] TIRHUTA SIGN VIRAMA..TIRHUTA SIGN NUKTA - {0x115AF, 0x115AF, prExtend}, // Mc SIDDHAM VOWEL SIGN AA - {0x115B0, 0x115B1, prSpacingMark}, // Mc [2] SIDDHAM VOWEL SIGN I..SIDDHAM VOWEL SIGN II - {0x115B2, 0x115B5, prExtend}, // Mn [4] SIDDHAM VOWEL SIGN U..SIDDHAM VOWEL SIGN VOCALIC RR - {0x115B8, 0x115BB, prSpacingMark}, // Mc [4] SIDDHAM VOWEL SIGN E..SIDDHAM VOWEL SIGN AU - {0x115BC, 0x115BD, prExtend}, // Mn [2] SIDDHAM SIGN CANDRABINDU..SIDDHAM SIGN ANUSVARA - {0x115BE, 0x115BE, prSpacingMark}, // Mc SIDDHAM SIGN VISARGA - {0x115BF, 0x115C0, prExtend}, // Mn [2] SIDDHAM SIGN VIRAMA..SIDDHAM SIGN NUKTA - {0x115DC, 0x115DD, prExtend}, // Mn [2] SIDDHAM VOWEL SIGN ALTERNATE U..SIDDHAM VOWEL SIGN ALTERNATE UU - {0x11630, 0x11632, prSpacingMark}, // Mc [3] MODI VOWEL SIGN AA..MODI VOWEL SIGN II - {0x11633, 0x1163A, prExtend}, // Mn [8] MODI VOWEL SIGN U..MODI VOWEL SIGN AI - {0x1163B, 0x1163C, prSpacingMark}, // Mc [2] MODI VOWEL SIGN O..MODI VOWEL SIGN AU - {0x1163D, 0x1163D, prExtend}, // Mn MODI SIGN ANUSVARA - {0x1163E, 0x1163E, prSpacingMark}, // Mc MODI SIGN VISARGA - {0x1163F, 0x11640, prExtend}, // Mn [2] MODI SIGN VIRAMA..MODI SIGN ARDHACANDRA - {0x116AB, 0x116AB, prExtend}, // Mn TAKRI SIGN ANUSVARA - {0x116AC, 0x116AC, prSpacingMark}, // Mc TAKRI SIGN VISARGA - {0x116AD, 0x116AD, prExtend}, // Mn TAKRI VOWEL SIGN AA - {0x116AE, 0x116AF, prSpacingMark}, // Mc [2] TAKRI VOWEL SIGN I..TAKRI VOWEL SIGN II - {0x116B0, 0x116B5, prExtend}, // Mn [6] TAKRI VOWEL SIGN U..TAKRI VOWEL SIGN AU - {0x116B6, 0x116B6, prSpacingMark}, // Mc TAKRI SIGN VIRAMA - {0x116B7, 0x116B7, prExtend}, // Mn TAKRI SIGN NUKTA - {0x1171D, 0x1171F, prExtend}, // Mn [3] AHOM CONSONANT SIGN MEDIAL LA..AHOM CONSONANT SIGN MEDIAL LIGATING RA - {0x11720, 0x11721, prSpacingMark}, // Mc [2] AHOM VOWEL SIGN A..AHOM VOWEL SIGN AA - {0x11722, 0x11725, prExtend}, // Mn [4] AHOM VOWEL SIGN I..AHOM VOWEL SIGN UU - {0x11726, 0x11726, prSpacingMark}, // Mc AHOM VOWEL SIGN E - {0x11727, 0x1172B, prExtend}, // Mn [5] AHOM VOWEL SIGN AW..AHOM SIGN KILLER - {0x1182C, 0x1182E, prSpacingMark}, // Mc [3] DOGRA VOWEL SIGN AA..DOGRA VOWEL SIGN II - {0x1182F, 0x11837, prExtend}, // Mn [9] DOGRA VOWEL SIGN U..DOGRA SIGN ANUSVARA - {0x11838, 0x11838, prSpacingMark}, // Mc DOGRA SIGN VISARGA - {0x11839, 0x1183A, prExtend}, // Mn [2] DOGRA SIGN VIRAMA..DOGRA SIGN NUKTA - {0x119D1, 0x119D3, prSpacingMark}, // Mc [3] NANDINAGARI VOWEL SIGN AA..NANDINAGARI VOWEL SIGN II - {0x119D4, 0x119D7, prExtend}, // Mn [4] NANDINAGARI VOWEL SIGN U..NANDINAGARI VOWEL SIGN VOCALIC RR - {0x119DA, 0x119DB, prExtend}, // Mn [2] NANDINAGARI VOWEL SIGN E..NANDINAGARI VOWEL SIGN AI - {0x119DC, 0x119DF, prSpacingMark}, // Mc [4] NANDINAGARI VOWEL SIGN O..NANDINAGARI SIGN VISARGA - {0x119E0, 0x119E0, prExtend}, // Mn NANDINAGARI SIGN VIRAMA - {0x119E4, 0x119E4, prSpacingMark}, // Mc NANDINAGARI VOWEL SIGN PRISHTHAMATRA E - {0x11A01, 0x11A0A, prExtend}, // Mn [10] ZANABAZAR SQUARE VOWEL SIGN I..ZANABAZAR SQUARE VOWEL LENGTH MARK - {0x11A33, 0x11A38, prExtend}, // Mn [6] ZANABAZAR SQUARE FINAL CONSONANT MARK..ZANABAZAR SQUARE SIGN ANUSVARA - {0x11A39, 0x11A39, prSpacingMark}, // Mc ZANABAZAR SQUARE SIGN VISARGA - {0x11A3A, 0x11A3A, prPreprend}, // Lo ZANABAZAR SQUARE CLUSTER-INITIAL LETTER RA - {0x11A3B, 0x11A3E, prExtend}, // Mn [4] ZANABAZAR SQUARE CLUSTER-FINAL LETTER YA..ZANABAZAR SQUARE CLUSTER-FINAL LETTER VA - {0x11A47, 0x11A47, prExtend}, // Mn ZANABAZAR SQUARE SUBJOINER - {0x11A51, 0x11A56, prExtend}, // Mn [6] SOYOMBO VOWEL SIGN I..SOYOMBO VOWEL SIGN OE - {0x11A57, 0x11A58, prSpacingMark}, // Mc [2] SOYOMBO VOWEL SIGN AI..SOYOMBO VOWEL SIGN AU - {0x11A59, 0x11A5B, prExtend}, // Mn [3] SOYOMBO VOWEL SIGN VOCALIC R..SOYOMBO VOWEL LENGTH MARK - {0x11A84, 0x11A89, prPreprend}, // Lo [6] SOYOMBO SIGN JIHVAMULIYA..SOYOMBO CLUSTER-INITIAL LETTER SA - {0x11A8A, 0x11A96, prExtend}, // Mn [13] SOYOMBO FINAL CONSONANT SIGN G..SOYOMBO SIGN ANUSVARA - {0x11A97, 0x11A97, prSpacingMark}, // Mc SOYOMBO SIGN VISARGA - {0x11A98, 0x11A99, prExtend}, // Mn [2] SOYOMBO GEMINATION MARK..SOYOMBO SUBJOINER - {0x11C2F, 0x11C2F, prSpacingMark}, // Mc BHAIKSUKI VOWEL SIGN AA - {0x11C30, 0x11C36, prExtend}, // Mn [7] BHAIKSUKI VOWEL SIGN I..BHAIKSUKI VOWEL SIGN VOCALIC L - {0x11C38, 0x11C3D, prExtend}, // Mn [6] BHAIKSUKI VOWEL SIGN E..BHAIKSUKI SIGN ANUSVARA - {0x11C3E, 0x11C3E, prSpacingMark}, // Mc BHAIKSUKI SIGN VISARGA - {0x11C3F, 0x11C3F, prExtend}, // Mn BHAIKSUKI SIGN VIRAMA - {0x11C92, 0x11CA7, prExtend}, // Mn [22] MARCHEN SUBJOINED LETTER KA..MARCHEN SUBJOINED LETTER ZA - {0x11CA9, 0x11CA9, prSpacingMark}, // Mc MARCHEN SUBJOINED LETTER YA - {0x11CAA, 0x11CB0, prExtend}, // Mn [7] MARCHEN SUBJOINED LETTER RA..MARCHEN VOWEL SIGN AA - {0x11CB1, 0x11CB1, prSpacingMark}, // Mc MARCHEN VOWEL SIGN I - {0x11CB2, 0x11CB3, prExtend}, // Mn [2] MARCHEN VOWEL SIGN U..MARCHEN VOWEL SIGN E - {0x11CB4, 0x11CB4, prSpacingMark}, // Mc MARCHEN VOWEL SIGN O - {0x11CB5, 0x11CB6, prExtend}, // Mn [2] MARCHEN SIGN ANUSVARA..MARCHEN SIGN CANDRABINDU - {0x11D31, 0x11D36, prExtend}, // Mn [6] MASARAM GONDI VOWEL SIGN AA..MASARAM GONDI VOWEL SIGN VOCALIC R - {0x11D3A, 0x11D3A, prExtend}, // Mn MASARAM GONDI VOWEL SIGN E - {0x11D3C, 0x11D3D, prExtend}, // Mn [2] MASARAM GONDI VOWEL SIGN AI..MASARAM GONDI VOWEL SIGN O - {0x11D3F, 0x11D45, prExtend}, // Mn [7] MASARAM GONDI VOWEL SIGN AU..MASARAM GONDI VIRAMA - {0x11D46, 0x11D46, prPreprend}, // Lo MASARAM GONDI REPHA - {0x11D47, 0x11D47, prExtend}, // Mn MASARAM GONDI RA-KARA - {0x11D8A, 0x11D8E, prSpacingMark}, // Mc [5] GUNJALA GONDI VOWEL SIGN AA..GUNJALA GONDI VOWEL SIGN UU - {0x11D90, 0x11D91, prExtend}, // Mn [2] GUNJALA GONDI VOWEL SIGN EE..GUNJALA GONDI VOWEL SIGN AI - {0x11D93, 0x11D94, prSpacingMark}, // Mc [2] GUNJALA GONDI VOWEL SIGN OO..GUNJALA GONDI VOWEL SIGN AU - {0x11D95, 0x11D95, prExtend}, // Mn GUNJALA GONDI SIGN ANUSVARA - {0x11D96, 0x11D96, prSpacingMark}, // Mc GUNJALA GONDI SIGN VISARGA - {0x11D97, 0x11D97, prExtend}, // Mn GUNJALA GONDI VIRAMA - {0x11EF3, 0x11EF4, prExtend}, // Mn [2] MAKASAR VOWEL SIGN I..MAKASAR VOWEL SIGN U - {0x11EF5, 0x11EF6, prSpacingMark}, // Mc [2] MAKASAR VOWEL SIGN E..MAKASAR VOWEL SIGN O - {0x13430, 0x13438, prControl}, // Cf [9] EGYPTIAN HIEROGLYPH VERTICAL JOINER..EGYPTIAN HIEROGLYPH END SEGMENT - {0x16AF0, 0x16AF4, prExtend}, // Mn [5] BASSA VAH COMBINING HIGH TONE..BASSA VAH COMBINING HIGH-LOW TONE - {0x16B30, 0x16B36, prExtend}, // Mn [7] PAHAWH HMONG MARK CIM TUB..PAHAWH HMONG MARK CIM TAUM - {0x16F4F, 0x16F4F, prExtend}, // Mn MIAO SIGN CONSONANT MODIFIER BAR - {0x16F51, 0x16F87, prSpacingMark}, // Mc [55] MIAO SIGN ASPIRATION..MIAO VOWEL SIGN UI - {0x16F8F, 0x16F92, prExtend}, // Mn [4] MIAO TONE RIGHT..MIAO TONE BELOW - {0x1BC9D, 0x1BC9E, prExtend}, // Mn [2] DUPLOYAN THICK LETTER SELECTOR..DUPLOYAN DOUBLE MARK - {0x1BCA0, 0x1BCA3, prControl}, // Cf [4] SHORTHAND FORMAT LETTER OVERLAP..SHORTHAND FORMAT UP STEP - {0x1D165, 0x1D165, prExtend}, // Mc MUSICAL SYMBOL COMBINING STEM - {0x1D166, 0x1D166, prSpacingMark}, // Mc MUSICAL SYMBOL COMBINING SPRECHGESANG STEM - {0x1D167, 0x1D169, prExtend}, // Mn [3] MUSICAL SYMBOL COMBINING TREMOLO-1..MUSICAL SYMBOL COMBINING TREMOLO-3 - {0x1D16D, 0x1D16D, prSpacingMark}, // Mc MUSICAL SYMBOL COMBINING AUGMENTATION DOT - {0x1D16E, 0x1D172, prExtend}, // Mc [5] MUSICAL SYMBOL COMBINING FLAG-1..MUSICAL SYMBOL COMBINING FLAG-5 - {0x1D173, 0x1D17A, prControl}, // Cf [8] MUSICAL SYMBOL BEGIN BEAM..MUSICAL SYMBOL END PHRASE - {0x1D17B, 0x1D182, prExtend}, // Mn [8] MUSICAL SYMBOL COMBINING ACCENT..MUSICAL SYMBOL COMBINING LOURE - {0x1D185, 0x1D18B, prExtend}, // Mn [7] MUSICAL SYMBOL COMBINING DOIT..MUSICAL SYMBOL COMBINING TRIPLE TONGUE - {0x1D1AA, 0x1D1AD, prExtend}, // Mn [4] MUSICAL SYMBOL COMBINING DOWN BOW..MUSICAL SYMBOL COMBINING SNAP PIZZICATO - {0x1D242, 0x1D244, prExtend}, // Mn [3] COMBINING GREEK MUSICAL TRISEME..COMBINING GREEK MUSICAL PENTASEME - {0x1DA00, 0x1DA36, prExtend}, // Mn [55] SIGNWRITING HEAD RIM..SIGNWRITING AIR SUCKING IN - {0x1DA3B, 0x1DA6C, prExtend}, // Mn [50] SIGNWRITING MOUTH CLOSED NEUTRAL..SIGNWRITING EXCITEMENT - {0x1DA75, 0x1DA75, prExtend}, // Mn SIGNWRITING UPPER BODY TILTING FROM HIP JOINTS - {0x1DA84, 0x1DA84, prExtend}, // Mn SIGNWRITING LOCATION HEAD NECK - {0x1DA9B, 0x1DA9F, prExtend}, // Mn [5] SIGNWRITING FILL MODIFIER-2..SIGNWRITING FILL MODIFIER-6 - {0x1DAA1, 0x1DAAF, prExtend}, // Mn [15] SIGNWRITING ROTATION MODIFIER-2..SIGNWRITING ROTATION MODIFIER-16 - {0x1E000, 0x1E006, prExtend}, // Mn [7] COMBINING GLAGOLITIC LETTER AZU..COMBINING GLAGOLITIC LETTER ZHIVETE - {0x1E008, 0x1E018, prExtend}, // Mn [17] COMBINING GLAGOLITIC LETTER ZEMLJA..COMBINING GLAGOLITIC LETTER HERU - {0x1E01B, 0x1E021, prExtend}, // Mn [7] COMBINING GLAGOLITIC LETTER SHTA..COMBINING GLAGOLITIC LETTER YATI - {0x1E023, 0x1E024, prExtend}, // Mn [2] COMBINING GLAGOLITIC LETTER YU..COMBINING GLAGOLITIC LETTER SMALL YUS - {0x1E026, 0x1E02A, prExtend}, // Mn [5] COMBINING GLAGOLITIC LETTER YO..COMBINING GLAGOLITIC LETTER FITA - {0x1E130, 0x1E136, prExtend}, // Mn [7] NYIAKENG PUACHUE HMONG TONE-B..NYIAKENG PUACHUE HMONG TONE-D - {0x1E2EC, 0x1E2EF, prExtend}, // Mn [4] WANCHO TONE TUP..WANCHO TONE KOINI - {0x1E8D0, 0x1E8D6, prExtend}, // Mn [7] MENDE KIKAKUI COMBINING NUMBER TEENS..MENDE KIKAKUI COMBINING NUMBER MILLIONS - {0x1E944, 0x1E94A, prExtend}, // Mn [7] ADLAM ALIF LENGTHENER..ADLAM NUKTA - {0x1F000, 0x1F02B, prExtendedPictographic}, // 5.1 [44] (🀀..🀫) MAHJONG TILE EAST WIND..MAHJONG TILE BACK - {0x1F02C, 0x1F02F, prExtendedPictographic}, // NA [4] (🀬..🀯) .. - {0x1F030, 0x1F093, prExtendedPictographic}, // 5.1[100] (🀰..🂓) DOMINO TILE HORIZONTAL BACK..DOMINO TILE VERTICAL-06-06 - {0x1F094, 0x1F09F, prExtendedPictographic}, // NA [12] (🂔..🂟) .. - {0x1F0A0, 0x1F0AE, prExtendedPictographic}, // 6.0 [15] (🂠..🂮) PLAYING CARD BACK..PLAYING CARD KING OF SPADES - {0x1F0AF, 0x1F0B0, prExtendedPictographic}, // NA [2] (🂯..🂰) .. - {0x1F0B1, 0x1F0BE, prExtendedPictographic}, // 6.0 [14] (🂱..🂾) PLAYING CARD ACE OF HEARTS..PLAYING CARD KING OF HEARTS - {0x1F0BF, 0x1F0BF, prExtendedPictographic}, // 7.0 [1] (🂿) PLAYING CARD RED JOKER - {0x1F0C0, 0x1F0C0, prExtendedPictographic}, // NA [1] (🃀) - {0x1F0C1, 0x1F0CF, prExtendedPictographic}, // 6.0 [15] (🃁..🃏) PLAYING CARD ACE OF DIAMONDS..joker - {0x1F0D0, 0x1F0D0, prExtendedPictographic}, // NA [1] (🃐) - {0x1F0D1, 0x1F0DF, prExtendedPictographic}, // 6.0 [15] (🃑..🃟) PLAYING CARD ACE OF CLUBS..PLAYING CARD WHITE JOKER - {0x1F0E0, 0x1F0F5, prExtendedPictographic}, // 7.0 [22] (🃠..🃵) PLAYING CARD FOOL..PLAYING CARD TRUMP-21 - {0x1F0F6, 0x1F0FF, prExtendedPictographic}, // NA [10] (🃶..🃿) .. - {0x1F10D, 0x1F10F, prExtendedPictographic}, // NA [3] (🄍..🄏) .. - {0x1F12F, 0x1F12F, prExtendedPictographic}, // 11.0 [1] (🄯) COPYLEFT SYMBOL - {0x1F16C, 0x1F16C, prExtendedPictographic}, // 12.0 [1] (🅬) RAISED MR SIGN - {0x1F16D, 0x1F16F, prExtendedPictographic}, // NA [3] (🅭..🅯) .. - {0x1F170, 0x1F171, prExtendedPictographic}, // 6.0 [2] (🅰️..🅱️) A button (blood type)..B button (blood type) - {0x1F17E, 0x1F17E, prExtendedPictographic}, // 6.0 [1] (🅾️) O button (blood type) - {0x1F17F, 0x1F17F, prExtendedPictographic}, // 5.2 [1] (🅿️) P button - {0x1F18E, 0x1F18E, prExtendedPictographic}, // 6.0 [1] (🆎) AB button (blood type) - {0x1F191, 0x1F19A, prExtendedPictographic}, // 6.0 [10] (🆑..🆚) CL button..VS button - {0x1F1AD, 0x1F1E5, prExtendedPictographic}, // NA [57] (🆭..🇥) .. - {0x1F1E6, 0x1F1FF, prRegionalIndicator}, // So [26] REGIONAL INDICATOR SYMBOL LETTER A..REGIONAL INDICATOR SYMBOL LETTER Z - {0x1F201, 0x1F202, prExtendedPictographic}, // 6.0 [2] (🈁..🈂️) Japanese “here” button..Japanese “service charge” button - {0x1F203, 0x1F20F, prExtendedPictographic}, // NA [13] (🈃..🈏) .. - {0x1F21A, 0x1F21A, prExtendedPictographic}, // 5.2 [1] (🈚) Japanese “free of charge” button - {0x1F22F, 0x1F22F, prExtendedPictographic}, // 5.2 [1] (🈯) Japanese “reserved” button - {0x1F232, 0x1F23A, prExtendedPictographic}, // 6.0 [9] (🈲..🈺) Japanese “prohibited” button..Japanese “open for business” button - {0x1F23C, 0x1F23F, prExtendedPictographic}, // NA [4] (🈼..🈿) .. - {0x1F249, 0x1F24F, prExtendedPictographic}, // NA [7] (🉉..🉏) .. - {0x1F250, 0x1F251, prExtendedPictographic}, // 6.0 [2] (🉐..🉑) Japanese “bargain” button..Japanese “acceptable” button - {0x1F252, 0x1F25F, prExtendedPictographic}, // NA [14] (🉒..🉟) .. - {0x1F260, 0x1F265, prExtendedPictographic}, // 10.0 [6] (🉠..🉥) ROUNDED SYMBOL FOR FU..ROUNDED SYMBOL FOR CAI - {0x1F266, 0x1F2FF, prExtendedPictographic}, // NA[154] (🉦..🋿) .. - {0x1F300, 0x1F320, prExtendedPictographic}, // 6.0 [33] (🌀..🌠) cyclone..shooting star - {0x1F321, 0x1F32C, prExtendedPictographic}, // 7.0 [12] (🌡️..🌬️) thermometer..wind face - {0x1F32D, 0x1F32F, prExtendedPictographic}, // 8.0 [3] (🌭..🌯) hot dog..burrito - {0x1F330, 0x1F335, prExtendedPictographic}, // 6.0 [6] (🌰..🌵) chestnut..cactus - {0x1F336, 0x1F336, prExtendedPictographic}, // 7.0 [1] (🌶️) hot pepper - {0x1F337, 0x1F37C, prExtendedPictographic}, // 6.0 [70] (🌷..🍼) tulip..baby bottle - {0x1F37D, 0x1F37D, prExtendedPictographic}, // 7.0 [1] (🍽️) fork and knife with plate - {0x1F37E, 0x1F37F, prExtendedPictographic}, // 8.0 [2] (🍾..🍿) bottle with popping cork..popcorn - {0x1F380, 0x1F393, prExtendedPictographic}, // 6.0 [20] (🎀..🎓) ribbon..graduation cap - {0x1F394, 0x1F39F, prExtendedPictographic}, // 7.0 [12] (🎔..🎟️) HEART WITH TIP ON THE LEFT..admission tickets - {0x1F3A0, 0x1F3C4, prExtendedPictographic}, // 6.0 [37] (🎠..🏄) carousel horse..person surfing - {0x1F3C5, 0x1F3C5, prExtendedPictographic}, // 7.0 [1] (🏅) sports medal - {0x1F3C6, 0x1F3CA, prExtendedPictographic}, // 6.0 [5] (🏆..🏊) trophy..person swimming - {0x1F3CB, 0x1F3CE, prExtendedPictographic}, // 7.0 [4] (🏋️..🏎️) person lifting weights..racing car - {0x1F3CF, 0x1F3D3, prExtendedPictographic}, // 8.0 [5] (🏏..🏓) cricket game..ping pong - {0x1F3D4, 0x1F3DF, prExtendedPictographic}, // 7.0 [12] (🏔️..🏟️) snow-capped mountain..stadium - {0x1F3E0, 0x1F3F0, prExtendedPictographic}, // 6.0 [17] (🏠..🏰) house..castle - {0x1F3F1, 0x1F3F7, prExtendedPictographic}, // 7.0 [7] (🏱..🏷️) WHITE PENNANT..label - {0x1F3F8, 0x1F3FA, prExtendedPictographic}, // 8.0 [3] (🏸..🏺) badminton..amphora - {0x1F3FB, 0x1F3FF, prExtend}, // Sk [5] EMOJI MODIFIER FITZPATRICK TYPE-1-2..EMOJI MODIFIER FITZPATRICK TYPE-6 - {0x1F400, 0x1F43E, prExtendedPictographic}, // 6.0 [63] (🐀..🐾) rat..paw prints - {0x1F43F, 0x1F43F, prExtendedPictographic}, // 7.0 [1] (🐿️) chipmunk - {0x1F440, 0x1F440, prExtendedPictographic}, // 6.0 [1] (👀) eyes - {0x1F441, 0x1F441, prExtendedPictographic}, // 7.0 [1] (👁️) eye - {0x1F442, 0x1F4F7, prExtendedPictographic}, // 6.0[182] (👂..📷) ear..camera - {0x1F4F8, 0x1F4F8, prExtendedPictographic}, // 7.0 [1] (📸) camera with flash - {0x1F4F9, 0x1F4FC, prExtendedPictographic}, // 6.0 [4] (📹..📼) video camera..videocassette - {0x1F4FD, 0x1F4FE, prExtendedPictographic}, // 7.0 [2] (📽️..📾) film projector..PORTABLE STEREO - {0x1F4FF, 0x1F4FF, prExtendedPictographic}, // 8.0 [1] (📿) prayer beads - {0x1F500, 0x1F53D, prExtendedPictographic}, // 6.0 [62] (🔀..🔽) shuffle tracks button..downwards button - {0x1F546, 0x1F54A, prExtendedPictographic}, // 7.0 [5] (🕆..🕊️) WHITE LATIN CROSS..dove - {0x1F54B, 0x1F54F, prExtendedPictographic}, // 8.0 [5] (🕋..🕏) kaaba..BOWL OF HYGIEIA - {0x1F550, 0x1F567, prExtendedPictographic}, // 6.0 [24] (🕐..🕧) one o’clock..twelve-thirty - {0x1F568, 0x1F579, prExtendedPictographic}, // 7.0 [18] (🕨..🕹️) RIGHT SPEAKER..joystick - {0x1F57A, 0x1F57A, prExtendedPictographic}, // 9.0 [1] (🕺) man dancing - {0x1F57B, 0x1F5A3, prExtendedPictographic}, // 7.0 [41] (🕻..🖣) LEFT HAND TELEPHONE RECEIVER..BLACK DOWN POINTING BACKHAND INDEX - {0x1F5A4, 0x1F5A4, prExtendedPictographic}, // 9.0 [1] (🖤) black heart - {0x1F5A5, 0x1F5FA, prExtendedPictographic}, // 7.0 [86] (🖥️..🗺️) desktop computer..world map - {0x1F5FB, 0x1F5FF, prExtendedPictographic}, // 6.0 [5] (🗻..🗿) mount fuji..moai - {0x1F600, 0x1F600, prExtendedPictographic}, // 6.1 [1] (😀) grinning face - {0x1F601, 0x1F610, prExtendedPictographic}, // 6.0 [16] (😁..😐) beaming face with smiling eyes..neutral face - {0x1F611, 0x1F611, prExtendedPictographic}, // 6.1 [1] (😑) expressionless face - {0x1F612, 0x1F614, prExtendedPictographic}, // 6.0 [3] (😒..😔) unamused face..pensive face - {0x1F615, 0x1F615, prExtendedPictographic}, // 6.1 [1] (😕) confused face - {0x1F616, 0x1F616, prExtendedPictographic}, // 6.0 [1] (😖) confounded face - {0x1F617, 0x1F617, prExtendedPictographic}, // 6.1 [1] (😗) kissing face - {0x1F618, 0x1F618, prExtendedPictographic}, // 6.0 [1] (😘) face blowing a kiss - {0x1F619, 0x1F619, prExtendedPictographic}, // 6.1 [1] (😙) kissing face with smiling eyes - {0x1F61A, 0x1F61A, prExtendedPictographic}, // 6.0 [1] (😚) kissing face with closed eyes - {0x1F61B, 0x1F61B, prExtendedPictographic}, // 6.1 [1] (😛) face with tongue - {0x1F61C, 0x1F61E, prExtendedPictographic}, // 6.0 [3] (😜..😞) winking face with tongue..disappointed face - {0x1F61F, 0x1F61F, prExtendedPictographic}, // 6.1 [1] (😟) worried face - {0x1F620, 0x1F625, prExtendedPictographic}, // 6.0 [6] (😠..😥) angry face..sad but relieved face - {0x1F626, 0x1F627, prExtendedPictographic}, // 6.1 [2] (😦..😧) frowning face with open mouth..anguished face - {0x1F628, 0x1F62B, prExtendedPictographic}, // 6.0 [4] (😨..😫) fearful face..tired face - {0x1F62C, 0x1F62C, prExtendedPictographic}, // 6.1 [1] (😬) grimacing face - {0x1F62D, 0x1F62D, prExtendedPictographic}, // 6.0 [1] (😭) loudly crying face - {0x1F62E, 0x1F62F, prExtendedPictographic}, // 6.1 [2] (😮..😯) face with open mouth..hushed face - {0x1F630, 0x1F633, prExtendedPictographic}, // 6.0 [4] (😰..😳) anxious face with sweat..flushed face - {0x1F634, 0x1F634, prExtendedPictographic}, // 6.1 [1] (😴) sleeping face - {0x1F635, 0x1F640, prExtendedPictographic}, // 6.0 [12] (😵..🙀) dizzy face..weary cat - {0x1F641, 0x1F642, prExtendedPictographic}, // 7.0 [2] (🙁..🙂) slightly frowning face..slightly smiling face - {0x1F643, 0x1F644, prExtendedPictographic}, // 8.0 [2] (🙃..🙄) upside-down face..face with rolling eyes - {0x1F645, 0x1F64F, prExtendedPictographic}, // 6.0 [11] (🙅..🙏) person gesturing NO..folded hands - {0x1F680, 0x1F6C5, prExtendedPictographic}, // 6.0 [70] (🚀..🛅) rocket..left luggage - {0x1F6C6, 0x1F6CF, prExtendedPictographic}, // 7.0 [10] (🛆..🛏️) TRIANGLE WITH ROUNDED CORNERS..bed - {0x1F6D0, 0x1F6D0, prExtendedPictographic}, // 8.0 [1] (🛐) place of worship - {0x1F6D1, 0x1F6D2, prExtendedPictographic}, // 9.0 [2] (🛑..🛒) stop sign..shopping cart - {0x1F6D3, 0x1F6D4, prExtendedPictographic}, // 10.0 [2] (🛓..🛔) STUPA..PAGODA - {0x1F6D5, 0x1F6D5, prExtendedPictographic}, // 12.0 [1] (🛕) hindu temple - {0x1F6D6, 0x1F6DF, prExtendedPictographic}, // NA [10] (🛖..🛟) .. - {0x1F6E0, 0x1F6EC, prExtendedPictographic}, // 7.0 [13] (🛠️..🛬) hammer and wrench..airplane arrival - {0x1F6ED, 0x1F6EF, prExtendedPictographic}, // NA [3] (🛭..🛯) .. - {0x1F6F0, 0x1F6F3, prExtendedPictographic}, // 7.0 [4] (🛰️..🛳️) satellite..passenger ship - {0x1F6F4, 0x1F6F6, prExtendedPictographic}, // 9.0 [3] (🛴..🛶) kick scooter..canoe - {0x1F6F7, 0x1F6F8, prExtendedPictographic}, // 10.0 [2] (🛷..🛸) sled..flying saucer - {0x1F6F9, 0x1F6F9, prExtendedPictographic}, // 11.0 [1] (🛹) skateboard - {0x1F6FA, 0x1F6FA, prExtendedPictographic}, // 12.0 [1] (🛺) auto rickshaw - {0x1F6FB, 0x1F6FF, prExtendedPictographic}, // NA [5] (🛻..🛿) .. - {0x1F774, 0x1F77F, prExtendedPictographic}, // NA [12] (🝴..🝿) .. - {0x1F7D5, 0x1F7D8, prExtendedPictographic}, // 11.0 [4] (🟕..🟘) CIRCLED TRIANGLE..NEGATIVE CIRCLED SQUARE - {0x1F7D9, 0x1F7DF, prExtendedPictographic}, // NA [7] (🟙..🟟) .. - {0x1F7E0, 0x1F7EB, prExtendedPictographic}, // 12.0 [12] (🟠..🟫) orange circle..brown square - {0x1F7EC, 0x1F7FF, prExtendedPictographic}, // NA [20] (🟬..🟿) .. - {0x1F80C, 0x1F80F, prExtendedPictographic}, // NA [4] (🠌..🠏) .. - {0x1F848, 0x1F84F, prExtendedPictographic}, // NA [8] (🡈..🡏) .. - {0x1F85A, 0x1F85F, prExtendedPictographic}, // NA [6] (🡚..🡟) .. - {0x1F888, 0x1F88F, prExtendedPictographic}, // NA [8] (🢈..🢏) .. - {0x1F8AE, 0x1F8FF, prExtendedPictographic}, // NA [82] (🢮..🣿) .. - {0x1F90C, 0x1F90C, prExtendedPictographic}, // NA [1] (🤌) - {0x1F90D, 0x1F90F, prExtendedPictographic}, // 12.0 [3] (🤍..🤏) white heart..pinching hand - {0x1F910, 0x1F918, prExtendedPictographic}, // 8.0 [9] (🤐..🤘) zipper-mouth face..sign of the horns - {0x1F919, 0x1F91E, prExtendedPictographic}, // 9.0 [6] (🤙..🤞) call me hand..crossed fingers - {0x1F91F, 0x1F91F, prExtendedPictographic}, // 10.0 [1] (🤟) love-you gesture - {0x1F920, 0x1F927, prExtendedPictographic}, // 9.0 [8] (🤠..🤧) cowboy hat face..sneezing face - {0x1F928, 0x1F92F, prExtendedPictographic}, // 10.0 [8] (🤨..🤯) face with raised eyebrow..exploding head - {0x1F930, 0x1F930, prExtendedPictographic}, // 9.0 [1] (🤰) pregnant woman - {0x1F931, 0x1F932, prExtendedPictographic}, // 10.0 [2] (🤱..🤲) breast-feeding..palms up together - {0x1F933, 0x1F93A, prExtendedPictographic}, // 9.0 [8] (🤳..🤺) selfie..person fencing - {0x1F93C, 0x1F93E, prExtendedPictographic}, // 9.0 [3] (🤼..🤾) people wrestling..person playing handball - {0x1F93F, 0x1F93F, prExtendedPictographic}, // 12.0 [1] (🤿) diving mask - {0x1F940, 0x1F945, prExtendedPictographic}, // 9.0 [6] (🥀..🥅) wilted flower..goal net - {0x1F947, 0x1F94B, prExtendedPictographic}, // 9.0 [5] (🥇..🥋) 1st place medal..martial arts uniform - {0x1F94C, 0x1F94C, prExtendedPictographic}, // 10.0 [1] (🥌) curling stone - {0x1F94D, 0x1F94F, prExtendedPictographic}, // 11.0 [3] (🥍..🥏) lacrosse..flying disc - {0x1F950, 0x1F95E, prExtendedPictographic}, // 9.0 [15] (🥐..🥞) croissant..pancakes - {0x1F95F, 0x1F96B, prExtendedPictographic}, // 10.0 [13] (🥟..🥫) dumpling..canned food - {0x1F96C, 0x1F970, prExtendedPictographic}, // 11.0 [5] (🥬..🥰) leafy green..smiling face with hearts - {0x1F971, 0x1F971, prExtendedPictographic}, // 12.0 [1] (🥱) yawning face - {0x1F972, 0x1F972, prExtendedPictographic}, // NA [1] (🥲) - {0x1F973, 0x1F976, prExtendedPictographic}, // 11.0 [4] (🥳..🥶) partying face..cold face - {0x1F977, 0x1F979, prExtendedPictographic}, // NA [3] (🥷..🥹) .. - {0x1F97A, 0x1F97A, prExtendedPictographic}, // 11.0 [1] (🥺) pleading face - {0x1F97B, 0x1F97B, prExtendedPictographic}, // 12.0 [1] (🥻) sari - {0x1F97C, 0x1F97F, prExtendedPictographic}, // 11.0 [4] (🥼..🥿) lab coat..flat shoe - {0x1F980, 0x1F984, prExtendedPictographic}, // 8.0 [5] (🦀..🦄) crab..unicorn - {0x1F985, 0x1F991, prExtendedPictographic}, // 9.0 [13] (🦅..🦑) eagle..squid - {0x1F992, 0x1F997, prExtendedPictographic}, // 10.0 [6] (🦒..🦗) giraffe..cricket - {0x1F998, 0x1F9A2, prExtendedPictographic}, // 11.0 [11] (🦘..🦢) kangaroo..swan - {0x1F9A3, 0x1F9A4, prExtendedPictographic}, // NA [2] (🦣..🦤) .. - {0x1F9A5, 0x1F9AA, prExtendedPictographic}, // 12.0 [6] (🦥..🦪) sloth..oyster - {0x1F9AB, 0x1F9AD, prExtendedPictographic}, // NA [3] (🦫..🦭) .. - {0x1F9AE, 0x1F9AF, prExtendedPictographic}, // 12.0 [2] (🦮..🦯) guide dog..probing cane - {0x1F9B0, 0x1F9B9, prExtendedPictographic}, // 11.0 [10] (🦰..🦹) red hair..supervillain - {0x1F9BA, 0x1F9BF, prExtendedPictographic}, // 12.0 [6] (🦺..🦿) safety vest..mechanical leg - {0x1F9C0, 0x1F9C0, prExtendedPictographic}, // 8.0 [1] (🧀) cheese wedge - {0x1F9C1, 0x1F9C2, prExtendedPictographic}, // 11.0 [2] (🧁..🧂) cupcake..salt - {0x1F9C3, 0x1F9CA, prExtendedPictographic}, // 12.0 [8] (🧃..🧊) beverage box..ice cube - {0x1F9CB, 0x1F9CC, prExtendedPictographic}, // NA [2] (🧋..🧌) .. - {0x1F9CD, 0x1F9CF, prExtendedPictographic}, // 12.0 [3] (🧍..🧏) person standing..deaf person - {0x1F9D0, 0x1F9E6, prExtendedPictographic}, // 10.0 [23] (🧐..🧦) face with monocle..socks - {0x1F9E7, 0x1F9FF, prExtendedPictographic}, // 11.0 [25] (🧧..🧿) red envelope..nazar amulet - {0x1FA00, 0x1FA53, prExtendedPictographic}, // 12.0 [84] (🨀..🩓) NEUTRAL CHESS KING..BLACK CHESS KNIGHT-BISHOP - {0x1FA54, 0x1FA5F, prExtendedPictographic}, // NA [12] (🩔..🩟) .. - {0x1FA60, 0x1FA6D, prExtendedPictographic}, // 11.0 [14] (🩠..🩭) XIANGQI RED GENERAL..XIANGQI BLACK SOLDIER - {0x1FA6E, 0x1FA6F, prExtendedPictographic}, // NA [2] (🩮..🩯) .. - {0x1FA70, 0x1FA73, prExtendedPictographic}, // 12.0 [4] (🩰..🩳) ballet shoes..shorts - {0x1FA74, 0x1FA77, prExtendedPictographic}, // NA [4] (🩴..🩷) .. - {0x1FA78, 0x1FA7A, prExtendedPictographic}, // 12.0 [3] (🩸..🩺) drop of blood..stethoscope - {0x1FA7B, 0x1FA7F, prExtendedPictographic}, // NA [5] (🩻..🩿) .. - {0x1FA80, 0x1FA82, prExtendedPictographic}, // 12.0 [3] (🪀..🪂) yo-yo..parachute - {0x1FA83, 0x1FA8F, prExtendedPictographic}, // NA [13] (🪃..🪏) .. - {0x1FA90, 0x1FA95, prExtendedPictographic}, // 12.0 [6] (🪐..🪕) ringed planet..banjo - {0x1FA96, 0x1FFFD, prExtendedPictographic}, // NA[1384] (🪖..🿽) .. - {0xE0000, 0xE0000, prControl}, // Cn - {0xE0001, 0xE0001, prControl}, // Cf LANGUAGE TAG - {0xE0002, 0xE001F, prControl}, // Cn [30] .. - {0xE0020, 0xE007F, prExtend}, // Cf [96] TAG SPACE..CANCEL TAG - {0xE0080, 0xE00FF, prControl}, // Cn [128] .. - {0xE0100, 0xE01EF, prExtend}, // Mn [240] VARIATION SELECTOR-17..VARIATION SELECTOR-256 - {0xE01F0, 0xE0FFF, prControl}, // Cn [3600] .. -} - -// property returns the Unicode property value (see constants above) of the -// given code point. -func property(r rune) int { - // Run a binary search. - from := 0 - to := len(codePoints) - for to > from { - middle := (from + to) / 2 - cpRange := codePoints[middle] - if int(r) < cpRange[0] { - to = middle - continue - } - if int(r) > cpRange[1] { - from = middle + 1 - continue - } - return cpRange[2] - } - return prAny -} diff --git a/vendor/github.com/syndtr/goleveldb/.travis.yml b/vendor/github.com/syndtr/goleveldb/.travis.yml deleted file mode 100644 index f31939e..0000000 --- a/vendor/github.com/syndtr/goleveldb/.travis.yml +++ /dev/null @@ -1,13 +0,0 @@ -language: go - -go: - - 1.5 - - 1.6 - - 1.7 - - 1.8 - - 1.9 - - tip - -script: - - go test -timeout 1h ./... - - go test -timeout 30m -race -run "TestDB_(Concurrent|GoleveldbIssue74)" ./leveldb diff --git a/vendor/github.com/syndtr/goleveldb/LICENSE b/vendor/github.com/syndtr/goleveldb/LICENSE deleted file mode 100644 index 4a772d1..0000000 --- a/vendor/github.com/syndtr/goleveldb/LICENSE +++ /dev/null @@ -1,24 +0,0 @@ -Copyright 2012 Suryandaru Triandana -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above copyright -notice, this list of conditions and the following disclaimer in the -documentation and/or other materials provided with the distribution. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/github.com/syndtr/goleveldb/README.md b/vendor/github.com/syndtr/goleveldb/README.md deleted file mode 100644 index 41a4761..0000000 --- a/vendor/github.com/syndtr/goleveldb/README.md +++ /dev/null @@ -1,107 +0,0 @@ -This is an implementation of the [LevelDB key/value database](http:code.google.com/p/leveldb) in the [Go programming language](http:golang.org). - -[![Build Status](https://travis-ci.org/syndtr/goleveldb.png?branch=master)](https://travis-ci.org/syndtr/goleveldb) - -Installation ------------ - - go get github.com/syndtr/goleveldb/leveldb - -Requirements ------------ - -* Need at least `go1.5` or newer. - -Usage ------------ - -Create or open a database: -```go -// The returned DB instance is safe for concurrent use. Which mean that all -// DB's methods may be called concurrently from multiple goroutine. -db, err := leveldb.OpenFile("path/to/db", nil) -... -defer db.Close() -... -``` -Read or modify the database content: -```go -// Remember that the contents of the returned slice should not be modified. -data, err := db.Get([]byte("key"), nil) -... -err = db.Put([]byte("key"), []byte("value"), nil) -... -err = db.Delete([]byte("key"), nil) -... -``` - -Iterate over database content: -```go -iter := db.NewIterator(nil, nil) -for iter.Next() { - // Remember that the contents of the returned slice should not be modified, and - // only valid until the next call to Next. - key := iter.Key() - value := iter.Value() - ... -} -iter.Release() -err = iter.Error() -... -``` -Seek-then-Iterate: -```go -iter := db.NewIterator(nil, nil) -for ok := iter.Seek(key); ok; ok = iter.Next() { - // Use key/value. - ... -} -iter.Release() -err = iter.Error() -... -``` -Iterate over subset of database content: -```go -iter := db.NewIterator(&util.Range{Start: []byte("foo"), Limit: []byte("xoo")}, nil) -for iter.Next() { - // Use key/value. - ... -} -iter.Release() -err = iter.Error() -... -``` -Iterate over subset of database content with a particular prefix: -```go -iter := db.NewIterator(util.BytesPrefix([]byte("foo-")), nil) -for iter.Next() { - // Use key/value. - ... -} -iter.Release() -err = iter.Error() -... -``` -Batch writes: -```go -batch := new(leveldb.Batch) -batch.Put([]byte("foo"), []byte("value")) -batch.Put([]byte("bar"), []byte("another value")) -batch.Delete([]byte("baz")) -err = db.Write(batch, nil) -... -``` -Use bloom filter: -```go -o := &opt.Options{ - Filter: filter.NewBloomFilter(10), -} -db, err := leveldb.OpenFile("path/to/db", o) -... -defer db.Close() -... -``` -Documentation ------------ - -You can read package documentation [here](http:godoc.org/github.com/syndtr/goleveldb). diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/batch.go b/vendor/github.com/syndtr/goleveldb/leveldb/batch.go deleted file mode 100644 index 2259200..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/batch.go +++ /dev/null @@ -1,349 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "encoding/binary" - "fmt" - "io" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/memdb" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -// ErrBatchCorrupted records reason of batch corruption. This error will be -// wrapped with errors.ErrCorrupted. -type ErrBatchCorrupted struct { - Reason string -} - -func (e *ErrBatchCorrupted) Error() string { - return fmt.Sprintf("leveldb: batch corrupted: %s", e.Reason) -} - -func newErrBatchCorrupted(reason string) error { - return errors.NewErrCorrupted(storage.FileDesc{}, &ErrBatchCorrupted{reason}) -} - -const ( - batchHeaderLen = 8 + 4 - batchGrowRec = 3000 - batchBufioSize = 16 -) - -// BatchReplay wraps basic batch operations. -type BatchReplay interface { - Put(key, value []byte) - Delete(key []byte) -} - -type batchIndex struct { - keyType keyType - keyPos, keyLen int - valuePos, valueLen int -} - -func (index batchIndex) k(data []byte) []byte { - return data[index.keyPos : index.keyPos+index.keyLen] -} - -func (index batchIndex) v(data []byte) []byte { - if index.valueLen != 0 { - return data[index.valuePos : index.valuePos+index.valueLen] - } - return nil -} - -func (index batchIndex) kv(data []byte) (key, value []byte) { - return index.k(data), index.v(data) -} - -// Batch is a write batch. -type Batch struct { - data []byte - index []batchIndex - - // internalLen is sums of key/value pair length plus 8-bytes internal key. - internalLen int -} - -func (b *Batch) grow(n int) { - o := len(b.data) - if cap(b.data)-o < n { - div := 1 - if len(b.index) > batchGrowRec { - div = len(b.index) / batchGrowRec - } - ndata := make([]byte, o, o+n+o/div) - copy(ndata, b.data) - b.data = ndata - } -} - -func (b *Batch) appendRec(kt keyType, key, value []byte) { - n := 1 + binary.MaxVarintLen32 + len(key) - if kt == keyTypeVal { - n += binary.MaxVarintLen32 + len(value) - } - b.grow(n) - index := batchIndex{keyType: kt} - o := len(b.data) - data := b.data[:o+n] - data[o] = byte(kt) - o++ - o += binary.PutUvarint(data[o:], uint64(len(key))) - index.keyPos = o - index.keyLen = len(key) - o += copy(data[o:], key) - if kt == keyTypeVal { - o += binary.PutUvarint(data[o:], uint64(len(value))) - index.valuePos = o - index.valueLen = len(value) - o += copy(data[o:], value) - } - b.data = data[:o] - b.index = append(b.index, index) - b.internalLen += index.keyLen + index.valueLen + 8 -} - -// Put appends 'put operation' of the given key/value pair to the batch. -// It is safe to modify the contents of the argument after Put returns but not -// before. -func (b *Batch) Put(key, value []byte) { - b.appendRec(keyTypeVal, key, value) -} - -// Delete appends 'delete operation' of the given key to the batch. -// It is safe to modify the contents of the argument after Delete returns but -// not before. -func (b *Batch) Delete(key []byte) { - b.appendRec(keyTypeDel, key, nil) -} - -// Dump dumps batch contents. The returned slice can be loaded into the -// batch using Load method. -// The returned slice is not its own copy, so the contents should not be -// modified. -func (b *Batch) Dump() []byte { - return b.data -} - -// Load loads given slice into the batch. Previous contents of the batch -// will be discarded. -// The given slice will not be copied and will be used as batch buffer, so -// it is not safe to modify the contents of the slice. -func (b *Batch) Load(data []byte) error { - return b.decode(data, -1) -} - -// Replay replays batch contents. -func (b *Batch) Replay(r BatchReplay) error { - for _, index := range b.index { - switch index.keyType { - case keyTypeVal: - r.Put(index.k(b.data), index.v(b.data)) - case keyTypeDel: - r.Delete(index.k(b.data)) - } - } - return nil -} - -// Len returns number of records in the batch. -func (b *Batch) Len() int { - return len(b.index) -} - -// Reset resets the batch. -func (b *Batch) Reset() { - b.data = b.data[:0] - b.index = b.index[:0] - b.internalLen = 0 -} - -func (b *Batch) replayInternal(fn func(i int, kt keyType, k, v []byte) error) error { - for i, index := range b.index { - if err := fn(i, index.keyType, index.k(b.data), index.v(b.data)); err != nil { - return err - } - } - return nil -} - -func (b *Batch) append(p *Batch) { - ob := len(b.data) - oi := len(b.index) - b.data = append(b.data, p.data...) - b.index = append(b.index, p.index...) - b.internalLen += p.internalLen - - // Updating index offset. - if ob != 0 { - for ; oi < len(b.index); oi++ { - index := &b.index[oi] - index.keyPos += ob - if index.valueLen != 0 { - index.valuePos += ob - } - } - } -} - -func (b *Batch) decode(data []byte, expectedLen int) error { - b.data = data - b.index = b.index[:0] - b.internalLen = 0 - err := decodeBatch(data, func(i int, index batchIndex) error { - b.index = append(b.index, index) - b.internalLen += index.keyLen + index.valueLen + 8 - return nil - }) - if err != nil { - return err - } - if expectedLen >= 0 && len(b.index) != expectedLen { - return newErrBatchCorrupted(fmt.Sprintf("invalid records length: %d vs %d", expectedLen, len(b.index))) - } - return nil -} - -func (b *Batch) putMem(seq uint64, mdb *memdb.DB) error { - var ik []byte - for i, index := range b.index { - ik = makeInternalKey(ik, index.k(b.data), seq+uint64(i), index.keyType) - if err := mdb.Put(ik, index.v(b.data)); err != nil { - return err - } - } - return nil -} - -func (b *Batch) revertMem(seq uint64, mdb *memdb.DB) error { - var ik []byte - for i, index := range b.index { - ik = makeInternalKey(ik, index.k(b.data), seq+uint64(i), index.keyType) - if err := mdb.Delete(ik); err != nil { - return err - } - } - return nil -} - -func newBatch() interface{} { - return &Batch{} -} - -func decodeBatch(data []byte, fn func(i int, index batchIndex) error) error { - var index batchIndex - for i, o := 0, 0; o < len(data); i++ { - // Key type. - index.keyType = keyType(data[o]) - if index.keyType > keyTypeVal { - return newErrBatchCorrupted(fmt.Sprintf("bad record: invalid type %#x", uint(index.keyType))) - } - o++ - - // Key. - x, n := binary.Uvarint(data[o:]) - o += n - if n <= 0 || o+int(x) > len(data) { - return newErrBatchCorrupted("bad record: invalid key length") - } - index.keyPos = o - index.keyLen = int(x) - o += index.keyLen - - // Value. - if index.keyType == keyTypeVal { - x, n = binary.Uvarint(data[o:]) - o += n - if n <= 0 || o+int(x) > len(data) { - return newErrBatchCorrupted("bad record: invalid value length") - } - index.valuePos = o - index.valueLen = int(x) - o += index.valueLen - } else { - index.valuePos = 0 - index.valueLen = 0 - } - - if err := fn(i, index); err != nil { - return err - } - } - return nil -} - -func decodeBatchToMem(data []byte, expectSeq uint64, mdb *memdb.DB) (seq uint64, batchLen int, err error) { - seq, batchLen, err = decodeBatchHeader(data) - if err != nil { - return 0, 0, err - } - if seq < expectSeq { - return 0, 0, newErrBatchCorrupted("invalid sequence number") - } - data = data[batchHeaderLen:] - var ik []byte - var decodedLen int - err = decodeBatch(data, func(i int, index batchIndex) error { - if i >= batchLen { - return newErrBatchCorrupted("invalid records length") - } - ik = makeInternalKey(ik, index.k(data), seq+uint64(i), index.keyType) - if err := mdb.Put(ik, index.v(data)); err != nil { - return err - } - decodedLen++ - return nil - }) - if err == nil && decodedLen != batchLen { - err = newErrBatchCorrupted(fmt.Sprintf("invalid records length: %d vs %d", batchLen, decodedLen)) - } - return -} - -func encodeBatchHeader(dst []byte, seq uint64, batchLen int) []byte { - dst = ensureBuffer(dst, batchHeaderLen) - binary.LittleEndian.PutUint64(dst, seq) - binary.LittleEndian.PutUint32(dst[8:], uint32(batchLen)) - return dst -} - -func decodeBatchHeader(data []byte) (seq uint64, batchLen int, err error) { - if len(data) < batchHeaderLen { - return 0, 0, newErrBatchCorrupted("too short") - } - - seq = binary.LittleEndian.Uint64(data) - batchLen = int(binary.LittleEndian.Uint32(data[8:])) - if batchLen < 0 { - return 0, 0, newErrBatchCorrupted("invalid records length") - } - return -} - -func batchesLen(batches []*Batch) int { - batchLen := 0 - for _, batch := range batches { - batchLen += batch.Len() - } - return batchLen -} - -func writeBatchesWithHeader(wr io.Writer, batches []*Batch, seq uint64) error { - if _, err := wr.Write(encodeBatchHeader(nil, seq, batchesLen(batches))); err != nil { - return err - } - for _, batch := range batches { - if _, err := wr.Write(batch.data); err != nil { - return err - } - } - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/batch_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/batch_test.go deleted file mode 100644 index 62775f7..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/batch_test.go +++ /dev/null @@ -1,147 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "bytes" - "fmt" - "testing" - "testing/quick" - - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -func TestBatchHeader(t *testing.T) { - f := func(seq uint64, length uint32) bool { - encoded := encodeBatchHeader(nil, seq, int(length)) - decSeq, decLength, err := decodeBatchHeader(encoded) - return err == nil && decSeq == seq && decLength == int(length) - } - config := &quick.Config{ - Rand: testutil.NewRand(), - } - if err := quick.Check(f, config); err != nil { - t.Error(err) - } -} - -type batchKV struct { - kt keyType - k, v []byte -} - -func TestBatch(t *testing.T) { - var ( - kvs []batchKV - internalLen int - ) - batch := new(Batch) - rbatch := new(Batch) - abatch := new(Batch) - testBatch := func(i int, kt keyType, k, v []byte) error { - kv := kvs[i] - if kv.kt != kt { - return fmt.Errorf("invalid key type, index=%d: %d vs %d", i, kv.kt, kt) - } - if !bytes.Equal(kv.k, k) { - return fmt.Errorf("invalid key, index=%d", i) - } - if !bytes.Equal(kv.v, v) { - return fmt.Errorf("invalid value, index=%d", i) - } - return nil - } - f := func(ktr uint8, k, v []byte) bool { - kt := keyType(ktr % 2) - if kt == keyTypeVal { - batch.Put(k, v) - rbatch.Put(k, v) - kvs = append(kvs, batchKV{kt: kt, k: k, v: v}) - internalLen += len(k) + len(v) + 8 - } else { - batch.Delete(k) - rbatch.Delete(k) - kvs = append(kvs, batchKV{kt: kt, k: k}) - internalLen += len(k) + 8 - } - if batch.Len() != len(kvs) { - t.Logf("batch.Len: %d vs %d", len(kvs), batch.Len()) - return false - } - if batch.internalLen != internalLen { - t.Logf("abatch.internalLen: %d vs %d", internalLen, batch.internalLen) - return false - } - if len(kvs)%1000 == 0 { - if err := batch.replayInternal(testBatch); err != nil { - t.Logf("batch.replayInternal: %v", err) - return false - } - - abatch.append(rbatch) - rbatch.Reset() - if abatch.Len() != len(kvs) { - t.Logf("abatch.Len: %d vs %d", len(kvs), abatch.Len()) - return false - } - if abatch.internalLen != internalLen { - t.Logf("abatch.internalLen: %d vs %d", internalLen, abatch.internalLen) - return false - } - if err := abatch.replayInternal(testBatch); err != nil { - t.Logf("abatch.replayInternal: %v", err) - return false - } - - nbatch := new(Batch) - if err := nbatch.Load(batch.Dump()); err != nil { - t.Logf("nbatch.Load: %v", err) - return false - } - if nbatch.Len() != len(kvs) { - t.Logf("nbatch.Len: %d vs %d", len(kvs), nbatch.Len()) - return false - } - if nbatch.internalLen != internalLen { - t.Logf("nbatch.internalLen: %d vs %d", internalLen, nbatch.internalLen) - return false - } - if err := nbatch.replayInternal(testBatch); err != nil { - t.Logf("nbatch.replayInternal: %v", err) - return false - } - } - if len(kvs)%10000 == 0 { - nbatch := new(Batch) - if err := batch.Replay(nbatch); err != nil { - t.Logf("batch.Replay: %v", err) - return false - } - if nbatch.Len() != len(kvs) { - t.Logf("nbatch.Len: %d vs %d", len(kvs), nbatch.Len()) - return false - } - if nbatch.internalLen != internalLen { - t.Logf("nbatch.internalLen: %d vs %d", internalLen, nbatch.internalLen) - return false - } - if err := nbatch.replayInternal(testBatch); err != nil { - t.Logf("nbatch.replayInternal: %v", err) - return false - } - } - return true - } - config := &quick.Config{ - MaxCount: 40000, - Rand: testutil.NewRand(), - } - if err := quick.Check(f, config); err != nil { - t.Error(err) - } - t.Logf("length=%d internalLen=%d", len(kvs), internalLen) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/bench_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/bench_test.go deleted file mode 100644 index 435250c..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/bench_test.go +++ /dev/null @@ -1,507 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "bytes" - "fmt" - "math/rand" - "os" - "path/filepath" - "runtime" - "sync/atomic" - "testing" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -func randomString(r *rand.Rand, n int) []byte { - b := new(bytes.Buffer) - for i := 0; i < n; i++ { - b.WriteByte(' ' + byte(r.Intn(95))) - } - return b.Bytes() -} - -func compressibleStr(r *rand.Rand, frac float32, n int) []byte { - nn := int(float32(n) * frac) - rb := randomString(r, nn) - b := make([]byte, 0, n+nn) - for len(b) < n { - b = append(b, rb...) - } - return b[:n] -} - -type valueGen struct { - src []byte - pos int -} - -func newValueGen(frac float32) *valueGen { - v := new(valueGen) - r := rand.New(rand.NewSource(301)) - v.src = make([]byte, 0, 1048576+100) - for len(v.src) < 1048576 { - v.src = append(v.src, compressibleStr(r, frac, 100)...) - } - return v -} - -func (v *valueGen) get(n int) []byte { - if v.pos+n > len(v.src) { - v.pos = 0 - } - v.pos += n - return v.src[v.pos-n : v.pos] -} - -var benchDB = filepath.Join(os.TempDir(), fmt.Sprintf("goleveldbbench-%d", os.Getuid())) - -type dbBench struct { - b *testing.B - stor storage.Storage - db *DB - - o *opt.Options - ro *opt.ReadOptions - wo *opt.WriteOptions - - keys, values [][]byte -} - -func openDBBench(b *testing.B, noCompress bool) *dbBench { - _, err := os.Stat(benchDB) - if err == nil { - err = os.RemoveAll(benchDB) - if err != nil { - b.Fatal("cannot remove old db: ", err) - } - } - - p := &dbBench{ - b: b, - o: &opt.Options{}, - ro: &opt.ReadOptions{}, - wo: &opt.WriteOptions{}, - } - p.stor, err = storage.OpenFile(benchDB, false) - if err != nil { - b.Fatal("cannot open stor: ", err) - } - if noCompress { - p.o.Compression = opt.NoCompression - } - - p.db, err = Open(p.stor, p.o) - if err != nil { - b.Fatal("cannot open db: ", err) - } - - return p -} - -func (p *dbBench) reopen() { - p.db.Close() - var err error - p.db, err = Open(p.stor, p.o) - if err != nil { - p.b.Fatal("Reopen: got error: ", err) - } -} - -func (p *dbBench) populate(n int) { - p.keys, p.values = make([][]byte, n), make([][]byte, n) - v := newValueGen(0.5) - for i := range p.keys { - p.keys[i], p.values[i] = []byte(fmt.Sprintf("%016d", i)), v.get(100) - } -} - -func (p *dbBench) randomize() { - m := len(p.keys) - times := m * 2 - r1, r2 := rand.New(rand.NewSource(0xdeadbeef)), rand.New(rand.NewSource(0xbeefface)) - for n := 0; n < times; n++ { - i, j := r1.Int()%m, r2.Int()%m - if i == j { - continue - } - p.keys[i], p.keys[j] = p.keys[j], p.keys[i] - p.values[i], p.values[j] = p.values[j], p.values[i] - } -} - -func (p *dbBench) writes(perBatch int) { - b := p.b - db := p.db - - n := len(p.keys) - m := n / perBatch - if n%perBatch > 0 { - m++ - } - batches := make([]Batch, m) - j := 0 - for i := range batches { - first := true - for ; j < n && ((j+1)%perBatch != 0 || first); j++ { - first = false - batches[i].Put(p.keys[j], p.values[j]) - } - } - runtime.GC() - - b.ResetTimer() - b.StartTimer() - for i := range batches { - err := db.Write(&(batches[i]), p.wo) - if err != nil { - b.Fatal("write failed: ", err) - } - } - b.StopTimer() - b.SetBytes(116) -} - -func (p *dbBench) gc() { - p.keys, p.values = nil, nil - runtime.GC() -} - -func (p *dbBench) puts() { - b := p.b - db := p.db - - b.ResetTimer() - b.StartTimer() - for i := range p.keys { - err := db.Put(p.keys[i], p.values[i], p.wo) - if err != nil { - b.Fatal("put failed: ", err) - } - } - b.StopTimer() - b.SetBytes(116) -} - -func (p *dbBench) fill() { - b := p.b - db := p.db - - perBatch := 10000 - batch := new(Batch) - for i, n := 0, len(p.keys); i < n; { - first := true - for ; i < n && ((i+1)%perBatch != 0 || first); i++ { - first = false - batch.Put(p.keys[i], p.values[i]) - } - err := db.Write(batch, p.wo) - if err != nil { - b.Fatal("write failed: ", err) - } - batch.Reset() - } -} - -func (p *dbBench) gets() { - b := p.b - db := p.db - - b.ResetTimer() - for i := range p.keys { - _, err := db.Get(p.keys[i], p.ro) - if err != nil { - b.Error("got error: ", err) - } - } - b.StopTimer() -} - -func (p *dbBench) seeks() { - b := p.b - - iter := p.newIter() - defer iter.Release() - b.ResetTimer() - for i := range p.keys { - if !iter.Seek(p.keys[i]) { - b.Error("value not found for: ", string(p.keys[i])) - } - } - b.StopTimer() -} - -func (p *dbBench) newIter() iterator.Iterator { - iter := p.db.NewIterator(nil, p.ro) - err := iter.Error() - if err != nil { - p.b.Fatal("cannot create iterator: ", err) - } - return iter -} - -func (p *dbBench) close() { - if bp, err := p.db.GetProperty("leveldb.blockpool"); err == nil { - p.b.Log("Block pool stats: ", bp) - } - p.db.Close() - p.stor.Close() - os.RemoveAll(benchDB) - p.db = nil - p.keys = nil - p.values = nil - runtime.GC() -} - -func BenchmarkDBWrite(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.writes(1) - p.close() -} - -func BenchmarkDBWriteBatch(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.writes(1000) - p.close() -} - -func BenchmarkDBWriteUncompressed(b *testing.B) { - p := openDBBench(b, true) - p.populate(b.N) - p.writes(1) - p.close() -} - -func BenchmarkDBWriteBatchUncompressed(b *testing.B) { - p := openDBBench(b, true) - p.populate(b.N) - p.writes(1000) - p.close() -} - -func BenchmarkDBWriteRandom(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.randomize() - p.writes(1) - p.close() -} - -func BenchmarkDBWriteRandomSync(b *testing.B) { - p := openDBBench(b, false) - p.wo.Sync = true - p.populate(b.N) - p.writes(1) - p.close() -} - -func BenchmarkDBOverwrite(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.writes(1) - p.writes(1) - p.close() -} - -func BenchmarkDBOverwriteRandom(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.writes(1) - p.randomize() - p.writes(1) - p.close() -} - -func BenchmarkDBPut(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.puts() - p.close() -} - -func BenchmarkDBRead(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.gc() - - iter := p.newIter() - b.ResetTimer() - for iter.Next() { - } - iter.Release() - b.StopTimer() - b.SetBytes(116) - p.close() -} - -func BenchmarkDBReadGC(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - - iter := p.newIter() - b.ResetTimer() - for iter.Next() { - } - iter.Release() - b.StopTimer() - b.SetBytes(116) - p.close() -} - -func BenchmarkDBReadUncompressed(b *testing.B) { - p := openDBBench(b, true) - p.populate(b.N) - p.fill() - p.gc() - - iter := p.newIter() - b.ResetTimer() - for iter.Next() { - } - iter.Release() - b.StopTimer() - b.SetBytes(116) - p.close() -} - -func BenchmarkDBReadTable(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.reopen() - p.gc() - - iter := p.newIter() - b.ResetTimer() - for iter.Next() { - } - iter.Release() - b.StopTimer() - b.SetBytes(116) - p.close() -} - -func BenchmarkDBReadReverse(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.gc() - - iter := p.newIter() - b.ResetTimer() - iter.Last() - for iter.Prev() { - } - iter.Release() - b.StopTimer() - b.SetBytes(116) - p.close() -} - -func BenchmarkDBReadReverseTable(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.reopen() - p.gc() - - iter := p.newIter() - b.ResetTimer() - iter.Last() - for iter.Prev() { - } - iter.Release() - b.StopTimer() - b.SetBytes(116) - p.close() -} - -func BenchmarkDBSeek(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.seeks() - p.close() -} - -func BenchmarkDBSeekRandom(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.randomize() - p.seeks() - p.close() -} - -func BenchmarkDBGet(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.gets() - p.close() -} - -func BenchmarkDBGetRandom(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.randomize() - p.gets() - p.close() -} - -func BenchmarkDBReadConcurrent(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.gc() - defer p.close() - - b.ResetTimer() - b.SetBytes(116) - - b.RunParallel(func(pb *testing.PB) { - iter := p.newIter() - defer iter.Release() - for pb.Next() && iter.Next() { - } - }) -} - -func BenchmarkDBReadConcurrent2(b *testing.B) { - p := openDBBench(b, false) - p.populate(b.N) - p.fill() - p.gc() - defer p.close() - - b.ResetTimer() - b.SetBytes(116) - - var dir uint32 - b.RunParallel(func(pb *testing.PB) { - iter := p.newIter() - defer iter.Release() - if atomic.AddUint32(&dir, 1)%2 == 0 { - for pb.Next() && iter.Next() { - } - } else { - if pb.Next() && iter.Last() { - for pb.Next() && iter.Prev() { - } - } - } - }) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/cache/bench_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/cache/bench_test.go deleted file mode 100644 index 89aef69..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/cache/bench_test.go +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package cache - -import ( - "math/rand" - "testing" - "time" -) - -func BenchmarkLRUCache(b *testing.B) { - c := NewCache(NewLRU(10000)) - - b.SetParallelism(10) - b.RunParallel(func(pb *testing.PB) { - r := rand.New(rand.NewSource(time.Now().UnixNano())) - - for pb.Next() { - key := uint64(r.Intn(1000000)) - c.Get(0, key, func() (int, Value) { - return 1, key - }).Release() - } - }) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache.go b/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache.go deleted file mode 100644 index c5940b2..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache.go +++ /dev/null @@ -1,705 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package cache provides interface and implementation of a cache algorithms. -package cache - -import ( - "sync" - "sync/atomic" - "unsafe" - - "github.com/syndtr/goleveldb/leveldb/util" -) - -// Cacher provides interface to implements a caching functionality. -// An implementation must be safe for concurrent use. -type Cacher interface { - // Capacity returns cache capacity. - Capacity() int - - // SetCapacity sets cache capacity. - SetCapacity(capacity int) - - // Promote promotes the 'cache node'. - Promote(n *Node) - - // Ban evicts the 'cache node' and prevent subsequent 'promote'. - Ban(n *Node) - - // Evict evicts the 'cache node'. - Evict(n *Node) - - // EvictNS evicts 'cache node' with the given namespace. - EvictNS(ns uint64) - - // EvictAll evicts all 'cache node'. - EvictAll() - - // Close closes the 'cache tree' - Close() error -} - -// Value is a 'cacheable object'. It may implements util.Releaser, if -// so the the Release method will be called once object is released. -type Value interface{} - -// NamespaceGetter provides convenient wrapper for namespace. -type NamespaceGetter struct { - Cache *Cache - NS uint64 -} - -// Get simply calls Cache.Get() method. -func (g *NamespaceGetter) Get(key uint64, setFunc func() (size int, value Value)) *Handle { - return g.Cache.Get(g.NS, key, setFunc) -} - -// The hash tables implementation is based on: -// "Dynamic-Sized Nonblocking Hash Tables", by Yujie Liu, -// Kunlong Zhang, and Michael Spear. -// ACM Symposium on Principles of Distributed Computing, Jul 2014. - -const ( - mInitialSize = 1 << 4 - mOverflowThreshold = 1 << 5 - mOverflowGrowThreshold = 1 << 7 -) - -type mBucket struct { - mu sync.Mutex - node []*Node - frozen bool -} - -func (b *mBucket) freeze() []*Node { - b.mu.Lock() - defer b.mu.Unlock() - if !b.frozen { - b.frozen = true - } - return b.node -} - -func (b *mBucket) get(r *Cache, h *mNode, hash uint32, ns, key uint64, noset bool) (done, added bool, n *Node) { - b.mu.Lock() - - if b.frozen { - b.mu.Unlock() - return - } - - // Scan the node. - for _, n := range b.node { - if n.hash == hash && n.ns == ns && n.key == key { - atomic.AddInt32(&n.ref, 1) - b.mu.Unlock() - return true, false, n - } - } - - // Get only. - if noset { - b.mu.Unlock() - return true, false, nil - } - - // Create node. - n = &Node{ - r: r, - hash: hash, - ns: ns, - key: key, - ref: 1, - } - // Add node to bucket. - b.node = append(b.node, n) - bLen := len(b.node) - b.mu.Unlock() - - // Update counter. - grow := atomic.AddInt32(&r.nodes, 1) >= h.growThreshold - if bLen > mOverflowThreshold { - grow = grow || atomic.AddInt32(&h.overflow, 1) >= mOverflowGrowThreshold - } - - // Grow. - if grow && atomic.CompareAndSwapInt32(&h.resizeInProgess, 0, 1) { - nhLen := len(h.buckets) << 1 - nh := &mNode{ - buckets: make([]unsafe.Pointer, nhLen), - mask: uint32(nhLen) - 1, - pred: unsafe.Pointer(h), - growThreshold: int32(nhLen * mOverflowThreshold), - shrinkThreshold: int32(nhLen >> 1), - } - ok := atomic.CompareAndSwapPointer(&r.mHead, unsafe.Pointer(h), unsafe.Pointer(nh)) - if !ok { - panic("BUG: failed swapping head") - } - go nh.initBuckets() - } - - return true, true, n -} - -func (b *mBucket) delete(r *Cache, h *mNode, hash uint32, ns, key uint64) (done, deleted bool) { - b.mu.Lock() - - if b.frozen { - b.mu.Unlock() - return - } - - // Scan the node. - var ( - n *Node - bLen int - ) - for i := range b.node { - n = b.node[i] - if n.ns == ns && n.key == key { - if atomic.LoadInt32(&n.ref) == 0 { - deleted = true - - // Call releaser. - if n.value != nil { - if r, ok := n.value.(util.Releaser); ok { - r.Release() - } - n.value = nil - } - - // Remove node from bucket. - b.node = append(b.node[:i], b.node[i+1:]...) - bLen = len(b.node) - } - break - } - } - b.mu.Unlock() - - if deleted { - // Call OnDel. - for _, f := range n.onDel { - f() - } - - // Update counter. - atomic.AddInt32(&r.size, int32(n.size)*-1) - shrink := atomic.AddInt32(&r.nodes, -1) < h.shrinkThreshold - if bLen >= mOverflowThreshold { - atomic.AddInt32(&h.overflow, -1) - } - - // Shrink. - if shrink && len(h.buckets) > mInitialSize && atomic.CompareAndSwapInt32(&h.resizeInProgess, 0, 1) { - nhLen := len(h.buckets) >> 1 - nh := &mNode{ - buckets: make([]unsafe.Pointer, nhLen), - mask: uint32(nhLen) - 1, - pred: unsafe.Pointer(h), - growThreshold: int32(nhLen * mOverflowThreshold), - shrinkThreshold: int32(nhLen >> 1), - } - ok := atomic.CompareAndSwapPointer(&r.mHead, unsafe.Pointer(h), unsafe.Pointer(nh)) - if !ok { - panic("BUG: failed swapping head") - } - go nh.initBuckets() - } - } - - return true, deleted -} - -type mNode struct { - buckets []unsafe.Pointer // []*mBucket - mask uint32 - pred unsafe.Pointer // *mNode - resizeInProgess int32 - - overflow int32 - growThreshold int32 - shrinkThreshold int32 -} - -func (n *mNode) initBucket(i uint32) *mBucket { - if b := (*mBucket)(atomic.LoadPointer(&n.buckets[i])); b != nil { - return b - } - - p := (*mNode)(atomic.LoadPointer(&n.pred)) - if p != nil { - var node []*Node - if n.mask > p.mask { - // Grow. - pb := (*mBucket)(atomic.LoadPointer(&p.buckets[i&p.mask])) - if pb == nil { - pb = p.initBucket(i & p.mask) - } - m := pb.freeze() - // Split nodes. - for _, x := range m { - if x.hash&n.mask == i { - node = append(node, x) - } - } - } else { - // Shrink. - pb0 := (*mBucket)(atomic.LoadPointer(&p.buckets[i])) - if pb0 == nil { - pb0 = p.initBucket(i) - } - pb1 := (*mBucket)(atomic.LoadPointer(&p.buckets[i+uint32(len(n.buckets))])) - if pb1 == nil { - pb1 = p.initBucket(i + uint32(len(n.buckets))) - } - m0 := pb0.freeze() - m1 := pb1.freeze() - // Merge nodes. - node = make([]*Node, 0, len(m0)+len(m1)) - node = append(node, m0...) - node = append(node, m1...) - } - b := &mBucket{node: node} - if atomic.CompareAndSwapPointer(&n.buckets[i], nil, unsafe.Pointer(b)) { - if len(node) > mOverflowThreshold { - atomic.AddInt32(&n.overflow, int32(len(node)-mOverflowThreshold)) - } - return b - } - } - - return (*mBucket)(atomic.LoadPointer(&n.buckets[i])) -} - -func (n *mNode) initBuckets() { - for i := range n.buckets { - n.initBucket(uint32(i)) - } - atomic.StorePointer(&n.pred, nil) -} - -// Cache is a 'cache map'. -type Cache struct { - mu sync.RWMutex - mHead unsafe.Pointer // *mNode - nodes int32 - size int32 - cacher Cacher - closed bool -} - -// NewCache creates a new 'cache map'. The cacher is optional and -// may be nil. -func NewCache(cacher Cacher) *Cache { - h := &mNode{ - buckets: make([]unsafe.Pointer, mInitialSize), - mask: mInitialSize - 1, - growThreshold: int32(mInitialSize * mOverflowThreshold), - shrinkThreshold: 0, - } - for i := range h.buckets { - h.buckets[i] = unsafe.Pointer(&mBucket{}) - } - r := &Cache{ - mHead: unsafe.Pointer(h), - cacher: cacher, - } - return r -} - -func (r *Cache) getBucket(hash uint32) (*mNode, *mBucket) { - h := (*mNode)(atomic.LoadPointer(&r.mHead)) - i := hash & h.mask - b := (*mBucket)(atomic.LoadPointer(&h.buckets[i])) - if b == nil { - b = h.initBucket(i) - } - return h, b -} - -func (r *Cache) delete(n *Node) bool { - for { - h, b := r.getBucket(n.hash) - done, deleted := b.delete(r, h, n.hash, n.ns, n.key) - if done { - return deleted - } - } - return false -} - -// Nodes returns number of 'cache node' in the map. -func (r *Cache) Nodes() int { - return int(atomic.LoadInt32(&r.nodes)) -} - -// Size returns sums of 'cache node' size in the map. -func (r *Cache) Size() int { - return int(atomic.LoadInt32(&r.size)) -} - -// Capacity returns cache capacity. -func (r *Cache) Capacity() int { - if r.cacher == nil { - return 0 - } - return r.cacher.Capacity() -} - -// SetCapacity sets cache capacity. -func (r *Cache) SetCapacity(capacity int) { - if r.cacher != nil { - r.cacher.SetCapacity(capacity) - } -} - -// Get gets 'cache node' with the given namespace and key. -// If cache node is not found and setFunc is not nil, Get will atomically creates -// the 'cache node' by calling setFunc. Otherwise Get will returns nil. -// -// The returned 'cache handle' should be released after use by calling Release -// method. -func (r *Cache) Get(ns, key uint64, setFunc func() (size int, value Value)) *Handle { - r.mu.RLock() - defer r.mu.RUnlock() - if r.closed { - return nil - } - - hash := murmur32(ns, key, 0xf00) - for { - h, b := r.getBucket(hash) - done, _, n := b.get(r, h, hash, ns, key, setFunc == nil) - if done { - if n != nil { - n.mu.Lock() - if n.value == nil { - if setFunc == nil { - n.mu.Unlock() - n.unref() - return nil - } - - n.size, n.value = setFunc() - if n.value == nil { - n.size = 0 - n.mu.Unlock() - n.unref() - return nil - } - atomic.AddInt32(&r.size, int32(n.size)) - } - n.mu.Unlock() - if r.cacher != nil { - r.cacher.Promote(n) - } - return &Handle{unsafe.Pointer(n)} - } - - break - } - } - return nil -} - -// Delete removes and ban 'cache node' with the given namespace and key. -// A banned 'cache node' will never inserted into the 'cache tree'. Ban -// only attributed to the particular 'cache node', so when a 'cache node' -// is recreated it will not be banned. -// -// If onDel is not nil, then it will be executed if such 'cache node' -// doesn't exist or once the 'cache node' is released. -// -// Delete return true is such 'cache node' exist. -func (r *Cache) Delete(ns, key uint64, onDel func()) bool { - r.mu.RLock() - defer r.mu.RUnlock() - if r.closed { - return false - } - - hash := murmur32(ns, key, 0xf00) - for { - h, b := r.getBucket(hash) - done, _, n := b.get(r, h, hash, ns, key, true) - if done { - if n != nil { - if onDel != nil { - n.mu.Lock() - n.onDel = append(n.onDel, onDel) - n.mu.Unlock() - } - if r.cacher != nil { - r.cacher.Ban(n) - } - n.unref() - return true - } - - break - } - } - - if onDel != nil { - onDel() - } - - return false -} - -// Evict evicts 'cache node' with the given namespace and key. This will -// simply call Cacher.Evict. -// -// Evict return true is such 'cache node' exist. -func (r *Cache) Evict(ns, key uint64) bool { - r.mu.RLock() - defer r.mu.RUnlock() - if r.closed { - return false - } - - hash := murmur32(ns, key, 0xf00) - for { - h, b := r.getBucket(hash) - done, _, n := b.get(r, h, hash, ns, key, true) - if done { - if n != nil { - if r.cacher != nil { - r.cacher.Evict(n) - } - n.unref() - return true - } - - break - } - } - - return false -} - -// EvictNS evicts 'cache node' with the given namespace. This will -// simply call Cacher.EvictNS. -func (r *Cache) EvictNS(ns uint64) { - r.mu.RLock() - defer r.mu.RUnlock() - if r.closed { - return - } - - if r.cacher != nil { - r.cacher.EvictNS(ns) - } -} - -// EvictAll evicts all 'cache node'. This will simply call Cacher.EvictAll. -func (r *Cache) EvictAll() { - r.mu.RLock() - defer r.mu.RUnlock() - if r.closed { - return - } - - if r.cacher != nil { - r.cacher.EvictAll() - } -} - -// Close closes the 'cache map' and forcefully releases all 'cache node'. -func (r *Cache) Close() error { - r.mu.Lock() - if !r.closed { - r.closed = true - - h := (*mNode)(r.mHead) - h.initBuckets() - - for i := range h.buckets { - b := (*mBucket)(h.buckets[i]) - for _, n := range b.node { - // Call releaser. - if n.value != nil { - if r, ok := n.value.(util.Releaser); ok { - r.Release() - } - n.value = nil - } - - // Call OnDel. - for _, f := range n.onDel { - f() - } - n.onDel = nil - } - } - } - r.mu.Unlock() - - // Avoid deadlock. - if r.cacher != nil { - if err := r.cacher.Close(); err != nil { - return err - } - } - return nil -} - -// CloseWeak closes the 'cache map' and evict all 'cache node' from cacher, but -// unlike Close it doesn't forcefully releases 'cache node'. -func (r *Cache) CloseWeak() error { - r.mu.Lock() - if !r.closed { - r.closed = true - } - r.mu.Unlock() - - // Avoid deadlock. - if r.cacher != nil { - r.cacher.EvictAll() - if err := r.cacher.Close(); err != nil { - return err - } - } - return nil -} - -// Node is a 'cache node'. -type Node struct { - r *Cache - - hash uint32 - ns, key uint64 - - mu sync.Mutex - size int - value Value - - ref int32 - onDel []func() - - CacheData unsafe.Pointer -} - -// NS returns this 'cache node' namespace. -func (n *Node) NS() uint64 { - return n.ns -} - -// Key returns this 'cache node' key. -func (n *Node) Key() uint64 { - return n.key -} - -// Size returns this 'cache node' size. -func (n *Node) Size() int { - return n.size -} - -// Value returns this 'cache node' value. -func (n *Node) Value() Value { - return n.value -} - -// Ref returns this 'cache node' ref counter. -func (n *Node) Ref() int32 { - return atomic.LoadInt32(&n.ref) -} - -// GetHandle returns an handle for this 'cache node'. -func (n *Node) GetHandle() *Handle { - if atomic.AddInt32(&n.ref, 1) <= 1 { - panic("BUG: Node.GetHandle on zero ref") - } - return &Handle{unsafe.Pointer(n)} -} - -func (n *Node) unref() { - if atomic.AddInt32(&n.ref, -1) == 0 { - n.r.delete(n) - } -} - -func (n *Node) unrefLocked() { - if atomic.AddInt32(&n.ref, -1) == 0 { - n.r.mu.RLock() - if !n.r.closed { - n.r.delete(n) - } - n.r.mu.RUnlock() - } -} - -// Handle is a 'cache handle' of a 'cache node'. -type Handle struct { - n unsafe.Pointer // *Node -} - -// Value returns the value of the 'cache node'. -func (h *Handle) Value() Value { - n := (*Node)(atomic.LoadPointer(&h.n)) - if n != nil { - return n.value - } - return nil -} - -// Release releases this 'cache handle'. -// It is safe to call release multiple times. -func (h *Handle) Release() { - nPtr := atomic.LoadPointer(&h.n) - if nPtr != nil && atomic.CompareAndSwapPointer(&h.n, nPtr, nil) { - n := (*Node)(nPtr) - n.unrefLocked() - } -} - -func murmur32(ns, key uint64, seed uint32) uint32 { - const ( - m = uint32(0x5bd1e995) - r = 24 - ) - - k1 := uint32(ns >> 32) - k2 := uint32(ns) - k3 := uint32(key >> 32) - k4 := uint32(key) - - k1 *= m - k1 ^= k1 >> r - k1 *= m - - k2 *= m - k2 ^= k2 >> r - k2 *= m - - k3 *= m - k3 ^= k3 >> r - k3 *= m - - k4 *= m - k4 ^= k4 >> r - k4 *= m - - h := seed - - h *= m - h ^= k1 - h *= m - h ^= k2 - h *= m - h ^= k3 - h *= m - h ^= k4 - - h ^= h >> 13 - h *= m - h ^= h >> 15 - - return h -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache_test.go deleted file mode 100644 index 6b017bd..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/cache/cache_test.go +++ /dev/null @@ -1,563 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package cache - -import ( - "math/rand" - "runtime" - "sync" - "sync/atomic" - "testing" - "time" - "unsafe" -) - -type int32o int32 - -func (o *int32o) acquire() { - if atomic.AddInt32((*int32)(o), 1) != 1 { - panic("BUG: invalid ref") - } -} - -func (o *int32o) Release() { - if atomic.AddInt32((*int32)(o), -1) != 0 { - panic("BUG: invalid ref") - } -} - -type releaserFunc struct { - fn func() - value Value -} - -func (r releaserFunc) Release() { - if r.fn != nil { - r.fn() - } -} - -func set(c *Cache, ns, key uint64, value Value, charge int, relf func()) *Handle { - return c.Get(ns, key, func() (int, Value) { - if relf != nil { - return charge, releaserFunc{relf, value} - } - return charge, value - }) -} - -type cacheMapTestParams struct { - nobjects, nhandles, concurrent, repeat int -} - -func TestCacheMap(t *testing.T) { - runtime.GOMAXPROCS(runtime.NumCPU()) - - var params []cacheMapTestParams - if testing.Short() { - params = []cacheMapTestParams{ - {1000, 100, 20, 3}, - {10000, 300, 50, 10}, - } - } else { - params = []cacheMapTestParams{ - {10000, 400, 50, 3}, - {100000, 1000, 100, 10}, - } - } - - var ( - objects [][]int32o - handles [][]unsafe.Pointer - ) - - for _, x := range params { - objects = append(objects, make([]int32o, x.nobjects)) - handles = append(handles, make([]unsafe.Pointer, x.nhandles)) - } - - c := NewCache(nil) - - wg := new(sync.WaitGroup) - var done int32 - - for ns, x := range params { - for i := 0; i < x.concurrent; i++ { - wg.Add(1) - go func(ns, i, repeat int, objects []int32o, handles []unsafe.Pointer) { - defer wg.Done() - r := rand.New(rand.NewSource(time.Now().UnixNano())) - - for j := len(objects) * repeat; j >= 0; j-- { - key := uint64(r.Intn(len(objects))) - h := c.Get(uint64(ns), key, func() (int, Value) { - o := &objects[key] - o.acquire() - return 1, o - }) - if v := h.Value().(*int32o); v != &objects[key] { - t.Fatalf("#%d invalid value: want=%p got=%p", ns, &objects[key], v) - } - if objects[key] != 1 { - t.Fatalf("#%d invalid object %d: %d", ns, key, objects[key]) - } - if !atomic.CompareAndSwapPointer(&handles[r.Intn(len(handles))], nil, unsafe.Pointer(h)) { - h.Release() - } - } - }(ns, i, x.repeat, objects[ns], handles[ns]) - } - - go func(handles []unsafe.Pointer) { - r := rand.New(rand.NewSource(time.Now().UnixNano())) - - for atomic.LoadInt32(&done) == 0 { - i := r.Intn(len(handles)) - h := (*Handle)(atomic.LoadPointer(&handles[i])) - if h != nil && atomic.CompareAndSwapPointer(&handles[i], unsafe.Pointer(h), nil) { - h.Release() - } - time.Sleep(time.Millisecond) - } - }(handles[ns]) - } - - go func() { - handles := make([]*Handle, 100000) - for atomic.LoadInt32(&done) == 0 { - for i := range handles { - handles[i] = c.Get(999999999, uint64(i), func() (int, Value) { - return 1, 1 - }) - } - for _, h := range handles { - h.Release() - } - } - }() - - wg.Wait() - - atomic.StoreInt32(&done, 1) - - for _, handles0 := range handles { - for i := range handles0 { - h := (*Handle)(atomic.LoadPointer(&handles0[i])) - if h != nil && atomic.CompareAndSwapPointer(&handles0[i], unsafe.Pointer(h), nil) { - h.Release() - } - } - } - - for ns, objects0 := range objects { - for i, o := range objects0 { - if o != 0 { - t.Fatalf("invalid object #%d.%d: ref=%d", ns, i, o) - } - } - } -} - -func TestCacheMap_NodesAndSize(t *testing.T) { - c := NewCache(nil) - if c.Nodes() != 0 { - t.Errorf("invalid nodes counter: want=%d got=%d", 0, c.Nodes()) - } - if c.Size() != 0 { - t.Errorf("invalid size counter: want=%d got=%d", 0, c.Size()) - } - set(c, 0, 1, 1, 1, nil) - set(c, 0, 2, 2, 2, nil) - set(c, 1, 1, 3, 3, nil) - set(c, 2, 1, 4, 1, nil) - if c.Nodes() != 4 { - t.Errorf("invalid nodes counter: want=%d got=%d", 4, c.Nodes()) - } - if c.Size() != 7 { - t.Errorf("invalid size counter: want=%d got=%d", 4, c.Size()) - } -} - -func TestLRUCache_Capacity(t *testing.T) { - c := NewCache(NewLRU(10)) - if c.Capacity() != 10 { - t.Errorf("invalid capacity: want=%d got=%d", 10, c.Capacity()) - } - set(c, 0, 1, 1, 1, nil).Release() - set(c, 0, 2, 2, 2, nil).Release() - set(c, 1, 1, 3, 3, nil).Release() - set(c, 2, 1, 4, 1, nil).Release() - set(c, 2, 2, 5, 1, nil).Release() - set(c, 2, 3, 6, 1, nil).Release() - set(c, 2, 4, 7, 1, nil).Release() - set(c, 2, 5, 8, 1, nil).Release() - if c.Nodes() != 7 { - t.Errorf("invalid nodes counter: want=%d got=%d", 7, c.Nodes()) - } - if c.Size() != 10 { - t.Errorf("invalid size counter: want=%d got=%d", 10, c.Size()) - } - c.SetCapacity(9) - if c.Capacity() != 9 { - t.Errorf("invalid capacity: want=%d got=%d", 9, c.Capacity()) - } - if c.Nodes() != 6 { - t.Errorf("invalid nodes counter: want=%d got=%d", 6, c.Nodes()) - } - if c.Size() != 8 { - t.Errorf("invalid size counter: want=%d got=%d", 8, c.Size()) - } -} - -func TestCacheMap_NilValue(t *testing.T) { - c := NewCache(NewLRU(10)) - h := c.Get(0, 0, func() (size int, value Value) { - return 1, nil - }) - if h != nil { - t.Error("cache handle is non-nil") - } - if c.Nodes() != 0 { - t.Errorf("invalid nodes counter: want=%d got=%d", 0, c.Nodes()) - } - if c.Size() != 0 { - t.Errorf("invalid size counter: want=%d got=%d", 0, c.Size()) - } -} - -func TestLRUCache_GetLatency(t *testing.T) { - runtime.GOMAXPROCS(runtime.NumCPU()) - - const ( - concurrentSet = 30 - concurrentGet = 3 - duration = 3 * time.Second - delay = 3 * time.Millisecond - maxkey = 100000 - ) - - var ( - set, getHit, getAll int32 - getMaxLatency, getDuration int64 - ) - - c := NewCache(NewLRU(5000)) - wg := &sync.WaitGroup{} - until := time.Now().Add(duration) - for i := 0; i < concurrentSet; i++ { - wg.Add(1) - go func(i int) { - defer wg.Done() - r := rand.New(rand.NewSource(time.Now().UnixNano())) - for time.Now().Before(until) { - c.Get(0, uint64(r.Intn(maxkey)), func() (int, Value) { - time.Sleep(delay) - atomic.AddInt32(&set, 1) - return 1, 1 - }).Release() - } - }(i) - } - for i := 0; i < concurrentGet; i++ { - wg.Add(1) - go func(i int) { - defer wg.Done() - r := rand.New(rand.NewSource(time.Now().UnixNano())) - for { - mark := time.Now() - if mark.Before(until) { - h := c.Get(0, uint64(r.Intn(maxkey)), nil) - latency := int64(time.Now().Sub(mark)) - m := atomic.LoadInt64(&getMaxLatency) - if latency > m { - atomic.CompareAndSwapInt64(&getMaxLatency, m, latency) - } - atomic.AddInt64(&getDuration, latency) - if h != nil { - atomic.AddInt32(&getHit, 1) - h.Release() - } - atomic.AddInt32(&getAll, 1) - } else { - break - } - } - }(i) - } - - wg.Wait() - getAvglatency := time.Duration(getDuration) / time.Duration(getAll) - t.Logf("set=%d getHit=%d getAll=%d getMaxLatency=%v getAvgLatency=%v", - set, getHit, getAll, time.Duration(getMaxLatency), getAvglatency) - - if getAvglatency > delay/3 { - t.Errorf("get avg latency > %v: got=%v", delay/3, getAvglatency) - } -} - -func TestLRUCache_HitMiss(t *testing.T) { - cases := []struct { - key uint64 - value string - }{ - {1, "vvvvvvvvv"}, - {100, "v1"}, - {0, "v2"}, - {12346, "v3"}, - {777, "v4"}, - {999, "v5"}, - {7654, "v6"}, - {2, "v7"}, - {3, "v8"}, - {9, "v9"}, - } - - setfin := 0 - c := NewCache(NewLRU(1000)) - for i, x := range cases { - set(c, 0, x.key, x.value, len(x.value), func() { - setfin++ - }).Release() - for j, y := range cases { - h := c.Get(0, y.key, nil) - if j <= i { - // should hit - if h == nil { - t.Errorf("case '%d' iteration '%d' is miss", i, j) - } else { - if x := h.Value().(releaserFunc).value.(string); x != y.value { - t.Errorf("case '%d' iteration '%d' has invalid value got '%s', want '%s'", i, j, x, y.value) - } - } - } else { - // should miss - if h != nil { - t.Errorf("case '%d' iteration '%d' is hit , value '%s'", i, j, h.Value().(releaserFunc).value.(string)) - } - } - if h != nil { - h.Release() - } - } - } - - for i, x := range cases { - finalizerOk := false - c.Delete(0, x.key, func() { - finalizerOk = true - }) - - if !finalizerOk { - t.Errorf("case %d delete finalizer not executed", i) - } - - for j, y := range cases { - h := c.Get(0, y.key, nil) - if j > i { - // should hit - if h == nil { - t.Errorf("case '%d' iteration '%d' is miss", i, j) - } else { - if x := h.Value().(releaserFunc).value.(string); x != y.value { - t.Errorf("case '%d' iteration '%d' has invalid value got '%s', want '%s'", i, j, x, y.value) - } - } - } else { - // should miss - if h != nil { - t.Errorf("case '%d' iteration '%d' is hit, value '%s'", i, j, h.Value().(releaserFunc).value.(string)) - } - } - if h != nil { - h.Release() - } - } - } - - if setfin != len(cases) { - t.Errorf("some set finalizer may not be executed, want=%d got=%d", len(cases), setfin) - } -} - -func TestLRUCache_Eviction(t *testing.T) { - c := NewCache(NewLRU(12)) - o1 := set(c, 0, 1, 1, 1, nil) - set(c, 0, 2, 2, 1, nil).Release() - set(c, 0, 3, 3, 1, nil).Release() - set(c, 0, 4, 4, 1, nil).Release() - set(c, 0, 5, 5, 1, nil).Release() - if h := c.Get(0, 2, nil); h != nil { // 1,3,4,5,2 - h.Release() - } - set(c, 0, 9, 9, 10, nil).Release() // 5,2,9 - - for _, key := range []uint64{9, 2, 5, 1} { - h := c.Get(0, key, nil) - if h == nil { - t.Errorf("miss for key '%d'", key) - } else { - if x := h.Value().(int); x != int(key) { - t.Errorf("invalid value for key '%d' want '%d', got '%d'", key, key, x) - } - h.Release() - } - } - o1.Release() - for _, key := range []uint64{1, 2, 5} { - h := c.Get(0, key, nil) - if h == nil { - t.Errorf("miss for key '%d'", key) - } else { - if x := h.Value().(int); x != int(key) { - t.Errorf("invalid value for key '%d' want '%d', got '%d'", key, key, x) - } - h.Release() - } - } - for _, key := range []uint64{3, 4, 9} { - h := c.Get(0, key, nil) - if h != nil { - t.Errorf("hit for key '%d'", key) - if x := h.Value().(int); x != int(key) { - t.Errorf("invalid value for key '%d' want '%d', got '%d'", key, key, x) - } - h.Release() - } - } -} - -func TestLRUCache_Evict(t *testing.T) { - c := NewCache(NewLRU(6)) - set(c, 0, 1, 1, 1, nil).Release() - set(c, 0, 2, 2, 1, nil).Release() - set(c, 1, 1, 4, 1, nil).Release() - set(c, 1, 2, 5, 1, nil).Release() - set(c, 2, 1, 6, 1, nil).Release() - set(c, 2, 2, 7, 1, nil).Release() - - for ns := 0; ns < 3; ns++ { - for key := 1; key < 3; key++ { - if h := c.Get(uint64(ns), uint64(key), nil); h != nil { - h.Release() - } else { - t.Errorf("Cache.Get on #%d.%d return nil", ns, key) - } - } - } - - if ok := c.Evict(0, 1); !ok { - t.Error("first Cache.Evict on #0.1 return false") - } - if ok := c.Evict(0, 1); ok { - t.Error("second Cache.Evict on #0.1 return true") - } - if h := c.Get(0, 1, nil); h != nil { - t.Errorf("Cache.Get on #0.1 return non-nil: %v", h.Value()) - } - - c.EvictNS(1) - if h := c.Get(1, 1, nil); h != nil { - t.Errorf("Cache.Get on #1.1 return non-nil: %v", h.Value()) - } - if h := c.Get(1, 2, nil); h != nil { - t.Errorf("Cache.Get on #1.2 return non-nil: %v", h.Value()) - } - - c.EvictAll() - for ns := 0; ns < 3; ns++ { - for key := 1; key < 3; key++ { - if h := c.Get(uint64(ns), uint64(key), nil); h != nil { - t.Errorf("Cache.Get on #%d.%d return non-nil: %v", ns, key, h.Value()) - } - } - } -} - -func TestLRUCache_Delete(t *testing.T) { - delFuncCalled := 0 - delFunc := func() { - delFuncCalled++ - } - - c := NewCache(NewLRU(2)) - set(c, 0, 1, 1, 1, nil).Release() - set(c, 0, 2, 2, 1, nil).Release() - - if ok := c.Delete(0, 1, delFunc); !ok { - t.Error("Cache.Delete on #1 return false") - } - if h := c.Get(0, 1, nil); h != nil { - t.Errorf("Cache.Get on #1 return non-nil: %v", h.Value()) - } - if ok := c.Delete(0, 1, delFunc); ok { - t.Error("Cache.Delete on #1 return true") - } - - h2 := c.Get(0, 2, nil) - if h2 == nil { - t.Error("Cache.Get on #2 return nil") - } - if ok := c.Delete(0, 2, delFunc); !ok { - t.Error("(1) Cache.Delete on #2 return false") - } - if ok := c.Delete(0, 2, delFunc); !ok { - t.Error("(2) Cache.Delete on #2 return false") - } - - set(c, 0, 3, 3, 1, nil).Release() - set(c, 0, 4, 4, 1, nil).Release() - c.Get(0, 2, nil).Release() - - for key := 2; key <= 4; key++ { - if h := c.Get(0, uint64(key), nil); h != nil { - h.Release() - } else { - t.Errorf("Cache.Get on #%d return nil", key) - } - } - - h2.Release() - if h := c.Get(0, 2, nil); h != nil { - t.Errorf("Cache.Get on #2 return non-nil: %v", h.Value()) - } - - if delFuncCalled != 4 { - t.Errorf("delFunc isn't called 4 times: got=%d", delFuncCalled) - } -} - -func TestLRUCache_Close(t *testing.T) { - relFuncCalled := 0 - relFunc := func() { - relFuncCalled++ - } - delFuncCalled := 0 - delFunc := func() { - delFuncCalled++ - } - - c := NewCache(NewLRU(2)) - set(c, 0, 1, 1, 1, relFunc).Release() - set(c, 0, 2, 2, 1, relFunc).Release() - - h3 := set(c, 0, 3, 3, 1, relFunc) - if h3 == nil { - t.Error("Cache.Get on #3 return nil") - } - if ok := c.Delete(0, 3, delFunc); !ok { - t.Error("Cache.Delete on #3 return false") - } - - c.Close() - - if relFuncCalled != 3 { - t.Errorf("relFunc isn't called 3 times: got=%d", relFuncCalled) - } - if delFuncCalled != 1 { - t.Errorf("delFunc isn't called 1 times: got=%d", delFuncCalled) - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/cache/lru.go b/vendor/github.com/syndtr/goleveldb/leveldb/cache/lru.go deleted file mode 100644 index d9a84cd..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/cache/lru.go +++ /dev/null @@ -1,195 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package cache - -import ( - "sync" - "unsafe" -) - -type lruNode struct { - n *Node - h *Handle - ban bool - - next, prev *lruNode -} - -func (n *lruNode) insert(at *lruNode) { - x := at.next - at.next = n - n.prev = at - n.next = x - x.prev = n -} - -func (n *lruNode) remove() { - if n.prev != nil { - n.prev.next = n.next - n.next.prev = n.prev - n.prev = nil - n.next = nil - } else { - panic("BUG: removing removed node") - } -} - -type lru struct { - mu sync.Mutex - capacity int - used int - recent lruNode -} - -func (r *lru) reset() { - r.recent.next = &r.recent - r.recent.prev = &r.recent - r.used = 0 -} - -func (r *lru) Capacity() int { - r.mu.Lock() - defer r.mu.Unlock() - return r.capacity -} - -func (r *lru) SetCapacity(capacity int) { - var evicted []*lruNode - - r.mu.Lock() - r.capacity = capacity - for r.used > r.capacity { - rn := r.recent.prev - if rn == nil { - panic("BUG: invalid LRU used or capacity counter") - } - rn.remove() - rn.n.CacheData = nil - r.used -= rn.n.Size() - evicted = append(evicted, rn) - } - r.mu.Unlock() - - for _, rn := range evicted { - rn.h.Release() - } -} - -func (r *lru) Promote(n *Node) { - var evicted []*lruNode - - r.mu.Lock() - if n.CacheData == nil { - if n.Size() <= r.capacity { - rn := &lruNode{n: n, h: n.GetHandle()} - rn.insert(&r.recent) - n.CacheData = unsafe.Pointer(rn) - r.used += n.Size() - - for r.used > r.capacity { - rn := r.recent.prev - if rn == nil { - panic("BUG: invalid LRU used or capacity counter") - } - rn.remove() - rn.n.CacheData = nil - r.used -= rn.n.Size() - evicted = append(evicted, rn) - } - } - } else { - rn := (*lruNode)(n.CacheData) - if !rn.ban { - rn.remove() - rn.insert(&r.recent) - } - } - r.mu.Unlock() - - for _, rn := range evicted { - rn.h.Release() - } -} - -func (r *lru) Ban(n *Node) { - r.mu.Lock() - if n.CacheData == nil { - n.CacheData = unsafe.Pointer(&lruNode{n: n, ban: true}) - } else { - rn := (*lruNode)(n.CacheData) - if !rn.ban { - rn.remove() - rn.ban = true - r.used -= rn.n.Size() - r.mu.Unlock() - - rn.h.Release() - rn.h = nil - return - } - } - r.mu.Unlock() -} - -func (r *lru) Evict(n *Node) { - r.mu.Lock() - rn := (*lruNode)(n.CacheData) - if rn == nil || rn.ban { - r.mu.Unlock() - return - } - n.CacheData = nil - r.mu.Unlock() - - rn.h.Release() -} - -func (r *lru) EvictNS(ns uint64) { - var evicted []*lruNode - - r.mu.Lock() - for e := r.recent.prev; e != &r.recent; { - rn := e - e = e.prev - if rn.n.NS() == ns { - rn.remove() - rn.n.CacheData = nil - r.used -= rn.n.Size() - evicted = append(evicted, rn) - } - } - r.mu.Unlock() - - for _, rn := range evicted { - rn.h.Release() - } -} - -func (r *lru) EvictAll() { - r.mu.Lock() - back := r.recent.prev - for rn := back; rn != &r.recent; rn = rn.prev { - rn.n.CacheData = nil - } - r.reset() - r.mu.Unlock() - - for rn := back; rn != &r.recent; rn = rn.prev { - rn.h.Release() - } -} - -func (r *lru) Close() error { - return nil -} - -// NewLRU create a new LRU-cache. -func NewLRU(capacity int) Cacher { - r := &lru{capacity: capacity} - r.reset() - return r -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/comparer.go b/vendor/github.com/syndtr/goleveldb/leveldb/comparer.go deleted file mode 100644 index 448402b..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/comparer.go +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "github.com/syndtr/goleveldb/leveldb/comparer" -) - -type iComparer struct { - ucmp comparer.Comparer -} - -func (icmp *iComparer) uName() string { - return icmp.ucmp.Name() -} - -func (icmp *iComparer) uCompare(a, b []byte) int { - return icmp.ucmp.Compare(a, b) -} - -func (icmp *iComparer) uSeparator(dst, a, b []byte) []byte { - return icmp.ucmp.Separator(dst, a, b) -} - -func (icmp *iComparer) uSuccessor(dst, b []byte) []byte { - return icmp.ucmp.Successor(dst, b) -} - -func (icmp *iComparer) Name() string { - return icmp.uName() -} - -func (icmp *iComparer) Compare(a, b []byte) int { - x := icmp.uCompare(internalKey(a).ukey(), internalKey(b).ukey()) - if x == 0 { - if m, n := internalKey(a).num(), internalKey(b).num(); m > n { - return -1 - } else if m < n { - return 1 - } - } - return x -} - -func (icmp *iComparer) Separator(dst, a, b []byte) []byte { - ua, ub := internalKey(a).ukey(), internalKey(b).ukey() - dst = icmp.uSeparator(dst, ua, ub) - if dst != nil && len(dst) < len(ua) && icmp.uCompare(ua, dst) < 0 { - // Append earliest possible number. - return append(dst, keyMaxNumBytes...) - } - return nil -} - -func (icmp *iComparer) Successor(dst, b []byte) []byte { - ub := internalKey(b).ukey() - dst = icmp.uSuccessor(dst, ub) - if dst != nil && len(dst) < len(ub) && icmp.uCompare(ub, dst) < 0 { - // Append earliest possible number. - return append(dst, keyMaxNumBytes...) - } - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/comparer/bytes_comparer.go b/vendor/github.com/syndtr/goleveldb/leveldb/comparer/bytes_comparer.go deleted file mode 100644 index 14dddf8..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/comparer/bytes_comparer.go +++ /dev/null @@ -1,51 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package comparer - -import "bytes" - -type bytesComparer struct{} - -func (bytesComparer) Compare(a, b []byte) int { - return bytes.Compare(a, b) -} - -func (bytesComparer) Name() string { - return "leveldb.BytewiseComparator" -} - -func (bytesComparer) Separator(dst, a, b []byte) []byte { - i, n := 0, len(a) - if n > len(b) { - n = len(b) - } - for ; i < n && a[i] == b[i]; i++ { - } - if i >= n { - // Do not shorten if one string is a prefix of the other - } else if c := a[i]; c < 0xff && c+1 < b[i] { - dst = append(dst, a[:i+1]...) - dst[i]++ - return dst - } - return nil -} - -func (bytesComparer) Successor(dst, b []byte) []byte { - for i, c := range b { - if c != 0xff { - dst = append(dst, b[:i+1]...) - dst[i]++ - return dst - } - } - return nil -} - -// DefaultComparer are default implementation of the Comparer interface. -// It uses the natural ordering, consistent with bytes.Compare. -var DefaultComparer = bytesComparer{} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/comparer/comparer.go b/vendor/github.com/syndtr/goleveldb/leveldb/comparer/comparer.go deleted file mode 100644 index 14a28f1..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/comparer/comparer.go +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package comparer provides interface and implementation for ordering -// sets of data. -package comparer - -// BasicComparer is the interface that wraps the basic Compare method. -type BasicComparer interface { - // Compare returns -1, 0, or +1 depending on whether a is 'less than', - // 'equal to' or 'greater than' b. The two arguments can only be 'equal' - // if their contents are exactly equal. Furthermore, the empty slice - // must be 'less than' any non-empty slice. - Compare(a, b []byte) int -} - -// Comparer defines a total ordering over the space of []byte keys: a 'less -// than' relationship. -type Comparer interface { - BasicComparer - - // Name returns name of the comparer. - // - // The Level-DB on-disk format stores the comparer name, and opening a - // database with a different comparer from the one it was created with - // will result in an error. - // - // An implementation to a new name whenever the comparer implementation - // changes in a way that will cause the relative ordering of any two keys - // to change. - // - // Names starting with "leveldb." are reserved and should not be used - // by any users of this package. - Name() string - - // Bellow are advanced functions used used to reduce the space requirements - // for internal data structures such as index blocks. - - // Separator appends a sequence of bytes x to dst such that a <= x && x < b, - // where 'less than' is consistent with Compare. An implementation should - // return nil if x equal to a. - // - // Either contents of a or b should not by any means modified. Doing so - // may cause corruption on the internal state. - Separator(dst, a, b []byte) []byte - - // Successor appends a sequence of bytes x to dst such that x >= b, where - // 'less than' is consistent with Compare. An implementation should return - // nil if x equal to b. - // - // Contents of b should not by any means modified. Doing so may cause - // corruption on the internal state. - Successor(dst, b []byte) []byte -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/corrupt_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/corrupt_test.go deleted file mode 100644 index fef2026..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/corrupt_test.go +++ /dev/null @@ -1,496 +0,0 @@ -// Copyright (c) 2013, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "bytes" - "fmt" - "io" - "math/rand" - "testing" - - "github.com/syndtr/goleveldb/leveldb/filter" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -const ctValSize = 1000 - -type dbCorruptHarness struct { - dbHarness -} - -func newDbCorruptHarnessWopt(t *testing.T, o *opt.Options) *dbCorruptHarness { - h := new(dbCorruptHarness) - h.init(t, o) - return h -} - -func newDbCorruptHarness(t *testing.T) *dbCorruptHarness { - return newDbCorruptHarnessWopt(t, &opt.Options{ - BlockCacheCapacity: 100, - Strict: opt.StrictJournalChecksum, - }) -} - -func (h *dbCorruptHarness) recover() { - p := &h.dbHarness - t := p.t - - var err error - p.db, err = Recover(h.stor, h.o) - if err != nil { - t.Fatal("Repair: got error: ", err) - } -} - -func (h *dbCorruptHarness) build(n int) { - p := &h.dbHarness - t := p.t - db := p.db - - batch := new(Batch) - for i := 0; i < n; i++ { - batch.Reset() - batch.Put(tkey(i), tval(i, ctValSize)) - err := db.Write(batch, p.wo) - if err != nil { - t.Fatal("write error: ", err) - } - } -} - -func (h *dbCorruptHarness) buildShuffled(n int, rnd *rand.Rand) { - p := &h.dbHarness - t := p.t - db := p.db - - batch := new(Batch) - for i := range rnd.Perm(n) { - batch.Reset() - batch.Put(tkey(i), tval(i, ctValSize)) - err := db.Write(batch, p.wo) - if err != nil { - t.Fatal("write error: ", err) - } - } -} - -func (h *dbCorruptHarness) deleteRand(n, max int, rnd *rand.Rand) { - p := &h.dbHarness - t := p.t - db := p.db - - batch := new(Batch) - for i := 0; i < n; i++ { - batch.Reset() - batch.Delete(tkey(rnd.Intn(max))) - err := db.Write(batch, p.wo) - if err != nil { - t.Fatal("write error: ", err) - } - } -} - -func (h *dbCorruptHarness) corrupt(ft storage.FileType, fi, offset, n int) { - p := &h.dbHarness - t := p.t - - fds, _ := p.stor.List(ft) - sortFds(fds) - if fi < 0 { - fi = len(fds) - 1 - } - if fi >= len(fds) { - t.Fatalf("no such file with type %q with index %d", ft, fi) - } - - fd := fds[fi] - r, err := h.stor.Open(fd) - if err != nil { - t.Fatal("cannot open file: ", err) - } - x, err := r.Seek(0, 2) - if err != nil { - t.Fatal("cannot query file size: ", err) - } - m := int(x) - if _, err := r.Seek(0, 0); err != nil { - t.Fatal(err) - } - - if offset < 0 { - if -offset > m { - offset = 0 - } else { - offset = m + offset - } - } - if offset > m { - offset = m - } - if offset+n > m { - n = m - offset - } - - buf := make([]byte, m) - _, err = io.ReadFull(r, buf) - if err != nil { - t.Fatal("cannot read file: ", err) - } - r.Close() - - for i := 0; i < n; i++ { - buf[offset+i] ^= 0x80 - } - - err = h.stor.Remove(fd) - if err != nil { - t.Fatal("cannot remove old file: ", err) - } - w, err := h.stor.Create(fd) - if err != nil { - t.Fatal("cannot create new file: ", err) - } - _, err = w.Write(buf) - if err != nil { - t.Fatal("cannot write new file: ", err) - } - w.Close() -} - -func (h *dbCorruptHarness) removeAll(ft storage.FileType) { - fds, err := h.stor.List(ft) - if err != nil { - h.t.Fatal("get files: ", err) - } - for _, fd := range fds { - if err := h.stor.Remove(fd); err != nil { - h.t.Error("remove file: ", err) - } - } -} - -func (h *dbCorruptHarness) forceRemoveAll(ft storage.FileType) { - fds, err := h.stor.List(ft) - if err != nil { - h.t.Fatal("get files: ", err) - } - for _, fd := range fds { - if err := h.stor.ForceRemove(fd); err != nil { - h.t.Error("remove file: ", err) - } - } -} - -func (h *dbCorruptHarness) removeOne(ft storage.FileType) { - fds, err := h.stor.List(ft) - if err != nil { - h.t.Fatal("get files: ", err) - } - fd := fds[rand.Intn(len(fds))] - h.t.Logf("removing file @%d", fd.Num) - if err := h.stor.Remove(fd); err != nil { - h.t.Error("remove file: ", err) - } -} - -func (h *dbCorruptHarness) check(min, max int) { - p := &h.dbHarness - t := p.t - db := p.db - - var n, badk, badv, missed, good int - iter := db.NewIterator(nil, p.ro) - for iter.Next() { - k := 0 - fmt.Sscanf(string(iter.Key()), "%d", &k) - if k < n { - badk++ - continue - } - missed += k - n - n = k + 1 - if !bytes.Equal(iter.Value(), tval(k, ctValSize)) { - badv++ - } else { - good++ - } - } - err := iter.Error() - iter.Release() - t.Logf("want=%d..%d got=%d badkeys=%d badvalues=%d missed=%d, err=%v", - min, max, good, badk, badv, missed, err) - if good < min || good > max { - t.Errorf("good entries number not in range") - } -} - -func TestCorruptDB_Journal(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.build(100) - h.check(100, 100) - h.closeDB() - h.corrupt(storage.TypeJournal, -1, 19, 1) - h.corrupt(storage.TypeJournal, -1, 32*1024+1000, 1) - - h.openDB() - h.check(36, 36) -} - -func TestCorruptDB_Table(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.build(100) - h.compactMem() - h.compactRangeAt(0, "", "") - h.compactRangeAt(1, "", "") - h.closeDB() - h.corrupt(storage.TypeTable, -1, 100, 1) - - h.openDB() - h.check(99, 99) -} - -func TestCorruptDB_TableIndex(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.build(10000) - h.compactMem() - h.closeDB() - h.corrupt(storage.TypeTable, -1, -2000, 500) - - h.openDB() - h.check(5000, 9999) -} - -func TestCorruptDB_MissingManifest(t *testing.T) { - rnd := rand.New(rand.NewSource(0x0badda7a)) - h := newDbCorruptHarnessWopt(t, &opt.Options{ - BlockCacheCapacity: 100, - Strict: opt.StrictJournalChecksum, - WriteBuffer: 1000 * 60, - }) - defer h.close() - - h.build(1000) - h.compactMem() - h.buildShuffled(1000, rnd) - h.compactMem() - h.deleteRand(500, 1000, rnd) - h.compactMem() - h.buildShuffled(1000, rnd) - h.compactMem() - h.deleteRand(500, 1000, rnd) - h.compactMem() - h.buildShuffled(1000, rnd) - h.compactMem() - h.closeDB() - - h.forceRemoveAll(storage.TypeManifest) - h.openAssert(false) - - h.recover() - h.check(1000, 1000) - h.build(1000) - h.compactMem() - h.compactRange("", "") - h.closeDB() - - h.recover() - h.check(1000, 1000) -} - -func TestCorruptDB_SequenceNumberRecovery(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.put("foo", "v1") - h.put("foo", "v2") - h.put("foo", "v3") - h.put("foo", "v4") - h.put("foo", "v5") - h.closeDB() - - h.recover() - h.getVal("foo", "v5") - h.put("foo", "v6") - h.getVal("foo", "v6") - - h.reopenDB() - h.getVal("foo", "v6") -} - -func TestCorruptDB_SequenceNumberRecoveryTable(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.put("foo", "v1") - h.put("foo", "v2") - h.put("foo", "v3") - h.compactMem() - h.put("foo", "v4") - h.put("foo", "v5") - h.compactMem() - h.closeDB() - - h.recover() - h.getVal("foo", "v5") - h.put("foo", "v6") - h.getVal("foo", "v6") - - h.reopenDB() - h.getVal("foo", "v6") -} - -func TestCorruptDB_CorruptedManifest(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.put("foo", "hello") - h.compactMem() - h.compactRange("", "") - h.closeDB() - h.corrupt(storage.TypeManifest, -1, 0, 1000) - h.openAssert(false) - - h.recover() - h.getVal("foo", "hello") -} - -func TestCorruptDB_CompactionInputError(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.build(10) - h.compactMem() - h.closeDB() - h.corrupt(storage.TypeTable, -1, 100, 1) - - h.openDB() - h.check(9, 9) - - h.build(10000) - h.check(10000, 10000) -} - -func TestCorruptDB_UnrelatedKeys(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.build(10) - h.compactMem() - h.closeDB() - h.corrupt(storage.TypeTable, -1, 100, 1) - - h.openDB() - h.put(string(tkey(1000)), string(tval(1000, ctValSize))) - h.getVal(string(tkey(1000)), string(tval(1000, ctValSize))) - h.compactMem() - h.getVal(string(tkey(1000)), string(tval(1000, ctValSize))) -} - -func TestCorruptDB_Level0NewerFileHasOlderSeqnum(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.put("a", "v1") - h.put("b", "v1") - h.compactMem() - h.put("a", "v2") - h.put("b", "v2") - h.compactMem() - h.put("a", "v3") - h.put("b", "v3") - h.compactMem() - h.put("c", "v0") - h.put("d", "v0") - h.compactMem() - h.compactRangeAt(1, "", "") - h.closeDB() - - h.recover() - h.getVal("a", "v3") - h.getVal("b", "v3") - h.getVal("c", "v0") - h.getVal("d", "v0") -} - -func TestCorruptDB_RecoverInvalidSeq_Issue53(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.put("a", "v1") - h.put("b", "v1") - h.compactMem() - h.put("a", "v2") - h.put("b", "v2") - h.compactMem() - h.put("a", "v3") - h.put("b", "v3") - h.compactMem() - h.put("c", "v0") - h.put("d", "v0") - h.compactMem() - h.compactRangeAt(0, "", "") - h.closeDB() - - h.recover() - h.getVal("a", "v3") - h.getVal("b", "v3") - h.getVal("c", "v0") - h.getVal("d", "v0") -} - -func TestCorruptDB_MissingTableFiles(t *testing.T) { - h := newDbCorruptHarness(t) - defer h.close() - - h.put("a", "v1") - h.put("b", "v1") - h.compactMem() - h.put("c", "v2") - h.put("d", "v2") - h.compactMem() - h.put("e", "v3") - h.put("f", "v3") - h.closeDB() - - h.removeOne(storage.TypeTable) - h.openAssert(false) -} - -func TestCorruptDB_RecoverTable(t *testing.T) { - h := newDbCorruptHarnessWopt(t, &opt.Options{ - WriteBuffer: 112 * opt.KiB, - CompactionTableSize: 90 * opt.KiB, - Filter: filter.NewBloomFilter(10), - }) - defer h.close() - - h.build(1000) - h.compactMem() - h.compactRangeAt(0, "", "") - h.compactRangeAt(1, "", "") - seq := h.db.seq - h.closeDB() - h.corrupt(storage.TypeTable, 0, 1000, 1) - h.corrupt(storage.TypeTable, 3, 10000, 1) - // Corrupted filter shouldn't affect recovery. - h.corrupt(storage.TypeTable, 3, 113888, 10) - h.corrupt(storage.TypeTable, -1, 20000, 1) - - h.recover() - if h.db.seq != seq { - t.Errorf("invalid seq, want=%d got=%d", seq, h.db.seq) - } - h.check(985, 985) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db.go b/vendor/github.com/syndtr/goleveldb/leveldb/db.go deleted file mode 100644 index ea5595e..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db.go +++ /dev/null @@ -1,1098 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "container/list" - "fmt" - "io" - "os" - "runtime" - "strings" - "sync" - "sync/atomic" - "time" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/journal" - "github.com/syndtr/goleveldb/leveldb/memdb" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/table" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// DB is a LevelDB database. -type DB struct { - // Need 64-bit alignment. - seq uint64 - - // Stats. Need 64-bit alignment. - cWriteDelay int64 // The cumulative duration of write delays - cWriteDelayN int32 // The cumulative number of write delays - aliveSnaps, aliveIters int32 - - // Session. - s *session - - // MemDB. - memMu sync.RWMutex - memPool chan *memdb.DB - mem, frozenMem *memDB - journal *journal.Writer - journalWriter storage.Writer - journalFd storage.FileDesc - frozenJournalFd storage.FileDesc - frozenSeq uint64 - - // Snapshot. - snapsMu sync.Mutex - snapsList *list.List - - // Write. - batchPool sync.Pool - writeMergeC chan writeMerge - writeMergedC chan bool - writeLockC chan struct{} - writeAckC chan error - writeDelay time.Duration - writeDelayN int - tr *Transaction - - // Compaction. - compCommitLk sync.Mutex - tcompCmdC chan cCmd - tcompPauseC chan chan<- struct{} - mcompCmdC chan cCmd - compErrC chan error - compPerErrC chan error - compErrSetC chan error - compWriteLocking bool - compStats cStats - memdbMaxLevel int // For testing. - - // Close. - closeW sync.WaitGroup - closeC chan struct{} - closed uint32 - closer io.Closer -} - -func openDB(s *session) (*DB, error) { - s.log("db@open opening") - start := time.Now() - db := &DB{ - s: s, - // Initial sequence - seq: s.stSeqNum, - // MemDB - memPool: make(chan *memdb.DB, 1), - // Snapshot - snapsList: list.New(), - // Write - batchPool: sync.Pool{New: newBatch}, - writeMergeC: make(chan writeMerge), - writeMergedC: make(chan bool), - writeLockC: make(chan struct{}, 1), - writeAckC: make(chan error), - // Compaction - tcompCmdC: make(chan cCmd), - tcompPauseC: make(chan chan<- struct{}), - mcompCmdC: make(chan cCmd), - compErrC: make(chan error), - compPerErrC: make(chan error), - compErrSetC: make(chan error), - // Close - closeC: make(chan struct{}), - } - - // Read-only mode. - readOnly := s.o.GetReadOnly() - - if readOnly { - // Recover journals (read-only mode). - if err := db.recoverJournalRO(); err != nil { - return nil, err - } - } else { - // Recover journals. - if err := db.recoverJournal(); err != nil { - return nil, err - } - - // Remove any obsolete files. - if err := db.checkAndCleanFiles(); err != nil { - // Close journal. - if db.journal != nil { - db.journal.Close() - db.journalWriter.Close() - } - return nil, err - } - - } - - // Doesn't need to be included in the wait group. - go db.compactionError() - go db.mpoolDrain() - - if readOnly { - db.SetReadOnly() - } else { - db.closeW.Add(2) - go db.tCompaction() - go db.mCompaction() - // go db.jWriter() - } - - s.logf("db@open done T·%v", time.Since(start)) - - runtime.SetFinalizer(db, (*DB).Close) - return db, nil -} - -// Open opens or creates a DB for the given storage. -// The DB will be created if not exist, unless ErrorIfMissing is true. -// Also, if ErrorIfExist is true and the DB exist Open will returns -// os.ErrExist error. -// -// Open will return an error with type of ErrCorrupted if corruption -// detected in the DB. Use errors.IsCorrupted to test whether an error is -// due to corruption. Corrupted DB can be recovered with Recover function. -// -// The returned DB instance is safe for concurrent use. -// The DB must be closed after use, by calling Close method. -func Open(stor storage.Storage, o *opt.Options) (db *DB, err error) { - s, err := newSession(stor, o) - if err != nil { - return - } - defer func() { - if err != nil { - s.close() - s.release() - } - }() - - err = s.recover() - if err != nil { - if !os.IsNotExist(err) || s.o.GetErrorIfMissing() { - return - } - err = s.create() - if err != nil { - return - } - } else if s.o.GetErrorIfExist() { - err = os.ErrExist - return - } - - return openDB(s) -} - -// OpenFile opens or creates a DB for the given path. -// The DB will be created if not exist, unless ErrorIfMissing is true. -// Also, if ErrorIfExist is true and the DB exist OpenFile will returns -// os.ErrExist error. -// -// OpenFile uses standard file-system backed storage implementation as -// described in the leveldb/storage package. -// -// OpenFile will return an error with type of ErrCorrupted if corruption -// detected in the DB. Use errors.IsCorrupted to test whether an error is -// due to corruption. Corrupted DB can be recovered with Recover function. -// -// The returned DB instance is safe for concurrent use. -// The DB must be closed after use, by calling Close method. -func OpenFile(path string, o *opt.Options) (db *DB, err error) { - stor, err := storage.OpenFile(path, o.GetReadOnly()) - if err != nil { - return - } - db, err = Open(stor, o) - if err != nil { - stor.Close() - } else { - db.closer = stor - } - return -} - -// Recover recovers and opens a DB with missing or corrupted manifest files -// for the given storage. It will ignore any manifest files, valid or not. -// The DB must already exist or it will returns an error. -// Also, Recover will ignore ErrorIfMissing and ErrorIfExist options. -// -// The returned DB instance is safe for concurrent use. -// The DB must be closed after use, by calling Close method. -func Recover(stor storage.Storage, o *opt.Options) (db *DB, err error) { - s, err := newSession(stor, o) - if err != nil { - return - } - defer func() { - if err != nil { - s.close() - s.release() - } - }() - - err = recoverTable(s, o) - if err != nil { - return - } - return openDB(s) -} - -// RecoverFile recovers and opens a DB with missing or corrupted manifest files -// for the given path. It will ignore any manifest files, valid or not. -// The DB must already exist or it will returns an error. -// Also, Recover will ignore ErrorIfMissing and ErrorIfExist options. -// -// RecoverFile uses standard file-system backed storage implementation as described -// in the leveldb/storage package. -// -// The returned DB instance is safe for concurrent use. -// The DB must be closed after use, by calling Close method. -func RecoverFile(path string, o *opt.Options) (db *DB, err error) { - stor, err := storage.OpenFile(path, false) - if err != nil { - return - } - db, err = Recover(stor, o) - if err != nil { - stor.Close() - } else { - db.closer = stor - } - return -} - -func recoverTable(s *session, o *opt.Options) error { - o = dupOptions(o) - // Mask StrictReader, lets StrictRecovery doing its job. - o.Strict &= ^opt.StrictReader - - // Get all tables and sort it by file number. - fds, err := s.stor.List(storage.TypeTable) - if err != nil { - return err - } - sortFds(fds) - - var ( - maxSeq uint64 - recoveredKey, goodKey, corruptedKey, corruptedBlock, droppedTable int - - // We will drop corrupted table. - strict = o.GetStrict(opt.StrictRecovery) - noSync = o.GetNoSync() - - rec = &sessionRecord{} - bpool = util.NewBufferPool(o.GetBlockSize() + 5) - ) - buildTable := func(iter iterator.Iterator) (tmpFd storage.FileDesc, size int64, err error) { - tmpFd = s.newTemp() - writer, err := s.stor.Create(tmpFd) - if err != nil { - return - } - defer func() { - writer.Close() - if err != nil { - s.stor.Remove(tmpFd) - tmpFd = storage.FileDesc{} - } - }() - - // Copy entries. - tw := table.NewWriter(writer, o) - for iter.Next() { - key := iter.Key() - if validInternalKey(key) { - err = tw.Append(key, iter.Value()) - if err != nil { - return - } - } - } - err = iter.Error() - if err != nil && !errors.IsCorrupted(err) { - return - } - err = tw.Close() - if err != nil { - return - } - if !noSync { - err = writer.Sync() - if err != nil { - return - } - } - size = int64(tw.BytesLen()) - return - } - recoverTable := func(fd storage.FileDesc) error { - s.logf("table@recovery recovering @%d", fd.Num) - reader, err := s.stor.Open(fd) - if err != nil { - return err - } - var closed bool - defer func() { - if !closed { - reader.Close() - } - }() - - // Get file size. - size, err := reader.Seek(0, 2) - if err != nil { - return err - } - - var ( - tSeq uint64 - tgoodKey, tcorruptedKey, tcorruptedBlock int - imin, imax []byte - ) - tr, err := table.NewReader(reader, size, fd, nil, bpool, o) - if err != nil { - return err - } - iter := tr.NewIterator(nil, nil) - if itererr, ok := iter.(iterator.ErrorCallbackSetter); ok { - itererr.SetErrorCallback(func(err error) { - if errors.IsCorrupted(err) { - s.logf("table@recovery block corruption @%d %q", fd.Num, err) - tcorruptedBlock++ - } - }) - } - - // Scan the table. - for iter.Next() { - key := iter.Key() - _, seq, _, kerr := parseInternalKey(key) - if kerr != nil { - tcorruptedKey++ - continue - } - tgoodKey++ - if seq > tSeq { - tSeq = seq - } - if imin == nil { - imin = append([]byte{}, key...) - } - imax = append(imax[:0], key...) - } - if err := iter.Error(); err != nil && !errors.IsCorrupted(err) { - iter.Release() - return err - } - iter.Release() - - goodKey += tgoodKey - corruptedKey += tcorruptedKey - corruptedBlock += tcorruptedBlock - - if strict && (tcorruptedKey > 0 || tcorruptedBlock > 0) { - droppedTable++ - s.logf("table@recovery dropped @%d Gk·%d Ck·%d Cb·%d S·%d Q·%d", fd.Num, tgoodKey, tcorruptedKey, tcorruptedBlock, size, tSeq) - return nil - } - - if tgoodKey > 0 { - if tcorruptedKey > 0 || tcorruptedBlock > 0 { - // Rebuild the table. - s.logf("table@recovery rebuilding @%d", fd.Num) - iter := tr.NewIterator(nil, nil) - tmpFd, newSize, err := buildTable(iter) - iter.Release() - if err != nil { - return err - } - closed = true - reader.Close() - if err := s.stor.Rename(tmpFd, fd); err != nil { - return err - } - size = newSize - } - if tSeq > maxSeq { - maxSeq = tSeq - } - recoveredKey += tgoodKey - // Add table to level 0. - rec.addTable(0, fd.Num, size, imin, imax) - s.logf("table@recovery recovered @%d Gk·%d Ck·%d Cb·%d S·%d Q·%d", fd.Num, tgoodKey, tcorruptedKey, tcorruptedBlock, size, tSeq) - } else { - droppedTable++ - s.logf("table@recovery unrecoverable @%d Ck·%d Cb·%d S·%d", fd.Num, tcorruptedKey, tcorruptedBlock, size) - } - - return nil - } - - // Recover all tables. - if len(fds) > 0 { - s.logf("table@recovery F·%d", len(fds)) - - // Mark file number as used. - s.markFileNum(fds[len(fds)-1].Num) - - for _, fd := range fds { - if err := recoverTable(fd); err != nil { - return err - } - } - - s.logf("table@recovery recovered F·%d N·%d Gk·%d Ck·%d Q·%d", len(fds), recoveredKey, goodKey, corruptedKey, maxSeq) - } - - // Set sequence number. - rec.setSeqNum(maxSeq) - - // Create new manifest. - if err := s.create(); err != nil { - return err - } - - // Commit. - return s.commit(rec) -} - -func (db *DB) recoverJournal() error { - // Get all journals and sort it by file number. - rawFds, err := db.s.stor.List(storage.TypeJournal) - if err != nil { - return err - } - sortFds(rawFds) - - // Journals that will be recovered. - var fds []storage.FileDesc - for _, fd := range rawFds { - if fd.Num >= db.s.stJournalNum || fd.Num == db.s.stPrevJournalNum { - fds = append(fds, fd) - } - } - - var ( - ofd storage.FileDesc // Obsolete file. - rec = &sessionRecord{} - ) - - // Recover journals. - if len(fds) > 0 { - db.logf("journal@recovery F·%d", len(fds)) - - // Mark file number as used. - db.s.markFileNum(fds[len(fds)-1].Num) - - var ( - // Options. - strict = db.s.o.GetStrict(opt.StrictJournal) - checksum = db.s.o.GetStrict(opt.StrictJournalChecksum) - writeBuffer = db.s.o.GetWriteBuffer() - - jr *journal.Reader - mdb = memdb.New(db.s.icmp, writeBuffer) - buf = &util.Buffer{} - batchSeq uint64 - batchLen int - ) - - for _, fd := range fds { - db.logf("journal@recovery recovering @%d", fd.Num) - - fr, err := db.s.stor.Open(fd) - if err != nil { - return err - } - - // Create or reset journal reader instance. - if jr == nil { - jr = journal.NewReader(fr, dropper{db.s, fd}, strict, checksum) - } else { - jr.Reset(fr, dropper{db.s, fd}, strict, checksum) - } - - // Flush memdb and remove obsolete journal file. - if !ofd.Zero() { - if mdb.Len() > 0 { - if _, err := db.s.flushMemdb(rec, mdb, 0); err != nil { - fr.Close() - return err - } - } - - rec.setJournalNum(fd.Num) - rec.setSeqNum(db.seq) - if err := db.s.commit(rec); err != nil { - fr.Close() - return err - } - rec.resetAddedTables() - - db.s.stor.Remove(ofd) - ofd = storage.FileDesc{} - } - - // Replay journal to memdb. - mdb.Reset() - for { - r, err := jr.Next() - if err != nil { - if err == io.EOF { - break - } - - fr.Close() - return errors.SetFd(err, fd) - } - - buf.Reset() - if _, err := buf.ReadFrom(r); err != nil { - if err == io.ErrUnexpectedEOF { - // This is error returned due to corruption, with strict == false. - continue - } - - fr.Close() - return errors.SetFd(err, fd) - } - batchSeq, batchLen, err = decodeBatchToMem(buf.Bytes(), db.seq, mdb) - if err != nil { - if !strict && errors.IsCorrupted(err) { - db.s.logf("journal error: %v (skipped)", err) - // We won't apply sequence number as it might be corrupted. - continue - } - - fr.Close() - return errors.SetFd(err, fd) - } - - // Save sequence number. - db.seq = batchSeq + uint64(batchLen) - - // Flush it if large enough. - if mdb.Size() >= writeBuffer { - if _, err := db.s.flushMemdb(rec, mdb, 0); err != nil { - fr.Close() - return err - } - - mdb.Reset() - } - } - - fr.Close() - ofd = fd - } - - // Flush the last memdb. - if mdb.Len() > 0 { - if _, err := db.s.flushMemdb(rec, mdb, 0); err != nil { - return err - } - } - } - - // Create a new journal. - if _, err := db.newMem(0); err != nil { - return err - } - - // Commit. - rec.setJournalNum(db.journalFd.Num) - rec.setSeqNum(db.seq) - if err := db.s.commit(rec); err != nil { - // Close journal on error. - if db.journal != nil { - db.journal.Close() - db.journalWriter.Close() - } - return err - } - - // Remove the last obsolete journal file. - if !ofd.Zero() { - db.s.stor.Remove(ofd) - } - - return nil -} - -func (db *DB) recoverJournalRO() error { - // Get all journals and sort it by file number. - rawFds, err := db.s.stor.List(storage.TypeJournal) - if err != nil { - return err - } - sortFds(rawFds) - - // Journals that will be recovered. - var fds []storage.FileDesc - for _, fd := range rawFds { - if fd.Num >= db.s.stJournalNum || fd.Num == db.s.stPrevJournalNum { - fds = append(fds, fd) - } - } - - var ( - // Options. - strict = db.s.o.GetStrict(opt.StrictJournal) - checksum = db.s.o.GetStrict(opt.StrictJournalChecksum) - writeBuffer = db.s.o.GetWriteBuffer() - - mdb = memdb.New(db.s.icmp, writeBuffer) - ) - - // Recover journals. - if len(fds) > 0 { - db.logf("journal@recovery RO·Mode F·%d", len(fds)) - - var ( - jr *journal.Reader - buf = &util.Buffer{} - batchSeq uint64 - batchLen int - ) - - for _, fd := range fds { - db.logf("journal@recovery recovering @%d", fd.Num) - - fr, err := db.s.stor.Open(fd) - if err != nil { - return err - } - - // Create or reset journal reader instance. - if jr == nil { - jr = journal.NewReader(fr, dropper{db.s, fd}, strict, checksum) - } else { - jr.Reset(fr, dropper{db.s, fd}, strict, checksum) - } - - // Replay journal to memdb. - for { - r, err := jr.Next() - if err != nil { - if err == io.EOF { - break - } - - fr.Close() - return errors.SetFd(err, fd) - } - - buf.Reset() - if _, err := buf.ReadFrom(r); err != nil { - if err == io.ErrUnexpectedEOF { - // This is error returned due to corruption, with strict == false. - continue - } - - fr.Close() - return errors.SetFd(err, fd) - } - batchSeq, batchLen, err = decodeBatchToMem(buf.Bytes(), db.seq, mdb) - if err != nil { - if !strict && errors.IsCorrupted(err) { - db.s.logf("journal error: %v (skipped)", err) - // We won't apply sequence number as it might be corrupted. - continue - } - - fr.Close() - return errors.SetFd(err, fd) - } - - // Save sequence number. - db.seq = batchSeq + uint64(batchLen) - } - - fr.Close() - } - } - - // Set memDB. - db.mem = &memDB{db: db, DB: mdb, ref: 1} - - return nil -} - -func memGet(mdb *memdb.DB, ikey internalKey, icmp *iComparer) (ok bool, mv []byte, err error) { - mk, mv, err := mdb.Find(ikey) - if err == nil { - ukey, _, kt, kerr := parseInternalKey(mk) - if kerr != nil { - // Shouldn't have had happen. - panic(kerr) - } - if icmp.uCompare(ukey, ikey.ukey()) == 0 { - if kt == keyTypeDel { - return true, nil, ErrNotFound - } - return true, mv, nil - - } - } else if err != ErrNotFound { - return true, nil, err - } - return -} - -func (db *DB) get(auxm *memdb.DB, auxt tFiles, key []byte, seq uint64, ro *opt.ReadOptions) (value []byte, err error) { - ikey := makeInternalKey(nil, key, seq, keyTypeSeek) - - if auxm != nil { - if ok, mv, me := memGet(auxm, ikey, db.s.icmp); ok { - return append([]byte{}, mv...), me - } - } - - em, fm := db.getMems() - for _, m := range [...]*memDB{em, fm} { - if m == nil { - continue - } - defer m.decref() - - if ok, mv, me := memGet(m.DB, ikey, db.s.icmp); ok { - return append([]byte{}, mv...), me - } - } - - v := db.s.version() - value, cSched, err := v.get(auxt, ikey, ro, false) - v.release() - if cSched { - // Trigger table compaction. - db.compTrigger(db.tcompCmdC) - } - return -} - -func nilIfNotFound(err error) error { - if err == ErrNotFound { - return nil - } - return err -} - -func (db *DB) has(auxm *memdb.DB, auxt tFiles, key []byte, seq uint64, ro *opt.ReadOptions) (ret bool, err error) { - ikey := makeInternalKey(nil, key, seq, keyTypeSeek) - - if auxm != nil { - if ok, _, me := memGet(auxm, ikey, db.s.icmp); ok { - return me == nil, nilIfNotFound(me) - } - } - - em, fm := db.getMems() - for _, m := range [...]*memDB{em, fm} { - if m == nil { - continue - } - defer m.decref() - - if ok, _, me := memGet(m.DB, ikey, db.s.icmp); ok { - return me == nil, nilIfNotFound(me) - } - } - - v := db.s.version() - _, cSched, err := v.get(auxt, ikey, ro, true) - v.release() - if cSched { - // Trigger table compaction. - db.compTrigger(db.tcompCmdC) - } - if err == nil { - ret = true - } else if err == ErrNotFound { - err = nil - } - return -} - -// Get gets the value for the given key. It returns ErrNotFound if the -// DB does not contains the key. -// -// The returned slice is its own copy, it is safe to modify the contents -// of the returned slice. -// It is safe to modify the contents of the argument after Get returns. -func (db *DB) Get(key []byte, ro *opt.ReadOptions) (value []byte, err error) { - err = db.ok() - if err != nil { - return - } - - se := db.acquireSnapshot() - defer db.releaseSnapshot(se) - return db.get(nil, nil, key, se.seq, ro) -} - -// Has returns true if the DB does contains the given key. -// -// It is safe to modify the contents of the argument after Has returns. -func (db *DB) Has(key []byte, ro *opt.ReadOptions) (ret bool, err error) { - err = db.ok() - if err != nil { - return - } - - se := db.acquireSnapshot() - defer db.releaseSnapshot(se) - return db.has(nil, nil, key, se.seq, ro) -} - -// NewIterator returns an iterator for the latest snapshot of the -// underlying DB. -// The returned iterator is not safe for concurrent use, but it is safe to use -// multiple iterators concurrently, with each in a dedicated goroutine. -// It is also safe to use an iterator concurrently with modifying its -// underlying DB. The resultant key/value pairs are guaranteed to be -// consistent. -// -// Slice allows slicing the iterator to only contains keys in the given -// range. A nil Range.Start is treated as a key before all keys in the -// DB. And a nil Range.Limit is treated as a key after all keys in -// the DB. -// -// The iterator must be released after use, by calling Release method. -// -// Also read Iterator documentation of the leveldb/iterator package. -func (db *DB) NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator { - if err := db.ok(); err != nil { - return iterator.NewEmptyIterator(err) - } - - se := db.acquireSnapshot() - defer db.releaseSnapshot(se) - // Iterator holds 'version' lock, 'version' is immutable so snapshot - // can be released after iterator created. - return db.newIterator(nil, nil, se.seq, slice, ro) -} - -// GetSnapshot returns a latest snapshot of the underlying DB. A snapshot -// is a frozen snapshot of a DB state at a particular point in time. The -// content of snapshot are guaranteed to be consistent. -// -// The snapshot must be released after use, by calling Release method. -func (db *DB) GetSnapshot() (*Snapshot, error) { - if err := db.ok(); err != nil { - return nil, err - } - - return db.newSnapshot(), nil -} - -// GetProperty returns value of the given property name. -// -// Property names: -// leveldb.num-files-at-level{n} -// Returns the number of files at level 'n'. -// leveldb.stats -// Returns statistics of the underlying DB. -// leveldb.writedelay -// Returns cumulative write delay caused by compaction. -// leveldb.sstables -// Returns sstables list for each level. -// leveldb.blockpool -// Returns block pool stats. -// leveldb.cachedblock -// Returns size of cached block. -// leveldb.openedtables -// Returns number of opened tables. -// leveldb.alivesnaps -// Returns number of alive snapshots. -// leveldb.aliveiters -// Returns number of alive iterators. -func (db *DB) GetProperty(name string) (value string, err error) { - err = db.ok() - if err != nil { - return - } - - const prefix = "leveldb." - if !strings.HasPrefix(name, prefix) { - return "", ErrNotFound - } - p := name[len(prefix):] - - v := db.s.version() - defer v.release() - - numFilesPrefix := "num-files-at-level" - switch { - case strings.HasPrefix(p, numFilesPrefix): - var level uint - var rest string - n, _ := fmt.Sscanf(p[len(numFilesPrefix):], "%d%s", &level, &rest) - if n != 1 { - err = ErrNotFound - } else { - value = fmt.Sprint(v.tLen(int(level))) - } - case p == "stats": - value = "Compactions\n" + - " Level | Tables | Size(MB) | Time(sec) | Read(MB) | Write(MB)\n" + - "-------+------------+---------------+---------------+---------------+---------------\n" - for level, tables := range v.levels { - duration, read, write := db.compStats.getStat(level) - if len(tables) == 0 && duration == 0 { - continue - } - value += fmt.Sprintf(" %3d | %10d | %13.5f | %13.5f | %13.5f | %13.5f\n", - level, len(tables), float64(tables.size())/1048576.0, duration.Seconds(), - float64(read)/1048576.0, float64(write)/1048576.0) - } - case p == "writedelay": - writeDelayN, writeDelay := atomic.LoadInt32(&db.cWriteDelayN), time.Duration(atomic.LoadInt64(&db.cWriteDelay)) - value = fmt.Sprintf("DelayN:%d Delay:%s", writeDelayN, writeDelay) - case p == "sstables": - for level, tables := range v.levels { - value += fmt.Sprintf("--- level %d ---\n", level) - for _, t := range tables { - value += fmt.Sprintf("%d:%d[%q .. %q]\n", t.fd.Num, t.size, t.imin, t.imax) - } - } - case p == "blockpool": - value = fmt.Sprintf("%v", db.s.tops.bpool) - case p == "cachedblock": - if db.s.tops.bcache != nil { - value = fmt.Sprintf("%d", db.s.tops.bcache.Size()) - } else { - value = "" - } - case p == "openedtables": - value = fmt.Sprintf("%d", db.s.tops.cache.Size()) - case p == "alivesnaps": - value = fmt.Sprintf("%d", atomic.LoadInt32(&db.aliveSnaps)) - case p == "aliveiters": - value = fmt.Sprintf("%d", atomic.LoadInt32(&db.aliveIters)) - default: - err = ErrNotFound - } - - return -} - -// SizeOf calculates approximate sizes of the given key ranges. -// The length of the returned sizes are equal with the length of the given -// ranges. The returned sizes measure storage space usage, so if the user -// data compresses by a factor of ten, the returned sizes will be one-tenth -// the size of the corresponding user data size. -// The results may not include the sizes of recently written data. -func (db *DB) SizeOf(ranges []util.Range) (Sizes, error) { - if err := db.ok(); err != nil { - return nil, err - } - - v := db.s.version() - defer v.release() - - sizes := make(Sizes, 0, len(ranges)) - for _, r := range ranges { - imin := makeInternalKey(nil, r.Start, keyMaxSeq, keyTypeSeek) - imax := makeInternalKey(nil, r.Limit, keyMaxSeq, keyTypeSeek) - start, err := v.offsetOf(imin) - if err != nil { - return nil, err - } - limit, err := v.offsetOf(imax) - if err != nil { - return nil, err - } - var size int64 - if limit >= start { - size = limit - start - } - sizes = append(sizes, size) - } - - return sizes, nil -} - -// Close closes the DB. This will also releases any outstanding snapshot, -// abort any in-flight compaction and discard open transaction. -// -// It is not safe to close a DB until all outstanding iterators are released. -// It is valid to call Close multiple times. Other methods should not be -// called after the DB has been closed. -func (db *DB) Close() error { - if !db.setClosed() { - return ErrClosed - } - - start := time.Now() - db.log("db@close closing") - - // Clear the finalizer. - runtime.SetFinalizer(db, nil) - - // Get compaction error. - var err error - select { - case err = <-db.compErrC: - if err == ErrReadOnly { - err = nil - } - default: - } - - // Signal all goroutines. - close(db.closeC) - - // Discard open transaction. - if db.tr != nil { - db.tr.Discard() - } - - // Acquire writer lock. - db.writeLockC <- struct{}{} - - // Wait for all gorotines to exit. - db.closeW.Wait() - - // Closes journal. - if db.journal != nil { - db.journal.Close() - db.journalWriter.Close() - db.journal = nil - db.journalWriter = nil - } - - if db.writeDelayN > 0 { - db.logf("db@write was delayed N·%d T·%v", db.writeDelayN, db.writeDelay) - } - - // Close session. - db.s.close() - db.logf("db@close done T·%v", time.Since(start)) - db.s.release() - - if db.closer != nil { - if err1 := db.closer.Close(); err == nil { - err = err1 - } - db.closer = nil - } - - // Clear memdbs. - db.clearMems() - - return err -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_compaction.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_compaction.go deleted file mode 100644 index b6563e8..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_compaction.go +++ /dev/null @@ -1,826 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "sync" - "time" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -var ( - errCompactionTransactExiting = errors.New("leveldb: compaction transact exiting") -) - -type cStat struct { - duration time.Duration - read int64 - write int64 -} - -func (p *cStat) add(n *cStatStaging) { - p.duration += n.duration - p.read += n.read - p.write += n.write -} - -func (p *cStat) get() (duration time.Duration, read, write int64) { - return p.duration, p.read, p.write -} - -type cStatStaging struct { - start time.Time - duration time.Duration - on bool - read int64 - write int64 -} - -func (p *cStatStaging) startTimer() { - if !p.on { - p.start = time.Now() - p.on = true - } -} - -func (p *cStatStaging) stopTimer() { - if p.on { - p.duration += time.Since(p.start) - p.on = false - } -} - -type cStats struct { - lk sync.Mutex - stats []cStat -} - -func (p *cStats) addStat(level int, n *cStatStaging) { - p.lk.Lock() - if level >= len(p.stats) { - newStats := make([]cStat, level+1) - copy(newStats, p.stats) - p.stats = newStats - } - p.stats[level].add(n) - p.lk.Unlock() -} - -func (p *cStats) getStat(level int) (duration time.Duration, read, write int64) { - p.lk.Lock() - defer p.lk.Unlock() - if level < len(p.stats) { - return p.stats[level].get() - } - return -} - -func (db *DB) compactionError() { - var err error -noerr: - // No error. - for { - select { - case err = <-db.compErrSetC: - switch { - case err == nil: - case err == ErrReadOnly, errors.IsCorrupted(err): - goto hasperr - default: - goto haserr - } - case <-db.closeC: - return - } - } -haserr: - // Transient error. - for { - select { - case db.compErrC <- err: - case err = <-db.compErrSetC: - switch { - case err == nil: - goto noerr - case err == ErrReadOnly, errors.IsCorrupted(err): - goto hasperr - default: - } - case <-db.closeC: - return - } - } -hasperr: - // Persistent error. - for { - select { - case db.compErrC <- err: - case db.compPerErrC <- err: - case db.writeLockC <- struct{}{}: - // Hold write lock, so that write won't pass-through. - db.compWriteLocking = true - case <-db.closeC: - if db.compWriteLocking { - // We should release the lock or Close will hang. - <-db.writeLockC - } - return - } - } -} - -type compactionTransactCounter int - -func (cnt *compactionTransactCounter) incr() { - *cnt++ -} - -type compactionTransactInterface interface { - run(cnt *compactionTransactCounter) error - revert() error -} - -func (db *DB) compactionTransact(name string, t compactionTransactInterface) { - defer func() { - if x := recover(); x != nil { - if x == errCompactionTransactExiting { - if err := t.revert(); err != nil { - db.logf("%s revert error %q", name, err) - } - } - panic(x) - } - }() - - const ( - backoffMin = 1 * time.Second - backoffMax = 8 * time.Second - backoffMul = 2 * time.Second - ) - var ( - backoff = backoffMin - backoffT = time.NewTimer(backoff) - lastCnt = compactionTransactCounter(0) - - disableBackoff = db.s.o.GetDisableCompactionBackoff() - ) - for n := 0; ; n++ { - // Check whether the DB is closed. - if db.isClosed() { - db.logf("%s exiting", name) - db.compactionExitTransact() - } else if n > 0 { - db.logf("%s retrying N·%d", name, n) - } - - // Execute. - cnt := compactionTransactCounter(0) - err := t.run(&cnt) - if err != nil { - db.logf("%s error I·%d %q", name, cnt, err) - } - - // Set compaction error status. - select { - case db.compErrSetC <- err: - case perr := <-db.compPerErrC: - if err != nil { - db.logf("%s exiting (persistent error %q)", name, perr) - db.compactionExitTransact() - } - case <-db.closeC: - db.logf("%s exiting", name) - db.compactionExitTransact() - } - if err == nil { - return - } - if errors.IsCorrupted(err) { - db.logf("%s exiting (corruption detected)", name) - db.compactionExitTransact() - } - - if !disableBackoff { - // Reset backoff duration if counter is advancing. - if cnt > lastCnt { - backoff = backoffMin - lastCnt = cnt - } - - // Backoff. - backoffT.Reset(backoff) - if backoff < backoffMax { - backoff *= backoffMul - if backoff > backoffMax { - backoff = backoffMax - } - } - select { - case <-backoffT.C: - case <-db.closeC: - db.logf("%s exiting", name) - db.compactionExitTransact() - } - } - } -} - -type compactionTransactFunc struct { - runFunc func(cnt *compactionTransactCounter) error - revertFunc func() error -} - -func (t *compactionTransactFunc) run(cnt *compactionTransactCounter) error { - return t.runFunc(cnt) -} - -func (t *compactionTransactFunc) revert() error { - if t.revertFunc != nil { - return t.revertFunc() - } - return nil -} - -func (db *DB) compactionTransactFunc(name string, run func(cnt *compactionTransactCounter) error, revert func() error) { - db.compactionTransact(name, &compactionTransactFunc{run, revert}) -} - -func (db *DB) compactionExitTransact() { - panic(errCompactionTransactExiting) -} - -func (db *DB) compactionCommit(name string, rec *sessionRecord) { - db.compCommitLk.Lock() - defer db.compCommitLk.Unlock() // Defer is necessary. - db.compactionTransactFunc(name+"@commit", func(cnt *compactionTransactCounter) error { - return db.s.commit(rec) - }, nil) -} - -func (db *DB) memCompaction() { - mdb := db.getFrozenMem() - if mdb == nil { - return - } - defer mdb.decref() - - db.logf("memdb@flush N·%d S·%s", mdb.Len(), shortenb(mdb.Size())) - - // Don't compact empty memdb. - if mdb.Len() == 0 { - db.logf("memdb@flush skipping") - // drop frozen memdb - db.dropFrozenMem() - return - } - - // Pause table compaction. - resumeC := make(chan struct{}) - select { - case db.tcompPauseC <- (chan<- struct{})(resumeC): - case <-db.compPerErrC: - close(resumeC) - resumeC = nil - case <-db.closeC: - db.compactionExitTransact() - } - - var ( - rec = &sessionRecord{} - stats = &cStatStaging{} - flushLevel int - ) - - // Generate tables. - db.compactionTransactFunc("memdb@flush", func(cnt *compactionTransactCounter) (err error) { - stats.startTimer() - flushLevel, err = db.s.flushMemdb(rec, mdb.DB, db.memdbMaxLevel) - stats.stopTimer() - return - }, func() error { - for _, r := range rec.addedTables { - db.logf("memdb@flush revert @%d", r.num) - if err := db.s.stor.Remove(storage.FileDesc{Type: storage.TypeTable, Num: r.num}); err != nil { - return err - } - } - return nil - }) - - rec.setJournalNum(db.journalFd.Num) - rec.setSeqNum(db.frozenSeq) - - // Commit. - stats.startTimer() - db.compactionCommit("memdb", rec) - stats.stopTimer() - - db.logf("memdb@flush committed F·%d T·%v", len(rec.addedTables), stats.duration) - - for _, r := range rec.addedTables { - stats.write += r.size - } - db.compStats.addStat(flushLevel, stats) - - // Drop frozen memdb. - db.dropFrozenMem() - - // Resume table compaction. - if resumeC != nil { - select { - case <-resumeC: - close(resumeC) - case <-db.closeC: - db.compactionExitTransact() - } - } - - // Trigger table compaction. - db.compTrigger(db.tcompCmdC) -} - -type tableCompactionBuilder struct { - db *DB - s *session - c *compaction - rec *sessionRecord - stat0, stat1 *cStatStaging - - snapHasLastUkey bool - snapLastUkey []byte - snapLastSeq uint64 - snapIter int - snapKerrCnt int - snapDropCnt int - - kerrCnt int - dropCnt int - - minSeq uint64 - strict bool - tableSize int - - tw *tWriter -} - -func (b *tableCompactionBuilder) appendKV(key, value []byte) error { - // Create new table if not already. - if b.tw == nil { - // Check for pause event. - if b.db != nil { - select { - case ch := <-b.db.tcompPauseC: - b.db.pauseCompaction(ch) - case <-b.db.closeC: - b.db.compactionExitTransact() - default: - } - } - - // Create new table. - var err error - b.tw, err = b.s.tops.create() - if err != nil { - return err - } - } - - // Write key/value into table. - return b.tw.append(key, value) -} - -func (b *tableCompactionBuilder) needFlush() bool { - return b.tw.tw.BytesLen() >= b.tableSize -} - -func (b *tableCompactionBuilder) flush() error { - t, err := b.tw.finish() - if err != nil { - return err - } - b.rec.addTableFile(b.c.sourceLevel+1, t) - b.stat1.write += t.size - b.s.logf("table@build created L%d@%d N·%d S·%s %q:%q", b.c.sourceLevel+1, t.fd.Num, b.tw.tw.EntriesLen(), shortenb(int(t.size)), t.imin, t.imax) - b.tw = nil - return nil -} - -func (b *tableCompactionBuilder) cleanup() { - if b.tw != nil { - b.tw.drop() - b.tw = nil - } -} - -func (b *tableCompactionBuilder) run(cnt *compactionTransactCounter) error { - snapResumed := b.snapIter > 0 - hasLastUkey := b.snapHasLastUkey // The key might has zero length, so this is necessary. - lastUkey := append([]byte{}, b.snapLastUkey...) - lastSeq := b.snapLastSeq - b.kerrCnt = b.snapKerrCnt - b.dropCnt = b.snapDropCnt - // Restore compaction state. - b.c.restore() - - defer b.cleanup() - - b.stat1.startTimer() - defer b.stat1.stopTimer() - - iter := b.c.newIterator() - defer iter.Release() - for i := 0; iter.Next(); i++ { - // Incr transact counter. - cnt.incr() - - // Skip until last state. - if i < b.snapIter { - continue - } - - resumed := false - if snapResumed { - resumed = true - snapResumed = false - } - - ikey := iter.Key() - ukey, seq, kt, kerr := parseInternalKey(ikey) - - if kerr == nil { - shouldStop := !resumed && b.c.shouldStopBefore(ikey) - - if !hasLastUkey || b.s.icmp.uCompare(lastUkey, ukey) != 0 { - // First occurrence of this user key. - - // Only rotate tables if ukey doesn't hop across. - if b.tw != nil && (shouldStop || b.needFlush()) { - if err := b.flush(); err != nil { - return err - } - - // Creates snapshot of the state. - b.c.save() - b.snapHasLastUkey = hasLastUkey - b.snapLastUkey = append(b.snapLastUkey[:0], lastUkey...) - b.snapLastSeq = lastSeq - b.snapIter = i - b.snapKerrCnt = b.kerrCnt - b.snapDropCnt = b.dropCnt - } - - hasLastUkey = true - lastUkey = append(lastUkey[:0], ukey...) - lastSeq = keyMaxSeq - } - - switch { - case lastSeq <= b.minSeq: - // Dropped because newer entry for same user key exist - fallthrough // (A) - case kt == keyTypeDel && seq <= b.minSeq && b.c.baseLevelForKey(lastUkey): - // For this user key: - // (1) there is no data in higher levels - // (2) data in lower levels will have larger seq numbers - // (3) data in layers that are being compacted here and have - // smaller seq numbers will be dropped in the next - // few iterations of this loop (by rule (A) above). - // Therefore this deletion marker is obsolete and can be dropped. - lastSeq = seq - b.dropCnt++ - continue - default: - lastSeq = seq - } - } else { - if b.strict { - return kerr - } - - // Don't drop corrupted keys. - hasLastUkey = false - lastUkey = lastUkey[:0] - lastSeq = keyMaxSeq - b.kerrCnt++ - } - - if err := b.appendKV(ikey, iter.Value()); err != nil { - return err - } - } - - if err := iter.Error(); err != nil { - return err - } - - // Finish last table. - if b.tw != nil && !b.tw.empty() { - return b.flush() - } - return nil -} - -func (b *tableCompactionBuilder) revert() error { - for _, at := range b.rec.addedTables { - b.s.logf("table@build revert @%d", at.num) - if err := b.s.stor.Remove(storage.FileDesc{Type: storage.TypeTable, Num: at.num}); err != nil { - return err - } - } - return nil -} - -func (db *DB) tableCompaction(c *compaction, noTrivial bool) { - defer c.release() - - rec := &sessionRecord{} - rec.addCompPtr(c.sourceLevel, c.imax) - - if !noTrivial && c.trivial() { - t := c.levels[0][0] - db.logf("table@move L%d@%d -> L%d", c.sourceLevel, t.fd.Num, c.sourceLevel+1) - rec.delTable(c.sourceLevel, t.fd.Num) - rec.addTableFile(c.sourceLevel+1, t) - db.compactionCommit("table-move", rec) - return - } - - var stats [2]cStatStaging - for i, tables := range c.levels { - for _, t := range tables { - stats[i].read += t.size - // Insert deleted tables into record - rec.delTable(c.sourceLevel+i, t.fd.Num) - } - } - sourceSize := int(stats[0].read + stats[1].read) - minSeq := db.minSeq() - db.logf("table@compaction L%d·%d -> L%d·%d S·%s Q·%d", c.sourceLevel, len(c.levels[0]), c.sourceLevel+1, len(c.levels[1]), shortenb(sourceSize), minSeq) - - b := &tableCompactionBuilder{ - db: db, - s: db.s, - c: c, - rec: rec, - stat1: &stats[1], - minSeq: minSeq, - strict: db.s.o.GetStrict(opt.StrictCompaction), - tableSize: db.s.o.GetCompactionTableSize(c.sourceLevel + 1), - } - db.compactionTransact("table@build", b) - - // Commit. - stats[1].startTimer() - db.compactionCommit("table", rec) - stats[1].stopTimer() - - resultSize := int(stats[1].write) - db.logf("table@compaction committed F%s S%s Ke·%d D·%d T·%v", sint(len(rec.addedTables)-len(rec.deletedTables)), sshortenb(resultSize-sourceSize), b.kerrCnt, b.dropCnt, stats[1].duration) - - // Save compaction stats - for i := range stats { - db.compStats.addStat(c.sourceLevel+1, &stats[i]) - } -} - -func (db *DB) tableRangeCompaction(level int, umin, umax []byte) error { - db.logf("table@compaction range L%d %q:%q", level, umin, umax) - if level >= 0 { - if c := db.s.getCompactionRange(level, umin, umax, true); c != nil { - db.tableCompaction(c, true) - } - } else { - // Retry until nothing to compact. - for { - compacted := false - - // Scan for maximum level with overlapped tables. - v := db.s.version() - m := 1 - for i := m; i < len(v.levels); i++ { - tables := v.levels[i] - if tables.overlaps(db.s.icmp, umin, umax, false) { - m = i - } - } - v.release() - - for level := 0; level < m; level++ { - if c := db.s.getCompactionRange(level, umin, umax, false); c != nil { - db.tableCompaction(c, true) - compacted = true - } - } - - if !compacted { - break - } - } - } - - return nil -} - -func (db *DB) tableAutoCompaction() { - if c := db.s.pickCompaction(); c != nil { - db.tableCompaction(c, false) - } -} - -func (db *DB) tableNeedCompaction() bool { - v := db.s.version() - defer v.release() - return v.needCompaction() -} - -func (db *DB) pauseCompaction(ch chan<- struct{}) { - select { - case ch <- struct{}{}: - case <-db.closeC: - db.compactionExitTransact() - } -} - -type cCmd interface { - ack(err error) -} - -type cAuto struct { - ackC chan<- error -} - -func (r cAuto) ack(err error) { - if r.ackC != nil { - defer func() { - recover() - }() - r.ackC <- err - } -} - -type cRange struct { - level int - min, max []byte - ackC chan<- error -} - -func (r cRange) ack(err error) { - if r.ackC != nil { - defer func() { - recover() - }() - r.ackC <- err - } -} - -// This will trigger auto compaction but will not wait for it. -func (db *DB) compTrigger(compC chan<- cCmd) { - select { - case compC <- cAuto{}: - default: - } -} - -// This will trigger auto compaction and/or wait for all compaction to be done. -func (db *DB) compTriggerWait(compC chan<- cCmd) (err error) { - ch := make(chan error) - defer close(ch) - // Send cmd. - select { - case compC <- cAuto{ch}: - case err = <-db.compErrC: - return - case <-db.closeC: - return ErrClosed - } - // Wait cmd. - select { - case err = <-ch: - case err = <-db.compErrC: - case <-db.closeC: - return ErrClosed - } - return err -} - -// Send range compaction request. -func (db *DB) compTriggerRange(compC chan<- cCmd, level int, min, max []byte) (err error) { - ch := make(chan error) - defer close(ch) - // Send cmd. - select { - case compC <- cRange{level, min, max, ch}: - case err := <-db.compErrC: - return err - case <-db.closeC: - return ErrClosed - } - // Wait cmd. - select { - case err = <-ch: - case err = <-db.compErrC: - case <-db.closeC: - return ErrClosed - } - return err -} - -func (db *DB) mCompaction() { - var x cCmd - - defer func() { - if x := recover(); x != nil { - if x != errCompactionTransactExiting { - panic(x) - } - } - if x != nil { - x.ack(ErrClosed) - } - db.closeW.Done() - }() - - for { - select { - case x = <-db.mcompCmdC: - switch x.(type) { - case cAuto: - db.memCompaction() - x.ack(nil) - x = nil - default: - panic("leveldb: unknown command") - } - case <-db.closeC: - return - } - } -} - -func (db *DB) tCompaction() { - var x cCmd - var ackQ []cCmd - - defer func() { - if x := recover(); x != nil { - if x != errCompactionTransactExiting { - panic(x) - } - } - for i := range ackQ { - ackQ[i].ack(ErrClosed) - ackQ[i] = nil - } - if x != nil { - x.ack(ErrClosed) - } - db.closeW.Done() - }() - - for { - if db.tableNeedCompaction() { - select { - case x = <-db.tcompCmdC: - case ch := <-db.tcompPauseC: - db.pauseCompaction(ch) - continue - case <-db.closeC: - return - default: - } - } else { - for i := range ackQ { - ackQ[i].ack(nil) - ackQ[i] = nil - } - ackQ = ackQ[:0] - select { - case x = <-db.tcompCmdC: - case ch := <-db.tcompPauseC: - db.pauseCompaction(ch) - continue - case <-db.closeC: - return - } - } - if x != nil { - switch cmd := x.(type) { - case cAuto: - ackQ = append(ackQ, x) - case cRange: - x.ack(db.tableRangeCompaction(cmd.level, cmd.min, cmd.max)) - default: - panic("leveldb: unknown command") - } - x = nil - } - db.tableAutoCompaction() - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_iter.go deleted file mode 100644 index 03c24cd..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_iter.go +++ /dev/null @@ -1,360 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "errors" - "math/rand" - "runtime" - "sync" - "sync/atomic" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/util" -) - -var ( - errInvalidInternalKey = errors.New("leveldb: Iterator: invalid internal key") -) - -type memdbReleaser struct { - once sync.Once - m *memDB -} - -func (mr *memdbReleaser) Release() { - mr.once.Do(func() { - mr.m.decref() - }) -} - -func (db *DB) newRawIterator(auxm *memDB, auxt tFiles, slice *util.Range, ro *opt.ReadOptions) iterator.Iterator { - strict := opt.GetStrict(db.s.o.Options, ro, opt.StrictReader) - em, fm := db.getMems() - v := db.s.version() - - tableIts := v.getIterators(slice, ro) - n := len(tableIts) + len(auxt) + 3 - its := make([]iterator.Iterator, 0, n) - - if auxm != nil { - ami := auxm.NewIterator(slice) - ami.SetReleaser(&memdbReleaser{m: auxm}) - its = append(its, ami) - } - for _, t := range auxt { - its = append(its, v.s.tops.newIterator(t, slice, ro)) - } - - emi := em.NewIterator(slice) - emi.SetReleaser(&memdbReleaser{m: em}) - its = append(its, emi) - if fm != nil { - fmi := fm.NewIterator(slice) - fmi.SetReleaser(&memdbReleaser{m: fm}) - its = append(its, fmi) - } - its = append(its, tableIts...) - mi := iterator.NewMergedIterator(its, db.s.icmp, strict) - mi.SetReleaser(&versionReleaser{v: v}) - return mi -} - -func (db *DB) newIterator(auxm *memDB, auxt tFiles, seq uint64, slice *util.Range, ro *opt.ReadOptions) *dbIter { - var islice *util.Range - if slice != nil { - islice = &util.Range{} - if slice.Start != nil { - islice.Start = makeInternalKey(nil, slice.Start, keyMaxSeq, keyTypeSeek) - } - if slice.Limit != nil { - islice.Limit = makeInternalKey(nil, slice.Limit, keyMaxSeq, keyTypeSeek) - } - } - rawIter := db.newRawIterator(auxm, auxt, islice, ro) - iter := &dbIter{ - db: db, - icmp: db.s.icmp, - iter: rawIter, - seq: seq, - strict: opt.GetStrict(db.s.o.Options, ro, opt.StrictReader), - key: make([]byte, 0), - value: make([]byte, 0), - } - atomic.AddInt32(&db.aliveIters, 1) - runtime.SetFinalizer(iter, (*dbIter).Release) - return iter -} - -func (db *DB) iterSamplingRate() int { - return rand.Intn(2 * db.s.o.GetIteratorSamplingRate()) -} - -type dir int - -const ( - dirReleased dir = iota - 1 - dirSOI - dirEOI - dirBackward - dirForward -) - -// dbIter represent an interator states over a database session. -type dbIter struct { - db *DB - icmp *iComparer - iter iterator.Iterator - seq uint64 - strict bool - - smaplingGap int - dir dir - key []byte - value []byte - err error - releaser util.Releaser -} - -func (i *dbIter) sampleSeek() { - ikey := i.iter.Key() - i.smaplingGap -= len(ikey) + len(i.iter.Value()) - for i.smaplingGap < 0 { - i.smaplingGap += i.db.iterSamplingRate() - i.db.sampleSeek(ikey) - } -} - -func (i *dbIter) setErr(err error) { - i.err = err - i.key = nil - i.value = nil -} - -func (i *dbIter) iterErr() { - if err := i.iter.Error(); err != nil { - i.setErr(err) - } -} - -func (i *dbIter) Valid() bool { - return i.err == nil && i.dir > dirEOI -} - -func (i *dbIter) First() bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - if i.iter.First() { - i.dir = dirSOI - return i.next() - } - i.dir = dirEOI - i.iterErr() - return false -} - -func (i *dbIter) Last() bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - if i.iter.Last() { - return i.prev() - } - i.dir = dirSOI - i.iterErr() - return false -} - -func (i *dbIter) Seek(key []byte) bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - ikey := makeInternalKey(nil, key, i.seq, keyTypeSeek) - if i.iter.Seek(ikey) { - i.dir = dirSOI - return i.next() - } - i.dir = dirEOI - i.iterErr() - return false -} - -func (i *dbIter) next() bool { - for { - if ukey, seq, kt, kerr := parseInternalKey(i.iter.Key()); kerr == nil { - i.sampleSeek() - if seq <= i.seq { - switch kt { - case keyTypeDel: - // Skip deleted key. - i.key = append(i.key[:0], ukey...) - i.dir = dirForward - case keyTypeVal: - if i.dir == dirSOI || i.icmp.uCompare(ukey, i.key) > 0 { - i.key = append(i.key[:0], ukey...) - i.value = append(i.value[:0], i.iter.Value()...) - i.dir = dirForward - return true - } - } - } - } else if i.strict { - i.setErr(kerr) - break - } - if !i.iter.Next() { - i.dir = dirEOI - i.iterErr() - break - } - } - return false -} - -func (i *dbIter) Next() bool { - if i.dir == dirEOI || i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - if !i.iter.Next() || (i.dir == dirBackward && !i.iter.Next()) { - i.dir = dirEOI - i.iterErr() - return false - } - return i.next() -} - -func (i *dbIter) prev() bool { - i.dir = dirBackward - del := true - if i.iter.Valid() { - for { - if ukey, seq, kt, kerr := parseInternalKey(i.iter.Key()); kerr == nil { - i.sampleSeek() - if seq <= i.seq { - if !del && i.icmp.uCompare(ukey, i.key) < 0 { - return true - } - del = (kt == keyTypeDel) - if !del { - i.key = append(i.key[:0], ukey...) - i.value = append(i.value[:0], i.iter.Value()...) - } - } - } else if i.strict { - i.setErr(kerr) - return false - } - if !i.iter.Prev() { - break - } - } - } - if del { - i.dir = dirSOI - i.iterErr() - return false - } - return true -} - -func (i *dbIter) Prev() bool { - if i.dir == dirSOI || i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - switch i.dir { - case dirEOI: - return i.Last() - case dirForward: - for i.iter.Prev() { - if ukey, _, _, kerr := parseInternalKey(i.iter.Key()); kerr == nil { - i.sampleSeek() - if i.icmp.uCompare(ukey, i.key) < 0 { - goto cont - } - } else if i.strict { - i.setErr(kerr) - return false - } - } - i.dir = dirSOI - i.iterErr() - return false - } - -cont: - return i.prev() -} - -func (i *dbIter) Key() []byte { - if i.err != nil || i.dir <= dirEOI { - return nil - } - return i.key -} - -func (i *dbIter) Value() []byte { - if i.err != nil || i.dir <= dirEOI { - return nil - } - return i.value -} - -func (i *dbIter) Release() { - if i.dir != dirReleased { - // Clear the finalizer. - runtime.SetFinalizer(i, nil) - - if i.releaser != nil { - i.releaser.Release() - i.releaser = nil - } - - i.dir = dirReleased - i.key = nil - i.value = nil - i.iter.Release() - i.iter = nil - atomic.AddInt32(&i.db.aliveIters, -1) - i.db = nil - } -} - -func (i *dbIter) SetReleaser(releaser util.Releaser) { - if i.dir == dirReleased { - panic(util.ErrReleased) - } - if i.releaser != nil && releaser != nil { - panic(util.ErrHasReleaser) - } - i.releaser = releaser -} - -func (i *dbIter) Error() error { - return i.err -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_snapshot.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_snapshot.go deleted file mode 100644 index 2c69d2e..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_snapshot.go +++ /dev/null @@ -1,183 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "container/list" - "fmt" - "runtime" - "sync" - "sync/atomic" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/util" -) - -type snapshotElement struct { - seq uint64 - ref int - e *list.Element -} - -// Acquires a snapshot, based on latest sequence. -func (db *DB) acquireSnapshot() *snapshotElement { - db.snapsMu.Lock() - defer db.snapsMu.Unlock() - - seq := db.getSeq() - - if e := db.snapsList.Back(); e != nil { - se := e.Value.(*snapshotElement) - if se.seq == seq { - se.ref++ - return se - } else if seq < se.seq { - panic("leveldb: sequence number is not increasing") - } - } - se := &snapshotElement{seq: seq, ref: 1} - se.e = db.snapsList.PushBack(se) - return se -} - -// Releases given snapshot element. -func (db *DB) releaseSnapshot(se *snapshotElement) { - db.snapsMu.Lock() - defer db.snapsMu.Unlock() - - se.ref-- - if se.ref == 0 { - db.snapsList.Remove(se.e) - se.e = nil - } else if se.ref < 0 { - panic("leveldb: Snapshot: negative element reference") - } -} - -// Gets minimum sequence that not being snapshotted. -func (db *DB) minSeq() uint64 { - db.snapsMu.Lock() - defer db.snapsMu.Unlock() - - if e := db.snapsList.Front(); e != nil { - return e.Value.(*snapshotElement).seq - } - - return db.getSeq() -} - -// Snapshot is a DB snapshot. -type Snapshot struct { - db *DB - elem *snapshotElement - mu sync.RWMutex - released bool -} - -// Creates new snapshot object. -func (db *DB) newSnapshot() *Snapshot { - snap := &Snapshot{ - db: db, - elem: db.acquireSnapshot(), - } - atomic.AddInt32(&db.aliveSnaps, 1) - runtime.SetFinalizer(snap, (*Snapshot).Release) - return snap -} - -func (snap *Snapshot) String() string { - return fmt.Sprintf("leveldb.Snapshot{%d}", snap.elem.seq) -} - -// Get gets the value for the given key. It returns ErrNotFound if -// the DB does not contains the key. -// -// The caller should not modify the contents of the returned slice, but -// it is safe to modify the contents of the argument after Get returns. -func (snap *Snapshot) Get(key []byte, ro *opt.ReadOptions) (value []byte, err error) { - err = snap.db.ok() - if err != nil { - return - } - snap.mu.RLock() - defer snap.mu.RUnlock() - if snap.released { - err = ErrSnapshotReleased - return - } - return snap.db.get(nil, nil, key, snap.elem.seq, ro) -} - -// Has returns true if the DB does contains the given key. -// -// It is safe to modify the contents of the argument after Get returns. -func (snap *Snapshot) Has(key []byte, ro *opt.ReadOptions) (ret bool, err error) { - err = snap.db.ok() - if err != nil { - return - } - snap.mu.RLock() - defer snap.mu.RUnlock() - if snap.released { - err = ErrSnapshotReleased - return - } - return snap.db.has(nil, nil, key, snap.elem.seq, ro) -} - -// NewIterator returns an iterator for the snapshot of the underlying DB. -// The returned iterator is not safe for concurrent use, but it is safe to use -// multiple iterators concurrently, with each in a dedicated goroutine. -// It is also safe to use an iterator concurrently with modifying its -// underlying DB. The resultant key/value pairs are guaranteed to be -// consistent. -// -// Slice allows slicing the iterator to only contains keys in the given -// range. A nil Range.Start is treated as a key before all keys in the -// DB. And a nil Range.Limit is treated as a key after all keys in -// the DB. -// -// The iterator must be released after use, by calling Release method. -// Releasing the snapshot doesn't mean releasing the iterator too, the -// iterator would be still valid until released. -// -// Also read Iterator documentation of the leveldb/iterator package. -func (snap *Snapshot) NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator { - if err := snap.db.ok(); err != nil { - return iterator.NewEmptyIterator(err) - } - snap.mu.Lock() - defer snap.mu.Unlock() - if snap.released { - return iterator.NewEmptyIterator(ErrSnapshotReleased) - } - // Since iterator already hold version ref, it doesn't need to - // hold snapshot ref. - return snap.db.newIterator(nil, nil, snap.elem.seq, slice, ro) -} - -// Release releases the snapshot. This will not release any returned -// iterators, the iterators would still be valid until released or the -// underlying DB is closed. -// -// Other methods should not be called after the snapshot has been released. -func (snap *Snapshot) Release() { - snap.mu.Lock() - defer snap.mu.Unlock() - - if !snap.released { - // Clear the finalizer. - runtime.SetFinalizer(snap, nil) - - snap.released = true - snap.db.releaseSnapshot(snap.elem) - atomic.AddInt32(&snap.db.aliveSnaps, -1) - snap.db = nil - snap.elem = nil - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_state.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_state.go deleted file mode 100644 index 65e1c54..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_state.go +++ /dev/null @@ -1,239 +0,0 @@ -// Copyright (c) 2013, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "errors" - "sync/atomic" - "time" - - "github.com/syndtr/goleveldb/leveldb/journal" - "github.com/syndtr/goleveldb/leveldb/memdb" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -var ( - errHasFrozenMem = errors.New("has frozen mem") -) - -type memDB struct { - db *DB - *memdb.DB - ref int32 -} - -func (m *memDB) getref() int32 { - return atomic.LoadInt32(&m.ref) -} - -func (m *memDB) incref() { - atomic.AddInt32(&m.ref, 1) -} - -func (m *memDB) decref() { - if ref := atomic.AddInt32(&m.ref, -1); ref == 0 { - // Only put back memdb with std capacity. - if m.Capacity() == m.db.s.o.GetWriteBuffer() { - m.Reset() - m.db.mpoolPut(m.DB) - } - m.db = nil - m.DB = nil - } else if ref < 0 { - panic("negative memdb ref") - } -} - -// Get latest sequence number. -func (db *DB) getSeq() uint64 { - return atomic.LoadUint64(&db.seq) -} - -// Atomically adds delta to seq. -func (db *DB) addSeq(delta uint64) { - atomic.AddUint64(&db.seq, delta) -} - -func (db *DB) setSeq(seq uint64) { - atomic.StoreUint64(&db.seq, seq) -} - -func (db *DB) sampleSeek(ikey internalKey) { - v := db.s.version() - if v.sampleSeek(ikey) { - // Trigger table compaction. - db.compTrigger(db.tcompCmdC) - } - v.release() -} - -func (db *DB) mpoolPut(mem *memdb.DB) { - if !db.isClosed() { - select { - case db.memPool <- mem: - default: - } - } -} - -func (db *DB) mpoolGet(n int) *memDB { - var mdb *memdb.DB - select { - case mdb = <-db.memPool: - default: - } - if mdb == nil || mdb.Capacity() < n { - mdb = memdb.New(db.s.icmp, maxInt(db.s.o.GetWriteBuffer(), n)) - } - return &memDB{ - db: db, - DB: mdb, - } -} - -func (db *DB) mpoolDrain() { - ticker := time.NewTicker(30 * time.Second) - for { - select { - case <-ticker.C: - select { - case <-db.memPool: - default: - } - case <-db.closeC: - ticker.Stop() - // Make sure the pool is drained. - select { - case <-db.memPool: - case <-time.After(time.Second): - } - close(db.memPool) - return - } - } -} - -// Create new memdb and froze the old one; need external synchronization. -// newMem only called synchronously by the writer. -func (db *DB) newMem(n int) (mem *memDB, err error) { - fd := storage.FileDesc{Type: storage.TypeJournal, Num: db.s.allocFileNum()} - w, err := db.s.stor.Create(fd) - if err != nil { - db.s.reuseFileNum(fd.Num) - return - } - - db.memMu.Lock() - defer db.memMu.Unlock() - - if db.frozenMem != nil { - return nil, errHasFrozenMem - } - - if db.journal == nil { - db.journal = journal.NewWriter(w) - } else { - db.journal.Reset(w) - db.journalWriter.Close() - db.frozenJournalFd = db.journalFd - } - db.journalWriter = w - db.journalFd = fd - db.frozenMem = db.mem - mem = db.mpoolGet(n) - mem.incref() // for self - mem.incref() // for caller - db.mem = mem - // The seq only incremented by the writer. And whoever called newMem - // should hold write lock, so no need additional synchronization here. - db.frozenSeq = db.seq - return -} - -// Get all memdbs. -func (db *DB) getMems() (e, f *memDB) { - db.memMu.RLock() - defer db.memMu.RUnlock() - if db.mem != nil { - db.mem.incref() - } else if !db.isClosed() { - panic("nil effective mem") - } - if db.frozenMem != nil { - db.frozenMem.incref() - } - return db.mem, db.frozenMem -} - -// Get effective memdb. -func (db *DB) getEffectiveMem() *memDB { - db.memMu.RLock() - defer db.memMu.RUnlock() - if db.mem != nil { - db.mem.incref() - } else if !db.isClosed() { - panic("nil effective mem") - } - return db.mem -} - -// Check whether we has frozen memdb. -func (db *DB) hasFrozenMem() bool { - db.memMu.RLock() - defer db.memMu.RUnlock() - return db.frozenMem != nil -} - -// Get frozen memdb. -func (db *DB) getFrozenMem() *memDB { - db.memMu.RLock() - defer db.memMu.RUnlock() - if db.frozenMem != nil { - db.frozenMem.incref() - } - return db.frozenMem -} - -// Drop frozen memdb; assume that frozen memdb isn't nil. -func (db *DB) dropFrozenMem() { - db.memMu.Lock() - if err := db.s.stor.Remove(db.frozenJournalFd); err != nil { - db.logf("journal@remove removing @%d %q", db.frozenJournalFd.Num, err) - } else { - db.logf("journal@remove removed @%d", db.frozenJournalFd.Num) - } - db.frozenJournalFd = storage.FileDesc{} - db.frozenMem.decref() - db.frozenMem = nil - db.memMu.Unlock() -} - -// Clear mems ptr; used by DB.Close(). -func (db *DB) clearMems() { - db.memMu.Lock() - db.mem = nil - db.frozenMem = nil - db.memMu.Unlock() -} - -// Set closed flag; return true if not already closed. -func (db *DB) setClosed() bool { - return atomic.CompareAndSwapUint32(&db.closed, 0, 1) -} - -// Check whether DB was closed. -func (db *DB) isClosed() bool { - return atomic.LoadUint32(&db.closed) != 0 -} - -// Check read ok status. -func (db *DB) ok() error { - if db.isClosed() { - return ErrClosed - } - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_test.go deleted file mode 100644 index e985709..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_test.go +++ /dev/null @@ -1,2926 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "bytes" - "container/list" - crand "crypto/rand" - "encoding/binary" - "fmt" - "math/rand" - "os" - "path/filepath" - "runtime" - "strings" - "sync" - "sync/atomic" - "testing" - "time" - "unsafe" - - "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/filter" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/testutil" - "github.com/syndtr/goleveldb/leveldb/util" -) - -func tkey(i int) []byte { - return []byte(fmt.Sprintf("%016d", i)) -} - -func tval(seed, n int) []byte { - r := rand.New(rand.NewSource(int64(seed))) - return randomString(r, n) -} - -func testingLogger(t *testing.T) func(log string) { - return func(log string) { - t.Log(log) - } -} - -func testingPreserveOnFailed(t *testing.T) func() (preserve bool, err error) { - return func() (preserve bool, err error) { - preserve = t.Failed() - return - } -} - -type dbHarness struct { - t *testing.T - - stor *testutil.Storage - db *DB - o *opt.Options - ro *opt.ReadOptions - wo *opt.WriteOptions -} - -func newDbHarnessWopt(t *testing.T, o *opt.Options) *dbHarness { - h := new(dbHarness) - h.init(t, o) - return h -} - -func newDbHarness(t *testing.T) *dbHarness { - return newDbHarnessWopt(t, &opt.Options{DisableLargeBatchTransaction: true}) -} - -func (h *dbHarness) init(t *testing.T, o *opt.Options) { - gomega.RegisterTestingT(t) - h.t = t - h.stor = testutil.NewStorage() - h.stor.OnLog(testingLogger(t)) - h.stor.OnClose(testingPreserveOnFailed(t)) - h.o = o - h.ro = nil - h.wo = nil - - if err := h.openDB0(); err != nil { - // So that it will come after fatal message. - defer h.stor.Close() - h.t.Fatal("Open (init): got error: ", err) - } -} - -func (h *dbHarness) openDB0() (err error) { - h.t.Log("opening DB") - h.db, err = Open(h.stor, h.o) - return -} - -func (h *dbHarness) openDB() { - if err := h.openDB0(); err != nil { - h.t.Fatal("Open: got error: ", err) - } -} - -func (h *dbHarness) closeDB0() error { - h.t.Log("closing DB") - return h.db.Close() -} - -func (h *dbHarness) closeDB() { - if h.db != nil { - if err := h.closeDB0(); err != nil { - h.t.Error("Close: got error: ", err) - } - } - h.stor.CloseCheck() - runtime.GC() -} - -func (h *dbHarness) reopenDB() { - if h.db != nil { - h.closeDB() - } - h.openDB() -} - -func (h *dbHarness) close() { - if h.db != nil { - h.closeDB0() - h.db = nil - } - h.stor.Close() - h.stor = nil - runtime.GC() -} - -func (h *dbHarness) openAssert(want bool) { - db, err := Open(h.stor, h.o) - if err != nil { - if want { - h.t.Error("Open: assert: got error: ", err) - } else { - h.t.Log("Open: assert: got error (expected): ", err) - } - } else { - if !want { - h.t.Error("Open: assert: expect error") - } - db.Close() - } -} - -func (h *dbHarness) write(batch *Batch) { - if err := h.db.Write(batch, h.wo); err != nil { - h.t.Error("Write: got error: ", err) - } -} - -func (h *dbHarness) put(key, value string) { - if err := h.db.Put([]byte(key), []byte(value), h.wo); err != nil { - h.t.Error("Put: got error: ", err) - } -} - -func (h *dbHarness) putMulti(n int, low, hi string) { - for i := 0; i < n; i++ { - h.put(low, "begin") - h.put(hi, "end") - h.compactMem() - } -} - -func (h *dbHarness) maxNextLevelOverlappingBytes(want int64) { - t := h.t - db := h.db - - var ( - maxOverlaps int64 - maxLevel int - ) - v := db.s.version() - if len(v.levels) > 2 { - for i, tt := range v.levels[1 : len(v.levels)-1] { - level := i + 1 - next := v.levels[level+1] - for _, t := range tt { - r := next.getOverlaps(nil, db.s.icmp, t.imin.ukey(), t.imax.ukey(), false) - sum := r.size() - if sum > maxOverlaps { - maxOverlaps = sum - maxLevel = level - } - } - } - } - v.release() - - if maxOverlaps > want { - t.Errorf("next level most overlapping bytes is more than %d, got=%d level=%d", want, maxOverlaps, maxLevel) - } else { - t.Logf("next level most overlapping bytes is %d, level=%d want=%d", maxOverlaps, maxLevel, want) - } -} - -func (h *dbHarness) delete(key string) { - t := h.t - db := h.db - - err := db.Delete([]byte(key), h.wo) - if err != nil { - t.Error("Delete: got error: ", err) - } -} - -func (h *dbHarness) assertNumKeys(want int) { - iter := h.db.NewIterator(nil, h.ro) - defer iter.Release() - got := 0 - for iter.Next() { - got++ - } - if err := iter.Error(); err != nil { - h.t.Error("assertNumKeys: ", err) - } - if want != got { - h.t.Errorf("assertNumKeys: want=%d got=%d", want, got) - } -} - -func (h *dbHarness) getr(db Reader, key string, expectFound bool) (found bool, v []byte) { - t := h.t - v, err := db.Get([]byte(key), h.ro) - switch err { - case ErrNotFound: - if expectFound { - t.Errorf("Get: key '%s' not found, want found", key) - } - case nil: - found = true - if !expectFound { - t.Errorf("Get: key '%s' found, want not found", key) - } - default: - t.Error("Get: got error: ", err) - } - return -} - -func (h *dbHarness) get(key string, expectFound bool) (found bool, v []byte) { - return h.getr(h.db, key, expectFound) -} - -func (h *dbHarness) getValr(db Reader, key, value string) { - t := h.t - found, r := h.getr(db, key, true) - if !found { - return - } - rval := string(r) - if rval != value { - t.Errorf("Get: invalid value, got '%s', want '%s'", rval, value) - } -} - -func (h *dbHarness) getVal(key, value string) { - h.getValr(h.db, key, value) -} - -func (h *dbHarness) allEntriesFor(key, want string) { - t := h.t - db := h.db - s := db.s - - ikey := makeInternalKey(nil, []byte(key), keyMaxSeq, keyTypeVal) - iter := db.newRawIterator(nil, nil, nil, nil) - if !iter.Seek(ikey) && iter.Error() != nil { - t.Error("AllEntries: error during seek, err: ", iter.Error()) - return - } - res := "[ " - first := true - for iter.Valid() { - if ukey, _, kt, kerr := parseInternalKey(iter.Key()); kerr == nil { - if s.icmp.uCompare(ikey.ukey(), ukey) != 0 { - break - } - if !first { - res += ", " - } - first = false - switch kt { - case keyTypeVal: - res += string(iter.Value()) - case keyTypeDel: - res += "DEL" - } - } else { - if !first { - res += ", " - } - first = false - res += "CORRUPTED" - } - iter.Next() - } - if !first { - res += " " - } - res += "]" - if res != want { - t.Errorf("AllEntries: assert failed for key %q, got=%q want=%q", key, res, want) - } -} - -// Return a string that contains all key,value pairs in order, -// formatted like "(k1->v1)(k2->v2)". -func (h *dbHarness) getKeyVal(want string) { - t := h.t - db := h.db - - s, err := db.GetSnapshot() - if err != nil { - t.Fatal("GetSnapshot: got error: ", err) - } - res := "" - iter := s.NewIterator(nil, nil) - for iter.Next() { - res += fmt.Sprintf("(%s->%s)", string(iter.Key()), string(iter.Value())) - } - iter.Release() - - if res != want { - t.Errorf("GetKeyVal: invalid key/value pair, got=%q want=%q", res, want) - } - s.Release() -} - -func (h *dbHarness) waitCompaction() { - t := h.t - db := h.db - if err := db.compTriggerWait(db.tcompCmdC); err != nil { - t.Error("compaction error: ", err) - } -} - -func (h *dbHarness) waitMemCompaction() { - t := h.t - db := h.db - - if err := db.compTriggerWait(db.mcompCmdC); err != nil { - t.Error("compaction error: ", err) - } -} - -func (h *dbHarness) compactMem() { - t := h.t - db := h.db - - t.Log("starting memdb compaction") - - db.writeLockC <- struct{}{} - defer func() { - <-db.writeLockC - }() - - if _, err := db.rotateMem(0, true); err != nil { - t.Error("compaction error: ", err) - } - - if h.totalTables() == 0 { - t.Error("zero tables after mem compaction") - } - - t.Log("memdb compaction done") -} - -func (h *dbHarness) compactRangeAtErr(level int, min, max string, wanterr bool) { - t := h.t - db := h.db - - var _min, _max []byte - if min != "" { - _min = []byte(min) - } - if max != "" { - _max = []byte(max) - } - - t.Logf("starting table range compaction: level=%d, min=%q, max=%q", level, min, max) - - if err := db.compTriggerRange(db.tcompCmdC, level, _min, _max); err != nil { - if wanterr { - t.Log("CompactRangeAt: got error (expected): ", err) - } else { - t.Error("CompactRangeAt: got error: ", err) - } - } else if wanterr { - t.Error("CompactRangeAt: expect error") - } - - t.Log("table range compaction done") -} - -func (h *dbHarness) compactRangeAt(level int, min, max string) { - h.compactRangeAtErr(level, min, max, false) -} - -func (h *dbHarness) compactRange(min, max string) { - t := h.t - db := h.db - - t.Logf("starting DB range compaction: min=%q, max=%q", min, max) - - var r util.Range - if min != "" { - r.Start = []byte(min) - } - if max != "" { - r.Limit = []byte(max) - } - if err := db.CompactRange(r); err != nil { - t.Error("CompactRange: got error: ", err) - } - - t.Log("DB range compaction done") -} - -func (h *dbHarness) sizeOf(start, limit string) int64 { - sz, err := h.db.SizeOf([]util.Range{ - {[]byte(start), []byte(limit)}, - }) - if err != nil { - h.t.Error("SizeOf: got error: ", err) - } - return sz.Sum() -} - -func (h *dbHarness) sizeAssert(start, limit string, low, hi int64) { - sz := h.sizeOf(start, limit) - if sz < low || sz > hi { - h.t.Errorf("sizeOf %q to %q not in range, want %d - %d, got %d", - shorten(start), shorten(limit), low, hi, sz) - } -} - -func (h *dbHarness) getSnapshot() (s *Snapshot) { - s, err := h.db.GetSnapshot() - if err != nil { - h.t.Fatal("GetSnapshot: got error: ", err) - } - return -} - -func (h *dbHarness) getTablesPerLevel() string { - res := "" - nz := 0 - v := h.db.s.version() - for level, tables := range v.levels { - if level > 0 { - res += "," - } - res += fmt.Sprint(len(tables)) - if len(tables) > 0 { - nz = len(res) - } - } - v.release() - return res[:nz] -} - -func (h *dbHarness) tablesPerLevel(want string) { - res := h.getTablesPerLevel() - if res != want { - h.t.Errorf("invalid tables len, want=%s, got=%s", want, res) - } -} - -func (h *dbHarness) totalTables() (n int) { - v := h.db.s.version() - for _, tables := range v.levels { - n += len(tables) - } - v.release() - return -} - -type keyValue interface { - Key() []byte - Value() []byte -} - -func testKeyVal(t *testing.T, kv keyValue, want string) { - res := string(kv.Key()) + "->" + string(kv.Value()) - if res != want { - t.Errorf("invalid key/value, want=%q, got=%q", want, res) - } -} - -func numKey(num int) string { - return fmt.Sprintf("key%06d", num) -} - -var testingBloomFilter = filter.NewBloomFilter(10) - -func truno(t *testing.T, o *opt.Options, f func(h *dbHarness)) { - for i := 0; i < 4; i++ { - func() { - switch i { - case 0: - case 1: - if o == nil { - o = &opt.Options{ - DisableLargeBatchTransaction: true, - Filter: testingBloomFilter, - } - } else { - old := o - o = &opt.Options{} - *o = *old - o.Filter = testingBloomFilter - } - case 2: - if o == nil { - o = &opt.Options{ - DisableLargeBatchTransaction: true, - Compression: opt.NoCompression, - } - } else { - old := o - o = &opt.Options{} - *o = *old - o.Compression = opt.NoCompression - } - } - h := newDbHarnessWopt(t, o) - defer h.close() - switch i { - case 3: - h.reopenDB() - } - f(h) - }() - } -} - -func trun(t *testing.T, f func(h *dbHarness)) { - truno(t, nil, f) -} - -func testAligned(t *testing.T, name string, offset uintptr) { - if offset%8 != 0 { - t.Errorf("field %s offset is not 64-bit aligned", name) - } -} - -func Test_FieldsAligned(t *testing.T) { - p1 := new(DB) - testAligned(t, "DB.seq", unsafe.Offsetof(p1.seq)) - p2 := new(session) - testAligned(t, "session.stNextFileNum", unsafe.Offsetof(p2.stNextFileNum)) - testAligned(t, "session.stJournalNum", unsafe.Offsetof(p2.stJournalNum)) - testAligned(t, "session.stPrevJournalNum", unsafe.Offsetof(p2.stPrevJournalNum)) - testAligned(t, "session.stSeqNum", unsafe.Offsetof(p2.stSeqNum)) -} - -func TestDB_Locking(t *testing.T) { - h := newDbHarness(t) - defer h.stor.Close() - h.openAssert(false) - h.closeDB() - h.openAssert(true) -} - -func TestDB_Empty(t *testing.T) { - trun(t, func(h *dbHarness) { - h.get("foo", false) - - h.reopenDB() - h.get("foo", false) - }) -} - -func TestDB_ReadWrite(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("foo", "v1") - h.getVal("foo", "v1") - h.put("bar", "v2") - h.put("foo", "v3") - h.getVal("foo", "v3") - h.getVal("bar", "v2") - - h.reopenDB() - h.getVal("foo", "v3") - h.getVal("bar", "v2") - }) -} - -func TestDB_PutDeleteGet(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("foo", "v1") - h.getVal("foo", "v1") - h.put("foo", "v2") - h.getVal("foo", "v2") - h.delete("foo") - h.get("foo", false) - - h.reopenDB() - h.get("foo", false) - }) -} - -func TestDB_EmptyBatch(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.get("foo", false) - err := h.db.Write(new(Batch), h.wo) - if err != nil { - t.Error("writing empty batch yield error: ", err) - } - h.get("foo", false) -} - -func TestDB_GetFromFrozen(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 100100, - }) - defer h.close() - - h.put("foo", "v1") - h.getVal("foo", "v1") - - h.stor.Stall(testutil.ModeSync, storage.TypeTable) // Block sync calls - h.put("k1", strings.Repeat("x", 100000)) // Fill memtable - h.put("k2", strings.Repeat("y", 100000)) // Trigger compaction - for i := 0; h.db.getFrozenMem() == nil && i < 100; i++ { - time.Sleep(10 * time.Microsecond) - } - if h.db.getFrozenMem() == nil { - h.stor.Release(testutil.ModeSync, storage.TypeTable) - t.Fatal("No frozen mem") - } - h.getVal("foo", "v1") - h.stor.Release(testutil.ModeSync, storage.TypeTable) // Release sync calls - - h.reopenDB() - h.getVal("foo", "v1") - h.get("k1", true) - h.get("k2", true) -} - -func TestDB_GetFromTable(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("foo", "v1") - h.compactMem() - h.getVal("foo", "v1") - }) -} - -func TestDB_GetSnapshot(t *testing.T) { - trun(t, func(h *dbHarness) { - bar := strings.Repeat("b", 200) - h.put("foo", "v1") - h.put(bar, "v1") - - snap, err := h.db.GetSnapshot() - if err != nil { - t.Fatal("GetSnapshot: got error: ", err) - } - - h.put("foo", "v2") - h.put(bar, "v2") - - h.getVal("foo", "v2") - h.getVal(bar, "v2") - h.getValr(snap, "foo", "v1") - h.getValr(snap, bar, "v1") - - h.compactMem() - - h.getVal("foo", "v2") - h.getVal(bar, "v2") - h.getValr(snap, "foo", "v1") - h.getValr(snap, bar, "v1") - - snap.Release() - - h.reopenDB() - h.getVal("foo", "v2") - h.getVal(bar, "v2") - }) -} - -func TestDB_GetLevel0Ordering(t *testing.T) { - trun(t, func(h *dbHarness) { - h.db.memdbMaxLevel = 2 - - for i := 0; i < 4; i++ { - h.put("bar", fmt.Sprintf("b%d", i)) - h.put("foo", fmt.Sprintf("v%d", i)) - h.compactMem() - } - h.getVal("foo", "v3") - h.getVal("bar", "b3") - - v := h.db.s.version() - t0len := v.tLen(0) - v.release() - if t0len < 2 { - t.Errorf("level-0 tables is less than 2, got %d", t0len) - } - - h.reopenDB() - h.getVal("foo", "v3") - h.getVal("bar", "b3") - }) -} - -func TestDB_GetOrderedByLevels(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("foo", "v1") - h.compactMem() - h.compactRange("a", "z") - h.getVal("foo", "v1") - h.put("foo", "v2") - h.compactMem() - h.getVal("foo", "v2") - }) -} - -func TestDB_GetPicksCorrectFile(t *testing.T) { - trun(t, func(h *dbHarness) { - // Arrange to have multiple files in a non-level-0 level. - h.put("a", "va") - h.compactMem() - h.compactRange("a", "b") - h.put("x", "vx") - h.compactMem() - h.compactRange("x", "y") - h.put("f", "vf") - h.compactMem() - h.compactRange("f", "g") - - h.getVal("a", "va") - h.getVal("f", "vf") - h.getVal("x", "vx") - - h.compactRange("", "") - h.getVal("a", "va") - h.getVal("f", "vf") - h.getVal("x", "vx") - }) -} - -func TestDB_GetEncountersEmptyLevel(t *testing.T) { - trun(t, func(h *dbHarness) { - h.db.memdbMaxLevel = 2 - - // Arrange for the following to happen: - // * sstable A in level 0 - // * nothing in level 1 - // * sstable B in level 2 - // Then do enough Get() calls to arrange for an automatic compaction - // of sstable A. A bug would cause the compaction to be marked as - // occurring at level 1 (instead of the correct level 0). - - // Step 1: First place sstables in levels 0 and 2 - for i := 0; ; i++ { - if i >= 100 { - t.Fatal("could not fill levels-0 and level-2") - } - v := h.db.s.version() - if v.tLen(0) > 0 && v.tLen(2) > 0 { - v.release() - break - } - v.release() - h.put("a", "begin") - h.put("z", "end") - h.compactMem() - - h.getVal("a", "begin") - h.getVal("z", "end") - } - - // Step 2: clear level 1 if necessary. - h.compactRangeAt(1, "", "") - h.tablesPerLevel("1,0,1") - - h.getVal("a", "begin") - h.getVal("z", "end") - - // Step 3: read a bunch of times - for i := 0; i < 200; i++ { - h.get("missing", false) - } - - // Step 4: Wait for compaction to finish - h.waitCompaction() - - v := h.db.s.version() - if v.tLen(0) > 0 { - t.Errorf("level-0 tables more than 0, got %d", v.tLen(0)) - } - v.release() - - h.getVal("a", "begin") - h.getVal("z", "end") - }) -} - -func TestDB_IterMultiWithDelete(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("a", "va") - h.put("b", "vb") - h.put("c", "vc") - h.delete("b") - h.get("b", false) - - iter := h.db.NewIterator(nil, nil) - iter.Seek([]byte("c")) - testKeyVal(t, iter, "c->vc") - iter.Prev() - testKeyVal(t, iter, "a->va") - iter.Release() - - h.compactMem() - - iter = h.db.NewIterator(nil, nil) - iter.Seek([]byte("c")) - testKeyVal(t, iter, "c->vc") - iter.Prev() - testKeyVal(t, iter, "a->va") - iter.Release() - }) -} - -func TestDB_IteratorPinsRef(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.put("foo", "hello") - - // Get iterator that will yield the current contents of the DB. - iter := h.db.NewIterator(nil, nil) - - // Write to force compactions - h.put("foo", "newvalue1") - for i := 0; i < 100; i++ { - h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), 100000/10)) - } - h.put("foo", "newvalue2") - - iter.First() - testKeyVal(t, iter, "foo->hello") - if iter.Next() { - t.Errorf("expect eof") - } - iter.Release() -} - -func TestDB_Recover(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("foo", "v1") - h.put("baz", "v5") - - h.reopenDB() - h.getVal("foo", "v1") - - h.getVal("foo", "v1") - h.getVal("baz", "v5") - h.put("bar", "v2") - h.put("foo", "v3") - - h.reopenDB() - h.getVal("foo", "v3") - h.put("foo", "v4") - h.getVal("foo", "v4") - h.getVal("bar", "v2") - h.getVal("baz", "v5") - }) -} - -func TestDB_RecoverWithEmptyJournal(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("foo", "v1") - h.put("foo", "v2") - - h.reopenDB() - h.reopenDB() - h.put("foo", "v3") - - h.reopenDB() - h.getVal("foo", "v3") - }) -} - -func TestDB_RecoverDuringMemtableCompaction(t *testing.T) { - truno(t, &opt.Options{DisableLargeBatchTransaction: true, WriteBuffer: 1000000}, func(h *dbHarness) { - - h.stor.Stall(testutil.ModeSync, storage.TypeTable) - h.put("big1", strings.Repeat("x", 10000000)) - h.put("big2", strings.Repeat("y", 1000)) - h.put("bar", "v2") - h.stor.Release(testutil.ModeSync, storage.TypeTable) - - h.reopenDB() - h.getVal("bar", "v2") - h.getVal("big1", strings.Repeat("x", 10000000)) - h.getVal("big2", strings.Repeat("y", 1000)) - }) -} - -func TestDB_MinorCompactionsHappen(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{DisableLargeBatchTransaction: true, WriteBuffer: 10000}) - defer h.close() - - n := 500 - - key := func(i int) string { - return fmt.Sprintf("key%06d", i) - } - - for i := 0; i < n; i++ { - h.put(key(i), key(i)+strings.Repeat("v", 1000)) - } - - for i := 0; i < n; i++ { - h.getVal(key(i), key(i)+strings.Repeat("v", 1000)) - } - - h.reopenDB() - for i := 0; i < n; i++ { - h.getVal(key(i), key(i)+strings.Repeat("v", 1000)) - } -} - -func TestDB_RecoverWithLargeJournal(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.put("big1", strings.Repeat("1", 200000)) - h.put("big2", strings.Repeat("2", 200000)) - h.put("small3", strings.Repeat("3", 10)) - h.put("small4", strings.Repeat("4", 10)) - h.tablesPerLevel("") - - // Make sure that if we re-open with a small write buffer size that - // we flush table files in the middle of a large journal file. - h.o.WriteBuffer = 100000 - h.reopenDB() - h.getVal("big1", strings.Repeat("1", 200000)) - h.getVal("big2", strings.Repeat("2", 200000)) - h.getVal("small3", strings.Repeat("3", 10)) - h.getVal("small4", strings.Repeat("4", 10)) - v := h.db.s.version() - if v.tLen(0) <= 1 { - t.Errorf("tables-0 less than one") - } - v.release() -} - -func TestDB_CompactionsGenerateMultipleFiles(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 10000000, - Compression: opt.NoCompression, - }) - defer h.close() - - v := h.db.s.version() - if v.tLen(0) > 0 { - t.Errorf("level-0 tables more than 0, got %d", v.tLen(0)) - } - v.release() - - n := 80 - - // Write 8MB (80 values, each 100K) - for i := 0; i < n; i++ { - h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), 100000/10)) - } - - // Reopening moves updates to level-0 - h.reopenDB() - h.compactRangeAt(0, "", "") - - v = h.db.s.version() - if v.tLen(0) > 0 { - t.Errorf("level-0 tables more than 0, got %d", v.tLen(0)) - } - if v.tLen(1) <= 1 { - t.Errorf("level-1 tables less than 1, got %d", v.tLen(1)) - } - v.release() - - for i := 0; i < n; i++ { - h.getVal(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), 100000/10)) - } -} - -func TestDB_RepeatedWritesToSameKey(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{DisableLargeBatchTransaction: true, WriteBuffer: 100000}) - defer h.close() - - maxTables := h.o.GetWriteL0PauseTrigger() + 7 - - value := strings.Repeat("v", 2*h.o.GetWriteBuffer()) - for i := 0; i < 5*maxTables; i++ { - h.put("key", value) - n := h.totalTables() - if n > maxTables { - t.Errorf("total tables exceed %d, got=%d, iter=%d", maxTables, n, i) - } - } -} - -func TestDB_RepeatedWritesToSameKeyAfterReopen(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 100000, - }) - defer h.close() - - h.reopenDB() - - maxTables := h.o.GetWriteL0PauseTrigger() + 7 - - value := strings.Repeat("v", 2*h.o.GetWriteBuffer()) - for i := 0; i < 5*maxTables; i++ { - h.put("key", value) - n := h.totalTables() - if n > maxTables { - t.Errorf("total tables exceed %d, got=%d, iter=%d", maxTables, n, i) - } - } -} - -func TestDB_SparseMerge(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{DisableLargeBatchTransaction: true, Compression: opt.NoCompression}) - defer h.close() - - h.putMulti(7, "A", "Z") - - // Suppose there is: - // small amount of data with prefix A - // large amount of data with prefix B - // small amount of data with prefix C - // and that recent updates have made small changes to all three prefixes. - // Check that we do not do a compaction that merges all of B in one shot. - h.put("A", "va") - value := strings.Repeat("x", 1000) - for i := 0; i < 100000; i++ { - h.put(fmt.Sprintf("B%010d", i), value) - } - h.put("C", "vc") - h.compactMem() - h.compactRangeAt(0, "", "") - h.waitCompaction() - - // Make sparse update - h.put("A", "va2") - h.put("B100", "bvalue2") - h.put("C", "vc2") - h.compactMem() - - h.waitCompaction() - h.maxNextLevelOverlappingBytes(20 * 1048576) - h.compactRangeAt(0, "", "") - h.waitCompaction() - h.maxNextLevelOverlappingBytes(20 * 1048576) - h.compactRangeAt(1, "", "") - h.waitCompaction() - h.maxNextLevelOverlappingBytes(20 * 1048576) -} - -func TestDB_SizeOf(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - Compression: opt.NoCompression, - WriteBuffer: 10000000, - }) - defer h.close() - - h.sizeAssert("", "xyz", 0, 0) - h.reopenDB() - h.sizeAssert("", "xyz", 0, 0) - - // Write 8MB (80 values, each 100K) - n := 80 - s1 := 100000 - s2 := 105000 - - for i := 0; i < n; i++ { - h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), s1/10)) - } - - // 0 because SizeOf() does not account for memtable space - h.sizeAssert("", numKey(50), 0, 0) - - for r := 0; r < 3; r++ { - h.reopenDB() - - for cs := 0; cs < n; cs += 10 { - for i := 0; i < n; i += 10 { - h.sizeAssert("", numKey(i), int64(s1*i), int64(s2*i)) - h.sizeAssert("", numKey(i)+".suffix", int64(s1*(i+1)), int64(s2*(i+1))) - h.sizeAssert(numKey(i), numKey(i+10), int64(s1*10), int64(s2*10)) - } - - h.sizeAssert("", numKey(50), int64(s1*50), int64(s2*50)) - h.sizeAssert("", numKey(50)+".suffix", int64(s1*50), int64(s2*50)) - - h.compactRangeAt(0, numKey(cs), numKey(cs+9)) - } - - v := h.db.s.version() - if v.tLen(0) != 0 { - t.Errorf("level-0 tables was not zero, got %d", v.tLen(0)) - } - if v.tLen(1) == 0 { - t.Error("level-1 tables was zero") - } - v.release() - } -} - -func TestDB_SizeOf_MixOfSmallAndLarge(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - Compression: opt.NoCompression, - }) - defer h.close() - - sizes := []int64{ - 10000, - 10000, - 100000, - 10000, - 100000, - 10000, - 300000, - 10000, - } - - for i, n := range sizes { - h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), int(n)/10)) - } - - for r := 0; r < 3; r++ { - h.reopenDB() - - var x int64 - for i, n := range sizes { - y := x - if i > 0 { - y += 1000 - } - h.sizeAssert("", numKey(i), x, y) - x += n - } - - h.sizeAssert(numKey(3), numKey(5), 110000, 111000) - - h.compactRangeAt(0, "", "") - } -} - -func TestDB_Snapshot(t *testing.T) { - trun(t, func(h *dbHarness) { - h.put("foo", "v1") - s1 := h.getSnapshot() - h.put("foo", "v2") - s2 := h.getSnapshot() - h.put("foo", "v3") - s3 := h.getSnapshot() - h.put("foo", "v4") - - h.getValr(s1, "foo", "v1") - h.getValr(s2, "foo", "v2") - h.getValr(s3, "foo", "v3") - h.getVal("foo", "v4") - - s3.Release() - h.getValr(s1, "foo", "v1") - h.getValr(s2, "foo", "v2") - h.getVal("foo", "v4") - - s1.Release() - h.getValr(s2, "foo", "v2") - h.getVal("foo", "v4") - - s2.Release() - h.getVal("foo", "v4") - }) -} - -func TestDB_SnapshotList(t *testing.T) { - db := &DB{snapsList: list.New()} - e0a := db.acquireSnapshot() - e0b := db.acquireSnapshot() - db.seq = 1 - e1 := db.acquireSnapshot() - db.seq = 2 - e2 := db.acquireSnapshot() - - if db.minSeq() != 0 { - t.Fatalf("invalid sequence number, got=%d", db.minSeq()) - } - db.releaseSnapshot(e0a) - if db.minSeq() != 0 { - t.Fatalf("invalid sequence number, got=%d", db.minSeq()) - } - db.releaseSnapshot(e2) - if db.minSeq() != 0 { - t.Fatalf("invalid sequence number, got=%d", db.minSeq()) - } - db.releaseSnapshot(e0b) - if db.minSeq() != 1 { - t.Fatalf("invalid sequence number, got=%d", db.minSeq()) - } - e2 = db.acquireSnapshot() - if db.minSeq() != 1 { - t.Fatalf("invalid sequence number, got=%d", db.minSeq()) - } - db.releaseSnapshot(e1) - if db.minSeq() != 2 { - t.Fatalf("invalid sequence number, got=%d", db.minSeq()) - } - db.releaseSnapshot(e2) - if db.minSeq() != 2 { - t.Fatalf("invalid sequence number, got=%d", db.minSeq()) - } -} - -func TestDB_HiddenValuesAreRemoved(t *testing.T) { - trun(t, func(h *dbHarness) { - s := h.db.s - - m := 2 - h.db.memdbMaxLevel = m - - h.put("foo", "v1") - h.compactMem() - v := s.version() - num := v.tLen(m) - v.release() - if num != 1 { - t.Errorf("invalid level-%d len, want=1 got=%d", m, num) - } - - // Place a table at level last-1 to prevent merging with preceding mutation - h.put("a", "begin") - h.put("z", "end") - h.compactMem() - v = s.version() - if v.tLen(m) != 1 { - t.Errorf("invalid level-%d len, want=1 got=%d", m, v.tLen(m)) - } - if v.tLen(m-1) != 1 { - t.Errorf("invalid level-%d len, want=1 got=%d", m-1, v.tLen(m-1)) - } - v.release() - - h.delete("foo") - h.put("foo", "v2") - h.allEntriesFor("foo", "[ v2, DEL, v1 ]") - h.compactMem() - h.allEntriesFor("foo", "[ v2, DEL, v1 ]") - h.compactRangeAt(m-2, "", "z") - // DEL eliminated, but v1 remains because we aren't compacting that level - // (DEL can be eliminated because v2 hides v1). - h.allEntriesFor("foo", "[ v2, v1 ]") - h.compactRangeAt(m-1, "", "") - // Merging last-1 w/ last, so we are the base level for "foo", so - // DEL is removed. (as is v1). - h.allEntriesFor("foo", "[ v2 ]") - }) -} - -func TestDB_DeletionMarkers2(t *testing.T) { - h := newDbHarness(t) - defer h.close() - s := h.db.s - - m := 2 - h.db.memdbMaxLevel = m - - h.put("foo", "v1") - h.compactMem() - v := s.version() - num := v.tLen(m) - v.release() - if num != 1 { - t.Errorf("invalid level-%d len, want=1 got=%d", m, num) - } - - // Place a table at level last-1 to prevent merging with preceding mutation - h.put("a", "begin") - h.put("z", "end") - h.compactMem() - v = s.version() - if v.tLen(m) != 1 { - t.Errorf("invalid level-%d len, want=1 got=%d", m, v.tLen(m)) - } - if v.tLen(m-1) != 1 { - t.Errorf("invalid level-%d len, want=1 got=%d", m-1, v.tLen(m-1)) - } - v.release() - - h.delete("foo") - h.allEntriesFor("foo", "[ DEL, v1 ]") - h.compactMem() // Moves to level last-2 - h.allEntriesFor("foo", "[ DEL, v1 ]") - h.compactRangeAt(m-2, "", "") - // DEL kept: "last" file overlaps - h.allEntriesFor("foo", "[ DEL, v1 ]") - h.compactRangeAt(m-1, "", "") - // Merging last-1 w/ last, so we are the base level for "foo", so - // DEL is removed. (as is v1). - h.allEntriesFor("foo", "[ ]") -} - -func TestDB_CompactionTableOpenError(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - OpenFilesCacheCapacity: -1, - }) - defer h.close() - - h.db.memdbMaxLevel = 2 - - im := 10 - jm := 10 - for r := 0; r < 2; r++ { - for i := 0; i < im; i++ { - for j := 0; j < jm; j++ { - h.put(fmt.Sprintf("k%d,%d", i, j), fmt.Sprintf("v%d,%d", i, j)) - } - h.compactMem() - } - } - - if n := h.totalTables(); n != im*2 { - t.Errorf("total tables is %d, want %d", n, im*2) - } - - h.stor.EmulateError(testutil.ModeOpen, storage.TypeTable, errors.New("open error during table compaction")) - go h.db.CompactRange(util.Range{}) - if err := h.db.compTriggerWait(h.db.tcompCmdC); err != nil { - t.Log("compaction error: ", err) - } - h.closeDB0() - h.openDB() - h.stor.EmulateError(testutil.ModeOpen, storage.TypeTable, nil) - - for i := 0; i < im; i++ { - for j := 0; j < jm; j++ { - h.getVal(fmt.Sprintf("k%d,%d", i, j), fmt.Sprintf("v%d,%d", i, j)) - } - } -} - -func TestDB_OverlapInLevel0(t *testing.T) { - trun(t, func(h *dbHarness) { - h.db.memdbMaxLevel = 2 - - // Fill levels 1 and 2 to disable the pushing of new memtables to levels > 0. - h.put("100", "v100") - h.put("999", "v999") - h.compactMem() - h.delete("100") - h.delete("999") - h.compactMem() - h.tablesPerLevel("0,1,1") - - // Make files spanning the following ranges in level-0: - // files[0] 200 .. 900 - // files[1] 300 .. 500 - // Note that files are sorted by min key. - h.put("300", "v300") - h.put("500", "v500") - h.compactMem() - h.put("200", "v200") - h.put("600", "v600") - h.put("900", "v900") - h.compactMem() - h.tablesPerLevel("2,1,1") - - // Compact away the placeholder files we created initially - h.compactRangeAt(1, "", "") - h.compactRangeAt(2, "", "") - h.tablesPerLevel("2") - - // Do a memtable compaction. Before bug-fix, the compaction would - // not detect the overlap with level-0 files and would incorrectly place - // the deletion in a deeper level. - h.delete("600") - h.compactMem() - h.tablesPerLevel("3") - h.get("600", false) - }) -} - -func TestDB_L0_CompactionBug_Issue44_a(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.reopenDB() - h.put("b", "v") - h.reopenDB() - h.delete("b") - h.delete("a") - h.reopenDB() - h.delete("a") - h.reopenDB() - h.put("a", "v") - h.reopenDB() - h.reopenDB() - h.getKeyVal("(a->v)") - h.waitCompaction() - h.getKeyVal("(a->v)") -} - -func TestDB_L0_CompactionBug_Issue44_b(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.reopenDB() - h.put("", "") - h.reopenDB() - h.delete("e") - h.put("", "") - h.reopenDB() - h.put("c", "cv") - h.reopenDB() - h.put("", "") - h.reopenDB() - h.put("", "") - h.waitCompaction() - h.reopenDB() - h.put("d", "dv") - h.reopenDB() - h.put("", "") - h.reopenDB() - h.delete("d") - h.delete("b") - h.reopenDB() - h.getKeyVal("(->)(c->cv)") - h.waitCompaction() - h.getKeyVal("(->)(c->cv)") -} - -func TestDB_SingleEntryMemCompaction(t *testing.T) { - trun(t, func(h *dbHarness) { - for i := 0; i < 10; i++ { - h.put("big", strings.Repeat("v", opt.DefaultWriteBuffer)) - h.compactMem() - h.put("key", strings.Repeat("v", opt.DefaultBlockSize)) - h.compactMem() - h.put("k", "v") - h.compactMem() - h.put("", "") - h.compactMem() - h.put("verybig", strings.Repeat("v", opt.DefaultWriteBuffer*2)) - h.compactMem() - } - }) -} - -func TestDB_ManifestWriteError(t *testing.T) { - for i := 0; i < 2; i++ { - func() { - h := newDbHarness(t) - defer h.close() - - h.put("foo", "bar") - h.getVal("foo", "bar") - - // Mem compaction (will succeed) - h.compactMem() - h.getVal("foo", "bar") - v := h.db.s.version() - if n := v.tLen(0); n != 1 { - t.Errorf("invalid total tables, want=1 got=%d", n) - } - v.release() - - if i == 0 { - h.stor.EmulateError(testutil.ModeWrite, storage.TypeManifest, errors.New("manifest write error")) - } else { - h.stor.EmulateError(testutil.ModeSync, storage.TypeManifest, errors.New("manifest sync error")) - } - - // Merging compaction (will fail) - h.compactRangeAtErr(0, "", "", true) - - h.db.Close() - h.stor.EmulateError(testutil.ModeWrite, storage.TypeManifest, nil) - h.stor.EmulateError(testutil.ModeSync, storage.TypeManifest, nil) - - // Should not lose data - h.openDB() - h.getVal("foo", "bar") - }() - } -} - -func assertErr(t *testing.T, err error, wanterr bool) { - if err != nil { - if wanterr { - t.Log("AssertErr: got error (expected): ", err) - } else { - t.Error("AssertErr: got error: ", err) - } - } else if wanterr { - t.Error("AssertErr: expect error") - } -} - -func TestDB_ClosedIsClosed(t *testing.T) { - h := newDbHarness(t) - db := h.db - - var iter, iter2 iterator.Iterator - var snap *Snapshot - func() { - defer h.close() - - h.put("k", "v") - h.getVal("k", "v") - - iter = db.NewIterator(nil, h.ro) - iter.Seek([]byte("k")) - testKeyVal(t, iter, "k->v") - - var err error - snap, err = db.GetSnapshot() - if err != nil { - t.Fatal("GetSnapshot: got error: ", err) - } - - h.getValr(snap, "k", "v") - - iter2 = snap.NewIterator(nil, h.ro) - iter2.Seek([]byte("k")) - testKeyVal(t, iter2, "k->v") - - h.put("foo", "v2") - h.delete("foo") - - // closing DB - iter.Release() - iter2.Release() - }() - - assertErr(t, db.Put([]byte("x"), []byte("y"), h.wo), true) - _, err := db.Get([]byte("k"), h.ro) - assertErr(t, err, true) - - if iter.Valid() { - t.Errorf("iter.Valid should false") - } - assertErr(t, iter.Error(), false) - testKeyVal(t, iter, "->") - if iter.Seek([]byte("k")) { - t.Errorf("iter.Seek should false") - } - assertErr(t, iter.Error(), true) - - assertErr(t, iter2.Error(), false) - - _, err = snap.Get([]byte("k"), h.ro) - assertErr(t, err, true) - - _, err = db.GetSnapshot() - assertErr(t, err, true) - - iter3 := db.NewIterator(nil, h.ro) - assertErr(t, iter3.Error(), true) - - iter3 = snap.NewIterator(nil, h.ro) - assertErr(t, iter3.Error(), true) - - assertErr(t, db.Delete([]byte("k"), h.wo), true) - - _, err = db.GetProperty("leveldb.stats") - assertErr(t, err, true) - - _, err = db.SizeOf([]util.Range{{[]byte("a"), []byte("z")}}) - assertErr(t, err, true) - - assertErr(t, db.CompactRange(util.Range{}), true) - - assertErr(t, db.Close(), true) -} - -type numberComparer struct{} - -func (numberComparer) num(x []byte) (n int) { - fmt.Sscan(string(x[1:len(x)-1]), &n) - return -} - -func (numberComparer) Name() string { - return "test.NumberComparer" -} - -func (p numberComparer) Compare(a, b []byte) int { - return p.num(a) - p.num(b) -} - -func (numberComparer) Separator(dst, a, b []byte) []byte { return nil } -func (numberComparer) Successor(dst, b []byte) []byte { return nil } - -func TestDB_CustomComparer(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - Comparer: numberComparer{}, - WriteBuffer: 1000, - }) - defer h.close() - - h.put("[10]", "ten") - h.put("[0x14]", "twenty") - for i := 0; i < 2; i++ { - h.getVal("[10]", "ten") - h.getVal("[0xa]", "ten") - h.getVal("[20]", "twenty") - h.getVal("[0x14]", "twenty") - h.get("[15]", false) - h.get("[0xf]", false) - h.compactMem() - h.compactRange("[0]", "[9999]") - } - - for n := 0; n < 2; n++ { - for i := 0; i < 100; i++ { - v := fmt.Sprintf("[%d]", i*10) - h.put(v, v) - } - h.compactMem() - h.compactRange("[0]", "[1000000]") - } -} - -func TestDB_ManualCompaction(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.db.memdbMaxLevel = 2 - - h.putMulti(3, "p", "q") - h.tablesPerLevel("1,1,1") - - // Compaction range falls before files - h.compactRange("", "c") - h.tablesPerLevel("1,1,1") - - // Compaction range falls after files - h.compactRange("r", "z") - h.tablesPerLevel("1,1,1") - - // Compaction range overlaps files - h.compactRange("p1", "p9") - h.tablesPerLevel("0,0,1") - - // Populate a different range - h.putMulti(3, "c", "e") - h.tablesPerLevel("1,1,2") - - // Compact just the new range - h.compactRange("b", "f") - h.tablesPerLevel("0,0,2") - - // Compact all - h.putMulti(1, "a", "z") - h.tablesPerLevel("0,1,2") - h.compactRange("", "") - h.tablesPerLevel("0,0,1") -} - -func TestDB_BloomFilter(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - DisableBlockCache: true, - Filter: filter.NewBloomFilter(10), - }) - defer h.close() - - key := func(i int) string { - return fmt.Sprintf("key%06d", i) - } - - const n = 10000 - - // Populate multiple layers - for i := 0; i < n; i++ { - h.put(key(i), key(i)) - } - h.compactMem() - h.compactRange("a", "z") - for i := 0; i < n; i += 100 { - h.put(key(i), key(i)) - } - h.compactMem() - - // Prevent auto compactions triggered by seeks - h.stor.Stall(testutil.ModeSync, storage.TypeTable) - - // Lookup present keys. Should rarely read from small sstable. - h.stor.ResetCounter(testutil.ModeRead, storage.TypeTable) - for i := 0; i < n; i++ { - h.getVal(key(i), key(i)) - } - cnt, _ := h.stor.Counter(testutil.ModeRead, storage.TypeTable) - t.Logf("lookup of %d present keys yield %d sstable I/O reads", n, cnt) - if min, max := n, n+2*n/100; cnt < min || cnt > max { - t.Errorf("num of sstable I/O reads of present keys not in range of %d - %d, got %d", min, max, cnt) - } - - // Lookup missing keys. Should rarely read from either sstable. - h.stor.ResetCounter(testutil.ModeRead, storage.TypeTable) - for i := 0; i < n; i++ { - h.get(key(i)+".missing", false) - } - cnt, _ = h.stor.Counter(testutil.ModeRead, storage.TypeTable) - t.Logf("lookup of %d missing keys yield %d sstable I/O reads", n, cnt) - if max := 3 * n / 100; cnt > max { - t.Errorf("num of sstable I/O reads of missing keys was more than %d, got %d", max, cnt) - } - - h.stor.Release(testutil.ModeSync, storage.TypeTable) -} - -func TestDB_Concurrent(t *testing.T) { - const n, secs, maxkey = 4, 6, 1000 - h := newDbHarness(t) - defer h.close() - - runtime.GOMAXPROCS(runtime.NumCPU()) - - var ( - closeWg sync.WaitGroup - stop uint32 - cnt [n]uint32 - ) - - for i := 0; i < n; i++ { - closeWg.Add(1) - go func(i int) { - var put, get, found uint - defer func() { - t.Logf("goroutine %d stopped after %d ops, put=%d get=%d found=%d missing=%d", - i, cnt[i], put, get, found, get-found) - closeWg.Done() - }() - - rnd := rand.New(rand.NewSource(int64(1000 + i))) - for atomic.LoadUint32(&stop) == 0 { - x := cnt[i] - - k := rnd.Intn(maxkey) - kstr := fmt.Sprintf("%016d", k) - - if (rnd.Int() % 2) > 0 { - put++ - h.put(kstr, fmt.Sprintf("%d.%d.%-1000d", k, i, x)) - } else { - get++ - v, err := h.db.Get([]byte(kstr), h.ro) - if err == nil { - found++ - rk, ri, rx := 0, -1, uint32(0) - fmt.Sscanf(string(v), "%d.%d.%d", &rk, &ri, &rx) - if rk != k { - t.Errorf("invalid key want=%d got=%d", k, rk) - } - if ri < 0 || ri >= n { - t.Error("invalid goroutine number: ", ri) - } else { - tx := atomic.LoadUint32(&(cnt[ri])) - if rx > tx { - t.Errorf("invalid seq number, %d > %d ", rx, tx) - } - } - } else if err != ErrNotFound { - t.Error("Get: got error: ", err) - return - } - } - atomic.AddUint32(&cnt[i], 1) - } - }(i) - } - - time.Sleep(secs * time.Second) - atomic.StoreUint32(&stop, 1) - closeWg.Wait() -} - -func TestDB_ConcurrentIterator(t *testing.T) { - const n, n2 = 4, 1000 - h := newDbHarnessWopt(t, &opt.Options{DisableLargeBatchTransaction: true, WriteBuffer: 30}) - defer h.close() - - runtime.GOMAXPROCS(runtime.NumCPU()) - - var ( - closeWg sync.WaitGroup - stop uint32 - ) - - for i := 0; i < n; i++ { - closeWg.Add(1) - go func(i int) { - for k := 0; atomic.LoadUint32(&stop) == 0; k++ { - h.put(fmt.Sprintf("k%d", k), fmt.Sprintf("%d.%d.", k, i)+strings.Repeat("x", 10)) - } - closeWg.Done() - }(i) - } - - for i := 0; i < n; i++ { - closeWg.Add(1) - go func(i int) { - for k := 1000000; k < 0 || atomic.LoadUint32(&stop) == 0; k-- { - h.put(fmt.Sprintf("k%d", k), fmt.Sprintf("%d.%d.", k, i)+strings.Repeat("x", 10)) - } - closeWg.Done() - }(i) - } - - cmp := comparer.DefaultComparer - for i := 0; i < n2; i++ { - closeWg.Add(1) - go func(i int) { - it := h.db.NewIterator(nil, nil) - var pk []byte - for it.Next() { - kk := it.Key() - if cmp.Compare(kk, pk) <= 0 { - t.Errorf("iter %d: %q is successor of %q", i, pk, kk) - } - pk = append(pk[:0], kk...) - var k, vk, vi int - if n, err := fmt.Sscanf(string(it.Key()), "k%d", &k); err != nil { - t.Errorf("iter %d: Scanf error on key %q: %v", i, it.Key(), err) - } else if n < 1 { - t.Errorf("iter %d: Cannot parse key %q", i, it.Key()) - } - if n, err := fmt.Sscanf(string(it.Value()), "%d.%d", &vk, &vi); err != nil { - t.Errorf("iter %d: Scanf error on value %q: %v", i, it.Value(), err) - } else if n < 2 { - t.Errorf("iter %d: Cannot parse value %q", i, it.Value()) - } - - if vk != k { - t.Errorf("iter %d: invalid value i=%d, want=%d got=%d", i, vi, k, vk) - } - } - if err := it.Error(); err != nil { - t.Errorf("iter %d: Got error: %v", i, err) - } - it.Release() - closeWg.Done() - }(i) - } - - atomic.StoreUint32(&stop, 1) - closeWg.Wait() -} - -func TestDB_ConcurrentWrite(t *testing.T) { - const n, bk, niter = 10, 3, 10000 - h := newDbHarness(t) - defer h.close() - - runtime.GOMAXPROCS(runtime.NumCPU()) - - var wg sync.WaitGroup - for i := 0; i < n; i++ { - wg.Add(1) - go func(i int) { - defer wg.Done() - for k := 0; k < niter; k++ { - kstr := fmt.Sprintf("put-%d.%d", i, k) - vstr := fmt.Sprintf("v%d", k) - h.put(kstr, vstr) - // Key should immediately available after put returns. - h.getVal(kstr, vstr) - } - }(i) - } - for i := 0; i < n; i++ { - wg.Add(1) - batch := &Batch{} - go func(i int) { - defer wg.Done() - for k := 0; k < niter; k++ { - batch.Reset() - for j := 0; j < bk; j++ { - batch.Put([]byte(fmt.Sprintf("batch-%d.%d.%d", i, k, j)), []byte(fmt.Sprintf("v%d", k))) - } - h.write(batch) - // Key should immediately available after put returns. - for j := 0; j < bk; j++ { - h.getVal(fmt.Sprintf("batch-%d.%d.%d", i, k, j), fmt.Sprintf("v%d", k)) - } - } - }(i) - } - wg.Wait() -} - -func TestDB_CreateReopenDbOnFile(t *testing.T) { - dbpath := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldbtestCreateReopenDbOnFile-%d", os.Getuid())) - if err := os.RemoveAll(dbpath); err != nil { - t.Fatal("cannot remove old db: ", err) - } - defer os.RemoveAll(dbpath) - - for i := 0; i < 3; i++ { - stor, err := storage.OpenFile(dbpath, false) - if err != nil { - t.Fatalf("(%d) cannot open storage: %s", i, err) - } - db, err := Open(stor, nil) - if err != nil { - t.Fatalf("(%d) cannot open db: %s", i, err) - } - if err := db.Put([]byte("foo"), []byte("bar"), nil); err != nil { - t.Fatalf("(%d) cannot write to db: %s", i, err) - } - if err := db.Close(); err != nil { - t.Fatalf("(%d) cannot close db: %s", i, err) - } - if err := stor.Close(); err != nil { - t.Fatalf("(%d) cannot close storage: %s", i, err) - } - } -} - -func TestDB_CreateReopenDbOnFile2(t *testing.T) { - dbpath := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldbtestCreateReopenDbOnFile2-%d", os.Getuid())) - if err := os.RemoveAll(dbpath); err != nil { - t.Fatal("cannot remove old db: ", err) - } - defer os.RemoveAll(dbpath) - - for i := 0; i < 3; i++ { - db, err := OpenFile(dbpath, nil) - if err != nil { - t.Fatalf("(%d) cannot open db: %s", i, err) - } - if err := db.Put([]byte("foo"), []byte("bar"), nil); err != nil { - t.Fatalf("(%d) cannot write to db: %s", i, err) - } - if err := db.Close(); err != nil { - t.Fatalf("(%d) cannot close db: %s", i, err) - } - } -} - -func TestDB_DeletionMarkersOnMemdb(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.put("foo", "v1") - h.compactMem() - h.delete("foo") - h.get("foo", false) - h.getKeyVal("") -} - -func TestDB_LeveldbIssue178(t *testing.T) { - nKeys := (opt.DefaultCompactionTableSize / 30) * 5 - key1 := func(i int) string { - return fmt.Sprintf("my_key_%d", i) - } - key2 := func(i int) string { - return fmt.Sprintf("my_key_%d_xxx", i) - } - - // Disable compression since it affects the creation of layers and the - // code below is trying to test against a very specific scenario. - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - Compression: opt.NoCompression, - }) - defer h.close() - - // Create first key range. - batch := new(Batch) - for i := 0; i < nKeys; i++ { - batch.Put([]byte(key1(i)), []byte("value for range 1 key")) - } - h.write(batch) - - // Create second key range. - batch.Reset() - for i := 0; i < nKeys; i++ { - batch.Put([]byte(key2(i)), []byte("value for range 2 key")) - } - h.write(batch) - - // Delete second key range. - batch.Reset() - for i := 0; i < nKeys; i++ { - batch.Delete([]byte(key2(i))) - } - h.write(batch) - h.waitMemCompaction() - - // Run manual compaction. - h.compactRange(key1(0), key1(nKeys-1)) - - // Checking the keys. - h.assertNumKeys(nKeys) -} - -func TestDB_LeveldbIssue200(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.put("1", "b") - h.put("2", "c") - h.put("3", "d") - h.put("4", "e") - h.put("5", "f") - - iter := h.db.NewIterator(nil, h.ro) - - // Add an element that should not be reflected in the iterator. - h.put("25", "cd") - - iter.Seek([]byte("5")) - assertBytes(t, []byte("5"), iter.Key()) - iter.Prev() - assertBytes(t, []byte("4"), iter.Key()) - iter.Prev() - assertBytes(t, []byte("3"), iter.Key()) - iter.Next() - assertBytes(t, []byte("4"), iter.Key()) - iter.Next() - assertBytes(t, []byte("5"), iter.Key()) -} - -func TestDB_GoleveldbIssue74(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 1 * opt.MiB, - }) - defer h.close() - - const n, dur = 10000, 5 * time.Second - - runtime.GOMAXPROCS(runtime.NumCPU()) - - until := time.Now().Add(dur) - wg := new(sync.WaitGroup) - wg.Add(2) - var done uint32 - go func() { - var i int - defer func() { - t.Logf("WRITER DONE #%d", i) - atomic.StoreUint32(&done, 1) - wg.Done() - }() - - b := new(Batch) - for ; time.Now().Before(until) && atomic.LoadUint32(&done) == 0; i++ { - iv := fmt.Sprintf("VAL%010d", i) - for k := 0; k < n; k++ { - key := fmt.Sprintf("KEY%06d", k) - b.Put([]byte(key), []byte(key+iv)) - b.Put([]byte(fmt.Sprintf("PTR%06d", k)), []byte(key)) - } - h.write(b) - - b.Reset() - snap := h.getSnapshot() - iter := snap.NewIterator(util.BytesPrefix([]byte("PTR")), nil) - var k int - for ; iter.Next(); k++ { - ptrKey := iter.Key() - key := iter.Value() - - if _, err := snap.Get(ptrKey, nil); err != nil { - t.Fatalf("WRITER #%d snapshot.Get %q: %v", i, ptrKey, err) - } - if value, err := snap.Get(key, nil); err != nil { - t.Fatalf("WRITER #%d snapshot.Get %q: %v", i, key, err) - } else if string(value) != string(key)+iv { - t.Fatalf("WRITER #%d snapshot.Get %q got invalid value, want %q got %q", i, key, string(key)+iv, value) - } - - b.Delete(key) - b.Delete(ptrKey) - } - h.write(b) - iter.Release() - snap.Release() - if k != n { - t.Fatalf("#%d %d != %d", i, k, n) - } - } - }() - go func() { - var i int - defer func() { - t.Logf("READER DONE #%d", i) - atomic.StoreUint32(&done, 1) - wg.Done() - }() - for ; time.Now().Before(until) && atomic.LoadUint32(&done) == 0; i++ { - snap := h.getSnapshot() - iter := snap.NewIterator(util.BytesPrefix([]byte("PTR")), nil) - var prevValue string - var k int - for ; iter.Next(); k++ { - ptrKey := iter.Key() - key := iter.Value() - - if _, err := snap.Get(ptrKey, nil); err != nil { - t.Fatalf("READER #%d snapshot.Get %q: %v", i, ptrKey, err) - } - - if value, err := snap.Get(key, nil); err != nil { - t.Fatalf("READER #%d snapshot.Get %q: %v", i, key, err) - } else if prevValue != "" && string(value) != string(key)+prevValue { - t.Fatalf("READER #%d snapshot.Get %q got invalid value, want %q got %q", i, key, string(key)+prevValue, value) - } else { - prevValue = string(value[len(key):]) - } - } - iter.Release() - snap.Release() - if k > 0 && k != n { - t.Fatalf("#%d %d != %d", i, k, n) - } - } - }() - wg.Wait() -} - -func TestDB_GetProperties(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - _, err := h.db.GetProperty("leveldb.num-files-at-level") - if err == nil { - t.Error("GetProperty() failed to detect missing level") - } - - _, err = h.db.GetProperty("leveldb.num-files-at-level0") - if err != nil { - t.Error("got unexpected error", err) - } - - _, err = h.db.GetProperty("leveldb.num-files-at-level0x") - if err == nil { - t.Error("GetProperty() failed to detect invalid level") - } -} - -func TestDB_GoleveldbIssue72and83(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 1 * opt.MiB, - OpenFilesCacheCapacity: 3, - }) - defer h.close() - - const n, wn, dur = 10000, 100, 30 * time.Second - - runtime.GOMAXPROCS(runtime.NumCPU()) - - randomData := func(prefix byte, i int) []byte { - data := make([]byte, 1+4+32+64+32) - _, err := crand.Reader.Read(data[1 : len(data)-8]) - if err != nil { - panic(err) - } - data[0] = prefix - binary.LittleEndian.PutUint32(data[len(data)-8:], uint32(i)) - binary.LittleEndian.PutUint32(data[len(data)-4:], util.NewCRC(data[:len(data)-4]).Value()) - return data - } - - keys := make([][]byte, n) - for i := range keys { - keys[i] = randomData(1, 0) - } - - until := time.Now().Add(dur) - wg := new(sync.WaitGroup) - wg.Add(3) - var done uint32 - go func() { - i := 0 - defer func() { - t.Logf("WRITER DONE #%d", i) - wg.Done() - }() - - b := new(Batch) - for ; i < wn && atomic.LoadUint32(&done) == 0; i++ { - b.Reset() - for _, k1 := range keys { - k2 := randomData(2, i) - b.Put(k2, randomData(42, i)) - b.Put(k1, k2) - } - if err := h.db.Write(b, h.wo); err != nil { - atomic.StoreUint32(&done, 1) - t.Fatalf("WRITER #%d db.Write: %v", i, err) - } - } - }() - go func() { - var i int - defer func() { - t.Logf("READER0 DONE #%d", i) - atomic.StoreUint32(&done, 1) - wg.Done() - }() - for ; time.Now().Before(until) && atomic.LoadUint32(&done) == 0; i++ { - snap := h.getSnapshot() - seq := snap.elem.seq - if seq == 0 { - snap.Release() - continue - } - iter := snap.NewIterator(util.BytesPrefix([]byte{1}), nil) - writei := int(seq/(n*2) - 1) - var k int - for ; iter.Next(); k++ { - k1 := iter.Key() - k2 := iter.Value() - k1checksum0 := binary.LittleEndian.Uint32(k1[len(k1)-4:]) - k1checksum1 := util.NewCRC(k1[:len(k1)-4]).Value() - if k1checksum0 != k1checksum1 { - t.Fatalf("READER0 #%d.%d W#%d invalid K1 checksum: %#x != %#x", i, k, writei, k1checksum0, k1checksum0) - } - k2checksum0 := binary.LittleEndian.Uint32(k2[len(k2)-4:]) - k2checksum1 := util.NewCRC(k2[:len(k2)-4]).Value() - if k2checksum0 != k2checksum1 { - t.Fatalf("READER0 #%d.%d W#%d invalid K2 checksum: %#x != %#x", i, k, writei, k2checksum0, k2checksum1) - } - kwritei := int(binary.LittleEndian.Uint32(k2[len(k2)-8:])) - if writei != kwritei { - t.Fatalf("READER0 #%d.%d W#%d invalid write iteration num: %d", i, k, writei, kwritei) - } - if _, err := snap.Get(k2, nil); err != nil { - t.Fatalf("READER0 #%d.%d W#%d snap.Get: %v\nk1: %x\n -> k2: %x", i, k, writei, err, k1, k2) - } - } - if err := iter.Error(); err != nil { - t.Fatalf("READER0 #%d.%d W#%d snap.Iterator: %v", i, k, writei, err) - } - iter.Release() - snap.Release() - if k > 0 && k != n { - t.Fatalf("READER0 #%d W#%d short read, got=%d want=%d", i, writei, k, n) - } - } - }() - go func() { - var i int - defer func() { - t.Logf("READER1 DONE #%d", i) - atomic.StoreUint32(&done, 1) - wg.Done() - }() - for ; time.Now().Before(until) && atomic.LoadUint32(&done) == 0; i++ { - iter := h.db.NewIterator(nil, nil) - seq := iter.(*dbIter).seq - if seq == 0 { - iter.Release() - continue - } - writei := int(seq/(n*2) - 1) - var k int - for ok := iter.Last(); ok; ok = iter.Prev() { - k++ - } - if err := iter.Error(); err != nil { - t.Fatalf("READER1 #%d.%d W#%d db.Iterator: %v", i, k, writei, err) - } - iter.Release() - if m := (writei+1)*n + n; k != m { - t.Fatalf("READER1 #%d W#%d short read, got=%d want=%d", i, writei, k, m) - } - } - }() - - wg.Wait() -} - -func TestDB_TransientError(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 128 * opt.KiB, - OpenFilesCacheCapacity: 3, - DisableCompactionBackoff: true, - }) - defer h.close() - - const ( - nSnap = 20 - nKey = 10000 - ) - - var ( - snaps [nSnap]*Snapshot - b = &Batch{} - ) - for i := range snaps { - vtail := fmt.Sprintf("VAL%030d", i) - b.Reset() - for k := 0; k < nKey; k++ { - key := fmt.Sprintf("KEY%8d", k) - b.Put([]byte(key), []byte(key+vtail)) - } - h.stor.EmulateError(testutil.ModeOpen|testutil.ModeRead, storage.TypeTable, errors.New("table transient read error")) - if err := h.db.Write(b, nil); err != nil { - t.Logf("WRITE #%d error: %v", i, err) - h.stor.EmulateError(testutil.ModeOpen|testutil.ModeRead, storage.TypeTable, nil) - for { - if err := h.db.Write(b, nil); err == nil { - break - } else if errors.IsCorrupted(err) { - t.Fatalf("WRITE #%d corrupted: %v", i, err) - } - } - } - - snaps[i] = h.db.newSnapshot() - b.Reset() - for k := 0; k < nKey; k++ { - key := fmt.Sprintf("KEY%8d", k) - b.Delete([]byte(key)) - } - h.stor.EmulateError(testutil.ModeOpen|testutil.ModeRead, storage.TypeTable, errors.New("table transient read error")) - if err := h.db.Write(b, nil); err != nil { - t.Logf("WRITE #%d error: %v", i, err) - h.stor.EmulateError(testutil.ModeOpen|testutil.ModeRead, storage.TypeTable, nil) - for { - if err := h.db.Write(b, nil); err == nil { - break - } else if errors.IsCorrupted(err) { - t.Fatalf("WRITE #%d corrupted: %v", i, err) - } - } - } - } - h.stor.EmulateError(testutil.ModeOpen|testutil.ModeRead, storage.TypeTable, nil) - - runtime.GOMAXPROCS(runtime.NumCPU()) - - rnd := rand.New(rand.NewSource(0xecafdaed)) - wg := &sync.WaitGroup{} - for i, snap := range snaps { - wg.Add(2) - - go func(i int, snap *Snapshot, sk []int) { - defer wg.Done() - - vtail := fmt.Sprintf("VAL%030d", i) - for _, k := range sk { - key := fmt.Sprintf("KEY%8d", k) - xvalue, err := snap.Get([]byte(key), nil) - if err != nil { - t.Fatalf("READER_GET #%d SEQ=%d K%d error: %v", i, snap.elem.seq, k, err) - } - value := key + vtail - if !bytes.Equal([]byte(value), xvalue) { - t.Fatalf("READER_GET #%d SEQ=%d K%d invalid value: want %q, got %q", i, snap.elem.seq, k, value, xvalue) - } - } - }(i, snap, rnd.Perm(nKey)) - - go func(i int, snap *Snapshot) { - defer wg.Done() - - vtail := fmt.Sprintf("VAL%030d", i) - iter := snap.NewIterator(nil, nil) - defer iter.Release() - for k := 0; k < nKey; k++ { - if !iter.Next() { - if err := iter.Error(); err != nil { - t.Fatalf("READER_ITER #%d K%d error: %v", i, k, err) - } else { - t.Fatalf("READER_ITER #%d K%d eoi", i, k) - } - } - key := fmt.Sprintf("KEY%8d", k) - xkey := iter.Key() - if !bytes.Equal([]byte(key), xkey) { - t.Fatalf("READER_ITER #%d K%d invalid key: want %q, got %q", i, k, key, xkey) - } - value := key + vtail - xvalue := iter.Value() - if !bytes.Equal([]byte(value), xvalue) { - t.Fatalf("READER_ITER #%d K%d invalid value: want %q, got %q", i, k, value, xvalue) - } - } - }(i, snap) - } - - wg.Wait() -} - -func TestDB_UkeyShouldntHopAcrossTable(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 112 * opt.KiB, - CompactionTableSize: 90 * opt.KiB, - CompactionExpandLimitFactor: 1, - }) - defer h.close() - - const ( - nSnap = 190 - nKey = 140 - ) - - var ( - snaps [nSnap]*Snapshot - b = &Batch{} - ) - for i := range snaps { - vtail := fmt.Sprintf("VAL%030d", i) - b.Reset() - for k := 0; k < nKey; k++ { - key := fmt.Sprintf("KEY%08d", k) - b.Put([]byte(key), []byte(key+vtail)) - } - if err := h.db.Write(b, nil); err != nil { - t.Fatalf("WRITE #%d error: %v", i, err) - } - - snaps[i] = h.db.newSnapshot() - b.Reset() - for k := 0; k < nKey; k++ { - key := fmt.Sprintf("KEY%08d", k) - b.Delete([]byte(key)) - } - if err := h.db.Write(b, nil); err != nil { - t.Fatalf("WRITE #%d error: %v", i, err) - } - } - - h.compactMem() - - h.waitCompaction() - for level, tables := range h.db.s.stVersion.levels { - for _, table := range tables { - t.Logf("L%d@%d %q:%q", level, table.fd.Num, table.imin, table.imax) - } - } - - h.compactRangeAt(0, "", "") - h.waitCompaction() - for level, tables := range h.db.s.stVersion.levels { - for _, table := range tables { - t.Logf("L%d@%d %q:%q", level, table.fd.Num, table.imin, table.imax) - } - } - h.compactRangeAt(1, "", "") - h.waitCompaction() - for level, tables := range h.db.s.stVersion.levels { - for _, table := range tables { - t.Logf("L%d@%d %q:%q", level, table.fd.Num, table.imin, table.imax) - } - } - runtime.GOMAXPROCS(runtime.NumCPU()) - - wg := &sync.WaitGroup{} - for i, snap := range snaps { - wg.Add(1) - - go func(i int, snap *Snapshot) { - defer wg.Done() - - vtail := fmt.Sprintf("VAL%030d", i) - for k := 0; k < nKey; k++ { - key := fmt.Sprintf("KEY%08d", k) - xvalue, err := snap.Get([]byte(key), nil) - if err != nil { - t.Fatalf("READER_GET #%d SEQ=%d K%d error: %v", i, snap.elem.seq, k, err) - } - value := key + vtail - if !bytes.Equal([]byte(value), xvalue) { - t.Fatalf("READER_GET #%d SEQ=%d K%d invalid value: want %q, got %q", i, snap.elem.seq, k, value, xvalue) - } - } - }(i, snap) - } - - wg.Wait() -} - -func TestDB_TableCompactionBuilder(t *testing.T) { - gomega.RegisterTestingT(t) - stor := testutil.NewStorage() - stor.OnLog(testingLogger(t)) - stor.OnClose(testingPreserveOnFailed(t)) - defer stor.Close() - - const nSeq = 99 - - o := &opt.Options{ - DisableLargeBatchTransaction: true, - WriteBuffer: 112 * opt.KiB, - CompactionTableSize: 43 * opt.KiB, - CompactionExpandLimitFactor: 1, - CompactionGPOverlapsFactor: 1, - DisableBlockCache: true, - } - s, err := newSession(stor, o) - if err != nil { - t.Fatal(err) - } - if err := s.create(); err != nil { - t.Fatal(err) - } - defer s.close() - var ( - seq uint64 - targetSize = 5 * o.CompactionTableSize - value = bytes.Repeat([]byte{'0'}, 100) - ) - for i := 0; i < 2; i++ { - tw, err := s.tops.create() - if err != nil { - t.Fatal(err) - } - for k := 0; tw.tw.BytesLen() < targetSize; k++ { - key := []byte(fmt.Sprintf("%09d", k)) - seq += nSeq - 1 - for x := uint64(0); x < nSeq; x++ { - if err := tw.append(makeInternalKey(nil, key, seq-x, keyTypeVal), value); err != nil { - t.Fatal(err) - } - } - } - tf, err := tw.finish() - if err != nil { - t.Fatal(err) - } - rec := &sessionRecord{} - rec.addTableFile(i, tf) - if err := s.commit(rec); err != nil { - t.Fatal(err) - } - } - - // Build grandparent. - v := s.version() - c := newCompaction(s, v, 1, append(tFiles{}, v.levels[1]...)) - rec := &sessionRecord{} - b := &tableCompactionBuilder{ - s: s, - c: c, - rec: rec, - stat1: new(cStatStaging), - minSeq: 0, - strict: true, - tableSize: o.CompactionTableSize/3 + 961, - } - if err := b.run(new(compactionTransactCounter)); err != nil { - t.Fatal(err) - } - for _, t := range c.levels[0] { - rec.delTable(c.sourceLevel, t.fd.Num) - } - if err := s.commit(rec); err != nil { - t.Fatal(err) - } - c.release() - - // Build level-1. - v = s.version() - c = newCompaction(s, v, 0, append(tFiles{}, v.levels[0]...)) - rec = &sessionRecord{} - b = &tableCompactionBuilder{ - s: s, - c: c, - rec: rec, - stat1: new(cStatStaging), - minSeq: 0, - strict: true, - tableSize: o.CompactionTableSize, - } - if err := b.run(new(compactionTransactCounter)); err != nil { - t.Fatal(err) - } - for _, t := range c.levels[0] { - rec.delTable(c.sourceLevel, t.fd.Num) - } - // Move grandparent to level-3 - for _, t := range v.levels[2] { - rec.delTable(2, t.fd.Num) - rec.addTableFile(3, t) - } - if err := s.commit(rec); err != nil { - t.Fatal(err) - } - c.release() - - v = s.version() - for level, want := range []bool{false, true, false, true} { - got := len(v.levels[level]) > 0 - if want != got { - t.Fatalf("invalid level-%d tables len: want %v, got %v", level, want, got) - } - } - for i, f := range v.levels[1][:len(v.levels[1])-1] { - nf := v.levels[1][i+1] - if bytes.Equal(f.imax.ukey(), nf.imin.ukey()) { - t.Fatalf("KEY %q hop across table %d .. %d", f.imax.ukey(), f.fd.Num, nf.fd.Num) - } - } - v.release() - - // Compaction with transient error. - v = s.version() - c = newCompaction(s, v, 1, append(tFiles{}, v.levels[1]...)) - rec = &sessionRecord{} - b = &tableCompactionBuilder{ - s: s, - c: c, - rec: rec, - stat1: new(cStatStaging), - minSeq: 0, - strict: true, - tableSize: o.CompactionTableSize, - } - stor.EmulateErrorOnce(testutil.ModeSync, storage.TypeTable, errors.New("table sync error (once)")) - stor.EmulateRandomError(testutil.ModeRead|testutil.ModeWrite, storage.TypeTable, 0.01, errors.New("table random IO error")) - for { - if err := b.run(new(compactionTransactCounter)); err != nil { - t.Logf("(expected) b.run: %v", err) - } else { - break - } - } - if err := s.commit(rec); err != nil { - t.Fatal(err) - } - c.release() - - stor.EmulateErrorOnce(testutil.ModeSync, storage.TypeTable, nil) - stor.EmulateRandomError(testutil.ModeRead|testutil.ModeWrite, storage.TypeTable, 0, nil) - - v = s.version() - if len(v.levels[1]) != len(v.levels[2]) { - t.Fatalf("invalid tables length, want %d, got %d", len(v.levels[1]), len(v.levels[2])) - } - for i, f0 := range v.levels[1] { - f1 := v.levels[2][i] - iter0 := s.tops.newIterator(f0, nil, nil) - iter1 := s.tops.newIterator(f1, nil, nil) - for j := 0; true; j++ { - next0 := iter0.Next() - next1 := iter1.Next() - if next0 != next1 { - t.Fatalf("#%d.%d invalid eoi: want %v, got %v", i, j, next0, next1) - } - key0 := iter0.Key() - key1 := iter1.Key() - if !bytes.Equal(key0, key1) { - t.Fatalf("#%d.%d invalid key: want %q, got %q", i, j, key0, key1) - } - if next0 == false { - break - } - } - iter0.Release() - iter1.Release() - } - v.release() -} - -func testDB_IterTriggeredCompaction(t *testing.T, limitDiv int) { - const ( - vSize = 200 * opt.KiB - tSize = 100 * opt.MiB - mIter = 100 - n = tSize / vSize - ) - - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - Compression: opt.NoCompression, - DisableBlockCache: true, - }) - defer h.close() - - h.db.memdbMaxLevel = 2 - - key := func(x int) string { - return fmt.Sprintf("v%06d", x) - } - - // Fill. - value := strings.Repeat("x", vSize) - for i := 0; i < n; i++ { - h.put(key(i), value) - } - h.compactMem() - - // Delete all. - for i := 0; i < n; i++ { - h.delete(key(i)) - } - h.compactMem() - - var ( - limit = n / limitDiv - - startKey = key(0) - limitKey = key(limit) - maxKey = key(n) - slice = &util.Range{Limit: []byte(limitKey)} - - initialSize0 = h.sizeOf(startKey, limitKey) - initialSize1 = h.sizeOf(limitKey, maxKey) - ) - - t.Logf("initial size %s [rest %s]", shortenb(int(initialSize0)), shortenb(int(initialSize1))) - - for r := 0; true; r++ { - if r >= mIter { - t.Fatal("taking too long to compact") - } - - // Iterates. - iter := h.db.NewIterator(slice, h.ro) - for iter.Next() { - } - if err := iter.Error(); err != nil { - t.Fatalf("Iter err: %v", err) - } - iter.Release() - - // Wait compaction. - h.waitCompaction() - - // Check size. - size0 := h.sizeOf(startKey, limitKey) - size1 := h.sizeOf(limitKey, maxKey) - t.Logf("#%03d size %s [rest %s]", r, shortenb(int(size0)), shortenb(int(size1))) - if size0 < initialSize0/10 { - break - } - } - - if initialSize1 > 0 { - h.sizeAssert(limitKey, maxKey, initialSize1/4-opt.MiB, initialSize1+opt.MiB) - } -} - -func TestDB_IterTriggeredCompaction(t *testing.T) { - testDB_IterTriggeredCompaction(t, 1) -} - -func TestDB_IterTriggeredCompactionHalf(t *testing.T) { - testDB_IterTriggeredCompaction(t, 2) -} - -func TestDB_ReadOnly(t *testing.T) { - h := newDbHarness(t) - defer h.close() - - h.put("foo", "v1") - h.put("bar", "v2") - h.compactMem() - - h.put("xfoo", "v1") - h.put("xbar", "v2") - - t.Log("Trigger read-only") - if err := h.db.SetReadOnly(); err != nil { - h.close() - t.Fatalf("SetReadOnly error: %v", err) - } - - mode := testutil.ModeCreate | testutil.ModeRemove | testutil.ModeRename | testutil.ModeWrite | testutil.ModeSync - h.stor.EmulateError(mode, storage.TypeAll, errors.New("read-only DB shouldn't writes")) - - ro := func(key, value, wantValue string) { - if err := h.db.Put([]byte(key), []byte(value), h.wo); err != ErrReadOnly { - t.Fatalf("unexpected error: %v", err) - } - h.getVal(key, wantValue) - } - - ro("foo", "vx", "v1") - - h.o.ReadOnly = true - h.reopenDB() - - ro("foo", "vx", "v1") - ro("bar", "vx", "v2") - h.assertNumKeys(4) -} - -func TestDB_BulkInsertDelete(t *testing.T) { - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - Compression: opt.NoCompression, - CompactionTableSize: 128 * opt.KiB, - CompactionTotalSize: 1 * opt.MiB, - WriteBuffer: 256 * opt.KiB, - }) - defer h.close() - - const R = 100 - const N = 2500 - key := make([]byte, 4) - value := make([]byte, 256) - for i := 0; i < R; i++ { - offset := N * i - for j := 0; j < N; j++ { - binary.BigEndian.PutUint32(key, uint32(offset+j)) - h.db.Put(key, value, nil) - } - for j := 0; j < N; j++ { - binary.BigEndian.PutUint32(key, uint32(offset+j)) - h.db.Delete(key, nil) - } - } - - h.waitCompaction() - if tot := h.totalTables(); tot > 10 { - t.Fatalf("too many uncompacted tables: %d (%s)", tot, h.getTablesPerLevel()) - } -} - -func TestDB_GracefulClose(t *testing.T) { - runtime.GOMAXPROCS(4) - h := newDbHarnessWopt(t, &opt.Options{ - DisableLargeBatchTransaction: true, - Compression: opt.NoCompression, - CompactionTableSize: 1 * opt.MiB, - WriteBuffer: 1 * opt.MiB, - }) - defer h.close() - - var closeWait sync.WaitGroup - - // During write. - n := 0 - closing := false - for i := 0; i < 1000000; i++ { - if !closing && h.totalTables() > 3 { - t.Logf("close db during write, index=%d", i) - closeWait.Add(1) - go func() { - h.closeDB() - closeWait.Done() - }() - closing = true - } - if err := h.db.Put([]byte(fmt.Sprintf("%09d", i)), []byte(fmt.Sprintf("VAL-%09d", i)), h.wo); err != nil { - t.Logf("Put error: %s (expected)", err) - n = i - break - } - } - closeWait.Wait() - - // During read. - h.openDB() - closing = false - for i := 0; i < n; i++ { - if !closing && i > n/2 { - t.Logf("close db during read, index=%d", i) - closeWait.Add(1) - go func() { - h.closeDB() - closeWait.Done() - }() - closing = true - } - if _, err := h.db.Get([]byte(fmt.Sprintf("%09d", i)), h.ro); err != nil { - t.Logf("Get error: %s (expected)", err) - break - } - } - closeWait.Wait() - - // During iterate. - h.openDB() - closing = false - iter := h.db.NewIterator(nil, h.ro) - for i := 0; iter.Next(); i++ { - if len(iter.Key()) == 0 || len(iter.Value()) == 0 { - t.Error("Key or value has zero length") - } - if !closing { - t.Logf("close db during iter, index=%d", i) - closeWait.Add(1) - go func() { - h.closeDB() - closeWait.Done() - }() - closing = true - } - time.Sleep(time.Millisecond) - } - if err := iter.Error(); err != nil { - t.Logf("Iter error: %s (expected)", err) - } - iter.Release() - closeWait.Wait() -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_transaction.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_transaction.go deleted file mode 100644 index b8f7e7d..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_transaction.go +++ /dev/null @@ -1,325 +0,0 @@ -// Copyright (c) 2016, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "errors" - "sync" - "time" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/util" -) - -var errTransactionDone = errors.New("leveldb: transaction already closed") - -// Transaction is the transaction handle. -type Transaction struct { - db *DB - lk sync.RWMutex - seq uint64 - mem *memDB - tables tFiles - ikScratch []byte - rec sessionRecord - stats cStatStaging - closed bool -} - -// Get gets the value for the given key. It returns ErrNotFound if the -// DB does not contains the key. -// -// The returned slice is its own copy, it is safe to modify the contents -// of the returned slice. -// It is safe to modify the contents of the argument after Get returns. -func (tr *Transaction) Get(key []byte, ro *opt.ReadOptions) ([]byte, error) { - tr.lk.RLock() - defer tr.lk.RUnlock() - if tr.closed { - return nil, errTransactionDone - } - return tr.db.get(tr.mem.DB, tr.tables, key, tr.seq, ro) -} - -// Has returns true if the DB does contains the given key. -// -// It is safe to modify the contents of the argument after Has returns. -func (tr *Transaction) Has(key []byte, ro *opt.ReadOptions) (bool, error) { - tr.lk.RLock() - defer tr.lk.RUnlock() - if tr.closed { - return false, errTransactionDone - } - return tr.db.has(tr.mem.DB, tr.tables, key, tr.seq, ro) -} - -// NewIterator returns an iterator for the latest snapshot of the transaction. -// The returned iterator is not safe for concurrent use, but it is safe to use -// multiple iterators concurrently, with each in a dedicated goroutine. -// It is also safe to use an iterator concurrently while writes to the -// transaction. The resultant key/value pairs are guaranteed to be consistent. -// -// Slice allows slicing the iterator to only contains keys in the given -// range. A nil Range.Start is treated as a key before all keys in the -// DB. And a nil Range.Limit is treated as a key after all keys in -// the DB. -// -// The iterator must be released after use, by calling Release method. -// -// Also read Iterator documentation of the leveldb/iterator package. -func (tr *Transaction) NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator { - tr.lk.RLock() - defer tr.lk.RUnlock() - if tr.closed { - return iterator.NewEmptyIterator(errTransactionDone) - } - tr.mem.incref() - return tr.db.newIterator(tr.mem, tr.tables, tr.seq, slice, ro) -} - -func (tr *Transaction) flush() error { - // Flush memdb. - if tr.mem.Len() != 0 { - tr.stats.startTimer() - iter := tr.mem.NewIterator(nil) - t, n, err := tr.db.s.tops.createFrom(iter) - iter.Release() - tr.stats.stopTimer() - if err != nil { - return err - } - if tr.mem.getref() == 1 { - tr.mem.Reset() - } else { - tr.mem.decref() - tr.mem = tr.db.mpoolGet(0) - tr.mem.incref() - } - tr.tables = append(tr.tables, t) - tr.rec.addTableFile(0, t) - tr.stats.write += t.size - tr.db.logf("transaction@flush created L0@%d N·%d S·%s %q:%q", t.fd.Num, n, shortenb(int(t.size)), t.imin, t.imax) - } - return nil -} - -func (tr *Transaction) put(kt keyType, key, value []byte) error { - tr.ikScratch = makeInternalKey(tr.ikScratch, key, tr.seq+1, kt) - if tr.mem.Free() < len(tr.ikScratch)+len(value) { - if err := tr.flush(); err != nil { - return err - } - } - if err := tr.mem.Put(tr.ikScratch, value); err != nil { - return err - } - tr.seq++ - return nil -} - -// Put sets the value for the given key. It overwrites any previous value -// for that key; a DB is not a multi-map. -// Please note that the transaction is not compacted until committed, so if you -// writes 10 same keys, then those 10 same keys are in the transaction. -// -// It is safe to modify the contents of the arguments after Put returns. -func (tr *Transaction) Put(key, value []byte, wo *opt.WriteOptions) error { - tr.lk.Lock() - defer tr.lk.Unlock() - if tr.closed { - return errTransactionDone - } - return tr.put(keyTypeVal, key, value) -} - -// Delete deletes the value for the given key. -// Please note that the transaction is not compacted until committed, so if you -// writes 10 same keys, then those 10 same keys are in the transaction. -// -// It is safe to modify the contents of the arguments after Delete returns. -func (tr *Transaction) Delete(key []byte, wo *opt.WriteOptions) error { - tr.lk.Lock() - defer tr.lk.Unlock() - if tr.closed { - return errTransactionDone - } - return tr.put(keyTypeDel, key, nil) -} - -// Write apply the given batch to the transaction. The batch will be applied -// sequentially. -// Please note that the transaction is not compacted until committed, so if you -// writes 10 same keys, then those 10 same keys are in the transaction. -// -// It is safe to modify the contents of the arguments after Write returns. -func (tr *Transaction) Write(b *Batch, wo *opt.WriteOptions) error { - if b == nil || b.Len() == 0 { - return nil - } - - tr.lk.Lock() - defer tr.lk.Unlock() - if tr.closed { - return errTransactionDone - } - return b.replayInternal(func(i int, kt keyType, k, v []byte) error { - return tr.put(kt, k, v) - }) -} - -func (tr *Transaction) setDone() { - tr.closed = true - tr.db.tr = nil - tr.mem.decref() - <-tr.db.writeLockC -} - -// Commit commits the transaction. If error is not nil, then the transaction is -// not committed, it can then either be retried or discarded. -// -// Other methods should not be called after transaction has been committed. -func (tr *Transaction) Commit() error { - if err := tr.db.ok(); err != nil { - return err - } - - tr.lk.Lock() - defer tr.lk.Unlock() - if tr.closed { - return errTransactionDone - } - if err := tr.flush(); err != nil { - // Return error, lets user decide either to retry or discard - // transaction. - return err - } - if len(tr.tables) != 0 { - // Committing transaction. - tr.rec.setSeqNum(tr.seq) - tr.db.compCommitLk.Lock() - tr.stats.startTimer() - var cerr error - for retry := 0; retry < 3; retry++ { - cerr = tr.db.s.commit(&tr.rec) - if cerr != nil { - tr.db.logf("transaction@commit error R·%d %q", retry, cerr) - select { - case <-time.After(time.Second): - case <-tr.db.closeC: - tr.db.logf("transaction@commit exiting") - tr.db.compCommitLk.Unlock() - return cerr - } - } else { - // Success. Set db.seq. - tr.db.setSeq(tr.seq) - break - } - } - tr.stats.stopTimer() - if cerr != nil { - // Return error, lets user decide either to retry or discard - // transaction. - return cerr - } - - // Update compaction stats. This is safe as long as we hold compCommitLk. - tr.db.compStats.addStat(0, &tr.stats) - - // Trigger table auto-compaction. - tr.db.compTrigger(tr.db.tcompCmdC) - tr.db.compCommitLk.Unlock() - - // Additionally, wait compaction when certain threshold reached. - // Ignore error, returns error only if transaction can't be committed. - tr.db.waitCompaction() - } - // Only mark as done if transaction committed successfully. - tr.setDone() - return nil -} - -func (tr *Transaction) discard() { - // Discard transaction. - for _, t := range tr.tables { - tr.db.logf("transaction@discard @%d", t.fd.Num) - if err1 := tr.db.s.stor.Remove(t.fd); err1 == nil { - tr.db.s.reuseFileNum(t.fd.Num) - } - } -} - -// Discard discards the transaction. -// -// Other methods should not be called after transaction has been discarded. -func (tr *Transaction) Discard() { - tr.lk.Lock() - if !tr.closed { - tr.discard() - tr.setDone() - } - tr.lk.Unlock() -} - -func (db *DB) waitCompaction() error { - if db.s.tLen(0) >= db.s.o.GetWriteL0PauseTrigger() { - return db.compTriggerWait(db.tcompCmdC) - } - return nil -} - -// OpenTransaction opens an atomic DB transaction. Only one transaction can be -// opened at a time. Subsequent call to Write and OpenTransaction will be blocked -// until in-flight transaction is committed or discarded. -// The returned transaction handle is safe for concurrent use. -// -// Transaction is expensive and can overwhelm compaction, especially if -// transaction size is small. Use with caution. -// -// The transaction must be closed once done, either by committing or discarding -// the transaction. -// Closing the DB will discard open transaction. -func (db *DB) OpenTransaction() (*Transaction, error) { - if err := db.ok(); err != nil { - return nil, err - } - - // The write happen synchronously. - select { - case db.writeLockC <- struct{}{}: - case err := <-db.compPerErrC: - return nil, err - case <-db.closeC: - return nil, ErrClosed - } - - if db.tr != nil { - panic("leveldb: has open transaction") - } - - // Flush current memdb. - if db.mem != nil && db.mem.Len() != 0 { - if _, err := db.rotateMem(0, true); err != nil { - return nil, err - } - } - - // Wait compaction when certain threshold reached. - if err := db.waitCompaction(); err != nil { - return nil, err - } - - tr := &Transaction{ - db: db, - seq: db.seq, - mem: db.mpoolGet(0), - } - tr.mem.incref() - db.tr = tr - return tr, nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_util.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_util.go deleted file mode 100644 index 7ecd960..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_util.go +++ /dev/null @@ -1,102 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// Reader is the interface that wraps basic Get and NewIterator methods. -// This interface implemented by both DB and Snapshot. -type Reader interface { - Get(key []byte, ro *opt.ReadOptions) (value []byte, err error) - NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator -} - -// Sizes is list of size. -type Sizes []int64 - -// Sum returns sum of the sizes. -func (sizes Sizes) Sum() int64 { - var sum int64 - for _, size := range sizes { - sum += size - } - return sum -} - -// Logging. -func (db *DB) log(v ...interface{}) { db.s.log(v...) } -func (db *DB) logf(format string, v ...interface{}) { db.s.logf(format, v...) } - -// Check and clean files. -func (db *DB) checkAndCleanFiles() error { - v := db.s.version() - defer v.release() - - tmap := make(map[int64]bool) - for _, tables := range v.levels { - for _, t := range tables { - tmap[t.fd.Num] = false - } - } - - fds, err := db.s.stor.List(storage.TypeAll) - if err != nil { - return err - } - - var nt int - var rem []storage.FileDesc - for _, fd := range fds { - keep := true - switch fd.Type { - case storage.TypeManifest: - keep = fd.Num >= db.s.manifestFd.Num - case storage.TypeJournal: - if !db.frozenJournalFd.Zero() { - keep = fd.Num >= db.frozenJournalFd.Num - } else { - keep = fd.Num >= db.journalFd.Num - } - case storage.TypeTable: - _, keep = tmap[fd.Num] - if keep { - tmap[fd.Num] = true - nt++ - } - } - - if !keep { - rem = append(rem, fd) - } - } - - if nt != len(tmap) { - var mfds []storage.FileDesc - for num, present := range tmap { - if !present { - mfds = append(mfds, storage.FileDesc{storage.TypeTable, num}) - db.logf("db@janitor table missing @%d", num) - } - } - return errors.NewErrCorrupted(storage.FileDesc{}, &errors.ErrMissingFiles{Fds: mfds}) - } - - db.logf("db@janitor F·%d G·%d", len(fds), len(rem)) - for _, fd := range rem { - db.logf("db@janitor removing %s-%d", fd.Type, fd.Num) - if err := db.s.stor.Remove(fd); err != nil { - return err - } - } - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/db_write.go b/vendor/github.com/syndtr/goleveldb/leveldb/db_write.go deleted file mode 100644 index 31f4bc5..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/db_write.go +++ /dev/null @@ -1,460 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "sync/atomic" - "time" - - "github.com/syndtr/goleveldb/leveldb/memdb" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/util" -) - -func (db *DB) writeJournal(batches []*Batch, seq uint64, sync bool) error { - wr, err := db.journal.Next() - if err != nil { - return err - } - if err := writeBatchesWithHeader(wr, batches, seq); err != nil { - return err - } - if err := db.journal.Flush(); err != nil { - return err - } - if sync { - return db.journalWriter.Sync() - } - return nil -} - -func (db *DB) rotateMem(n int, wait bool) (mem *memDB, err error) { - retryLimit := 3 -retry: - // Wait for pending memdb compaction. - err = db.compTriggerWait(db.mcompCmdC) - if err != nil { - return - } - retryLimit-- - - // Create new memdb and journal. - mem, err = db.newMem(n) - if err != nil { - if err == errHasFrozenMem { - if retryLimit <= 0 { - panic("BUG: still has frozen memdb") - } - goto retry - } - return - } - - // Schedule memdb compaction. - if wait { - err = db.compTriggerWait(db.mcompCmdC) - } else { - db.compTrigger(db.mcompCmdC) - } - return -} - -func (db *DB) flush(n int) (mdb *memDB, mdbFree int, err error) { - delayed := false - slowdownTrigger := db.s.o.GetWriteL0SlowdownTrigger() - pauseTrigger := db.s.o.GetWriteL0PauseTrigger() - flush := func() (retry bool) { - mdb = db.getEffectiveMem() - if mdb == nil { - err = ErrClosed - return false - } - defer func() { - if retry { - mdb.decref() - mdb = nil - } - }() - tLen := db.s.tLen(0) - mdbFree = mdb.Free() - switch { - case tLen >= slowdownTrigger && !delayed: - delayed = true - time.Sleep(time.Millisecond) - case mdbFree >= n: - return false - case tLen >= pauseTrigger: - delayed = true - err = db.compTriggerWait(db.tcompCmdC) - if err != nil { - return false - } - default: - // Allow memdb to grow if it has no entry. - if mdb.Len() == 0 { - mdbFree = n - } else { - mdb.decref() - mdb, err = db.rotateMem(n, false) - if err == nil { - mdbFree = mdb.Free() - } else { - mdbFree = 0 - } - } - return false - } - return true - } - start := time.Now() - for flush() { - } - if delayed { - db.writeDelay += time.Since(start) - db.writeDelayN++ - } else if db.writeDelayN > 0 { - db.logf("db@write was delayed N·%d T·%v", db.writeDelayN, db.writeDelay) - atomic.AddInt32(&db.cWriteDelayN, int32(db.writeDelayN)) - atomic.AddInt64(&db.cWriteDelay, int64(db.writeDelay)) - db.writeDelay = 0 - db.writeDelayN = 0 - } - return -} - -type writeMerge struct { - sync bool - batch *Batch - keyType keyType - key, value []byte -} - -func (db *DB) unlockWrite(overflow bool, merged int, err error) { - for i := 0; i < merged; i++ { - db.writeAckC <- err - } - if overflow { - // Pass lock to the next write (that failed to merge). - db.writeMergedC <- false - } else { - // Release lock. - <-db.writeLockC - } -} - -// ourBatch is batch that we can modify. -func (db *DB) writeLocked(batch, ourBatch *Batch, merge, sync bool) error { - // Try to flush memdb. This method would also trying to throttle writes - // if it is too fast and compaction cannot catch-up. - mdb, mdbFree, err := db.flush(batch.internalLen) - if err != nil { - db.unlockWrite(false, 0, err) - return err - } - defer mdb.decref() - - var ( - overflow bool - merged int - batches = []*Batch{batch} - ) - - if merge { - // Merge limit. - var mergeLimit int - if batch.internalLen > 128<<10 { - mergeLimit = (1 << 20) - batch.internalLen - } else { - mergeLimit = 128 << 10 - } - mergeCap := mdbFree - batch.internalLen - if mergeLimit > mergeCap { - mergeLimit = mergeCap - } - - merge: - for mergeLimit > 0 { - select { - case incoming := <-db.writeMergeC: - if incoming.batch != nil { - // Merge batch. - if incoming.batch.internalLen > mergeLimit { - overflow = true - break merge - } - batches = append(batches, incoming.batch) - mergeLimit -= incoming.batch.internalLen - } else { - // Merge put. - internalLen := len(incoming.key) + len(incoming.value) + 8 - if internalLen > mergeLimit { - overflow = true - break merge - } - if ourBatch == nil { - ourBatch = db.batchPool.Get().(*Batch) - ourBatch.Reset() - batches = append(batches, ourBatch) - } - // We can use same batch since concurrent write doesn't - // guarantee write order. - ourBatch.appendRec(incoming.keyType, incoming.key, incoming.value) - mergeLimit -= internalLen - } - sync = sync || incoming.sync - merged++ - db.writeMergedC <- true - - default: - break merge - } - } - } - - // Release ourBatch if any. - if ourBatch != nil { - defer db.batchPool.Put(ourBatch) - } - - // Seq number. - seq := db.seq + 1 - - // Write journal. - if err := db.writeJournal(batches, seq, sync); err != nil { - db.unlockWrite(overflow, merged, err) - return err - } - - // Put batches. - for _, batch := range batches { - if err := batch.putMem(seq, mdb.DB); err != nil { - panic(err) - } - seq += uint64(batch.Len()) - } - - // Incr seq number. - db.addSeq(uint64(batchesLen(batches))) - - // Rotate memdb if it's reach the threshold. - if batch.internalLen >= mdbFree { - db.rotateMem(0, false) - } - - db.unlockWrite(overflow, merged, nil) - return nil -} - -// Write apply the given batch to the DB. The batch records will be applied -// sequentially. Write might be used concurrently, when used concurrently and -// batch is small enough, write will try to merge the batches. Set NoWriteMerge -// option to true to disable write merge. -// -// It is safe to modify the contents of the arguments after Write returns but -// not before. Write will not modify content of the batch. -func (db *DB) Write(batch *Batch, wo *opt.WriteOptions) error { - if err := db.ok(); err != nil || batch == nil || batch.Len() == 0 { - return err - } - - // If the batch size is larger than write buffer, it may justified to write - // using transaction instead. Using transaction the batch will be written - // into tables directly, skipping the journaling. - if batch.internalLen > db.s.o.GetWriteBuffer() && !db.s.o.GetDisableLargeBatchTransaction() { - tr, err := db.OpenTransaction() - if err != nil { - return err - } - if err := tr.Write(batch, wo); err != nil { - tr.Discard() - return err - } - return tr.Commit() - } - - merge := !wo.GetNoWriteMerge() && !db.s.o.GetNoWriteMerge() - sync := wo.GetSync() && !db.s.o.GetNoSync() - - // Acquire write lock. - if merge { - select { - case db.writeMergeC <- writeMerge{sync: sync, batch: batch}: - if <-db.writeMergedC { - // Write is merged. - return <-db.writeAckC - } - // Write is not merged, the write lock is handed to us. Continue. - case db.writeLockC <- struct{}{}: - // Write lock acquired. - case err := <-db.compPerErrC: - // Compaction error. - return err - case <-db.closeC: - // Closed - return ErrClosed - } - } else { - select { - case db.writeLockC <- struct{}{}: - // Write lock acquired. - case err := <-db.compPerErrC: - // Compaction error. - return err - case <-db.closeC: - // Closed - return ErrClosed - } - } - - return db.writeLocked(batch, nil, merge, sync) -} - -func (db *DB) putRec(kt keyType, key, value []byte, wo *opt.WriteOptions) error { - if err := db.ok(); err != nil { - return err - } - - merge := !wo.GetNoWriteMerge() && !db.s.o.GetNoWriteMerge() - sync := wo.GetSync() && !db.s.o.GetNoSync() - - // Acquire write lock. - if merge { - select { - case db.writeMergeC <- writeMerge{sync: sync, keyType: kt, key: key, value: value}: - if <-db.writeMergedC { - // Write is merged. - return <-db.writeAckC - } - // Write is not merged, the write lock is handed to us. Continue. - case db.writeLockC <- struct{}{}: - // Write lock acquired. - case err := <-db.compPerErrC: - // Compaction error. - return err - case <-db.closeC: - // Closed - return ErrClosed - } - } else { - select { - case db.writeLockC <- struct{}{}: - // Write lock acquired. - case err := <-db.compPerErrC: - // Compaction error. - return err - case <-db.closeC: - // Closed - return ErrClosed - } - } - - batch := db.batchPool.Get().(*Batch) - batch.Reset() - batch.appendRec(kt, key, value) - return db.writeLocked(batch, batch, merge, sync) -} - -// Put sets the value for the given key. It overwrites any previous value -// for that key; a DB is not a multi-map. Write merge also applies for Put, see -// Write. -// -// It is safe to modify the contents of the arguments after Put returns but not -// before. -func (db *DB) Put(key, value []byte, wo *opt.WriteOptions) error { - return db.putRec(keyTypeVal, key, value, wo) -} - -// Delete deletes the value for the given key. Delete will not returns error if -// key doesn't exist. Write merge also applies for Delete, see Write. -// -// It is safe to modify the contents of the arguments after Delete returns but -// not before. -func (db *DB) Delete(key []byte, wo *opt.WriteOptions) error { - return db.putRec(keyTypeDel, key, nil, wo) -} - -func isMemOverlaps(icmp *iComparer, mem *memdb.DB, min, max []byte) bool { - iter := mem.NewIterator(nil) - defer iter.Release() - return (max == nil || (iter.First() && icmp.uCompare(max, internalKey(iter.Key()).ukey()) >= 0)) && - (min == nil || (iter.Last() && icmp.uCompare(min, internalKey(iter.Key()).ukey()) <= 0)) -} - -// CompactRange compacts the underlying DB for the given key range. -// In particular, deleted and overwritten versions are discarded, -// and the data is rearranged to reduce the cost of operations -// needed to access the data. This operation should typically only -// be invoked by users who understand the underlying implementation. -// -// A nil Range.Start is treated as a key before all keys in the DB. -// And a nil Range.Limit is treated as a key after all keys in the DB. -// Therefore if both is nil then it will compact entire DB. -func (db *DB) CompactRange(r util.Range) error { - if err := db.ok(); err != nil { - return err - } - - // Lock writer. - select { - case db.writeLockC <- struct{}{}: - case err := <-db.compPerErrC: - return err - case <-db.closeC: - return ErrClosed - } - - // Check for overlaps in memdb. - mdb := db.getEffectiveMem() - if mdb == nil { - return ErrClosed - } - defer mdb.decref() - if isMemOverlaps(db.s.icmp, mdb.DB, r.Start, r.Limit) { - // Memdb compaction. - if _, err := db.rotateMem(0, false); err != nil { - <-db.writeLockC - return err - } - <-db.writeLockC - if err := db.compTriggerWait(db.mcompCmdC); err != nil { - return err - } - } else { - <-db.writeLockC - } - - // Table compaction. - return db.compTriggerRange(db.tcompCmdC, -1, r.Start, r.Limit) -} - -// SetReadOnly makes DB read-only. It will stay read-only until reopened. -func (db *DB) SetReadOnly() error { - if err := db.ok(); err != nil { - return err - } - - // Lock writer. - select { - case db.writeLockC <- struct{}{}: - db.compWriteLocking = true - case err := <-db.compPerErrC: - return err - case <-db.closeC: - return ErrClosed - } - - // Set compaction read-only. - select { - case db.compErrSetC <- ErrReadOnly: - case perr := <-db.compPerErrC: - return perr - case <-db.closeC: - return ErrClosed - } - - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/doc.go b/vendor/github.com/syndtr/goleveldb/leveldb/doc.go deleted file mode 100644 index be768e5..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/doc.go +++ /dev/null @@ -1,92 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package leveldb provides implementation of LevelDB key/value database. -// -// Create or open a database: -// -// // The returned DB instance is safe for concurrent use. Which mean that all -// // DB's methods may be called concurrently from multiple goroutine. -// db, err := leveldb.OpenFile("path/to/db", nil) -// ... -// defer db.Close() -// ... -// -// Read or modify the database content: -// -// // Remember that the contents of the returned slice should not be modified. -// data, err := db.Get([]byte("key"), nil) -// ... -// err = db.Put([]byte("key"), []byte("value"), nil) -// ... -// err = db.Delete([]byte("key"), nil) -// ... -// -// Iterate over database content: -// -// iter := db.NewIterator(nil, nil) -// for iter.Next() { -// // Remember that the contents of the returned slice should not be modified, and -// // only valid until the next call to Next. -// key := iter.Key() -// value := iter.Value() -// ... -// } -// iter.Release() -// err = iter.Error() -// ... -// -// Iterate over subset of database content with a particular prefix: -// iter := db.NewIterator(util.BytesPrefix([]byte("foo-")), nil) -// for iter.Next() { -// // Use key/value. -// ... -// } -// iter.Release() -// err = iter.Error() -// ... -// -// Seek-then-Iterate: -// -// iter := db.NewIterator(nil, nil) -// for ok := iter.Seek(key); ok; ok = iter.Next() { -// // Use key/value. -// ... -// } -// iter.Release() -// err = iter.Error() -// ... -// -// Iterate over subset of database content: -// -// iter := db.NewIterator(&util.Range{Start: []byte("foo"), Limit: []byte("xoo")}, nil) -// for iter.Next() { -// // Use key/value. -// ... -// } -// iter.Release() -// err = iter.Error() -// ... -// -// Batch writes: -// -// batch := new(leveldb.Batch) -// batch.Put([]byte("foo"), []byte("value")) -// batch.Put([]byte("bar"), []byte("another value")) -// batch.Delete([]byte("baz")) -// err = db.Write(batch, nil) -// ... -// -// Use bloom filter: -// -// o := &opt.Options{ -// Filter: filter.NewBloomFilter(10), -// } -// db, err := leveldb.OpenFile("path/to/db", o) -// ... -// defer db.Close() -// ... -package leveldb diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/errors.go b/vendor/github.com/syndtr/goleveldb/leveldb/errors.go deleted file mode 100644 index de26498..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/errors.go +++ /dev/null @@ -1,20 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "github.com/syndtr/goleveldb/leveldb/errors" -) - -// Common errors. -var ( - ErrNotFound = errors.ErrNotFound - ErrReadOnly = errors.New("leveldb: read-only mode") - ErrSnapshotReleased = errors.New("leveldb: snapshot released") - ErrIterReleased = errors.New("leveldb: iterator released") - ErrClosed = errors.New("leveldb: closed") -) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/errors/errors.go b/vendor/github.com/syndtr/goleveldb/leveldb/errors/errors.go deleted file mode 100644 index 8d6146b..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/errors/errors.go +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package errors provides common error types used throughout leveldb. -package errors - -import ( - "errors" - "fmt" - - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// Common errors. -var ( - ErrNotFound = New("leveldb: not found") - ErrReleased = util.ErrReleased - ErrHasReleaser = util.ErrHasReleaser -) - -// New returns an error that formats as the given text. -func New(text string) error { - return errors.New(text) -} - -// ErrCorrupted is the type that wraps errors that indicate corruption in -// the database. -type ErrCorrupted struct { - Fd storage.FileDesc - Err error -} - -func (e *ErrCorrupted) Error() string { - if !e.Fd.Zero() { - return fmt.Sprintf("%v [file=%v]", e.Err, e.Fd) - } - return e.Err.Error() -} - -// NewErrCorrupted creates new ErrCorrupted error. -func NewErrCorrupted(fd storage.FileDesc, err error) error { - return &ErrCorrupted{fd, err} -} - -// IsCorrupted returns a boolean indicating whether the error is indicating -// a corruption. -func IsCorrupted(err error) bool { - switch err.(type) { - case *ErrCorrupted: - return true - case *storage.ErrCorrupted: - return true - } - return false -} - -// ErrMissingFiles is the type that indicating a corruption due to missing -// files. ErrMissingFiles always wrapped with ErrCorrupted. -type ErrMissingFiles struct { - Fds []storage.FileDesc -} - -func (e *ErrMissingFiles) Error() string { return "file missing" } - -// SetFd sets 'file info' of the given error with the given file. -// Currently only ErrCorrupted is supported, otherwise will do nothing. -func SetFd(err error, fd storage.FileDesc) error { - switch x := err.(type) { - case *ErrCorrupted: - x.Fd = fd - return x - } - return err -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/external_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/external_test.go deleted file mode 100644 index 669d77f..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/external_test.go +++ /dev/null @@ -1,117 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -var _ = testutil.Defer(func() { - Describe("Leveldb external", func() { - o := &opt.Options{ - DisableBlockCache: true, - BlockRestartInterval: 5, - BlockSize: 80, - Compression: opt.NoCompression, - OpenFilesCacheCapacity: -1, - Strict: opt.StrictAll, - WriteBuffer: 1000, - CompactionTableSize: 2000, - } - - Describe("write test", func() { - It("should do write correctly", func(done Done) { - db := newTestingDB(o, nil, nil) - t := testutil.DBTesting{ - DB: db, - Deleted: testutil.KeyValue_Generate(nil, 500, 1, 1, 50, 5, 5).Clone(), - } - testutil.DoDBTesting(&t) - db.TestClose() - done <- true - }, 80.0) - }) - - Describe("read test", func() { - testutil.AllKeyValueTesting(nil, nil, func(kv testutil.KeyValue) testutil.DB { - // Building the DB. - db := newTestingDB(o, nil, nil) - kv.IterateShuffled(nil, func(i int, key, value []byte) { - err := db.TestPut(key, value) - Expect(err).NotTo(HaveOccurred()) - }) - - return db - }, func(db testutil.DB) { - db.(*testingDB).TestClose() - }) - }) - - Describe("transaction test", func() { - It("should do transaction correctly", func(done Done) { - db := newTestingDB(o, nil, nil) - - By("creating first transaction") - var err error - tr := &testingTransaction{} - tr.Transaction, err = db.OpenTransaction() - Expect(err).NotTo(HaveOccurred()) - t0 := &testutil.DBTesting{ - DB: tr, - Deleted: testutil.KeyValue_Generate(nil, 200, 1, 1, 50, 5, 5).Clone(), - } - testutil.DoDBTesting(t0) - testutil.TestGet(tr, t0.Present) - testutil.TestHas(tr, t0.Present) - - By("committing first transaction") - err = tr.Commit() - Expect(err).NotTo(HaveOccurred()) - testutil.TestIter(db, nil, t0.Present) - testutil.TestGet(db, t0.Present) - testutil.TestHas(db, t0.Present) - - By("manipulating DB without transaction") - t0.DB = db - testutil.DoDBTesting(t0) - - By("creating second transaction") - tr.Transaction, err = db.OpenTransaction() - Expect(err).NotTo(HaveOccurred()) - t1 := &testutil.DBTesting{ - DB: tr, - Deleted: t0.Deleted.Clone(), - Present: t0.Present.Clone(), - } - testutil.DoDBTesting(t1) - testutil.TestIter(db, nil, t0.Present) - - By("discarding second transaction") - tr.Discard() - testutil.TestIter(db, nil, t0.Present) - - By("creating third transaction") - tr.Transaction, err = db.OpenTransaction() - Expect(err).NotTo(HaveOccurred()) - t0.DB = tr - testutil.DoDBTesting(t0) - - By("committing third transaction") - err = tr.Commit() - Expect(err).NotTo(HaveOccurred()) - testutil.TestIter(db, nil, t0.Present) - - db.TestClose() - done <- true - }, 240.0) - }) - }) -}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/filter.go b/vendor/github.com/syndtr/goleveldb/leveldb/filter.go deleted file mode 100644 index e961e42..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/filter.go +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "github.com/syndtr/goleveldb/leveldb/filter" -) - -type iFilter struct { - filter.Filter -} - -func (f iFilter) Contains(filter, key []byte) bool { - return f.Filter.Contains(filter, internalKey(key).ukey()) -} - -func (f iFilter) NewGenerator() filter.FilterGenerator { - return iFilterGenerator{f.Filter.NewGenerator()} -} - -type iFilterGenerator struct { - filter.FilterGenerator -} - -func (g iFilterGenerator) Add(key []byte) { - g.FilterGenerator.Add(internalKey(key).ukey()) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/filter/bloom.go b/vendor/github.com/syndtr/goleveldb/leveldb/filter/bloom.go deleted file mode 100644 index bab0e99..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/filter/bloom.go +++ /dev/null @@ -1,116 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package filter - -import ( - "github.com/syndtr/goleveldb/leveldb/util" -) - -func bloomHash(key []byte) uint32 { - return util.Hash(key, 0xbc9f1d34) -} - -type bloomFilter int - -// The bloom filter serializes its parameters and is backward compatible -// with respect to them. Therefor, its parameters are not added to its -// name. -func (bloomFilter) Name() string { - return "leveldb.BuiltinBloomFilter" -} - -func (f bloomFilter) Contains(filter, key []byte) bool { - nBytes := len(filter) - 1 - if nBytes < 1 { - return false - } - nBits := uint32(nBytes * 8) - - // Use the encoded k so that we can read filters generated by - // bloom filters created using different parameters. - k := filter[nBytes] - if k > 30 { - // Reserved for potentially new encodings for short bloom filters. - // Consider it a match. - return true - } - - kh := bloomHash(key) - delta := (kh >> 17) | (kh << 15) // Rotate right 17 bits - for j := uint8(0); j < k; j++ { - bitpos := kh % nBits - if (uint32(filter[bitpos/8]) & (1 << (bitpos % 8))) == 0 { - return false - } - kh += delta - } - return true -} - -func (f bloomFilter) NewGenerator() FilterGenerator { - // Round down to reduce probing cost a little bit. - k := uint8(f * 69 / 100) // 0.69 =~ ln(2) - if k < 1 { - k = 1 - } else if k > 30 { - k = 30 - } - return &bloomFilterGenerator{ - n: int(f), - k: k, - } -} - -type bloomFilterGenerator struct { - n int - k uint8 - - keyHashes []uint32 -} - -func (g *bloomFilterGenerator) Add(key []byte) { - // Use double-hashing to generate a sequence of hash values. - // See analysis in [Kirsch,Mitzenmacher 2006]. - g.keyHashes = append(g.keyHashes, bloomHash(key)) -} - -func (g *bloomFilterGenerator) Generate(b Buffer) { - // Compute bloom filter size (in both bits and bytes) - nBits := uint32(len(g.keyHashes) * g.n) - // For small n, we can see a very high false positive rate. Fix it - // by enforcing a minimum bloom filter length. - if nBits < 64 { - nBits = 64 - } - nBytes := (nBits + 7) / 8 - nBits = nBytes * 8 - - dest := b.Alloc(int(nBytes) + 1) - dest[nBytes] = g.k - for _, kh := range g.keyHashes { - delta := (kh >> 17) | (kh << 15) // Rotate right 17 bits - for j := uint8(0); j < g.k; j++ { - bitpos := kh % nBits - dest[bitpos/8] |= (1 << (bitpos % 8)) - kh += delta - } - } - - g.keyHashes = g.keyHashes[:0] -} - -// NewBloomFilter creates a new initialized bloom filter for given -// bitsPerKey. -// -// Since bitsPerKey is persisted individually for each bloom filter -// serialization, bloom filters are backwards compatible with respect to -// changing bitsPerKey. This means that no big performance penalty will -// be experienced when changing the parameter. See documentation for -// opt.Options.Filter for more information. -func NewBloomFilter(bitsPerKey int) Filter { - return bloomFilter(bitsPerKey) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/filter/bloom_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/filter/bloom_test.go deleted file mode 100644 index 1fb56f0..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/filter/bloom_test.go +++ /dev/null @@ -1,142 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package filter - -import ( - "encoding/binary" - "github.com/syndtr/goleveldb/leveldb/util" - "testing" -) - -type harness struct { - t *testing.T - - bloom Filter - generator FilterGenerator - filter []byte -} - -func newHarness(t *testing.T) *harness { - bloom := NewBloomFilter(10) - return &harness{ - t: t, - bloom: bloom, - generator: bloom.NewGenerator(), - } -} - -func (h *harness) add(key []byte) { - h.generator.Add(key) -} - -func (h *harness) addNum(key uint32) { - var b [4]byte - binary.LittleEndian.PutUint32(b[:], key) - h.add(b[:]) -} - -func (h *harness) build() { - b := &util.Buffer{} - h.generator.Generate(b) - h.filter = b.Bytes() -} - -func (h *harness) reset() { - h.filter = nil -} - -func (h *harness) filterLen() int { - return len(h.filter) -} - -func (h *harness) assert(key []byte, want, silent bool) bool { - got := h.bloom.Contains(h.filter, key) - if !silent && got != want { - h.t.Errorf("assert on '%v' failed got '%v', want '%v'", key, got, want) - } - return got -} - -func (h *harness) assertNum(key uint32, want, silent bool) bool { - var b [4]byte - binary.LittleEndian.PutUint32(b[:], key) - return h.assert(b[:], want, silent) -} - -func TestBloomFilter_Empty(t *testing.T) { - h := newHarness(t) - h.build() - h.assert([]byte("hello"), false, false) - h.assert([]byte("world"), false, false) -} - -func TestBloomFilter_Small(t *testing.T) { - h := newHarness(t) - h.add([]byte("hello")) - h.add([]byte("world")) - h.build() - h.assert([]byte("hello"), true, false) - h.assert([]byte("world"), true, false) - h.assert([]byte("x"), false, false) - h.assert([]byte("foo"), false, false) -} - -func nextN(n int) int { - switch { - case n < 10: - n += 1 - case n < 100: - n += 10 - case n < 1000: - n += 100 - default: - n += 1000 - } - return n -} - -func TestBloomFilter_VaryingLengths(t *testing.T) { - h := newHarness(t) - var mediocre, good int - for n := 1; n < 10000; n = nextN(n) { - h.reset() - for i := 0; i < n; i++ { - h.addNum(uint32(i)) - } - h.build() - - got := h.filterLen() - want := (n * 10 / 8) + 40 - if got > want { - t.Errorf("filter len test failed, '%d' > '%d'", got, want) - } - - for i := 0; i < n; i++ { - h.assertNum(uint32(i), true, false) - } - - var rate float32 - for i := 0; i < 10000; i++ { - if h.assertNum(uint32(i+1000000000), true, true) { - rate++ - } - } - rate /= 10000 - if rate > 0.02 { - t.Errorf("false positive rate is more than 2%%, got %v, at len %d", rate, n) - } - if rate > 0.0125 { - mediocre++ - } else { - good++ - } - } - t.Logf("false positive rate: %d good, %d mediocre", good, mediocre) - if mediocre > good/5 { - t.Error("mediocre false positive rate is more than expected") - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/filter/filter.go b/vendor/github.com/syndtr/goleveldb/leveldb/filter/filter.go deleted file mode 100644 index 7a925c5..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/filter/filter.go +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package filter provides interface and implementation of probabilistic -// data structure. -// -// The filter is resposible for creating small filter from a set of keys. -// These filter will then used to test whether a key is a member of the set. -// In many cases, a filter can cut down the number of disk seeks from a -// handful to a single disk seek per DB.Get call. -package filter - -// Buffer is the interface that wraps basic Alloc, Write and WriteByte methods. -type Buffer interface { - // Alloc allocs n bytes of slice from the buffer. This also advancing - // write offset. - Alloc(n int) []byte - - // Write appends the contents of p to the buffer. - Write(p []byte) (n int, err error) - - // WriteByte appends the byte c to the buffer. - WriteByte(c byte) error -} - -// Filter is the filter. -type Filter interface { - // Name returns the name of this policy. - // - // Note that if the filter encoding changes in an incompatible way, - // the name returned by this method must be changed. Otherwise, old - // incompatible filters may be passed to methods of this type. - Name() string - - // NewGenerator creates a new filter generator. - NewGenerator() FilterGenerator - - // Contains returns true if the filter contains the given key. - // - // The filter are filters generated by the filter generator. - Contains(filter, key []byte) bool -} - -// FilterGenerator is the filter generator. -type FilterGenerator interface { - // Add adds a key to the filter generator. - // - // The key may become invalid after call to this method end, therefor - // key must be copied if implementation require keeping key for later - // use. The key should not modified directly, doing so may cause - // undefined results. - Add(key []byte) - - // Generate generates filters based on keys passed so far. After call - // to Generate the filter generator maybe resetted, depends on implementation. - Generate(b Buffer) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go deleted file mode 100644 index a23ab05..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go +++ /dev/null @@ -1,184 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package iterator - -import ( - "github.com/syndtr/goleveldb/leveldb/util" -) - -// BasicArray is the interface that wraps basic Len and Search method. -type BasicArray interface { - // Len returns length of the array. - Len() int - - // Search finds smallest index that point to a key that is greater - // than or equal to the given key. - Search(key []byte) int -} - -// Array is the interface that wraps BasicArray and basic Index method. -type Array interface { - BasicArray - - // Index returns key/value pair with index of i. - Index(i int) (key, value []byte) -} - -// Array is the interface that wraps BasicArray and basic Get method. -type ArrayIndexer interface { - BasicArray - - // Get returns a new data iterator with index of i. - Get(i int) Iterator -} - -type basicArrayIterator struct { - util.BasicReleaser - array BasicArray - pos int - err error -} - -func (i *basicArrayIterator) Valid() bool { - return i.pos >= 0 && i.pos < i.array.Len() && !i.Released() -} - -func (i *basicArrayIterator) First() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - if i.array.Len() == 0 { - i.pos = -1 - return false - } - i.pos = 0 - return true -} - -func (i *basicArrayIterator) Last() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - n := i.array.Len() - if n == 0 { - i.pos = 0 - return false - } - i.pos = n - 1 - return true -} - -func (i *basicArrayIterator) Seek(key []byte) bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - n := i.array.Len() - if n == 0 { - i.pos = 0 - return false - } - i.pos = i.array.Search(key) - if i.pos >= n { - return false - } - return true -} - -func (i *basicArrayIterator) Next() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - i.pos++ - if n := i.array.Len(); i.pos >= n { - i.pos = n - return false - } - return true -} - -func (i *basicArrayIterator) Prev() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - i.pos-- - if i.pos < 0 { - i.pos = -1 - return false - } - return true -} - -func (i *basicArrayIterator) Error() error { return i.err } - -type arrayIterator struct { - basicArrayIterator - array Array - pos int - key, value []byte -} - -func (i *arrayIterator) updateKV() { - if i.pos == i.basicArrayIterator.pos { - return - } - i.pos = i.basicArrayIterator.pos - if i.Valid() { - i.key, i.value = i.array.Index(i.pos) - } else { - i.key = nil - i.value = nil - } -} - -func (i *arrayIterator) Key() []byte { - i.updateKV() - return i.key -} - -func (i *arrayIterator) Value() []byte { - i.updateKV() - return i.value -} - -type arrayIteratorIndexer struct { - basicArrayIterator - array ArrayIndexer -} - -func (i *arrayIteratorIndexer) Get() Iterator { - if i.Valid() { - return i.array.Get(i.basicArrayIterator.pos) - } - return nil -} - -// NewArrayIterator returns an iterator from the given array. -func NewArrayIterator(array Array) Iterator { - return &arrayIterator{ - basicArrayIterator: basicArrayIterator{array: array, pos: -1}, - array: array, - pos: -1, - } -} - -// NewArrayIndexer returns an index iterator from the given array. -func NewArrayIndexer(array ArrayIndexer) IteratorIndexer { - return &arrayIteratorIndexer{ - basicArrayIterator: basicArrayIterator{array: array, pos: -1}, - array: array, - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter_test.go deleted file mode 100644 index f16d014..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/array_iter_test.go +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package iterator_test - -import ( - . "github.com/onsi/ginkgo" - - . "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -var _ = testutil.Defer(func() { - Describe("Array iterator", func() { - It("Should iterates and seeks correctly", func() { - // Build key/value. - kv := testutil.KeyValue_Generate(nil, 70, 1, 1, 5, 3, 3) - - // Test the iterator. - t := testutil.IteratorTesting{ - KeyValue: kv.Clone(), - Iter: NewArrayIterator(kv), - } - testutil.DoIteratorTesting(&t) - }) - }) -}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go deleted file mode 100644 index 939adbb..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go +++ /dev/null @@ -1,242 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package iterator - -import ( - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// IteratorIndexer is the interface that wraps CommonIterator and basic Get -// method. IteratorIndexer provides index for indexed iterator. -type IteratorIndexer interface { - CommonIterator - - // Get returns a new data iterator for the current position, or nil if - // done. - Get() Iterator -} - -type indexedIterator struct { - util.BasicReleaser - index IteratorIndexer - strict bool - - data Iterator - err error - errf func(err error) - closed bool -} - -func (i *indexedIterator) setData() { - if i.data != nil { - i.data.Release() - } - i.data = i.index.Get() -} - -func (i *indexedIterator) clearData() { - if i.data != nil { - i.data.Release() - } - i.data = nil -} - -func (i *indexedIterator) indexErr() { - if err := i.index.Error(); err != nil { - if i.errf != nil { - i.errf(err) - } - i.err = err - } -} - -func (i *indexedIterator) dataErr() bool { - if err := i.data.Error(); err != nil { - if i.errf != nil { - i.errf(err) - } - if i.strict || !errors.IsCorrupted(err) { - i.err = err - return true - } - } - return false -} - -func (i *indexedIterator) Valid() bool { - return i.data != nil && i.data.Valid() -} - -func (i *indexedIterator) First() bool { - if i.err != nil { - return false - } else if i.Released() { - i.err = ErrIterReleased - return false - } - - if !i.index.First() { - i.indexErr() - i.clearData() - return false - } - i.setData() - return i.Next() -} - -func (i *indexedIterator) Last() bool { - if i.err != nil { - return false - } else if i.Released() { - i.err = ErrIterReleased - return false - } - - if !i.index.Last() { - i.indexErr() - i.clearData() - return false - } - i.setData() - if !i.data.Last() { - if i.dataErr() { - return false - } - i.clearData() - return i.Prev() - } - return true -} - -func (i *indexedIterator) Seek(key []byte) bool { - if i.err != nil { - return false - } else if i.Released() { - i.err = ErrIterReleased - return false - } - - if !i.index.Seek(key) { - i.indexErr() - i.clearData() - return false - } - i.setData() - if !i.data.Seek(key) { - if i.dataErr() { - return false - } - i.clearData() - return i.Next() - } - return true -} - -func (i *indexedIterator) Next() bool { - if i.err != nil { - return false - } else if i.Released() { - i.err = ErrIterReleased - return false - } - - switch { - case i.data != nil && !i.data.Next(): - if i.dataErr() { - return false - } - i.clearData() - fallthrough - case i.data == nil: - if !i.index.Next() { - i.indexErr() - return false - } - i.setData() - return i.Next() - } - return true -} - -func (i *indexedIterator) Prev() bool { - if i.err != nil { - return false - } else if i.Released() { - i.err = ErrIterReleased - return false - } - - switch { - case i.data != nil && !i.data.Prev(): - if i.dataErr() { - return false - } - i.clearData() - fallthrough - case i.data == nil: - if !i.index.Prev() { - i.indexErr() - return false - } - i.setData() - if !i.data.Last() { - if i.dataErr() { - return false - } - i.clearData() - return i.Prev() - } - } - return true -} - -func (i *indexedIterator) Key() []byte { - if i.data == nil { - return nil - } - return i.data.Key() -} - -func (i *indexedIterator) Value() []byte { - if i.data == nil { - return nil - } - return i.data.Value() -} - -func (i *indexedIterator) Release() { - i.clearData() - i.index.Release() - i.BasicReleaser.Release() -} - -func (i *indexedIterator) Error() error { - if i.err != nil { - return i.err - } - if err := i.index.Error(); err != nil { - return err - } - return nil -} - -func (i *indexedIterator) SetErrorCallback(f func(err error)) { - i.errf = f -} - -// NewIndexedIterator returns an 'indexed iterator'. An index is iterator -// that returns another iterator, a 'data iterator'. A 'data iterator' is the -// iterator that contains actual key/value pairs. -// -// If strict is true the any 'corruption errors' (i.e errors.IsCorrupted(err) == true) -// won't be ignored and will halt 'indexed iterator', otherwise the iterator will -// continue to the next 'data iterator'. Corruption on 'index iterator' will not be -// ignored and will halt the iterator. -func NewIndexedIterator(index IteratorIndexer, strict bool) Iterator { - return &indexedIterator{index: index, strict: strict} -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter_test.go deleted file mode 100644 index fde8016..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter_test.go +++ /dev/null @@ -1,83 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package iterator_test - -import ( - "sort" - - . "github.com/onsi/ginkgo" - - "github.com/syndtr/goleveldb/leveldb/comparer" - . "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -type keyValue struct { - key []byte - testutil.KeyValue -} - -type keyValueIndex []keyValue - -func (x keyValueIndex) Search(key []byte) int { - return sort.Search(x.Len(), func(i int) bool { - return comparer.DefaultComparer.Compare(x[i].key, key) >= 0 - }) -} - -func (x keyValueIndex) Len() int { return len(x) } -func (x keyValueIndex) Index(i int) (key, value []byte) { return x[i].key, nil } -func (x keyValueIndex) Get(i int) Iterator { return NewArrayIterator(x[i]) } - -var _ = testutil.Defer(func() { - Describe("Indexed iterator", func() { - Test := func(n ...int) func() { - if len(n) == 0 { - rnd := testutil.NewRand() - n = make([]int, rnd.Intn(17)+3) - for i := range n { - n[i] = rnd.Intn(19) + 1 - } - } - - return func() { - It("Should iterates and seeks correctly", func(done Done) { - // Build key/value. - index := make(keyValueIndex, len(n)) - sum := 0 - for _, x := range n { - sum += x - } - kv := testutil.KeyValue_Generate(nil, sum, 1, 1, 10, 4, 4) - for i, j := 0, 0; i < len(n); i++ { - for x := n[i]; x > 0; x-- { - key, value := kv.Index(j) - index[i].key = key - index[i].Put(key, value) - j++ - } - } - - // Test the iterator. - t := testutil.IteratorTesting{ - KeyValue: kv.Clone(), - Iter: NewIndexedIterator(NewArrayIndexer(index), true), - } - testutil.DoIteratorTesting(&t) - done <- true - }, 15.0) - } - } - - Describe("with 100 keys", Test(100)) - Describe("with 50-50 keys", Test(50, 50)) - Describe("with 50-1 keys", Test(50, 1)) - Describe("with 50-1-50 keys", Test(50, 1, 50)) - Describe("with 1-50 keys", Test(1, 50)) - Describe("with random N-keys", Test()) - }) -}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/iter.go deleted file mode 100644 index b16e3a7..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/iter.go +++ /dev/null @@ -1,132 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package iterator provides interface and implementation to traverse over -// contents of a database. -package iterator - -import ( - "errors" - - "github.com/syndtr/goleveldb/leveldb/util" -) - -var ( - ErrIterReleased = errors.New("leveldb/iterator: iterator released") -) - -// IteratorSeeker is the interface that wraps the 'seeks method'. -type IteratorSeeker interface { - // First moves the iterator to the first key/value pair. If the iterator - // only contains one key/value pair then First and Last would moves - // to the same key/value pair. - // It returns whether such pair exist. - First() bool - - // Last moves the iterator to the last key/value pair. If the iterator - // only contains one key/value pair then First and Last would moves - // to the same key/value pair. - // It returns whether such pair exist. - Last() bool - - // Seek moves the iterator to the first key/value pair whose key is greater - // than or equal to the given key. - // It returns whether such pair exist. - // - // It is safe to modify the contents of the argument after Seek returns. - Seek(key []byte) bool - - // Next moves the iterator to the next key/value pair. - // It returns whether the iterator is exhausted. - Next() bool - - // Prev moves the iterator to the previous key/value pair. - // It returns whether the iterator is exhausted. - Prev() bool -} - -// CommonIterator is the interface that wraps common iterator methods. -type CommonIterator interface { - IteratorSeeker - - // util.Releaser is the interface that wraps basic Release method. - // When called Release will releases any resources associated with the - // iterator. - util.Releaser - - // util.ReleaseSetter is the interface that wraps the basic SetReleaser - // method. - util.ReleaseSetter - - // TODO: Remove this when ready. - Valid() bool - - // Error returns any accumulated error. Exhausting all the key/value pairs - // is not considered to be an error. - Error() error -} - -// Iterator iterates over a DB's key/value pairs in key order. -// -// When encounter an error any 'seeks method' will return false and will -// yield no key/value pairs. The error can be queried by calling the Error -// method. Calling Release is still necessary. -// -// An iterator must be released after use, but it is not necessary to read -// an iterator until exhaustion. -// Also, an iterator is not necessarily safe for concurrent use, but it is -// safe to use multiple iterators concurrently, with each in a dedicated -// goroutine. -type Iterator interface { - CommonIterator - - // Key returns the key of the current key/value pair, or nil if done. - // The caller should not modify the contents of the returned slice, and - // its contents may change on the next call to any 'seeks method'. - Key() []byte - - // Value returns the value of the current key/value pair, or nil if done. - // The caller should not modify the contents of the returned slice, and - // its contents may change on the next call to any 'seeks method'. - Value() []byte -} - -// ErrorCallbackSetter is the interface that wraps basic SetErrorCallback -// method. -// -// ErrorCallbackSetter implemented by indexed and merged iterator. -type ErrorCallbackSetter interface { - // SetErrorCallback allows set an error callback of the corresponding - // iterator. Use nil to clear the callback. - SetErrorCallback(f func(err error)) -} - -type emptyIterator struct { - util.BasicReleaser - err error -} - -func (i *emptyIterator) rErr() { - if i.err == nil && i.Released() { - i.err = ErrIterReleased - } -} - -func (*emptyIterator) Valid() bool { return false } -func (i *emptyIterator) First() bool { i.rErr(); return false } -func (i *emptyIterator) Last() bool { i.rErr(); return false } -func (i *emptyIterator) Seek(key []byte) bool { i.rErr(); return false } -func (i *emptyIterator) Next() bool { i.rErr(); return false } -func (i *emptyIterator) Prev() bool { i.rErr(); return false } -func (*emptyIterator) Key() []byte { return nil } -func (*emptyIterator) Value() []byte { return nil } -func (i *emptyIterator) Error() error { return i.err } - -// NewEmptyIterator creates an empty iterator. The err parameter can be -// nil, but if not nil the given err will be returned by Error method. -func NewEmptyIterator(err error) Iterator { - return &emptyIterator{err: err} -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/iter_suite_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/iter_suite_test.go deleted file mode 100644 index 5ef8d5b..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/iter_suite_test.go +++ /dev/null @@ -1,11 +0,0 @@ -package iterator_test - -import ( - "testing" - - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -func TestIterator(t *testing.T) { - testutil.RunSuite(t, "Iterator Suite") -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go deleted file mode 100644 index 1a7e29d..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go +++ /dev/null @@ -1,304 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package iterator - -import ( - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/util" -) - -type dir int - -const ( - dirReleased dir = iota - 1 - dirSOI - dirEOI - dirBackward - dirForward -) - -type mergedIterator struct { - cmp comparer.Comparer - iters []Iterator - strict bool - - keys [][]byte - index int - dir dir - err error - errf func(err error) - releaser util.Releaser -} - -func assertKey(key []byte) []byte { - if key == nil { - panic("leveldb/iterator: nil key") - } - return key -} - -func (i *mergedIterator) iterErr(iter Iterator) bool { - if err := iter.Error(); err != nil { - if i.errf != nil { - i.errf(err) - } - if i.strict || !errors.IsCorrupted(err) { - i.err = err - return true - } - } - return false -} - -func (i *mergedIterator) Valid() bool { - return i.err == nil && i.dir > dirEOI -} - -func (i *mergedIterator) First() bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - for x, iter := range i.iters { - switch { - case iter.First(): - i.keys[x] = assertKey(iter.Key()) - case i.iterErr(iter): - return false - default: - i.keys[x] = nil - } - } - i.dir = dirSOI - return i.next() -} - -func (i *mergedIterator) Last() bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - for x, iter := range i.iters { - switch { - case iter.Last(): - i.keys[x] = assertKey(iter.Key()) - case i.iterErr(iter): - return false - default: - i.keys[x] = nil - } - } - i.dir = dirEOI - return i.prev() -} - -func (i *mergedIterator) Seek(key []byte) bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - for x, iter := range i.iters { - switch { - case iter.Seek(key): - i.keys[x] = assertKey(iter.Key()) - case i.iterErr(iter): - return false - default: - i.keys[x] = nil - } - } - i.dir = dirSOI - return i.next() -} - -func (i *mergedIterator) next() bool { - var key []byte - if i.dir == dirForward { - key = i.keys[i.index] - } - for x, tkey := range i.keys { - if tkey != nil && (key == nil || i.cmp.Compare(tkey, key) < 0) { - key = tkey - i.index = x - } - } - if key == nil { - i.dir = dirEOI - return false - } - i.dir = dirForward - return true -} - -func (i *mergedIterator) Next() bool { - if i.dir == dirEOI || i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - switch i.dir { - case dirSOI: - return i.First() - case dirBackward: - key := append([]byte{}, i.keys[i.index]...) - if !i.Seek(key) { - return false - } - return i.Next() - } - - x := i.index - iter := i.iters[x] - switch { - case iter.Next(): - i.keys[x] = assertKey(iter.Key()) - case i.iterErr(iter): - return false - default: - i.keys[x] = nil - } - return i.next() -} - -func (i *mergedIterator) prev() bool { - var key []byte - if i.dir == dirBackward { - key = i.keys[i.index] - } - for x, tkey := range i.keys { - if tkey != nil && (key == nil || i.cmp.Compare(tkey, key) > 0) { - key = tkey - i.index = x - } - } - if key == nil { - i.dir = dirSOI - return false - } - i.dir = dirBackward - return true -} - -func (i *mergedIterator) Prev() bool { - if i.dir == dirSOI || i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - switch i.dir { - case dirEOI: - return i.Last() - case dirForward: - key := append([]byte{}, i.keys[i.index]...) - for x, iter := range i.iters { - if x == i.index { - continue - } - seek := iter.Seek(key) - switch { - case seek && iter.Prev(), !seek && iter.Last(): - i.keys[x] = assertKey(iter.Key()) - case i.iterErr(iter): - return false - default: - i.keys[x] = nil - } - } - } - - x := i.index - iter := i.iters[x] - switch { - case iter.Prev(): - i.keys[x] = assertKey(iter.Key()) - case i.iterErr(iter): - return false - default: - i.keys[x] = nil - } - return i.prev() -} - -func (i *mergedIterator) Key() []byte { - if i.err != nil || i.dir <= dirEOI { - return nil - } - return i.keys[i.index] -} - -func (i *mergedIterator) Value() []byte { - if i.err != nil || i.dir <= dirEOI { - return nil - } - return i.iters[i.index].Value() -} - -func (i *mergedIterator) Release() { - if i.dir != dirReleased { - i.dir = dirReleased - for _, iter := range i.iters { - iter.Release() - } - i.iters = nil - i.keys = nil - if i.releaser != nil { - i.releaser.Release() - i.releaser = nil - } - } -} - -func (i *mergedIterator) SetReleaser(releaser util.Releaser) { - if i.dir == dirReleased { - panic(util.ErrReleased) - } - if i.releaser != nil && releaser != nil { - panic(util.ErrHasReleaser) - } - i.releaser = releaser -} - -func (i *mergedIterator) Error() error { - return i.err -} - -func (i *mergedIterator) SetErrorCallback(f func(err error)) { - i.errf = f -} - -// NewMergedIterator returns an iterator that merges its input. Walking the -// resultant iterator will return all key/value pairs of all input iterators -// in strictly increasing key order, as defined by cmp. -// The input's key ranges may overlap, but there are assumed to be no duplicate -// keys: if iters[i] contains a key k then iters[j] will not contain that key k. -// None of the iters may be nil. -// -// If strict is true the any 'corruption errors' (i.e errors.IsCorrupted(err) == true) -// won't be ignored and will halt 'merged iterator', otherwise the iterator will -// continue to the next 'input iterator'. -func NewMergedIterator(iters []Iterator, cmp comparer.Comparer, strict bool) Iterator { - return &mergedIterator{ - iters: iters, - cmp: cmp, - strict: strict, - keys: make([][]byte, len(iters)), - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter_test.go deleted file mode 100644 index ee40881..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter_test.go +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package iterator_test - -import ( - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/comparer" - . "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -var _ = testutil.Defer(func() { - Describe("Merged iterator", func() { - Test := func(filled int, empty int) func() { - return func() { - It("Should iterates and seeks correctly", func(done Done) { - rnd := testutil.NewRand() - - // Build key/value. - filledKV := make([]testutil.KeyValue, filled) - kv := testutil.KeyValue_Generate(nil, 100, 1, 1, 10, 4, 4) - kv.Iterate(func(i int, key, value []byte) { - filledKV[rnd.Intn(filled)].Put(key, value) - }) - - // Create itearators. - iters := make([]Iterator, filled+empty) - for i := range iters { - if empty == 0 || (rnd.Int()%2 == 0 && filled > 0) { - filled-- - Expect(filledKV[filled].Len()).ShouldNot(BeZero()) - iters[i] = NewArrayIterator(filledKV[filled]) - } else { - empty-- - iters[i] = NewEmptyIterator(nil) - } - } - - // Test the iterator. - t := testutil.IteratorTesting{ - KeyValue: kv.Clone(), - Iter: NewMergedIterator(iters, comparer.DefaultComparer, true), - } - testutil.DoIteratorTesting(&t) - done <- true - }, 15.0) - } - } - - Describe("with three, all filled iterators", Test(3, 0)) - Describe("with one filled, one empty iterators", Test(1, 1)) - Describe("with one filled, two empty iterators", Test(1, 2)) - }) -}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal.go b/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal.go deleted file mode 100644 index d094c3d..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal.go +++ /dev/null @@ -1,524 +0,0 @@ -// Copyright 2011 The LevelDB-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Taken from: https://code.google.com/p/leveldb-go/source/browse/leveldb/record/record.go?r=1d5ccbe03246da926391ee12d1c6caae054ff4b0 -// License, authors and contributors informations can be found at bellow URLs respectively: -// https://code.google.com/p/leveldb-go/source/browse/LICENSE -// https://code.google.com/p/leveldb-go/source/browse/AUTHORS -// https://code.google.com/p/leveldb-go/source/browse/CONTRIBUTORS - -// Package journal reads and writes sequences of journals. Each journal is a stream -// of bytes that completes before the next journal starts. -// -// When reading, call Next to obtain an io.Reader for the next journal. Next will -// return io.EOF when there are no more journals. It is valid to call Next -// without reading the current journal to exhaustion. -// -// When writing, call Next to obtain an io.Writer for the next journal. Calling -// Next finishes the current journal. Call Close to finish the final journal. -// -// Optionally, call Flush to finish the current journal and flush the underlying -// writer without starting a new journal. To start a new journal after flushing, -// call Next. -// -// Neither Readers or Writers are safe to use concurrently. -// -// Example code: -// func read(r io.Reader) ([]string, error) { -// var ss []string -// journals := journal.NewReader(r, nil, true, true) -// for { -// j, err := journals.Next() -// if err == io.EOF { -// break -// } -// if err != nil { -// return nil, err -// } -// s, err := ioutil.ReadAll(j) -// if err != nil { -// return nil, err -// } -// ss = append(ss, string(s)) -// } -// return ss, nil -// } -// -// func write(w io.Writer, ss []string) error { -// journals := journal.NewWriter(w) -// for _, s := range ss { -// j, err := journals.Next() -// if err != nil { -// return err -// } -// if _, err := j.Write([]byte(s)), err != nil { -// return err -// } -// } -// return journals.Close() -// } -// -// The wire format is that the stream is divided into 32KiB blocks, and each -// block contains a number of tightly packed chunks. Chunks cannot cross block -// boundaries. The last block may be shorter than 32 KiB. Any unused bytes in a -// block must be zero. -// -// A journal maps to one or more chunks. Each chunk has a 7 byte header (a 4 -// byte checksum, a 2 byte little-endian uint16 length, and a 1 byte chunk type) -// followed by a payload. The checksum is over the chunk type and the payload. -// -// There are four chunk types: whether the chunk is the full journal, or the -// first, middle or last chunk of a multi-chunk journal. A multi-chunk journal -// has one first chunk, zero or more middle chunks, and one last chunk. -// -// The wire format allows for limited recovery in the face of data corruption: -// on a format error (such as a checksum mismatch), the reader moves to the -// next block and looks for the next full or first chunk. -package journal - -import ( - "encoding/binary" - "fmt" - "io" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// These constants are part of the wire format and should not be changed. -const ( - fullChunkType = 1 - firstChunkType = 2 - middleChunkType = 3 - lastChunkType = 4 -) - -const ( - blockSize = 32 * 1024 - headerSize = 7 -) - -type flusher interface { - Flush() error -} - -// ErrCorrupted is the error type that generated by corrupted block or chunk. -type ErrCorrupted struct { - Size int - Reason string -} - -func (e *ErrCorrupted) Error() string { - return fmt.Sprintf("leveldb/journal: block/chunk corrupted: %s (%d bytes)", e.Reason, e.Size) -} - -// Dropper is the interface that wrap simple Drop method. The Drop -// method will be called when the journal reader dropping a block or chunk. -type Dropper interface { - Drop(err error) -} - -// Reader reads journals from an underlying io.Reader. -type Reader struct { - // r is the underlying reader. - r io.Reader - // the dropper. - dropper Dropper - // strict flag. - strict bool - // checksum flag. - checksum bool - // seq is the sequence number of the current journal. - seq int - // buf[i:j] is the unread portion of the current chunk's payload. - // The low bound, i, excludes the chunk header. - i, j int - // n is the number of bytes of buf that are valid. Once reading has started, - // only the final block can have n < blockSize. - n int - // last is whether the current chunk is the last chunk of the journal. - last bool - // err is any accumulated error. - err error - // buf is the buffer. - buf [blockSize]byte -} - -// NewReader returns a new reader. The dropper may be nil, and if -// strict is true then corrupted or invalid chunk will halt the journal -// reader entirely. -func NewReader(r io.Reader, dropper Dropper, strict, checksum bool) *Reader { - return &Reader{ - r: r, - dropper: dropper, - strict: strict, - checksum: checksum, - last: true, - } -} - -var errSkip = errors.New("leveldb/journal: skipped") - -func (r *Reader) corrupt(n int, reason string, skip bool) error { - if r.dropper != nil { - r.dropper.Drop(&ErrCorrupted{n, reason}) - } - if r.strict && !skip { - r.err = errors.NewErrCorrupted(storage.FileDesc{}, &ErrCorrupted{n, reason}) - return r.err - } - return errSkip -} - -// nextChunk sets r.buf[r.i:r.j] to hold the next chunk's payload, reading the -// next block into the buffer if necessary. -func (r *Reader) nextChunk(first bool) error { - for { - if r.j+headerSize <= r.n { - checksum := binary.LittleEndian.Uint32(r.buf[r.j+0 : r.j+4]) - length := binary.LittleEndian.Uint16(r.buf[r.j+4 : r.j+6]) - chunkType := r.buf[r.j+6] - unprocBlock := r.n - r.j - if checksum == 0 && length == 0 && chunkType == 0 { - // Drop entire block. - r.i = r.n - r.j = r.n - return r.corrupt(unprocBlock, "zero header", false) - } - if chunkType < fullChunkType || chunkType > lastChunkType { - // Drop entire block. - r.i = r.n - r.j = r.n - return r.corrupt(unprocBlock, fmt.Sprintf("invalid chunk type %#x", chunkType), false) - } - r.i = r.j + headerSize - r.j = r.j + headerSize + int(length) - if r.j > r.n { - // Drop entire block. - r.i = r.n - r.j = r.n - return r.corrupt(unprocBlock, "chunk length overflows block", false) - } else if r.checksum && checksum != util.NewCRC(r.buf[r.i-1:r.j]).Value() { - // Drop entire block. - r.i = r.n - r.j = r.n - return r.corrupt(unprocBlock, "checksum mismatch", false) - } - if first && chunkType != fullChunkType && chunkType != firstChunkType { - chunkLength := (r.j - r.i) + headerSize - r.i = r.j - // Report the error, but skip it. - return r.corrupt(chunkLength, "orphan chunk", true) - } - r.last = chunkType == fullChunkType || chunkType == lastChunkType - return nil - } - - // The last block. - if r.n < blockSize && r.n > 0 { - if !first { - return r.corrupt(0, "missing chunk part", false) - } - r.err = io.EOF - return r.err - } - - // Read block. - n, err := io.ReadFull(r.r, r.buf[:]) - if err != nil && err != io.EOF && err != io.ErrUnexpectedEOF { - return err - } - if n == 0 { - if !first { - return r.corrupt(0, "missing chunk part", false) - } - r.err = io.EOF - return r.err - } - r.i, r.j, r.n = 0, 0, n - } -} - -// Next returns a reader for the next journal. It returns io.EOF if there are no -// more journals. The reader returned becomes stale after the next Next call, -// and should no longer be used. If strict is false, the reader will returns -// io.ErrUnexpectedEOF error when found corrupted journal. -func (r *Reader) Next() (io.Reader, error) { - r.seq++ - if r.err != nil { - return nil, r.err - } - r.i = r.j - for { - if err := r.nextChunk(true); err == nil { - break - } else if err != errSkip { - return nil, err - } - } - return &singleReader{r, r.seq, nil}, nil -} - -// Reset resets the journal reader, allows reuse of the journal reader. Reset returns -// last accumulated error. -func (r *Reader) Reset(reader io.Reader, dropper Dropper, strict, checksum bool) error { - r.seq++ - err := r.err - r.r = reader - r.dropper = dropper - r.strict = strict - r.checksum = checksum - r.i = 0 - r.j = 0 - r.n = 0 - r.last = true - r.err = nil - return err -} - -type singleReader struct { - r *Reader - seq int - err error -} - -func (x *singleReader) Read(p []byte) (int, error) { - r := x.r - if r.seq != x.seq { - return 0, errors.New("leveldb/journal: stale reader") - } - if x.err != nil { - return 0, x.err - } - if r.err != nil { - return 0, r.err - } - for r.i == r.j { - if r.last { - return 0, io.EOF - } - x.err = r.nextChunk(false) - if x.err != nil { - if x.err == errSkip { - x.err = io.ErrUnexpectedEOF - } - return 0, x.err - } - } - n := copy(p, r.buf[r.i:r.j]) - r.i += n - return n, nil -} - -func (x *singleReader) ReadByte() (byte, error) { - r := x.r - if r.seq != x.seq { - return 0, errors.New("leveldb/journal: stale reader") - } - if x.err != nil { - return 0, x.err - } - if r.err != nil { - return 0, r.err - } - for r.i == r.j { - if r.last { - return 0, io.EOF - } - x.err = r.nextChunk(false) - if x.err != nil { - if x.err == errSkip { - x.err = io.ErrUnexpectedEOF - } - return 0, x.err - } - } - c := r.buf[r.i] - r.i++ - return c, nil -} - -// Writer writes journals to an underlying io.Writer. -type Writer struct { - // w is the underlying writer. - w io.Writer - // seq is the sequence number of the current journal. - seq int - // f is w as a flusher. - f flusher - // buf[i:j] is the bytes that will become the current chunk. - // The low bound, i, includes the chunk header. - i, j int - // buf[:written] has already been written to w. - // written is zero unless Flush has been called. - written int - // first is whether the current chunk is the first chunk of the journal. - first bool - // pending is whether a chunk is buffered but not yet written. - pending bool - // err is any accumulated error. - err error - // buf is the buffer. - buf [blockSize]byte -} - -// NewWriter returns a new Writer. -func NewWriter(w io.Writer) *Writer { - f, _ := w.(flusher) - return &Writer{ - w: w, - f: f, - } -} - -// fillHeader fills in the header for the pending chunk. -func (w *Writer) fillHeader(last bool) { - if w.i+headerSize > w.j || w.j > blockSize { - panic("leveldb/journal: bad writer state") - } - if last { - if w.first { - w.buf[w.i+6] = fullChunkType - } else { - w.buf[w.i+6] = lastChunkType - } - } else { - if w.first { - w.buf[w.i+6] = firstChunkType - } else { - w.buf[w.i+6] = middleChunkType - } - } - binary.LittleEndian.PutUint32(w.buf[w.i+0:w.i+4], util.NewCRC(w.buf[w.i+6:w.j]).Value()) - binary.LittleEndian.PutUint16(w.buf[w.i+4:w.i+6], uint16(w.j-w.i-headerSize)) -} - -// writeBlock writes the buffered block to the underlying writer, and reserves -// space for the next chunk's header. -func (w *Writer) writeBlock() { - _, w.err = w.w.Write(w.buf[w.written:]) - w.i = 0 - w.j = headerSize - w.written = 0 -} - -// writePending finishes the current journal and writes the buffer to the -// underlying writer. -func (w *Writer) writePending() { - if w.err != nil { - return - } - if w.pending { - w.fillHeader(true) - w.pending = false - } - _, w.err = w.w.Write(w.buf[w.written:w.j]) - w.written = w.j -} - -// Close finishes the current journal and closes the writer. -func (w *Writer) Close() error { - w.seq++ - w.writePending() - if w.err != nil { - return w.err - } - w.err = errors.New("leveldb/journal: closed Writer") - return nil -} - -// Flush finishes the current journal, writes to the underlying writer, and -// flushes it if that writer implements interface{ Flush() error }. -func (w *Writer) Flush() error { - w.seq++ - w.writePending() - if w.err != nil { - return w.err - } - if w.f != nil { - w.err = w.f.Flush() - return w.err - } - return nil -} - -// Reset resets the journal writer, allows reuse of the journal writer. Reset -// will also closes the journal writer if not already. -func (w *Writer) Reset(writer io.Writer) (err error) { - w.seq++ - if w.err == nil { - w.writePending() - err = w.err - } - w.w = writer - w.f, _ = writer.(flusher) - w.i = 0 - w.j = 0 - w.written = 0 - w.first = false - w.pending = false - w.err = nil - return -} - -// Next returns a writer for the next journal. The writer returned becomes stale -// after the next Close, Flush or Next call, and should no longer be used. -func (w *Writer) Next() (io.Writer, error) { - w.seq++ - if w.err != nil { - return nil, w.err - } - if w.pending { - w.fillHeader(true) - } - w.i = w.j - w.j = w.j + headerSize - // Check if there is room in the block for the header. - if w.j > blockSize { - // Fill in the rest of the block with zeroes. - for k := w.i; k < blockSize; k++ { - w.buf[k] = 0 - } - w.writeBlock() - if w.err != nil { - return nil, w.err - } - } - w.first = true - w.pending = true - return singleWriter{w, w.seq}, nil -} - -type singleWriter struct { - w *Writer - seq int -} - -func (x singleWriter) Write(p []byte) (int, error) { - w := x.w - if w.seq != x.seq { - return 0, errors.New("leveldb/journal: stale writer") - } - if w.err != nil { - return 0, w.err - } - n0 := len(p) - for len(p) > 0 { - // Write a block, if it is full. - if w.j == blockSize { - w.fillHeader(false) - w.writeBlock() - if w.err != nil { - return 0, w.err - } - w.first = false - } - // Copy bytes into the buffer. - n := copy(w.buf[w.j:], p) - w.j += n - p = p[n:] - } - return n0, nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal_test.go deleted file mode 100644 index 0fcf225..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/journal/journal_test.go +++ /dev/null @@ -1,818 +0,0 @@ -// Copyright 2011 The LevelDB-Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Taken from: https://code.google.com/p/leveldb-go/source/browse/leveldb/record/record_test.go?r=df1fa28f7f3be6c3935548169002309c12967135 -// License, authors and contributors informations can be found at bellow URLs respectively: -// https://code.google.com/p/leveldb-go/source/browse/LICENSE -// https://code.google.com/p/leveldb-go/source/browse/AUTHORS -// https://code.google.com/p/leveldb-go/source/browse/CONTRIBUTORS - -package journal - -import ( - "bytes" - "encoding/binary" - "fmt" - "io" - "io/ioutil" - "math/rand" - "strings" - "testing" -) - -type dropper struct { - t *testing.T -} - -func (d dropper) Drop(err error) { - d.t.Log(err) -} - -func short(s string) string { - if len(s) < 64 { - return s - } - return fmt.Sprintf("%s...(skipping %d bytes)...%s", s[:20], len(s)-40, s[len(s)-20:]) -} - -// big returns a string of length n, composed of repetitions of partial. -func big(partial string, n int) string { - return strings.Repeat(partial, n/len(partial)+1)[:n] -} - -func TestEmpty(t *testing.T) { - buf := new(bytes.Buffer) - r := NewReader(buf, dropper{t}, true, true) - if _, err := r.Next(); err != io.EOF { - t.Fatalf("got %v, want %v", err, io.EOF) - } -} - -func testGenerator(t *testing.T, reset func(), gen func() (string, bool)) { - buf := new(bytes.Buffer) - - reset() - w := NewWriter(buf) - for { - s, ok := gen() - if !ok { - break - } - ww, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write([]byte(s)); err != nil { - t.Fatal(err) - } - } - if err := w.Close(); err != nil { - t.Fatal(err) - } - - reset() - r := NewReader(buf, dropper{t}, true, true) - for { - s, ok := gen() - if !ok { - break - } - rr, err := r.Next() - if err != nil { - t.Fatal(err) - } - x, err := ioutil.ReadAll(rr) - if err != nil { - t.Fatal(err) - } - if string(x) != s { - t.Fatalf("got %q, want %q", short(string(x)), short(s)) - } - } - if _, err := r.Next(); err != io.EOF { - t.Fatalf("got %v, want %v", err, io.EOF) - } -} - -func testLiterals(t *testing.T, s []string) { - var i int - reset := func() { - i = 0 - } - gen := func() (string, bool) { - if i == len(s) { - return "", false - } - i++ - return s[i-1], true - } - testGenerator(t, reset, gen) -} - -func TestMany(t *testing.T) { - const n = 1e5 - var i int - reset := func() { - i = 0 - } - gen := func() (string, bool) { - if i == n { - return "", false - } - i++ - return fmt.Sprintf("%d.", i-1), true - } - testGenerator(t, reset, gen) -} - -func TestRandom(t *testing.T) { - const n = 1e2 - var ( - i int - r *rand.Rand - ) - reset := func() { - i, r = 0, rand.New(rand.NewSource(0)) - } - gen := func() (string, bool) { - if i == n { - return "", false - } - i++ - return strings.Repeat(string(uint8(i)), r.Intn(2*blockSize+16)), true - } - testGenerator(t, reset, gen) -} - -func TestBasic(t *testing.T) { - testLiterals(t, []string{ - strings.Repeat("a", 1000), - strings.Repeat("b", 97270), - strings.Repeat("c", 8000), - }) -} - -func TestBoundary(t *testing.T) { - for i := blockSize - 16; i < blockSize+16; i++ { - s0 := big("abcd", i) - for j := blockSize - 16; j < blockSize+16; j++ { - s1 := big("ABCDE", j) - testLiterals(t, []string{s0, s1}) - testLiterals(t, []string{s0, "", s1}) - testLiterals(t, []string{s0, "x", s1}) - } - } -} - -func TestFlush(t *testing.T) { - buf := new(bytes.Buffer) - w := NewWriter(buf) - // Write a couple of records. Everything should still be held - // in the record.Writer buffer, so that buf.Len should be 0. - w0, _ := w.Next() - w0.Write([]byte("0")) - w1, _ := w.Next() - w1.Write([]byte("11")) - if got, want := buf.Len(), 0; got != want { - t.Fatalf("buffer length #0: got %d want %d", got, want) - } - // Flush the record.Writer buffer, which should yield 17 bytes. - // 17 = 2*7 + 1 + 2, which is two headers and 1 + 2 payload bytes. - if err := w.Flush(); err != nil { - t.Fatal(err) - } - if got, want := buf.Len(), 17; got != want { - t.Fatalf("buffer length #1: got %d want %d", got, want) - } - // Do another write, one that isn't large enough to complete the block. - // The write should not have flowed through to buf. - w2, _ := w.Next() - w2.Write(bytes.Repeat([]byte("2"), 10000)) - if got, want := buf.Len(), 17; got != want { - t.Fatalf("buffer length #2: got %d want %d", got, want) - } - // Flushing should get us up to 10024 bytes written. - // 10024 = 17 + 7 + 10000. - if err := w.Flush(); err != nil { - t.Fatal(err) - } - if got, want := buf.Len(), 10024; got != want { - t.Fatalf("buffer length #3: got %d want %d", got, want) - } - // Do a bigger write, one that completes the current block. - // We should now have 32768 bytes (a complete block), without - // an explicit flush. - w3, _ := w.Next() - w3.Write(bytes.Repeat([]byte("3"), 40000)) - if got, want := buf.Len(), 32768; got != want { - t.Fatalf("buffer length #4: got %d want %d", got, want) - } - // Flushing should get us up to 50038 bytes written. - // 50038 = 10024 + 2*7 + 40000. There are two headers because - // the one record was split into two chunks. - if err := w.Flush(); err != nil { - t.Fatal(err) - } - if got, want := buf.Len(), 50038; got != want { - t.Fatalf("buffer length #5: got %d want %d", got, want) - } - // Check that reading those records give the right lengths. - r := NewReader(buf, dropper{t}, true, true) - wants := []int64{1, 2, 10000, 40000} - for i, want := range wants { - rr, _ := r.Next() - n, err := io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #%d: %v", i, err) - } - if n != want { - t.Fatalf("read #%d: got %d bytes want %d", i, n, want) - } - } -} - -func TestNonExhaustiveRead(t *testing.T) { - const n = 100 - buf := new(bytes.Buffer) - p := make([]byte, 10) - rnd := rand.New(rand.NewSource(1)) - - w := NewWriter(buf) - for i := 0; i < n; i++ { - length := len(p) + rnd.Intn(3*blockSize) - s := string(uint8(i)) + "123456789abcdefgh" - ww, _ := w.Next() - ww.Write([]byte(big(s, length))) - } - if err := w.Close(); err != nil { - t.Fatal(err) - } - - r := NewReader(buf, dropper{t}, true, true) - for i := 0; i < n; i++ { - rr, _ := r.Next() - _, err := io.ReadFull(rr, p) - if err != nil { - t.Fatal(err) - } - want := string(uint8(i)) + "123456789" - if got := string(p); got != want { - t.Fatalf("read #%d: got %q want %q", i, got, want) - } - } -} - -func TestStaleReader(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - w0, err := w.Next() - if err != nil { - t.Fatal(err) - } - w0.Write([]byte("0")) - w1, err := w.Next() - if err != nil { - t.Fatal(err) - } - w1.Write([]byte("11")) - if err := w.Close(); err != nil { - t.Fatal(err) - } - - r := NewReader(buf, dropper{t}, true, true) - r0, err := r.Next() - if err != nil { - t.Fatal(err) - } - r1, err := r.Next() - if err != nil { - t.Fatal(err) - } - p := make([]byte, 1) - if _, err := r0.Read(p); err == nil || !strings.Contains(err.Error(), "stale") { - t.Fatalf("stale read #0: unexpected error: %v", err) - } - if _, err := r1.Read(p); err != nil { - t.Fatalf("fresh read #1: got %v want nil error", err) - } - if p[0] != '1' { - t.Fatalf("fresh read #1: byte contents: got '%c' want '1'", p[0]) - } -} - -func TestStaleWriter(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - w0, err := w.Next() - if err != nil { - t.Fatal(err) - } - w1, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := w0.Write([]byte("0")); err == nil || !strings.Contains(err.Error(), "stale") { - t.Fatalf("stale write #0: unexpected error: %v", err) - } - if _, err := w1.Write([]byte("11")); err != nil { - t.Fatalf("fresh write #1: got %v want nil error", err) - } - if err := w.Flush(); err != nil { - t.Fatalf("flush: %v", err) - } - if _, err := w1.Write([]byte("0")); err == nil || !strings.Contains(err.Error(), "stale") { - t.Fatalf("stale write #1: unexpected error: %v", err) - } -} - -func TestCorrupt_MissingLastBlock(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - - // First record. - ww, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize-1024)); err != nil { - t.Fatalf("write #0: unexpected error: %v", err) - } - - // Second record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize-headerSize)); err != nil { - t.Fatalf("write #1: unexpected error: %v", err) - } - - if err := w.Close(); err != nil { - t.Fatal(err) - } - - // Cut the last block. - b := buf.Bytes()[:blockSize] - r := NewReader(bytes.NewReader(b), dropper{t}, false, true) - - // First read. - rr, err := r.Next() - if err != nil { - t.Fatal(err) - } - n, err := io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #0: %v", err) - } - if n != blockSize-1024 { - t.Fatalf("read #0: got %d bytes want %d", n, blockSize-1024) - } - - // Second read. - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != io.ErrUnexpectedEOF { - t.Fatalf("read #1: unexpected error: %v", err) - } - - if _, err := r.Next(); err != io.EOF { - t.Fatalf("last next: unexpected error: %v", err) - } -} - -func TestCorrupt_CorruptedFirstBlock(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - - // First record. - ww, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize/2)); err != nil { - t.Fatalf("write #0: unexpected error: %v", err) - } - - // Second record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize-headerSize)); err != nil { - t.Fatalf("write #1: unexpected error: %v", err) - } - - // Third record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+1)); err != nil { - t.Fatalf("write #2: unexpected error: %v", err) - } - - // Fourth record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+2)); err != nil { - t.Fatalf("write #3: unexpected error: %v", err) - } - - if err := w.Close(); err != nil { - t.Fatal(err) - } - - b := buf.Bytes() - // Corrupting block #0. - for i := 0; i < 1024; i++ { - b[i] = '1' - } - - r := NewReader(bytes.NewReader(b), dropper{t}, false, true) - - // First read (third record). - rr, err := r.Next() - if err != nil { - t.Fatal(err) - } - n, err := io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #0: %v", err) - } - if want := int64(blockSize-headerSize) + 1; n != want { - t.Fatalf("read #0: got %d bytes want %d", n, want) - } - - // Second read (fourth record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #1: %v", err) - } - if want := int64(blockSize-headerSize) + 2; n != want { - t.Fatalf("read #1: got %d bytes want %d", n, want) - } - - if _, err := r.Next(); err != io.EOF { - t.Fatalf("last next: unexpected error: %v", err) - } -} - -func TestCorrupt_CorruptedMiddleBlock(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - - // First record. - ww, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize/2)); err != nil { - t.Fatalf("write #0: unexpected error: %v", err) - } - - // Second record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize-headerSize)); err != nil { - t.Fatalf("write #1: unexpected error: %v", err) - } - - // Third record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+1)); err != nil { - t.Fatalf("write #2: unexpected error: %v", err) - } - - // Fourth record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+2)); err != nil { - t.Fatalf("write #3: unexpected error: %v", err) - } - - if err := w.Close(); err != nil { - t.Fatal(err) - } - - b := buf.Bytes() - // Corrupting block #1. - for i := 0; i < 1024; i++ { - b[blockSize+i] = '1' - } - - r := NewReader(bytes.NewReader(b), dropper{t}, false, true) - - // First read (first record). - rr, err := r.Next() - if err != nil { - t.Fatal(err) - } - n, err := io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #0: %v", err) - } - if want := int64(blockSize / 2); n != want { - t.Fatalf("read #0: got %d bytes want %d", n, want) - } - - // Second read (second record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != io.ErrUnexpectedEOF { - t.Fatalf("read #1: unexpected error: %v", err) - } - - // Third read (fourth record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #2: %v", err) - } - if want := int64(blockSize-headerSize) + 2; n != want { - t.Fatalf("read #2: got %d bytes want %d", n, want) - } - - if _, err := r.Next(); err != io.EOF { - t.Fatalf("last next: unexpected error: %v", err) - } -} - -func TestCorrupt_CorruptedLastBlock(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - - // First record. - ww, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize/2)); err != nil { - t.Fatalf("write #0: unexpected error: %v", err) - } - - // Second record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize-headerSize)); err != nil { - t.Fatalf("write #1: unexpected error: %v", err) - } - - // Third record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+1)); err != nil { - t.Fatalf("write #2: unexpected error: %v", err) - } - - // Fourth record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+2)); err != nil { - t.Fatalf("write #3: unexpected error: %v", err) - } - - if err := w.Close(); err != nil { - t.Fatal(err) - } - - b := buf.Bytes() - // Corrupting block #3. - for i := len(b) - 1; i > len(b)-1024; i-- { - b[i] = '1' - } - - r := NewReader(bytes.NewReader(b), dropper{t}, false, true) - - // First read (first record). - rr, err := r.Next() - if err != nil { - t.Fatal(err) - } - n, err := io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #0: %v", err) - } - if want := int64(blockSize / 2); n != want { - t.Fatalf("read #0: got %d bytes want %d", n, want) - } - - // Second read (second record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #1: %v", err) - } - if want := int64(blockSize - headerSize); n != want { - t.Fatalf("read #1: got %d bytes want %d", n, want) - } - - // Third read (third record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #2: %v", err) - } - if want := int64(blockSize-headerSize) + 1; n != want { - t.Fatalf("read #2: got %d bytes want %d", n, want) - } - - // Fourth read (fourth record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != io.ErrUnexpectedEOF { - t.Fatalf("read #3: unexpected error: %v", err) - } - - if _, err := r.Next(); err != io.EOF { - t.Fatalf("last next: unexpected error: %v", err) - } -} - -func TestCorrupt_FirstChuckLengthOverflow(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - - // First record. - ww, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize/2)); err != nil { - t.Fatalf("write #0: unexpected error: %v", err) - } - - // Second record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize-headerSize)); err != nil { - t.Fatalf("write #1: unexpected error: %v", err) - } - - // Third record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+1)); err != nil { - t.Fatalf("write #2: unexpected error: %v", err) - } - - if err := w.Close(); err != nil { - t.Fatal(err) - } - - b := buf.Bytes() - // Corrupting record #1. - x := blockSize - binary.LittleEndian.PutUint16(b[x+4:], 0xffff) - - r := NewReader(bytes.NewReader(b), dropper{t}, false, true) - - // First read (first record). - rr, err := r.Next() - if err != nil { - t.Fatal(err) - } - n, err := io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #0: %v", err) - } - if want := int64(blockSize / 2); n != want { - t.Fatalf("read #0: got %d bytes want %d", n, want) - } - - // Second read (second record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != io.ErrUnexpectedEOF { - t.Fatalf("read #1: unexpected error: %v", err) - } - - if _, err := r.Next(); err != io.EOF { - t.Fatalf("last next: unexpected error: %v", err) - } -} - -func TestCorrupt_MiddleChuckLengthOverflow(t *testing.T) { - buf := new(bytes.Buffer) - - w := NewWriter(buf) - - // First record. - ww, err := w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize/2)); err != nil { - t.Fatalf("write #0: unexpected error: %v", err) - } - - // Second record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), blockSize-headerSize)); err != nil { - t.Fatalf("write #1: unexpected error: %v", err) - } - - // Third record. - ww, err = w.Next() - if err != nil { - t.Fatal(err) - } - if _, err := ww.Write(bytes.Repeat([]byte("0"), (blockSize-headerSize)+1)); err != nil { - t.Fatalf("write #2: unexpected error: %v", err) - } - - if err := w.Close(); err != nil { - t.Fatal(err) - } - - b := buf.Bytes() - // Corrupting record #1. - x := blockSize/2 + headerSize - binary.LittleEndian.PutUint16(b[x+4:], 0xffff) - - r := NewReader(bytes.NewReader(b), dropper{t}, false, true) - - // First read (first record). - rr, err := r.Next() - if err != nil { - t.Fatal(err) - } - n, err := io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #0: %v", err) - } - if want := int64(blockSize / 2); n != want { - t.Fatalf("read #0: got %d bytes want %d", n, want) - } - - // Second read (third record). - rr, err = r.Next() - if err != nil { - t.Fatal(err) - } - n, err = io.Copy(ioutil.Discard, rr) - if err != nil { - t.Fatalf("read #1: %v", err) - } - if want := int64(blockSize-headerSize) + 1; n != want { - t.Fatalf("read #1: got %d bytes want %d", n, want) - } - - if _, err := r.Next(); err != io.EOF { - t.Fatalf("last next: unexpected error: %v", err) - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/key.go b/vendor/github.com/syndtr/goleveldb/leveldb/key.go deleted file mode 100644 index ad8f51e..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/key.go +++ /dev/null @@ -1,143 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "encoding/binary" - "fmt" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -// ErrInternalKeyCorrupted records internal key corruption. -type ErrInternalKeyCorrupted struct { - Ikey []byte - Reason string -} - -func (e *ErrInternalKeyCorrupted) Error() string { - return fmt.Sprintf("leveldb: internal key %q corrupted: %s", e.Ikey, e.Reason) -} - -func newErrInternalKeyCorrupted(ikey []byte, reason string) error { - return errors.NewErrCorrupted(storage.FileDesc{}, &ErrInternalKeyCorrupted{append([]byte{}, ikey...), reason}) -} - -type keyType uint - -func (kt keyType) String() string { - switch kt { - case keyTypeDel: - return "d" - case keyTypeVal: - return "v" - } - return fmt.Sprintf("", uint(kt)) -} - -// Value types encoded as the last component of internal keys. -// Don't modify; this value are saved to disk. -const ( - keyTypeDel = keyType(0) - keyTypeVal = keyType(1) -) - -// keyTypeSeek defines the keyType that should be passed when constructing an -// internal key for seeking to a particular sequence number (since we -// sort sequence numbers in decreasing order and the value type is -// embedded as the low 8 bits in the sequence number in internal keys, -// we need to use the highest-numbered ValueType, not the lowest). -const keyTypeSeek = keyTypeVal - -const ( - // Maximum value possible for sequence number; the 8-bits are - // used by value type, so its can packed together in single - // 64-bit integer. - keyMaxSeq = (uint64(1) << 56) - 1 - // Maximum value possible for packed sequence number and type. - keyMaxNum = (keyMaxSeq << 8) | uint64(keyTypeSeek) -) - -// Maximum number encoded in bytes. -var keyMaxNumBytes = make([]byte, 8) - -func init() { - binary.LittleEndian.PutUint64(keyMaxNumBytes, keyMaxNum) -} - -type internalKey []byte - -func makeInternalKey(dst, ukey []byte, seq uint64, kt keyType) internalKey { - if seq > keyMaxSeq { - panic("leveldb: invalid sequence number") - } else if kt > keyTypeVal { - panic("leveldb: invalid type") - } - - dst = ensureBuffer(dst, len(ukey)+8) - copy(dst, ukey) - binary.LittleEndian.PutUint64(dst[len(ukey):], (seq<<8)|uint64(kt)) - return internalKey(dst) -} - -func parseInternalKey(ik []byte) (ukey []byte, seq uint64, kt keyType, err error) { - if len(ik) < 8 { - return nil, 0, 0, newErrInternalKeyCorrupted(ik, "invalid length") - } - num := binary.LittleEndian.Uint64(ik[len(ik)-8:]) - seq, kt = uint64(num>>8), keyType(num&0xff) - if kt > keyTypeVal { - return nil, 0, 0, newErrInternalKeyCorrupted(ik, "invalid type") - } - ukey = ik[:len(ik)-8] - return -} - -func validInternalKey(ik []byte) bool { - _, _, _, err := parseInternalKey(ik) - return err == nil -} - -func (ik internalKey) assert() { - if ik == nil { - panic("leveldb: nil internalKey") - } - if len(ik) < 8 { - panic(fmt.Sprintf("leveldb: internal key %q, len=%d: invalid length", []byte(ik), len(ik))) - } -} - -func (ik internalKey) ukey() []byte { - ik.assert() - return ik[:len(ik)-8] -} - -func (ik internalKey) num() uint64 { - ik.assert() - return binary.LittleEndian.Uint64(ik[len(ik)-8:]) -} - -func (ik internalKey) parseNum() (seq uint64, kt keyType) { - num := ik.num() - seq, kt = uint64(num>>8), keyType(num&0xff) - if kt > keyTypeVal { - panic(fmt.Sprintf("leveldb: internal key %q, len=%d: invalid type %#x", []byte(ik), len(ik), kt)) - } - return -} - -func (ik internalKey) String() string { - if ik == nil { - return "" - } - - if ukey, seq, kt, err := parseInternalKey(ik); err == nil { - return fmt.Sprintf("%s,%s%d", shorten(string(ukey)), kt, seq) - } - return fmt.Sprintf("", []byte(ik)) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/key_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/key_test.go deleted file mode 100644 index 2f33ccb..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/key_test.go +++ /dev/null @@ -1,133 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "bytes" - "testing" - - "github.com/syndtr/goleveldb/leveldb/comparer" -) - -var defaultIComparer = &iComparer{comparer.DefaultComparer} - -func ikey(key string, seq uint64, kt keyType) internalKey { - return makeInternalKey(nil, []byte(key), uint64(seq), kt) -} - -func shortSep(a, b []byte) []byte { - dst := make([]byte, len(a)) - dst = defaultIComparer.Separator(dst[:0], a, b) - if dst == nil { - return a - } - return dst -} - -func shortSuccessor(b []byte) []byte { - dst := make([]byte, len(b)) - dst = defaultIComparer.Successor(dst[:0], b) - if dst == nil { - return b - } - return dst -} - -func testSingleKey(t *testing.T, key string, seq uint64, kt keyType) { - ik := ikey(key, seq, kt) - - if !bytes.Equal(ik.ukey(), []byte(key)) { - t.Errorf("user key does not equal, got %v, want %v", string(ik.ukey()), key) - } - - rseq, rt := ik.parseNum() - if rseq != seq { - t.Errorf("seq number does not equal, got %v, want %v", rseq, seq) - } - if rt != kt { - t.Errorf("type does not equal, got %v, want %v", rt, kt) - } - - if rukey, rseq, rt, kerr := parseInternalKey(ik); kerr == nil { - if !bytes.Equal(rukey, []byte(key)) { - t.Errorf("user key does not equal, got %v, want %v", string(ik.ukey()), key) - } - if rseq != seq { - t.Errorf("seq number does not equal, got %v, want %v", rseq, seq) - } - if rt != kt { - t.Errorf("type does not equal, got %v, want %v", rt, kt) - } - } else { - t.Errorf("key error: %v", kerr) - } -} - -func TestInternalKey_EncodeDecode(t *testing.T) { - keys := []string{"", "k", "hello", "longggggggggggggggggggggg"} - seqs := []uint64{ - 1, 2, 3, - (1 << 8) - 1, 1 << 8, (1 << 8) + 1, - (1 << 16) - 1, 1 << 16, (1 << 16) + 1, - (1 << 32) - 1, 1 << 32, (1 << 32) + 1, - } - for _, key := range keys { - for _, seq := range seqs { - testSingleKey(t, key, seq, keyTypeVal) - testSingleKey(t, "hello", 1, keyTypeDel) - } - } -} - -func assertBytes(t *testing.T, want, got []byte) { - if !bytes.Equal(got, want) { - t.Errorf("assert failed, got %v, want %v", got, want) - } -} - -func TestInternalKeyShortSeparator(t *testing.T) { - // When user keys are same - assertBytes(t, ikey("foo", 100, keyTypeVal), - shortSep(ikey("foo", 100, keyTypeVal), - ikey("foo", 99, keyTypeVal))) - assertBytes(t, ikey("foo", 100, keyTypeVal), - shortSep(ikey("foo", 100, keyTypeVal), - ikey("foo", 101, keyTypeVal))) - assertBytes(t, ikey("foo", 100, keyTypeVal), - shortSep(ikey("foo", 100, keyTypeVal), - ikey("foo", 100, keyTypeVal))) - assertBytes(t, ikey("foo", 100, keyTypeVal), - shortSep(ikey("foo", 100, keyTypeVal), - ikey("foo", 100, keyTypeDel))) - - // When user keys are misordered - assertBytes(t, ikey("foo", 100, keyTypeVal), - shortSep(ikey("foo", 100, keyTypeVal), - ikey("bar", 99, keyTypeVal))) - - // When user keys are different, but correctly ordered - assertBytes(t, ikey("g", uint64(keyMaxSeq), keyTypeSeek), - shortSep(ikey("foo", 100, keyTypeVal), - ikey("hello", 200, keyTypeVal))) - - // When start user key is prefix of limit user key - assertBytes(t, ikey("foo", 100, keyTypeVal), - shortSep(ikey("foo", 100, keyTypeVal), - ikey("foobar", 200, keyTypeVal))) - - // When limit user key is prefix of start user key - assertBytes(t, ikey("foobar", 100, keyTypeVal), - shortSep(ikey("foobar", 100, keyTypeVal), - ikey("foo", 200, keyTypeVal))) -} - -func TestInternalKeyShortestSuccessor(t *testing.T) { - assertBytes(t, ikey("g", uint64(keyMaxSeq), keyTypeSeek), - shortSuccessor(ikey("foo", 100, keyTypeVal))) - assertBytes(t, ikey("\xff\xff", 100, keyTypeVal), - shortSuccessor(ikey("\xff\xff", 100, keyTypeVal))) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/leveldb_suite_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/leveldb_suite_test.go deleted file mode 100644 index fefa007..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/leveldb_suite_test.go +++ /dev/null @@ -1,11 +0,0 @@ -package leveldb - -import ( - "testing" - - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -func TestLevelDB(t *testing.T) { - testutil.RunSuite(t, "LevelDB Suite") -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/bench_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/memdb/bench_test.go deleted file mode 100644 index b05084c..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/bench_test.go +++ /dev/null @@ -1,75 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package memdb - -import ( - "encoding/binary" - "math/rand" - "testing" - - "github.com/syndtr/goleveldb/leveldb/comparer" -) - -func BenchmarkPut(b *testing.B) { - buf := make([][4]byte, b.N) - for i := range buf { - binary.LittleEndian.PutUint32(buf[i][:], uint32(i)) - } - - b.ResetTimer() - p := New(comparer.DefaultComparer, 0) - for i := range buf { - p.Put(buf[i][:], nil) - } -} - -func BenchmarkPutRandom(b *testing.B) { - buf := make([][4]byte, b.N) - for i := range buf { - binary.LittleEndian.PutUint32(buf[i][:], uint32(rand.Int())) - } - - b.ResetTimer() - p := New(comparer.DefaultComparer, 0) - for i := range buf { - p.Put(buf[i][:], nil) - } -} - -func BenchmarkGet(b *testing.B) { - buf := make([][4]byte, b.N) - for i := range buf { - binary.LittleEndian.PutUint32(buf[i][:], uint32(i)) - } - - p := New(comparer.DefaultComparer, 0) - for i := range buf { - p.Put(buf[i][:], nil) - } - - b.ResetTimer() - for i := range buf { - p.Get(buf[i][:]) - } -} - -func BenchmarkGetRandom(b *testing.B) { - buf := make([][4]byte, b.N) - for i := range buf { - binary.LittleEndian.PutUint32(buf[i][:], uint32(i)) - } - - p := New(comparer.DefaultComparer, 0) - for i := range buf { - p.Put(buf[i][:], nil) - } - - b.ResetTimer() - for i := 0; i < b.N; i++ { - p.Get(buf[rand.Int()%b.N][:]) - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb.go b/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb.go deleted file mode 100644 index b661c08..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb.go +++ /dev/null @@ -1,475 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package memdb provides in-memory key/value database implementation. -package memdb - -import ( - "math/rand" - "sync" - - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// Common errors. -var ( - ErrNotFound = errors.ErrNotFound - ErrIterReleased = errors.New("leveldb/memdb: iterator released") -) - -const tMaxHeight = 12 - -type dbIter struct { - util.BasicReleaser - p *DB - slice *util.Range - node int - forward bool - key, value []byte - err error -} - -func (i *dbIter) fill(checkStart, checkLimit bool) bool { - if i.node != 0 { - n := i.p.nodeData[i.node] - m := n + i.p.nodeData[i.node+nKey] - i.key = i.p.kvData[n:m] - if i.slice != nil { - switch { - case checkLimit && i.slice.Limit != nil && i.p.cmp.Compare(i.key, i.slice.Limit) >= 0: - fallthrough - case checkStart && i.slice.Start != nil && i.p.cmp.Compare(i.key, i.slice.Start) < 0: - i.node = 0 - goto bail - } - } - i.value = i.p.kvData[m : m+i.p.nodeData[i.node+nVal]] - return true - } -bail: - i.key = nil - i.value = nil - return false -} - -func (i *dbIter) Valid() bool { - return i.node != 0 -} - -func (i *dbIter) First() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - i.forward = true - i.p.mu.RLock() - defer i.p.mu.RUnlock() - if i.slice != nil && i.slice.Start != nil { - i.node, _ = i.p.findGE(i.slice.Start, false) - } else { - i.node = i.p.nodeData[nNext] - } - return i.fill(false, true) -} - -func (i *dbIter) Last() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - i.forward = false - i.p.mu.RLock() - defer i.p.mu.RUnlock() - if i.slice != nil && i.slice.Limit != nil { - i.node = i.p.findLT(i.slice.Limit) - } else { - i.node = i.p.findLast() - } - return i.fill(true, false) -} - -func (i *dbIter) Seek(key []byte) bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - i.forward = true - i.p.mu.RLock() - defer i.p.mu.RUnlock() - if i.slice != nil && i.slice.Start != nil && i.p.cmp.Compare(key, i.slice.Start) < 0 { - key = i.slice.Start - } - i.node, _ = i.p.findGE(key, false) - return i.fill(false, true) -} - -func (i *dbIter) Next() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - if i.node == 0 { - if !i.forward { - return i.First() - } - return false - } - i.forward = true - i.p.mu.RLock() - defer i.p.mu.RUnlock() - i.node = i.p.nodeData[i.node+nNext] - return i.fill(false, true) -} - -func (i *dbIter) Prev() bool { - if i.Released() { - i.err = ErrIterReleased - return false - } - - if i.node == 0 { - if i.forward { - return i.Last() - } - return false - } - i.forward = false - i.p.mu.RLock() - defer i.p.mu.RUnlock() - i.node = i.p.findLT(i.key) - return i.fill(true, false) -} - -func (i *dbIter) Key() []byte { - return i.key -} - -func (i *dbIter) Value() []byte { - return i.value -} - -func (i *dbIter) Error() error { return i.err } - -func (i *dbIter) Release() { - if !i.Released() { - i.p = nil - i.node = 0 - i.key = nil - i.value = nil - i.BasicReleaser.Release() - } -} - -const ( - nKV = iota - nKey - nVal - nHeight - nNext -) - -// DB is an in-memory key/value database. -type DB struct { - cmp comparer.BasicComparer - rnd *rand.Rand - - mu sync.RWMutex - kvData []byte - // Node data: - // [0] : KV offset - // [1] : Key length - // [2] : Value length - // [3] : Height - // [3..height] : Next nodes - nodeData []int - prevNode [tMaxHeight]int - maxHeight int - n int - kvSize int -} - -func (p *DB) randHeight() (h int) { - const branching = 4 - h = 1 - for h < tMaxHeight && p.rnd.Int()%branching == 0 { - h++ - } - return -} - -// Must hold RW-lock if prev == true, as it use shared prevNode slice. -func (p *DB) findGE(key []byte, prev bool) (int, bool) { - node := 0 - h := p.maxHeight - 1 - for { - next := p.nodeData[node+nNext+h] - cmp := 1 - if next != 0 { - o := p.nodeData[next] - cmp = p.cmp.Compare(p.kvData[o:o+p.nodeData[next+nKey]], key) - } - if cmp < 0 { - // Keep searching in this list - node = next - } else { - if prev { - p.prevNode[h] = node - } else if cmp == 0 { - return next, true - } - if h == 0 { - return next, cmp == 0 - } - h-- - } - } -} - -func (p *DB) findLT(key []byte) int { - node := 0 - h := p.maxHeight - 1 - for { - next := p.nodeData[node+nNext+h] - o := p.nodeData[next] - if next == 0 || p.cmp.Compare(p.kvData[o:o+p.nodeData[next+nKey]], key) >= 0 { - if h == 0 { - break - } - h-- - } else { - node = next - } - } - return node -} - -func (p *DB) findLast() int { - node := 0 - h := p.maxHeight - 1 - for { - next := p.nodeData[node+nNext+h] - if next == 0 { - if h == 0 { - break - } - h-- - } else { - node = next - } - } - return node -} - -// Put sets the value for the given key. It overwrites any previous value -// for that key; a DB is not a multi-map. -// -// It is safe to modify the contents of the arguments after Put returns. -func (p *DB) Put(key []byte, value []byte) error { - p.mu.Lock() - defer p.mu.Unlock() - - if node, exact := p.findGE(key, true); exact { - kvOffset := len(p.kvData) - p.kvData = append(p.kvData, key...) - p.kvData = append(p.kvData, value...) - p.nodeData[node] = kvOffset - m := p.nodeData[node+nVal] - p.nodeData[node+nVal] = len(value) - p.kvSize += len(value) - m - return nil - } - - h := p.randHeight() - if h > p.maxHeight { - for i := p.maxHeight; i < h; i++ { - p.prevNode[i] = 0 - } - p.maxHeight = h - } - - kvOffset := len(p.kvData) - p.kvData = append(p.kvData, key...) - p.kvData = append(p.kvData, value...) - // Node - node := len(p.nodeData) - p.nodeData = append(p.nodeData, kvOffset, len(key), len(value), h) - for i, n := range p.prevNode[:h] { - m := n + nNext + i - p.nodeData = append(p.nodeData, p.nodeData[m]) - p.nodeData[m] = node - } - - p.kvSize += len(key) + len(value) - p.n++ - return nil -} - -// Delete deletes the value for the given key. It returns ErrNotFound if -// the DB does not contain the key. -// -// It is safe to modify the contents of the arguments after Delete returns. -func (p *DB) Delete(key []byte) error { - p.mu.Lock() - defer p.mu.Unlock() - - node, exact := p.findGE(key, true) - if !exact { - return ErrNotFound - } - - h := p.nodeData[node+nHeight] - for i, n := range p.prevNode[:h] { - m := n + nNext + i - p.nodeData[m] = p.nodeData[p.nodeData[m]+nNext+i] - } - - p.kvSize -= p.nodeData[node+nKey] + p.nodeData[node+nVal] - p.n-- - return nil -} - -// Contains returns true if the given key are in the DB. -// -// It is safe to modify the contents of the arguments after Contains returns. -func (p *DB) Contains(key []byte) bool { - p.mu.RLock() - _, exact := p.findGE(key, false) - p.mu.RUnlock() - return exact -} - -// Get gets the value for the given key. It returns error.ErrNotFound if the -// DB does not contain the key. -// -// The caller should not modify the contents of the returned slice, but -// it is safe to modify the contents of the argument after Get returns. -func (p *DB) Get(key []byte) (value []byte, err error) { - p.mu.RLock() - if node, exact := p.findGE(key, false); exact { - o := p.nodeData[node] + p.nodeData[node+nKey] - value = p.kvData[o : o+p.nodeData[node+nVal]] - } else { - err = ErrNotFound - } - p.mu.RUnlock() - return -} - -// Find finds key/value pair whose key is greater than or equal to the -// given key. It returns ErrNotFound if the table doesn't contain -// such pair. -// -// The caller should not modify the contents of the returned slice, but -// it is safe to modify the contents of the argument after Find returns. -func (p *DB) Find(key []byte) (rkey, value []byte, err error) { - p.mu.RLock() - if node, _ := p.findGE(key, false); node != 0 { - n := p.nodeData[node] - m := n + p.nodeData[node+nKey] - rkey = p.kvData[n:m] - value = p.kvData[m : m+p.nodeData[node+nVal]] - } else { - err = ErrNotFound - } - p.mu.RUnlock() - return -} - -// NewIterator returns an iterator of the DB. -// The returned iterator is not safe for concurrent use, but it is safe to use -// multiple iterators concurrently, with each in a dedicated goroutine. -// It is also safe to use an iterator concurrently with modifying its -// underlying DB. However, the resultant key/value pairs are not guaranteed -// to be a consistent snapshot of the DB at a particular point in time. -// -// Slice allows slicing the iterator to only contains keys in the given -// range. A nil Range.Start is treated as a key before all keys in the -// DB. And a nil Range.Limit is treated as a key after all keys in -// the DB. -// -// The iterator must be released after use, by calling Release method. -// -// Also read Iterator documentation of the leveldb/iterator package. -func (p *DB) NewIterator(slice *util.Range) iterator.Iterator { - return &dbIter{p: p, slice: slice} -} - -// Capacity returns keys/values buffer capacity. -func (p *DB) Capacity() int { - p.mu.RLock() - defer p.mu.RUnlock() - return cap(p.kvData) -} - -// Size returns sum of keys and values length. Note that deleted -// key/value will not be accounted for, but it will still consume -// the buffer, since the buffer is append only. -func (p *DB) Size() int { - p.mu.RLock() - defer p.mu.RUnlock() - return p.kvSize -} - -// Free returns keys/values free buffer before need to grow. -func (p *DB) Free() int { - p.mu.RLock() - defer p.mu.RUnlock() - return cap(p.kvData) - len(p.kvData) -} - -// Len returns the number of entries in the DB. -func (p *DB) Len() int { - p.mu.RLock() - defer p.mu.RUnlock() - return p.n -} - -// Reset resets the DB to initial empty state. Allows reuse the buffer. -func (p *DB) Reset() { - p.mu.Lock() - p.rnd = rand.New(rand.NewSource(0xdeadbeef)) - p.maxHeight = 1 - p.n = 0 - p.kvSize = 0 - p.kvData = p.kvData[:0] - p.nodeData = p.nodeData[:nNext+tMaxHeight] - p.nodeData[nKV] = 0 - p.nodeData[nKey] = 0 - p.nodeData[nVal] = 0 - p.nodeData[nHeight] = tMaxHeight - for n := 0; n < tMaxHeight; n++ { - p.nodeData[nNext+n] = 0 - p.prevNode[n] = 0 - } - p.mu.Unlock() -} - -// New creates a new initialized in-memory key/value DB. The capacity -// is the initial key/value buffer capacity. The capacity is advisory, -// not enforced. -// -// This DB is append-only, deleting an entry would remove entry node but not -// reclaim KV buffer. -// -// The returned DB instance is safe for concurrent use. -func New(cmp comparer.BasicComparer, capacity int) *DB { - p := &DB{ - cmp: cmp, - rnd: rand.New(rand.NewSource(0xdeadbeef)), - maxHeight: 1, - kvData: make([]byte, 0, capacity), - nodeData: make([]int, 4+tMaxHeight), - } - p.nodeData[nHeight] = tMaxHeight - return p -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb_suite_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb_suite_test.go deleted file mode 100644 index 18c304b..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb_suite_test.go +++ /dev/null @@ -1,11 +0,0 @@ -package memdb - -import ( - "testing" - - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -func TestMemDB(t *testing.T) { - testutil.RunSuite(t, "MemDB Suite") -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb_test.go deleted file mode 100644 index 3f0a31e..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/memdb/memdb_test.go +++ /dev/null @@ -1,135 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package memdb - -import ( - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/testutil" - "github.com/syndtr/goleveldb/leveldb/util" -) - -func (p *DB) TestFindLT(key []byte) (rkey, value []byte, err error) { - p.mu.RLock() - if node := p.findLT(key); node != 0 { - n := p.nodeData[node] - m := n + p.nodeData[node+nKey] - rkey = p.kvData[n:m] - value = p.kvData[m : m+p.nodeData[node+nVal]] - } else { - err = ErrNotFound - } - p.mu.RUnlock() - return -} - -func (p *DB) TestFindLast() (rkey, value []byte, err error) { - p.mu.RLock() - if node := p.findLast(); node != 0 { - n := p.nodeData[node] - m := n + p.nodeData[node+nKey] - rkey = p.kvData[n:m] - value = p.kvData[m : m+p.nodeData[node+nVal]] - } else { - err = ErrNotFound - } - p.mu.RUnlock() - return -} - -func (p *DB) TestPut(key []byte, value []byte) error { - p.Put(key, value) - return nil -} - -func (p *DB) TestDelete(key []byte) error { - p.Delete(key) - return nil -} - -func (p *DB) TestFind(key []byte) (rkey, rvalue []byte, err error) { - return p.Find(key) -} - -func (p *DB) TestGet(key []byte) (value []byte, err error) { - return p.Get(key) -} - -func (p *DB) TestNewIterator(slice *util.Range) iterator.Iterator { - return p.NewIterator(slice) -} - -var _ = testutil.Defer(func() { - Describe("Memdb", func() { - Describe("write test", func() { - It("should do write correctly", func() { - db := New(comparer.DefaultComparer, 0) - t := testutil.DBTesting{ - DB: db, - Deleted: testutil.KeyValue_Generate(nil, 1000, 1, 1, 30, 5, 5).Clone(), - PostFn: func(t *testutil.DBTesting) { - Expect(db.Len()).Should(Equal(t.Present.Len())) - Expect(db.Size()).Should(Equal(t.Present.Size())) - switch t.Act { - case testutil.DBPut, testutil.DBOverwrite: - Expect(db.Contains(t.ActKey)).Should(BeTrue()) - default: - Expect(db.Contains(t.ActKey)).Should(BeFalse()) - } - }, - } - testutil.DoDBTesting(&t) - }) - }) - - Describe("read test", func() { - testutil.AllKeyValueTesting(nil, func(kv testutil.KeyValue) testutil.DB { - // Building the DB. - db := New(comparer.DefaultComparer, 0) - kv.IterateShuffled(nil, func(i int, key, value []byte) { - db.Put(key, value) - }) - - if kv.Len() > 1 { - It("Should find correct keys with findLT", func() { - testutil.ShuffledIndex(nil, kv.Len()-1, 1, func(i int) { - key_, key, _ := kv.IndexInexact(i + 1) - expectedKey, expectedValue := kv.Index(i) - - // Using key that exist. - rkey, rvalue, err := db.TestFindLT(key) - Expect(err).ShouldNot(HaveOccurred(), "Error for key %q -> %q", key, expectedKey) - Expect(rkey).Should(Equal(expectedKey), "Key") - Expect(rvalue).Should(Equal(expectedValue), "Value for key %q -> %q", key, expectedKey) - - // Using key that doesn't exist. - rkey, rvalue, err = db.TestFindLT(key_) - Expect(err).ShouldNot(HaveOccurred(), "Error for key %q (%q) -> %q", key_, key, expectedKey) - Expect(rkey).Should(Equal(expectedKey)) - Expect(rvalue).Should(Equal(expectedValue), "Value for key %q (%q) -> %q", key_, key, expectedKey) - }) - }) - } - - if kv.Len() > 0 { - It("Should find last key with findLast", func() { - key, value := kv.Index(kv.Len() - 1) - rkey, rvalue, err := db.TestFindLast() - Expect(err).ShouldNot(HaveOccurred()) - Expect(rkey).Should(Equal(key)) - Expect(rvalue).Should(Equal(value)) - }) - } - - return db - }, nil, nil) - }) - }) -}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options.go b/vendor/github.com/syndtr/goleveldb/leveldb/opt/options.go deleted file mode 100644 index 44e7d9a..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/opt/options.go +++ /dev/null @@ -1,684 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package opt provides sets of options used by LevelDB. -package opt - -import ( - "math" - - "github.com/syndtr/goleveldb/leveldb/cache" - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/filter" -) - -const ( - KiB = 1024 - MiB = KiB * 1024 - GiB = MiB * 1024 -) - -var ( - DefaultBlockCacher = LRUCacher - DefaultBlockCacheCapacity = 8 * MiB - DefaultBlockRestartInterval = 16 - DefaultBlockSize = 4 * KiB - DefaultCompactionExpandLimitFactor = 25 - DefaultCompactionGPOverlapsFactor = 10 - DefaultCompactionL0Trigger = 4 - DefaultCompactionSourceLimitFactor = 1 - DefaultCompactionTableSize = 2 * MiB - DefaultCompactionTableSizeMultiplier = 1.0 - DefaultCompactionTotalSize = 10 * MiB - DefaultCompactionTotalSizeMultiplier = 10.0 - DefaultCompressionType = SnappyCompression - DefaultIteratorSamplingRate = 1 * MiB - DefaultOpenFilesCacher = LRUCacher - DefaultOpenFilesCacheCapacity = 500 - DefaultWriteBuffer = 4 * MiB - DefaultWriteL0PauseTrigger = 12 - DefaultWriteL0SlowdownTrigger = 8 -) - -// Cacher is a caching algorithm. -type Cacher interface { - New(capacity int) cache.Cacher -} - -type CacherFunc struct { - NewFunc func(capacity int) cache.Cacher -} - -func (f *CacherFunc) New(capacity int) cache.Cacher { - if f.NewFunc != nil { - return f.NewFunc(capacity) - } - return nil -} - -func noCacher(int) cache.Cacher { return nil } - -var ( - // LRUCacher is the LRU-cache algorithm. - LRUCacher = &CacherFunc{cache.NewLRU} - - // NoCacher is the value to disable caching algorithm. - NoCacher = &CacherFunc{} -) - -// Compression is the 'sorted table' block compression algorithm to use. -type Compression uint - -func (c Compression) String() string { - switch c { - case DefaultCompression: - return "default" - case NoCompression: - return "none" - case SnappyCompression: - return "snappy" - } - return "invalid" -} - -const ( - DefaultCompression Compression = iota - NoCompression - SnappyCompression - nCompression -) - -// Strict is the DB 'strict level'. -type Strict uint - -const ( - // If present then a corrupted or invalid chunk or block in manifest - // journal will cause an error instead of being dropped. - // This will prevent database with corrupted manifest to be opened. - StrictManifest Strict = 1 << iota - - // If present then journal chunk checksum will be verified. - StrictJournalChecksum - - // If present then a corrupted or invalid chunk or block in journal - // will cause an error instead of being dropped. - // This will prevent database with corrupted journal to be opened. - StrictJournal - - // If present then 'sorted table' block checksum will be verified. - // This has effect on both 'read operation' and compaction. - StrictBlockChecksum - - // If present then a corrupted 'sorted table' will fails compaction. - // The database will enter read-only mode. - StrictCompaction - - // If present then a corrupted 'sorted table' will halts 'read operation'. - StrictReader - - // If present then leveldb.Recover will drop corrupted 'sorted table'. - StrictRecovery - - // This only applicable for ReadOptions, if present then this ReadOptions - // 'strict level' will override global ones. - StrictOverride - - // StrictAll enables all strict flags. - StrictAll = StrictManifest | StrictJournalChecksum | StrictJournal | StrictBlockChecksum | StrictCompaction | StrictReader | StrictRecovery - - // DefaultStrict is the default strict flags. Specify any strict flags - // will override default strict flags as whole (i.e. not OR'ed). - DefaultStrict = StrictJournalChecksum | StrictBlockChecksum | StrictCompaction | StrictReader - - // NoStrict disables all strict flags. Override default strict flags. - NoStrict = ^StrictAll -) - -// Options holds the optional parameters for the DB at large. -type Options struct { - // AltFilters defines one or more 'alternative filters'. - // 'alternative filters' will be used during reads if a filter block - // does not match with the 'effective filter'. - // - // The default value is nil - AltFilters []filter.Filter - - // BlockCacher provides cache algorithm for LevelDB 'sorted table' block caching. - // Specify NoCacher to disable caching algorithm. - // - // The default value is LRUCacher. - BlockCacher Cacher - - // BlockCacheCapacity defines the capacity of the 'sorted table' block caching. - // Use -1 for zero, this has same effect as specifying NoCacher to BlockCacher. - // - // The default value is 8MiB. - BlockCacheCapacity int - - // BlockRestartInterval is the number of keys between restart points for - // delta encoding of keys. - // - // The default value is 16. - BlockRestartInterval int - - // BlockSize is the minimum uncompressed size in bytes of each 'sorted table' - // block. - // - // The default value is 4KiB. - BlockSize int - - // CompactionExpandLimitFactor limits compaction size after expanded. - // This will be multiplied by table size limit at compaction target level. - // - // The default value is 25. - CompactionExpandLimitFactor int - - // CompactionGPOverlapsFactor limits overlaps in grandparent (Level + 2) that a - // single 'sorted table' generates. - // This will be multiplied by table size limit at grandparent level. - // - // The default value is 10. - CompactionGPOverlapsFactor int - - // CompactionL0Trigger defines number of 'sorted table' at level-0 that will - // trigger compaction. - // - // The default value is 4. - CompactionL0Trigger int - - // CompactionSourceLimitFactor limits compaction source size. This doesn't apply to - // level-0. - // This will be multiplied by table size limit at compaction target level. - // - // The default value is 1. - CompactionSourceLimitFactor int - - // CompactionTableSize limits size of 'sorted table' that compaction generates. - // The limits for each level will be calculated as: - // CompactionTableSize * (CompactionTableSizeMultiplier ^ Level) - // The multiplier for each level can also fine-tuned using CompactionTableSizeMultiplierPerLevel. - // - // The default value is 2MiB. - CompactionTableSize int - - // CompactionTableSizeMultiplier defines multiplier for CompactionTableSize. - // - // The default value is 1. - CompactionTableSizeMultiplier float64 - - // CompactionTableSizeMultiplierPerLevel defines per-level multiplier for - // CompactionTableSize. - // Use zero to skip a level. - // - // The default value is nil. - CompactionTableSizeMultiplierPerLevel []float64 - - // CompactionTotalSize limits total size of 'sorted table' for each level. - // The limits for each level will be calculated as: - // CompactionTotalSize * (CompactionTotalSizeMultiplier ^ Level) - // The multiplier for each level can also fine-tuned using - // CompactionTotalSizeMultiplierPerLevel. - // - // The default value is 10MiB. - CompactionTotalSize int - - // CompactionTotalSizeMultiplier defines multiplier for CompactionTotalSize. - // - // The default value is 10. - CompactionTotalSizeMultiplier float64 - - // CompactionTotalSizeMultiplierPerLevel defines per-level multiplier for - // CompactionTotalSize. - // Use zero to skip a level. - // - // The default value is nil. - CompactionTotalSizeMultiplierPerLevel []float64 - - // Comparer defines a total ordering over the space of []byte keys: a 'less - // than' relationship. The same comparison algorithm must be used for reads - // and writes over the lifetime of the DB. - // - // The default value uses the same ordering as bytes.Compare. - Comparer comparer.Comparer - - // Compression defines the 'sorted table' block compression to use. - // - // The default value (DefaultCompression) uses snappy compression. - Compression Compression - - // DisableBufferPool allows disable use of util.BufferPool functionality. - // - // The default value is false. - DisableBufferPool bool - - // DisableBlockCache allows disable use of cache.Cache functionality on - // 'sorted table' block. - // - // The default value is false. - DisableBlockCache bool - - // DisableCompactionBackoff allows disable compaction retry backoff. - // - // The default value is false. - DisableCompactionBackoff bool - - // DisableLargeBatchTransaction allows disabling switch-to-transaction mode - // on large batch write. If enable batch writes large than WriteBuffer will - // use transaction. - // - // The default is false. - DisableLargeBatchTransaction bool - - // ErrorIfExist defines whether an error should returned if the DB already - // exist. - // - // The default value is false. - ErrorIfExist bool - - // ErrorIfMissing defines whether an error should returned if the DB is - // missing. If false then the database will be created if missing, otherwise - // an error will be returned. - // - // The default value is false. - ErrorIfMissing bool - - // Filter defines an 'effective filter' to use. An 'effective filter' - // if defined will be used to generate per-table filter block. - // The filter name will be stored on disk. - // During reads LevelDB will try to find matching filter from - // 'effective filter' and 'alternative filters'. - // - // Filter can be changed after a DB has been created. It is recommended - // to put old filter to the 'alternative filters' to mitigate lack of - // filter during transition period. - // - // A filter is used to reduce disk reads when looking for a specific key. - // - // The default value is nil. - Filter filter.Filter - - // IteratorSamplingRate defines approximate gap (in bytes) between read - // sampling of an iterator. The samples will be used to determine when - // compaction should be triggered. - // - // The default is 1MiB. - IteratorSamplingRate int - - // NoSync allows completely disable fsync. - // - // The default is false. - NoSync bool - - // NoWriteMerge allows disabling write merge. - // - // The default is false. - NoWriteMerge bool - - // OpenFilesCacher provides cache algorithm for open files caching. - // Specify NoCacher to disable caching algorithm. - // - // The default value is LRUCacher. - OpenFilesCacher Cacher - - // OpenFilesCacheCapacity defines the capacity of the open files caching. - // Use -1 for zero, this has same effect as specifying NoCacher to OpenFilesCacher. - // - // The default value is 500. - OpenFilesCacheCapacity int - - // If true then opens DB in read-only mode. - // - // The default value is false. - ReadOnly bool - - // Strict defines the DB strict level. - Strict Strict - - // WriteBuffer defines maximum size of a 'memdb' before flushed to - // 'sorted table'. 'memdb' is an in-memory DB backed by an on-disk - // unsorted journal. - // - // LevelDB may held up to two 'memdb' at the same time. - // - // The default value is 4MiB. - WriteBuffer int - - // WriteL0StopTrigger defines number of 'sorted table' at level-0 that will - // pause write. - // - // The default value is 12. - WriteL0PauseTrigger int - - // WriteL0SlowdownTrigger defines number of 'sorted table' at level-0 that - // will trigger write slowdown. - // - // The default value is 8. - WriteL0SlowdownTrigger int -} - -func (o *Options) GetAltFilters() []filter.Filter { - if o == nil { - return nil - } - return o.AltFilters -} - -func (o *Options) GetBlockCacher() Cacher { - if o == nil || o.BlockCacher == nil { - return DefaultBlockCacher - } else if o.BlockCacher == NoCacher { - return nil - } - return o.BlockCacher -} - -func (o *Options) GetBlockCacheCapacity() int { - if o == nil || o.BlockCacheCapacity == 0 { - return DefaultBlockCacheCapacity - } else if o.BlockCacheCapacity < 0 { - return 0 - } - return o.BlockCacheCapacity -} - -func (o *Options) GetBlockRestartInterval() int { - if o == nil || o.BlockRestartInterval <= 0 { - return DefaultBlockRestartInterval - } - return o.BlockRestartInterval -} - -func (o *Options) GetBlockSize() int { - if o == nil || o.BlockSize <= 0 { - return DefaultBlockSize - } - return o.BlockSize -} - -func (o *Options) GetCompactionExpandLimit(level int) int { - factor := DefaultCompactionExpandLimitFactor - if o != nil && o.CompactionExpandLimitFactor > 0 { - factor = o.CompactionExpandLimitFactor - } - return o.GetCompactionTableSize(level+1) * factor -} - -func (o *Options) GetCompactionGPOverlaps(level int) int { - factor := DefaultCompactionGPOverlapsFactor - if o != nil && o.CompactionGPOverlapsFactor > 0 { - factor = o.CompactionGPOverlapsFactor - } - return o.GetCompactionTableSize(level+2) * factor -} - -func (o *Options) GetCompactionL0Trigger() int { - if o == nil || o.CompactionL0Trigger == 0 { - return DefaultCompactionL0Trigger - } - return o.CompactionL0Trigger -} - -func (o *Options) GetCompactionSourceLimit(level int) int { - factor := DefaultCompactionSourceLimitFactor - if o != nil && o.CompactionSourceLimitFactor > 0 { - factor = o.CompactionSourceLimitFactor - } - return o.GetCompactionTableSize(level+1) * factor -} - -func (o *Options) GetCompactionTableSize(level int) int { - var ( - base = DefaultCompactionTableSize - mult float64 - ) - if o != nil { - if o.CompactionTableSize > 0 { - base = o.CompactionTableSize - } - if level < len(o.CompactionTableSizeMultiplierPerLevel) && o.CompactionTableSizeMultiplierPerLevel[level] > 0 { - mult = o.CompactionTableSizeMultiplierPerLevel[level] - } else if o.CompactionTableSizeMultiplier > 0 { - mult = math.Pow(o.CompactionTableSizeMultiplier, float64(level)) - } - } - if mult == 0 { - mult = math.Pow(DefaultCompactionTableSizeMultiplier, float64(level)) - } - return int(float64(base) * mult) -} - -func (o *Options) GetCompactionTotalSize(level int) int64 { - var ( - base = DefaultCompactionTotalSize - mult float64 - ) - if o != nil { - if o.CompactionTotalSize > 0 { - base = o.CompactionTotalSize - } - if level < len(o.CompactionTotalSizeMultiplierPerLevel) && o.CompactionTotalSizeMultiplierPerLevel[level] > 0 { - mult = o.CompactionTotalSizeMultiplierPerLevel[level] - } else if o.CompactionTotalSizeMultiplier > 0 { - mult = math.Pow(o.CompactionTotalSizeMultiplier, float64(level)) - } - } - if mult == 0 { - mult = math.Pow(DefaultCompactionTotalSizeMultiplier, float64(level)) - } - return int64(float64(base) * mult) -} - -func (o *Options) GetComparer() comparer.Comparer { - if o == nil || o.Comparer == nil { - return comparer.DefaultComparer - } - return o.Comparer -} - -func (o *Options) GetCompression() Compression { - if o == nil || o.Compression <= DefaultCompression || o.Compression >= nCompression { - return DefaultCompressionType - } - return o.Compression -} - -func (o *Options) GetDisableBufferPool() bool { - if o == nil { - return false - } - return o.DisableBufferPool -} - -func (o *Options) GetDisableBlockCache() bool { - if o == nil { - return false - } - return o.DisableBlockCache -} - -func (o *Options) GetDisableCompactionBackoff() bool { - if o == nil { - return false - } - return o.DisableCompactionBackoff -} - -func (o *Options) GetDisableLargeBatchTransaction() bool { - if o == nil { - return false - } - return o.DisableLargeBatchTransaction -} - -func (o *Options) GetErrorIfExist() bool { - if o == nil { - return false - } - return o.ErrorIfExist -} - -func (o *Options) GetErrorIfMissing() bool { - if o == nil { - return false - } - return o.ErrorIfMissing -} - -func (o *Options) GetFilter() filter.Filter { - if o == nil { - return nil - } - return o.Filter -} - -func (o *Options) GetIteratorSamplingRate() int { - if o == nil || o.IteratorSamplingRate <= 0 { - return DefaultIteratorSamplingRate - } - return o.IteratorSamplingRate -} - -func (o *Options) GetNoSync() bool { - if o == nil { - return false - } - return o.NoSync -} - -func (o *Options) GetNoWriteMerge() bool { - if o == nil { - return false - } - return o.NoWriteMerge -} - -func (o *Options) GetOpenFilesCacher() Cacher { - if o == nil || o.OpenFilesCacher == nil { - return DefaultOpenFilesCacher - } - if o.OpenFilesCacher == NoCacher { - return nil - } - return o.OpenFilesCacher -} - -func (o *Options) GetOpenFilesCacheCapacity() int { - if o == nil || o.OpenFilesCacheCapacity == 0 { - return DefaultOpenFilesCacheCapacity - } else if o.OpenFilesCacheCapacity < 0 { - return 0 - } - return o.OpenFilesCacheCapacity -} - -func (o *Options) GetReadOnly() bool { - if o == nil { - return false - } - return o.ReadOnly -} - -func (o *Options) GetStrict(strict Strict) bool { - if o == nil || o.Strict == 0 { - return DefaultStrict&strict != 0 - } - return o.Strict&strict != 0 -} - -func (o *Options) GetWriteBuffer() int { - if o == nil || o.WriteBuffer <= 0 { - return DefaultWriteBuffer - } - return o.WriteBuffer -} - -func (o *Options) GetWriteL0PauseTrigger() int { - if o == nil || o.WriteL0PauseTrigger == 0 { - return DefaultWriteL0PauseTrigger - } - return o.WriteL0PauseTrigger -} - -func (o *Options) GetWriteL0SlowdownTrigger() int { - if o == nil || o.WriteL0SlowdownTrigger == 0 { - return DefaultWriteL0SlowdownTrigger - } - return o.WriteL0SlowdownTrigger -} - -// ReadOptions holds the optional parameters for 'read operation'. The -// 'read operation' includes Get, Find and NewIterator. -type ReadOptions struct { - // DontFillCache defines whether block reads for this 'read operation' - // should be cached. If false then the block will be cached. This does - // not affects already cached block. - // - // The default value is false. - DontFillCache bool - - // Strict will be OR'ed with global DB 'strict level' unless StrictOverride - // is present. Currently only StrictReader that has effect here. - Strict Strict -} - -func (ro *ReadOptions) GetDontFillCache() bool { - if ro == nil { - return false - } - return ro.DontFillCache -} - -func (ro *ReadOptions) GetStrict(strict Strict) bool { - if ro == nil { - return false - } - return ro.Strict&strict != 0 -} - -// WriteOptions holds the optional parameters for 'write operation'. The -// 'write operation' includes Write, Put and Delete. -type WriteOptions struct { - // NoWriteMerge allows disabling write merge. - // - // The default is false. - NoWriteMerge bool - - // Sync is whether to sync underlying writes from the OS buffer cache - // through to actual disk, if applicable. Setting Sync can result in - // slower writes. - // - // If false, and the machine crashes, then some recent writes may be lost. - // Note that if it is just the process that crashes (and the machine does - // not) then no writes will be lost. - // - // In other words, Sync being false has the same semantics as a write - // system call. Sync being true means write followed by fsync. - // - // The default value is false. - Sync bool -} - -func (wo *WriteOptions) GetNoWriteMerge() bool { - if wo == nil { - return false - } - return wo.NoWriteMerge -} - -func (wo *WriteOptions) GetSync() bool { - if wo == nil { - return false - } - return wo.Sync -} - -func GetStrict(o *Options, ro *ReadOptions, strict Strict) bool { - if ro.GetStrict(StrictOverride) { - return ro.GetStrict(strict) - } else { - return o.GetStrict(strict) || ro.GetStrict(strict) - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/options.go b/vendor/github.com/syndtr/goleveldb/leveldb/options.go deleted file mode 100644 index b072b1a..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/options.go +++ /dev/null @@ -1,107 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "github.com/syndtr/goleveldb/leveldb/filter" - "github.com/syndtr/goleveldb/leveldb/opt" -) - -func dupOptions(o *opt.Options) *opt.Options { - newo := &opt.Options{} - if o != nil { - *newo = *o - } - if newo.Strict == 0 { - newo.Strict = opt.DefaultStrict - } - return newo -} - -func (s *session) setOptions(o *opt.Options) { - no := dupOptions(o) - // Alternative filters. - if filters := o.GetAltFilters(); len(filters) > 0 { - no.AltFilters = make([]filter.Filter, len(filters)) - for i, filter := range filters { - no.AltFilters[i] = &iFilter{filter} - } - } - // Comparer. - s.icmp = &iComparer{o.GetComparer()} - no.Comparer = s.icmp - // Filter. - if filter := o.GetFilter(); filter != nil { - no.Filter = &iFilter{filter} - } - - s.o = &cachedOptions{Options: no} - s.o.cache() -} - -const optCachedLevel = 7 - -type cachedOptions struct { - *opt.Options - - compactionExpandLimit []int - compactionGPOverlaps []int - compactionSourceLimit []int - compactionTableSize []int - compactionTotalSize []int64 -} - -func (co *cachedOptions) cache() { - co.compactionExpandLimit = make([]int, optCachedLevel) - co.compactionGPOverlaps = make([]int, optCachedLevel) - co.compactionSourceLimit = make([]int, optCachedLevel) - co.compactionTableSize = make([]int, optCachedLevel) - co.compactionTotalSize = make([]int64, optCachedLevel) - - for level := 0; level < optCachedLevel; level++ { - co.compactionExpandLimit[level] = co.Options.GetCompactionExpandLimit(level) - co.compactionGPOverlaps[level] = co.Options.GetCompactionGPOverlaps(level) - co.compactionSourceLimit[level] = co.Options.GetCompactionSourceLimit(level) - co.compactionTableSize[level] = co.Options.GetCompactionTableSize(level) - co.compactionTotalSize[level] = co.Options.GetCompactionTotalSize(level) - } -} - -func (co *cachedOptions) GetCompactionExpandLimit(level int) int { - if level < optCachedLevel { - return co.compactionExpandLimit[level] - } - return co.Options.GetCompactionExpandLimit(level) -} - -func (co *cachedOptions) GetCompactionGPOverlaps(level int) int { - if level < optCachedLevel { - return co.compactionGPOverlaps[level] - } - return co.Options.GetCompactionGPOverlaps(level) -} - -func (co *cachedOptions) GetCompactionSourceLimit(level int) int { - if level < optCachedLevel { - return co.compactionSourceLimit[level] - } - return co.Options.GetCompactionSourceLimit(level) -} - -func (co *cachedOptions) GetCompactionTableSize(level int) int { - if level < optCachedLevel { - return co.compactionTableSize[level] - } - return co.Options.GetCompactionTableSize(level) -} - -func (co *cachedOptions) GetCompactionTotalSize(level int) int64 { - if level < optCachedLevel { - return co.compactionTotalSize[level] - } - return co.Options.GetCompactionTotalSize(level) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session.go b/vendor/github.com/syndtr/goleveldb/leveldb/session.go deleted file mode 100644 index ad68a87..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session.go +++ /dev/null @@ -1,210 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "fmt" - "io" - "os" - "sync" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/journal" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -// ErrManifestCorrupted records manifest corruption. This error will be -// wrapped with errors.ErrCorrupted. -type ErrManifestCorrupted struct { - Field string - Reason string -} - -func (e *ErrManifestCorrupted) Error() string { - return fmt.Sprintf("leveldb: manifest corrupted (field '%s'): %s", e.Field, e.Reason) -} - -func newErrManifestCorrupted(fd storage.FileDesc, field, reason string) error { - return errors.NewErrCorrupted(fd, &ErrManifestCorrupted{field, reason}) -} - -// session represent a persistent database session. -type session struct { - // Need 64-bit alignment. - stNextFileNum int64 // current unused file number - stJournalNum int64 // current journal file number; need external synchronization - stPrevJournalNum int64 // prev journal file number; no longer used; for compatibility with older version of leveldb - stTempFileNum int64 - stSeqNum uint64 // last mem compacted seq; need external synchronization - - stor storage.Storage - storLock storage.Locker - o *cachedOptions - icmp *iComparer - tops *tOps - fileRef map[int64]int - - manifest *journal.Writer - manifestWriter storage.Writer - manifestFd storage.FileDesc - - stCompPtrs []internalKey // compaction pointers; need external synchronization - stVersion *version // current version - vmu sync.Mutex -} - -// Creates new initialized session instance. -func newSession(stor storage.Storage, o *opt.Options) (s *session, err error) { - if stor == nil { - return nil, os.ErrInvalid - } - storLock, err := stor.Lock() - if err != nil { - return - } - s = &session{ - stor: stor, - storLock: storLock, - fileRef: make(map[int64]int), - } - s.setOptions(o) - s.tops = newTableOps(s) - s.setVersion(newVersion(s)) - s.log("log@legend F·NumFile S·FileSize N·Entry C·BadEntry B·BadBlock Ke·KeyError D·DroppedEntry L·Level Q·SeqNum T·TimeElapsed") - return -} - -// Close session. -func (s *session) close() { - s.tops.close() - if s.manifest != nil { - s.manifest.Close() - } - if s.manifestWriter != nil { - s.manifestWriter.Close() - } - s.manifest = nil - s.manifestWriter = nil - s.setVersion(&version{s: s, closing: true}) -} - -// Release session lock. -func (s *session) release() { - s.storLock.Unlock() -} - -// Create a new database session; need external synchronization. -func (s *session) create() error { - // create manifest - return s.newManifest(nil, nil) -} - -// Recover a database session; need external synchronization. -func (s *session) recover() (err error) { - defer func() { - if os.IsNotExist(err) { - // Don't return os.ErrNotExist if the underlying storage contains - // other files that belong to LevelDB. So the DB won't get trashed. - if fds, _ := s.stor.List(storage.TypeAll); len(fds) > 0 { - err = &errors.ErrCorrupted{Fd: storage.FileDesc{Type: storage.TypeManifest}, Err: &errors.ErrMissingFiles{}} - } - } - }() - - fd, err := s.stor.GetMeta() - if err != nil { - return - } - - reader, err := s.stor.Open(fd) - if err != nil { - return - } - defer reader.Close() - - var ( - // Options. - strict = s.o.GetStrict(opt.StrictManifest) - - jr = journal.NewReader(reader, dropper{s, fd}, strict, true) - rec = &sessionRecord{} - staging = s.stVersion.newStaging() - ) - for { - var r io.Reader - r, err = jr.Next() - if err != nil { - if err == io.EOF { - err = nil - break - } - return errors.SetFd(err, fd) - } - - err = rec.decode(r) - if err == nil { - // save compact pointers - for _, r := range rec.compPtrs { - s.setCompPtr(r.level, internalKey(r.ikey)) - } - // commit record to version staging - staging.commit(rec) - } else { - err = errors.SetFd(err, fd) - if strict || !errors.IsCorrupted(err) { - return - } - s.logf("manifest error: %v (skipped)", errors.SetFd(err, fd)) - } - rec.resetCompPtrs() - rec.resetAddedTables() - rec.resetDeletedTables() - } - - switch { - case !rec.has(recComparer): - return newErrManifestCorrupted(fd, "comparer", "missing") - case rec.comparer != s.icmp.uName(): - return newErrManifestCorrupted(fd, "comparer", fmt.Sprintf("mismatch: want '%s', got '%s'", s.icmp.uName(), rec.comparer)) - case !rec.has(recNextFileNum): - return newErrManifestCorrupted(fd, "next-file-num", "missing") - case !rec.has(recJournalNum): - return newErrManifestCorrupted(fd, "journal-file-num", "missing") - case !rec.has(recSeqNum): - return newErrManifestCorrupted(fd, "seq-num", "missing") - } - - s.manifestFd = fd - s.setVersion(staging.finish()) - s.setNextFileNum(rec.nextFileNum) - s.recordCommited(rec) - return nil -} - -// Commit session; need external synchronization. -func (s *session) commit(r *sessionRecord) (err error) { - v := s.version() - defer v.release() - - // spawn new version based on current version - nv := v.spawn(r) - - if s.manifest == nil { - // manifest journal writer not yet created, create one - err = s.newManifest(r, nv) - } else { - err = s.flushManifest(r) - } - - // finally, apply new version if no error rise - if err == nil { - s.setVersion(nv) - } - - return -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session_compaction.go b/vendor/github.com/syndtr/goleveldb/leveldb/session_compaction.go deleted file mode 100644 index 089cd00..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session_compaction.go +++ /dev/null @@ -1,302 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "sync/atomic" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/memdb" - "github.com/syndtr/goleveldb/leveldb/opt" -) - -func (s *session) pickMemdbLevel(umin, umax []byte, maxLevel int) int { - v := s.version() - defer v.release() - return v.pickMemdbLevel(umin, umax, maxLevel) -} - -func (s *session) flushMemdb(rec *sessionRecord, mdb *memdb.DB, maxLevel int) (int, error) { - // Create sorted table. - iter := mdb.NewIterator(nil) - defer iter.Release() - t, n, err := s.tops.createFrom(iter) - if err != nil { - return 0, err - } - - // Pick level other than zero can cause compaction issue with large - // bulk insert and delete on strictly incrementing key-space. The - // problem is that the small deletion markers trapped at lower level, - // while key/value entries keep growing at higher level. Since the - // key-space is strictly incrementing it will not overlaps with - // higher level, thus maximum possible level is always picked, while - // overlapping deletion marker pushed into lower level. - // See: https://github.com/syndtr/goleveldb/issues/127. - flushLevel := s.pickMemdbLevel(t.imin.ukey(), t.imax.ukey(), maxLevel) - rec.addTableFile(flushLevel, t) - - s.logf("memdb@flush created L%d@%d N·%d S·%s %q:%q", flushLevel, t.fd.Num, n, shortenb(int(t.size)), t.imin, t.imax) - return flushLevel, nil -} - -// Pick a compaction based on current state; need external synchronization. -func (s *session) pickCompaction() *compaction { - v := s.version() - - var sourceLevel int - var t0 tFiles - if v.cScore >= 1 { - sourceLevel = v.cLevel - cptr := s.getCompPtr(sourceLevel) - tables := v.levels[sourceLevel] - for _, t := range tables { - if cptr == nil || s.icmp.Compare(t.imax, cptr) > 0 { - t0 = append(t0, t) - break - } - } - if len(t0) == 0 { - t0 = append(t0, tables[0]) - } - } else { - if p := atomic.LoadPointer(&v.cSeek); p != nil { - ts := (*tSet)(p) - sourceLevel = ts.level - t0 = append(t0, ts.table) - } else { - v.release() - return nil - } - } - - return newCompaction(s, v, sourceLevel, t0) -} - -// Create compaction from given level and range; need external synchronization. -func (s *session) getCompactionRange(sourceLevel int, umin, umax []byte, noLimit bool) *compaction { - v := s.version() - - if sourceLevel >= len(v.levels) { - v.release() - return nil - } - - t0 := v.levels[sourceLevel].getOverlaps(nil, s.icmp, umin, umax, sourceLevel == 0) - if len(t0) == 0 { - v.release() - return nil - } - - // Avoid compacting too much in one shot in case the range is large. - // But we cannot do this for level-0 since level-0 files can overlap - // and we must not pick one file and drop another older file if the - // two files overlap. - if !noLimit && sourceLevel > 0 { - limit := int64(v.s.o.GetCompactionSourceLimit(sourceLevel)) - total := int64(0) - for i, t := range t0 { - total += t.size - if total >= limit { - s.logf("table@compaction limiting F·%d -> F·%d", len(t0), i+1) - t0 = t0[:i+1] - break - } - } - } - - return newCompaction(s, v, sourceLevel, t0) -} - -func newCompaction(s *session, v *version, sourceLevel int, t0 tFiles) *compaction { - c := &compaction{ - s: s, - v: v, - sourceLevel: sourceLevel, - levels: [2]tFiles{t0, nil}, - maxGPOverlaps: int64(s.o.GetCompactionGPOverlaps(sourceLevel)), - tPtrs: make([]int, len(v.levels)), - } - c.expand() - c.save() - return c -} - -// compaction represent a compaction state. -type compaction struct { - s *session - v *version - - sourceLevel int - levels [2]tFiles - maxGPOverlaps int64 - - gp tFiles - gpi int - seenKey bool - gpOverlappedBytes int64 - imin, imax internalKey - tPtrs []int - released bool - - snapGPI int - snapSeenKey bool - snapGPOverlappedBytes int64 - snapTPtrs []int -} - -func (c *compaction) save() { - c.snapGPI = c.gpi - c.snapSeenKey = c.seenKey - c.snapGPOverlappedBytes = c.gpOverlappedBytes - c.snapTPtrs = append(c.snapTPtrs[:0], c.tPtrs...) -} - -func (c *compaction) restore() { - c.gpi = c.snapGPI - c.seenKey = c.snapSeenKey - c.gpOverlappedBytes = c.snapGPOverlappedBytes - c.tPtrs = append(c.tPtrs[:0], c.snapTPtrs...) -} - -func (c *compaction) release() { - if !c.released { - c.released = true - c.v.release() - } -} - -// Expand compacted tables; need external synchronization. -func (c *compaction) expand() { - limit := int64(c.s.o.GetCompactionExpandLimit(c.sourceLevel)) - vt0 := c.v.levels[c.sourceLevel] - vt1 := tFiles{} - if level := c.sourceLevel + 1; level < len(c.v.levels) { - vt1 = c.v.levels[level] - } - - t0, t1 := c.levels[0], c.levels[1] - imin, imax := t0.getRange(c.s.icmp) - // We expand t0 here just incase ukey hop across tables. - t0 = vt0.getOverlaps(t0, c.s.icmp, imin.ukey(), imax.ukey(), c.sourceLevel == 0) - if len(t0) != len(c.levels[0]) { - imin, imax = t0.getRange(c.s.icmp) - } - t1 = vt1.getOverlaps(t1, c.s.icmp, imin.ukey(), imax.ukey(), false) - // Get entire range covered by compaction. - amin, amax := append(t0, t1...).getRange(c.s.icmp) - - // See if we can grow the number of inputs in "sourceLevel" without - // changing the number of "sourceLevel+1" files we pick up. - if len(t1) > 0 { - exp0 := vt0.getOverlaps(nil, c.s.icmp, amin.ukey(), amax.ukey(), c.sourceLevel == 0) - if len(exp0) > len(t0) && t1.size()+exp0.size() < limit { - xmin, xmax := exp0.getRange(c.s.icmp) - exp1 := vt1.getOverlaps(nil, c.s.icmp, xmin.ukey(), xmax.ukey(), false) - if len(exp1) == len(t1) { - c.s.logf("table@compaction expanding L%d+L%d (F·%d S·%s)+(F·%d S·%s) -> (F·%d S·%s)+(F·%d S·%s)", - c.sourceLevel, c.sourceLevel+1, len(t0), shortenb(int(t0.size())), len(t1), shortenb(int(t1.size())), - len(exp0), shortenb(int(exp0.size())), len(exp1), shortenb(int(exp1.size()))) - imin, imax = xmin, xmax - t0, t1 = exp0, exp1 - amin, amax = append(t0, t1...).getRange(c.s.icmp) - } - } - } - - // Compute the set of grandparent files that overlap this compaction - // (parent == sourceLevel+1; grandparent == sourceLevel+2) - if level := c.sourceLevel + 2; level < len(c.v.levels) { - c.gp = c.v.levels[level].getOverlaps(c.gp, c.s.icmp, amin.ukey(), amax.ukey(), false) - } - - c.levels[0], c.levels[1] = t0, t1 - c.imin, c.imax = imin, imax -} - -// Check whether compaction is trivial. -func (c *compaction) trivial() bool { - return len(c.levels[0]) == 1 && len(c.levels[1]) == 0 && c.gp.size() <= c.maxGPOverlaps -} - -func (c *compaction) baseLevelForKey(ukey []byte) bool { - for level := c.sourceLevel + 2; level < len(c.v.levels); level++ { - tables := c.v.levels[level] - for c.tPtrs[level] < len(tables) { - t := tables[c.tPtrs[level]] - if c.s.icmp.uCompare(ukey, t.imax.ukey()) <= 0 { - // We've advanced far enough. - if c.s.icmp.uCompare(ukey, t.imin.ukey()) >= 0 { - // Key falls in this file's range, so definitely not base level. - return false - } - break - } - c.tPtrs[level]++ - } - } - return true -} - -func (c *compaction) shouldStopBefore(ikey internalKey) bool { - for ; c.gpi < len(c.gp); c.gpi++ { - gp := c.gp[c.gpi] - if c.s.icmp.Compare(ikey, gp.imax) <= 0 { - break - } - if c.seenKey { - c.gpOverlappedBytes += gp.size - } - } - c.seenKey = true - - if c.gpOverlappedBytes > c.maxGPOverlaps { - // Too much overlap for current output; start new output. - c.gpOverlappedBytes = 0 - return true - } - return false -} - -// Creates an iterator. -func (c *compaction) newIterator() iterator.Iterator { - // Creates iterator slice. - icap := len(c.levels) - if c.sourceLevel == 0 { - // Special case for level-0. - icap = len(c.levels[0]) + 1 - } - its := make([]iterator.Iterator, 0, icap) - - // Options. - ro := &opt.ReadOptions{ - DontFillCache: true, - Strict: opt.StrictOverride, - } - strict := c.s.o.GetStrict(opt.StrictCompaction) - if strict { - ro.Strict |= opt.StrictReader - } - - for i, tables := range c.levels { - if len(tables) == 0 { - continue - } - - // Level-0 is not sorted and may overlaps each other. - if c.sourceLevel+i == 0 { - for _, t := range tables { - its = append(its, c.s.tops.newIterator(t, nil, ro)) - } - } else { - it := iterator.NewIndexedIterator(tables.newIndexIterator(c.s.tops, c.s.icmp, nil, ro), strict) - its = append(its, it) - } - } - - return iterator.NewMergedIterator(its, c.s.icmp, strict) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session_record.go b/vendor/github.com/syndtr/goleveldb/leveldb/session_record.go deleted file mode 100644 index 854e1aa..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session_record.go +++ /dev/null @@ -1,323 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "bufio" - "encoding/binary" - "io" - "strings" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -type byteReader interface { - io.Reader - io.ByteReader -} - -// These numbers are written to disk and should not be changed. -const ( - recComparer = 1 - recJournalNum = 2 - recNextFileNum = 3 - recSeqNum = 4 - recCompPtr = 5 - recDelTable = 6 - recAddTable = 7 - // 8 was used for large value refs - recPrevJournalNum = 9 -) - -type cpRecord struct { - level int - ikey internalKey -} - -type atRecord struct { - level int - num int64 - size int64 - imin internalKey - imax internalKey -} - -type dtRecord struct { - level int - num int64 -} - -type sessionRecord struct { - hasRec int - comparer string - journalNum int64 - prevJournalNum int64 - nextFileNum int64 - seqNum uint64 - compPtrs []cpRecord - addedTables []atRecord - deletedTables []dtRecord - - scratch [binary.MaxVarintLen64]byte - err error -} - -func (p *sessionRecord) has(rec int) bool { - return p.hasRec&(1< -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "bytes" - "testing" -) - -func decodeEncode(v *sessionRecord) (res bool, err error) { - b := new(bytes.Buffer) - err = v.encode(b) - if err != nil { - return - } - v2 := &sessionRecord{} - err = v.decode(b) - if err != nil { - return - } - b2 := new(bytes.Buffer) - err = v2.encode(b2) - if err != nil { - return - } - return bytes.Equal(b.Bytes(), b2.Bytes()), nil -} - -func TestSessionRecord_EncodeDecode(t *testing.T) { - big := int64(1) << 50 - v := &sessionRecord{} - i := int64(0) - test := func() { - res, err := decodeEncode(v) - if err != nil { - t.Fatalf("error when testing encode/decode sessionRecord: %v", err) - } - if !res { - t.Error("encode/decode test failed at iteration:", i) - } - } - - for ; i < 4; i++ { - test() - v.addTable(3, big+300+i, big+400+i, - makeInternalKey(nil, []byte("foo"), uint64(big+500+1), keyTypeVal), - makeInternalKey(nil, []byte("zoo"), uint64(big+600+1), keyTypeDel)) - v.delTable(4, big+700+i) - v.addCompPtr(int(i), makeInternalKey(nil, []byte("x"), uint64(big+900+1), keyTypeVal)) - } - - v.setComparer("foo") - v.setJournalNum(big + 100) - v.setPrevJournalNum(big + 99) - v.setNextFileNum(big + 200) - v.setSeqNum(uint64(big + 1000)) - test() -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/session_util.go b/vendor/github.com/syndtr/goleveldb/leveldb/session_util.go deleted file mode 100644 index 9232893..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/session_util.go +++ /dev/null @@ -1,271 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "fmt" - "sync/atomic" - - "github.com/syndtr/goleveldb/leveldb/journal" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -// Logging. - -type dropper struct { - s *session - fd storage.FileDesc -} - -func (d dropper) Drop(err error) { - if e, ok := err.(*journal.ErrCorrupted); ok { - d.s.logf("journal@drop %s-%d S·%s %q", d.fd.Type, d.fd.Num, shortenb(e.Size), e.Reason) - } else { - d.s.logf("journal@drop %s-%d %q", d.fd.Type, d.fd.Num, err) - } -} - -func (s *session) log(v ...interface{}) { s.stor.Log(fmt.Sprint(v...)) } -func (s *session) logf(format string, v ...interface{}) { s.stor.Log(fmt.Sprintf(format, v...)) } - -// File utils. - -func (s *session) newTemp() storage.FileDesc { - num := atomic.AddInt64(&s.stTempFileNum, 1) - 1 - return storage.FileDesc{storage.TypeTemp, num} -} - -func (s *session) addFileRef(fd storage.FileDesc, ref int) int { - ref += s.fileRef[fd.Num] - if ref > 0 { - s.fileRef[fd.Num] = ref - } else if ref == 0 { - delete(s.fileRef, fd.Num) - } else { - panic(fmt.Sprintf("negative ref: %v", fd)) - } - return ref -} - -// Session state. - -// Get current version. This will incr version ref, must call -// version.release (exactly once) after use. -func (s *session) version() *version { - s.vmu.Lock() - defer s.vmu.Unlock() - s.stVersion.incref() - return s.stVersion -} - -func (s *session) tLen(level int) int { - s.vmu.Lock() - defer s.vmu.Unlock() - return s.stVersion.tLen(level) -} - -// Set current version to v. -func (s *session) setVersion(v *version) { - s.vmu.Lock() - defer s.vmu.Unlock() - // Hold by session. It is important to call this first before releasing - // current version, otherwise the still used files might get released. - v.incref() - if s.stVersion != nil { - // Release current version. - s.stVersion.releaseNB() - } - s.stVersion = v -} - -// Get current unused file number. -func (s *session) nextFileNum() int64 { - return atomic.LoadInt64(&s.stNextFileNum) -} - -// Set current unused file number to num. -func (s *session) setNextFileNum(num int64) { - atomic.StoreInt64(&s.stNextFileNum, num) -} - -// Mark file number as used. -func (s *session) markFileNum(num int64) { - nextFileNum := num + 1 - for { - old, x := s.stNextFileNum, nextFileNum - if old > x { - x = old - } - if atomic.CompareAndSwapInt64(&s.stNextFileNum, old, x) { - break - } - } -} - -// Allocate a file number. -func (s *session) allocFileNum() int64 { - return atomic.AddInt64(&s.stNextFileNum, 1) - 1 -} - -// Reuse given file number. -func (s *session) reuseFileNum(num int64) { - for { - old, x := s.stNextFileNum, num - if old != x+1 { - x = old - } - if atomic.CompareAndSwapInt64(&s.stNextFileNum, old, x) { - break - } - } -} - -// Set compaction ptr at given level; need external synchronization. -func (s *session) setCompPtr(level int, ik internalKey) { - if level >= len(s.stCompPtrs) { - newCompPtrs := make([]internalKey, level+1) - copy(newCompPtrs, s.stCompPtrs) - s.stCompPtrs = newCompPtrs - } - s.stCompPtrs[level] = append(internalKey{}, ik...) -} - -// Get compaction ptr at given level; need external synchronization. -func (s *session) getCompPtr(level int) internalKey { - if level >= len(s.stCompPtrs) { - return nil - } - return s.stCompPtrs[level] -} - -// Manifest related utils. - -// Fill given session record obj with current states; need external -// synchronization. -func (s *session) fillRecord(r *sessionRecord, snapshot bool) { - r.setNextFileNum(s.nextFileNum()) - - if snapshot { - if !r.has(recJournalNum) { - r.setJournalNum(s.stJournalNum) - } - - if !r.has(recSeqNum) { - r.setSeqNum(s.stSeqNum) - } - - for level, ik := range s.stCompPtrs { - if ik != nil { - r.addCompPtr(level, ik) - } - } - - r.setComparer(s.icmp.uName()) - } -} - -// Mark if record has been committed, this will update session state; -// need external synchronization. -func (s *session) recordCommited(rec *sessionRecord) { - if rec.has(recJournalNum) { - s.stJournalNum = rec.journalNum - } - - if rec.has(recPrevJournalNum) { - s.stPrevJournalNum = rec.prevJournalNum - } - - if rec.has(recSeqNum) { - s.stSeqNum = rec.seqNum - } - - for _, r := range rec.compPtrs { - s.setCompPtr(r.level, internalKey(r.ikey)) - } -} - -// Create a new manifest file; need external synchronization. -func (s *session) newManifest(rec *sessionRecord, v *version) (err error) { - fd := storage.FileDesc{storage.TypeManifest, s.allocFileNum()} - writer, err := s.stor.Create(fd) - if err != nil { - return - } - jw := journal.NewWriter(writer) - - if v == nil { - v = s.version() - defer v.release() - } - if rec == nil { - rec = &sessionRecord{} - } - s.fillRecord(rec, true) - v.fillRecord(rec) - - defer func() { - if err == nil { - s.recordCommited(rec) - if s.manifest != nil { - s.manifest.Close() - } - if s.manifestWriter != nil { - s.manifestWriter.Close() - } - if !s.manifestFd.Zero() { - s.stor.Remove(s.manifestFd) - } - s.manifestFd = fd - s.manifestWriter = writer - s.manifest = jw - } else { - writer.Close() - s.stor.Remove(fd) - s.reuseFileNum(fd.Num) - } - }() - - w, err := jw.Next() - if err != nil { - return - } - err = rec.encode(w) - if err != nil { - return - } - err = jw.Flush() - if err != nil { - return - } - err = s.stor.SetMeta(fd) - return -} - -// Flush record to disk. -func (s *session) flushManifest(rec *sessionRecord) (err error) { - s.fillRecord(rec, false) - w, err := s.manifest.Next() - if err != nil { - return - } - err = rec.encode(w) - if err != nil { - return - } - err = s.manifest.Flush() - if err != nil { - return - } - if !s.o.GetNoSync() { - err = s.manifestWriter.Sync() - if err != nil { - return - } - } - s.recordCommited(rec) - return -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go deleted file mode 100644 index 1189dec..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go +++ /dev/null @@ -1,599 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reservefs. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package storage - -import ( - "errors" - "fmt" - "io/ioutil" - "os" - "path/filepath" - "runtime" - "strconv" - "strings" - "sync" - "time" -) - -var ( - errFileOpen = errors.New("leveldb/storage: file still open") - errReadOnly = errors.New("leveldb/storage: storage is read-only") -) - -type fileLock interface { - release() error -} - -type fileStorageLock struct { - fs *fileStorage -} - -func (lock *fileStorageLock) Unlock() { - if lock.fs != nil { - lock.fs.mu.Lock() - defer lock.fs.mu.Unlock() - if lock.fs.slock == lock { - lock.fs.slock = nil - } - } -} - -const logSizeThreshold = 1024 * 1024 // 1 MiB - -// fileStorage is a file-system backed storage. -type fileStorage struct { - path string - readOnly bool - - mu sync.Mutex - flock fileLock - slock *fileStorageLock - logw *os.File - logSize int64 - buf []byte - // Opened file counter; if open < 0 means closed. - open int - day int -} - -// OpenFile returns a new filesytem-backed storage implementation with the given -// path. This also acquire a file lock, so any subsequent attempt to open the -// same path will fail. -// -// The storage must be closed after use, by calling Close method. -func OpenFile(path string, readOnly bool) (Storage, error) { - if fi, err := os.Stat(path); err == nil { - if !fi.IsDir() { - return nil, fmt.Errorf("leveldb/storage: open %s: not a directory", path) - } - } else if os.IsNotExist(err) && !readOnly { - if err := os.MkdirAll(path, 0755); err != nil { - return nil, err - } - } else { - return nil, err - } - - flock, err := newFileLock(filepath.Join(path, "LOCK"), readOnly) - if err != nil { - return nil, err - } - - defer func() { - if err != nil { - flock.release() - } - }() - - var ( - logw *os.File - logSize int64 - ) - if !readOnly { - logw, err = os.OpenFile(filepath.Join(path, "LOG"), os.O_WRONLY|os.O_CREATE, 0644) - if err != nil { - return nil, err - } - logSize, err = logw.Seek(0, os.SEEK_END) - if err != nil { - logw.Close() - return nil, err - } - } - - fs := &fileStorage{ - path: path, - readOnly: readOnly, - flock: flock, - logw: logw, - logSize: logSize, - } - runtime.SetFinalizer(fs, (*fileStorage).Close) - return fs, nil -} - -func (fs *fileStorage) Lock() (Locker, error) { - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return nil, ErrClosed - } - if fs.readOnly { - return &fileStorageLock{}, nil - } - if fs.slock != nil { - return nil, ErrLocked - } - fs.slock = &fileStorageLock{fs: fs} - return fs.slock, nil -} - -func itoa(buf []byte, i int, wid int) []byte { - u := uint(i) - if u == 0 && wid <= 1 { - return append(buf, '0') - } - - // Assemble decimal in reverse order. - var b [32]byte - bp := len(b) - for ; u > 0 || wid > 0; u /= 10 { - bp-- - wid-- - b[bp] = byte(u%10) + '0' - } - return append(buf, b[bp:]...) -} - -func (fs *fileStorage) printDay(t time.Time) { - if fs.day == t.Day() { - return - } - fs.day = t.Day() - fs.logw.Write([]byte("=============== " + t.Format("Jan 2, 2006 (MST)") + " ===============\n")) -} - -func (fs *fileStorage) doLog(t time.Time, str string) { - if fs.logSize > logSizeThreshold { - // Rotate log file. - fs.logw.Close() - fs.logw = nil - fs.logSize = 0 - rename(filepath.Join(fs.path, "LOG"), filepath.Join(fs.path, "LOG.old")) - } - if fs.logw == nil { - var err error - fs.logw, err = os.OpenFile(filepath.Join(fs.path, "LOG"), os.O_WRONLY|os.O_CREATE, 0644) - if err != nil { - return - } - // Force printDay on new log file. - fs.day = 0 - } - fs.printDay(t) - hour, min, sec := t.Clock() - msec := t.Nanosecond() / 1e3 - // time - fs.buf = itoa(fs.buf[:0], hour, 2) - fs.buf = append(fs.buf, ':') - fs.buf = itoa(fs.buf, min, 2) - fs.buf = append(fs.buf, ':') - fs.buf = itoa(fs.buf, sec, 2) - fs.buf = append(fs.buf, '.') - fs.buf = itoa(fs.buf, msec, 6) - fs.buf = append(fs.buf, ' ') - // write - fs.buf = append(fs.buf, []byte(str)...) - fs.buf = append(fs.buf, '\n') - fs.logw.Write(fs.buf) -} - -func (fs *fileStorage) Log(str string) { - if !fs.readOnly { - t := time.Now() - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return - } - fs.doLog(t, str) - } -} - -func (fs *fileStorage) log(str string) { - if !fs.readOnly { - fs.doLog(time.Now(), str) - } -} - -func (fs *fileStorage) SetMeta(fd FileDesc) (err error) { - if !FileDescOk(fd) { - return ErrInvalidFile - } - if fs.readOnly { - return errReadOnly - } - - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return ErrClosed - } - defer func() { - if err != nil { - fs.log(fmt.Sprintf("CURRENT: %v", err)) - } - }() - path := fmt.Sprintf("%s.%d", filepath.Join(fs.path, "CURRENT"), fd.Num) - w, err := os.OpenFile(path, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644) - if err != nil { - return - } - _, err = fmt.Fprintln(w, fsGenName(fd)) - if err != nil { - fs.log(fmt.Sprintf("write CURRENT.%d: %v", fd.Num, err)) - return - } - if err = w.Sync(); err != nil { - fs.log(fmt.Sprintf("flush CURRENT.%d: %v", fd.Num, err)) - return - } - if err = w.Close(); err != nil { - fs.log(fmt.Sprintf("close CURRENT.%d: %v", fd.Num, err)) - return - } - if err != nil { - return - } - if err = rename(path, filepath.Join(fs.path, "CURRENT")); err != nil { - fs.log(fmt.Sprintf("rename CURRENT.%d: %v", fd.Num, err)) - return - } - // Sync root directory. - if err = syncDir(fs.path); err != nil { - fs.log(fmt.Sprintf("syncDir: %v", err)) - } - return -} - -func (fs *fileStorage) GetMeta() (fd FileDesc, err error) { - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return FileDesc{}, ErrClosed - } - dir, err := os.Open(fs.path) - if err != nil { - return - } - names, err := dir.Readdirnames(0) - // Close the dir first before checking for Readdirnames error. - if ce := dir.Close(); ce != nil { - fs.log(fmt.Sprintf("close dir: %v", ce)) - } - if err != nil { - return - } - // Find latest CURRENT file. - var rem []string - var pend bool - var cerr error - for _, name := range names { - if strings.HasPrefix(name, "CURRENT") { - pend1 := len(name) > 7 - var pendNum int64 - // Make sure it is valid name for a CURRENT file, otherwise skip it. - if pend1 { - if name[7] != '.' || len(name) < 9 { - fs.log(fmt.Sprintf("skipping %s: invalid file name", name)) - continue - } - var e1 error - if pendNum, e1 = strconv.ParseInt(name[8:], 10, 0); e1 != nil { - fs.log(fmt.Sprintf("skipping %s: invalid file num: %v", name, e1)) - continue - } - } - path := filepath.Join(fs.path, name) - r, e1 := os.OpenFile(path, os.O_RDONLY, 0) - if e1 != nil { - return FileDesc{}, e1 - } - b, e1 := ioutil.ReadAll(r) - if e1 != nil { - r.Close() - return FileDesc{}, e1 - } - var fd1 FileDesc - if len(b) < 1 || b[len(b)-1] != '\n' || !fsParseNamePtr(string(b[:len(b)-1]), &fd1) { - fs.log(fmt.Sprintf("skipping %s: corrupted or incomplete", name)) - if pend1 { - rem = append(rem, name) - } - if !pend1 || cerr == nil { - metaFd, _ := fsParseName(name) - cerr = &ErrCorrupted{ - Fd: metaFd, - Err: errors.New("leveldb/storage: corrupted or incomplete meta file"), - } - } - } else if pend1 && pendNum != fd1.Num { - fs.log(fmt.Sprintf("skipping %s: inconsistent pending-file num: %d vs %d", name, pendNum, fd1.Num)) - rem = append(rem, name) - } else if fd1.Num < fd.Num { - fs.log(fmt.Sprintf("skipping %s: obsolete", name)) - if pend1 { - rem = append(rem, name) - } - } else { - fd = fd1 - pend = pend1 - } - if err := r.Close(); err != nil { - fs.log(fmt.Sprintf("close %s: %v", name, err)) - } - } - } - // Don't remove any files if there is no valid CURRENT file. - if fd.Zero() { - if cerr != nil { - err = cerr - } else { - err = os.ErrNotExist - } - return - } - if !fs.readOnly { - // Rename pending CURRENT file to an effective CURRENT. - if pend { - path := fmt.Sprintf("%s.%d", filepath.Join(fs.path, "CURRENT"), fd.Num) - if err := rename(path, filepath.Join(fs.path, "CURRENT")); err != nil { - fs.log(fmt.Sprintf("CURRENT.%d -> CURRENT: %v", fd.Num, err)) - } - } - // Remove obsolete or incomplete pending CURRENT files. - for _, name := range rem { - path := filepath.Join(fs.path, name) - if err := os.Remove(path); err != nil { - fs.log(fmt.Sprintf("remove %s: %v", name, err)) - } - } - } - return -} - -func (fs *fileStorage) List(ft FileType) (fds []FileDesc, err error) { - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return nil, ErrClosed - } - dir, err := os.Open(fs.path) - if err != nil { - return - } - names, err := dir.Readdirnames(0) - // Close the dir first before checking for Readdirnames error. - if cerr := dir.Close(); cerr != nil { - fs.log(fmt.Sprintf("close dir: %v", cerr)) - } - if err == nil { - for _, name := range names { - if fd, ok := fsParseName(name); ok && fd.Type&ft != 0 { - fds = append(fds, fd) - } - } - } - return -} - -func (fs *fileStorage) Open(fd FileDesc) (Reader, error) { - if !FileDescOk(fd) { - return nil, ErrInvalidFile - } - - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return nil, ErrClosed - } - of, err := os.OpenFile(filepath.Join(fs.path, fsGenName(fd)), os.O_RDONLY, 0) - if err != nil { - if fsHasOldName(fd) && os.IsNotExist(err) { - of, err = os.OpenFile(filepath.Join(fs.path, fsGenOldName(fd)), os.O_RDONLY, 0) - if err == nil { - goto ok - } - } - return nil, err - } -ok: - fs.open++ - return &fileWrap{File: of, fs: fs, fd: fd}, nil -} - -func (fs *fileStorage) Create(fd FileDesc) (Writer, error) { - if !FileDescOk(fd) { - return nil, ErrInvalidFile - } - if fs.readOnly { - return nil, errReadOnly - } - - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return nil, ErrClosed - } - of, err := os.OpenFile(filepath.Join(fs.path, fsGenName(fd)), os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644) - if err != nil { - return nil, err - } - fs.open++ - return &fileWrap{File: of, fs: fs, fd: fd}, nil -} - -func (fs *fileStorage) Remove(fd FileDesc) error { - if !FileDescOk(fd) { - return ErrInvalidFile - } - if fs.readOnly { - return errReadOnly - } - - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return ErrClosed - } - err := os.Remove(filepath.Join(fs.path, fsGenName(fd))) - if err != nil { - if fsHasOldName(fd) && os.IsNotExist(err) { - if e1 := os.Remove(filepath.Join(fs.path, fsGenOldName(fd))); !os.IsNotExist(e1) { - fs.log(fmt.Sprintf("remove %s: %v (old name)", fd, err)) - err = e1 - } - } else { - fs.log(fmt.Sprintf("remove %s: %v", fd, err)) - } - } - return err -} - -func (fs *fileStorage) Rename(oldfd, newfd FileDesc) error { - if !FileDescOk(oldfd) || !FileDescOk(newfd) { - return ErrInvalidFile - } - if oldfd == newfd { - return nil - } - if fs.readOnly { - return errReadOnly - } - - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return ErrClosed - } - return rename(filepath.Join(fs.path, fsGenName(oldfd)), filepath.Join(fs.path, fsGenName(newfd))) -} - -func (fs *fileStorage) Close() error { - fs.mu.Lock() - defer fs.mu.Unlock() - if fs.open < 0 { - return ErrClosed - } - // Clear the finalizer. - runtime.SetFinalizer(fs, nil) - - if fs.open > 0 { - fs.log(fmt.Sprintf("close: warning, %d files still open", fs.open)) - } - fs.open = -1 - if fs.logw != nil { - fs.logw.Close() - } - return fs.flock.release() -} - -type fileWrap struct { - *os.File - fs *fileStorage - fd FileDesc - closed bool -} - -func (fw *fileWrap) Sync() error { - if err := fw.File.Sync(); err != nil { - return err - } - if fw.fd.Type == TypeManifest { - // Also sync parent directory if file type is manifest. - // See: https://code.google.com/p/leveldb/issues/detail?id=190. - if err := syncDir(fw.fs.path); err != nil { - fw.fs.log(fmt.Sprintf("syncDir: %v", err)) - return err - } - } - return nil -} - -func (fw *fileWrap) Close() error { - fw.fs.mu.Lock() - defer fw.fs.mu.Unlock() - if fw.closed { - return ErrClosed - } - fw.closed = true - fw.fs.open-- - err := fw.File.Close() - if err != nil { - fw.fs.log(fmt.Sprintf("close %s: %v", fw.fd, err)) - } - return err -} - -func fsGenName(fd FileDesc) string { - switch fd.Type { - case TypeManifest: - return fmt.Sprintf("MANIFEST-%06d", fd.Num) - case TypeJournal: - return fmt.Sprintf("%06d.log", fd.Num) - case TypeTable: - return fmt.Sprintf("%06d.ldb", fd.Num) - case TypeTemp: - return fmt.Sprintf("%06d.tmp", fd.Num) - default: - panic("invalid file type") - } -} - -func fsHasOldName(fd FileDesc) bool { - return fd.Type == TypeTable -} - -func fsGenOldName(fd FileDesc) string { - switch fd.Type { - case TypeTable: - return fmt.Sprintf("%06d.sst", fd.Num) - } - return fsGenName(fd) -} - -func fsParseName(name string) (fd FileDesc, ok bool) { - var tail string - _, err := fmt.Sscanf(name, "%d.%s", &fd.Num, &tail) - if err == nil { - switch tail { - case "log": - fd.Type = TypeJournal - case "ldb", "sst": - fd.Type = TypeTable - case "tmp": - fd.Type = TypeTemp - default: - return - } - return fd, true - } - n, _ := fmt.Sscanf(name, "MANIFEST-%d%s", &fd.Num, &tail) - if n == 1 { - fd.Type = TypeManifest - return fd, true - } - return -} - -func fsParseNamePtr(name string, fd *FileDesc) bool { - _fd, ok := fsParseName(name) - if fd != nil { - *fd = _fd - } - return ok -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_nacl.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_nacl.go deleted file mode 100644 index 5545aee..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_nacl.go +++ /dev/null @@ -1,34 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// +build nacl - -package storage - -import ( - "os" - "syscall" -) - -func newFileLock(path string, readOnly bool) (fl fileLock, err error) { - return nil, syscall.ENOTSUP -} - -func setFileLock(f *os.File, readOnly, lock bool) error { - return syscall.ENOTSUP -} - -func rename(oldpath, newpath string) error { - return syscall.ENOTSUP -} - -func isErrInvalid(err error) bool { - return false -} - -func syncDir(name string) error { - return syscall.ENOTSUP -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_plan9.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_plan9.go deleted file mode 100644 index bab62bf..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_plan9.go +++ /dev/null @@ -1,65 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package storage - -import ( - "os" - "path/filepath" -) - -type plan9FileLock struct { - f *os.File -} - -func (fl *plan9FileLock) release() error { - return fl.f.Close() -} - -func newFileLock(path string, readOnly bool) (fl fileLock, err error) { - var ( - flag int - perm os.FileMode - ) - if readOnly { - flag = os.O_RDONLY - } else { - flag = os.O_RDWR - perm = os.ModeExclusive - } - f, err := os.OpenFile(path, flag, perm) - if os.IsNotExist(err) { - f, err = os.OpenFile(path, flag|os.O_CREATE, perm|0644) - } - if err != nil { - return - } - fl = &plan9FileLock{f: f} - return -} - -func rename(oldpath, newpath string) error { - if _, err := os.Stat(newpath); err == nil { - if err := os.Remove(newpath); err != nil { - return err - } - } - - _, fname := filepath.Split(newpath) - return os.Rename(oldpath, fname) -} - -func syncDir(name string) error { - f, err := os.Open(name) - if err != nil { - return err - } - defer f.Close() - if err := f.Sync(); err != nil { - return err - } - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_solaris.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_solaris.go deleted file mode 100644 index 79901ee..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_solaris.go +++ /dev/null @@ -1,81 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// +build solaris - -package storage - -import ( - "os" - "syscall" -) - -type unixFileLock struct { - f *os.File -} - -func (fl *unixFileLock) release() error { - if err := setFileLock(fl.f, false, false); err != nil { - return err - } - return fl.f.Close() -} - -func newFileLock(path string, readOnly bool) (fl fileLock, err error) { - var flag int - if readOnly { - flag = os.O_RDONLY - } else { - flag = os.O_RDWR - } - f, err := os.OpenFile(path, flag, 0) - if os.IsNotExist(err) { - f, err = os.OpenFile(path, flag|os.O_CREATE, 0644) - } - if err != nil { - return - } - err = setFileLock(f, readOnly, true) - if err != nil { - f.Close() - return - } - fl = &unixFileLock{f: f} - return -} - -func setFileLock(f *os.File, readOnly, lock bool) error { - flock := syscall.Flock_t{ - Type: syscall.F_UNLCK, - Start: 0, - Len: 0, - Whence: 1, - } - if lock { - if readOnly { - flock.Type = syscall.F_RDLCK - } else { - flock.Type = syscall.F_WRLCK - } - } - return syscall.FcntlFlock(f.Fd(), syscall.F_SETLK, &flock) -} - -func rename(oldpath, newpath string) error { - return os.Rename(oldpath, newpath) -} - -func syncDir(name string) error { - f, err := os.Open(name) - if err != nil { - return err - } - defer f.Close() - if err := f.Sync(); err != nil { - return err - } - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_test.go deleted file mode 100644 index 28a59ec..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_test.go +++ /dev/null @@ -1,176 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package storage - -import ( - "fmt" - "os" - "path/filepath" - "testing" -) - -var cases = []struct { - oldName []string - name string - ftype FileType - num int64 -}{ - {nil, "000100.log", TypeJournal, 100}, - {nil, "000000.log", TypeJournal, 0}, - {[]string{"000000.sst"}, "000000.ldb", TypeTable, 0}, - {nil, "MANIFEST-000002", TypeManifest, 2}, - {nil, "MANIFEST-000007", TypeManifest, 7}, - {nil, "9223372036854775807.log", TypeJournal, 9223372036854775807}, - {nil, "000100.tmp", TypeTemp, 100}, -} - -var invalidCases = []string{ - "", - "foo", - "foo-dx-100.log", - ".log", - "", - "manifest", - "CURREN", - "CURRENTX", - "MANIFES", - "MANIFEST", - "MANIFEST-", - "XMANIFEST-3", - "MANIFEST-3x", - "LOC", - "LOCKx", - "LO", - "LOGx", - "18446744073709551616.log", - "184467440737095516150.log", - "100", - "100.", - "100.lop", -} - -func TestFileStorage_CreateFileName(t *testing.T) { - for _, c := range cases { - if name := fsGenName(FileDesc{c.ftype, c.num}); name != c.name { - t.Errorf("invalid filename got '%s', want '%s'", name, c.name) - } - } -} - -func TestFileStorage_ParseFileName(t *testing.T) { - for _, c := range cases { - for _, name := range append([]string{c.name}, c.oldName...) { - fd, ok := fsParseName(name) - if !ok { - t.Errorf("cannot parse filename '%s'", name) - continue - } - if fd.Type != c.ftype { - t.Errorf("filename '%s' invalid type got '%d', want '%d'", name, fd.Type, c.ftype) - } - if fd.Num != c.num { - t.Errorf("filename '%s' invalid number got '%d', want '%d'", name, fd.Num, c.num) - } - } - } -} - -func TestFileStorage_InvalidFileName(t *testing.T) { - for _, name := range invalidCases { - if fsParseNamePtr(name, nil) { - t.Errorf("filename '%s' should be invalid", name) - } - } -} - -func TestFileStorage_Locking(t *testing.T) { - path := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldb-testrwlock-%d", os.Getuid())) - if err := os.RemoveAll(path); err != nil && !os.IsNotExist(err) { - t.Fatal("RemoveAll: got error: ", err) - } - defer os.RemoveAll(path) - - p1, err := OpenFile(path, false) - if err != nil { - t.Fatal("OpenFile(1): got error: ", err) - } - - p2, err := OpenFile(path, false) - if err != nil { - t.Logf("OpenFile(2): got error: %s (expected)", err) - } else { - p2.Close() - p1.Close() - t.Fatal("OpenFile(2): expect error") - } - - p1.Close() - - p3, err := OpenFile(path, false) - if err != nil { - t.Fatal("OpenFile(3): got error: ", err) - } - defer p3.Close() - - l, err := p3.Lock() - if err != nil { - t.Fatal("storage lock failed(1): ", err) - } - _, err = p3.Lock() - if err == nil { - t.Fatal("expect error for second storage lock attempt") - } else { - t.Logf("storage lock got error: %s (expected)", err) - } - l.Unlock() - _, err = p3.Lock() - if err != nil { - t.Fatal("storage lock failed(2): ", err) - } -} - -func TestFileStorage_ReadOnlyLocking(t *testing.T) { - path := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldb-testrolock-%d", os.Getuid())) - if err := os.RemoveAll(path); err != nil && !os.IsNotExist(err) { - t.Fatal("RemoveAll: got error: ", err) - } - defer os.RemoveAll(path) - - p1, err := OpenFile(path, false) - if err != nil { - t.Fatal("OpenFile(1): got error: ", err) - } - - _, err = OpenFile(path, true) - if err != nil { - t.Logf("OpenFile(2): got error: %s (expected)", err) - } else { - t.Fatal("OpenFile(2): expect error") - } - - p1.Close() - - p3, err := OpenFile(path, true) - if err != nil { - t.Fatal("OpenFile(3): got error: ", err) - } - - p4, err := OpenFile(path, true) - if err != nil { - t.Fatal("OpenFile(4): got error: ", err) - } - - _, err = OpenFile(path, false) - if err != nil { - t.Logf("OpenFile(5): got error: %s (expected)", err) - } else { - t.Fatal("OpenFile(2): expect error") - } - - p3.Close() - p4.Close() -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go deleted file mode 100644 index 7e29915..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go +++ /dev/null @@ -1,86 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// +build darwin dragonfly freebsd linux netbsd openbsd - -package storage - -import ( - "os" - "syscall" -) - -type unixFileLock struct { - f *os.File -} - -func (fl *unixFileLock) release() error { - if err := setFileLock(fl.f, false, false); err != nil { - return err - } - return fl.f.Close() -} - -func newFileLock(path string, readOnly bool) (fl fileLock, err error) { - var flag int - if readOnly { - flag = os.O_RDONLY - } else { - flag = os.O_RDWR - } - f, err := os.OpenFile(path, flag, 0) - if os.IsNotExist(err) { - f, err = os.OpenFile(path, flag|os.O_CREATE, 0644) - } - if err != nil { - return - } - err = setFileLock(f, readOnly, true) - if err != nil { - f.Close() - return - } - fl = &unixFileLock{f: f} - return -} - -func setFileLock(f *os.File, readOnly, lock bool) error { - how := syscall.LOCK_UN - if lock { - if readOnly { - how = syscall.LOCK_SH - } else { - how = syscall.LOCK_EX - } - } - return syscall.Flock(int(f.Fd()), how|syscall.LOCK_NB) -} - -func rename(oldpath, newpath string) error { - return os.Rename(oldpath, newpath) -} - -func isErrInvalid(err error) bool { - if err == os.ErrInvalid { - return true - } - if syserr, ok := err.(*os.SyscallError); ok && syserr.Err == syscall.EINVAL { - return true - } - return false -} - -func syncDir(name string) error { - f, err := os.Open(name) - if err != nil { - return err - } - defer f.Close() - if err := f.Sync(); err != nil && !isErrInvalid(err) { - return err - } - return nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_windows.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_windows.go deleted file mode 100644 index 899335f..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/file_storage_windows.go +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright (c) 2013, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package storage - -import ( - "syscall" - "unsafe" -) - -var ( - modkernel32 = syscall.NewLazyDLL("kernel32.dll") - - procMoveFileExW = modkernel32.NewProc("MoveFileExW") -) - -const ( - _MOVEFILE_REPLACE_EXISTING = 1 -) - -type windowsFileLock struct { - fd syscall.Handle -} - -func (fl *windowsFileLock) release() error { - return syscall.Close(fl.fd) -} - -func newFileLock(path string, readOnly bool) (fl fileLock, err error) { - pathp, err := syscall.UTF16PtrFromString(path) - if err != nil { - return - } - var access, shareMode uint32 - if readOnly { - access = syscall.GENERIC_READ - shareMode = syscall.FILE_SHARE_READ - } else { - access = syscall.GENERIC_READ | syscall.GENERIC_WRITE - } - fd, err := syscall.CreateFile(pathp, access, shareMode, nil, syscall.OPEN_EXISTING, syscall.FILE_ATTRIBUTE_NORMAL, 0) - if err == syscall.ERROR_FILE_NOT_FOUND { - fd, err = syscall.CreateFile(pathp, access, shareMode, nil, syscall.OPEN_ALWAYS, syscall.FILE_ATTRIBUTE_NORMAL, 0) - } - if err != nil { - return - } - fl = &windowsFileLock{fd: fd} - return -} - -func moveFileEx(from *uint16, to *uint16, flags uint32) error { - r1, _, e1 := syscall.Syscall(procMoveFileExW.Addr(), 3, uintptr(unsafe.Pointer(from)), uintptr(unsafe.Pointer(to)), uintptr(flags)) - if r1 == 0 { - if e1 != 0 { - return error(e1) - } - return syscall.EINVAL - } - return nil -} - -func rename(oldpath, newpath string) error { - from, err := syscall.UTF16PtrFromString(oldpath) - if err != nil { - return err - } - to, err := syscall.UTF16PtrFromString(newpath) - if err != nil { - return err - } - return moveFileEx(from, to, _MOVEFILE_REPLACE_EXISTING) -} - -func syncDir(name string) error { return nil } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go deleted file mode 100644 index 9b0421f..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go +++ /dev/null @@ -1,218 +0,0 @@ -// Copyright (c) 2013, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package storage - -import ( - "bytes" - "os" - "sync" -) - -const typeShift = 3 - -type memStorageLock struct { - ms *memStorage -} - -func (lock *memStorageLock) Unlock() { - ms := lock.ms - ms.mu.Lock() - defer ms.mu.Unlock() - if ms.slock == lock { - ms.slock = nil - } - return -} - -// memStorage is a memory-backed storage. -type memStorage struct { - mu sync.Mutex - slock *memStorageLock - files map[uint64]*memFile - meta FileDesc -} - -// NewMemStorage returns a new memory-backed storage implementation. -func NewMemStorage() Storage { - return &memStorage{ - files: make(map[uint64]*memFile), - } -} - -func (ms *memStorage) Lock() (Locker, error) { - ms.mu.Lock() - defer ms.mu.Unlock() - if ms.slock != nil { - return nil, ErrLocked - } - ms.slock = &memStorageLock{ms: ms} - return ms.slock, nil -} - -func (*memStorage) Log(str string) {} - -func (ms *memStorage) SetMeta(fd FileDesc) error { - if !FileDescOk(fd) { - return ErrInvalidFile - } - - ms.mu.Lock() - ms.meta = fd - ms.mu.Unlock() - return nil -} - -func (ms *memStorage) GetMeta() (FileDesc, error) { - ms.mu.Lock() - defer ms.mu.Unlock() - if ms.meta.Zero() { - return FileDesc{}, os.ErrNotExist - } - return ms.meta, nil -} - -func (ms *memStorage) List(ft FileType) ([]FileDesc, error) { - ms.mu.Lock() - var fds []FileDesc - for x := range ms.files { - fd := unpackFile(x) - if fd.Type&ft != 0 { - fds = append(fds, fd) - } - } - ms.mu.Unlock() - return fds, nil -} - -func (ms *memStorage) Open(fd FileDesc) (Reader, error) { - if !FileDescOk(fd) { - return nil, ErrInvalidFile - } - - ms.mu.Lock() - defer ms.mu.Unlock() - if m, exist := ms.files[packFile(fd)]; exist { - if m.open { - return nil, errFileOpen - } - m.open = true - return &memReader{Reader: bytes.NewReader(m.Bytes()), ms: ms, m: m}, nil - } - return nil, os.ErrNotExist -} - -func (ms *memStorage) Create(fd FileDesc) (Writer, error) { - if !FileDescOk(fd) { - return nil, ErrInvalidFile - } - - x := packFile(fd) - ms.mu.Lock() - defer ms.mu.Unlock() - m, exist := ms.files[x] - if exist { - if m.open { - return nil, errFileOpen - } - m.Reset() - } else { - m = &memFile{} - ms.files[x] = m - } - m.open = true - return &memWriter{memFile: m, ms: ms}, nil -} - -func (ms *memStorage) Remove(fd FileDesc) error { - if !FileDescOk(fd) { - return ErrInvalidFile - } - - x := packFile(fd) - ms.mu.Lock() - defer ms.mu.Unlock() - if _, exist := ms.files[x]; exist { - delete(ms.files, x) - return nil - } - return os.ErrNotExist -} - -func (ms *memStorage) Rename(oldfd, newfd FileDesc) error { - if FileDescOk(oldfd) || FileDescOk(newfd) { - return ErrInvalidFile - } - if oldfd == newfd { - return nil - } - - oldx := packFile(oldfd) - newx := packFile(newfd) - ms.mu.Lock() - defer ms.mu.Unlock() - oldm, exist := ms.files[oldx] - if !exist { - return os.ErrNotExist - } - newm, exist := ms.files[newx] - if (exist && newm.open) || oldm.open { - return errFileOpen - } - delete(ms.files, oldx) - ms.files[newx] = oldm - return nil -} - -func (*memStorage) Close() error { return nil } - -type memFile struct { - bytes.Buffer - open bool -} - -type memReader struct { - *bytes.Reader - ms *memStorage - m *memFile - closed bool -} - -func (mr *memReader) Close() error { - mr.ms.mu.Lock() - defer mr.ms.mu.Unlock() - if mr.closed { - return ErrClosed - } - mr.m.open = false - return nil -} - -type memWriter struct { - *memFile - ms *memStorage - closed bool -} - -func (*memWriter) Sync() error { return nil } - -func (mw *memWriter) Close() error { - mw.ms.mu.Lock() - defer mw.ms.mu.Unlock() - if mw.closed { - return ErrClosed - } - mw.memFile.open = false - return nil -} - -func packFile(fd FileDesc) uint64 { - return uint64(fd.Num)<> typeShift)} -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage_test.go deleted file mode 100644 index fb03d30..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/mem_storage_test.go +++ /dev/null @@ -1,65 +0,0 @@ -// Copyright (c) 2013, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package storage - -import ( - "bytes" - "testing" -) - -func TestMemStorage(t *testing.T) { - m := NewMemStorage() - - l, err := m.Lock() - if err != nil { - t.Fatal("storage lock failed(1): ", err) - } - _, err = m.Lock() - if err == nil { - t.Fatal("expect error for second storage lock attempt") - } else { - t.Logf("storage lock got error: %s (expected)", err) - } - l.Unlock() - _, err = m.Lock() - if err != nil { - t.Fatal("storage lock failed(2): ", err) - } - - w, err := m.Create(FileDesc{TypeTable, 1}) - if err != nil { - t.Fatal("Storage.Create: ", err) - } - w.Write([]byte("abc")) - w.Close() - if fds, _ := m.List(TypeAll); len(fds) != 1 { - t.Fatal("invalid GetFiles len") - } - buf := new(bytes.Buffer) - r, err := m.Open(FileDesc{TypeTable, 1}) - if err != nil { - t.Fatal("Open: got error: ", err) - } - buf.ReadFrom(r) - r.Close() - if got := buf.String(); got != "abc" { - t.Fatalf("Read: invalid value, want=abc got=%s", got) - } - if _, err := m.Open(FileDesc{TypeTable, 1}); err != nil { - t.Fatal("Open: got error: ", err) - } - if _, err := m.Open(FileDesc{TypeTable, 1}); err == nil { - t.Fatal("expecting error") - } - m.Remove(FileDesc{TypeTable, 1}) - if fds, _ := m.List(TypeAll); len(fds) != 0 { - t.Fatal("invalid GetFiles len", len(fds)) - } - if _, err := m.Open(FileDesc{TypeTable, 1}); err == nil { - t.Fatal("expecting error") - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/storage/storage.go b/vendor/github.com/syndtr/goleveldb/leveldb/storage/storage.go deleted file mode 100644 index c16bce6..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/storage/storage.go +++ /dev/null @@ -1,179 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package storage provides storage abstraction for LevelDB. -package storage - -import ( - "errors" - "fmt" - "io" -) - -// FileType represent a file type. -type FileType int - -// File types. -const ( - TypeManifest FileType = 1 << iota - TypeJournal - TypeTable - TypeTemp - - TypeAll = TypeManifest | TypeJournal | TypeTable | TypeTemp -) - -func (t FileType) String() string { - switch t { - case TypeManifest: - return "manifest" - case TypeJournal: - return "journal" - case TypeTable: - return "table" - case TypeTemp: - return "temp" - } - return fmt.Sprintf("", t) -} - -// Common error. -var ( - ErrInvalidFile = errors.New("leveldb/storage: invalid file for argument") - ErrLocked = errors.New("leveldb/storage: already locked") - ErrClosed = errors.New("leveldb/storage: closed") -) - -// ErrCorrupted is the type that wraps errors that indicate corruption of -// a file. Package storage has its own type instead of using -// errors.ErrCorrupted to prevent circular import. -type ErrCorrupted struct { - Fd FileDesc - Err error -} - -func (e *ErrCorrupted) Error() string { - if !e.Fd.Zero() { - return fmt.Sprintf("%v [file=%v]", e.Err, e.Fd) - } - return e.Err.Error() -} - -// Syncer is the interface that wraps basic Sync method. -type Syncer interface { - // Sync commits the current contents of the file to stable storage. - Sync() error -} - -// Reader is the interface that groups the basic Read, Seek, ReadAt and Close -// methods. -type Reader interface { - io.ReadSeeker - io.ReaderAt - io.Closer -} - -// Writer is the interface that groups the basic Write, Sync and Close -// methods. -type Writer interface { - io.WriteCloser - Syncer -} - -// Locker is the interface that wraps Unlock method. -type Locker interface { - Unlock() -} - -// FileDesc is a 'file descriptor'. -type FileDesc struct { - Type FileType - Num int64 -} - -func (fd FileDesc) String() string { - switch fd.Type { - case TypeManifest: - return fmt.Sprintf("MANIFEST-%06d", fd.Num) - case TypeJournal: - return fmt.Sprintf("%06d.log", fd.Num) - case TypeTable: - return fmt.Sprintf("%06d.ldb", fd.Num) - case TypeTemp: - return fmt.Sprintf("%06d.tmp", fd.Num) - default: - return fmt.Sprintf("%#x-%d", fd.Type, fd.Num) - } -} - -// Zero returns true if fd == (FileDesc{}). -func (fd FileDesc) Zero() bool { - return fd == (FileDesc{}) -} - -// FileDescOk returns true if fd is a valid 'file descriptor'. -func FileDescOk(fd FileDesc) bool { - switch fd.Type { - case TypeManifest: - case TypeJournal: - case TypeTable: - case TypeTemp: - default: - return false - } - return fd.Num >= 0 -} - -// Storage is the storage. A storage instance must be safe for concurrent use. -type Storage interface { - // Lock locks the storage. Any subsequent attempt to call Lock will fail - // until the last lock released. - // Caller should call Unlock method after use. - Lock() (Locker, error) - - // Log logs a string. This is used for logging. - // An implementation may write to a file, stdout or simply do nothing. - Log(str string) - - // SetMeta store 'file descriptor' that can later be acquired using GetMeta - // method. The 'file descriptor' should point to a valid file. - // SetMeta should be implemented in such way that changes should happen - // atomically. - SetMeta(fd FileDesc) error - - // GetMeta returns 'file descriptor' stored in meta. The 'file descriptor' - // can be updated using SetMeta method. - // Returns os.ErrNotExist if meta doesn't store any 'file descriptor', or - // 'file descriptor' point to nonexistent file. - GetMeta() (FileDesc, error) - - // List returns file descriptors that match the given file types. - // The file types may be OR'ed together. - List(ft FileType) ([]FileDesc, error) - - // Open opens file with the given 'file descriptor' read-only. - // Returns os.ErrNotExist error if the file does not exist. - // Returns ErrClosed if the underlying storage is closed. - Open(fd FileDesc) (Reader, error) - - // Create creates file with the given 'file descriptor', truncate if already - // exist and opens write-only. - // Returns ErrClosed if the underlying storage is closed. - Create(fd FileDesc) (Writer, error) - - // Remove removes file with the given 'file descriptor'. - // Returns ErrClosed if the underlying storage is closed. - Remove(fd FileDesc) error - - // Rename renames file from oldfd to newfd. - // Returns ErrClosed if the underlying storage is closed. - Rename(oldfd, newfd FileDesc) error - - // Close closes the storage. - // It is valid to call Close multiple times. Other methods should not be - // called after the storage has been closed. - Close() error -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table.go b/vendor/github.com/syndtr/goleveldb/leveldb/table.go deleted file mode 100644 index 81d18a5..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table.go +++ /dev/null @@ -1,529 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "fmt" - "sort" - "sync/atomic" - - "github.com/syndtr/goleveldb/leveldb/cache" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/table" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// tFile holds basic information about a table. -type tFile struct { - fd storage.FileDesc - seekLeft int32 - size int64 - imin, imax internalKey -} - -// Returns true if given key is after largest key of this table. -func (t *tFile) after(icmp *iComparer, ukey []byte) bool { - return ukey != nil && icmp.uCompare(ukey, t.imax.ukey()) > 0 -} - -// Returns true if given key is before smallest key of this table. -func (t *tFile) before(icmp *iComparer, ukey []byte) bool { - return ukey != nil && icmp.uCompare(ukey, t.imin.ukey()) < 0 -} - -// Returns true if given key range overlaps with this table key range. -func (t *tFile) overlaps(icmp *iComparer, umin, umax []byte) bool { - return !t.after(icmp, umin) && !t.before(icmp, umax) -} - -// Cosumes one seek and return current seeks left. -func (t *tFile) consumeSeek() int32 { - return atomic.AddInt32(&t.seekLeft, -1) -} - -// Creates new tFile. -func newTableFile(fd storage.FileDesc, size int64, imin, imax internalKey) *tFile { - f := &tFile{ - fd: fd, - size: size, - imin: imin, - imax: imax, - } - - // We arrange to automatically compact this file after - // a certain number of seeks. Let's assume: - // (1) One seek costs 10ms - // (2) Writing or reading 1MB costs 10ms (100MB/s) - // (3) A compaction of 1MB does 25MB of IO: - // 1MB read from this level - // 10-12MB read from next level (boundaries may be misaligned) - // 10-12MB written to next level - // This implies that 25 seeks cost the same as the compaction - // of 1MB of data. I.e., one seek costs approximately the - // same as the compaction of 40KB of data. We are a little - // conservative and allow approximately one seek for every 16KB - // of data before triggering a compaction. - f.seekLeft = int32(size / 16384) - if f.seekLeft < 100 { - f.seekLeft = 100 - } - - return f -} - -func tableFileFromRecord(r atRecord) *tFile { - return newTableFile(storage.FileDesc{storage.TypeTable, r.num}, r.size, r.imin, r.imax) -} - -// tFiles hold multiple tFile. -type tFiles []*tFile - -func (tf tFiles) Len() int { return len(tf) } -func (tf tFiles) Swap(i, j int) { tf[i], tf[j] = tf[j], tf[i] } - -func (tf tFiles) nums() string { - x := "[ " - for i, f := range tf { - if i != 0 { - x += ", " - } - x += fmt.Sprint(f.fd.Num) - } - x += " ]" - return x -} - -// Returns true if i smallest key is less than j. -// This used for sort by key in ascending order. -func (tf tFiles) lessByKey(icmp *iComparer, i, j int) bool { - a, b := tf[i], tf[j] - n := icmp.Compare(a.imin, b.imin) - if n == 0 { - return a.fd.Num < b.fd.Num - } - return n < 0 -} - -// Returns true if i file number is greater than j. -// This used for sort by file number in descending order. -func (tf tFiles) lessByNum(i, j int) bool { - return tf[i].fd.Num > tf[j].fd.Num -} - -// Sorts tables by key in ascending order. -func (tf tFiles) sortByKey(icmp *iComparer) { - sort.Sort(&tFilesSortByKey{tFiles: tf, icmp: icmp}) -} - -// Sorts tables by file number in descending order. -func (tf tFiles) sortByNum() { - sort.Sort(&tFilesSortByNum{tFiles: tf}) -} - -// Returns sum of all tables size. -func (tf tFiles) size() (sum int64) { - for _, t := range tf { - sum += t.size - } - return sum -} - -// Searches smallest index of tables whose its smallest -// key is after or equal with given key. -func (tf tFiles) searchMin(icmp *iComparer, ikey internalKey) int { - return sort.Search(len(tf), func(i int) bool { - return icmp.Compare(tf[i].imin, ikey) >= 0 - }) -} - -// Searches smallest index of tables whose its largest -// key is after or equal with given key. -func (tf tFiles) searchMax(icmp *iComparer, ikey internalKey) int { - return sort.Search(len(tf), func(i int) bool { - return icmp.Compare(tf[i].imax, ikey) >= 0 - }) -} - -// Returns true if given key range overlaps with one or more -// tables key range. If unsorted is true then binary search will not be used. -func (tf tFiles) overlaps(icmp *iComparer, umin, umax []byte, unsorted bool) bool { - if unsorted { - // Check against all files. - for _, t := range tf { - if t.overlaps(icmp, umin, umax) { - return true - } - } - return false - } - - i := 0 - if len(umin) > 0 { - // Find the earliest possible internal key for min. - i = tf.searchMax(icmp, makeInternalKey(nil, umin, keyMaxSeq, keyTypeSeek)) - } - if i >= len(tf) { - // Beginning of range is after all files, so no overlap. - return false - } - return !tf[i].before(icmp, umax) -} - -// Returns tables whose its key range overlaps with given key range. -// Range will be expanded if ukey found hop across tables. -// If overlapped is true then the search will be restarted if umax -// expanded. -// The dst content will be overwritten. -func (tf tFiles) getOverlaps(dst tFiles, icmp *iComparer, umin, umax []byte, overlapped bool) tFiles { - dst = dst[:0] - for i := 0; i < len(tf); { - t := tf[i] - if t.overlaps(icmp, umin, umax) { - if umin != nil && icmp.uCompare(t.imin.ukey(), umin) < 0 { - umin = t.imin.ukey() - dst = dst[:0] - i = 0 - continue - } else if umax != nil && icmp.uCompare(t.imax.ukey(), umax) > 0 { - umax = t.imax.ukey() - // Restart search if it is overlapped. - if overlapped { - dst = dst[:0] - i = 0 - continue - } - } - - dst = append(dst, t) - } - i++ - } - - return dst -} - -// Returns tables key range. -func (tf tFiles) getRange(icmp *iComparer) (imin, imax internalKey) { - for i, t := range tf { - if i == 0 { - imin, imax = t.imin, t.imax - continue - } - if icmp.Compare(t.imin, imin) < 0 { - imin = t.imin - } - if icmp.Compare(t.imax, imax) > 0 { - imax = t.imax - } - } - - return -} - -// Creates iterator index from tables. -func (tf tFiles) newIndexIterator(tops *tOps, icmp *iComparer, slice *util.Range, ro *opt.ReadOptions) iterator.IteratorIndexer { - if slice != nil { - var start, limit int - if slice.Start != nil { - start = tf.searchMax(icmp, internalKey(slice.Start)) - } - if slice.Limit != nil { - limit = tf.searchMin(icmp, internalKey(slice.Limit)) - } else { - limit = tf.Len() - } - tf = tf[start:limit] - } - return iterator.NewArrayIndexer(&tFilesArrayIndexer{ - tFiles: tf, - tops: tops, - icmp: icmp, - slice: slice, - ro: ro, - }) -} - -// Tables iterator index. -type tFilesArrayIndexer struct { - tFiles - tops *tOps - icmp *iComparer - slice *util.Range - ro *opt.ReadOptions -} - -func (a *tFilesArrayIndexer) Search(key []byte) int { - return a.searchMax(a.icmp, internalKey(key)) -} - -func (a *tFilesArrayIndexer) Get(i int) iterator.Iterator { - if i == 0 || i == a.Len()-1 { - return a.tops.newIterator(a.tFiles[i], a.slice, a.ro) - } - return a.tops.newIterator(a.tFiles[i], nil, a.ro) -} - -// Helper type for sortByKey. -type tFilesSortByKey struct { - tFiles - icmp *iComparer -} - -func (x *tFilesSortByKey) Less(i, j int) bool { - return x.lessByKey(x.icmp, i, j) -} - -// Helper type for sortByNum. -type tFilesSortByNum struct { - tFiles -} - -func (x *tFilesSortByNum) Less(i, j int) bool { - return x.lessByNum(i, j) -} - -// Table operations. -type tOps struct { - s *session - noSync bool - cache *cache.Cache - bcache *cache.Cache - bpool *util.BufferPool -} - -// Creates an empty table and returns table writer. -func (t *tOps) create() (*tWriter, error) { - fd := storage.FileDesc{storage.TypeTable, t.s.allocFileNum()} - fw, err := t.s.stor.Create(fd) - if err != nil { - return nil, err - } - return &tWriter{ - t: t, - fd: fd, - w: fw, - tw: table.NewWriter(fw, t.s.o.Options), - }, nil -} - -// Builds table from src iterator. -func (t *tOps) createFrom(src iterator.Iterator) (f *tFile, n int, err error) { - w, err := t.create() - if err != nil { - return - } - - defer func() { - if err != nil { - w.drop() - } - }() - - for src.Next() { - err = w.append(src.Key(), src.Value()) - if err != nil { - return - } - } - err = src.Error() - if err != nil { - return - } - - n = w.tw.EntriesLen() - f, err = w.finish() - return -} - -// Opens table. It returns a cache handle, which should -// be released after use. -func (t *tOps) open(f *tFile) (ch *cache.Handle, err error) { - ch = t.cache.Get(0, uint64(f.fd.Num), func() (size int, value cache.Value) { - var r storage.Reader - r, err = t.s.stor.Open(f.fd) - if err != nil { - return 0, nil - } - - var bcache *cache.NamespaceGetter - if t.bcache != nil { - bcache = &cache.NamespaceGetter{Cache: t.bcache, NS: uint64(f.fd.Num)} - } - - var tr *table.Reader - tr, err = table.NewReader(r, f.size, f.fd, bcache, t.bpool, t.s.o.Options) - if err != nil { - r.Close() - return 0, nil - } - return 1, tr - - }) - if ch == nil && err == nil { - err = ErrClosed - } - return -} - -// Finds key/value pair whose key is greater than or equal to the -// given key. -func (t *tOps) find(f *tFile, key []byte, ro *opt.ReadOptions) (rkey, rvalue []byte, err error) { - ch, err := t.open(f) - if err != nil { - return nil, nil, err - } - defer ch.Release() - return ch.Value().(*table.Reader).Find(key, true, ro) -} - -// Finds key that is greater than or equal to the given key. -func (t *tOps) findKey(f *tFile, key []byte, ro *opt.ReadOptions) (rkey []byte, err error) { - ch, err := t.open(f) - if err != nil { - return nil, err - } - defer ch.Release() - return ch.Value().(*table.Reader).FindKey(key, true, ro) -} - -// Returns approximate offset of the given key. -func (t *tOps) offsetOf(f *tFile, key []byte) (offset int64, err error) { - ch, err := t.open(f) - if err != nil { - return - } - defer ch.Release() - return ch.Value().(*table.Reader).OffsetOf(key) -} - -// Creates an iterator from the given table. -func (t *tOps) newIterator(f *tFile, slice *util.Range, ro *opt.ReadOptions) iterator.Iterator { - ch, err := t.open(f) - if err != nil { - return iterator.NewEmptyIterator(err) - } - iter := ch.Value().(*table.Reader).NewIterator(slice, ro) - iter.SetReleaser(ch) - return iter -} - -// Removes table from persistent storage. It waits until -// no one use the the table. -func (t *tOps) remove(f *tFile) { - t.cache.Delete(0, uint64(f.fd.Num), func() { - if err := t.s.stor.Remove(f.fd); err != nil { - t.s.logf("table@remove removing @%d %q", f.fd.Num, err) - } else { - t.s.logf("table@remove removed @%d", f.fd.Num) - } - if t.bcache != nil { - t.bcache.EvictNS(uint64(f.fd.Num)) - } - }) -} - -// Closes the table ops instance. It will close all tables, -// regadless still used or not. -func (t *tOps) close() { - t.bpool.Close() - t.cache.Close() - if t.bcache != nil { - t.bcache.CloseWeak() - } -} - -// Creates new initialized table ops instance. -func newTableOps(s *session) *tOps { - var ( - cacher cache.Cacher - bcache *cache.Cache - bpool *util.BufferPool - ) - if s.o.GetOpenFilesCacheCapacity() > 0 { - cacher = cache.NewLRU(s.o.GetOpenFilesCacheCapacity()) - } - if !s.o.GetDisableBlockCache() { - var bcacher cache.Cacher - if s.o.GetBlockCacheCapacity() > 0 { - bcacher = cache.NewLRU(s.o.GetBlockCacheCapacity()) - } - bcache = cache.NewCache(bcacher) - } - if !s.o.GetDisableBufferPool() { - bpool = util.NewBufferPool(s.o.GetBlockSize() + 5) - } - return &tOps{ - s: s, - noSync: s.o.GetNoSync(), - cache: cache.NewCache(cacher), - bcache: bcache, - bpool: bpool, - } -} - -// tWriter wraps the table writer. It keep track of file descriptor -// and added key range. -type tWriter struct { - t *tOps - - fd storage.FileDesc - w storage.Writer - tw *table.Writer - - first, last []byte -} - -// Append key/value pair to the table. -func (w *tWriter) append(key, value []byte) error { - if w.first == nil { - w.first = append([]byte{}, key...) - } - w.last = append(w.last[:0], key...) - return w.tw.Append(key, value) -} - -// Returns true if the table is empty. -func (w *tWriter) empty() bool { - return w.first == nil -} - -// Closes the storage.Writer. -func (w *tWriter) close() { - if w.w != nil { - w.w.Close() - w.w = nil - } -} - -// Finalizes the table and returns table file. -func (w *tWriter) finish() (f *tFile, err error) { - defer w.close() - err = w.tw.Close() - if err != nil { - return - } - if !w.t.noSync { - err = w.w.Sync() - if err != nil { - return - } - } - f = newTableFile(w.fd, int64(w.tw.BytesLen()), internalKey(w.first), internalKey(w.last)) - return -} - -// Drops the table. -func (w *tWriter) drop() { - w.close() - w.t.s.stor.Remove(w.fd) - w.t.s.reuseFileNum(w.fd.Num) - w.tw = nil - w.first = nil - w.last = nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/block_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/block_test.go deleted file mode 100644 index 00e6f9e..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/block_test.go +++ /dev/null @@ -1,139 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package table - -import ( - "encoding/binary" - "fmt" - - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/testutil" - "github.com/syndtr/goleveldb/leveldb/util" -) - -type blockTesting struct { - tr *Reader - b *block -} - -func (t *blockTesting) TestNewIterator(slice *util.Range) iterator.Iterator { - return t.tr.newBlockIter(t.b, nil, slice, false) -} - -var _ = testutil.Defer(func() { - Describe("Block", func() { - Build := func(kv *testutil.KeyValue, restartInterval int) *blockTesting { - // Building the block. - bw := &blockWriter{ - restartInterval: restartInterval, - scratch: make([]byte, 30), - } - kv.Iterate(func(i int, key, value []byte) { - bw.append(key, value) - }) - bw.finish() - - // Opening the block. - data := bw.buf.Bytes() - restartsLen := int(binary.LittleEndian.Uint32(data[len(data)-4:])) - return &blockTesting{ - tr: &Reader{cmp: comparer.DefaultComparer}, - b: &block{ - data: data, - restartsLen: restartsLen, - restartsOffset: len(data) - (restartsLen+1)*4, - }, - } - } - - Describe("read test", func() { - for restartInterval := 1; restartInterval <= 5; restartInterval++ { - Describe(fmt.Sprintf("with restart interval of %d", restartInterval), func() { - kv := &testutil.KeyValue{} - Text := func() string { - return fmt.Sprintf("and %d keys", kv.Len()) - } - - Test := func() { - // Make block. - br := Build(kv, restartInterval) - // Do testing. - testutil.KeyValueTesting(nil, kv.Clone(), br, nil, nil) - } - - Describe(Text(), Test) - - kv.PutString("", "empty") - Describe(Text(), Test) - - kv.PutString("a1", "foo") - Describe(Text(), Test) - - kv.PutString("a2", "v") - Describe(Text(), Test) - - kv.PutString("a3qqwrkks", "hello") - Describe(Text(), Test) - - kv.PutString("a4", "bar") - Describe(Text(), Test) - - kv.PutString("a5111111", "v5") - kv.PutString("a6", "") - kv.PutString("a7", "v7") - kv.PutString("a8", "vvvvvvvvvvvvvvvvvvvvvv8") - kv.PutString("b", "v9") - kv.PutString("c9", "v9") - kv.PutString("c91", "v9") - kv.PutString("d0", "v9") - Describe(Text(), Test) - }) - } - }) - - Describe("out-of-bound slice test", func() { - kv := &testutil.KeyValue{} - kv.PutString("k1", "v1") - kv.PutString("k2", "v2") - kv.PutString("k3abcdefgg", "v3") - kv.PutString("k4", "v4") - kv.PutString("k5", "v5") - for restartInterval := 1; restartInterval <= 5; restartInterval++ { - Describe(fmt.Sprintf("with restart interval of %d", restartInterval), func() { - // Make block. - bt := Build(kv, restartInterval) - - Test := func(r *util.Range) func(done Done) { - return func(done Done) { - iter := bt.TestNewIterator(r) - Expect(iter.Error()).ShouldNot(HaveOccurred()) - - t := testutil.IteratorTesting{ - KeyValue: kv.Clone(), - Iter: iter, - } - - testutil.DoIteratorTesting(&t) - iter.Release() - done <- true - } - } - - It("Should do iterations and seeks correctly #0", - Test(&util.Range{Start: []byte("k0"), Limit: []byte("k6")}), 2.0) - - It("Should do iterations and seeks correctly #1", - Test(&util.Range{Start: []byte(""), Limit: []byte("zzzzzzz")}), 2.0) - }) - } - }) - }) -}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/reader.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/reader.go deleted file mode 100644 index 16cfbaa..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/reader.go +++ /dev/null @@ -1,1135 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package table - -import ( - "encoding/binary" - "fmt" - "io" - "sort" - "strings" - "sync" - - "github.com/golang/snappy" - - "github.com/syndtr/goleveldb/leveldb/cache" - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/filter" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/util" -) - -// Reader errors. -var ( - ErrNotFound = errors.ErrNotFound - ErrReaderReleased = errors.New("leveldb/table: reader released") - ErrIterReleased = errors.New("leveldb/table: iterator released") -) - -// ErrCorrupted describes error due to corruption. This error will be wrapped -// with errors.ErrCorrupted. -type ErrCorrupted struct { - Pos int64 - Size int64 - Kind string - Reason string -} - -func (e *ErrCorrupted) Error() string { - return fmt.Sprintf("leveldb/table: corruption on %s (pos=%d): %s", e.Kind, e.Pos, e.Reason) -} - -func max(x, y int) int { - if x > y { - return x - } - return y -} - -type block struct { - bpool *util.BufferPool - bh blockHandle - data []byte - restartsLen int - restartsOffset int -} - -func (b *block) seek(cmp comparer.Comparer, rstart, rlimit int, key []byte) (index, offset int, err error) { - index = sort.Search(b.restartsLen-rstart-(b.restartsLen-rlimit), func(i int) bool { - offset := int(binary.LittleEndian.Uint32(b.data[b.restartsOffset+4*(rstart+i):])) - offset++ // shared always zero, since this is a restart point - v1, n1 := binary.Uvarint(b.data[offset:]) // key length - _, n2 := binary.Uvarint(b.data[offset+n1:]) // value length - m := offset + n1 + n2 - return cmp.Compare(b.data[m:m+int(v1)], key) > 0 - }) + rstart - 1 - if index < rstart { - // The smallest key is greater-than key sought. - index = rstart - } - offset = int(binary.LittleEndian.Uint32(b.data[b.restartsOffset+4*index:])) - return -} - -func (b *block) restartIndex(rstart, rlimit, offset int) int { - return sort.Search(b.restartsLen-rstart-(b.restartsLen-rlimit), func(i int) bool { - return int(binary.LittleEndian.Uint32(b.data[b.restartsOffset+4*(rstart+i):])) > offset - }) + rstart - 1 -} - -func (b *block) restartOffset(index int) int { - return int(binary.LittleEndian.Uint32(b.data[b.restartsOffset+4*index:])) -} - -func (b *block) entry(offset int) (key, value []byte, nShared, n int, err error) { - if offset >= b.restartsOffset { - if offset != b.restartsOffset { - err = &ErrCorrupted{Reason: "entries offset not aligned"} - } - return - } - v0, n0 := binary.Uvarint(b.data[offset:]) // Shared prefix length - v1, n1 := binary.Uvarint(b.data[offset+n0:]) // Key length - v2, n2 := binary.Uvarint(b.data[offset+n0+n1:]) // Value length - m := n0 + n1 + n2 - n = m + int(v1) + int(v2) - if n0 <= 0 || n1 <= 0 || n2 <= 0 || offset+n > b.restartsOffset { - err = &ErrCorrupted{Reason: "entries corrupted"} - return - } - key = b.data[offset+m : offset+m+int(v1)] - value = b.data[offset+m+int(v1) : offset+n] - nShared = int(v0) - return -} - -func (b *block) Release() { - b.bpool.Put(b.data) - b.bpool = nil - b.data = nil -} - -type dir int - -const ( - dirReleased dir = iota - 1 - dirSOI - dirEOI - dirBackward - dirForward -) - -type blockIter struct { - tr *Reader - block *block - blockReleaser util.Releaser - releaser util.Releaser - key, value []byte - offset int - // Previous offset, only filled by Next. - prevOffset int - prevNode []int - prevKeys []byte - restartIndex int - // Iterator direction. - dir dir - // Restart index slice range. - riStart int - riLimit int - // Offset slice range. - offsetStart int - offsetRealStart int - offsetLimit int - // Error. - err error -} - -func (i *blockIter) sErr(err error) { - i.err = err - i.key = nil - i.value = nil - i.prevNode = nil - i.prevKeys = nil -} - -func (i *blockIter) reset() { - if i.dir == dirBackward { - i.prevNode = i.prevNode[:0] - i.prevKeys = i.prevKeys[:0] - } - i.restartIndex = i.riStart - i.offset = i.offsetStart - i.dir = dirSOI - i.key = i.key[:0] - i.value = nil -} - -func (i *blockIter) isFirst() bool { - switch i.dir { - case dirForward: - return i.prevOffset == i.offsetRealStart - case dirBackward: - return len(i.prevNode) == 1 && i.restartIndex == i.riStart - } - return false -} - -func (i *blockIter) isLast() bool { - switch i.dir { - case dirForward, dirBackward: - return i.offset == i.offsetLimit - } - return false -} - -func (i *blockIter) First() bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - if i.dir == dirBackward { - i.prevNode = i.prevNode[:0] - i.prevKeys = i.prevKeys[:0] - } - i.dir = dirSOI - return i.Next() -} - -func (i *blockIter) Last() bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - if i.dir == dirBackward { - i.prevNode = i.prevNode[:0] - i.prevKeys = i.prevKeys[:0] - } - i.dir = dirEOI - return i.Prev() -} - -func (i *blockIter) Seek(key []byte) bool { - if i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - ri, offset, err := i.block.seek(i.tr.cmp, i.riStart, i.riLimit, key) - if err != nil { - i.sErr(err) - return false - } - i.restartIndex = ri - i.offset = max(i.offsetStart, offset) - if i.dir == dirSOI || i.dir == dirEOI { - i.dir = dirForward - } - for i.Next() { - if i.tr.cmp.Compare(i.key, key) >= 0 { - return true - } - } - return false -} - -func (i *blockIter) Next() bool { - if i.dir == dirEOI || i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - if i.dir == dirSOI { - i.restartIndex = i.riStart - i.offset = i.offsetStart - } else if i.dir == dirBackward { - i.prevNode = i.prevNode[:0] - i.prevKeys = i.prevKeys[:0] - } - for i.offset < i.offsetRealStart { - key, value, nShared, n, err := i.block.entry(i.offset) - if err != nil { - i.sErr(i.tr.fixErrCorruptedBH(i.block.bh, err)) - return false - } - if n == 0 { - i.dir = dirEOI - return false - } - i.key = append(i.key[:nShared], key...) - i.value = value - i.offset += n - } - if i.offset >= i.offsetLimit { - i.dir = dirEOI - if i.offset != i.offsetLimit { - i.sErr(i.tr.newErrCorruptedBH(i.block.bh, "entries offset not aligned")) - } - return false - } - key, value, nShared, n, err := i.block.entry(i.offset) - if err != nil { - i.sErr(i.tr.fixErrCorruptedBH(i.block.bh, err)) - return false - } - if n == 0 { - i.dir = dirEOI - return false - } - i.key = append(i.key[:nShared], key...) - i.value = value - i.prevOffset = i.offset - i.offset += n - i.dir = dirForward - return true -} - -func (i *blockIter) Prev() bool { - if i.dir == dirSOI || i.err != nil { - return false - } else if i.dir == dirReleased { - i.err = ErrIterReleased - return false - } - - var ri int - if i.dir == dirForward { - // Change direction. - i.offset = i.prevOffset - if i.offset == i.offsetRealStart { - i.dir = dirSOI - return false - } - ri = i.block.restartIndex(i.restartIndex, i.riLimit, i.offset) - i.dir = dirBackward - } else if i.dir == dirEOI { - // At the end of iterator. - i.restartIndex = i.riLimit - i.offset = i.offsetLimit - if i.offset == i.offsetRealStart { - i.dir = dirSOI - return false - } - ri = i.riLimit - 1 - i.dir = dirBackward - } else if len(i.prevNode) == 1 { - // This is the end of a restart range. - i.offset = i.prevNode[0] - i.prevNode = i.prevNode[:0] - if i.restartIndex == i.riStart { - i.dir = dirSOI - return false - } - i.restartIndex-- - ri = i.restartIndex - } else { - // In the middle of restart range, get from cache. - n := len(i.prevNode) - 3 - node := i.prevNode[n:] - i.prevNode = i.prevNode[:n] - // Get the key. - ko := node[0] - i.key = append(i.key[:0], i.prevKeys[ko:]...) - i.prevKeys = i.prevKeys[:ko] - // Get the value. - vo := node[1] - vl := vo + node[2] - i.value = i.block.data[vo:vl] - i.offset = vl - return true - } - // Build entries cache. - i.key = i.key[:0] - i.value = nil - offset := i.block.restartOffset(ri) - if offset == i.offset { - ri-- - if ri < 0 { - i.dir = dirSOI - return false - } - offset = i.block.restartOffset(ri) - } - i.prevNode = append(i.prevNode, offset) - for { - key, value, nShared, n, err := i.block.entry(offset) - if err != nil { - i.sErr(i.tr.fixErrCorruptedBH(i.block.bh, err)) - return false - } - if offset >= i.offsetRealStart { - if i.value != nil { - // Appends 3 variables: - // 1. Previous keys offset - // 2. Value offset in the data block - // 3. Value length - i.prevNode = append(i.prevNode, len(i.prevKeys), offset-len(i.value), len(i.value)) - i.prevKeys = append(i.prevKeys, i.key...) - } - i.value = value - } - i.key = append(i.key[:nShared], key...) - offset += n - // Stop if target offset reached. - if offset >= i.offset { - if offset != i.offset { - i.sErr(i.tr.newErrCorruptedBH(i.block.bh, "entries offset not aligned")) - return false - } - - break - } - } - i.restartIndex = ri - i.offset = offset - return true -} - -func (i *blockIter) Key() []byte { - if i.err != nil || i.dir <= dirEOI { - return nil - } - return i.key -} - -func (i *blockIter) Value() []byte { - if i.err != nil || i.dir <= dirEOI { - return nil - } - return i.value -} - -func (i *blockIter) Release() { - if i.dir != dirReleased { - i.tr = nil - i.block = nil - i.prevNode = nil - i.prevKeys = nil - i.key = nil - i.value = nil - i.dir = dirReleased - if i.blockReleaser != nil { - i.blockReleaser.Release() - i.blockReleaser = nil - } - if i.releaser != nil { - i.releaser.Release() - i.releaser = nil - } - } -} - -func (i *blockIter) SetReleaser(releaser util.Releaser) { - if i.dir == dirReleased { - panic(util.ErrReleased) - } - if i.releaser != nil && releaser != nil { - panic(util.ErrHasReleaser) - } - i.releaser = releaser -} - -func (i *blockIter) Valid() bool { - return i.err == nil && (i.dir == dirBackward || i.dir == dirForward) -} - -func (i *blockIter) Error() error { - return i.err -} - -type filterBlock struct { - bpool *util.BufferPool - data []byte - oOffset int - baseLg uint - filtersNum int -} - -func (b *filterBlock) contains(filter filter.Filter, offset uint64, key []byte) bool { - i := int(offset >> b.baseLg) - if i < b.filtersNum { - o := b.data[b.oOffset+i*4:] - n := int(binary.LittleEndian.Uint32(o)) - m := int(binary.LittleEndian.Uint32(o[4:])) - if n < m && m <= b.oOffset { - return filter.Contains(b.data[n:m], key) - } else if n == m { - return false - } - } - return true -} - -func (b *filterBlock) Release() { - b.bpool.Put(b.data) - b.bpool = nil - b.data = nil -} - -type indexIter struct { - *blockIter - tr *Reader - slice *util.Range - // Options - fillCache bool -} - -func (i *indexIter) Get() iterator.Iterator { - value := i.Value() - if value == nil { - return nil - } - dataBH, n := decodeBlockHandle(value) - if n == 0 { - return iterator.NewEmptyIterator(i.tr.newErrCorruptedBH(i.tr.indexBH, "bad data block handle")) - } - - var slice *util.Range - if i.slice != nil && (i.blockIter.isFirst() || i.blockIter.isLast()) { - slice = i.slice - } - return i.tr.getDataIterErr(dataBH, slice, i.tr.verifyChecksum, i.fillCache) -} - -// Reader is a table reader. -type Reader struct { - mu sync.RWMutex - fd storage.FileDesc - reader io.ReaderAt - cache *cache.NamespaceGetter - err error - bpool *util.BufferPool - // Options - o *opt.Options - cmp comparer.Comparer - filter filter.Filter - verifyChecksum bool - - dataEnd int64 - metaBH, indexBH, filterBH blockHandle - indexBlock *block - filterBlock *filterBlock -} - -func (r *Reader) blockKind(bh blockHandle) string { - switch bh.offset { - case r.metaBH.offset: - return "meta-block" - case r.indexBH.offset: - return "index-block" - case r.filterBH.offset: - if r.filterBH.length > 0 { - return "filter-block" - } - } - return "data-block" -} - -func (r *Reader) newErrCorrupted(pos, size int64, kind, reason string) error { - return &errors.ErrCorrupted{Fd: r.fd, Err: &ErrCorrupted{Pos: pos, Size: size, Kind: kind, Reason: reason}} -} - -func (r *Reader) newErrCorruptedBH(bh blockHandle, reason string) error { - return r.newErrCorrupted(int64(bh.offset), int64(bh.length), r.blockKind(bh), reason) -} - -func (r *Reader) fixErrCorruptedBH(bh blockHandle, err error) error { - if cerr, ok := err.(*ErrCorrupted); ok { - cerr.Pos = int64(bh.offset) - cerr.Size = int64(bh.length) - cerr.Kind = r.blockKind(bh) - return &errors.ErrCorrupted{Fd: r.fd, Err: cerr} - } - return err -} - -func (r *Reader) readRawBlock(bh blockHandle, verifyChecksum bool) ([]byte, error) { - data := r.bpool.Get(int(bh.length + blockTrailerLen)) - if _, err := r.reader.ReadAt(data, int64(bh.offset)); err != nil && err != io.EOF { - return nil, err - } - - if verifyChecksum { - n := bh.length + 1 - checksum0 := binary.LittleEndian.Uint32(data[n:]) - checksum1 := util.NewCRC(data[:n]).Value() - if checksum0 != checksum1 { - r.bpool.Put(data) - return nil, r.newErrCorruptedBH(bh, fmt.Sprintf("checksum mismatch, want=%#x got=%#x", checksum0, checksum1)) - } - } - - switch data[bh.length] { - case blockTypeNoCompression: - data = data[:bh.length] - case blockTypeSnappyCompression: - decLen, err := snappy.DecodedLen(data[:bh.length]) - if err != nil { - r.bpool.Put(data) - return nil, r.newErrCorruptedBH(bh, err.Error()) - } - decData := r.bpool.Get(decLen) - decData, err = snappy.Decode(decData, data[:bh.length]) - r.bpool.Put(data) - if err != nil { - r.bpool.Put(decData) - return nil, r.newErrCorruptedBH(bh, err.Error()) - } - data = decData - default: - r.bpool.Put(data) - return nil, r.newErrCorruptedBH(bh, fmt.Sprintf("unknown compression type %#x", data[bh.length])) - } - return data, nil -} - -func (r *Reader) readBlock(bh blockHandle, verifyChecksum bool) (*block, error) { - data, err := r.readRawBlock(bh, verifyChecksum) - if err != nil { - return nil, err - } - restartsLen := int(binary.LittleEndian.Uint32(data[len(data)-4:])) - b := &block{ - bpool: r.bpool, - bh: bh, - data: data, - restartsLen: restartsLen, - restartsOffset: len(data) - (restartsLen+1)*4, - } - return b, nil -} - -func (r *Reader) readBlockCached(bh blockHandle, verifyChecksum, fillCache bool) (*block, util.Releaser, error) { - if r.cache != nil { - var ( - err error - ch *cache.Handle - ) - if fillCache { - ch = r.cache.Get(bh.offset, func() (size int, value cache.Value) { - var b *block - b, err = r.readBlock(bh, verifyChecksum) - if err != nil { - return 0, nil - } - return cap(b.data), b - }) - } else { - ch = r.cache.Get(bh.offset, nil) - } - if ch != nil { - b, ok := ch.Value().(*block) - if !ok { - ch.Release() - return nil, nil, errors.New("leveldb/table: inconsistent block type") - } - return b, ch, err - } else if err != nil { - return nil, nil, err - } - } - - b, err := r.readBlock(bh, verifyChecksum) - return b, b, err -} - -func (r *Reader) readFilterBlock(bh blockHandle) (*filterBlock, error) { - data, err := r.readRawBlock(bh, true) - if err != nil { - return nil, err - } - n := len(data) - if n < 5 { - return nil, r.newErrCorruptedBH(bh, "too short") - } - m := n - 5 - oOffset := int(binary.LittleEndian.Uint32(data[m:])) - if oOffset > m { - return nil, r.newErrCorruptedBH(bh, "invalid data-offsets offset") - } - b := &filterBlock{ - bpool: r.bpool, - data: data, - oOffset: oOffset, - baseLg: uint(data[n-1]), - filtersNum: (m - oOffset) / 4, - } - return b, nil -} - -func (r *Reader) readFilterBlockCached(bh blockHandle, fillCache bool) (*filterBlock, util.Releaser, error) { - if r.cache != nil { - var ( - err error - ch *cache.Handle - ) - if fillCache { - ch = r.cache.Get(bh.offset, func() (size int, value cache.Value) { - var b *filterBlock - b, err = r.readFilterBlock(bh) - if err != nil { - return 0, nil - } - return cap(b.data), b - }) - } else { - ch = r.cache.Get(bh.offset, nil) - } - if ch != nil { - b, ok := ch.Value().(*filterBlock) - if !ok { - ch.Release() - return nil, nil, errors.New("leveldb/table: inconsistent block type") - } - return b, ch, err - } else if err != nil { - return nil, nil, err - } - } - - b, err := r.readFilterBlock(bh) - return b, b, err -} - -func (r *Reader) getIndexBlock(fillCache bool) (b *block, rel util.Releaser, err error) { - if r.indexBlock == nil { - return r.readBlockCached(r.indexBH, true, fillCache) - } - return r.indexBlock, util.NoopReleaser{}, nil -} - -func (r *Reader) getFilterBlock(fillCache bool) (*filterBlock, util.Releaser, error) { - if r.filterBlock == nil { - return r.readFilterBlockCached(r.filterBH, fillCache) - } - return r.filterBlock, util.NoopReleaser{}, nil -} - -func (r *Reader) newBlockIter(b *block, bReleaser util.Releaser, slice *util.Range, inclLimit bool) *blockIter { - bi := &blockIter{ - tr: r, - block: b, - blockReleaser: bReleaser, - // Valid key should never be nil. - key: make([]byte, 0), - dir: dirSOI, - riStart: 0, - riLimit: b.restartsLen, - offsetStart: 0, - offsetRealStart: 0, - offsetLimit: b.restartsOffset, - } - if slice != nil { - if slice.Start != nil { - if bi.Seek(slice.Start) { - bi.riStart = b.restartIndex(bi.restartIndex, b.restartsLen, bi.prevOffset) - bi.offsetStart = b.restartOffset(bi.riStart) - bi.offsetRealStart = bi.prevOffset - } else { - bi.riStart = b.restartsLen - bi.offsetStart = b.restartsOffset - bi.offsetRealStart = b.restartsOffset - } - } - if slice.Limit != nil { - if bi.Seek(slice.Limit) && (!inclLimit || bi.Next()) { - bi.offsetLimit = bi.prevOffset - bi.riLimit = bi.restartIndex + 1 - } - } - bi.reset() - if bi.offsetStart > bi.offsetLimit { - bi.sErr(errors.New("leveldb/table: invalid slice range")) - } - } - return bi -} - -func (r *Reader) getDataIter(dataBH blockHandle, slice *util.Range, verifyChecksum, fillCache bool) iterator.Iterator { - b, rel, err := r.readBlockCached(dataBH, verifyChecksum, fillCache) - if err != nil { - return iterator.NewEmptyIterator(err) - } - return r.newBlockIter(b, rel, slice, false) -} - -func (r *Reader) getDataIterErr(dataBH blockHandle, slice *util.Range, verifyChecksum, fillCache bool) iterator.Iterator { - r.mu.RLock() - defer r.mu.RUnlock() - - if r.err != nil { - return iterator.NewEmptyIterator(r.err) - } - - return r.getDataIter(dataBH, slice, verifyChecksum, fillCache) -} - -// NewIterator creates an iterator from the table. -// -// Slice allows slicing the iterator to only contains keys in the given -// range. A nil Range.Start is treated as a key before all keys in the -// table. And a nil Range.Limit is treated as a key after all keys in -// the table. -// -// The returned iterator is not safe for concurrent use and should be released -// after use. -// -// Also read Iterator documentation of the leveldb/iterator package. -func (r *Reader) NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator { - r.mu.RLock() - defer r.mu.RUnlock() - - if r.err != nil { - return iterator.NewEmptyIterator(r.err) - } - - fillCache := !ro.GetDontFillCache() - indexBlock, rel, err := r.getIndexBlock(fillCache) - if err != nil { - return iterator.NewEmptyIterator(err) - } - index := &indexIter{ - blockIter: r.newBlockIter(indexBlock, rel, slice, true), - tr: r, - slice: slice, - fillCache: !ro.GetDontFillCache(), - } - return iterator.NewIndexedIterator(index, opt.GetStrict(r.o, ro, opt.StrictReader)) -} - -func (r *Reader) find(key []byte, filtered bool, ro *opt.ReadOptions, noValue bool) (rkey, value []byte, err error) { - r.mu.RLock() - defer r.mu.RUnlock() - - if r.err != nil { - err = r.err - return - } - - indexBlock, rel, err := r.getIndexBlock(true) - if err != nil { - return - } - defer rel.Release() - - index := r.newBlockIter(indexBlock, nil, nil, true) - defer index.Release() - - if !index.Seek(key) { - if err = index.Error(); err == nil { - err = ErrNotFound - } - return - } - - dataBH, n := decodeBlockHandle(index.Value()) - if n == 0 { - r.err = r.newErrCorruptedBH(r.indexBH, "bad data block handle") - return nil, nil, r.err - } - - // The filter should only used for exact match. - if filtered && r.filter != nil { - filterBlock, frel, ferr := r.getFilterBlock(true) - if ferr == nil { - if !filterBlock.contains(r.filter, dataBH.offset, key) { - frel.Release() - return nil, nil, ErrNotFound - } - frel.Release() - } else if !errors.IsCorrupted(ferr) { - return nil, nil, ferr - } - } - - data := r.getDataIter(dataBH, nil, r.verifyChecksum, !ro.GetDontFillCache()) - if !data.Seek(key) { - data.Release() - if err = data.Error(); err != nil { - return - } - - // The nearest greater-than key is the first key of the next block. - if !index.Next() { - if err = index.Error(); err == nil { - err = ErrNotFound - } - return - } - - dataBH, n = decodeBlockHandle(index.Value()) - if n == 0 { - r.err = r.newErrCorruptedBH(r.indexBH, "bad data block handle") - return nil, nil, r.err - } - - data = r.getDataIter(dataBH, nil, r.verifyChecksum, !ro.GetDontFillCache()) - if !data.Next() { - data.Release() - if err = data.Error(); err == nil { - err = ErrNotFound - } - return - } - } - - // Key doesn't use block buffer, no need to copy the buffer. - rkey = data.Key() - if !noValue { - if r.bpool == nil { - value = data.Value() - } else { - // Value does use block buffer, and since the buffer will be - // recycled, it need to be copied. - value = append([]byte{}, data.Value()...) - } - } - data.Release() - return -} - -// Find finds key/value pair whose key is greater than or equal to the -// given key. It returns ErrNotFound if the table doesn't contain -// such pair. -// If filtered is true then the nearest 'block' will be checked against -// 'filter data' (if present) and will immediately return ErrNotFound if -// 'filter data' indicates that such pair doesn't exist. -// -// The caller may modify the contents of the returned slice as it is its -// own copy. -// It is safe to modify the contents of the argument after Find returns. -func (r *Reader) Find(key []byte, filtered bool, ro *opt.ReadOptions) (rkey, value []byte, err error) { - return r.find(key, filtered, ro, false) -} - -// FindKey finds key that is greater than or equal to the given key. -// It returns ErrNotFound if the table doesn't contain such key. -// If filtered is true then the nearest 'block' will be checked against -// 'filter data' (if present) and will immediately return ErrNotFound if -// 'filter data' indicates that such key doesn't exist. -// -// The caller may modify the contents of the returned slice as it is its -// own copy. -// It is safe to modify the contents of the argument after Find returns. -func (r *Reader) FindKey(key []byte, filtered bool, ro *opt.ReadOptions) (rkey []byte, err error) { - rkey, _, err = r.find(key, filtered, ro, true) - return -} - -// Get gets the value for the given key. It returns errors.ErrNotFound -// if the table does not contain the key. -// -// The caller may modify the contents of the returned slice as it is its -// own copy. -// It is safe to modify the contents of the argument after Find returns. -func (r *Reader) Get(key []byte, ro *opt.ReadOptions) (value []byte, err error) { - r.mu.RLock() - defer r.mu.RUnlock() - - if r.err != nil { - err = r.err - return - } - - rkey, value, err := r.find(key, false, ro, false) - if err == nil && r.cmp.Compare(rkey, key) != 0 { - value = nil - err = ErrNotFound - } - return -} - -// OffsetOf returns approximate offset for the given key. -// -// It is safe to modify the contents of the argument after Get returns. -func (r *Reader) OffsetOf(key []byte) (offset int64, err error) { - r.mu.RLock() - defer r.mu.RUnlock() - - if r.err != nil { - err = r.err - return - } - - indexBlock, rel, err := r.readBlockCached(r.indexBH, true, true) - if err != nil { - return - } - defer rel.Release() - - index := r.newBlockIter(indexBlock, nil, nil, true) - defer index.Release() - if index.Seek(key) { - dataBH, n := decodeBlockHandle(index.Value()) - if n == 0 { - r.err = r.newErrCorruptedBH(r.indexBH, "bad data block handle") - return - } - offset = int64(dataBH.offset) - return - } - err = index.Error() - if err == nil { - offset = r.dataEnd - } - return -} - -// Release implements util.Releaser. -// It also close the file if it is an io.Closer. -func (r *Reader) Release() { - r.mu.Lock() - defer r.mu.Unlock() - - if closer, ok := r.reader.(io.Closer); ok { - closer.Close() - } - if r.indexBlock != nil { - r.indexBlock.Release() - r.indexBlock = nil - } - if r.filterBlock != nil { - r.filterBlock.Release() - r.filterBlock = nil - } - r.reader = nil - r.cache = nil - r.bpool = nil - r.err = ErrReaderReleased -} - -// NewReader creates a new initialized table reader for the file. -// The fi, cache and bpool is optional and can be nil. -// -// The returned table reader instance is safe for concurrent use. -func NewReader(f io.ReaderAt, size int64, fd storage.FileDesc, cache *cache.NamespaceGetter, bpool *util.BufferPool, o *opt.Options) (*Reader, error) { - if f == nil { - return nil, errors.New("leveldb/table: nil file") - } - - r := &Reader{ - fd: fd, - reader: f, - cache: cache, - bpool: bpool, - o: o, - cmp: o.GetComparer(), - verifyChecksum: o.GetStrict(opt.StrictBlockChecksum), - } - - if size < footerLen { - r.err = r.newErrCorrupted(0, size, "table", "too small") - return r, nil - } - - footerPos := size - footerLen - var footer [footerLen]byte - if _, err := r.reader.ReadAt(footer[:], footerPos); err != nil && err != io.EOF { - return nil, err - } - if string(footer[footerLen-len(magic):footerLen]) != magic { - r.err = r.newErrCorrupted(footerPos, footerLen, "table-footer", "bad magic number") - return r, nil - } - - var n int - // Decode the metaindex block handle. - r.metaBH, n = decodeBlockHandle(footer[:]) - if n == 0 { - r.err = r.newErrCorrupted(footerPos, footerLen, "table-footer", "bad metaindex block handle") - return r, nil - } - - // Decode the index block handle. - r.indexBH, n = decodeBlockHandle(footer[n:]) - if n == 0 { - r.err = r.newErrCorrupted(footerPos, footerLen, "table-footer", "bad index block handle") - return r, nil - } - - // Read metaindex block. - metaBlock, err := r.readBlock(r.metaBH, true) - if err != nil { - if errors.IsCorrupted(err) { - r.err = err - return r, nil - } - return nil, err - } - - // Set data end. - r.dataEnd = int64(r.metaBH.offset) - - // Read metaindex. - metaIter := r.newBlockIter(metaBlock, nil, nil, true) - for metaIter.Next() { - key := string(metaIter.Key()) - if !strings.HasPrefix(key, "filter.") { - continue - } - fn := key[7:] - if f0 := o.GetFilter(); f0 != nil && f0.Name() == fn { - r.filter = f0 - } else { - for _, f0 := range o.GetAltFilters() { - if f0.Name() == fn { - r.filter = f0 - break - } - } - } - if r.filter != nil { - filterBH, n := decodeBlockHandle(metaIter.Value()) - if n == 0 { - continue - } - r.filterBH = filterBH - // Update data end. - r.dataEnd = int64(filterBH.offset) - break - } - } - metaIter.Release() - metaBlock.Release() - - // Cache index and filter block locally, since we don't have global cache. - if cache == nil { - r.indexBlock, err = r.readBlock(r.indexBH, true) - if err != nil { - if errors.IsCorrupted(err) { - r.err = err - return r, nil - } - return nil, err - } - if r.filter != nil { - r.filterBlock, err = r.readFilterBlock(r.filterBH) - if err != nil { - if !errors.IsCorrupted(err) { - return nil, err - } - - // Don't use filter then. - r.filter = nil - } - } - } - - return r, nil -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/table.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/table.go deleted file mode 100644 index beacdc1..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/table.go +++ /dev/null @@ -1,177 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package table allows read and write sorted key/value. -package table - -import ( - "encoding/binary" -) - -/* -Table: - -Table is consist of one or more data blocks, an optional filter block -a metaindex block, an index block and a table footer. Metaindex block -is a special block used to keep parameters of the table, such as filter -block name and its block handle. Index block is a special block used to -keep record of data blocks offset and length, index block use one as -restart interval. The key used by index block are the last key of preceding -block, shorter separator of adjacent blocks or shorter successor of the -last key of the last block. Filter block is an optional block contains -sequence of filter data generated by a filter generator. - -Table data structure: - + optional - / - +--------------+--------------+--------------+------+-------+-----------------+-------------+--------+ - | data block 1 | ... | data block n | filter block | metaindex block | index block | footer | - +--------------+--------------+--------------+--------------+-----------------+-------------+--------+ - - Each block followed by a 5-bytes trailer contains compression type and checksum. - -Table block trailer: - - +---------------------------+-------------------+ - | compression type (1-byte) | checksum (4-byte) | - +---------------------------+-------------------+ - - The checksum is a CRC-32 computed using Castagnoli's polynomial. Compression - type also included in the checksum. - -Table footer: - - +------------------- 40-bytes -------------------+ - / \ - +------------------------+--------------------+------+-----------------+ - | metaindex block handle / index block handle / ---- | magic (8-bytes) | - +------------------------+--------------------+------+-----------------+ - - The magic are first 64-bit of SHA-1 sum of "http://code.google.com/p/leveldb/". - -NOTE: All fixed-length integer are little-endian. -*/ - -/* -Block: - -Block is consist of one or more key/value entries and a block trailer. -Block entry shares key prefix with its preceding key until a restart -point reached. A block should contains at least one restart point. -First restart point are always zero. - -Block data structure: - - + restart point + restart point (depends on restart interval) - / / - +---------------+---------------+---------------+---------------+---------+ - | block entry 1 | block entry 2 | ... | block entry n | trailer | - +---------------+---------------+---------------+---------------+---------+ - -Key/value entry: - - +---- key len ----+ - / \ - +-------+---------+-----------+---------+--------------------+--------------+----------------+ - | shared (varint) | not shared (varint) | value len (varint) | key (varlen) | value (varlen) | - +-----------------+---------------------+--------------------+--------------+----------------+ - - Block entry shares key prefix with its preceding key: - Conditions: - restart_interval=2 - entry one : key=deck,value=v1 - entry two : key=dock,value=v2 - entry three: key=duck,value=v3 - The entries will be encoded as follow: - - + restart point (offset=0) + restart point (offset=16) - / / - +-----+-----+-----+----------+--------+-----+-----+-----+---------+--------+-----+-----+-----+----------+--------+ - | 0 | 4 | 2 | "deck" | "v1" | 1 | 3 | 2 | "ock" | "v2" | 0 | 4 | 2 | "duck" | "v3" | - +-----+-----+-----+----------+--------+-----+-----+-----+---------+--------+-----+-----+-----+----------+--------+ - \ / \ / \ / - +----------- entry one -----------+ +----------- entry two ----------+ +---------- entry three ----------+ - - The block trailer will contains two restart points: - - +------------+-----------+--------+ - | 0 | 16 | 2 | - +------------+-----------+---+----+ - \ / \ - +-- restart points --+ + restart points length - -Block trailer: - - +-- 4-bytes --+ - / \ - +-----------------+-----------------+-----------------+------------------------------+ - | restart point 1 | .... | restart point n | restart points len (4-bytes) | - +-----------------+-----------------+-----------------+------------------------------+ - - -NOTE: All fixed-length integer are little-endian. -*/ - -/* -Filter block: - -Filter block consist of one or more filter data and a filter block trailer. -The trailer contains filter data offsets, a trailer offset and a 1-byte base Lg. - -Filter block data structure: - - + offset 1 + offset 2 + offset n + trailer offset - / / / / - +---------------+---------------+---------------+---------+ - | filter data 1 | ... | filter data n | trailer | - +---------------+---------------+---------------+---------+ - -Filter block trailer: - - +- 4-bytes -+ - / \ - +---------------+---------------+---------------+-------------------------------+------------------+ - | data 1 offset | .... | data n offset | data-offsets offset (4-bytes) | base Lg (1-byte) | - +-------------- +---------------+---------------+-------------------------------+------------------+ - - -NOTE: All fixed-length integer are little-endian. -*/ - -const ( - blockTrailerLen = 5 - footerLen = 48 - - magic = "\x57\xfb\x80\x8b\x24\x75\x47\xdb" - - // The block type gives the per-block compression format. - // These constants are part of the file format and should not be changed. - blockTypeNoCompression = 0 - blockTypeSnappyCompression = 1 - - // Generate new filter every 2KB of data - filterBaseLg = 11 - filterBase = 1 << filterBaseLg -) - -type blockHandle struct { - offset, length uint64 -} - -func decodeBlockHandle(src []byte) (blockHandle, int) { - offset, n := binary.Uvarint(src) - length, m := binary.Uvarint(src[n:]) - if n == 0 || m == 0 { - return blockHandle{}, 0 - } - return blockHandle{offset, length}, n + m -} - -func encodeBlockHandle(dst []byte, b blockHandle) int { - n := binary.PutUvarint(dst, b.offset) - m := binary.PutUvarint(dst[n:], b.length) - return n + m -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/table_suite_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/table_suite_test.go deleted file mode 100644 index 6465da6..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/table_suite_test.go +++ /dev/null @@ -1,11 +0,0 @@ -package table - -import ( - "testing" - - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -func TestTable(t *testing.T) { - testutil.RunSuite(t, "Table Suite") -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/table_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/table_test.go deleted file mode 100644 index 232efcd..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/table_test.go +++ /dev/null @@ -1,123 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package table - -import ( - "bytes" - - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/testutil" - "github.com/syndtr/goleveldb/leveldb/util" -) - -type tableWrapper struct { - *Reader -} - -func (t tableWrapper) TestFind(key []byte) (rkey, rvalue []byte, err error) { - return t.Reader.Find(key, false, nil) -} - -func (t tableWrapper) TestGet(key []byte) (value []byte, err error) { - return t.Reader.Get(key, nil) -} - -func (t tableWrapper) TestNewIterator(slice *util.Range) iterator.Iterator { - return t.Reader.NewIterator(slice, nil) -} - -var _ = testutil.Defer(func() { - Describe("Table", func() { - Describe("approximate offset test", func() { - var ( - buf = &bytes.Buffer{} - o = &opt.Options{ - BlockSize: 1024, - Compression: opt.NoCompression, - } - ) - - // Building the table. - tw := NewWriter(buf, o) - tw.Append([]byte("k01"), []byte("hello")) - tw.Append([]byte("k02"), []byte("hello2")) - tw.Append([]byte("k03"), bytes.Repeat([]byte{'x'}, 10000)) - tw.Append([]byte("k04"), bytes.Repeat([]byte{'x'}, 200000)) - tw.Append([]byte("k05"), bytes.Repeat([]byte{'x'}, 300000)) - tw.Append([]byte("k06"), []byte("hello3")) - tw.Append([]byte("k07"), bytes.Repeat([]byte{'x'}, 100000)) - err := tw.Close() - - It("Should be able to approximate offset of a key correctly", func() { - Expect(err).ShouldNot(HaveOccurred()) - - tr, err := NewReader(bytes.NewReader(buf.Bytes()), int64(buf.Len()), storage.FileDesc{}, nil, nil, o) - Expect(err).ShouldNot(HaveOccurred()) - CheckOffset := func(key string, expect, threshold int) { - offset, err := tr.OffsetOf([]byte(key)) - Expect(err).ShouldNot(HaveOccurred()) - Expect(offset).Should(BeNumerically("~", expect, threshold), "Offset of key %q", key) - } - - CheckOffset("k0", 0, 0) - CheckOffset("k01a", 0, 0) - CheckOffset("k02", 0, 0) - CheckOffset("k03", 0, 0) - CheckOffset("k04", 10000, 1000) - CheckOffset("k04a", 210000, 1000) - CheckOffset("k05", 210000, 1000) - CheckOffset("k06", 510000, 1000) - CheckOffset("k07", 510000, 1000) - CheckOffset("xyz", 610000, 2000) - }) - }) - - Describe("read test", func() { - Build := func(kv testutil.KeyValue) testutil.DB { - o := &opt.Options{ - BlockSize: 512, - BlockRestartInterval: 3, - } - buf := &bytes.Buffer{} - - // Building the table. - tw := NewWriter(buf, o) - kv.Iterate(func(i int, key, value []byte) { - tw.Append(key, value) - }) - tw.Close() - - // Opening the table. - tr, _ := NewReader(bytes.NewReader(buf.Bytes()), int64(buf.Len()), storage.FileDesc{}, nil, nil, o) - return tableWrapper{tr} - } - Test := func(kv *testutil.KeyValue, body func(r *Reader)) func() { - return func() { - db := Build(*kv) - if body != nil { - body(db.(tableWrapper).Reader) - } - testutil.KeyValueTesting(nil, *kv, db, nil, nil) - } - } - - testutil.AllKeyValueTesting(nil, Build, nil, nil) - Describe("with one key per block", Test(testutil.KeyValue_Generate(nil, 9, 1, 1, 10, 512, 512), func(r *Reader) { - It("should have correct blocks number", func() { - indexBlock, err := r.readBlock(r.indexBH, true) - Expect(err).To(BeNil()) - Expect(indexBlock.restartsLen).Should(Equal(9)) - }) - })) - }) - }) -}) diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/table/writer.go b/vendor/github.com/syndtr/goleveldb/leveldb/table/writer.go deleted file mode 100644 index b96b271..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/table/writer.go +++ /dev/null @@ -1,375 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package table - -import ( - "encoding/binary" - "errors" - "fmt" - "io" - - "github.com/golang/snappy" - - "github.com/syndtr/goleveldb/leveldb/comparer" - "github.com/syndtr/goleveldb/leveldb/filter" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/util" -) - -func sharedPrefixLen(a, b []byte) int { - i, n := 0, len(a) - if n > len(b) { - n = len(b) - } - for i < n && a[i] == b[i] { - i++ - } - return i -} - -type blockWriter struct { - restartInterval int - buf util.Buffer - nEntries int - prevKey []byte - restarts []uint32 - scratch []byte -} - -func (w *blockWriter) append(key, value []byte) { - nShared := 0 - if w.nEntries%w.restartInterval == 0 { - w.restarts = append(w.restarts, uint32(w.buf.Len())) - } else { - nShared = sharedPrefixLen(w.prevKey, key) - } - n := binary.PutUvarint(w.scratch[0:], uint64(nShared)) - n += binary.PutUvarint(w.scratch[n:], uint64(len(key)-nShared)) - n += binary.PutUvarint(w.scratch[n:], uint64(len(value))) - w.buf.Write(w.scratch[:n]) - w.buf.Write(key[nShared:]) - w.buf.Write(value) - w.prevKey = append(w.prevKey[:0], key...) - w.nEntries++ -} - -func (w *blockWriter) finish() { - // Write restarts entry. - if w.nEntries == 0 { - // Must have at least one restart entry. - w.restarts = append(w.restarts, 0) - } - w.restarts = append(w.restarts, uint32(len(w.restarts))) - for _, x := range w.restarts { - buf4 := w.buf.Alloc(4) - binary.LittleEndian.PutUint32(buf4, x) - } -} - -func (w *blockWriter) reset() { - w.buf.Reset() - w.nEntries = 0 - w.restarts = w.restarts[:0] -} - -func (w *blockWriter) bytesLen() int { - restartsLen := len(w.restarts) - if restartsLen == 0 { - restartsLen = 1 - } - return w.buf.Len() + 4*restartsLen + 4 -} - -type filterWriter struct { - generator filter.FilterGenerator - buf util.Buffer - nKeys int - offsets []uint32 -} - -func (w *filterWriter) add(key []byte) { - if w.generator == nil { - return - } - w.generator.Add(key) - w.nKeys++ -} - -func (w *filterWriter) flush(offset uint64) { - if w.generator == nil { - return - } - for x := int(offset / filterBase); x > len(w.offsets); { - w.generate() - } -} - -func (w *filterWriter) finish() { - if w.generator == nil { - return - } - // Generate last keys. - - if w.nKeys > 0 { - w.generate() - } - w.offsets = append(w.offsets, uint32(w.buf.Len())) - for _, x := range w.offsets { - buf4 := w.buf.Alloc(4) - binary.LittleEndian.PutUint32(buf4, x) - } - w.buf.WriteByte(filterBaseLg) -} - -func (w *filterWriter) generate() { - // Record offset. - w.offsets = append(w.offsets, uint32(w.buf.Len())) - // Generate filters. - if w.nKeys > 0 { - w.generator.Generate(&w.buf) - w.nKeys = 0 - } -} - -// Writer is a table writer. -type Writer struct { - writer io.Writer - err error - // Options - cmp comparer.Comparer - filter filter.Filter - compression opt.Compression - blockSize int - - dataBlock blockWriter - indexBlock blockWriter - filterBlock filterWriter - pendingBH blockHandle - offset uint64 - nEntries int - // Scratch allocated enough for 5 uvarint. Block writer should not use - // first 20-bytes since it will be used to encode block handle, which - // then passed to the block writer itself. - scratch [50]byte - comparerScratch []byte - compressionScratch []byte -} - -func (w *Writer) writeBlock(buf *util.Buffer, compression opt.Compression) (bh blockHandle, err error) { - // Compress the buffer if necessary. - var b []byte - if compression == opt.SnappyCompression { - // Allocate scratch enough for compression and block trailer. - if n := snappy.MaxEncodedLen(buf.Len()) + blockTrailerLen; len(w.compressionScratch) < n { - w.compressionScratch = make([]byte, n) - } - compressed := snappy.Encode(w.compressionScratch, buf.Bytes()) - n := len(compressed) - b = compressed[:n+blockTrailerLen] - b[n] = blockTypeSnappyCompression - } else { - tmp := buf.Alloc(blockTrailerLen) - tmp[0] = blockTypeNoCompression - b = buf.Bytes() - } - - // Calculate the checksum. - n := len(b) - 4 - checksum := util.NewCRC(b[:n]).Value() - binary.LittleEndian.PutUint32(b[n:], checksum) - - // Write the buffer to the file. - _, err = w.writer.Write(b) - if err != nil { - return - } - bh = blockHandle{w.offset, uint64(len(b) - blockTrailerLen)} - w.offset += uint64(len(b)) - return -} - -func (w *Writer) flushPendingBH(key []byte) { - if w.pendingBH.length == 0 { - return - } - var separator []byte - if len(key) == 0 { - separator = w.cmp.Successor(w.comparerScratch[:0], w.dataBlock.prevKey) - } else { - separator = w.cmp.Separator(w.comparerScratch[:0], w.dataBlock.prevKey, key) - } - if separator == nil { - separator = w.dataBlock.prevKey - } else { - w.comparerScratch = separator - } - n := encodeBlockHandle(w.scratch[:20], w.pendingBH) - // Append the block handle to the index block. - w.indexBlock.append(separator, w.scratch[:n]) - // Reset prev key of the data block. - w.dataBlock.prevKey = w.dataBlock.prevKey[:0] - // Clear pending block handle. - w.pendingBH = blockHandle{} -} - -func (w *Writer) finishBlock() error { - w.dataBlock.finish() - bh, err := w.writeBlock(&w.dataBlock.buf, w.compression) - if err != nil { - return err - } - w.pendingBH = bh - // Reset the data block. - w.dataBlock.reset() - // Flush the filter block. - w.filterBlock.flush(w.offset) - return nil -} - -// Append appends key/value pair to the table. The keys passed must -// be in increasing order. -// -// It is safe to modify the contents of the arguments after Append returns. -func (w *Writer) Append(key, value []byte) error { - if w.err != nil { - return w.err - } - if w.nEntries > 0 && w.cmp.Compare(w.dataBlock.prevKey, key) >= 0 { - w.err = fmt.Errorf("leveldb/table: Writer: keys are not in increasing order: %q, %q", w.dataBlock.prevKey, key) - return w.err - } - - w.flushPendingBH(key) - // Append key/value pair to the data block. - w.dataBlock.append(key, value) - // Add key to the filter block. - w.filterBlock.add(key) - - // Finish the data block if block size target reached. - if w.dataBlock.bytesLen() >= w.blockSize { - if err := w.finishBlock(); err != nil { - w.err = err - return w.err - } - } - w.nEntries++ - return nil -} - -// BlocksLen returns number of blocks written so far. -func (w *Writer) BlocksLen() int { - n := w.indexBlock.nEntries - if w.pendingBH.length > 0 { - // Includes the pending block. - n++ - } - return n -} - -// EntriesLen returns number of entries added so far. -func (w *Writer) EntriesLen() int { - return w.nEntries -} - -// BytesLen returns number of bytes written so far. -func (w *Writer) BytesLen() int { - return int(w.offset) -} - -// Close will finalize the table. Calling Append is not possible -// after Close, but calling BlocksLen, EntriesLen and BytesLen -// is still possible. -func (w *Writer) Close() error { - if w.err != nil { - return w.err - } - - // Write the last data block. Or empty data block if there - // aren't any data blocks at all. - if w.dataBlock.nEntries > 0 || w.nEntries == 0 { - if err := w.finishBlock(); err != nil { - w.err = err - return w.err - } - } - w.flushPendingBH(nil) - - // Write the filter block. - var filterBH blockHandle - w.filterBlock.finish() - if buf := &w.filterBlock.buf; buf.Len() > 0 { - filterBH, w.err = w.writeBlock(buf, opt.NoCompression) - if w.err != nil { - return w.err - } - } - - // Write the metaindex block. - if filterBH.length > 0 { - key := []byte("filter." + w.filter.Name()) - n := encodeBlockHandle(w.scratch[:20], filterBH) - w.dataBlock.append(key, w.scratch[:n]) - } - w.dataBlock.finish() - metaindexBH, err := w.writeBlock(&w.dataBlock.buf, w.compression) - if err != nil { - w.err = err - return w.err - } - - // Write the index block. - w.indexBlock.finish() - indexBH, err := w.writeBlock(&w.indexBlock.buf, w.compression) - if err != nil { - w.err = err - return w.err - } - - // Write the table footer. - footer := w.scratch[:footerLen] - for i := range footer { - footer[i] = 0 - } - n := encodeBlockHandle(footer, metaindexBH) - encodeBlockHandle(footer[n:], indexBH) - copy(footer[footerLen-len(magic):], magic) - if _, err := w.writer.Write(footer); err != nil { - w.err = err - return w.err - } - w.offset += footerLen - - w.err = errors.New("leveldb/table: writer is closed") - return nil -} - -// NewWriter creates a new initialized table writer for the file. -// -// Table writer is not safe for concurrent use. -func NewWriter(f io.Writer, o *opt.Options) *Writer { - w := &Writer{ - writer: f, - cmp: o.GetComparer(), - filter: o.GetFilter(), - compression: o.GetCompression(), - blockSize: o.GetBlockSize(), - comparerScratch: make([]byte, 0), - } - // data block - w.dataBlock.restartInterval = o.GetBlockRestartInterval() - // The first 20-bytes are used for encoding block handle. - w.dataBlock.scratch = w.scratch[20:] - // index block - w.indexBlock.restartInterval = 1 - w.indexBlock.scratch = w.scratch[20:] - // filter block - if w.filter != nil { - w.filterBlock.generator = w.filter.NewGenerator() - w.filterBlock.flush(0) - } - return w -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/db.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil/db.go deleted file mode 100644 index ec3f177..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/db.go +++ /dev/null @@ -1,222 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package testutil - -import ( - "fmt" - "math/rand" - - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/util" -) - -type DB interface{} - -type Put interface { - TestPut(key []byte, value []byte) error -} - -type Delete interface { - TestDelete(key []byte) error -} - -type Find interface { - TestFind(key []byte) (rkey, rvalue []byte, err error) -} - -type Get interface { - TestGet(key []byte) (value []byte, err error) -} - -type Has interface { - TestHas(key []byte) (ret bool, err error) -} - -type NewIterator interface { - TestNewIterator(slice *util.Range) iterator.Iterator -} - -type DBAct int - -func (a DBAct) String() string { - switch a { - case DBNone: - return "none" - case DBPut: - return "put" - case DBOverwrite: - return "overwrite" - case DBDelete: - return "delete" - case DBDeleteNA: - return "delete_na" - } - return "unknown" -} - -const ( - DBNone DBAct = iota - DBPut - DBOverwrite - DBDelete - DBDeleteNA -) - -type DBTesting struct { - Rand *rand.Rand - DB interface { - Get - Put - Delete - } - PostFn func(t *DBTesting) - Deleted, Present KeyValue - Act, LastAct DBAct - ActKey, LastActKey []byte -} - -func (t *DBTesting) post() { - if t.PostFn != nil { - t.PostFn(t) - } -} - -func (t *DBTesting) setAct(act DBAct, key []byte) { - t.LastAct, t.Act = t.Act, act - t.LastActKey, t.ActKey = t.ActKey, key -} - -func (t *DBTesting) text() string { - return fmt.Sprintf("last action was <%v> %q, <%v> %q", t.LastAct, t.LastActKey, t.Act, t.ActKey) -} - -func (t *DBTesting) Text() string { - return "DBTesting " + t.text() -} - -func (t *DBTesting) TestPresentKV(key, value []byte) { - rvalue, err := t.DB.TestGet(key) - Expect(err).ShouldNot(HaveOccurred(), "Get on key %q, %s", key, t.text()) - Expect(rvalue).Should(Equal(value), "Value for key %q, %s", key, t.text()) -} - -func (t *DBTesting) TestAllPresent() { - t.Present.IterateShuffled(t.Rand, func(i int, key, value []byte) { - t.TestPresentKV(key, value) - }) -} - -func (t *DBTesting) TestDeletedKey(key []byte) { - _, err := t.DB.TestGet(key) - Expect(err).Should(Equal(errors.ErrNotFound), "Get on deleted key %q, %s", key, t.text()) -} - -func (t *DBTesting) TestAllDeleted() { - t.Deleted.IterateShuffled(t.Rand, func(i int, key, value []byte) { - t.TestDeletedKey(key) - }) -} - -func (t *DBTesting) TestAll() { - dn := t.Deleted.Len() - pn := t.Present.Len() - ShuffledIndex(t.Rand, dn+pn, 1, func(i int) { - if i >= dn { - key, value := t.Present.Index(i - dn) - t.TestPresentKV(key, value) - } else { - t.TestDeletedKey(t.Deleted.KeyAt(i)) - } - }) -} - -func (t *DBTesting) Put(key, value []byte) { - if new := t.Present.PutU(key, value); new { - t.setAct(DBPut, key) - } else { - t.setAct(DBOverwrite, key) - } - t.Deleted.Delete(key) - err := t.DB.TestPut(key, value) - Expect(err).ShouldNot(HaveOccurred(), t.Text()) - t.TestPresentKV(key, value) - t.post() -} - -func (t *DBTesting) PutRandom() bool { - if t.Deleted.Len() > 0 { - i := t.Rand.Intn(t.Deleted.Len()) - key, value := t.Deleted.Index(i) - t.Put(key, value) - return true - } - return false -} - -func (t *DBTesting) Delete(key []byte) { - if exist, value := t.Present.Delete(key); exist { - t.setAct(DBDelete, key) - t.Deleted.PutU(key, value) - } else { - t.setAct(DBDeleteNA, key) - } - err := t.DB.TestDelete(key) - Expect(err).ShouldNot(HaveOccurred(), t.Text()) - t.TestDeletedKey(key) - t.post() -} - -func (t *DBTesting) DeleteRandom() bool { - if t.Present.Len() > 0 { - i := t.Rand.Intn(t.Present.Len()) - t.Delete(t.Present.KeyAt(i)) - return true - } - return false -} - -func (t *DBTesting) RandomAct(round int) { - for i := 0; i < round; i++ { - if t.Rand.Int()%2 == 0 { - t.PutRandom() - } else { - t.DeleteRandom() - } - } -} - -func DoDBTesting(t *DBTesting) { - if t.Rand == nil { - t.Rand = NewRand() - } - - t.DeleteRandom() - t.PutRandom() - t.DeleteRandom() - t.DeleteRandom() - for i := t.Deleted.Len() / 2; i >= 0; i-- { - t.PutRandom() - } - t.RandomAct((t.Deleted.Len() + t.Present.Len()) * 10) - - // Additional iterator testing - if db, ok := t.DB.(NewIterator); ok { - iter := db.TestNewIterator(nil) - Expect(iter.Error()).NotTo(HaveOccurred()) - - it := IteratorTesting{ - KeyValue: t.Present, - Iter: iter, - } - - DoIteratorTesting(&it) - iter.Release() - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/ginkgo.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil/ginkgo.go deleted file mode 100644 index 82f3d0e..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/ginkgo.go +++ /dev/null @@ -1,21 +0,0 @@ -package testutil - -import ( - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" -) - -func RunSuite(t GinkgoTestingT, name string) { - RunDefer() - - SynchronizedBeforeSuite(func() []byte { - RunDefer("setup") - return nil - }, func(data []byte) {}) - SynchronizedAfterSuite(func() { - RunDefer("teardown") - }, func() {}) - - RegisterFailHandler(Fail) - RunSpecs(t, name) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/iter.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil/iter.go deleted file mode 100644 index df6d9db..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/iter.go +++ /dev/null @@ -1,327 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package testutil - -import ( - "fmt" - "math/rand" - - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/iterator" -) - -type IterAct int - -func (a IterAct) String() string { - switch a { - case IterNone: - return "none" - case IterFirst: - return "first" - case IterLast: - return "last" - case IterPrev: - return "prev" - case IterNext: - return "next" - case IterSeek: - return "seek" - case IterSOI: - return "soi" - case IterEOI: - return "eoi" - } - return "unknown" -} - -const ( - IterNone IterAct = iota - IterFirst - IterLast - IterPrev - IterNext - IterSeek - IterSOI - IterEOI -) - -type IteratorTesting struct { - KeyValue - Iter iterator.Iterator - Rand *rand.Rand - PostFn func(t *IteratorTesting) - Pos int - Act, LastAct IterAct - - once bool -} - -func (t *IteratorTesting) init() { - if !t.once { - t.Pos = -1 - t.once = true - } -} - -func (t *IteratorTesting) post() { - if t.PostFn != nil { - t.PostFn(t) - } -} - -func (t *IteratorTesting) setAct(act IterAct) { - t.LastAct, t.Act = t.Act, act -} - -func (t *IteratorTesting) text() string { - return fmt.Sprintf("at pos %d and last action was <%v> -> <%v>", t.Pos, t.LastAct, t.Act) -} - -func (t *IteratorTesting) Text() string { - return "IteratorTesting is " + t.text() -} - -func (t *IteratorTesting) IsFirst() bool { - t.init() - return t.Len() > 0 && t.Pos == 0 -} - -func (t *IteratorTesting) IsLast() bool { - t.init() - return t.Len() > 0 && t.Pos == t.Len()-1 -} - -func (t *IteratorTesting) TestKV() { - t.init() - key, value := t.Index(t.Pos) - Expect(t.Iter.Key()).NotTo(BeNil()) - Expect(t.Iter.Key()).Should(Equal(key), "Key is invalid, %s", t.text()) - Expect(t.Iter.Value()).Should(Equal(value), "Value for key %q, %s", key, t.text()) -} - -func (t *IteratorTesting) First() { - t.init() - t.setAct(IterFirst) - - ok := t.Iter.First() - Expect(t.Iter.Error()).ShouldNot(HaveOccurred()) - if t.Len() > 0 { - t.Pos = 0 - Expect(ok).Should(BeTrue(), t.Text()) - t.TestKV() - } else { - t.Pos = -1 - Expect(ok).ShouldNot(BeTrue(), t.Text()) - } - t.post() -} - -func (t *IteratorTesting) Last() { - t.init() - t.setAct(IterLast) - - ok := t.Iter.Last() - Expect(t.Iter.Error()).ShouldNot(HaveOccurred()) - if t.Len() > 0 { - t.Pos = t.Len() - 1 - Expect(ok).Should(BeTrue(), t.Text()) - t.TestKV() - } else { - t.Pos = 0 - Expect(ok).ShouldNot(BeTrue(), t.Text()) - } - t.post() -} - -func (t *IteratorTesting) Next() { - t.init() - t.setAct(IterNext) - - ok := t.Iter.Next() - Expect(t.Iter.Error()).ShouldNot(HaveOccurred()) - if t.Pos < t.Len()-1 { - t.Pos++ - Expect(ok).Should(BeTrue(), t.Text()) - t.TestKV() - } else { - t.Pos = t.Len() - Expect(ok).ShouldNot(BeTrue(), t.Text()) - } - t.post() -} - -func (t *IteratorTesting) Prev() { - t.init() - t.setAct(IterPrev) - - ok := t.Iter.Prev() - Expect(t.Iter.Error()).ShouldNot(HaveOccurred()) - if t.Pos > 0 { - t.Pos-- - Expect(ok).Should(BeTrue(), t.Text()) - t.TestKV() - } else { - t.Pos = -1 - Expect(ok).ShouldNot(BeTrue(), t.Text()) - } - t.post() -} - -func (t *IteratorTesting) Seek(i int) { - t.init() - t.setAct(IterSeek) - - key, _ := t.Index(i) - oldKey, _ := t.IndexOrNil(t.Pos) - - ok := t.Iter.Seek(key) - Expect(t.Iter.Error()).ShouldNot(HaveOccurred()) - Expect(ok).Should(BeTrue(), fmt.Sprintf("Seek from key %q to %q, to pos %d, %s", oldKey, key, i, t.text())) - - t.Pos = i - t.TestKV() - t.post() -} - -func (t *IteratorTesting) SeekInexact(i int) { - t.init() - t.setAct(IterSeek) - var key0 []byte - key1, _ := t.Index(i) - if i > 0 { - key0, _ = t.Index(i - 1) - } - key := BytesSeparator(key0, key1) - oldKey, _ := t.IndexOrNil(t.Pos) - - ok := t.Iter.Seek(key) - Expect(t.Iter.Error()).ShouldNot(HaveOccurred()) - Expect(ok).Should(BeTrue(), fmt.Sprintf("Seek from key %q to %q (%q), to pos %d, %s", oldKey, key, key1, i, t.text())) - - t.Pos = i - t.TestKV() - t.post() -} - -func (t *IteratorTesting) SeekKey(key []byte) { - t.init() - t.setAct(IterSeek) - oldKey, _ := t.IndexOrNil(t.Pos) - i := t.Search(key) - - ok := t.Iter.Seek(key) - Expect(t.Iter.Error()).ShouldNot(HaveOccurred()) - if i < t.Len() { - key_, _ := t.Index(i) - Expect(ok).Should(BeTrue(), fmt.Sprintf("Seek from key %q to %q (%q), to pos %d, %s", oldKey, key, key_, i, t.text())) - t.Pos = i - t.TestKV() - } else { - Expect(ok).ShouldNot(BeTrue(), fmt.Sprintf("Seek from key %q to %q, %s", oldKey, key, t.text())) - } - - t.Pos = i - t.post() -} - -func (t *IteratorTesting) SOI() { - t.init() - t.setAct(IterSOI) - Expect(t.Pos).Should(BeNumerically("<=", 0), t.Text()) - for i := 0; i < 3; i++ { - t.Prev() - } - t.post() -} - -func (t *IteratorTesting) EOI() { - t.init() - t.setAct(IterEOI) - Expect(t.Pos).Should(BeNumerically(">=", t.Len()-1), t.Text()) - for i := 0; i < 3; i++ { - t.Next() - } - t.post() -} - -func (t *IteratorTesting) WalkPrev(fn func(t *IteratorTesting)) { - t.init() - for old := t.Pos; t.Pos > 0; old = t.Pos { - fn(t) - Expect(t.Pos).Should(BeNumerically("<", old), t.Text()) - } -} - -func (t *IteratorTesting) WalkNext(fn func(t *IteratorTesting)) { - t.init() - for old := t.Pos; t.Pos < t.Len()-1; old = t.Pos { - fn(t) - Expect(t.Pos).Should(BeNumerically(">", old), t.Text()) - } -} - -func (t *IteratorTesting) PrevAll() { - t.WalkPrev(func(t *IteratorTesting) { - t.Prev() - }) -} - -func (t *IteratorTesting) NextAll() { - t.WalkNext(func(t *IteratorTesting) { - t.Next() - }) -} - -func DoIteratorTesting(t *IteratorTesting) { - if t.Rand == nil { - t.Rand = NewRand() - } - t.SOI() - t.NextAll() - t.First() - t.SOI() - t.NextAll() - t.EOI() - t.PrevAll() - t.Last() - t.EOI() - t.PrevAll() - t.SOI() - - t.NextAll() - t.PrevAll() - t.NextAll() - t.Last() - t.PrevAll() - t.First() - t.NextAll() - t.EOI() - - ShuffledIndex(t.Rand, t.Len(), 1, func(i int) { - t.Seek(i) - }) - - ShuffledIndex(t.Rand, t.Len(), 1, func(i int) { - t.SeekInexact(i) - }) - - ShuffledIndex(t.Rand, t.Len(), 1, func(i int) { - t.Seek(i) - if i%2 != 0 { - t.PrevAll() - t.SOI() - } else { - t.NextAll() - t.EOI() - } - }) - - for _, key := range []string{"", "foo", "bar", "\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff"} { - t.SeekKey([]byte(key)) - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/kv.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil/kv.go deleted file mode 100644 index 608cbf3..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/kv.go +++ /dev/null @@ -1,352 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package testutil - -import ( - "fmt" - "math/rand" - "sort" - "strings" - - "github.com/syndtr/goleveldb/leveldb/util" -) - -type KeyValueEntry struct { - key, value []byte -} - -type KeyValue struct { - entries []KeyValueEntry - nbytes int -} - -func (kv *KeyValue) Put(key, value []byte) { - if n := len(kv.entries); n > 0 && cmp.Compare(kv.entries[n-1].key, key) >= 0 { - panic(fmt.Sprintf("Put: keys are not in increasing order: %q, %q", kv.entries[n-1].key, key)) - } - kv.entries = append(kv.entries, KeyValueEntry{key, value}) - kv.nbytes += len(key) + len(value) -} - -func (kv *KeyValue) PutString(key, value string) { - kv.Put([]byte(key), []byte(value)) -} - -func (kv *KeyValue) PutU(key, value []byte) bool { - if i, exist := kv.Get(key); !exist { - if i < kv.Len() { - kv.entries = append(kv.entries[:i+1], kv.entries[i:]...) - kv.entries[i] = KeyValueEntry{key, value} - } else { - kv.entries = append(kv.entries, KeyValueEntry{key, value}) - } - kv.nbytes += len(key) + len(value) - return true - } else { - kv.nbytes += len(value) - len(kv.ValueAt(i)) - kv.entries[i].value = value - } - return false -} - -func (kv *KeyValue) PutUString(key, value string) bool { - return kv.PutU([]byte(key), []byte(value)) -} - -func (kv *KeyValue) Delete(key []byte) (exist bool, value []byte) { - i, exist := kv.Get(key) - if exist { - value = kv.entries[i].value - kv.DeleteIndex(i) - } - return -} - -func (kv *KeyValue) DeleteIndex(i int) bool { - if i < kv.Len() { - kv.nbytes -= len(kv.KeyAt(i)) + len(kv.ValueAt(i)) - kv.entries = append(kv.entries[:i], kv.entries[i+1:]...) - return true - } - return false -} - -func (kv KeyValue) Len() int { - return len(kv.entries) -} - -func (kv *KeyValue) Size() int { - return kv.nbytes -} - -func (kv KeyValue) KeyAt(i int) []byte { - return kv.entries[i].key -} - -func (kv KeyValue) ValueAt(i int) []byte { - return kv.entries[i].value -} - -func (kv KeyValue) Index(i int) (key, value []byte) { - if i < 0 || i >= len(kv.entries) { - panic(fmt.Sprintf("Index #%d: out of range", i)) - } - return kv.entries[i].key, kv.entries[i].value -} - -func (kv KeyValue) IndexInexact(i int) (key_, key, value []byte) { - key, value = kv.Index(i) - var key0 []byte - var key1 = kv.KeyAt(i) - if i > 0 { - key0 = kv.KeyAt(i - 1) - } - key_ = BytesSeparator(key0, key1) - return -} - -func (kv KeyValue) IndexOrNil(i int) (key, value []byte) { - if i >= 0 && i < len(kv.entries) { - return kv.entries[i].key, kv.entries[i].value - } - return nil, nil -} - -func (kv KeyValue) IndexString(i int) (key, value string) { - key_, _value := kv.Index(i) - return string(key_), string(_value) -} - -func (kv KeyValue) Search(key []byte) int { - return sort.Search(kv.Len(), func(i int) bool { - return cmp.Compare(kv.KeyAt(i), key) >= 0 - }) -} - -func (kv KeyValue) SearchString(key string) int { - return kv.Search([]byte(key)) -} - -func (kv KeyValue) Get(key []byte) (i int, exist bool) { - i = kv.Search(key) - if i < kv.Len() && cmp.Compare(kv.KeyAt(i), key) == 0 { - exist = true - } - return -} - -func (kv KeyValue) GetString(key string) (i int, exist bool) { - return kv.Get([]byte(key)) -} - -func (kv KeyValue) Iterate(fn func(i int, key, value []byte)) { - for i, x := range kv.entries { - fn(i, x.key, x.value) - } -} - -func (kv KeyValue) IterateString(fn func(i int, key, value string)) { - kv.Iterate(func(i int, key, value []byte) { - fn(i, string(key), string(value)) - }) -} - -func (kv KeyValue) IterateShuffled(rnd *rand.Rand, fn func(i int, key, value []byte)) { - ShuffledIndex(rnd, kv.Len(), 1, func(i int) { - fn(i, kv.entries[i].key, kv.entries[i].value) - }) -} - -func (kv KeyValue) IterateShuffledString(rnd *rand.Rand, fn func(i int, key, value string)) { - kv.IterateShuffled(rnd, func(i int, key, value []byte) { - fn(i, string(key), string(value)) - }) -} - -func (kv KeyValue) IterateInexact(fn func(i int, key_, key, value []byte)) { - for i := range kv.entries { - key_, key, value := kv.IndexInexact(i) - fn(i, key_, key, value) - } -} - -func (kv KeyValue) IterateInexactString(fn func(i int, key_, key, value string)) { - kv.IterateInexact(func(i int, key_, key, value []byte) { - fn(i, string(key_), string(key), string(value)) - }) -} - -func (kv KeyValue) Clone() KeyValue { - return KeyValue{append([]KeyValueEntry{}, kv.entries...), kv.nbytes} -} - -func (kv KeyValue) Slice(start, limit int) KeyValue { - if start < 0 || limit > kv.Len() { - panic(fmt.Sprintf("Slice %d .. %d: out of range", start, limit)) - } else if limit < start { - panic(fmt.Sprintf("Slice %d .. %d: invalid range", start, limit)) - } - return KeyValue{append([]KeyValueEntry{}, kv.entries[start:limit]...), kv.nbytes} -} - -func (kv KeyValue) SliceKey(start, limit []byte) KeyValue { - start_ := 0 - limit_ := kv.Len() - if start != nil { - start_ = kv.Search(start) - } - if limit != nil { - limit_ = kv.Search(limit) - } - return kv.Slice(start_, limit_) -} - -func (kv KeyValue) SliceKeyString(start, limit string) KeyValue { - return kv.SliceKey([]byte(start), []byte(limit)) -} - -func (kv KeyValue) SliceRange(r *util.Range) KeyValue { - if r != nil { - return kv.SliceKey(r.Start, r.Limit) - } - return kv.Clone() -} - -func (kv KeyValue) Range(start, limit int) (r util.Range) { - if kv.Len() > 0 { - if start == kv.Len() { - r.Start = BytesAfter(kv.KeyAt(start - 1)) - } else { - r.Start = kv.KeyAt(start) - } - } - if limit < kv.Len() { - r.Limit = kv.KeyAt(limit) - } - return -} - -func KeyValue_EmptyKey() *KeyValue { - kv := &KeyValue{} - kv.PutString("", "v") - return kv -} - -func KeyValue_EmptyValue() *KeyValue { - kv := &KeyValue{} - kv.PutString("abc", "") - kv.PutString("abcd", "") - return kv -} - -func KeyValue_OneKeyValue() *KeyValue { - kv := &KeyValue{} - kv.PutString("abc", "v") - return kv -} - -func KeyValue_BigValue() *KeyValue { - kv := &KeyValue{} - kv.PutString("big1", strings.Repeat("1", 200000)) - return kv -} - -func KeyValue_SpecialKey() *KeyValue { - kv := &KeyValue{} - kv.PutString("\xff\xff", "v3") - return kv -} - -func KeyValue_MultipleKeyValue() *KeyValue { - kv := &KeyValue{} - kv.PutString("a", "v") - kv.PutString("aa", "v1") - kv.PutString("aaa", "v2") - kv.PutString("aaacccccccccc", "v2") - kv.PutString("aaaccccccccccd", "v3") - kv.PutString("aaaccccccccccf", "v4") - kv.PutString("aaaccccccccccfg", "v5") - kv.PutString("ab", "v6") - kv.PutString("abc", "v7") - kv.PutString("abcd", "v8") - kv.PutString("accccccccccccccc", "v9") - kv.PutString("b", "v10") - kv.PutString("bb", "v11") - kv.PutString("bc", "v12") - kv.PutString("c", "v13") - kv.PutString("c1", "v13") - kv.PutString("czzzzzzzzzzzzzz", "v14") - kv.PutString("fffffffffffffff", "v15") - kv.PutString("g11", "v15") - kv.PutString("g111", "v15") - kv.PutString("g111\xff", "v15") - kv.PutString("zz", "v16") - kv.PutString("zzzzzzz", "v16") - kv.PutString("zzzzzzzzzzzzzzzz", "v16") - return kv -} - -var keymap = []byte("012345678ABCDEFGHIJKLMNOPQRSTUVWXYabcdefghijklmnopqrstuvwxy") - -func KeyValue_Generate(rnd *rand.Rand, n, incr, minlen, maxlen, vminlen, vmaxlen int) *KeyValue { - if rnd == nil { - rnd = NewRand() - } - if maxlen < minlen { - panic("max len should >= min len") - } - - rrand := func(min, max int) int { - if min == max { - return max - } - return rnd.Intn(max-min) + min - } - - kv := &KeyValue{} - endC := byte(len(keymap) - incr) - gen := make([]byte, 0, maxlen) - for i := 0; i < n; i++ { - m := rrand(minlen, maxlen) - last := gen - retry: - gen = last[:m] - if k := len(last); m > k { - for j := k; j < m; j++ { - gen[j] = 0 - } - } else { - for j := m - 1; j >= 0; j-- { - c := last[j] - if c == endC { - continue - } - gen[j] = c + byte(incr) - for j++; j < m; j++ { - gen[j] = 0 - } - goto ok - } - if m < maxlen { - m++ - goto retry - } - panic(fmt.Sprintf("only able to generate %d keys out of %d keys, try increasing max len", kv.Len(), n)) - ok: - } - key := make([]byte, m) - for j := 0; j < m; j++ { - key[j] = keymap[gen[j]] - } - value := make([]byte, rrand(vminlen, vmaxlen)) - for n := copy(value, []byte(fmt.Sprintf("v%d", i))); n < len(value); n++ { - value[n] = 'x' - } - kv.Put(key, value) - } - return kv -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/kvtest.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil/kvtest.go deleted file mode 100644 index f7563dc..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/kvtest.go +++ /dev/null @@ -1,212 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package testutil - -import ( - "fmt" - "math/rand" - - . "github.com/onsi/ginkgo" - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/util" -) - -func TestFind(db Find, kv KeyValue) { - ShuffledIndex(nil, kv.Len(), 1, func(i int) { - key_, key, value := kv.IndexInexact(i) - - // Using exact key. - rkey, rvalue, err := db.TestFind(key) - Expect(err).ShouldNot(HaveOccurred(), "Error for exact key %q", key) - Expect(rkey).Should(Equal(key), "Key") - Expect(rvalue).Should(Equal(value), "Value for exact key %q", key) - - // Using inexact key. - rkey, rvalue, err = db.TestFind(key_) - Expect(err).ShouldNot(HaveOccurred(), "Error for inexact key %q (%q)", key_, key) - Expect(rkey).Should(Equal(key), "Key for inexact key %q (%q)", key_, key) - Expect(rvalue).Should(Equal(value), "Value for inexact key %q (%q)", key_, key) - }) -} - -func TestFindAfterLast(db Find, kv KeyValue) { - var key []byte - if kv.Len() > 0 { - key_, _ := kv.Index(kv.Len() - 1) - key = BytesAfter(key_) - } - rkey, _, err := db.TestFind(key) - Expect(err).Should(HaveOccurred(), "Find for key %q yield key %q", key, rkey) - Expect(err).Should(Equal(errors.ErrNotFound)) -} - -func TestGet(db Get, kv KeyValue) { - ShuffledIndex(nil, kv.Len(), 1, func(i int) { - key_, key, value := kv.IndexInexact(i) - - // Using exact key. - rvalue, err := db.TestGet(key) - Expect(err).ShouldNot(HaveOccurred(), "Error for key %q", key) - Expect(rvalue).Should(Equal(value), "Value for key %q", key) - - // Using inexact key. - if len(key_) > 0 { - _, err = db.TestGet(key_) - Expect(err).Should(HaveOccurred(), "Error for key %q", key_) - Expect(err).Should(Equal(errors.ErrNotFound)) - } - }) -} - -func TestHas(db Has, kv KeyValue) { - ShuffledIndex(nil, kv.Len(), 1, func(i int) { - key_, key, _ := kv.IndexInexact(i) - - // Using exact key. - ret, err := db.TestHas(key) - Expect(err).ShouldNot(HaveOccurred(), "Error for key %q", key) - Expect(ret).Should(BeTrue(), "False for key %q", key) - - // Using inexact key. - if len(key_) > 0 { - ret, err = db.TestHas(key_) - Expect(err).ShouldNot(HaveOccurred(), "Error for key %q", key_) - Expect(ret).ShouldNot(BeTrue(), "True for key %q", key) - } - }) -} - -func TestIter(db NewIterator, r *util.Range, kv KeyValue) { - iter := db.TestNewIterator(r) - Expect(iter.Error()).ShouldNot(HaveOccurred()) - - t := IteratorTesting{ - KeyValue: kv, - Iter: iter, - } - - DoIteratorTesting(&t) - iter.Release() -} - -func KeyValueTesting(rnd *rand.Rand, kv KeyValue, p DB, setup func(KeyValue) DB, teardown func(DB)) { - if rnd == nil { - rnd = NewRand() - } - - if p == nil { - BeforeEach(func() { - p = setup(kv) - }) - if teardown != nil { - AfterEach(func() { - teardown(p) - }) - } - } - - It("Should find all keys with Find", func() { - if db, ok := p.(Find); ok { - TestFind(db, kv) - } - }) - - It("Should return error if Find on key after the last", func() { - if db, ok := p.(Find); ok { - TestFindAfterLast(db, kv) - } - }) - - It("Should only find exact key with Get", func() { - if db, ok := p.(Get); ok { - TestGet(db, kv) - } - }) - - It("Should only find present key with Has", func() { - if db, ok := p.(Has); ok { - TestHas(db, kv) - } - }) - - It("Should iterates and seeks correctly", func(done Done) { - if db, ok := p.(NewIterator); ok { - TestIter(db, nil, kv.Clone()) - } - done <- true - }, 30.0) - - It("Should iterates and seeks slice correctly", func(done Done) { - if db, ok := p.(NewIterator); ok { - RandomIndex(rnd, kv.Len(), Min(kv.Len(), 50), func(i int) { - type slice struct { - r *util.Range - start, limit int - } - - key_, _, _ := kv.IndexInexact(i) - for _, x := range []slice{ - {&util.Range{Start: key_, Limit: nil}, i, kv.Len()}, - {&util.Range{Start: nil, Limit: key_}, 0, i}, - } { - By(fmt.Sprintf("Random index of %d .. %d", x.start, x.limit), func() { - TestIter(db, x.r, kv.Slice(x.start, x.limit)) - }) - } - }) - } - done <- true - }, 200.0) - - It("Should iterates and seeks slice correctly", func(done Done) { - if db, ok := p.(NewIterator); ok { - RandomRange(rnd, kv.Len(), Min(kv.Len(), 50), func(start, limit int) { - By(fmt.Sprintf("Random range of %d .. %d", start, limit), func() { - r := kv.Range(start, limit) - TestIter(db, &r, kv.Slice(start, limit)) - }) - }) - } - done <- true - }, 200.0) -} - -func AllKeyValueTesting(rnd *rand.Rand, body, setup func(KeyValue) DB, teardown func(DB)) { - Test := func(kv *KeyValue) func() { - return func() { - var p DB - if setup != nil { - Defer("setup", func() { - p = setup(*kv) - }) - } - if teardown != nil { - Defer("teardown", func() { - teardown(p) - }) - } - if body != nil { - p = body(*kv) - } - KeyValueTesting(rnd, *kv, p, func(KeyValue) DB { - return p - }, nil) - } - } - - Describe("with no key/value (empty)", Test(&KeyValue{})) - Describe("with empty key", Test(KeyValue_EmptyKey())) - Describe("with empty value", Test(KeyValue_EmptyValue())) - Describe("with one key/value", Test(KeyValue_OneKeyValue())) - Describe("with big value", Test(KeyValue_BigValue())) - Describe("with special key", Test(KeyValue_SpecialKey())) - Describe("with multiple key/value", Test(KeyValue_MultipleKeyValue())) - Describe("with generated key/value 2-incr", Test(KeyValue_Generate(nil, 120, 2, 1, 50, 10, 120))) - Describe("with generated key/value 3-incr", Test(KeyValue_Generate(nil, 120, 3, 1, 50, 10, 120))) -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/storage.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil/storage.go deleted file mode 100644 index 581daf3..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/storage.go +++ /dev/null @@ -1,693 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package testutil - -import ( - "bytes" - "fmt" - "io" - "math/rand" - "os" - "path/filepath" - "runtime" - "strings" - "sync" - - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/storage" -) - -var ( - storageMu sync.Mutex - storageUseFS = true - storageKeepFS = false - storageNum int -) - -type StorageMode int - -const ( - ModeOpen StorageMode = 1 << iota - ModeCreate - ModeRemove - ModeRename - ModeRead - ModeWrite - ModeSync - ModeClose -) - -const ( - modeOpen = iota - modeCreate - modeRemove - modeRename - modeRead - modeWrite - modeSync - modeClose - - modeCount -) - -const ( - typeManifest = iota - typeJournal - typeTable - typeTemp - - typeCount -) - -const flattenCount = modeCount * typeCount - -func flattenType(m StorageMode, t storage.FileType) int { - var x int - switch m { - case ModeOpen: - x = modeOpen - case ModeCreate: - x = modeCreate - case ModeRemove: - x = modeRemove - case ModeRename: - x = modeRename - case ModeRead: - x = modeRead - case ModeWrite: - x = modeWrite - case ModeSync: - x = modeSync - case ModeClose: - x = modeClose - default: - panic("invalid storage mode") - } - x *= typeCount - switch t { - case storage.TypeManifest: - return x + typeManifest - case storage.TypeJournal: - return x + typeJournal - case storage.TypeTable: - return x + typeTable - case storage.TypeTemp: - return x + typeTemp - default: - panic("invalid file type") - } -} - -func listFlattenType(m StorageMode, t storage.FileType) []int { - ret := make([]int, 0, flattenCount) - add := func(x int) { - x *= typeCount - switch { - case t&storage.TypeManifest != 0: - ret = append(ret, x+typeManifest) - case t&storage.TypeJournal != 0: - ret = append(ret, x+typeJournal) - case t&storage.TypeTable != 0: - ret = append(ret, x+typeTable) - case t&storage.TypeTemp != 0: - ret = append(ret, x+typeTemp) - } - } - switch { - case m&ModeOpen != 0: - add(modeOpen) - case m&ModeCreate != 0: - add(modeCreate) - case m&ModeRemove != 0: - add(modeRemove) - case m&ModeRename != 0: - add(modeRename) - case m&ModeRead != 0: - add(modeRead) - case m&ModeWrite != 0: - add(modeWrite) - case m&ModeSync != 0: - add(modeSync) - case m&ModeClose != 0: - add(modeClose) - } - return ret -} - -func packFile(fd storage.FileDesc) uint64 { - if fd.Num>>(63-typeCount) != 0 { - panic("overflow") - } - return uint64(fd.Num<> typeCount)} -} - -type emulatedError struct { - err error -} - -func (err emulatedError) Error() string { - return fmt.Sprintf("emulated storage error: %v", err.err) -} - -type storageLock struct { - s *Storage - l storage.Locker -} - -func (l storageLock) Unlock() { - l.l.Unlock() - l.s.logI("storage lock released") -} - -type reader struct { - s *Storage - fd storage.FileDesc - storage.Reader -} - -func (r *reader) Read(p []byte) (n int, err error) { - err = r.s.emulateError(ModeRead, r.fd.Type) - if err == nil { - r.s.stall(ModeRead, r.fd.Type) - n, err = r.Reader.Read(p) - } - r.s.count(ModeRead, r.fd.Type, n) - if err != nil && err != io.EOF { - r.s.logI("read error, fd=%s n=%d err=%v", r.fd, n, err) - } - return -} - -func (r *reader) ReadAt(p []byte, off int64) (n int, err error) { - err = r.s.emulateError(ModeRead, r.fd.Type) - if err == nil { - r.s.stall(ModeRead, r.fd.Type) - n, err = r.Reader.ReadAt(p, off) - } - r.s.count(ModeRead, r.fd.Type, n) - if err != nil && err != io.EOF { - r.s.logI("readAt error, fd=%s offset=%d n=%d err=%v", r.fd, off, n, err) - } - return -} - -func (r *reader) Close() (err error) { - return r.s.fileClose(r.fd, r.Reader) -} - -type writer struct { - s *Storage - fd storage.FileDesc - storage.Writer -} - -func (w *writer) Write(p []byte) (n int, err error) { - err = w.s.emulateError(ModeWrite, w.fd.Type) - if err == nil { - w.s.stall(ModeWrite, w.fd.Type) - n, err = w.Writer.Write(p) - } - w.s.count(ModeWrite, w.fd.Type, n) - if err != nil && err != io.EOF { - w.s.logI("write error, fd=%s n=%d err=%v", w.fd, n, err) - } - return -} - -func (w *writer) Sync() (err error) { - err = w.s.emulateError(ModeSync, w.fd.Type) - if err == nil { - w.s.stall(ModeSync, w.fd.Type) - err = w.Writer.Sync() - } - w.s.count(ModeSync, w.fd.Type, 0) - if err != nil { - w.s.logI("sync error, fd=%s err=%v", w.fd, err) - } - return -} - -func (w *writer) Close() (err error) { - return w.s.fileClose(w.fd, w.Writer) -} - -type Storage struct { - storage.Storage - path string - onClose func() (preserve bool, err error) - onLog func(str string) - - lmu sync.Mutex - lb bytes.Buffer - - mu sync.Mutex - rand *rand.Rand - // Open files, true=writer, false=reader - opens map[uint64]bool - counters [flattenCount]int - bytesCounter [flattenCount]int64 - emulatedError [flattenCount]error - emulatedErrorOnce [flattenCount]bool - emulatedRandomError [flattenCount]error - emulatedRandomErrorProb [flattenCount]float64 - stallCond sync.Cond - stalled [flattenCount]bool -} - -func (s *Storage) log(skip int, str string) { - s.lmu.Lock() - defer s.lmu.Unlock() - _, file, line, ok := runtime.Caller(skip + 2) - if ok { - // Truncate file name at last file name separator. - if index := strings.LastIndex(file, "/"); index >= 0 { - file = file[index+1:] - } else if index = strings.LastIndex(file, "\\"); index >= 0 { - file = file[index+1:] - } - } else { - file = "???" - line = 1 - } - fmt.Fprintf(&s.lb, "%s:%d: ", file, line) - lines := strings.Split(str, "\n") - if l := len(lines); l > 1 && lines[l-1] == "" { - lines = lines[:l-1] - } - for i, line := range lines { - if i > 0 { - s.lb.WriteString("\n\t") - } - s.lb.WriteString(line) - } - if s.onLog != nil { - s.onLog(s.lb.String()) - s.lb.Reset() - } else { - s.lb.WriteByte('\n') - } -} - -func (s *Storage) logISkip(skip int, format string, args ...interface{}) { - pc, _, _, ok := runtime.Caller(skip + 1) - if ok { - if f := runtime.FuncForPC(pc); f != nil { - fname := f.Name() - if index := strings.LastIndex(fname, "."); index >= 0 { - fname = fname[index+1:] - } - format = fname + ": " + format - } - } - s.log(skip+1, fmt.Sprintf(format, args...)) -} - -func (s *Storage) logI(format string, args ...interface{}) { - s.logISkip(1, format, args...) -} - -func (s *Storage) OnLog(onLog func(log string)) { - s.lmu.Lock() - s.onLog = onLog - if s.lb.Len() != 0 { - log := s.lb.String() - s.onLog(log[:len(log)-1]) - s.lb.Reset() - } - s.lmu.Unlock() -} - -func (s *Storage) Log(str string) { - s.log(1, "Log: "+str) - s.Storage.Log(str) -} - -func (s *Storage) Lock() (l storage.Locker, err error) { - l, err = s.Storage.Lock() - if err != nil { - s.logI("storage locking failed, err=%v", err) - } else { - s.logI("storage locked") - l = storageLock{s, l} - } - return -} - -func (s *Storage) List(t storage.FileType) (fds []storage.FileDesc, err error) { - fds, err = s.Storage.List(t) - if err != nil { - s.logI("list failed, err=%v", err) - return - } - s.logI("list, type=0x%x count=%d", int(t), len(fds)) - return -} - -func (s *Storage) GetMeta() (fd storage.FileDesc, err error) { - fd, err = s.Storage.GetMeta() - if err != nil { - if !os.IsNotExist(err) { - s.logI("get meta failed, err=%v", err) - } - return - } - s.logI("get meta, fd=%s", fd) - return -} - -func (s *Storage) SetMeta(fd storage.FileDesc) error { - ExpectWithOffset(1, fd.Type).To(Equal(storage.TypeManifest)) - err := s.Storage.SetMeta(fd) - if err != nil { - s.logI("set meta failed, fd=%s err=%v", fd, err) - } else { - s.logI("set meta, fd=%s", fd) - } - return err -} - -func (s *Storage) fileClose(fd storage.FileDesc, closer io.Closer) (err error) { - err = s.emulateError(ModeClose, fd.Type) - if err == nil { - s.stall(ModeClose, fd.Type) - } - x := packFile(fd) - s.mu.Lock() - defer s.mu.Unlock() - if err == nil { - ExpectWithOffset(2, s.opens).To(HaveKey(x), "File closed, fd=%s", fd) - err = closer.Close() - } - s.countNB(ModeClose, fd.Type, 0) - writer := s.opens[x] - if err != nil { - s.logISkip(1, "file close failed, fd=%s writer=%v err=%v", fd, writer, err) - } else { - s.logISkip(1, "file closed, fd=%s writer=%v", fd, writer) - delete(s.opens, x) - } - return -} - -func (s *Storage) assertOpen(fd storage.FileDesc) { - x := packFile(fd) - ExpectWithOffset(2, s.opens).NotTo(HaveKey(x), "File open, fd=%s writer=%v", fd, s.opens[x]) -} - -func (s *Storage) Open(fd storage.FileDesc) (r storage.Reader, err error) { - err = s.emulateError(ModeOpen, fd.Type) - if err == nil { - s.stall(ModeOpen, fd.Type) - } - s.mu.Lock() - defer s.mu.Unlock() - if err == nil { - s.assertOpen(fd) - s.countNB(ModeOpen, fd.Type, 0) - r, err = s.Storage.Open(fd) - } - if err != nil { - s.logI("file open failed, fd=%s err=%v", fd, err) - } else { - s.logI("file opened, fd=%s", fd) - s.opens[packFile(fd)] = false - r = &reader{s, fd, r} - } - return -} - -func (s *Storage) Create(fd storage.FileDesc) (w storage.Writer, err error) { - err = s.emulateError(ModeCreate, fd.Type) - if err == nil { - s.stall(ModeCreate, fd.Type) - } - s.mu.Lock() - defer s.mu.Unlock() - if err == nil { - s.assertOpen(fd) - s.countNB(ModeCreate, fd.Type, 0) - w, err = s.Storage.Create(fd) - } - if err != nil { - s.logI("file create failed, fd=%s err=%v", fd, err) - } else { - s.logI("file created, fd=%s", fd) - s.opens[packFile(fd)] = true - w = &writer{s, fd, w} - } - return -} - -func (s *Storage) Remove(fd storage.FileDesc) (err error) { - err = s.emulateError(ModeRemove, fd.Type) - if err == nil { - s.stall(ModeRemove, fd.Type) - } - s.mu.Lock() - defer s.mu.Unlock() - if err == nil { - s.assertOpen(fd) - s.countNB(ModeRemove, fd.Type, 0) - err = s.Storage.Remove(fd) - } - if err != nil { - s.logI("file remove failed, fd=%s err=%v", fd, err) - } else { - s.logI("file removed, fd=%s", fd) - } - return -} - -func (s *Storage) ForceRemove(fd storage.FileDesc) (err error) { - s.countNB(ModeRemove, fd.Type, 0) - if err = s.Storage.Remove(fd); err != nil { - s.logI("file remove failed (forced), fd=%s err=%v", fd, err) - } else { - s.logI("file removed (forced), fd=%s", fd) - } - return -} - -func (s *Storage) Rename(oldfd, newfd storage.FileDesc) (err error) { - err = s.emulateError(ModeRename, oldfd.Type) - if err == nil { - s.stall(ModeRename, oldfd.Type) - } - s.mu.Lock() - defer s.mu.Unlock() - if err == nil { - s.assertOpen(oldfd) - s.assertOpen(newfd) - s.countNB(ModeRename, oldfd.Type, 0) - err = s.Storage.Rename(oldfd, newfd) - } - if err != nil { - s.logI("file rename failed, oldfd=%s newfd=%s err=%v", oldfd, newfd, err) - } else { - s.logI("file renamed, oldfd=%s newfd=%s", oldfd, newfd) - } - return -} - -func (s *Storage) ForceRename(oldfd, newfd storage.FileDesc) (err error) { - s.countNB(ModeRename, oldfd.Type, 0) - if err = s.Storage.Rename(oldfd, newfd); err != nil { - s.logI("file rename failed (forced), oldfd=%s newfd=%s err=%v", oldfd, newfd, err) - } else { - s.logI("file renamed (forced), oldfd=%s newfd=%s", oldfd, newfd) - } - return -} - -func (s *Storage) openFiles() string { - out := "Open files:" - for x, writer := range s.opens { - fd := unpackFile(x) - out += fmt.Sprintf("\n · fd=%s writer=%v", fd, writer) - } - return out -} - -func (s *Storage) CloseCheck() { - s.mu.Lock() - defer s.mu.Unlock() - ExpectWithOffset(1, s.opens).To(BeEmpty(), s.openFiles()) -} - -func (s *Storage) OnClose(onClose func() (preserve bool, err error)) { - s.mu.Lock() - s.onClose = onClose - s.mu.Unlock() -} - -func (s *Storage) Close() error { - s.mu.Lock() - defer s.mu.Unlock() - ExpectWithOffset(1, s.opens).To(BeEmpty(), s.openFiles()) - err := s.Storage.Close() - if err != nil { - s.logI("storage closing failed, err=%v", err) - } else { - s.logI("storage closed") - } - var preserve bool - if s.onClose != nil { - var err0 error - if preserve, err0 = s.onClose(); err0 != nil { - s.logI("onClose error, err=%v", err0) - } - } - if s.path != "" { - if storageKeepFS || preserve { - s.logI("storage is preserved, path=%v", s.path) - } else { - if err1 := os.RemoveAll(s.path); err1 != nil { - s.logI("cannot remove storage, err=%v", err1) - } else { - s.logI("storage has been removed") - } - } - } - return err -} - -func (s *Storage) countNB(m StorageMode, t storage.FileType, n int) { - s.counters[flattenType(m, t)]++ - s.bytesCounter[flattenType(m, t)] += int64(n) -} - -func (s *Storage) count(m StorageMode, t storage.FileType, n int) { - s.mu.Lock() - defer s.mu.Unlock() - s.countNB(m, t, n) -} - -func (s *Storage) ResetCounter(m StorageMode, t storage.FileType) { - for _, x := range listFlattenType(m, t) { - s.counters[x] = 0 - s.bytesCounter[x] = 0 - } -} - -func (s *Storage) Counter(m StorageMode, t storage.FileType) (count int, bytes int64) { - for _, x := range listFlattenType(m, t) { - count += s.counters[x] - bytes += s.bytesCounter[x] - } - return -} - -func (s *Storage) emulateError(m StorageMode, t storage.FileType) error { - s.mu.Lock() - defer s.mu.Unlock() - x := flattenType(m, t) - if err := s.emulatedError[x]; err != nil { - if s.emulatedErrorOnce[x] { - s.emulatedError[x] = nil - } - return emulatedError{err} - } - if err := s.emulatedRandomError[x]; err != nil && s.rand.Float64() < s.emulatedRandomErrorProb[x] { - return emulatedError{err} - } - return nil -} - -func (s *Storage) EmulateError(m StorageMode, t storage.FileType, err error) { - s.mu.Lock() - defer s.mu.Unlock() - for _, x := range listFlattenType(m, t) { - s.emulatedError[x] = err - s.emulatedErrorOnce[x] = false - } -} - -func (s *Storage) EmulateErrorOnce(m StorageMode, t storage.FileType, err error) { - s.mu.Lock() - defer s.mu.Unlock() - for _, x := range listFlattenType(m, t) { - s.emulatedError[x] = err - s.emulatedErrorOnce[x] = true - } -} - -func (s *Storage) EmulateRandomError(m StorageMode, t storage.FileType, prob float64, err error) { - s.mu.Lock() - defer s.mu.Unlock() - for _, x := range listFlattenType(m, t) { - s.emulatedRandomError[x] = err - s.emulatedRandomErrorProb[x] = prob - } -} - -func (s *Storage) stall(m StorageMode, t storage.FileType) { - x := flattenType(m, t) - s.mu.Lock() - defer s.mu.Unlock() - for s.stalled[x] { - s.stallCond.Wait() - } -} - -func (s *Storage) Stall(m StorageMode, t storage.FileType) { - s.mu.Lock() - defer s.mu.Unlock() - for _, x := range listFlattenType(m, t) { - s.stalled[x] = true - } -} - -func (s *Storage) Release(m StorageMode, t storage.FileType) { - s.mu.Lock() - defer s.mu.Unlock() - for _, x := range listFlattenType(m, t) { - s.stalled[x] = false - } - s.stallCond.Broadcast() -} - -func NewStorage() *Storage { - var ( - stor storage.Storage - path string - ) - if storageUseFS { - for { - storageMu.Lock() - num := storageNum - storageNum++ - storageMu.Unlock() - path = filepath.Join(os.TempDir(), fmt.Sprintf("goleveldb-test%d0%d0%d", os.Getuid(), os.Getpid(), num)) - if _, err := os.Stat(path); os.IsNotExist(err) { - stor, err = storage.OpenFile(path, false) - ExpectWithOffset(1, err).NotTo(HaveOccurred(), "creating storage at %s", path) - break - } - } - } else { - stor = storage.NewMemStorage() - } - s := &Storage{ - Storage: stor, - path: path, - rand: NewRand(), - opens: make(map[uint64]bool), - } - s.stallCond.L = &s.mu - if s.path != "" { - s.logI("using FS storage") - s.logI("storage path: %s", s.path) - } else { - s.logI("using MEM storage") - } - return s -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/util.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil/util.go deleted file mode 100644 index 97c5294..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil/util.go +++ /dev/null @@ -1,171 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package testutil - -import ( - "bytes" - "flag" - "math/rand" - "reflect" - "sync" - - "github.com/onsi/ginkgo/config" - - "github.com/syndtr/goleveldb/leveldb/comparer" -) - -var ( - runfn = make(map[string][]func()) - runmu sync.Mutex -) - -func Defer(args ...interface{}) bool { - var ( - group string - fn func() - ) - for _, arg := range args { - v := reflect.ValueOf(arg) - switch v.Kind() { - case reflect.String: - group = v.String() - case reflect.Func: - r := reflect.ValueOf(&fn).Elem() - r.Set(v) - } - } - if fn != nil { - runmu.Lock() - runfn[group] = append(runfn[group], fn) - runmu.Unlock() - } - return true -} - -func RunDefer(groups ...string) bool { - if len(groups) == 0 { - groups = append(groups, "") - } - runmu.Lock() - var runfn_ []func() - for _, group := range groups { - runfn_ = append(runfn_, runfn[group]...) - delete(runfn, group) - } - runmu.Unlock() - for _, fn := range runfn_ { - fn() - } - return runfn_ != nil -} - -func RandomSeed() int64 { - if !flag.Parsed() { - panic("random seed not initialized") - } - return config.GinkgoConfig.RandomSeed -} - -func NewRand() *rand.Rand { - return rand.New(rand.NewSource(RandomSeed())) -} - -var cmp = comparer.DefaultComparer - -func BytesSeparator(a, b []byte) []byte { - if bytes.Equal(a, b) { - return b - } - i, n := 0, len(a) - if n > len(b) { - n = len(b) - } - for ; i < n && (a[i] == b[i]); i++ { - } - x := append([]byte{}, a[:i]...) - if i < n { - if c := a[i] + 1; c < b[i] { - return append(x, c) - } - x = append(x, a[i]) - i++ - } - for ; i < len(a); i++ { - if c := a[i]; c < 0xff { - return append(x, c+1) - } else { - x = append(x, c) - } - } - if len(b) > i && b[i] > 0 { - return append(x, b[i]-1) - } - return append(x, 'x') -} - -func BytesAfter(b []byte) []byte { - var x []byte - for _, c := range b { - if c < 0xff { - return append(x, c+1) - } else { - x = append(x, c) - } - } - return append(x, 'x') -} - -func RandomIndex(rnd *rand.Rand, n, round int, fn func(i int)) { - if rnd == nil { - rnd = NewRand() - } - for x := 0; x < round; x++ { - fn(rnd.Intn(n)) - } - return -} - -func ShuffledIndex(rnd *rand.Rand, n, round int, fn func(i int)) { - if rnd == nil { - rnd = NewRand() - } - for x := 0; x < round; x++ { - for _, i := range rnd.Perm(n) { - fn(i) - } - } - return -} - -func RandomRange(rnd *rand.Rand, n, round int, fn func(start, limit int)) { - if rnd == nil { - rnd = NewRand() - } - for x := 0; x < round; x++ { - start := rnd.Intn(n) - length := 0 - if j := n - start; j > 0 { - length = rnd.Intn(j) - } - fn(start, start+length) - } - return -} - -func Max(x, y int) int { - if x > y { - return x - } - return y -} - -func Min(x, y int) int { - if x < y { - return x - } - return y -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/testutil_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/testutil_test.go deleted file mode 100644 index c8cb44c..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/testutil_test.go +++ /dev/null @@ -1,91 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - . "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/testutil" - "github.com/syndtr/goleveldb/leveldb/util" -) - -type testingDB struct { - *DB - ro *opt.ReadOptions - wo *opt.WriteOptions - stor *testutil.Storage -} - -func (t *testingDB) TestPut(key []byte, value []byte) error { - return t.Put(key, value, t.wo) -} - -func (t *testingDB) TestDelete(key []byte) error { - return t.Delete(key, t.wo) -} - -func (t *testingDB) TestGet(key []byte) (value []byte, err error) { - return t.Get(key, t.ro) -} - -func (t *testingDB) TestHas(key []byte) (ret bool, err error) { - return t.Has(key, t.ro) -} - -func (t *testingDB) TestNewIterator(slice *util.Range) iterator.Iterator { - return t.NewIterator(slice, t.ro) -} - -func (t *testingDB) TestClose() { - err := t.Close() - ExpectWithOffset(1, err).NotTo(HaveOccurred()) - err = t.stor.Close() - ExpectWithOffset(1, err).NotTo(HaveOccurred()) -} - -func newTestingDB(o *opt.Options, ro *opt.ReadOptions, wo *opt.WriteOptions) *testingDB { - stor := testutil.NewStorage() - db, err := Open(stor, o) - // FIXME: This may be called from outside It, which may cause panic. - Expect(err).NotTo(HaveOccurred()) - return &testingDB{ - DB: db, - ro: ro, - wo: wo, - stor: stor, - } -} - -type testingTransaction struct { - *Transaction - ro *opt.ReadOptions - wo *opt.WriteOptions -} - -func (t *testingTransaction) TestPut(key []byte, value []byte) error { - return t.Put(key, value, t.wo) -} - -func (t *testingTransaction) TestDelete(key []byte) error { - return t.Delete(key, t.wo) -} - -func (t *testingTransaction) TestGet(key []byte) (value []byte, err error) { - return t.Get(key, t.ro) -} - -func (t *testingTransaction) TestHas(key []byte) (ret bool, err error) { - return t.Has(key, t.ro) -} - -func (t *testingTransaction) TestNewIterator(slice *util.Range) iterator.Iterator { - return t.NewIterator(slice, t.ro) -} - -func (t *testingTransaction) TestClose() {} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util.go b/vendor/github.com/syndtr/goleveldb/leveldb/util.go deleted file mode 100644 index e572a32..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util.go +++ /dev/null @@ -1,98 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "fmt" - "sort" - - "github.com/syndtr/goleveldb/leveldb/storage" -) - -func shorten(str string) string { - if len(str) <= 8 { - return str - } - return str[:3] + ".." + str[len(str)-3:] -} - -var bunits = [...]string{"", "Ki", "Mi", "Gi"} - -func shortenb(bytes int) string { - i := 0 - for ; bytes > 1024 && i < 4; i++ { - bytes /= 1024 - } - return fmt.Sprintf("%d%sB", bytes, bunits[i]) -} - -func sshortenb(bytes int) string { - if bytes == 0 { - return "~" - } - sign := "+" - if bytes < 0 { - sign = "-" - bytes *= -1 - } - i := 0 - for ; bytes > 1024 && i < 4; i++ { - bytes /= 1024 - } - return fmt.Sprintf("%s%d%sB", sign, bytes, bunits[i]) -} - -func sint(x int) string { - if x == 0 { - return "~" - } - sign := "+" - if x < 0 { - sign = "-" - x *= -1 - } - return fmt.Sprintf("%s%d", sign, x) -} - -func minInt(a, b int) int { - if a < b { - return a - } - return b -} - -func maxInt(a, b int) int { - if a > b { - return a - } - return b -} - -type fdSorter []storage.FileDesc - -func (p fdSorter) Len() int { - return len(p) -} - -func (p fdSorter) Less(i, j int) bool { - return p[i].Num < p[j].Num -} - -func (p fdSorter) Swap(i, j int) { - p[i], p[j] = p[j], p[i] -} - -func sortFds(fds []storage.FileDesc) { - sort.Sort(fdSorter(fds)) -} - -func ensureBuffer(b []byte, n int) []byte { - if cap(b) < n { - return make([]byte, n) - } - return b[:n] -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer.go deleted file mode 100644 index 21de242..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer.go +++ /dev/null @@ -1,293 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package util - -// This a copy of Go std bytes.Buffer with some modification -// and some features stripped. - -import ( - "bytes" - "io" -) - -// A Buffer is a variable-sized buffer of bytes with Read and Write methods. -// The zero value for Buffer is an empty buffer ready to use. -type Buffer struct { - buf []byte // contents are the bytes buf[off : len(buf)] - off int // read at &buf[off], write at &buf[len(buf)] - bootstrap [64]byte // memory to hold first slice; helps small buffers (Printf) avoid allocation. -} - -// Bytes returns a slice of the contents of the unread portion of the buffer; -// len(b.Bytes()) == b.Len(). If the caller changes the contents of the -// returned slice, the contents of the buffer will change provided there -// are no intervening method calls on the Buffer. -func (b *Buffer) Bytes() []byte { return b.buf[b.off:] } - -// String returns the contents of the unread portion of the buffer -// as a string. If the Buffer is a nil pointer, it returns "". -func (b *Buffer) String() string { - if b == nil { - // Special case, useful in debugging. - return "" - } - return string(b.buf[b.off:]) -} - -// Len returns the number of bytes of the unread portion of the buffer; -// b.Len() == len(b.Bytes()). -func (b *Buffer) Len() int { return len(b.buf) - b.off } - -// Truncate discards all but the first n unread bytes from the buffer. -// It panics if n is negative or greater than the length of the buffer. -func (b *Buffer) Truncate(n int) { - switch { - case n < 0 || n > b.Len(): - panic("leveldb/util.Buffer: truncation out of range") - case n == 0: - // Reuse buffer space. - b.off = 0 - } - b.buf = b.buf[0 : b.off+n] -} - -// Reset resets the buffer so it has no content. -// b.Reset() is the same as b.Truncate(0). -func (b *Buffer) Reset() { b.Truncate(0) } - -// grow grows the buffer to guarantee space for n more bytes. -// It returns the index where bytes should be written. -// If the buffer can't grow it will panic with bytes.ErrTooLarge. -func (b *Buffer) grow(n int) int { - m := b.Len() - // If buffer is empty, reset to recover space. - if m == 0 && b.off != 0 { - b.Truncate(0) - } - if len(b.buf)+n > cap(b.buf) { - var buf []byte - if b.buf == nil && n <= len(b.bootstrap) { - buf = b.bootstrap[0:] - } else if m+n <= cap(b.buf)/2 { - // We can slide things down instead of allocating a new - // slice. We only need m+n <= cap(b.buf) to slide, but - // we instead let capacity get twice as large so we - // don't spend all our time copying. - copy(b.buf[:], b.buf[b.off:]) - buf = b.buf[:m] - } else { - // not enough space anywhere - buf = makeSlice(2*cap(b.buf) + n) - copy(buf, b.buf[b.off:]) - } - b.buf = buf - b.off = 0 - } - b.buf = b.buf[0 : b.off+m+n] - return b.off + m -} - -// Alloc allocs n bytes of slice from the buffer, growing the buffer as -// needed. If n is negative, Alloc will panic. -// If the buffer can't grow it will panic with bytes.ErrTooLarge. -func (b *Buffer) Alloc(n int) []byte { - if n < 0 { - panic("leveldb/util.Buffer.Alloc: negative count") - } - m := b.grow(n) - return b.buf[m:] -} - -// Grow grows the buffer's capacity, if necessary, to guarantee space for -// another n bytes. After Grow(n), at least n bytes can be written to the -// buffer without another allocation. -// If n is negative, Grow will panic. -// If the buffer can't grow it will panic with bytes.ErrTooLarge. -func (b *Buffer) Grow(n int) { - if n < 0 { - panic("leveldb/util.Buffer.Grow: negative count") - } - m := b.grow(n) - b.buf = b.buf[0:m] -} - -// Write appends the contents of p to the buffer, growing the buffer as -// needed. The return value n is the length of p; err is always nil. If the -// buffer becomes too large, Write will panic with bytes.ErrTooLarge. -func (b *Buffer) Write(p []byte) (n int, err error) { - m := b.grow(len(p)) - return copy(b.buf[m:], p), nil -} - -// MinRead is the minimum slice size passed to a Read call by -// Buffer.ReadFrom. As long as the Buffer has at least MinRead bytes beyond -// what is required to hold the contents of r, ReadFrom will not grow the -// underlying buffer. -const MinRead = 512 - -// ReadFrom reads data from r until EOF and appends it to the buffer, growing -// the buffer as needed. The return value n is the number of bytes read. Any -// error except io.EOF encountered during the read is also returned. If the -// buffer becomes too large, ReadFrom will panic with bytes.ErrTooLarge. -func (b *Buffer) ReadFrom(r io.Reader) (n int64, err error) { - // If buffer is empty, reset to recover space. - if b.off >= len(b.buf) { - b.Truncate(0) - } - for { - if free := cap(b.buf) - len(b.buf); free < MinRead { - // not enough space at end - newBuf := b.buf - if b.off+free < MinRead { - // not enough space using beginning of buffer; - // double buffer capacity - newBuf = makeSlice(2*cap(b.buf) + MinRead) - } - copy(newBuf, b.buf[b.off:]) - b.buf = newBuf[:len(b.buf)-b.off] - b.off = 0 - } - m, e := r.Read(b.buf[len(b.buf):cap(b.buf)]) - b.buf = b.buf[0 : len(b.buf)+m] - n += int64(m) - if e == io.EOF { - break - } - if e != nil { - return n, e - } - } - return n, nil // err is EOF, so return nil explicitly -} - -// makeSlice allocates a slice of size n. If the allocation fails, it panics -// with bytes.ErrTooLarge. -func makeSlice(n int) []byte { - // If the make fails, give a known error. - defer func() { - if recover() != nil { - panic(bytes.ErrTooLarge) - } - }() - return make([]byte, n) -} - -// WriteTo writes data to w until the buffer is drained or an error occurs. -// The return value n is the number of bytes written; it always fits into an -// int, but it is int64 to match the io.WriterTo interface. Any error -// encountered during the write is also returned. -func (b *Buffer) WriteTo(w io.Writer) (n int64, err error) { - if b.off < len(b.buf) { - nBytes := b.Len() - m, e := w.Write(b.buf[b.off:]) - if m > nBytes { - panic("leveldb/util.Buffer.WriteTo: invalid Write count") - } - b.off += m - n = int64(m) - if e != nil { - return n, e - } - // all bytes should have been written, by definition of - // Write method in io.Writer - if m != nBytes { - return n, io.ErrShortWrite - } - } - // Buffer is now empty; reset. - b.Truncate(0) - return -} - -// WriteByte appends the byte c to the buffer, growing the buffer as needed. -// The returned error is always nil, but is included to match bufio.Writer's -// WriteByte. If the buffer becomes too large, WriteByte will panic with -// bytes.ErrTooLarge. -func (b *Buffer) WriteByte(c byte) error { - m := b.grow(1) - b.buf[m] = c - return nil -} - -// Read reads the next len(p) bytes from the buffer or until the buffer -// is drained. The return value n is the number of bytes read. If the -// buffer has no data to return, err is io.EOF (unless len(p) is zero); -// otherwise it is nil. -func (b *Buffer) Read(p []byte) (n int, err error) { - if b.off >= len(b.buf) { - // Buffer is empty, reset to recover space. - b.Truncate(0) - if len(p) == 0 { - return - } - return 0, io.EOF - } - n = copy(p, b.buf[b.off:]) - b.off += n - return -} - -// Next returns a slice containing the next n bytes from the buffer, -// advancing the buffer as if the bytes had been returned by Read. -// If there are fewer than n bytes in the buffer, Next returns the entire buffer. -// The slice is only valid until the next call to a read or write method. -func (b *Buffer) Next(n int) []byte { - m := b.Len() - if n > m { - n = m - } - data := b.buf[b.off : b.off+n] - b.off += n - return data -} - -// ReadByte reads and returns the next byte from the buffer. -// If no byte is available, it returns error io.EOF. -func (b *Buffer) ReadByte() (c byte, err error) { - if b.off >= len(b.buf) { - // Buffer is empty, reset to recover space. - b.Truncate(0) - return 0, io.EOF - } - c = b.buf[b.off] - b.off++ - return c, nil -} - -// ReadBytes reads until the first occurrence of delim in the input, -// returning a slice containing the data up to and including the delimiter. -// If ReadBytes encounters an error before finding a delimiter, -// it returns the data read before the error and the error itself (often io.EOF). -// ReadBytes returns err != nil if and only if the returned data does not end in -// delim. -func (b *Buffer) ReadBytes(delim byte) (line []byte, err error) { - slice, err := b.readSlice(delim) - // return a copy of slice. The buffer's backing array may - // be overwritten by later calls. - line = append(line, slice...) - return -} - -// readSlice is like ReadBytes but returns a reference to internal buffer data. -func (b *Buffer) readSlice(delim byte) (line []byte, err error) { - i := bytes.IndexByte(b.buf[b.off:], delim) - end := b.off + i + 1 - if i < 0 { - end = len(b.buf) - err = io.EOF - } - line = b.buf[b.off:end] - b.off = end - return line, err -} - -// NewBuffer creates and initializes a new Buffer using buf as its initial -// contents. It is intended to prepare a Buffer to read existing data. It -// can also be used to size the internal buffer for writing. To do that, -// buf should have the desired capacity but a length of zero. -// -// In most cases, new(Buffer) (or just declaring a Buffer variable) is -// sufficient to initialize a Buffer. -func NewBuffer(buf []byte) *Buffer { return &Buffer{buf: buf} } diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_pool.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_pool.go deleted file mode 100644 index 2f3db97..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_pool.go +++ /dev/null @@ -1,239 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package util - -import ( - "fmt" - "sync" - "sync/atomic" - "time" -) - -type buffer struct { - b []byte - miss int -} - -// BufferPool is a 'buffer pool'. -type BufferPool struct { - pool [6]chan []byte - size [5]uint32 - sizeMiss [5]uint32 - sizeHalf [5]uint32 - baseline [4]int - baseline0 int - - mu sync.RWMutex - closed bool - closeC chan struct{} - - get uint32 - put uint32 - half uint32 - less uint32 - equal uint32 - greater uint32 - miss uint32 -} - -func (p *BufferPool) poolNum(n int) int { - if n <= p.baseline0 && n > p.baseline0/2 { - return 0 - } - for i, x := range p.baseline { - if n <= x { - return i + 1 - } - } - return len(p.baseline) + 1 -} - -// Get returns buffer with length of n. -func (p *BufferPool) Get(n int) []byte { - if p == nil { - return make([]byte, n) - } - - p.mu.RLock() - defer p.mu.RUnlock() - - if p.closed { - return make([]byte, n) - } - - atomic.AddUint32(&p.get, 1) - - poolNum := p.poolNum(n) - pool := p.pool[poolNum] - if poolNum == 0 { - // Fast path. - select { - case b := <-pool: - switch { - case cap(b) > n: - if cap(b)-n >= n { - atomic.AddUint32(&p.half, 1) - select { - case pool <- b: - default: - } - return make([]byte, n) - } else { - atomic.AddUint32(&p.less, 1) - return b[:n] - } - case cap(b) == n: - atomic.AddUint32(&p.equal, 1) - return b[:n] - default: - atomic.AddUint32(&p.greater, 1) - } - default: - atomic.AddUint32(&p.miss, 1) - } - - return make([]byte, n, p.baseline0) - } else { - sizePtr := &p.size[poolNum-1] - - select { - case b := <-pool: - switch { - case cap(b) > n: - if cap(b)-n >= n { - atomic.AddUint32(&p.half, 1) - sizeHalfPtr := &p.sizeHalf[poolNum-1] - if atomic.AddUint32(sizeHalfPtr, 1) == 20 { - atomic.StoreUint32(sizePtr, uint32(cap(b)/2)) - atomic.StoreUint32(sizeHalfPtr, 0) - } else { - select { - case pool <- b: - default: - } - } - return make([]byte, n) - } else { - atomic.AddUint32(&p.less, 1) - return b[:n] - } - case cap(b) == n: - atomic.AddUint32(&p.equal, 1) - return b[:n] - default: - atomic.AddUint32(&p.greater, 1) - if uint32(cap(b)) >= atomic.LoadUint32(sizePtr) { - select { - case pool <- b: - default: - } - } - } - default: - atomic.AddUint32(&p.miss, 1) - } - - if size := atomic.LoadUint32(sizePtr); uint32(n) > size { - if size == 0 { - atomic.CompareAndSwapUint32(sizePtr, 0, uint32(n)) - } else { - sizeMissPtr := &p.sizeMiss[poolNum-1] - if atomic.AddUint32(sizeMissPtr, 1) == 20 { - atomic.StoreUint32(sizePtr, uint32(n)) - atomic.StoreUint32(sizeMissPtr, 0) - } - } - return make([]byte, n) - } else { - return make([]byte, n, size) - } - } -} - -// Put adds given buffer to the pool. -func (p *BufferPool) Put(b []byte) { - if p == nil { - return - } - - p.mu.RLock() - defer p.mu.RUnlock() - - if p.closed { - return - } - - atomic.AddUint32(&p.put, 1) - - pool := p.pool[p.poolNum(cap(b))] - select { - case pool <- b: - default: - } - -} - -func (p *BufferPool) Close() { - if p == nil { - return - } - - p.mu.Lock() - if !p.closed { - p.closed = true - p.closeC <- struct{}{} - } - p.mu.Unlock() -} - -func (p *BufferPool) String() string { - if p == nil { - return "" - } - - return fmt.Sprintf("BufferPool{B·%d Z·%v Zm·%v Zh·%v G·%d P·%d H·%d <·%d =·%d >·%d M·%d}", - p.baseline0, p.size, p.sizeMiss, p.sizeHalf, p.get, p.put, p.half, p.less, p.equal, p.greater, p.miss) -} - -func (p *BufferPool) drain() { - ticker := time.NewTicker(2 * time.Second) - defer ticker.Stop() - for { - select { - case <-ticker.C: - for _, ch := range p.pool { - select { - case <-ch: - default: - } - } - case <-p.closeC: - close(p.closeC) - for _, ch := range p.pool { - close(ch) - } - return - } - } -} - -// NewBufferPool creates a new initialized 'buffer pool'. -func NewBufferPool(baseline int) *BufferPool { - if baseline <= 0 { - panic("baseline can't be <= 0") - } - p := &BufferPool{ - baseline0: baseline, - baseline: [...]int{baseline / 4, baseline / 2, baseline * 2, baseline * 4}, - closeC: make(chan struct{}, 1), - } - for i, cap := range []int{2, 2, 4, 4, 2, 1} { - p.pool[i] = make(chan []byte, cap) - } - go p.drain() - return p -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_test.go deleted file mode 100644 index 87d9673..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/buffer_test.go +++ /dev/null @@ -1,369 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package util - -import ( - "bytes" - "io" - "math/rand" - "runtime" - "testing" -) - -const N = 10000 // make this bigger for a larger (and slower) test -var data string // test data for write tests -var testBytes []byte // test data; same as data but as a slice. - -func init() { - testBytes = make([]byte, N) - for i := 0; i < N; i++ { - testBytes[i] = 'a' + byte(i%26) - } - data = string(testBytes) -} - -// Verify that contents of buf match the string s. -func check(t *testing.T, testname string, buf *Buffer, s string) { - bytes := buf.Bytes() - str := buf.String() - if buf.Len() != len(bytes) { - t.Errorf("%s: buf.Len() == %d, len(buf.Bytes()) == %d", testname, buf.Len(), len(bytes)) - } - - if buf.Len() != len(str) { - t.Errorf("%s: buf.Len() == %d, len(buf.String()) == %d", testname, buf.Len(), len(str)) - } - - if buf.Len() != len(s) { - t.Errorf("%s: buf.Len() == %d, len(s) == %d", testname, buf.Len(), len(s)) - } - - if string(bytes) != s { - t.Errorf("%s: string(buf.Bytes()) == %q, s == %q", testname, string(bytes), s) - } -} - -// Fill buf through n writes of byte slice fub. -// The initial contents of buf corresponds to the string s; -// the result is the final contents of buf returned as a string. -func fillBytes(t *testing.T, testname string, buf *Buffer, s string, n int, fub []byte) string { - check(t, testname+" (fill 1)", buf, s) - for ; n > 0; n-- { - m, err := buf.Write(fub) - if m != len(fub) { - t.Errorf(testname+" (fill 2): m == %d, expected %d", m, len(fub)) - } - if err != nil { - t.Errorf(testname+" (fill 3): err should always be nil, found err == %s", err) - } - s += string(fub) - check(t, testname+" (fill 4)", buf, s) - } - return s -} - -func TestNewBuffer(t *testing.T) { - buf := NewBuffer(testBytes) - check(t, "NewBuffer", buf, data) -} - -// Empty buf through repeated reads into fub. -// The initial contents of buf corresponds to the string s. -func empty(t *testing.T, testname string, buf *Buffer, s string, fub []byte) { - check(t, testname+" (empty 1)", buf, s) - - for { - n, err := buf.Read(fub) - if n == 0 { - break - } - if err != nil { - t.Errorf(testname+" (empty 2): err should always be nil, found err == %s", err) - } - s = s[n:] - check(t, testname+" (empty 3)", buf, s) - } - - check(t, testname+" (empty 4)", buf, "") -} - -func TestBasicOperations(t *testing.T) { - var buf Buffer - - for i := 0; i < 5; i++ { - check(t, "TestBasicOperations (1)", &buf, "") - - buf.Reset() - check(t, "TestBasicOperations (2)", &buf, "") - - buf.Truncate(0) - check(t, "TestBasicOperations (3)", &buf, "") - - n, err := buf.Write([]byte(data[0:1])) - if n != 1 { - t.Errorf("wrote 1 byte, but n == %d", n) - } - if err != nil { - t.Errorf("err should always be nil, but err == %s", err) - } - check(t, "TestBasicOperations (4)", &buf, "a") - - buf.WriteByte(data[1]) - check(t, "TestBasicOperations (5)", &buf, "ab") - - n, err = buf.Write([]byte(data[2:26])) - if n != 24 { - t.Errorf("wrote 25 bytes, but n == %d", n) - } - check(t, "TestBasicOperations (6)", &buf, string(data[0:26])) - - buf.Truncate(26) - check(t, "TestBasicOperations (7)", &buf, string(data[0:26])) - - buf.Truncate(20) - check(t, "TestBasicOperations (8)", &buf, string(data[0:20])) - - empty(t, "TestBasicOperations (9)", &buf, string(data[0:20]), make([]byte, 5)) - empty(t, "TestBasicOperations (10)", &buf, "", make([]byte, 100)) - - buf.WriteByte(data[1]) - c, err := buf.ReadByte() - if err != nil { - t.Error("ReadByte unexpected eof") - } - if c != data[1] { - t.Errorf("ReadByte wrong value c=%v", c) - } - c, err = buf.ReadByte() - if err == nil { - t.Error("ReadByte unexpected not eof") - } - } -} - -func TestLargeByteWrites(t *testing.T) { - var buf Buffer - limit := 30 - if testing.Short() { - limit = 9 - } - for i := 3; i < limit; i += 3 { - s := fillBytes(t, "TestLargeWrites (1)", &buf, "", 5, testBytes) - empty(t, "TestLargeByteWrites (2)", &buf, s, make([]byte, len(data)/i)) - } - check(t, "TestLargeByteWrites (3)", &buf, "") -} - -func TestLargeByteReads(t *testing.T) { - var buf Buffer - for i := 3; i < 30; i += 3 { - s := fillBytes(t, "TestLargeReads (1)", &buf, "", 5, testBytes[0:len(testBytes)/i]) - empty(t, "TestLargeReads (2)", &buf, s, make([]byte, len(data))) - } - check(t, "TestLargeByteReads (3)", &buf, "") -} - -func TestMixedReadsAndWrites(t *testing.T) { - var buf Buffer - s := "" - for i := 0; i < 50; i++ { - wlen := rand.Intn(len(data)) - s = fillBytes(t, "TestMixedReadsAndWrites (1)", &buf, s, 1, testBytes[0:wlen]) - rlen := rand.Intn(len(data)) - fub := make([]byte, rlen) - n, _ := buf.Read(fub) - s = s[n:] - } - empty(t, "TestMixedReadsAndWrites (2)", &buf, s, make([]byte, buf.Len())) -} - -func TestNil(t *testing.T) { - var b *Buffer - if b.String() != "" { - t.Errorf("expected ; got %q", b.String()) - } -} - -func TestReadFrom(t *testing.T) { - var buf Buffer - for i := 3; i < 30; i += 3 { - s := fillBytes(t, "TestReadFrom (1)", &buf, "", 5, testBytes[0:len(testBytes)/i]) - var b Buffer - b.ReadFrom(&buf) - empty(t, "TestReadFrom (2)", &b, s, make([]byte, len(data))) - } -} - -func TestWriteTo(t *testing.T) { - var buf Buffer - for i := 3; i < 30; i += 3 { - s := fillBytes(t, "TestWriteTo (1)", &buf, "", 5, testBytes[0:len(testBytes)/i]) - var b Buffer - buf.WriteTo(&b) - empty(t, "TestWriteTo (2)", &b, s, make([]byte, len(data))) - } -} - -func TestNext(t *testing.T) { - b := []byte{0, 1, 2, 3, 4} - tmp := make([]byte, 5) - for i := 0; i <= 5; i++ { - for j := i; j <= 5; j++ { - for k := 0; k <= 6; k++ { - // 0 <= i <= j <= 5; 0 <= k <= 6 - // Check that if we start with a buffer - // of length j at offset i and ask for - // Next(k), we get the right bytes. - buf := NewBuffer(b[0:j]) - n, _ := buf.Read(tmp[0:i]) - if n != i { - t.Fatalf("Read %d returned %d", i, n) - } - bb := buf.Next(k) - want := k - if want > j-i { - want = j - i - } - if len(bb) != want { - t.Fatalf("in %d,%d: len(Next(%d)) == %d", i, j, k, len(bb)) - } - for l, v := range bb { - if v != byte(l+i) { - t.Fatalf("in %d,%d: Next(%d)[%d] = %d, want %d", i, j, k, l, v, l+i) - } - } - } - } - } -} - -var readBytesTests = []struct { - buffer string - delim byte - expected []string - err error -}{ - {"", 0, []string{""}, io.EOF}, - {"a\x00", 0, []string{"a\x00"}, nil}, - {"abbbaaaba", 'b', []string{"ab", "b", "b", "aaab"}, nil}, - {"hello\x01world", 1, []string{"hello\x01"}, nil}, - {"foo\nbar", 0, []string{"foo\nbar"}, io.EOF}, - {"alpha\nbeta\ngamma\n", '\n', []string{"alpha\n", "beta\n", "gamma\n"}, nil}, - {"alpha\nbeta\ngamma", '\n', []string{"alpha\n", "beta\n", "gamma"}, io.EOF}, -} - -func TestReadBytes(t *testing.T) { - for _, test := range readBytesTests { - buf := NewBuffer([]byte(test.buffer)) - var err error - for _, expected := range test.expected { - var bytes []byte - bytes, err = buf.ReadBytes(test.delim) - if string(bytes) != expected { - t.Errorf("expected %q, got %q", expected, bytes) - } - if err != nil { - break - } - } - if err != test.err { - t.Errorf("expected error %v, got %v", test.err, err) - } - } -} - -func TestGrow(t *testing.T) { - x := []byte{'x'} - y := []byte{'y'} - tmp := make([]byte, 72) - for _, startLen := range []int{0, 100, 1000, 10000, 100000} { - xBytes := bytes.Repeat(x, startLen) - for _, growLen := range []int{0, 100, 1000, 10000, 100000} { - buf := NewBuffer(xBytes) - // If we read, this affects buf.off, which is good to test. - readBytes, _ := buf.Read(tmp) - buf.Grow(growLen) - yBytes := bytes.Repeat(y, growLen) - // Check no allocation occurs in write, as long as we're single-threaded. - var m1, m2 runtime.MemStats - runtime.ReadMemStats(&m1) - buf.Write(yBytes) - runtime.ReadMemStats(&m2) - if runtime.GOMAXPROCS(-1) == 1 && m1.Mallocs != m2.Mallocs { - t.Errorf("allocation occurred during write") - } - // Check that buffer has correct data. - if !bytes.Equal(buf.Bytes()[0:startLen-readBytes], xBytes[readBytes:]) { - t.Errorf("bad initial data at %d %d", startLen, growLen) - } - if !bytes.Equal(buf.Bytes()[startLen-readBytes:startLen-readBytes+growLen], yBytes) { - t.Errorf("bad written data at %d %d", startLen, growLen) - } - } - } -} - -// Was a bug: used to give EOF reading empty slice at EOF. -func TestReadEmptyAtEOF(t *testing.T) { - b := new(Buffer) - slice := make([]byte, 0) - n, err := b.Read(slice) - if err != nil { - t.Errorf("read error: %v", err) - } - if n != 0 { - t.Errorf("wrong count; got %d want 0", n) - } -} - -// Tests that we occasionally compact. Issue 5154. -func TestBufferGrowth(t *testing.T) { - var b Buffer - buf := make([]byte, 1024) - b.Write(buf[0:1]) - var cap0 int - for i := 0; i < 5<<10; i++ { - b.Write(buf) - b.Read(buf) - if i == 0 { - cap0 = cap(b.buf) - } - } - cap1 := cap(b.buf) - // (*Buffer).grow allows for 2x capacity slop before sliding, - // so set our error threshold at 3x. - if cap1 > cap0*3 { - t.Errorf("buffer cap = %d; too big (grew from %d)", cap1, cap0) - } -} - -// From Issue 5154. -func BenchmarkBufferNotEmptyWriteRead(b *testing.B) { - buf := make([]byte, 1024) - for i := 0; i < b.N; i++ { - var b Buffer - b.Write(buf[0:1]) - for i := 0; i < 5<<10; i++ { - b.Write(buf) - b.Read(buf) - } - } -} - -// Check that we don't compact too often. From Issue 5154. -func BenchmarkBufferFullSmallReads(b *testing.B) { - buf := make([]byte, 1024) - for i := 0; i < b.N; i++ { - var b Buffer - b.Write(buf) - for b.Len()+20 < cap(b.buf) { - b.Write(buf[:10]) - } - for i := 0; i < 5<<10; i++ { - b.Read(buf[:1]) - b.Write(buf[:1]) - } - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/crc32.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/crc32.go deleted file mode 100644 index 631c9d6..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/crc32.go +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright 2011 The LevelDB-Go Authors. All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package util - -import ( - "hash/crc32" -) - -var table = crc32.MakeTable(crc32.Castagnoli) - -// CRC is a CRC-32 checksum computed using Castagnoli's polynomial. -type CRC uint32 - -// NewCRC creates a new crc based on the given bytes. -func NewCRC(b []byte) CRC { - return CRC(0).Update(b) -} - -// Update updates the crc with the given bytes. -func (c CRC) Update(b []byte) CRC { - return CRC(crc32.Update(uint32(c), table, b)) -} - -// Value returns a masked crc. -func (c CRC) Value() uint32 { - return uint32(c>>15|c<<17) + 0xa282ead8 -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/hash.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/hash.go deleted file mode 100644 index 7f3fa4e..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/hash.go +++ /dev/null @@ -1,48 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package util - -import ( - "encoding/binary" -) - -// Hash return hash of the given data. -func Hash(data []byte, seed uint32) uint32 { - // Similar to murmur hash - const ( - m = uint32(0xc6a4a793) - r = uint32(24) - ) - var ( - h = seed ^ (uint32(len(data)) * m) - i int - ) - - for n := len(data) - len(data)%4; i < n; i += 4 { - h += binary.LittleEndian.Uint32(data[i:]) - h *= m - h ^= (h >> 16) - } - - switch len(data) - i { - default: - panic("not reached") - case 3: - h += uint32(data[i+2]) << 16 - fallthrough - case 2: - h += uint32(data[i+1]) << 8 - fallthrough - case 1: - h += uint32(data[i]) - h *= m - h ^= (h >> r) - case 0: - } - - return h -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/hash_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/hash_test.go deleted file mode 100644 index a35d273..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/hash_test.go +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package util - -import ( - "testing" -) - -var hashTests = []struct { - data []byte - seed uint32 - hash uint32 -}{ - {nil, 0xbc9f1d34, 0xbc9f1d34}, - {[]byte{0x62}, 0xbc9f1d34, 0xef1345c4}, - {[]byte{0xc3, 0x97}, 0xbc9f1d34, 0x5b663814}, - {[]byte{0xe2, 0x99, 0xa5}, 0xbc9f1d34, 0x323c078f}, - {[]byte{0xe1, 0x80, 0xb9, 0x32}, 0xbc9f1d34, 0xed21633a}, - {[]byte{ - 0x01, 0xc0, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, - 0x14, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x04, 0x00, - 0x00, 0x00, 0x00, 0x14, - 0x00, 0x00, 0x00, 0x18, - 0x28, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, - 0x02, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, - }, 0x12345678, 0xf333dabb}, -} - -func TestHash(t *testing.T) { - for i, x := range hashTests { - h := Hash(x.data, x.seed) - if h != x.hash { - t.Fatalf("test-%d: invalid hash, %#x vs %#x", i, h, x.hash) - } - } -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/range.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/range.go deleted file mode 100644 index 8515958..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/range.go +++ /dev/null @@ -1,32 +0,0 @@ -// Copyright (c) 2014, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package util - -// Range is a key range. -type Range struct { - // Start of the key range, include in the range. - Start []byte - - // Limit of the key range, not include in the range. - Limit []byte -} - -// BytesPrefix returns key range that satisfy the given prefix. -// This only applicable for the standard 'bytes comparer'. -func BytesPrefix(prefix []byte) *Range { - var limit []byte - for i := len(prefix) - 1; i >= 0; i-- { - c := prefix[i] - if c < 0xff { - limit = make([]byte, i+1) - copy(limit, prefix) - limit[i] = c + 1 - break - } - } - return &Range{prefix, limit} -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/util/util.go b/vendor/github.com/syndtr/goleveldb/leveldb/util/util.go deleted file mode 100644 index 80614af..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/util/util.go +++ /dev/null @@ -1,73 +0,0 @@ -// Copyright (c) 2013, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -// Package util provides utilities used throughout leveldb. -package util - -import ( - "errors" -) - -var ( - ErrReleased = errors.New("leveldb: resource already relesed") - ErrHasReleaser = errors.New("leveldb: releaser already defined") -) - -// Releaser is the interface that wraps the basic Release method. -type Releaser interface { - // Release releases associated resources. Release should always success - // and can be called multiple times without causing error. - Release() -} - -// ReleaseSetter is the interface that wraps the basic SetReleaser method. -type ReleaseSetter interface { - // SetReleaser associates the given releaser to the resources. The - // releaser will be called once coresponding resources released. - // Calling SetReleaser with nil will clear the releaser. - // - // This will panic if a releaser already present or coresponding - // resource is already released. Releaser should be cleared first - // before assigned a new one. - SetReleaser(releaser Releaser) -} - -// BasicReleaser provides basic implementation of Releaser and ReleaseSetter. -type BasicReleaser struct { - releaser Releaser - released bool -} - -// Released returns whether Release method already called. -func (r *BasicReleaser) Released() bool { - return r.released -} - -// Release implements Releaser.Release. -func (r *BasicReleaser) Release() { - if !r.released { - if r.releaser != nil { - r.releaser.Release() - r.releaser = nil - } - r.released = true - } -} - -// SetReleaser implements ReleaseSetter.SetReleaser. -func (r *BasicReleaser) SetReleaser(releaser Releaser) { - if r.released { - panic(ErrReleased) - } - if r.releaser != nil && releaser != nil { - panic(ErrHasReleaser) - } - r.releaser = releaser -} - -type NoopReleaser struct{} - -func (NoopReleaser) Release() {} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/version.go b/vendor/github.com/syndtr/goleveldb/leveldb/version.go deleted file mode 100644 index 73f272a..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/version.go +++ /dev/null @@ -1,528 +0,0 @@ -// Copyright (c) 2012, Suryandaru Triandana -// All rights reserved. -// -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -package leveldb - -import ( - "fmt" - "sync/atomic" - "unsafe" - - "github.com/syndtr/goleveldb/leveldb/iterator" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/util" -) - -type tSet struct { - level int - table *tFile -} - -type version struct { - s *session - - levels []tFiles - - // Level that should be compacted next and its compaction score. - // Score < 1 means compaction is not strictly needed. These fields - // are initialized by computeCompaction() - cLevel int - cScore float64 - - cSeek unsafe.Pointer - - closing bool - ref int - released bool -} - -func newVersion(s *session) *version { - return &version{s: s} -} - -func (v *version) incref() { - if v.released { - panic("already released") - } - - v.ref++ - if v.ref == 1 { - // Incr file ref. - for _, tt := range v.levels { - for _, t := range tt { - v.s.addFileRef(t.fd, 1) - } - } - } -} - -func (v *version) releaseNB() { - v.ref-- - if v.ref > 0 { - return - } else if v.ref < 0 { - panic("negative version ref") - } - - for _, tt := range v.levels { - for _, t := range tt { - if v.s.addFileRef(t.fd, -1) == 0 { - v.s.tops.remove(t) - } - } - } - - v.released = true -} - -func (v *version) release() { - v.s.vmu.Lock() - v.releaseNB() - v.s.vmu.Unlock() -} - -func (v *version) walkOverlapping(aux tFiles, ikey internalKey, f func(level int, t *tFile) bool, lf func(level int) bool) { - ukey := ikey.ukey() - - // Aux level. - if aux != nil { - for _, t := range aux { - if t.overlaps(v.s.icmp, ukey, ukey) { - if !f(-1, t) { - return - } - } - } - - if lf != nil && !lf(-1) { - return - } - } - - // Walk tables level-by-level. - for level, tables := range v.levels { - if len(tables) == 0 { - continue - } - - if level == 0 { - // Level-0 files may overlap each other. Find all files that - // overlap ukey. - for _, t := range tables { - if t.overlaps(v.s.icmp, ukey, ukey) { - if !f(level, t) { - return - } - } - } - } else { - if i := tables.searchMax(v.s.icmp, ikey); i < len(tables) { - t := tables[i] - if v.s.icmp.uCompare(ukey, t.imin.ukey()) >= 0 { - if !f(level, t) { - return - } - } - } - } - - if lf != nil && !lf(level) { - return - } - } -} - -func (v *version) get(aux tFiles, ikey internalKey, ro *opt.ReadOptions, noValue bool) (value []byte, tcomp bool, err error) { - if v.closing { - return nil, false, ErrClosed - } - - ukey := ikey.ukey() - - var ( - tset *tSet - tseek bool - - // Level-0. - zfound bool - zseq uint64 - zkt keyType - zval []byte - ) - - err = ErrNotFound - - // Since entries never hop across level, finding key/value - // in smaller level make later levels irrelevant. - v.walkOverlapping(aux, ikey, func(level int, t *tFile) bool { - if level >= 0 && !tseek { - if tset == nil { - tset = &tSet{level, t} - } else { - tseek = true - } - } - - var ( - fikey, fval []byte - ferr error - ) - if noValue { - fikey, ferr = v.s.tops.findKey(t, ikey, ro) - } else { - fikey, fval, ferr = v.s.tops.find(t, ikey, ro) - } - - switch ferr { - case nil: - case ErrNotFound: - return true - default: - err = ferr - return false - } - - if fukey, fseq, fkt, fkerr := parseInternalKey(fikey); fkerr == nil { - if v.s.icmp.uCompare(ukey, fukey) == 0 { - // Level <= 0 may overlaps each-other. - if level <= 0 { - if fseq >= zseq { - zfound = true - zseq = fseq - zkt = fkt - zval = fval - } - } else { - switch fkt { - case keyTypeVal: - value = fval - err = nil - case keyTypeDel: - default: - panic("leveldb: invalid internalKey type") - } - return false - } - } - } else { - err = fkerr - return false - } - - return true - }, func(level int) bool { - if zfound { - switch zkt { - case keyTypeVal: - value = zval - err = nil - case keyTypeDel: - default: - panic("leveldb: invalid internalKey type") - } - return false - } - - return true - }) - - if tseek && tset.table.consumeSeek() <= 0 { - tcomp = atomic.CompareAndSwapPointer(&v.cSeek, nil, unsafe.Pointer(tset)) - } - - return -} - -func (v *version) sampleSeek(ikey internalKey) (tcomp bool) { - var tset *tSet - - v.walkOverlapping(nil, ikey, func(level int, t *tFile) bool { - if tset == nil { - tset = &tSet{level, t} - return true - } - if tset.table.consumeSeek() <= 0 { - tcomp = atomic.CompareAndSwapPointer(&v.cSeek, nil, unsafe.Pointer(tset)) - } - return false - }, nil) - - return -} - -func (v *version) getIterators(slice *util.Range, ro *opt.ReadOptions) (its []iterator.Iterator) { - strict := opt.GetStrict(v.s.o.Options, ro, opt.StrictReader) - for level, tables := range v.levels { - if level == 0 { - // Merge all level zero files together since they may overlap. - for _, t := range tables { - its = append(its, v.s.tops.newIterator(t, slice, ro)) - } - } else if len(tables) != 0 { - its = append(its, iterator.NewIndexedIterator(tables.newIndexIterator(v.s.tops, v.s.icmp, slice, ro), strict)) - } - } - return -} - -func (v *version) newStaging() *versionStaging { - return &versionStaging{base: v} -} - -// Spawn a new version based on this version. -func (v *version) spawn(r *sessionRecord) *version { - staging := v.newStaging() - staging.commit(r) - return staging.finish() -} - -func (v *version) fillRecord(r *sessionRecord) { - for level, tables := range v.levels { - for _, t := range tables { - r.addTableFile(level, t) - } - } -} - -func (v *version) tLen(level int) int { - if level < len(v.levels) { - return len(v.levels[level]) - } - return 0 -} - -func (v *version) offsetOf(ikey internalKey) (n int64, err error) { - for level, tables := range v.levels { - for _, t := range tables { - if v.s.icmp.Compare(t.imax, ikey) <= 0 { - // Entire file is before "ikey", so just add the file size - n += t.size - } else if v.s.icmp.Compare(t.imin, ikey) > 0 { - // Entire file is after "ikey", so ignore - if level > 0 { - // Files other than level 0 are sorted by meta->min, so - // no further files in this level will contain data for - // "ikey". - break - } - } else { - // "ikey" falls in the range for this table. Add the - // approximate offset of "ikey" within the table. - if m, err := v.s.tops.offsetOf(t, ikey); err == nil { - n += m - } else { - return 0, err - } - } - } - } - - return -} - -func (v *version) pickMemdbLevel(umin, umax []byte, maxLevel int) (level int) { - if maxLevel > 0 { - if len(v.levels) == 0 { - return maxLevel - } - if !v.levels[0].overlaps(v.s.icmp, umin, umax, true) { - var overlaps tFiles - for ; level < maxLevel; level++ { - if pLevel := level + 1; pLevel >= len(v.levels) { - return maxLevel - } else if v.levels[pLevel].overlaps(v.s.icmp, umin, umax, false) { - break - } - if gpLevel := level + 2; gpLevel < len(v.levels) { - overlaps = v.levels[gpLevel].getOverlaps(overlaps, v.s.icmp, umin, umax, false) - if overlaps.size() > int64(v.s.o.GetCompactionGPOverlaps(level)) { - break - } - } - } - } - } - return -} - -func (v *version) computeCompaction() { - // Precomputed best level for next compaction - bestLevel := int(-1) - bestScore := float64(-1) - - statFiles := make([]int, len(v.levels)) - statSizes := make([]string, len(v.levels)) - statScore := make([]string, len(v.levels)) - statTotSize := int64(0) - - for level, tables := range v.levels { - var score float64 - size := tables.size() - if level == 0 { - // We treat level-0 specially by bounding the number of files - // instead of number of bytes for two reasons: - // - // (1) With larger write-buffer sizes, it is nice not to do too - // many level-0 compaction. - // - // (2) The files in level-0 are merged on every read and - // therefore we wish to avoid too many files when the individual - // file size is small (perhaps because of a small write-buffer - // setting, or very high compression ratios, or lots of - // overwrites/deletions). - score = float64(len(tables)) / float64(v.s.o.GetCompactionL0Trigger()) - } else { - score = float64(size) / float64(v.s.o.GetCompactionTotalSize(level)) - } - - if score > bestScore { - bestLevel = level - bestScore = score - } - - statFiles[level] = len(tables) - statSizes[level] = shortenb(int(size)) - statScore[level] = fmt.Sprintf("%.2f", score) - statTotSize += size - } - - v.cLevel = bestLevel - v.cScore = bestScore - - v.s.logf("version@stat F·%v S·%s%v Sc·%v", statFiles, shortenb(int(statTotSize)), statSizes, statScore) -} - -func (v *version) needCompaction() bool { - return v.cScore >= 1 || atomic.LoadPointer(&v.cSeek) != nil -} - -type tablesScratch struct { - added map[int64]atRecord - deleted map[int64]struct{} -} - -type versionStaging struct { - base *version - levels []tablesScratch -} - -func (p *versionStaging) getScratch(level int) *tablesScratch { - if level >= len(p.levels) { - newLevels := make([]tablesScratch, level+1) - copy(newLevels, p.levels) - p.levels = newLevels - } - return &(p.levels[level]) -} - -func (p *versionStaging) commit(r *sessionRecord) { - // Deleted tables. - for _, r := range r.deletedTables { - scratch := p.getScratch(r.level) - if r.level < len(p.base.levels) && len(p.base.levels[r.level]) > 0 { - if scratch.deleted == nil { - scratch.deleted = make(map[int64]struct{}) - } - scratch.deleted[r.num] = struct{}{} - } - if scratch.added != nil { - delete(scratch.added, r.num) - } - } - - // New tables. - for _, r := range r.addedTables { - scratch := p.getScratch(r.level) - if scratch.added == nil { - scratch.added = make(map[int64]atRecord) - } - scratch.added[r.num] = r - if scratch.deleted != nil { - delete(scratch.deleted, r.num) - } - } -} - -func (p *versionStaging) finish() *version { - // Build new version. - nv := newVersion(p.base.s) - numLevel := len(p.levels) - if len(p.base.levels) > numLevel { - numLevel = len(p.base.levels) - } - nv.levels = make([]tFiles, numLevel) - for level := 0; level < numLevel; level++ { - var baseTabels tFiles - if level < len(p.base.levels) { - baseTabels = p.base.levels[level] - } - - if level < len(p.levels) { - scratch := p.levels[level] - - var nt tFiles - // Prealloc list if possible. - if n := len(baseTabels) + len(scratch.added) - len(scratch.deleted); n > 0 { - nt = make(tFiles, 0, n) - } - - // Base tables. - for _, t := range baseTabels { - if _, ok := scratch.deleted[t.fd.Num]; ok { - continue - } - if _, ok := scratch.added[t.fd.Num]; ok { - continue - } - nt = append(nt, t) - } - - // New tables. - for _, r := range scratch.added { - nt = append(nt, tableFileFromRecord(r)) - } - - if len(nt) != 0 { - // Sort tables. - if level == 0 { - nt.sortByNum() - } else { - nt.sortByKey(p.base.s.icmp) - } - - nv.levels[level] = nt - } - } else { - nv.levels[level] = baseTabels - } - } - - // Trim levels. - n := len(nv.levels) - for ; n > 0 && nv.levels[n-1] == nil; n-- { - } - nv.levels = nv.levels[:n] - - // Compute compaction score for new version. - nv.computeCompaction() - - return nv -} - -type versionReleaser struct { - v *version - once bool -} - -func (vr *versionReleaser) Release() { - v := vr.v - v.s.vmu.Lock() - if !vr.once { - v.releaseNB() - vr.once = true - } - v.s.vmu.Unlock() -} diff --git a/vendor/github.com/syndtr/goleveldb/leveldb/version_test.go b/vendor/github.com/syndtr/goleveldb/leveldb/version_test.go deleted file mode 100644 index a643be1..0000000 --- a/vendor/github.com/syndtr/goleveldb/leveldb/version_test.go +++ /dev/null @@ -1,181 +0,0 @@ -package leveldb - -import ( - "encoding/binary" - "reflect" - "testing" - - "github.com/onsi/gomega" - - "github.com/syndtr/goleveldb/leveldb/testutil" -) - -type testFileRec struct { - level int - num int64 -} - -func TestVersionStaging(t *testing.T) { - gomega.RegisterTestingT(t) - stor := testutil.NewStorage() - defer stor.Close() - s, err := newSession(stor, nil) - if err != nil { - t.Fatal(err) - } - - v := newVersion(s) - v.newStaging() - - tmp := make([]byte, 4) - mik := func(i uint64) []byte { - binary.BigEndian.PutUint32(tmp, uint32(i)) - return []byte(makeInternalKey(nil, tmp, 0, keyTypeVal)) - } - - for i, x := range []struct { - add, del []testFileRec - levels [][]int64 - }{ - { - add: []testFileRec{ - {1, 1}, - }, - levels: [][]int64{ - {}, - {1}, - }, - }, - { - add: []testFileRec{ - {1, 1}, - }, - levels: [][]int64{ - {}, - {1}, - }, - }, - { - del: []testFileRec{ - {1, 1}, - }, - levels: [][]int64{}, - }, - { - add: []testFileRec{ - {0, 1}, - {0, 3}, - {0, 2}, - {2, 5}, - {1, 4}, - }, - levels: [][]int64{ - {3, 2, 1}, - {4}, - {5}, - }, - }, - { - add: []testFileRec{ - {1, 6}, - {2, 5}, - }, - del: []testFileRec{ - {0, 1}, - {0, 4}, - }, - levels: [][]int64{ - {3, 2}, - {4, 6}, - {5}, - }, - }, - { - del: []testFileRec{ - {0, 3}, - {0, 2}, - {1, 4}, - {1, 6}, - {2, 5}, - }, - levels: [][]int64{}, - }, - { - add: []testFileRec{ - {0, 1}, - }, - levels: [][]int64{ - {1}, - }, - }, - { - add: []testFileRec{ - {1, 2}, - }, - levels: [][]int64{ - {1}, - {2}, - }, - }, - { - add: []testFileRec{ - {0, 3}, - }, - levels: [][]int64{ - {3, 1}, - {2}, - }, - }, - { - add: []testFileRec{ - {6, 9}, - }, - levels: [][]int64{ - {3, 1}, - {2}, - {}, - {}, - {}, - {}, - {9}, - }, - }, - { - del: []testFileRec{ - {6, 9}, - }, - levels: [][]int64{ - {3, 1}, - {2}, - }, - }, - } { - rec := &sessionRecord{} - for _, f := range x.add { - ik := mik(uint64(f.num)) - rec.addTable(f.level, f.num, 1, ik, ik) - } - for _, f := range x.del { - rec.delTable(f.level, f.num) - } - vs := v.newStaging() - vs.commit(rec) - v = vs.finish() - if len(v.levels) != len(x.levels) { - t.Fatalf("#%d: invalid level count: want=%d got=%d", i, len(x.levels), len(v.levels)) - } - for j, want := range x.levels { - tables := v.levels[j] - if len(want) != len(tables) { - t.Fatalf("#%d.%d: invalid tables count: want=%d got=%d", i, j, len(want), len(tables)) - } - got := make([]int64, len(tables)) - for k, t := range tables { - got[k] = t.fd.Num - } - if !reflect.DeepEqual(want, got) { - t.Fatalf("#%d.%d: invalid tables: want=%v got=%v", i, j, want, got) - } - } - } -} diff --git a/vendor/github.com/syndtr/goleveldb/manualtest/dbstress/key.go b/vendor/github.com/syndtr/goleveldb/manualtest/dbstress/key.go deleted file mode 100644 index c9f6963..0000000 --- a/vendor/github.com/syndtr/goleveldb/manualtest/dbstress/key.go +++ /dev/null @@ -1,137 +0,0 @@ -package main - -import ( - "encoding/binary" - "fmt" - - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/storage" -) - -type ErrIkeyCorrupted struct { - Ikey []byte - Reason string -} - -func (e *ErrIkeyCorrupted) Error() string { - return fmt.Sprintf("leveldb: iKey %q corrupted: %s", e.Ikey, e.Reason) -} - -func newErrIkeyCorrupted(ikey []byte, reason string) error { - return errors.NewErrCorrupted(storage.FileDesc{}, &ErrIkeyCorrupted{append([]byte{}, ikey...), reason}) -} - -type kType int - -func (kt kType) String() string { - switch kt { - case ktDel: - return "d" - case ktVal: - return "v" - } - return "x" -} - -// Value types encoded as the last component of internal keys. -// Don't modify; this value are saved to disk. -const ( - ktDel kType = iota - ktVal -) - -// ktSeek defines the kType that should be passed when constructing an -// internal key for seeking to a particular sequence number (since we -// sort sequence numbers in decreasing order and the value type is -// embedded as the low 8 bits in the sequence number in internal keys, -// we need to use the highest-numbered ValueType, not the lowest). -const ktSeek = ktVal - -const ( - // Maximum value possible for sequence number; the 8-bits are - // used by value type, so its can packed together in single - // 64-bit integer. - kMaxSeq uint64 = (uint64(1) << 56) - 1 - // Maximum value possible for packed sequence number and type. - kMaxNum uint64 = (kMaxSeq << 8) | uint64(ktSeek) -) - -// Maximum number encoded in bytes. -var kMaxNumBytes = make([]byte, 8) - -func init() { - binary.LittleEndian.PutUint64(kMaxNumBytes, kMaxNum) -} - -type iKey []byte - -func newIkey(ukey []byte, seq uint64, kt kType) iKey { - if seq > kMaxSeq { - panic("leveldb: invalid sequence number") - } else if kt > ktVal { - panic("leveldb: invalid type") - } - - ik := make(iKey, len(ukey)+8) - copy(ik, ukey) - binary.LittleEndian.PutUint64(ik[len(ukey):], (seq<<8)|uint64(kt)) - return ik -} - -func parseIkey(ik []byte) (ukey []byte, seq uint64, kt kType, err error) { - if len(ik) < 8 { - return nil, 0, 0, newErrIkeyCorrupted(ik, "invalid length") - } - num := binary.LittleEndian.Uint64(ik[len(ik)-8:]) - seq, kt = uint64(num>>8), kType(num&0xff) - if kt > ktVal { - return nil, 0, 0, newErrIkeyCorrupted(ik, "invalid type") - } - ukey = ik[:len(ik)-8] - return -} - -func validIkey(ik []byte) bool { - _, _, _, err := parseIkey(ik) - return err == nil -} - -func (ik iKey) assert() { - if ik == nil { - panic("leveldb: nil iKey") - } - if len(ik) < 8 { - panic(fmt.Sprintf("leveldb: iKey %q, len=%d: invalid length", ik, len(ik))) - } -} - -func (ik iKey) ukey() []byte { - ik.assert() - return ik[:len(ik)-8] -} - -func (ik iKey) num() uint64 { - ik.assert() - return binary.LittleEndian.Uint64(ik[len(ik)-8:]) -} - -func (ik iKey) parseNum() (seq uint64, kt kType) { - num := ik.num() - seq, kt = uint64(num>>8), kType(num&0xff) - if kt > ktVal { - panic(fmt.Sprintf("leveldb: iKey %q, len=%d: invalid type %#x", ik, len(ik), kt)) - } - return -} - -func (ik iKey) String() string { - if ik == nil { - return "" - } - - if ukey, seq, kt, err := parseIkey(ik); err == nil { - return fmt.Sprintf("%x,%s%d", ukey, kt, seq) - } else { - return "" - } -} diff --git a/vendor/github.com/syndtr/goleveldb/manualtest/dbstress/main.go b/vendor/github.com/syndtr/goleveldb/manualtest/dbstress/main.go deleted file mode 100644 index 3344d25..0000000 --- a/vendor/github.com/syndtr/goleveldb/manualtest/dbstress/main.go +++ /dev/null @@ -1,628 +0,0 @@ -package main - -import ( - "crypto/rand" - "encoding/binary" - "flag" - "fmt" - "log" - mrand "math/rand" - "net/http" - _ "net/http/pprof" - "os" - "os/signal" - "path" - "runtime" - "strconv" - "strings" - "sync" - "sync/atomic" - "time" - - "github.com/syndtr/goleveldb/leveldb" - "github.com/syndtr/goleveldb/leveldb/errors" - "github.com/syndtr/goleveldb/leveldb/opt" - "github.com/syndtr/goleveldb/leveldb/storage" - "github.com/syndtr/goleveldb/leveldb/table" - "github.com/syndtr/goleveldb/leveldb/util" -) - -var ( - dbPath = path.Join(os.TempDir(), "goleveldb-testdb") - openFilesCacheCapacity = 500 - keyLen = 63 - valueLen = 256 - numKeys = arrayInt{100000, 1332, 531, 1234, 9553, 1024, 35743} - httpProf = "127.0.0.1:5454" - transactionProb = 0.5 - enableBlockCache = false - enableCompression = false - enableBufferPool = false - - wg = new(sync.WaitGroup) - done, fail uint32 - - bpool *util.BufferPool -) - -type arrayInt []int - -func (a arrayInt) String() string { - var str string - for i, n := range a { - if i > 0 { - str += "," - } - str += strconv.Itoa(n) - } - return str -} - -func (a *arrayInt) Set(str string) error { - var na arrayInt - for _, s := range strings.Split(str, ",") { - s = strings.TrimSpace(s) - if s != "" { - n, err := strconv.Atoi(s) - if err != nil { - return err - } - na = append(na, n) - } - } - *a = na - return nil -} - -func init() { - flag.StringVar(&dbPath, "db", dbPath, "testdb path") - flag.IntVar(&openFilesCacheCapacity, "openfilescachecap", openFilesCacheCapacity, "open files cache capacity") - flag.IntVar(&keyLen, "keylen", keyLen, "key length") - flag.IntVar(&valueLen, "valuelen", valueLen, "value length") - flag.Var(&numKeys, "numkeys", "num keys") - flag.StringVar(&httpProf, "httpprof", httpProf, "http pprof listen addr") - flag.Float64Var(&transactionProb, "transactionprob", transactionProb, "probablity of writes using transaction") - flag.BoolVar(&enableBufferPool, "enablebufferpool", enableBufferPool, "enable buffer pool") - flag.BoolVar(&enableBlockCache, "enableblockcache", enableBlockCache, "enable block cache") - flag.BoolVar(&enableCompression, "enablecompression", enableCompression, "enable block compression") -} - -func randomData(dst []byte, ns, prefix byte, i uint32, dataLen int) []byte { - if dataLen < (2+4+4)*2+4 { - panic("dataLen is too small") - } - if cap(dst) < dataLen { - dst = make([]byte, dataLen) - } else { - dst = dst[:dataLen] - } - half := (dataLen - 4) / 2 - if _, err := rand.Reader.Read(dst[2 : half-8]); err != nil { - panic(err) - } - dst[0] = ns - dst[1] = prefix - binary.LittleEndian.PutUint32(dst[half-8:], i) - binary.LittleEndian.PutUint32(dst[half-8:], i) - binary.LittleEndian.PutUint32(dst[half-4:], util.NewCRC(dst[:half-4]).Value()) - full := half * 2 - copy(dst[half:full], dst[:half]) - if full < dataLen-4 { - if _, err := rand.Reader.Read(dst[full : dataLen-4]); err != nil { - panic(err) - } - } - binary.LittleEndian.PutUint32(dst[dataLen-4:], util.NewCRC(dst[:dataLen-4]).Value()) - return dst -} - -func dataSplit(data []byte) (data0, data1 []byte) { - n := (len(data) - 4) / 2 - return data[:n], data[n : n+n] -} - -func dataNS(data []byte) byte { - return data[0] -} - -func dataPrefix(data []byte) byte { - return data[1] -} - -func dataI(data []byte) uint32 { - return binary.LittleEndian.Uint32(data[(len(data)-4)/2-8:]) -} - -func dataChecksum(data []byte) (uint32, uint32) { - checksum0 := binary.LittleEndian.Uint32(data[len(data)-4:]) - checksum1 := util.NewCRC(data[:len(data)-4]).Value() - return checksum0, checksum1 -} - -func dataPrefixSlice(ns, prefix byte) *util.Range { - return util.BytesPrefix([]byte{ns, prefix}) -} - -func dataNsSlice(ns byte) *util.Range { - return util.BytesPrefix([]byte{ns}) -} - -type testingStorage struct { - storage.Storage -} - -func (ts *testingStorage) scanTable(fd storage.FileDesc, checksum bool) (corrupted bool) { - r, err := ts.Open(fd) - if err != nil { - log.Fatal(err) - } - defer r.Close() - - size, err := r.Seek(0, os.SEEK_END) - if err != nil { - log.Fatal(err) - } - - o := &opt.Options{ - DisableLargeBatchTransaction: true, - Strict: opt.NoStrict, - } - if checksum { - o.Strict = opt.StrictBlockChecksum | opt.StrictReader - } - tr, err := table.NewReader(r, size, fd, nil, bpool, o) - if err != nil { - log.Fatal(err) - } - defer tr.Release() - - checkData := func(i int, t string, data []byte) bool { - if len(data) == 0 { - panic(fmt.Sprintf("[%v] nil data: i=%d t=%s", fd, i, t)) - } - - checksum0, checksum1 := dataChecksum(data) - if checksum0 != checksum1 { - atomic.StoreUint32(&fail, 1) - atomic.StoreUint32(&done, 1) - corrupted = true - - data0, data1 := dataSplit(data) - data0c0, data0c1 := dataChecksum(data0) - data1c0, data1c1 := dataChecksum(data1) - log.Printf("FATAL: [%v] Corrupted data i=%d t=%s (%#x != %#x): %x(%v) vs %x(%v)", - fd, i, t, checksum0, checksum1, data0, data0c0 == data0c1, data1, data1c0 == data1c1) - return true - } - return false - } - - iter := tr.NewIterator(nil, nil) - defer iter.Release() - for i := 0; iter.Next(); i++ { - ukey, _, kt, kerr := parseIkey(iter.Key()) - if kerr != nil { - atomic.StoreUint32(&fail, 1) - atomic.StoreUint32(&done, 1) - corrupted = true - - log.Printf("FATAL: [%v] Corrupted ikey i=%d: %v", fd, i, kerr) - return - } - if checkData(i, "key", ukey) { - return - } - if kt == ktVal && checkData(i, "value", iter.Value()) { - return - } - } - if err := iter.Error(); err != nil { - if errors.IsCorrupted(err) { - atomic.StoreUint32(&fail, 1) - atomic.StoreUint32(&done, 1) - corrupted = true - - log.Printf("FATAL: [%v] Corruption detected: %v", fd, err) - } else { - log.Fatal(err) - } - } - - return -} - -func (ts *testingStorage) Remove(fd storage.FileDesc) error { - if atomic.LoadUint32(&fail) == 1 { - return nil - } - - if fd.Type == storage.TypeTable { - if ts.scanTable(fd, true) { - return nil - } - } - return ts.Storage.Remove(fd) -} - -type latencyStats struct { - mark time.Time - dur, min, max time.Duration - num int -} - -func (s *latencyStats) start() { - s.mark = time.Now() -} - -func (s *latencyStats) record(n int) { - if s.mark.IsZero() { - panic("not started") - } - dur := time.Now().Sub(s.mark) - dur1 := dur / time.Duration(n) - if dur1 < s.min || s.min == 0 { - s.min = dur1 - } - if dur1 > s.max { - s.max = dur1 - } - s.dur += dur - s.num += n - s.mark = time.Time{} -} - -func (s *latencyStats) ratePerSec() int { - durSec := s.dur / time.Second - if durSec > 0 { - return s.num / int(durSec) - } - return s.num -} - -func (s *latencyStats) avg() time.Duration { - if s.num > 0 { - return s.dur / time.Duration(s.num) - } - return 0 -} - -func (s *latencyStats) add(x *latencyStats) { - if x.min < s.min || s.min == 0 { - s.min = x.min - } - if x.max > s.max { - s.max = x.max - } - s.dur += x.dur - s.num += x.num -} - -func main() { - flag.Parse() - - if enableBufferPool { - bpool = util.NewBufferPool(opt.DefaultBlockSize + 128) - } - - log.Printf("Test DB stored at %q", dbPath) - if httpProf != "" { - log.Printf("HTTP pprof listening at %q", httpProf) - runtime.SetBlockProfileRate(1) - go func() { - if err := http.ListenAndServe(httpProf, nil); err != nil { - log.Fatalf("HTTPPROF: %v", err) - } - }() - } - - runtime.GOMAXPROCS(runtime.NumCPU()) - - os.RemoveAll(dbPath) - stor, err := storage.OpenFile(dbPath, false) - if err != nil { - log.Fatal(err) - } - tstor := &testingStorage{stor} - defer tstor.Close() - - fatalf := func(err error, format string, v ...interface{}) { - atomic.StoreUint32(&fail, 1) - atomic.StoreUint32(&done, 1) - log.Printf("FATAL: "+format, v...) - if err != nil && errors.IsCorrupted(err) { - cerr := err.(*errors.ErrCorrupted) - if !cerr.Fd.Zero() && cerr.Fd.Type == storage.TypeTable { - log.Print("FATAL: corruption detected, scanning...") - if !tstor.scanTable(storage.FileDesc{Type: storage.TypeTable, Num: cerr.Fd.Num}, false) { - log.Printf("FATAL: unable to find corrupted key/value pair in table %v", cerr.Fd) - } - } - } - runtime.Goexit() - } - - if openFilesCacheCapacity == 0 { - openFilesCacheCapacity = -1 - } - o := &opt.Options{ - OpenFilesCacheCapacity: openFilesCacheCapacity, - DisableBufferPool: !enableBufferPool, - DisableBlockCache: !enableBlockCache, - ErrorIfExist: true, - Compression: opt.NoCompression, - } - if enableCompression { - o.Compression = opt.DefaultCompression - } - - db, err := leveldb.Open(tstor, o) - if err != nil { - log.Fatal(err) - } - defer db.Close() - - var ( - mu = &sync.Mutex{} - gGetStat = &latencyStats{} - gIterStat = &latencyStats{} - gWriteStat = &latencyStats{} - gTrasactionStat = &latencyStats{} - startTime = time.Now() - - writeReq = make(chan *leveldb.Batch) - writeAck = make(chan error) - writeAckAck = make(chan struct{}) - ) - - go func() { - for b := range writeReq { - - var err error - if mrand.Float64() < transactionProb { - log.Print("> Write using transaction") - gTrasactionStat.start() - var tr *leveldb.Transaction - if tr, err = db.OpenTransaction(); err == nil { - if err = tr.Write(b, nil); err == nil { - if err = tr.Commit(); err == nil { - gTrasactionStat.record(b.Len()) - } - } else { - tr.Discard() - } - } - } else { - gWriteStat.start() - if err = db.Write(b, nil); err == nil { - gWriteStat.record(b.Len()) - } - } - writeAck <- err - <-writeAckAck - } - }() - - go func() { - for { - time.Sleep(3 * time.Second) - - log.Print("------------------------") - - log.Printf("> Elapsed=%v", time.Now().Sub(startTime)) - mu.Lock() - log.Printf("> GetLatencyMin=%v GetLatencyMax=%v GetLatencyAvg=%v GetRatePerSec=%d", - gGetStat.min, gGetStat.max, gGetStat.avg(), gGetStat.ratePerSec()) - log.Printf("> IterLatencyMin=%v IterLatencyMax=%v IterLatencyAvg=%v IterRatePerSec=%d", - gIterStat.min, gIterStat.max, gIterStat.avg(), gIterStat.ratePerSec()) - log.Printf("> WriteLatencyMin=%v WriteLatencyMax=%v WriteLatencyAvg=%v WriteRatePerSec=%d", - gWriteStat.min, gWriteStat.max, gWriteStat.avg(), gWriteStat.ratePerSec()) - log.Printf("> TransactionLatencyMin=%v TransactionLatencyMax=%v TransactionLatencyAvg=%v TransactionRatePerSec=%d", - gTrasactionStat.min, gTrasactionStat.max, gTrasactionStat.avg(), gTrasactionStat.ratePerSec()) - mu.Unlock() - - cachedblock, _ := db.GetProperty("leveldb.cachedblock") - openedtables, _ := db.GetProperty("leveldb.openedtables") - alivesnaps, _ := db.GetProperty("leveldb.alivesnaps") - aliveiters, _ := db.GetProperty("leveldb.aliveiters") - blockpool, _ := db.GetProperty("leveldb.blockpool") - writeDelay, _ := db.GetProperty("leveldb.writedelay") - log.Printf("> BlockCache=%s OpenedTables=%s AliveSnaps=%s AliveIter=%s BlockPool=%q WriteDelay=%q", - cachedblock, openedtables, alivesnaps, aliveiters, blockpool, writeDelay) - log.Print("------------------------") - } - }() - - for ns, numKey := range numKeys { - func(ns, numKey int) { - log.Printf("[%02d] STARTING: numKey=%d", ns, numKey) - - keys := make([][]byte, numKey) - for i := range keys { - keys[i] = randomData(nil, byte(ns), 1, uint32(i), keyLen) - } - - wg.Add(1) - go func() { - var wi uint32 - defer func() { - log.Printf("[%02d] WRITER DONE #%d", ns, wi) - wg.Done() - }() - - var ( - b = new(leveldb.Batch) - k2, v2 []byte - nReader int32 - ) - for atomic.LoadUint32(&done) == 0 { - log.Printf("[%02d] WRITER #%d", ns, wi) - - b.Reset() - for _, k1 := range keys { - k2 = randomData(k2, byte(ns), 2, wi, keyLen) - v2 = randomData(v2, byte(ns), 3, wi, valueLen) - b.Put(k2, v2) - b.Put(k1, k2) - } - writeReq <- b - if err := <-writeAck; err != nil { - writeAckAck <- struct{}{} - fatalf(err, "[%02d] WRITER #%d db.Write: %v", ns, wi, err) - } - - snap, err := db.GetSnapshot() - if err != nil { - writeAckAck <- struct{}{} - fatalf(err, "[%02d] WRITER #%d db.GetSnapshot: %v", ns, wi, err) - } - - writeAckAck <- struct{}{} - - wg.Add(1) - atomic.AddInt32(&nReader, 1) - go func(snapwi uint32, snap *leveldb.Snapshot) { - var ( - ri int - iterStat = &latencyStats{} - getStat = &latencyStats{} - ) - defer func() { - mu.Lock() - gGetStat.add(getStat) - gIterStat.add(iterStat) - mu.Unlock() - - atomic.AddInt32(&nReader, -1) - log.Printf("[%02d] READER #%d.%d DONE Snap=%v Alive=%d IterLatency=%v GetLatency=%v", ns, snapwi, ri, snap, atomic.LoadInt32(&nReader), iterStat.avg(), getStat.avg()) - snap.Release() - wg.Done() - }() - - stopi := snapwi + 3 - for (ri < 3 || atomic.LoadUint32(&wi) < stopi) && atomic.LoadUint32(&done) == 0 { - var n int - iter := snap.NewIterator(dataPrefixSlice(byte(ns), 1), nil) - iterStat.start() - for iter.Next() { - k1 := iter.Key() - k2 := iter.Value() - iterStat.record(1) - - if dataNS(k2) != byte(ns) { - fatalf(nil, "[%02d] READER #%d.%d K%d invalid in-key NS: want=%d got=%d", ns, snapwi, ri, n, ns, dataNS(k2)) - } - - kwritei := dataI(k2) - if kwritei != snapwi { - fatalf(nil, "[%02d] READER #%d.%d K%d invalid in-key iter num: %d", ns, snapwi, ri, n, kwritei) - } - - getStat.start() - v2, err := snap.Get(k2, nil) - if err != nil { - fatalf(err, "[%02d] READER #%d.%d K%d snap.Get: %v\nk1: %x\n -> k2: %x", ns, snapwi, ri, n, err, k1, k2) - } - getStat.record(1) - - if checksum0, checksum1 := dataChecksum(v2); checksum0 != checksum1 { - err := &errors.ErrCorrupted{Fd: storage.FileDesc{0xff, 0}, Err: fmt.Errorf("v2: %x: checksum mismatch: %v vs %v", v2, checksum0, checksum1)} - fatalf(err, "[%02d] READER #%d.%d K%d snap.Get: %v\nk1: %x\n -> k2: %x", ns, snapwi, ri, n, err, k1, k2) - } - - n++ - iterStat.start() - } - iter.Release() - if err := iter.Error(); err != nil { - fatalf(err, "[%02d] READER #%d.%d K%d iter.Error: %v", ns, snapwi, ri, numKey, err) - } - if n != numKey { - fatalf(nil, "[%02d] READER #%d.%d missing keys: want=%d got=%d", ns, snapwi, ri, numKey, n) - } - - ri++ - } - }(wi, snap) - - atomic.AddUint32(&wi, 1) - } - }() - - delB := new(leveldb.Batch) - wg.Add(1) - go func() { - var ( - i int - iterStat = &latencyStats{} - ) - defer func() { - log.Printf("[%02d] SCANNER DONE #%d", ns, i) - wg.Done() - }() - - time.Sleep(2 * time.Second) - - for atomic.LoadUint32(&done) == 0 { - var n int - delB.Reset() - iter := db.NewIterator(dataNsSlice(byte(ns)), nil) - iterStat.start() - for iter.Next() && atomic.LoadUint32(&done) == 0 { - k := iter.Key() - v := iter.Value() - iterStat.record(1) - - for ci, x := range [...][]byte{k, v} { - checksum0, checksum1 := dataChecksum(x) - if checksum0 != checksum1 { - if ci == 0 { - fatalf(nil, "[%02d] SCANNER %d.%d invalid key checksum: want %d, got %d\n%x -> %x", ns, i, n, checksum0, checksum1, k, v) - } else { - fatalf(nil, "[%02d] SCANNER %d.%d invalid value checksum: want %d, got %d\n%x -> %x", ns, i, n, checksum0, checksum1, k, v) - } - } - } - - if dataPrefix(k) == 2 || mrand.Int()%999 == 0 { - delB.Delete(k) - } - - n++ - iterStat.start() - } - iter.Release() - if err := iter.Error(); err != nil { - fatalf(err, "[%02d] SCANNER #%d.%d iter.Error: %v", ns, i, n, err) - } - - if n > 0 { - log.Printf("[%02d] SCANNER #%d IterLatency=%v", ns, i, iterStat.avg()) - } - - if delB.Len() > 0 && atomic.LoadUint32(&done) == 0 { - t := time.Now() - writeReq <- delB - if err := <-writeAck; err != nil { - writeAckAck <- struct{}{} - fatalf(err, "[%02d] SCANNER #%d db.Write: %v", ns, i, err) - } else { - writeAckAck <- struct{}{} - } - log.Printf("[%02d] SCANNER #%d Deleted=%d Time=%v", ns, i, delB.Len(), time.Now().Sub(t)) - } - - i++ - } - }() - }(ns, numKey) - } - - go func() { - sig := make(chan os.Signal) - signal.Notify(sig, os.Interrupt, os.Kill) - log.Printf("Got signal: %v, exiting...", <-sig) - atomic.StoreUint32(&done, 1) - }() - - wg.Wait() -} diff --git a/vendor/github.com/syndtr/goleveldb/manualtest/filelock/main.go b/vendor/github.com/syndtr/goleveldb/manualtest/filelock/main.go deleted file mode 100644 index 192951f..0000000 --- a/vendor/github.com/syndtr/goleveldb/manualtest/filelock/main.go +++ /dev/null @@ -1,85 +0,0 @@ -package main - -import ( - "bufio" - "bytes" - "flag" - "fmt" - "os" - "os/exec" - "path/filepath" - - "github.com/syndtr/goleveldb/leveldb/storage" -) - -var ( - filename string - child bool -) - -func init() { - flag.StringVar(&filename, "filename", filepath.Join(os.TempDir(), "goleveldb_filelock_test"), "Filename used for testing") - flag.BoolVar(&child, "child", false, "This is the child") -} - -func runChild() error { - var args []string - args = append(args, os.Args[1:]...) - args = append(args, "-child") - cmd := exec.Command(os.Args[0], args...) - var out bytes.Buffer - cmd.Stdout = &out - err := cmd.Run() - r := bufio.NewReader(&out) - for { - line, _, e1 := r.ReadLine() - if e1 != nil { - break - } - fmt.Println("[Child]", string(line)) - } - return err -} - -func main() { - flag.Parse() - - fmt.Printf("Using path: %s\n", filename) - if child { - fmt.Println("Child flag set.") - } - - stor, err := storage.OpenFile(filename, false) - if err != nil { - fmt.Printf("Could not open storage: %s", err) - os.Exit(10) - } - - if !child { - fmt.Println("Executing child -- first test (expecting error)") - err := runChild() - if err == nil { - fmt.Println("Expecting error from child") - } else if err.Error() != "exit status 10" { - fmt.Println("Got unexpected error from child:", err) - } else { - fmt.Printf("Got error from child: %s (expected)\n", err) - } - } - - err = stor.Close() - if err != nil { - fmt.Printf("Error when closing storage: %s", err) - os.Exit(11) - } - - if !child { - fmt.Println("Executing child -- second test") - err := runChild() - if err != nil { - fmt.Println("Got unexpected error from child:", err) - } - } - - os.RemoveAll(filename) -} diff --git a/vendor/github.com/tinylib/msgp/.gitignore b/vendor/github.com/tinylib/msgp/.gitignore deleted file mode 100644 index b77b56e..0000000 --- a/vendor/github.com/tinylib/msgp/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -_generated/generated.go -_generated/generated_test.go -_generated/*_gen.go -_generated/*_gen_test.go -msgp/defgen_test.go -msgp/cover.out -*~ -*.coverprofile diff --git a/vendor/github.com/tinylib/msgp/.travis.yml b/vendor/github.com/tinylib/msgp/.travis.yml deleted file mode 100644 index 0fe66da..0000000 --- a/vendor/github.com/tinylib/msgp/.travis.yml +++ /dev/null @@ -1,11 +0,0 @@ -language: go - -go: - - 1.9 - - tip - -env: - - GIMME_ARCH=amd64 - - GIMME_ARCH=386 - -script: "make travis" diff --git a/vendor/github.com/tinylib/msgp/LICENSE b/vendor/github.com/tinylib/msgp/LICENSE deleted file mode 100644 index 14d6042..0000000 --- a/vendor/github.com/tinylib/msgp/LICENSE +++ /dev/null @@ -1,8 +0,0 @@ -Copyright (c) 2014 Philip Hofer -Portions Copyright (c) 2009 The Go Authors (license at http://golang.org) where indicated - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/vendor/github.com/tinylib/msgp/Makefile b/vendor/github.com/tinylib/msgp/Makefile deleted file mode 100644 index 596efec..0000000 --- a/vendor/github.com/tinylib/msgp/Makefile +++ /dev/null @@ -1,52 +0,0 @@ - -# NOTE: This Makefile is only necessary if you -# plan on developing the msgp tool and library. -# Installation can still be performed with a -# normal `go install`. - -# generated integration test files -GGEN = ./_generated/generated.go ./_generated/generated_test.go -# generated unit test files -MGEN = ./msgp/defgen_test.go - -SHELL := /bin/bash - -BIN = $(GOBIN)/msgp - -.PHONY: clean wipe install get-deps bench all - -$(BIN): */*.go - @go install ./... - -install: $(BIN) - -$(GGEN): ./_generated/def.go - go generate ./_generated - -$(MGEN): ./msgp/defs_test.go - go generate ./msgp - -test: all - go test -v ./... - -bench: all - go test -bench ./... - -clean: - $(RM) $(GGEN) $(MGEN) - -wipe: clean - $(RM) $(BIN) - -get-deps: - go get -d -t ./... - -all: install $(GGEN) $(MGEN) - -# travis CI enters here -travis: - go get -d -t ./... - go build -o "$${GOPATH%%:*}/bin/msgp" . - go generate ./msgp - go generate ./_generated - go test -v ./... diff --git a/vendor/github.com/tinylib/msgp/README.md b/vendor/github.com/tinylib/msgp/README.md deleted file mode 100644 index 1328cca..0000000 --- a/vendor/github.com/tinylib/msgp/README.md +++ /dev/null @@ -1,102 +0,0 @@ -MessagePack Code Generator [![Build Status](https://travis-ci.org/tinylib/msgp.svg?branch=master)](https://travis-ci.org/tinylib/msgp) -======= - -This is a code generation tool and serialization library for [MessagePack](http://msgpack.org). You can read more about MessagePack [in the wiki](http://github.com/tinylib/msgp/wiki), or at [msgpack.org](http://msgpack.org). - -### Why? - -- Use Go as your schema language -- Performance -- [JSON interop](http://godoc.org/github.com/tinylib/msgp/msgp#CopyToJSON) -- [User-defined extensions](http://github.com/tinylib/msgp/wiki/Using-Extensions) -- Type safety -- Encoding flexibility - -### Quickstart - -In a source file, include the following directive: - -```go -//go:generate msgp -``` - -The `msgp` command will generate serialization methods for all exported type declarations in the file. - -You can [read more about the code generation options here](http://github.com/tinylib/msgp/wiki/Using-the-Code-Generator). - -### Use - -Field names can be set in much the same way as the `encoding/json` package. For example: - -```go -type Person struct { - Name string `msg:"name"` - Address string `msg:"address"` - Age int `msg:"age"` - Hidden string `msg:"-"` // this field is ignored - unexported bool // this field is also ignored -} -``` - -By default, the code generator will satisfy `msgp.Sizer`, `msgp.Encodable`, `msgp.Decodable`, -`msgp.Marshaler`, and `msgp.Unmarshaler`. Carefully-designed applications can use these methods to do -marshalling/unmarshalling with zero heap allocations. - -While `msgp.Marshaler` and `msgp.Unmarshaler` are quite similar to the standard library's -`json.Marshaler` and `json.Unmarshaler`, `msgp.Encodable` and `msgp.Decodable` are useful for -stream serialization. (`*msgp.Writer` and `*msgp.Reader` are essentially protocol-aware versions -of `*bufio.Writer` and `*bufio.Reader`, respectively.) - -### Features - - - Extremely fast generated code - - Test and benchmark generation - - JSON interoperability (see `msgp.CopyToJSON() and msgp.UnmarshalAsJSON()`) - - Support for complex type declarations - - Native support for Go's `time.Time`, `complex64`, and `complex128` types - - Generation of both `[]byte`-oriented and `io.Reader/io.Writer`-oriented methods - - Support for arbitrary type system extensions - - [Preprocessor directives](http://github.com/tinylib/msgp/wiki/Preprocessor-Directives) - - File-based dependency model means fast codegen regardless of source tree size. - -Consider the following: -```go -const Eight = 8 -type MyInt int -type Data []byte - -type Struct struct { - Which map[string]*MyInt `msg:"which"` - Other Data `msg:"other"` - Nums [Eight]float64 `msg:"nums"` -} -``` -As long as the declarations of `MyInt` and `Data` are in the same file as `Struct`, the parser will determine that the type information for `MyInt` and `Data` can be passed into the definition of `Struct` before its methods are generated. - -#### Extensions - -MessagePack supports defining your own types through "extensions," which are just a tuple of -the data "type" (`int8`) and the raw binary. You [can see a worked example in the wiki.](http://github.com/tinylib/msgp/wiki/Using-Extensions) - -### Status - -Mostly stable, in that no breaking changes have been made to the `/msgp` library in more than a year. Newer versions -of the code may generate different code than older versions for performance reasons. I (@philhofer) am aware of a -number of stability-critical commercial applications that use this code with good results. But, caveat emptor. - -You can read more about how `msgp` maps MessagePack types onto Go types [in the wiki](http://github.com/tinylib/msgp/wiki). - -Here some of the known limitations/restrictions: - -- Identifiers from outside the processed source file are assumed (optimistically) to satisfy the generator's interfaces. If this isn't the case, your code will fail to compile. -- Like most serializers, `chan` and `func` fields are ignored, as well as non-exported fields. -- Encoding of `interface{}` is limited to built-ins or types that have explicit encoding methods. -- _Maps must have `string` keys._ This is intentional (as it preserves JSON interop.) Although non-string map keys are not forbidden by the MessagePack standard, many serializers impose this restriction. (It also means *any* well-formed `struct` can be de-serialized into a `map[string]interface{}`.) The only exception to this rule is that the deserializers will allow you to read map keys encoded as `bin` types, due to the fact that some legacy encodings permitted this. (However, those values will still be cast to Go `string`s, and they will be converted to `str` types when re-encoded. It is the responsibility of the user to ensure that map keys are UTF-8 safe in this case.) The same rules hold true for JSON translation. - -If the output compiles, then there's a pretty good chance things are fine. (Plus, we generate tests for you.) *Please, please, please* file an issue if you think the generator is writing broken code. - -### Performance - -If you like benchmarks, see [here](http://bravenewgeek.com/so-you-wanna-go-fast/) and [here](https://github.com/alecthomas/go_serialization_benchmarks). - -As one might expect, the generated methods that deal with `[]byte` are faster for small objects, but the `io.Reader/Writer` methods are generally more memory-efficient (and, at some point, faster) for large (> 2KB) objects. diff --git a/vendor/github.com/tinylib/msgp/_generated/convert.go b/vendor/github.com/tinylib/msgp/_generated/convert.go deleted file mode 100644 index 964cff7..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/convert.go +++ /dev/null @@ -1,83 +0,0 @@ -package _generated - -import "errors" - -//go:generate msgp - -//msgp:shim ConvertStringVal as:string using:fromConvertStringVal/toConvertStringVal mode:convert -//msgp:ignore ConvertStringVal - -func fromConvertStringVal(v ConvertStringVal) (string, error) { - return string(v), nil -} - -func toConvertStringVal(s string) (ConvertStringVal, error) { - return ConvertStringVal(s), nil -} - -type ConvertStringVal string - -type ConvertString struct { - String ConvertStringVal -} - -type ConvertStringSlice struct { - Strings []ConvertStringVal -} - -type ConvertStringMapValue struct { - Strings map[string]ConvertStringVal -} - -//msgp:shim ConvertIntfVal as:interface{} using:fromConvertIntfVal/toConvertIntfVal mode:convert -//msgp:ignore ConvertIntfVal - -func fromConvertIntfVal(v ConvertIntfVal) (interface{}, error) { - return v.Test, nil -} - -func toConvertIntfVal(s interface{}) (ConvertIntfVal, error) { - return ConvertIntfVal{Test: s.(string)}, nil -} - -type ConvertIntfVal struct { - Test string -} - -type ConvertIntf struct { - Intf ConvertIntfVal -} - -//msgp:shim ConvertErrVal as:string using:fromConvertErrVal/toConvertErrVal mode:convert -//msgp:ignore ConvertErrVal - -var ( - errConvertFrom = errors.New("error: convert from") - errConvertTo = errors.New("error: convert to") -) - -const ( - fromFailStr = "fromfail" - toFailStr = "tofail" -) - -func fromConvertErrVal(v ConvertErrVal) (string, error) { - s := string(v) - if s == fromFailStr { - return "", errConvertFrom - } - return s, nil -} - -func toConvertErrVal(s string) (ConvertErrVal, error) { - if s == toFailStr { - return ConvertErrVal(""), errConvertTo - } - return ConvertErrVal(s), nil -} - -type ConvertErrVal string - -type ConvertErr struct { - Err ConvertErrVal -} diff --git a/vendor/github.com/tinylib/msgp/_generated/convert_test.go b/vendor/github.com/tinylib/msgp/_generated/convert_test.go deleted file mode 100644 index 5d22469..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/convert_test.go +++ /dev/null @@ -1,59 +0,0 @@ -package _generated - -import ( - "bytes" - "testing" - - "github.com/tinylib/msgp/msgp" -) - -func TestConvertFromEncodeError(t *testing.T) { - e := ConvertErr{ConvertErrVal(fromFailStr)} - var buf bytes.Buffer - w := msgp.NewWriter(&buf) - err := e.EncodeMsg(w) - if err != errConvertFrom { - t.Fatalf("expected conversion error, found %v", err.Error()) - } -} - -func TestConvertToEncodeError(t *testing.T) { - var in, out ConvertErr - in = ConvertErr{ConvertErrVal(toFailStr)} - var buf bytes.Buffer - w := msgp.NewWriter(&buf) - err := in.EncodeMsg(w) - if err != nil { - t.FailNow() - } - w.Flush() - - r := msgp.NewReader(&buf) - err = (&out).DecodeMsg(r) - if err != errConvertTo { - t.Fatalf("expected conversion error, found %v", err.Error()) - } -} - -func TestConvertFromMarshalError(t *testing.T) { - e := ConvertErr{ConvertErrVal(fromFailStr)} - var b []byte - _, err := e.MarshalMsg(b) - if err != errConvertFrom { - t.Fatalf("expected conversion error, found %v", err.Error()) - } -} - -func TestConvertToMarshalError(t *testing.T) { - var in, out ConvertErr - in = ConvertErr{ConvertErrVal(toFailStr)} - b, err := in.MarshalMsg(nil) - if err != nil { - t.FailNow() - } - - _, err = (&out).UnmarshalMsg(b) - if err != errConvertTo { - t.Fatalf("expected conversion error, found %v", err.Error()) - } -} diff --git a/vendor/github.com/tinylib/msgp/_generated/def.go b/vendor/github.com/tinylib/msgp/_generated/def.go deleted file mode 100644 index db39af0..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/def.go +++ /dev/null @@ -1,265 +0,0 @@ -package _generated - -import ( - "os" - "time" - - "github.com/tinylib/msgp/msgp" -) - -//go:generate msgp -o generated.go - -// All of the struct -// definitions in this -// file are fed to the code -// generator when `make test` is -// called, followed by an -// invocation of `go test -v` in this -// directory. A simple way of testing -// a struct definition is -// by adding it to this file. - -type Block [32]byte - -// tests edge-cases with -// compiling size compilation. -type X struct { - Values [32]byte // should compile to 32*msgp.ByteSize; encoded as Bin - ValuesPtr *[32]byte // check (*)[:] deref - More Block // should be identical to the above - Others [][32]int32 // should compile to len(x.Others)*32*msgp.Int32Size - Matrix [][]int32 // should not optimize - ManyFixed []Fixed -} - -// test fixed-size struct -// size compilation -type Fixed struct { - A float64 - B bool -} - -type TestType struct { - F *float64 `msg:"float"` - Els map[string]string `msg:"elements"` - Obj struct { // test anonymous struct - ValueA string `msg:"value_a"` - ValueB []byte `msg:"value_b"` - } `msg:"object"` - Child *TestType `msg:"child"` - Time time.Time `msg:"time"` - Any interface{} `msg:"any"` - Appended msgp.Raw `msg:"appended"` - Num msgp.Number `msg:"num"` - Byte byte - Rune rune - RunePtr *rune - RunePtrPtr **rune - RuneSlice []rune - Slice1 []string - Slice2 []string - SlicePtr *[]string -} - -//msgp:tuple Object -type Object struct { - ObjectNo string `msg:"objno"` - Slice1 []string `msg:"slice1"` - Slice2 []string `msg:"slice2"` - MapMap map[string]map[string]string -} - -//msgp:tuple TestBench - -type TestBench struct { - Name string - BirthDay time.Time - Phone string - Siblings int - Spouse bool - Money float64 -} - -//msgp:tuple TestFast - -type TestFast struct { - Lat, Long, Alt float64 // test inline decl - Data []byte -} - -// Test nested aliases -type FastAlias TestFast -type AliasContainer struct { - Fast FastAlias -} - -// Test dependency resolution -type IntA int -type IntB IntA -type IntC IntB - -type TestHidden struct { - A string - B []float64 - Bad func(string) bool // This results in a warning: field "Bad" unsupported -} - -type Embedded struct { - *Embedded // test embedded field - Children []Embedded - PtrChildren []*Embedded - Other string -} - -const eight = 8 - -type Things struct { - Cmplx complex64 `msg:"complex"` // test slices - Vals []int32 `msg:"values"` - Arr [msgp.ExtensionPrefixSize]float64 `msg:"arr"` // test const array and *ast.SelectorExpr as array size - Arr2 [4]float64 `msg:"arr2"` // test basic lit array - Ext *msgp.RawExtension `msg:"ext,extension"` // test extension - Oext msgp.RawExtension `msg:"oext,extension"` // test extension reference -} - -//msgp:shim SpecialID as:[]byte using:toBytes/fromBytes - -type SpecialID string -type TestObj struct{ ID1, ID2 SpecialID } - -func toBytes(id SpecialID) []byte { return []byte(string(id)) } -func fromBytes(id []byte) SpecialID { return SpecialID(string(id)) } - -type MyEnum byte - -const ( - A MyEnum = iota - B - C - D - invalid -) - -// test shim directive (below) - -//msgp:shim MyEnum as:string using:(MyEnum).String/myenumStr - -//msgp:shim *os.File as:string using:filetostr/filefromstr - -func filetostr(f *os.File) string { - return f.Name() -} - -func filefromstr(s string) *os.File { - f, _ := os.Open(s) - return f -} - -func (m MyEnum) String() string { - switch m { - case A: - return "A" - case B: - return "B" - case C: - return "C" - case D: - return "D" - default: - return "" - } -} - -func myenumStr(s string) MyEnum { - switch s { - case "A": - return A - case "B": - return B - case "C": - return C - case "D": - return D - default: - return invalid - } -} - -// test pass-specific directive -//msgp:decode ignore Insane - -type Insane [3]map[string]struct{ A, B CustomInt } - -type Custom struct { - Bts CustomBytes `msg:"bts"` - Mp map[string]*Embedded `msg:"mp"` - Enums []MyEnum `msg:"enums"` // test explicit enum shim - Some FileHandle `msg:file_handle` -} - -type Files []*os.File - -type FileHandle struct { - Relevant Files `msg:"files"` - Name string `msg:"name"` -} - -type CustomInt int -type CustomBytes []byte - -type Wrapper struct { - Tree *Tree -} - -type Tree struct { - Children []Tree - Element int - Parent *Wrapper -} - -// Ensure all different widths of integer can be used as constant keys. -const ( - ConstantInt int = 8 - ConstantInt8 int8 = 8 - ConstantInt16 int16 = 8 - ConstantInt32 int32 = 8 - ConstantInt64 int64 = 8 - ConstantUint uint = 8 - ConstantUint8 uint8 = 8 - ConstantUint16 uint16 = 8 - ConstantUint32 uint32 = 8 - ConstantUint64 uint64 = 8 -) - -type ArrayConstants struct { - ConstantInt [ConstantInt]string - ConstantInt8 [ConstantInt8]string - ConstantInt16 [ConstantInt16]string - ConstantInt32 [ConstantInt32]string - ConstantInt64 [ConstantInt64]string - ConstantUint [ConstantUint]string - ConstantUint8 [ConstantUint8]string - ConstantUint16 [ConstantUint16]string - ConstantUint32 [ConstantUint32]string - ConstantUint64 [ConstantUint64]string - ConstantHex [0x16]string - ConstantOctal [07]string -} - -// Ensure non-msg struct tags work: -// https://github.com/tinylib/msgp/issues/201 - -type NonMsgStructTags struct { - A []string `json:"fooJSON" msg:"fooMsgp"` - B string `json:"barJSON"` - C []string `json:"bazJSON" msg:"-"` - Nested []struct { - A []string `json:"a"` - B string `json:"b"` - C []string `json:"c"` - VeryNested []struct { - A []string `json:"a"` - B []string `msg:"bbbb" xml:"-"` - } - } -} diff --git a/vendor/github.com/tinylib/msgp/_generated/def_test.go b/vendor/github.com/tinylib/msgp/_generated/def_test.go deleted file mode 100644 index 5d2e80f..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/def_test.go +++ /dev/null @@ -1,76 +0,0 @@ -package _generated - -import ( - "bytes" - "reflect" - "testing" - - "github.com/tinylib/msgp/msgp" -) - -func TestRuneEncodeDecode(t *testing.T) { - tt := &TestType{} - r := 'r' - rp := &r - tt.Rune = r - tt.RunePtr = &r - tt.RunePtrPtr = &rp - tt.RuneSlice = []rune{'a', 'b', '😳'} - - var buf bytes.Buffer - wrt := msgp.NewWriter(&buf) - if err := tt.EncodeMsg(wrt); err != nil { - t.Errorf("%v", err) - } - wrt.Flush() - - var out TestType - rdr := msgp.NewReader(&buf) - if err := (&out).DecodeMsg(rdr); err != nil { - t.Errorf("%v", err) - } - if r != out.Rune { - t.Errorf("rune mismatch: expected %c found %c", r, out.Rune) - } - if r != *out.RunePtr { - t.Errorf("rune ptr mismatch: expected %c found %c", r, *out.RunePtr) - } - if r != **out.RunePtrPtr { - t.Errorf("rune ptr ptr mismatch: expected %c found %c", r, **out.RunePtrPtr) - } - if !reflect.DeepEqual(tt.RuneSlice, out.RuneSlice) { - t.Errorf("rune slice mismatch") - } -} - -func TestRuneMarshalUnmarshal(t *testing.T) { - tt := &TestType{} - r := 'r' - rp := &r - tt.Rune = r - tt.RunePtr = &r - tt.RunePtrPtr = &rp - tt.RuneSlice = []rune{'a', 'b', '😳'} - - bts, err := tt.MarshalMsg(nil) - if err != nil { - t.Errorf("%v", err) - } - - var out TestType - if _, err := (&out).UnmarshalMsg(bts); err != nil { - t.Errorf("%v", err) - } - if r != out.Rune { - t.Errorf("rune mismatch: expected %c found %c", r, out.Rune) - } - if r != *out.RunePtr { - t.Errorf("rune ptr mismatch: expected %c found %c", r, *out.RunePtr) - } - if r != **out.RunePtrPtr { - t.Errorf("rune ptr ptr mismatch: expected %c found %c", r, **out.RunePtrPtr) - } - if !reflect.DeepEqual(tt.RuneSlice, out.RuneSlice) { - t.Errorf("rune slice mismatch") - } -} diff --git a/vendor/github.com/tinylib/msgp/_generated/gen_test.go b/vendor/github.com/tinylib/msgp/_generated/gen_test.go deleted file mode 100644 index a89b3be..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/gen_test.go +++ /dev/null @@ -1,150 +0,0 @@ -package _generated - -import ( - "bytes" - "github.com/tinylib/msgp/msgp" - "reflect" - "testing" - "time" -) - -// benchmark encoding a small, "fast" type. -// the point here is to see how much garbage -// is generated intrinsically by the encoding/ -// decoding process as opposed to the nature -// of the struct. -func BenchmarkFastEncode(b *testing.B) { - v := &TestFast{ - Lat: 40.12398, - Long: -41.9082, - Alt: 201.08290, - Data: []byte("whaaaaargharbl"), - } - var buf bytes.Buffer - msgp.Encode(&buf, v) - en := msgp.NewWriter(msgp.Nowhere) - b.SetBytes(int64(buf.Len())) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - v.EncodeMsg(en) - } - en.Flush() -} - -// benchmark decoding a small, "fast" type. -// the point here is to see how much garbage -// is generated intrinsically by the encoding/ -// decoding process as opposed to the nature -// of the struct. -func BenchmarkFastDecode(b *testing.B) { - v := &TestFast{ - Lat: 40.12398, - Long: -41.9082, - Alt: 201.08290, - Data: []byte("whaaaaargharbl"), - } - - var buf bytes.Buffer - msgp.Encode(&buf, v) - dc := msgp.NewReader(msgp.NewEndlessReader(buf.Bytes(), b)) - b.SetBytes(int64(buf.Len())) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - v.DecodeMsg(dc) - } -} - -func (a *TestType) Equal(b *TestType) bool { - // compare times, then zero out those - // fields, perform a DeepEqual, and restore them - ta, tb := a.Time, b.Time - if !ta.Equal(tb) { - return false - } - a.Time, b.Time = time.Time{}, time.Time{} - ok := reflect.DeepEqual(a, b) - a.Time, b.Time = ta, tb - return ok -} - -// This covers the following cases: -// - Recursive types -// - Non-builtin identifiers (and recursive types) -// - time.Time -// - map[string]string -// - anonymous structs -// -func Test1EncodeDecode(t *testing.T) { - f := 32.00 - tt := &TestType{ - F: &f, - Els: map[string]string{ - "thing_one": "one", - "thing_two": "two", - }, - Obj: struct { - ValueA string `msg:"value_a"` - ValueB []byte `msg:"value_b"` - }{ - ValueA: "here's the first inner value", - ValueB: []byte("here's the second inner value"), - }, - Child: nil, - Time: time.Now(), - Appended: msgp.Raw([]byte{0xc0}), // 'nil' - } - - var buf bytes.Buffer - - err := msgp.Encode(&buf, tt) - if err != nil { - t.Fatal(err) - } - - tnew := new(TestType) - - err = msgp.Decode(&buf, tnew) - if err != nil { - t.Error(err) - } - - if !tt.Equal(tnew) { - t.Logf("in: %v", tt) - t.Logf("out: %v", tnew) - t.Fatal("objects not equal") - } - - tanother := new(TestType) - - buf.Reset() - msgp.Encode(&buf, tt) - - var left []byte - left, err = tanother.UnmarshalMsg(buf.Bytes()) - if err != nil { - t.Error(err) - } - if len(left) > 0 { - t.Errorf("%d bytes left", len(left)) - } - - if !tt.Equal(tanother) { - t.Logf("in: %v", tt) - t.Logf("out: %v", tanother) - t.Fatal("objects not equal") - } -} - -func TestIssue168(t *testing.T) { - buf := bytes.Buffer{} - test := TestObj{} - - msgp.Encode(&buf, &TestObj{ID1: "1", ID2: "2"}) - msgp.Decode(&buf, &test) - - if test.ID1 != "1" || test.ID2 != "2" { - t.Fatalf("got back %+v", test) - } -} diff --git a/vendor/github.com/tinylib/msgp/_generated/issue102.go b/vendor/github.com/tinylib/msgp/_generated/issue102.go deleted file mode 100644 index a1cc85c..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/issue102.go +++ /dev/null @@ -1,49 +0,0 @@ -package _generated - -//go:generate msgp - -type Issue102 struct{} - -type Issue102deep struct { - A int - X struct{} - Y struct{} - Z int -} - -//msgp:tuple Issue102Tuple - -type Issue102Tuple struct{} - -//msgp:tuple Issue102TupleDeep - -type Issue102TupleDeep struct { - A int - X struct{} - Y struct{} - Z int -} - -type Issue102Uses struct { - Nested Issue102 - NestedPtr *Issue102 -} - -//msgp:tuple Issue102TupleUsesTuple - -type Issue102TupleUsesTuple struct { - Nested Issue102Tuple - NestedPtr *Issue102Tuple -} - -//msgp:tuple Issue102TupleUsesMap - -type Issue102TupleUsesMap struct { - Nested Issue102 - NestedPtr *Issue102 -} - -type Issue102MapUsesTuple struct { - Nested Issue102Tuple - NestedPtr *Issue102Tuple -} diff --git a/vendor/github.com/tinylib/msgp/_generated/issue191.go b/vendor/github.com/tinylib/msgp/_generated/issue191.go deleted file mode 100644 index 699263c..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/issue191.go +++ /dev/null @@ -1,8 +0,0 @@ -package _generated - -//go:generate msgp - -type Issue191 struct { - Foo string - Bar string -} diff --git a/vendor/github.com/tinylib/msgp/_generated/issue191_test.go b/vendor/github.com/tinylib/msgp/_generated/issue191_test.go deleted file mode 100644 index e6cdf66..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/issue191_test.go +++ /dev/null @@ -1,16 +0,0 @@ -package _generated - -import ( - "testing" -) - -// Issue #191: panic in unsafe.UnsafeString() - -func TestIssue191(t *testing.T) { - b := []byte{0x81, 0xa0, 0xa0} - var i Issue191 - _, err := (&i).UnmarshalMsg(b) - if err != nil { - t.Error(err) - } -} diff --git a/vendor/github.com/tinylib/msgp/_generated/issue94.go b/vendor/github.com/tinylib/msgp/_generated/issue94.go deleted file mode 100644 index 4384d5d..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/issue94.go +++ /dev/null @@ -1,31 +0,0 @@ -package _generated - -import ( - "time" -) - -//go:generate msgp - -// Issue 94: shims were not propogated recursively, -// which caused shims that weren't at the top level -// to be silently ignored. -// -// The following line will generate an error after -// the code is generated if the generated code doesn't -// have the right identifier in it. - -//go:generate ./search.sh $GOFILE timetostr - -//msgp:shim time.Time as:string using:timetostr/strtotime -type T struct { - T time.Time -} - -func timetostr(t time.Time) string { - return t.Format(time.RFC3339) -} - -func strtotime(s string) time.Time { - t, _ := time.Parse(time.RFC3339, s) - return t -} diff --git a/vendor/github.com/tinylib/msgp/_generated/search.sh b/vendor/github.com/tinylib/msgp/_generated/search.sh deleted file mode 100755 index aa6d647..0000000 --- a/vendor/github.com/tinylib/msgp/_generated/search.sh +++ /dev/null @@ -1,12 +0,0 @@ -#! /bin/sh - -FILE=$(echo $1 | sed s/.go/_gen.go/) -echo "searching" $FILE "for" $2 -grep -q $2 $FILE -if [ $? -eq 0 ] -then - echo "OK" -else - echo "whoops!" - exit 1 -fi diff --git a/vendor/github.com/tinylib/msgp/gen/decode.go b/vendor/github.com/tinylib/msgp/gen/decode.go deleted file mode 100644 index 3ba88fa..0000000 --- a/vendor/github.com/tinylib/msgp/gen/decode.go +++ /dev/null @@ -1,222 +0,0 @@ -package gen - -import ( - "io" - "strconv" -) - -func decode(w io.Writer) *decodeGen { - return &decodeGen{ - p: printer{w: w}, - hasfield: false, - } -} - -type decodeGen struct { - passes - p printer - hasfield bool -} - -func (d *decodeGen) Method() Method { return Decode } - -func (d *decodeGen) needsField() { - if d.hasfield { - return - } - d.p.print("\nvar field []byte; _ = field") - d.hasfield = true -} - -func (d *decodeGen) Execute(p Elem) error { - p = d.applyall(p) - if p == nil { - return nil - } - d.hasfield = false - if !d.p.ok() { - return d.p.err - } - - if !IsPrintable(p) { - return nil - } - - d.p.comment("DecodeMsg implements msgp.Decodable") - - d.p.printf("\nfunc (%s %s) DecodeMsg(dc *msgp.Reader) (err error) {", p.Varname(), methodReceiver(p)) - next(d, p) - d.p.nakedReturn() - unsetReceiver(p) - return d.p.err -} - -func (d *decodeGen) gStruct(s *Struct) { - if !d.p.ok() { - return - } - if s.AsTuple { - d.structAsTuple(s) - } else { - d.structAsMap(s) - } - return -} - -func (d *decodeGen) assignAndCheck(name string, typ string) { - if !d.p.ok() { - return - } - d.p.printf("\n%s, err = dc.Read%s()", name, typ) - d.p.print(errcheck) -} - -func (d *decodeGen) structAsTuple(s *Struct) { - nfields := len(s.Fields) - - sz := randIdent() - d.p.declare(sz, u32) - d.assignAndCheck(sz, arrayHeader) - d.p.arrayCheck(strconv.Itoa(nfields), sz) - for i := range s.Fields { - if !d.p.ok() { - return - } - next(d, s.Fields[i].FieldElem) - } -} - -func (d *decodeGen) structAsMap(s *Struct) { - d.needsField() - sz := randIdent() - d.p.declare(sz, u32) - d.assignAndCheck(sz, mapHeader) - - d.p.printf("\nfor %s > 0 {\n%s--", sz, sz) - d.assignAndCheck("field", mapKey) - d.p.print("\nswitch msgp.UnsafeString(field) {") - for i := range s.Fields { - d.p.printf("\ncase \"%s\":", s.Fields[i].FieldTag) - next(d, s.Fields[i].FieldElem) - if !d.p.ok() { - return - } - } - d.p.print("\ndefault:\nerr = dc.Skip()") - d.p.print(errcheck) - d.p.closeblock() // close switch - d.p.closeblock() // close for loop -} - -func (d *decodeGen) gBase(b *BaseElem) { - if !d.p.ok() { - return - } - - // open block for 'tmp' - var tmp string - if b.Convert { - tmp = randIdent() - d.p.printf("\n{ var %s %s", tmp, b.BaseType()) - } - - vname := b.Varname() // e.g. "z.FieldOne" - bname := b.BaseName() // e.g. "Float64" - - // handle special cases - // for object type. - switch b.Value { - case Bytes: - if b.Convert { - d.p.printf("\n%s, err = dc.ReadBytes([]byte(%s))", tmp, vname) - } else { - d.p.printf("\n%s, err = dc.ReadBytes(%s)", vname, vname) - } - case IDENT: - d.p.printf("\nerr = %s.DecodeMsg(dc)", vname) - case Ext: - d.p.printf("\nerr = dc.ReadExtension(%s)", vname) - default: - if b.Convert { - d.p.printf("\n%s, err = dc.Read%s()", tmp, bname) - } else { - d.p.printf("\n%s, err = dc.Read%s()", vname, bname) - } - } - d.p.print(errcheck) - - // close block for 'tmp' - if b.Convert { - if b.ShimMode == Cast { - d.p.printf("\n%s = %s(%s)\n}", vname, b.FromBase(), tmp) - } else { - d.p.printf("\n%s, err = %s(%s)\n}", vname, b.FromBase(), tmp) - d.p.print(errcheck) - } - } -} - -func (d *decodeGen) gMap(m *Map) { - if !d.p.ok() { - return - } - sz := randIdent() - - // resize or allocate map - d.p.declare(sz, u32) - d.assignAndCheck(sz, mapHeader) - d.p.resizeMap(sz, m) - - // for element in map, read string/value - // pair and assign - d.p.printf("\nfor %s > 0 {\n%s--", sz, sz) - d.p.declare(m.Keyidx, "string") - d.p.declare(m.Validx, m.Value.TypeName()) - d.assignAndCheck(m.Keyidx, stringTyp) - next(d, m.Value) - d.p.mapAssign(m) - d.p.closeblock() -} - -func (d *decodeGen) gSlice(s *Slice) { - if !d.p.ok() { - return - } - sz := randIdent() - d.p.declare(sz, u32) - d.assignAndCheck(sz, arrayHeader) - d.p.resizeSlice(sz, s) - d.p.rangeBlock(s.Index, s.Varname(), d, s.Els) -} - -func (d *decodeGen) gArray(a *Array) { - if !d.p.ok() { - return - } - - // special case if we have [const]byte - if be, ok := a.Els.(*BaseElem); ok && (be.Value == Byte || be.Value == Uint8) { - d.p.printf("\nerr = dc.ReadExactBytes((%s)[:])", a.Varname()) - d.p.print(errcheck) - return - } - sz := randIdent() - d.p.declare(sz, u32) - d.assignAndCheck(sz, arrayHeader) - d.p.arrayCheck(coerceArraySize(a.Size), sz) - - d.p.rangeBlock(a.Index, a.Varname(), d, a.Els) -} - -func (d *decodeGen) gPtr(p *Ptr) { - if !d.p.ok() { - return - } - d.p.print("\nif dc.IsNil() {") - d.p.print("\nerr = dc.ReadNil()") - d.p.print(errcheck) - d.p.printf("\n%s = nil\n} else {", p.Varname()) - d.p.initPtr(p) - next(d, p.Value) - d.p.closeblock() -} diff --git a/vendor/github.com/tinylib/msgp/gen/elem.go b/vendor/github.com/tinylib/msgp/gen/elem.go deleted file mode 100644 index 6588355..0000000 --- a/vendor/github.com/tinylib/msgp/gen/elem.go +++ /dev/null @@ -1,619 +0,0 @@ -package gen - -import ( - "fmt" - "strings" -) - -var ( - identNext = 0 - identPrefix = "za" -) - -func resetIdent(prefix string) { - identPrefix = prefix - identNext = 0 -} - -// generate a random identifier name -func randIdent() string { - identNext++ - return fmt.Sprintf("%s%04d", identPrefix, identNext) -} - -// This code defines the type declaration tree. -// -// Consider the following: -// -// type Marshaler struct { -// Thing1 *float64 `msg:"thing1"` -// Body []byte `msg:"body"` -// } -// -// A parser using this generator as a backend -// should parse the above into: -// -// var val Elem = &Ptr{ -// name: "z", -// Value: &Struct{ -// Name: "Marshaler", -// Fields: []StructField{ -// { -// FieldTag: "thing1", -// FieldElem: &Ptr{ -// name: "z.Thing1", -// Value: &BaseElem{ -// name: "*z.Thing1", -// Value: Float64, -// Convert: false, -// }, -// }, -// }, -// { -// FieldTag: "body", -// FieldElem: &BaseElem{ -// name: "z.Body", -// Value: Bytes, -// Convert: false, -// }, -// }, -// }, -// }, -// } - -// Base is one of the -// base types -type Primitive uint8 - -// this is effectively the -// list of currently available -// ReadXxxx / WriteXxxx methods. -const ( - Invalid Primitive = iota - Bytes - String - Float32 - Float64 - Complex64 - Complex128 - Uint - Uint8 - Uint16 - Uint32 - Uint64 - Byte - Int - Int8 - Int16 - Int32 - Int64 - Bool - Intf // interface{} - Time // time.Time - Ext // extension - - IDENT // IDENT means an unrecognized identifier -) - -// all of the recognized identities -// that map to primitive types -var primitives = map[string]Primitive{ - "[]byte": Bytes, - "string": String, - "float32": Float32, - "float64": Float64, - "complex64": Complex64, - "complex128": Complex128, - "uint": Uint, - "uint8": Uint8, - "uint16": Uint16, - "uint32": Uint32, - "uint64": Uint64, - "byte": Byte, - "rune": Int32, - "int": Int, - "int8": Int8, - "int16": Int16, - "int32": Int32, - "int64": Int64, - "bool": Bool, - "interface{}": Intf, - "time.Time": Time, - "msgp.Extension": Ext, -} - -// types built into the library -// that satisfy all of the -// interfaces. -var builtins = map[string]struct{}{ - "msgp.Raw": struct{}{}, - "msgp.Number": struct{}{}, -} - -// common data/methods for every Elem -type common struct{ vname, alias string } - -func (c *common) SetVarname(s string) { c.vname = s } -func (c *common) Varname() string { return c.vname } -func (c *common) Alias(typ string) { c.alias = typ } -func (c *common) hidden() {} - -func IsPrintable(e Elem) bool { - if be, ok := e.(*BaseElem); ok && !be.Printable() { - return false - } - return true -} - -// Elem is a go type capable of being -// serialized into MessagePack. It is -// implemented by *Ptr, *Struct, *Array, -// *Slice, *Map, and *BaseElem. -type Elem interface { - // SetVarname sets this nodes - // variable name and recursively - // sets the names of all its children. - // In general, this should only be - // called on the parent of the tree. - SetVarname(s string) - - // Varname returns the variable - // name of the element. - Varname() string - - // TypeName is the canonical - // go type name of the node - // e.g. "string", "int", "map[string]float64" - // OR the alias name, if it has been set. - TypeName() string - - // Alias sets a type (alias) name - Alias(typ string) - - // Copy should perform a deep copy of the object - Copy() Elem - - // Complexity returns a measure of the - // complexity of element (greater than - // or equal to 1.) - Complexity() int - - hidden() -} - -// Ident returns the *BaseElem that corresponds -// to the provided identity. -func Ident(id string) *BaseElem { - p, ok := primitives[id] - if ok { - return &BaseElem{Value: p} - } - be := &BaseElem{Value: IDENT} - be.Alias(id) - return be -} - -type Array struct { - common - Index string // index variable name - Size string // array size - Els Elem // child -} - -func (a *Array) SetVarname(s string) { - a.common.SetVarname(s) -ridx: - a.Index = randIdent() - - // try to avoid using the same - // index as a parent slice - if strings.Contains(a.Varname(), a.Index) { - goto ridx - } - - a.Els.SetVarname(fmt.Sprintf("%s[%s]", a.Varname(), a.Index)) -} - -func (a *Array) TypeName() string { - if a.common.alias != "" { - return a.common.alias - } - a.common.Alias(fmt.Sprintf("[%s]%s", a.Size, a.Els.TypeName())) - return a.common.alias -} - -func (a *Array) Copy() Elem { - b := *a - b.Els = a.Els.Copy() - return &b -} - -func (a *Array) Complexity() int { return 1 + a.Els.Complexity() } - -// Map is a map[string]Elem -type Map struct { - common - Keyidx string // key variable name - Validx string // value variable name - Value Elem // value element -} - -func (m *Map) SetVarname(s string) { - m.common.SetVarname(s) -ridx: - m.Keyidx = randIdent() - m.Validx = randIdent() - - // just in case - if m.Keyidx == m.Validx { - goto ridx - } - - m.Value.SetVarname(m.Validx) -} - -func (m *Map) TypeName() string { - if m.common.alias != "" { - return m.common.alias - } - m.common.Alias("map[string]" + m.Value.TypeName()) - return m.common.alias -} - -func (m *Map) Copy() Elem { - g := *m - g.Value = m.Value.Copy() - return &g -} - -func (m *Map) Complexity() int { return 2 + m.Value.Complexity() } - -type Slice struct { - common - Index string - Els Elem // The type of each element -} - -func (s *Slice) SetVarname(a string) { - s.common.SetVarname(a) - s.Index = randIdent() - varName := s.Varname() - if varName[0] == '*' { - // Pointer-to-slice requires parenthesis for slicing. - varName = "(" + varName + ")" - } - s.Els.SetVarname(fmt.Sprintf("%s[%s]", varName, s.Index)) -} - -func (s *Slice) TypeName() string { - if s.common.alias != "" { - return s.common.alias - } - s.common.Alias("[]" + s.Els.TypeName()) - return s.common.alias -} - -func (s *Slice) Copy() Elem { - z := *s - z.Els = s.Els.Copy() - return &z -} - -func (s *Slice) Complexity() int { - return 1 + s.Els.Complexity() -} - -type Ptr struct { - common - Value Elem -} - -func (s *Ptr) SetVarname(a string) { - s.common.SetVarname(a) - - // struct fields are dereferenced - // automatically... - switch x := s.Value.(type) { - case *Struct: - // struct fields are automatically dereferenced - x.SetVarname(a) - return - - case *BaseElem: - // identities have pointer receivers - if x.Value == IDENT { - x.SetVarname(a) - } else { - x.SetVarname("*" + a) - } - return - - default: - s.Value.SetVarname("*" + a) - return - } -} - -func (s *Ptr) TypeName() string { - if s.common.alias != "" { - return s.common.alias - } - s.common.Alias("*" + s.Value.TypeName()) - return s.common.alias -} - -func (s *Ptr) Copy() Elem { - v := *s - v.Value = s.Value.Copy() - return &v -} - -func (s *Ptr) Complexity() int { return 1 + s.Value.Complexity() } - -func (s *Ptr) Needsinit() bool { - if be, ok := s.Value.(*BaseElem); ok && be.needsref { - return false - } - return true -} - -type Struct struct { - common - Fields []StructField // field list - AsTuple bool // write as an array instead of a map -} - -func (s *Struct) TypeName() string { - if s.common.alias != "" { - return s.common.alias - } - str := "struct{\n" - for i := range s.Fields { - str += s.Fields[i].FieldName + - " " + s.Fields[i].FieldElem.TypeName() + - " " + s.Fields[i].RawTag + ";\n" - } - str += "}" - s.common.Alias(str) - return s.common.alias -} - -func (s *Struct) SetVarname(a string) { - s.common.SetVarname(a) - writeStructFields(s.Fields, a) -} - -func (s *Struct) Copy() Elem { - g := *s - g.Fields = make([]StructField, len(s.Fields)) - copy(g.Fields, s.Fields) - for i := range s.Fields { - g.Fields[i].FieldElem = s.Fields[i].FieldElem.Copy() - } - return &g -} - -func (s *Struct) Complexity() int { - c := 1 - for i := range s.Fields { - c += s.Fields[i].FieldElem.Complexity() - } - return c -} - -type StructField struct { - FieldTag string // the string inside the `msg:""` tag - RawTag string // the full struct tag - FieldName string // the name of the struct field - FieldElem Elem // the field type -} - -type ShimMode int - -const ( - Cast ShimMode = iota - Convert -) - -// BaseElem is an element that -// can be represented by a primitive -// MessagePack type. -type BaseElem struct { - common - ShimMode ShimMode // Method used to shim - ShimToBase string // shim to base type, or empty - ShimFromBase string // shim from base type, or empty - Value Primitive // Type of element - Convert bool // should we do an explicit conversion? - mustinline bool // must inline; not printable - needsref bool // needs reference for shim -} - -func (s *BaseElem) Printable() bool { return !s.mustinline } - -func (s *BaseElem) Alias(typ string) { - s.common.Alias(typ) - if s.Value != IDENT { - s.Convert = true - } - if strings.Contains(typ, ".") { - s.mustinline = true - } -} - -func (s *BaseElem) SetVarname(a string) { - // extensions whose parents - // are not pointers need to - // be explicitly referenced - if s.Value == Ext || s.needsref { - if strings.HasPrefix(a, "*") { - s.common.SetVarname(a[1:]) - return - } - s.common.SetVarname("&" + a) - return - } - - s.common.SetVarname(a) -} - -// TypeName returns the syntactically correct Go -// type name for the base element. -func (s *BaseElem) TypeName() string { - if s.common.alias != "" { - return s.common.alias - } - s.common.Alias(s.BaseType()) - return s.common.alias -} - -// ToBase, used if Convert==true, is used as tmp = {{ToBase}}({{Varname}}) -func (s *BaseElem) ToBase() string { - if s.ShimToBase != "" { - return s.ShimToBase - } - return s.BaseType() -} - -// FromBase, used if Convert==true, is used as {{Varname}} = {{FromBase}}(tmp) -func (s *BaseElem) FromBase() string { - if s.ShimFromBase != "" { - return s.ShimFromBase - } - return s.TypeName() -} - -// BaseName returns the string form of the -// base type (e.g. Float64, Ident, etc) -func (s *BaseElem) BaseName() string { - // time is a special case; - // we strip the package prefix - if s.Value == Time { - return "Time" - } - return s.Value.String() -} - -func (s *BaseElem) BaseType() string { - switch s.Value { - case IDENT: - return s.TypeName() - - // exceptions to the naming/capitalization - // rule: - case Intf: - return "interface{}" - case Bytes: - return "[]byte" - case Time: - return "time.Time" - case Ext: - return "msgp.Extension" - - // everything else is base.String() with - // the first letter as lowercase - default: - return strings.ToLower(s.BaseName()) - } -} - -func (s *BaseElem) Needsref(b bool) { - s.needsref = b -} - -func (s *BaseElem) Copy() Elem { - g := *s - return &g -} - -func (s *BaseElem) Complexity() int { - if s.Convert && !s.mustinline { - return 2 - } - // we need to return 1 if !printable(), - // in order to make sure that stuff gets - // inlined appropriately - return 1 -} - -// Resolved returns whether or not -// the type of the element is -// a primitive or a builtin provided -// by the package. -func (s *BaseElem) Resolved() bool { - if s.Value == IDENT { - _, ok := builtins[s.TypeName()] - return ok - } - return true -} - -func (k Primitive) String() string { - switch k { - case String: - return "String" - case Bytes: - return "Bytes" - case Float32: - return "Float32" - case Float64: - return "Float64" - case Complex64: - return "Complex64" - case Complex128: - return "Complex128" - case Uint: - return "Uint" - case Uint8: - return "Uint8" - case Uint16: - return "Uint16" - case Uint32: - return "Uint32" - case Uint64: - return "Uint64" - case Byte: - return "Byte" - case Int: - return "Int" - case Int8: - return "Int8" - case Int16: - return "Int16" - case Int32: - return "Int32" - case Int64: - return "Int64" - case Bool: - return "Bool" - case Intf: - return "Intf" - case Time: - return "time.Time" - case Ext: - return "Extension" - case IDENT: - return "Ident" - default: - return "INVALID" - } -} - -// writeStructFields is a trampoline for writeBase for -// all of the fields in a struct -func writeStructFields(s []StructField, name string) { - for i := range s { - s[i].FieldElem.SetVarname(fmt.Sprintf("%s.%s", name, s[i].FieldName)) - } -} - -// coerceArraySize ensures we can compare constant array lengths. -// -// msgpack array headers are 32 bit unsigned, which is reflected in the -// ArrayHeader implementation in this library using uint32. On the Go side, we -// can declare array lengths as any constant integer width, which breaks when -// attempting a direct comparison to an array header's uint32. -// -func coerceArraySize(asz string) string { - return fmt.Sprintf("uint32(%s)", asz) -} diff --git a/vendor/github.com/tinylib/msgp/gen/encode.go b/vendor/github.com/tinylib/msgp/gen/encode.go deleted file mode 100644 index 1ffec61..0000000 --- a/vendor/github.com/tinylib/msgp/gen/encode.go +++ /dev/null @@ -1,198 +0,0 @@ -package gen - -import ( - "fmt" - "io" - - "github.com/tinylib/msgp/msgp" -) - -func encode(w io.Writer) *encodeGen { - return &encodeGen{ - p: printer{w: w}, - } -} - -type encodeGen struct { - passes - p printer - fuse []byte -} - -func (e *encodeGen) Method() Method { return Encode } - -func (e *encodeGen) Apply(dirs []string) error { - return nil -} - -func (e *encodeGen) writeAndCheck(typ string, argfmt string, arg interface{}) { - e.p.printf("\nerr = en.Write%s(%s)", typ, fmt.Sprintf(argfmt, arg)) - e.p.print(errcheck) -} - -func (e *encodeGen) fuseHook() { - if len(e.fuse) > 0 { - e.appendraw(e.fuse) - e.fuse = e.fuse[:0] - } -} - -func (e *encodeGen) Fuse(b []byte) { - if len(e.fuse) > 0 { - e.fuse = append(e.fuse, b...) - } else { - e.fuse = b - } -} - -func (e *encodeGen) Execute(p Elem) error { - if !e.p.ok() { - return e.p.err - } - p = e.applyall(p) - if p == nil { - return nil - } - if !IsPrintable(p) { - return nil - } - - e.p.comment("EncodeMsg implements msgp.Encodable") - - e.p.printf("\nfunc (%s %s) EncodeMsg(en *msgp.Writer) (err error) {", p.Varname(), imutMethodReceiver(p)) - next(e, p) - e.p.nakedReturn() - return e.p.err -} - -func (e *encodeGen) gStruct(s *Struct) { - if !e.p.ok() { - return - } - if s.AsTuple { - e.tuple(s) - } else { - e.structmap(s) - } - return -} - -func (e *encodeGen) tuple(s *Struct) { - nfields := len(s.Fields) - data := msgp.AppendArrayHeader(nil, uint32(nfields)) - e.p.printf("\n// array header, size %d", nfields) - e.Fuse(data) - if len(s.Fields) == 0 { - e.fuseHook() - } - for i := range s.Fields { - if !e.p.ok() { - return - } - next(e, s.Fields[i].FieldElem) - } -} - -func (e *encodeGen) appendraw(bts []byte) { - e.p.print("\nerr = en.Append(") - for i, b := range bts { - if i != 0 { - e.p.print(", ") - } - e.p.printf("0x%x", b) - } - e.p.print(")\nif err != nil { return }") -} - -func (e *encodeGen) structmap(s *Struct) { - nfields := len(s.Fields) - data := msgp.AppendMapHeader(nil, uint32(nfields)) - e.p.printf("\n// map header, size %d", nfields) - e.Fuse(data) - if len(s.Fields) == 0 { - e.fuseHook() - } - for i := range s.Fields { - if !e.p.ok() { - return - } - data = msgp.AppendString(nil, s.Fields[i].FieldTag) - e.p.printf("\n// write %q", s.Fields[i].FieldTag) - e.Fuse(data) - next(e, s.Fields[i].FieldElem) - } -} - -func (e *encodeGen) gMap(m *Map) { - if !e.p.ok() { - return - } - e.fuseHook() - vname := m.Varname() - e.writeAndCheck(mapHeader, lenAsUint32, vname) - - e.p.printf("\nfor %s, %s := range %s {", m.Keyidx, m.Validx, vname) - e.writeAndCheck(stringTyp, literalFmt, m.Keyidx) - next(e, m.Value) - e.p.closeblock() -} - -func (e *encodeGen) gPtr(s *Ptr) { - if !e.p.ok() { - return - } - e.fuseHook() - e.p.printf("\nif %s == nil { err = en.WriteNil(); if err != nil { return; } } else {", s.Varname()) - next(e, s.Value) - e.p.closeblock() -} - -func (e *encodeGen) gSlice(s *Slice) { - if !e.p.ok() { - return - } - e.fuseHook() - e.writeAndCheck(arrayHeader, lenAsUint32, s.Varname()) - e.p.rangeBlock(s.Index, s.Varname(), e, s.Els) -} - -func (e *encodeGen) gArray(a *Array) { - if !e.p.ok() { - return - } - e.fuseHook() - // shortcut for [const]byte - if be, ok := a.Els.(*BaseElem); ok && (be.Value == Byte || be.Value == Uint8) { - e.p.printf("\nerr = en.WriteBytes((%s)[:])", a.Varname()) - e.p.print(errcheck) - return - } - - e.writeAndCheck(arrayHeader, literalFmt, coerceArraySize(a.Size)) - e.p.rangeBlock(a.Index, a.Varname(), e, a.Els) -} - -func (e *encodeGen) gBase(b *BaseElem) { - if !e.p.ok() { - return - } - e.fuseHook() - vname := b.Varname() - if b.Convert { - if b.ShimMode == Cast { - vname = tobaseConvert(b) - } else { - vname = randIdent() - e.p.printf("\nvar %s %s", vname, b.BaseType()) - e.p.printf("\n%s, err = %s", vname, tobaseConvert(b)) - e.p.printf(errcheck) - } - } - - if b.Value == IDENT { // unknown identity - e.p.printf("\nerr = %s.EncodeMsg(en)", vname) - e.p.print(errcheck) - } else { // typical case - e.writeAndCheck(b.BaseName(), literalFmt, vname) - } -} diff --git a/vendor/github.com/tinylib/msgp/gen/marshal.go b/vendor/github.com/tinylib/msgp/gen/marshal.go deleted file mode 100644 index ef3bf99..0000000 --- a/vendor/github.com/tinylib/msgp/gen/marshal.go +++ /dev/null @@ -1,212 +0,0 @@ -package gen - -import ( - "fmt" - "io" - - "github.com/tinylib/msgp/msgp" -) - -func marshal(w io.Writer) *marshalGen { - return &marshalGen{ - p: printer{w: w}, - } -} - -type marshalGen struct { - passes - p printer - fuse []byte -} - -func (m *marshalGen) Method() Method { return Marshal } - -func (m *marshalGen) Apply(dirs []string) error { - return nil -} - -func (m *marshalGen) Execute(p Elem) error { - if !m.p.ok() { - return m.p.err - } - p = m.applyall(p) - if p == nil { - return nil - } - if !IsPrintable(p) { - return nil - } - - m.p.comment("MarshalMsg implements msgp.Marshaler") - - // save the vname before - // calling methodReceiver so - // that z.Msgsize() is printed correctly - c := p.Varname() - - m.p.printf("\nfunc (%s %s) MarshalMsg(b []byte) (o []byte, err error) {", p.Varname(), imutMethodReceiver(p)) - m.p.printf("\no = msgp.Require(b, %s.Msgsize())", c) - next(m, p) - m.p.nakedReturn() - return m.p.err -} - -func (m *marshalGen) rawAppend(typ string, argfmt string, arg interface{}) { - m.p.printf("\no = msgp.Append%s(o, %s)", typ, fmt.Sprintf(argfmt, arg)) -} - -func (m *marshalGen) fuseHook() { - if len(m.fuse) > 0 { - m.rawbytes(m.fuse) - m.fuse = m.fuse[:0] - } -} - -func (m *marshalGen) Fuse(b []byte) { - if len(m.fuse) == 0 { - m.fuse = b - } else { - m.fuse = append(m.fuse, b...) - } -} - -func (m *marshalGen) gStruct(s *Struct) { - if !m.p.ok() { - return - } - - if s.AsTuple { - m.tuple(s) - } else { - m.mapstruct(s) - } - return -} - -func (m *marshalGen) tuple(s *Struct) { - data := make([]byte, 0, 5) - data = msgp.AppendArrayHeader(data, uint32(len(s.Fields))) - m.p.printf("\n// array header, size %d", len(s.Fields)) - m.Fuse(data) - if len(s.Fields) == 0 { - m.fuseHook() - } - for i := range s.Fields { - if !m.p.ok() { - return - } - next(m, s.Fields[i].FieldElem) - } -} - -func (m *marshalGen) mapstruct(s *Struct) { - data := make([]byte, 0, 64) - data = msgp.AppendMapHeader(data, uint32(len(s.Fields))) - m.p.printf("\n// map header, size %d", len(s.Fields)) - m.Fuse(data) - if len(s.Fields) == 0 { - m.fuseHook() - } - for i := range s.Fields { - if !m.p.ok() { - return - } - data = msgp.AppendString(nil, s.Fields[i].FieldTag) - - m.p.printf("\n// string %q", s.Fields[i].FieldTag) - m.Fuse(data) - - next(m, s.Fields[i].FieldElem) - } -} - -// append raw data -func (m *marshalGen) rawbytes(bts []byte) { - m.p.print("\no = append(o, ") - for _, b := range bts { - m.p.printf("0x%x,", b) - } - m.p.print(")") -} - -func (m *marshalGen) gMap(s *Map) { - if !m.p.ok() { - return - } - m.fuseHook() - vname := s.Varname() - m.rawAppend(mapHeader, lenAsUint32, vname) - m.p.printf("\nfor %s, %s := range %s {", s.Keyidx, s.Validx, vname) - m.rawAppend(stringTyp, literalFmt, s.Keyidx) - next(m, s.Value) - m.p.closeblock() -} - -func (m *marshalGen) gSlice(s *Slice) { - if !m.p.ok() { - return - } - m.fuseHook() - vname := s.Varname() - m.rawAppend(arrayHeader, lenAsUint32, vname) - m.p.rangeBlock(s.Index, vname, m, s.Els) -} - -func (m *marshalGen) gArray(a *Array) { - if !m.p.ok() { - return - } - m.fuseHook() - if be, ok := a.Els.(*BaseElem); ok && be.Value == Byte { - m.rawAppend("Bytes", "(%s)[:]", a.Varname()) - return - } - - m.rawAppend(arrayHeader, literalFmt, coerceArraySize(a.Size)) - m.p.rangeBlock(a.Index, a.Varname(), m, a.Els) -} - -func (m *marshalGen) gPtr(p *Ptr) { - if !m.p.ok() { - return - } - m.fuseHook() - m.p.printf("\nif %s == nil {\no = msgp.AppendNil(o)\n} else {", p.Varname()) - next(m, p.Value) - m.p.closeblock() -} - -func (m *marshalGen) gBase(b *BaseElem) { - if !m.p.ok() { - return - } - m.fuseHook() - vname := b.Varname() - - if b.Convert { - if b.ShimMode == Cast { - vname = tobaseConvert(b) - } else { - vname = randIdent() - m.p.printf("\nvar %s %s", vname, b.BaseType()) - m.p.printf("\n%s, err = %s", vname, tobaseConvert(b)) - m.p.printf(errcheck) - } - } - - var echeck bool - switch b.Value { - case IDENT: - echeck = true - m.p.printf("\no, err = %s.MarshalMsg(o)", vname) - case Intf, Ext: - echeck = true - m.p.printf("\no, err = msgp.Append%s(o, %s)", b.BaseName(), vname) - default: - m.rawAppend(b.BaseName(), literalFmt, vname) - } - - if echeck { - m.p.print(errcheck) - } -} diff --git a/vendor/github.com/tinylib/msgp/gen/size.go b/vendor/github.com/tinylib/msgp/gen/size.go deleted file mode 100644 index fd9cc42..0000000 --- a/vendor/github.com/tinylib/msgp/gen/size.go +++ /dev/null @@ -1,286 +0,0 @@ -package gen - -import ( - "fmt" - "io" - "strconv" - - "github.com/tinylib/msgp/msgp" -) - -type sizeState uint8 - -const ( - // need to write "s = ..." - assign sizeState = iota - - // need to write "s += ..." - add - - // can just append "+ ..." - expr -) - -func sizes(w io.Writer) *sizeGen { - return &sizeGen{ - p: printer{w: w}, - state: assign, - } -} - -type sizeGen struct { - passes - p printer - state sizeState -} - -func (s *sizeGen) Method() Method { return Size } - -func (s *sizeGen) Apply(dirs []string) error { - return nil -} - -func builtinSize(typ string) string { - return "msgp." + typ + "Size" -} - -// this lets us chain together addition -// operations where possible -func (s *sizeGen) addConstant(sz string) { - if !s.p.ok() { - return - } - - switch s.state { - case assign: - s.p.print("\ns = " + sz) - s.state = expr - return - case add: - s.p.print("\ns += " + sz) - s.state = expr - return - case expr: - s.p.print(" + " + sz) - return - } - - panic("unknown size state") -} - -func (s *sizeGen) Execute(p Elem) error { - if !s.p.ok() { - return s.p.err - } - p = s.applyall(p) - if p == nil { - return nil - } - if !IsPrintable(p) { - return nil - } - - s.p.comment("Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message") - - s.p.printf("\nfunc (%s %s) Msgsize() (s int) {", p.Varname(), imutMethodReceiver(p)) - s.state = assign - next(s, p) - s.p.nakedReturn() - return s.p.err -} - -func (s *sizeGen) gStruct(st *Struct) { - if !s.p.ok() { - return - } - - nfields := uint32(len(st.Fields)) - - if st.AsTuple { - data := msgp.AppendArrayHeader(nil, nfields) - s.addConstant(strconv.Itoa(len(data))) - for i := range st.Fields { - if !s.p.ok() { - return - } - next(s, st.Fields[i].FieldElem) - } - } else { - data := msgp.AppendMapHeader(nil, nfields) - s.addConstant(strconv.Itoa(len(data))) - for i := range st.Fields { - data = data[:0] - data = msgp.AppendString(data, st.Fields[i].FieldTag) - s.addConstant(strconv.Itoa(len(data))) - next(s, st.Fields[i].FieldElem) - } - } -} - -func (s *sizeGen) gPtr(p *Ptr) { - s.state = add // inner must use add - s.p.printf("\nif %s == nil {\ns += msgp.NilSize\n} else {", p.Varname()) - next(s, p.Value) - s.state = add // closing block; reset to add - s.p.closeblock() -} - -func (s *sizeGen) gSlice(sl *Slice) { - if !s.p.ok() { - return - } - - s.addConstant(builtinSize(arrayHeader)) - - // if the slice's element is a fixed size - // (e.g. float64, [32]int, etc.), then - // print the length times the element size directly - if str, ok := fixedsizeExpr(sl.Els); ok { - s.addConstant(fmt.Sprintf("(%s * (%s))", lenExpr(sl), str)) - return - } - - // add inside the range block, and immediately after - s.state = add - s.p.rangeBlock(sl.Index, sl.Varname(), s, sl.Els) - s.state = add -} - -func (s *sizeGen) gArray(a *Array) { - if !s.p.ok() { - return - } - - s.addConstant(builtinSize(arrayHeader)) - - // if the array's children are a fixed - // size, we can compile an expression - // that always represents the array's wire size - if str, ok := fixedsizeExpr(a); ok { - s.addConstant(str) - return - } - - s.state = add - s.p.rangeBlock(a.Index, a.Varname(), s, a.Els) - s.state = add -} - -func (s *sizeGen) gMap(m *Map) { - s.addConstant(builtinSize(mapHeader)) - vn := m.Varname() - s.p.printf("\nif %s != nil {", vn) - s.p.printf("\nfor %s, %s := range %s {", m.Keyidx, m.Validx, vn) - s.p.printf("\n_ = %s", m.Validx) // we may not use the value - s.p.printf("\ns += msgp.StringPrefixSize + len(%s)", m.Keyidx) - s.state = expr - next(s, m.Value) - s.p.closeblock() - s.p.closeblock() - s.state = add -} - -func (s *sizeGen) gBase(b *BaseElem) { - if !s.p.ok() { - return - } - if b.Convert && b.ShimMode == Convert { - s.state = add - vname := randIdent() - s.p.printf("\nvar %s %s", vname, b.BaseType()) - - // ensure we don't get "unused variable" warnings from outer slice iterations - s.p.printf("\n_ = %s", b.Varname()) - - s.p.printf("\ns += %s", basesizeExpr(b.Value, vname, b.BaseName())) - s.state = expr - - } else { - vname := b.Varname() - if b.Convert { - vname = tobaseConvert(b) - } - s.addConstant(basesizeExpr(b.Value, vname, b.BaseName())) - } -} - -// returns "len(slice)" -func lenExpr(sl *Slice) string { - return "len(" + sl.Varname() + ")" -} - -// is a given primitive always the same (max) -// size on the wire? -func fixedSize(p Primitive) bool { - switch p { - case Intf, Ext, IDENT, Bytes, String: - return false - default: - return true - } -} - -// strip reference from string -func stripRef(s string) string { - if s[0] == '&' { - return s[1:] - } - return s -} - -// return a fixed-size expression, if possible. -// only possible for *BaseElem and *Array. -// returns (expr, ok) -func fixedsizeExpr(e Elem) (string, bool) { - switch e := e.(type) { - case *Array: - if str, ok := fixedsizeExpr(e.Els); ok { - return fmt.Sprintf("(%s * (%s))", e.Size, str), true - } - case *BaseElem: - if fixedSize(e.Value) { - return builtinSize(e.BaseName()), true - } - case *Struct: - var str string - for _, f := range e.Fields { - if fs, ok := fixedsizeExpr(f.FieldElem); ok { - if str == "" { - str = fs - } else { - str += "+" + fs - } - } else { - return "", false - } - } - var hdrlen int - mhdr := msgp.AppendMapHeader(nil, uint32(len(e.Fields))) - hdrlen += len(mhdr) - var strbody []byte - for _, f := range e.Fields { - strbody = msgp.AppendString(strbody[:0], f.FieldTag) - hdrlen += len(strbody) - } - return fmt.Sprintf("%d + %s", hdrlen, str), true - } - return "", false -} - -// print size expression of a variable name -func basesizeExpr(value Primitive, vname, basename string) string { - switch value { - case Ext: - return "msgp.ExtensionPrefixSize + " + stripRef(vname) + ".Len()" - case Intf: - return "msgp.GuessSize(" + vname + ")" - case IDENT: - return vname + ".Msgsize()" - case Bytes: - return "msgp.BytesPrefixSize + len(" + vname + ")" - case String: - return "msgp.StringPrefixSize + len(" + vname + ")" - default: - return builtinSize(basename) - } -} diff --git a/vendor/github.com/tinylib/msgp/gen/spec.go b/vendor/github.com/tinylib/msgp/gen/spec.go deleted file mode 100644 index c4bc8c9..0000000 --- a/vendor/github.com/tinylib/msgp/gen/spec.go +++ /dev/null @@ -1,383 +0,0 @@ -package gen - -import ( - "fmt" - "io" -) - -const ( - errcheck = "\nif err != nil { return }" - lenAsUint32 = "uint32(len(%s))" - literalFmt = "%s" - intFmt = "%d" - quotedFmt = `"%s"` - mapHeader = "MapHeader" - arrayHeader = "ArrayHeader" - mapKey = "MapKeyPtr" - stringTyp = "String" - u32 = "uint32" -) - -// Method is a bitfield representing something that the -// generator knows how to print. -type Method uint8 - -// are the bits in 'f' set in 'm'? -func (m Method) isset(f Method) bool { return (m&f == f) } - -// String implements fmt.Stringer -func (m Method) String() string { - switch m { - case 0, invalidmeth: - return "" - case Decode: - return "decode" - case Encode: - return "encode" - case Marshal: - return "marshal" - case Unmarshal: - return "unmarshal" - case Size: - return "size" - case Test: - return "test" - default: - // return e.g. "decode+encode+test" - modes := [...]Method{Decode, Encode, Marshal, Unmarshal, Size, Test} - any := false - nm := "" - for _, mm := range modes { - if m.isset(mm) { - if any { - nm += "+" + mm.String() - } else { - nm += mm.String() - any = true - } - } - } - return nm - - } -} - -func strtoMeth(s string) Method { - switch s { - case "encode": - return Encode - case "decode": - return Decode - case "marshal": - return Marshal - case "unmarshal": - return Unmarshal - case "size": - return Size - case "test": - return Test - default: - return 0 - } -} - -const ( - Decode Method = 1 << iota // msgp.Decodable - Encode // msgp.Encodable - Marshal // msgp.Marshaler - Unmarshal // msgp.Unmarshaler - Size // msgp.Sizer - Test // generate tests - invalidmeth // this isn't a method - encodetest = Encode | Decode | Test // tests for Encodable and Decodable - marshaltest = Marshal | Unmarshal | Test // tests for Marshaler and Unmarshaler -) - -type Printer struct { - gens []generator -} - -func NewPrinter(m Method, out io.Writer, tests io.Writer) *Printer { - if m.isset(Test) && tests == nil { - panic("cannot print tests with 'nil' tests argument!") - } - gens := make([]generator, 0, 7) - if m.isset(Decode) { - gens = append(gens, decode(out)) - } - if m.isset(Encode) { - gens = append(gens, encode(out)) - } - if m.isset(Marshal) { - gens = append(gens, marshal(out)) - } - if m.isset(Unmarshal) { - gens = append(gens, unmarshal(out)) - } - if m.isset(Size) { - gens = append(gens, sizes(out)) - } - if m.isset(marshaltest) { - gens = append(gens, mtest(tests)) - } - if m.isset(encodetest) { - gens = append(gens, etest(tests)) - } - if len(gens) == 0 { - panic("NewPrinter called with invalid method flags") - } - return &Printer{gens: gens} -} - -// TransformPass is a pass that transforms individual -// elements. (Note that if the returned is different from -// the argument, it should not point to the same objects.) -type TransformPass func(Elem) Elem - -// IgnoreTypename is a pass that just ignores -// types of a given name. -func IgnoreTypename(name string) TransformPass { - return func(e Elem) Elem { - if e.TypeName() == name { - return nil - } - return e - } -} - -// ApplyDirective applies a directive to a named pass -// and all of its dependents. -func (p *Printer) ApplyDirective(pass Method, t TransformPass) { - for _, g := range p.gens { - if g.Method().isset(pass) { - g.Add(t) - } - } -} - -// Print prints an Elem. -func (p *Printer) Print(e Elem) error { - for _, g := range p.gens { - // Elem.SetVarname() is called before the Print() step in parse.FileSet.PrintTo(). - // Elem.SetVarname() generates identifiers as it walks the Elem. This can cause - // collisions between idents created during SetVarname and idents created during Print, - // hence the separate prefixes. - resetIdent("zb") - err := g.Execute(e) - resetIdent("za") - - if err != nil { - return err - } - } - return nil -} - -// generator is the interface through -// which code is generated. -type generator interface { - Method() Method - Add(p TransformPass) - Execute(Elem) error // execute writes the method for the provided object. -} - -type passes []TransformPass - -func (p *passes) Add(t TransformPass) { - *p = append(*p, t) -} - -func (p *passes) applyall(e Elem) Elem { - for _, t := range *p { - e = t(e) - if e == nil { - return nil - } - } - return e -} - -type traversal interface { - gMap(*Map) - gSlice(*Slice) - gArray(*Array) - gPtr(*Ptr) - gBase(*BaseElem) - gStruct(*Struct) -} - -// type-switch dispatch to the correct -// method given the type of 'e' -func next(t traversal, e Elem) { - switch e := e.(type) { - case *Map: - t.gMap(e) - case *Struct: - t.gStruct(e) - case *Slice: - t.gSlice(e) - case *Array: - t.gArray(e) - case *Ptr: - t.gPtr(e) - case *BaseElem: - t.gBase(e) - default: - panic("bad element type") - } -} - -// possibly-immutable method receiver -func imutMethodReceiver(p Elem) string { - switch e := p.(type) { - case *Struct: - // TODO(HACK): actually do real math here. - if len(e.Fields) <= 3 { - for i := range e.Fields { - if be, ok := e.Fields[i].FieldElem.(*BaseElem); !ok || (be.Value == IDENT || be.Value == Bytes) { - goto nope - } - } - return p.TypeName() - } - nope: - return "*" + p.TypeName() - - // gets dereferenced automatically - case *Array: - return "*" + p.TypeName() - - // everything else can be - // by-value. - default: - return p.TypeName() - } -} - -// if necessary, wraps a type -// so that its method receiver -// is of the write type. -func methodReceiver(p Elem) string { - switch p.(type) { - - // structs and arrays are - // dereferenced automatically, - // so no need to alter varname - case *Struct, *Array: - return "*" + p.TypeName() - // set variable name to - // *varname - default: - p.SetVarname("(*" + p.Varname() + ")") - return "*" + p.TypeName() - } -} - -func unsetReceiver(p Elem) { - switch p.(type) { - case *Struct, *Array: - default: - p.SetVarname("z") - } -} - -// shared utility for generators -type printer struct { - w io.Writer - err error -} - -// writes "var {{name}} {{typ}};" -func (p *printer) declare(name string, typ string) { - p.printf("\nvar %s %s", name, typ) -} - -// does: -// -// if m != nil && size > 0 { -// m = make(type, size) -// } else if len(m) > 0 { -// for key, _ := range m { delete(m, key) } -// } -// -func (p *printer) resizeMap(size string, m *Map) { - vn := m.Varname() - if !p.ok() { - return - } - p.printf("\nif %s == nil && %s > 0 {", vn, size) - p.printf("\n%s = make(%s, %s)", vn, m.TypeName(), size) - p.printf("\n} else if len(%s) > 0 {", vn) - p.clearMap(vn) - p.closeblock() -} - -// assign key to value based on varnames -func (p *printer) mapAssign(m *Map) { - if !p.ok() { - return - } - p.printf("\n%s[%s] = %s", m.Varname(), m.Keyidx, m.Validx) -} - -// clear map keys -func (p *printer) clearMap(name string) { - p.printf("\nfor key, _ := range %[1]s { delete(%[1]s, key) }", name) -} - -func (p *printer) resizeSlice(size string, s *Slice) { - p.printf("\nif cap(%[1]s) >= int(%[2]s) { %[1]s = (%[1]s)[:%[2]s] } else { %[1]s = make(%[3]s, %[2]s) }", s.Varname(), size, s.TypeName()) -} - -func (p *printer) arrayCheck(want string, got string) { - p.printf("\nif %[1]s != %[2]s { err = msgp.ArrayError{Wanted: %[2]s, Got: %[1]s}; return }", got, want) -} - -func (p *printer) closeblock() { p.print("\n}") } - -// does: -// -// for idx := range iter { -// {{generate inner}} -// } -// -func (p *printer) rangeBlock(idx string, iter string, t traversal, inner Elem) { - p.printf("\n for %s := range %s {", idx, iter) - next(t, inner) - p.closeblock() -} - -func (p *printer) nakedReturn() { - if p.ok() { - p.print("\nreturn\n}\n") - } -} - -func (p *printer) comment(s string) { - p.print("\n// " + s) -} - -func (p *printer) printf(format string, args ...interface{}) { - if p.err == nil { - _, p.err = fmt.Fprintf(p.w, format, args...) - } -} - -func (p *printer) print(format string) { - if p.err == nil { - _, p.err = io.WriteString(p.w, format) - } -} - -func (p *printer) initPtr(pt *Ptr) { - if pt.Needsinit() { - vname := pt.Varname() - p.printf("\nif %s == nil { %s = new(%s); }", vname, vname, pt.Value.TypeName()) - } -} - -func (p *printer) ok() bool { return p.err == nil } - -func tobaseConvert(b *BaseElem) string { - return b.ToBase() + "(" + b.Varname() + ")" -} diff --git a/vendor/github.com/tinylib/msgp/gen/testgen.go b/vendor/github.com/tinylib/msgp/gen/testgen.go deleted file mode 100644 index a0e0114..0000000 --- a/vendor/github.com/tinylib/msgp/gen/testgen.go +++ /dev/null @@ -1,182 +0,0 @@ -package gen - -import ( - "io" - "text/template" -) - -var ( - marshalTestTempl = template.New("MarshalTest") - encodeTestTempl = template.New("EncodeTest") -) - -// TODO(philhofer): -// for simplicity's sake, right now -// we can only generate tests for types -// that can be initialized with the -// "Type{}" syntax. -// we should support all the types. - -func mtest(w io.Writer) *mtestGen { - return &mtestGen{w: w} -} - -type mtestGen struct { - passes - w io.Writer -} - -func (m *mtestGen) Execute(p Elem) error { - p = m.applyall(p) - if p != nil && IsPrintable(p) { - switch p.(type) { - case *Struct, *Array, *Slice, *Map: - return marshalTestTempl.Execute(m.w, p) - } - } - return nil -} - -func (m *mtestGen) Method() Method { return marshaltest } - -type etestGen struct { - passes - w io.Writer -} - -func etest(w io.Writer) *etestGen { - return &etestGen{w: w} -} - -func (e *etestGen) Execute(p Elem) error { - p = e.applyall(p) - if p != nil && IsPrintable(p) { - switch p.(type) { - case *Struct, *Array, *Slice, *Map: - return encodeTestTempl.Execute(e.w, p) - } - } - return nil -} - -func (e *etestGen) Method() Method { return encodetest } - -func init() { - template.Must(marshalTestTempl.Parse(`func TestMarshalUnmarshal{{.TypeName}}(t *testing.T) { - v := {{.TypeName}}{} - bts, err := v.MarshalMsg(nil) - if err != nil { - t.Fatal(err) - } - left, err := v.UnmarshalMsg(bts) - if err != nil { - t.Fatal(err) - } - if len(left) > 0 { - t.Errorf("%d bytes left over after UnmarshalMsg(): %q", len(left), left) - } - - left, err = msgp.Skip(bts) - if err != nil { - t.Fatal(err) - } - if len(left) > 0 { - t.Errorf("%d bytes left over after Skip(): %q", len(left), left) - } -} - -func BenchmarkMarshalMsg{{.TypeName}}(b *testing.B) { - v := {{.TypeName}}{} - b.ReportAllocs() - b.ResetTimer() - for i:=0; i m { - t.Logf("WARNING: Msgsize() for %v is inaccurate", v) - } - - vn := {{.TypeName}}{} - err := msgp.Decode(&buf, &vn) - if err != nil { - t.Error(err) - } - - buf.Reset() - msgp.Encode(&buf, &v) - err = msgp.NewReader(&buf).Skip() - if err != nil { - t.Error(err) - } -} - -func BenchmarkEncode{{.TypeName}}(b *testing.B) { - v := {{.TypeName}}{} - var buf bytes.Buffer - msgp.Encode(&buf, &v) - b.SetBytes(int64(buf.Len())) - en := msgp.NewWriter(msgp.Nowhere) - b.ReportAllocs() - b.ResetTimer() - for i:=0; i 0 {", sz) - u.p.printf("\n%s--; field, bts, err = msgp.ReadMapKeyZC(bts)", sz) - u.p.print(errcheck) - u.p.print("\nswitch msgp.UnsafeString(field) {") - for i := range s.Fields { - if !u.p.ok() { - return - } - u.p.printf("\ncase \"%s\":", s.Fields[i].FieldTag) - next(u, s.Fields[i].FieldElem) - } - u.p.print("\ndefault:\nbts, err = msgp.Skip(bts)") - u.p.print(errcheck) - u.p.print("\n}\n}") // close switch and for loop -} - -func (u *unmarshalGen) gBase(b *BaseElem) { - if !u.p.ok() { - return - } - - refname := b.Varname() // assigned to - lowered := b.Varname() // passed as argument - if b.Convert { - // begin 'tmp' block - refname = randIdent() - lowered = b.ToBase() + "(" + lowered + ")" - u.p.printf("\n{\nvar %s %s", refname, b.BaseType()) - } - - switch b.Value { - case Bytes: - u.p.printf("\n%s, bts, err = msgp.ReadBytesBytes(bts, %s)", refname, lowered) - case Ext: - u.p.printf("\nbts, err = msgp.ReadExtensionBytes(bts, %s)", lowered) - case IDENT: - u.p.printf("\nbts, err = %s.UnmarshalMsg(bts)", lowered) - default: - u.p.printf("\n%s, bts, err = msgp.Read%sBytes(bts)", refname, b.BaseName()) - } - u.p.print(errcheck) - - if b.Convert { - // close 'tmp' block - if b.ShimMode == Cast { - u.p.printf("\n%s = %s(%s)\n", b.Varname(), b.FromBase(), refname) - } else { - u.p.printf("\n%s, err = %s(%s)", b.Varname(), b.FromBase(), refname) - u.p.print(errcheck) - } - u.p.printf("}") - } -} - -func (u *unmarshalGen) gArray(a *Array) { - if !u.p.ok() { - return - } - - // special case for [const]byte objects - // see decode.go for symmetry - if be, ok := a.Els.(*BaseElem); ok && be.Value == Byte { - u.p.printf("\nbts, err = msgp.ReadExactBytes(bts, (%s)[:])", a.Varname()) - u.p.print(errcheck) - return - } - - sz := randIdent() - u.p.declare(sz, u32) - u.assignAndCheck(sz, arrayHeader) - u.p.arrayCheck(coerceArraySize(a.Size), sz) - u.p.rangeBlock(a.Index, a.Varname(), u, a.Els) -} - -func (u *unmarshalGen) gSlice(s *Slice) { - if !u.p.ok() { - return - } - sz := randIdent() - u.p.declare(sz, u32) - u.assignAndCheck(sz, arrayHeader) - u.p.resizeSlice(sz, s) - u.p.rangeBlock(s.Index, s.Varname(), u, s.Els) -} - -func (u *unmarshalGen) gMap(m *Map) { - if !u.p.ok() { - return - } - sz := randIdent() - u.p.declare(sz, u32) - u.assignAndCheck(sz, mapHeader) - - // allocate or clear map - u.p.resizeMap(sz, m) - - // loop and get key,value - u.p.printf("\nfor %s > 0 {", sz) - u.p.printf("\nvar %s string; var %s %s; %s--", m.Keyidx, m.Validx, m.Value.TypeName(), sz) - u.assignAndCheck(m.Keyidx, stringTyp) - next(u, m.Value) - u.p.mapAssign(m) - u.p.closeblock() -} - -func (u *unmarshalGen) gPtr(p *Ptr) { - u.p.printf("\nif msgp.IsNil(bts) { bts, err = msgp.ReadNilBytes(bts); if err != nil { return }; %s = nil; } else { ", p.Varname()) - u.p.initPtr(p) - next(u, p.Value) - u.p.closeblock() -} diff --git a/vendor/github.com/tinylib/msgp/issue185_test.go b/vendor/github.com/tinylib/msgp/issue185_test.go deleted file mode 100644 index b866108..0000000 --- a/vendor/github.com/tinylib/msgp/issue185_test.go +++ /dev/null @@ -1,308 +0,0 @@ -package main - -import ( - "fmt" - "go/ast" - "go/parser" - "go/token" - "io/ioutil" - "os" - "path/filepath" - "reflect" - "sort" - "testing" - "text/template" - - "github.com/tinylib/msgp/gen" -) - -// When stuff's going wrong, you'll be glad this is here! -const debugTemp = false - -// Ensure that consistent identifiers are generated on a per-method basis by msgp. -// -// Also ensure that no duplicate identifiers appear in a method. -// -// structs are currently processed alphabetically by msgp. this test relies on -// that property. -// -func TestIssue185Idents(t *testing.T) { - var identCases = []struct { - tpl *template.Template - expectedChanged []string - }{ - {tpl: issue185IdentsTpl, expectedChanged: []string{"Test1"}}, - {tpl: issue185ComplexIdentsTpl, expectedChanged: []string{"Test2"}}, - } - - methods := []string{"DecodeMsg", "EncodeMsg", "Msgsize", "MarshalMsg", "UnmarshalMsg"} - - for idx, identCase := range identCases { - // generate the code, extract the generated variable names, mapped to function name - var tplData issue185TplData - varsBefore, err := loadVars(identCase.tpl, tplData) - if err != nil { - t.Fatalf("%d: could not extract before vars: %v", idx, err) - } - - // regenerate the code with extra field(s), extract the generated variable - // names, mapped to function name - tplData.Extra = true - varsAfter, err := loadVars(identCase.tpl, tplData) - if err != nil { - t.Fatalf("%d: could not extract after vars: %v", idx, err) - } - - // ensure that all declared variable names inside each of the methods we - // expect to change have actually changed - for _, stct := range identCase.expectedChanged { - for _, method := range methods { - fn := fmt.Sprintf("%s.%s", stct, method) - - bv, av := varsBefore.Value(fn), varsAfter.Value(fn) - if len(bv) > 0 && len(av) > 0 && reflect.DeepEqual(bv, av) { - t.Fatalf("%d vars identical! expected vars to change for %s", idx, fn) - } - delete(varsBefore, fn) - delete(varsAfter, fn) - } - } - - // all of the remaining keys should not have changed - for bmethod, bvars := range varsBefore { - avars := varsAfter.Value(bmethod) - - if !reflect.DeepEqual(bvars, avars) { - t.Fatalf("%d: vars changed! expected vars identical for %s", idx, bmethod) - } - delete(varsBefore, bmethod) - delete(varsAfter, bmethod) - } - - if len(varsBefore) > 0 || len(varsAfter) > 0 { - t.Fatalf("%d: unexpected methods remaining", idx) - } - } -} - -type issue185TplData struct { - Extra bool -} - -func TestIssue185Overlap(t *testing.T) { - var overlapCases = []struct { - tpl *template.Template - data issue185TplData - }{ - {tpl: issue185IdentsTpl, data: issue185TplData{Extra: false}}, - {tpl: issue185IdentsTpl, data: issue185TplData{Extra: true}}, - {tpl: issue185ComplexIdentsTpl, data: issue185TplData{Extra: false}}, - {tpl: issue185ComplexIdentsTpl, data: issue185TplData{Extra: true}}, - } - - for idx, o := range overlapCases { - // regenerate the code with extra field(s), extract the generated variable - // names, mapped to function name - mvars, err := loadVars(o.tpl, o.data) - if err != nil { - t.Fatalf("%d: could not extract after vars: %v", idx, err) - } - - identCnt := 0 - for fn, vars := range mvars { - sort.Strings(vars) - - // Loose sanity check to make sure the tests expectations aren't broken. - // If the prefix ever changes, this needs to change. - for _, v := range vars { - if v[0] == 'z' { - identCnt++ - } - } - - for i := 0; i < len(vars)-1; i++ { - if vars[i] == vars[i+1] { - t.Fatalf("%d: duplicate var %s in function %s", idx, vars[i], fn) - } - } - } - - // one last sanity check: if there aren't any vars that start with 'z', - // this test's expectations are unsatisfiable. - if identCnt == 0 { - t.Fatalf("%d: no generated identifiers found", idx) - } - } -} - -func loadVars(tpl *template.Template, tplData interface{}) (vars extractedVars, err error) { - tempDir, err := ioutil.TempDir("", "msgp-") - if err != nil { - err = fmt.Errorf("could not create temp dir: %v", err) - return - } - - if !debugTemp { - defer os.RemoveAll(tempDir) - } else { - fmt.Println(tempDir) - } - tfile := filepath.Join(tempDir, "msg.go") - genFile := newFilename(tfile, "") - - if err = goGenerateTpl(tempDir, tfile, tpl, tplData); err != nil { - err = fmt.Errorf("could not generate code: %v", err) - return - } - - vars, err = extractVars(genFile) - if err != nil { - err = fmt.Errorf("could not extract after vars: %v", err) - return - } - - return -} - -type varVisitor struct { - vars []string - fset *token.FileSet -} - -func (v *varVisitor) Visit(node ast.Node) (w ast.Visitor) { - gen, ok := node.(*ast.GenDecl) - if !ok { - return v - } - for _, spec := range gen.Specs { - if vspec, ok := spec.(*ast.ValueSpec); ok { - for _, n := range vspec.Names { - v.vars = append(v.vars, n.Name) - } - } - } - return v -} - -type extractedVars map[string][]string - -func (e extractedVars) Value(key string) []string { - if v, ok := e[key]; ok { - return v - } - panic(fmt.Errorf("unknown key %s", key)) -} - -func extractVars(file string) (extractedVars, error) { - fset := token.NewFileSet() - - f, err := parser.ParseFile(fset, file, nil, 0) - if err != nil { - return nil, err - } - - vars := make(map[string][]string) - for _, d := range f.Decls { - switch d := d.(type) { - case *ast.FuncDecl: - sn := "" - switch rt := d.Recv.List[0].Type.(type) { - case *ast.Ident: - sn = rt.Name - case *ast.StarExpr: - sn = rt.X.(*ast.Ident).Name - default: - panic("unknown receiver type") - } - - key := fmt.Sprintf("%s.%s", sn, d.Name.Name) - vis := &varVisitor{fset: fset} - ast.Walk(vis, d.Body) - vars[key] = vis.vars - } - } - return vars, nil -} - -func goGenerateTpl(cwd, tfile string, tpl *template.Template, tplData interface{}) error { - outf, err := os.OpenFile(tfile, os.O_CREATE|os.O_RDWR|os.O_TRUNC, 0600) - if err != nil { - return err - } - defer outf.Close() - - if err := tpl.Execute(outf, tplData); err != nil { - return err - } - - mode := gen.Encode | gen.Decode | gen.Size | gen.Marshal | gen.Unmarshal - - return Run(tfile, mode, false) -} - -var issue185IdentsTpl = template.Must(template.New("").Parse(` -package issue185 - -//go:generate msgp - -type Test1 struct { - Foo string - Bar string - {{ if .Extra }}Baz []string{{ end }} - Qux string -} - -type Test2 struct { - Foo string - Bar string - Baz string -} -`)) - -var issue185ComplexIdentsTpl = template.Must(template.New("").Parse(` -package issue185 - -//go:generate msgp - -type Test1 struct { - Foo string - Bar string - Baz string -} - -type Test2 struct { - Foo string - Bar string - Baz []string - Qux map[string]string - Yep map[string]map[string]string - Quack struct { - Quack struct { - Quack struct { - {{ if .Extra }}Extra []string{{ end }} - Quack string - } - } - } - Nup struct { - Foo string - Bar string - Baz []string - Qux map[string]string - Yep map[string]map[string]string - } - Ding struct { - Dong struct { - Dung struct { - Thing string - } - } - } -} - -type Test3 struct { - Foo string - Bar string - Baz string -} -`)) diff --git a/vendor/github.com/tinylib/msgp/main.go b/vendor/github.com/tinylib/msgp/main.go deleted file mode 100644 index 4369d73..0000000 --- a/vendor/github.com/tinylib/msgp/main.go +++ /dev/null @@ -1,119 +0,0 @@ -// msgp is a code generation tool for -// creating methods to serialize and de-serialize -// Go data structures to and from MessagePack. -// -// This package is targeted at the `go generate` tool. -// To use it, include the following directive in a -// go source file with types requiring source generation: -// -// //go:generate msgp -// -// The go generate tool should set the proper environment variables for -// the generator to execute without any command-line flags. However, the -// following options are supported, if you need them: -// -// -o = output file name (default is {input}_gen.go) -// -file = input file name (or directory; default is $GOFILE, which is set by the `go generate` command) -// -io = satisfy the `msgp.Decodable` and `msgp.Encodable` interfaces (default is true) -// -marshal = satisfy the `msgp.Marshaler` and `msgp.Unmarshaler` interfaces (default is true) -// -tests = generate tests and benchmarks (default is true) -// -// For more information, please read README.md, and the wiki at github.com/tinylib/msgp -// -package main - -import ( - "flag" - "fmt" - "os" - "path/filepath" - "strings" - - "github.com/tinylib/msgp/gen" - "github.com/tinylib/msgp/parse" - "github.com/tinylib/msgp/printer" - "github.com/ttacon/chalk" -) - -var ( - out = flag.String("o", "", "output file") - file = flag.String("file", "", "input file") - encode = flag.Bool("io", true, "create Encode and Decode methods") - marshal = flag.Bool("marshal", true, "create Marshal and Unmarshal methods") - tests = flag.Bool("tests", true, "create tests and benchmarks") - unexported = flag.Bool("unexported", false, "also process unexported types") -) - -func main() { - flag.Parse() - - // GOFILE is set by go generate - if *file == "" { - *file = os.Getenv("GOFILE") - if *file == "" { - fmt.Println(chalk.Red.Color("No file to parse.")) - os.Exit(1) - } - } - - var mode gen.Method - if *encode { - mode |= (gen.Encode | gen.Decode | gen.Size) - } - if *marshal { - mode |= (gen.Marshal | gen.Unmarshal | gen.Size) - } - if *tests { - mode |= gen.Test - } - - if mode&^gen.Test == 0 { - fmt.Println(chalk.Red.Color("No methods to generate; -io=false && -marshal=false")) - os.Exit(1) - } - - if err := Run(*file, mode, *unexported); err != nil { - fmt.Println(chalk.Red.Color(err.Error())) - os.Exit(1) - } -} - -// Run writes all methods using the associated file or path, e.g. -// -// err := msgp.Run("path/to/myfile.go", gen.Size|gen.Marshal|gen.Unmarshal|gen.Test, false) -// -func Run(gofile string, mode gen.Method, unexported bool) error { - if mode&^gen.Test == 0 { - return nil - } - fmt.Println(chalk.Magenta.Color("======== MessagePack Code Generator =======")) - fmt.Printf(chalk.Magenta.Color(">>> Input: \"%s\"\n"), gofile) - fs, err := parse.File(gofile, unexported) - if err != nil { - return err - } - - if len(fs.Identities) == 0 { - fmt.Println(chalk.Magenta.Color("No types requiring code generation were found!")) - return nil - } - - return printer.PrintFile(newFilename(gofile, fs.Package), fs, mode) -} - -// picks a new file name based on input flags and input filename(s). -func newFilename(old string, pkg string) string { - if *out != "" { - if pre := strings.TrimPrefix(*out, old); len(pre) > 0 && - !strings.HasSuffix(*out, ".go") { - return filepath.Join(old, *out) - } - return *out - } - - if fi, err := os.Stat(old); err == nil && fi.IsDir() { - old = filepath.Join(old, pkg) - } - // new file name is old file name + _gen.go - return strings.TrimSuffix(old, ".go") + "_gen.go" -} diff --git a/vendor/github.com/tinylib/msgp/msgp/advise_linux.go b/vendor/github.com/tinylib/msgp/msgp/advise_linux.go deleted file mode 100644 index 6c6bb37..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/advise_linux.go +++ /dev/null @@ -1,24 +0,0 @@ -// +build linux,!appengine - -package msgp - -import ( - "os" - "syscall" -) - -func adviseRead(mem []byte) { - syscall.Madvise(mem, syscall.MADV_SEQUENTIAL|syscall.MADV_WILLNEED) -} - -func adviseWrite(mem []byte) { - syscall.Madvise(mem, syscall.MADV_SEQUENTIAL) -} - -func fallocate(f *os.File, sz int64) error { - err := syscall.Fallocate(int(f.Fd()), 0, 0, sz) - if err == syscall.ENOTSUP { - return f.Truncate(sz) - } - return err -} diff --git a/vendor/github.com/tinylib/msgp/msgp/advise_other.go b/vendor/github.com/tinylib/msgp/msgp/advise_other.go deleted file mode 100644 index da65ea5..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/advise_other.go +++ /dev/null @@ -1,17 +0,0 @@ -// +build !linux appengine - -package msgp - -import ( - "os" -) - -// TODO: darwin, BSD support - -func adviseRead(mem []byte) {} - -func adviseWrite(mem []byte) {} - -func fallocate(f *os.File, sz int64) error { - return f.Truncate(sz) -} diff --git a/vendor/github.com/tinylib/msgp/msgp/appengine.go b/vendor/github.com/tinylib/msgp/msgp/appengine.go deleted file mode 100644 index bff9e76..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/appengine.go +++ /dev/null @@ -1,15 +0,0 @@ -// +build appengine - -package msgp - -// let's just assume appengine -// uses 64-bit hardware... -const smallint = false - -func UnsafeString(b []byte) string { - return string(b) -} - -func UnsafeBytes(s string) []byte { - return []byte(s) -} diff --git a/vendor/github.com/tinylib/msgp/msgp/circular.go b/vendor/github.com/tinylib/msgp/msgp/circular.go deleted file mode 100644 index a0434c7..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/circular.go +++ /dev/null @@ -1,39 +0,0 @@ -package msgp - -type timer interface { - StartTimer() - StopTimer() -} - -// EndlessReader is an io.Reader -// that loops over the same data -// endlessly. It is used for benchmarking. -type EndlessReader struct { - tb timer - data []byte - offset int -} - -// NewEndlessReader returns a new endless reader -func NewEndlessReader(b []byte, tb timer) *EndlessReader { - return &EndlessReader{tb: tb, data: b, offset: 0} -} - -// Read implements io.Reader. In practice, it -// always returns (len(p), nil), although it -// fills the supplied slice while the benchmark -// timer is stopped. -func (c *EndlessReader) Read(p []byte) (int, error) { - c.tb.StopTimer() - var n int - l := len(p) - m := len(c.data) - for n < l { - nn := copy(p[n:], c.data[c.offset:]) - n += nn - c.offset += nn - c.offset %= m - } - c.tb.StartTimer() - return n, nil -} diff --git a/vendor/github.com/tinylib/msgp/msgp/defs.go b/vendor/github.com/tinylib/msgp/msgp/defs.go deleted file mode 100644 index c634eef..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/defs.go +++ /dev/null @@ -1,142 +0,0 @@ -// This package is the support library for the msgp code generator (http://github.com/tinylib/msgp). -// -// This package defines the utilites used by the msgp code generator for encoding and decoding MessagePack -// from []byte and io.Reader/io.Writer types. Much of this package is devoted to helping the msgp code -// generator implement the Marshaler/Unmarshaler and Encodable/Decodable interfaces. -// -// This package defines four "families" of functions: -// - AppendXxxx() appends an object to a []byte in MessagePack encoding. -// - ReadXxxxBytes() reads an object from a []byte and returns the remaining bytes. -// - (*Writer).WriteXxxx() writes an object to the buffered *Writer type. -// - (*Reader).ReadXxxx() reads an object from a buffered *Reader type. -// -// Once a type has satisfied the `Encodable` and `Decodable` interfaces, -// it can be written and read from arbitrary `io.Writer`s and `io.Reader`s using -// msgp.Encode(io.Writer, msgp.Encodable) -// and -// msgp.Decode(io.Reader, msgp.Decodable) -// -// There are also methods for converting MessagePack to JSON without -// an explicit de-serialization step. -// -// For additional tips, tricks, and gotchas, please visit -// the wiki at http://github.com/tinylib/msgp -package msgp - -const last4 = 0x0f -const first4 = 0xf0 -const last5 = 0x1f -const first3 = 0xe0 -const last7 = 0x7f - -func isfixint(b byte) bool { - return b>>7 == 0 -} - -func isnfixint(b byte) bool { - return b&first3 == mnfixint -} - -func isfixmap(b byte) bool { - return b&first4 == mfixmap -} - -func isfixarray(b byte) bool { - return b&first4 == mfixarray -} - -func isfixstr(b byte) bool { - return b&first3 == mfixstr -} - -func wfixint(u uint8) byte { - return u & last7 -} - -func rfixint(b byte) uint8 { - return b -} - -func wnfixint(i int8) byte { - return byte(i) | mnfixint -} - -func rnfixint(b byte) int8 { - return int8(b) -} - -func rfixmap(b byte) uint8 { - return b & last4 -} - -func wfixmap(u uint8) byte { - return mfixmap | (u & last4) -} - -func rfixstr(b byte) uint8 { - return b & last5 -} - -func wfixstr(u uint8) byte { - return (u & last5) | mfixstr -} - -func rfixarray(b byte) uint8 { - return (b & last4) -} - -func wfixarray(u uint8) byte { - return (u & last4) | mfixarray -} - -// These are all the byte -// prefixes defined by the -// msgpack standard -const ( - // 0XXXXXXX - mfixint uint8 = 0x00 - - // 111XXXXX - mnfixint uint8 = 0xe0 - - // 1000XXXX - mfixmap uint8 = 0x80 - - // 1001XXXX - mfixarray uint8 = 0x90 - - // 101XXXXX - mfixstr uint8 = 0xa0 - - mnil uint8 = 0xc0 - mfalse uint8 = 0xc2 - mtrue uint8 = 0xc3 - mbin8 uint8 = 0xc4 - mbin16 uint8 = 0xc5 - mbin32 uint8 = 0xc6 - mext8 uint8 = 0xc7 - mext16 uint8 = 0xc8 - mext32 uint8 = 0xc9 - mfloat32 uint8 = 0xca - mfloat64 uint8 = 0xcb - muint8 uint8 = 0xcc - muint16 uint8 = 0xcd - muint32 uint8 = 0xce - muint64 uint8 = 0xcf - mint8 uint8 = 0xd0 - mint16 uint8 = 0xd1 - mint32 uint8 = 0xd2 - mint64 uint8 = 0xd3 - mfixext1 uint8 = 0xd4 - mfixext2 uint8 = 0xd5 - mfixext4 uint8 = 0xd6 - mfixext8 uint8 = 0xd7 - mfixext16 uint8 = 0xd8 - mstr8 uint8 = 0xd9 - mstr16 uint8 = 0xda - mstr32 uint8 = 0xdb - marray16 uint8 = 0xdc - marray32 uint8 = 0xdd - mmap16 uint8 = 0xde - mmap32 uint8 = 0xdf -) diff --git a/vendor/github.com/tinylib/msgp/msgp/defs_test.go b/vendor/github.com/tinylib/msgp/msgp/defs_test.go deleted file mode 100644 index 667dfd6..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/defs_test.go +++ /dev/null @@ -1,12 +0,0 @@ -package msgp_test - -//go:generate msgp -o=defgen_test.go -tests=false - -type Blobs []Blob - -type Blob struct { - Name string `msg:"name"` - Float float64 `msg:"float"` - Bytes []byte `msg:"bytes"` - Amount int64 `msg:"amount"` -} diff --git a/vendor/github.com/tinylib/msgp/msgp/edit.go b/vendor/github.com/tinylib/msgp/msgp/edit.go deleted file mode 100644 index 41f9298..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/edit.go +++ /dev/null @@ -1,241 +0,0 @@ -package msgp - -import ( - "math" -) - -// Locate returns a []byte pointing to the field -// in a messagepack map with the provided key. (The returned []byte -// points to a sub-slice of 'raw'; Locate does no allocations.) If the -// key doesn't exist in the map, a zero-length []byte will be returned. -func Locate(key string, raw []byte) []byte { - s, n := locate(raw, key) - return raw[s:n] -} - -// Replace takes a key ("key") in a messagepack map ("raw") -// and replaces its value with the one provided and returns -// the new []byte. The returned []byte may point to the same -// memory as "raw". Replace makes no effort to evaluate the validity -// of the contents of 'val'. It may use up to the full capacity of 'raw.' -// Replace returns 'nil' if the field doesn't exist or if the object in 'raw' -// is not a map. -func Replace(key string, raw []byte, val []byte) []byte { - start, end := locate(raw, key) - if start == end { - return nil - } - return replace(raw, start, end, val, true) -} - -// CopyReplace works similarly to Replace except that the returned -// byte slice does not point to the same memory as 'raw'. CopyReplace -// returns 'nil' if the field doesn't exist or 'raw' isn't a map. -func CopyReplace(key string, raw []byte, val []byte) []byte { - start, end := locate(raw, key) - if start == end { - return nil - } - return replace(raw, start, end, val, false) -} - -// Remove removes a key-value pair from 'raw'. It returns -// 'raw' unchanged if the key didn't exist. -func Remove(key string, raw []byte) []byte { - start, end := locateKV(raw, key) - if start == end { - return raw - } - raw = raw[:start+copy(raw[start:], raw[end:])] - return resizeMap(raw, -1) -} - -// HasKey returns whether the map in 'raw' has -// a field with key 'key' -func HasKey(key string, raw []byte) bool { - sz, bts, err := ReadMapHeaderBytes(raw) - if err != nil { - return false - } - var field []byte - for i := uint32(0); i < sz; i++ { - field, bts, err = ReadStringZC(bts) - if err != nil { - return false - } - if UnsafeString(field) == key { - return true - } - } - return false -} - -func replace(raw []byte, start int, end int, val []byte, inplace bool) []byte { - ll := end - start // length of segment to replace - lv := len(val) - - if inplace { - extra := lv - ll - - // fastest case: we're doing - // a 1:1 replacement - if extra == 0 { - copy(raw[start:], val) - return raw - - } else if extra < 0 { - // 'val' smaller than replaced value - // copy in place and shift back - - x := copy(raw[start:], val) - y := copy(raw[start+x:], raw[end:]) - return raw[:start+x+y] - - } else if extra < cap(raw)-len(raw) { - // 'val' less than (cap-len) extra bytes - // copy in place and shift forward - raw = raw[0 : len(raw)+extra] - // shift end forward - copy(raw[end+extra:], raw[end:]) - copy(raw[start:], val) - return raw - } - } - - // we have to allocate new space - out := make([]byte, len(raw)+len(val)-ll) - x := copy(out, raw[:start]) - y := copy(out[x:], val) - copy(out[x+y:], raw[end:]) - return out -} - -// locate does a naive O(n) search for the map key; returns start, end -// (returns 0,0 on error) -func locate(raw []byte, key string) (start int, end int) { - var ( - sz uint32 - bts []byte - field []byte - err error - ) - sz, bts, err = ReadMapHeaderBytes(raw) - if err != nil { - return - } - - // loop and locate field - for i := uint32(0); i < sz; i++ { - field, bts, err = ReadStringZC(bts) - if err != nil { - return 0, 0 - } - if UnsafeString(field) == key { - // start location - l := len(raw) - start = l - len(bts) - bts, err = Skip(bts) - if err != nil { - return 0, 0 - } - end = l - len(bts) - return - } - bts, err = Skip(bts) - if err != nil { - return 0, 0 - } - } - return 0, 0 -} - -// locate key AND value -func locateKV(raw []byte, key string) (start int, end int) { - var ( - sz uint32 - bts []byte - field []byte - err error - ) - sz, bts, err = ReadMapHeaderBytes(raw) - if err != nil { - return 0, 0 - } - - for i := uint32(0); i < sz; i++ { - tmp := len(bts) - field, bts, err = ReadStringZC(bts) - if err != nil { - return 0, 0 - } - if UnsafeString(field) == key { - start = len(raw) - tmp - bts, err = Skip(bts) - if err != nil { - return 0, 0 - } - end = len(raw) - len(bts) - return - } - bts, err = Skip(bts) - if err != nil { - return 0, 0 - } - } - return 0, 0 -} - -// delta is delta on map size -func resizeMap(raw []byte, delta int64) []byte { - var sz int64 - switch raw[0] { - case mmap16: - sz = int64(big.Uint16(raw[1:])) - if sz+delta <= math.MaxUint16 { - big.PutUint16(raw[1:], uint16(sz+delta)) - return raw - } - if cap(raw)-len(raw) >= 2 { - raw = raw[0 : len(raw)+2] - copy(raw[5:], raw[3:]) - big.PutUint32(raw[1:], uint32(sz+delta)) - return raw - } - n := make([]byte, 0, len(raw)+5) - n = AppendMapHeader(n, uint32(sz+delta)) - return append(n, raw[3:]...) - - case mmap32: - sz = int64(big.Uint32(raw[1:])) - big.PutUint32(raw[1:], uint32(sz+delta)) - return raw - - default: - sz = int64(rfixmap(raw[0])) - if sz+delta < 16 { - raw[0] = wfixmap(uint8(sz + delta)) - return raw - } else if sz+delta <= math.MaxUint16 { - if cap(raw)-len(raw) >= 2 { - raw = raw[0 : len(raw)+2] - copy(raw[3:], raw[1:]) - raw[0] = mmap16 - big.PutUint16(raw[1:], uint16(sz+delta)) - return raw - } - n := make([]byte, 0, len(raw)+5) - n = AppendMapHeader(n, uint32(sz+delta)) - return append(n, raw[1:]...) - } - if cap(raw)-len(raw) >= 4 { - raw = raw[0 : len(raw)+4] - copy(raw[5:], raw[1:]) - raw[0] = mmap32 - big.PutUint32(raw[1:], uint32(sz+delta)) - return raw - } - n := make([]byte, 0, len(raw)+5) - n = AppendMapHeader(n, uint32(sz+delta)) - return append(n, raw[1:]...) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/edit_test.go b/vendor/github.com/tinylib/msgp/msgp/edit_test.go deleted file mode 100644 index e33b4e1..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/edit_test.go +++ /dev/null @@ -1,200 +0,0 @@ -package msgp - -import ( - "bytes" - "reflect" - "testing" -) - -func TestRemove(t *testing.T) { - var buf bytes.Buffer - w := NewWriter(&buf) - w.WriteMapHeader(3) - w.WriteString("first") - w.WriteFloat64(-3.1) - w.WriteString("second") - w.WriteString("DELETE ME!!!") - w.WriteString("third") - w.WriteBytes([]byte("blah")) - w.Flush() - - raw := Remove("second", buf.Bytes()) - - m, _, err := ReadMapStrIntfBytes(raw, nil) - if err != nil { - t.Fatal(err) - } - if len(m) != 2 { - t.Errorf("expected %d fields; found %d", 2, len(m)) - } - if _, ok := m["first"]; !ok { - t.Errorf("field %q not found", "first") - } - if _, ok := m["third"]; !ok { - t.Errorf("field %q not found", "third") - } - if _, ok := m["second"]; ok { - t.Errorf("field %q (deleted field) still present", "second") - } -} - -func TestLocate(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteMapHeader(2) - en.WriteString("thing_one") - en.WriteString("value_one") - en.WriteString("thing_two") - en.WriteFloat64(2.0) - en.Flush() - - field := Locate("thing_one", buf.Bytes()) - if len(field) == 0 { - t.Fatal("field not found") - } - - if !HasKey("thing_one", buf.Bytes()) { - t.Fatal("field not found") - } - - var zbuf bytes.Buffer - w := NewWriter(&zbuf) - w.WriteString("value_one") - w.Flush() - - if !bytes.Equal(zbuf.Bytes(), field) { - t.Errorf("got %q; wanted %q", field, zbuf.Bytes()) - } - - zbuf.Reset() - w.WriteFloat64(2.0) - w.Flush() - field = Locate("thing_two", buf.Bytes()) - if len(field) == 0 { - t.Fatal("field not found") - } - if !bytes.Equal(zbuf.Bytes(), field) { - t.Errorf("got %q; wanted %q", field, zbuf.Bytes()) - } - - field = Locate("nope", buf.Bytes()) - if len(field) != 0 { - t.Fatalf("wanted a zero-length returned slice") - } - -} - -func TestReplace(t *testing.T) { - // there are 4 cases that need coverage: - // - new value is smaller than old value - // - new value is the same size as the old value - // - new value is larger than old, but fits within cap(b) - // - new value is larger than old, and doesn't fit within cap(b) - - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteMapHeader(3) - en.WriteString("thing_one") - en.WriteString("value_one") - en.WriteString("thing_two") - en.WriteFloat64(2.0) - en.WriteString("some_bytes") - en.WriteBytes([]byte("here are some bytes")) - en.Flush() - - // same-size replacement - var fbuf bytes.Buffer - w := NewWriter(&fbuf) - w.WriteFloat64(4.0) - w.Flush() - - // replace 2.0 with 4.0 in field two - raw := Replace("thing_two", buf.Bytes(), fbuf.Bytes()) - if len(raw) == 0 { - t.Fatal("field not found") - } - var err error - m := make(map[string]interface{}) - m, _, err = ReadMapStrIntfBytes(raw, m) - if err != nil { - t.Logf("%q", raw) - t.Fatal(err) - } - - if !reflect.DeepEqual(m["thing_two"], 4.0) { - t.Errorf("wanted %v; got %v", 4.0, m["thing_two"]) - } - - // smaller-size replacement - // replace 2.0 with []byte("hi!") - fbuf.Reset() - w.WriteBytes([]byte("hi!")) - w.Flush() - raw = Replace("thing_two", raw, fbuf.Bytes()) - if len(raw) == 0 { - t.Fatal("field not found") - } - - m, _, err = ReadMapStrIntfBytes(raw, m) - if err != nil { - t.Logf("%q", raw) - t.Fatal(err) - } - - if !reflect.DeepEqual(m["thing_two"], []byte("hi!")) { - t.Errorf("wanted %v; got %v", []byte("hi!"), m["thing_two"]) - } - - // larger-size replacement - fbuf.Reset() - w.WriteBytes([]byte("some even larger bytes than before")) - w.Flush() - raw = Replace("some_bytes", raw, fbuf.Bytes()) - if len(raw) == 0 { - t.Logf("%q", raw) - t.Fatal(err) - } - - m, _, err = ReadMapStrIntfBytes(raw, m) - if err != nil { - t.Logf("%q", raw) - t.Fatal(err) - } - - if !reflect.DeepEqual(m["some_bytes"], []byte("some even larger bytes than before")) { - t.Errorf("wanted %v; got %v", []byte("hello there!"), m["some_bytes"]) - } - - // identical in-place replacement - field := Locate("some_bytes", raw) - newraw := CopyReplace("some_bytes", raw, field) - - if !bytes.Equal(newraw, raw) { - t.Logf("in: %q", raw) - t.Logf("out: %q", newraw) - t.Error("bytes not equal after copyreplace") - } -} - -func BenchmarkLocate(b *testing.B) { - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteMapHeader(3) - en.WriteString("thing_one") - en.WriteString("value_one") - en.WriteString("thing_two") - en.WriteFloat64(2.0) - en.WriteString("thing_three") - en.WriteBytes([]byte("hello!")) - en.Flush() - - raw := buf.Bytes() - // bytes/s will be the number of bytes traversed per unit of time - field := Locate("thing_three", raw) - b.SetBytes(int64(len(raw) - len(field))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - Locate("thing_three", raw) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/elsize.go b/vendor/github.com/tinylib/msgp/msgp/elsize.go deleted file mode 100644 index 95762e7..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/elsize.go +++ /dev/null @@ -1,99 +0,0 @@ -package msgp - -// size of every object on the wire, -// plus type information. gives us -// constant-time type information -// for traversing composite objects. -// -var sizes = [256]bytespec{ - mnil: {size: 1, extra: constsize, typ: NilType}, - mfalse: {size: 1, extra: constsize, typ: BoolType}, - mtrue: {size: 1, extra: constsize, typ: BoolType}, - mbin8: {size: 2, extra: extra8, typ: BinType}, - mbin16: {size: 3, extra: extra16, typ: BinType}, - mbin32: {size: 5, extra: extra32, typ: BinType}, - mext8: {size: 3, extra: extra8, typ: ExtensionType}, - mext16: {size: 4, extra: extra16, typ: ExtensionType}, - mext32: {size: 6, extra: extra32, typ: ExtensionType}, - mfloat32: {size: 5, extra: constsize, typ: Float32Type}, - mfloat64: {size: 9, extra: constsize, typ: Float64Type}, - muint8: {size: 2, extra: constsize, typ: UintType}, - muint16: {size: 3, extra: constsize, typ: UintType}, - muint32: {size: 5, extra: constsize, typ: UintType}, - muint64: {size: 9, extra: constsize, typ: UintType}, - mint8: {size: 2, extra: constsize, typ: IntType}, - mint16: {size: 3, extra: constsize, typ: IntType}, - mint32: {size: 5, extra: constsize, typ: IntType}, - mint64: {size: 9, extra: constsize, typ: IntType}, - mfixext1: {size: 3, extra: constsize, typ: ExtensionType}, - mfixext2: {size: 4, extra: constsize, typ: ExtensionType}, - mfixext4: {size: 6, extra: constsize, typ: ExtensionType}, - mfixext8: {size: 10, extra: constsize, typ: ExtensionType}, - mfixext16: {size: 18, extra: constsize, typ: ExtensionType}, - mstr8: {size: 2, extra: extra8, typ: StrType}, - mstr16: {size: 3, extra: extra16, typ: StrType}, - mstr32: {size: 5, extra: extra32, typ: StrType}, - marray16: {size: 3, extra: array16v, typ: ArrayType}, - marray32: {size: 5, extra: array32v, typ: ArrayType}, - mmap16: {size: 3, extra: map16v, typ: MapType}, - mmap32: {size: 5, extra: map32v, typ: MapType}, -} - -func init() { - // set up fixed fields - - // fixint - for i := mfixint; i < 0x80; i++ { - sizes[i] = bytespec{size: 1, extra: constsize, typ: IntType} - } - - // nfixint - for i := uint16(mnfixint); i < 0x100; i++ { - sizes[uint8(i)] = bytespec{size: 1, extra: constsize, typ: IntType} - } - - // fixstr gets constsize, - // since the prefix yields the size - for i := mfixstr; i < 0xc0; i++ { - sizes[i] = bytespec{size: 1 + rfixstr(i), extra: constsize, typ: StrType} - } - - // fixmap - for i := mfixmap; i < 0x90; i++ { - sizes[i] = bytespec{size: 1, extra: varmode(2 * rfixmap(i)), typ: MapType} - } - - // fixarray - for i := mfixarray; i < 0xa0; i++ { - sizes[i] = bytespec{size: 1, extra: varmode(rfixarray(i)), typ: ArrayType} - } -} - -// a valid bytespsec has -// non-zero 'size' and -// non-zero 'typ' -type bytespec struct { - size uint8 // prefix size information - extra varmode // extra size information - typ Type // type - _ byte // makes bytespec 4 bytes (yes, this matters) -} - -// size mode -// if positive, # elements for composites -type varmode int8 - -const ( - constsize varmode = 0 // constant size (size bytes + uint8(varmode) objects) - extra8 = -1 // has uint8(p[1]) extra bytes - extra16 = -2 // has be16(p[1:]) extra bytes - extra32 = -3 // has be32(p[1:]) extra bytes - map16v = -4 // use map16 - map32v = -5 // use map32 - array16v = -6 // use array16 - array32v = -7 // use array32 -) - -func getType(v byte) Type { - return sizes[v].typ -} diff --git a/vendor/github.com/tinylib/msgp/msgp/errors.go b/vendor/github.com/tinylib/msgp/msgp/errors.go deleted file mode 100644 index 5c24f27..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/errors.go +++ /dev/null @@ -1,142 +0,0 @@ -package msgp - -import ( - "fmt" - "reflect" -) - -var ( - // ErrShortBytes is returned when the - // slice being decoded is too short to - // contain the contents of the message - ErrShortBytes error = errShort{} - - // this error is only returned - // if we reach code that should - // be unreachable - fatal error = errFatal{} -) - -// Error is the interface satisfied -// by all of the errors that originate -// from this package. -type Error interface { - error - - // Resumable returns whether - // or not the error means that - // the stream of data is malformed - // and the information is unrecoverable. - Resumable() bool -} - -type errShort struct{} - -func (e errShort) Error() string { return "msgp: too few bytes left to read object" } -func (e errShort) Resumable() bool { return false } - -type errFatal struct{} - -func (f errFatal) Error() string { return "msgp: fatal decoding error (unreachable code)" } -func (f errFatal) Resumable() bool { return false } - -// ArrayError is an error returned -// when decoding a fix-sized array -// of the wrong size -type ArrayError struct { - Wanted uint32 - Got uint32 -} - -// Error implements the error interface -func (a ArrayError) Error() string { - return fmt.Sprintf("msgp: wanted array of size %d; got %d", a.Wanted, a.Got) -} - -// Resumable is always 'true' for ArrayErrors -func (a ArrayError) Resumable() bool { return true } - -// IntOverflow is returned when a call -// would downcast an integer to a type -// with too few bits to hold its value. -type IntOverflow struct { - Value int64 // the value of the integer - FailedBitsize int // the bit size that the int64 could not fit into -} - -// Error implements the error interface -func (i IntOverflow) Error() string { - return fmt.Sprintf("msgp: %d overflows int%d", i.Value, i.FailedBitsize) -} - -// Resumable is always 'true' for overflows -func (i IntOverflow) Resumable() bool { return true } - -// UintOverflow is returned when a call -// would downcast an unsigned integer to a type -// with too few bits to hold its value -type UintOverflow struct { - Value uint64 // value of the uint - FailedBitsize int // the bit size that couldn't fit the value -} - -// Error implements the error interface -func (u UintOverflow) Error() string { - return fmt.Sprintf("msgp: %d overflows uint%d", u.Value, u.FailedBitsize) -} - -// Resumable is always 'true' for overflows -func (u UintOverflow) Resumable() bool { return true } - -// A TypeError is returned when a particular -// decoding method is unsuitable for decoding -// a particular MessagePack value. -type TypeError struct { - Method Type // Type expected by method - Encoded Type // Type actually encoded -} - -// Error implements the error interface -func (t TypeError) Error() string { - return fmt.Sprintf("msgp: attempted to decode type %q with method for %q", t.Encoded, t.Method) -} - -// Resumable returns 'true' for TypeErrors -func (t TypeError) Resumable() bool { return true } - -// returns either InvalidPrefixError or -// TypeError depending on whether or not -// the prefix is recognized -func badPrefix(want Type, lead byte) error { - t := sizes[lead].typ - if t == InvalidType { - return InvalidPrefixError(lead) - } - return TypeError{Method: want, Encoded: t} -} - -// InvalidPrefixError is returned when a bad encoding -// uses a prefix that is not recognized in the MessagePack standard. -// This kind of error is unrecoverable. -type InvalidPrefixError byte - -// Error implements the error interface -func (i InvalidPrefixError) Error() string { - return fmt.Sprintf("msgp: unrecognized type prefix 0x%x", byte(i)) -} - -// Resumable returns 'false' for InvalidPrefixErrors -func (i InvalidPrefixError) Resumable() bool { return false } - -// ErrUnsupportedType is returned -// when a bad argument is supplied -// to a function that takes `interface{}`. -type ErrUnsupportedType struct { - T reflect.Type -} - -// Error implements error -func (e *ErrUnsupportedType) Error() string { return fmt.Sprintf("msgp: type %q not supported", e.T) } - -// Resumable returns 'true' for ErrUnsupportedType -func (e *ErrUnsupportedType) Resumable() bool { return true } diff --git a/vendor/github.com/tinylib/msgp/msgp/extension.go b/vendor/github.com/tinylib/msgp/msgp/extension.go deleted file mode 100644 index 588b18f..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/extension.go +++ /dev/null @@ -1,548 +0,0 @@ -package msgp - -import ( - "fmt" - "math" -) - -const ( - // Complex64Extension is the extension number used for complex64 - Complex64Extension = 3 - - // Complex128Extension is the extension number used for complex128 - Complex128Extension = 4 - - // TimeExtension is the extension number used for time.Time - TimeExtension = 5 -) - -// our extensions live here -var extensionReg = make(map[int8]func() Extension) - -// RegisterExtension registers extensions so that they -// can be initialized and returned by methods that -// decode `interface{}` values. This should only -// be called during initialization. f() should return -// a newly-initialized zero value of the extension. Keep in -// mind that extensions 3, 4, and 5 are reserved for -// complex64, complex128, and time.Time, respectively, -// and that MessagePack reserves extension types from -127 to -1. -// -// For example, if you wanted to register a user-defined struct: -// -// msgp.RegisterExtension(10, func() msgp.Extension { &MyExtension{} }) -// -// RegisterExtension will panic if you call it multiple times -// with the same 'typ' argument, or if you use a reserved -// type (3, 4, or 5). -func RegisterExtension(typ int8, f func() Extension) { - switch typ { - case Complex64Extension, Complex128Extension, TimeExtension: - panic(fmt.Sprint("msgp: forbidden extension type:", typ)) - } - if _, ok := extensionReg[typ]; ok { - panic(fmt.Sprint("msgp: RegisterExtension() called with typ", typ, "more than once")) - } - extensionReg[typ] = f -} - -// ExtensionTypeError is an error type returned -// when there is a mis-match between an extension type -// and the type encoded on the wire -type ExtensionTypeError struct { - Got int8 - Want int8 -} - -// Error implements the error interface -func (e ExtensionTypeError) Error() string { - return fmt.Sprintf("msgp: error decoding extension: wanted type %d; got type %d", e.Want, e.Got) -} - -// Resumable returns 'true' for ExtensionTypeErrors -func (e ExtensionTypeError) Resumable() bool { return true } - -func errExt(got int8, wanted int8) error { - return ExtensionTypeError{Got: got, Want: wanted} -} - -// Extension is the interface fulfilled -// by types that want to define their -// own binary encoding. -type Extension interface { - // ExtensionType should return - // a int8 that identifies the concrete - // type of the extension. (Types <0 are - // officially reserved by the MessagePack - // specifications.) - ExtensionType() int8 - - // Len should return the length - // of the data to be encoded - Len() int - - // MarshalBinaryTo should copy - // the data into the supplied slice, - // assuming that the slice has length Len() - MarshalBinaryTo([]byte) error - - UnmarshalBinary([]byte) error -} - -// RawExtension implements the Extension interface -type RawExtension struct { - Data []byte - Type int8 -} - -// ExtensionType implements Extension.ExtensionType, and returns r.Type -func (r *RawExtension) ExtensionType() int8 { return r.Type } - -// Len implements Extension.Len, and returns len(r.Data) -func (r *RawExtension) Len() int { return len(r.Data) } - -// MarshalBinaryTo implements Extension.MarshalBinaryTo, -// and returns a copy of r.Data -func (r *RawExtension) MarshalBinaryTo(d []byte) error { - copy(d, r.Data) - return nil -} - -// UnmarshalBinary implements Extension.UnmarshalBinary, -// and sets r.Data to the contents of the provided slice -func (r *RawExtension) UnmarshalBinary(b []byte) error { - if cap(r.Data) >= len(b) { - r.Data = r.Data[0:len(b)] - } else { - r.Data = make([]byte, len(b)) - } - copy(r.Data, b) - return nil -} - -// WriteExtension writes an extension type to the writer -func (mw *Writer) WriteExtension(e Extension) error { - l := e.Len() - var err error - switch l { - case 0: - o, err := mw.require(3) - if err != nil { - return err - } - mw.buf[o] = mext8 - mw.buf[o+1] = 0 - mw.buf[o+2] = byte(e.ExtensionType()) - case 1: - o, err := mw.require(2) - if err != nil { - return err - } - mw.buf[o] = mfixext1 - mw.buf[o+1] = byte(e.ExtensionType()) - case 2: - o, err := mw.require(2) - if err != nil { - return err - } - mw.buf[o] = mfixext2 - mw.buf[o+1] = byte(e.ExtensionType()) - case 4: - o, err := mw.require(2) - if err != nil { - return err - } - mw.buf[o] = mfixext4 - mw.buf[o+1] = byte(e.ExtensionType()) - case 8: - o, err := mw.require(2) - if err != nil { - return err - } - mw.buf[o] = mfixext8 - mw.buf[o+1] = byte(e.ExtensionType()) - case 16: - o, err := mw.require(2) - if err != nil { - return err - } - mw.buf[o] = mfixext16 - mw.buf[o+1] = byte(e.ExtensionType()) - default: - switch { - case l < math.MaxUint8: - o, err := mw.require(3) - if err != nil { - return err - } - mw.buf[o] = mext8 - mw.buf[o+1] = byte(uint8(l)) - mw.buf[o+2] = byte(e.ExtensionType()) - case l < math.MaxUint16: - o, err := mw.require(4) - if err != nil { - return err - } - mw.buf[o] = mext16 - big.PutUint16(mw.buf[o+1:], uint16(l)) - mw.buf[o+3] = byte(e.ExtensionType()) - default: - o, err := mw.require(6) - if err != nil { - return err - } - mw.buf[o] = mext32 - big.PutUint32(mw.buf[o+1:], uint32(l)) - mw.buf[o+5] = byte(e.ExtensionType()) - } - } - // we can only write directly to the - // buffer if we're sure that it - // fits the object - if l <= mw.bufsize() { - o, err := mw.require(l) - if err != nil { - return err - } - return e.MarshalBinaryTo(mw.buf[o:]) - } - // here we create a new buffer - // just large enough for the body - // and save it as the write buffer - err = mw.flush() - if err != nil { - return err - } - buf := make([]byte, l) - err = e.MarshalBinaryTo(buf) - if err != nil { - return err - } - mw.buf = buf - mw.wloc = l - return nil -} - -// peek at the extension type, assuming the next -// kind to be read is Extension -func (m *Reader) peekExtensionType() (int8, error) { - p, err := m.R.Peek(2) - if err != nil { - return 0, err - } - spec := sizes[p[0]] - if spec.typ != ExtensionType { - return 0, badPrefix(ExtensionType, p[0]) - } - if spec.extra == constsize { - return int8(p[1]), nil - } - size := spec.size - p, err = m.R.Peek(int(size)) - if err != nil { - return 0, err - } - return int8(p[size-1]), nil -} - -// peekExtension peeks at the extension encoding type -// (must guarantee at least 1 byte in 'b') -func peekExtension(b []byte) (int8, error) { - spec := sizes[b[0]] - size := spec.size - if spec.typ != ExtensionType { - return 0, badPrefix(ExtensionType, b[0]) - } - if len(b) < int(size) { - return 0, ErrShortBytes - } - // for fixed extensions, - // the type information is in - // the second byte - if spec.extra == constsize { - return int8(b[1]), nil - } - // otherwise, it's in the last - // part of the prefix - return int8(b[size-1]), nil -} - -// ReadExtension reads the next object from the reader -// as an extension. ReadExtension will fail if the next -// object in the stream is not an extension, or if -// e.Type() is not the same as the wire type. -func (m *Reader) ReadExtension(e Extension) (err error) { - var p []byte - p, err = m.R.Peek(2) - if err != nil { - return - } - lead := p[0] - var read int - var off int - switch lead { - case mfixext1: - if int8(p[1]) != e.ExtensionType() { - err = errExt(int8(p[1]), e.ExtensionType()) - return - } - p, err = m.R.Peek(3) - if err != nil { - return - } - err = e.UnmarshalBinary(p[2:]) - if err == nil { - _, err = m.R.Skip(3) - } - return - - case mfixext2: - if int8(p[1]) != e.ExtensionType() { - err = errExt(int8(p[1]), e.ExtensionType()) - return - } - p, err = m.R.Peek(4) - if err != nil { - return - } - err = e.UnmarshalBinary(p[2:]) - if err == nil { - _, err = m.R.Skip(4) - } - return - - case mfixext4: - if int8(p[1]) != e.ExtensionType() { - err = errExt(int8(p[1]), e.ExtensionType()) - return - } - p, err = m.R.Peek(6) - if err != nil { - return - } - err = e.UnmarshalBinary(p[2:]) - if err == nil { - _, err = m.R.Skip(6) - } - return - - case mfixext8: - if int8(p[1]) != e.ExtensionType() { - err = errExt(int8(p[1]), e.ExtensionType()) - return - } - p, err = m.R.Peek(10) - if err != nil { - return - } - err = e.UnmarshalBinary(p[2:]) - if err == nil { - _, err = m.R.Skip(10) - } - return - - case mfixext16: - if int8(p[1]) != e.ExtensionType() { - err = errExt(int8(p[1]), e.ExtensionType()) - return - } - p, err = m.R.Peek(18) - if err != nil { - return - } - err = e.UnmarshalBinary(p[2:]) - if err == nil { - _, err = m.R.Skip(18) - } - return - - case mext8: - p, err = m.R.Peek(3) - if err != nil { - return - } - if int8(p[2]) != e.ExtensionType() { - err = errExt(int8(p[2]), e.ExtensionType()) - return - } - read = int(uint8(p[1])) - off = 3 - - case mext16: - p, err = m.R.Peek(4) - if err != nil { - return - } - if int8(p[3]) != e.ExtensionType() { - err = errExt(int8(p[3]), e.ExtensionType()) - return - } - read = int(big.Uint16(p[1:])) - off = 4 - - case mext32: - p, err = m.R.Peek(6) - if err != nil { - return - } - if int8(p[5]) != e.ExtensionType() { - err = errExt(int8(p[5]), e.ExtensionType()) - return - } - read = int(big.Uint32(p[1:])) - off = 6 - - default: - err = badPrefix(ExtensionType, lead) - return - } - - p, err = m.R.Peek(read + off) - if err != nil { - return - } - err = e.UnmarshalBinary(p[off:]) - if err == nil { - _, err = m.R.Skip(read + off) - } - return -} - -// AppendExtension appends a MessagePack extension to the provided slice -func AppendExtension(b []byte, e Extension) ([]byte, error) { - l := e.Len() - var o []byte - var n int - switch l { - case 0: - o, n = ensure(b, 3) - o[n] = mext8 - o[n+1] = 0 - o[n+2] = byte(e.ExtensionType()) - return o[:n+3], nil - case 1: - o, n = ensure(b, 3) - o[n] = mfixext1 - o[n+1] = byte(e.ExtensionType()) - n += 2 - case 2: - o, n = ensure(b, 4) - o[n] = mfixext2 - o[n+1] = byte(e.ExtensionType()) - n += 2 - case 4: - o, n = ensure(b, 6) - o[n] = mfixext4 - o[n+1] = byte(e.ExtensionType()) - n += 2 - case 8: - o, n = ensure(b, 10) - o[n] = mfixext8 - o[n+1] = byte(e.ExtensionType()) - n += 2 - case 16: - o, n = ensure(b, 18) - o[n] = mfixext16 - o[n+1] = byte(e.ExtensionType()) - n += 2 - } - switch { - case l < math.MaxUint8: - o, n = ensure(b, l+3) - o[n] = mext8 - o[n+1] = byte(uint8(l)) - o[n+2] = byte(e.ExtensionType()) - n += 3 - case l < math.MaxUint16: - o, n = ensure(b, l+4) - o[n] = mext16 - big.PutUint16(o[n+1:], uint16(l)) - o[n+3] = byte(e.ExtensionType()) - n += 4 - default: - o, n = ensure(b, l+6) - o[n] = mext32 - big.PutUint32(o[n+1:], uint32(l)) - o[n+5] = byte(e.ExtensionType()) - n += 6 - } - return o, e.MarshalBinaryTo(o[n:]) -} - -// ReadExtensionBytes reads an extension from 'b' into 'e' -// and returns any remaining bytes. -// Possible errors: -// - ErrShortBytes ('b' not long enough) -// - ExtensionTypeErorr{} (wire type not the same as e.Type()) -// - TypeErorr{} (next object not an extension) -// - InvalidPrefixError -// - An umarshal error returned from e.UnmarshalBinary -func ReadExtensionBytes(b []byte, e Extension) ([]byte, error) { - l := len(b) - if l < 3 { - return b, ErrShortBytes - } - lead := b[0] - var ( - sz int // size of 'data' - off int // offset of 'data' - typ int8 - ) - switch lead { - case mfixext1: - typ = int8(b[1]) - sz = 1 - off = 2 - case mfixext2: - typ = int8(b[1]) - sz = 2 - off = 2 - case mfixext4: - typ = int8(b[1]) - sz = 4 - off = 2 - case mfixext8: - typ = int8(b[1]) - sz = 8 - off = 2 - case mfixext16: - typ = int8(b[1]) - sz = 16 - off = 2 - case mext8: - sz = int(uint8(b[1])) - typ = int8(b[2]) - off = 3 - if sz == 0 { - return b[3:], e.UnmarshalBinary(b[3:3]) - } - case mext16: - if l < 4 { - return b, ErrShortBytes - } - sz = int(big.Uint16(b[1:])) - typ = int8(b[3]) - off = 4 - case mext32: - if l < 6 { - return b, ErrShortBytes - } - sz = int(big.Uint32(b[1:])) - typ = int8(b[5]) - off = 6 - default: - return b, badPrefix(ExtensionType, lead) - } - - if typ != e.ExtensionType() { - return b, errExt(typ, e.ExtensionType()) - } - - // the data of the extension starts - // at 'off' and is 'sz' bytes long - if len(b[off:]) < sz { - return b, ErrShortBytes - } - tot := off + sz - return b[tot:], e.UnmarshalBinary(b[off:tot]) -} diff --git a/vendor/github.com/tinylib/msgp/msgp/extension_test.go b/vendor/github.com/tinylib/msgp/msgp/extension_test.go deleted file mode 100644 index d46fcfe..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/extension_test.go +++ /dev/null @@ -1,49 +0,0 @@ -package msgp - -import ( - "bytes" - "math/rand" - "testing" - "time" -) - -var extSizes = [...]int{0, 1, 2, 4, 8, 16, int(tint8), int(tuint16), int(tuint32)} - -func randomExt() RawExtension { - e := RawExtension{} - e.Type = int8(rand.Int()) - e.Data = RandBytes(extSizes[rand.Intn(len(extSizes))]) - return e -} - -func TestReadWriteExtension(t *testing.T) { - rand.Seed(time.Now().Unix()) - var buf bytes.Buffer - en := NewWriter(&buf) - dc := NewReader(&buf) - - for i := 0; i < 25; i++ { - buf.Reset() - e := randomExt() - en.WriteExtension(&e) - en.Flush() - err := dc.ReadExtension(&e) - if err != nil { - t.Errorf("error with extension (length %d): %s", len(buf.Bytes()), err) - } - } -} - -func TestReadWriteExtensionBytes(t *testing.T) { - var bts []byte - rand.Seed(time.Now().Unix()) - - for i := 0; i < 24; i++ { - e := randomExt() - bts, _ = AppendExtension(bts[0:0], &e) - _, err := ReadExtensionBytes(bts, &e) - if err != nil { - t.Errorf("error with extension (length %d): %s", len(bts), err) - } - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/file.go b/vendor/github.com/tinylib/msgp/msgp/file.go deleted file mode 100644 index 8e7370e..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/file.go +++ /dev/null @@ -1,92 +0,0 @@ -// +build linux darwin dragonfly freebsd netbsd openbsd -// +build !appengine - -package msgp - -import ( - "os" - "syscall" -) - -// ReadFile reads a file into 'dst' using -// a read-only memory mapping. Consequently, -// the file must be mmap-able, and the -// Unmarshaler should never write to -// the source memory. (Methods generated -// by the msgp tool obey that constraint, but -// user-defined implementations may not.) -// -// Reading and writing through file mappings -// is only efficient for large files; small -// files are best read and written using -// the ordinary streaming interfaces. -// -func ReadFile(dst Unmarshaler, file *os.File) error { - stat, err := file.Stat() - if err != nil { - return err - } - data, err := syscall.Mmap(int(file.Fd()), 0, int(stat.Size()), syscall.PROT_READ, syscall.MAP_SHARED) - if err != nil { - return err - } - adviseRead(data) - _, err = dst.UnmarshalMsg(data) - uerr := syscall.Munmap(data) - if err == nil { - err = uerr - } - return err -} - -// MarshalSizer is the combination -// of the Marshaler and Sizer -// interfaces. -type MarshalSizer interface { - Marshaler - Sizer -} - -// WriteFile writes a file from 'src' using -// memory mapping. It overwrites the entire -// contents of the previous file. -// The mapping size is calculated -// using the `Msgsize()` method -// of 'src', so it must produce a result -// equal to or greater than the actual encoded -// size of the object. Otherwise, -// a fault (SIGBUS) will occur. -// -// Reading and writing through file mappings -// is only efficient for large files; small -// files are best read and written using -// the ordinary streaming interfaces. -// -// NOTE: The performance of this call -// is highly OS- and filesystem-dependent. -// Users should take care to test that this -// performs as expected in a production environment. -// (Linux users should run a kernel and filesystem -// that support fallocate(2) for the best results.) -func WriteFile(src MarshalSizer, file *os.File) error { - sz := src.Msgsize() - err := fallocate(file, int64(sz)) - if err != nil { - return err - } - data, err := syscall.Mmap(int(file.Fd()), 0, sz, syscall.PROT_READ|syscall.PROT_WRITE, syscall.MAP_SHARED) - if err != nil { - return err - } - adviseWrite(data) - chunk := data[:0] - chunk, err = src.MarshalMsg(chunk) - if err != nil { - return err - } - uerr := syscall.Munmap(data) - if uerr != nil { - return uerr - } - return file.Truncate(int64(len(chunk))) -} diff --git a/vendor/github.com/tinylib/msgp/msgp/file_port.go b/vendor/github.com/tinylib/msgp/msgp/file_port.go deleted file mode 100644 index 6e654db..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/file_port.go +++ /dev/null @@ -1,47 +0,0 @@ -// +build windows appengine - -package msgp - -import ( - "io/ioutil" - "os" -) - -// MarshalSizer is the combination -// of the Marshaler and Sizer -// interfaces. -type MarshalSizer interface { - Marshaler - Sizer -} - -func ReadFile(dst Unmarshaler, file *os.File) error { - if u, ok := dst.(Decodable); ok { - return u.DecodeMsg(NewReader(file)) - } - - data, err := ioutil.ReadAll(file) - if err != nil { - return err - } - _, err = dst.UnmarshalMsg(data) - return err -} - -func WriteFile(src MarshalSizer, file *os.File) error { - if e, ok := src.(Encodable); ok { - w := NewWriter(file) - err := e.EncodeMsg(w) - if err == nil { - err = w.Flush() - } - return err - } - - raw, err := src.MarshalMsg(nil) - if err != nil { - return err - } - _, err = file.Write(raw) - return err -} diff --git a/vendor/github.com/tinylib/msgp/msgp/file_test.go b/vendor/github.com/tinylib/msgp/msgp/file_test.go deleted file mode 100644 index 1cc01ce..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/file_test.go +++ /dev/null @@ -1,103 +0,0 @@ -// +build linux darwin dragonfly freebsd netbsd openbsd - -package msgp_test - -import ( - "bytes" - "crypto/rand" - "github.com/tinylib/msgp/msgp" - prand "math/rand" - "os" - "testing" -) - -type rawBytes []byte - -func (r rawBytes) MarshalMsg(b []byte) ([]byte, error) { - return msgp.AppendBytes(b, []byte(r)), nil -} - -func (r rawBytes) Msgsize() int { - return msgp.BytesPrefixSize + len(r) -} - -func (r *rawBytes) UnmarshalMsg(b []byte) ([]byte, error) { - tmp, out, err := msgp.ReadBytesBytes(b, (*(*[]byte)(r))[:0]) - *r = rawBytes(tmp) - return out, err -} - -func TestReadWriteFile(t *testing.T) { - t.Parallel() - - f, err := os.Create("tmpfile") - if err != nil { - t.Fatal(err) - } - defer func() { - f.Close() - os.Remove("tmpfile") - }() - - data := make([]byte, 1024*1024) - rand.Read(data) - - err = msgp.WriteFile(rawBytes(data), f) - if err != nil { - t.Fatal(err) - } - - var out rawBytes - f.Seek(0, os.SEEK_SET) - err = msgp.ReadFile(&out, f) - if err != nil { - t.Fatal(err) - } - - if !bytes.Equal([]byte(out), []byte(data)) { - t.Fatal("Input and output not equal.") - } -} - -var blobstrings = []string{"", "a string", "a longer string here!"} -var blobfloats = []float64{0.0, -1.0, 1.0, 3.1415926535} -var blobints = []int64{0, 1, -1, 80000, 1 << 30} -var blobbytes = [][]byte{[]byte{}, []byte("hello"), []byte("{\"is_json\":true,\"is_compact\":\"unable to determine\"}")} - -func BenchmarkWriteReadFile(b *testing.B) { - - // let's not run out of disk space... - if b.N > 10000000 { - b.N = 10000000 - } - - fname := "bench-tmpfile" - f, err := os.Create(fname) - if err != nil { - b.Fatal(err) - } - defer func(f *os.File, name string) { - f.Close() - os.Remove(name) - }(f, fname) - - data := make(Blobs, b.N) - - for i := range data { - data[i].Name = blobstrings[prand.Intn(len(blobstrings))] - data[i].Float = blobfloats[prand.Intn(len(blobfloats))] - data[i].Amount = blobints[prand.Intn(len(blobints))] - data[i].Bytes = blobbytes[prand.Intn(len(blobbytes))] - } - - b.SetBytes(int64(data.Msgsize() / b.N)) - b.ResetTimer() - err = msgp.WriteFile(data, f) - if err != nil { - b.Fatal(err) - } - err = msgp.ReadFile(&data, f) - if err != nil { - b.Fatal(err) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/floatbench_test.go b/vendor/github.com/tinylib/msgp/msgp/floatbench_test.go deleted file mode 100644 index 575b081..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/floatbench_test.go +++ /dev/null @@ -1,25 +0,0 @@ -package msgp - -import ( - "testing" -) - -func BenchmarkReadWriteFloat32(b *testing.B) { - var f float32 = 3.9081 - bts := AppendFloat32([]byte{}, f) - b.ResetTimer() - for i := 0; i < b.N; i++ { - bts = AppendFloat32(bts[0:0], f) - f, bts, _ = ReadFloat32Bytes(bts) - } -} - -func BenchmarkReadWriteFloat64(b *testing.B) { - var f float64 = 3.9081 - bts := AppendFloat64([]byte{}, f) - b.ResetTimer() - for i := 0; i < b.N; i++ { - bts = AppendFloat64(bts[0:0], f) - f, bts, _ = ReadFloat64Bytes(bts) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/integers.go b/vendor/github.com/tinylib/msgp/msgp/integers.go deleted file mode 100644 index f817d77..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/integers.go +++ /dev/null @@ -1,174 +0,0 @@ -package msgp - -/* ---------------------------------- - integer encoding utilities - (inline-able) - - TODO(tinylib): there are faster, - albeit non-portable solutions - to the code below. implement - byteswap? - ---------------------------------- */ - -func putMint64(b []byte, i int64) { - b[0] = mint64 - b[1] = byte(i >> 56) - b[2] = byte(i >> 48) - b[3] = byte(i >> 40) - b[4] = byte(i >> 32) - b[5] = byte(i >> 24) - b[6] = byte(i >> 16) - b[7] = byte(i >> 8) - b[8] = byte(i) -} - -func getMint64(b []byte) int64 { - return (int64(b[1]) << 56) | (int64(b[2]) << 48) | - (int64(b[3]) << 40) | (int64(b[4]) << 32) | - (int64(b[5]) << 24) | (int64(b[6]) << 16) | - (int64(b[7]) << 8) | (int64(b[8])) -} - -func putMint32(b []byte, i int32) { - b[0] = mint32 - b[1] = byte(i >> 24) - b[2] = byte(i >> 16) - b[3] = byte(i >> 8) - b[4] = byte(i) -} - -func getMint32(b []byte) int32 { - return (int32(b[1]) << 24) | (int32(b[2]) << 16) | (int32(b[3]) << 8) | (int32(b[4])) -} - -func putMint16(b []byte, i int16) { - b[0] = mint16 - b[1] = byte(i >> 8) - b[2] = byte(i) -} - -func getMint16(b []byte) (i int16) { - return (int16(b[1]) << 8) | int16(b[2]) -} - -func putMint8(b []byte, i int8) { - b[0] = mint8 - b[1] = byte(i) -} - -func getMint8(b []byte) (i int8) { - return int8(b[1]) -} - -func putMuint64(b []byte, u uint64) { - b[0] = muint64 - b[1] = byte(u >> 56) - b[2] = byte(u >> 48) - b[3] = byte(u >> 40) - b[4] = byte(u >> 32) - b[5] = byte(u >> 24) - b[6] = byte(u >> 16) - b[7] = byte(u >> 8) - b[8] = byte(u) -} - -func getMuint64(b []byte) uint64 { - return (uint64(b[1]) << 56) | (uint64(b[2]) << 48) | - (uint64(b[3]) << 40) | (uint64(b[4]) << 32) | - (uint64(b[5]) << 24) | (uint64(b[6]) << 16) | - (uint64(b[7]) << 8) | (uint64(b[8])) -} - -func putMuint32(b []byte, u uint32) { - b[0] = muint32 - b[1] = byte(u >> 24) - b[2] = byte(u >> 16) - b[3] = byte(u >> 8) - b[4] = byte(u) -} - -func getMuint32(b []byte) uint32 { - return (uint32(b[1]) << 24) | (uint32(b[2]) << 16) | (uint32(b[3]) << 8) | (uint32(b[4])) -} - -func putMuint16(b []byte, u uint16) { - b[0] = muint16 - b[1] = byte(u >> 8) - b[2] = byte(u) -} - -func getMuint16(b []byte) uint16 { - return (uint16(b[1]) << 8) | uint16(b[2]) -} - -func putMuint8(b []byte, u uint8) { - b[0] = muint8 - b[1] = byte(u) -} - -func getMuint8(b []byte) uint8 { - return uint8(b[1]) -} - -func getUnix(b []byte) (sec int64, nsec int32) { - sec = (int64(b[0]) << 56) | (int64(b[1]) << 48) | - (int64(b[2]) << 40) | (int64(b[3]) << 32) | - (int64(b[4]) << 24) | (int64(b[5]) << 16) | - (int64(b[6]) << 8) | (int64(b[7])) - - nsec = (int32(b[8]) << 24) | (int32(b[9]) << 16) | (int32(b[10]) << 8) | (int32(b[11])) - return -} - -func putUnix(b []byte, sec int64, nsec int32) { - b[0] = byte(sec >> 56) - b[1] = byte(sec >> 48) - b[2] = byte(sec >> 40) - b[3] = byte(sec >> 32) - b[4] = byte(sec >> 24) - b[5] = byte(sec >> 16) - b[6] = byte(sec >> 8) - b[7] = byte(sec) - b[8] = byte(nsec >> 24) - b[9] = byte(nsec >> 16) - b[10] = byte(nsec >> 8) - b[11] = byte(nsec) -} - -/* ----------------------------- - prefix utilities - ----------------------------- */ - -// write prefix and uint8 -func prefixu8(b []byte, pre byte, sz uint8) { - b[0] = pre - b[1] = byte(sz) -} - -// write prefix and big-endian uint16 -func prefixu16(b []byte, pre byte, sz uint16) { - b[0] = pre - b[1] = byte(sz >> 8) - b[2] = byte(sz) -} - -// write prefix and big-endian uint32 -func prefixu32(b []byte, pre byte, sz uint32) { - b[0] = pre - b[1] = byte(sz >> 24) - b[2] = byte(sz >> 16) - b[3] = byte(sz >> 8) - b[4] = byte(sz) -} - -func prefixu64(b []byte, pre byte, sz uint64) { - b[0] = pre - b[1] = byte(sz >> 56) - b[2] = byte(sz >> 48) - b[3] = byte(sz >> 40) - b[4] = byte(sz >> 32) - b[5] = byte(sz >> 24) - b[6] = byte(sz >> 16) - b[7] = byte(sz >> 8) - b[8] = byte(sz) -} diff --git a/vendor/github.com/tinylib/msgp/msgp/json.go b/vendor/github.com/tinylib/msgp/msgp/json.go deleted file mode 100644 index 4325860..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/json.go +++ /dev/null @@ -1,542 +0,0 @@ -package msgp - -import ( - "bufio" - "encoding/base64" - "encoding/json" - "io" - "strconv" - "unicode/utf8" -) - -var ( - null = []byte("null") - hex = []byte("0123456789abcdef") -) - -var defuns [_maxtype]func(jsWriter, *Reader) (int, error) - -// note: there is an initialization loop if -// this isn't set up during init() -func init() { - // since none of these functions are inline-able, - // there is not much of a penalty to the indirect - // call. however, this is best expressed as a jump-table... - defuns = [_maxtype]func(jsWriter, *Reader) (int, error){ - StrType: rwString, - BinType: rwBytes, - MapType: rwMap, - ArrayType: rwArray, - Float64Type: rwFloat64, - Float32Type: rwFloat32, - BoolType: rwBool, - IntType: rwInt, - UintType: rwUint, - NilType: rwNil, - ExtensionType: rwExtension, - Complex64Type: rwExtension, - Complex128Type: rwExtension, - TimeType: rwTime, - } -} - -// this is the interface -// used to write json -type jsWriter interface { - io.Writer - io.ByteWriter - WriteString(string) (int, error) -} - -// CopyToJSON reads MessagePack from 'src' and copies it -// as JSON to 'dst' until EOF. -func CopyToJSON(dst io.Writer, src io.Reader) (n int64, err error) { - r := NewReader(src) - n, err = r.WriteToJSON(dst) - freeR(r) - return -} - -// WriteToJSON translates MessagePack from 'r' and writes it as -// JSON to 'w' until the underlying reader returns io.EOF. It returns -// the number of bytes written, and an error if it stopped before EOF. -func (r *Reader) WriteToJSON(w io.Writer) (n int64, err error) { - var j jsWriter - var bf *bufio.Writer - if jsw, ok := w.(jsWriter); ok { - j = jsw - } else { - bf = bufio.NewWriter(w) - j = bf - } - var nn int - for err == nil { - nn, err = rwNext(j, r) - n += int64(nn) - } - if err != io.EOF { - if bf != nil { - bf.Flush() - } - return - } - err = nil - if bf != nil { - err = bf.Flush() - } - return -} - -func rwNext(w jsWriter, src *Reader) (int, error) { - t, err := src.NextType() - if err != nil { - return 0, err - } - return defuns[t](w, src) -} - -func rwMap(dst jsWriter, src *Reader) (n int, err error) { - var comma bool - var sz uint32 - var field []byte - - sz, err = src.ReadMapHeader() - if err != nil { - return - } - - if sz == 0 { - return dst.WriteString("{}") - } - - err = dst.WriteByte('{') - if err != nil { - return - } - n++ - var nn int - for i := uint32(0); i < sz; i++ { - if comma { - err = dst.WriteByte(',') - if err != nil { - return - } - n++ - } - - field, err = src.ReadMapKeyPtr() - if err != nil { - return - } - nn, err = rwquoted(dst, field) - n += nn - if err != nil { - return - } - - err = dst.WriteByte(':') - if err != nil { - return - } - n++ - nn, err = rwNext(dst, src) - n += nn - if err != nil { - return - } - if !comma { - comma = true - } - } - - err = dst.WriteByte('}') - if err != nil { - return - } - n++ - return -} - -func rwArray(dst jsWriter, src *Reader) (n int, err error) { - err = dst.WriteByte('[') - if err != nil { - return - } - var sz uint32 - var nn int - sz, err = src.ReadArrayHeader() - if err != nil { - return - } - comma := false - for i := uint32(0); i < sz; i++ { - if comma { - err = dst.WriteByte(',') - if err != nil { - return - } - n++ - } - nn, err = rwNext(dst, src) - n += nn - if err != nil { - return - } - comma = true - } - - err = dst.WriteByte(']') - if err != nil { - return - } - n++ - return -} - -func rwNil(dst jsWriter, src *Reader) (int, error) { - err := src.ReadNil() - if err != nil { - return 0, err - } - return dst.Write(null) -} - -func rwFloat32(dst jsWriter, src *Reader) (int, error) { - f, err := src.ReadFloat32() - if err != nil { - return 0, err - } - src.scratch = strconv.AppendFloat(src.scratch[:0], float64(f), 'f', -1, 64) - return dst.Write(src.scratch) -} - -func rwFloat64(dst jsWriter, src *Reader) (int, error) { - f, err := src.ReadFloat64() - if err != nil { - return 0, err - } - src.scratch = strconv.AppendFloat(src.scratch[:0], f, 'f', -1, 32) - return dst.Write(src.scratch) -} - -func rwInt(dst jsWriter, src *Reader) (int, error) { - i, err := src.ReadInt64() - if err != nil { - return 0, err - } - src.scratch = strconv.AppendInt(src.scratch[:0], i, 10) - return dst.Write(src.scratch) -} - -func rwUint(dst jsWriter, src *Reader) (int, error) { - u, err := src.ReadUint64() - if err != nil { - return 0, err - } - src.scratch = strconv.AppendUint(src.scratch[:0], u, 10) - return dst.Write(src.scratch) -} - -func rwBool(dst jsWriter, src *Reader) (int, error) { - b, err := src.ReadBool() - if err != nil { - return 0, err - } - if b { - return dst.WriteString("true") - } - return dst.WriteString("false") -} - -func rwTime(dst jsWriter, src *Reader) (int, error) { - t, err := src.ReadTime() - if err != nil { - return 0, err - } - bts, err := t.MarshalJSON() - if err != nil { - return 0, err - } - return dst.Write(bts) -} - -func rwExtension(dst jsWriter, src *Reader) (n int, err error) { - et, err := src.peekExtensionType() - if err != nil { - return 0, err - } - - // registered extensions can override - // the JSON encoding - if j, ok := extensionReg[et]; ok { - var bts []byte - e := j() - err = src.ReadExtension(e) - if err != nil { - return - } - bts, err = json.Marshal(e) - if err != nil { - return - } - return dst.Write(bts) - } - - e := RawExtension{} - e.Type = et - err = src.ReadExtension(&e) - if err != nil { - return - } - - var nn int - err = dst.WriteByte('{') - if err != nil { - return - } - n++ - - nn, err = dst.WriteString(`"type:"`) - n += nn - if err != nil { - return - } - - src.scratch = strconv.AppendInt(src.scratch[0:0], int64(e.Type), 10) - nn, err = dst.Write(src.scratch) - n += nn - if err != nil { - return - } - - nn, err = dst.WriteString(`,"data":"`) - n += nn - if err != nil { - return - } - - enc := base64.NewEncoder(base64.StdEncoding, dst) - - nn, err = enc.Write(e.Data) - n += nn - if err != nil { - return - } - err = enc.Close() - if err != nil { - return - } - nn, err = dst.WriteString(`"}`) - n += nn - return -} - -func rwString(dst jsWriter, src *Reader) (n int, err error) { - var p []byte - p, err = src.R.Peek(1) - if err != nil { - return - } - lead := p[0] - var read int - - if isfixstr(lead) { - read = int(rfixstr(lead)) - src.R.Skip(1) - goto write - } - - switch lead { - case mstr8: - p, err = src.R.Next(2) - if err != nil { - return - } - read = int(uint8(p[1])) - case mstr16: - p, err = src.R.Next(3) - if err != nil { - return - } - read = int(big.Uint16(p[1:])) - case mstr32: - p, err = src.R.Next(5) - if err != nil { - return - } - read = int(big.Uint32(p[1:])) - default: - err = badPrefix(StrType, lead) - return - } -write: - p, err = src.R.Next(read) - if err != nil { - return - } - n, err = rwquoted(dst, p) - return -} - -func rwBytes(dst jsWriter, src *Reader) (n int, err error) { - var nn int - err = dst.WriteByte('"') - if err != nil { - return - } - n++ - src.scratch, err = src.ReadBytes(src.scratch[:0]) - if err != nil { - return - } - enc := base64.NewEncoder(base64.StdEncoding, dst) - nn, err = enc.Write(src.scratch) - n += nn - if err != nil { - return - } - err = enc.Close() - if err != nil { - return - } - err = dst.WriteByte('"') - if err != nil { - return - } - n++ - return -} - -// Below (c) The Go Authors, 2009-2014 -// Subject to the BSD-style license found at http://golang.org -// -// see: encoding/json/encode.go:(*encodeState).stringbytes() -func rwquoted(dst jsWriter, s []byte) (n int, err error) { - var nn int - err = dst.WriteByte('"') - if err != nil { - return - } - n++ - start := 0 - for i := 0; i < len(s); { - if b := s[i]; b < utf8.RuneSelf { - if 0x20 <= b && b != '\\' && b != '"' && b != '<' && b != '>' && b != '&' { - i++ - continue - } - if start < i { - nn, err = dst.Write(s[start:i]) - n += nn - if err != nil { - return - } - } - switch b { - case '\\', '"': - err = dst.WriteByte('\\') - if err != nil { - return - } - n++ - err = dst.WriteByte(b) - if err != nil { - return - } - n++ - case '\n': - err = dst.WriteByte('\\') - if err != nil { - return - } - n++ - err = dst.WriteByte('n') - if err != nil { - return - } - n++ - case '\r': - err = dst.WriteByte('\\') - if err != nil { - return - } - n++ - err = dst.WriteByte('r') - if err != nil { - return - } - n++ - default: - nn, err = dst.WriteString(`\u00`) - n += nn - if err != nil { - return - } - err = dst.WriteByte(hex[b>>4]) - if err != nil { - return - } - n++ - err = dst.WriteByte(hex[b&0xF]) - if err != nil { - return - } - n++ - } - i++ - start = i - continue - } - c, size := utf8.DecodeRune(s[i:]) - if c == utf8.RuneError && size == 1 { - if start < i { - nn, err = dst.Write(s[start:i]) - n += nn - if err != nil { - return - } - nn, err = dst.WriteString(`\ufffd`) - n += nn - if err != nil { - return - } - i += size - start = i - continue - } - } - if c == '\u2028' || c == '\u2029' { - if start < i { - nn, err = dst.Write(s[start:i]) - n += nn - if err != nil { - return - } - nn, err = dst.WriteString(`\u202`) - n += nn - if err != nil { - return - } - err = dst.WriteByte(hex[c&0xF]) - if err != nil { - return - } - n++ - } - } - i += size - } - if start < len(s) { - nn, err = dst.Write(s[start:]) - n += nn - if err != nil { - return - } - } - err = dst.WriteByte('"') - if err != nil { - return - } - n++ - return -} diff --git a/vendor/github.com/tinylib/msgp/msgp/json_bytes.go b/vendor/github.com/tinylib/msgp/msgp/json_bytes.go deleted file mode 100644 index 438caf5..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/json_bytes.go +++ /dev/null @@ -1,363 +0,0 @@ -package msgp - -import ( - "bufio" - "encoding/base64" - "encoding/json" - "io" - "strconv" - "time" -) - -var unfuns [_maxtype]func(jsWriter, []byte, []byte) ([]byte, []byte, error) - -func init() { - - // NOTE(pmh): this is best expressed as a jump table, - // but gc doesn't do that yet. revisit post-go1.5. - unfuns = [_maxtype]func(jsWriter, []byte, []byte) ([]byte, []byte, error){ - StrType: rwStringBytes, - BinType: rwBytesBytes, - MapType: rwMapBytes, - ArrayType: rwArrayBytes, - Float64Type: rwFloat64Bytes, - Float32Type: rwFloat32Bytes, - BoolType: rwBoolBytes, - IntType: rwIntBytes, - UintType: rwUintBytes, - NilType: rwNullBytes, - ExtensionType: rwExtensionBytes, - Complex64Type: rwExtensionBytes, - Complex128Type: rwExtensionBytes, - TimeType: rwTimeBytes, - } -} - -// UnmarshalAsJSON takes raw messagepack and writes -// it as JSON to 'w'. If an error is returned, the -// bytes not translated will also be returned. If -// no errors are encountered, the length of the returned -// slice will be zero. -func UnmarshalAsJSON(w io.Writer, msg []byte) ([]byte, error) { - var ( - scratch []byte - cast bool - dst jsWriter - err error - ) - if jsw, ok := w.(jsWriter); ok { - dst = jsw - cast = true - } else { - dst = bufio.NewWriterSize(w, 512) - } - for len(msg) > 0 && err == nil { - msg, scratch, err = writeNext(dst, msg, scratch) - } - if !cast && err == nil { - err = dst.(*bufio.Writer).Flush() - } - return msg, err -} - -func writeNext(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - if len(msg) < 1 { - return msg, scratch, ErrShortBytes - } - t := getType(msg[0]) - if t == InvalidType { - return msg, scratch, InvalidPrefixError(msg[0]) - } - if t == ExtensionType { - et, err := peekExtension(msg) - if err != nil { - return nil, scratch, err - } - if et == TimeExtension { - t = TimeType - } - } - return unfuns[t](w, msg, scratch) -} - -func rwArrayBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - sz, msg, err := ReadArrayHeaderBytes(msg) - if err != nil { - return msg, scratch, err - } - err = w.WriteByte('[') - if err != nil { - return msg, scratch, err - } - for i := uint32(0); i < sz; i++ { - if i != 0 { - err = w.WriteByte(',') - if err != nil { - return msg, scratch, err - } - } - msg, scratch, err = writeNext(w, msg, scratch) - if err != nil { - return msg, scratch, err - } - } - err = w.WriteByte(']') - return msg, scratch, err -} - -func rwMapBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - sz, msg, err := ReadMapHeaderBytes(msg) - if err != nil { - return msg, scratch, err - } - err = w.WriteByte('{') - if err != nil { - return msg, scratch, err - } - for i := uint32(0); i < sz; i++ { - if i != 0 { - err = w.WriteByte(',') - if err != nil { - return msg, scratch, err - } - } - msg, scratch, err = rwMapKeyBytes(w, msg, scratch) - if err != nil { - return msg, scratch, err - } - err = w.WriteByte(':') - if err != nil { - return msg, scratch, err - } - msg, scratch, err = writeNext(w, msg, scratch) - if err != nil { - return msg, scratch, err - } - } - err = w.WriteByte('}') - return msg, scratch, err -} - -func rwMapKeyBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - msg, scratch, err := rwStringBytes(w, msg, scratch) - if err != nil { - if tperr, ok := err.(TypeError); ok && tperr.Encoded == BinType { - return rwBytesBytes(w, msg, scratch) - } - } - return msg, scratch, err -} - -func rwStringBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - str, msg, err := ReadStringZC(msg) - if err != nil { - return msg, scratch, err - } - _, err = rwquoted(w, str) - return msg, scratch, err -} - -func rwBytesBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - bts, msg, err := ReadBytesZC(msg) - if err != nil { - return msg, scratch, err - } - l := base64.StdEncoding.EncodedLen(len(bts)) - if cap(scratch) >= l { - scratch = scratch[0:l] - } else { - scratch = make([]byte, l) - } - base64.StdEncoding.Encode(scratch, bts) - err = w.WriteByte('"') - if err != nil { - return msg, scratch, err - } - _, err = w.Write(scratch) - if err != nil { - return msg, scratch, err - } - err = w.WriteByte('"') - return msg, scratch, err -} - -func rwNullBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - msg, err := ReadNilBytes(msg) - if err != nil { - return msg, scratch, err - } - _, err = w.Write(null) - return msg, scratch, err -} - -func rwBoolBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - b, msg, err := ReadBoolBytes(msg) - if err != nil { - return msg, scratch, err - } - if b { - _, err = w.WriteString("true") - return msg, scratch, err - } - _, err = w.WriteString("false") - return msg, scratch, err -} - -func rwIntBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - i, msg, err := ReadInt64Bytes(msg) - if err != nil { - return msg, scratch, err - } - scratch = strconv.AppendInt(scratch[0:0], i, 10) - _, err = w.Write(scratch) - return msg, scratch, err -} - -func rwUintBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - u, msg, err := ReadUint64Bytes(msg) - if err != nil { - return msg, scratch, err - } - scratch = strconv.AppendUint(scratch[0:0], u, 10) - _, err = w.Write(scratch) - return msg, scratch, err -} - -func rwFloatBytes(w jsWriter, msg []byte, f64 bool, scratch []byte) ([]byte, []byte, error) { - var f float64 - var err error - var sz int - if f64 { - sz = 64 - f, msg, err = ReadFloat64Bytes(msg) - } else { - sz = 32 - var v float32 - v, msg, err = ReadFloat32Bytes(msg) - f = float64(v) - } - if err != nil { - return msg, scratch, err - } - scratch = strconv.AppendFloat(scratch, f, 'f', -1, sz) - _, err = w.Write(scratch) - return msg, scratch, err -} - -func rwFloat32Bytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - var f float32 - var err error - f, msg, err = ReadFloat32Bytes(msg) - if err != nil { - return msg, scratch, err - } - scratch = strconv.AppendFloat(scratch[:0], float64(f), 'f', -1, 32) - _, err = w.Write(scratch) - return msg, scratch, err -} - -func rwFloat64Bytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - var f float64 - var err error - f, msg, err = ReadFloat64Bytes(msg) - if err != nil { - return msg, scratch, err - } - scratch = strconv.AppendFloat(scratch[:0], f, 'f', -1, 64) - _, err = w.Write(scratch) - return msg, scratch, err -} - -func rwTimeBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - var t time.Time - var err error - t, msg, err = ReadTimeBytes(msg) - if err != nil { - return msg, scratch, err - } - bts, err := t.MarshalJSON() - if err != nil { - return msg, scratch, err - } - _, err = w.Write(bts) - return msg, scratch, err -} - -func rwExtensionBytes(w jsWriter, msg []byte, scratch []byte) ([]byte, []byte, error) { - var err error - var et int8 - et, err = peekExtension(msg) - if err != nil { - return msg, scratch, err - } - - // if it's time.Time - if et == TimeExtension { - var tm time.Time - tm, msg, err = ReadTimeBytes(msg) - if err != nil { - return msg, scratch, err - } - bts, err := tm.MarshalJSON() - if err != nil { - return msg, scratch, err - } - _, err = w.Write(bts) - return msg, scratch, err - } - - // if the extension is registered, - // use its canonical JSON form - if f, ok := extensionReg[et]; ok { - e := f() - msg, err = ReadExtensionBytes(msg, e) - if err != nil { - return msg, scratch, err - } - bts, err := json.Marshal(e) - if err != nil { - return msg, scratch, err - } - _, err = w.Write(bts) - return msg, scratch, err - } - - // otherwise, write `{"type": , "data": ""}` - r := RawExtension{} - r.Type = et - msg, err = ReadExtensionBytes(msg, &r) - if err != nil { - return msg, scratch, err - } - scratch, err = writeExt(w, r, scratch) - return msg, scratch, err -} - -func writeExt(w jsWriter, r RawExtension, scratch []byte) ([]byte, error) { - _, err := w.WriteString(`{"type":`) - if err != nil { - return scratch, err - } - scratch = strconv.AppendInt(scratch[0:0], int64(r.Type), 10) - _, err = w.Write(scratch) - if err != nil { - return scratch, err - } - _, err = w.WriteString(`,"data":"`) - if err != nil { - return scratch, err - } - l := base64.StdEncoding.EncodedLen(len(r.Data)) - if cap(scratch) >= l { - scratch = scratch[0:l] - } else { - scratch = make([]byte, l) - } - base64.StdEncoding.Encode(scratch, r.Data) - _, err = w.Write(scratch) - if err != nil { - return scratch, err - } - _, err = w.WriteString(`"}`) - return scratch, err -} diff --git a/vendor/github.com/tinylib/msgp/msgp/json_bytes_test.go b/vendor/github.com/tinylib/msgp/msgp/json_bytes_test.go deleted file mode 100644 index 726974a..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/json_bytes_test.go +++ /dev/null @@ -1,121 +0,0 @@ -package msgp - -import ( - "bytes" - "encoding/json" - "testing" - "time" -) - -func TestUnmarshalJSON(t *testing.T) { - var buf bytes.Buffer - enc := NewWriter(&buf) - enc.WriteMapHeader(5) - - enc.WriteString("thing_1") - enc.WriteString("a string object") - - enc.WriteString("a_map") - enc.WriteMapHeader(2) - - // INNER - enc.WriteString("cmplx") - enc.WriteComplex64(complex(1.0, 1.0)) - enc.WriteString("int_b") - enc.WriteInt64(-100) - - enc.WriteString("an extension") - enc.WriteExtension(&RawExtension{Type: 1, Data: []byte("blaaahhh")}) - - enc.WriteString("some bytes") - enc.WriteBytes([]byte("here are some bytes")) - - enc.WriteString("now") - enc.WriteTime(time.Now()) - - enc.Flush() - - var js bytes.Buffer - _, err := UnmarshalAsJSON(&js, buf.Bytes()) - if err != nil { - t.Logf("%s", js.Bytes()) - t.Fatal(err) - } - mp := make(map[string]interface{}) - err = json.Unmarshal(js.Bytes(), &mp) - if err != nil { - t.Log(js.String()) - t.Fatalf("Error unmarshaling: %s", err) - } - - if len(mp) != 5 { - t.Errorf("map length should be %d, not %d", 5, len(mp)) - } - - so, ok := mp["thing_1"] - if !ok || so != "a string object" { - t.Errorf("expected %q; got %q", "a string object", so) - } - - if _, ok := mp["now"]; !ok { - t.Error(`"now" field doesn't exist`) - } - - c, ok := mp["a_map"] - if !ok { - t.Error(`"a_map" field doesn't exist`) - } else { - if m, ok := c.(map[string]interface{}); ok { - if _, ok := m["cmplx"]; !ok { - t.Error(`"a_map.cmplx" doesn't exist`) - } - } else { - t.Error(`can't type-assert "c" to map[string]interface{}`) - } - - } - - t.Logf("JSON: %s", js.Bytes()) -} - -func BenchmarkUnmarshalAsJSON(b *testing.B) { - var buf bytes.Buffer - enc := NewWriter(&buf) - enc.WriteMapHeader(4) - - enc.WriteString("thing_1") - enc.WriteString("a string object") - - enc.WriteString("a_first_map") - enc.WriteMapHeader(2) - enc.WriteString("float_a") - enc.WriteFloat32(1.0) - enc.WriteString("int_b") - enc.WriteInt64(-100) - - enc.WriteString("an array") - enc.WriteArrayHeader(2) - enc.WriteBool(true) - enc.WriteUint(2089) - - enc.WriteString("a_second_map") - enc.WriteMapStrStr(map[string]string{ - "internal_one": "blah", - "internal_two": "blahhh...", - }) - enc.Flush() - - var js bytes.Buffer - bts := buf.Bytes() - _, err := UnmarshalAsJSON(&js, bts) - if err != nil { - b.Fatal(err) - } - b.SetBytes(int64(len(js.Bytes()))) - b.ResetTimer() - b.ReportAllocs() - for i := 0; i < b.N; i++ { - js.Reset() - UnmarshalAsJSON(&js, bts) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/json_test.go b/vendor/github.com/tinylib/msgp/msgp/json_test.go deleted file mode 100644 index 439d479..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/json_test.go +++ /dev/null @@ -1,142 +0,0 @@ -package msgp - -import ( - "bytes" - "encoding/json" - "reflect" - "testing" -) - -func TestCopyJSON(t *testing.T) { - var buf bytes.Buffer - enc := NewWriter(&buf) - enc.WriteMapHeader(5) - - enc.WriteString("thing_1") - enc.WriteString("a string object") - - enc.WriteString("a_map") - enc.WriteMapHeader(2) - enc.WriteString("float_a") - enc.WriteFloat32(1.0) - enc.WriteString("int_b") - enc.WriteInt64(-100) - - enc.WriteString("some bytes") - enc.WriteBytes([]byte("here are some bytes")) - enc.WriteString("a bool") - enc.WriteBool(true) - - enc.WriteString("a map") - enc.WriteMapStrStr(map[string]string{ - "internal_one": "blah", - "internal_two": "blahhh...", - }) - enc.Flush() - - var js bytes.Buffer - _, err := CopyToJSON(&js, &buf) - if err != nil { - t.Fatal(err) - } - mp := make(map[string]interface{}) - err = json.Unmarshal(js.Bytes(), &mp) - if err != nil { - t.Log(js.String()) - t.Fatalf("Error unmarshaling: %s", err) - } - - if len(mp) != 5 { - t.Errorf("map length should be %d, not %d", 4, len(mp)) - } - - so, ok := mp["thing_1"] - if !ok || so != "a string object" { - t.Errorf("expected %q; got %q", "a string object", so) - } - - in, ok := mp["a map"] - if !ok { - t.Error("no key 'a map'") - } - if inm, ok := in.(map[string]interface{}); !ok { - t.Error("inner map not type-assertable to map[string]interface{}") - } else { - inm1, ok := inm["internal_one"] - if !ok || !reflect.DeepEqual(inm1, "blah") { - t.Errorf("inner map field %q should be %q, not %q", "internal_one", "blah", inm1) - } - } -} - -func BenchmarkCopyToJSON(b *testing.B) { - var buf bytes.Buffer - enc := NewWriter(&buf) - enc.WriteMapHeader(4) - - enc.WriteString("thing_1") - enc.WriteString("a string object") - - enc.WriteString("a_first_map") - enc.WriteMapHeader(2) - enc.WriteString("float_a") - enc.WriteFloat32(1.0) - enc.WriteString("int_b") - enc.WriteInt64(-100) - - enc.WriteString("an array") - enc.WriteArrayHeader(2) - enc.WriteBool(true) - enc.WriteUint(2089) - - enc.WriteString("a_second_map") - enc.WriteMapStrStr(map[string]string{ - "internal_one": "blah", - "internal_two": "blahhh...", - }) - enc.Flush() - - var js bytes.Buffer - bts := buf.Bytes() - _, err := CopyToJSON(&js, &buf) - if err != nil { - b.Fatal(err) - } - b.SetBytes(int64(len(js.Bytes()))) - b.ResetTimer() - b.ReportAllocs() - for i := 0; i < b.N; i++ { - js.Reset() - CopyToJSON(&js, bytes.NewReader(bts)) - } -} - -func BenchmarkStdlibJSON(b *testing.B) { - obj := map[string]interface{}{ - "thing_1": "a string object", - "a_first_map": map[string]interface{}{ - "float_a": float32(1.0), - "float_b": -100, - }, - "an array": []interface{}{ - "part_A", - "part_B", - }, - "a_second_map": map[string]interface{}{ - "internal_one": "blah", - "internal_two": "blahhh...", - }, - } - var js bytes.Buffer - err := json.NewEncoder(&js).Encode(&obj) - if err != nil { - b.Fatal(err) - } - b.SetBytes(int64(len(js.Bytes()))) - b.ResetTimer() - b.ReportAllocs() - for i := 0; i < b.N; i++ { - js.Reset() - json.NewEncoder(&js).Encode(&obj) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/number.go b/vendor/github.com/tinylib/msgp/msgp/number.go deleted file mode 100644 index ad07ef9..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/number.go +++ /dev/null @@ -1,267 +0,0 @@ -package msgp - -import ( - "math" - "strconv" -) - -// The portable parts of the Number implementation - -// Number can be -// an int64, uint64, float32, -// or float64 internally. -// It can decode itself -// from any of the native -// messagepack number types. -// The zero-value of Number -// is Int(0). Using the equality -// operator with Number compares -// both the type and the value -// of the number. -type Number struct { - // internally, this - // is just a tagged union. - // the raw bits of the number - // are stored the same way regardless. - bits uint64 - typ Type -} - -// AsInt sets the number to an int64. -func (n *Number) AsInt(i int64) { - - // we always store int(0) - // as {0, InvalidType} in - // order to preserve - // the behavior of the == operator - if i == 0 { - n.typ = InvalidType - n.bits = 0 - return - } - - n.typ = IntType - n.bits = uint64(i) -} - -// AsUint sets the number to a uint64. -func (n *Number) AsUint(u uint64) { - n.typ = UintType - n.bits = u -} - -// AsFloat32 sets the value of the number -// to a float32. -func (n *Number) AsFloat32(f float32) { - n.typ = Float32Type - n.bits = uint64(math.Float32bits(f)) -} - -// AsFloat64 sets the value of the -// number to a float64. -func (n *Number) AsFloat64(f float64) { - n.typ = Float64Type - n.bits = math.Float64bits(f) -} - -// Int casts the number as an int64, and -// returns whether or not that was the -// underlying type. -func (n *Number) Int() (int64, bool) { - return int64(n.bits), n.typ == IntType || n.typ == InvalidType -} - -// Uint casts the number as a uint64, and returns -// whether or not that was the underlying type. -func (n *Number) Uint() (uint64, bool) { - return n.bits, n.typ == UintType -} - -// Float casts the number to a float64, and -// returns whether or not that was the underlying -// type (either a float64 or a float32). -func (n *Number) Float() (float64, bool) { - switch n.typ { - case Float32Type: - return float64(math.Float32frombits(uint32(n.bits))), true - case Float64Type: - return math.Float64frombits(n.bits), true - default: - return 0.0, false - } -} - -// Type will return one of: -// Float64Type, Float32Type, UintType, or IntType. -func (n *Number) Type() Type { - if n.typ == InvalidType { - return IntType - } - return n.typ -} - -// DecodeMsg implements msgp.Decodable -func (n *Number) DecodeMsg(r *Reader) error { - typ, err := r.NextType() - if err != nil { - return err - } - switch typ { - case Float32Type: - f, err := r.ReadFloat32() - if err != nil { - return err - } - n.AsFloat32(f) - return nil - case Float64Type: - f, err := r.ReadFloat64() - if err != nil { - return err - } - n.AsFloat64(f) - return nil - case IntType: - i, err := r.ReadInt64() - if err != nil { - return err - } - n.AsInt(i) - return nil - case UintType: - u, err := r.ReadUint64() - if err != nil { - return err - } - n.AsUint(u) - return nil - default: - return TypeError{Encoded: typ, Method: IntType} - } -} - -// UnmarshalMsg implements msgp.Unmarshaler -func (n *Number) UnmarshalMsg(b []byte) ([]byte, error) { - typ := NextType(b) - switch typ { - case IntType: - i, o, err := ReadInt64Bytes(b) - if err != nil { - return b, err - } - n.AsInt(i) - return o, nil - case UintType: - u, o, err := ReadUint64Bytes(b) - if err != nil { - return b, err - } - n.AsUint(u) - return o, nil - case Float64Type: - f, o, err := ReadFloat64Bytes(b) - if err != nil { - return b, err - } - n.AsFloat64(f) - return o, nil - case Float32Type: - f, o, err := ReadFloat32Bytes(b) - if err != nil { - return b, err - } - n.AsFloat32(f) - return o, nil - default: - return b, TypeError{Method: IntType, Encoded: typ} - } -} - -// MarshalMsg implements msgp.Marshaler -func (n *Number) MarshalMsg(b []byte) ([]byte, error) { - switch n.typ { - case IntType: - return AppendInt64(b, int64(n.bits)), nil - case UintType: - return AppendUint64(b, uint64(n.bits)), nil - case Float64Type: - return AppendFloat64(b, math.Float64frombits(n.bits)), nil - case Float32Type: - return AppendFloat32(b, math.Float32frombits(uint32(n.bits))), nil - default: - return AppendInt64(b, 0), nil - } -} - -// EncodeMsg implements msgp.Encodable -func (n *Number) EncodeMsg(w *Writer) error { - switch n.typ { - case IntType: - return w.WriteInt64(int64(n.bits)) - case UintType: - return w.WriteUint64(n.bits) - case Float64Type: - return w.WriteFloat64(math.Float64frombits(n.bits)) - case Float32Type: - return w.WriteFloat32(math.Float32frombits(uint32(n.bits))) - default: - return w.WriteInt64(0) - } -} - -// Msgsize implements msgp.Sizer -func (n *Number) Msgsize() int { - switch n.typ { - case Float32Type: - return Float32Size - case Float64Type: - return Float64Size - case IntType: - return Int64Size - case UintType: - return Uint64Size - default: - return 1 // fixint(0) - } -} - -// MarshalJSON implements json.Marshaler -func (n *Number) MarshalJSON() ([]byte, error) { - t := n.Type() - if t == InvalidType { - return []byte{'0'}, nil - } - out := make([]byte, 0, 32) - switch t { - case Float32Type, Float64Type: - f, _ := n.Float() - return strconv.AppendFloat(out, f, 'f', -1, 64), nil - case IntType: - i, _ := n.Int() - return strconv.AppendInt(out, i, 10), nil - case UintType: - u, _ := n.Uint() - return strconv.AppendUint(out, u, 10), nil - default: - panic("(*Number).typ is invalid") - } -} - -// String implements fmt.Stringer -func (n *Number) String() string { - switch n.typ { - case InvalidType: - return "0" - case Float32Type, Float64Type: - f, _ := n.Float() - return strconv.FormatFloat(f, 'f', -1, 64) - case IntType: - i, _ := n.Int() - return strconv.FormatInt(i, 10) - case UintType: - u, _ := n.Uint() - return strconv.FormatUint(u, 10) - default: - panic("(*Number).typ is invalid") - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/number_test.go b/vendor/github.com/tinylib/msgp/msgp/number_test.go deleted file mode 100644 index 3490647..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/number_test.go +++ /dev/null @@ -1,94 +0,0 @@ -package msgp - -import ( - "bytes" - "testing" -) - -func TestNumber(t *testing.T) { - - n := Number{} - - if n.Type() != IntType { - t.Errorf("expected zero-value type to be %s; got %s", IntType, n.Type()) - } - - if n.String() != "0" { - t.Errorf("expected Number{}.String() to be \"0\" but got %q", n.String()) - } - - n.AsInt(248) - i, ok := n.Int() - if !ok || i != 248 || n.Type() != IntType || n.String() != "248" { - t.Errorf("%d in; %d out!", 248, i) - } - - n.AsFloat64(3.141) - f, ok := n.Float() - if !ok || f != 3.141 || n.Type() != Float64Type || n.String() != "3.141" { - t.Errorf("%f in; %f out!", 3.141, f) - } - - n.AsUint(40000) - u, ok := n.Uint() - if !ok || u != 40000 || n.Type() != UintType || n.String() != "40000" { - t.Errorf("%d in; %d out!", 40000, u) - } - - nums := []interface{}{ - float64(3.14159), - int64(-29081), - uint64(90821983), - float32(3.141), - } - - var dat []byte - var buf bytes.Buffer - wr := NewWriter(&buf) - for _, n := range nums { - dat, _ = AppendIntf(dat, n) - wr.WriteIntf(n) - } - wr.Flush() - - mout := make([]Number, len(nums)) - dout := make([]Number, len(nums)) - - rd := NewReader(&buf) - unm := dat - for i := range nums { - var err error - unm, err = mout[i].UnmarshalMsg(unm) - if err != nil { - t.Fatal("unmarshal error:", err) - } - err = dout[i].DecodeMsg(rd) - if err != nil { - t.Fatal("decode error:", err) - } - if mout[i] != dout[i] { - t.Errorf("for %#v, got %#v from unmarshal and %#v from decode", nums[i], mout[i], dout[i]) - } - } - - buf.Reset() - var odat []byte - for i := range nums { - var err error - odat, err = mout[i].MarshalMsg(odat) - if err != nil { - t.Fatal("marshal error:", err) - } - err = dout[i].EncodeMsg(wr) - } - wr.Flush() - - if !bytes.Equal(dat, odat) { - t.Errorf("marshal: expected output %#v; got %#v", dat, odat) - } - - if !bytes.Equal(dat, buf.Bytes()) { - t.Errorf("encode: expected output %#v; got %#v", dat, buf.Bytes()) - } - -} diff --git a/vendor/github.com/tinylib/msgp/msgp/raw_test.go b/vendor/github.com/tinylib/msgp/msgp/raw_test.go deleted file mode 100644 index 9f3321f..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/raw_test.go +++ /dev/null @@ -1,85 +0,0 @@ -package msgp - -import ( - "bytes" - "testing" - "time" -) - -// all standard interfaces -type allifaces interface { - Encodable - Decodable - Marshaler - Unmarshaler - Sizer -} - -func TestRaw(t *testing.T) { - bts := make([]byte, 0, 512) - bts = AppendMapHeader(bts, 3) - bts = AppendString(bts, "key_one") - bts = AppendFloat64(bts, -1.0) - bts = AppendString(bts, "key_two") - bts = AppendString(bts, "value_two") - bts = AppendString(bts, "key_three") - bts = AppendTime(bts, time.Now()) - - var r Raw - - // verify that Raw satisfies - // the interfaces we want it to - var _ allifaces = &r - - // READ TESTS - - extra, err := r.UnmarshalMsg(bts) - if err != nil { - t.Fatal("error from UnmarshalMsg:", err) - } - if len(extra) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(extra)) - } - if !bytes.Equal([]byte(r), bts) { - t.Fatal("value of raw and input slice are not equal after UnmarshalMsg") - } - - r = r[:0] - - var buf bytes.Buffer - buf.Write(bts) - - rd := NewReader(&buf) - - err = r.DecodeMsg(rd) - if err != nil { - t.Fatal("error from DecodeMsg:", err) - } - - if !bytes.Equal([]byte(r), bts) { - t.Fatal("value of raw and input slice are not equal after DecodeMsg") - } - - // WRITE TESTS - - buf.Reset() - wr := NewWriter(&buf) - err = r.EncodeMsg(wr) - if err != nil { - t.Fatal("error from EncodeMsg:", err) - } - - wr.Flush() - if !bytes.Equal(buf.Bytes(), bts) { - t.Fatal("value of buf.Bytes() and input slice are not equal after EncodeMsg") - } - - var outsl []byte - outsl, err = r.MarshalMsg(outsl) - if err != nil { - t.Fatal("error from MarshalMsg:", err) - } - if !bytes.Equal(outsl, bts) { - t.Fatal("value of output and input of MarshalMsg are not equal.") - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/read.go b/vendor/github.com/tinylib/msgp/msgp/read.go deleted file mode 100644 index 20cd1ef..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/read.go +++ /dev/null @@ -1,1265 +0,0 @@ -package msgp - -import ( - "io" - "math" - "sync" - "time" - - "github.com/philhofer/fwd" -) - -// where we keep old *Readers -var readerPool = sync.Pool{New: func() interface{} { return &Reader{} }} - -// Type is a MessagePack wire type, -// including this package's built-in -// extension types. -type Type byte - -// MessagePack Types -// -// The zero value of Type -// is InvalidType. -const ( - InvalidType Type = iota - - // MessagePack built-in types - - StrType - BinType - MapType - ArrayType - Float64Type - Float32Type - BoolType - IntType - UintType - NilType - ExtensionType - - // pseudo-types provided - // by extensions - - Complex64Type - Complex128Type - TimeType - - _maxtype -) - -// String implements fmt.Stringer -func (t Type) String() string { - switch t { - case StrType: - return "str" - case BinType: - return "bin" - case MapType: - return "map" - case ArrayType: - return "array" - case Float64Type: - return "float64" - case Float32Type: - return "float32" - case BoolType: - return "bool" - case UintType: - return "uint" - case IntType: - return "int" - case ExtensionType: - return "ext" - case NilType: - return "nil" - default: - return "" - } -} - -func freeR(m *Reader) { - readerPool.Put(m) -} - -// Unmarshaler is the interface fulfilled -// by objects that know how to unmarshal -// themselves from MessagePack. -// UnmarshalMsg unmarshals the object -// from binary, returing any leftover -// bytes and any errors encountered. -type Unmarshaler interface { - UnmarshalMsg([]byte) ([]byte, error) -} - -// Decodable is the interface fulfilled -// by objects that know how to read -// themselves from a *Reader. -type Decodable interface { - DecodeMsg(*Reader) error -} - -// Decode decodes 'd' from 'r'. -func Decode(r io.Reader, d Decodable) error { - rd := NewReader(r) - err := d.DecodeMsg(rd) - freeR(rd) - return err -} - -// NewReader returns a *Reader that -// reads from the provided reader. The -// reader will be buffered. -func NewReader(r io.Reader) *Reader { - p := readerPool.Get().(*Reader) - if p.R == nil { - p.R = fwd.NewReader(r) - } else { - p.R.Reset(r) - } - return p -} - -// NewReaderSize returns a *Reader with a buffer of the given size. -// (This is vastly preferable to passing the decoder a reader that is already buffered.) -func NewReaderSize(r io.Reader, sz int) *Reader { - return &Reader{R: fwd.NewReaderSize(r, sz)} -} - -// Reader wraps an io.Reader and provides -// methods to read MessagePack-encoded values -// from it. Readers are buffered. -type Reader struct { - // R is the buffered reader - // that the Reader uses - // to decode MessagePack. - // The Reader itself - // is stateless; all the - // buffering is done - // within R. - R *fwd.Reader - scratch []byte -} - -// Read implements `io.Reader` -func (m *Reader) Read(p []byte) (int, error) { - return m.R.Read(p) -} - -// CopyNext reads the next object from m without decoding it and writes it to w. -// It avoids unnecessary copies internally. -func (m *Reader) CopyNext(w io.Writer) (int64, error) { - sz, o, err := getNextSize(m.R) - if err != nil { - return 0, err - } - - var n int64 - // Opportunistic optimization: if we can fit the whole thing in the m.R - // buffer, then just get a pointer to that, and pass it to w.Write, - // avoiding an allocation. - if int(sz) <= m.R.BufferSize() { - var nn int - var buf []byte - buf, err = m.R.Next(int(sz)) - if err != nil { - if err == io.ErrUnexpectedEOF { - err = ErrShortBytes - } - return 0, err - } - nn, err = w.Write(buf) - n += int64(nn) - } else { - // Fall back to io.CopyN. - // May avoid allocating if w is a ReaderFrom (e.g. bytes.Buffer) - n, err = io.CopyN(w, m.R, int64(sz)) - if err == io.ErrUnexpectedEOF { - err = ErrShortBytes - } - } - if err != nil { - return n, err - } else if n < int64(sz) { - return n, io.ErrShortWrite - } - - // for maps and slices, read elements - for x := uintptr(0); x < o; x++ { - var n2 int64 - n2, err = m.CopyNext(w) - if err != nil { - return n, err - } - n += n2 - } - return n, nil -} - -// ReadFull implements `io.ReadFull` -func (m *Reader) ReadFull(p []byte) (int, error) { - return m.R.ReadFull(p) -} - -// Reset resets the underlying reader. -func (m *Reader) Reset(r io.Reader) { m.R.Reset(r) } - -// Buffered returns the number of bytes currently in the read buffer. -func (m *Reader) Buffered() int { return m.R.Buffered() } - -// BufferSize returns the capacity of the read buffer. -func (m *Reader) BufferSize() int { return m.R.BufferSize() } - -// NextType returns the next object type to be decoded. -func (m *Reader) NextType() (Type, error) { - p, err := m.R.Peek(1) - if err != nil { - return InvalidType, err - } - t := getType(p[0]) - if t == InvalidType { - return t, InvalidPrefixError(p[0]) - } - if t == ExtensionType { - v, err := m.peekExtensionType() - if err != nil { - return InvalidType, err - } - switch v { - case Complex64Extension: - return Complex64Type, nil - case Complex128Extension: - return Complex128Type, nil - case TimeExtension: - return TimeType, nil - } - } - return t, nil -} - -// IsNil returns whether or not -// the next byte is a null messagepack byte -func (m *Reader) IsNil() bool { - p, err := m.R.Peek(1) - return err == nil && p[0] == mnil -} - -// getNextSize returns the size of the next object on the wire. -// returns (obj size, obj elements, error) -// only maps and arrays have non-zero obj elements -// for maps and arrays, obj size does not include elements -// -// use uintptr b/c it's guaranteed to be large enough -// to hold whatever we can fit in memory. -func getNextSize(r *fwd.Reader) (uintptr, uintptr, error) { - b, err := r.Peek(1) - if err != nil { - return 0, 0, err - } - lead := b[0] - spec := &sizes[lead] - size, mode := spec.size, spec.extra - if size == 0 { - return 0, 0, InvalidPrefixError(lead) - } - if mode >= 0 { - return uintptr(size), uintptr(mode), nil - } - b, err = r.Peek(int(size)) - if err != nil { - return 0, 0, err - } - switch mode { - case extra8: - return uintptr(size) + uintptr(b[1]), 0, nil - case extra16: - return uintptr(size) + uintptr(big.Uint16(b[1:])), 0, nil - case extra32: - return uintptr(size) + uintptr(big.Uint32(b[1:])), 0, nil - case map16v: - return uintptr(size), 2 * uintptr(big.Uint16(b[1:])), nil - case map32v: - return uintptr(size), 2 * uintptr(big.Uint32(b[1:])), nil - case array16v: - return uintptr(size), uintptr(big.Uint16(b[1:])), nil - case array32v: - return uintptr(size), uintptr(big.Uint32(b[1:])), nil - default: - return 0, 0, fatal - } -} - -// Skip skips over the next object, regardless of -// its type. If it is an array or map, the whole array -// or map will be skipped. -func (m *Reader) Skip() error { - var ( - v uintptr // bytes - o uintptr // objects - err error - p []byte - ) - - // we can use the faster - // method if we have enough - // buffered data - if m.R.Buffered() >= 5 { - p, err = m.R.Peek(5) - if err != nil { - return err - } - v, o, err = getSize(p) - if err != nil { - return err - } - } else { - v, o, err = getNextSize(m.R) - if err != nil { - return err - } - } - - // 'v' is always non-zero - // if err == nil - _, err = m.R.Skip(int(v)) - if err != nil { - return err - } - - // for maps and slices, skip elements - for x := uintptr(0); x < o; x++ { - err = m.Skip() - if err != nil { - return err - } - } - return nil -} - -// ReadMapHeader reads the next object -// as a map header and returns the size -// of the map and the number of bytes written. -// It will return a TypeError{} if the next -// object is not a map. -func (m *Reader) ReadMapHeader() (sz uint32, err error) { - var p []byte - var lead byte - p, err = m.R.Peek(1) - if err != nil { - return - } - lead = p[0] - if isfixmap(lead) { - sz = uint32(rfixmap(lead)) - _, err = m.R.Skip(1) - return - } - switch lead { - case mmap16: - p, err = m.R.Next(3) - if err != nil { - return - } - sz = uint32(big.Uint16(p[1:])) - return - case mmap32: - p, err = m.R.Next(5) - if err != nil { - return - } - sz = big.Uint32(p[1:]) - return - default: - err = badPrefix(MapType, lead) - return - } -} - -// ReadMapKey reads either a 'str' or 'bin' field from -// the reader and returns the value as a []byte. It uses -// scratch for storage if it is large enough. -func (m *Reader) ReadMapKey(scratch []byte) ([]byte, error) { - out, err := m.ReadStringAsBytes(scratch) - if err != nil { - if tperr, ok := err.(TypeError); ok && tperr.Encoded == BinType { - return m.ReadBytes(scratch) - } - return nil, err - } - return out, nil -} - -// MapKeyPtr returns a []byte pointing to the contents -// of a valid map key. The key cannot be empty, and it -// must be shorter than the total buffer size of the -// *Reader. Additionally, the returned slice is only -// valid until the next *Reader method call. Users -// should exercise extreme care when using this -// method; writing into the returned slice may -// corrupt future reads. -func (m *Reader) ReadMapKeyPtr() ([]byte, error) { - p, err := m.R.Peek(1) - if err != nil { - return nil, err - } - lead := p[0] - var read int - if isfixstr(lead) { - read = int(rfixstr(lead)) - m.R.Skip(1) - goto fill - } - switch lead { - case mstr8, mbin8: - p, err = m.R.Next(2) - if err != nil { - return nil, err - } - read = int(p[1]) - case mstr16, mbin16: - p, err = m.R.Next(3) - if err != nil { - return nil, err - } - read = int(big.Uint16(p[1:])) - case mstr32, mbin32: - p, err = m.R.Next(5) - if err != nil { - return nil, err - } - read = int(big.Uint32(p[1:])) - default: - return nil, badPrefix(StrType, lead) - } -fill: - if read == 0 { - return nil, ErrShortBytes - } - return m.R.Next(read) -} - -// ReadArrayHeader reads the next object as an -// array header and returns the size of the array -// and the number of bytes read. -func (m *Reader) ReadArrayHeader() (sz uint32, err error) { - var lead byte - var p []byte - p, err = m.R.Peek(1) - if err != nil { - return - } - lead = p[0] - if isfixarray(lead) { - sz = uint32(rfixarray(lead)) - _, err = m.R.Skip(1) - return - } - switch lead { - case marray16: - p, err = m.R.Next(3) - if err != nil { - return - } - sz = uint32(big.Uint16(p[1:])) - return - - case marray32: - p, err = m.R.Next(5) - if err != nil { - return - } - sz = big.Uint32(p[1:]) - return - - default: - err = badPrefix(ArrayType, lead) - return - } -} - -// ReadNil reads a 'nil' MessagePack byte from the reader -func (m *Reader) ReadNil() error { - p, err := m.R.Peek(1) - if err != nil { - return err - } - if p[0] != mnil { - return badPrefix(NilType, p[0]) - } - _, err = m.R.Skip(1) - return err -} - -// ReadFloat64 reads a float64 from the reader. -// (If the value on the wire is encoded as a float32, -// it will be up-cast to a float64.) -func (m *Reader) ReadFloat64() (f float64, err error) { - var p []byte - p, err = m.R.Peek(9) - if err != nil { - // we'll allow a coversion from float32 to float64, - // since we don't lose any precision - if err == io.EOF && len(p) > 0 && p[0] == mfloat32 { - ef, err := m.ReadFloat32() - return float64(ef), err - } - return - } - if p[0] != mfloat64 { - // see above - if p[0] == mfloat32 { - ef, err := m.ReadFloat32() - return float64(ef), err - } - err = badPrefix(Float64Type, p[0]) - return - } - f = math.Float64frombits(getMuint64(p)) - _, err = m.R.Skip(9) - return -} - -// ReadFloat32 reads a float32 from the reader -func (m *Reader) ReadFloat32() (f float32, err error) { - var p []byte - p, err = m.R.Peek(5) - if err != nil { - return - } - if p[0] != mfloat32 { - err = badPrefix(Float32Type, p[0]) - return - } - f = math.Float32frombits(getMuint32(p)) - _, err = m.R.Skip(5) - return -} - -// ReadBool reads a bool from the reader -func (m *Reader) ReadBool() (b bool, err error) { - var p []byte - p, err = m.R.Peek(1) - if err != nil { - return - } - switch p[0] { - case mtrue: - b = true - case mfalse: - default: - err = badPrefix(BoolType, p[0]) - return - } - _, err = m.R.Skip(1) - return -} - -// ReadInt64 reads an int64 from the reader -func (m *Reader) ReadInt64() (i int64, err error) { - var p []byte - var lead byte - p, err = m.R.Peek(1) - if err != nil { - return - } - lead = p[0] - - if isfixint(lead) { - i = int64(rfixint(lead)) - _, err = m.R.Skip(1) - return - } else if isnfixint(lead) { - i = int64(rnfixint(lead)) - _, err = m.R.Skip(1) - return - } - - switch lead { - case mint8: - p, err = m.R.Next(2) - if err != nil { - return - } - i = int64(getMint8(p)) - return - - case mint16: - p, err = m.R.Next(3) - if err != nil { - return - } - i = int64(getMint16(p)) - return - - case mint32: - p, err = m.R.Next(5) - if err != nil { - return - } - i = int64(getMint32(p)) - return - - case mint64: - p, err = m.R.Next(9) - if err != nil { - return - } - i = getMint64(p) - return - - default: - err = badPrefix(IntType, lead) - return - } -} - -// ReadInt32 reads an int32 from the reader -func (m *Reader) ReadInt32() (i int32, err error) { - var in int64 - in, err = m.ReadInt64() - if in > math.MaxInt32 || in < math.MinInt32 { - err = IntOverflow{Value: in, FailedBitsize: 32} - return - } - i = int32(in) - return -} - -// ReadInt16 reads an int16 from the reader -func (m *Reader) ReadInt16() (i int16, err error) { - var in int64 - in, err = m.ReadInt64() - if in > math.MaxInt16 || in < math.MinInt16 { - err = IntOverflow{Value: in, FailedBitsize: 16} - return - } - i = int16(in) - return -} - -// ReadInt8 reads an int8 from the reader -func (m *Reader) ReadInt8() (i int8, err error) { - var in int64 - in, err = m.ReadInt64() - if in > math.MaxInt8 || in < math.MinInt8 { - err = IntOverflow{Value: in, FailedBitsize: 8} - return - } - i = int8(in) - return -} - -// ReadInt reads an int from the reader -func (m *Reader) ReadInt() (i int, err error) { - if smallint { - var in int32 - in, err = m.ReadInt32() - i = int(in) - return - } - var in int64 - in, err = m.ReadInt64() - i = int(in) - return -} - -// ReadUint64 reads a uint64 from the reader -func (m *Reader) ReadUint64() (u uint64, err error) { - var p []byte - var lead byte - p, err = m.R.Peek(1) - if err != nil { - return - } - lead = p[0] - if isfixint(lead) { - u = uint64(rfixint(lead)) - _, err = m.R.Skip(1) - return - } - switch lead { - case muint8: - p, err = m.R.Next(2) - if err != nil { - return - } - u = uint64(getMuint8(p)) - return - - case muint16: - p, err = m.R.Next(3) - if err != nil { - return - } - u = uint64(getMuint16(p)) - return - - case muint32: - p, err = m.R.Next(5) - if err != nil { - return - } - u = uint64(getMuint32(p)) - return - - case muint64: - p, err = m.R.Next(9) - if err != nil { - return - } - u = getMuint64(p) - return - - default: - err = badPrefix(UintType, lead) - return - - } -} - -// ReadUint32 reads a uint32 from the reader -func (m *Reader) ReadUint32() (u uint32, err error) { - var in uint64 - in, err = m.ReadUint64() - if in > math.MaxUint32 { - err = UintOverflow{Value: in, FailedBitsize: 32} - return - } - u = uint32(in) - return -} - -// ReadUint16 reads a uint16 from the reader -func (m *Reader) ReadUint16() (u uint16, err error) { - var in uint64 - in, err = m.ReadUint64() - if in > math.MaxUint16 { - err = UintOverflow{Value: in, FailedBitsize: 16} - return - } - u = uint16(in) - return -} - -// ReadUint8 reads a uint8 from the reader -func (m *Reader) ReadUint8() (u uint8, err error) { - var in uint64 - in, err = m.ReadUint64() - if in > math.MaxUint8 { - err = UintOverflow{Value: in, FailedBitsize: 8} - return - } - u = uint8(in) - return -} - -// ReadUint reads a uint from the reader -func (m *Reader) ReadUint() (u uint, err error) { - if smallint { - var un uint32 - un, err = m.ReadUint32() - u = uint(un) - return - } - var un uint64 - un, err = m.ReadUint64() - u = uint(un) - return -} - -// ReadByte is analogous to ReadUint8. -// -// NOTE: this is *not* an implementation -// of io.ByteReader. -func (m *Reader) ReadByte() (b byte, err error) { - var in uint64 - in, err = m.ReadUint64() - if in > math.MaxUint8 { - err = UintOverflow{Value: in, FailedBitsize: 8} - return - } - b = byte(in) - return -} - -// ReadBytes reads a MessagePack 'bin' object -// from the reader and returns its value. It may -// use 'scratch' for storage if it is non-nil. -func (m *Reader) ReadBytes(scratch []byte) (b []byte, err error) { - var p []byte - var lead byte - p, err = m.R.Peek(2) - if err != nil { - return - } - lead = p[0] - var read int64 - switch lead { - case mbin8: - read = int64(p[1]) - m.R.Skip(2) - case mbin16: - p, err = m.R.Next(3) - if err != nil { - return - } - read = int64(big.Uint16(p[1:])) - case mbin32: - p, err = m.R.Next(5) - if err != nil { - return - } - read = int64(big.Uint32(p[1:])) - default: - err = badPrefix(BinType, lead) - return - } - if int64(cap(scratch)) < read { - b = make([]byte, read) - } else { - b = scratch[0:read] - } - _, err = m.R.ReadFull(b) - return -} - -// ReadBytesHeader reads the size header -// of a MessagePack 'bin' object. The user -// is responsible for dealing with the next -// 'sz' bytes from the reader in an application-specific -// way. -func (m *Reader) ReadBytesHeader() (sz uint32, err error) { - var p []byte - p, err = m.R.Peek(1) - if err != nil { - return - } - switch p[0] { - case mbin8: - p, err = m.R.Next(2) - if err != nil { - return - } - sz = uint32(p[1]) - return - case mbin16: - p, err = m.R.Next(3) - if err != nil { - return - } - sz = uint32(big.Uint16(p[1:])) - return - case mbin32: - p, err = m.R.Next(5) - if err != nil { - return - } - sz = uint32(big.Uint32(p[1:])) - return - default: - err = badPrefix(BinType, p[0]) - return - } -} - -// ReadExactBytes reads a MessagePack 'bin'-encoded -// object off of the wire into the provided slice. An -// ArrayError will be returned if the object is not -// exactly the length of the input slice. -func (m *Reader) ReadExactBytes(into []byte) error { - p, err := m.R.Peek(2) - if err != nil { - return err - } - lead := p[0] - var read int64 // bytes to read - var skip int // prefix size to skip - switch lead { - case mbin8: - read = int64(p[1]) - skip = 2 - case mbin16: - p, err = m.R.Peek(3) - if err != nil { - return err - } - read = int64(big.Uint16(p[1:])) - skip = 3 - case mbin32: - p, err = m.R.Peek(5) - if err != nil { - return err - } - read = int64(big.Uint32(p[1:])) - skip = 5 - default: - return badPrefix(BinType, lead) - } - if read != int64(len(into)) { - return ArrayError{Wanted: uint32(len(into)), Got: uint32(read)} - } - m.R.Skip(skip) - _, err = m.R.ReadFull(into) - return err -} - -// ReadStringAsBytes reads a MessagePack 'str' (utf-8) string -// and returns its value as bytes. It may use 'scratch' for storage -// if it is non-nil. -func (m *Reader) ReadStringAsBytes(scratch []byte) (b []byte, err error) { - var p []byte - var lead byte - p, err = m.R.Peek(1) - if err != nil { - return - } - lead = p[0] - var read int64 - - if isfixstr(lead) { - read = int64(rfixstr(lead)) - m.R.Skip(1) - goto fill - } - - switch lead { - case mstr8: - p, err = m.R.Next(2) - if err != nil { - return - } - read = int64(uint8(p[1])) - case mstr16: - p, err = m.R.Next(3) - if err != nil { - return - } - read = int64(big.Uint16(p[1:])) - case mstr32: - p, err = m.R.Next(5) - if err != nil { - return - } - read = int64(big.Uint32(p[1:])) - default: - err = badPrefix(StrType, lead) - return - } -fill: - if int64(cap(scratch)) < read { - b = make([]byte, read) - } else { - b = scratch[0:read] - } - _, err = m.R.ReadFull(b) - return -} - -// ReadStringHeader reads a string header -// off of the wire. The user is then responsible -// for dealing with the next 'sz' bytes from -// the reader in an application-specific manner. -func (m *Reader) ReadStringHeader() (sz uint32, err error) { - var p []byte - p, err = m.R.Peek(1) - if err != nil { - return - } - lead := p[0] - if isfixstr(lead) { - sz = uint32(rfixstr(lead)) - m.R.Skip(1) - return - } - switch lead { - case mstr8: - p, err = m.R.Next(2) - if err != nil { - return - } - sz = uint32(p[1]) - return - case mstr16: - p, err = m.R.Next(3) - if err != nil { - return - } - sz = uint32(big.Uint16(p[1:])) - return - case mstr32: - p, err = m.R.Next(5) - if err != nil { - return - } - sz = big.Uint32(p[1:]) - return - default: - err = badPrefix(StrType, lead) - return - } -} - -// ReadString reads a utf-8 string from the reader -func (m *Reader) ReadString() (s string, err error) { - var p []byte - var lead byte - var read int64 - p, err = m.R.Peek(1) - if err != nil { - return - } - lead = p[0] - - if isfixstr(lead) { - read = int64(rfixstr(lead)) - m.R.Skip(1) - goto fill - } - - switch lead { - case mstr8: - p, err = m.R.Next(2) - if err != nil { - return - } - read = int64(uint8(p[1])) - case mstr16: - p, err = m.R.Next(3) - if err != nil { - return - } - read = int64(big.Uint16(p[1:])) - case mstr32: - p, err = m.R.Next(5) - if err != nil { - return - } - read = int64(big.Uint32(p[1:])) - default: - err = badPrefix(StrType, lead) - return - } -fill: - if read == 0 { - s, err = "", nil - return - } - // reading into the memory - // that will become the string - // itself has vastly superior - // worst-case performance, because - // the reader buffer doesn't have - // to be large enough to hold the string. - // the idea here is to make it more - // difficult for someone malicious - // to cause the system to run out of - // memory by sending very large strings. - // - // NOTE: this works because the argument - // passed to (*fwd.Reader).ReadFull escapes - // to the heap; its argument may, in turn, - // be passed to the underlying reader, and - // thus escape analysis *must* conclude that - // 'out' escapes. - out := make([]byte, read) - _, err = m.R.ReadFull(out) - if err != nil { - return - } - s = UnsafeString(out) - return -} - -// ReadComplex64 reads a complex64 from the reader -func (m *Reader) ReadComplex64() (f complex64, err error) { - var p []byte - p, err = m.R.Peek(10) - if err != nil { - return - } - if p[0] != mfixext8 { - err = badPrefix(Complex64Type, p[0]) - return - } - if int8(p[1]) != Complex64Extension { - err = errExt(int8(p[1]), Complex64Extension) - return - } - f = complex(math.Float32frombits(big.Uint32(p[2:])), - math.Float32frombits(big.Uint32(p[6:]))) - _, err = m.R.Skip(10) - return -} - -// ReadComplex128 reads a complex128 from the reader -func (m *Reader) ReadComplex128() (f complex128, err error) { - var p []byte - p, err = m.R.Peek(18) - if err != nil { - return - } - if p[0] != mfixext16 { - err = badPrefix(Complex128Type, p[0]) - return - } - if int8(p[1]) != Complex128Extension { - err = errExt(int8(p[1]), Complex128Extension) - return - } - f = complex(math.Float64frombits(big.Uint64(p[2:])), - math.Float64frombits(big.Uint64(p[10:]))) - _, err = m.R.Skip(18) - return -} - -// ReadMapStrIntf reads a MessagePack map into a map[string]interface{}. -// (You must pass a non-nil map into the function.) -func (m *Reader) ReadMapStrIntf(mp map[string]interface{}) (err error) { - var sz uint32 - sz, err = m.ReadMapHeader() - if err != nil { - return - } - for key := range mp { - delete(mp, key) - } - for i := uint32(0); i < sz; i++ { - var key string - var val interface{} - key, err = m.ReadString() - if err != nil { - return - } - val, err = m.ReadIntf() - if err != nil { - return - } - mp[key] = val - } - return -} - -// ReadTime reads a time.Time object from the reader. -// The returned time's location will be set to time.Local. -func (m *Reader) ReadTime() (t time.Time, err error) { - var p []byte - p, err = m.R.Peek(15) - if err != nil { - return - } - if p[0] != mext8 || p[1] != 12 { - err = badPrefix(TimeType, p[0]) - return - } - if int8(p[2]) != TimeExtension { - err = errExt(int8(p[2]), TimeExtension) - return - } - sec, nsec := getUnix(p[3:]) - t = time.Unix(sec, int64(nsec)).Local() - _, err = m.R.Skip(15) - return -} - -// ReadIntf reads out the next object as a raw interface{}. -// Arrays are decoded as []interface{}, and maps are decoded -// as map[string]interface{}. Integers are decoded as int64 -// and unsigned integers are decoded as uint64. -func (m *Reader) ReadIntf() (i interface{}, err error) { - var t Type - t, err = m.NextType() - if err != nil { - return - } - switch t { - case BoolType: - i, err = m.ReadBool() - return - - case IntType: - i, err = m.ReadInt64() - return - - case UintType: - i, err = m.ReadUint64() - return - - case BinType: - i, err = m.ReadBytes(nil) - return - - case StrType: - i, err = m.ReadString() - return - - case Complex64Type: - i, err = m.ReadComplex64() - return - - case Complex128Type: - i, err = m.ReadComplex128() - return - - case TimeType: - i, err = m.ReadTime() - return - - case ExtensionType: - var t int8 - t, err = m.peekExtensionType() - if err != nil { - return - } - f, ok := extensionReg[t] - if ok { - e := f() - err = m.ReadExtension(e) - i = e - return - } - var e RawExtension - e.Type = t - err = m.ReadExtension(&e) - i = &e - return - - case MapType: - mp := make(map[string]interface{}) - err = m.ReadMapStrIntf(mp) - i = mp - return - - case NilType: - err = m.ReadNil() - i = nil - return - - case Float32Type: - i, err = m.ReadFloat32() - return - - case Float64Type: - i, err = m.ReadFloat64() - return - - case ArrayType: - var sz uint32 - sz, err = m.ReadArrayHeader() - - if err != nil { - return - } - out := make([]interface{}, int(sz)) - for j := range out { - out[j], err = m.ReadIntf() - if err != nil { - return - } - } - i = out - return - - default: - return nil, fatal // unreachable - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/read_bytes.go b/vendor/github.com/tinylib/msgp/msgp/read_bytes.go deleted file mode 100644 index 78e466f..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/read_bytes.go +++ /dev/null @@ -1,1089 +0,0 @@ -package msgp - -import ( - "bytes" - "encoding/binary" - "math" - "time" -) - -var big = binary.BigEndian - -// NextType returns the type of the next -// object in the slice. If the length -// of the input is zero, it returns -// InvalidType. -func NextType(b []byte) Type { - if len(b) == 0 { - return InvalidType - } - spec := sizes[b[0]] - t := spec.typ - if t == ExtensionType && len(b) > int(spec.size) { - var tp int8 - if spec.extra == constsize { - tp = int8(b[1]) - } else { - tp = int8(b[spec.size-1]) - } - switch tp { - case TimeExtension: - return TimeType - case Complex128Extension: - return Complex128Type - case Complex64Extension: - return Complex64Type - default: - return ExtensionType - } - } - return t -} - -// IsNil returns true if len(b)>0 and -// the leading byte is a 'nil' MessagePack -// byte; false otherwise -func IsNil(b []byte) bool { - if len(b) != 0 && b[0] == mnil { - return true - } - return false -} - -// Raw is raw MessagePack. -// Raw allows you to read and write -// data without interpreting its contents. -type Raw []byte - -// MarshalMsg implements msgp.Marshaler. -// It appends the raw contents of 'raw' -// to the provided byte slice. If 'raw' -// is 0 bytes, 'nil' will be appended instead. -func (r Raw) MarshalMsg(b []byte) ([]byte, error) { - i := len(r) - if i == 0 { - return AppendNil(b), nil - } - o, l := ensure(b, i) - copy(o[l:], []byte(r)) - return o, nil -} - -// UnmarshalMsg implements msgp.Unmarshaler. -// It sets the contents of *Raw to be the next -// object in the provided byte slice. -func (r *Raw) UnmarshalMsg(b []byte) ([]byte, error) { - l := len(b) - out, err := Skip(b) - if err != nil { - return b, err - } - rlen := l - len(out) - if cap(*r) < rlen { - *r = make(Raw, rlen) - } else { - *r = (*r)[0:rlen] - } - copy(*r, b[:rlen]) - return out, nil -} - -// EncodeMsg implements msgp.Encodable. -// It writes the raw bytes to the writer. -// If r is empty, it writes 'nil' instead. -func (r Raw) EncodeMsg(w *Writer) error { - if len(r) == 0 { - return w.WriteNil() - } - _, err := w.Write([]byte(r)) - return err -} - -// DecodeMsg implements msgp.Decodable. -// It sets the value of *Raw to be the -// next object on the wire. -func (r *Raw) DecodeMsg(f *Reader) error { - *r = (*r)[:0] - return appendNext(f, (*[]byte)(r)) -} - -// Msgsize implements msgp.Sizer -func (r Raw) Msgsize() int { - l := len(r) - if l == 0 { - return 1 // for 'nil' - } - return l -} - -func appendNext(f *Reader, d *[]byte) error { - amt, o, err := getNextSize(f.R) - if err != nil { - return err - } - var i int - *d, i = ensure(*d, int(amt)) - _, err = f.R.ReadFull((*d)[i:]) - if err != nil { - return err - } - for o > 0 { - err = appendNext(f, d) - if err != nil { - return err - } - o-- - } - return nil -} - -// MarshalJSON implements json.Marshaler -func (r *Raw) MarshalJSON() ([]byte, error) { - var buf bytes.Buffer - _, err := UnmarshalAsJSON(&buf, []byte(*r)) - return buf.Bytes(), err -} - -// ReadMapHeaderBytes reads a map header size -// from 'b' and returns the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a map) -func ReadMapHeaderBytes(b []byte) (sz uint32, o []byte, err error) { - l := len(b) - if l < 1 { - err = ErrShortBytes - return - } - - lead := b[0] - if isfixmap(lead) { - sz = uint32(rfixmap(lead)) - o = b[1:] - return - } - - switch lead { - case mmap16: - if l < 3 { - err = ErrShortBytes - return - } - sz = uint32(big.Uint16(b[1:])) - o = b[3:] - return - - case mmap32: - if l < 5 { - err = ErrShortBytes - return - } - sz = big.Uint32(b[1:]) - o = b[5:] - return - - default: - err = badPrefix(MapType, lead) - return - } -} - -// ReadMapKeyZC attempts to read a map key -// from 'b' and returns the key bytes and the remaining bytes -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a str or bin) -func ReadMapKeyZC(b []byte) ([]byte, []byte, error) { - o, b, err := ReadStringZC(b) - if err != nil { - if tperr, ok := err.(TypeError); ok && tperr.Encoded == BinType { - return ReadBytesZC(b) - } - return nil, b, err - } - return o, b, nil -} - -// ReadArrayHeaderBytes attempts to read -// the array header size off of 'b' and return -// the size and remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not an array) -func ReadArrayHeaderBytes(b []byte) (sz uint32, o []byte, err error) { - if len(b) < 1 { - return 0, nil, ErrShortBytes - } - lead := b[0] - if isfixarray(lead) { - sz = uint32(rfixarray(lead)) - o = b[1:] - return - } - - switch lead { - case marray16: - if len(b) < 3 { - err = ErrShortBytes - return - } - sz = uint32(big.Uint16(b[1:])) - o = b[3:] - return - - case marray32: - if len(b) < 5 { - err = ErrShortBytes - return - } - sz = big.Uint32(b[1:]) - o = b[5:] - return - - default: - err = badPrefix(ArrayType, lead) - return - } -} - -// ReadNilBytes tries to read a "nil" byte -// off of 'b' and return the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a 'nil') -// - InvalidPrefixError -func ReadNilBytes(b []byte) ([]byte, error) { - if len(b) < 1 { - return nil, ErrShortBytes - } - if b[0] != mnil { - return b, badPrefix(NilType, b[0]) - } - return b[1:], nil -} - -// ReadFloat64Bytes tries to read a float64 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a float64) -func ReadFloat64Bytes(b []byte) (f float64, o []byte, err error) { - if len(b) < 9 { - if len(b) >= 5 && b[0] == mfloat32 { - var tf float32 - tf, o, err = ReadFloat32Bytes(b) - f = float64(tf) - return - } - err = ErrShortBytes - return - } - - if b[0] != mfloat64 { - if b[0] == mfloat32 { - var tf float32 - tf, o, err = ReadFloat32Bytes(b) - f = float64(tf) - return - } - err = badPrefix(Float64Type, b[0]) - return - } - - f = math.Float64frombits(getMuint64(b)) - o = b[9:] - return -} - -// ReadFloat32Bytes tries to read a float64 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a float32) -func ReadFloat32Bytes(b []byte) (f float32, o []byte, err error) { - if len(b) < 5 { - err = ErrShortBytes - return - } - - if b[0] != mfloat32 { - err = TypeError{Method: Float32Type, Encoded: getType(b[0])} - return - } - - f = math.Float32frombits(getMuint32(b)) - o = b[5:] - return -} - -// ReadBoolBytes tries to read a float64 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a bool) -func ReadBoolBytes(b []byte) (bool, []byte, error) { - if len(b) < 1 { - return false, b, ErrShortBytes - } - switch b[0] { - case mtrue: - return true, b[1:], nil - case mfalse: - return false, b[1:], nil - default: - return false, b, badPrefix(BoolType, b[0]) - } -} - -// ReadInt64Bytes tries to read an int64 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError (not a int) -func ReadInt64Bytes(b []byte) (i int64, o []byte, err error) { - l := len(b) - if l < 1 { - return 0, nil, ErrShortBytes - } - - lead := b[0] - if isfixint(lead) { - i = int64(rfixint(lead)) - o = b[1:] - return - } - if isnfixint(lead) { - i = int64(rnfixint(lead)) - o = b[1:] - return - } - - switch lead { - case mint8: - if l < 2 { - err = ErrShortBytes - return - } - i = int64(getMint8(b)) - o = b[2:] - return - - case mint16: - if l < 3 { - err = ErrShortBytes - return - } - i = int64(getMint16(b)) - o = b[3:] - return - - case mint32: - if l < 5 { - err = ErrShortBytes - return - } - i = int64(getMint32(b)) - o = b[5:] - return - - case mint64: - if l < 9 { - err = ErrShortBytes - return - } - i = getMint64(b) - o = b[9:] - return - - default: - err = badPrefix(IntType, lead) - return - } -} - -// ReadInt32Bytes tries to read an int32 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a int) -// - IntOverflow{} (value doesn't fit in int32) -func ReadInt32Bytes(b []byte) (int32, []byte, error) { - i, o, err := ReadInt64Bytes(b) - if i > math.MaxInt32 || i < math.MinInt32 { - return 0, o, IntOverflow{Value: i, FailedBitsize: 32} - } - return int32(i), o, err -} - -// ReadInt16Bytes tries to read an int16 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a int) -// - IntOverflow{} (value doesn't fit in int16) -func ReadInt16Bytes(b []byte) (int16, []byte, error) { - i, o, err := ReadInt64Bytes(b) - if i > math.MaxInt16 || i < math.MinInt16 { - return 0, o, IntOverflow{Value: i, FailedBitsize: 16} - } - return int16(i), o, err -} - -// ReadInt8Bytes tries to read an int16 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a int) -// - IntOverflow{} (value doesn't fit in int8) -func ReadInt8Bytes(b []byte) (int8, []byte, error) { - i, o, err := ReadInt64Bytes(b) - if i > math.MaxInt8 || i < math.MinInt8 { - return 0, o, IntOverflow{Value: i, FailedBitsize: 8} - } - return int8(i), o, err -} - -// ReadIntBytes tries to read an int -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a int) -// - IntOverflow{} (value doesn't fit in int; 32-bit platforms only) -func ReadIntBytes(b []byte) (int, []byte, error) { - if smallint { - i, b, err := ReadInt32Bytes(b) - return int(i), b, err - } - i, b, err := ReadInt64Bytes(b) - return int(i), b, err -} - -// ReadUint64Bytes tries to read a uint64 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a uint) -func ReadUint64Bytes(b []byte) (u uint64, o []byte, err error) { - l := len(b) - if l < 1 { - return 0, nil, ErrShortBytes - } - - lead := b[0] - if isfixint(lead) { - u = uint64(rfixint(lead)) - o = b[1:] - return - } - - switch lead { - case muint8: - if l < 2 { - err = ErrShortBytes - return - } - u = uint64(getMuint8(b)) - o = b[2:] - return - - case muint16: - if l < 3 { - err = ErrShortBytes - return - } - u = uint64(getMuint16(b)) - o = b[3:] - return - - case muint32: - if l < 5 { - err = ErrShortBytes - return - } - u = uint64(getMuint32(b)) - o = b[5:] - return - - case muint64: - if l < 9 { - err = ErrShortBytes - return - } - u = getMuint64(b) - o = b[9:] - return - - default: - err = badPrefix(UintType, lead) - return - } -} - -// ReadUint32Bytes tries to read a uint32 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a uint) -// - UintOverflow{} (value too large for uint32) -func ReadUint32Bytes(b []byte) (uint32, []byte, error) { - v, o, err := ReadUint64Bytes(b) - if v > math.MaxUint32 { - return 0, nil, UintOverflow{Value: v, FailedBitsize: 32} - } - return uint32(v), o, err -} - -// ReadUint16Bytes tries to read a uint16 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a uint) -// - UintOverflow{} (value too large for uint16) -func ReadUint16Bytes(b []byte) (uint16, []byte, error) { - v, o, err := ReadUint64Bytes(b) - if v > math.MaxUint16 { - return 0, nil, UintOverflow{Value: v, FailedBitsize: 16} - } - return uint16(v), o, err -} - -// ReadUint8Bytes tries to read a uint8 -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a uint) -// - UintOverflow{} (value too large for uint8) -func ReadUint8Bytes(b []byte) (uint8, []byte, error) { - v, o, err := ReadUint64Bytes(b) - if v > math.MaxUint8 { - return 0, nil, UintOverflow{Value: v, FailedBitsize: 8} - } - return uint8(v), o, err -} - -// ReadUintBytes tries to read a uint -// from 'b' and return the value and the remaining bytes. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a uint) -// - UintOverflow{} (value too large for uint; 32-bit platforms only) -func ReadUintBytes(b []byte) (uint, []byte, error) { - if smallint { - u, b, err := ReadUint32Bytes(b) - return uint(u), b, err - } - u, b, err := ReadUint64Bytes(b) - return uint(u), b, err -} - -// ReadByteBytes is analogous to ReadUint8Bytes -func ReadByteBytes(b []byte) (byte, []byte, error) { - return ReadUint8Bytes(b) -} - -// ReadBytesBytes reads a 'bin' object -// from 'b' and returns its vaue and -// the remaining bytes in 'b'. -// Possible errors: -// - ErrShortBytes (too few bytes) -// - TypeError{} (not a 'bin' object) -func ReadBytesBytes(b []byte, scratch []byte) (v []byte, o []byte, err error) { - return readBytesBytes(b, scratch, false) -} - -func readBytesBytes(b []byte, scratch []byte, zc bool) (v []byte, o []byte, err error) { - l := len(b) - if l < 1 { - return nil, nil, ErrShortBytes - } - - lead := b[0] - var read int - switch lead { - case mbin8: - if l < 2 { - err = ErrShortBytes - return - } - - read = int(b[1]) - b = b[2:] - - case mbin16: - if l < 3 { - err = ErrShortBytes - return - } - read = int(big.Uint16(b[1:])) - b = b[3:] - - case mbin32: - if l < 5 { - err = ErrShortBytes - return - } - read = int(big.Uint32(b[1:])) - b = b[5:] - - default: - err = badPrefix(BinType, lead) - return - } - - if len(b) < read { - err = ErrShortBytes - return - } - - // zero-copy - if zc { - v = b[0:read] - o = b[read:] - return - } - - if cap(scratch) >= read { - v = scratch[0:read] - } else { - v = make([]byte, read) - } - - o = b[copy(v, b):] - return -} - -// ReadBytesZC extracts the messagepack-encoded -// binary field without copying. The returned []byte -// points to the same memory as the input slice. -// Possible errors: -// - ErrShortBytes (b not long enough) -// - TypeError{} (object not 'bin') -func ReadBytesZC(b []byte) (v []byte, o []byte, err error) { - return readBytesBytes(b, nil, true) -} - -func ReadExactBytes(b []byte, into []byte) (o []byte, err error) { - l := len(b) - if l < 1 { - err = ErrShortBytes - return - } - - lead := b[0] - var read uint32 - var skip int - switch lead { - case mbin8: - if l < 2 { - err = ErrShortBytes - return - } - - read = uint32(b[1]) - skip = 2 - - case mbin16: - if l < 3 { - err = ErrShortBytes - return - } - read = uint32(big.Uint16(b[1:])) - skip = 3 - - case mbin32: - if l < 5 { - err = ErrShortBytes - return - } - read = uint32(big.Uint32(b[1:])) - skip = 5 - - default: - err = badPrefix(BinType, lead) - return - } - - if read != uint32(len(into)) { - err = ArrayError{Wanted: uint32(len(into)), Got: read} - return - } - - o = b[skip+copy(into, b[skip:]):] - return -} - -// ReadStringZC reads a messagepack string field -// without copying. The returned []byte points -// to the same memory as the input slice. -// Possible errors: -// - ErrShortBytes (b not long enough) -// - TypeError{} (object not 'str') -func ReadStringZC(b []byte) (v []byte, o []byte, err error) { - l := len(b) - if l < 1 { - return nil, nil, ErrShortBytes - } - - lead := b[0] - var read int - - if isfixstr(lead) { - read = int(rfixstr(lead)) - b = b[1:] - } else { - switch lead { - case mstr8: - if l < 2 { - err = ErrShortBytes - return - } - read = int(b[1]) - b = b[2:] - - case mstr16: - if l < 3 { - err = ErrShortBytes - return - } - read = int(big.Uint16(b[1:])) - b = b[3:] - - case mstr32: - if l < 5 { - err = ErrShortBytes - return - } - read = int(big.Uint32(b[1:])) - b = b[5:] - - default: - err = TypeError{Method: StrType, Encoded: getType(lead)} - return - } - } - - if len(b) < read { - err = ErrShortBytes - return - } - - v = b[0:read] - o = b[read:] - return -} - -// ReadStringBytes reads a 'str' object -// from 'b' and returns its value and the -// remaining bytes in 'b'. -// Possible errors: -// - ErrShortBytes (b not long enough) -// - TypeError{} (not 'str' type) -// - InvalidPrefixError -func ReadStringBytes(b []byte) (string, []byte, error) { - v, o, err := ReadStringZC(b) - return string(v), o, err -} - -// ReadStringAsBytes reads a 'str' object -// into a slice of bytes. 'v' is the value of -// the 'str' object, which may reside in memory -// pointed to by 'scratch.' 'o' is the remaining bytes -// in 'b.'' -// Possible errors: -// - ErrShortBytes (b not long enough) -// - TypeError{} (not 'str' type) -// - InvalidPrefixError (unknown type marker) -func ReadStringAsBytes(b []byte, scratch []byte) (v []byte, o []byte, err error) { - var tmp []byte - tmp, o, err = ReadStringZC(b) - v = append(scratch[:0], tmp...) - return -} - -// ReadComplex128Bytes reads a complex128 -// extension object from 'b' and returns the -// remaining bytes. -// Possible errors: -// - ErrShortBytes (not enough bytes in 'b') -// - TypeError{} (object not a complex128) -// - InvalidPrefixError -// - ExtensionTypeError{} (object an extension of the correct size, but not a complex128) -func ReadComplex128Bytes(b []byte) (c complex128, o []byte, err error) { - if len(b) < 18 { - err = ErrShortBytes - return - } - if b[0] != mfixext16 { - err = badPrefix(Complex128Type, b[0]) - return - } - if int8(b[1]) != Complex128Extension { - err = errExt(int8(b[1]), Complex128Extension) - return - } - c = complex(math.Float64frombits(big.Uint64(b[2:])), - math.Float64frombits(big.Uint64(b[10:]))) - o = b[18:] - return -} - -// ReadComplex64Bytes reads a complex64 -// extension object from 'b' and returns the -// remaining bytes. -// Possible errors: -// - ErrShortBytes (not enough bytes in 'b') -// - TypeError{} (object not a complex64) -// - ExtensionTypeError{} (object an extension of the correct size, but not a complex64) -func ReadComplex64Bytes(b []byte) (c complex64, o []byte, err error) { - if len(b) < 10 { - err = ErrShortBytes - return - } - if b[0] != mfixext8 { - err = badPrefix(Complex64Type, b[0]) - return - } - if b[1] != Complex64Extension { - err = errExt(int8(b[1]), Complex64Extension) - return - } - c = complex(math.Float32frombits(big.Uint32(b[2:])), - math.Float32frombits(big.Uint32(b[6:]))) - o = b[10:] - return -} - -// ReadTimeBytes reads a time.Time -// extension object from 'b' and returns the -// remaining bytes. -// Possible errors: -// - ErrShortBytes (not enough bytes in 'b') -// - TypeError{} (object not a complex64) -// - ExtensionTypeError{} (object an extension of the correct size, but not a time.Time) -func ReadTimeBytes(b []byte) (t time.Time, o []byte, err error) { - if len(b) < 15 { - err = ErrShortBytes - return - } - if b[0] != mext8 || b[1] != 12 { - err = badPrefix(TimeType, b[0]) - return - } - if int8(b[2]) != TimeExtension { - err = errExt(int8(b[2]), TimeExtension) - return - } - sec, nsec := getUnix(b[3:]) - t = time.Unix(sec, int64(nsec)).Local() - o = b[15:] - return -} - -// ReadMapStrIntfBytes reads a map[string]interface{} -// out of 'b' and returns the map and remaining bytes. -// If 'old' is non-nil, the values will be read into that map. -func ReadMapStrIntfBytes(b []byte, old map[string]interface{}) (v map[string]interface{}, o []byte, err error) { - var sz uint32 - o = b - sz, o, err = ReadMapHeaderBytes(o) - - if err != nil { - return - } - - if old != nil { - for key := range old { - delete(old, key) - } - v = old - } else { - v = make(map[string]interface{}, int(sz)) - } - - for z := uint32(0); z < sz; z++ { - if len(o) < 1 { - err = ErrShortBytes - return - } - var key []byte - key, o, err = ReadMapKeyZC(o) - if err != nil { - return - } - var val interface{} - val, o, err = ReadIntfBytes(o) - if err != nil { - return - } - v[string(key)] = val - } - return -} - -// ReadIntfBytes attempts to read -// the next object out of 'b' as a raw interface{} and -// return the remaining bytes. -func ReadIntfBytes(b []byte) (i interface{}, o []byte, err error) { - if len(b) < 1 { - err = ErrShortBytes - return - } - - k := NextType(b) - - switch k { - case MapType: - i, o, err = ReadMapStrIntfBytes(b, nil) - return - - case ArrayType: - var sz uint32 - sz, o, err = ReadArrayHeaderBytes(b) - if err != nil { - return - } - j := make([]interface{}, int(sz)) - i = j - for d := range j { - j[d], o, err = ReadIntfBytes(o) - if err != nil { - return - } - } - return - - case Float32Type: - i, o, err = ReadFloat32Bytes(b) - return - - case Float64Type: - i, o, err = ReadFloat64Bytes(b) - return - - case IntType: - i, o, err = ReadInt64Bytes(b) - return - - case UintType: - i, o, err = ReadUint64Bytes(b) - return - - case BoolType: - i, o, err = ReadBoolBytes(b) - return - - case TimeType: - i, o, err = ReadTimeBytes(b) - return - - case Complex64Type: - i, o, err = ReadComplex64Bytes(b) - return - - case Complex128Type: - i, o, err = ReadComplex128Bytes(b) - return - - case ExtensionType: - var t int8 - t, err = peekExtension(b) - if err != nil { - return - } - // use a user-defined extension, - // if it's been registered - f, ok := extensionReg[t] - if ok { - e := f() - o, err = ReadExtensionBytes(b, e) - i = e - return - } - // last resort is a raw extension - e := RawExtension{} - e.Type = int8(t) - o, err = ReadExtensionBytes(b, &e) - i = &e - return - - case NilType: - o, err = ReadNilBytes(b) - return - - case BinType: - i, o, err = ReadBytesBytes(b, nil) - return - - case StrType: - i, o, err = ReadStringBytes(b) - return - - default: - err = InvalidPrefixError(b[0]) - return - } -} - -// Skip skips the next object in 'b' and -// returns the remaining bytes. If the object -// is a map or array, all of its elements -// will be skipped. -// Possible Errors: -// - ErrShortBytes (not enough bytes in b) -// - InvalidPrefixError (bad encoding) -func Skip(b []byte) ([]byte, error) { - sz, asz, err := getSize(b) - if err != nil { - return b, err - } - if uintptr(len(b)) < sz { - return b, ErrShortBytes - } - b = b[sz:] - for asz > 0 { - b, err = Skip(b) - if err != nil { - return b, err - } - asz-- - } - return b, nil -} - -// returns (skip N bytes, skip M objects, error) -func getSize(b []byte) (uintptr, uintptr, error) { - l := len(b) - if l == 0 { - return 0, 0, ErrShortBytes - } - lead := b[0] - spec := &sizes[lead] // get type information - size, mode := spec.size, spec.extra - if size == 0 { - return 0, 0, InvalidPrefixError(lead) - } - if mode >= 0 { // fixed composites - return uintptr(size), uintptr(mode), nil - } - if l < int(size) { - return 0, 0, ErrShortBytes - } - switch mode { - case extra8: - return uintptr(size) + uintptr(b[1]), 0, nil - case extra16: - return uintptr(size) + uintptr(big.Uint16(b[1:])), 0, nil - case extra32: - return uintptr(size) + uintptr(big.Uint32(b[1:])), 0, nil - case map16v: - return uintptr(size), 2 * uintptr(big.Uint16(b[1:])), nil - case map32v: - return uintptr(size), 2 * uintptr(big.Uint32(b[1:])), nil - case array16v: - return uintptr(size), uintptr(big.Uint16(b[1:])), nil - case array32v: - return uintptr(size), uintptr(big.Uint32(b[1:])), nil - default: - return 0, 0, fatal - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/read_bytes_test.go b/vendor/github.com/tinylib/msgp/msgp/read_bytes_test.go deleted file mode 100644 index 0049471..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/read_bytes_test.go +++ /dev/null @@ -1,518 +0,0 @@ -package msgp - -import ( - "bytes" - "reflect" - "testing" - "time" -) - -func TestReadMapHeaderBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []uint32{0, 1, 5, 49082} - - for i, v := range tests { - buf.Reset() - en.WriteMapHeader(v) - en.Flush() - - out, left, err := ReadMapHeaderBytes(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - - if out != v { - t.Errorf("%d in; %d out", v, out) - } - } -} - -func BenchmarkReadMapHeaderBytes(b *testing.B) { - sizes := []uint32{1, 100, tuint16, tuint32} - buf := make([]byte, 0, 5*len(sizes)) - for _, sz := range sizes { - buf = AppendMapHeader(buf, sz) - } - b.SetBytes(int64(len(buf) / len(sizes))) - b.ReportAllocs() - b.ResetTimer() - o := buf - for i := 0; i < b.N; i++ { - _, buf, _ = ReadMapHeaderBytes(buf) - if len(buf) == 0 { - buf = o - } - } -} - -func TestReadArrayHeaderBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []uint32{0, 1, 5, 49082} - - for i, v := range tests { - buf.Reset() - en.WriteArrayHeader(v) - en.Flush() - - out, left, err := ReadArrayHeaderBytes(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - - if out != v { - t.Errorf("%d in; %d out", v, out) - } - } -} - -func BenchmarkReadArrayHeaderBytes(b *testing.B) { - sizes := []uint32{1, 100, tuint16, tuint32} - buf := make([]byte, 0, 5*len(sizes)) - for _, sz := range sizes { - buf = AppendArrayHeader(buf, sz) - } - b.SetBytes(int64(len(buf) / len(sizes))) - b.ReportAllocs() - b.ResetTimer() - o := buf - for i := 0; i < b.N; i++ { - _, buf, _ = ReadArrayHeaderBytes(buf) - if len(buf) == 0 { - buf = o - } - } -} - -func TestReadNilBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteNil() - en.Flush() - - left, err := ReadNilBytes(buf.Bytes()) - if err != nil { - t.Fatal(err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } -} - -func BenchmarkReadNilByte(b *testing.B) { - buf := []byte{mnil} - b.SetBytes(1) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - ReadNilBytes(buf) - } -} - -func TestReadFloat64Bytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteFloat64(3.14159) - en.Flush() - - out, left, err := ReadFloat64Bytes(buf.Bytes()) - if err != nil { - t.Fatal(err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if out != 3.14159 { - t.Errorf("%f in; %f out", 3.14159, out) - } -} - -func BenchmarkReadFloat64Bytes(b *testing.B) { - f := float64(3.14159) - buf := make([]byte, 0, 9) - buf = AppendFloat64(buf, f) - b.SetBytes(int64(len(buf))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - ReadFloat64Bytes(buf) - } -} - -func TestReadFloat32Bytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteFloat32(3.1) - en.Flush() - - out, left, err := ReadFloat32Bytes(buf.Bytes()) - if err != nil { - t.Fatal(err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if out != 3.1 { - t.Errorf("%f in; %f out", 3.1, out) - } -} - -func BenchmarkReadFloat32Bytes(b *testing.B) { - f := float32(3.14159) - buf := make([]byte, 0, 5) - buf = AppendFloat32(buf, f) - b.SetBytes(int64(len(buf))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - ReadFloat32Bytes(buf) - } -} - -func TestReadBoolBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []bool{true, false} - - for i, v := range tests { - buf.Reset() - en.WriteBool(v) - en.Flush() - out, left, err := ReadBoolBytes(buf.Bytes()) - - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - - if out != v { - t.Errorf("%t in; %t out", v, out) - } - } -} - -func BenchmarkReadBoolBytes(b *testing.B) { - buf := []byte{mtrue, mfalse, mtrue, mfalse} - b.SetBytes(1) - b.ReportAllocs() - b.ResetTimer() - o := buf - for i := 0; i < b.N; i++ { - _, buf, _ = ReadBoolBytes(buf) - if len(buf) == 0 { - buf = o - } - } -} - -func TestReadInt64Bytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []int64{-5, -30, 0, 1, 127, 300, 40921, 34908219} - - for i, v := range tests { - buf.Reset() - en.WriteInt64(v) - en.Flush() - out, left, err := ReadInt64Bytes(buf.Bytes()) - - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - - if out != v { - t.Errorf("%d in; %d out", v, out) - } - } -} - -func TestReadUint64Bytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []uint64{0, 1, 127, 300, 40921, 34908219} - - for i, v := range tests { - buf.Reset() - en.WriteUint64(v) - en.Flush() - out, left, err := ReadUint64Bytes(buf.Bytes()) - - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - - if out != v { - t.Errorf("%d in; %d out", v, out) - } - } -} - -func TestReadBytesBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := [][]byte{[]byte{}, []byte("some bytes"), []byte("some more bytes")} - var scratch []byte - - for i, v := range tests { - buf.Reset() - en.WriteBytes(v) - en.Flush() - out, left, err := ReadBytesBytes(buf.Bytes(), scratch) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if !bytes.Equal(out, v) { - t.Errorf("%q in; %q out", v, out) - } - } -} - -func TestReadZCBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := [][]byte{[]byte{}, []byte("some bytes"), []byte("some more bytes")} - - for i, v := range tests { - buf.Reset() - en.WriteBytes(v) - en.Flush() - out, left, err := ReadBytesZC(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if !bytes.Equal(out, v) { - t.Errorf("%q in; %q out", v, out) - } - } -} - -func TestReadZCString(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []string{"", "hello", "here's another string......"} - - for i, v := range tests { - buf.Reset() - en.WriteString(v) - en.Flush() - - out, left, err := ReadStringZC(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if string(out) != v { - t.Errorf("%q in; %q out", v, out) - } - } -} - -func TestReadStringBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []string{"", "hello", "here's another string......"} - - for i, v := range tests { - buf.Reset() - en.WriteString(v) - en.Flush() - - out, left, err := ReadStringBytes(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if out != v { - t.Errorf("%q in; %q out", v, out) - } - } -} - -func TestReadComplex128Bytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []complex128{complex(0, 0), complex(12.8, 32.0)} - - for i, v := range tests { - buf.Reset() - en.WriteComplex128(v) - en.Flush() - - out, left, err := ReadComplex128Bytes(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if out != v { - t.Errorf("%f in; %f out", v, out) - } - } -} - -func TestReadComplex64Bytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := []complex64{complex(0, 0), complex(12.8, 32.0)} - - for i, v := range tests { - buf.Reset() - en.WriteComplex64(v) - en.Flush() - - out, left, err := ReadComplex64Bytes(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if out != v { - t.Errorf("%f in; %f out", v, out) - } - } -} - -func TestReadTimeBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - now := time.Now() - en.WriteTime(now) - en.Flush() - out, left, err := ReadTimeBytes(buf.Bytes()) - if err != nil { - t.Fatal(err) - } - - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if !now.Equal(out) { - t.Errorf("%s in; %s out", now, out) - } -} - -func BenchmarkReadTimeBytes(b *testing.B) { - data := AppendTime(nil, time.Now()) - b.SetBytes(15) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - ReadTimeBytes(data) - } -} - -func TestReadIntfBytes(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - tests := make([]interface{}, 0, 10) - tests = append(tests, float64(3.5)) - tests = append(tests, int64(-49082)) - tests = append(tests, uint64(34908)) - tests = append(tests, string("hello!")) - tests = append(tests, []byte("blah.")) - tests = append(tests, map[string]interface{}{ - "key_one": 3.5, - "key_two": "hi.", - }) - - for i, v := range tests { - buf.Reset() - if err := en.WriteIntf(v); err != nil { - t.Fatal(err) - } - en.Flush() - - out, left, err := ReadIntfBytes(buf.Bytes()) - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if len(left) != 0 { - t.Errorf("expected 0 bytes left; found %d", len(left)) - } - if !reflect.DeepEqual(v, out) { - t.Errorf("ReadIntf(): %v in; %v out", v, out) - } - } - -} - -func BenchmarkSkipBytes(b *testing.B) { - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteMapHeader(6) - - en.WriteString("thing_one") - en.WriteString("value_one") - - en.WriteString("thing_two") - en.WriteFloat64(3.14159) - - en.WriteString("some_bytes") - en.WriteBytes([]byte("nkl4321rqw908vxzpojnlk2314rqew098-s09123rdscasd")) - - en.WriteString("the_time") - en.WriteTime(time.Now()) - - en.WriteString("what?") - en.WriteBool(true) - - en.WriteString("ext") - en.WriteExtension(&RawExtension{Type: 55, Data: []byte("raw data!!!")}) - en.Flush() - - bts := buf.Bytes() - b.SetBytes(int64(len(bts))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := Skip(bts) - if err != nil { - b.Fatal(err) - } - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/read_test.go b/vendor/github.com/tinylib/msgp/msgp/read_test.go deleted file mode 100644 index 8e781c1..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/read_test.go +++ /dev/null @@ -1,770 +0,0 @@ -package msgp - -import ( - "bytes" - "io" - "math" - "math/rand" - "reflect" - "testing" - "time" -) - -func TestSanity(t *testing.T) { - if !isfixint(0) { - t.Fatal("WUT.") - } -} - -func TestReadIntf(t *testing.T) { - // NOTE: if you include cases - // with, say, int32s, the test - // will fail, b/c integers are - // always read out as int64, and - // unsigned integers as uint64 - - var testCases = []interface{}{ - float64(128.032), - float32(9082.092), - int64(-40), - uint64(9082981), - time.Now(), - "hello!", - []byte("hello!"), - map[string]interface{}{ - "thing-1": "thing-1-value", - "thing-2": int64(800), - "thing-3": []byte("some inner bytes..."), - "thing-4": false, - }, - } - - var buf bytes.Buffer - var v interface{} - dec := NewReader(&buf) - enc := NewWriter(&buf) - - for i, ts := range testCases { - buf.Reset() - err := enc.WriteIntf(ts) - if err != nil { - t.Errorf("Test case %d: %s", i, err) - continue - } - err = enc.Flush() - if err != nil { - t.Fatal(err) - } - v, err = dec.ReadIntf() - if err != nil { - t.Errorf("Test case: %d: %s", i, err) - } - - /* for time, use time.Equal instead of reflect.DeepEqual */ - if tm, ok := v.(time.Time); ok { - if !tm.Equal(v.(time.Time)) { - t.Errorf("%v != %v", ts, v) - } - } else if !reflect.DeepEqual(v, ts) { - t.Errorf("%v in; %v out", ts, v) - } - } - -} - -func TestReadMapHeader(t *testing.T) { - tests := []struct { - Sz uint32 - }{ - {0}, - {1}, - {tuint16}, - {tuint32}, - } - - var buf bytes.Buffer - var sz uint32 - var err error - wr := NewWriter(&buf) - rd := NewReader(&buf) - for i, test := range tests { - buf.Reset() - err = wr.WriteMapHeader(test.Sz) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - sz, err = rd.ReadMapHeader() - if err != nil { - t.Errorf("Test case %d: got error %s", i, err) - } - if sz != test.Sz { - t.Errorf("Test case %d: wrote size %d; got size %d", i, test.Sz, sz) - } - } -} - -func BenchmarkReadMapHeader(b *testing.B) { - sizes := []uint32{0, 1, tuint16, tuint32} - data := make([]byte, 0, len(sizes)*5) - for _, d := range sizes { - data = AppendMapHeader(data, d) - } - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data) / len(sizes))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - rd.ReadMapHeader() - } -} - -func TestReadArrayHeader(t *testing.T) { - tests := []struct { - Sz uint32 - }{ - {0}, - {1}, - {tuint16}, - {tuint32}, - } - - var buf bytes.Buffer - var sz uint32 - var err error - wr := NewWriter(&buf) - rd := NewReader(&buf) - for i, test := range tests { - buf.Reset() - err = wr.WriteArrayHeader(test.Sz) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - sz, err = rd.ReadArrayHeader() - if err != nil { - t.Errorf("Test case %d: got error %s", i, err) - } - if sz != test.Sz { - t.Errorf("Test case %d: wrote size %d; got size %d", i, test.Sz, sz) - } - } -} - -func BenchmarkReadArrayHeader(b *testing.B) { - sizes := []uint32{0, 1, tuint16, tuint32} - data := make([]byte, 0, len(sizes)*5) - for _, d := range sizes { - data = AppendArrayHeader(data, d) - } - rd := NewReader(NewEndlessReader(data, b)) - b.ReportAllocs() - b.SetBytes(int64(len(data) / len(sizes))) - b.ResetTimer() - for i := 0; i < b.N; i++ { - rd.ReadArrayHeader() - } -} - -func TestReadNil(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - wr.WriteNil() - wr.Flush() - err := rd.ReadNil() - if err != nil { - t.Fatal(err) - } -} - -func BenchmarkReadNil(b *testing.B) { - data := AppendNil(nil) - rd := NewReader(NewEndlessReader(data, b)) - b.ReportAllocs() - b.SetBytes(1) - b.ResetTimer() - for i := 0; i < b.N; i++ { - err := rd.ReadNil() - if err != nil { - b.Fatal(err) - } - } -} - -func TestReadFloat64(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - for i := 0; i < 100; i++ { - buf.Reset() - - flt := (rand.Float64() - 0.5) * math.MaxFloat64 - err := wr.WriteFloat64(flt) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - out, err := rd.ReadFloat64() - if err != nil { - t.Errorf("Error reading %f: %s", flt, err) - continue - } - - if out != flt { - t.Errorf("Put in %f but got out %f", flt, out) - } - } -} - -func BenchmarkReadFloat64(b *testing.B) { - fs := []float64{rand.Float64(), rand.Float64(), rand.Float64(), rand.Float64()} - data := make([]byte, 0, 9*len(fs)) - for _, f := range fs { - data = AppendFloat64(data, f) - } - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(9) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadFloat64() - if err != nil { - b.Fatal(err) - } - } -} - -func TestReadFloat32(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - for i := 0; i < 10000; i++ { - buf.Reset() - - flt := (rand.Float32() - 0.5) * math.MaxFloat32 - err := wr.WriteFloat32(flt) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - out, err := rd.ReadFloat32() - if err != nil { - t.Errorf("Error reading %f: %s", flt, err) - continue - } - - if out != flt { - t.Errorf("Put in %f but got out %f", flt, out) - } - } -} - -func BenchmarkReadFloat32(b *testing.B) { - fs := []float32{rand.Float32(), rand.Float32(), rand.Float32(), rand.Float32()} - data := make([]byte, 0, 5*len(fs)) - for _, f := range fs { - data = AppendFloat32(data, f) - } - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(5) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadFloat32() - if err != nil { - b.Fatal(err) - } - } -} - -func TestReadInt64(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - ints := []int64{-100000, -5000, -5, 0, 8, 240, int64(tuint16), int64(tuint32), int64(tuint64)} - - for i, num := range ints { - buf.Reset() - - err := wr.WriteInt64(num) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - out, err := rd.ReadInt64() - if err != nil { - t.Fatal(err) - } - if out != num { - t.Errorf("Test case %d: put %d in and got %d out", i, num, out) - } - } -} - -func BenchmarkReadInt64(b *testing.B) { - is := []int64{0, 1, 65000, rand.Int63()} - data := make([]byte, 0, 9*len(is)) - for _, n := range is { - data = AppendInt64(data, n) - } - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data) / len(is))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadInt64() - if err != nil { - b.Fatal(err) - } - } -} - -func TestReadUint64(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - ints := []uint64{0, 8, 240, uint64(tuint16), uint64(tuint32), uint64(tuint64)} - - for i, num := range ints { - buf.Reset() - - err := wr.WriteUint64(num) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - out, err := rd.ReadUint64() - if out != num { - t.Errorf("Test case %d: put %d in and got %d out", i, num, out) - } - } -} - -func BenchmarkReadUint64(b *testing.B) { - us := []uint64{0, 1, 10000, uint64(rand.Uint32() * 4)} - data := make([]byte, 0, 9*len(us)) - for _, n := range us { - data = AppendUint64(data, n) - } - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data) / len(us))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadUint64() - if err != nil { - b.Fatal(err) - } - } -} - -func TestReadBytes(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - sizes := []int{0, 1, 225, int(tuint32)} - var scratch []byte - for i, size := range sizes { - buf.Reset() - bts := RandBytes(size) - - err := wr.WriteBytes(bts) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - - out, err := rd.ReadBytes(scratch) - if err != nil { - t.Errorf("test case %d: %s", i, err) - continue - } - - if !bytes.Equal(bts, out) { - t.Errorf("test case %d: Bytes not equal.", i) - } - - } -} - -func benchBytes(size uint32, b *testing.B) { - data := make([]byte, 0, size+5) - data = AppendBytes(data, RandBytes(int(size))) - - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data))) - b.ReportAllocs() - b.ResetTimer() - var scratch []byte - var err error - for i := 0; i < b.N; i++ { - scratch, err = rd.ReadBytes(scratch) - if err != nil { - b.Fatal(err) - } - } -} - -func BenchmarkRead16Bytes(b *testing.B) { - benchBytes(16, b) -} - -func BenchmarkRead256Bytes(b *testing.B) { - benchBytes(256, b) -} - -// This particular case creates -// an object larger than the default -// read buffer size, so it's a decent -// indicator of worst-case performance. -func BenchmarkRead2048Bytes(b *testing.B) { - benchBytes(2048, b) -} - -func TestReadString(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - sizes := []int{0, 1, 225, int(math.MaxUint16 + 5)} - for i, size := range sizes { - buf.Reset() - in := string(RandBytes(size)) - - err := wr.WriteString(in) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - - out, err := rd.ReadString() - if err != nil { - t.Errorf("test case %d: %s", i, err) - } - if out != in { - t.Errorf("test case %d: strings not equal.", i) - t.Errorf("string (len = %d) in; string (len = %d) out", size, len(out)) - } - - } -} - -func benchString(size uint32, b *testing.B) { - str := string(RandBytes(int(size))) - data := make([]byte, 0, len(str)+5) - data = AppendString(data, str) - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadString() - if err != nil { - b.Fatal(err) - } - } -} - -func benchStringAsBytes(size uint32, b *testing.B) { - str := string(RandBytes(int(size))) - data := make([]byte, 0, len(str)+5) - data = AppendString(data, str) - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data))) - b.ReportAllocs() - b.ResetTimer() - var scratch []byte - var err error - for i := 0; i < b.N; i++ { - scratch, err = rd.ReadStringAsBytes(scratch) - if err != nil { - b.Fatal(err) - } - } -} - -func BenchmarkRead16StringAsBytes(b *testing.B) { - benchStringAsBytes(16, b) -} - -func BenchmarkRead256StringAsBytes(b *testing.B) { - benchStringAsBytes(256, b) -} - -func BenchmarkRead16String(b *testing.B) { - benchString(16, b) -} - -func BenchmarkRead256String(b *testing.B) { - benchString(256, b) -} - -func TestReadComplex64(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - for i := 0; i < 100; i++ { - buf.Reset() - f := complex(rand.Float32()*math.MaxFloat32, rand.Float32()*math.MaxFloat32) - - wr.WriteComplex64(f) - err := wr.Flush() - if err != nil { - t.Fatal(err) - } - - out, err := rd.ReadComplex64() - if err != nil { - t.Error(err) - continue - } - - if out != f { - t.Errorf("Wrote %f; read %f", f, out) - } - - } -} - -func BenchmarkReadComplex64(b *testing.B) { - f := complex(rand.Float32(), rand.Float32()) - data := AppendComplex64(nil, f) - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadComplex64() - if err != nil { - b.Fatal(err) - } - } -} - -func TestReadComplex128(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - for i := 0; i < 10; i++ { - buf.Reset() - f := complex(rand.Float64()*math.MaxFloat64, rand.Float64()*math.MaxFloat64) - - wr.WriteComplex128(f) - err := wr.Flush() - if err != nil { - t.Fatal(err) - } - - out, err := rd.ReadComplex128() - if err != nil { - t.Error(err) - continue - } - if out != f { - t.Errorf("Wrote %f; read %f", f, out) - } - - } -} - -func BenchmarkReadComplex128(b *testing.B) { - f := complex(rand.Float64(), rand.Float64()) - data := AppendComplex128(nil, f) - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadComplex128() - if err != nil { - b.Fatal(err) - } - } -} - -func TestTime(t *testing.T) { - var buf bytes.Buffer - now := time.Now() - en := NewWriter(&buf) - dc := NewReader(&buf) - - err := en.WriteTime(now) - if err != nil { - t.Fatal(err) - } - err = en.Flush() - if err != nil { - t.Fatal(err) - } - - out, err := dc.ReadTime() - if err != nil { - t.Fatal(err) - } - - // check for equivalence - if !now.Equal(out) { - t.Fatalf("%s in; %s out", now, out) - } -} - -func BenchmarkReadTime(b *testing.B) { - t := time.Now() - data := AppendTime(nil, t) - rd := NewReader(NewEndlessReader(data, b)) - b.SetBytes(int64(len(data))) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - _, err := rd.ReadTime() - if err != nil { - b.Fatal(err) - } - } -} - -func TestSkip(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - rd := NewReader(&buf) - - wr.WriteMapHeader(4) - wr.WriteString("key_1") - wr.WriteBytes([]byte("value_1")) - wr.WriteString("key_2") - wr.WriteFloat64(2.0) - wr.WriteString("key_3") - wr.WriteComplex128(3.0i) - wr.WriteString("key_4") - wr.WriteInt64(49080432189) - wr.Flush() - - // this should skip the whole map - err := rd.Skip() - if err != nil { - t.Fatal(err) - } - - tp, err := rd.NextType() - if err != io.EOF { - t.Errorf("expected %q; got %q", io.EOF, err) - t.Errorf("returned type %q", tp) - } - -} - -func BenchmarkSkip(b *testing.B) { - var buf bytes.Buffer - en := NewWriter(&buf) - en.WriteMapHeader(6) - - en.WriteString("thing_one") - en.WriteString("value_one") - - en.WriteString("thing_two") - en.WriteFloat64(3.14159) - - en.WriteString("some_bytes") - en.WriteBytes([]byte("nkl4321rqw908vxzpojnlk2314rqew098-s09123rdscasd")) - - en.WriteString("the_time") - en.WriteTime(time.Now()) - - en.WriteString("what?") - en.WriteBool(true) - - en.WriteString("ext") - en.WriteExtension(&RawExtension{Type: 55, Data: []byte("raw data!!!")}) - en.Flush() - - bts := buf.Bytes() - b.SetBytes(int64(len(bts))) - b.ReportAllocs() - b.ResetTimer() - - rd := NewReader(NewEndlessReader(bts, b)) - for i := 0; i < b.N; i++ { - err := rd.Skip() - if err != nil { - b.Fatal(err) - } - } -} - -func TestCopyNext(t *testing.T) { - var buf bytes.Buffer - en := NewWriter(&buf) - - en.WriteMapHeader(6) - - en.WriteString("thing_one") - en.WriteString("value_one") - - en.WriteString("thing_two") - en.WriteFloat64(3.14159) - - en.WriteString("some_bytes") - en.WriteBytes([]byte("nkl4321rqw908vxzpojnlk2314rqew098-s09123rdscasd")) - - en.WriteString("the_time") - en.WriteTime(time.Now()) - - en.WriteString("what?") - en.WriteBool(true) - - en.WriteString("ext") - en.WriteExtension(&RawExtension{Type: 55, Data: []byte("raw data!!!")}) - - en.Flush() - - // Read from a copy of the original buf. - de := NewReader(bytes.NewReader(buf.Bytes())) - - w := new(bytes.Buffer) - - n, err := de.CopyNext(w) - if err != nil { - t.Fatal(err) - } - if n != int64(buf.Len()) { - t.Fatalf("CopyNext returned the wrong value (%d != %d)", - n, buf.Len()) - } - - if !bytes.Equal(buf.Bytes(), w.Bytes()) { - t.Fatalf("not equal! %v, %v", buf.Bytes(), w.Bytes()) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/size.go b/vendor/github.com/tinylib/msgp/msgp/size.go deleted file mode 100644 index ce2f8b1..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/size.go +++ /dev/null @@ -1,38 +0,0 @@ -package msgp - -// The sizes provided -// are the worst-case -// encoded sizes for -// each type. For variable- -// length types ([]byte, string), -// the total encoded size is -// the prefix size plus the -// length of the object. -const ( - Int64Size = 9 - IntSize = Int64Size - UintSize = Int64Size - Int8Size = 2 - Int16Size = 3 - Int32Size = 5 - Uint8Size = 2 - ByteSize = Uint8Size - Uint16Size = 3 - Uint32Size = 5 - Uint64Size = Int64Size - Float64Size = 9 - Float32Size = 5 - Complex64Size = 10 - Complex128Size = 18 - - TimeSize = 15 - BoolSize = 1 - NilSize = 1 - - MapHeaderSize = 5 - ArrayHeaderSize = 5 - - BytesPrefixSize = 5 - StringPrefixSize = 5 - ExtensionPrefixSize = 6 -) diff --git a/vendor/github.com/tinylib/msgp/msgp/unsafe.go b/vendor/github.com/tinylib/msgp/msgp/unsafe.go deleted file mode 100644 index 4bcf321..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/unsafe.go +++ /dev/null @@ -1,41 +0,0 @@ -// +build !appengine - -package msgp - -import ( - "reflect" - "unsafe" -) - -// NOTE: -// all of the definition in this file -// should be repeated in appengine.go, -// but without using unsafe - -const ( - // spec says int and uint are always - // the same size, but that int/uint - // size may not be machine word size - smallint = unsafe.Sizeof(int(0)) == 4 -) - -// UnsafeString returns the byte slice as a volatile string -// THIS SHOULD ONLY BE USED BY THE CODE GENERATOR. -// THIS IS EVIL CODE. -// YOU HAVE BEEN WARNED. -func UnsafeString(b []byte) string { - sh := (*reflect.SliceHeader)(unsafe.Pointer(&b)) - return *(*string)(unsafe.Pointer(&reflect.StringHeader{Data: sh.Data, Len: sh.Len})) -} - -// UnsafeBytes returns the string as a byte slice -// THIS SHOULD ONLY BE USED BY THE CODE GENERATOR. -// THIS IS EVIL CODE. -// YOU HAVE BEEN WARNED. -func UnsafeBytes(s string) []byte { - return *(*[]byte)(unsafe.Pointer(&reflect.SliceHeader{ - Len: len(s), - Cap: len(s), - Data: (*(*reflect.StringHeader)(unsafe.Pointer(&s))).Data, - })) -} diff --git a/vendor/github.com/tinylib/msgp/msgp/write.go b/vendor/github.com/tinylib/msgp/msgp/write.go deleted file mode 100644 index da9099c..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/write.go +++ /dev/null @@ -1,845 +0,0 @@ -package msgp - -import ( - "errors" - "fmt" - "io" - "math" - "reflect" - "sync" - "time" -) - -// Sizer is an interface implemented -// by types that can estimate their -// size when MessagePack encoded. -// This interface is optional, but -// encoding/marshaling implementations -// may use this as a way to pre-allocate -// memory for serialization. -type Sizer interface { - Msgsize() int -} - -var ( - // Nowhere is an io.Writer to nowhere - Nowhere io.Writer = nwhere{} - - btsType = reflect.TypeOf(([]byte)(nil)) - writerPool = sync.Pool{ - New: func() interface{} { - return &Writer{buf: make([]byte, 2048)} - }, - } -) - -func popWriter(w io.Writer) *Writer { - wr := writerPool.Get().(*Writer) - wr.Reset(w) - return wr -} - -func pushWriter(wr *Writer) { - wr.w = nil - wr.wloc = 0 - writerPool.Put(wr) -} - -// freeW frees a writer for use -// by other processes. It is not necessary -// to call freeW on a writer. However, maintaining -// a reference to a *Writer after calling freeW on -// it will cause undefined behavior. -func freeW(w *Writer) { pushWriter(w) } - -// Require ensures that cap(old)-len(old) >= extra. -func Require(old []byte, extra int) []byte { - l := len(old) - c := cap(old) - r := l + extra - if c >= r { - return old - } else if l == 0 { - return make([]byte, 0, extra) - } - // the new size is the greater - // of double the old capacity - // and the sum of the old length - // and the number of new bytes - // necessary. - c <<= 1 - if c < r { - c = r - } - n := make([]byte, l, c) - copy(n, old) - return n -} - -// nowhere writer -type nwhere struct{} - -func (n nwhere) Write(p []byte) (int, error) { return len(p), nil } - -// Marshaler is the interface implemented -// by types that know how to marshal themselves -// as MessagePack. MarshalMsg appends the marshalled -// form of the object to the provided -// byte slice, returning the extended -// slice and any errors encountered. -type Marshaler interface { - MarshalMsg([]byte) ([]byte, error) -} - -// Encodable is the interface implemented -// by types that know how to write themselves -// as MessagePack using a *msgp.Writer. -type Encodable interface { - EncodeMsg(*Writer) error -} - -// Writer is a buffered writer -// that can be used to write -// MessagePack objects to an io.Writer. -// You must call *Writer.Flush() in order -// to flush all of the buffered data -// to the underlying writer. -type Writer struct { - w io.Writer - buf []byte - wloc int -} - -// NewWriter returns a new *Writer. -func NewWriter(w io.Writer) *Writer { - if wr, ok := w.(*Writer); ok { - return wr - } - return popWriter(w) -} - -// NewWriterSize returns a writer with a custom buffer size. -func NewWriterSize(w io.Writer, sz int) *Writer { - // we must be able to require() 18 - // contiguous bytes, so that is the - // practical minimum buffer size - if sz < 18 { - sz = 18 - } - - return &Writer{ - w: w, - buf: make([]byte, sz), - } -} - -// Encode encodes an Encodable to an io.Writer. -func Encode(w io.Writer, e Encodable) error { - wr := NewWriter(w) - err := e.EncodeMsg(wr) - if err == nil { - err = wr.Flush() - } - freeW(wr) - return err -} - -func (mw *Writer) flush() error { - if mw.wloc == 0 { - return nil - } - n, err := mw.w.Write(mw.buf[:mw.wloc]) - if err != nil { - if n > 0 { - mw.wloc = copy(mw.buf, mw.buf[n:mw.wloc]) - } - return err - } - mw.wloc = 0 - return nil -} - -// Flush flushes all of the buffered -// data to the underlying writer. -func (mw *Writer) Flush() error { return mw.flush() } - -// Buffered returns the number bytes in the write buffer -func (mw *Writer) Buffered() int { return len(mw.buf) - mw.wloc } - -func (mw *Writer) avail() int { return len(mw.buf) - mw.wloc } - -func (mw *Writer) bufsize() int { return len(mw.buf) } - -// NOTE: this should only be called with -// a number that is guaranteed to be less than -// len(mw.buf). typically, it is called with a constant. -// -// NOTE: this is a hot code path -func (mw *Writer) require(n int) (int, error) { - c := len(mw.buf) - wl := mw.wloc - if c-wl < n { - if err := mw.flush(); err != nil { - return 0, err - } - wl = mw.wloc - } - mw.wloc += n - return wl, nil -} - -func (mw *Writer) Append(b ...byte) error { - if mw.avail() < len(b) { - err := mw.flush() - if err != nil { - return err - } - } - mw.wloc += copy(mw.buf[mw.wloc:], b) - return nil -} - -// push one byte onto the buffer -// -// NOTE: this is a hot code path -func (mw *Writer) push(b byte) error { - if mw.wloc == len(mw.buf) { - if err := mw.flush(); err != nil { - return err - } - } - mw.buf[mw.wloc] = b - mw.wloc++ - return nil -} - -func (mw *Writer) prefix8(b byte, u uint8) error { - const need = 2 - if len(mw.buf)-mw.wloc < need { - if err := mw.flush(); err != nil { - return err - } - } - prefixu8(mw.buf[mw.wloc:], b, u) - mw.wloc += need - return nil -} - -func (mw *Writer) prefix16(b byte, u uint16) error { - const need = 3 - if len(mw.buf)-mw.wloc < need { - if err := mw.flush(); err != nil { - return err - } - } - prefixu16(mw.buf[mw.wloc:], b, u) - mw.wloc += need - return nil -} - -func (mw *Writer) prefix32(b byte, u uint32) error { - const need = 5 - if len(mw.buf)-mw.wloc < need { - if err := mw.flush(); err != nil { - return err - } - } - prefixu32(mw.buf[mw.wloc:], b, u) - mw.wloc += need - return nil -} - -func (mw *Writer) prefix64(b byte, u uint64) error { - const need = 9 - if len(mw.buf)-mw.wloc < need { - if err := mw.flush(); err != nil { - return err - } - } - prefixu64(mw.buf[mw.wloc:], b, u) - mw.wloc += need - return nil -} - -// Write implements io.Writer, and writes -// data directly to the buffer. -func (mw *Writer) Write(p []byte) (int, error) { - l := len(p) - if mw.avail() < l { - if err := mw.flush(); err != nil { - return 0, err - } - if l > len(mw.buf) { - return mw.w.Write(p) - } - } - mw.wloc += copy(mw.buf[mw.wloc:], p) - return l, nil -} - -// implements io.WriteString -func (mw *Writer) writeString(s string) error { - l := len(s) - if mw.avail() < l { - if err := mw.flush(); err != nil { - return err - } - if l > len(mw.buf) { - _, err := io.WriteString(mw.w, s) - return err - } - } - mw.wloc += copy(mw.buf[mw.wloc:], s) - return nil -} - -// Reset changes the underlying writer used by the Writer -func (mw *Writer) Reset(w io.Writer) { - mw.buf = mw.buf[:cap(mw.buf)] - mw.w = w - mw.wloc = 0 -} - -// WriteMapHeader writes a map header of the given -// size to the writer -func (mw *Writer) WriteMapHeader(sz uint32) error { - switch { - case sz <= 15: - return mw.push(wfixmap(uint8(sz))) - case sz <= math.MaxUint16: - return mw.prefix16(mmap16, uint16(sz)) - default: - return mw.prefix32(mmap32, sz) - } -} - -// WriteArrayHeader writes an array header of the -// given size to the writer -func (mw *Writer) WriteArrayHeader(sz uint32) error { - switch { - case sz <= 15: - return mw.push(wfixarray(uint8(sz))) - case sz <= math.MaxUint16: - return mw.prefix16(marray16, uint16(sz)) - default: - return mw.prefix32(marray32, sz) - } -} - -// WriteNil writes a nil byte to the buffer -func (mw *Writer) WriteNil() error { - return mw.push(mnil) -} - -// WriteFloat64 writes a float64 to the writer -func (mw *Writer) WriteFloat64(f float64) error { - return mw.prefix64(mfloat64, math.Float64bits(f)) -} - -// WriteFloat32 writes a float32 to the writer -func (mw *Writer) WriteFloat32(f float32) error { - return mw.prefix32(mfloat32, math.Float32bits(f)) -} - -// WriteInt64 writes an int64 to the writer -func (mw *Writer) WriteInt64(i int64) error { - if i >= 0 { - switch { - case i <= math.MaxInt8: - return mw.push(wfixint(uint8(i))) - case i <= math.MaxInt16: - return mw.prefix16(mint16, uint16(i)) - case i <= math.MaxInt32: - return mw.prefix32(mint32, uint32(i)) - default: - return mw.prefix64(mint64, uint64(i)) - } - } - switch { - case i >= -32: - return mw.push(wnfixint(int8(i))) - case i >= math.MinInt8: - return mw.prefix8(mint8, uint8(i)) - case i >= math.MinInt16: - return mw.prefix16(mint16, uint16(i)) - case i >= math.MinInt32: - return mw.prefix32(mint32, uint32(i)) - default: - return mw.prefix64(mint64, uint64(i)) - } -} - -// WriteInt8 writes an int8 to the writer -func (mw *Writer) WriteInt8(i int8) error { return mw.WriteInt64(int64(i)) } - -// WriteInt16 writes an int16 to the writer -func (mw *Writer) WriteInt16(i int16) error { return mw.WriteInt64(int64(i)) } - -// WriteInt32 writes an int32 to the writer -func (mw *Writer) WriteInt32(i int32) error { return mw.WriteInt64(int64(i)) } - -// WriteInt writes an int to the writer -func (mw *Writer) WriteInt(i int) error { return mw.WriteInt64(int64(i)) } - -// WriteUint64 writes a uint64 to the writer -func (mw *Writer) WriteUint64(u uint64) error { - switch { - case u <= (1<<7)-1: - return mw.push(wfixint(uint8(u))) - case u <= math.MaxUint8: - return mw.prefix8(muint8, uint8(u)) - case u <= math.MaxUint16: - return mw.prefix16(muint16, uint16(u)) - case u <= math.MaxUint32: - return mw.prefix32(muint32, uint32(u)) - default: - return mw.prefix64(muint64, u) - } -} - -// WriteByte is analogous to WriteUint8 -func (mw *Writer) WriteByte(u byte) error { return mw.WriteUint8(uint8(u)) } - -// WriteUint8 writes a uint8 to the writer -func (mw *Writer) WriteUint8(u uint8) error { return mw.WriteUint64(uint64(u)) } - -// WriteUint16 writes a uint16 to the writer -func (mw *Writer) WriteUint16(u uint16) error { return mw.WriteUint64(uint64(u)) } - -// WriteUint32 writes a uint32 to the writer -func (mw *Writer) WriteUint32(u uint32) error { return mw.WriteUint64(uint64(u)) } - -// WriteUint writes a uint to the writer -func (mw *Writer) WriteUint(u uint) error { return mw.WriteUint64(uint64(u)) } - -// WriteBytes writes binary as 'bin' to the writer -func (mw *Writer) WriteBytes(b []byte) error { - sz := uint32(len(b)) - var err error - switch { - case sz <= math.MaxUint8: - err = mw.prefix8(mbin8, uint8(sz)) - case sz <= math.MaxUint16: - err = mw.prefix16(mbin16, uint16(sz)) - default: - err = mw.prefix32(mbin32, sz) - } - if err != nil { - return err - } - _, err = mw.Write(b) - return err -} - -// WriteBytesHeader writes just the size header -// of a MessagePack 'bin' object. The user is responsible -// for then writing 'sz' more bytes into the stream. -func (mw *Writer) WriteBytesHeader(sz uint32) error { - switch { - case sz <= math.MaxUint8: - return mw.prefix8(mbin8, uint8(sz)) - case sz <= math.MaxUint16: - return mw.prefix16(mbin16, uint16(sz)) - default: - return mw.prefix32(mbin32, sz) - } -} - -// WriteBool writes a bool to the writer -func (mw *Writer) WriteBool(b bool) error { - if b { - return mw.push(mtrue) - } - return mw.push(mfalse) -} - -// WriteString writes a messagepack string to the writer. -// (This is NOT an implementation of io.StringWriter) -func (mw *Writer) WriteString(s string) error { - sz := uint32(len(s)) - var err error - switch { - case sz <= 31: - err = mw.push(wfixstr(uint8(sz))) - case sz <= math.MaxUint8: - err = mw.prefix8(mstr8, uint8(sz)) - case sz <= math.MaxUint16: - err = mw.prefix16(mstr16, uint16(sz)) - default: - err = mw.prefix32(mstr32, sz) - } - if err != nil { - return err - } - return mw.writeString(s) -} - -// WriteStringHeader writes just the string size -// header of a MessagePack 'str' object. The user -// is responsible for writing 'sz' more valid UTF-8 -// bytes to the stream. -func (mw *Writer) WriteStringHeader(sz uint32) error { - switch { - case sz <= 31: - return mw.push(wfixstr(uint8(sz))) - case sz <= math.MaxUint8: - return mw.prefix8(mstr8, uint8(sz)) - case sz <= math.MaxUint16: - return mw.prefix16(mstr16, uint16(sz)) - default: - return mw.prefix32(mstr32, sz) - } -} - -// WriteStringFromBytes writes a 'str' object -// from a []byte. -func (mw *Writer) WriteStringFromBytes(str []byte) error { - sz := uint32(len(str)) - var err error - switch { - case sz <= 31: - err = mw.push(wfixstr(uint8(sz))) - case sz <= math.MaxUint8: - err = mw.prefix8(mstr8, uint8(sz)) - case sz <= math.MaxUint16: - err = mw.prefix16(mstr16, uint16(sz)) - default: - err = mw.prefix32(mstr32, sz) - } - if err != nil { - return err - } - _, err = mw.Write(str) - return err -} - -// WriteComplex64 writes a complex64 to the writer -func (mw *Writer) WriteComplex64(f complex64) error { - o, err := mw.require(10) - if err != nil { - return err - } - mw.buf[o] = mfixext8 - mw.buf[o+1] = Complex64Extension - big.PutUint32(mw.buf[o+2:], math.Float32bits(real(f))) - big.PutUint32(mw.buf[o+6:], math.Float32bits(imag(f))) - return nil -} - -// WriteComplex128 writes a complex128 to the writer -func (mw *Writer) WriteComplex128(f complex128) error { - o, err := mw.require(18) - if err != nil { - return err - } - mw.buf[o] = mfixext16 - mw.buf[o+1] = Complex128Extension - big.PutUint64(mw.buf[o+2:], math.Float64bits(real(f))) - big.PutUint64(mw.buf[o+10:], math.Float64bits(imag(f))) - return nil -} - -// WriteMapStrStr writes a map[string]string to the writer -func (mw *Writer) WriteMapStrStr(mp map[string]string) (err error) { - err = mw.WriteMapHeader(uint32(len(mp))) - if err != nil { - return - } - for key, val := range mp { - err = mw.WriteString(key) - if err != nil { - return - } - err = mw.WriteString(val) - if err != nil { - return - } - } - return nil -} - -// WriteMapStrIntf writes a map[string]interface to the writer -func (mw *Writer) WriteMapStrIntf(mp map[string]interface{}) (err error) { - err = mw.WriteMapHeader(uint32(len(mp))) - if err != nil { - return - } - for key, val := range mp { - err = mw.WriteString(key) - if err != nil { - return - } - err = mw.WriteIntf(val) - if err != nil { - return - } - } - return -} - -// WriteTime writes a time.Time object to the wire. -// -// Time is encoded as Unix time, which means that -// location (time zone) data is removed from the object. -// The encoded object itself is 12 bytes: 8 bytes for -// a big-endian 64-bit integer denoting seconds -// elapsed since "zero" Unix time, followed by 4 bytes -// for a big-endian 32-bit signed integer denoting -// the nanosecond offset of the time. This encoding -// is intended to ease portability across languages. -// (Note that this is *not* the standard time.Time -// binary encoding, because its implementation relies -// heavily on the internal representation used by the -// time package.) -func (mw *Writer) WriteTime(t time.Time) error { - t = t.UTC() - o, err := mw.require(15) - if err != nil { - return err - } - mw.buf[o] = mext8 - mw.buf[o+1] = 12 - mw.buf[o+2] = TimeExtension - putUnix(mw.buf[o+3:], t.Unix(), int32(t.Nanosecond())) - return nil -} - -// WriteIntf writes the concrete type of 'v'. -// WriteIntf will error if 'v' is not one of the following: -// - A bool, float, string, []byte, int, uint, or complex -// - A map of supported types (with string keys) -// - An array or slice of supported types -// - A pointer to a supported type -// - A type that satisfies the msgp.Encodable interface -// - A type that satisfies the msgp.Extension interface -func (mw *Writer) WriteIntf(v interface{}) error { - if v == nil { - return mw.WriteNil() - } - switch v := v.(type) { - - // preferred interfaces - - case Encodable: - return v.EncodeMsg(mw) - case Extension: - return mw.WriteExtension(v) - - // concrete types - - case bool: - return mw.WriteBool(v) - case float32: - return mw.WriteFloat32(v) - case float64: - return mw.WriteFloat64(v) - case complex64: - return mw.WriteComplex64(v) - case complex128: - return mw.WriteComplex128(v) - case uint8: - return mw.WriteUint8(v) - case uint16: - return mw.WriteUint16(v) - case uint32: - return mw.WriteUint32(v) - case uint64: - return mw.WriteUint64(v) - case uint: - return mw.WriteUint(v) - case int8: - return mw.WriteInt8(v) - case int16: - return mw.WriteInt16(v) - case int32: - return mw.WriteInt32(v) - case int64: - return mw.WriteInt64(v) - case int: - return mw.WriteInt(v) - case string: - return mw.WriteString(v) - case []byte: - return mw.WriteBytes(v) - case map[string]string: - return mw.WriteMapStrStr(v) - case map[string]interface{}: - return mw.WriteMapStrIntf(v) - case time.Time: - return mw.WriteTime(v) - } - - val := reflect.ValueOf(v) - if !isSupported(val.Kind()) || !val.IsValid() { - return fmt.Errorf("msgp: type %s not supported", val) - } - - switch val.Kind() { - case reflect.Ptr: - if val.IsNil() { - return mw.WriteNil() - } - return mw.WriteIntf(val.Elem().Interface()) - case reflect.Slice: - return mw.writeSlice(val) - case reflect.Map: - return mw.writeMap(val) - } - return &ErrUnsupportedType{val.Type()} -} - -func (mw *Writer) writeMap(v reflect.Value) (err error) { - if v.Type().Key().Kind() != reflect.String { - return errors.New("msgp: map keys must be strings") - } - ks := v.MapKeys() - err = mw.WriteMapHeader(uint32(len(ks))) - if err != nil { - return - } - for _, key := range ks { - val := v.MapIndex(key) - err = mw.WriteString(key.String()) - if err != nil { - return - } - err = mw.WriteIntf(val.Interface()) - if err != nil { - return - } - } - return -} - -func (mw *Writer) writeSlice(v reflect.Value) (err error) { - // is []byte - if v.Type().ConvertibleTo(btsType) { - return mw.WriteBytes(v.Bytes()) - } - - sz := uint32(v.Len()) - err = mw.WriteArrayHeader(sz) - if err != nil { - return - } - for i := uint32(0); i < sz; i++ { - err = mw.WriteIntf(v.Index(int(i)).Interface()) - if err != nil { - return - } - } - return -} - -func (mw *Writer) writeStruct(v reflect.Value) error { - if enc, ok := v.Interface().(Encodable); ok { - return enc.EncodeMsg(mw) - } - return fmt.Errorf("msgp: unsupported type: %s", v.Type()) -} - -func (mw *Writer) writeVal(v reflect.Value) error { - if !isSupported(v.Kind()) { - return fmt.Errorf("msgp: msgp/enc: type %q not supported", v.Type()) - } - - // shortcut for nil values - if v.IsNil() { - return mw.WriteNil() - } - switch v.Kind() { - case reflect.Bool: - return mw.WriteBool(v.Bool()) - - case reflect.Float32, reflect.Float64: - return mw.WriteFloat64(v.Float()) - - case reflect.Complex64, reflect.Complex128: - return mw.WriteComplex128(v.Complex()) - - case reflect.Int, reflect.Int16, reflect.Int32, reflect.Int64, reflect.Int8: - return mw.WriteInt64(v.Int()) - - case reflect.Interface, reflect.Ptr: - if v.IsNil() { - mw.WriteNil() - } - return mw.writeVal(v.Elem()) - - case reflect.Map: - return mw.writeMap(v) - - case reflect.Uint, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uint8: - return mw.WriteUint64(v.Uint()) - - case reflect.String: - return mw.WriteString(v.String()) - - case reflect.Slice, reflect.Array: - return mw.writeSlice(v) - - case reflect.Struct: - return mw.writeStruct(v) - - } - return fmt.Errorf("msgp: msgp/enc: type %q not supported", v.Type()) -} - -// is the reflect.Kind encodable? -func isSupported(k reflect.Kind) bool { - switch k { - case reflect.Func, reflect.Chan, reflect.Invalid, reflect.UnsafePointer: - return false - default: - return true - } -} - -// GuessSize guesses the size of the underlying -// value of 'i'. If the underlying value is not -// a simple builtin (or []byte), GuessSize defaults -// to 512. -func GuessSize(i interface{}) int { - if i == nil { - return NilSize - } - - switch i := i.(type) { - case Sizer: - return i.Msgsize() - case Extension: - return ExtensionPrefixSize + i.Len() - case float64: - return Float64Size - case float32: - return Float32Size - case uint8, uint16, uint32, uint64, uint: - return UintSize - case int8, int16, int32, int64, int: - return IntSize - case []byte: - return BytesPrefixSize + len(i) - case string: - return StringPrefixSize + len(i) - case complex64: - return Complex64Size - case complex128: - return Complex128Size - case bool: - return BoolSize - case map[string]interface{}: - s := MapHeaderSize - for key, val := range i { - s += StringPrefixSize + len(key) + GuessSize(val) - } - return s - case map[string]string: - s := MapHeaderSize - for key, val := range i { - s += 2*StringPrefixSize + len(key) + len(val) - } - return s - default: - return 512 - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/write_bytes.go b/vendor/github.com/tinylib/msgp/msgp/write_bytes.go deleted file mode 100644 index eaa03c4..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/write_bytes.go +++ /dev/null @@ -1,411 +0,0 @@ -package msgp - -import ( - "math" - "reflect" - "time" -) - -// ensure 'sz' extra bytes in 'b' btw len(b) and cap(b) -func ensure(b []byte, sz int) ([]byte, int) { - l := len(b) - c := cap(b) - if c-l < sz { - o := make([]byte, (2*c)+sz) // exponential growth - n := copy(o, b) - return o[:n+sz], n - } - return b[:l+sz], l -} - -// AppendMapHeader appends a map header with the -// given size to the slice -func AppendMapHeader(b []byte, sz uint32) []byte { - switch { - case sz <= 15: - return append(b, wfixmap(uint8(sz))) - - case sz <= math.MaxUint16: - o, n := ensure(b, 3) - prefixu16(o[n:], mmap16, uint16(sz)) - return o - - default: - o, n := ensure(b, 5) - prefixu32(o[n:], mmap32, sz) - return o - } -} - -// AppendArrayHeader appends an array header with -// the given size to the slice -func AppendArrayHeader(b []byte, sz uint32) []byte { - switch { - case sz <= 15: - return append(b, wfixarray(uint8(sz))) - - case sz <= math.MaxUint16: - o, n := ensure(b, 3) - prefixu16(o[n:], marray16, uint16(sz)) - return o - - default: - o, n := ensure(b, 5) - prefixu32(o[n:], marray32, sz) - return o - } -} - -// AppendNil appends a 'nil' byte to the slice -func AppendNil(b []byte) []byte { return append(b, mnil) } - -// AppendFloat64 appends a float64 to the slice -func AppendFloat64(b []byte, f float64) []byte { - o, n := ensure(b, Float64Size) - prefixu64(o[n:], mfloat64, math.Float64bits(f)) - return o -} - -// AppendFloat32 appends a float32 to the slice -func AppendFloat32(b []byte, f float32) []byte { - o, n := ensure(b, Float32Size) - prefixu32(o[n:], mfloat32, math.Float32bits(f)) - return o -} - -// AppendInt64 appends an int64 to the slice -func AppendInt64(b []byte, i int64) []byte { - if i >= 0 { - switch { - case i <= math.MaxInt8: - return append(b, wfixint(uint8(i))) - case i <= math.MaxInt16: - o, n := ensure(b, 3) - putMint16(o[n:], int16(i)) - return o - case i <= math.MaxInt32: - o, n := ensure(b, 5) - putMint32(o[n:], int32(i)) - return o - default: - o, n := ensure(b, 9) - putMint64(o[n:], i) - return o - } - } - switch { - case i >= -32: - return append(b, wnfixint(int8(i))) - case i >= math.MinInt8: - o, n := ensure(b, 2) - putMint8(o[n:], int8(i)) - return o - case i >= math.MinInt16: - o, n := ensure(b, 3) - putMint16(o[n:], int16(i)) - return o - case i >= math.MinInt32: - o, n := ensure(b, 5) - putMint32(o[n:], int32(i)) - return o - default: - o, n := ensure(b, 9) - putMint64(o[n:], i) - return o - } -} - -// AppendInt appends an int to the slice -func AppendInt(b []byte, i int) []byte { return AppendInt64(b, int64(i)) } - -// AppendInt8 appends an int8 to the slice -func AppendInt8(b []byte, i int8) []byte { return AppendInt64(b, int64(i)) } - -// AppendInt16 appends an int16 to the slice -func AppendInt16(b []byte, i int16) []byte { return AppendInt64(b, int64(i)) } - -// AppendInt32 appends an int32 to the slice -func AppendInt32(b []byte, i int32) []byte { return AppendInt64(b, int64(i)) } - -// AppendUint64 appends a uint64 to the slice -func AppendUint64(b []byte, u uint64) []byte { - switch { - case u <= (1<<7)-1: - return append(b, wfixint(uint8(u))) - - case u <= math.MaxUint8: - o, n := ensure(b, 2) - putMuint8(o[n:], uint8(u)) - return o - - case u <= math.MaxUint16: - o, n := ensure(b, 3) - putMuint16(o[n:], uint16(u)) - return o - - case u <= math.MaxUint32: - o, n := ensure(b, 5) - putMuint32(o[n:], uint32(u)) - return o - - default: - o, n := ensure(b, 9) - putMuint64(o[n:], u) - return o - - } -} - -// AppendUint appends a uint to the slice -func AppendUint(b []byte, u uint) []byte { return AppendUint64(b, uint64(u)) } - -// AppendUint8 appends a uint8 to the slice -func AppendUint8(b []byte, u uint8) []byte { return AppendUint64(b, uint64(u)) } - -// AppendByte is analogous to AppendUint8 -func AppendByte(b []byte, u byte) []byte { return AppendUint8(b, uint8(u)) } - -// AppendUint16 appends a uint16 to the slice -func AppendUint16(b []byte, u uint16) []byte { return AppendUint64(b, uint64(u)) } - -// AppendUint32 appends a uint32 to the slice -func AppendUint32(b []byte, u uint32) []byte { return AppendUint64(b, uint64(u)) } - -// AppendBytes appends bytes to the slice as MessagePack 'bin' data -func AppendBytes(b []byte, bts []byte) []byte { - sz := len(bts) - var o []byte - var n int - switch { - case sz <= math.MaxUint8: - o, n = ensure(b, 2+sz) - prefixu8(o[n:], mbin8, uint8(sz)) - n += 2 - case sz <= math.MaxUint16: - o, n = ensure(b, 3+sz) - prefixu16(o[n:], mbin16, uint16(sz)) - n += 3 - default: - o, n = ensure(b, 5+sz) - prefixu32(o[n:], mbin32, uint32(sz)) - n += 5 - } - return o[:n+copy(o[n:], bts)] -} - -// AppendBool appends a bool to the slice -func AppendBool(b []byte, t bool) []byte { - if t { - return append(b, mtrue) - } - return append(b, mfalse) -} - -// AppendString appends a string as a MessagePack 'str' to the slice -func AppendString(b []byte, s string) []byte { - sz := len(s) - var n int - var o []byte - switch { - case sz <= 31: - o, n = ensure(b, 1+sz) - o[n] = wfixstr(uint8(sz)) - n++ - case sz <= math.MaxUint8: - o, n = ensure(b, 2+sz) - prefixu8(o[n:], mstr8, uint8(sz)) - n += 2 - case sz <= math.MaxUint16: - o, n = ensure(b, 3+sz) - prefixu16(o[n:], mstr16, uint16(sz)) - n += 3 - default: - o, n = ensure(b, 5+sz) - prefixu32(o[n:], mstr32, uint32(sz)) - n += 5 - } - return o[:n+copy(o[n:], s)] -} - -// AppendStringFromBytes appends a []byte -// as a MessagePack 'str' to the slice 'b.' -func AppendStringFromBytes(b []byte, str []byte) []byte { - sz := len(str) - var n int - var o []byte - switch { - case sz <= 31: - o, n = ensure(b, 1+sz) - o[n] = wfixstr(uint8(sz)) - n++ - case sz <= math.MaxUint8: - o, n = ensure(b, 2+sz) - prefixu8(o[n:], mstr8, uint8(sz)) - n += 2 - case sz <= math.MaxUint16: - o, n = ensure(b, 3+sz) - prefixu16(o[n:], mstr16, uint16(sz)) - n += 3 - default: - o, n = ensure(b, 5+sz) - prefixu32(o[n:], mstr32, uint32(sz)) - n += 5 - } - return o[:n+copy(o[n:], str)] -} - -// AppendComplex64 appends a complex64 to the slice as a MessagePack extension -func AppendComplex64(b []byte, c complex64) []byte { - o, n := ensure(b, Complex64Size) - o[n] = mfixext8 - o[n+1] = Complex64Extension - big.PutUint32(o[n+2:], math.Float32bits(real(c))) - big.PutUint32(o[n+6:], math.Float32bits(imag(c))) - return o -} - -// AppendComplex128 appends a complex128 to the slice as a MessagePack extension -func AppendComplex128(b []byte, c complex128) []byte { - o, n := ensure(b, Complex128Size) - o[n] = mfixext16 - o[n+1] = Complex128Extension - big.PutUint64(o[n+2:], math.Float64bits(real(c))) - big.PutUint64(o[n+10:], math.Float64bits(imag(c))) - return o -} - -// AppendTime appends a time.Time to the slice as a MessagePack extension -func AppendTime(b []byte, t time.Time) []byte { - o, n := ensure(b, TimeSize) - t = t.UTC() - o[n] = mext8 - o[n+1] = 12 - o[n+2] = TimeExtension - putUnix(o[n+3:], t.Unix(), int32(t.Nanosecond())) - return o -} - -// AppendMapStrStr appends a map[string]string to the slice -// as a MessagePack map with 'str'-type keys and values -func AppendMapStrStr(b []byte, m map[string]string) []byte { - sz := uint32(len(m)) - b = AppendMapHeader(b, sz) - for key, val := range m { - b = AppendString(b, key) - b = AppendString(b, val) - } - return b -} - -// AppendMapStrIntf appends a map[string]interface{} to the slice -// as a MessagePack map with 'str'-type keys. -func AppendMapStrIntf(b []byte, m map[string]interface{}) ([]byte, error) { - sz := uint32(len(m)) - b = AppendMapHeader(b, sz) - var err error - for key, val := range m { - b = AppendString(b, key) - b, err = AppendIntf(b, val) - if err != nil { - return b, err - } - } - return b, nil -} - -// AppendIntf appends the concrete type of 'i' to the -// provided []byte. 'i' must be one of the following: -// - 'nil' -// - A bool, float, string, []byte, int, uint, or complex -// - A map[string]interface{} or map[string]string -// - A []T, where T is another supported type -// - A *T, where T is another supported type -// - A type that satisfieds the msgp.Marshaler interface -// - A type that satisfies the msgp.Extension interface -func AppendIntf(b []byte, i interface{}) ([]byte, error) { - if i == nil { - return AppendNil(b), nil - } - - // all the concrete types - // for which we have methods - switch i := i.(type) { - case Marshaler: - return i.MarshalMsg(b) - case Extension: - return AppendExtension(b, i) - case bool: - return AppendBool(b, i), nil - case float32: - return AppendFloat32(b, i), nil - case float64: - return AppendFloat64(b, i), nil - case complex64: - return AppendComplex64(b, i), nil - case complex128: - return AppendComplex128(b, i), nil - case string: - return AppendString(b, i), nil - case []byte: - return AppendBytes(b, i), nil - case int8: - return AppendInt8(b, i), nil - case int16: - return AppendInt16(b, i), nil - case int32: - return AppendInt32(b, i), nil - case int64: - return AppendInt64(b, i), nil - case int: - return AppendInt64(b, int64(i)), nil - case uint: - return AppendUint64(b, uint64(i)), nil - case uint8: - return AppendUint8(b, i), nil - case uint16: - return AppendUint16(b, i), nil - case uint32: - return AppendUint32(b, i), nil - case uint64: - return AppendUint64(b, i), nil - case time.Time: - return AppendTime(b, i), nil - case map[string]interface{}: - return AppendMapStrIntf(b, i) - case map[string]string: - return AppendMapStrStr(b, i), nil - case []interface{}: - b = AppendArrayHeader(b, uint32(len(i))) - var err error - for _, k := range i { - b, err = AppendIntf(b, k) - if err != nil { - return b, err - } - } - return b, nil - } - - var err error - v := reflect.ValueOf(i) - switch v.Kind() { - case reflect.Array, reflect.Slice: - l := v.Len() - b = AppendArrayHeader(b, uint32(l)) - for i := 0; i < l; i++ { - b, err = AppendIntf(b, v.Index(i).Interface()) - if err != nil { - return b, err - } - } - return b, nil - case reflect.Ptr: - if v.IsNil() { - return AppendNil(b), err - } - b, err = AppendIntf(b, v.Elem().Interface()) - return b, err - default: - return b, &ErrUnsupportedType{T: v.Type()} - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/write_bytes_test.go b/vendor/github.com/tinylib/msgp/msgp/write_bytes_test.go deleted file mode 100644 index fa0b7d5..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/write_bytes_test.go +++ /dev/null @@ -1,319 +0,0 @@ -package msgp - -import ( - "bytes" - "math" - "testing" - "time" -) - -func TestIssue116(t *testing.T) { - data := AppendInt64(nil, math.MinInt64) - i, _, err := ReadInt64Bytes(data) - if err != nil { - t.Fatal(err) - } - if i != math.MinInt64 { - t.Errorf("put %d in and got %d out", int64(math.MinInt64), i) - } - - var buf bytes.Buffer - - w := NewWriter(&buf) - w.WriteInt64(math.MinInt64) - w.Flush() - i, err = NewReader(&buf).ReadInt64() - if err != nil { - t.Fatal(err) - } - if i != math.MinInt64 { - t.Errorf("put %d in and got %d out", int64(math.MinInt64), i) - } -} - -func TestAppendMapHeader(t *testing.T) { - szs := []uint32{0, 1, uint32(tint8), uint32(tint16), tuint32} - var buf bytes.Buffer - en := NewWriter(&buf) - - var bts []byte - for _, sz := range szs { - buf.Reset() - en.WriteMapHeader(sz) - en.Flush() - bts = AppendMapHeader(bts[0:0], sz) - - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for size %d, encoder wrote %q and append wrote %q", sz, buf.Bytes(), bts) - } - } -} - -func BenchmarkAppendMapHeader(b *testing.B) { - buf := make([]byte, 0, 9) - N := b.N / 4 - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < N; i++ { - AppendMapHeader(buf[:0], 0) - AppendMapHeader(buf[:0], uint32(tint8)) - AppendMapHeader(buf[:0], tuint16) - AppendMapHeader(buf[:0], tuint32) - } -} - -func TestAppendArrayHeader(t *testing.T) { - szs := []uint32{0, 1, uint32(tint8), uint32(tint16), tuint32} - var buf bytes.Buffer - en := NewWriter(&buf) - - var bts []byte - for _, sz := range szs { - buf.Reset() - en.WriteArrayHeader(sz) - en.Flush() - bts = AppendArrayHeader(bts[0:0], sz) - - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for size %d, encoder wrote %q and append wrote %q", sz, buf.Bytes(), bts) - } - } -} - -func BenchmarkAppendArrayHeader(b *testing.B) { - buf := make([]byte, 0, 9) - N := b.N / 4 - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < N; i++ { - AppendArrayHeader(buf[:0], 0) - AppendArrayHeader(buf[:0], uint32(tint8)) - AppendArrayHeader(buf[:0], tuint16) - AppendArrayHeader(buf[:0], tuint32) - } -} - -func TestAppendNil(t *testing.T) { - var bts []byte - bts = AppendNil(bts[0:0]) - if bts[0] != mnil { - t.Fatal("bts[0] is not 'nil'") - } -} - -func TestAppendFloat64(t *testing.T) { - f := float64(3.14159) - var buf bytes.Buffer - en := NewWriter(&buf) - - var bts []byte - en.WriteFloat64(f) - en.Flush() - bts = AppendFloat64(bts[0:0], f) - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for float %f, encoder wrote %q; append wrote %q", f, buf.Bytes(), bts) - } -} - -func BenchmarkAppendFloat64(b *testing.B) { - f := float64(3.14159) - buf := make([]byte, 0, 9) - b.SetBytes(9) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - AppendFloat64(buf[0:0], f) - } -} - -func TestAppendFloat32(t *testing.T) { - f := float32(3.14159) - var buf bytes.Buffer - en := NewWriter(&buf) - - var bts []byte - en.WriteFloat32(f) - en.Flush() - bts = AppendFloat32(bts[0:0], f) - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for float %f, encoder wrote %q; append wrote %q", f, buf.Bytes(), bts) - } -} - -func BenchmarkAppendFloat32(b *testing.B) { - f := float32(3.14159) - buf := make([]byte, 0, 5) - b.SetBytes(5) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - AppendFloat32(buf[0:0], f) - } -} - -func TestAppendInt64(t *testing.T) { - is := []int64{0, 1, -5, -50, int64(tint16), int64(tint32), int64(tint64)} - var buf bytes.Buffer - en := NewWriter(&buf) - - var bts []byte - for _, i := range is { - buf.Reset() - en.WriteInt64(i) - en.Flush() - bts = AppendInt64(bts[0:0], i) - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for int64 %d, encoder wrote %q; append wrote %q", i, buf.Bytes(), bts) - } - } -} - -func BenchmarkAppendInt64(b *testing.B) { - is := []int64{0, 1, -5, -50, int64(tint16), int64(tint32), int64(tint64)} - l := len(is) - buf := make([]byte, 0, 9) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - AppendInt64(buf[0:0], is[i%l]) - } -} - -func TestAppendUint64(t *testing.T) { - us := []uint64{0, 1, uint64(tuint16), uint64(tuint32), tuint64} - var buf bytes.Buffer - en := NewWriter(&buf) - var bts []byte - - for _, u := range us { - buf.Reset() - en.WriteUint64(u) - en.Flush() - bts = AppendUint64(bts[0:0], u) - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for uint64 %d, encoder wrote %q; append wrote %q", u, buf.Bytes(), bts) - } - } -} - -func BenchmarkAppendUint64(b *testing.B) { - us := []uint64{0, 1, 15, uint64(tuint16), uint64(tuint32), tuint64} - buf := make([]byte, 0, 9) - b.ReportAllocs() - b.ResetTimer() - l := len(us) - for i := 0; i < b.N; i++ { - AppendUint64(buf[0:0], us[i%l]) - } -} - -func TestAppendBytes(t *testing.T) { - sizes := []int{0, 1, 225, int(tuint32)} - var buf bytes.Buffer - en := NewWriter(&buf) - var bts []byte - - for _, sz := range sizes { - buf.Reset() - b := RandBytes(sz) - en.WriteBytes(b) - en.Flush() - bts = AppendBytes(b[0:0], b) - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for bytes of length %d, encoder wrote %d bytes and append wrote %d bytes", sz, buf.Len(), len(bts)) - } - } -} - -func benchappendBytes(size uint32, b *testing.B) { - bts := RandBytes(int(size)) - buf := make([]byte, 0, len(bts)+5) - b.SetBytes(int64(len(bts) + 5)) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - AppendBytes(buf[0:0], bts) - } -} - -func BenchmarkAppend16Bytes(b *testing.B) { benchappendBytes(16, b) } - -func BenchmarkAppend256Bytes(b *testing.B) { benchappendBytes(256, b) } - -func BenchmarkAppend2048Bytes(b *testing.B) { benchappendBytes(2048, b) } - -func TestAppendString(t *testing.T) { - sizes := []int{0, 1, 225, int(tuint32)} - var buf bytes.Buffer - en := NewWriter(&buf) - var bts []byte - - for _, sz := range sizes { - buf.Reset() - s := string(RandBytes(sz)) - en.WriteString(s) - en.Flush() - bts = AppendString(bts[0:0], s) - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for string of length %d, encoder wrote %d bytes and append wrote %d bytes", sz, buf.Len(), len(bts)) - t.Errorf("WriteString prefix: %x", buf.Bytes()[0:5]) - t.Errorf("Appendstring prefix: %x", bts[0:5]) - } - } -} - -func benchappendString(size uint32, b *testing.B) { - str := string(RandBytes(int(size))) - buf := make([]byte, 0, len(str)+5) - b.SetBytes(int64(len(str) + 5)) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - AppendString(buf[0:0], str) - } -} - -func BenchmarkAppend16String(b *testing.B) { benchappendString(16, b) } - -func BenchmarkAppend256String(b *testing.B) { benchappendString(256, b) } - -func BenchmarkAppend2048String(b *testing.B) { benchappendString(2048, b) } - -func TestAppendBool(t *testing.T) { - vs := []bool{true, false} - var buf bytes.Buffer - en := NewWriter(&buf) - var bts []byte - - for _, v := range vs { - buf.Reset() - en.WriteBool(v) - en.Flush() - bts = AppendBool(bts[0:0], v) - if !bytes.Equal(buf.Bytes(), bts) { - t.Errorf("for %t, encoder wrote %q and append wrote %q", v, buf.Bytes(), bts) - } - } -} - -func BenchmarkAppendBool(b *testing.B) { - vs := []bool{true, false} - buf := make([]byte, 0, 1) - b.SetBytes(1) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - AppendBool(buf[0:0], vs[i%2]) - } -} - -func BenchmarkAppendTime(b *testing.B) { - t := time.Now() - b.SetBytes(15) - buf := make([]byte, 0, 15) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - AppendTime(buf[0:0], t) - } -} diff --git a/vendor/github.com/tinylib/msgp/msgp/write_test.go b/vendor/github.com/tinylib/msgp/msgp/write_test.go deleted file mode 100644 index c5e97fe..0000000 --- a/vendor/github.com/tinylib/msgp/msgp/write_test.go +++ /dev/null @@ -1,405 +0,0 @@ -package msgp - -import ( - "bytes" - "math" - "math/rand" - "testing" - "time" -) - -var ( - tint8 int8 = 126 // cannot be most fix* types - tint16 int16 = 150 // cannot be int8 - tint32 int32 = math.MaxInt16 + 100 // cannot be int16 - tint64 int64 = math.MaxInt32 + 100 // cannot be int32 - tuint16 uint32 = 300 // cannot be uint8 - tuint32 uint32 = math.MaxUint16 + 100 // cannot be uint16 - tuint64 uint64 = math.MaxUint32 + 100 // cannot be uint32 -) - -func RandBytes(sz int) []byte { - out := make([]byte, sz) - for i := range out { - out[i] = byte(rand.Int63n(math.MaxInt64) % 256) - } - return out -} - -func TestWriteMapHeader(t *testing.T) { - tests := []struct { - Sz uint32 - Outbytes []byte - }{ - {0, []byte{mfixmap}}, - {1, []byte{mfixmap | byte(1)}}, - {100, []byte{mmap16, byte(uint16(100) >> 8), byte(uint16(100))}}, - {tuint32, - []byte{mmap32, - byte(tuint32 >> 24), - byte(tuint32 >> 16), - byte(tuint32 >> 8), - byte(tuint32), - }, - }, - } - - var buf bytes.Buffer - var err error - wr := NewWriter(&buf) - for _, test := range tests { - buf.Reset() - err = wr.WriteMapHeader(test.Sz) - if err != nil { - t.Error(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - if !bytes.Equal(buf.Bytes(), test.Outbytes) { - t.Errorf("Expected bytes %x; got %x", test.Outbytes, buf.Bytes()) - } - } -} - -func BenchmarkWriteMapHeader(b *testing.B) { - wr := NewWriter(Nowhere) - N := b.N / 4 - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < N; i++ { - wr.WriteMapHeader(0) - wr.WriteMapHeader(8) - wr.WriteMapHeader(tuint16) - wr.WriteMapHeader(tuint32) - } -} - -func TestWriteArrayHeader(t *testing.T) { - tests := []struct { - Sz uint32 - Outbytes []byte - }{ - {0, []byte{mfixarray}}, - {1, []byte{mfixarray | byte(1)}}, - {tuint16, []byte{marray16, byte(tuint16 >> 8), byte(tuint16)}}, - {tuint32, []byte{marray32, byte(tuint32 >> 24), byte(tuint32 >> 16), byte(tuint32 >> 8), byte(tuint32)}}, - } - - var buf bytes.Buffer - var err error - wr := NewWriter(&buf) - for _, test := range tests { - buf.Reset() - err = wr.WriteArrayHeader(test.Sz) - if err != nil { - t.Error(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - if !bytes.Equal(buf.Bytes(), test.Outbytes) { - t.Errorf("Expected bytes %x; got %x", test.Outbytes, buf.Bytes()) - } - } -} - -func TestReadWriteStringHeader(t *testing.T) { - sizes := []uint32{0, 5, 8, 19, 150, tuint16, tuint32} - var buf bytes.Buffer - var err error - wr := NewWriter(&buf) - for _, sz := range sizes { - buf.Reset() - err = wr.WriteStringHeader(sz) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - var nsz uint32 - nsz, err = NewReader(&buf).ReadStringHeader() - if err != nil { - t.Fatal(err) - } - if nsz != sz { - t.Errorf("put in size %d but got out size %d", sz, nsz) - } - } -} - -func TestReadWriteBytesHeader(t *testing.T) { - sizes := []uint32{0, 5, 8, 19, 150, tuint16, tuint32} - var buf bytes.Buffer - var err error - wr := NewWriter(&buf) - for _, sz := range sizes { - buf.Reset() - err = wr.WriteBytesHeader(sz) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - var nsz uint32 - nsz, err = NewReader(&buf).ReadBytesHeader() - if err != nil { - t.Fatal(err) - } - if nsz != sz { - t.Errorf("put in size %d but got out size %d", sz, nsz) - } - } -} - -func BenchmarkWriteArrayHeader(b *testing.B) { - wr := NewWriter(Nowhere) - N := b.N / 4 - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < N; i++ { - wr.WriteArrayHeader(0) - wr.WriteArrayHeader(16) - wr.WriteArrayHeader(tuint16) - wr.WriteArrayHeader(tuint32) - } -} - -func TestWriteNil(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - - err := wr.WriteNil() - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - - bts := buf.Bytes() - if bts[0] != mnil { - t.Errorf("Expected %x; wrote %x", mnil, bts[0]) - } -} - -func TestWriteFloat64(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - - for i := 0; i < 10000; i++ { - buf.Reset() - flt := (rand.Float64() - 0.5) * math.MaxFloat64 - err := wr.WriteFloat64(flt) - if err != nil { - t.Errorf("Error with %f: %s", flt, err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - - bts := buf.Bytes() - - if bts[0] != mfloat64 { - t.Errorf("Leading byte was %x and not %x", bts[0], mfloat64) - } - } -} - -func BenchmarkWriteFloat64(b *testing.B) { - f := rand.Float64() - wr := NewWriter(Nowhere) - b.SetBytes(9) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - wr.WriteFloat64(f) - } -} - -func TestWriteFloat32(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - - for i := 0; i < 10000; i++ { - buf.Reset() - flt := (rand.Float32() - 0.5) * math.MaxFloat32 - err := wr.WriteFloat32(flt) - if err != nil { - t.Errorf("Error with %f: %s", flt, err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - - bts := buf.Bytes() - - if bts[0] != mfloat32 { - t.Errorf("Leading byte was %x and not %x", bts[0], mfloat64) - } - } -} - -func BenchmarkWriteFloat32(b *testing.B) { - f := rand.Float32() - wr := NewWriter(Nowhere) - b.SetBytes(5) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - wr.WriteFloat32(f) - } -} - -func TestWriteInt64(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - - for i := 0; i < 10000; i++ { - buf.Reset() - - num := (rand.Int63n(math.MaxInt64)) - (math.MaxInt64 / 2) - - err := wr.WriteInt64(num) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - - if buf.Len() > 9 { - t.Errorf("buffer length should be <= 9; it's %d", buf.Len()) - } - } -} - -func BenchmarkWriteInt64(b *testing.B) { - wr := NewWriter(Nowhere) - b.SetBytes(9) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - wr.WriteInt64(int64(tint64)) - } -} - -func TestWriteUint64(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - - for i := 0; i < 10000; i++ { - buf.Reset() - - num := uint64(rand.Int63n(math.MaxInt64)) - - err := wr.WriteUint64(num) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - if buf.Len() > 9 { - t.Errorf("buffer length should be <= 9; it's %d", buf.Len()) - } - } -} - -func BenchmarkWriteUint64(b *testing.B) { - wr := NewWriter(Nowhere) - b.SetBytes(9) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - wr.WriteUint64(uint64(tuint64)) - } -} - -func TestWriteBytes(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - sizes := []int{0, 1, 225, int(tuint32)} - - for _, size := range sizes { - buf.Reset() - bts := RandBytes(size) - - err := wr.WriteBytes(bts) - if err != nil { - t.Fatal(err) - } - - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - - if buf.Len() < len(bts) { - t.Errorf("somehow, %d bytes were encoded in %d bytes", len(bts), buf.Len()) - } - } -} - -func benchwrBytes(size uint32, b *testing.B) { - bts := RandBytes(int(size)) - wr := NewWriter(Nowhere) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - wr.WriteBytes(bts) - } -} - -func BenchmarkWrite16Bytes(b *testing.B) { benchwrBytes(16, b) } - -func BenchmarkWrite256Bytes(b *testing.B) { benchwrBytes(256, b) } - -func BenchmarkWrite2048Bytes(b *testing.B) { benchwrBytes(2048, b) } - -func TestWriteTime(t *testing.T) { - var buf bytes.Buffer - wr := NewWriter(&buf) - tm := time.Now() - err := wr.WriteTime(tm) - if err != nil { - t.Fatal(err) - } - err = wr.Flush() - if err != nil { - t.Fatal(err) - } - if buf.Len() != 15 { - t.Errorf("expected time.Time to be %d bytes; got %d", 15, buf.Len()) - } - - newt, err := NewReader(&buf).ReadTime() - if err != nil { - t.Fatal(err) - } - if !newt.Equal(tm) { - t.Errorf("in/out not equal; %s in and %s out", tm, newt) - } -} - -func BenchmarkWriteTime(b *testing.B) { - t := time.Now() - wr := NewWriter(Nowhere) - b.SetBytes(15) - b.ReportAllocs() - b.ResetTimer() - for i := 0; i < b.N; i++ { - wr.WriteTime(t) - } -} diff --git a/vendor/github.com/tinylib/msgp/parse/directives.go b/vendor/github.com/tinylib/msgp/parse/directives.go deleted file mode 100644 index 73e441e..0000000 --- a/vendor/github.com/tinylib/msgp/parse/directives.go +++ /dev/null @@ -1,130 +0,0 @@ -package parse - -import ( - "fmt" - "go/ast" - "strings" - - "github.com/tinylib/msgp/gen" -) - -const linePrefix = "//msgp:" - -// func(args, fileset) -type directive func([]string, *FileSet) error - -// func(passName, args, printer) -type passDirective func(gen.Method, []string, *gen.Printer) error - -// map of all recognized directives -// -// to add a directive, define a func([]string, *FileSet) error -// and then add it to this list. -var directives = map[string]directive{ - "shim": applyShim, - "ignore": ignore, - "tuple": astuple, -} - -var passDirectives = map[string]passDirective{ - "ignore": passignore, -} - -func passignore(m gen.Method, text []string, p *gen.Printer) error { - pushstate(m.String()) - for _, a := range text { - p.ApplyDirective(m, gen.IgnoreTypename(a)) - infof("ignoring %s\n", a) - } - popstate() - return nil -} - -// find all comment lines that begin with //msgp: -func yieldComments(c []*ast.CommentGroup) []string { - var out []string - for _, cg := range c { - for _, line := range cg.List { - if strings.HasPrefix(line.Text, linePrefix) { - out = append(out, strings.TrimPrefix(line.Text, linePrefix)) - } - } - } - return out -} - -//msgp:shim {Type} as:{Newtype} using:{toFunc/fromFunc} mode:{Mode} -func applyShim(text []string, f *FileSet) error { - if len(text) < 4 || len(text) > 5 { - return fmt.Errorf("shim directive should have 3 or 4 arguments; found %d", len(text)-1) - } - - name := text[1] - be := gen.Ident(strings.TrimPrefix(strings.TrimSpace(text[2]), "as:")) // parse as::{base} - if name[0] == '*' { - name = name[1:] - be.Needsref(true) - } - be.Alias(name) - - usestr := strings.TrimPrefix(strings.TrimSpace(text[3]), "using:") // parse using::{method/method} - - methods := strings.Split(usestr, "/") - if len(methods) != 2 { - return fmt.Errorf("expected 2 using::{} methods; found %d (%q)", len(methods), text[3]) - } - - be.ShimToBase = methods[0] - be.ShimFromBase = methods[1] - - if len(text) == 5 { - modestr := strings.TrimPrefix(strings.TrimSpace(text[4]), "mode:") // parse mode::{mode} - switch modestr { - case "cast": - be.ShimMode = gen.Cast - case "convert": - be.ShimMode = gen.Convert - default: - return fmt.Errorf("invalid shim mode; found %s, expected 'cast' or 'convert", modestr) - } - } - - infof("%s -> %s\n", name, be.Value.String()) - f.findShim(name, be) - - return nil -} - -//msgp:ignore {TypeA} {TypeB}... -func ignore(text []string, f *FileSet) error { - if len(text) < 2 { - return nil - } - for _, item := range text[1:] { - name := strings.TrimSpace(item) - if _, ok := f.Identities[name]; ok { - delete(f.Identities, name) - infof("ignoring %s\n", name) - } - } - return nil -} - -//msgp:tuple {TypeA} {TypeB}... -func astuple(text []string, f *FileSet) error { - if len(text) < 2 { - return nil - } - for _, item := range text[1:] { - name := strings.TrimSpace(item) - if el, ok := f.Identities[name]; ok { - if st, ok := el.(*gen.Struct); ok { - st.AsTuple = true - infoln(name) - } else { - warnf("%s: only structs can be tuples\n", name) - } - } - } - return nil -} diff --git a/vendor/github.com/tinylib/msgp/parse/getast.go b/vendor/github.com/tinylib/msgp/parse/getast.go deleted file mode 100644 index 871020d..0000000 --- a/vendor/github.com/tinylib/msgp/parse/getast.go +++ /dev/null @@ -1,587 +0,0 @@ -package parse - -import ( - "fmt" - "go/ast" - "go/parser" - "go/token" - "os" - "reflect" - "sort" - "strings" - - "github.com/tinylib/msgp/gen" - "github.com/ttacon/chalk" -) - -// A FileSet is the in-memory representation of a -// parsed file. -type FileSet struct { - Package string // package name - Specs map[string]ast.Expr // type specs in file - Identities map[string]gen.Elem // processed from specs - Directives []string // raw preprocessor directives - Imports []*ast.ImportSpec // imports -} - -// File parses a file at the relative path -// provided and produces a new *FileSet. -// If you pass in a path to a directory, the entire -// directory will be parsed. -// If unexport is false, only exported identifiers are included in the FileSet. -// If the resulting FileSet would be empty, an error is returned. -func File(name string, unexported bool) (*FileSet, error) { - pushstate(name) - defer popstate() - fs := &FileSet{ - Specs: make(map[string]ast.Expr), - Identities: make(map[string]gen.Elem), - } - - fset := token.NewFileSet() - finfo, err := os.Stat(name) - if err != nil { - return nil, err - } - if finfo.IsDir() { - pkgs, err := parser.ParseDir(fset, name, nil, parser.ParseComments) - if err != nil { - return nil, err - } - if len(pkgs) != 1 { - return nil, fmt.Errorf("multiple packages in directory: %s", name) - } - var one *ast.Package - for _, nm := range pkgs { - one = nm - break - } - fs.Package = one.Name - for _, fl := range one.Files { - pushstate(fl.Name.Name) - fs.Directives = append(fs.Directives, yieldComments(fl.Comments)...) - if !unexported { - ast.FileExports(fl) - } - fs.getTypeSpecs(fl) - popstate() - } - } else { - f, err := parser.ParseFile(fset, name, nil, parser.ParseComments) - if err != nil { - return nil, err - } - fs.Package = f.Name.Name - fs.Directives = yieldComments(f.Comments) - if !unexported { - ast.FileExports(f) - } - fs.getTypeSpecs(f) - } - - if len(fs.Specs) == 0 { - return nil, fmt.Errorf("no definitions in %s", name) - } - - fs.process() - fs.applyDirectives() - fs.propInline() - - return fs, nil -} - -// applyDirectives applies all of the directives that -// are known to the parser. additional method-specific -// directives remain in f.Directives -func (f *FileSet) applyDirectives() { - newdirs := make([]string, 0, len(f.Directives)) - for _, d := range f.Directives { - chunks := strings.Split(d, " ") - if len(chunks) > 0 { - if fn, ok := directives[chunks[0]]; ok { - pushstate(chunks[0]) - err := fn(chunks, f) - if err != nil { - warnln(err.Error()) - } - popstate() - } else { - newdirs = append(newdirs, d) - } - } - } - f.Directives = newdirs -} - -// A linkset is a graph of unresolved -// identities. -// -// Since gen.Ident can only represent -// one level of type indirection (e.g. Foo -> uint8), -// type declarations like `type Foo Bar` -// aren't resolve-able until we've processed -// everything else. -// -// The goal of this dependency resolution -// is to distill the type declaration -// into just one level of indirection. -// In other words, if we have: -// -// type A uint64 -// type B A -// type C B -// type D C -// -// ... then we want to end up -// figuring out that D is just a uint64. -type linkset map[string]*gen.BaseElem - -func (f *FileSet) resolve(ls linkset) { - progress := true - for progress && len(ls) > 0 { - progress = false - for name, elem := range ls { - real, ok := f.Identities[elem.TypeName()] - if ok { - // copy the old type descriptor, - // alias it to the new value, - // and insert it into the resolved - // identities list - progress = true - nt := real.Copy() - nt.Alias(name) - f.Identities[name] = nt - delete(ls, name) - } - } - } - - // what's left can't be resolved - for name, elem := range ls { - warnf("couldn't resolve type %s (%s)\n", name, elem.TypeName()) - } -} - -// process takes the contents of f.Specs and -// uses them to populate f.Identities -func (f *FileSet) process() { - - deferred := make(linkset) -parse: - for name, def := range f.Specs { - pushstate(name) - el := f.parseExpr(def) - if el == nil { - warnln("failed to parse") - popstate() - continue parse - } - // push unresolved identities into - // the graph of links and resolve after - // we've handled every possible named type. - if be, ok := el.(*gen.BaseElem); ok && be.Value == gen.IDENT { - deferred[name] = be - popstate() - continue parse - } - el.Alias(name) - f.Identities[name] = el - popstate() - } - - if len(deferred) > 0 { - f.resolve(deferred) - } -} - -func strToMethod(s string) gen.Method { - switch s { - case "encode": - return gen.Encode - case "decode": - return gen.Decode - case "test": - return gen.Test - case "size": - return gen.Size - case "marshal": - return gen.Marshal - case "unmarshal": - return gen.Unmarshal - default: - return 0 - } -} - -func (f *FileSet) applyDirs(p *gen.Printer) { - // apply directives of the form - // - // //msgp:encode ignore {{TypeName}} - // -loop: - for _, d := range f.Directives { - chunks := strings.Split(d, " ") - if len(chunks) > 1 { - for i := range chunks { - chunks[i] = strings.TrimSpace(chunks[i]) - } - m := strToMethod(chunks[0]) - if m == 0 { - warnf("unknown pass name: %q\n", chunks[0]) - continue loop - } - if fn, ok := passDirectives[chunks[1]]; ok { - pushstate(chunks[1]) - err := fn(m, chunks[2:], p) - if err != nil { - warnf("error applying directive: %s\n", err) - } - popstate() - } else { - warnf("unrecognized directive %q\n", chunks[1]) - } - } else { - warnf("empty directive: %q\n", d) - } - } -} - -func (f *FileSet) PrintTo(p *gen.Printer) error { - f.applyDirs(p) - names := make([]string, 0, len(f.Identities)) - for name := range f.Identities { - names = append(names, name) - } - sort.Strings(names) - for _, name := range names { - el := f.Identities[name] - el.SetVarname("z") - pushstate(el.TypeName()) - err := p.Print(el) - popstate() - if err != nil { - return err - } - } - return nil -} - -// getTypeSpecs extracts all of the *ast.TypeSpecs in the file -// into fs.Identities, but does not set the actual element -func (fs *FileSet) getTypeSpecs(f *ast.File) { - - // collect all imports... - fs.Imports = append(fs.Imports, f.Imports...) - - // check all declarations... - for i := range f.Decls { - - // for GenDecls... - if g, ok := f.Decls[i].(*ast.GenDecl); ok { - - // and check the specs... - for _, s := range g.Specs { - - // for ast.TypeSpecs.... - if ts, ok := s.(*ast.TypeSpec); ok { - switch ts.Type.(type) { - - // this is the list of parse-able - // type specs - case *ast.StructType, - *ast.ArrayType, - *ast.StarExpr, - *ast.MapType, - *ast.Ident: - fs.Specs[ts.Name.Name] = ts.Type - - } - } - } - } - } -} - -func fieldName(f *ast.Field) string { - switch len(f.Names) { - case 0: - return stringify(f.Type) - case 1: - return f.Names[0].Name - default: - return f.Names[0].Name + " (and others)" - } -} - -func (fs *FileSet) parseFieldList(fl *ast.FieldList) []gen.StructField { - if fl == nil || fl.NumFields() == 0 { - return nil - } - out := make([]gen.StructField, 0, fl.NumFields()) - for _, field := range fl.List { - pushstate(fieldName(field)) - fds := fs.getField(field) - if len(fds) > 0 { - out = append(out, fds...) - } else { - warnln("ignored.") - } - popstate() - } - return out -} - -// translate *ast.Field into []gen.StructField -func (fs *FileSet) getField(f *ast.Field) []gen.StructField { - sf := make([]gen.StructField, 1) - var extension bool - // parse tag; otherwise field name is field tag - if f.Tag != nil { - body := reflect.StructTag(strings.Trim(f.Tag.Value, "`")).Get("msg") - tags := strings.Split(body, ",") - if len(tags) == 2 && tags[1] == "extension" { - extension = true - } - // ignore "-" fields - if tags[0] == "-" { - return nil - } - sf[0].FieldTag = tags[0] - sf[0].RawTag = f.Tag.Value - } - - ex := fs.parseExpr(f.Type) - if ex == nil { - return nil - } - - // parse field name - switch len(f.Names) { - case 0: - sf[0].FieldName = embedded(f.Type) - case 1: - sf[0].FieldName = f.Names[0].Name - default: - // this is for a multiple in-line declaration, - // e.g. type A struct { One, Two int } - sf = sf[0:0] - for _, nm := range f.Names { - sf = append(sf, gen.StructField{ - FieldTag: nm.Name, - FieldName: nm.Name, - FieldElem: ex.Copy(), - }) - } - return sf - } - sf[0].FieldElem = ex - if sf[0].FieldTag == "" { - sf[0].FieldTag = sf[0].FieldName - } - - // validate extension - if extension { - switch ex := ex.(type) { - case *gen.Ptr: - if b, ok := ex.Value.(*gen.BaseElem); ok { - b.Value = gen.Ext - } else { - warnln("couldn't cast to extension.") - return nil - } - case *gen.BaseElem: - ex.Value = gen.Ext - default: - warnln("couldn't cast to extension.") - return nil - } - } - return sf -} - -// extract embedded field name -// -// so, for a struct like -// -// type A struct { -// io.Writer -// } -// -// we want "Writer" -func embedded(f ast.Expr) string { - switch f := f.(type) { - case *ast.Ident: - return f.Name - case *ast.StarExpr: - return embedded(f.X) - case *ast.SelectorExpr: - return f.Sel.Name - default: - // other possibilities are disallowed - return "" - } -} - -// stringify a field type name -func stringify(e ast.Expr) string { - switch e := e.(type) { - case *ast.Ident: - return e.Name - case *ast.StarExpr: - return "*" + stringify(e.X) - case *ast.SelectorExpr: - return stringify(e.X) + "." + e.Sel.Name - case *ast.ArrayType: - if e.Len == nil { - return "[]" + stringify(e.Elt) - } - return fmt.Sprintf("[%s]%s", stringify(e.Len), stringify(e.Elt)) - case *ast.InterfaceType: - if e.Methods == nil || e.Methods.NumFields() == 0 { - return "interface{}" - } - } - return "" -} - -// recursively translate ast.Expr to gen.Elem; nil means type not supported -// expected input types: -// - *ast.MapType (map[T]J) -// - *ast.Ident (name) -// - *ast.ArrayType ([(sz)]T) -// - *ast.StarExpr (*T) -// - *ast.StructType (struct {}) -// - *ast.SelectorExpr (a.B) -// - *ast.InterfaceType (interface {}) -func (fs *FileSet) parseExpr(e ast.Expr) gen.Elem { - switch e := e.(type) { - - case *ast.MapType: - if k, ok := e.Key.(*ast.Ident); ok && k.Name == "string" { - if in := fs.parseExpr(e.Value); in != nil { - return &gen.Map{Value: in} - } - } - return nil - - case *ast.Ident: - b := gen.Ident(e.Name) - - // work to resove this expression - // can be done later, once we've resolved - // everything else. - if b.Value == gen.IDENT { - if _, ok := fs.Specs[e.Name]; !ok { - warnf("non-local identifier: %s\n", e.Name) - } - } - return b - - case *ast.ArrayType: - - // special case for []byte - if e.Len == nil { - if i, ok := e.Elt.(*ast.Ident); ok && i.Name == "byte" { - return &gen.BaseElem{Value: gen.Bytes} - } - } - - // return early if we don't know - // what the slice element type is - els := fs.parseExpr(e.Elt) - if els == nil { - return nil - } - - // array and not a slice - if e.Len != nil { - switch s := e.Len.(type) { - case *ast.BasicLit: - return &gen.Array{ - Size: s.Value, - Els: els, - } - - case *ast.Ident: - return &gen.Array{ - Size: s.String(), - Els: els, - } - - case *ast.SelectorExpr: - return &gen.Array{ - Size: stringify(s), - Els: els, - } - - default: - return nil - } - } - return &gen.Slice{Els: els} - - case *ast.StarExpr: - if v := fs.parseExpr(e.X); v != nil { - return &gen.Ptr{Value: v} - } - return nil - - case *ast.StructType: - return &gen.Struct{Fields: fs.parseFieldList(e.Fields)} - - case *ast.SelectorExpr: - return gen.Ident(stringify(e)) - - case *ast.InterfaceType: - // support `interface{}` - if len(e.Methods.List) == 0 { - return &gen.BaseElem{Value: gen.Intf} - } - return nil - - default: // other types not supported - return nil - } -} - -func infof(s string, v ...interface{}) { - pushstate(s) - fmt.Printf(chalk.Green.Color(strings.Join(logctx, ": ")), v...) - popstate() -} - -func infoln(s string) { - pushstate(s) - fmt.Println(chalk.Green.Color(strings.Join(logctx, ": "))) - popstate() -} - -func warnf(s string, v ...interface{}) { - pushstate(s) - fmt.Printf(chalk.Yellow.Color(strings.Join(logctx, ": ")), v...) - popstate() -} - -func warnln(s string) { - pushstate(s) - fmt.Println(chalk.Yellow.Color(strings.Join(logctx, ": "))) - popstate() -} - -func fatalf(s string, v ...interface{}) { - pushstate(s) - fmt.Printf(chalk.Red.Color(strings.Join(logctx, ": ")), v...) - popstate() -} - -var logctx []string - -// push logging state -func pushstate(s string) { - logctx = append(logctx, s) -} - -// pop logging state -func popstate() { - logctx = logctx[:len(logctx)-1] -} diff --git a/vendor/github.com/tinylib/msgp/parse/inline.go b/vendor/github.com/tinylib/msgp/parse/inline.go deleted file mode 100644 index 5dba4e5..0000000 --- a/vendor/github.com/tinylib/msgp/parse/inline.go +++ /dev/null @@ -1,146 +0,0 @@ -package parse - -import ( - "github.com/tinylib/msgp/gen" -) - -// This file defines when and how we -// propagate type information from -// one type declaration to another. -// After the processing pass, every -// non-primitive type is marshalled/unmarshalled/etc. -// through a function call. Here, we propagate -// the type information into the caller's type -// tree *if* the child type is simple enough. -// -// For example, types like -// -// type A [4]int -// -// will get pushed into parent methods, -// whereas types like -// -// type B [3]map[string]struct{A, B [4]string} -// -// will not. - -// this is an approximate measure -// of the number of children in a node -const maxComplex = 5 - -// begin recursive search for identities with the -// given name and replace them with be -func (f *FileSet) findShim(id string, be *gen.BaseElem) { - for name, el := range f.Identities { - pushstate(name) - switch el := el.(type) { - case *gen.Struct: - for i := range el.Fields { - f.nextShim(&el.Fields[i].FieldElem, id, be) - } - case *gen.Array: - f.nextShim(&el.Els, id, be) - case *gen.Slice: - f.nextShim(&el.Els, id, be) - case *gen.Map: - f.nextShim(&el.Value, id, be) - case *gen.Ptr: - f.nextShim(&el.Value, id, be) - } - popstate() - } - // we'll need this at the top level as well - f.Identities[id] = be -} - -func (f *FileSet) nextShim(ref *gen.Elem, id string, be *gen.BaseElem) { - if (*ref).TypeName() == id { - vn := (*ref).Varname() - *ref = be.Copy() - (*ref).SetVarname(vn) - } else { - switch el := (*ref).(type) { - case *gen.Struct: - for i := range el.Fields { - f.nextShim(&el.Fields[i].FieldElem, id, be) - } - case *gen.Array: - f.nextShim(&el.Els, id, be) - case *gen.Slice: - f.nextShim(&el.Els, id, be) - case *gen.Map: - f.nextShim(&el.Value, id, be) - case *gen.Ptr: - f.nextShim(&el.Value, id, be) - } - } -} - -// propInline identifies and inlines candidates -func (f *FileSet) propInline() { - for name, el := range f.Identities { - pushstate(name) - switch el := el.(type) { - case *gen.Struct: - for i := range el.Fields { - f.nextInline(&el.Fields[i].FieldElem, name) - } - case *gen.Array: - f.nextInline(&el.Els, name) - case *gen.Slice: - f.nextInline(&el.Els, name) - case *gen.Map: - f.nextInline(&el.Value, name) - case *gen.Ptr: - f.nextInline(&el.Value, name) - } - popstate() - } -} - -const fatalloop = `detected infinite recursion in inlining loop! -Please file a bug at github.com/tinylib/msgp/issues! -Thanks! -` - -func (f *FileSet) nextInline(ref *gen.Elem, root string) { - switch el := (*ref).(type) { - case *gen.BaseElem: - // ensure that we're not inlining - // a type into itself - typ := el.TypeName() - if el.Value == gen.IDENT && typ != root { - if node, ok := f.Identities[typ]; ok && node.Complexity() < maxComplex { - infof("inlining %s\n", typ) - - // This should never happen; it will cause - // infinite recursion. - if node == *ref { - panic(fatalloop) - } - - *ref = node.Copy() - f.nextInline(ref, node.TypeName()) - } else if !ok && !el.Resolved() { - // this is the point at which we're sure that - // we've got a type that isn't a primitive, - // a library builtin, or a processed type - warnf("unresolved identifier: %s\n", typ) - } - } - case *gen.Struct: - for i := range el.Fields { - f.nextInline(&el.Fields[i].FieldElem, root) - } - case *gen.Array: - f.nextInline(&el.Els, root) - case *gen.Slice: - f.nextInline(&el.Els, root) - case *gen.Map: - f.nextInline(&el.Value, root) - case *gen.Ptr: - f.nextInline(&el.Value, root) - default: - panic("bad elem type") - } -} diff --git a/vendor/github.com/tinylib/msgp/printer/print.go b/vendor/github.com/tinylib/msgp/printer/print.go deleted file mode 100644 index d3ef52d..0000000 --- a/vendor/github.com/tinylib/msgp/printer/print.go +++ /dev/null @@ -1,129 +0,0 @@ -package printer - -import ( - "bytes" - "fmt" - "io" - "io/ioutil" - "strings" - - "github.com/tinylib/msgp/gen" - "github.com/tinylib/msgp/parse" - "github.com/ttacon/chalk" - "golang.org/x/tools/imports" -) - -func infof(s string, v ...interface{}) { - fmt.Printf(chalk.Magenta.Color(s), v...) -} - -// PrintFile prints the methods for the provided list -// of elements to the given file name and canonical -// package path. -func PrintFile(file string, f *parse.FileSet, mode gen.Method) error { - out, tests, err := generate(f, mode) - if err != nil { - return err - } - - // we'll run goimports on the main file - // in another goroutine, and run it here - // for the test file. empirically, this - // takes about the same amount of time as - // doing them in serial when GOMAXPROCS=1, - // and faster otherwise. - res := goformat(file, out.Bytes()) - if tests != nil { - testfile := strings.TrimSuffix(file, ".go") + "_test.go" - err = format(testfile, tests.Bytes()) - if err != nil { - return err - } - infof(">>> Wrote and formatted \"%s\"\n", testfile) - } - err = <-res - if err != nil { - return err - } - return nil -} - -func format(file string, data []byte) error { - out, err := imports.Process(file, data, nil) - if err != nil { - return err - } - return ioutil.WriteFile(file, out, 0600) -} - -func goformat(file string, data []byte) <-chan error { - out := make(chan error, 1) - go func(file string, data []byte, end chan error) { - end <- format(file, data) - infof(">>> Wrote and formatted \"%s\"\n", file) - }(file, data, out) - return out -} - -func dedupImports(imp []string) []string { - m := make(map[string]struct{}) - for i := range imp { - m[imp[i]] = struct{}{} - } - r := []string{} - for k := range m { - r = append(r, k) - } - return r -} - -func generate(f *parse.FileSet, mode gen.Method) (*bytes.Buffer, *bytes.Buffer, error) { - outbuf := bytes.NewBuffer(make([]byte, 0, 4096)) - writePkgHeader(outbuf, f.Package) - - myImports := []string{"github.com/tinylib/msgp/msgp"} - for _, imp := range f.Imports { - if imp.Name != nil { - // have an alias, include it. - myImports = append(myImports, imp.Name.Name+` `+imp.Path.Value) - } else { - myImports = append(myImports, imp.Path.Value) - } - } - dedup := dedupImports(myImports) - writeImportHeader(outbuf, dedup...) - - var testbuf *bytes.Buffer - var testwr io.Writer - if mode&gen.Test == gen.Test { - testbuf = bytes.NewBuffer(make([]byte, 0, 4096)) - writePkgHeader(testbuf, f.Package) - if mode&(gen.Encode|gen.Decode) != 0 { - writeImportHeader(testbuf, "bytes", "github.com/tinylib/msgp/msgp", "testing") - } else { - writeImportHeader(testbuf, "github.com/tinylib/msgp/msgp", "testing") - } - testwr = testbuf - } - return outbuf, testbuf, f.PrintTo(gen.NewPrinter(mode, outbuf, testwr)) -} - -func writePkgHeader(b *bytes.Buffer, name string) { - b.WriteString("package ") - b.WriteString(name) - b.WriteByte('\n') - b.WriteString("// NOTE: THIS FILE WAS PRODUCED BY THE\n// MSGP CODE GENERATION TOOL (github.com/tinylib/msgp)\n// DO NOT EDIT\n\n") -} - -func writeImportHeader(b *bytes.Buffer, imports ...string) { - b.WriteString("import (\n") - for _, im := range imports { - if im[len(im)-1] == '"' { - // support aliased imports - fmt.Fprintf(b, "\t%s\n", im) - } else { - fmt.Fprintf(b, "\t%q\n", im) - } - } - b.WriteString(")\n\n") -} diff --git a/vendor/github.com/vmihailenco/msgpack/.travis.yml b/vendor/github.com/vmihailenco/msgpack/.travis.yml deleted file mode 100644 index 016eedc..0000000 --- a/vendor/github.com/vmihailenco/msgpack/.travis.yml +++ /dev/null @@ -1,15 +0,0 @@ -sudo: false -language: go - -go: - - 1.7.x - - 1.8.x - - 1.9.x - - tip - -matrix: - allow_failures: - - go: tip - -install: - - go get gopkg.in/check.v1 diff --git a/vendor/github.com/vmihailenco/msgpack/CHANGELOG.md b/vendor/github.com/vmihailenco/msgpack/CHANGELOG.md deleted file mode 100644 index ac1a4a7..0000000 --- a/vendor/github.com/vmihailenco/msgpack/CHANGELOG.md +++ /dev/null @@ -1,14 +0,0 @@ -## v3.2 - -- Decoding extension types returns pointer to the value instead of the value. Fixes #153 - -## v3 - -- gopkg.in is not supported any more. Update import path to github.com/vmihailenco/msgpack. -- Msgpack maps are decoded into map[string]interface{} by default. -- EncodeSliceLen is removed in favor of EncodeArrayLen. DecodeSliceLen is removed in favor of DecodeArrayLen. -- Embedded structs are automatically inlined where possible. -- Time is encoded using extension as described in https://github.com/msgpack/msgpack/pull/209. Old format is supported as well. -- EncodeInt8/16/32/64 is replaced with EncodeInt. EncodeUint8/16/32/64 is replaced with EncodeUint. There should be no performance differences. -- DecodeInterface can now return int8/16/32 and uint8/16/32. -- PeekCode returns codes.Code instead of byte. diff --git a/vendor/github.com/vmihailenco/msgpack/LICENSE b/vendor/github.com/vmihailenco/msgpack/LICENSE deleted file mode 100644 index b749d07..0000000 --- a/vendor/github.com/vmihailenco/msgpack/LICENSE +++ /dev/null @@ -1,25 +0,0 @@ -Copyright (c) 2013 The github.com/vmihailenco/msgpack Authors. -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above -copyright notice, this list of conditions and the following disclaimer -in the documentation and/or other materials provided with the -distribution. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/github.com/vmihailenco/msgpack/Makefile b/vendor/github.com/vmihailenco/msgpack/Makefile deleted file mode 100644 index b62ae6a..0000000 --- a/vendor/github.com/vmihailenco/msgpack/Makefile +++ /dev/null @@ -1,5 +0,0 @@ -all: - go test ./... - env GOOS=linux GOARCH=386 go test ./... - go test ./... -short -race - go vet diff --git a/vendor/github.com/vmihailenco/msgpack/README.md b/vendor/github.com/vmihailenco/msgpack/README.md deleted file mode 100644 index f35d272..0000000 --- a/vendor/github.com/vmihailenco/msgpack/README.md +++ /dev/null @@ -1,68 +0,0 @@ -# MessagePack encoding for Golang - -[![Build Status](https://travis-ci.org/vmihailenco/msgpack.svg?branch=v2)](https://travis-ci.org/vmihailenco/msgpack) -[![GoDoc](https://godoc.org/github.com/vmihailenco/msgpack?status.svg)](https://godoc.org/github.com/vmihailenco/msgpack) - -Supports: -- Primitives, arrays, maps, structs, time.Time and interface{}. -- Appengine *datastore.Key and datastore.Cursor. -- [CustomEncoder](https://godoc.org/github.com/vmihailenco/msgpack#example-CustomEncoder)/CustomDecoder interfaces for custom encoding. -- [Extensions](https://godoc.org/github.com/vmihailenco/msgpack#example-RegisterExt) to encode type information. -- Renaming fields via `msgpack:"my_field_name"`. -- Omitting individual empty fields via `msgpack:",omitempty"` tag or all [empty fields in a struct](https://godoc.org/github.com/vmihailenco/msgpack#example-Marshal--OmitEmpty). -- [Map keys sorting](https://godoc.org/github.com/vmihailenco/msgpack#Encoder.SortMapKeys). -- Encoding/decoding all [structs as arrays](https://godoc.org/github.com/vmihailenco/msgpack#Encoder.StructAsArray) or [individual structs](https://godoc.org/github.com/vmihailenco/msgpack#example-Marshal--AsArray). -- Simple but very fast and efficient [queries](https://godoc.org/github.com/vmihailenco/msgpack#example-Decoder-Query). - -API docs: https://godoc.org/github.com/vmihailenco/msgpack. -Examples: https://godoc.org/github.com/vmihailenco/msgpack#pkg-examples. - -## Installation - -Install: - -```shell -go get -u github.com/vmihailenco/msgpack -``` - -## Quickstart - -```go -func ExampleMarshal() { - type Item struct { - Foo string - } - - b, err := msgpack.Marshal(&Item{Foo: "bar"}) - if err != nil { - panic(err) - } - - var item Item - err = msgpack.Unmarshal(b, &item) - if err != nil { - panic(err) - } - fmt.Println(item.Foo) - // Output: bar -} -``` - -## Benchmark - -``` -BenchmarkStructVmihailencoMsgpack-4 200000 12814 ns/op 2128 B/op 26 allocs/op -BenchmarkStructUgorjiGoMsgpack-4 100000 17678 ns/op 3616 B/op 70 allocs/op -BenchmarkStructUgorjiGoCodec-4 100000 19053 ns/op 7346 B/op 23 allocs/op -BenchmarkStructJSON-4 20000 69438 ns/op 7864 B/op 26 allocs/op -BenchmarkStructGOB-4 10000 104331 ns/op 14664 B/op 278 allocs/op -``` - -## Howto - -Please go through [examples](https://godoc.org/github.com/vmihailenco/msgpack#pkg-examples) to get an idea how to use this package. - -## See also - -- [Golang PostgreSQL ORM](https://github.com/go-pg/pg) -- [Golang message task queue](https://github.com/go-msgqueue/msgqueue) diff --git a/vendor/github.com/vmihailenco/msgpack/appengine.go b/vendor/github.com/vmihailenco/msgpack/appengine.go deleted file mode 100644 index e8e91e5..0000000 --- a/vendor/github.com/vmihailenco/msgpack/appengine.go +++ /dev/null @@ -1,64 +0,0 @@ -// +build appengine - -package msgpack - -import ( - "reflect" - - ds "google.golang.org/appengine/datastore" -) - -func init() { - Register((*ds.Key)(nil), encodeDatastoreKeyValue, decodeDatastoreKeyValue) - Register((*ds.Cursor)(nil), encodeDatastoreCursorValue, decodeDatastoreCursorValue) -} - -func EncodeDatastoreKey(e *Encoder, key *ds.Key) error { - if key == nil { - return e.EncodeNil() - } - return e.EncodeString(key.Encode()) -} - -func encodeDatastoreKeyValue(e *Encoder, v reflect.Value) error { - key := v.Interface().(*ds.Key) - return EncodeDatastoreKey(e, key) -} - -func DecodeDatastoreKey(d *Decoder) (*ds.Key, error) { - v, err := d.DecodeString() - if err != nil { - return nil, err - } - if v == "" { - return nil, nil - } - return ds.DecodeKey(v) -} - -func decodeDatastoreKeyValue(d *Decoder, v reflect.Value) error { - key, err := DecodeDatastoreKey(d) - if err != nil { - return err - } - v.Set(reflect.ValueOf(key)) - return nil -} - -func encodeDatastoreCursorValue(e *Encoder, v reflect.Value) error { - cursor := v.Interface().(ds.Cursor) - return e.Encode(cursor.String()) -} - -func decodeDatastoreCursorValue(d *Decoder, v reflect.Value) error { - s, err := d.DecodeString() - if err != nil { - return err - } - cursor, err := ds.DecodeCursor(s) - if err != nil { - return err - } - v.Set(reflect.ValueOf(cursor)) - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/bench_test.go b/vendor/github.com/vmihailenco/msgpack/bench_test.go deleted file mode 100644 index 0a1f693..0000000 --- a/vendor/github.com/vmihailenco/msgpack/bench_test.go +++ /dev/null @@ -1,323 +0,0 @@ -package msgpack_test - -import ( - "bytes" - "math" - "testing" - "time" - - "github.com/vmihailenco/msgpack" -) - -func benchmarkEncodeDecode(b *testing.B, src, dst interface{}) { - var buf bytes.Buffer - dec := msgpack.NewDecoder(&buf) - enc := msgpack.NewEncoder(&buf) - - b.ResetTimer() - - for i := 0; i < b.N; i++ { - if err := enc.Encode(src); err != nil { - b.Fatal(err) - } - if err := dec.Decode(dst); err != nil { - b.Fatal(err) - } - } -} - -func BenchmarkBool(b *testing.B) { - var dst bool - benchmarkEncodeDecode(b, true, &dst) -} - -func BenchmarkInt0(b *testing.B) { - var dst int - benchmarkEncodeDecode(b, 1, &dst) -} - -func BenchmarkInt1(b *testing.B) { - var dst int - benchmarkEncodeDecode(b, -33, &dst) -} - -func BenchmarkInt2(b *testing.B) { - var dst int - benchmarkEncodeDecode(b, 128, &dst) -} - -func BenchmarkInt4(b *testing.B) { - var dst int - benchmarkEncodeDecode(b, 32768, &dst) -} - -func BenchmarkInt8(b *testing.B) { - var dst int - benchmarkEncodeDecode(b, int64(2147483648), &dst) -} - -func BenchmarkInt32(b *testing.B) { - var dst int32 - benchmarkEncodeDecode(b, int32(0), &dst) -} - -func BenchmarkTime(b *testing.B) { - var dst time.Time - benchmarkEncodeDecode(b, time.Now(), &dst) -} - -func BenchmarkDuration(b *testing.B) { - var dst time.Duration - benchmarkEncodeDecode(b, time.Hour, &dst) -} - -func BenchmarkByteSlice(b *testing.B) { - src := make([]byte, 1024) - var dst []byte - benchmarkEncodeDecode(b, src, &dst) -} - -func BenchmarkByteArray(b *testing.B) { - var src [1024]byte - var dst [1024]byte - benchmarkEncodeDecode(b, src, &dst) -} - -func BenchmarkMapStringString(b *testing.B) { - src := map[string]string{ - "hello": "world", - "foo": "bar", - } - var dst map[string]string - benchmarkEncodeDecode(b, src, &dst) -} - -func BenchmarkMapStringStringPtr(b *testing.B) { - src := map[string]string{ - "hello": "world", - "foo": "bar", - } - var dst map[string]string - dstptr := &dst - benchmarkEncodeDecode(b, src, &dstptr) -} - -func BenchmarkMapStringInterface(b *testing.B) { - src := map[string]interface{}{ - "hello": "world", - "foo": "bar", - } - var dst map[string]interface{} - benchmarkEncodeDecode(b, src, &dst) -} - -func BenchmarkMapIntInt(b *testing.B) { - src := map[int]int{ - 1: 10, - 2: 20, - } - var dst map[int]int - benchmarkEncodeDecode(b, src, &dst) -} - -func BenchmarkStringSlice(b *testing.B) { - src := []string{"hello", "world"} - var dst []string - benchmarkEncodeDecode(b, src, &dst) -} - -func BenchmarkStringSlicePtr(b *testing.B) { - src := []string{"hello", "world"} - var dst []string - dstptr := &dst - benchmarkEncodeDecode(b, src, &dstptr) -} - -type benchmarkStruct struct { - Name string - Age int - Colors []string - Data []byte - CreatedAt time.Time - UpdatedAt time.Time -} - -type benchmarkStruct2 struct { - Name string - Age int - Colors []string - Data []byte - CreatedAt time.Time - UpdatedAt time.Time -} - -var _ msgpack.CustomEncoder = (*benchmarkStruct2)(nil) -var _ msgpack.CustomDecoder = (*benchmarkStruct2)(nil) - -func (s *benchmarkStruct2) EncodeMsgpack(enc *msgpack.Encoder) error { - return enc.Encode( - s.Name, - s.Colors, - s.Age, - s.Data, - s.CreatedAt, - s.UpdatedAt, - ) -} - -func (s *benchmarkStruct2) DecodeMsgpack(dec *msgpack.Decoder) error { - return dec.Decode( - &s.Name, - &s.Colors, - &s.Age, - &s.Data, - &s.CreatedAt, - &s.UpdatedAt, - ) -} - -func structForBenchmark() *benchmarkStruct { - return &benchmarkStruct{ - Name: "Hello World", - Colors: []string{"red", "orange", "yellow", "green", "blue", "violet"}, - Age: math.MaxInt32, - Data: make([]byte, 1024), - CreatedAt: time.Now(), - UpdatedAt: time.Now(), - } -} - -func structForBenchmark2() *benchmarkStruct2 { - return &benchmarkStruct2{ - Name: "Hello World", - Colors: []string{"red", "orange", "yellow", "green", "blue", "violet"}, - Age: math.MaxInt32, - Data: make([]byte, 1024), - CreatedAt: time.Now(), - UpdatedAt: time.Now(), - } -} - -func BenchmarkStructVmihailencoMsgpack(b *testing.B) { - in := structForBenchmark() - out := new(benchmarkStruct) - - b.ResetTimer() - - for i := 0; i < b.N; i++ { - buf, err := msgpack.Marshal(in) - if err != nil { - b.Fatal(err) - } - - err = msgpack.Unmarshal(buf, out) - if err != nil { - b.Fatal(err) - } - } -} - -func BenchmarkStructMarshal(b *testing.B) { - in := structForBenchmark() - - b.ResetTimer() - - for i := 0; i < b.N; i++ { - _, err := msgpack.Marshal(in) - if err != nil { - b.Fatal(err) - } - } -} - -func BenchmarkStructUnmarshal(b *testing.B) { - in := structForBenchmark() - buf, err := msgpack.Marshal(in) - if err != nil { - b.Fatal(err) - } - out := new(benchmarkStruct) - - b.ResetTimer() - - for i := 0; i < b.N; i++ { - err = msgpack.Unmarshal(buf, out) - if err != nil { - b.Fatal(err) - } - } -} - -func BenchmarkStructManual(b *testing.B) { - in := structForBenchmark2() - out := new(benchmarkStruct2) - - b.ResetTimer() - - for i := 0; i < b.N; i++ { - buf, err := msgpack.Marshal(in) - if err != nil { - b.Fatal(err) - } - - err = msgpack.Unmarshal(buf, out) - if err != nil { - b.Fatal(err) - } - } -} - -type benchmarkStructPartially struct { - Name string - Age int -} - -func BenchmarkStructUnmarshalPartially(b *testing.B) { - in := structForBenchmark() - buf, err := msgpack.Marshal(in) - if err != nil { - b.Fatal(err) - } - out := new(benchmarkStructPartially) - - b.ResetTimer() - - for i := 0; i < b.N; i++ { - err = msgpack.Unmarshal(buf, out) - if err != nil { - b.Fatal(err) - } - } -} - -func BenchmarkQuery(b *testing.B) { - var records []map[string]interface{} - for i := 0; i < 1000; i++ { - record := map[string]interface{}{ - "id": i, - "attrs": map[string]interface{}{"phone": i}, - } - records = append(records, record) - } - - bs, err := msgpack.Marshal(records) - if err != nil { - b.Fatal(err) - } - - dec := msgpack.NewDecoder(bytes.NewBuffer(bs)) - - b.ResetTimer() - - for i := 0; i < b.N; i++ { - dec.Reset(bytes.NewBuffer(bs)) - - values, err := dec.Query("10.attrs.phone") - if err != nil { - b.Fatal(err) - } - if values[0].(int8) != 10 { - b.Fatalf("%v != %d", values[0], 10) - } - } -} diff --git a/vendor/github.com/vmihailenco/msgpack/codes/codes.go b/vendor/github.com/vmihailenco/msgpack/codes/codes.go deleted file mode 100644 index 3433ece..0000000 --- a/vendor/github.com/vmihailenco/msgpack/codes/codes.go +++ /dev/null @@ -1,78 +0,0 @@ -package codes - -type Code byte - -var ( - PosFixedNumHigh Code = 0x7f - NegFixedNumLow Code = 0xe0 - - Nil Code = 0xc0 - - False Code = 0xc2 - True Code = 0xc3 - - Float Code = 0xca - Double Code = 0xcb - - Uint8 Code = 0xcc - Uint16 Code = 0xcd - Uint32 Code = 0xce - Uint64 Code = 0xcf - - Int8 Code = 0xd0 - Int16 Code = 0xd1 - Int32 Code = 0xd2 - Int64 Code = 0xd3 - - FixedStrLow Code = 0xa0 - FixedStrHigh Code = 0xbf - FixedStrMask Code = 0x1f - Str8 Code = 0xd9 - Str16 Code = 0xda - Str32 Code = 0xdb - - Bin8 Code = 0xc4 - Bin16 Code = 0xc5 - Bin32 Code = 0xc6 - - FixedArrayLow Code = 0x90 - FixedArrayHigh Code = 0x9f - FixedArrayMask Code = 0xf - Array16 Code = 0xdc - Array32 Code = 0xdd - - FixedMapLow Code = 0x80 - FixedMapHigh Code = 0x8f - FixedMapMask Code = 0xf - Map16 Code = 0xde - Map32 Code = 0xdf - - FixExt1 Code = 0xd4 - FixExt2 Code = 0xd5 - FixExt4 Code = 0xd6 - FixExt8 Code = 0xd7 - FixExt16 Code = 0xd8 - Ext8 Code = 0xc7 - Ext16 Code = 0xc8 - Ext32 Code = 0xc9 -) - -func IsFixedNum(c Code) bool { - return c <= PosFixedNumHigh || c >= NegFixedNumLow -} - -func IsFixedMap(c Code) bool { - return c >= FixedMapLow && c <= FixedMapHigh -} - -func IsFixedArray(c Code) bool { - return c >= FixedArrayLow && c <= FixedArrayHigh -} - -func IsFixedString(c Code) bool { - return c >= FixedStrLow && c <= FixedStrHigh -} - -func IsExt(c Code) bool { - return (c >= FixExt1 && c <= FixExt16) || (c >= Ext8 && c <= Ext32) -} diff --git a/vendor/github.com/vmihailenco/msgpack/decode.go b/vendor/github.com/vmihailenco/msgpack/decode.go deleted file mode 100644 index 47791a9..0000000 --- a/vendor/github.com/vmihailenco/msgpack/decode.go +++ /dev/null @@ -1,509 +0,0 @@ -package msgpack - -import ( - "bufio" - "bytes" - "errors" - "fmt" - "io" - "reflect" - "time" - - "github.com/vmihailenco/msgpack/codes" -) - -const bytesAllocLimit = 1024 * 1024 // 1mb - -type bufReader interface { - io.Reader - io.ByteScanner -} - -func newBufReader(r io.Reader) bufReader { - if br, ok := r.(bufReader); ok { - return br - } - return bufio.NewReader(r) -} - -func makeBuffer() []byte { - return make([]byte, 0, 64) -} - -// Unmarshal decodes the MessagePack-encoded data and stores the result -// in the value pointed to by v. -func Unmarshal(data []byte, v ...interface{}) error { - return NewDecoder(bytes.NewReader(data)).Decode(v...) -} - -type Decoder struct { - r io.Reader - s io.ByteScanner - buf []byte - - extLen int - rec []byte // accumulates read data if not nil - - decodeMapFunc func(*Decoder) (interface{}, error) -} - -// NewDecoder returns a new decoder that reads from r. -// -// The decoder introduces its own buffering and may read data from r -// beyond the MessagePack values requested. Buffering can be disabled -// by passing a reader that implements io.ByteScanner interface. -func NewDecoder(r io.Reader) *Decoder { - d := &Decoder{ - decodeMapFunc: decodeMap, - - buf: makeBuffer(), - } - d.resetReader(r) - return d -} - -func (d *Decoder) SetDecodeMapFunc(fn func(*Decoder) (interface{}, error)) { - d.decodeMapFunc = fn -} - -func (d *Decoder) Reset(r io.Reader) error { - d.resetReader(r) - return nil -} - -func (d *Decoder) resetReader(r io.Reader) { - reader := newBufReader(r) - d.r = reader - d.s = reader -} - -func (d *Decoder) Decode(v ...interface{}) error { - for _, vv := range v { - if err := d.decode(vv); err != nil { - return err - } - } - return nil -} - -func (d *Decoder) decode(dst interface{}) error { - var err error - switch v := dst.(type) { - case *string: - if v != nil { - *v, err = d.DecodeString() - return err - } - case *[]byte: - if v != nil { - return d.decodeBytesPtr(v) - } - case *int: - if v != nil { - *v, err = d.DecodeInt() - return err - } - case *int8: - if v != nil { - *v, err = d.DecodeInt8() - return err - } - case *int16: - if v != nil { - *v, err = d.DecodeInt16() - return err - } - case *int32: - if v != nil { - *v, err = d.DecodeInt32() - return err - } - case *int64: - if v != nil { - *v, err = d.DecodeInt64() - return err - } - case *uint: - if v != nil { - *v, err = d.DecodeUint() - return err - } - case *uint8: - if v != nil { - *v, err = d.DecodeUint8() - return err - } - case *uint16: - if v != nil { - *v, err = d.DecodeUint16() - return err - } - case *uint32: - if v != nil { - *v, err = d.DecodeUint32() - return err - } - case *uint64: - if v != nil { - *v, err = d.DecodeUint64() - return err - } - case *bool: - if v != nil { - *v, err = d.DecodeBool() - return err - } - case *float32: - if v != nil { - *v, err = d.DecodeFloat32() - return err - } - case *float64: - if v != nil { - *v, err = d.DecodeFloat64() - return err - } - case *[]string: - return d.decodeStringSlicePtr(v) - case *map[string]string: - return d.decodeMapStringStringPtr(v) - case *map[string]interface{}: - return d.decodeMapStringInterfacePtr(v) - case *time.Duration: - if v != nil { - vv, err := d.DecodeInt64() - *v = time.Duration(vv) - return err - } - case *time.Time: - if v != nil { - *v, err = d.DecodeTime() - return err - } - } - - v := reflect.ValueOf(dst) - if !v.IsValid() { - return errors.New("msgpack: Decode(nil)") - } - if v.Kind() != reflect.Ptr { - return fmt.Errorf("msgpack: Decode(nonsettable %T)", dst) - } - v = v.Elem() - if !v.IsValid() { - return fmt.Errorf("msgpack: Decode(nonsettable %T)", dst) - } - return d.DecodeValue(v) -} - -func (d *Decoder) DecodeValue(v reflect.Value) error { - decode := getDecoder(v.Type()) - return decode(d, v) -} - -func (d *Decoder) DecodeNil() error { - c, err := d.readCode() - if err != nil { - return err - } - if c != codes.Nil { - return fmt.Errorf("msgpack: invalid code=%x decoding nil", c) - } - return nil -} - -func (d *Decoder) decodeNilValue(v reflect.Value) error { - err := d.DecodeNil() - if v.IsNil() { - return err - } - if v.Kind() == reflect.Ptr { - v = v.Elem() - } - v.Set(reflect.Zero(v.Type())) - return err -} - -func (d *Decoder) DecodeBool() (bool, error) { - c, err := d.readCode() - if err != nil { - return false, err - } - return d.bool(c) -} - -func (d *Decoder) bool(c codes.Code) (bool, error) { - if c == codes.False { - return false, nil - } - if c == codes.True { - return true, nil - } - return false, fmt.Errorf("msgpack: invalid code=%x decoding bool", c) -} - -// DecodeInterface decodes value into interface. Possible value types are: -// - nil, -// - bool, -// - int8, int16, int32, int64, -// - uint8, uint16, uint32, uint64, -// - float32 and float64, -// - string, -// - []byte, -// - slices of any of the above, -// - maps of any of the above. -func (d *Decoder) DecodeInterface() (interface{}, error) { - c, err := d.readCode() - if err != nil { - return nil, err - } - - if codes.IsFixedNum(c) { - return int8(c), nil - } - if codes.IsFixedMap(c) { - d.s.UnreadByte() - return d.DecodeMap() - } - if codes.IsFixedArray(c) { - return d.decodeSlice(c) - } - if codes.IsFixedString(c) { - return d.string(c) - } - - switch c { - case codes.Nil: - return nil, nil - case codes.False, codes.True: - return d.bool(c) - case codes.Float: - return d.float32(c) - case codes.Double: - return d.float64(c) - case codes.Uint8: - return d.uint8() - case codes.Uint16: - return d.uint16() - case codes.Uint32: - return d.uint32() - case codes.Uint64: - return d.uint64() - case codes.Int8: - return d.int8() - case codes.Int16: - return d.int16() - case codes.Int32: - return d.int32() - case codes.Int64: - return d.int64() - case codes.Bin8, codes.Bin16, codes.Bin32: - return d.bytes(c, nil) - case codes.Str8, codes.Str16, codes.Str32: - return d.string(c) - case codes.Array16, codes.Array32: - return d.decodeSlice(c) - case codes.Map16, codes.Map32: - d.s.UnreadByte() - return d.DecodeMap() - case codes.FixExt1, codes.FixExt2, codes.FixExt4, codes.FixExt8, codes.FixExt16, - codes.Ext8, codes.Ext16, codes.Ext32: - return d.extInterface(c) - } - - return 0, fmt.Errorf("msgpack: unknown code %x decoding interface{}", c) -} - -// DecodeInterfaceLoose is like DecodeInterface except that: -// - int8, int16, and int32 are converted to int64, -// - uint8, uint16, and uint32 are converted to uint64, -// - float32 is converted to float64. -func (d *Decoder) DecodeInterfaceLoose() (interface{}, error) { - c, err := d.readCode() - if err != nil { - return nil, err - } - - if codes.IsFixedNum(c) { - return int64(c), nil - } - if codes.IsFixedMap(c) { - d.s.UnreadByte() - return d.DecodeMap() - } - if codes.IsFixedArray(c) { - return d.decodeSlice(c) - } - if codes.IsFixedString(c) { - return d.string(c) - } - - switch c { - case codes.Nil: - return nil, nil - case codes.False, codes.True: - return d.bool(c) - case codes.Float, codes.Double: - return d.float64(c) - case codes.Uint8, codes.Uint16, codes.Uint32, codes.Uint64: - return d.uint(c) - case codes.Int8, codes.Int16, codes.Int32, codes.Int64: - return d.int(c) - case codes.Bin8, codes.Bin16, codes.Bin32: - return d.bytes(c, nil) - case codes.Str8, codes.Str16, codes.Str32: - return d.string(c) - case codes.Array16, codes.Array32: - return d.decodeSlice(c) - case codes.Map16, codes.Map32: - d.s.UnreadByte() - return d.DecodeMap() - case codes.FixExt1, codes.FixExt2, codes.FixExt4, codes.FixExt8, codes.FixExt16, - codes.Ext8, codes.Ext16, codes.Ext32: - return d.extInterface(c) - } - - return 0, fmt.Errorf("msgpack: unknown code %x decoding interface{}", c) -} - -// Skip skips next value. -func (d *Decoder) Skip() error { - c, err := d.readCode() - if err != nil { - return err - } - - if codes.IsFixedNum(c) { - return nil - } else if codes.IsFixedMap(c) { - return d.skipMap(c) - } else if codes.IsFixedArray(c) { - return d.skipSlice(c) - } else if codes.IsFixedString(c) { - return d.skipBytes(c) - } - - switch c { - case codes.Nil, codes.False, codes.True: - return nil - case codes.Uint8, codes.Int8: - return d.skipN(1) - case codes.Uint16, codes.Int16: - return d.skipN(2) - case codes.Uint32, codes.Int32, codes.Float: - return d.skipN(4) - case codes.Uint64, codes.Int64, codes.Double: - return d.skipN(8) - case codes.Bin8, codes.Bin16, codes.Bin32: - return d.skipBytes(c) - case codes.Str8, codes.Str16, codes.Str32: - return d.skipBytes(c) - case codes.Array16, codes.Array32: - return d.skipSlice(c) - case codes.Map16, codes.Map32: - return d.skipMap(c) - case codes.FixExt1, codes.FixExt2, codes.FixExt4, codes.FixExt8, codes.FixExt16, - codes.Ext8, codes.Ext16, codes.Ext32: - return d.skipExt(c) - } - - return fmt.Errorf("msgpack: unknown code %x", c) -} - -// PeekCode returns the next MessagePack code without advancing the reader. -// Subpackage msgpack/codes contains list of available codes. -func (d *Decoder) PeekCode() (codes.Code, error) { - c, err := d.s.ReadByte() - if err != nil { - return 0, err - } - return codes.Code(c), d.s.UnreadByte() -} - -func (d *Decoder) hasNilCode() bool { - code, err := d.PeekCode() - return err == nil && code == codes.Nil -} - -func (d *Decoder) readCode() (codes.Code, error) { - d.extLen = 0 - c, err := d.s.ReadByte() - if err != nil { - return 0, err - } - if d.rec != nil { - d.rec = append(d.rec, c) - } - return codes.Code(c), nil -} - -func (d *Decoder) readFull(b []byte) error { - _, err := io.ReadFull(d.r, b) - if err != nil { - return err - } - if d.rec != nil { - d.rec = append(d.rec, b...) - } - return nil -} - -func (d *Decoder) readN(n int) ([]byte, error) { - buf, err := readN(d.r, d.buf, n) - if err != nil { - return nil, err - } - d.buf = buf - if d.rec != nil { - d.rec = append(d.rec, buf...) - } - return buf, nil -} - -func readN(r io.Reader, b []byte, n int) ([]byte, error) { - if b == nil { - if n == 0 { - return make([]byte, 0), nil - } - if n <= bytesAllocLimit { - b = make([]byte, n) - } else { - b = make([]byte, bytesAllocLimit) - } - } - - if n <= cap(b) { - b = b[:n] - _, err := io.ReadFull(r, b) - return b, err - } - b = b[:cap(b)] - - var pos int - for { - alloc := n - len(b) - if alloc > bytesAllocLimit { - alloc = bytesAllocLimit - } - b = append(b, make([]byte, alloc)...) - - _, err := io.ReadFull(r, b[pos:]) - if err != nil { - return nil, err - } - - if len(b) == n { - break - } - pos = len(b) - } - - return b, nil -} - -func min(a, b int) int { - if a <= b { - return a - } - return b -} diff --git a/vendor/github.com/vmihailenco/msgpack/decode_map.go b/vendor/github.com/vmihailenco/msgpack/decode_map.go deleted file mode 100644 index e92565e..0000000 --- a/vendor/github.com/vmihailenco/msgpack/decode_map.go +++ /dev/null @@ -1,269 +0,0 @@ -package msgpack - -import ( - "fmt" - "reflect" - - "github.com/vmihailenco/msgpack/codes" -) - -const mapElemsAllocLimit = 1e4 - -var mapStringStringPtrType = reflect.TypeOf((*map[string]string)(nil)) -var mapStringStringType = mapStringStringPtrType.Elem() - -var mapStringInterfacePtrType = reflect.TypeOf((*map[string]interface{})(nil)) -var mapStringInterfaceType = mapStringInterfacePtrType.Elem() - -func decodeMapValue(d *Decoder, v reflect.Value) error { - n, err := d.DecodeMapLen() - if err != nil { - return err - } - - typ := v.Type() - if n == -1 { - v.Set(reflect.Zero(typ)) - return nil - } - - if v.IsNil() { - v.Set(reflect.MakeMap(typ)) - } - keyType := typ.Key() - valueType := typ.Elem() - - for i := 0; i < n; i++ { - mk := reflect.New(keyType).Elem() - if err := d.DecodeValue(mk); err != nil { - return err - } - - mv := reflect.New(valueType).Elem() - if err := d.DecodeValue(mv); err != nil { - return err - } - - v.SetMapIndex(mk, mv) - } - - return nil -} - -func decodeMap(d *Decoder) (interface{}, error) { - n, err := d.DecodeMapLen() - if err != nil { - return nil, err - } - if n == -1 { - return nil, nil - } - - m := make(map[string]interface{}, min(n, mapElemsAllocLimit)) - for i := 0; i < n; i++ { - mk, err := d.DecodeString() - if err != nil { - return nil, err - } - mv, err := d.DecodeInterface() - if err != nil { - return nil, err - } - m[mk] = mv - } - return m, nil -} - -func (d *Decoder) DecodeMapLen() (int, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - - if codes.IsExt(c) { - if err = d.skipExtHeader(c); err != nil { - return 0, err - } - - c, err = d.readCode() - if err != nil { - return 0, err - } - } - - return d.mapLen(c) -} - -func (d *Decoder) mapLen(c codes.Code) (int, error) { - if c == codes.Nil { - return -1, nil - } - if c >= codes.FixedMapLow && c <= codes.FixedMapHigh { - return int(c & codes.FixedMapMask), nil - } - if c == codes.Map16 { - n, err := d.uint16() - return int(n), err - } - if c == codes.Map32 { - n, err := d.uint32() - return int(n), err - } - return 0, fmt.Errorf("msgpack: invalid code=%x decoding map length", c) -} - -func decodeMapStringStringValue(d *Decoder, v reflect.Value) error { - mptr := v.Addr().Convert(mapStringStringPtrType).Interface().(*map[string]string) - return d.decodeMapStringStringPtr(mptr) -} - -func (d *Decoder) decodeMapStringStringPtr(ptr *map[string]string) error { - n, err := d.DecodeMapLen() - if err != nil { - return err - } - if n == -1 { - *ptr = nil - return nil - } - - m := *ptr - if m == nil { - *ptr = make(map[string]string, min(n, mapElemsAllocLimit)) - m = *ptr - } - - for i := 0; i < n; i++ { - mk, err := d.DecodeString() - if err != nil { - return err - } - mv, err := d.DecodeString() - if err != nil { - return err - } - m[mk] = mv - } - - return nil -} - -func decodeMapStringInterfaceValue(d *Decoder, v reflect.Value) error { - ptr := v.Addr().Convert(mapStringInterfacePtrType).Interface().(*map[string]interface{}) - return d.decodeMapStringInterfacePtr(ptr) -} - -func (d *Decoder) decodeMapStringInterfacePtr(ptr *map[string]interface{}) error { - n, err := d.DecodeMapLen() - if err != nil { - return err - } - if n == -1 { - *ptr = nil - return nil - } - - m := *ptr - if m == nil { - *ptr = make(map[string]interface{}, min(n, mapElemsAllocLimit)) - m = *ptr - } - - for i := 0; i < n; i++ { - mk, err := d.DecodeString() - if err != nil { - return err - } - mv, err := d.DecodeInterface() - if err != nil { - return err - } - m[mk] = mv - } - - return nil -} - -func (d *Decoder) DecodeMap() (interface{}, error) { - return d.decodeMapFunc(d) -} - -func (d *Decoder) skipMap(c codes.Code) error { - n, err := d.mapLen(c) - if err != nil { - return err - } - for i := 0; i < n; i++ { - if err := d.Skip(); err != nil { - return err - } - if err := d.Skip(); err != nil { - return err - } - } - return nil -} - -func decodeStructValue(d *Decoder, v reflect.Value) error { - c, err := d.readCode() - if err != nil { - return err - } - - var isArray bool - - n, err := d.mapLen(c) - if err != nil { - var err2 error - n, err2 = d.arrayLen(c) - if err2 != nil { - return err - } - isArray = true - } - if n == -1 { - if err = mustSet(v); err != nil { - return err - } - v.Set(reflect.Zero(v.Type())) - return nil - } - - fields := structs.Fields(v.Type()) - - if isArray { - for i, f := range fields.List { - if i >= n { - break - } - if err := f.DecodeValue(d, v); err != nil { - return err - } - } - // Skip extra values. - for i := len(fields.List); i < n; i++ { - if err := d.Skip(); err != nil { - return err - } - } - return nil - } - - for i := 0; i < n; i++ { - name, err := d.DecodeString() - if err != nil { - return err - } - if f := fields.Table[name]; f != nil { - if err := f.DecodeValue(d, v); err != nil { - return err - } - } else { - if err := d.Skip(); err != nil { - return err - } - } - } - - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/decode_number.go b/vendor/github.com/vmihailenco/msgpack/decode_number.go deleted file mode 100644 index 46067b7..0000000 --- a/vendor/github.com/vmihailenco/msgpack/decode_number.go +++ /dev/null @@ -1,302 +0,0 @@ -package msgpack - -import ( - "fmt" - "math" - "reflect" - - "github.com/vmihailenco/msgpack/codes" -) - -func (d *Decoder) skipN(n int) error { - _, err := d.readN(n) - return err -} - -func (d *Decoder) uint8() (uint8, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - return uint8(c), nil -} - -func (d *Decoder) int8() (int8, error) { - n, err := d.uint8() - return int8(n), err -} - -func (d *Decoder) uint16() (uint16, error) { - b, err := d.readN(2) - if err != nil { - return 0, err - } - return (uint16(b[0]) << 8) | uint16(b[1]), nil -} - -func (d *Decoder) int16() (int16, error) { - n, err := d.uint16() - return int16(n), err -} - -func (d *Decoder) uint32() (uint32, error) { - b, err := d.readN(4) - if err != nil { - return 0, err - } - n := (uint32(b[0]) << 24) | - (uint32(b[1]) << 16) | - (uint32(b[2]) << 8) | - uint32(b[3]) - return n, nil -} - -func (d *Decoder) int32() (int32, error) { - n, err := d.uint32() - return int32(n), err -} - -func (d *Decoder) uint64() (uint64, error) { - b, err := d.readN(8) - if err != nil { - return 0, err - } - n := (uint64(b[0]) << 56) | - (uint64(b[1]) << 48) | - (uint64(b[2]) << 40) | - (uint64(b[3]) << 32) | - (uint64(b[4]) << 24) | - (uint64(b[5]) << 16) | - (uint64(b[6]) << 8) | - uint64(b[7]) - return n, nil -} - -func (d *Decoder) int64() (int64, error) { - n, err := d.uint64() - return int64(n), err -} - -func (d *Decoder) DecodeUint64() (uint64, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - return d.uint(c) -} - -func (d *Decoder) uint(c codes.Code) (uint64, error) { - if c == codes.Nil { - return 0, nil - } - if codes.IsFixedNum(c) { - return uint64(int8(c)), nil - } - switch c { - case codes.Uint8: - n, err := d.uint8() - return uint64(n), err - case codes.Int8: - n, err := d.int8() - return uint64(n), err - case codes.Uint16: - n, err := d.uint16() - return uint64(n), err - case codes.Int16: - n, err := d.int16() - return uint64(n), err - case codes.Uint32: - n, err := d.uint32() - return uint64(n), err - case codes.Int32: - n, err := d.int32() - return uint64(n), err - case codes.Uint64, codes.Int64: - return d.uint64() - } - return 0, fmt.Errorf("msgpack: invalid code=%x decoding uint64", c) -} - -func (d *Decoder) DecodeInt64() (int64, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - return d.int(c) -} - -func (d *Decoder) int(c codes.Code) (int64, error) { - if c == codes.Nil { - return 0, nil - } - if codes.IsFixedNum(c) { - return int64(int8(c)), nil - } - switch c { - case codes.Uint8: - n, err := d.uint8() - return int64(n), err - case codes.Int8: - n, err := d.uint8() - return int64(int8(n)), err - case codes.Uint16: - n, err := d.uint16() - return int64(n), err - case codes.Int16: - n, err := d.uint16() - return int64(int16(n)), err - case codes.Uint32: - n, err := d.uint32() - return int64(n), err - case codes.Int32: - n, err := d.uint32() - return int64(int32(n)), err - case codes.Uint64, codes.Int64: - n, err := d.uint64() - return int64(n), err - } - return 0, fmt.Errorf("msgpack: invalid code=%x decoding int64", c) -} - -func (d *Decoder) DecodeFloat32() (float32, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - return d.float32(c) -} - -func (d *Decoder) float32(c codes.Code) (float32, error) { - if c == codes.Float { - n, err := d.uint32() - if err != nil { - return 0, err - } - return math.Float32frombits(n), nil - } - - n, err := d.int(c) - if err != nil { - return 0, fmt.Errorf("msgpack: invalid code=%x decoding float32", c) - } - return float32(n), nil -} - -func (d *Decoder) DecodeFloat64() (float64, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - return d.float64(c) -} - -func (d *Decoder) float64(c codes.Code) (float64, error) { - switch c { - case codes.Float: - n, err := d.float32(c) - if err != nil { - return 0, err - } - return float64(n), nil - case codes.Double: - n, err := d.uint64() - if err != nil { - return 0, err - } - return math.Float64frombits(n), nil - } - - n, err := d.int(c) - if err != nil { - return 0, fmt.Errorf("msgpack: invalid code=%x decoding float32", c) - } - return float64(n), nil -} - -func (d *Decoder) DecodeUint() (uint, error) { - n, err := d.DecodeUint64() - return uint(n), err -} - -func (d *Decoder) DecodeUint8() (uint8, error) { - n, err := d.DecodeUint64() - return uint8(n), err -} - -func (d *Decoder) DecodeUint16() (uint16, error) { - n, err := d.DecodeUint64() - return uint16(n), err -} - -func (d *Decoder) DecodeUint32() (uint32, error) { - n, err := d.DecodeUint64() - return uint32(n), err -} - -func (d *Decoder) DecodeInt() (int, error) { - n, err := d.DecodeInt64() - return int(n), err -} - -func (d *Decoder) DecodeInt8() (int8, error) { - n, err := d.DecodeInt64() - return int8(n), err -} - -func (d *Decoder) DecodeInt16() (int16, error) { - n, err := d.DecodeInt64() - return int16(n), err -} - -func (d *Decoder) DecodeInt32() (int32, error) { - n, err := d.DecodeInt64() - return int32(n), err -} - -func decodeFloat32Value(d *Decoder, v reflect.Value) error { - f, err := d.DecodeFloat32() - if err != nil { - return err - } - if err = mustSet(v); err != nil { - return err - } - v.SetFloat(float64(f)) - return nil -} - -func decodeFloat64Value(d *Decoder, v reflect.Value) error { - f, err := d.DecodeFloat64() - if err != nil { - return err - } - if err = mustSet(v); err != nil { - return err - } - v.SetFloat(f) - return nil -} - -func decodeInt64Value(d *Decoder, v reflect.Value) error { - n, err := d.DecodeInt64() - if err != nil { - return err - } - if err = mustSet(v); err != nil { - return err - } - v.SetInt(n) - return nil -} - -func decodeUint64Value(d *Decoder, v reflect.Value) error { - n, err := d.DecodeUint64() - if err != nil { - return err - } - if err = mustSet(v); err != nil { - return err - } - v.SetUint(n) - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/decode_query.go b/vendor/github.com/vmihailenco/msgpack/decode_query.go deleted file mode 100644 index ff496d8..0000000 --- a/vendor/github.com/vmihailenco/msgpack/decode_query.go +++ /dev/null @@ -1,158 +0,0 @@ -package msgpack - -import ( - "fmt" - "strconv" - "strings" - - "github.com/vmihailenco/msgpack/codes" -) - -type queryResult struct { - query string - key string - hasAsterisk bool - - values []interface{} -} - -func (q *queryResult) nextKey() { - ind := strings.IndexByte(q.query, '.') - if ind == -1 { - q.key = q.query - q.query = "" - return - } - q.key = q.query[:ind] - q.query = q.query[ind+1:] -} - -// Query extracts data specified by the query from the msgpack stream skipping -// any other data. Query consists of map keys and array indexes separated with dot, -// e.g. key1.0.key2. -func (d *Decoder) Query(query string) ([]interface{}, error) { - res := queryResult{ - query: query, - } - if err := d.query(&res); err != nil { - return nil, err - } - return res.values, nil -} - -func (d *Decoder) query(q *queryResult) error { - q.nextKey() - if q.key == "" { - v, err := d.DecodeInterface() - if err != nil { - return err - } - q.values = append(q.values, v) - return nil - } - - code, err := d.PeekCode() - if err != nil { - return err - } - - switch { - case code == codes.Map16 || code == codes.Map32 || codes.IsFixedMap(code): - err = d.queryMapKey(q) - case code == codes.Array16 || code == codes.Array32 || codes.IsFixedArray(code): - err = d.queryArrayIndex(q) - default: - err = fmt.Errorf("msgpack: unsupported code=%x decoding key=%q", code, q.key) - } - return err -} - -func (d *Decoder) queryMapKey(q *queryResult) error { - n, err := d.DecodeMapLen() - if err != nil { - return err - } - if n == -1 { - return nil - } - - for i := 0; i < n; i++ { - k, err := d.bytesNoCopy() - if err != nil { - return err - } - - if string(k) == q.key { - if err := d.query(q); err != nil { - return err - } - if q.hasAsterisk { - return d.skipNext((n - i - 1) * 2) - } - return nil - } - - if err := d.Skip(); err != nil { - return err - } - } - - return nil -} - -func (d *Decoder) queryArrayIndex(q *queryResult) error { - n, err := d.DecodeArrayLen() - if err != nil { - return err - } - if n == -1 { - return nil - } - - if q.key == "*" { - q.hasAsterisk = true - - query := q.query - for i := 0; i < n; i++ { - q.query = query - if err := d.query(q); err != nil { - return err - } - } - - q.hasAsterisk = false - return nil - } - - ind, err := strconv.Atoi(q.key) - if err != nil { - return err - } - - for i := 0; i < n; i++ { - if i == ind { - if err := d.query(q); err != nil { - return err - } - if q.hasAsterisk { - return d.skipNext(n - i - 1) - } - return nil - } - - if err := d.Skip(); err != nil { - return err - } - } - - return nil -} - -func (d *Decoder) skipNext(n int) error { - for i := 0; i < n; i++ { - if err := d.Skip(); err != nil { - return err - } - } - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/decode_slice.go b/vendor/github.com/vmihailenco/msgpack/decode_slice.go deleted file mode 100644 index db1dd6d..0000000 --- a/vendor/github.com/vmihailenco/msgpack/decode_slice.go +++ /dev/null @@ -1,192 +0,0 @@ -package msgpack - -import ( - "fmt" - "reflect" - - "github.com/vmihailenco/msgpack/codes" -) - -const sliceElemsAllocLimit = 1e4 - -var sliceStringPtrType = reflect.TypeOf((*[]string)(nil)) - -func (d *Decoder) DecodeArrayLen() (int, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - return d.arrayLen(c) -} - -func (d *Decoder) arrayLen(c codes.Code) (int, error) { - if c == codes.Nil { - return -1, nil - } else if c >= codes.FixedArrayLow && c <= codes.FixedArrayHigh { - return int(c & codes.FixedArrayMask), nil - } - switch c { - case codes.Array16: - n, err := d.uint16() - return int(n), err - case codes.Array32: - n, err := d.uint32() - return int(n), err - } - return 0, fmt.Errorf("msgpack: invalid code=%x decoding array length", c) -} - -func decodeStringSliceValue(d *Decoder, v reflect.Value) error { - ptr := v.Addr().Convert(sliceStringPtrType).Interface().(*[]string) - return d.decodeStringSlicePtr(ptr) -} - -func (d *Decoder) decodeStringSlicePtr(ptr *[]string) error { - n, err := d.DecodeArrayLen() - if err != nil { - return err - } - if n == -1 { - return nil - } - - ss := setStringsCap(*ptr, n) - for i := 0; i < n; i++ { - s, err := d.DecodeString() - if err != nil { - return err - } - ss = append(ss, s) - } - *ptr = ss - - return nil -} - -func setStringsCap(s []string, n int) []string { - if n > sliceElemsAllocLimit { - n = sliceElemsAllocLimit - } - - if s == nil { - return make([]string, 0, n) - } - - if cap(s) >= n { - return s[:0] - } - - s = s[:cap(s)] - s = append(s, make([]string, n-len(s))...) - return s[:0] -} - -func decodeSliceValue(d *Decoder, v reflect.Value) error { - n, err := d.DecodeArrayLen() - if err != nil { - return err - } - - if n == -1 { - v.Set(reflect.Zero(v.Type())) - return nil - } - if n == 0 && v.IsNil() { - v.Set(reflect.MakeSlice(v.Type(), 0, 0)) - return nil - } - - if v.Cap() >= n { - v.Set(v.Slice(0, n)) - } else if v.Len() < v.Cap() { - v.Set(v.Slice(0, v.Cap())) - } - - for i := 0; i < n; i++ { - if i >= v.Len() { - v.Set(growSliceValue(v, n)) - } - sv := v.Index(i) - if err := d.DecodeValue(sv); err != nil { - return err - } - } - - return nil -} - -func growSliceValue(v reflect.Value, n int) reflect.Value { - diff := n - v.Len() - if diff > sliceElemsAllocLimit { - diff = sliceElemsAllocLimit - } - v = reflect.AppendSlice(v, reflect.MakeSlice(v.Type(), diff, diff)) - return v -} - -func decodeArrayValue(d *Decoder, v reflect.Value) error { - n, err := d.DecodeArrayLen() - if err != nil { - return err - } - - if n == -1 { - return nil - } - - if n > v.Len() { - return fmt.Errorf("%s len is %d, but msgpack has %d elements", v.Type(), v.Len(), n) - } - for i := 0; i < n; i++ { - sv := v.Index(i) - if err := d.DecodeValue(sv); err != nil { - return err - } - } - - return nil -} - -func (d *Decoder) DecodeSlice() ([]interface{}, error) { - c, err := d.readCode() - if err != nil { - return nil, err - } - return d.decodeSlice(c) -} - -func (d *Decoder) decodeSlice(c codes.Code) ([]interface{}, error) { - n, err := d.arrayLen(c) - if err != nil { - return nil, err - } - if n == -1 { - return nil, nil - } - - s := make([]interface{}, 0, min(n, sliceElemsAllocLimit)) - for i := 0; i < n; i++ { - v, err := d.DecodeInterface() - if err != nil { - return nil, err - } - s = append(s, v) - } - - return s, nil -} - -func (d *Decoder) skipSlice(c codes.Code) error { - n, err := d.arrayLen(c) - if err != nil { - return err - } - - for i := 0; i < n; i++ { - if err := d.Skip(); err != nil { - return err - } - } - - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/decode_string.go b/vendor/github.com/vmihailenco/msgpack/decode_string.go deleted file mode 100644 index 5402022..0000000 --- a/vendor/github.com/vmihailenco/msgpack/decode_string.go +++ /dev/null @@ -1,175 +0,0 @@ -package msgpack - -import ( - "fmt" - "reflect" - - "github.com/vmihailenco/msgpack/codes" -) - -func (d *Decoder) bytesLen(c codes.Code) (int, error) { - if c == codes.Nil { - return -1, nil - } else if codes.IsFixedString(c) { - return int(c & codes.FixedStrMask), nil - } - switch c { - case codes.Str8, codes.Bin8: - n, err := d.uint8() - return int(n), err - case codes.Str16, codes.Bin16: - n, err := d.uint16() - return int(n), err - case codes.Str32, codes.Bin32: - n, err := d.uint32() - return int(n), err - } - return 0, fmt.Errorf("msgpack: invalid code=%x decoding bytes length", c) -} - -func (d *Decoder) DecodeString() (string, error) { - c, err := d.readCode() - if err != nil { - return "", err - } - return d.string(c) -} - -func (d *Decoder) string(c codes.Code) (string, error) { - n, err := d.bytesLen(c) - if err != nil { - return "", err - } - if n == -1 { - return "", nil - } - b, err := d.readN(n) - return string(b), err -} - -func decodeStringValue(d *Decoder, v reflect.Value) error { - s, err := d.DecodeString() - if err != nil { - return err - } - if err = mustSet(v); err != nil { - return err - } - v.SetString(s) - return nil -} - -func (d *Decoder) DecodeBytesLen() (int, error) { - c, err := d.readCode() - if err != nil { - return 0, err - } - return d.bytesLen(c) -} - -func (d *Decoder) DecodeBytes() ([]byte, error) { - c, err := d.readCode() - if err != nil { - return nil, err - } - return d.bytes(c, nil) -} - -func (d *Decoder) bytes(c codes.Code, b []byte) ([]byte, error) { - n, err := d.bytesLen(c) - if err != nil { - return nil, err - } - if n == -1 { - return nil, nil - } - return readN(d.r, b, n) -} - -func (d *Decoder) bytesNoCopy() ([]byte, error) { - c, err := d.readCode() - if err != nil { - return nil, err - } - n, err := d.bytesLen(c) - if err != nil { - return nil, err - } - if n == -1 { - return nil, nil - } - return d.readN(n) -} - -func (d *Decoder) decodeBytesPtr(ptr *[]byte) error { - c, err := d.readCode() - if err != nil { - return err - } - return d.bytesPtr(c, ptr) -} - -func (d *Decoder) bytesPtr(c codes.Code, ptr *[]byte) error { - n, err := d.bytesLen(c) - if err != nil { - return err - } - if n == -1 { - *ptr = nil - return nil - } - - *ptr, err = readN(d.r, *ptr, n) - return err -} - -func (d *Decoder) skipBytes(c codes.Code) error { - n, err := d.bytesLen(c) - if err != nil { - return err - } - if n == -1 { - return nil - } - return d.skipN(n) -} - -func decodeBytesValue(d *Decoder, v reflect.Value) error { - c, err := d.readCode() - if err != nil { - return err - } - - b, err := d.bytes(c, v.Bytes()) - if err != nil { - return err - } - - if err = mustSet(v); err != nil { - return err - } - v.SetBytes(b) - - return nil -} - -func decodeByteArrayValue(d *Decoder, v reflect.Value) error { - c, err := d.readCode() - if err != nil { - return err - } - - n, err := d.bytesLen(c) - if err != nil { - return err - } - if n == -1 { - return nil - } - if n > v.Len() { - return fmt.Errorf("%s len is %d, but msgpack has %d elements", v.Type(), v.Len(), n) - } - - b := v.Slice(0, n).Bytes() - return d.readFull(b) -} diff --git a/vendor/github.com/vmihailenco/msgpack/decode_value.go b/vendor/github.com/vmihailenco/msgpack/decode_value.go deleted file mode 100644 index 66db2de..0000000 --- a/vendor/github.com/vmihailenco/msgpack/decode_value.go +++ /dev/null @@ -1,276 +0,0 @@ -package msgpack - -import ( - "errors" - "fmt" - "reflect" - - "github.com/vmihailenco/msgpack/codes" -) - -var interfaceType = reflect.TypeOf((*interface{})(nil)).Elem() -var stringType = reflect.TypeOf((*string)(nil)).Elem() - -var valueDecoders []decoderFunc - -func init() { - valueDecoders = []decoderFunc{ - reflect.Bool: decodeBoolValue, - reflect.Int: decodeInt64Value, - reflect.Int8: decodeInt64Value, - reflect.Int16: decodeInt64Value, - reflect.Int32: decodeInt64Value, - reflect.Int64: decodeInt64Value, - reflect.Uint: decodeUint64Value, - reflect.Uint8: decodeUint64Value, - reflect.Uint16: decodeUint64Value, - reflect.Uint32: decodeUint64Value, - reflect.Uint64: decodeUint64Value, - reflect.Float32: decodeFloat32Value, - reflect.Float64: decodeFloat64Value, - reflect.Complex64: decodeUnsupportedValue, - reflect.Complex128: decodeUnsupportedValue, - reflect.Array: decodeArrayValue, - reflect.Chan: decodeUnsupportedValue, - reflect.Func: decodeUnsupportedValue, - reflect.Interface: decodeInterfaceValue, - reflect.Map: decodeMapValue, - reflect.Ptr: decodeUnsupportedValue, - reflect.Slice: decodeSliceValue, - reflect.String: decodeStringValue, - reflect.Struct: decodeStructValue, - reflect.UnsafePointer: decodeUnsupportedValue, - } -} - -func mustSet(v reflect.Value) error { - if !v.CanSet() { - return fmt.Errorf("msgpack: Decode(nonsettable %s)", v.Type()) - } - return nil -} - -func getDecoder(typ reflect.Type) decoderFunc { - kind := typ.Kind() - - if decoder, ok := typDecMap[typ]; ok { - return decoder - } - - if typ.Implements(customDecoderType) { - return decodeCustomValue - } - if typ.Implements(unmarshalerType) { - return unmarshalValue - } - - // Addressable struct field value. - if kind != reflect.Ptr { - ptr := reflect.PtrTo(typ) - if ptr.Implements(customDecoderType) { - return decodeCustomValueAddr - } - if ptr.Implements(unmarshalerType) { - return unmarshalValueAddr - } - } - - switch kind { - case reflect.Ptr: - return ptrDecoderFunc(typ) - case reflect.Slice: - elem := typ.Elem() - switch elem.Kind() { - case reflect.Uint8: - return decodeBytesValue - } - switch elem { - case stringType: - return decodeStringSliceValue - } - case reflect.Array: - if typ.Elem().Kind() == reflect.Uint8 { - return decodeByteArrayValue - } - case reflect.Map: - if typ.Key() == stringType { - switch typ.Elem() { - case stringType: - return decodeMapStringStringValue - case interfaceType: - return decodeMapStringInterfaceValue - } - } - } - return valueDecoders[kind] -} - -func ptrDecoderFunc(typ reflect.Type) decoderFunc { - decoder := getDecoder(typ.Elem()) - return func(d *Decoder, v reflect.Value) error { - if d.hasNilCode() { - v.Set(reflect.Zero(v.Type())) - return d.DecodeNil() - } - if v.IsNil() { - if err := mustSet(v); err != nil { - return err - } - v.Set(reflect.New(v.Type().Elem())) - } - return decoder(d, v.Elem()) - } -} - -func decodeCustomValueAddr(d *Decoder, v reflect.Value) error { - if !v.CanAddr() { - return fmt.Errorf("msgpack: Decode(nonaddressable %T)", v.Interface()) - } - return decodeCustomValue(d, v.Addr()) -} - -func decodeCustomValue(d *Decoder, v reflect.Value) error { - c, err := d.PeekCode() - if err != nil { - return err - } - - if codes.IsExt(c) { - c, err = d.readCode() - if err != nil { - return err - } - - _, err = d.parseExtLen(c) - if err != nil { - return err - } - - _, err = d.readCode() - if err != nil { - return err - } - - c, err = d.PeekCode() - if err != nil { - return err - } - } - - if c == codes.Nil { - return d.decodeNilValue(v) - } - - if v.IsNil() { - v.Set(reflect.New(v.Type().Elem())) - } - - decoder := v.Interface().(CustomDecoder) - return decoder.DecodeMsgpack(d) -} - -func unmarshalValueAddr(d *Decoder, v reflect.Value) error { - if !v.CanAddr() { - return fmt.Errorf("msgpack: Decode(nonaddressable %T)", v.Interface()) - } - return unmarshalValue(d, v.Addr()) -} - -func unmarshalValue(d *Decoder, v reflect.Value) error { - c, err := d.PeekCode() - if err != nil { - return err - } - - extLen := d.extLen - d.extLen = 0 - - if extLen == 0 && codes.IsExt(c) { - c, err = d.readCode() - if err != nil { - return err - } - - extLen, err = d.parseExtLen(c) - if err != nil { - return err - } - - _, err = d.readCode() - if err != nil { - return err - } - - c, err = d.PeekCode() - if err != nil { - return err - } - } - - if c == codes.Nil { - return d.decodeNilValue(v) - } - - if v.IsNil() { - v.Set(reflect.New(v.Type().Elem())) - } - - if extLen != 0 { - b, err := d.readN(extLen) - if err != nil { - return err - } - d.rec = b - } else { - d.rec = makeBuffer() - if err := d.Skip(); err != nil { - return err - } - } - - unmarshaler := v.Interface().(Unmarshaler) - err = unmarshaler.UnmarshalMsgpack(d.rec) - d.rec = nil - return err -} - -func decodeBoolValue(d *Decoder, v reflect.Value) error { - flag, err := d.DecodeBool() - if err != nil { - return err - } - if err = mustSet(v); err != nil { - return err - } - v.SetBool(flag) - return nil -} - -func decodeInterfaceValue(d *Decoder, v reflect.Value) error { - if v.IsNil() { - return d.interfaceValue(v) - } - return d.DecodeValue(v.Elem()) -} - -func (d *Decoder) interfaceValue(v reflect.Value) error { - vv, err := d.DecodeInterface() - if err != nil { - return err - } - if vv != nil { - if v.Type() == errorType { - if vv, ok := vv.(string); ok { - v.Set(reflect.ValueOf(errors.New(vv))) - return nil - } - } - - v.Set(reflect.ValueOf(vv)) - } - return nil -} - -func decodeUnsupportedValue(d *Decoder, v reflect.Value) error { - return fmt.Errorf("msgpack: Decode(unsupported %s)", v.Type()) -} diff --git a/vendor/github.com/vmihailenco/msgpack/encode.go b/vendor/github.com/vmihailenco/msgpack/encode.go deleted file mode 100644 index 87131ca..0000000 --- a/vendor/github.com/vmihailenco/msgpack/encode.go +++ /dev/null @@ -1,140 +0,0 @@ -package msgpack - -import ( - "bytes" - "io" - "reflect" - "time" - - "github.com/vmihailenco/msgpack/codes" -) - -type writer interface { - io.Writer - WriteByte(byte) error - WriteString(string) (int, error) -} - -type byteWriter struct { - io.Writer -} - -func (w byteWriter) WriteByte(b byte) error { - _, err := w.Write([]byte{b}) - return err -} - -func (w byteWriter) WriteString(s string) (int, error) { - return w.Write([]byte(s)) -} - -// Marshal returns the MessagePack encoding of v. -func Marshal(v ...interface{}) ([]byte, error) { - var buf bytes.Buffer - err := NewEncoder(&buf).Encode(v...) - return buf.Bytes(), err -} - -type Encoder struct { - w writer - buf []byte - - sortMapKeys bool - structAsArray bool -} - -// NewEncoder returns a new encoder that writes to w. -func NewEncoder(w io.Writer) *Encoder { - bw, ok := w.(writer) - if !ok { - bw = byteWriter{Writer: w} - } - return &Encoder{ - w: bw, - buf: make([]byte, 9), - } -} - -// SortMapKeys causes the Encoder to encode map keys in increasing order. -// Supported map types are: -// - map[string]string -// - map[string]interface{} -func (e *Encoder) SortMapKeys(v bool) *Encoder { - e.sortMapKeys = v - return e -} - -// StructAsArray causes the Encoder to encode Go structs as MessagePack arrays. -func (e *Encoder) StructAsArray(v bool) *Encoder { - e.structAsArray = v - return e -} - -func (e *Encoder) Encode(v ...interface{}) error { - for _, vv := range v { - if err := e.encode(vv); err != nil { - return err - } - } - return nil -} - -func (e *Encoder) encode(v interface{}) error { - switch v := v.(type) { - case nil: - return e.EncodeNil() - case string: - return e.EncodeString(v) - case []byte: - return e.EncodeBytes(v) - case int: - return e.EncodeInt(int64(v)) - case int64: - return e.EncodeInt(v) - case uint: - return e.EncodeUint(uint64(v)) - case uint64: - return e.EncodeUint(v) - case bool: - return e.EncodeBool(v) - case float32: - return e.EncodeFloat32(v) - case float64: - return e.EncodeFloat64(v) - case time.Duration: - return e.EncodeInt(int64(v)) - case time.Time: - return e.EncodeTime(v) - } - return e.EncodeValue(reflect.ValueOf(v)) -} - -func (e *Encoder) EncodeValue(v reflect.Value) error { - encode := getEncoder(v.Type()) - return encode(e, v) -} - -func (e *Encoder) EncodeNil() error { - return e.writeCode(codes.Nil) -} - -func (e *Encoder) EncodeBool(value bool) error { - if value { - return e.writeCode(codes.True) - } - return e.writeCode(codes.False) -} - -func (e *Encoder) writeCode(c codes.Code) error { - return e.w.WriteByte(byte(c)) -} - -func (e *Encoder) write(b []byte) error { - _, err := e.w.Write(b) - return err -} - -func (e *Encoder) writeString(s string) error { - _, err := e.w.WriteString(s) - return err -} diff --git a/vendor/github.com/vmihailenco/msgpack/encode_map.go b/vendor/github.com/vmihailenco/msgpack/encode_map.go deleted file mode 100644 index e43bdb2..0000000 --- a/vendor/github.com/vmihailenco/msgpack/encode_map.go +++ /dev/null @@ -1,166 +0,0 @@ -package msgpack - -import ( - "reflect" - "sort" - - "github.com/vmihailenco/msgpack/codes" -) - -func encodeMapValue(e *Encoder, v reflect.Value) error { - if v.IsNil() { - return e.EncodeNil() - } - - if err := e.EncodeMapLen(v.Len()); err != nil { - return err - } - - for _, key := range v.MapKeys() { - if err := e.EncodeValue(key); err != nil { - return err - } - if err := e.EncodeValue(v.MapIndex(key)); err != nil { - return err - } - } - - return nil -} - -func encodeMapStringStringValue(e *Encoder, v reflect.Value) error { - if v.IsNil() { - return e.EncodeNil() - } - - if err := e.EncodeMapLen(v.Len()); err != nil { - return err - } - - m := v.Convert(mapStringStringType).Interface().(map[string]string) - if e.sortMapKeys { - return e.encodeSortedMapStringString(m) - } - - for mk, mv := range m { - if err := e.EncodeString(mk); err != nil { - return err - } - if err := e.EncodeString(mv); err != nil { - return err - } - } - - return nil -} - -func encodeMapStringInterfaceValue(e *Encoder, v reflect.Value) error { - if v.IsNil() { - return e.EncodeNil() - } - - if err := e.EncodeMapLen(v.Len()); err != nil { - return err - } - - m := v.Convert(mapStringInterfaceType).Interface().(map[string]interface{}) - if e.sortMapKeys { - return e.encodeSortedMapStringInterface(m) - } - - for mk, mv := range m { - if err := e.EncodeString(mk); err != nil { - return err - } - if err := e.Encode(mv); err != nil { - return err - } - } - - return nil -} - -func (e *Encoder) encodeSortedMapStringString(m map[string]string) error { - keys := make([]string, 0, len(m)) - for k, _ := range m { - keys = append(keys, k) - } - sort.Strings(keys) - - for _, k := range keys { - err := e.EncodeString(k) - if err != nil { - return err - } - if err = e.EncodeString(m[k]); err != nil { - return err - } - } - - return nil -} - -func (e *Encoder) encodeSortedMapStringInterface(m map[string]interface{}) error { - keys := make([]string, 0, len(m)) - for k, _ := range m { - keys = append(keys, k) - } - sort.Strings(keys) - - for _, k := range keys { - err := e.EncodeString(k) - if err != nil { - return err - } - if err = e.Encode(m[k]); err != nil { - return err - } - } - - return nil -} - -func (e *Encoder) EncodeMapLen(l int) error { - if l < 16 { - return e.writeCode(codes.FixedMapLow | codes.Code(l)) - } - if l < 65536 { - return e.write2(codes.Map16, uint64(l)) - } - return e.write4(codes.Map32, uint32(l)) -} - -func encodeStructValue(e *Encoder, strct reflect.Value) error { - structFields := structs.Fields(strct.Type()) - if e.structAsArray || structFields.asArray { - return encodeStructValueAsArray(e, strct, structFields.List) - } - fields := structFields.OmitEmpty(strct) - - if err := e.EncodeMapLen(len(fields)); err != nil { - return err - } - - for _, f := range fields { - if err := e.EncodeString(f.name); err != nil { - return err - } - if err := f.EncodeValue(e, strct); err != nil { - return err - } - } - - return nil -} - -func encodeStructValueAsArray(e *Encoder, strct reflect.Value, fields []*field) error { - if err := e.EncodeArrayLen(len(fields)); err != nil { - return err - } - for _, f := range fields { - if err := f.EncodeValue(e, strct); err != nil { - return err - } - } - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/encode_number.go b/vendor/github.com/vmihailenco/msgpack/encode_number.go deleted file mode 100644 index e361585..0000000 --- a/vendor/github.com/vmihailenco/msgpack/encode_number.go +++ /dev/null @@ -1,108 +0,0 @@ -package msgpack - -import ( - "math" - "reflect" - - "github.com/vmihailenco/msgpack/codes" -) - -// EncodeUint encodes an uint64 in 1, 2, 3, 5, or 9 bytes. -func (e *Encoder) EncodeUint(v uint64) error { - if v <= math.MaxInt8 { - return e.w.WriteByte(byte(v)) - } - if v <= math.MaxUint8 { - return e.write1(codes.Uint8, v) - } - if v <= math.MaxUint16 { - return e.write2(codes.Uint16, v) - } - if v <= math.MaxUint32 { - return e.write4(codes.Uint32, uint32(v)) - } - return e.write8(codes.Uint64, v) -} - -// EncodeInt encodes an int64 in 1, 2, 3, 5, or 9 bytes. -func (e *Encoder) EncodeInt(v int64) error { - if v >= 0 { - return e.EncodeUint(uint64(v)) - } - if v >= int64(int8(codes.NegFixedNumLow)) { - return e.w.WriteByte(byte(v)) - } - if v >= math.MinInt8 { - return e.write1(codes.Int8, uint64(v)) - } - if v >= math.MinInt16 { - return e.write2(codes.Int16, uint64(v)) - } - if v >= math.MinInt32 { - return e.write4(codes.Int32, uint32(v)) - } - return e.write8(codes.Int64, uint64(v)) -} - -func (e *Encoder) EncodeFloat32(n float32) error { - return e.write4(codes.Float, math.Float32bits(n)) -} - -func (e *Encoder) EncodeFloat64(n float64) error { - return e.write8(codes.Double, math.Float64bits(n)) -} - -func (e *Encoder) write1(code codes.Code, n uint64) error { - e.buf = e.buf[:2] - e.buf[0] = byte(code) - e.buf[1] = byte(n) - return e.write(e.buf) -} - -func (e *Encoder) write2(code codes.Code, n uint64) error { - e.buf = e.buf[:3] - e.buf[0] = byte(code) - e.buf[1] = byte(n >> 8) - e.buf[2] = byte(n) - return e.write(e.buf) -} - -func (e *Encoder) write4(code codes.Code, n uint32) error { - e.buf = e.buf[:5] - e.buf[0] = byte(code) - e.buf[1] = byte(n >> 24) - e.buf[2] = byte(n >> 16) - e.buf[3] = byte(n >> 8) - e.buf[4] = byte(n) - return e.write(e.buf) -} - -func (e *Encoder) write8(code codes.Code, n uint64) error { - e.buf = e.buf[:9] - e.buf[0] = byte(code) - e.buf[1] = byte(n >> 56) - e.buf[2] = byte(n >> 48) - e.buf[3] = byte(n >> 40) - e.buf[4] = byte(n >> 32) - e.buf[5] = byte(n >> 24) - e.buf[6] = byte(n >> 16) - e.buf[7] = byte(n >> 8) - e.buf[8] = byte(n) - return e.write(e.buf) -} - -func encodeInt64Value(e *Encoder, v reflect.Value) error { - return e.EncodeInt(v.Int()) -} - -func encodeUint64Value(e *Encoder, v reflect.Value) error { - return e.EncodeUint(v.Uint()) -} - -func encodeFloat32Value(e *Encoder, v reflect.Value) error { - return e.EncodeFloat32(float32(v.Float())) -} - -func encodeFloat64Value(e *Encoder, v reflect.Value) error { - return e.EncodeFloat64(v.Float()) -} diff --git a/vendor/github.com/vmihailenco/msgpack/encode_slice.go b/vendor/github.com/vmihailenco/msgpack/encode_slice.go deleted file mode 100644 index 65f25bb..0000000 --- a/vendor/github.com/vmihailenco/msgpack/encode_slice.go +++ /dev/null @@ -1,115 +0,0 @@ -package msgpack - -import ( - "reflect" - - "github.com/vmihailenco/msgpack/codes" -) - -func encodeStringValue(e *Encoder, v reflect.Value) error { - return e.EncodeString(v.String()) -} - -func encodeByteSliceValue(e *Encoder, v reflect.Value) error { - return e.EncodeBytes(v.Bytes()) -} - -func encodeByteArrayValue(e *Encoder, v reflect.Value) error { - if err := e.EncodeBytesLen(v.Len()); err != nil { - return err - } - - if v.CanAddr() { - b := v.Slice(0, v.Len()).Bytes() - return e.write(b) - } - - b := make([]byte, v.Len()) - reflect.Copy(reflect.ValueOf(b), v) - return e.write(b) -} - -func (e *Encoder) EncodeBytesLen(l int) error { - if l < 256 { - return e.write1(codes.Bin8, uint64(l)) - } - if l < 65536 { - return e.write2(codes.Bin16, uint64(l)) - } - return e.write4(codes.Bin32, uint32(l)) -} - -func (e *Encoder) encodeStrLen(l int) error { - if l < 32 { - return e.writeCode(codes.FixedStrLow | codes.Code(l)) - } - if l < 256 { - return e.write1(codes.Str8, uint64(l)) - } - if l < 65536 { - return e.write2(codes.Str16, uint64(l)) - } - return e.write4(codes.Str32, uint32(l)) -} - -func (e *Encoder) EncodeString(v string) error { - if err := e.encodeStrLen(len(v)); err != nil { - return err - } - return e.writeString(v) -} - -func (e *Encoder) EncodeBytes(v []byte) error { - if v == nil { - return e.EncodeNil() - } - if err := e.EncodeBytesLen(len(v)); err != nil { - return err - } - return e.write(v) -} - -func (e *Encoder) EncodeArrayLen(l int) error { - if l < 16 { - return e.writeCode(codes.FixedArrayLow | codes.Code(l)) - } - if l < 65536 { - return e.write2(codes.Array16, uint64(l)) - } - return e.write4(codes.Array32, uint32(l)) -} - -func (e *Encoder) encodeStringSlice(s []string) error { - if s == nil { - return e.EncodeNil() - } - if err := e.EncodeArrayLen(len(s)); err != nil { - return err - } - for _, v := range s { - if err := e.EncodeString(v); err != nil { - return err - } - } - return nil -} - -func encodeSliceValue(e *Encoder, v reflect.Value) error { - if v.IsNil() { - return e.EncodeNil() - } - return encodeArrayValue(e, v) -} - -func encodeArrayValue(e *Encoder, v reflect.Value) error { - l := v.Len() - if err := e.EncodeArrayLen(l); err != nil { - return err - } - for i := 0; i < l; i++ { - if err := e.EncodeValue(v.Index(i)); err != nil { - return err - } - } - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/encode_value.go b/vendor/github.com/vmihailenco/msgpack/encode_value.go deleted file mode 100644 index 2f5a350..0000000 --- a/vendor/github.com/vmihailenco/msgpack/encode_value.go +++ /dev/null @@ -1,167 +0,0 @@ -package msgpack - -import ( - "fmt" - "reflect" -) - -var valueEncoders []encoderFunc - -func init() { - valueEncoders = []encoderFunc{ - reflect.Bool: encodeBoolValue, - reflect.Int: encodeInt64Value, - reflect.Int8: encodeInt64Value, - reflect.Int16: encodeInt64Value, - reflect.Int32: encodeInt64Value, - reflect.Int64: encodeInt64Value, - reflect.Uint: encodeUint64Value, - reflect.Uint8: encodeUint64Value, - reflect.Uint16: encodeUint64Value, - reflect.Uint32: encodeUint64Value, - reflect.Uint64: encodeUint64Value, - reflect.Float32: encodeFloat32Value, - reflect.Float64: encodeFloat64Value, - reflect.Complex64: encodeUnsupportedValue, - reflect.Complex128: encodeUnsupportedValue, - reflect.Array: encodeArrayValue, - reflect.Chan: encodeUnsupportedValue, - reflect.Func: encodeUnsupportedValue, - reflect.Interface: encodeInterfaceValue, - reflect.Map: encodeMapValue, - reflect.Ptr: encodeUnsupportedValue, - reflect.Slice: encodeSliceValue, - reflect.String: encodeStringValue, - reflect.Struct: encodeStructValue, - reflect.UnsafePointer: encodeUnsupportedValue, - } -} - -func getEncoder(typ reflect.Type) encoderFunc { - if encoder, ok := typEncMap[typ]; ok { - return encoder - } - - if typ.Implements(customEncoderType) { - return encodeCustomValue - } - if typ.Implements(marshalerType) { - return marshalValue - } - - kind := typ.Kind() - - // Addressable struct field value. - if kind != reflect.Ptr { - ptr := reflect.PtrTo(typ) - if ptr.Implements(customEncoderType) { - return encodeCustomValuePtr - } - if ptr.Implements(marshalerType) { - return marshalValuePtr - } - } - - if typ == errorType { - return encodeErrorValue - } - - switch kind { - case reflect.Ptr: - return ptrEncoderFunc(typ) - case reflect.Slice: - if typ.Elem().Kind() == reflect.Uint8 { - return encodeByteSliceValue - } - case reflect.Array: - if typ.Elem().Kind() == reflect.Uint8 { - return encodeByteArrayValue - } - case reflect.Map: - if typ.Key() == stringType { - switch typ.Elem() { - case stringType: - return encodeMapStringStringValue - case interfaceType: - return encodeMapStringInterfaceValue - } - } - } - return valueEncoders[kind] -} - -func ptrEncoderFunc(typ reflect.Type) encoderFunc { - encoder := getEncoder(typ.Elem()) - return func(e *Encoder, v reflect.Value) error { - if v.IsNil() { - return e.EncodeNil() - } - return encoder(e, v.Elem()) - } -} - -func encodeCustomValuePtr(e *Encoder, v reflect.Value) error { - if !v.CanAddr() { - return fmt.Errorf("msgpack: Encode(non-addressable %T)", v.Interface()) - } - encoder := v.Addr().Interface().(CustomEncoder) - return encoder.EncodeMsgpack(e) -} - -func encodeCustomValue(e *Encoder, v reflect.Value) error { - switch v.Kind() { - case reflect.Chan, reflect.Func, reflect.Interface, reflect.Map, reflect.Ptr, reflect.Slice: - if v.IsNil() { - return e.EncodeNil() - } - } - - encoder := v.Interface().(CustomEncoder) - return encoder.EncodeMsgpack(e) -} - -func marshalValuePtr(e *Encoder, v reflect.Value) error { - if !v.CanAddr() { - return fmt.Errorf("msgpack: Encode(non-addressable %T)", v.Interface()) - } - return marshalValue(e, v.Addr()) -} - -func marshalValue(e *Encoder, v reflect.Value) error { - switch v.Kind() { - case reflect.Chan, reflect.Func, reflect.Interface, reflect.Map, reflect.Ptr, reflect.Slice: - if v.IsNil() { - return e.EncodeNil() - } - } - - marshaler := v.Interface().(Marshaler) - b, err := marshaler.MarshalMsgpack() - if err != nil { - return err - } - _, err = e.w.Write(b) - return err -} - -func encodeBoolValue(e *Encoder, v reflect.Value) error { - return e.EncodeBool(v.Bool()) -} - -func encodeInterfaceValue(e *Encoder, v reflect.Value) error { - if v.IsNil() { - return e.EncodeNil() - } - return e.EncodeValue(v.Elem()) -} - -func encodeErrorValue(e *Encoder, v reflect.Value) error { - if v.IsNil() { - return e.EncodeNil() - } - return e.EncodeString(v.Interface().(error).Error()) -} - -func encodeUnsupportedValue(e *Encoder, v reflect.Value) error { - return fmt.Errorf("msgpack: Encode(unsupported %s)", v.Type()) -} diff --git a/vendor/github.com/vmihailenco/msgpack/example_CustomEncoder_test.go b/vendor/github.com/vmihailenco/msgpack/example_CustomEncoder_test.go deleted file mode 100644 index 1098cfc..0000000 --- a/vendor/github.com/vmihailenco/msgpack/example_CustomEncoder_test.go +++ /dev/null @@ -1,38 +0,0 @@ -package msgpack_test - -import ( - "fmt" - - "github.com/vmihailenco/msgpack" -) - -type customStruct struct { - S string - N int -} - -var _ msgpack.CustomEncoder = (*customStruct)(nil) -var _ msgpack.CustomDecoder = (*customStruct)(nil) - -func (s *customStruct) EncodeMsgpack(enc *msgpack.Encoder) error { - return enc.Encode(s.S, s.N) -} - -func (s *customStruct) DecodeMsgpack(dec *msgpack.Decoder) error { - return dec.Decode(&s.S, &s.N) -} - -func ExampleCustomEncoder() { - b, err := msgpack.Marshal(&customStruct{S: "hello", N: 42}) - if err != nil { - panic(err) - } - - var v customStruct - err = msgpack.Unmarshal(b, &v) - if err != nil { - panic(err) - } - fmt.Printf("%#v", v) - // Output: msgpack_test.customStruct{S:"hello", N:42} -} diff --git a/vendor/github.com/vmihailenco/msgpack/example_registerExt_test.go b/vendor/github.com/vmihailenco/msgpack/example_registerExt_test.go deleted file mode 100644 index a54ff26..0000000 --- a/vendor/github.com/vmihailenco/msgpack/example_registerExt_test.go +++ /dev/null @@ -1,62 +0,0 @@ -package msgpack_test - -import ( - "encoding/binary" - "fmt" - "time" - - "github.com/vmihailenco/msgpack" -) - -func init() { - msgpack.RegisterExt(0, (*EventTime)(nil)) -} - -// https://github.com/fluent/fluentd/wiki/Forward-Protocol-Specification-v1#eventtime-ext-format -type EventTime struct { - time.Time -} - -var _ msgpack.Marshaler = (*EventTime)(nil) -var _ msgpack.Unmarshaler = (*EventTime)(nil) - -func (tm *EventTime) MarshalMsgpack() ([]byte, error) { - b := make([]byte, 8) - binary.BigEndian.PutUint32(b, uint32(tm.Unix())) - binary.BigEndian.PutUint32(b[4:], uint32(tm.Nanosecond())) - return b, nil -} - -func (tm *EventTime) UnmarshalMsgpack(b []byte) error { - if len(b) != 8 { - return fmt.Errorf("invalid data length: got %d, wanted 8", len(b)) - } - sec := binary.BigEndian.Uint32(b) - usec := binary.BigEndian.Uint32(b[4:]) - tm.Time = time.Unix(int64(sec), int64(usec)) - return nil -} - -func ExampleRegisterExt() { - b, err := msgpack.Marshal(&EventTime{time.Unix(123456789, 123)}) - if err != nil { - panic(err) - } - - var v interface{} - err = msgpack.Unmarshal(b, &v) - if err != nil { - panic(err) - } - fmt.Println(v.(*EventTime).UTC()) - - tm := new(EventTime) - err = msgpack.Unmarshal(b, tm) - if err != nil { - panic(err) - } - fmt.Println(tm.UTC()) - - // Output: 1973-11-29 21:33:09.000000123 +0000 UTC - // 1973-11-29 21:33:09.000000123 +0000 UTC -} diff --git a/vendor/github.com/vmihailenco/msgpack/example_test.go b/vendor/github.com/vmihailenco/msgpack/example_test.go deleted file mode 100644 index ea1beee..0000000 --- a/vendor/github.com/vmihailenco/msgpack/example_test.go +++ /dev/null @@ -1,195 +0,0 @@ -package msgpack_test - -import ( - "bytes" - "fmt" - - "github.com/vmihailenco/msgpack" -) - -func ExampleMarshal() { - type Item struct { - Foo string - } - - b, err := msgpack.Marshal(&Item{Foo: "bar"}) - if err != nil { - panic(err) - } - - var item Item - err = msgpack.Unmarshal(b, &item) - if err != nil { - panic(err) - } - fmt.Println(item.Foo) - // Output: bar -} - -func ExampleMarshal_mapStringInterface() { - in := map[string]interface{}{"foo": 1, "hello": "world"} - b, err := msgpack.Marshal(in) - if err != nil { - panic(err) - } - - var out map[string]interface{} - err = msgpack.Unmarshal(b, &out) - if err != nil { - panic(err) - } - - fmt.Println("foo =", out["foo"]) - fmt.Println("hello =", out["hello"]) - - // Output: - // foo = 1 - // hello = world -} - -func ExampleDecoder_SetDecodeMapFunc() { - buf := new(bytes.Buffer) - - enc := msgpack.NewEncoder(buf) - in := map[string]string{"hello": "world"} - err := enc.Encode(in) - if err != nil { - panic(err) - } - - dec := msgpack.NewDecoder(buf) - dec.SetDecodeMapFunc(func(d *msgpack.Decoder) (interface{}, error) { - n, err := d.DecodeMapLen() - if err != nil { - return nil, err - } - - m := make(map[string]string, n) - for i := 0; i < n; i++ { - mk, err := d.DecodeString() - if err != nil { - return nil, err - } - - mv, err := d.DecodeString() - if err != nil { - return nil, err - } - - m[mk] = mv - } - return m, nil - }) - - out, err := dec.DecodeInterface() - if err != nil { - panic(err) - } - fmt.Println(out) - // Output: map[hello:world] -} - -func ExampleDecoder_Query() { - b, err := msgpack.Marshal([]map[string]interface{}{ - {"id": 1, "attrs": map[string]interface{}{"phone": 12345}}, - {"id": 2, "attrs": map[string]interface{}{"phone": 54321}}, - }) - if err != nil { - panic(err) - } - - dec := msgpack.NewDecoder(bytes.NewBuffer(b)) - values, err := dec.Query("*.attrs.phone") - if err != nil { - panic(err) - } - fmt.Println("phones are", values) - - dec.Reset(bytes.NewBuffer(b)) - values, err = dec.Query("1.attrs.phone") - if err != nil { - panic(err) - } - fmt.Println("2nd phone is", values[0]) - // Output: phones are [12345 54321] - // 2nd phone is 54321 -} - -func ExampleEncoder_StructAsArray() { - type Item struct { - Foo string - Bar string - } - - var buf bytes.Buffer - enc := msgpack.NewEncoder(&buf).StructAsArray(true) - err := enc.Encode(&Item{Foo: "foo", Bar: "bar"}) - if err != nil { - panic(err) - } - - dec := msgpack.NewDecoder(&buf) - v, err := dec.DecodeInterface() - if err != nil { - panic(err) - } - fmt.Println(v) - // Output: [foo bar] -} - -func ExampleMarshal_asArray() { - type Item struct { - _msgpack struct{} `msgpack:",asArray"` - Foo string - Bar string - } - - var buf bytes.Buffer - enc := msgpack.NewEncoder(&buf) - err := enc.Encode(&Item{Foo: "foo", Bar: "bar"}) - if err != nil { - panic(err) - } - - dec := msgpack.NewDecoder(&buf) - v, err := dec.DecodeInterface() - if err != nil { - panic(err) - } - fmt.Println(v) - // Output: [foo bar] -} - -func ExampleMarshal_omitEmpty() { - type Item struct { - Foo string - Bar string - } - - item := &Item{ - Foo: "hello", - } - b, err := msgpack.Marshal(item) - if err != nil { - panic(err) - } - fmt.Printf("item: %q\n", b) - - type ItemOmitEmpty struct { - _msgpack struct{} `msgpack:",omitempty"` - Foo string - Bar string - } - - itemOmitEmpty := &ItemOmitEmpty{ - Foo: "hello", - } - b, err = msgpack.Marshal(itemOmitEmpty) - if err != nil { - panic(err) - } - fmt.Printf("item2: %q\n", b) - - // Output: item: "\x82\xa3Foo\xa5hello\xa3Bar\xa0" - // item2: "\x81\xa3Foo\xa5hello" -} diff --git a/vendor/github.com/vmihailenco/msgpack/ext.go b/vendor/github.com/vmihailenco/msgpack/ext.go deleted file mode 100644 index d11d5f7..0000000 --- a/vendor/github.com/vmihailenco/msgpack/ext.go +++ /dev/null @@ -1,188 +0,0 @@ -package msgpack - -import ( - "bytes" - "fmt" - "reflect" - "sync" - - "github.com/vmihailenco/msgpack/codes" -) - -var extTypes = make(map[int8]reflect.Type) - -var bufferPool = &sync.Pool{ - New: func() interface{} { - return new(bytes.Buffer) - }, -} - -// RegisterExt records a type, identified by a value for that type, -// under the provided id. That id will identify the concrete type of a value -// sent or received as an interface variable. Only types that will be -// transferred as implementations of interface values need to be registered. -// Expecting to be used only during initialization, it panics if the mapping -// between types and ids is not a bijection. -func RegisterExt(id int8, value interface{}) { - typ := reflect.TypeOf(value) - if typ.Kind() == reflect.Ptr { - typ = typ.Elem() - } - ptr := reflect.PtrTo(typ) - - if _, ok := extTypes[id]; ok { - panic(fmt.Errorf("msgpack: ext with id=%d is already registered", id)) - } - - registerExt(id, ptr, getEncoder(ptr), nil) - registerExt(id, typ, getEncoder(typ), getDecoder(typ)) -} - -func registerExt(id int8, typ reflect.Type, enc encoderFunc, dec decoderFunc) { - if dec != nil { - extTypes[id] = typ - } - if enc != nil { - typEncMap[typ] = makeExtEncoder(id, enc) - } - if dec != nil { - typDecMap[typ] = dec - } -} - -func makeExtEncoder(typeId int8, enc encoderFunc) encoderFunc { - return func(e *Encoder, v reflect.Value) error { - buf := bufferPool.Get().(*bytes.Buffer) - defer bufferPool.Put(buf) - buf.Reset() - - oldw := e.w - e.w = buf - err := enc(e, v) - e.w = oldw - - if err != nil { - return err - } - - if err := e.encodeExtLen(buf.Len()); err != nil { - return err - } - if err := e.w.WriteByte(byte(typeId)); err != nil { - return err - } - return e.write(buf.Bytes()) - } -} - -func (e *Encoder) encodeExtLen(l int) error { - switch l { - case 1: - return e.writeCode(codes.FixExt1) - case 2: - return e.writeCode(codes.FixExt2) - case 4: - return e.writeCode(codes.FixExt4) - case 8: - return e.writeCode(codes.FixExt8) - case 16: - return e.writeCode(codes.FixExt16) - } - if l < 256 { - return e.write1(codes.Ext8, uint64(l)) - } - if l < 65536 { - return e.write2(codes.Ext16, uint64(l)) - } - return e.write4(codes.Ext32, uint32(l)) -} - -func (d *Decoder) parseExtLen(c codes.Code) (int, error) { - switch c { - case codes.FixExt1: - return 1, nil - case codes.FixExt2: - return 2, nil - case codes.FixExt4: - return 4, nil - case codes.FixExt8: - return 8, nil - case codes.FixExt16: - return 16, nil - case codes.Ext8: - n, err := d.uint8() - return int(n), err - case codes.Ext16: - n, err := d.uint16() - return int(n), err - case codes.Ext32: - n, err := d.uint32() - return int(n), err - default: - return 0, fmt.Errorf("msgpack: invalid code=%x decoding ext length", c) - } -} - -func (d *Decoder) extInterface(c codes.Code) (interface{}, error) { - extLen, err := d.parseExtLen(c) - if err != nil { - return nil, err - } - - extId, err := d.readCode() - if err != nil { - return nil, err - } - - typ, ok := extTypes[int8(extId)] - if !ok { - return nil, fmt.Errorf("msgpack: unregistered ext id=%d", int8(extId)) - } - - v := reflect.New(typ) - - d.extLen = extLen - err = d.DecodeValue(v.Elem()) - d.extLen = 0 - if err != nil { - return nil, err - } - - return v.Interface(), nil -} - -func (d *Decoder) skipExt(c codes.Code) error { - n, err := d.parseExtLen(c) - if err != nil { - return err - } - return d.skipN(n + 1) -} - -func (d *Decoder) skipExtHeader(c codes.Code) error { - // Read ext type. - _, err := d.readCode() - if err != nil { - return err - } - // Read ext body len. - for i := 0; i < extHeaderLen(c); i++ { - _, err := d.readCode() - if err != nil { - return err - } - } - return nil -} - -func extHeaderLen(c codes.Code) int { - switch c { - case codes.Ext8: - return 1 - case codes.Ext16: - return 2 - case codes.Ext32: - return 4 - } - return 0 -} diff --git a/vendor/github.com/vmihailenco/msgpack/ext_test.go b/vendor/github.com/vmihailenco/msgpack/ext_test.go deleted file mode 100644 index e0d67c0..0000000 --- a/vendor/github.com/vmihailenco/msgpack/ext_test.go +++ /dev/null @@ -1,116 +0,0 @@ -package msgpack_test - -import ( - "reflect" - "testing" - - "github.com/vmihailenco/msgpack" - "github.com/vmihailenco/msgpack/codes" -) - -func init() { - msgpack.RegisterExt(9, (*ExtTest)(nil)) -} - -func TestRegisterExtPanic(t *testing.T) { - defer func() { - r := recover() - if r == nil { - t.Fatalf("panic expected") - } - got := r.(error).Error() - wanted := "msgpack: ext with id=9 is already registered" - if got != wanted { - t.Fatalf("got %q, wanted %q", got, wanted) - } - }() - msgpack.RegisterExt(9, (*ExtTest)(nil)) -} - -type ExtTest struct { - S string -} - -var _ msgpack.CustomEncoder = (*ExtTest)(nil) -var _ msgpack.CustomDecoder = (*ExtTest)(nil) - -func (ext ExtTest) EncodeMsgpack(e *msgpack.Encoder) error { - return e.EncodeString("hello " + ext.S) -} - -func (ext *ExtTest) DecodeMsgpack(d *msgpack.Decoder) error { - var err error - ext.S, err = d.DecodeString() - return err -} - -func TestExt(t *testing.T) { - for _, v := range []interface{}{ExtTest{"world"}, &ExtTest{"world"}} { - b, err := msgpack.Marshal(v) - if err != nil { - t.Fatal(err) - } - - var dst interface{} - err = msgpack.Unmarshal(b, &dst) - if err != nil { - t.Fatal(err) - } - - v, ok := dst.(*ExtTest) - if !ok { - t.Fatalf("got %#v, wanted ExtTest", dst) - } - - wanted := "hello world" - if v.S != wanted { - t.Fatalf("got %q, wanted %q", v.S, wanted) - } - - ext := new(ExtTest) - err = msgpack.Unmarshal(b, ext) - if err != nil { - t.Fatal(err) - } - if ext.S != wanted { - t.Fatalf("got %q, wanted %q", ext.S, wanted) - } - } -} - -func TestUnknownExt(t *testing.T) { - b := []byte{byte(codes.FixExt1), 1, 0} - - var dst interface{} - err := msgpack.Unmarshal(b, &dst) - if err == nil { - t.Fatalf("got nil, wanted error") - } - got := err.Error() - wanted := "msgpack: unregistered ext id=1" - if got != wanted { - t.Fatalf("got %q, wanted %q", got, wanted) - } -} - -func TestDecodeExtWithMap(t *testing.T) { - type S struct { - I int - } - msgpack.RegisterExt(2, S{}) - - b, err := msgpack.Marshal(&S{I: 42}) - if err != nil { - t.Fatal(err) - } - - var got map[string]interface{} - if err := msgpack.Unmarshal(b, &got); err != nil { - t.Fatal(err) - } - - wanted := map[string]interface{}{"I": int8(42)} - if !reflect.DeepEqual(got, wanted) { - t.Fatalf("got %#v, but wanted %#v", got, wanted) - } -} diff --git a/vendor/github.com/vmihailenco/msgpack/msgpack.go b/vendor/github.com/vmihailenco/msgpack/msgpack.go deleted file mode 100644 index 220b43c..0000000 --- a/vendor/github.com/vmihailenco/msgpack/msgpack.go +++ /dev/null @@ -1,17 +0,0 @@ -package msgpack - -type Marshaler interface { - MarshalMsgpack() ([]byte, error) -} - -type Unmarshaler interface { - UnmarshalMsgpack([]byte) error -} - -type CustomEncoder interface { - EncodeMsgpack(*Encoder) error -} - -type CustomDecoder interface { - DecodeMsgpack(*Decoder) error -} diff --git a/vendor/github.com/vmihailenco/msgpack/msgpack_test.go b/vendor/github.com/vmihailenco/msgpack/msgpack_test.go deleted file mode 100644 index ebde887..0000000 --- a/vendor/github.com/vmihailenco/msgpack/msgpack_test.go +++ /dev/null @@ -1,274 +0,0 @@ -package msgpack_test - -import ( - "bufio" - "bytes" - "reflect" - "testing" - "time" - - . "gopkg.in/check.v1" - - "github.com/vmihailenco/msgpack" -) - -type nameStruct struct { - Name string -} - -func TestGocheck(t *testing.T) { TestingT(t) } - -type MsgpackTest struct { - buf *bytes.Buffer - enc *msgpack.Encoder - dec *msgpack.Decoder -} - -var _ = Suite(&MsgpackTest{}) - -func (t *MsgpackTest) SetUpTest(c *C) { - t.buf = &bytes.Buffer{} - t.enc = msgpack.NewEncoder(t.buf) - t.dec = msgpack.NewDecoder(bufio.NewReader(t.buf)) -} - -func (t *MsgpackTest) TestDecodeNil(c *C) { - c.Assert(t.dec.Decode(nil), NotNil) -} - -func (t *MsgpackTest) TestTime(c *C) { - in := time.Now() - var out time.Time - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out.Equal(in), Equals, true) - - var zero time.Time - c.Assert(t.enc.Encode(zero), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out.Equal(zero), Equals, true) - c.Assert(out.IsZero(), Equals, true) -} - -func (t *MsgpackTest) TestLargeBytes(c *C) { - N := int(1e6) - - src := bytes.Repeat([]byte{'1'}, N) - c.Assert(t.enc.Encode(src), IsNil) - var dst []byte - c.Assert(t.dec.Decode(&dst), IsNil) - c.Assert(dst, DeepEquals, src) -} - -func (t *MsgpackTest) TestLargeString(c *C) { - N := int(1e6) - - src := string(bytes.Repeat([]byte{'1'}, N)) - c.Assert(t.enc.Encode(src), IsNil) - var dst string - c.Assert(t.dec.Decode(&dst), IsNil) - c.Assert(dst, Equals, src) -} - -func (t *MsgpackTest) TestSliceOfStructs(c *C) { - in := []*nameStruct{&nameStruct{"hello"}} - var out []*nameStruct - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out, DeepEquals, in) -} - -func (t *MsgpackTest) TestMap(c *C) { - for _, i := range []struct { - m map[string]string - b []byte - }{ - {map[string]string{}, []byte{0x80}}, - {map[string]string{"hello": "world"}, []byte{0x81, 0xa5, 0x68, 0x65, 0x6c, 0x6c, 0x6f, 0xa5, 0x77, 0x6f, 0x72, 0x6c, 0x64}}, - } { - c.Assert(t.enc.Encode(i.m), IsNil) - c.Assert(t.buf.Bytes(), DeepEquals, i.b, Commentf("err encoding %v", i.m)) - var m map[string]string - c.Assert(t.dec.Decode(&m), IsNil) - c.Assert(m, DeepEquals, i.m) - } -} - -func (t *MsgpackTest) TestStructNil(c *C) { - var dst *nameStruct - - c.Assert(t.enc.Encode(nameStruct{Name: "foo"}), IsNil) - c.Assert(t.dec.Decode(&dst), IsNil) - c.Assert(dst, Not(IsNil)) - c.Assert(dst.Name, Equals, "foo") -} - -func (t *MsgpackTest) TestStructUnknownField(c *C) { - in := struct { - Field1 string - Field2 string - Field3 string - }{ - Field1: "value1", - Field2: "value2", - Field3: "value3", - } - c.Assert(t.enc.Encode(in), IsNil) - - out := struct { - Field2 string - }{} - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out.Field2, Equals, "value2") -} - -//------------------------------------------------------------------------------ - -type coderStruct struct { - name string -} - -type wrapperStruct struct { - coderStruct -} - -var ( - _ msgpack.CustomEncoder = (*coderStruct)(nil) - _ msgpack.CustomDecoder = (*coderStruct)(nil) -) - -func (s *coderStruct) Name() string { - return s.name -} - -func (s *coderStruct) EncodeMsgpack(enc *msgpack.Encoder) error { - return enc.Encode(s.name) -} - -func (s *coderStruct) DecodeMsgpack(dec *msgpack.Decoder) error { - return dec.Decode(&s.name) -} - -func (t *MsgpackTest) TestCoder(c *C) { - in := &coderStruct{name: "hello"} - var out coderStruct - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out.Name(), Equals, "hello") -} - -func (t *MsgpackTest) TestNilCoder(c *C) { - in := &coderStruct{name: "hello"} - var out *coderStruct - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out.Name(), Equals, "hello") -} - -func (t *MsgpackTest) TestNilCoderValue(c *C) { - in := &coderStruct{name: "hello"} - var out *coderStruct - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.DecodeValue(reflect.ValueOf(&out)), IsNil) - c.Assert(out.Name(), Equals, "hello") -} - -func (t *MsgpackTest) TestPtrToCoder(c *C) { - in := &coderStruct{name: "hello"} - var out coderStruct - out2 := &out - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out2), IsNil) - c.Assert(out.Name(), Equals, "hello") -} - -func (t *MsgpackTest) TestWrappedCoder(c *C) { - in := &wrapperStruct{coderStruct: coderStruct{name: "hello"}} - var out wrapperStruct - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out.Name(), Equals, "hello") -} - -//------------------------------------------------------------------------------ - -type struct2 struct { - Name string -} - -type struct1 struct { - Name string - Struct2 struct2 -} - -func (t *MsgpackTest) TestNestedStructs(c *C) { - in := &struct1{Name: "hello", Struct2: struct2{Name: "world"}} - var out struct1 - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out.Name, Equals, in.Name) - c.Assert(out.Struct2.Name, Equals, in.Struct2.Name) -} - -type Struct4 struct { - Name2 string -} - -type Struct3 struct { - Struct4 - Name1 string -} - -func TestEmbedding(t *testing.T) { - in := &Struct3{ - Name1: "hello", - Struct4: Struct4{ - Name2: "world", - }, - } - var out Struct3 - - b, err := msgpack.Marshal(in) - if err != nil { - t.Fatal(err) - } - - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if out.Name1 != in.Name1 { - t.Fatalf("") - } - if out.Name2 != in.Name2 { - t.Fatalf("") - } -} - -func (t *MsgpackTest) TestSliceNil(c *C) { - in := [][]*int{nil} - var out [][]*int - - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - c.Assert(out, DeepEquals, in) -} - -//------------------------------------------------------------------------------ - -func (t *MsgpackTest) TestMapStringInterface(c *C) { - in := map[string]interface{}{ - "foo": "bar", - "hello": map[string]interface{}{ - "foo": "bar", - }, - } - var out map[string]interface{} - - c.Assert(t.enc.Encode(in), IsNil) - c.Assert(t.dec.Decode(&out), IsNil) - - c.Assert(out["foo"], Equals, "bar") - mm := out["hello"].(map[string]interface{}) - c.Assert(mm["foo"], Equals, "bar") -} diff --git a/vendor/github.com/vmihailenco/msgpack/tag.go b/vendor/github.com/vmihailenco/msgpack/tag.go deleted file mode 100644 index 48e6f94..0000000 --- a/vendor/github.com/vmihailenco/msgpack/tag.go +++ /dev/null @@ -1,42 +0,0 @@ -package msgpack - -import ( - "strings" -) - -type tagOptions string - -func (o tagOptions) Get(name string) (string, bool) { - s := string(o) - for len(s) > 0 { - var next string - idx := strings.IndexByte(s, ',') - if idx >= 0 { - s, next = s[:idx], s[idx+1:] - } - if strings.HasPrefix(s, name) { - return s[len(name):], true - } - s = next - } - return "", false -} - -func (o tagOptions) Contains(name string) bool { - _, ok := o.Get(name) - return ok -} - -func parseTag(tag string) (string, tagOptions) { - if idx := strings.IndexByte(tag, ','); idx != -1 { - name := tag[:idx] - if strings.IndexByte(name, ':') == -1 { - return name, tagOptions(tag[idx+1:]) - } - } - - if strings.IndexByte(tag, ':') == -1 { - return tag, "" - } - return "", tagOptions(tag) -} diff --git a/vendor/github.com/vmihailenco/msgpack/time.go b/vendor/github.com/vmihailenco/msgpack/time.go deleted file mode 100644 index e51a31f..0000000 --- a/vendor/github.com/vmihailenco/msgpack/time.go +++ /dev/null @@ -1,135 +0,0 @@ -package msgpack - -import ( - "encoding/binary" - "fmt" - "reflect" - "time" - - "github.com/vmihailenco/msgpack/codes" -) - -var timeExtId int8 = -1 - -func init() { - timeType := reflect.TypeOf((*time.Time)(nil)).Elem() - registerExt(timeExtId, timeType, encodeTimeValue, decodeTimeValue) -} - -func (e *Encoder) EncodeTime(tm time.Time) error { - b := e.encodeTime(tm) - if err := e.encodeExtLen(len(b)); err != nil { - return err - } - if err := e.w.WriteByte(byte(timeExtId)); err != nil { - return err - } - return e.write(b) -} - -func (e *Encoder) encodeTime(tm time.Time) []byte { - secs := uint64(tm.Unix()) - if secs>>34 == 0 { - data := uint64(tm.Nanosecond())<<34 | secs - if data&0xffffffff00000000 == 0 { - b := make([]byte, 4) - binary.BigEndian.PutUint32(b, uint32(data)) - return b - } else { - b := make([]byte, 8) - binary.BigEndian.PutUint64(b, data) - return b - } - } - - b := make([]byte, 12) - binary.BigEndian.PutUint32(b, uint32(tm.Nanosecond())) - binary.BigEndian.PutUint64(b[4:], uint64(secs)) - return b -} - -func (d *Decoder) DecodeTime() (time.Time, error) { - tm, err := d.decodeTime() - if err != nil { - return tm, err - } - - if tm.IsZero() { - // Assume that zero time does not have timezone information. - return tm.UTC(), nil - } - return tm, nil -} - -func (d *Decoder) decodeTime() (time.Time, error) { - extLen := d.extLen - d.extLen = 0 - if extLen == 0 { - c, err := d.readCode() - if err != nil { - return time.Time{}, err - } - - // Legacy format. - if c == codes.FixedArrayLow|2 { - sec, err := d.DecodeInt64() - if err != nil { - return time.Time{}, err - } - nsec, err := d.DecodeInt64() - if err != nil { - return time.Time{}, err - } - return time.Unix(sec, nsec), nil - } - - extLen, err = d.parseExtLen(c) - if err != nil { - return time.Time{}, err - } - - // Skip ext id. - _, err = d.s.ReadByte() - if err != nil { - return time.Time{}, nil - } - } - - b, err := d.readN(extLen) - if err != nil { - return time.Time{}, err - } - - switch len(b) { - case 4: - sec := binary.BigEndian.Uint32(b) - return time.Unix(int64(sec), 0), nil - case 8: - sec := binary.BigEndian.Uint64(b) - nsec := int64(sec >> 34) - sec &= 0x00000003ffffffff - return time.Unix(int64(sec), nsec), nil - case 12: - nsec := binary.BigEndian.Uint32(b) - sec := binary.BigEndian.Uint64(b[4:]) - return time.Unix(int64(sec), int64(nsec)), nil - default: - err = fmt.Errorf("msgpack: invalid ext len=%d decoding time", extLen) - return time.Time{}, err - } -} - -func encodeTimeValue(e *Encoder, v reflect.Value) error { - tm := v.Interface().(time.Time) - b := e.encodeTime(tm) - return e.write(b) -} - -func decodeTimeValue(d *Decoder, v reflect.Value) error { - tm, err := d.DecodeTime() - if err != nil { - return err - } - v.Set(reflect.ValueOf(tm)) - return nil -} diff --git a/vendor/github.com/vmihailenco/msgpack/types.go b/vendor/github.com/vmihailenco/msgpack/types.go deleted file mode 100644 index 3ceaa4f..0000000 --- a/vendor/github.com/vmihailenco/msgpack/types.go +++ /dev/null @@ -1,280 +0,0 @@ -package msgpack - -import ( - "reflect" - "sync" -) - -var errorType = reflect.TypeOf((*error)(nil)).Elem() - -var customEncoderType = reflect.TypeOf((*CustomEncoder)(nil)).Elem() -var customDecoderType = reflect.TypeOf((*CustomDecoder)(nil)).Elem() - -var marshalerType = reflect.TypeOf((*Marshaler)(nil)).Elem() -var unmarshalerType = reflect.TypeOf((*Unmarshaler)(nil)).Elem() - -type encoderFunc func(*Encoder, reflect.Value) error -type decoderFunc func(*Decoder, reflect.Value) error - -var typEncMap = make(map[reflect.Type]encoderFunc) -var typDecMap = make(map[reflect.Type]decoderFunc) - -// Register registers encoder and decoder functions for a value. -// This is low level API and in most cases you should prefer implementing -// Marshaler/CustomEncoder and Unmarshaler/CustomDecoder interfaces. -func Register(value interface{}, enc encoderFunc, dec decoderFunc) { - typ := reflect.TypeOf(value) - if enc != nil { - typEncMap[typ] = enc - } - if dec != nil { - typDecMap[typ] = dec - } -} - -//------------------------------------------------------------------------------ - -var structs = newStructCache() - -type structCache struct { - mu sync.RWMutex - m map[reflect.Type]*fields -} - -func newStructCache() *structCache { - return &structCache{ - m: make(map[reflect.Type]*fields), - } -} - -func (m *structCache) Fields(typ reflect.Type) *fields { - m.mu.RLock() - fs, ok := m.m[typ] - m.mu.RUnlock() - if ok { - return fs - } - - m.mu.Lock() - fs, ok = m.m[typ] - if !ok { - fs = getFields(typ) - m.m[typ] = fs - } - m.mu.Unlock() - - return fs -} - -//------------------------------------------------------------------------------ - -type field struct { - name string - index []int - omitEmpty bool - - encoder encoderFunc - decoder decoderFunc -} - -func (f *field) value(v reflect.Value) reflect.Value { - return fieldByIndex(v, f.index) -} - -func (f *field) Omit(strct reflect.Value) bool { - return f.omitEmpty && isEmptyValue(f.value(strct)) -} - -func (f *field) EncodeValue(e *Encoder, strct reflect.Value) error { - return f.encoder(e, f.value(strct)) -} - -func (f *field) DecodeValue(d *Decoder, strct reflect.Value) error { - return f.decoder(d, f.value(strct)) -} - -//------------------------------------------------------------------------------ - -type fields struct { - List []*field - Table map[string]*field - - asArray bool - omitEmpty bool -} - -func newFields(numField int) *fields { - return &fields{ - List: make([]*field, 0, numField), - Table: make(map[string]*field, numField), - } -} - -func (fs *fields) Len() int { - return len(fs.List) -} - -func (fs *fields) Add(field *field) { - fs.List = append(fs.List, field) - fs.Table[field.name] = field - if field.omitEmpty { - fs.omitEmpty = field.omitEmpty - } -} - -func (fs *fields) OmitEmpty(strct reflect.Value) []*field { - if !fs.omitEmpty { - return fs.List - } - - fields := make([]*field, 0, fs.Len()) - for _, f := range fs.List { - if !f.Omit(strct) { - fields = append(fields, f) - } - } - return fields -} - -func getFields(typ reflect.Type) *fields { - numField := typ.NumField() - fs := newFields(numField) - - var omitEmpty bool - for i := 0; i < numField; i++ { - f := typ.Field(i) - - name, opt := parseTag(f.Tag.Get("msgpack")) - if name == "-" { - continue - } - - if f.Name == "_msgpack" { - if opt.Contains("asArray") { - fs.asArray = true - } - if opt.Contains("omitempty") { - omitEmpty = true - } - } - - if f.PkgPath != "" && !f.Anonymous { - continue - } - - if name == "" { - name = f.Name - } - field := &field{ - name: name, - index: f.Index, - omitEmpty: omitEmpty || opt.Contains("omitempty"), - encoder: getEncoder(f.Type), - decoder: getDecoder(f.Type), - } - - if f.Anonymous && inlineFields(fs, f.Type, field) { - continue - } - - fs.Add(field) - } - return fs -} - -var encodeStructValuePtr uintptr -var decodeStructValuePtr uintptr - -func init() { - encodeStructValuePtr = reflect.ValueOf(encodeStructValue).Pointer() - decodeStructValuePtr = reflect.ValueOf(decodeStructValue).Pointer() -} - -func inlineFields(fs *fields, typ reflect.Type, f *field) bool { - var encoder encoderFunc - var decoder decoderFunc - - if typ.Kind() == reflect.Struct { - encoder = f.encoder - decoder = f.decoder - } else { - for typ.Kind() == reflect.Ptr { - typ = typ.Elem() - encoder = getEncoder(typ) - decoder = getDecoder(typ) - } - if typ.Kind() != reflect.Struct { - return false - } - } - - if reflect.ValueOf(encoder).Pointer() != encodeStructValuePtr { - return false - } - if reflect.ValueOf(decoder).Pointer() != decodeStructValuePtr { - return false - } - - inlinedFields := getFields(typ).List - for _, field := range inlinedFields { - if _, ok := fs.Table[field.name]; ok { - // Don't overwrite shadowed fields. - continue - } - field.index = append(f.index, field.index...) - fs.Add(field) - } - return true -} - -func isEmptyValue(v reflect.Value) bool { - switch v.Kind() { - case reflect.Array, reflect.Map, reflect.Slice, reflect.String: - return v.Len() == 0 - case reflect.Bool: - return !v.Bool() - case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: - return v.Int() == 0 - case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr: - return v.Uint() == 0 - case reflect.Float32, reflect.Float64: - return v.Float() == 0 - case reflect.Interface, reflect.Ptr: - return v.IsNil() - } - return false -} - -func fieldByIndex(v reflect.Value, index []int) reflect.Value { - if len(index) == 1 { - return v.Field(index[0]) - } - for i, x := range index { - if i > 0 { - var ok bool - v, ok = indirectNew(v) - if !ok { - return v - } - } - v = v.Field(x) - } - return v -} - -func indirectNew(v reflect.Value) (reflect.Value, bool) { - if v.Kind() == reflect.Ptr { - if v.IsNil() { - if !v.CanSet() { - return v, false - } - elemType := v.Type().Elem() - if elemType.Kind() != reflect.Struct { - return v, false - } - v.Set(reflect.New(elemType)) - } - v = v.Elem() - } - return v, true -} diff --git a/vendor/github.com/vmihailenco/msgpack/types_test.go b/vendor/github.com/vmihailenco/msgpack/types_test.go deleted file mode 100644 index de8f552..0000000 --- a/vendor/github.com/vmihailenco/msgpack/types_test.go +++ /dev/null @@ -1,924 +0,0 @@ -package msgpack_test - -import ( - "bytes" - "encoding/hex" - "fmt" - "math" - "net/url" - "reflect" - "strings" - "testing" - "time" - - "github.com/vmihailenco/msgpack" - "github.com/vmihailenco/msgpack/codes" -) - -//------------------------------------------------------------------------------ - -type Object struct { - n int -} - -func (o *Object) MarshalMsgpack() ([]byte, error) { - return msgpack.Marshal(o.n) -} - -func (o *Object) UnmarshalMsgpack(b []byte) error { - return msgpack.Unmarshal(b, &o.n) -} - -//------------------------------------------------------------------------------ - -type IntSet map[int]struct{} - -var _ msgpack.CustomEncoder = (*IntSet)(nil) -var _ msgpack.CustomDecoder = (*IntSet)(nil) - -func (set IntSet) EncodeMsgpack(enc *msgpack.Encoder) error { - slice := make([]int, 0, len(set)) - for n, _ := range set { - slice = append(slice, n) - } - return enc.Encode(slice) -} - -func (setptr *IntSet) DecodeMsgpack(dec *msgpack.Decoder) error { - n, err := dec.DecodeArrayLen() - if err != nil { - return err - } - - set := make(IntSet, n) - for i := 0; i < n; i++ { - n, err := dec.DecodeInt() - if err != nil { - return err - } - set[n] = struct{}{} - } - *setptr = set - - return nil -} - -//------------------------------------------------------------------------------ - -type CustomEncoder struct { - str string - ref *CustomEncoder - num int -} - -var _ msgpack.CustomEncoder = (*CustomEncoder)(nil) -var _ msgpack.CustomDecoder = (*CustomEncoder)(nil) - -func (s *CustomEncoder) EncodeMsgpack(enc *msgpack.Encoder) error { - if s == nil { - return enc.EncodeNil() - } - return enc.Encode(s.str, s.ref, s.num) -} - -func (s *CustomEncoder) DecodeMsgpack(dec *msgpack.Decoder) error { - return dec.Decode(&s.str, &s.ref, &s.num) -} - -type CustomEncoderField struct { - Field CustomEncoder -} - -//------------------------------------------------------------------------------ - -type OmitEmptyTest struct { - Foo string `msgpack:",omitempty"` - Bar string `msgpack:",omitempty"` -} - -type InlineTest struct { - OmitEmptyTest -} - -type InlinePtrTest struct { - *OmitEmptyTest -} - -type AsArrayTest struct { - _msgpack struct{} `msgpack:",asArray"` - - OmitEmptyTest -} - -//------------------------------------------------------------------------------ - -type encoderTest struct { - in interface{} - wanted string -} - -var encoderTests = []encoderTest{ - {nil, "c0"}, - - {[]byte(nil), "c0"}, - {[]byte{1, 2, 3}, "c403010203"}, - {[3]byte{1, 2, 3}, "c403010203"}, - - {time.Unix(0, 0), "d6ff00000000"}, - {time.Unix(1, 1), "d7ff0000000400000001"}, - {time.Time{}, "c70cff00000000fffffff1886e0900"}, - - {IntSet{}, "90"}, - {IntSet{8: struct{}{}}, "9108"}, - - {map[string]string(nil), "c0"}, - { - map[string]string{"a": "", "b": "", "c": "", "d": "", "e": ""}, - "85a161a0a162a0a163a0a164a0a165a0", - }, - - {(*Object)(nil), "c0"}, - {&Object{}, "00"}, - {&Object{42}, "2a"}, - {[]*Object{nil, nil}, "92c0c0"}, - - {&CustomEncoder{}, "a0c000"}, - { - &CustomEncoder{"a", &CustomEncoder{"b", nil, 7}, 6}, - "a161a162c00706", - }, - - {OmitEmptyTest{}, "80"}, - {&OmitEmptyTest{Foo: "hello"}, "81a3466f6fa568656c6c6f"}, - - {&InlineTest{OmitEmptyTest: OmitEmptyTest{Bar: "world"}}, "81a3426172a5776f726c64"}, - {&InlinePtrTest{OmitEmptyTest: &OmitEmptyTest{Bar: "world"}}, "81a3426172a5776f726c64"}, - - {&AsArrayTest{}, "92a0a0"}, -} - -func TestEncoder(t *testing.T) { - for _, test := range encoderTests { - var buf bytes.Buffer - enc := msgpack.NewEncoder(&buf).SortMapKeys(true) - if err := enc.Encode(test.in); err != nil { - t.Fatal(err) - } - - s := hex.EncodeToString(buf.Bytes()) - if s != test.wanted { - t.Fatalf("%s != %s (in=%#v)", s, test.wanted, test.in) - } - } -} - -//------------------------------------------------------------------------------ - -type decoderTest struct { - b []byte - out interface{} - err string -} - -var decoderTests = []decoderTest{ - {b: []byte{byte(codes.Bin32), 0x0f, 0xff, 0xff, 0xff}, out: new([]byte), err: "EOF"}, - {b: []byte{byte(codes.Str32), 0x0f, 0xff, 0xff, 0xff}, out: new([]byte), err: "EOF"}, - {b: []byte{byte(codes.Array32), 0x0f, 0xff, 0xff, 0xff}, out: new([]int), err: "EOF"}, - {b: []byte{byte(codes.Map32), 0x0f, 0xff, 0xff, 0xff}, out: new(map[int]int), err: "EOF"}, -} - -func TestDecoder(t *testing.T) { - for i, test := range decoderTests { - err := msgpack.Unmarshal(test.b, test.out) - if err == nil { - t.Fatalf("#%d err is nil, wanted %q", i, test.err) - } - if err.Error() != test.err { - t.Fatalf("#%d err is %q, wanted %q", i, err.Error(), test.err) - } - } -} - -//------------------------------------------------------------------------------ - -type unexported struct { - Foo string -} - -type Exported struct { - Bar string -} - -type EmbeddingTest struct { - unexported - Exported -} - -type EmbeddingPtrTest struct { - *Exported -} - -//------------------------------------------------------------------------------ - -type EmbeddedTime struct { - time.Time -} - -type ( - interfaceAlias interface{} - byteAlias byte - uint8Alias uint8 - stringAlias string - sliceByte []byte - sliceString []string - mapStringString map[string]string - mapStringInterface map[string]interface{} -) - -type StructTest struct { - F1 sliceString - F2 []string -} - -type typeTest struct { - *testing.T - - in interface{} - out interface{} - encErr string - decErr string - wantnil bool - wantzero bool - wanted interface{} -} - -func (t typeTest) String() string { - return fmt.Sprintf("in=%#v, out=%#v", t.in, t.out) -} - -func (t *typeTest) assertErr(err error, s string) { - if err == nil { - t.Fatalf("got %v error, wanted %q", err, s) - } - if err.Error() != s { - t.Fatalf("got %q error, wanted %q", err, s) - } -} - -var ( - intSlice = make([]int, 0, 3) - repoURL, _ = url.Parse("https://github.com/vmihailenco/msgpack") - typeTests = []typeTest{ - {in: make(chan bool), encErr: "msgpack: Encode(unsupported chan bool)"}, - - {in: nil, out: nil, decErr: "msgpack: Decode(nil)"}, - {in: nil, out: 0, decErr: "msgpack: Decode(nonsettable int)"}, - {in: nil, out: (*int)(nil), decErr: "msgpack: Decode(nonsettable *int)"}, - {in: nil, out: new(chan bool), decErr: "msgpack: Decode(unsupported chan bool)"}, - - {in: true, out: new(bool)}, - {in: false, out: new(bool)}, - - {in: nil, out: new(int), wanted: int(0)}, - {in: nil, out: new(*int), wantnil: true}, - - {in: float32(3.14), out: new(float32)}, - {in: int8(-1), out: new(float32), wanted: float32(-1)}, - {in: int32(1), out: new(float32), wanted: float32(1)}, - {in: int32(999999999), out: new(float32), wanted: float32(999999999)}, - {in: int64(math.MaxInt64), out: new(float32), wanted: float32(math.MaxInt64)}, - - {in: float64(3.14), out: new(float64)}, - {in: int8(-1), out: new(float64), wanted: float64(-1)}, - {in: int64(1), out: new(float64), wanted: float64(1)}, - {in: int64(999999999), out: new(float64), wanted: float64(999999999)}, - {in: int64(math.MaxInt64), out: new(float64), wanted: float64(math.MaxInt64)}, - - {in: nil, out: new(*string), wantnil: true}, - {in: nil, out: new(string), wanted: ""}, - {in: "", out: new(string)}, - {in: "foo", out: new(string)}, - - {in: nil, out: new([]byte), wantnil: true}, - {in: []byte(nil), out: new([]byte), wantnil: true}, - {in: []byte(nil), out: &[]byte{}, wantnil: true}, - {in: []byte{1, 2, 3}, out: new([]byte)}, - {in: []byte{1, 2, 3}, out: new([]byte)}, - {in: sliceByte{1, 2, 3}, out: new(sliceByte)}, - {in: []byteAlias{1, 2, 3}, out: new([]byteAlias)}, - {in: []uint8Alias{1, 2, 3}, out: new([]uint8Alias)}, - - {in: nil, out: new([3]byte), wanted: [3]byte{}}, - {in: [3]byte{1, 2, 3}, out: new([3]byte)}, - {in: [3]byte{1, 2, 3}, out: new([2]byte), decErr: "[2]uint8 len is 2, but msgpack has 3 elements"}, - - {in: nil, out: new([]interface{}), wantnil: true}, - {in: nil, out: new([]interface{}), wantnil: true}, - {in: []interface{}{int8(1), "hello"}, out: new([]interface{})}, - - {in: nil, out: new([]int), wantnil: true}, - {in: nil, out: &[]int{1, 2}, wantnil: true}, - {in: []int(nil), out: new([]int), wantnil: true}, - {in: make([]int, 0), out: new([]int)}, - {in: []int{}, out: new([]int)}, - {in: []int{1, 2, 3}, out: new([]int)}, - {in: []int{1, 2, 3}, out: &intSlice}, - {in: [3]int{1, 2, 3}, out: new([3]int)}, - {in: [3]int{1, 2, 3}, out: new([2]int), decErr: "[2]int len is 2, but msgpack has 3 elements"}, - - {in: []string(nil), out: new([]string), wantnil: true}, - {in: []string{}, out: new([]string)}, - {in: []string{"a", "b"}, out: new([]string)}, - {in: [2]string{"a", "b"}, out: new([2]string)}, - {in: sliceString{"foo", "bar"}, out: new(sliceString)}, - {in: []stringAlias{"hello"}, out: new([]stringAlias)}, - - {in: nil, out: new(map[string]string), wantnil: true}, - {in: nil, out: new(map[int]int), wantnil: true}, - {in: nil, out: &map[string]string{"foo": "bar"}, wantnil: true}, - {in: nil, out: &map[int]int{1: 2}, wantnil: true}, - {in: map[string]string(nil), out: new(map[string]string)}, - {in: map[string]interface{}{"foo": nil}, out: new(map[string]interface{})}, - {in: mapStringString{"foo": "bar"}, out: new(mapStringString)}, - {in: map[stringAlias]stringAlias{"foo": "bar"}, out: new(map[stringAlias]stringAlias)}, - {in: mapStringInterface{"foo": "bar"}, out: new(mapStringInterface)}, - {in: map[stringAlias]interfaceAlias{"foo": "bar"}, out: new(map[stringAlias]interfaceAlias)}, - - {in: (*Object)(nil), out: new(*Object)}, - {in: &Object{42}, out: new(Object)}, - {in: []*Object{new(Object), new(Object)}, out: new([]*Object)}, - - {in: IntSet{}, out: new(IntSet)}, - {in: IntSet{42: struct{}{}}, out: new(IntSet)}, - {in: IntSet{42: struct{}{}}, out: new(*IntSet)}, - - {in: StructTest{sliceString{"foo", "bar"}, []string{"hello"}}, out: new(StructTest)}, - {in: StructTest{sliceString{"foo", "bar"}, []string{"hello"}}, out: new(*StructTest)}, - - {in: EmbeddingTest{}, out: new(EmbeddingTest)}, - { - in: EmbeddingTest{}, - out: new(EmbeddingPtrTest), - wanted: EmbeddingPtrTest{Exported: new(Exported)}, - }, - {in: EmbeddingTest{}, out: new(*EmbeddingTest)}, - { - in: EmbeddingTest{ - unexported: unexported{Foo: "hello"}, - Exported: Exported{Bar: "world"}, - }, - out: new(EmbeddingTest), - }, - - {in: time.Unix(0, 0), out: new(time.Time)}, - {in: time.Unix(0, 1), out: new(time.Time)}, - {in: time.Unix(1, 0), out: new(time.Time)}, - {in: time.Unix(1, 1), out: new(time.Time)}, - {in: EmbeddedTime{Time: time.Unix(1, 1)}, out: new(EmbeddedTime)}, - {in: EmbeddedTime{Time: time.Unix(1, 1)}, out: new(*EmbeddedTime)}, - - {in: nil, out: new(*CustomEncoder), wantnil: true}, - {in: nil, out: &CustomEncoder{str: "a"}, wantzero: true}, - { - in: &CustomEncoder{"a", &CustomEncoder{"b", nil, 1}, 2}, - out: new(CustomEncoder), - }, - { - in: &CustomEncoderField{Field: CustomEncoder{"a", nil, 1}}, - out: new(CustomEncoderField), - }, - - {in: repoURL, out: new(url.URL)}, - {in: repoURL, out: new(*url.URL)}, - - {in: nil, out: new(*AsArrayTest), wantnil: true}, - {in: nil, out: new(AsArrayTest), wantzero: true}, - {in: AsArrayTest{OmitEmptyTest: OmitEmptyTest{"foo", "bar"}}, out: new(AsArrayTest)}, - { - in: AsArrayTest{OmitEmptyTest: OmitEmptyTest{"foo", "bar"}}, - out: new(unexported), - wanted: unexported{Foo: "foo"}, - }, - - {in: (*EventTime)(nil), out: new(*EventTime)}, - {in: &EventTime{time.Unix(0, 0)}, out: new(EventTime)}, - - {in: (*ExtTest)(nil), out: new(*ExtTest)}, - {in: &ExtTest{"world"}, out: new(ExtTest), wanted: ExtTest{"hello world"}}, - } -) - -func indirect(viface interface{}) interface{} { - v := reflect.ValueOf(viface) - for v.Kind() == reflect.Ptr { - v = v.Elem() - } - if v.IsValid() { - return v.Interface() - } - return nil -} - -func TestTypes(t *testing.T) { - for _, test := range typeTests { - test.T = t - - var buf bytes.Buffer - - enc := msgpack.NewEncoder(&buf) - err := enc.Encode(test.in) - if test.encErr != "" { - test.assertErr(err, test.encErr) - continue - } - if err != nil { - t.Fatalf("Encode failed: %s (in=%#v)", err, test.in) - } - - dec := msgpack.NewDecoder(&buf) - err = dec.Decode(test.out) - if test.decErr != "" { - test.assertErr(err, test.decErr) - continue - } - if err != nil { - t.Fatalf("Decode failed: %s (%s)", err, test) - } - - if buf.Len() > 0 { - t.Fatalf("unread data in the buffer: %q (%s)", buf.Bytes(), test) - } - - if test.wantnil { - v := reflect.Indirect(reflect.ValueOf(test.out)) - if !v.IsNil() { - t.Fatalf("got %#v, wanted nil (%s)", test.out, test) - } - continue - } - - out := indirect(test.out) - var wanted interface{} - if test.wantzero { - typ := reflect.TypeOf(out) - wanted = reflect.Zero(typ).Interface() - } else { - wanted = test.wanted - } - if wanted == nil { - wanted = indirect(test.in) - } - if !reflect.DeepEqual(out, wanted) { - t.Fatalf("%#v != %#v (%s)", out, wanted, test) - } - } - - for _, test := range typeTests { - if test.encErr != "" || test.decErr != "" { - continue - } - - b, err := msgpack.Marshal(test.in) - if err != nil { - t.Fatal(err) - } - - var dst interface{} - err = msgpack.Unmarshal(b, &dst) - if err != nil { - t.Fatalf("Decode failed: %s (%s)", err, test) - } - - dec := msgpack.NewDecoder(bytes.NewReader(b)) - _, err = dec.DecodeInterface() - if err != nil { - t.Fatalf("Decode failed: %s (%s)", err, test) - } - } -} - -func TestStringsBin(t *testing.T) { - tests := []struct { - in string - wanted string - }{ - {"", "a0"}, - {"a", "a161"}, - {"hello", "a568656c6c6f"}, - { - strings.Repeat("x", 31), - "bf" + strings.Repeat("78", 31), - }, - { - strings.Repeat("x", 32), - "d920" + strings.Repeat("78", 32), - }, - { - strings.Repeat("x", 255), - "d9ff" + strings.Repeat("78", 255), - }, - { - strings.Repeat("x", 256), - "da0100" + strings.Repeat("78", 256), - }, - { - strings.Repeat("x", 65535), - "daffff" + strings.Repeat("78", 65535), - }, - { - strings.Repeat("x", 65536), - "db00010000" + strings.Repeat("78", 65536), - }, - } - - for _, test := range tests { - b, err := msgpack.Marshal(test.in) - if err != nil { - t.Fatal(err) - } - s := hex.EncodeToString(b) - if s != test.wanted { - t.Fatalf("%.32s != %.32s", s, test.wanted) - } - - var out string - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if out != test.in { - t.Fatalf("%s != %s", out, test.in) - } - - dec := msgpack.NewDecoder(bytes.NewReader(b)) - v, err := dec.DecodeInterface() - if err != nil { - t.Fatal(err) - } - if v.(string) != test.in { - t.Fatalf("%s != %s", v, test.in) - } - - var dst interface{} - dst = "" - err = msgpack.Unmarshal(b, &dst) - if err.Error() != "msgpack: Decode(nonsettable string)" { - t.Fatal(err) - } - } -} - -func TestBin(t *testing.T) { - tests := []struct { - in []byte - wanted string - }{ - {[]byte{}, "c400"}, - {[]byte{0}, "c40100"}, - { - bytes.Repeat([]byte{'x'}, 31), - "c41f" + strings.Repeat("78", 31), - }, - { - bytes.Repeat([]byte{'x'}, 32), - "c420" + strings.Repeat("78", 32), - }, - { - bytes.Repeat([]byte{'x'}, 255), - "c4ff" + strings.Repeat("78", 255), - }, - { - bytes.Repeat([]byte{'x'}, 256), - "c50100" + strings.Repeat("78", 256), - }, - { - bytes.Repeat([]byte{'x'}, 65535), - "c5ffff" + strings.Repeat("78", 65535), - }, - { - bytes.Repeat([]byte{'x'}, 65536), - "c600010000" + strings.Repeat("78", 65536), - }, - } - - for _, test := range tests { - b, err := msgpack.Marshal(test.in) - if err != nil { - t.Fatal(err) - } - s := hex.EncodeToString(b) - if s != test.wanted { - t.Fatalf("%.32s != %.32s", s, test.wanted) - } - - var out []byte - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if !bytes.Equal(out, test.in) { - t.Fatalf("%x != %x", out, test.in) - } - - dec := msgpack.NewDecoder(bytes.NewReader(b)) - v, err := dec.DecodeInterface() - if err != nil { - t.Fatal(err) - } - if !bytes.Equal(v.([]byte), test.in) { - t.Fatalf("%x != %x", v, test.in) - } - - var dst interface{} - dst = make([]byte, 0) - err = msgpack.Unmarshal(b, &dst) - if err.Error() != "msgpack: Decode(nonsettable []uint8)" { - t.Fatal(err) - } - } -} - -func TestUint64(t *testing.T) { - tests := []struct { - in uint64 - wanted string - }{ - {0, "00"}, - {1, "01"}, - {math.MaxInt8 - 1, "7e"}, - {math.MaxInt8, "7f"}, - {math.MaxInt8 + 1, "cc80"}, - {math.MaxUint8 - 1, "ccfe"}, - {math.MaxUint8, "ccff"}, - {math.MaxUint8 + 1, "cd0100"}, - {math.MaxUint16 - 1, "cdfffe"}, - {math.MaxUint16, "cdffff"}, - {math.MaxUint16 + 1, "ce00010000"}, - {math.MaxUint32 - 1, "cefffffffe"}, - {math.MaxUint32, "ceffffffff"}, - {math.MaxUint32 + 1, "cf0000000100000000"}, - {math.MaxInt64 - 1, "cf7ffffffffffffffe"}, - {math.MaxInt64, "cf7fffffffffffffff"}, - } - for _, test := range tests { - b, err := msgpack.Marshal(test.in) - if err != nil { - t.Fatal(err) - } - s := hex.EncodeToString(b) - if s != test.wanted { - t.Fatalf("%.32s != %.32s", s, test.wanted) - } - - var out uint64 - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if out != test.in { - t.Fatalf("%d != %d", out, test.in) - } - - var out2 int64 - err = msgpack.Unmarshal(b, &out2) - if err != nil { - t.Fatal(err) - } - if out2 != int64(test.in) { - t.Fatalf("%d != %d", out2, int64(test.in)) - } - - dec := msgpack.NewDecoder(bytes.NewReader(b)) - _, err = dec.DecodeInterface() - if err != nil { - t.Fatal(err) - } - - var dst interface{} - dst = uint64(0) - err = msgpack.Unmarshal(b, &dst) - if err.Error() != "msgpack: Decode(nonsettable uint64)" { - t.Fatal(err) - } - } -} - -func TestInt64(t *testing.T) { - tests := []struct { - in int64 - wanted string - }{ - {math.MinInt64, "d38000000000000000"}, - {math.MinInt32 - 1, "d3ffffffff7fffffff"}, - {math.MinInt32, "d280000000"}, - {math.MinInt32 + 1, "d280000001"}, - {math.MinInt16 - 1, "d2ffff7fff"}, - {math.MinInt16, "d18000"}, - {math.MinInt16 + 1, "d18001"}, - {math.MinInt8 - 1, "d1ff7f"}, - {math.MinInt8, "d080"}, - {math.MinInt8 + 1, "d081"}, - {-33, "d0df"}, - {-32, "e0"}, - {-31, "e1"}, - {-1, "ff"}, - {0, "00"}, - {1, "01"}, - {math.MaxInt8 - 1, "7e"}, - {math.MaxInt8, "7f"}, - {math.MaxInt8 + 1, "cc80"}, - {math.MaxUint8 - 1, "ccfe"}, - {math.MaxUint8, "ccff"}, - {math.MaxUint8 + 1, "cd0100"}, - {math.MaxUint16 - 1, "cdfffe"}, - {math.MaxUint16, "cdffff"}, - {math.MaxUint16 + 1, "ce00010000"}, - {math.MaxUint32 - 1, "cefffffffe"}, - {math.MaxUint32, "ceffffffff"}, - {math.MaxUint32 + 1, "cf0000000100000000"}, - {math.MaxInt64 - 1, "cf7ffffffffffffffe"}, - {math.MaxInt64, "cf7fffffffffffffff"}, - } - for _, test := range tests { - b, err := msgpack.Marshal(test.in) - if err != nil { - t.Fatal(err) - } - s := hex.EncodeToString(b) - if s != test.wanted { - t.Fatalf("%.32s != %.32s", s, test.wanted) - } - - var out int64 - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if out != test.in { - t.Fatalf("%d != %d", out, test.in) - } - - var out2 uint64 - err = msgpack.Unmarshal(b, &out2) - if err != nil { - t.Fatal(err) - } - if out2 != uint64(test.in) { - t.Fatalf("%d != %d", out2, uint64(test.in)) - } - - dec := msgpack.NewDecoder(bytes.NewReader(b)) - _, err = dec.DecodeInterface() - if err != nil { - t.Fatal(err) - } - - var dst interface{} - dst = int64(0) - err = msgpack.Unmarshal(b, &dst) - if err.Error() != "msgpack: Decode(nonsettable int64)" { - t.Fatal(err) - } - } -} - -func TestFloat32(t *testing.T) { - tests := []struct { - in float32 - wanted string - }{ - {0.1, "ca3dcccccd"}, - {0.2, "ca3e4ccccd"}, - {-0.1, "cabdcccccd"}, - {-0.2, "cabe4ccccd"}, - {float32(math.Inf(1)), "ca7f800000"}, - {float32(math.Inf(-1)), "caff800000"}, - {math.MaxFloat32, "ca7f7fffff"}, - {math.SmallestNonzeroFloat32, "ca00000001"}, - } - for _, test := range tests { - b, err := msgpack.Marshal(test.in) - if err != nil { - t.Fatal(err) - } - s := hex.EncodeToString(b) - if s != test.wanted { - t.Fatalf("%.32s != %.32s", s, test.wanted) - } - - var out float32 - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if out != test.in { - t.Fatalf("%f != %f", out, test.in) - } - - var out2 float64 - err = msgpack.Unmarshal(b, &out2) - if err != nil { - t.Fatal(err) - } - if out2 != float64(test.in) { - t.Fatalf("%f != %f", out2, float64(test.in)) - } - - dec := msgpack.NewDecoder(bytes.NewReader(b)) - v, err := dec.DecodeInterface() - if err != nil { - t.Fatal(err) - } - if v.(float32) != test.in { - t.Fatalf("%f != %f", v, test.in) - } - - var dst interface{} - dst = float32(0) - err = msgpack.Unmarshal(b, &dst) - if err.Error() != "msgpack: Decode(nonsettable float32)" { - t.Fatal(err) - } - } - - in := float32(math.NaN()) - b, err := msgpack.Marshal(in) - if err != nil { - t.Fatal(err) - } - - var out float32 - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if !math.IsNaN(float64(out)) { - t.Fatal("not NaN") - } -} - -func TestFloat64(t *testing.T) { - table := []struct { - in float64 - wanted string - }{ - {0.1, "cb3fb999999999999a"}, - {0.2, "cb3fc999999999999a"}, - {-0.1, "cbbfb999999999999a"}, - {-0.2, "cbbfc999999999999a"}, - {math.Inf(1), "cb7ff0000000000000"}, - {math.Inf(-1), "cbfff0000000000000"}, - {math.MaxFloat64, "cb7fefffffffffffff"}, - {math.SmallestNonzeroFloat64, "cb0000000000000001"}, - } - for _, test := range table { - b, err := msgpack.Marshal(test.in) - if err != nil { - t.Fatal(err) - } - s := hex.EncodeToString(b) - if s != test.wanted { - t.Fatalf("%.32s != %.32s", s, test.wanted) - } - - var out float64 - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if out != test.in { - t.Fatalf("%f != %f", out, test.in) - } - - dec := msgpack.NewDecoder(bytes.NewReader(b)) - v, err := dec.DecodeInterface() - if err != nil { - t.Fatal(err) - } - if v.(float64) != test.in { - t.Fatalf("%f != %f", v, test.in) - } - - var dst interface{} - dst = float64(0) - err = msgpack.Unmarshal(b, &dst) - if err.Error() != "msgpack: Decode(nonsettable float64)" { - t.Fatal(err) - } - } - - in := float64(math.NaN()) - b, err := msgpack.Marshal(in) - if err != nil { - t.Fatal(err) - } - - var out float64 - err = msgpack.Unmarshal(b, &out) - if err != nil { - t.Fatal(err) - } - if !math.IsNaN(out) { - t.Fatal("not NaN") - } -} diff --git a/vendor/github.com/x448/float16/.github/workflows/ci.yml b/vendor/github.com/x448/float16/.github/workflows/ci.yml new file mode 100644 index 0000000..22bcfd5 --- /dev/null +++ b/vendor/github.com/x448/float16/.github/workflows/ci.yml @@ -0,0 +1,23 @@ +# GitHub Actions - CI for Go with just builders and tests. Use cover.yml and linters.yml for coverage and linting. +name: ci +on: [push] +jobs: + + # Test on various OS with default Go version. Specifying Go version causes too much slowdown as of January 2020. + tests: + name: Test on ${{matrix.os}} + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [macos-latest, ubuntu-latest] + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Get dependencies + run: go get -v -t -d ./... + - name: Build project + run: go build ./... + - name: Run tests + run: | + go version + go test -short -race -v ./... diff --git a/vendor/github.com/x448/float16/.github/workflows/cover.yml b/vendor/github.com/x448/float16/.github/workflows/cover.yml new file mode 100644 index 0000000..969cd63 --- /dev/null +++ b/vendor/github.com/x448/float16/.github/workflows/cover.yml @@ -0,0 +1,32 @@ +# Copyright 2020-present Montgomery Edwards⁴⁴⁸ (github.com/x448). +# This file is licensed under MIT License. +# +# Go Cover - GitHub Actions Workflow +# This GitHub Actions workflow checks if Go code coverage satisfies the required minimum. +# The required minimum is specified in the workflow name. This keeps badge.svg and verified minimum in sync. +# +# To help protect your privacy, this workflow avoids external services. +# Using script visible here, this workflow simply runs `go test -short -cover` --> grep --> python. +# +# Steps to install and set minimum required coverage: +# 0. Copy this file to github.com/OWNER_NAME/REPO_NAME/.github/workflows/cover.yml +# 1. Change workflow name from "cover 100%" to "cover ≥92.5%". Script will automatically use 92.5%. +# 2. Change README.md to use the new path to badge.svg because the path includes the workflow name. + +name: cover 100% +on: [push] +jobs: + + # Verify minimum coverage is reached using `go test -short -cover` on latest-ubuntu with default version of Go. + # The grep expression can't be too strict, it needed to be relaxed to work with different versions of Go. + cover: + name: Coverage + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Go Coverage + run: | + go version + go test -short -cover | grep "^.*coverage:.*of statements$" | python -c "import os,re,sys; cover_rpt = sys.stdin.read(); print(cover_rpt) if len(cover_rpt) != 0 else sys.exit(1); min_cover = float(re.findall(r'\d*\.\d+|\d+', os.environ['GITHUB_WORKFLOW'])[0]); cover = float(re.findall(r'\d*\.\d+|\d+', cover_rpt)[0]); sys.exit(1) if (cover > 100) or (cover < min_cover) else sys.exit(0)" + shell: bash diff --git a/vendor/github.com/x448/float16/.github/workflows/linters.yml b/vendor/github.com/x448/float16/.github/workflows/linters.yml new file mode 100644 index 0000000..0d8c692 --- /dev/null +++ b/vendor/github.com/x448/float16/.github/workflows/linters.yml @@ -0,0 +1,24 @@ +# Go Linters - GitHub Actions +# This workflow runs golangci-lint with linters specified in .golangci.yml plus linters enabled here. +# To disable a linter, it must be removed from this file and also from .golangci.yml. +# Required linters must pass. Optional linters don't need to pass so they can be more aggressive. +name: linters +on: [push] +jobs: + + # Check linters on latest-ubuntu with default version of Go. + lint: + name: Lint + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + - name: Install golangci-lint + run: | + go version + curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin v1.23.1 + - name: Run required linters in .golangci.yml plus hard-coded ones here + run: $(go env GOPATH)/bin/golangci-lint run --timeout=5m -E deadcode -E errcheck -E goconst -E gocyclo -E gofmt -E golint -E gosec -E govet -E ineffassign -E maligned -E misspell -E staticcheck -E structcheck -E typecheck -E unconvert -E varcheck + - name: Run optional linters (not required to pass) + run: $(go env GOPATH)/bin/golangci-lint run --timeout=5m --issues-exit-code=0 -E dupl -E gocritic -E gosimple -E lll -E prealloc -E deadcode -E errcheck -E goconst -E gocyclo -E gofmt -E golint -E gosec -E govet -E ineffassign -E lll -E maligned -E misspell -E staticcheck -E structcheck -E typecheck -E unconvert -E varcheck + diff --git a/vendor/github.com/x448/float16/.golangci.yml b/vendor/github.com/x448/float16/.golangci.yml new file mode 100644 index 0000000..bf99a6b --- /dev/null +++ b/vendor/github.com/x448/float16/.golangci.yml @@ -0,0 +1,73 @@ +# github.com/x448/float16/.golangci.yml +linters: + disable-all: true + enable: + - deadcode + - dupl + - errcheck + - goconst + - gocyclo + - gofmt + - golint + - gosec + - gosimple + - govet + - ineffassign + - maligned + - misspell + - staticcheck + - structcheck + - typecheck + - unconvert + - unparam + - unused + - varcheck + +issues: + # Excluding configuration per-path, per-linter, per-text and per-source + exclude-rules: + - path: _test\.go + linters: + - gomnd + - lll + +# Do not remove linters-settings, some extra linters like gocritic are enabled from Github Actions or cli. +linters-settings: + dupl: + threshold: 100 + funlen: + lines: 100 + statements: 50 + goconst: + min-len: 2 + min-occurrences: 2 + gocritic: + enabled-tags: + - diagnostic + - experimental + - opinionated + - performance + - style + disabled-checks: + - dupImport # https://github.com/go-critic/go-critic/issues/845 + - ifElseChain + - octalLiteral + - paramTypeCombine + - whyNoLint + - wrapperFunc + gocyclo: + min-complexity: 15 + gofmt: + simplify: false + goimports: + local-prefixes: github.com/x448/float16 + golint: + min-confidence: 0 + govet: + check-shadowing: true + lll: + line-length: 140 + maligned: + suggest-new: true + misspell: + locale: US diff --git a/vendor/github.com/rivo/uniseg/LICENSE.txt b/vendor/github.com/x448/float16/LICENSE similarity index 93% rename from vendor/github.com/rivo/uniseg/LICENSE.txt rename to vendor/github.com/x448/float16/LICENSE index 5040f1e..3bd2a29 100644 --- a/vendor/github.com/rivo/uniseg/LICENSE.txt +++ b/vendor/github.com/x448/float16/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2019 Oliver Kuederle +Copyright (c) 2019-present Montgomery Edwards⁴⁴⁸ and Faye Amacker Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/vendor/github.com/x448/float16/README.md b/vendor/github.com/x448/float16/README.md new file mode 100644 index 0000000..e53a45d --- /dev/null +++ b/vendor/github.com/x448/float16/README.md @@ -0,0 +1,135 @@ +# Float16 (Binary16) in Go/Golang +[![](https://github.com/x448/float16/workflows/ci/badge.svg)](https://github.com/x448/float16/actions?query=workflow%3Aci) +[![](https://github.com/x448/float16/workflows/cover%20100%25/badge.svg)](https://github.com/x448/float16/actions?query=workflow%3A%22cover+100%25%22) +[![](https://github.com/x448/float16/workflows/linters/badge.svg)](https://github.com/x448/float16/actions?query=workflow%3Alinters) +[![Go Report Card](https://goreportcard.com/badge/github.com/x448/float16)](https://goreportcard.com/report/github.com/x448/float16) +[![Release](https://img.shields.io/github/release/x448/float16.svg?style=flat-square)](https://github.com/x448/float16/releases) +[![License](http://img.shields.io/badge/license-mit-blue.svg?style=flat-square)](https://raw.githubusercontent.com/x448/float16/master/LICENSE) + +[__`x448/float16`__](https://github.com/x448/float16) package provides [IEEE 754 half-precision floating-point format (binary16)](https://en.wikipedia.org/wiki/Half-precision_floating-point_format) with IEEE 754 default rounding for conversions. IEEE 754-2008 refers to this 16-bit floating-point format as binary16. + +IEEE 754 default rounding ("Round-to-Nearest RoundTiesToEven") is considered the most accurate and statistically unbiased estimate of the true result. + +All possible 4+ billion floating-point conversions with this library are verified to be correct. + +Lowercase "float16" refers to IEEE 754 binary16. And capitalized "Float16" refers to exported Go data type. + +## Features +Current features include: + +* float16 to float32 conversions use lossless conversion. +* float32 to float16 conversions use IEEE 754-2008 "Round-to-Nearest RoundTiesToEven". +* conversions using pure Go take about 2.65 ns/op on a desktop amd64. +* unit tests provide 100% code coverage and check all possible 4+ billion conversions. +* other functions include: IsInf(), IsNaN(), IsNormal(), PrecisionFromfloat32(), String(), etc. +* all functions in this library use zero allocs except String(). + +## Status +This library is used by [fxamacker/cbor](https://github.com/fxamacker/cbor) and is ready for production use on supported platforms. The version number < 1.0 indicates more functions and options are planned but not yet published. + +Current status: + +* Core API is done and breaking API changes are unlikely. +* 100% of unit tests pass: + * short mode (`go test -short`) tests around 65765 conversions in 0.005s. + * normal mode (`go test`) tests all possible 4+ billion conversions in about 95s. +* 100% code coverage with both short mode and normal mode. +* Tested on amd64, arm64, ppc64le, and s390x. + +Roadmap: + +* Add functions for fast batch conversions leveraging SIMD when supported by hardware. +* Speed up unit test when verifying all possible 4+ billion conversions. + +## Float16 to Float32 Conversion +Conversions from float16 to float32 are lossless conversions. All 65536 possible float16 to float32 conversions (in pure Go) are confirmed to be correct. + +Unit tests take a fraction of a second to check all 65536 expected values for float16 to float32 conversions. + +## Float32 to Float16 Conversion +Conversions from float32 to float16 use IEEE 754 default rounding ("Round-to-Nearest RoundTiesToEven"). All 4294967296 possible float32 to float16 conversions (in pure Go) are confirmed to be correct. + +Unit tests in normal mode take about 1-2 minutes to check all 4+ billion float32 input values and results for Fromfloat32(), FromNaN32ps(), and PrecisionFromfloat32(). + +Unit tests in short mode use a small subset (around 229 float32 inputs) and finish in under 0.01 second while still reaching 100% code coverage. + +## Usage +Install with `go get github.com/x448/float16`. +``` +// Convert float32 to float16 +pi := float32(math.Pi) +pi16 := float16.Fromfloat32(pi) + +// Convert float16 to float32 +pi32 := pi16.Float32() + +// PrecisionFromfloat32() is faster than the overhead of calling a function. +// This example only converts if there's no data loss and input is not a subnormal. +if float16.PrecisionFromfloat32(pi) == float16.PrecisionExact { + pi16 := float16.Fromfloat32(pi) +} +``` + +## Float16 Type and API +Float16 (capitalized) is a Go type with uint16 as the underlying state. There are 6 exported functions and 9 exported methods. +``` +package float16 // import "github.com/x448/float16" + +// Exported types and consts +type Float16 uint16 +const ErrInvalidNaNValue = float16Error("float16: invalid NaN value, expected IEEE 754 NaN") + +// Exported functions +Fromfloat32(f32 float32) Float16 // Float16 number converted from f32 using IEEE 754 default rounding + with identical results to AMD and Intel F16C hardware. NaN inputs + are converted with quiet bit always set on, to be like F16C. + +FromNaN32ps(nan float32) (Float16, error) // Float16 NaN without modifying quiet bit. + // The "ps" suffix means "preserve signaling". + // Returns sNaN and ErrInvalidNaNValue if nan isn't a NaN. + +Frombits(b16 uint16) Float16 // Float16 number corresponding to b16 (IEEE 754 binary16 rep.) +NaN() Float16 // Float16 of IEEE 754 binary16 not-a-number +Inf(sign int) Float16 // Float16 of IEEE 754 binary16 infinity according to sign + +PrecisionFromfloat32(f32 float32) Precision // quickly indicates exact, ..., overflow, underflow + // (inline and < 1 ns/op) +// Exported methods +(f Float16) Float32() float32 // float32 number converted from f16 using lossless conversion +(f Float16) Bits() uint16 // the IEEE 754 binary16 representation of f +(f Float16) IsNaN() bool // true if f is not-a-number (NaN) +(f Float16) IsQuietNaN() bool // true if f is a quiet not-a-number (NaN) +(f Float16) IsInf(sign int) bool // true if f is infinite based on sign (-1=NegInf, 0=any, 1=PosInf) +(f Float16) IsFinite() bool // true if f is not infinite or NaN +(f Float16) IsNormal() bool // true if f is not zero, infinite, subnormal, or NaN. +(f Float16) Signbit() bool // true if f is negative or negative zero +(f Float16) String() string // string representation of f to satisfy fmt.Stringer interface +``` +See [API](https://godoc.org/github.com/x448/float16) at godoc.org for more info. + +## Benchmarks +Conversions (in pure Go) are around 2.65 ns/op for float16 -> float32 and float32 -> float16 on amd64. Speeds can vary depending on input value. + +``` +All functions have zero allocations except float16.String(). + +FromFloat32pi-2 2.59ns ± 0% // speed using Fromfloat32() to convert a float32 of math.Pi to Float16 +ToFloat32pi-2 2.69ns ± 0% // speed using Float32() to convert a float16 of math.Pi to float32 +Frombits-2 0.29ns ± 5% // speed using Frombits() to cast a uint16 to Float16 + +PrecisionFromFloat32-2 0.29ns ± 1% // speed using PrecisionFromfloat32() to check for overflows, etc. +``` + +## System Requirements +* Go 1.12 (or newer). +* amd64, arm64, ppc64le, or s390x. + +Other architectures and Go versions may work, but are not tested regularly. + +## Special Thanks +Special thanks to Kathryn Long (starkat99) for creating [half-rs](https://github.com/starkat99/half-rs), a very nice rust implementation of float16. + +## License +Copyright © 2019-present Montgomery Edwards⁴⁴⁸ and Faye Amacker. + +x448/float16 is licensed under the MIT License. See [LICENSE](LICENSE) for the full license text. diff --git a/vendor/github.com/x448/float16/float16.go b/vendor/github.com/x448/float16/float16.go new file mode 100644 index 0000000..f3a17ed --- /dev/null +++ b/vendor/github.com/x448/float16/float16.go @@ -0,0 +1,302 @@ +// Copyright 2019 Montgomery Edwards⁴⁴⁸ and Faye Amacker +// +// Special thanks to Kathryn Long for her Rust implementation +// of float16 at github.com/starkat99/half-rs (MIT license) + +package float16 + +import ( + "math" + "strconv" +) + +// Float16 represents IEEE 754 half-precision floating-point numbers (binary16). +type Float16 uint16 + +// Precision indicates whether the conversion to Float16 is +// exact, subnormal without dropped bits, inexact, underflow, or overflow. +type Precision int + +const ( + + // PrecisionExact is for non-subnormals that don't drop bits during conversion. + // All of these can round-trip. Should always convert to float16. + PrecisionExact Precision = iota + + // PrecisionUnknown is for subnormals that don't drop bits during conversion but + // not all of these can round-trip so precision is unknown without more effort. + // Only 2046 of these can round-trip and the rest cannot round-trip. + PrecisionUnknown + + // PrecisionInexact is for dropped significand bits and cannot round-trip. + // Some of these are subnormals. Cannot round-trip float32->float16->float32. + PrecisionInexact + + // PrecisionUnderflow is for Underflows. Cannot round-trip float32->float16->float32. + PrecisionUnderflow + + // PrecisionOverflow is for Overflows. Cannot round-trip float32->float16->float32. + PrecisionOverflow +) + +// PrecisionFromfloat32 returns Precision without performing +// the conversion. Conversions from both Infinity and NaN +// values will always report PrecisionExact even if NaN payload +// or NaN-Quiet-Bit is lost. This function is kept simple to +// allow inlining and run < 0.5 ns/op, to serve as a fast filter. +func PrecisionFromfloat32(f32 float32) Precision { + u32 := math.Float32bits(f32) + + if u32 == 0 || u32 == 0x80000000 { + // +- zero will always be exact conversion + return PrecisionExact + } + + const COEFMASK uint32 = 0x7fffff // 23 least significant bits + const EXPSHIFT uint32 = 23 + const EXPBIAS uint32 = 127 + const EXPMASK uint32 = uint32(0xff) << EXPSHIFT + const DROPMASK uint32 = COEFMASK >> 10 + + exp := int32(((u32 & EXPMASK) >> EXPSHIFT) - EXPBIAS) + coef := u32 & COEFMASK + + if exp == 128 { + // +- infinity or NaN + // apps may want to do extra checks for NaN separately + return PrecisionExact + } + + // https://en.wikipedia.org/wiki/Half-precision_floating-point_format says, + // "Decimals between 2^−24 (minimum positive subnormal) and 2^−14 (maximum subnormal): fixed interval 2^−24" + if exp < -24 { + return PrecisionUnderflow + } + if exp > 15 { + return PrecisionOverflow + } + if (coef & DROPMASK) != uint32(0) { + // these include subnormals and non-subnormals that dropped bits + return PrecisionInexact + } + + if exp < -14 { + // Subnormals. Caller may want to test these further. + // There are 2046 subnormals that can successfully round-trip f32->f16->f32 + // and 20 of those 2046 have 32-bit input coef == 0. + // RFC 7049 and 7049bis Draft 12 don't precisely define "preserves value" + // so some protocols and libraries will choose to handle subnormals differently + // when deciding to encode them to CBOR float32 vs float16. + return PrecisionUnknown + } + + return PrecisionExact +} + +// Frombits returns the float16 number corresponding to the IEEE 754 binary16 +// representation u16, with the sign bit of u16 and the result in the same bit +// position. Frombits(Bits(x)) == x. +func Frombits(u16 uint16) Float16 { + return Float16(u16) +} + +// Fromfloat32 returns a Float16 value converted from f32. Conversion uses +// IEEE default rounding (nearest int, with ties to even). +func Fromfloat32(f32 float32) Float16 { + return Float16(f32bitsToF16bits(math.Float32bits(f32))) +} + +// ErrInvalidNaNValue indicates a NaN was not received. +const ErrInvalidNaNValue = float16Error("float16: invalid NaN value, expected IEEE 754 NaN") + +type float16Error string + +func (e float16Error) Error() string { return string(e) } + +// FromNaN32ps converts nan to IEEE binary16 NaN while preserving both +// signaling and payload. Unlike Fromfloat32(), which can only return +// qNaN because it sets quiet bit = 1, this can return both sNaN and qNaN. +// If the result is infinity (sNaN with empty payload), then the +// lowest bit of payload is set to make the result a NaN. +// Returns ErrInvalidNaNValue and 0x7c01 (sNaN) if nan isn't IEEE 754 NaN. +// This function was kept simple to be able to inline. +func FromNaN32ps(nan float32) (Float16, error) { + const SNAN = Float16(uint16(0x7c01)) // signaling NaN + + u32 := math.Float32bits(nan) + sign := u32 & 0x80000000 + exp := u32 & 0x7f800000 + coef := u32 & 0x007fffff + + if (exp != 0x7f800000) || (coef == 0) { + return SNAN, ErrInvalidNaNValue + } + + u16 := uint16((sign >> 16) | uint32(0x7c00) | (coef >> 13)) + + if (u16 & 0x03ff) == 0 { + // result became infinity, make it NaN by setting lowest bit in payload + u16 |= 0x0001 + } + + return Float16(u16), nil +} + +// NaN returns a Float16 of IEEE 754 binary16 not-a-number (NaN). +// Returned NaN value 0x7e01 has all exponent bits = 1 with the +// first and last bits = 1 in the significand. This is consistent +// with Go's 64-bit math.NaN(). Canonical CBOR in RFC 7049 uses 0x7e00. +func NaN() Float16 { + return Float16(0x7e01) +} + +// Inf returns a Float16 with an infinity value with the specified sign. +// A sign >= returns positive infinity. +// A sign < 0 returns negative infinity. +func Inf(sign int) Float16 { + if sign >= 0 { + return Float16(0x7c00) + } + return Float16(0x8000 | 0x7c00) +} + +// Float32 returns a float32 converted from f (Float16). +// This is a lossless conversion. +func (f Float16) Float32() float32 { + u32 := f16bitsToF32bits(uint16(f)) + return math.Float32frombits(u32) +} + +// Bits returns the IEEE 754 binary16 representation of f, with the sign bit +// of f and the result in the same bit position. Bits(Frombits(x)) == x. +func (f Float16) Bits() uint16 { + return uint16(f) +} + +// IsNaN reports whether f is an IEEE 754 binary16 “not-a-number” value. +func (f Float16) IsNaN() bool { + return (f&0x7c00 == 0x7c00) && (f&0x03ff != 0) +} + +// IsQuietNaN reports whether f is a quiet (non-signaling) IEEE 754 binary16 +// “not-a-number” value. +func (f Float16) IsQuietNaN() bool { + return (f&0x7c00 == 0x7c00) && (f&0x03ff != 0) && (f&0x0200 != 0) +} + +// IsInf reports whether f is an infinity (inf). +// A sign > 0 reports whether f is positive inf. +// A sign < 0 reports whether f is negative inf. +// A sign == 0 reports whether f is either inf. +func (f Float16) IsInf(sign int) bool { + return ((f == 0x7c00) && sign >= 0) || + (f == 0xfc00 && sign <= 0) +} + +// IsFinite returns true if f is neither infinite nor NaN. +func (f Float16) IsFinite() bool { + return (uint16(f) & uint16(0x7c00)) != uint16(0x7c00) +} + +// IsNormal returns true if f is neither zero, infinite, subnormal, or NaN. +func (f Float16) IsNormal() bool { + exp := uint16(f) & uint16(0x7c00) + return (exp != uint16(0x7c00)) && (exp != 0) +} + +// Signbit reports whether f is negative or negative zero. +func (f Float16) Signbit() bool { + return (uint16(f) & uint16(0x8000)) != 0 +} + +// String satisfies the fmt.Stringer interface. +func (f Float16) String() string { + return strconv.FormatFloat(float64(f.Float32()), 'f', -1, 32) +} + +// f16bitsToF32bits returns uint32 (float32 bits) converted from specified uint16. +func f16bitsToF32bits(in uint16) uint32 { + // All 65536 conversions with this were confirmed to be correct + // by Montgomery Edwards⁴⁴⁸ (github.com/x448). + + sign := uint32(in&0x8000) << 16 // sign for 32-bit + exp := uint32(in&0x7c00) >> 10 // exponenent for 16-bit + coef := uint32(in&0x03ff) << 13 // significand for 32-bit + + if exp == 0x1f { + if coef == 0 { + // infinity + return sign | 0x7f800000 | coef + } + // NaN + return sign | 0x7fc00000 | coef + } + + if exp == 0 { + if coef == 0 { + // zero + return sign + } + + // normalize subnormal numbers + exp++ + for coef&0x7f800000 == 0 { + coef <<= 1 + exp-- + } + coef &= 0x007fffff + } + + return sign | ((exp + (0x7f - 0xf)) << 23) | coef +} + +// f32bitsToF16bits returns uint16 (Float16 bits) converted from the specified float32. +// Conversion rounds to nearest integer with ties to even. +func f32bitsToF16bits(u32 uint32) uint16 { + // Translated from Rust to Go by Montgomery Edwards⁴⁴⁸ (github.com/x448). + // All 4294967296 conversions with this were confirmed to be correct by x448. + // Original Rust implementation is by Kathryn Long (github.com/starkat99) with MIT license. + + sign := u32 & 0x80000000 + exp := u32 & 0x7f800000 + coef := u32 & 0x007fffff + + if exp == 0x7f800000 { + // NaN or Infinity + nanBit := uint32(0) + if coef != 0 { + nanBit = uint32(0x0200) + } + return uint16((sign >> 16) | uint32(0x7c00) | nanBit | (coef >> 13)) + } + + halfSign := sign >> 16 + + unbiasedExp := int32(exp>>23) - 127 + halfExp := unbiasedExp + 15 + + if halfExp >= 0x1f { + return uint16(halfSign | uint32(0x7c00)) + } + + if halfExp <= 0 { + if 14-halfExp > 24 { + return uint16(halfSign) + } + c := coef | uint32(0x00800000) + halfCoef := c >> uint32(14-halfExp) + roundBit := uint32(1) << uint32(13-halfExp) + if (c&roundBit) != 0 && (c&(3*roundBit-1)) != 0 { + halfCoef++ + } + return uint16(halfSign | halfCoef) + } + + uHalfExp := uint32(halfExp) << 10 + halfCoef := coef >> 13 + roundBit := uint32(0x00001000) + if (coef&roundBit) != 0 && (coef&(3*roundBit-1)) != 0 { + return uint16((halfSign | uHalfExp | halfCoef) + 1) + } + return uint16(halfSign | uHalfExp | halfCoef) +} diff --git a/vendor/github.com/x448/float16/float16_bench_test.go b/vendor/github.com/x448/float16/float16_bench_test.go new file mode 100644 index 0000000..bd9fbfa --- /dev/null +++ b/vendor/github.com/x448/float16/float16_bench_test.go @@ -0,0 +1,88 @@ +// Copyright 2019 Montgomery Edwards⁴⁴⁸ and Faye Amacker + +package float16_test + +import ( + "math" + "testing" + + "github.com/x448/float16" +) + +// prevent compiler optimizing out code by assigning to these +var resultF16 float16.Float16 +var resultF32 float32 +var resultStr string +var pcn float16.Precision + +func BenchmarkFloat32pi(b *testing.B) { + result := float32(0) + pi32 := float32(math.Pi) + pi16 := float16.Fromfloat32(pi32) + for i := 0; i < b.N; i++ { + f16 := float16.Frombits(uint16(pi16)) + result = f16.Float32() + } + resultF32 = result +} + +func BenchmarkFrombits(b *testing.B) { + result := float16.Float16(0) + pi32 := float32(math.Pi) + pi16 := float16.Fromfloat32(pi32) + for i := 0; i < b.N; i++ { + result = float16.Frombits(uint16(pi16)) + } + resultF16 = result +} + +func BenchmarkFromFloat32pi(b *testing.B) { + result := float16.Float16(0) + + pi := float32(math.Pi) + for i := 0; i < b.N; i++ { + result = float16.Fromfloat32(pi) + } + resultF16 = result +} + +func BenchmarkFromFloat32nan(b *testing.B) { + result := float16.Float16(0) + + nan := float32(math.NaN()) + for i := 0; i < b.N; i++ { + result = float16.Fromfloat32(nan) + } + resultF16 = result +} + +func BenchmarkFromFloat32subnorm(b *testing.B) { + result := float16.Float16(0) + + subnorm := math.Float32frombits(0x007fffff) + for i := 0; i < b.N; i++ { + result = float16.Fromfloat32(subnorm) + } + resultF16 = result +} + +func BenchmarkPrecisionFromFloat32(b *testing.B) { + var result float16.Precision + + for i := 0; i < b.N; i++ { + f32 := float32(0.00001) + float32(0.00001) + result = float16.PrecisionFromfloat32(f32) + } + pcn = result +} + +func BenchmarkString(b *testing.B) { + var result string + + pi32 := float32(math.Pi) + pi16 := float16.Fromfloat32(pi32) + for i := 0; i < b.N; i++ { + result = pi16.String() + } + resultStr = result +} diff --git a/vendor/github.com/x448/float16/float16_test.go b/vendor/github.com/x448/float16/float16_test.go new file mode 100644 index 0000000..766cf35 --- /dev/null +++ b/vendor/github.com/x448/float16/float16_test.go @@ -0,0 +1,798 @@ +// Copyright 2019 Montgomery Edwards⁴⁴⁸ and Faye Amacker + +package float16_test + +import ( + "bytes" + "crypto/sha512" + "encoding/binary" + "encoding/hex" + "fmt" + "math" + "testing" + + "github.com/x448/float16" +) + +// wantF32toF16bits is a tiny subset of expected values +var wantF32toF16bits = []struct { + in float32 + out uint16 +}{ + // generated to provide 100% code coverage plus additional tests for rounding, etc. + {in: math.Float32frombits(0x00000000), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x00000001), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x00001fff), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x00002000), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x00003fff), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x00004000), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x007fffff), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x00800000), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x33000000), out: 0x0000}, // in f32=0.000000, out f16=0 + {in: math.Float32frombits(0x33000001), out: 0x0001}, // in f32=0.000000, out f16=0.000000059604645 + {in: math.Float32frombits(0x33000002), out: 0x0001}, // in f32=0.000000, out f16=0.000000059604645 + {in: math.Float32frombits(0x387fc000), out: 0x03ff}, // in f32=0.000061, out f16=0.00006097555 // exp32=-15 (underflows binary16 exp) but round-trips + {in: math.Float32frombits(0x387fffff), out: 0x0400}, // in f32=0.000061, out f16=0.000061035156 + {in: math.Float32frombits(0x38800000), out: 0x0400}, // in f32=0.000061, out f16=0.000061035156 + {in: math.Float32frombits(0x38801fff), out: 0x0401}, // in f32=0.000061, out f16=0.00006109476 + {in: math.Float32frombits(0x38802000), out: 0x0401}, // in f32=0.000061, out f16=0.00006109476 + {in: math.Float32frombits(0x38803fff), out: 0x0402}, // in f32=0.000061, out f16=0.000061154366 + {in: math.Float32frombits(0x38804000), out: 0x0402}, // in f32=0.000061, out f16=0.000061154366 + {in: math.Float32frombits(0x33bfffff), out: 0x0001}, // in f32=0.000000, out f16=0.000000059604645 + {in: math.Float32frombits(0x33c00000), out: 0x0002}, // in f32=0.000000, out f16=0.00000011920929 + {in: math.Float32frombits(0x33c00001), out: 0x0002}, // in f32=0.000000, out f16=0.00000011920929 + {in: math.Float32frombits(0x477fffff), out: 0x7c00}, // in f32=65535.996094, out f16=+Inf + {in: math.Float32frombits(0x47800000), out: 0x7c00}, // in f32=65536.000000, out f16=+Inf + {in: math.Float32frombits(0x7f7fffff), out: 0x7c00}, // in f32=340282346638528859811704183484516925440.000000, out f16=+Inf + {in: math.Float32frombits(0x7f800000), out: 0x7c00}, // in f32=+Inf, out f16=+Inf + {in: math.Float32frombits(0x7f801fff), out: 0x7e00}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0x7f802000), out: 0x7e01}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0x7f803fff), out: 0x7e01}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0x7f804000), out: 0x7e02}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0x7fffffff), out: 0x7fff}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0x80000000), out: 0x8000}, // in f32=-0.000000, out f16=-0 + {in: math.Float32frombits(0x80001fff), out: 0x8000}, // in f32=-0.000000, out f16=-0 + {in: math.Float32frombits(0x80002000), out: 0x8000}, // in f32=-0.000000, out f16=-0 + {in: math.Float32frombits(0x80003fff), out: 0x8000}, // in f32=-0.000000, out f16=-0 + {in: math.Float32frombits(0x80004000), out: 0x8000}, // in f32=-0.000000, out f16=-0 + {in: math.Float32frombits(0x807fffff), out: 0x8000}, // in f32=-0.000000, out f16=-0 + {in: math.Float32frombits(0x80800000), out: 0x8000}, // in f32=-0.000000, out f16=-0 + {in: math.Float32frombits(0xb87fc000), out: 0x83ff}, // in f32=-0.000061, out f16=-0.00006097555 // exp32=-15 (underflows binary16 exp) but round-trips + {in: math.Float32frombits(0xb87fffff), out: 0x8400}, // in f32=-0.000061, out f16=-0.000061035156 + {in: math.Float32frombits(0xb8800000), out: 0x8400}, // in f32=-0.000061, out f16=-0.000061035156 + {in: math.Float32frombits(0xb8801fff), out: 0x8401}, // in f32=-0.000061, out f16=-0.00006109476 + {in: math.Float32frombits(0xb8802000), out: 0x8401}, // in f32=-0.000061, out f16=-0.00006109476 + {in: math.Float32frombits(0xb8803fff), out: 0x8402}, // in f32=-0.000061, out f16=-0.000061154366 + {in: math.Float32frombits(0xb8804000), out: 0x8402}, // in f32=-0.000061, out f16=-0.000061154366 + {in: math.Float32frombits(0xc77fffff), out: 0xfc00}, // in f32=-65535.996094, out f16=-Inf + {in: math.Float32frombits(0xc7800000), out: 0xfc00}, // in f32=-65536.000000, out f16=-Inf + {in: math.Float32frombits(0xff7fffff), out: 0xfc00}, // in f32=-340282346638528859811704183484516925440.000000, out f16=-Inf + {in: math.Float32frombits(0xff800000), out: 0xfc00}, // in f32=-Inf, out f16=-Inf + {in: math.Float32frombits(0xff801fff), out: 0xfe00}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0xff802000), out: 0xfe01}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0xff803fff), out: 0xfe01}, // in f32=NaN, out f16=NaN + {in: math.Float32frombits(0xff804000), out: 0xfe02}, // in f32=NaN, out f16=NaN + // additional tests + {in: math.Float32frombits(0xc77ff000), out: 0xfc00}, // in f32=-65520.000000, out f16=-Inf + {in: math.Float32frombits(0xc77fef00), out: 0xfbff}, // in f32=-65519.000000, out f16=-65504 + {in: math.Float32frombits(0xc77fee00), out: 0xfbff}, // in f32=-65518.000000, out f16=-65504 + {in: math.Float32frombits(0xc5802000), out: 0xec01}, // in f32=-4100.000000, out f16=-4100 + {in: math.Float32frombits(0xc5801800), out: 0xec01}, // in f32=-4099.000000, out f16=-4100 + {in: math.Float32frombits(0xc5801000), out: 0xec00}, // in f32=-4098.000000, out f16=-4096 + {in: math.Float32frombits(0xc5800800), out: 0xec00}, // in f32=-4097.000000, out f16=-4096 + {in: math.Float32frombits(0xc5800000), out: 0xec00}, // in f32=-4096.000000, out f16=-4096 + {in: math.Float32frombits(0xc57ff000), out: 0xec00}, // in f32=-4095.000000, out f16=-4096 + {in: math.Float32frombits(0xc57fe000), out: 0xebff}, // in f32=-4094.000000, out f16=-4094 + {in: math.Float32frombits(0xc57fd000), out: 0xebfe}, // in f32=-4093.000000, out f16=-4092 + {in: math.Float32frombits(0xc5002000), out: 0xe801}, // in f32=-2050.000000, out f16=-2050 + {in: math.Float32frombits(0xc5001000), out: 0xe800}, // in f32=-2049.000000, out f16=-2048 + {in: math.Float32frombits(0xc5000829), out: 0xe800}, // in f32=-2048.510010, out f16=-2048 + {in: math.Float32frombits(0xc5000800), out: 0xe800}, // in f32=-2048.500000, out f16=-2048 + {in: math.Float32frombits(0xc50007d7), out: 0xe800}, // in f32=-2048.489990, out f16=-2048 + {in: math.Float32frombits(0xc5000000), out: 0xe800}, // in f32=-2048.000000, out f16=-2048 + {in: math.Float32frombits(0xc4fff052), out: 0xe800}, // in f32=-2047.510010, out f16=-2048 + {in: math.Float32frombits(0xc4fff000), out: 0xe800}, // in f32=-2047.500000, out f16=-2048 + {in: math.Float32frombits(0xc4ffefae), out: 0xe7ff}, // in f32=-2047.489990, out f16=-2047 + {in: math.Float32frombits(0xc4ffe000), out: 0xe7ff}, // in f32=-2047.000000, out f16=-2047 + {in: math.Float32frombits(0xc4ffc000), out: 0xe7fe}, // in f32=-2046.000000, out f16=-2046 + {in: math.Float32frombits(0xc4ffa000), out: 0xe7fd}, // in f32=-2045.000000, out f16=-2045 + {in: math.Float32frombits(0xbf800000), out: 0xbc00}, // in f32=-1.000000, out f16=-1 + {in: math.Float32frombits(0xbf028f5c), out: 0xb814}, // in f32=-0.510000, out f16=-0.5097656 + {in: math.Float32frombits(0xbf000000), out: 0xb800}, // in f32=-0.500000, out f16=-0.5 + {in: math.Float32frombits(0xbefae148), out: 0xb7d7}, // in f32=-0.490000, out f16=-0.48999023 + {in: math.Float32frombits(0x3efae148), out: 0x37d7}, // in f32=0.490000, out f16=0.48999023 + {in: math.Float32frombits(0x3f000000), out: 0x3800}, // in f32=0.500000, out f16=0.5 + {in: math.Float32frombits(0x3f028f5c), out: 0x3814}, // in f32=0.510000, out f16=0.5097656 + {in: math.Float32frombits(0x3f800000), out: 0x3c00}, // in f32=1.000000, out f16=1 + {in: math.Float32frombits(0x3fbeb852), out: 0x3df6}, // in f32=1.490000, out f16=1.4902344 + {in: math.Float32frombits(0x3fc00000), out: 0x3e00}, // in f32=1.500000, out f16=1.5 + {in: math.Float32frombits(0x3fc147ae), out: 0x3e0a}, // in f32=1.510000, out f16=1.5097656 + {in: math.Float32frombits(0x3fcf1bbd), out: 0x3e79}, // in f32=1.618034, out f16=1.6181641 + {in: math.Float32frombits(0x401f5c29), out: 0x40fb}, // in f32=2.490000, out f16=2.4902344 + {in: math.Float32frombits(0x40200000), out: 0x4100}, // in f32=2.500000, out f16=2.5 + {in: math.Float32frombits(0x4020a3d7), out: 0x4105}, // in f32=2.510000, out f16=2.5097656 + {in: math.Float32frombits(0x402df854), out: 0x4170}, // in f32=2.718282, out f16=2.71875 + {in: math.Float32frombits(0x40490fdb), out: 0x4248}, // in f32=3.141593, out f16=3.140625 + {in: math.Float32frombits(0x40b00000), out: 0x4580}, // in f32=5.500000, out f16=5.5 + {in: math.Float32frombits(0x44ffa000), out: 0x67fd}, // in f32=2045.000000, out f16=2045 + {in: math.Float32frombits(0x44ffc000), out: 0x67fe}, // in f32=2046.000000, out f16=2046 + {in: math.Float32frombits(0x44ffe000), out: 0x67ff}, // in f32=2047.000000, out f16=2047 + {in: math.Float32frombits(0x44ffefae), out: 0x67ff}, // in f32=2047.489990, out f16=2047 + {in: math.Float32frombits(0x44fff000), out: 0x6800}, // in f32=2047.500000, out f16=2048 + {in: math.Float32frombits(0x44fff052), out: 0x6800}, // in f32=2047.510010, out f16=2048 + {in: math.Float32frombits(0x45000000), out: 0x6800}, // in f32=2048.000000, out f16=2048 + {in: math.Float32frombits(0x450007d7), out: 0x6800}, // in f32=2048.489990, out f16=2048 + {in: math.Float32frombits(0x45000800), out: 0x6800}, // in f32=2048.500000, out f16=2048 + {in: math.Float32frombits(0x45000829), out: 0x6800}, // in f32=2048.510010, out f16=2048 + {in: math.Float32frombits(0x45001000), out: 0x6800}, // in f32=2049.000000, out f16=2048 + {in: math.Float32frombits(0x450017d7), out: 0x6801}, // in f32=2049.489990, out f16=2050 + {in: math.Float32frombits(0x45001800), out: 0x6801}, // in f32=2049.500000, out f16=2050 + {in: math.Float32frombits(0x45001829), out: 0x6801}, // in f32=2049.510010, out f16=2050 + {in: math.Float32frombits(0x45002000), out: 0x6801}, // in f32=2050.000000, out f16=2050 + {in: math.Float32frombits(0x45003000), out: 0x6802}, // in f32=2051.000000, out f16=2052 + {in: math.Float32frombits(0x457fd000), out: 0x6bfe}, // in f32=4093.000000, out f16=4092 + {in: math.Float32frombits(0x457fe000), out: 0x6bff}, // in f32=4094.000000, out f16=4094 + {in: math.Float32frombits(0x457ff000), out: 0x6c00}, // in f32=4095.000000, out f16=4096 + {in: math.Float32frombits(0x45800000), out: 0x6c00}, // in f32=4096.000000, out f16=4096 + {in: math.Float32frombits(0x45800800), out: 0x6c00}, // in f32=4097.000000, out f16=4096 + {in: math.Float32frombits(0x45801000), out: 0x6c00}, // in f32=4098.000000, out f16=4096 + {in: math.Float32frombits(0x45801800), out: 0x6c01}, // in f32=4099.000000, out f16=4100 + {in: math.Float32frombits(0x45802000), out: 0x6c01}, // in f32=4100.000000, out f16=4100 + {in: math.Float32frombits(0x45ad9c00), out: 0x6d6d}, // in f32=5555.500000, out f16=5556 + {in: math.Float32frombits(0x45ffe800), out: 0x6fff}, // in f32=8189.000000, out f16=8188 + {in: math.Float32frombits(0x45fff000), out: 0x7000}, // in f32=8190.000000, out f16=8192 + {in: math.Float32frombits(0x45fff800), out: 0x7000}, // in f32=8191.000000, out f16=8192 + {in: math.Float32frombits(0x46000000), out: 0x7000}, // in f32=8192.000000, out f16=8192 + {in: math.Float32frombits(0x46000400), out: 0x7000}, // in f32=8193.000000, out f16=8192 + {in: math.Float32frombits(0x46000800), out: 0x7000}, // in f32=8194.000000, out f16=8192 + {in: math.Float32frombits(0x46000c00), out: 0x7000}, // in f32=8195.000000, out f16=8192 + {in: math.Float32frombits(0x46001000), out: 0x7000}, // in f32=8196.000000, out f16=8192 + {in: math.Float32frombits(0x46001400), out: 0x7001}, // in f32=8197.000000, out f16=8200 + {in: math.Float32frombits(0x46001800), out: 0x7001}, // in f32=8198.000000, out f16=8200 + {in: math.Float32frombits(0x46001c00), out: 0x7001}, // in f32=8199.000000, out f16=8200 + {in: math.Float32frombits(0x46002000), out: 0x7001}, // in f32=8200.000000, out f16=8200 + {in: math.Float32frombits(0x46002400), out: 0x7001}, // in f32=8201.000000, out f16=8200 + {in: math.Float32frombits(0x46002800), out: 0x7001}, // in f32=8202.000000, out f16=8200 + {in: math.Float32frombits(0x46002c00), out: 0x7001}, // in f32=8203.000000, out f16=8200 + {in: math.Float32frombits(0x46003000), out: 0x7002}, // in f32=8204.000000, out f16=8208 + {in: math.Float32frombits(0x467fec00), out: 0x73ff}, // in f32=16379.000000, out f16=16376 + {in: math.Float32frombits(0x467ff000), out: 0x7400}, // in f32=16380.000000, out f16=16384 + {in: math.Float32frombits(0x467ff400), out: 0x7400}, // in f32=16381.000000, out f16=16384 + {in: math.Float32frombits(0x467ff800), out: 0x7400}, // in f32=16382.000000, out f16=16384 + {in: math.Float32frombits(0x467ffc00), out: 0x7400}, // in f32=16383.000000, out f16=16384 + {in: math.Float32frombits(0x46800000), out: 0x7400}, // in f32=16384.000000, out f16=16384 + {in: math.Float32frombits(0x46800200), out: 0x7400}, // in f32=16385.000000, out f16=16384 + {in: math.Float32frombits(0x46800400), out: 0x7400}, // in f32=16386.000000, out f16=16384 + {in: math.Float32frombits(0x46800600), out: 0x7400}, // in f32=16387.000000, out f16=16384 + {in: math.Float32frombits(0x46800800), out: 0x7400}, // in f32=16388.000000, out f16=16384 + {in: math.Float32frombits(0x46800a00), out: 0x7400}, // in f32=16389.000000, out f16=16384 + {in: math.Float32frombits(0x46800c00), out: 0x7400}, // in f32=16390.000000, out f16=16384 + {in: math.Float32frombits(0x46800e00), out: 0x7400}, // in f32=16391.000000, out f16=16384 + {in: math.Float32frombits(0x46801000), out: 0x7400}, // in f32=16392.000000, out f16=16384 + {in: math.Float32frombits(0x46801200), out: 0x7401}, // in f32=16393.000000, out f16=16400 + {in: math.Float32frombits(0x46801400), out: 0x7401}, // in f32=16394.000000, out f16=16400 + {in: math.Float32frombits(0x46801600), out: 0x7401}, // in f32=16395.000000, out f16=16400 + {in: math.Float32frombits(0x46801800), out: 0x7401}, // in f32=16396.000000, out f16=16400 + {in: math.Float32frombits(0x46801a00), out: 0x7401}, // in f32=16397.000000, out f16=16400 + {in: math.Float32frombits(0x46801c00), out: 0x7401}, // in f32=16398.000000, out f16=16400 + {in: math.Float32frombits(0x46801e00), out: 0x7401}, // in f32=16399.000000, out f16=16400 + {in: math.Float32frombits(0x46802000), out: 0x7401}, // in f32=16400.000000, out f16=16400 + {in: math.Float32frombits(0x46802200), out: 0x7401}, // in f32=16401.000000, out f16=16400 + {in: math.Float32frombits(0x46802400), out: 0x7401}, // in f32=16402.000000, out f16=16400 + {in: math.Float32frombits(0x46802600), out: 0x7401}, // in f32=16403.000000, out f16=16400 + {in: math.Float32frombits(0x46802800), out: 0x7401}, // in f32=16404.000000, out f16=16400 + {in: math.Float32frombits(0x46802a00), out: 0x7401}, // in f32=16405.000000, out f16=16400 + {in: math.Float32frombits(0x46802c00), out: 0x7401}, // in f32=16406.000000, out f16=16400 + {in: math.Float32frombits(0x46802e00), out: 0x7401}, // in f32=16407.000000, out f16=16400 + {in: math.Float32frombits(0x46803000), out: 0x7402}, // in f32=16408.000000, out f16=16416 + {in: math.Float32frombits(0x46ffee00), out: 0x77ff}, // in f32=32759.000000, out f16=32752 + {in: math.Float32frombits(0x46fff000), out: 0x7800}, // in f32=32760.000000, out f16=32768 + {in: math.Float32frombits(0x46fff200), out: 0x7800}, // in f32=32761.000000, out f16=32768 + {in: math.Float32frombits(0x46fff400), out: 0x7800}, // in f32=32762.000000, out f16=32768 + {in: math.Float32frombits(0x46fff600), out: 0x7800}, // in f32=32763.000000, out f16=32768 + {in: math.Float32frombits(0x46fff800), out: 0x7800}, // in f32=32764.000000, out f16=32768 + {in: math.Float32frombits(0x46fffa00), out: 0x7800}, // in f32=32765.000000, out f16=32768 + {in: math.Float32frombits(0x46fffc00), out: 0x7800}, // in f32=32766.000000, out f16=32768 + {in: math.Float32frombits(0x46fffe00), out: 0x7800}, // in f32=32767.000000, out f16=32768 + {in: math.Float32frombits(0x47000000), out: 0x7800}, // in f32=32768.000000, out f16=32768 + {in: math.Float32frombits(0x47000100), out: 0x7800}, // in f32=32769.000000, out f16=32768 + {in: math.Float32frombits(0x47000200), out: 0x7800}, // in f32=32770.000000, out f16=32768 + {in: math.Float32frombits(0x47000300), out: 0x7800}, // in f32=32771.000000, out f16=32768 + {in: math.Float32frombits(0x47000400), out: 0x7800}, // in f32=32772.000000, out f16=32768 + {in: math.Float32frombits(0x47000500), out: 0x7800}, // in f32=32773.000000, out f16=32768 + {in: math.Float32frombits(0x47000600), out: 0x7800}, // in f32=32774.000000, out f16=32768 + {in: math.Float32frombits(0x47000700), out: 0x7800}, // in f32=32775.000000, out f16=32768 + {in: math.Float32frombits(0x47000800), out: 0x7800}, // in f32=32776.000000, out f16=32768 + {in: math.Float32frombits(0x47000900), out: 0x7800}, // in f32=32777.000000, out f16=32768 + {in: math.Float32frombits(0x47000a00), out: 0x7800}, // in f32=32778.000000, out f16=32768 + {in: math.Float32frombits(0x47000b00), out: 0x7800}, // in f32=32779.000000, out f16=32768 + {in: math.Float32frombits(0x47000c00), out: 0x7800}, // in f32=32780.000000, out f16=32768 + {in: math.Float32frombits(0x47000d00), out: 0x7800}, // in f32=32781.000000, out f16=32768 + {in: math.Float32frombits(0x47000e00), out: 0x7800}, // in f32=32782.000000, out f16=32768 + {in: math.Float32frombits(0x47000f00), out: 0x7800}, // in f32=32783.000000, out f16=32768 + {in: math.Float32frombits(0x47001000), out: 0x7800}, // in f32=32784.000000, out f16=32768 + {in: math.Float32frombits(0x47001100), out: 0x7801}, // in f32=32785.000000, out f16=32800 + {in: math.Float32frombits(0x47001200), out: 0x7801}, // in f32=32786.000000, out f16=32800 + {in: math.Float32frombits(0x47001300), out: 0x7801}, // in f32=32787.000000, out f16=32800 + {in: math.Float32frombits(0x47001400), out: 0x7801}, // in f32=32788.000000, out f16=32800 + {in: math.Float32frombits(0x47001500), out: 0x7801}, // in f32=32789.000000, out f16=32800 + {in: math.Float32frombits(0x47001600), out: 0x7801}, // in f32=32790.000000, out f16=32800 + {in: math.Float32frombits(0x47001700), out: 0x7801}, // in f32=32791.000000, out f16=32800 + {in: math.Float32frombits(0x47001800), out: 0x7801}, // in f32=32792.000000, out f16=32800 + {in: math.Float32frombits(0x47001900), out: 0x7801}, // in f32=32793.000000, out f16=32800 + {in: math.Float32frombits(0x47001a00), out: 0x7801}, // in f32=32794.000000, out f16=32800 + {in: math.Float32frombits(0x47001b00), out: 0x7801}, // in f32=32795.000000, out f16=32800 + {in: math.Float32frombits(0x47001c00), out: 0x7801}, // in f32=32796.000000, out f16=32800 + {in: math.Float32frombits(0x47001d00), out: 0x7801}, // in f32=32797.000000, out f16=32800 + {in: math.Float32frombits(0x47001e00), out: 0x7801}, // in f32=32798.000000, out f16=32800 + {in: math.Float32frombits(0x47001f00), out: 0x7801}, // in f32=32799.000000, out f16=32800 + {in: math.Float32frombits(0x47002000), out: 0x7801}, // in f32=32800.000000, out f16=32800 + {in: math.Float32frombits(0x47002100), out: 0x7801}, // in f32=32801.000000, out f16=32800 + {in: math.Float32frombits(0x47002200), out: 0x7801}, // in f32=32802.000000, out f16=32800 + {in: math.Float32frombits(0x47002300), out: 0x7801}, // in f32=32803.000000, out f16=32800 + {in: math.Float32frombits(0x47002400), out: 0x7801}, // in f32=32804.000000, out f16=32800 + {in: math.Float32frombits(0x47002500), out: 0x7801}, // in f32=32805.000000, out f16=32800 + {in: math.Float32frombits(0x47002600), out: 0x7801}, // in f32=32806.000000, out f16=32800 + {in: math.Float32frombits(0x47002700), out: 0x7801}, // in f32=32807.000000, out f16=32800 + {in: math.Float32frombits(0x47002800), out: 0x7801}, // in f32=32808.000000, out f16=32800 + {in: math.Float32frombits(0x47002900), out: 0x7801}, // in f32=32809.000000, out f16=32800 + {in: math.Float32frombits(0x47002a00), out: 0x7801}, // in f32=32810.000000, out f16=32800 + {in: math.Float32frombits(0x47002b00), out: 0x7801}, // in f32=32811.000000, out f16=32800 + {in: math.Float32frombits(0x47002c00), out: 0x7801}, // in f32=32812.000000, out f16=32800 + {in: math.Float32frombits(0x47002d00), out: 0x7801}, // in f32=32813.000000, out f16=32800 + {in: math.Float32frombits(0x47002e00), out: 0x7801}, // in f32=32814.000000, out f16=32800 + {in: math.Float32frombits(0x47002f00), out: 0x7801}, // in f32=32815.000000, out f16=32800 + {in: math.Float32frombits(0x47003000), out: 0x7802}, // in f32=32816.000000, out f16=32832 + {in: math.Float32frombits(0x477fe500), out: 0x7bff}, // in f32=65509.000000, out f16=65504 + {in: math.Float32frombits(0x477fe100), out: 0x7bff}, // in f32=65505.000000, out f16=65504 + {in: math.Float32frombits(0x477fee00), out: 0x7bff}, // in f32=65518.000000, out f16=65504 + {in: math.Float32frombits(0x477fef00), out: 0x7bff}, // in f32=65519.000000, out f16=65504 + {in: math.Float32frombits(0x477feffd), out: 0x7bff}, // in f32=65519.988281, out f16=65504 + {in: math.Float32frombits(0x477ff000), out: 0x7c00}, // in f32=65520.000000, out f16=+Inf +} + +func TestPrecisionFromfloat32(t *testing.T) { + for i, v := range wantF32toF16bits { + f16 := float16.Fromfloat32(v.in) + u16 := uint16(f16) + + if u16 != v.out { + t.Errorf("i=%d, in f32bits=0x%08x, wanted=0x%04x, got=0x%04x.", i, math.Float32bits(v.in), v.out, u16) + } + + checkPrecision(t, v.in, f16, uint64(i)) + } + + f32 := float32(5.5) // value that doesn't drop any bits in the significand, is within normal exponent range + pre := float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionExact { + t.Errorf("f32bits=0x%08x, wanted=PrecisionExact (%d), got=%d.", math.Float32bits(f32), float16.PrecisionExact, pre) + } + + f32 = math.Float32frombits(0x38000000) // subnormal value with coef = 0 that can round-trip float32->float16->float32 + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionUnknown { + t.Errorf("f32bits=0x%08x, wanted=PrecisionUnknown (%d), got=%d.", math.Float32bits(f32), float16.PrecisionUnknown, pre) + } + + f32 = math.Float32frombits(0x387fc000) // subnormal value with coef !=0 that can round-trip float32->float16->float32 + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionUnknown { + t.Errorf("f32bits=0x%08x, wanted=PrecisionUnknown (%d), got=%d.", math.Float32bits(f32), float16.PrecisionUnknown, pre) + } + + f32 = math.Float32frombits(0x33c00000) // subnormal value with no dropped bits that cannot round-trip float32->float16->float32 + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionUnknown { + t.Errorf("f32bits=0x%08x, wanted=PrecisionUnknown (%d), got=%d.", math.Float32bits(f32), float16.PrecisionUnknown, pre) + } + + f32 = math.Float32frombits(0x38000001) // subnormal value with dropped non-zero bits > 0 + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionInexact { + t.Errorf("f32bits=0x%08x, wanted=PrecisionInexact (%d), got=%d.", math.Float32bits(f32), float16.PrecisionInexact, pre) + } + + f32 = float32(math.Pi) // value that cannot "preserve value" because it drops bits in the significand + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionInexact { + t.Errorf("f32bits=0x%08x, wanted=PrecisionInexact (%d), got=%d.", math.Float32bits(f32), float16.PrecisionInexact, pre) + } + + f32 = math.Float32frombits(0x1) // value that will underflow + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionUnderflow { + t.Errorf("f32bits=0x%08x, wanted=PrecisionUnderflow (%d), got=%d.", math.Float32bits(f32), float16.PrecisionUnderflow, pre) + } + + f32 = math.Float32frombits(0x33000000) // value that will underflow + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionUnderflow { + t.Errorf("f32bits=0x%08x, wanted=PrecisionUnderflow (%d), got=%d.", math.Float32bits(f32), float16.PrecisionUnderflow, pre) + } + + f32 = math.Float32frombits(0x47800000) // value that will overflow + pre = float16.PrecisionFromfloat32(f32) + if pre != float16.PrecisionOverflow { + t.Errorf("f32bits=0x%08x, wanted=PrecisionOverflow (%d), got=%d.", math.Float32bits(f32), float16.PrecisionOverflow, pre) + } + +} + +func TestFromNaN32ps(t *testing.T) { + for i, v := range wantF32toF16bits { + f16 := float16.Fromfloat32(v.in) + u16 := uint16(f16) + + if u16 != v.out { + t.Errorf("i=%d, in f32bits=0x%08x, wanted=0x%04x, got=0x%04x.", i, math.Float32bits(v.in), v.out, u16) + } + + checkFromNaN32ps(t, v.in, f16) + } + + // since checkFromNaN32ps rejects non-NaN input, try one here + nan, err := float16.FromNaN32ps(float32(math.Pi)) + if err != float16.ErrInvalidNaNValue { + t.Errorf("FromNaN32ps: in float32(math.Pi) wanted err float16.ErrInvalidNaNValue, got err = %q", err) + } + if err.Error() != "float16: invalid NaN value, expected IEEE 754 NaN" { + t.Errorf("unexpected string value returned by err.Error() for ErrInvalidNaNValue: %s", err.Error()) + } + if uint16(nan) != 0x7c01 { // signaling NaN + t.Errorf("FromNaN32ps: in float32(math.Pi) wanted nan = 0x7c01, got nan = 0x%04x", uint16(nan)) + } + +} + +// Test a small subset of possible conversions from float32 to Float16. +// TestSomeFromFloat32 runs in under 1 second while TestAllFromFloat32 takes about 45 seconds. +func TestSomeFromFloat32(t *testing.T) { + + for i, v := range wantF32toF16bits { + f16 := float16.Fromfloat32(v.in) + u16 := uint16(f16) + + if u16 != v.out { + t.Errorf("i=%d, in f32bits=0x%08x, wanted=0x%04x, got=0x%04x.", i, math.Float32bits(v.in), v.out, u16) + } + } +} + +// Test all possible 4294967296 float32 input values and results for +// Fromfloat32(), FromNaN32ps(), and PrecisionFromfloat32(). +func TestAllFromFloat32(t *testing.T) { + + if testing.Short() { + t.Skip("skipping TestAllFromFloat32 in short mode.") + } + + fmt.Printf("WARNING: TestAllFromFloat32 should take about 1-2 minutes to run on amd64, other platforms may take longer...\n") + + // Blake2b is "3f310bc5608a087462d361644fe66feeb4c68145f6f18eb6f1439cd7914888b6df9e30ae5350dce0635162cc6a2f23b31b3e4353ca132a3c552bdbd58baa54e6" + const wantSHA512 = "08670429a475164d6c4a080969e35231c77ef7069b430b5f38af22e013796b7818bbe8f5942a6ddf26de0e1dfc67d02243f483d85729ebc3762fc2948a5ca1f8" + + const batchSize uint32 = 16384 + results := make([]uint16, batchSize) + buf := new(bytes.Buffer) + h := sha512.New() + + for i := uint64(0); i < uint64(0xFFFFFFFF); i += uint64(batchSize) { + // fill results + for j := uint32(0); j < batchSize; j++ { + inF32 := math.Float32frombits(uint32(i) + j) + f16 := float16.Fromfloat32(inF32) + results[j] = uint16(f16) + checkPrecision(t, inF32, f16, i) + checkFromNaN32ps(t, inF32, f16) + } + + // convert results to []byte + err := binary.Write(buf, binary.LittleEndian, results) + if err != nil { + panic(err) + } + + // update hash with []byte of results + _, err = h.Write(buf.Bytes()) + if err != nil { + panic(err) + } + + buf.Reset() + } + + // display hash digest in hex + digest := h.Sum(nil) + gotSHA512hex := hex.EncodeToString(digest) + if gotSHA512hex != wantSHA512 { + t.Errorf("gotSHA512hex = %s", gotSHA512hex) + } +} + +// Test all 65536 conversions from float16 to float32. +// TestAllToFloat32 runs in under 1 second. +func TestAllToFloat32(t *testing.T) { + // Blake2b is "078d8e3fac9480de1493f22c8f9bfc1eb2051537c536f00f621557d70eed1af057a487c3e252f6d593769f5288d5ab66d8e9cd1adba359838802944bdb731f4d" + const wantSHA512 = "1a4ccec9fd7b6e83310c6b4958a25778cd95f8d4f88b19950e4b8d6932a955f7fbd96b1c9bd9b2a79c3a9d34d653f55e671f8f86e6a5a876660cd38479001aa6" + const batchSize uint32 = 16384 + results := make([]float32, batchSize) + buf := new(bytes.Buffer) + h := sha512.New() + + for i := uint64(0); i < uint64(0xFFFF); i += uint64(batchSize) { + // fill results + for j := uint32(0); j < batchSize; j++ { + inU16 := uint16(i) + uint16(j) + f16 := float16.Float16(inU16) + results[j] = f16.Float32() + } + + // convert results to []byte + err := binary.Write(buf, binary.LittleEndian, results) + if err != nil { + panic(err) + } + + // update hash with []byte of results + _, err = h.Write(buf.Bytes()) + if err != nil { + panic(err) + } + + buf.Reset() + } + + // display hash digest in hex + digest := h.Sum(nil) + gotSHA512hex := hex.EncodeToString(digest) + if gotSHA512hex != wantSHA512 { + t.Errorf("Float16toFloat32: gotSHA512hex = %s", gotSHA512hex) + } + +} + +func TestFrombits(t *testing.T) { + x := uint16(0x1234) + f16 := float16.Frombits(x) + if uint16(f16) != f16.Bits() || uint16(f16) != x { + t.Errorf("float16.Frombits(0x7fff) returned %04x, wanted %04x", uint16(f16), x) + } +} + +func TestNaN(t *testing.T) { + nan := float16.NaN() + if !nan.IsNaN() { + t.Errorf("nan.IsNaN() returned false, wanted true") + } +} + +func TestInf(t *testing.T) { + posInf := float16.Inf(0) + if uint16(posInf) != 0x7c00 { + t.Errorf("float16.Inf(0) returned %04x, wanted %04x", uint16(posInf), 0x7c00) + } + + posInf = float16.Inf(1) + if uint16(posInf) != 0x7c00 { + t.Errorf("float16.Inf(1) returned %04x, wanted %04x", uint16(posInf), 0x7c00) + } + + negInf := float16.Inf(-1) + if uint16(negInf) != 0xfc00 { + t.Errorf("float16.Inf(-1) returned %04x, wanted %04x", uint16(negInf), 0xfc00) + } +} + +func TestBits(t *testing.T) { + x := uint16(0x1234) + f16 := float16.Frombits(x) + if uint16(f16) != f16.Bits() || f16.Bits() != x { + t.Errorf("Bits() returned %04x, wanted %04x", uint16(f16), x) + } +} + +func TestIsFinite(t *testing.T) { + // IsFinite returns true if f is neither infinite nor NaN. + + finite := float16.Fromfloat32(float32(1.5)) + if !finite.IsFinite() { + t.Errorf("finite.Infinite() returned false, wanted true") + } + + posInf := float16.Inf(0) + if posInf.IsFinite() { + t.Errorf("posInf.Infinite() returned true, wanted false") + } + + negInf := float16.Inf(-1) + if negInf.IsFinite() { + t.Errorf("negInf.Infinite() returned true, wanted false") + } + + nan := float16.NaN() + if nan.IsFinite() { + t.Errorf("nan.Infinite() returned true, wanted false") + } +} + +func TestIsNaN(t *testing.T) { + + f16 := float16.Float16(0) + if f16.IsNaN() { + t.Errorf("Float16(0).IsNaN() returned true, wanted false") + } + + f16 = float16.Float16(0x7e00) + if !f16.IsNaN() { + t.Errorf("Float16(0x7e00).IsNaN() returned false, wanted true") + } +} + +func TestIsQuietNaN(t *testing.T) { + + f16 := float16.Float16(0) + if f16.IsQuietNaN() { + t.Errorf("Float16(0).IsQuietNaN() returned true, wanted false") + } + + f16 = float16.Float16(0x7e00) + if !f16.IsQuietNaN() { + t.Errorf("Float16(0x7e00).IsQuietNaN() returned false, wanted true") + } + + f16 = float16.Float16(0x7e00 ^ 0x0200) + if f16.IsQuietNaN() { + t.Errorf("Float16(0x7e00 ^ 0x0200).IsQuietNaN() returned true, wanted false") + } +} + +func TestIsNormal(t *testing.T) { + // IsNormal returns true if f is neither zero, infinite, subnormal, or NaN. + + zero := float16.Frombits(0) + if zero.IsNormal() { + t.Errorf("zero.IsNormal() returned true, wanted false") + } + + posInf := float16.Inf(0) + if posInf.IsNormal() { + t.Errorf("posInf.IsNormal() returned true, wanted false") + } + + negInf := float16.Inf(-1) + if negInf.IsNormal() { + t.Errorf("negInf.IsNormal() returned true, wanted false") + } + + nan := float16.NaN() + if nan.IsNormal() { + t.Errorf("nan.IsNormal() returned true, wanted false") + } + + subnormal := float16.Frombits(0x0001) + if subnormal.IsNormal() { + t.Errorf("subnormal.IsNormal() returned true, wanted false") + } + + normal := float16.Fromfloat32(float32(1.5)) + if !normal.IsNormal() { + t.Errorf("normal.IsNormal() returned false, wanted true") + } + +} + +func TestSignbit(t *testing.T) { + + f16 := float16.Fromfloat32(float32(0.0)) + if f16.Signbit() { + t.Errorf("float16.Fromfloat32(float32(0)).Signbit() returned true, wanted false") + } + + f16 = float16.Fromfloat32(float32(2.0)) + if f16.Signbit() { + t.Errorf("float16.Fromfloat32(float32(2)).Signbit() returned true, wanted false") + } + + f16 = float16.Fromfloat32(float32(-2.0)) + if !f16.Signbit() { + t.Errorf("float16.Fromfloat32(float32(-2)).Signbit() returned false, wanted true") + } + +} + +func TestString(t *testing.T) { + f16 := float16.Fromfloat32(1.5) + s := f16.String() + if s != "1.5" { + t.Errorf("Float16(1.5).String() returned %s, wanted 1.5", s) + } + + f16 = float16.Fromfloat32(3.141593) + s = f16.String() + if s != "3.140625" { + t.Errorf("Float16(3.141593).String() returned %s, wanted 3.140625", s) + } + +} + +func TestIsInf(t *testing.T) { + + f16 := float16.Float16(0) + if f16.IsInf(0) { + t.Errorf("Float16(0).IsInf(0) returned true, wanted false") + } + + f16 = float16.Float16(0x7c00) + if !f16.IsInf(0) { + t.Errorf("Float16(0x7c00).IsInf(0) returned false, wanted true") + } + + f16 = float16.Float16(0x7c00) + if !f16.IsInf(1) { + t.Errorf("Float16(0x7c00).IsInf(1) returned false, wanted true") + } + + f16 = float16.Float16(0x7c00) + if f16.IsInf(-1) { + t.Errorf("Float16(0x7c00).IsInf(-1) returned true, wanted false") + } + + f16 = float16.Float16(0xfc00) + if !f16.IsInf(0) { + t.Errorf("Float16(0xfc00).IsInf(0) returned false, wanted true") + } + + f16 = float16.Float16(0xfc00) + if f16.IsInf(1) { + t.Errorf("Float16(0xfc00).IsInf(1) returned true, wanted false") + } + + f16 = float16.Float16(0xfc00) + if !f16.IsInf(-1) { + t.Errorf("Float16(0xfc00).IsInf(-1) returned false, wanted true") + } +} + +func float32parts(f32 float32) (exp int32, coef uint32, dropped uint32) { + const COEFMASK uint32 = 0x7fffff // 23 least significant bits + const EXPSHIFT uint32 = 23 + const EXPBIAS uint32 = 127 + const EXPMASK uint32 = uint32(0xff) << EXPSHIFT + const DROPMASK uint32 = COEFMASK >> 10 + u32 := math.Float32bits(f32) + exp = int32(((u32 & EXPMASK) >> EXPSHIFT) - EXPBIAS) + coef = u32 & COEFMASK + dropped = coef & DROPMASK + return exp, coef, dropped +} + +func isNaN32(f32 float32) bool { + exp, coef, _ := float32parts(f32) + return (exp == 128) && (coef != 0) +} + +func isQuietNaN32(f32 float32) bool { + exp, coef, _ := float32parts(f32) + return (exp == 128) && (coef != 0) && ((coef & 0x00400000) != 0) +} + +func checkFromNaN32ps(t *testing.T, f32 float32, f16 float16.Float16) { + + if !isNaN32(f32) { + return + } + + u32 := math.Float32bits(f32) + nan16, err := float16.FromNaN32ps(f32) + + if isQuietNaN32(f32) { + // result should be the same + if err != nil { + t.Errorf("FromNaN32ps: qnan = 0x%08x (%f) wanted err = nil, got err = %q", u32, f32, err) + } + if uint16(nan16) != uint16(f16) { + t.Errorf("FromNaN32ps: qnan = 0x%08x (%f) wanted nan16 = %v, got nan16 = %v", u32, f32, f16, nan16) + } + } else { + // result should differ only by the signaling/quiet bit unless payload is empty + if err != nil { + t.Errorf("FromNaN32ps: snan = 0x%08x (%f) wanted err = nil, got err = %q", u32, f32, err) + } + + coef := uint16(f16) & uint16(0x03ff) + payload := uint16(f16) & uint16(0x01ff) + diff := uint16(nan16 ^ f16) + + if payload == 0 { + // the lowest bit needed to be set to prevent turning sNaN into infinity, so 2 bits differ + if diff != 0x0201 { + t.Errorf("FromNaN32ps: snan = 0x%08x (%f) wanted diff == 0x0201, got 0x%04x", u32, f32, diff) + } + } else { + // only the quiet bit was restored, so 1 bit differs + if diff != 0x0200 { + t.Errorf("FromNaN32ps: snan = 0x%08x (%f) wanted diff == 0x0200, got 0x%04x. f16=0x%04x n16=0x%04x coef=0x%04x", u32, f32, diff, uint16(f16), uint16(nan16), coef) + } + } + } +} + +func checkPrecision(t *testing.T, f32 float32, f16 float16.Float16, i uint64) { + // TODO: rewrite this test when time allows + + u32 := math.Float32bits(f32) + u16 := f16.Bits() + f32bis := f16.Float32() + u32bis := math.Float32bits(f32bis) + pre := float16.PrecisionFromfloat32(f32) + roundtripped := u32 == u32bis + exp32, coef32, dropped32 := float32parts(f32) + + if roundtripped { + checkRoundTrippedPrecision(t, u32, u16, u32bis, exp32, coef32, dropped32) + return + } + + if pre == float16.PrecisionExact { + // this should only happen if both input and output are NaN + if !(f16.IsNaN() && isNaN32(f32)) { + t.Errorf("i=%d, PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionExact when roundtrip failed with non-special value", i, u32, f32, u16, u32bis, f32bis) + } + + } else if pre == float16.PrecisionUnknown { + if exp32 < -24 { + t.Errorf("i=%d, PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionUnknown, wanted PrecisionUnderflow", i, u32, f32, u16, u32bis, f32bis) + } + if dropped32 != 0 { + t.Errorf("i=%d, PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionUnknown, wanted PrecisionInexact", i, u32, f32, u16, u32bis, f32bis) + } + } else if pre == float16.PrecisionInexact { + checkPrecisionInexact(t, u32, u16, u32bis, exp32, coef32, dropped32) + } else if pre == float16.PrecisionUnderflow { + if exp32 >= -14 { + t.Errorf("i=%d, PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionUnderflow when exp32 is >= -14", i, u32, f32, u16, u32bis, f32bis) + } + } else if pre == float16.PrecisionOverflow { + if exp32 <= 15 { + t.Errorf("i=%d, PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionOverflow when exp32 is <= 15", i, u32, f32, u16, u32bis, f32bis) + } + } +} + +func checkPrecisionInexact(t *testing.T, u32 uint32, u16 uint16, u32bis uint32, exp32 int32, coef32 uint32, dropped32 uint32) { + f32 := math.Float32frombits(u32) + f32bis := math.Float32frombits(u32bis) + + if exp32 < -24 { + t.Errorf("PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionInexact, wanted PrecisionUnderflow", u32, f32, u16, u32bis, f32bis) + } + if exp32 > 15 { + t.Errorf("PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionInexact, wanted PrecisionOverflow", u32, f32, u16, u32bis, f32bis) + } + if coef32 == 0 { + t.Errorf("PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionInexact when coef32 is 0", u32, f32, u16, u32bis, f32bis) + } + if dropped32 == 0 { + t.Errorf("PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), got PrecisionInexact when dropped32 is 0", u32, f32, u16, u32bis, f32bis) + } +} + +func checkRoundTrippedPrecision(t *testing.T, u32 uint32, u16 uint16, u32bis uint32, exp32 int32, coef32 uint32, dropped32 uint32) { + f32 := math.Float32frombits(u32) + f32bis := math.Float32frombits(u32bis) + pre := float16.PrecisionFromfloat32(f32) + f16 := float16.Frombits(u16) + + if dropped32 != 0 { + t.Errorf("PrecisionFromfloat32 in f32bits=0x%08x (%f), out f16bits=0x%04x, back=0x%08x (%f), dropped32 != 0 with successful roundtrip", u32, f32, u16, u32bis, f32bis) + } + + if pre != float16.PrecisionExact { + // there are 2046 values that are subnormal and can round-trip float32->float16->float32 + if pre != float16.PrecisionUnknown { + t.Errorf("PrecisionFromfloat32 in f32bits=0x%08x (%032b) (%f), out f16bits=0x%04x (%v), back=0x%08x (%f), got %v, wanted PrecisionExact, exp=%d, coef=%d, drpd=%d", u32, u32, f32, u16, f16, u32bis, f32bis, pre, exp32, coef32, dropped32) + } + } + +} diff --git a/vendor/github.com/x448/float16/go.mod b/vendor/github.com/x448/float16/go.mod new file mode 100644 index 0000000..2074c3a --- /dev/null +++ b/vendor/github.com/x448/float16/go.mod @@ -0,0 +1,3 @@ +module github.com/x448/float16 + +go 1.11 diff --git a/vendor/github.com/ybbus/jsonrpc/LICENSE b/vendor/github.com/ybbus/jsonrpc/LICENSE index bc53bd7..6e3b3a6 100644 --- a/vendor/github.com/ybbus/jsonrpc/LICENSE +++ b/vendor/github.com/ybbus/jsonrpc/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2016 Alexander Gehres +Copyright (c) 2019 Alexander Gehres Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/vendor/github.com/ybbus/jsonrpc/README.md b/vendor/github.com/ybbus/jsonrpc/README.md index 6b5d660..955b7b7 100644 --- a/vendor/github.com/ybbus/jsonrpc/README.md +++ b/vendor/github.com/ybbus/jsonrpc/README.md @@ -1,6 +1,7 @@ [![Go Report Card](https://goreportcard.com/badge/github.com/ybbus/jsonrpc)](https://goreportcard.com/report/github.com/ybbus/jsonrpc) [![GoDoc](https://godoc.org/github.com/ybbus/jsonrpc?status.svg)](https://godoc.org/github.com/ybbus/jsonrpc) [![GitHub license](https://img.shields.io/github/license/mashape/apistatus.svg)]() +[![Mentioned in Awesome Go](https://awesome.re/mentioned-badge.svg)](https://github.com/avelino/awesome-go) # JSON-RPC 2.0 Client for golang A go implementation of an rpc client using json as data format over http. @@ -8,45 +9,43 @@ The implementation is based on the JSON-RPC 2.0 specification: http://www.jsonrp Supports: - requests with arbitrary parameters -- requests with named parameters -- notifications -- batch requests - convenient response retrieval -- basic authentication -- custom headers -- custom http client +- batch requests +- custom http client (e.g. proxy, tls config) +- custom headers (e.g. basic auth) ## Installation ```sh -go get -u github.com/ybbus/jsonrpc +go get -u github.com/ybbus/jsonrpc/v2 ``` ## Getting started -Let's say we want to retrieve a person with a specific id using rpc-json over http. -Then we want to save this person with new properties. -We have to provide basic authentication credentials. +Let's say we want to retrieve a person struct with a specific id using rpc-json over http. +Then we want to save this person after we changed a property. (Error handling is omitted here) ```go +package main + +import "github.com/ybbus/jsonrpc/v2" + type Person struct { - Id int `json:"id"` + ID int `json:"id"` Name string `json:"name"` - Age int `json:"age"` + Age int `json:"age"` } func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - rpcClient.SetBasicAuth("alex", "secret") + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("getPersonById", 123) - - person := Person{} - response.GetObject(&person) + var person *Person + rpcClient.CallFor(&person, "getPersonById", 4711) person.Age = 33 rpcClient.Call("updatePerson", person) } + ``` ## In detail @@ -60,9 +59,9 @@ This calls generate and send a valid rpc-json object. (see: http://www.jsonrpc.o ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("getDate") - // generates body: {"jsonrpc":"2.0","method":"getDate","id":0} + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + rpcClient.Call("getDate") + // generates body: {"method":"getDate","id":0,"jsonrpc":"2.0"} } ``` @@ -70,9 +69,9 @@ Call a function with parameter: ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("addNumbers", 1, 2) - // generates body: {"jsonrpc":"2.0","method":"addNumbers","params":[1,2],"id":0} + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + rpcClient.Call("addNumbers", 1, 2) + // generates body: {"method":"addNumbers","params":[1,2],"id":0,"jsonrpc":"2.0"} } ``` @@ -80,28 +79,9 @@ Call a function with arbitrary parameters: ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("createPerson", "Alex", 33, "Germany") - // generates body: {"jsonrpc":"2.0","method":"createPerson","params":["Alex",33,"Germany"],"id":0} -} -``` - -Call a function with named parameters: - -```go -func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - rpcClient.CallNamed("createPerson", map[string]interface{}{ - "name": "Bartholomew Allen", - "nicknames": []string{"Barry", "Flash",}, - "male": true, - "age": 28, - "address": map[string]interface{}{"street": "Main Street", "city": "Central City"}, - }) - // generates body: {"jsonrpc":"2.0","method":"createPerson","params": - // {"name": "Bartholomew Allen", "nicknames": ["Barry", "Flash"], "male": true, "age": 28, - // "address": {"street": "Main Street", "city": "Central City"}} - // ,"id":0} + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + rpcClient.Call("createPerson", "Alex", 33, "Germany") + // generates body: {"method":"createPerson","params":["Alex",33,"Germany"],"id":0,"jsonrpc":"2.0"} } ``` @@ -114,9 +94,9 @@ type Person struct { Country string `json:"country"` } func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("createPerson", Person{"Alex", 33, "Germany"}) - // generates body: {"jsonrpc":"2.0","method":"createPerson","params":[{"name":"Alex","age":33,"country":"Germany"}],"id":0} + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + rpcClient.Call("createPerson", &Person{"Alex", 33, "Germany"}) + // generates body: {"jsonrpc":"2.0","method":"createPerson","params":{"name":"Alex","age":33,"country":"Germany"},"id":0} } ``` @@ -129,103 +109,131 @@ type Person struct { Country string `json:"country"` } func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("createPersonsWithRole", []Person{{"Alex", 33, "Germany"}, {"Barney", 38, "Germany"}}, []string{"Admin", "User"}) - // generates body: {"jsonrpc":"2.0","method":"createPersonsWithRole","params":[[{"name":"Alex","age":33,"country":"Germany"},{"name":"Barney","age":38,"country":"Germany"}],["Admin","User"]],"id":0} + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + rpcClient.Call("createPersonsWithRole", &Person{"Alex", 33, "Germany"}, &Person{"Barney", 38, "Germany"}, []string{"Admin", "User"}) + // generates body: {"jsonrpc":"2.0","method":"createPersonsWithRole","params":[{"name":"Alex","age":33,"country":"Germany"},{"name":"Barney","age":38,"country":"Germany"},["Admin","User"]],"id":0} } ``` -### Notification - -A jsonrpc notification is a rpc call to the server without expecting a response. -Only an error object is returned in case of networkt / http error. -No id field is set in the request json object. (see: http://www.jsonrpc.org/specification#notification) - -Execute an simple notification: +Some examples and resulting JSON-RPC objects: ```go -func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - err := rpcClient.Notification("disconnectClient", 123) - if err != nil { - //error handling goes here - } -} -``` +rpcClient.Call("missingParam") +{"method":"missingParam"} -### Batch rpcjson calls +rpcClient.Call("nullParam", nil) +{"method":"nullParam","params":[null]} -A jsonrpc batch call encapsulates multiple json-rpc requests in a single rpc-service call. -It returns an array of results (for all non-notification requests). -(see: http://www.jsonrpc.org/specification#batch) +rpcClient.Call("boolParam", true) +{"method":"boolParam","params":[true]} -Execute two jsonrpc calls and a single notification as batch: +rpcClient.Call("boolParams", true, false, true) +{"method":"boolParams","params":[true,false,true]} -```go -func main() { - rpcClient := jsonrpc.NewRPCClient(httpServer.URL) +rpcClient.Call("stringParam", "Alex") +{"method":"stringParam","params":["Alex"]} - req1 := rpcClient.NewRPCRequestObject("addNumbers", 1, 2) - req2 := rpcClient.NewRPCRequestObject("getPersonByName", "alex") - notify1 := rpcClient.NewRPCNotificationObject("disconnect", true) +rpcClient.Call("stringParams", "JSON", "RPC") +{"method":"stringParams","params":["JSON","RPC"]} - responses, _ := rpcClient.Batch(req1, req2, notify1) +rpcClient.Call("numberParam", 123) +{"method":"numberParam","params":[123]} - person := Person{} - response2, _ := responses.GetResponseOf(req2) - response2.GetObject(&person) -} -``` +rpcClient.Call("numberParams", 123, 321) +{"method":"numberParams","params":[123,321]} -To update the ID of an existing rpcRequest object: -```go -func main() { - rpcClient := jsonrpc.NewRPCClient(httpServer.URL) +rpcClient.Call("floatParam", 1.23) +{"method":"floatParam","params":[1.23]} - req1 := rpcClient.NewRPCRequestObject("addNumbers", 1, 2) - req2 := rpcClient.NewRPCRequestObject("getPersonByName", "alex") - notify1 := rpcClient.NewRPCNotifyObject("disconnect", true) +rpcClient.Call("floatParams", 1.23, 3.21) +{"method":"floatParams","params":[1.23,3.21]} - responses, _ := rpcClient.Batch(req1, req2, notify1) +rpcClient.Call("manyParams", "Alex", 35, true, nil, 2.34) +{"method":"manyParams","params":["Alex",35,true,null,2.34]} - rpcClient.UpdateRequestID(req1) // updates id to the next valid id if autoincrement is enabled -} +rpcClient.Call("singlePointerToStruct", &person) +{"method":"singlePointerToStruct","params":{"name":"Alex","age":35,"country":"Germany"}} + +rpcClient.Call("multipleStructs", &person, &drink) +{"method":"multipleStructs","params":[{"name":"Alex","age":35,"country":"Germany"},{"name":"Cuba Libre","ingredients":["rum","cola"]}]} + +rpcClient.Call("singleStructInArray", []*Person{&person}) +{"method":"singleStructInArray","params":[{"name":"Alex","age":35,"country":"Germany"}]} + +rpcClient.Call("namedParameters", map[string]interface{}{ + "name": "Alex", + "age": 35, +}) +{"method":"namedParameters","params":{"age":35,"name":"Alex"}} + +rpcClient.Call("anonymousStruct", struct { + Name string `json:"name"` + Age int `json:"age"` +}{"Alex", 33}) +{"method":"anonymousStructWithTags","params":{"name":"Alex","age":33}} + +rpcClient.Call("structWithNullField", struct { + Name string `json:"name"` + Address *string `json:"address"` +}{"Alex", nil}) +{"method":"structWithNullField","params":{"name":"Alex","address":null}} ``` ### Working with rpc-json responses -Before working with the response object, make sure to check err != nil first. -This error indicates problems on the network / http level of an error when parsing the json response. +Before working with the response object, make sure to check err != nil. +Also keep in mind that the json-rpc result field can be nil even on success. ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") response, err := rpcClient.Call("addNumbers", 1, 2) if err != nil { - //error handling goes here + // error handling goes here e.g. network / http error } } ``` -The next thing you have to check is if an rpc-json protocol error occoured. This is done by checking if the Error field in the rpc-response != nil: +If an http error occurred, maybe you are interested in the error code (403 etc.) +```go +func main() { + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + response, err := rpcClient.Call("addNumbers", 1, 2) + + switch e := err.(type) { + case nil: // if error is nil, do nothing + case *HTTPError: + // use e.Code here + return + default: + // any other error + return + } + + // no error, go on... +} +``` + +The next thing you have to check is if an rpc-json protocol error occurred. This is done by checking if the Error field in the rpc-response != nil: (see: http://www.jsonrpc.org/specification#error_object) ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") response, err := rpcClient.Call("addNumbers", 1, 2) if err != nil { //error handling goes here } if response.Error != nil { - // check response.Error.Code, response.Error.Message, response.Error.Data here + // rpc error handling goes here + // check response.Error.Code, response.Error.Message and optional response.Error.Data } } ``` -After making sure that no errors occoured you can now examine the RPCResponse object. +After making sure that no errors occurred you can now examine the RPCResponse object. When executing a json-rpc request, most of the time you will be interested in the "result"-property of the returned json-rpc response object. (see: http://www.jsonrpc.org/specification#response_object) The library provides some helper functions to retrieve the result in the data format you are interested in. @@ -233,18 +241,17 @@ Again: check for err != nil here to be sure the expected type was provided in th ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") response, _ := rpcClient.Call("addNumbers", 1, 2) result, err := response.GetInt() if err != nil { - // result seems not to be an integer value + // result cannot be unmarshalled as integer } // helpers provided for all primitive types: - response.GetInt() // int32 or int64 depends on architecture / implementation - response.GetInt64() - response.GetFloat64() + response.GetInt() + response.GetFloat() response.GetString() response.GetBool() } @@ -261,68 +268,190 @@ type Person struct { } func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") response, _ := rpcClient.Call("getPersonById", 123) - person := Person{} - err := response.GetObject(&Person) // expects a rpc-object result value like: {"id": 123, "name": "alex", "age": 33} + var person *Person + err := response.GetObject(&person) // expects a rpc-object result value like: {"id": 123, "name": "alex", "age": 33} + if err != nil || person == nil { + // some error on json unmarshal level or json result field was null + } + + fmt.Println(person.Name) + + // we can also set default values if they are missing from the result, or result == null: + person2 := &Person{ + Id: 0, + Name: "", + Age: -1, + } + err := response.GetObject(&person2) // expects a rpc-object result value like: {"id": 123, "name": "alex", "age": 33} + if err != nil || person2 == nil { + // some error on json unmarshal level or json result field was null + } + + fmt.Println(person2.Name) // prints "" if "name" field was missing in result-json +} +``` + +Retrieving arrays: + +```go +func main() { + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + response, _ := rpcClient.Call("getRandomNumbers", 10) + + rndNumbers := []int{} + err := response.GetObject(&rndNumbers) // expects a rpc-object result value like: [10, 188, 14, 3] + if err != nil { + // do error handling + } + + for _, num := range rndNumbers { + fmt.Printf("%v\n", num) + } +} +``` + +### Using convenient function CallFor() +A very handy way to quickly invoke methods and retrieve results is by using CallFor() + +You can directly provide an object where the result should be stored. Be sure to provide it be reference. +An error is returned if: +- there was an network / http error +- RPCError object is not nil (err can be casted to this object) +- rpc result could not be parsed into provided object + +One of te above examples could look like this: + +```go +// json annotations are only required to transform the structure back to json +type Person struct { + Id int `json:"id"` + Name string `json:"name"` + Age int `json:"age"` +} + +func main() { + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + + var person *Person + err := rpcClient.CallFor(&person, "getPersonById", 123) + + if err != nil || person == nil { + // handle error + } fmt.Println(person.Name) } ``` -Retrieving arrays e.g. of ints: +Most of the time it is ok to check if a struct field is 0, empty string "" etc. to check if it was provided by the json rpc response. +But if you want to be sure that a JSON-RPC response field was missing or not, you should use pointers to the fields. +This is just a single example since all this Unmarshaling is standard go json functionality, exactly as if you would call json.Unmarshal(rpcResponse.ResultAsByteArray, &objectToStoreResult) + +``` +type Person struct { + Id *int `json:"id"` + Name *string `json:"name"` + Age *int `json:"age"` +} -```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("getRandomNumbers", 10) + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") - rndNumbers := []int{} - err := response.getObject(&rndNumbers) // expects a rpc-object result value like: [10, 188, 14, 3] + var person *Person + err := rpcClient.CallFor(&person, "getPersonById", 123) - fmt.Println(rndNumbers[0]) + if err != nil || person == nil { + // handle error + } + + if person.Name == nil { + // json rpc response did not provide a field "name" in the result object + } } ``` -### Basic authentication +### Using RPC Batch Requests -If the rpc-service is running behind a basic authentication you can easily set the credentials: +You can send multiple RPC-Requests in one single HTTP request using RPC Batch Requests. + +``` +func main() { + rpcClient := jsonrpc.NewClient("http://my-rpc-service:8080/rpc") + + response, _ := rpcClient.CallBatch(RPCRequests{ + NewRequest("myMethod1", 1, 2, 3), + NewRequest("anotherMethod", "Alex", 35, true), + NewRequest("myMethod2", &Person{ + Name: "Emmy", + Age: 4, + }), + }) +} +``` + +Keep the following in mind: +- the request / response id's are important to map the requests to the responses. CallBatch() automatically sets the ids to requests[i].ID == i +- the response can be provided in an unordered and maybe incomplete form +- when you want to set the id yourself use, CallRaw() + +There are some helper methods for batch request results: +``` +func main() { + // [...] + + result.HasErrors() // returns true if one of the rpc response objects has Error field != nil + resultMap := result.AsMap() // returns a map for easier retrieval of requests + + if response123, ok := resultMap[123]; ok { + // response object with id 123 exists, use it here + // response123.ID == 123 + response123.GetObjectAs(&person) + // ... + } + +} +``` + +### Raw functions +There are also Raw function calls. Consider the non Raw functions first, unless you know what you are doing. +You can create invalid json rpc requests and have to take care of id's etc. yourself. +Also check documentation of Params() for raw requests. + +### Custom Headers, Basic authentication + +If the rpc-service is running behind a basic authentication you can easily set the Authorization header: ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - rpcClient.SetBasicAuth("alex", "secret") + rpcClient := jsonrpc.NewClientWithOpts("http://my-rpc-service:8080/rpc", &jsonrpc.RPCClientOpts{ + CustomHeaders: map[string]string{ + "Authorization": "Basic " + base64.StdEncoding.EncodeToString([]byte("myUser"+":"+"mySecret")), + }, + }) response, _ := rpcClient.Call("addNumbers", 1, 2) // send with Authorization-Header } ``` -### Set custom headers +### Using oauth -Setting some custom headers (e.g. when using another authentication) is simple: -```go -func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - rpcClient.SetCustomHeader("Authorization", "Bearer abcd1234") - response, _ := rpcClient.Call("addNumbers", 1, 2) // send with a custom Auth-Header -} -``` - -### ID auto-increment - -Per default the ID of the json-rpc request increments automatically for each request. -You can change this behaviour: +Using oauth is also easy, e.g. with clientID and clientSecret authentication ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - response, _ := rpcClient.Call("addNumbers", 1, 2) // send with ID == 0 - response, _ = rpcClient.Call("addNumbers", 1, 2) // send with ID == 1 - rpcClient.SetNextID(10) - response, _ = rpcClient.Call("addNumbers", 1, 2) // send with ID == 10 - rpcClient.SetAutoIncrementID(false) - response, _ = rpcClient.Call("addNumbers", 1, 2) // send with ID == 11 - response, _ = rpcClient.Call("addNumbers", 1, 2) // send with ID == 11 + credentials := clientcredentials.Config{ + ClientID: "myID", + ClientSecret: "mySecret", + TokenURL: "http://mytokenurl", + } + + rpcClient := jsonrpc.NewClientWithOpts("http://my-rpc-service:8080/rpc", &jsonrpc.RPCClientOpts{ + HTTPClient: credentials.Client(context.Background()), + }) + + // requests now retrieve and use an oauth token } ``` @@ -333,15 +462,17 @@ For example to use a proxy when executing json-rpc calls: ```go func main() { - rpcClient := jsonrpc.NewRPCClient("http://my-rpc-service:8080/rpc") - - proxyURL, _ := url.Parse("http://proxy:8080") + proxyURL, _ := url.Parse("http://proxy:8080") transport := &http.Transport{Proxy: http.ProxyURL(proxyURL)} httpClient := &http.Client{ Transport: transport, } - rpcClient.SetHTTPClient(httpClient) + rpcClient := jsonrpc.NewClientWithOpts("http://my-rpc-service:8080/rpc", &jsonrpc.RPCClientOpts{ + HTTPClient: httpClient, + }) + + // requests now use proxy } ``` diff --git a/vendor/github.com/ybbus/jsonrpc/examples_test.go b/vendor/github.com/ybbus/jsonrpc/examples_test.go deleted file mode 100644 index 41a3b22..0000000 --- a/vendor/github.com/ybbus/jsonrpc/examples_test.go +++ /dev/null @@ -1,116 +0,0 @@ -package jsonrpc - -import ( - "fmt" -) - -func Example() { - type Person struct { - Name string `json:"name"` - Age int `json:"age"` - Country string `json:"country"` - } - - // create client - rpcClient := NewRPCClient("http://my-rpc-service") - - // execute rpc to service - response, _ := rpcClient.Call("getPersonByID", 12345) - - // parse result into struct - var person Person - response.GetObject(&person) - - // change result and send back using rpc - person.Age = 35 - rpcClient.Call("setPersonByID", 12345, person) -} - -func ExampleRPCClient_Call() { - rpcClient := NewRPCClient("http://my-rpc-service") - - // result processing omitted, see: RPCResponse methods - rpcClient.Call("getTimestamp") - - rpcClient.Call("getPerson", 1234) - - rpcClient.Call("addNumbers", 5, 2, 3) - - rpcClient.Call("strangeFunction", 1, true, "alex", 3.4) - - type Person struct { - Name string `json:"name"` - Age int `json:"age"` - Country string `json:"country"` - } - - person := Person{ - Name: "alex", - Age: 33, - Country: "germany", - } - - rpcClient.Call("setPersonByID", 123, person) -} - -func ExampleRPCClient_CallNamed() { - rpcClient := NewRPCClient("http://my-rpc-service") - - // result processing omitted, see: RPCResponse methods - rpcClient.CallNamed("createPerson", map[string]interface{}{ - "name": "Bartholomew Allen", - "nicknames": []string{"Barry", "Flash"}, - "male": true, - "age": 28, - "address": map[string]interface{}{"street": "Main Street", "city": "Central City"}, - }) -} - -func ExampleRPCResponse() { - rpcClient := NewRPCClient("http://my-rpc-service") - - response, _ := rpcClient.Call("addNumbers", 1, 2, 3) - sum, _ := response.GetInt() - fmt.Println(sum) - - response, _ = rpcClient.Call("isValidEmail", "my@ema.il") - valid, _ := response.GetBool() - fmt.Println(valid) - - response, _ = rpcClient.Call("getJoke") - joke, _ := response.GetString() - fmt.Println(joke) - - response, _ = rpcClient.Call("getPi", 10) - piRounded, _ := response.GetFloat64() - fmt.Println(piRounded) - - var rndNumbers []int - response, _ = rpcClient.Call("getRndIntNumbers", 10) - response.GetObject(&rndNumbers) - fmt.Println(rndNumbers[0]) - - type Person struct { - Name string `json:"name"` - Age int `json:"age"` - Country string `json:"country"` - } - - var p Person - response, _ = rpcClient.Call("getPersonByID", 1234) - response.GetObject(&p) - fmt.Println(p.Name) -} - -func ExampleRPCClient_Batch() { - rpcClient := NewRPCClient(httpServer.URL) - - req1 := rpcClient.NewRPCRequestObject("addNumbers", 1, 2, 3) - req2 := rpcClient.NewRPCRequestObject("getTimestamp") - responses, _ := rpcClient.Batch(req1, req2) - - response, _ := responses.GetResponseOf(req2) - timestamp, _ := response.GetInt() - - fmt.Println(timestamp) -} diff --git a/vendor/github.com/ybbus/jsonrpc/go.mod b/vendor/github.com/ybbus/jsonrpc/go.mod new file mode 100644 index 0000000..6e2dcc4 --- /dev/null +++ b/vendor/github.com/ybbus/jsonrpc/go.mod @@ -0,0 +1,5 @@ +module github.com/ybbus/jsonrpc/v2 + +go 1.12 + +require github.com/onsi/gomega v1.5.0 diff --git a/vendor/github.com/ybbus/jsonrpc/go.sum b/vendor/github.com/ybbus/jsonrpc/go.sum new file mode 100644 index 0000000..3a549a2 --- /dev/null +++ b/vendor/github.com/ybbus/jsonrpc/go.sum @@ -0,0 +1,13 @@ +github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= +github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= +github.com/onsi/gomega v1.5.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= +golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= +gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= +gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= diff --git a/vendor/github.com/ybbus/jsonrpc/jsonrpc.go b/vendor/github.com/ybbus/jsonrpc/jsonrpc.go index 03dd81d..a1da0f3 100644 --- a/vendor/github.com/ybbus/jsonrpc/jsonrpc.go +++ b/vendor/github.com/ybbus/jsonrpc/jsonrpc.go @@ -1,389 +1,556 @@ -// Package jsonrpc provides an jsonrpc 2.0 client that sends jsonrpc requests and receives jsonrpc responses using http. +// Package jsonrpc provides a JSON-RPC 2.0 client that sends JSON-RPC requests and receives JSON-RPC responses using HTTP. package jsonrpc import ( "bytes" - "encoding/base64" "encoding/json" "errors" "fmt" "net/http" + "reflect" "strconv" - "sync" ) -// RPCRequest represents a jsonrpc request object. +const ( + jsonrpcVersion = "2.0" +) + +// RPCClient sends JSON-RPC requests over HTTP to the provided JSON-RPC backend. +// +// RPCClient is created using the factory function NewClient(). +type RPCClient interface { + // Call is used to send a JSON-RPC request to the server endpoint. + // + // The spec states, that params can only be an array or an object, no primitive values. + // So there are a few simple rules to notice: + // + // 1. no params: params field is omitted. e.g. Call("getinfo") + // + // 2. single params primitive value: value is wrapped in array. e.g. Call("getByID", 1423) + // + // 3. single params value array or object: value is unchanged. e.g. Call("storePerson", &Person{Name: "Alex"}) + // + // 4. multiple params values: always wrapped in array. e.g. Call("setDetails", "Alex, 35, "Germany", true) + // + // Examples: + // Call("getinfo") -> {"method": "getinfo"} + // Call("getPersonId", 123) -> {"method": "getPersonId", "params": [123]} + // Call("setName", "Alex") -> {"method": "setName", "params": ["Alex"]} + // Call("setMale", true) -> {"method": "setMale", "params": [true]} + // Call("setNumbers", []int{1, 2, 3}) -> {"method": "setNumbers", "params": [1, 2, 3]} + // Call("setNumbers", 1, 2, 3) -> {"method": "setNumbers", "params": [1, 2, 3]} + // Call("savePerson", &Person{Name: "Alex", Age: 35}) -> {"method": "savePerson", "params": {"name": "Alex", "age": 35}} + // Call("setPersonDetails", "Alex", 35, "Germany") -> {"method": "setPersonDetails", "params": ["Alex", 35, "Germany"}} + // + // for more information, see the examples or the unit tests + Call(method string, params ...interface{}) (*RPCResponse, error) + + // CallRaw is like Call() but without magic in the requests.Params field. + // The RPCRequest object is sent exactly as you provide it. + // See docs: NewRequest, RPCRequest, Params() + // + // It is recommended to first consider Call() and CallFor() + CallRaw(request *RPCRequest) (*RPCResponse, error) + + // CallFor is a very handy function to send a JSON-RPC request to the server endpoint + // and directly specify an object to store the response. + // + // out: will store the unmarshaled object, if request was successful. + // should always be provided by references. can be nil even on success. + // the behaviour is the same as expected from json.Unmarshal() + // + // method and params: see Call() function + // + // if the request was not successful (network, http error) or the rpc response returns an error, + // an error is returned. if it was an JSON-RPC error it can be casted + // to *RPCError. + // + CallFor(out interface{}, method string, params ...interface{}) error + + // CallBatch invokes a list of RPCRequests in a single batch request. + // + // Most convenient is to use the following form: + // CallBatch(RPCRequests{ + // NewRequest("myMethod1", 1, 2, 3), + // NewRequest("myMethod2", "Test"), + // }) + // + // You can create the []*RPCRequest array yourself, but it is not recommended and you should notice the following: + // - field Params is sent as provided, so Params: 2 forms an invalid json (correct would be Params: []int{2}) + // - you can use the helper function Params(1, 2, 3) to use the same format as in Call() + // - field JSONRPC is overwritten and set to value: "2.0" + // - field ID is overwritten and set incrementally and maps to the array position (e.g. requests[5].ID == 5) + // + // + // Returns RPCResponses that is of type []*RPCResponse + // - note that a list of RPCResponses can be received unordered so it can happen that: responses[i] != responses[i].ID + // - RPCPersponses is enriched with helper functions e.g.: responses.HasError() returns true if one of the responses holds an RPCError + CallBatch(requests RPCRequests) (RPCResponses, error) + + // CallBatchRaw invokes a list of RPCRequests in a single batch request. + // It sends the RPCRequests parameter is it passed (no magic, no id autoincrement). + // + // Consider to use CallBatch() instead except you have some good reason not to. + // + // CallBatchRaw(RPCRequests{ + // &RPCRequest{ + // ID: 123, // this won't be replaced in CallBatchRaw + // JSONRPC: "wrong", // this won't be replaced in CallBatchRaw + // Method: "myMethod1", + // Params: []int{1}, // there is no magic, be sure to only use array or object + // }, + // &RPCRequest{ + // ID: 612, + // JSONRPC: "2.0", + // Method: "myMethod2", + // Params: Params("Alex", 35, true), // you can use helper function Params() (see doc) + // }, + // }) + // + // Returns RPCResponses that is of type []*RPCResponse + // - note that a list of RPCResponses can be received unordered + // - the id's must be mapped against the id's you provided + // - RPCPersponses is enriched with helper functions e.g.: responses.HasError() returns true if one of the responses holds an RPCError + CallBatchRaw(requests RPCRequests) (RPCResponses, error) +} + +// RPCRequest represents a JSON-RPC request object. +// +// Method: string containing the method to be invoked +// +// Params: can be nil. if not must be an json array or object +// +// ID: may always set to 1 for single requests. Should be unique for every request in one batch request. +// +// JSONRPC: must always be set to "2.0" for JSON-RPC version 2.0 // // See: http://www.jsonrpc.org/specification#request_object -type RPCRequest struct { - JSONRPC string `json:"jsonrpc"` - Method string `json:"method"` - Params interface{} `json:"params,omitempty"` - ID uint `json:"id"` -} - -// RPCNotification represents a jsonrpc notification object. -// A notification object omits the id field since there will be no server response. // -// See: http://www.jsonrpc.org/specification#notification -type RPCNotification struct { - JSONRPC string `json:"jsonrpc"` +// Most of the time you shouldn't create the RPCRequest object yourself. +// The following functions do that for you: +// Call(), CallFor(), NewRequest() +// +// If you want to create it yourself (e.g. in batch or CallRaw()), consider using Params(). +// Params() is a helper function that uses the same parameter syntax as Call(). +// +// e.g. to manually create an RPCRequest object: +// request := &RPCRequest{ +// Method: "myMethod", +// Params: Params("Alex", 35, true), +// } +// +// If you know what you are doing you can omit the Params() call to avoid some reflection but potentially create incorrect rpc requests: +//request := &RPCRequest{ +// Method: "myMethod", +// Params: 2, <-- invalid since a single primitive value must be wrapped in an array --> no magic without Params() +// } +// +// correct: +// request := &RPCRequest{ +// Method: "myMethod", +// Params: []int{2}, <-- invalid since a single primitive value must be wrapped in an array +// } +type RPCRequest struct { Method string `json:"method"` Params interface{} `json:"params,omitempty"` + ID int `json:"id"` + JSONRPC string `json:"jsonrpc"` } -// RPCResponse represents a jsonrpc response object. -// If no rpc specific error occurred Error field is nil. +// NewRequest returns a new RPCRequest that can be created using the same convenient parameter syntax as Call() +// +// e.g. NewRequest("myMethod", "Alex", 35, true) +func NewRequest(method string, params ...interface{}) *RPCRequest { + request := &RPCRequest{ + Method: method, + Params: Params(params...), + JSONRPC: jsonrpcVersion, + } + + return request +} + +// RPCResponse represents a JSON-RPC response object. +// +// Result: holds the result of the rpc call if no error occurred, nil otherwise. can be nil even on success. +// +// Error: holds an RPCError object if an error occurred. must be nil on success. +// +// ID: may always be 0 for single requests. is unique for each request in a batch call (see CallBatch()) +// +// JSONRPC: must always be set to "2.0" for JSON-RPC version 2.0 // // See: http://www.jsonrpc.org/specification#response_object type RPCResponse struct { JSONRPC string `json:"jsonrpc"` Result interface{} `json:"result,omitempty"` Error *RPCError `json:"error,omitempty"` - ID uint `json:"id"` + ID int `json:"id"` } -// BatchResponse a list of jsonrpc response objects as a result of a batch request +// RPCError represents a JSON-RPC error object if an RPC error occurred. // -// if you are interested in the response of a specific request use: GetResponseOf(request) -type BatchResponse struct { - rpcResponses []RPCResponse -} - -// RPCError represents a jsonrpc error object if an rpc error occurred. +// Code: holds the error code +// +// Message: holds a short error message +// +// Data: holds additional error data, may be nil // // See: http://www.jsonrpc.org/specification#error_object type RPCError struct { Code int `json:"code"` Message string `json:"message"` - Data interface{} `json:"data"` + Data interface{} `json:"data,omitempty"` } +// Error function is provided to be used as error object. func (e *RPCError) Error() string { - return strconv.Itoa(e.Code) + ": " + e.Message + return strconv.Itoa(e.Code) + ":" + e.Message } -// RPCClient sends jsonrpc requests over http to the provided rpc backend. -// RPCClient is created using the factory function NewRPCClient(). -type RPCClient struct { - endpoint string - httpClient *http.Client - customHeaders map[string]string - autoIncrementID bool - nextID uint - idMutex sync.Mutex -} - -// NewRPCClient returns a new RPCClient instance with default configuration (no custom headers, default http.Client, autoincrement ids). -// Endpoint is the rpc-service url to which the rpc requests are sent. -func NewRPCClient(endpoint string) *RPCClient { - return &RPCClient{ - endpoint: endpoint, - httpClient: http.DefaultClient, - autoIncrementID: true, - nextID: 0, - customHeaders: make(map[string]string), - } -} - -// NewRPCRequestObject creates and returns a raw RPCRequest structure. -// It is mainly used when building batch requests. For single requests use RPCClient.Call(). -// RPCRequest struct can also be created directly, but this function sets the ID and the jsonrpc field to the correct values. -func (client *RPCClient) NewRPCRequestObject(method string, params ...interface{}) *RPCRequest { - client.idMutex.Lock() - rpcRequest := RPCRequest{ - ID: client.nextID, - JSONRPC: "2.0", - Method: method, - Params: params, - } - if client.autoIncrementID == true { - client.nextID++ - } - client.idMutex.Unlock() - - if len(params) == 0 { - rpcRequest.Params = nil - } - - return &rpcRequest -} - -// NewRPCNotificationObject creates and returns a raw RPCNotification structure. -// It is mainly used when building batch requests. For single notifications use RPCClient.Notification(). -// NewRPCNotificationObject struct can also be created directly, but this function sets the ID and the jsonrpc field to the correct values. -func (client *RPCClient) NewRPCNotificationObject(method string, params ...interface{}) *RPCNotification { - rpcNotification := RPCNotification{ - JSONRPC: "2.0", - Method: method, - Params: params, - } - - if len(params) == 0 { - rpcNotification.Params = nil - } - - return &rpcNotification -} - -// Call sends an jsonrpc request over http to the rpc-service url that was provided on client creation. +// HTTPError represents a error that occurred on HTTP level. // -// If something went wrong on the network / http level or if json parsing failed it returns an error. +// An error of type HTTPError is returned when a HTTP error occurred (status code) +// and the body could not be parsed to a valid RPCResponse object that holds a RPCError. // -// If something went wrong on the rpc-service / protocol level the Error field of the returned RPCResponse is set -// and contains information about the error. -// -// If the request was successful the Error field is nil and the Result field of the RPCRespnse struct contains the rpc result. -func (client *RPCClient) Call(method string, params ...interface{}) (*RPCResponse, error) { - // Ensure that params are nil and will be omitted from JSON if not specified. - var p interface{} - if len(params) != 0 { - p = params - } - httpRequest, err := client.newRequest(false, method, p) - if err != nil { - return nil, err - } - return client.doCall(httpRequest) +// Otherwise a RPCResponse object is returned with a RPCError field that is not nil. +type HTTPError struct { + Code int + err error } -// CallNamed sends an jsonrpc request over http to the rpc-service url that was provided on client creation. -// This differs from Call() by sending named, rather than positional, arguments. -// -// If something went wrong on the network / http level or if json parsing failed it returns an error. -// -// If something went wrong on the rpc-service / protocol level the Error field of the returned RPCResponse is set -// and contains information about the error. -// -// If the request was successful the Error field is nil and the Result field of the RPCRespnse struct contains the rpc result. -func (client *RPCClient) CallNamed(method string, params map[string]interface{}) (*RPCResponse, error) { - httpRequest, err := client.newRequest(false, method, params) - if err != nil { - return nil, err - } - return client.doCall(httpRequest) +// Error function is provided to be used as error object. +func (e *HTTPError) Error() string { + return e.err.Error() } -func (client *RPCClient) doCall(req *http.Request) (*RPCResponse, error) { - httpResponse, err := client.httpClient.Do(req) - if err != nil { - return nil, err - } - defer httpResponse.Body.Close() - - rpcResponse := RPCResponse{} - decoder := json.NewDecoder(httpResponse.Body) - decoder.UseNumber() - err = decoder.Decode(&rpcResponse) - if err != nil { - return nil, err - } - - return &rpcResponse, nil +type rpcClient struct { + endpoint string + httpClient *http.Client + customHeaders map[string]string } -// Notification sends a jsonrpc request to the rpc-service. The difference to Call() is that this request does not expect a response. -// The ID field of the request is omitted. -func (client *RPCClient) Notification(method string, params ...interface{}) error { - if len(params) == 0 { - params = nil - } - httpRequest, err := client.newRequest(true, method, params) - if err != nil { - return err +// RPCClientOpts can be provided to NewClientWithOpts() to change configuration of RPCClient. +// +// HTTPClient: provide a custom http.Client (e.g. to set a proxy, or tls options) +// +// CustomHeaders: provide custom headers, e.g. to set BasicAuth +type RPCClientOpts struct { + HTTPClient *http.Client + CustomHeaders map[string]string +} + +// RPCResponses is of type []*RPCResponse. +// This type is used to provide helper functions on the result list +type RPCResponses []*RPCResponse + +// AsMap returns the responses as map with response id as key. +func (res RPCResponses) AsMap() map[int]*RPCResponse { + resMap := make(map[int]*RPCResponse, 0) + for _, r := range res { + resMap[r.ID] = r } - httpResponse, err := client.httpClient.Do(httpRequest) - if err != nil { - return err + return resMap +} + +// GetByID returns the response object of the given id, nil if it does not exist. +func (res RPCResponses) GetByID(id int) *RPCResponse { + for _, r := range res { + if r.ID == id { + return r + } } - defer httpResponse.Body.Close() + return nil } -// Batch sends a jsonrpc batch request to the rpc-service. -// The parameter is a list of requests the could be one of: -// RPCRequest -// RPCNotification. +// HasError returns true if one of the response objects has Error field != nil +func (res RPCResponses) HasError() bool { + for _, res := range res { + if res.Error != nil { + return true + } + } + return false +} + +// RPCRequests is of type []*RPCRequest. +// This type is used to provide helper functions on the request list +type RPCRequests []*RPCRequest + +// NewClient returns a new RPCClient instance with default configuration. // -// The batch requests returns a list of RPCResponse structs. -func (client *RPCClient) Batch(requests ...interface{}) (*BatchResponse, error) { - for _, r := range requests { - switch r := r.(type) { - default: - return nil, fmt.Errorf("Invalid parameter: %s", r) - case *RPCRequest: - case *RPCNotification: +// endpoint: JSON-RPC service URL to which JSON-RPC requests are sent. +func NewClient(endpoint string) RPCClient { + return NewClientWithOpts(endpoint, nil) +} + +// NewClientWithOpts returns a new RPCClient instance with custom configuration. +// +// endpoint: JSON-RPC service URL to which JSON-RPC requests are sent. +// +// opts: RPCClientOpts provide custom configuration +func NewClientWithOpts(endpoint string, opts *RPCClientOpts) RPCClient { + rpcClient := &rpcClient{ + endpoint: endpoint, + httpClient: &http.Client{}, + customHeaders: make(map[string]string), + } + + if opts == nil { + return rpcClient + } + + if opts.HTTPClient != nil { + rpcClient.httpClient = opts.HTTPClient + } + + if opts.CustomHeaders != nil { + for k, v := range opts.CustomHeaders { + rpcClient.customHeaders[k] = v } } - httpRequest, err := client.newBatchRequest(requests...) + return rpcClient +} + +func (client *rpcClient) Call(method string, params ...interface{}) (*RPCResponse, error) { + + request := &RPCRequest{ + Method: method, + Params: Params(params...), + JSONRPC: jsonrpcVersion, + } + + return client.doCall(request) +} + +func (client *rpcClient) CallRaw(request *RPCRequest) (*RPCResponse, error) { + + return client.doCall(request) +} + +func (client *rpcClient) CallFor(out interface{}, method string, params ...interface{}) error { + rpcResponse, err := client.Call(method, params...) + if err != nil { + return err + } + + if rpcResponse.Error != nil { + return rpcResponse.Error + } + + return rpcResponse.GetObject(out) +} + +func (client *rpcClient) CallBatch(requests RPCRequests) (RPCResponses, error) { + if len(requests) == 0 { + return nil, errors.New("empty request list") + } + + for i, req := range requests { + req.ID = i + req.JSONRPC = jsonrpcVersion + } + + return client.doBatchCall(requests) +} + +func (client *rpcClient) CallBatchRaw(requests RPCRequests) (RPCResponses, error) { + if len(requests) == 0 { + return nil, errors.New("empty request list") + } + + return client.doBatchCall(requests) +} + +func (client *rpcClient) newRequest(req interface{}) (*http.Request, error) { + + body, err := json.Marshal(req) if err != nil { return nil, err } - httpResponse, err := client.httpClient.Do(httpRequest) + request, err := http.NewRequest("POST", client.endpoint, bytes.NewReader(body)) if err != nil { return nil, err } + + request.Header.Set("Content-Type", "application/json") + request.Header.Set("Accept", "application/json") + + // set default headers first, so that even content type and accept can be overwritten + for k, v := range client.customHeaders { + request.Header.Set(k, v) + } + + return request, nil +} + +func (client *rpcClient) doCall(RPCRequest *RPCRequest) (*RPCResponse, error) { + + httpRequest, err := client.newRequest(RPCRequest) + if err != nil { + return nil, fmt.Errorf("rpc call %v() on %v: %v", RPCRequest.Method, client.endpoint, err.Error()) + } + httpResponse, err := client.httpClient.Do(httpRequest) + if err != nil { + return nil, fmt.Errorf("rpc call %v() on %v: %v", RPCRequest.Method, httpRequest.URL.String(), err.Error()) + } defer httpResponse.Body.Close() - rpcResponses := []RPCResponse{} + var rpcResponse *RPCResponse decoder := json.NewDecoder(httpResponse.Body) + decoder.DisallowUnknownFields() decoder.UseNumber() - err = decoder.Decode(&rpcResponses) + err = decoder.Decode(&rpcResponse) + + // parsing error if err != nil { - return nil, err - } - - return &BatchResponse{rpcResponses: rpcResponses}, nil -} - -// SetAutoIncrementID if set to true, the id field of an rpcjson request will be incremented automatically -func (client *RPCClient) SetAutoIncrementID(flag bool) { - client.autoIncrementID = flag -} - -// SetNextID can be used to manually set the next id / reset the id. -func (client *RPCClient) SetNextID(id uint) { - client.idMutex.Lock() - client.nextID = id - client.idMutex.Unlock() -} - -// SetCustomHeader is used to set a custom header for each rpc request. -// You could for example set the Authorization Bearer here. -func (client *RPCClient) SetCustomHeader(key string, value string) { - client.customHeaders[key] = value -} - -// UnsetCustomHeader is used to removes a custom header that was added before. -func (client *RPCClient) UnsetCustomHeader(key string) { - delete(client.customHeaders, key) -} - -// SetBasicAuth is a helper function that sets the header for the given basic authentication credentials. -// To reset / disable authentication just set username or password to an empty string value. -func (client *RPCClient) SetBasicAuth(username string, password string) { - if username == "" || password == "" { - delete(client.customHeaders, "Authorization") - return - } - auth := username + ":" + password - client.customHeaders["Authorization"] = "Basic " + base64.StdEncoding.EncodeToString([]byte(auth)) -} - -// SetHTTPClient can be used to set a custom http.Client. -// This can be useful for example if you want to customize the http.Client behaviour (e.g. proxy settings) -func (client *RPCClient) SetHTTPClient(httpClient *http.Client) { - if httpClient == nil { - panic("httpClient cannot be nil") - } - client.httpClient = httpClient -} - -func (client *RPCClient) newRequest(notification bool, method string, params interface{}) (*http.Request, error) { - // TODO: easier way to remove ID from RPCRequest without extra struct - var rpcRequest interface{} - if notification { - rpcNotification := RPCNotification{ - JSONRPC: "2.0", - Method: method, - Params: params, + // if we have some http error, return it + if httpResponse.StatusCode >= 400 { + return nil, &HTTPError{ + Code: httpResponse.StatusCode, + err: fmt.Errorf("rpc call %v() on %v status code: %v. could not decode body to rpc response: %v", RPCRequest.Method, httpRequest.URL.String(), httpResponse.StatusCode, err.Error()), + } } - rpcRequest = rpcNotification - } else { - client.idMutex.Lock() - request := RPCRequest{ - ID: client.nextID, - JSONRPC: "2.0", - Method: method, - Params: params, + return nil, fmt.Errorf("rpc call %v() on %v status code: %v. could not decode body to rpc response: %v", RPCRequest.Method, httpRequest.URL.String(), httpResponse.StatusCode, err.Error()) + } + + // response body empty + if rpcResponse == nil { + // if we have some http error, return it + if httpResponse.StatusCode >= 400 { + return nil, &HTTPError{ + Code: httpResponse.StatusCode, + err: fmt.Errorf("rpc call %v() on %v status code: %v. rpc response missing", RPCRequest.Method, httpRequest.URL.String(), httpResponse.StatusCode), + } } - if client.autoIncrementID == true { - client.nextID++ + return nil, fmt.Errorf("rpc call %v() on %v status code: %v. rpc response missing", RPCRequest.Method, httpRequest.URL.String(), httpResponse.StatusCode) + } + + return rpcResponse, nil +} + +func (client *rpcClient) doBatchCall(rpcRequest []*RPCRequest) ([]*RPCResponse, error) { + httpRequest, err := client.newRequest(rpcRequest) + if err != nil { + return nil, fmt.Errorf("rpc batch call on %v: %v", client.endpoint, err.Error()) + } + httpResponse, err := client.httpClient.Do(httpRequest) + if err != nil { + return nil, fmt.Errorf("rpc batch call on %v: %v", httpRequest.URL.String(), err.Error()) + } + defer httpResponse.Body.Close() + + var rpcResponse RPCResponses + decoder := json.NewDecoder(httpResponse.Body) + decoder.DisallowUnknownFields() + decoder.UseNumber() + err = decoder.Decode(&rpcResponse) + + // parsing error + if err != nil { + // if we have some http error, return it + if httpResponse.StatusCode >= 400 { + return nil, &HTTPError{ + Code: httpResponse.StatusCode, + err: fmt.Errorf("rpc batch call on %v status code: %v. could not decode body to rpc response: %v", httpRequest.URL.String(), httpResponse.StatusCode, err.Error()), + } } - client.idMutex.Unlock() - rpcRequest = request + return nil, fmt.Errorf("rpc batch call on %v status code: %v. could not decode body to rpc response: %v", httpRequest.URL.String(), httpResponse.StatusCode, err.Error()) } - body, err := json.Marshal(rpcRequest) - if err != nil { - return nil, err + // response body empty + if rpcResponse == nil || len(rpcResponse) == 0 { + // if we have some http error, return it + if httpResponse.StatusCode >= 400 { + return nil, &HTTPError{ + Code: httpResponse.StatusCode, + err: fmt.Errorf("rpc batch call on %v status code: %v. rpc response missing", httpRequest.URL.String(), httpResponse.StatusCode), + } + } + return nil, fmt.Errorf("rpc batch call on %v status code: %v. rpc response missing", httpRequest.URL.String(), httpResponse.StatusCode) } - request, err := http.NewRequest("POST", client.endpoint, bytes.NewReader(body)) - if err != nil { - return nil, err - } - - for k, v := range client.customHeaders { - request.Header.Add(k, v) - } - - request.Header.Add("Content-Type", "application/json") - request.Header.Add("Accept", "application/json") - - return request, nil + return rpcResponse, nil } -func (client *RPCClient) newBatchRequest(requests ...interface{}) (*http.Request, error) { +// Params is a helper function that uses the same parameter syntax as Call(). +// But you should consider to always use NewRequest() instead. +// +// e.g. to manually create an RPCRequest object: +// request := &RPCRequest{ +// Method: "myMethod", +// Params: Params("Alex", 35, true), +// } +// +// same with new request: +// request := NewRequest("myMethod", "Alex", 35, true) +// +// If you know what you are doing you can omit the Params() call but potentially create incorrect rpc requests: +// request := &RPCRequest{ +// Method: "myMethod", +// Params: 2, <-- invalid since a single primitive value must be wrapped in an array --> no magic without Params() +// } +// +// correct: +// request := &RPCRequest{ +// Method: "myMethod", +// Params: []int{2}, <-- valid since a single primitive value must be wrapped in an array +// } +func Params(params ...interface{}) interface{} { + var finalParams interface{} - body, err := json.Marshal(requests) - if err != nil { - return nil, err + // if params was nil skip this and p stays nil + if params != nil { + switch len(params) { + case 0: // no parameters were provided, do nothing so finalParam is nil and will be omitted + case 1: // one param was provided, use it directly as is, or wrap primitive types in array + if params[0] != nil { + var typeOf reflect.Type + + // traverse until nil or not a pointer type + for typeOf = reflect.TypeOf(params[0]); typeOf != nil && typeOf.Kind() == reflect.Ptr; typeOf = typeOf.Elem() { + } + + if typeOf != nil { + // now check if we can directly marshal the type or if it must be wrapped in an array + switch typeOf.Kind() { + // for these types we just do nothing, since value of p is already unwrapped from the array params + case reflect.Struct: + finalParams = params[0] + case reflect.Array: + finalParams = params[0] + case reflect.Slice: + finalParams = params[0] + case reflect.Interface: + finalParams = params[0] + case reflect.Map: + finalParams = params[0] + default: // everything else must stay in an array (int, string, etc) + finalParams = params + } + } + } else { + finalParams = params + } + default: // if more than one parameter was provided it should be treated as an array + finalParams = params + } } - request, err := http.NewRequest("POST", client.endpoint, bytes.NewReader(body)) - if err != nil { - return nil, err - } - - for k, v := range client.customHeaders { - request.Header.Add(k, v) - } - - request.Header.Add("Content-Type", "application/json") - request.Header.Add("Accept", "application/json") - - return request, nil + return finalParams } -// UpdateRequestID updates the ID of an RPCRequest structure. -// -// This is used if a request is sent another time and the request should get an updated id. -// -// This does only make sense when used on with Batch() since Call() and Notififcation() do update the id automatically. -func (client *RPCClient) UpdateRequestID(rpcRequest *RPCRequest) { - if rpcRequest == nil { - return - } - client.idMutex.Lock() - defer client.idMutex.Unlock() - rpcRequest.ID = client.nextID - if client.autoIncrementID == true { - client.nextID++ - } -} - -// GetInt converts the rpc response to an int and returns it. -// -// This is a convenient function. Int could be 32 or 64 bit, depending on the architecture the code is running on. -// For a deterministic result use GetInt64(). +// GetInt converts the rpc response to an int64 and returns it. // // If result was not an integer an error is returned. -func (rpcResponse *RPCResponse) GetInt() (int, error) { - i, err := rpcResponse.GetInt64() - return int(i), err -} - -// GetInt64 converts the rpc response to an int64 and returns it. -// -// If result was not an integer an error is returned. -func (rpcResponse *RPCResponse) GetInt64() (int64, error) { - val, ok := rpcResponse.Result.(json.Number) +func (RPCResponse *RPCResponse) GetInt() (int64, error) { + val, ok := RPCResponse.Result.(json.Number) if !ok { - return 0, fmt.Errorf("could not parse int64 from %s", rpcResponse.Result) + return 0, fmt.Errorf("could not parse int64 from %s", RPCResponse.Result) } i, err := val.Int64() @@ -394,13 +561,13 @@ func (rpcResponse *RPCResponse) GetInt64() (int64, error) { return i, nil } -// GetFloat64 converts the rpc response to an float64 and returns it. +// GetFloat converts the rpc response to float64 and returns it. // // If result was not an float64 an error is returned. -func (rpcResponse *RPCResponse) GetFloat64() (float64, error) { - val, ok := rpcResponse.Result.(json.Number) +func (RPCResponse *RPCResponse) GetFloat() (float64, error) { + val, ok := RPCResponse.Result.(json.Number) if !ok { - return 0, fmt.Errorf("could not parse float64 from %s", rpcResponse.Result) + return 0, fmt.Errorf("could not parse float64 from %s", RPCResponse.Result) } f, err := val.Float64() @@ -414,10 +581,10 @@ func (rpcResponse *RPCResponse) GetFloat64() (float64, error) { // GetBool converts the rpc response to a bool and returns it. // // If result was not a bool an error is returned. -func (rpcResponse *RPCResponse) GetBool() (bool, error) { - val, ok := rpcResponse.Result.(bool) +func (RPCResponse *RPCResponse) GetBool() (bool, error) { + val, ok := RPCResponse.Result.(bool) if !ok { - return false, fmt.Errorf("could not parse bool from %s", rpcResponse.Result) + return false, fmt.Errorf("could not parse bool from %s", RPCResponse.Result) } return val, nil @@ -426,27 +593,20 @@ func (rpcResponse *RPCResponse) GetBool() (bool, error) { // GetString converts the rpc response to a string and returns it. // // If result was not a string an error is returned. -func (rpcResponse *RPCResponse) GetString() (string, error) { - val, ok := rpcResponse.Result.(string) +func (RPCResponse *RPCResponse) GetString() (string, error) { + val, ok := RPCResponse.Result.(string) if !ok { - return "", fmt.Errorf("could not parse string from %s", rpcResponse.Result) + return "", fmt.Errorf("could not parse string from %s", RPCResponse.Result) } return val, nil } -// GetObject converts the rpc response to an object (e.g. a struct) and returns it. -// The parameter should be a structure that can hold the data of the response object. +// GetObject converts the rpc response to an arbitrary type. // -// For example if the following json return value is expected: {"name": "alex", age: 33, "country": "Germany"} -// the struct should look like -// type Person struct { -// Name string -// Age int -// Country string -// } -func (rpcResponse *RPCResponse) GetObject(toType interface{}) error { - js, err := json.Marshal(rpcResponse.Result) +// The function works as you would expect it from json.Unmarshal() +func (RPCResponse *RPCResponse) GetObject(toType interface{}) error { + js, err := json.Marshal(RPCResponse.Result) if err != nil { return err } @@ -458,19 +618,3 @@ func (rpcResponse *RPCResponse) GetObject(toType interface{}) error { return nil } - -// GetResponseOf returns the rpc response of the corresponding request by matching the id. -// -// For this method to work, autoincrementID should be set to true (default). -func (batchResponse *BatchResponse) GetResponseOf(request *RPCRequest) (*RPCResponse, error) { - if request == nil { - return nil, errors.New("parameter cannot be nil") - } - for _, elem := range batchResponse.rpcResponses { - if elem.ID == request.ID { - return &elem, nil - } - } - - return nil, fmt.Errorf("element with id %d not found", request.ID) -} diff --git a/vendor/github.com/ybbus/jsonrpc/jsonrpc_test.go b/vendor/github.com/ybbus/jsonrpc/jsonrpc_test.go index 3bea957..21afdfa 100644 --- a/vendor/github.com/ybbus/jsonrpc/jsonrpc_test.go +++ b/vendor/github.com/ybbus/jsonrpc/jsonrpc_test.go @@ -5,13 +5,10 @@ import ( "io/ioutil" "net/http" "net/http/httptest" - "net/url" "os" "testing" - "time" - - "github.com/onsi/gomega" + . "github.com/onsi/gomega" ) // needed to retrieve requests that arrived at httpServer for further investigation @@ -44,428 +41,1090 @@ func TestMain(m *testing.M) { } func TestSimpleRpcCallHeaderCorrect(t *testing.T) { - gomega.RegisterTestingT(t) + RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) + rpcClient := NewClient(httpServer.URL) rpcClient.Call("add", 1, 2) req := (<-requestChan).request - gomega.Expect(req.Method).To(gomega.Equal("POST")) - gomega.Expect(req.Header.Get("Content-Type")).To(gomega.Equal("application/json")) - gomega.Expect(req.Header.Get("Accept")).To(gomega.Equal("application/json")) + Expect(req.Method).To(Equal("POST")) + Expect(req.Header.Get("Content-Type")).To(Equal("application/json")) + Expect(req.Header.Get("Accept")).To(Equal("application/json")) } -// test if the structure of an rpc request is built correctly validate the data that arrived on the server -func TestRpcJsonRequestStruct(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetAutoIncrementID(false) +// test if the structure of an rpc request is built correctly by validating the data that arrived on the test server +func TestRpcClient_Call(t *testing.T) { + RegisterTestingT(t) + rpcClient := NewClient(httpServer.URL) - rpcClient.Call("add", 1, 2) - body := (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"add","params":[1,2],"id":0}`)) + person := Person{ + Name: "Alex", + Age: 35, + Country: "Germany", + } - rpcClient.Call("setName", "alex") - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"setName","params":["alex"],"id":0}`)) + drink := Drink{ + Name: "Cuba Libre", + Ingredients: []string{"rum", "cola"}, + } - rpcClient.Call("setPerson", "alex", 33, "Germany") - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"setPerson","params":["alex",33,"Germany"],"id":0}`)) + rpcClient.Call("missingParam") + Expect((<-requestChan).body).To(Equal(`{"method":"missingParam","id":0,"jsonrpc":"2.0"}`)) - rpcClient.Call("setPersonObject", Person{"alex", 33, "Germany"}) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"setPersonObject","params":[{"name":"alex","age":33,"country":"Germany"}],"id":0}`)) + rpcClient.Call("nullParam", nil) + Expect((<-requestChan).body).To(Equal(`{"method":"nullParam","params":[null],"id":0,"jsonrpc":"2.0"}`)) - rpcClient.Call("getDate") - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"getDate","id":0}`)) + rpcClient.Call("nullParams", nil, nil) + Expect((<-requestChan).body).To(Equal(`{"method":"nullParams","params":[null,null],"id":0,"jsonrpc":"2.0"}`)) - rpcClient.Call("setAnonymStruct", struct { + rpcClient.Call("emptyParams", []interface{}{}) + Expect((<-requestChan).body).To(Equal(`{"method":"emptyParams","params":[],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("emptyAnyParams", []string{}) + Expect((<-requestChan).body).To(Equal(`{"method":"emptyAnyParams","params":[],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("emptyObject", struct{}{}) + Expect((<-requestChan).body).To(Equal(`{"method":"emptyObject","params":{},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("emptyObjectList", []struct{}{{}, {}}) + Expect((<-requestChan).body).To(Equal(`{"method":"emptyObjectList","params":[{},{}],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("boolParam", true) + Expect((<-requestChan).body).To(Equal(`{"method":"boolParam","params":[true],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("boolParams", true, false, true) + Expect((<-requestChan).body).To(Equal(`{"method":"boolParams","params":[true,false,true],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("stringParam", "Alex") + Expect((<-requestChan).body).To(Equal(`{"method":"stringParam","params":["Alex"],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("stringParams", "JSON", "RPC") + Expect((<-requestChan).body).To(Equal(`{"method":"stringParams","params":["JSON","RPC"],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("numberParam", 123) + Expect((<-requestChan).body).To(Equal(`{"method":"numberParam","params":[123],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("numberParams", 123, 321) + Expect((<-requestChan).body).To(Equal(`{"method":"numberParams","params":[123,321],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("floatParam", 1.23) + Expect((<-requestChan).body).To(Equal(`{"method":"floatParam","params":[1.23],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("floatParams", 1.23, 3.21) + Expect((<-requestChan).body).To(Equal(`{"method":"floatParams","params":[1.23,3.21],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("manyParams", "Alex", 35, true, nil, 2.34) + Expect((<-requestChan).body).To(Equal(`{"method":"manyParams","params":["Alex",35,true,null,2.34],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("emptyMissingPublicFieldObject", struct{ name string }{name: "Alex"}) + Expect((<-requestChan).body).To(Equal(`{"method":"emptyMissingPublicFieldObject","params":{},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("singleStruct", person) + Expect((<-requestChan).body).To(Equal(`{"method":"singleStruct","params":{"name":"Alex","age":35,"country":"Germany"},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("singlePointerToStruct", &person) + Expect((<-requestChan).body).To(Equal(`{"method":"singlePointerToStruct","params":{"name":"Alex","age":35,"country":"Germany"},"id":0,"jsonrpc":"2.0"}`)) + + pp := &person + rpcClient.Call("doublePointerStruct", &pp) + Expect((<-requestChan).body).To(Equal(`{"method":"doublePointerStruct","params":{"name":"Alex","age":35,"country":"Germany"},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("multipleStructs", person, &drink) + Expect((<-requestChan).body).To(Equal(`{"method":"multipleStructs","params":[{"name":"Alex","age":35,"country":"Germany"},{"name":"Cuba Libre","ingredients":["rum","cola"]}],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("singleStructInArray", []interface{}{person}) + Expect((<-requestChan).body).To(Equal(`{"method":"singleStructInArray","params":[{"name":"Alex","age":35,"country":"Germany"}],"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("namedParameters", map[string]interface{}{ + "name": "Alex", + "age": 35, + }) + Expect((<-requestChan).body).To(Equal(`{"method":"namedParameters","params":{"age":35,"name":"Alex"},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("anonymousStructNoTags", struct { + Name string + Age int + }{"Alex", 33}) + Expect((<-requestChan).body).To(Equal(`{"method":"anonymousStructNoTags","params":{"Name":"Alex","Age":33},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("anonymousStructWithTags", struct { Name string `json:"name"` Age int `json:"age"` }{"Alex", 33}) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"setAnonymStruct","params":[{"name":"Alex","age":33}],"id":0}`)) + Expect((<-requestChan).body).To(Equal(`{"method":"anonymousStructWithTags","params":{"name":"Alex","age":33},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("structWithNullField", struct { + Name string `json:"name"` + Address *string `json:"address"` + }{"Alex", nil}) + Expect((<-requestChan).body).To(Equal(`{"method":"structWithNullField","params":{"name":"Alex","address":null},"id":0,"jsonrpc":"2.0"}`)) + + rpcClient.Call("nestedStruct", + Planet{ + Name: "Mars", + Properties: Properties{ + Distance: 54600000, + Color: "red", + }, + }) + Expect((<-requestChan).body).To(Equal(`{"method":"nestedStruct","params":{"name":"Mars","properties":{"distance":54600000,"color":"red"}},"id":0,"jsonrpc":"2.0"}`)) } -// test if the structure of an rpc request is built correctly validate the data that arrived on the server -func TestRpcJsonRequestStructWithNamedParams(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetAutoIncrementID(false) - - rpcClient.CallNamed("myMethod", map[string]interface{}{ - "arrayOfInts": []int{1, 2, 3}, - "arrayOfStrings": []string{"A", "B", "C"}, - "bool": true, - "int": 1, - "number": 1.2, - "string": "boogaloo", - "subObject": map[string]interface{}{"foo": "bar"}, - }) - body := (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"myMethod","params":{"arrayOfInts":[1,2,3],"arrayOfStrings":["A","B","C"],"bool":true,"int":1,"number":1.2,"string":"boogaloo","subObject":{"foo":"bar"}},"id":0}`)) -} -func TestRpcJsonResponseStruct(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetAutoIncrementID(false) - - responseBody = `{"jsonrpc":"2.0","result":3,"id":0}` - response, _ := rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var int64Result int64 - int64Result, _ = response.GetInt64() - gomega.Expect(int64Result).To(gomega.Equal(int64(3))) - - responseBody = `{"jsonrpc":"2.0","result":3,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var intResult int - intResult, _ = response.GetInt() - gomega.Expect(intResult).To(gomega.Equal(3)) - - responseBody = `{"jsonrpc":"2.0","result":3.3,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - _, err := response.GetInt() - gomega.Expect(err).To(gomega.Not(gomega.Equal(nil))) - - responseBody = `{"jsonrpc":"2.0","result":false,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - _, err = response.GetInt() - gomega.Expect(err).To(gomega.Not(gomega.Equal(nil))) - - responseBody = `{"jsonrpc":"2.0","result": 3.7,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var float64Result float64 - float64Result, _ = response.GetFloat64() - gomega.Expect(float64Result).To(gomega.Equal(3.7)) - - responseBody = `{"jsonrpc":"2.0","result": "1.3","id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - _, err = response.GetFloat64() - gomega.Expect(err).To(gomega.Not(gomega.Equal(nil))) - - responseBody = `{"jsonrpc":"2.0","result": true,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var boolResult bool - boolResult, _ = response.GetBool() - gomega.Expect(boolResult).To(gomega.Equal(true)) - - responseBody = `{"jsonrpc":"2.0","result": 0,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - _, err = response.GetBool() - gomega.Expect(err).To(gomega.Not(gomega.Equal(nil))) - - responseBody = `{"jsonrpc":"2.0","result": "alex","id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var stringResult string - stringResult, _ = response.GetString() - gomega.Expect(stringResult).To(gomega.Equal("alex")) - - responseBody = `{"jsonrpc":"2.0","result": 123,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - _, err = response.GetString() - gomega.Expect(err).To(gomega.Not(gomega.Equal(nil))) - - responseBody = `{"jsonrpc":"2.0","result": {"name": "alex", "age": 33, "country": "Germany"},"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var person Person - response.GetObject(&person) - gomega.Expect(person).To(gomega.Equal(Person{"alex", 33, "Germany"})) - - responseBody = `{"jsonrpc":"2.0","result": 3,"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var number int - response.GetObject(&number) - gomega.Expect(int(number)).To(gomega.Equal(3)) - - responseBody = `{"jsonrpc":"2.0","result": [{"name": "alex", "age": 33, "country": "Germany"}, {"name": "Ferolaz", "age": 333, "country": "Azeroth"}],"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var personArray = []Person{} - response.GetObject(&personArray) - gomega.Expect(personArray).To(gomega.Equal([]Person{{"alex", 33, "Germany"}, {"Ferolaz", 333, "Azeroth"}})) - - responseBody = `{"jsonrpc":"2.0","result": [1, 2, 3],"id":0}` - response, _ = rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - var intArray []int - response.GetObject(&intArray) - gomega.Expect(intArray).To(gomega.Equal([]int{1, 2, 3})) -} - -func TestResponseErrorWorks(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetAutoIncrementID(false) - - responseBody = `{"jsonrpc":"2.0","error": {"code": -123, "message": "something wrong"},"id":0}` - response, _ := rpcClient.Call("test") // Call param does not matter, since response does not depend on request - <-requestChan - gomega.Expect(*response.Error).To(gomega.Equal(RPCError{-123, "something wrong", nil})) -} - -func TestNotifyWorks(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - - rpcClient.Notification("test", 10) - <-requestChan - rpcClient.Notification("test", Person{"alex", 33, "Germany"}) - <-requestChan - rpcClient.Notification("test", 10, 20, "alex") - body := (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"test","params":[10,20,"alex"]}`)) -} - -func TestNewRPCRequestObject(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - - req := rpcClient.NewRPCRequestObject("add", 1, 2) - gomega.Expect(req).To(gomega.Equal(&RPCRequest{ - JSONRPC: "2.0", - ID: 0, - Method: "add", - Params: []interface{}{1, 2}, - })) - - req = rpcClient.NewRPCRequestObject("getDate") - gomega.Expect(req).To(gomega.Equal(&RPCRequest{ - JSONRPC: "2.0", - ID: 1, - Method: "getDate", - Params: nil, - })) - - req = rpcClient.NewRPCRequestObject("getPerson", Person{"alex", 33, "germany"}) - gomega.Expect(req).To(gomega.Equal(&RPCRequest{ - JSONRPC: "2.0", - ID: 2, - Method: "getPerson", - Params: []interface{}{Person{"alex", 33, "germany"}}, - })) -} - -func TestNewRPCNotificationObject(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - - req := rpcClient.NewRPCNotificationObject("add", 1, 2) - gomega.Expect(req).To(gomega.Equal(&RPCNotification{ - JSONRPC: "2.0", - Method: "add", - Params: []interface{}{1, 2}, - })) - - req = rpcClient.NewRPCNotificationObject("getDate") - gomega.Expect(req).To(gomega.Equal(&RPCNotification{ - JSONRPC: "2.0", - Method: "getDate", - Params: nil, - })) - - req = rpcClient.NewRPCNotificationObject("getPerson", Person{"alex", 33, "germany"}) - gomega.Expect(req).To(gomega.Equal(&RPCNotification{ - JSONRPC: "2.0", - Method: "getPerson", - Params: []interface{}{Person{"alex", 33, "germany"}}, - })) -} - -func TestBatchRequestWorks(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetCustomHeader("Test", "test") - - req1 := rpcClient.NewRPCRequestObject("test1", "alex") - rpcClient.Batch(req1) - req := <-requestChan - body := req.body - gomega.Expect(req.request.Header.Get("Test")).To(gomega.Equal("test")) - gomega.Expect(body).To(gomega.Equal(`[{"jsonrpc":"2.0","method":"test1","params":["alex"],"id":0}]`)) - - notify1 := rpcClient.NewRPCNotificationObject("test2", "alex") - rpcClient.Batch(notify1) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`[{"jsonrpc":"2.0","method":"test2","params":["alex"]}]`)) - - rpcClient.Batch(req1, notify1) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`[{"jsonrpc":"2.0","method":"test1","params":["alex"],"id":0},{"jsonrpc":"2.0","method":"test2","params":["alex"]}]`)) - - requests := []interface{}{req1, notify1} - rpcClient.Batch(requests...) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`[{"jsonrpc":"2.0","method":"test1","params":["alex"],"id":0},{"jsonrpc":"2.0","method":"test2","params":["alex"]}]`)) - - invalid := &Person{"alex", 33, "germany"} - _, err := rpcClient.Batch(invalid, notify1) - gomega.Expect(err).To(gomega.Not(gomega.Equal(nil))) -} - -func TestBatchResponseWorks(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - - responseBody = `[{"jsonrpc":"2.0","result": 1,"id":0},{"jsonrpc":"2.0","result": 2,"id":1},{"jsonrpc":"2.0","result": 3,"id":3}]` - req1 := rpcClient.NewRPCRequestObject("test1", 1) - req2 := rpcClient.NewRPCRequestObject("test2", 2) - req3 := rpcClient.NewRPCRequestObject("test3", 3) - responses, _ := rpcClient.Batch(req1, req2, req3) - <-requestChan - - resp2, _ := responses.GetResponseOf(req2) - res2, _ := resp2.GetInt() - - gomega.Expect(res2).To(gomega.Equal(2)) -} - -func TestIDIncremtWorks(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetAutoIncrementID(true) // default - - rpcClient.Call("test1", 1, 2) - body := (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"test1","params":[1,2],"id":0}`)) - - rpcClient.Call("test2", 1, 2) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"test2","params":[1,2],"id":1}`)) - - rpcClient.SetNextID(10) - - rpcClient.Call("test3", 1, 2) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"test3","params":[1,2],"id":10}`)) - - rpcClient.Call("test4", 1, 2) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"test4","params":[1,2],"id":11}`)) - - rpcClient.SetAutoIncrementID(false) - - rpcClient.Call("test5", 1, 2) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"test5","params":[1,2],"id":12}`)) - - rpcClient.Call("test6", 1, 2) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"test6","params":[1,2],"id":12}`)) -} - -func TestRequestIDUpdateWorks(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetAutoIncrementID(true) // default - - req1 := rpcClient.NewRPCRequestObject("test", 1, 2, 3) - req2 := rpcClient.NewRPCRequestObject("test", 1, 2, 3) - gomega.Expect(int(req1.ID)).To(gomega.Equal(0)) - gomega.Expect(int(req2.ID)).To(gomega.Equal(1)) - - rpcClient.UpdateRequestID(req1) - rpcClient.UpdateRequestID(req2) - - gomega.Expect(int(req1.ID)).To(gomega.Equal(2)) - gomega.Expect(int(req2.ID)).To(gomega.Equal(3)) - - rpcClient.UpdateRequestID(req2) - rpcClient.UpdateRequestID(req1) - - gomega.Expect(int(req1.ID)).To(gomega.Equal(5)) - gomega.Expect(int(req2.ID)).To(gomega.Equal(4)) - - rpcClient.UpdateRequestID(req1) - rpcClient.UpdateRequestID(req1) - - gomega.Expect(int(req1.ID)).To(gomega.Equal(7)) - gomega.Expect(int(req2.ID)).To(gomega.Equal(4)) - - rpcClient.SetAutoIncrementID(false) - - rpcClient.UpdateRequestID(req2) - rpcClient.UpdateRequestID(req1) - - gomega.Expect(int(req1.ID)).To(gomega.Equal(8)) - gomega.Expect(int(req2.ID)).To(gomega.Equal(8)) - - rpcClient.SetAutoIncrementID(false) - -} - -func TestBasicAuthentication(t *testing.T) { - gomega.RegisterTestingT(t) - rpcClient := NewRPCClient(httpServer.URL) - - rpcClient.SetBasicAuth("alex", "secret") - rpcClient.Call("add", 1, 2) - req := (<-requestChan).request - gomega.Expect(req.Header.Get("Authorization")).To(gomega.Equal("Basic YWxleDpzZWNyZXQ=")) - - rpcClient.SetBasicAuth("", "") - rpcClient.Call("add", 1, 2) - req = (<-requestChan).request - gomega.Expect(req.Header.Get("Authorization")).NotTo(gomega.Equal("Basic YWxleDpzZWNyZXQ=")) -} - -func TestCustomHeaders(t *testing.T) { - gomega.RegisterTestingT(t) - - rpcClient := NewRPCClient(httpServer.URL) - - rpcClient.SetCustomHeader("Test", "success") - rpcClient.Call("add", 1, 2) - req := (<-requestChan).request - - gomega.Expect(req.Header.Get("Test")).To(gomega.Equal("success")) - - rpcClient.SetCustomHeader("Test2", "success2") - rpcClient.Call("add", 1, 2) - req = (<-requestChan).request - - gomega.Expect(req.Header.Get("Test")).To(gomega.Equal("success")) - gomega.Expect(req.Header.Get("Test2")).To(gomega.Equal("success2")) - - rpcClient.UnsetCustomHeader("Test") - rpcClient.Call("add", 1, 2) - req = (<-requestChan).request - - gomega.Expect(req.Header.Get("Test")).NotTo(gomega.Equal("success")) - gomega.Expect(req.Header.Get("Test2")).To(gomega.Equal("success2")) -} - -func TestCustomHTTPClient(t *testing.T) { - gomega.RegisterTestingT(t) - - rpcClient := NewRPCClient(httpServer.URL) - - proxyURL, _ := url.Parse("http://proxy:8080") - transport := &http.Transport{Proxy: http.ProxyURL(proxyURL)} - - httpClient := &http.Client{ - Timeout: 5 * time.Second, - Transport: transport, +func TestRpcClient_CallBatch(t *testing.T) { + RegisterTestingT(t) + rpcClient := NewClient(httpServer.URL) + + person := Person{ + Name: "Alex", + Age: 35, + Country: "Germany", } - rpcClient.SetHTTPClient(httpClient) - rpcClient.Call("add", 1, 2) - // req := (<-requestChan).request - // TODO: what to test here? + drink := Drink{ + Name: "Cuba Libre", + Ingredients: []string{"rum", "cola"}, + } + + // invalid parameters are possible by manually defining *RPCRequest + rpcClient.CallBatch(RPCRequests{ + { + Method: "singleRequest", + Params: 3, // invalid, should be []int{3} + }, + }) + Expect((<-requestChan).body).To(Equal(`[{"method":"singleRequest","params":3,"id":0,"jsonrpc":"2.0"}]`)) + + // better use Params() unless you know what you are doing + rpcClient.CallBatch(RPCRequests{ + { + Method: "singleRequest", + Params: Params(3), // always valid json rpc + }, + }) + Expect((<-requestChan).body).To(Equal(`[{"method":"singleRequest","params":[3],"id":0,"jsonrpc":"2.0"}]`)) + + // even better, use NewRequest() + rpcClient.CallBatch(RPCRequests{ + NewRequest("multipleRequests1", 1), + NewRequest("multipleRequests2", 2), + NewRequest("multipleRequests3", 3), + }) + Expect((<-requestChan).body).To(Equal(`[{"method":"multipleRequests1","params":[1],"id":0,"jsonrpc":"2.0"},{"method":"multipleRequests2","params":[2],"id":1,"jsonrpc":"2.0"},{"method":"multipleRequests3","params":[3],"id":2,"jsonrpc":"2.0"}]`)) + + // test a huge batch request + requests := RPCRequests{ + NewRequest("nullParam", nil), + NewRequest("nullParams", nil, nil), + NewRequest("emptyParams", []interface{}{}), + NewRequest("emptyAnyParams", []string{}), + NewRequest("emptyObject", struct{}{}), + NewRequest("emptyObjectList", []struct{}{{}, {}}), + NewRequest("boolParam", true), + NewRequest("boolParams", true, false, true), + NewRequest("stringParam", "Alex"), + NewRequest("stringParams", "JSON", "RPC"), + NewRequest("numberParam", 123), + NewRequest("numberParams", 123, 321), + NewRequest("floatParam", 1.23), + NewRequest("floatParams", 1.23, 3.21), + NewRequest("manyParams", "Alex", 35, true, nil, 2.34), + NewRequest("emptyMissingPublicFieldObject", struct{ name string }{name: "Alex"}), + NewRequest("singleStruct", person), + NewRequest("singlePointerToStruct", &person), + NewRequest("multipleStructs", person, &drink), + NewRequest("singleStructInArray", []interface{}{person}), + NewRequest("namedParameters", map[string]interface{}{ + "name": "Alex", + "age": 35, + }), + NewRequest("anonymousStructNoTags", struct { + Name string + Age int + }{"Alex", 33}), + NewRequest("anonymousStructWithTags", struct { + Name string `json:"name"` + Age int `json:"age"` + }{"Alex", 33}), + NewRequest("structWithNullField", struct { + Name string `json:"name"` + Address *string `json:"address"` + }{"Alex", nil}), + } + rpcClient.CallBatch(requests) + + Expect((<-requestChan).body).To(Equal(`[{"method":"nullParam","params":[null],"id":0,"jsonrpc":"2.0"},` + + `{"method":"nullParams","params":[null,null],"id":1,"jsonrpc":"2.0"},` + + `{"method":"emptyParams","params":[],"id":2,"jsonrpc":"2.0"},` + + `{"method":"emptyAnyParams","params":[],"id":3,"jsonrpc":"2.0"},` + + `{"method":"emptyObject","params":{},"id":4,"jsonrpc":"2.0"},` + + `{"method":"emptyObjectList","params":[{},{}],"id":5,"jsonrpc":"2.0"},` + + `{"method":"boolParam","params":[true],"id":6,"jsonrpc":"2.0"},` + + `{"method":"boolParams","params":[true,false,true],"id":7,"jsonrpc":"2.0"},` + + `{"method":"stringParam","params":["Alex"],"id":8,"jsonrpc":"2.0"},` + + `{"method":"stringParams","params":["JSON","RPC"],"id":9,"jsonrpc":"2.0"},` + + `{"method":"numberParam","params":[123],"id":10,"jsonrpc":"2.0"},` + + `{"method":"numberParams","params":[123,321],"id":11,"jsonrpc":"2.0"},` + + `{"method":"floatParam","params":[1.23],"id":12,"jsonrpc":"2.0"},` + + `{"method":"floatParams","params":[1.23,3.21],"id":13,"jsonrpc":"2.0"},` + + `{"method":"manyParams","params":["Alex",35,true,null,2.34],"id":14,"jsonrpc":"2.0"},` + + `{"method":"emptyMissingPublicFieldObject","params":{},"id":15,"jsonrpc":"2.0"},` + + `{"method":"singleStruct","params":{"name":"Alex","age":35,"country":"Germany"},"id":16,"jsonrpc":"2.0"},` + + `{"method":"singlePointerToStruct","params":{"name":"Alex","age":35,"country":"Germany"},"id":17,"jsonrpc":"2.0"},` + + `{"method":"multipleStructs","params":[{"name":"Alex","age":35,"country":"Germany"},{"name":"Cuba Libre","ingredients":["rum","cola"]}],"id":18,"jsonrpc":"2.0"},` + + `{"method":"singleStructInArray","params":[{"name":"Alex","age":35,"country":"Germany"}],"id":19,"jsonrpc":"2.0"},` + + `{"method":"namedParameters","params":{"age":35,"name":"Alex"},"id":20,"jsonrpc":"2.0"},` + + `{"method":"anonymousStructNoTags","params":{"Name":"Alex","Age":33},"id":21,"jsonrpc":"2.0"},` + + `{"method":"anonymousStructWithTags","params":{"name":"Alex","age":33},"id":22,"jsonrpc":"2.0"},` + + `{"method":"structWithNullField","params":{"name":"Alex","address":null},"id":23,"jsonrpc":"2.0"}]`)) + + // create batch manually + requests = []*RPCRequest{ + { + Method: "myMethod1", + Params: []int{1}, + ID: 123, // will be forced to requests[i].ID == i unless you use CallBatchRaw + JSONRPC: "7.0", // will be forced to "2.0" unless you use CallBatchRaw + }, + { + Method: "myMethod2", + Params: &person, + ID: 321, // will be forced to requests[i].ID == i unless you use CallBatchRaw + JSONRPC: "wrong", // will be forced to "2.0" unless you use CallBatchRaw + }, + } + rpcClient.CallBatch(requests) + + Expect((<-requestChan).body).To(Equal(`[{"method":"myMethod1","params":[1],"id":0,"jsonrpc":"2.0"},` + + `{"method":"myMethod2","params":{"name":"Alex","age":35,"country":"Germany"},"id":1,"jsonrpc":"2.0"}]`)) + + // use raw batch + requests = []*RPCRequest{ + { + Method: "myMethod1", + Params: []int{1}, + ID: 123, + JSONRPC: "7.0", + }, + { + Method: "myMethod2", + Params: &person, + ID: 321, + JSONRPC: "wrong", + }, + } + rpcClient.CallBatchRaw(requests) + + Expect((<-requestChan).body).To(Equal(`[{"method":"myMethod1","params":[1],"id":123,"jsonrpc":"7.0"},` + + `{"method":"myMethod2","params":{"name":"Alex","age":35,"country":"Germany"},"id":321,"jsonrpc":"wrong"}]`)) +} + +// test if the result of an an rpc request is parsed correctly and if errors are thrown correctly +func TestRpcJsonResponseStruct(t *testing.T) { + RegisterTestingT(t) + rpcClient := NewClient(httpServer.URL) + + // empty return body is an error + responseBody = `` + res, err := rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil()) + + // not a json body is an error + responseBody = `{ "not": "a", "json": "object"` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil()) + + // field "anotherField" not allowed in rpc response is an error + responseBody = `{ "anotherField": "norpc"}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil()) + + // TODO: result must contain one of "result", "error" + // TODO: is there an efficient way to do this? + /*responseBody = `{}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil())*/ + + // result null is ok + responseBody = `{"result": null}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error).To(BeNil()) + + // error null is ok + responseBody = `{"error": null}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error).To(BeNil()) + + // result and error null is ok + responseBody = `{"result": null, "error": null}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error).To(BeNil()) + + // TODO: result must not contain both of "result", "error" != null + // TODO: is there an efficient way to do this? + /*responseBody = `{ "result": 123, "error": {"code": 123, "message": "something wrong"}}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil())*/ + + // result string is ok + responseBody = `{"result": "ok"}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(Equal("ok")) + + // result with error null is ok + responseBody = `{"result": "ok", "error": null}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(Equal("ok")) + + // error with result null is ok + responseBody = `{"error": {"code": 123, "message": "something wrong"}, "result": null}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error.Code).To(Equal(123)) + Expect(res.Error.Message).To(Equal("something wrong")) + + // TODO: empty error is not ok, must at least contain code and message + /*responseBody = `{ "error": {}}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error).NotTo(BeNil())*/ + + // TODO: only code in error is not ok, must at least contain code and message + /*responseBody = `{ "error": {"code": 123}}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error).NotTo(BeNil())*/ + + // TODO: only message in error is not ok, must at least contain code and message + /*responseBody = `{ "error": {"message": "something wrong"}}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error).NotTo(BeNil())*/ + + // error with code and message is ok + responseBody = `{ "error": {"code": 123, "message": "something wrong"}}` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Result).To(BeNil()) + Expect(res.Error.Code).To(Equal(123)) + Expect(res.Error.Message).To(Equal("something wrong")) + + // check results + + // should return int correctly + responseBody = `{ "result": 1 }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + i, err := res.GetInt() + Expect(err).To(BeNil()) + Expect(i).To(Equal(int64(1))) + + // error on wrong type + i = 3 + responseBody = `{ "result": "notAnInt" }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + i, err = res.GetInt() + Expect(err).NotTo(BeNil()) + Expect(i).To(Equal(int64(0))) + + // error on result null + i = 3 + responseBody = `{ "result": null }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + i, err = res.GetInt() + Expect(err).NotTo(BeNil()) + Expect(i).To(Equal(int64(0))) + + b := false + responseBody = `{ "result": true }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + b, err = res.GetBool() + Expect(err).To(BeNil()) + Expect(b).To(Equal(true)) + + b = true + responseBody = `{ "result": 123 }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + b, err = res.GetBool() + Expect(err).NotTo(BeNil()) + Expect(b).To(Equal(false)) + + var p *Person + responseBody = `{ "result": {"name": "Alex", "age": 35, "anotherField": "something"} }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p) + Expect(err).To(BeNil()) + Expect(p.Name).To(Equal("Alex")) + Expect(p.Age).To(Equal(35)) + Expect(p.Country).To(Equal("")) + + // TODO: How to check if result could be parsed or if it is default? + p = nil + responseBody = `{ "result": {"anotherField": "something"} }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p) + Expect(err).To(BeNil()) + Expect(p).NotTo(BeNil()) + + // TODO: HERE###### + var pp *PointerFieldPerson + responseBody = `{ "result": {"anotherField": "something", "country": "Germany"} }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&pp) + Expect(err).To(BeNil()) + Expect(pp.Name).To(BeNil()) + Expect(pp.Age).To(BeNil()) + Expect(*pp.Country).To(Equal("Germany")) + + p = nil + responseBody = `{ "result": null }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p) + Expect(err).To(BeNil()) + Expect(p).To(BeNil()) + + // passing nil is an error + p = nil + responseBody = `{ "result": null }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(p) + Expect(err).NotTo(BeNil()) + Expect(p).To(BeNil()) + + p2 := &Person{ + Name: "Alex", + } + responseBody = `{ "result": null }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p2) + Expect(err).To(BeNil()) + Expect(p2).To(BeNil()) + + p2 = &Person{ + Name: "Alex", + } + responseBody = `{ "result": {"age": 35} }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(p2) + Expect(err).To(BeNil()) + Expect(p2.Name).To(Equal("Alex")) + Expect(p2.Age).To(Equal(35)) + + // prefilled struct is kept on no result + p3 := Person{ + Name: "Alex", + } + responseBody = `{ "result": null }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p3) + Expect(err).To(BeNil()) + Expect(p3.Name).To(Equal("Alex")) + + // prefilled struct is extended / overwritten + p3 = Person{ + Name: "Alex", + Age: 123, + } + responseBody = `{ "result": {"age": 35, "country": "Germany"} }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p3) + Expect(err).To(BeNil()) + Expect(p3.Name).To(Equal("Alex")) + Expect(p3.Age).To(Equal(35)) + Expect(p3.Country).To(Equal("Germany")) + + // nil is an error + responseBody = `{ "result": {"age": 35} }` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(nil) + Expect(err).NotTo(BeNil()) +} + +func TestRpcBatchJsonResponseStruct(t *testing.T) { + RegisterTestingT(t) + rpcClient := NewClient(httpServer.URL) + + // empty return body is an error + responseBody = `` + res, err := rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil()) + + // not a json body is an error + responseBody = `{ "not": "a", "json": "object"` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil()) + + // field "anotherField" not allowed in rpc response is an error + responseBody = `{ "anotherField": "norpc"}` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil()) + + // TODO: result must contain one of "result", "error" + // TODO: is there an efficient way to do this? + /*responseBody = `[{}]` + res, err = rpcClient.Call("something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil())*/ + + // result must be wrapped in array on batch request + responseBody = `{"result": null}` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err.Error()).NotTo(BeNil()) + + // result ok since in array + responseBody = `[{"result": null}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(len(res)).To(Equal(1)) + Expect(res[0].Result).To(BeNil()) + + // error null is ok + responseBody = `[{"error": null}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(BeNil()) + Expect(res[0].Error).To(BeNil()) + + // result and error null is ok + responseBody = `[{"result": null, "error": null}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(BeNil()) + Expect(res[0].Error).To(BeNil()) + + // TODO: result must not contain both of "result", "error" != null + // TODO: is there an efficient way to do this? + /*responseBody = `[{ "result": 123, "error": {"code": 123, "message": "something wrong"}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something",1, 2, 3), + }) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(res).To(BeNil())*/ + + // result string is ok + responseBody = `[{"result": "ok","id":0}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(Equal("ok")) + Expect(res[0].ID).To(Equal(0)) + + // result with error null is ok + responseBody = `[{"result": "ok", "error": null}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(Equal("ok")) + + // error with result null is ok + responseBody = `[{"error": {"code": 123, "message": "something wrong"}, "result": null}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(BeNil()) + Expect(res[0].Error.Code).To(Equal(123)) + Expect(res[0].Error.Message).To(Equal("something wrong")) + + // TODO: empty error is not ok, must at least contain code and message + /*responseBody = `[{ "error": {}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something",1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(BeNil()) + Expect(res[0].Error).NotTo(BeNil())*/ /* + + // TODO: only code in error is not ok, must at least contain code and message + */ /*responseBody = `[{ "error": {"code": 123}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something",1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(BeNil()) + Expect(res[0].Error).NotTo(BeNil())*/ /* + + // TODO: only message in error is not ok, must at least contain code and message + */ /*responseBody = `[{ "error": {"message": "something wrong"}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something",1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(BeNil()) + Expect(res[0].Error).NotTo(BeNil())*/ + + // error with code and message is ok + responseBody = `[{ "error": {"code": 123, "message": "something wrong"}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Result).To(BeNil()) + Expect(res[0].Error.Code).To(Equal(123)) + Expect(res[0].Error.Message).To(Equal("something wrong")) + + // check results + + // should return int correctly + responseBody = `[{ "result": 1 }]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Error).To(BeNil()) + i, err := res[0].GetInt() + Expect(err).To(BeNil()) + Expect(i).To(Equal(int64(1))) + + // error on wrong type + i = 3 + responseBody = `[{ "result": "notAnInt" }]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res[0].Error).To(BeNil()) + i, err = res[0].GetInt() + Expect(err).NotTo(BeNil()) + Expect(i).To(Equal(int64(0))) + + var p *Person + responseBody = `[{"id":0, "result": {"name": "Alex", "age": 35}}, {"id":2, "result": {"name": "Lena", "age": 2}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + + <-requestChan + Expect(err).To(BeNil()) + + Expect(res[0].Error).To(BeNil()) + Expect(res[0].ID).To(Equal(0)) + + Expect(res[1].Error).To(BeNil()) + Expect(res[1].ID).To(Equal(2)) + + err = res[0].GetObject(&p) + Expect(p.Name).To(Equal("Alex")) + Expect(p.Age).To(Equal(35)) + + err = res[1].GetObject(&p) + Expect(p.Name).To(Equal("Lena")) + Expect(p.Age).To(Equal(2)) + + // check if error occurred + responseBody = `[{ "result": "someresult", "error": null}, { "result": null, "error": {"code": 123, "message": "something wrong"}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.HasError()).To(BeTrue()) + + // check if error occurred + responseBody = `[{ "result": null, "error": {"code": 123, "message": "something wrong"}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.HasError()).To(BeTrue()) + // check if error occurred + responseBody = `[{ "result": null, "error": {"code": 123, "message": "something wrong"}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.HasError()).To(BeTrue()) + + // check if response mapping works + responseBody = `[{ "id":123,"result": 123},{ "id":1,"result": 1}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.HasError()).To(BeFalse()) + resMap := res.AsMap() + + int1, _ := resMap[1].GetInt() + int123, _ := resMap[123].GetInt() + Expect(int1).To(Equal(int64(1))) + Expect(int123).To(Equal(int64(123))) + + // check if getByID works + int123, _ = res.GetByID(123).GetInt() + Expect(int123).To(Equal(int64(123))) + + // check if error occurred + responseBody = `[{ "result": null, "error": {"code": 123, "message": "something wrong"}}]` + res, err = rpcClient.CallBatch(RPCRequests{ + NewRequest("something", 1, 2, 3), + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.HasError()).To(BeTrue()) + + /* + // TODO: How to check if result could be parsed or if it is default? + p = nil + responseBody = `{ "result": {"anotherField": "something"} }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p) + Expect(err).To(BeNil()) + Expect(p).NotTo(BeNil()) + + // TODO: HERE###### + var pp *PointerFieldPerson + responseBody = `{ "result": {"anotherField": "something", "country": "Germany"} }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&pp) + Expect(err).To(BeNil()) + Expect(pp.Name).To(BeNil()) + Expect(pp.Age).To(BeNil()) + Expect(*pp.Country).To(Equal("Germany")) + + p = nil + responseBody = `{ "result": null }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p) + Expect(err).To(BeNil()) + Expect(p).To(BeNil()) + + // passing nil is an error + p = nil + responseBody = `{ "result": null }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(p) + Expect(err).NotTo(BeNil()) + Expect(p).To(BeNil()) + + p2 := &Person{ + Name: "Alex", + } + responseBody = `{ "result": null }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p2) + Expect(err).To(BeNil()) + Expect(p2).To(BeNil()) + + p2 = &Person{ + Name: "Alex", + } + responseBody = `{ "result": {"age": 35} }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(p2) + Expect(err).To(BeNil()) + Expect(p2.Name).To(Equal("Alex")) + Expect(p2.Age).To(Equal(35)) + + // prefilled struct is kept on no result + p3 := Person{ + Name: "Alex", + } + responseBody = `{ "result": null }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p3) + Expect(err).To(BeNil()) + Expect(p3.Name).To(Equal("Alex")) + + // prefilled struct is extended / overwritten + p3 = Person{ + Name: "Alex", + Age: 123, + } + responseBody = `{ "result": {"age": 35, "country": "Germany"} }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(&p3) + Expect(err).To(BeNil()) + Expect(p3.Name).To(Equal("Alex")) + Expect(p3.Age).To(Equal(35)) + Expect(p3.Country).To(Equal("Germany")) + + // nil is an error + responseBody = `{ "result": {"age": 35} }` + res, err = rpcClient.CallBatch(RPCRequests{ + {"something", Params(1, 2, 3)}, + }) + <-requestChan + Expect(err).To(BeNil()) + Expect(res.Error).To(BeNil()) + err = res.GetObject(nil) + Expect(err).NotTo(BeNil()) + */ +} + +func TestRpcClient_CallFor(t *testing.T) { + RegisterTestingT(t) + rpcClient := NewClient(httpServer.URL) + + i := 0 + responseBody = `{"result":3,"id":0,"jsonrpc":"2.0"}` + err := rpcClient.CallFor(&i, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(i).To(Equal(3)) + + /* + i = 3 + responseBody = `{"result":null,"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&i, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // i is not modified when result is empty since null (nil) value cannot be stored in int + Expect(i).To(Equal(3)) + + var pi *int + responseBody = `{"result":4,"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(pi, "something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + Expect(pi).To(BeNil()) + + responseBody = `{"result":4,"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&pi, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + Expect(*pi).To(Equal(4)) + + *pi = 3 + responseBody = `{"result":null,"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&pi, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // since pi has a value it is not overwritten by null result + Expect(pi).To(BeNil()) + + p := &Person{} + responseBody = `{"result":null,"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(p, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // p is not changed since it has a value and result is null + Expect(p).NotTo(BeNil()) + + var p2 *Person + responseBody = `{"result":null,"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(p2, "something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + // p is not changed since it has a value and result is null + Expect(p2).To(BeNil()) + + p3 := Person{} + responseBody = `{"result":null,"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&p3, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // p is not changed since it has a value and result is null + Expect(p).NotTo(BeNil()) + + p = &Person{Age: 35} + responseBody = `{"result":{"name":"Alex"},"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(p, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // p is not changed since it has a value and result is null + Expect(p.Name).To(Equal("Alex")) + Expect(p.Age).To(Equal(35)) + + p2 = nil + responseBody = `{"result":{"name":"Alex"},"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(p2, "something", 1, 2, 3) + <-requestChan + Expect(err).NotTo(BeNil()) + // p is not changed since it has a value and result is null + Expect(p2).To(BeNil()) + + p2 = nil + responseBody = `{"result":{"name":"Alex"},"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&p2, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // p is not changed since it has a value and result is null + Expect(p2).NotTo(BeNil()) + Expect(p2.Name).To(Equal("Alex")) + + p3 = Person{Age: 35} + responseBody = `{"result":{"name":"Alex"},"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&p3, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // p is not changed since it has a value and result is null + Expect(p.Name).To(Equal("Alex")) + Expect(p.Age).To(Equal(35)) + + p3 = Person{Age: 35} + responseBody = `{"result":{"name":"Alex"},"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&p3, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // p is not changed since it has a value and result is null + Expect(p.Name).To(Equal("Alex")) + Expect(p.Age).To(Equal(35)) + + var intArray []int + responseBody = `{"result":[1, 2, 3],"id":0,"jsonrpc":"2.0"}` + err = rpcClient.CallFor(&intArray, "something", 1, 2, 3) + <-requestChan + Expect(err).To(BeNil()) + // p is not changed since it has a value and result is null + Expect(intArray).To(ContainElement(1)) + Expect(intArray).To(ContainElement(2)) + Expect(intArray).To(ContainElement(3))*/ } type Person struct { @@ -474,30 +1133,23 @@ type Person struct { Country string `json:"country"` } -func TestReadmeExamples(t *testing.T) { - gomega.RegisterTestingT(t) - - rpcClient := NewRPCClient(httpServer.URL) - rpcClient.SetAutoIncrementID(false) - - rpcClient.Call("getDate") - body := (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"getDate","id":0}`)) - - rpcClient.Call("addNumbers", 1, 2) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"addNumbers","params":[1,2],"id":0}`)) - - rpcClient.Call("createPerson", "Alex", 33, "Germany") - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"createPerson","params":["Alex",33,"Germany"],"id":0}`)) - - rpcClient.Call("createPerson", Person{"Alex", 33, "Germany"}) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"createPerson","params":[{"name":"Alex","age":33,"country":"Germany"}],"id":0}`)) - - rpcClient.Call("createPersonsWithRole", []Person{{"Alex", 33, "Germany"}, {"Barney", 38, "Germany"}}, []string{"Admin", "User"}) - body = (<-requestChan).body - gomega.Expect(body).To(gomega.Equal(`{"jsonrpc":"2.0","method":"createPersonsWithRole","params":[[{"name":"Alex","age":33,"country":"Germany"},{"name":"Barney","age":38,"country":"Germany"}],["Admin","User"]],"id":0}`)) - +type PointerFieldPerson struct { + Name *string `json:"name"` + Age *int `json:"age"` + Country *string `json:"country"` +} + +type Drink struct { + Name string `json:"name"` + Ingredients []string `json:"ingredients"` +} + +type Planet struct { + Name string `json:"name"` + Properties Properties `json:"properties"` +} + +type Properties struct { + Distance int `json:"distance"` + Color string `json:"color"` } diff --git a/vendor/golang.org/x/crypto/internal/subtle/aliasing.go b/vendor/golang.org/x/crypto/internal/subtle/aliasing.go new file mode 100644 index 0000000..f38797b --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/subtle/aliasing.go @@ -0,0 +1,32 @@ +// Copyright 2018 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build !appengine + +// Package subtle implements functions that are often useful in cryptographic +// code but require careful thought to use correctly. +package subtle // import "golang.org/x/crypto/internal/subtle" + +import "unsafe" + +// AnyOverlap reports whether x and y share memory at any (not necessarily +// corresponding) index. The memory beyond the slice length is ignored. +func AnyOverlap(x, y []byte) bool { + return len(x) > 0 && len(y) > 0 && + uintptr(unsafe.Pointer(&x[0])) <= uintptr(unsafe.Pointer(&y[len(y)-1])) && + uintptr(unsafe.Pointer(&y[0])) <= uintptr(unsafe.Pointer(&x[len(x)-1])) +} + +// InexactOverlap reports whether x and y share memory at any non-corresponding +// index. The memory beyond the slice length is ignored. Note that x and y can +// have different lengths and still not have any inexact overlap. +// +// InexactOverlap can be used to implement the requirements of the crypto/cipher +// AEAD, Block, BlockMode and Stream interfaces. +func InexactOverlap(x, y []byte) bool { + if len(x) == 0 || len(y) == 0 || &x[0] == &y[0] { + return false + } + return AnyOverlap(x, y) +} diff --git a/vendor/golang.org/x/crypto/internal/subtle/aliasing_appengine.go b/vendor/golang.org/x/crypto/internal/subtle/aliasing_appengine.go new file mode 100644 index 0000000..0cc4a8a --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/subtle/aliasing_appengine.go @@ -0,0 +1,35 @@ +// Copyright 2018 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build appengine + +// Package subtle implements functions that are often useful in cryptographic +// code but require careful thought to use correctly. +package subtle // import "golang.org/x/crypto/internal/subtle" + +// This is the Google App Engine standard variant based on reflect +// because the unsafe package and cgo are disallowed. + +import "reflect" + +// AnyOverlap reports whether x and y share memory at any (not necessarily +// corresponding) index. The memory beyond the slice length is ignored. +func AnyOverlap(x, y []byte) bool { + return len(x) > 0 && len(y) > 0 && + reflect.ValueOf(&x[0]).Pointer() <= reflect.ValueOf(&y[len(y)-1]).Pointer() && + reflect.ValueOf(&y[0]).Pointer() <= reflect.ValueOf(&x[len(x)-1]).Pointer() +} + +// InexactOverlap reports whether x and y share memory at any non-corresponding +// index. The memory beyond the slice length is ignored. Note that x and y can +// have different lengths and still not have any inexact overlap. +// +// InexactOverlap can be used to implement the requirements of the crypto/cipher +// AEAD, Block, BlockMode and Stream interfaces. +func InexactOverlap(x, y []byte) bool { + if len(x) == 0 || len(y) == 0 || &x[0] == &y[0] { + return false + } + return AnyOverlap(x, y) +} diff --git a/vendor/golang.org/x/crypto/internal/subtle/aliasing_test.go b/vendor/golang.org/x/crypto/internal/subtle/aliasing_test.go new file mode 100644 index 0000000..a5b62ff --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/subtle/aliasing_test.go @@ -0,0 +1,50 @@ +// Copyright 2018 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package subtle_test + +import ( + "testing" + + "golang.org/x/crypto/internal/subtle" +) + +var a, b [100]byte + +var aliasingTests = []struct { + x, y []byte + anyOverlap, inexactOverlap bool +}{ + {a[:], b[:], false, false}, + {a[:], b[:0], false, false}, + {a[:], b[:50], false, false}, + {a[40:50], a[50:60], false, false}, + {a[40:50], a[60:70], false, false}, + {a[:51], a[50:], true, true}, + {a[:], a[:], true, false}, + {a[:50], a[:60], true, false}, + {a[:], nil, false, false}, + {nil, nil, false, false}, + {a[:], a[:0], false, false}, + {a[:10], a[:10:20], true, false}, + {a[:10], a[5:10:20], true, true}, +} + +func testAliasing(t *testing.T, i int, x, y []byte, anyOverlap, inexactOverlap bool) { + any := subtle.AnyOverlap(x, y) + if any != anyOverlap { + t.Errorf("%d: wrong AnyOverlap result, expected %v, got %v", i, anyOverlap, any) + } + inexact := subtle.InexactOverlap(x, y) + if inexact != inexactOverlap { + t.Errorf("%d: wrong InexactOverlap result, expected %v, got %v", i, inexactOverlap, any) + } +} + +func TestAliasing(t *testing.T) { + for i, tt := range aliasingTests { + testAliasing(t, i, tt.x, tt.y, tt.anyOverlap, tt.inexactOverlap) + testAliasing(t, i, tt.y, tt.x, tt.anyOverlap, tt.inexactOverlap) + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/README.md b/vendor/golang.org/x/crypto/internal/wycheproof/README.md new file mode 100644 index 0000000..8ae6c6c --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/README.md @@ -0,0 +1,12 @@ +This package runs a set of the Wycheproof tests provided by +https://github.com/google/wycheproof. + +The JSON test files live in +https://github.com/google/wycheproof/tree/master/testvectors +and are being fetched and cached at a pinned version every time +these tests are run. To change the version of the wycheproof +repository that is being used for testing, update wycheproofModVer. + +The structs for these tests are generated from the +schemas provided in https://github.com/google/wycheproof/tree/master/schemas +using https://github.com/a-h/generate. \ No newline at end of file diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/aead_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/aead_test.go new file mode 100644 index 0000000..292d854 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/aead_test.go @@ -0,0 +1,176 @@ +// Copyright 2020 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "bytes" + "crypto/aes" + "crypto/cipher" + "fmt" + "testing" + + "golang.org/x/crypto/chacha20poly1305" +) + +func TestAEAD(t *testing.T) { + // AeadTestVector + type AeadTestVector struct { + + // additional authenticated data + Aad string `json:"aad,omitempty"` + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // the ciphertext (without iv and tag) + Ct string `json:"ct,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // the nonce + Iv string `json:"iv,omitempty"` + + // the key + Key string `json:"key,omitempty"` + + // the plaintext + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // the authentication tag + Tag string `json:"tag,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // AeadTestGroup + type AeadTestGroup struct { + + // the IV size in bits + IvSize int `json:"ivSize,omitempty"` + + // the keySize in bits + KeySize int `json:"keySize,omitempty"` + + // the expected size of the tag in bits + TagSize int `json:"tagSize,omitempty"` + Tests []*AeadTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*AeadTestGroup `json:"testGroups,omitempty"` + } + + testSealOpen := func(t *testing.T, aead cipher.AEAD, tv *AeadTestVector, recoverBadNonce func()) { + defer recoverBadNonce() + + iv, tag, ct, msg, aad := decodeHex(tv.Iv), decodeHex(tv.Tag), decodeHex(tv.Ct), decodeHex(tv.Msg), decodeHex(tv.Aad) + + genCT := aead.Seal(nil, iv, msg, aad) + genMsg, err := aead.Open(nil, iv, genCT, aad) + if err != nil { + t.Errorf("failed to decrypt generated ciphertext: %s", err) + } + if !bytes.Equal(genMsg, msg) { + t.Errorf("unexpected roundtripped plaintext: got %x, want %x", genMsg, msg) + } + + ctWithTag := append(ct, tag...) + msg2, err := aead.Open(nil, iv, ctWithTag, aad) + wantPass := shouldPass(tv.Result, tv.Flags, nil) + if !wantPass && err == nil { + t.Error("decryption succeeded when it should've failed") + } else if wantPass { + if err != nil { + t.Fatalf("decryption failed: %s", err) + } + if !bytes.Equal(genCT, ctWithTag) { + t.Errorf("generated ciphertext doesn't match expected: got %x, want %x", genCT, ctWithTag) + } + if !bytes.Equal(msg, msg2) { + t.Errorf("decrypted ciphertext doesn't match expected: got %x, want %x", msg2, msg) + } + } + } + + vectors := map[string]func(*testing.T, []byte) cipher.AEAD{ + "aes_gcm_test.json": func(t *testing.T, key []byte) cipher.AEAD { + aesCipher, err := aes.NewCipher(key) + if err != nil { + t.Fatalf("failed to construct cipher: %s", err) + } + aead, err := cipher.NewGCM(aesCipher) + if err != nil { + t.Fatalf("failed to construct cipher: %s", err) + } + return aead + }, + "chacha20_poly1305_test.json": func(t *testing.T, key []byte) cipher.AEAD { + aead, err := chacha20poly1305.New(key) + if err != nil { + t.Fatalf("failed to construct cipher: %s", err) + } + return aead + }, + "xchacha20_poly1305_test.json": func(t *testing.T, key []byte) cipher.AEAD { + aead, err := chacha20poly1305.NewX(key) + if err != nil { + t.Fatalf("failed to construct cipher: %s", err) + } + return aead + }, + } + for file, cipherInit := range vectors { + var root Root + readTestVector(t, file, &root) + for _, tg := range root.TestGroups { + for _, tv := range tg.Tests { + testName := fmt.Sprintf("%s #%d", file, tv.TcId) + if tv.Comment != "" { + testName += fmt.Sprintf(" %s", tv.Comment) + } + t.Run(testName, func(t *testing.T) { + aead := cipherInit(t, decodeHex(tv.Key)) + testSealOpen(t, aead, tv, func() { + // A bad nonce causes a panic in AEAD.Seal and AEAD.Open, + // so should be recovered. Fail the test if it broke for + // some other reason. + if r := recover(); r != nil { + if tg.IvSize/8 == aead.NonceSize() { + t.Error("unexpected panic") + } + } + }) + }) + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/aes_cbc_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/aes_cbc_test.go new file mode 100644 index 0000000..0a60fc3 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/aes_cbc_test.go @@ -0,0 +1,127 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "crypto/aes" + "crypto/cipher" + "encoding/hex" + "fmt" + "testing" +) + +func TestAesCbc(t *testing.T) { + // IndCpaTestVector + type IndCpaTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // the raw ciphertext (without IV) + Ct string `json:"ct,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // the initialization vector + Iv string `json:"iv,omitempty"` + + // the key + Key string `json:"key,omitempty"` + + // the plaintext + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // IndCpaTestGroup + type IndCpaTestGroup struct { + + // the IV size in bits + IvSize int `json:"ivSize,omitempty"` + + // the keySize in bits + KeySize int `json:"keySize,omitempty"` + + // the expected size of the tag in bits + TagSize int `json:"tagSize,omitempty"` + Tests []*IndCpaTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*IndCpaTestGroup `json:"testGroups,omitempty"` + } + + var root Root + readTestVector(t, "aes_cbc_pkcs5_test.json", &root) + for _, tg := range root.TestGroups { + tests: + for _, tv := range tg.Tests { + block, err := aes.NewCipher(decodeHex(tv.Key)) + if err != nil { + t.Fatalf("#%d: %v", tv.TcId, err) + } + mode := cipher.NewCBCDecrypter(block, decodeHex(tv.Iv)) + ct := decodeHex(tv.Ct) + if len(ct)%aes.BlockSize != 0 { + panic(fmt.Sprintf("#%d: ciphertext is not a multiple of the block size", tv.TcId)) + } + mode.CryptBlocks(ct, ct) // decrypt the block in place + + // Skip the tests that are broken due to bad padding. Panic if there are any + // tests left that are invalid for some other reason in the future, to + // evaluate what to do with those tests. + for _, flag := range tv.Flags { + if flag == "BadPadding" { + continue tests + } + } + if !shouldPass(tv.Result, tv.Flags, nil) { + panic(fmt.Sprintf("#%d: found an invalid test that is broken for some reason other than bad padding", tv.TcId)) + } + + // Remove the PKCS#5 padding from the given ciphertext to validate it + padding := ct[len(ct)-1] + paddingNum := int(padding) + for i := paddingNum; i > 0; i-- { + if ct[len(ct)-i] != padding { // panic if the padding is unexpectedly bad + panic(fmt.Sprintf("#%d: bad padding at index=%d of %v", tv.TcId, i, ct)) + } + } + ct = ct[:len(ct)-paddingNum] + + if got, want := hex.EncodeToString(ct), tv.Msg; got != want { + t.Errorf("#%d, type: %s, comment: %q, decoded ciphertext not equal: %s, want %s", tv.TcId, tv.Result, tv.Comment, got, want) + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/dsa_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/dsa_test.go new file mode 100644 index 0000000..e554708 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/dsa_test.go @@ -0,0 +1,123 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "crypto/dsa" + "testing" + + wdsa "golang.org/x/crypto/internal/wycheproof/internal/dsa" +) + +func TestDsa(t *testing.T) { + // AsnSignatureTestVector + type AsnSignatureTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // The message to sign + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // An ASN encoded signature for msg + Sig string `json:"sig,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // DsaPublicKey + type DsaPublicKey struct { + + // the generator of the multiplicative subgroup + G string `json:"g,omitempty"` + + // the key size in bits + KeySize int `json:"keySize,omitempty"` + + // the modulus p + P string `json:"p,omitempty"` + + // the order of the generator g + Q string `json:"q,omitempty"` + + // the key type + Type string `json:"type,omitempty"` + + // the public key value + Y string `json:"y,omitempty"` + } + + // DsaTestGroup + type DsaTestGroup struct { + + // unenocded DSA public key + Key *DsaPublicKey `json:"key,omitempty"` + + // DER encoded public key + KeyDer string `json:"keyDer,omitempty"` + + // Pem encoded public key + KeyPem string `json:"keyPem,omitempty"` + + // the hash function used for DSA + Sha string `json:"sha,omitempty"` + Tests []*AsnSignatureTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*DsaTestGroup `json:"testGroups,omitempty"` + } + + flagsShouldPass := map[string]bool{ + // An encoded ASN.1 integer missing a leading zero is invalid, but accepted by some implementations. + "NoLeadingZero": false, + } + + var root Root + readTestVector(t, "dsa_test.json", &root) + for _, tg := range root.TestGroups { + pub := decodePublicKey(tg.KeyDer).(*dsa.PublicKey) + h := parseHash(tg.Sha).New() + for _, sig := range tg.Tests { + h.Reset() + h.Write(decodeHex(sig.Msg)) + hashed := h.Sum(nil) + hashed = hashed[:pub.Q.BitLen()/8] // Truncate to the byte-length of the subgroup (Q) + got := wdsa.VerifyASN1(pub, hashed, decodeHex(sig.Sig)) + if want := shouldPass(sig.Result, sig.Flags, flagsShouldPass); got != want { + t.Errorf("tcid: %d, type: %s, comment: %q, wanted success: %t", sig.TcId, sig.Result, sig.Comment, want) + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_compat_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_compat_test.go new file mode 100644 index 0000000..8edc10b --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_compat_test.go @@ -0,0 +1,33 @@ +// Copyright 2020 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build !go1.15 + +// ecdsa.VerifyASN1 was added in Go 1.15. + +package wycheproof + +import ( + "crypto/ecdsa" + "math/big" + + "golang.org/x/crypto/cryptobyte" + "golang.org/x/crypto/cryptobyte/asn1" +) + +func verifyASN1(pub *ecdsa.PublicKey, hash, sig []byte) bool { + var ( + r, s = &big.Int{}, &big.Int{} + inner cryptobyte.String + ) + input := cryptobyte.String(sig) + if !input.ReadASN1(&inner, asn1.SEQUENCE) || + !input.Empty() || + !inner.ReadASN1Integer(r) || + !inner.ReadASN1Integer(s) || + !inner.Empty() { + return false + } + return ecdsa.Verify(pub, hash, r, s) +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_go115_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_go115_test.go new file mode 100644 index 0000000..8da3be5 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_go115_test.go @@ -0,0 +1,15 @@ +// Copyright 2020 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build go1.15 + +package wycheproof + +import ( + "crypto/ecdsa" +) + +func verifyASN1(pub *ecdsa.PublicKey, hash, sig []byte) bool { + return ecdsa.VerifyASN1(pub, hash, sig) +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_test.go new file mode 100644 index 0000000..81731f7 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/ecdsa_test.go @@ -0,0 +1,164 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "crypto/ecdsa" + "testing" +) + +func TestEcdsa(t *testing.T) { + // AsnSignatureTestVector + type AsnSignatureTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // The message to sign + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // An ASN encoded signature for msg + Sig string `json:"sig,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // EcPublicKey + type EcPublicKey struct { + + // the EC group used by this public key + Curve interface{} `json:"curve,omitempty"` + + // the key size in bits + KeySize int `json:"keySize,omitempty"` + + // the key type + Type string `json:"type,omitempty"` + + // encoded public key point + Uncompressed string `json:"uncompressed,omitempty"` + + // the x-coordinate of the public key point + Wx string `json:"wx,omitempty"` + + // the y-coordinate of the public key point + Wy string `json:"wy,omitempty"` + } + + // EcUnnamedGroup + type EcUnnamedGroup struct { + + // coefficient a of the elliptic curve equation + A string `json:"a,omitempty"` + + // coefficient b of the elliptic curve equation + B string `json:"b,omitempty"` + + // the x-coordinate of the generator + Gx string `json:"gx,omitempty"` + + // the y-coordinate of the generator + Gy string `json:"gy,omitempty"` + + // the cofactor + H int `json:"h,omitempty"` + + // the order of the generator + N string `json:"n,omitempty"` + + // the order of the underlying field + P string `json:"p,omitempty"` + + // an unnamed EC group over a prime field in Weierstrass form + Type string `json:"type,omitempty"` + } + + // EcdsaTestGroup + type EcdsaTestGroup struct { + + // unenocded EC public key + Key *EcPublicKey `json:"key,omitempty"` + + // DER encoded public key + KeyDer string `json:"keyDer,omitempty"` + + // Pem encoded public key + KeyPem string `json:"keyPem,omitempty"` + + // the hash function used for ECDSA + Sha string `json:"sha,omitempty"` + Tests []*AsnSignatureTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*EcdsaTestGroup `json:"testGroups,omitempty"` + } + + flagsShouldPass := map[string]bool{ + // An encoded ASN.1 integer missing a leading zero is invalid, but accepted by some implementations. + "MissingZero": false, + // A signature using a weaker hash than the EC params is not a security risk, as long as the hash is secure. + // https://www.imperialviolet.org/2014/05/25/strengthmatching.html + "WeakHash": true, + } + + // supportedCurves is a map of all elliptic curves supported + // by crypto/elliptic, which can subsequently be parsed and tested. + supportedCurves := map[string]bool{ + "secp224r1": true, + "secp256r1": true, + "secp384r1": true, + "secp521r1": true, + } + + var root Root + readTestVector(t, "ecdsa_test.json", &root) + for _, tg := range root.TestGroups { + curve := tg.Key.Curve.(string) + if !supportedCurves[curve] { + continue + } + pub := decodePublicKey(tg.KeyDer).(*ecdsa.PublicKey) + h := parseHash(tg.Sha).New() + for _, sig := range tg.Tests { + h.Reset() + h.Write(decodeHex(sig.Msg)) + hashed := h.Sum(nil) + got := verifyASN1(pub, hashed, decodeHex(sig.Sig)) + if want := shouldPass(sig.Result, sig.Flags, flagsShouldPass); got != want { + t.Errorf("tcid: %d, type: %s, comment: %q, wanted success: %t", sig.TcId, sig.Result, sig.Comment, want) + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/eddsa_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/eddsa_test.go new file mode 100644 index 0000000..06c9829 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/eddsa_test.go @@ -0,0 +1,100 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// +build go1.13 + +package wycheproof + +import ( + "testing" + + "golang.org/x/crypto/ed25519" +) + +func TestEddsa(t *testing.T) { + // Jwk the private key in webcrypto format + type Jwk struct { + } + + // Key unencoded key pair + type Key struct { + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // SignatureTestVector + type SignatureTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // The message to sign + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // A signature for msg + Sig string `json:"sig,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // EddsaTestGroup + type EddsaTestGroup struct { + + // the private key in webcrypto format + Jwk *Jwk `json:"jwk,omitempty"` + + // unencoded key pair + Key *Key `json:"key,omitempty"` + + // Asn encoded public key + KeyDer string `json:"keyDer,omitempty"` + + // Pem encoded public key + KeyPem string `json:"keyPem,omitempty"` + Tests []*SignatureTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*EddsaTestGroup `json:"testGroups,omitempty"` + } + + var root Root + readTestVector(t, "eddsa_test.json", &root) + for _, tg := range root.TestGroups { + pub := decodePublicKey(tg.KeyDer).(ed25519.PublicKey) + for _, sig := range tg.Tests { + got := ed25519.Verify(pub, decodeHex(sig.Msg), decodeHex(sig.Sig)) + if want := shouldPass(sig.Result, sig.Flags, nil); got != want { + t.Errorf("tcid: %d, type: %s, comment: %q, wanted success: %t", sig.TcId, sig.Result, sig.Comment, want) + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/hkdf_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/hkdf_test.go new file mode 100644 index 0000000..6b72e2c --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/hkdf_test.go @@ -0,0 +1,111 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "bytes" + "io" + "testing" + + "golang.org/x/crypto/hkdf" +) + +func TestHkdf(t *testing.T) { + + // HkdfTestVector + type HkdfTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // the key (input key material) + Ikm string `json:"ikm,omitempty"` + + // additional information used in the key derivation + Info string `json:"info,omitempty"` + + // the generated bytes (output key material) + Okm string `json:"okm,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // the salt for the key derivation + Salt string `json:"salt,omitempty"` + + // the size of the output in bytes + Size int `json:"size,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // HkdfTestGroup + type HkdfTestGroup struct { + + // the size of the ikm in bits + KeySize int `json:"keySize,omitempty"` + Tests []*HkdfTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*HkdfTestGroup `json:"testGroups,omitempty"` + } + + fileHashAlgorithms := map[string]string{ + "hkdf_sha1_test.json": "SHA-1", + "hkdf_sha256_test.json": "SHA-256", + "hkdf_sha384_test.json": "SHA-384", + "hkdf_sha512_test.json": "SHA-512", + } + + for f := range fileHashAlgorithms { + var root Root + readTestVector(t, f, &root) + for _, tg := range root.TestGroups { + for _, tv := range tg.Tests { + h := parseHash(fileHashAlgorithms[f]).New + hkdf := hkdf.New(h, decodeHex(tv.Ikm), decodeHex(tv.Salt), decodeHex(tv.Info)) + key := make([]byte, tv.Size) + wantPass := shouldPass(tv.Result, tv.Flags, nil) + _, err := io.ReadFull(hkdf, key) + if (err == nil) != wantPass { + t.Errorf("tcid: %d, type: %s, comment: %q, wanted success: %t, got: %v", tv.TcId, tv.Result, tv.Comment, wantPass, err) + } + if err != nil { + continue // don't validate output text if reading failed + } + if got, want := key, decodeHex(tv.Okm); !bytes.Equal(got, want) { + t.Errorf("tcid: %d, type: %s, comment: %q, output bytes don't match", tv.TcId, tv.Result, tv.Comment) + } + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/hmac_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/hmac_test.go new file mode 100644 index 0000000..bcc56f2 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/hmac_test.go @@ -0,0 +1,105 @@ +// Copyright 2020 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "crypto/hmac" + "testing" +) + +func TestHMAC(t *testing.T) { + // MacTestVector + type MacTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // the key + Key string `json:"key,omitempty"` + + // the plaintext + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // the authentication tag + Tag string `json:"tag,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // MacTestGroup + type MacTestGroup struct { + + // the keySize in bits + KeySize int `json:"keySize,omitempty"` + + // the expected size of the tag in bits + TagSize int `json:"tagSize,omitempty"` + Tests []*MacTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*MacTestGroup `json:"testGroups,omitempty"` + } + + fileHashAlgs := map[string]string{ + "hmac_sha1_test.json": "SHA-1", + "hmac_sha224_test.json": "SHA-224", + "hmac_sha256_test.json": "SHA-256", + "hmac_sha384_test.json": "SHA-384", + "hmac_sha512_test.json": "SHA-512", + } + + for f := range fileHashAlgs { + var root Root + readTestVector(t, f, &root) + for _, tg := range root.TestGroups { + h := parseHash(fileHashAlgs[f]) + // Skip test vectors where the tag length does not equal the + // hash length, since crypto/hmac does not support generating + // these truncated tags. + if tg.TagSize/8 != h.Size() { + continue + } + for _, tv := range tg.Tests { + hm := hmac.New(h.New, decodeHex(tv.Key)) + hm.Write(decodeHex(tv.Msg)) + tag := hm.Sum(nil) + got := hmac.Equal(decodeHex(tv.Tag), tag) + if want := shouldPass(tv.Result, tv.Flags, nil); want != got { + t.Errorf("%s, tcid: %d, type: %s, comment: %q, unexpected result", f, tv.TcId, tv.Result, tv.Comment) + } + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/internal/dsa/dsa.go b/vendor/golang.org/x/crypto/internal/wycheproof/internal/dsa/dsa.go new file mode 100644 index 0000000..3101dfc --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/internal/dsa/dsa.go @@ -0,0 +1,33 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package dsa provides an internal version of dsa.Verify +// that is used for the Wycheproof tests. +package dsa + +import ( + "crypto/dsa" + "math/big" + + "golang.org/x/crypto/cryptobyte" + "golang.org/x/crypto/cryptobyte/asn1" +) + +// VerifyASN1 verifies the ASN1 encoded signature, sig, of hash using the +// public key, pub. Its return value records whether the signature is valid. +func VerifyASN1(pub *dsa.PublicKey, hash, sig []byte) bool { + var ( + r, s = &big.Int{}, &big.Int{} + inner cryptobyte.String + ) + input := cryptobyte.String(sig) + if !input.ReadASN1(&inner, asn1.SEQUENCE) || + !input.Empty() || + !inner.ReadASN1Integer(r) || + !inner.ReadASN1Integer(s) || + !inner.Empty() { + return false + } + return dsa.Verify(pub, hash, r, s) +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/rsa_pss_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/rsa_pss_test.go new file mode 100644 index 0000000..fc8fa0e --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/rsa_pss_test.go @@ -0,0 +1,164 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "crypto/rsa" + "testing" +) + +func TestRsaPss(t *testing.T) { + // KeyJwk Public key in JWK format + type KeyJwk struct { + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // SignatureTestVector + type SignatureTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // The message to sign + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // A signature for msg + Sig string `json:"sig,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // RsassaPkcs1TestGroup + type RsassaPkcs1TestGroup struct { + + // The private exponent + D string `json:"d,omitempty"` + + // The public exponent + E string `json:"e,omitempty"` + + // ASN encoding of the sequence [n, e] + KeyAsn string `json:"keyAsn,omitempty"` + + // ASN encoding of the public key + KeyDer string `json:"keyDer,omitempty"` + + // Public key in JWK format + KeyJwk *KeyJwk `json:"keyJwk,omitempty"` + + // Pem encoded public key + KeyPem string `json:"keyPem,omitempty"` + + // the size of the modulus in bits + KeySize int `json:"keySize,omitempty"` + + // The modulus of the key + N string `json:"n,omitempty"` + + // The salt length + SLen int `json:"sLen,omitempty"` + + // the hash function used for the message + Sha string `json:"sha,omitempty"` + Tests []*SignatureTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*RsassaPkcs1TestGroup `json:"testGroups,omitempty"` + } + + flagsShouldPass := map[string]bool{ + // A signature using a weaker hash than the EC params is not a security risk, as long as the hash is secure. + // https://www.imperialviolet.org/2014/05/25/strengthmatching.html + "WeakHash": true, + } + + // filesOverrideToPassZeroSLen is a map of all test files + // and which TcIds that should be overriden to pass if the + // rsa.PSSOptions.SaltLength is zero. + // These tests expect a failure with a PSSOptions.SaltLength: 0 + // and a signature that uses a different salt length. However, + // a salt length of 0 is defined as rsa.PSSSaltLengthAuto which + // works deterministically to auto-detect the length when + // verifying, so these tests actually pass as they should. + filesOverrideToPassZeroSLen := map[string][]int{ + "rsa_pss_2048_sha1_mgf1_20_test.json": []int{46, 47}, + "rsa_pss_2048_sha256_mgf1_0_test.json": []int{67, 68}, + "rsa_pss_2048_sha256_mgf1_32_test.json": []int{67, 68}, + "rsa_pss_2048_sha512_256_mgf1_28_test.json": []int{13, 14, 15}, + "rsa_pss_2048_sha512_256_mgf1_32_test.json": []int{13, 14}, + "rsa_pss_3072_sha256_mgf1_32_test.json": []int{67, 68}, + "rsa_pss_4096_sha256_mgf1_32_test.json": []int{67, 68}, + "rsa_pss_4096_sha512_mgf1_32_test.json": []int{136, 137}, + // "rsa_pss_misc_test.json": nil, // TODO: This ones seems to be broken right now, but can enable later on. + } + + for f := range filesOverrideToPassZeroSLen { + var root Root + readTestVector(t, f, &root) + for _, tg := range root.TestGroups { + pub := decodePublicKey(tg.KeyDer).(*rsa.PublicKey) + ch := parseHash(tg.Sha) + h := ch.New() + opts := &rsa.PSSOptions{ + Hash: ch, + SaltLength: rsa.PSSSaltLengthAuto, + } + // Run all the tests twice: the first time with the salt length + // as PSSSaltLengthAuto, and the second time with the salt length + // explictily set to tg.SLen. + for i := 0; i < 2; i++ { + for _, sig := range tg.Tests { + h.Reset() + h.Write(decodeHex(sig.Msg)) + hashed := h.Sum(nil) + err := rsa.VerifyPSS(pub, ch, hashed, decodeHex(sig.Sig), opts) + want := shouldPass(sig.Result, sig.Flags, flagsShouldPass) + if opts.SaltLength == 0 { + for _, id := range filesOverrideToPassZeroSLen[f] { + if sig.TcId == id { + want = true + break + } + } + } + if (err == nil) != want { + t.Errorf("file: %v, tcid: %d, type: %s, opts.SaltLength: %v, comment: %q, wanted success: %t", f, sig.TcId, sig.Result, opts.SaltLength, sig.Comment, want) + } + } + // Update opts.SaltLength for the second run of the tests. + opts.SaltLength = tg.SLen + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/rsa_signature_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/rsa_signature_test.go new file mode 100644 index 0000000..3c31c22 --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/rsa_signature_test.go @@ -0,0 +1,123 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package wycheproof + +import ( + "crypto/rsa" + "testing" +) + +func TestRsa(t *testing.T) { + // KeyJwk Public key in JWK format + type KeyJwk struct { + } + + // Notes a description of the labels used in the test vectors + type Notes struct { + } + + // SignatureTestVector + type SignatureTestVector struct { + + // A brief description of the test case + Comment string `json:"comment,omitempty"` + + // A list of flags + Flags []string `json:"flags,omitempty"` + + // The message to sign + Msg string `json:"msg,omitempty"` + + // Test result + Result string `json:"result,omitempty"` + + // A signature for msg + Sig string `json:"sig,omitempty"` + + // Identifier of the test case + TcId int `json:"tcId,omitempty"` + } + + // RsassaPkcs1TestGroup + type RsassaPkcs1TestGroup struct { + + // The private exponent + D string `json:"d,omitempty"` + + // The public exponent + E string `json:"e,omitempty"` + + // ASN encoding of the sequence [n, e] + KeyAsn string `json:"keyAsn,omitempty"` + + // ASN encoding of the public key + KeyDer string `json:"keyDer,omitempty"` + + // Public key in JWK format + KeyJwk *KeyJwk `json:"keyJwk,omitempty"` + + // Pem encoded public key + KeyPem string `json:"keyPem,omitempty"` + + // the size of the modulus in bits + KeySize int `json:"keySize,omitempty"` + + // The modulus of the key + N string `json:"n,omitempty"` + + // the hash function used for the message + Sha string `json:"sha,omitempty"` + Tests []*SignatureTestVector `json:"tests,omitempty"` + Type interface{} `json:"type,omitempty"` + } + + // Root + type Root struct { + + // the primitive tested in the test file + Algorithm string `json:"algorithm,omitempty"` + + // the version of the test vectors. + GeneratorVersion string `json:"generatorVersion,omitempty"` + + // additional documentation + Header []string `json:"header,omitempty"` + + // a description of the labels used in the test vectors + Notes *Notes `json:"notes,omitempty"` + + // the number of test vectors in this test + NumberOfTests int `json:"numberOfTests,omitempty"` + Schema interface{} `json:"schema,omitempty"` + TestGroups []*RsassaPkcs1TestGroup `json:"testGroups,omitempty"` + } + + flagsShouldPass := map[string]bool{ + // Omitting the parameter field in an ASN encoded integer is a legacy behavior. + "MissingNull": false, + // Keys with a modulus less than 2048 bits are supported by crypto/rsa. + "SmallModulus": true, + // Small public keys are supported by crypto/rsa. + "SmallPublicKey": true, + } + + var root Root + readTestVector(t, "rsa_signature_test.json", &root) + for _, tg := range root.TestGroups { + pub := decodePublicKey(tg.KeyDer).(*rsa.PublicKey) + ch := parseHash(tg.Sha) + h := ch.New() + for _, sig := range tg.Tests { + h.Reset() + h.Write(decodeHex(sig.Msg)) + hashed := h.Sum(nil) + err := rsa.VerifyPKCS1v15(pub, ch, hashed, decodeHex(sig.Sig)) + want := shouldPass(sig.Result, sig.Flags, flagsShouldPass) + if (err == nil) != want { + t.Errorf("tcid: %d, type: %s, comment: %q, wanted success: %t", sig.TcId, sig.Result, sig.Comment, want) + } + } + } +} diff --git a/vendor/golang.org/x/crypto/internal/wycheproof/wycheproof_test.go b/vendor/golang.org/x/crypto/internal/wycheproof/wycheproof_test.go new file mode 100644 index 0000000..983ba5c --- /dev/null +++ b/vendor/golang.org/x/crypto/internal/wycheproof/wycheproof_test.go @@ -0,0 +1,134 @@ +// Copyright 2019 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Package wycheproof runs a set of the Wycheproof tests +// provided by https://github.com/google/wycheproof. +package wycheproof + +import ( + "crypto" + "crypto/x509" + "encoding/hex" + "encoding/json" + "fmt" + "io/ioutil" + "log" + "os" + "os/exec" + "path/filepath" + "testing" + + _ "crypto/sha1" + _ "crypto/sha256" + _ "crypto/sha512" +) + +const wycheproofModVer = "v0.0.0-20191219022705-2196000605e4" + +var wycheproofTestVectorsDir string + +func TestMain(m *testing.M) { + if _, err := exec.LookPath("go"); err != nil { + log.Printf("skipping test because 'go' command is unavailable: %v", err) + os.Exit(0) + } + + // Download the JSON test files from github.com/google/wycheproof + // using `go mod download -json` so the cached source of the testdata + // can be used in the following tests. + path := "github.com/google/wycheproof@" + wycheproofModVer + cmd := exec.Command("go", "mod", "download", "-json", path) + // TODO: enable the sumdb once the Trybots proxy supports it. + cmd.Env = append(os.Environ(), "GONOSUMDB=*") + output, err := cmd.Output() + if err != nil { + log.Fatalf("failed to run `go mod download -json %s`, output: %s", path, output) + } + var dm struct { + Dir string // absolute path to cached source root directory + } + if err := json.Unmarshal(output, &dm); err != nil { + log.Fatal(err) + } + // Now that the module has been downloaded, use the absolute path of the + // cached source as the root directory for all tests going forward. + wycheproofTestVectorsDir = filepath.Join(dm.Dir, "testvectors") + os.Exit(m.Run()) +} + +func readTestVector(t *testing.T, f string, dest interface{}) { + b, err := ioutil.ReadFile(filepath.Join(wycheproofTestVectorsDir, f)) + if err != nil { + t.Fatalf("failed to read json file: %v", err) + } + if err := json.Unmarshal(b, &dest); err != nil { + t.Fatalf("failed to unmarshal json file: %v", err) + } +} + +func decodeHex(s string) []byte { + b, err := hex.DecodeString(s) + if err != nil { + panic(err) + } + return b +} + +func decodePublicKey(der string) interface{} { + d := decodeHex(der) + pub, err := x509.ParsePKIXPublicKey(d) + if err != nil { + panic(fmt.Sprintf("failed to parse DER encoded public key: %v", err)) + } + return pub +} + +func parseHash(h string) crypto.Hash { + switch h { + case "SHA-1": + return crypto.SHA1 + case "SHA-256": + return crypto.SHA256 + case "SHA-224": + return crypto.SHA224 + case "SHA-384": + return crypto.SHA384 + case "SHA-512": + return crypto.SHA512 + case "SHA-512/224": + return crypto.SHA512_224 + case "SHA-512/256": + return crypto.SHA512_256 + default: + panic(fmt.Sprintf("could not identify SHA hash algorithm: %q", h)) + } +} + +// shouldPass returns whether or not the test should pass. +// flagsShouldPass is a map associated with whether or not +// a flag for an "acceptable" result should pass. +// Every possible flag value that's associated with an +// "acceptable" result should be explicitly specified, +// otherwise the test will panic. +func shouldPass(result string, flags []string, flagsShouldPass map[string]bool) bool { + switch result { + case "valid": + return true + case "invalid": + return false + case "acceptable": + for _, flag := range flags { + pass, ok := flagsShouldPass[flag] + if !ok { + panic(fmt.Sprintf("unspecified flag: %q", flag)) + } + if !pass { + return false + } + } + return true // There are no flags, or all are meant to pass. + default: + panic(fmt.Sprintf("unexpected result: %v", result)) + } +} diff --git a/vendor/golang.org/x/tools/.directory b/vendor/golang.org/x/tools/.directory deleted file mode 100644 index db61fb4..0000000 --- a/vendor/golang.org/x/tools/.directory +++ /dev/null @@ -1,6 +0,0 @@ -[Dolphin] -Timestamp=2018,1,11,12,12,46 -Version=3 - -[Settings] -HiddenFilesShown=true diff --git a/vendor/golang.org/x/tools/.gitattributes b/vendor/golang.org/x/tools/.gitattributes deleted file mode 100644 index d2f212e..0000000 --- a/vendor/golang.org/x/tools/.gitattributes +++ /dev/null @@ -1,10 +0,0 @@ -# Treat all files in this repo as binary, with no git magic updating -# line endings. Windows users contributing to Go will need to use a -# modern version of git and editors capable of LF line endings. -# -# We'll prevent accidental CRLF line endings from entering the repo -# via the git-review gofmt checks. -# -# See golang.org/issue/9281 - -* -text diff --git a/vendor/golang.org/x/tools/.gitignore b/vendor/golang.org/x/tools/.gitignore deleted file mode 100644 index 5a9d62e..0000000 --- a/vendor/golang.org/x/tools/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -# Add no patterns to .gitignore except for files generated by the build. -last-change diff --git a/vendor/golang.org/x/tools/AUTHORS b/vendor/golang.org/x/tools/AUTHORS deleted file mode 100644 index 15167cd..0000000 --- a/vendor/golang.org/x/tools/AUTHORS +++ /dev/null @@ -1,3 +0,0 @@ -# This source code refers to The Go Authors for copyright purposes. -# The master list of authors is in the main Go distribution, -# visible at http://tip.golang.org/AUTHORS. diff --git a/vendor/golang.org/x/tools/CONTRIBUTING.md b/vendor/golang.org/x/tools/CONTRIBUTING.md deleted file mode 100644 index 88dff59..0000000 --- a/vendor/golang.org/x/tools/CONTRIBUTING.md +++ /dev/null @@ -1,31 +0,0 @@ -# Contributing to Go - -Go is an open source project. - -It is the work of hundreds of contributors. We appreciate your help! - - -## Filing issues - -When [filing an issue](https://golang.org/issue/new), make sure to answer these five questions: - -1. What version of Go are you using (`go version`)? -2. What operating system and processor architecture are you using? -3. What did you do? -4. What did you expect to see? -5. What did you see instead? - -General questions should go to the [golang-nuts mailing list](https://groups.google.com/group/golang-nuts) instead of the issue tracker. -The gophers there will answer or ask you to file an issue if you've tripped over a bug. - -## Contributing code - -Please read the [Contribution Guidelines](https://golang.org/doc/contribute.html) -before sending patches. - -**We do not accept GitHub pull requests** -(we use [Gerrit](https://code.google.com/p/gerrit/) instead for code review). - -Unless otherwise noted, the Go source files are distributed under -the BSD-style license found in the LICENSE file. - diff --git a/vendor/golang.org/x/tools/CONTRIBUTORS b/vendor/golang.org/x/tools/CONTRIBUTORS deleted file mode 100644 index 1c4577e..0000000 --- a/vendor/golang.org/x/tools/CONTRIBUTORS +++ /dev/null @@ -1,3 +0,0 @@ -# This source code was written by the Go contributors. -# The master list of contributors is in the main Go distribution, -# visible at http://tip.golang.org/CONTRIBUTORS. diff --git a/vendor/golang.org/x/tools/PATENTS b/vendor/golang.org/x/tools/PATENTS deleted file mode 100644 index 7330990..0000000 --- a/vendor/golang.org/x/tools/PATENTS +++ /dev/null @@ -1,22 +0,0 @@ -Additional IP Rights Grant (Patents) - -"This implementation" means the copyrightable works distributed by -Google as part of the Go project. - -Google hereby grants to You a perpetual, worldwide, non-exclusive, -no-charge, royalty-free, irrevocable (except as stated in this section) -patent license to make, have made, use, offer to sell, sell, import, -transfer and otherwise run, modify and propagate the contents of this -implementation of Go, where such license applies only to those patent -claims, both currently owned or controlled by Google and acquired in -the future, licensable by Google that are necessarily infringed by this -implementation of Go. This grant does not include claims that would be -infringed only as a consequence of further modification of this -implementation. If you or your agent or exclusive licensee institute or -order or agree to the institution of patent litigation against any -entity (including a cross-claim or counterclaim in a lawsuit) alleging -that this implementation of Go or any code incorporated within this -implementation of Go constitutes direct or contributory patent -infringement, or inducement of patent infringement, then any patent -rights granted to you under this License for this implementation of Go -shall terminate as of the date such litigation is filed. diff --git a/vendor/golang.org/x/tools/README.md b/vendor/golang.org/x/tools/README.md deleted file mode 100644 index 20be9e1..0000000 --- a/vendor/golang.org/x/tools/README.md +++ /dev/null @@ -1,27 +0,0 @@ -# Go Tools - -This subrepository holds the source for various packages and tools that support -the Go programming language. - -Some of the tools, `godoc` and `vet` for example, are included in binary Go -distributions. - -Others, including the Go `guru` and the test coverage tool, can be fetched with -`go get`. - -Packages include a type-checker for Go and an implementation of the -Static Single Assignment form (SSA) representation for Go programs. - -## Download/Install - -The easiest way to install is to run `go get -u golang.org/x/tools/...`. You can -also manually git clone the repository to `$GOPATH/src/golang.org/x/tools`. - -## Report Issues / Send Patches - -This repository uses Gerrit for code changes. To learn how to submit changes to -this repository, see https://golang.org/doc/contribute.html. - -The main issue tracker for the tools repository is located at -https://github.com/golang/go/issues. Prefix your issue with "x/tools/(your -subdir):" in the subject line, so it is easy to find. diff --git a/vendor/golang.org/x/tools/benchmark/parse/parse.go b/vendor/golang.org/x/tools/benchmark/parse/parse.go deleted file mode 100644 index b37e6f0..0000000 --- a/vendor/golang.org/x/tools/benchmark/parse/parse.go +++ /dev/null @@ -1,131 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package parse provides support for parsing benchmark results as -// generated by 'go test -bench'. -package parse // import "golang.org/x/tools/benchmark/parse" - -import ( - "bufio" - "bytes" - "fmt" - "io" - "strconv" - "strings" -) - -// Flags used by Benchmark.Measured to indicate -// which measurements a Benchmark contains. -const ( - NsPerOp = 1 << iota - MBPerS - AllocedBytesPerOp - AllocsPerOp -) - -// Benchmark is one run of a single benchmark. -type Benchmark struct { - Name string // benchmark name - N int // number of iterations - NsPerOp float64 // nanoseconds per iteration - AllocedBytesPerOp uint64 // bytes allocated per iteration - AllocsPerOp uint64 // allocs per iteration - MBPerS float64 // MB processed per second - Measured int // which measurements were recorded - Ord int // ordinal position within a benchmark run -} - -// ParseLine extracts a Benchmark from a single line of testing.B -// output. -func ParseLine(line string) (*Benchmark, error) { - fields := strings.Fields(line) - - // Two required, positional fields: Name and iterations. - if len(fields) < 2 { - return nil, fmt.Errorf("two fields required, have %d", len(fields)) - } - if !strings.HasPrefix(fields[0], "Benchmark") { - return nil, fmt.Errorf(`first field does not start with "Benchmark"`) - } - n, err := strconv.Atoi(fields[1]) - if err != nil { - return nil, err - } - b := &Benchmark{Name: fields[0], N: n} - - // Parse any remaining pairs of fields; we've parsed one pair already. - for i := 1; i < len(fields)/2; i++ { - b.parseMeasurement(fields[i*2], fields[i*2+1]) - } - return b, nil -} - -func (b *Benchmark) parseMeasurement(quant string, unit string) { - switch unit { - case "ns/op": - if f, err := strconv.ParseFloat(quant, 64); err == nil { - b.NsPerOp = f - b.Measured |= NsPerOp - } - case "MB/s": - if f, err := strconv.ParseFloat(quant, 64); err == nil { - b.MBPerS = f - b.Measured |= MBPerS - } - case "B/op": - if i, err := strconv.ParseUint(quant, 10, 64); err == nil { - b.AllocedBytesPerOp = i - b.Measured |= AllocedBytesPerOp - } - case "allocs/op": - if i, err := strconv.ParseUint(quant, 10, 64); err == nil { - b.AllocsPerOp = i - b.Measured |= AllocsPerOp - } - } -} - -func (b *Benchmark) String() string { - buf := new(bytes.Buffer) - fmt.Fprintf(buf, "%s %d", b.Name, b.N) - if (b.Measured & NsPerOp) != 0 { - fmt.Fprintf(buf, " %.2f ns/op", b.NsPerOp) - } - if (b.Measured & MBPerS) != 0 { - fmt.Fprintf(buf, " %.2f MB/s", b.MBPerS) - } - if (b.Measured & AllocedBytesPerOp) != 0 { - fmt.Fprintf(buf, " %d B/op", b.AllocedBytesPerOp) - } - if (b.Measured & AllocsPerOp) != 0 { - fmt.Fprintf(buf, " %d allocs/op", b.AllocsPerOp) - } - return buf.String() -} - -// Set is a collection of benchmarks from one -// testing.B run, keyed by name to facilitate comparison. -type Set map[string][]*Benchmark - -// ParseSet extracts a Set from testing.B output. -// ParseSet preserves the order of benchmarks that have identical -// names. -func ParseSet(r io.Reader) (Set, error) { - bb := make(Set) - scan := bufio.NewScanner(r) - ord := 0 - for scan.Scan() { - if b, err := ParseLine(scan.Text()); err == nil { - b.Ord = ord - ord++ - bb[b.Name] = append(bb[b.Name], b) - } - } - - if err := scan.Err(); err != nil { - return nil, err - } - - return bb, nil -} diff --git a/vendor/golang.org/x/tools/benchmark/parse/parse_test.go b/vendor/golang.org/x/tools/benchmark/parse/parse_test.go deleted file mode 100644 index 06db848..0000000 --- a/vendor/golang.org/x/tools/benchmark/parse/parse_test.go +++ /dev/null @@ -1,154 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package parse - -import ( - "reflect" - "strings" - "testing" -) - -func TestParseLine(t *testing.T) { - cases := []struct { - line string - want *Benchmark - err bool // expect an error - }{ - { - line: "BenchmarkEncrypt 100000000 19.6 ns/op", - want: &Benchmark{ - Name: "BenchmarkEncrypt", - N: 100000000, NsPerOp: 19.6, - Measured: NsPerOp, - }, - }, - { - line: "BenchmarkEncrypt 100000000 19.6 ns/op 817.77 MB/s", - want: &Benchmark{ - Name: "BenchmarkEncrypt", - N: 100000000, NsPerOp: 19.6, MBPerS: 817.77, - Measured: NsPerOp | MBPerS, - }, - }, - { - line: "BenchmarkEncrypt 100000000 19.6 ns/op 817.77", - want: &Benchmark{ - Name: "BenchmarkEncrypt", - N: 100000000, NsPerOp: 19.6, - Measured: NsPerOp, - }, - }, - { - line: "BenchmarkEncrypt 100000000 19.6 ns/op 817.77 MB/s 5 allocs/op", - want: &Benchmark{ - Name: "BenchmarkEncrypt", - N: 100000000, NsPerOp: 19.6, MBPerS: 817.77, AllocsPerOp: 5, - Measured: NsPerOp | MBPerS | AllocsPerOp, - }, - }, - { - line: "BenchmarkEncrypt 100000000 19.6 ns/op 817.77 MB/s 3 B/op 5 allocs/op", - want: &Benchmark{ - Name: "BenchmarkEncrypt", - N: 100000000, NsPerOp: 19.6, MBPerS: 817.77, AllocedBytesPerOp: 3, AllocsPerOp: 5, - Measured: NsPerOp | MBPerS | AllocedBytesPerOp | AllocsPerOp, - }, - }, - // error handling cases - { - line: "BenchPress 100 19.6 ns/op", // non-benchmark - err: true, - }, - { - line: "BenchmarkEncrypt lots 19.6 ns/op", // non-int iterations - err: true, - }, - { - line: "BenchmarkBridge 100000000 19.6 smoots", // unknown unit - want: &Benchmark{ - Name: "BenchmarkBridge", - N: 100000000, - }, - }, - { - line: "PASS", - err: true, - }, - } - - for _, tt := range cases { - have, err := ParseLine(tt.line) - if tt.err && err == nil { - t.Errorf("parsing line %q should have failed", tt.line) - continue - } - if !reflect.DeepEqual(have, tt.want) { - t.Errorf("parsed line %q incorrectly, want %v have %v", tt.line, tt.want, have) - } - } -} - -func TestParseSet(t *testing.T) { - // Test two things: - // 1. The noise that can accompany testing.B output gets ignored. - // 2. Benchmarks with the same name have their order preserved. - in := ` - ? crypto [no test files] - PASS - pem_decrypt_test.go:17: test 4. %!s(x509.PEMCipher=5) - ... [output truncated] - - BenchmarkEncrypt 100000000 19.6 ns/op - BenchmarkEncrypt 5000000 517 ns/op - === RUN TestChunk - --- PASS: TestChunk (0.00 seconds) - --- SKIP: TestLinuxSendfile (0.00 seconds) - fs_test.go:716: skipping; linux-only test - BenchmarkReadRequestApachebench 1000000 2960 ns/op 27.70 MB/s 839 B/op 9 allocs/op - BenchmarkClientServerParallel64 50000 59192 ns/op 7028 B/op 60 allocs/op - ok net/http 95.783s - ` - - want := Set{ - "BenchmarkReadRequestApachebench": []*Benchmark{ - { - Name: "BenchmarkReadRequestApachebench", - N: 1000000, NsPerOp: 2960, MBPerS: 27.70, AllocedBytesPerOp: 839, AllocsPerOp: 9, - Measured: NsPerOp | MBPerS | AllocedBytesPerOp | AllocsPerOp, - Ord: 2, - }, - }, - "BenchmarkClientServerParallel64": []*Benchmark{ - { - Name: "BenchmarkClientServerParallel64", - N: 50000, NsPerOp: 59192, AllocedBytesPerOp: 7028, AllocsPerOp: 60, - Measured: NsPerOp | AllocedBytesPerOp | AllocsPerOp, - Ord: 3, - }, - }, - "BenchmarkEncrypt": []*Benchmark{ - { - Name: "BenchmarkEncrypt", - N: 100000000, NsPerOp: 19.6, - Measured: NsPerOp, - Ord: 0, - }, - { - Name: "BenchmarkEncrypt", - N: 5000000, NsPerOp: 517, - Measured: NsPerOp, - Ord: 1, - }, - }, - } - - have, err := ParseSet(strings.NewReader(in)) - if err != nil { - t.Fatalf("unexpected err during ParseSet: %v", err) - } - if !reflect.DeepEqual(want, have) { - t.Errorf("parsed bench set incorrectly, want %v have %v", want, have) - } -} diff --git a/vendor/golang.org/x/tools/blog/atom/atom.go b/vendor/golang.org/x/tools/blog/atom/atom.go deleted file mode 100644 index 542c50e..0000000 --- a/vendor/golang.org/x/tools/blog/atom/atom.go +++ /dev/null @@ -1,61 +0,0 @@ -// Copyright 2009 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Adapted from encoding/xml/read_test.go. - -// Package atom defines XML data structures for an Atom feed. -package atom // import "golang.org/x/tools/blog/atom" - -import ( - "encoding/xml" - "time" -) - -type Feed struct { - XMLName xml.Name `xml:"http://www.w3.org/2005/Atom feed"` - Title string `xml:"title"` - ID string `xml:"id"` - Link []Link `xml:"link"` - Updated TimeStr `xml:"updated"` - Author *Person `xml:"author"` - Entry []*Entry `xml:"entry"` -} - -type Entry struct { - Title string `xml:"title"` - ID string `xml:"id"` - Link []Link `xml:"link"` - Published TimeStr `xml:"published"` - Updated TimeStr `xml:"updated"` - Author *Person `xml:"author"` - Summary *Text `xml:"summary"` - Content *Text `xml:"content"` -} - -type Link struct { - Rel string `xml:"rel,attr,omitempty"` - Href string `xml:"href,attr"` - Type string `xml:"type,attr,omitempty"` - HrefLang string `xml:"hreflang,attr,omitempty"` - Title string `xml:"title,attr,omitempty"` - Length uint `xml:"length,attr,omitempty"` -} - -type Person struct { - Name string `xml:"name"` - URI string `xml:"uri,omitempty"` - Email string `xml:"email,omitempty"` - InnerXML string `xml:",innerxml"` -} - -type Text struct { - Type string `xml:"type,attr"` - Body string `xml:",chardata"` -} - -type TimeStr string - -func Time(t time.Time) TimeStr { - return TimeStr(t.Format("2006-01-02T15:04:05-07:00")) -} diff --git a/vendor/golang.org/x/tools/blog/blog.go b/vendor/golang.org/x/tools/blog/blog.go deleted file mode 100644 index 23c8dc6..0000000 --- a/vendor/golang.org/x/tools/blog/blog.go +++ /dev/null @@ -1,424 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package blog implements a web server for articles written in present format. -package blog // import "golang.org/x/tools/blog" - -import ( - "bytes" - "encoding/json" - "encoding/xml" - "fmt" - "html/template" - "log" - "net/http" - "os" - "path/filepath" - "regexp" - "sort" - "strings" - "time" - - "golang.org/x/tools/blog/atom" - "golang.org/x/tools/present" -) - -var validJSONPFunc = regexp.MustCompile(`(?i)^[a-z_][a-z0-9_.]*$`) - -// Config specifies Server configuration values. -type Config struct { - ContentPath string // Relative or absolute location of article files and related content. - TemplatePath string // Relative or absolute location of template files. - - BaseURL string // Absolute base URL (for permalinks; no trailing slash). - BasePath string // Base URL path relative to server root (no trailing slash). - GodocURL string // The base URL of godoc (for menu bar; no trailing slash). - Hostname string // Server host name, used for rendering ATOM feeds. - - HomeArticles int // Articles to display on the home page. - FeedArticles int // Articles to include in Atom and JSON feeds. - FeedTitle string // The title of the Atom XML feed - - PlayEnabled bool -} - -// Doc represents an article adorned with presentation data. -type Doc struct { - *present.Doc - Permalink string // Canonical URL for this document. - Path string // Path relative to server root (including base). - HTML template.HTML // rendered article - - Related []*Doc - Newer, Older *Doc -} - -// Server implements an http.Handler that serves blog articles. -type Server struct { - cfg Config - docs []*Doc - tags []string - docPaths map[string]*Doc // key is path without BasePath. - docTags map[string][]*Doc - template struct { - home, index, article, doc *template.Template - } - atomFeed []byte // pre-rendered Atom feed - jsonFeed []byte // pre-rendered JSON feed - content http.Handler -} - -// NewServer constructs a new Server using the specified config. -func NewServer(cfg Config) (*Server, error) { - present.PlayEnabled = cfg.PlayEnabled - - root := filepath.Join(cfg.TemplatePath, "root.tmpl") - parse := func(name string) (*template.Template, error) { - t := template.New("").Funcs(funcMap) - return t.ParseFiles(root, filepath.Join(cfg.TemplatePath, name)) - } - - s := &Server{cfg: cfg} - - // Parse templates. - var err error - s.template.home, err = parse("home.tmpl") - if err != nil { - return nil, err - } - s.template.index, err = parse("index.tmpl") - if err != nil { - return nil, err - } - s.template.article, err = parse("article.tmpl") - if err != nil { - return nil, err - } - p := present.Template().Funcs(funcMap) - s.template.doc, err = p.ParseFiles(filepath.Join(cfg.TemplatePath, "doc.tmpl")) - if err != nil { - return nil, err - } - - // Load content. - err = s.loadDocs(filepath.Clean(cfg.ContentPath)) - if err != nil { - return nil, err - } - - err = s.renderAtomFeed() - if err != nil { - return nil, err - } - - err = s.renderJSONFeed() - if err != nil { - return nil, err - } - - // Set up content file server. - s.content = http.StripPrefix(s.cfg.BasePath, http.FileServer(http.Dir(cfg.ContentPath))) - - return s, nil -} - -var funcMap = template.FuncMap{ - "sectioned": sectioned, - "authors": authors, -} - -// sectioned returns true if the provided Doc contains more than one section. -// This is used to control whether to display the table of contents and headings. -func sectioned(d *present.Doc) bool { - return len(d.Sections) > 1 -} - -// authors returns a comma-separated list of author names. -func authors(authors []present.Author) string { - var b bytes.Buffer - last := len(authors) - 1 - for i, a := range authors { - if i > 0 { - if i == last { - b.WriteString(" and ") - } else { - b.WriteString(", ") - } - } - b.WriteString(authorName(a)) - } - return b.String() -} - -// authorName returns the first line of the Author text: the author's name. -func authorName(a present.Author) string { - el := a.TextElem() - if len(el) == 0 { - return "" - } - text, ok := el[0].(present.Text) - if !ok || len(text.Lines) == 0 { - return "" - } - return text.Lines[0] -} - -// loadDocs reads all content from the provided file system root, renders all -// the articles it finds, adds them to the Server's docs field, computes the -// denormalized docPaths, docTags, and tags fields, and populates the various -// helper fields (Next, Previous, Related) for each Doc. -func (s *Server) loadDocs(root string) error { - // Read content into docs field. - const ext = ".article" - fn := func(p string, info os.FileInfo, err error) error { - if filepath.Ext(p) != ext { - return nil - } - f, err := os.Open(p) - if err != nil { - return err - } - defer f.Close() - d, err := present.Parse(f, p, 0) - if err != nil { - return err - } - html := new(bytes.Buffer) - err = d.Render(html, s.template.doc) - if err != nil { - return err - } - p = p[len(root) : len(p)-len(ext)] // trim root and extension - p = filepath.ToSlash(p) - s.docs = append(s.docs, &Doc{ - Doc: d, - Path: s.cfg.BasePath + p, - Permalink: s.cfg.BaseURL + p, - HTML: template.HTML(html.String()), - }) - return nil - } - err := filepath.Walk(root, fn) - if err != nil { - return err - } - sort.Sort(docsByTime(s.docs)) - - // Pull out doc paths and tags and put in reverse-associating maps. - s.docPaths = make(map[string]*Doc) - s.docTags = make(map[string][]*Doc) - for _, d := range s.docs { - s.docPaths[strings.TrimPrefix(d.Path, s.cfg.BasePath)] = d - for _, t := range d.Tags { - s.docTags[t] = append(s.docTags[t], d) - } - } - - // Pull out unique sorted list of tags. - for t := range s.docTags { - s.tags = append(s.tags, t) - } - sort.Strings(s.tags) - - // Set up presentation-related fields, Newer, Older, and Related. - for _, doc := range s.docs { - // Newer, Older: docs adjacent to doc - for i := range s.docs { - if s.docs[i] != doc { - continue - } - if i > 0 { - doc.Newer = s.docs[i-1] - } - if i+1 < len(s.docs) { - doc.Older = s.docs[i+1] - } - break - } - - // Related: all docs that share tags with doc. - related := make(map[*Doc]bool) - for _, t := range doc.Tags { - for _, d := range s.docTags[t] { - if d != doc { - related[d] = true - } - } - } - for d := range related { - doc.Related = append(doc.Related, d) - } - sort.Sort(docsByTime(doc.Related)) - } - - return nil -} - -// renderAtomFeed generates an XML Atom feed and stores it in the Server's -// atomFeed field. -func (s *Server) renderAtomFeed() error { - var updated time.Time - if len(s.docs) > 0 { - updated = s.docs[0].Time - } - feed := atom.Feed{ - Title: s.cfg.FeedTitle, - ID: "tag:" + s.cfg.Hostname + ",2013:" + s.cfg.Hostname, - Updated: atom.Time(updated), - Link: []atom.Link{{ - Rel: "self", - Href: s.cfg.BaseURL + "/feed.atom", - }}, - } - for i, doc := range s.docs { - if i >= s.cfg.FeedArticles { - break - } - e := &atom.Entry{ - Title: doc.Title, - ID: feed.ID + doc.Path, - Link: []atom.Link{{ - Rel: "alternate", - Href: doc.Permalink, - }}, - Published: atom.Time(doc.Time), - Updated: atom.Time(doc.Time), - Summary: &atom.Text{ - Type: "html", - Body: summary(doc), - }, - Content: &atom.Text{ - Type: "html", - Body: string(doc.HTML), - }, - Author: &atom.Person{ - Name: authors(doc.Authors), - }, - } - feed.Entry = append(feed.Entry, e) - } - data, err := xml.Marshal(&feed) - if err != nil { - return err - } - s.atomFeed = data - return nil -} - -type jsonItem struct { - Title string - Link string - Time time.Time - Summary string - Content string - Author string -} - -// renderJSONFeed generates a JSON feed and stores it in the Server's jsonFeed -// field. -func (s *Server) renderJSONFeed() error { - var feed []jsonItem - for i, doc := range s.docs { - if i >= s.cfg.FeedArticles { - break - } - item := jsonItem{ - Title: doc.Title, - Link: doc.Permalink, - Time: doc.Time, - Summary: summary(doc), - Content: string(doc.HTML), - Author: authors(doc.Authors), - } - feed = append(feed, item) - } - data, err := json.Marshal(feed) - if err != nil { - return err - } - s.jsonFeed = data - return nil -} - -// summary returns the first paragraph of text from the provided Doc. -func summary(d *Doc) string { - if len(d.Sections) == 0 { - return "" - } - for _, elem := range d.Sections[0].Elem { - text, ok := elem.(present.Text) - if !ok || text.Pre { - // skip everything but non-text elements - continue - } - var buf bytes.Buffer - for _, s := range text.Lines { - buf.WriteString(string(present.Style(s))) - buf.WriteByte('\n') - } - return buf.String() - } - return "" -} - -// rootData encapsulates data destined for the root template. -type rootData struct { - Doc *Doc - BasePath string - GodocURL string - Data interface{} -} - -// ServeHTTP serves the front, index, and article pages -// as well as the ATOM and JSON feeds. -func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) { - var ( - d = rootData{BasePath: s.cfg.BasePath, GodocURL: s.cfg.GodocURL} - t *template.Template - ) - switch p := strings.TrimPrefix(r.URL.Path, s.cfg.BasePath); p { - case "/": - d.Data = s.docs - if len(s.docs) > s.cfg.HomeArticles { - d.Data = s.docs[:s.cfg.HomeArticles] - } - t = s.template.home - case "/index": - d.Data = s.docs - t = s.template.index - case "/feed.atom", "/feeds/posts/default": - w.Header().Set("Content-type", "application/atom+xml; charset=utf-8") - w.Write(s.atomFeed) - return - case "/.json": - if p := r.FormValue("jsonp"); validJSONPFunc.MatchString(p) { - w.Header().Set("Content-type", "application/javascript; charset=utf-8") - fmt.Fprintf(w, "%v(%s)", p, s.jsonFeed) - return - } - w.Header().Set("Content-type", "application/json; charset=utf-8") - w.Write(s.jsonFeed) - return - default: - doc, ok := s.docPaths[p] - if !ok { - // Not a doc; try to just serve static content. - s.content.ServeHTTP(w, r) - return - } - d.Doc = doc - t = s.template.article - } - err := t.ExecuteTemplate(w, "root", d) - if err != nil { - log.Println(err) - } -} - -// docsByTime implements sort.Interface, sorting Docs by their Time field. -type docsByTime []*Doc - -func (s docsByTime) Len() int { return len(s) } -func (s docsByTime) Swap(i, j int) { s[i], s[j] = s[j], s[i] } -func (s docsByTime) Less(i, j int) bool { return s[i].Time.After(s[j].Time) } diff --git a/vendor/golang.org/x/tools/cmd/benchcmp/benchcmp.go b/vendor/golang.org/x/tools/cmd/benchcmp/benchcmp.go deleted file mode 100644 index 32f3a1c..0000000 --- a/vendor/golang.org/x/tools/cmd/benchcmp/benchcmp.go +++ /dev/null @@ -1,184 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package main - -import ( - "flag" - "fmt" - "os" - "sort" - "strconv" - "text/tabwriter" - - "golang.org/x/tools/benchmark/parse" -) - -var ( - changedOnly = flag.Bool("changed", false, "show only benchmarks that have changed") - magSort = flag.Bool("mag", false, "sort benchmarks by magnitude of change") - best = flag.Bool("best", false, "compare best times from old and new") -) - -const usageFooter = ` -Each input file should be from: - go test -run=NONE -bench=. > [old,new].txt - -Benchcmp compares old and new for each benchmark. - -If -test.benchmem=true is added to the "go test" command -benchcmp will also compare memory allocations. -` - -func main() { - flag.Usage = func() { - fmt.Fprintf(os.Stderr, "usage: %s old.txt new.txt\n\n", os.Args[0]) - flag.PrintDefaults() - fmt.Fprint(os.Stderr, usageFooter) - os.Exit(2) - } - flag.Parse() - if flag.NArg() != 2 { - flag.Usage() - } - - before := parseFile(flag.Arg(0)) - after := parseFile(flag.Arg(1)) - - cmps, warnings := Correlate(before, after) - - for _, warn := range warnings { - fmt.Fprintln(os.Stderr, warn) - } - - if len(cmps) == 0 { - fatal("benchcmp: no repeated benchmarks") - } - - w := new(tabwriter.Writer) - w.Init(os.Stdout, 0, 0, 5, ' ', 0) - defer w.Flush() - - var header bool // Has the header has been displayed yet for a given block? - - if *magSort { - sort.Sort(ByDeltaNsPerOp(cmps)) - } else { - sort.Sort(ByParseOrder(cmps)) - } - for _, cmp := range cmps { - if !cmp.Measured(parse.NsPerOp) { - continue - } - if delta := cmp.DeltaNsPerOp(); !*changedOnly || delta.Changed() { - if !header { - fmt.Fprint(w, "benchmark\told ns/op\tnew ns/op\tdelta\n") - header = true - } - fmt.Fprintf(w, "%s\t%s\t%s\t%s\n", cmp.Name(), formatNs(cmp.Before.NsPerOp), formatNs(cmp.After.NsPerOp), delta.Percent()) - } - } - - header = false - if *magSort { - sort.Sort(ByDeltaMBPerS(cmps)) - } - for _, cmp := range cmps { - if !cmp.Measured(parse.MBPerS) { - continue - } - if delta := cmp.DeltaMBPerS(); !*changedOnly || delta.Changed() { - if !header { - fmt.Fprint(w, "\nbenchmark\told MB/s\tnew MB/s\tspeedup\n") - header = true - } - fmt.Fprintf(w, "%s\t%.2f\t%.2f\t%s\n", cmp.Name(), cmp.Before.MBPerS, cmp.After.MBPerS, delta.Multiple()) - } - } - - header = false - if *magSort { - sort.Sort(ByDeltaAllocsPerOp(cmps)) - } - for _, cmp := range cmps { - if !cmp.Measured(parse.AllocsPerOp) { - continue - } - if delta := cmp.DeltaAllocsPerOp(); !*changedOnly || delta.Changed() { - if !header { - fmt.Fprint(w, "\nbenchmark\told allocs\tnew allocs\tdelta\n") - header = true - } - fmt.Fprintf(w, "%s\t%d\t%d\t%s\n", cmp.Name(), cmp.Before.AllocsPerOp, cmp.After.AllocsPerOp, delta.Percent()) - } - } - - header = false - if *magSort { - sort.Sort(ByDeltaAllocedBytesPerOp(cmps)) - } - for _, cmp := range cmps { - if !cmp.Measured(parse.AllocedBytesPerOp) { - continue - } - if delta := cmp.DeltaAllocedBytesPerOp(); !*changedOnly || delta.Changed() { - if !header { - fmt.Fprint(w, "\nbenchmark\told bytes\tnew bytes\tdelta\n") - header = true - } - fmt.Fprintf(w, "%s\t%d\t%d\t%s\n", cmp.Name(), cmp.Before.AllocedBytesPerOp, cmp.After.AllocedBytesPerOp, cmp.DeltaAllocedBytesPerOp().Percent()) - } - } -} - -func fatal(msg interface{}) { - fmt.Fprintln(os.Stderr, msg) - os.Exit(1) -} - -func parseFile(path string) parse.Set { - f, err := os.Open(path) - if err != nil { - fatal(err) - } - defer f.Close() - bb, err := parse.ParseSet(f) - if err != nil { - fatal(err) - } - if *best { - selectBest(bb) - } - return bb -} - -func selectBest(bs parse.Set) { - for name, bb := range bs { - if len(bb) < 2 { - continue - } - ord := bb[0].Ord - best := bb[0] - for _, b := range bb { - if b.NsPerOp < best.NsPerOp { - b.Ord = ord - best = b - } - } - bs[name] = []*parse.Benchmark{best} - } -} - -// formatNs formats ns measurements to expose a useful amount of -// precision. It mirrors the ns precision logic of testing.B. -func formatNs(ns float64) string { - prec := 0 - switch { - case ns < 10: - prec = 2 - case ns < 100: - prec = 1 - } - return strconv.FormatFloat(ns, 'f', prec, 64) -} diff --git a/vendor/golang.org/x/tools/cmd/benchcmp/benchcmp_test.go b/vendor/golang.org/x/tools/cmd/benchcmp/benchcmp_test.go deleted file mode 100644 index 2226079..0000000 --- a/vendor/golang.org/x/tools/cmd/benchcmp/benchcmp_test.go +++ /dev/null @@ -1,59 +0,0 @@ -package main - -import ( - "reflect" - "testing" - - "golang.org/x/tools/benchmark/parse" -) - -func TestSelectBest(t *testing.T) { - have := parse.Set{ - "Benchmark1": []*parse.Benchmark{ - { - Name: "Benchmark1", - N: 10, NsPerOp: 100, Measured: parse.NsPerOp, - Ord: 0, - }, - { - Name: "Benchmark1", - N: 10, NsPerOp: 50, Measured: parse.NsPerOp, - Ord: 3, - }, - }, - "Benchmark2": []*parse.Benchmark{ - { - Name: "Benchmark2", - N: 10, NsPerOp: 60, Measured: parse.NsPerOp, - Ord: 1, - }, - { - Name: "Benchmark2", - N: 10, NsPerOp: 500, Measured: parse.NsPerOp, - Ord: 2, - }, - }, - } - - want := parse.Set{ - "Benchmark1": []*parse.Benchmark{ - { - Name: "Benchmark1", - N: 10, NsPerOp: 50, Measured: parse.NsPerOp, - Ord: 0, - }, - }, - "Benchmark2": []*parse.Benchmark{ - { - Name: "Benchmark2", - N: 10, NsPerOp: 60, Measured: parse.NsPerOp, - Ord: 1, - }, - }, - } - - selectBest(have) - if !reflect.DeepEqual(want, have) { - t.Errorf("filtered bench set incorrectly, want %v have %v", want, have) - } -} diff --git a/vendor/golang.org/x/tools/cmd/benchcmp/compare.go b/vendor/golang.org/x/tools/cmd/benchcmp/compare.go deleted file mode 100644 index c3f5e89..0000000 --- a/vendor/golang.org/x/tools/cmd/benchcmp/compare.go +++ /dev/null @@ -1,156 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package main - -import ( - "fmt" - "math" - - "golang.org/x/tools/benchmark/parse" -) - -// BenchCmp is a pair of benchmarks. -type BenchCmp struct { - Before *parse.Benchmark - After *parse.Benchmark -} - -// Correlate correlates benchmarks from two BenchSets. -func Correlate(before, after parse.Set) (cmps []BenchCmp, warnings []string) { - cmps = make([]BenchCmp, 0, len(after)) - for name, beforebb := range before { - afterbb := after[name] - if len(beforebb) != len(afterbb) { - warnings = append(warnings, fmt.Sprintf("ignoring %s: before has %d instances, after has %d", name, len(beforebb), len(afterbb))) - continue - } - for i, beforeb := range beforebb { - afterb := afterbb[i] - cmps = append(cmps, BenchCmp{beforeb, afterb}) - } - } - return -} - -func (c BenchCmp) Name() string { return c.Before.Name } -func (c BenchCmp) String() string { return fmt.Sprintf("<%s, %s>", c.Before, c.After) } -func (c BenchCmp) Measured(flag int) bool { return (c.Before.Measured & c.After.Measured & flag) != 0 } -func (c BenchCmp) DeltaNsPerOp() Delta { return Delta{c.Before.NsPerOp, c.After.NsPerOp} } -func (c BenchCmp) DeltaMBPerS() Delta { return Delta{c.Before.MBPerS, c.After.MBPerS} } -func (c BenchCmp) DeltaAllocedBytesPerOp() Delta { - return Delta{float64(c.Before.AllocedBytesPerOp), float64(c.After.AllocedBytesPerOp)} -} -func (c BenchCmp) DeltaAllocsPerOp() Delta { - return Delta{float64(c.Before.AllocsPerOp), float64(c.After.AllocsPerOp)} -} - -// Delta is the before and after value for a benchmark measurement. -// Both must be non-negative. -type Delta struct { - Before float64 - After float64 -} - -// mag calculates the magnitude of a change, regardless of the direction of -// the change. mag is intended for sorting and has no independent meaning. -func (d Delta) mag() float64 { - switch { - case d.Before != 0 && d.After != 0 && d.Before >= d.After: - return d.After / d.Before - case d.Before != 0 && d.After != 0 && d.Before < d.After: - return d.Before / d.After - case d.Before == 0 && d.After == 0: - return 1 - default: - // 0 -> 1 or 1 -> 0 - // These are significant changes and worth surfacing. - return math.Inf(1) - } -} - -// Changed reports whether the benchmark quantities are different. -func (d Delta) Changed() bool { return d.Before != d.After } - -// Float64 returns After / Before. If Before is 0, Float64 returns -// 1 if After is also 0, and +Inf otherwise. -func (d Delta) Float64() float64 { - switch { - case d.Before != 0: - return d.After / d.Before - case d.After == 0: - return 1 - default: - return math.Inf(1) - } -} - -// Percent formats a Delta as a percent change, ranging from -100% up. -func (d Delta) Percent() string { - return fmt.Sprintf("%+.2f%%", 100*d.Float64()-100) -} - -// Multiple formats a Delta as a multiplier, ranging from 0.00x up. -func (d Delta) Multiple() string { - return fmt.Sprintf("%.2fx", d.Float64()) -} - -func (d Delta) String() string { - return fmt.Sprintf("Δ(%f, %f)", d.Before, d.After) -} - -// ByParseOrder sorts BenchCmps to match the order in -// which the Before benchmarks were presented to Parse. -type ByParseOrder []BenchCmp - -func (x ByParseOrder) Len() int { return len(x) } -func (x ByParseOrder) Swap(i, j int) { x[i], x[j] = x[j], x[i] } -func (x ByParseOrder) Less(i, j int) bool { return x[i].Before.Ord < x[j].Before.Ord } - -// lessByDelta provides lexicographic ordering: -// * largest delta by magnitude -// * alphabetic by name -func lessByDelta(i, j BenchCmp, calcDelta func(BenchCmp) Delta) bool { - iDelta, jDelta := calcDelta(i).mag(), calcDelta(j).mag() - if iDelta != jDelta { - return iDelta < jDelta - } - return i.Name() < j.Name() -} - -// ByDeltaNsPerOp sorts BenchCmps lexicographically by change -// in ns/op, descending, then by benchmark name. -type ByDeltaNsPerOp []BenchCmp - -func (x ByDeltaNsPerOp) Len() int { return len(x) } -func (x ByDeltaNsPerOp) Swap(i, j int) { x[i], x[j] = x[j], x[i] } -func (x ByDeltaNsPerOp) Less(i, j int) bool { return lessByDelta(x[i], x[j], BenchCmp.DeltaNsPerOp) } - -// ByDeltaMBPerS sorts BenchCmps lexicographically by change -// in MB/s, descending, then by benchmark name. -type ByDeltaMBPerS []BenchCmp - -func (x ByDeltaMBPerS) Len() int { return len(x) } -func (x ByDeltaMBPerS) Swap(i, j int) { x[i], x[j] = x[j], x[i] } -func (x ByDeltaMBPerS) Less(i, j int) bool { return lessByDelta(x[i], x[j], BenchCmp.DeltaMBPerS) } - -// ByDeltaAllocedBytesPerOp sorts BenchCmps lexicographically by change -// in B/op, descending, then by benchmark name. -type ByDeltaAllocedBytesPerOp []BenchCmp - -func (x ByDeltaAllocedBytesPerOp) Len() int { return len(x) } -func (x ByDeltaAllocedBytesPerOp) Swap(i, j int) { x[i], x[j] = x[j], x[i] } -func (x ByDeltaAllocedBytesPerOp) Less(i, j int) bool { - return lessByDelta(x[i], x[j], BenchCmp.DeltaAllocedBytesPerOp) -} - -// ByDeltaAllocsPerOp sorts BenchCmps lexicographically by change -// in allocs/op, descending, then by benchmark name. -type ByDeltaAllocsPerOp []BenchCmp - -func (x ByDeltaAllocsPerOp) Len() int { return len(x) } -func (x ByDeltaAllocsPerOp) Swap(i, j int) { x[i], x[j] = x[j], x[i] } -func (x ByDeltaAllocsPerOp) Less(i, j int) bool { - return lessByDelta(x[i], x[j], BenchCmp.DeltaAllocsPerOp) -} diff --git a/vendor/golang.org/x/tools/cmd/benchcmp/compare_test.go b/vendor/golang.org/x/tools/cmd/benchcmp/compare_test.go deleted file mode 100644 index 3403796..0000000 --- a/vendor/golang.org/x/tools/cmd/benchcmp/compare_test.go +++ /dev/null @@ -1,133 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package main - -import ( - "math" - "reflect" - "sort" - "testing" - - "golang.org/x/tools/benchmark/parse" -) - -func TestDelta(t *testing.T) { - cases := []struct { - before float64 - after float64 - mag float64 - f float64 - changed bool - pct string - mult string - }{ - {before: 1, after: 1, mag: 1, f: 1, changed: false, pct: "+0.00%", mult: "1.00x"}, - {before: 1, after: 2, mag: 0.5, f: 2, changed: true, pct: "+100.00%", mult: "2.00x"}, - {before: 2, after: 1, mag: 0.5, f: 0.5, changed: true, pct: "-50.00%", mult: "0.50x"}, - {before: 0, after: 0, mag: 1, f: 1, changed: false, pct: "+0.00%", mult: "1.00x"}, - {before: 1, after: 0, mag: math.Inf(1), f: 0, changed: true, pct: "-100.00%", mult: "0.00x"}, - {before: 0, after: 1, mag: math.Inf(1), f: math.Inf(1), changed: true, pct: "+Inf%", mult: "+Infx"}, - } - for _, tt := range cases { - d := Delta{tt.before, tt.after} - if want, have := tt.mag, d.mag(); want != have { - t.Errorf("%s.mag(): want %f have %f", d, want, have) - } - if want, have := tt.f, d.Float64(); want != have { - t.Errorf("%s.Float64(): want %f have %f", d, want, have) - } - if want, have := tt.changed, d.Changed(); want != have { - t.Errorf("%s.Changed(): want %t have %t", d, want, have) - } - if want, have := tt.pct, d.Percent(); want != have { - t.Errorf("%s.Percent(): want %q have %q", d, want, have) - } - if want, have := tt.mult, d.Multiple(); want != have { - t.Errorf("%s.Multiple(): want %q have %q", d, want, have) - } - } -} - -func TestCorrelate(t *testing.T) { - // Benches that are going to be successfully correlated get N thus: - // 0x - // Read this: " of , from ". - before := parse.Set{ - "BenchmarkOneEach": []*parse.Benchmark{{Name: "BenchmarkOneEach", N: 0x11b}}, - "BenchmarkOneToNone": []*parse.Benchmark{{Name: "BenchmarkOneToNone"}}, - "BenchmarkOneToTwo": []*parse.Benchmark{{Name: "BenchmarkOneToTwo"}}, - "BenchmarkTwoToOne": []*parse.Benchmark{ - {Name: "BenchmarkTwoToOne"}, - {Name: "BenchmarkTwoToOne"}, - }, - "BenchmarkTwoEach": []*parse.Benchmark{ - {Name: "BenchmarkTwoEach", N: 0x12b}, - {Name: "BenchmarkTwoEach", N: 0x22b}, - }, - } - - after := parse.Set{ - "BenchmarkOneEach": []*parse.Benchmark{{Name: "BenchmarkOneEach", N: 0x11a}}, - "BenchmarkNoneToOne": []*parse.Benchmark{{Name: "BenchmarkNoneToOne"}}, - "BenchmarkTwoToOne": []*parse.Benchmark{{Name: "BenchmarkTwoToOne"}}, - "BenchmarkOneToTwo": []*parse.Benchmark{ - {Name: "BenchmarkOneToTwo"}, - {Name: "BenchmarkOneToTwo"}, - }, - "BenchmarkTwoEach": []*parse.Benchmark{ - {Name: "BenchmarkTwoEach", N: 0x12a}, - {Name: "BenchmarkTwoEach", N: 0x22a}, - }, - } - - pairs, errs := Correlate(before, after) - - // Fail to match: BenchmarkOneToNone, BenchmarkOneToTwo, BenchmarkTwoToOne. - // Correlate does not notice BenchmarkNoneToOne. - if len(errs) != 3 { - t.Errorf("Correlated expected 4 errors, got %d: %v", len(errs), errs) - } - - // Want three correlated pairs: one BenchmarkOneEach, two BenchmarkTwoEach. - if len(pairs) != 3 { - t.Fatalf("Correlated expected 3 pairs, got %v", pairs) - } - - for _, pair := range pairs { - if pair.Before.N&0xF != 0xb { - t.Errorf("unexpected Before in pair %s", pair) - } - if pair.After.N&0xF != 0xa { - t.Errorf("unexpected After in pair %s", pair) - } - if pair.Before.N>>4 != pair.After.N>>4 { - t.Errorf("mismatched pair %s", pair) - } - } -} - -func TestBenchCmpSorting(t *testing.T) { - c := []BenchCmp{ - {&parse.Benchmark{Name: "BenchmarkMuchFaster", NsPerOp: 10, Ord: 3}, &parse.Benchmark{Name: "BenchmarkMuchFaster", NsPerOp: 1}}, - {&parse.Benchmark{Name: "BenchmarkSameB", NsPerOp: 5, Ord: 1}, &parse.Benchmark{Name: "BenchmarkSameB", NsPerOp: 5}}, - {&parse.Benchmark{Name: "BenchmarkSameA", NsPerOp: 5, Ord: 2}, &parse.Benchmark{Name: "BenchmarkSameA", NsPerOp: 5}}, - {&parse.Benchmark{Name: "BenchmarkSlower", NsPerOp: 10, Ord: 0}, &parse.Benchmark{Name: "BenchmarkSlower", NsPerOp: 11}}, - } - - // Test just one magnitude-based sort order; they are symmetric. - sort.Sort(ByDeltaNsPerOp(c)) - want := []string{"BenchmarkMuchFaster", "BenchmarkSlower", "BenchmarkSameA", "BenchmarkSameB"} - have := []string{c[0].Name(), c[1].Name(), c[2].Name(), c[3].Name()} - if !reflect.DeepEqual(want, have) { - t.Errorf("ByDeltaNsOp incorrect sorting: want %v have %v", want, have) - } - - sort.Sort(ByParseOrder(c)) - want = []string{"BenchmarkSlower", "BenchmarkSameB", "BenchmarkSameA", "BenchmarkMuchFaster"} - have = []string{c[0].Name(), c[1].Name(), c[2].Name(), c[3].Name()} - if !reflect.DeepEqual(want, have) { - t.Errorf("ByParseOrder incorrect sorting: want %v have %v", want, have) - } -} diff --git a/vendor/golang.org/x/tools/cmd/benchcmp/doc.go b/vendor/golang.org/x/tools/cmd/benchcmp/doc.go deleted file mode 100644 index f5c7a36..0000000 --- a/vendor/golang.org/x/tools/cmd/benchcmp/doc.go +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -/* - -The benchcmp command displays performance changes between benchmarks. - -Benchcmp parses the output of two 'go test' benchmark runs, -correlates the results per benchmark, and displays the deltas. - -To measure the performance impact of a change, use 'go test' -to run benchmarks before and after the change: - - go test -run=NONE -bench=. ./... > old.txt - # make changes - go test -run=NONE -bench=. ./... > new.txt - -Then feed the benchmark results to benchcmp: - - benchcmp old.txt new.txt - -Benchcmp will summarize and display the performance changes, -in a format like this: - - $ benchcmp old.txt new.txt - benchmark old ns/op new ns/op delta - BenchmarkConcat 523 68.6 -86.88% - - benchmark old allocs new allocs delta - BenchmarkConcat 3 1 -66.67% - - benchmark old bytes new bytes delta - BenchmarkConcat 80 48 -40.00% - -*/ -package main // import "golang.org/x/tools/cmd/benchcmp" diff --git a/vendor/golang.org/x/tools/cmd/bundle/.gitignore b/vendor/golang.org/x/tools/cmd/bundle/.gitignore deleted file mode 100644 index caaeb09..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/.gitignore +++ /dev/null @@ -1 +0,0 @@ -testdata/out.got diff --git a/vendor/golang.org/x/tools/cmd/bundle/main.go b/vendor/golang.org/x/tools/cmd/bundle/main.go deleted file mode 100644 index 601da7f..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/main.go +++ /dev/null @@ -1,468 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Bundle creates a single-source-file version of a source package -// suitable for inclusion in a particular target package. -// -// Usage: -// -// bundle [-o file] [-dst path] [-pkg name] [-prefix p] [-import old=new] -// -// The src argument specifies the import path of the package to bundle. -// The bundling of a directory of source files into a single source file -// necessarily imposes a number of constraints. -// The package being bundled must not use cgo; must not use conditional -// file compilation, whether with build tags or system-specific file names -// like code_amd64.go; must not depend on any special comments, which -// may not be preserved; must not use any assembly sources; -// must not use renaming imports; and must not use reflection-based APIs -// that depend on the specific names of types or struct fields. -// -// By default, bundle writes the bundled code to standard output. -// If the -o argument is given, bundle writes to the named file -// and also includes a ``//go:generate'' comment giving the exact -// command line used, for regenerating the file with ``go generate.'' -// -// Bundle customizes its output for inclusion in a particular package, the destination package. -// By default bundle assumes the destination is the package in the current directory, -// but the destination package can be specified explicitly using the -dst option, -// which takes an import path as its argument. -// If the source package imports the destination package, bundle will remove -// those imports and rewrite any references to use direct references to the -// corresponding symbols. -// Bundle also must write a package declaration in the output and must -// choose a name to use in that declaration. -// If the -package option is given, bundle uses that name. -// Otherwise, if the -dst option is given, bundle uses the last -// element of the destination import path. -// Otherwise, by default bundle uses the package name found in the -// package sources in the current directory. -// -// To avoid collisions, bundle inserts a prefix at the beginning of -// every package-level const, func, type, and var identifier in src's code, -// updating references accordingly. The default prefix is the package name -// of the source package followed by an underscore. The -prefix option -// specifies an alternate prefix. -// -// Occasionally it is necessary to rewrite imports during the bundling -// process. The -import option, which may be repeated, specifies that -// an import of "old" should be rewritten to import "new" instead. -// -// Example -// -// Bundle archive/zip for inclusion in cmd/dist: -// -// cd $GOROOT/src/cmd/dist -// bundle -o zip.go archive/zip -// -// Bundle golang.org/x/net/http2 for inclusion in net/http, -// prefixing all identifiers by "http2" instead of "http2_", -// and rewriting the import "golang.org/x/net/http2/hpack" -// to "internal/golang.org/x/net/http2/hpack": -// -// cd $GOROOT/src/net/http -// bundle -o h2_bundle.go \ -// -prefix http2 \ -// -import golang.org/x/net/http2/hpack=internal/golang.org/x/net/http2/hpack \ -// golang.org/x/net/http2 -// -// Two ways to update the http2 bundle: -// -// go generate net/http -// -// cd $GOROOT/src/net/http -// go generate -// -// Update both bundles, restricting ``go generate'' to running bundle commands: -// -// go generate -run bundle cmd/dist net/http -// -package main - -import ( - "bytes" - "flag" - "fmt" - "go/ast" - "go/build" - "go/format" - "go/parser" - "go/printer" - "go/token" - "go/types" - "io/ioutil" - "log" - "os" - "path" - "strconv" - "strings" - - "golang.org/x/tools/go/loader" -) - -var ( - outputFile = flag.String("o", "", "write output to `file` (default standard output)") - dstPath = flag.String("dst", "", "set destination import `path` (default taken from current directory)") - pkgName = flag.String("pkg", "", "set destination package `name` (default taken from current directory)") - prefix = flag.String("prefix", "", "set bundled identifier prefix to `p` (default source package name + \"_\")") - underscore = flag.Bool("underscore", false, "rewrite golang.org to golang_org in imports; temporary workaround for golang.org/issue/16333") - - importMap = map[string]string{} -) - -func init() { - flag.Var(flagFunc(addImportMap), "import", "rewrite import using `map`, of form old=new (can be repeated)") -} - -func addImportMap(s string) { - if strings.Count(s, "=") != 1 { - log.Fatal("-import argument must be of the form old=new") - } - i := strings.Index(s, "=") - old, new := s[:i], s[i+1:] - if old == "" || new == "" { - log.Fatal("-import argument must be of the form old=new; old and new must be non-empty") - } - importMap[old] = new -} - -func usage() { - fmt.Fprintf(os.Stderr, "Usage: bundle [options] \n") - flag.PrintDefaults() -} - -func main() { - log.SetPrefix("bundle: ") - log.SetFlags(0) - - flag.Usage = usage - flag.Parse() - args := flag.Args() - if len(args) != 1 { - usage() - os.Exit(2) - } - - if *dstPath != "" { - if *pkgName == "" { - *pkgName = path.Base(*dstPath) - } - } else { - wd, _ := os.Getwd() - pkg, err := build.ImportDir(wd, 0) - if err != nil { - log.Fatalf("cannot find package in current directory: %v", err) - } - *dstPath = pkg.ImportPath - if *pkgName == "" { - *pkgName = pkg.Name - } - } - - code, err := bundle(args[0], *dstPath, *pkgName, *prefix) - if err != nil { - log.Fatal(err) - } - if *outputFile != "" { - err := ioutil.WriteFile(*outputFile, code, 0666) - if err != nil { - log.Fatal(err) - } - } else { - _, err := os.Stdout.Write(code) - if err != nil { - log.Fatal(err) - } - } -} - -// isStandardImportPath is copied from cmd/go in the standard library. -func isStandardImportPath(path string) bool { - i := strings.Index(path, "/") - if i < 0 { - i = len(path) - } - elem := path[:i] - return !strings.Contains(elem, ".") -} - -var ctxt = &build.Default - -func bundle(src, dst, dstpkg, prefix string) ([]byte, error) { - // Load the initial package. - conf := loader.Config{ParserMode: parser.ParseComments, Build: ctxt} - conf.TypeCheckFuncBodies = func(p string) bool { return p == src } - conf.Import(src) - - lprog, err := conf.Load() - if err != nil { - return nil, err - } - - // Because there was a single Import call and Load succeeded, - // InitialPackages is guaranteed to hold the sole requested package. - info := lprog.InitialPackages()[0] - if prefix == "" { - pkgName := info.Files[0].Name.Name - prefix = pkgName + "_" - } - - objsToUpdate := make(map[types.Object]bool) - var rename func(from types.Object) - rename = func(from types.Object) { - if !objsToUpdate[from] { - objsToUpdate[from] = true - - // Renaming a type that is used as an embedded field - // requires renaming the field too. e.g. - // type T int // if we rename this to U.. - // var s struct {T} - // print(s.T) // ...this must change too - if _, ok := from.(*types.TypeName); ok { - for id, obj := range info.Uses { - if obj == from { - if field := info.Defs[id]; field != nil { - rename(field) - } - } - } - } - } - } - - // Rename each package-level object. - scope := info.Pkg.Scope() - for _, name := range scope.Names() { - rename(scope.Lookup(name)) - } - - var out bytes.Buffer - - fmt.Fprintf(&out, "// Code generated by golang.org/x/tools/cmd/bundle. DO NOT EDIT.\n") - if *outputFile != "" { - fmt.Fprintf(&out, "//go:generate bundle %s\n", strings.Join(os.Args[1:], " ")) - } else { - fmt.Fprintf(&out, "// $ bundle %s\n", strings.Join(os.Args[1:], " ")) - } - fmt.Fprintf(&out, "\n") - - // Concatenate package comments from all files... - for _, f := range info.Files { - if doc := f.Doc.Text(); strings.TrimSpace(doc) != "" { - for _, line := range strings.Split(doc, "\n") { - fmt.Fprintf(&out, "// %s\n", line) - } - } - } - // ...but don't let them become the actual package comment. - fmt.Fprintln(&out) - - fmt.Fprintf(&out, "package %s\n\n", dstpkg) - - // BUG(adonovan,shurcooL): bundle may generate incorrect code - // due to shadowing between identifiers and imported package names. - // - // The generated code will either fail to compile or - // (unlikely) compile successfully but have different behavior - // than the original package. The risk of this happening is higher - // when the original package has renamed imports (they're typically - // renamed in order to resolve a shadow inside that particular .go file). - - // TODO(adonovan,shurcooL): - // - detect shadowing issues, and either return error or resolve them - // - preserve comments from the original import declarations. - - // pkgStd and pkgExt are sets of printed import specs. This is done - // to deduplicate instances of the same import name and path. - var pkgStd = make(map[string]bool) - var pkgExt = make(map[string]bool) - for _, f := range info.Files { - for _, imp := range f.Imports { - path, err := strconv.Unquote(imp.Path.Value) - if err != nil { - log.Fatalf("invalid import path string: %v", err) // Shouldn't happen here since conf.Load succeeded. - } - if path == dst { - continue - } - if newPath, ok := importMap[path]; ok { - path = newPath - } - - var name string - if imp.Name != nil { - name = imp.Name.Name - } - spec := fmt.Sprintf("%s %q", name, path) - if isStandardImportPath(path) { - pkgStd[spec] = true - } else { - if *underscore { - spec = strings.Replace(spec, "golang.org/", "golang_org/", 1) - } - pkgExt[spec] = true - } - } - } - - // Print a single declaration that imports all necessary packages. - fmt.Fprintln(&out, "import (") - for p := range pkgStd { - fmt.Fprintf(&out, "\t%s\n", p) - } - if len(pkgExt) > 0 { - fmt.Fprintln(&out) - } - for p := range pkgExt { - fmt.Fprintf(&out, "\t%s\n", p) - } - fmt.Fprint(&out, ")\n\n") - - // Modify and print each file. - for _, f := range info.Files { - // Update renamed identifiers. - for id, obj := range info.Defs { - if objsToUpdate[obj] { - id.Name = prefix + obj.Name() - } - } - for id, obj := range info.Uses { - if objsToUpdate[obj] { - id.Name = prefix + obj.Name() - } - } - - // For each qualified identifier that refers to the - // destination package, remove the qualifier. - // The "@@@." strings are removed in postprocessing. - ast.Inspect(f, func(n ast.Node) bool { - if sel, ok := n.(*ast.SelectorExpr); ok { - if id, ok := sel.X.(*ast.Ident); ok { - if obj, ok := info.Uses[id].(*types.PkgName); ok { - if obj.Imported().Path() == dst { - id.Name = "@@@" - } - } - } - } - return true - }) - - last := f.Package - if len(f.Imports) > 0 { - imp := f.Imports[len(f.Imports)-1] - last = imp.End() - if imp.Comment != nil { - if e := imp.Comment.End(); e > last { - last = e - } - } - } - - // Pretty-print package-level declarations. - // but no package or import declarations. - var buf bytes.Buffer - for _, decl := range f.Decls { - if decl, ok := decl.(*ast.GenDecl); ok && decl.Tok == token.IMPORT { - continue - } - - beg, end := sourceRange(decl) - - printComments(&out, f.Comments, last, beg) - - buf.Reset() - format.Node(&buf, lprog.Fset, &printer.CommentedNode{Node: decl, Comments: f.Comments}) - // Remove each "@@@." in the output. - // TODO(adonovan): not hygienic. - out.Write(bytes.Replace(buf.Bytes(), []byte("@@@."), nil, -1)) - - last = printSameLineComment(&out, f.Comments, lprog.Fset, end) - - out.WriteString("\n\n") - } - - printLastComments(&out, f.Comments, last) - } - - // Now format the entire thing. - result, err := format.Source(out.Bytes()) - if err != nil { - log.Fatalf("formatting failed: %v", err) - } - - return result, nil -} - -// sourceRange returns the [beg, end) interval of source code -// belonging to decl (incl. associated comments). -func sourceRange(decl ast.Decl) (beg, end token.Pos) { - beg = decl.Pos() - end = decl.End() - - var doc, com *ast.CommentGroup - - switch d := decl.(type) { - case *ast.GenDecl: - doc = d.Doc - if len(d.Specs) > 0 { - switch spec := d.Specs[len(d.Specs)-1].(type) { - case *ast.ValueSpec: - com = spec.Comment - case *ast.TypeSpec: - com = spec.Comment - } - } - case *ast.FuncDecl: - doc = d.Doc - } - - if doc != nil { - beg = doc.Pos() - } - if com != nil && com.End() > end { - end = com.End() - } - - return beg, end -} - -func printComments(out *bytes.Buffer, comments []*ast.CommentGroup, pos, end token.Pos) { - for _, cg := range comments { - if pos <= cg.Pos() && cg.Pos() < end { - for _, c := range cg.List { - fmt.Fprintln(out, c.Text) - } - fmt.Fprintln(out) - } - } -} - -const infinity = 1 << 30 - -func printLastComments(out *bytes.Buffer, comments []*ast.CommentGroup, pos token.Pos) { - printComments(out, comments, pos, infinity) -} - -func printSameLineComment(out *bytes.Buffer, comments []*ast.CommentGroup, fset *token.FileSet, pos token.Pos) token.Pos { - tf := fset.File(pos) - for _, cg := range comments { - if pos <= cg.Pos() && tf.Line(cg.Pos()) == tf.Line(pos) { - for _, c := range cg.List { - fmt.Fprintln(out, c.Text) - } - return cg.End() - } - } - return pos -} - -type flagFunc func(string) - -func (f flagFunc) Set(s string) error { - f(s) - return nil -} - -func (f flagFunc) String() string { return "" } diff --git a/vendor/golang.org/x/tools/cmd/bundle/main_test.go b/vendor/golang.org/x/tools/cmd/bundle/main_test.go deleted file mode 100644 index b96f7d9..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/main_test.go +++ /dev/null @@ -1,74 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build go1.9 - -package main - -import ( - "bytes" - "io/ioutil" - "os" - "os/exec" - "runtime" - "testing" - - "golang.org/x/tools/go/buildutil" -) - -func TestBundle(t *testing.T) { - load := func(name string) string { - data, err := ioutil.ReadFile(name) - if err != nil { - t.Fatal(err) - } - return string(data) - } - - ctxt = buildutil.FakeContext(map[string]map[string]string{ - "initial": { - "a.go": load("testdata/src/initial/a.go"), - "b.go": load("testdata/src/initial/b.go"), - "c.go": load("testdata/src/initial/c.go"), - }, - "domain.name/importdecl": { - "p.go": load("testdata/src/domain.name/importdecl/p.go"), - }, - "fmt": { - "print.go": `package fmt; func Println(...interface{})`, - }, - }) - - os.Args = os.Args[:1] // avoid e.g. -test=short in the output - out, err := bundle("initial", "github.com/dest", "dest", "prefix") - if err != nil { - t.Fatal(err) - } - if got, want := string(out), load("testdata/out.golden"); got != want { - t.Errorf("-- got --\n%s\n-- want --\n%s\n-- diff --", got, want) - - if err := ioutil.WriteFile("testdata/out.got", out, 0644); err != nil { - t.Fatal(err) - } - t.Log(diff("testdata/out.golden", "testdata/out.got")) - } -} - -func diff(a, b string) string { - var cmd *exec.Cmd - switch runtime.GOOS { - case "plan9": - cmd = exec.Command("/bin/diff", "-c", a, b) - default: - cmd = exec.Command("/usr/bin/diff", "-u", a, b) - } - var out bytes.Buffer - cmd.Stdout = &out - cmd.Stderr = &out - cmd.Run() // nonzero exit is expected - if out.Len() == 0 { - return "(failed to compute diff)" - } - return out.String() -} diff --git a/vendor/golang.org/x/tools/cmd/bundle/testdata/out.golden b/vendor/golang.org/x/tools/cmd/bundle/testdata/out.golden deleted file mode 100644 index 5260fdd..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/testdata/out.golden +++ /dev/null @@ -1,62 +0,0 @@ -// Code generated by golang.org/x/tools/cmd/bundle. DO NOT EDIT. -// $ bundle - -// The package doc comment -// - -package dest - -import ( - "fmt" - . "fmt" - _ "fmt" - renamedfmt "fmt" - renamedfmt2 "fmt" - - "domain.name/importdecl" -) - -// init functions are not renamed -func init() { prefixfoo() } - -// Type S. -type prefixS struct { - prefixt - u int -} /* multi-line -comment -*/ - -// non-associated comment - -/* - non-associated comment2 -*/ - -// Function bar. -func prefixbar(s *prefixS) { - fmt.Println(s.prefixt, s.u) // comment inside function -} - -// file-end comment - -type prefixt int // type1 - -// const1 -const prefixc = 1 // const2 - -func prefixfoo() { - fmt.Println(importdecl.F()) -} - -// zinit -const ( - prefixz1 = iota // z1 - prefixz2 // z2 -) // zend - -func prefixbaz() { - renamedfmt.Println() - renamedfmt2.Println() - Println() -} diff --git a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/domain.name/importdecl/p.go b/vendor/golang.org/x/tools/cmd/bundle/testdata/src/domain.name/importdecl/p.go deleted file mode 100644 index 36dfd15..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/domain.name/importdecl/p.go +++ /dev/null @@ -1,3 +0,0 @@ -package importdecl - -func F() int { return 1 } diff --git a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/a.go b/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/a.go deleted file mode 100644 index ded6c64..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/a.go +++ /dev/null @@ -1,27 +0,0 @@ -package initial - -import "fmt" // this comment should not be visible - -// init functions are not renamed -func init() { foo() } - -// Type S. -type S struct { - t - u int -} /* multi-line -comment -*/ - -// non-associated comment - -/* - non-associated comment2 -*/ - -// Function bar. -func bar(s *S) { - fmt.Println(s.t, s.u) // comment inside function -} - -// file-end comment diff --git a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/b.go b/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/b.go deleted file mode 100644 index 31d5cab..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/b.go +++ /dev/null @@ -1,23 +0,0 @@ -// The package doc comment -package initial - -import ( - "fmt" - - "domain.name/importdecl" -) - -type t int // type1 - -// const1 -const c = 1 // const2 - -func foo() { - fmt.Println(importdecl.F()) -} - -// zinit -const ( - z1 = iota // z1 - z2 // z2 -) // zend diff --git a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/c.go b/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/c.go deleted file mode 100644 index 6a9cbc6..0000000 --- a/vendor/golang.org/x/tools/cmd/bundle/testdata/src/initial/c.go +++ /dev/null @@ -1,12 +0,0 @@ -package initial - -import _ "fmt" -import renamedfmt "fmt" -import renamedfmt2 "fmt" -import . "fmt" - -func baz() { - renamedfmt.Println() - renamedfmt2.Println() - Println() -} diff --git a/vendor/golang.org/x/tools/cmd/callgraph/main.go b/vendor/golang.org/x/tools/cmd/callgraph/main.go deleted file mode 100644 index 8ef4597..0000000 --- a/vendor/golang.org/x/tools/cmd/callgraph/main.go +++ /dev/null @@ -1,361 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// callgraph: a tool for reporting the call graph of a Go program. -// See Usage for details, or run with -help. -package main // import "golang.org/x/tools/cmd/callgraph" - -// TODO(adonovan): -// -// Features: -// - restrict graph to a single package -// - output -// - functions reachable from root (use digraph tool?) -// - unreachable functions (use digraph tool?) -// - dynamic (runtime) types -// - indexed output (numbered nodes) -// - JSON output -// - additional template fields: -// callee file/line/col - -import ( - "bufio" - "bytes" - "flag" - "fmt" - "go/build" - "go/token" - "io" - "log" - "os" - "runtime" - "text/template" - - "golang.org/x/tools/go/buildutil" - "golang.org/x/tools/go/callgraph" - "golang.org/x/tools/go/callgraph/cha" - "golang.org/x/tools/go/callgraph/rta" - "golang.org/x/tools/go/callgraph/static" - "golang.org/x/tools/go/loader" - "golang.org/x/tools/go/pointer" - "golang.org/x/tools/go/ssa" - "golang.org/x/tools/go/ssa/ssautil" -) - -// flags -var ( - algoFlag = flag.String("algo", "rta", - `Call graph construction algorithm (static, cha, rta, pta)`) - - testFlag = flag.Bool("test", false, - "Loads test code (*_test.go) for imported packages") - - formatFlag = flag.String("format", - "{{.Caller}}\t--{{.Dynamic}}-{{.Line}}:{{.Column}}-->\t{{.Callee}}", - "A template expression specifying how to format an edge") - - ptalogFlag = flag.String("ptalog", "", - "Location of the points-to analysis log file, or empty to disable logging.") -) - -func init() { - flag.Var((*buildutil.TagsFlag)(&build.Default.BuildTags), "tags", buildutil.TagsFlagDoc) -} - -const Usage = `callgraph: display the the call graph of a Go program. - -Usage: - - callgraph [-algo=static|cha|rta|pta] [-test] [-format=...] ... - -Flags: - --algo Specifies the call-graph construction algorithm, one of: - - static static calls only (unsound) - cha Class Hierarchy Analysis - rta Rapid Type Analysis - pta inclusion-based Points-To Analysis - - The algorithms are ordered by increasing precision in their - treatment of dynamic calls (and thus also computational cost). - RTA and PTA require a whole program (main or test), and - include only functions reachable from main. - --test Include the package's tests in the analysis. - --format Specifies the format in which each call graph edge is displayed. - One of: - - digraph output suitable for input to - golang.org/x/tools/cmd/digraph. - graphviz output in AT&T GraphViz (.dot) format. - - All other values are interpreted using text/template syntax. - The default value is: - - {{.Caller}}\t--{{.Dynamic}}-{{.Line}}:{{.Column}}-->\t{{.Callee}} - - The structure passed to the template is (effectively): - - type Edge struct { - Caller *ssa.Function // calling function - Callee *ssa.Function // called function - - // Call site: - Filename string // containing file - Offset int // offset within file of '(' - Line int // line number - Column int // column number of call - Dynamic string // "static" or "dynamic" - Description string // e.g. "static method call" - } - - Caller and Callee are *ssa.Function values, which print as - "(*sync/atomic.Mutex).Lock", but other attributes may be - derived from them, e.g. Caller.Pkg.Pkg.Path yields the - import path of the enclosing package. Consult the go/ssa - API documentation for details. - -` + loader.FromArgsUsage + ` - -Examples: - - Show the call graph of the trivial web server application: - - callgraph -format digraph $GOROOT/src/net/http/triv.go - - Same, but show only the packages of each function: - - callgraph -format '{{.Caller.Pkg.Pkg.Path}} -> {{.Callee.Pkg.Pkg.Path}}' \ - $GOROOT/src/net/http/triv.go | sort | uniq - - Show functions that make dynamic calls into the 'fmt' test package, - using the pointer analysis algorithm: - - callgraph -format='{{.Caller}} -{{.Dynamic}}-> {{.Callee}}' -test -algo=pta fmt | - sed -ne 's/-dynamic-/--/p' | - sed -ne 's/-->.*fmt_test.*$//p' | sort | uniq - - Show all functions directly called by the callgraph tool's main function: - - callgraph -format=digraph golang.org/x/tools/cmd/callgraph | - digraph succs golang.org/x/tools/cmd/callgraph.main -` - -func init() { - // If $GOMAXPROCS isn't set, use the full capacity of the machine. - // For small machines, use at least 4 threads. - if os.Getenv("GOMAXPROCS") == "" { - n := runtime.NumCPU() - if n < 4 { - n = 4 - } - runtime.GOMAXPROCS(n) - } -} - -func main() { - flag.Parse() - if err := doCallgraph(&build.Default, *algoFlag, *formatFlag, *testFlag, flag.Args()); err != nil { - fmt.Fprintf(os.Stderr, "callgraph: %s\n", err) - os.Exit(1) - } -} - -var stdout io.Writer = os.Stdout - -func doCallgraph(ctxt *build.Context, algo, format string, tests bool, args []string) error { - conf := loader.Config{Build: ctxt} - - if len(args) == 0 { - fmt.Fprintln(os.Stderr, Usage) - return nil - } - - // Use the initial packages from the command line. - _, err := conf.FromArgs(args, tests) - if err != nil { - return err - } - - // Load, parse and type-check the whole program. - iprog, err := conf.Load() - if err != nil { - return err - } - - // Create and build SSA-form program representation. - prog := ssautil.CreateProgram(iprog, 0) - prog.Build() - - // -- call graph construction ------------------------------------------ - - var cg *callgraph.Graph - - switch algo { - case "static": - cg = static.CallGraph(prog) - - case "cha": - cg = cha.CallGraph(prog) - - case "pta": - // Set up points-to analysis log file. - var ptalog io.Writer - if *ptalogFlag != "" { - if f, err := os.Create(*ptalogFlag); err != nil { - log.Fatalf("Failed to create PTA log file: %s", err) - } else { - buf := bufio.NewWriter(f) - ptalog = buf - defer func() { - if err := buf.Flush(); err != nil { - log.Printf("flush: %s", err) - } - if err := f.Close(); err != nil { - log.Printf("close: %s", err) - } - }() - } - } - - mains, err := mainPackages(prog, tests) - if err != nil { - return err - } - config := &pointer.Config{ - Mains: mains, - BuildCallGraph: true, - Log: ptalog, - } - ptares, err := pointer.Analyze(config) - if err != nil { - return err // internal error in pointer analysis - } - cg = ptares.CallGraph - - case "rta": - mains, err := mainPackages(prog, tests) - if err != nil { - return err - } - var roots []*ssa.Function - for _, main := range mains { - roots = append(roots, main.Func("init"), main.Func("main")) - } - rtares := rta.Analyze(roots, true) - cg = rtares.CallGraph - - // NB: RTA gives us Reachable and RuntimeTypes too. - - default: - return fmt.Errorf("unknown algorithm: %s", algo) - } - - cg.DeleteSyntheticNodes() - - // -- output------------------------------------------------------------ - - var before, after string - - // Pre-canned formats. - switch format { - case "digraph": - format = `{{printf "%q %q" .Caller .Callee}}` - - case "graphviz": - before = "digraph callgraph {\n" - after = "}\n" - format = ` {{printf "%q" .Caller}} -> {{printf "%q" .Callee}}` - } - - tmpl, err := template.New("-format").Parse(format) - if err != nil { - return fmt.Errorf("invalid -format template: %v", err) - } - - // Allocate these once, outside the traversal. - var buf bytes.Buffer - data := Edge{fset: prog.Fset} - - fmt.Fprint(stdout, before) - if err := callgraph.GraphVisitEdges(cg, func(edge *callgraph.Edge) error { - data.position.Offset = -1 - data.edge = edge - data.Caller = edge.Caller.Func - data.Callee = edge.Callee.Func - - buf.Reset() - if err := tmpl.Execute(&buf, &data); err != nil { - return err - } - stdout.Write(buf.Bytes()) - if len := buf.Len(); len == 0 || buf.Bytes()[len-1] != '\n' { - fmt.Fprintln(stdout) - } - return nil - }); err != nil { - return err - } - fmt.Fprint(stdout, after) - return nil -} - -// mainPackages returns the main packages to analyze. -// Each resulting package is named "main" and has a main function. -func mainPackages(prog *ssa.Program, tests bool) ([]*ssa.Package, error) { - pkgs := prog.AllPackages() // TODO(adonovan): use only initial packages - - // If tests, create a "testmain" package for each test. - var mains []*ssa.Package - if tests { - for _, pkg := range pkgs { - if main := prog.CreateTestMainPackage(pkg); main != nil { - mains = append(mains, main) - } - } - if mains == nil { - return nil, fmt.Errorf("no tests") - } - return mains, nil - } - - // Otherwise, use the main packages. - mains = append(mains, ssautil.MainPackages(pkgs)...) - if len(mains) == 0 { - return nil, fmt.Errorf("no main packages") - } - return mains, nil -} - -type Edge struct { - Caller *ssa.Function - Callee *ssa.Function - - edge *callgraph.Edge - fset *token.FileSet - position token.Position // initialized lazily -} - -func (e *Edge) pos() *token.Position { - if e.position.Offset == -1 { - e.position = e.fset.Position(e.edge.Pos()) // called lazily - } - return &e.position -} - -func (e *Edge) Filename() string { return e.pos().Filename } -func (e *Edge) Column() int { return e.pos().Column } -func (e *Edge) Line() int { return e.pos().Line } -func (e *Edge) Offset() int { return e.pos().Offset } - -func (e *Edge) Dynamic() string { - if e.edge.Site != nil && e.edge.Site.Common().StaticCallee() == nil { - return "dynamic" - } - return "static" -} - -func (e *Edge) Description() string { return e.edge.Description() } diff --git a/vendor/golang.org/x/tools/cmd/callgraph/main_test.go b/vendor/golang.org/x/tools/cmd/callgraph/main_test.go deleted file mode 100644 index c42f56d..0000000 --- a/vendor/golang.org/x/tools/cmd/callgraph/main_test.go +++ /dev/null @@ -1,81 +0,0 @@ -// Copyright 2014 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// No testdata on Android. - -// +build !android - -package main - -import ( - "bytes" - "fmt" - "go/build" - "reflect" - "sort" - "strings" - "testing" -) - -func TestCallgraph(t *testing.T) { - ctxt := build.Default // copy - ctxt.GOPATH = "testdata" - - const format = "{{.Caller}} --> {{.Callee}}" - - for _, test := range []struct { - algo, format string - tests bool - want []string - }{ - {"rta", format, false, []string{ - // rta imprecisely shows cross product of {main,main2} x {C,D} - `pkg.main --> (pkg.C).f`, - `pkg.main --> (pkg.D).f`, - `pkg.main --> pkg.main2`, - `pkg.main2 --> (pkg.C).f`, - `pkg.main2 --> (pkg.D).f`, - }}, - {"pta", format, false, []string{ - // pta distinguishes main->C, main2->D. Also has a root node. - ` --> pkg.init`, - ` --> pkg.main`, - `pkg.main --> (pkg.C).f`, - `pkg.main --> pkg.main2`, - `pkg.main2 --> (pkg.D).f`, - }}, - // tests: main is not called. - {"rta", format, true, []string{ - `pkg$testmain.init --> pkg.init`, - `pkg.Example --> (pkg.C).f`, - }}, - {"pta", format, true, []string{ - ` --> pkg$testmain.init`, - ` --> pkg.Example`, - `pkg$testmain.init --> pkg.init`, - `pkg.Example --> (pkg.C).f`, - }}, - } { - stdout = new(bytes.Buffer) - if err := doCallgraph(&ctxt, test.algo, test.format, test.tests, []string{"pkg"}); err != nil { - t.Error(err) - continue - } - - got := sortedLines(fmt.Sprint(stdout)) - if !reflect.DeepEqual(got, test.want) { - t.Errorf("callgraph(%q, %q, %t):\ngot:\n%s\nwant:\n%s", - test.algo, test.format, test.tests, - strings.Join(got, "\n"), - strings.Join(test.want, "\n")) - } - } -} - -func sortedLines(s string) []string { - s = strings.TrimSpace(s) - lines := strings.Split(s, "\n") - sort.Strings(lines) - return lines -} diff --git a/vendor/golang.org/x/tools/cmd/callgraph/testdata/src/pkg/pkg.go b/vendor/golang.org/x/tools/cmd/callgraph/testdata/src/pkg/pkg.go deleted file mode 100644 index b81c97f..0000000 --- a/vendor/golang.org/x/tools/cmd/callgraph/testdata/src/pkg/pkg.go +++ /dev/null @@ -1,25 +0,0 @@ -package main - -type I interface { - f() -} - -type C int - -func (C) f() {} - -type D int - -func (D) f() {} - -func main() { - var i I = C(0) - i.f() // dynamic call - - main2() -} - -func main2() { - var i I = D(0) - i.f() // dynamic call -} diff --git a/vendor/golang.org/x/tools/cmd/callgraph/testdata/src/pkg/pkg_test.go b/vendor/golang.org/x/tools/cmd/callgraph/testdata/src/pkg/pkg_test.go deleted file mode 100644 index d624757..0000000 --- a/vendor/golang.org/x/tools/cmd/callgraph/testdata/src/pkg/pkg_test.go +++ /dev/null @@ -1,7 +0,0 @@ -package main - -// Don't import "testing", it adds a lot of callgraph edges. - -func Example() { - C(0).f() -} diff --git a/vendor/golang.org/x/tools/cmd/compilebench/main.go b/vendor/golang.org/x/tools/cmd/compilebench/main.go deleted file mode 100644 index d2cd70b..0000000 --- a/vendor/golang.org/x/tools/cmd/compilebench/main.go +++ /dev/null @@ -1,360 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Compilebench benchmarks the speed of the Go compiler. -// -// Usage: -// -// compilebench [options] -// -// It times the compilation of various packages and prints results in -// the format used by package testing (and expected by golang.org/x/perf/cmd/benchstat). -// -// The options are: -// -// -alloc -// Report allocations. -// -// -compile exe -// Use exe as the path to the cmd/compile binary. -// -// -compileflags 'list' -// Pass the space-separated list of flags to the compilation. -// -// -count n -// Run each benchmark n times (default 1). -// -// -cpuprofile file -// Write a CPU profile of the compiler to file. -// -// -memprofile file -// Write a memory profile of the compiler to file. -// -// -memprofilerate rate -// Set runtime.MemProfileRate during compilation. -// -// -obj -// Report object file statistics. -// -// -pkg -// Benchmark compiling a single package. -// -// -run regexp -// Only run benchmarks with names matching regexp. -// -// Although -cpuprofile and -memprofile are intended to write a -// combined profile for all the executed benchmarks to file, -// today they write only the profile for the last benchmark executed. -// -// The default memory profiling rate is one profile sample per 512 kB -// allocated (see ``go doc runtime.MemProfileRate''). -// Lowering the rate (for example, -memprofilerate 64000) produces -// a more fine-grained and therefore accurate profile, but it also incurs -// execution cost. For benchmark comparisons, never use timings -// obtained with a low -memprofilerate option. -// -// Example -// -// Assuming the base version of the compiler has been saved with -// ``toolstash save,'' this sequence compares the old and new compiler: -// -// compilebench -count 10 -compile $(toolstash -n compile) >old.txt -// compilebench -count 10 >new.txt -// benchstat old.txt new.txt -// -package main - -import ( - "bytes" - "flag" - "fmt" - "go/build" - "io/ioutil" - "log" - "os" - "os/exec" - "path/filepath" - "regexp" - "strconv" - "strings" - "time" -) - -var ( - goroot string - compiler string - runRE *regexp.Regexp - is6g bool -) - -var ( - flagGoCmd = flag.String("go", "go", "path to \"go\" command") - flagAlloc = flag.Bool("alloc", false, "report allocations") - flagObj = flag.Bool("obj", false, "report object file stats") - flagCompiler = flag.String("compile", "", "use `exe` as the cmd/compile binary") - flagCompilerFlags = flag.String("compileflags", "", "additional `flags` to pass to compile") - flagRun = flag.String("run", "", "run benchmarks matching `regexp`") - flagCount = flag.Int("count", 1, "run benchmarks `n` times") - flagCpuprofile = flag.String("cpuprofile", "", "write CPU profile to `file`") - flagMemprofile = flag.String("memprofile", "", "write memory profile to `file`") - flagMemprofilerate = flag.Int64("memprofilerate", -1, "set memory profile `rate`") - flagPackage = flag.String("pkg", "", "if set, benchmark the package at path `pkg`") - flagShort = flag.Bool("short", false, "skip long-running benchmarks") -) - -var tests = []struct { - name string - dir string - long bool -}{ - {"BenchmarkTemplate", "html/template", false}, - {"BenchmarkUnicode", "unicode", false}, - {"BenchmarkGoTypes", "go/types", false}, - {"BenchmarkCompiler", "cmd/compile/internal/gc", false}, - {"BenchmarkSSA", "cmd/compile/internal/ssa", false}, - {"BenchmarkFlate", "compress/flate", false}, - {"BenchmarkGoParser", "go/parser", false}, - {"BenchmarkReflect", "reflect", false}, - {"BenchmarkTar", "archive/tar", false}, - {"BenchmarkXML", "encoding/xml", false}, - {"BenchmarkStdCmd", "", true}, - {"BenchmarkHelloSize", "", false}, - {"BenchmarkCmdGoSize", "", true}, -} - -func usage() { - fmt.Fprintf(os.Stderr, "usage: compilebench [options]\n") - fmt.Fprintf(os.Stderr, "options:\n") - flag.PrintDefaults() - os.Exit(2) -} - -func main() { - log.SetFlags(0) - log.SetPrefix("compilebench: ") - flag.Usage = usage - flag.Parse() - if flag.NArg() != 0 { - usage() - } - - s, err := exec.Command(*flagGoCmd, "env", "GOROOT").CombinedOutput() - if err != nil { - log.Fatalf("%s env GOROOT: %v", *flagGoCmd, err) - } - goroot = strings.TrimSpace(string(s)) - - compiler = *flagCompiler - if compiler == "" { - out, err := exec.Command(*flagGoCmd, "tool", "-n", "compile").CombinedOutput() - if err != nil { - out, err = exec.Command(*flagGoCmd, "tool", "-n", "6g").CombinedOutput() - is6g = true - if err != nil { - out, err = exec.Command(*flagGoCmd, "tool", "-n", "compile").CombinedOutput() - log.Fatalf("go tool -n compiler: %v\n%s", err, out) - } - } - compiler = strings.TrimSpace(string(out)) - } - - if *flagRun != "" { - r, err := regexp.Compile(*flagRun) - if err != nil { - log.Fatalf("invalid -run argument: %v", err) - } - runRE = r - } - - for i := 0; i < *flagCount; i++ { - if *flagPackage != "" { - runBuild("BenchmarkPkg", *flagPackage, i) - continue - } - for _, tt := range tests { - if tt.long && *flagShort { - continue - } - if runRE == nil || runRE.MatchString(tt.name) { - runBuild(tt.name, tt.dir, i) - } - } - } -} - -func runCmd(name string, cmd *exec.Cmd) { - start := time.Now() - out, err := cmd.CombinedOutput() - if err != nil { - log.Printf("%v: %v\n%s", name, err, out) - return - } - fmt.Printf("%s 1 %d ns/op\n", name, time.Since(start).Nanoseconds()) -} - -func runStdCmd() { - args := []string{"build", "-a"} - if *flagCompilerFlags != "" { - args = append(args, "-gcflags", *flagCompilerFlags) - } - args = append(args, "std", "cmd") - cmd := exec.Command(*flagGoCmd, args...) - cmd.Dir = filepath.Join(goroot, "src") - runCmd("BenchmarkStdCmd", cmd) -} - -// path is either a path to a file ("$GOROOT/test/helloworld.go") or a package path ("cmd/go"). -func runSize(name, path string) { - cmd := exec.Command(*flagGoCmd, "build", "-o", "_compilebenchout_", path) - cmd.Stdout = os.Stderr - cmd.Stderr = os.Stderr - if err := cmd.Run(); err != nil { - log.Print(err) - return - } - defer os.Remove("_compilebenchout_") - info, err := os.Stat("_compilebenchout_") - if err != nil { - log.Print(err) - return - } - out, err := exec.Command("size", "_compilebenchout_").CombinedOutput() - if err != nil { - log.Printf("size: %v\n%s", err, out) - return - } - lines := strings.Split(string(out), "\n") - if len(lines) < 2 { - log.Printf("not enough output from size: %s", out) - return - } - f := strings.Fields(lines[1]) - if strings.HasPrefix(lines[0], "__TEXT") && len(f) >= 2 { // OS X - fmt.Printf("%s 1 %s text-bytes %s data-bytes %v exe-bytes\n", name, f[0], f[1], info.Size()) - } else if strings.Contains(lines[0], "bss") && len(f) >= 3 { - fmt.Printf("%s 1 %s text-bytes %s data-bytes %s bss-bytes %v exe-bytes\n", name, f[0], f[1], f[2], info.Size()) - } -} - -func runBuild(name, dir string, count int) { - switch name { - case "BenchmarkStdCmd": - runStdCmd() - return - case "BenchmarkCmdGoSize": - runSize("BenchmarkCmdGoSize", "cmd/go") - return - case "BenchmarkHelloSize": - runSize("BenchmarkHelloSize", filepath.Join(goroot, "test/helloworld.go")) - return - } - - pkg, err := build.Import(dir, ".", 0) - if err != nil { - log.Print(err) - return - } - args := []string{"-o", "_compilebench_.o"} - if is6g { - *flagMemprofilerate = -1 - *flagAlloc = false - *flagCpuprofile = "" - *flagMemprofile = "" - } - if *flagMemprofilerate >= 0 { - args = append(args, "-memprofilerate", fmt.Sprint(*flagMemprofilerate)) - } - args = append(args, strings.Fields(*flagCompilerFlags)...) - if *flagAlloc || *flagCpuprofile != "" || *flagMemprofile != "" { - if *flagAlloc || *flagMemprofile != "" { - args = append(args, "-memprofile", "_compilebench_.memprof") - } - if *flagCpuprofile != "" { - args = append(args, "-cpuprofile", "_compilebench_.cpuprof") - } - } - args = append(args, pkg.GoFiles...) - cmd := exec.Command(compiler, args...) - cmd.Dir = pkg.Dir - cmd.Stdout = os.Stderr - cmd.Stderr = os.Stderr - start := time.Now() - err = cmd.Run() - if err != nil { - log.Printf("%v: %v", name, err) - return - } - end := time.Now() - - var allocs, allocbytes int64 - if *flagAlloc || *flagMemprofile != "" { - out, err := ioutil.ReadFile(pkg.Dir + "/_compilebench_.memprof") - if err != nil { - log.Print("cannot find memory profile after compilation") - } - for _, line := range strings.Split(string(out), "\n") { - f := strings.Fields(line) - if len(f) < 4 || f[0] != "#" || f[2] != "=" { - continue - } - val, err := strconv.ParseInt(f[3], 0, 64) - if err != nil { - continue - } - switch f[1] { - case "TotalAlloc": - allocbytes = val - case "Mallocs": - allocs = val - } - } - - if *flagMemprofile != "" { - if err := ioutil.WriteFile(*flagMemprofile, out, 0666); err != nil { - log.Print(err) - } - } - os.Remove(pkg.Dir + "/_compilebench_.memprof") - } - - if *flagCpuprofile != "" { - out, err := ioutil.ReadFile(pkg.Dir + "/_compilebench_.cpuprof") - if err != nil { - log.Print(err) - } - outpath := *flagCpuprofile - if *flagCount != 1 { - outpath = fmt.Sprintf("%s_%d", outpath, count) - } - if err := ioutil.WriteFile(outpath, out, 0666); err != nil { - log.Print(err) - } - os.Remove(pkg.Dir + "/_compilebench_.cpuprof") - } - - wallns := end.Sub(start).Nanoseconds() - userns := cmd.ProcessState.UserTime().Nanoseconds() - - fmt.Printf("%s 1 %d ns/op %d user-ns/op", name, wallns, userns) - if *flagAlloc { - fmt.Printf(" %d B/op %d allocs/op", allocbytes, allocs) - } - - opath := pkg.Dir + "/_compilebench_.o" - if *flagObj { - // TODO(josharian): object files are big; just read enough to find what we seek. - data, err := ioutil.ReadFile(opath) - if err != nil { - log.Print(err) - } - // Find start of export data. - i := bytes.Index(data, []byte("\n$$B\n")) + len("\n$$B\n") - // Count bytes to end of export data. - nexport := bytes.Index(data[i:], []byte("\n$$\n")) - fmt.Printf(" %d object-bytes %d export-bytes", len(data), nexport) - } - fmt.Println() - - os.Remove(opath) -} diff --git a/vendor/golang.org/x/tools/cmd/cover/README b/vendor/golang.org/x/tools/cmd/cover/README deleted file mode 100644 index ff9523d..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/README +++ /dev/null @@ -1,2 +0,0 @@ -NOTE: For Go releases 1.5 and later, this tool lives in the -standard repository. The code here is not maintained. diff --git a/vendor/golang.org/x/tools/cmd/cover/cover.go b/vendor/golang.org/x/tools/cmd/cover/cover.go deleted file mode 100644 index e093364..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/cover.go +++ /dev/null @@ -1,722 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package main - -import ( - "bytes" - "flag" - "fmt" - "go/ast" - "go/parser" - "go/printer" - "go/token" - "io" - "io/ioutil" - "log" - "os" - "path/filepath" - "sort" - "strconv" - "strings" -) - -const usageMessage = "" + - `Usage of 'go tool cover': -Given a coverage profile produced by 'go test': - go test -coverprofile=c.out - -Open a web browser displaying annotated source code: - go tool cover -html=c.out - -Write out an HTML file instead of launching a web browser: - go tool cover -html=c.out -o coverage.html - -Display coverage percentages to stdout for each function: - go tool cover -func=c.out - -Finally, to generate modified source code with coverage annotations -(what go test -cover does): - go tool cover -mode=set -var=CoverageVariableName program.go -` - -func usage() { - fmt.Fprintln(os.Stderr, usageMessage) - fmt.Fprintln(os.Stderr, "Flags:") - flag.PrintDefaults() - fmt.Fprintln(os.Stderr, "\n Only one of -html, -func, or -mode may be set.") - os.Exit(2) -} - -var ( - mode = flag.String("mode", "", "coverage mode: set, count, atomic") - varVar = flag.String("var", "GoCover", "name of coverage variable to generate") - output = flag.String("o", "", "file for output; default: stdout") - htmlOut = flag.String("html", "", "generate HTML representation of coverage profile") - funcOut = flag.String("func", "", "output coverage profile information for each function") -) - -var profile string // The profile to read; the value of -html or -func - -var counterStmt func(*File, ast.Expr) ast.Stmt - -const ( - atomicPackagePath = "sync/atomic" - atomicPackageName = "_cover_atomic_" -) - -func main() { - flag.Usage = usage - flag.Parse() - - // Usage information when no arguments. - if flag.NFlag() == 0 && flag.NArg() == 0 { - flag.Usage() - } - - err := parseFlags() - if err != nil { - fmt.Fprintln(os.Stderr, err) - fmt.Fprintln(os.Stderr, `For usage information, run "go tool cover -help"`) - os.Exit(2) - } - - // Generate coverage-annotated source. - if *mode != "" { - annotate(flag.Arg(0)) - return - } - - // Output HTML or function coverage information. - if *htmlOut != "" { - err = htmlOutput(profile, *output) - } else { - err = funcOutput(profile, *output) - } - - if err != nil { - fmt.Fprintf(os.Stderr, "cover: %v\n", err) - os.Exit(2) - } -} - -// parseFlags sets the profile and counterStmt globals and performs validations. -func parseFlags() error { - profile = *htmlOut - if *funcOut != "" { - if profile != "" { - return fmt.Errorf("too many options") - } - profile = *funcOut - } - - // Must either display a profile or rewrite Go source. - if (profile == "") == (*mode == "") { - return fmt.Errorf("too many options") - } - - if *mode != "" { - switch *mode { - case "set": - counterStmt = setCounterStmt - case "count": - counterStmt = incCounterStmt - case "atomic": - counterStmt = atomicCounterStmt - default: - return fmt.Errorf("unknown -mode %v", *mode) - } - - if flag.NArg() == 0 { - return fmt.Errorf("missing source file") - } else if flag.NArg() == 1 { - return nil - } - } else if flag.NArg() == 0 { - return nil - } - return fmt.Errorf("too many arguments") -} - -// Block represents the information about a basic block to be recorded in the analysis. -// Note: Our definition of basic block is based on control structures; we don't break -// apart && and ||. We could but it doesn't seem important enough to bother. -type Block struct { - startByte token.Pos - endByte token.Pos - numStmt int -} - -// File is a wrapper for the state of a file used in the parser. -// The basic parse tree walker is a method of this type. -type File struct { - fset *token.FileSet - name string // Name of file. - astFile *ast.File - blocks []Block - atomicPkg string // Package name for "sync/atomic" in this file. -} - -// Visit implements the ast.Visitor interface. -func (f *File) Visit(node ast.Node) ast.Visitor { - switch n := node.(type) { - case *ast.BlockStmt: - // If it's a switch or select, the body is a list of case clauses; don't tag the block itself. - if len(n.List) > 0 { - switch n.List[0].(type) { - case *ast.CaseClause: // switch - for _, n := range n.List { - clause := n.(*ast.CaseClause) - clause.Body = f.addCounters(clause.Pos(), clause.End(), clause.Body, false) - } - return f - case *ast.CommClause: // select - for _, n := range n.List { - clause := n.(*ast.CommClause) - clause.Body = f.addCounters(clause.Pos(), clause.End(), clause.Body, false) - } - return f - } - } - n.List = f.addCounters(n.Lbrace, n.Rbrace+1, n.List, true) // +1 to step past closing brace. - case *ast.IfStmt: - ast.Walk(f, n.Body) - if n.Else == nil { - return nil - } - // The elses are special, because if we have - // if x { - // } else if y { - // } - // we want to cover the "if y". To do this, we need a place to drop the counter, - // so we add a hidden block: - // if x { - // } else { - // if y { - // } - // } - switch stmt := n.Else.(type) { - case *ast.IfStmt: - block := &ast.BlockStmt{ - Lbrace: n.Body.End(), // Start at end of the "if" block so the covered part looks like it starts at the "else". - List: []ast.Stmt{stmt}, - Rbrace: stmt.End(), - } - n.Else = block - case *ast.BlockStmt: - stmt.Lbrace = n.Body.End() // Start at end of the "if" block so the covered part looks like it starts at the "else". - default: - panic("unexpected node type in if") - } - ast.Walk(f, n.Else) - return nil - case *ast.SelectStmt: - // Don't annotate an empty select - creates a syntax error. - if n.Body == nil || len(n.Body.List) == 0 { - return nil - } - case *ast.SwitchStmt: - // Don't annotate an empty switch - creates a syntax error. - if n.Body == nil || len(n.Body.List) == 0 { - return nil - } - case *ast.TypeSwitchStmt: - // Don't annotate an empty type switch - creates a syntax error. - if n.Body == nil || len(n.Body.List) == 0 { - return nil - } - } - return f -} - -// unquote returns the unquoted string. -func unquote(s string) string { - t, err := strconv.Unquote(s) - if err != nil { - log.Fatalf("cover: improperly quoted string %q\n", s) - } - return t -} - -// addImport adds an import for the specified path, if one does not already exist, and returns -// the local package name. -func (f *File) addImport(path string) string { - // Does the package already import it? - for _, s := range f.astFile.Imports { - if unquote(s.Path.Value) == path { - if s.Name != nil { - return s.Name.Name - } - return filepath.Base(path) - } - } - newImport := &ast.ImportSpec{ - Name: ast.NewIdent(atomicPackageName), - Path: &ast.BasicLit{ - Kind: token.STRING, - Value: fmt.Sprintf("%q", path), - }, - } - impDecl := &ast.GenDecl{ - Tok: token.IMPORT, - Specs: []ast.Spec{ - newImport, - }, - } - // Make the new import the first Decl in the file. - astFile := f.astFile - astFile.Decls = append(astFile.Decls, nil) - copy(astFile.Decls[1:], astFile.Decls[0:]) - astFile.Decls[0] = impDecl - astFile.Imports = append(astFile.Imports, newImport) - - // Now refer to the package, just in case it ends up unused. - // That is, append to the end of the file the declaration - // var _ = _cover_atomic_.AddUint32 - reference := &ast.GenDecl{ - Tok: token.VAR, - Specs: []ast.Spec{ - &ast.ValueSpec{ - Names: []*ast.Ident{ - ast.NewIdent("_"), - }, - Values: []ast.Expr{ - &ast.SelectorExpr{ - X: ast.NewIdent(atomicPackageName), - Sel: ast.NewIdent("AddUint32"), - }, - }, - }, - }, - } - astFile.Decls = append(astFile.Decls, reference) - return atomicPackageName -} - -var slashslash = []byte("//") - -// initialComments returns the prefix of content containing only -// whitespace and line comments. Any +build directives must appear -// within this region. This approach is more reliable than using -// go/printer to print a modified AST containing comments. -// -func initialComments(content []byte) []byte { - // Derived from go/build.Context.shouldBuild. - end := 0 - p := content - for len(p) > 0 { - line := p - if i := bytes.IndexByte(line, '\n'); i >= 0 { - line, p = line[:i], p[i+1:] - } else { - p = p[len(p):] - } - line = bytes.TrimSpace(line) - if len(line) == 0 { // Blank line. - end = len(content) - len(p) - continue - } - if !bytes.HasPrefix(line, slashslash) { // Not comment line. - break - } - } - return content[:end] -} - -func annotate(name string) { - fset := token.NewFileSet() - content, err := ioutil.ReadFile(name) - if err != nil { - log.Fatalf("cover: %s: %s", name, err) - } - parsedFile, err := parser.ParseFile(fset, name, content, parser.ParseComments) - if err != nil { - log.Fatalf("cover: %s: %s", name, err) - } - parsedFile.Comments = trimComments(parsedFile, fset) - - file := &File{ - fset: fset, - name: name, - astFile: parsedFile, - } - if *mode == "atomic" { - file.atomicPkg = file.addImport(atomicPackagePath) - } - ast.Walk(file, file.astFile) - fd := os.Stdout - if *output != "" { - var err error - fd, err = os.Create(*output) - if err != nil { - log.Fatalf("cover: %s", err) - } - } - fd.Write(initialComments(content)) // Retain '// +build' directives. - file.print(fd) - // After printing the source tree, add some declarations for the counters etc. - // We could do this by adding to the tree, but it's easier just to print the text. - file.addVariables(fd) -} - -// trimComments drops all but the //go: comments, some of which are semantically important. -// We drop all others because they can appear in places that cause our counters -// to appear in syntactically incorrect places. //go: appears at the beginning of -// the line and is syntactically safe. -func trimComments(file *ast.File, fset *token.FileSet) []*ast.CommentGroup { - var comments []*ast.CommentGroup - for _, group := range file.Comments { - var list []*ast.Comment - for _, comment := range group.List { - if strings.HasPrefix(comment.Text, "//go:") && fset.Position(comment.Slash).Column == 1 { - list = append(list, comment) - } - } - if list != nil { - comments = append(comments, &ast.CommentGroup{List: list}) - } - } - return comments -} - -func (f *File) print(w io.Writer) { - printer.Fprint(w, f.fset, f.astFile) -} - -// intLiteral returns an ast.BasicLit representing the integer value. -func (f *File) intLiteral(i int) *ast.BasicLit { - node := &ast.BasicLit{ - Kind: token.INT, - Value: fmt.Sprint(i), - } - return node -} - -// index returns an ast.BasicLit representing the number of counters present. -func (f *File) index() *ast.BasicLit { - return f.intLiteral(len(f.blocks)) -} - -// setCounterStmt returns the expression: __count[23] = 1. -func setCounterStmt(f *File, counter ast.Expr) ast.Stmt { - return &ast.AssignStmt{ - Lhs: []ast.Expr{counter}, - Tok: token.ASSIGN, - Rhs: []ast.Expr{f.intLiteral(1)}, - } -} - -// incCounterStmt returns the expression: __count[23]++. -func incCounterStmt(f *File, counter ast.Expr) ast.Stmt { - return &ast.IncDecStmt{ - X: counter, - Tok: token.INC, - } -} - -// atomicCounterStmt returns the expression: atomic.AddUint32(&__count[23], 1) -func atomicCounterStmt(f *File, counter ast.Expr) ast.Stmt { - return &ast.ExprStmt{ - X: &ast.CallExpr{ - Fun: &ast.SelectorExpr{ - X: ast.NewIdent(f.atomicPkg), - Sel: ast.NewIdent("AddUint32"), - }, - Args: []ast.Expr{&ast.UnaryExpr{ - Op: token.AND, - X: counter, - }, - f.intLiteral(1), - }, - }, - } -} - -// newCounter creates a new counter expression of the appropriate form. -func (f *File) newCounter(start, end token.Pos, numStmt int) ast.Stmt { - counter := &ast.IndexExpr{ - X: &ast.SelectorExpr{ - X: ast.NewIdent(*varVar), - Sel: ast.NewIdent("Count"), - }, - Index: f.index(), - } - stmt := counterStmt(f, counter) - f.blocks = append(f.blocks, Block{start, end, numStmt}) - return stmt -} - -// addCounters takes a list of statements and adds counters to the beginning of -// each basic block at the top level of that list. For instance, given -// -// S1 -// if cond { -// S2 -// } -// S3 -// -// counters will be added before S1 and before S3. The block containing S2 -// will be visited in a separate call. -// TODO: Nested simple blocks get unnecessary (but correct) counters -func (f *File) addCounters(pos, blockEnd token.Pos, list []ast.Stmt, extendToClosingBrace bool) []ast.Stmt { - // Special case: make sure we add a counter to an empty block. Can't do this below - // or we will add a counter to an empty statement list after, say, a return statement. - if len(list) == 0 { - return []ast.Stmt{f.newCounter(pos, blockEnd, 0)} - } - // We have a block (statement list), but it may have several basic blocks due to the - // appearance of statements that affect the flow of control. - var newList []ast.Stmt - for { - // Find first statement that affects flow of control (break, continue, if, etc.). - // It will be the last statement of this basic block. - var last int - end := blockEnd - for last = 0; last < len(list); last++ { - end = f.statementBoundary(list[last]) - if f.endsBasicSourceBlock(list[last]) { - extendToClosingBrace = false // Block is broken up now. - last++ - break - } - } - if extendToClosingBrace { - end = blockEnd - } - if pos != end { // Can have no source to cover if e.g. blocks abut. - newList = append(newList, f.newCounter(pos, end, last)) - } - newList = append(newList, list[0:last]...) - list = list[last:] - if len(list) == 0 { - break - } - pos = list[0].Pos() - } - return newList -} - -// hasFuncLiteral reports the existence and position of the first func literal -// in the node, if any. If a func literal appears, it usually marks the termination -// of a basic block because the function body is itself a block. -// Therefore we draw a line at the start of the body of the first function literal we find. -// TODO: what if there's more than one? Probably doesn't matter much. -func hasFuncLiteral(n ast.Node) (bool, token.Pos) { - if n == nil { - return false, 0 - } - var literal funcLitFinder - ast.Walk(&literal, n) - return literal.found(), token.Pos(literal) -} - -// statementBoundary finds the location in s that terminates the current basic -// block in the source. -func (f *File) statementBoundary(s ast.Stmt) token.Pos { - // Control flow statements are easy. - switch s := s.(type) { - case *ast.BlockStmt: - // Treat blocks like basic blocks to avoid overlapping counters. - return s.Lbrace - case *ast.IfStmt: - found, pos := hasFuncLiteral(s.Init) - if found { - return pos - } - found, pos = hasFuncLiteral(s.Cond) - if found { - return pos - } - return s.Body.Lbrace - case *ast.ForStmt: - found, pos := hasFuncLiteral(s.Init) - if found { - return pos - } - found, pos = hasFuncLiteral(s.Cond) - if found { - return pos - } - found, pos = hasFuncLiteral(s.Post) - if found { - return pos - } - return s.Body.Lbrace - case *ast.LabeledStmt: - return f.statementBoundary(s.Stmt) - case *ast.RangeStmt: - found, pos := hasFuncLiteral(s.X) - if found { - return pos - } - return s.Body.Lbrace - case *ast.SwitchStmt: - found, pos := hasFuncLiteral(s.Init) - if found { - return pos - } - found, pos = hasFuncLiteral(s.Tag) - if found { - return pos - } - return s.Body.Lbrace - case *ast.SelectStmt: - return s.Body.Lbrace - case *ast.TypeSwitchStmt: - found, pos := hasFuncLiteral(s.Init) - if found { - return pos - } - return s.Body.Lbrace - } - // If not a control flow statement, it is a declaration, expression, call, etc. and it may have a function literal. - // If it does, that's tricky because we want to exclude the body of the function from this block. - // Draw a line at the start of the body of the first function literal we find. - // TODO: what if there's more than one? Probably doesn't matter much. - found, pos := hasFuncLiteral(s) - if found { - return pos - } - return s.End() -} - -// endsBasicSourceBlock reports whether s changes the flow of control: break, if, etc., -// or if it's just problematic, for instance contains a function literal, which will complicate -// accounting due to the block-within-an expression. -func (f *File) endsBasicSourceBlock(s ast.Stmt) bool { - switch s := s.(type) { - case *ast.BlockStmt: - // Treat blocks like basic blocks to avoid overlapping counters. - return true - case *ast.BranchStmt: - return true - case *ast.ForStmt: - return true - case *ast.IfStmt: - return true - case *ast.LabeledStmt: - return f.endsBasicSourceBlock(s.Stmt) - case *ast.RangeStmt: - return true - case *ast.SwitchStmt: - return true - case *ast.SelectStmt: - return true - case *ast.TypeSwitchStmt: - return true - case *ast.ExprStmt: - // Calls to panic change the flow. - // We really should verify that "panic" is the predefined function, - // but without type checking we can't and the likelihood of it being - // an actual problem is vanishingly small. - if call, ok := s.X.(*ast.CallExpr); ok { - if ident, ok := call.Fun.(*ast.Ident); ok && ident.Name == "panic" && len(call.Args) == 1 { - return true - } - } - } - found, _ := hasFuncLiteral(s) - return found -} - -// funcLitFinder implements the ast.Visitor pattern to find the location of any -// function literal in a subtree. -type funcLitFinder token.Pos - -func (f *funcLitFinder) Visit(node ast.Node) (w ast.Visitor) { - if f.found() { - return nil // Prune search. - } - switch n := node.(type) { - case *ast.FuncLit: - *f = funcLitFinder(n.Body.Lbrace) - return nil // Prune search. - } - return f -} - -func (f *funcLitFinder) found() bool { - return token.Pos(*f) != token.NoPos -} - -// Sort interface for []block1; used for self-check in addVariables. - -type block1 struct { - Block - index int -} - -type blockSlice []block1 - -func (b blockSlice) Len() int { return len(b) } -func (b blockSlice) Less(i, j int) bool { return b[i].startByte < b[j].startByte } -func (b blockSlice) Swap(i, j int) { b[i], b[j] = b[j], b[i] } - -// offset translates a token position into a 0-indexed byte offset. -func (f *File) offset(pos token.Pos) int { - return f.fset.Position(pos).Offset -} - -// addVariables adds to the end of the file the declarations to set up the counter and position variables. -func (f *File) addVariables(w io.Writer) { - // Self-check: Verify that the instrumented basic blocks are disjoint. - t := make([]block1, len(f.blocks)) - for i := range f.blocks { - t[i].Block = f.blocks[i] - t[i].index = i - } - sort.Sort(blockSlice(t)) - for i := 1; i < len(t); i++ { - if t[i-1].endByte > t[i].startByte { - fmt.Fprintf(os.Stderr, "cover: internal error: block %d overlaps block %d\n", t[i-1].index, t[i].index) - // Note: error message is in byte positions, not token positions. - fmt.Fprintf(os.Stderr, "\t%s:#%d,#%d %s:#%d,#%d\n", - f.name, f.offset(t[i-1].startByte), f.offset(t[i-1].endByte), - f.name, f.offset(t[i].startByte), f.offset(t[i].endByte)) - } - } - - // Declare the coverage struct as a package-level variable. - fmt.Fprintf(w, "\nvar %s = struct {\n", *varVar) - fmt.Fprintf(w, "\tCount [%d]uint32\n", len(f.blocks)) - fmt.Fprintf(w, "\tPos [3 * %d]uint32\n", len(f.blocks)) - fmt.Fprintf(w, "\tNumStmt [%d]uint16\n", len(f.blocks)) - fmt.Fprintf(w, "} {\n") - - // Initialize the position array field. - fmt.Fprintf(w, "\tPos: [3 * %d]uint32{\n", len(f.blocks)) - - // A nice long list of positions. Each position is encoded as follows to reduce size: - // - 32-bit starting line number - // - 32-bit ending line number - // - (16 bit ending column number << 16) | (16-bit starting column number). - for i, block := range f.blocks { - start := f.fset.Position(block.startByte) - end := f.fset.Position(block.endByte) - fmt.Fprintf(w, "\t\t%d, %d, %#x, // [%d]\n", start.Line, end.Line, (end.Column&0xFFFF)<<16|(start.Column&0xFFFF), i) - } - - // Close the position array. - fmt.Fprintf(w, "\t},\n") - - // Initialize the position array field. - fmt.Fprintf(w, "\tNumStmt: [%d]uint16{\n", len(f.blocks)) - - // A nice long list of statements-per-block, so we can give a conventional - // valuation of "percent covered". To save space, it's a 16-bit number, so we - // clamp it if it overflows - won't matter in practice. - for i, block := range f.blocks { - n := block.numStmt - if n > 1<<16-1 { - n = 1<<16 - 1 - } - fmt.Fprintf(w, "\t\t%d, // %d\n", n, i) - } - - // Close the statements-per-block array. - fmt.Fprintf(w, "\t},\n") - - // Close the struct initialization. - fmt.Fprintf(w, "}\n") -} diff --git a/vendor/golang.org/x/tools/cmd/cover/cover_test.go b/vendor/golang.org/x/tools/cmd/cover/cover_test.go deleted file mode 100644 index a18778b..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/cover_test.go +++ /dev/null @@ -1,94 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// No testdata on Android. - -// +build !android - -package main_test - -import ( - "bytes" - "fmt" - "io/ioutil" - "os" - "os/exec" - "path/filepath" - "testing" -) - -const ( - // Data directory, also the package directory for the test. - testdata = "testdata" - - // Binaries we compile. - testcover = "./testcover.exe" -) - -var ( - // Files we use. - testMain = filepath.Join(testdata, "main.go") - testTest = filepath.Join(testdata, "test.go") - coverInput = filepath.Join(testdata, "test_line.go") - coverOutput = filepath.Join(testdata, "test_cover.go") -) - -var debug = false // Keeps the rewritten files around if set. - -// Run this shell script, but do it in Go so it can be run by "go test". -// -// replace the word LINE with the line number < testdata/test.go > testdata/test_line.go -// go build -o ./testcover -// ./testcover -mode=count -var=CoverTest -o ./testdata/test_cover.go testdata/test_line.go -// go run ./testdata/main.go ./testdata/test.go -// -func TestCover(t *testing.T) { - // Read in the test file (testTest) and write it, with LINEs specified, to coverInput. - file, err := ioutil.ReadFile(testTest) - if err != nil { - t.Fatal(err) - } - lines := bytes.Split(file, []byte("\n")) - for i, line := range lines { - lines[i] = bytes.Replace(line, []byte("LINE"), []byte(fmt.Sprint(i+1)), -1) - } - err = ioutil.WriteFile(coverInput, bytes.Join(lines, []byte("\n")), 0666) - if err != nil { - t.Fatal(err) - } - - // defer removal of test_line.go - if !debug { - defer os.Remove(coverInput) - } - - // go build -o testcover - cmd := exec.Command("go", "build", "-o", testcover) - run(cmd, t) - - // defer removal of testcover - defer os.Remove(testcover) - - // ./testcover -mode=count -var=coverTest -o ./testdata/test_cover.go testdata/test_line.go - cmd = exec.Command(testcover, "-mode=count", "-var=coverTest", "-o", coverOutput, coverInput) - run(cmd, t) - - // defer removal of ./testdata/test_cover.go - if !debug { - defer os.Remove(coverOutput) - } - - // go run ./testdata/main.go ./testdata/test.go - cmd = exec.Command("go", "run", testMain, coverOutput) - run(cmd, t) -} - -func run(c *exec.Cmd, t *testing.T) { - c.Stdout = os.Stdout - c.Stderr = os.Stderr - err := c.Run() - if err != nil { - t.Fatal(err) - } -} diff --git a/vendor/golang.org/x/tools/cmd/cover/doc.go b/vendor/golang.org/x/tools/cmd/cover/doc.go deleted file mode 100644 index b74d5b3..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/doc.go +++ /dev/null @@ -1,27 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -/* -Cover is a program for analyzing the coverage profiles generated by -'go test -coverprofile=cover.out'. - -Cover is also used by 'go test -cover' to rewrite the source code with -annotations to track which parts of each function are executed. -It operates on one Go source file at a time, computing approximate -basic block information by studying the source. It is thus more portable -than binary-rewriting coverage tools, but also a little less capable. -For instance, it does not probe inside && and || expressions, and can -be mildly confused by single statements with multiple function literals. - -For usage information, please see: - go help testflag - go tool cover -help - -No longer maintained: - -For Go releases 1.5 and later, this tool lives in the -standard repository. The code here is not maintained. - -*/ -package main // import "golang.org/x/tools/cmd/cover" diff --git a/vendor/golang.org/x/tools/cmd/cover/func.go b/vendor/golang.org/x/tools/cmd/cover/func.go deleted file mode 100644 index 41d9fce..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/func.go +++ /dev/null @@ -1,166 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// This file implements the visitor that computes the (line, column)-(line-column) range for each function. - -package main - -import ( - "bufio" - "fmt" - "go/ast" - "go/build" - "go/parser" - "go/token" - "os" - "path/filepath" - "text/tabwriter" - - "golang.org/x/tools/cover" -) - -// funcOutput takes two file names as arguments, a coverage profile to read as input and an output -// file to write ("" means to write to standard output). The function reads the profile and produces -// as output the coverage data broken down by function, like this: -// -// fmt/format.go:30: init 100.0% -// fmt/format.go:57: clearflags 100.0% -// ... -// fmt/scan.go:1046: doScan 100.0% -// fmt/scan.go:1075: advance 96.2% -// fmt/scan.go:1119: doScanf 96.8% -// total: (statements) 91.9% - -func funcOutput(profile, outputFile string) error { - profiles, err := cover.ParseProfiles(profile) - if err != nil { - return err - } - - var out *bufio.Writer - if outputFile == "" { - out = bufio.NewWriter(os.Stdout) - } else { - fd, err := os.Create(outputFile) - if err != nil { - return err - } - defer fd.Close() - out = bufio.NewWriter(fd) - } - defer out.Flush() - - tabber := tabwriter.NewWriter(out, 1, 8, 1, '\t', 0) - defer tabber.Flush() - - var total, covered int64 - for _, profile := range profiles { - fn := profile.FileName - file, err := findFile(fn) - if err != nil { - return err - } - funcs, err := findFuncs(file) - if err != nil { - return err - } - // Now match up functions and profile blocks. - for _, f := range funcs { - c, t := f.coverage(profile) - fmt.Fprintf(tabber, "%s:%d:\t%s\t%.1f%%\n", fn, f.startLine, f.name, 100.0*float64(c)/float64(t)) - total += t - covered += c - } - } - fmt.Fprintf(tabber, "total:\t(statements)\t%.1f%%\n", 100.0*float64(covered)/float64(total)) - - return nil -} - -// findFuncs parses the file and returns a slice of FuncExtent descriptors. -func findFuncs(name string) ([]*FuncExtent, error) { - fset := token.NewFileSet() - parsedFile, err := parser.ParseFile(fset, name, nil, 0) - if err != nil { - return nil, err - } - visitor := &FuncVisitor{ - fset: fset, - name: name, - astFile: parsedFile, - } - ast.Walk(visitor, visitor.astFile) - return visitor.funcs, nil -} - -// FuncExtent describes a function's extent in the source by file and position. -type FuncExtent struct { - name string - startLine int - startCol int - endLine int - endCol int -} - -// FuncVisitor implements the visitor that builds the function position list for a file. -type FuncVisitor struct { - fset *token.FileSet - name string // Name of file. - astFile *ast.File - funcs []*FuncExtent -} - -// Visit implements the ast.Visitor interface. -func (v *FuncVisitor) Visit(node ast.Node) ast.Visitor { - switch n := node.(type) { - case *ast.FuncDecl: - start := v.fset.Position(n.Pos()) - end := v.fset.Position(n.End()) - fe := &FuncExtent{ - name: n.Name.Name, - startLine: start.Line, - startCol: start.Column, - endLine: end.Line, - endCol: end.Column, - } - v.funcs = append(v.funcs, fe) - } - return v -} - -// coverage returns the fraction of the statements in the function that were covered, as a numerator and denominator. -func (f *FuncExtent) coverage(profile *cover.Profile) (num, den int64) { - // We could avoid making this n^2 overall by doing a single scan and annotating the functions, - // but the sizes of the data structures is never very large and the scan is almost instantaneous. - var covered, total int64 - // The blocks are sorted, so we can stop counting as soon as we reach the end of the relevant block. - for _, b := range profile.Blocks { - if b.StartLine > f.endLine || (b.StartLine == f.endLine && b.StartCol >= f.endCol) { - // Past the end of the function. - break - } - if b.EndLine < f.startLine || (b.EndLine == f.startLine && b.EndCol <= f.startCol) { - // Before the beginning of the function - continue - } - total += int64(b.NumStmt) - if b.Count > 0 { - covered += int64(b.NumStmt) - } - } - if total == 0 { - total = 1 // Avoid zero denominator. - } - return covered, total -} - -// findFile finds the location of the named file in GOROOT, GOPATH etc. -func findFile(file string) (string, error) { - dir, file := filepath.Split(file) - pkg, err := build.Import(dir, ".", build.FindOnly) - if err != nil { - return "", fmt.Errorf("can't find %q: %v", file, err) - } - return filepath.Join(pkg.Dir, file), nil -} diff --git a/vendor/golang.org/x/tools/cmd/cover/html.go b/vendor/golang.org/x/tools/cmd/cover/html.go deleted file mode 100644 index ef50e2b..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/html.go +++ /dev/null @@ -1,284 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package main - -import ( - "bufio" - "bytes" - "fmt" - "html/template" - "io" - "io/ioutil" - "math" - "os" - "os/exec" - "path/filepath" - "runtime" - - "golang.org/x/tools/cover" -) - -// htmlOutput reads the profile data from profile and generates an HTML -// coverage report, writing it to outfile. If outfile is empty, -// it writes the report to a temporary file and opens it in a web browser. -func htmlOutput(profile, outfile string) error { - profiles, err := cover.ParseProfiles(profile) - if err != nil { - return err - } - - var d templateData - - for _, profile := range profiles { - fn := profile.FileName - if profile.Mode == "set" { - d.Set = true - } - file, err := findFile(fn) - if err != nil { - return err - } - src, err := ioutil.ReadFile(file) - if err != nil { - return fmt.Errorf("can't read %q: %v", fn, err) - } - var buf bytes.Buffer - err = htmlGen(&buf, src, profile.Boundaries(src)) - if err != nil { - return err - } - d.Files = append(d.Files, &templateFile{ - Name: fn, - Body: template.HTML(buf.String()), - Coverage: percentCovered(profile), - }) - } - - var out *os.File - if outfile == "" { - var dir string - dir, err = ioutil.TempDir("", "cover") - if err != nil { - return err - } - out, err = os.Create(filepath.Join(dir, "coverage.html")) - } else { - out, err = os.Create(outfile) - } - if err != nil { - return err - } - err = htmlTemplate.Execute(out, d) - if err == nil { - err = out.Close() - } - if err != nil { - return err - } - - if outfile == "" { - if !startBrowser("file://" + out.Name()) { - fmt.Fprintf(os.Stderr, "HTML output written to %s\n", out.Name()) - } - } - - return nil -} - -// percentCovered returns, as a percentage, the fraction of the statements in -// the profile covered by the test run. -// In effect, it reports the coverage of a given source file. -func percentCovered(p *cover.Profile) float64 { - var total, covered int64 - for _, b := range p.Blocks { - total += int64(b.NumStmt) - if b.Count > 0 { - covered += int64(b.NumStmt) - } - } - if total == 0 { - return 0 - } - return float64(covered) / float64(total) * 100 -} - -// htmlGen generates an HTML coverage report with the provided filename, -// source code, and tokens, and writes it to the given Writer. -func htmlGen(w io.Writer, src []byte, boundaries []cover.Boundary) error { - dst := bufio.NewWriter(w) - for i := range src { - for len(boundaries) > 0 && boundaries[0].Offset == i { - b := boundaries[0] - if b.Start { - n := 0 - if b.Count > 0 { - n = int(math.Floor(b.Norm*9)) + 1 - } - fmt.Fprintf(dst, ``, n, b.Count) - } else { - dst.WriteString("") - } - boundaries = boundaries[1:] - } - switch b := src[i]; b { - case '>': - dst.WriteString(">") - case '<': - dst.WriteString("<") - case '&': - dst.WriteString("&") - case '\t': - dst.WriteString(" ") - default: - dst.WriteByte(b) - } - } - return dst.Flush() -} - -// startBrowser tries to open the URL in a browser -// and reports whether it succeeds. -func startBrowser(url string) bool { - // try to start the browser - var args []string - switch runtime.GOOS { - case "darwin": - args = []string{"open"} - case "windows": - args = []string{"cmd", "/c", "start"} - default: - args = []string{"xdg-open"} - } - cmd := exec.Command(args[0], append(args[1:], url)...) - return cmd.Start() == nil -} - -// rgb returns an rgb value for the specified coverage value -// between 0 (no coverage) and 10 (max coverage). -func rgb(n int) string { - if n == 0 { - return "rgb(192, 0, 0)" // Red - } - // Gradient from gray to green. - r := 128 - 12*(n-1) - g := 128 + 12*(n-1) - b := 128 + 3*(n-1) - return fmt.Sprintf("rgb(%v, %v, %v)", r, g, b) -} - -// colors generates the CSS rules for coverage colors. -func colors() template.CSS { - var buf bytes.Buffer - for i := 0; i < 11; i++ { - fmt.Fprintf(&buf, ".cov%v { color: %v }\n", i, rgb(i)) - } - return template.CSS(buf.String()) -} - -var htmlTemplate = template.Must(template.New("html").Funcs(template.FuncMap{ - "colors": colors, -}).Parse(tmplHTML)) - -type templateData struct { - Files []*templateFile - Set bool -} - -type templateFile struct { - Name string - Body template.HTML - Coverage float64 -} - -const tmplHTML = ` - - - - - - - -
- -
- not tracked - {{if .Set}} - not covered - covered - {{else}} - no coverage - low coverage - * - * - * - * - * - * - * - * - high coverage - {{end}} -
-
-
- {{range $i, $f := .Files}} -
{{$f.Body}}
- {{end}} -
- - - -` diff --git a/vendor/golang.org/x/tools/cmd/cover/testdata/main.go b/vendor/golang.org/x/tools/cmd/cover/testdata/main.go deleted file mode 100644 index 6ed39c4..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/testdata/main.go +++ /dev/null @@ -1,112 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Test runner for coverage test. This file is not coverage-annotated; test.go is. -// It knows the coverage counter is called "coverTest". - -package main - -import ( - "fmt" - "os" -) - -func main() { - testAll() - verify() -} - -type block struct { - count uint32 - line uint32 -} - -var counters = make(map[block]bool) - -// check records the location and expected value for a counter. -func check(line, count uint32) { - b := block{ - count, - line, - } - counters[b] = true -} - -// checkVal is a version of check that returns its extra argument, -// so it can be used in conditionals. -func checkVal(line, count uint32, val int) int { - b := block{ - count, - line, - } - counters[b] = true - return val -} - -var PASS = true - -// verify checks the expected counts against the actual. It runs after the test has completed. -func verify() { - for b := range counters { - got, index := count(b.line) - if b.count == anything && got != 0 { - got = anything - } - if got != b.count { - fmt.Fprintf(os.Stderr, "test_go:%d expected count %d got %d [counter %d]\n", b.line, b.count, got, index) - PASS = false - } - } - verifyPanic() - if !PASS { - fmt.Fprintf(os.Stderr, "FAIL\n") - os.Exit(2) - } -} - -// verifyPanic is a special check for the known counter that should be -// after the panic call in testPanic. -func verifyPanic() { - if coverTest.Count[panicIndex-1] != 1 { - // Sanity check for test before panic. - fmt.Fprintf(os.Stderr, "bad before panic") - PASS = false - } - if coverTest.Count[panicIndex] != 0 { - fmt.Fprintf(os.Stderr, "bad at panic: %d should be 0\n", coverTest.Count[panicIndex]) - PASS = false - } - if coverTest.Count[panicIndex+1] != 1 { - fmt.Fprintf(os.Stderr, "bad after panic") - PASS = false - } -} - -// count returns the count and index for the counter at the specified line. -func count(line uint32) (uint32, int) { - // Linear search is fine. Choose perfect fit over approximate. - // We can have a closing brace for a range on the same line as a condition for an "else if" - // and we don't want that brace to steal the count for the condition on the "if". - // Therefore we test for a perfect (lo==line && hi==line) match, but if we can't - // find that we take the first imperfect match. - index := -1 - indexLo := uint32(1e9) - for i := range coverTest.Count { - lo, hi := coverTest.Pos[3*i], coverTest.Pos[3*i+1] - if lo == line && line == hi { - return coverTest.Count[i], i - } - // Choose the earliest match (the counters are in unpredictable order). - if lo <= line && line <= hi && indexLo > lo { - index = i - indexLo = lo - } - } - if index == -1 { - fmt.Fprintln(os.Stderr, "cover_test: no counter for line", line) - PASS = false - return 0, 0 - } - return coverTest.Count[index], index -} diff --git a/vendor/golang.org/x/tools/cmd/cover/testdata/test.go b/vendor/golang.org/x/tools/cmd/cover/testdata/test.go deleted file mode 100644 index 9013950..0000000 --- a/vendor/golang.org/x/tools/cmd/cover/testdata/test.go +++ /dev/null @@ -1,218 +0,0 @@ -// Copyright 2013 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// This program is processed by the cover command, and then testAll is called. -// The test driver in main.go can then compare the coverage statistics with expectation. - -// The word LINE is replaced by the line number in this file. When the file is executed, -// the coverage processing has changed the line numbers, so we can't use runtime.Caller. - -package main - -const anything = 1e9 // Just some unlikely value that means "we got here, don't care how often" - -func testAll() { - testSimple() - testBlockRun() - testIf() - testFor() - testRange() - testSwitch() - testTypeSwitch() - testSelect1() - testSelect2() - testPanic() - testEmptySwitches() -} - -// The indexes of the counters in testPanic are known to main.go -const panicIndex = 3 - -// This test appears first because the index of its counters is known to main.go -func testPanic() { - defer func() { - recover() - }() - check(LINE, 1) - panic("should not get next line") - check(LINE, 0) // this is GoCover.Count[panicIndex] - // The next counter is in testSimple and it will be non-zero. - // If the panic above does not trigger a counter, the test will fail - // because GoCover.Count[panicIndex] will be the one in testSimple. -} - -func testSimple() { - check(LINE, 1) -} - -func testIf() { - if true { - check(LINE, 1) - } else { - check(LINE, 0) - } - if false { - check(LINE, 0) - } else { - check(LINE, 1) - } - for i := 0; i < 3; i++ { - if checkVal(LINE, 3, i) <= 2 { - check(LINE, 3) - } - if checkVal(LINE, 3, i) <= 1 { - check(LINE, 2) - } - if checkVal(LINE, 3, i) <= 0 { - check(LINE, 1) - } - } - for i := 0; i < 3; i++ { - if checkVal(LINE, 3, i) <= 1 { - check(LINE, 2) - } else { - check(LINE, 1) - } - } - for i := 0; i < 3; i++ { - if checkVal(LINE, 3, i) <= 0 { - check(LINE, 1) - } else if checkVal(LINE, 2, i) <= 1 { - check(LINE, 1) - } else if checkVal(LINE, 1, i) <= 2 { - check(LINE, 1) - } else if checkVal(LINE, 0, i) <= 3 { - check(LINE, 0) - } - } - if func(a, b int) bool { return a < b }(3, 4) { - check(LINE, 1) - } -} - -func testFor() { - for i := 0; i < 10; func() { i++; check(LINE, 10) }() { - check(LINE, 10) - } -} - -func testRange() { - for _, f := range []func(){ - func() { check(LINE, 1) }, - } { - f() - check(LINE, 1) - } -} - -func testBlockRun() { - check(LINE, 1) - { - check(LINE, 1) - } - { - check(LINE, 1) - } - check(LINE, 1) - { - check(LINE, 1) - } - { - check(LINE, 1) - } - check(LINE, 1) -} - -func testSwitch() { - for i := 0; i < 5; func() { i++; check(LINE, 5) }() { - switch i { - case 0: - check(LINE, 1) - case 1: - check(LINE, 1) - case 2: - check(LINE, 1) - default: - check(LINE, 2) - } - } -} - -func testTypeSwitch() { - var x = []interface{}{1, 2.0, "hi"} - for _, v := range x { - switch func() { check(LINE, 3) }(); v.(type) { - case int: - check(LINE, 1) - case float64: - check(LINE, 1) - case string: - check(LINE, 1) - case complex128: - check(LINE, 0) - default: - check(LINE, 0) - } - } -} - -func testSelect1() { - c := make(chan int) - go func() { - for i := 0; i < 1000; i++ { - c <- i - } - }() - for { - select { - case <-c: - check(LINE, anything) - case <-c: - check(LINE, anything) - default: - check(LINE, 1) - return - } - } -} - -func testSelect2() { - c1 := make(chan int, 1000) - c2 := make(chan int, 1000) - for i := 0; i < 1000; i++ { - c1 <- i - c2 <- i - } - for { - select { - case <-c1: - check(LINE, 1000) - case <-c2: - check(LINE, 1000) - default: - check(LINE, 1) - return - } - } -} - -// Empty control statements created syntax errors. This function -// is here just to be sure that those are handled correctly now. -func testEmptySwitches() { - check(LINE, 1) - switch 3 { - } - check(LINE, 1) - switch i := (interface{})(3).(int); i { - } - check(LINE, 1) - c := make(chan int) - go func() { - check(LINE, 1) - c <- 1 - select {} - }() - <-c - check(LINE, 1) -} diff --git a/vendor/golang.org/x/tools/cmd/digraph/digraph.go b/vendor/golang.org/x/tools/cmd/digraph/digraph.go deleted file mode 100644 index 3ad2950..0000000 --- a/vendor/golang.org/x/tools/cmd/digraph/digraph.go +++ /dev/null @@ -1,540 +0,0 @@ -// The digraph command performs queries over unlabelled directed graphs -// represented in text form. It is intended to integrate nicely with -// typical UNIX command pipelines. -// -// Since directed graphs (import graphs, reference graphs, call graphs, -// etc) often arise during software tool development and debugging, this -// command is included in the go.tools repository. -// -// TODO(adonovan): -// - support input files other than stdin -// - suport alternative formats (AT&T GraphViz, CSV, etc), -// a comment syntax, etc. -// - allow queries to nest, like Blaze query language. -// -package main // import "golang.org/x/tools/cmd/digraph" - -import ( - "bufio" - "bytes" - "errors" - "flag" - "fmt" - "io" - "os" - "sort" - "strconv" - "unicode" - "unicode/utf8" -) - -const Usage = `digraph: queries over directed graphs in text form. - -Graph format: - - Each line contains zero or more words. Words are separated by - unquoted whitespace; words may contain Go-style double-quoted portions, - allowing spaces and other characters to be expressed. - - Each field declares a node, and if there are more than one, - an edge from the first to each subsequent one. - The graph is provided on the standard input. - - For instance, the following (acyclic) graph specifies a partial order - among the subtasks of getting dressed: - - % cat clothes.txt - socks shoes - "boxer shorts" pants - pants belt shoes - shirt tie sweater - sweater jacket - hat - - The line "shirt tie sweater" indicates the two edges shirt -> tie and - shirt -> sweater, not shirt -> tie -> sweater. - -Supported queries: - - nodes - the set of all nodes - degree - the in-degree and out-degree of each node. - preds