{"id":18555355,"url":"https://github.com/0x727/fingerprinthub","last_synced_at":"2026-01-25T06:44:32.368Z","repository":{"id":37623709,"uuid":"398282332","full_name":"0x727/FingerprintHub","owner":"0x727","description":"侦查守卫(ObserverWard)的指纹库","archived":false,"fork":false,"pushed_at":"2024-01-26T01:41:31.000Z","size":9791,"stargazers_count":884,"open_issues_count":1,"forks_count":171,"subscribers_count":18,"default_branch":"main","last_synced_at":"2024-05-20T21:13:42.983Z","etag":null,"topics":["fingerprinting","nuclei-templates","wappalyzer","whatweb"],"latest_commit_sha":null,"homepage":"https://0x727.github.io/FingerprintHub/","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/0x727.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null},"funding":{"github":["cn-kali-team"]}},"created_at":"2021-08-20T13:17:26.000Z","updated_at":"2024-05-18T17:21:59.000Z","dependencies_parsed_at":"2024-01-24T19:45:09.564Z","dependency_job_id":null,"html_url":"https://github.com/0x727/FingerprintHub","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x727%2FFingerprintHub","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x727%2FFingerprintHub/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x727%2FFingerprintHub/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x727%2FFingerprintHub/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/0x727","download_url":"https://codeload.github.com/0x727/FingerprintHub/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239279538,"owners_count":19612514,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fingerprinting","nuclei-templates","wappalyzer","whatweb"],"created_at":"2024-11-06T21:26:15.801Z","updated_at":"2025-11-01T10:30:29.295Z","avatar_url":"https://github.com/0x727.png","language":null,"funding_links":["https://github.com/sponsors/cn-kali-team"],"categories":[],"sub_categories":[],"readme":"# FingerprintHub\n\n郑重声明：文中所涉及的技术、思路和工具仅供以安全为目的的学习交流使用，任何人不得将其用于非法用途以及盈利等目的，否则后果自行承担。\n\n- 该仓库为侦查守卫(observer_ward)指纹库，[observer_ward](https://github.com/emo-crab/observer_ward)是一个基于社区的指纹识别工具。\n- 旧版指纹已经归档在：https://github.com/0x727/FingerprintHub/tree/v3\n\n| 类别 | 说明                                              |\n|----|-------------------------------------------------|\n| 作者 | [三米前有蕉皮](https://github.com/cn-kali-team)       |\n| 团队 | [0x727](https://github.com/0x727) 未来一段时间将陆续开源工具 |\n| 定位 | 社区化指纹库，让管理和使用指纹规则更加简单。                          |\n| 语言 | Yaml                                            |\n| 功能 | 可自定义请求，使用github actions 自动更新指纹库。                |\n\n## 规则说明\n\n- 例子：下面为识别thinkphp的规则\n\n```yaml\nid: thinkphp\ninfo:\n  name: thinkphp\n  author: cn-kali-team\n  tags: detect,tech,thinkphp\n  severity: info\n  metadata:\n    product: thinkphp\n    vendor: thinkphp\n    verified: true\nhttp:\n  - method: GET\n    path:\n      - '{{BaseURL}}/'\n    matchers:\n      - type: favicon\n        hash:\n          - f49c4a4bde1eec6c0b80c2277c76e3db\n      - type: word\n        words:\n          - href=\"http://www.thinkphp.cn\"\u003ethinkphp\u003c/a\u003e\n          - thinkphp_show_page_trace\n        case-insensitive: true\n      - type: word\n        words:\n          - 'x-powered-by: thinkphp'\n        part: header\n        case-insensitive: true\n```\n\n## 规则组成\n\n- 在设计规则的时候参考了nuclei的template编写规范，将规则分为\n    - 基础信息：保存指纹的基本信息，和漏洞关联关系\n    - 探针：自定义发送数据包，http和tcp客户端\n    - 匹配器：关键词，正则表达式，favicon哈希\n    - 提取器：正则表达式，jsonpath\n\n### ID和基础信息\n\n```yaml\nid: thinkphp\ninfo:\n  name: thinkphp\n  author: cn-kali-team\n  tags: detect,tech,thinkphp\n  severity: info\n  metadata:\n    product: thinkphp\n    vendor: thinkphp\n    verified: true\n```\n\n| 字段          | 数据类型                    | 描述                                         |\n|-------------|-------------------------|--------------------------------------------|\n| id          | String                  | 规则ID，命中指纹会在终端打印该字段，不支持中文                   |\n| name        | String                  | 规则名称，一般和id一样，或者是它众所周知的别名，支持中文              |\n| author      | String                  | 作者列表，一个以逗号隔开的字符串列表                         |\n| tags        | String                  | 标签列表，一个以逗号隔开的字符串列表                         |\n| severity    | Enum                    | 严重程度：unknown,info,low,medium,high,critical |\n| metadata    | HashMap\u003cString,String\u003e  | 元数据，一个字典，可以存放任意类型数据                        |\n| description | Option\\\u003cString\\\u003e        | (可选)描述                                     |\n| reference   | Option\\\u003cVec\\\u003cString\\\u003e\\\u003e | (可选)引用参考链接                                 |\n\n- 其中的`metadata`内置有意义的字段\n    - 存储了CPE解析后的厂商`vendor`，产品信息`product`和是否已经经过验证`verified`，作用：关联nuclei漏洞验证插件\n    - 在服务指纹中储存了版本信息，后面编写服务指纹规则会详细描述\n\n- info中的`metadata`十分重要，它是指纹和漏洞关联的依据。要明白如何进行漏洞关联首先要了解什么是CPE：\n\n\u003e Common Platform Enumeration (CPE) 是由MITRE公司开发的一种标准化格式，用于表示网络设备、软件应用和其他IT资产的身份。在国家漏洞数据库（National\n\u003e Vulnerability Database, NVD）中，CPE用于精确描述每个漏洞影响的具体产品和版本。\n\nCPE命名规范包括以下部分：\n\n    核心部分：cpe:/a:vendor:product:version:update:edition:language:sw_edition:target_sw:target_hw:other\n        a: 表示应用程序（application）\n        vendor 是供应商或制造商的名字\n        product 是产品的名称\n        version 是主要版本号\n        update 是次要版本号或更新版本\n        edition 是特定版本（如企业版、标准版等）\n        language 是语言环境\n        sw_edition 是软件版本（如专业版、家庭版等）\n        target_sw 是目标操作系统或其他软件平台\n        target_hw 是目标硬件平台\n        other 是其他任何相关的信息\n\n    通配符：如果某项未知或不重要，可以使用通配符*代替具体值。\n\n- 例如，一个CPE字符串可能如下所示：cpe:/a:microsoft:windows_10:1903\n- NVD中的每个漏洞记录都包含受影响的CPE列表，帮助用户确定其系统是否受到特定漏洞的影响。这使得组织能够更准确地评估风险并采取相应的缓解措施。\n\n- 例如：[CVE-2016-4437](https://scap.kali-team.cn/cve/CVE-2016-4437)这个漏洞\n- 可以看到受到影响的产品为`cpe:2.3:a:apache:shiro:*:*:*:*:*:*:*:*`，对这个cpe进行解析后得到类型为应用，厂商为`apache`\n  ，产品为`shiro`，就可以编写以下规则：\n\n```yaml\nid: shiro\ninfo:\n  name: shiro\n  author: cn-kali-team\n  tags: detect,tech,shiro\n  severity: info\n  metadata:\n    product: shiro\n    vendor: apache\n    verified: true\n```\n\n- 如果我们通过读取`info`中的`metadata`cpe信息就可以反向查询到`CVE-2016-4437`\n  和其他[关联了这个cpe的漏洞](https://scap.kali-team.cn/cve/?vendor=apache\u0026product=shiro\u0026size=10)\n\n### 探针\n\n- 探针是引用了nmap的服务指纹的`probe`，在nuclei称`request`，但是我更喜欢`probe`探针\n- 探针目前分为`http`和`tcp`两种\n\n#### http探针\n\n```yaml\nhttp:\n  - method: GET\n    path:\n      - '{{BaseURL}}/'\n    headers:\n      Cookie: rememberMe=admin;rememberMe-K=admin\n```\n\n- 多个路径\n\n```yaml\n- method: GET\n  path:\n    - '{{BaseURL}}/'\n    - '{{BaseURL}}/nacos/'\n```\n\n| 字段      | 数据类型                               | 描述                                                            |\n|---------|------------------------------------|---------------------------------------------------------------|\n| method  | Enum                               | http请求方式：OPTIONS,GET,POST,PUT,DELETE,HEAD,TRACE,CONNECT,PATCH |\n| path    | Vec\\\u003cString\\\u003e                      | 路径列表，一般只为{{BaseURL}}/，代表首页请求，不建议填写特殊路径，除非首页没有任何特征             |\n| headers | Option\\\u003cHashMap\\\u003cString,String\\\u003e\\\u003e | (可选)请求头，一个键值对                                                 |\n| body    | Option\\\u003cString\\\u003e                   | (可选)请求体                                                       |\n\n- 支持raw请求，但是不建议在识别指纹规则填写\n\n#### tcp探针\n\n- 使用了[Nmap服务指纹识别](https://nmap.org/book/vscan-fileformat.html)\n\n```yaml\ntcp:\n  - name: \"null\"\n    inputs:\n      - data: \"\"\n        read: 16\n    host:\n      - \"{{Hostname}}\"\n```\n\n| 字段          | 数据类型             | 描述                                |\n|-------------|------------------|-----------------------------------|\n| name        | Option\\\u003cString\\\u003e | 探针名称，对应nmap中的probe_name           |\n| inputs.data | String           | 写入数据，会自动反转义，例如：`HTTP/1.0\\r\\n\\r\\n` |\n| inputs.read | Option\\\u003cusize\\\u003e  | (可选)读取多少数据长度，默认读取完全部，最多不超过2048字节  |\n| host        | Option\\\u003cString\\\u003e | (可选)主机                            |\n\n### 匹配器\n\n- 匹配器是在探针下面，当前匹配器只会对自己所在的探针响应作出匹配\n- 探针\n\n```yaml\nmatchers:\n  - type: favicon\n    hash:\n      - f49c4a4bde1eec6c0b80c2277c76e3db\n  - type: word\n    words:\n      - href=\"http://www.thinkphp.cn\"\u003ethinkphp\u003c/a\u003e\n      - thinkphp_show_page_trace\n    case-insensitive: true\n  - type: word\n    words:\n      - 'x-powered-by: thinkphp'\n    part: header\n    case-insensitive: true\n```\n\n| 字段               | 数据类型             | 描述                                               |\n|------------------|------------------|--------------------------------------------------|\n| name             | Option\\\u003cString\\\u003e | 匹配名称，如果不为空并且匹配到结果会返回                             |\n| type             | Enum             | 匹配类型：word，favicon，regex                          |\n| part             | Enum             | 匹配位置：header,body，默认：body                         |\n| favicon.hash     | Vec\\\u003cString\\\u003e    | 如果是favicon类型：hash为图标hash列表，支持md5和mmh3            |\n| word.words       | Vec\\\u003cString\\\u003e    | 关键词                                              |\n| case-insensitive | bool             | 是否忽略大小写，默认为`false`                               |\n| negative         | bool             | 是否将匹配结果取反，默认为`false`                             |\n| condition        | Enum             | 匹配关系：or,and，当为or时匹配到就立即返回，为and时要全部匹配到才返回结果，默认为or |\n\n#### 关键词\n\n- 当请求httpbin.org目标时，判断body里是否存在`\u003ctitle\u003ehttpbin.org\u003c/title\u003e`关键词，并且忽略大小写\n\n```yaml\nmatchers:\n  - type: word\n    words:\n      - \u003ctitle\u003ehttpbin.org\u003c/title\u003e\n    case-insensitive: true\n```\n\n- 例如：tomcat的规则，多个关键词，必须全部同时匹配\n\n```yaml\nmatchers:\n  - type: word\n    words:\n      - /manager/html\n      - /manager/status\n    condition: and\n```\n\n#### favicon哈希\n\n- 可以填写多个，只要匹配到一个就算命中指纹\n- 不需要在探针填写favicon的路径，工具会在主页html自动提取favicon的链接\n\n```yaml\nmatchers:\n  - type: favicon\n    hash:\n      - 4644f2d45601037b8423d45e13194c93\n      - 其他哈希，支持md5和mmh3\n```\n\n### 提取器\n\n- 用于从响应中提前信息返回到结果，例如：提取版本号\n\n#### 正则表达式\n\n- 建议少使用regex，因为初始化加载编译正则需要消耗更多cpu资源，如果有很多正则表达式启动会比较慢。\n- 例子：正则一般之用于服务识别，并且为了避免重复编译正则只在提取器中使用，下面为识别ssh服务的规则\n\n```yaml\nid: ssh\ninfo:\n  name: OpenSSH\n  author: cn-kali-team\n  tags: detect,tech,ssh,service\n  severity: info\n  metadata:\n    info: protocol $1\n    version: $2\ntcp:\n  - name: \"null\"\n    inputs:\n      - data: \"\"\n    host:\n      - \"{{Hostname}}\"\n    extractors:\n      - name: ssh\n        type: regex\n        regex:\n          - (?x)^SSH-([\\d.]+)-OpenSSH[_-]([\\w.]+)\\s*\\r?\\n\n```\n\n- 在这顺便补充服务指纹中的`metadata`，从上面的`ssh`指纹中可以看到`metadata`有两个键值对，并且存在`$1`和`$2`\n  。这里的$后面的数字就是提取器正则对应的提取组\n\n| 字段               | 数据类型             | 描述       |\n|------------------|------------------|----------|\n| product_name     | Option\\\u003cString\\\u003e | (可选)产品名称 |\n| version          | Option\\\u003cString\\\u003e | (可选)版本号  |\n| info             | Option\\\u003cString\\\u003e | (可选)信息   |\n| hostname         | Option\\\u003cString\\\u003e | (可选)主机名  |\n| operating_system | Option\\\u003cString\\\u003e | (可选)操作系统 |\n| device_type      | Option\\\u003cString\\\u003e | (可选)设备类型 |\n| cpe              | Vec\\\u003cString\\\u003e    | (可选)通用枚举 |\n\n- 在regex在线平台可以看到，右面的提取组`2.0`和`9.7`会对应替换到上面`metadata`的值，在结果中就会返回`version:[9.7]`\n  和`info:[protocol 2.0]`\n  ![提取组](images/regex.png)\n\n#### jsonpath\n\n- 类似命令行中的jq，例如：从json中提取`origin`的值可以使用下面的提取器\n\n```json\n{\n  \"origin\": \"1.1.1.1\"\n}\n```\n\n- 然后会在结果中返回`ip:[\"1.1.1.1\"]`\n\n```yaml\nextractors:\n  - type: json\n    name: ip\n    json:\n      - '.origin'\n```\n\n## 如何贡献\n\n### 验证单个指纹是否有效\n\n- 为了方便验证编写的yaml规则是否有效，可以使用`-p`参数指定要验证的yaml文件,`-t`\n  指定测试目标对指纹进行验证，并且使用`--debug`参数开启调试输出更多信息。\n\n```bash,no-run\n➜ ./observer_ward -t http://httpbin.org -p observer_ward/examples/json.yaml --debug           \n[INFO ] 📇probes loaded: 1                                                                                                               \n[INFO ] 🎯target loaded: 1                                                                                                               \n[INFO ] 🚀optimized probes: 1                                                                                                            \n[DEBUG] start: http://httpbin.org/                                                                                                       \n[DEBUG] Request {                                                                                                                        \n        uri: http://httpbin.org/ip,                                                                                                      \n        version: HTTP/1.1,                                                                                                               \n        method: GET,                                                                                                                     \n        headers: {                                                                                                                       \n            \"accept\": \"text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,*/*;q=0.8\",                           \n            \"content-type\": \"application/json\",                                                                                          \n        },                                                                                                                               \n        body: None,                                                                                                                      \n        raw_request: None,                                                                                                               \n    }\n[DEBUG] Response {\n        version: HTTP/1.1,\n        uri: http://httpbin.org/ip,\n        status_code: 200,\n        headers: {\n            \"date\": \"Mon, 08 Jul 2024 13:19:59 GMT\",\n            \"content-type\": \"application/json\",\n            \"content-length\": \"32\",\n            \"connection\": \"keep-alive\",\n            \"server\": \"gunicorn/19.9.0\",\n            \"access-control-allow-origin\": \"*\",\n            \"access-control-allow-credentials\": \"true\",\n        },\n        extensions: Extensions,\n        body: Some(\n            {\n              \"origin\": \"1.1.1.1\"\n            }\n            ,\n        ),\n    }\n[DEBUG] end: http://httpbin.org/\n🏹: http://httpbin.org/\n |_🎯:[ http://httpbin.org/]\n |_🎯:[ http://httpbin.org/ip [httpbin-ip]  \u003c\u003e]\n  |_📰: ip:[\"1.1.1.1\"] \n```\n\n### 提交指纹规则\n\n- 点击Fork按钮克隆这个项目到你的仓库\n\n```bash,no-run\ngit clone git@github.com:你的个人github用户名/FingerprintHub.git\n```\n\n- 添加上游接收更新\n\n```bash,no-run\ncd FingerprintHub\ngit remote add upstream git@github.com:0x727/FingerprintHub.git\ngit fetch upstream\n```\n\n- 配置你的github个人信息\n\n```bash,no-run\ngit config --global user.name \"$GITHUB_USERNAME\"\ngit config --global user.email \"$GITHUB_EMAIL\"\ngit config --global github.user \"$GITHUB_USERNAME\"\n```\n\n- 拉取所有分支的规则\n\n```bash,no-run\ngit fetch --all\ngit fetch upstream\n```\n\n- **不要**直接在`main`分支上修改，例如我想添加一个`thinkphp`的指纹，创建一个新的分支并切换到新的分支。\n\n```bash,no-run\ngit checkout -b thinkphp\n```\n\n- 复制一份指纹规则文件，修改文件名和你想要提交的组件名一样，修改yaml文件里面的`name`字段为添加的组件名，添加或者修改规则。\n- 跟踪修改和提交Pull-Requests，合并指纹。\n\n```bash,no-run\ngit add 你添加或者修改的文件名\ngit commit -m \"添加的组件名或者你的描述\"\ngit push origin thinkphp\n```\n\n- 打开你Fork这个项目的地址，点击与上游合并，等待审核合并指纹。\n\n### 谁在使用FingerprintHub\n\n- 如果你的开源工具中也使用了`FingerprintHub`，我感到非常的荣幸，欢迎补充列表，当项目有破坏性更新时可以及时通知到你。\n\n| [observer_ward](https://github.com/emo-crab/observer_ward) |\n|------------------------------------------------------------|\n| [nuclei](https://github.com/projectdiscovery/nuclei)       |\n| [nemo_go](https://github.com/hanc00l/nemo_go)              |\n| [afrog](https://github.com/zan8in/afrog)                   |\n| [ShuiZe](https://github.com/0x727/ShuiZe_0x727)            |\n\n### 指纹反馈\n\n- 当前指纹库收集于互联网，虽然已经经过了人工整理，但是难免会有以下情况：\n    - 出现误报，当指纹不够精确时会产生识别不准确的情况。\n    - 组件重复，可能出现多个组件名称，但是都是同一个组件。\n    - 识别不出组件，指纹规则覆盖不到。\n- 出现上面情况可以提交**issues**，可以附上演示URL地址，如果不方便演示可以提交首页的HTML源码，我们会人工修正指纹规则。\n\n### 谢谢\n\n- 感谢您的关注和支持！\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x727%2Ffingerprinthub","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F0x727%2Ffingerprinthub","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x727%2Ffingerprinthub/lists"}