Mike Salvatore
8788b258dd
Docs: Change "launch" to "starts"
2022-08-12 10:29:42 -04:00
Mike Salvatore
658607de25
UT: Remove unnecessary wait() from test_version
...
Unit tests should not be exposed to the internals of what they are
testing. Furthermore, the `latest_version` and `download` properties
wait for the event to be set, making the extra `wait()` redundant.
2022-08-12 10:27:53 -04:00
Mike Salvatore
94a25b07b2
Island: Simplify error messages in Version
2022-08-12 10:24:29 -04:00
Mike Salvatore
df1b9f0f9c
Island: Fix return type hint for Version._get_version_info()
2022-08-12 10:22:22 -04:00
Mike Salvatore
617d101af2
Island: Fix string formatting in _send_analytics()
2022-08-12 10:20:30 -04:00
Mike Salvatore
6dc29e36e2
UT: Fix test_version__request_failed()
2022-08-12 10:16:46 -04:00
Mike Salvatore
2e70b87ee9
Revert "Island, UI: Handle the case when version couldn't be fetched"
...
This reverts commit 737070f956
.
2022-08-12 10:15:44 -04:00
Mike Salvatore
dc0f865f9b
Merge pull request #2192 from guardicore/2176-initialize-event-queue
...
Initialize IEventQueue
2022-08-12 10:14:20 -04:00
Mike Salvatore
23b96c2a36
Agent: Convert _event_queue from member to local variable
2022-08-12 10:13:36 -04:00
Ilija Lazoroski
21c9ea9d44
Agent: Initialize IEventQueue
2022-08-12 15:31:55 +02:00
Mike Salvatore
74ca26657e
Merge pull request #2189 from guardicore/2176-define-stolen-credentials-event
...
2176 define stolen credentials event
2022-08-12 06:48:16 -04:00
Mike Salvatore
b0b0874be9
Common: Modify stolen_credentials description in docstring
2022-08-12 06:47:08 -04:00
Ilija Lazoroski
743d40abab
Common: Rename StolenCredentialsEvent to CredentialsStolenEvent
2022-08-12 09:39:04 +02:00
vakarisz
737070f956
Island, UI: Handle the case when version couldn't be fetched
2022-08-12 09:50:28 +03:00
vakarisz
c61737abc0
Island: Send analytics on island startup instead of object creation
...
This change makes the logic more evident, because sending the analytics is not done during the initialization of an object
2022-08-12 09:32:50 +03:00
Ilija Lazoroski
f06d53368a
Common: Export StolenCredentialsEvent from __init__
2022-08-11 19:36:58 +02:00
Ilija Lazoroski
889863bb93
Common: Define StolenCredentialsEvent
2022-08-11 19:36:52 +02:00
vakarisz
bec7bef1b3
Island: Return current version number instead of None
2022-08-11 17:57:07 +03:00
vakarisz
5ffec0eb4f
Changelog: Add entry about separating version and analytics requests
2022-08-11 17:45:09 +03:00
vakarisz
248cef589a
Docs: Change performed queried documentation in the FAQ
...
Island now performs 2 queries instead of 1(1 for analytics and 1 for update information)
2022-08-11 17:45:08 +03:00
ilija-lazoroski
956621dcf3
Island: Add events endpoint
...
PR #2187
Issue #2155
2022-08-11 10:23:54 -04:00
vakarisz
32460bbb3e
Island: Send analytics upon island startup
2022-08-11 17:20:56 +03:00
Kekoa Kaaikala
5558d075be
Agent: Fix credential repository import
...
Fix a failed import that prevented the agent from running.
Resolves PR #2186
2022-08-11 09:14:22 -04:00
Mike Salvatore
5c7b2d713b
Merge pull request #2185 from guardicore/2141-gcp-machines-to-bb-tests
...
BB: Gather enabled tests and select GCP machines needed for the speci…
2022-08-11 08:26:49 -04:00
vakarisz
02e719f7b2
Island: Fetch version and download url from new lambda API
2022-08-11 15:14:54 +03:00
Mike Salvatore
016048abca
Merge pull request #2184 from guardicore/2146-replace-guardicore-links
2022-08-11 07:14:09 -04:00
Mike Salvatore
52ca082e87
Project: Update job post in README.md
2022-08-11 07:03:19 -04:00
Mike Salvatore
ae82578ae0
BB: Rename list_machines -> gcp_machines_to_start
2022-08-10 14:23:16 -04:00
Mike Salvatore
ea81226c2a
BB: Simplify list_machines()
2022-08-10 14:18:23 -04:00
Mike Salvatore
21f9b5ad53
Merge pull request #2182 from guardicore/2156-implement-event-queue
...
Implement EventQueue
2022-08-10 13:22:43 -04:00
Mike Salvatore
dcc2717ac8
Common: Fix typo specifed -> specified
2022-08-10 12:47:47 -04:00
Mike Salvatore
b1c77b7be8
Common: Fix typo well -> will
2022-08-10 12:47:47 -04:00
Mike Salvatore
8a02305277
Common: Export PyPubSubEventQueue from common.event_queue
2022-08-10 12:47:47 -04:00
Mike Salvatore
4243f9f3ea
Common: Export IEventQueue from common.event_queue
2022-08-10 12:47:47 -04:00
Mike Salvatore
2bbe56035d
UT: Use UUID for source in test_pypubsub_event_queue.py
2022-08-10 12:47:47 -04:00
Mike Salvatore
ac69e7d25b
UT: Use frozenset() for tags in test_pypubsub_event_queue.py
2022-08-10 12:47:47 -04:00
Mike Salvatore
e36fb9af73
UT: Add type hints to test_pypubsub_event_queue.py
2022-08-10 12:47:47 -04:00
Mike Salvatore
35155c345f
Common: Use EventSubscriber for IEventQueue type hints
2022-08-10 12:36:59 -04:00
Mike Salvatore
97a612be2d
Common: Add EventSubscriber type
2022-08-10 12:34:06 -04:00
Mike Salvatore
83e09ca957
Common: Fix type hint for IEventQueue.subscribe_type()
2022-08-10 11:35:55 -04:00
Mike Salvatore
d151ce12fd
Common: Rename _INTERNAL_ALL_EVENT_TYPES_TOPIC -> _ALL_EVENTS_TOPIC
2022-08-10 11:34:48 -04:00
Ilija Lazoroski
736e779f4c
BB: Gather enabled tests and select GCP machines needed for the specific tests
2022-08-10 17:32:39 +02:00
Mike Salvatore
a6c24af622
Common: Prevent topic collision between types and tags
...
If an event tag happened to be the same as an event type, subscribers
could receive event types that they were not prepared to handle,
resulting in difficult-to-diagnose bugs. Prevent tags and types from
being sent to the wrong subscribers by appending unique strings to the
topics.
2022-08-10 11:32:09 -04:00
Mike Salvatore
3384c049a4
UT: Use new Publisher for each test instead of default `pub`
...
Using the default publisher provided by pypubsub causes state to be
carried over between tests. Unit tests should not depend on eachother or
the order in which they're run.
2022-08-10 11:10:22 -04:00
Mike Salvatore
68dafbfb9d
UT: Add event_queue() fixture
2022-08-10 11:09:51 -04:00
Mike Salvatore
2bdc16c286
UT: Refactor test_pypubsub_event_queue.py
2022-08-10 11:07:36 -04:00
Mike Salvatore
d6bb56536d
UT: Test with instances of AbstractEvent, not classes
2022-08-10 09:37:10 -04:00
Mike Salvatore
4da0cefa7d
Common: Publish message to event's class name
2022-08-10 09:34:09 -04:00
Mike Salvatore
a461226fec
Common: Fix type hint for PyPubSubEventQueue.subscribe_type()
2022-08-10 09:21:54 -04:00
Mike Salvatore
c0a9a8cf4d
Common: Rename _publish_to_tags_topic{,s}()
2022-08-10 09:18:25 -04:00