summaryrefslogtreecommitdiffstats
path: root/module/obmc/wsgi
diff options
context:
space:
mode:
authorLei YU <mine260309@gmail.com>2018-01-26 14:09:44 +0800
committerLei YU <mine260309@gmail.com>2018-01-26 14:12:40 +0800
commit4af5f33b134f4397e6499158dc6d5e711ce18adc (patch)
treecac9077a56ea4ac12caed5c620d409565ea7e853 /module/obmc/wsgi
parent9e2a211304d667756bc4136ec4bd1be27a2b5457 (diff)
downloadphosphor-rest-server-4af5f33b134f4397e6499158dc6d5e711ce18adc.tar.gz
phosphor-rest-server-4af5f33b134f4397e6499158dc6d5e711ce18adc.zip
Revert "Remove org.openbmc.* from REST server"
This reverts commit 9e2a211304d667756bc4136ec4bd1be27a2b5457, which breaks code update for non-UBIFS bmcs. Change-Id: Iecdad70f4ca9d2b4852addac3c2550e081253366 Signed-off-by: Lei YU <mine260309@gmail.com>
Diffstat (limited to 'module/obmc/wsgi')
-rw-r--r--module/obmc/wsgi/apps/rest_dbus.py22
1 files changed, 0 insertions, 22 deletions
diff --git a/module/obmc/wsgi/apps/rest_dbus.py b/module/obmc/wsgi/apps/rest_dbus.py
index 71c8788..cda23df 100644
--- a/module/obmc/wsgi/apps/rest_dbus.py
+++ b/module/obmc/wsgi/apps/rest_dbus.py
@@ -1181,27 +1181,6 @@ class ContentCheckerPlugin(object):
return self.Checker(content_type, callback)
-class CheckURLPlugin(object):
- ''' Ensures that anything read and written using the old /org/openbmc route
- would not be allowed. '''
- name = 'url_checker'
- api = 2
-
- class Checker:
- def __init__(self, callback):
- self.callback = callback
- self.error_str = "org.freedesktop.DBus.Error.FileNotFound: path " \
- + "or object not found: '%s'"
-
- def __call__(self, *a, **kw):
- if "/org/openbmc" in request.url:
- abort(404, self.error_str % (request.url))
- return self.callback(*a, **kw)
-
- def apply(self, callback, route):
- return self.Checker(callback)
-
-
class App(Bottle):
def __init__(self, **kw):
super(App, self).__init__(autojson=False)
@@ -1228,7 +1207,6 @@ class App(Bottle):
self.install(JsonApiResponsePlugin(self))
self.install(JsonApiRequestPlugin())
self.install(JsonApiRequestTypePlugin())
- self.install(CheckURLPlugin())
def install_hooks(self):
self.error_handler_type = type(self.default_error_handler)
OpenPOWER on IntegriCloud