@@ -25,12 +25,12 @@ confirm identity and establish trust to ensure security.
2525The mechanisms that you can use with the latest version of MongoDB Community
2626Edition are as follows:
2727
28- * :ref:`Default <default-auth-mechanism>`
29- * :ref:`SCRAM-SHA-256 <scram-sha-256-auth-mechanism>`
30- * :ref:`SCRAM-SHA-1 <scram-sha-1-auth-mechanism>`
31- * :ref:`MONGODB-CR <mongodb-cr-auth-mechanism>`
32- * :ref:`MONGODB-AWS <mongodb-aws-auth-mechanism>`
33- * :ref:`X.509 <x509-auth-mechanism>`
28+ - :ref:`Default <default-auth-mechanism>`
29+ - :ref:`SCRAM-SHA-256 <scram-sha-256-auth-mechanism>`
30+ - :ref:`SCRAM-SHA-1 <scram-sha-1-auth-mechanism>`
31+ - :ref:`MONGODB-CR <mongodb-cr-auth-mechanism>`
32+ - :ref:`MONGODB-AWS <mongodb-aws-auth-mechanism>`
33+ - :ref:`X.509 <x509-auth-mechanism>`
3434
3535To authenticate using ``Kerberos`` or ``LDAP``, see the
3636:doc:`Enterprise Authentication Mechanisms guide </fundamentals/enterprise-auth>`.
@@ -65,13 +65,18 @@ which they advertise support.
6565The following code snippets show how to specify the authentication mechanism,
6666using the following placeholders:
6767
68- * ``username`` - your MongoDB username
69- * ``password`` - your MongoDB user's password
70- * ``hostname`` - network address of your MongoDB deployment, accessible by your client
71- * ``port`` - port number of your MongoDB deployment
72- * ``authenticationDb`` - MongoDB database that contains your user's
73- authentication data. If you omit this parameter, the driver uses the
74- default value ``admin``.
68+ - ``username``: your MongoDB username
69+ - ``password``: your MongoDB user's password
70+ - ``hostname``: network address of your MongoDB deployment that your
71+ client can access
72+ - ``port``: port number of your MongoDB deployment
73+ - ``authenticationDb``: MongoDB database that contains your user's
74+ authentication data
75+
76+ .. note::
77+
78+ If you omit the ``authenticationDb`` parameter, the driver uses the
79+ default ``admin`` database.
7580
7681Select the :guilabel:`Connection String` or the :guilabel:`MongoCredential`
7782tab below for instructions and sample code for specifying this authentication
@@ -123,13 +128,18 @@ algorithm, to authenticate your user.
123128The following code snippets show how to specify the authentication mechanism,
124129using the following placeholders:
125130
126- * ``username`` - your MongoDB username.
127- * ``password`` - your MongoDB user's password.
128- * ``hostname`` - network address of your MongoDB deployment, accessible by your client.
129- * ``port`` - port number of your MongoDB deployment.
130- * ``authenticationDb`` - MongoDB database that contains your user's
131- authentication data. If you omit this parameter, the driver uses the
132- default value ``admin``.
131+ - ``username``: your MongoDB username
132+ - ``password``: your MongoDB user's password
133+ - ``hostname``: network address of your MongoDB deployment that your
134+ client can access
135+ - ``port``: port number of your MongoDB deployment
136+ - ``authenticationDb``: MongoDB database that contains your user's
137+ authentication data
138+
139+ .. note::
140+
141+ If you omit the ``authenticationDb`` parameter, the driver uses the
142+ default ``admin`` database.
133143
134144Select the :guilabel:`Connection String` or the :guilabel:`MongoCredential`
135145tab below for instructions and sample code for specifying this authentication
@@ -175,13 +185,18 @@ your user.
175185The following code snippets show how to specify the authentication mechanism,
176186using the following placeholders:
177187
178- * ``username`` - your MongoDB username.
179- * ``password`` - your MongoDB user's password.
180- * ``hostname`` - network address of your MongoDB deployment, accessible by your client.
181- * ``port`` - port number of your MongoDB deployment.
182- * ``authenticationDb`` - MongoDB database that contains your user's
183- authentication data. If you omit this parameter, the driver uses the
184- default value ``admin``.
188+ - ``username``: your MongoDB username
189+ - ``password``: your MongoDB user's password
190+ - ``hostname``: network address of your MongoDB deployment that your
191+ client can access
192+ - ``port``: port number of your MongoDB deployment
193+ - ``authenticationDb``: MongoDB database that contains your user's
194+ authentication data
195+
196+ .. note::
197+
198+ If you omit the ``authenticationDb`` parameter, the driver uses the
199+ default ``admin`` database.
185200
186201Select the :guilabel:`Connection String` or the :guilabel:`MongoCredential`
187202tab below for instructions and sample code for specifying this authentication
@@ -254,12 +269,12 @@ provide your AWS IAM credentials in the next sections.
254269
255270These sections contain code examples that use the following placeholders:
256271
257- * ``awsKeyId`` - value of your AWS access key ID
258- * ``awsSecretKey`` - value of your AWS secret access key
259- * ``atlasUri`` - network address of your MongoDB Atlas deployment
260- * ``hostname`` - hostname of your MongoDB Atlas deployment
261- * ``port`` - port of your MongoDB Atlas deployment
262- * ``awsSessionToken`` - value of your AWS session token
272+ - ``awsKeyId``: value of your AWS access key ID
273+ - ``awsSecretKey``: value of your AWS secret access key
274+ - ``atlasUri``: network address of your MongoDB Atlas deployment
275+ - ``hostname``: hostname of your MongoDB Atlas deployment
276+ - ``port``: port of your MongoDB Atlas deployment
277+ - ``awsSessionToken``: value of your AWS session token
263278
264279.. _java-mongodb-aws-sdk:
265280
@@ -424,7 +439,6 @@ to the absolute path to this file, as shown in the following example:
424439
425440 export AWS_WEB_IDENTITY_TOKEN_FILE=<absolute path to file containing your OIDC token>
426441
427-
428442To authenticate by using **ECS container credentials**, set the ECS
429443endpoint relative URI in an environment variable by using ``bash`` or
430444a similar shell as shown in the following example:
@@ -433,9 +447,10 @@ a similar shell as shown in the following example:
433447
434448 export AWS_CONTAINER_CREDENTIALS_RELATIVE_URI=<your ECS endpoint>
435449
436- To authenticate using **EC2 container credentials**, make sure none of the
437- aforementioned environment variables are set. The driver obtains the
438- credentials from the default IPv4 EC2 instance metadata endpoint.
450+ To authenticate by using **EC2 container credentials**, make sure none of the
451+ environment variables mentioned in this section are set. The driver obtains the
452+ credentials from the default IPv4 EC2 instance metadata endpoint instead
453+ of from environment variables.
439454
440455.. _java-mongodb-aws-mongoclient-configuration:
441456
@@ -511,11 +526,16 @@ the subject name of the client certificate.
511526The following code snippets show how to specify the authentication mechanism,
512527using the following placeholders:
513528
514- * ``hostname`` - network address of your MongoDB deployment, accessible by your client.
515- * ``port`` - port number of your MongoDB deployment.
516- * ``authenticationDb`` - MongoDB database that contains your user's
517- authentication data. If you omit this parameter, the driver uses the
518- default value ``admin``.
529+ - ``hostname``: network address of your MongoDB deployment that your
530+ client can access
531+ - ``port``: port number of your MongoDB deployment
532+ - ``authenticationDb``: MongoDB database that contains your user's
533+ authentication data
534+
535+ .. note::
536+
537+ If you omit the ``authenticationDb`` parameter, the driver uses the
538+ default ``admin`` database.
519539
520540Select the :guilabel:`Connection String` or the :guilabel:`MongoCredential`
521541tab below for instructions and sample code for specifying this authentication
0 commit comments