From 01d8875f22a18a533593b1f640d6c07241fcbd38 Mon Sep 17 00:00:00 2001 From: Shreya Malviya Date: Wed, 28 Sep 2022 15:42:07 +0530 Subject: [PATCH] Island: Register FileAgentLogRegister in DI container --- monkey/monkey_island/cc/services/initialize.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/monkey/monkey_island/cc/services/initialize.py b/monkey/monkey_island/cc/services/initialize.py index c0dc600c3..1cd020fd8 100644 --- a/monkey/monkey_island/cc/services/initialize.py +++ b/monkey/monkey_island/cc/services/initialize.py @@ -21,6 +21,7 @@ from monkey_island.cc.event_queue import IIslandEventQueue, PyPubSubIslandEventQ from monkey_island.cc.repository import ( AgentBinaryRepository, FileAgentConfigurationRepository, + FileAgentLogRepository, FileRepositoryCachingDecorator, FileRepositoryLockingDecorator, FileRepositoryLoggingDecorator, @@ -28,6 +29,7 @@ from monkey_island.cc.repository import ( IAgentBinaryRepository, IAgentConfigurationRepository, IAgentEventRepository, + IAgentLogRepository, IAgentRepository, ICredentialsRepository, IFileRepository, @@ -117,6 +119,7 @@ def _register_repositories(container: DIContainer, data_dir: Path): container.register_instance(INodeRepository, container.resolve(MongoNodeRepository)) container.register_instance(IMachineRepository, _build_machine_repository(container)) container.register_instance(IAgentRepository, container.resolve(MongoAgentRepository)) + container.register_instance(IAgentLogRepository, container.resolve(FileAgentLogRepository)) def _decorate_file_repository(file_repository: IFileRepository) -> IFileRepository: