[Pkg-drupal-commits] r2038 - in /branches/drupal6/debian: changelog patches/00list patches/20_xss.dpatch
luigi at users.alioth.debian.org
luigi at users.alioth.debian.org
Tue Jun 2 00:20:41 UTC 2009
Author: luigi
Date: Tue Jun 2 00:20:41 2009
New Revision: 2038
URL: http://svn.debian.org/wsvn/pkg-drupal/?sc=1&rev=2038
Log:
Acknowledge NMU
Added:
branches/drupal6/debian/patches/20_xss.dpatch
Modified:
branches/drupal6/debian/changelog
branches/drupal6/debian/patches/00list
Modified: branches/drupal6/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-drupal/branches/drupal6/debian/changelog?rev=2038&op=diff
==============================================================================
--- branches/drupal6/debian/changelog (original)
+++ branches/drupal6/debian/changelog Tue Jun 2 00:20:41 2009
@@ -1,3 +1,10 @@
+drupal6 (6.11-1.1) unstable; urgency=high
+
+ * Non-maintainer upload by the Security Team.
+ * Fix several XSS issues (SA-CORE-2009-006; Closes: #529190).
+
+ -- Nico Golde <nion at debian.org> Thu, 28 May 2009 20:45:35 +0200
+
drupal6 (6.11-1) unstable; urgency=low
[ Luigi Gangitano ]
Modified: branches/drupal6/debian/patches/00list
URL: http://svn.debian.org/wsvn/pkg-drupal/branches/drupal6/debian/patches/00list?rev=2038&op=diff
==============================================================================
--- branches/drupal6/debian/patches/00list (original)
+++ branches/drupal6/debian/patches/00list Tue Jun 2 00:20:41 2009
@@ -1,1 +1,2 @@
10_cronjob
+20_xss
Added: branches/drupal6/debian/patches/20_xss.dpatch
URL: http://svn.debian.org/wsvn/pkg-drupal/branches/drupal6/debian/patches/20_xss.dpatch?rev=2038&op=file
==============================================================================
--- branches/drupal6/debian/patches/20_xss.dpatch (added)
+++ branches/drupal6/debian/patches/20_xss.dpatch Tue Jun 2 00:20:41 2009
@@ -1,0 +1,98 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 20_xss.dpatch by Nico Golde <nion at debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Fix SA-CORE-2009-006
+
+ at DPATCH@
+diff -urNad drupal6-6.11~/includes/theme.inc drupal6-6.11/includes/theme.inc
+--- drupal6-6.11~/includes/theme.inc 2009-04-30 02:13:30.000000000 +0200
++++ drupal6-6.11/includes/theme.inc 2009-05-28 20:29:17.000000000 +0200
+@@ -688,7 +688,7 @@
+ // restore path_to_theme()
+ $theme_path = $temp;
+ // Add final markup to the full page.
+- if ($hook == 'page') {
++ if ($hook == 'page' || $hook == 'book_export_html') {
+ $output = drupal_final_markup($output);
+ }
+ return $output;
+diff -urNad drupal6-6.11~/modules/book/book-export-html.tpl.php drupal6-6.11/modules/book/book-export-html.tpl.php
+--- drupal6-6.11~/modules/book/book-export-html.tpl.php 2007-11-04 15:29:09.000000000 +0100
++++ drupal6-6.11/modules/book/book-export-html.tpl.php 2009-05-28 20:29:17.000000000 +0200
+@@ -20,8 +20,8 @@
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+ <html xmlns="http://www.w3.org/1999/xhtml" lang="<?php print $language->language; ?>" xml:lang="<?php print $language->language; ?>">
+ <head>
+- <title><?php print $title; ?></title>
+ <?php print $head; ?>
++ <title><?php print $title; ?></title>
+ <base href="<?php print $base_url; ?>" />
+ <link type="text/css" rel="stylesheet" href="misc/print.css" />
+ <?php if ($language_rtl): ?>
+diff -urNad drupal6-6.11~/modules/taxonomy/taxonomy.module drupal6-6.11/modules/taxonomy/taxonomy.module
+--- drupal6-6.11~/modules/taxonomy/taxonomy.module 2009-04-27 13:49:05.000000000 +0200
++++ drupal6-6.11/modules/taxonomy/taxonomy.module 2009-05-28 20:29:17.000000000 +0200
+@@ -415,7 +415,7 @@
+ */
+ function taxonomy_form($vid, $value = 0, $help = NULL, $name = 'taxonomy') {
+ $vocabulary = taxonomy_vocabulary_load($vid);
+- $help = ($help) ? $help : $vocabulary->help;
++ $help = ($help) ? $help : filter_xss_admin($vocabulary->help);
+
+ if (!$vocabulary->multiple) {
+ $blank = ($vocabulary->required) ? t('- Please choose -') : t('- None selected -');
+@@ -514,7 +514,7 @@
+ $typed_string = taxonomy_implode_tags($terms, $vocabulary->vid) . (array_key_exists('tags', $terms) ? $terms['tags'][$vocabulary->vid] : NULL);
+ }
+ if ($vocabulary->help) {
+- $help = $vocabulary->help;
++ $help = filter_xss_admin($vocabulary->help);
+ }
+ else {
+ $help = t('A comma-separated list of terms describing this content. Example: funny, bungee jumping, "Company, Inc.".');
+@@ -538,7 +538,7 @@
+ $default_terms[$term->tid] = $term;
+ }
+ }
+- $form['taxonomy'][$vocabulary->vid] = taxonomy_form($vocabulary->vid, array_keys($default_terms), $vocabulary->help);
++ $form['taxonomy'][$vocabulary->vid] = taxonomy_form($vocabulary->vid, array_keys($default_terms), filter_xss_admin($vocabulary->help));
+ $form['taxonomy'][$vocabulary->vid]['#weight'] = $vocabulary->weight;
+ $form['taxonomy'][$vocabulary->vid]['#required'] = $vocabulary->required;
+ }
+@@ -1018,6 +1018,35 @@
+ return $terms[$tid];
+ }
+
++/**
++ * Create a select form element for a given taxonomy vocabulary.
++ *
++ * NOTE: This function expects input that has already been sanitized and is
++ * safe for display. Callers must properly sanitize the $title and
++ * $description arguments to prevent XSS vulnerabilities.
++ *
++ * @param $title
++ * The title of the vocabulary. This MUST be sanitized by the caller.
++ * @param $name
++ * Ignored.
++ * @param $value
++ * The currently selected terms from this vocabulary, if any.
++ * @param $vocabulary_id
++ * The vocabulary ID to build the form element for.
++ * @param $description
++ * Help text for the form element. This MUST be sanitized by the caller.
++ * @param $multiple
++ * Boolean to control if the form should use a single or multiple select.
++ * @param $blank
++ * Optional form choice to use when no value has been selected.
++ * @param $exclude
++ * Optional array of term ids to exclude in the selector.
++ * @return
++ * A FAPI form array to select terms from the given vocabulary.
++ *
++ * @see taxonomy_form()
++ * @see taxonomy_form_term()
++ */
+ function _taxonomy_term_select($title, $name, $value, $vocabulary_id, $description, $multiple, $blank, $exclude = array()) {
+ $tree = taxonomy_get_tree($vocabulary_id);
+ $options = array();
More information about the Pkg-drupal-commits
mailing list