Welcome Guest, Not a member yet? Register   Sign In
Are URI segments "cleansed"?
#1

[eluser]Wayne Smallman[/eluser]
Hi guys!

I've been poking around in the documentation, the web and this forum to find out if URI segments are "cleansed" before they're called from within controllers et cetera.

So far, I've not found anything that's helped.

Right now, I have:

Code:
// clean the URI segment
$uri_segment['tag'] = urldecode($this->security->set_variable_string($this->uri->segment(3)));
Where the function being called is:
Code:
function set_variable_string ($string_data) {

    return htmlentities($string_data, ENT_QUOTES, 'UTF-8');

} // end function set_variable
Problem is, I've got to do that all the way throughout the application, unless this process is being handled automatically.

Any ideas?
#2

[eluser]InsiteFX[/eluser]
It filter segments for malicious characters.

See the URI Class code.

InsiteFX
#3

[eluser]Wayne Smallman[/eluser]
InsiteFX, thanks for the reply!

That'll save me a lot of extra needless coding.




Theme © iAndrew 2016 - Forum software by © MyBB