25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-12-20 17:27:00 +01:00

Less strict extauth.py

This commit is contained in:
Alexey Shchepin 2016-05-13 17:26:15 +03:00
parent 792f47b4bd
commit 9bd446e519

View File

@ -6,17 +6,17 @@ def read():
pkt = sys.stdin.read(pkt_size).split(':')
cmd = pkt[0]
args_num = len(pkt) - 1
if cmd == 'auth' and args_num == 3:
if cmd == 'auth' and args_num >= 3:
write(True)
elif cmd == 'isuser' and args_num == 2:
write(True)
elif cmd == 'setpass' and args_num == 3:
elif cmd == 'setpass' and args_num >= 3:
write(True)
elif cmd == 'tryregister' and args_num == 3:
elif cmd == 'tryregister' and args_num >= 3:
write(True)
elif cmd == 'removeuser' and args_num == 2:
write(True)
elif cmd == 'removeuser3' and args_num == 3:
elif cmd == 'removeuser3' and args_num >= 3:
write(True)
else:
write(False)