Invalid character found in the request target on Confluence behind nginx












0














Currently I'm using Confluene 6.10.2 behind nginx. I have some pages with the page name including character '>' could not accessible, the error is:




HTTP Status 400 – Bad Request Type Exception Report



Message Invalid character found in the request target. The valid
characters are defined in RFC 7230 and RFC 3986



Description The server cannot or will not process the request due to
something that is perceived to be a client error (e.g., malformed
request syntax, invalid request message framing, or deceptive request
routing).



Exception



java.lang.IllegalArgumentException: Invalid character found in the
request target. The valid characters are defined in RFC 7230 and RFC
3986
org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:474)
org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:294)
org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764)
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388)
org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
java.lang.Thread.run(Thread.java:748) Note The full stack trace of
the root cause is available in the server logs.



Apache Tomcat/9.0.10




But when I access the page bypassing the reverse proxy, it's ok, so it could be a problem in nginx.



I read logs in Confluence and nginx, but did not find any stranges, please advise me how to fix the issue.










share|improve this question






















  • For a lot of practical reasons, I would strongly discourage use of character such as ">" in file names, as most interactions with command line tools are likely to get confused.
    – Dragonthoughts
    Nov 13 '18 at 8:42










  • I think in nginx configuration must have some rewrite rule to by pass this issue
    – Tien Dung Tran
    Nov 13 '18 at 11:18
















0














Currently I'm using Confluene 6.10.2 behind nginx. I have some pages with the page name including character '>' could not accessible, the error is:




HTTP Status 400 – Bad Request Type Exception Report



Message Invalid character found in the request target. The valid
characters are defined in RFC 7230 and RFC 3986



Description The server cannot or will not process the request due to
something that is perceived to be a client error (e.g., malformed
request syntax, invalid request message framing, or deceptive request
routing).



Exception



java.lang.IllegalArgumentException: Invalid character found in the
request target. The valid characters are defined in RFC 7230 and RFC
3986
org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:474)
org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:294)
org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764)
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388)
org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
java.lang.Thread.run(Thread.java:748) Note The full stack trace of
the root cause is available in the server logs.



Apache Tomcat/9.0.10




But when I access the page bypassing the reverse proxy, it's ok, so it could be a problem in nginx.



I read logs in Confluence and nginx, but did not find any stranges, please advise me how to fix the issue.










share|improve this question






















  • For a lot of practical reasons, I would strongly discourage use of character such as ">" in file names, as most interactions with command line tools are likely to get confused.
    – Dragonthoughts
    Nov 13 '18 at 8:42










  • I think in nginx configuration must have some rewrite rule to by pass this issue
    – Tien Dung Tran
    Nov 13 '18 at 11:18














0












0








0


1





Currently I'm using Confluene 6.10.2 behind nginx. I have some pages with the page name including character '>' could not accessible, the error is:




HTTP Status 400 – Bad Request Type Exception Report



Message Invalid character found in the request target. The valid
characters are defined in RFC 7230 and RFC 3986



Description The server cannot or will not process the request due to
something that is perceived to be a client error (e.g., malformed
request syntax, invalid request message framing, or deceptive request
routing).



Exception



java.lang.IllegalArgumentException: Invalid character found in the
request target. The valid characters are defined in RFC 7230 and RFC
3986
org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:474)
org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:294)
org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764)
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388)
org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
java.lang.Thread.run(Thread.java:748) Note The full stack trace of
the root cause is available in the server logs.



Apache Tomcat/9.0.10




But when I access the page bypassing the reverse proxy, it's ok, so it could be a problem in nginx.



I read logs in Confluence and nginx, but did not find any stranges, please advise me how to fix the issue.










share|improve this question













Currently I'm using Confluene 6.10.2 behind nginx. I have some pages with the page name including character '>' could not accessible, the error is:




HTTP Status 400 – Bad Request Type Exception Report



Message Invalid character found in the request target. The valid
characters are defined in RFC 7230 and RFC 3986



Description The server cannot or will not process the request due to
something that is perceived to be a client error (e.g., malformed
request syntax, invalid request message framing, or deceptive request
routing).



Exception



java.lang.IllegalArgumentException: Invalid character found in the
request target. The valid characters are defined in RFC 7230 and RFC
3986
org.apache.coyote.http11.Http11InputBuffer.parseRequestLine(Http11InputBuffer.java:474)
org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:294)
org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:764)
org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1388)
org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
java.lang.Thread.run(Thread.java:748) Note The full stack trace of
the root cause is available in the server logs.



Apache Tomcat/9.0.10




But when I access the page bypassing the reverse proxy, it's ok, so it could be a problem in nginx.



I read logs in Confluence and nginx, but did not find any stranges, please advise me how to fix the issue.







nginx atlassian confluence






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 13 '18 at 8:39









Tien Dung TranTien Dung Tran

120111




120111












  • For a lot of practical reasons, I would strongly discourage use of character such as ">" in file names, as most interactions with command line tools are likely to get confused.
    – Dragonthoughts
    Nov 13 '18 at 8:42










  • I think in nginx configuration must have some rewrite rule to by pass this issue
    – Tien Dung Tran
    Nov 13 '18 at 11:18


















  • For a lot of practical reasons, I would strongly discourage use of character such as ">" in file names, as most interactions with command line tools are likely to get confused.
    – Dragonthoughts
    Nov 13 '18 at 8:42










  • I think in nginx configuration must have some rewrite rule to by pass this issue
    – Tien Dung Tran
    Nov 13 '18 at 11:18
















For a lot of practical reasons, I would strongly discourage use of character such as ">" in file names, as most interactions with command line tools are likely to get confused.
– Dragonthoughts
Nov 13 '18 at 8:42




For a lot of practical reasons, I would strongly discourage use of character such as ">" in file names, as most interactions with command line tools are likely to get confused.
– Dragonthoughts
Nov 13 '18 at 8:42












I think in nginx configuration must have some rewrite rule to by pass this issue
– Tien Dung Tran
Nov 13 '18 at 11:18




I think in nginx configuration must have some rewrite rule to by pass this issue
– Tien Dung Tran
Nov 13 '18 at 11:18












1 Answer
1






active

oldest

votes


















0














Probably you'll need to add a rewrite rule.




  • Nginx Rewrite to Replace a single Character

  • Nginx Doc - Creating Rewrite Rules





if ($request_uri ~ ^(/.*)[>](.*)$) { 
return 301 $1%3E$2;
}
if ($request_uri ~ ^(/.*)[<](.*)$) {
return 301 $1%3C$2;
}





You may want to place this inside a location block to limit the scope. See this caution on the use of if.






share|improve this answer





















  • Thanks, I tried it but no luck. I just found out that, the request has been drop from nginx, it not even go go confluence upstream.
    – Tien Dung Tran
    Nov 15 '18 at 7:13











Your Answer






StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");

StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53276927%2finvalid-character-found-in-the-request-target-on-confluence-behind-nginx%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














Probably you'll need to add a rewrite rule.




  • Nginx Rewrite to Replace a single Character

  • Nginx Doc - Creating Rewrite Rules





if ($request_uri ~ ^(/.*)[>](.*)$) { 
return 301 $1%3E$2;
}
if ($request_uri ~ ^(/.*)[<](.*)$) {
return 301 $1%3C$2;
}





You may want to place this inside a location block to limit the scope. See this caution on the use of if.






share|improve this answer





















  • Thanks, I tried it but no luck. I just found out that, the request has been drop from nginx, it not even go go confluence upstream.
    – Tien Dung Tran
    Nov 15 '18 at 7:13
















0














Probably you'll need to add a rewrite rule.




  • Nginx Rewrite to Replace a single Character

  • Nginx Doc - Creating Rewrite Rules





if ($request_uri ~ ^(/.*)[>](.*)$) { 
return 301 $1%3E$2;
}
if ($request_uri ~ ^(/.*)[<](.*)$) {
return 301 $1%3C$2;
}





You may want to place this inside a location block to limit the scope. See this caution on the use of if.






share|improve this answer





















  • Thanks, I tried it but no luck. I just found out that, the request has been drop from nginx, it not even go go confluence upstream.
    – Tien Dung Tran
    Nov 15 '18 at 7:13














0












0








0






Probably you'll need to add a rewrite rule.




  • Nginx Rewrite to Replace a single Character

  • Nginx Doc - Creating Rewrite Rules





if ($request_uri ~ ^(/.*)[>](.*)$) { 
return 301 $1%3E$2;
}
if ($request_uri ~ ^(/.*)[<](.*)$) {
return 301 $1%3C$2;
}





You may want to place this inside a location block to limit the scope. See this caution on the use of if.






share|improve this answer












Probably you'll need to add a rewrite rule.




  • Nginx Rewrite to Replace a single Character

  • Nginx Doc - Creating Rewrite Rules





if ($request_uri ~ ^(/.*)[>](.*)$) { 
return 301 $1%3E$2;
}
if ($request_uri ~ ^(/.*)[<](.*)$) {
return 301 $1%3C$2;
}





You may want to place this inside a location block to limit the scope. See this caution on the use of if.






if ($request_uri ~ ^(/.*)[>](.*)$) { 
return 301 $1%3E$2;
}
if ($request_uri ~ ^(/.*)[<](.*)$) {
return 301 $1%3C$2;
}





if ($request_uri ~ ^(/.*)[>](.*)$) { 
return 301 $1%3E$2;
}
if ($request_uri ~ ^(/.*)[<](.*)$) {
return 301 $1%3C$2;
}






share|improve this answer












share|improve this answer



share|improve this answer










answered Nov 14 '18 at 15:38









Nimbus2000Nimbus2000

1




1












  • Thanks, I tried it but no luck. I just found out that, the request has been drop from nginx, it not even go go confluence upstream.
    – Tien Dung Tran
    Nov 15 '18 at 7:13


















  • Thanks, I tried it but no luck. I just found out that, the request has been drop from nginx, it not even go go confluence upstream.
    – Tien Dung Tran
    Nov 15 '18 at 7:13
















Thanks, I tried it but no luck. I just found out that, the request has been drop from nginx, it not even go go confluence upstream.
– Tien Dung Tran
Nov 15 '18 at 7:13




Thanks, I tried it but no luck. I just found out that, the request has been drop from nginx, it not even go go confluence upstream.
– Tien Dung Tran
Nov 15 '18 at 7:13


















draft saved

draft discarded




















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53276927%2finvalid-character-found-in-the-request-target-on-confluence-behind-nginx%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Bressuire

Vorschmack

Quarantine