diff --git a/secrules/user_exists.py b/secrules/user_exists.py new file mode 100644 index 0000000000000000000000000000000000000000..bfb6aa2d338bada366cc1f96d49c856cd30ff518_c2VjcnVsZXMvdXNlcl9leGlzdHMucHk= --- /dev/null +++ b/secrules/user_exists.py @@ -0,0 +1,12 @@ +from vms import starlet +from vms import itemList, uaidef + +def user_exists(u): + itm = [itemList.itemList (code=uaidef.UAI__UIC, dtype=itemList.il_unsignedLong),] + try: + s, uic = starlet.getuai (usrnam=u, itmlst=itm) + uic_g = uic.values()[0] / 65536 + uic_m = uic.values()[0] - (uic_g * 65536) + return uic_g, uic_m + except: + return None, None