You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In src/Appwrite/Platform/Modules/Proxy/Action.php, the validateDomainRestrictions() method has a bug on line 53. The empty() check inside the foreach loop checks the outer variable$functionsDomains (plural) instead of the loop variable$functionsDomain (singular).
The loop should check empty($functionsDomain) (singular) to skip empty entries from the comma-separated string, consistent with the sites domain loop above it.
Impact
If _APP_DOMAIN_FUNCTIONS is set (non-empty), the empty() check never triggers, meaning empty entries from trailing commas or double commas get processed as domain restrictions
Domain restriction validation for functions domains may not work correctly
Fix
- if (empty($functionsDomains)) {+ if (empty($functionsDomain)) {
Single character fix: $functionsDomains → $functionsDomain
Activity
zaidxshaikh commentedon Mar 30, 2026
I'd like to work on this. I've already identified the fix - it's a single character change from \ to \ on line 53.
Fix domain validation checking wrong variable in functions domain loop
bellahadid27211-lab commentedon Mar 30, 2026
Fix domain validation checking wrong variable in functions domain loop
zaidxshaikh commentedon Mar 31, 2026
@bellahadid27211-lab Thanks! PR is already open: #11676
fix: validate proxy functions domains with empty entries (appwrite#11675
HarshMN2345 commentedon Sep 8, 2026
fixed in #13529