From the course: Security in ASP.NET Core
Unlock this course with a free trial
Join today to access over 24,800 courses taught by industry experts.
Fixing SQL injection - ASP.NET Tutorial
From the course: Security in ASP.NET Core
Fixing SQL injection
- [Instructor] You may be shocked, (chuckles) but yes indeed, our h+ board application is vulnerable to SQL injection. However, I had to work really hard to actually add that vulnerability to the code. There are different ways of showcasing that. Let me show you something relatively subtle and for that, I first create a second order. So how about some mineral water to get hydrated and remain hydrated? Okay, $5 and 60 cents. Fair enough. I sent the order. The order number is nine. Now if you go to our secret AdminOrders page, which you've seen before, you'll see now that we have two orders. Let's open the first order I did. Order number eight, with a total amount of $90 and that eight, that value eight, that's part of the URL and is then processed by the action method. However, the processing turns out to be not really good. The AdminOrder action method expects a string as an argument, which is a bit weird, since our IDs are integers. And then there's some really creative code, I'm…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
OWASP Top Ten2m 45s
-
(Locked)
Cross-site scripting (XSS): The attack4m 33s
-
(Locked)
Cross-site scripting (XSS): The defense3m 25s
-
(Locked)
Cross-site scripting (XSS) in JavaScript4m 40s
-
(Locked)
Cross-site scripting (XSS) in single-page applications3m 30s
-
(Locked)
Same-origin policy and CORS4m 26s
-
(Locked)
Enabling CORS in ASP.NET Core web API6m 23s
-
(Locked)
SQL injection with ADO.NET2m 25s
-
(Locked)
SQL injection with Entity Framework Core2m 34s
-
(Locked)
Fixing SQL injection5m 23s
-
(Locked)
Cross-Site Request Forgery (CSRF): The attack5m 25s
-
(Locked)
Cross-Site Request Forgery (CSRF): The defense7m 11s
-
-
-
-
-