Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F14000117
D11727.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
649 B
Referenced Files
None
Subscribers
None
D11727.diff
View Options
diff --git a/src/applications/policy/filter/PhabricatorPolicyFilter.php b/src/applications/policy/filter/PhabricatorPolicyFilter.php
--- a/src/applications/policy/filter/PhabricatorPolicyFilter.php
+++ b/src/applications/policy/filter/PhabricatorPolicyFilter.php
@@ -411,7 +411,11 @@
$viewer = $this->viewer;
$viewer_phid = $viewer->getPHID();
- $policy = $this->customPolicies[$viewer_phid][$policy_phid];
+ $policy = idx($this->customPolicies[$viewer_phid], $policy_phid);
+ if (!$policy) {
+ // Reject, this policy is bogus.
+ return false;
+ }
$objects = $policy->getRuleObjects();
$action = null;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Oct 25, 7:20 PM (3 w, 4 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6737955
Default Alt Text
D11727.diff (649 B)
Attached To
Mode
D11727: Reject objects with invalid policies instead of fataling
Attached
Detach File
Event Timeline
Log In to Comment