[jboss-jira] [JBoss JIRA] (WFCORE-4497) jdbc realm is not supporting hex encoding

Darran Lofthouse (Jira) issues at jboss.org
Thu May 30 05:55:00 EDT 2019


     [ https://issues.jboss.org/browse/WFCORE-4497?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Darran Lofthouse resolved WFCORE-4497.
--------------------------------------
    Resolution: Explained


Thanks, please re-open or create a new issue if there are problems with WildFly 17.

> jdbc realm is not supporting hex encoding 
> ------------------------------------------
>
>                 Key: WFCORE-4497
>                 URL: https://issues.jboss.org/browse/WFCORE-4497
>             Project: WildFly Core
>          Issue Type: Bug
>          Components: Security
>         Environment: windows mssql 
>            Reporter: Christopher Willems
>            Priority: Major
>
> following CLI is not generating the encoding attributes in the standalone xml :
> /subsystem=elytron/jdbc-realm=demo-realm:add(principal-query=[{data-source=Identities,sql="select PASSWORD, SALT, ITERATION_COUNT from IDENTITIES where NAME = ?", bcrypt-mapper={password-index=1,hash-encoding=hex, salt-index=2, salt-encoding=hex, iteration-count-index=3}}])
> we get 
>    <jdbc-realm name="demo-realm">
>                     <principal-query sql="select PASSWORD, SALT, ITERATION_COUNT from IDENTITIES where NAME = ?" data-source="veri95">
>                         <bcrypt-mapper password-index="1" salt-index="2" iteration-count-index="3"/>
>                     </principal-query>
>                 </jdbc-realm>
> adding the attributes ourselves results in a parsing error .
> OPVDX001: Validation error in standalone.xml -----------------------------------
> |
> |  360: <jdbc-realm name="demo-realm">
> |  361:     <principal-query sql="select PASSWORD, SALT, ITERATION_COUNT from IDENTITIES where NAME = ?" data-source="veri95">
> |  362:         <bcrypt-mapper password-index="1" salt-index="2" iteration-count-index="3" hash-encoding="hex"/>
> |                                                                                          ^^^^ 'hash-encoding' isn't an allowed attribute for the 'bcrypt-mapper'
> |                                                                                                 element
> |                                                                                               
> |                                                                                               Attributes allowed here are: iteration-count-index, password-index,
> |                                                                                                 salt-index 
> |
> |  363:     </principal-query>
> |  364: </jdbc-realm>
> |  365: <jdbc-realm name="jdbc2-realm">
> |
> | The primary underlying error message was:
> | > ParseError at [row,col]:[362,25]
> | > Message: WFLYCTL0376: Unexpected attribute 'hash-encoding'
> | >   encountered. Valid attributes are: 'password-index, salt-index,
> | >   iteration-count-index'
> |
> this is also the case for the other mappers 



--
This message was sent by Atlassian Jira
(v7.12.1#712002)


More information about the jboss-jira mailing list