Page MenuHomePhabricator

Improve consistency of policy enforcement on new repository edit UI
ClosedPublic

Authored by epriestley on Oct 25 2013, 9:11 PM.
Tags
None
Referenced Files
F19017435: D7406.diff
Sun, Nov 23, 7:52 AM
F19015932: D7406.id16693.diff
Sun, Nov 23, 2:06 AM
F18869354: D7406.diff
Nov 4 2025, 11:20 AM
F18672741: D7406.id16693.diff
Sep 25 2025, 8:09 AM
F18672709: D7406.id16686.diff
Sep 25 2025, 8:06 AM
F18672702: D7406.id.diff
Sep 25 2025, 8:05 AM
F18672625: D7406.diff
Sep 25 2025, 7:57 AM
F18104129: D7406.id16693.diff
Aug 10 2025, 10:05 AM
Subscribers

Details

Reviewers
btrahan
Maniphest Tasks
Restricted Maniphest Task
Commits
Restricted Diffusion Commit
rPe81bad9ba21f: Improve consistency of policy enforcement on new repository edit UI
Summary

Ref T2231. The policy rules are a little murky right now: the "Edit Repository" link requires CAN_EDIT, but the actualy page doesn't. Instead, require CAN_EDIT for the edit page.

Test Plan

As a user without CAN_EDIT, viewed a repository and clicked the edit link.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

btrahan added inline comments.
src/applications/diffusion/controller/DiffusionRepositoryCreateController.php
28

this should be CAN_EDIT, right? (On that note, I could imagine CAN_CREATE being desired for repositories (and projects))

src/applications/diffusion/controller/DiffusionRepositoryCreateController.php
28

Ack, good catch!

(We have a create policy for projects already and I'll add one for repositories pretty soon.)