title: jboss 4.3 DatabaseServerLoginModule doesn't work if passwords are MD5 and hex-ed
body: <p>I have a problem with authorization when my login-conf is</p>
  
  <pre><code>&lt;login-module code="org.jboss.security.auth.spi.DatabaseServerLoginModule" flag="optional"&gt;
      &lt;module-option name="dsJndiName"&gt;java:/myDS&lt;/module-option&gt;
      &lt;module-option name="hashAlgorithm"&gt;MD5&lt;/module-option&gt;
      &lt;module-option name="hashEncoding"&gt;hex&lt;/module-option&gt;
      &lt;module-option name="principalsQuery"&gt;SELECT PASSWORD FROM PASS_TABLE WHERE LOGINNAME=?&lt;/module-option&gt;
      &lt;module-option name="rolesQuery"&gt;SELECT VALUE, 'Roles' FROM PASSWD_TABLE_PROPERTY WHERE LOGINNAME=? AND NAME='profile'&lt;/module-option&gt;
  &lt;/login-module&gt;
  </code></pre>
  
  <p>It works fine when hasEnchoding is changed to base64. And both works fine on JBoss 4.2. But hex in JBoss4.3 doesn't work.</p>
  
  <p>Example of hash that is saved into database is like this:
      echo -n password | openssl dgst -md5</p>
  
  <p>what means: 5f4dcc3b5aa765d61d8327deb882cf99</p>
  
  <p>Any help?</p>