<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <%@ page import="java.util.*" %> Data Dump

JEE

<% ServletContext cx = getServletContext(); %> JEE API = <%= cx.getMajorVersion() %>.<%=cx.getMinorVersion() %>
Server = <%= cx.getServerInfo() %>
ContextName = <%= cx.getServletContextName() %>
ContextPath = <%= cx.getContextPath() %>
RealPath = <%= cx.getRealPath("/") %>
ServletInfo = <%= getServletInfo() %>
ServletName = <%= getServletName() %>

request headers

<% Enumeration names = request.getHeaderNames(); while (names.hasMoreElements()) { String name = (String) names.nextElement(); Enumeration values= request.getHeaders(name); while (values.hasMoreElements() ) { String value = values.nextElement(); out.println( name + '=' + value + "
"); } } %>

request info

AuthType=<%=request.getAuthType() %>
LocalAddr=<%=request.getLocalAddr() %>
LocalName=<%=request.getLocalName() %>
LocalPort=<%=request.getLocalPort() %>
Method=<%=request.getMethod() %>
PathInfo=<%=request.getPathInfo() %>
Protocol=<%=request.getProtocol() %>
QueryString=<%=request.getQueryString() %>
RemoteAddr=<%=request.getRemoteAddr() %>
RemoteHost=<%=request.getRemoteHost() %>
RemotePort=<%=request.getRemotePort() %>
RemoteUser=<%=request.getRemoteUser() %>
RequestedSessionId=<%=request.getRequestedSessionId() %>
RequestUri=<%=request.getRequestURI() %>
RequestUrl=<%=request.getRequestURL() %>
scheme=<%=request.getScheme() %>
ServerName=<%=request.getServerName() %>
ServerPort=<%=request.getServerPort() %>
ServletPath=<%=request.getServletPath() %>

Parameters

<% Enumeration parms = request.getParameterNames(); while (parms.hasMoreElements()) { String name = (String) parms.nextElement(); String val = request.getParameter(name); out.println(name + "=" + val + "
"); } %>

Cookies

<% Cookie[] cookies = request.getCookies(); if( cookies != null) { for (int i=0; i"); } } %>