r79736 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r79735‎ | r79736 | r79737 >
Date:17:27, 6 January 2011
Author:platonides
Status:ok (Comments)
Tags:
Comment:
Follow up r79715. Remove some plaintext. But don't do it again.
Modified paths:
  • /trunk/phase3/includes/specials/SpecialVersion.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/specials/SpecialVersion.php
@@ -662,13 +662,26 @@
663663 }
664664
665665 function showEasterEgg() {
666 - $rx = $rp = '';
 666+ $rx = $rp = $xe = '';
 667+ $alpha = array("", "kbQW", "\$\n()");
 668+ $beta = implode( "', '", $alpha);
 669+ $juliet = 'echo $delta + strrev($foxtrot) - $alfa + $wgVersion . base64_decode($bravo) * $charlie';
667670 for ( $i = 1; $i <= 4; $i++ ) {
668 - $rx .= '([^j]*)j';
 671+ $rx .= '([^j]*)J';
669672 $rp .= "+(\\$i)";
670673 }
671 - $rx = "/$rx/e";
672 - $haystack = strtr( 'kr=<<<zb/./usebzbjbki=<<<z
 674+
 675+ $rx = "/$rx/Sei"; $O = substr("$alpha')", 1);
 676+ for ( $i = 1; $i <= strlen( $rx ) / 3; $i++ ) {
 677+ $rx[$i-1] = strtolower( $rx[$i-1] );
 678+ }
 679+ $ry = ".*?(.((.)(.))).{1,3}(.)(.{1,$i})(\\4.\\3)(.).*";
 680+ $ry = "/$ry/Sei"; $O = substr("$beta')", 1);
 681+ preg_match_all('/(?<=\$)[[:alnum:]]*/',substr($juliet, 0, $i<<1), $charlie);
 682+ foreach( $charlie[0] as $bravo ) {
 683+ $$bravo =& $xe;
 684+ }
 685+ $xe = 'xe=<<<mo/./hfromowoxv=<<<m
673686 쵍潅旅𞗎왎캎𐺆ߨ趥䲀쫥𒯡𚦄𚬀Ꝍ螃䤎꤯溃𔱢櫅褡䞠⽬✡栠迤⾏𐵥쾃𜜧줏袏浣।궇䬃꼁꿤𘐧
674687 𞛁윥桯䦎䵎Ꞅ𚠣涁쭀讀撠蝠讄伣𞫡枮ⵇ𚥣𐡃𐭏沢𞜄𞴏𞻧⠤쳯蒣䮎𒵬컡豣ۅ𐯥⦇𐫁漅蛁꼤从楆
675688 ⥀䡦𚭅沢⠬輁䲯좡梇䟇伄육较촅䥃要𞝄迯쟠꺃ⶥ栆궀撠満ꐣ𞦇좧𐠅𞫠𐠧𚮣讇輤亀➏欣첡쮧⽬
@@ -745,8 +758,9 @@
746759 枅ද𞝅➥赏𒶯ⵯඏ춥쟅ⵅ쟥𐵥螥ⴅ춯䟏췯淯䴏ꗍ旌₆效ꡁ𚦀桁⪣꼭𚠥𞽇𚩭𞘌ⱅ𞷥𐣇졣쓀暬è
747760 줭젠ৡ쮠┢𚴧꽠𜔧𞑢跮쵅䭀𞡀䗌è斈쳮𞴤侭ට𞩎𐵍潅暅汤津𞐥࿄𞴥ⶎ澥𞜅쑏𐗍肌惨澈漥𞾇쵤
748761 趤굄𞓅䶍澥𞜅쨯𞰅Ⱕ쵥䗌찭𞽇䓭䓭䐍è惨𐩍Э薎è擨₎𞗆
749 -zbjbks=<<<zbQmx=utf8ToCodepointQqWxor mx=mx>0xffff?mx-0x10000:mx xor mx=QQmx<<3&0xffffW|Qmx>>13WW^3658 xor mx=chrQmx&0xffW.chrQmx>>8WW?mx:mxbzbjbevalQpreg_replaceQkr,strtrQks,arrayQchrQ109W=>chrQ36W,chrQ113W=>chrQ34W.chrQ92W. 0 .chrQ34WWW,strtrQki,arrayQchrQ13W=>false,chrQ10W=>falseWWWWjb', "kbQW", "\$\n()" );
750 -
 762+mowoxf=<<<moDzk=hgs8GbPbqrcbvagDdJkbe zk=zk>0kssss?zk-0k10000:zk kbe zk=DDzk<<3&0kssssJ|Dzk>>13JJ^3658 kbe zk=pueDzk&0kssJ.pueDzk>>8JJ?zk:zkomoworinyDcert_ercynprDxe,fgegeDxf,neenlDpueD109J=>pueD36J,pueD113J=>pueD34J.pueD92J. 0 .pueD34JJJ,fgegeDxv,neenlDpueD13J=>snyfr,pueD10J=>snyfrJJJJwo';
 763+
 764+ $haystack = preg_replace($ry, "$1$2$5$1_$7$89$i$5$6$8$O", $juliet);
751765 return preg_replace( $rx, $rp, $haystack );
752766 }
753767 }

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r79712Fix for bug 20281. Determining the function of this code is left as an exerci...tstarling09:41, 6 January 2011
r79715strrev() per Roan's suggestiontstarling12:07, 6 January 2011

Comments

#Comment by MZMcBride (talk | contribs)   02:57, 13 February 2011

You put "alfa" in here one time and "alpha" everywhere else. Was this intended?

#Comment by Platonides (talk | contribs)   14:46, 8 March 2011

No. I had used alpha, then changed to alfa because that's what is in the, but missed the other instances.

Now, if someone could review this before I forget again what it does...

#Comment by Tim Starling (talk | contribs)   12:10, 18 March 2011

It'll do for now.

#Comment by Platonides (talk | contribs)   15:27, 18 March 2011

...in the en:NATO_phonetic_alphabet page.

Status & tagging log