Beispiel #1
0
def _ReadClientKnowledgeBase(client_id, allow_uninitialized=False, token=None):
  if data_store.RelationalDBEnabled():
    client = data_store.REL_DB.ReadClientSnapshot(client_id)
    return artifact.GetKnowledgeBase(
        client, allow_uninitialized=allow_uninitialized)
  else:
    client = aff4.FACTORY.Open(client_id, token=token)
    return artifact.GetArtifactKnowledgeBase(
        client, allow_uninitialized=allow_uninitialized)
Beispiel #2
0
def _ReadClientKnowledgeBase(client_id, allow_uninitialized=False):
  client = data_store.REL_DB.ReadClientSnapshot(client_id)
  return artifact.GetKnowledgeBase(
      client, allow_uninitialized=allow_uninitialized)