sfPaymentWebMoneyPlugin - 0.1.3

sfPaymentPlugin WebMoney implementation

You are currently browsing
the website for symfony 1

Visit the Symfony2 website


« Back to the Plugins Home

Signin


Forgot your password?
Create an account

Tools

Stats

advanced search
Information Readme Releases Changelog Contribute
Show source

sfPaymentWebMoneyPlugin

WARNING : This plugin is in alpha state, therefore NOT READY for production. It still needs contribution to be fully functional.

NOTE : You need to install sfPaymentPlugin

The sfPaymentWebMoneyPlugin is intended to ease integration with webmoney payment service.

Installation

  • Install the plugin

    $ symfony plugin:install sfPaymentWebMoneyPlugin --stability=alpha
    
  • Clear you cache

    $ symfony cc
    

Usage

At first, you need to configure the plugin by editing config/app.yml file. You have to change the vendor_purse, secret_key, because they depends on your webmoney references. Also you can change default module actions and validation algorithm(now only MD5 is supported).

When the plugin is ready!

Create a payment form. It can be done by BasesfPaymentWebMoneyActions::executePayForm() method. Optional parameters, such as user_id or order_id can be added too.

Results from WebMoney processed in BasesfPaymentWebMoneyActions::executeIpn() method. If payment is valid transactionCompleted will called.

SIGN validation

There are two possible means to verify payment. One of this is SIGN method. It's more complicated than MD5 method, but I guess more reliable. And It needs a WebMoney Keeper Classic. I haven't install it yet.

So that's how it works:

  1. DONE Make a string by sticking the parameters received in the ‘Payment notification form’ in the same order as at the control signature generation (see above). Remember that the Secret Key is used to generate the signature.

  2. There is ready PHP-lib Verify the digital signature. Use Interface X7. Specify the following parameters:

  • TesterWMID – WM identifier of the merchant;
  • ClientWMID – WM identifier of Merchant WebMoney Transfer that generates the digital signature of the
    payment notification. Its number is 967909998006.
  • AccessMarker -string received at the first stage of sticking parameters of the ’Payment notification
    form ’;
  • ClientSignStr – control signature generated by Merchant WebMoney Transfer and transmitted to the website of the merchant in the ‘Payment notification form’ (the ‘LMI_HASH’ parameter);
  • SignStr – digital signature of the request.

Tests

Test is written for use with sfPHPUnit2Plugin

TODO

  • Complete SIGN validation
  • Example of using system with users
  • Get feedbacks for this first version and improve plugin consistency

Links