cancel
Showing results for 
Search instead for 
Did you mean: 
Create a Post
Employee+
Employee+

Migrating threat profiles using the R80 Web APIs, Python, and cpauto

Overview

This script shows how threat profiles can be migrated from one R80 manager to another R80 or R80.10 manager programmatically using the R80 web APIs, Python, and cpauto.

Description

Script requires at least two R80/R80.10 managers with the web APIs enabled. The source manager should have some user-defined threat profiles for the demo to be useful.

The provided code is merely an example but is a viable pattern that can be reused for virtually all policy and object types.

Instructions

Download the archive and run the enclosed Python script on a system that meets the following requirements:

  • Python and cpauto installed correctly
  • Network access to the source and destination R80 web API resources

Grab the code here: https://www.dropbox.com/s/6o6fslt2yz4k8wa/cpauto-threat-profile-migrate-demo.tar.gz?dl=0

For more information on cpauto: https://github.com/dana-at-cp/cpauto

Code Version

Code version 1.0.0

Tested on version

R80, API version 1.0, 1.1

NOTICE: By using this sample code you agree to terms and conditions in this Not authorized to view the specified document 1042

...

2 Replies

Re: Migrating threat profiles using the R80 Web APIs, Python, and cpauto

Would help if there was more documentation on cpauto. 

0 Kudos
Highlighted
Employee+
Employee+

Re: Migrating threat profiles using the R80 Web APIs, Python, and cpauto

Hi Jacob Blankenship‌ ... cpauto is an open source project that is not officially supported by Check Point. It was developed to abstract some of the common bits required to consume the early R80.x web APIs. There is documentation in the code itself in the form of Python comments. The Python comments are structured in a way to automatically generate documentation you can find here: Welcome to cpauto’s documentation! — cpauto 0.0.5 documentation 

Since it is an open source project that means you and others can contribute. Smiley Happy Please feel free to create documentation and submit pull requests via Github. The project is lagging behind advancements in the R80.x web APIs so there is plenty of Python to write for anyone interested.

There's also a project page on PyPI: cpauto · PyPI