2024年1月6日由于 robots.txt 包含有关网站结构的信息,因此攻击者可以利用robots.txt来了解仅通过重复爬行超链接无法访问的资源。如果我们在构建 Web 服务器时遵循常见的安全实践,那么我们肯定已经禁用了目录列表并创建了一些访问资源的规则。然而,仍然存在攻击者利用 robots 文件来了解我们的 Web 服务器的结构的风险。例如
2025年6月6日# this robots.txt file allows Slurp & Webcrawler to crawl # the public parts of our site, but no other robots ... User-Agent: slurp User-Agent: webcrawler Disallow: /private User-Agent: * Disallow: AI写代码 1 2 3 4 5 6 7 8 9 robots.txt文件中的行可以从逻辑上划分成“记录”。每...