Skip to content

Commit

Permalink
Fix CSRF check
Browse files Browse the repository at this point in the history
  • Loading branch information
collectiveaccess committed May 4, 2022
1 parent 198eaf9 commit 4740f39
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions themes/default/views/Contact/form_html.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
}
?>
<form id="contactForm" action="<?php print caNavUrl($this->request, "", "Contact", "send"); ?>" role="form" method="post">
<input type="hidden" name="crsfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<input type="hidden" name="csrfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<?php
if($pn_id && $t_item->getPrimaryKey()){
?>
Expand Down Expand Up @@ -95,4 +95,4 @@
<input type="hidden" name="sum" value="<?php print $vn_sum; ?>">
</form>

</div><!-- end col --></div><!-- end row -->
</div><!-- end col --></div><!-- end row -->
2 changes: 1 addition & 1 deletion themes/default/views/LoginReg/form_login_html.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
}
?>
<form id="LoginForm" action="<?php print caNavUrl($this->request, "", "LoginReg", "login"); ?>" class="form-horizontal" role="form" method="POST">
<input type="hidden" name="crsfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<input type="hidden" name="csrfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<div class="form-group">
<label for="username" class="col-sm-<?php print $vn_label_col; ?> control-label"><?php print _t("Username"); ?></label>
<div class="col-sm-7">
Expand Down
4 changes: 2 additions & 2 deletions themes/default/views/LoginReg/form_profile_html.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
}
?>
<form id="ProfileForm" action="<?php print caNavUrl($this->request, "", "LoginReg", "profileSave"); ?>" class="form-horizontal" role="form" method="POST">
<input type="hidden" name="crsfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<input type="hidden" name="csrfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<?php
foreach(array("fname", "lname", "email") as $vs_field){
if($va_errors[$vs_field]){
Expand Down Expand Up @@ -103,4 +103,4 @@
</script>
<?php
}
?>
?>
2 changes: 1 addition & 1 deletion themes/default/views/LoginReg/form_register_html.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
}
?>
<form id="RegForm" action="<?php print caNavUrl($this->request, "", "LoginReg", "register"); ?>" class="form-horizontal" role="form" method="POST">
<input type="hidden" name="crsfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<input type="hidden" name="csrfToken" value="<?php print caGenerateCSRFToken($this->request); ?>"/>
<?php
if($this->request->isAjax()){
?>
Expand Down

0 comments on commit 4740f39

Please sign in to comment.