Lately we have seen spam attack, injected into wordpress search pages causing google to index these pages, be sure add the the fix below. The fix works like you simply add the noindex to the wordpress results page.
Vulnerability
Although fixed by wordpress core, AISEO plugin is causing this.
Spam
The spam would like like
/?s=s=?+Discount+online+Pharmacy:+?+www.Trust4Me.site+?+Buy+Dialon+?+Buy+Dialon+No+Rx&=1 ?s=?+Cheap+Pharmacy+->+?+www.Trust4Me.site+?+-+Buy+Apo-napro-na+?+Apo-napro-na+Overnight+Delivery&=1
Fix
1. Easy fix would be Disable indexing in AISEO plugin (Go to Search Appearance > Archives > Search Page > Selecto NO to Show In Search Results)
2. Filter
Another fix is also available here
add_filter( 'wp_robots', 'wp_robots_noindex_search' ); function wp_robots_noindex_search( array $robots ) { if ( is_search() ) { return wp_robots_no_robots( $robots ); } return $robots; }
3. Block spam pages in Robots.tx
Disallow: /*?s=*