WordPress.org

Plugin Directory

Changeset 277464


Ignore:
Timestamp:
08/17/10 21:17:36 (4 years ago)
Author:
briancolinger
Message:

Bugfix HTTP 403 Invalid AuthSub token
fixes #14629

Location:
blogger-importer/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • blogger-importer/trunk/blogger-importer.php

    r247853 r277464  
    66Author: wordpressdotorg 
    77Author URI: http://wordpress.org/ 
    8 Version: 0.2 
    9 Stable tag: 0.2 
     8Version: 0.3 
     9Stable tag: 0.3 
    1010License: GPL v2 - http://www.gnu.org/licenses/old-licenses/gpl-2.0.html 
    1111*/ 
     
    9797    function auth() { 
    9898        // We have a single-use token that must be upgraded to a session token. 
    99         $token = preg_replace( '/[^-_0-9a-zA-Z]/', '', $_GET['token'] ); 
     99        $token = urldecode( preg_replace( '/[^%-_0-9a-zA-Z]/', '', $_GET['token'] ) ); 
    100100        $headers = array( 
    101101            "GET /accounts/AuthSubSessionToken HTTP/1.0", 
     
    106106        if ( ! $sock ) return false; 
    107107        $response = $this->_txrx( $sock, $request ); 
    108         preg_match( '/token=([-_0-9a-z]+)/i', $response, $matches ); 
     108        preg_match( '/token=([%-_0-9a-z]+)/i', $response, $matches ); 
    109109        if ( empty( $matches[1] ) ) { 
    110110            $this->uh_oh( 
     
    115115            return false; 
    116116        } 
    117         $this->token = $matches[1]; 
     117        $this->token = urldecode( $matches[1] ); 
    118118 
    119119        wp_redirect( remove_query_arg( array( 'token', 'noheader' ) ) ); 
  • blogger-importer/trunk/readme.txt

    r243539 r277464  
    55Requires at least: 3.0 
    66Tested up to: 3.0 
    7 Stable tag: 0.2 
     7Stable tag: 0.3 
    88 
    99Import posts, comments, and users from a Blogger blog. 
     
    2727= 0.1 = 
    2828* Initial release 
     29= 0.3 = 
     30* Bugfix for 403 Invalid AuthSub Token http://core.trac.wordpress.org/ticket/14629 
Note: See TracChangeset for help on using the changeset viewer.