shahdsalama-4412 avatar image
0 Votes"
shahdsalama-4412 asked KaelYao-MSFT commented

Exchange on prem Authentication

I am working on creating a connector to exchange server on prem to retrieve personal calendar to view it in our system which is called "DoZen".

the exchange server has adfs configured, and "DoZen" users authenticate to the system using adfs

I want to figure out a way to authenticate to exchange without passing the credentials.. as the system that uses the connector does not store the credentials.

as a start I used this code

ExchangeService service = new ExchangeService()
Credentials = new WebCredentials("shahd@dz.local", "xxxxxx")
service.TraceEnabled = true;
service.TraceFlags = TraceFlags.All;
service.Url = new Uri("https://ServerName/ews/exchange.asmx");

it worked fine but this is not what I want, i do not have the credentials as mentioned before.

I removed the credentials and used
service.UseDefaultCredentials = true;
but it gave me unauthorized 401

· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @shahdsalama-4412

Since your question is more related to EWS development, I have added the tag office-exchange-server-dev to it.
Thanks for your understanding and hope you will get the answer soon.

0 Votes 0 ·

0 Answers