Skip to content

Commit 320523f

Browse files
authored
gcp generate ecs.yml (#1478)
* convert to ECS generated fields * update changelog, fix id in ecs.yml
1 parent d59c500 commit 320523f

File tree

10 files changed

+358
-916
lines changed

10 files changed

+358
-916
lines changed

packages/gcp/_dev/build/build.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
dependencies:
2+
ecs:
3+
reference: git@1.11

packages/gcp/changelog.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
# newer versions go on top
2+
- version: "0.3.3"
3+
changes:
4+
- description: Convert to generated ECS fields
5+
type: enhancement
6+
link: https://github.com/elastic/integrations/pull/1478
27
- version: '0.3.2'
38
changes:
49
- description: update to ECS 1.11.0

packages/gcp/data_stream/audit/fields/agent.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,3 +196,9 @@
196196
description: >
197197
OS codename, if any.
198198
199+
- name: input.type
200+
type: keyword
201+
description: Input type
202+
- name: log.offset
203+
type: long
204+
description: Log offset
Lines changed: 83 additions & 267 deletions
Original file line numberDiff line numberDiff line change
@@ -1,268 +1,84 @@
1-
- name: message
1+
- external: ecs
2+
name: container.name
3+
- external: ecs
4+
name: container.runtime
5+
- external: ecs
6+
name: ecs.version
7+
- external: ecs
8+
name: event.action
9+
- external: ecs
10+
name: event.ingested
11+
- external: ecs
12+
name: event.outcome
13+
- external: ecs
14+
name: log.file.path
15+
- external: ecs
16+
name: log.logger
17+
- external: ecs
18+
name: message
19+
- external: ecs
20+
name: orchestrator.api_version
21+
- external: ecs
22+
name: orchestrator.cluster.name
23+
- external: ecs
24+
name: orchestrator.cluster.url
25+
- external: ecs
26+
name: orchestrator.cluster.version
27+
- external: ecs
28+
name: orchestrator.namespace
29+
- external: ecs
30+
name: orchestrator.organization
31+
- external: ecs
32+
name: orchestrator.resource.name
33+
- external: ecs
34+
name: orchestrator.resource.type
35+
- external: ecs
36+
name: orchestrator.type
37+
- external: ecs
38+
name: service.name
39+
- external: ecs
40+
name: source.as.number
41+
- external: ecs
42+
name: source.as.organization.name
43+
- external: ecs
44+
name: source.geo.city_name
45+
- external: ecs
46+
name: source.geo.continent_name
47+
- external: ecs
48+
name: source.geo.country_iso_code
49+
- external: ecs
50+
name: source.geo.country_name
51+
- description: Longitude and latitude.
252
level: core
3-
type: text
4-
description: |-
5-
For log events the message field contains the log message, optimized for viewing in a log viewer.
6-
For structured logs without an original message field, other fields can be concatenated to form a human-readable summary of the event.
7-
If multiple messages exist, they can be combined into one message.
8-
- name: container
9-
title: Container
10-
group: 2
11-
type: group
12-
fields:
13-
- name: name
14-
level: extended
15-
type: keyword
16-
description: Container name.
17-
ignore_above: 1024
18-
- name: runtime
19-
level: extended
20-
type: keyword
21-
description: Runtime managing this container.
22-
ignore_above: 1024
23-
- name: ecs.version
24-
type: keyword
25-
description: ECS version
26-
- name: event
27-
title: Event
28-
group: 2
29-
type: group
30-
fields:
31-
- name: action
32-
level: core
33-
type: keyword
34-
description: |-
35-
The action captured by the event.
36-
This describes the information in the event. It is more specific than `event.category`. Examples are `group-add`, `process-started`, `file-created`. The value is normally defined by the implementer.
37-
ignore_above: 1024
38-
- name: ingested
39-
level: core
40-
type: date
41-
description: 'Timestamp when an event arrived in the central data store. This is different from `@timestamp`, which is when the event originally occurred. It''s also different from `event.created`, which is meant to capture the first time an agent saw the event. In normal conditions, assuming no tampering, the timestamps should chronologically look like this: `@timestamp` < `event.created` < `event.ingested`.'
42-
- name: outcome
43-
level: core
44-
type: keyword
45-
description: |-
46-
This is one of four ECS Categorization Fields, and indicates the lowest level in the ECS category hierarchy.
47-
`event.outcome` simply denotes whether the event represents a success or a failure from the perspective of the entity that produced the event.
48-
Note that when a single transaction is described in multiple events, each event may populate different values of `event.outcome`, according to their perspective.
49-
Also note that in the case of a compound event (a single event that contains multiple logical events), this field should be populated with the value that best captures the overall success or failure from the perspective of the event producer.
50-
Further note that not all events will have an associated outcome. For example, this field is generally not populated for metric events, events with `event.type:info`, or any events for which an outcome does not make logical sense.
51-
ignore_above: 1024
52-
- name: input.type
53-
type: keyword
54-
description: Input type
55-
- name: log.file.path
56-
type: keyword
57-
description: Log path
58-
- name: log.offset
59-
type: long
60-
description: Log offset
61-
- name: log.logger
62-
type: keyword
63-
- name: source
64-
title: Source
65-
group: 2
66-
type: group
67-
fields:
68-
- name: as.number
69-
description: Unique number allocated to the autonomous system. The autonomous system number (ASN) uniquely identifies each network on the Internet.
70-
level: extended
71-
type: long
72-
- name: as.organization.name
73-
description: Organization name.
74-
ignore_above: 1024
75-
level: extended
76-
type: keyword
77-
multi_fields:
78-
- name: text
79-
type: text
80-
norms: false
81-
default_field: false
82-
- name: geo.city_name
83-
level: core
84-
type: keyword
85-
description: City name.
86-
ignore_above: 1024
87-
- name: geo.continent_name
88-
level: core
89-
type: keyword
90-
description: Name of the continent.
91-
ignore_above: 1024
92-
- name: geo.country_iso_code
93-
level: core
94-
type: keyword
95-
description: Country ISO code.
96-
ignore_above: 1024
97-
- name: geo.country_name
98-
description: Country name.
99-
ignore_above: 1024
100-
level: core
101-
type: keyword
102-
- name: geo.location
103-
level: core
104-
type: geo_point
105-
description: Longitude and latitude.
106-
- name: geo.region_iso_code
107-
level: core
108-
type: keyword
109-
description: Region ISO code.
110-
ignore_above: 1024
111-
- name: geo.region_name
112-
level: core
113-
type: keyword
114-
description: Region name.
115-
ignore_above: 1024
116-
- name: ip
117-
level: core
118-
type: ip
119-
description: IP address of the source (IPv4 or IPv6).
120-
- name: service.name
121-
level: core
122-
type: keyword
123-
ignore_above: 1024
124-
description: Name of the service data is collected from.
125-
- name: tags
126-
level: core
127-
type: keyword
128-
ignore_above: 1024
129-
description: List of keywords used to tag each event.
130-
- name: user.email
131-
level: extended
132-
type: wildcard
133-
description: User email address.
134-
- name: user_agent
135-
title: User agent
136-
group: 2
137-
description: 'The user_agent fields normally come from a browser request.
138-
139-
They often show up in web service logs coming from the parsed user agent string.'
140-
type: group
141-
fields:
142-
- name: device.name
143-
level: extended
144-
type: keyword
145-
ignore_above: 1024
146-
description: Name of the device.
147-
- name: name
148-
level: extended
149-
type: keyword
150-
ignore_above: 1024
151-
description: Name of the user agent.
152-
- name: original
153-
level: extended
154-
type: wildcard
155-
multi_fields:
156-
- name: text
157-
type: text
158-
norms: false
159-
description: Unparsed user_agent string.
160-
- name: os.family
161-
level: extended
162-
type: keyword
163-
ignore_above: 1024
164-
description: OS family (such as redhat, debian, freebsd, windows).
165-
- name: os.full
166-
level: extended
167-
type: wildcard
168-
multi_fields:
169-
- name: text
170-
type: text
171-
norms: false
172-
default_field: false
173-
description: Operating system name, including the version or code name.
174-
- name: os.kernel
175-
level: extended
176-
type: keyword
177-
ignore_above: 1024
178-
description: Operating system kernel version as a raw string.
179-
- name: os.name
180-
level: extended
181-
type: wildcard
182-
multi_fields:
183-
- name: text
184-
type: text
185-
norms: false
186-
default_field: false
187-
description: Operating system name, without the version.
188-
- name: os.platform
189-
level: extended
190-
type: keyword
191-
ignore_above: 1024
192-
description: Operating system platform (such centos, ubuntu, windows).
193-
- name: os.version
194-
level: extended
195-
type: keyword
196-
ignore_above: 1024
197-
description: Operating system version as a raw string.
198-
- name: version
199-
level: extended
200-
type: keyword
201-
ignore_above: 1024
202-
description: Version of the user agent.
203-
- name: orchestrator
204-
title: Orchestrator
205-
group: 2
206-
description: Fields that describe the resources which container orchestrators manage or act upon.
207-
type: group
208-
fields:
209-
- name: api_version
210-
level: extended
211-
type: keyword
212-
ignore_above: 1024
213-
description: API version being used to carry out the action
214-
example: v1beta1
215-
default_field: false
216-
- name: cluster.name
217-
level: extended
218-
type: keyword
219-
ignore_above: 1024
220-
description: Name of the cluster.
221-
default_field: false
222-
- name: cluster.url
223-
level: extended
224-
type: keyword
225-
ignore_above: 1024
226-
description: URL of the API used to manage the cluster.
227-
default_field: false
228-
- name: cluster.version
229-
level: extended
230-
type: keyword
231-
ignore_above: 1024
232-
description: The version of the cluster.
233-
default_field: false
234-
- name: namespace
235-
level: extended
236-
type: keyword
237-
ignore_above: 1024
238-
description: Namespace in which the action is taking place.
239-
example: kube-system
240-
default_field: false
241-
- name: organization
242-
level: extended
243-
type: keyword
244-
ignore_above: 1024
245-
description: Organization affected by the event (for multi-tenant orchestrator setups).
246-
example: elastic
247-
default_field: false
248-
- name: resource.name
249-
level: extended
250-
type: keyword
251-
ignore_above: 1024
252-
description: Name of the resource being acted upon.
253-
example: test-pod-cdcws
254-
default_field: false
255-
- name: resource.type
256-
level: extended
257-
type: keyword
258-
ignore_above: 1024
259-
description: Type of resource being acted upon.
260-
example: service
261-
default_field: false
262-
- name: type
263-
level: extended
264-
type: keyword
265-
ignore_above: 1024
266-
description: Orchestrator cluster type (e.g. kubernetes, nomad or cloudfoundry).
267-
example: kubernetes
268-
default_field: false
53+
name: source.geo.location
54+
type: geo_point
55+
- external: ecs
56+
name: source.geo.region_iso_code
57+
- external: ecs
58+
name: source.geo.region_name
59+
- external: ecs
60+
name: source.ip
61+
- external: ecs
62+
name: tags
63+
- external: ecs
64+
name: user.email
65+
- external: ecs
66+
name: user_agent.device.name
67+
- external: ecs
68+
name: user_agent.name
69+
- external: ecs
70+
name: user_agent.original
71+
- external: ecs
72+
name: user_agent.os.family
73+
- external: ecs
74+
name: user_agent.os.full
75+
- external: ecs
76+
name: user_agent.os.kernel
77+
- external: ecs
78+
name: user_agent.os.name
79+
- external: ecs
80+
name: user_agent.os.platform
81+
- external: ecs
82+
name: user_agent.os.version
83+
- external: ecs
84+
name: user_agent.version

packages/gcp/data_stream/firewall/fields/agent.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,3 +196,9 @@
196196
description: >
197197
OS codename, if any.
198198
199+
- name: input.type
200+
type: keyword
201+
description: Input type
202+
- name: log.offset
203+
type: long
204+
description: Log offset

0 commit comments

Comments
 (0)