Skip to content

Latest commit

 

History

History
65 lines (45 loc) · 2.08 KB

File metadata and controls

65 lines (45 loc) · 2.08 KB

Config2Text - Automatic Network Policy Inference

1. Setting up Batfish/Minesweeper

Important: The additions work with Batfish at commit 73946b2f1bdea5f1146e4db4f2586e071da752df

A snapshot of the Batfish code at that commit is also available in batfish_repo.zip.

After you obtained the Batfish code, you need to add the Config2Spec specific modifications.

To that end, use the setup.sh script. It copies all the necessary files into the batfish repository such that you can just build the entire project with Maven.

Use the script as follows:

$ bash setup.sh <repo path> <Config2Spec path>

Arguments

  • repo path - Specify the full path to the directory in which you have cloned the batfish repository (e.g., c2s_batfish) or unzipped the archive provided above.

  • Config2Spec path - Specify the full path of the Config2Spec repository.

Example

$ bash setup.sh /home/user/GitHub/c2s_batfish /home/user/GitHub/config2spec

2. Installing Prerequisites

Install all the prerequisites described in the Batfish installation guide (Java, Maven, etc.).

Then, install Z3. All the other steps in the guide can be skipped. Depending on your operating system, you might have to build Z3 from its source. In that case, make sure to use the --java command line flag with the mk_make.py script to enable building the Java bindings.

Build Batfish/Minesweeper

Once, you have installed all the prerequisites, you can enter the projects directory within the Batfish repository and run:

$ cd projects/
$ mvn package

You should then find all the .jar-files in the target directory of all the module directories. The backend-bundle-0.36.0.jar is the file that contains all the dependencies and can be run using:

$ cd backend/target/
$ java -cp backend-bundle-0.36.0.jar org.batfish.backend.Backend