# Wiz API

## 개요

Panther는 가져올 수 있습니다 [Wiz](https://www.wiz.io/) [감사](#wiz.audit), [이슈](#wiz.issues)및 [취약점 발견](#wiz.vulnerabilityfinding) 로그를 쿼리하여 [Wiz API](https://win.wiz.io/reference/prerequisites).

{% hint style="info" %}
다른 유형의 Wiz 로그를 수집하려면 추가로 또는 대신 [Wiz Webhook 통합](https://docs.panther.com/data-onboarding/supported-logs/wiz/webhook)을 사용할 수 있습니다. 이 통합을 통해 사용할 수 있는 Wiz.Issues 이벤트와 [Wiz API 통합](https://docs.panther.com/data-onboarding/supported-logs/wiz/api) 을 통해 사용할 수 있는 Wiz.IssuesWebhook 이벤트는 약간 다릅니다.
{% endhint %}

## Panther에 Wiz 로그를 온보딩하는 방법

### 사전 요구 사항

* 이 통합을 설정하는 사용자는 Wiz 테넌트에 접근할 수 있어야 하며 서비스 계정을 생성할 수 있는 권한이 있는 Wiz 역할을 보유해야 합니다(예: `Global Admin`).

### 1단계: Wiz API 엔드포인트 URL 가져오기

Wiz GraphQL API에는 단일 엔드포인트(`https://api.<TENANT_DATA_CENTER>.app.wiz.io/graphql`)가 있으며, 여기서 `<TENANT_DATA_CENTER>` 는 테넌트가 위치한 Wiz 지역 데이터 센터입니다. 예: `us1`, `us2`, `eu1` 또는 `eu2`. 엔드포인트는 수행 중인 작업과 관계없이 동일합니다.

GraphQL 엔드포인트를 가져오려면:

1. Wiz 콘솔의 오른쪽 상단에서 사용자 아이콘 > **사용자 설정** (또는 이 [직접 링크](https://app.wiz.io/user/profile)).
2. 왼쪽에서 **테넌트** (또는 이 [직접 링크](https://app.wiz.io/user/tenant)).
3. 를 클릭한 다음 **API 엔드포인트 URL** 을 복사하여 이후 단계에서 필요하므로 안전한 위치에 저장합니다.

### 2단계: Wiz에서 서비스 계정 생성

1. Wiz 대시보드에서 다음으로 이동합니다. **설정** > **액세스 관리** > **서비스 계정**.
2. 을 클릭합니다 **서비스 계정 추가**.
3. 에서 **새 서비스 계정** 양식에서 다음 필드를 채웁니다:
   * **Name**: 서비스 계정의 설명이 되는 이름을 입력합니다. 예: `Panther 통합`.
   * **유형**:  **Custom Integration (GraphQL API)**.
   * **프로젝트** (선택 사항): 이 서비스 계정이 접근할 수 있는 하나 이상의 프로젝트를 선택합니다.
     * 하나 이상의 프로젝트를 선택하면 다음을 조회할 수 없게 됩니다. [감사](#wiz.audit) 로그.
   * **API 스코프**:
     * 선택 **read:resources**.
     * Panther로 수집하려는 Wiz 로그 유형에 대해 아래 표의 **서비스 계정에 필요한 API 스코프** 에 나열된 스코프를 선택합니다.
4. 을 클릭합니다 **서비스 계정 추가**.
5. 복사 **클라이언트 시크릿**를 선택하고, 이후 단계에서 필요하므로 안전한 위치에 저장합니다. 이 단계가 끝나면 이 값을 볼 수 없습니다.
6. 복사 **Client ID**를 선택하고, 이후 단계에서 필요하므로 안전한 위치에 저장합니다.

#### 서비스 계정에 필요한 API 스코프

<table><thead><tr><th width="199">로그 유형</th><th width="264">쿼리에 필요한 스코프</th><th>참고</th></tr></thead><tbody><tr><td><a href="#wiz.audit">감사</a></td><td>admin:audit</td><td>이 권한은 하나 이상의 <strong>프로젝트</strong> 를 서비스 계정에 대해 선택하지 않은 경우에만 표시됩니다</td></tr><tr><td><a href="#wiz.issues">이슈</a></td><td>read:issues</td><td></td></tr><tr><td><a href="#wiz.vulnerabilityfinding">VulnerabilityFinding</a></td><td>read:vulnerabilities</td><td></td></tr></tbody></table>

### 3단계: Panther에 새 Wiz 로그 소스 생성

1. Panther Console의 왼쪽 탐색 표시줄에서 **구성** > **로그 소스**.
2. 을 클릭합니다 **Create New.**
3. "Wiz"를 검색한 다음 해당 타일을 클릭합니다.
4. 슬라이드아웃 패널의 오른쪽 상단에서 **Start Setup**.

   <figure><img src="https://2400888838-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LgdiSWdyJcXPahGi9Rs-2910905616%2Fuploads%2Fgit-blob-3e093cf49bbe1f2e4677598993d8af6e80839bbe%2FScreenshot%202024-06-13%20at%2011.10.38%20AM.png?alt=media" alt="A page in the Panther console with the trail Configure > Log Sources > Add New Source is shown, with a slide-out panel expanded with the title Wiz. An arrow is drawn to a &#x22;Start Setup&#x22; button."><figcaption></figcaption></figure>
5. 에서 **구성** 화면에서 양식을 채웁니다:
   * **Name**: 소스의 설명이 되는 이름을 입력합니다. 예: `내 Wiz 로그`.
   * **프로젝트 ID** (선택 사항): 로그를 가져올 프로젝트의 ID를 입력합니다. 이 필드를 비워 두면 Panther는 모든 프로젝트의 로그를 가져옵니다. Wiz 콘솔에서 특정 프로젝트의 ID를 찾으려면:
     1. 을 클릭합니다 **설정** > **프로젝트**.
     2. 프로젝트 행의 오른쪽에서 점 3개 아이콘 > **프로젝트 ID**를 클릭합니다. ID가 클립보드에 복사됩니다.
   * **모니터링할 로그 유형 선택**: 모든 Wiz 로그 유형이 미리 채워집니다.
6. 을 클릭합니다 **Setup**.
7. 에서 **자격 증명 설정** 페이지에서 양식을 작성합니다:
   * **토큰 URL**: Wiz API 토큰 URL을 입력합니다. 이 값은 Wiz 계정의 ID 공급자에 따라 다릅니다:
     * Amazon Cognito: 다음을 입력 `https://auth.app.wiz.io/oauth/token`.
     * Auth0: 다음을 입력 `https://auth.wiz.io/oauth/token`.
       * Wiz는 2022년 12월에 ID 공급자로서 Auth0 지원을 종료했습니다.
   * **API 엔드포인트**: **API 엔드포인트 URL** Wiz에서 가져온 값을 입력합니다.
   * **Client ID**: **Client ID** Wiz에서 생성한 값을 입력합니다.
   * **Client Secret:** 다음을 입력합니다. **클라이언트 시크릿** Wiz에서 생성한 값을 입력합니다.
8. 을 클릭합니다 **Setup**. 그러면 성공 화면으로 이동합니다:

   <figure><img src="https://2400888838-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LgdiSWdyJcXPahGi9Rs-2910905616%2Fuploads%2Fgit-blob-e55cedf82c6a6adc66ec5c14ebdcb164c3b1dcca%2FScreenshot%202023-08-03%20at%204.33.30%20PM.png?alt=media" alt="The success screen reads, &#x22;Everything looks good! Panther will now automatically pull &#x26; process logs from your account&#x22;" width="281"><figcaption></figcaption></figure>

   * 선택적으로 하나 이상의 [디택션 팩](https://docs.panther.com/detections/panther-managed/packs).
   * the **이벤트가 처리되지 않을 때 알러트 트리거** 설정의 기본값은 **YES**. 이 기능을 활성화한 상태로 두는 것을 권장합니다. 그러면 일정 기간 후 로그 소스에서 데이터가 더 이상 흐르지 않으면 알림을 받게 됩니다. 기간은 구성 가능하며 기본값은 24시간입니다.

     <figure><img src="https://2400888838-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LgdiSWdyJcXPahGi9Rs-2910905616%2Fuploads%2Fgit-blob-c48119abd559990173004bde99ff4907fdd2ded2%2FScreenshot%202023-08-03%20at%204.26.54%20PM.png?alt=media" alt="The &#x22;Trigger an alert when no events are processed&#x22; toggle is set to YES. The &#x22;How long should Panther wait before it sends you an alert that no events have been processed&#x22; setting is set to 1 Day" width="320"><figcaption></figcaption></figure>

## Panther에서 관리하는 탐지

자세한 내용은 [Panther에서 관리하는](https://docs.panther.com/ko/detections/panther-managed) Wiz용 룰은 [panther-analysis GitHub 저장소](https://github.com/panther-labs/panther-analysis/tree/main/rules/wiz_rules).

## 지원되는 로그 유형

### Wiz.Audit

감사 로그는 로그인, 로그아웃, 사용자 업데이트와 같은 Wiz의 주요 이벤트를 기록합니다. 감사 로그는 주로 잠재적으로 의심스러운 활동을 조사하거나 오류를 진단 및 문제 해결하는 데 사용됩니다.

참조: <https://win.wiz.io/reference/audit-log>

```yaml
schema: Wiz.Audit
description: 감사 로그는 로그인, 로그아웃, 사용자 업데이트와 같은 Wiz의 주요 이벤트를 기록합니다. 감사 로그는 주로 잠재적으로 의심스러운 활동을 조사하거나 오류를 진단 및 문제 해결하는 데 사용됩니다.
referenceURL: https://win.wiz.io/reference/audit-log
필드:
    - name: id
      필수: true
      description: 감사 로그 항목의 고유 식별자.
      유형: string
    - name: action
      필수: true
      description: 수행된 작업.
      유형: string
    - 이름: requestId
      description: 요청의 고유 식별자.
      유형: string
    - 이름: status
      description: 감사 로그 이벤트의 상태.
      유형: string
    - name: timestamp
      필수: true
      description: 이벤트의 타임스탬프.
      유형: timestamp
      timeFormats:
        - rfc3339
      isEventTime: true
    - name: actionParameters
      description: 작업과 관련된 매개변수.
      유형: json
    - name: userAgent
      description: 사용자 에이전트 문자열.
      유형: string
    - name: sourceIP
      description: 원본 IP 주소.
      유형: string
      indicators:
        - ip
    - name: serviceAccount
      description: 작업과 연결된 서비스 계정.
      type: object
      필드:
        - name: id
          필수: true
          description: 서비스 계정의 ID.
          유형: string
          indicators:
            - actor_id
        - name: name
          description: 서비스 계정의 이름.
          유형: string
    - name: user
      description: 해당하는 경우 작업과 연결된 사용자.
      type: object
      필드:
        - name: id
          필수: true
          description: 사용자의 ID.
          유형: string
          indicators:
            - actor_id
        - name: name
          description: 사용자의 이름.
          유형: string
          indicators:
            - username
```

### Wiz.Issues

이슈 로그는 취약점 발견 및 보안 사고와 같이 이슈와 관련된 Wiz의 주요 이벤트를 기록합니다. 보안 취약점과 사고를 추적, 관리 및 수정하는 데 사용됩니다.

참조: <https://win.wiz.io/reference/issues-query>

```yaml
schema: Wiz.Issues
description: 이슈 로그는 취약점 발견 및 보안 사고와 같이 이슈와 관련된 Wiz의 주요 이벤트를 기록합니다. 보안 취약점과 사고를 추적, 관리 및 수정하는 데 사용됩니다.
referenceURL: https://win.wiz.io/reference/issues-query
필드:
    - name: id
      필수: true
      description: 이슈의 고유 식별자.
      유형: string
    - name: sourceRule
      description: 이슈의 소스 룰.
      유형: json
    - name: createdAt
      필수: true
      description: 이슈의 생성 타임스탬프.
      유형: timestamp
    - name: updatedAt
      description: 이슈의 마지막 업데이트 타임스탬프.
      유형: timestamp
    - name: dueAt
      description: 이슈의 기한 타임스탬프.
      유형: timestamp
    - name: type
      description: 이슈의 유형.
      유형: string
    - name: resolvedAt
      description: 이슈가 해결된 타임스탬프.
      유형: timestamp
    - name: statusChangedAt
      description: 이슈의 상태가 변경된 타임스탬프.
      유형: timestamp
    - name: projects
      description: 이슈와 연결된 프로젝트.
      유형: array
      요소:
        type: object
        필드:
            - name: id
              description: 프로젝트의 고유 식별자.
              유형: string
            - name: name
              description: 프로젝트의 이름.
              유형: string
            - name: slug
              description: 프로젝트의 슬러그.
              유형: string
            - name: businessUnit
              description: 프로젝트의 비즈니스 단위.
              유형: string
            - name: riskProfile
              description: 프로젝트의 위험 프로필.
              유형: json
    - 이름: status
      description: 이슈의 상태.
      유형: string
    - name: severity
      description: 이슈의 심각도.
      유형: string
    - name: entitySnapshot
      description: 이슈와 관련된 엔터티의 스냅샷.
      type: object
      필드:
        - name: id
          description: 엔터티 스냅샷의 고유 식별자.
          유형: string
        - name: type
          description: 엔터티 스냅샷의 유형.
          유형: string
        - name: nativeType
          description: 엔터티 스냅샷의 네이티브 유형.
          유형: string
        - name: name
          description: 엔터티 스냅샷의 이름.
          유형: string
        - 이름: status
          description: 엔터티 스냅샷의 상태.
          유형: string
        - name: cloudPlatform
          description: 엔터티 스냅샷의 클라우드 플랫폼.
          유형: string
        - name: cloudProviderURL
          description: 엔터티 스냅샷의 클라우드 제공자 URL.
          유형: string
        - name: providerId
          description: 엔터티 스냅샷의 제공자 ID.
          유형: string
        - name: region
          description: 엔터티 스냅샷의 지역.
          유형: string
        - name: resourceGroupExternalId
          description: 리소스 그룹의 외부 ID.
          유형: string
        - name: subscriptionExternalId
          description: 구독의 외부 ID.
          유형: string
        - name: subscriptionName
          description: 구독의 이름.
          유형: string
        - name: subscriptionTags
          description: 구독의 태그.
          유형: json
        - name: tags
          description: 엔터티 스냅샷의 태그.
          유형: json
        - name: externalId
          description: 엔터티 스냅샷의 외부 ID.
          유형: string
    - name: serviceTickets
      description: 이슈와 관련된 서비스 티켓.
      유형: json
    - 이름: notes
      description: 이슈와 관련된 추가 메모.
      유형: json
```

### Wiz.VulnerabilityFinding

취약점 발견 로그는 Wiz에서 탐지된 보안 취약점에 대한 정보를 기록하며, 취약점, 영향을 받는 자산, 수정 단계에 대한 세부 정보를 포함합니다.

참조: <https://win.wiz.io/reference/vulnerability-finding>

```yaml
schema: Wiz.VulnerabilityFinding
description: 취약점 발견 로그는 Wiz에서 탐지된 보안 취약점에 대한 정보를 기록하며, 취약점, 영향을 받는 자산, 수정 단계에 대한 세부 정보를 포함합니다.
referenceURL: https://win.wiz.io/reference/vulnerability-finding
필드:
    - name: id
      필수: true
      description: 취약점 발견의 고유 식별자.
      유형: string
    - name: portalUrl
      description: 취약점 발견의 포털 URL.
      유형: string
      indicators:
        - url
    - name: name
      description: 취약점의 이름.
      유형: string
    - name: CVEDescription
      description: 취약점의 CVE 설명.
      유형: string
    - name: CVSSSeverity
      description: 취약점의 CVSS 심각도.
      유형: string
    - name: score
      description: 취약점의 점수.
      type: float
    - name: exploitabilityScore
      description: 취약점의 악용 가능성 점수.
      type: float
    - name: impactScore
      description: 취약점의 영향 점수.
      type: float
    - name: dataSourceName
      description: 취약점 발견의 데이터 소스 이름.
      유형: string
    - name: hasExploit
      description: 취약점에 익스플로잇이 있는지 여부를 나타냅니다.
      유형: boolean
    - name: hasCisaKevExploit
      description: 취약점에 CISA/KEV 익스플로잇이 있는지 여부를 나타냅니다.
      유형: boolean
    - 이름: status
      description: 취약점 발견의 상태.
      유형: string
    - name: vendorSeverity
      description: 취약점의 공급자 심각도.
      유형: string
    - name: firstDetectedAt
      description: 취약점이 처음 탐지된 타임스탬프.
      유형: timestamp
      timeFormats:
        - rfc3339
    - name: lastDetectedAt
      description: 취약점이 마지막으로 탐지된 타임스탬프.
      유형: timestamp
      timeFormats:
        - rfc3339
    - name: resolvedAt
      description: 취약점이 해결된 타임스탬프.
      유형: timestamp
    - name: description
      description: 취약점의 설명.
      유형: string
    - name: remediation
      description: 취약점의 수정 단계.
      유형: string
    - name: detailedName
      description: 취약점의 상세 이름.
      유형: string
    - name: version
      description: 취약점에 의해 영향을 받는 버전.
      유형: string
    - name: fixedVersion
      description: 취약점이 수정된 버전.
      유형: string
    - name: detectionMethod
      description: 취약점을 탐지하는 데 사용된 방법.
      유형: string
    - name: link
      description: 취약점과 관련된 링크.
      유형: string
      indicators:
        - url
    - name: locationPath
      description: 취약점의 위치 경로.
      유형: string
    - name: resolutionReason
      description: 취약점이 해결된 이유.
      유형: string
    - name: epssSeverity
      description: 취약점의 EPSS 심각도.
      유형: string
    - name: epssPercentile
      description: 취약점의 EPSS 백분위수.
      type: float
    - name: epssProbability
      description: 취약점의 EPSS 확률.
      type: float
    - name: validatedInRuntime
      description: 취약점이 런타임에서 검증되었는지 여부를 나타냅니다.
      유형: string
    - name: layerMetadata
      description: 취약점의 레이어 메타데이터.
      유형: json
    - name: projects
      description: 취약점 발견과 관련된 프로젝트.
      유형: array
      요소:
        type: object
        필드:
            - name: id
              description: 프로젝트의 고유 식별자.
              유형: string
            - name: name
              description: 프로젝트의 이름.
              유형: string
            - name: slug
              description: 프로젝트의 슬러그.
              유형: string
            - name: businessUnit
              description: 프로젝트의 비즈니스 단위.
              유형: string
            - name: riskProfile
              description: 프로젝트의 위험 프로필.
              유형: json
    - name: ignoreRules
      description: 취약점에 대한 무시 룰.
      유형: json
    - name: vulnerableAsset
      description: 취약점 발견과 관련된 취약한 자산.
      type: object
      필드:
        - name: id
          description: 취약한 자산의 고유 식별자.
          유형: string
        - name: type
          description: 취약한 자산의 유형.
          유형: string
        - name: name
          description: 취약한 자산의 이름.
          유형: string
        - name: region
          description: 취약한 자산의 지역.
          유형: string
        - name: providerUniqueId
          description: 제공자의 고유 식별자.
          유형: string
        - name: cloudProviderURL
          description: 취약한 자산의 클라우드 제공자 URL.
          유형: string
          indicators:
            - url
        - name: cloudPlatform
          description: 취약한 자산의 클라우드 플랫폼.
          유형: string
        - 이름: status
          description: 취약한 자산의 상태.
          유형: string
        - name: subscriptionName
          description: 구독의 이름.
          유형: string
        - name: subscriptionExternalId
          description: 구독의 외부 ID.
          유형: string
        - name: subscriptionId
          description: 구독의 ID.
          유형: string
        - name: tags
          description: 취약한 자산의 태그.
          유형: json
        - name: hasLimitedInternetExposure
          description: 취약한 자산이 제한된 인터넷 노출을 갖는지 여부를 나타냅니다.
          유형: boolean
        - name: hasWideInternetExposure
          description: 취약한 자산이 광범위한 인터넷 노출을 갖는지 여부를 나타냅니다.
          유형: boolean
        - name: isAccessibleFromVPN
          description: 취약한 자산에 VPN으로 접근할 수 있는지 여부를 나타냅니다.
          유형: boolean
        - name: isAccessibleFromOtherVnets
          description: 취약한 자산에 다른 VNet에서 접근할 수 있는지 여부를 나타냅니다.
          유형: boolean
        - name: isAccessibleFromOtherSubscriptions
          description: 취약한 자산에 다른 구독에서 접근할 수 있는지 여부를 나타냅니다.
          유형: boolean
        - name: operatingSystem
          description: 취약한 자산의 운영 체제.
          유형: string
        - name: ipAddresses
          description: 취약한 자산의 IP 주소.
          유형: array
          요소:
            유형: string
            indicators:
                - ip
```


---

# Agent Instructions: 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/data-onboarding/supported-logs/wiz/api.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.
