Install - .NET Core Agent Startup Parameters on Windows started from the Command Line for Dynamic Analysis
.NET Framework Compatibility
vFunction supports C# .NET Core version 3.x and .NET 6.x, 7.x and 8.x applications.
Installation Workflow
- Install the Dynamic Analysis Controller
- Open the vFunction Core Standard-Executables 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\standard-executables - Open a new, blank document in a text editor
- Copy-and-paste either the Batch Script or PowerShell Script section of the vmargs-examples\standard-executables into the new, blank document
- Modify the line for 'RunApp.exe' to point to the full path to launch the Application
- Save and close the new, blank document. Be sure to use the .bat or .ps1 file extension when saving the document
- Launch the .bat or .ps1 script
- Confirm that the Application comes up and functions as expected
- If any issues arise:
Sample contents of vmargs-example/standard-executables 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\standard-executables
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
### Replace RunApp with the name and path to the Application to be profiled
### Alternatively, find the location referenced in the next text block below after running the install script to find the fields already replaced
### .bat Example:
set VF_AGENT_CONF_LOCATION=REPLACE_BASE_DIR\config\agent\instances\REPLACE_INSTANCE\conf.json
set CORECLR_PROFILER_PATH_64=REPLACE_BASE_DIR\agent\vfagent.net.dll
set CORECLR_PROFILER_PATH_32=REPLACE_BASE_DIR\agent\vfagent.net.x86.dll
set CORECLR_ENABLE_PROFILING=1
set CORECLR_PROFILER={cd7d4b53-96c8-4552-9c11-6e41df8eab8a}
set DOTNET_TailCallOpt=0
RunApp.exe
###############
### .ps example
$env:VF_AGENT_CONF_LOCATION='REPLACE_BASE_DIR\config\agent\instances\REPLACE_INSTANCE\conf.json'
$env:CORECLR_PROFILER_PATH_64 = 'REPLACE_BASE_DIR\agent\vfagent.net.dll'
$env:CORECLR_PROFILER_PATH_32 = 'REPLACE_BASE_DIR\agent\vfagent.net.x86.dll'
$env:CORECLR_ENABLE_PROFILING = '1'
$env:CORECLR_PROFILER = '{cd7d4b53-96c8-4552-9c11-6e41df8eab8a}'
$env:DOTNET_TailCallOpt = 0
& 'RunApp.exe'
Or, alternatively. once the install script is run, the relevant placeholder fields in the file are replaced in the version of the environmentally-specific file in:
### 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\standard-executables