@@ -71,7 +71,10 @@ to use Kerberos to authenticate.
71
71
this option to ``"SERVICE_NAME:<authentication service name>"``.
72
72
73
73
You can set these options in two ways: by passing arguments to the
74
- ``MongoClient`` constructor or through parameters in your connection string.
74
+ ``MongoClient`` constructor or through parameters in your connection
75
+ string.
76
+
77
+ .. include:: /includes/authentication/auth-properties-commas.rst
75
78
76
79
.. tabs::
77
80
@@ -170,6 +173,8 @@ To authenticate with SASL, set the ``authMechanism`` connection option to ``PLAI
170
173
You can set this option in two ways: by passing an argument to the
171
174
``MongoClient`` constructor or through a parameter in your connection string.
172
175
176
+ .. include:: /includes/authentication/auth-properties-commas.rst
177
+
173
178
.. tabs::
174
179
175
180
.. tab:: MongoClient
@@ -228,6 +233,8 @@ support.
228
233
You can configure OIDC for Azure IMDS in two ways: by passing arguments to the
229
234
``MongoClient`` constructor or through parameters in your connection string.
230
235
236
+ .. include:: /includes/authentication/auth-properties-commas.rst
237
+
231
238
.. tabs::
232
239
233
240
.. tab:: MongoClient
@@ -272,8 +279,8 @@ You can configure OIDC for Azure IMDS in two ways: by passing arguments to the
272
279
enterprise application, set this to the application ID of the service principal.
273
280
- ``authMechanism``: Set to ``MONGODB-OIDC``.
274
281
- ``authMechanismProperties``: Set to
275
- ``ENVIRONMENT:azure,TOKEN_RESOURCE:<percent-encoded audience>``.
276
- Replace the ``<percent-encoded audience>`` placeholder with the percent-encoded
282
+ ``ENVIRONMENT:azure,TOKEN_RESOURCE:<audience>``.
283
+ Replace the ``<audience>`` placeholder with the
277
284
value of the ``audience`` parameter configured on your MongoDB deployment.
278
285
279
286
The following code example shows how to set these options in your connection string:
@@ -301,6 +308,8 @@ support.
301
308
You can configure OIDC for GCP IMDS in two ways: by passing arguments to the
302
309
``MongoClient`` constructor or through parameters in your connection string.
303
310
311
+ .. include:: /includes/authentication/auth-properties-commas.rst
312
+
304
313
.. tabs::
305
314
306
315
.. tab:: MongoClient
@@ -337,8 +346,8 @@ You can configure OIDC for GCP IMDS in two ways: by passing arguments to the
337
346
338
347
- ``authMechanism``: Set to ``MONGODB-OIDC``.
339
348
- ``authMechanismProperties``: Set to
340
- ``ENVIRONMENT:gcp,TOKEN_RESOURCE:<percent-encoded audience>``.
341
- Replace the ``<percent-encoded audience>`` placeholder with the percent-encoded
349
+ ``ENVIRONMENT:gcp,TOKEN_RESOURCE:<audience>``.
350
+ Replace the ``<audience>`` placeholder with the
342
351
value of the ``audience`` parameter configured on your MongoDB deployment.
343
352
344
353
The following code example shows how to set these options in your connection string:
0 commit comments