[Bug]: host-rewrite policy documentation lists fewer allowed host characters than the policy accepts

オープン 初心者向け
#4,355 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

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

評価

難易度
1/5
見積もり時間
1時間未満
初心者へのやさしさ
91/100
issue の種類
ドキュメント
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
go
領域
documentation

調査の方向性

docs/host-rewrite/v1.1/docs/host-rewrite.md の「User Parameters (API Definition)」セクションを読み、許可される文字の説明を policies/host-rewrite/policy-definition.yaml のパターンと比較してください。スキーマですでに受け入れられているコロンを含めるよう、ドキュメントを更新してください。パラメータ表に、backend.example.com:8080 のようなポートを含め、ホストで受け入れられる文字が正確に記載されていれば完了です。

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

説明

Area/Policies Aspect/Other Severity/Trivial Type/Bug
Please select the area the issue is related to

Gateway

Please select the aspect the issue is related to

Aspect/Other (Anything else which does not match above categories)

Description

The parameter table in the host-rewrite policy documentation says the host value allows letters, digits, - and .. The policy's schema also allows :.

  • Doc: docs/host-rewrite/v1.1/docs/host-rewrite.md in wso2/gateway-controllers, section "User Parameters (API Definition)": "Allowed characters: letters, digits, - and .."
  • Schema: policies/host-rewrite/policy-definition.yaml, pattern: "^[a-zA-Z0-9.:-]+$".

The doc's own Notes section says a port may be included, for example backend.example.com:8080. That needs :. The integration tests confirm a host with a port is accepted and sent upstream unchanged.

Steps to Reproduce
  1. Read the parameter table in docs/host-rewrite/v1.1/docs/host-rewrite.md.
  2. Compare it with the pattern in policies/host-rewrite/policy-definition.yaml.
  3. Deploy an API with host-rewrite host: backend.example.com:8080 and hostRewrite: manual on the upstream.
  4. The API is accepted, and the upstream receives Host: backend.example.com:8080.
Severity Level of the Issue

Severity/Trivial (Cosmetic issues. Can be fixed in future releases)

Environment Details (with versions)
  • host-rewrite policy v1.1.0, built from wso2/gateway-controllers source (commit 4f1520a8). Doc v1.1.
  • Gateway 1.1.0, 1.2.0 and main (main-a7e8774).
主要言語
Go
スター
85
フォーク
137
平均マージ
1日 12時間
マージ済み PR(30日)
247

環境構築

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

はじめの一歩

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

wso2/api-platform のほかの issue

wso2/api-platform の issue をすべて見る

似ている issue

Go の issue をもっと見る

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

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