summaryrefslogtreecommitdiff
path: root/httemplate/elements/handle_uri_query
blob: 2dea96a6db99a226d969ff83b6690961951c91a9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<%init>

my %opt = @_;

if ( $cgi->param('redirect') ) {
  my $session = $cgi->param('redirect');

  my $pref = $FS::CurrentUser::CurrentUser->option("redirect$session");
  die "unknown redirect session $session\n" unless length($pref);
  $cgi = new CGI($pref);

  foreach my $param (grep /pay(info\d?|cvv)$/, $cgi->param) {
    my $value = $cgi->param($param);
    next unless length($value);
    my $decrypted = FS::Record->decrypt( $value );
    $cgi->param($param, $decrypted);
  }

}
</%init>