Plugin Directory

Changeset 2125602


Ignore:
Timestamp:
07/19/2019 06:26:50 AM (7 years ago)
Author:
tinycks
Message:

Author e-mail change

Location:
cloudbric-basic-ssl
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • cloudbric-basic-ssl/trunk/cloudbric-basic-ssl.php

    r1562588 r2125602  
    44Plugin URI:  https://wordpress.org/plugins/cloudbric-basic-ssl/
    55Description: fixed The Redirect Loop and Client IP address for Cloudbric.
    6 Version: 0.9.2
    7 Author: Tiny (kscho@pentasecurity.com)
     6Version: 0.9.3
     7Author: Tiny (tiny@cloudbric.com)
    88Author URI: https://www.cloudbric.com
    99License: GPLv2 or later
     
    1818
    1919    //fixed Client IP address
    20     if (isset($_SERVER['HTTP_X_FORWARDED_FOR']) && !empty($_SERVER['HTTP_X_FORWARDED_FOR'])) $_SERVER['REMOTE_ADDR'] = $_SERVER['HTTP_X_FORWARDED_FOR'];
     20    if (isset($_SERVER['HTTP_X_FORWARDED_FOR']) && !empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {
     21
     22        if (strpos($_SERVER['HTTP_X_FORWARDED_FOR'], ',')>0) {
     23            $addr = explode(",",$_SERVER['HTTP_X_FORWARDED_FOR']);
     24            $_SERVER['REMOTE_ADDR'] =  trim($addr[0]);
     25        } else {
     26            $_SERVER['REMOTE_ADDR'] = $_SERVER['HTTP_X_FORWARDED_FOR'];
     27        }
     28    }
    2129
    2230}
  • cloudbric-basic-ssl/trunk/readme.txt

    r1562588 r2125602  
    44Requires at least: 3.0
    55Tested up to: 4.7
    6 Stable tag: 0.9.2
     6Stable tag: 0.9.3
    77License: GPLv2 or later
    88License URI: https://www.gnu.org/licenses/gpl-2.0.html
     
    5353== Changelog ==
    5454
     55= 0.9.3 =
     56* handle HTTP_X_FORWARDED_FOR multiple ip.
     57* Wordpress version test.
     58
    5559= 0.9.2 =
    5660* readme.txt change.
Note: See TracChangeset for help on using the changeset viewer.