]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Merge branch 'faves' into 1.0.x
authorBrion Vibber <brion@pobox.com>
Thu, 17 Mar 2011 21:48:14 +0000 (14:48 -0700)
committerBrion Vibber <brion@pobox.com>
Thu, 17 Mar 2011 21:48:14 +0000 (14:48 -0700)
lib/action.php
lib/xmloutputter.php
plugins/Msn/extlib/phpmsnclass/msn.class.php

index 20de71aec1cf8f9ab980d40b897c4c44eb05a86a..654ec7aa43e533b6c94ca8ba8bfc580935c9357a 100644 (file)
@@ -100,10 +100,12 @@ class Action extends HTMLOutputter // lawsuit
     {
         if (Event::handle('StartShowHTML', array($this))) {
             $this->startHTML();
+            $this->flush();
             Event::handle('EndShowHTML', array($this));
         }
         if (Event::handle('StartShowHead', array($this))) {
             $this->showHead();
+            $this->flush();
             Event::handle('EndShowHead', array($this));
         }
         if (Event::handle('StartShowBody', array($this))) {
@@ -471,11 +473,14 @@ class Action extends HTMLOutputter // lawsuit
         $this->elementStart('div', array('id' => 'wrap'));
         if (Event::handle('StartShowHeader', array($this))) {
             $this->showHeader();
+            $this->flush();
             Event::handle('EndShowHeader', array($this));
         }
         $this->showCore();
+        $this->flush();
         if (Event::handle('StartShowFooter', array($this))) {
             $this->showFooter();
+            $this->flush();
             Event::handle('EndShowFooter', array($this));
         }
         $this->elementEnd('div');
@@ -695,14 +700,17 @@ class Action extends HTMLOutputter // lawsuit
         $this->elementStart('div', array('id' => 'site_nav_local_views_wrapper'));
         if (Event::handle('StartShowLocalNavBlock', array($this))) {
             $this->showLocalNavBlock();
+            $this->flush();
             Event::handle('EndShowLocalNavBlock', array($this));
         }
         if (Event::handle('StartShowContentBlock', array($this))) {
             $this->showContentBlock();
+            $this->flush();
             Event::handle('EndShowContentBlock', array($this));
         }
         if (Event::handle('StartShowAside', array($this))) {
             $this->showAside();
+            $this->flush();
             Event::handle('EndShowAside', array($this));
         }
         $this->elementEnd('div');
index 15b18e7d90738f8ac3a348dd1b41931396d6c339..528f633050570c54b939ebed2b73f513a9a63d10 100644 (file)
@@ -242,4 +242,15 @@ class XMLOutputter
     {
         $this->xw->writeComment($txt);
     }
+
+    /**
+     * Flush output buffers
+     *
+     * @return void
+     */
+
+    function flush()
+    {
+        $this->xw->flush();
+    }
 }
index 996c5571c20bd2c0a29458b7b1a00ef654f2e97b..3d10c25b2c2ce5cba68bc1fe8d4b70da0f67a7be 100644 (file)
@@ -2995,8 +2995,37 @@ X-OIM-Sequence-Num: 1
 \r
         // no ticket found!\r
         if (count($matches) == 0) {\r
-            $this->debug_message('*** Could not get passport ticket!');\r
-            return false;\r
+            // Since 2011/2/15, the return value will be Compact2, not PPToken2\r
+\r
+            // we need ticket and secret code\r
+            // RST1: messengerclear.live.com\r
+            // <wsse:BinarySecurityToken Id="Compact1">t=tick&p=</wsse:BinarySecurityToken>\r
+            // <wst:BinarySecret>binary secret</wst:BinarySecret>\r
+            // RST2: messenger.msn.com\r
+            // <wsse:BinarySecurityToken Id="PPToken2">t=tick</wsse:BinarySecurityToken>\r
+            // RST3: contacts.msn.com\r
+            // <wsse:BinarySecurityToken Id="Compact3">t=tick&p=</wsse:BinarySecurityToken>\r
+            // RST4: messengersecure.live.com\r
+            // <wsse:BinarySecurityToken Id="Compact4">t=tick&p=</wsse:BinarySecurityToken>\r
+            // RST5: spaces.live.com\r
+            // <wsse:BinarySecurityToken Id="Compact5">t=tick&p=</wsse:BinarySecurityToken>\r
+            // RST6: storage.msn.com\r
+            // <wsse:BinarySecurityToken Id="Compact6">t=tick&p=</wsse:BinarySecurityToken>\r
+            preg_match("#".\r
+                       "<wsse\:BinarySecurityToken Id=\"Compact1\">(.*)</wsse\:BinarySecurityToken>(.*)".\r
+                       "<wst\:BinarySecret>(.*)</wst\:BinarySecret>(.*)".\r
+                       "<wsse\:BinarySecurityToken Id=\"Compact2\">(.*)</wsse\:BinarySecurityToken>(.*)".\r
+                       "<wsse\:BinarySecurityToken Id=\"Compact3\">(.*)</wsse\:BinarySecurityToken>(.*)".\r
+                       "<wsse\:BinarySecurityToken Id=\"Compact4\">(.*)</wsse\:BinarySecurityToken>(.*)".\r
+                       "<wsse\:BinarySecurityToken Id=\"Compact5\">(.*)</wsse\:BinarySecurityToken>(.*)".\r
+                       "<wsse\:BinarySecurityToken Id=\"Compact6\">(.*)</wsse\:BinarySecurityToken>(.*)".\r
+                       "#",\r
+                       $data, $matches);\r
+            // no ticket found!\r
+            if (count($matches) == 0) {\r
+                $this->debug_message("*** Can't get passport ticket!");\r
+                return false;\r
+            }\r
         }\r
 \r
         //$this->debug_message(var_export($matches, true));\r