From 2458733f8b8e269549a0633db28c729f2b5092b8 Mon Sep 17 00:00:00 2001 From: Xenira <1288524+Xenira@users.noreply.github.com> Date: Mon, 21 Oct 2024 19:49:59 +0200 Subject: [PATCH] fix(globals)!: disabled `$_REQUEST` super global function BREAKING CHANGE: If you used `http_request_vars()` before it will now panic until a proper implementation is found. Refs: #331 --- src/zend/globals.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/zend/globals.rs b/src/zend/globals.rs index 2e3789e6c..11e7b2e45 100644 --- a/src/zend/globals.rs +++ b/src/zend/globals.rs @@ -284,9 +284,10 @@ impl ProcessGlobals { /// Get the HTTP Request variables. Equivalent of $_REQUEST. pub fn http_request_vars(&self) -> &ZendHashTable { - self.http_globals[TRACK_VARS_REQUEST as usize] - .array() - .expect("Type is not a ZendArray") + todo!("$_REQUEST super global was erroneously fetched from http_globals which resulted in an out-of-bounds access. A new implementation is needed."); + // self.http_globals[TRACK_VARS_REQUEST as usize] + // .array() + // .expect("Type is not a ZendArray") } /// Get the HTTP Environment variables. Equivalent of $_ENV.