Exchange IP

Mar 20, 2012 at 7:18 PM

I am unable to get the Exchange IP's configuration set right. It seems I always get an SSL cert error is this a configuration problem on the exchange side of things? I am not well versed in exchange.

Mar 20, 2012 at 8:40 PM

When using a Autodiscovery testing app it seems to work fine but when using the IP this is the error i'm receiving from the connection:

The request failed. The remote server returned an error: (401) Unauthorized.

Exception: ServiceRequestException
Target site: ServiceRequestBase.ValidateAndEmitRequest

Stack trace:
   at Microsoft.Exchange.WebServices.Data.ServiceRequestBase.ValidateAndEmitRequest(HttpWebRequest& request)
   at Microsoft.Exchange.WebServices.Data.SimpleServiceRequestBase.InternalExecute()
   at Microsoft.Exchange.WebServices.Data.MultiResponseServiceRequest`1.Execute()
   at Microsoft.Exchange.WebServices.Data.ExchangeService.InternalFindFolders(IEnumerable`1 parentFolderIds, SearchFilter searchFilter, FolderView view, ServiceErrorHandling errorHandlingMode)
   at Microsoft.Exchange.WebServices.Data.ExchangeService.FindFolders(FolderId parentFolderId, SearchFilter searchFilter, FolderView view)
   at Microsoft.Exchange.WebServices.Data.ExchangeService.FindFolders(WellKnownFolderName parentFolderName, SearchFilter searchFilter, FolderView view)
   at ExchangeMail.ReadMail.Execute(IActivityRequest request, IActivityResponse response)

Coordinator
Mar 20, 2012 at 8:44 PM

Hey,

I think I have addressed this issue in a new version, I am just finishing up some testing. I will put it up on Codeplex if everything tests out well tomorrow J

From: ryandurbin [email removed]
Sent: Tuesday, March 20, 2012 3:41 PM
To: Ryan Andorfer
Subject: Re: Exchange IP [scorch:349373]

From: ryandurbin

When using a Autodiscovery testing app it seems to work fine but when using the IP this is the error i'm receiving from the connection:

The request failed. The remote server returned an error: (401) Unauthorized.

Exception: ServiceRequestException
Target site: ServiceRequestBase.ValidateAndEmitRequest

Stack trace:
at Microsoft.Exchange.WebServices.Data.ServiceRequestBase.ValidateAndEmitRequest(HttpWebRequest& request)
at Microsoft.Exchange.WebServices.Data.SimpleServiceRequestBase.InternalExecute()
at Microsoft.Exchange.WebServices.Data.MultiResponseServiceRequest`1.Execute()
at Microsoft.Exchange.WebServices.Data.ExchangeService.InternalFindFolders(IEnumerable`1 parentFolderIds, SearchFilter searchFilter, FolderView view, ServiceErrorHandling errorHandlingMode)
at Microsoft.Exchange.WebServices.Data.ExchangeService.FindFolders(FolderId parentFolderId, SearchFilter searchFilter, FolderView view)
at Microsoft.Exchange.WebServices.Data.ExchangeService.FindFolders(WellKnownFolderName parentFolderName, SearchFilter searchFilter, FolderView view)
at ExchangeMail.ReadMail.Execute(IActivityRequest request, IActivityResponse response)

Mar 20, 2012 at 8:47 PM

Thanks! I'll wait on the new version then.

Apr 11, 2012 at 1:34 PM

I seem to be having similar issues with the SCORCH DEV - Exchange Mail v2.0 when it is set to autodiscover for the ServiceURL.  If I change it to the FQDN for the mail server it fails much quicker but with a different error.  I'm not sure if this is an Exchange issue or issue with the IP configuration?  My cofiiguration of of the IP is as follows:

Type: Exchange Mailbox Settings

Username: <Service account name for SCORCH>

Password: <password for the above account>

Domain: <domain FQDN>

ServiceURL: Autodiscover

--------------------------------------------------------Error-------------------------------------------------------

The Autodiscover service couldn't be located.

Exception: AutodiscoverLocalException
Target site: AutodiscoverService.InternalGetLegacyUserSettings

Stack trace:
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.InternalGetLegacyUserSettings[TSettings](String emailAddress, List`1 redirectionEmailAddresses, Int32& currentHop)
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.GetLegacyUserSettings[TSettings](String emailAddress)
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.InternalGetLegacyUserSettings(String emailAddress, List`1 requestedSettings)
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.GetUserSettings(String userSmtpAddress, UserSettingName[] userSettingNames)
   at Microsoft.Exchange.WebServices.Data.ExchangeService.GetAutodiscoverUrl(String emailAddress, ExchangeVersion requestedServerVersion, AutodiscoverRedirectionUrlValidationCallback validateRedirectionUrlCallback)
   at Microsoft.Exchange.WebServices.Data.ExchangeService.AutodiscoverUrl(String emailAddress, AutodiscoverRedirectionUrlValidationCallback validateRedirectionUrlCallback)
   at Microsoft.Exchange.WebServices.Data.ExchangeService.AutodiscoverUrl(String emailAddress)
   at ExchangeMail.SendEmail.Execute(IActivityRequest request, IActivityResponse response)

Coordinator
Apr 11, 2012 at 1:55 PM

That error would seem to indicate that autodiscover for exchange is not working from the segment that has your orchestrator environment.  You can troubleshoot the exchange configuration (http://social.technet.microsoft.com/Forums/en-US/exchange2010/thread/5617c82f-b0c3-4591-8a40-4fc590091ed9 may help specifically try running https://www.testexchangeconnectivity.com/ from an action server) or switch from autodiscover to a hard coded service url of the form https://computername.domain.contoso.com/EWS/Exchange.asmx note this is a hardcoded value so if your exchange environment changes you would need to update this configuration to reflect (this is the reason we default to autodiscover).

 

The error ryan durbin brought up above was due to improper authorization against the webservice and has been addressed :-).  If you would like any more assistance please, let me know!

Apr 11, 2012 at 2:55 PM

Ryan,

Thanks for the tips. I will check into what you suggest and will get back with you if I’m still having issues. I’m not an Exchange guy so I didn’t want to go poking around grasping at straws

Thanks,

Erik

From: randorfer [email removed]
Sent: Wednesday, April 11, 2012 9:56 AM
To: erikmuns@hotmail.com
Subject: Re: Exchange IP [scorch:349373]

From: randorfer

That error would seem to indicate that autodiscover for orchestrator exchange is not working from the segment that has your environment. You can troubleshoot the exchange configuration (http://social.technet.microsoft.com/Forums/en-US/exchange2010/thread/5617c82f-b0c3-4591-8a40-4fc590091ed9 may help specifically try running https://www.testexchangeconnectivity.com/ from an action server) or switch from autodiscover to a hard coded service url of the form https://computername.domain.contoso.com/EWS/Exchange.asmx note this is a hardcoded value so if your exchange environment changes you would need to update this configuration to reflect (this is the reason we default to autodiscover).

The error ryan durbin brought up above was due to improper authorization against the webservice and has been addressed :-). If you would like any more assistance please, let me know!

Coordinator
Apr 11, 2012 at 2:59 PM

Sounds good, let me know if you need any more

Coordinator
Apr 11, 2012 at 3:03 PM

By the way, the exchange machine that hosts the webservice usually is your Exchange CAS Server

Apr 12, 2012 at 7:47 PM

Ryan,

The mail issue turned out to be an exchange issue with not have a public cert.

I do have one further question about the Exchange IP you developed. Is the a way to format the text of the email message? More specifically I’m trying to keep all of the message body from being run together and insert carriage returns for readability.

I’ve tried all of the usual suspects: \n, `r`n, chr(13), chr(10) as well as putting quotes around the entire message body without any luck.

Any insight is appreciated.

Erik

From: randorfer [email removed]
Sent: Wednesday, April 11, 2012 11:03 AM
To: erikmuns@hotmail.com
Subject: Re: Exchange IP [scorch:349373]

From: randorfer

By the way, the exchange machine that hosts the webservice usually is your Exchange CAS Server

Apr 12, 2012 at 8:19 PM
erikmuns wrote:

Ryan,

 

The mail issue turned out to be an exchange issue with not have a public cert.

 

I do have one further question about the Exchange IP you developed. Is the a way to format the text of the email message? More specifically I’m trying to keep all of the message body from being run together and insert carriage returns for readability.

 

I’ve tried all of the usual suspects: \n, `r`n, chr(13), chr(10) as well as putting quotes around the entire message body without any luck.

 

Any insight is appreciated.

Erik

 

From: randorfer [email removed]
Sent: Wednesday, April 11, 2012 11:03 AM
To: erikmuns@hotmail.com
Subject: Re: Exchange IP [scorch:349373]

 

From: randorfer

By the way, the exchange machine that hosts the webservice usually is your Exchange CAS Server


Using HTML email and inserting <BR> resolved the issues.

Coordinator
Apr 12, 2012 at 8:32 PM
Edited Apr 13, 2012 at 2:33 PM

Hey Erik,

 

Sorry for not getting back to you sooner with more details.  The IP supports sending both plain text emails as well as html formatted emails.  In order to put a line break in a plain text email you need to put the ascii character for space in the message body.  An easier way is actually to make an HTML formatted body (see the HTML example below).  An easy way to figure what a the HTML body would be for an email is actually to just create an email using outlook and send it to a mailbox.  You can then use an object from the IP (like find mail) to read that mail and look how it’s body is formatted (make sure you select HTML format for the body type).

   

<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<meta name="Generator" content="Microsoft Word 14 (filtered medium)">

<style><!--

/* Font Definitions */

@font-face

                {font-family:Calibri;

                panose-1:2 15 5 2 2 2 4 3 2 4;}

/* Style Definitions */

p.MsoNormal, li.MsoNormal, div.MsoNormal

                {margin:0in;

                margin-bottom:.0001pt;

                font-size:11.0pt;

                font-family:"Calibri","sans-serif";}

a:link, span.MsoHyperlink

                {mso-style-priority:99;

                color:blue;

                text-decoration:underline;}

a:visited, span.MsoHyperlinkFollowed

                {mso-style-priority:99;

                color:purple;

                text-decoration:underline;}

span.EmailStyle17

                {mso-style-type:personal-compose;

                font-family:"Calibri","sans-serif";

                color:windowtext;}

.MsoChpDefault

                {mso-style-type:export-only;

                font-family:"Calibri","sans-serif";}

@page WordSection1

                {size:8.5in 11.0in;

                margin:1.0in 1.0in 1.0in 1.0in;}

div.WordSection1

                {page:WordSection1;}

--></style><!--[if gte mso 9]><xml>

<o:shapedefaults v:ext="edit" spidmax="1026" />

</xml><![endif]--><!--[if gte mso 9]><xml>

<o:shapelayout v:ext="edit">

<o:idmap v:ext="edit" data="1" />

</o:shapelayout></xml><![endif]-->

</head>

<body lang="EN-US" link="blue" vlink="purple">

<div class="WordSection1">

<p>A HTML Formatted Email<o:p></o:p></p>

<p><o:p>&nbsp;</o:p></p>

<p><span style="color:#1F497D">Best regards,<o:p></o:p></span></p>

<p><span style="color:#1F497D">Ryan<o:p></o:p></span></p>

<p><o:p>&nbsp;</o:p></p>

</div>

</body>

</html>

Oct 25, 2012 at 3:37 PM

Hello:

We were able to successfully deploy the Exchange Email IP in our environment. We were also able to utilize the Monitor Email and Send Email. However, it appears the Monitor Mailbox activity is no longer publishing any of the Common Published Data such as Body, From, Id, IsRead, ReceivedDate, Subject and attachments. Literally, the entries are missing in the Runbook Details log. Both Runbook logging options are enabled.

As a simple test, we are sending a confirmation email stating the message has been received (at the monitored mailbox) and including the published variables: From and Subject. These are now blank in the confirmation email because the published data is gone. We tried disabling the old Monitor Mailbox activity and creating a new one - same result. We tried deleting and re-creating the Monitor Mailbox activity - same result. However, when we created a new runbook and added the Monitor Mailbox and Send Email activities it appears to be working again.

Any thoughts as to why this might occur?

Environment Information:

MS SCORH: v7.0.1154.0
Exchange Email IP v2.9 - deployed to all Runbook servers
Microsoft Exchange Web Services Managed API v2.0 - deployed to all Runbook servers

Thanks!

Tobin

Coordinator
Oct 25, 2012 at 3:53 PM

Hey Tobin,

Did you do any updates to the IP in between? For example, did you have the initial workflow with version 2.6 of the IP then upgrade to version 2.9? Did the initial version ever work correctly or was it always broken? Are you encountering any database issues (check under the events tab and see if there are any errors complaining of frequent database errors)?

-Ryan

Oct 25, 2012 at 4:09 PM

Hey Ryan:

Thanks for the quick reply! So, as soon as I posted I figured out why we are seeing inconsistencies. It appears that the Monitor Mailbox activity is not properly handling multiple conditional filters. For example, we are monitoring a mailbox using the following filters:

· From – Contains – first.last@somecompany.com

· Subject – Contains – Start Demo

I just verified in one of the original runbooks that the behavior is back to normal – all Common Published Data is available for the Monitor Mailbox activity. Using the filter ‘relation’ Equals works too. However, we assumed that since there is a warning message stating “Remove all other filters from field ‘From’ before adding a filter with the ‘Equals’ relation” that you could have multiple ‘Contains’ relations giving us the ability to trigger the activity from multiple senders. This did not work properly. The activity fires as expected but no common data is available. We had the same experience by trying to add multiple entries to a single From filter using the ‘Contains’ relation too. Let me know if this makes sense…it was pretty easy to re-produce.

I guess we need to understand if this is a limitation or possibly a bug. The good thing is that we can move forward with test knowing what we can and cannot do. Let me know if you would like additional information.

Thanks!

Tobin

From: randorfer [email removed]
Sent: Thursday, October 25, 2012 10:54 AM
To: Turney, Tobin
Subject: Re: Exchange IP [scorch:349373]

From: randorfer

Hey Tobin,

Did you do any updates to the IP in between? For example, did you have the initial workflow with version 2.6 of the IP then upgrade to version 2.9? Did the initial version ever work correctly or was it always broken? Are you encountering any database issues (check under the events tab and see if there are any errors complaining of frequent database errors)?

-Ryan

Oct 25, 2012 at 4:23 PM

BTW…to answer your initial questions – this was not an upgrade of any sort. Also, we are starting to see the same issue again in Runbooks that were just working – so I am not sure what is going on. We do not have any DB issues either.

From: randorfer [email removed]
Sent: Thursday, October 25, 2012 10:54 AM
To: Turney, Tobin
Subject: Re: Exchange IP [scorch:349373]

From: randorfer

Hey Tobin,

Did you do any updates to the IP in between? For example, did you have the initial workflow with version 2.6 of the IP then upgrade to version 2.9? Did the initial version ever work correctly or was it always broken? Are you encountering any database issues (check under the events tab and see if there are any errors complaining of frequent database errors)?

-Ryan

Mar 19, 2013 at 9:18 PM
Edited Mar 19, 2013 at 9:19 PM
I hate to bring this one up again... :(

I am having this issue as well with Autodiscover...

I did test with https://www.testexchangeconnectivity.com/ from my Runbook server and it tests fine for the AutoDiscover tests for Exchange, Office 365 etc...
The Autodiscover service couldn't be located.

Exception: AutodiscoverLocalException
Target site: AutodiscoverService.InternalGetLegacyUserSettings

Stack trace:
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.InternalGetLegacyUserSettings[TSettings](String emailAddress, List`1 redirectionEmailAddresses, Int32& currentHop)
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.GetLegacyUserSettings[TSettings](String emailAddress)
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.InternalGetLegacyUserSettings(String emailAddress, List`1 requestedSettings)
   at Microsoft.Exchange.WebServices.Autodiscover.AutodiscoverService.GetUserSettings(String userSmtpAddress, UserSettingName[] userSettingNames)
   at Microsoft.Exchange.WebServices.Data.ExchangeService.GetAutodiscoverUrl(String emailAddress, ExchangeVersion requestedServerVersion, AutodiscoverRedirectionUrlValidationCallback validateRedirectionUrlCallback)
   at Microsoft.Exchange.WebServices.Data.ExchangeService.AutodiscoverUrl(String emailAddress, AutodiscoverRedirectionUrlValidationCallback validateRedirectionUrlCallback)
   at ExchangeMail.FindMail.Execute(IActivityRequest request, IActivityResponse response)
I went as far as installing Outlook on this server and it works fine without having to do any manual configuration. :(

I am lost at this point. Any help? :)

We are using Office 365. I did get the other Exchange User IP to work but it doesn't have the "Get Attachments" function I am looking for. Then I found this one, which to be honest, is more complete.

Thank you,
Rob
Apr 25, 2014 at 3:26 PM
We are also using O365 and I am having trouble using this OIP.
I'm worried support for Exchange Online is missing, since the Exchange versions in the config settings do not provide it.

Will support be coming soon? Like the poster above, this OIP has greater functionality - there are specific runbooks I need to create that this OIP can address.
If it is supported, can someone provide a quick run through on what the proper settings are to connect to a cloud based account?

Cheers
Steve