Navigation Menu

Skip to content

Commit

Permalink
Only allow iFrame integration within the same domain #1114
Browse files Browse the repository at this point in the history
  • Loading branch information
Fasse committed Oct 17, 2021
1 parent a71534e commit 2f4520d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion adm_program/system/bootstrap/constants.php
Expand Up @@ -24,7 +24,7 @@

define('ADMIDIO_VERSION_MAIN', 4);
define('ADMIDIO_VERSION_MINOR', 0);
define('ADMIDIO_VERSION_PATCH', 10);
define('ADMIDIO_VERSION_PATCH', 11);
define('ADMIDIO_VERSION_BETA', 0);
define('ADMIDIO_VERSION', ADMIDIO_VERSION_MAIN . '.' . ADMIDIO_VERSION_MINOR . '.' . ADMIDIO_VERSION_PATCH);

Expand Down
3 changes: 3 additions & 0 deletions adm_program/system/classes/HtmlPage.php
Expand Up @@ -449,6 +449,9 @@ public function show()
$hasPreviousUrl = true;
}

// disallow iFrame integration from other domains to avoid clickjacking attacks
header('X-Frame-Options: SAMEORIGIN');

// add page functions menu to global menu
$gMenu->addFunctionsNode($this->menuNodePageFunctions);

Expand Down
6 changes: 6 additions & 0 deletions adm_program/system/classes/HtmlPageInstallation.php
Expand Up @@ -114,6 +114,9 @@ public function setUpdateModus()
*/
public function show()
{
// disallow iFrame integration from other domains to avoid clickjacking attacks
header('X-Frame-Options: SAMEORIGIN');

$this->assignDefaultVariables();
$this->display('index.tpl');
}
Expand All @@ -132,6 +135,9 @@ public function show()
*/
public function showMessage($outputMode, $headline, $text, $buttonText, $buttonIcon, $destinationUrl)
{
// disallow iFrame integration from other domains to avoid clickjacking attacks
header('X-Frame-Options: SAMEORIGIN');

$this->assign('outputMode', $outputMode);
$this->assign('messageHeadline', $headline);
$this->assign('messageText', $text);
Expand Down

0 comments on commit 2f4520d

Please sign in to comment.