SafeAI documentation

How-to guides

Short recipes: add devices and Wi-Fi controllers, roll out the agent, find why Wi-Fi is bad, see what changed before an outage, approve a fix, back up and upgrade.

Short recipes for the jobs people do most. Each one links to the full detail in Installation guide or Administrator guide. Menu names are written as the console shows them: Network → Wi-Fi is the Wi-Fi tab of the Network place.

What is here

For Recipes
Setting up Add devices; Add a Cisco IOS / IOS XE router or switch; Add a FortiGate; Add a Palo Alto firewall (preview); Connect AWS, Azure or Google Cloud (preview); Send device logs to SafeAI; Add a remote site with a site collector; Turn on single sign-on; Connect your change system; Set up alerts
Computers Install the SafeAI Agent on computers; Decide where to use the agent; Roll the agent out to many computers; Check the security posture of your computers; Measure what users experience
Wi-Fi and where things are Add a Wi-Fi controller (preview); Find out why someone's Wi-Fi is bad; Find where a device is plugged in
Changes, incidents and approvals See what a change would do before making it; Find what changed before an outage; Approve or reject something that is waiting; Turn on approved fixes and run one; Undo a change from an incident
Security and audits Act on AI readiness; Check a configuration file without connecting to the device; Give an auditor the evidence
Running SafeAI Give an MSP client its own access; Back up, and restore onto a new server; Copy backups off the server; Upgrade, and roll back; Watch SafeAI itself; Install your own certificate; Change the read-only account's password; Replace a device; Get back in after losing the owner's password or phone; Send SafeCadence what support needs; Run with no internet access

To design a deployment before you start, read Design guide (SRND).

Add devices

One at a time: Settings → Devices & accounts → Add device: name, address, platform, site, and the saved account to log in with. SafeAI reads it straight away and shows the result.

Many at once: the same page, Import, with a CSV:

name,address,vendor,site,credential,port,options
core-1,10.0.0.1,cisco-ios,HQ,default,22,
fw-hq,10.0.0.254,fortios,HQ,default,22,
aws-prod,aws-prod,aws,Cloud,aws-audit,443,regions=eu-west-1

Without a list at all: zero-touch discovery scans the private management ranges you give it and adds every device that accepts the read-only account (Zero-touch deployment). Then check Coverage for addresses that answered but couldn't be added, with the reason.

Add a Cisco IOS / IOS XE router or switch

  1. On the device, create the read-only account (privilege 7 can read everything but can't configure): username safeai-observe privilege 7 secret <password> file privilege 7 privilege exec level 7 more If the vty lines have an access-class, allow SafeAI's address.
  2. In SafeAI, save the account (Devices & accounts → Device accounts) and add the device with platform cisco-ios.
  3. Send its logs (below) so changes are seen within seconds, with who made them.

Add a FortiGate

  1. Create a read-only profile and an administrator allowed only from SafeAI's address (deploy/accounts/fortinet-fortios.txt has the full block; set trusthost1 <SafeAI address> 255.255.255.255).
  2. Make sure the interface SafeAI connects to allows SSH (set allowaccess ... ssh).
  3. Add the device with platform fortios. Large FortiGate configurations can take a few minutes to read; the timeout is a setting.

Add a Palo Alto firewall (preview)

  1. Create an administrator with the built-in Superuser (read-only) role and XML API access.
  2. Add the device with platform panos. If its management certificate is self-signed, the first read fails and shows the certificate's fingerprint: add the device option tls_sha256=<fingerprint> and read again.

Connect AWS, Azure or Google Cloud (preview)

Cloud Create Save in SafeAI as Device options
AWS an IAM user with the AWS-managed SecurityAudit policy (or a role to assume) user = access key ID, password = secret key regions=...; role_arn=, external_id=
Azure an app registration with the Reader role user = application (client) ID, password = a client secret tenant=<directory id>, subscriptions=...
Google Cloud a service account with Viewer and Security Reviewer user = service account e-mail, password = its JSON key projects=...

Add a device with platform aws, azure or gcp and a label as its address (for example aws-prod). SafeAI calls only the providers' own API addresses, with list and describe calls.

Send device logs to SafeAI

Directly from the device (the console's Device logs page shows the exact lines for your installation):

! Cisco IOS / IOS XE
logging host <SafeAI address>
archive
 log config
  logging enable
  notify syslog contenttype plaintext
  hidekeys
login on-failure log
login on-success log
# FortiOS: a second syslog destination
config log syslogd2 setting
    set status enable
    set server "<SafeAI address>"
end

pfSense: Status → System Logs → Settings, remote logging to SafeAI with "Everything". OPNsense: System → Settings → Logging, a remote destination.

Through your existing log server: forward to SafeAI (rsyslog: *.* @<SafeAI address>:514) and add the log server under Device logs → Trusted relays, so SafeAI attributes each message to the device that sent it.

Install the SafeAI Agent on computers

  1. Agents → Add computers: choose how long the enrollment code lasts and for how many computers. SafeAI shows one install command per operating system.
  2. Run the command as administrator/root on each computer, or push it with your software-distribution tool. It downloads the agent from your SafeAI, checks it, enrolls and starts the service.
  3. The computer appears under Agents and Devices and reports every 15 minutes, including the AI tools on it.

To let SafeAI apply approved fixes on that computer, its own administrator runs safeai-agent fixes on. SafeAI can't turn that on.

Decide where to use the agent

Network devices are always read without an agent. For computers: read servers SafeAI can reach without it (nothing to install), and put the agent on laptops, desktop PCs and Macs, and on any server where you also want disk forecasts, connections per program or its important events. Wi-Fi, user experience and AI tools are agent-only. The full comparison is in With the agent and without it.

Roll the agent out to many computers

  1. Network → Agents → Add computers: make a code for the number of computers in the first group, valid for the days the rollout will take, and give it the site those computers belong to.
  2. Try the command by hand on one computer of each operating system. It must be run as administrator or root.
  3. Push the same command with the tool you already use (Intune, Group Policy, Jamf, Ansible, your RMM). The agent programs aren't signed by SafeCadence yet, so allow the program in your endpoint protection first.
  4. Watch Agents: each computer appears once it has enrolled, and reports every 15 minutes.
  5. Make a new code for the next site. When the rollout is done, revoke the codes: a code for many computers is as good as a password.
  6. Later versions arrive through Agents → Agent updates: approve one site first, then the rest.

To remove the agent from a computer: safeai-agent uninstall there, or Revoke it on the Agents page.

Add a remote site with a site collector

  1. Install the same bundle at the site as a collector: sudo ./install.sh --collector --seed site.conf, where site.conf holds the site's ranges and read-only accounts.
  2. In the central console, Agents → Site collectors: create an enrollment command for the site and run it on the collector.
  3. The site's devices appear in the central console. Their passwords never leave the site, and secrets are removed there.

Add a Wi-Fi controller (preview)

Settings → Devices & accounts: save the account, then add a device of the kind below. One read later the access points, radios and devices appear on Network → Wi-Fi. All of these are read-only and in preview.

Controller Kind to choose Account to save Options
Cisco Catalyst 9800 Cisco Catalyst 9800 Wi-Fi controller A privilege 15 account (IOS XE requires it for RESTCONF; SafeAI sends only GET). Turn on restconf and ip http secure-server.
Cisco Meraki Cisco Meraki Wi-Fi password = a Dashboard API key with read-only access organization=, network=; one device per Meraki network
HPE Aruba Central HPE Aruba Networking Central Wi-Fi user = API client id; password = {"client_secret": "…", "refresh_token": "…"} api_url= your cluster's gateway; site= or group=
Juniper Mist Juniper Mist Wi-Fi password = an API token with the Observer role site=, org=; api_url= outside the global cloud
FortiGate with FortiAPs FortiGate Wi-Fi controller: FortiAPs password = the token of a read-only REST API administrator, allowed from SafeAI's address vdom=
Ubiquiti UniFi Ubiquiti UniFi a local account with the View Only role site=

A Catalyst 9800 and a FortiGate also have a configuration: add each a second time as Cisco IOS / IOS XE or FortiOS to record its changes. Meraki, Aruba Central and Mist need internet access from SafeAI to the vendor's cloud. Check the first readings against the controller's own screens and tell SafeCadence what differs.

Find out why someone's Wi-Fi is bad

  1. Network → Wi-Fi. Find the person's computer under Each computer. The verdict is Working, Weak spot, Problem or No recent report, with each reason and the reading behind it.
  2. Read the reason. A weak signal says whether the others on the same access point are weak too (the access point's coverage) or fine (that computer's position or adapter).
  3. Press Follow the path. SafeAI walks from the computer's link to its access point's radio, joining, roaming, where the access point is plugged in, the services tested from the computer, and what changed at that site in the last 24 hours. The first step with a problem is where the readings point.
  4. It is a pointer, not a proven cause. To have SafeAI test it, open an incident (Incidents → Incident desk).

If the computer isn't listed, it has no agent or User experience is off. If a step says No data, SafeAI has no reading for it: usually the controller isn't added, or doesn't report that reading. For a phone or scanner, look under Devices, as the access points hear them.

Check the security posture of your computers

  1. Security → Computer posture: one row per server and PC, one column per check. Filter by Windows, macOS, Linux or With a failed check.
  2. What failed, and the evidence lists each failure with the finding behind it. Fix it your usual way; the cell changes at the next report.
  3. No data means SafeAI couldn't see that part (for example BitLocker without administrator rights). It is never a pass.
  4. Download the report for one page to print or send.

Measure what users experience

  1. Network → User experience: an administrator turns it on at the bottom of the page and lists up to 10 services (https:// addresses on port 443; Microsoft 365 sign-in, Outlook and Teams are filled in). Tick Wi-Fi, and Network tests for latency, loss, the path and DNS.
  2. Computers with the agent start testing at their next report.
  3. Where the problem is, at the top, says where a slowdown most likely is: the service, one site's connection, the Wi-Fi there, or the internet provider, named from the path. It is worded as "likely": a reading of measurements, not a diagnosis.
  4. For a site with no computer that is always on, install the agent on a small always-on machine there.

This is monitoring of people's computers: check your privacy rules, and tell your users, before turning it on.

Find where a device is plugged in

Network → On the network: find the device by its name, address or MAC address. SafeAI shows the switch and port it is learned on, the VLAN, the port's description and the switch's location, or for a Wi-Fi device its access point, band and signal. The history shows every move. Good port descriptions and switch locations are what turn "Gi1/0/14" into "2nd floor, desk 14".

Turn on single sign-on

  1. In your identity provider (Entra ID, Okta, Keycloak …), register SafeAI as a web application with redirect URI https://<console address>/auth/sso/callback and a groups claim.
  2. In SafeAI, Single sign-on: the issuer, client ID and secret, and one group per role (owner, administrator, approver, operator, viewer). The highest group a person is in wins.
  3. Keep one local owner as a fallback. To insist on your identity provider's second step, turn on "Refuse sign-ins your identity provider didn't confirm with a second step".

Connect your change system

So planned work isn't flagged as unplanned, on Planned changes:

  • By hand: Add a window (devices or a site, start, end, ticket).
  • ServiceNow: SafeAI reads approved change requests itself with a read-only account (Table API, change_request). A request covers a device when its configuration item or short description names the device.
  • Any other system: create a token that may post planned changes, and have the system call POST /api/v1/planned-changes (Integration and API).

See what a change would do before making it

On a device's page, What if… (or Changes → Checks & what-if): paste the configuration lines, or choose an interface to shut down or a reload. SafeAI works out the effect from the configuration and state it last read, without contacting the device: what stops working, which neighbours are lost, and which computers the agent saw using what would be cut off. If the result is what you want, Request this change sends it for approval. Platforms: Compatibility matrix.

Find what changed before an outage

  • It is happening now: open the incident from the alert or Incidents → Incident desk. SafeAI builds the timeline and tests possible causes against the devices.
  • It already happened, on devices SafeAI reads: Changes → All changes, narrowed to the time and site. Each change shows the lines, who made it (as the device logged it), the problems it introduced and the device's logs from 15 minutes either side.
  • It happened before SafeAI was installed: Incidents → Outage replay. Give each changed device's configuration from before and after (two files from your backups) and one sentence about what broke. SafeAI explains every changed line and what the change took out. A replay is not proof and says so; nothing is stored.
  • A week's summary for a manager or an auditor: Reports → Measurements → Change audit, last 7 days (one page).

Approve or reject something that is waiting

  1. Approvals → Waiting for approval lists every fix, undo and change request waiting, and the number on the menu counts them.
  2. Open one. Who can approve this says whether you can, and if not why (you proposed it, your role, your account is too new), who can approve it now, and how many approvals it still needs.
  3. Read the exact plan, the rollback and what it can affect. Approve it with a change window, or reject it with a reason.

Nobody approves their own proposal. If the page says Nobody can approve this right now, it says what to do about it.

Set up alerts

Alerts: add email, Microsoft Teams, Slack, a webhook, or syslog to your SIEM, then Send a test. You are alerted for changes nobody planned, approved changes that introduced a high-severity problem, devices that can't be read, detected attacks, and SafeAI's own health.

Act on AI readiness

  1. Security → AI readiness shows one score and six categories: what outsiders can reach, hardening, credentials, whether you can see an attack, your own AI agents, and end-of-life software.
  2. Start with Close these first. Each item says exactly what to change, and on which device.
  3. Items marked can prepare have a built-in fix SafeAI can draft for approval (if approved fixes are on). Items marked can be previewed can also be checked with What if… on the device page before anyone makes the change.
  4. Fix the rest your usual way; the score updates at the next read.

Check a configuration file without connecting to the device

Security → Review a file: upload or paste a configuration export. SafeAI gives the same explanations, problems and firewall-rule checks as for a live read, labelled "From an uploaded file, not verified live". For FortiGate and Palo Alto, add a hit-count export to list unused rules. Nothing becomes a device or a change record.

Give an auditor the evidence

  1. Security → Controls: pick the framework (SOC 2, ISO 27001, PCI DSS, NIST CSF, CIS Controls) to see its requirements with the controls behind them.
  2. Export evidence (CSV): every result with its evidence, signed by this SafeAI so the file can be checked later.
  3. Changes → All changes, From/To, Change-control report: every change in the period with how its approval was established.

The export is technical evidence, not a certification of compliance, and the file says so. Your auditor decides what counts.

Turn on approved fixes and run one

  1. An owner turns fixes on: Settings → Fixes (two-person approval is on by default; also turn on fixes.approvals_sso_only).
  2. On a network device, add a write account and name it on the device: option write_credential=<saved account>.
  3. On a device's page, a problem with a built-in fix shows Propose the built-in fix. The fix page shows the exact plan, the rollback and what it can affect.
  4. Someone else approves that plan with a change window. In the window SafeAI applies it, reads the device again itself, and either confirms it or rolls it back.

Undo a change from an incident

  1. Open the incident from the alert (or the Incident desk). SafeAI builds the timeline and tests possible causes.
  2. When a change is the proven cause and all five undo conditions hold, the change page offers Undo this change. If any is missing, SafeAI says which and recommends escalation instead.
  3. A second person approves; SafeAI sends the undo, re-tests the symptom, and keeps the undo only if the service came back. Platforms: Cisco IOS / IOS XE, FRRouting, Nokia SR Linux.

Give an MSP client its own access

  1. Group the client's sites into a client (Reports → Client reports).
  2. Settings → Users: create accounts for the client's people and set Sees to that client (viewer, operator or approver). Or map an identity-provider group to the client under Single sign-on, Client groups.
  3. To have the client approve changes on its own network, tick it under Clients approve their own changes.

Back up, and restore onto a new server

sudo safeaictl key-export /secure/place/safeai-keys.json   # once; keep this file offline
sudo safeaictl backup                                       # a backup now (one is taken every night anyway)
sudo safeaictl verify-backup                                # a restore drill; live data isn't touched

On a new server: install SafeAI, then sudo safeaictl key-import <keys file> and sudo safeaictl restore <backup>. Everyone signs in again afterwards.

Upgrade, and roll back

sha256sum safeai-observe-X.Y.Z.tar          # compare with the value SafeCadence sent you
sudo safeaictl upgrade safeai-observe-X.Y.Z.tar

The upgrade checks the bundle's signature, takes a backup, and goes back on its own if the new version doesn't start within three minutes. To return to the previous version by hand: sudo safeaictl rollback.

Copy backups off the server

Settings → Backups & restore: choose a mounted file share, or another server over SSH (sudo safeaictl backup-copy-key prints the key to add there). New backups are copied within ten minutes. The four tiles on the page say whether you are covered: the last backup, copies off this server, whether the key was exported, and the last restore drill. Press Check for a restore drill.

Watch SafeAI itself

Point your monitoring at https://<console address>/healthz (HTTP 503 when SafeAI has stopped working; ?strict=1 also when a check fails), or set a heartbeat URL under Settings → All settings so your monitoring notices when the posts stop. Settings → SafeAI health shows every check.

Install your own certificate

sudo safeaictl tls-install fullchain.pem key.pem. If your identity provider, ServiceNow or webhooks use an internal certificate authority: sudo safeaictl ca-install ca-bundle.pem.

Change the read-only account's password

Change it on the devices (or in TACACS+ / RADIUS) and, at the same moment, in SafeAI: Settings → Devices & accounts → Device accounts, save the account again. With a site collector, change it in the collector's setup too. Saved passwords are never shown again.

Replace a device

After a replacement or a new SSH key, SafeAI stops reading the device and sends it nothing. Compare the fingerprint on the device's page with the one the device itself shows, and confirm it there. Do this only when you know the device was replaced or re-keyed on purpose.

Get back in after losing the owner's password or phone

On the server: sudo safeaictl reset-admin <username>. It gives a new password, makes the account an owner and resets its two-step sign-in. If single sign-on is on with local sign-in off, it also turns local sign-in back on.

Send SafeCadence what support needs

sudo safeaictl support-bundle writes one file with versions, health, settings and the service log. It contains no passwords, keys, tokens, user accounts or device configurations. Look through it before you send it.

Run with no internet access

Install and upgrade from the signed bundle (it carries Docker too); update vulnerability data from a file (sudo safeaictl vulns-update FILE); point the AI setting at a model on your own network, or leave it off; and point the server's own time sync at your NTP server. SafeAI itself connects out only to what you configure.

These pages are the documentation that ships inside SafeAI 2.9.85.1, the version you download. Something unclear or wrong? Tell us.