mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-03-28 17:42:57 +01:00
Merged revision(s) 26916 from trunk:
bug 3029: XSS on website_url comment form git-svn-id: http://piwigo.org/svn/branches/2.6@26919 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
@@ -147,6 +147,7 @@ SELECT COUNT(*) AS user_exists
|
||||
// website
|
||||
if (!empty($comm['website_url']))
|
||||
{
|
||||
$comm['website_url'] = strip_tags($comm['website_url']);
|
||||
if (!preg_match('/^https?/i', $comm['website_url']))
|
||||
{
|
||||
$comm['website_url'] = 'http://'.$comm['website_url'];
|
||||
@@ -351,6 +352,7 @@ function update_user_comment($comment, $post_key)
|
||||
// website
|
||||
if (!empty($comment['website_url']))
|
||||
{
|
||||
$comm['website_url'] = strip_tags($comm['website_url']);
|
||||
if (!preg_match('/^https?/i', $comment['website_url']))
|
||||
{
|
||||
$comment['website_url'] = 'http://'.$comment['website_url'];
|
||||
|
||||
Reference in New Issue
Block a user