Token Exchange Testbed¶
The token exchange testbed tries per-hop OAuth 2.0 token exchange with LS Login, for the chain of ELIXIR On-Cloud services from a front end through a WES and the proTES gateway to the TES nodes: each service exchanges the token that it received for one that is only good for the next service. It tests the design proposed in [proTES issue
391](https://github.com/elixir-cloud-aai/proTES/issues/391), with a small¶
client, gateway and node as stand-ins for the real services.
Local mock only
So far, the testbed has run against a local mock of LS Login only. The mock accepts almost everything, so the testbed enforces LS Login's rules itself. A passing run shows that the testbed works, not how LS Login behaves. See the testbed's limits. Never use it in production or with real accounts.
What you need¶
- Docker with Compose, on Linux, macOS or WSL. It has been run on Linux only so far.
- Nothing else for the mock: no Python on your computer, no free ports, no account.
Steps¶
-
Clone the repository, build the images and run all scenarios against the mock:
-
Check the output. It ends with
N/N checks passed, with the same number twice. -
Remove the containers:
The repository's CI runs the same scenarios on every change.
What you see¶
The run goes through the scenarios of the tests: one sign-in, then one token per hop up to the node; requests that must be refused, and which service refuses them; groups and entitlements; token lifetimes and refresh; and what a node can tell about the path of a request.
Where to go next¶
- To try the commands by hand against the mock: Checking the setup.
- To run the tests against LS Login, with test accounts and registered clients: Tests and Client registration.
- The background, independent of any product: Use case.