Ronny_OO7
Frequent contributor

Clarify $(ProgramData);$(ProgramFiles);$(ProgramFiles(x86)) Includedirectory use

Jump to solution

Hello I would like to know what is exactly included for files scanning if you use: 

$(ProgramData);$(ProgramFiles);$(ProgramFiles(x86))

Gathering Inventory mentioned:

Values
Values / range The valid folder name where applications are installed.
Default values Default values respectively on a 32-bit platform are:
Program Files
Program Files
"" (empty value).
Default values on a 64-bit platform are:
Program Files
Program Files (x86)
Program Files
Example values -o ProgramFiles=”D:\Program Files”

So does that cover all installations of software in D:\Program Files” E:\Program Files” F drive etc and 32 and 64 bit?

 

Also what system setting is this depending on? Path?

Also can Flexera share an list with all supported $(paramaters)

Thanks and Regards

Ronald

 

1 Solution

Accepted Solutions
ChrisG
Community Manager Community Manager
Community Manager

Re: Clarify $(ProgramData);$(ProgramFiles);$(ProgramFiles(x86)) Includedirectory use

Jump to solution

Here's a shot at answering these questions:


1:  Would like to know what is exactly included for files scanning if you use the paramater? So what are they designed to collect information from? On what system paramaters? 

The inventory gathering process will collect details about executable files that are found in or under any directories specified by the IncludeDirectory FlexNet agent preference. On Windows, the gathered details include the filename, path, size, and selected properties from WinPE header information in the executable file (if available). Here is an example from what you may see in an inventory NDI file showing data gathered about an executable file:

<Content MD5="NO_MD5" Size="461824">
	<Instance Path="C:\Program Files\7-Zip\7z.exe" DateTime="20180430T180000"/>
	<Property Name="CompanyName" Value="Igor Pavlov"/>
	<Property Name="LegalCopyright" Value="Copyright (c) 1999-2018 Igor Pavlov"/>
	<Property Name="OriginalFilename" Value="7z.exe"/>
	<Property Name="ProductName" Value="7-Zip"/>
	<Property Name="ProductVersion" Value="18.05"/>
	<Property Name="FileVersion" Value="18.05"/>
	<Property Name="WinPE Version" Value="18.5.0.0"/>
	<Property Name="FileDescription" Value="7-Zip Console"/>
	<Property Name="InternalName" Value="7z"/>
	<Property Name="Language" Value="1033"/>
</Content>

 


2: How exact the values for these preferences are obtained

FlexNet agent preference values are taken from:

  1. Command line options when invoking the appropriate process (for example: ndtrack.exe -o IncludeDirectory=c:\); or
  2. The registry (for example, HKLM\SOFTWARE\Wow6432Node\ManageSoft Corp\ManageSoft\Tracker\CurrentVersion\IncludeDirectory=C:\) - see [Registry] Explained for more info

If you specify any directories to be included in inventory on the Inventory Settings page in the FlexNet Manager Suite web UI, then those details will end up in the agent policy. When the agent applies its policy the value will get stored in the registry entry noted above to be picked up when the inventory gathering process is executed.

 


3: If this works also in the Zerotouch agent

If ndtrack is invoked in a zero-touch manner (i.e. without the agent fully installed) then preference values won't be stored in or taken from the registry. Non-default preference values will only be obtained from the command line that is used to invoke ndtrack in this case.

 


4: Do the paramater cover all Flavours of programdata and programfiles on C,D,E etc and 32 and 64 bit

The $(ProgramFiles), $(ProgramFilesX86) and $(ProgramData) agent preference references correspond to the similarly named folder IDs described on the following Microsoft docs page: KNOWNFOLDERID. That page discusses the how the semantics of these values differ between 32 and 64 bit operating systems.

Each installation of Windows only has a single formal ProgramFiles/ProgramFilesX86/ProgramData directory, which is what the agent preferences here refer to. Even if you have (say) a D:\Program Files directory that exists on the filesystem, Windows likely won't recognize it as the operating system's ProgramFiles directory which would normally be on the C:\ drive.

 

(Anything expressed here is my own view and not necessarily that of my employer, Flexera. If my reply answers a question you have raised, please click "ACCEPT AS SOLUTION".)

View solution in original post

12 Replies
JohnSorensenDK
Moderator Moderator
Moderator

Re: Clarify $(ProgramData);$(ProgramFiles);$(ProgramFiles(x86)) Includedirectory use

Jump to solution

@Ronny_OO7 

AFAIK these parameters refer to the Windows parameters set, e.g. for my laptop:

ProgramData=C:\ProgramData
ProgramFiles=C:\Program Files
ProgramFiles(x86)=C:\Program Files (x86)

Thanks,

0 Kudos
Ronny_OO7
Frequent contributor

Re: Clarify $(ProgramData);$(ProgramFiles);$(ProgramFiles(x86)) Includedirectory use

Jump to solution
Thanks John,
What Windows paramaters exacly? I would like to know the exact way it is designed.

Regards
Ronald
0 Kudos
kclausen
Flexera
Flexera

Re: Clarify $(ProgramData);$(ProgramFiles);$(ProgramFiles(x86)) Includedirectory use

Jump to solution

@Ronny_OO7  - These parameters are seldom used because the Windows Folders to include or exclude are specified on the Inventory Settings page in the FNMS User Interface (see attached image).

By default, File Scanning is not enabled.  On the Inventory Settings page, you can enable File Scanning for Windows.  In general, this is all that is needed.  When this is specified, then all folders on the local drives of the device are scanned, except the $(WindowsFolder) is always excluded

If you want to change the above behavior, then you can specify specific folders to Include or Exclude within the Inventory Settings.

Additional details on File Evidence gathering can be found in the On-Line Help.

https://docs.flexera.com/fnms/EN/WebHelp/index.html#tasks/InvSet-FileInvSection.html

 

 

0 Kudos
ChrisG
Community Manager Community Manager
Community Manager

Re: Clarify $(ProgramData);$(ProgramFiles);$(ProgramFiles(x86)) Includedirectory use

Jump to solution

@Ronny_OO7 - are you wanting to know how the values for these preferences are obtained?

Generally these preferences default (on Windows operating systems) to values obtained through the SHGetKnownFolderPath function available from the Windows Shell API. For example, the default value for the ProgramFiles preference is obtained by calling SHGetKnownFolderPath with a KNOWNFOLDERID value of FOLDERID_ProgramFiles.

(Anything expressed here is my own view and not necessarily that of my employer, Flexera. If my reply answers a question you have raised, please click "ACCEPT AS SOLUTION".)
0 Kudos