Install - .NET Core Agent Startup Parameters on Windows started as an IIS Site for Dynamic Analysis



.NET Framework Compatibility

vFunction supports C# .NET Core version 3.x and .NET 6.x, 7.x and 8.x applications.


Application Pool Prerequisites

The vFunction Agent requires a distinct Application Pool to be created for the Application if the current Application Pool is used by multiple Applications. Follow these steps to create a new Application Pool if needed.


Installation Workflow

  1. Install the Dynamic Analysis Controller
  2. Open the vFunction Core IIS startup parameters in a text editor

    ### Replace the REPLACE_BASE_DIR below with the actual values, such as C:\vfunction\
    ### Replace the INSTANCE_NAME below with the actual values, such as default-dotnet

    REPLACE_BASE_DIR\config\agent\instances\INSTANCE_NAME\vmargs-examples\IIS
  3. In a text editor, open the C:\Windows\System32\inetsrv\config\applicationHost.config XML
  4. Search for the term applicationPools in the applicationHost.config
  5. Modify the XML entry for the Application Pool used by the Application using the vmargs-examples\IIS file as a guide
  6. Save and close the file
  7. Stop and restart the Application Pool used by the Application
  8. Create new traffic to the IIS Site so a new Worker Process is launched
  9. Confirm that the Application comes up and functions as expected
  10. If any issues arise:

Sample contents of vmargs-example/IIS file

Open the sample file in:

### Replace the REPLACE_BASE_DIR below with the actual values, such as C:\vfunction\

REPLACE_BASE_DIR\controller-installation\stuff\agent\vmargs-examples\dotnet\dotnet\IIS

The contents of this sample file are below:

### Replace the REPLACE_BASE_DIR below with the actual values, such as C:\vfunction\
### Replace the REPLACE_INSTANCE below with the actual values, such as default-dotnet

### Open the applicationHost.config XML usually located at: C:\\Windows\\System32\\inetsrv\\config\\applicationHost.config
### Under the applicationPools node, find the relevant application pool and add the env vars:
<add name="DefaultAppPool" autoStart="true">
        <environmentVariables>
                <add name="VF_AGENT_CONF_LOCATION" value="REPLACE_BASE_DIR\config\agent\instances\REPLACE_INSTANCE\conf.json" />
    		    <add name="CORECLR_PROFILER_PATH_64" value="REPLACE_BASE_DIR\agent\vfagent.net.dll" />
    		    <add name="CORECLR_PROFILER_PATH_32" value="REPLACE_BASE_DIR\agent\vfagent.net.x86.dll" />
    		    <add name="CORECLR_ENABLE_PROFILING" value="1" />
        	    <add name="CORECLR_PROFILER" value="{cd7d4b53-96c8-4552-9c11-6e41df8eab8a}" />
        	    <add name="DOTNET_TailCallOpt" value="0"/>
    	</environmentVariables>
</add>