VerificationCredential::VerificationCredential(
    CredentialSet& parent,
    const proto::Credential& credential)
        : ot_super(parent, credential)
{
    master_id_ = credential.childdata().masterid();
    data_.reset(new proto::VerificationSet(credential.verification()));
}
VerificationCredential::VerificationCredential(
    const api::Core& api,
    CredentialSet& parent,
    const proto::Credential& credential)
    : ot_super(api, parent, credential)
{
    mode_ = proto::KEYMODE_NULL;
    master_id_ = credential.childdata().masterid();
    data_.reset(new proto::VerificationSet(credential.verification()));
}
Пример #3
0
MasterCredential::MasterCredential(CredentialSet& theOwner, const proto::Credential& serializedCred)
: ot_super(theOwner, serializedCred)
{
    role_ = proto::CREDROLE_MASTERKEY;

    std::shared_ptr<NymIDSource> source = std::make_shared<NymIDSource>(
        serializedCred.masterdata().source());

    owner_backlink_->SetSource(source);
    source_proof_.reset(new proto::SourceProof(serializedCred.masterdata().sourceproof()));
}