Skip to content

fix(data): resolve Shelf false negative#2845

Open
juliosuas wants to merge 12 commits intosherlock-project:masterfrom
juliosuas:fix/false-negative-shelf
Open

fix(data): resolve Shelf false negative#2845
juliosuas wants to merge 12 commits intosherlock-project:masterfrom
juliosuas:fix/false-negative-shelf

Conversation

@juliosuas
Copy link
Copy Markdown

Summary

Fixes #2806 — Shelf produces false negatives for all usernames.

Root Cause

shelf.im migrated to a SvelteKit SPA that returns HTTP 200 for all profile URLs, including non-existent users. The previous status_code detection always saw 200, so it marked every username as "Claimed" (or never found them, depending on flow).

Non-existent users render User Not Found in the page body.

Fix

Switch detection method from status_code to message with:

  • errorMsg: "User Not Found"
  • errorType: "message"

Verification

Test Username Expected Result
F- (known user) blue Claimed ✅ Claimed
F+ (nonexistent) xyzNonexistent123456789 Available ✅ Available

GNOME VCS (sherlock-project#2804): Switch from response_url to API-based detection
using /api/v4/users?username={} endpoint (same approach as GitLab).
The previous response_url method failed because non-existent users
get 302-redirected to /users/sign_in instead of staying at the
profile URL.

Patched (sherlock-project#2805): Update domain from patched.sh to patched.to.
The site migrated domains, causing all lookups to fail with the
old URL.

Verified both fixes: GNOME VCS API returns user data for existing
users and [] for non-existent ones. Patched.to returns the expected
error message for invalid users on the new domain.

Fixes sherlock-project#2804
Fixes sherlock-project#2805
Patched.sh now redirects to patched.to, which returns HTTP 403
for all requests (both existing and non-existing users) due to
Cloudflare WAF. This causes guaranteed false positives.

GNOME VCS fix (API-based detection) is retained and passes F+/F-
validation locally.
shelf.im migrated to a SvelteKit SPA that returns HTTP 200 for all
profile URLs. Non-existent users render 'User Not Found' in the page
body instead of a different status code.

Switch detection from status_code to message-based with errorMsg
'User Not Found'. Verified F+ and F- locally.
@github-actions
Copy link
Copy Markdown
Contributor

Automatic validation of changes

Target F+ Check F- Check
Root-Me ✔️   Pass ✔️   Pass
Shelf ✔️   Pass ✔️   Pass

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

False negative for: Shelf

1 participant