mguessan / davmail

DavMail POP/IMAP/SMTP/Caldav/Carddav/LDAP Exchange and Office 365 Gateway - Synced with main subversion repository at
http://davmail.sourceforge.net
GNU General Public License v2.0
558 stars 82 forks source link

Could you please add support for Office 365 China version #341

Open FlashIvano opened 3 months ago

FlashIvano commented 3 months ago

The Office 365 operated by 21Vianet version of Office 365 is specific to China.

Thanks.

Clients Settings

POP:
  服务器名称: 
    Outlook Global: outlook.office365.com
    Outlook 21Vianet: partner.outlook.cn
  端口: 995
  加密方法: SSL

IMAP:
  服务器名称:
    Outlook Global: outlook.office365.com
    Outlook 21Vianet: partner.outlook.cn
  端口: 993
  加密方法: SSL

SMTP:
  服务器名称:
    Outlook Global: smtp.office365.com
    Outlook 21Vianet: smtp.partner.outlook.cn
  端口: 587
  加密方法: StartTLS

OAUTH Settings

Outlook Global: 
  ews_url: https://outlook.office365.com/EWS/Exchange.asmx
  permission_url: https://login.microsoftonline.com/common/oauth2/v2.0/authorize
  token_url: https://login.microsoftonline.com/common/oauth2/v2.0/token
Outlook 21Vianet:
  ews_url: https://partner.outlook.cn/EWS/Exchange.asmx
  permission_url: https://login.chinacloudapi.cn/common/oauth2/v2.0/authorize
  token_url: https://login.chinacloudapi.cn/common/oauth2/v2.0/token
mguessan commented 3 months ago

Sounds like the tld setting introduced for .us tenants will not be enough to cover this.

The good news is that we already moved O365 url value to Settings class so this should not be too difficult.