opskit 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,171 @@
1
+ Metadata-Version: 2.4
2
+ Name: opskit
3
+ Version: 0.1.0
4
+ Summary: Cross-platform diagnostics for engineers — one toolkit, every OS.
5
+ Project-URL: Homepage, https://github.com/Prabhakar-cg/opskit
6
+ Project-URL: Repository, https://github.com/Prabhakar-cg/opskit
7
+ Project-URL: Issues, https://github.com/Prabhakar-cg/opskit/issues
8
+ Project-URL: Changelog, https://github.com/Prabhakar-cg/opskit/blob/main/CHANGELOG.md
9
+ Author: prabhakar-cg
10
+ License-Expression: MIT
11
+ License-File: LICENSE
12
+ Keywords: cli,diagnostics,dns,networking,ops,troubleshooting
13
+ Classifier: Development Status :: 3 - Alpha
14
+ Classifier: Environment :: Console
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: Intended Audience :: System Administrators
17
+ Classifier: Operating System :: OS Independent
18
+ Classifier: Programming Language :: Python :: 3 :: Only
19
+ Classifier: Programming Language :: Python :: 3.9
20
+ Classifier: Programming Language :: Python :: 3.10
21
+ Classifier: Programming Language :: Python :: 3.11
22
+ Classifier: Programming Language :: Python :: 3.12
23
+ Classifier: Programming Language :: Python :: 3.13
24
+ Classifier: Topic :: System :: Networking
25
+ Classifier: Topic :: Utilities
26
+ Classifier: Typing :: Typed
27
+ Requires-Python: >=3.9.2
28
+ Requires-Dist: cryptography<49,>=48.0.1
29
+ Requires-Dist: dnspython<3,>=2.6
30
+ Requires-Dist: platformdirs<5,>=4
31
+ Requires-Dist: pyopenssl<27,>=24
32
+ Requires-Dist: rich<16,>=13
33
+ Requires-Dist: tomli>=2; python_version < '3.11'
34
+ Requires-Dist: typer<1,>=0.12
35
+ Provides-Extra: dev
36
+ Requires-Dist: dnslib>=0.9; extra == 'dev'
37
+ Requires-Dist: hypothesis>=6; extra == 'dev'
38
+ Requires-Dist: mypy>=1.11; extra == 'dev'
39
+ Requires-Dist: nox>=2024.4; (python_version >= '3.10') and extra == 'dev'
40
+ Requires-Dist: pip-audit>=2.7; (python_version >= '3.10') and extra == 'dev'
41
+ Requires-Dist: pre-commit>=3.7; (python_version >= '3.10') and extra == 'dev'
42
+ Requires-Dist: pyright>=1.1.380; extra == 'dev'
43
+ Requires-Dist: pytest-cov>=5; extra == 'dev'
44
+ Requires-Dist: pytest>=8; extra == 'dev'
45
+ Requires-Dist: ruff>=0.6; extra == 'dev'
46
+ Description-Content-Type: text/markdown
47
+
48
+ # opskit
49
+
50
+ Cross-platform diagnostics for engineers — one toolkit, every OS.
51
+
52
+ [![CI](https://github.com/Prabhakar-cg/opskit/actions/workflows/ci.yml/badge.svg)](https://github.com/Prabhakar-cg/opskit/actions/workflows/ci.yml)
53
+ [![CodeQL](https://github.com/Prabhakar-cg/opskit/actions/workflows/codeql.yml/badge.svg)](https://github.com/Prabhakar-cg/opskit/actions/workflows/codeql.yml)
54
+ [![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/Prabhakar-cg/opskit/badge)](https://securityscorecards.dev/viewer/?uri=github.com/Prabhakar-cg/opskit)
55
+ [![OpenSSF Best Practices](https://www.bestpractices.dev/projects/13462/badge)](https://www.bestpractices.dev/projects/13462)
56
+ [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=Prabhakar-cg_opskit&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=Prabhakar-cg_opskit)
57
+ [![Known Vulnerabilities](https://snyk.io/test/github/Prabhakar-cg/opskit/badge.svg)](https://snyk.io/test/github/Prabhakar-cg/opskit)
58
+ ![CodeRabbit Pull Request Reviews](https://img.shields.io/coderabbit/prs/github/Prabhakar-cg/opskit?utm_source=oss&utm_medium=github&utm_campaign=Prabhakar-cg%2Fopskit&labelColor=171717&color=FF570A&link=https%3A%2F%2Fcoderabbit.ai&label=CodeRabbit+Reviews)
59
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)
60
+ [![Python](https://img.shields.io/badge/python-3.9%20|%203.10%20|%203.11%20|%203.12%20|%203.13-blue)](pyproject.toml)
61
+
62
+ **opskit** gives engineers, developers, and operations teams one consistent set of read-only
63
+ troubleshooting commands that behave **identically on Windows, macOS, and Linux** — so you stop
64
+ juggling `nslookup` vs `dig` vs PowerShell cmdlets. It's a **CLI *and* an importable Python
65
+ library**, is pure-Python (nothing to shell out to), and never phones home.
66
+
67
+ > ⚠️ **Early development.** v1 ships **DNS diagnostics**; network / TLS / AD categories follow.
68
+
69
+ ---
70
+
71
+ ## Contents
72
+
73
+ - [Install](#install)
74
+ - [Commands](#commands)
75
+ - [Why opskit](#why-opskit)
76
+ - [Output & exit codes](#output--exit-codes)
77
+ - [Development](#development)
78
+ - [Security](#security)
79
+ - [License](#license)
80
+
81
+ ---
82
+
83
+ ## Install
84
+
85
+ ```bash
86
+ pip install opskit # once published
87
+ # or, from source:
88
+ git clone https://github.com/Prabhakar-cg/opskit && cd opskit
89
+ uv sync # or: pip install -e .
90
+ ```
91
+
92
+ Everything lives under a single command; each category is a sub-command group:
93
+
94
+ ```bash
95
+ opskit --help # top-level help
96
+ opskit dns --help # the DNS command group
97
+ opskit dns lookup --help # a specific command (grouped options + examples)
98
+ ```
99
+
100
+ ## Commands
101
+
102
+ Each command group is self-contained and documented in its own README next to the code:
103
+
104
+ | Command group | What it does | Docs |
105
+ |---|---|---|
106
+ | `opskit dns` | Read-only DNS diagnostics — forward/reverse lookups, multi-resolver diff, iterative trace, watch | [dns/README.md](src/opskit/dns/README.md) |
107
+ | `opskit tls` | TLS verification — layered endpoint checks, certificate/chain inspection, expiry warnings, private-PKI trust | [tls/README.md](src/opskit/tls/README.md) |
108
+ | `opskit net` | Network reachability (TCP connect, port checks) — the connect primitive already ships as the `opskit.net` library | _planned_ |
109
+ | `opskit ad` | Directory (LDAP/AD) queries | _planned_ |
110
+
111
+ Quick taste of the DNS group:
112
+
113
+ ```bash
114
+ opskit dns lookup example.com # A records, pretty table
115
+ opskit dns lookup example.com --all # every common record type at once
116
+ opskit dns reverse 8.8.8.8 # PTR (IP → hostname)
117
+ opskit dns lookup example.com --diff -s 1.1.1.1 -s 8.8.8.8 # compare resolvers
118
+ ```
119
+
120
+ See **[the DNS command reference](src/opskit/dns/README.md)** for every option, mode, and the
121
+ importable Python API.
122
+
123
+ ## Why opskit
124
+
125
+ - **One tool, every OS.** Identical behavior and output on Windows, macOS, and Linux — no more
126
+ remembering which flag `nslookup` uses versus `dig` versus `Resolve-DnsName`.
127
+ - **CLI *and* library.** Every capability is importable, typed, and API-first; the CLI is a thin
128
+ client over it. Ships `py.typed`.
129
+ - **Scriptable by design.** A stable, versioned `--json` envelope, NDJSON `--jsonl`, and
130
+ structured exit codes make it safe to build automation on.
131
+ - **Read-only & private.** Only performs the diagnostic you asked for; no telemetry, no phoning
132
+ home, no offensive/abuse features.
133
+
134
+ ## Output & exit codes
135
+
136
+ Every command shares one output contract:
137
+
138
+ - **Human** (default): colorized tables, auto-plain when piped; honors `NO_COLOR` and `--no-color`.
139
+ - **`--json`**: a stable, versioned envelope (`schema_version`, `command`, `query`, `result`,
140
+ `error`, `elapsed_ms`); an array for batches.
141
+ - **`--jsonl`**: NDJSON — one envelope per line, ideal for `jq` / streaming.
142
+ - **Exit codes** are documented and scriptable (`0` success, `2` usage error, `7` partial, plus
143
+ category-specific codes). See each command's README for the full table.
144
+
145
+ ## Development
146
+
147
+ Built to a high bar: `src/` layout, [uv](https://docs.astral.sh/uv/), Ruff, `mypy --strict` +
148
+ pyright, pytest with ≥90% coverage, and a hardened CI/CD pipeline (see [`docs/PLAN.md`](docs/PLAN.md)
149
+ and the project constitution in [`.specify/memory/constitution.md`](.specify/memory/constitution.md)).
150
+
151
+ ```bash
152
+ uv sync --extra dev
153
+ uv run opskit dns lookup example.com # run the CLI
154
+ uv run ruff format --check . && uv run ruff check . # format + lint
155
+ uv run mypy && uv run pyright # types
156
+ uv run pytest # tests (coverage ≥ 90%)
157
+ ```
158
+
159
+ These are exactly the gates CI runs on every pull request — see
160
+ [`.github/workflows/ci.yml`](.github/workflows/ci.yml).
161
+
162
+ Contributions go through PRs into a protected `main` (squash-merge, Conventional Commits).
163
+
164
+ ## Security
165
+
166
+ Report vulnerabilities privately — see [SECURITY.md](SECURITY.md). Every PR is gated by a full
167
+ scanner suite (pip-audit, Ruff `S`, CodeQL, secret scanning, dependency review, SonarCloud, Snyk).
168
+
169
+ ## License
170
+
171
+ [MIT](LICENSE) © `prabhakar-cg`. Provided as-is, without warranty.
@@ -0,0 +1,35 @@
1
+ opskit/__init__.py,sha256=RENuuWvZ25oyaOeaBJjFJ_7yvStrWkdBQ_BMi6Rd-jk,522
2
+ opskit/__main__.py,sha256=F51GXYwlWZeK-5I1i6Ej120dJ1fTFCnXzHVed46axcc,159
3
+ opskit/cli.py,sha256=hC_ijfELBDi0XHarSlxT_9JAsNDEv1AteKnwgpEEfVk,1255
4
+ opskit/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
+ opskit/core/__init__.py,sha256=qRjrZtI6DY1TgBOcxVaxq1bTdSzjse3vu4jn_HXAxMs,339
6
+ opskit/core/cliutils.py,sha256=zD2muKXjcGfY9b78LyCMf-SVhXh7L4bP2cpcOVCw9XA,5970
7
+ opskit/core/errors.py,sha256=14wmEkbB_JeeuotMAe3ey5u5L-h23uWCqMwpPLSrdb8,1275
8
+ opskit/core/exit_codes.py,sha256=VI1dpefkiQ9M_UHu7fgx7pyIPxPM9E5x4lF7nwYS1pw,991
9
+ opskit/core/output.py,sha256=d9-oLIU2m38-a8LwunG6Uhc29wubdxMP2YHdazsIy_w,757
10
+ opskit/core/result.py,sha256=9Lqumml1RFNd9pYrMKvgTYsK6K7crGWfXDN1YftUE58,1186
11
+ opskit/dns/README.md,sha256=LlettX_pFyN6F5PmN1Aq0OASC_WGcZkiZR-uFM9TASk,6999
12
+ opskit/dns/__init__.py,sha256=3nWA5SChFDO3h4cbFBYvZxlPNfoSherJXg3zulWXr8E,1102
13
+ opskit/dns/api.py,sha256=gtY92G2gg5l2oWnD3Lqvvliif5hAMrdOWnpNneyXo70,12968
14
+ opskit/dns/cli.py,sha256=Lwb1zBDCR_idKR5FMero_UBOzXDJpJwOVbb4L7NTos0,19253
15
+ opskit/dns/errors.py,sha256=Lgu5DhYNQiRhypqHc3P9JI6iuz6wXsQ-NH88RFCFWNs,1084
16
+ opskit/dns/models.py,sha256=qRQ3lg2Gimo2oF_v2WddzQVqY4LuVsj039yy0ZxhppI,5653
17
+ opskit/dns/output.py,sha256=uskOo3vnZ4oXn8TI0hizEXDUPvEJrwesdRXEPwvwB88,3385
18
+ opskit/dns/resolver.py,sha256=k1A1upD_tYkwTWuaSW14ELtc_yQ100yMlvZ3belBcZc,9123
19
+ opskit/net/__init__.py,sha256=ITamWIiSqB7ek7nGd7eBMgvGAFC_4jsXYcP1R7d8N_s,641
20
+ opskit/net/errors.py,sha256=LxkfVups2WfpNZ-Ko44BjYJsQRxPi6f2zo1P5og6_b0,1092
21
+ opskit/net/tcp.py,sha256=J2PXPEMApWXbyYcbcMbceXt7gozRWejcGQmm8ulLvOQ,6023
22
+ opskit/tls/README.md,sha256=Yk0PbMAlzSS64FvfwOhq0NRkHG4qjNIPjXMuHE-ljIE,6655
23
+ opskit/tls/__init__.py,sha256=3lHFBINOCWC7AgIcEUrUpuoas8KYeuPhP3tAKBNmYJw,845
24
+ opskit/tls/api.py,sha256=dqpQf1QKXVHLiMyxwIUZXZNFed47Tltmf1_IsqS-r2s,5457
25
+ opskit/tls/cli.py,sha256=UCQBuzo_4LUbRgYMGSecXMN2Zfm-C2TNDGR6BssOY3s,8536
26
+ opskit/tls/errors.py,sha256=OSoZZI5e-iUgIzivKBT7FiZpE4Wpzxov4Yj0OrAFTHg,1852
27
+ opskit/tls/handshake.py,sha256=mTjemcuo4AB-3vj7Hdu2LrtDZ2j-MDW6T6by12sr66s,10070
28
+ opskit/tls/inspect.py,sha256=WJg5RYJvIiXTH25TElbUqtjfb0njrTEAlzeK4G4jj4c,9881
29
+ opskit/tls/models.py,sha256=mWY_dNYpBP7IyUSHLg5pYocevv24oXGTSe1lcbNQMCs,7834
30
+ opskit/tls/output.py,sha256=I30b0JDorwtrni9R6oX7iCtE-0ziBq-g0WAxsbhCyjg,3307
31
+ opskit-0.1.0.dist-info/METADATA,sha256=kjDVdAxreQJNfh3G29u4roWPRr8IMWEjQwPM6SFVTjg,8120
32
+ opskit-0.1.0.dist-info/WHEEL,sha256=lCkmxWfQsSc9CfIClYeavTdQeEX2toPqufh9gI35EQA,87
33
+ opskit-0.1.0.dist-info/entry_points.txt,sha256=-s20XnEY1-fuebLs8s9xi6a2ZOjGm9MmKP8ixnCQtsU,43
34
+ opskit-0.1.0.dist-info/licenses/LICENSE,sha256=NWQaI0KLknzrx-KPkUoVMbkzho91Ms014AV85ao-wfE,1069
35
+ opskit-0.1.0.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: hatchling 1.31.0
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ opskit = opskit.cli:main
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 prabhakar-cg
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.