Closed noahheck closed 6 years ago
i.e. password_hash function may produce something like this:
$2y$10$Xs/oqD0cVCb7hM1suoAD/Oqf4tlm5suTb8IsczDTnttiWUtHsb5ay
but the full query value ends up like this:
y$Xs/oqD0cVCb7hM1suoAD/Oqf4tlm5suTb8IsczDTnttiWUtHsb5ay
$2y$10$Xs/oqD0cVCb7hM1suoAD/Oqf4tlm5suTb8IsczDTnttiWUtHsb5ay y $Xs/oqD0cVCb7hM1suoAD/Oqf4tlm5suTb8IsczDTnttiWUtHsb5ay
More problematic would be the presence of a $0 backreference in the replacement value (potentially re-adding the placeholder to the content string)
$0
This might be a solution to this:
https://stackoverflow.com/questions/39968330/avoid-backreference-replacement-in-phps-preg-replace
i.e. password_hash function may produce something like this:
but the full query value ends up like this:
More problematic would be the presence of a
$0
backreference in the replacement value (potentially re-adding the placeholder to the content string)