summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDeepak Kodihalli <dkodihal@in.ibm.com>2018-10-03 04:59:26 -0500
committerDeepak Kodihalli <dkodihal@in.ibm.com>2018-10-03 04:59:26 -0500
commit844bb4e13bf53905f899760e1f4435576f334b11 (patch)
treec889060a64c99b8391c56bc749a184236e095e03
parenta324acd93fb88322f7fd1b7ff8fe0bf81fd401ef (diff)
downloadphosphor-rest-server-844bb4e13bf53905f899760e1f4435576f334b11.zip
phosphor-rest-server-844bb4e13bf53905f899760e1f4435576f334b11.tar.gz
certificate handler: fixup return code
Map a certificate install fail to a 400. This is likely due to an invalid certificate. Change-Id: Ie451aa356e4a708889aa7475f10a1c122253e859 Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
-rw-r--r--module/obmc/wsgi/apps/rest_dbus.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/module/obmc/wsgi/apps/rest_dbus.py b/module/obmc/wsgi/apps/rest_dbus.py
index 6066126..f52032a 100644
--- a/module/obmc/wsgi/apps/rest_dbus.py
+++ b/module/obmc/wsgi/apps/rest_dbus.py
@@ -922,7 +922,7 @@ class CertificateHandler:
iface.Install(temp.name)
except Exception as e:
cleanup()
- abort(503, str(e))
+ abort(400, str(e))
cleanup()
def do_delete(self):
OpenPOWER on IntegriCloud