Developers

PKI or Public Key Infrastructure is the defined framework of encryption and cybersecurity that secures interchanges between the server and the customer. PKI features a symmetric key methodology - a private key and a public key. Only the proprietor of the DSC can access the personal key and they have the liberty to select where and to whom the general public key goes.

This document is intended for portals/developers/ websites to integrate the API into their web applications and desktop application.

This helps the user in making their entire signing work easy and secure.

The specification can always change at the last minute. This is intended for selected people and is confidential.

Request Command<Command> <ts> <txn> <certificate> <File> <Pdf> <Data>
<ts>

This is Time Stamping element, which the server would pass to the signing Tool. (This is an Optional Element) The Signing tool would compare with the client system Date and Time and see the difference, if there is a difference for 30 seconds from Server Date and Time it would not Sign.

<txn>

A unique ID could be passed with each signing request, it would help the web application to get responsive and map it to the correct request. (this is an Optional Element)

<certificate>

The application could also pass to a prompt signing tool to match for a certificate present in Browser Store and operations could be performed. (This is an Optional Element)

  • if there is more than One Signature matching the criteria, then a Box showing all the matching signatures would be shown, and the user could select signature
  • If only One Signature is found, then our application would only show the pop-up for Password and it would automatically sign.
  • If no Parameters are sent then all allowed certificates would be shown.
<File>

Type= The Type of Data which needs to be Used by the Commands (This is a Mandatory Element) Allowed variables PDF, TXT, or XML

inputFile =Unsigned file path (full), which needs to be signed (This is Optional if you passing <data> element)

outputFile =Signed file copied here (optional)

<Page>

Only Numeric, Zero is not allowed

<cood>

Only Numeric allowed, two numeric values allowed, it would try to sign the pixels mentioned (depending on the resolutions of the file saved), else it would generate an error. Please separate the value by a comma, the first figure is horizontal and the next figure is vertical on the page (eg.79,100)

<size>

Only Numeric allowed, two numeric values allowed, and it would print the signature in the box mentioned here. Please separate the value by a comma the first figure is horizontal and the next figure is vertical on the page (eg.79,100)

<Invisiablesign>

For invisible signature. Allowed values are "yes" and "No"

<enableltv>

To enable the LTV. Allowed values are "yes" and "No"

<enabletimestamp>

To enable the embedded timestamp. Allowed values are "yes" and "No"

<data>

The actual data is encoded in Base64 format. (This is a Mandatory Element)

<attribute name="CN"> John </attribute >
<attribute name="O">John & Company </attribute>
<attribute name="OU"> Management </attribute>
<attribute name="T">CEO </attribute>
<attribute name="E">SomeEmail@domain.com </attribute>
<attribute name="SN"> A123 </attribute>
<attribute name="CA"> Capricorn CA </attribute>
<attribute name="TC"> SG </attribute>
<attribute name="AP"> Application Id </attribute>
<attribute name="VD"> Application Validity Date </attribute>
CN = Common Name
O = Organization Name
Ou = Organization Unit
T = Title
E = Email
SN = Serial Number
CA = Certifying Authority
TC = Type of certificate allowed variables
SG (Signing)
EN (Encryption)
AP = Application Id (This is intended for application developers)
VD = Application Validity Date

This Element is used when <File> element is PDF (This is an Optional Element)

  • This Element is used when we would want to sign the PDF file on a particular page and in a particular place.
  • In case no values are passed, the signing would happen in the file invisible form (No Physical footprint would leave in the file).
  • If the values are passed with <file> not equal to PDF the values present would not affect the signing Process.
  • This element is used for PDF file Signing only.

This is the actual command to help you perform operations using our applications

S.NO.COMMANDDESCRIPTION
01pkiNetworkSign

This command is used to Sign, XML, TEXT, and PDF, data has to be passed in Base64.

02pkiNetworkSignHash

This Command is used to sign Hash instead of sending the Base64 File

03pkiNetworkVerSign

This command is used to Verify Signature.

You could pass any existing document (Text, Pdf, XML), with attributes and it would verify the signature

04pkiNetworkEnc

This command is used for Encryption of Data.

05pkiNetworkDeEnc

This command is used for De Encryption of data.

06pkiNetworkCertExt

This command is used to extract details of the certificate.

The response would be details of the certificate in XML format, No attributes can be passed

07pkiNetworkCertAuth

This command is used to validate data and certificate details

Response would be Valid/ Not Valid, and you could pass all attributes.

08pkiNetworkFileEnc

This command is used to encrypt files from the client machine, when the command is initiated it would open a File browser window, a file would be selected, and the same file would be converted into Base64, and encrypted.

09pkiNetworkFileEncSign

This command is used to encrypt files from the client machine, when the command is initiated it would open a File Browser window, a file would be selected, the same file would be converted into Base64, and encrypted, then the same data would be signed with the selected DSC.

10pkiNetworkEncSign

This command is used to encrypt the block of the Text file and then the same data would be signed with the selected DSC.

11pkiNetworkEncExt

This command is used to extract the P7B file of the encryption certificate and the same would be converted into Base64 and sent back as a response.

12pkiNetworkFileSign

This command is used to Sign files from the client machine, when the command is initiated it would open a File Browser window, a file would be selected, and the same file would be converted into Base64, and encrypted.

Our Errors are divided into four different categories

  • ER - are related to Application
  • CR - are related to Certificate and Licensing related
  • PE - are related to API Data and before Signing
  • OT - are related to Actual Signing
Error CodeError MessageAction
ER-01Latest version availableDownload new version of the application
ER-02License expiredRenew your Software license
ER-03Internal errorSend error details by email to the support team.
ER-04Operation not allowedAn illegal operation was attempted.
ER-05Invalid command nameThe command is not supported in this version of the software. Only allowed for listed commands
Error CodeError MessageAction
CR-01No License FoundThere was no certificate license found.
CR-02Chain certificate missingImport root chain
CR-03Certificate not foundPlease acquire software license or register DSC with PKI
CR-04Invalid CRL or OCSPPlease delete the files and sync the software
CR-05Invalid or corrupted licensesPlease delete all the license
Error CodeError MessageAction
PE-02Missing or invalid data element valuefile base64 with URL encoded
PE-03Invalid file type valuePass any of the [XML, PDF, TEXT]
PE-04Page number is out of rangeEnter page no according to PDF. and zero is not allowed
PE-05Invalid page numberBlank or zero is not allowed
PE-08Invalid type of certificate
  • SG : for signing
  • EN : for encryption or decryption
Error CodeError MessageAction
OT-02The action was cancelled by the userResend the request again
OT-03Private key is not foundInstall the token driver / chek the certificate
OT-04USB device not respondingReconnect USB device
OT-05Signing time outCheck date & time
OT-10Invalid base64 encoded datafile base64 with URL encoded
whatsapp