This chapter shows how changes made to an edited configuration can be saved and then activated.
As discussed in Chapter 3, Opening Configurations, configurations need to be checked out for editing. After editing is complete, a configuration needs to be checked back in and/or deployed to the firewall.
The code example found in Chapter 2, Starting Coding achieves this with the code lines:
// Check in the new configuration server.CheckInConfiguration(cfg, "Added IP rule allowing NAT LAN to WAN HTTP traffic"); // Activate the new configuration on the Security Gateway server.DeployConfiguration(sgwStockholm);
Check In
A check in is a simple operation which is performed by invoking the CheckInConfiguration method on the Server object with the: configuration as a parameter.server.CheckInConfiguration(cfg, "Added IP rule allowing NAT LAN to WAN HTTP traffic");The string parameter Example is a comment for the check in.
Deployment
Checking in a configuration does not mean that the changes made will come into effect on the Clavister Next Generation Firewall. It is necessary to deploy a configuration for it to become the active configuration on the firewall. Deployment is done with the following code:server.DeployConfiguration(sgwStockholm);Notice that the configuration is not the parameter for the DeployConfiguration method but the Device object instance is used instead. In other words, the deployment is done for the firewall and the most recent version of the configuration is deployed.