Hello Everyone,
I am trying to find a pattern to match a web address and a port number in the content of a log. For example the log will contain
This is a test message for http://ltest-bed.trigun.org for a system test-bed.trigun.org:443. Tunnel id account:///test/locat
I want to be able to match the content in bold. The port number of the org keeps varying and also sometimes the system comes enclosed in a quote for example
log 1: This is a test message for http://ltest-bed.trigun.org for a system \“test-bed.trigun.org:443\”. Tunnel id account:///test/locat
The log might also come in the format
log 2: This is a test message for a system “test-bed.trigun.org:443”. Tunnel id account:///test/locat
any suggestions please ?
I tried this [a-zA-Z0-9.-]*:host’:'[0-9]*:port but that did not work because it would also match http: rather than the webaddress:port