> For the complete documentation index, see [llms.txt](https://docs.panther.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.panther.com/ko/pantherflow/best-practices.md).

# PantherFlow 모범 사례

## 개요

{% hint style="info" %}
PantherFlow는 Panther 버전 1.110부터 오픈 베타로 제공되며, 모든 고객이 사용할 수 있습니다. 버그 보고와 기능 요청은 Panther 지원팀에 공유해 주세요.
{% endhint %}

PantherFlow 쿼리 결과가 가능한 한 빨리 반환되도록 하고(검색으로 인해 발생하는 데이터 레이크 비용을 최소화하기 위해), 아래의 모범 사례를 따르는 것이 좋습니다.

이를 적용한 후에도 쿼리가 여전히 느리게 실행된다면:

* 쿼리의 시간 범위를 줄이세요.
* 쿼리가 완료되면 반환된 행 수를 확인하여 얼마나 많은 데이터를 쿼리하는지 파악하세요. 데이터 양이 많다면 시간이 걸리는 것이 예상됩니다.
* 추가 도움이 필요하면 Panther 지원팀에 문의하세요.

## PantherFlow 일반 모범 사례

### **다음을 사용하세요 `limit` 연산자**

다음을 사용하세요 [`limit` 연산자](/ko/pantherflow/operators/limit.md) 를 사용하여 쿼리가 반환할 최대 레코드 수를 지정하세요.

예: `panther_logs.public.aws_alb | limit 100`

### **시간 범위 필터 사용**

다음을 사용하세요 [`where` 연산자](/ko/pantherflow/operators/where.md) 시간 범위로 필터링하려면(아마도 `p_event_time`에 대해). 시간 범위 필터가 있는 [마이크로 파티션](https://docs.snowflake.com/en/user-guide/tables-clustering-micropartitions)에 액세스하므로 결과가 더 빨리 반환됩니다.

예: `panther_logs.public.aws_alb | where p_event_time > time.ago(1d)`

자세한 내용은 [사용 가능한 시간 함수는 여기에서](/ko/pantherflow/functions.md#date-time).

### **사용합니다 `p_any` 필드**

로그 수집 중 Panther는 일반적인 보안 지표를 `p_any` 필드로 추출하며, 이를 통해 모든 데이터 소스에서 속성 이름을 표준화합니다.  `p_any` 필드는 최적화된 열에 저장됩니다. 여러 로그 유형에 대해 다양한 이름의 필드 대신 `p_any` 필드를 쿼리하는 것이 좋습니다.

자세한 내용은 [표준 필드](https://docs.panther.com/search/panther-fields).

예: `panther_logs.public.aws_alb | '10.0.0.0' in p_any_ip_addresses`

### **다음을 사용하세요 `투영` 연산자**

쿼리에 [`투영` 연산자](/ko/pantherflow/operators/project.md) 가 없으면 모든 열을 검색하게 되어 쿼리가 느려질 수 있습니다. 가능하면 `투영` 조사에 필요한 필드만 쿼리하세요.

예: `panther_logs.public.aws_alb | project targetIp, targetPort`

### **결과 요약**

요약은 전체 로그 레코드를 가져오는 쿼리보다 더 빠르게 실행됩니다. 특히 오랜 기간에 걸친 로그를 조사하거나, 조사 중인 시간 범위의 데이터 볼륨이 얼마나 되는지 모를 때 요약을 사용하는 것이 매우 유용합니다.

전체 데이터 세트를 쿼리하는 대신 [`요약` 연산자](/ko/pantherflow/operators/summarize.md)를 사용하면 더 빠르게 실행되고, 다음에 쿼리할 더 좁은 시간 범위를 파악하는 데 도움이 됩니다.

예: `panther_logs.public.aws_alb | summarize count=agg.count() by targetIp`

자세한 내용은 [사용 가능한 집계 함수는 여기에서](/ko/pantherflow/functions.md#aggregations).

### **다음을 사용해 데이터를 초기에 필터링하세요 `where`**

다음을 사용하여 데이터를 필터링하세요 [`where`](/ko/pantherflow/operators/where.md) 다음과 같은 비용이 큰 작업을 수행하기 전에 [`요약`](/ko/pantherflow/operators/summarize.md) 또는 [`조인`](/ko/pantherflow/operators/join.md)이후가 아니라.

예:

```kusto
// 대신:
panther_logs.public.aws_alb 
| summarize agg.count() by actor 
| where actor != nil

// 다음을 사용:
panther_logs.public.aws_alb 
| where actor != nil 
| summarize agg.count() by actor 
```

### **다음을 피하세요 `검색` 연산자**

해당 [`검색` 연산자](/ko/pantherflow/operators/search.md) 는 느려질 수 있으며, 꼭 필요하지 않다면 피해야 합니다. 검색할 텍스트가 포함될 가능성이 있는 열(또는 열들)을 알고 있다면, *모든* 지정된 데이터베이스/테이블의 열을 대상으로 `검색`, 대신 [`where`](/ko/pantherflow/operators/where.md) 와 함께 [`strings.contains()`](https://docs.panther.com/ko/pantherflow/pages/e5c4ab662f13148d5d148a22c398090241e61a1c#strings.contains).

예:

* 대신: `| search 'alice'`
* 사용: `| where strings.contains(name, 'alice')`

## PantherFlow에서 모든 로그를 가장 효과적으로 검색하는 방법

PantherFlow에서 모든 로그를 검색하려면, 다음을 사용하세요 [`union` 연산자](/ko/pantherflow/operators/union.md):

```kusto
union panther_logs.public.*
```

{% hint style="info" %}
에 대한 추가 최적화가 `union` 계획되어 있습니다.
{% endhint %}

검색하려는 값이 나타나야 하는 열(들)을 알고 있다면(예를 들어, 인디케이터 검색—즉, 침해 지표\[IoC]를 [`p_any` 필드](/ko/search/panther-fields.md#indicator-fields)) `union panther_logs.public.*` 검색을 [`투영`](/ko/pantherflow/operators/project.md) 그리고 [`where`](/ko/pantherflow/operators/where.md) 관련 열에서만 IoC를 검색하도록 필터를 추가하여 최적화할 수 있습니다:

```kusto
union panther_logs.public.*
| project p_event_time, p_any_ip_addresses
| where p_event_time > time.ago(1d)
| where p_any_ip_addresses != null
| where 'ip1' in p_any_ip_addresses or 'ip2' in p_any_ip_addresses
```

Panther에서 지표 검색을 수행할 수도 있습니다:

* (권장) 다음 [검색](/ko/search/search-tool.md) 도구: 참조 [침해 지표 검색](/ko/search/search-tool.md#searching-indicators-of-compromise)
  * Search에는 모든 로그를 효율적으로 검색할 수 있게 하는 기본 제공 최적화 기능이 있습니다.
* 해당 `executeIndicatorSearchQuery` [GraphQL API](/ko/panther/api/graphql.md) 엔드포인트: 예시 보기 [여기에서](/ko/panther/api/graphql/data-lake-queries.md#execute-a-search-query)
* [Panther AI](/ko/ai.md): 올바른 [데이터 검색 및 분석 도구](/ko/ai.md#data-search-and-analysis) 가 자동으로 선택됩니다

{% hint style="warning" %}
다음을 사용하여 모든 로그를 쿼리하지 마세요 `panther_views` 데이터베이스는 [사용 중단이 예정되어 있습니다](https://docs.panther.com/search/backend#panther-views).
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.panther.com/ko/pantherflow/best-practices.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
