...

Package v12

import "github.com/hyperledger/fabric/core/handlers/validation/builtin/v12"
Overview
Index
Subdirectories

Overview ▾

Constants

const (
    DUPLICATED_IDENTITY_ERROR = "Endorsement policy evaluation failure might be caused by duplicated identities"
)

type Validator

Validator implements the default transaction validation policy, which is to check the correctness of the read-write set and the endorsement signatures against an endorsement policy that is supplied as argument to every invoke

type Validator struct {
    // contains filtered or unexported fields
}

func New

func New(c Capabilities, s StateFetcher, d IdentityDeserializer, pe PolicyEvaluator) *Validator

New creates a new instance of the default VSCC Typically this will only be invoked once per peer

func (*Validator) Validate

func (vscc *Validator) Validate(
    block *common.Block,
    namespace string,
    txPosition int,
    actionPosition int,
    policyBytes []byte,
) commonerrors.TxValidationError

Validate validates the given envelope corresponding to a transaction with an endorsement policy as given in its serialized form

func (*Validator) ValidateLSCCInvocation

func (vscc *Validator) ValidateLSCCInvocation(
    chid string,
    env *common.Envelope,
    cap *pb.ChaincodeActionPayload,
    payl *common.Payload,
    ac channelconfig.ApplicationCapabilities,
) commonerrors.TxValidationError

Subdirectories

Name Synopsis
..
mocks Code generated by mockery v1.0.0.