You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Phill Ashworth (Updated) (JIRA)" <ji...@apache.org> on 2012/01/23 11:30:40 UTC
[jira] [Updated] (WICKET-4222) CryptoMapper - Error decoding text,
exception thrown for links in markup
[ https://issues.apache.org/jira/browse/WICKET-4222?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Phill Ashworth updated WICKET-4222:
-----------------------------------
Attachment: cryptoMapperQs2.tgz
Quickstart showing decryption exceptions.
> CryptoMapper - Error decoding text, exception thrown for links in markup
> ------------------------------------------------------------------------
>
> Key: WICKET-4222
> URL: https://issues.apache.org/jira/browse/WICKET-4222
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.5.2, 1.5.3
> Reporter: Phill Ashworth
> Assignee: Igor Vaynberg
> Labels: crypto, urls, wicket
> Fix For: 1.5.4, 6.0.0
>
> Attachments: cryptoMapperQs.tgz, cryptoMapperQs2.tgz
>
>
> When CryptoMapper is used an exception is thrown for any links in the page markup such as images and stylesheets.
> Can be replicate with this init() and a standard quickstart.
> public void init() {
> super.init();
> getSecuritySettings().setCryptFactory(new KeyInSessionSunJceCryptFactory());
> setRootRequestMapper(new CryptoMapper(getRootRequestMapper(), this));
> }
> HomePage.html
> <img src="logo.png" width="50px" height="50px" alt="Wicket Logo" />
> ERROR - AbstractCrypt - Error decoding text: logo.png
> java.lang.RuntimeException: Unable to decrypt the text '??(?x'
> at org.apache.wicket.util.crypt.AbstractCrypt.decryptByteArray(AbstractCrypt.java:150)
> at org.apache.wicket.util.crypt.AbstractCrypt.decryptUrlSafe(AbstractCrypt.java:66)
> at org.apache.wicket.request.mapper.CryptoMapper.decryptUrl(CryptoMapper.java:159)
> at org.apache.wicket.request.mapper.CryptoMapper.mapRequest(CryptoMapper.java:102)
> at org.apache.wicket.request.cycle.RequestCycle.resolveRequestHandler(RequestCycle.java:181)
> at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:206)
> at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:280)
> at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:162)
> at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:218)
> ..snip
> Caused by: javax.crypto.IllegalBlockSizeException: Input length must be multiple of 8 when decrypting with padded cipher
> at com.sun.crypto.provider.SunJCE_f.b(DashoA13*..)
> at com.sun.crypto.provider.SunJCE_f.b(DashoA13*..)
> at com.sun.crypto.provider.SunJCE_ab.b(DashoA13*..)
> at com.sun.crypto.provider.PBEWithMD5AndDESCipher.engineDoFinal(DashoA13*..)
> at javax.crypto.Cipher.doFinal(DashoA13*..)
> at org.apache.wicket.util.crypt.SunJceCrypt.crypt(SunJceCrypt.java:94)
> at org.apache.wicket.util.crypt.AbstractCrypt.decryptByteArray(AbstractCrypt.java:146)
> ... 32 more
> ERROR - CryptoMapper - Error decrypting URL
> java.lang.IllegalArgumentException: Argument 'url' may not be null.
> at org.apache.wicket.util.lang.Args.notNull(Args.java:41)
> at org.apache.wicket.request.Url.parse(Url.java:127)
> at org.apache.wicket.request.mapper.CryptoMapper.decryptUrl(CryptoMapper.java:160)
> at org.apache.wicket.request.mapper.CryptoMapper.mapRequest(CryptoMapper.java:102)
> at org.apache.wicket.request.cycle.RequestCycle.resolveRequestHandler(RequestCycle.java:181)
> at org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:206)
> at org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:280)
> at org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:162)
> at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:218)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira