Skip to content

Commit d7a2dff

Browse files
ushasanFredericHeem
authored andcommitted
Adding fixes for Jan 2022 preview version (sasUri/provisioningState params) & PoSH fixes (Azure#18330)
* adding fixes for Jan 2022 preview version * adding fix for PoSH * removing un-needed params
1 parent a26741e commit d7a2dff

File tree

2 files changed

+124
-2
lines changed

2 files changed

+124
-2
lines changed

specification/securityinsights/resource-manager/Microsoft.SecurityInsights/preview/2022-01-01-preview/Watchlists.json

Lines changed: 36 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,9 @@
182182
},
183183
"Creates or updates a watchlist and bulk creates watchlist items.": {
184184
"$ref": "./examples/watchlists/CreateWatchlistAndWatchlistItems.json"
185+
},
186+
"Create or update a watchlist and bulk creates watchlist items from SAL URI.": {
187+
"$ref": "./examples/watchlists/CreateWatchlistAndWatchlistItemsFromSasUri.json"
185188
}
186189
},
187190
"tags": [
@@ -568,6 +571,11 @@
568571
"description": "The raw content that represents to watchlist items to create. In case of csv/tsv content type, it's the content of the file that will parsed by the endpoint",
569572
"type": "string"
570573
},
574+
"sasUri": {
575+
"x-ms-secret": true,
576+
"description": "The Shared Access Signature (SAS) URI under which the large csv watchlist file is located and from which the watchlist and its items will be created",
577+
"type": "string"
578+
},
571579
"itemsSearchKey": {
572580
"description": "The search key is used to optimize query performance when using watchlists for joins with other data. For example, enable a column with IP addresses to be the designated SearchKey field, then use this field as the key field when joining to other event data by IP address.",
573581
"type": "string"
@@ -579,6 +587,11 @@
579587
"uploadStatus": {
580588
"description": "The status of the Watchlist upload : New, InProgress or Complete. Pls note : When a Watchlist upload status is equal to InProgress, the Watchlist cannot be deleted",
581589
"type": "string"
590+
},
591+
"provisioningState": {
592+
"readOnly": true,
593+
"$ref": "#/definitions/ProvisioningState",
594+
"description": "The provisioning state of the watchlist resource."
582595
}
583596
},
584597
"required": [
@@ -665,17 +678,38 @@
665678
},
666679
"itemsKeyValue": {
667680
"description": "key-value pairs for a watchlist item",
668-
"type": "object"
681+
"type": "object",
682+
"additionalProperties": {}
669683
},
670684
"entityMapping": {
671685
"description": "key-value pairs for a watchlist item entity mapping",
672-
"type": "object"
686+
"type": "object",
687+
"additionalProperties": {}
673688
}
674689
},
675690
"required": [
676691
"itemsKeyValue"
677692
],
678693
"type": "object"
694+
},
695+
"Label": {
696+
"description": "Label that will be used to tag and filter on.",
697+
"type": "string"
698+
},
699+
"ProvisioningState": {
700+
"type": "string",
701+
"readOnly": true,
702+
"description": "The current provisioning state.",
703+
"enum": [
704+
"Succeeded",
705+
"Failed",
706+
"Canceled",
707+
"InProgress"
708+
],
709+
"x-ms-enum": {
710+
"name": "ProvisioningState",
711+
"modelAsString": true
712+
}
679713
}
680714
},
681715
"parameters": {
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
{
2+
"parameters": {
3+
"api-version": "2022-01-01-preview",
4+
"subscriptionId": "d0cfe6b2-9ac0-4464-9919-dccaee2e48c0",
5+
"resourceGroupName": "myRg",
6+
"workspaceName": "myWorkspace",
7+
"operationalInsightsResourceProvider": "Microsoft.OperationalInsights",
8+
"watchlistAlias": "highValueAsset",
9+
"watchlist": {
10+
"etag": "\"0300bf09-0000-0000-0000-5c37296e0000\"",
11+
"properties": {
12+
"displayName": "High Value Assets Watchlist",
13+
"sourceType": "Remote storage",
14+
"provider": "Microsoft",
15+
"description": "Watchlist from a large CSV file under Blob storage",
16+
"numberOfLinesToSkip": 1,
17+
"sasUri": "https://storagesample.blob.core.windows.net/sample-contaier/sampleBlob.csv?sp=r&st=2021-09-24T01:15:52Z&se=2021-10-01T09:15:52Z&spr=https&sv=2020-08-04&sr=b&sig=HRRRMc43ZJz634eBc402X%2FFPxam5sZVPSkLOY14baEd%4Z",
18+
"itemsSearchKey": "header1"
19+
}
20+
}
21+
},
22+
"responses": {
23+
"200": {
24+
"body": {
25+
"id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/watchlists/highValueAsset",
26+
"name": "highValueAsset",
27+
"etag": "\"0300bf09-0000-0000-0000-5c37296e0000\"",
28+
"type": "Microsoft.SecurityInsights/Watchlists",
29+
"properties": {
30+
"watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017",
31+
"displayName": "High Value Assets Watchlist",
32+
"provider": "Microsoft",
33+
"sourceType": "Local file",
34+
"created": "2020-09-28T00:26:54.7746089+00:00",
35+
"updated": "2020-09-28T00:26:57+00:00",
36+
"createdBy": {
37+
"objectId": "2046feea-040d-4a46-9e2b-91c2941bfa70",
38+
"email": "[email protected]",
39+
"name": "john doe"
40+
},
41+
"updatedBy": {
42+
"objectId": "2046feea-040d-4a46-9e2b-91c2941bfa70",
43+
"email": "[email protected]",
44+
"name": "john doe"
45+
},
46+
"description": "Watchlist from CSV content",
47+
"watchlistType": "watchlist",
48+
"watchlistAlias": "highValueAsset",
49+
"itemsSearchKey": "header1",
50+
"isDeleted": false,
51+
"tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd"
52+
}
53+
}
54+
},
55+
"201": {
56+
"body": {
57+
"id": "/subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/watchlists/highValueAsset",
58+
"name": "highValueAsset",
59+
"etag": "\"0300bf09-0000-0000-0000-5c37296e0000\"",
60+
"type": "Microsoft.SecurityInsights/Watchlists",
61+
"properties": {
62+
"watchlistId": "76d5a51f-ba1f-4038-9d22-59fda38dc017",
63+
"displayName": "High Value Assets Watchlist",
64+
"provider": "Microsoft",
65+
"sourceType": "Local file",
66+
"created": "2020-09-28T00:26:54.7746089+00:00",
67+
"updated": "2020-09-28T00:26:57+00:00",
68+
"createdBy": {
69+
"objectId": "2046feea-040d-4a46-9e2b-91c2941bfa70",
70+
"email": "[email protected]",
71+
"name": "john doe"
72+
},
73+
"updatedBy": {
74+
"objectId": "2046feea-040d-4a46-9e2b-91c2941bfa70",
75+
"email": "[email protected]",
76+
"name": "john doe"
77+
},
78+
"description": "Watchlist from CSV content",
79+
"watchlistType": "watchlist",
80+
"watchlistAlias": "highValueAsset",
81+
"itemsSearchKey": "header1",
82+
"isDeleted": false,
83+
"tenantId": "f686d426-8d16-42db-81b7-ab578e110ccd"
84+
}
85+
}
86+
}
87+
}
88+
}

0 commit comments

Comments
 (0)