I have this currently
([\w\-"]+)[ ]+OBJECT-TYPE[^[::=]*]*::=[ ]*\{[ ]*([\w\-"]+) ([\w\-"]+)
What it does is search for stuff like this:
DATA1 OBJECT-TYPE
SYNTAX SEQUENCE OF ContactInfoEntry
MAX-ACCESS not-accessible
STATUS current
DESCRIPTION
"A table containing Contact Info information"
::= { DATA2 DATA3 }
I just had one problem that thought i fixed
OBJECT-TYPE[^[::=]*]*::=
This was meant to search for any chars after the string "OBJECT-TYPE" that wasnt "::=" until it actualy found "::=" this worked well until i noticed that
[^[::=]*]*
actualy meant meant : or = and not the excact string "::=" so how do i fix that?
EDIT: If someone is still here so that i dont need to open another question, how do i ignore any and all chars, symbols, numbers, etc between two ".
Example:
dont ignore this "ignore everything that is in here" dont ignore again "ignore again" etc