Commit 99a8056
fix(image): reject trailing garbage in resize size parameter
Add !iss.eof() check to istringstream parsing so inputs like "100abc"
or "100GB" are rejected instead of silently truncating to 100. The CLI
path was already protected by regex validation in size_in_mb(), but
direct XML-RPC/gRPC API callers were not.
Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Aleksei Sviridkin <f@lex.la>1 parent a8496f5 commit 99a8056
2 files changed
+6
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1653 | 1653 | | |
1654 | 1654 | | |
1655 | 1655 | | |
1656 | | - | |
| 1656 | + | |
1657 | 1657 | | |
1658 | 1658 | | |
1659 | 1659 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
258 | 258 | | |
259 | 259 | | |
260 | 260 | | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
261 | 266 | | |
262 | 267 | | |
263 | 268 | | |
| |||
0 commit comments