-
Notifications
You must be signed in to change notification settings - Fork 52
DOCSP-38014 SSL Error Workaround #942
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 4 commits
c799da8
729fb00
6c802b8
6a8a4ea
57010e1
1edbb52
002abaf
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -77,6 +77,26 @@ in the following ways: | |
| see the :manual:`SRV Connection Format </reference/connection-string/#srv-connection-format>` | ||
| section in the Server manual. | ||
|
|
||
| .. note:: Workaround for an "unsafe legacy renegotiation disabled" error | ||
|
||
|
|
||
| The {+driver-short+} depends on OpenSSL by default. You may encounter an "unsafe | ||
lindseymoore marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| legacy renegotiation disabled" error in certain environments when using OpenSSL | ||
| versions 3.0 and later, due to outdated SSL proxies. If you encounter this error, | ||
lindseymoore marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| you can set the ``SSL_OP_LEGACY_SERVER_CONNECT`` option to resolve, as shown in | ||
lindseymoore marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| the following example: | ||
|
|
||
| .. code-block:: js | ||
| :emphasize-lines: 6 | ||
|
|
||
| import { MongoClient } from 'mongodb'; | ||
| import crypto from 'crypto'; | ||
|
|
||
| const client = new MongoClient("mongodb+srv://...", { | ||
| secureContext: { | ||
| secureOptions: crypto.constants.SSL_OP_LEGACY_SERVER_CONNECT | ||
| } | ||
| }); | ||
|
|
||
| In addition to the ``tls`` client option, the driver provides more | ||
| options to configure TLS on your connection. For **testing purposes**, | ||
| you can set the ``tlsAllowInvalidHostnames``, | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.