Files
@ 9a02f9ef28d7
Branch filter:
Location: kallithea/docs/usage/backup.rst - annotation
9a02f9ef28d7
511 B
text/prs.fallenstein.rst
utils: make API key generator more random
The API key generator abused temporary filenames in what seems to be an attempt
of creating keys that unambiguously specified the user and thus were unique
across users. A final hashing did however remove that property.
More importantly, tempfile is not documented to use secure random numbers ...
and it only uses 6 characters, giving approximately 36 bits of entropy.
Instead, use the cryptographically secure os.urandom directly to generate keys
with the same length but with the full 160 bits of entropy.
Reported and fixed by Andrew Bartlett.
The API key generator abused temporary filenames in what seems to be an attempt
of creating keys that unambiguously specified the user and thus were unique
across users. A final hashing did however remove that property.
More importantly, tempfile is not documented to use secure random numbers ...
and it only uses 6 characters, giving approximately 36 bits of entropy.
Instead, use the cryptographically secure os.urandom directly to generate keys
with the same length but with the full 160 bits of entropy.
Reported and fixed by Andrew Bartlett.
af371e206ec5 af371e206ec5 17c9393e9645 e73a69cb98dc af371e206ec5 af371e206ec5 af371e206ec5 af371e206ec5 af371e206ec5 af371e206ec5 e73a69cb98dc af371e206ec5 af371e206ec5 af371e206ec5 af371e206ec5 4e6dfdb3fa01 4e6dfdb3fa01 af371e206ec5 af371e206ec5 af371e206ec5 af371e206ec5 af371e206ec5 e73a69cb98dc af371e206ec5 af371e206ec5 4e6dfdb3fa01 | .. _backup:
====================
Backing up Kallithea
====================
Settings
--------
Just copy your .ini file, it contains all Kallithea settings.
Whoosh index
------------
The Whoosh index is located in the ``data/index`` directory where you installed
Kallithea, i.e., the same place where the ini file is located
Database
--------
When using sqlite just copy kallithea.db.
Any other database engine requires a manual backup operation.
A database backup will contain all gathered statistics.
|