osquery_policy

Column Type PK Required Default
osquery_policy_id TEXT Yes Yes
policy_group TEXT No No
policy_name TEXT No Yes
osquery_code TEXT No Yes
policy_description TEXT No Yes
policy_pass_label TEXT No Yes 'Pass'
policy_fail_label TEXT No Yes 'Fail'
policy_pass_remarks TEXT No No
policy_fail_remarks TEXT No No
osquery_platforms TEXT No No
created_at TIMESTAMPTZ No No CURRENT_TIMESTAMP
created_by TEXT No No 'UNKNOWN'
updated_at TIMESTAMPTZ No No
updated_by TEXT No No
deleted_at TIMESTAMPTZ No No
deleted_by TEXT No No
activity_log TEXT No No

Foreign Keys

No data

Indexes

Column Name Index Name
policy_name osquery_policy_policy_name_osquery_code_unique
osquery_code osquery_policy_policy_name_osquery_code_unique
osquery_policy_id sqlite_autoindex_osquery_policy_1

SQL DDL

CREATE TABLE `osquery_policy` (
	`osquery_policy_id` text PRIMARY KEY NOT NULL,
	`policy_group` text,
	`policy_name` text NOT NULL,
	`osquery_code` text NOT NULL,
	`policy_description` text NOT NULL,
	`policy_pass_label` text DEFAULT 'Pass' NOT NULL,
	`policy_fail_label` text DEFAULT 'Fail' NOT NULL,
	`policy_pass_remarks` text,
	`policy_fail_remarks` text,
	`osquery_platforms` text,
	`created_at` TIMESTAMPTZ DEFAULT CURRENT_TIMESTAMP,
	`created_by` text DEFAULT 'UNKNOWN',
	`updated_at` TIMESTAMPTZ,
	`updated_by` text,
	`deleted_at` TIMESTAMPTZ,
	`deleted_by` text,
	`activity_log` text
)