Files
threshold/internal/bsr/errors.go
T
Elim Tsiagbey fd3091d8dc feat: Decode Summary File (#3408)
* feat: Decode Summary File

- Add support for decoding BSR session, connection and channel summary file
- Introduce base summary interfaces that other protocols can extend
- Add new SSH register allocation function for getting SSH Channel Summary Type
2023-07-13 10:25:01 -04:00

45 lines
1.5 KiB
Go

// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: MPL-2.0
package bsr
import (
"errors"
)
var (
// ErrUnknown represents an unknown error
ErrUnknown = errors.New("unknown error")
// ErrInvalidParameter represents an invalid parameter error
ErrInvalidParameter = errors.New("invalid parameter")
// ErrBsrKeyPersistenceFailure indicates a failure in persisting BSR encryption keys
ErrBsrKeyPersistenceFailure = errors.New("could not persist BSR keys")
// ErrSummaryUnavailable indicates a BSR summary is unavailable
ErrSummaryUnavailable = errors.New("summary not available")
// ErrSignatureVerification indicates a failure in verifying a signature
ErrSignatureVerification = errors.New("could not verify signature")
// ErrNotSupported represents an operation that is not supported for a
// particular protocol.
ErrNotSupported = errors.New("not supported by protocol")
// ErrAlreadyRegistered is an error with registering functions.
ErrAlreadyRegistered = errors.New("type already registered")
// ErrEndChunkNotEmpty indicates a malformed END chunk.
ErrEndChunkNotEmpty = errors.New("end chunk not empty")
// ErrChunkDecode indicates an error when decoding a chunk.
ErrChunkDecode = errors.New("error decoding chunk")
// ErrInvalidMagic is used when a binary bsr file is missing the magic string.
ErrInvalidMagic = errors.New("invalid magic string")
// ErrChecksum indicates that a checksum did not match.
ErrChecksum = errors.New("computed checksum did NOT match")
)