Skip to content

Protect leaderboard privacy and normalize legacy aliases - #120

Merged
shimoverse merged 2 commits into
mainfrom
sync-origin
Sep 1, 2026
Merged

Protect leaderboard privacy and normalize legacy aliases#120
shimoverse merged 2 commits into
mainfrom
sync-origin

Conversation

@shimoverse

Copy link
Copy Markdown
Owner

What this changes

  • Enforces the leaderboard privacy boundary in the public API: only rows with at least 60 minutes saved are exposed, and public standings are capped at five rows.
  • Always returns the requesting installation's own row separately, including below the public threshold, with inTop calculated against the filtered standings.
  • Compacts exact legacy auto-generated aliases server-side while preserving custom names and the native client's 10–99 boundary.
  • Adds direct API regressions for the reveal threshold/cap, viewer fallback, and alias boundary behavior.
  • Leaves the native dashboard unchanged.

Verification

  • npm install — passed; 0 vulnerabilities
  • npm run test:api — 7 passed
  • python3 -m pytest -q — 287 passed, 1 optional skip
  • cd native && swift build — passed with Xcode 26.5 / Swift 6.3.2; existing deprecation warnings only
  • npm run build — passed
  • uvx ruff check voiceflow/ — passed
  • npm audit --audit-level=high — 0 vulnerabilities
  • Independent review — approved with no blocking findings
  • Direct endpoint reproduction — five public rows, all at least 60 minutes; below-threshold viewer still returned with inTop: false

No version, tag, release, or native DMG workflow changes are included.

shimoverse and others added 2 commits August 31, 2026 21:58
Only show rows with >=1hr saved, capped at 5, so the board never hints
at the real number of users; the viewer's own row always renders
regardless of their usage. Also compact legacy "Adjective Noun NN"
display names server-side so already-stored names lose their spaces
for every viewer, not just after the writing device relaunches.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The reveal threshold and row cap were only applied in the native
client; the public API still returned all rows, so a direct request
exposed sub-60-minute users. Move the filter/cap into
createLeaderboardHandler, which lets the original client code (using
board.you.inTop) work correctly unmodified.

Also fix _leaderboardAlias.js accepting any two-digit number where
Swift's compactLegacyDefault only accepts 10-99, which caused
00-09-suffixed names to be rewritten when the native app would have
left them untouched.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Sep 1, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
openvoiceflow Ready Ready Preview Sep 1, 2026 5:30am UTC

Request Review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-01T05:33:15.951574Z 59b3ca3 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@shimoverse
shimoverse merged commit a69cfb1 into main Sep 1, 2026
8 checks passed
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.

1 participant