Skip to content

Conversation

@themuffinator
Copy link
Owner

Summary

  • sanitize player social IDs and reject unsafe values before loading/saving configs
  • create or validate the baseq2/pcfg directory and warn when setup fails

Testing

  • not run (not requested)

Codex Task

…ety-issues-ztxzwa

Remove unused freeze implementation
Fix broadcast filters and stabilize string helpers
…-dll-file-size

Reduce release DLL size by using header-only fmt
…xitlevel-routine

Harden ExitLevel intermission screenshot handling
…on-error-in-g_main.cpp

Fix map list shuffle format usage
…ion-error

Fix screenshot command format strings
…nment-in-spawnentities

Ensure override checks see updated map name
…ion-in-spawnentities

Reset num_entities after clearing entity array
…to-manage-server_flags

Ensure server loading flag persists through initialization
…alue-initialization-in-spawnentities

Add helper to reset level struct safely
…s-for-code-reuse

Refactor SpawnEntities entity parsing
…opulation-after-reset

Preserve level entity string
…or-g_entities

Refactor G_Find to use span
…to-use-vector-arithmetic

Refactor findradius center distance calculation
…game.motd-memory

Handle MOTD buffer lifecycle
…remain-for-graceful-end

Handle Horde rounds when no active players remain
…nd-entries

Add null check for menu status bar entries
…nt-in-p_menu_buildstatusbar

Adjust status bar caret alignment
…ng-logic-for-serialization

Restore writeip persistence
…-helper-and-replace-push/pop

Add RAII guard for JSON stack handling
…er-fatal-error-handling

Stop emitting JSON warnings after fatal errors
…th_max-to-float-before-division

Fix vampiric regen cap rounding and add regression test
…ain-behavior-and-add-unit-test

Handle empty horde rosters in life check
…ndlymessage-for-spectators

Ensure spectators inherit team chat prefix
…in-main

Reset shared state between CTF flag tests
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +306 to +310
for (const char* ch = social_id; *ch; ++ch) {
if ((*ch >= '0' && *ch <= '9') ||
(*ch >= 'A' && *ch <= 'Z') ||
(*ch >= 'a' && *ch <= 'z') ||
*ch == '_') {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Sanitization drops hyphens causing existing configs to be ignored

The new sanitization only allows letters, digits, and underscores, stripping hyphens from social_id values while the filename later uses this sanitized id. Real social IDs in this codebase (e.g., Steamworks-…, EOS-…) contain hyphens, so a player who previously wrote baseq2/pcfg/Steamworks-7656….cfg will now look for baseq2/pcfg/Steamworks7656….cfg, fail to load their existing config, and silently create a new empty one. This regression resets configs for any account with a hyphenated ID, which appears to be the common case.

Useful? React with 👍 / 👎.

@ozy24 ozy24 force-pushed the main branch 2 times, most recently from e51338e to c2adaf5 Compare December 27, 2025 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants