James Moger
2014-11-04 b5010f9f54ae2d32cf1c86e7b7129aa2d6633053
Whitelist the "target" link attribute in the XSS filter
2 files modified
4 ■■■ changed files
releases.moxie 2 ●●●●● patch | view | raw | blame | history
src/main/java/com/gitblit/utils/JSoupXssFilter.java 2 ●●● patch | view | raw | blame | history
releases.moxie
@@ -18,6 +18,7 @@
    - Fix exception when viewing a ticket with a patchset where the integration branch does not exist (issue-521, ticket-212)
    - Fix exception when deleting a repository using the FileTicketService (issue-522, ticket-213)
    - Do not inject team repository permissions as explicit user permissoins when editing a user (issue-462, ticket-214)
    - Whitelist the target link attribute in the XSS filter (ticket-216)
    changes:
    - Replaced Dagger with Guice (ticket-80)
    - Use release name as root directory in Gitblit GO artifacts (ticket-109)
@@ -41,6 +42,7 @@
    - Florian Zschocke
    - Paul Martin
    - razzard
    - Alexander Zabluda
}
#
src/main/java/com/gitblit/utils/JSoupXssFilter.java
@@ -73,7 +73,7 @@
                "sub", "sup", "table", "tbody", "td", "tfoot", "th", "thead", "tr", "tt", "u",
                "ul", "var")
        .addAttributes("a", "class", "href", "style", "title")
        .addAttributes("a", "class", "href", "style", "target", "title")
        .addAttributes("blockquote", "cite")
        .addAttributes("col", "span", "width")
        .addAttributes("colgroup", "span", "width")