Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use tabs in vocab JSDoc #3

Merged
merged 1 commit into from
Dec 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions src/vocab/authentication.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,11 @@ export function authn_login_successafterfail<
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authn_login_fail:joebob1",
* "level": "WARN",
* "description": "User joebob1 login failed",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authn_login_fail:joebob1",
* "level": "WARN",
* "description": "User joebob1 login failed",
* "requestId": "b7c29e30-199e-4234-a8f1-fff0c12f1624"
* }
* ```
Expand All @@ -104,11 +104,11 @@ export function authn_login_fail<U extends string | number | bigint>(
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authn_login_fail_max:joebob1,3",
* "level": "WARN",
* "description": "User joebob1 reached the login fail limit of 3",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authn_login_fail_max:joebob1,3",
* "level": "WARN",
* "description": "User joebob1 reached the login fail limit of 3",
* "requestId": "b7c29e30-199e-4234-a8f1-fff0c12f1624"
* }
* ```
Expand Down Expand Up @@ -137,10 +137,10 @@ export function authn_login_fail_max<
*
* **Reasons:**
* ```txt
* maxretries: The maximum number of retries was reached
* suspicious: Suspicious activity was observed on the account
* customer: The customer requested their account be locked
* other: Other
* maxretries: The maximum number of retries was reached
* suspicious: Suspicious activity was observed on the account
* customer: The customer requested their account be locked
* other: Other
* ```
* @example
* ```ts
Expand Down
20 changes: 10 additions & 10 deletions src/vocab/authorization.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authz_fail:joebob1,resource",
* "level": "CRITICAL",
* "description": "User joebob1 attempted to access a resource without entitlement",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authz_fail:joebob1,resource",
* "level": "CRITICAL",
* "description": "User joebob1 attempted to access a resource without entitlement",
* "requestId": "00b13b12-51ab-49bc-94be-34c450804850"
* }
* ```
Expand Down Expand Up @@ -44,11 +44,11 @@ export function authz_fail<
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authz_change:joebob1,user,admin",
* "level": "WARN",
* "description": "User joebob1 access was changed from user to admin",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "authz_change:joebob1,user,admin",
* "level": "WARN",
* "description": "User joebob1 access was changed from user to admin",
* "requestId": "5e952d3b-97b6-4c20-a241-b3aa9a591647"
* }
* ```
Expand Down
6 changes: 3 additions & 3 deletions src/vocab/file-upload.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ export function upload_stored<N extends string, T extends string>(
* const { status } = await performVirusScan(filepath); // PASSED, INCOMPLETE, FAILED
* const vendor = "virusscan"; // imagemagick, clamav, etc.
* if (status === "FAILED") {
* await fs.promises.rm(filepath, { force: true })
* logger.critical({ event: upload_validation(filename, vendor, status) }, `File ${filename} ${status} virus scan and was purged`);
* await fs.promises.rm(filepath, { force: true })
* logger.critical({ event: upload_validation(filename, vendor, status) }, `File ${filename} ${status} virus scan and was purged`);
* } else {
* logger.info({ event: upload_validation(filename, vendor, status) }, `File ${filename} ${status} virus scan`);
* logger.info({ event: upload_validation(filename, vendor, status) }, `File ${filename} ${status} virus scan`);
* }
*
* ```
Expand Down
40 changes: 20 additions & 20 deletions src/vocab/sensitive-data-changes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_create:joebob1, /users/admin/some/important/path",
* "level": "WARN",
* "description": "User joebob1 created a new file in /users/admin/some/important/path",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_create:joebob1, /users/admin/some/important/path",
* "level": "WARN",
* "description": "User joebob1 created a new file in /users/admin/some/important/path",
* "requestId": "cd1f3327-48ea-4614-bce0-260d14e30e93"
* }
* ```
Expand Down Expand Up @@ -46,11 +46,11 @@ export function sensitive_create<
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_read:joebob1, /users/admin/some/important/path",
* "level": "INFO",
* "description": "User joebob1 read file /users/admin/some/important/path",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_read:joebob1, /users/admin/some/important/path",
* "level": "INFO",
* "description": "User joebob1 read file /users/admin/some/important/path",
* "requestId": "df064296-507f-46e3-8384-bb14966cd2bc"
* }
* ```
Expand Down Expand Up @@ -80,11 +80,11 @@ export function sensitive_read<
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_update:joebob1, /users/admin/some/important/path",
* "level": "WARN",
* "description": "User joebob1 modified file /users/admin/some/important/path",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_update:joebob1, /users/admin/some/important/path",
* "level": "WARN",
* "description": "User joebob1 modified file /users/admin/some/important/path",
* "requestId": "9345a8a2-611e-4053-a75c-05c29101dc59"
* }
* ```
Expand Down Expand Up @@ -114,11 +114,11 @@ export function sensitive_update<
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_delete:joebob1, /users/admin/some/important/path",
* "level": "WARN",
* "description": "User joebob1 marked file /users/admin/some/important/path for deletion",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sensitive_delete:joebob1, /users/admin/some/important/path",
* "level": "WARN",
* "description": "User joebob1 marked file /users/admin/some/important/path for deletion",
* "requestId": "f6a08db8-df7a-4b13-82ee-18aaf15c7fc1"
* }
* ```
Expand Down
10 changes: 5 additions & 5 deletions src/vocab/sequence-errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sequence_fail:joebob1",
* "level": "WARN",
* "description": "User joebob1 has reached a part of the application out of the normal application flow.",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sequence_fail:joebob1",
* "level": "WARN",
* "description": "User joebob1 has reached a part of the application out of the normal application flow.",
* "requestId": "b6de2047-08f0-4041-aab1-c693d337d63b"
* }
* ```
Expand Down
40 changes: 20 additions & 20 deletions src/vocab/session-management.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_created:joebob1",
* "level": "INFO",
* "description": "User joebob1 has started a new session",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_created:joebob1",
* "level": "INFO",
* "description": "User joebob1 has started a new session",
* "requestId": "3852a457-6d69-4f8c-a98e-aeafe5f1fdd1"
* }
* ```
Expand All @@ -39,11 +39,11 @@ export function session_created<U extends string | number | bigint>(userId: U) {
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_renewed:joebob1",
* "level": "INFO",
* "description": "User joebob1 was warned of expiring session and extended",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_renewed:joebob1",
* "level": "INFO",
* "description": "User joebob1 was warned of expiring session and extended",
* "requestId": "ec67b394-8391-4579-94fb-a36719ab5292"
* }
* ```
Expand All @@ -70,11 +70,11 @@ export function session_renewed<U extends string | number | bigint>(userId: U) {
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_expired:joebob1,revoked",
* "level": "INFO",
* "description": "User joebob1 session expired due to administrator revocation.",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_expired:joebob1,revoked",
* "level": "INFO",
* "description": "User joebob1 session expired due to administrator revocation.",
* "requestId": "5c0f4762-1170-437f-b618-4406847a533b"
* }
* ```
Expand Down Expand Up @@ -102,11 +102,11 @@ export function session_expired<
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_use_after_expire:joebob1",
* "level": "WARN",
* "description": "User joebob1 attempted access after session expired.",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "session_use_after_expire:joebob1",
* "level": "WARN",
* "description": "User joebob1 attempted access after session expired.",
* "requestId": "..."
* }
* ```
Expand Down
60 changes: 30 additions & 30 deletions src/vocab/system-events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_startup:joebob1",
* "level": "WARN",
* "description": "User joebob1 spawned a new instance",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_startup:joebob1",
* "level": "WARN",
* "description": "User joebob1 spawned a new instance",
* "requestId": "27939458-b680-4132-925f-4dc38678b4b2"
* }
* ```
Expand All @@ -40,11 +40,11 @@ export function sys_startup<U extends string | number | bigint>(userId: U) {
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_shutdown:joebob1",
* "level": "WARN",
* "description": "User joebob1 stopped this instance",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_shutdown:joebob1",
* "level": "WARN",
* "description": "User joebob1 stopped this instance",
* "requestId": "cbe8f317-085c-46a6-9551-057b7c275b63"
* }
* ```
Expand All @@ -68,11 +68,11 @@ export function sys_shutdown<U extends string | number | bigint>(userId: U) {
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_restart:joebob1",
* "level": "WARN",
* "description": "User joebob1 initiated a restart",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_restart:joebob1",
* "level": "WARN",
* "description": "User joebob1 initiated a restart",
* "requestId": "1e7b4e37-7acd-4d08-89e9-8a9b07de6a90"
* }
* ```
Expand All @@ -97,11 +97,11 @@ export function sys_restarted<U extends string | number | bigint>(userId: U) {
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_crash:outofmemory",
* "level": "WARN",
* "description": "The system crashed due to Out of Memory error.",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_crash:outofmemory",
* "level": "WARN",
* "description": "The system crashed due to Out of Memory error.",
* "requestId": "43549e84-4d5a-402c-a5cd-753a28795f82"
* }
* ```
Expand All @@ -127,11 +127,11 @@ export function sys_crash<R extends string>(reason: R) {
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_monitor_disabled:joebob1,crowdstrike",
* "level": "WARN",
* "description": "User joebob1 has disabled CrowdStrike",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_monitor_disabled:joebob1,crowdstrike",
* "level": "WARN",
* "description": "User joebob1 has disabled CrowdStrike",
* "requestId": "897365e2-7cd2-475d-a94b-082bf11f368e"
* }
* ```
Expand Down Expand Up @@ -161,11 +161,11 @@ export function sys_monitor_disabled<
* @example
* ```json
* {
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_monitor_enabled:joebob1,crowdstrike",
* "level": "WARN",
* "description": "User joebob1 has enabled CrowdStrike",
* "datetime": "2019-01-01 00:00:00,000",
* "appid": "foobar.netportal_auth",
* "event": "sys_monitor_enabled:joebob1,crowdstrike",
* "level": "WARN",
* "description": "User joebob1 has enabled CrowdStrike",
* "requestId": "897365e2-7cd2-475d-a94b-082bf11f368e"
* }
* ```
Expand Down
Loading
Loading