Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/SafeBreach-Labs/CloudMiner
/ functions
Functions
32 in github.com/SafeBreach-Labs/CloudMiner
⨍
Functions
32
◇
Types & classes
7
↓ 7 callers
Method
__http_request
Safe HTTP request to Azure services :param http_method: HTTP method of the request :param url: URL of the reques
src/cloudminer/azure_automation_session.py:86
↓ 5 callers
Method
__get_url
Construct a url for the given path in the Automation Account
src/cloudminer/azure_automation_session.py:67
↓ 4 callers
Method
add_indent
(self)
src/cloudminer/logger.py:29
↓ 4 callers
Method
remove_indent
(self)
src/cloudminer/logger.py:32
↓ 2 callers
Method
__upload_file_to_temp_storage
Create a temp storage and upload a file :param file_path: File path to upload :return: Temp storage url
src/cloudminer/azure_automation_session.py:134
↓ 2 callers
Method
get_python_package
Retrieve a Python package. Return None if does not exist
src/cloudminer/azure_automation_session.py:193
↓ 2 callers
Method
upload_python_package
Upload a Python package from a given blob storage
src/cloudminer/azure_automation_session.py:175
↓ 1 callers
Method
__init__
:param automation_session: Automation account session to use :param script_path: Script to execute within Automation Account
src/cloudminer/scripts_executor.py:18
↓ 1 callers
Method
__wait_for_next_request
Helper function to make sure we wait before each request
src/cloudminer/azure_automation_session.py:75
↓ 1 callers
Method
_create_whl_for_upload
Creates a Python package whl using the given Python script :raises CloudMinerException: If failed to create .whl file
src/cloudminer/scripts_executor.py:144
↓ 1 callers
Method
_delete_pip_if_exists
Validate 'pip' package does not exist :param delete_if_exists: If True and package exists, deletes the package :raises Clou
src/cloudminer/scripts_executor.py:76
↓ 1 callers
Method
_wait_for_package_upload
Wait until the package upload flow is finished or until timeout (Blocking) :param package_name: Python package name to wait for
src/cloudminer/scripts_executor.py:89
↓ 1 callers
Method
_wrap_script
Construct lines of code for installing Python packages
src/cloudminer/scripts_executor.py:122
↓ 1 callers
Method
delete_python_package
Delete a Python package :raises CloudMinerException: If the given package does not exists
src/cloudminer/azure_automation_session.py:208
↓ 1 callers
Method
execute_script
Executes Python script within Azure Automation :param script_path: .whl file path. Get using 'prepare_file_for_upload' :para
src/cloudminer/scripts_executor.py:164
↓ 1 callers
Function
get_access_token_from_cli
Retrieve Azure access token using Azure CLI :raises CloudMinerException: If Azure CLI is not installed or not in PATH environment variable
src/cloudminer/cloud_miner.py:13
↓ 1 callers
Function
get_file_name
Returns the file name from full file path
src/cloudminer/utils.py:41
↓ 1 callers
Function
get_temp_file_path
Returns the user temp directory
src/cloudminer/utils.py:26
↓ 1 callers
Function
init_logging
()
src/cloudminer/logger.py:36
↓ 1 callers
Function
main
()
src/cloudminer/cloud_miner.py:52
↓ 1 callers
Function
parse_args
Parse command line arguments
src/cloudminer/cloud_miner.py:38
↓ 1 callers
Function
run_command
Helper function to run commands
src/cloudminer/utils.py:72
↓ 1 callers
Method
upload_powershell_module
Upload a Powershell module to the Automation Account
src/cloudminer/azure_automation_session.py:158
Method
__init__
Initiate an Azure Automation session Validates that the Automation Account exists and the access token is valid :param accou
src/cloudminer/azure_automation_session.py:40
Method
__init__
(self, name: str, level: int = 0)
src/cloudminer/logger.py:10
Method
__init__
:param automation_session: Automation account session to use :param script_path: Script to execute within Automation Account
src/cloudminer/scripts_executor.py:67
Method
_log
(self, level, msg, *args, **kwargs)
src/cloudminer/logger.py:14
Method
execute_script
Executes a script within Azure Automation :param count: Number of executions
src/cloudminer/scripts_executor.py:28
Method
execute_script
Executes Powershell module within Azure Automation :param count: Number of executions
src/cloudminer/scripts_executor.py:41
Function
get_file_extension
Returns the file extension from file path
src/cloudminer/utils.py:34
Function
package_to_whl
Create a whl file from a given Python package whl file wil lbe saved in the dist directory :raises CloudMinerException: If failed to
src/cloudminer/utils.py:85
Function
zip_file
Zip a file :param source_file: File path to zip :param file_name_within_archive: Name of file within the zip archive :param zip_path
src/cloudminer/utils.py:48