File tree Expand file tree Collapse file tree 1 file changed +25
-1
lines changed
driver-core/src/test/resources/auth Expand file tree Collapse file tree 1 file changed +25
-1
lines changed Original file line number Diff line number Diff line change 216
216
"mechanism_properties" : null
217
217
}
218
218
},
219
+ {
220
+ "description" : " should recognize the mechanism with no username when auth source is explicitly specified (MONGODB-X509)" ,
221
+ "uri" : " mongodb://localhost/?authMechanism=MONGODB-X509&authSource=$external" ,
222
+ "valid" : true ,
223
+ "credential" : {
224
+ "username" : null ,
225
+ "password" : null ,
226
+ "source" : " $external" ,
227
+ "mechanism" : " MONGODB-X509" ,
228
+ "mechanism_properties" : null
229
+ }
230
+ },
219
231
{
220
232
"description" : " should throw an exception if supplied a password (MONGODB-X509)" ,
221
233
"uri" : " mongodb://user:password@localhost/?authMechanism=MONGODB-X509" ,
362
374
"credential" : null
363
375
},
364
376
{
365
- "description" : " authSource without username doesn't create credential" ,
377
+ "description" : " authSource without username doesn't create credential (default mechanism) " ,
366
378
"uri" : " mongodb://localhost/?authSource=foo" ,
367
379
"valid" : true ,
368
380
"credential" : null
389
401
"mechanism_properties" : null
390
402
}
391
403
},
404
+ {
405
+ "description" : " should recognise the mechanism when auth source is explicitly specified (MONGODB-AWS)" ,
406
+ "uri" : " mongodb://localhost/?authMechanism=MONGODB-AWS&authSource=$external" ,
407
+ "valid" : true ,
408
+ "credential" : {
409
+ "username" : null ,
410
+ "password" : null ,
411
+ "source" : " $external" ,
412
+ "mechanism" : " MONGODB-AWS" ,
413
+ "mechanism_properties" : null
414
+ }
415
+ },
392
416
{
393
417
"description" : " should throw an exception if username and no password (MONGODB-AWS)" ,
394
418
"uri" : " mongodb://user@localhost/?authMechanism=MONGODB-AWS" ,
You can’t perform that action at this time.
0 commit comments