datadog-checks-base 37.6.1__py2.py3-none-any.whl → 37.7.0__py2.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.
@@ -1,4 +1,4 @@
1
1
  # (C) Datadog, Inc. 2018-present
2
2
  # All rights reserved
3
3
  # Licensed under a 3-clause BSD style license (see LICENSE)
4
- __version__ = "37.6.1"
4
+ __version__ = "37.7.0"
@@ -385,7 +385,7 @@ class AggregatorStub(object):
385
385
  if hostname is not None and hostname != sc.hostname:
386
386
  continue
387
387
 
388
- if message is not None and message != sc.message:
388
+ if message is not None and re.search(message, sc.message) is None:
389
389
  continue
390
390
 
391
391
  candidates.append(sc)
@@ -2,7 +2,11 @@
2
2
  # All rights reserved
3
3
  # Licensed under a 3-clause BSD style license (see LICENSE)
4
4
 
5
+ import logging
5
6
  import os
7
+ import sys
8
+
9
+ LOGGER = logging.getLogger(__file__)
6
10
 
7
11
 
8
12
  def enable_fips(path_to_openssl_conf=None, path_to_openssl_modules=None):
@@ -24,6 +28,32 @@ def enable_fips(path_to_openssl_conf=None, path_to_openssl_modules=None):
24
28
  os.environ["OPENSSL_MODULES"] = str(path_to_openssl_modules)
25
29
 
26
30
 
31
+ def is_enabled():
32
+ enabled = False
33
+ # On Windows, FIPS mode is activated through a registry:
34
+ # https://csrc.nist.gov/CSRC/media/projects/cryptographic-module-validation-program/documents/security-policies/140sp4825.pdf
35
+ # We copy the Agent's implementation for this function:
36
+ # https://github.com/DataDog/datadog-agent/tree/main/pkg/fips
37
+ if sys.platform == "win32":
38
+ try:
39
+ import winreg
40
+
41
+ with winreg.OpenKey(
42
+ winreg.HKEY_LOCAL_MACHINE, r"SYSTEM\CurrentControlSet\Control\Lsa\FipsAlgorithmPolicy"
43
+ ) as key:
44
+ fips_registry, _ = winreg.QueryValueEx(key, "Enabled")
45
+ enabled = fips_registry == 1
46
+ except Exception as e:
47
+ LOGGER.debug(
48
+ "Windows error encountered when fetching FipsAlgorithmPolicy registry key,\
49
+ assuming FIPS mode is disabled: %s",
50
+ e,
51
+ )
52
+ else:
53
+ enabled = os.environ.get("GOFIPS", "0") == "1"
54
+ return enabled
55
+
56
+
27
57
  def _get_embedded_path():
28
58
  import sys
29
59
  from pathlib import Path
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: datadog-checks-base
3
- Version: 37.6.1
3
+ Version: 37.7.0
4
4
  Summary: The Datadog Check Toolkit
5
5
  Project-URL: Source, https://github.com/DataDog/integrations-core
6
6
  Author-email: Datadog <packages@datadoghq.com>
@@ -3,7 +3,7 @@ datadog_checks/config.py,sha256=PrAXGdlLnoV2VMQff_noSaSJJ0wg4BAiGnw7jCQLSik,196
3
3
  datadog_checks/errors.py,sha256=eFwmnrX-batIgbu-iJyseqAPNO_4rk1UuaKK89evLhg,155
4
4
  datadog_checks/log.py,sha256=orvOgMKGNEsqSTLalCAQpWP-ouorpG1A7Gn-j2mRD80,301
5
5
  datadog_checks/py.typed,sha256=la67KBlbjXN-_-DfGNcdOcjYumVpKG_Tkw-8n5dnGB4,8
6
- datadog_checks/base/__about__.py,sha256=L56e6SJ2L24q3EfI391-ib0_nBXjubulAGFIAmNCTgA,138
6
+ datadog_checks/base/__about__.py,sha256=uC9MNosQSG_gx-e-sqvVM7JrsKTSw1P50Ns6IDQUAko,138
7
7
  datadog_checks/base/__init__.py,sha256=rSTDo6-2p_RX6I6wnuXrNMglaatoLRyZFTE5wbHZY8s,1466
8
8
  datadog_checks/base/agent.py,sha256=nX9x_BYYizRKGNYfXq5z7S0FZ9xcX_wd2tuxpGe3_8k,350
9
9
  datadog_checks/base/config.py,sha256=qcAA4X9sXQZRdwQe8DgiGd2980VBp1SQA0d695tX_tU,604
@@ -85,7 +85,7 @@ datadog_checks/base/checks/windows/perf_counters/transformers/temporal_percent.p
85
85
  datadog_checks/base/checks/windows/perf_counters/transformers/time_elapsed.py,sha256=hWM8CHYSqFnFYrNdr1NFY464nMAVFOiN8jhlhZTOb78,513
86
86
  datadog_checks/base/stubs/__init__.py,sha256=wpWAR9v7BiTbbmTO6pVpshqa_z-PWaYTr33wSTZLz3c,272
87
87
  datadog_checks/base/stubs/_util.py,sha256=ZDGtQa8F3cHf8-QvSVHMB4BGI3C9VgC7sGcGGvO0apI,1268
88
- datadog_checks/base/stubs/aggregator.py,sha256=GIVfe0IAbvloKlm886PLjLyjVyz9nkOdq51oZpK9liY,24431
88
+ datadog_checks/base/stubs/aggregator.py,sha256=Px4JgZNjh-vMHibfGR452ZiA3kUiHA02ZUIDK70d62A,24448
89
89
  datadog_checks/base/stubs/common.py,sha256=ZGzF2dXy1uVFQGdG_bvz_pMMiULaBcpzra_k9wo9f04,1088
90
90
  datadog_checks/base/stubs/datadog_agent.py,sha256=u4e8ZFSt4CO9mxuZ4UinteIJOyLKQgzcHFa0pTzRaCY,5995
91
91
  datadog_checks/base/stubs/log.py,sha256=A-eWnzY5gTpTW41Zch-W5CVclzldlmhMTW-vDNFdT1o,836
@@ -98,7 +98,7 @@ datadog_checks/base/utils/constants.py,sha256=QwTey4CWB0NAxm2rcD-wPYRkEyglekQIrA
98
98
  datadog_checks/base/utils/containers.py,sha256=LBqUzERHxx5TdgcWVQTq1A1WaGCMhzXT9k4Gn0fX3J8,2753
99
99
  datadog_checks/base/utils/date.py,sha256=JJmqP84CgVcFJ0cvAmMu8EtM6v96tIESucQNm9eKeEc,2780
100
100
  datadog_checks/base/utils/diagnose.py,sha256=eLMe0tISpkzS3yxVR83IHxorQJfHT_Xi6Cq4zzRNxVI,5285
101
- datadog_checks/base/utils/fips.py,sha256=G92RNoZkrMojaTKi1DiccbvfMFO3adktDZgKjpxkkTw,1400
101
+ datadog_checks/base/utils/fips.py,sha256=vxm3K7wTQKYenP1LbXk7pmJ8WA6l367BTJGBNO0DkvQ,2490
102
102
  datadog_checks/base/utils/functions.py,sha256=iGlybxR6aPPElNxNb2ELOzbk328j9OVBAxredJxdCRw,695
103
103
  datadog_checks/base/utils/headers.py,sha256=0SSdC71jwaB61BODfusahCVr1c56GvT9iwt7cidcHP0,1779
104
104
  datadog_checks/base/utils/http.py,sha256=TcOdwoFKggxr_VsCEQoXlxFFGS-n9UYz4pDZH2zxjoM,40516
@@ -200,6 +200,6 @@ datadog_checks/utils/tracing.py,sha256=HQbQakKM-Lw75MDkItaYJYipS6YO24Z_ymDVxDsx5
200
200
  datadog_checks/utils/prometheus/__init__.py,sha256=8WwXnM9g1sfS5267QYCJX_hd8MZl5kRgBgQ_SzdNdXs,161
201
201
  datadog_checks/utils/prometheus/functions.py,sha256=4vWsTGLgujHwdYZo0tlAQkqDPHofqUJM3k9eItJqERQ,197
202
202
  datadog_checks/utils/prometheus/metrics_pb2.py,sha256=xg3UdUHe4TjeR4s13LUKZ2U1WVSt6U6zjsVRG6lX6dc,173
203
- datadog_checks_base-37.6.1.dist-info/METADATA,sha256=iMylQRYC88icbKrkMES-dTg1SzDEhgsInJI-6c_Vh0o,3591
204
- datadog_checks_base-37.6.1.dist-info/WHEEL,sha256=tkmg4JIqwd9H8mL30xA7crRmoStyCtGp0VWshokd1Jc,105
205
- datadog_checks_base-37.6.1.dist-info/RECORD,,
203
+ datadog_checks_base-37.7.0.dist-info/METADATA,sha256=PZB-HV-qp0-y24D_xbNPaucom3CEhb-kaDpnQ7LOmhs,3591
204
+ datadog_checks_base-37.7.0.dist-info/WHEEL,sha256=tkmg4JIqwd9H8mL30xA7crRmoStyCtGp0VWshokd1Jc,105
205
+ datadog_checks_base-37.7.0.dist-info/RECORD,,