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.
salemneaz
Staff
Staff
Article Id 297560
Description This article describes how to compare FortiGate Firewall Configuration using Notepad++.
Scope FortiGate, Notepad++
Solution

Comparison of configuration backups is required when sometimes, some of the features are not working as expected after the firmware upgrade or sometimes when the High cluster goes out of sync.

It is possible to use the 'Compare' plugin that is available in the Notepad++ application to easily find the differences between the backup files if any.

 

Download Notepad++ from the official website. After downloading the Notepad++ application, install the compare plugin following the steps given below.

 

  1. Launch Notepad++.
  2. Navigate to Plugins -> Plugins Admin.
  3. In the Plugins Admin window, type Compare in the search bar.
  4. Check Compare, then click Install.
 

Figure-1: Install "Compare" Plugins.Figure-1: Install "Compare" Plugins.

 

After installing the 'Compare' Plugin,  open the backup configuration in Notepad++:

 

Figure-2: Open Backup Configuration Files.Figure-2: Open Backup Configuration Files.

 

Open the configuration backup file of the notepad++ at two different tabs side by side:

 

Figure-3: Files are openedFigure-3: Files are opened

 

Select  one of the configuration file Tab open the 'Plugins' select 'Compare' and then 'Set as First to Compare':

 

Figure-4: Set the First Files to CompareFigure-4: Set the First Files to Compare

 

Select the Second Configuration File Tab, once again open the 'plugins' and select 'Compare':

 

Figure-5: Set  Files to CompareFigure-5: Set  Files to Compare

 

It is now set to compare the two configuration backup files that will open side by side to each other and the differences will be highlighted as scrolled through the sections up and down.

 

Figure-6: Differences are Highlighted between the FilesFigure-6: Differences are Highlighted between the Files

 

After the configuration comparison work is done,  go back to the 'Plugins' tab and then select 'Clear Active Compare':

 

Figure-6: Clear Active ConfigurationFigure-6: Clear Active Configuration

 

This is an easy and effective way to compare not only configuration files but also outputs from the CLI console.

This provides easy visibility of the differences between the outputs. This is particularly effectively used to find differences in configuration between the High Availability cluster members.

Contributors