You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit be7e61c
Browse filesBrowse the repository at this point in the historyBrowse files
For other users the IP column shows a masked value, own sessions included. Hidden IPs are not sent to the
78
+
browser at all, so they can't be read from the network tab either.
79
+
80
+
The callback covers the "Active sessions" page and the block on the show page of a user. IPs in the
81
+
[login history](#login-history) are columns of your own resource, restrict them there, e.g. with
82
+
`allowedActions`. The [revoke page](#revoke-page) shows the IP to whoever has the link from `onNewLogin`.
83
+
65
84
## Client IP and country
66
85
67
86
IP is taken from [`adminforth.auth.getClientIp`](/docs/tutorial/Customization/security#trusting-client-ip-addresses),
@@ -320,6 +339,7 @@ export default {
320
339
| `countryHeader` | `CF-IPCountry` | Header with two-letter country code set by your CDN, empty string disables it |
321
340
| `resolveCountry` | — | Called when the header did not tell the country |
322
341
| `canManageOtherUsersSessions` | — | `(adminUser) =>Promise<boolean>`, decides who may see and revoke sessions of other users |
342
+
| `canSeeIps` | — | `(adminUser) =>Promise<boolean>`, decides who sees IPs of sessions, see [Hiding IP addresses](#hiding-ip-addresses) |
323
343
| `lastUsedThrottleSeconds` | `60` | How often `last_used_at` is refreshed. Every refresh is one write to the adapter |
324
344
| `onNewLogin` | — | `({ pk, username, session, reasons, revokePath }) =>Promise<void>`, called after a sign-in from a new device or country, see [Notifying about sign-ins from new devices](#notifying-about-sign-ins-from-new-devices) |
325
345
| `loginHistory.resourceId` | — | Resource where sign-ins and failed attempts are stored, see [Login history](#login-history) |
0 commit comments