title: TFS 2012 - Email Alerts not working
body: <p>We have a TFS 2012 server and have tried to enable email alerts. However, we never receive them.</p>
  
  <p>I have set up both team alerts and alerts specific to my account. When configuring the SMTP settings in the TFS Admin Console, I have tried leaving the credentials blank, and also using my own credentials. Neither works.</p>
  
  <p>I have also created a simple console app in C# using the <code>System.Net.Mail.SmtpClient</code> class to test emails, both with and without my credentials, from the TFS server and it works.</p>
  
  <p>The Event Logs don't show any relevant error messages.</p>
  
  <p>How can I troubleshoot and fix this issue?</p>
  
  <h2>Update</h2>
  
  <p>Using the information in this <a href="http://blogs.msdn.com/b/granth/archive/2009/10/28/tfs2010-diagnosing-email-and-soap-subscription-failures.aspx" rel="nofollow">article</a>, I was able to extract the following error message from the database job history table.</p>
  
  <pre><code>elapsed time: 00:00:00.5255295, sql calls: 35, sql connect time: 00:00:00, sql execute time: 00:00:00.0311960, non-sql time: 00:00:00.4943335 (94%), cpu time: 00:00:00.0312002 ( 5.9%), avg connect time: 0.00 ms, avg execute time:  0.9 ms. All methods quick. All sql calls quick. CollectionError: CreateEvent != TransformEvents. CollectionError: AfterReadSubscription != ExpandEvents. CollectionError: RemoveRestrictedContent != FilterNotification. CollectionError: RemoveRestrictedContent != SendNotifications.
  There were errors or warnings during notification delivery.
  
  0/0 emails delivered.
  0/0 soap notifications delivered. 
  1 errors.
  0 warnings.
  
  -------------------------------
  Notification not delivered due to error during filtering of restricted content.
  
  Notification: WorkItemChangedEvent (DeliveryType: EmailHtml; Address: )
  
  Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---&gt; System.InvalidOperationException: This implementation is not part of the Windows Platform FIPS validated cryptographic algorithms.
     at System.Security.Cryptography.MD5CryptoServiceProvider..ctor()
     --- End of inner exception stack trace ---
     at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
     at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
     at System.Security.Cryptography.CryptoConfig.CreateFromName(String name, Object[] args)
     at System.Security.Cryptography.MD5.Create(String algName)
     at Microsoft.TeamFoundation.Framework.Server.Alm.ConversationThread.Create(TeamFoundationRequestContext requestContext, ToolType toolType, Byte artifactType, Int32 artifactId, String topic, DateTime creationDate)
     at Microsoft.TeamFoundation.WorkItemTracking.Server.NotificationFilter.RemoveRestrictedContent(TeamFoundationRequestContext requestContext, String server, TeamFoundationIdentity[] userIdentities, XmlDocument eventCopy, Restriction[]&amp; restrictions)
     at Microsoft.TeamFoundation.JobService.Extensions.Core.NotificationJobExtension.FilterNotification(TeamFoundationRequestContext requestContext, TeamFoundationIdentity subscriber, IEnumerable`1 filters, TeamFoundationNotification notification)
  </code></pre>
  
  <p>As described <a href="http://support.microsoft.com/kb/2550971/en-us" rel="nofollow">here</a>, I have checked <strong>Local Security Policy</strong> for the <em>Security Settings->Local Policies->Security Options->"System cryptography: Use FIPS compliant algorithms for encryption, hashing, and signing"</em> value and it was already set to <strong>disabled</strong>.</p>