identt
Classes | Functions
ProtoJsonSigned.hpp File Reference

identt More...

#include <query/ProtoJson.hpp>

Go to the source code of this file.

Classes

struct  identt::query::SignatureT
 

Functions

void identt::query::pb2signedjson (const google::protobuf::Message *msg, std::string &str, std::vector< SignatureT > &signatures)
 pb2signedjson : Convert protobuf to signed json simple no unsigned More...
 
void identt::query::pb2signedjson (const google::protobuf::Message *msg, const google::protobuf::Message *umsg, std::string &str, std::vector< SignatureT > &signatures)
 pb2signedjson : Convert protobuf to signed json with unsigned More...
 
int identt::query::signedjson2unsigned (const std::string &input, std::string &output, std::string &umsg, std::string &err, std::vector< SignatureT > &signatures)
 signedjson2unsigned : Convert signed json unsigned json string for verification More...
 
int identt::query::unsigned2signedjson (const std::string &input, const std::string &uinput, std::string &output, std::string &err, std::vector< SignatureT > &signatures)
 unsigned2signedjson : Convert uniigned json to signed json More...
 

Detailed Description

identt

Author
S Roychowdhury <sroycode at="" gmail="" dot="" com>="">
Version
1.0.0

LICENSE

Copyright (c) 2017 S Roychowdhury.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

DESCRIPTION

ProtoJsonSigned.hpp : Headers for Protobuf<->Json signed

Function Documentation

§ pb2signedjson() [1/2]

void identt::query::pb2signedjson ( const google::protobuf::Message *  msg,
std::string &  str,
std::vector< SignatureT > &  signatures 
)

pb2signedjson : Convert protobuf to signed json simple no unsigned

Parameters
msgconst google::protobuf::Message* from msg pointer
strstd::string& to string
stackof signatures std::vector<SignatureT>& signatures
Returns
none

§ pb2signedjson() [2/2]

void identt::query::pb2signedjson ( const google::protobuf::Message *  msg,
const google::protobuf::Message *  umsg,
std::string &  str,
std::vector< SignatureT > &  signatures 
)

pb2signedjson : Convert protobuf to signed json with unsigned

Parameters
msgconst google::protobuf::Message* from msg pointer
umsgconst google::protobuf::Message* from msg pointer for unsigned
strstd::string& to string
stackof signatures std::vector<SignatureT>& signatures
Returns
none

§ signedjson2unsigned()

int identt::query::signedjson2unsigned ( const std::string &  input,
std::string &  output,
std::string &  umsg,
std::string &  err,
std::vector< SignatureT > &  signatures 
)

signedjson2unsigned : Convert signed json unsigned json string for verification

Parameters
inputconst std::string& from string
outputstd::string& to string
umsgstd::string unsigned part of message
errstd::string& error string
stackof signatures std::vector<SignatureT>& signatures
Returns
int

§ unsigned2signedjson()

int identt::query::unsigned2signedjson ( const std::string &  input,
const std::string &  uinput,
std::string &  output,
std::string &  err,
std::vector< SignatureT > &  signatures 
)

unsigned2signedjson : Convert uniigned json to signed json

unsigned2signedjson : Convert signed json unsigned json string for verification

Parameters
inputconst std::string& from string signed
uinputconst std::string& from string unsigned
outputstd::string& to string
errstd::string& error string
stackof signatures std::vector<SignatureT>& signatures
Returns
int