Тёмный

Stop Putting Your Asp.Net Core Secrets at Risk - Use Azure Key Vault! 

Codewrinkles
Подписаться 28 тыс.
Просмотров 9 тыс.
50% 1

Опубликовано:

 

10 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 66   
@abuuthmaan
@abuuthmaan 4 месяца назад
You're the man, Dan! This is the best tutorial on the topic I've found.
@PatGarvey
@PatGarvey Год назад
Three hours to find this videos. !5 minutes to get things to work. Excellent!
@Codewrinkles
@Codewrinkles Год назад
In the end, I'd say it's a success! I'm glad it was helpful. Make sure to subscribe, so that you don't spend other 3 hours searching for stuff you might find here :)
@343GuiItySpark
@343GuiItySpark Год назад
exactly. As a fresher, helped a lot. now manager won't shout at me 😉
@Thecodemagic
@Thecodemagic 26 дней назад
Thanks @Codewrinkles. The way you explained is fire. 🔥..you eared a new subscriber.
@androidsavior
@androidsavior 5 месяцев назад
So if i sign out of Azure from the web on my pc, the key-vault will stop working in the C# code ? What if i host my application on-premise ? should i signin to azure form the server to get it authenticate the key-vault in my C# code ?
@goranmaric6806
@goranmaric6806 Год назад
Excellent video, indeed. Thanks! I would like to suggest that it could be beneficial to mention the order in which the secrets are added to the configuration object. Based on my experience using this configuration, it appears that secrets are loaded from KeyVault at the end. Therefore, if there is a configuration key with the same name as a secret in KeyVault within the Azure App Service, the value from KeyVault will be present in the configuration object at the end.
@Codewrinkles
@Codewrinkles Год назад
Thank you for watching. I have talked in dept about the order of configuration keys and how this might brake our apps in the video about configurations that I also mentioned in this one: ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-5TxnLU-SXVg.html Also with practical demos to show how things happen.
@19balazs86
@19balazs86 Год назад
This video could be on the Microsoft Learn page by default. Easier and better to understand the KeyVault, than other learning materials.
@Codewrinkles
@Codewrinkles Год назад
Thank you for the kind words. Feel then free to share it wherever you can. That would probably help a lot of people.
@nove1398
@nove1398 Год назад
I feel the same here
@Codewrinkles
@Codewrinkles Год назад
@@nove1398 Same goes for you. Feel free to share it wherever you think there are people that would find in useful: at work, friends, social media, forums. That would be highly appreciated.
@isrukhasan8504
@isrukhasan8504 Год назад
This is one of the best. Clear and precise. Good job ! Love from Bangladesh
@Codewrinkles
@Codewrinkles Год назад
Thanks for watching. Love back from Romania!
@kojoagyemang4169
@kojoagyemang4169 Год назад
Really useful and simple. Can't like it enough
@androidsavior
@androidsavior 5 месяцев назад
the developer will be able to debug the code and inspect the connection string and the secrets after they are returned from azure ? So we're just hiding the secretes from viruses and cyber attacks ?
@343GuiItySpark
@343GuiItySpark Год назад
you just got a new subscriber. And I dont usually subscribe to anyone to keep my yt feed cleaner. Many thanks .
@Codewrinkles
@Codewrinkles Год назад
Thanks for the sub! I really appreciate it. Hope to not disappoint in the future :)
@jadhavvishal89
@jadhavvishal89 Год назад
Always waiting for your new videos, it's really help me and encourage me to learn and use concept with new way. Thank you very much.
@Codewrinkles
@Codewrinkles Год назад
Happy to hear that! Thank you for watching.
@zaharivaklinov
@zaharivaklinov Год назад
Short, clear and concise. If only this had been uploaded back in December. Nevertheless, I will be using it from now on (:
@Codewrinkles
@Codewrinkles Год назад
Glad you liked the video.
@ravindranaths513
@ravindranaths513 4 дня назад
In Azure, how can we link one service-bus topic to another topic?
@viktorasmickunas2527
@viktorasmickunas2527 Год назад
A very useful and much needed video. Thank you.
@androidsavior
@androidsavior 5 месяцев назад
Thank you very much, it will try it soon
@Liboterac
@Liboterac Год назад
Bro u are fking awesome! Thank you for this. Clear, on spot, nice examples....
@Codewrinkles
@Codewrinkles Год назад
Glad you found it useful. Thanks for watching!
@bouthaynahamdi707
@bouthaynahamdi707 4 месяца назад
very helpful. does it work if the app service is container base?
@hackneythugg
@hackneythugg Год назад
Sure, here's the edited version of the RU-vid comment: Great video! I have a question: When you create an enabled identity on the web app and then create the access policy so that the application can access it, do you need to make any code changes? From what I saw in the video, it didn't seem like you had to change any code. So, does the Azure Default Identity work when the application is running in Azure? So no code changes are required?
@Codewrinkles
@Codewrinkles Год назад
If you use the system assigned managed identity, then no change should be required in the code. If you use a user assigned managed identity, then you need to provide the Object identifier for that identity either in code or as an environment variable.
@HungTran-jx2xc
@HungTran-jx2xc Год назад
how is the cost would increase since we retrieve the connection string directly from Azure Key Vault ?
@Codewrinkles
@Codewrinkles Год назад
What cost exactly? Bot the Azure webapp and the KeyVault reside inside Azure, in the same region. So, I wouldn't be too worried about that in terms of network latency.
@AhmedMohammed23
@AhmedMohammed23 Год назад
my man where were you hiding great content overall thanks
@Codewrinkles
@Codewrinkles Год назад
Appreciate it! More to come!
@xelaksal6690
@xelaksal6690 Год назад
Thanks for very clear explanation!
@Codewrinkles
@Codewrinkles Год назад
You are welcome!
@NazarYuras
@NazarYuras Год назад
Thank you very much!
@Codewrinkles
@Codewrinkles Год назад
Glad you enjoyed it. Thanks for watching.
@jadhavvishal89
@jadhavvishal89 Год назад
Awesome video @codewrincles, you explain how to use key vault concept very simple way. I gone through lots of documents, but your 16 min video help me to clear my most of the doubts. Thanks. Could you please cover azure function with real time scenario. Like input and output bindings.
@Codewrinkles
@Codewrinkles Год назад
I'm glad the video was useful to you. I will for sure cover also Azure Functions, probably in a lot of videos. I'm just getting the Azure series started. That's the 4th video only :)
@alboshajdari6871
@alboshajdari6871 Год назад
AddAzureKeyVault is now updated and now requiring different arguments: (string vault, string clientId, string clientSecret) But why do I need to manually give clientId and clientSecret when I already have valid credentials through DefaultAzureCredential(); ?
@Codewrinkles
@Codewrinkles Год назад
TBH, I'm not sure about this change. This video is not that old. I will investigate. But it seems very odd to me.
@alboshajdari6871
@alboshajdari6871 Год назад
@@Codewrinkles I found a solution, I was able to do it with this code here: string keyVaultUrl = builder.Configuration.GetSection("KeyVaultUrl").Value!; var azureServiceTokenProvider = new AzureServiceTokenProvider(); var keyVaultClient = new KeyVaultClient(new KeyVaultClient.AuthenticationCallback(azureServiceTokenProvider.KeyVaultTokenCallback)); builder.Configuration.AddAzureKeyVault(keyVaultUrl, keyVaultClient, new DefaultKeyVaultSecretManager());
@pylvr8021
@pylvr8021 Год назад
any updates on this, could you tell from what packages its comes from, i did not find it anywhere @@Codewrinkles
@codeme8016
@codeme8016 5 месяцев назад
Wonderful
@asdasdaa7063
@asdasdaa7063 7 месяцев назад
what about Cache the secrets? the way you did it now you'd have to pay for every read operation on a secret. You need to Cache the secrets and reuse from memory whenever possible right?
@Codewrinkles
@Codewrinkles 7 месяцев назад
That sounds like a valid point and idea.
@brianalessi2673
@brianalessi2673 Год назад
Create video, this was very informative! We just implanted this with success, but we also noticed that it takes about 12 seconds to retrieve just one secret. Has anyone noticed this or discovered workaround(s)?
@Codewrinkles
@Codewrinkles Год назад
I assume there's a networking problem somewhere. Retrieving secrets is and should be very fast.
@dailylearning1706
@dailylearning1706 Год назад
Excellent job, thank you. But can you make a video like this with Terraform? I mean, by using Terraform to create the key vault, the secret inside the key vault and then access the secret from the secret vault with Terraform and Azurerm provider. Thank you in advance.
@Codewrinkles
@Codewrinkles Год назад
Thanks for the idea! I guess infrastructure as code topics is something that I'll cover sooner rather than later.
@RoyZASTEROiD
@RoyZASTEROiD Год назад
thanks
@Codewrinkles
@Codewrinkles Год назад
You're welcome!
@loadiam
@loadiam Год назад
Simple and helpful!
@Codewrinkles
@Codewrinkles Год назад
Glad you enjoyed it.
@PROFDAILY
@PROFDAILY Год назад
Great Work, what happens if you deploy to different environments(dev, QA and Prod), your vault will have different secrets, how do you then update you Program.cs to read different secret based on the environment?
@Codewrinkles
@Codewrinkles Год назад
First of, you just create the needed secrets for each environment. In your app you than use the secrets based on the environment you are currently in. You'll have to create 3 managed identities for each of the web apps and assign permissions. An alternative here would be to create one user assigned managed identity and use it for all the environments. This would actually be a scenario where a user assigned managed identity would make sense.
@flo187de
@flo187de Год назад
@@Codewrinkles I've used a separate keyvault for each environment. that way I only have to change they keyvault url in appsettings. any downsides to that?
@Codewrinkles
@Codewrinkles Год назад
I wouldn't say it's a problem or downside, but companies tend to usually have more consolidated key vaults, as they would contain keys, secrets and certificates used throughout all the Azure resources.
@PROFDAILY
@PROFDAILY Год назад
@@Codewrinkles that makes sense
@mustafaaltnok3250
@mustafaaltnok3250 Год назад
Thanks for the video, What about azure keyvault- azure kubernetes integration?
@SinanNAR
@SinanNAR Год назад
What is the difference between system generated and user generated managed identity? Also could you please cover app configuration with keyvault together for next topic?
@Codewrinkles
@Codewrinkles Год назад
I explained the difference in the video. Maybe you have skipped that part :)
@sauravbhatta5303
@sauravbhatta5303 Год назад
Good content. You should also start producing content for Azure service fabric, function and service bus Have u also looked into Azure app configuration?
@Codewrinkles
@Codewrinkles Год назад
I have just started the Azure videos on this channel. I'll get probably in most of the topicsyou mentioned. Thank you for watching and commenting!
@AnsisPlepis
@AnsisPlepis Год назад
14:20 Theres nothing wrong with your face :)
Далее
Async Messaging With Azure Storage Queues
14:17
Просмотров 2,1 тыс.
Azure Logging for Asp.Net Core Developers
16:50
Просмотров 8 тыс.
BeastMasters Hawk just had enough #ti13
00:30
Просмотров 291 тыс.
The Best Way to Add Health Checks in Any .NET App
12:31
How To Add Google Authentication To Blazor SSR
24:23
Просмотров 3,7 тыс.
Stop using the HttpClient the wrong way in .NET
10:14
Просмотров 191 тыс.
What Is .NET Aspire? The Insane Future of .NET!
18:35
Просмотров 269 тыс.
The RIGHT Way To Use HttpClient In .NET
11:46
Просмотров 57 тыс.