helper: _scan_dir() checks read permission on regular files