Skip to content

Commit aacdf47

Browse files
authored
Merge pull request #6638 from ShashaankS/Clickjacking_enhancement
Clickjacking Security Enhancement
2 parents 4b02a97 + 81adb1d commit aacdf47

File tree

3 files changed

+211
-0
lines changed

3 files changed

+211
-0
lines changed

gatsby-config.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,19 @@ module.exports = {
1717
},
1818
trailingSlash: "never",
1919
plugins: [
20+
{
21+
resolve: "gatsby-plugin-netlify",
22+
options: {
23+
headers: {
24+
"/*": [
25+
"X-Frame-Options: SAMEORIGIN",
26+
"Content-Security-Policy: frame-ancestors 'self'",
27+
],
28+
},
29+
mergeSecurityHeaders: true,
30+
mergeCachingHeaders: true,
31+
},
32+
},
2033
{
2134
resolve: "gatsby-plugin-webpack-bundle-analyser-v2",
2235
options: {

package-lock.json

Lines changed: 197 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@
6666
"gatsby-plugin-manifest": "^5.11.0",
6767
"gatsby-plugin-mdx": "3.20.0",
6868
"gatsby-plugin-meta-redirect": "github:layer5labs/gatsby-plugin-meta-redirect",
69+
"gatsby-plugin-netlify": "^5.1.1",
6970
"gatsby-plugin-preload-fonts": "^4.11.0",
7071
"gatsby-plugin-robots-txt": "^1.8.0",
7172
"gatsby-plugin-sharp": "^5.11.0",

0 commit comments

Comments
 (0)