Nothing Special   »   [go: up one dir, main page]

Skip to content

dfederschmidt/azuread

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Azure AD Graph

Publisher: Splunk
Connector Version: 2.3.1
Product Vendor: Microsoft
Product Name: Azure AD Graph
Product Version Supported (regex): ".*"
Minimum Product Version: 5.3.0

Connects to Azure AD Graph REST API services

Authentication

This app requires creating a Microsoft Azure Application. To do so, navigate to https://portal.azure.com in a browser and log in with a Microsoft account, then select Azure Active Directory .

  1. Go to App Registrations and click on + New registration .
  2. Give the app an appropriate name. The Redirect URI will be populated in a later step.
  3. Select a supported account type (configure the application to be multitenant).
  4. Click on the Register .
    • Under Certificates & secrets , add New client secret . Note this key somewhere secure, as it cannot be retrieved after closing the window.
    • Under Redirect URIs we will be updating the entry of https://phantom.local to reflect the actual redirect URI. We will get this from the Phantom asset we create below in the section titled "Configure the Azure AD Graph Phantom app Asset"
    • Under API Permissions , click on Add a permission .
    • Go to Microsoft Graph Permissions , the following Delegated Permissions need to be added:
      • User.Read
      • User.Read.All
      • Directory.ReadWrite.All
      • Directory.AccessAsUser.All
    • Click on the Add permissions .

Note* You must ensure that the Azure Active Directory user account that will be used during the interactive authentication (described in "Method to Run Test Connectivity below) has a permanently assigned role that has sufficient permissions as Azure provides the option to revoke roles assigned to user accounts automatically at a given frequency. After making these changes, click on Grant admin consent .

Configure the Azure AD Graph Phantom app Asset

When creating an asset for the Azure AD Graph app, place the Application ID of the app created during the previous step in the Client ID field and place the password generated during the app creation process in the Client Secret field. Then, after filling out the Tenant field, click SAVE .

After saving, a new field will appear in the Asset Settings tab. Take the URL found in the POST incoming for Azure AD Graph to this location field and place it in the Redirect URIs field mentioned in a previous step. To this URL, add /result . After doing so the URL should look something like:

https://<phantom_host>/rest/handler/azureadgraph_c6d3b801-5c26-4abd-9e89-6d8007e2778f/<asset_name>/result

Once again, click on Save.

User Permissions

To complete the authorization process, this app needs permission to view assets, which is not granted by default. First, under asset settings , check which user is listed under Select a user on behalf of which automated actions can be executed . By default, the user will be automation , but this user can be changed by clicking EDIT at the bottom of the window. To give this user permission to view assets, follow these steps:

  • In the main drop-down menu, select Administration , then select the User Management , and under that tab, select Roles . Finally, click + ROLE .
  • In the Add Role wizard, give the role a name (e.g Asset Viewer ), and provide a description. Subsequently, under Available Users , add the user assigned to the asset viewed earlier. Then click the Permissions tab.
  • On the permission tab, under Available Privileges , give the role the View Assets privilege. Then click SAVE .

Method to Run Test Connectivity

After setting up the asset and user, click the TEST CONNECTIVITY button. A window should pop up and display a URL. Navigate to this URL in a separate browser tab. This new tab will redirect to a Microsoft login page. Log in to a Microsoft account with administrator privileges to the Azure AD environment. After logging in, review the requested permissions listed, then click Accept . Finally, close that tab. The test connectivity window should show a success.

The app should now be ready to use.

State File Permissions

Please check the permissions for the state file as mentioned below.

State Filepath

  • For Non-NRI Instance: /opt/phantom/local_data/app_states/c6d3b801-5c26-4abd-9e89-6d8007e2778f/{asset_id}_state.json
  • For NRI Instance: /<PHANTOM_HOME_DIRECTORY>/local_data/app_states/c6d3b801-5c26-4abd-9e89-6d8007e2778f/{asset_id}_state.json

State File Permissions

  • File Rights: rw-rw-r-- (664) (The phantom user should have read and write access for the state file)
  • File Owner: appropriate phantom user

Port Information

The app uses HTTP/ HTTPS protocol for communicating with the Azure AD server. Below are the default ports used by Splunk SOAR.

        Service Name Transport Protocol Port
        http tcp 80
        https tcp 443

Configuration Variables

The below configuration variables are required for this Connector to operate. These variables are specified when configuring a Azure AD Graph asset in SOAR.

VARIABLE REQUIRED TYPE DESCRIPTION
tenant_id required string Tenant (Tenant ID or Tenant Name)
client_id required string Application ID
client_secret required password Client Secret
region optional string Azure AD Region

Supported Actions

test connectivity - Use supplied credentials to generate a token with MS Graph
list users - List users in a tenant
reset password - Reset or set a user's password in an Azure AD environment
disable tokens - Invalidate all active refresh tokens for a user in an Azure AD environment
enable user - Enable a user
disable user - Disable a user
list user attributes - List attributes for all or a specified user
set user attribute - Set an attribute for a user
remove user - Remove a user from a specified group
add user - Add a user to the tenant by creating an organizational account
list groups - List groups in the organization
get group - Get information about a group
list group members - List the members in a group
validate group - Returns true if a user is in a group; otherwise, false
list directory roles - List the directory roles in a tenant
generate token - Generate a token or regenerates token when the token expires

action: 'test connectivity'

Use supplied credentials to generate a token with MS Graph

Type: test
Read only: True

Action Parameters

No parameters are required for this action

Action Output

No Output

action: 'list users'

List users in a tenant

Type: investigate
Read only: True

For more information on using the filter_string parameter, refer to https://docs.microsoft.com/en-us/previous-versions/azure/ad/graph/howto/azure-ad-graph-api-supported-queries-filters-and-paging-options.

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
filter_string optional Filter string to apply to user listing string

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.filter_string string
action_result.data.*.accountEnabled boolean
action_result.data.*.ageGroup string
action_result.data.*.assignedLicenses.*.skuId string
action_result.data.*.assignedPlans.*.assignedTimestamp string
action_result.data.*.assignedPlans.*.capabilityStatus string
action_result.data.*.assignedPlans.*.service string
action_result.data.*.assignedPlans.*.servicePlanId string
action_result.data.*.city string
action_result.data.*.companyName string
action_result.data.*.consentProvidedForMinor string
action_result.data.*.country string
action_result.data.*.createdDateTime string
action_result.data.*.creationType string
action_result.data.*.deletionTimestamp string
action_result.data.*.department string
action_result.data.*.dirSyncEnabled string
action_result.data.*.displayName string
action_result.data.*.employeeId string
action_result.data.*.facsimileTelephoneNumber string
action_result.data.*.givenName string
action_result.data.*.immutableId string
action_result.data.*.isCompromised string
action_result.data.*.jobTitle string
action_result.data.*.lastDirSyncTime string
action_result.data.*.legalAgeGroupClassification string
action_result.data.*.mail string email
action_result.data.*.mailNickname string
action_result.data.*.mobile string
action_result.data.*.objectId string azure object id
action_result.data.*.objectType string
action_result.data.*.odata.type string
action_result.data.*.onPremisesDistinguishedName string
action_result.data.*.onPremisesSecurityIdentifier string
action_result.data.*.otherMails string email
action_result.data.*.passwordPolicies string
action_result.data.*.passwordProfile string
action_result.data.*.passwordProfile.enforceChangePasswordPolicy boolean
action_result.data.*.passwordProfile.forceChangePasswordNextLogin boolean
action_result.data.*.passwordProfile.password string
action_result.data.*.physicalDeliveryOfficeName string
action_result.data.*.postalCode string
action_result.data.*.preferredLanguage string
action_result.data.*.provisionedPlans.*.capabilityStatus string
action_result.data.*.provisionedPlans.*.provisioningStatus string
action_result.data.*.provisionedPlans.*.service string
action_result.data.*.proxyAddresses string
action_result.data.*.refreshTokensValidFromDateTime string
action_result.data.*.showInAddressList string
action_result.data.*.sipProxyAddress string email
action_result.data.*.state string
action_result.data.*.streetAddress string
action_result.data.*.surname string
action_result.data.*.telephoneNumber string
action_result.data.*.thumbnailPhoto@odata.mediaEditLink string
action_result.data.*.usageLocation string
action_result.data.*.userPrincipalName string email azure user principal name
action_result.data.*.userState string
action_result.data.*.userStateChangedOn string
action_result.data.*.userType string
action_result.summary.num_users numeric
action_result.summary.result_found boolean
action_result.summary.total_results numeric
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'reset password'

Reset or set a user's password in an Azure AD environment

Type: contain
Read only: False

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
user_id required User ID to change password - can be user principal name or object ID string azure user principal name azure object id email
force_change optional Force user to change password on next login boolean
temp_password required Temporary password for user string

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.force_change boolean
action_result.parameter.temp_password string
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data string
action_result.summary.status string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'disable tokens'

Invalidate all active refresh tokens for a user in an Azure AD environment

Type: contain
Read only: False

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
user_id required User ID to disable tokens of - can be user principal name or object ID string azure user principal name azure object id email

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data string
action_result.data.*.odata.metadata string url
action_result.data.*.odata.null boolean
action_result.data.*.value boolean
action_result.summary.status string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'enable user'

Enable a user

Type: generic
Read only: False

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
user_id required User ID to enable tokens of - can be user principal name or object ID string azure user principal name azure object id email

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data string
action_result.summary.status string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'disable user'

Disable a user

Type: generic
Read only: False

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
user_id required User ID to change password - can be user principal name or object ID string azure user principal name azure object id email

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data string
action_result.summary.status string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'list user attributes'

List attributes for all or a specified user

Type: investigate
Read only: True

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
user_id optional User ID - can be user principal name or object ID string azure user principal name azure object id email

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data.*.accountEnabled boolean
action_result.data.*.ageGroup string
action_result.data.*.assignedLicenses.*.skuId string
action_result.data.*.assignedPlans.*.assignedTimestamp string
action_result.data.*.assignedPlans.*.capabilityStatus string
action_result.data.*.assignedPlans.*.service string
action_result.data.*.assignedPlans.*.servicePlanId string
action_result.data.*.city string
action_result.data.*.companyName string
action_result.data.*.consentProvidedForMinor string
action_result.data.*.country string
action_result.data.*.createdDateTime string
action_result.data.*.creationType string
action_result.data.*.deletionTimestamp string
action_result.data.*.department string
action_result.data.*.dirSyncEnabled string
action_result.data.*.displayName string
action_result.data.*.employeeId string
action_result.data.*.facsimileTelephoneNumber string
action_result.data.*.givenName string
action_result.data.*.immutableId string
action_result.data.*.isCompromised string
action_result.data.*.jobTitle string
action_result.data.*.lastDirSyncTime string
action_result.data.*.legalAgeGroupClassification string
action_result.data.*.mail string email
action_result.data.*.mailNickname string
action_result.data.*.mobile string
action_result.data.*.objectId string
action_result.data.*.objectType string
action_result.data.*.odata.metadata string
action_result.data.*.odata.type string
action_result.data.*.onPremisesDistinguishedName string
action_result.data.*.onPremisesSecurityIdentifier string
action_result.data.*.otherMails string email
action_result.data.*.passwordPolicies string
action_result.data.*.passwordProfile string
action_result.data.*.passwordProfile.enforceChangePasswordPolicy boolean
action_result.data.*.passwordProfile.forceChangePasswordNextLogin boolean
action_result.data.*.passwordProfile.password string
action_result.data.*.physicalDeliveryOfficeName string
action_result.data.*.postalCode string
action_result.data.*.preferredLanguage string
action_result.data.*.provisionedPlans.*.capabilityStatus string
action_result.data.*.provisionedPlans.*.provisioningStatus string
action_result.data.*.provisionedPlans.*.service string
action_result.data.*.proxyAddresses string
action_result.data.*.refreshTokensValidFromDateTime string
action_result.data.*.showInAddressList string
action_result.data.*.sipProxyAddress string email
action_result.data.*.state string
action_result.data.*.streetAddress string
action_result.data.*.surname string
action_result.data.*.telephoneNumber string
action_result.data.*.thumbnailPhoto@odata.mediaEditLink string
action_result.data.*.usageLocation string
action_result.data.*.userPrincipalName string email
action_result.data.*.userState string
action_result.data.*.userStateChangedOn string
action_result.data.*.userType string
action_result.summary.status string
action_result.summary.user_enabled boolean
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'set user attribute'

Set an attribute for a user

Type: generic
Read only: False

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
user_id required User ID - can be user principal name or object ID string azure user principal name azure object id email
attribute required Attribute to set string
attribute_value required Value of attribute to set string

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.attribute string
action_result.parameter.attribute_value string
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data string
action_result.summary.status string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'remove user'

Remove a user from a specified group

Type: generic
Read only: False

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
group_object_id required Object ID of group string azure group object id
user_id required User ID to remove from group string azure user principal name azure object id email

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.group_object_id string azure group object id
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data string
action_result.summary.status string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'add user'

Add a user to the tenant by creating an organizational account

Type: generic
Read only: False

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
group_object_id required Object ID of group string azure group object id
user_id required User ID to add to group string azure object id

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.group_object_id string azure group object id
action_result.parameter.user_id string azure object id
action_result.data string
action_result.summary.status string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'list groups'

List groups in the organization

Type: investigate
Read only: True

Action Parameters

No parameters are required for this action

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.data.*.deletionTimestamp string
action_result.data.*.description string
action_result.data.*.dirSyncEnabled string
action_result.data.*.displayName string
action_result.data.*.lastDirSyncTime string
action_result.data.*.mail string email
action_result.data.*.mailEnabled boolean
action_result.data.*.mailNickname string
action_result.data.*.objectId string azure object id
action_result.data.*.objectType string
action_result.data.*.odata.type string
action_result.data.*.onPremisesDomainName string domain
action_result.data.*.onPremisesNetBiosName string
action_result.data.*.onPremisesSamAccountName string
action_result.data.*.onPremisesSecurityIdentifier string
action_result.data.*.proxyAddresses string
action_result.data.*.securityEnabled boolean
action_result.summary.num_groups numeric
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'get group'

Get information about a group

Type: investigate
Read only: True

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
object_id required Object ID of group string azure object id

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.object_id string azure object id
action_result.data.*.deletionTimestamp string
action_result.data.*.description string
action_result.data.*.dirSyncEnabled string
action_result.data.*.displayName string
action_result.data.*.lastDirSyncTime string
action_result.data.*.mail string email
action_result.data.*.mailEnabled boolean
action_result.data.*.mailNickname string
action_result.data.*.objectId string azure object id
action_result.data.*.objectType string
action_result.data.*.odata.metadata string
action_result.data.*.odata.type string
action_result.data.*.onPremisesDomainName string domain
action_result.data.*.onPremisesNetBiosName string
action_result.data.*.onPremisesSamAccountName string
action_result.data.*.onPremisesSecurityIdentifier string
action_result.data.*.proxyAddresses string
action_result.data.*.securityEnabled boolean
action_result.summary.display_name string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'list group members'

List the members in a group

Type: investigate
Read only: True

Pagination is not implemented for this action as this endpoint does not support pagination\. Here is the Documentation for the same\.

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
group_object_id required Object ID of group string azure object id

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.group_object_id string azure object id
action_result.data.*.displayName string
action_result.data.*.objectId string azure object id
action_result.summary.num_members numeric
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'validate group'

Returns true if a user is in a group; otherwise, false

Type: investigate
Read only: True

Action Parameters

PARAMETER REQUIRED DESCRIPTION TYPE CONTAINS
group_object_id required Object ID of group string azure group object id
user_id required User ID to validate string azure user principal name azure object id email

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.parameter.group_object_id string azure group object id
action_result.parameter.user_id string azure user principal name azure object id email
action_result.data.*.user_in_group boolean
action_result.summary.user_in_group boolean
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'list directory roles'

List the directory roles in a tenant

Type: investigate
Read only: True

Pagination is not implemented for this action as this endpoint does not support pagination\. Here is the Documentation for the same\.

Action Parameters

No parameters are required for this action

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.data.*.deletionTimestamp string
action_result.data.*.description string
action_result.data.*.displayName string
action_result.data.*.isSystem boolean
action_result.data.*.objectId string azure object id
action_result.data.*.objectType string
action_result.data.*.odata.type string
action_result.data.*.roleDisabled boolean
action_result.data.*.roleTemplateId string azure role template id
action_result.summary.num_directory_roles numeric
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

action: 'generate token'

Generate a token or regenerates token when the token expires

Type: generic
Read only: False

Action Parameters

No parameters are required for this action

Action Output

DATA PATH TYPE CONTAINS
action_result.status string
action_result.data string
action_result.summary string
action_result.message string
summary.total_objects numeric
summary.total_objects_successful numeric

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 93.0%
  • HTML 7.0%