web analytics

Wintriage: Publicada la versión 09042023 / Released version 09042023

¡Llega una nueva versión de WinTriage!

The latest release of Wintriage is here! (English version here).

Como ya habíamos anticipado anteriormente, estábamos implementando una nueva versión de Wintriage que viene con más artefactos en la extracción, hemos solucionado algunos bugs y hemos añadido nuevas funcionalidades en base a las necesidades que hemos tenido últimamente en la resolución de diversos incidentes de seguridad.

Hasta ahora Wintriage generaba una estructura de directorios con todos los artefactos que podía sacar, hubiera o no hubiera cosas dentro. Es decir, que a veces, ibas con toda la ilusión a ver si el usuario tenía algo en un artefacto en concreto y luego veías que la carpeta estaba vacía, puesto que no se había extraído nada. Así, como funcionalidad principal o cambio en el funcionamiento de Wintriage es que ahora sólo se generará una carpeta en el directorio de la extracción si de lo que has pedido extraer, hay algo. Por ejemplo si se pide información de usuarios, y resulta que sólo tiene perfiles en Google Chrome, no veremos una carpeta creada por cada navegador sino solo aquellos de los que el usuario tuviera un perfil. Asimismo, si solo le pedimos que saque el Prefetch de un sistema, por ejemplo, solo nos creará la carpeta Evidencias\Prefetch (y esto siempre y cuando existan ficheros .PF en c:\windows\Prefetch). Lo que es común siempre es el fichero Wintriage.log con la información relativa a la extracción.

La lista de nuevos artefactos forenses que extraemos es la siguiente:

  • Según se indica en este artículo a partir de Windows 11 22H2 se genera un nuevo artefacto de sistema que prueba la ejecución de programas: el PCA o Program Compatibility Assistant. En realidad el servicio pcasvc existe desde Windows 8, pero el contenido en C:\Windows\AppCompat\PCA no se ha generado hasta ahora. En caso de que le hayamos dicho que extraiga Prefetch, buscará el artefacto PCA y creará un directorio en el destino Evidencias\PCA.

  • Si un usuario tiene instalada la aplicación Google Drive, se generará información en formato SQLite en C:\Users\<usuario>\AppData\Local\Google\DriveFS.

  • Logs de IIS: Hasta ahora solo extraía los logs de IIS si este estaba instalado en Windows XP o 2003. Cierto es que ahí la ruta es distinta, pero no sé por qué no había extraído los de IIS (si estos existían). Ahora si hay un IIS en la máquina a la que se le hace Triage, generará un directorio de Logs de IIS en la carpeta Evidencias\Eventos.

  • Logs de Microsoft Exchange: Ahora, si se activa la opción de extraer eventos, en caso de que la máquina tenga instalado Microsoft Exchange, extraemos también los logs del servidor de correo tanto a nivel de Localqueue, los generados por ejecución interactiva con Powershell, los de MessageTracking y los de EWS (Exchange Web Services). Están soportados Exchange 2010, 2016 y 2019. Mil gracias al gran Antonio Sanz por su gran ayuda ;D

  • Aunque ya en versiones anteriores extraíamos logs generados por algunas aplicaciones que permiten acceso y asistencia remota como Teamviewer y Anydesk, fue ver este post y decir, tengo que implementar esto en Wintriage. Ahora es mucho más completo y tengo en cuenta varios clientes VNC referenciados en el mismo.  La localización de los logs será en una carpeta en Evidencias\eventos con el nombre de la aplicación, si es versión instalada y en el usuario si es versión portable.

 

  • Además, y complementario a lo anterior, dado que nos tocó atender un incidente en el que el grupo atacante utilizaba un servicio de acceso remoto libre llamado Rustdesk, ahora extraemos también los logs generados por esta aplicación tanto en la versión instalada como en la portable. La localización de los resultados, al igual que en el item anterior, será en la carpeta Evidencias\eventos para la versión instalable o en la del usuario para la versión portable, que además extraerá el directorio donde se encuentran los ficheros de configuración.

  • Por último, he identificado alguna otra llamada WMI que podría ser interesante y he añadido su ejecución a la sección de comandos ejecutados.

En cuanto a bugfixes también he solucionado varias «cositas». Entre otras:

  • He modificado las opciones CLI para que en caso de que la máquina detectada sea XP/2003 eGarante no esté soportado. Antiguamente no existía esta limitación, pero dado que se utiliza un componente navegador nativo al sistema que no soporta TLS v1.3 (Windows XP y 2003 tienen MUCHOS años ya) y que el servidor API REST de eGarante no soporta peticiones con protocolos más antiguos, para que no funcione, lo elimino. En la versión anterior lo había hecho en modo GUI, pero olvidé hacerlo en modo CLI, así que lo he implementado en esta versión.

 

  • Solucionados varios bugs en Shadow Copies en la extracción de artefactos forenses como activitiescache.db, entre otros.

 

  • Bugs solucionados en la extracción de artefactos forenses de usuario en navegadores como EdgeChromium (detectaba incorrectamente el directorio con perfil Default) u Opera (en este caso no sacaba la Caché del navegador correctamente)

Como siempre, puedes descargar Wintriage desde https://cursos.securizame.com/extra/wintriage.7z  El hash SHA-256 de esta versión es 46ea7f9ba88d90fefc61a665c171faae1962d808ae50b5bf52f1776b24897f53

 


As we anticipated on this post, we were implementing a new version of Wintriage that includes the extraction of more artifacts, fixed some bugs and added new features based on the needs we have had lately, in the resolution of some security incidents with our clients.

So far, Wintriage generated a directory structure with all the artifacts it could pull out, whether or not there was stuff inside. It means, that sometimes, you would go with all your illusion to see if the user had something in a specific artifact and then you would see that the folder was empty, since nothing had been extracted. So the main functionality or change in the operation of Wintriage is that now a folder will only be generated in the extraction directory if there is something that you have requested to extract. For example, if user information is requested, and it only have profiles in Google Chrome, we will not see a folder created by each browser, but only for those where the user had a profile. Likewise, if we only ask it to remove the Prefetch from a system, for example, it will only create the Evidences\Prefetch folder (only as long as there are .PF files in c:\windows\Prefetch). What is always common is the Wintriage.log file with the information related to the extraction.

The list of new forensic artifacts we extract is:

  • As indicated in this article, starting with Windows 11 22H2, a new system artifact is generated that tests the execution of programs: the PCA or Program Compatibility Assistant. Actually the pcasvc service exists since Windows 8, but the content in C:\Windows\AppCompat\PCA has not been generated so far. In case we told it to extract Prefetch, it will search for the PCA artifact and create a directory at the destination Evidences\PCA.

 

  • If a user has the Google Drive app installed, information in SQLite format will be generated in C:\Users\<user>\AppData\Local\Google\DriveFS.

  • IIS logs: Until now, Wintriage only extracted the IIS logs if it was installed on Windows XP or 2003. It is true that the path is different there, but I don’t know why I hadn’t extracted the IIS ones before (if they existed). Now if there is an IIS on the machine being triaged, it will generate an IIS Logs directory in the Evidences\Events folder.

  • Microsoft Exchange logs: If the option to extract events is activated, and if the machine has Microsoft Exchange installed, we also extract the mail server logs, both at the Localqueue level, those generated by interactive execution with Powershell, the MessageTracking and EWS (Exchange Web Services). Exchange 2010, 2016 and 2019 are supported. A thousand thanks to the great Antonio Sanz for his great help ;D

  • Although in previous versions we already extracted logs generated by some applications that allow remote access and assistance such as Teamviewer and Anydesk, we saw this post and said, we have to implement this in Wintriage. Now it is much more complete and we take into account several VNC clients referenced in it. The location of the logs will be in a folder in Evidences\events with the name of the application, if it is an installed version, and in the user folder if it is a portable version.

 

  • In addition, and complementary to the previous point, since we had to deal with an incident in which the threat actors group used a free remote access service called Rustdesk, now we also extract the logs generated by this application, available in both the installed and in the portable version. The location of the results, as in the previous item, will be in the Evidences\events folder for the installable version, or in the user folder for the portable version, which will also extract the directory where the configuration files are located.

  • Finally, we identified some other WMI calls that might be interesting and added their execution to the executed commands section.

About the bugfixes, we also fixed several «little things». Among other:

  • Modified the CLI options so that if the detected machine is XP/2003 eGarante is not supported. In the past, this limitation didn’t exist, but since a browser component native to the system is used that does not support TLS v1.3 (Windows XP and 2003 have MANY years) and that the eGarante REST API server does not support requests with older protocols , so as it doesn’t work, we remove it. In the previous version, we had done it in GUI mode, but we forgot to do it in CLI mode, so we implemented it in this version.

 

  • Fixed several errors in Shadow Copies in the extraction of forensic artifacts such as Activitiescache.db, among others.

 

  • Fixed bugs in the extraction of user forensic artifacts in browsers such as EdgeChromium (it incorrectly detected the directory with the Default profile) or Opera (in this case it did not remove the browser’s Cache correctly)

As always, you can download Wintriage from https://cursos.securizame.com/extra/wintriage.7z. SHA-256 hash for this version tarball is 46ea7f9ba88d90fefc61a665c171faae1962d808ae50b5bf52f1776b24897f53

 

LIST OF PREVIOUS WINTRIAGE UPDATES