Web Security · Middle · Question 18 of 75

Why should a strict CSP include base-uri 'none' (or 'self')?

Explanation

A <base> tag changes how every relative URL resolves. Restricting it closes a bypass even when nonces are in place.

Further reading

Problem with a question

Web Security · Middle · question 18

Test yourself

Take the Web Security · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz