certifyclouds 1.3.5__tar.gz → 1.3.6__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: certifyclouds
3
- Version: 1.3.5
3
+ Version: 1.3.6
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
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "certifyclouds"
3
- version = "1.3.5"
3
+ version = "1.3.6"
4
4
  description = "Scan Azure Key Vaults for expiring secrets, certificates, and keys"
5
5
  readme = "README.md"
6
6
  license = { text = "Apache-2.0" }
@@ -1,3 +1,3 @@
1
1
  """CertifyClouds Scanner — scan Azure Key Vaults for expiring secrets, certificates, and keys."""
2
2
 
3
- __version__ = "1.3.5"
3
+ __version__ = "1.3.6"
@@ -25,6 +25,22 @@ from .security import analyze, has_critical_or_high
25
25
  console = Console()
26
26
 
27
27
 
28
+ def _is_newer_version(latest: str, current: str) -> bool:
29
+ """True if `latest` is strictly higher than `current` as dotted-integer semver.
30
+
31
+ Uses tuple comparison on `int`-parsed segments. Returns False on any
32
+ parse failure (e.g. pre-release suffixes like "1.3.5rc1") — we'd
33
+ rather skip the banner than tell the user to upgrade from a newer
34
+ dev build to an older release.
35
+ """
36
+ try:
37
+ return tuple(int(p) for p in latest.split(".")) > tuple(
38
+ int(p) for p in current.split(".")
39
+ )
40
+ except (ValueError, AttributeError):
41
+ return False
42
+
43
+
28
44
  _LOGO_LINES = [
29
45
  " ▄▄███▄▄ ",
30
46
  " ▄▄███▀▀ ▀▀███▄▄ ",
@@ -287,7 +303,7 @@ def main(
287
303
  console.print()
288
304
  elif validation.offline and validation.error:
289
305
  console.print(f"[dim]{validation.error}. Scanning in offline mode.[/dim]")
290
- elif validation.latest_version and validation.latest_version != __version__:
306
+ elif validation.latest_version and _is_newer_version(validation.latest_version, __version__):
291
307
  console.print(f"[dim]Update available: cc-scan {__version__} → {validation.latest_version} — pip install --upgrade certifyclouds[/dim]")
292
308
  if validation.release_notes:
293
309
  console.print(f"[dim] What's new: {validation.release_notes}[/dim]")
File without changes
File without changes
File without changes