Реализовать лабораторную 7: mTLS, OpenBao и защита worker
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
"""Trusted operator only: bound retention of old authentication counters."""
|
||||
from app import store
|
||||
store.pool.open(wait=True)
|
||||
try:
|
||||
with store.connect() as conn:
|
||||
count=conn.execute("DELETE FROM login_limits WHERE bucket<now()-interval '10 minutes'").rowcount
|
||||
print('Removed obsolete rate-limit counters:',count)
|
||||
finally:store.pool.close()
|
||||
Reference in New Issue
Block a user