skey
(in payment response)
skey is a payment gateway generated returning hash string to ensure the payment result data integrity that passed to the merchant system. Merchants or developers MUST verify this hash string properly and compare the order ID, currency, amount, and the payment date/time, to protect self-interest from being cheated by a fraudster/hacker. It uses a “Secret Key” (like a private key) in combination with a data string for the hashing process.
Please note that there are other “skey” with different formulas in Merchant Request APIs’ parameters. Try not to confuse yourself with this payment response “skey”.
skey was encrypted twice using MD5 encryption hash function and consists of the following information (must be set in the following orders) :
First hash string
Transaction ID
Order ID
Status
Merchant ID (domain)
Amount
Currency
Final hash string
Payment Date/Time
Merchant ID (domain)
First hash string
Approval Code
Secret Key
Formula to generate skey
pre_skey = md5( txnID & orderID & status & merchantID & amount & currency)
skey = md5( paydate & merchantID & pre_skey & appcode & secret_key )
Example to generate skey for PHP developer
Last updated