MCPcopy Create free account

hub / github.com/chain/txvm / functions

Functions1,025 in github.com/chain/txvm

↓ 2 callersFunctionDurationMillis
DurationMillis converts a time.Duration to a number of milliseconds.
protocol/bc/time.go:16
↓ 2 callersMethodErr
Err returns the first error encountered by Write, if any.
errors/writer.go:38
↓ 2 callersFunctionFeInvert
(out, z *FieldElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:506
↓ 2 callersFunctionFeIsNonZero
(f *FieldElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:226
↓ 2 callersFunctionGeDoubleScalarMultVartime
GeDoubleScalarMultVartime sets r = a*A + b*B where a = a[0]+256*a[1]+...+256^31 a[31]. and b = b[0]+256*b[1]+...+256^31 b[31]. B is the Ed25519 base p
crypto/ed25519/internal/edwards25519/edwards25519.go:878
↓ 2 callersMethodMarshalText
MarshalText satisfies the TextMarshaler interface. It returns the bytes of h encoded in hex, for formats that can't hold arbitrary binary data. It nev
protocol/bc/hash.go:49
↓ 2 callersFunctionNegateInt64
NegateInt64 returns -a with an integer overflow check.
math/checked/checked.go:67
↓ 2 callersFunctionNew384
New384 creates a new SHA3-384 hash. Its generic security strength is 384 bits against preimage attacks, and 192 bits against collision attacks.
crypto/sha3/hashes.go:28
↓ 2 callersFunctionNewBlockBuilder
()
protocol/builder.go:33
↓ 2 callersFunctionNewShake128
NewShake128 creates a new SHAKE128 variable-output-length ShakeHash. Its generic security strength is 128 bits against all attacks if at least 32 byte
crypto/sha3/shake.go:41
↓ 2 callersFunctionNonceCommitment
NonceCommitment returns the byte commitment for the given nonce id and expiration.
protocol/bc/hash.go:138
↓ 2 callersFunctionNonceHash
NonceHash computes the hash of a nonce tuple.
protocol/txvm/anchors.go:31
↓ 2 callersFunctionNonceTuple
NonceTuple computes a nonce tuple suitable for logging (with vm.log(nonce...)) or hashing (with NonceHash).
protocol/txvm/anchors.go:26
↓ 2 callersFunctionPreComputedGroupElementCMove
(t, u *PreComputedGroupElement, b int32)
crypto/ed25519/internal/edwards25519/edwards25519.go:942
↓ 2 callersMethodPruneNonces
PruneNonces modifies a Snapshot, removing all nonce IDs with expiration times earlier than the provided timestamp.
protocol/state/snapshot.go:34
↓ 2 callersMethodPublic
Public returns the PublicKey corresponding to priv.
crypto/ed25519/ed25519.go:44
↓ 2 callersMethodRecover
Recover performs crash recovery, restoring the blockchain to a complete state. It returns the latest confirmed block and the corresponding state snaps
protocol/recover.go:19
↓ 2 callersMethodRunlimit
Runlimit returns the current remaining runlimit in the VM.
protocol/txvm/introspection.go:9
↓ 2 callersMethodSaveSnapshot
(context.Context, *state.Snapshot)
protocol/protocol.go:106
↓ 2 callersMethodScMul
ScMul multiplies the EC point x by the scalar y, placing the result in z and returning that. X and z may be the same pointer.
crypto/ed25519/ecmath/point.go:43
↓ 2 callersMethodScMulBase
ScMulBase multiplies the ed25519 base point by x and places the result in z, returning that.
crypto/ed25519/ecmath/point.go:49
↓ 2 callersMethodSetUint64
SetUint64 sets the scalar to a given integer value. One-liner: s := (&ecmath.Scalar{}).SetUint64(n)
crypto/ed25519/ecmath/scalar.go:43
↓ 2 callersFunctionSpendMultisig
SpendMultisig writes txvm bytecode to b, spending a value previously locked with the standard pay-to-multisig-program contract.
protocol/txbuilder/standard/input.go:42
↓ 2 callersMethodStart
(snapshot *state.Snapshot, timestampMS uint64)
protocol/builder.go:42
↓ 2 callersFunctionSum256
Sum256 uses a ShakeHash from the pool to sum into hash.
crypto/sha3pool/pool.go:26
↓ 2 callersMethodToBytes
(s *[32]byte)
crypto/ed25519/internal/edwards25519/edwards25519.go:671
↓ 2 callersMethodWritten
Written returns the number of bytes written to the underlying writer.
errors/writer.go:44
↓ 2 callersFunctionaddSig
(src string, priv []byte)
protocol/txvm/txvmtest/txvmtest.go:258
↓ 2 callersFunctionappendPrefix
(b []byte, keyval ...interface{})
log/log.go:61
↓ 2 callersMethodasTxvm
()
protocol/bc/blockheader.go:78
↓ 2 callersFunctionassemble
(s *scanner, stoptok token)
protocol/txvm/asm/asm.go:80
↓ 2 callersMethodclone
()
crypto/sha3/kmac.go:90
↓ 2 callersMethodclone
()
crypto/sha3/sha3.go:69
↓ 2 callersMethodclone
()
crypto/sha3/tuple_hash.go:164
↓ 2 callersFunctioncontractSnapshot
(t Tuple)
protocol/txvm/contract.go:26
↓ 2 callersFunctionextractTypeCode
(t Tuple)
protocol/txvm/entries.go:159
↓ 2 callersFunctionfeSquare
(f *FieldElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:428
↓ 2 callersMethodfinalizeCommitState
(ctx context.Context, snapshot *state.Snapshot)
protocol/block.go:105
↓ 2 callersFunctiongeAdd
(r *CompletedGroupElement, p *ExtendedGroupElement, q *CachedGroupElement)
crypto/ed25519/internal/edwards25519/edwards25519.go:782
↓ 2 callersFunctiongetReader
(arg string)
cmd/bcstate/bcstate.go:65
↓ 2 callersFunctionhash2hex
(hash [32]byte)
protocol/merkle/merkle_test.go:243
↓ 2 callersMethodindex
()
protocol/txbuilder/template.go:131
↓ 2 callersMethodinitCShake
The initialization of cSHAKE
crypto/sha3/cshake.go:69
↓ 2 callersMethodinitString
(str string)
protocol/txvm/asm/scanner.go:23
↓ 2 callersFunctionisEmpty
(v reflect.Value)
testutil/deepequal.go:146
↓ 2 callersFunctionisLetter
(ch rune)
protocol/txvm/asm/scanner.go:80
↓ 2 callersFunctionisStackVal
(v interface{})
log/log.go:176
↓ 2 callersMethodisZero
()
protocol/txvm/entries.go:38
↓ 2 callersFunctionissue
(withAnchor bool, version, quorum int, pubkeys []ed25519.PublicKey, tag []byte, amount int64, refdata []byte,
protocol/txbuilder/standard/issue.go:129
↓ 2 callersFunctionkeyHash
duplicated from core/key/store.go.
protocol/txbuilder/txbuilder_test.go:21
↓ 2 callersMethodlogTimeRange
(mintime, maxtime Int)
protocol/txvm/log.go:39
↓ 2 callersMethodmaterializeTx
materializeTx materializes the template into txvm bytecode. The resulting program is complete up until op.Finalize. It does not include the transacti
protocol/txbuilder/template.go:437
↓ 2 callersFunctionmeasureProgram
(prog []byte, measuremem bool)
protocol/txvm/asm/runlimit_test.go:1121
↓ 2 callersFunctionmodifyScalar
s must be >= 32 bytes long and gets rewritten in place
crypto/ed25519/chainkd/chainkd.go:226
↓ 2 callersFunctionmust
(err error)
protocol/bc/merkle_test.go:53
↓ 2 callersFunctionmustDecodeHash
(s string)
protocol/block_test.go:307
↓ 2 callersFunctionmustDecodeHash
(str string)
protocol/patricia/patricia_test.go:705
↓ 2 callersMethodpopZeroValue
()
protocol/txvm/values.go:125
↓ 2 callersFunctionprevPowerOfTwo
prevPowerOfTwo returns the largest power of two that is smaller than a given number. In other words, for some input n, the prevPowerOfTwo k is a power
protocol/merkle/merkle.go:91
↓ 2 callersMethodpush
(v Item)
protocol/txvm/stack.go:29
↓ 2 callersMethodrecoverExec
(prog []byte)
protocol/txvm/complex_ops_test.go:1100
↓ 2 callersFunctionselectPoint
(t *PreComputedGroupElement, pos int32, b int32)
crypto/ed25519/internal/edwards25519/edwards25519.go:948
↓ 2 callersMethodsetState
(s *state.Snapshot)
protocol/protocol.go:195
↓ 2 callersFunctionshowSigs
(sigs []interface{})
protocol/bc/block_test.go:272
↓ 2 callersFunctionsign
()
errors/example_test.go:21
↓ 2 callersFunctionslide
(r *[256]int8, a *[32]byte)
crypto/ed25519/internal/edwards25519/edwards25519.go:844
↓ 2 callersFunctionstackPortable
(stack stack)
protocol/txvm/contract.go:158
↓ 2 callersFunctiontreeFromBytes
(keys [][]byte)
protocol/state/serialize.go:60
↓ 2 callersFunctiontreeToBytes
(tree *patricia.Tree)
protocol/state/serialize.go:51
↓ 2 callersFunctionuninspect
(t Tuple)
protocol/txvm/item.go:119
↓ 2 callersMethoduninspect
(t Tuple)
protocol/txvm/entries.go:111
↓ 2 callersFunctionusage
()
cmd/tx/main.go:429
↓ 2 callersFunctionusage
(exitval int)
cmd/assetid/assetid.go:40
↓ 2 callersFunctionvalueToTop
(b *txvmutil.Builder, stack []stackItem, amount int64, assetID bc.Hash)
protocol/txbuilder/template.go:741
↓ 2 callersFunctionwritePushdata
(buf *bytes.Buffer, data []byte)
protocol/txvm/item.go:111
↓ 2 callersFunctionwritePushdata
(buf *bytes.Buffer, data []byte)
protocol/txvm/txvmutil/builder.go:140
↓ 2 callersFunctionwritePushint64
(buf *bytes.Buffer, num int64)
protocol/txvm/asm/asm.go:223
↓ 2 callersFunctionwriteRawStack
(w io.Writer, v interface{})
log/log.go:159
↓ 2 callersFunctionwriteVarint
(buf *bytes.Buffer, v uint64)
protocol/txvm/asm/asm.go:238
↓ 2 callersFunctionwriteVarint
(buf *bytes.Buffer, v uint64)
protocol/txvm/txvmutil/builder.go:134
↓ 2 callersFunctionzerovalToTopSplit
Find any value on the stack, move it to the top, and splitzero it. Returns nil if no value is found.
protocol/txbuilder/template.go:724
↓ 1 callersFunctionAfterStep
AfterStep can be passed as an option to Validate. It adds a callback to be invoked after each instruction is executed.
protocol/txvm/option.go:43
↓ 1 callersMethodBlockWaiter
BlockWaiter returns a channel that waits for the block at the given height.
protocol/protocol.go:230
↓ 1 callersFunctionCShakeSum128
CShakeSum128 writes an arbitrary-length digest of data into hash. n is a customization string for derived functions specified by NIST. Set n to an emp
crypto/sha3/cshake.go:29
↓ 1 callersFunctionCode
Code returns the opcode for the given name, or false if name is unknown.
protocol/txvm/op/op.go:122
↓ 1 callersMethodConcat
Concat concatenates an already assemble txvm program fragment onto the end of b.
protocol/txvm/txvmutil/builder.go:65
↓ 1 callersFunctionDetail
Detail returns the detail message contained in err, if any. An error has a detail message if it was made by WithDetail or WithDetailf.
errors/errors.go:115
↓ 1 callersFunctionEmptyTx
EmptyTx produces a minimal valid transaction from "nonce" and "finalize". The supplied blockID and exp are for computing the nonce. Some random bytes
protocol/bc/bctest/tx.go:18
↓ 1 callersFunctionFeFromBytes
(dst *FieldElement, src *[32]byte)
crypto/ed25519/internal/edwards25519/edwards25519.go:93
↓ 1 callersFunctionFeSquare2
FeSquare2 sets h = 2 * f * f Can overlap h with f. Preconditions: |f| bounded by 1.65*2^26,1.65*2^25,1.65*2^26,1.65*2^25,etc. Postconditions: |h| b
crypto/ed25519/internal/edwards25519/edwards25519.go:489
↓ 1 callersMethodFinalizeHeight
(context.Context, uint64)
protocol/protocol.go:105
↓ 1 callersMethodFromBytes
(b []byte)
protocol/state/serialize.go:10
↓ 1 callersFunctionFromMillis
FromMillis converts a number of milliseconds since 1970 to a time.Time.
protocol/bc/time.go:11
↓ 1 callersMethodGet
()
cmd/hex/flag.go:27
↓ 1 callersMethodGetBlock
GetBlock returns the block at the given height, if there is one, otherwise it returns an error.
protocol/block.go:29
↓ 1 callersFunctionIsSubset
(a, b interface{})
testutil/deepequal.go:203
↓ 1 callersMethodMaterialize
Materialize returns the transaction's program and ID. If the transaction ID cannot be computed because the transaction is not finalized or because of
protocol/txbuilder/template.go:416
↓ 1 callersFunctionMillisDuration
MillisDuration coverts milliseconds to a time.Duration.
protocol/bc/time.go:21
↓ 1 callersFunctionNegateInt32
NegateInt32 returns -a with an integer overflow check.
math/checked/checked.go:147
↓ 1 callersFunctionNewChain
NewChain makes a new Chain. By default it uses a memstore for storage and creates an initial block using a 0/0 multisig program. It commits the initia
protocol/prottest/block.go:74
← previousnext →301–400 of 1,025, ranked by callers