title: Which validator should be used to implement login in Symfony?
body: <p>Currently, my login form looks like this,</p>
  
  <pre><code>class LoginForm extends BaseFormPropel
  {
    public function setup()
    {
      $this-&gt;setWidgets(array(
        'login_id' =&gt; new sfWidgetFormInput(), 
        'pwd' =&gt; new sfWidgetFormInputPassword() 
      ));
  
      $this-&gt;widgetSchema-&gt;setLabels(array(
          'login_id'=&gt;'Login Id',
          'pwd'=&gt;'Password'
      ));
  
      $this-&gt;widgetSchema-&gt;setNameFormat('member[%s]');
  
      $this-&gt;setValidators(array(
        'login_id' =&gt; new sfValidatorPropelChoice(array('model' =&gt; 'Member', 'column' =&gt; 'login_id', 'required' =&gt; true)), 
        'pwd' =&gt; new sfValidatorPropelChoice(array('model' =&gt; 'Member', 'column' =&gt; 'pwd', 'required' =&gt; true))
      ));
  
      $this-&gt;errorSchema = new sfValidatorErrorSchema($this-&gt;validatorSchema);
  
      parent::setup();
    }
  
  
    public function getModelName()
    {
      return 'Member';
    }
  
  }
  </code></pre>
  
  <p>But this is a wrong implementation, because sfValidatorPropelChoice only ensures the user enters a value that does exist in the column. This means if the database contains the following rows,</p>
  
  <p>login_id | pwd<br/>
  john, 12345<br/>
  peter, 67890<br/></p>
  
  <p>A user using john and 67890 to login will succeed.
  My question is that, which validator should I use to correct the problem?</p>