plugin  2.1.3
Runtime plugin loader and Ed25519 DSO signing for C++ applications
fedem::sign::Manifest Class Reference

#include <Manifest.hh>

Static Public Member Functions

static ManifestResult read (std::string const &soPath)
 
static std::string toJson (ManifestData const &d)
 
static bool fromJson (std::string const &json, ManifestData &out, std::string &error)
 

Static Private Member Functions

static bool readElfSection (std::string const &path, std::string const &sectionName, std::vector< uint8_t > &out, std::string &error)
 ELF section extraction — mmap + manual header walk, no libelf. More...
 

Member Function Documentation

◆ read()

ManifestResult fedem::sign::Manifest::read ( std::string const &  soPath)
static

Read and parse manifest + signature from a DSO (ELF .so / .ffs / …).

Parameters
soPathabsolute or relative path to the DSO file

References fedem::sign::ManifestResult::data, fedem::sign::ED25519_SIG_BYTES, fedem::sign::ManifestResult::error, fromJson(), fedem::sign::ManifestResult::hasManifest, fedem::sign::ManifestResult::hasSig, fedem::sign::kManifestSection, fedem::sign::kSigSection, fedem::sign::ManifestResult::manifestJson, readElfSection(), and fedem::sign::ManifestResult::sig.

Referenced by fedem::sign::Verifier::verifyUncached().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ toJson()

std::string fedem::sign::Manifest::toJson ( ManifestData const &  d)
static

Serialise ManifestData to canonical JSON (fixed key insertion order). dso-sign uses this to produce the JSON before signing.

References fedem::sign::ManifestData::abiMajor, fedem::sign::ManifestData::abiMinor, fedem::sign::ManifestData::author, fedem::sign::ManifestData::name, fedem::sign::ManifestData::publicKeyId, fedem::sign::ManifestData::sha256, fedem::sign::ManifestData::timestamp, and fedem::sign::ManifestData::version.

Referenced by main().

+ Here is the caller graph for this function:

◆ fromJson()

bool fedem::sign::Manifest::fromJson ( std::string const &  json,
ManifestData out,
std::string &  error 
)
static

Parse JSON into ManifestData. Returns false and sets error on failure.

References fedem::sign::ManifestData::abiMajor, fedem::sign::ManifestData::abiMinor, fedem::sign::ManifestData::author, fedem::sign::ManifestData::name, fedem::sign::ManifestData::publicKeyId, fedem::sign::ManifestData::sha256, fedem::sign::ManifestData::timestamp, and fedem::sign::ManifestData::version.

Referenced by read().

+ Here is the caller graph for this function:

◆ readElfSection()

bool fedem::sign::Manifest::readElfSection ( std::string const &  path,
std::string const &  sectionName,
std::vector< uint8_t > &  out,
std::string &  error 
)
staticprivate

ELF section extraction — mmap + manual header walk, no libelf.

Referenced by read().

+ Here is the caller graph for this function:

The documentation for this class was generated from the following files: