Commit Graph

11273 Commits

Author SHA1 Message Date
Mike Salvatore 8ee14c4564 Island: Add LockingIslandEventQueueDecorator 2022-09-29 12:12:19 -04:00
Mike Salvatore 67c78abee1 Island: Add docstring to PyPubSubIslandEventQueue 2022-09-29 11:50:43 -04:00
Mike Salvatore 17017d6962 UT: Add missing SocketAddress tests for invalid ports 2022-09-29 11:37:54 -04:00
Mike Salvatore 64b9432bb9 UI: Capitalize "Agent" in info_box_scan_my_metworks 2022-09-29 09:21:12 -04:00
Mike Salvatore 5a0251c442
Merge pull request #2358 from guardicore/2268-modify-ping-scanner-with-agent-queue
2268 modify ping scanner with agent queue
2022-09-29 07:57:29 -04:00
Ilija Lazoroski 66e8032ef3 UT: Replace call_args comparison with assert_called_with in test_ping_scanner 2022-09-29 13:45:59 +02:00
Mike Salvatore 2ab86fa428 UT: Remove patch_get_agent_id()
1. This fixture was never actually executing
2. get_agent_id() always returns the same value (per process). This
   means that _get_ping_scan_event() and the ping scanner will receive
   the same value for any given test. In other words, mocking it is
   unnecessary.
2022-09-29 07:39:57 -04:00
Shreya Malviya 03ebdd461f UT: Check that correct events are published in test_ping_scanner.py 2022-09-29 15:34:07 +05:30
Shreya Malviya d78615fa92 UT: Add _get_ping_scan_event()to test_ping_scanner.py 2022-09-29 15:30:12 +05:30
Shreya Malviya 9f15bea5bd UT: Extract data to variables HOST_IP and TIMEOUT in test_ping_scanner.py 2022-09-29 15:27:55 +05:30
Shreya Malviya a65bbc592d UT: Check that publish is being called with expected event in test_linux_ping_success 2022-09-29 15:23:57 +05:30
Mike Salvatore 2eee427901 Agent: Generate PingScanEvent timestamp closer to ping command 2022-09-29 14:29:53 +05:30
Mike Salvatore 0cd8cd577d UT: Remove unnecessary tests from test_ping_scan_event.py
These tests are unnecessary because we will not use json() to convert to
JSON.
2022-09-29 14:29:53 +05:30
Mike Salvatore 6390993875 UT: Handle ValueError in test_construct_invalid_field__value_error() 2022-09-29 14:29:53 +05:30
Mike Salvatore d3c9691dfe UT: Add assertion to PingScanEvent serialization tests 2022-09-29 14:29:53 +05:30
Ilija Lazoroski 14f8014709 Agent: Save correct event timestamp in ping_scanner 2022-09-29 14:29:53 +05:30
Ilija Lazoroski d235e7a19e UT: Add unit tests for PingScanEvent 2022-09-29 14:29:53 +05:30
Ilija Lazoroski 478ea05fa9 Common: Override target in PingScanEvent 2022-09-29 14:29:52 +05:30
Ilija Lazoroski aa2b49bc66 Agent: Seperate the generation of PingScanEvents 2022-09-29 14:29:52 +05:30
Ilija Lazoroski 3202bfa2c1 Common: Flatten out PingScanEvent 2022-09-29 14:29:52 +05:30
Ilija Lazoroski 228ce9bae1 Agent: Publish PingScanEvent from ping_scanner 2022-09-29 14:29:52 +05:30
Ilija Lazoroski 0357d43d33 Agent: Accept IAgentEventQueue in Puppet constructor 2022-09-29 14:29:52 +05:30
Ilija Lazoroski ec56b15219 Agent: Pass IAgentEventQueue to the Puppet 2022-09-29 14:29:52 +05:30
Mike Salvatore ba0ffeacce Agent: Change method order 2022-09-29 14:29:52 +05:30
Mike Salvatore 082bb3bb6f Agent: Return a sequence from InfectionMonkey._build_server_list() 2022-09-29 14:29:52 +05:30
Mike Salvatore 5e129fd137 Agent: Use set comprehension instead of set(list()) 2022-09-29 14:29:52 +05:30
Ilija Lazoroski acf877f3d8 Common: Remove default from PingScanEvent 2022-09-29 14:29:52 +05:30
Ilija Lazoroski a44f763fab Common: Remove default from AbstractAgentEvent source field 2022-09-29 14:29:52 +05:30
Ilija Lazoroski 9ada95c126 Agent: Return set when building server list 2022-09-29 14:29:52 +05:30
Ilija Lazoroski 799aae4498 Common: Add default to PingScanEvent 2022-09-29 14:29:52 +05:30
Ilija Lazoroski b1b9eb394e Common: Add default to source in AbstractAgentEvent 2022-09-29 14:29:52 +05:30
Ilija Lazoroski 89397d8cbd Agent: Rename event_queue to agent_event_queue 2022-09-29 14:29:52 +05:30
Mike Salvatore 56ead43c11 Changelog: Add entry for #2299 2022-09-28 15:43:07 -04:00
Mike Salvatore 83f0ebfda4
Merge pull request #2356 from guardicore/2299-local-network-scan-ui-tooltip
Info box in UI for Scan Agent's networks
2022-09-28 15:41:09 -04:00
Mike Salvatore e8449817ad Island: Reword Scan Agent's networks tool tip wording 2022-09-28 15:38:05 -04:00
Mike Salvatore 1b4f72e5e3
Merge pull request #2364 from guardicore/2274-agent-logs-endpoint
Use new agent logs endpoint
2022-09-28 15:28:40 -04:00
Mike Salvatore ff8c8bd0a0 Agent: Use PUT instead of POST to send agent logs 2022-09-28 15:24:46 -04:00
Kekoa Kaaikala ab919f6d57 UI: Use colors from existing warning theme 2022-09-28 19:21:09 +00:00
Mike Salvatore 87d25d2ac8 Agent: Remove disused send_log() from ControlClient 2022-09-28 15:15:32 -04:00
Mike Salvatore fab67d893f Agent: Call IIslandAPIClient.send_log() directly
ControlClient is going away. It's been replaced by IIslandAPIClient.
Now is a good time to remove ControlClient.send_log()
2022-09-28 15:11:42 -04:00
Mike Salvatore a1516535f9 Agent: Add InfectionMonkey._agent_id attribute 2022-09-28 15:08:59 -04:00
Shreya Malviya 21f01292f7 Agent: Fix type hint in IIslandAPIClient.send_log() 2022-09-28 15:03:32 -04:00
Shreya Malviya 8dc8a516d5 Agent: Fix type hint in HTTPIslandAPIClient.send_log() 2022-09-28 15:03:32 -04:00
Shreya Malviya 29c08ff40c Agent: Simplify logic for sending logs in ControlClient 2022-09-28 15:03:32 -04:00
Shreya Malviya 8e3918cebe UT: Fix island_api_client.send_log() calls in test_http_island_api_client.py 2022-09-28 15:03:32 -04:00
Shreya Malviya 539f4e1c82 Agent: Fix self._island_api_client.send_log() call in ControlClient 2022-09-28 15:03:32 -04:00
Shreya Malviya 74e30a2f88 Agent: Update API endpoint in HTTPIslandAPIClient.send_log() 2022-09-28 15:03:32 -04:00
Shreya Malviya a9e1b99f2f Agent: Add agent_id parameter to IIslandAPIClient.send_log() 2022-09-28 15:03:32 -04:00
Mike Salvatore 4f3fd6987e Merge branch '2274-implement-new-agent-logs-endpoint' into develop
PR #2365
2022-09-28 14:19:21 -04:00
Kekoa Kaaikala 2f7f4fef9c UI: Fix warning icon spacing 2022-09-28 18:18:35 +00:00