Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
Wazuh + VAT Evidence Collector
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
MEDINA
Public
Wazuh + VAT Evidence Collector
Commits
313a0139
Commit
313a0139
authored
3 years ago
by
Zitnik, Anze
Browse files
Options
Downloads
Patches
Plain Diff
Logging all exceptions
parent
1e714e73
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
scheduler/scheduler.py
+2
-2
2 additions, 2 deletions
scheduler/scheduler.py
wazuh_evidence_collector/wazuh_evidence_collector.py
+7
-1
7 additions, 1 deletion
wazuh_evidence_collector/wazuh_evidence_collector.py
with
9 additions
and
3 deletions
scheduler/scheduler.py
+
2
−
2
View file @
313a0139
...
...
@@ -24,8 +24,8 @@ remove_jobs(scheduler)
# TODO: Change cron expression and repeat value for production verion.
# Should probably be "0 0 * * * ".
scheduler
.
cron
(
'
* * * * *
'
,
func
=
wazuh_evidence_collector
.
run_collector
,
'
* * * * *
'
,
func
=
wazuh_evidence_collector
.
main
,
args
=
[],
repeat
=
None
,
queue_name
=
CONSTANTS
[
'
redis
'
][
'
queue
'
],
...
...
This diff is collapsed.
Click to expand it.
wazuh_evidence_collector/wazuh_evidence_collector.py
+
7
−
1
View file @
313a0139
...
...
@@ -49,6 +49,12 @@ def get_tool_id():
return
version
def
main
():
try
:
run_collector
()
except
BaseException
as
e
:
LOGGER
.
exception
(
"
Exception caught in run_collector()
"
)
# Wrapper function that runs all the checks (for every manager/agent)
def
run_collector
():
...
...
@@ -201,4 +207,4 @@ def generate_evidence(wc, es, agent):
return
create_evidence
(
get_id
(),
"
evidence_collector_service
"
,
get_tool_id
(),
raw_evidence
,
resource
)
if
__name__
==
"
__main__
"
:
run_collector
()
\ No newline at end of file
main
()
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment