talk is cheap, show me the code.
devServer.disableHostCheck
boolean
When set to true this option bypasses host checking. THIS IS NOT RECOMMENDED as apps that do not check the host are vulnerable to DNS rebinding attacks.
https://webpack.js.org/configuration/dev-server/#devserverdisablehostcheck
- vue-cli 2.x
devServer: { disableHostCheck: true, } - vue-cli 3.x
module.exports = { devServer: { disableHostCheck: true } }
本文介绍如何在Vue CLI 2.x和3.x中通过配置devServer.disableHostCheck为true来禁用主机检查,以绕过DNS重绑定攻击的潜在风险。此操作不推荐,因为会增加应用程序的安全风险。

616

被折叠的 条评论
为什么被折叠?



