[ 
https://issues.apache.org/jira/browse/SLING-7525?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16396924#comment-16396924
 ] 

Antonio Sanso commented on SLING-7525:
--------------------------------------

I can reproduce. Thanks a lot [~orlowska]

> Content-Type missing after applying the ContentDispositionFilter twice
> ----------------------------------------------------------------------
>
>                 Key: SLING-7525
>                 URL: https://issues.apache.org/jira/browse/SLING-7525
>             Project: Sling
>          Issue Type: Bug
>    Affects Versions: Security 1.1.8, Security 1.1.10
>            Reporter: Orlowska
>            Assignee: Antonio Sanso
>            Priority: Major
>
> The issue started with the SLING-7219.
> When the {{ContentDispositionFilter}} is called twice (as a request filter 
> and as a forward filter) on a single request then the {{Content-Type}} is not 
> propagated and missing in the Response.
>  
> On the second pass in the {{setContentType()}} the condition [1]
> {code:java}
> if (previousContentType != null && previousContentType.equals(type)){code}
> will be fulfilled so the [2]
> {code:java}
> super.setContentType(type);{code}
> will not be called.
>  
> [1] 
> [https://github.com/apache/sling-org-apache-sling-security/blob/master/src/main/java/org/apache/sling/security/impl/ContentDispositionFilter.java#L208]
> [2] 
> [https://github.com/apache/sling-org-apache-sling-security/blob/master/src/main/java/org/apache/sling/security/impl/ContentDispositionFilter.java#L253]



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to