Commit Graph

4957 Commits

Author SHA1 Message Date
Mike Salvatore b8d4452e70 island: Rename RunLocalMonkeyService -> LocalMonkeyRunService 2021-05-12 12:09:46 -04:00
Mike Salvatore 79eb7442ae island: Move the specifics of saving pba files to pba service 2021-05-12 11:53:10 -04:00
Mike Salvatore 253588b3ac island: Move PBA filename paths to config_value_paths.py 2021-05-12 11:53:07 -04:00
Mike Salvatore 2485c85d59 island: Don't use `shell=True` when running local monkey 2021-05-12 08:42:12 -04:00
Mike Salvatore f86bc7f943 island: Move run_local_monkey() to its own service 2021-05-12 08:35:46 -04:00
Mike Salvatore db14285934 island: Add `dir_is_empty()` to clarify intent of `test_remove_pba_files()` 2021-05-12 08:10:01 -04:00
Mike Salvatore e3449d17c7 Remove file that was accidentally added 2021-05-12 08:07:04 -04:00
Mike Salvatore 9476441526 island: Remove circular dep btw ConfigService and PostBreachFilesService 2021-05-11 14:40:53 -04:00
Mike Salvatore ea82e86df5 island: Add tests for PostBreachFilesService 2021-05-11 14:40:53 -04:00
Mike Salvatore 4364a48561 island: Simplify remove_PBA_files() 2021-05-11 14:40:53 -04:00
Mike Salvatore 5742e85ff5 island: Consolidate duplicate delete post breach file functionality 2021-05-11 14:40:53 -04:00
Mike Salvatore 71029cb7f9 island: Decouple FileUpload resource from environment_singleton 2021-05-11 14:40:53 -04:00
Mike Salvatore ca65330e86 island: Create custom PBA directory on PostBreachFilesService init 2021-05-11 14:40:53 -04:00
Mike Salvatore be0f7ac881 island: Decouple PBAFileDownload from environment_singleton 2021-05-11 14:40:53 -04:00
Mike Salvatore 4190797ca2 island: Add PostBreachFilesService.get_custom_pba_directory() 2021-05-11 14:40:53 -04:00
Mike Salvatore ee19eed596 island: Decouple PostBreachFilesService from environment_singleton 2021-05-11 14:40:53 -04:00
Mike Salvatore a7f2e023b8 island: Wrap services/post_breach_files.py functions in a static class 2021-05-11 14:40:53 -04:00
Mike Salvatore ba86ba0395 island: Decouple Database service from services.post_breach_files
Since Database.reset_db() calls ConfigService.init_config() which calls
ConfigService.reset_config() which calls
services.post_breach_files.remove_PBA_files(), it is redundant to call
remove_PBA_files() from Database.reset_db(). Removing this call has the
added benefit of reducing the coupling between the Database service and
services.post_breach_files
2021-05-11 14:40:53 -04:00
Mike Salvatore f048cf313c island: Pass data_dir to LocalRun instead of using global singleton 2021-05-11 14:40:53 -04:00
Mike Salvatore 0b21dac261 Merge branch 'untangle-logger-config' into develop 2021-05-11 14:40:39 -04:00
Mike Salvatore b13839d7ba island: Add debug log level to server_config.json.develop 2021-05-11 14:01:43 -04:00
Mike Salvatore 08668f3eae island: Handle lower case log levels in server config 2021-05-11 13:40:58 -04:00
Mike Salvatore 5ea241f120 island: Simplify logic in add_default_values_to_config() 2021-05-11 13:29:53 -04:00
Mike Salvatore de7865aa21 island: Add tests for default server config values 2021-05-11 13:25:22 -04:00
Mike Salvatore 990244c3ac island: Return config dict from load_server_config()
As the number of configuration items will increase in the future, return
the config dict instead of individual config properties.
2021-05-11 13:18:24 -04:00
Mike Salvatore 5847674d92 island: Add unit test for load_server_config() 2021-05-11 13:14:07 -04:00
Mike Salvatore f7bef76f39 island: Move load_server_config() to config_loader.py
Because `monkey_island.py` has the same name as the `monkey_island`
module, pytest can't import monkey_island.py and run any tests against
its code.
2021-05-11 13:00:44 -04:00
VakarisZ d385778828 Documented why windows and osx doesn't support docker deployment options. 2021-05-11 11:35:35 -04:00
Shreya 83a235bb5d Rename unit test functions in test_island_logger.py 2021-05-11 19:08:28 +05:30
Shreya 5f8145e3d1 Add tests for console logging (test_island_logger.py) 2021-05-11 19:06:38 +05:30
Shreya c5ba48db53 Modify/add unit tests (test_island_logger.py) 2021-05-11 18:57:24 +05:30
Mike Salvatore a30d586c3d
Merge pull request #1152 from guardicore/speed-up-travis-build
Speed up travis build
2021-05-11 09:04:02 -04:00
Shreya e8c1c81edf Move `DEFAULT_LOG_LEVEL` and add function `load_server_config` to monkey_island.py 2021-05-11 18:16:45 +05:30
Shreya 3c7687a405 Catch and print errors instead of creating a default server config 2021-05-11 18:08:07 +05:30
Shreya 805ab989b9 Remove "__author__" field 2021-05-11 17:58:07 +05:30
Shreya 8dc84ee0f7 Assume configured data directory exists when configuring the logger 2021-05-11 17:56:49 +05:30
Mike Salvatore b5c9828ddc island: Remove errant space in manual run windows command
Fixes #1153
2021-05-10 11:52:31 -04:00
Mike Salvatore c17ccb05f0 travis: cache pipenv 2021-05-10 10:39:15 -04:00
Mike Salvatore f25cfe277d travis: Install hugo binary from github
It currently takes 4 minutes to install hugo with homebrew. Using a
faster way to install hugo could speed up the Travis CI build by as much
as 42%.
2021-05-10 10:08:43 -04:00
Shreya 0556465c6a Update CHANGELOG.md (removed island logger config) 2021-05-10 16:47:30 +05:30
Shreya 6d04e7cbb4 Fix unit tests and modify code based on failed tests (tests/monkey_island/cc/server_utils/test_island_logger.py) 2021-05-10 14:52:07 +05:30
Shreya f84e4aed2c Set log filename in config before expanding its paths 2021-05-10 14:04:07 +05:30
Shreya 785f2ef77d Replace `json_setup_logging()` with `setup_logging()` to configure logger 2021-05-10 13:49:33 +05:30
Shreya ab89590389 Remove `--logger-config` command-line argument, add "log_level" to server_config.json 2021-05-10 13:05:06 +05:30
Shreya 5bcd9176fc Remove `island_logger_config.json\' 2021-05-10 12:23:50 +05:30
Mike Salvatore aa959c3879 Merge branch 'vulture' into develop 2021-05-07 08:12:54 -04:00
Mike Salvatore 69af8a8662 island: Remove MongoClient() call from BootloaderHttpServer 2021-05-07 08:12:09 -04:00
Mike Salvatore 5b75dc524a zoo: Send password (not hash) to authenticate with Island
This step was missed in merge e609094a.
2021-05-06 21:39:50 -04:00
Mike Salvatore e8947a375a Add a whitelist for vulture 2021-05-06 19:51:23 -04:00
Shreya e1ef807c2c Remove unused import in infection_monkey/network/info.py 2021-05-06 22:42:28 +05:30