Practical tools for system, network, security, and operations administrators.

SEC-C0035 · Web & API Security

Web Security for Admins

Set TLS and response headers for a site you run, and use the OWASP list as failures to prevent.

Updated 25 October 2026 · Pillar guide

This is an original planning guide. It is not a vendor manual, an official standard, or legal advice. Example addresses use documentation ranges. Review every command before you paste it.

A site you administer, and the failures you refuse

Web security for an admin is the listener, the certificate, the headers, and the habit of not trusting input. The OWASP list is a set of failure classes: injection, broken access control, misconfiguration, and the rest. This page does not show how to perform those failures. It tells you how to see whether your own site has the boring controls in place.

TLS uses a certificate for a name you control. The certificate guide is the key and the expiry. This page asks whether the public listener is HTTPS and whether plain HTTP redirects to it on purpose. A lab stays on 127.0.0.1 until that decision is made. Do not request a certificate for a name you do not own.

Headers are promises the browser can enforce. A strict transport header belongs on an HTTPS site you mean to keep on HTTPS. A frame header says whether other sites may embed you. A content type header stops a browser from guessing. A content security policy starts in a report mode you can read, then tightens. A header you copy from a sample and do not understand is a header you do not ship.

The header checker and the OWASP checklist generator on this site draft a view of a site you administer or a checklist you will answer. Do not point them at a site you do not run. A checklist with every box ticked and no evidence is a poster.

One lab site, headers you can explain

Use the lab site from the system desk's web guide, bound to loopback. Add one header you can explain, fetch the page, and see the header in the response. Then add the next one. A bundle of ten headers in one reload is ten changes.

The certificate, if the lab has one, is local. The public site gets a certificate only when the name and the DNS are yours. HSTS comes after HTTPS works, not before, and not on a lab name you will abandon.

For the OWASP list, pick one class, such as access control. Write where your site decides who may see a page. If the answer is only the front end, the ticket is to check the server too. You do not need an example payload to know that the server must decide.

Cookies that carry a session are marked for the browser the way your platform documents: sent on HTTPS, not readable by script when they are only a session, and scoped to the site. A cookie flag you cannot define stays off the list until you can.

A change you can finish

Production is the same order: one header or one control, evidence, then the next. The system web guide owns the server reload. This page owns the security decision.

Rollback is the previous header set. You kept the config.

  1. Confirm you administer the site.
  2. Keep the lab on loopback until the public name is a decision.
  3. Add one header, fetch, and read it back.
  4. Hand TLS expiry to the certificate guide.
  5. Answer one OWASP class with an evidence path, not a tick.
  6. Leave report-only content security policy in place until you have read a report.
  7. Do not point the checker at a site you do not run.

Mistakes that outlive the command

web security fails in the same few ways. Each one looks finished on the day you type it. The list is here so the ticket can forbid them before the window, not so you can recognise them in an incident review.

Decisions to write down before the window

One decision for web security: The site in the ticket is one you administer. Headers are added one at a time and read back. HTTPS and the certificate name match the certificate guide. Content security policy starts in a mode that reports, until you have read a report. Each OWASP class you claim has an evidence path. The checker was aimed only at your site. The previous config is the rollback. Cookie flags are ones you can define. The lab listener is loopback. And no exploit material is in the ticket.

The hour you stop

Write the hostname or the system name, the owner, and the clock time before you change anything for web security. If the system is serving people and you do not have a spare, this hour is a plan, not a change. A plan you can read tomorrow is a success. A change you cannot undo is not.

Use a lab or a copy. The log line you test with is one you created, or one you are already allowed to hold. You do not point a tool at a network, a mailbox, or an account you do not administer. The tools on this site run in the browser. They do not log in, and they do not scan.

prompt-for-this is a reminder that a secret is missing. It is not a password, a token, or a key you save. The real secret stays in the password store. If a draft, a log, or a ticket still contains a live secret, stop and rotate it. Then delete the copy.

One change. A firewall, a detection, a DNS record, and a policy do not share a window. If two things move and the outcome is wrong, you will not know which one did it. The rollback is the previous value, written down while the system still works.

A second person reads the scope aloud: which host, which domain, which account. If they cannot find it in the ticket, the ticket is not ready. Silence is not agreement.

Documentation addresses stay in the lab. 192.0.2.0/24, 198.51.100.0/24, and 203.0.113.0/24 are not your production network. example.com is not your domain. Replace them before a real record or a real rule is published.

Do not allow every address because a test failed. A rule, a header, or a detection that matches the world is a draft you delete. Management stays on the prefix you named. A service port opens when the service is ready, for the clients you named.

Keep the previous file. A generator draft is not the previous file. The previous file is what you reload if the new one is wrong. You practised the reload on the lab, with a console or a second session open when the change can lock you out.

If a step fails twice, stop. The failure is the result. Adding a command from a forum beside a half-applied config produces a system nobody can explain. Rebuild the lab from the copy you kept.

When the checks pass, the next system waits until someone else can repeat the proof from the notes. web security is done for this window when the proof is written, not when the tool printed a file.

This page is a planning guide. It is not legal advice, not an audit opinion, not a vendor manual, and not the text of a standard. If a lawyer, an auditor, or a regulator must see the decision, they see the ticket and the evidence, not this paragraph.

Hand the finished note to the neighbouring guide that owns the next step, and leave this system alone until that guide has its own window.

Web security checks before the header set is called done

Confirm this before you call the change done: You administer the host and the name. One new header was seen on a real response. The certificate name matches, or TLS is still the lab. HSTS is absent until HTTPS is the steady state. A content security policy is report-only or explained. One OWASP class has evidence, not only a tick. The checker target is your site. The previous config is saved. Session cookies are scoped on purpose. No payload or exploit notes are in the ticket. A second person can explain the header you added. The server reload followed that server's own test command. The hostname in the prompt matches the hostname in the ticket for web security. The result line includes the time and the person, not only the command. You can point at the rollback value without searching a chat history. And done is a sentence a second person can repeat: the proof for web security happened, and the next host is not started early. If one of those fails, stop.

Tools for this guide

These tools run in the browser on this site. They do not log into your machines.

Guides in this cluster

These supporting pages belong to this pillar.

Companion: System: Web Server Administration Guide.