O'Reilly logo

Professional Visual Basic® 2008 by Bill Sheldon, Kent Sharkey, Bill Evjen, Billy Hollis

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 12. Security in the .NET Framework

This chapter covers the basics of security and cryptography. It begins with a brief discussion of the .NET Framework's security architecture, because this affects all the solutions you may choose to implement.

The .NET Framework provides you with additional tools and functionality with regard to security. You now have the System.Security.Permissions namespace, which enables you to control code access permissions along with role-based and identity permissions. Through your code, you can control access to objects programmatically, as well as receive information on the current permissions of objects. This security framework will assist you in determining whether you have permissions to run your code, instead of getting halfway through execution and having to deal with permission-based exceptions. This chapter covers the following:

  • Concepts and definitions

  • Permissions

  • Roles

  • Principals

  • Code access permissions

  • Role-based permissions

  • Identity permissions

  • Managing permissions and policies

  • Cryptography

Cryptography is the cornerstone of the .NET Web Services security model, so the second half of this chapter discusses the basis of cryptography and how to implement it. Specifically, it covers the following:

  • Hash algorithms

  • SHA

  • MD5

  • Secret key encryption

  • Public key cryptography standard

  • Digital signatures

  • Certification

  • Secure Sockets Layer communications

Let's begin by looking at some security concepts and definitions.

Note

As always, the code for this chapter is available ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required