title: IIS 10 - URL rewrite rules to block direct requests to servername except from SOAPUI
body: <p>Window 2016 / IIS 10. </p>
  
  <p>I want to block all requests that are using the servername:portnumber/service and enforce the use of DNS-aliases. Problem at the moment seems to be that when the rule "Allow SOAPUI" matches it does not stop processing and therefore the last one kicks in and blocks SOAPUI</p>
  
  <pre><code> &lt;rule name="Allow SOAPUI" enabled="true" patternSyntax="Wildcard" stopProcessing="true"&gt;
    &lt;match url="*" /&gt;
    &lt;conditions logicalGrouping="MatchAll" trackAllCaptures="false"&gt;
      &lt;add input="{HTTP_HOST}" pattern="dsttst100*" /&gt;
      &lt;add input="{HTTP_USER_AGENT}" pattern="*SOAPUI*" negate="true" /&gt;
    &lt;/conditions&gt;
    &lt;action type="Rewrite" url="http://redirect.to.what" /&gt;
   &lt;/rule&gt;
   &lt;rule name="Only allow requests from loadbalancer" enabled="true" patternSyntax="Wildcard" stopProcessing="true"&gt;
    &lt;match url="*" /&gt;
    &lt;conditions logicalGrouping="MatchAny" trackAllCaptures="false"&gt;
    &lt;add input="{REMOTE_ADDR}" pattern="111.22.55.11" negate="true" /&gt;
    &lt;/conditions&gt;
    &lt;action type="CustomResponse" statusCode="403" subStatusCode="6" statusReason="Only allowed from IISAR01 (use DNS) or using SOAPUI" statusDescription="Use dns-alias" /&gt;
   &lt;/rule&gt;
  </code></pre>