问题描述
我想编写自动测试来测试kibana UI中是否有日志,并且在使用Java向kibana发送http请求时遇到问题。从浏览器中,一切正常,但是当我从Jsoup库发送HTTP请求时(curl也会发生同样的情况),kibana向我显示以下内容:
Please upgrade your browser This Elastic installation has strict
security requirements enabled that your current browser does not meet.
好像kibana正在执行一些易受攻击的js,如果执行正确,它将停止加载kibana UI。
<script>
// Since this is an unsafe inline script,this code will not run
// in browsers that support content security policy(CSP). This is
// intentional as we check for the existence of __kbnCspNotEnforced__ in
// bootstrap.
window.__kbnCspNotEnforced__ = true;
</script>
<script src="/bundles/app/kibana/bootstrap.js"></script>
您是否知道如何通过代码解决该问题?我认为可以从kibana.yaml中禁用此安全功能,但我不想仅在测试时禁用它。
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)