Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Shared / MS / Internal / securitycriticaldata.cs / 1 / securitycriticaldata.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // Description: // This is a helper class to facilate the storage of Security critical data ( aka "Plutonium") // It's primary purpose is to do put a [SecurityCritical] on all access to the data. // // What is "critical data" ? This is any data created that required an Assert for it's creation. // As an example - the creation of an HwndWrapper during Dispatcher.Attach. // // History: // 10/25/04 : [....] Created. // //--------------------------------------------------------------------------- using System ; using System.Security ; #if WINDOWS_BASE using MS.Internal.WindowsBase; #elif PRESENTATION_CORE using MS.Internal.PresentationCore; #elif PRESENTATIONFRAMEWORK using MS.Internal.PresentationFramework; #elif DRT using MS.Internal.Drt; #else #error Attempt to use FriendAccessAllowedAttribute from an unknown assembly. using MS.Internal.YourAssemblyName; #endif namespace MS.Internal { [FriendAccessAllowed] internal struct SecurityCriticalData{ /// /// Critical - as this accesses _value which is Critical. /// Safe - as the caller already got the critical value. /// [SecurityCritical, SecurityTreatAsSafe] internal SecurityCriticalData(T value) { _value = value; } //// Critical "by definition" - this class is intended only to store critical data. // internal T Value { [SecurityCritical] get { return _value; } } ////// Critical - by definition as this is a wrapper for Critical data. /// [SecurityCritical] private T _value; } } // 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
- DesignerActionHeaderItem.cs
- NonceCache.cs
- Utility.cs
- BasicCellRelation.cs
- cookiecollection.cs
- DurableInstancingOptions.cs
- ExpandCollapseProviderWrapper.cs
- TransactionOptions.cs
- Visual3D.cs
- PathParser.cs
- IMembershipProvider.cs
- ToggleButtonAutomationPeer.cs
- WCFModelStrings.Designer.cs
- DbReferenceCollection.cs
- SchemaImporter.cs
- ResXResourceWriter.cs
- NullEntityWrapper.cs
- LinearGradientBrush.cs
- NamespaceCollection.cs
- Rotation3DKeyFrameCollection.cs
- CodeArrayCreateExpression.cs
- FormViewUpdateEventArgs.cs
- XmlAnyElementAttributes.cs
- DataGridViewRowErrorTextNeededEventArgs.cs
- PenLineJoinValidation.cs
- ExtensionDataObject.cs
- DiagnosticsConfiguration.cs
- CompilerParameters.cs
- FixedTextContainer.cs
- GenerateTemporaryTargetAssembly.cs
- ContentWrapperAttribute.cs
- UnmanagedBitmapWrapper.cs
- Regex.cs
- StylusLogic.cs
- CompositeActivityCodeGenerator.cs
- XmlSchemaImport.cs
- XmlCodeExporter.cs
- Vector3DAnimation.cs
- FileUpload.cs
- HtmlInputSubmit.cs
- PeerServiceMessageContracts.cs
- RowBinding.cs
- FlowDocumentReaderAutomationPeer.cs
- DesigntimeLicenseContext.cs
- SoapAttributes.cs
- PeerApplication.cs
- WebPartManagerInternals.cs
- DictionaryMarkupSerializer.cs
- VerificationException.cs
- NamespaceList.cs
- CodeRemoveEventStatement.cs
- BitmapEffectGroup.cs
- NumberAction.cs
- SqlDependency.cs
- ProbeRequestResponseAsyncResult.cs
- ConfigurationLoader.cs
- OracleConnectionFactory.cs
- DataRowComparer.cs
- AmbientLight.cs
- NativeMethods.cs
- SchemaSetCompiler.cs
- DateTimeOffsetConverter.cs
- SoapObjectInfo.cs
- UriPrefixTable.cs
- WorkflowRuntimeServicesBehavior.cs
- OperatorExpressions.cs
- DependencyPropertyValueSerializer.cs
- BasicBrowserDialog.designer.cs
- BaseUriHelper.cs
- BamlResourceSerializer.cs
- _LocalDataStoreMgr.cs
- DataGridLinkButton.cs
- CapabilitiesRule.cs
- UserControlCodeDomTreeGenerator.cs
- PersonalizableAttribute.cs
- FontDialog.cs
- HttpStreamXmlDictionaryWriter.cs
- LineVisual.cs
- StaticFileHandler.cs
- DefaultBindingPropertyAttribute.cs
- KnownTypesHelper.cs
- DataGridCaption.cs
- UndoManager.cs
- DesignerCatalogPartChrome.cs
- Rectangle.cs
- NoClickablePointException.cs
- TableCellCollection.cs
- UrlMappingsSection.cs
- ConfigurationLockCollection.cs
- ThemeDictionaryExtension.cs
- ToolStripItemTextRenderEventArgs.cs
- IdentityHolder.cs
- CookieParameter.cs
- HtmlForm.cs
- SHA512Managed.cs
- XsdValidatingReader.cs
- WaitHandleCannotBeOpenedException.cs
- InputProcessorProfiles.cs
- mactripleDES.cs
- HttpCacheParams.cs