Re: svn commit: r1867891 - in /tomcat/jk/trunk: native/apache-2.0/mod_jk.c xdocs/miscellaneous/changelog.xml

2019-10-02 Thread Rainer Jung

Thank you, Mark!

Am 02.10.2019 um 17:00 schrieb ma...@apache.org:

Author: markt
Date: Wed Oct  2 15:00:48 2019
New Revision: 1867891

URL: http://svn.apache.org/viewvc?rev=1867891&view=rev
Log:
Fix a bug in the normalization checks that prevented file based requests, such 
as SSI file includes, from being processed.

Modified:
 tomcat/jk/trunk/native/apache-2.0/mod_jk.c
 tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml

Modified: tomcat/jk/trunk/native/apache-2.0/mod_jk.c
URL: 
http://svn.apache.org/viewvc/tomcat/jk/trunk/native/apache-2.0/mod_jk.c?rev=1867891&r1=1867890&r2=1867891&view=diff
==
--- tomcat/jk/trunk/native/apache-2.0/mod_jk.c (original)
+++ tomcat/jk/trunk/native/apache-2.0/mod_jk.c Wed Oct  2 15:00:48 2019
@@ -4035,6 +4035,15 @@ static int jk_map_to_storage(request_rec
  return DECLINED;
  }
  
+// Not a URI based request - e.g. file based SSI include

+if (strlen(r->uri) == 0) {
+jk_log(conf->log, JK_LOG_DEBUG,
+   "File based (sub-)request for file=%s. No URI to 
match.",
+  r->filename);
+JK_TRACE_EXIT(conf->log);
+return DECLINED;
+}
+
  clean_uri = apr_pstrdup(r->pool, r->uri);
  rc = jk_servlet_normalize(clean_uri, conf->log);
  if (rc != 0) {

Modified: tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml?rev=1867891&r1=1867890&r2=1867891&view=diff
==
--- tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml (original)
+++ tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml Wed Oct  2 15:00:48 2019
@@ -47,6 +47,10 @@
  Extend trace level logging of method entry/exit to aid debugging of
  request mapping issues. (markt)

+  
+Fix a bug in the normalization checks that prevented file based
+requests, such as SSI file includes, from being processed. (markt)
+  
  

  


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



Re: Tag Tomcat 7

2019-10-02 Thread Violeta Georgieva
На ср, 2.10.2019 г. в 18:12 ч. Mark Thomas  написа:
>
> On 01/10/2019 12:18, Mark Thomas wrote:
> > On 01/10/2019 12:17, Violeta Georgieva wrote:
> >> Hi Mark,
> >>
> >> На вт, 1.10.2019 г. в 13:58 ч. Mark Thomas  >> > написа:
> >>>
> >>> On 01/10/2019 11:09, Violeta Georgieva wrote:
>  Hi,
> 
>  I'm planning to tag Tomcat 7 later today.
>  If you want to include something please reply here.
> >>>
> >>> I am just looking at PR #170 that should backport to 7.0.x. I should
be
> >>> done in less than an hour.
> >>>
> >>> If you could delay the tag until after I have completed the back-port
> >>> that would be great. Don't worry if not.
> >>
> >> Ok
> >> Just let me know when you are ready.
> >
> > Thanks. I'm done.
>
> Actually...
>
> Do you want to wait for the Commons Daemon 1.2.2 release?
>

Ok
When will this be available?

Regards,
Violeta


[tomcat] branch master updated: Harmonize names with NIO

2019-10-02 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this push:
 new e68e417  Harmonize names with NIO
e68e417 is described below

commit e68e41700fd7235bc29f47c40624ee2da5c90698
Author: remm 
AuthorDate: Wed Oct 2 18:10:19 2019 +0200

Harmonize names with NIO
---
 java/org/apache/tomcat/util/net/Nio2Channel.java   | 14 +++---
 java/org/apache/tomcat/util/net/Nio2Endpoint.java  |  2 +-
 java/org/apache/tomcat/util/net/SecureNio2Channel.java | 16 
 3 files changed, 16 insertions(+), 16 deletions(-)

diff --git a/java/org/apache/tomcat/util/net/Nio2Channel.java 
b/java/org/apache/tomcat/util/net/Nio2Channel.java
index 90986a5..4980170 100644
--- a/java/org/apache/tomcat/util/net/Nio2Channel.java
+++ b/java/org/apache/tomcat/util/net/Nio2Channel.java
@@ -36,9 +36,9 @@ public class Nio2Channel implements AsynchronousByteChannel {
 
 protected static final ByteBuffer emptyBuf = ByteBuffer.allocate(0);
 
-protected AsynchronousSocketChannel sc = null;
-protected SocketWrapperBase socket = null;
 protected final SocketBufferHandler bufHandler;
+protected AsynchronousSocketChannel sc = null;
+protected SocketWrapperBase socketWrapper = null;
 
 public Nio2Channel(SocketBufferHandler bufHandler) {
 this.bufHandler = bufHandler;
@@ -48,14 +48,14 @@ public class Nio2Channel implements AsynchronousByteChannel 
{
  * Reset the channel.
  *
  * @param channel The new async channel to associate with this NIO2 channel
- * @param socket  The new socket to associate with this NIO2 channel
+ * @param socketWrapper The new socket to associate with this NIO2 channel
  *
  * @throws IOException If a problem was encountered resetting the channel
  */
-public void reset(AsynchronousSocketChannel channel, 
SocketWrapperBase socket)
+public void reset(AsynchronousSocketChannel channel, 
SocketWrapperBase socketWrapper)
 throws IOException {
 this.sc = channel;
-this.socket = socket;
+this.socketWrapper = socketWrapper;
 bufHandler.reset();
 }
 
@@ -66,8 +66,8 @@ public class Nio2Channel implements AsynchronousByteChannel {
 bufHandler.free();
 }
 
-public SocketWrapperBase getSocket() {
-return socket;
+SocketWrapperBase getSocketWrapper() {
+return socketWrapper;
 }
 
 
diff --git a/java/org/apache/tomcat/util/net/Nio2Endpoint.java 
b/java/org/apache/tomcat/util/net/Nio2Endpoint.java
index 88c17cc..0ff7c4f 100644
--- a/java/org/apache/tomcat/util/net/Nio2Endpoint.java
+++ b/java/org/apache/tomcat/util/net/Nio2Endpoint.java
@@ -213,7 +213,7 @@ public class Nio2Endpoint extends 
AbstractJsseEndpoint 0) {
@@ -296,7 +296,7 @@ public class SecureNio2Channel extends Nio2Channel  {
 //should actually return OP_READ if we have NEED_UNWRAP
 if (async) {
 sc.write(netOutBuffer, 
AbstractEndpoint.toTimeout(timeout),
-TimeUnit.MILLISECONDS, socket, 
handshakeWriteCompletionHandler);
+TimeUnit.MILLISECONDS, socketWrapper, 
handshakeWriteCompletionHandler);
 } else {
 try {
 if (timeout > 0) {
@@ -328,7 +328,7 @@ public class SecureNio2Channel extends Nio2Channel  {
 //read more data
 if (async) {
 sc.read(netInBuffer, 
AbstractEndpoint.toTimeout(timeout),
-TimeUnit.MILLISECONDS, socket, 
handshakeReadCompletionHandler);
+TimeUnit.MILLISECONDS, socketWrapper, 
handshakeReadCompletionHandler);
 } else {
 try {
 int read;
@@ -373,7 +373,7 @@ public class SecureNio2Channel extends Nio2Channel  {
 // SNIExtractor only to discover there is no data to process
 if (netInBuffer.position() == 0) {
 sc.read(netInBuffer, 
AbstractEndpoint.toTimeout(endpoint.getConnectionTimeout()),
-TimeUnit.MILLISECONDS, socket, 
handshakeReadCompletionHandler);
+TimeUnit.MILLISECONDS, socketWrapper, 
handshakeReadCompletionHandler);
 return 1;
 }
 
@@ -389,7 +389,7 @@ public class SecureNio2Channel extends Nio2Channel  {
 
 netInBuffer = ByteBufferUtils.expand(netInBuffer, newLimit);
 sc.read(netInBuffer, 
AbstractEndpoint.toTimeout(endpoint.getConnectionTimeout()),
-TimeUnit.MILLISECONDS, socket, 
handshakeReadCompletionHandler);
+TimeUnit.MILLISECONDS, socketWrapper, 
handshakeReadCompletion

[tomcat] branch master updated: Minor NIO refactoring to align with NIO2

2019-10-02 Thread remm
This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this push:
 new 2e47b58  Minor NIO refactoring to align with NIO2
2e47b58 is described below

commit 2e47b58fb3667f56a5d7332ffb6fd3c7ce13b8a0
Author: remm 
AuthorDate: Wed Oct 2 17:53:25 2019 +0200

Minor NIO refactoring to align with NIO2

NIO2 uses the reset() method instead of setter in a weird order, this
looks better to me.
---
 java/org/apache/tomcat/util/net/NioChannel.java| 28 +++---
 java/org/apache/tomcat/util/net/NioEndpoint.java   |  6 ++---
 .../apache/tomcat/util/net/SecureNioChannel.java   |  7 +++---
 3 files changed, 14 insertions(+), 27 deletions(-)

diff --git a/java/org/apache/tomcat/util/net/NioChannel.java 
b/java/org/apache/tomcat/util/net/NioChannel.java
index 9f39afb..75bc3f8 100644
--- a/java/org/apache/tomcat/util/net/NioChannel.java
+++ b/java/org/apache/tomcat/util/net/NioChannel.java
@@ -44,23 +44,21 @@ public class NioChannel implements ByteChannel, 
ScatteringByteChannel, Gathering
 protected SocketChannel sc = null;
 protected NioSocketWrapper socketWrapper = null;
 
-public NioChannel(SocketChannel channel, SocketBufferHandler bufHandler) {
-this.sc = channel;
+public NioChannel(SocketBufferHandler bufHandler) {
 this.bufHandler = bufHandler;
 }
 
 /**
  * Reset the channel
  *
+ * @param channel the socket channel
+ * @param socketWrapper the socket wrapper
  * @throws IOException If a problem was encountered resetting the channel
  */
-public void reset() throws IOException {
-bufHandler.reset();
-}
-
-
-void setSocketWrapper(NioSocketWrapper socketWrapper) {
+public void reset(SocketChannel channel, NioSocketWrapper socketWrapper) 
throws IOException {
+this.sc = channel;
 this.socketWrapper = socketWrapper;
+bufHandler.reset();
 }
 
 /**
@@ -205,10 +203,6 @@ public class NioChannel implements ByteChannel, 
ScatteringByteChannel, Gathering
 return 0;
 }
 
-public void setIOChannel(SocketChannel sc) {
-this.sc = sc;
-}
-
 @Override
 public String toString() {
 return super.toString() + ":" + sc.toString();
@@ -257,7 +251,7 @@ public class NioChannel implements ByteChannel, 
ScatteringByteChannel, Gathering
 static final NioChannel CLOSED_NIO_CHANNEL = new ClosedNioChannel();
 public static class ClosedNioChannel extends NioChannel {
 public ClosedNioChannel() {
-super(null, SocketBufferHandler.EMPTY);
+super(SocketBufferHandler.EMPTY);
 }
 @Override
 public void close() throws IOException {
@@ -267,18 +261,12 @@ public class NioChannel implements ByteChannel, 
ScatteringByteChannel, Gathering
 return false;
 }
 @Override
-public void reset() throws IOException {
+public void reset(SocketChannel channel, NioSocketWrapper 
socketWrapper) throws IOException {
 }
 @Override
 public void free() {
 }
 @Override
-void setSocketWrapper(NioSocketWrapper socketWrapper) {
-}
-@Override
-public void setIOChannel(SocketChannel sc) {
-}
-@Override
 public void setAppReadBufHandler(ApplicationBufferHandler handler) {
 }
 @Override
diff --git a/java/org/apache/tomcat/util/net/NioEndpoint.java 
b/java/org/apache/tomcat/util/net/NioEndpoint.java
index 78a74f0..99d8896 100644
--- a/java/org/apache/tomcat/util/net/NioEndpoint.java
+++ b/java/org/apache/tomcat/util/net/NioEndpoint.java
@@ -412,14 +412,12 @@ public class NioEndpoint extends 
AbstractJsseEndpoint
 if (isSSLEnabled()) {
 channel = new SecureNioChannel(socket, bufhandler, 
selectorPool, this);
 } else {
-channel = new NioChannel(socket, bufhandler);
+channel = new NioChannel(bufhandler);
 }
 } else {
-channel.setIOChannel(socket);
-channel.reset();
 }
 NioSocketWrapper socketWrapper = new NioSocketWrapper(channel, 
this);
-channel.setSocketWrapper(socketWrapper);
+channel.reset(socket, socketWrapper);
 socketWrapper.setReadTimeout(getConnectionTimeout());
 socketWrapper.setWriteTimeout(getConnectionTimeout());
 
socketWrapper.setKeepAliveLeft(NioEndpoint.this.getMaxKeepAliveRequests());
diff --git a/java/org/apache/tomcat/util/net/SecureNioChannel.java 
b/java/org/apache/tomcat/util/net/SecureNioChannel.java
index 5dc2fe5..4c4c85a 100644
--- a/java/org/apache/tomcat/util/net/SecureNioChannel.java
+++ b/java/org/apache/tomcat/util/net/SecureNioChannel.java
@

Re: Tag Tomcat 7

2019-10-02 Thread Mark Thomas
On 01/10/2019 12:18, Mark Thomas wrote:
> On 01/10/2019 12:17, Violeta Georgieva wrote:
>> Hi Mark,
>>
>> На вт, 1.10.2019 г. в 13:58 ч. Mark Thomas > > написа:
>>>
>>> On 01/10/2019 11:09, Violeta Georgieva wrote:
 Hi,

 I'm planning to tag Tomcat 7 later today.
 If you want to include something please reply here.
>>>
>>> I am just looking at PR #170 that should backport to 7.0.x. I should be
>>> done in less than an hour.
>>>
>>> If you could delay the tag until after I have completed the back-port
>>> that would be great. Don't worry if not.
>>
>> Ok
>> Just let me know when you are ready.
> 
> Thanks. I'm done.

Actually...

Do you want to wait for the Commons Daemon 1.2.2 release?

Mark

-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



svn commit: r1867891 - in /tomcat/jk/trunk: native/apache-2.0/mod_jk.c xdocs/miscellaneous/changelog.xml

2019-10-02 Thread markt
Author: markt
Date: Wed Oct  2 15:00:48 2019
New Revision: 1867891

URL: http://svn.apache.org/viewvc?rev=1867891&view=rev
Log:
Fix a bug in the normalization checks that prevented file based requests, such 
as SSI file includes, from being processed.

Modified:
tomcat/jk/trunk/native/apache-2.0/mod_jk.c
tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml

Modified: tomcat/jk/trunk/native/apache-2.0/mod_jk.c
URL: 
http://svn.apache.org/viewvc/tomcat/jk/trunk/native/apache-2.0/mod_jk.c?rev=1867891&r1=1867890&r2=1867891&view=diff
==
--- tomcat/jk/trunk/native/apache-2.0/mod_jk.c (original)
+++ tomcat/jk/trunk/native/apache-2.0/mod_jk.c Wed Oct  2 15:00:48 2019
@@ -4035,6 +4035,15 @@ static int jk_map_to_storage(request_rec
 return DECLINED;
 }
 
+// Not a URI based request - e.g. file based SSI include
+if (strlen(r->uri) == 0) {
+jk_log(conf->log, JK_LOG_DEBUG,
+   "File based (sub-)request for file=%s. No URI to 
match.",
+  r->filename);
+JK_TRACE_EXIT(conf->log);
+return DECLINED;
+}
+
 clean_uri = apr_pstrdup(r->pool, r->uri);
 rc = jk_servlet_normalize(clean_uri, conf->log);
 if (rc != 0) {

Modified: tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml?rev=1867891&r1=1867890&r2=1867891&view=diff
==
--- tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml (original)
+++ tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml Wed Oct  2 15:00:48 2019
@@ -47,6 +47,10 @@
 Extend trace level logging of method entry/exit to aid debugging of
 request mapping issues. (markt)
   
+  
+Fix a bug in the normalization checks that prevented file based
+requests, such as SSI file includes, from being processed. (markt)
+  
 
   
 



-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



svn commit: r1867890 - in /tomcat/jk/trunk: native/apache-2.0/mod_jk.c xdocs/miscellaneous/changelog.xml

2019-10-02 Thread markt
Author: markt
Date: Wed Oct  2 14:56:48 2019
New Revision: 1867890

URL: http://svn.apache.org/viewvc?rev=1867890&view=rev
Log:
Extend trace level logging of method entry/exit to aid debugging of request 
mapping issues.

Modified:
tomcat/jk/trunk/native/apache-2.0/mod_jk.c
tomcat/jk/trunk/xdocs/miscellaneous/changelog.xml

Modified: tomcat/jk/trunk/native/apache-2.0/mod_jk.c
URL: 
http://svn.apache.org/viewvc/tomcat/jk/trunk/native/apache-2.0/mod_jk.c?rev=1867890&r1=1867889&r2=1867890&view=diff
==
--- tomcat/jk/trunk/native/apache-2.0/mod_jk.c (original)
+++ tomcat/jk/trunk/native/apache-2.0/mod_jk.c Wed Oct  2 14:56:48 2019
@@ -2793,6 +2793,7 @@ static int jk_handler(request_rec * r)
 clean_uri = apr_pstrdup(r->pool, r->uri);
 rc = jk_servlet_normalize(clean_uri, xconf->log);
 if (rc != 0) {
+JK_TRACE_EXIT(xconf->log);
 return HTTP_BAD_REQUEST;
 }
 
@@ -3788,6 +3789,8 @@ static int jk_translate(request_rec * r)
 int rc;
 const char *worker;
 
+JK_TRACE_ENTER(conf->log);
+
 if ((r->handler != NULL) && (!strcmp(r->handler, JK_HANDLER))) {
 /* Somebody already set the handler, probably manual config
  * or "native" configuration, no need for extra overhead
@@ -3795,6 +3798,7 @@ static int jk_translate(request_rec * r)
 if (JK_IS_DEBUG_LEVEL(conf->log))
 jk_log(conf->log, JK_LOG_DEBUG,
"Manually mapped, no need to call uri_to_worker");
+JK_TRACE_EXIT(conf->log);
 return DECLINED;
 }
 
@@ -3804,12 +3808,14 @@ static int jk_translate(request_rec * r)
"Into translate no-jk env var detected for uri=%s, 
declined",
r->uri);
 
+JK_TRACE_EXIT(conf->log);
 return DECLINED;
 }
 
 clean_uri = apr_pstrdup(r->pool, r->uri);
 rc = jk_servlet_normalize(clean_uri, conf->log);
 if (rc != 0) {
+JK_TRACE_EXIT(conf->log);
 return HTTP_BAD_REQUEST;
 }
 
@@ -3842,6 +3848,7 @@ static int jk_translate(request_rec * r)
 jk_log(conf->log, JK_LOG_DEBUG,
"JkAutoAlias, no DirectoryIndex file for URI 
%s",
r->uri);
+JK_TRACE_EXIT(conf->log);
 return DECLINED;
 }
 }
@@ -3851,6 +3858,7 @@ static int jk_translate(request_rec * r)
"missing uri map for %s:%s",
conf->s->server_hostname ? conf->s->server_hostname 
: "_default_",
r->uri);
+JK_TRACE_EXIT(conf->log);
 return DECLINED;
 }
 else {
@@ -3875,6 +3883,7 @@ static int jk_translate(request_rec * r)
 apr_table_setn(r->main->notes, JK_NOTE_WORKER_NAME, 
worker);
 }
 
+JK_TRACE_EXIT(conf->log);
 return OK;
 }
 else if (conf->alias_dir != NULL) {
@@ -3915,6 +3924,7 @@ static int jk_translate(request_rec * r)
 jk_log(conf->log, JK_LOG_DEBUG,
"AutoAlias HTTP_NOT_FOUND for URI: 
%s",
r->uri);
+JK_TRACE_EXIT(conf->log);
 return HTTP_NOT_FOUND;
 }
 }
@@ -3945,6 +3955,7 @@ static int jk_translate(request_rec * r)
"AutoAlias OK for file: %s",
ret);
 r->filename = ret;
+JK_TRACE_EXIT(conf->log);
 return OK;
 }
 }
@@ -3958,6 +3969,7 @@ static int jk_translate(request_rec * r)
 jk_log(conf->log, JK_LOG_DEBUG,
"AutoAlias HTTP_FORBIDDEN for URI: 
%s",
r->uri);
+JK_TRACE_EXIT(conf->log);
 return HTTP_FORBIDDEN;
 }
 }
@@ -4000,6 +4012,8 @@ static int jk_map_to_storage(request_rec
 int rc;
 const char *worker;
 
+JK_TRACE_ENTER(conf->log);
+
 if ((r->handler != NULL) && (!strcmp(r->handler, JK_HANDLER))) {
 /* Somebody already set the handler, probably manual config
  * or "native" configuration, no 

[tomcat] branch master updated: Fix memory leak with HTTP/2 and WebSocket

2019-10-02 Thread markt
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this push:
 new 069be70  Fix memory leak with HTTP/2 and WebSocket
069be70 is described below

commit 069be707125fa4391dd6221e36c710d8bc8e3963
Author: Mark Thomas 
AuthorDate: Wed Oct 2 12:19:44 2019 +0100

Fix memory leak with HTTP/2 and WebSocket
---
 java/org/apache/coyote/AbstractProtocol.java   | 23 --
 .../http11/upgrade/UpgradeProcessorInternal.java   |  5 +
 webapps/docs/changelog.xml |  4 
 3 files changed, 26 insertions(+), 6 deletions(-)

diff --git a/java/org/apache/coyote/AbstractProtocol.java 
b/java/org/apache/coyote/AbstractProtocol.java
index 9753447..748be34 100644
--- a/java/org/apache/coyote/AbstractProtocol.java
+++ b/java/org/apache/coyote/AbstractProtocol.java
@@ -40,6 +40,7 @@ import javax.servlet.http.HttpUpgradeHandler;
 import javax.servlet.http.WebConnection;
 
 import org.apache.coyote.http11.upgrade.InternalHttpUpgradeHandler;
+import org.apache.coyote.http11.upgrade.UpgradeProcessorInternal;
 import org.apache.juli.logging.Log;
 import org.apache.tomcat.InstanceManager;
 import org.apache.tomcat.util.ExceptionUtils;
@@ -1053,12 +1054,22 @@ public abstract class AbstractProtocol implements 
ProtocolHandler,
 private void release(Processor processor) {
 if (processor != null) {
 processor.recycle();
-// After recycling, only instances of UpgradeProcessorBase will
-// return true for isUpgrade().
-// Instances of UpgradeProcessorBase should not be added to
-// recycledProcessors since that pool is only for AJP or HTTP
-// processors
-if (!processor.isUpgrade()) {
+if (processor.isUpgrade()) {
+// UpgradeProcessorInternal instances can utilise AsyncIO.
+// If they do, the processor will not pass through the
+// process() method and be removed from waitingProcessors
+// so do that here.
+if (processor instanceof UpgradeProcessorInternal) {
+if (((UpgradeProcessorInternal) 
processor).hasAsyncIO()) {
+getProtocol().removeWaitingProcessor(processor);
+}
+}
+} else {
+// After recycling, only instances of UpgradeProcessorBase
+// will return true for isUpgrade().
+// Instances of UpgradeProcessorBase should not be added to
+// recycledProcessors since that pool is only for AJP or
+// HTTP processors
 recycledProcessors.push(processor);
 getLog().debug("Pushed Processor [" + processor + "]");
 }
diff --git 
a/java/org/apache/coyote/http11/upgrade/UpgradeProcessorInternal.java 
b/java/org/apache/coyote/http11/upgrade/UpgradeProcessorInternal.java
index f0f5460..0e99265 100644
--- a/java/org/apache/coyote/http11/upgrade/UpgradeProcessorInternal.java
+++ b/java/org/apache/coyote/http11/upgrade/UpgradeProcessorInternal.java
@@ -79,6 +79,11 @@ public class UpgradeProcessorInternal extends 
UpgradeProcessorBase {
 }
 
 
+public boolean hasAsyncIO() {
+return internalHttpUpgradeHandler.hasAsyncIO();
+}
+
+
 // --- AutoCloseable 
methods
 
 @Override
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index b3093a2..4ed78e0 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -69,6 +69,10 @@
 an HTTP upgrade connection that terminates before processing switches 
to
 the Processor for the upgraded protocol. (markt)
   
+  
+Fix a memory leak introduced by the HTTP/2 timeout refactoring in 
9.0.23
+that could occur when HTTP/2 or WebSocket was used. (markt)
+  
 
   
   


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[tomcat] branch 7.0.x updated: Fixes having an issue number are sorted by their number, ascending.

2019-10-02 Thread violetagg
This is an automated email from the ASF dual-hosted git repository.

violetagg pushed a commit to branch 7.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/7.0.x by this push:
 new 1d8fd37  Fixes having an issue number are sorted by their number, 
ascending.
1d8fd37 is described below

commit 1d8fd374200bc3da3beb157d0d2b6839fe267d11
Author: Violeta Georgieva 
AuthorDate: Wed Oct 2 10:33:17 2019 +0300

Fixes having an issue number are sorted by their number, ascending.
---
 webapps/docs/changelog.xml | 90 +++---
 1 file changed, 45 insertions(+), 45 deletions(-)

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 2494008..438223d 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -62,23 +62,23 @@
 
   
 
-  
-63627: Implement more fine-grained handling in
-RealmBase.authenticate(GSSContext, boolean). (michaelo)
-  
-  
-62496: Add option to write auth information (remote 
user/auth type)
-to response headers. (michaelo)
-  
   
 57665: Add support for the X-Forwarded-Host
 header to the RemoteIpFilter and 
RemotepValve.
 (markt)
   
+  
+62496: Add option to write auth information (remote 
user/auth type)
+to response headers. (michaelo)
+  
   
 63550: Only try the alternateURL in the
 JNDIRealm if one has been specified. (markt)
   
+  
+63627: Implement more fine-grained handling in
+RealmBase.authenticate(GSSContext, boolean). (michaelo)
+  
   
 Avoid a NullPointerException in the
 CrawlerSessionManagerValve if no ROOT Context is deployed
@@ -194,6 +194,11 @@
   
 
   
+55620: Partial fix. Prevent Tomcat from starting when
+$CATALINA_HOME and/or $CATALINA_BASE contains
+a semi-colon on Windows or a colon on Linux/FreeBSD/etc. (markt)
+  
+  
 62140: Additional usage documentation in comments for
 catalina.[bat|sh]. (markt)
   
@@ -207,6 +212,11 @@
 --rename option after the service name. (markt)
   
   
+63625: Update to Commons Daemon 1.2.1. This corrects several
+regressions in Commons Daemon 1.2.0, most notably the Windows Service
+crashing on start when using 32-bit JVMs. (markt)
+  
+  
 63634: Align setproxy target in build.xml with
 8.5/9.0. (michaelo)
   
@@ -214,11 +224,6 @@
 Limit the default JPDA (remote debugging interface) listen address to
 localhost:8000. (markt)
   
-  
-55620: Partial fix. Prevent Tomcat from starting when
-$CATALINA_HOME and/or $CATALINA_BASE contains
-a semi-colon on Windows or a colon on Linux/FreeBSD/etc. (markt)
-  
   
 Tighten up the default file permissions for the .tar.gz
 distribution so no files or directories are world readable by default.
@@ -235,11 +240,6 @@
 pick up the fix for CODEC-134. (markt)
   
   
-63625: Update to Commons Daemon 1.2.1. This corrects several
-regressions in Commons Daemon 1.2.0, most notably the Windows Service
-crashing on start when using 32-bit JVMs. (markt)
-  
-  
 63648: Update the test TLS keys and certificates used in the
 test suite to replace the keys and certificates that are about to
 expire. (markt)
@@ -347,6 +347,22 @@
   
 
   
+43548: Add an XML schema for the tomcat-users.xml file.
+(markt)
+  
+  
+63324: Refactor the CrawlerSessionManagerValve
+so that the object placed in the session is compatible with session
+serialization with mem-cached. Patch provided by Martin Lemanski.
+(markt)
+  
+  
+63531: Refactor authenticators so that the session last
+accessed time is not updated if the cache attribute is set to
+false and FORM authentication is not being
+used. (markt)
+  
+  
 63556: Mark request as forwarded in RemoteIpValve and
 RemoteIpFilter (michaelo)
   
@@ -383,16 +399,6 @@
 defined in server.xml with a docBase but not
 the optional path. (markt)
   
-  
-43548: Add an XML schema for the tomcat-users.xml file.
-(markt)
-  
-  
-63324: Refactor the CrawlerSessionManagerValve
-so that the object placed in the session is compatible with session
-serialization with mem-cached. Patch provided by Martin Lemanski.
-(markt)
-  
   
 Ensure that the default servlet reads the entire global XSLT file if
 one is defined. Identified by Coverity Scan. (markt)
@@ -406,12 +412,6 @@
 RequestDispatcher. The requested target path is logged as 
a
 warning since this is an appl

[tomcat] branch 8.5.x updated: Fixes having an issue number are sorted by their number, ascending.

2019-10-02 Thread violetagg
This is an automated email from the ASF dual-hosted git repository.

violetagg pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
 new cc85b6c  Fixes having an issue number are sorted by their number, 
ascending.
cc85b6c is described below

commit cc85b6c305870d5cdd1609b5bee253ec1d9ae1df
Author: Violeta Georgieva 
AuthorDate: Wed Oct 2 10:27:25 2019 +0300

Fixes having an issue number are sorted by their number, ascending.
---
 webapps/docs/changelog.xml | 64 +++---
 1 file changed, 32 insertions(+), 32 deletions(-)

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index e9f142a..160d851 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -274,10 +274,6 @@
 the error has caused the connection to the client to be closed as 
no-one
 will ever see the error page. (markt)
   
-  
-63627: Implement more fine-grained handling in
-RealmBase.authenticate(GSSContext, boolean). (michaelo)
-  
   
 62496: Add option to write auth information (remote 
user/auth type)
 to response headers. (michaelo)
@@ -301,6 +297,20 @@
 RemoteIpFilter (michaelo)
   
   
+63579: Correct parsing of malformed OPTIONS requests and
+reject them with a 400 response rather than triggering an internal 
error
+that results in a 500 response. (markt)
+  
+  
+63608: Align the implementation of the negative match 
feature
+for patterns used with the RewriteValve with the
+description in the documentation. (markt)
+  
+  
+63627: Implement more fine-grained handling in
+RealmBase.authenticate(GSSContext, boolean). (michaelo)
+  
+  
 If an unhandled exception occurs on a asynchronous thread started via
 AsyncContext.start(Runnable), process it using the 
standard
 error page mechanism. (markt)
@@ -310,19 +320,9 @@
 the request. (remm)
   
   
-63579: Correct parsing of malformed OPTIONS requests and
-reject them with a 400 response rather than triggering an internal 
error
-that results in a 500 response. (markt)
-  
-  
 Correct version information in X-Powered-By header. 
(markt)
   
   
-63608: Align the implementation of the negative match 
feature
-for patterns used with the RewriteValve with the
-description in the documentation. (markt)
-  
-  
 Avoid a NullPointerException in the
 CrawlerSessionManagerValve if no ROOT Context is deployed
 and a request does not map to any of the other deployed Contexts. Patch
@@ -396,6 +396,18 @@
   
 
   
+55969: Tighten up the security of the Apache Tomcat
+installation created by the Windows installer. Change the default
+shutdown port used by the Windows installer from 8005 to
+-1 (disabled). Limit access to the chosen installation
+directory to local administrators, Local System and Local Service.
+(markt)
+  
+  
+62696: The digital signature for the Windows installer now
+uses SHA-256 for hashes. (markt)
+  
+  
 63285: Modify service.bat so that when
 installing a Windows service, by default, it changes the name of the
 executables used by the Windows service to match the service name. This
@@ -409,24 +421,6 @@
 This allows Tomcat 8.5 to use the newer Checkstyle releases while still
 building with Java 7. (markt)
   
-  
-62696: The digital signature for the Windows installer now
-uses SHA-256 for hashes. (markt)
-  
-  
-63310: Update to Commons Daemon 1.2.0. This provides 
improved
-support for Java 11. This also changes the user configured by the
-Windows installer for the Windows service from Local 
System
-to the lower privileged Local Service. (markt)
-  
-  
-55969: Tighten up the security of the Apache Tomcat
-installation created by the Windows installer. Change the default
-shutdown port used by the Windows installer from 8005 to
--1 (disabled). Limit access to the chosen installation
-directory to local administrators, Local System and Local Service.
-(markt)
-  
   
 63285: Add an option to service.bat so that 
when
 installing a Windows service, the name of the executables used by the
@@ -436,6 +430,12 @@
 removed. The renaming can be enabled by using the new
 --rename option after the service name. (markt)
   
+  
+63310: Update to Commons Daemon 1.2.0. This provides 
improved
+support for Java 11. This also changes the user configured by the
+Windows installer 

[tomcat] branch master updated: Fixes having an issue number are sorted by their number, ascending.

2019-10-02 Thread violetagg
This is an automated email from the ASF dual-hosted git repository.

violetagg pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this push:
 new 02c17de  Fixes having an issue number are sorted by their number, 
ascending.
02c17de is described below

commit 02c17de7cee8b934084f31fb6272e932102b6d60
Author: Violeta Georgieva 
AuthorDate: Wed Oct 2 10:21:15 2019 +0300

Fixes having an issue number are sorted by their number, ascending.
---
 webapps/docs/changelog.xml | 80 +++---
 1 file changed, 40 insertions(+), 40 deletions(-)

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 8f901f5..b3093a2 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -309,19 +309,15 @@
 
   
 
-  
-63627: Implement more fine-grained handling in
-RealmBase.authenticate(GSSContext, boolean). (michaelo)
-  
-  
-62496: Add option to write auth information (remote 
user/auth type)
-to response headers. (michaelo)
-  
   
 57665: Add support for the X-Forwarded-Host
 header to the RemoteIpFilter and 
RemoteIpValve.
 (markt)
   
+  
+62496: Add option to write auth information (remote 
user/auth type)
+to response headers. (michaelo)
+  
   
 63550: Only try the alternateURL in the
 JNDIRealm if one has been specified. (markt)
@@ -331,15 +327,6 @@
 RemoteIpFilter (michaelo)
   
   
-If an unhandled exception occurs on a asynchronous thread started via
-AsyncContext.start(Runnable), process it using the 
standard
-error page mechanism. (markt)
-  
-  
-Discard large byte buffers allocated using setBufferSize when recycling
-the request. (remm)
-  
-  
 63579: Correct parsing of malformed OPTIONS requests and
 reject them with a 400 response rather than triggering an internal 
error
 that results in a 500 response. (markt)
@@ -349,6 +336,19 @@
 for patterns used with the RewriteValve with the
 description in the documentation. (markt)
   
+  
+63627: Implement more fine-grained handling in
+RealmBase.authenticate(GSSContext, boolean). (michaelo)
+  
+  
+If an unhandled exception occurs on a asynchronous thread started via
+AsyncContext.start(Runnable), process it using the 
standard
+error page mechanism. (markt)
+  
+  
+Discard large byte buffers allocated using setBufferSize when recycling
+the request. (remm)
+  
   
 Avoid a NullPointerException in the
 CrawlerSessionManagerValve if no ROOT Context is deployed
@@ -380,15 +380,15 @@
 (remm)
   
   
-63570: Fix regression retrieving local address with
-the NIO connector. Submitted by Aditya Kadakia. (remm)
-  
-  
 63568: Avoid error when trying to set tcpNoDelay on socket
 types that do not support it, which can occur when using the NIO
 inherited channel capability. Submitted by František Kučera. (remm)
   
   
+63570: Fix regression retrieving local address with
+the NIO connector. Submitted by Aditya Kadakia. (remm)
+  
+  
 Correct parsing of invalid host names that contain bytes in the range
 128 to 255 and reject them with a 400 response rather than triggering 
an
 internal error that results in a 500 response. (markt)
@@ -470,16 +470,6 @@
   
 Update Checkstyle to 8.22. (markt)
   
-  
-62696: The digital signature for the Windows installer now
-uses SHA-256 for hashes. (markt)
-  
-  
-63310: Update to Commons Daemon 1.2.0. This provides 
improved
-support for Java 11. This also changes the user configured by the
-Windows installer for the Windows service from Local 
System
-to the lower privileged Local Service. (markt)
-  
   
 55969: Tighten up the security of the Apache Tomcat
 installation created by the Windows installer. Change the default
@@ -488,10 +478,10 @@
 directory to local administrators, Local System and Local Service.
 (markt)
   
-  
-Expand the coverage and quality of the French translations provided
-with Apache Tomcat. (remm)
-  
+  
+62696: The digital signature for the Windows installer now
+uses SHA-256 for hashes. (markt)
+  
   
 63285: Add an option to service.bat so that 
when
 installing a Windows service, the name of the executables used by the
@@ -501,6 +491,21 @@
 is removed. The renaming can be enabled by using the new
 --rename option after the service name. (markt)
   
+  
+ 

[tomcat] branch 7.0.x updated: Fix typos

2019-10-02 Thread violetagg
This is an automated email from the ASF dual-hosted git repository.

violetagg pushed a commit to branch 7.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/7.0.x by this push:
 new a491e1a  Fix typos
a491e1a is described below

commit a491e1a4e7cd7af8806867743cd913df47e2d6c3
Author: Violeta Georgieva 
AuthorDate: Wed Oct 2 10:11:10 2019 +0300

Fix typos
---
 webapps/docs/changelog.xml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index c4e3fcd..2494008 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -100,7 +100,7 @@
   
   
 Avoid a potential NullPointerException on Service stop if 
a
-Service is embedded directly (i.e. with no Server) in an applciation
+Service is embedded directly (i.e. with no Server) in an application
 and JNDI is enabled. Patch provided by S. Ali Tokmen. (markt)
   
   
@@ -145,7 +145,7 @@
   
 63766: Ensure Processor objects are recycled when processing
 an HTTP upgrade connection that terminates before processing switches 
to
-the Processor for the upgraded procotol. (markt)
+the Processor for the upgraded protocol. (markt)
   
 
   


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[tomcat] branch 8.5.x updated: Fix typos

2019-10-02 Thread violetagg
This is an automated email from the ASF dual-hosted git repository.

violetagg pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
 new fa8de32  Fix typos
fa8de32 is described below

commit fa8de3284d41abfe26f04e6d68b9b08a7bad8443
Author: Violeta Georgieva 
AuthorDate: Wed Oct 2 09:59:48 2019 +0300

Fix typos
---
 webapps/docs/changelog.xml | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 0af1788..e9f142a 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -59,7 +59,7 @@
   
 63766: Ensure Processor objects are recycled when processing
 an HTTP upgrade connection that terminates before processing switches 
to
-the Processor for the upgraded procotol. (markt)
+the Processor for the upgraded protocol. (markt)
   
 
   
@@ -119,7 +119,7 @@
   
   
 Avoid a potential NullPointerException on Service stop if 
a
-Service is embedded directly (i.e. with no Server) in an applciation
+Service is embedded directly (i.e. with no Server) in an application
 and JNDI is enabled. Patch provided by S. Ali Tokmen. (markt)
   
   
@@ -222,7 +222,7 @@
 Add Korean translations to the standard Tomcat distribution. (markt)
   
   
-Add Simplifed Chinese translations to the standard Tomcat distribution.
+Add Simplified Chinese translations to the standard Tomcat 
distribution.
 (markt)
   
   


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org



[tomcat] branch master updated: Fix typos

2019-10-02 Thread violetagg
This is an automated email from the ASF dual-hosted git repository.

violetagg pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/master by this push:
 new 8db21b3  Fix typos
8db21b3 is described below

commit 8db21b3894fefab07a7fed0bf8ff2b4e147662e9
Author: Violeta Georgieva 
AuthorDate: Wed Oct 2 09:59:48 2019 +0300

Fix typos
---
 webapps/docs/changelog.xml | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 4c27a08..8f901f5 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -67,7 +67,7 @@
   
 63766: Ensure Processor objects are recycled when processing
 an HTTP upgrade connection that terminates before processing switches 
to
-the Processor for the upgraded procotol. (markt)
+the Processor for the upgraded protocol. (markt)
   
 
   
@@ -160,7 +160,7 @@
   
   
 Avoid a potential NullPointerException on Service stop if 
a
-Service is embedded directly (i.e. with no Server) in an applciation
+Service is embedded directly (i.e. with no Server) in an application
 and JNDI is enabled. Patch provided by S. Ali Tokmen. (markt)
   
   
@@ -511,7 +511,7 @@
   
   
 Add "embed" to the Bundle-Name and
-Bundle-Symbolic-Name for the Tomact embedded WebSocket JAR
+Bundle-Symbolic-Name for the Tomcat embedded WebSocket JAR
 to align the naming with the other embedded JARs and to differentiate 
it
 from the standard WebSocket JAR that does not include the API classes.
 (markt)


-
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org