mirror of
https://github.com/go-gitea/gitea.git
synced 2026-03-22 06:24:14 -05:00
Support federated login for guest users (OpenID) #64
Closed
opened 2025-11-02 03:07:04 -06:00 by GiteaMirror
·
19 comments
No Branch/Tag Specified
main
release/v1.25
release/v1.24
release/v1.23
release/v1.22
release/v1.21
release/v1.20
release/v1.19
release/v1.18
release/v1.17
release/v1.16
release/v1.15
release/v1.14
release/v1.13
release/v1.12
release/v1.11
release/v1.10
release/v1.9
release/v1.8
v1.25.3
v1.25.2
v1.25.1
v1.25.0
v1.24.7
v1.25.0-rc0
v1.26.0-dev
v1.24.6
v1.24.5
v1.24.4
v1.24.3
v1.24.2
v1.24.1
v1.24.0
v1.23.8
v1.24.0-rc0
v1.25.0-dev
v1.23.7
v1.23.6
v1.23.5
v1.23.4
v1.23.3
v1.23.2
v1.23.1
v1.23.0
v1.23.0-rc0
v1.24.0-dev
v1.22.6
v1.22.5
v1.22.4
v1.22.3
v1.22.2
v1.22.1
v1.22.0
v1.23.0-dev
v1.22.0-rc1
v1.21.11
v1.22.0-rc0
v1.21.10
v1.21.9
v1.21.8
v1.21.7
v1.21.6
v1.21.5
v1.21.4
v1.21.3
v1.21.2
v1.20.6
v1.21.1
v1.21.0
v1.21.0-rc2
v1.21.0-rc1
v1.20.5
v1.22.0-dev
v1.21.0-rc0
v1.20.4
v1.20.3
v1.20.2
v1.20.1
v1.20.0
v1.19.4
v1.21.0-dev
v1.20.0-rc2
v1.20.0-rc1
v1.20.0-rc0
v1.19.3
v1.19.2
v1.19.1
v1.19.0
v1.19.0-rc1
v1.20.0-dev
v1.19.0-rc0
v1.18.5
v1.18.4
v1.18.3
v1.18.2
v1.18.1
v1.18.0
v1.17.4
v1.18.0-rc1
v1.19.0-dev
v1.18.0-rc0
v1.17.3
v1.17.2
v1.17.1
v1.17.0
v1.17.0-rc2
v1.16.9
v1.17.0-rc1
v1.18.0-dev
v1.16.8
v1.16.7
v1.16.6
v1.16.5
v1.16.4
v1.16.3
v1.16.2
v1.16.1
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c1
v1.3.2
v1.3.1
v1.3.0
v1.3.0-rc2
v1.3.0-rc1
v1.2.3
v1.2.2
v1.2.1
v1.2.0
v1.2.0-rc3
v1.2.0-rc2
v1.1.4
v1.2.0-rc1
v1.1.3
v1.1.2
v1.1.1
v1.1.0
v1.0.2
v1.0.1
v1.0.0
v0.9.99
Labels
Clear labels
$20
$250
$50
$500
backport/done
💎 Bounty
docs-update-needed
good first issue
hacktoberfest
issue/bounty
issue/confirmed
issue/critical
issue/duplicate
issue/needs-feedback
issue/not-a-bug
issue/regression
issue/stale
issue/workaround
lgtm/need 2
modifies/api
modifies/translation
outdated/backport/v1.18
outdated/theme/markdown
outdated/theme/timetracker
performance/bigrepo
performance/cpu
performance/memory
performance/speed
pr/breaking
proposal/accepted
proposal/rejected
pr/wip
pull-request
reviewed/wontfix
💰 Rewarded
skip-changelog
status/blocked
topic/accessibility
topic/api
topic/authentication
topic/build
topic/code-linting
topic/commit-signing
topic/content-rendering
topic/deployment
topic/distribution
topic/federation
topic/gitea-actions
topic/issues
topic/lfs
topic/mobile
topic/moderation
topic/packages
topic/pr
topic/projects
topic/repo
topic/repo-migration
topic/security
topic/theme
topic/ui
topic/ui-interaction
topic/ux
topic/webhooks
topic/wiki
type/bug
type/deprecation
type/docs
type/enhancement
type/feature
type/miscellaneous
type/proposal
type/question
type/refactoring
type/summary
type/testing
type/upstream
Mirrored from GitHub Pull Request
No Label
type/proposal
Milestone
No items
No Milestone
Projects
Clear projects
No project
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/gitea#64
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @stevenroose on GitHub (Nov 16, 2016).
From @stevenroose on May 26, 2015 9:5
It bothers many that they have to enter a full form of personal information in order to just file a bug or make a feature request.
OpenID support can fix this and allows guest users to login with they GitHub of Google account f.e.
Ideally, it would also be possible to restrict these "guest"/external users to only be able to make create issues and pull requests and not have their own repositories.
Copied from original issue: gogits/gogs#1297
--- Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/39298589-support-federated-login-for-guest-users-openid?utm_campaign=plugin&utm_content=tracker%2F47456670&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F47456670&utm_medium=issues&utm_source=github).@sbrl commented on GitHub (Nov 16, 2016):
Waaaaat? I don't understand what's going on here. What's
gitea? Why has it been forked? Isgogsstill a thing?To answer [this comment], I don't think I can since I don't have go installed, I don't know go, I don't understand the go package system, and I don't understand openid 😕 😞
???
@tboerger commented on GitHub (Nov 16, 2016):
@stevenroose you shouldn't copy everything, a single reference to the issue should be fine.
@strk commented on GitHub (Nov 17, 2016):
@sbrl
giteais a fork ofgogsmade to avoid development being blocked by a single person in charge of accepting contributions. Management ofgiteais in the hands of 3 owners elected yearly by a growing number of maintainers (currently 10). See the CONTRIBUTING.md file for further details.Binary packages, for those who don't want to build from sources, are in the works, see #31
@sbrl commented on GitHub (Nov 17, 2016):
Ah right! I might switch when a full release is made then.
@bkcsoft commented on GitHub (Nov 23, 2016):
@tboerger One can always clean it up 😉 (Like I just did)
@tscs37 commented on GitHub (Dec 10, 2016):
I'm in favor of adding basic OpenID support and like to also propose OpenID Connect support.
That would allow arbitrary federation from any provider that supports OpenID Connect.
@strk commented on GitHub (Dec 10, 2016):
@tscs37 are you up to try at moving some steps toward the implementation of one or the other ?
I've moved the first step for OpenID but it's far from ready (mostly needs UX design), see #271
As per
OpenID Connect, do you know of any consumer implementation that does support arbitrary provider support ? I'm asking because I don't and would like to spread the word about its existance.@stevenroose commented on GitHub (Dec 12, 2016):
@strk StackExchange has it (prob not open source). I thought the OSQA had it too, that's an old open-source clone of SE. Or is that basic OpenID?
@strk commented on GitHub (Dec 12, 2016):
I can log into StackExchange with my OpenID-2.0 provider
(not OAuth based). I dont' have an OpenID-Connect provider
to test with StackExchange, but I suspect only hard-coded
providers would be supported there.
@stevenroose commented on GitHub (Dec 14, 2016):
Just to copy from @strk 's PR:
The big advantage I would see from having OpenID is as a way of users to login without having been registered. Just like systems like Discuss allow anyone with an OpenID (even though Discuss requires this to be from a small set of providers) to make contributions in the form of issues or (federated) pull requests.
A possible setup that would benefit greatly from OpenID is the case of single-user usage. Gitea as a self-hosted Git homepage in which only one user has commit access, while he can allow anyone to open issues or request pulls with their OpenID (and a CAPTCHA ofc).
@strk commented on GitHub (Dec 14, 2016):
Ouch, I already commented in the PR, can we continue there ?
@stevenroose commented on GitHub (Mar 19, 2017):
Does #816 allow guest users in some way?
@strk commented on GitHub (Mar 20, 2017):
@stevenroose I guess you meant #618 (OpenID). It depends on what you mean by "guest users".
Logging in via OpenID still needs you to register as a local user, and confirm your email if the service is configured like that.
The registration step is needed to have a unique identifier on the specific node (rather than using the full OpenID URI as an identifier). Also the code to deal with permissions and teams invitations and such are all based on a local "UserID", so registration is also needed for that (to assign an UserID to an OpenID account).
Doing the registration step also lets you associate multiple OpenID URIs to a single account.
BTW, @stevenroose as you mentioned stackexchange, it also supports OpenID-2.0 so you do can login to Gitea now with "openid.stackexchange.com" as your OpenID URI :)
@sbrl commented on GitHub (Mar 20, 2017):
@strk Awesome! So can I restrict auto-registered account to not be able to create repositories too?
@strk commented on GitHub (Mar 22, 2017):
To my knowledge there's currently no support to specify default permissions for new users, but it'll be great to add that feature !
@stevenroose commented on GitHub (Mar 22, 2017):
@strk @sbrl, yeah that's what I meant with "guest users". Those that only can make issues and submit federated PRs. I.e. not being able to take resources, so that you don't have to trust them not to DOS down your Gitea..
@strk commented on GitHub (Mar 22, 2017):
"taking resources" should be clearly defined.
Opening a PR at the bare minimum probably implies opening
a "ticket" record (issue/PR) and probably also the ability
to discuss/react to comments (so more records, issue/pr comments).
I suspect that alone would currently be enough to DOS a Gitea instance.
Anyway I do see also another problem with limiting the space taken
by a user. A fork might probably not take much space until it diverges
too much from the original, but how much is too much ?
I think this discussion (setting limits for users) should be discussed
in a separate ticket, IMHO.
Beside, if I'm not mistaken someone started work on a more fine-grained
set of permissions (check out open issues/PRs)
@sbrl commented on GitHub (Mar 23, 2017):
I'd allow the admin to set the amount of space allowed on a per-group basis or something. My main concern is losing all my server's (rather limited) hard drive space.
And can I migrate to gitea from gogs version 0.10.1.0228? I missed the first release of gitea, and according to the website it's not an explicitly supported upgrade path.
@strk commented on GitHub (Mar 23, 2017):
@sbrl see also #1377 for setting users limits (and use the forum or IRC chat or file another issue to know about upgrade)