如何防止暴露 AEM 中的内容层次结构路径?我正在寻找 AEM 级别和调度程序级别的替代方案

2023-12-25

举个例子,你将如何实现: A。将 www.mysite.com 的点击翻译为 www.mysite.com/en 并 b.将上面的 www.mysite.com/en 翻译为 /content/mysite/en.html


这是一个完整的例子

  1. 看看上面的帖子本地调度程序设置 https://stackoverflow.com/questions/38954232/aem-security-environments-checklist/38955425#38955425 https://stackoverflow.com/questions/38954232/aem-security-environments-checklist/38955425#38955425
  2. 将本地主机设置为域名(w.r.t 操作系统 Windows 7)
  3. 与本地调度程序映射域名
  4. AEM 中的 etc/maps 设置用于缩短内容路径(请记住,我们可以根据您的要求对 etc/maps 正则表达式设置进行多种变体。)

本地主机到域名

更改主机文件中的设置,如下图所示。

Add entries of your like name as the domain names as shown below example. enter image description here

Access the project via the domain name as shown in the below screenshot. Your pages should be render as below. enter image description here

与本地调度程序映射域名

Open the dispatcher.any file (if you have separated the farms related to module open the specific site related farm file in my case it is) enter image description here

Make sure your virtualhost allows your domain name in the below screenshot “*” represents to allow all hosts. (Else if you want to allow only the specific domain names specify instead of *) enter image description here

通过 etc/map 缩短内容路径

可以手动创建 etc/maps 节点,如下面的屏幕截图所示 (或者您可以使用一些第三方开发的插件来创建它们http://cognifide.github.io/Carty/ http://cognifide.github.io/Carty/)

Add a virtual host entries in your dispatcher.any file or in a separate virtualhost file. In my case I have added them in a separate file. And enabled the file include in the httpd.conf file. Also enable the rewrite module else virtualhost file enrty rewrite will not work. enter image description here enter image description here

请务必注意突出显示的重写规则和 SetHandler 配置,这些是正确呈现页面的关键规则,否则请求可能会在调度程序级别本身停止,而不会传播到 AEM 的发布实例。

完成上述所有配置后,没有任何错误,您应该可以看到我们首页的域名访问了。所有其他页面应通过隐藏已在 etc/maps 中配置的内容路径,以简短形式的 url 呈现

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

如何防止暴露 AEM 中的内容层次结构路径?我正在寻找 AEM 级别和调度程序级别的替代方案 的相关文章

  • htaccess 清理 URL 的最佳方法是什么?

    我正在为我的网站开发干净的网址 我注意到您在互联网上找到的内容几乎都是将您的干净网址重写为您的服务器可以使用的网址 所以像这样 www domain com profile username gt www domain com profil
  • 如何将 Tomcat 重写阀添加到 Spring Boot 2.0 应用程序

    我正在尝试在 Spring Boot 应用程序中使用 Tomcat 重写阀 但是无法确定将 rewrite conf 放在哪里才能成功加载 我将 Spring Boot 2 0 3 RELEASE 与 Tomcat 8 5 31 一起使用
  • 在 IIS URL Rewrite 2.0 中,为什么 HTTP_HOST 包含端口号?

    我正在尝试使用IIS URL 重写 2 0 http www iis net downloads microsoft url rewrite在 Windows 8 1 上使用 IIS 8 5 根据从重写规则访问 URL 部分 http ww
  • IIS重写虚拟文件夹

    我需要在 IIS 中为以下内容创建 URL 重写规则 From http hostname virtual path folder myisapi dll a 1 b 1 To http hostname myisapi dll a 1 b
  • nginx 子域和域重写 w 代理通行证

    我需要这两种类型的重写 subdomain domain com gt domain com website subdomain otherdomain com gt domain com userdomain otherdomain co
  • VB.NET 和 COM Interop 看似随机崩溃

    我正在考虑用 VB 6 重写一个全新的 VB NET 应用程序 该应用程序在终端服务下运行并大量使用 COM 由于某种原因 该应用程序存在随机奇怪之处 随机访问冲突错误 WinDbg 异常分析指向 dll 如 comdlg32 dll ms
  • 无法在 OSGi 中解决 LDAP 库的 Maven 依赖关系

    我正在尝试导入 import org apache commons pool2 impl GenericObjectPool import org apache commons pool2 impl GenericObjectPoolCon
  • AEM 6.1 Maven 依赖关系解析

    我使用 AEM6 1 和 Maven 作为构建管理器 我想延长com day cq dam core process ThumbnailProcess班级 使用 ARM 内置依赖解析器 系统 控制台 depfinder 看来该类应该包含在
  • SEO URL 重写 ASP.NET

    我已经有一个 ASP NET 网站 我想更改我的网站 使其对 SEO 网址更加友好 我想改变前任这个网站 www mydomain aspx articleID 5 到 www mydomain article learningURLrew
  • AEM/CQ 中删除子组件的事件处理程序

    如何为 Adob e AEM6 组件添加在删除子组件时触发的事件处理程序 我可以将事件处理程序附加到多个侦听器 列在cq listeners 的文档 http dev day com docs en cq current developin
  • 如何用帖子标题 slug 重写 url?

    考虑一个网址 www example com paper ads details php req 43397 rnd 1308546000 我想将此网址更改为 www example com jobs in chanai php where
  • 将正则表达式拆分为 2 个捕获组

    好吧 我之前的问题都得到解答了 我还有一个 这个对我来说比较难 A Za z A Za z0 9 domain com 现在这个表达式只产生 1 个捕获组 如 所示 我该如何为此 URL 执行 2 个捕获组 用于IIS正则表达式重写 您可以
  • 从 URL 中删除文件扩展名

    我从未使用过 mod rewrite 但我想从网站的网址中删除所有文件扩展名 我需要遵循什么规则才能做到这一点 我已经尝试过这个 但是每次我单击网站上的链接时都会出现内部错误 RewriteRule 1 php L Options Mult
  • Request.Url.Query 和 Request.QueryString 有什么区别?

    我一直在追踪 URL 重写应用程序上的错误 该错误表现为查询字符串中某些变音符号的编码问题 基本上 问题是基本上 search aspx search he m nek 的请求被 search he c5 99m c3 a1nek 的查询字
  • 强制某些页面通过 HTTPS,而其他页面则通过 HTTP...这可能吗?

    我真的被这个困住了 基本上 我尝试使用 IIS 的 URLRewrite 附加组件始终通过 SSL 制作 2 个页面 但我还需要强制所有其他页面使用 HTTP 叹气 不要问 但如果我强制其他页面通过 HTTP 那么当您查看 SSL 页面时
  • ASP.NET Core URL 重写

    我正在尝试将我的网站从 www 重定向到非 www 规则以及 http 到 https https example com https example com 在中间件中 我曾经在 web config 中进行这些重定向更改 例如
  • 使用 IIS 7.5 的特定页面的 HTTPS URL 重写规则

    我正在尝试在 IIS 7 5 中进行 URL 重写 以重定向到 HTTPS 以获得 单页 域的其余部分应保留 HTTP 为此 我正在编辑 Web config 文件 有人可以告诉我我在做什么吗 以下规则错误
  • 这个重写规则是什么意思?

    我正在安装 phpancake 有一个像这样的文件夹 application install library public sql schema install html install php 这条规则意味着什么 RewriteEngin
  • 如何配置 nginx 重写规则以使 CakePHP 在 CentOS 上运行?

    大家好 请帮帮我 我正在尝试在运行 Nginx 和 Fact CGI 的 Centos 服务器上设置 cakephp 环境 我已经在服务器上运行了一个 WordPress 站点和一个 phpmyadmin 站点 因此我已经正确配置了 PHP
  • Cq5.5 将 servlet 过滤器应用于特定路径

    我正在 cq5 5 中开发自定义表单处理程序 一切都很顺利 我现在正在努力锁定一些安全性 我的任务之一是对表单处理程序路径实施请求限制过滤器 目前我有类似的东西 Component immediate true metatype true

随机推荐