myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leonardo Uribe (JIRA)" <...@myfaces.apache.org>
Subject [jira] Commented: (TOMAHAWK-1329) javax.crypto.IllegalBlockSizeException with inputSuggestAjax
Date Thu, 02 Oct 2008 22:35:44 GMT

    [ https://issues.apache.org/jira/browse/TOMAHAWK-1329?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12636490#action_12636490
] 

Leonardo Uribe commented on TOMAHAWK-1329:
------------------------------------------

After checking this error the problem is when the ajax call to ask for suggested values is
done, the value of javax.faces.ViewState send in the code of FacesIO.js needs to be encoded
correctly. 

The solution is encode properly the value so when the state is restored, the correct value
is given.

> javax.crypto.IllegalBlockSizeException with inputSuggestAjax
> ------------------------------------------------------------
>
>                 Key: TOMAHAWK-1329
>                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-1329
>             Project: MyFaces Tomahawk
>          Issue Type: Bug
>          Components: InputSuggestAjax
>    Affects Versions: 1.1.7-SNAPSHOT, 1.1.7, 1.1.8-SNAPSHOT
>            Reporter: Gertjan van Oosten
>            Priority: Minor
>
> When I use the current inputSuggestAjax from Tomahawk 1.1.7-SNAPSHOT I get the following
stacktrace:
> 12 sep 2008 15:16:26 ERROR (_ErrorPageWriter.java:460) - An exception occurred
> javax.faces.FacesException: javax.crypto.IllegalBlockSizeException: Input length must
be multiple of 8 when decrypting with padded cipher
>         at org.apache.myfaces.shared_impl.util.StateUtils.symmetric(StateUtils.java:373)
>         at org.apache.myfaces.shared_impl.util.StateUtils.symmetric(StateUtils.java:411)
>         at org.apache.myfaces.shared_impl.util.StateUtils.decrypt(StateUtils.java:291)
>         at org.apache.myfaces.shared_impl.util.StateUtils.reconstruct(StateUtils.java:240)
>         at org.apache.myfaces.renderkit.html.HtmlResponseStateManager.getSavedState(HtmlResponseStateManager.java:187)
>         at org.apache.myfaces.renderkit.html.HtmlResponseStateManager.getState(HtmlResponseStateManager.java:139)
>         at org.apache.myfaces.application.jsp.JspStateManagerImpl.restoreView(JspStateManagerImpl.java:306)
>         at org.apache.myfaces.application.jsp.JspViewHandlerImpl.restoreView(JspViewHandlerImpl.java:515)
>         at com.sun.facelets.FaceletViewHandler.restoreView(FaceletViewHandler.java:316)
>         [...]
> Caused by: javax.crypto.IllegalBlockSizeException: Input length must be multiple of 8
when decrypting with padded cipher
>         at com.sun.crypto.provider.SunJCE_h.b(DashoA12275)
>         at com.sun.crypto.provider.SunJCE_h.b(DashoA12275)
>         at com.sun.crypto.provider.DESCipher.engineDoFinal(DashoA12275)
>         at javax.crypto.Cipher.doFinal(DashoA12275)
>         at org.apache.myfaces.shared_impl.util.StateUtils.symmetric(StateUtils.java:369)
>         ... 61 more
> 12 sep 2008 15:16:26 WARN  (DefaultAddResource.java:363) - MyFaces special javascript
could not be retrieved from request-map.
> When I revert the following change in FacesIO.js:
> 2008-06-16 15:01  lu4242
>         * [r668179]
>           core/src/main/resources/org/apache/myfaces/custom/dojoextensions/resource/FacesIO.js:
>           TOMAHAWK-1157 tableSuggestAjax not render with trinidad
> the inputSuggestAjax works again as before.
> This is with MyFaces-1.2.4, Tomahawk/sandbox 1.1.7-SNAPSHOT and Facelets.
> As suggested by Cagatay Civici, adding this parameter to web.xml is a work-around:
>     <context-param>
>         <param-name>org.apache.myfaces.USE_ENCRYPTION</param-name>
>         <param-value>false</param-value>
>     </context-param>
> However, this needs a real solution.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message