Web application security
357 practice items · needed by 20 roles
Easy 101Medium 127Hard 129
Practice questions
- Links that open a new tabeasy
- A secret key in import.meta.enveasy
- A name containing a script tageasy
- Fixing a CORS errormedium
- Where to keep a session tokenmedium
- Secret key with NEXT_PUBLIC_ prefixmedium
- Showing a user commentmedium
- Security of a Server Functionmedium
- Preventing XSS from user HTMLhard
- A CSP that stops injected scriptshard
- CSRF risk left with SameSite=Laxhard
- Unsafe postMessage listenerhard
- onclick stops working after adding CSPhard
- Relying on accept for uploadshard
- Deep merge of user JSONhard
- A user-supplied website linkhard
- Stopping SQL injectioneasy
- How to store passwordseasy
- Keeping secrets out of codeeasy
- Browser blocks a call that curl allowseasy
- What HttpOnly does on a cookieeasy
- Storing times for global userseasy
- What HTTPS leaves visibleeasy
- Database user for the appeasy
- Stack traces in production errorseasy
- What the Secure cookie flag doeseasy
- Why cookie auth needs CSRF thoughteasy
- Building SQL from user inputeasy
- What RabbitMQ vhosts are foreasy
- Logging out with JWTsmedium
- Webhook signature never matchesmedium
- Risk of "import image from URL"medium
- Any user can read any invoicemedium
- Saving req.body directlymedium
- CDN serves one user's profile to anothermedium
- A nested GraphQL query overloads the servermedium
- What SameSite=Lax allowsmedium
- Cookie ignored in an embedded widgetmedium
- Cookie leaks to every subdomainmedium
- Credentialed requests with Allow-Origin *medium
- Why OAuth uses a state parametermedium
- What the __Host- cookie prefix needsmedium
- Data inside a signed cookiemedium
- Logging in with an operator as passwordmedium
- Fail open or fail closedmedium
- JWT verified with an attacker-chosen algorithmhard
- Comparing secrets with ===hard
- Sorting by a user-chosen columnhard
- Deep merge of untrusted JSONhard
- A user subdomain overrides your cookiehard
- Logged in to the attacker's accounthard
- Hash flooding attackshard
- Fixing a CORS erroreasy
- Where to keep a secret keyeasy
- Preventing SQL injectioneasy
- Storing user passwordseasy
- The .env file and Giteasy
- What HttpOnly doeseasy
- What HTTPS protectseasy
- What triggers a preflighteasy
- Caching a bank statement pageeasy
- Stored versus reflected XSSeasy
- Writing location.hash into the pageeasy
- Encoding user text inside HTMLeasy
- What the Secure cookie flag doeseasy
- Purpose of Strict-Transport-Securityeasy
- X-Content-Type-Options: nosniffeasy
- Stopping clickjackingeasy
- Running a shell command with user inputeasy
- Download endpoint reads any fileeasy
- Slowing password guessingeasy
- Why turn on MFAeasy
- Top OWASP web riskeasy
- Login error wordingeasy
- Only validating in the browsereasy
- Known holes in librarieseasy
- Scope of a reporting keyeasy
- A sensible password ruleeasy
- HTTPS page loads an HTTP scripteasy
- Validating a country codeeasy
- SQL error in the API replyeasy
- Folder listing on the web servereasy
- Admin panel with admin/admineasy
- What a password salt stopseasy
- Session left open on a shared PCeasy
- Logout that only clears the cookieeasy
- Delete link using GETeasy
- Bots creating fake accountseasy
- JSON served as text/htmleasy
- Hiding the admin buttoneasy
- Generating a reset tokeneasy
- The S in STRIDEeasy
- SAST compared with DASTeasy
- Secret pushed to a public repoeasy
- Huge JSON body crashes the APIeasy
- Which uploads to accepteasy
- Defence in deptheasy
- Reading a CVSS scoreeasy
- JWT in localStoragemedium
- CSRF with cookie sessionsmedium
- When SameSite=Lax cookies are sentmedium
- Users see each other’s profilemedium
- User bios rendered as HTMLmedium
- Adding security headers to all pagesmedium
- XSS that JSX does not escapemedium
- User data inside a script blockmedium
- How a CSRF token worksmedium
- Double-submit cookiemedium
- Cookie for an embedded widgetmedium
- CORS wildcard and cookiesmedium
- Echoing the Origin headermedium
- MongoDB login bypassmedium
- XML upload reads server filesmedium
- Loading a pickled cookiemedium
- Profile picture uploaded as SVGmedium
- Same session ID after loginmedium
- Choosing a password hashmedium
- Hard lockout after 5 failuresmedium
- Script tag from a public CDNmedium
- Reset token leaks to analyticsmedium
- Request bodies in the logsmedium
- Detailed errors shown to usersmedium
- Reset link built from the Host headermedium
- A regex that freezes the servermedium
- The __Host- cookie prefixmedium
- Session cookie with Domain=.example.commedium
- Old CNAME to a deleted bucketmedium
- Allowing Origin: nullmedium
- What Trusted Types enforcesmedium
- Rolling out a CSP safelymedium
- Rate limit keyed on X-Forwarded-Formedium
- Deeply nested GraphQL querymedium
- Many login attempts in one requestmedium
- Secret key passed as ?api_key=medium
- Chance of guessing a 6-digit OTPmedium
- Entropy of a random tokenmedium
- Template built from user textmedium
- Newlines in a redirect headermedium
- Export opens with a formulamedium
- WebSocket accepts any originmedium
- Sending a token with postMessagemedium
- Token from another service acceptedmedium
- Attacker stays logged inmedium
- Storing card detailsmedium
- What helmet adds to Expressmedium
- Next.js Server Action without a checkmedium
- Serving user-uploaded HTMLmedium
- Private invoice downloads from S3medium
- Valid webhook sent twicemedium
- How long to guess a 4-digit PINmedium
- Package name with one letter offmedium
- Install scripts in CImedium
- Fake lines in the audit logmedium
- Removed admin still has accessmedium
- Refresh token rotationhard
- Module variable holds the current userhard
- JWT algorithm confusionhard
- Redirect check that can be bypassedhard
- Link previews fetch internal URLshard
- Nonce-based CSP trade-offhard
- Comparing secret tokens safelyhard
- Designing password reset linkshard
- Blocking secrets from reaching the clienthard
- Safe data for client componentshard
- CSRF protection for Server Actionshard
- Sanitised HTML changed afterwardshard
- What 'strict-dynamic' allowshard
- CSP that trusts a whole CDNhard
- SSRF check passes, request hits internal IPhard
- Safe URL that redirects insidehard
- Proxy and server disagree on body lengthhard
- CDN caches an attacker's script URLhard
- One-time coupon used five timeshard
- Why public clients use PKCEhard
- OAuth callback without statehard
- Username that attacks laterhard
- Extracting an uploaded ZIPhard
- JWT key chosen by the kid headerhard
- bcrypt and very long inputhard
- Cart accepts negative quantityhard
- Same nonce for every AES-GCM messagehard
- Signing with sha256(secret + message)hard
- Two framing headers disagreehard
- What COOP protectshard
- Different errors for bad paddinghard
- Access check only on the top fieldhard
- Where to keep a pepperhard
- SAML response with two assertionshard
- Lookalike usernamehard
- Duplicate query parametershard
- Profile cached as a .css filehard
- Sandbox with scripts and same-originhard
- Linking accounts by emailhard
- Login is slower for real usershard
- Token with alg set to nonehard
- Origin regex that is too loosehard
- Denylist misses another IP formathard
- Internal package pulled from the public registryhard
- Injected base tag beats a nonce CSPhard
- Invoice PDF renders attacker HTMLhard
- Double charge on retryhard
- Loose redirect_uri matchinghard
- Secret key in the app codeeasy
- HTTP request blocked on iOSeasy
- Blocking screenshots of sensitive screenseasy
- Logging the login requesteasy
- Copying a one-time passwordeasy
- A standard for mobile app securityeasy
- What to clear on logouteasy
- Validation only in the appeasy
- HTTP request blockedeasy
- Refresh token in UserDefaultseasy
- Sharing a PDF with another appmedium
- Checking app integritymedium
- EXPO_PUBLIC variables and secretsmedium
- OAuth login from a mobile appmedium
- Cleartext HTTP fails on Androidmedium
- Trusting a debug proxy only in debugmedium
- What R8 obfuscation gives youmedium
- Encrypting a local databasemedium
- Sensitive data in device backupsmedium
- Deep link sets the payment amountmedium
- Adding a free analytics SDKmedium
- Card number in the app switchermedium
- Refreshing an expired tokenhard
- Decryption fails after new fingerprinthard
- Trusting the phone's clockhard
- Login page inside a WebViewhard
- Detecting a stolen refresh tokenhard
- Relying on jailbreak detectionhard
- Exposing native code to a WebViewhard
- Attacker installs a CA certificatehard
- Overlay tricks the user into tappinghard
- Biometric login that can be bypassedhard
- Reading roles from a JWT in the apphard
- Client reports its own damagehard
- Free gems from fake purchaseshard
- Spot the reentrancy bugmedium
- Using tx.origin for authmedium
- Upgrading a proxy safelymedium
- Overflow in Solidity 0.8medium
- Blind signing on a hardware walletmedium
- Building Sign-In with Ethereummedium
- Relying on the contract balancemedium
- Lending protocol price oraclehard
- Replaying a signed messagehard
- First depositor in a vaulthard
- Reentrancy through a view functionhard
- Paying everyone in a loophard
- delegatecall to user inputhard
- The forgotten implementation contracthard
- Building leaves for a Merkle airdrophard
- A private key in a NEXT_PUBLIC variablehard
- Changing an allowance from 100 to 50hard
- When collateral can be frozenhard
- A lookalike address in the historyhard
- A proposal passed at 3amhard
- The real trust in a bridgehard
- A compromised npm package in a dapphard
- Drained after "just signing a message"hard
- Signing payouts from a backendhard
- A view call that revertshard
- Bricked devices after an updatehard
- NetworkPolicy has no effectmedium
- Looking after the root accounteasy
- The least privilege principleeasy
- Who deleted the bucket?easy
- Where to keep database passwordseasy
- What a key management service doeseasy
- Blocking web attacks at the edgeeasy
- Giving an app on EC2 access to S3medium
- Stopping accidental public bucketsmedium
- Rotating a database password safelymedium
- What HSTS doesmedium
- Deleting an encryption keyhard
- Access keys pushed to a public repohard
- Who is responsible on a managed database?hard
- Deploying from GitHub without stored keyshard
- Thousands of half-open connectionshard
- A domain that breaks only for some usershard
- Risk of TLS 1.3 early datahard
- Removing a rule did not cut the attacker offhard
- Where password hashes are kepteasy
- Safe way to edit sudoerseasy
- Opening HTTPS in ufweasy
- How passwd edits a root-owned filemedium
- Permission denied on an executablemedium
- Permissions fine, nginx still deniedmedium
- Changing sshd_config remotelymedium
- Creating a temp file safelymedium
- Emergency access to productionhard
- Binding port 443 without roothard
- Setuid on a Bash scripthard
- Service writes to /tmp but nothing is therehard
- Read-only file system under systemdhard
- Agent forwarding through a bastionhard
- nginx cannot bind to port 8081hard
- Patched OpenSSL, still vulnerablehard
- Applying a pg_hba.conf changeeasy
- CREATE USER vs CREATE ROLEeasy
- Where roles liveeasy
- Remote clients cannot connecteasy
- Role for a monitoring agenteasy
- Same MySQL user, different hosteasy
- Old client fails to log in to MySQL 8.4easy
- Password file ignored by psqleasy
- Client TLS mode that stops spoofingeasy
- Granting one set of rights to many MySQL userseasy
- Recording who logged ineasy
- Backups that ransomware cannot deletemedium
- Password hashing method to usemedium
- The pg_hba line that never appliesmedium
- Users cannot create tables in publicmedium
- Roles missing after a restoremedium
- Logging who read card datamedium
- Member of a role but no accessmedium
- Encrypting Aadhaar numbers in a columnmedium
- A role that can run COPY FROM PROGRAMhard
- Any user can connect to any databasehard
- Spot the attack in a web logmedium
- SSRF and cloud instance metadatahard
- Keeping tenants apart in RAGmedium
- Running SQL that an LLM wrotemedium
- Injected instructions in a web pagehard
- Data leaking through image linkshard
- A suspicious third-party MCP serverhard
- Why prompt injection is hard to fixhard
- Where API keys belongeasy
- Database password in config.yamleasy
- Loading weights from an unknown sourceeasy
- Spike in injection attemptsmedium
- Loading a model from a public hubhard
- Each manager sees only their regioneasy
- RLS without one role per regionmedium
- Row-level security in Tableaumedium
- A manager sees every regionhard
- Where to keep a database passwordeasy
- Encrypting traffic to brokerseasy
- Only one service may writeeasy
- What the Fernet key protectsmedium
- Joining on email without exposing itmedium
- Phone numbers for some users onlymedium
- Hiding phone numbers from most usersmedium
- Hashing emails is not anonymisinghard
- An API key printed in a task loghard
- Erasing one person from a long loghard
- Passwords in test codeeasy
- Copying production data for testshard
- A security hole is foundmedium
- A "must not" criterioneasy
- Criteria for login lockoutmedium
- Writing an OTP SMSmedium
- Too many OTP requestshard
- Warning before a session times outhard
- Tone for a new-login alerthard
- A login error that leaks informationhard
- Copy for 2FA recovery codeshard