diff options
| author | Russell Bryant <rbryant@redhat.com> | 2012-10-17 12:13:06 -0700 |
|---|---|---|
| committer | Russell Bryant <rbryant@redhat.com> | 2012-10-17 12:25:59 -0700 |
| commit | faf4e9a976600c6608fcf17485bd667766335fce (patch) | |
| tree | 3eb60ce2337538b75b1a9f334a079ab1d414e2e0 | |
| parent | 6bf2e41cc3ad636b9d4c493a2a61f97aacefd4cf (diff) | |
Use consoleauth rpcapi in nova-novncproxy.
The nova-novncproxy service was using rpc.call directly when it should
have been going through the rpcapi client proxy class. This patch fixes
that.
Fix bug 1067858.
Change-Id: I626fb01ff61ff507520d528122358ef687d297b7
| -rwxr-xr-x | bin/nova-novncproxy | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/nova-novncproxy b/bin/nova-novncproxy index 3abaaa769..483c72e81 100755 --- a/bin/nova-novncproxy +++ b/bin/nova-novncproxy @@ -28,6 +28,7 @@ import sys import websockify +from nova.consoleauth import rpcapi as consoleauth_rpcapi from nova import context from nova import flags from nova.openstack.common import cfg @@ -84,9 +85,8 @@ class NovaWebSocketProxy(websockify.WebSocketProxy): cookie.load(self.headers.getheader('cookie')) token = cookie['token'].value ctxt = context.get_admin_context() - connect_info = rpc.call(ctxt, 'consoleauth', - {'method': 'check_token', - 'args': {'token': token}}) + rpcapi = consoleauth_rpcapi.ConsoleAuthAPI() + connect_info = rpcapi.check_token(ctxt, token=token) if not connect_info: LOG.audit("Invalid Token: %s", token) |
