the inputs for capacity bytes in edit option of storage pool are not validated to be positive
まだ誰も着手していません。
評価
調査の方向性
Start at the updateStoragePool API entry point and trace validation for the capacity bytes parameter. Reproduce the request with zero and negative values, then verify that both are rejected immediately with a clear Invalid parameter error rather than reaching backend processing.
索引モデルが issue の本文から書いたものです。
説明
problem
The updateStoragePool API currently accepts zero or negative values for capacity-related parameters. Add positive-number validation so invalid values are rejected with Invalid parameter error. This prevents invalid storage pool capacity settings from reaching backend processing.
versions
The versions of ACS, hypervisors, storage, network etc..
Checked on 4.23
The steps to reproduce the bug
- Click on edit option for storage pool
- Input a negative number for capacity bytes
3.click on OK to edit it.
you see an error as : Unable to update on DB, due to: Data truncation: Out of range value for column 'capacity_bytes' at row 1
instead of throwing an error for invalid parameter.
...
What to do about it?
Before this fix : When I tried to update a default primary storage pool using a negative value
when I tried to input 0 as capacity bytes for storage pool: It is updating it to 0
Add positive-number validation to the capacity bytes parameter in the updateStoragePool API. If a user provides zero or a negative value, reject the request immediately with a clear invalid-parameter error instead of sending it for backend processing.
After the fix:
- 主要言語
- Java
- スター
- 3.1k
- フォーク
- 1.4k
- 平均マージ
- 6日 20時間
- マージ済み PR(30日)
- 27
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
apache/cloudstack のほかの issue
-
bug
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
apache/cloudstack#14222 ·
-
bug component:kubernetes
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
apache/cloudstack#14180 ·
-
bug component:projects component:UI
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
apache/cloudstack#14070 · コメント 5 件 ·
-
component:backup
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
apache/cloudstack#14013 ·
-
KVM agent fails to connect to Ceph RBD storage pool after upgrading Ceph client to Tentacle 20.2.4 オープンbug component:ceph
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
apache/cloudstack#13989 · コメント 3 件 ·
apache/cloudstack の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
elastic/gradle-plugins#157 ·
-
enhancement Tools
難易度 1/5 1時間未満 初心者へのやさしさ 75/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
apache/rocketmq-dashboard#5008 ·
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
-
DETECT_PARAMETER_NAMES=false silently disables @ConstructorProperties-based Creator detection too オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
FasterXML/jackson-databind#6229 ·