Tomcat conf to pass special chars in URLs

How to pass special characters in the URL ?
Example : http://mytest.cfm?var=règle (character è)
This gives an error :
Un caractère invalide a été trouvé dans la cible de la requête
from Apache Tomcat/9.0.24

Is there something to set in the Tomcat conf to allow spec char in URLs ?
in server.xml

Thanks for help
Pierre.

Don’t forget to tell us about your stack!
Linux debian 10
apache 2.4
Lucee 5.3.7.47
Tomcat 9

Hi @Pierre_Larde

My suggestion is instead of allowing a page to query a variable, set the variable as a post vs a url query parameter.

The second issue is your request isnt UTF8 compliant so you search engines, browsers and tomcat may not like what you are trying to do.

What you could try, and is to look at ASCII mapping for that character and then encode character value and then decode the request

Take a look at

and
https://www.asciitable.com/

so CHR(130)

I avoid passing spec chars in URLs.
But, sometimes this exist in applications, I wrote or written by someone else.
Under WindowsXP/Coldfusion 8, there is no error. (old application).
I still have this on a local server. (it works fine)

There should be a way to make it work, without Forms or CF functions in that new environment.

I try to find it, It seems it comes from Tomcat ?

Thanks for others ideas.
Pierre.

With this new environment, It seems it depends on browser used ?
Old browser gives error,
New browser , no error. (spec char pass in URL, without doing anything)

I am lost.

Pierre.

É or other special characters in the url might work, but its not compliant. You should/must urlencode that.

What is URL Encoding and How does it work? | URLEncoder).

You may also want to look at something like this, in server.xml :

<Connector port="8009" protocol="AJP/1.3" redirectPort="8443" relaxedQueryChars='[]|{}^&#x5c;&#x60;&quot;&lt;&gt;'/-->
2 Likes

Old versions of ACF before 10 ran JRUN, which to say is insecure and different is a an understatement.

As for forms, You still define a form in html using what ever framework you want. You wrap what ever application logic around it and post it to do something.

form method = post action = some_cf_page.cfm or php, or whatever.

@thefalken that is awesome! Didn’t know that.