Proceeding from where Olaf left off, follow these steps:
(1) You may omit the address
attribute.
(2) Change the secretRequired attribute to secretRequired="true"
, or equivalently, leave it out. (The default value is True).
(3) Add a secret
attribute to the workers.properties
file and to the server.xml file. You may choose whatever secret you want, on condition that the values in both files match exactly.
(4) For the time being, add to the AJP connector the attribute allowedRequestAttributesPattern=".*"
, as T Cervenka suggests.
You should then end up with something like,
workers.properties
worker.list=worker1
worker.worker1.type=ajp13
worker.worker1.host=localhost
worker.worker1.port=8009
worker.worker1.secret=F45A93BF-3AA7-4CB4-E49A-DB34573E4A25
server.xml
<Connector port="8009" protocol="AJP/1.3" maxThreads="500" secret="F45A93BF-3AA7-4CB4-E49A-DB34573E4A25" allowedRequestAttributesPattern=".*" />
The value of allowedRequestAttributesPattern
must be a regular expression. It represents the request attributes passed from the reverse proxy to the AJP connector. See the Tomcat docs for details. https://tomcat.apache.org/tomcat-8.5-doc/config/ajp.html.
The regex value for allowedRequestAttributesPattern
must be an exact match for the request attributes passed in the AJP protocol. Its default value (where you don't mention the attribute) is null: this is known to break requests. If in doubt, use the regex wildcard, ".*", as above.