tuckey urlrewrite filter - include utm parameters in url rewrite condition

I did couple of trial and error in including utm params on my URL for tuckey url rewrite but its always forwarding to 404 page.this is my current condition on URL rewrite:<rule> <from>^/n/(.*)/([0-9]+)$</from> <to last="true" type="permanent-redirect">/ttsvr/$1/$2</to> </rule> <rule> <from>^/(.*)/([0-9]+)\?(gclid=.*)$</from> <to last="true" type="forward">/n/force-redirect/fitmycar-webdesign-63?id=$2&amp;name=$1&amp;$3</to> </rule&g...Read more

Tuckey URLRewriteFilter alternative

I am looking to use the UrlRewriteFilter based on a recommendation. It was working fine, until I tried to pass the parameters from the "From" to the "to". I ended up getting "&" as the character between the URL and the parameters instead of the "?". In researching this, it has been fixed since 2015, but the release 4.0.5 has never been made public in the maven repository. 4.0.4 is the latest and it is from 2012. It looks like a great project, but does not appear to be maintained anymore. Does anyone have an alternate project that the...Read more

How to do 307 redirect with tuckey UrlRewriteFilter

I have the following rule...<rule> <condition type="scheme" operator="equal">^http$</condition> <from>/(.*)</from> <to type="temporary-redirect" last="true">https://something.com/$1</to></rule>... And it works just fine (gives a 302 redirect) however i want to make it 307 redirect since that preserves parameters. I tried the following and have had no luck:...<rule> <condition type="scheme" operator="equal">^http$</condition> <from>/(.*)</from> <se...Read more

check if url has '/?' thru tuckey urlrewrite

I need to check thru URL rewrite if the URL has question mark after 'search-product-list/'. I'm using tuckey. Here's the current rule: <rule> <from>^/n/search-product-list/(.*)$</from> <to last="true" type="permanent-redirect">/ttsvr/search-product-list/$1</to> </rule> <rule> <from>^/search-product-list/(.*)$</from> <to last="true" type="forward">/n/force-redirect/fitmycar-webdesign-73?query=$1</to> </rule>...Read more

urlrewritefilter tuckey configuration for tomcat 7.0.64

I'm trying to configure urlrewritefilter 4.0.3 but I'm not sure to understand instructions and setting it in the correct way.I'm using apache-tomcat-7.0.64 installed under /opt/apache-tomcat-7.0.64/ and with the following configuration:Using CATALINA_BASE: /opt/apache-tomcat-7.0.64Using CATALINA_HOME: /opt/apache-tomcat-7.0.64Using CATALINA_TMPDIR: /opt/apache-tomcat-7.0.64/tempUsing JRE_HOME: /opt/jdk1.7.0_80/jreUsing CLASSPATH: /opt/apache-tomcat-7.0.64/bin/bootstrap.jar:/opt/apache-tomcat-7.0.64/bin/tomcat-juli.jarI have set ...Read more

tuckey urlrewrite filter - Setting origin or referer value which from request to the response-header using urlrewritefilter

How to set origin value or referer value in a response-header using tuckey url rewrite filter xml file.Accessing %{origin} directly in the set tag is not working but not working in condition tag.Below is the example I tried. <rule enabled="true" last="false" match-type="regex"> <name>Enabling CORS Headers</name> <from>^/path/someMorePath.*$</from> <condition name="origin" operator="equal">http://www.testsite.com</condition> <!-- would like to write some regex to match a set of sites and i...Read more

Tuckey urlrewritefilter rewrite query string

I am trying to use Tuckey URL rewrite filter to rewrite the query string passed to Solr.Using the following configuration:<urlrewrite use-query-strings="true"> <rule> <from>^/test1/(.*)command=(.*)clean=true(.*)$</from> <to type="redirect">$1command=$2clean=false$3</to> </rule></urlrewrite>This configuration works if the query string is not read as a query string i.e.http://localhost/test1/command=something&clean=true&somethingelese=newbut fails as intended:http://localho...Read more

Tuckey UrlRewrite Filter redirecting all http requests except foo.html

I'm trying to redirect all http requests to https except "health.html" which I need to serve over standard http on port 80; For some reason the rules below don't seem to be doing it - I'm sure it's a syntax thing...Thoughts?<?xml version="1.0" encoding="utf-8"?><!DOCTYPE urlrewrite PUBLIC "-//tuckey.org//DTD UrlRewrite 4.0//EN" "http://www.tuckey.org/res/dtds/urlrewrite4.0.dtd"><urlrewrite><rule match-type="regex"> <note> Redirect all http requests to https except health.html for EB monitoring <...Read more

Tuckey urlrewrite matching and context

I have an AngularJS application running under a Tomcat 7 server, where the app lives in ~/tomcat/webapps/web-client/.I'm trying to configure the server such that a refresh, or otherwise playing with the URL will redirect to http://server:8080/web-client/index.html.Using Tuckey UrlRewrite, I have this in my urlrewrite.xml:<?xml version="1.0" encoding="utf-8"?><!DOCTYPE urlrewrite PUBLIC "-//tuckey.org//DTD UrlRewrite 4.0//EN" "http://www.tuckey.org/res/dtds/urlrewrite4.0.dtd"><urlrewrite> <rule> <fro...Read more

Optional capturing group in tuckey

I have been trying to use optional capturing group in tuckey outbound rule, but it is not working. Any help on this will be highly appreciated.Can we use the format(.+)? as optional capturing group in tuckey. When I tried in apache it works fine, but in Tuckey it is not working. I even tried escaping the ?, but still doesn't work.For eg: I have two types of URLhttp://xxx/discontinued-products/token/--categories%3C%_c_discontinued_category%7D--http://xxx/token/--categories%3C%_c_discontinued_category%7D--I am trying to write an outbound rule to ...Read more

URLrewriteFilter tuckey redirect

I am trying to use UrlRewriteFilter to do a redirect. As we are moving servers and infrastructure all the time to develop our in house cloud solutions we plan to use a lot of this.My problem is I have a URL like https:// google.com/web-app/servlet?request-parameters&valuesI need to redirect all the URLs which has a value for a particular parameter to a different server.so a URL like : https:// google.com/administrator/servlet/ej.processOrder?sec=100&geo=appointment&cus=dubaiIf the parameters contain cus=dubai, I need to redirect i...Read more