Skip to main content

Posts

Showing posts with the label Exchange 2010 SP2

EWS Managed API and Powershell How-To Series Part 11 Moderation

Moderation is an Exchange feature that was introduced in Exchange 2010 that allows the Human control of mail flow to a distribution group or mailbox. There is a good Blog article that describes the process at  http://blogs.technet.com/b/exchange/archive/2009/06/10/3407662.aspx. In this installment of the How-To series I'll go through all the different ways in which you can use and manipulate moderated email via EWS.  Moderation Workflow The moderation process flows through a workflow so I'll look at the full process and show where EWS can be used along that way.  Before Send The first thing you can do is even before a message is going to be sent is to work out if its going to be moderated by using MailTips. Eg the following code will access the MailTip for moderation and show you if the recipient will be moderated. $MailboxName  =  "sender@domain.com"           $Mailboxes  = @( "user1@domain....

Version 1.2 or the EWS Managed API just released

The new version of the EWS Managed API has just been released http://www.microsoft.com/download/en/details.aspx?id=28952  which means you can start using the new Exchange 2010 SP2 features that have been added to the Managed API. A Quck few examples are First make sure you set the Version to SP2 eg ExchangeService service =  new  ExchangeService(ExchangeVersion.Exchange2010_SP2);   Using Password Expiration DateTime PasswordExpirDate = (DateTime)service.GetPasswordExpirationDate( "user@domain.com" );   Accessing the Directory Photo NameResolutionCollection ncCol = service.ResolveName( "user@domain.com" ,ResolveNameSearchLocation.DirectoryOnly, true );   foreach (NameResolution nc  in  ncCol) {       Byte[] dirPhoto = nc.Contact.DirectoryPhoto;   }   See a full list of the new ...

Using the new EWS password expiration operation in Exchange 2010 SP2 in Powershell

If it hadn't escaped your notice Exchange 2010 SP2 was released this week although from an EWS perspective there isn't that much to shout about one of the interesting new operations is the GetPasswordExpiration operation. This allows you to get the DateTime when the password for an account will expire. Currently version 1.1 of the Managed API doesn't support this operation but from the information that has been released the next version should. In the meantime you can take advantage of this new operation using some raw SOAP. The following is a quick sample script that makes a GetPasswordExpiration request there is some SSL ignore code so it should run okay in a test environment without a valid SSL cert. To use this script you need to configure the following variables. $MailboxName = "user@domain.com"         $cred = New-Object System.Net.NetworkCredential("user@domamin.com","password") If you don't have autodiscover configured if y...
All sample scripts and source code is provided by for illustrative purposes only. All examples are untested in different environments and therefore, I cannot guarantee or imply reliability, serviceability, or function of these programs.

All code contained herein is provided to you "AS IS" without any warranties of any kind. The implied warranties of non-infringement, merchantability and fitness for a particular purpose are expressly disclaimed.