Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
Closed
Description
Bug report
Bug description:
GNU coreutilsrealpath -m doesn't raise an error for secret symlinks (no read permission):
wannes@Stefans-iMacdirs % sudo ls -l secret-symlinkl--------- 1 wannes staff 44 Jun 30 2023 secret-symlink -> /Users/wannes/path-picker/link-test/dirs/dirwannes@Stefans-iMacdirs % grealpath -m secret-symlink/Users/wannes/path-picker/link-test/dirs/secret-symlink
Butposixpath.realpath() does:
>>>importposixpath>>>posixpath.realpath("secret-symlink")Traceback (mostrecentcalllast):File"<stdin>",line1,in<module>File"<frozen posixpath>",line435,inrealpathFile"<frozen posixpath>",line495,in_joinrealpathPermissionError: [Errno13]Permissiondenied:'secret-symlink'
CPython versions tested on:
3.12
Operating systems tested on:
macOS