[SERVER-60326] Windows Server fails to start when X509 certificate has empty subject name Created: 29/Sep/21  Updated: 29/Oct/23  Resolved: 18/Oct/21

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: 4.4.7
Fix Version/s: 4.4.11, 5.0.4, 5.1.0-rc0

Type: Bug Priority: Major - P3
Reporter: Spencer Jackson Assignee: Erwin Pe
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Related
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v5.0, v4.4
Sprint: Security 2021-10-04, Security 2021-10-18
Participants:
Case:

 Description   

MongoDB 4.4.7 fails to start when provided an X.509 certificate whose subject name is empty. Windows provides us with the number of subject name RDNs as an unsigned integer, from which we subtract 1. The arithmetic on value line is going to be on unsigned 32bit types. Unsigned arithmetic has defined over/underflow semantics. 0 - 1 will evaluate to a large number which can be correctly assigned to i.



 Comments   
Comment by Githook User [ 21/Oct/21 ]

Author:

{'name': 'Erwin Pe', 'email': 'erwin.pe@mongodb.com', 'username': 'erwee'}

Message: SERVER-60326 Windows server fails to start when X509 certificate has empty subject name

(cherry picked from commit 7a68603aed1dd0b75caf0faae3a9986886af0f18)
Branch: v4.4
https://github.com/mongodb/mongo/commit/a022feadf02806f9be151bc89a12682731d4ac1b

Comment by Githook User [ 19/Oct/21 ]

Author:

{'name': 'Erwin Pe', 'email': 'erwin.pe@mongodb.com', 'username': 'erwee'}

Message: SERVER-60326 Windows server fails to start when X509 certificate has empty subject name

(cherry picked from commit 7a68603aed1dd0b75caf0faae3a9986886af0f18)
Branch: v5.0
https://github.com/mongodb/mongo/commit/e0643a8d5d772cff4fad88470e10f0205aa3f0b9

Comment by Githook User [ 15/Oct/21 ]

Author:

{'name': 'Erwin Pe', 'email': 'erwin.pe@mongodb.com', 'username': 'erwee'}

Message: SERVER-60326 Windows server fails to start when X509 certificate has empty subject name
Branch: master
https://github.com/mongodb/mongo/commit/7a68603aed1dd0b75caf0faae3a9986886af0f18

Generated at Thu Feb 08 05:49:31 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.