Support Forum
The Forums are a place to find answers on a range of Fortinet products from peers and product experts.
JDoetsch
New Contributor

Script Execution Fails with no indication of why

Hi, I'm working with a new client who has Fortigate, and have not done much work with them in the past.  They've got a very active security department and frequently need IPs added to their block list on 15+ firewalls.  I decided that I should try to script something to make that less painful, so I looked up the appropriate commands and created a script that prints out the appropriate CLI input.  When I run this in the script execution area of the GUI, however, it just says "Some or All Commands Failed to Execute" without giving me any additional info Here's what I'm running as a test (note, these commands work when I paste directly into CLI)

 

config firewall address
edit Block_1.2.3.4
set type ipmask
set subnet 1.2.3.4/32
set visibility disable
set comment "Added on 05/28/21 per INC012345"
set associated-interface wan1
next
end

 

I've tried it without the "next" and "end" lines as well, as I saw them in other examples, but weren't sure if they were necessary Is there something I'm missing here?  How do I see what Fortigate is complaining about? Cheers,

-J

0 REPLIES 0
Labels
Top Kudoed Authors