Meraki MX Converter - Import ASA config files and automatically adapt rules to the target MX. This script will parse through an existing ASA config and generate Meraki MX compatible FW rules. The script supports objects(network/service). It'll build iterative or multi-source/multi-destination L3 based rules. It'll then configure the target MX network with the ruleset mapping to the new interfaces.
- place config files in local directory (raw output from 'show run' on the ASA)
- Create a new MX network in the Meraki Dashboard
- Enable "Use VLANs" under "Addressing & Vlans" (it'll error out if you don't do this!)
- Create interfaces (vlan, ip and subnet) in that new network (these should match interfaces VLAN-ID in the config file)
- For step#4, the IP/subnets do not have to match, just the VLAN-ID. The script will auto-map the new IP/subnet to the ruleset
- Edit "acl_list.txt" this file should contain the names of every ACL rule you want to process
- RUN THIS ON A TEST NETWORK FIRST! This re-writes ALL the rules and anything currently in the rules will be lost.
- Run the commandline "python3 mx_import.py -k <key> -o <org> -n <networkID> -c command <ASA CONFIG FILE>" -commands supported "write", "clear" and "test". Test is default. Clear will wipe the FW rules.
- After the script runs, validate the rules have ported correctly. The comments section will hold the original ACL rule to compare
- python 3.x
- meraki SDK for python (https://developer.cisco.com/meraki/api/#/python/getting-started)
- install python packages ('pip3 install -r requirements.txt')
-limitations on source addresses rules, you can only import a rule if the source address/subnet exists on the target MX. The script will omit subnets for which it doesn't have a local interface or default route. -test it first