It exist cases when an uncompressed tarball has directories without
any traversal or read permissions so ensure to also fix directory
permissions in normalize_permissions function.
I spotted that issue while testing the CPAN loader in docker.
It is also happening when attempting to load some PyPI packages
(see Sentry issue below).
Fixes [SWH-LOADER-CORE-1AZ](https://sentry.softwareheritage.org/share/issue/ff458f16c4044a24871e0e57a8f2ae6e/)