21 June 2016

Exchange 2013 Default IIS Settings

These are the default IIS settings for the Front End Website and the Exchange Back End Website, taken from a fresh installed Exchange 2013 CU12 server:

Default Web Site (Front End)
Virtual directory
Default IIS Authentication methods
SSL settings
Default authentication methods
Exchange Admin Center (EAC)
AuthenticationMethods
Exchange Management Shell (EMS)
Sites \ Default Web Site
As shown in Internet Information Services (IIS) Manager
 Available through EAC
 Internal
 External
Autodiscover
• Anonymous authentication
• Basic authentication
• Windows authentication
 • SSL required
• Integrated Windows authentication
• Basic authentication
Basic, Ntlm, WindowsIntegrated, WSSecurity, OAuth
Basic, Ntlm, WindowsIntegrated, WSSecurity, OAuth
ECP (Exchange Control Panel)
• Anonymous authentication
• Basic authentication
 • SSL required
• Use-forms-based authentication
 Basic, Fba
 Fba
EWS (Exchange Web Services)
• Anonymous authentication
• Basic authentication
 • SSL required
• Integrated Windows authentication
Ntlm, WindowsIntegrated, WSSecurity, OAuth
Ntlm, WindowsIntegrated, WSSecurity, OAuth
Mapi
 • Windows authentication
 • SSL required
 Not available in EAC
Ntlm, OAuth, Negotiate
Not configured
Microsoft-Server-Active-Sync
• Basic authentication
 • SSL required
• Basic authentication
• Ignore client certificate
Not set *
All methods can be used.
Not set *
All methods can be used.
OAB (Offline Address Book)
• Windows authentication
None available
WindowsIntegrated, OAuth
WindowsIntegrated, OAuth
OWA (Outlook Web App)
• Basic authentication
• SSL required
 • Use-forms-based authentication
• Domain\user name
 Basic, Fba
 Basic, Fba
OWA\Calendar
• Anonymous authentication
• Ignore client certificates
None available
OWA\Integrated
• Windows authentication
• SSL required
• Ignore client certificates
None available
OWA\oma (Outlook Mobile Access)
• Basic authentication
• Ignore client certificates
None available
PowerShell
• Windows authentication
• Not Required
 None set
 {}
 {}
* The InternalAuthenticationMethods/ExternalAuthenticationMethods  parameter specifies the authentication methods supported by the server that contains the virtual directory when access is requested from inside the network firewall. If this parameter isn’t set, all authentication methods can be used.
Aside from the above listed Virtual Directories, which you can find in the EAC, you also have the following directories to manage through IIS or EMS:
Virtual directory
Authentication method
SSL settings
Management method
Default Website
• Anonymous authentication
• SSL required
IIS Management Console*
This virtual directory can’t be configured by the user*
aspnet_client
• Anonymous authentication
• SSL required
IIS management console
Rpc
• Basic authentication
• Windows authentication
• SSL required
Exchange Management Shell (EMS)
* Indicates difference between multirole and Mailbox role server. You can’t configure this if the server only has the Mailbox role

Exchange Back End Website
Virtual directory
IIS Default Authentication methods
IIS SSL settings
Exchange Back End
• Anonymous authentication
• SSL required
• Ignore client certificates
Autodiscover
• Anonymous authentication
• Windows authentication
• SSL required
• Ignore client certificates
 ecp
• Anonymous authentication
• Windows authentication
• SSL required
• Ignore client certificates
 EWS
• Anonymous authentication
• Windows authentication
• SSL required
• Ignore client certificates
 Exchange
• SSL required
• Ignore client certificates
 Exchweb
• SSL required
• Ignore client certificates
 mapi
• Anonymous authentication
• SSL required
• Ignore client certificates
 Microsoft-Server-ActiveSync
• Basic authentication
• SSL required
• Ignore client certificates
 OAB
• Windows authentication
• SSL required
• Ignore client certificates
owa
• Anonymous authentication
• Windows authentication
• SSL required
• Ignore client certificates
owa\Calender
• Anonymous authentication
• Ignore client certificates
PopImap
• Anonymous authentication
• SSL required
• Ignore client certificates
 PowerShell
• Windows authentication
 • SSL required
• Accept client certificates
PowerShell-Proxy

• SSL required
• Ignore client certificates
Public
• SSL required
• Ignore client certificates
 PushNotifications
• Anonymous authentication
• Windows authentication
• SSL required
• Ignore client certificates
Quarantine
• Anonymous authentication
• SSL required
• Ignore client certificates
ReportingWebService
• Anonymous authentication
• SSL required
• Ignore client certificates
Reports
• Anonymous authentication
• SSL required
• Ignore client certificates
 Rpc
• Windows authentication
• Ignore client certificates
RpcProxy
• Anonymous authentication
• SSL required
• Ignore client certificates
 RpcWithCert
• Windows authentication
• Ignore client certificates
Sync

• SSL required
• Ignore client certificates
Ucc
• Anonymous authentication
• SSL required
• Ignore client certificates


17 May 2016

Exchange 2013 Event ID: 106 The case of the missing Performance counter

Well actually it's not missing, there is just a big fat typo in the file.
And that typo is the reason why the eventlogs are filling up with event id 106 error's faster than you can blink an eye.

There is a Technet Article showing you how to update the Performance counter all at once with a PowerShell script, but if you do this then you get the following error:


Well that doesn't help, But now we know which performance counter to deal with.
Let's have a look at the file it self:

Open C:\Program Files\Microsoft\Exchange Server\V15\Setup\Perf\InfoWorkerMultiMailboxSearchPerformanceCounters.xml

In there you have to search for: "> Searches"

The one space is causing all the trouble.
Find/replace "> Searches" with ">Searches" and save the file on all your exchange 2013 Servers.
-Note This seems to be going on from the RTM up to CU12, so don't think i've got the most recent CU so i'm fine, no your not, this is one of the many issues that just don't ever get fixed until the Office365 team or the Exchange dev team wants to or get's told to do so.

In the mean time use this.
After the file has been saved on all Exchange 2013 servers go to the EMS:

[PS] C:\windows\system32>Add-Pssnapin Microsoft.Exchange.Management.PowerShell.Setup
[PS] C:\windows\system32>New-PerfCounters -definitionfilename "C:\Program Files\Microsoft\Exchange Server\V15\Setup\Perf
\InfoWorkerMultiMailboxSearchPerformanceCounters.xml"
[PS] C:\windows\system32>


Source

10 May 2016

Disable SSL 3.0, Weak Ciphers and enable TLS 1.1 and 1.2

Windows Server 2008 (R2) using IIS 7 allows SSL 2.0 and SSL 3.0 by default. Unfortunately, this means you will fail a PCI Compliance scan by default. To properly secure your server and ensure that you pass your PCI-DSS scans, you will need to disable SSL 2.0 and disable weak ciphers. In order to disable SSL 2.0 and SSL 3.0 in IIS 7 and make sure that the stronger TLS 1.0 is used, even better enable TLS 1.1 and TLS 1.2.

Below you can find how to disable SSL 3.0 and the weak Ciphers, and enable TLS 1.1 and TLS 1.2.

Remember that this only works after a server reboot, stopping services or IIS is not enough

UPDATE: 27-05-2016 I found an error in the registry key settings, below are the correct settings.

Disable SSL3.0. and Weak Ciphers and Enable TLS 1.1 and 1.2

Copy the text below and paste in to a .reg file:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL]
"EventLogging"=dword:00000001
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\AES 128/128]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\AES 256/256]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\DES 56]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\DES 56/56]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\NULL]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC2 128/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC2 40/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC2 56/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC4 128/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC4 40/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC4 56/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\RC4 64/128]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Ciphers\Triple DES 168/168]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\CipherSuites]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Hashes]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Hashes\MD5]
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Hashes\SHA]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Hashes\SHA256]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Hashes\SHA384]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Hashes\SHA512]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\KeyExchangeAlgorithms]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\KeyExchangeAlgorithms\Diffie-Hellman]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\KeyExchangeAlgorithms\ECDH]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\KeyExchangeAlgorithms\PKCS]
"Enabled"=dword:ffffffff
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\Multi-Protocol Unified Hello]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\Multi-Protocol Unified Hello\Server]
"Enabled"=dword:00000000
"DisabledByDefault"=dword:00000001
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\PCT 1.0]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\PCT 1.0\Server]
"Enabled"=dword:00000000
"DisabledByDefault"=dword:00000001
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 2.0]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 2.0\Client]
"DisabledByDefault"=dword:00000001
"Enabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 2.0\Server]
"Enabled"=dword:00000000
"DisabledByDefault"=dword:00000001
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 3.0]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\SSL 3.0\Server]
"Enabled"=dword:00000000
"DisabledByDefault"=dword:00000001
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Server]
"Enabled"=dword:ffffffff
"DisabledByDefault"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Server]
"Enabled"=dword:ffffffff
"DisabledByDefault"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Server]
"Enabled"=dword:ffffffff
"DisabledByDefault"=dword:00000000

Change cipher order and remove unsafe ciphers:

Open gpedit.msc =>> go to Administrative Templates =>> Network =>> SSL Configuration Settings =>> double click SSL Cipher Suite Order.



In the SSL Cipher Suite Order screen select "Enabled" and under options select and delete everything in that text field.



Then copy this line in that text field:

TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256_P521,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256_P256,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256_P521,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256_P256,TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384_P521,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384_P521,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P521,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P384,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P521,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256,TLS_RSA_WITH_AES_128_CBC_SHA256,TLS_RSA_WITH_AES_256_CBC_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA_P521,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA_P256,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA_P521,TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA_P256,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA_P521,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA_P256,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P521,TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P256,TLS_RSA_WITH_RC4_128_SHA,TLS_RSA_WITH_AES_256_CBC_SHA,TLS_RSA_WITH_AES_128_CBC_SHA

Click "Apply" and "OK".

Now you have to reboot the server in order to activate these changes,
After the reboot go to https://www.ssllabs.com/ssltest/ and see if you get any errors or warnings.

Another way to do this is by using IISCrypto by Nartac Software, this freeware does the same but in a GUI. But for some reason it didn't do what i axpected it to do, so this way you can do it manually.

14 April 2016

Remove MailboxDatabase - This mailbox database contains one or more mailboxes…

A common error, with numerous google search hits to over come the most common problems when deleting a mailbox database. But this is a nasty one, turns out that Set-AdServerSettings -ViewEntireForest $True doesn't always show you exactly what is happening.

This was the case in my case. I couldn't get the database removed, and than i found this.

Delete the mailboxdatabase:
Remove-MailboxDatabase databasename -Verbose

It then shows the reason why it can't be deleted.
In my case it was a systemmailbox that wasnt showing when i did
get-mailbox -database databasename


Now i could see what the reason was why the deletion stopped.

1. Start the Active Directory Users and Computers snap-in.

2. On the View menu, make sure that Advanced Features is selected.

3. Locate the Microsoft Exchange System Objects container.

4. Delete the SystemMailbox{yournumber} item.