Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F13972499
D8559.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
909 B
Referenced Files
None
Subscribers
None
D8559.id.diff
View Options
diff --git a/src/applications/harbormaster/step/HarbormasterHTTPRequestBuildStepImplementation.php b/src/applications/harbormaster/step/HarbormasterHTTPRequestBuildStepImplementation.php
--- a/src/applications/harbormaster/step/HarbormasterHTTPRequestBuildStepImplementation.php
+++ b/src/applications/harbormaster/step/HarbormasterHTTPRequestBuildStepImplementation.php
@@ -59,10 +59,18 @@
return false;
}
- if ($settings['method'] === null || $settings['method'] != '' &&
- !in_array ($settings['method'],
- array('GET', 'PUT', 'DELETE', 'POST'))) {
- return false;
+ $methods = array(
+ 'GET' => true,
+ 'POST' => true,
+ 'DELETE' => true,
+ 'PUT' => true,
+ );
+
+ $method = idx($settings, 'method');
+ if (strlen($method)) {
+ if (empty($methods[$method])) {
+ return false;
+ }
}
return true;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Oct 18 2024, 7:21 PM (4 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6728392
Default Alt Text
D8559.id.diff (909 B)
Attached To
Mode
D8559: Fix validation of Harbormaster HTTP methods
Attached
Detach File
Event Timeline
Log In to Comment