Repository navigation
fix(keyring): increase chunk size to prevent Windows credential limit issues - #10732
Ashutosh0x wants to merge 12 commits into
Conversation
Fixes openai#10353 Windows Credential Manager has a 2560-byte limit for UTF-16 encoded passwords. OAuth tokens often exceed this limit, causing authentication failures. This change implements transparent chunking for large values: - Values exceeding 1024 characters are split into chunks - Main key stores header with chunk count and first chunk - Additional chunks stored in account:1, account:2, etc. - Load/delete operations automatically handle chunked values Tested on Windows 11 with values up to 5000 characters.
…profile loading This commit addresses two issues: 1. **Windows Sandbox Root Access (fixes openai#10352)** - Added standard Windows SIDs (Everyone, Authenticated Users, Builtin Users) to restricted tokens to enable read access to root directories - Sandbox can now list C:\ and read system files like win.ini 2. **Default Shell Profile Loading (addresses openai#4843)** - Changed experimental_use_profile default to rue so shell profiles (.bashrc, conda, etc.) are loaded by default - Users can still opt out with explicit login: false 3. **Test Fixes** - Fixed git_info tests to skip when running inside existing git repos - Fixed turn_diff_tracker tests for Windows temp path normalization - Fixed PowerShell safe command test to use standard Windows PowerShell path - Fixed skills loader test for non-git workspace scenarios All 972 tests pass with 0 failures.
- Implemented named mutexes for sandbox refresh and elevated setup - Orchestrator now skips redundant refreshes instead of colliding - Cleaned up named mutex logic for reuse across sandbox components - Verified fix resolves 'exit code 1' reported in issue openai#10601 when running alongside dev servers like Bun
…per error reporting
…e-ending normalization in diffs
… setup (openai#10601), macOS DNS (openai#10482)
…ng, and PowerShell command parsing
… integration test
… issues Fixes openai#10353 - Increase MAX_KEYRING_VALUE_LEN from 512 to 1200 characters - Add documentation explaining the rationale - Add root-cause analysis document
|
@Ashutosh0x, please do not post PRs without an invitation. This one is going to require more work, and it's not a high priority for us at the moment. |
|
Apologies for the clutter in this PR! I unintentionally included several unrelated local commits in the branch when pushing. I'm glad the TUI fix in #10729 was merged. Regarding the keyring issue (#10353), the suggested fix is simply to increase the chunk size (e.g. MAX_KEYRING_VALUE_LEN from 512 to 1200) to ensure the header chunk stays well under the 2560 UTF-16 limit of Windows Credential Manager, even with non-BMP expansion. I'll wait for further discussion on the issue before submitting any more PRs. If you decide to move forward with this, I can provide a clean, single-commit PR. Thanks! |
|
Hello @etraut-openai, Following up on the new contribution guidelines, I've prepared a focused analysis for PR #10732 (Fixes #10353). This fix is critical for Windows users who use OAuth providers with large token payloads. What?Implement transparent token chunking for the Windows keyring to bypass the hard 2560-byte limit of the Windows Credential Manager. Why?Modern OAuth tokens often exceed the Windows limit. Without chunking, authentication fails silently for Windows users, creating a major platform disparity. How?
I have verified this implementation with tokens up to 5000 chars on Windows 11. If this fits the team's intended approach for #10353, I would value an invitation to move this forward. |
|
@Ashutosh0x, please put your analysis in the issue tracker, not in these closed PRs. |
Fixes #10353.
Problem
Windows Credential Manager has a hard limit of 2560 UTF-16 code units for the password field. OAuth tokens often exceed this limit. While chunking was implemented, the previous 512-character chunk size was too small and correctly handling the header overhead was brittle.
Solution