Home/Research/Post

GHSA-f9h7-4mmq-vgcq: Klever Go counts bitmap padding bits toward BLS quorum, allowing blocks with insufficient signatures

  • Severity: HIGH
  • CVE: CVE-2026-58262
  • Ecosystems: go
  • Packages: github.com/klever-io/klever-go

## Summary

When validating an incoming block header, `HeaderSigVerifier.verifyConsensusSize` counts *every* set bit in `PubKeysBitmap` — including bits that correspond to no validator (the padding bits of the final byte, which exist whenever the consensus group size is not a multiple of 8). The subsequent BLS aggregate-signature verification (`blsMultiSigner.Verify`) only checks signature validity for real validator indices and silently ignores those padding bits. As a result, a malicious or compromised block producer can set the padding bits to make the on-bits reach the PBFT quorum while only gathering a smaller number of real validator signature shares, causing a block to be accepted as correctly signed without a genuine two-thirds validator quorum.

## Details

Quorum counter counts padding bits — `core/process/headerCheck/headerSignatureVerify.go:145-183`:

“`go
func (hsv *HeaderSigVerifier) verifyConsensusSize(consensusPubKeys []string, header data.HeaderHandler) error {
consensusSize := len(consensusPubKeys)
bitmap := header.GetPubKeysBitmap()

expectedBitmapSize := consensusSize / 8
if consensusSize%8 != 0 {
expectedBitmapSize++
}
if len(bitmap) != expectedBitmapSize {
…
return ErrWrongSizeBitmap
}

numOfOnesInBitmap := 0
for index := range bitmap {
numOfOnesInBitmap += bits.OnesCount8(bitmap[index]) // = minNumRequiredSignatures {
return nil
}
…
return ErrNotEnoughSignatures
}
“`

The bitmap-byte-length check above only ensures the byte array…

Source: GitHub Security Advisories · 2026-11-23