Skip to content
This repository has been archived by the owner on Jan 27, 2021. It is now read-only.

Commit

Permalink
Fixed bug#10099: Missing challenge token checks on customer interface.
Browse files Browse the repository at this point in the history
Conflicts:
	CHANGES.md
  • Loading branch information
mgruner committed Dec 20, 2013
1 parent 4c5c15f commit 6f324aa
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 6 deletions.
1 change: 1 addition & 0 deletions CHANGES.md
@@ -1,4 +1,5 @@
#3.2.14 201?-??-??
- 2013-12-20 Fixed bug#[10099](http://bugs.otrs.org/show_bug.cgi?id=10099) - Missing challenge token checks on customer interface.
- 2013-12-17 Fixed bug#[10103](http://bugs.otrs.org/show_bug.cgi?id=10103) - ArticleTypeID is always undef in AgentTicketCompose.
- 2013-12-12 Added functionality to disable access to tickets of other customers with the same customer company in customer interface.
- 2013-12-12 Fixed bug#[9650](http://bugs.otrs.org/show_bug.cgi?id=9650) - Special character in customer id breaks Open Tickets in AgentTicketZoom.
Expand Down
2 changes: 1 addition & 1 deletion Kernel/Modules/CustomerPreferences.pm
Expand Up @@ -44,7 +44,7 @@ sub Run {
if ( $Self->{Subaction} eq 'Update' ) {

# challenge token check for write action
$Self->{LayoutObject}->ChallengeTokenCheck();
$Self->{LayoutObject}->ChallengeTokenCheck(Type => 'Customer');

# check group param
my $Group = $Self->{ParamObject}->GetParam( Param => 'Group' ) || '';
Expand Down
4 changes: 4 additions & 0 deletions Kernel/Modules/CustomerTicketMessage.pm
Expand Up @@ -193,6 +193,10 @@ sub Run {
return $Output;
}
elsif ( $Self->{Subaction} eq 'StoreNew' ) {

# challenge token check for write action
$Self->{LayoutObject}->ChallengeTokenCheck(Type => 'Customer');

my $NextScreen = $Self->{Config}->{NextScreenAfterNewTicket};
my %Error;

Expand Down
2 changes: 1 addition & 1 deletion Kernel/Modules/CustomerTicketProcess.pm
Expand Up @@ -227,7 +227,7 @@ sub Run {
}

if ( $Self->{Subaction} eq 'StoreActivityDialog' && $ProcessEntityID ) {
$Self->{LayoutObject}->ChallengeTokenCheck();
$Self->{LayoutObject}->ChallengeTokenCheck(Type => 'Customer');

return $Self->_StoreActivityDialog(
%Param,
Expand Down
4 changes: 4 additions & 0 deletions Kernel/Modules/CustomerTicketZoom.pm
Expand Up @@ -305,6 +305,10 @@ sub Run {

# check follow up
elsif ( $Self->{Subaction} eq 'Store' ) {

# challenge token check for write action
$Self->{LayoutObject}->ChallengeTokenCheck(Type => 'Customer');

my $NextScreen = $Self->{NextScreen} || $Self->{Config}->{NextScreenAfterFollowUp};
my %Error;

Expand Down
14 changes: 10 additions & 4 deletions Kernel/Output/HTML/Layout.pm
Expand Up @@ -1151,11 +1151,17 @@ sub ChallengeTokenCheck {
}

# no valid token found
$Self->FatalError(
Message => 'Invalid Challenge Token!',
);
if ($Param{Type} && lc $Param{Type} eq 'customer') {
$Self->CustomerFatalError(
Message => 'Invalid Challenge Token!',
);
}
else {
$Self->FatalError(
Message => 'Invalid Challenge Token!',
);
}

# ChallengeToken ok
return;
}

Expand Down

0 comments on commit 6f324aa

Please sign in to comment.