mirror of
https://github.com/certbot/certbot.git
synced 2026-07-28 16:54:59 +02:00
policy to trigger requiring payment
This commit is contained in:
+6
-1
@@ -15,7 +15,12 @@ r = redis.Redis()
|
||||
|
||||
def payment_required(session):
|
||||
"""Does this session require a payment?"""
|
||||
return False
|
||||
# Sample policy: require a payment when total number of requested
|
||||
# subject names is greater than one.
|
||||
if r.llen("%s:names" % session) > 1:
|
||||
return True
|
||||
else:
|
||||
return False
|
||||
|
||||
def expire_session(session, state):
|
||||
"""Should this session be expired?"""
|
||||
|
||||
Reference in New Issue
Block a user