Skip to content

Commit 21d5fa1

Browse files
committed
feat: add X-Frame-Options DENY header
Prevent iframe embeds, Fixes ethereum/devops#1593
1 parent ef384b5 commit 21d5fa1

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

next.config.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,19 @@ module.exports = (phase, { defaultConfig }) => {
7070
},
7171
],
7272
},
73+
async headers() {
74+
return [
75+
{
76+
source: "/(.*)", // Apply to all routes
77+
headers: [
78+
{
79+
key: "X-Frame-Options",
80+
value: "DENY",
81+
},
82+
],
83+
},
84+
]
85+
},
7386
}
7487

7588
if (phase !== PHASE_DEVELOPMENT_SERVER) {

0 commit comments

Comments
 (0)