Skip to content

For defense-in-depth only allow primitive types to be unserialize()-d - #1700

Merged
cpeel merged 2 commits into
DistributedProofreaders:masterfrom
bpfoley:security-2
Oct 27, 2026
Merged

cpeel merged 2 commits into
DistributedProofreaders:masterfrom
bpfoley:security-2

Conversation

@bpfoley

@bpfoley bpfoley commented Oct 27, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

Out of an abundance of caution in case there is some path by which
user-provided serialized data can be provided to the project search
filters. If that were to happen, it would likely be an exploitable
security hole.
As far as I can tell, only validated user input (arrays of
forum posting ID integers) is serialized into the DB, but out
of an abundance of caution, only allow primitive types to be
deserialized to avoid PHP unserialize() security issues.

@cpeel cpeel left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Love me some belt+suspenders.

@cpeel
cpeel merged commit 1046c9e into DistributedProofreaders:master Oct 27, 2026
12 checks passed
@bpfoley
bpfoley deleted the security-2 branch October 27, 2026 17:10
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.

2 participants