AIDE(Advanced Intrusion Detection Environment)のログを収集する

パーサーのバージョン: 1.0

以下でサポートされています。

このドキュメントでは、Bindplane を使用して AIDE(Advanced Intrusion Detection Environment)ログを Google Security Operations に取り込む方法について説明します。AIDE は、Linux/Unix システム上のファイルへの変更を検出するファイル整合性モニタリング ツールです。

始める前に

次の前提条件を満たしていることを確認してください。

  • Google SecOps インスタンス
  • AIDE バージョン 0.18 以降を実行している systemd を搭載した Linux ホスト(JSON 形式のサポート用)
  • プロキシの背後で実行している場合は、Bindplane エージェントの要件に従ってファイアウォール ポートが開いていることを確認します。
  • AIDE 構成ファイルへの特権アクセス

Bindplane エージェントの Google SecOps 認証情報を取得する

Bindplane エージェントを Google SecOps に対して認証するには、次のいずれかの方法を選択します。

  • 新規デプロイ: Chronicle API を使用します(オプション 1)。
  • 以前のデプロイ: 2027 年 7 月 20 日に Ingestion API が廃止されるまで、取り込み認証ファイル(オプション 2)を引き続き使用します。
  1. Google Cloud コンソールにログインし、Google SecOps インスタンスにリンクされている Google Cloud プロジェクトを選択します。
  2. [IAM と管理> サービス アカウント] に移動します。
  3. [サービス アカウントを作成] をクリックします。
  4. 次の構成情報を指定します。
    • サービス アカウント名: アカウントの名前を入力します(例: bindplane-ingest)。
    • サービス アカウントの説明: 説明を入力します(例: Bindplane agent log ingestion)。
  5. [作成して続行] をクリックします。
  6. [このサービス アカウントにプロジェクトへのアクセスを許可する] セクションで、[ロールを選択] をクリックし、[Chronicle 編集者] を選択します。
  7. [続行] をクリックして [完了] をクリックします。
  8. 作成したサービス アカウントをクリックし、[キー] タブに移動します。
  9. [鍵を追加] > [新しい鍵を作成] の順にクリックします。
  10. [JSON] を選択し、[作成] をクリックします。キーファイルがパソコンにダウンロードされます。
  11. 鍵ファイルを ingestion-auth.json として Bindplane コレクタ ディレクトリ(Linux の場合は /opt/observiq-otel-collector/ingestion-auth.json、Windows の場合は C:\Program Files\observIQ OpenTelemetry Collector\ingestion-auth.json)に保存するか、config.yaml の creds_file_path を更新して、保存先のパスと一致させます。
  12. [IAM と管理] > [設定] に移動し、[プロジェクト番号] をコピーします。エクスポーターの構成に必要になります。

オプション 2: 取り込み認証ファイルをダウンロードする(レガシー)

  1. Google SecOps コンソールにログインします。
  2. [SIEM 設定] > [収集エージェント] に移動します。
  3. 取り込み認証ファイルをダウンロードします。
  4. Bindplane エージェントがインストールされるシステムにファイルを安全に保存します。

Google SecOps のお客様 ID を取得する

  1. Google SecOps コンソールにログインします。
  2. [SIEM 設定] > [プロファイル] に移動します。
  3. [組織の詳細情報] セクションから [お客様 ID] をコピーして保存します。

Bindplane エージェントをインストールする

次の手順に沿って、Linux オペレーティング システムに Bindplane エージェントをインストールします。

Linux へのインストール

  1. root 権限または sudo 権限でターミナルを開きます。
  2. 次のコマンドを実行します。

    sudo sh -c "$(curl -fsSlL https://github.com/observiq/bindplane-agent/releases/latest/download/install_unix.sh)" install_unix.sh
    

その他のインストール リソース

その他のインストール オプションについては、こちらのインストール ガイドをご覧ください。

Syslog を取り込んで Google SecOps に送信するように Bindplane エージェントを構成する

  1. 構成ファイルにアクセスします。

    • config.yaml ファイルを見つけます。通常、Linux の /opt/observiq-otel-collector/ ディレクトリにあります。
    • テキスト エディタ(nano や vi など)を使用してファイルを開きます。
  2. config.yaml ファイルを次のように編集します。

    receivers:
      udplog:
        # Replace the port and IP address as required
        listen_address: "0.0.0.0:514"
    
    exporters:
      chronicle/chronicle_w_labels:
        protocol: https
        # Region of your instance, for example us, europe, asia-southeast1
        location: <LOCATION>
        # Project number of the Google Cloud project linked to the instance
        project: '<PROJECT_NUMBER>'
        compression: gzip
        # Adjust the path to the credentials file you downloaded in Step 1
        creds_file_path: '/path/to/ingestion-authentication-file.json'
        # Replace with your actual customer ID from Step 2
        customer_id: <CUSTOMER_ID>
        endpoint: chronicle.googleapis.com
        # Add optional ingestion labels for better organization
        log_type: 'AIDE'
        raw_log_field: body
        ingestion_labels:
    
    service:
      pipelines:
        logs/source0__chronicle_w_labels-0:
          receivers:
            - udplog
          exporters:
            - chronicle/chronicle_w_labels
    
    • 自社のインフラストラクチャでの必要性に応じて、ポートと IP アドレスを置き換えます。
    • <LOCATION> は、Google SecOps インスタンスのリージョン(us、europe、asia-southeast1 など)に置き換えます。エクスポータは、chronicle.googleapis.com の先頭にこの値を付加します。
    • <PROJECT_NUMBER> は、[IAM と管理>設定] のプロジェクト番号に置き換えます。
    • <CUSTOMER_ID> は、実際のお客様 ID に置き換えます。
    • /path/to/ingestion-authentication-file.json を、ステップ 1 でサービス アカウント キーファイル(オプション 1)を保存したファイルパスに更新します。

以前の Ingestion API エクスポータ

  • オプション 2 の取り込み認証ファイルを使用する場合は、exporters ブロックを次のように置き換えます。creds_file_path を取り込み認証ファイルのパスに設定します。インスタンスが米国以外にある場合は、malachiteingestion-pa.googleapis.com をリージョン エンドポイント(europe-malachiteingestion-pa.googleapis.com など)に置き換えます。

    exporters:
      chronicle/chronicle_w_labels:
        compression: gzip
        # Adjust the path to the credentials file you downloaded in Step 1
        creds_file_path: '/path/to/ingestion-authentication-file.json'
        # Replace with your actual customer ID from Step 2
        customer_id: <CUSTOMER_ID>
        endpoint: malachiteingestion-pa.googleapis.com
        # Add optional ingestion labels for better organization
        log_type: 'AIDE'
        raw_log_field: body
        ingestion_labels:
    

Bindplane エージェントを再起動して変更を適用する

  • Linux で Bindplane エージェントを再起動するには、次のコマンドを実行します。

    sudo systemctl restart observiq-otel-collector
    

AIDE で Syslog 転送を構成する

  1. AIDE 構成ファイルを開きます。

    sudo vi /etc/aide/aide.conf
    
  2. [レポート] セクションに移動します。

  3. 次の構成を追加します。

    • report_level: 「list_entries」と入力します。
    • report_format: json(AIDE 0.18 以降の場合)または plain を入力します。
    • report_url: 「syslog:authpriv」と入力します。

    構成の例:

    ```ini
    report_level=list_entries
    report_format=json
    report_url=syslog:authpriv
    ```
    
  4. 構成を保存します。

  5. AIDE ログを Bindplane エージェントに転送するように rsyslog を構成します。rsyslog 構成を開きます。

    sudo vi /etc/rsyslog.d/aide-forward.conf
    
  6. authpriv ファシリティ ログを Bindplane エージェントに転送するには、次の構成を追加します。

    authpriv.* @<BINDPLANE_AGENT_IP>:514
    
    • <BINDPLANE_AGENT_IP> は、Bindplane エージェント ホストの IP アドレスに置き換えます。
    • UDP の場合は @、TCP 転送の場合は @@ を使用します。
  7. rsyslog を再起動します。

    sudo systemctl restart rsyslog
    
  8. 新規インストールの場合、AIDE データベースを初期化します。

    sudo aide --init
    sudo mv /var/lib/aide/aide.db.new /var/lib/aide/aide.db
    
  9. 構成をテストします。

    sudo aide --check
    
  10. cron を使用して自動チェックを設定します。

    sudo crontab -e
    
  11. 次の行を追加して、毎日午前 4 時 5 分に AIDE を実行します。

    05 4 * * * root /usr/sbin/aide --check
    

UDM マッピング テーブル

ログフィールド UDM マッピング ロジック
added_label principal.asset.attribute.labels 統合済み
changed_label principal.asset.attribute.labels 統合済み
old_acl_label principal.asset.attribute.labels 統合済み
old_md5_label principal.asset.attribute.labels 統合済み
old_perms_label principal.asset.attribute.labels 統合済み
old_sha256_label principal.asset.attribute.labels 統合済み
old_ts_label principal.asset.attribute.labels 統合済み
removed_label principal.asset.attribute.labels 統合済み
total_label principal.asset.attribute.labels 統合済み
file_path principal.file.full_path 直接マッピングされます。
path principal.file.full_path 直接マッピングされます。
old_size principal.file.size 直接マッピングされます。
host principal.hostname 直接マッピングされます。
sr security_result 統合済み
new_acl_label target.asset.attribute.labels 統合済み
new_md5_label target.asset.attribute.labels 統合済み
new_perms_label target.asset.attribute.labels 統合済み
new_sha256_label target.asset.attribute.labels 統合済み
new_ts_label target.asset.attribute.labels 統合済み
path target.file.full_path 直接マッピングされます。
new_size target.file.size 直接マッピングされます。
なし metadata.event_type 定数: GENERIC_EVENT
なし metadata.product_name 定数: AIDE
なし metadata.vendor_name 定数: AIDE
なし principal.application 定数: aide
なし principal.file.size 定数: sizedata
なし target.file.size 定数: sizedata_target
total_files", "added_files", "removed_files", "changed_files", "old_timestamp", "old_perms", "old_sha256", "old_md5", and "old_acl principal.asset.attribute.labels 変更履歴からマッピング
new_timestamp", "new_perms", "new_sha256", "new_md5", and "new_acl target.asset.attribute.labels 変更履歴からマッピング

変更ログ

このパーサーの変更ログを表示する

さらにサポートが必要な場合 コミュニティ メンバーや Google SecOps のプロフェッショナルから回答を得ることができます。