Skip to content

Commit 868d629

Browse files
committed
Merge branch 'main' of https://github.com/MicrosoftDocs/defender-docs-pr into msem-mdvm-updates-1
2 parents 655f254 + 65d8b8d commit 868d629

11 files changed

+79
-40
lines changed

defender-for-cloud-apps/protect-salesforce.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,13 @@ Connecting Salesforce to Defender for Cloud Apps gives you improved insights int
2626
- Ransomware
2727
- Unmanaged bring your own device (BYOD)
2828

29+
30+
### Prerequisites
31+
32+
- Install and authorize the Salesforce Connected App in the target Salesforce org before you start the connection process. Salesforce enforces usage restrictions on Connected Apps. For more information, see:[Prepare for Connected App Usage Restrictions Change](https://help.salesforce.com/s/articleView?id=005132365&type=1)
33+
34+
- Assign the **Approve Uninstalled Connected Apps** permission to the Salesforce service account used to connect Microsoft Defender for Cloud Apps. Salesforce requires this permission to connect third-party apps via OAuth.
35+
2936
## How Defender for Cloud Apps helps to protect your environment
3037

3138
- [Detect cloud threats, compromised accounts, and malicious insiders](best-practices.md#detect-cloud-threats-compromised-accounts-malicious-insiders-and-ransomware)

defender-xdr/advanced-hunting-aiagentsinfo-table.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,13 @@ ms.topic: reference
2424
ms.date: 11/06/2025
2525
---
2626

27-
# AIAgentsInfo
27+
# AIAgentsInfo (Preview)
2828

2929
[!INCLUDE [Microsoft Defender XDR rebranding](../includes/microsoft-defender.md)]
3030

31+
> [!IMPORTANT]
32+
> Some information relates to prereleased product that may be substantially modified before it's commercially released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
33+
3134
The `AIAgentsInfo` table in the [advanced hunting](advanced-hunting-overview.md) schema contains information about various entities—files, IP addresses, URLs, users, or devices—associated with alerts from Microsoft Defender for Endpoint, Microsoft Defender for Office 365, Microsoft Defender for Cloud Apps, and Microsoft Defender for Identity. Use this reference to construct queries that return information from this table.
3235

3336
This advanced hunting table is populated by records from various Microsoft Defender services. If your organization doesn't deploy the service in Microsoft Defender XDR, queries that use the table don't work or return any results. For more information about how to deploy services in Microsoft Defender XDR, see [Deploy supported services](deploy-supported-services.md).

defender-xdr/advanced-hunting-custom-functions.md

Lines changed: 45 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -36,39 +36,63 @@ ms.date: 03/28/2025
3636
> Some information relates to prereleased product which may be substantially modified before it's commercially released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
3737
3838
## Types of functions
39-
A function is a type of query in advanced hunting that can be used in other queries as if it's a command. You can create your own custom functions so you can reuse any query logic when you hunt in your environment.
39+
A function is a type of query in advanced hunting that you can use in other queries as if it's a command. You can create your own custom functions so you can reuse any query logic when you hunt in your environment.
4040

4141
There are three different types of functions in advanced hunting:
4242

4343
![Function types](/defender/media/advanced-hunting-custom-fxns/function-types.png)
4444

45-
- **Built-in functions** – Prebuilt functions included with Microsoft Defender XDR advanced hunting. These are available in all advanced hunting instances and can't be modified.
46-
- **Shared functions** – Custom functions created by users, which are available for all users in a specific tenant and can be modified and controlled by users.
47-
- **My functions** – Custom functions created by a user, which can be viewed and modified only by the user who created it.
45+
- **Built-in functions** – Prebuilt functions included with Microsoft Defender XDR advanced hunting. These functions are available in all advanced hunting instances and can't be modified.
46+
- **Shared functions** – Custom functions that users create. All users in a specific tenant can access these functions. Users can modify and control these functions.
47+
- **My functions** – Custom functions that a user creates. Only the user who created these functions can view and modify them.
4848

4949
## Write your own custom function
5050

51-
To create a function from the current query in the editor, select **Save** and then **Save as function**.
51+
To create a function from the current query in the editor:
5252

53-
![Save as function](/defender/media/advanced-hunting-custom-fxns/save-as-function.png)
53+
1. Select **Save** and then **Save as function**.
54+
![Save as function](/defender/media/advanced-hunting-custom-fxns/save-as-function.png)
5455

55-
Next, provide the following information:
56+
1. In the **Save as function** flyout panel, provide the following information:
5657

57-
- **Name** - Name of the function. Can contain only numbers, English letters, and underscores. To avoid accidentally using Kusto keywords, begin or end function names with an underscore or begin with a capital letter.
58-
- **Location** - The folder in which you would like to save the function, either shared or private.
59-
- **Description** - A description that can help other users understand the purpose of the function and how it works.
60-
- **Parameters** - Add a parameter for each variable in the function that requires a value when it's used.
61-
Add parameters to a function so that you can provide the arguments or values for certain variables when calling the function. This allows the same function to be used in different queries, each allowing for different values for the parameters. Parameters are defined by the following properties:
58+
- **Name** - Name of the function. Can contain only numbers, English letters, and underscores. To avoid accidentally using Kusto keywords, begin or end function names with an underscore or begin with a capital letter.
59+
- **Location** - The folder in which you want to save the function, either shared or private.
60+
- **Description** - A description that helps other users understand the purpose of the function and how it works.
61+
- **Parameters** - Add a parameter for each variable in the function that requires a value when it's used. For more information, see [Add parameters to your custom function](#add-parameters-to-your-custom-function).
62+
63+
![Save as function dialog box](/defender/media/advanced-hunting-custom-fxns/save-as-function-dialog-box.png)
64+
65+
1. Select **Save**.
66+
67+
### Add parameters to your custom function
68+
69+
You can add parameters to a function so that you can provide the arguments or values for certain variables when calling the function. This feature allows the same function to be used in different queries, each with different values for the parameters.
70+
71+
To add parameters when saving your custom function, select **Add parameter**, then enter the following properties:
6272
- **Type** - Data type for the value
6373
- **Name** - The name that must be used in the query to replace the parameter value
64-
- **Default value** - Value to be used for the parameter if a value isn't provided
74+
- **Default value** - Value to use for the parameter if you don't provide a value
6575

66-
Parameters are listed in the order they were created, with parameters that have no default value listed above those that have a default value.
76+
Parameters are listed in the order you create them, with parameters that have no default value listed before those that have a default value.
6777

68-
![Save as function dialog box](/defender/media/advanced-hunting-custom-fxns/save-as-function-dialog-box.png)
78+
### Create custom functions with tabular parameters
6979

80+
Create custom functions that use tabular parameters. With tabular parameters, you can pass entire tables as inputs. This approach lets you build more modular, reusable, and expressive logic across your hunting queries. This capability is especially useful for complex hunting scenarios that require structured data inputs.
81+
82+
To create tabular parameters for your custom function:
83+
1. Select **Add parameter** and then choose **table** as its **Type**.
84+
1. Enter a **Name** and **Default value** for the table.
85+
1. Map each column that your query references to the table. Select **Add column**, then enter the column's properties.
86+
87+
![Table parameter in custom functions](/defender/media/advanced-hunting-custom-fxns/save-as-function-table.png)
88+
89+
> [!NOTE]
90+
>- You can save a function with more than one table.
91+
>- If your query doesn't reference any columns in the table parameter, you can still save and run the function without mapping any columns.
92+
>- You can set tabular and scalar parameters in the same function.
93+
7094
## Use a custom function
71-
Use a function in a query by typing its name along with values for any parameter just as you would type in a command. The output of the function can either be returned as results or piped to another command.
95+
Use a function in a query by typing its name along with values for any parameter, just as you would type in a command. The output of the function can either be returned as results or piped to another command.
7296

7397
Add a function to the current query by double-clicking on its name or selecting the three dots to the right of the function and selecting **Open in query editor**.
7498

@@ -77,27 +101,27 @@ If a query requires arguments, provide them using the following syntax: *functio
77101
![Open in query editor](/defender/media/advanced-hunting-custom-fxns/open-in-query-editor.png)
78102

79103
> [!NOTE]
80-
> Functions can't be used inside another function.
104+
> You can't use functions inside another function.
81105
82106
## Work with function codes
83-
You can view the code of a function either to gain insight into how it works or to modify its code. Select the three dots to the right of the function and select **Load function code** to open a new tab with the function code.
107+
You can view the code of a function to understand how it works or to modify its code. Select the three dots to the right of the function and select **Load function code** to open a new tab with the function code.
84108

85109
![Load function code](/defender/media/advanced-hunting-custom-fxns/load-function-code.png)
86110

87111
## Edit a custom function
88112

89-
Edit the properties of a function by selecting the three dots to the right of the function and selecting **Edit details**. Make any modifications that you want to the properties and parameters of the function then select **Save**.
113+
Edit the properties of a function by selecting the three dots to the right of the function and selecting **Edit details**. Make any modifications that you want to the properties and parameters of the function, then select **Save**.
90114

91115
![Edit function code](/defender/media/advanced-hunting-custom-fxns/edit-function.png)
92116

93-
If the function code is already loaded to the editor, you can also select **Save** to apply any changes to the code or properties of the function.
117+
If the function code is already loaded in the editor, you can also select **Save** to apply any changes to the code or properties of the function.
94118

95119
> [!NOTE]
96120
> Once a function is in use in a saved query or a detection rule, you can't edit the function to expand its scope. For example, if you saved a function that queries identity tables, and this function is used in a detection rule, you can't edit the function to include a device table after the fact. To do that, you can save a new function. Product scoping can be narrowed for the same function but not extended.
97121
98122
## Delete a custom function
99123

100-
You can delete functions from **My functions** and functions you created in **Shared functions**. You cannot delete functions that you have not created, unless you have security data manage permissions.
124+
You can delete functions from **My functions** and functions you created in **Shared functions**. You can't delete functions that you didn't create, unless you have security data manage permissions.
101125

102126
To delete a function, select the three dots to the right of the function and select **Delete**.
103127

0 commit comments

Comments
 (0)