def __init__(self, users):
self.users = users
-
+
+ @handler('Adds a user')
def add(self, user, password):
if user in self.users:
raise UserAlreadyExistsError(user)
self.users[user] = crypt.crypt(password,'BA')
-
+
+ @handler('Deletes a user')
def delete(self, user):
if not user in self.users:
raise UserNotFound(user)
px.host.delete('192.168.0.25.27')
px.user.add('lala','soronga')
px.user.add('culo','sarasa')
- px.commit()
\ No newline at end of file
+ px.commit()