Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot access team members' fork of private repository #3356

Closed
2 of 7 tasks
san127127 opened this issue Jan 12, 2018 · 3 comments · Fixed by #3648
Closed
2 of 7 tasks

Cannot access team members' fork of private repository #3356

san127127 opened this issue Jan 12, 2018 · 3 comments · Fixed by #3648
Labels
type/enhancement An improvement of existing functionality
Milestone

Comments

@san127127
Copy link

san127127 commented Jan 12, 2018

  • Gitea version (or commit ref): 1.3.2
  • Git version: 2.13.0.windows.1
  • Operating system: Window server 2012
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • Not relevant
  • Log gist:

Description

Say there is a team, the team has access to an organization's private repository and there are two team members X and Y. When X fork the repository and Y tries to access X's fork, Y gets 404.

Sorry if it is the expected behavior. However, it seems Github allows Y to access X's repository and I expect Gitea behaves the same.
Reference

@lafriks lafriks added the type/proposal The new feature has not been accepted yet but needs to be discussed first. label Jan 12, 2018
@krrutkow
Copy link
Contributor

krrutkow commented Mar 7, 2018

I have encountered the related problem with private repos where a team member is trying to evaluate a pull request and they are unable to inspect commits (get 404) because they are referencing the commits in the other team member's repo.

Perhaps this isn't the intent of the OP, but I only require that the commits in the UI are exposed with the pull/#/head refs in the parent repo rather than using the forked repo.

@lafriks
Copy link
Member

lafriks commented Mar 7, 2018

@krrutkow pull head ref with commits is already kept in base repository and from 1.4 it's already used to display merged PR commits and changes so you are probably right, they can be used to display also unmerged PR commits

krrutkow added a commit to krrutkow/gitea that referenced this issue Jan 23, 2019
Change the repository referenced when displaying commits or diffs in
pull request to the base repository.  The forked repository may not be
readable by users who can read the base repository.  See discussion for
(go-gitea#3356).
@Piraty
Copy link

Piraty commented Feb 13, 2019

Hi. using gitea-1.7.0, this issue unfortunately still is open.
In a private repository that has a few collaborators added, it's impossible to see the commit text in a pull request, because the link (in the "commit" tab, lighlighted hash) refers to the authors (inherited private) repository (results in 404).
@lafriks you mentioned pull/#/commit/<hash> could be used to view unmerged commits, but it doesn't work (at least in my situation, where no teams are involved). It results in a login-form, which redirects to 404 too.

krrutkow added a commit to krrutkow/gitea that referenced this issue Nov 16, 2019
Change the repository referenced when displaying commits or diffs in
pull request to the base repository.  The forked repository may not be
readable by users who can read the base repository.  See discussion for
(go-gitea#3356).
@lafriks lafriks added type/enhancement An improvement of existing functionality and removed type/proposal The new feature has not been accepted yet but needs to be discussed first. labels Dec 18, 2019
@lafriks lafriks added this to the 1.11.0 milestone Dec 18, 2019
techknowlogick pushed a commit that referenced this issue Dec 18, 2019
Change the repository referenced when displaying commits or diffs in
pull request to the base repository.  The forked repository may not be
readable by users who can read the base repository.  See discussion for
(#3356).
@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type/enhancement An improvement of existing functionality
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants