Commit Graph

70 Commits

Author SHA1 Message Date
Jörn Friedrich Dreyer
09ecfd08ee cache account
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2020-06-17 17:26:33 +02:00
Jörn Friedrich Dreyer
ac2694251b update to new accounts api
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
2020-06-16 18:17:32 +02:00
A.Unger
afb2291eb9 Fix user claims on x-access-token Reva header; initialize cache size 2020-06-12 12:00:21 +02:00
Benedikt Kulmann
fc7b6c1a81 Fix that response is ignored
The request to the accounts service is written to the cache, but the
retrieved uuid was not used, because it was overwritten by the value
from the (non-existant) cache entry.
2020-06-03 15:45:23 +02:00
Ilja Neumann
d7c0728e00 Disable OIDC Keep-Alive and instantiate client once
This should reduce file-descriptor leaks.
2020-05-29 11:15:36 +02:00
Ilja Neumann
6b76c2783e Re-enable selector-test 2020-05-28 16:05:10 +02:00
Benedikt Kulmann
e1847b5c4a Fix flag description 2020-05-26 17:41:30 +02:00
Benedikt Kulmann
89a0f13956 Make jwt secret for reva token manager configurable. 2020-05-26 16:31:05 +02:00
Benedikt Kulmann
87ff5f5d43 Set minted token on request header instead of response writer header. 2020-05-26 16:10:37 +02:00
A.Unger
85c4232901 fix linters 2020-05-22 12:55:42 +02:00
Ilja Neumann
ee82f69390 Create JWT from claims 2020-05-13 13:42:07 +02:00
Benedikt Kulmann
c47dc845b1 Use email claim for account GetRequest 2020-05-11 13:59:18 +02:00
A.Unger
a8c01a4da8 use latest accounts, get rid of replace, fix api 2020-05-11 12:52:21 +02:00
A.Unger
b74496bbf4 add alice and maintain a set order on the middlewares. Write uuid as a temporary response header 2020-05-06 14:30:41 +02:00
A.Unger
c6da8624a5 add uuid to context 2020-05-05 18:29:32 +02:00
A.Unger
1d735adac6 added eviction logiuc 2020-05-05 17:22:23 +02:00
A.Unger
c97ef8a464 add todo comment 2020-05-04 14:11:39 +02:00
A.Unger
0dffde2e6d added a generic cache 2020-05-04 14:08:19 +02:00
A.Unger
ad6a306a6f add trailing comma 2020-05-04 09:24:07 +02:00
A.Unger
a0ed0b2e90 refactor middleware code and provide an example flow to get UUID 2020-04-30 13:39:17 +02:00
Ilja Neumann
617628b1a6 Integration test 2020-04-06 09:52:37 +02:00
Ilja Neumann
976c13cf62 Redirect http-requests to https (#29) 2020-03-27 10:57:32 +01:00
Ilja Neumann
c523942899 User based routing
Implements a configurable "migration" policy-selector which reads the preferred_username attribute from
the oidc claims and checks if the uid exists in the ocis-accounts service.

A configurable policy-name can be selected based on the outcome of the check.
2020-03-27 06:36:17 +01:00
Ilja Neumann
b20b05806e Integrate oid-middleware
This feature is required for user-based routing.
2020-03-26 09:44:51 +01:00
Ilja Neumann
1aa2b1df07 Fix TLS-Certificate not set correctly 2020-03-25 16:55:58 +01:00
Ilja Neumann
6e33472b40 Make TLS-Certificate configurable
Currently the proxy generates certificates on every start for dev purposes. This commit adds an option to make this behaviour configurable.
This also removes the dependency on konnectd`s crypto code and copies it instead, as this library is a first version which is not meant for usage by other services.

A proper cert-generation lib should be added to ocis-pkg instead. Then this code can be refactored to use it.
2020-03-25 09:44:18 +01:00
David Christofas
a86e745c75 use labeled break 2020-03-24 10:55:09 +01:00
David Christofas
1cd3f8936d add unit tests 2020-03-24 10:43:01 +01:00
David Christofas
eb539bc78e implement review feedback 2020-03-24 10:42:47 +01:00
David Christofas
a718777747 route requests based on pattern or query parameters 2020-03-23 19:13:46 +01:00
Ilja Neumann
60a1e6a143 Proxy client urls in default configuration #19 2020-03-23 13:01:29 +01:00
A.Unger
747e345b08 rename reverseproxy -> rp 2020-03-18 12:12:12 +01:00
A.Unger
ae8150dd57 added logging info 2020-03-18 12:12:12 +01:00
A.Unger
52b81a8605 add default runtime redirects 2020-03-18 12:12:12 +01:00
A.Unger
b0e8dbba85 remove mapstructure from config directives 2020-03-18 12:12:12 +01:00
A.Unger
356ad9c9e7 add debug lines 2020-03-18 12:12:12 +01:00
A.Unger
972b2ffe30 document why we use ParseConfig on server before hook 2020-03-17 14:39:13 +01:00
A.Unger
c74e5f5434 document ParseConfig 2020-03-17 14:35:40 +01:00
A.Unger
e2fec340eb code style 2020-03-17 14:34:45 +01:00
A.Unger
40a27c9e93 save allocation 2020-03-17 14:34:32 +01:00
A.Unger
c9010a3016 move commands to its scope 2020-03-16 17:17:56 +01:00
A.Unger
52bb4c0e1a delete helpers file 2020-03-16 12:21:06 +01:00
A.Unger
e4fee19170 remove unecessary mapstruct 2020-03-16 12:09:28 +01:00
A.Unger
6c1ed02acd arrange config.Config 2020-03-16 11:27:27 +01:00
A.Unger
fc1389b087 call ParseConfig on server command 2020-03-16 11:26:45 +01:00
A.Unger
c863d6f71f abstract ParseConfig to its own scope 2020-03-16 11:26:31 +01:00
A.Unger
86f7220526 remove hacky embedded-config flag 2020-03-16 11:25:50 +01:00
A.Unger
739d226d09 add embedded-config flag, override config.File if present 2020-03-13 10:52:42 +01:00
A.Unger
8c1f12a164 add loader helper (temporary fix, move away from the helper pattern) 2020-03-13 10:52:22 +01:00
A.Unger
f0d9b00f38 load config from embedded-config if running on embedded mode 2020-03-13 10:51:55 +01:00