From 910c3964164a3f2cd4b05d62ee1f3c2ca18325cd Mon Sep 17 00:00:00 2001 From: Dion Hulse Date: Wed, 30 Jul 2025 11:33:25 +1000 Subject: [PATCH] Don't URI encode the TOTP url for display. Fixes #710 Co-authored-by: fb656720 < 223508510 +fb656720@users.noreply.github.com> --- providers/class-two-factor-totp.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/providers/class-two-factor-totp.php b/providers/class-two-factor-totp.php index 88831185..d51e4ab3 100644 --- a/providers/class-two-factor-totp.php +++ b/providers/class-two-factor-totp.php @@ -255,7 +255,7 @@ public static function generate_qr_code_url( $user, $secret_key ) { * @param WP_User $user The user object. */ $totp_url = apply_filters( 'two_factor_totp_url', $totp_url, $user ); - $totp_url = esc_url( $totp_url, array( 'otpauth' ) ); + $totp_url = esc_url_raw( $totp_url, array( 'otpauth' ) ); return $totp_url; }