Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / ndp / fx / src / xsp / System / Web / Security / FormsIdentity.cs / 1 / FormsIdentity.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * FormsIdentity * * Copyright (c) 1999 Microsoft Corporation */ namespace System.Web.Security { using System.Security.Principal; using System.Security.Permissions; ////// This class is an IIdentity derived class /// used by FormsAuthenticationModule. It provides a way for an application to /// access the cookie authentication ticket. /// [Serializable] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class FormsIdentity : IIdentity { ////// The name of the identity (in this case, the /// passport user name). /// public String Name { get { return _Ticket.Name;}} ////// The type of the identity (in this case, /// "Forms"). /// public String AuthenticationType { get { return "Forms";}} ////// Indicates whether or not authentication took /// place. /// public bool IsAuthenticated { get { return true;}} ////// Returns the FormsAuthenticationTicket /// associated with the current request. /// public FormsAuthenticationTicket Ticket { get { return _Ticket;}} ////// Constructor. /// public FormsIdentity (FormsAuthenticationTicket ticket) { _Ticket = ticket; } private FormsAuthenticationTicket _Ticket; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* * FormsIdentity * * Copyright (c) 1999 Microsoft Corporation */ namespace System.Web.Security { using System.Security.Principal; using System.Security.Permissions; ////// This class is an IIdentity derived class /// used by FormsAuthenticationModule. It provides a way for an application to /// access the cookie authentication ticket. /// [Serializable] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class FormsIdentity : IIdentity { ////// The name of the identity (in this case, the /// passport user name). /// public String Name { get { return _Ticket.Name;}} ////// The type of the identity (in this case, /// "Forms"). /// public String AuthenticationType { get { return "Forms";}} ////// Indicates whether or not authentication took /// place. /// public bool IsAuthenticated { get { return true;}} ////// Returns the FormsAuthenticationTicket /// associated with the current request. /// public FormsAuthenticationTicket Ticket { get { return _Ticket;}} ////// Constructor. /// public FormsIdentity (FormsAuthenticationTicket ticket) { _Ticket = ticket; } private FormsAuthenticationTicket _Ticket; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- NumericUpDown.cs
- KeyedHashAlgorithm.cs
- OrderedDictionary.cs
- RightsManagementEncryptedStream.cs
- Imaging.cs
- ToolZoneDesigner.cs
- NativeObjectSecurity.cs
- AttachedPropertyBrowsableForChildrenAttribute.cs
- ConnectionConsumerAttribute.cs
- SqlProfileProvider.cs
- SmiMetaDataProperty.cs
- OperatingSystemVersionCheck.cs
- SynchronizationHandlesCodeDomSerializer.cs
- ImageField.cs
- Vector3DConverter.cs
- TickBar.cs
- DataColumnSelectionConverter.cs
- Stroke2.cs
- CqlLexerHelpers.cs
- SamlSerializer.cs
- SocketElement.cs
- CollectionBase.cs
- ConfigurationManager.cs
- ByteConverter.cs
- sapiproxy.cs
- CounterSetInstance.cs
- RegisteredArrayDeclaration.cs
- CustomCategoryAttribute.cs
- EventLogPermission.cs
- DataRelation.cs
- EnumUnknown.cs
- OrderedDictionary.cs
- DefinitionUpdate.cs
- SerializationEventsCache.cs
- PropertyPanel.cs
- ScrollEventArgs.cs
- ObjectSet.cs
- HuffCodec.cs
- Bold.cs
- BaseValidator.cs
- MarkupWriter.cs
- SelectionItemPattern.cs
- CodeDefaultValueExpression.cs
- mediaclock.cs
- CommandID.cs
- UrlMappingsModule.cs
- XamlWriter.cs
- LinkedResource.cs
- Crypto.cs
- ToolStripButton.cs
- DecimalKeyFrameCollection.cs
- HorizontalAlignConverter.cs
- HwndHost.cs
- EntityDataSourceViewSchema.cs
- ValueTable.cs
- SiteMapDataSource.cs
- SimpleHandlerBuildProvider.cs
- ProfileService.cs
- ZipFileInfoCollection.cs
- EntityParameter.cs
- DataColumnMapping.cs
- ViewGenResults.cs
- ListControl.cs
- DocumentGrid.cs
- CallbackValidator.cs
- ManagedIStream.cs
- _SslSessionsCache.cs
- PixelFormat.cs
- SmiMetaDataProperty.cs
- HoistedLocals.cs
- ToolTipService.cs
- RecipientInfo.cs
- BamlLocalizer.cs
- Renderer.cs
- X509ChainPolicy.cs
- TextTreeFixupNode.cs
- ValueQuery.cs
- PagesChangedEventArgs.cs
- ScrollItemPatternIdentifiers.cs
- ConfigXmlSignificantWhitespace.cs
- ComponentChangedEvent.cs
- SafeSecurityHelper.cs
- TemplatedMailWebEventProvider.cs
- exports.cs
- FloaterParagraph.cs
- WebPartsSection.cs
- JpegBitmapEncoder.cs
- ImageSourceValueSerializer.cs
- WorkflowApplicationAbortedEventArgs.cs
- RewritingProcessor.cs
- DataTableReader.cs
- EmptyEnumerable.cs
- RepeaterItemCollection.cs
- ToolboxItem.cs
- Underline.cs
- StateDesignerConnector.cs
- ToolTip.cs
- StandardToolWindows.cs
- Token.cs
- StateDesigner.Helpers.cs