File and Project Information ¶ Scope Name Type Content FileHeader creationDateTime date 02.03.2023, 11:03:44 companyName string 3S-Smart Software Solutions GmbH libraryFile CmpX509Cert Implementation.library primaryProject True productName CODESYS productProfile CODESYS V3.5 SP16 Patch 3 contentFile CmpX509Cert Implementation.clean.json version version 2.0.0.0 ProjectInformation IsEndUserLibrary bool False Released True LastModificationDateTime date 02.03.2023, 11:03:42 LibraryCategories library-category-list System|SysLibs Author string CODESYS Development GmbH Company System CompiledLibraryCompatibilityVersion CODESYS V3.5 SP15 DefaultNamespace Description See: Description DocFormat reStructuredText Placeholder CmpX509Cert Implementation Project CmpX509Cert Implementation Title CmpX509Cert Implementation Version version 3.5.19.0
Library Reference ¶ This is a dictionary of all referenced libraries and their name spaces. CmpCrypto Interfaces ¶ Library Identification ¶ Name: CmpCrypto Interfaces Version: newest Company: System Namespace: CmpCrypto_Interfaces Library Properties ¶ LinkAllContent: False Optional: False QualifiedOnly: False SystemLibrary: False Key: CmpCrypto Interfaces, * (System) CmpX509Cert Interfaces ¶ Library Identification ¶ Name: CmpX509Cert Interfaces Version: newest Company: System Namespace: CmpX509Cert_Interfaces Library Properties ¶ LinkAllContent: False Optional: False QualifiedOnly: False SystemLibrary: False Key: CmpX509Cert Interfaces, * (System) SysSocket Interfaces ¶ Library Identification ¶ Name: SysSocket Interfaces Version: newest Company: System Namespace: SysSocket_Interfaces Library Properties ¶ LinkAllContent: False Optional: False QualifiedOnly: False SystemLibrary: False Key: SysSocket Interfaces, * (System) SysTime ¶ Library Identification ¶ Name: SysTime Version: 3.5.9.0 Company: System Namespace: SysTime Library Properties ¶ LinkAllContent: False Optional: False QualifiedOnly: False SystemLibrary: False Key: SysTime, 3.5.9.0 (System) SysTypes2 Interfaces ¶ Library Identification ¶ Name: SysTypes2 Interfaces Version: newest Company: System Namespace: SysTypes Library Properties ¶ LinkAllContent: False Optional: False QualifiedOnly: False SystemLibrary: False Key: SysTypes2 Interfaces, * (System)
Collections Library Documentation ¶ Company System Title Collections Version 3.5.17.0 Categories Intern|DataServer Author 3S-Smart Software Solutions GmbH Placeholder Collections Description 1 ¶ This library contains some collections and baseclasses to easily create own collections for some types. Contents: ¶ AbstrTreeNode (FunctionBlock) ChildCount (Property) GetChild (Method) GetFather (Method) IBase Sorted (Property) abstrNodeType (Property) proChildren (Property) BaseMap (FunctionBlock) BeginUpdate (Method) EndUpdate (Method) proUseOptimizedSortForInsertionAtTheEnd (Property) BaseVector (FunctionBlock) Capacity (Property) Clear (Method) Count (Property) InitMemory (Method) RemoveLast (Method) ReserveSpace (Method) proAfterAlloc (Method) proRemove (Method) BranchNamedTreeNode (FunctionBlock) ChildCount (Property) proChildren (Property) CaseSensitiveNamedTreeNode (FunctionBlock) CaseSensitiveComparison (Property) DintToDintMap (FunctionBlock) AddDintPair (Method) GetValue (Method) DintVector (FunctionBlock) AddDint (Method) GetDint (Method) DwordVector (FunctionBlock) AddDword (Method) GetDword (Method) Remove (Method) GVL_DebugOnlyCollections (GVL) Globals (GVL) InstancePathBuildingBranchNode (FunctionBlock) ChildCount (Property) InstancePathNodeType (Property) proChildren (Property) InstancePathBuildingNode (FunctionBlock) GetFullPath (Method) IBase InstancePathNodeType (Property) InstancePathNodeFinder (FunctionBlock) Find (Method) FindLong (Method) FindLongWithData (Method) FindWithData (Method) Initialize (Method) abstrIgnoreRootNode (Method) abstrNodeFound (Method) abstrNodeNotFound (Method) protCallNodeFoundForRootNode (Property) protCallNodeNotFoundForRootNode (Property) MemBuffer (FunctionBlock) Alloc (Method) CanResize (Method) FB_Exit (Method) InitStatic (Method) Resize (Method) NamedTreeNode (FunctionBlock) CaseSensitiveComparison (Property) FindChildByName (Method) IBase Name (Property) PStringToDintMap (FunctionBlock) AddPStringDintPair (Method) CaseSensitive (Property) Clear (Method) CopyStrings (Property) FB_Exit (Method) GetIndex (Method) GetKeyByIndex (Method) GetValue (Method) GetValueByIndex (Method) Remove (Method) SetValueByIndex (Method) PStringToXWORDMap (FunctionBlock) AddPStringXWORDPair (Method) CaseSensitive (Property) Clear (Method) CopyStrings (Property) FB_Exit (Method) GetIndex (Method) GetKeyByIndex (Method) GetValue (Method) GetValueByIndex (Method) Remove (Method) SetValueByIndex (Method) PStringVector (FunctionBlock) AddString (Method) GetString (Method) Pair_DintDint (Struct) Pair_PStringDint (Struct) Pair_PStringXWORD (Struct) Pair_StringDint (Struct) Pair_StringString (Struct) SortedBranchNamedTreeNode (FunctionBlock) Sorted (Property) SortedInstancePathBuildingBranchNode (FunctionBlock) Sorted (Property) SortedPStringVector (FunctionBlock) AddPString (Method) CaseSensitive (Property) GetPString (Method) StaticMemBuffer (Struct) StringBuilder (FunctionBlock) AppendChar (Method) AppendPString (Method) AppendString (Method) Capacity (Property) Clear (Method) GetPStringResult (Method) InitMemory (Method) Length (Property) ReserveSpace (Method) prvAppend (Method) StringFunctions PStrCat (Function) PStrCmp (Function) PStrICmp (Function) PStrIFind (Function) PStrLen (Function) PStrLenUntil (Function) PStrToUpper (Function) StringToDintMap (FunctionBlock) AddStringDintPair (Method) CaseSensitive (Property) GetValue (Method) StringToStringMap (FunctionBlock) AddStringStringPair (Method) CaseSensitive (Property) GetValue (Method) abstrAssign (Method) StringVector (FunctionBlock) AddString (Method) GetString (Method) RemoveAt (Method) UtilTokenizer (FunctionBlock) CurrentPosition (Property) Initialize (Method) NextToken (Method) XwordVector (FunctionBlock) AddXword (Method) FB_Exit (Method) GetXword (Method) Remove (Method) Indices and tables ¶ 1 Based on Collections.library, last modified 20.04.2021, 14:41:10. LibDoc 4.4.0.0-b.27 The content file Collections.clean.json was generated with CODESYS V3.5 SP16 Patch 3 on 20.04.2021, 14:41:10.
X509CertCmsVerify (FUN) ¶ FUNCTION X509CertCmsVerify : RTS_IEC_RESULT Verifies a CMS signature. This function can handle both (detached and attached) signatures. The signers certificate has to be located in the CMS container. Otherwise the verify will fail. The signers certificate is always verified against the trusted certificate store on the PLC. InOut: Scope Name Type Comment Return X509CertCmsVerify RTS_IEC_RESULT ERR_OK if the signature is valid and the signer was trustworthy. ERR_SIGNATURE_MISMATCH if the signature is invalid and / or the signer was not trustworthy. ERR_PARAMETER if the given parameters are not consistent. Input hCertStore RTS_IEC_HANDLE Handle to the certificate store. pCms POINTER TO RtsByteString Pointer to a byte string storing the CMS container. encoding RtsCertEncoding Encoding of the CMS container. pInData POINTER TO RtsByteString Used only if the signature is detached. In this case this byte string has to store the data to be verified pOutData POINTER TO RtsByteString Pointer to a byte string where to store the extracted data.
CertificateStore ¶ X509CertCreateCSR (Function) X509CertCreateSelfSigned (Function) X509CertGetPrivateKey (Function) X509CertStoreAddCert (Function) X509CertStoreClose (Function) X509CertStoreGetFirstCert (Function) X509CertStoreGetNextCert (Function) X509CertStoreGetRegisteredCert (Function) X509CertStoreOpen (Function) X509CertStoreRegister (Function) X509CertStoreRemoveCert (Function) X509CertStoreSearchGetFirst (Function) X509CertStoreSearchGetNext (Function) X509CertStoreUnregister (Function) X509CertVerify (Function) X509CertVerify2 (Function)
X509CertCreateCSR (FUN) ¶ FUNCTION X509CertCreateCSR : RTS_IEC_RESULT Create a new certificate request. A new PRIVATE key will be generated and automatically stored in the key store. The certificate request can be sent to an official CA to get a signed certificate. InOut: Scope Name Type Comment Return X509CertCreateCSR RTS_IEC_RESULT Input hCertStore RTS_IEC_HANDLE Handle to the certificate store hBackend RTS_IEC_HANDLE Handle to the back-end where to store the generated certificate. RTS_INVALID_HANDLE should be used if no back- end is specified. pCertInfo POINTER TO RtsX509CertInfo Information of the certificate to be generated. ui32KeySize UDINT Size in bits of the private key. encoding RtsCertEncoding Encoding of the generated CSR. pCSR POINTER TO RtsByteString The signing request in binary form.
X509CertCreateSelfSigned (FUN) ¶ FUNCTION X509CertCreateSelfSigned : RTS_IEC_HANDLE Create a new self signed certificate. A private key is generated and automatically stored. InOut: Scope Name Type Comment Return X509CertCreateSelfSigned RTS_IEC_HANDLE Input hCertStore RTS_IEC_HANDLE Handle to the certificate store hBackend RTS_IEC_HANDLE Handle to the back-end where to store the generated certificate. RTS_INVALID_HANDLE should be used if no back- end is specified. pCertInfo POINTER TO RtsX509CertInfo Information of the certificate to be generated. ui32KeySize UDINT Size in bits of the private key. pResult POINTER TO RTS_IEC_RESULT Result of the operation. ERR_OK: Everything went fine. ERR_INVALID_HANDLE: Some input handle is invalid. ERR_PARAMETER: Some input parameter is invalid. ERR_OVERFLOW: The timestamps of the certificate would overflow. ERR_NOMEMORY: Not enough memory to perform this operation. ERR_FAILED: Creation of self signed certificate failed. failed
X509CertGetPrivateKey (FUN) ¶ FUNCTION X509CertGetPrivateKey : RTS_IEC_RESULT Get the PRIVATE key OF the certificate. THIS is only possible if the private key stored in the certificate store. The format of this key is an implementation detail and has to match the expected format of the asymmetric functions of the CmpCrpyotItf. The key data is opaque for the user of the keys. InOut: Scope Name Type Comment Return X509CertGetPrivateKey RTS_IEC_RESULT Input hCertStore RTS_IEC_HANDLE Handle to the certificate store. hCert RTS_IEC_HANDLE Handle of the certificate of interest. pPrivateKey POINTER TO RtsCryptoKey Pointer to the cryptographic key storing the private key.
X509CertStoreAddCert (FUN) ¶ FUNCTION X509CertStoreAddCert : RTS_IEC_RESULT Add the given certificate to the Certificate store InOut: Scope Name Type Comment Return X509CertStoreAddCert RTS_IEC_RESULT Handle to the imported certificate. Input hCertStore RTS_IEC_HANDLE Handle of to certificate store. hBackend RTS_IEC_HANDLE Handle to the back-end where to store the generated certificate. RTS_INVALID_HANDLE should be used if no back- end is specified. hCert RTS_IEC_HANDLE Handle of the certificate to be imported. trustLevel RtsCertTrustLevel The category where to store the certificate. Note: RtsTrustLevel_Own ist not selectable.
X509CertStoreClose (FUN) ¶ FUNCTION X509CertStoreClose : RTS_IEC_RESULT Close the certificate store. InOut: Scope Name Type Comment Return X509CertStoreClose RTS_IEC_RESULT Input hCertStore RTS_IEC_HANDLE Handle of to certificate store.