jojo/routers/web
Gusted 1c64bad453 fix: improve OAuth2 experience (#11715)
- fix: show oauth2 retrieve error
  - `true` indicates it only should be shown when the page is rendered
directly via `ctx.HTML` and not propagated if it redirects. As you can
see this always redirects and means the error is not shown.
  - Has the funny behavior that you get redirected to `/user/login`
without any indication what went wrong, no errors in the logs either.
- fix: pre-process OAuth2 client ID and secret
  - Spaces should are not appropriate for these input, remove them.
  - Manually copying and pasting client ID and secret from Github OAuth2
applications seems prone to introduce whitespaces.
  - The error of having a incorrect client ID is more noticeable (404 page
for the user).
  - The error of having a incorrect client secret is not noticeable (404
page for the goth library but no mention it's the wrong secret).

Reported-by: marijnh
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/11715
Reviewed-by: Mathieu Fenniak <mfenniak@noreply.codeberg.org>
Reviewed-by: Andreas Ahlenstorf <aahlenst@noreply.codeberg.org>
Co-authored-by: Gusted <postmaster@gusted.xyz>
Co-committed-by: Gusted <postmaster@gusted.xyz>
2026-03-17 18:44:23 +01:00
..
admin ci: detect and prevent empty case statements in Go code (#11593) 2026-03-10 02:50:28 +01:00
auth fix: improve OAuth2 experience (#11715) 2026-03-17 18:44:23 +01:00
demo chore(ui): change /devtest to /-/demo (#11019) 2026-01-26 13:12:25 +01:00
events chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
explore refactor: replace Value() from Option[T] with Get() & ValueOrZeroValue() (#11218) 2026-02-10 16:41:21 +01:00
feed fix: use an absolute URL for compare links in atom feed (#10933) 2026-02-01 10:00:21 +01:00
healthcheck chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
misc Move web app manifest to a own cache-able route and add a setting to set "display": "standalone"; Closes #2638 (#5384) 2026-01-09 17:49:29 +01:00
moderation feat!: Abusive content reporting (#6977) 2025-05-18 08:05:16 +00:00
org fix: check owner when changing state of project 2026-03-06 11:21:07 -07:00
repo feat: scope-specific headings for list of recent tasks (#11690) 2026-03-17 03:02:09 +01:00
shared feat: scope-specific headings for list of recent tasks (#11690) 2026-03-17 03:02:09 +01:00
user feat(ui): display repositories accessible by repo-specific access tokens (#11604) 2026-03-12 16:06:38 +01:00
base.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
githttp.go feat: replace cross origin protection (#9830) 2025-10-29 22:43:22 +01:00
goget.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
home.go feat: Global 2FA enforcement (#8753) 2025-08-15 10:56:45 +02:00
metrics.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
nodeinfo.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
swagger_json.go chore: branding import path (#7337) 2025-03-27 19:40:14 +00:00
web.go feat: scope-specific headings for list of recent tasks (#11690) 2026-03-17 03:02:09 +01:00
webfinger.go fix: trim trailing slash in WebFinger OIDC issuer link (#8794) 2025-08-06 14:50:51 +02:00