5.13. File system access

SFTPPlus is a cross-platform software designed to provide native file system access. It handles native file system access on both Unix and Windows platforms. While running on a specific operating system, it provides the extra features provided by that operating system.

Names can contain ASCII characters or Unicode characters.

5.13.1. Unix and Linux

Folder / file names that contain only space characters are fully supported on Linux and Unix systems. Names containing leading or trailing spaces are preserved as is.

Unicode names should be encoded using UTF-8.

Other character encoding schemes are not supported yet.

Note

If you require to handle names using a character encoding scheme other than UTF-8, please contact us.

5.13.2. Windows

On Windows, leading and trailing spaces from file names are stripped by the operating system. Due to this, names with only space characters are converted into names with no characters, invalidating them.

Files having the read-only attribute set are removed, renamed, moved, copied without getting an access denied error. This is done in order to get the same behaviour as the one described on the Microsoft website

Warning

Read-only files can’t be modified, but they can be copied, moved, renamed, or deleted. It’s possible that moving, renaming, or deleting a read-only file can cause a program that relies on that file to stop working properly.

5.13.3. Privileged access to files and folders

When accounts are authenticated as operating systems accounts (local, domain, or remote), they will observe the same file system permissions as those defined in the local file system. This way, you can have multiple accounts accessing the same file or folder, each account having its own permissions.

For accounts authenticated as server application accounts, all accounts are mapped to the same OS account and they will have the same permissions.

5.13.4. Resumed transfers

Resuming unfinished transfers, either upload or download, is supported across available file transfer protocols as follows:

Protocol Download Upload
FTP/FTPS Yes Yes
SFTP Yes Yes
SCP No No
HTTP Yes No

Note

Our roadmap includes adding support for resuming transfers across all available protocols. In the case that resume support is not available for your preferred transfer protocol, please contact us.

5.13.5. Locked accounts

Lock access is specified by lock_in_home_folder in the account’s settings. It is enabled by default for SFTP Plus version 1.6 and onwards.

In locked accounts, the account is locked inside the home folder path and access to files and folders outside the home folder path will be denied.

Application accounts are always inside their home folder and will not have access to files outside the home folder.

Operating System accounts have further configuration options - 1) deny access to files and folders outside the home folder, and 2) inherit the account’s group configuration.

5.13.5.1. Locked to home folder

Scenario:If an account is locked and the home folder is set to /home/user1/, the user is locked inside the home folder. The home folder path is now the root folder visible to the client. When a client lists the folder contents of ‘/upload’, the request is mapped in accordance to the home folder. Therefore it is mapped to /home/user1/upload on the local file system.

5.13.5.2. Not locked to home folder

Scenario:If an account is not locked inside the home folder, a request to list the relative file path /upload/ folder will be mapped to the /upload folder on the local file system.

5.13.6. Absolute and relative path handling in locked accounts

You can use absolute or relative file paths when specifying a home folder to lock an account to.

Absolute and relative file paths when used in locked_in_home folder accounts differ to the paths used inside the configuration file as mentioned in the section on absolute and relative paths.

To avoid potentially creating ambiguous behaviour in setting lock access, opt to specify an absolute file path instead of a relative file path.

5.13.6.1. Locked to home folder - use of absolute file paths

Scenario:When a locked account specifies an absolute file path outside the home folder, they will not be able to access that folder. For example, an account with a home folder of /home/user1/ and states an absolute file path to navigate to /home/user2/upload will be unable to access the folder.

5.13.6.2. Locked to home folder - use of relative file paths

Scenario:When a client navigates to a folder via relative file path, like /upload/, they will be able to access that folder.

5.13.6.3. Not locked to home folder - use of absolute file paths

Scenario:When an account that is not locked to the home folder specifies an absolute file path to a destination outside that folder, it is able to access that folder. For example, if an account with a home folder of /home/user1 navigates to a file path outside its home folder to /home/user2/upload it will be able to access that folder. However, this is also dependent on the account having privileges on the OS to access that particular folder.

5.13.6.4. Not locked to home folder - use of relative file paths

Scenario:Similar to the scenario of a locked home folder account, when a user navigates to a folder via relative file paths, they will also be able to access that folder.