Most systems distinguish standard users from administrative users — admins can access nearly any file or setting, while standard accounts are limited. That distinction only protects anything if it's actually enforced.
Privilege escalation happens when a standard user is unnecessarily given administrative rights. If an adversary compromises that one account — through any method from earlier units, phishing included — they inherit full administrative access, not just the limited access a standard account should have had.
Weak access control settings create a related but distinct problem: when file and folder permissions are configured too loosely, many users can view or even edit files they have no real reason to touch — widening the pool of accounts an adversary could compromise to reach the same sensitive data.
Many applications take open-ended user input, then use it to query a database using SQL (Structured Query Language). If that input isn't checked against what's actually expected — a process called data validation — an adversary can type SQL commands directly into the input field instead of the data the field expects.
A crafted input like this can trick a poorly-built login query into treating the condition as always true — returning data it shouldn't (a confidentiality breach), or letting the adversary modify or delete database records (an integrity breach).
Websites commonly use JavaScript to create dynamic content — but because that code runs inside the visitor's own browser, it can potentially access sensitive data stored there: usernames, passwords, session tokens. A cross-site scripting (XSS) attack injects malicious code into a website that a victim's browser then executes as if it were legitimate.
User input gets written to a buffer — a fixed-size section of memory reserved for it. If the input is larger than the buffer, the excess spills into adjacent memory it was never meant to occupy.
Web servers store their files in specific directories. When your browser requests a page or image, it sends an HTTP GET request pointing to a file somewhere in that structure. A directory traversal attack manipulates that request to reach files well outside the folder it was supposed to stay in.
A web server stores product images at /var/www/images/. An adversary requests: /var/www/images/../../../etc/passwd