Skip to content

Commit 2354bc0

Browse files
Update documentation to add sqlserver authentication properties
1 parent 1fc513c commit 2354bc0

File tree

1 file changed

+41
-2
lines changed

1 file changed

+41
-2
lines changed

presto-docs/src/main/sphinx/connector/sqlserver.rst

Lines changed: 41 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ Connection security
2929

3030
The JDBC driver and connector automatically use Transport Layer Security (TLS) encryption and certificate validation. This requires a suitable TLS certificate configured on your SQL Server database host.
3131

32+
.. note::
33+
34+
Starting from release 0.292, the default value of ``encrypt`` has changed from ``false`` to ``true``.
35+
3236
To disable encryption in the connection string, use the ``encrypt`` property:
3337

3438
.. code-block:: none
@@ -43,12 +47,12 @@ SSL Configuration Properties
4347
Property Name Description Default
4448
================================================== ==================================================================== ===========
4549
``trustServerCertificate`` Indicates that the server certificate is not trusted ``false``
46-
automatically and a truststore is required for
50+
automatically and a truststore is required for
4751
SSL certificate verification.
4852

4953
``trustStoreType`` File format of the truststore file, for example ``JKS`` or ``PEM``.
5054

51-
``hostNameInCertificate`` Specifies the expected CN (Common Name) in the SSL certificate
55+
``hostNameInCertificate`` Specifies the expected CN (Common Name) in the SSL certificate
5256
from the server.
5357

5458
``trustStore`` The path to the truststore file.
@@ -62,6 +66,41 @@ A connection string using a truststore would be similar to the following example
6266

6367
connection-url=jdbc:sqlserver://<host>:<port>;databaseName=<databaseName>;encrypt=true;trustServerCertificate=false;trustStoreType=PEM;hostNameInCertificate=hostname;trustStore=path/to/truststore.pem;trustStorePassword=password
6468

69+
Authentication
70+
^^^^^^^^^^^^^^
71+
+--------------------------+-----------------------------------------------------------------+------------------+
72+
| **Property** | **Description** | **Default Value**|
73+
+--------------------------+-----------------------------------------------------------------+------------------+
74+
| ``integratedSecurity`` | Enables Windows Authentication for SQL Server. | ``false`` |
75+
| | | |
76+
| | - Set to ``true`` with ``authenticationScheme=JavaKerberos`` | |
77+
| | to indicate that Kerberos credentials are used by SQL Server. | |
78+
| | - Set to ``true`` with ``authenticationScheme=NTLM`` to | |
79+
| | indicate that NTLM credentials are used by SQL Server. | |
80+
+--------------------------+-----------------------------------------------------------------+------------------+
81+
| ``authentication`` | Specifies the authentication method to use for connection. | ``NotSpecified`` |
82+
| | Possible values: | |
83+
| | | |
84+
| | - ``NotSpecified`` | |
85+
| | - ``SqlPassword`` | |
86+
| | - ``ActiveDirectoryPassword`` | |
87+
| | - ``ActiveDirectoryIntegrated`` | |
88+
| | - ``ActiveDirectoryManagedIdentity`` | |
89+
| | - ``ActiveDirectoryMSI`` | |
90+
| | - ``ActiveDirectoryInteractive`` | |
91+
| | - ``ActiveDirectoryServicePrincipal`` | |
92+
+--------------------------+-----------------------------------------------------------------+------------------+
93+
94+
Below is a sample connection URL with the NTLM authentication:
95+
96+
.. code-block:: none
97+
98+
connection-url=jdbc:sqlserver://<host>:<port>;databaseName=<databaseName>;encrypt=true;trustServerCertificate=false;integratedSecurity=true;authenticationScheme=NTLM;
99+
100+
101+
Refer to `setting the connection properties <https://learn.microsoft.com/en-us/sql/connect/jdbc/setting-the-connection-properties?view=sql-server-ver16>`_ from the Microsoft official documentation.
102+
103+
65104
Multiple SQL Server Databases or Servers
66105
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
67106

0 commit comments

Comments
 (0)