Web Science/Part1: Foundations of the web/Dynamic Web Content/Handling a post request in a Java Servlet/quiz

{How can HTTP header fields of an HTTP request be accessed in the Java code snippet which uses Jetty as an embedded servlet?} - Retrieve the data from the socket using a reader class. - Retrieve the data from the socket using an input stream class. + There are methods on the request object for accesing HTTP header fields + Inside of the doGet and doPost methods exist objects which have access to the header fields.

{What should one do when accessing request parameters or HTTP headers and processing them inside a server?} + The user input retrieved from the fields should be escaped before running database queries - The video demonstrated everything that should happen. Nothing more needs to be done.
 * This is important because else SQL injection can easily happen.
 * No, the video would result to insecure code and bad software.