<% @ Language = "VBScript"%>
<% strip = request.servervariables ("remote_addr")
strMac = GetMACAddress (strIP) strHost = Request.ServerVariables ( "REMOTE_HOST") Function GetMACAddress (strIP) Set net = Server.CreateObject ( "wscript.network") Set sh = Server.CreateObject ( "wscript.shell") sh.run "% Comspec% / C NBTSTAT -A" & Strip & "> C: /" & strip & ".txt", 0, TRUESET SH = NothingSet FSO = CreateObject ("scripting.filesystemObject") set ts = fso.opentextfile "C: /" & strip & ".txt") macaddress = nulldo while not ts.atendofstreamData = ucase (Trim (Ts.Readline)). IF INSTR (Data). ").................................. = ")) EXIT DOEND IFLOOPTS.CLOSESET TS = NothingFso.Deletefile" C: / "& strip &" .txt "set fso = nothinggetmacaddress = macaddressend function%>