CryptoParser 0.9.1__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.
- CryptoParser-0.9.1/CHANGELOG.rst +304 -0
- CryptoParser-0.9.1/CONTRIBUTING.rst +164 -0
- CryptoParser-0.9.1/CryptoParser.egg-info/PKG-INFO +96 -0
- CryptoParser-0.9.1/CryptoParser.egg-info/SOURCES.txt +44 -0
- CryptoParser-0.9.1/CryptoParser.egg-info/dependency_links.txt +1 -0
- CryptoParser-0.9.1/CryptoParser.egg-info/requires.txt +26 -0
- CryptoParser-0.9.1/CryptoParser.egg-info/top_level.txt +1 -0
- CryptoParser-0.9.1/LICENSE.txt +373 -0
- CryptoParser-0.9.1/MANIFEST.in +2 -0
- CryptoParser-0.9.1/PKG-INFO +96 -0
- CryptoParser-0.9.1/README.rst +44 -0
- CryptoParser-0.9.1/cryptoparser/__init__.py +0 -0
- CryptoParser-0.9.1/cryptoparser/__setup__.py +10 -0
- CryptoParser-0.9.1/cryptoparser/common/__init__.py +0 -0
- CryptoParser-0.9.1/cryptoparser/common/base.py +976 -0
- CryptoParser-0.9.1/cryptoparser/common/classes.py +55 -0
- CryptoParser-0.9.1/cryptoparser/common/exception.py +25 -0
- CryptoParser-0.9.1/cryptoparser/common/key.py +42 -0
- CryptoParser-0.9.1/cryptoparser/common/parse.py +916 -0
- CryptoParser-0.9.1/cryptoparser/common/utils.py +44 -0
- CryptoParser-0.9.1/cryptoparser/common/x509.py +101 -0
- CryptoParser-0.9.1/cryptoparser/httpx/__init__.py +0 -0
- CryptoParser-0.9.1/cryptoparser/httpx/header.py +662 -0
- CryptoParser-0.9.1/cryptoparser/httpx/parse.py +564 -0
- CryptoParser-0.9.1/cryptoparser/httpx/version.py +29 -0
- CryptoParser-0.9.1/cryptoparser/ssh/__init__.py +0 -0
- CryptoParser-0.9.1/cryptoparser/ssh/key.py +1081 -0
- CryptoParser-0.9.1/cryptoparser/ssh/record.py +79 -0
- CryptoParser-0.9.1/cryptoparser/ssh/subprotocol.py +645 -0
- CryptoParser-0.9.1/cryptoparser/ssh/version.py +231 -0
- CryptoParser-0.9.1/cryptoparser/tls/__init__.py +0 -0
- CryptoParser-0.9.1/cryptoparser/tls/algorithm.py +37 -0
- CryptoParser-0.9.1/cryptoparser/tls/ciphersuite.py +28 -0
- CryptoParser-0.9.1/cryptoparser/tls/extension.py +1266 -0
- CryptoParser-0.9.1/cryptoparser/tls/grease.py +117 -0
- CryptoParser-0.9.1/cryptoparser/tls/ldap.py +209 -0
- CryptoParser-0.9.1/cryptoparser/tls/mysql.py +498 -0
- CryptoParser-0.9.1/cryptoparser/tls/openvpn.py +225 -0
- CryptoParser-0.9.1/cryptoparser/tls/postgresql.py +61 -0
- CryptoParser-0.9.1/cryptoparser/tls/rdp.py +234 -0
- CryptoParser-0.9.1/cryptoparser/tls/record.py +113 -0
- CryptoParser-0.9.1/cryptoparser/tls/subprotocol.py +1137 -0
- CryptoParser-0.9.1/cryptoparser/tls/version.py +92 -0
- CryptoParser-0.9.1/requirements.txt +7 -0
- CryptoParser-0.9.1/setup.cfg +4 -0
- CryptoParser-0.9.1/setup.py +104 -0
|
@@ -0,0 +1,304 @@
|
|
|
1
|
+
Changelog
|
|
2
|
+
=========
|
|
3
|
+
|
|
4
|
+
0.9.1 - 2022-06-22
|
|
5
|
+
------------------
|
|
6
|
+
|
|
7
|
+
- TLS (``tls``)
|
|
8
|
+
|
|
9
|
+
- Generic
|
|
10
|
+
|
|
11
|
+
- add parser for `signed certificate timestamp <https://www.rfc-editor.org/rfc/rfc6962.html#section-3.3.1>`__
|
|
12
|
+
entries (#52)
|
|
13
|
+
|
|
14
|
+
0.9.0 - 2023-04-29
|
|
15
|
+
------------------
|
|
16
|
+
|
|
17
|
+
- TLS (``tls``)
|
|
18
|
+
|
|
19
|
+
- Generic
|
|
20
|
+
|
|
21
|
+
- protocol item classes for `OpenVPN <https://en.wikipedia.org/wiki/OpenVPN>`__ support (#62)
|
|
22
|
+
|
|
23
|
+
0.8.5 - 2023-04-02
|
|
24
|
+
------------------
|
|
25
|
+
|
|
26
|
+
- Generic
|
|
27
|
+
|
|
28
|
+
- move data classes to `CryptoDataHub repository <https://gitlab.com/coroner/cryptodatahub>`__ (#67)
|
|
29
|
+
|
|
30
|
+
0.8.4 - 2023-01-22
|
|
31
|
+
------------------
|
|
32
|
+
|
|
33
|
+
- TLS (``tls``)
|
|
34
|
+
|
|
35
|
+
- Generic
|
|
36
|
+
|
|
37
|
+
- protocol item classes for MySQL support (#61)
|
|
38
|
+
|
|
39
|
+
0.8.2 - 2022-10-10
|
|
40
|
+
------------------
|
|
41
|
+
|
|
42
|
+
- TLS (``tls``)
|
|
43
|
+
|
|
44
|
+
- Cipher Suites (``ciphers``)
|
|
45
|
+
|
|
46
|
+
- add OpenSSL names (#54)
|
|
47
|
+
- add min/max versions (#55)
|
|
48
|
+
|
|
49
|
+
- SSH (``ssh``)
|
|
50
|
+
|
|
51
|
+
- Public Keys (``pubkeys``)
|
|
52
|
+
|
|
53
|
+
- `HASSH fingerprint <https://engineering.salesforce.com/open-sourcing-hassh-abed3ae5044c/>`__ calculation (#48)
|
|
54
|
+
- add `host certificate <https://github.com/openssh/openssh-portable/blob/master/PROTOCOL.certkeys>`__ related
|
|
55
|
+
classes (#53)
|
|
56
|
+
|
|
57
|
+
0.8.0 - 2022-01-18
|
|
58
|
+
------------------
|
|
59
|
+
|
|
60
|
+
- SSH (``ssh``)
|
|
61
|
+
|
|
62
|
+
- Public Keys (``pubkeys``)
|
|
63
|
+
|
|
64
|
+
- add `public key <https://datatracker.ietf.org/doc/html/rfc4253#section-6.6>`__ related classes (#43)
|
|
65
|
+
|
|
66
|
+
- Versions (``versions``)
|
|
67
|
+
|
|
68
|
+
- add `software version <https://tools.ietf.org/html/rfc4253#section-4.2>`__ related classes (#46)
|
|
69
|
+
|
|
70
|
+
0.7.3 - 2021-12-26
|
|
71
|
+
------------------
|
|
72
|
+
|
|
73
|
+
- Generic
|
|
74
|
+
|
|
75
|
+
- Fix time zone handlind in datetime parser
|
|
76
|
+
|
|
77
|
+
0.7.2 - 2021-10-07
|
|
78
|
+
------------------
|
|
79
|
+
|
|
80
|
+
Other
|
|
81
|
+
~~~~~
|
|
82
|
+
|
|
83
|
+
- switch to Markdown format in changelog, readme and contributing
|
|
84
|
+
- update contributing to the latest version from contribution-guide.org
|
|
85
|
+
|
|
86
|
+
0.7.1 - 2021-09-20
|
|
87
|
+
------------------
|
|
88
|
+
|
|
89
|
+
- TLS (``tls``)
|
|
90
|
+
|
|
91
|
+
- protocol item classes for PostgreSQL support (#44)
|
|
92
|
+
|
|
93
|
+
0.7.0 - 2021-09-02
|
|
94
|
+
------------------
|
|
95
|
+
|
|
96
|
+
- TLS (``tls``)
|
|
97
|
+
|
|
98
|
+
- Extensions (``extensions``)
|
|
99
|
+
|
|
100
|
+
- add `application-layer protocol negotiation <https://www.rfc-editor.org/rfc/rfc5077.html>`__ extension related
|
|
101
|
+
messages (#40)
|
|
102
|
+
- add `encrypt-then-MAC <https://www.rfc-editor.org/rfc/rfc7366.html>`__ extension related messages (#40)
|
|
103
|
+
- add `extended master secret <https://www.rfc-editor.org/rfc/rfc7627.html>`__ extension related messages (#40)
|
|
104
|
+
- add `next protocol negotiation <https://tools.ietf.org/id/draft-agl-tls-nextprotoneg-03.html>`__ extension
|
|
105
|
+
related messages (#40)
|
|
106
|
+
- add `renegotiation indication <https://www.rfc-editor.org/rfc/rfc5746.html>`__ extension related messages (#40)
|
|
107
|
+
- add `session ticket <https://www.rfc-editor.org/rfc/rfc5077.html>`__ extension related messages (#40)
|
|
108
|
+
|
|
109
|
+
0.6.0 - 2021-05-27
|
|
110
|
+
------------------
|
|
111
|
+
|
|
112
|
+
Features
|
|
113
|
+
~~~~~~~~
|
|
114
|
+
|
|
115
|
+
- HTTP(S) (``http``)
|
|
116
|
+
|
|
117
|
+
- Headers (``headers``)
|
|
118
|
+
|
|
119
|
+
- supports header wire format parsing
|
|
120
|
+
- add parsers for generic headers
|
|
121
|
+
(`Content-Type <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Type>`__,
|
|
122
|
+
`Server <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Server>`__)
|
|
123
|
+
- add parsers for cache related headers (`Age <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Age>`__,
|
|
124
|
+
`Cache-Control <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control>`__,
|
|
125
|
+
`Date <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Date>`__,
|
|
126
|
+
`ETag <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/ETag>`__,
|
|
127
|
+
`Expires <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Expires>`__,
|
|
128
|
+
`Last-Modified <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Last-Modified>`__,
|
|
129
|
+
`Pragma <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Pragma>`__)
|
|
130
|
+
- add parsers for security related headers
|
|
131
|
+
(`Expect-CT <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Expect-CT>`__,
|
|
132
|
+
`Expect-Staple <https://scotthelme.co.uk/designing-a-new-security-header-expect-staple>`__,
|
|
133
|
+
`Referrer-Policy <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Referrer-Policy>`__,
|
|
134
|
+
`Strict-Transport-Security <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security>`__,
|
|
135
|
+
`X-Content-Type-Options <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Content-Type-Options>`__,
|
|
136
|
+
`X-Frame-Options <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options>`__)
|
|
137
|
+
|
|
138
|
+
- TLS (``tls``)
|
|
139
|
+
|
|
140
|
+
- Versions (``versions``)
|
|
141
|
+
|
|
142
|
+
- add `protocol version 1.3 <https://tools.ietf.org/html/rfc8446>`__ related messages (#20)
|
|
143
|
+
|
|
144
|
+
- Cipher Suites (``ciphers``)
|
|
145
|
+
|
|
146
|
+
- add `cipher suites <https://tools.ietf.org/html/rfc8446#appendix-B.4>`__ relate to version 1.3 (#20)
|
|
147
|
+
|
|
148
|
+
- Diffie-Hellman (``dhparams``)
|
|
149
|
+
|
|
150
|
+
- add `supported groups <https://tools.ietf.org/html/rfc8446#section-4.2.7>`__ relate to version 1.3 (#20)
|
|
151
|
+
|
|
152
|
+
- Elliptic Curves (``curves``)
|
|
153
|
+
|
|
154
|
+
- add `supported groups <https://tools.ietf.org/html/rfc8446#section-4.2.7>`__ relate to version 1.3 (#20)
|
|
155
|
+
|
|
156
|
+
- Signature Algorithms (``sigalgos``)
|
|
157
|
+
|
|
158
|
+
- add `signature algorithms <https://tools.ietf.org/html/rfc8446#section-4.2.3>`__ relate to version 1.3 (#20)
|
|
159
|
+
|
|
160
|
+
0.5.0 - 2021-04-08
|
|
161
|
+
------------------
|
|
162
|
+
|
|
163
|
+
Features
|
|
164
|
+
~~~~~~~~
|
|
165
|
+
|
|
166
|
+
- Generic
|
|
167
|
+
|
|
168
|
+
- add parser for `text-based protocols <https://en.wikipedia.org/wiki/Text-based_protocol>`__ (#21)
|
|
169
|
+
|
|
170
|
+
- SSH (``ssh``)
|
|
171
|
+
|
|
172
|
+
- Versions (``versions``)
|
|
173
|
+
|
|
174
|
+
- add `protocol version exchange <https://tools.ietf.org/html/rfc4253#section-4.2>`__ related messages (#21)
|
|
175
|
+
|
|
176
|
+
- SSH 2.0 (``ssh2``)
|
|
177
|
+
|
|
178
|
+
- Cipher Suites (``ciphers``)
|
|
179
|
+
|
|
180
|
+
- add `algorithm negotiation <https://tools.ietf.org/html/rfc4253#section-7.1>`__ related messages (#21)
|
|
181
|
+
|
|
182
|
+
Usability
|
|
183
|
+
~~~~~~~~~
|
|
184
|
+
|
|
185
|
+
- Generic
|
|
186
|
+
|
|
187
|
+
- show attributes in user-friendly order in Markdown output (#30)
|
|
188
|
+
- use human readable algorithms names in Markdown output (#32)
|
|
189
|
+
- add human readable descriptions for exceptions (#33)
|
|
190
|
+
|
|
191
|
+
0.4.0 - 2021-01-30
|
|
192
|
+
------------------
|
|
193
|
+
|
|
194
|
+
Features
|
|
195
|
+
~~~~~~~~
|
|
196
|
+
|
|
197
|
+
- TLS (``tls``)
|
|
198
|
+
|
|
199
|
+
- Generic
|
|
200
|
+
|
|
201
|
+
- add `LDAP <https://en.wikipedia.org/wiki/Lightweight_Directory_Access_Protocol>`__ related messages (#23)
|
|
202
|
+
|
|
203
|
+
- Client Public Key Request (``pubkeyreq``)
|
|
204
|
+
|
|
205
|
+
- add `client public key request <https://tools.ietf.org/html/rfc2246#section-7.4.4>`__ related messages (#24)
|
|
206
|
+
|
|
207
|
+
Improvements
|
|
208
|
+
~~~~~~~~~~~~
|
|
209
|
+
|
|
210
|
+
- Generic
|
|
211
|
+
|
|
212
|
+
- add `OID <https://en.wikipedia.org/wiki/Object_identifier>`__ to algorithms
|
|
213
|
+
|
|
214
|
+
0.3.1 - 2020-09-15
|
|
215
|
+
------------------
|
|
216
|
+
|
|
217
|
+
Features
|
|
218
|
+
~~~~~~~~
|
|
219
|
+
|
|
220
|
+
- Generic
|
|
221
|
+
|
|
222
|
+
- `Markdown <https://en.wikipedia.org/wiki/Markdown>`__ serializable format (#19)
|
|
223
|
+
|
|
224
|
+
Improvements
|
|
225
|
+
~~~~~~~~~~~~
|
|
226
|
+
|
|
227
|
+
- TLS (``tls``)
|
|
228
|
+
|
|
229
|
+
- Cipher Suites (``ciphers``)
|
|
230
|
+
|
|
231
|
+
- add missing ``ECDHE_PSK`` cipher suites (#7)
|
|
232
|
+
- add `GOST <https://en.wikipedia.org/wiki/GOST>`__ cipher suites
|
|
233
|
+
- add missing draft ECC cipher suites (#9)
|
|
234
|
+
- add missing `FIPS <https://en.wikipedia.org/wiki/FIPS_140-2>`__ cipher suites (#11)
|
|
235
|
+
- add `CECPQ1 <https://en.wikipedia.org/wiki/CECPQ1>`__ cipher suites (#12)
|
|
236
|
+
- add missing `Fortezza <https://en.wikipedia.org/wiki/Fortezza>`__ cipher suites (#13)
|
|
237
|
+
- add missing ``DHE`` cipher suites (#14)
|
|
238
|
+
- add missing SSLv3 cipher suites (#15)
|
|
239
|
+
|
|
240
|
+
Notable fixes
|
|
241
|
+
~~~~~~~~~~~~~
|
|
242
|
+
|
|
243
|
+
- Generic
|
|
244
|
+
|
|
245
|
+
- fix unicode string representation in JSON output (#18)
|
|
246
|
+
|
|
247
|
+
- TLS (``tls``)
|
|
248
|
+
|
|
249
|
+
- Cipher Suites (``ciphers``)
|
|
250
|
+
|
|
251
|
+
- fix some cipher suite names and parameters (#7, #10)
|
|
252
|
+
|
|
253
|
+
0.3.0 - 2020-04-30
|
|
254
|
+
------------------
|
|
255
|
+
|
|
256
|
+
Features
|
|
257
|
+
~~~~~~~~
|
|
258
|
+
|
|
259
|
+
- TLS (``tls``)
|
|
260
|
+
|
|
261
|
+
- protocol item classes for RDP support (#4)
|
|
262
|
+
- `JA3 fingerprint <https://engineering.salesforce.com/tls-fingerprinting-with-ja3-and-ja3s-247362855967>`__
|
|
263
|
+
calculation for TLS client hello (#2)
|
|
264
|
+
|
|
265
|
+
Bugs
|
|
266
|
+
^^^^
|
|
267
|
+
|
|
268
|
+
- TLS (``tls``)
|
|
269
|
+
|
|
270
|
+
- compose all the messages in case of a TLS record (#1)
|
|
271
|
+
|
|
272
|
+
Refactor
|
|
273
|
+
~~~~~~~~
|
|
274
|
+
|
|
275
|
+
- use attrs to avoid boilerplates (#3)
|
|
276
|
+
|
|
277
|
+
0.2.0 - 2019-12-02
|
|
278
|
+
------------------
|
|
279
|
+
|
|
280
|
+
Notable fixes
|
|
281
|
+
~~~~~~~~~~~~~
|
|
282
|
+
|
|
283
|
+
- clarify TLS related parameter names
|
|
284
|
+
- several packaging fixes
|
|
285
|
+
|
|
286
|
+
0.1.0 - 2019-03-20
|
|
287
|
+
------------------
|
|
288
|
+
|
|
289
|
+
Features
|
|
290
|
+
~~~~~~~~
|
|
291
|
+
|
|
292
|
+
- added TLS record protocol support
|
|
293
|
+
- added TLS ChangeCipherSpec message support
|
|
294
|
+
- added TLS ApplicationData message support
|
|
295
|
+
- added TLS handshake message support
|
|
296
|
+
- added TLS client
|
|
297
|
+
- added SSL support
|
|
298
|
+
|
|
299
|
+
Improvements
|
|
300
|
+
~~~~~~~~~~~~
|
|
301
|
+
|
|
302
|
+
- added serialization support for classes
|
|
303
|
+
- added elliptic-curve related descriptive classes
|
|
304
|
+
- added timeout parameter to TLS client class
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
Contributing
|
|
2
|
+
============
|
|
3
|
+
|
|
4
|
+
Submitting bugs
|
|
5
|
+
---------------
|
|
6
|
+
|
|
7
|
+
Due diligence
|
|
8
|
+
~~~~~~~~~~~~~
|
|
9
|
+
|
|
10
|
+
Before submitting a bug, please do the following:
|
|
11
|
+
|
|
12
|
+
- Perform **basic troubleshooting** steps:
|
|
13
|
+
|
|
14
|
+
- **Make sure you're on the latest version.** If you're not on the most recent version, your problem may have been
|
|
15
|
+
solved already! Upgrading is always the best first step.
|
|
16
|
+
- **Try older versions.** If you're already *on* the latest release, try rolling back a few minor versions (e.g. if
|
|
17
|
+
on 1.7, try 1.5 or 1.6) and see if the problem goes away. This will help the devs narrow down when the problem
|
|
18
|
+
first arose in the commit log.
|
|
19
|
+
- **Try switching up dependency versions.** If the software in question has dependencies (other libraries, etc) try
|
|
20
|
+
upgrading/downgrading those as well.
|
|
21
|
+
|
|
22
|
+
- **Search the project's bug/issue tracker** to make sure it's not a known issue.
|
|
23
|
+
- If you don't find a pre-existing issue, consider **checking with the mailing list and/or IRC channel** in case the
|
|
24
|
+
problem is non-bug-related.
|
|
25
|
+
|
|
26
|
+
What to put in your bug report
|
|
27
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
28
|
+
|
|
29
|
+
Make sure your report gets the attention it deserves: bug reports with missing information may be ignored or punted back
|
|
30
|
+
to you, delaying a fix. The below constitutes a bare minimum; more info is almost always better:
|
|
31
|
+
|
|
32
|
+
- **What version of the core programming language interpreter/compiler are you using?** For example, if it's a Python
|
|
33
|
+
project, are you using Python 2.7.3? Python 3.3.1? PyPy 2.0?
|
|
34
|
+
- **What operating system are you on?** Windows? (Vista? 7? 32-bit? 64-bit?) Mac OS X? (10.7.4? 10.9.0?) Linux? (Which
|
|
35
|
+
distro? Which version of that distro? 32 or 64 bits?) Again, more detail is better.
|
|
36
|
+
- **Which version or versions of the software are you using?** Ideally, you followed the advice above and have ruled
|
|
37
|
+
out (or verified that the problem exists in) a few different versions.
|
|
38
|
+
- **How can the developers recreate the bug on their end?** If possible, include a copy of your code, the command you
|
|
39
|
+
used to invoke it, and the full output of your run (if applicable.)
|
|
40
|
+
|
|
41
|
+
- A common tactic is to pare down your code until a simple (but still bug-causing) "base case" remains. Not only can
|
|
42
|
+
this help you identify problems which aren't real bugs, but it means the developer can get to fixing the bug
|
|
43
|
+
faster.
|
|
44
|
+
|
|
45
|
+
Contributing changes
|
|
46
|
+
--------------------
|
|
47
|
+
|
|
48
|
+
Licensing of contributed material
|
|
49
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
50
|
+
|
|
51
|
+
Keep in mind as you contribute, that code, docs and other material submitted to open source projects are usually
|
|
52
|
+
considered licensed under the same terms as the rest of the work.
|
|
53
|
+
|
|
54
|
+
The details vary from project to project, but from the perspective of this document's authors:
|
|
55
|
+
|
|
56
|
+
- Anything submitted to a project falls under the licensing terms in the repository's top level ``LICENSE`` file.
|
|
57
|
+
|
|
58
|
+
- For example, if a project's ``LICENSE`` is BSD-based, contributors should be comfortable with their work
|
|
59
|
+
potentially being distributed in binary form without the original source code.
|
|
60
|
+
|
|
61
|
+
- Per-file copyright/license headers are typically extraneous and undesirable. Please don't add your own copyright
|
|
62
|
+
headers to new files unless the project's license actually requires them!
|
|
63
|
+
|
|
64
|
+
- Not least because even a new file created by one individual (who often feels compelled to put their personal
|
|
65
|
+
copyright notice at the top) will inherently end up contributed to by dozens of others over time, making a
|
|
66
|
+
per-file header outdated/misleading.
|
|
67
|
+
|
|
68
|
+
Version control branching
|
|
69
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
70
|
+
|
|
71
|
+
- Always **make a new branch** for your work, no matter how small. This makes it easy for others to take just that one
|
|
72
|
+
set of changes from your repository, in case you have multiple unrelated changes floating around.
|
|
73
|
+
|
|
74
|
+
- A corollary: **don't submit unrelated changes in the same branch/pull request**! The maintainer shouldn't have to
|
|
75
|
+
reject your awesome bugfix because the feature you put in with it needs more review.
|
|
76
|
+
|
|
77
|
+
- **Base your new branch off of the appropriate branch** on the main repository:
|
|
78
|
+
|
|
79
|
+
- **Bug fixes** should be based on the branch named after the **oldest supported release line** the bug affects.
|
|
80
|
+
|
|
81
|
+
- E.g. if a feature was introduced in 1.1, the latest release line is 1.3, and a bug is found in that feature -
|
|
82
|
+
make your branch based on 1.1. The maintainer will then forward-port it to 1.3 and master.
|
|
83
|
+
- Bug fixes requiring large changes to the code or which have a chance of being otherwise disruptive, may need to
|
|
84
|
+
base off of **master** instead. This is a judgement call -- ask the devs!
|
|
85
|
+
|
|
86
|
+
- **New features** should branch off of **the 'master' branch**.
|
|
87
|
+
|
|
88
|
+
- Note that depending on how long it takes for the dev team to merge your patch, the copy of ``master`` you
|
|
89
|
+
worked off of may get out of date! If you find yourself 'bumping' a pull request that's been sidelined for a
|
|
90
|
+
while, **make sure you rebase or merge to latest master** to ensure a speedier resolution.
|
|
91
|
+
|
|
92
|
+
Code formatting
|
|
93
|
+
~~~~~~~~~~~~~~~
|
|
94
|
+
|
|
95
|
+
- **Follow the style you see used in the primary repository**! Consistency with the rest of the project always trumps
|
|
96
|
+
other considerations. It doesn't matter if you have your own style or if the rest of the code breaks with the greater
|
|
97
|
+
community - just follow along.
|
|
98
|
+
- Python projects usually follow the `PEP-8 <http://www.python.org/dev/peps/pep-0008/>`__ guidelines (though many have
|
|
99
|
+
minor deviations depending on the lead maintainers' preferences.)
|
|
100
|
+
|
|
101
|
+
Documentation isn't optional
|
|
102
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
103
|
+
|
|
104
|
+
It's not! Patches without documentation will be returned to sender. By "documentation" we mean:
|
|
105
|
+
|
|
106
|
+
- **Docstrings** (for Python; or API-doc-friendly comments for other languages) must be created or updated for public
|
|
107
|
+
API functions/methods/etc. (This step is optional for some bugfixes.)
|
|
108
|
+
|
|
109
|
+
- Don't forget to include
|
|
110
|
+
`versionadded <http://sphinx-doc.org/markup/para.html#directive-versionadded>`__/`versionchanged <http://sphinx-doc.org/markup/para.html#directive-versionchanged>`__
|
|
111
|
+
ReST directives at the bottom of any new or changed Python docstrings!
|
|
112
|
+
|
|
113
|
+
- Use ``versionadded`` for truly new API members -- new methods, functions, classes or modules.
|
|
114
|
+
- Use ``versionchanged`` when adding/removing new function/method arguments, or whenever behavior changes.
|
|
115
|
+
|
|
116
|
+
- New features should ideally include updates to **prose documentation**, including useful example code snippets.
|
|
117
|
+
|
|
118
|
+
- All submissions should have a **changelog entry** crediting the contributor and/or any individuals instrumental in
|
|
119
|
+
identifying the problem.
|
|
120
|
+
|
|
121
|
+
Tests aren't optional
|
|
122
|
+
~~~~~~~~~~~~~~~~~~~~~
|
|
123
|
+
|
|
124
|
+
Any bugfix that doesn't include a test proving the existence of the bug being fixed, may be suspect. Ditto for new
|
|
125
|
+
features that can't prove they actually work.
|
|
126
|
+
|
|
127
|
+
We've found that test-first development really helps make features better architected and identifies potential edge
|
|
128
|
+
cases earlier instead of later. Writing tests before the implementation is strongly encouraged.
|
|
129
|
+
|
|
130
|
+
Full example
|
|
131
|
+
~~~~~~~~~~~~
|
|
132
|
+
|
|
133
|
+
Here's an example workflow for a project ``theproject`` hosted on Github, which is currently in version 1.3.x. Your
|
|
134
|
+
username is ``yourname`` and you're submitting a basic bugfix. (This workflow only changes slightly if the project is
|
|
135
|
+
hosted at Bitbucket, self-hosted, or etc.)
|
|
136
|
+
|
|
137
|
+
Preparing your Fork
|
|
138
|
+
^^^^^^^^^^^^^^^^^^^
|
|
139
|
+
|
|
140
|
+
1. Click 'Fork' on Github, creating e.g. ``yourname/theproject``.
|
|
141
|
+
2. Clone your project: ``git clone git@github.com:yourname/theproject``.
|
|
142
|
+
3. ``cd theproject``
|
|
143
|
+
4. `Create and activate a virtual
|
|
144
|
+
environment <https://packaging.python.org/tutorials/installing-packages/#creating-virtual-environments>`__.
|
|
145
|
+
5. Install the development requirements: ``pip install -r dev-requirements.txt``.
|
|
146
|
+
6. Create a branch: ``git checkout -b foo-the-bars 1.3``.
|
|
147
|
+
|
|
148
|
+
Making your Changes
|
|
149
|
+
^^^^^^^^^^^^^^^^^^^
|
|
150
|
+
|
|
151
|
+
1. Add changelog entry crediting yourself.
|
|
152
|
+
2. Write tests expecting the correct/fixed functionality; make sure they fail.
|
|
153
|
+
3. Hack, hack, hack.
|
|
154
|
+
4. Run tests again, making sure they pass.
|
|
155
|
+
5. Commit your changes: ``git commit -m "Foo the bars"``
|
|
156
|
+
|
|
157
|
+
Creating Pull Requests
|
|
158
|
+
^^^^^^^^^^^^^^^^^^^^^^
|
|
159
|
+
|
|
160
|
+
1. Push your commit to get it back up to your fork: ``git push origin HEAD``
|
|
161
|
+
2. Visit Github, click handy "Pull request" button that it will make upon noticing your new branch.
|
|
162
|
+
3. In the description field, write down issue number (if submitting code fixing an existing issue) or describe the issue
|
|
163
|
+
+ your fix (if submitting a wholly new bugfix).
|
|
164
|
+
4. Hit 'submit'! And please be patient - the maintainers will get to you when they can.
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: CryptoParser
|
|
3
|
+
Version: 0.9.1
|
|
4
|
+
Summary: Fast and flexible security protocol parser and generator
|
|
5
|
+
Author: Szilárd Pfeiffer
|
|
6
|
+
Author-email: coroner@pfeifferszilard.hu
|
|
7
|
+
Maintainer: Szilárd Pfeiffer
|
|
8
|
+
Maintainer-email: coroner@pfeifferszilard.hu
|
|
9
|
+
License: MPL-2.0
|
|
10
|
+
Project-URL: Homepage, https://gitlab.com/coroner/cryptoparser
|
|
11
|
+
Project-URL: Changelog, https://cryptoparser.readthedocs.io/en/latest/changelog
|
|
12
|
+
Project-URL: Documentation, https://cryptoparser.readthedocs.io/en/latest/
|
|
13
|
+
Project-URL: Issues, https://gitlab.com/coroner/cryptoparser/-/issues
|
|
14
|
+
Project-URL: Source, https://gitlab.com/coroner/cryptoparser
|
|
15
|
+
Keywords: ssl tls gost ja3 ldap rdp ssh hsts
|
|
16
|
+
Classifier: Development Status :: 4 - Beta
|
|
17
|
+
Classifier: Environment :: Console
|
|
18
|
+
Classifier: Framework :: tox
|
|
19
|
+
Classifier: Intended Audience :: Developers
|
|
20
|
+
Classifier: Intended Audience :: Information Technology
|
|
21
|
+
Classifier: Intended Audience :: Science/Research
|
|
22
|
+
Classifier: Intended Audience :: System Administrators
|
|
23
|
+
Classifier: License :: OSI Approved :: Mozilla Public License 2.0 (MPL 2.0)
|
|
24
|
+
Classifier: Natural Language :: English
|
|
25
|
+
Classifier: Operating System :: MacOS
|
|
26
|
+
Classifier: Operating System :: Microsoft :: Windows
|
|
27
|
+
Classifier: Operating System :: POSIX
|
|
28
|
+
Classifier: Programming Language :: Python :: 2.7
|
|
29
|
+
Classifier: Programming Language :: Python :: 3.3
|
|
30
|
+
Classifier: Programming Language :: Python :: 3.4
|
|
31
|
+
Classifier: Programming Language :: Python :: 3.5
|
|
32
|
+
Classifier: Programming Language :: Python :: 3.6
|
|
33
|
+
Classifier: Programming Language :: Python :: 3.7
|
|
34
|
+
Classifier: Programming Language :: Python :: 3.8
|
|
35
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
36
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
37
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
38
|
+
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
39
|
+
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
40
|
+
Classifier: Programming Language :: Python
|
|
41
|
+
Classifier: Topic :: Internet
|
|
42
|
+
Classifier: Topic :: Security
|
|
43
|
+
Classifier: Topic :: Security :: Cryptography
|
|
44
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
45
|
+
Classifier: Topic :: Software Development :: Testing :: Traffic Generation
|
|
46
|
+
Classifier: Topic :: Software Development :: Testing
|
|
47
|
+
Description-Content-Type: text/x-rst
|
|
48
|
+
Provides-Extra: test
|
|
49
|
+
Provides-Extra: pep8
|
|
50
|
+
Provides-Extra: pylint
|
|
51
|
+
License-File: LICENSE.txt
|
|
52
|
+
|
|
53
|
+
**CryptoParser** is a cryptographic protocol (TLS, SSH) and security-related protocol piece (HTTP headers) parser. It
|
|
54
|
+
is neither a comprehensive nor a secure implementation of any cryptographic protocol. The goal is to support
|
|
55
|
+
testing cryptographic libraries or analysing cryptography-realted settings of application servers such as
|
|
56
|
+
`CryptoLyzer <https://cryptolyzer.readthedocs.io/>`__ does.
|
|
57
|
+
|
|
58
|
+
Usage
|
|
59
|
+
-----
|
|
60
|
+
|
|
61
|
+
Pip
|
|
62
|
+
^^^
|
|
63
|
+
|
|
64
|
+
.. code:: shell
|
|
65
|
+
|
|
66
|
+
pip install cryptoparser
|
|
67
|
+
|
|
68
|
+
Support
|
|
69
|
+
-------
|
|
70
|
+
|
|
71
|
+
Python implementation
|
|
72
|
+
^^^^^^^^^^^^^^^^^^^^^
|
|
73
|
+
|
|
74
|
+
- CPython (2.7, 3.3+)
|
|
75
|
+
- PyPy (2.7, 3.5+)
|
|
76
|
+
|
|
77
|
+
Operating systems
|
|
78
|
+
^^^^^^^^^^^^^^^^^
|
|
79
|
+
|
|
80
|
+
- Linux
|
|
81
|
+
- macOS
|
|
82
|
+
- Windows
|
|
83
|
+
|
|
84
|
+
License
|
|
85
|
+
-------
|
|
86
|
+
|
|
87
|
+
The code is available under the terms of Mozilla Public License Version 2.0 (MPL 2.0).
|
|
88
|
+
|
|
89
|
+
A non-comprehensive, but straightforward description of MPL 2.0 can be found at
|
|
90
|
+
`Choose an open source license <https://choosealicense.com/licenses#mpl-2.0>`__ website.
|
|
91
|
+
|
|
92
|
+
Credits
|
|
93
|
+
-------
|
|
94
|
+
|
|
95
|
+
- `NLnet Foundation <https://nlnet.nl>`__ and `NGI Assure <https://www.assure.ngi.eu>`__, supports the project part of
|
|
96
|
+
the `Next Generation Internet <https://ngi.eu>`__ initiative.
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
CHANGELOG.rst
|
|
2
|
+
CONTRIBUTING.rst
|
|
3
|
+
LICENSE.txt
|
|
4
|
+
MANIFEST.in
|
|
5
|
+
README.rst
|
|
6
|
+
requirements.txt
|
|
7
|
+
setup.py
|
|
8
|
+
CryptoParser.egg-info/PKG-INFO
|
|
9
|
+
CryptoParser.egg-info/SOURCES.txt
|
|
10
|
+
CryptoParser.egg-info/dependency_links.txt
|
|
11
|
+
CryptoParser.egg-info/requires.txt
|
|
12
|
+
CryptoParser.egg-info/top_level.txt
|
|
13
|
+
cryptoparser/__init__.py
|
|
14
|
+
cryptoparser/__setup__.py
|
|
15
|
+
cryptoparser/common/__init__.py
|
|
16
|
+
cryptoparser/common/base.py
|
|
17
|
+
cryptoparser/common/classes.py
|
|
18
|
+
cryptoparser/common/exception.py
|
|
19
|
+
cryptoparser/common/key.py
|
|
20
|
+
cryptoparser/common/parse.py
|
|
21
|
+
cryptoparser/common/utils.py
|
|
22
|
+
cryptoparser/common/x509.py
|
|
23
|
+
cryptoparser/httpx/__init__.py
|
|
24
|
+
cryptoparser/httpx/header.py
|
|
25
|
+
cryptoparser/httpx/parse.py
|
|
26
|
+
cryptoparser/httpx/version.py
|
|
27
|
+
cryptoparser/ssh/__init__.py
|
|
28
|
+
cryptoparser/ssh/key.py
|
|
29
|
+
cryptoparser/ssh/record.py
|
|
30
|
+
cryptoparser/ssh/subprotocol.py
|
|
31
|
+
cryptoparser/ssh/version.py
|
|
32
|
+
cryptoparser/tls/__init__.py
|
|
33
|
+
cryptoparser/tls/algorithm.py
|
|
34
|
+
cryptoparser/tls/ciphersuite.py
|
|
35
|
+
cryptoparser/tls/extension.py
|
|
36
|
+
cryptoparser/tls/grease.py
|
|
37
|
+
cryptoparser/tls/ldap.py
|
|
38
|
+
cryptoparser/tls/mysql.py
|
|
39
|
+
cryptoparser/tls/openvpn.py
|
|
40
|
+
cryptoparser/tls/postgresql.py
|
|
41
|
+
cryptoparser/tls/rdp.py
|
|
42
|
+
cryptoparser/tls/record.py
|
|
43
|
+
cryptoparser/tls/subprotocol.py
|
|
44
|
+
cryptoparser/tls/version.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
asn1crypto
|
|
2
|
+
attrs<22.0.1,>=19.1
|
|
3
|
+
cryptodatahub>=0.9.1
|
|
4
|
+
python-dateutil
|
|
5
|
+
python-dateutil
|
|
6
|
+
|
|
7
|
+
[:python_version < "3.4"]
|
|
8
|
+
py2-ipaddress
|
|
9
|
+
|
|
10
|
+
[:python_version < "3.5"]
|
|
11
|
+
typing
|
|
12
|
+
|
|
13
|
+
[:python_version < '3']
|
|
14
|
+
enum34==1.1.6
|
|
15
|
+
pathlib2==2.3.7.post1
|
|
16
|
+
Mock
|
|
17
|
+
unittest2
|
|
18
|
+
|
|
19
|
+
[pep8]
|
|
20
|
+
flake8
|
|
21
|
+
|
|
22
|
+
[pylint]
|
|
23
|
+
pylint
|
|
24
|
+
|
|
25
|
+
[test]
|
|
26
|
+
coverage
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
cryptoparser
|