Rules converted as hyperscan rules
Opened this issue · 0 comments
adulau commented
ChatGPT generic question
Can you convert this regular expression in python regexp format "ORIGINAL regexp in Python format" into a hyperscan regular expression without zero-width assertions?
Onion match
((http|https|ftp):\/\/)?([a-zA-Z0-9.\-]+(\:[a-zA-Z0-9.&%$\-]+)*@)?((25[0-5]|2[0-4][0-9]|[01]?[0-9]{1,2}|[1-9]{1}[0-9]{0,1})\.(25[0-5]|2[0-4][0-9]|[01]?[0-9]{1,2}|[1-9]{1}[0-9]{0,1}|0)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9]{1,2}|[1-9]{1}[0-9]{0,1}|0)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9]{1,2}|[0-9]))|localhost|([a-zA-Z0-9\-]+\.)*[a-zA-Z0-9\-]+\.onion(\:[0-9]+)?(\/($|[a-zA-Z0-9.,?'\\+&%$#~=/_\-]+))*
BTC
(?!.*[+/=])[13][A-Za-z0-9]{26,33}(?![+/=])
bitcoin-bech32
(bc(?:0(?:[ac-hj-np-z02-9]{39}|[ac-hj-np-z02-9]{59})|1[ac-hj-np-z02-9]{8,87}))