.net security is not an island of generation, but a slice of a bigger entity referred to as the .net Framework. Primary expertise of the .net Framework is required before trying .net security programming. This chapter provides the primary standards of the .net Framework architecture and programming. That is an overview and isn’t always intended to replace the independent examine required for a mastery of this subject.
Microsoft .net is not only a one of a kind spin on the Win32 running version. Furthermore, despite reviews to the opposite, it isn’t always Java in wolf’s garb. You’ll by no means understand or adequately provide an explanation for .net surely by evaluating it to present products. .net is new. As such, .internet introduces a sparkling working modality and perspective on computing software and gadgets.
To help create languages for the .NET Framework, Microsoft created the Common Language Infrastructure specification (CLI). The CLI describes the features that each language must provide in order to use the .NET Framework and comm6n language runtime and to interoperate with components written in other languages. If a language implements the necessary functionality, it is said to be .NET-compliant.
Every .NET-compliant language supports the same data types, uses the same .NET Framework classes, compiles to the same MSIL, and uses a single common language runtime to manage execution. Because of this, every .NET-compliant language is a first-class Microsoft .NET citizen.-Developers are free to choose the best language for a particular component without losing any of the power and freedom of the platform. In addition, components written in one language can easily interoperate with components written in another language. For example, you can write a class in C# that inherits from a base class written in Visual Basic.
The .NET Framework was developed so that it could support a theoretically infinite number of development languages. Currently, more than 20 development languages work with the .NET Framework. C# is the programming language specifically designed for the .NET platform, but C++ and Visual Basic have also been upgraded to fully support the .NET framework. The following are the commonly used languages provided by the Microsoft:
• VC++
• VB.NET
.C#
• J#
JScript .NET
Many third parties are writing compilers for other languages with .NET support. With CLR, Microsoft has adopted a much liberal policy. Microsoft has themselves evolved/ developed/ modified many of their programming languages which compliant with .NET CLR.
VC++
Although Visual C++ (VC++) , has undergone changes to incorporate .NET; yet VC++ also maintains its status being a platform dependent programming. Many new MFC classes have been added a programmer can choose between using MFC and compiling the program into a platform specific executable file; or using .NET framework classes and compile into platform independent MISL file. A programmer can also specify (via directives) whenever he uses “unsafe” (the code that by passes CLR, e.g. the use of pointers) code.
VB.NET
Out of ALL .NET languages, Visual Basic.NET (VB.NET) is one language that has probably undergone into the most of changes. Now VB.NET may be considered a complete Object- Oriented Language (as opposed to its previous “Half Object Based and Half Object Oriented” status).
Visual Basic .NET provides substantial language innovations over previous versions of visual basic. Visual Basic .NET supports inheritance, constructors, polymorphism, constructor overloading, structured exceptions, stricter type checking, free threading, and many other features. There is only one form of assignment: noLet of set methods. New rapid application development (BAD) features, such as XML Designer, Server Explorer, and Web Forms designer, are available in Visual Basic from Visual Studio .NET. With this release, Visual Basic Scripting Edition provides full Visual Basic functionality.
C#
Microsoft has also developed a brand new programming language C# (C Sharp). This language makes full use of .NET. It is a pure object oriented language. A Java programmer may find most aspects of this language which is identical to Java. If you are a new comer to Microsoft Technologies – this language is the easiest way to get on the .NET band wagon. While VC++ and VB enthusiast would stick to VC.NET and VB.NET; they would probably increase their productivity by switching to C#. C# is developed to make full use of all the intricacies of .NET. The learning curve of C# for a Java programmer is minimal. Microsoft has also come up with a The Microsoft Java Language Conversion Assistant-which is a tool that automatically converts existing Java-language source code into C# for developers who want to move their existing applications to the Microsoft .NET Framework.
J#
Microsoft has also developed J# (Java Sharp). C# is similar to Java, but it is not entirely’ identical. It is for this reason that Microsoft has developed J# – the syntax of J# is identical to Visual J++. Microsoft’s growing legal battle with Sun, over Visual J++ – forced Microsoft to discontinue Visual J++. So J# is Microsoft’s indirect continuation of Visual J++. It has been reported that porting a medium sized Visual J++ project, entirely to J# takes only a few days of effort.
JScript.NET
Jscript.NET is rewritten to be fully .NET aware. It includes support for classes, inheritance, types and compilation, and it provides improved performance and productivity features. JScript.NET is also integrated with visual Studio .NET. You can take advantage of any .NET Framework class in JScript .NET.
Comparison of the programming languages
VC#
|
C++
|
VB.Net
|
VC# is a high level language that is component oriented.
|
C++ is a low level and indeed platform neutral programming language.
|
It is a multi-paradigm, object oriented
|
When compiled, C# code is converted into intermediate language code.
|
When compiled, C++ code is converted into assembly language code.
|
Here, sub is used in method declaration to indicate that the method does not return any value.
|
In C# memory management is automatically handled by garbage collector.
|
In C++, the memory that is allocated in the heap dynamically has to be explicitly deleted.
|
The overload keyword is used to indicate an overloaded method.
|
In C# switch statement, test variables can be string.
|
In C++ switch statement, the test variables cannot be a string.
|
Compound data types are declared in VB.Net using structure.
|
While and do while, C# has another flow control statement call for each.
|
C++ does not contain for each statement.
|
Object cleanup can be done by using finalize method in VB.Net.
|
Third-party languages
Microsoft encourages third party vendors to make use of Visual Studio. Net. Third, party vendors can write compilers for different languages ~ that compile the language to MSIL (Microsoft Intermediate Language). These vendors need not develop their own development environment. They can easily use Visual Studio.NET as an IDE for their .NET compliant language. A vendor has already produced COBOL.NET that integrates with Visual Studio.NET and compiles into MSIL. Theoretically it would then be possible to come up with Java compiler that compiles into MSIL, instead of Java Byte code; and uses CLR instead of JVM. However Microsoft has not pursued this due to possible legal action by Sun.
Several third party languages are supporting the .NET platform. These languages include APL, COBOL, Pascal, Eiffel, Haskell, ML, Oberon, Perl, Python, Scheme and Smalltalk.
.net framework architecture
It is not only a package or language. It is called as .NET Environment or platform. At the introduction of .net, it came with several languages like vb .net, C#, COBOL and Perl. Programs developed in Machine level language are converted at the time of executing which is directly executed in the operating system. It is said that it supports 44 languages. These languages, plus other experimental languages like F#, all compile to the common language specification and can work together in the same application.