Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / infocard / Service / managed / Microsoft / InfoCards / TokenFactoryBase.cs / 1 / TokenFactoryBase.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace Microsoft.InfoCards { using System; using System.Security.Cryptography; using System.Security.Cryptography.X509Certificates; using System.ServiceModel.Security; using IDT = Microsoft.InfoCards.Diagnostics.InfoCardTrace; // // Summary: // Base implementation of ITokenFactory. // internal abstract class TokenFactoryBase : ITokenFactory { bool m_aborted; public bool IsAborted { get{ return m_aborted; } } // // Summary: // Base CTOR for all derived classes // protected TokenFactoryBase() { } // // Summary: // Creates a TokenDescriptor object for the specified recipient. // // Params: // infoCard: The infocard that the token will be generated from. // credential: The credential object used to autenticate/authorize with a token factory. // policy: Specifies the policy of the relying party or identity provider. // discloseOptional: Specifies whether optional claims are to be disclosed. // public TokenDescriptor CreateToken( InfoCard infoCard, TokenFactoryCredential credential, InfoCardPolicy policy, bool discloseOptional ) { TokenCreationParameter param = null; // // If credentials where provided, and the credential used a param, get the param. // if( null != credential && TokenFactoryCredential.NoCredential != credential.ParameterIndex ) { param = infoCard.CreationParameters[ credential.ParameterIndex ]; } return ProduceToken( infoCard, param, credential, policy, discloseOptional ); } public void Abort() { OnAbort(); m_aborted = true; } // // Summary: // Derived class entrypoint. Implementers must implement this method. // protected abstract TokenDescriptor ProduceToken( InfoCard card, TokenCreationParameter parameters, TokenFactoryCredential credential, InfoCardPolicy policy, bool discloseOptional ); // // Overide when aborting the token creation. // protected virtual void OnAbort() { } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- JpegBitmapEncoder.cs
- BCLDebug.cs
- XmlUtil.cs
- CounterSetInstanceCounterDataSet.cs
- FilteredAttributeCollection.cs
- SHA1Managed.cs
- QueryOperationResponseOfT.cs
- MultiAsyncResult.cs
- MissingMemberException.cs
- LoginNameDesigner.cs
- MenuItemAutomationPeer.cs
- COM2DataTypeToManagedDataTypeConverter.cs
- BatchParser.cs
- StatusCommandUI.cs
- RegistryKey.cs
- VirtualizingPanel.cs
- ResourceDictionaryCollection.cs
- MenuItemBinding.cs
- UnsafeNativeMethods.cs
- TriggerAction.cs
- SocketStream.cs
- TimeIntervalCollection.cs
- IsolatedStorageFileStream.cs
- DbProviderFactories.cs
- XmlSchemaGroup.cs
- RichTextBoxConstants.cs
- OdbcReferenceCollection.cs
- AndCondition.cs
- InstanceKeyCollisionException.cs
- LineServices.cs
- TreeNodeBinding.cs
- JsonObjectDataContract.cs
- EventMappingSettings.cs
- HashStream.cs
- MaterialGroup.cs
- ToolStripHighContrastRenderer.cs
- LastQueryOperator.cs
- SiteMapNodeCollection.cs
- SchemaTableOptionalColumn.cs
- Graphics.cs
- MenuItem.cs
- ListViewPagedDataSource.cs
- VisualStyleTypesAndProperties.cs
- StrokeDescriptor.cs
- PackageFilter.cs
- RealProxy.cs
- NullableLongSumAggregationOperator.cs
- DataGridViewRowHeaderCell.cs
- SuppressMessageAttribute.cs
- StorageMappingItemLoader.cs
- CodeGeneratorOptions.cs
- DataMisalignedException.cs
- FlowDocumentPage.cs
- WebResourceAttribute.cs
- CacheDependency.cs
- LinkConverter.cs
- DesignerEditorPartChrome.cs
- OleDbMetaDataFactory.cs
- Parameter.cs
- Hashtable.cs
- ExpressionPrefixAttribute.cs
- DbModificationClause.cs
- EditorAttribute.cs
- BreadCrumbTextConverter.cs
- EmulateRecognizeCompletedEventArgs.cs
- GroupBoxAutomationPeer.cs
- SocketInformation.cs
- sqlnorm.cs
- PaperSize.cs
- ListDictionaryInternal.cs
- ObjectListItemCollection.cs
- Or.cs
- GridPattern.cs
- GroupDescription.cs
- HttpConfigurationContext.cs
- TypeValidationEventArgs.cs
- SpAudioStreamWrapper.cs
- WebPartConnection.cs
- MailWriter.cs
- MessageQueuePermissionEntry.cs
- DelayDesigner.cs
- HotSpotCollectionEditor.cs
- PassportPrincipal.cs
- SmiEventStream.cs
- SystemBrushes.cs
- CodeVariableReferenceExpression.cs
- RequestContext.cs
- ProfilePropertySettingsCollection.cs
- ServiceProviders.cs
- ConnectionPointGlyph.cs
- DataContractSerializerElement.cs
- LinkButton.cs
- PathSegmentCollection.cs
- SystemIcmpV6Statistics.cs
- PropertyInformation.cs
- PersistenceTypeAttribute.cs
- AppDomainProtocolHandler.cs
- RealProxy.cs
- ArgumentValidation.cs
- StorageMappingItemCollection.cs