-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from trendmicro/feature/pytmv1-client
Update of pytmv1 code into GH
- Loading branch information
Showing
37 changed files
with
4,737 additions
and
122 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[run] | ||
omit = __about__.py |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
[build-system] | ||
requires = ["hatchling>=1.12.2"] | ||
build-backend = "hatchling.build" | ||
|
||
[project] | ||
name = "pytmv1" | ||
description = "Python library for Trend Micro Vision One" | ||
license = "Apache-2.0" | ||
readme = "README.md" | ||
dynamic = ["version"] | ||
requires-python = ">=3.7" | ||
authors = [ | ||
{ name = "Thomas Legros", email = "[email protected]" } | ||
] | ||
maintainers = [ | ||
{ name = "TrendATI", email = "[email protected]"}, | ||
] | ||
classifiers = [ | ||
"Development Status :: 2 - Pre-Alpha", | ||
"Intended Audience :: Developers", | ||
"License :: OSI Approved :: Apache Software License", | ||
"Natural Language :: English", | ||
"Operating System :: OS Independent", | ||
"Programming Language :: Python :: 3.7", | ||
"Programming Language :: Python :: 3.8", | ||
"Programming Language :: Python :: 3.9", | ||
"Programming Language :: Python :: 3.10", | ||
"Programming Language :: Python :: 3.11", | ||
"Topic :: Internet :: WWW/HTTP", | ||
"Topic :: Software Development :: Libraries", | ||
] | ||
dependencies = [ | ||
"beautifulsoup4 ~= 4.11.1", | ||
"requests ~= 2.27.1", | ||
"pydantic ~= 1.10.4", | ||
] | ||
|
||
[project.optional-dependencies] | ||
dev = [ | ||
"hatch ~= 1.6.3", | ||
"psutil ~= 5.9.4", | ||
"pytest ~= 7.2.0", | ||
"pytest-mock ~= 3.10.0", | ||
"pytest-cov ~= 4.0.0", | ||
] | ||
|
||
[project.urls] | ||
"Source" = "https://github.com/TrendATI/pytmv1" | ||
"Issues" = "https://github.com/TrendATI/pytmv1/issues" | ||
|
||
[tool.hatch.build.targets.sdist] | ||
exclude = [".github", "tests"] | ||
|
||
[tool.hatch.version] | ||
path = "src/pytmv1/__about__.py" | ||
|
||
[tool.black] | ||
target-version = ["py37"] | ||
line-length = 79 | ||
preview = true | ||
color = true | ||
|
||
[tool.isort] | ||
profile = "black" | ||
line_length = 79 | ||
color_output = true | ||
|
||
[tool.mypy] | ||
python_version = "3.7" | ||
exclude = ["dist", "tests", "venv"] | ||
show_column_numbers = true | ||
warn_unused_configs = true | ||
pretty = true | ||
strict = true | ||
|
||
[tool.pytest.ini_options] | ||
addopts = "--show-capture=log -s" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
__version__ = "0.6.2" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,186 @@ | ||
from .__about__ import __version__ | ||
from .caller import Client, client | ||
from .mapper import map_cef | ||
from .model.commons import ( | ||
Alert, | ||
Digest, | ||
EmailActivity, | ||
EmailMessage, | ||
Endpoint, | ||
EndpointActivity, | ||
Entity, | ||
Error, | ||
ExceptionObject, | ||
HostInfo, | ||
ImpactScope, | ||
Indicator, | ||
MatchedEvent, | ||
MatchedFilter, | ||
MatchedIndicatorPattern, | ||
MatchedRule, | ||
MsData, | ||
MsDataUrl, | ||
MsError, | ||
SaeAlert, | ||
SaeIndicator, | ||
SandboxSuspiciousObject, | ||
SuspiciousObject, | ||
TiAlert, | ||
TiIndicator, | ||
Value, | ||
ValueList, | ||
) | ||
from .model.enums import ( | ||
EntityType, | ||
EventID, | ||
EventSubID, | ||
IntegrityLevel, | ||
InvestigationStatus, | ||
ObjectType, | ||
OperatingSystem, | ||
ProductCode, | ||
Provenance, | ||
Provider, | ||
QueryField, | ||
QueryOp, | ||
RiskLevel, | ||
SandboxAction, | ||
SandboxObjectType, | ||
ScanAction, | ||
Severity, | ||
Status, | ||
TaskAction, | ||
) | ||
from .model.requests import ( | ||
AccountTask, | ||
EmailMessageIdTask, | ||
EmailMessageUIdTask, | ||
EndpointTask, | ||
FileTask, | ||
ObjectTask, | ||
ProcessTask, | ||
SuspiciousObjectTask, | ||
) | ||
from .model.responses import ( | ||
AccountTaskResp, | ||
AddAlertNoteResp, | ||
BaseTaskResp, | ||
BlockListTaskResp, | ||
BytesResp, | ||
CollectFileTaskResp, | ||
ConnectivityResp, | ||
ConsumeLinkableResp, | ||
EmailMessageTaskResp, | ||
EndpointTaskResp, | ||
GetAlertDetailsResp, | ||
GetAlertListResp, | ||
GetEmailActivityDataCountResp, | ||
GetEmailActivityDataResp, | ||
GetEndpointActivityDataCountResp, | ||
GetEndpointActivityDataResp, | ||
GetEndpointDataResp, | ||
GetExceptionListResp, | ||
GetSuspiciousListResp, | ||
MultiResp, | ||
MultiUrlResp, | ||
NoContentResp, | ||
SandboxAnalysisResultResp, | ||
SandboxSubmissionStatusResp, | ||
SandboxSubmitUrlTaskResp, | ||
SandboxSuspiciousListResp, | ||
SubmitFileToSandboxResp, | ||
TerminateProcessTaskResp, | ||
) | ||
from .results import MultiResult, Result, ResultCode | ||
|
||
__all__ = [ | ||
"__version__", | ||
"client", | ||
"map_cef", | ||
"AccountTask", | ||
"AccountTaskResp", | ||
"AddAlertNoteResp", | ||
"Alert", | ||
"BaseTaskResp", | ||
"BlockListTaskResp", | ||
"BytesResp", | ||
"Client", | ||
"CollectFileTaskResp", | ||
"ConnectivityResp", | ||
"ConsumeLinkableResp", | ||
"Digest", | ||
"EmailActivity", | ||
"EmailMessage", | ||
"EmailMessageIdTask", | ||
"EmailMessageTaskResp", | ||
"EmailMessageUIdTask", | ||
"Endpoint", | ||
"EndpointActivity", | ||
"EndpointTask", | ||
"EndpointTaskResp", | ||
"Entity", | ||
"EntityType", | ||
"Error", | ||
"EventID", | ||
"EventSubID", | ||
"ExceptionObject", | ||
"FileTask", | ||
"GetAlertDetailsResp", | ||
"GetAlertListResp", | ||
"GetEmailActivityDataResp", | ||
"GetEmailActivityDataCountResp", | ||
"GetEndpointActivityDataResp", | ||
"GetEndpointActivityDataCountResp", | ||
"GetEndpointDataResp", | ||
"GetExceptionListResp", | ||
"GetSuspiciousListResp", | ||
"HostInfo", | ||
"ImpactScope", | ||
"Indicator", | ||
"IntegrityLevel", | ||
"InvestigationStatus", | ||
"MatchedEvent", | ||
"MatchedFilter", | ||
"MatchedIndicatorPattern", | ||
"MatchedRule", | ||
"MsData", | ||
"MsDataUrl", | ||
"MsError", | ||
"MultiResult", | ||
"MultiResp", | ||
"MultiUrlResp", | ||
"NoContentResp", | ||
"ObjectTask", | ||
"ObjectType", | ||
"OperatingSystem", | ||
"ProcessTask", | ||
"ProductCode", | ||
"Provenance", | ||
"Provider", | ||
"QueryField", | ||
"QueryOp", | ||
"Result", | ||
"ResultCode", | ||
"RiskLevel", | ||
"SaeAlert", | ||
"SaeIndicator", | ||
"SandboxAction", | ||
"SandboxAnalysisResultResp", | ||
"SandboxObjectType", | ||
"SandboxSubmissionStatusResp", | ||
"SandboxSubmitUrlTaskResp", | ||
"SandboxSuspiciousListResp", | ||
"SandboxSuspiciousObject", | ||
"ScanAction", | ||
"Severity", | ||
"Status", | ||
"SubmitFileToSandboxResp", | ||
"SuspiciousObject", | ||
"SuspiciousObjectTask", | ||
"TaskAction", | ||
"TerminateProcessTaskResp", | ||
"TiAlert", | ||
"TiIndicator", | ||
"Value", | ||
"ValueList", | ||
] |
Oops, something went wrong.