MCPcopy Create free account

hub / github.com/chain/txvm / functions

Functions1,025 in github.com/chain/txvm

↓ 8 callersFunctionNewTx
NewTx runs the given txvm program through an instance of the txvm virtual machine, populating a new Tx object with its side effects.
protocol/bc/tx.go:124
↓ 8 callersMethodPushdataByte
PushdataByte writes instructions to b, pushing byt onto the stack.
protocol/txvm/txvmutil/builder.go:38
↓ 8 callersMethodSign
Sign produces a chainkd signature of msg using xprv.
crypto/ed25519/chainkd/chainkd.go:145
↓ 8 callersMethodSign
Sign invokes a callback function to add signatures to Inputs and Issuances in the template. The callback adds as many as it can, up to the number need
protocol/txbuilder/template.go:306
↓ 8 callersMethodStackLen
StackLen returns the length of the stack of the VM's current contract.
protocol/txvm/introspection.go:21
↓ 8 callersMethodTx
Tx produces a bc.Tx from the transaction currently described by the template. This involves rendering the transaction as txvm code, running it, and ex
protocol/txbuilder/template.go:611
↓ 8 callersMethodUnmarshalJSON
UnmarshalJSON satisfies the json.Unmarshaler interface.
encoding/json/json.go:42
↓ 8 callersFunctioncheckLogTypes
(t *testing.T, log []txvm.Tuple, inputCount, outputCount, retireCount, issueCount, finalizeCount int)
protocol/txbuilder/txbuilder_test.go:460
↓ 8 callersFunctionfname
(f interface{})
math/checked/checked_test.go:229
↓ 8 callersFunctionhashPtr
(hash Hash)
protocol/bc/blockheader_test.go:81
↓ 8 callersMethodlog
charges the creation cost of a tuple containing the given data and logs it
protocol/txvm/log.go:24
↓ 8 callersFunctionmustDecodeHexProg
(s string)
protocol/txbuilder/standard/standard_test.go:144
↓ 7 callersMethodBytes
()
protocol/state/serialize.go:36
↓ 7 callersMethodCommitAppliedBlock
CommitAppliedBlock takes a block, commits it to persistent storage and sets c's state. Unlike CommitBlock, it accepts an already applied snapshot. Com
protocol/block.go:56
↓ 7 callersFunctionContractSeed
ContractSeed computes the seed of a contract whose initial program is prog.
protocol/txvm/contract.go:169
↓ 7 callersMethodDelete
Delete removes item from t, if present.
protocol/patricia/patricia.go:167
↓ 7 callersFunctionFeOne
(fe *FieldElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:23
↓ 7 callersMethodFromBytes
FromBytes parses a Block from a byte slice, by unmarshaling and converting a RawBlock protobuf.
protocol/bc/block.go:125
↓ 7 callersMethodIsZero
IsZero tells whether a Hash pointer is nil or points to an all-zero hash.
protocol/bc/hash.go:129
↓ 7 callersMethodState
State returns the most recent state available. It will not be current unless the current process is the leader. Callers should examine the returned st
protocol/protocol.go:189
↓ 7 callersMethodWriteItem
WriteItem writes length-prefixed item to the hash state.
crypto/sha3/tuple_hash.go:14
↓ 7 callersFunctiondoverify
(t *testing.T, xpub XPub, msg, sig []byte, xpubdesc, xprvdesc string)
crypto/ed25519/chainkd/chainkd_test.go:82
↓ 7 callersMethoderror
(offs int, msg string)
protocol/txvm/asm/scanner.go:260
↓ 7 callersFunctionmust
(err error)
cmd/ed25519/ed25519.go:76
↓ 7 callersMethodpopBool
()
protocol/txvm/vm.go:219
↓ 7 callersFunctionprefix
(ctx context.Context)
log/log.go:95
↓ 7 callersMethodpushBool
(b bool)
protocol/txvm/vm.go:195
↓ 7 callersFunctionrightEncode
rightEncode encodes integer in a variable-length encoding unambiguously parseable from the end of a string. Used by TupleHash and KMAC.
crypto/sha3/cshake.go:86
↓ 6 callersFunctionAddPrefixkv
AddPrefixkv appends keyval to any prefix stored in ctx, and returns a new context with the longer prefix.
log/log.go:87
↓ 6 callersFunctionAssetID
AssetID computes the ID of an asset using the standard asset-issuance contract with the given parameters.
protocol/txbuilder/standard/issue.go:163
↓ 6 callersMethodDouble
(r *CompletedGroupElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:657
↓ 6 callersFunctionFeCopy
(dst, src *FieldElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:54
↓ 6 callersFunctionScReduce
Input: s[0]+256*s[1]+...+256^63*s[63] = s Output: s[0]+256*s[1]+...+256^31*s[31] = s mod l where l = 2^252 + 27742317777372353535851937790883648493.
crypto/ed25519/internal/edwards25519/edwards25519.go:1456
↓ 6 callersFunctionSignBlock
SignBlock produces a SignedBlock from a Block. It invokes its callback once for each position in [0..N) where N is the number of pubkeys in the previo
protocol/bc/block.go:39
↓ 6 callersFunctionSum256
Sum256 returns the SHA3-256 digest of the data.
crypto/sha3/hashes.go:44
↓ 6 callersMethodToProjective
(r *ProjectiveGroupElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:763
↓ 6 callersFunctionTxMerkleRoot
TxMerkleRoot creates a merkle tree from a slice of Transactions and returns the root hash of the tree.
protocol/bc/merkle.go:11
↓ 6 callersFunctionencodeString
(d *state, s []byte)
crypto/sha3/cshake.go:77
↓ 6 callersFunctionlogTuple
(t txvm.Tuple, seed *[32]byte)
protocol/txbuilder/txresult/result.go:336
↓ 6 callersFunctionmust
(err error)
cmd/bcstate/bcstate.go:78
↓ 6 callersFunctionmustDecodeHex
(s string)
protocol/txbuilder/standard/standard_test.go:135
↓ 6 callersMethodrotate
()
log/rotation/file.go:100
↓ 6 callersMethodrunHooks
TODO(bobg): Update the hook mechanism.
protocol/txvm/hook.go:5
↓ 5 callersMethodBytes
Bytes produces xprv as a byte slice.
crypto/ed25519/chainkd/serialize.go:37
↓ 5 callersFunctionCopy
Copy makes a copy of provided snapshot. Copying a snapshot is an O(n) operation where n is the number of nonces in the snapshot's nonce set.
protocol/state/snapshot.go:52
↓ 5 callersFunctionCreate
Create creates a log writing to the named file with mode 0644 (before umask), appending to it if it already exists. It will rotate to files name.1, na
log/rotation/file.go:37
↓ 5 callersFunctionFeToBytes
FeToBytes marshals h to s. Preconditions: |h| bounded by 1.1*2^25,1.1*2^24,1.1*2^25,1.1*2^24,etc. Write p=2^255-19; q=floor(h/p). Basic claim: q = fl
crypto/ed25519/internal/edwards25519/edwards25519.go:131
↓ 5 callersFunctionFeZero
(fe *FieldElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:19
↓ 5 callersFunctionGet256
Get256 returns an initialized SHA3-256 hash ready to use. It is like sha3.New256 except it uses the freelist. The caller should call Put256 when finis
crypto/sha3pool/pool.go:15
↓ 5 callersFunctionGetRunlimit
GetRunlimit causes the vm to write its ending runlimit to the given pointer on exit.
protocol/txvm/option.go:69
↓ 5 callersFunctionHelper
Helper marks the calling function as a log helper function. When logging file and line information, that function will be skipped. Helper may be calle
log/stack.go:18
↓ 5 callersFunctionName
Name returns the name of opcode.
protocol/txvm/op/op.go:115
↓ 5 callersFunctionNewInitialBlock
NewInitialBlock produces the first block for a new blockchain, using the given pubkeys and quorum for its NextPredicate.
protocol/block.go:139
↓ 5 callersFunctionNewShake256
NewShake256 creates a new SHAKE128 variable-output-length ShakeHash. Its generic security strength is 256 bits against all attacks if at least 64 byte
crypto/sha3/shake.go:46
↓ 5 callersFunctionPut256
Put256 resets h and puts it in the freelist.
crypto/sha3pool/pool.go:20
↓ 5 callersMethodScan
Scan satisfies the driver.Scanner interface
protocol/bc/hash.go:96
↓ 5 callersMethodToCached
(r *CachedGroupElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:694
↓ 5 callersMethodVerify
Verify verifies that sig is a proper signature of msg using xpub's corresponding XPrv.
crypto/ed25519/chainkd/chainkd.go:192
↓ 5 callersFunctionWalk
Walk walks t calling walkFn for each item. If an error is returned by walkFn at any point, processing is stopped and the error is returned.
protocol/patricia/patricia.go:47
↓ 5 callersFunctionWithDetail
WithDetail returns a new error that wraps err as a chain error messsage containing text as its additional context. Function Detail will return the giv
errors/errors.go:86
↓ 5 callersMethodXPub
XPub produces the XPub corresponding to xprv.
crypto/ed25519/chainkd/chainkd.go:45
↓ 5 callersFunctionaddPayToSig
(src string, priv []byte)
protocol/txvm/txvmtest/txvmtest.go:268
↓ 5 callersFunctionbenchmarkHash
benchmarkHash tests the speed to hash num buffers of buflen each.
crypto/sha3/sha3_test.go:237
↓ 5 callersFunctioncheckTypeOk
(t *testing.T, ok bool, i int, a, b Item)
protocol/txvm/simple_ops_test.go:1307
↓ 5 callersMethodcreateValue
(amount int64, assetID, anchor []byte)
protocol/txvm/entries.go:80
↓ 5 callersMethodexec
(prog []byte)
protocol/txvm/vm.go:137
↓ 5 callersFunctiongetWitness
()
cmd/tx/main.go:402
↓ 5 callersFunctionhasPrefix
(s, prefix []byte, bit byte)
protocol/patricia/patricia.go:239
↓ 5 callersMethodinspect
()
protocol/txvm/item.go:15
↓ 5 callersFunctionleftEncode
leftEncode encodes integer in a variable-length encoding unambiguously parseable from the beginning of a string. Used to encode strings for all cSHAKE
crypto/sha3/cshake.go:109
↓ 5 callersFunctionlookup
(n *node, key []byte)
protocol/patricia/patricia.go:79
↓ 5 callersFunctionnewBuilder
()
protocol/txvm/txvmutil/builder_test.go:11
↓ 5 callersFunctionnewCShake
(securitybits int, n []byte, s []byte)
crypto/sha3/cshake.go:47
↓ 5 callersMethodnext
()
protocol/txvm/asm/asm.go:111
↓ 5 callersMethodpopValue
()
protocol/txvm/values.go:116
↓ 5 callersFunctiontestUnalignedAndGeneric
(t *testing.T, testf func(impl string))
crypto/sha3/sha3_test.go:75
↓ 5 callersFunctiontouch
(name string)
log/rotation/file_test.go:239
↓ 5 callersFunctionusage
()
cmd/ed25519/ed25519.go:82
↓ 5 callersFunctionwrap
wrap adds a context message and stack trace to err and returns a new error containing the new context. This function is meant to be composed within ot
errors/errors.go:43
↓ 4 callersMethodBytes
Bytes returns binary representation of a EC point (32-byte slice)
crypto/ed25519/ecmath/point_serialization.go:12
↓ 4 callersMethodDouble
(r *CompletedGroupElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:688
↓ 4 callersFunctionFeCombine
(h *FieldElement, h0, h1, h2, h3, h4, h5, h6, h7, h8, h9 int64)
crypto/ed25519/internal/edwards25519/edwards25519.go:259
↓ 4 callersFunctionFeNeg
FeNeg sets h = -f Preconditions: |f| bounded by 1.1*2^25,1.1*2^24,1.1*2^25,1.1*2^24,etc. Postconditions: |h| bounded by 1.1*2^25,1.1*2^24,1.1*2^25,1
crypto/ed25519/internal/edwards25519/edwards25519.go:246
↓ 4 callersMethodGetBlock
(context.Context, uint64)
protocol/protocol.go:101
↓ 4 callersFunctionIsPushdataOp
IsPushdataOp tells whether the given opcode is a pushdata instruction.
protocol/txvm/op/op.go:141
↓ 4 callersFunctionIsSmallInt
IsSmallInt tells whether the given integer can be encoded with a small-integer-encoding instruction.
protocol/txvm/op/op.go:135
↓ 4 callersMethodLatestSnapshot
(context.Context)
protocol/protocol.go:102
↓ 4 callersMethodMulAdd
MulAdd computes ab+c (mod L) and places the result in z, returning that. Any or all of the pointers may be the same.
crypto/ed25519/ecmath/scalar.go:83
↓ 4 callersFunctionNew
New produces a Result from a bc.Tx by parsing the Tx object's Log.
protocol/txbuilder/txresult/result.go:85
↓ 4 callersFunctionNew224
New224 creates a new SHA3-224 hash. Its generic security strength is 224 bits against preimage attacks, and 112 bits against collision attacks.
crypto/sha3/hashes.go:18
↓ 4 callersFunctionNewXPrv
NewXPrv takes a source of random bytes and produces a new XPrv. If r is nil, crypto/rand.Reader is used.
crypto/ed25519/chainkd/chainkd.go:27
↓ 4 callersMethodPushdataUint64
PushdataInt64 writes instructions to b pushing v onto the stack. It panics if v does not fit in a int64.
protocol/txvm/txvmutil/builder.go:55
↓ 4 callersMethodSaveBlock
(context.Context, *bc.Block)
protocol/protocol.go:104
↓ 4 callersFunctionScMulAdd
The scalars are GF(2^252 + 27742317777372353535851937790883648493). Input: a[0]+256*a[1]+...+256^31*a[31] = a b[0]+256*b[1]+...+256^31*b[31] = b c[0]+
crypto/ed25519/internal/edwards25519/edwards25519.go:1025
↓ 4 callersMethodSeed
Seed returns the contract seed of the VM's current contract.
protocol/txvm/introspection.go:33
↓ 4 callersMethodValue
Value satisfies the driver.Valuer interface
protocol/bc/hash.go:91
↓ 4 callersFunctionWithCommitments
WithCommitments takes in a slice of *bc.Tx and wraps each of them with their commitments, returning a slice of *bc.CommitmentsTx
protocol/bc/bctest/tx.go:46
↓ 4 callersMethodZero
()
crypto/ed25519/internal/edwards25519/edwards25519.go:681
↓ 4 callersFunctionasHexBytes
(b [][]byte)
protocol/txbuilder/template.go:207
↓ 4 callersFunctionbenchmarkShake
benchmarkShake is specialized to the Shake instances, which don't require a copy on reading output.
crypto/sha3/sha3_test.go:257
← previousnext →101–200 of 1,025, ranked by callers