Browse Source

properly use smb permissions

remotes/origin/ldap-empty-hardening
Robin Appelman 10 years ago
parent
commit
8ab70b1231
  1. 22
      apps/files_external/lib/smb.php

22
apps/files_external/lib/smb.php

@ -349,6 +349,28 @@ class SMB extends Common {
}
}
public function isReadable($path) {
try {
$info = $this->getFileInfo($path);
return !$info->isHidden();
} catch (NotFoundException $e) {
return false;
} catch (ForbiddenException $e) {
return false;
}
}
public function isUpdatable($path) {
try {
$info = $this->getFileInfo($path);
return !$info->isHidden() && !$info->isReadOnly();
} catch (NotFoundException $e) {
return false;
} catch (ForbiddenException $e) {
return false;
}
}
/**
* check if smbclient is installed
*/

Loading…
Cancel
Save