diff options
| author | JP Dillingham <jp@dillingham.me> | 2026-10-23 14:54:37 -0500 |
|---|---|---|
| committer | JP Dillingham <jp@dillingham.me> | 2026-10-23 14:54:37 -0500 |
| commit | d4447890e5fad1cd942affe051c9479385667465 (patch) | |
| tree | d0637d2edeece33d9a146d73630a2995fe974792 /src/slskd/Shares/API/Controllers | |
| parent | 3c34fcc3bde265d8c98792a8b7d00c61c4bd06e6 (diff) | |
| download | slskd-d4447890e5fad1cd942affe051c9479385667465.tar.gz | |
perms for more controllers, use paranoid check of api keys
Diffstat (limited to 'src/slskd/Shares/API/Controllers')
| -rw-r--r-- | src/slskd/Shares/API/Controllers/SharesController.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/slskd/Shares/API/Controllers/SharesController.cs b/src/slskd/Shares/API/Controllers/SharesController.cs index 76ec4643..64d703bd 100644 --- a/src/slskd/Shares/API/Controllers/SharesController.cs +++ b/src/slskd/Shares/API/Controllers/SharesController.cs @@ -148,7 +148,7 @@ namespace slskd.Shares.API /// <response code="409">A share scan is already in progress.</response> [HttpPut] [Route("")] - [Authorize(Policy = AuthPolicy.Any)] + [Authorize(Policy = AuthPolicy.Any, Roles = AuthRole.ReadWriteOrAdministrator)] [ProducesResponseType(204)] [ProducesResponseType(409)] public IActionResult RescanSharesAsync() @@ -173,7 +173,7 @@ namespace slskd.Shares.API /// <response code="409">A share scan was not in progress.</response> [HttpDelete] [Route("")] - [Authorize(Policy = AuthPolicy.Any)] + [Authorize(Policy = AuthPolicy.Any, Roles = AuthRole.ReadWriteOrAdministrator)] [ProducesResponseType(204)] [ProducesResponseType(404)] public IActionResult CancelShareScan() |
