<?
class SessionsController extends ApplicationController{
  function login(){
    //Show Login Page
	}

	function process(){
		$this->auth->logUserIn($_POST['email'], $_POST['password']);
	}

	function logout(){
		$this->auth->logout();

		$this->redirect($this->config['root']);
	}
}
?>

<?
class SessionsController extends ApplicationController{
  function login(){
    //Show Login Page
	}

	function process(){
    if(isset($_POST['email']) && isset($_POST['password'])){
      $this->auth->logUserIn($_POST['email'], $_POST['password'], false);
    }else{
      flash('error', 'Incorrect username or password. Try again.');
      session_write_close();
      header('Location: '.$this->config['address'].'/login');
    }
	}

	function logout(){
		$this->auth->logout();

		$this->redirect($this->config['root']);
	}
}
?>

Check to make sure username and password are explicitly posted
Check to make sure username and password are explicitly posted
