This needs to be paired with the CssUrlRewritingProcessor for expected functionality.
It addresses a specific use case where a combination of pre/post processors are modifying URLs so that the ResourceAuthorizationManager no longer recognizes them to be retrieved from the classpath.
For example, assets stored in LESS variables are manipulated by both the CSS URL rewriter, which generates the first entry in the ResourceAuthorizationManager, and then the LESS compiler, which does not update the ResourceAuthorizationManager. This post processor simply adds any missing entries in ResourceAuthorizationManager for assets loaded from the classpath.
It should be noted that this processor exposes you to considerable risk if you use dynamic CSS provided by users, because it authorizes any and all asset loads if they are found in your CSS/LESS. It is not suitable for use in those conditions since it would allow users to retrieve any data from your classpath.
Adapted from {@link CssUrlRewritingProcessor} and {@link AbstractCssUrlRewritingProcessor} @author Greg Pendlebury @created June 10, 2014 @since 1.7.6
|
|
|
|
|
|