noobaa-core
noobaa-core copied to clipboard
NSFS add bucket option "followSymlinks"
Environment info
- NooBaa Version: master-20210505
- Platform: NA
Actual behavior
- Currently we use stat to access the filesystem, which means that we will follow symlinks.
Expected behavior
- Using lstat makes sure that symbolic links are not followed, which might be required to prevent trespassing over to other areas of the filesystem tree which were not exported to the user.
- Some use cases require following links and other require avoiding it, we would want to have a configuration option whether to follow links or not.
Steps to reproduce
- Create a symlink to /etc and behold as the S3 bucket starts reading from /etc of the endpoint pod.
More information - Screenshots / Logs / Other output
@guymguym is this per system configuration or per exported bucket?
According to our discussion I think that per bucket since this is a security property that admins would set for the dataset.
lstat
: https://github.com/noobaa/noobaa-core/pull/6588