Metadata-Version: 2.4
Name: securezy-cli
Version: 0.1.1
Summary: Lightweight security utility CLI (port scan, vault, crypto, hashing, reports, plugins).
Project-URL: Homepage, https://github.com/akashkokare2910/securezy-cli
Project-URL: Repository, https://github.com/akashkokare2910/securezy-cli
Project-URL: Issues, https://github.com/akashkokare2910/securezy-cli/issues
Author: Akash
License: MIT License
        
        Copyright (c) 2020 Parinz
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE
Keywords: audit,cli,encryption,hashing,network,security
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Security
Requires-Python: >=3.9
Requires-Dist: rich>=13.0.0
Requires-Dist: typer>=0.9.0
Provides-Extra: crypto
Requires-Dist: cryptography>=41.0.0; extra == 'crypto'
Provides-Extra: dev
Requires-Dist: pytest>=7.4.0; extra == 'dev'
Requires-Dist: ruff>=0.3.0; extra == 'dev'
Provides-Extra: vault
Requires-Dist: cryptography>=41.0.0; extra == 'vault'
Description-Content-Type: text/markdown

# Securezy CLI (`securezy-cli`)

Securezy CLI is a lightweight, pip-installable Python toolkit for common security tasks: fast port scanning, encrypted vault storage, file encryption, hashing, reporting, and plugins.

PyPI: `securezy-cli` (CLI command: `securezy`)

## Install (recommended)

Install from PyPI (recommended: use a virtualenv):

```powershell
py -m venv .venv
.\.venv\Scripts\python -m pip install -U pip
.\.venv\Scripts\python -m pip install "securezy-cli[crypto,vault]"
.\.venv\Scripts\securezy --help
```

For local development (editable):

```powershell
py -m venv .venv
.\.venv\Scripts\python -m pip install -U pip
.\.venv\Scripts\python -m pip install -e ".[dev,crypto,vault]"
.\.venv\Scripts\securezy --help
```

## CLI quickstart

Show commands:

```powershell
.\.venv\Scripts\securezy --help
```

### Fast port scanning

```powershell
.\.venv\Scripts\securezy scan ports -t 127.0.0.1 -p 1-1024
.\.venv\Scripts\securezy scan ports -t 127.0.0.1 -p 22,80,443 --timeout 0.8 --concurrency 800
.\.venv\Scripts\securezy scan ports -t 127.0.0.1 -p 1-1024 --json
```

### Scan reporting/export (JSON/CSV/Markdown)

Single report file:

```powershell
.\.venv\Scripts\securezy scan ports -t 127.0.0.1 -p 1-1024 --report .\report.json --report-format json
.\.venv\Scripts\securezy scan ports -t 127.0.0.1 -p 1-1024 --report .\report.md --report-format md
.\.venv\Scripts\securezy scan ports -t 127.0.0.1 -p 1-1024 --report .\report.csv --report-format csv
```

Report bundle directory:

```powershell
.\.venv\Scripts\securezy scan ports -t 127.0.0.1 -p 1-1024 --report-dir .\reports --report-formats json,md,csv
```

### Profiles (saved scan configs)

Create and use a profile:

```powershell
.\.venv\Scripts\securezy profiles set local -t 127.0.0.1 -p 1-1024 --timeout 0.5 --concurrency 500
.\.venv\Scripts\securezy profiles list
.\.venv\Scripts\securezy scan ports --profile local
```

Show where profiles are stored:

```powershell
.\.venv\Scripts\securezy profiles path
```

To store profiles in a custom location (useful for CI/tests):

```powershell
$env:SECUREZY_HOME = "C:\\temp\\securezy"
```

### Plugins

List and run plugins:

```powershell
.\.venv\Scripts\securezy plugins list
.\.venv\Scripts\securezy plugins run hello "hello from plugin"
```

Plugins are discovered via Python entrypoints group `securezy.plugins`.

Generate a new plugin skeleton:

```powershell
.\.venv\Scripts\securezy plugins scaffold my-plugin -o .
```

Then install it:

```powershell
cd .\securezy-plugin-my-plugin
py -m venv .venv
.\.venv\Scripts\python -m pip install -U pip
.\.venv\Scripts\python -m pip install -e .
```

And verify it shows up:

```powershell
.\.venv\Scripts\securezy plugins list
.\.venv\Scripts\securezy plugins run my-plugin "it works"
```

### Vault (encrypted credential storage)

```powershell
.\.venv\Scripts\securezy vault init
.\.venv\Scripts\securezy vault add github -u akash
.\.venv\Scripts\securezy vault get github --show-password
.\.venv\Scripts\securezy vault list
```

### Crypto (file encryption/decryption)

```powershell
.\.venv\Scripts\securezy crypto encrypt -i secret.txt -o secret.txt.sz
.\.venv\Scripts\securezy crypto decrypt -i secret.txt.sz -o secret.txt
```

### Hashing + verify

```powershell
.\.venv\Scripts\securezy hash text --algo sha256 "hello"
.\.venv\Scripts\securezy hash file --algo sha256 .\somefile.iso
.\.venv\Scripts\securezy hash verify --algo sha256 --hash <expected> --file .\somefile.iso
```

## Development

```powershell
.\.venv\Scripts\python -m ruff check securezy tests
.\.venv\Scripts\python -m pytest -q
```

## Publishing (TestPyPI / PyPI)

This repo includes a GitHub Actions workflow at `.github/workflows/release.yml`.

### Required GitHub secrets

Create these secrets in your GitHub repo settings:

- `PYPI_API_TOKEN`
- `TEST_PYPI_API_TOKEN`

### Publish to TestPyPI (recommended first)

Use GitHub Actions `Release` workflow → `Run workflow` → choose `testpypi`.

### Publish to PyPI

Option A (recommended): push a tag like `v0.1.0`:

```powershell
git tag v0.1.0
git push origin v0.1.0
```

Option B: run the GitHub Actions workflow manually and choose `pypi`.
