Traffic Capture

Microsoft Azure virtual network TAP

Step-by-step Azure setup that streams virtual machine traffic to HOSSIDARK with virtual network TAP (VXLAN UDP 4789), plus the alternatives when TAP is not available in your region.

Licence required · network3 min read
On this page

What it is for

Azure virtual network TAP copies the traffic of a virtual machine network interface and streams it, wrapped in VXLAN (UDP 4789), to an address in the same or a peered virtual network. HOSSIDARK receives it on its capture card and analyses the original packets.

Important: Microsoft currently offers virtual network TAP as a public preview in selected regions. Check that your region is listed before planning; otherwise use one of the alternatives at the end of this page.

 VM network interface --TAP configuration--> virtual network TAP resource
                                                 |  destination:
                                                 |   HOSSIDARK capture NIC IP
                                                 |   or internal Load Balancer frontend
                                                 v  VXLAN UDP 4789
                                     HOSSIDARK capture card -> sensor -> console

Before you start

RequirementDetail
RegionVirtual network TAP available (public preview list).
ApplianceVM with two NICs: management and capture; IP forwarding is not required.
NetworkCapture NIC in the same VNet as the monitored NICs, or in a peered VNet in the same region.
NSGInbound UDP 4789 to the capture NIC from the monitored subnets.
Azure CLI2.61 or later; the virtual-network-tap extension installs on first use.
PermissionsMicrosoft.Network/virtualNetworkTaps/* and Microsoft.Network/networkInterfaces/tapConfigurations/*

Step by step

1. Prepare the capture NIC

Create a NIC in the appliance subnet, attach it to the HOSSIDARK VM (stop the VM first) and add an NSG rule allowing UDP 4789 inbound. For high availability place the capture NIC behind an internal Standard Load Balancer with a UDP 4789 rule.

2. Create the virtual network TAP

az account set --subscription <subscription-id>
az provider register --namespace Microsoft.Network
az network vnet tap create -g RG -n hossidark-tap \
  --destination /subscriptions/<id>/resourceGroups/RG/providers/Microsoft.Network/networkInterfaces/hossidark-capture/ipConfigurations/ipconfig1 \
  --port 4789

With a load balancer, use the frontend IP configuration ID as --destination.

3. Add a TAP configuration to each monitored NIC

az network nic vtap-config create -g RG --nic-name web01-nic \
  -n hossidark --vnet-tap hossidark-tap

Start with the NICs of your firewall or network virtual appliance, then domain controllers and key servers.

In Network Settings > Sensing (or the terminal capture menu) choose the capture card. VXLAN is unwrapped automatically.

How to confirm it works

  • az network vnet tap show -g RG -n hossidark-tap lists the network interface configurations.
  • The console shows the capture card as Receiving; the terminal communication tests report it OK.

Common problems

SymptomCauseFix
tap create failsRegion not in previewUse an alternative below.
Nothing receivedNSG blocks UDP 4789Add inbound rule on the capture NIC/subnet.
Peered VNet sources missingPeering not established before TAPCreate peering first, then recreate the TAP config.

Alternatives when TAP is unavailable

  1. Inline network virtual appliance path: route subnet traffic (User Defined Routes) through a firewall that exports a mirror or flows to HOSSIDARK.
  2. Flows: NetFlow/IPFIX to UDP 2055 or sFlow to UDP 6343 from your virtual firewall or router.
  3. Probe: install a HOSSIDARK probe on a monitored VM to forward its traffic (see Probes).
  4. Agents: endpoint agents report host activity directly.