Created on
06-20-2018
02:06 AM
Edited on
11-26-2024
01:21 AM
By
Jean-Philippe_P
Description
This article describes how to insert the special symbol '?' in the CLI as part of the input. In the FortiOS CLI, '?' is usually used to open the help menu, but under certain circumstances it can be used as part of the input, for example, to configure a redirect URL containing a '?' in a firewall policy.
Scope
FortiGate.
Solution
To use the special symbol '?' as part of the input in the CLI, press 'CTRL+V' or 'Ctrl + Shift + -' on the keyboard first, then press '?'.
This is how to configure a redirect firewall policy to use a URL with a '?':
config firewall policy
edit 1
set name "test"
set uuid 9454cdf2-4923-51e8-336f-123d6b6ab6b5
set srcintf "port2"
set dstintf "port1"
set srcaddr "all"
set dstaddr "all"
set action accept
set schedule "always"
set service "ALL"
set logtraffic all
set groups "Local"
set nat enable
set redirect-url "http://abc.com/test?=123"
next
end
Note that copying and pasting the entire redirect-url will not work, it is absolutely necessary to input 'CTRL+V' or 'Ctrl + Shift + -' first before using the '?' symbol.