struct

ECS::LogEntry::Source

Inherits JSON::Serializable < Struct < Value < Object

Constructors

new(pull : JSON::PullParser)
Source
new

Initialize all values as nil

Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source

Instance methods

_as(value : As)

A chainable setter for @as.

Source
_as

Note that Crystal does not allow redefining the #as method of Object.

Source
_as

Initialize a new As, yield it to the block

Source
_as=(_as : As | Nil)

Note that Crystal does not allow redefining the #as method of Object.

Source
address(new_value : String)

A chainable setter for address

Source
address

source.address

Some event source addresses are defined ambiguously. The event will sometimes list an IP, a domain or a unix socket. You should always store the raw address in the .address field.

Then it should be duplicated to .ip or .domain, depending on which one it is.

Level: Extended Type: Keyword

Source
address=(address : String | Nil)

source.address

Some event source addresses are defined ambiguously. The event will sometimes list an IP, a domain or a unix socket. You should always store the raw address in the .address field.

Then it should be duplicated to .ip or .domain, depending on which one it is.

Level: Extended Type: Keyword

Source
bytes(new_value : UInt64)

A chainable setter for bytes

Source
bytes

source.bytes

Bytes sent from the source to the destination.

Level: Core Type: Long Example:

184
Source
bytes=(bytes : UInt64 | Nil)

source.bytes

Bytes sent from the source to the destination.

Level: Core Type: Long Example:

184
Source
domain(new_value : String)

A chainable setter for domain

Source
domain

source.domain

Source domain.

Level: Core Type: Keyword

Source
domain=(domain : String | Nil)

source.domain

Source domain.

Level: Core Type: Keyword

Source
geo(value : Geo)

A chainable setter for geo

Source
geo

Initialize a new Geo, yield it to the block

Source
geo=(geo : Geo | Nil)
Source
ip(new_value : String)

A chainable setter for ip

Source
ip

source.ip

IP address of the source (IPv4 or IPv6).

Level: Core Type: IP

Source
ip=(ip : String | Nil)

source.ip

IP address of the source (IPv4 or IPv6).

Level: Core Type: IP

Source
mac(new_value : String)

A chainable setter for mac

Source
mac

source.mac

MAC address of the source.

Level: Core Type: Keyword

Source
mac=(mac : String | Nil)

source.mac

MAC address of the source.

Level: Core Type: Keyword

Source
nat(value : Nat)

A chainable setter for nat

Source
nat

Initialize a new Nat, yield it to the block

Source
nat=(nat : Nat | Nil)
Source
packets(new_value : UInt64)

A chainable setter for packets

Source
packets

source.packets

Packets sent from the source to the destination.

Level: Core Type: Long Example:

12
Source
packets=(packets : UInt64 | Nil)

source.packets

Packets sent from the source to the destination.

Level: Core Type: Long Example:

12
Source
port(new_value : UInt64)

A chainable setter for port

Source
port

source.port

Port of the source.

Level: Core Type: Long

Source
port=(port : UInt64 | Nil)

source.port

Port of the source.

Level: Core Type: Long

Source
registered_domain(new_value : String)

A chainable setter for registered_domain

Source
registered_domain

source.registered_domain

The highest registered source domain, stripped of the subdomain.

For example, the registered domain for "foo.google.com" is "google.com".

This value can be determined precisely with a list like the public suffix list (http://publicsuffix.org). Trying to approximate this by simply taking the last two labels will not work well for TLDs such as "co.uk".

Level: Extended Type: Keyword Example:

google.com
Source
registered_domain=(registered_domain : String | Nil)

source.registered_domain

The highest registered source domain, stripped of the subdomain.

For example, the registered domain for "foo.google.com" is "google.com".

This value can be determined precisely with a list like the public suffix list (http://publicsuffix.org). Trying to approximate this by simply taking the last two labels will not work well for TLDs such as "co.uk".

Level: Extended Type: Keyword Example:

google.com
Source
top_level_domain(new_value : String)

A chainable setter for top_level_domain

Source
top_level_domain

source.top_level_domain

The effective top level domain (eTLD), also known as the domain suffix, is the last part of the domain name. For example, the top level domain for google.com is "com".

This value can be determined precisely with a list like the public suffix list (http://publicsuffix.org). Trying to approximate this by simply taking the last label will not work well for effective TLDs such as "co.uk".

Level: Extended Type: Keyword Example:

co.uk
Source
top_level_domain=(top_level_domain : String | Nil)

source.top_level_domain

The effective top level domain (eTLD), also known as the domain suffix, is the last part of the domain name. For example, the top level domain for google.com is "com".

This value can be determined precisely with a list like the public suffix list (http://publicsuffix.org). Trying to approximate this by simply taking the last label will not work well for effective TLDs such as "co.uk".

Level: Extended Type: Keyword Example:

co.uk
Source
user(value : User)

A chainable setter for user

Source
user
Source
user

Initialize a new User, yield it to the block

Source
user=(user : User | Nil)
Source

Nested types