Answer the question
In order to leave comments, you need to log in
How to generate a digest?
There is the following instruction.
I can not understand.
Request headers
X-Signature header
Request electronic signature
To authorize terminal requests and establish authorship, the protocol uses asymmetric cryptographic algorithms with private and public keys:
ECDSA prime256v1
RSA 1024
RSA 2048
The SHA256 hash function is used to generate a message digest. The private key is generated on the terminal side and stored in the crypto storage. The public key is transferred to the Sendy PC during the terminal activation procedure.
Formation of the Electronic Signature (ES)
The body of the transmitted POST request is converted into a digest (hash) using the SHA256 algorithm and passed to the selected crypto algorithm. The received ES must be in the DER format (asn.1 serialized structure) with data on the crypto-algorithm used. Next, the binary ES is converted to a base64 sequence and passed to the request header in the "X-Signature" parameter.
The received ES must be in DER format (asn.1 serialized structure)
f5dcbf42be3cf18a87a0fd5127aabd8f5bcc78e96cb1811c0af3c687f350696a
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question