Behavior rules

Alerts on logins and admin actions that happen outside your working hours, or from outside the countries your team works from. You set the hours and the countries.

Free 14-Day Trial
**No credit card required.

One alert, one log line

An SSH login as root at 02:14 Los Angeles time, from an address outside the United States and Canada. Part of the email it sends, with "..." where we cut lines:

Subject: Trunc Alert: Behavior: Root login outside working hours, from outside your business countries
...
Alert description: Someone logged in over SSH as root outside your working hours. A successful login from an IPv4 address outside your business countries.
...
Rules: Login outside working hours; root or sudo outside working hours; Login from outside your business countries
User: root
Host: web01
Source: 198.51.100.23 (NL)
Processed: Thu 2026-11-19 02:14 PST (America/Los_Angeles)

Nov 19 10:14:07 web01 sshd[48211]: Accepted password for root from 198.51.100.23 port 40122 ssh2
...

When one login is both off-hours and from outside your countries, you get one alert with both in the title. Processed is the time we used, in your time zone. Slack gets the same title, the host and the log line.

Every rule with its log lines

What it alerts on

These six rules run today.

The six behavior rules that run today, what each one fires on and the alert title it sends
Rule Fires on Alert title
Login outside working hours A successful login: SSH, Windows console or RDP, WordPress, Azure, SharePoint, GlobalProtect, Meraki VPN, FortiGate admin. Windows unlock and IMAP/POP mail if you turn them on. Behavior: Login outside working hours
Desktop login outside working hours Windows logon type 2 or 11, someone at the console Behavior: Desktop login outside working hours
root or sudo outside working hours SSH login as root, sudo that ran a command as root, su to root, a Windows console or RDP logon as Administrator or with an elevated token Behavior: Root login outside working hoursBehavior: sudo outside working hoursBehavior: su to root outside working hoursBehavior: Admin login outside working hours
User added outside working hours useradd, Windows 4720, a new Azure AD user, a user created through the Linode API Behavior: User added outside working hours
New service outside working hours Windows event 7045 (Defender updates left out) Behavior: New service outside working hours
Login from outside your business countries A successful login from an IPv4 address in a country that isn't on your list, at any hour Behavior: Login from outside your business countries

The same settings page also has alerts for logins from Tor, commercial VPNs and datacenter networks. Those come from Security Insights and run at any hour.

Coming soon

These are planned and don't fire yet.

  • Login from a new country for that user
  • Implausible country change
  • Password spraying
  • Dormant account logged in
  • First login to a host
  • USB storage outside working hours
  • Server restart outside working hours
  • Desktop turned on outside working hours
  • Security settings changed outside working hours
  • New scheduled task outside working hours
  • Crontab changed outside working hours

What you set

Two things:

Working hours

One range per day in 15-minute steps, in your account time zone. The default is Monday to Friday, 06:00-21:00. An end time before the start runs past midnight. Add holidays by hand, or add US federal or UK bank holidays in one click.

Trunc Working hours settings: Monday to Friday 06:00 to 21:00, Saturday and Sunday off

Business countries

Pick them from a list. A login from anywhere else alerts at any hour.

Trunc Business countries picker with United States and Canada selected

Then tick which rules go to which email address or Slack channel. Nothing alerts until you do.

Quiet by default

  • Every rule is off until you tick it for an email address or Slack channel.
  • One alert per rule, user and host per hour. 40 sudo commands from alice at midnight is one email.
  • 20 behavior alerts an hour, then one summary with a count per rule. The rest are still stored and searchable.
  • Ignore lists for users, hosts (bastion*) and source IPs (192.0.2.0/28).
  • Windows unlock and IMAP/POP mail logins are off by default. Network logons (type 3) and Kerberos tickets (4769) never count.
Trunc Behavior rules settings with rules switched on per email address and Slack channel, and the current working hours and business countries above

After the alert

Every alert we send is in Alert history for 24 months. Filter by Behavior. The Behavior rules page shows the last 7 days.

To see everything a rule matched, including alerts the limits held back, search:

category:behavior_*

Or one rule, such as category:behavior_offhours_root. Then click the user or the address to see what else they did.

Matches of Login outside working hours, Desktop login outside working hours and Login from outside your business countries are also tagged MITRE ATT&CK T1078 (Valid Accounts).

Trunc Alert history filtered to Behavior alerts, showing each alert, where it was sent and whether it was delivered

Limits

  • Processing time. The rules use the time we processed the line, usually seconds after the host wrote it. A late log can land on the wrong side of your hours. While we catch up on a past day's file, the time rules are paused.
  • IPv4, country level. IPv6 and private addresses are never checked. A VPN user shows up in the VPN's country. Only the logins ticked under Which logins count are checked.
  • Servers and Windows. Linux server logins, sudo, su and useradd, and Windows desktops and servers are covered. Linux desktop logins aren't yet.
  • Email and Slack only. No PagerDuty, no SMS.
  • You set the profile. Trunc doesn't learn your hours or countries from your logs.

Common questions

Which plan includes it?

All of them, including the free trial. Pricing.

Does Trunc learn what's normal for my users?

No. You set the working hours and the business countries, and the rules check every login against them.

Does it block the login?

No. It sends an alert. To block addresses that brute force your servers, see Active Response.

Which logs does it need?

Linux auth logs (sshd, sudo, su, useradd), sent over syslog or through the Trunc agent. Windows Security and System event logs only through the Trunc agent: Windows events from other forwarders such as NXLog, Snare or Kiwi don't trigger the Windows rules. The supported logs page has the full list.

How it works, with log lines Security Insights MITRE ATT&CK tags Supported logs Pricing

Simple, Affordable, Log Management and Analysis.

14 days free trial. No credit card required.