Island: Remove jwt_required from agent-configuration resource

Can't secure the endpoint because it is used by the agent
This commit is contained in:
Ilija Lazoroski 2022-06-24 19:57:59 +02:00 committed by Mike Salvatore
parent 13a7e4ea31
commit 98a9fd3285
1 changed files with 2 additions and 3 deletions

View File

@ -6,7 +6,6 @@ from common.configuration.agent_configuration import AgentConfiguration as Agent
from common.configuration.agent_configuration import InvalidConfigurationError
from monkey_island.cc.repository import IAgentConfigurationRepository
from monkey_island.cc.resources.AbstractResource import AbstractResource
from monkey_island.cc.resources.request_authentication import jwt_required
class AgentConfiguration(AbstractResource):
@ -15,13 +14,13 @@ class AgentConfiguration(AbstractResource):
def __init__(self, agent_configuration_repository: IAgentConfigurationRepository):
self._agent_configuration_repository = agent_configuration_repository
@jwt_required
# Used by the agent. Can't secure
def get(self):
configuration = self._agent_configuration_repository.get_configuration()
configuration_json = AgentConfigurationObject.to_json(configuration)
return make_response(configuration_json, 200)
@jwt_required
# Used by the agent. Can't secure
def post(self):
try: