certifyclouds 1.3.8__tar.gz → 1.3.9__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.
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/PKG-INFO +1 -1
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/pyproject.toml +1 -1
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/__init__.py +1 -1
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/cli.py +20 -1
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/.gitignore +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/LICENSE +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/README.md +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/auth.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/config.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/filters.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/formatters/__init__.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/formatters/csv_fmt.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/formatters/html.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/formatters/json_fmt.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/formatters/table.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/registration.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/scanner.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/security.py +0 -0
- {certifyclouds-1.3.8 → certifyclouds-1.3.9}/src/cc_scanner/thumbprint.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: certifyclouds
|
|
3
|
-
Version: 1.3.
|
|
3
|
+
Version: 1.3.9
|
|
4
4
|
Summary: Scan Azure Key Vaults for expiring secrets, certificates, and keys
|
|
5
5
|
Project-URL: Homepage, https://certifyclouds.com/scanner
|
|
6
6
|
Project-URL: Documentation, https://docs.certifyclouds.com/scanner
|
|
@@ -123,6 +123,23 @@ def _setup_logging(verbosity: int) -> None:
|
|
|
123
123
|
logging.getLogger(name).setLevel(logging.WARNING)
|
|
124
124
|
|
|
125
125
|
|
|
126
|
+
|
|
127
|
+
def _exit_now(code: int) -> None:
|
|
128
|
+
"""Exit without waiting for in-flight scan threads.
|
|
129
|
+
|
|
130
|
+
``scan()`` returns at the timeout deadline (pool shut down with
|
|
131
|
+
``wait=False``), but the interpreter still joins non-daemon pool threads at
|
|
132
|
+
exit — ``threading._shutdown`` waits for them, and ThreadPoolExecutor has
|
|
133
|
+
not allowed daemon threads since Python 3.9. So a plain ``sys.exit`` here
|
|
134
|
+
holds the command open until the abandoned Azure call finishes, which is
|
|
135
|
+
exactly what --timeout promises not to do. ``os._exit`` after flushing
|
|
136
|
+
skips the join. Only used on the timed-out paths, where the lingering
|
|
137
|
+
thread is abandoned by design; normal exits keep ``sys.exit``.
|
|
138
|
+
"""
|
|
139
|
+
sys.stdout.flush()
|
|
140
|
+
sys.stderr.flush()
|
|
141
|
+
os._exit(code)
|
|
142
|
+
|
|
126
143
|
@click.command()
|
|
127
144
|
@click.option("--format", "fmt", type=click.Choice(["table", "json", "csv", "html"]),
|
|
128
145
|
default=None, help="Output format (default: table)")
|
|
@@ -249,6 +266,8 @@ def main(
|
|
|
249
266
|
console.print(" AZURE_TENANT_ID")
|
|
250
267
|
elif fmt == "json":
|
|
251
268
|
get_formatter("json")(results, [], output_file)
|
|
269
|
+
if results.get("timed_out"):
|
|
270
|
+
_exit_now(2)
|
|
252
271
|
sys.exit(2)
|
|
253
272
|
|
|
254
273
|
if results.get("timed_out"):
|
|
@@ -319,7 +338,7 @@ def main(
|
|
|
319
338
|
|
|
320
339
|
# Exit code
|
|
321
340
|
if results.get("timed_out"):
|
|
322
|
-
|
|
341
|
+
_exit_now(2)
|
|
323
342
|
if has_critical_or_high(findings):
|
|
324
343
|
sys.exit(1)
|
|
325
344
|
sys.exit(0)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|