CGI::Untaint::asin - validate an Amazon ID


CGI-Untaint-asin documentation Contained in the CGI-Untaint-asin distribution.

Index


Code Index:

NAME

Top

CGI::Untaint::asin - validate an Amazon ID

SYNOPSIS

Top

  use CGI::Untaint;
  my $handler = CGI::Untaint->new($q->Vars);

  my $url = $handler->extract( -as_asin => 'id' );

DESCRIPTION

Top

This CGI::Untaint input handler verifies that it is dealing with a plausible Amazon ID (asin). It does not (yet?) check that this is a *real* asin, just that it looks like one.

SEE ALSO

Top

CGI::Untaint

AUTHOR

Top

Tony Bowden

BUGS and QUERIES

Top

Please direct all correspondence regarding this module to: bug-CGI-Untaint-asin@rt.cpan.org

COPYRIGHT

Top


CGI-Untaint-asin documentation Contained in the CGI-Untaint-asin distribution.

package CGI::Untaint::asin;

$VERSION = '1.02';

use strict;
use base 'CGI::Untaint::object';

sub _untaint_re { 
  qr/^([\d\w]\d{3}[\d\w]{6})$/i;
}

1;