diff options
| author | JP Dillingham <jp@dillingham.me> | 2023-07-02 12:22:39 -0500 |
|---|---|---|
| committer | JP Dillingham <jp@dillingham.me> | 2023-07-02 12:22:39 -0500 |
| commit | da070602c8db9ec39b447c34857f2a8434e9cdd0 (patch) | |
| tree | 990bf8ea388ca59323f567585d457061848a6578 /src/slskd/Files/IFileService.cs | |
| parent | 94712ee9915cd46212b589e283a211545ec1141e (diff) | |
| download | slskd-da070602c8db9ec39b447c34857f2a8434e9cdd0.tar.gz | |
add tests to ensure only desirable paths can be accessed
Diffstat (limited to 'src/slskd/Files/IFileService.cs')
| -rw-r--r-- | src/slskd/Files/IFileService.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/slskd/Files/IFileService.cs b/src/slskd/Files/IFileService.cs index 63b5f1a3..89d4ce76 100644 --- a/src/slskd/Files/IFileService.cs +++ b/src/slskd/Files/IFileService.cs @@ -43,7 +43,7 @@ namespace slskd.Files /// Thrown if any of the directories is an exact match for an application-controlled directory. /// </exception> /// <exception cref="NotFoundException">Thrown if a specified directory does not exist.</exception> - /// <exception cref="SecurityException">Thrown if a specified directory is restricted.</exception> + /// <exception cref="UnauthorizedException">Thrown if a specified directory is restricted.</exception> Task<Dictionary<string, OneOf<bool, Exception>>> DeleteDirectoriesAsync(params string[] directories); /// <summary> @@ -57,7 +57,7 @@ namespace slskd.Files /// <returns>The operation context.</returns> /// <exception cref="ArgumentException">Thrown if any of the specified files have a relative path.</exception> /// <exception cref="NotFoundException">Thrown if a specified file does not exist.</exception> - /// <exception cref="SecurityException">Thrown if a specified file is restricted.</exception> + /// <exception cref="UnauthorizedException">Thrown if a specified file is restricted.</exception> Task<Dictionary<string, OneOf<bool, Exception>>> DeleteFilesAsync(params string[] files); /// <summary> @@ -68,7 +68,7 @@ namespace slskd.Files /// <returns>The list of found contents.</returns> /// <exception cref="ArgumentException">Thrown if the specified directory has a relative path.</exception> /// <exception cref="NotFoundException">Thrown if the specified directory does not exist.</exception> - /// <exception cref="SecurityException">Thrown if the specified root directory is restricted.</exception> + /// <exception cref="UnauthorizedException">Thrown if the specified root directory is restricted.</exception> Task<FilesystemDirectory> ListContentsAsync(string directory, EnumerationOptions enumerationOptions = null); } }
\ No newline at end of file |
