aboutsummaryrefslogtreecommitdiff
path: root/test/gie
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2021-11-24 00:31:21 +0100
committerEven Rouault <even.rouault@spatialys.com>2021-11-24 00:31:24 +0100
commita1dd3facaefd85e25a8202b7b9ea19b31278e36c (patch)
tree6d1fb42fd9c3de338f035f16a70488fadbdd7eb0 /test/gie
parentdf894f50eeea49e70d9a76dd58972e71cb6a29e4 (diff)
downloadPROJ-a1dd3facaefd85e25a8202b7b9ea19b31278e36c.tar.gz
PROJ-a1dd3facaefd85e25a8202b7b9ea19b31278e36c.zip
Pipeline parsing: reject proj=/o_proj= before first step, to avoid bad performance pattern on hostile pipelines
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=41290
Diffstat (limited to 'test/gie')
-rw-r--r--test/gie/4D-API_cs2cs-style.gie15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/gie/4D-API_cs2cs-style.gie b/test/gie/4D-API_cs2cs-style.gie
index 123bf638..9189b328 100644
--- a/test/gie/4D-API_cs2cs-style.gie
+++ b/test/gie/4D-API_cs2cs-style.gie
@@ -290,6 +290,21 @@ expect 1335.8339 7522.963
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
+# Test invalid pipelines
+-------------------------------------------------------------------------------
+# proj= before first step
+operation +proj=pipeline +proj=merc +step +inv +proj=merc
+expect failure pjd_err_malformed_pipeline
+
+# o_proj= before first step
+operation +proj=pipeline +o_proj=merc +step +proj=ob_tran
+expect failure pjd_err_malformed_pipeline
+
+# nested pipeline
+operation +proj=pipeline +step +proj=pipeline +step +proj=merc
+expect failure pjd_err_malformed_pipeline
+
+-------------------------------------------------------------------------------
# Test Pipeline Coordinate Stack
-------------------------------------------------------------------------------
operation +proj=pipeline \