Андрей (andy) wrote in changelog,
Андрей
andy
changelog

[livejournal] r19218: LJSUP-8979 (Need to block ebeded tags of...

Committer: ailyin
LJSUP-8979 (Need to block ebeded tags of social nexworks pluggins)
U   trunk/cgi-bin/cleanhtml.pl
Modified: trunk/cgi-bin/cleanhtml.pl
===================================================================
--- trunk/cgi-bin/cleanhtml.pl	2011-06-03 07:13:31 UTC (rev 19217)
+++ trunk/cgi-bin/cleanhtml.pl	2011-06-03 07:17:54 UTC (rev 19218)
@@ -1764,8 +1764,8 @@
             my $attrs = $token->[3]; # attribute names, in original order
 
             ## check the tag
-            if ($tag eq 'script') {
-                $p->get_tag('/script');
+            if ( $tag eq 'script' || $tag =~ /^(?:g|fb):/ ) {
+                $p->get_tag("/$tag");
                 next TOKEN;
             }
             if ($tag =~ /:set$/) {

Tags: andy, livejournal, pl
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments