...
BugZero found this defect 2751 days ago.
If auth fails via an exception, the following code will leak a DBClientBase object: https://github.com/mongodb/mongo/blob/v3.4/src/mongo/client/mongo_uri_connect.cpp#L180-L188
xgen-internal-githook commented on Wed, 24 May 2017 19:41:19 +0000: Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'} Message: SERVER-28996 SERVER-28996 Fix memory leak in MongoURI if auth fails (cherry picked from commit cb893ef71d66bea22dd79553bd0080549f794c16) Branch: v3.2 https://github.com/mongodb/mongo/commit/24353098bf91d2914ade05b305f3edc0cbe30c7c xgen-internal-githook commented on Wed, 24 May 2017 19:41:18 +0000: Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'} Message: SERVER-28996 SERVER-28996 Fix memory leak in MongoURI if auth fails (cherry picked from commit cb893ef71d66bea22dd79553bd0080549f794c16) Branch: v3.2 https://github.com/mongodb/mongo/commit/24353098bf91d2914ade05b305f3edc0cbe30c7c xgen-internal-githook commented on Wed, 17 May 2017 20:26:33 +0000: Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'} Message: SERVER-28996 SERVER-28996 Fix memory leak in MongoURI if auth fails (cherry picked from commit cb893ef71d66bea22dd79553bd0080549f794c16) Branch: v3.4 https://github.com/mongodb/mongo/commit/ae06aa4ec7137bb1e2688838d29dd778338a6393 xgen-internal-githook commented on Wed, 17 May 2017 20:26:32 +0000: Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'} Message: SERVER-28996 SERVER-28996 Fix memory leak in MongoURI if auth fails (cherry picked from commit cb893ef71d66bea22dd79553bd0080549f794c16) Branch: v3.4 https://github.com/mongodb/mongo/commit/ae06aa4ec7137bb1e2688838d29dd778338a6393 xgen-internal-githook commented on Mon, 1 May 2017 19:09:52 +0000: Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'} Message: SERVER-28996 SERVER-28996 Fix memory leak in MongoURI if auth fails Branch: master https://github.com/mongodb/mongo/commit/cb893ef71d66bea22dd79553bd0080549f794c16 xgen-internal-githook commented on Mon, 1 May 2017 19:09:51 +0000: Author: {u'username': u'jbreams', u'name': u'Jonathan Reams', u'email': u'jbreams@mongodb.com'} Message: SERVER-28996 SERVER-28996 Fix memory leak in MongoURI if auth fails Branch: master https://github.com/mongodb/mongo/commit/cb893ef71d66bea22dd79553bd0080549f794c16 acm commented on Thu, 27 Apr 2017 15:29:50 +0000: This issue also affects v3.4 and v3.2. The 3.0 branch is unaffected.