Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I know there are lot of regex for the purpose, but in my case the regex i want to write is one that matches following payload

 ...............sssfdf.makememad.com......
........makemadcom.....
dfdfddd   makeme.ru.......
also ...makeme.net.......

I just want to match anything with following

.ru
.net
.com

And due to some limitations of the software in which im using the regex it won't allow to do this

\.

so any regex which skips this would be great.

Thanks.

share|improve this question
    
How do you escape a period then in your engine then, what engine are you using? Also that looks like the text dump from a hex editor. Are all those periods really periods or are they really unprintable text from a hex editor. Please provide more detail about how you are trying to do what you want to do. I would put money that whatever language you are using uses \ as a escape character so you need to escape the escape via something like "\\." –  Scott Chamberlain Aug 22 '13 at 19:17
    
the engine works fine on other traffic but one particular application traffic e.g dns it won't work. Its closed system SIEM solution. The engine uses java regex –  asadz Aug 22 '13 at 19:18
    
Well java supports escaping metacharaters with a slash –  Scott Chamberlain Aug 22 '13 at 19:42

1 Answer 1

Use a character class since you don't need to escape:

[.](ru|net|com)
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.