Provide a framework for CSRF protection, with tests.

Add CSRF protection to Asset editSave, AssetManager, VersionTags and Group operations.
This commit is contained in:
Colin Kuskie 2009-07-06 16:58:57 +00:00
parent 4664ab7035
commit 5e4db3adb4
19 changed files with 362 additions and 62 deletions

View file

@ -378,6 +378,23 @@ sub get_output {
#----------------------------------------------------------------------------
=head2 method ( [ $method ] )
Getter/setter for the HTTP request method.
=cut
sub method {
my ($self, $newMethod) = @_;
my $method = $self->{method};
if (defined $newMethod) {
$self->{method} = $newMethod;
}
return $method;
}
#----------------------------------------------------------------------------
=head2 print ( @values )
Fake print method for the PseudoRequest object. It caches everything printed