Skip to content

Commit

Permalink
Merge pull request #11440 from monojp/w4y-patches
Browse files Browse the repository at this point in the history
login form style fix, sprites css caching fix and extended security-related HTTP headers
  • Loading branch information
lem9 committed Aug 29, 2015
2 parents 2a5a378 + 699d55f commit 2192acf
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
16 changes: 16 additions & 0 deletions libraries/Header.class.php
Expand Up @@ -593,6 +593,22 @@ public function sendHttpHeaders()
. $captcha_url
. ";"
);
// Re-enable possible disabled XSS filters
// see https://www.owasp.org/index.php/List_of_useful_HTTP_headers
header(
'X-XSS-Protection: 1; mode=block'
);
// "nosniff", prevents Internet Explorer and Google Chrome from MIME-sniffing a
// response away from the declared content-type
/// see https://www.owasp.org/index.php/List_of_useful_HTTP_headers
header(
'X-Content-Type-Options: nosniff'
);
// Adobe cross-domain-policies
// see http://www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html
header(
'X-Permitted-Cross-Domain-Policies: none'
);
PMA_noCacheHeader();
if (! defined('IS_TRANSFORMATION_WRAPPER')) {
// Define the charset to be used
Expand Down
1 change: 1 addition & 0 deletions themes/pmahomme/css/common.css.php
Expand Up @@ -894,6 +894,7 @@
form.login input[type=text],
form.login input[type=password],
form.login select {
box-sizing: border-box;
width: 14em;
}

Expand Down
2 changes: 1 addition & 1 deletion themes/sprites.css.php
Expand Up @@ -11,7 +11,7 @@
exit();
}

$bg = $_SESSION['PMA_Theme']->getImgPath() . 'sprites.png';
$bg = $_SESSION['PMA_Theme']->getImgPath() . 'sprites.png?v=' . urlencode(PMA_VERSION);
/* Check if there is a valid data file for sprites */
if (is_readable($_SESSION['PMA_Theme']->getPath() . '/sprites.lib.php')) {

Expand Down

0 comments on commit 2192acf

Please sign in to comment.