From 35a2792bb4cf7c13ce2a3ff227f03279628af95b Mon Sep 17 00:00:00 2001 From: Max Schmitt Date: Tue, 5 Jul 2022 17:48:30 +0200 Subject: [PATCH] fix(html-report): listen on 127.0.0.1 only (#15361) Fixes #11568 --- packages/playwright-core/src/utils/httpServer.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/playwright-core/src/utils/httpServer.ts b/packages/playwright-core/src/utils/httpServer.ts index a1918e95e8..f5b8a4f78a 100644 --- a/packages/playwright-core/src/utils/httpServer.ts +++ b/packages/playwright-core/src/utils/httpServer.ts @@ -58,7 +58,7 @@ export class HttpServer { this._activeSockets.add(socket); socket.once('close', () => this._activeSockets.delete(socket)); }); - this._server.listen(port); + this._server.listen(port, '127.0.0.1'); await new Promise(cb => this._server!.once('listening', cb)); const address = this._server.address(); assert(address, 'Could not bind server socket');