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

Better handling of unsafe filenames #352

Merged
merged 4 commits into from
Jul 29, 2024

Conversation

Carreau
Copy link
Collaborator

@Carreau Carreau commented Jul 16, 2024

See #346,

The handling of unsafe Filenames is a bit weird as the safety is checked a bit too late in my opinion, and checked before the path is fully resolved.

This tries to change this a bit by eing stricter on checking for safeness, and refactor the caching of import db to use Pathlib (which did not exists when FIlename was crreated).

This is still a bit more complicated than it should and might need some cleanup later on.

There is also a buch of "deprecated" code in a if True in this area, that would need propoer deprecation.

See deshaw#346,

The handling of unsafe Filenames is a bit weird as the safety is checked
a bit too late in my opinion, and checked before the path is fully
resolved.

This tries to change this a bit by eing stricter on checking for
safeness, and refactor the caching of import db to use Pathlib (which
did not exists when FIlename was crreated).

This is still a bit more complicated than it should and might need some
cleanup later on.

There is also a buch of "deprecated" code in a if True in this area,
that would need propoer deprecation.
@Carreau Carreau marked this pull request as ready for review July 16, 2024 14:59
@Carreau Carreau merged commit c508269 into deshaw:master Jul 29, 2024
8 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.

1 participant