source: main/trunk/greenstone3/resources/tomcat/greenstone3.xml.svn@ 33461

Last change on this file since 33461 was 33461, checked in by ak19, 5 years ago

Implementing Diego Spano's suggested changes for tomcat's allowLinking configuration settings used to support symlinking from the web to folders outside the web app base folder. This confug setting needs to be set differently for tomcat 8. Its value used to be fixed to false in the past, so false becomes the new default. A new user configurable property is introduced in build.xml, tomcat.user.allowLinking. However, since apache's tomcat documentation says that the value should never be set to true for Windows or any OS where the filesystem is case insensitive, as this can affect security, build.xml internally uses a different new property called tomcat.allowLinking which works out the final value. For windows, this will always be false and a warning is printed when the user configurable property got overridden to false on Windows. When the user configurable property was set to true in any other case, a warning is printed on non-Windows OS about how the user should set the value to false if their OS has a case onsensitive file system. Finally, the calculated/sanitised value stored in tomcat.allowLinking propagates to greenstone.xml in place of the placeholders in the greenstone.xml.in and ultimately greenstone.xml.svn files

  • Property svn:keywords set to Author Date Id Revision
File size: 1.8 KB
Line 
1<!-- set allowLinking to true if you want to use symlinks to files or directories outside the docBase directory -->
2<!-- set reloadable to false for a production version. if true, automatically reloads the webapp if it detects changes in classes or lib directories -->
3<!-- see http://tomcat.apache.org/tomcat-5.5-doc/config/context.html for more Context attributes -->
4
5<Context
6 docBase="@gsdl3webwritablehome@"
7 aliases="/interfaces=@gsdl3webhome@/interfaces,/sites=@gsdl3webhome@/sites"
8 debug="1" reloadable="true"
9 @privilegedattribute@
10 allowLinking="@allowlinking@"
11 xmlBlockExternal="false">
12 <Resources allowLinking="@allowlinking@" />
13
14<!--
15 For embedded derby db:
16 driverName="org.apache.derby.jdbc.EmbeddedDriver"
17 connectionURL="jdbc:derby:@gsdl3webhome@/etc/usersDB"
18-->
19 <Realm className="org.apache.catalina.realm.JDBCRealm"
20 driverName="org.apache.derby.jdbc.ClientDriver"
21 connectionURL="jdbc:derby://@derbyserver@:@derbyserverport@/@gsdl3webhome@/etc/usersDB"
22 userTable="users" userNameCol="username" userCredCol="password"
23 userRoleTable="roles" roleNameCol="role"
24 />
25 <!-- Session Manager. Default values are used. See
26 packages/tomcat/webapps/docs/config/manager.html for more info.
27 Pathname may be absolute, or relative to greenstone3 context work
28 directory: packages/tomcat/work/Catalina/localhost/greenstone3.
29 Set pathname="" to disable storing session info between restarts.
30 To manually clear session info, stop Tomcat and delete the session
31 file. -->
32 <Manager pathname="SESSIONS.ser" />
33
34 <!-- Allow all machines or just this machine: 127.0.0.1 (IPv4) and 0:0:0:0:0:0:0:1 (IPv6, needed on windows)
35 https://tomcat.apache.org/tomcat-7.0-doc/config/valve.html -->
36 <Valve className="org.apache.catalina.valves.RemoteAddrValve" allow="@allowedIPs@"/>
37</Context>
Note: See TracBrowser for help on using the repository browser.