Welcome to the VanDyke Software Forums

Join the discussion today!


Go Back   VanDyke Software Forums > Secure Shell

Notices

Reply
 
Thread Tools Display Modes
  #1  
Old 05-19-2021, 09:54 AM
WesR WesR is offline
Registered User
 
Join Date: Mar 2005
Location: USA
Posts: 149
Highlight Keyword with Regex Positive Look Ahead

I'm trying to highlight the sequence "site=name&" without including the "&" in the highlight.

In regex, I can use the following query and it works, but in SecureCRT highlighting it does not.
site=.*?(?=\&))
Does SecureCRT support this?

If I use "site=.*?\&", the whole sequence is highlighted including the "&".

I'm using SecureCRT Version 8.2.0 (x64 build 1402)
Reply With Quote
  #2  
Old 05-19-2021, 11:25 AM
bgagnon bgagnon is offline
VanDyke Technical Support
 
Join Date: Oct 2008
Posts: 4,636
Hi WesR,

I think you have one too many closing parens.

This works for me in v9.0.1:
site=.*?(?=\&)

This does not:
site=.*?(?=\&))

If you think the double close parens is correct, please post the text you are testing against.

As a note, v8.2 was not even an official release but it's very old. You might check your upgrade eligibility.
__________________
Thanks,
--Brenda

VanDyke Software
Technical Support
support@vandyke.com
(505) 332-5730
Reply With Quote
  #3  
Old 05-19-2021, 11:52 AM
WesR WesR is offline
Registered User
 
Join Date: Mar 2005
Location: USA
Posts: 149
Thanks and sorry, not sure how that extra Paren made it in there, but it is in the post only.

It still does not work for me in 8.2.
Reply With Quote
  #4  
Old 05-19-2021, 12:59 PM
WesR WesR is offline
Registered User
 
Join Date: Mar 2005
Location: USA
Posts: 149
Here is an example of the type of string I'm testing against:

enterprise=enterprise1&site=TestSite1&area=Area1&line=Line1&

In this case,

Quote:
site=.*?(?=\&)
doesn't highlight anything.

I can see what I can do with upgrading, but because this was a corporate purchase done for me, I don't know what it might take.

Wes
Reply With Quote
  #5  
Old 05-19-2021, 01:13 PM
bgagnon bgagnon is offline
VanDyke Technical Support
 
Join Date: Oct 2008
Posts: 4,636
Hi Wes,

Keyword highlighting/regex has been enhanced since v8.2. The first version in which this will work is v8.7.

Changes in SecureCRT 8.7 (Beta 1) -- November 20, 2019
------------------------------------------------------
New features:

  • Keyword highlighting supports the ability to match phrases and substrings and works with literal strings and regular expressions.

What did you find when you checked upgrade eligibility? What is the most recent version your license provides access to? (Please do not post the serial number here, if unsure, please send email to support@vandyke.com and we can check for you.)
__________________
Thanks,
--Brenda

VanDyke Software
Technical Support
support@vandyke.com
(505) 332-5730

Last edited by bgagnon; 05-19-2021 at 01:17 PM.
Reply With Quote
  #6  
Old 05-19-2021, 01:18 PM
WesR WesR is offline
Registered User
 
Join Date: Mar 2005
Location: USA
Posts: 149
I was able to upgrade to 8.3.4 (x64 build 1699), but unfortunately get the same results.

Wes
Reply With Quote
  #7  
Old 05-19-2021, 01:20 PM
WesR WesR is offline
Registered User
 
Join Date: Mar 2005
Location: USA
Posts: 149
Just saw your post. I don't think I can get to 8.7 or higher easily.

Thanks
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -6. The time now is 02:12 PM.