feat: host session list/terminate and event session actions (0.20.28)
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import type { EventSummary } from "../api";
|
||||
|
||||
const LINUX_SESSION_EVENT_TYPES = new Set([
|
||||
"session.logind.new",
|
||||
"ssh.login.success",
|
||||
"privilege.sudo.command",
|
||||
]);
|
||||
|
||||
const WINDOWS_SESSION_EVENT_TYPES = new Set(["rdp.login.success"]);
|
||||
|
||||
export function eventSupportsSessionTerminate(event: Pick<EventSummary, "type">): boolean {
|
||||
return (
|
||||
LINUX_SESSION_EVENT_TYPES.has(event.type) ||
|
||||
WINDOWS_SESSION_EVENT_TYPES.has(event.type)
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user