VMware VSHIELD MANAGER 4.1.0 UPDATE 1 - API Manuale Utente Pagina 34

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 90
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 33
vShield API Programming Guide
34 VMware, Inc.
Example:
GET /api/1.0/network/network-244/firewall/rules HTTP/1.1
Authorization: Basic YWRtaW46ZGVmYXVsdA==
Host: 10.112.196.213
Post a Firewall Rule Set
YouaddallfirewallrulesasasetforeachvShieldEdge.ThevShieldManagerprocessesthepostedXMLfile
asacompleterulesetforthespecifiedvShieldEdge.Thenewrulesetreplacestheentirepreviousruleset.
Example 5-26. Post the Firewall Rule Set on a vShield Edge
Request:
POST <vShield_Manager-uri>/api/1.0/network/<internal-portgroup-vc-moref-id>/firewall/rules
<VShieldEdgeConfig>
<FirewallConfig>
<FirewallRule>
<protocol>tcp|udp|icmp|any</protocol>
<sourceIpAddress>see_below</sourceIpAddress>
<sourcePort>see_below</sourcePort>
<destinationIpAddress>see_below</destinationIpAddress>
<destinationPort>see_below</destinationPort>
<direction>in|out|both</direction>
<action>allow|deny</action>
</FirewallRule>
</FirewallConfig>
</VShieldEdgeConfig>
Rules:
Youcanaddmultiplefirewallrulesbyenteringmultiple<FirewallRule></FirewallRule>sectionsinthe
body.
For<protocol />optionstcpandudp,youmustspecifysourcePortanddestinationPortelements.
Foroptionsicmpandany,thesourcePortanddestinationPortelementsarenotexpected.
Youmustadd<icmpType />ifyouconfigureicmpastheprotocol.
Loggingisdisabledbydefault.Toenablelogging,adda<log />elementwithin<FirewallRule />.
ThesourceIpAddressanddestinationIpAddressparameterscanbeenteredineitherofthese
formats.
<ipAddress>IpOrAny</ipAddress>
or
<IpRange>
<rangeStart>low_ip_address</rangeStart>
<rangeEnd>high_ip_address</rangeEnd>
</IpRange>
ThesourcePortanddestinationPortparameterscanbeenteredineitherofthefollowingformats.
<port>PortOrAny</port>
or
<PortRange>
<rangeStart>low_port</rangeStart>
<rangeEnd>high_port</rangeEnd>
</PortRange>
Vedere la pagina 33
1 2 ... 29 30 31 32 33 34 35 36 37 38 39 ... 89 90

Commenti su questo manuale

Nessun commento