title: ASP.Net MVC Model Binder - Ignore Properties
body: <p>I have an ASP.Net MVC5 site using Entity Framework 6.</p>
  
  <p>I am using ASP.Net Identity role-based security that performs granular security checks within the page to determine if certain input fields should be visible to the user.  i.e. </p>
  
  <pre><code>@if (User.IsInRole(MyProj.Security.Roles.ViewSocial)) {
     @Html.TextBoxFor(m=&gt; m.SSN)
  }
  </code></pre>
  
  <p>If the user does not have the permission, the input field is not created and thus the model binder will blank out the value of this property.</p>
  
  <p>How can I work this so that it ignores these properties in the case where they are not being displayed for edit?</p>
  
  <p><code>@Html.HiddenFor()</code> will not work because I can't have the tags included in the client-side HTML where the values can be seen in the source.</p>
  
  <p>Will I need a custom model binder in this scenario?</p>