svn: /pear/packages/Bugtracker/trunk/site/ bug.php report.php search.php
| From: | Jani Taskinen | Date: | Mon, 01 Mar 2010 19:08:32 +0000 |
| Subject: | svn: /pear/packages/Bugtracker/trunk/site/ bug.php report.php search.php | ||
| Groups: | php.pear.cvs php.pear.core | ||
| Request: | Send a blank email to pear-core+get-9228@lists.php.net to get a copy of this message | ||
jani Mon, 01 Mar 2010 19:08:32 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=295677
Log:
- Fix some xss issues found by Rasmus
Changed paths:
U pear/packages/Bugtracker/trunk/site/bug.php
U pear/packages/Bugtracker/trunk/site/report.php
U pear/packages/Bugtracker/trunk/site/search.php
Modified: pear/packages/Bugtracker/trunk/site/bug.php
===================================================================
--- pear/packages/Bugtracker/trunk/site/bug.php 2010-03-01 18:58:30 UTC (rev 295676)
+++ pear/packages/Bugtracker/trunk/site/bug.php 2010-03-01 19:08:32 UTC (rev 295677)
@@ -822,7 +822,7 @@
<tr>
<th class="details">Y<span class="accesskey">o</span>ur
email address:<br /><strong>MUST BE VALID</strong></th>
<td class="form-input">
- <input type="text" size="40" maxlength="40"
name="in[commentemail]" value="<?php echo
isset($_POST['in']['commentemail']) ?
htmlspecialchars($_POST['in']['commentemail']) : ''; ?>"
accesskey="o" />
+ <input type="text" size="40" maxlength="40"
name="in[commentemail]" value="<?php echo
isset($_POST['in']['commentemail']) ?
htmlspecialchars($_POST['in']['commentemail'], ENT_COMPAT, 'UTF-8') :
''; ?>" accesskey="o" />
</td>
</tr>
<tr>
Modified: pear/packages/Bugtracker/trunk/site/report.php
===================================================================
--- pear/packages/Bugtracker/trunk/site/report.php 2010-03-01 18:58:30 UTC (rev 295676)
+++ pear/packages/Bugtracker/trunk/site/report.php 2010-03-01 19:08:32 UTC (rev 295677)
@@ -357,7 +357,7 @@
<?php } else { ?>
<th class="form-label_left">Y<span
class="accesskey">o</span>ur email address:<br /><strong>MUST BE
VALID</strong></th>
<td class="form-input">
- <input type="text" size="20" maxlength="40"
name="in[email]" value="<?php echo
htmlspecialchars($_POST['in']['email']); ?>" accesskey="o"
/>
+ <input type="text" size="20" maxlength="40"
name="in[email]" value="<?php echo
htmlspecialchars($_POST['in']['email'], ENT_COMPAT, 'UTF-8');
?>" accesskey="o" />
</td>
</th>
<?php } ?>
@@ -366,7 +366,7 @@
<tr>
<th class="form-label_left"><span
class="accesskey">P</span>assword:</th>
<td class="form-input">
- <input type="password" size="20" maxlength="20"
name="in[passwd]" value="<?php echo
htmlspecialchars($_POST['in']['passwd']);?>" accesskey="p"
/><br />
+ <input type="password" size="20" maxlength="20"
name="in[passwd]" value="<?php echo
htmlspecialchars($_POST['in']['passwd'], ENT_COMPAT,
'UTF-8');?>" accesskey="p" /><br />
You <b>must</b> enter any password here, which will be stored for this bug
report.<br />
This password allows you to come back and modify your submitted bug report at a later date.
[<a href="bug-pwd-finder.php">Lost a bug password?</a>]
@@ -403,14 +403,14 @@
<tr>
<th class="form-label_left">Operating system:</th>
<td class="form-input">
- <input type="text" size="20" maxlength="32"
name="in[php_os]" value="<?php echo
htmlspecialchars($_POST['in']['php_os']); ?>" />
+ <input type="text" size="20" maxlength="32"
name="in[php_os]" value="<?php echo
htmlspecialchars($_POST['in']['php_os'], ENT_COMPAT, 'UTF-8');
?>" />
</td>
</tr>
<tr>
<th class="form-label_left">Summary:</th>
<td class="form-input">
- <input type="text" size="40" maxlength="79"
name="in[sdesc]" value="<?php echo
htmlspecialchars($_POST['in']['sdesc']); ?>" />
+ <input type="text" size="40" maxlength="79"
name="in[sdesc]" value="<?php echo
htmlspecialchars($_POST['in']['sdesc'], ENT_COMPAT, 'UTF-8');
?>" />
</td>
</tr>
@@ -438,7 +438,7 @@
</p>
</th>
<td class="form-input">
- <textarea cols="80" rows="15" name="in[ldesc]"
wrap="physical"><?php echo
htmlspecialchars($_POST['in']['ldesc']); ?></textarea>
+ <textarea cols="80" rows="15" name="in[ldesc]"
wrap="physical"><?php echo
htmlspecialchars($_POST['in']['ldesc'], ENT_COMPAT, 'UTF-8');
?></textarea>
</td>
</tr>
<tr>
@@ -452,7 +452,7 @@
</p>
</th>
<td class="form-input">
- <textarea cols="80" rows="15" name="in[repcode]"
wrap="no"><?php echo htmlspecialchars($_POST['in']['repcode']);
?></textarea>
+ <textarea cols="80" rows="15" name="in[repcode]"
wrap="no"><?php echo htmlspecialchars($_POST['in']['repcode'],
ENT_COMPAT, 'UTF-8'); ?></textarea>
</td>
</tr>
<?php
@@ -469,7 +469,7 @@
</p>
</th>
<td class="form-input">
- <textarea cols="80" rows="15" name="in[expres]"
wrap="physical"><?php echo
htmlspecialchars($_POST['in']['expres']); ?></textarea>
+ <textarea cols="80" rows="15" name="in[expres]"
wrap="physical"><?php echo
htmlspecialchars($_POST['in']['expres'], ENT_COMPAT, 'UTF-8');
?></textarea>
</td>
</tr>
@@ -482,7 +482,7 @@
</p>
</th>
<td class="form-input">
- <textarea cols="80" rows="15" name="in[actres]"
wrap="physical"><?php echo
htmlspecialchars($_POST['in']['actres']); ?></textarea>
+ <textarea cols="80" rows="15" name="in[actres]"
wrap="physical"><?php echo
htmlspecialchars($_POST['in']['actres'], ENT_COMPAT, 'UTF-8');
?></textarea>
</td>
</tr>
Modified: pear/packages/Bugtracker/trunk/site/search.php
===================================================================
--- pear/packages/Bugtracker/trunk/site/search.php 2010-03-01 18:58:30 UTC (rev 295676)
+++ pear/packages/Bugtracker/trunk/site/search.php 2010-03-01 19:08:32 UTC (rev 295677)
@@ -173,7 +173,7 @@
<tr valign="top">
<th>Find bugs</th>
<td style="white-space: nowrap">with all or any of the w<span
class="accesskey">o</span>rds</td>
- <td style="white-space: nowrap"><input type="text"
name="search_for" value="<?php echo htmlspecialchars($search_for);?>"
size="20" maxlength="255" accesskey="o" /><br />
+ <td style="white-space: nowrap"><input type="text"
name="search_for" value="<?php echo htmlspecialchars($search_for, ENT_COMPAT,
'UTF-8'); ?>" size="20" maxlength="255"
accesskey="o" /><br />
<small>
<?php show_boolean_options($boolean_search) ?>
(<a href="search-howto.php" target="_new">?</a>)
@@ -227,19 +227,19 @@
<th>OS</th>
<td style="white-space: nowrap">Return bugs with <b>operating
system</b></td>
<td>
- <input type="text" name="php_os" value="<?php echo
htmlspecialchars($php_os);?>" />
+ <input type="text" name="php_os" value="<?php echo
htmlspecialchars($php_os, ENT_COMPAT, 'UTF-8'); ?>" />
<input style="vertical-align:middle;" type="checkbox"
name="php_os_not" value="1" <?php echo ($php_os_not == 'not') ?
'checked="checked"' : ''; ?>" /> NOT
</td>
</tr>
<tr valign="top">
<th>PHP Version</th>
<td style="white-space: nowrap">Return bugs reported with <b>PHP
version</b></td>
- <td><input type="text" name="phpver" value="<?php echo
htmlspecialchars($phpver);?>" /></td>
+ <td><input type="text" name="phpver" value="<?php echo
htmlspecialchars($phpver, ENT_COMPAT, 'UTF-8'); ?>" /></td>
</tr>
<tr valign="top">
<th>Assigned</th>
<td style="white-space: nowrap">Return bugs <b>assigned</b>
to</td>
- <td><input type="text" name="assign" value="<?php echo
htmlspecialchars($assign);?>" />
+ <td><input type="text" name="assign" value="<?php echo
htmlspecialchars($assign, ENT_COMPAT, 'UTF-8'); ?>" />
<?php
if (!empty($auth_user->handle)) {
$u = htmlspecialchars($auth_user->handle);
@@ -252,7 +252,7 @@
<tr valign="top">
<th>Author e<span class="accesskey">m</span>ail</th>
<td style="white-space: nowrap">Return bugs with author email</td>
- <td><input accesskey="m" type="text" name="author_email"
value="<?php echo htmlspecialchars($author_email); ?>" />
+ <td><input accesskey="m" type="text" name="author_email"
value="<?php echo htmlspecialchars($author_email, ENT_COMPAT, 'UTF-8');
?>" />
<?php
if (!empty($auth_user->handle)) {
$u = htmlspecialchars($auth_user->handle);