当选择“允许内容浏览”时允许在较新的 Artifactory 版本中执行脚本的步骤已启用?

发布于 2025-01-21 03:36:24 字数 460 浏览 1 评论 0 原文

在最新版本的文物中,设置“允许内容浏览”设置,以不允许脚本执行。例如,这意味着使用JavaScript的HTML无法正确渲染。 Jfrog的KB确认这是通过设计设置,并指出以下内容:

“如果您有兴趣禁用此安全性改进并允许脚本执行较新的文物版本,请与JFrog Support联系。”

https://jfrog.com/ knowledge-base/artifactory-blocked-blocked-blocked-script - 执行/

我们正在使用不包括支持的Pro许可级别的PREM版本的AN PREM版本。希望看到这一点的人能够提供我们自己禁用此安全性改进的步骤。

In the latest versions of Artifactory the setting “Allow Content Browsing” is setup to not allow script execution by design. That means HTML utilizing JavaScript, for example, does not render correctly. This KB from Jfrog confirms this is setup is by design and states the following:

"If you’re interested in disabling this security improvement and allowing script execution in newer Artifactory versions, kindly reach out to JFrog Support."

https://jfrog.com/knowledge-base/artifactory-blocked-script-execution/

We are using the on prem version of Artifactory with the Pro license level that doesn't include support. Hoping someone that sees this could provide the steps to disable this security improvement on our own.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

太阳公公是暖光 2025-01-28 03:36:24

将以下属性添加到位于位置 $ jfrog_home/artifactory/var/etc/actifactory artifactory.system.properties 文件:

artifactory.repo.browsing.content.security.policy=""

您可以在此处找到更多信息:

在此更改后,请执行伪影重新启动。

Add the following properties to the artifactory.system.properties file located at the location $JFROG_HOME/artifactory/var/etc/artifactory:

artifactory.repo.browsing.content.security.policy=""

You can find more information here: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/sandbox

Kindly perform the Artifactory restart after this change.

眉目亦如画i 2025-01-28 03:36:24

这些错误与内容浏览无关 - 它们实际上是您环境中的错误 - 至少在某种意义上,像Chrome这样的新浏览器正在强制使用其代码中使用适当的MIME类型。

此问题之所以发生,是因为客户端代码(例如在JavaScript中)请求加载CSS文件,并且服务器返回标题,说它是和HTML文件,或者它试图加载JavaScript文件,并且服务器将其返回它用标头说明内容类型为文本/html,

这很可能是由您的服务器本身安装的服务器引起的,也许是Apache或nginx配置问题或客户端和服务器之间的跃点(也许是Nginx服务器,加载均衡器或FireWall )

these errors are not related to the content browsing - they are actually bugs in your environment - at least in the sense that newer browsers like chrome are enforcing the use of the proper mime types in their code.

The issue occurs because the client code (in the javascript for example) requests to load a CSS file, for example, and the server returns a header saying it's and html file, or it it tried to load a javascript file and the server returns it with a header stating content type is text/html

This is most likely caused by your the server where artifactory is installed itself, perhaps apache or nginx config issue or a hop between the client and the server (perhaps a nginx server, load balancer or firewall)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文