SecureBlackbox 2020 C++ Edition

Questions / Feedback?

Sign Method

Creates a new CAdES signature over the provided data.

Syntax

ANSI (Cross Platform)
int Sign(int iLevel, int bDetached);

Unicode (Windows)
INT Sign(INT iLevel, BOOL bDetached);
- (void)sign:(int)level :(BOOL)detached;
#define MID_CADESSIGNER_SIGN 7

SECUREBLACKBOX_EXTERNAL int SECUREBLACKBOX_CALL SecureBlackbox_CAdESSigner_Do(void *lpObj, int methid, int cparam, void *param[], int cbparam[], int64 *lpllVal);

Remarks

Call this method to produce a new signature of the needed Level over the provided data. Set Detached to true to generate a detached signature (stored as a separate file and not including the data).

CAdES standard defines a number of different 'levels' of signatures. Supported signature levels:

cslUnknown0Unknown signature level

cslBES1BES (Basic Electronic Signature)

cslEPES2EPES (Electronic Signature with an Explicit Policy)

cslT3T (Timestamped)

cslC4C (T with revocation references)

cslXType15X Type 1 (C with an ES-C timestamp)

cslXType26X Type 2 (C with a CertsAndCRLs timestamp)

cslXLType17XL Type 1 (C with revocation values and an ES-C timestamp)

cslXLType28XL Type 2 (C with revocation values and a CertsAndCRLs timestamp)

cslBaselineB9Baseline B (B-B, basic)

cslBaselineT10Baseline T (B-T, timestamped)

cslBaselineLT11Baseline LT (B-LT, long-term)

cslBaselineLTA12Baseline LTA (B-LTA, long-term with archived timestamp)

cslExtendedBES13Extended BES

cslExtendedEPES14Extended EPES

cslExtendedT15Extended T

cslExtendedC16Extended C

cslExtendedXType117Extended X Type 1

cslExtendedXType218Extended X Type 2

cslExtendedXLType119Extended XL Type 1

cslExtendedXLType220Extended XL Type 2

cslExtendedA21Extended A

cslA22A (archived)

Error Handling (C++)

This method returns a result code; 0 indicates success, while a non-zero error code indicates that this method encountered an error during its execution. If an error occurs, the GetLastError() method can be called to retrieve the associated error message. (Note: This method's result code can also be obtained by calling the GetLastErrorCode() method after it returns.)

Copyright (c) 2022 /n software inc. - All rights reserved.
SecureBlackbox 2020 C++ Edition - Version 20.0 [Build 8166]