Eneboo - Documentación para desarrolladores
'defines' | Funciones
Referencia del Archivo src/libdigidoc/ts/DigiDocTS.c
#include <libdigidoc/ts/DigiDocTS.h>
#include <libdigidoc/DigiDocError.h>
#include <libdigidoc/DigiDocDebug.h>
#include <libdigidoc/DigiDocGen.h>
#include <libdigidoc/DigiDocConvert.h>
#include <libdigidoc/DigiDocLib.h>
#include <libdigidoc/DigiDocCert.h>
#include <openssl/rand.h>
#include <openssl/ts.h>
#include <string.h>

'defines'

#define NONCE_LENGTH   64
#define ERR_LIB_NONE   1

Funciones

int ddocTsValidateTimestampType (const char *szType)
EXP_OPTION int ddocIncludeInfo_new (TimestampInfo *pTimestampInfo, IncludeInfo **ppIncludeInfo, const char *szURI)
EXP_OPTION int ddocIncludeInfo_free (IncludeInfo *pIncludeInfo)
EXP_OPTION const char * ddocIncludeInfo_GetURI (const IncludeInfo *pIncludeInfo)
EXP_OPTION int ddocIncludeInfo_SetURI (IncludeInfo *pIncludeInfo, const char *value)
int ddocIncludeInfo_toXML (const IncludeInfo *pIncludeInfo, DigiDocMemBuf *pBuf)
EXP_OPTION int ddocTimestampInfo_new (TimestampInfoList *pTimestampInfoList, TimestampInfo **ppTimestampInfo, const char *szId, const char *szType)
EXP_OPTION int ddocTimestampInfo_free (TimestampInfo *pTimestampInfo)
EXP_OPTION const char * ddocTimestampInfo_GetId (const TimestampInfo *pTimestampInfo)
EXP_OPTION int ddocTimestampInfo_SetId (TimestampInfo *pTimestampInfo, const char *value)
EXP_OPTION const char * ddocTimestampInfo_GetType (const TimestampInfo *pTimestampInfo)
EXP_OPTION int ddocTimestampInfo_SetType (TimestampInfo *pTimestampInfo, const char *value)
EXP_OPTION const DigiDocMemBufddocTimestampInfo_GetTS (const TimestampInfo *pTimestampInfo)
EXP_OPTION int ddocTimestampInfo_SetTS (TimestampInfo *pTimestampInfo, const char *value, long len)
EXP_OPTION const DigiDocMemBufddocTimestampInfo_GetRealDigest (const TimestampInfo *pTimestampInfo)
EXP_OPTION int ddocTimestampInfo_SetRealDigest (TimestampInfo *pTimestampInfo, const char *value, long len)
EXP_OPTION int ddocTimestampInfo_GetIncludeInfosCount (const TimestampInfo *pTimestampInfo)
EXP_OPTION IncludeInfoddocTimestampInfo_GetIncludeInfo (const TimestampInfo *pTimestampInfo, int nIdx)
EXP_OPTION IncludeInfoddocTimestampInfo_GetLastIncludeInfo (const TimestampInfo *pTimestampInfo)
EXP_OPTION int ddocTimestampInfo_DeleteIncludeInfo (TimestampInfo *pTimestampInfo, int nIdx)
EXP_OPTION int ddocTimestampInfo_AddIncludeInfo (TimestampInfo *pTimestampInfo, const char *szURI)
int ddocTimestampInfo_toXML (const TimestampInfo *pTimestampInfo, DigiDocMemBuf *pBuf)
EXP_OPTION int ddocTimestampInfoList_new (TimestampInfoList **ppTimestampInfoList)
EXP_OPTION int ddocTimestampInfoList_free (TimestampInfoList *pTimestampInfoList)
EXP_OPTION int ddocTimestampInfoList_GetTimestampInfosCount (const TimestampInfoList *pTimestampInfoList)
EXP_OPTION TimestampInfoddocTimestampInfoList_GetTimestampInfo (const TimestampInfoList *pTimestampInfoList, int nIdx)
EXP_OPTION TimestampInfoddocTimestampInfoList_GetTimestampInfoOfType (const TimestampInfoList *pTimestampInfoList, const char *szType)
EXP_OPTION TimestampInfoddocTimestampInfoList_GetOrCreateTimestampInfoOfType (TimestampInfoList *pTimestampInfoList, const char *szId, const char *szType)
EXP_OPTION int ddocTimestampInfoList_DeleteTimestampInfo (TimestampInfoList *pTimestampInfoList, int nIdx)
int ddocTsReadTsReq (TS_REQ **ppReq, DigiDocMemBuf *pMBufInData)
int ddocTsWriteTsReq (TS_REQ *pReq, DigiDocMemBuf *pMBufOutData)
EXP_OPTION int ddocTsReadTsResp (TS_RESP **ppResp, DigiDocMemBuf *pMBufInData)
int ddocTsWriteTsResp (TS_RESP *pResp, DigiDocMemBuf *pMBufOutData)
int ddocCreateNonce (ASN1_INTEGER **ppNonce, int bits)
int ddocTxt2Obj (ASN1_OBJECT **ppObj, const char *oid)
int ddocTsCreateTsReq (TS_REQ **ppReq, DigiDocMemBuf *pMBufDigest, const char *policy, int bNonce, int bCert)
int ddocTsCreateTsReqBin (DigiDocMemBuf *pMBufReq, DigiDocMemBuf *pMBufInData, const char *policy, int bNonce, int bCert)
int ddocGetHttpResponseCode (DigiDocMemBuf *pBuf)
int ddocGetHttpPayload (DigiDocMemBuf *pInBuf, DigiDocMemBuf *pOutBuf)
int ddocFindHostAndPathFromUrl (const char *url, char *szHost, int lHost, char *szPath, int lPath)
EXP_OPTION int ddocSendTSRequest (DigiDocMemBuf *pMBufDigest, TS_RESP **ppResp, const char *policy, int bNonce, int bCert, const char *url, const char *proxyHost, const char *proxyPort)
int ddocVerifyTSResponse (TS_RESP *pResp, const DigiDocMemBuf *pMBufDigest, X509 **pCACerts, char *szCAPath)
int ddocVerifyTimestampInfo (TimestampInfo *pTS, X509 **pCACerts, char *szCAPath, time_t *pTime, X509 **ppTsaCert)
int ddocTSResp_GetPolicyId (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
int ddocTSResp_GetStatus (TS_RESP *pResp, int *pStatus)
EXP_OPTION int ddocTSResp_GetSerial (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
int ddocTSResp_GetNonce (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
EXP_OPTION int ddocTSResp_GetTime (TS_RESP *pResp, time_t *pTime)
EXP_OPTION int ddocTSResp_GetTsaName (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
EXP_OPTION int ddocTSResp_GetMsgImprint (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
EXP_OPTION int ddocTSResp_GetMsgImprint_Algoritm (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
EXP_OPTION int ddocTsResp_GetSignerCertSerial (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
int ddocTsResp_GetSignerCertIssuer (TS_RESP *pResp, DigiDocMemBuf *pMBuf)
int ddocTsResp_GetSignerCert (TS_RESP *pResp, X509 **ppCert)

Documentación de los 'defines'

#define ERR_LIB_NONE   1
#define NONCE_LENGTH   64

Documentación de las funciones

int ddocCreateNonce ( ASN1_INTEGER **  ppNonce,
int  bits 
)
int ddocFindHostAndPathFromUrl ( const char *  url,
char *  szHost,
int  lHost,
char *  szPath,
int  lPath 
)
int ddocGetHttpPayload ( DigiDocMemBuf pInBuf,
DigiDocMemBuf pOutBuf 
)
int ddocGetHttpResponseCode ( DigiDocMemBuf pBuf)
EXP_OPTION int ddocIncludeInfo_free ( IncludeInfo pIncludeInfo)
EXP_OPTION const char* ddocIncludeInfo_GetURI ( const IncludeInfo pIncludeInfo)
EXP_OPTION int ddocIncludeInfo_new ( TimestampInfo pTimestampInfo,
IncludeInfo **  ppIncludeInfo,
const char *  szURI 
)
EXP_OPTION int ddocIncludeInfo_SetURI ( IncludeInfo pIncludeInfo,
const char *  value 
)
int ddocIncludeInfo_toXML ( const IncludeInfo pIncludeInfo,
DigiDocMemBuf pBuf 
)
EXP_OPTION int ddocSendTSRequest ( DigiDocMemBuf pMBufDigest,
TS_RESP **  ppResp,
const char *  policy,
int  bNonce,
int  bCert,
const char *  url,
const char *  proxyHost,
const char *  proxyPort 
)
EXP_OPTION int ddocTimestampInfo_AddIncludeInfo ( TimestampInfo pTimestampInfo,
const char *  szURI 
)
EXP_OPTION int ddocTimestampInfo_DeleteIncludeInfo ( TimestampInfo pTimestampInfo,
int  nIdx 
)
EXP_OPTION int ddocTimestampInfo_free ( TimestampInfo pTimestampInfo)
EXP_OPTION const char* ddocTimestampInfo_GetId ( const TimestampInfo pTimestampInfo)
EXP_OPTION IncludeInfo* ddocTimestampInfo_GetIncludeInfo ( const TimestampInfo pTimestampInfo,
int  nIdx 
)
EXP_OPTION int ddocTimestampInfo_GetIncludeInfosCount ( const TimestampInfo pTimestampInfo)
EXP_OPTION IncludeInfo* ddocTimestampInfo_GetLastIncludeInfo ( const TimestampInfo pTimestampInfo)
EXP_OPTION const DigiDocMemBuf* ddocTimestampInfo_GetRealDigest ( const TimestampInfo pTimestampInfo)
EXP_OPTION const DigiDocMemBuf* ddocTimestampInfo_GetTS ( const TimestampInfo pTimestampInfo)
EXP_OPTION const char* ddocTimestampInfo_GetType ( const TimestampInfo pTimestampInfo)
EXP_OPTION int ddocTimestampInfo_new ( TimestampInfoList pTimestampInfoList,
TimestampInfo **  ppTimestampInfo,
const char *  szId,
const char *  szType 
)
EXP_OPTION int ddocTimestampInfo_SetId ( TimestampInfo pTimestampInfo,
const char *  value 
)
EXP_OPTION int ddocTimestampInfo_SetRealDigest ( TimestampInfo pTimestampInfo,
const char *  value,
long  len 
)
EXP_OPTION int ddocTimestampInfo_SetTS ( TimestampInfo pTimestampInfo,
const char *  value,
long  len 
)
EXP_OPTION int ddocTimestampInfo_SetType ( TimestampInfo pTimestampInfo,
const char *  value 
)
int ddocTimestampInfo_toXML ( const TimestampInfo pTimestampInfo,
DigiDocMemBuf pBuf 
)
EXP_OPTION int ddocTimestampInfoList_DeleteTimestampInfo ( TimestampInfoList pTimestampInfoList,
int  nIdx 
)
EXP_OPTION int ddocTimestampInfoList_free ( TimestampInfoList pTimestampInfoList)
EXP_OPTION TimestampInfo* ddocTimestampInfoList_GetOrCreateTimestampInfoOfType ( TimestampInfoList pTimestampInfoList,
const char *  szId,
const char *  szType 
)
EXP_OPTION TimestampInfo* ddocTimestampInfoList_GetTimestampInfo ( const TimestampInfoList pTimestampInfoList,
int  nIdx 
)
EXP_OPTION TimestampInfo* ddocTimestampInfoList_GetTimestampInfoOfType ( const TimestampInfoList pTimestampInfoList,
const char *  szType 
)
EXP_OPTION int ddocTimestampInfoList_GetTimestampInfosCount ( const TimestampInfoList pTimestampInfoList)
EXP_OPTION int ddocTimestampInfoList_new ( TimestampInfoList **  ppTimestampInfoList)
int ddocTsCreateTsReq ( TS_REQ **  ppReq,
DigiDocMemBuf pMBufDigest,
const char *  policy,
int  bNonce,
int  bCert 
)
int ddocTsCreateTsReqBin ( DigiDocMemBuf pMBufReq,
DigiDocMemBuf pMBufInData,
const char *  policy,
int  bNonce,
int  bCert 
)
int ddocTsReadTsReq ( TS_REQ **  ppReq,
DigiDocMemBuf pMBufInData 
)
EXP_OPTION int ddocTsReadTsResp ( TS_RESP **  ppResp,
DigiDocMemBuf pMBufInData 
)
EXP_OPTION int ddocTSResp_GetMsgImprint ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
EXP_OPTION int ddocTSResp_GetMsgImprint_Algoritm ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
int ddocTSResp_GetNonce ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
int ddocTSResp_GetPolicyId ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
EXP_OPTION int ddocTSResp_GetSerial ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
int ddocTsResp_GetSignerCert ( TS_RESP *  pResp,
X509 **  ppCert 
)
int ddocTsResp_GetSignerCertIssuer ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
EXP_OPTION int ddocTsResp_GetSignerCertSerial ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
int ddocTSResp_GetStatus ( TS_RESP *  pResp,
int pStatus 
)
EXP_OPTION int ddocTSResp_GetTime ( TS_RESP *  pResp,
time_t *  pTime 
)
EXP_OPTION int ddocTSResp_GetTsaName ( TS_RESP *  pResp,
DigiDocMemBuf pMBuf 
)
int ddocTsValidateTimestampType ( const char *  szType)
int ddocTsWriteTsReq ( TS_REQ *  pReq,
DigiDocMemBuf pMBufOutData 
)
int ddocTsWriteTsResp ( TS_RESP *  pResp,
DigiDocMemBuf pMBufOutData 
)
int ddocTxt2Obj ( ASN1_OBJECT **  ppObj,
const char *  oid 
)
int ddocVerifyTimestampInfo ( TimestampInfo pTS,
X509 **  pCACerts,
char *  szCAPath,
time_t *  pTime,
X509 **  ppTsaCert 
)
int ddocVerifyTSResponse ( TS_RESP *  pResp,
const DigiDocMemBuf pMBufDigest,
X509 **  pCACerts,
char *  szCAPath 
)
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'