im using a custom captive portal, the user registers his account
I would like to set the expiration date of the registration for 1 day for captive portal local users

in the code below is done the registration of the user, how could I add an expiration date?

if action == 'Register':
if email and len(email.strip()) > 0 and pwd and len(pwd.strip()) > 0 and uname and len(uname.strip()) > 0:
userToRegister={"email": "%s"%email, "firstName":"%s"%fn, "lastName":"%s"%ln, "password":"%s"%pwd, "username":"%s"%uname, "javaClass":"com.untangle.uvm.LocalDirectoryUser"}
if not localDirectory.userExists(userToRegister):
capture.userAuthenticate(address, uname, pwd)
return index(req,rawpath,webpath,appid,host,uri,"User already exists !")
return index(req,rawpath,webpath,appid,host,uri,"Username, password and email must be set !")