[SERVER-11523] Roles with many duplicate linked roles assert, without nice error message Created: 01/Nov/13 Updated: 10/Dec/14 Resolved: 04/Nov/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Security |
| Affects Version/s: | 2.5.4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Samantha Ritter (Inactive) | Assignee: | Unassigned |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | 26qa | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
||||||||||||
| Issue Links: |
|
||||||||||||
| Operating System: | ALL | ||||||||||||
| Participants: | |||||||||||||
| Description |
|
> var duplicateRoles = [ "a", "a", "a", "a", ... "a" ]; ); > db.runCommand( { grantRolesToRole: "empty", privileges: [], roles: duplicateRoles }); In both cases, when the duplicateRoles array becomes very large (>16mb) we get an error and a stack trace from mongo: Assertion: 10334:BSONObj size: 19888945 (0x12F7B31) is invalid. Instead, I would expect one of two things: a graceful failure with a nice error message, or a successful insert, since the linked roles will (in theory) be de-duped before the parent role is stored in the db. |
| Comments |
| Comment by Daniel Pasette (Inactive) [ 04/Nov/13 ] |
|
duplicate: |
| Comment by Samantha Ritter (Inactive) [ 01/Nov/13 ] |
|
So, the stack trace is basically identical to the one in |
| Comment by Spencer Brody (Inactive) [ 01/Nov/13 ] |
|
I'm pretty sure all of these are actually just |
| Comment by Samantha Ritter (Inactive) [ 01/Nov/13 ] |
|
The same thing affects duplicate actions listed within a single privilege. When trying to add the privilege to a role, assert and stack trace. |