Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

2 watching

Forks

Latest commit

 

History

9 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Meraki API Scripts to Find Clients Matching MAC Addresses

How to run...

It is recommend to use a Python 3.8.X virtualenv to avoid installing packages in system Python. Please consult the Python Official Docs.

  • Open a terminal and Clone the repo.

    git clone https://github.com/IE-OnDemand/fhi360_MerakiBlocker
    cd fhi360_MerakiBlocker
  • Install requirements.

    pip install -r requirements.txt
  • Create environment variable MERAKI_DASHBOARD_API with your key or update the scripts manually with your Meraki API Key. Example using environment variables (recommended):

    touch .envrc
    echo "export MERAKI_DASHBOARD_API=987654321_MY_SUPER_SECRET_MERAKI_KEY_123456789" >> .envrc
    source .envrc
  • If you wish to block clients, you must update the script manually and change the following:

    BLOCK_BAD_CLIENTS = True
  • Run the script in "src" directory as required. See details below.

    ./src/mac_blocker.py

File Explanations

  • bad_macs.txt This file is used to locate MACs you wish to report or block on.

  • bad_companies.txt This file is used to locate companies you wish to report or block on. The manufacturer for each client determined using manuf and what's listed in Meraki are both processed. If either manufacturer is matched to one in this file, it is reported and/or blocked. The match does not have to exact. Uses: "if bad_company in mac_manufacturer" Example:

    • "Apple" will match manufacturer "Apple Corp.", "Apple Inc.", "Red Apple Distillery"
  • mac_blocker.py This script will write a report for BAD clients within the last 30 days for each network in seperate "network" folders. Also adds a column "blocked" which reports True if client has been blocked or False otherwise. Then it will write a final report of clients in a single CSV report.

Distribute freely and credit me, make money and share with me, lose money and don't ask me.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

2 watching

Forks

Releases

Packages

Contributors

Languages