By looking at the name of this directive one may think that magic_quotes are only applied to $_GET, $_POST and $_COOKIE superglobals but there is one perturbing comment on the PHP Manual:
Please note, that when
magic_quotes_gpcis set not only$_POST,$_GET,$_REQUEST,$_COOKIEarrays values are slashed. Actually every string value in$GLOBALSarray is slashed, ie.$GLOBALS['_SERVER']['PATH_INFO'](or$_SERVER['PATH_INFO']).
Can anyone confirm that this is true? Are the superglobals $GLOBALS, $_SERVER, $_FILES, $_SESSION and $_ENV affected as well?
One more question, if I iterate stripslashes() over the $_GET, $_POST and $_COOKIE arrays do I also need to iterate through the $_REQUEST array? Or are the changes automatically reflected?