Repository navigation
Tags
Tags
fix(fanavacard): refuse callbacks without the amount of the invoice (#… …370) * fix(fanavacard): refuse callbacks without the amount of the invoice When transactionAmount of the request was missing or differed from the amount of the invoice, verify() skipped the gateway and still returned a receipt, so a forged callback (or a verification without one) passed as a payment. It throws InvalidPaymentException now. * fix(fanavacard): send Token and RefNum at the top level of the reverse request The reverse request nested the token and the reference number under a numeric key beside WSContext, so the gateway never read them. They are merged in, as the verification request does, and the test checks the body it sends. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Mahdi Khanzadi <khanzadimahdi@gmail.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Fail cleanly on Novinopay answers without data (#377) The gateway can answer with status 100 and no data during an incident. The purchase then went on with a PHP warning and a null transaction id, and the verification ended in a TypeError while building the receipt. Both now throw the exception the caller expects instead: a PurchaseFailedException when the authority or the payment url is missing, and an InvalidPaymentException when the reference number is.
Add Referer header to Zibal requests (#362) * Add Referer header to Zibal requests According to Zibal's latest update, we need to add the `Referer` header to Zibal requests by September 11 (20 Shahrivar). https://zib.al/UWHS3PC * fix(zibal): make referer header configurable * fix: failing tests
Add `IranCurrency` enum for handling currency conversion (#349) * [feat] define Currency Constants * [chore] use Currency Constant on config file, and define method normalizeByCurrency * [chore] use method normalizeByCurrency on drivers * [chore] rename const * [test] add test for curency * [fix] fix passed type on sepehr driver * [feat] add trait for IranCurrency and use it on drivers need it * [fix] fix passed type on sepehr driver * [feat] add IranCurrency to enum class * [chore] update usage of the currency in drivers
Fixed unhandled exception in zarinpal in some rare cases (#358) * Chore: introduce CI * Fixed Null safety issue in some rare cases * Fixed Null safety issue in some rare cases * Resolved Issue related to phpstan --------- Co-authored-by: Mahdi Khanzadi <khanzadimahdi@gmail.com>
PreviousNext