Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion netsecgame/agents/base_agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ def request_game_reset(

if __name__ == "__main__":
# Example usage of BaseAgent
GAME_PORT = 5000 # Change to the appropriate port
GAME_PORT = 9000 # Change to the appropriate port
agent = BaseAgent("localhost", GAME_PORT, AgentRole.Attacker)
# Register the agent
observation = agent.register()
Expand Down
2 changes: 2 additions & 0 deletions netsecgame/game/worlds/NetSecGame.py
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,8 @@ def _create_state_from_view(self, view:dict, add_neighboring_nets:bool=True)->Ga
# Add all controlled hosts to known_hosts
known_hosts = known_hosts.union(controlled_hosts)
if add_neighboring_nets:
self.logger.info("Adding neighboring networks to the state.")
self.logger.warning("Using 'add_neighboring_nets=True' is deprecated and will be removed in future.")
# Extend the known networks with the neighbouring networks
# This is to solve in the env (and not in the agent) the problem
# of not knowing other networks appart from the one the agent is in
Expand Down
Loading