This file is indexed.

/usr/share/i2p/eepsite/jetty-rewrite.xml is in i2p-router 0.9.34-1ubuntu3.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
<?xml version="1.0"?>
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure_9_0.dtd">

<!-- =============================================================== -->
<!-- Mixin the RewriteHandler                                        -->
<!-- =============================================================== -->


<Configure id="Server" class="org.eclipse.jetty.server.Server">

    <!-- =========================================================== -->
    <!-- configure rewrite handler                                   -->
    <!-- =========================================================== -->
    <Get id="oldhandler" name="handler"/>

    <Set name="handler">
     <New id="Rewrite" class="org.eclipse.jetty.rewrite.handler.RewriteHandler">
      <Set name="handler"><Ref refid="oldhandler"/></Set>
      <Set name="rewriteRequestURI">true</Set>
      <Set name="rewritePathInfo">false</Set>
      <Set name="originalPathAttribute">requestedPath</Set>

      <!-- Add rule to protect against IE ssl bug -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.MsieSslRule"/>
        </Arg>
      </Call>

      <!-- protect favicon handling -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.HeaderPatternRule">
            <Set name="pattern">/favicon.ico</Set>
            <Set name="name">Cache-Control</Set>
            <Set name="value">Max-Age=3600,public</Set>
            <Set name="terminating">true</Set>
          </New>
        </Arg>
      </Call>

      <!-- redirect from the welcome page to a specific page -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.RewritePatternRule">
            <Set name="pattern">/rewrite/</Set>
            <Set name="replacement">/rewrite/info.html</Set>
          </New>
        </Arg>
      </Call>

      <!-- replace the entire request URI -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.RewritePatternRule">
            <Set name="pattern">/some/old/context</Set>
            <Set name="replacement">/rewritten/newcontext</Set>
          </New>
        </Arg>
      </Call>

      <!-- replace the beginning of the request URI -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.RewritePatternRule">
            <Set name="pattern">/rewrite/for/*</Set>
            <Set name="replacement">/rewritten/</Set>
          </New>
        </Arg>
      </Call>

      <!-- reverse the order of the path sections -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.RewriteRegexRule">
            <Set name="regex">(.*?)/reverse/([^/]*)/(.*)</Set>
            <Set name="replacement">$1/reverse/$3/$2</Set>
          </New>
        </Arg>
      </Call>

      <!-- add a cookie to each path visited -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.CookiePatternRule">
            <Set name="pattern">/*</Set>
            <Set name="name">visited</Set>
            <Set name="value">yes</Set>
          </New>
        </Arg>
      </Call>

      <!--  actual redirect, instead of internal rewrite -->
      <Call name="addRule">
        <Arg>
          <New class="org.eclipse.jetty.rewrite.handler.RedirectPatternRule">
            <Set name="pattern">/redirect/*</Set>
            <Set name="location">/redirected</Set>
          </New>
        </Arg>
      </Call>

      <!-- add a response rule -->
      <Call name="addRule">
        <Arg>
           <New class="org.eclipse.jetty.rewrite.handler.ResponsePatternRule">
             <Set name="pattern">/400Error</Set>
             <Set name="code">400</Set>
             <Set name="reason">ResponsePatternRule Demo</Set>
          </New>
        </Arg>
      </Call>

     </New>
    </Set>

</Configure>