Hi, can anyone give some insight on osquery suppor...
# general
p
Hi, can anyone give some insight on osquery support for language other than English. Example, I have my OS language as Spanish, then I run osquery and getting the output in Spanish.
osquery> .all logical_drives; +-----------+---------+------------------+-------------+--------------+-------------+----------------+ | device_id | type | description | free_space | size | file_system | boot_partition | +-----------+---------+------------------+-------------+--------------+-------------+----------------+ | C: | Unknown | Disco fijo local | 78378098688 | 106662506496 | NTFS | 1 | | D: | Unknown | Disco CD-ROM | 0 | 4919504896 | UDF | 0 | +-----------+---------+------------------+-------------+--------------+-------------+----------------+
The description here is in Spanish
m
osquery is returning string values from the underlying OS APIs, which is probably controlled by the language locale, which the osquery process inherits from its environment.
As far as I know you can change that language setting for the whole system or for a particular user, but not for a single process. One hack people have done is, create a new user, set their language to English, then use the
runas
command to run a process as that user.
p
In our application, osquery commands are run through a fixed/ defined user, is it possible to change the language to English for a user through command to run osquery or any other command?
m
osquery cannot change the system or run commands, but if you had another ability to run a system command, it looks like you can change the OS language for just the user account that runs osquery. I have not tested it but there are two PowerShell commands:
Set-WinSystemLocale
and
Set-WinUserLanguageList
Alternatively, there's the registry key https://www.tenforums.com/tutorials/30656-see-system-default-ui-language-windows-10-a.html