Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / Net / System / Net / Mail / SmtpAuthenticationManager.cs / 1 / SmtpAuthenticationManager.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Net.Mail { using System; using System.Collections; using System.IO; using System.Net; internal static class SmtpAuthenticationManager { static ArrayList modules = new ArrayList(); static SmtpAuthenticationManager() { // #if !FEATURE_PAL if (ComNetOS.IsWin2K) { // Negotiate supported only if Win2K or later Register(new SmtpNegotiateAuthenticationModule()); } Register(new SmtpNtlmAuthenticationModule()); Register(new SmtpDigestAuthenticationModule()); #endif // !FEATURE_PAL Register(new SmtpLoginAuthenticationModule()); } internal static void Register(ISmtpAuthenticationModule module) { if (module == null) throw new ArgumentNullException("module"); lock (modules) { modules.Add(module); } } /* // Consider removing. internal static void Unregister(ISmtpAuthenticationModule module) { if (module == null) throw new ArgumentNullException("module"); lock (modules) { modules.Remove(module); } } */ /* // Consider removing. internal static void Unregister(string authenticationType) { if (authenticationType == null) throw new ArgumentNullException("authenticationType"); lock (modules) { foreach (ISmtpAuthenticationModule module in modules) { if (0 == string.Compare(module.AuthenticationType, authenticationType, StringComparison.OrdinalIgnoreCase)) { modules.Remove(module); } } } } */ internal static ISmtpAuthenticationModule[] GetModules() { lock (modules) { ISmtpAuthenticationModule[] copy = new ISmtpAuthenticationModule[modules.Count]; modules.CopyTo(0, copy, 0, modules.Count); return copy; } } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- XmlQualifiedName.cs
- ServiceObjectContainer.cs
- GenerateTemporaryAssemblyTask.cs
- WebPartCloseVerb.cs
- HttpResponseWrapper.cs
- DataGridViewRowErrorTextNeededEventArgs.cs
- RenderData.cs
- SecurityKeyUsage.cs
- WebServiceClientProxyGenerator.cs
- MaxMessageSizeStream.cs
- QilXmlWriter.cs
- DeferrableContent.cs
- KnownBoxes.cs
- FixedSOMPageConstructor.cs
- SystemMulticastIPAddressInformation.cs
- Vector3DCollection.cs
- SqlCaseSimplifier.cs
- MouseOverProperty.cs
- StrongTypingException.cs
- GenericTypeParameterBuilder.cs
- Events.cs
- RuntimeTrackingProfile.cs
- ColorKeyFrameCollection.cs
- PointCollection.cs
- TraceSection.cs
- FontDifferentiator.cs
- DefaultTextStoreTextComposition.cs
- EmptyTextWriter.cs
- DataService.cs
- SecurityElement.cs
- nulltextnavigator.cs
- ContainerUtilities.cs
- EraserBehavior.cs
- ItemsChangedEventArgs.cs
- RectangleConverter.cs
- ReflectEventDescriptor.cs
- IPipelineRuntime.cs
- CodeStatement.cs
- SqlError.cs
- WebServiceReceive.cs
- TailPinnedEventArgs.cs
- DbProviderManifest.cs
- IncrementalHitTester.cs
- Lasso.cs
- DockPattern.cs
- FormViewPageEventArgs.cs
- SafeWaitHandle.cs
- StrokeDescriptor.cs
- ModelItemCollectionImpl.cs
- Italic.cs
- ImagingCache.cs
- MessageVersion.cs
- SqlMultiplexer.cs
- CachedRequestParams.cs
- BitStack.cs
- WmlPageAdapter.cs
- TcpAppDomainProtocolHandler.cs
- WindowsHyperlink.cs
- SvcFileManager.cs
- TraceContext.cs
- GrammarBuilder.cs
- DataGridColumnDropSeparator.cs
- BinaryParser.cs
- BaseComponentEditor.cs
- SecureEnvironment.cs
- UserControl.cs
- Image.cs
- CheckBoxAutomationPeer.cs
- Model3D.cs
- CursorConverter.cs
- PeerCollaborationPermission.cs
- SessionChannels.cs
- DATA_BLOB.cs
- PropertyFilter.cs
- WebPartCatalogAddVerb.cs
- __Filters.cs
- TileModeValidation.cs
- DataSource.cs
- CRYPTPROTECT_PROMPTSTRUCT.cs
- GridPattern.cs
- UnsafeNativeMethods.cs
- AdjustableArrowCap.cs
- UnsafeNativeMethods.cs
- TextTabProperties.cs
- DesignerActionGlyph.cs
- SafeReversePInvokeHandle.cs
- BrowserCapabilitiesCompiler.cs
- ProtocolReflector.cs
- ClientData.cs
- SystemGatewayIPAddressInformation.cs
- TlsnegoTokenAuthenticator.cs
- InternalTypeHelper.cs
- BinaryReader.cs
- cookieexception.cs
- StatusBar.cs
- WorkflowCommandExtensionItem.cs
- MachineKey.cs
- ErrorInfoXmlDocument.cs
- GACIdentityPermission.cs
- ParagraphResult.cs