Difference between revisions of "Setenv"

From SpybotWiki
Jump to: navigation, search
m (Description: added templates)
m (Description: added environment template info)
 
Line 23: Line 23:
 
* ''<$FULLPATH>'' to set the variable to the file path and filename;
 
* ''<$FULLPATH>'' to set the variable to the file path and filename;
 
* and ''<$MD5>'' to set the variable to the files MD5 hash.
 
* and ''<$MD5>'' to set the variable to the files MD5 hash.
 +
 +
Beginning with ''SpybotSD.exe'' 1.5.3 and ''advcheck.dll'' 1.5.6, environment variables may also be used as templates in any part of a command, in the form ''<$ENV(variablename)>'', as shown in an example below:
 +
 +
NoOp:"setenv=basefilename:malware"
 +
File:"Test","<$WINDIR>\<$ENV(basefilename)>.exe"
  
 
==See also==
 
==See also==

Latest revision as of 11:53, 6 May 2008

setenv
Variants setenv
Previously
Group Flow Control
Version advcheck.dll ??? < 1.5.4.5

Sets a global environment variable.

Usage

setenv=<name(string)>:<value(string)>

Examples

setenv=greeting:Hello

Description

This parameter can be used to store certain values in environment variables that are retained throughout the OpenSBI file.

It allows the following special templates for properties unknown at design time:

  • <$FILENAME> to set the variable to the filename, excluding its path;
  • <$FILEPATH> to set the variable to the file path, excluding its name;
  • <$FULLPATH> to set the variable to the file path and filename;
  • and <$MD5> to set the variable to the files MD5 hash.

Beginning with SpybotSD.exe 1.5.3 and advcheck.dll 1.5.6, environment variables may also be used as templates in any part of a command, in the form <$ENV(variablename)>, as shown in an example below:

NoOp:"setenv=basefilename:malware"
File:"Test","<$WINDIR>\<$ENV(basefilename)>.exe"

See also

Similar parameters

Similar commands