From the course: Writing Secure Code in iOS by Infosec
Unlock this course with a free trial
Join today to access over 25,300 courses taught by industry experts.
Format string attack, part 3
From the course: Writing Secure Code in iOS by Infosec
Format string attack, part 3
- [Instructor] Format string attack part three. We've talked about format strings. Now what's a format string attack? It's a type of bug, takes advantage of what should be an easily avoidable programmer mistake. Submitted data from an input string is evaluated as a command by the application. You didn't mean for this to happen. It could happen if a vulnerable function accepts a format string from a user. The attacker could use the format string attack to execute code, read the stack, Cause a segmentation fault in the running app, cause some weird new behaviors that compromise the security or the stability of the system. Like for example, going back to print format, print F and C. What if we passed %P %P, and we did it 15 times. 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 times. If we pass that in C to printf printf would be fooled into thinking it has 15 arguments. It would read the next 15 addresses from the stack thinking "Those are my arguments, "I got to read 'em and print…
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
-
-
-
-
(Locked)
Understanding input risks14m 13s
-
(Locked)
Autocorrect and autofill10m 43s
-
(Locked)
Activity: Disabling autocorrection10m 53s
-
(Locked)
Special characters, part 114m 23s
-
Special characters, part 27m 28s
-
(Locked)
Format string attack, part 17m 58s
-
(Locked)
Format string attack, part 28m 38s
-
(Locked)
Format string attack, part 36m 49s
-
(Locked)
Activity: Playing with format strings9m 53s
-
(Locked)
Input sanitization12m 42s
-
(Locked)
Input sanitization techniques: Regular expressions, part 18m 18s
-
(Locked)
Input sanitization techniques: Regular expressions, part 26m 59s
-
(Locked)
Activity: Regular expressions, part 18m 17s
-
(Locked)
Activity: Regular expressions, part 26m 53s
-
(Locked)
Activity: Regular expressions, part 37m 31s
-
(Locked)
Activity: Sanitizing input, part 110m 44s
-
Activity: Sanitizing input, part 213m 45s
-
(Locked)
Property wrappers9m 27s
-
(Locked)
Activity: Trimming whitespace and newlines with a property wrapper6m 38s
-
(Locked)
Activity: Value clamping with a property wrapper6m 48s
-
(Locked)
Activity: Sanitizing input with a property wrapper7m 18s
-
(Locked)
Null bytes7m 27s
-
(Locked)
Cross-site attacks12m 8s
-
(Locked)
Activity: Exploring XSS attacks10m 10s
-
(Locked)
Code injection14m 51s
-
(Locked)
Activity: Filtering a malicious QR code, part 112m 11s
-
(Locked)
Activity: Filtering a malicious QR code, part 25m 31s
-
(Locked)
SQL injection, part 111m 4s
-
(Locked)
SQL injection, part 24m 13s
-
(Locked)
Object deserialization7m 20s
-
(Locked)
Activity: Installing Alamofire and SwiftyJSON pods3m 36s
-
(Locked)
Activity: Securely working with JSON, part 112m 49s
-
(Locked)
Activity: Securely working with JSON, part 29m 23s
-
WebView protection4m 48s
-
(Locked)
Activity: Protecting users against insecure UIWebView10m 44s
-
(Locked)
-
-
-
-
-
-