I have a local web application and its sending email over from EWS as below with app's user self Exchange Account information
ExchangeService _ExchangeService = new ExchangeService()
{
Credentials = new NetworkCredential("name.surname@domain.com", "********"),
Url = new Uri("https://xxx.domain.xxx/EWS/Exchange.asmx")
};
EmailMessage _EmailMessage = new EmailMessage(_ExchangeService);
_EmailMessage.Subject = "Subject Test";
_EmailMessage.Body = "Body Test";
_EmailMessage.ToRecipients.Add("name.surname@domain.com");
_EmailMessage.Save();
_EmailMessage.SendAndSaveCopy();
But I have to store user's exchange username and password values in database before sending email. I do not want to store user's password in database for security reasons. Is there any way to get user's login details from their local cache?