When you create a simple .Net 4 WCF Service Application it generates a simplified web.config file with default endpoints. This is great when you need a simple service and don’t want a cluttered config file. However, I did come across a small issue with the default file when you try to open it with the Service Configuration Editor. When you try to open the file an error is displayed; ‘The ‘name’ configuration element key cannot be null’. To fix the problem just add the name attribute to the behavior node;
<behaviors> <serviceBehaviors> <behavior name="defaultBehaviour"> <serviceMetadata httpGetEnabled="true" /> </behavior> </serviceBehaviors> </behaviors>