Long story short of this is that occassionally the ) and ; chars will end up right next to one another during salt generation and this will cause things to blow up badly.
The root of the problem was not preferring string values within quotes first before attempting to match everything within the statement. So this PR improves the regex to do just that.
Consider the following constant value in wp-config.php:
define( 'AUTH_SALT', 'abc);123' ); // <--- a perfectly valid salt value
If you try to run $ wp config shuffle-salts you will get a success in the console but your site will break in dramatic fashion.
Long story short of this is that occassionally the
)
and;
chars will end up right next to one another during salt generation and this will cause things to blow up badly.The root of the problem was not preferring string values within quotes first before attempting to match everything within the statement. So this PR improves the regex to do just that.
Consider the following constant value in
wp-config.php
:If you try to run
$ wp config shuffle-salts
you will get a success in the console but your site will break in dramatic fashion.