[SERVER-77168] mongod crashes when restoring time series collection with auth enabled Created: 16/May/23  Updated: 29/Oct/23  Resolved: 08/Jun/23

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 7.1.0-rc0, 5.0.19, 7.0.0-rc6, 6.0.8

Type: Bug Priority: Major - P3
Reporter: Satyam Gupta Assignee: Sara Golemon
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: Text File mongod.log     File repro.sh    
Issue Links:
Backports
Problem/Incident
Assigned Teams:
Server Security
Backwards Compatibility: Fully Compatible
Backport Requested:
v7.0, v6.0, v5.0
Sprint: Security 2023-06-12
Participants:

 Description   

Hi team,

A user reached out to us on the Community Forums that their mongod is crashing when doing a mongostore against a time series collection. I tried to reproduce the issue on my end as well and found that the mongod indeed crashes with invariant failure and signal 6 under certain scenarios.

 

This will happen when:

  • auth is used and
  • mongorestore was called using a file parameter mongorestore --username xx --password xx <file>

And will not happen when:

  • auth is not used 
  • the file is not specified in mongorestore

 

Versions:

This will also happen on a mongod that is part of a replica set. This appears to affect MongoDB 6.0.1. I also tried with version 5.0.17 as well as 6.0.6 and it affects them too. mongorestore and mongodump versions were 100.6.0 (tried with 100.7.0 as well).

 

I'm attaching the code, mongorestore error, logs as well as the forum post of the user who reported the issue.

 

Kindly let me know if anything else is required from my end.



 Comments   
Comment by Githook User [ 22/Jun/23 ]

Author:

{'name': 'Sara Golemon', 'email': 'sara.golemon@mongodb.com', 'username': 'sgolemon'}

Message: SERVER-77168 uassert on invalid system.buckets namespace

(cherry picked from commit 712bd1c149a80afc640d821f592e02832e6c6007)
Branch: v5.0
https://github.com/mongodb/mongo/commit/75b3b24942dec1877602d294b91aa46f87abc4e2

Comment by Githook User [ 22/Jun/23 ]

Author:

{'name': 'Sara Golemon', 'email': 'sara.golemon@mongodb.com', 'username': 'sgolemon'}

Message: SERVER-77168 uassert on invalid system.buckets namespace

(cherry picked from commit 712bd1c149a80afc640d821f592e02832e6c6007)
Branch: v7.0
https://github.com/mongodb/mongo/commit/b0dc8ce2a3acafa0b350b4384c229e29899be75b

Comment by Githook User [ 22/Jun/23 ]

Author:

{'name': 'Sara Golemon', 'email': 'sara.golemon@mongodb.com', 'username': 'sgolemon'}

Message: SERVER-77168 uassert on invalid system.buckets namespace

(cherry picked from commit 712bd1c149a80afc640d821f592e02832e6c6007)
Branch: v6.0
https://github.com/mongodb/mongo/commit/7f888b70aff614d9db19189ef5cc33f916d588af

Comment by Githook User [ 08/Jun/23 ]

Author:

{'name': 'Sara Golemon', 'email': 'sara.golemon@mongodb.com', 'username': 'sgolemon'}

Message: SERVER-77168 uassert on invalid system.buckets namespace
Branch: master
https://github.com/mongodb/mongo/commit/712bd1c149a80afc640d821f592e02832e6c6007

Generated at Thu Feb 08 06:34:43 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.