'."\n";
} else {
diff --git a/htdocs/public/test/test_arrays.php b/htdocs/public/test/test_arrays.php
index 01910f71aaf..609ced5f684 100644
--- a/htdocs/public/test/test_arrays.php
+++ b/htdocs/public/test/test_arrays.php
@@ -44,6 +44,10 @@ $usedolheader = 1; // 1 = Test inside a dolibarr page, 0 = Use hard coded header
if (empty($usedolheader)) {
header("Content-type: text/html; charset=UTF8");
+
+ // Security options
+ header("X-Content-Type-Options: nosniff"); // With the nosniff option, if the server says the content is text/html, the browser will render it as text/html (note that most browsers now force this option to on)
+ header("X-Frame-Options: SAMEORIGIN"); // Frames allowed only if on same domain (stop some XSS attacks)
?>
diff --git a/htdocs/public/test/test_badges.php b/htdocs/public/test/test_badges.php
index 64ccf82345b..d3ed6476f95 100644
--- a/htdocs/public/test/test_badges.php
+++ b/htdocs/public/test/test_badges.php
@@ -12,6 +12,16 @@ if ($dolibarr_main_prod) {
accessforbidden('Access forbidden when $dolibarr_main_prod is set to 1');
}
+/*
+ * View
+ */
+
+header("Content-type: text/html; charset=UTF8");
+
+// Security options
+header("X-Content-Type-Options: nosniff"); // With the nosniff option, if the server says the content is text/html, the browser will render it as text/html (note that most browsers now force this option to on)
+header("X-Frame-Options: SAMEORIGIN"); // Frames allowed only if on same domain (stop some XSS attacks)
+
?>
diff --git a/htdocs/public/test/buttons.php b/htdocs/public/test/test_buttons.php
similarity index 100%
rename from htdocs/public/test/buttons.php
rename to htdocs/public/test/test_buttons.php
diff --git a/htdocs/public/test/test_csrf.php b/htdocs/public/test/test_csrf.php
index 3127a765985..43372d22f15 100644
--- a/htdocs/public/test/test_csrf.php
+++ b/htdocs/public/test/test_csrf.php
@@ -34,6 +34,11 @@ if ($dolibarr_main_prod) {
* View
*/
+header("Content-type: text/html; charset=UTF8");
+
+// Security options
+header("X-Content-Type-Options: nosniff"); // With the nosniff option, if the server says the content is text/html, the browser will render it as text/html (note that most browsers now force this option to on)
+header("X-Frame-Options: SAMEORIGIN"); // Frames allowed only if on same domain (stop some XSS attacks)
?>
This is a form to test if a CSRF exists into a Dolibarr page.
diff --git a/htdocs/public/test/test_exec.php b/htdocs/public/test/test_exec.php
index 026a8d12b7b..ef6f41df132 100644
--- a/htdocs/public/test/test_exec.php
+++ b/htdocs/public/test/test_exec.php
@@ -41,17 +41,6 @@ if (!defined("NOSESSION")) {
define("NOSESSION", '1');
}
-print "*** SHOW SESSION STATUS \n";
-print "Legend: \n";
-print 'PHP_SESSION_DISABLED='.PHP_SESSION_DISABLED." \n";
-print 'PHP_SESSION_NONE='.PHP_SESSION_NONE." \n";
-print 'PHP_SESSION_ACTIVE='.PHP_SESSION_ACTIVE." \n";
-print ' ';
-
-print 'session_status='.session_status().' (before main.inc.php) ';
-
-print '
'."\n";
-
require '../../main.inc.php';
// Security
@@ -64,6 +53,12 @@ if ($dolibarr_main_prod) {
* View
*/
+header("Content-type: text/html; charset=UTF8");
+
+// Security options
+header("X-Content-Type-Options: nosniff"); // With the nosniff option, if the server says the content is text/html, the browser will render it as text/html (note that most browsers now force this option to on)
+header("X-Frame-Options: SAMEORIGIN"); // Frames allowed only if on same domain (stop some XSS attacks)
+
print "*** TEST READ OF /tmp/test.txt FILE \n";
$out='';
diff --git a/htdocs/public/test/test_sessionlock.php b/htdocs/public/test/test_sessionlock.php
index 8464ba2eb4f..1aea6204b3e 100644
--- a/htdocs/public/test/test_sessionlock.php
+++ b/htdocs/public/test/test_sessionlock.php
@@ -41,6 +41,17 @@ if (!defined("NOSESSION")) {
define("NOSESSION", '1');
}
+
+// Special
+// We add header and output some content before the include of main.inc.php !!
+// Because we need to So we can make
+header("Content-type: text/html; charset=UTF8");
+
+// Security options
+header("X-Content-Type-Options: nosniff"); // With the nosniff option, if the server says the content is text/html, the browser will render it as text/html (note that most browsers now force this option to on)
+header("X-Frame-Options: SAMEORIGIN"); // Frames allowed only if on same domain (stop some XSS attacks)
+
+
print "Legend: \n";
print 'PHP_SESSION_DISABLED='.PHP_SESSION_DISABLED." \n";
print 'PHP_SESSION_NONE='.PHP_SESSION_NONE." \n";
diff --git a/htdocs/theme/eldy/global.inc.php b/htdocs/theme/eldy/global.inc.php
index 2e225e1658f..eff502190cb 100644
--- a/htdocs/theme/eldy/global.inc.php
+++ b/htdocs/theme/eldy/global.inc.php
@@ -5099,6 +5099,7 @@ tr.visible {
.websiteformtoolbar {
position: sticky;
top: ;
+ z-index: 1000;
}
.exampleapachesetup {
diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php
index ceb5caa9d44..8a6c864fb17 100644
--- a/htdocs/theme/md/style.css.php
+++ b/htdocs/theme/md/style.css.php
@@ -4953,6 +4953,7 @@ tr.visible {
.websiteformtoolbar {
position: sticky;
top: ;
+ z-index: 1000;
}
.exampleapachesetup {