[filebrowser] Default Home directory button in Filebrowser should be sanitized and should trust the input from untrusted source (asnaik)
@@ -52,7 +52,7 @@ else:
</span>
</li>
%else:
- <li><a class="pointer breadcrumb-link homeLink" data-bind="click: $root.openHome, attr:{'href': window.HUE_BASE_URL + '/filebrowser/view=${ urllib_quote(path.encode('utf-8'), safe=SAFE_CHARACTERS_URI_COMPONENTS) }?default_to_home'}">
+ <li><a class="pointer breadcrumb-link homeLink" data-bind="click: $root.openHome, attr:{'href': window.HUE_BASE_URL + '/filebrowser/view=' + window.USER_HOME_DIR + '?default_to_home'}">
<i class="fa fa-home"></i> ${_('Home')}</a>
</li>
%endif
@@ -69,7 +69,7 @@ else:
</li>
% if is_trash_enabled:
<li class="pull-right">
- <a class="pointer breadcrumb-link trashLink" data-bind="click: $root.openTrash, attr:{'href': window.HUE_BASE_URL + '/filebrowser/view=${ urllib_quote(path.encode('utf-8'), safe=SAFE_CHARACTERS_URI_COMPONENTS) }?default_to_trash'}" title="${_('View trash')}">
+ <a class="pointer breadcrumb-link trashLink" data-bind="click: $root.openTrash, attr:{'href': window.HUE_BASE_URL + '/filebrowser/view='+ window.USER_HOME_DIR +'?default_to_trash'}" title="${_('View trash')}">
<i class="fa fa-trash-o"></i> ${_('Trash')}
</a>
</li>
@@ -77,7 +77,7 @@ else:
</ul>
% else:
<ul class="nav nav-pills hue-breadcrumbs-bar">
- <li><a data-bind="hueLink: window.HUE_BASE_URL + '/filebrowser/view=${ urllib_quote(path.encode('utf-8'), safe=SAFE_CHARACTERS_URI_COMPONENTS) }?default_to_home'" class="breadcrumb-link homeLink"><i class="fa fa-home"></i> ${_('Home')}</a></li>
+ <li><a data-bind="hueLink: window.HUE_BASE_URL + '/filebrowser/view='+ window.USER_HOME_DIR +'?default_to_home'" class="breadcrumb-link homeLink"><i class="fa fa-home"></i> ${_('Home')}</a></li>
<li>
<ul class="hue-breadcrumbs" style="padding-right:40px; padding-top: 12px">
% for breadcrumb_item in breadcrumbs:
