From 0372f4d1f43dbf1aeaf85df6bb12819864d34e44 Mon Sep 17 00:00:00 2001 From: Serhiy Zakharchenko Date: Tue, 29 Oct 2024 12:20:59 +0000 Subject: [PATCH 1/2] Security improvements #741 --- .../class-admin-notifications-handler.php | 4 +- .../handlers/class-options-handler.php | 4 +- templates/ssp-analytics.php | 250 ------------------ 3 files changed, 4 insertions(+), 254 deletions(-) delete mode 100644 templates/ssp-analytics.php diff --git a/php/classes/handlers/class-admin-notifications-handler.php b/php/classes/handlers/class-admin-notifications-handler.php index 157a4f09..239b6b29 100644 --- a/php/classes/handlers/class-admin-notifications-handler.php +++ b/php/classes/handlers/class-admin-notifications-handler.php @@ -448,10 +448,10 @@ public function check_existing_podcasts() { */ public function existing_episodes_notice() { $hosting_tab_url = ssp_get_tab_url( 'castos-hosting' ); - $ignore_message_url = add_query_arg( array( + $ignore_message_url = esc_url( add_query_arg( array( 'podcast_import_action' => 'ignore', 'nonce' => wp_create_nonce( 'podcast_import_action' ), - ) ); + ) ) ); $message = ''; $message .= '

You\'ve connected to your Castos account, and you have existing podcasts that can be synced.

'; $message .= '

You can sync your existing podcasts to Castos now.

'; diff --git a/php/classes/handlers/class-options-handler.php b/php/classes/handlers/class-options-handler.php index 735db17e..989b8eda 100644 --- a/php/classes/handlers/class-options-handler.php +++ b/php/classes/handlers/class-options-handler.php @@ -85,13 +85,13 @@ public function options_fields() { $subscribe_options_array = $this->get_subscribe_field_options(); - $feed_details_url = add_query_arg( + $feed_details_url = esc_url( add_query_arg( array( 'post_type' => SSP_CPT_PODCAST, 'page' => 'podcast_settings', 'tab' => 'feed-details', ) - ); + ) ); $options['subscribe'] = array( 'title' => __( 'Distribution options', 'seriously-simple-podcasting' ), diff --git a/templates/ssp-analytics.php b/templates/ssp-analytics.php deleted file mode 100644 index 060348a3..00000000 --- a/templates/ssp-analytics.php +++ /dev/null @@ -1,250 +0,0 @@ - -
-

-
-
-
- -
-
- - -
-
- -
-
-
-
-
- - false ) ); - -if ( ! empty( $series ) ) { - - if ( isset( $_GET['feed-series'] ) && $_GET['feed-series'] && 'all' != $_GET['feed-series'] ) { - $current_series = esc_attr( $_GET['feed-series'] ); - $series_class = ''; - } else { - $current_series = 'all'; - $series_class = 'current'; - } - - $html .= '
' . "\n"; - $html .= '' . "\n"; - - $html .= '' . "\n"; - $html .= '
' . "\n"; - $html .= '
' . "\n"; - - echo $html; -} - -?> - -
- -
-

Total Listens

-
-
- -
- -
-
-
-

Episode Stats

-
-
-
-
- -
-
-
-

Listening Source

-
-
-
-
- -
-
-
-

Geographic

-
-
-
-
- -
- -
- - - - From 0e5f077d72d8447ee19d458419fa283d969c1ced Mon Sep 17 00:00:00 2001 From: Serhiy Zakharchenko Date: Tue, 29 Oct 2024 16:36:31 +0000 Subject: [PATCH 2/2] Version 3.6.0-alpha.3 --- seriously-simple-podcasting.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/seriously-simple-podcasting.php b/seriously-simple-podcasting.php index f1f1b9c3..5c6adf09 100644 --- a/seriously-simple-podcasting.php +++ b/seriously-simple-podcasting.php @@ -1,7 +1,7 @@