Versions in this module Expand all Collapse all v1 v1.0.1 Apr 25, 2024 v1.0.0 Apr 25, 2024 Changes in this version + const MAX + const OFD_PATH + const SM3WITHSM2_OID + const SM3_OID + func LoadZipFileContent(rc *zip.ReadCloser, path string) ([]byte, error) + type Attachments struct + func (attachments *Attachments) GetFileContent(path string) ([]byte, error) + type AttachmentsXml struct + Attachment []struct{ ... } + Ofd string + Text string + XMLName xml.Name + type Category int + const SEAL + const SIGN + type Cert []byte + type CertDigestList struct + CertDigestObjs []CertDigestObj + type CertDigestObj struct + Type ObjType + Value CertDigestValue + type CertDigestValue []byte + type CertInfoList struct + Certs []Cert + type CommonData struct + func (commonData *CommonData) GetDocumentRes() (*DocumentRes, error) + func (commonData *CommonData) GetPublicRes() (*PublicRes, error) + func (commonData *CommonData) GetTemplatePage() (*Page, error) + type CommonDataResource int + const DOCUMENTRES + const PUBLICRES + const TEMPLATEPAGE + type CommonDataXml struct + DocumentRes struct{ ... } + MaxUnitID struct{ ... } + PageArea struct{ ... } + PublicRes struct{ ... } + TemplatePage struct{ ... } + Text string + type CommonValidator struct + func (common *CommonValidator) Digest(msg []byte) []byte + func (common *CommonValidator) Verify(cert []byte, msg []byte, signature []byte) (bool, error) + type ContentInfo struct + func NewContentInfo(input cryptobyte.String) (*ContentInfo, error) + func (contentInfo *ContentInfo) GetContent() []byte + type CustomTags struct + func (attachments *CustomTags) GetFileContent(path string) ([]byte, error) + type CustomTagsXml struct + CustomTag struct{ ... } + Ofd string + Text string + XMLName xml.Name + type DocResource int + const ATTACHMENTS + const CUSTOMTAGS + type Document struct + func (doc *Document) GetAttachments() (*Attachments, error) + func (doc *Document) GetCommonData() (*CommonData, error) + func (doc *Document) GetCustomTags() (*CustomTags, error) + func (doc *Document) GetPages() (*Pages, error) + func (document *Document) GetFileContent(path string) ([]byte, error) + type DocumentRes struct + func (docRes *DocumentRes) GetFileContent(path string) ([]byte, error) + type DocumentResXml struct + BaseLoc string + MultiMedias struct{ ... } + Ofd string + Text string + XMLName xml.Name + type DocumentXml struct + Attachments struct{ ... } + CommonData CommonData + CustomTags struct{ ... } + Ofd string + Pages Pages + Text string + XMLName xml.Name + type ExtensionDatas struct + Critical bool + ExtnId std.ObjectIdentifier + ExtnValue []byte + func New_ExtensionDatas(extDatas cryptobyte.String) (*ExtensionDatas, error) + type Hash interface + Digest func([]byte) []byte + type OFD struct + DocBody []struct{ ... } + Ofd string + Text string + Version string + XMLName xml.Name + type OFDReader struct + func NewOFDReader(path string, opts ...Option) (*OFDReader, error) + func (ofdReader *OFDReader) Close() error + func (ofdReader *OFDReader) GetDocumentById(docId string) (*Document, error) + func (ofdReader *OFDReader) GetFileContent(path string) ([]byte, error) + func (ofdReader *OFDReader) GetSignaturesById(docId string) (*Signatures, error) + func (ofdReader *OFDReader) OFD() (*OFD, error) + type ObjType string + type Option func(opt *Options) + func WithValidator(validator Validator) Option + type Options struct + type Page struct + type PageXml struct + Area struct{ ... } + Content struct{ ... } + Ofd string + Text string + XMLName xml.Name + type Pages struct + func (pages *Pages) GetFileContent(path string) ([]byte, error) + func (pages *Pages) GetPageById(pageId string) (*Page, error) + func (pages *Pages) GetPages() ([]Page, error) + type PagesXml struct + Page []struct{ ... } + Text string + type PublicRes struct + func (publicRes *PublicRes) GetFileContent(path string) ([]byte, error) + type PublicResXml struct + BaseLoc string + Fonts struct{ ... } + Ofd string + Text string + XMLName xml.Name + type Resource int + const DOCUMENT + const SIGNATURES + type SES_CertList struct + func New_SES_CertList(cert_type int64, cert_list cryptobyte.String) (*SES_CertList, error) + func (ses_certlist *SES_CertList) Get_CertDigestList() []byte + func (ses_certlist *SES_CertList) Get_Certs() []byte + type SES_ESPictrueInfo struct + Data []byte + Height int64 + Type string + Width int64 + func New_SES_ESPictrueInfo(pictrue cryptobyte.String) (*SES_ESPictrueInfo, error) + type SES_ESPropertyInfo struct + CertList cryptobyte.String + CertListType int64 + CreateDate time.Time + Name string + Type int64 + ValidEnd time.Time + ValidStart time.Time + func New_SES_ESPropertyInfo(ses_property cryptobyte.String) (*SES_ESPropertyInfo, error) + func (ses_property_info *SES_ESPropertyInfo) Get_CertList() (*SES_CertList, error) + type SES_Header struct + ID string + Version int64 + Vid string + func New_SES_Header(ses_header cryptobyte.String) (*SES_Header, error) + type SES_Seal_Info struct + func New_SES_Seal_Info(input cryptobyte.String) (*SES_Seal_Info, error) + func (ses_seal_info *SES_Seal_Info) Get_ESID() string + func (ses_seal_info *SES_Seal_Info) Get_ExtDatas() (*ExtensionDatas, error) + func (ses_seal_info *SES_Seal_Info) Get_Header() (*SES_Header, error) + func (ses_seal_info *SES_Seal_Info) Get_Pictrue() (*SES_ESPictrueInfo, error) + func (ses_seal_info *SES_Seal_Info) Get_Property() (*SES_ESPropertyInfo, error) + type SES_Signature struct + func New_SES_Signature(input cryptobyte.String) (*SES_Signature, error) + func (ses *SES_Signature) Get_Cert() ([]byte, error) + func (ses *SES_Signature) Get_Signature() []byte + func (ses *SES_Signature) Get_SignatureAlgId() string + func (ses *SES_Signature) Get_TBS_Sign() (*TBS_Sign, error) + type SESeal struct + func New_SESeal(seSeal cryptobyte.String) (*SESeal, error) + func (seal *SESeal) Get_Cert() ([]byte, error) + func (seal *SESeal) Get_SES_SealInfo() (*SES_Seal_Info, error) + func (seal *SESeal) Get_Signature() []byte + func (seal *SESeal) Get_SignatureAlgId() string + type Signature struct + Content []byte + func (signature Signature) GetFileContent(path string) ([]byte, error) + func (signature Signature) Verify() (bool, error) + func (signature Signature) VerifyDigest() (bool, error) + type SignatureXml struct + Ofd string + SignedInfo struct{ ... } + SignedValue struct{ ... } + Text string + XMLName xml.Name + type Signatures struct + func (signatures Signatures) GetFileContent(path string) ([]byte, error) + func (signatures Signatures) GetSignatureById(signId string) (*Signature, error) + type SignaturesXml struct + MaxSignId struct{ ... } + Ofd string + Signature []struct{ ... } + Text string + XMLName xml.Name + type SignedData struct + func NewSignedData(content cryptobyte.String) (*SignedData, error) + func (signedData *SignedData) GetCertificates() []byte + func (signedData *SignedData) GetSignerInfos() ([]SignerInfo, error) + type SignerInfo struct + func NewSignerInfo(signInfo cryptobyte.String) (*SignerInfo, error) + func (signerInfo *SignerInfo) GetAuthenticatedAttributes() cryptobyte.String + func (signerInfo *SignerInfo) GetDigestAlgorithm() string + func (signerInfo *SignerInfo) GetDigestEncryptionAlgorithm() string + func (signerInfo *SignerInfo) GetEncryptedDigest() cryptobyte.String + func (signerInfo *SignerInfo) GetIssuerAndSerialNumber() cryptobyte.String + func (signerInfo *SignerInfo) GetUnauthenticatedAttributes() cryptobyte.String + func (signerInfo *SignerInfo) GetVersion() int64 + type TBS_Sign struct + func New_TBS_Sign(input cryptobyte.String) (*TBS_Sign, error) + func (tbs *TBS_Sign) Get_DataHash() []byte + func (tbs *TBS_Sign) Get_Seal() (*SESeal, error) + func (tbs *TBS_Sign) Get_Version() int64 + type Validator interface + Verify func([]byte, []byte, []byte) (bool, error)