Keypop Calypso Crypto Legacy SAM C++ API - 1.0.0
Component of the Keypop C++ API
SignatureComputationData.hpp
Go to the documentation of this file.
1/******************************************************************************
2 * Copyright (c) 2025 Calypso Networks Association https://calypsonet.org/ *
3 * *
4 * This program and the accompanying materials are made available under the *
5 * terms of the MIT License which is available at *
6 * https://opensource.org/licenses/MIT. *
7 * *
8 * SPDX-License-Identifier: MIT *
9 ******************************************************************************/
10
11#pragma once
12
13#include <cstdint>
14#include <vector>
15
17
18namespace keypop {
19namespace calypso {
20namespace crypto {
21namespace legacysam {
22namespace transaction {
23
32template <typename T>
34public:
45 virtual T&
46 setData(const std::vector<uint8_t>& data, uint8_t kif, uint8_t kvc)
47 = 0;
48
61 virtual T& setSignatureSize(const int size) = 0;
62
74 virtual T& setKeyDiversifier(const std::vector<uint8_t>& diversifier) = 0;
75};
76
77} /* namespace transaction */
78} /* namespace legacysam */
79} /* namespace crypto */
80} /* namespace calypso */
81} /* namespace keypop */
Contains the input/output data of the FreeTransactionManager::prepareComputeSignature(SignatureComput...
virtual T & setData(const std::vector< uint8_t > &data, uint8_t kif, uint8_t kvc)=0
Sets the data to be signed and the KIF/KVC of the key to be used for the signature computation.
virtual T & setKeyDiversifier(const std::vector< uint8_t > &diversifier)=0
Sets a specific key diversifier to use before signing (optional).
virtual T & setSignatureSize(const int size)=0
Sets the expected size of the signature in bytes, which can be between 1 and 8 bytes (optional).