3 ##############################################################################
4 # Copyright (c) 2017 Politecnico di Torino and others.
6 # All rights reserved. This program and the accompanying materials
7 # are made available under the terms of the Apache License, Version 2.0
8 # which accompanies this distribution, and is available at
9 # http://www.apache.org/licenses/LICENSE-2.0
10 ##############################################################################
12 devices_to_classes = { "webclient" : "PolitoWebClient",
13 "webserver" : "PolitoWebServer",
14 "cache" : "PolitoCache",
16 "firewall" : "AclFirewall",
17 "mailclient" : "PolitoMailClient",
18 "mailserver" : "PolitoMailServer",
19 "antispam" : "PolitoAntispam",
20 "endpoint": "EndHost",
22 "endhost": "PolitoEndHost",
23 "vpnaccess":"PolitoVpnAccess",
24 "vpnexit":"PolitoVpnExit",
25 "fieldmodifier":"PolitoFieldModifier"
27 devices_to_configuration_methods = {"webclient" : "",
29 "cache" : "installCache",
30 "nat" : "setInternalAddress",
31 "firewall" : "addAcls",
37 "endhost": "installEndHost",
38 "vpnaccess":"vpnAccessModel",
39 "vpnexit":"vpnAccessModel",
40 "fieldmodifier":"installFieldModifier"
42 devices_initialization = { "webclient" : ["webserver"],
47 "mailclient" : ["mailserver"],
58 convert_configuration_property_to_ip = { "webclient" : ["value"],
62 "firewall" : ["key", "value"],
63 "mailclient" : ["value"],
69 "vpnaccess": ["value"],
74 devices_configuration_fields = { "webclient" : "",
76 "cache" : "cached address",
77 "nat" : "natted address",
78 "firewall" : "acl entry",
83 "dpi":"words blacklist",
85 "vpnaccess":"vpn access",
87 "fieldmodifier":"field modifier"