-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Co-authored-by: Luke Elmers <[email protected]>
- Loading branch information
1 parent
f730038
commit b91f8c8
Showing
52 changed files
with
326 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0 and the Server Side Public License, v 1; you may not use this file except | ||
* in compliance with, at your election, the Elastic License 2.0 or the Server | ||
* Side Public License, v 1. | ||
*/ | ||
|
||
/** | ||
* https://www.elastic.co/guide/en/ecs/1.12/ecs-data_stream.html | ||
* | ||
* @internal | ||
*/ | ||
export interface EcsDataStream { | ||
dataset?: string; | ||
namespace?: string; | ||
type?: 'logs' | 'metrics'; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0 and the Server Side Public License, v 1; you may not use this file except | ||
* in compliance with, at your election, the Elastic License 2.0 or the Server | ||
* Side Public License, v 1. | ||
*/ | ||
|
||
/** | ||
* https://www.elastic.co/guide/en/ecs/1.12/ecs-elf.html | ||
* | ||
* @internal | ||
*/ | ||
export interface EcsElf { | ||
architecture?: string; | ||
byte_order?: string; | ||
cpu_type?: string; | ||
creation_date?: string; | ||
exports?: Export[]; | ||
imports?: Import[]; | ||
header?: Header; | ||
sections?: Section[]; | ||
segments?: Segment[]; | ||
shared_libraries?: string[]; | ||
telfhash?: string; | ||
} | ||
|
||
interface Export { | ||
binding?: string; | ||
name?: string; | ||
section?: string; | ||
size?: string; | ||
type?: string; | ||
version?: string; | ||
visibility?: string; | ||
} | ||
|
||
interface Import { | ||
library?: string; | ||
name?: string; | ||
type?: string; | ||
version?: string; | ||
} | ||
|
||
interface Header { | ||
abi_version?: string; | ||
class?: string; | ||
data?: string; | ||
entrypoint?: number; | ||
object_version?: string; | ||
os_abi?: string; | ||
type?: string; | ||
version?: string; | ||
} | ||
|
||
interface Section { | ||
chi2?: number; | ||
entropy?: number; | ||
flags?: string; | ||
name?: string; | ||
physical_offset?: string; | ||
physical_size?: number; | ||
type?: string; | ||
virtual_address?: number; | ||
virtual_size?: number; | ||
} | ||
|
||
interface Segment { | ||
sections?: string; | ||
type?: string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/* | ||
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one | ||
* or more contributor license agreements. Licensed under the Elastic License | ||
* 2.0 and the Server Side Public License, v 1; you may not use this file except | ||
* in compliance with, at your election, the Elastic License 2.0 or the Server | ||
* Side Public License, v 1. | ||
*/ | ||
|
||
import { EcsFile } from './file'; | ||
import { EcsHash } from './hash'; | ||
|
||
interface NestedFields { | ||
// Not all hash types are explicitly supported, see | ||
// https://github.com/elastic/ecs/pull/1569 | ||
hash?: Pick<EcsHash, 'md5' | 'sha1' | 'sha256'>; | ||
} | ||
|
||
interface AttachmentNestedFields { | ||
file?: Pick<EcsFile, 'extension' | 'mime_type' | 'name' | 'size' | 'hash'>; | ||
} | ||
|
||
/** | ||
* No docs yet, see https://github.com/elastic/ecs/pull/1569 | ||
* | ||
* @internal | ||
*/ | ||
export interface EcsEmail extends NestedFields { | ||
attachments?: Attachment[]; | ||
bcc?: string[]; | ||
cc?: string[]; | ||
content_type?: string; | ||
delivery_timestamp?: string; | ||
direction?: string; | ||
from?: string; | ||
local_id?: string; | ||
message_id?: string; | ||
origination_timestamp?: string; | ||
reply_to?: string; | ||
subject?: string; | ||
'subject.text'?: string; | ||
to?: string[]; | ||
x_mailer?: string; | ||
} | ||
|
||
// eslint-disable-next-line @typescript-eslint/no-empty-interface | ||
interface Attachment extends AttachmentNestedFields { | ||
// intentionally empty | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.