579 Commits

Author SHA1 Message Date
Simone Taeggi
3e7a45fdb8 define a new action to prevent the access of the api token page in the settings 2022-08-23 16:27:26 +02:00
Ben Irvin
7e446b7414 add token usage tests 2022-08-23 15:04:24 +02:00
Ben Irvin
8803dbbd46 fix tests 2022-08-23 14:14:04 +02:00
Ben Irvin
e47db1a490 add comment 2022-08-23 13:52:33 +02:00
Ben Irvin
3c724eb483 rename tests 2022-08-23 13:52:00 +02:00
Ben Irvin
dbe79dc605 fix data type 2022-08-23 13:51:23 +02:00
Ben Irvin
e54e5f7ddc fix lastUsedAt 2022-08-23 13:45:27 +02:00
Ben Irvin
7b389e49a9 add test todos 2022-08-23 13:03:15 +02:00
Ben Irvin
36b53e8046 more tests and fixes 2022-08-23 12:53:20 +02:00
Ben Irvin
28f078be0a lifespan validation 2022-08-23 10:51:53 +02:00
Ben Irvin
1cf0cb5c4c fix test 2022-08-23 10:49:27 +02:00
Ben Irvin
da00ba89e1 lifespan unit test 2022-08-22 18:46:22 +02:00
Ben Irvin
0918729d21 Merge branch 'features/api-token-v2' into api-token-v2/backend-expirations 2022-08-22 17:54:33 +02:00
Ben Irvin
aa5a1c7ed7 regenerate throws on invalid id 2022-08-22 12:33:00 +02:00
Ben Irvin
dabbd42ca7 assert acessKey has changed 2022-08-22 12:22:36 +02:00
Ben Irvin
ae90cf5fd0 Merge branch 'api-token-v2/regenerate-tokens-api' into api-token-v2/backend-expirations 2022-08-22 12:11:46 +02:00
Ben Irvin
6de74793df add test todos 2022-08-22 09:26:20 +02:00
Ben Irvin
55dee1a09d verify expiration of token 2022-08-22 09:25:55 +02:00
Ben Irvin
a063f21474 jsdoc comments 2022-08-19 16:53:51 +02:00
Ben Irvin
c5eb2b1a9d rename mapTokenPermissions to flattenTokenPermissions 2022-08-19 16:45:16 +02:00
Ben Irvin
d4f03c7d56 declare functions before use 2022-08-19 16:42:55 +02:00
Ben Irvin
c6aef125c9 fix jsdoc params 2022-08-19 16:41:39 +02:00
Ben Irvin
e79617b094 lastUsedAt isn't a valid update field 2022-08-19 16:37:41 +02:00
Ben Irvin
e3961fb298 rename lastUsed to lastUsedAt 2022-08-19 16:36:28 +02:00
Ben Irvin
36d37706ce add lifespan and expiresAt fields 2022-08-19 16:33:58 +02:00
Ben Irvin
f30f25ecbe lint 2022-08-18 14:52:16 +02:00
Ben Irvin
7ce7db6604 update tests 2022-08-18 14:12:34 +02:00
Ben Irvin
9941198dac fix regeneration 2022-08-18 14:03:59 +02:00
Ben Irvin
7098ae95be Merge branch 'api-token-v2/backend/regenerate-token' into api-token-v2/regenerate-tokens-api 2022-08-18 13:48:06 +02:00
Ben Irvin
06d95419f4 add regeneration of tokens 2022-08-18 13:31:02 +02:00
Ben Irvin
21845bb0d0 remove lastUsed from create 2022-08-18 12:30:27 +02:00
Ben Irvin
fd05d49346 fix linting 2022-08-18 12:24:13 +02:00
Ben Irvin
b2b1432322 Merge branch 'features/api-token-v2' into api-token-v2/permissions-for-api-token 2022-08-18 12:20:45 +02:00
Ben Irvin
622d00930f fix required attributes 2022-08-18 12:13:29 +02:00
Ben Irvin
c61e402461 disallow updating lastUsed from api 2022-08-18 12:03:25 +02:00
Ben Irvin
745a3a8497 add lastUsed to yup validation schema 2022-08-18 12:00:47 +02:00
Ben Irvin
9de7791fad cleanup 2022-08-18 11:53:30 +02:00
Bassel Kanso
baad6fd93f Merge branch 'main' into features/api-token-v2 2022-08-18 12:18:09 +03:00
Ben Irvin
7b60783888 fix e2e tests 2022-08-18 11:02:24 +02:00
Ben Irvin
449f982781 Merge branch 'api-token-v2/permissions-for-api-token' into api-token-v2/access-times-backend 2022-08-18 10:55:11 +02:00
Ben Irvin
e28c9e7ec9 add lastUsed 2022-08-18 10:22:09 +02:00
Ben Irvin
215735b0cd update lastUsed when token is accessed 2022-08-17 23:28:35 +02:00
Ben Irvin
f95bb29d76 add lastUsed 2022-08-17 23:28:20 +02:00
Ben Irvin
1436345e78 remove console.log 2022-08-17 10:10:28 +02:00
ivanThePleasant
1c3c04ab28 Fix unit test 2022-08-16 14:06:35 +03:00
ivanThePleasant
1cda317e03 Refactor FE admin hash generation to fix error 2022-08-16 14:00:45 +03:00
ivanThePleasant
459de9774d Refactor hash function, add uuid to the admin hash, remove debug console logs 2022-08-16 11:58:15 +03:00
Ben Irvin
88c243243d make error message unique 2022-08-16 10:18:41 +02:00
Ben Irvin
dbddec6c62 fix permission mapping 2022-08-16 10:11:32 +02:00
Ben Irvin
0972919247 list and get should return array of action strings 2022-08-12 09:52:47 +02:00