Obtain the requester's MAC address
Package cn.com. henry. servlet; import Java. io. bufferedreader; import Java. io. ioexception; import Java. io. inputstreamreader; import Java. io. printwriter; import java.net. inetaddress; import java.net. networkinterface; import javax. servlet. servletexception; import javax. servlet. HTTP. httpservlet; import javax. servlet. HTTP. httpservletrequest; import javax. servlet. HTTP. httpservletresponse; public class test extends H Ttpservlet {/*** constructor of the object. */public test () {super ();}/*** destruction of the servlet. <br> */Public void destroy () {super. destroy (); // just puts "Destroy" string in log // put your code here}/*** the doget method of the servlet. <br> ** this method is called when a form has its tag Value Method equals to get. ** @ Param request the request send by the client to the server * @ P Aram response the response send by the server to the client * @ throws servletexception if an error occurred * @ throws ioexception if an error occurred */Public void doget (httpservletrequest request, httpservletresponse response) throws servletexception, ioexception {response. setcontenttype ("text/html"); printwriter out = response. getwriter (); out. println ("<! Doctype HTML public \ "-// W3C // dtd html 4.01 transitional // en \"> "); out. println ("<HTML>"); out. println ("