secure_auth_redirect

secure_auth_redirect

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: wordpress-6.5.2

apply_filters('secure_auth_redirect') is found 1 times:

  • /wp-includes/pluggable.php line 1190
    		 * @since 3.1.0
    		 *
    		 * @param bool $secure Whether to use a secure authentication redirect. Default false.
    		 */
    		$secure = apply_filters( 'secure_auth_redirect', $secure );
    
    		// If https is required and request is http, redirect.
    		if ( $secure && ! is_ssl() && str_contains( $_SERVER['REQUEST_URI'], 'wp-admin' ) ) {
    			if ( str_starts_with( $_SERVER['REQUEST_URI'], 'http' ) ) {
    				wp_redirect( set_url_scheme( $_SERVER['REQUEST_URI'], 'https' ) );
    				exit;