mirror of
https://github.com/github/codeql.git
synced 2026-02-13 05:31:22 +01:00
21 lines
580 B
Java
21 lines
580 B
Java
import javax.servlet.ServletException;
|
|
import javax.servlet.http.HttpServlet;
|
|
import javax.servlet.http.HttpServletRequest;
|
|
import javax.servlet.http.HttpServletResponse;
|
|
import javax.servlet.http.Part;
|
|
|
|
/**
|
|
* Hello world!
|
|
*/
|
|
public class App {
|
|
|
|
|
|
|
|
public class FileUploadServlet extends HttpServlet {
|
|
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, java.io.IOException {
|
|
Part filePart = request.getPart("file"); // Retrieves <input type="file" name="file">
|
|
sink(filePart.getName());
|
|
|
|
}
|
|
}
|
|
} |