Are there any security concerns for using user provided data as an array or session key? An non-defined index error is not a concern. For instance, any dangers of doing the following? If so, how is it mitigated? Thanks
$var=$_SESSION['xyz'][$_GET['abc']];
EDIT. The reason I ask...
User uploads a document. It is stored in a tmp directory using a random name, and the filename is stored in a session using the random name as a key. It "might" later be moved to a database and stored in a permanent location.
A link is provided to download the document which contains the random name. Upon clicking, the filename is obtained using the random name as a key.