secure by default

Designing software so the setting you get by typing nothing is the safe one, and anything riskier must be asked for by name.

In more detail

Defaults do not compete with deadlines, because a default is what happens when nobody has time to think. Make the cautious setting the one you get for free, make the dangerous one an explicit, reviewable option, and refuse to start in production with a known-unsafe override.

Examples

The course inverts unsafe defaults such as debug on and certificate checks off, and adds a startup check that refuses to run in production with an unsafe override.
DEFAULTS = {"debug": False, "verify_tls": True, "allowed_origins": [], "cookie_secure": True}

Related terms

Taught in

References