Update your Datadog .NET library to at least version 2.2.0 (at least version 2.16.0 for Software Composition Analysis detection features) for your target operating system architecture.
To check that your service’s language and framework versions are supported for ASM capabilities, see Compatibility.
Enable ASM by setting the DD_APPSEC_ENABLED environment variable to true. For example, on Windows self-hosted, run the following PowerShell snippet as part of your application start up script:
Run the following PowerShell command as administrator to configure the necessary environment variables in the registry HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment and restart IIS.
$target=[System.EnvironmentVariableTarget]::Machine
[System.Environment]::SetEnvironmentVariable("DD_APPSEC_ENABLED","true",$target)
net stop was /y
net start w3svc
Or, for IIS services exclusively, on WAS and W3SVC with Powershell as an administrator, run:
for ((i=1;i<=250;i++)); do # Target existing service’s routes curl https://your-application-url/existing-route -A dd-test-scanner-log; # Target non existing service’s routes curl https://your-application-url/non-existing-route -A dd-test-scanner-log; done