cyinfo 1.0.0__tar.gz
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.
- cyinfo-1.0.0/LICENSE.txt +21 -0
- cyinfo-1.0.0/PKG-INFO +196 -0
- cyinfo-1.0.0/README.md +154 -0
- cyinfo-1.0.0/pyproject.toml +82 -0
- cyinfo-1.0.0/setup.cfg +4 -0
- cyinfo-1.0.0/setup.py +23 -0
- cyinfo-1.0.0/src/cyinfo/__init__.py +69 -0
- cyinfo-1.0.0/src/cyinfo/cert_analyzer.py +1104 -0
- cyinfo-1.0.0/src/cyinfo/cli.py +116 -0
- cyinfo-1.0.0/src/cyinfo/py.typed +1 -0
- cyinfo-1.0.0/src/cyinfo/pycurl_inspector.py +1588 -0
- cyinfo-1.0.0/src/cyinfo/scanner.py +882 -0
- cyinfo-1.0.0/src/cyinfo.egg-info/PKG-INFO +196 -0
- cyinfo-1.0.0/src/cyinfo.egg-info/SOURCES.txt +17 -0
- cyinfo-1.0.0/src/cyinfo.egg-info/dependency_links.txt +1 -0
- cyinfo-1.0.0/src/cyinfo.egg-info/entry_points.txt +2 -0
- cyinfo-1.0.0/src/cyinfo.egg-info/requires.txt +16 -0
- cyinfo-1.0.0/src/cyinfo.egg-info/top_level.txt +1 -0
- cyinfo-1.0.0/tests/test_basic.py +109 -0
cyinfo-1.0.0/LICENSE.txt
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 sripa
|
|
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.
|
cyinfo-1.0.0/PKG-INFO
ADDED
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: cyinfo
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: A comprehensive network security toolkit — SSL/TLS analysis, certificate inspection, vulnerability scanning, and deep HTTP/TLS probing via pycurl.
|
|
5
|
+
Author: sripa
|
|
6
|
+
Project-URL: Homepage, https://github.com/sripa/cyinfo
|
|
7
|
+
Project-URL: Documentation, https://github.com/sripa/cyinfo#readme
|
|
8
|
+
Project-URL: Repository, https://github.com/sripa/cyinfo
|
|
9
|
+
Project-URL: Issues, https://github.com/sripa/cyinfo/issues
|
|
10
|
+
Keywords: cybersecurity,ssl,tls,certificate,scanner,vulnerability,network,pycurl,security,pentest
|
|
11
|
+
Classifier: Development Status :: 4 - Beta
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: Intended Audience :: Information Technology
|
|
14
|
+
Classifier: Intended Audience :: System Administrators
|
|
15
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
16
|
+
Classifier: Operating System :: OS Independent
|
|
17
|
+
Classifier: Programming Language :: Python :: 3
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
23
|
+
Classifier: Topic :: Security
|
|
24
|
+
Classifier: Topic :: Internet :: WWW/HTTP
|
|
25
|
+
Classifier: Topic :: System :: Networking
|
|
26
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
27
|
+
Requires-Python: >=3.9
|
|
28
|
+
Description-Content-Type: text/markdown
|
|
29
|
+
Requires-Dist: requests>=2.28.0
|
|
30
|
+
Requires-Dist: dnspython>=2.3.0
|
|
31
|
+
Requires-Dist: pyOpenSSL>=23.0.0
|
|
32
|
+
Requires-Dist: pycurl>=7.45.0
|
|
33
|
+
Provides-Extra: jks
|
|
34
|
+
Requires-Dist: pyjks>=20.0.0; extra == "jks"
|
|
35
|
+
Provides-Extra: all
|
|
36
|
+
Requires-Dist: pyjks>=20.0.0; extra == "all"
|
|
37
|
+
Provides-Extra: dev
|
|
38
|
+
Requires-Dist: pytest>=7.0; extra == "dev"
|
|
39
|
+
Requires-Dist: pytest-cov>=4.0; extra == "dev"
|
|
40
|
+
Requires-Dist: build>=0.10; extra == "dev"
|
|
41
|
+
Requires-Dist: twine>=4.0; extra == "dev"
|
|
42
|
+
|
|
43
|
+
# CyInfo
|
|
44
|
+
|
|
45
|
+
A comprehensive Python network security toolkit for SSL/TLS analysis, certificate inspection, vulnerability scanning, and deep HTTP/TLS probing.
|
|
46
|
+
|
|
47
|
+
[](https://pypi.org/project/cyinfo/)
|
|
48
|
+
[](https://www.python.org/downloads/)
|
|
49
|
+
[](https://opensource.org/licenses/MIT)
|
|
50
|
+
|
|
51
|
+
---
|
|
52
|
+
|
|
53
|
+
## Features
|
|
54
|
+
|
|
55
|
+
### 🔍 Network Scanner (`cyinfo.scanner`)
|
|
56
|
+
Three-tier scanning with increasing depth:
|
|
57
|
+
|
|
58
|
+
| Level | Method | What it does |
|
|
59
|
+
|-------|--------|-------------|
|
|
60
|
+
| **Basic** | `basic_scan(target)` | IP resolution, DNS records (A/AAAA/MX/NS/TXT/CNAME/SOA), geolocation, HTTP status, reverse DNS |
|
|
61
|
+
| **Medium** | `medium_scan(target)` | SSL certificate details, TLS version, cipher suite, security headers grading, port scan with banner grabbing |
|
|
62
|
+
| **Advanced** | `advanced_scan(target)` | SSL handshake breakdown, encryption algorithms, PFS analysis, full certificate chain via pyOpenSSL |
|
|
63
|
+
| **Full** | `full_scan(target)` | Runs all three levels |
|
|
64
|
+
|
|
65
|
+
### 🔐 Certificate Analyzer (`cyinfo.cert_analyzer`)
|
|
66
|
+
Deep certificate and keystore inspection:
|
|
67
|
+
|
|
68
|
+
- **`analyze_certificate(path)`** — Parse any cert format (PEM, DER, CRT, CER, P7B). Extracts: type/usage, subject, issuer, dates, fingerprints (SHA-256/SHA-1/MD5), crypto suite, key usage, SANs, extensions, and more.
|
|
69
|
+
- **`analyze_keystore(path, password)`** — Parse PKCS12/PFX and JKS keystores. Extracts private key info, certificate chain, and all cert details.
|
|
70
|
+
- **`test_ssl_with_private_key(key, cert, port)`** — Bind a private key to a socket and test all TLS versions with 20-field handshake detail extraction.
|
|
71
|
+
|
|
72
|
+
### 🌐 PyCurl Inspector (`cyinfo.pycurl_inspector`)
|
|
73
|
+
Low-level HTTP/TLS analysis using only pycurl — **17 parameters tested**:
|
|
74
|
+
|
|
75
|
+
TLS handshake • Certificate chain & fingerprints • TLS version probing (1.0–1.3) • HTTP response & timing breakdown • HTTP/2 & HTTP/3/QUIC detection • Redirect chain tracing • Compression support • Cookie inspection • Security headers (10 checks) • Server/CDN/WAF fingerprinting • SSH banner & key exchange • Keep-alive behavior
|
|
76
|
+
|
|
77
|
+
---
|
|
78
|
+
|
|
79
|
+
## Installation
|
|
80
|
+
|
|
81
|
+
> [!IMPORTANT]
|
|
82
|
+
> Please ensure you are using a **64-bit version of Python**. If you attempt to install on 32-bit Python, the installation will be blocked.
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
pip install cyinfo
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
With JKS keystore support:
|
|
89
|
+
```bash
|
|
90
|
+
pip install cyinfo[jks]
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
For development:
|
|
94
|
+
```bash
|
|
95
|
+
pip install cyinfo[dev]
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
---
|
|
99
|
+
|
|
100
|
+
## Quick Start
|
|
101
|
+
|
|
102
|
+
### Python API
|
|
103
|
+
|
|
104
|
+
```python
|
|
105
|
+
from cyinfo import basic_scan, medium_scan, advanced_scan
|
|
106
|
+
|
|
107
|
+
# Level 1 — Basic recon
|
|
108
|
+
result = basic_scan("example.com")
|
|
109
|
+
print(result['ip_info']['resolved_ip'])
|
|
110
|
+
print(result['geolocation']['country'])
|
|
111
|
+
|
|
112
|
+
# Level 2 — Medium analysis
|
|
113
|
+
result = medium_scan("example.com")
|
|
114
|
+
print(result['ssl_tls_info']['tls_version'])
|
|
115
|
+
print(result['security_headers_analysis']['grade'])
|
|
116
|
+
|
|
117
|
+
# Level 3 — Advanced SSL deep dive
|
|
118
|
+
result = advanced_scan("example.com")
|
|
119
|
+
print(result['encryption_details']['key_exchange'])
|
|
120
|
+
print(result['forward_secrecy']['supported'])
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
```python
|
|
124
|
+
from cyinfo import analyze_certificate, analyze_keystore
|
|
125
|
+
|
|
126
|
+
# Analyze any certificate
|
|
127
|
+
cert = analyze_certificate("server.crt")
|
|
128
|
+
print(cert['certificates'][0]['validity']['days_remaining'])
|
|
129
|
+
|
|
130
|
+
# Parse a PKCS12 keystore
|
|
131
|
+
ks = analyze_keystore("keystore.p12", "password123")
|
|
132
|
+
print(ks['private_key_info']['bits'])
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
```python
|
|
136
|
+
from cyinfo import pycurl_deep_inspect
|
|
137
|
+
|
|
138
|
+
# Full 17-parameter inspection
|
|
139
|
+
result = pycurl_deep_inspect("https://example.com")
|
|
140
|
+
print(result['4_tls_version_support']['supported_versions'])
|
|
141
|
+
print(result['13_security_headers']['grade'])
|
|
142
|
+
print(result['15_ssh_info']['banner'])
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
### CLI
|
|
146
|
+
|
|
147
|
+
```bash
|
|
148
|
+
# Interactive scanner
|
|
149
|
+
cyinfo scan
|
|
150
|
+
|
|
151
|
+
# Quick commands
|
|
152
|
+
cyinfo scan --target example.com --level basic
|
|
153
|
+
cyinfo scan --target example.com --level full
|
|
154
|
+
cyinfo cert --file server.crt
|
|
155
|
+
cyinfo inspect --url https://example.com
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
---
|
|
159
|
+
|
|
160
|
+
## Project Structure
|
|
161
|
+
|
|
162
|
+
```
|
|
163
|
+
cyinfo/
|
|
164
|
+
├── pyproject.toml # Package metadata & dependencies
|
|
165
|
+
├── README.md
|
|
166
|
+
├── LICENSE
|
|
167
|
+
├── src/
|
|
168
|
+
│ └── cyinfo/
|
|
169
|
+
│ ├── __init__.py # Public API exports
|
|
170
|
+
│ ├── cli.py # CLI entry point
|
|
171
|
+
│ ├── scanner.py # 3-tier network scanner
|
|
172
|
+
│ ├── cert_analyzer.py # Certificate & keystore analyzer
|
|
173
|
+
│ └── pycurl_inspector.py # PyCurl deep inspector
|
|
174
|
+
└── tests/
|
|
175
|
+
├── __init__.py
|
|
176
|
+
└── test_basic.py
|
|
177
|
+
```
|
|
178
|
+
|
|
179
|
+
---
|
|
180
|
+
|
|
181
|
+
## Requirements
|
|
182
|
+
|
|
183
|
+
- **Python 3.9+ (64-bit strictly required)**
|
|
184
|
+
- `requests` — HTTP requests
|
|
185
|
+
- `dnspython` — DNS resolution
|
|
186
|
+
- `pyOpenSSL` — Certificate chain analysis
|
|
187
|
+
- `pycurl` — Low-level HTTP/TLS probing
|
|
188
|
+
|
|
189
|
+
> [!WARNING]
|
|
190
|
+
> **64-bit Python Required:** Because this toolkit relies on advanced cryptographic libraries (`cryptography`, `twofish`), **you must use a 64-bit version of Python**. 32-bit Python will fail to install due to missing pre-compiled binaries.
|
|
191
|
+
|
|
192
|
+
---
|
|
193
|
+
|
|
194
|
+
## License
|
|
195
|
+
|
|
196
|
+
MIT License — see [LICENSE](LICENSE) for details.
|
cyinfo-1.0.0/README.md
ADDED
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
# CyInfo
|
|
2
|
+
|
|
3
|
+
A comprehensive Python network security toolkit for SSL/TLS analysis, certificate inspection, vulnerability scanning, and deep HTTP/TLS probing.
|
|
4
|
+
|
|
5
|
+
[](https://pypi.org/project/cyinfo/)
|
|
6
|
+
[](https://www.python.org/downloads/)
|
|
7
|
+
[](https://opensource.org/licenses/MIT)
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## Features
|
|
12
|
+
|
|
13
|
+
### 🔍 Network Scanner (`cyinfo.scanner`)
|
|
14
|
+
Three-tier scanning with increasing depth:
|
|
15
|
+
|
|
16
|
+
| Level | Method | What it does |
|
|
17
|
+
|-------|--------|-------------|
|
|
18
|
+
| **Basic** | `basic_scan(target)` | IP resolution, DNS records (A/AAAA/MX/NS/TXT/CNAME/SOA), geolocation, HTTP status, reverse DNS |
|
|
19
|
+
| **Medium** | `medium_scan(target)` | SSL certificate details, TLS version, cipher suite, security headers grading, port scan with banner grabbing |
|
|
20
|
+
| **Advanced** | `advanced_scan(target)` | SSL handshake breakdown, encryption algorithms, PFS analysis, full certificate chain via pyOpenSSL |
|
|
21
|
+
| **Full** | `full_scan(target)` | Runs all three levels |
|
|
22
|
+
|
|
23
|
+
### 🔐 Certificate Analyzer (`cyinfo.cert_analyzer`)
|
|
24
|
+
Deep certificate and keystore inspection:
|
|
25
|
+
|
|
26
|
+
- **`analyze_certificate(path)`** — Parse any cert format (PEM, DER, CRT, CER, P7B). Extracts: type/usage, subject, issuer, dates, fingerprints (SHA-256/SHA-1/MD5), crypto suite, key usage, SANs, extensions, and more.
|
|
27
|
+
- **`analyze_keystore(path, password)`** — Parse PKCS12/PFX and JKS keystores. Extracts private key info, certificate chain, and all cert details.
|
|
28
|
+
- **`test_ssl_with_private_key(key, cert, port)`** — Bind a private key to a socket and test all TLS versions with 20-field handshake detail extraction.
|
|
29
|
+
|
|
30
|
+
### 🌐 PyCurl Inspector (`cyinfo.pycurl_inspector`)
|
|
31
|
+
Low-level HTTP/TLS analysis using only pycurl — **17 parameters tested**:
|
|
32
|
+
|
|
33
|
+
TLS handshake • Certificate chain & fingerprints • TLS version probing (1.0–1.3) • HTTP response & timing breakdown • HTTP/2 & HTTP/3/QUIC detection • Redirect chain tracing • Compression support • Cookie inspection • Security headers (10 checks) • Server/CDN/WAF fingerprinting • SSH banner & key exchange • Keep-alive behavior
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## Installation
|
|
38
|
+
|
|
39
|
+
> [!IMPORTANT]
|
|
40
|
+
> Please ensure you are using a **64-bit version of Python**. If you attempt to install on 32-bit Python, the installation will be blocked.
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
pip install cyinfo
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
With JKS keystore support:
|
|
47
|
+
```bash
|
|
48
|
+
pip install cyinfo[jks]
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
For development:
|
|
52
|
+
```bash
|
|
53
|
+
pip install cyinfo[dev]
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
## Quick Start
|
|
59
|
+
|
|
60
|
+
### Python API
|
|
61
|
+
|
|
62
|
+
```python
|
|
63
|
+
from cyinfo import basic_scan, medium_scan, advanced_scan
|
|
64
|
+
|
|
65
|
+
# Level 1 — Basic recon
|
|
66
|
+
result = basic_scan("example.com")
|
|
67
|
+
print(result['ip_info']['resolved_ip'])
|
|
68
|
+
print(result['geolocation']['country'])
|
|
69
|
+
|
|
70
|
+
# Level 2 — Medium analysis
|
|
71
|
+
result = medium_scan("example.com")
|
|
72
|
+
print(result['ssl_tls_info']['tls_version'])
|
|
73
|
+
print(result['security_headers_analysis']['grade'])
|
|
74
|
+
|
|
75
|
+
# Level 3 — Advanced SSL deep dive
|
|
76
|
+
result = advanced_scan("example.com")
|
|
77
|
+
print(result['encryption_details']['key_exchange'])
|
|
78
|
+
print(result['forward_secrecy']['supported'])
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
```python
|
|
82
|
+
from cyinfo import analyze_certificate, analyze_keystore
|
|
83
|
+
|
|
84
|
+
# Analyze any certificate
|
|
85
|
+
cert = analyze_certificate("server.crt")
|
|
86
|
+
print(cert['certificates'][0]['validity']['days_remaining'])
|
|
87
|
+
|
|
88
|
+
# Parse a PKCS12 keystore
|
|
89
|
+
ks = analyze_keystore("keystore.p12", "password123")
|
|
90
|
+
print(ks['private_key_info']['bits'])
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
```python
|
|
94
|
+
from cyinfo import pycurl_deep_inspect
|
|
95
|
+
|
|
96
|
+
# Full 17-parameter inspection
|
|
97
|
+
result = pycurl_deep_inspect("https://example.com")
|
|
98
|
+
print(result['4_tls_version_support']['supported_versions'])
|
|
99
|
+
print(result['13_security_headers']['grade'])
|
|
100
|
+
print(result['15_ssh_info']['banner'])
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
### CLI
|
|
104
|
+
|
|
105
|
+
```bash
|
|
106
|
+
# Interactive scanner
|
|
107
|
+
cyinfo scan
|
|
108
|
+
|
|
109
|
+
# Quick commands
|
|
110
|
+
cyinfo scan --target example.com --level basic
|
|
111
|
+
cyinfo scan --target example.com --level full
|
|
112
|
+
cyinfo cert --file server.crt
|
|
113
|
+
cyinfo inspect --url https://example.com
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
---
|
|
117
|
+
|
|
118
|
+
## Project Structure
|
|
119
|
+
|
|
120
|
+
```
|
|
121
|
+
cyinfo/
|
|
122
|
+
├── pyproject.toml # Package metadata & dependencies
|
|
123
|
+
├── README.md
|
|
124
|
+
├── LICENSE
|
|
125
|
+
├── src/
|
|
126
|
+
│ └── cyinfo/
|
|
127
|
+
│ ├── __init__.py # Public API exports
|
|
128
|
+
│ ├── cli.py # CLI entry point
|
|
129
|
+
│ ├── scanner.py # 3-tier network scanner
|
|
130
|
+
│ ├── cert_analyzer.py # Certificate & keystore analyzer
|
|
131
|
+
│ └── pycurl_inspector.py # PyCurl deep inspector
|
|
132
|
+
└── tests/
|
|
133
|
+
├── __init__.py
|
|
134
|
+
└── test_basic.py
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
---
|
|
138
|
+
|
|
139
|
+
## Requirements
|
|
140
|
+
|
|
141
|
+
- **Python 3.9+ (64-bit strictly required)**
|
|
142
|
+
- `requests` — HTTP requests
|
|
143
|
+
- `dnspython` — DNS resolution
|
|
144
|
+
- `pyOpenSSL` — Certificate chain analysis
|
|
145
|
+
- `pycurl` — Low-level HTTP/TLS probing
|
|
146
|
+
|
|
147
|
+
> [!WARNING]
|
|
148
|
+
> **64-bit Python Required:** Because this toolkit relies on advanced cryptographic libraries (`cryptography`, `twofish`), **you must use a 64-bit version of Python**. 32-bit Python will fail to install due to missing pre-compiled binaries.
|
|
149
|
+
|
|
150
|
+
---
|
|
151
|
+
|
|
152
|
+
## License
|
|
153
|
+
|
|
154
|
+
MIT License — see [LICENSE](LICENSE) for details.
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=68.0", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "cyinfo"
|
|
7
|
+
version = "1.0.0"
|
|
8
|
+
description = "A comprehensive network security toolkit — SSL/TLS analysis, certificate inspection, vulnerability scanning, and deep HTTP/TLS probing via pycurl."
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.9"
|
|
11
|
+
authors = [
|
|
12
|
+
{name = "sripa"},
|
|
13
|
+
]
|
|
14
|
+
keywords = [
|
|
15
|
+
"cybersecurity",
|
|
16
|
+
"ssl",
|
|
17
|
+
"tls",
|
|
18
|
+
"certificate",
|
|
19
|
+
"scanner",
|
|
20
|
+
"vulnerability",
|
|
21
|
+
"network",
|
|
22
|
+
"pycurl",
|
|
23
|
+
"security",
|
|
24
|
+
"pentest",
|
|
25
|
+
]
|
|
26
|
+
classifiers = [
|
|
27
|
+
"Development Status :: 4 - Beta",
|
|
28
|
+
"Intended Audience :: Developers",
|
|
29
|
+
"Intended Audience :: Information Technology",
|
|
30
|
+
"Intended Audience :: System Administrators",
|
|
31
|
+
"License :: OSI Approved :: MIT License",
|
|
32
|
+
"Operating System :: OS Independent",
|
|
33
|
+
"Programming Language :: Python :: 3",
|
|
34
|
+
"Programming Language :: Python :: 3.9",
|
|
35
|
+
"Programming Language :: Python :: 3.10",
|
|
36
|
+
"Programming Language :: Python :: 3.11",
|
|
37
|
+
"Programming Language :: Python :: 3.12",
|
|
38
|
+
"Programming Language :: Python :: 3.13",
|
|
39
|
+
"Topic :: Security",
|
|
40
|
+
"Topic :: Internet :: WWW/HTTP",
|
|
41
|
+
"Topic :: System :: Networking",
|
|
42
|
+
"Topic :: Software Development :: Libraries :: Python Modules",
|
|
43
|
+
]
|
|
44
|
+
dependencies = [
|
|
45
|
+
"requests>=2.28.0",
|
|
46
|
+
"dnspython>=2.3.0",
|
|
47
|
+
"pyOpenSSL>=23.0.0",
|
|
48
|
+
"pycurl>=7.45.0",
|
|
49
|
+
]
|
|
50
|
+
|
|
51
|
+
[project.optional-dependencies]
|
|
52
|
+
jks = ["pyjks>=20.0.0"]
|
|
53
|
+
all = [
|
|
54
|
+
"pyjks>=20.0.0",
|
|
55
|
+
]
|
|
56
|
+
dev = [
|
|
57
|
+
"pytest>=7.0",
|
|
58
|
+
"pytest-cov>=4.0",
|
|
59
|
+
"build>=0.10",
|
|
60
|
+
"twine>=4.0",
|
|
61
|
+
]
|
|
62
|
+
|
|
63
|
+
[project.urls]
|
|
64
|
+
Homepage = "https://github.com/sripa/cyinfo"
|
|
65
|
+
Documentation = "https://github.com/sripa/cyinfo#readme"
|
|
66
|
+
Repository = "https://github.com/sripa/cyinfo"
|
|
67
|
+
Issues = "https://github.com/sripa/cyinfo/issues"
|
|
68
|
+
|
|
69
|
+
[project.scripts]
|
|
70
|
+
cyinfo = "cyinfo.cli:main"
|
|
71
|
+
|
|
72
|
+
[tool.setuptools.packages.find]
|
|
73
|
+
where = ["src"]
|
|
74
|
+
|
|
75
|
+
[tool.setuptools.package-data]
|
|
76
|
+
cyinfo = ["py.typed"]
|
|
77
|
+
|
|
78
|
+
[tool.setuptools]
|
|
79
|
+
license-files = []
|
|
80
|
+
[tool.pytest.ini_options]
|
|
81
|
+
testpaths = ["tests"]
|
|
82
|
+
pythonpath = ["src"]
|
cyinfo-1.0.0/setup.cfg
ADDED
cyinfo-1.0.0/setup.py
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
from setuptools import setup
|
|
3
|
+
|
|
4
|
+
# Ensure 64-bit Python to prevent massive C++ compilation errors
|
|
5
|
+
# from cryptography/twofish on 32-bit systems
|
|
6
|
+
if sys.maxsize <= 2**32:
|
|
7
|
+
sys.exit(
|
|
8
|
+
"\n" + "=" * 70 + "\n"
|
|
9
|
+
"ERROR: CyInfo strictly requires a 64-bit Python interpreter!\n"
|
|
10
|
+
"You are currently using a 32-bit Python version.\n\n"
|
|
11
|
+
"Please install a 64-bit version of Python, and then install this package.\n"
|
|
12
|
+
+ "=" * 70 + "\n"
|
|
13
|
+
)
|
|
14
|
+
|
|
15
|
+
with open("README.md", "r", encoding="utf-8") as fh:
|
|
16
|
+
long_description = fh.read()
|
|
17
|
+
|
|
18
|
+
setup(
|
|
19
|
+
name="cyinfo",
|
|
20
|
+
version="1.0.0",
|
|
21
|
+
long_description=long_description,
|
|
22
|
+
long_description_content_type="text/markdown"
|
|
23
|
+
)
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"""
|
|
2
|
+
CyInfo — Comprehensive Network Security Toolkit
|
|
3
|
+
|
|
4
|
+
Modules:
|
|
5
|
+
scanner — Three-tier network scanning (basic, medium, advanced)
|
|
6
|
+
cert_analyzer — Certificate & keystore analysis with handshake testing
|
|
7
|
+
pycurl_inspector — Low-level HTTP/TLS probing via pycurl (17 parameters)
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
__version__ = "1.0.0"
|
|
11
|
+
__author__ = "sripa"
|
|
12
|
+
|
|
13
|
+
import sys
|
|
14
|
+
if sys.maxsize <= 2**32:
|
|
15
|
+
sys.exit(
|
|
16
|
+
"\n======================================================================\n"
|
|
17
|
+
"[ERROR] CyInfo strictly requires a 64-bit Python interpreter!\n"
|
|
18
|
+
"You are currently using a 32-bit Python version.\n"
|
|
19
|
+
"Please install a 64-bit version of Python and try again.\n"
|
|
20
|
+
"======================================================================\n"
|
|
21
|
+
)
|
|
22
|
+
|
|
23
|
+
# ── Scanner — 3-tier network reconnaissance ──
|
|
24
|
+
from cyinfo.scanner import (
|
|
25
|
+
basic_scan,
|
|
26
|
+
medium_scan,
|
|
27
|
+
advanced_scan,
|
|
28
|
+
full_scan,
|
|
29
|
+
)
|
|
30
|
+
|
|
31
|
+
# ── Certificate Analyzer — cert & keystore inspection ──
|
|
32
|
+
from cyinfo.cert_analyzer import (
|
|
33
|
+
analyze_certificate,
|
|
34
|
+
analyze_keystore,
|
|
35
|
+
test_ssl_with_private_key,
|
|
36
|
+
)
|
|
37
|
+
|
|
38
|
+
# ── PyCurl Inspector — low-level HTTP/TLS probing ──
|
|
39
|
+
from cyinfo.pycurl_inspector import (
|
|
40
|
+
pycurl_deep_inspect,
|
|
41
|
+
pycurl_tls_handshake,
|
|
42
|
+
pycurl_cert_chain,
|
|
43
|
+
pycurl_tls_versions,
|
|
44
|
+
pycurl_security_headers,
|
|
45
|
+
pycurl_ssh_info,
|
|
46
|
+
pycurl_timing,
|
|
47
|
+
)
|
|
48
|
+
|
|
49
|
+
__all__ = [
|
|
50
|
+
# Version
|
|
51
|
+
"__version__",
|
|
52
|
+
# Scanner
|
|
53
|
+
"basic_scan",
|
|
54
|
+
"medium_scan",
|
|
55
|
+
"advanced_scan",
|
|
56
|
+
"full_scan",
|
|
57
|
+
# Certificate Analyzer
|
|
58
|
+
"analyze_certificate",
|
|
59
|
+
"analyze_keystore",
|
|
60
|
+
"test_ssl_with_private_key",
|
|
61
|
+
# PyCurl Inspector
|
|
62
|
+
"pycurl_deep_inspect",
|
|
63
|
+
"pycurl_tls_handshake",
|
|
64
|
+
"pycurl_cert_chain",
|
|
65
|
+
"pycurl_tls_versions",
|
|
66
|
+
"pycurl_security_headers",
|
|
67
|
+
"pycurl_ssh_info",
|
|
68
|
+
"pycurl_timing",
|
|
69
|
+
]
|