regscale-cli 6.18.0.0__py3-none-any.whl → 6.19.0.1__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.
Potentially problematic release.
This version of regscale-cli might be problematic. Click here for more details.
- regscale/__init__.py +1 -1
- regscale/integrations/api_paginator.py +932 -0
- regscale/integrations/api_paginator_example.py +348 -0
- regscale/integrations/commercial/__init__.py +11 -10
- regscale/integrations/commercial/{qualys.py → qualys/__init__.py} +756 -105
- regscale/integrations/commercial/qualys/scanner.py +1051 -0
- regscale/integrations/commercial/qualys/variables.py +21 -0
- regscale/integrations/commercial/sicura/api.py +1 -0
- regscale/integrations/commercial/stigv2/click_commands.py +36 -8
- regscale/integrations/commercial/stigv2/stig_integration.py +63 -9
- regscale/integrations/commercial/tenablev2/__init__.py +9 -0
- regscale/integrations/commercial/tenablev2/authenticate.py +23 -2
- regscale/integrations/commercial/tenablev2/commands.py +779 -0
- regscale/integrations/commercial/tenablev2/jsonl_scanner.py +1999 -0
- regscale/integrations/commercial/tenablev2/sc_scanner.py +600 -0
- regscale/integrations/commercial/tenablev2/scanner.py +7 -5
- regscale/integrations/commercial/tenablev2/utils.py +21 -4
- regscale/integrations/commercial/tenablev2/variables.py +4 -0
- regscale/integrations/jsonl_scanner_integration.py +523 -142
- regscale/integrations/scanner_integration.py +102 -26
- regscale/integrations/transformer/__init__.py +17 -0
- regscale/integrations/transformer/data_transformer.py +445 -0
- regscale/integrations/transformer/mappings/__init__.py +8 -0
- regscale/integrations/variables.py +2 -0
- regscale/models/__init__.py +5 -2
- regscale/models/integration_models/cisa_kev_data.json +6 -6
- regscale/models/integration_models/synqly_models/capabilities.json +1 -1
- regscale/models/regscale_models/asset.py +5 -2
- regscale/models/regscale_models/file.py +5 -2
- regscale/models/regscale_models/group.py +2 -1
- regscale/models/regscale_models/user_group.py +1 -1
- regscale/regscale.py +3 -1
- {regscale_cli-6.18.0.0.dist-info → regscale_cli-6.19.0.1.dist-info}/METADATA +1 -1
- {regscale_cli-6.18.0.0.dist-info → regscale_cli-6.19.0.1.dist-info}/RECORD +46 -30
- tests/regscale/core/test_version.py +22 -0
- tests/regscale/integrations/__init__.py +0 -0
- tests/regscale/integrations/test_api_paginator.py +597 -0
- tests/regscale/integrations/test_integration_mapping.py +60 -0
- tests/regscale/integrations/test_issue_creation.py +317 -0
- tests/regscale/integrations/test_issue_due_date.py +46 -0
- tests/regscale/integrations/transformer/__init__.py +0 -0
- tests/regscale/integrations/transformer/test_data_transformer.py +850 -0
- regscale/integrations/commercial/tenablev2/click.py +0 -1641
- {regscale_cli-6.18.0.0.dist-info → regscale_cli-6.19.0.1.dist-info}/LICENSE +0 -0
- {regscale_cli-6.18.0.0.dist-info → regscale_cli-6.19.0.1.dist-info}/WHEEL +0 -0
- {regscale_cli-6.18.0.0.dist-info → regscale_cli-6.19.0.1.dist-info}/entry_points.txt +0 -0
- {regscale_cli-6.18.0.0.dist-info → regscale_cli-6.19.0.1.dist-info}/top_level.txt +0 -0
|
@@ -192,17 +192,20 @@ class Asset(RegScaleModel):
|
|
|
192
192
|
}
|
|
193
193
|
|
|
194
194
|
@classmethod
|
|
195
|
-
def get_map(
|
|
195
|
+
def get_map(
|
|
196
|
+
cls, plan_id: int, key_field: str = "otherTrackingNumber", is_component: Optional[bool] = False
|
|
197
|
+
) -> dict[str, "Asset"]:
|
|
196
198
|
"""
|
|
197
199
|
Get the asset map for the asset and cache it in Redis.
|
|
198
200
|
|
|
199
201
|
:param int plan_id: Security Plan ID
|
|
200
202
|
:param str key_field: Key field to use, defaults to "identifier"
|
|
203
|
+
:param bool is_component: Whether the plan_id is a component ID, defaults to False
|
|
201
204
|
:return: Asset Map
|
|
202
205
|
:rtype: dict[str, "Asset"]
|
|
203
206
|
"""
|
|
204
207
|
search_data = f"""query {{
|
|
205
|
-
assetMappings(skip: 0, take: 50, where: {{component: {{securityPlansId: {{eq: {plan_id}}} }} }}) {{
|
|
208
|
+
assetMappings(skip: 0, take: 50, where: {{component: {{{"id" if is_component else "securityPlansId"}: {{eq: {plan_id}}} }} }}) {{
|
|
206
209
|
items {{
|
|
207
210
|
id
|
|
208
211
|
asset {{
|
|
@@ -348,10 +348,13 @@ class File(BaseModel):
|
|
|
348
348
|
data=data,
|
|
349
349
|
files=files,
|
|
350
350
|
)
|
|
351
|
-
if not file_response
|
|
351
|
+
if not file_response:
|
|
352
|
+
api.logger.warning("File upload failed. Please check the file path and try again.")
|
|
353
|
+
return None
|
|
354
|
+
elif not file_response.ok:
|
|
352
355
|
api.logger.warning(f"{file_response.status_code} - {file_response.text}")
|
|
353
356
|
return None
|
|
354
|
-
|
|
357
|
+
else:
|
|
355
358
|
data = file_response.json()
|
|
356
359
|
data["size"] = file_size
|
|
357
360
|
return data
|
|
@@ -8,7 +8,8 @@ from typing import Optional, List, Tuple, cast
|
|
|
8
8
|
from pydantic import ConfigDict, Field
|
|
9
9
|
|
|
10
10
|
from regscale.core.app.utils.app_utils import get_current_datetime
|
|
11
|
-
from regscale.models import
|
|
11
|
+
from regscale.models import User, deprecated
|
|
12
|
+
from regscale.models.regscale_models.regscale_model import RegScaleModel, T
|
|
12
13
|
from regscale.models.regscale_models.user_group import UserGroup
|
|
13
14
|
|
|
14
15
|
logger = logging.getLogger(__name__)
|
|
@@ -7,7 +7,7 @@ from typing import Optional
|
|
|
7
7
|
from pydantic import ConfigDict, Field
|
|
8
8
|
|
|
9
9
|
from regscale.core.app.utils.app_utils import get_current_datetime
|
|
10
|
-
from regscale.models import RegScaleModel
|
|
10
|
+
from regscale.models.regscale_models.regscale_model import RegScaleModel
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
class UserGroup(RegScaleModel):
|
regscale/regscale.py
CHANGED
|
@@ -181,7 +181,7 @@ sonarcloud = import_command_with_timing(COMMERCIAL, "sonarcloud")
|
|
|
181
181
|
tenable = import_command_with_timing(COMMERCIAL, "tenable")
|
|
182
182
|
trivy = import_command_with_timing(COMMERCIAL, "trivy")
|
|
183
183
|
grype = import_command_with_timing(COMMERCIAL, "grype")
|
|
184
|
-
|
|
184
|
+
tenable_v2 = import_command_with_timing("regscale.integrations.commercial.tenablev2.commands", "tenable")
|
|
185
185
|
veracode = import_command_with_timing(COMMERCIAL, "veracode")
|
|
186
186
|
wiz = import_command_with_timing(COMMERCIAL, "wiz")
|
|
187
187
|
xray = import_command_with_timing(COMMERCIAL, "xray")
|
|
@@ -800,6 +800,8 @@ cli.add_command(tenable) # add Tenable support
|
|
|
800
800
|
cli.add_command(trivy) # add Trivy support
|
|
801
801
|
cli.add_command(wiz) # add Wiz support
|
|
802
802
|
cli.add_command(xray) # add JFrog Xray support
|
|
803
|
+
tenable_v2.name = "tenable2" # Use a different name to avoid conflict
|
|
804
|
+
cli.add_command(tenable_v2) # add Tenable v2 support
|
|
803
805
|
|
|
804
806
|
############################################################
|
|
805
807
|
# Add Public Integrations
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
regscale/__init__.py,sha256=
|
|
2
|
-
regscale/regscale.py,sha256=
|
|
1
|
+
regscale/__init__.py,sha256=BVzwcyu7M9vUKN8JF2eHy61Le8zrZvupLmlwkhOLLag,25
|
|
2
|
+
regscale/regscale.py,sha256=t4uLMzy9P_KeKazI9ZTQupTkbgh28uMilLSpmzn7adE,30983
|
|
3
3
|
regscale/airflow/__init__.py,sha256=yMwN0Bz4JbM0nl5qY_hPegxo_O2ilhTOL9PY5Njhn-s,270
|
|
4
4
|
regscale/airflow/click_dags.py,sha256=H3SUR5jkvInNMv1gu-VG-Ja_H-kH145CpQYNalWNAbE,4520
|
|
5
5
|
regscale/airflow/click_mixins.py,sha256=BTwKWsEu6KVtlrzFbXpD_RuEpMzc-CSnCCySUzqzCgQ,3571
|
|
@@ -107,11 +107,13 @@ regscale/exceptions/__init__.py,sha256=97lZsao_6Dz4U8LVgOiXV0arRkkN6XAEu4ZkelMh4
|
|
|
107
107
|
regscale/exceptions/license_exception.py,sha256=5lDYW1uGf7dHFKBkhzYD3FlNnI6W4BICXi24OJyOs_w,195
|
|
108
108
|
regscale/exceptions/validation_exception.py,sha256=_DW_GARtPr_Dyy8tolnvC_AYsHRsUUvRz_Rkk8-fjgk,219
|
|
109
109
|
regscale/integrations/__init__.py,sha256=Sqthp3Jggo7co_go380cLn3OAb0cHwqL609_4QJSFBY,58
|
|
110
|
+
regscale/integrations/api_paginator.py,sha256=73rjaNM9mGv8evHAeoObXEjZPg-bJuGPo60ewCLEil8,33192
|
|
111
|
+
regscale/integrations/api_paginator_example.py,sha256=lEuYI-xEGcjnXuIzbCobCP0YRuukLF0s8S3d382SAH4,12119
|
|
110
112
|
regscale/integrations/integration_override.py,sha256=PH7t_bf-RCe_it3FJ61tlKX5UghqHuSEQNJWDfCamAg,5480
|
|
111
|
-
regscale/integrations/jsonl_scanner_integration.py,sha256=
|
|
112
|
-
regscale/integrations/scanner_integration.py,sha256=
|
|
113
|
-
regscale/integrations/variables.py,sha256=
|
|
114
|
-
regscale/integrations/commercial/__init__.py,sha256=
|
|
113
|
+
regscale/integrations/jsonl_scanner_integration.py,sha256=fglDgJN9alUvbJzNYKrlIf_25oqQ8kIU0moE3f9tDMQ,56717
|
|
114
|
+
regscale/integrations/scanner_integration.py,sha256=ECWOq2bZ-4LwwXxlEXd5VkCqtlXRhcNeRn2pHMYyZUU,134678
|
|
115
|
+
regscale/integrations/variables.py,sha256=A0R76VAeJFj48wHnNgUY-xaD7QKcSmGO9-9cQLlqDJ8,2071
|
|
116
|
+
regscale/integrations/commercial/__init__.py,sha256=BZcCIUdyW027NjOGkcBOT52RPSLrtUv69UEPIkAmq1M,13319
|
|
115
117
|
regscale/integrations/commercial/ad.py,sha256=YXSmK8vRf6yi2GnREGa5GrE6GelhFrLj44SY8AO1pK0,15509
|
|
116
118
|
regscale/integrations/commercial/burp.py,sha256=G7v_sMP2FsskT7N2V1OZgBe_aAwLdCbB1zW2qdzSy6g,2762
|
|
117
119
|
regscale/integrations/commercial/cpe.py,sha256=eXZeDXicnp1yYgKuyKcthQUYxXi2Pgc__UD8lUqr5H0,4924
|
|
@@ -125,7 +127,6 @@ regscale/integrations/commercial/jira.py,sha256=1fBF3y4kotbD9hFtqZxlBIb4Q6iNkhIK
|
|
|
125
127
|
regscale/integrations/commercial/nexpose.py,sha256=lqPw9yk7ywHDoLwPeXKSz9DaLyVzOQIKOotCgayVTNE,2853
|
|
126
128
|
regscale/integrations/commercial/okta.py,sha256=VNwE848xiBxkha4DibkhLJN-fi0T8rLMd30PPAmRjpk,30837
|
|
127
129
|
regscale/integrations/commercial/prisma.py,sha256=shr71NkaSfcg2m-Ak6EVV9ozAFPibiOoehEty24MtyA,2841
|
|
128
|
-
regscale/integrations/commercial/qualys.py,sha256=-ql86aJtL3Gde9s_JiVRI7yStfqOH2FbEoU8XHcA6Bo,53274
|
|
129
130
|
regscale/integrations/commercial/salesforce.py,sha256=vvXWlXxhJMQj45tU7wz7o4YbkhqjPlaMx_6SWYkI3Bs,36671
|
|
130
131
|
regscale/integrations/commercial/servicenow.py,sha256=nUVZwt8-G1rQhwACX6i2BKIAjkMtd46uskBznxgOOsA,64014
|
|
131
132
|
regscale/integrations/commercial/snyk.py,sha256=j2cN90BzzcZDeORDcnMbuQwL3__FRd-X5JnH3ZpMKJE,2816
|
|
@@ -179,6 +180,9 @@ regscale/integrations/commercial/nessus/scanner.py,sha256=xz-OBd98ZbKKWnuxsP7oTq
|
|
|
179
180
|
regscale/integrations/commercial/opentext/__init__.py,sha256=zqCPb_4rYRZZPXfeKn4AoZyyYyQ6MU4C0lCs2ysOBhc,251
|
|
180
181
|
regscale/integrations/commercial/opentext/commands.py,sha256=RBsZUOE2qYBbVzKAX4hkhWqT6VUMXAA8l_NtTY2T2WE,2212
|
|
181
182
|
regscale/integrations/commercial/opentext/scanner.py,sha256=xDNQlce1OpbS4ZTey6FvDtVMg1If701Tay4t7R1EPHs,22433
|
|
183
|
+
regscale/integrations/commercial/qualys/__init__.py,sha256=QfIzQXtVckEFN3lP_wZeeESm23WFkX28lfJbVYoDHhg,78158
|
|
184
|
+
regscale/integrations/commercial/qualys/scanner.py,sha256=G_cBNd0qwyo0K2IgUO_IS6fQh9Jc_1bdNczjTwq5MIU,43398
|
|
185
|
+
regscale/integrations/commercial/qualys/variables.py,sha256=TPoIW5_yNmU6c0AlLOpHQdxp6OrH8jUmMJikqT7YYz8,962
|
|
182
186
|
regscale/integrations/commercial/sap/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
183
187
|
regscale/integrations/commercial/sap/click.py,sha256=pWgjUOA_4WKkDUWcE8z4EshnJUdrTl15NKUfKpKyqzE,522
|
|
184
188
|
regscale/integrations/commercial/sap/sysdig/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -188,7 +192,7 @@ regscale/integrations/commercial/sap/tenable/__init__.py,sha256=47DEQpj8HBSa-_TI
|
|
|
188
192
|
regscale/integrations/commercial/sap/tenable/click.py,sha256=vCdRe6d5ey6mywtL8GY21n5ecqWTdYLLDceEOy8QrLg,1425
|
|
189
193
|
regscale/integrations/commercial/sap/tenable/scanner.py,sha256=eeXXe2b-zoth80pVcasO7Cy-3NhW_4PcDhin1G8hj0o,9363
|
|
190
194
|
regscale/integrations/commercial/sicura/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
191
|
-
regscale/integrations/commercial/sicura/api.py,sha256=
|
|
195
|
+
regscale/integrations/commercial/sicura/api.py,sha256=4FDM3ATk8bysdGaBtcfsexlZoTHUf-ckA60eGrK-KDk,32151
|
|
192
196
|
regscale/integrations/commercial/sicura/commands.py,sha256=-54gqCpmGECC1ph5Wpr8cwYhBscsQy1V_24-xQ0sFyw,1874
|
|
193
197
|
regscale/integrations/commercial/sicura/scanner.py,sha256=WWYTs1JDIz_5mxqkAS_bnY3EbIqQGet7NHul2lWxFWw,17726
|
|
194
198
|
regscale/integrations/commercial/sicura/variables.py,sha256=FOdXj5bTtmsAYJYLdLxYMalKhkP1l0bWjA5bCmvgvdU,676
|
|
@@ -197,20 +201,22 @@ regscale/integrations/commercial/stig_mapper_integration/click_commands.py,sha25
|
|
|
197
201
|
regscale/integrations/commercial/stig_mapper_integration/mapping_engine.py,sha256=woASLcQVB9Ta__1FteY3cyf9fc8vNOYBSSFvH5lrAVk,14022
|
|
198
202
|
regscale/integrations/commercial/stigv2/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
199
203
|
regscale/integrations/commercial/stigv2/ckl_parser.py,sha256=RPrDGsKqAbTJMsJd3AYe_8SCzL00ZsB8RnuL8iPTjS0,11896
|
|
200
|
-
regscale/integrations/commercial/stigv2/click_commands.py,sha256=
|
|
201
|
-
regscale/integrations/commercial/stigv2/stig_integration.py,sha256
|
|
204
|
+
regscale/integrations/commercial/stigv2/click_commands.py,sha256=Tywelob4WwZuriSZV7-qgCeNzWtChMPimeBI2unYEqo,3552
|
|
205
|
+
regscale/integrations/commercial/stigv2/stig_integration.py,sha256=-UlfL0BBI3jFGotctOJyTCRAU9zIXW6mwU7ySrRXE9U,11573
|
|
202
206
|
regscale/integrations/commercial/synqly/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
203
207
|
regscale/integrations/commercial/synqly/assets.py,sha256=GcDGe6XvumaAYyo5Af8Ccmg1DzLfgnNFGdsyRdKsiEs,1412
|
|
204
208
|
regscale/integrations/commercial/synqly/edr.py,sha256=Z2gwscLvrFLKcodU83qbVn1jF8eFhwdjXm94LA8EwxQ,2444
|
|
205
209
|
regscale/integrations/commercial/synqly/ticketing.py,sha256=6UhmDa0l-GYTJAyc93HiaS-maCVQD9UtDcGIjQ9n270,4909
|
|
206
210
|
regscale/integrations/commercial/synqly/vulnerabilities.py,sha256=B8GwfKVDdoOIikjZO-4KqDNf-ApXlcJNkwmno0FjDOQ,7842
|
|
207
|
-
regscale/integrations/commercial/tenablev2/__init__.py,sha256=
|
|
208
|
-
regscale/integrations/commercial/tenablev2/authenticate.py,sha256=
|
|
209
|
-
regscale/integrations/commercial/tenablev2/
|
|
210
|
-
regscale/integrations/commercial/tenablev2/
|
|
211
|
+
regscale/integrations/commercial/tenablev2/__init__.py,sha256=UpSY_oww83kz9c7amdbptJKwDB1gAOBQDS-Q9WFp588,295
|
|
212
|
+
regscale/integrations/commercial/tenablev2/authenticate.py,sha256=VPTmxaVCaah2gJYNeU9P1KoQ734ohGQ-wcVy6JfqDTE,1247
|
|
213
|
+
regscale/integrations/commercial/tenablev2/commands.py,sha256=MedjPqMXTudoYP32gErio-1FVgDwzrDnh6CxelMotaQ,26180
|
|
214
|
+
regscale/integrations/commercial/tenablev2/jsonl_scanner.py,sha256=zNruS_Oi6ls6lJTUxwdD6jRiXCvVLuGI2nvpF29pvU4,83485
|
|
215
|
+
regscale/integrations/commercial/tenablev2/sc_scanner.py,sha256=Y70eZf_1DM3Np9tlrvZ_OHHjqzHjqrizFcHG8esqLQQ,23220
|
|
216
|
+
regscale/integrations/commercial/tenablev2/scanner.py,sha256=bKm7MmZ_xAjKwNT0x16WvuRbQcip3pXg8xqPNHejgKs,21584
|
|
211
217
|
regscale/integrations/commercial/tenablev2/stig_parsers.py,sha256=01h5ImYMUsjrVHaGgqj5JVBx6Jzlhg06ufu0SL_uBEs,5983
|
|
212
|
-
regscale/integrations/commercial/tenablev2/utils.py,sha256=
|
|
213
|
-
regscale/integrations/commercial/tenablev2/variables.py,sha256=
|
|
218
|
+
regscale/integrations/commercial/tenablev2/utils.py,sha256=_MmvcR71PmvH4dQ1k4M-q4PYAg0EE_aQ9w4cUdP7SwE,3359
|
|
219
|
+
regscale/integrations/commercial/tenablev2/variables.py,sha256=CHK8HpSFHMUF4HWj0xosfEQ-RRNDoWdeRvjJok_mKpU,991
|
|
214
220
|
regscale/integrations/commercial/trivy/__init__.py,sha256=fTTABeR1Z3Wei3l-A54SoTPn2mrMQrKLmr9SwTyYLTM,117
|
|
215
221
|
regscale/integrations/commercial/trivy/commands.py,sha256=uzK-15k6ZNdOQ9TxAIF_3wj5rqiJ9UDRRlZVPnXhQvQ,2068
|
|
216
222
|
regscale/integrations/commercial/trivy/scanner.py,sha256=rs7amq0IbJPbV40CJI8Mgr5Nn51XFmv4C1VsYjaWqnk,11204
|
|
@@ -275,7 +281,10 @@ regscale/integrations/public/fedramp/models/leveraged_auth_new.py,sha256=MIJ7pMY
|
|
|
275
281
|
regscale/integrations/public/fedramp/models/poam_importer.py,sha256=UP98NOwzmCgN7666q1IgiVrwfPyXbCeCalDQmXctic8,20993
|
|
276
282
|
regscale/integrations/public/fedramp/poam/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
277
283
|
regscale/integrations/public/fedramp/poam/scanner.py,sha256=M15Mx6xC1IjSbJ4ZHXjF9nZvJRlAH8FrTX-tvhBNZuM,34134
|
|
278
|
-
regscale/
|
|
284
|
+
regscale/integrations/transformer/__init__.py,sha256=XFmkvjPjpZkQPknz0NEC0pQsWA2JNtPygbeUCf_b5jk,484
|
|
285
|
+
regscale/integrations/transformer/data_transformer.py,sha256=J2FlY1vqPVzVafE4AwjJZvuN_rmsg4xP6qZjNqQtBt8,15407
|
|
286
|
+
regscale/integrations/transformer/mappings/__init__.py,sha256=Pp6Qb0dVtr0ehIujmSbNLzQy2nVogLajiDfP4XY_7-w,247
|
|
287
|
+
regscale/models/__init__.py,sha256=-0IaJGCvCkrSNqhv-l63hs1etqk3uJF278AKxvWjWxk,299
|
|
279
288
|
regscale/models/click_models.py,sha256=EI0HFFXQvGy53boZ473ayDJP-qpQsCdufD0xkUGqM3I,15295
|
|
280
289
|
regscale/models/config.py,sha256=M_ftoZUgYL8x1CliDk8Pw6jMhPlz83_xh_Gi8lAabQ4,5420
|
|
281
290
|
regscale/models/email_style.css,sha256=d8PlsCiOxmmkp2Qc7T4qI9Ha5mT12Jn9kRBMOk2xx2Q,2202
|
|
@@ -296,7 +305,7 @@ regscale/models/integration_models/azure_alerts.py,sha256=2etrpvcxa7jVQrc98bJlVG
|
|
|
296
305
|
regscale/models/integration_models/base64.py,sha256=sxV6O5qY1_TstJENX5jBPsSdQwmA83-NNhgJFunXiZE,570
|
|
297
306
|
regscale/models/integration_models/burp.py,sha256=hPQkmmUdC84MBFTE2Di5NvjbGz1ssISSkZdDaVi-ZoQ,16941
|
|
298
307
|
regscale/models/integration_models/burp_models.py,sha256=UytDTAcCaxyu-knFkm_mEUH6UmWK3OTXKSC9Sc6OjVs,3669
|
|
299
|
-
regscale/models/integration_models/cisa_kev_data.json,sha256=
|
|
308
|
+
regscale/models/integration_models/cisa_kev_data.json,sha256=cwg8yXKaprwRWSyS7tZz56Zy-8DzwcpVCOilohvHXfg,1164738
|
|
300
309
|
regscale/models/integration_models/defender_data.py,sha256=jsAcjKxiGmumGerj7xSWkFd6r__YpuKDnYX5o7xHDiE,2844
|
|
301
310
|
regscale/models/integration_models/defenderimport.py,sha256=OFwEH0Xu-HFLIZJZ8hP60Ov3lS8RR7KHEsw4wI8QnoE,5766
|
|
302
311
|
regscale/models/integration_models/drf.py,sha256=Aq7AdLa_CH97NrnR-CxaFI22JjVN9uCxVN7Z-BBUaNU,18896
|
|
@@ -322,7 +331,7 @@ regscale/models/integration_models/flat_file_importer/__init__.py,sha256=Mq4V3tR
|
|
|
322
331
|
regscale/models/integration_models/sbom/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
323
332
|
regscale/models/integration_models/sbom/cyclone_dx.py,sha256=0pFR0BWBrF5c8_cC_8mj2MXvNOMHOdHbBYXvTVfFAh8,4058
|
|
324
333
|
regscale/models/integration_models/synqly_models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
325
|
-
regscale/models/integration_models/synqly_models/capabilities.json,sha256=
|
|
334
|
+
regscale/models/integration_models/synqly_models/capabilities.json,sha256=A3xtvxBnjgrpMYudRG4UuryPyCCutevdfeK_L4q8cTs,259829
|
|
326
335
|
regscale/models/integration_models/synqly_models/connector_types.py,sha256=8nxptkTexpskySnmL0obNAff_iu_fx6tJ7i1-4hJvao,461
|
|
327
336
|
regscale/models/integration_models/synqly_models/ocsf_mapper.py,sha256=e2kTOhWSNRnzbgMchMx-7c21pCgSv2DqWnxvajKEKJM,16960
|
|
328
337
|
regscale/models/integration_models/synqly_models/param.py,sha256=45zgYUV4U9Ia8-CdIb4TlE3vfDMMtbfA1y5LOiznnH8,2645
|
|
@@ -339,7 +348,7 @@ regscale/models/integration_models/tenable_models/models.py,sha256=dmG7btkN4YkDW
|
|
|
339
348
|
regscale/models/regscale_models/__init__.py,sha256=OmFpksQ7e1P52xkBfP5_CTew1A4JiB65cvNuwchGXWU,1900
|
|
340
349
|
regscale/models/regscale_models/assessment.py,sha256=ekzNlcsfDGBu97PMCi7hBRGbzVgxk7Ij0RfrdGh1Rfw,20440
|
|
341
350
|
regscale/models/regscale_models/assessment_plan.py,sha256=8AEj-lSq5kk7nSMJ7wJmDwkY9h94PB-oD7qKfLfT9cE,1701
|
|
342
|
-
regscale/models/regscale_models/asset.py,sha256
|
|
351
|
+
regscale/models/regscale_models/asset.py,sha256=-ws6o6hRl2sMLNcT8CIw0SQvOwLtrVSeEp5kF80ydAQ,19840
|
|
343
352
|
regscale/models/regscale_models/asset_mapping.py,sha256=HFlkAoPZHy2xPYq28cXuzLpFoP36SI08HTL8mH_Q-uE,6851
|
|
344
353
|
regscale/models/regscale_models/case.py,sha256=hLVTwZXzusnXR9avqh7xSVLJwPJ1rPI_Nla_VAkpZcg,1192
|
|
345
354
|
regscale/models/regscale_models/catalog.py,sha256=U0nEyQSKgMuNCWh22gGk5sC-xeBmN8UXHiBsJKIFNZ8,8546
|
|
@@ -365,11 +374,11 @@ regscale/models/regscale_models/email.py,sha256=kgEzXTUZr7uHksMOCextWbXJXYuRKyXO
|
|
|
365
374
|
regscale/models/regscale_models/evidence.py,sha256=nOc328HreJgSNFhlLh8lfZclj2HQOq46Ee1Lo1xSrqI,1904
|
|
366
375
|
regscale/models/regscale_models/evidence_mapping.py,sha256=1TPFUEGl0uWChdAcVuFkEAwl36twRVfN81Hz4vNUI5A,1440
|
|
367
376
|
regscale/models/regscale_models/facility.py,sha256=J3gGv0Tf3zNdyKGhb0iM8WjgjWqJHZLKdcN9n-jDrTA,1059
|
|
368
|
-
regscale/models/regscale_models/file.py,sha256=
|
|
377
|
+
regscale/models/regscale_models/file.py,sha256=_95A8ERXkA7CQRmbl3z7dpe2uZyrkEcGlSKDpIYwurg,14360
|
|
369
378
|
regscale/models/regscale_models/filetag.py,sha256=jd99xcQsGheLFfy7PYtZEzT-re_Dp_ZoUF3GWYMsi0Q,1138
|
|
370
379
|
regscale/models/regscale_models/form_field_value.py,sha256=4LQrIdJgDwBh2Fyne9CH-EJ8G21a-tglxod8D48r2lY,3443
|
|
371
380
|
regscale/models/regscale_models/functional_roles.py,sha256=Vm_j-UZBKoaiONO75VqqCKnDHE6ynP0X5XZmKXl8UT8,932
|
|
372
|
-
regscale/models/regscale_models/group.py,sha256=
|
|
381
|
+
regscale/models/regscale_models/group.py,sha256=HFE3FPUIYo7PArHnvZhb8EQToZQ73jFRU1M-oaHuees,6209
|
|
373
382
|
regscale/models/regscale_models/implementation_objective.py,sha256=e0Hamt-9RBeHRDzlWDbIJ3t4qnZKXPrbsesBK3wYoNk,12132
|
|
374
383
|
regscale/models/regscale_models/implementation_option.py,sha256=gEScteJjmTq_jw010gnOJbvYE6ZeWmrGdl6Qs1kw_Mc,11395
|
|
375
384
|
regscale/models/regscale_models/implementation_role.py,sha256=ZjJOhjM3dVlulsGx3lUKgG49LpxNzx6J-RwTd4eRgx0,1107
|
|
@@ -417,7 +426,7 @@ regscale/models/regscale_models/tag_mapping.py,sha256=QtafVsWjpBR8BAxRhabk3FL3E4
|
|
|
417
426
|
regscale/models/regscale_models/task.py,sha256=eKVdR89Gb6M9E2plhK4fru8teQI3zPJpgtJ0f43FOrY,4919
|
|
418
427
|
regscale/models/regscale_models/threat.py,sha256=4TNZcRnTgmlDwBsYu5Pbh9GRd8ZWAtqqr0Xph3uPNAA,7255
|
|
419
428
|
regscale/models/regscale_models/user.py,sha256=2OfrIlwD-vtEMnC2Pn_ch2Ze5S_p7_SgBD4ejXmestI,6854
|
|
420
|
-
regscale/models/regscale_models/user_group.py,sha256=
|
|
429
|
+
regscale/models/regscale_models/user_group.py,sha256=vzlXHvPNsgJd38H0R3osi46Oj19QO5oPx0qXntQBKWI,1891
|
|
421
430
|
regscale/models/regscale_models/vulnerability.py,sha256=VKgWMVvAQ74Sq46myYsivGfIeW63dHq3bv3cRCkDcbg,10960
|
|
422
431
|
regscale/models/regscale_models/vulnerability_mapping.py,sha256=cq44xkkCH7rfp0BJxavr4DLiEAHouyyPmi5EaizH6NI,6261
|
|
423
432
|
regscale/models/regscale_models/workflow.py,sha256=uMNVVAn5qR8wxjMP5PHbcvMmvPRe1gn1oclVUpbv52s,1873
|
|
@@ -471,7 +480,14 @@ tests/regscale/core/test_login.py,sha256=Kl7ySS8JU7SzhmupaDexeUH8VOMjtMRJvW8-Cim
|
|
|
471
480
|
tests/regscale/core/test_logz.py,sha256=Yf6tAthETLlYOEp3hee3ovDw-WnZ_6fTw3e1rjx4xSw,2621
|
|
472
481
|
tests/regscale/core/test_sbom_generator.py,sha256=lgzo1HRbkNIIDZIeKiM2JbbIYQsak0BpU0GlvbrcexM,2935
|
|
473
482
|
tests/regscale/core/test_validation_utils.py,sha256=5GHQfSVEr3f1HzEatI5CyCgGriyc-OPyKbc1YQ9zRjI,5464
|
|
474
|
-
tests/regscale/core/test_version.py,sha256=
|
|
483
|
+
tests/regscale/core/test_version.py,sha256=q8F2ERXxdToXbYxfOcP9f6lkUYaxF4jEmsPUmduMo9U,3216
|
|
484
|
+
tests/regscale/integrations/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
485
|
+
tests/regscale/integrations/test_api_paginator.py,sha256=42-F8FMkJwkZ1Xlsj7YYVyOb6-rbxwI4F4H6Y4ZI9jA,18973
|
|
486
|
+
tests/regscale/integrations/test_integration_mapping.py,sha256=ffl7opp6_IDxScSOfULy8ASqytYUMAqGA5c3PpAu3u8,1981
|
|
487
|
+
tests/regscale/integrations/test_issue_creation.py,sha256=L4Fjww16S6sst2kqLoE0PK6WYL_pijSMzzxpWzdajRo,12089
|
|
488
|
+
tests/regscale/integrations/test_issue_due_date.py,sha256=W8TVOlsB3nIVJdTHm0UKTsBFycTdpVDDji0-eUFXmMg,1448
|
|
489
|
+
tests/regscale/integrations/transformer/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
490
|
+
tests/regscale/integrations/transformer/test_data_transformer.py,sha256=Na-trXL2n97b6H6V9CwVU4nvqkL8HMy7E2yvAuhKtSo,36584
|
|
475
491
|
tests/regscale/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
476
492
|
tests/regscale/models/test_asset.py,sha256=eFt-GvH5rkAT04LxtdfnR88LoqSPT6a-1fScMchp8lE,2435
|
|
477
493
|
tests/regscale/models/test_config.py,sha256=r2mIJJDpmnLYZjw8Nw7yTzwZCsHbmfZD4rHSupfeOec,797
|
|
@@ -484,9 +500,9 @@ tests/regscale/models/test_regscale_model.py,sha256=ZsrEZkC4EtdIsoQuayn1xv2gEGcV
|
|
|
484
500
|
tests/regscale/models/test_report.py,sha256=eiSvS_zS0aVeL0HBvtmHVvEzcfF9ZFVn2twj5g8KttY,970
|
|
485
501
|
tests/regscale/models/test_tenable_integrations.py,sha256=PNJC2Zu6lv1xj7y6e1yOsz5FktSU3PRKb5x3n5YG3w0,4072
|
|
486
502
|
tests/regscale/models/test_user_model.py,sha256=e9olv28qBApgnvK6hFHOgXjUC-pkaV8aGDirEIWASL4,4427
|
|
487
|
-
regscale_cli-6.
|
|
488
|
-
regscale_cli-6.
|
|
489
|
-
regscale_cli-6.
|
|
490
|
-
regscale_cli-6.
|
|
491
|
-
regscale_cli-6.
|
|
492
|
-
regscale_cli-6.
|
|
503
|
+
regscale_cli-6.19.0.1.dist-info/LICENSE,sha256=ytNhYQ9Rmhj_m-EX2pPq9Ld6tH5wrqqDYg-fCf46WDU,1076
|
|
504
|
+
regscale_cli-6.19.0.1.dist-info/METADATA,sha256=wWhMYlFSOvacarUAvTVNBKFy-HAUeWd_br8BZQH0Jho,30913
|
|
505
|
+
regscale_cli-6.19.0.1.dist-info/WHEEL,sha256=oiQVh_5PnQM0E3gPdiz09WCNmwiHDMaGer_elqB3coM,92
|
|
506
|
+
regscale_cli-6.19.0.1.dist-info/entry_points.txt,sha256=cLOaIP1eRv1yZ2u7BvpE3aB4x3kDrDwkpeisKOu33z8,269
|
|
507
|
+
regscale_cli-6.19.0.1.dist-info/top_level.txt,sha256=Uv8VUCAdxRm70bgrD4YNEJUmDhBThad_1aaEFGwRByc,15
|
|
508
|
+
regscale_cli-6.19.0.1.dist-info/RECORD,,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"""Tests for the version module."""
|
|
2
2
|
|
|
3
|
+
import os
|
|
3
4
|
from unittest.mock import patch
|
|
4
5
|
import pytest
|
|
5
6
|
import logging
|
|
@@ -76,3 +77,24 @@ def test_compare_versions(version1, version2, dev_is_latest, expected):
|
|
|
76
77
|
def test_meets_minimum_version(mock_get_platform_version, minimum_version, dev_is_latest, expected):
|
|
77
78
|
"""Test meets_minimum_version method."""
|
|
78
79
|
assert RegscaleVersion.meets_minimum_version(minimum_version, dev_is_latest) == expected
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
def test_no_application_initialized():
|
|
83
|
+
"""Test no application initialized."""
|
|
84
|
+
# Run the regscale version command and verify the word app is not in the console output
|
|
85
|
+
import re
|
|
86
|
+
import subprocess
|
|
87
|
+
|
|
88
|
+
log_level = "LOGLEVEL"
|
|
89
|
+
|
|
90
|
+
previous_value = os.getenv(log_level)
|
|
91
|
+
os.environ[log_level] = "DEBUG"
|
|
92
|
+
process = subprocess.run(
|
|
93
|
+
["regscale", "version"],
|
|
94
|
+
stdout=subprocess.PIPE,
|
|
95
|
+
stderr=subprocess.PIPE,
|
|
96
|
+
text=True,
|
|
97
|
+
)
|
|
98
|
+
assert not re.search(r"Initializing\s+(?:.*?\.py:\d+\s+)?Application", process.stdout)
|
|
99
|
+
print(process.stdout)
|
|
100
|
+
os.environ[log_level] = previous_value or "INFO"
|
|
File without changes
|