Keep the colleague's microbu-esp32c5 tree in this repository
obu-firmware builds against vanetza-idf from microbu-esp32c5/external, but that tree was gitignored, so a clone of this repository could not build the firmware it ships. It is now committed here as ordinary files in its own folder, microbu-esp32c5/: the colleague's commit cf4b99f plus the V2X2MAP bridge's signature verification (--trust) used on the bench. Nothing is fetched from or pushed to the colleague's repository; this repository and its remotes carry everything. The folder's own .gitignore keeps build output, downloaded components and private key material out, as it did there; the committed file set is identical to that repository's tracked files. The ESP32-C5 is still flashed from obu-firmware/, which only takes vanetza-idf from microbu-esp32c5/, so the two stay separate folders. FLASHING.md says how to take a newer version of the colleague's tree (copy it over the folder, rebuild, test, commit).
This commit is contained in:
@@ -0,0 +1,58 @@
|
||||
#ifndef SUBJECT_INFO_HPP_WCKSWSKY
|
||||
#define SUBJECT_INFO_HPP_WCKSWSKY
|
||||
|
||||
#include <vanetza/security/v2/serialization.hpp>
|
||||
#include <vanetza/common/byte_buffer.hpp>
|
||||
#include <array>
|
||||
#include <cstdint>
|
||||
|
||||
namespace vanetza
|
||||
{
|
||||
namespace security
|
||||
{
|
||||
namespace v2
|
||||
{
|
||||
|
||||
/// described in TS 103 097 v1.2.1, section 6.3
|
||||
enum class SubjectType : uint8_t
|
||||
{
|
||||
Enrollment_Credential = 0,
|
||||
Authorization_Ticket = 1,
|
||||
Authorization_Authority = 2,
|
||||
Enrollment_Authority = 3,
|
||||
Root_CA = 4,
|
||||
CRL_Signer = 5
|
||||
};
|
||||
|
||||
/// described in TS 103 097 v1.2.1, section 6.2
|
||||
struct SubjectInfo
|
||||
{
|
||||
SubjectType subject_type;
|
||||
ByteBuffer subject_name;
|
||||
};
|
||||
|
||||
/**
|
||||
* \brief Serializes a SubjectInfo into a binary archive
|
||||
*/
|
||||
void serialize(OutputArchive&, const SubjectInfo&);
|
||||
|
||||
/**
|
||||
* \brief Deserializes a SubjectInfo from a binary archive
|
||||
* \param archive with a serialized SubjectInfo at the beginning
|
||||
* \param SubjectInfo
|
||||
* \return size of the deserialized SubjectInfo
|
||||
*/
|
||||
size_t deserialize(InputArchive&, SubjectInfo&);
|
||||
|
||||
/**
|
||||
* \brief Calculates size of a SubjectInfo
|
||||
* \param SubjectInfo
|
||||
* \return number of octets needed to serialize SubjectInfo
|
||||
*/
|
||||
size_t get_size(const SubjectInfo&);
|
||||
|
||||
} // namespace v2
|
||||
} // namespace security
|
||||
} // namespace vanetza
|
||||
|
||||
#endif /* SUBJECT_INFO_HPP_WCKSWSKY */
|
||||
Reference in New Issue
Block a user