JSP writes to text file: File permissions
I wrote a JSP webpage that takes data from a registration form and adds it to a CSV spreadsheet. The permissions for the CSV file are set to 666.
My question is: can users make arbitrary changes to the CSV? My JSP prevents unauthorized data from getting through into the file, but if the user can just open up the file and bypass the JSP completely, what can be done about that? Or does the user only have access to add to the CSV through the JSP?
Also, in the data that is being written to the CSV, what should I prevent from being written? Right now I have it filtering out special characters, but in the long run it would be nice to allow special characters because of the type of data we are receiving.

