Examples & Notebooks

Jupyter Notebooks

This library, and especially the analyzer module will accelerate any Python development project that seeks to leverage RiskIQ data for investigation, enrichment, and attack surface management, but it is also ideally suited to working with Jupyter Notebooks.

Jupyter Notebooks have emerged as the defacto tool for interactive analysis, first with scientific data, and more recently across other disciplines including security.

In fact, the Microsoft Threat Intelligence (MSTIC) team publishes a Python library purpose-built for threat detection and incident triage in Jupyter Notebooks, and they make a good case for notebooks

The RiskIQ passivetotal python library isn’t designed exclusively for use in Jupyter, but it works so well in that context that we’ve choosen to publish most of our examples as notebooks.

Notebooks also provide a useful way of explaining the library features, even if you’re a developer planning to use the library in your own project.

Example Notebooks

Jupyter notebooks are published on Github adjacent to the source code for this package.

Github provides a handy viewer for the files, but it can be a bit onerous to download the notebook itself. The easiest way is to clone the entire repo, but if you’re not familiar with how to do that or don’t need all the code locally, try this:

  1. Follow the link above to view the list of notebooks

  2. Click on a notebook to view it in Github

  3. Locate the “Raw” button near the top-right corner of the notebook, right-click the button, and select your browser’s option to save the target of that link.