User security is perhaps one of the most critical aspects of a system and, therefore, its architecture. Security has, of course, always been important to protect sensitive information within an organization. However, as we move our applications online and widen our audience, the need to ensure only the correct people gain access to their data has become crucial.
In this chapter, we explore the key differences between authentication and authorization, what tooling we have available within Azure to ensure the safety of user accounts, and how we design solutions according to different business needs.
In this chapter, we will examine the following topics:
- Differentiating authentication from authorization
- Introducing Active Directory (AD)
- Integrating AD
- Understanding Conditional Access (CA), Multi-Factor Authentication (MFA), and security defaults
- Using external identities
Differentiating authentication from authorization
A significant and essential role of any platform is that of authentication and authorization. These two terms are often confused and combined as a single entity. When understanding security on platforms such as Azure, it’s vital to know how the different technologies are used.
Authentication is the act of proving who you are, often performed with a username/password combination. If you can provide the correct details, a system authenticates you.
Authentication does not give you access to anything; it merely proves who you are.
Once a system knows the who, it then checks to see what you have access to—this is termed authorization.
In Azure, authorization is the act of checking whether you have access to a particular resource such as a storage account, and what actions you can perform, such as creating, deleting, modifying, or even reading the data in the storage account.
Because of the number of different services and their associated actions that are available to a user in Azure, and the importance of ensuring the validity of a user, the ensuing mechanisms that control all this can become quite complicated.
Luckily, Azure provides a range of services, broken down into authentication and authorization services, that enable you to strictly control how users authenticate and what they can then access, in a very granular way.
Traditionally, authentication has been via simple username/password combinations; however, this is ineffective on its own, and therefore you need to consider many factors and strategies when designing an authentication mechanism. For example, the following scenarios may apply:
- A user may choose too simple a password, increasing the chances of it being compromised.
- Complex passwords or regular changes mean users are more likely to forget their password.
- There may be delays in the authentication process if a user needs to call a helpdesk to request a password reset.
- A username/password combination itself is open to phishing attacks.
- Password databases can be compromised.
Important note
A phishing attack is an action whereby a malicious person will attempt to steal your password by sending you to a dummy website that looks like the one you want to access but is, in fact, their site. You enter your details, thinking it is the correct site, and now they have your personal information and can then use this to log in to the real site.
When systems are hosted on a physically isolated network, some of these issues are mitigated as you first need physical access to a building or at least a device set up with a virtual private network (VPN) connection that, in turn, would require a certificate.
However, in cloud scenarios, and especially hybrid systems, whereby you need external authentication mechanisms that must also map or sync to internal systems, this physical firewall cannot always be achieved.
With these scenarios in mind, we need to consider how we might address the following:
- Managing and enforcing password complexity rules
- Providing additional layers over and above a password
- How to securely store and protect passwords
Now that we understand some of the issues we face with authentication systems, especially those that rely on username/password combinations, we can investigate what options are available to mitigate them. First, we will examine Microsoft’s established security platform, AD.