AES 256 with BCrypt hash. How to check user password from database?
<p>I am using AES256 encryption but it can be decrypt with secure key. And i hash the encrypted password and store in my DB. But the plain-text "password" encrypt different each time. And hash by BCrypt different each time.How can i store or check password when  user submit his/her password?  </p>

<pre><code> AES256Encryption d = new AES256Encryption();


    String password = "password";
    System.out.println("password : " + password);
    String encPsw = d.encrypt(password);
    System.out.println("Encrypted string:" + encPsw);


    String hash = BCrypt.hashpw(encPsw, BCrypt.gensalt()); 
    System.out.println("hashed string : " + hash);

    if(BCrypt.checkpw(password,hash )){
        System.err.println("password matched!!");
    }else{
        System.err.println("password not matched!!");
    }
</code></pre>

<p>These codes always prints "password not matched!!". How can i compare user's password and hashed password from database?</p>