
<%
'@BEGINVERSIONINFO

'@APPVERSION: 5.10.10

'@FILENAME: processor.asp
	
'@FILEVERSION: 1.0.1

'@VERSIONDATETIME: 2/21/01

'@DESCRIPTION: Enforces Login Security for all Admin Files

'@STARTCOPYRIGHT
'The contents of this file is protected under the United States
'copyright laws and is confidential and proprietary to
'LaGarde, Incorporated.  Its use or disclosure in whole or in part without the
'expressed written permission of LaGarde, Incorporated is expressly prohibited.
'
'(c) Copyright 2000,2001 by LaGarde, Incorporated.  All rights reserved.
'Original File supplied by Michael Hamilton, Suite500.net
'@ENDCOPYRIGHT

'@ENDVERSIONINFO

	If Request.ServerVariables("LOGON_USER") = "" Then
		Dim fso, drv, drvPath
		drvPath = left(Request.ServerVariables("PATH_TRANSLATED"),2)  ' get the drive ???
		Set fso = CreateObject("Scripting.FileSystemObject")
		Set drv = fso.GetDrive(fso.GetDriveName(drvPath))

%>
<head>
<style>
a:link                  {font:8pt/11pt verdana; color:FF0000}
a:visited               {font:8pt/11pt verdana; color:#4e4e4e}
</style>
<META NAME="ROBOTS" CONTENT="NOINDEX">
<title>You are not authorized to view this page</title>
<META HTTP-EQUIV="Content-Type" Content="text-html; charset=Windows-1252">
</head>
<script> 
function Homepage(){
<!--
// in real bits, urls get returned to our script like this:
// res://shdocvw.dll/http_404.htm#http://www.DocURL.com/bar.htm 

	//For testing use DocURL = "res://shdocvw.dll/http_404.htm#https://www.microsoft.com/bar.htm"
	DocURL=document.URL;
	
	//this is where the http or https will be, as found by searching for :// but skipping the res://
	protocolIndex=DocURL.indexOf("://",4);
	
	//this finds the ending slash for the domain server 
	serverIndex=DocURL.indexOf("/",protocolIndex + 3);

	//for the href, we need a valid URL to the domain. We search for the # symbol to find the begining 
	//of the true URL, and add 1 to skip it - this is the BeginURL value. We use serverIndex as the end marker.
	//urlresult=DocURL.substring(protocolIndex - 4,serverIndex);
	BeginURL=DocURL.indexOf("#",1) + 1;
	urlresult=DocURL.substring(BeginURL,serverIndex);
		
	//for display, we need to skip after http://, and go to the next slash
	displayresult=DocURL.substring(protocolIndex + 3 ,serverIndex);
	document.write('<A HREF="' + urlresult + '">' + displayresult + "</a>");
}
//-->
</script>
<body bgcolor="FFFFFF">
<table width="410" cellpadding="3" cellspacing="5">
  <tr>    
    <td align="left" valign="middle" width="360">
	<h1 style="COLOR:000000; FONT: 13pt/15pt verdana"><!--Problem--><%response.write Request.ServerVariables("AUTH_TYPE")%>
StoreFront 5.0 Authorization Error<br><br>You are not authorized to view this page</h1>
    </td>
  </tr>
  
  <tr>
    <td width="400" colspan="2">
	<font style="COLOR:000000; FONT: 8pt/11pt verdana">You do not have permission to view this directory or page using the credentials you supplied.</font></td>
  </tr>
  <tr>
    <td width="400" colspan="2">
	<font style="COLOR:000000; FONT: 8pt/11pt verdana">

	<hr color="#C0C0C0" noshade>
	
   <p>Please try the following:</p>
<ul>
<li>Click the <a href="javascript:location.reload()">Refresh</a> button to try again with different credentials.</li>
<li>If you believe you should be able to view this directory or page, please contact the Web site administrator by using the e-mail address or phone number listed on the 
	<script> 
	<!--
	if (!((window.navigator.userAgent.indexOf("MSIE") > 0) && (window.navigator.appVersion.charAt(0) == "2")))
	{
		Homepage();
	}
	//-->
	</script>
	home page.</li>
</ul>
    <h2 style="font:8pt/11pt verdana; color:000000">HTTP 401.2 - Unauthorized: Logon failed<br></h2>
	<hr color="#C0C0C0" noshade>
	<p>Technical Information (for support personnel)</p>
	<ul>
	<li>Background:<br>
	This is caused by a providing incorrect credentials.
<p>
<li>More information:<br>
<a href="http://www.storefront.net" target="_blank">StoreFront</a>
</li>
</p>
</ul> 
	</font></td>
  </tr>
</table>
</body>
</html>
<%
	Response.End		
End If
Response.Buffer = True


%>





