Chris Stylianidou
12/11/2023, 4:46 PMprograms
to fetch all apps installed on a Windows machine. Unfortunately we are not able to fetch applications whose binaries are located under the Program Files\WindowsApps
folder... did anyone faced the same issue? is there a workaround?
thanks 😉Stefano Bonicatti
12/11/2023, 4:56 PMprograms
table (https://github.com/osquery/osquery/blob/master/osquery/tables/system/windows/programs.cpp) is implemented using part of the logic of the registry
table. If those apps are registered too in the system registry, the registry
table can be used.
Not sure where they are though.Stefano Bonicatti
12/11/2023, 5:01 PMChris Stylianidou
12/11/2023, 5:03 PMregistry
tableStefano Bonicatti
12/11/2023, 5:05 PMChris Stylianidou
12/11/2023, 5:07 PMChris Stylianidou
12/11/2023, 5:10 PMSELECT * from registry
where
path like '%HKEY_CURRENT_USER\Software\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\AppModel\Repository\Packages%'
Stefano Bonicatti
12/11/2023, 5:10 PMStefano Bonicatti
12/11/2023, 5:10 PMStefano Bonicatti
12/11/2023, 5:10 PMChris Stylianidou
12/11/2023, 5:11 PMStefano Bonicatti
12/11/2023, 5:11 PM%
?Stefano Bonicatti
12/11/2023, 5:14 PM[...]\Packages\%
, otherwise if no separator, the listing of keys actually starts one level above, and then if I remember correctly it will only return that single keyStefano Bonicatti
12/11/2023, 5:15 PMStefano Bonicatti
12/11/2023, 5:17 PMPackages%
means matching also PackagesSomeOtherWords
Stefano Bonicatti
12/11/2023, 5:22 PMStefano Bonicatti
12/11/2023, 5:23 PMStefano Bonicatti
12/11/2023, 5:27 PMHKEY_USERS\<SID>\Software\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\AppModel\Repository\Packages\%
Chris Stylianidou
12/11/2023, 5:35 PMSELECT * from registry
where
path like 'HKEY_USERS\%\Software\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\AppModel\Repository\Packages\%'
tokcum
11/22/2024, 1:21 AMtokcum
11/27/2024, 4:45 PMSELECT DISTINCT
SUBSTR(filename, 1, INSTR(filename, '_') - 1 ) AS name,
SUBSTR(filename, INSTR(filename, '_') + 1, INSTR(SUBSTR(filename, INSTR(filename, '_') + 1), '_') - 1) AS version,
CASE
WHEN filename LIKE '%_x64__%' THEN 'x64'
WHEN filename LIKE '%_x86__%' THEN 'x86'
WHEN filename LIKE '%_neutral__%' THEN 'neutral'
ELSE ''
END AS arch
FROM file
WHERE directory = 'C:\Program Files\WindowsApps' AND filename like "%.%_%_%__%"
More and more software products seem to get installed in this location. Popular examples in our case is Apps installed from Microsoft Store such as the Company Portal and Mozilla Firefox. As a result, the software inventory in Fleet is increasingly incomplete. It would be great if Fleet would be able to add this location to the software inventory as well.tokcum
11/27/2024, 4:54 PM