Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding single members to collection below Admin level does not work #2924

Closed
1 task done
Tracked by #2480
CMALG opened this issue May 11, 2023 · 2 comments
Closed
1 task done
Tracked by #2480

Adding single members to collection below Admin level does not work #2924

CMALG opened this issue May 11, 2023 · 2 comments
Labels
bug bw-unified-deploy An Issue related to Bitwarden unified deployment

Comments

@CMALG
Copy link

CMALG commented May 11, 2023

Steps To Reproduce

  1. Go to 'Organizations
  2. Go to 'Vault'
  3. Go to 'Collections'
  4. Click on '....'
  5. Click on 'Access'
  6. under Select groups and members select some members
  7. save

Expected Result

Users are added to the collection

Actual Result

Anyone you picked belov Admin level permisson just vanishes / Admin and above will work
Same issue applies if someone with manager level permission creates a collection and tries to add someone

Screenshots or Videos

No response

Additional Context

No response

Githash Version

"8d9ca424-dirty"

Environment Details

AWS K8s

Database Image

AWS Aurora

Issue-Link

#2480

Issue Tracking Info

  • I understand that work is tracked outside of Github. A PR will be linked to this issue should one be opened to address it, but Bitwarden doesn't use fields like "assigned", "milestone", or "project" to track progress.
@CMALG CMALG added bug bw-unified-deploy An Issue related to Bitwarden unified deployment labels May 11, 2023
@davidgvg
Copy link

Can confirm this on the following configuration:
Release branch: dev (update today 11.05.2023)
Docker: 23.0.1, build a5ee5b1
OS: Ubuntu 22.04.1 LTS

If I try to add permission via Vaults -> Collections -> 3dots on collection -> Access add a User and save no error is thrown but the user does not show up when opening the access view again.

I found that if I try to add a user to a collection via 'Members -> 3dots on user -> collections' add a collection and save an error is thrown.

In firefox debug console I get an internal server error for
PUT https://my-domain.com/api/organizations/12345678-1234-1234-1234-123456789012/users/12345678-1234-1234-1234-123456789012
(obfuscated the guids but made sure to have the same length)
and an Async submit exception: [object Object]

in api.log I see the following trace

2023-05-11 09:46:25.674 +00:00 [ERR] Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).
System.FormatException: Guid should contain 32 digits with 4 dashes (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).
   at System.Guid.GuidResult.SetFailure(Boolean overflow, String failureMessageID)
   at System.Guid.TryParseExactD(ReadOnlySpan`1 guidString, GuidResult& result)
   at System.Guid.TryParseGuid(ReadOnlySpan`1 guidString, GuidResult& result)
   at System.Guid..ctor(String g)
   at Bit.Api.Models.Request.SelectionReadOnlyRequestModel.ToSelectionReadOnly() in /source/src/Api/Models/Request/SelectionReadOnlyRequestModel.cs:line 15
   at Bit.Api.Controllers.OrganizationUsersController.<>c.<Put>b__21_0(SelectionReadOnlyRequestModel c) in /source/src/Api/Controllers/OrganizationUsersController.cs:line 284
   at System.Linq.Enumerable.SelectListIterator`2.MoveNext()
   at Bit.Infrastructure.EntityFramework.Repositories.OrganizationUserRepository.ReplaceAsync(OrganizationUser obj, IEnumerable`1 requestedCollections) in /source/src/Infrastructure.EntityFramework/Repositories/OrganizationUserRepository.cs:line 431
   at Bit.Core.Services.OrganizationService.SaveUserAsync(OrganizationUser user, Nullable`1 savingUserId, IEnumerable`1 collections, IEnumerable`1 groups) in /source/src/Core/Services/Implementations/OrganizationService.cs:line 1552
   at Bit.Api.Controllers.OrganizationUsersController.Put(String orgId, String id, OrganizationUserUpdateRequestModel model) in /source/src/Api/Controllers/OrganizationUsersController.cs:line 283
   at lambda_method1352(Closure , Object )
   at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.AwaitableResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Logged|12_1(ControllerActionInvoker invoker)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Rethrow(ActionExecutedContextSealed context)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeInnerFilterAsync>g__Awaited|13_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextExceptionFilterAsync>g__Awaited|26_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)

Creating permissions via Groups -> new group and assigning members and collections there seems to work.

Hope that helps.

@NovaSilentium
Copy link

Hi there!

Thank you for your report, it seems like it is a duplicate of this one [https://github.com/bitwarden/clients/issues/5328}.

If you wish to add any further information/screenshots/recordings etc., please feel free to do so at any time in there - our engineering team will be happy to review these.
This issue will now be closed.
Thanks!

@NovaSilentium NovaSilentium closed this as not planned Won't fix, can't repro, duplicate, stale May 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug bw-unified-deploy An Issue related to Bitwarden unified deployment
Projects
None yet
Development

No branches or pull requests

3 participants