1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-02 16:42:50 -05:00

check user access permissions on collections edit

This commit is contained in:
Kyle Spearrin
2018-08-23 23:04:44 -04:00
parent 68c349f72f
commit 0816c609db
2 changed files with 4 additions and 1 deletions

View File

@ -478,6 +478,10 @@ namespace Bit.Core.Services
}
else
{
if(!(await UserCanEditAsync(cipher, savingUserId)))
{
throw new BadRequestException("You do not have permissions to edit this.");
}
await _collectionCipherRepository.UpdateCollectionsAsync(cipher.Id, savingUserId, collectionIds);
}