• yacovm's avatar
    [FAB-13716] Block verifier book-keeping for onboarding · e0e3ddbb
    yacovm authored
    This change set adds the following supporting structs for adding
    support for verifying blocks pulled by onboarding in future CRs:
    - Ledger interceptor: intercepts a commit of a block, and invokes
      a callback.
    - VerificationRegistry: tracks commit of config blocks, and builds
      channelconfig bundles from them, in order to support verification
      of blocks pulled.
    - BlockVerifierAssembler and BlockValidationPolicyVerifier: together
      they build block verifiers out of config blocks.
    - verifierLoader: Loads a mapping of chainID->cluster.BlockVerifier,
      which is to be used at OSN startup to preload the existing verifiers.
      It is needed in cases we recover from a crash, or if we do
      dynamic onboarding and the previous config blocks have been committed
      to the ledger before the OSN was started.
    In the next CR, I will wire all these into the onboarding infrastructure
    itself, and they will be used to hold the latest bundle per channel
    in order to verify block signatures.
    Change-Id: Ic9fc99243baa5c2cef97103d001180207414d98a
    Signed-off-by: default avataryacovm <yacovm@il.ibm.com>