Commit Graph

885 Commits

Author SHA1 Message Date
Henning Perl f29fe3af97
feat: stateless authorization code flow (#3515)
This patch optimizes the performance of authorization code grant flows by minimizing the number of database queries. We acheive this by storing the flow in an AEAD-encoded cookie and AEAD-encoded request parameters for the authentication and consent screens. 

BREAKING CHANGE:

* The client that is used as part of the authorization grant flow is stored in the AEAD-encoding. Therefore, running flows will not observe updates to the client after they were started.
* Because the login and consent challenge values now include the AEAD-encoded flow, their size increased to around 1kB for a flow without any metadata (and increases linearly with the amount of metadata). Please adjust your ingress / gateway accordingly.
2023-06-12 20:27:00 +02:00
Grant Zvolsky 8e961d0eb3 code review 2022-09-07 08:10:31 +02:00
Grant Zvolsky 9d01e24890 autogen(docs): generate cli docs 2022-09-07 08:10:31 +02:00
Grant Zvolsky 53862f290c refactor: improve performance and reduce data use of consent persistence layer (#2836)
This patch changes the internal data structure and reduces four (sort of redundant) tables into one. As part of this change, a few new tools have been added:

* Introduce the `hydra sql gen` command and a convenience Make target with autocompletion. The command reads migration templates from a source directory and produces migration files in a target directory. Its main function is to split a single source file into multiple files using split marks.

* Introduce the `hack/db-diff.sh` command to generate database schema diffs at different commits. This script is used to view and review the impact of migrations on the database schema.

BREAKING CHANGES: This patch merges four SQL Tables into a new table, deleting the old tables in the process. The migrations in this patch are expected to be applied offline. Please be aware that *there are no down migrations*, and if something goes wrong, data loss is possible. Always back up your database before applying migrations. For more information, see [Hydra 2.x Migration Guide](https://www.ory.sh/hydra/docs/guides/migrate-v2).

Rows with NULL login_challenge in `hydra_oauth2_consent_request` and corresponding `hydra_oauth2_consent_request_handled` are deleted as a side effect of the merge migration. This is done with the assumption that only a very small number of sessions, issued by pre-1.0 Hydra, will be affected. Please contact us if this assumption doesn't apply or if the deletion adversely affects your deployment.

Signed-off-by: Grant Zvolsky <grant@zvolsky.org>
2022-09-07 08:10:31 +02:00
Grant Zvolský 9544c03a3b
feat: custom client token ttl (#3206)
This change introduces a new endpoint that allows you to control how long client tokens last. Now you can configure the lifespan for each valid combination of Client, GrantType, and TokenType.

See #3157

Co-authored-by: aeneasr <3372410+aeneasr@users.noreply.github.com>
Co-authored-by: Andreas Bucksteeg <andreas@bucksteeg.de>
2022-07-28 21:12:09 +02:00
hackerman 159c788f58
refactor: migrate docs to ory/docs (#2982) 2022-02-11 13:43:16 +01:00
Maurice Freitag 05038deebc
docs: add options for using SQLite & Cockroach DB to 5min tutorial, fix typo in contribution guidelines (#2970) 2022-02-08 10:04:54 +01:00
Anirudh Oppiliappan 6191630b33
ci: add workflow for GitHub Actions CI (#2955)
Previously, end-to-end tests ran sequentially and took about ~30 mins to
complete. With this patch, they now run in parallel, bringing down the
total run-time to roughly about 5.5 mins. We further shave off a couple
of minutes by pre-building Hydra (setup-e2e job), and caching the built
binary. Before the start of every test run, we restore the binary at
test/e2e/hydra.

See ory-corp/cloud#1796

Co-authored-by: hackerman <3372410+aeneasr@users.noreply.github.com>
Co-authored-by: ory-bot <60093411+ory-bot@users.noreply.github.com>
2022-02-04 14:43:30 +01:00
aeneasr 41b2d856ee autogen(docs): generate and format documentation 2022-02-03 22:38:04 +00:00
aeneasr e91c761634 autogen(docs): generate and format documentation 2022-02-03 20:11:41 +00:00
aeneasr 20af96a17a autogen(docs): generate and format documentation 2022-02-03 18:02:49 +00:00
hackerman 7f574aa49b
ci: resolve prettier issues (#2965) 2022-02-03 15:34:47 +01:00
aeneasr 8cd888c1e0 chore: update repository templates
[skip ci] - updated repository templates to a4c405f4aa
2022-02-02 10:52:35 +00:00
Vincent 71c9ca4984
fix: remove outdated notice (#2961) 2022-02-02 11:47:06 +01:00
hackerman a36d623341
chore: update docusaurus template (#2956)
Signed-off-by: aeneasr <aeneasr@users.noreply.github.com>

Co-authored-by: aeneasr <aeneasr@users.noreply.github.com>
2022-01-27 14:44:12 +01:00
mig5 e257f3e6a4
docs: recommend to start with one container in prod to complete first-time setup. (#2945)
This is to ensure multiple concurrent workers don't both generate JWKs needlessly, for example.

See https://github.com/ory/hydra/discussions/2943#discussioncomment-1997531
2022-01-21 16:52:05 +01:00
aeneasr 61cef9600c autogen(docs): generate and format documentation 2022-01-20 18:40:04 +00:00
aeneasr 91b0870ee7 autogen(docs): update milestone document 2022-01-20 00:10:06 +00:00
aeneasr e29153515c chore: update docusaurus template
Signed-off-by: aeneasr <aeneasr@users.noreply.github.com>
2022-01-19 08:46:14 +01:00
Andrew Minkin 5895d03a37
docs: ORY -> Ory to follow styleguides (#2941) 2022-01-18 14:44:04 +01:00
aeneasr 844a595004 autogen(docs): generate and format documentation 2022-01-15 16:42:16 +00:00
Andrew Minkin 1b2f6a675e
docs: use Ory instead of ORY in the documentation (#2939) 2022-01-15 17:27:36 +01:00
aeneasr abffb098cf feat: native ARM64 support in Docker and Binaries
This release adds important security updates for the base Docker Images (e.g. Alpine). Additionally, Ory Hydra now has full ARM support have been resolved and the binaries are now downloadable for all major platforms.

BREAKING CHANGE: To celebrate this change, we cleaned up the ways you install Ory software. There is now one central brew / bash curl repository:

```patch
-brew install ory/hydra/hydra
+brew install ory/tap/hydra

-bash <(curl https://raw.githubusercontent.com/ory/kratos/master/install.sh)
+bash <(curl https://raw.githubusercontent.com/ory/meta/master/install.sh) hydra
```
2022-01-12 08:40:33 +01:00
aeneasr 5ca99e5988 docs: update bash install 2022-01-12 08:40:33 +01:00
aeneasr 5a4e11c94d autogen(docs): generate and format documentation 2022-01-11 15:51:54 +00:00
Mart Aarma 7578aa9f3a
feat: Hardware Security Module support (#2625)
This change introduces support for Hardware Security Modules, a physical computing device that safeguards and manages digital keys, performs encryption and decryption functions for digital signatures, strong authentication, and other cryptographic functions.

If enabled, the Hardware Security Module is used to look up any keys. If no key is found, the software module is used as a fallback for lookup. This allows you to use the HSM for privileged keys, and the software module to manage lifecycle keys (e.g. for Token Exchange).

For more information, please [read the guide](https://www.ory.sh/hydra/docs/next/guides/hsm-support).

Thank you to [aarmam](https://github.com/aarmam) for this great contribution!

Co-authored-by: aeneasr <3372410+aeneasr@users.noreply.github.com>
2022-01-11 16:33:22 +01:00
Matouš Dzivjak 74da7b6b0a feat(docs): opentelemetry tracing 2022-01-11 14:22:11 +01:00
aeneasr b75b20ab4b chore: update docusaurus template
Signed-off-by: aeneasr <aeneasr@users.noreply.github.com>
2022-01-10 08:47:28 +01:00
hackerman c094288572
chore: update docusaurus template (#2922)
Signed-off-by: aeneasr <aeneasr@users.noreply.github.com>

Co-authored-by: aeneasr <aeneasr@users.noreply.github.com>
2022-01-07 15:08:50 +01:00
aeneasr 3236e31d81 autogen(docs): update milestone document 2022-01-07 00:09:50 +00:00
aeneasr b7ecf2c1c3 chore: update docusaurus template
Signed-off-by: aeneasr <aeneasr@users.noreply.github.com>
2022-01-06 11:47:17 +01:00
aeneasr e91e2d1c63 autogen(docs): update milestone document 2022-01-05 00:09:47 +00:00
aeneasr b052084e00 autogen(docs): generate and format documentation 2022-01-04 11:16:32 +00:00
hackerman 6a18f62935
feat: OpenID Connect Dynamic Client Registration and OAuth2 Dynamic Client Registration Protocol (#2909)
This feature adds first-class support for two IETF RFCs and one OpenID Spec:

- [OpenID Connect Dynamic Client Registration 1.0](https://openid.net/specs/openid-connect-registration-1_0.html)
- [OAuth 2.0 Dynamic Client Registration Protocol](https://tools.ietf.org/html/rfc7591)
- [OAuth 2.0 Dynamic Client Registration Management Protocol](https://tools.ietf.org/html/rfc7592)

To enable this feature, which is disabled by default, set

```yaml
oidc:
  dynamic_client_registration:
    enabled: true
```

in your Ory Hydra configuration. Once enabled, endpoints `POST`, `GET`, `PUT`, and `DELETE` for `/connect/register` will be available at the public port!

Closes #2568
Closes #2549

BREAKING CHANGES: Endpoint `PUT /clients` now returns a 404 error when the OAuth2 Client to be updated does not exist. It returned 401 previously. This change requires you to run SQL migrations!

Co-authored-by: fjviera <javier.viera@mindcurv.com>
2022-01-04 12:54:32 +02:00
aeneasr ecb841c301 autogen(docs): update milestone document 2022-01-04 00:09:24 +00:00
aeneasr e03a1fedcc autogen(docs): update milestone document 2022-01-03 00:09:47 +00:00
aeneasr e10309c3a3 autogen(docs): update milestone document 2021-12-30 00:09:25 +00:00
aeneasr 72837a10e5 autogen(docs): update milestone document 2021-12-27 00:10:29 +00:00
aeneasr 9a4d04e33b autogen(docs): generate cli docs 2021-12-26 18:28:11 +00:00
Vladimir Kalugin 858f2cf362
feat: support for urn:ietf:params:oauth:grant-type:jwt-bearer grant type RFC 7523 (#2384)
This change adds support for JSON Web Token (JWT) Profile for OAuth 2.0 Authorization Grants (RFC7523).
Users of Ory Hydra will be able to grant permission for OAuth 2.0 Client to act on behalf of some Resource Owner using JWT Bearer Assertions.

For more information about this feature, please head over to the documentation: https://www.ory.sh/hydra/docs/next/guides/oauth2-grant-type-jwt-bearer

Closes #2229

BREAKING CHANGES: Please notice that this change requires SQL migrations to be applied! As always, please make a backup before applying them!

Co-authored-by: aeneasr <3372410+aeneasr@users.noreply.github.com>
Co-authored-by: Jagoba Gascón <jagoba@arima.eu>
Co-authored-by: Gajewski Dmitriy <dmit8815@gmail.com>
2021-12-26 20:15:53 +02:00
aeneasr 21b470dce2 chore: update repository templates
[skip ci] - updated repository templates to efda325028
2021-12-06 16:46:44 +00:00
aeneasr c8eb2e265c chore: update repository templates
[skip ci] - updated repository templates to 57d31bfbd5
2021-11-26 08:23:41 +00:00
Mitar 33d75d791d
fix: error handling in persister (#2860)
Co-authored-by: hackerman <3372410+aeneasr@users.noreply.github.com>
2021-11-22 12:06:42 +01:00
hackerman ebe46983a5
chore: update docusaurus template (#2846)
Signed-off-by: aeneasr <aeneasr@users.noreply.github.com>

Co-authored-by: aeneasr <aeneasr@users.noreply.github.com>
2021-11-09 12:35:52 +01:00
Yuki Hirasawa 38cbcc02a0
feat: add shellcheck to circleci (#2835)
Closes #2832
2021-11-09 09:26:50 +01:00
wanderer163 49b582c5b3
docs: fix grammar issues and typos (#2830)
Co-authored-by: aeneasr <3372410+aeneasr@users.noreply.github.com>
2021-11-09 09:24:32 +01:00
hackerman d68736627e
chore: update docusaurus template (#2838)
Signed-off-by: aeneasr <aeneasr@users.noreply.github.com>

Co-authored-by: aeneasr <aeneasr@users.noreply.github.com>
2021-11-04 13:17:41 +01:00
Hendrik Heil 45afd0d836
fix: update v1.10 installation instructions for linux (#2799)
The documentation for how to install hydra on linux is still using the old version tags
2021-11-04 11:39:15 +01:00
Amaan Iqbal 50f9dc86fe
chore: document consent requirement for non-https redirect schemes (#2826)
Co-authored-by: hackerman <3372410+aeneasr@users.noreply.github.com>
2021-11-01 19:06:26 +01:00
aeneasr f15f3398bc autogen(docs): generate cli docs 2021-11-01 12:17:42 +00:00