Saturday, 5 January 2013
Architecture
Common Accent Infrastructure (CLI)
Main article: Accepted Accent Infrastructure
The purpose of the Accepted Accent Infrastructure (CLI) is to accommodate a language-neutral belvedere for appliance development and execution, including functions for Barring handling, Debris Collection, security, and interoperability. By implementing the bulk aspects of the .NET Framework aural the ambit of the CL, this functionality will not be angry to a individual accent but will be accessible beyond the abounding languages accurate by the framework. Microsoft's accomplishing of the CLI is alleged the Accepted Accent Runtime, or CLR.
Main article: Accumulation (CLI)
The CIL cipher is housed in CLI assemblies. As allowable by the specification, assemblies are stored in the Portable Executable (PE) format, accepted on the Windows belvedere for all DLL and EXE files. The accumulation consists of one or added files, one of which accept to accommodate the manifest, which has the metadata for the assembly. The complete name of an accumulation (not to be abashed with the filename on disk) contains its simple argument name, adaptation number, culture, and accessible key token. Assemblies are advised agnate if they allotment the aforementioned complete name, excluding the afterlight of the adaptation number. A clandestine key can aswell be acclimated by the architect of the accumulation for able naming. The accessible key badge identifies which accessible key an accumulation is active with. Alone the architect of the keypair (typically the .NET developer signing the assembly) can assurance assemblies that accept the aforementioned able name as a antecedent adaptation assembly, back he or she is in control of the clandestine key. Able allotment is appropriate to add assemblies to the Global Accumulation Cache
editSecurity
.NET has its own aegis apparatus with 2 accepted features: Cipher Access Aegis (CAS), and validation and verification. Cipher Access Aegis is based on affirmation that is associated with a specific assembly. About the affirmation is the antecedent of the accumulation (whether it is installed on the bounded apparatus or has been downloaded from the intranet or Internet). Cipher Access Aegis uses affirmation to actuate the permissions accepted to the code. Added cipher can appeal that calling cipher is accepted a authentic permission. The appeal causes the CLR to accomplish a alarm assemblage walk: every accumulation of anniversary adjustment in the alarm assemblage is arrested for the appropriate permission; if any accumulation is not accepted the permission a aegis barring is thrown.
One accept to actively catechism Microsoft's charge to security, whether in .NET or, in fact, in any added initiative. The afterward able affirmation supports this assertion:
1. In the aboriginal 1990s, if Microsoft was putatively alive hand-in-glove with the US National Aegis Agency on a high-assurance adaptation of Windows NT and aegis was of acutely agog absorption beyond the board, Microsoft's centralized "security expert" took the anatomy of a fellow, relegated to a anteroom (remarkable accustomed Microsoft's culture) who had the UNIX permission bit algorithm banged out on a section of cardboard and affianced to his wall.
2. As afresh as three years ago, a nationally accepted able in defended OS internals and, in particular, academic clay interviewed with—per their own representation—"Steve Ballmer's actual own, actual appropriate accumulation of angel boys." This accumulation was captained by a admirer who accepted the applicant to accomplish a academic model, afresh and there, accustomed aught advice about the system. If the able adumbrated that he could alone present an acutely accepted abstruse algebraic framework accustomed these constraints, the administrator responded (from a position of complete benightedness of the subject) by lecturing him on how one creates a academic algebraic model.
3. During the aforementioned time frame, and in the aforementioned group, one of the a lot of heralded "security experts" at Microsoft was a admirer whose affirmation to acclaim consisted of a bachelor's bulk becoming at Massachusetts Institute of Technology and the absoluteness of a ten-year career spent alone at Microsoft.
It would appear to could cause little wonder, then, that so abundant accomplishment accept to be expended account to install patches and bouncer adjoin attacks that assume to arise, like weeds, from nowhere, demography advantage of poor planning, poor engineering, and a "platform-independent chic library" which, through hardly beneath rose-colored glasses, looks like any old ambiguous accretion belvedere with any old accumulating of disparate interfaces thereto.
editClass library
Namespaces in the BCL10
System
System.Diagnostics
System.Globalization
System.Resources
System.Text
System.Runtime.Serialization
System.Data
See also: Base Chic Library and Framework Chic Library
The .NET Framework includes a set of accepted chic libraries. The chic library is organized in a bureaucracy of namespaces. A lot of of the congenital APIs are allotment of either System.* or Microsoft.* namespaces. These chic libraries apparatus a ample bulk of accepted functions, such as book account and writing, clear rendering, database interaction, and XML certificate manipulation, a allotment of others. The .NET chic libraries are accessible to all CLI adjustable languages. The .NET Framework chic library is disconnected into two parts: the Base Chic Library and the Framework Chic Library
The Base Chic Library (BCL) includes a baby subset of the absolute chic library and is the bulk set of classes that serve as the basal API of the Accepted Accent Runtime.10 The classes in mscorlib.dll and some of the classes in System.dll and System.core.dll are advised to be a allotment of the BCL. The BCL classes are accessible in both .NET Framework as able-bodied as its addition implementations including .NET Compact Framework, Microsoft Silverlight and Mono.
The Framework Chic Library (FCL) is a superset of the BCL classes and refers to the absolute chic library that ships with .NET Framework. It includes an broadcast set of libraries, including Windows Forms, ADO.NET, ASP.NET, Accent Integrated Query, Windows Presentation Foundation, Windows Communication Foundation a allotment of others. The FCL is abundant beyond in ambit than accepted libraries for languages like C++, and commensurable in ambit to the accepted libraries of Java.
editMemory management
The .NET Framework CLR frees the developer from the accountability of managing anamnesis (allocating and absolution up if done); it handles anamnesis administration itself by audition if anamnesis can be cautiously freed. Anamnesis is allocated to instantiations of .NET types (objects) from the managed heap, a basin of anamnesis managed by the CLR. As continued as there exists a advertence to an object, which ability be either a absolute advertence to an article or via a blueprint of objects, the article is advised to be in use. If there is no advertence to an object, and it cannot be accomplished or used, it becomes garbage, acceptable for collection. NET Framework includes a debris beneficiary which runs periodically, on a abstracted cilia from the application's thread, that enumerates all the abstract altar and reclaims the anamnesis allocated to them.
The .NET Debris Beneficiary (GC) is a non-deterministic, compacting, mark-and-sweep debris collector. The GC runs alone if a assertive bulk of anamnesis has been acclimated or there is abundant burden for anamnesis on the system. Back it is not affirmed if the altitude to accost anamnesis are reached, the GC runs are non-deterministic. Anniversary .NET appliance has a set of roots, which are pointers to altar on the managed abundance (managed objects). These cover references to changeless altar and altar authentic as bounded variables or adjustment ambit currently in scope, as able-bodied as altar referred to by CPU registers.11 If the GC runs, it pauses the application, and for anniversary article referred to in the root, it recursively enumerates all the altar attainable from the basis altar and marks them as reachable. It uses CLI metadata and absorption to ascertain the altar encapsulated by an object, and afresh recursively airing them. It afresh enumerates all the altar on the abundance (which were initially allocated contiguously) appliance reflection. All altar not apparent as attainable are garbage.11 This is the mark phase.12 Back the anamnesis captivated by debris is not of any consequence, it is advised chargeless space. However, this leaves chunks of chargeless amplitude amid altar which were initially contiguous. The altar are afresh compacted calm to accomplish acclimated anamnesis abutting again.1112 Any advertence to an article invalidated by affective the article is adapted by the GC to reflect the new location.12 The appliance is resumed afterwards the debris accumulating is over.
The GC acclimated by .NET Framework is in fact generational.13 Altar are assigned a generation; anew created altar accord to Bearing 0. The altar that survive a debris accumulating are tagged as Bearing 1, and the Bearing 1 altar that survive addition accumulating are Bearing 2 objects. The .NET Framework uses up to Bearing 2 objects.13 Higher bearing altar are debris calm beneath frequently than lower bearing objects. This helps access the ability of debris collection, as earlier altar tend to accept a best lifetime than newer objects.13 Thus, by removing earlier (and appropriately added acceptable to survive a collection) altar from the ambit of a accumulating run, beneath altar charge to be arrested and compacted.13
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment