Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

No "real" capture of HTTP:BL response

オープン
#3,465 コメント 8 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
35/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
cpp
領域
security

調査の方向性

まず、リンク先の該当箇所にある src/operators/rbl.cc を読み、現在の動作を過去のスニペットと比較します。RBL 応答とトランザクションキャプチャがどのように表現されているかを追跡します。完了とは、オペレーターが元の IP だけでなく、スコアベースのフィルタリングに必要な実際の応答データを公開することです。

索引モデルが issue の本文から書いたものです。

説明

Unfortunately the RBL operator returns the originally IP on match, but not the "real" response. This means, that this operator only could be used on a boolean base like "If there is a DNS response, then match".

IMHO being able to filter requests based on a score would be much better and more feasible, so I changed the code like mentioned below.

rbl.cc before 236

    if (rule && t && rule->hasCaptureAction()) {
        char *respBl;
        int first, second, third, fourth;

        respBl = inet_ntoa(sin.sin_addr);

        if (sscanf(respBl, "%d.%d.%d.%d", &first, &second, &third, &fourth) != 4) {
            ms_dbg_a(t, 4, "RBL lookup of " + ipStr + " failed: bad response");
            //return false;
        }
        else {
            t->m_collections.m_tx_collection->storeOrUpdateFirst(
            "1", std::string(respBl));

            t->m_collections.m_tx_collection->storeOrUpdateFirst(
            "2", std::to_string(fourth));
        }

        furtherInfo(&sin, ipStr, t, m_provider);
    }

rbl.cc before 126

        trans->m_collections.m_tx_collection->storeOrUpdateFirst(
        "2", std::to_string(score));

        trans->m_collections.m_tx_collection->storeOrUpdateFirst(
        "3", std::to_string(type));
        trans->m_collections.m_tx_collection->storeOrUpdateFirst(
        "4", std::to_string(days));
主要言語
C++
スター
9.8k
フォーク
1.8k
平均マージ
2時間 46分
マージ済み PR(30日)
1

環境構築

  • Dockerfile・Docker Compose ファイルなし
  • プルリクエストのテンプレートあり
  • コントリビューションガイドなし

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

owasp-modsecurity/ModSecurity のほかの issue

owasp-modsecurity/ModSecurity の issue をすべて見る

似ている issue

C++ の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。