https://github.com/prowler-cloud/py-ocsf-models
OCSF (https://schema.ocsf.io/) models in Python using Pydantic.
https://github.com/prowler-cloud/py-ocsf-models
Last synced: about 1 year ago
JSON representation
OCSF (https://schema.ocsf.io/) models in Python using Pydantic.
- Host: GitHub
- URL: https://github.com/prowler-cloud/py-ocsf-models
- Owner: prowler-cloud
- License: apache-2.0
- Created: 2024-02-13T14:30:04.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-03-31T17:51:26.000Z (about 1 year ago)
- Last Synced: 2025-03-31T18:21:54.804Z (about 1 year ago)
- Language: Python
- Homepage:
- Size: 580 KB
- Stars: 21
- Watchers: 4
- Forks: 6
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
# 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](https://github.com/prowler-cloud/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
Soon ...
## Installation
Install `py-ocsf-models` using pip:
```bash
pip install py-ocsf-models
```
Import the package in your Python application:
```python
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](./examples/) folder.
## 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](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.