Skip to main content

py-ocsf-models

The py-ocsf-models package offers a Python implementation of the Open Cybersecurity Schema Framework (OCSF) models, facilitating the manipulation and understanding of cybersecurity data within Python applications. This package provides a rich set of models covering various aspects of cybersecurity events, findings, objects, and profiles as defined by the OCSF Schema, enabling developers to work with structured cybersecurity data efficiently.

In Prowler, we leverage the py-ocsf-models package to generate JSON formatted OCSF outputs, specifically focusing on Detection Findings. This integration facilitates the standardization and sharing of cybersecurity findings in a structured and widely-accepted format, enhancing the interoperability between different security tools and platforms.

Features

  • Comprehensive OCSF Schema Implementation: Includes models for events, findings, objects, and profiles, covering the entire OCSF Schema.
  • Easy Data Manipulation: Easily create, modify, and interact with cybersecurity data structures.
  • Serialization and Deserialization Support: Convert OCSF model instances to and from JSON for easy storage and transmission.
  • Extensible Design: Extend and customize models to fit specific requirements while staying compliant with the OCSF schema.

OCSF Coverage

  • Detection Finding
  • Compliance Finding
  • Application Security Posture Finding

Installation

Install py-ocsf-models using pip:

pip install py-ocsf-models

Import the package in your Python application:

import py_ocsf_models

Usage Examples

You can find ready-to-run examples demonstrating how to generate events using the OCSF schema in the examples folder.

How to Release

To release a new version of py-ocsf-models:

  1. Create a PR with version update: Update the version number in pyproject.toml and create a pull request with the changes.

  2. Create a GitHub release: Once the PR is merged into the master branch, create a new release in GitHub from the master branch. This will automatically trigger the pypi-release.yml workflow to publish the package to PyPI.

Contributing

Contributions are welcome! Whether you're fixing a bug, adding new features, or improving the documentation, please feel free to make a pull request or open an issue.

License

This project is licensed under the Apache-2.0 License - see the LICENSE file for details.

Acknowledgments

This package is built to support and encourage the adoption of the Open Cybersecurity Schema Framework (OCSF) and facilitate the handling of cybersecurity data in Python applications.

Support

For support, questions, or feedback, please open an issue on the GitHub repository.

Metadata

Release files for py-ocsf-models 0.10.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 py-ocsf-models 0.10.0
File Size Uploaded
py_ocsf_models-0.10.0.tar.gz 36.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for py-ocsf-models 0.10.0
File Interpreter ABI Platform
py_ocsf_models-0.10.0-py3-none-any.whl Python 3 none any Details

Total release size: 100.8 kB

Release files / py_ocsf_models-0.10.0.tar.gz

Download URL py_ocsf_models-0.10.0.tar.gz
Size 36.5 kB
Tags Source
SHA-256 checksum
How to use checksums
29abaa5a3d4ebba0e2a21757508a4848fa5e1d57da233af57e580f97f0223c59
BLAKE2b-256 checksum
How to use checksums
70d6f0787cbe953e3cf6ef4430f3cc7d66cbbaabe4b20cb82cc27cc2d21e622a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.13

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 13, 2026.

Transparency log

Release files / py_ocsf_models-0.10.0-py3-none-any.whl

Download URL py_ocsf_models-0.10.0-py3-none-any.whl
Size 64.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a9d1e245b1c9fba1d2cb8c042253ef1b83a2dbfec30ed69975bbce599b4510bb
BLAKE2b-256 checksum
How to use checksums
7556eca45ec87a02f930cc7eaa7cb36660f69fb00c3d77bb4a84bb92d6c94c25
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.13

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 13, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.10.0 This release

2 release files

0.9.0

2 release files

0.8.1

2 release files

0.8.0

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

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