Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{

Check notice on line 1 in specification/network/resource-manager/Microsoft.Network/stable/2024-10-01/azureFirewall.json

View workflow job for this annotation

GitHub Actions / TypeSpec Requirement

Brownfield services will soon be required to convert from OpenAPI to TypeSpec. See https://aka.ms/azsdk/typespec.
"swagger": "2.0",
"info": {
"title": "NetworkManagementClient",
Expand Down Expand Up @@ -505,6 +505,78 @@
"final-state-via": "location"
}
}
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/azureFirewalls/{azureFirewallName}/packetCaptureOperation": {
"post": {
"tags": [
"AzureFirewalls"
],
"operationId": "AzureFirewalls_PacketCaptureOperation",
"description": "Runs a packet capture operation on AzureFirewall.",
"parameters": [
{
"name": "resourceGroupName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the resource group."
},
{
"name": "azureFirewallName",
"in": "path",
"required": true,
"type": "string",
"pattern": "^[A-Za-z0-9][\\w\\-._]{0,54}[A-Za-z0-9_]$",
"description": "The name of the azure firewall."
},
{
"name": "parameters",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/FirewallPacketCaptureParameters"
},
"description": "Parameters supplied to run packet capture on azure firewall."
},
{
"$ref": "./network.json#/parameters/ApiVersionParameter"
},
{
"$ref": "./network.json#/parameters/SubscriptionIdParameter"
}
],
"responses": {
"200": {
"description": "Azure Firewall Packet Capture Response",
"schema": {
"$ref": "#/definitions/AzureFirewallPacketCaptureResponse"
}
},
"202": {
"description": "Accepted and the operation will complete asynchronously.",
"headers": {
"Location": {
"type": "string"
}
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "./network.json#/definitions/CloudError"
}
}
},
"x-ms-examples": {
"AzureFirewallPacketCaptureOperation": {
"$ref": "./examples/AzureFirewallPacketCaptureOperation.json"
}
},
"x-ms-long-running-operation": true,
"x-ms-long-running-operation-options": {
"final-state-via": "location"
}
}
}
},
"definitions": {
Expand Down Expand Up @@ -1273,6 +1345,10 @@
},
"description": "Rules to filter packet captures.",
"x-ms-identifiers": []
},
"operation": {
"$ref": "#/definitions/AzureFirewallPacketCaptureOperationType",
"description": "The Azure Firewall packet capture operation to perform"
}
},
"description": "Azure Firewall Packet Capture Parameters."
Expand Down Expand Up @@ -1349,6 +1425,54 @@
}
},
"description": "Azure Firewall Autoscale Configuration parameters."
},
"AzureFirewallPacketCaptureResponse": {
"type": "object",
"properties": {
"azureFirewallPacketCaptureResponseCode": {
"$ref": "#/definitions/AzureFirewallPacketCaptureResponseCode",
"description": "The response code of the performed packet capture operation"
},
"message": {
"type": "string",
"description": "Localized Message String of The Result Of The Azure Firewall Packet Capture Operation"
}
},
"description": "Response of an Azure Firewall Packet Capture Operation."
},
"AzureFirewallPacketCaptureOperationType": {
"type": "string",
"description": "The packet capture operation to perform.",
"enum": [
"Start",
"Status",
"Stop"
],
"default": "Start",
"x-ms-enum": {
"name": "AzureFirewallPacketCaptureOperationType",
"modelAsString": true
}
},
"AzureFirewallPacketCaptureResponseCode": {
"type": "string",
"description": "The packet capture operation to perform.",
"enum": [
"NotImplemented",
"AzureFirewallPacketCaptureStartSucceeded",
"AzureFirewallPacketCaptureStartFailed",
"AzureFirewallPacketCaptureStartFailedToUpload",
"AzureFirewallPacketCaptureStartFailure",
"AzureFirewallPacketCaptureInProgress",
"AzureFirewallPacketCaptureNotInProgress",
"AzureFirewallPacketCaptureStopSucceeded",
"AzureFirewallPacketCaptureFailed",
"AzureFirewallPacketCaptureCompleted"
],
"x-ms-enum": {
"name": "AzureFirewallPacketCaptureResponseCode",
"modelAsString": true
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
{
"parameters": {
"api-version": "2024-10-01",
"subscriptionId": "subid",
"resourceGroupName": "rg1",
"azureFirewallName": "azureFirewall1",
"parameters": {
"durationInSeconds": 300,
"numberOfPacketsToCapture": 5000,
"sasUrl": "someSASURL",
"fileName": "azureFirewallPacketCapture",
"protocol": "Any",
"flags": [
{
"type": "syn"
},
{
"type": "fin"
}
],
"filters": [
{
"sources": [
"20.1.1.0"
],
"destinations": [
"20.1.2.0"
],
"destinationPorts": [
"4500"
]
},
{
"sources": [
"10.1.1.0",
"10.1.1.1"
],
"destinations": [
"10.1.2.0"
],
"destinationPorts": [
"123",
"80"
]
}
],
"operation": "Status"
}
},
"responses": {
"202": {
"headers": {
"Location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/locations/eastus/operationResults/00000000-0000-0000-0000-000000000000?api-version=2025-01-01",
"Azure-AsyncOperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Network/locations/eastus/operations/00000000-0000-0000-0000-000000000000?api-version=2025-01-01"
}
},
"200": {
"body": {
"azureFirewallPacketCaptureResponseCode": "AzureFirewallPacketCaptureInProgress",
"message": "Packet capture in progress. Please wait till it is finished or stop the current capture before starting another."
}
}
}
}
Loading