This week's book giveaway is in the OCPJP forum. We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line! See this thread for details.
the default encoding used for digest passwords in HEX in tomcat and glassfish as well, whereas it base64 in JBoss. I don't see the place where I can define the encoding for digest passwords as base64.
Can anyone help?
thanks in advance
Joined: Jun 20, 2009
when I specify the digest algorithm for password in the datasource realm as "MD5 as below
the digest password so generated is encoded in "HEX" by default.
But I want this to be encoded in "BASE64".
There is an option in JBoss to specify the hashEncoding along with hashAlgorithm as below:
<application-policy name ="........">
<login-module code = "org.jboss.security.auth.spi.DatabaseServerLoginModule" flag = "required">
<module-option name = "unauthenticatedIdentity">guest</module-option>
<module-option name = "dsJndiName">java:/jdbc/LoginDs</module-option>
<module-option name="principalsQuery">select passwd as PASSWORD from users where user_name=?</module-option>
<module-option name="rolesQuery">select role_name as Role, 'Roles' from user_roles where user_name=?</module-option>
<module-option name="hashEncoding">base64</module-option> </login-module>
There is "digestEncoding" attribute in Realm but I don't think I can specify the hashEncoding value "BASE64" in this attribute.
Is there any way that I can specify the encoding as base64 in tomcat for digest password?