Commit graph

11 commits

Author SHA1 Message Date
fusion44
25e4be8441 feat: make config loading more flexible
If the environment variable BAPI_ENV_PATH is set, the config system will
try to read configs from the given path instead of .env in pwd

If no file is found .env in pwd will be used as a fallback

Env variables will always override settings in .env files.
2025-03-23 17:43:39 +01:00
fusion44
2435b1c57f
feat: improve logging and remove print statements 2022-12-18 20:55:48 +01:00
fusion44
f06d84c29f
fix: return auth token as plain text on login 2022-10-22 11:45:59 +02:00
fusion44
fcb23c2fc0 fix: token expiry time check
fixes #105
2022-08-21 20:08:55 +02:00
fusion44
85d2de19e4
chore: fix some naming issues 2022-03-23 21:03:50 +01:00
Stefan Stammberger
71f87e06d7
feat: implement local cookie authentication
This is only useful for application running directly on the Raspiblitz.
This will create a file in ~/.blitz_api/.cookie with a valid JWT token.
Local applications can use this to authenticate to the API without
having to ask for the password. This is similar to how Bitcoin Cores
cookie auth works.
2021-11-28 08:42:52 +01:00
Stefan Stammberger
63c52d2ba7
fix: encode JWT expiry time as int, not float
fixes #46
2021-11-22 20:44:14 +01:00
Stefan Stammberger
070ac2131c
fix: update wrong PyJWT version
Also: don't silently eat exceptions when decoding a JWT token
2021-09-25 17:58:53 +02:00
Stefan Stammberger
f482c441cc
chore: format all files using black 2021-09-05 08:56:53 +02:00
Stefan Stammberger
c33351d968
refactor: move some config vars to the .env file 2021-07-25 17:24:33 +02:00
Stefan Stammberger
9046195d02
initial commit 2021-06-10 21:13:26 +02:00