public function process() { $this->result = $this->request->getPost(); // print_rr($downloadmd5); // print_rre($this->result); parent::process(); }
function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); $str = $request->getRawBody(); $ret = @json_decode($str); if (!$ret) { throw new Am_Exception_InternalError("Coinbase: Can't decode postback: " . $ret); } $this->order = @$ret->order; }
public function findTime() { $time = get_first($this->request->get('subscr_date'), $this->request->get('payment_date')); if (!$time) { return parent::findTime(); } $d = new DateTime($time); $d->setTimezone(new DateTimeZone(date_default_timezone_get())); return $d; }
function process() { try { parent::process(); } catch (Am_Exception_Paysystem_TransactionAlreadyHandled $e) { // do nothing if transaction is already handled } if (Am_Di::getInstance()->config->get('auto_login_after_signup')) { Am_Di::getInstance()->auth->setUser($this->invoice->getUser(), $this->request->getClientIp()); } }
public function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { $DR = preg_replace("/\\s/", "+", $request->get('DR', $_GET['DR'])); $rc4 = new Crypt_RC4($plugin->getConfig('secret', 'ebskey')); $QueryString = base64_decode($DR); $rc4->decrypt($QueryString); $QueryString = split('&', $QueryString); foreach ($QueryString as $param) { $param = split('=', $param); $request->setParam($param[0], $param[1]); } parent::__construct($plugin, $request, $request, $invokeArgs); }
function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); require_once dirname(__FILE__) . '/mapi/mapi_package.php'; // $r = HIPAY_MAPI_COMM_XML::analyzeNotificationXML($this->request->getPost('xml'), $operation, $status, $date, // $time, $transid, $amount, $currency, $idformerchant, $merchantdatas, $emailClient, $subscriptionId, $refProduct); $str = $this->request->getPost('xml'); //$request->getRawBody(); $xml = simplexml_load_string($str); //$this->_xml = $xml->mapi; $this->_xml = $xml; //The value of the MD5 is calculated for the information following the tag </md5content> and preceding the tag </mapi>. preg_match("/<\\/md5content>(.*)<\\/mapi>/im", $str, $matches); $this->_hash = md5($matches[1]); if (!$this->_xml) { throw new Am_Exception_Paysystem_TransactionInvalid('Invalid xml received from Hipay: ' . $str); } /* <?xml version="1.0" encoding="UTF-8"?> <mapi> <mapiversion>1.0</mapiversion> <md5content>c0783cc613bf025087b8bf5edecac824</md5content> <result> <operation>capture</operation> <status>ok</status> <date>2010-02-23</date> <time>10:32:12 UTC+0000</time> <transid>4B83AEA905C49</transid> <subscriptionId>753EA685B55651DC40F0C2784D5E1170</subscriptionId> (if the transaction is attached to a subscription) <origAmount>10.20</origAmount> <origCurrency>EUR</origCurrency> <idForMerchant>REF6522</idForMerchant> <emailClient>email_client@hipay.com</emailClient> <merchantDatas> <_aKey_id_client>2000</_aKey_id_client> <_aKey_credit>10</_aKey_credit> </merchantDatas> <refProduct0>REF6522</refProduct0> </result> </mapi> */ }
public function processValidated() { parent::processValidated(); if ($this->request->get('RebillAnchor')) { $this->invoice->data()->set(Am_Paysystem_Payonlinesystem::REBILL_ANCHOR, $this->request->get('RebillAnchor'))->update(); } }
public function processValidated() { parent::processValidated(); echo "REDIRECT=" . $this->plugin->getRootUrl() . "/thanks?id=" . $this->invoice->getSecureId("THANKS"); }
public function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); $this->invoice = Am_Di::getInstance()->invoiceTable->findFirstBy(array('public_id' => $request->get('reference_id'))); }
public function processValidated() { parent::processValidated(); echo "OK"; }
public function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { $this->tracking_params = $request->get("tracking_params"); $this->billing_address = $request->get("billing_address"); $this->subscription = $request->get("subscription"); parent::__construct($plugin, $request, $response, $invokeArgs); }
public function process() { $vars = $this->request->getPost(); if (($sign = $this->plugin->getConfig('signature')) && !isset($vars["WMI_SIGNATURE"])) { $this->printAnswer("Retry", "Parameter WMI_SIGNATURE is absent."); return; } if (!isset($vars["WMI_PAYMENT_NO"])) { $this->printAnswer("Retry", "Parameter WMI_PAYMENT_NO is absent."); return; } if (!isset($vars["WMI_ORDER_STATE"])) { $this->printAnswer("Retry", "Parameter WMI_ORDER_STATE is absent."); return; } $params = array(); foreach ($vars as $key => $value) { if ($key !== "WMI_SIGNATURE") { $params[$key] = $value; } } ksort($params, SORT_STRING); $values = ""; foreach ($params as $value) { $values .= $value; } $signature = base64_encode(pack("H*", $sign($values . $this->plugin->getConfig('key')))); if ($signature != $vars["WMI_SIGNATURE"]) { $this->printAnswer("Retry", "Wrong digital signature " . $vars["WMI_SIGNATURE"]); return; } if (strtoupper($this->request->get("WMI_ORDER_STATE")) != "ACCEPTED") { $this->printAnswer("Retry", "Unknown order status " . $vars["WMI_ORDER_STATE"]); return; } parent::process(); $this->printAnswer("Ok", "Order #" . $this->request->get("WMI_PAYMENT_NO") . " is paid!"); }
public function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); // $s = base64_decode(str_replace(" ", "+", $request->get("Crypt",$request->get("crypt")))); // $s = $plugin->sagepay_simple_xor($s, $plugin->getConfig('pass')); $s = Am_Paysystem_SagepayForm::decryptAes($request->get("Crypt", $request->get("crypt")), $plugin->getConfig('pass')); parse_str($s, $this->vars); }
function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); }
function processValidated() { parent::processValidated(); print "OK" . $this->invoice->invoice_id; }
public function processValidated() { if ($this->vars['action'] == 'mp_confirm_password') { parent::processValidated(); if (!$this->invoice->comment && ($n = $this->request->get('number')) && ($p = $this->request->get('passwd'))) { $this->invoice->updateQuick('comment', "SMS num/pass: {$n}/{$p}"); } } }
function setInvoiceLog(InvoiceLog $log) { parent::setInvoiceLog($log); $this->getPlugin()->logOther('SAFECART IPN:', $this->req); }
public function processValidated() { if (!$this->invoice) { return; } parent::processValidated(); }
public function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); $this->xml = simplexml_load_string($request->getRawBody()); }
function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); $this->_params = $this->request->isPost() ? $this->request->getPost() : $this->request->getQuery(); }
public function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { $this->vercode = split(":", $request->get('vercode')); parent::__construct($plugin, $request, $response, $invokeArgs); }
function setInvoiceLog(InvoiceLog $log) { parent::setInvoiceLog($log); $this->getPlugin()->logOther('1SC API NOTIFICATION', $this->_xml); $this->getPlugin()->logOther('1SC ORDER', $this->_order->asXML()); $this->getPlugin()->logOther('1SC CLIENT', $this->_client->asXML()); }
public function process() { $this->result = $this->request->getPost(); parent::process(); }
public function process() { $vars = $this->request->getPost(); $vars['CustomerID'] = $this->plugin->getConfig('CustomerID'); $vars['UserName'] = $this->plugin->getConfig('UserName'); $r = new Am_HttpRequest($this->getUrl() . '?' . http_build_query($vars, '', '&')); $response = $r->send()->getBody(); if (!$response) { throw new Am_Exception_Paysystem('Got empty response from API server'); } $xml = simplexml_load_string($response); if (!$xml) { throw new Am_Exception_Paysystem('Got error from API: response is not xml'); } $this->xml_result = $xml; parent::process(); }
public function processValidated() { parent::processValidated(); switch ($this->request->getParam($type)) { case '0': $this->invoice->addPayment($this); break; case '2': $this->invoice->addRefund($this, $this->request->get('ref')); break; } }
function processValidated() { parent::processValidated(); print $this->getPlugin()->getConfig('message', 'Thanks for your payment!'); }
public function processValidated() { if ($this->request->get('status') == 'closed') { $this->invoice->setCancelled(); } else { $user = $this->invoice->getUser(); $user->data()->set(Am_Paysystem_TargetpayWap::INVOICE_TRANSACTION_ID, $this->request->get('trxid'))->update(); parent::processValidated(); } }
public function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { $this->msp = $plugin->createMSP(); $this->msp->transaction['id'] = $request->get('transactionid'); parent::__construct($plugin, $request, $response, $invokeArgs); }
function __construct(Am_Paysystem_Abstract $plugin, Am_Request $request, Zend_Controller_Response_Http $response, $invokeArgs) { parent::__construct($plugin, $request, $response, $invokeArgs); $this->c = new Am_Controller($request, $response, $invokeArgs); $PathInfo = $request->getPathInfo(); $this->_case = substr($PathInfo, strrpos($PathInfo, '/') + 1); $this->_params = $this->request->isPost() ? $this->request->getPost() : $this->request->getQuery(); $receipt_id = ''; $invoice = $this->getInvoice(); //Am_Di::getInstance()->invoiceTable->findFirstByPublicId($payment_id); if ($invoice) { $receipt_id = Am_Di::getInstance()->invoicePaymentTable->getLastReceiptId($invoice->invoice_id); } if ($receipt_id) { $this->_params['transaction_id'] = $receipt_id; } }
public function processValidated() { if ($rbAccId = $this->request->get('rbAccountId')) { $this->invoice->data()->set(Am_Paysystem_BeanstreamRemote::RB_ACCOUNT_ID_KEY, $rbAccId)->update(); } parent::processValidated(); }