[Kimchi-devel] [PATCH] Bug fix: Do not require login for simple resources

Sheldon shaohef at linux.vnet.ibm.com
Thu Jun 19 10:38:20 UTC 2014


sure. kimchisession hook is heavy overhead.

the root.get just return  the kimchi-ui.html, actually it is not a 
restful API.

Consider root.get is the only entry of UI.

How about move the logic code to root.get.

On 06/19/2014 01:53 AM, Crístian Viana wrote:
> The subdirectories "css", "js", "libs" and "images" currently require
> a login session to be accessed. Those files are simple resources, thus
> they don't need to be protected.
> One consequence of this behavior is that it is not possible to create a remote
> template with the current security settings.
>
> Remove the login session requirement to access the subdirectories "css",
> "js", "libs" and "images".
>
> Signed-off-by: Aline Manera <alinefm at br.ibm.com>
> Signed-off-by: Crístian Viana <vianac at linux.vnet.ibm.com>
> ---
>   src/kimchi/config.py.in | 1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/src/kimchi/config.py.in b/src/kimchi/config.py.in
> index 74c8fa5..4be767e 100644
> --- a/src/kimchi/config.py.in
> +++ b/src/kimchi/config.py.in
> @@ -154,6 +154,7 @@ class UIConfig(dict):
>               ui_configs['/' + sub_dir] = {
>                   'tools.staticdir.on': True,
>                   'tools.staticdir.dir': os.path.join(paths.ui_dir, sub_dir),
> +                'tools.kimchisession.on': False,
>                   'tools.nocache.on': False}
>               if sub_dir != 'images':
>                   ui_configs['/' + sub_dir].update({


-- 
Thanks and best regards!

Sheldon Feng(冯少合)<shaohef at linux.vnet.ibm.com>
IBM Linux Technology Center




More information about the Kimchi-devel mailing list