device-certificate-report


Namedevice-certificate-report JSON
Version 0.1.2 PyPI version JSON
download
home_pageNone
SummaryA tool to generate device certificate reports from PAN-OS devices.
upload_time2024-10-02 21:09:55
maintainerNone
docs_urlNone
authorCalvin Remsburg
requires_python<4.0,>=3.10
licenseApache 2.0
keywords paloaltonetworks panos firewall certificate report automation
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # PAN-OS Device Certificate Report

![Banner Image](https://raw.githubusercontent.com/cdot65/device-certificate-report/refs/heads/main/device_certificate_report/assets/logo.svg)

[![Build Status](https://github.com/cdot65/device-certificate-report/actions/workflows/ci.yml/badge.svg)](https://github.com/cdot65/device-certificate-report/actions/workflows/ci.yml)
[![PyPI version](https://badge.fury.io/py/device-certificate-report.svg)](https://badge.fury.io/py/device-certificate-report)
[![Python versions](https://img.shields.io/pypi/pyversions/device-certificate-report.svg)](https://pypi.org/project/device-certificate-report/)
[![License](https://img.shields.io/github/license/cdot65/device-certificate-report.svg)](https://github.com/cdot65/device-certificate-report/blob/main/LICENSE)

A CLI tool to generate device certificate reports from Palo Alto Networks PAN-OS devices.

This tool assists customers in navigating the information provided within [this Knowledge Base article](https://live.paloaltonetworks.com/t5/customer-advisories/update-to-additional-pan-os-certificate-expirations-and-new/ta-p/572158).

## Table of Contents

- [Features](#features)
- [Installation](#installation)
- [Usage](#usage)
  - [CSV Subcommand](#csv-subcommand)
  - [Panorama Subcommand](#panorama-subcommand)
  - [Firewall Subcommand](#firewall-subcommand)
- [Contributing](#contributing)
- [License](#license)
- [Support](#support)

## Features

- **Multiple Data Sources**: Collect device information from CSV files, Panorama appliances, or individual firewalls.
- **Comprehensive Reports**: Generates detailed PDF reports including device certificate status, software versions, and upgrade requirements.
- **Easy to Use**: Provides a straightforward command-line interface powered by [Typer](https://typer.tiangolo.com/).
- **Data Validation**: Utilizes [Pydantic](https://pydantic-docs.helpmanual.io/) models for robust data handling.
- **Flexible Workflows**: Supports multiple workflows for different use cases and environments.

## Installation

Requires Python 3.10 or higher.

Install the package using pip:

```bash
$ pip install device-certificate-report
---> 100%
Successfully installed device-certificate-report
```

## Usage

The `device-certificate-report` utility provides three subcommands:

- [`csv`](#csv-subcommand): Generate a report from a CSV file containing device information.
- [`panorama`](#panorama-subcommand): Connect to a Panorama appliance to retrieve connected firewalls and generate a report.
- [`firewall`](#firewall-subcommand): Connect directly to a firewall appliance to generate a report.

### CSV Subcommand

Process a CSV file to generate the report.

```bash
$ device-certificate-report csv --csv-file <path_to_csv_file> --output-file <output_pdf>
```

* `--csv-file` and `--output-file` flags are optional*

**Examples:**

```bash
$ device-certificate-report csv                                                                                                                                                                                        ─╯
CSV file path: panorama.csv
Cleaned CSV file saved as: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv
Processing cleaned CSV file: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv
Report generated at device_certificate_report.pdf
```

```bash
$ device-certificate-report csv --csv-file panorama.csv --output-file device_certificate_report.pdf                                                                                                                    ─╯
Cleaned CSV file saved as: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv
Processing cleaned CSV file: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv
Report generated at device_certificate_report.pdf
```

### Panorama Subcommand

Connect to a Panorama appliance and generate the report from connected firewalls.

```bash
$ device-certificate-report panorama --hostname <panorama_ip> --username <user> --password <password> --output-file <output_pdf>
```

* `--hostname`, `--username`, `--password`, and `--output-file` flags are optional*


**Examples:**

```bash
$ device-certificate-report panorama                                                                                                                                                                                   ─╯
Panorama hostname or IP: panorama1.example.io
Panorama username: admin
Panorama password: 
Connecting to Panorama at panorama1.example.io
INFO:device_certificate_report.components.data_collection:Sending operational command to Panorama to retrieve all devices.
INFO:device_certificate_report.components.data_collection:Parsing XML response from Panorama.
INFO:device_certificate_report.components.data_collection:Found 14 devices connected to Panorama.
Report generated at device_certificate_report.pdf
```

```bash
$ device-certificate-report panorama --hostname panorama.example.io --username admin --password paloalto123 --output-file panorama_report.pdf                                                                      ─╯
Connecting to Panorama at panorama1.example.io
INFO:device_certificate_report.components.data_collection:Sending operational command to Panorama to retrieve all devices.
INFO:device_certificate_report.components.data_collection:Parsing XML response from Panorama.
INFO:device_certificate_report.components.data_collection:Found 14 devices connected to Panorama.
Report generated at panorama_report.pdf
```

### Firewall Subcommand

Connect to a single Firewall appliance and generate the report.

```bash
$ device-certificate-report firewall --hostname <firewall_ip> --username <user> --password <password> --output-file <output_pdf>
```

**Examples:**

```bash
$ device-certificate-report firewall                                                                                                                                                                                   ─╯
Firewall hostname or IP: austin-fw1.example.io
Firewall username: admin
Firewall password: 
Connecting to Firewall at austin-fw1.example.io
INFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve system info.
INFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve device certificate status.
INFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall system info.
INFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall device certificate status.
Report generated at austin-fw1.example.io.pdf
```

```bash
$ device-certificate-report firewall --hostname austin-fw1.example.io --username admin --password paloalto123 --output-file firewall.pdf                                                                            ─╯
Connecting to Firewall at austin-fw1.example.io
INFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve system info.
INFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve device certificate status.
INFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall system info.
INFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall device certificate status.
Report generated at firewall.pdf
```

**Note:** If `--output-file` is not specified, the report will be saved with a default name.

## Contributing

Contributions are welcome! Please follow these steps:

1. Fork the repository.
2. Create a new branch (`git checkout -b feature/your-feature`).
3. Commit your changes (`git commit -am 'Add some feature'`).
4. Push to the branch (`git push origin feature/your-feature`).
5. Open a Pull Request.

Please ensure that your code adheres to the existing coding standards and includes appropriate test coverage.

## License

This project is licensed under the Apache 2.0 License - see the [LICENSE](./LICENSE) file for details.

## Support

For details on the support provided by Palo Alto Networks for this project, please consult the [SUPPORT.md](./SUPPORT.md) file in the repository.

---

*More extensive documentation will be available through our GitHub Pages site.*

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "device-certificate-report",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.10",
    "maintainer_email": null,
    "keywords": "paloaltonetworks, panos, firewall, certificate, report, automation",
    "author": "Calvin Remsburg",
    "author_email": "cremsburg.dev@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/f4/bb/34011347c85dbc8b12b98a440833eef2b0d56eb3205d3e32634da56f4fde/device_certificate_report-0.1.2.tar.gz",
    "platform": null,
    "description": "# PAN-OS Device Certificate Report\n\n![Banner Image](https://raw.githubusercontent.com/cdot65/device-certificate-report/refs/heads/main/device_certificate_report/assets/logo.svg)\n\n[![Build Status](https://github.com/cdot65/device-certificate-report/actions/workflows/ci.yml/badge.svg)](https://github.com/cdot65/device-certificate-report/actions/workflows/ci.yml)\n[![PyPI version](https://badge.fury.io/py/device-certificate-report.svg)](https://badge.fury.io/py/device-certificate-report)\n[![Python versions](https://img.shields.io/pypi/pyversions/device-certificate-report.svg)](https://pypi.org/project/device-certificate-report/)\n[![License](https://img.shields.io/github/license/cdot65/device-certificate-report.svg)](https://github.com/cdot65/device-certificate-report/blob/main/LICENSE)\n\nA CLI tool to generate device certificate reports from Palo Alto Networks PAN-OS devices.\n\nThis tool assists customers in navigating the information provided within [this Knowledge Base article](https://live.paloaltonetworks.com/t5/customer-advisories/update-to-additional-pan-os-certificate-expirations-and-new/ta-p/572158).\n\n## Table of Contents\n\n- [Features](#features)\n- [Installation](#installation)\n- [Usage](#usage)\n  - [CSV Subcommand](#csv-subcommand)\n  - [Panorama Subcommand](#panorama-subcommand)\n  - [Firewall Subcommand](#firewall-subcommand)\n- [Contributing](#contributing)\n- [License](#license)\n- [Support](#support)\n\n## Features\n\n- **Multiple Data Sources**: Collect device information from CSV files, Panorama appliances, or individual firewalls.\n- **Comprehensive Reports**: Generates detailed PDF reports including device certificate status, software versions, and upgrade requirements.\n- **Easy to Use**: Provides a straightforward command-line interface powered by [Typer](https://typer.tiangolo.com/).\n- **Data Validation**: Utilizes [Pydantic](https://pydantic-docs.helpmanual.io/) models for robust data handling.\n- **Flexible Workflows**: Supports multiple workflows for different use cases and environments.\n\n## Installation\n\nRequires Python 3.10 or higher.\n\nInstall the package using pip:\n\n```bash\n$ pip install device-certificate-report\n---> 100%\nSuccessfully installed device-certificate-report\n```\n\n## Usage\n\nThe `device-certificate-report` utility provides three subcommands:\n\n- [`csv`](#csv-subcommand): Generate a report from a CSV file containing device information.\n- [`panorama`](#panorama-subcommand): Connect to a Panorama appliance to retrieve connected firewalls and generate a report.\n- [`firewall`](#firewall-subcommand): Connect directly to a firewall appliance to generate a report.\n\n### CSV Subcommand\n\nProcess a CSV file to generate the report.\n\n```bash\n$ device-certificate-report csv --csv-file <path_to_csv_file> --output-file <output_pdf>\n```\n\n* `--csv-file` and `--output-file` flags are optional*\n\n**Examples:**\n\n```bash\n$ device-certificate-report csv                                                                                                                                                                                        \u2500\u256f\nCSV file path: panorama.csv\nCleaned CSV file saved as: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv\nProcessing cleaned CSV file: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv\nReport generated at device_certificate_report.pdf\n```\n\n```bash\n$ device-certificate-report csv --csv-file panorama.csv --output-file device_certificate_report.pdf                                                                                                                    \u2500\u256f\nCleaned CSV file saved as: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv\nProcessing cleaned CSV file: /Users/cdot/development/cdot65/device_certificate_report/cleaned.csv\nReport generated at device_certificate_report.pdf\n```\n\n### Panorama Subcommand\n\nConnect to a Panorama appliance and generate the report from connected firewalls.\n\n```bash\n$ device-certificate-report panorama --hostname <panorama_ip> --username <user> --password <password> --output-file <output_pdf>\n```\n\n* `--hostname`, `--username`, `--password`, and `--output-file` flags are optional*\n\n\n**Examples:**\n\n```bash\n$ device-certificate-report panorama                                                                                                                                                                                   \u2500\u256f\nPanorama hostname or IP: panorama1.example.io\nPanorama username: admin\nPanorama password: \nConnecting to Panorama at panorama1.example.io\nINFO:device_certificate_report.components.data_collection:Sending operational command to Panorama to retrieve all devices.\nINFO:device_certificate_report.components.data_collection:Parsing XML response from Panorama.\nINFO:device_certificate_report.components.data_collection:Found 14 devices connected to Panorama.\nReport generated at device_certificate_report.pdf\n```\n\n```bash\n$ device-certificate-report panorama --hostname panorama.example.io --username admin --password paloalto123 --output-file panorama_report.pdf                                                                      \u2500\u256f\nConnecting to Panorama at panorama1.example.io\nINFO:device_certificate_report.components.data_collection:Sending operational command to Panorama to retrieve all devices.\nINFO:device_certificate_report.components.data_collection:Parsing XML response from Panorama.\nINFO:device_certificate_report.components.data_collection:Found 14 devices connected to Panorama.\nReport generated at panorama_report.pdf\n```\n\n### Firewall Subcommand\n\nConnect to a single Firewall appliance and generate the report.\n\n```bash\n$ device-certificate-report firewall --hostname <firewall_ip> --username <user> --password <password> --output-file <output_pdf>\n```\n\n**Examples:**\n\n```bash\n$ device-certificate-report firewall                                                                                                                                                                                   \u2500\u256f\nFirewall hostname or IP: austin-fw1.example.io\nFirewall username: admin\nFirewall password: \nConnecting to Firewall at austin-fw1.example.io\nINFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve system info.\nINFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve device certificate status.\nINFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall system info.\nINFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall device certificate status.\nReport generated at austin-fw1.example.io.pdf\n```\n\n```bash\n$ device-certificate-report firewall --hostname austin-fw1.example.io --username admin --password paloalto123 --output-file firewall.pdf                                                                            \u2500\u256f\nConnecting to Firewall at austin-fw1.example.io\nINFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve system info.\nINFO:device_certificate_report.components.data_collection:Sending operational command to Firewall to retrieve device certificate status.\nINFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall system info.\nINFO:device_certificate_report.components.data_collection:Parsing XML response from Firewall device certificate status.\nReport generated at firewall.pdf\n```\n\n**Note:** If `--output-file` is not specified, the report will be saved with a default name.\n\n## Contributing\n\nContributions are welcome! Please follow these steps:\n\n1. Fork the repository.\n2. Create a new branch (`git checkout -b feature/your-feature`).\n3. Commit your changes (`git commit -am 'Add some feature'`).\n4. Push to the branch (`git push origin feature/your-feature`).\n5. Open a Pull Request.\n\nPlease ensure that your code adheres to the existing coding standards and includes appropriate test coverage.\n\n## License\n\nThis project is licensed under the Apache 2.0 License - see the [LICENSE](./LICENSE) file for details.\n\n## Support\n\nFor details on the support provided by Palo Alto Networks for this project, please consult the [SUPPORT.md](./SUPPORT.md) file in the repository.\n\n---\n\n*More extensive documentation will be available through our GitHub Pages site.*\n",
    "bugtrack_url": null,
    "license": "Apache 2.0",
    "summary": "A tool to generate device certificate reports from PAN-OS devices.",
    "version": "0.1.2",
    "project_urls": {
        "Documentation": "https://cdot65.github.io/device-certificate-report/"
    },
    "split_keywords": [
        "paloaltonetworks",
        " panos",
        " firewall",
        " certificate",
        " report",
        " automation"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3380c48c159de1fc6368b90b5f1dffe170c18116ee91b7d13965eb18a667a924",
                "md5": "ffa5d505e9374d845a598218bd8be31b",
                "sha256": "0112786742aeca869887aab388bf465954e7cfbbb75298c66ed73c41b851700e"
            },
            "downloads": -1,
            "filename": "device_certificate_report-0.1.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ffa5d505e9374d845a598218bd8be31b",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.10",
            "size": 23713,
            "upload_time": "2024-10-02T21:09:53",
            "upload_time_iso_8601": "2024-10-02T21:09:53.887087Z",
            "url": "https://files.pythonhosted.org/packages/33/80/c48c159de1fc6368b90b5f1dffe170c18116ee91b7d13965eb18a667a924/device_certificate_report-0.1.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f4bb34011347c85dbc8b12b98a440833eef2b0d56eb3205d3e32634da56f4fde",
                "md5": "51b384e36d8c645a8e96a4e19f090e49",
                "sha256": "2208c91b278025b237fc1934994dadaf8b0142295b4a7f053aac9d7a8f8b04e9"
            },
            "downloads": -1,
            "filename": "device_certificate_report-0.1.2.tar.gz",
            "has_sig": false,
            "md5_digest": "51b384e36d8c645a8e96a4e19f090e49",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.10",
            "size": 21530,
            "upload_time": "2024-10-02T21:09:55",
            "upload_time_iso_8601": "2024-10-02T21:09:55.007827Z",
            "url": "https://files.pythonhosted.org/packages/f4/bb/34011347c85dbc8b12b98a440833eef2b0d56eb3205d3e32634da56f4fde/device_certificate_report-0.1.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-02 21:09:55",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "device-certificate-report"
}
        
Elapsed time: 0.31100s