PR feedback: add config option to enable rotation emails, add cert count and type to email

This commit is contained in:
Jasmine Schladen
2020-12-03 16:10:36 -08:00
parent 4c2227f23c
commit 42957cffc7
5 changed files with 30 additions and 5 deletions

View File

@ -864,3 +864,13 @@ def cleanup_after_revoke(certificate):
database.update(certificate)
return error_message
def get_issued_cert_count_for_authority(authority):
"""
Returns the count of certs issued by the specified authority.
:return:
"""
query = database.session_query(Certificate.id).filter(Authority.id == authority.id)
return database.get_count(query)