revengai 1.89.2__py3-none-any.whl → 1.89.4__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 revengai might be problematic. Click here for more details.
- revengai/__init__.py +3 -1
- revengai/api_client.py +1 -1
- revengai/configuration.py +2 -2
- revengai/models/__init__.py +1 -0
- revengai/models/analysis_function_matching_request.py +10 -4
- revengai/models/auto_unstrip_request.py +4 -4
- revengai/models/function_matching_batch_response.py +15 -1
- revengai/models/function_matching_request.py +10 -4
- revengai/models/function_matching_result_with_best_match.py +25 -20
- revengai/models/matched_function.py +9 -2
- revengai/models/name_confidence.py +89 -0
- {revengai-1.89.2.dist-info → revengai-1.89.4.dist-info}/METADATA +2 -1
- {revengai-1.89.2.dist-info → revengai-1.89.4.dist-info}/RECORD +14 -13
- {revengai-1.89.2.dist-info → revengai-1.89.4.dist-info}/WHEEL +0 -0
revengai/__init__.py
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
""" # noqa: E501
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
__version__ = "v1.89.
|
|
16
|
+
__version__ = "v1.89.4"
|
|
17
17
|
|
|
18
18
|
# Define package exports
|
|
19
19
|
__all__ = [
|
|
@@ -285,6 +285,7 @@ __all__ = [
|
|
|
285
285
|
"MetaModel",
|
|
286
286
|
"ModelName",
|
|
287
287
|
"ModelsResponse",
|
|
288
|
+
"NameConfidence",
|
|
288
289
|
"NearestNeighbor",
|
|
289
290
|
"NetworkOverviewDns",
|
|
290
291
|
"NetworkOverviewDnsAnswer",
|
|
@@ -633,6 +634,7 @@ from revengai.models.matched_function_suggestion import MatchedFunctionSuggestio
|
|
|
633
634
|
from revengai.models.meta_model import MetaModel as MetaModel
|
|
634
635
|
from revengai.models.model_name import ModelName as ModelName
|
|
635
636
|
from revengai.models.models_response import ModelsResponse as ModelsResponse
|
|
637
|
+
from revengai.models.name_confidence import NameConfidence as NameConfidence
|
|
636
638
|
from revengai.models.nearest_neighbor import NearestNeighbor as NearestNeighbor
|
|
637
639
|
from revengai.models.network_overview_dns import NetworkOverviewDns as NetworkOverviewDns
|
|
638
640
|
from revengai.models.network_overview_dns_answer import NetworkOverviewDnsAnswer as NetworkOverviewDnsAnswer
|
revengai/api_client.py
CHANGED
|
@@ -90,7 +90,7 @@ class ApiClient:
|
|
|
90
90
|
self.default_headers[header_name] = header_value
|
|
91
91
|
self.cookie = cookie
|
|
92
92
|
# Set default User-Agent.
|
|
93
|
-
self.user_agent = 'OpenAPI-Generator/v1.89.
|
|
93
|
+
self.user_agent = 'OpenAPI-Generator/v1.89.4/python'
|
|
94
94
|
self.client_side_validation = configuration.client_side_validation
|
|
95
95
|
|
|
96
96
|
def __enter__(self):
|
revengai/configuration.py
CHANGED
|
@@ -529,8 +529,8 @@ conf = revengai.Configuration(
|
|
|
529
529
|
return "Python SDK Debug Report:\n"\
|
|
530
530
|
"OS: {env}\n"\
|
|
531
531
|
"Python Version: {pyversion}\n"\
|
|
532
|
-
"Version of the API: v1.89.
|
|
533
|
-
"SDK Package Version: v1.89.
|
|
532
|
+
"Version of the API: v1.89.4\n"\
|
|
533
|
+
"SDK Package Version: v1.89.4".\
|
|
534
534
|
format(env=sys.platform, pyversion=sys.version)
|
|
535
535
|
|
|
536
536
|
def get_host_settings(self) -> List[HostSetting]:
|
revengai/models/__init__.py
CHANGED
|
@@ -251,6 +251,7 @@ from revengai.models.matched_function_suggestion import MatchedFunctionSuggestio
|
|
|
251
251
|
from revengai.models.meta_model import MetaModel
|
|
252
252
|
from revengai.models.model_name import ModelName
|
|
253
253
|
from revengai.models.models_response import ModelsResponse
|
|
254
|
+
from revengai.models.name_confidence import NameConfidence
|
|
254
255
|
from revengai.models.nearest_neighbor import NearestNeighbor
|
|
255
256
|
from revengai.models.network_overview_dns import NetworkOverviewDns
|
|
256
257
|
from revengai.models.network_overview_dns_answer import NetworkOverviewDnsAnswer
|
|
@@ -27,9 +27,12 @@ class AnalysisFunctionMatchingRequest(BaseModel):
|
|
|
27
27
|
"""
|
|
28
28
|
AnalysisFunctionMatchingRequest
|
|
29
29
|
""" # noqa: E501
|
|
30
|
-
min_similarity: Optional[Union[Annotated[float, Field(le=
|
|
30
|
+
min_similarity: Optional[Union[Annotated[float, Field(le=100.0, strict=True, ge=0.0)], Annotated[int, Field(le=100, strict=True, ge=0)]]] = Field(default=90.0, description="Minimum similarity expected for a match as a percentage, default is 90")
|
|
31
31
|
filters: Optional[FunctionMatchingFilters] = None
|
|
32
|
-
|
|
32
|
+
results_per_function: Optional[Annotated[int, Field(le=10, strict=True, ge=1)]] = Field(default=1, description="Maximum number of matches to return per function, default is 1, max is 10")
|
|
33
|
+
page: Optional[Annotated[int, Field(strict=True, ge=1)]] = Field(default=1, description="Page number for paginated results, default is 1 (first page)")
|
|
34
|
+
page_size: Optional[Annotated[int, Field(le=1000, strict=True, ge=0)]] = Field(default=0, description="Number of functions to return per page, default is 0 (all functions), max is 1000")
|
|
35
|
+
__properties: ClassVar[List[str]] = ["min_similarity", "filters", "results_per_function", "page", "page_size"]
|
|
33
36
|
|
|
34
37
|
model_config = ConfigDict(
|
|
35
38
|
populate_by_name=True,
|
|
@@ -90,8 +93,11 @@ class AnalysisFunctionMatchingRequest(BaseModel):
|
|
|
90
93
|
return cls.model_validate(obj)
|
|
91
94
|
|
|
92
95
|
_obj = cls.model_validate({
|
|
93
|
-
"min_similarity": obj.get("min_similarity") if obj.get("min_similarity") is not None else 0
|
|
94
|
-
"filters": FunctionMatchingFilters.from_dict(obj["filters"]) if obj.get("filters") is not None else None
|
|
96
|
+
"min_similarity": obj.get("min_similarity") if obj.get("min_similarity") is not None else 90.0,
|
|
97
|
+
"filters": FunctionMatchingFilters.from_dict(obj["filters"]) if obj.get("filters") is not None else None,
|
|
98
|
+
"results_per_function": obj.get("results_per_function") if obj.get("results_per_function") is not None else 1,
|
|
99
|
+
"page": obj.get("page") if obj.get("page") is not None else 1,
|
|
100
|
+
"page_size": obj.get("page_size") if obj.get("page_size") is not None else 0
|
|
95
101
|
})
|
|
96
102
|
return _obj
|
|
97
103
|
|
|
@@ -26,9 +26,9 @@ class AutoUnstripRequest(BaseModel):
|
|
|
26
26
|
"""
|
|
27
27
|
AutoUnstripRequest
|
|
28
28
|
""" # noqa: E501
|
|
29
|
-
min_similarity: Optional[Union[Annotated[float, Field(le=
|
|
29
|
+
min_similarity: Optional[Union[Annotated[float, Field(le=100.0, strict=True, ge=0.0)], Annotated[int, Field(le=100, strict=True, ge=0)]]] = Field(default=90.0, description="Minimum similarity expected for a match as a percentage, default is 90")
|
|
30
30
|
apply: Optional[StrictBool] = Field(default=False, description="Whether to apply the matched function names to the target binary, default is False")
|
|
31
|
-
confidence_threshold: Optional[Union[Annotated[float, Field(le=
|
|
31
|
+
confidence_threshold: Optional[Union[Annotated[float, Field(le=100.0, strict=True, ge=0.0)], Annotated[int, Field(le=100, strict=True, ge=0)]]] = Field(default=90.0, description="Confidence threshold for applying function names as a percentage, default is 90")
|
|
32
32
|
min_group_size: Optional[Annotated[int, Field(le=20, strict=True, ge=1)]] = Field(default=10, description="Minimum number of matching functions required to consider for a match, default is 10")
|
|
33
33
|
__properties: ClassVar[List[str]] = ["min_similarity", "apply", "confidence_threshold", "min_group_size"]
|
|
34
34
|
|
|
@@ -83,9 +83,9 @@ class AutoUnstripRequest(BaseModel):
|
|
|
83
83
|
return cls.model_validate(obj)
|
|
84
84
|
|
|
85
85
|
_obj = cls.model_validate({
|
|
86
|
-
"min_similarity": obj.get("min_similarity") if obj.get("min_similarity") is not None else 0
|
|
86
|
+
"min_similarity": obj.get("min_similarity") if obj.get("min_similarity") is not None else 90.0,
|
|
87
87
|
"apply": obj.get("apply") if obj.get("apply") is not None else False,
|
|
88
|
-
"confidence_threshold": obj.get("confidence_threshold") if obj.get("confidence_threshold") is not None else 0
|
|
88
|
+
"confidence_threshold": obj.get("confidence_threshold") if obj.get("confidence_threshold") is not None else 90.0,
|
|
89
89
|
"min_group_size": obj.get("min_group_size") if obj.get("min_group_size") is not None else 10
|
|
90
90
|
})
|
|
91
91
|
return _obj
|
|
@@ -30,8 +30,10 @@ class FunctionMatchingBatchResponse(BaseModel):
|
|
|
30
30
|
status: Optional[StrictStr] = None
|
|
31
31
|
total_time: Optional[StrictInt] = None
|
|
32
32
|
error_message: Optional[StrictStr] = None
|
|
33
|
+
current_page: Optional[StrictInt] = None
|
|
34
|
+
total_pages: Optional[StrictInt] = None
|
|
33
35
|
matches: List[FunctionMatchingResultWithBestMatch]
|
|
34
|
-
__properties: ClassVar[List[str]] = ["progress", "status", "total_time", "error_message", "matches"]
|
|
36
|
+
__properties: ClassVar[List[str]] = ["progress", "status", "total_time", "error_message", "current_page", "total_pages", "matches"]
|
|
35
37
|
|
|
36
38
|
model_config = ConfigDict(
|
|
37
39
|
populate_by_name=True,
|
|
@@ -94,6 +96,16 @@ class FunctionMatchingBatchResponse(BaseModel):
|
|
|
94
96
|
if self.error_message is None and "error_message" in self.model_fields_set:
|
|
95
97
|
_dict['error_message'] = None
|
|
96
98
|
|
|
99
|
+
# set to None if current_page (nullable) is None
|
|
100
|
+
# and model_fields_set contains the field
|
|
101
|
+
if self.current_page is None and "current_page" in self.model_fields_set:
|
|
102
|
+
_dict['current_page'] = None
|
|
103
|
+
|
|
104
|
+
# set to None if total_pages (nullable) is None
|
|
105
|
+
# and model_fields_set contains the field
|
|
106
|
+
if self.total_pages is None and "total_pages" in self.model_fields_set:
|
|
107
|
+
_dict['total_pages'] = None
|
|
108
|
+
|
|
97
109
|
return _dict
|
|
98
110
|
|
|
99
111
|
@classmethod
|
|
@@ -110,6 +122,8 @@ class FunctionMatchingBatchResponse(BaseModel):
|
|
|
110
122
|
"status": obj.get("status"),
|
|
111
123
|
"total_time": obj.get("total_time"),
|
|
112
124
|
"error_message": obj.get("error_message"),
|
|
125
|
+
"current_page": obj.get("current_page"),
|
|
126
|
+
"total_pages": obj.get("total_pages"),
|
|
113
127
|
"matches": [FunctionMatchingResultWithBestMatch.from_dict(_item) for _item in obj["matches"]] if obj.get("matches") is not None else None
|
|
114
128
|
})
|
|
115
129
|
return _obj
|
|
@@ -29,9 +29,12 @@ class FunctionMatchingRequest(BaseModel):
|
|
|
29
29
|
""" # noqa: E501
|
|
30
30
|
model_id: StrictInt = Field(description="ID of the model used for function matching, used to determine the embedding model")
|
|
31
31
|
function_ids: List[StrictInt] = Field(description="ID's of functions to find matches for, must be at least one function ID")
|
|
32
|
-
min_similarity: Optional[Union[Annotated[float, Field(le=
|
|
32
|
+
min_similarity: Optional[Union[Annotated[float, Field(le=100.0, strict=True, ge=0.0)], Annotated[int, Field(le=100, strict=True, ge=0)]]] = Field(default=90.0, description="Minimum similarity expected for a match as a percentage, default is 90")
|
|
33
33
|
filters: Optional[FunctionMatchingFilters] = None
|
|
34
|
-
|
|
34
|
+
results_per_function: Optional[Annotated[int, Field(le=10, strict=True, ge=1)]] = Field(default=1, description="Maximum number of matches to return per function, default is 1, max is 10")
|
|
35
|
+
page: Optional[Annotated[int, Field(strict=True, ge=1)]] = Field(default=1, description="Page number for paginated results, default is 1 (first page)")
|
|
36
|
+
page_size: Optional[Annotated[int, Field(le=1000, strict=True, ge=0)]] = Field(default=0, description="Number of functions to return per page, default is 0 (all functions), max is 1000")
|
|
37
|
+
__properties: ClassVar[List[str]] = ["model_id", "function_ids", "min_similarity", "filters", "results_per_function", "page", "page_size"]
|
|
35
38
|
|
|
36
39
|
model_config = ConfigDict(
|
|
37
40
|
populate_by_name=True,
|
|
@@ -94,8 +97,11 @@ class FunctionMatchingRequest(BaseModel):
|
|
|
94
97
|
_obj = cls.model_validate({
|
|
95
98
|
"model_id": obj.get("model_id"),
|
|
96
99
|
"function_ids": obj.get("function_ids"),
|
|
97
|
-
"min_similarity": obj.get("min_similarity") if obj.get("min_similarity") is not None else 0
|
|
98
|
-
"filters": FunctionMatchingFilters.from_dict(obj["filters"]) if obj.get("filters") is not None else None
|
|
100
|
+
"min_similarity": obj.get("min_similarity") if obj.get("min_similarity") is not None else 90.0,
|
|
101
|
+
"filters": FunctionMatchingFilters.from_dict(obj["filters"]) if obj.get("filters") is not None else None,
|
|
102
|
+
"results_per_function": obj.get("results_per_function") if obj.get("results_per_function") is not None else 1,
|
|
103
|
+
"page": obj.get("page") if obj.get("page") is not None else 1,
|
|
104
|
+
"page_size": obj.get("page_size") if obj.get("page_size") is not None else 0
|
|
99
105
|
})
|
|
100
106
|
return _obj
|
|
101
107
|
|
|
@@ -16,9 +16,10 @@ import pprint
|
|
|
16
16
|
import re # noqa: F401
|
|
17
17
|
import json
|
|
18
18
|
|
|
19
|
-
from pydantic import BaseModel, ConfigDict,
|
|
20
|
-
from typing import Any, ClassVar, Dict, List, Optional
|
|
19
|
+
from pydantic import BaseModel, ConfigDict, StrictInt
|
|
20
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
21
21
|
from revengai.models.matched_function import MatchedFunction
|
|
22
|
+
from revengai.models.name_confidence import NameConfidence
|
|
22
23
|
from typing import Optional, Set
|
|
23
24
|
from typing_extensions import Self
|
|
24
25
|
|
|
@@ -27,10 +28,9 @@ class FunctionMatchingResultWithBestMatch(BaseModel):
|
|
|
27
28
|
FunctionMatchingResultWithBestMatch
|
|
28
29
|
""" # noqa: E501
|
|
29
30
|
function_id: StrictInt
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
__properties: ClassVar[List[str]] = ["function_id", "matched_function", "suggested_name", "suggested_name_confidence"]
|
|
31
|
+
matched_functions: List[MatchedFunction]
|
|
32
|
+
confidences: Optional[List[NameConfidence]] = None
|
|
33
|
+
__properties: ClassVar[List[str]] = ["function_id", "matched_functions", "confidences"]
|
|
34
34
|
|
|
35
35
|
model_config = ConfigDict(
|
|
36
36
|
populate_by_name=True,
|
|
@@ -71,18 +71,24 @@ class FunctionMatchingResultWithBestMatch(BaseModel):
|
|
|
71
71
|
exclude=excluded_fields,
|
|
72
72
|
exclude_none=True,
|
|
73
73
|
)
|
|
74
|
-
# override the default output from pydantic by calling `to_dict()` of
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
74
|
+
# override the default output from pydantic by calling `to_dict()` of each item in matched_functions (list)
|
|
75
|
+
_items = []
|
|
76
|
+
if self.matched_functions:
|
|
77
|
+
for _item_matched_functions in self.matched_functions:
|
|
78
|
+
if _item_matched_functions:
|
|
79
|
+
_items.append(_item_matched_functions.to_dict())
|
|
80
|
+
_dict['matched_functions'] = _items
|
|
81
|
+
# override the default output from pydantic by calling `to_dict()` of each item in confidences (list)
|
|
82
|
+
_items = []
|
|
83
|
+
if self.confidences:
|
|
84
|
+
for _item_confidences in self.confidences:
|
|
85
|
+
if _item_confidences:
|
|
86
|
+
_items.append(_item_confidences.to_dict())
|
|
87
|
+
_dict['confidences'] = _items
|
|
88
|
+
# set to None if confidences (nullable) is None
|
|
78
89
|
# and model_fields_set contains the field
|
|
79
|
-
if self.
|
|
80
|
-
_dict['
|
|
81
|
-
|
|
82
|
-
# set to None if suggested_name_confidence (nullable) is None
|
|
83
|
-
# and model_fields_set contains the field
|
|
84
|
-
if self.suggested_name_confidence is None and "suggested_name_confidence" in self.model_fields_set:
|
|
85
|
-
_dict['suggested_name_confidence'] = None
|
|
90
|
+
if self.confidences is None and "confidences" in self.model_fields_set:
|
|
91
|
+
_dict['confidences'] = None
|
|
86
92
|
|
|
87
93
|
return _dict
|
|
88
94
|
|
|
@@ -97,9 +103,8 @@ class FunctionMatchingResultWithBestMatch(BaseModel):
|
|
|
97
103
|
|
|
98
104
|
_obj = cls.model_validate({
|
|
99
105
|
"function_id": obj.get("function_id"),
|
|
100
|
-
"
|
|
101
|
-
"
|
|
102
|
-
"suggested_name_confidence": obj.get("suggested_name_confidence")
|
|
106
|
+
"matched_functions": [MatchedFunction.from_dict(_item) for _item in obj["matched_functions"]] if obj.get("matched_functions") is not None else None,
|
|
107
|
+
"confidences": [NameConfidence.from_dict(_item) for _item in obj["confidences"]] if obj.get("confidences") is not None else None
|
|
103
108
|
})
|
|
104
109
|
return _obj
|
|
105
110
|
|
|
@@ -35,7 +35,8 @@ class MatchedFunction(BaseModel):
|
|
|
35
35
|
sha_256_hash: StrictStr
|
|
36
36
|
analysis_id: StrictInt
|
|
37
37
|
similarity: Optional[Union[StrictFloat, StrictInt]] = None
|
|
38
|
-
|
|
38
|
+
confidence: Optional[Union[StrictFloat, StrictInt]] = None
|
|
39
|
+
__properties: ClassVar[List[str]] = ["function_id", "binary_id", "function_name", "function_vaddr", "mangled_name", "debug", "binary_name", "sha_256_hash", "analysis_id", "similarity", "confidence"]
|
|
39
40
|
|
|
40
41
|
model_config = ConfigDict(
|
|
41
42
|
populate_by_name=True,
|
|
@@ -86,6 +87,11 @@ class MatchedFunction(BaseModel):
|
|
|
86
87
|
if self.similarity is None and "similarity" in self.model_fields_set:
|
|
87
88
|
_dict['similarity'] = None
|
|
88
89
|
|
|
90
|
+
# set to None if confidence (nullable) is None
|
|
91
|
+
# and model_fields_set contains the field
|
|
92
|
+
if self.confidence is None and "confidence" in self.model_fields_set:
|
|
93
|
+
_dict['confidence'] = None
|
|
94
|
+
|
|
89
95
|
return _dict
|
|
90
96
|
|
|
91
97
|
@classmethod
|
|
@@ -107,7 +113,8 @@ class MatchedFunction(BaseModel):
|
|
|
107
113
|
"binary_name": obj.get("binary_name"),
|
|
108
114
|
"sha_256_hash": obj.get("sha_256_hash"),
|
|
109
115
|
"analysis_id": obj.get("analysis_id"),
|
|
110
|
-
"similarity": obj.get("similarity")
|
|
116
|
+
"similarity": obj.get("similarity"),
|
|
117
|
+
"confidence": obj.get("confidence")
|
|
111
118
|
})
|
|
112
119
|
return _obj
|
|
113
120
|
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
RevEng.AI API
|
|
5
|
+
|
|
6
|
+
RevEng.AI is Similarity Search Engine for executable binaries
|
|
7
|
+
|
|
8
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
9
|
+
|
|
10
|
+
Do not edit the class manually.
|
|
11
|
+
""" # noqa: E501
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
from __future__ import annotations
|
|
15
|
+
import pprint
|
|
16
|
+
import re # noqa: F401
|
|
17
|
+
import json
|
|
18
|
+
|
|
19
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
20
|
+
from typing import Any, ClassVar, Dict, List, Union
|
|
21
|
+
from typing_extensions import Annotated
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class NameConfidence(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
NameConfidence
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
name: StrictStr = Field(description="The suggested function name")
|
|
30
|
+
confidence: Union[Annotated[float, Field(le=100.0, strict=True, ge=0.0)], Annotated[int, Field(le=100, strict=True, ge=0)]] = Field(description="Confidence score as a percentage")
|
|
31
|
+
__properties: ClassVar[List[str]] = ["name", "confidence"]
|
|
32
|
+
|
|
33
|
+
model_config = ConfigDict(
|
|
34
|
+
populate_by_name=True,
|
|
35
|
+
validate_assignment=True,
|
|
36
|
+
protected_namespaces=(),
|
|
37
|
+
)
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
def to_str(self) -> str:
|
|
41
|
+
"""Returns the string representation of the model using alias"""
|
|
42
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
43
|
+
|
|
44
|
+
def to_json(self) -> str:
|
|
45
|
+
"""Returns the JSON representation of the model using alias"""
|
|
46
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
47
|
+
return json.dumps(self.to_dict())
|
|
48
|
+
|
|
49
|
+
@classmethod
|
|
50
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
51
|
+
"""Create an instance of NameConfidence from a JSON string"""
|
|
52
|
+
return cls.from_dict(json.loads(json_str))
|
|
53
|
+
|
|
54
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
55
|
+
"""Return the dictionary representation of the model using alias.
|
|
56
|
+
|
|
57
|
+
This has the following differences from calling pydantic's
|
|
58
|
+
`self.model_dump(by_alias=True)`:
|
|
59
|
+
|
|
60
|
+
* `None` is only added to the output dict for nullable fields that
|
|
61
|
+
were set at model initialization. Other fields with value `None`
|
|
62
|
+
are ignored.
|
|
63
|
+
"""
|
|
64
|
+
excluded_fields: Set[str] = set([
|
|
65
|
+
])
|
|
66
|
+
|
|
67
|
+
_dict = self.model_dump(
|
|
68
|
+
by_alias=True,
|
|
69
|
+
exclude=excluded_fields,
|
|
70
|
+
exclude_none=True,
|
|
71
|
+
)
|
|
72
|
+
return _dict
|
|
73
|
+
|
|
74
|
+
@classmethod
|
|
75
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
76
|
+
"""Create an instance of NameConfidence from a dict"""
|
|
77
|
+
if obj is None:
|
|
78
|
+
return None
|
|
79
|
+
|
|
80
|
+
if not isinstance(obj, dict):
|
|
81
|
+
return cls.model_validate(obj)
|
|
82
|
+
|
|
83
|
+
_obj = cls.model_validate({
|
|
84
|
+
"name": obj.get("name"),
|
|
85
|
+
"confidence": obj.get("confidence")
|
|
86
|
+
})
|
|
87
|
+
return _obj
|
|
88
|
+
|
|
89
|
+
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: revengai
|
|
3
|
-
Version: 1.89.
|
|
3
|
+
Version: 1.89.4
|
|
4
4
|
Summary: RevEng.AI API
|
|
5
5
|
Project-URL: Repository, https://github.com/RevEngAI/revengai-python
|
|
6
6
|
Keywords: RevEng.AI API
|
|
@@ -415,6 +415,7 @@ Class | Method | HTTP request | Description
|
|
|
415
415
|
- [MetaModel](docs/MetaModel.md)
|
|
416
416
|
- [ModelName](docs/ModelName.md)
|
|
417
417
|
- [ModelsResponse](docs/ModelsResponse.md)
|
|
418
|
+
- [NameConfidence](docs/NameConfidence.md)
|
|
418
419
|
- [NearestNeighbor](docs/NearestNeighbor.md)
|
|
419
420
|
- [NetworkOverviewDns](docs/NetworkOverviewDns.md)
|
|
420
421
|
- [NetworkOverviewDnsAnswer](docs/NetworkOverviewDnsAnswer.md)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
revengai/__init__.py,sha256=
|
|
2
|
-
revengai/api_client.py,sha256=
|
|
1
|
+
revengai/__init__.py,sha256=yiB74i4IOzPCNvobaVqC5hRTgnqQNEgziE6qEZbumCY,44168
|
|
2
|
+
revengai/api_client.py,sha256=OHrdHHNqIxEV4Wdc9qgLIrnmdBvMRMCZCUflGq8Usk8,27670
|
|
3
3
|
revengai/api_response.py,sha256=eMxw1mpmJcoGZ3gs9z6jM4oYoZ10Gjk333s9sKxGv7s,652
|
|
4
|
-
revengai/configuration.py,sha256=
|
|
4
|
+
revengai/configuration.py,sha256=qh0HPuR5K7tGPdjUhzABtaG1v414lcvwyc_RT2okYsg,18749
|
|
5
5
|
revengai/exceptions.py,sha256=IvdI9ZIZ9b2lSSKtIKMQDlG-5UPAedrjm3U4xfmGkso,6385
|
|
6
6
|
revengai/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
7
7
|
revengai/rest.py,sha256=T6Q2dcazhntqm288H33BKC1hf8NVdvmQWgaymlJo158,9376
|
|
@@ -26,7 +26,7 @@ revengai/api/functions_renaming_history_api.py,sha256=L2CDadLnZrA0oNxhJfTSLLiMDz
|
|
|
26
26
|
revengai/api/functions_threat_score_api.py,sha256=RYbCaX71r2ssv7VxUrcezT8dSdU5K5ipHD6yR592k6I,23867
|
|
27
27
|
revengai/api/models_api.py,sha256=bqukeUMctErkaX5mH8Rm3iPKEHQOCx-JT-P8_KV_iP8,11319
|
|
28
28
|
revengai/api/search_api.py,sha256=Kzo7KfP4nY1-YsoCHxVOQm3Vn89kFjcnUV7oNdaw5z0,65835
|
|
29
|
-
revengai/models/__init__.py,sha256=
|
|
29
|
+
revengai/models/__init__.py,sha256=fzkAbG6D0iS6dPRokOKzJLrBsMixM8QIECWGV9LVCq4,23805
|
|
30
30
|
revengai/models/addr.py,sha256=-2N-UQsOiZ0eyEAQ7ssk0of8W2fBrXeYdTZXuVt3SZs,4787
|
|
31
31
|
revengai/models/ai_decompilation_rating.py,sha256=gyay27QJwToUNtK9NARyw731Sg8GFRTufGGUABVYyfo,722
|
|
32
32
|
revengai/models/ai_unstrip_request.py,sha256=loSXNdHATJmY5yttiUCE-lLEOkuE63qVDTz8U0eCAIc,2596
|
|
@@ -36,7 +36,7 @@ revengai/models/analysis_create_request.py,sha256=6hU94Fi47hrxXQ-wX1jRuDrDi1GQym
|
|
|
36
36
|
revengai/models/analysis_create_response.py,sha256=aaO3-lJ65iBGe5lnyW8exHb9qByDaWfF2hOVKrWkN-I,2628
|
|
37
37
|
revengai/models/analysis_detail_response.py,sha256=KPyzlSbu9TU7itVlhGusJVSszrZAkuC8dMg1welYZeM,4170
|
|
38
38
|
revengai/models/analysis_function_mapping.py,sha256=_8LOSaBOgsFKLeqvoizbU2FSHtekA7aNrM7deIJyM4k,2886
|
|
39
|
-
revengai/models/analysis_function_matching_request.py,sha256=
|
|
39
|
+
revengai/models/analysis_function_matching_request.py,sha256=gKIPk3xTwcQ5uBGVvSzwga9g8s5o1u_CTpbx-5YYZFU,4327
|
|
40
40
|
revengai/models/analysis_functions.py,sha256=N1TKQuw33I9dw-i07kLus36k2bcAXQVm2oc1Ycfrgdw,3067
|
|
41
41
|
revengai/models/analysis_record.py,sha256=DxnERhF-s5AilH804yKtMAOyXhhjWQsq0ned1ji5t5Q,5516
|
|
42
42
|
revengai/models/analysis_scope.py,sha256=azpsUux2axe4QKwQ4FbW30HbazYYVFP-e68F9zp33-4,668
|
|
@@ -57,7 +57,7 @@ revengai/models/app_api_rest_v2_similarity_schema_ann_function.py,sha256=atfQz2t
|
|
|
57
57
|
revengai/models/app_services_binary_ann_schema_tag_item.py,sha256=m25sIz8KEsPES0XGjmOZFhmLNLmB-jsakfRUpRfiMks,2977
|
|
58
58
|
revengai/models/app_services_dynamic_execution_schemas_dynamic_execution_status.py,sha256=9e3LDnw0iNCbowQPFTkNyIqkzsCQyJLZrx6tqRska6o,2562
|
|
59
59
|
revengai/models/argument.py,sha256=QmWpJiohyzTVC1GLHg1IlgM5QyONnBF6FGK_mOYQL_Y,3148
|
|
60
|
-
revengai/models/auto_unstrip_request.py,sha256=
|
|
60
|
+
revengai/models/auto_unstrip_request.py,sha256=Z_jmV5WnTIzdldBQPYBcKB-vlFxGEsxD2611HnBPDPo,3759
|
|
61
61
|
revengai/models/auto_unstrip_response.py,sha256=g37ANqNsVIM_BCb-kHNDak6E-8fNVUyPOh03YFjm2O8,4737
|
|
62
62
|
revengai/models/base_response.py,sha256=U1Hwv1TXztjpxHxXGwGk46egAYs49jfzEfr1nTajMjg,4526
|
|
63
63
|
revengai/models/base_response_analysis_create_response.py,sha256=bwA1vMqKgLUDcElBvuvTH2jo8tvx0mjfbMOnoniswbE,4682
|
|
@@ -223,10 +223,10 @@ revengai/models/function_info_output.py,sha256=iIxkZ6_KFSoz0NhbBXyNi7knPvWcIp-hm
|
|
|
223
223
|
revengai/models/function_local_variable_response.py,sha256=llv5alvfVXqxE3Cs6vt7qnQNyfwj4PBoxq_Sim65jic,2733
|
|
224
224
|
revengai/models/function_mapping.py,sha256=X4fa-lcMfO-40eVMtSTUPRpJlxdSZNEdzPTEOR0uAlg,2924
|
|
225
225
|
revengai/models/function_mapping_full.py,sha256=dax345vnk25zSPVVpAmCFrrOWXzFXW6OnhSs9zVIKpI,11948
|
|
226
|
-
revengai/models/function_matching_batch_response.py,sha256=
|
|
226
|
+
revengai/models/function_matching_batch_response.py,sha256=oBglZULIjMvbrlzjymWNKSNERVzftWH7hHBRC3uMoP0,4952
|
|
227
227
|
revengai/models/function_matching_filters.py,sha256=O5F1PIcPhbumH8z-4KbG7JNoUsx_H3wBZQU9kCZ_boI,3710
|
|
228
|
-
revengai/models/function_matching_request.py,sha256=
|
|
229
|
-
revengai/models/function_matching_result_with_best_match.py,sha256=
|
|
228
|
+
revengai/models/function_matching_request.py,sha256=V9SvbVDHayM21ZWjXbKJa4ggDOWhQTRN7r8E-12SjaU,4690
|
|
229
|
+
revengai/models/function_matching_result_with_best_match.py,sha256=87nF8Dq7b0bTmbpB_j5Upfsnv_hqAs_dZJ69zpLmQjs,4050
|
|
230
230
|
revengai/models/function_name_confidence_body.py,sha256=Dz8HvTUDn5YcyCie-KMXmOdy8yF8PD-m0XzwpRyyQmg,3415
|
|
231
231
|
revengai/models/function_name_history.py,sha256=INu3KWYUpQMFfWy6oWl5iSaxrlayKr-wvuiahRCzinI,3265
|
|
232
232
|
revengai/models/function_name_input.py,sha256=zKzb0qAJBZKadixsWnRfkTnFHdNGtS2i13QgSeHr4c0,2538
|
|
@@ -261,11 +261,12 @@ revengai/models/list_collection_results.py,sha256=ZYGFTvOQfI234u67tURX8J0jwb6q-A
|
|
|
261
261
|
revengai/models/login_request.py,sha256=48uYtkWFL_Q-hN64P1f15ExGJvbab9XLymBtDduQvg0,2684
|
|
262
262
|
revengai/models/login_response.py,sha256=O35cqntoQ68IdYCBtHTYhPXlDqw8CIlnK-bNjf6QMO0,2461
|
|
263
263
|
revengai/models/logs.py,sha256=cV_V-xN6q-yTd7eL-X89ugqz5ifWPsFPo6qYFgpS_Pw,2419
|
|
264
|
-
revengai/models/matched_function.py,sha256=
|
|
264
|
+
revengai/models/matched_function.py,sha256=UTMIoMa0xUSffexqQ5bjjSsehwFtjZ3-NDemz56Q1fM,4151
|
|
265
265
|
revengai/models/matched_function_suggestion.py,sha256=eNMKuAyJ94joT5It020lSujrporie50-ii_OCOk3KhY,2900
|
|
266
266
|
revengai/models/meta_model.py,sha256=GbyFJZ9kwvK1Gqg8QnJ1GHpaMs8cMht6j-MY1k0YSt0,2943
|
|
267
267
|
revengai/models/model_name.py,sha256=lVKok5pWyLcN1rhq1IYccC7uQQrPdyz1oohYRUMRrmw,1271
|
|
268
268
|
revengai/models/models_response.py,sha256=Ooo2HYuSI4llHg1wUMmyOsisPAXkPhR1y5BSiKh9ckg,2472
|
|
269
|
+
revengai/models/name_confidence.py,sha256=aVLK7raUE9IQcTEYW7GGjWDh2ciwkLHhlTWST-ZsD7s,2738
|
|
269
270
|
revengai/models/nearest_neighbor.py,sha256=iNNOEi_5Byh4lBshr77N7OWKx3hyFW47cxJNjnKwqKg,3980
|
|
270
271
|
revengai/models/network_overview_dns.py,sha256=Opx12khPVljqHvNf1nJaYV1_HBixed54602xPltzq54,3072
|
|
271
272
|
revengai/models/network_overview_dns_answer.py,sha256=-kL0ZdVz2xIxp5wOVsJre7Nh048UjD1mKLBbrVI5So0,2491
|
|
@@ -339,6 +340,6 @@ revengai/models/vulnerabilities.py,sha256=9t6uoZd3svWyfcZJjmj6zP731Dp47Apb25y8Qt
|
|
|
339
340
|
revengai/models/vulnerability.py,sha256=P7rAOAYU5JLLpcRr824-YJgZba5kPb_J9ALV3tSNfLQ,3688
|
|
340
341
|
revengai/models/vulnerability_type.py,sha256=SyOgfMmELYYc_H84oPkikBpjwngtG5Qw9Q_86a2TPr8,866
|
|
341
342
|
revengai/models/workspace.py,sha256=chjU62GFvByEmaNd6luMNQVQLP3wlPx1zJgGJ_yyMLA,676
|
|
342
|
-
revengai-1.89.
|
|
343
|
-
revengai-1.89.
|
|
344
|
-
revengai-1.89.
|
|
343
|
+
revengai-1.89.4.dist-info/METADATA,sha256=lIfou4ap8Pn0TuJlHMdVA9wR7cJbVqgObYqexHdAWW0,42460
|
|
344
|
+
revengai-1.89.4.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
345
|
+
revengai-1.89.4.dist-info/RECORD,,
|
|
File without changes
|