Skip to content

Commit f8600e2

Browse files
authored
Merge pull request #188 from mailchimp/release/2.0.1
Release/2.0.1
2 parents fe739e8 + dbed272 commit f8600e2

File tree

11 files changed

+102
-20
lines changed

11 files changed

+102
-20
lines changed

CHANGELOG.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,17 @@ All notable changes to this project will be documented in this file, per [the Ke
44

55
## [Unreleased] - TBD
66

7+
## [2.0.1] - 2026-01-08
8+
9+
### Fixed
10+
11+
- Provide CSRF hardening for Mailchimp List changes (props [@iamdharmesh](https://github.com/iamdharmesh), [@joemcgill](https://github.com/joemcgill), [@dkotter](https://github.com/dkotter), [@qasumitbagthariya](https://github.com/qasumitbagthariya)).
12+
- Plugin check plugin errors to improve overall codebase (props [@iamdharmesh](https://github.com/iamdharmesh), [@joemcgill](https://github.com/joemcgill), [@dkotter](https://github.com/dkotter), [@qasumitbagthariya](https://github.com/qasumitbagthariya)).
13+
14+
### Changed
15+
16+
- Bump WordPress "tested up to" version 6.9 (props [@iamdharmesh](https://github.com/iamdharmesh), [@joemcgill](https://github.com/joemcgill), [@qasumitbagthariya](https://github.com/qasumitbagthariya)).
17+
718
## [2.0.0] - 2025-08-11
819

920
### Added
@@ -33,6 +44,12 @@ All notable changes to this project will be documented in this file, per [the Ke
3344

3445
- Update 10up-toolkit from 6.2.0 to 6.5.0 (props [@iamdharmesh](https://github.com/iamdharmesh), [@dkotter](https://github.com/dkotter) via [#174](https://github.com/mailchimp/wordpress/pull/174)).
3546

47+
## [1.9.1] - 2026-01-08
48+
49+
### Fixed
50+
51+
- Provide CSRF hardening for Mailchimp List changes (props [@iamdharmesh](https://github.com/iamdharmesh), [@joemcgill](https://github.com/joemcgill), [@dkotter](https://github.com/dkotter), [@qasumitbagthariya](https://github.com/qasumitbagthariya)).
52+
3653
## [1.9.0] - 2025-06-04
3754

3855
### Added
@@ -43,6 +60,13 @@ All notable changes to this project will be documented in this file, per [the Ke
4360

4461
- Improved the enqueueing of JavaScript scripts and styles (props [@iamdharmesh](https://github.com/iamdharmesh), [@dkotter](https://github.com/dkotter), [@qasumitbagthariya](https://github.com/qasumitbagthariya) via [#161](https://github.com/mailchimp/wordpress/pull/161)).
4562

63+
## [1.8.1] - 2026-01-08
64+
65+
### Fixed
66+
67+
- Provide CSRF hardening for Mailchimp List changes (props [@iamdharmesh](https://github.com/iamdharmesh), [@joemcgill](https://github.com/joemcgill), [@dkotter](https://github.com/dkotter), [@qasumitbagthariya](https://github.com/qasumitbagthariya)).
68+
69+
4670
## [1.8.0] - 2025-05-08
4771

4872
**Note that this release bumps the WordPress minimum version from 6.3 to 6.4.**
@@ -58,6 +82,12 @@ All notable changes to this project will be documented in this file, per [the Ke
5882
- Bump WordPress "tested up to" version 6.8 (props [@qasumitbagthariya](https://github.com/qasumitbagthariya), [@dkotter](https://github.com/dkotter) via [#148](https://github.com/mailchimp/wordpress/pull/148)).
5983
- Bump WordPress minimum supported version from 6.3 to 6.4 (props [@qasumitbagthariya](https://github.com/qasumitbagthariya), [@dkotter](https://github.com/dkotter) via [#148](https://github.com/mailchimp/wordpress/pull/148)).
6084

85+
## [1.7.1] - 2026-01-08
86+
87+
### Fixed
88+
89+
- Provide CSRF hardening for Mailchimp List changes (props [@iamdharmesh](https://github.com/iamdharmesh), [@joemcgill](https://github.com/joemcgill), [@dkotter](https://github.com/dkotter), [@qasumitbagthariya](https://github.com/qasumitbagthariya)).
90+
6191
## [1.7.0] - 2025-04-08
6292

6393
### Changed
@@ -91,6 +121,12 @@ All notable changes to this project will be documented in this file, per [the Ke
91121
- Update all third-party actions our workflows rely on to use versions based on specific commit hashes (props [@dkotter](https://github.com/dkotter), [@jeffpaul](https://github.com/jeffpaul), [@iamdharmesh](https://github.com/iamdharmesh) via [#128](https://github.com/mailchimp/wordpress/pull/128)).
92122
- Prevent overwriting the release content with the body text provided in the GitHub Action workflow file (props [@iamdharmesh](https://github.com/iamdharmesh), [@dkotter](https://github.com/dkotter) via [#129](https://github.com/mailchimp/wordpress/pull/129)).
93123

124+
## [1.6.4] - 2026-01-08
125+
126+
### Fixed
127+
128+
- Provide CSRF hardening for Mailchimp List changes (props [@iamdharmesh](https://github.com/iamdharmesh), [@joemcgill](https://github.com/joemcgill), [@dkotter](https://github.com/dkotter), [@qasumitbagthariya](https://github.com/qasumitbagthariya)).
129+
94130
## [1.6.3] - 2025-01-30
95131

96132
### Added
@@ -209,6 +245,13 @@ All notable changes to this project will be documented in this file, per [the Ke
209245
- Added ESLint GitHub Action Workflow (props [@dkotter](https://github.com/dkotter), [@jeffpaul](https://github.com/jeffpaul) via [#20](https://github.com/mailchimp/wordpress/pull/20)).
210246
- Added Standard GitHub Action Workflows (props [@dkotter](https://github.com/dkotter), [@jeffpaul](https://github.com/jeffpaul) via [#21](https://github.com/mailchimp/wordpress/pull/21)).
211247

248+
## 1.5.9 - 2026-01-08
249+
250+
### Fixed
251+
252+
- Provide CSRF hardening for Mailchimp List changes.
253+
254+
212255
## 1.5.8 - 2022-09-26
213256

214257
### Changed
@@ -352,10 +395,15 @@ All notable changes to this project will be documented in this file, per [the Ke
352395
- Security and various other improvements
353396

354397
[Unreleased]: https://github.com/mailchimp/wordpress/compare/main...develop
398+
[2.0.1]: https://github.com/mailchimp/wordpress/compare/2.0.0...2.0.1
355399
[2.0.0]: https://github.com/mailchimp/wordpress/compare/1.9.0...2.0.0
400+
[1.9.1]: https://github.com/mailchimp/wordpress/compare/1.9.0...1.9.1
356401
[1.9.0]: https://github.com/mailchimp/wordpress/compare/1.8.0...1.9.0
402+
[1.8.1]: https://github.com/mailchimp/wordpress/compare/1.8.0...1.8.1
357403
[1.8.0]: https://github.com/mailchimp/wordpress/compare/1.7.0...1.8.0
404+
[1.7.1]: https://github.com/mailchimp/wordpress/compare/1.7.0...1.7.1
358405
[1.7.0]: https://github.com/mailchimp/wordpress/compare/1.6.3...1.7.0
406+
[1.6.4]: https://github.com/mailchimp/wordpress/compare/1.6.3...1.6.4
359407
[1.6.3]: https://github.com/mailchimp/wordpress/compare/1.6.2...1.6.3
360408
[1.6.2]: https://github.com/mailchimp/wordpress/compare/1.6.1...1.6.2
361409
[1.6.1]: https://github.com/mailchimp/wordpress/compare/1.6.0...1.6.1

CREDITS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ The following individuals are responsible for curating the list of issues, respo
1212

1313
Thank you to all the people who have already contributed to this repository via bug reports, code, design, ideas, project management, translation, testing, etc.
1414

15-
[Mailchimp (@mailchimp)](https://github.com/mailchimp), [Crowd Favorite (@crowdfavorite)](https://github.com/crowdfavorite), [Matthew Richmond (@bigdawggi)](https://github.com/bigdawggi), [Devin Reams (@devinreams)](https://github.com/devinreams), [Alex King (@alexkingorg)](https://github.com/alexkingorg), [Jesse (@jessedp)](https://github.com/jessedp), [Andrew Ellis]([email protected]), [Evan Anderson (@ejdanderson)](https://github.com/ejdanderson), [Webb Henderson (@emerywebster)](https://github.com/emerywebster), [Steven Mathias (@ssmathias)](https://github.com/ssmathias), [Jonathan D. Johnson (@jondavidjohn)](https://github.com/jondavidjohn), [Ross Tweedie (@digitales)](https://github.com/digitales), [(@mcwill)](https://github.com/mcwill), [Andrew Austin (@andrewjaustin)](https://github.com/andrewjaustin), [Marc Queralt i Bassa (@MarcQueralt)](https://github.com/MarcQueralt), [Chris Mospaw (@mospaw)](https://github.com/mospaw), [Jonas Stensved (@jstensved)](https://github.com/jstensved), [netboy]([email protected]), [Lenin]([email protected]), [Bauke Zwaan (@baukezwaan)](https://github.com/baukezwaan), [Jascha Ehrenreich (@jaeh)](https://github.com/jaeh), [Chris Wilcoxson (@slushman)](https://github.com/slushman), [Luke Watts (@thisislawatts)](https://github.com/thisislawatts), [Glenn Ansley (@glennansley)](https://github.com/glennansley), [SiteGround](http://www.siteground.com/wordpress-hosting.htm), [Peter Kahoun](http://kahi.cz/), [Jan Lund](), [Michael Jaekel](), [Ιωάννης Δημοφέρλιας (John Dimoferlias)](), [Tomás Nader](), [Claudia Mansilla](http://cricava.com/), [Helen Urbanik](http://www.motomaania.ee/), [Maxime Toulliou](http://www.maximetoulliou.com/), [שגיב בית](http://www.sagive.co.il), [Okostobi](), [Stefan Des](http://www.stefandes.com), [백선기 (SK Baek)](), [Alexander Roterud aka Defrag](http://www.tigerpews.com), [Filip Stas](http://suddenelfilio.net/), [Maria Manoela Porto](), [Tiago Faria](http://xroot.org), [Alexandru Armin Roșu](), [Илья](http://fatcow.com), [Sebastian Johnsson](http://www.agiley.se/), [Hakan E.](http://kazancexpert.com/), [Josh Grosser (@jgrosser-intuit)](https://github.com/jgrosser-intuit), [10up (@10up)](https://github.com/10up), [Nate Conley (@nateconley)](https://github.com/nateconley), [Darin Kotter (@dkotter)](https://github.com/dkotter), [Jeffrey Paul (@jeffpaul)](https://github.com/jeffpaul), [Eddie Shrake (@eddieshrake)](https://github.com/eddieshrake), [Sumit Bagthariya (@qasumitbagthariya)](https://github.com/qasumitbagthariya), [Vikram Moparthy (@vikrampm1)](https://github.com/vikrampm1), [Dharmesh Patel (@iamdharmesh)](https://github.com/iamdharmesh), [GitHub Dependabot (@dependabot)](https://github.com/apps/dependabot), [Jer Clarke (@jerclarke)](https://github.com/jerclarke), [Max Garceau (@MaxwellGarceau)](https://github.com/MaxwellGarceau), [Nathan Tetzlaff](), [Romain Deville](https://www.linkedin.com/in/devilleromain/).
15+
[Mailchimp (@mailchimp)](https://github.com/mailchimp), [Crowd Favorite (@crowdfavorite)](https://github.com/crowdfavorite), [Matthew Richmond (@bigdawggi)](https://github.com/bigdawggi), [Devin Reams (@devinreams)](https://github.com/devinreams), [Alex King (@alexkingorg)](https://github.com/alexkingorg), [Jesse (@jessedp)](https://github.com/jessedp), [Andrew Ellis]([email protected]), [Evan Anderson (@ejdanderson)](https://github.com/ejdanderson), [Webb Henderson (@emerywebster)](https://github.com/emerywebster), [Steven Mathias (@ssmathias)](https://github.com/ssmathias), [Jonathan D. Johnson (@jondavidjohn)](https://github.com/jondavidjohn), [Ross Tweedie (@digitales)](https://github.com/digitales), [(@mcwill)](https://github.com/mcwill), [Andrew Austin (@andrewjaustin)](https://github.com/andrewjaustin), [Marc Queralt i Bassa (@MarcQueralt)](https://github.com/MarcQueralt), [Chris Mospaw (@mospaw)](https://github.com/mospaw), [Jonas Stensved (@jstensved)](https://github.com/jstensved), [netboy]([email protected]), [Lenin]([email protected]), [Bauke Zwaan (@baukezwaan)](https://github.com/baukezwaan), [Jascha Ehrenreich (@jaeh)](https://github.com/jaeh), [Chris Wilcoxson (@slushman)](https://github.com/slushman), [Luke Watts (@thisislawatts)](https://github.com/thisislawatts), [Glenn Ansley (@glennansley)](https://github.com/glennansley), [SiteGround](http://www.siteground.com/wordpress-hosting.htm), [Peter Kahoun](http://kahi.cz/), [Jan Lund](), [Michael Jaekel](), [Ιωάννης Δημοφέρλιας (John Dimoferlias)](), [Tomás Nader](), [Claudia Mansilla](http://cricava.com/), [Helen Urbanik](http://www.motomaania.ee/), [Maxime Toulliou](http://www.maximetoulliou.com/), [שגיב בית](http://www.sagive.co.il), [Okostobi](), [Stefan Des](http://www.stefandes.com), [백선기 (SK Baek)](), [Alexander Roterud aka Defrag](http://www.tigerpews.com), [Filip Stas](http://suddenelfilio.net/), [Maria Manoela Porto](), [Tiago Faria](http://xroot.org), [Alexandru Armin Roșu](), [Илья](http://fatcow.com), [Sebastian Johnsson](http://www.agiley.se/), [Hakan E.](http://kazancexpert.com/), [Josh Grosser (@jgrosser-intuit)](https://github.com/jgrosser-intuit), [10up (@10up)](https://github.com/10up), [Nate Conley (@nateconley)](https://github.com/nateconley), [Darin Kotter (@dkotter)](https://github.com/dkotter), [Jeffrey Paul (@jeffpaul)](https://github.com/jeffpaul), [Eddie Shrake (@eddieshrake)](https://github.com/eddieshrake), [Sumit Bagthariya (@qasumitbagthariya)](https://github.com/qasumitbagthariya), [Vikram Moparthy (@vikrampm1)](https://github.com/vikrampm1), [Dharmesh Patel (@iamdharmesh)](https://github.com/iamdharmesh), [GitHub Dependabot (@dependabot)](https://github.com/apps/dependabot), [Jer Clarke (@jerclarke)](https://github.com/jerclarke), [Max Garceau (@MaxwellGarceau)](https://github.com/MaxwellGarceau), [Nathan Tetzlaff](), [Romain Deville](https://www.linkedin.com/in/devilleromain/), [@joemcgill](https://github.com/joemcgill).
1616

1717
## Libraries
1818

includes/admin/class-mailchimp-user-sync.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,8 @@ public function subscriber_status_field() {
325325
_n(
326326
'You will need %1$sa Mailchimp plan%2$s that includes %3$d contact.',
327327
'You will need %1$sa Mailchimp plan%2$s that includes %3$d contacts.',
328-
absint( $users_count )
328+
absint( $users_count ),
329+
'mailchimp'
329330
),
330331
'<a href="https://mailchimp.com/help/about-mailchimp-pricing-plans/" target="_blank" rel="noopener noreferrer">',
331332
'</a>',

includes/admin/templates/settings.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@ function ( $ele ) {
9494
</div>
9595
<div class="mailchimp-sf-settings-list-select-button">
9696
<input type="hidden" name="mcsf_action" value="update_mc_list_id" />
97+
<?php wp_nonce_field( 'update_mc_list_id_action', 'update_mc_list_id_nonce' ); ?>
9798
<input type="submit" name="submit" value="<?php esc_attr_e( 'Fetch list settings', 'mailchimp' ); ?>" class="mailchimp-sf-button btn-secondary" />
9899
</div>
99100
</div>

includes/admin/templates/setup-page.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@
224224
<tr>
225225
<th class="mailchimp-sf-option-header">
226226
<label for="mc_nuke_all_styles">
227-
<?php esc_html_e( 'Remove CSS' ); ?>
227+
<?php esc_html_e( 'Remove CSS', 'mailchimp' ); ?>
228228
</label>
229229
</th>
230230
<td>
@@ -234,7 +234,7 @@
234234
<input type="checkbox" name="mc_nuke_all_styles" id="mc_nuke_all_styles" class="mailchimp-sf-checkbox" <?php checked( get_option( 'mc_nuke_all_styles' ), true ); ?> onclick="showMe('mc-custom-styling')"/>
235235
</div>
236236
<label for="mc_nuke_all_styles">
237-
<?php esc_html_e( 'This will disable all Mailchimp CSS, so it\'s recommended for WordPress experts only.' ); ?>
237+
<?php esc_html_e( 'This will disable all Mailchimp CSS, so it\'s recommended for WordPress experts only.', 'mailchimp' ); ?>
238238
</label>
239239
</div>
240240
</td>
@@ -265,7 +265,7 @@
265265
<input type="checkbox" name="mc_custom_style" id="mc_custom_style" class="mailchimp-sf-checkbox"<?php checked( get_option( 'mc_custom_style' ), 'on' ); ?> />
266266
</div>
267267
<label for="mc_custom_style">
268-
<?php esc_html_e( 'Edit the default Mailchimp CSS style.' ); ?>
268+
<?php esc_html_e( 'Edit the default Mailchimp CSS style.', 'mailchimp' ); ?>
269269
</label>
270270
</div>
271271
</td>

includes/class-mailchimp-form-submission.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ public function handle_form_submission() {
9999
$merge_fields = get_option( 'mc_merge_vars', array() );
100100
$interest_groups = get_option( 'mc_interest_groups', array() );
101101

102+
// phpcs:disable WordPress.Security.NonceVerification.Missing -- Nonce check is already done in the request_handler() function.
102103
// Check if request from latest block.
103104
if ( isset( $_POST['mailchimp_sf_list_id'] ) ) {
104105
$list_id = isset( $_POST['mailchimp_sf_list_id'] ) ? sanitize_text_field( wp_unslash( $_POST['mailchimp_sf_list_id'] ) ) : '';
@@ -148,6 +149,7 @@ public function handle_form_submission() {
148149
} else {
149150
$email_type = 'html';
150151
}
152+
// phpcs:enable WordPress.Security.NonceVerification.Missing
151153

152154
$response = $this->subscribe_to_list(
153155
$list_id,
@@ -251,10 +253,11 @@ public function prepare_merge_fields_body( $merge_fields, $skip_merge_validation
251253
$opt = 'mc_mv_' . $tag;
252254

253255
// Skip if the field is not required and not submitted.
254-
if ( ( true !== (bool) $merge_field['required'] && ! isset( $_POST[ $opt ] ) ) || $skip_merge_validation ) {
256+
if ( ( true !== (bool) $merge_field['required'] && ! isset( $_POST[ $opt ] ) ) || $skip_merge_validation ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Nonce check is already done in the request_handler() function.
255257
continue;
256258
}
257259

260+
// phpcs:ignore WordPress.Security.NonceVerification.Missing -- Nonce check is already done in the request_handler() function.
258261
$opt_val = isset( $_POST[ $opt ] ) ? map_deep( stripslashes_deep( $_POST[ $opt ] ), 'sanitize_text_field' ) : '';
259262

260263
switch ( $merge_field['type'] ) {
@@ -339,6 +342,7 @@ public function prepare_groups_body( $interest_groups ) {
339342

340343
foreach ( $interest_groups as $interest_group ) {
341344
$ig_id = $interest_group['id'];
345+
// phpcs:disable WordPress.Security.NonceVerification.Missing -- Nonce check is already done in the request_handler() function.
342346
if ( isset( $_POST['group'][ $ig_id ] ) && 'hidden' !== $interest_group['type'] ) {
343347
switch ( $interest_group['type'] ) {
344348
case 'dropdown':
@@ -367,6 +371,7 @@ public function prepare_groups_body( $interest_groups ) {
367371
break;
368372
}
369373
}
374+
// phpcs:enable WordPress.Security.NonceVerification.Missing
370375
}
371376
return $groups;
372377
}
@@ -544,6 +549,7 @@ public function remove_empty_merge_fields( $merge ) {
544549
* @return bool|WP_Error True if valid, WP_Error if invalid.
545550
*/
546551
protected function validate_form_submission() {
552+
// phpcs:disable WordPress.Security.NonceVerification.Missing -- Nonce check is already done in the request_handler() function.
547553
$spam_message = esc_html__( "We couldn't process your submission as it was flagged as potential spam. Please try again.", 'mailchimp' );
548554
// Make sure the honeypot field is set, but not filled (if it is, then it's a spam).
549555
if ( ! isset( $_POST['mailchimp_sf_alt_email'] ) || ! empty( $_POST['mailchimp_sf_alt_email'] ) ) {
@@ -579,5 +585,6 @@ protected function validate_form_submission() {
579585
* @param array $post_data The $_POST data.
580586
*/
581587
return apply_filters( 'mailchimp_sf_form_submission_validation', true, $_POST );
588+
// phpcs:enable WordPress.Security.NonceVerification.Missing
582589
}
583590
}

0 commit comments

Comments
 (0)