title: Proper config for Unity dependency resolver to work with MvcMembership?
body: <p>I am not able to find the proper Unity configuration to get it to work with MvcMembership.</p>
  
  <p>At this point, I am getting the following error message:</p>
  
  <blockquote>
    <p>The type Boolean cannot be constructed. You must configure the
    container to supply this value.</p>
  </blockquote>
  
  <p>Here is my code to register dependencies:</p>
  
  <pre><code>    container.RegisterInstance&lt;MembershipProvider&gt;(Membership.Provider);
  
      container.RegisterType&lt;IMembershipSettings,AspNetMembershipProviderSettingsWrapper&gt;();
      container.RegisterType&lt;IUserService, AspNetMembershipProviderWrapper&gt;();
      container.RegisterType&lt;IPasswordService, AspNetMembershipProviderWrapper&gt;();
      container.RegisterType&lt;IRolesService, AspNetRoleProviderWrapper&gt;();
      container.RegisterType&lt;ISmtpClient, SmtpClientProxy&gt;();
      container.RegisterType&lt;IRegistrationSettings, RegistrationSettings&gt;();
  </code></pre>
  
  <p>And here is my Stack Trace:</p>
  
  <p>[InvalidOperationException: The type Boolean cannot be constructed. You must configure the container to supply this value.]
     Microsoft.Practices.ObjectBuilder2.DynamicMethodConstructorStrategy.GuardTypeIsNonPrimitive(IBuilderContext context, SelectedConstructor selectedConstructor) +277
     Microsoft.Practices.ObjectBuilder2.DynamicMethodConstructorStrategy.PreBuildUp(IBuilderContext context) +485
     Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +434
     Microsoft.Practices.ObjectBuilder2.DynamicMethodBuildPlanCreatorPolicy.CreatePlan(IBuilderContext context, NamedTypeBuildKey buildKey) +400
     Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +222
     Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +434
     Microsoft.Practices.ObjectBuilder2.BuilderContext.NewBuildUp(NamedTypeBuildKey newBuildKey) +318
     BuildUp_MvcMembership.Settings.RegistrationSettings(IBuilderContext ) +216
     Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +304
     Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +434
     Microsoft.Practices.ObjectBuilder2.BuilderContext.NewBuildUp(NamedTypeBuildKey newBuildKey) +318
     BuildUp_MvcMembership.Settings.AspNetMembershipProviderSettingsWrapper(IBuilderContext ) +220
     Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +304
     Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +434
     Microsoft.Practices.ObjectBuilder2.BuilderContext.NewBuildUp(NamedTypeBuildKey newBuildKey) +318
     BuildUp_MyProject.Web.Areas.MvcMembership.Controllers.UserAdministrationController(IBuilderContext ) +223
     Microsoft.Practices.ObjectBuilder2.BuildPlanStrategy.PreBuildUp(IBuilderContext context) +304
     Microsoft.Practices.ObjectBuilder2.StrategyChain.ExecuteBuildUp(IBuilderContext context) +434
     Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, Object existing, String name, IEnumerable`1 resolverOverrides) +440</p>
  
  <p>[ResolutionFailedException: Resolution of the dependency failed, type = "MyProject.Web.Areas.MvcMembership.Controllers.UserAdministrationController", name = "(none)".
  Exception occurred while: while resolving.</p>
  
  <h2>Exception is: InvalidOperationException - The type Boolean cannot be constructed. You must configure the container to supply this value.</h2>
  
  <p>At the time of the exception, the container was:</p>
  
  <p>Resolving MyProject.Web.Areas.MvcMembership.Controllers.UserAdministrationController,(none)
    Resolving parameter "membershipSettings" of constructor MyProject.Web.Areas.MvcMembership.Controllers.UserAdministrationController(MvcMembership.Settings.IMembershipSettings membershipSettings, MvcMembership.IUserService userService, MvcMembership.IPasswordService passwordService, MvcMembership.IRolesService rolesService, MvcMembership.ISmtpClient smtpClient)
      Resolving MvcMembership.Settings.AspNetMembershipProviderSettingsWrapper,(none) (mapped from MvcMembership.Settings.IMembershipSettings, (none))
      Resolving parameter "registration" of constructor MvcMembership.Settings.AspNetMembershipProviderSettingsWrapper(MvcMembership.Settings.IRegistrationSettings registration, MvcMembership.Settings.IPasswordSettings password, MvcMembership.Settings.ILoginSettings login)
        Resolving MvcMembership.Settings.RegistrationSettings,(none) (mapped from MvcMembership.Settings.IRegistrationSettings, (none))
        Resolving parameter "requiresUniqueEmailAddress" of constructor MvcMembership.Settings.RegistrationSettings(System.Boolean requiresUniqueEmailAddress)
          Resolving System.Boolean,(none)
  ]
     Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, Object existing, String name, IEnumerable<code>1 resolverOverrides) +546
     Microsoft.Practices.Unity.UnityContainer.DoBuildUp(Type t, String name, IEnumerable</code>1 resolverOverrides) +20
     System.Web.Mvc.DefaultControllerActivator.Create(RequestContext requestContext, Type controllerType) +68</p>
  
  <p>[InvalidOperationException: An error occurred when trying to create a controller of type 'MyProject.Web.Areas.MvcMembership.Controllers.UserAdministrationController'. Make sure that the controller has a parameterless public constructor.]
     System.Web.Mvc.DefaultControllerActivator.Create(RequestContext requestContext, Type controllerType) +634403
     System.Web.Mvc.DefaultControllerFactory.CreateController(RequestContext requestContext, String controllerName) +93
     System.Web.Mvc.MvcHandler.ProcessRequestInit(HttpContextBase httpContext, IController&amp; controller, IControllerFactory&amp; factory) +346
     System.Web.Mvc.&lt;>c_<em>DisplayClass6.b</em>_2() +71
     System.Web.Mvc.&lt;>c__DisplayClassb<code>1.&lt;ProcessInApplicationTrust&gt;b__a() +19
     System.Web.Mvc.SecurityUtil.ProcessInApplicationTrust(Func</code>1 func) +161
     System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +405
     System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean&amp; completedSynchronously) +375</p>