WordPress.org

Make WordPress Core

Ticket #17052: basic_auth_for_wp_redirect.diff

File basic_auth_for_wp_redirect.diff, 504 bytes (added by david.binda, 7 years ago)
  • pluggable.php

     
    909909 * @return string redirect-sanitized URL
    910910 **/
    911911function wp_sanitize_redirect($location) {
    912         $location = preg_replace('|[^a-z0-9-~+_.?#=&;,/:%!]|i', '', $location);
     912        $location = preg_replace('|[^a-z0-9-~+_.?#=&;,/:%!\[\]@]|i', '', $location);
    913913        $location = wp_kses_no_null($location);
    914914
    915915        // remove %0d and %0a from location