Making WordPress.org

Changeset 10973


Ignore:
Timestamp:
05/14/2021 01:40:37 AM (4 years ago)
Author:
dd32
Message:

Login: There's reports that login.wordpress.org can end up in an infinite loop redirecting to itself, try to catch it with some debugging data.

See https://wordpress.slack.com/archives/C02QB8GMM/p1620687204446100

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/common/includes/wporg-sso/class-wporg-sso.php

    r10889 r10973  
    213213            }
    214214
     215            // DEBUG - login.w.org redirecting to self?
     216            if (
     217                ! $_POST &&
     218                'login.wordpress.org' === $_SERVER['HTTP_HOST'] &&
     219                '/' === $_SERVER['REQUEST_URI'] &&
     220                'https://login.wordpress.org/' === $to
     221            ) {
     222                trigger_error( 'Login redirect to self: ' . var_export( [ __METHOD__, wp_debug_backtrace_summary(), $to, $_SERVER ], true ), E_USER_WARNING );
     223            }
     224
    215225            header(
    216226                'Location: ' . $to,
Note: See TracChangeset for help on using the changeset viewer.