Skip to main content

lookup the ieee's oui table by mac, mac prefix, org name or country

Project description

how to..

… install:

pip3 install pyoui
# master branch should be stable as well
pip3 install git+https://github.com/smthnspcl/pyoui

… use by cli:

pyoui --help

usage: pyoui [-h] [-o OUTFILE] [-d] [-p PREFIX] [-c COMPANY]

optional arguments:
  -h, --help            show this help message and exit
  -o OUTFILE, --outfile OUTFILE
                        oui file which will be downloaded and read.
  -d, --debug           enable debugging
  -p PREFIX, --prefix PREFIX
                        search by mac prefix
  -c COMPANY, --company COMPANY
                        search by company name

… use by code:

from pyoui import OUI

entries = OUI(debug=True).parse()

print("entries:", entries.size())

e = next(entries.by_company("national security"))
print("company", e.company.__dict__, e.prefix)

e = next(entries.by_prefix("00:22:72"))
print("prefix", e.company.__dict__, e.prefix)

e = next(entries.by_mac("BC:23:92:42:42:42"))
print("mac", e.company.__dict__, e.prefix)

e = list(entries.by_country_code("US"))
print("length:", len(e))
print("first item:", e[0].prefix, e[0].company.__dict__)

other info:

the csv folder was generated by obsolete/dump.py
the folder obsolete is as the name implies, obsolete.
all files in there are py2 and won't be refactored.

the setup.py will only install the pyoui package.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyoui-0.43.tar.gz (2.2 kB view details)

Uploaded Source

Built Distributions

pyoui-0.43-py3.8.egg (2.1 kB view details)

Uploaded Source

pyoui-0.43-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file pyoui-0.43.tar.gz.

File metadata

  • Download URL: pyoui-0.43.tar.gz
  • Upload date:
  • Size: 2.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2

File hashes

Hashes for pyoui-0.43.tar.gz
Algorithm Hash digest
SHA256 2fbd8f722eee2929b9bb239873c3191ad6ffaff30a9c8aee3777a96d0a64ca50
MD5 d70d76435125b8589ac93d5ef6e7d845
BLAKE2b-256 0e745e09849e8a6e8ce8a2ab565461e8b92fa864bd2182815e3a2a0953e1beba

See more details on using hashes here.

File details

Details for the file pyoui-0.43-py3.8.egg.

File metadata

  • Download URL: pyoui-0.43-py3.8.egg
  • Upload date:
  • Size: 2.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2

File hashes

Hashes for pyoui-0.43-py3.8.egg
Algorithm Hash digest
SHA256 9b8ee14b6ccc70473340c2dfef238223cd5c134c229c40a2aa50ec6839a57934
MD5 f114564257078c25db187b3ae2dfd7e1
BLAKE2b-256 6825294703216fe798f3e46f5fe3e1a0fd8fd4bcbb4f27787d72132d67bba939

See more details on using hashes here.

File details

Details for the file pyoui-0.43-py3-none-any.whl.

File metadata

  • Download URL: pyoui-0.43-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2

File hashes

Hashes for pyoui-0.43-py3-none-any.whl
Algorithm Hash digest
SHA256 9bcc4ce2c432eb86e36dcac81394a563d5c74ece65b22d0834e66d698d062c90
MD5 291c2ecfb05765e161fced777e5c7464
BLAKE2b-256 8df7ebe48a21df6a50d0fa241c9ec212b68093cd9c0ee6bfd173897e0bcd2eff

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page