mandiant / VM-Packages

Chocolatey packages supporting the analysis environment projects FLARE-VM & Commando VM.
Apache License 2.0
147 stars 67 forks source link

Enable Param Passing to Dependencies #139

Open MalwareMechanic opened 1 year ago

MalwareMechanic commented 1 year ago

Overview

Currently, dependencies install using default everything. However, chocolatey allows passing parameters to dependencies by coupling two command-line arguments: --params-global and --params (syntax --params '/PARAM1:value1 /PARAMFLAG').

As an example, say fake-package.vm had a dependency that could be configured to use a specific port, installation path, and verbosity flag, we would pass these parameters as below:

choco install fake-package.vm --params-global --params '/Port:82 /InstallationPath:""C:\blah\folder with space"" /DEBUG'

To enable this, we need to do the following:

Resources

MalwareMechanic commented 1 year ago

Also need to consider --install-arguments, which differs from "package" specific parameters -- it's used to instruct native installers.

There is also the concept of "Install Arguments", or silent arguments you can pass through transparently to the native installer. This is more of a way for a package consumer to override the default silent arguments that are passed to the native installer.

Ana06 commented 4 months ago

Is there a concrete package for which you would like to use this feature @MalwareMechanic? Otherwise I think we shouldn't implement this feature.