The regex can't match some base64 string
minwe opened this issue · comments
Minwe LUO commented
438026444
convert to base64 string is NDM4MDI2NDQ0
, the regex can't match this.
This function works well.
Sean Cai commented
Me also facing some issue testing some base64 strings such as "NTkxNjVSRUZVSV9JU19QaGFybWFjeV9TdGFmZixBc3Npc3RhbnRNYW5hZ2Vy"
Aras Abbasi commented
When I validate those base64-strings it validates them as correct.
def00111 commented
This regex seems working well:
(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=|[A-Za-z0-9+\/]{4})
Aras Abbasi commented
Wow... after three years I am checking this issue again... and still the catastrophic backtracking version is not updated.