Commit f0cb6f98 authored by Per Cederqvist's avatar Per Cederqvist
Browse files

Measure statistics for the number of existing texts. Fix a potential

denial-of-service scenario.
parent 590f62ca
2003-07-27 Per Cederqvist <ceder@ceder.dyndns.org>
Measure statistics for the number of existing texts.
* doc/Protocol-A.texi (Measured Properties): Document "texts".
* src/server/stats.h (enum stat_type): Added STAT_TEXTS.
* src/server/stats.c (name): Handle STAT_TEXTS.
* src/server/text.c (do_delete_text): Update STAT_TEXTS.
(do_create_text): Ditto.
* src/server/simple-cache.c (init_cache): Call update_stat
with STAT_TEXTS to updated the number of existing texts.
* src/server/ramkomd.c (main): Moved the call to init_stats
earlier, so that we can count the existing texts while reading the
database.
* src/server/testsuite/lyskomd.0/01.exp: Check the "texts" stat.
* src/server/testsuite/lyskomd.0/03.exp: Ditto.
Fix a potential denial-of-service scenario.
* src/server/connections.c (login_request): Give the new client
maximum penalty to start with. It has to be connected a while to
earn the right to do anything.
Code cleanup.
* src/server/simple-cache.c (init_cache): Use a new local
variable, "record", to count the records in the database file.
Don't reuse the "ic" variable for that purpose.
2003-07-25 Per Cederqvist <ceder@ceder.dyndns.org>
Fixed "make check" for the documentation.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment