DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Thu, 16 Aug 2007 17:43:49 -0700,    posted on: microsoft.public.dotnet.framework.aspnet        back       

Thread Index
  1    Richard
          2    Ladislav Mrnka


How to prevent a logged-out user from navigating to past pages?   
Hi,

After the user is signed out and taken to the login page, they can still use 
the back & history features in the browser to access pages. Every page 
(except login) has a check at the beginning to redirect the user after being 
logged out, but when the page is accessed via back button, the debugger 
doesn't stop at that code b/c the page is cached and is not generated at the 
server.

How can I make these pages disappear from the history?

Thank you in advance,

Richard
Date:Thu, 16 Aug 2007 17:43:49 -0700   Author:  

RE: How to prevent a logged-out user from navigating to past pages?   
Hi Richard,
you have to turn off caching of your web pages on client browser. Put 
following directive <%@ OutputCache Location="None" VaryByParam="None" %> to 
each page you are securing by authentication so when client press back button 
it will force browser to request the page from server and to load it from 
cache.

You can also make caching profile in your web.config file and load profile 
in your pages, your settings will be centralized.

<system.web>
  <outputCacheSettings>
    <outputCacheProfiles>
      <add name="myProfile" location="None" VaryByParam="None" />
    </outputCacheProfiles>
  </outputCacheSettings>
</system.web>

Each page will refernce your profile by adding this directive:
<%@ OutputCache CacheProfile="myProfile" />

Best regards,
Ladislav

<

Regards,
Ladislav

"Richard" wrote:


> Hi,
> 
> After the user is signed out and taken to the login page, they can still use 
> the back & history features in the browser to access pages. Every page 
> (except login) has a check at the beginning to redirect the user after being 
> logged out, but when the page is accessed via back button, the debugger 
> doesn't stop at that code b/c the page is cached and is not generated at the 
> server.
> 
> How can I make these pages disappear from the history?
> 
> Thank you in advance,
> 
> Richard
Date:Fri, 17 Aug 2007 00:26:05 -0700   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us