Commit Graph

27 Commits

Author SHA1 Message Date
ffranr
db30c8384d lint: remove depreciated io/ioutil
As of Go 1.16, functionality provided in io/ioutil has been depreciated
in favour of the io or os packages. Now that Go has been
upgraded in go.mod, the linter will not pass without these changes.
2023-01-27 13:27:38 +00:00
ffranr
73ed7bfc52 lint: rename private struct field: freebieDb
freebieDb -> freebieDB
Change suggested by linter stylecheck (rule: ST1003).
2023-01-27 12:41:18 +00:00
Oliver Gugger
c45cd3a317 proxy+aperture: refactor to local service
We want aperture to handle some of the incoming requests on its own,
without forwarding/proxying them to a remote backend. Those "local"
services can register themselves and will be given every request for
inspection. If a service decides to handle it locally, the request is
passed to that service and not forwarded.
2021-11-24 17:32:46 +01:00
Elle Mouton
a955d9174b multi: add and use DynamicPrice option
This commit adds a DynamicPrice member to the Services struct and uses
its values to determine if a GRPCPricer or DefaultPricer should be
initialised. The commit also updates the sample-conf.yaml file with the
new config options.
2021-08-03 14:31:00 +02:00
Elle Mouton
853b131d80 multi: cleanup proxy
This commit adds to ability to cleanup the Proxy by adding a Close
method and calling this method during server shut down.
2021-08-03 14:30:55 +02:00
Oliver Gugger
74282b9978 proxy: remove manual trailer fields
The last bugfix added some explicit header fields in an attempt of
fixing an issue with error responses. Unfortunately they weren't
strictly needed for the fix but ended up causing issues in a non-error
case.
This commit removes those header fields again and makes sure the "auth
header not found in response" header doesn't occur anymore.
2021-05-31 21:11:19 +02:00
Oliver Gugger
cf11bcc626 proxy: reproduce and fix weird HTTP/2 error 2021-05-11 13:25:25 +02:00
Oliver Gugger
ec089c4723 config+proxy: disable static file serving by default 2020-07-17 11:09:23 +02:00
Elle Mouton
162571ac45 aperture: Custom price per service 2020-05-13 09:57:40 +02:00
Oliver Gugger
59268f8f59 auth+lsat: move LSAT specific code 2020-03-19 16:16:34 +01:00
Olaoluwa Osuntokun
0c14706fa4 aperture: propagate rename 2020-03-18 13:57:18 -07:00
Oliver Gugger
c6c62b9472 multi: fix all linter errors 2019-12-04 10:58:04 +01:00
Oliver Gugger
c2e9d540ba proxy: add auth whitelist for paths 2019-12-04 10:45:07 +01:00
Wilmer Paulino
95c405b0c7 auth+proxy: extend Authenticator methods with target service name
The target service name remains unused in its current form, but will be
required in order to verify that an incoming request with an LSAT
attached is authorized to access the service being attempted. We can
derive this from the request's host field, but we choose to extend the
methods with the additional parameter in order to prevent parsing the
host field again to determine which service is being accessed.
2019-11-26 11:12:48 -08:00
Oliver Gugger
aef413da0a auth+proxy: forward auth to backend 2019-11-18 10:41:12 +01:00
Oliver Gugger
00f661318f proxy: send error as gRPC error 2019-11-15 09:45:06 +01:00
Oliver Gugger
564deb6545 proxy: add demo and README with the use cases 2019-11-12 12:02:14 +01:00
Oliver Gugger
e704ba4aa9 proxy: add prefix logger to log remote IP address 2019-11-12 12:02:14 +01:00
Oliver Gugger
38c17f4de8 proxy: dispatch all non-matched requests to static file server 2019-11-12 12:02:14 +01:00
Oliver Gugger
672766b340 proxy: allow update of backend services 2019-11-12 12:02:13 +01:00
Oliver Gugger
c8cbeb9ab1 config: add static file root 2019-11-06 13:21:56 +01:00
Oliver Gugger
a44e9fbd22 freebie+proxy: add memory based freebie DB implementation 2019-11-06 13:21:56 +01:00
Oliver Gugger
83395c0c98 proxy+auth: add log statements 2019-11-06 13:21:55 +01:00
Oliver Gugger
5a3b8b79d2 proxy: implement basic proxy functionality 2019-11-06 13:21:45 +01:00
Oliver Gugger
4d1fbbf4d6 proxy: add static file server 2019-11-04 12:43:31 +01:00
Oliver Gugger
9552a70cb9 proxy: match service with regular expressions 2019-11-04 12:43:25 +01:00
Valentine Wallace
279fa2a64b Initial version of the proxy.
Missing: logging, an Authenticator implementing the LSAT HTTP
and gRPC protocol.
2019-09-12 16:41:25 -07:00