Skip to content

Psalm's taint analysis does not work for magic properties with no phpdoc declaration #3668

@TysonAndre

Description

@TysonAndre

https://psalm.dev/r/22857fa662

Expected: If a property with name foo is set to an unsafe value, then psalm should warn about reads from foo being tainted, but not properties with other names such as other, whether or not there is an @property tag
Observed: No TaintedInput warning is emitted if the @property tag is absent. The example would also properly emit a warning if __get/__set are removed

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions