Skip to main content

PyLOOBins

PyLOOBins is a Python SDK and command-line utility for programmatically interacting with LOOBins.

You can download PyLOOBins from PyPI by running the following command: pip install pyloobins

PyLOOBins requires Python 3.8 or later.

Usage

Command-line

You can run pyloobins --help to see the available commands and options.

>>> pyloobins --help

Usage: pyloobins [OPTIONS] COMMAND [ARGS]...

  Create, validate, and view LOOBin objects.

Options:
  --help  Show this message and exit.

Commands:
  create    Create a YAML template file for a new LOOBin.
  get       Get a LOOBin object.
  validate  Validate a LOOBin YAML file.

You can run pyloobins <command> --help to see the available options for a specific command.

>>> pyloobins validate --help
Usage: pyloobins validate [OPTIONS]

  Validate a LOOBin YAML file.

Options:
  --path TEXT  The path of the LOOBin YAML file to validate.  [required]
  --help       Show this message and exit.

SDK

You can use pyloobins as a Python SDK to programmatically interact with LOOBins.

pyloobins.util

The util module can be used to get LOOBin objects from the LOOBins API, validate LOOBin YAML files, and create LOOBin YAML templates.

Example: get all LOOBins and print a list of the use case code.

from pyloobins import util

loobins = util.get_loobins()

for loobin in loobins:
  for uc in loobin.example_use_cases:
    print(f"{loobin.name}: {uc.code}")

pyloobins.models

The models module contains the classes that represent a LOOBin and its various components.

Example: programmitcally create a LOOBin object.

from pyloobins.models import Detection, ExampleUseCase, LOOBin, Resource

l = LOOBin(
        name="",
        short_description="A short description of the binary goes here.",
        full_description="A full length description of the binary goes here.",
        author="Enter your name or alias here.",
        created=date.today(),
        example_use_cases=[
            ExampleUseCase(
                name="An Example Use Case",
                description="A description of the use case goes here.",
                code="A code snippet goes here.",
                tactics=["Discovery"],
                tags=["example_tag", "another_tag"],
            )
        ],
        paths=["/enter/binary/path/here"],
        detections=[
            Detection(
                name="A detection source (e.g. Sigma)",
                url="https://urltodetection.here",
            )
        ],
        resources=[
            Resource(
                name="Name of resources.",
                url="https://urlofexternalreference.here",
            )
        ],
        acknowledgements=["Enter any acknowledgements here."],
    )

with open ("loobin.yaml", "w") as f:
  f.write(l.to_yaml())

Metadata

Release files for PyLOOBins 1.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for PyLOOBins 1.2.0
File Size Uploaded
pyloobins-1.2.0.tar.gz 38.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for PyLOOBins 1.2.0
File Interpreter ABI Platform
pyloobins-1.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 95.1 kB

Release files / pyloobins-1.2.0.tar.gz

Download URL pyloobins-1.2.0.tar.gz
Size 38.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ad73a7916b57059deb55f40aed4df6163b1b7290c4b451a46485f88184702138
BLAKE2b-256 checksum
How to use checksums
7adec59eb396c44808cba78031086a45f6e445682d6d8f765f10e48031dc4c55
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.6.1 CPython/3.11.4 Darwin/22.5.0

Release files / pyloobins-1.2.0-py3-none-any.whl

Download URL pyloobins-1.2.0-py3-none-any.whl
Size 56.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f73f76d0b94f997bb9888c04b3236b9558ff7c80ce1a1a3b020aee8bf4740315
BLAKE2b-256 checksum
How to use checksums
b9d2d1bd4161a3320a20d1c524deb2848dc75bdece1da8bbdf69e13892a0afaf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.6.1 CPython/3.11.4 Darwin/22.5.0

Release history Release notifications | RSS feed

2.0.14

2 release files

2.0.13

2 release files

2.0.12

2 release files

2.0.11

2 release files

2.0.10

2 release files

2.0.9

2 release files

2.0.8

2 release files

2.0.7

2 release files

2.0.6

2 release files

2.0.5

2 release files

2.0.4

2 release files

2.0.3

2 release files

2.0.2

2 release files

2.0.1

2 release files

2.0.0

2 release files

1.7.3

2 release files

1.7.2

2 release files

1.7.1

2 release files

1.7.0

2 release files

1.6.0

2 release files

1.5.0

2 release files

1.4.3

2 release files

1.4.2

2 release files

1.4.1

2 release files

1.4.0

2 release files

1.3.0

2 release files

This release

1.2.0 This release

2 release files

1.1.0

2 release files

1.0.0

2 release files

0.1.9

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page