[exim-cvs] testsuite: add 0990 for allow_insecure_tainted_da…

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Exim Git Commits Mailing List
Ημερομηνία:  
Προς: exim-cvs
Αντικείμενο: [exim-cvs] testsuite: add 0990 for allow_insecure_tainted_data
Gitweb: https://git.exim.org/exim.git/commitdiff/331817e995b05793ec840476fac67e8f7c638a47
Commit:     331817e995b05793ec840476fac67e8f7c638a47
Parent:     368ecb000c58995c5f61443d45d43942f1f431d0
Author:     Heiko Schlittermann (HS12-RIPE) <hs@???>
AuthorDate: Mon Apr 5 16:06:24 2021 +0200
Committer:  Heiko Schlittermann (HS12-RIPE) <hs@???>
CommitDate: Thu Jun 24 21:43:17 2021 +0200


    testsuite: add 0990 for allow_insecure_tainted_data


    (cherry picked from commit 56213337357265eb42c40dd04a22f6ac433b9e81)
---
 test/aux-fixed/0990/example.com               | 1 +
 test/confs/0990                               | 2 ++
 test/scripts/0990-Allow-Tainted-Data/0990     | 7 +++++++
 test/scripts/0990-Allow-Tainted-Data/REQUIRES | 1 +
 test/stderr/0990                              | 3 +++
 test/stdout/0990                              | 4 ++++
 6 files changed, 18 insertions(+)


diff --git a/test/aux-fixed/0990/example.com b/test/aux-fixed/0990/example.com
new file mode 100644
index 0000000..b586074
--- /dev/null
+++ b/test/aux-fixed/0990/example.com
@@ -0,0 +1 @@
+hans
diff --git a/test/confs/0990 b/test/confs/0990
new file mode 100644
index 0000000..076a399
--- /dev/null
+++ b/test/confs/0990
@@ -0,0 +1,2 @@
+# this is the default
+allow_insecure_tainted_data = ALLOW_TAINTED
diff --git a/test/scripts/0990-Allow-Tainted-Data/0990 b/test/scripts/0990-Allow-Tainted-Data/0990
new file mode 100644
index 0000000..87cf4c0
--- /dev/null
+++ b/test/scripts/0990-Allow-Tainted-Data/0990
@@ -0,0 +1,7 @@
+# Allow insecure tainted data
+exim -DALLOW_TAINTED=no -f hans@??? -be
+${lookup{$sender_address_local_part}lsearch{DIR/aux-fixed/0990/$sender_address_domain}{yes}{no}}
+****
+exim -DALLOW_TAINTED=yes -f hans@??? -be
+${lookup{$sender_address_local_part}lsearch{DIR/aux-fixed/0990/$sender_address_domain}{yes}{no}}
+****
diff --git a/test/scripts/0990-Allow-Tainted-Data/REQUIRES b/test/scripts/0990-Allow-Tainted-Data/REQUIRES
new file mode 100644
index 0000000..5fabbde
--- /dev/null
+++ b/test/scripts/0990-Allow-Tainted-Data/REQUIRES
@@ -0,0 +1 @@
+feature _OPT_MAIN_ALLOW_INSECURE_TAINTED_DATA
diff --git a/test/stderr/0990 b/test/stderr/0990
new file mode 100644
index 0000000..3feb126
--- /dev/null
+++ b/test/stderr/0990
@@ -0,0 +1,3 @@
+1999-03-02 09:44:33 Tainted filename for search: 'TESTSUITE/aux-fixed/0990/example.com'
+1999-03-02 09:44:33 Warning: Tainted filename for search: 'TESTSUITE/aux-fixed/0990/example.com'
+1999-03-02 09:44:33 Warning: Tainted filename 'TESTSUITE/aux-fixed/0990/example.com'
diff --git a/test/stdout/0990 b/test/stdout/0990
new file mode 100644
index 0000000..5a4290a
--- /dev/null
+++ b/test/stdout/0990
@@ -0,0 +1,4 @@
+> Failed: (null)
+>
+> yes
+>