grr/server/grr_response_server/flows/general/administrative.py
def ProcessResponse(self, client_id, response):
    """Actually processes the contents of the response."""

    downsampled = rdf_client_stats.ClientStats.Downsampled(response)
    if isinstance(client_id, rdfvalue.RDFURN):
      client_id = client_id.Basename()

    if data_store.AFF4Enabled():
      urn = rdf_client.ClientURN(client_id).Add("stats")

      with aff4.FACTORY.Create(
          urn, aff4_stats.ClientStats, token=self.token, mode="w") as stats_fd:
        # Only keep the average of all values that fall within one minute.
        stats_fd.AddAttribute(stats_fd.Schema.STATS, downsampled)

    if data_store.RelationalDBWriteEnabled():
      data_store.REL_DB.WriteClientStats(client_id, downsampled)

    return downsampled
Actually processes the contents of the response.
Actually processes the contents of the response.
Actually processes the contents of the response .
def ProcessResponse(self, client_id, response):
    downsampled = rdf_client_stats.ClientStats.Downsampled(response)
    if isinstance(client_id, rdfvalue.RDFURN):
      client_id = client_id.Basename()
    if data_store.AFF4Enabled():
      urn = rdf_client.ClientURN(client_id).Add("stats")
      with aff4.FACTORY.Create(
          urn, aff4_stats.ClientStats, token=self.token, mode="w") as stats_fd:
        stats_fd.AddAttribute(stats_fd.Schema.STATS, downsampled)
    if data_store.RelationalDBWriteEnabled():
      data_store.REL_DB.WriteClientStats(client_id, downsampled)
    return downsampled
def ProcessResponse ( self , client_id , response ) : downsampled = rdf_client_stats . ClientStats . Downsampled ( response ) if isinstance ( client_id , rdfvalue . RDFURN ) : client_id = client_id . Basename ( ) if data_store . AFF4Enabled ( ) : urn = rdf_client . ClientURN ( client_id ) . Add ( "stats" ) with aff4 . FACTORY . Create ( urn , aff4_stats . ClientStats , token = self . token , mode = "w" ) as stats_fd : stats_fd . AddAttribute ( stats_fd . Schema . STATS , downsampled ) if data_store . RelationalDBWriteEnabled ( ) : data_store . REL_DB . WriteClientStats ( client_id , downsampled ) return downsampled
Actually processes the contents of the response.
Actually processes the contents of the response .
"""Actually processes the contents of the response.""" # Only keep the average of all values that fall within one minute.
self
client_id
response