Forum Discussion

Yaoxie_117356's avatar
Yaoxie_117356
Icon for Nimbostratus rankNimbostratus
Jul 12, 2016

findstr irule

when RULE_INIT { set static::payload {windows-passwordusernamejackdomainTESTpasswordabcdef} 
set username [findstr [findstr [findstr [$static::payload] {username} 1 "} 1 "} 7 "


}
any idea why the irule is not working?
Jul 12 17:33:27 apm err tmm[17407]: 01220001:3: TCL error: /Common/finstr  - invalid command name "windows-passwordusernamejackdomainTESTpasswordabcdef"     while executing "$static::payload"
Many thanks

10 Replies

  • Hi,

    You may need to use

    "
    instead of
    {
    to define the
    static::payload
    :

    when RULE_INIT { 
      set static::payload "windows-passwordusernamejackdomainTESTpasswordabcdef" 
    set username [findstr [findstr [findstr [$static::payload] {username} 1 "} 1 "} 7 "
  • Hi,

    You may need to use

    "
    instead of
    {
    to define the
    static::payload
    :

    when RULE_INIT { 
      set static::payload "windows-passwordusernamejackdomainTESTpasswordabcdef" 
    set username [findstr [findstr [findstr [$static::payload] {username} 1 "} 1 "} 7 "