Forum Discussion
Using ARR / IIS as a proxy server and getting 404's on some files that are there
In addition, here are my rules that we have setup in case you all think you see something wrong.
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<clear />
<rule name="ReverseProxyInboundRule1" enabled="true" stopProcessing="true">
<match url="(.*)" />
<conditions logicalGrouping="MatchAny" trackAllCaptures="false">
<add input="{PATH_INFO}" pattern="^/otmm" />
<add input="{PATH_INFO}" pattern="^/content" />
<add input="{PATH_INFO}" pattern="^/jmx-console" />
<add input="{PATH_INFO}" pattern="^/console" />
<add input="{PATH_INFO}" pattern="^/swagger-ui" />
<add input="{PATH_INFO}" pattern="^/artesia-*" />
<add input="{PATH_INFO}" pattern="^/otmmapi" />
</conditions>
<serverVariables>
<set name="HTTP_X_ORIGINAL_ACCEPT_ENCODING" value="{HTTP_ACCEPT_ENCODING}" />
<set name="HTTP_ACCEPT_ENCODING" value="" />
</serverVariables>
<action type="Rewrite" url="http://ccc0sa01.ifaw.net:11090/{R:1}" appendQueryString="true" logRewrittenUrl="true" />
</rule>
<rule name="ReverseProxyInboundRuleVideo" enabled="true" stopProcessing="true">
<match url="(.*)" />
<conditions logicalGrouping="MatchAny" trackAllCaptures="false">
<add input="{PATH_INFO}" pattern="^/Video" />
</conditions>
<serverVariables>
<set name="HTTP_X_ORIGINAL_ACCEPT_ENCODING" value="{HTTP_ACCEPT_ENCODING}" />
<set name="HTTP_ACCEPT_ENCODING" value="" />
</serverVariables>
<action type="Rewrite" url="http://ccc0sa01.ifaw.net/{R:1}" appendQueryString="true" logRewrittenUrl="true" />
</rule>
<rule name="ReverseProxyInboundRule_OTDS" enabled="true" stopProcessing="true">
<match url="(.*)" />
<conditions logicalGrouping="MatchAny" trackAllCaptures="false">
<add input="{PATH_INFO}" pattern="^/otds" />
<add input="{PATH_INFO}" pattern="^/csadmin" />
<add input="{PATH_INFO}" pattern="^/OTDSConnectors" />
<add input="{PATH_INFO}" pattern="^/triggers" />
<add input="{PATH_INFO}" pattern="^/ot-*" />
<add input="{PATH_INFO}" pattern="^/ums*" />
<add input="{PATH_INFO}" pattern="^/otdsws*" />
</conditions>
<serverVariables>
<set name="HTTP_X_ORIGINAL_ACCEPT_ENCODING" value="{HTTP_ACCEPT_ENCODING}" />
<set name="HTTP_ACCEPT_ENCODING" value="" />
</serverVariables>
<action type="Rewrite" url="http://ccc0sa02.ifaw.net:8080/{R:1}" logRewrittenUrl="true" />
</rule>
<rule name="RootRedirect" stopProcessing="true">
<match url="^$" />
<action type="Redirect" url="/otmm" />
</rule>
</rules>
<outboundRules>
<clear />
<rule name="RestoreAcceptEncoding" preCondition="NeedsRestoreAcceptEncoding" enabled="true">
<match serverVariable="HTTP_ACCEPT_ENCODING" pattern="^(.*)" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="true" />
<action type="Rewrite" value="{HTTP_X_ORIGINAL_ACCEPT_ENCODING}" />
</rule>
<rule name="ReverseProxyOutboundRule_OTMM" preCondition="" enabled="true" stopProcessing="true">
<match filterByTags="A, Form, Img" pattern="^http(s)?://ccc0sa01.ifaw.net:11090/(.*)" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="true" />
<action type="Rewrite" value="https://www.ifawimages.com/{R:2}" />
</rule>
<rule name="ReverseProxyOutboundRule_OTDS" preCondition="" enabled="true" stopProcessing="true">
<match filterByTags="A, Form, Img" pattern="^http(s)?://ccc0sa02.ifaw.net:8080(.*)" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="true" />
<action type="Rewrite" value="https://www.ifawimages.com/{R:2}" />
</rule>
<rule name="ReverseProxyOutboundRule_StreamingMedia" preCondition="" enabled="true" stopProcessing="true">
<match filterByTags="None" pattern="^http://ccc0sa01.ifaw.net/Video/data(.*)" />
<action type="Rewrite" value="https://www.ifawimages.com/Video/data{R:1}" />
</rule>
<preConditions>
<preCondition name="NeedsRestoreAcceptEncoding">
<add input="{HTTP_X_ORIGINAL_ACCEPT_ENCODING}" pattern="'.+'" />
</preCondition>
</preConditions>
</outboundRules>
</rewrite>
<httpRedirect enabled="false" destination="/otmm" exactDestination="true" childOnly="true" />
<security>
<requestFiltering allowDoubleEscaping="true">
<requestLimits maxAllowedContentLength="300000000" maxQueryString="4096" />
</requestFiltering>
</security>
<tracing>
<traceFailedRequests>
<add path="*">
<traceAreas>
<add provider="ASP" verbosity="Verbose" />
<add provider="ISAPI Extension" verbosity="Verbose" />
<add provider="WWW Server" areas="Authentication,Security,Filter,StaticFile,CGI,Compression,Cache,RequestNotifications,Module,FastCGI,WebSocket" verbosity="Verbose" />
</traceAreas>
<failureDefinitions timeTaken="00:00:00" statusCodes="200-999" />
</add>
</traceFailedRequests>
</tracing>
<caching enabled="false" />
<staticContent>
<clientCache cacheControlMode="DisableCache" />
</staticContent>
</system.webServer>
</configuration>
- randysthomasJun 04, 2019Copper Contributor
at this point I am desperate, trying anywhere haha.
This is the target:
https://www.ifawimages.com/otdsws/login?PostTicket=true&RFA=e4b97c12-8614-4600-8898-7d7bbf2b65fc%3Ahttp%3A%2F%2Fccc0sa01.ifaw.net%3A11090%2Fotmm%2Fux-html%2Findex.html