WD
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
IP/command whitelist

Whitelist functionality allows to specify xml-file with list of IP with allowed/denied commands. To pass whitelist file to WebDriver need to use "white-list" server option(WD Server switches)

-white-list=/path/to/whitelist.xml

If no whitelist xml-file defined then all commands for all IP is allowed.

Example of whitelist.xml:

<?xml version="1.0" encoding="UTF-8"?>
<hosts>
<host ip="10.32.191.8"/>
<host ip="192.27.27.7">
<deny url="/session/*/window/*" method="*"/>
<deny url="/session/*/click" method="POST"/>
</host>
<host ip="192.34.191.7">
<allow url="/status" method="GET" />
</host>
</hosts>

*In this example:

  • - if nothing is specified (10.32.191.8) all command is allowed for that IP;
  • - if "allow" node is specified only these commands is allowed, other disallowed;
  • - if "deny" node is specified this command will be disallowed, all other allowed;
  • - if there will be "allow" and "deny" nodes for one IP, only "deny" will have effect, all other will be allowed;
  • - for all other IP all commands will be disallowed;

To allow some command for any IP wildcard should be used:

<host ip="*">
<allow url="/status" method="GET" />
</host>

There is xsd file to validate/generate whitelist.xml