lmccay opened a new pull request, #1052:
URL: https://github.com/apache/knox/pull/1052

   ## What changes were proposed in this pull request?
   
   Issue: The extension APIs of KNOXTOKEN: APIKEY and CLIENTID APIs are unable 
to be colocated with the KNOXTOKEN API in the same topology due to param name 
conflicts. This results in unexpected results when the TTL or other params are 
set in one or more of the APIs.
   
   Solution: I provided prefixes for all extension APIs that extend the 
PasscodeTokenResourceBase class via a getPrefix() method on each 
implementation. Those prefixes are used to disambiguate the params at 
initialization time and then are stripped from the params and reset to the 
expected names in KNOXTOKEN implementation.
   
   This insures that the params do not collide and that the implementation has 
the expected values at runtime.
   
   Note: there may be a more fundamental issue that has required this change 
that has been lurking for quite some time. The setting of all the params from 
the JAXRS APIs as init params within web.xml in a flat space for the 
GatewayServlet seems problematic. This will require additional investigation. 
In the meantime, this will work for our needs and will still be safe when we 
address that problem.
   
   ## How was this patch tested?
   
   Existing unit tests were run and adjusted to accommodate the new names with 
the prefixes.
   All other unit tests were also run.
   
   Please review [Knox Contributing 
Process](https://cwiki.apache.org/confluence/display/KNOX/Contribution+Process#ContributionProcess-GithubWorkflow)
 before opening a pull request.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@knox.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to