From: Yasin Date: Thu, 26 Sep 2013 10:25:56 +0000 (+0200) Subject: Merge branch 'master' of ssh://git.onelab.eu/git/myslice X-Git-Tag: myslice-0.2-5~85^2~7 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=dbce5d7127dc354a18f9f3cd83299be36ffa2ffa;hp=15ca59cb1f80be244df33026add2cf97f2f87a62;p=unfold.git Merge branch 'master' of ssh://git.onelab.eu/git/myslice --- diff --git a/portal/accountview.py b/portal/accountview.py index e89527e5..af0d03ea 100644 --- a/portal/accountview.py +++ b/portal/accountview.py @@ -236,7 +236,15 @@ def account_process(request): if 'myslice' in platform_detail['platform']: account_config = json.loads(account_detail['config']) if 'user_private_key' in account_config: - pass + for key in account_config.keys(): + if key== 'user_private_key': + del account_config[key] + + updated_config = json.dumps(account_config) + user_params = { 'config': updated_config, 'auth_type':'user'} + manifold_update_account(request,user_params) + messages.success(request, 'Private Key deleted. You need to delegate credentials manually once it expires.') + return HttpResponseRedirect("/portal/account/") else: messages.error(request, 'Delete error: Private key is not stored in the server') return HttpResponseRedirect("/portal/account/")