FortiGate
FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
Jonathan_Body_FTNT
Description
Following the release of FortiOS firmware version 4.0 MR2, the "grep" filter command can be used on the CLI of a FortiGate system.
Scope
FortiOS firmware version 4.0 MR2
FortiOS firmware version 4.0 MR3
FortiOS firmware version 5.0.x
 

Solution
The "grep" command is applied as a standard command filter within the FortiOS firmware, with the following syntax:
 
FGT# show  <subcommand>  | grep <expression>

  

FGT# diagnose  <subcommand>  | grep <expression>
 
 
Example:
 
<!--[if !supportLineBreakNewLine]-->
FGT # show system interface
 
 
config system interface
    edit "port1"
        set vdom "root"
        set ip 192.168.183.104 255.255.254.0
        set allowaccess ping ssh http telnet
        set type physical
    next
    edit "port2"
        set vdom "root"
        set ip 172.31.225.104 255.255.254.0
        set allowaccess ping https ssh http telnet
        set type physical
    next



FGT # show sys interface | grep 192


set ip 192.168.183.104 255.255.254.0

FGT # show system interface | grep https

set allowaccess ping https ssh http telnet


     

Contributors