Skip to main content
User guide

Security

Access security allows or denies the whole system by source IP; login policies restrict sign-in for chosen users by source IP and time.

Security (安全策略) has two pages. Access security (访问安全) applies to every request, and Login policies (登录策略) apply only to the users bound to them. Both cover the web console and the built-in SSH service.

With a reverse proxy in front, set BASTION_TRUSTED_PROXIES first, or the bastion sees the proxy's IP instead of the client's; see Configuration.

Access security

Allows or denies access to the whole system by source IP. Rules take effect as soon as they are saved. With no rules, every address is allowed.

Rules are matched by priority, lowest number first, and the first match applies.

Steps

  1. Select New rule (新建规则).
  2. Enter the Address: a single IP, a CIDR, a range or several entries separated by commas. IPv6 is supported.
  3. Pick the Rule: Deny access or Allow access.
  4. Enter a Priority, 1 or higher.
  5. Select Save.

Rules apply to administrators too. Before adding a deny rule, make sure it does not block your own current IP. If you are locked out, it has to be fixed on the server; contact technical support.

The built-in Security administrator role (安全管理员) can manage access security rules.

Login policies

Restrict sign-in for chosen users by source IP and time. A policy takes effect at sign-in once it is bound to a user. Several policies are matched by priority, lowest number first, and sign-in is allowed if none matches.

Steps

  1. Select New policy (新建策略).
  2. Enter a Name and Priority.
  3. Enter the Address, separated by commas: single IPs, CIDRs (such as 10.0.0.0/8), ranges (such as 192.168.1.1-192.168.1.100) and IPv6. 0.0.0.0 means every address.
  4. Pick the Rule: Deny sign-in or Allow sign-in.
  5. (Optional) Pick time slots in the weekly grid under Active time. Within the selected slots the rule applies; with no slots selected there is no time limit and only the IP is checked.
  6. Make sure Enabled is on and select Save.
  7. In the policy's row, select Bind users (绑定用户), then Add user, pick the users and select Bind.

Only users bound to a policy are checked against it. In a user's row in Users, select Login policies to see and unbind that user's policies. When a policy is deleted, its users are no longer restricted by it.

On this page