I'm trying to connect davmail to an Exchange 2016 server. The Exchange admin says they set up EWS, but I am unable to connect either davmail or Apple Mail to the EWS endpoint. I would like to know what methods exist to test the proper availability of EWS from the general internet so I can rule out problems with davmail and Apple Mail, and have some confidence in claiming there's something wrong on the Exchange side. I know nothing about Windows administration, and they do it professionally, so I need to have something to show.
Here's what I'm seeing:
In Apple Mail, when setting up a new account, selecting "Exchange" an supplying email address and password, I get "unable to verify account name or password". I have verified the email / password combo works using Outlook Web Access on the same Exchange server. Supplying an explicit "External URL" to Apple Mail does not help.
When connecting to davmail using IMAP, I see "Authentication failed: invalid user or password" in davmail's logs.
I also tried curl, but it's not getting me anywhere either:
simon$ curl -v -u "<username>:<password>" <EWS endpoint URL>
* Trying <IP>...
* Connected to <host> (<ip>) port 443 (#0)
* TLS 1.2 connection using TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
* Server certificate: *.domain
* Server certificate: thawte DV SSL SHA256 CA
* Server certificate: thawte Primary Root CA - G3
* Server auth using Basic with user '<username>'
> GET /EWS/Exchange.asmx HTTP/1.1
> Host: <host>
> Authorization: Basic <basic auth string>
> User-Agent: curl/7.43.0
> Accept: */*
>
< HTTP/1.1 401 Anonymous Request Disallowed
< Date: Fri, 29 Dec 2017 23:02:40 GMT
< Server: Apache
< request-id: d6fa4e8d-bbce-4de5-a097-753cda2e37e2
< X-WSSecurity-Enabled: True
< X-WSSecurity-For: None
< X-OAuth-Enabled: True
< WWW-Authenticate: Negotiate
< WWW-Authenticate: NTLM
< X-Powered-By: ASP.NET
< X-FEServer: COMPANYMX-01
< Content-Length: 0
< Set-Cookie: ClientId=<some id>; expires=Sat, 29-Dec-2018 23:02:40 GMT; path=/; HttpOnly
< Content-Type: application/x-asmx
<
* Connection #0 to host <host> left intact
I don't have access to a Windows machine, but I could borrow one if it helps.
Use the Remote Connectivity Analyzer.
Also note, if you are ever prompted for username or domain you should specify your full email address for username and leave domain blank.