[ 
https://issues.apache.org/jira/browse/KNOX-2841?focusedWorklogId=841506&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-841506
 ]

ASF GitHub Bot logged work on KNOX-2841:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 25/Jan/23 09:40
            Start Date: 25/Jan/23 09:40
    Worklog Time Spent: 10m 
      Work Description: dionusos opened a new pull request, #718:
URL: https://github.com/apache/knox/pull/718

   ## What changes were proposed in this pull request?
   
   We had to change the Oozie rewrite rules more strict not allowing them to 
mach to any protocol but only http and https. Besides this change additional 
service routing configuration have to be added not to break the Oozie UI 
usability.
   
   ## How was this patch tested?
   
   On a Hadoop cluster with Knox installed I edited 
/var/lib/knox/gateway/data/services/oozie/5.0.0/rewrite.xml and 
/var/lib/knox/gateway/data/services/oozie/5.0.0/service.xml files to have the 
final content. After that I deleted the Knox topology deployments then 
restarted Knox.
   After that I re-submitted the Oozie workflow which I had issues with 
earlier. The job submission was successful, the Oozie job executed without any 
error, the properties were set to the desired values and I was able to see the 
expected values on the Oozie UI too via Knox.
   




Issue Time Tracking
-------------------

    Worklog Id:     (was: 841506)
    Time Spent: 0.5h  (was: 20m)

> Oozie "root" rewrite rule's pattern is too open
> -----------------------------------------------
>
>                 Key: KNOX-2841
>                 URL: https://issues.apache.org/jira/browse/KNOX-2841
>             Project: Apache Knox
>          Issue Type: Bug
>    Affects Versions: 1.6.0
>            Reporter: Dénes Bodó
>            Assignee: Dénes Bodó
>            Priority: Major
>             Fix For: 2.0.0
>
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> It seems that the "root" rewrite rule for Oozie is too open and causes the 
> following issue:
> When we use Apache Hue as the UI for Oozie and we define a workflow property 
> for a file path like
> *hdfs://mnameservice1/oozie/test*
> then on Hue's workflow details page we will see an url for that property like:
> *[http://oozie-host.examole.com:11000/oozie/test]*
> And it seems this replacement is due to the following rule:
> {code:xml}
>     <rule dir="IN" name="OOZIE/oozie/root" 
> pattern="*://*:*/**/oozie/{**}?{**}">
>         <rewrite template="{$serviceUrl[OOZIE]}/{**}?{**}"/>
>     </rule> 
> {code}
> When I changed it to
> {code:xml}
>     <rule dir="IN" name="OOZIE/oozie/root" 
> pattern="http*://*:*/**/oozie/{**}?{**}">
>         <rewrite template="{$serviceUrl[OOZIE]}/{**}?{**}"/>
>     </rule> 
> {code}
> in my test environment then the Hue UI showed me the correct HDFS path.
>  
> I am creating the pull request soon.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to