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

Make SAF, ROSAF and virtual directories searchable #347

Merged
merged 1 commit into from
Jun 8, 2024

Conversation

lmagyar
Copy link
Contributor

@lmagyar lmagyar commented May 26, 2024

Plain old FS gets this info from the real FS, and folders are executable=searchable (rwxrwxrwx).

In case of SAF and ROSAF: set isExecutable() true for folders.
In case of virtual: use the backing FS or be default true (for the / and the /fs, etc. folders).

Without executable bit set, the folders created by SSHFS on the client can't be selected as working directories. (eg. cd .../saf/Anything results in "Access denied")

Note: The ROSAF part is not tested.

@wolpi
Copy link
Owner

wolpi commented Jun 2, 2024

Oh yes, that makes sense.
I think the changes should rather be done on the non-ssh version of the classes:

  • SafFile
  • RoSafFile
  • VirtualFile

That way it would work for FTP, too.

@lmagyar
Copy link
Contributor Author

lmagyar commented Jun 2, 2024

Yeah, nice catch. :) I was so concentrated on the sftp... I will do it after dinner. :D

@lmagyar
Copy link
Contributor Author

lmagyar commented Jun 2, 2024

So, no change, because isExecutable() is only part of SshFile interface and not part of FtpFile interface (it seems that ftp doesn't use this info), and that's why I've put it into XxxSshFile.

@wolpi wolpi added this to the 7.2 milestone Jun 8, 2024
@wolpi wolpi merged commit acbc809 into wolpi:master Jun 8, 2024
1 check passed
@wolpi
Copy link
Owner

wolpi commented Jun 8, 2024

I still think this can be done in AbsractFile, moved it there.

Thanks!

@lmagyar lmagyar deleted the pr-fix-make-dirs-searchable branch June 8, 2024 11:38
lmagyar pushed a commit to lmagyar/prim-ftpd that referenced this pull request Jun 8, 2024
@wolpi
Copy link
Owner

wolpi commented Jun 9, 2024

last commit should have been assigned to #352

lmagyar pushed a commit to lmagyar/prim-ftpd that referenced this pull request Jun 9, 2024
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.

2 participants