0

I want to allow queries from localhost to one url, and forward everything else to another service. Before I was doing this without the localhost requierement and it was working. But now it seems that although the localtion filter matches as shown with a granted message using the trace logs from authz_core:trace8 it redirects to the service I don't want to:

45         <Location /api/link1/>
46             JkMount Service1
47             <RequireAny>
48                 Require local
50             </RequireAny>
51         </Location>
52        # JkMount /api/link1/* Service1
53
55         JkMount /api Service2
56         JkMount /api/* Service2

So given this configuration I understand that I say that if the query goes to /api/link1 it should redirect the query to my Service1, and everything else with /api* should go to the Service2.

What is the reason that I'm getting the queries from /api/link1 into the Service2 and before adding the location requisite as shown in the commented line 52 it was working?

nck
  • 1,673
  • 16
  • 40

1 Answers1

0

You should try doing this way:

    <Location /api/link1/>
         JkMount Service1
         <RequireAny>
             Require local
         </RequireAny>
    </Location>
    # JkMount /api/link1/* Service1

     JkMount /api Service2
     JkMount /api/* Service2
     JKUnMount /api/link1 Service2

I allways have had the feeling that JkMount outside any Location or LocationMatch like tags are handled before any other statement

jlumietu
  • 6,234
  • 3
  • 22
  • 31