![]() |
| ||
| filtering bad user input I am trying to set up a jsp page which takes input from any form and filters out user input which may pose a security risk. I am using the following function to try to do this: I get a null pointer from the following line: if(test.indexOf(bad_characters[i]) != -1){Been working at the computer for too long and going kinda bugeyed - so any other eyes that check this out are much appreciated!Thanks in advance, Dave. |
| ||
| Re: filtering bad user input Wow, this is embarassing - the form I was submitting to the page had a spelling mistake inthe name of a field - so the page was trying to "request.getParameter("non_existant_parameter");" and passing a null pointer into the function. Sometimes you just need some sleep and or do something else for awhile.... Thanks to everyone who looked at the code. Sorry for the inconvienance. Dave. |
| All times are GMT -4. The time now is 12:08 pm. |
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC