Appearance
Response protection
These commands configure what Spalto adds to, removes from, and reads in application responses: security headers, the body scope that response inspection reads, and the custom pages shown instead of Spalto's built-in ones.
waap headers get
Prints the header protection settings: value, default, whether set, and range.
sh
waap headers get -app NAME [-json]waap headers set
Changes the header protection settings and rolls them out as a new version. KEY= removes a setting, back to its default. The first set turns header protection on.
sh
waap headers set -app NAME [-m WHY] [-dry-run] KEY=VALUE...Keys:
enabled,modepreset:none,baselineorstrictcsp_reportshsts.enabled,hsts.max_age(8760h is a year),hsts.include_subdomains,hsts.preloadremove_bannersremove: header names, comma-separatederrors.enabled,errors.statuses(5xx,4xx,404, ...),errors.status(keep,500,502,503),errors.skip(paths),errors.capture
sh
waap headers set -app shop -m "baseline headers" preset=baseline hsts.max_age=8760hwaap headers list get
Prints the header entries as YAML.
sh
waap headers list get -app NAME -list LISTwaap headers list set
Replaces the header entries with the records in FILE (YAML or JSON). Each record has name, value, when (missing, always or remove) and content_types. An empty list ([]) removes them.
sh
waap headers list set -app NAME -list LIST -f FILE [-m WHY] [-dry-run]waap headers presets
Lists the built-in presets with their headers, when they apply and to which content types.
sh
waap headers presetswaap headers posture
Shows, per content family (html, json, other):
- the answers counted, and each tracked security header's share of answers with an example value
- what the policy does (added when missing, removed)
- the recommended headers never sent to HTML
- the CSP violation reports: count, directive, blocked origin, page and last seen
Counts are taken on every node while header protection is on, and flushed about every minute.
It then shows the unsafe CORS answers the upstream sent on paths without a CORS rule, from cors.backend.reflect events: path, count, last seen, what was allowed, and the newest event.
sh
waap headers posture -app NAME [-window 7d] [-json]waap response get
Prints the response scope settings.
sh
waap response get -app NAME [-json]waap response set
Changes the response scope as a new version.
sh
waap response set -app NAME [-m WHY] [-dry-run] KEY=VALUE...Keys:
max_body: bytes read at most. Default 1MiB, at most 16MiB.content_types: defaulttext/html, text/plain, text/csv, application/json, application/xml, text/xml, +json, +xml.skip: paths never read.compress: the data plane compresses answers after inspection.
waap pages set
Uses FILE as the custom page of a kind. FILE is read from standard input when it is -. It is HTML, at most 64 KiB. It is rolled out as a new version (policy.block_response.pages).
sh
waap pages set -app NAME -kind KIND -f FILE [-m WHY] [-dry-run]KIND is one of:
blockedrate_limitedunavailableerror: replaces upstream errors.
Placeholders: , , , . Pages may style themselves and show data: images, but they run no scripts.
waap pages reset
Returns the custom page of a kind to the built-in page.
sh
waap pages reset -app NAME -kind KIND [-m WHY] [-dry-run]