Velvet Star Monitor

Standout celebrity highlights with iconic style.

news

IP ranges for login.microsoftonline.com and graph.microsoft.com endpoints

Writer Sophia Terry

I whìtelisted below URLs to connect Office 365 within my organization server, but still cannot connect to Microsoft Graph API. Later I found that login.microsoftonline.com is unable to establish a socket connection.

Therefore my network guys suggested to collect all IP ranges for below whitelist URLs. Any comment is this the right way to do this, and if yes, from where I can find the IP ranges for below URLs.

Whitelisted URLs:

  • login.microsoftonline.com
  • graph.microsoft.com

Python code:

import msal
app = msal.ConfidentialClientApplication( config['client_id'], authority = "", client_credential = config['secret'], proxies = {"http":""}
)
socket.connect(host,port)
#host = login.microsoftonline.com
#port = 443

1 Answer

Microsoft has published a large list of endpoints and IP ranges used for their global services, which you can find at . You'll be primarily interested in the Microsoft 365 Common and Office Online section.

Your authority value should also be

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy