SagePay::XORForm(3)

NAME
SagePay::XORForm - Perl extension for SagePay XOR form encryption

SYNOPSIS
  use SagePay::XORForm;

  my $obj = SagePay::XORForm->new( query_string => 'my form details string',
                                   key => 'my password string to encrypt with');

  my $encrypted_str = $obj->sage_xor_string([\%options]);

DESCRIPTION
Documentation for SagePay::XORForm. This module has been created to help ease the pain in creating a Perl side solution with the SagePay Form integration where an XOR encryption type format is required when posting data

  new()
Class constructor, simply pass the query string and password key strings in, the module will croak without these values included. NB you must know what your account password is as this will serve as the key

  sage_xor_string([\%options])
Call this method and the encrypted XOR string will be returned

%options

strip_newlines

By default is it's disable but if you'd like new lines to be stripped set to 1 to enable e.g.

my $enc_string = $obj->sage_xor_string({'strip_newlines' => 1});

Dependencies
MIME::Base64

SEE ALSO
SagePay documentation - http://www.sagepay.com/sites/default/files/pdf/user_guides/sagepayformprotocolandintegrationguidelines.pdf

AUTHOR
Cris Pini, <cris@perlconsulting.co.uk<gt>

COPYRIGHT AND LICENSE
Copyright (C) 2012 by Cris Pini

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.10.1 or, at your option, any later version of Perl 5 you may have available.