From 0e027e6858022589ace11218ce102ce57499e5e6 Mon Sep 17 00:00:00 2001 From: "Kali Kaneko (leap communications)" Date: Mon, 12 Dec 2016 17:37:30 +0100 Subject: [feature] better param error handling in rest api --- src/leap/bitmask/core/dummy.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/leap/bitmask/core/dummy.py') diff --git a/src/leap/bitmask/core/dummy.py b/src/leap/bitmask/core/dummy.py index 2037b81f..51eec1a0 100644 --- a/src/leap/bitmask/core/dummy.py +++ b/src/leap/bitmask/core/dummy.py @@ -37,6 +37,7 @@ class CannedData: class bonafide: auth = { + u'lcl_token': u'deadbeef', u'srp_token': u'deadbeef123456789012345678901234567890123', u'uuid': u'01234567890abcde01234567890abcde'} signup = { @@ -48,6 +49,8 @@ class CannedData: logout = { 'logout': 'ok'} get_active_user = 'dummyuser@provider.example.org' + change_password = { + 'update': 'ok'} class BackendCommands(object): @@ -90,10 +93,10 @@ class BonafideService(HookableService): def __init__(self, basedir): self.canned = CannedData - def do_authenticate(self, user, password): + def do_authenticate(self, user, password, autoconf): return self.canned.bonafide.auth - def do_signup(self, user, password): + def do_signup(self, user, password, invite, autoconf): return self.canned.bonafide.signup def do_list_users(self): @@ -104,3 +107,6 @@ class BonafideService(HookableService): def do_get_active_user(self): return self.canned.bonafide.get_active_user + + def do_change_password(self, username, old, new): + return self.canned.bonafide.change_password -- cgit v1.2.3