cookie CmDecryptPioData

Description

CmDecryptPioData decrypts a given encrypted Hidden Data sequence using the Product Item Option Data Key (PIODK).

tmr_02

Triple Mode Redundancy-related information (TMR)

  • C, C++
  • C#
  • Python
/html-code>
  • C, C++

Syntax

int CMAPIENTRY CmDecryptPioData(CMBYTE* pabDest, CMUINT cbDest, CMBYTE* pabPiodkDest, CMUINT cbPiodkDest)

Parameter

pabDest points to the data received by CmGetSecureData to be decrypted in this buffer.

cbDest contains the length of data at pabDest. Has to be a multiple of 16.

pabPiodkDest points to the input Product Item Option Decryption Key (PIODK) controlling the decryption.

cbPiodkDest contains the length of data at pabDest. Usually the length is 16.

Return

TRUE is returned, if the decryption was successful - FALSE, if not.

Syntax

public bool CmDecryptPioData(byte[] abDest, byte[] abPiodkDest)

Parameter

abDest contains the data received by CmGetSecureData to be decrypted in this buffer.

abPiodkDest contains the input Product Item Option Decryption Key (PIODK) controlling the decryption.

Return

true is returned, if the decryption was successful - false, if not.

 

Syntax

import cmapi
 
cmapi.CodeMeter().CmDecryptPioData(pabDest: bytes, pabPiodkDest: bytes)
 -> bytes
throws CodeMeterApiFailedException()

Parameter

pabDest points to the data received by CmGetSecureData to be decrypted in this buffer.

pabPiodkDest points to the input Product Item Option Decryption Key (PIODK) controlling the decryption.

Return

The decrypted data, if the decryption was successful. An exception is thrown, if not.