Skip to content

Commit 07668f6

Browse files
authored
feat: Disable Express eTag response header for consistent FF behaviour across FF runtimes (#439)
* Revert "Revert "Disable Express eTag response header for consistent FF behaviour across FF runtimes (#433)" (#438)" This reverts commit 957320b. * lint: update newlines
1 parent 451723b commit 07668f6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/server.ts

+4
Original file line numberDiff line numberDiff line change
@@ -93,10 +93,14 @@ export function getServer(
9393
// Subsequent parsers will be skipped when one is matched.
9494
app.use(bodyParser.raw(rawBodySavingOptions));
9595
app.enable('trust proxy'); // To respect X-Forwarded-For header.
96+
9697
// Disable Express 'x-powered-by' header:
9798
// http://expressjs.com/en/advanced/best-practice-security.html#at-a-minimum-disable-x-powered-by-header
9899
app.disable('x-powered-by');
99100

101+
// Disable Express eTag response header
102+
app.disable('etag');
103+
100104
if (
101105
functionSignatureType === 'event' ||
102106
functionSignatureType === 'cloudevent'

0 commit comments

Comments
 (0)