Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Net / System / Net / SecureProtocols / AuthenticatedStream.cs / 1 / AuthenticatedStream.cs
/*++ Copyright (c) 2003 Microsoft Corporation Module Name: AuthenticatedStream.cs Abstract: A public contact for a base abstract authenticated stream. Author: Alexei Vopilov Sept 28-2003 Revision History: --*/ namespace System.Net.Security { using System; using System.IO; using System.Threading; using System.Security.Permissions; using System.Security.Principal; public abstract class AuthenticatedStream: Stream { private Stream _InnerStream; private bool _LeaveStreamOpen; protected AuthenticatedStream(Stream innerStream, bool leaveInnerStreamOpen) { if (innerStream == null || innerStream == Stream.Null) { throw new ArgumentNullException("innerStream"); } if (!innerStream.CanRead || !innerStream.CanWrite) { throw new ArgumentException(SR.GetString(SR.net_io_must_be_rw_stream), "innerStream"); } _InnerStream = innerStream; _LeaveStreamOpen = leaveInnerStreamOpen; } public bool LeaveInnerStreamOpen { get { return _LeaveStreamOpen; } } // // protected Stream InnerStream { get { return _InnerStream; } } // // protected override void Dispose(bool disposing) { #if DEBUG using (GlobalLog.SetThreadKind(ThreadKinds.User)) { #endif try { if (disposing) { if (_LeaveStreamOpen) { _InnerStream.Flush(); } else { _InnerStream.Close(); } } } finally { base.Dispose(disposing); } #if DEBUG } #endif } // // General informational properties // public abstract bool IsAuthenticated {get;} public abstract bool IsMutuallyAuthenticated {get;} public abstract bool IsEncrypted {get;} public abstract bool IsSigned {get;} public abstract bool IsServer {get;} } }
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- InterleavedZipPartStream.cs
- FtpWebResponse.cs
- AvtEvent.cs
- VectorAnimation.cs
- WmlValidatorAdapter.cs
- SecurityKeyType.cs
- NamespaceDecl.cs
- MetabaseReader.cs
- GridViewRowEventArgs.cs
- ToolBar.cs
- WebPartPersonalization.cs
- SerializableReadOnlyDictionary.cs
- WorkflowElementDialog.cs
- AlphaSortedEnumConverter.cs
- SelectionHighlightInfo.cs
- DataGridViewTextBoxCell.cs
- TextLine.cs
- EntityDataSourceChangingEventArgs.cs
- LayoutManager.cs
- TimeSpanSecondsConverter.cs
- TextViewBase.cs
- GcSettings.cs
- VisualStyleTypesAndProperties.cs
- DbConnectionPool.cs
- ClientTargetSection.cs
- StreamingContext.cs
- SqlStream.cs
- ColumnHeader.cs
- AuthStoreRoleProvider.cs
- datacache.cs
- ClientSponsor.cs
- SpeakProgressEventArgs.cs
- peernodestatemanager.cs
- UidManager.cs
- NetMsmqBindingElement.cs
- securitycriticaldataClass.cs
- AuthorizationSection.cs
- NativeActivityMetadata.cs
- TextTreeTextElementNode.cs
- TextEndOfSegment.cs
- ProfileGroupSettingsCollection.cs
- InputScopeNameConverter.cs
- SqlUtils.cs
- ItemPager.cs
- TreeViewDataItemAutomationPeer.cs
- WebServiceErrorEvent.cs
- DataListItem.cs
- SignatureHelper.cs
- HiddenFieldPageStatePersister.cs
- XmlReflectionImporter.cs
- WebAdminConfigurationHelper.cs
- LayoutEvent.cs
- AvTraceDetails.cs
- FramingFormat.cs
- WindowsContainer.cs
- XmlSchemaDocumentation.cs
- StrokeNode.cs
- SharedPerformanceCounter.cs
- Renderer.cs
- OracleParameterCollection.cs
- columnmapfactory.cs
- WebServiceData.cs
- GeneralTransform2DTo3D.cs
- Constants.cs
- StyleSheetComponentEditor.cs
- Hex.cs
- Thumb.cs
- ToolboxComponentsCreatingEventArgs.cs
- QueryInterceptorAttribute.cs
- RootBuilder.cs
- DataGridClipboardCellContent.cs
- Validator.cs
- HttpListenerException.cs
- BufferBuilder.cs
- NumericUpDown.cs
- DataSourceSelectArguments.cs
- ClusterSafeNativeMethods.cs
- XmlElementElement.cs
- APCustomTypeDescriptor.cs
- StringAnimationBase.cs
- Region.cs
- IntegerValidator.cs
- XmlSchemaInferenceException.cs
- HostedHttpTransportManager.cs
- ControlFilterExpression.cs
- SerialStream.cs
- DataObjectCopyingEventArgs.cs
- IncomingWebRequestContext.cs
- DesignSurfaceEvent.cs
- JsonSerializer.cs
- UnknownWrapper.cs
- IndexingContentUnit.cs
- TransformCryptoHandle.cs
- DurableInstanceProvider.cs
- DESCryptoServiceProvider.cs
- GetLastErrorDetailsRequest.cs
- ByteAnimationUsingKeyFrames.cs
- SoapElementAttribute.cs
- MimeObjectFactory.cs
- DataGridViewCellStyleConverter.cs