From bbee5f1baec132f8b47ae80303ce22f7d7787cd8 Mon Sep 17 00:00:00 2001 From: jvoisin Date: Fri, 12 Jan 2018 16:05:19 +0100 Subject: Add an ugly hack to our parser to make the writing of configuration rules more obvious. --- doc/source/config.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'doc') diff --git a/doc/source/config.rst b/doc/source/config.rst index 9244668..e0df244 100644 --- a/doc/source/config.rst +++ b/doc/source/config.rst @@ -276,7 +276,7 @@ In the situation where you have a call to ``system()`` that lacks proper user-in :: # Allow `id.php` to restrict system() calls to `id` - sp.disable_function.function("system").filename("id.php").param("$cmd").value("id").allow(); + sp.disable_function.function("system").filename("id.php").param("cmd").value("id").allow(); sp.disable_function.function("system").filename("id.php").drop() Of course, this is a trivial example, a lot can be achieved with this feature, as you will see below. @@ -387,9 +387,9 @@ The following rules will: :: - sp.disable_function.function("system").param("$cmd").value("id").allow(); - sp.disable_function.function("system").param("$cmd").value_r("^ping").drop().simulation(); - sp.disable_function.function("system").param("$cmd").drop(); + sp.disable_function.function("system").param("cmd").value("id").allow(); + sp.disable_function.function("system").param("cmd").value_r("^ping").drop().simulation(); + sp.disable_function.function("system").param("cmd").drop(); Miscellaneous examples """""""""""""""""""""" -- cgit v1.3