Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Encode cache values for SQLite with base64 to prevent failing on \0 characters #54178

Merged
merged 1 commit into from
Jan 13, 2025

Conversation

adamkiss
Copy link
Contributor

Fixes a Cache serialization issue when the cache store is sqlite3 and the cached/serialized object contains any private or protected methods/properties.

It also handles reading non-encoded (previous) cache from SQLite - if it doesn't detect : or ;, it doesn't to try to base64_decode and just serializes the value.

Fixes #54082

@taylorotwell taylorotwell merged commit 85a02ca into laravel:11.x Jan 13, 2025
40 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.

Cache on Sqlite3 includes NULL character in the value
2 participants