Answer the question
In order to leave comments, you need to log in
Method in yii2 for reversible encryption whose result is no longer than 255?
For a secure transaction, you need to encrypt the checkout id so that it is not simply replaced in the response url.
checkout id - integer.
Yii2 has Yii::$app->getSecurity()->encryptByPassword() methods.
But the resulting string is long and bank gateway does not eat it.
You need a value of no more than 255 characters, which can be reversed.
What would you recommend using the Yii framework or just php functions?
Answer the question
In order to leave comments, you need to log in
It can be so. Table with 2 columns. checkout_id , hash .
A hash
\Yii::$app->security->generateRandomString($length);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question