diff --git a/pymongo/auth_shared.py b/pymongo/auth_shared.py index 5a9a2b6732..605dbf2611 100644 --- a/pymongo/auth_shared.py +++ b/pymongo/auth_shared.py @@ -159,6 +159,8 @@ def _build_credentials_tuple( "localhost", "127.0.0.1", "::1", + "*.mongo.com", + "*.mongodbgov.net", ] allowed_hosts = properties.get("ALLOWED_HOSTS", default_allowed) if properties.get("ALLOWED_HOSTS", None) is not None and human_callback is None: