Time
7 hours 46 minutes
Difficulty
Intermediate
CEU/CPE
7

Video Transcription

00:01
Hello and welcome back to Siberia's Microsoft Azure Administrator. A Z 103 course. This is Episode 22 storage account access control and I'm your instructor, Will Carlson.
00:12
In today's episode, we're going to discuss access keys and some of the pain points associated with their use and how a shared access signature can help us alleviate some of those concerns but still offers some concerns of its own. And we're going to give a little bit of a nod to something coming up in a future episode
00:31
that will help alleviate the concerns of both of these items.
00:34
To get started, we're gonna jump right back into portal as usual,
00:39
and we're gonna go to the storage account that we've been living in these past few episodes.
00:43
We're gonna click down into that storage account, and we're gonna start our discussion today. Here, under settings access keys.
00:51
Now the text up here at the top of the page. Talk about these access keys as being the keys that you'll use programmatically for your applications to securely authenticate and access and azure storage account. And that's true. That's exactly what they're here for.
01:07
They also figure into shared access signatures that we're gonna talk about in just a minute so they're not your relevant for our discussion if you don't plan on doing any APP development.
01:18
So there are two keys here to facilitate a concept called Key Rolling and Key. Rolling is when if you have this key key, one in an application and it's using that key to access your storage,
01:33
and then let's say there's a compromise. Or maybe you're just being proactive with your security and you want to generate there. You want to install a new key so you don't continue to use the same old key for forever.
01:46
What you can do here because Azure was smart enough to give us two keys, is you take your application and replaced Key one with key to. Then you can click this button here and regenerate key one.
02:00
If we didn't have two keys in that scenario, when we regenerated key one in the amount of time it took us to copy and paste these connections strings and put them into however many applications we had that we're using that key, we would have downtime.
02:14
So the two keys here allows us to key role and change the keys without having any associated downtime with that practice.
02:23
One other thing that I want to mention about keys here is that you should store them in a way that's equivalent to the security you would like to provide for the data that that access KIIS securing these access keys are essentially like SSL certificates or any other encryption mechanism. If you want your data to be scared secure
02:40
and you send your access keys out via email or post them on the public Internet, you're undoing all of the security that you've tried to maintain.
02:50
So by all means, keep your access keys secure.
02:53
Also, keep these access keys in mind as we move on and talk about shared access signatures
02:59
Because shared access signatures are a way that we can provide a U. R I or uniform resource identify rhe. Essentially, this is a girl string that allows you to access a particular item in the storage account directly and to authenticate improve that you have access to that file.
03:20
So remember in our previous example, when we set up the storage account in the Blob in particular, we said that there was no public or anonymous access to our blob storage. So how do you authenticate to that blob storage? Well, you do that by using a shared access signature
03:37
you can come through and set The type of service is that you want this shared access signature to apply to. You can say that we only wanted to apply to objects that are blobs, and we're gonna go ahead and allow this shared access Signature toe have full permissions on those blobs.
03:53
We can also go in and set the date and time both for the start and the expiration of this shared access signature. One thing to keep in mind here is that this applies to a specific time zone. So when you give this to somebody, make sure that's not gonna cause any problems. If you want somebody to have access now,
04:11
it's oftentimes beneficial to go ahead and give access at the beginning of the day so that they can get in right away.
04:17
We also have the ability of here to limit what I P addresses can authenticate using this shared excess signature very similar to the way we did with the storage account firewall.
04:30
We can say we want this, http, or to allow https only. And here again, these keys show up.
04:36
Now, this key being here is important because if we generate a shared access signature with key one and then her normal course of business or because of an event we were to go into access keys and key role and regenerate that key,
04:50
it will absolutely break the shared access signature that's associated with that key.
04:58
So you do have to be careful when you're key rolling. It will break shared access signatures.
05:03
Another thing to be mindful of here with shared excess signatures is going to be that as soon as I click generate,
05:11
I will never be able to get back to these three strings ever again. You have to document them now. You cannot go back and see what they were.
05:20
The last potential gotcha here for shared access signatures is going to be that there is not a real simple way to revoke them.
05:30
Let's say, for example, we wanted to give access to our storage accounts to a temporary contractor, and I gave them access via a shared access signature.
05:39
And let's say we put this in date two years in the future, and that contractor terminated, terminated early at the end of a year. Well, clearly, I don't want him to have access to my storage any longer, but with a shared access signature, there's no way simply to revoke it. We do have a couple of options to revoke it. The 1st 1 would be
05:59
two
06:00
key role, the key that was used for that shared access signature that would respectively revoke the shared access signature, but with some additional costs. Right? It may break some of my applications, and at the very least, I've got to go in and key role all of my applications that use that particular keep.
06:16
I could also go in and delete the storage account or the item that the shared access signature was associated with. So if I associated this with blobs in a storage account, I could delete that blob storage or the storage account completely and then effectively revoke access to the shared excess signature.
06:35
But as you can see, those air both pretty nuclear options, deleting the storage completely or key rolling may affect a whole lot more than just these shared access signatures. So azure gives us another solution in stored access policies, which will cover in the next video when we talk about Storage Explorer.
06:55
So in today's video, we talked about what in storage access key really is why we have to the two of them in Azure and the concept of key rolling.
07:03
We also talked about shared access signatures and how that provides us with U R I to give to somebody to access our storage account. And the shared excess signature gives us more granularity on what we give them access to instead of a full boat access that the access key would give them.
07:21
And we also mentioned some of the limitations of both of these approaches, primarily that there's not a simple way to revoke access when it's handed out with a shared access signature or an access key.
07:35
So coming up in the next video, we're going to talk about a client installed piece of software called Storage Explorer, and we're gonna also touch on the concept of excess policies that help us alleviate some of the concerns we had with the access control methods discussed today.
07:55
Thanks for joining me today for this episode. I'm looking forward to the next one

Up Next

AZ-103 Microsoft Azure Administrator

This is a training course for the Microsoft Azure AZ-103 Certification. The Microsoft Azure Administrator training course teaches students to perform tasks like managing Azure subscriptions and resources, implementing and managing storage, deploying and managing virtual machines (VM) and networks, and managing identities!

Instructed By

Instructor Profile Image
Will Carlson
Director of IT and Cybersecurity
Senior Instructor