<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic XQL help to detect when a process is stop or killed and by whom in Cortex XDR Discussions</title>
    <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/xql-help-to-detect-when-a-process-is-stop-or-killed-and-by-whom/m-p/1236409#M8681</link>
    <description>&lt;P&gt;Hello community,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm trying to create a XQL Query to detect whenever a user is stopping a particular service (via services.msc, cmd, powershell, WMI or any other way), but I can not do it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to detect the user that send the stop service command, or the user that is killing the process.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is it any way to make this query?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is the closest query that I get:&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;dataset = xdr_data | filter agent_hostname ="TEST_COMPUTER" and event_sub_type = ENUM.PROCESS_STOP and actor_process_image_name="PanGPS.exe"&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But in this query, we only get the user that stopped the process (the service user), but not the user that sent the service stop or process kill command, so we cannot determine whether the service is being stopped regularly (system shutdown) or is being stopped by the user.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you help, please?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much,&lt;BR /&gt;kind regards.&lt;/P&gt;</description>
    <pubDate>Thu, 21 Aug 2025 07:55:09 GMT</pubDate>
    <dc:creator>jrlambea</dc:creator>
    <dc:date>2025-08-21T07:55:09Z</dc:date>
    <item>
      <title>XQL help to detect when a process is stop or killed and by whom</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/xql-help-to-detect-when-a-process-is-stop-or-killed-and-by-whom/m-p/1236409#M8681</link>
      <description>&lt;P&gt;Hello community,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm trying to create a XQL Query to detect whenever a user is stopping a particular service (via services.msc, cmd, powershell, WMI or any other way), but I can not do it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to detect the user that send the stop service command, or the user that is killing the process.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is it any way to make this query?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is the closest query that I get:&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;dataset = xdr_data | filter agent_hostname ="TEST_COMPUTER" and event_sub_type = ENUM.PROCESS_STOP and actor_process_image_name="PanGPS.exe"&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But in this query, we only get the user that stopped the process (the service user), but not the user that sent the service stop or process kill command, so we cannot determine whether the service is being stopped regularly (system shutdown) or is being stopped by the user.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you help, please?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much,&lt;BR /&gt;kind regards.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Aug 2025 07:55:09 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/xql-help-to-detect-when-a-process-is-stop-or-killed-and-by-whom/m-p/1236409#M8681</guid>
      <dc:creator>jrlambea</dc:creator>
      <dc:date>2025-08-21T07:55:09Z</dc:date>
    </item>
    <item>
      <title>Re: XQL help to detect when a process is stop or killed and by whom</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/xql-help-to-detect-when-a-process-is-stop-or-killed-and-by-whom/m-p/1236519#M8686</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/306759"&gt;@jrlambea&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please try with the following and let me know if this works&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ataset = xdr_data | filter actor_effective_username != "nt_authority/system" and agent_hostname ="YOUR_HOSTNAME_HERE" and event_sub_type = ENUM.PROCESS_STOP and actor_process_image_name="YOUR_PROCESS_HERE" &lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you feel this has answered your query, please let us know by clicking like and on "mark this as a Solution". Thank you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;KR,&lt;/P&gt;
&lt;P&gt;Luis&lt;/P&gt;</description>
      <pubDate>Fri, 22 Aug 2025 13:04:54 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/xql-help-to-detect-when-a-process-is-stop-or-killed-and-by-whom/m-p/1236519#M8686</guid>
      <dc:creator>eluis</dc:creator>
      <dc:date>2025-08-22T13:04:54Z</dc:date>
    </item>
    <item>
      <title>Re: XQL help to detect when a process is stop or killed and by whom</title>
      <link>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/xql-help-to-detect-when-a-process-is-stop-or-killed-and-by-whom/m-p/1236930#M8707</link>
      <description>&lt;P&gt;Hi &lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/190764"&gt;@eluis&lt;/a&gt;!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much for your response. The current query doesn't meet our needs because when the process is stopped via the services.msc console, the user that appears in the actor_effective_username field is always nt_authority/system (the user configured for the service).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could we check if a user opened the service.msc console on the same machine a few minutes beforehand? I'm not sure if this is feasible in XQL, as I'm quite neophyte to it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Kind regards.&lt;/P&gt;</description>
      <pubDate>Fri, 29 Aug 2025 07:38:13 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/cortex-xdr-discussions/xql-help-to-detect-when-a-process-is-stop-or-killed-and-by-whom/m-p/1236930#M8707</guid>
      <dc:creator>jrlambea</dc:creator>
      <dc:date>2025-08-29T07:38:13Z</dc:date>
    </item>
  </channel>
</rss>

