protected static <T extends Payload> SignedData<T> readPayload(
      final RLPInput rlpInput, final Function<RLPInput, T> decoder) {
    rlpInput.enterList();
    final T unsignedMessageData = decoder.apply(rlpInput);
    final SECPSignature signature =
        rlpInput.readBytes((SignatureAlgorithmFactory.getInstance()::decodeSignature));
    rlpInput.leaveList();

    return SignedData.create(unsignedMessageData, signature);
  }
Read payload.

@param <T> the type parameter of Payload
@param rlpInput the rlp input
@param decoder the decoder
@return the signed data
consensus/common/src/main/java/org/hyperledger/besu/consensus/common/bft/messagewrappers/BftMessage.java